Merge remote-tracking branch 'origin/dev' into dev
This commit is contained in:
@@ -4,7 +4,7 @@
|
||||
<div class="header">
|
||||
<div class="header-left">
|
||||
<span>★</span>
|
||||
积分余额:428
|
||||
积分余额:{{userIntegral}}
|
||||
</div>
|
||||
<div class="header-right">
|
||||
<div @click="toMyOrder">我的订单</div>
|
||||
@@ -13,35 +13,24 @@
|
||||
</AiTopFixed>
|
||||
<div class="list-content">
|
||||
<div class="select">
|
||||
<div class="active">最新上架</div>
|
||||
<div class="price active">价格<span class="top active">⏶</span><span class="bottom">⏷</span></div>
|
||||
<div class="sure active">可兑换的
|
||||
<img src="./components/imgs/check-icon.png" alt="">
|
||||
<div :class="search.newStatus == 1 ? 'active' : ''" @click="clickNew()">最新上架</div>
|
||||
<div class="price active" @click="clickPrice()">价格<span class="top" :class="search.priceStatus == 1 ? 'active' : ''">⏶</span><span class="bottom" :class="search.priceStatus != 1 ? 'active' : ''">⏷</span></div>
|
||||
<div class="sure" :class="search.status == 2 ? 'active' : ''" @click="clickStatus()">可兑换的
|
||||
<img src="./components/imgs/check-icon.png" alt="" v-if="search.status == 2">
|
||||
</div>
|
||||
</div>
|
||||
<div class="type">
|
||||
<div class="type-item" :class="index == typeIndex ? 'active' : ''" v-for="(item, index) in typeList" :key="index" @click="typeClick(index)">{{item}}</div>
|
||||
</div>
|
||||
<div class="item" @click="toDetail()">
|
||||
<div class="item" :class="item.status != 0 ? 'lack-item' : ''" v-for="(item, index) in list" :key="index" @click="toDetail(item)">
|
||||
<div class="left">
|
||||
<img src="./components/imgs/check-icon.png" alt="">
|
||||
<img :src="item.imageUrl" alt="">
|
||||
</div>
|
||||
<div class="right">
|
||||
<p>天薇抽纸天然无香纸巾天薇抽纸天然无香纸巾天薇抽纸天然无香纸巾可湿水天薇抽纸天然无香纸巾可湿水</p>
|
||||
<h3>10<span>积分</span></h3>
|
||||
|
||||
<p>{{item.merchandiseName}}</p>
|
||||
<h3>{{item.merchandiseIntegral}}<span>积分</span></h3>
|
||||
</div>
|
||||
</div>
|
||||
<div class="item lack-item">
|
||||
<div class="left">
|
||||
<img src="./components/imgs/check-icon.png" alt="">
|
||||
</div>
|
||||
<div class="right">
|
||||
<p>天薇抽纸天然无香纸巾天薇抽纸天然无香纸巾天薇抽纸天然无香纸巾可湿水天薇抽纸天然无香纸巾可湿水</p>
|
||||
<h3>10<span>积分</span></h3>
|
||||
|
||||
</div>
|
||||
<img src="./components/imgs/lack-icon.png" alt="" class="status" />
|
||||
<img src="./components/imgs/lack-icon.png" alt="" class="status" v-if="item.status != 0"/>
|
||||
</div>
|
||||
</div>
|
||||
<!-- <AiEmpty v-else></AiEmpty> -->
|
||||
@@ -58,29 +47,44 @@ export default {
|
||||
return {
|
||||
current: 1,
|
||||
list: [],
|
||||
typeList: ['全部', '100分以下', '500分以下', '1000分以下', '5000分以下', '10000分以下'],
|
||||
typeIndex: 0
|
||||
typeList: ['全部', '100分以下', '500分以下', '1000分以下', '5000分以下'],
|
||||
typeIndex: 0,
|
||||
search: {
|
||||
status: '',
|
||||
newStatus: '',
|
||||
priceStatus: '1'
|
||||
},
|
||||
userIntegral: ''
|
||||
}
|
||||
},
|
||||
computed: {
|
||||
...mapState(['user']),
|
||||
},
|
||||
onLoad() {
|
||||
// this.getList()
|
||||
// uni.$on('reload', () => {
|
||||
// this.getListInit()
|
||||
// })
|
||||
this.getList()
|
||||
this.getIntegral()
|
||||
uni.$on('reloadIntegral', () => {
|
||||
this.getIntegral()
|
||||
})
|
||||
},
|
||||
onShow() {
|
||||
document.title = '积分兑换'
|
||||
},
|
||||
methods: {
|
||||
getIntegral() {
|
||||
this.$http.post('/app/appintegraluser/appGirdIntegral?current=1&size=1').then((res) => {
|
||||
if (res.code == 0) {
|
||||
this.userIntegral = res.data.nowIntegral
|
||||
}
|
||||
})
|
||||
},
|
||||
getList() {
|
||||
this.$http.post('/app/apppartyintegralinfo/list', null, {
|
||||
this.$http.post('/app/appintegralmerchandise/listByGirdMember', null, {
|
||||
params: {
|
||||
...this.search,
|
||||
size: 20,
|
||||
current: this.current,
|
||||
partyName: this.partyName
|
||||
queryIntegralType: this.typeIndex
|
||||
},
|
||||
})
|
||||
.then((res) => {
|
||||
@@ -97,12 +101,24 @@ export default {
|
||||
typeClick(index) {
|
||||
this.typeIndex = index
|
||||
},
|
||||
toDetail() {
|
||||
uni.navigateTo({url:'./detail'})
|
||||
toDetail(item) {
|
||||
uni.navigateTo({url:`./detail?id=${item.id}&userIntegral=${this.userIntegral}`})
|
||||
},
|
||||
toMyOrder() {
|
||||
uni.navigateTo({url:`./myOrder`})
|
||||
}
|
||||
},
|
||||
clickStatus() {
|
||||
this.search.status = this.search.status == 2 ? '' : 2
|
||||
this.getListInit()
|
||||
},
|
||||
clickNew() {
|
||||
this.search.newStatus = this.search.newStatus == 1 ? '' : 1
|
||||
this.getListInit()
|
||||
},
|
||||
clickPrice() {
|
||||
this.search.priceStatus = this.search.priceStatus == 1 ? '' : 1
|
||||
this.getListInit()
|
||||
},
|
||||
},
|
||||
onReachBottom() {
|
||||
this.current = this.current + 1
|
||||
|
||||
@@ -3,18 +3,16 @@
|
||||
<div class="goods-img">
|
||||
<u-swiper :list="list" mode="none" img-mode="aspectFit" height="750" bg-color="#fff"></u-swiper>
|
||||
</div>
|
||||
<div class="goods-title">
|
||||
天薇抽纸天然无香纸巾天薇抽纸天然无香纸巾天薇抽纸天然无香纸巾可湿水…
|
||||
</div>
|
||||
<div class="goods-title">{{goodsInfo.merchandiseName}}</div>
|
||||
<div class="goods-point">
|
||||
<h3>10<span>积分</span></h3>
|
||||
<div>库存100</div>
|
||||
<h3>{{goodsInfo.merchandiseIntegral}}<span>积分</span></h3>
|
||||
<div>库存{{goodsInfo.merchandiseNumber}}</div>
|
||||
</div>
|
||||
<div class="goods-btn status-lack">
|
||||
<div class="text">积分余额:438</div>
|
||||
<div class="btn" @click="toOrder()">立即兑换</div>
|
||||
<!-- <div class="btn lack-btn">积分不足</div> -->
|
||||
<!-- <div class="btn lack-btn">缺货</div> -->
|
||||
<div class="text">积分余额:{{userIntegral}}</div>
|
||||
<div class="btn" @click="toOrder()" v-if="goodsInfo.status == 0 && userIntegral >= goodsInfo.merchandiseIntegral">立即兑换</div>
|
||||
<div class="btn lack-btn" v-if="goodsInfo.status == 0 && userIntegral < goodsInfo.merchandiseIntegral">积分不足</div>
|
||||
<div class="btn lack-btn" v-if="goodsInfo.status != 0">缺货</div>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
@@ -26,23 +24,35 @@ export default {
|
||||
name: 'detail',
|
||||
data() {
|
||||
return {
|
||||
list: [
|
||||
{ image: 'https://cdn.uviewui.com/uview/swiper/1.jpg'},
|
||||
{ image: 'https://cdn.uviewui.com/uview/swiper/2.jpg'},
|
||||
{ image: 'https://cdn.uviewui.com/uview/swiper/3.jpg'}
|
||||
],
|
||||
list: [],
|
||||
userIntegral: '',
|
||||
id: '',
|
||||
goodsInfo: {}
|
||||
}
|
||||
},
|
||||
computed: {
|
||||
...mapState(['user']),
|
||||
},
|
||||
onLoad(option) {
|
||||
this.userIntegral = option.userIntegral
|
||||
this.id = option.id
|
||||
this.getDetail()
|
||||
},
|
||||
onShow() {
|
||||
document.title = '商品详情'
|
||||
},
|
||||
methods: {
|
||||
toOrder() {
|
||||
uni.navigateTo({url:'./order'})
|
||||
}
|
||||
uni.navigateTo({url:`./order?userIntegral=${this.userIntegral}&id=${this.id}`})
|
||||
},
|
||||
getDetail() {
|
||||
this.$http.post(`/app/appintegralmerchandise/queryDetailById?id=${this.id}`).then((res) => {
|
||||
if (res.code == 0) {
|
||||
this.goodsInfo = res.data
|
||||
this.list = [{image: res.data.imageUrl}]
|
||||
}
|
||||
})
|
||||
},
|
||||
},
|
||||
}
|
||||
</script>
|
||||
|
||||
@@ -2,14 +2,14 @@
|
||||
<div class="order">
|
||||
<div class="goods">
|
||||
<div class="left">
|
||||
<img src="./components/imgs/check-icon.png" alt="">
|
||||
<img :src="goodsInfo.imageUrl" alt="">
|
||||
</div>
|
||||
<div class="right">
|
||||
<p>天薇抽纸天然无香纸巾天薇抽纸天然无香纸巾天薇抽纸可湿水面巾纸1天薇抽纸天</p>
|
||||
<p>{{goodsInfo.merchandiseName}}</p>
|
||||
<div class="flex">
|
||||
<h3>10<span>积分</span></h3>
|
||||
<h3>{{goodsInfo.merchandiseIntegral}}<span>积分</span></h3>
|
||||
<div class="num">
|
||||
<u-number-box v-model="value" @change="valChange" :min="1" :max="200"></u-number-box>
|
||||
<u-number-box v-model="number" @change="valChange" :min="1" :max="max"></u-number-box>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -22,11 +22,11 @@
|
||||
</div>
|
||||
<div class="flex-item border">
|
||||
<div class="label">积分余额</div>
|
||||
<div class="value color-333">484</div>
|
||||
<div class="value color-333">{{userIntegral}}</div>
|
||||
</div>
|
||||
<div class="flex-item">
|
||||
<div class="label">支付积分</div>
|
||||
<div class="value color-ff6900">-10</div>
|
||||
<div class="value color-ff6900">-{{number*goodsInfo.merchandiseIntegral}}</div>
|
||||
</div>
|
||||
<div class="footer">
|
||||
<div>提交订单</div>
|
||||
@@ -41,20 +41,38 @@ export default {
|
||||
name: 'order',
|
||||
data() {
|
||||
return {
|
||||
value: 1,
|
||||
remark: ''
|
||||
number: 1,
|
||||
remark: '',
|
||||
userIntegral: '',
|
||||
id: '',
|
||||
goodsInfo: {},
|
||||
max: 1
|
||||
}
|
||||
},
|
||||
computed: {
|
||||
...mapState(['user']),
|
||||
},
|
||||
onLoad(option) {
|
||||
this.userIntegral = option.userIntegral
|
||||
this.id = option.id
|
||||
this.getDetail()
|
||||
},
|
||||
onShow() {
|
||||
document.title = '提交订单'
|
||||
},
|
||||
methods: {
|
||||
valChange(e) {
|
||||
console.log('当前值为: ' + e.value)
|
||||
}
|
||||
this.number = e.value
|
||||
|
||||
},
|
||||
getDetail() {
|
||||
this.$http.post(`/app/appintegralmerchandise/queryDetailById?id=${this.id}`).then((res) => {
|
||||
if (res.code == 0) {
|
||||
this.goodsInfo = res.data
|
||||
this.max = parseInt(this.userIntegral/this.goodsInfo.merchandiseIntegral)
|
||||
}
|
||||
})
|
||||
},
|
||||
},
|
||||
}
|
||||
</script>
|
||||
|
||||
@@ -169,7 +169,7 @@ export default {
|
||||
},
|
||||
getList() {
|
||||
var startDate = this.dateList?.length ? this.dateList[0] + ' 00:00:00' : ''
|
||||
var endDate = this.dateList?.length ? this.dateList[1] + ' 00:00:00' : ''
|
||||
var endDate = this.dateList?.length ? this.dateList[1] + ' 23:59:59' : ''
|
||||
this.$http.post('/app/appepidemicpreventioncommunitymanagement/list', null, {
|
||||
params: {
|
||||
size: 10,
|
||||
|
||||
@@ -9,7 +9,7 @@
|
||||
<span class="tips">*</span>身份证号
|
||||
</div>
|
||||
<div class="value">
|
||||
<u-input placeholder="请输入" type="number" input-align="right" height="32" maxlength="18" v-model="form.idNumber" :custom-style="{'font-size': '17px'}" @blur="idNumberChange" />
|
||||
<input placeholder="请输入" type="idcard" input-align="right" height="32" maxlength="18" v-model="form.idNumber" placeholder-style="font-size: 16px;color: #999;" :custom-style="{'font-size': '17px'}" @blur="idNumberChange" />
|
||||
</div>
|
||||
</div>
|
||||
<div class="item solid">
|
||||
@@ -49,7 +49,7 @@
|
||||
<div class="value">
|
||||
<AiAreaPicker v-model="form.startAreaId" all @select="areaSelectStart" :fullName.sync="form.startAreaName" style="color: #666">
|
||||
<span style="margin-left: 4px" v-if="form.startAreaName">{{ form.startAreaName }}</span>
|
||||
<span v-else>请选择</span>
|
||||
<span v-else class="color-999">请选择</span>
|
||||
<u-icon name="arrow-right" color="#999" size="16" style="margin-left: 4px" />
|
||||
</AiAreaPicker>
|
||||
</div>
|
||||
@@ -103,7 +103,7 @@
|
||||
<div class="value">
|
||||
<AiAreaPicker v-model="form.arriveAreaId" :areaId="cropAreaId" @select="areaSelectArrive" :name.sync="form.arriveAreaName" style="color: #666" selectRoot>
|
||||
<span style="margin-left: 4px" v-if="form.arriveAreaName">{{ form.arriveAreaName }}</span>
|
||||
<span v-else>请选择</span>
|
||||
<span v-else class="color-999">请选择</span>
|
||||
<u-icon name="arrow-right" color="#999" size="16" style="margin-left: 4px" />
|
||||
</AiAreaPicker>
|
||||
</div>
|
||||
|
||||
@@ -18,7 +18,7 @@
|
||||
<div class="item-flex">
|
||||
<div class="label">身份证号</div>
|
||||
<div class="value">
|
||||
<u-input v-if="isIdNumberInput" type="number" input-align="right" height="32" maxlength="18" v-model="info.idNumber" :custom-style="{'font-size': '17px'}" />
|
||||
<input v-if="isIdNumberInput" type="idcard" input-align="right" height="32" maxlength="18" v-model="info.idNumber" :custom-style="{'font-size': '17px'}" />
|
||||
<span v-else>{{info.idNumberText}}</span>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -26,7 +26,7 @@
|
||||
<div class="item-flex">
|
||||
<div class="label">身份证号</div>
|
||||
<div class="value">
|
||||
<u-input v-if="isIdNumberInput" type="number" input-align="right" height="32" maxlength="18" v-model="info.idNumber" :custom-style="{'font-size': '17px'}" />
|
||||
<u-input v-if="isIdNumberInput" type="idcard" input-align="right" height="32" maxlength="18" v-model="info.idNumber" :custom-style="{'font-size': '17px'}" />
|
||||
<span v-else>{{info.idNumberText}}</span>
|
||||
</div>
|
||||
</div>
|
||||
@@ -158,7 +158,7 @@
|
||||
<span class="tips">*</span>身份证号
|
||||
</div>
|
||||
<div class="value">
|
||||
<u-input type="number" input-align="right" height="32" maxlength="18" v-model="info.idNumber" :custom-style="{'font-size': '17px'}" />
|
||||
<input input-align="right" height="32" maxlength="18" v-model="form.idNumber" :custom-style="{'font-size': '17px'}" />
|
||||
</div>
|
||||
</div>
|
||||
<div class="item solid">
|
||||
@@ -172,7 +172,7 @@
|
||||
</div>
|
||||
<div class="item solid">
|
||||
<div class="label">
|
||||
<span class="tips">*</span>隔离时间
|
||||
<span class="tips">*</span>管理时间
|
||||
</div>
|
||||
<div class="value" @click="showDateSelect=true">
|
||||
<span class="color-999" v-if="!form.quarantineBeginTime">请选择</span>
|
||||
@@ -182,7 +182,7 @@
|
||||
</div>
|
||||
<div class="item">
|
||||
<div class="label">
|
||||
<span class="tips">*</span>隔离策略
|
||||
<span class="tips">*</span>管理策略
|
||||
</div>
|
||||
<div class="value" @click="dictSelectClick('EP_quarantineStrategy', 'quarantineStrategy')">
|
||||
<span :class="form.quarantineStrategy === '' ? 'color-999' : ''">{{ $dict.getLabel('EP_quarantineStrategy', form.quarantineStrategy) || '请选择'}}</span>
|
||||
@@ -340,14 +340,25 @@ export default {
|
||||
this.getDetail()
|
||||
},
|
||||
submit(status) {
|
||||
if (!this.form.idNumber) {
|
||||
return this.$u.toast('请输入身份证号')
|
||||
}
|
||||
let reg = /^[1-9]\d{5}(18|19|20)\d{2}((0[1-9])|(1[0-2]))(([0-2][1-9])|10|20|30|31)\d{3}[0-9Xx]$/;
|
||||
|
||||
if (this.form.idNumber.length == 18 && !reg.test(this.form.idNumber)) {
|
||||
return this.$u.toast('请输入正确的身份证账号')
|
||||
}
|
||||
if (this.form.idNumber.length == 18 && !reg.test(this.form.idNumber)) {
|
||||
return this.$u.toast('请输入正确的身份证账号')
|
||||
}
|
||||
if(this.form.homeStatus === '') {
|
||||
return this.$u.toast('请选择居家状态')
|
||||
}
|
||||
if(!this.form.quarantineBeginTime) {
|
||||
return this.$u.toast('请选择隔离时间')
|
||||
return this.$u.toast('请选择管理时间')
|
||||
}
|
||||
if(this.form.quarantineStrategy === '' || this.form.quarantineStrategy === null) {
|
||||
return this.$u.toast('请选择隔离策略')
|
||||
return this.$u.toast('请选择管理策略')
|
||||
}
|
||||
if(!this.form.controllerUserName) {
|
||||
return this.$u.toast('请输入管控人姓名')
|
||||
|
||||
@@ -4,11 +4,11 @@
|
||||
<div class="header">
|
||||
<div class="tab-item">
|
||||
<h2 style="color:#2C51CE;">{{totalInfo['登记人数']}}</h2>
|
||||
<p>返乡人员</p>
|
||||
<p>报备人员</p>
|
||||
</div>
|
||||
<div class="tab-item">
|
||||
<h2 style="color:#5AAD6A;">{{totalInfo['今日新增返乡']}}</h2>
|
||||
<p>今日返乡</p>
|
||||
<p>今日报备</p>
|
||||
</div>
|
||||
<div class="tab-item">
|
||||
<h2 style="color:#F5A319;">{{totalInfo['今日风险人数']}}</h2>
|
||||
@@ -20,7 +20,7 @@
|
||||
</div>
|
||||
</div>
|
||||
<div class="tab-select">
|
||||
<div class="item" :class="!tabIndex ? 'active' : ''" @click="tabClick(0)">返乡人员<span></span></div>
|
||||
<div class="item" :class="!tabIndex ? 'active' : ''" @click="tabClick(0)">报备人员<span></span></div>
|
||||
<div class="item" :class="tabIndex ? 'active' : ''" @click="tabClick(1)">风险人员<span></span></div>
|
||||
</div>
|
||||
<div class="search">
|
||||
@@ -82,9 +82,9 @@ export default {
|
||||
showGateSelect: false,
|
||||
gateList: [],
|
||||
statusImgList: [
|
||||
require('./components/img/status0.png'),
|
||||
require('./components/img/status1.png'),
|
||||
require('./components/img/status2.png'),
|
||||
require('./components/img/status0.png'),
|
||||
require('./components/img/status1.png'),
|
||||
require('./components/img/status2.png'),
|
||||
],
|
||||
options: [
|
||||
{
|
||||
@@ -393,7 +393,7 @@ export default {
|
||||
}
|
||||
}
|
||||
}
|
||||
.gateway-name {
|
||||
.gateway-name {
|
||||
max-width: calc(100% - 48px);
|
||||
word-break: break-all;
|
||||
overflow: hidden;
|
||||
|
||||
Reference in New Issue
Block a user