更新
This commit is contained in:
@@ -13,5 +13,12 @@ export default{
|
||||
url: `/oil-mall/mallOrderInfo/get/${id}`,
|
||||
method: 'get',
|
||||
})
|
||||
}
|
||||
},
|
||||
takeOrder(data) {
|
||||
return request({
|
||||
url: `/oil-mall/mallOrderInfo/takeOrder`,
|
||||
method: 'post',
|
||||
data
|
||||
})
|
||||
},
|
||||
}
|
||||
172
packageIntegral/components/mulpicker.vue
Normal file
172
packageIntegral/components/mulpicker.vue
Normal file
@@ -0,0 +1,172 @@
|
||||
<!-- 多列选择器 -->
|
||||
<template>
|
||||
<picker mode="multiSelector" @columnchange="handleColumnChange" @change="pickerChange" :value="multiIndex" :range="multiArray" :range-key="rangekey">
|
||||
<view class="uni-input space-between" hover-class="hover-color">
|
||||
<slot name="before"></slot>
|
||||
<text class="input-content ellipsis" :class="name?'':'color-placeholder'">{{name?name:placeholder}}</text>
|
||||
<slot name="after"></slot>
|
||||
</view>
|
||||
</picker>
|
||||
</template>
|
||||
<script>
|
||||
export default {
|
||||
props: {
|
||||
value: { default: ''}, // 必须要使用value
|
||||
list: {type: Array, default: [] },
|
||||
rangekey: { default: 'name' }, // 对应name取值
|
||||
childkey: { default: 'children' }, // 子集
|
||||
code: { default: 'code' }, // 对应value取值
|
||||
pidkey: { default: 'pid' }, // 对应父id取值
|
||||
placeholder: { default: '请选择' },
|
||||
emitPath: { default: false, type: Boolean }, // 是否子父级关联 ,是的时候返回的是逗号分隔的父子code
|
||||
level: { default: 3, type: Number } // 列数 2或者3
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
multiArray: [[],],
|
||||
multiIndex: [0, 0, 0],
|
||||
name: "",
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
handleColumnChange(e) {
|
||||
|
||||
let columnindex = e.detail.value; // 拖动列索引
|
||||
switch (e.detail.column) {
|
||||
case 0: //拖动第1列
|
||||
|
||||
// 第二级
|
||||
let arr1 = this.multiArray[0];
|
||||
this.multiArray[1] = arr1[columnindex][this.childkey]||[];
|
||||
|
||||
if(this.level === 3) {
|
||||
// 第三级
|
||||
let arr2 = this.multiArray[1];
|
||||
this.multiArray[2] = arr2[0][this.childkey]||[];
|
||||
}
|
||||
|
||||
this.multiIndex.splice(0, 1, columnindex)
|
||||
this.multiIndex.splice(1, 1, 0)
|
||||
this.multiIndex.splice(2, 1, 0)
|
||||
break
|
||||
case 1: //拖动第2列
|
||||
if (this.level === 3) {
|
||||
// 第三级
|
||||
let arr3 = this.multiArray[1];
|
||||
this.multiArray[2] = arr3[columnindex][this.childkey]||[];
|
||||
}
|
||||
|
||||
this.multiIndex.splice(1, 1, columnindex)
|
||||
this.multiIndex.splice(2, 1, 0)
|
||||
break
|
||||
}
|
||||
|
||||
},
|
||||
//
|
||||
pickerChange(e) {
|
||||
let multiIndex = e.detail.value;
|
||||
if(this.emitPath) {
|
||||
let codeArr = [], nameArr = [];
|
||||
for(let i = 0; i < multiIndex.length; i++ ) {
|
||||
if(this.multiArray[i] && this.multiArray[i][multiIndex[i]]) {
|
||||
codeArr.push(this.multiArray[i][multiIndex[i]][this.code]);
|
||||
nameArr.push(this.multiArray[i][multiIndex[i]][this.rangekey]);
|
||||
}
|
||||
}
|
||||
let code = codeArr.join(',');
|
||||
this.name = nameArr.join('/');
|
||||
console.log('code1',code);
|
||||
this.$emit('input', code)
|
||||
}else {
|
||||
|
||||
let curArr = this.multiArray[2], code='';
|
||||
if(curArr && curArr.length) {
|
||||
code = curArr[multiIndex[2]][this.code];
|
||||
this.name = curArr[multiIndex[2]][this.rangekey];
|
||||
}else {
|
||||
curArr = this.multiArray[1]
|
||||
code = curArr[multiIndex[1]][this.code];
|
||||
this.name = curArr[multiIndex[1]][this.rangekey];
|
||||
}
|
||||
|
||||
console.log('code2',code);
|
||||
this.$emit('input', code)
|
||||
}
|
||||
},
|
||||
// 初始化级联数据
|
||||
dataInit() {
|
||||
// 第一级
|
||||
this.multiArray[0] = this.list;
|
||||
// 第二级
|
||||
let arr1 = this.multiArray[0];
|
||||
this.multiArray.push(arr1[this.multiIndex[0]][this.childkey]||[]);
|
||||
if(this.level === 3) {
|
||||
// 第三级
|
||||
let arr2 = this.multiArray[1];
|
||||
this.multiArray.push(arr2[this.multiIndex[1]][this.childkey]||[]);
|
||||
|
||||
}
|
||||
},
|
||||
curDataFind (data, code) {
|
||||
let result;
|
||||
if (!data) {
|
||||
data = this.list;
|
||||
}
|
||||
for (var i = 0; i < data.length; i++) {
|
||||
let item = data[i]
|
||||
if (result) {
|
||||
return result;
|
||||
}
|
||||
if (Number(item[this.code]) === code) {
|
||||
result = item;
|
||||
break;
|
||||
} else if (item[this.childkey] && item[this.childkey].length > 0) {
|
||||
result = this.curDataFind(item[this.childkey], code);
|
||||
}
|
||||
}
|
||||
return result;
|
||||
},
|
||||
initName() {
|
||||
if(this.list.length && this.value) {
|
||||
if(this.emitPath) {
|
||||
let nameArr = [], codeArr = this.value.split(',');
|
||||
for(let i = 0; i < codeArr.length; i++ ) {
|
||||
codeArr[i] = codeArr[i] - 0;
|
||||
}
|
||||
for(let i = 0; i < codeArr.length; i++ ) {
|
||||
let item = this.curDataFind(this.list, codeArr[i]);
|
||||
nameArr.push(item[this.rangekey]);
|
||||
}
|
||||
this.name = nameArr.join('/');
|
||||
} else {
|
||||
let item = this.curDataFind(this.list, this.value);
|
||||
this.name = item[this.rangekey];
|
||||
}
|
||||
}else {
|
||||
this.name = '';
|
||||
}
|
||||
}
|
||||
},
|
||||
watch: {
|
||||
list: {
|
||||
immediate: true,
|
||||
handler(val) {
|
||||
console.log(val)
|
||||
this.dataInit();
|
||||
this.initName();
|
||||
}
|
||||
},
|
||||
value: {
|
||||
// immediate: true,
|
||||
handler(val) {
|
||||
console.log(val)
|
||||
this.initName();
|
||||
}
|
||||
},
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
|
||||
</style>
|
||||
@@ -23,13 +23,12 @@
|
||||
<view class="detial">
|
||||
<view>订单编号: <text>{{info.orderCode}}</text></view>
|
||||
<view>下单时间: <text>{{info.createTime}}</text></view>
|
||||
<view>站点电话: <text>18879008956</text></view>
|
||||
<view>支付方式: <text>积分</text></view>
|
||||
<view>商品金额: <text>¥{{info.marketPrice}}</text></view>
|
||||
<view>支付积分: <text>{{info.integral}}</text></view>
|
||||
</view>
|
||||
<view class="footer">
|
||||
<view class="button" @click="determine">确定提货</view>
|
||||
<view class="button" v-if="info.orderStatus=='1'" @click="determine">确定提货</view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
@@ -103,8 +102,23 @@
|
||||
}
|
||||
})
|
||||
},
|
||||
confirm() {
|
||||
this.controlWindows.code = false
|
||||
submit(){
|
||||
|
||||
let data = {}
|
||||
data.id = this.dataList[0].orderId
|
||||
data.takeCode = this.dataList[0].takeCode
|
||||
serve.takeOrder(data).then(res => {
|
||||
if (res.code === 20000) {
|
||||
uni.showToast({
|
||||
title: res.msg,
|
||||
icon: 'none'
|
||||
});
|
||||
this.$refs.popup.close();
|
||||
this.get(options.orderId)
|
||||
|
||||
}
|
||||
})
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -6,8 +6,8 @@
|
||||
</cu-custom>
|
||||
|
||||
<view class="search">
|
||||
<uni-easyinput prefixIcon="search" borderColor="#DCDFE6" v-model="paramter.customerphone" placeholder="请输入手机号后四位"
|
||||
@confirm="search" maxlength="4" />
|
||||
<uni-easyinput prefixIcon="search" borderColor="#DCDFE6" v-model="paramter.params.customerPhone" placeholder="请输入手机号后四位"
|
||||
@confirm="search" maxlength="4" @clear="search" />
|
||||
</view>
|
||||
|
||||
<scroll-view v-if="dataList.length" class="list" :scroll-y="true" @scrolltolower="lower">
|
||||
@@ -49,7 +49,7 @@
|
||||
currentPage: 1,
|
||||
pagesize: 20,
|
||||
params: {
|
||||
customerphone: ''
|
||||
customerPhone: ''
|
||||
},
|
||||
},
|
||||
dataList: [],
|
||||
@@ -109,7 +109,7 @@
|
||||
getByPageCloudMini() {
|
||||
serve.getByPageCloudMini(this.paramter).then(res => {
|
||||
if (res.code === 20000) {
|
||||
if (!res.data.list.length) {
|
||||
if (!res.data.list.length && this.paramter.currentPage != 1) {
|
||||
uni.showToast({
|
||||
title: '没有更多订单啦~',
|
||||
icon: 'none'
|
||||
|
||||
281
packageIntegral/productAddition/index.vue
Normal file
281
packageIntegral/productAddition/index.vue
Normal file
@@ -0,0 +1,281 @@
|
||||
<template>
|
||||
<view class="container">
|
||||
<cu-custom class="main-totextbar bg-main-oil" :isBack="true" bgColor="bg-main-oil">
|
||||
<block slot="backText">返回</block>
|
||||
<block slot="content">新增商品</block>
|
||||
</cu-custom>
|
||||
<view id="chooseType" :class="currentBoxId == 'chooseType' ? 'show' : 'hidden'">
|
||||
<uni-forms ref="productForm" :modelValue="productDate" label-width="200rpx">
|
||||
<uni-forms-item label="商品分类:" name="name">
|
||||
<mulpicker
|
||||
v-model="productDate.demandRegion"
|
||||
:list="productList"
|
||||
rangekey="name"
|
||||
code="id"
|
||||
pidkey="pid"
|
||||
childkey="city"
|
||||
:emitPath="true"
|
||||
:level="2"
|
||||
:placeholder="'选择商品分类'"
|
||||
/>
|
||||
<uni-icons color="#666666" type="right" size="22" style="position: absolute;right: 0;top: 10rpx;"></uni-icons>
|
||||
</uni-forms-item>
|
||||
<uni-forms-item label="商品名称:" name="age">
|
||||
<input type="text" v-model="productDate.age" placeholder="请输入" />
|
||||
</uni-forms-item>
|
||||
<uni-forms-item label="关键词:" name="age">
|
||||
<input type="text" v-model="productDate.age" placeholder="请输入" />
|
||||
</uni-forms-item>
|
||||
<uni-forms-item label="商品品牌:" name="age">
|
||||
<input type="text" v-model="productDate.age" placeholder="请输入" />
|
||||
</uni-forms-item>
|
||||
<uni-forms-item label="商品售价:" name="age">
|
||||
<input type="text" v-model="productDate.age" placeholder="请输入" />
|
||||
</uni-forms-item>
|
||||
<uni-forms-item label="商品上架:" name="age">
|
||||
<switch color="#FE0606" checked style="transform:scale(0.7)" />
|
||||
</uni-forms-item>
|
||||
<uni-forms-item label="商品推荐:" name="age">
|
||||
<view class='checkbox-con'>
|
||||
<radio-group @change="checkboxChange">
|
||||
<label :class="item.checked?'checkbox checked':'checkbox'" @click="checkbox(index)" v-for="(item, index) in radioItem" :key="item.value">
|
||||
<checkbox :value="item.value" :checked="item.checked"/>{{item.name}}
|
||||
</label>
|
||||
</radio-group>
|
||||
</view>
|
||||
</uni-forms-item>
|
||||
</uni-forms>
|
||||
<view class="buttons">
|
||||
<view @click="closed">取消</view>
|
||||
<view id="next" @click="changeBox">下一步</view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
|
||||
<view id="instruction" :class="currentBoxId == 'instruction' ? 'show' : 'hidden'">
|
||||
<productAddStep2 />
|
||||
<view class="buttons">
|
||||
<view id="previous" @click="changeBox">上一步</view>
|
||||
<view @click="addCompleted">完成</view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
|
||||
|
||||
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import serve from '@/api/packageIntegral/orderList.js'
|
||||
import mulpicker from '@/packageIntegral/components/mulpicker.vue'
|
||||
import productAddStep2 from '@/packageIntegral/productAddition/productAddStep2.vue'
|
||||
export default {
|
||||
components: {
|
||||
mulpicker,
|
||||
productAddStep2
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
currentBoxId: 'instruction', //当前显示的view的id
|
||||
isBoxShow: false,
|
||||
productDate:{},
|
||||
productList:[{
|
||||
"name": "北京市",
|
||||
'id':'0',
|
||||
"city": [{
|
||||
'name':"东城区",
|
||||
'id':'1',
|
||||
},{
|
||||
'name':"西城区",
|
||||
'id':'2',
|
||||
},{
|
||||
'name':"崇文区",
|
||||
'id':'3',
|
||||
},{
|
||||
'name':"宣武区",
|
||||
'id':'4',
|
||||
},{
|
||||
'name':"朝阳区",
|
||||
'id':'5',
|
||||
}
|
||||
]
|
||||
}],
|
||||
radioItem:[{
|
||||
name: '新品',
|
||||
checked: true
|
||||
}, {
|
||||
name: '推荐',
|
||||
checked: false
|
||||
}]
|
||||
}
|
||||
},
|
||||
|
||||
onLoad(options) {
|
||||
// this.get(options.orderId)
|
||||
},
|
||||
methods: {
|
||||
checkbox (e) {
|
||||
console.log(e)
|
||||
var index = e;//获取当前点击的下标
|
||||
var checkboxArr = this.radioItem;//选项集合
|
||||
if (checkboxArr[index].checked) return;//如果点击的当前已选中则返回
|
||||
checkboxArr.forEach(item => {
|
||||
item.checked = false
|
||||
})
|
||||
checkboxArr[index].checked = true;//改变当前选中的checked值
|
||||
// this.setData({
|
||||
// checkboxArr: checkboxArr
|
||||
// });
|
||||
|
||||
},
|
||||
checkboxChange (e) {
|
||||
var checkValue = e.detail.value;
|
||||
// this.setData({
|
||||
// checkValue: checkValue
|
||||
// });
|
||||
},
|
||||
changeBox(e){
|
||||
let currentFlag = e.currentTarget.id;
|
||||
switch(currentFlag){
|
||||
case 'next':
|
||||
this.currentBoxId = 'instruction'
|
||||
break;
|
||||
case 'previous':
|
||||
this.currentBoxId = 'chooseType'
|
||||
break;
|
||||
default:
|
||||
this.currentBoxId = 'viewInstruction'
|
||||
break;
|
||||
}
|
||||
},
|
||||
picker2(e){
|
||||
console.log(e.detail.value)
|
||||
this.productDate.value = e.detail.value
|
||||
},
|
||||
closed(){
|
||||
uni.navigateTo({
|
||||
url: '/pages/index/index'
|
||||
})
|
||||
},
|
||||
addCompleted(){
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
|
||||
.fadeBox{
|
||||
width: 100%;
|
||||
margin-bottom: 20rpx;
|
||||
}
|
||||
#chooseType{
|
||||
padding: 30rpx;
|
||||
|
||||
mulpicker{
|
||||
height: 72rpx;
|
||||
line-height: 72rpx;
|
||||
}
|
||||
/deep/ .uni-forms{
|
||||
width: 100%;
|
||||
}
|
||||
/deep/ .uni-forms-item{
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
/deep/ .uni-forms-item__label{
|
||||
color: #333 !important;
|
||||
font-size: 30rpx;
|
||||
font-weight: 700;
|
||||
}
|
||||
/deep/ .uni-forms-item__content{
|
||||
width: 100%;
|
||||
input{
|
||||
height: 72rpx;
|
||||
line-height: 72rpx;
|
||||
}
|
||||
}
|
||||
|
||||
switch{
|
||||
margin-top: 9rpx;
|
||||
}
|
||||
switch::before{
|
||||
content: '';
|
||||
}
|
||||
switch::after{
|
||||
content: '';
|
||||
}
|
||||
}
|
||||
.checkbox-con{
|
||||
margin-top: 40rpx;
|
||||
text-align: center;
|
||||
position: relative;
|
||||
}
|
||||
.checkbox{
|
||||
width: 180rpx;
|
||||
height: 76rpx;
|
||||
line-height: 76rpx;
|
||||
font-size: 30rpx;
|
||||
color: #666666;
|
||||
border: 1rpx solid #B6B6B6;
|
||||
border-radius: 5rpx;
|
||||
display: inline-block;
|
||||
margin: 0 10rpx 20rpx 0;
|
||||
position: absolute;
|
||||
top: 50rpx;
|
||||
&:nth-of-type(1){
|
||||
left: -190rpx;
|
||||
}
|
||||
&:nth-of-type(2){
|
||||
left: 50rpx;
|
||||
}
|
||||
}
|
||||
|
||||
.checked{
|
||||
color: #FFFFFF;
|
||||
background: #FE0606;
|
||||
border: 1rpx solid #FE0606;
|
||||
}
|
||||
.checkbox checkbox{
|
||||
display: none
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
.buttons {
|
||||
width: 100%;
|
||||
display: flex;
|
||||
justify-content: space-evenly;
|
||||
margin-top: 180rpx;
|
||||
|
||||
>view {
|
||||
width: 250rpx;
|
||||
height: 76rpx;
|
||||
text-align: center;
|
||||
line-height: 76rpx;
|
||||
border-radius: 10rpx;
|
||||
font-size: 28rpx;
|
||||
|
||||
&:nth-of-type(1) {
|
||||
background: #FFFFFF;
|
||||
border: 1rpx solid #B6B6B6;
|
||||
color: #333;
|
||||
}
|
||||
|
||||
&:nth-of-type(2) {
|
||||
background: #FE0505;
|
||||
color: #fff;
|
||||
}
|
||||
}
|
||||
}
|
||||
.show{
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
}
|
||||
.hidden{
|
||||
display: none;
|
||||
}
|
||||
</style>
|
||||
55
packageIntegral/productAddition/productAddStep2.vue
Normal file
55
packageIntegral/productAddition/productAddStep2.vue
Normal file
@@ -0,0 +1,55 @@
|
||||
<template>
|
||||
<view class="container">
|
||||
|
||||
<view class="body">
|
||||
<view class="bodyContent">
|
||||
<view class="bodyLabel">属性类型:</view>
|
||||
<view class="bodyItem">
|
||||
<uni-data-select
|
||||
v-model="value"
|
||||
:localdata="range"
|
||||
@change="change"
|
||||
></uni-data-select>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
export default{
|
||||
data(){
|
||||
return{
|
||||
value: 1,
|
||||
range: [
|
||||
{ value: 0, text: "篮球" },
|
||||
{ value: 1, text: "足球" },
|
||||
{ value: 2, text: "游泳" },
|
||||
],
|
||||
}
|
||||
},
|
||||
methods:{
|
||||
change(e) {
|
||||
console.log("e:", e);
|
||||
},
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.container{
|
||||
.body{
|
||||
padding: 30rpx;
|
||||
}
|
||||
}
|
||||
.bodyContent{
|
||||
position: relative;
|
||||
// padding-left:150rpx;
|
||||
.bodyLabel{
|
||||
display: inline-block;
|
||||
width: 150rpx;
|
||||
}
|
||||
}
|
||||
|
||||
</style>
|
||||
@@ -27,7 +27,7 @@
|
||||
<view>¥{{item.marketPrice}} X{{item.orderNum}}</view>
|
||||
<view>库存:{{item.orderNum}}</view>
|
||||
</view>
|
||||
<view class="examine" :style="{background:statusEnum[1].color}" >{{statusEnum[1].value}}</view>
|
||||
<view class="examine" @click="examineDetail" :style="{background:statusEnum[1].color}" >{{statusEnum[1].value}}</view>
|
||||
<view class="footer">
|
||||
<view class="button" @click="orderDelete">删除</view>
|
||||
<view class="button">编辑</view>
|
||||
@@ -41,6 +41,30 @@
|
||||
<view>还没有订单哦~</view>
|
||||
</view>
|
||||
|
||||
<uni-popup ref="detail">
|
||||
<view class="determine-detail">
|
||||
<view class="title">审核详情</view>
|
||||
<uni-icons @click="$refs.detail.close()" color="#666666" type="closeempty" size="28"></uni-icons>
|
||||
<view class="item" v-for="(item,index) in examineDetailList" :key="index">
|
||||
<view>
|
||||
<view class="header">审核时间</view>
|
||||
<view>{{item.createTime}}</view>
|
||||
</view>
|
||||
<view>
|
||||
<view class="header">审核结果</view>
|
||||
<view>{{item.status}}</view>
|
||||
</view>
|
||||
<view>
|
||||
<view class="header">反馈详情</view>
|
||||
<view>{{item.dateil}}</view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="buttons">
|
||||
<view @click="$refs.detail.close()">关闭</view>
|
||||
</view>
|
||||
</view>
|
||||
</uni-popup>
|
||||
|
||||
<uni-popup ref="delete">
|
||||
<view class="determine-frame">
|
||||
<view class="title">是否删除该商品?</view>
|
||||
@@ -129,7 +153,24 @@
|
||||
color: '#FCB438',
|
||||
value: "已审核"
|
||||
},
|
||||
},
|
||||
examineDetailList:[
|
||||
{
|
||||
createTime:'2023.11.22',
|
||||
status:'1',
|
||||
dateil:'未审核'
|
||||
},
|
||||
{
|
||||
createTime:'2023.11.23',
|
||||
status:'2',
|
||||
dateil:'已审核'
|
||||
},
|
||||
{
|
||||
createTime:'2023.11.24',
|
||||
status:'已驳回',
|
||||
dateil:'图片不清晰,请重新上传图片'
|
||||
}
|
||||
]
|
||||
}
|
||||
},
|
||||
|
||||
@@ -181,6 +222,9 @@
|
||||
this.paramter.currentPage += 1
|
||||
this.getByPageCloudMini()
|
||||
},
|
||||
examineDetail(){
|
||||
this.$refs.detail.open('center')
|
||||
},
|
||||
orderDelete(){
|
||||
this.$refs.delete.open('center')
|
||||
},
|
||||
@@ -369,6 +413,60 @@
|
||||
}
|
||||
}
|
||||
|
||||
.determine-detail {
|
||||
padding: 30rpx 0;
|
||||
width: 681rpx;
|
||||
background: #FFFFFF;
|
||||
border-radius: 15rpx;
|
||||
position: relative;
|
||||
|
||||
>.title {
|
||||
text-align: center;
|
||||
font-size: 38rpx;
|
||||
color: #000;
|
||||
margin-bottom: 20rpx;
|
||||
}
|
||||
>uni-icons{
|
||||
position: absolute;
|
||||
top: 30rpx;
|
||||
right: 30rpx;
|
||||
}
|
||||
>.item{
|
||||
display: flex;
|
||||
justify-content: space-evenly;
|
||||
overflow-y: hidden;
|
||||
font-size: 22rpx;
|
||||
color: #666;
|
||||
padding: 10rpx;
|
||||
view{
|
||||
width: 200rpx;
|
||||
line-height: 46rpx;
|
||||
}
|
||||
.header{
|
||||
font-size: 32rpx;
|
||||
color: #000;
|
||||
}
|
||||
}
|
||||
|
||||
>.buttons {
|
||||
|
||||
display: flex;
|
||||
justify-content: space-evenly;
|
||||
margin-top: 50rpx;
|
||||
|
||||
>view {
|
||||
width: 550rpx;
|
||||
height: 76rpx;
|
||||
text-align: center;
|
||||
line-height: 76rpx;
|
||||
border-radius: 10rpx;
|
||||
font-size: 28rpx;
|
||||
background: #FE0505;
|
||||
color: #fff;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.determine-frame {
|
||||
padding-top: 85rpx;
|
||||
width: 681rpx;
|
||||
|
||||
@@ -5,21 +5,21 @@
|
||||
<block slot="content">订单提货</block>
|
||||
</cu-custom>
|
||||
|
||||
<view class="code">提货码: 1899</view>
|
||||
<view class="code">提货码: {{code}}</view>
|
||||
|
||||
<scroll-view v-if="dataList.length" class="list" :scroll-y="true" @scrolltolower="lower">
|
||||
<view class="item" v-for="item,index in dataList" :key="index">
|
||||
<view class="header">用户手机:18879008955<text>待提货</text></view>
|
||||
<view class="header">用户手机:{{item.customerPhone}}<text>{{item.statusMerge}}</text></view>
|
||||
<view class="introduce">
|
||||
<image></image>
|
||||
<view>康师傅方便面 经典红烧牛肉面*5+番茄鸡蛋牛肉*1</view>
|
||||
<view>规格:默认</view>
|
||||
<view>¥120.61 X1</view>
|
||||
<view>共1件商品已支付积分:20000</view>
|
||||
<image :src="item.oderDetailImg"></image>
|
||||
<view>{{item.productName}}</view>
|
||||
<view>规格:{{handler(item.attributeJson)}}</view>
|
||||
<view>¥{{item.marketPrice}} X{{item.orderNum}}</view>
|
||||
<view>共{{item.orderNum}}件商品已支付积分:{{item.payIntegral}}</view>
|
||||
</view>
|
||||
<view class="footer">
|
||||
提货码:1899
|
||||
<view class="button" @click="determine">确定提货</view>
|
||||
提货码:{{item.takeCode}}
|
||||
<view class="button" v-if="item.statusMerge=='待核销'" @click="determine">确定提货</view>
|
||||
</view>
|
||||
</view>
|
||||
</scroll-view>
|
||||
@@ -48,7 +48,7 @@
|
||||
<view class="title">是否立即提货</view>
|
||||
<view class="buttons">
|
||||
<view @click="$refs.popup.close()">取消</view>
|
||||
<view>确认</view>
|
||||
<view @click="submitFirm">确认</view>
|
||||
</view>
|
||||
</view>
|
||||
</uni-popup>
|
||||
@@ -56,7 +56,7 @@
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import serve from '@/api/packageBill/push.js'
|
||||
import serve from '@/api/packageIntegral/orderList.js'
|
||||
|
||||
export default {
|
||||
options: {
|
||||
@@ -66,9 +66,17 @@
|
||||
return {
|
||||
code: '',
|
||||
controlWindows: {
|
||||
code: false
|
||||
code: true
|
||||
},
|
||||
dataList: [1]
|
||||
paramter: {
|
||||
currentPage: 1,
|
||||
pagesize: 20,
|
||||
params: {
|
||||
takeCode: '',
|
||||
customerPhone:''
|
||||
},
|
||||
},
|
||||
dataList: []
|
||||
}
|
||||
},
|
||||
|
||||
@@ -78,9 +86,58 @@
|
||||
determine() {
|
||||
this.$refs.popup.open('center')
|
||||
},
|
||||
|
||||
handler(json) {
|
||||
json = json.replace(/'/g, '"')
|
||||
let res = JSON.parse(json)
|
||||
let values = Object.values(res)
|
||||
let text =values.reduce((prev,item,index) => {
|
||||
let _text = `${index == 0 ? '' :','}${item}`
|
||||
return prev += _text
|
||||
},'')
|
||||
return text
|
||||
},
|
||||
confirm() {
|
||||
this.controlWindows.code = false
|
||||
this.paramter.params.takeCode = this.code
|
||||
this.paramter.params.customerPhone = this.code
|
||||
this.getByPageCloudMini()
|
||||
},
|
||||
getByPageCloudMini() {
|
||||
serve.getByPageCloudMini(this.paramter).then(res => {
|
||||
if (res.code === 20000) {
|
||||
if (!res.data.list.length) {
|
||||
uni.showToast({
|
||||
title: '没有更多订单啦~',
|
||||
icon: 'none'
|
||||
})
|
||||
return
|
||||
}
|
||||
if (this.paramter.currentPage == 1) {
|
||||
this.dataList = []
|
||||
}
|
||||
this.dataList = this.dataList.concat(res.data.list)
|
||||
// console.log(this.dataList)
|
||||
}
|
||||
})
|
||||
},
|
||||
submitFirm(){
|
||||
|
||||
let data = {}
|
||||
data.id = this.dataList[0].orderId
|
||||
data.takeCode = this.dataList[0].takeCode
|
||||
serve.takeOrder(data).then(res => {
|
||||
if (res.code === 20000) {
|
||||
uni.showToast({
|
||||
title: res.msg,
|
||||
icon: 'none'
|
||||
});
|
||||
this.$refs.popup.close();
|
||||
uni.navigateTo({
|
||||
url: '/packageIntegral/orderDetails/index'
|
||||
})
|
||||
}
|
||||
})
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -100,6 +100,9 @@
|
||||
},{
|
||||
"path": "productList/index",
|
||||
"style": {}
|
||||
},{
|
||||
"path": "productAddition/index",
|
||||
"style": {}
|
||||
}]
|
||||
},
|
||||
{
|
||||
|
||||
@@ -439,6 +439,12 @@
|
||||
obj.color = 'blue',
|
||||
obj.badge = 0
|
||||
obj.name = list.roleName
|
||||
}else if (list.roleName == '新增商品') {
|
||||
obj.cuIcon = 'punch',
|
||||
obj.path = '/packageIntegral/productAddition/index',
|
||||
obj.color = 'blue',
|
||||
obj.badge = 0
|
||||
obj.name = list.roleName
|
||||
}
|
||||
return obj
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user