邓雄飞 4 years ago
parent
commit
0e87ca304a
3 changed files with 17 additions and 7 deletions
  1. 4
      components/qn-input-number/qn-input-number.vue
  2. 12
      pages/login/index.vue
  3. 8
      pages/paper-details/index.vue

4
components/qn-input-number/qn-input-number.vue

@ -15,6 +15,7 @@
placeholder="请输入"
@blur="blur"
@confirm="confirm"
@input="input"
></qn-easyinput>
</view>
<view class="minus-box" @tap="addTap"><uni-icons size="16" type="plusempty" color="#007AFF"></uni-icons></view>
@ -43,6 +44,9 @@ export default {
}
},
methods: {
input(value) {
this.$emit('input', value)
},
blur(e) {
this.$emit('change', e.detail.value)
},

12
pages/login/index.vue

@ -1,5 +1,5 @@
<template>
<view style="background-color: white">
<view class="content">
<uni-nav-bar :fixed="true" color="#ffffff" background-color="#ffffff" :status-bar="true" :border="false" left-icon="closeempty" @clickLeft="close" />
<view class="logo_area">
<image class="logo" src="/static/logo.png"></image>
@ -174,7 +174,13 @@ export default {
}
</script>
<style lang="scss">
<style lang="scss" scoped>
.content {
background-color: white;
height: 100vh;
min-height: 650px;
position: relative;
}
.logo_area {
margin-top: 187rpx;
width: 750rpx;
@ -244,7 +250,7 @@ export default {
}
}
.agreement_area {
position: fixed;
position: absolute;
bottom: 108rpx;
width: 750rpx;
display: flex;

8
pages/paper-details/index.vue

@ -129,7 +129,7 @@
</view>
<view class="quantity-row">
<view class="label">购买数量()</view>
<view class=""><qnInputNumber @change="change" /></view>
<view class=""><qnInputNumber @input="change" /></view>
</view>
<view class="ygzl-text">预估重量{{ buyTon }}</view>
<view class="popup-footer-row"><view class="btn" @tap="confirm">确认</view></view>
@ -234,8 +234,8 @@ export default {
if (this.hasLogin) {
this.queryData()
} else {
this.$store.commit('setNextPage', { name: 'paper-detail', data: { paperId: option.paperId } })
go2('login')
this.$store.commit('setNextPage', { name: 'paper-details', data: { paperId: option.paperId } })
go2('login', {}, true)
}
} else {
uni.showToast({
@ -376,7 +376,7 @@ export default {
* 计数器返回值
*/
change(num) {
this.buyPaperDto.pieceQuantity = num
this.buyPaperDto.pieceQuantity = num || 0
},
//
confirm() {

Loading…
Cancel
Save