分销审批;bug修复
This commit is contained in:
parent
2919a528a3
commit
577c625783
|
|
@ -12,7 +12,7 @@ export default {
|
||||||
})
|
})
|
||||||
// request 触发前拼接 url
|
// request 触发前拼接 url
|
||||||
args.url = 'https://www.opsoul.com:8881' + args.url;
|
args.url = 'https://www.opsoul.com:8881' + args.url;
|
||||||
// args.url = 'http://92.168.2.12:80' + args.url;
|
// args.url = 'http://192.168.2.12:80' + args.url;
|
||||||
// args.url = 'http://127.0.0.1:80' + args.url;
|
// args.url = 'http://127.0.0.1:80' + args.url;
|
||||||
if (args.data && Object.prototype && Object.prototype.toString.call(args.data) === '[object Object]') {
|
if (args.data && Object.prototype && Object.prototype.toString.call(args.data) === '[object Object]') {
|
||||||
args.data.deptId = globalData.deptId;
|
args.data.deptId = globalData.deptId;
|
||||||
|
|
@ -689,5 +689,21 @@ export default {
|
||||||
data: params
|
data: params
|
||||||
})
|
})
|
||||||
return res[1].data;
|
return res[1].data;
|
||||||
|
},
|
||||||
|
async getMembersWaitingApproval(params = {}) {
|
||||||
|
let res = await uni.request({
|
||||||
|
url: '/customer/place/app/myCustomerPlace',
|
||||||
|
method: 'POST',
|
||||||
|
data: params
|
||||||
|
})
|
||||||
|
return res[1].data;
|
||||||
|
},
|
||||||
|
async editCustomerPlace(params = {}) {
|
||||||
|
let res = await uni.request({
|
||||||
|
url: '/customer/place/app/edit',
|
||||||
|
method: 'POST',
|
||||||
|
data: params
|
||||||
|
})
|
||||||
|
return res[1].data;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -9,14 +9,14 @@
|
||||||
<view class="cu-item shadow">
|
<view class="cu-item shadow">
|
||||||
<view v-if="item.imgs && item.imgs.length > 2" class="flex justify-between align-center multi-pic-container">
|
<view v-if="item.imgs && item.imgs.length > 2" class="flex justify-between align-center multi-pic-container">
|
||||||
<view class="left-view"><image class="radius-img" :src="item.imgs[0]" mode="aspectFill"></image></view>
|
<view class="left-view"><image class="radius-img" :src="item.imgs[0]" mode="aspectFill"></image></view>
|
||||||
<view class="flex-column-between align-center right-view">
|
<view class="flex-column-between align-center right-half-view">
|
||||||
<image class="radius-img" :src="item.imgs[1]" mode="aspectFill"></image>
|
<image class="radius-img" :src="item.imgs[1]" mode="aspectFill"></image>
|
||||||
<image class="radius-img" :src="item.imgs[2]" mode="aspectFill"></image>
|
<image class="radius-img" :src="item.imgs[2]" mode="aspectFill"></image>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view v-else-if="item.imgs && item.imgs.length > 1" class="flex justify-between align-center multi-pic-container">
|
<view v-else-if="item.imgs && item.imgs.length > 1" class="flex justify-between align-center multi-pic-container">
|
||||||
<view class="left-view"><image class="radius-img" :src="item.imgs[0]" mode="aspectFill"></image></view>
|
<view class="left-view"><image class="radius-img" :src="item.imgs[0]" mode="aspectFill"></image></view>
|
||||||
<view class="left-view"><image class="radius-img" :src="item.imgs[1]" mode="aspectFill"></image></view>
|
<view class="right-view"><image class="radius-img" :src="item.imgs[1]" mode="aspectFill"></image></view>
|
||||||
</view>
|
</view>
|
||||||
<view v-else-if="item.imgs && item.imgs.length" class="flex justify-between align-center multi-pic-container">
|
<view v-else-if="item.imgs && item.imgs.length" class="flex justify-between align-center multi-pic-container">
|
||||||
<view class="whole-view"><image class="radius-img" :src="item.imgs[0]" mode="aspectFill"></image></view>
|
<view class="whole-view"><image class="radius-img" :src="item.imgs[0]" mode="aspectFill"></image></view>
|
||||||
|
|
@ -74,6 +74,7 @@
|
||||||
.multi-pic-container > .whole-view {
|
.multi-pic-container > .whole-view {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
height: 100%;
|
height: 100%;
|
||||||
|
padding: 0 30rpx;
|
||||||
}
|
}
|
||||||
|
|
||||||
.multi-pic-container > .whole-view > image {
|
.multi-pic-container > .whole-view > image {
|
||||||
|
|
@ -92,6 +93,17 @@
|
||||||
width: 100%;
|
width: 100%;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.multi-pic-container > .right-half-view {
|
||||||
|
width: calc(50% - 7rpx);
|
||||||
|
padding-right: 30rpx;
|
||||||
|
height: 100%;
|
||||||
|
}
|
||||||
|
|
||||||
|
.multi-pic-container > .right-half-view > image {
|
||||||
|
height: calc(50% - 7rpx);
|
||||||
|
width: 100%;
|
||||||
|
}
|
||||||
|
|
||||||
.multi-pic-container > .right-view {
|
.multi-pic-container > .right-view {
|
||||||
width: calc(50% - 7rpx);
|
width: calc(50% - 7rpx);
|
||||||
padding-right: 30rpx;
|
padding-right: 30rpx;
|
||||||
|
|
@ -99,7 +111,7 @@
|
||||||
}
|
}
|
||||||
|
|
||||||
.multi-pic-container > .right-view > image {
|
.multi-pic-container > .right-view > image {
|
||||||
height: calc(50% - 7rpx);
|
height: 100%;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -15,14 +15,14 @@
|
||||||
</view>
|
</view>
|
||||||
</scroll-view>
|
</scroll-view>
|
||||||
<view class="VerticalBox" :style="'height:calc(' + containerHeight + ')'">
|
<view class="VerticalBox" :style="'height:calc(' + containerHeight + ')'">
|
||||||
<scroll-view class="VerticalNav nav">
|
<scroll-view class="VerticalNav nav" :scroll-y="true">
|
||||||
<view class="cu-item" :class="index==tabCur?'text-main-color cur':''" v-for="(item,index) in list"
|
<view class="cu-item" :class="index==tabCur?'text-main-color cur':''" v-for="(item,index) in list"
|
||||||
:key="index" @tap="tabSelect" :data-index="index" :data-id="item.goodsCategoryId"
|
:key="index" @tap="tabSelect" :data-index="index" :data-id="item.goodsCategoryId"
|
||||||
:data-main-cur="item.child && item.child.length > 0 ? item.child[0].goodsCategoryId : -1">
|
:data-main-cur="item.child && item.child.length > 0 ? item.child[0].goodsCategoryId : -1">
|
||||||
{{item.goodsCategoryName}}
|
{{item.goodsCategoryName}}
|
||||||
</view>
|
</view>
|
||||||
</scroll-view>
|
</scroll-view>
|
||||||
<scroll-view class="VerticalMain">
|
<scroll-view class="VerticalMain" :scroll-y="true" :style="'height:calc(' + containerHeight + ')'">
|
||||||
<view class="cu-bar bg-white" @click="chooseNavItem(list[tabCur])" v-if="list[tabCur].child && list[tabCur].child.length">
|
<view class="cu-bar bg-white" @click="chooseNavItem(list[tabCur])" v-if="list[tabCur].child && list[tabCur].child.length">
|
||||||
<view class="action">
|
<view class="action">
|
||||||
<!-- {{list[tabCur].goodsCategoryName}} -->全部
|
<!-- {{list[tabCur].goodsCategoryName}} -->全部
|
||||||
|
|
|
||||||
|
|
@ -54,6 +54,8 @@
|
||||||
"path": "b-account-bind"
|
"path": "b-account-bind"
|
||||||
}, {
|
}, {
|
||||||
"path": "my-money-bag"
|
"path": "my-money-bag"
|
||||||
|
}, {
|
||||||
|
"path": "member-approval"
|
||||||
}]
|
}]
|
||||||
}, {
|
}, {
|
||||||
"root":"pages/publish/",
|
"root":"pages/publish/",
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,117 @@
|
||||||
|
<template>
|
||||||
|
<view>
|
||||||
|
<!-- 顶部操作条 -->
|
||||||
|
<cu-custom :bgColor="'bg-main-color'" :isBack="true">
|
||||||
|
<block slot="backText">返回</block>
|
||||||
|
<block slot="content">审批列表</block>
|
||||||
|
</cu-custom>
|
||||||
|
<!-- 团队成员信息 -->
|
||||||
|
<view class="margin-top-sm margin-lr-sm padding bg-white name-card shadow-warp"
|
||||||
|
v-for="(member, index) in members">
|
||||||
|
<!-- 个人名片 -->
|
||||||
|
<view class="flex justify-start">
|
||||||
|
<view class="cu-avatar round"
|
||||||
|
:style="'background-image:url(' + member.customerLogoUrl + '); width: 130rpx; height: 130rpx;'">
|
||||||
|
</view>
|
||||||
|
<view class="margin-left-sm flex-column-around">
|
||||||
|
<view class="text-black text-xl">{{member.name}}</view>
|
||||||
|
<view class="">
|
||||||
|
<text class="margin-right-xs">角色:申请加入</text>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
<!-- 实名及公告图标 -->
|
||||||
|
<view class="flex justify-end oper-bar">
|
||||||
|
<view class="text-center margin-right-sm text-orange" @click="makePhoneCall(member.phone)">
|
||||||
|
<view class="cuIcon-phone"></view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
<view class="solid-top margin-top-sm flex justify-between align-center padding-top">
|
||||||
|
<view class="flex flex-twice">
|
||||||
|
<text class="margin-right-xs">审批意见</text>
|
||||||
|
<input class="radius-input" @input="inputRemark($event, member)"></input>
|
||||||
|
</view>
|
||||||
|
|
||||||
|
<view class="flex flex-sub justify-end">
|
||||||
|
<view class="cu-btn bg-main-color sm radius" @click="approvingMember(index, member, '同意')">同意</view>
|
||||||
|
<view class="cu-btn sm radius margin-left-xs" @click="approvingMember(index, member, '不同意')">不同意</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
import horizontalNameCard from '@/components/common-card/horizontal-name-card.vue';
|
||||||
|
|
||||||
|
export default {
|
||||||
|
components: {
|
||||||
|
horizontalNameCard
|
||||||
|
},
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
members: [],
|
||||||
|
curUserInfo: {}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
onLoad(option) {
|
||||||
|
this.loadData(option);
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
async loadData(option) {
|
||||||
|
this.curUserInfo = this.$request.getCurUserInfo();
|
||||||
|
this.loadMembers2Approve();
|
||||||
|
},
|
||||||
|
makePhoneCall(phoneNum) {
|
||||||
|
uni.makePhoneCall({
|
||||||
|
phoneNumber: phoneNum
|
||||||
|
})
|
||||||
|
},
|
||||||
|
inputRemark(e, member) {
|
||||||
|
member.remark = e.detail.value;
|
||||||
|
},
|
||||||
|
async loadMembers2Approve(params = {}) {
|
||||||
|
let res = await this.$request.getMembersWaitingApproval({
|
||||||
|
customerId: this.curUserInfo.customerId
|
||||||
|
});
|
||||||
|
if (res && res.data) {
|
||||||
|
this.members = res.data;
|
||||||
|
}
|
||||||
|
},
|
||||||
|
async approvingMember(index, member, defaultRemark) {
|
||||||
|
let remark = member.remark ? member.remark : defaultRemark;
|
||||||
|
let res = await this.$request.editCustomerPlace({
|
||||||
|
id: member.id,
|
||||||
|
remark: remark
|
||||||
|
});
|
||||||
|
if (res && res.code === 0) {
|
||||||
|
uni.showToast({
|
||||||
|
icon: 'success'
|
||||||
|
})
|
||||||
|
this.members.splice(index, 1);
|
||||||
|
} else {
|
||||||
|
uni.showToast({
|
||||||
|
icon: 'error'
|
||||||
|
})
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style scoped>
|
||||||
|
.name-card {
|
||||||
|
position: relative;
|
||||||
|
}
|
||||||
|
|
||||||
|
.name-card .oper-bar {
|
||||||
|
position: absolute;
|
||||||
|
top: 20rpx;
|
||||||
|
right: 20rpx;
|
||||||
|
font-size: 50rpx;
|
||||||
|
}
|
||||||
|
|
||||||
|
.cu-list+.cu-list {
|
||||||
|
margin-top: unset;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
|
|
@ -157,7 +157,7 @@
|
||||||
code: '',
|
code: '',
|
||||||
name: '添加团队'
|
name: '添加团队'
|
||||||
}, {
|
}, {
|
||||||
code: '',
|
code: 'showMembers2Approval',
|
||||||
name: '组建/审批区域团队'
|
name: '组建/审批区域团队'
|
||||||
}],
|
}],
|
||||||
agreeShield: 1,
|
agreeShield: 1,
|
||||||
|
|
@ -245,6 +245,10 @@
|
||||||
case 'showCustomers':
|
case 'showCustomers':
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url: '/pages/my/my-team-member'
|
url: '/pages/my/my-team-member'
|
||||||
|
})
|
||||||
|
case 'showMembers2Approval':
|
||||||
|
uni.navigateTo({
|
||||||
|
url: '/pages/my/member-approval'
|
||||||
})
|
})
|
||||||
default:
|
default:
|
||||||
break;
|
break;
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue