Compare commits
2 Commits
| Author | SHA1 | Date |
|---|---|---|
|
|
5b52699123 | |
|
|
7d26065eff |
|
|
@ -804,9 +804,6 @@ button.cuIcon.lg {
|
||||||
|
|
||||||
.cu-capsule .cu-tag {
|
.cu-capsule .cu-tag {
|
||||||
margin: 0;
|
margin: 0;
|
||||||
font-size: 25rpx;
|
|
||||||
padding: 0rpx 12rpx;
|
|
||||||
height: 42rpx;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.cu-capsule .cu-tag[class*="line-"]:last-child::after {
|
.cu-capsule .cu-tag[class*="line-"]:last-child::after {
|
||||||
|
|
@ -3029,12 +3026,8 @@ scroll-view.cu-steps .cu-item {
|
||||||
|
|
||||||
.margin-top-sm {
|
.margin-top-sm {
|
||||||
margin-top: 20upx;
|
margin-top: 20upx;
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
.margin-top-sm .labels {
|
|
||||||
font-size: 30upx;
|
|
||||||
}
|
|
||||||
.margin-top {
|
.margin-top {
|
||||||
margin-top: 30upx;
|
margin-top: 30upx;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -86,11 +86,15 @@ const myTeamInfo = {
|
||||||
}
|
}
|
||||||
|
|
||||||
const masterRules = [
|
const masterRules = [
|
||||||
'接单:属于您的订单请30分钟内接单。',
|
'0规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容',
|
||||||
'预约:接单后立即预约,超时30分钟会提示,超1小时你有责;',
|
'1规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容',
|
||||||
'排单:按约排单,30分钟未排单提示超时,超1小时你有责;',
|
'2规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容',
|
||||||
'上门:按约准时上门,超时上门或被投诉未上门,你有责;',
|
'3规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容',
|
||||||
'退单:当天订单不得私自退单,遇事可提前3小时与客户沟通妥善。紧急问题且沟通不畅的,请联系你上级或平台客服。上门时间3小时范围内退单的,产生责任由你承担。',
|
'4规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容',
|
||||||
|
'5规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容',
|
||||||
|
'6规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容',
|
||||||
|
'7规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容',
|
||||||
|
'8规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容规则内容'
|
||||||
]
|
]
|
||||||
|
|
||||||
// type: 0=升降序,1=功能按钮;order: 0=升序,1=降序;
|
// type: 0=升降序,1=功能按钮;order: 0=升序,1=降序;
|
||||||
|
|
@ -318,12 +322,7 @@ const timeRangeList = [
|
||||||
'18:00-18:30',
|
'18:00-18:30',
|
||||||
'18:30-19:00',
|
'18:30-19:00',
|
||||||
'19:00-19:30',
|
'19:00-19:30',
|
||||||
'19:30-20:00',
|
'19:30-20:00'
|
||||||
'19:00-20:00',
|
|
||||||
'20:00-21:00',
|
|
||||||
'21:00-22:00',
|
|
||||||
'22:00-23:00',
|
|
||||||
'23:00-24:00',
|
|
||||||
]
|
]
|
||||||
|
|
||||||
const servDetail = {
|
const servDetail = {
|
||||||
|
|
|
||||||
|
|
@ -27,12 +27,6 @@ export default {
|
||||||
}
|
}
|
||||||
return this.countDownDiffCache;
|
return this.countDownDiffCache;
|
||||||
},
|
},
|
||||||
addDays(dateStr, dayAmount) {
|
|
||||||
let date = new Date(dateStr);
|
|
||||||
// 使用时间戳计算,避免时区问题
|
|
||||||
const timestamp = date.getTime() + (dayAmount * 24 * 60 * 60 * 1000);
|
|
||||||
return new Date(timestamp);
|
|
||||||
},
|
|
||||||
addHours(dateStr, hourAmount) {
|
addHours(dateStr, hourAmount) {
|
||||||
let date = new Date(dateStr);
|
let date = new Date(dateStr);
|
||||||
date.setHours(date.getHours() + hourAmount);
|
date.setHours(date.getHours() + hourAmount);
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,5 @@
|
||||||
export default {
|
export default {
|
||||||
deptId: 101,
|
deptId: 102,
|
||||||
from: 'server',
|
from: 'server',
|
||||||
initPageNum: 1,
|
initPageNum: 1,
|
||||||
initPageSize: 10,
|
initPageSize: 10,
|
||||||
|
|
|
||||||
|
|
@ -1,45 +1,21 @@
|
||||||
import globalData from '@/common/js/globalData.js';
|
import globalData from '@/common/js/globalData.js';
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
address: 'https://gmhl.gmjlb.com',
|
address: 'https://www.opsoul.com:8881',
|
||||||
// address: 'https://gmhl.opsoul.com',
|
|
||||||
// 异步接口拦截
|
// 异步接口拦截
|
||||||
addInterceptor() {
|
addInterceptor() {
|
||||||
let _this = this;
|
let _this = this;
|
||||||
uni.addInterceptor('request', {
|
uni.addInterceptor('request', {
|
||||||
invoke(args) {
|
invoke(args) {
|
||||||
if(!args.hideLoading) {
|
|
||||||
uni.showLoading({
|
uni.showLoading({
|
||||||
mask: true,
|
mask: true,
|
||||||
title: '加载中'
|
title: '加载中'
|
||||||
})
|
})
|
||||||
}
|
|
||||||
|
|
||||||
let userInfo = _this.getCurUserInfo();
|
let userInfo = _this.getCurUserInfo();
|
||||||
|
|
||||||
// if(userInfo.loginStatus == 1) {
|
|
||||||
// // 禁止登录,退出登录
|
|
||||||
// uni.clearStorageSync('userProfile');
|
|
||||||
// uni.showToast({
|
|
||||||
// icon: 'none',
|
|
||||||
// title: '您已被禁止登录',
|
|
||||||
// duration: 3000,
|
|
||||||
// success() {
|
|
||||||
// setTimeout(() => {
|
|
||||||
// uni.hideLoading();
|
|
||||||
// uni.reLaunch({
|
|
||||||
// url: '/pages/login/login'
|
|
||||||
// })
|
|
||||||
// }, 3000)
|
|
||||||
// }
|
|
||||||
// })
|
|
||||||
// return
|
|
||||||
// }
|
|
||||||
// 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://127.0.0.1:80' + args.url;
|
// args.url = 'http://127.0.0.1:80' + args.url;
|
||||||
// args.url = 'https://gmhl.opsoul.com' + args.url;
|
// args.url = 'http://192.168.2.74:80' + args.url;
|
||||||
args.url = 'https://gmhl.gmjlb.com' + args.url;
|
|
||||||
|
|
||||||
if (!args.data) {
|
if (!args.data) {
|
||||||
args.data = {}
|
args.data = {}
|
||||||
|
|
@ -64,14 +40,12 @@ export default {
|
||||||
uni.hideLoading();
|
uni.hideLoading();
|
||||||
if (!res || !res.data || res.data.code !== 0) {
|
if (!res || !res.data || res.data.code !== 0) {
|
||||||
uni.showToast({
|
uni.showToast({
|
||||||
title: res.data.msg || '系统错误',
|
title: '系统错误',
|
||||||
icon: 'error'
|
icon: 'error'
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
// _this.getAndSetWorkerInfo()
|
|
||||||
},
|
},
|
||||||
fail(err) {
|
fail(err) {
|
||||||
console.log(err);
|
|
||||||
uni.hideLoading();
|
uni.hideLoading();
|
||||||
uni.showToast({
|
uni.showToast({
|
||||||
title: '请求失败',
|
title: '请求失败',
|
||||||
|
|
@ -206,33 +180,6 @@ export default {
|
||||||
uni.clearStorageSync('userProfile');
|
uni.clearStorageSync('userProfile');
|
||||||
uni.setStorageSync('userProfile', userInfo);
|
uni.setStorageSync('userProfile', userInfo);
|
||||||
},
|
},
|
||||||
async GetCurrentLocation() {
|
|
||||||
let res = await this.wxGetLocation()
|
|
||||||
console.log(res);
|
|
||||||
if (!res || !res.latitude) {
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
let res1 = await uni.request({
|
|
||||||
url: '/tool/baidu/getLocation',
|
|
||||||
method: 'POST',
|
|
||||||
data: {
|
|
||||||
location: res.latitude + ',' + res.longitude
|
|
||||||
}
|
|
||||||
})
|
|
||||||
let areaRes = res1[1].data
|
|
||||||
return areaRes.data;
|
|
||||||
},
|
|
||||||
async TransformLocation(params) {
|
|
||||||
let res1 = await uni.request({
|
|
||||||
url: '/tool/baidu/getLocation',
|
|
||||||
method: 'POST',
|
|
||||||
data: {
|
|
||||||
location: params.latitude + ',' + params.longitude
|
|
||||||
}
|
|
||||||
})
|
|
||||||
let areaRes = res1[1].data
|
|
||||||
return areaRes.data;
|
|
||||||
},
|
|
||||||
async registerUser(params = {}) {
|
async registerUser(params = {}) {
|
||||||
let res = await uni.request({
|
let res = await uni.request({
|
||||||
url: '/wx/addWorker',
|
url: '/wx/addWorker',
|
||||||
|
|
@ -323,13 +270,8 @@ export default {
|
||||||
},
|
},
|
||||||
getCurUserInfo() {
|
getCurUserInfo() {
|
||||||
let userProfile = uni.getStorageSync('userProfile');
|
let userProfile = uni.getStorageSync('userProfile');
|
||||||
|
|
||||||
return userProfile;
|
return userProfile;
|
||||||
},
|
},
|
||||||
async refreshCurUserCache() {
|
|
||||||
let newUserInfo = await this.getCurUserNoCache();
|
|
||||||
uni.setStorageSync('userProfile', newUserInfo);
|
|
||||||
},
|
|
||||||
updateCache(cacheKey, cacheVal) {
|
updateCache(cacheKey, cacheVal) {
|
||||||
uni.setStorageSync(cacheKey, cacheVal);
|
uni.setStorageSync(cacheKey, cacheVal);
|
||||||
},
|
},
|
||||||
|
|
@ -362,7 +304,7 @@ export default {
|
||||||
if (resStr != null && resStr.length > 0) {
|
if (resStr != null && resStr.length > 0) {
|
||||||
try {
|
try {
|
||||||
resObj = JSON.parse(resStr);
|
resObj = JSON.parse(resStr);
|
||||||
} catch (e) {
|
} catch(e) {
|
||||||
console.log(e)
|
console.log(e)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -375,9 +317,7 @@ export default {
|
||||||
}
|
}
|
||||||
return resObj.url;
|
return resObj.url;
|
||||||
},
|
},
|
||||||
async qrySpecialSkillList(params = {
|
async qrySpecialSkillList(params = {goodsCategoryId : null}) {
|
||||||
goodsCategoryId: null
|
|
||||||
}) {
|
|
||||||
let res = await uni.request({
|
let res = await uni.request({
|
||||||
url: '/special/skill/list',
|
url: '/special/skill/list',
|
||||||
method: 'POST',
|
method: 'POST',
|
||||||
|
|
@ -385,9 +325,7 @@ export default {
|
||||||
})
|
})
|
||||||
return res[1].data;
|
return res[1].data;
|
||||||
},
|
},
|
||||||
async listByStep(params = {
|
async listByStep(params = {goodsCategoryId : null}) {
|
||||||
goodsCategoryId: null
|
|
||||||
}) {
|
|
||||||
let res = await uni.request({
|
let res = await uni.request({
|
||||||
url: '/goods/deptcategory/listByStep',
|
url: '/goods/deptcategory/listByStep',
|
||||||
method: 'POST',
|
method: 'POST',
|
||||||
|
|
@ -395,9 +333,7 @@ export default {
|
||||||
})
|
})
|
||||||
return res[1].data;
|
return res[1].data;
|
||||||
},
|
},
|
||||||
async areaListByStep(params = {
|
async areaListByStep(params = { parentCode: null }) {
|
||||||
parentCode: null
|
|
||||||
}) {
|
|
||||||
let res = await uni.request({
|
let res = await uni.request({
|
||||||
url: '/system/area/app/list',
|
url: '/system/area/app/list',
|
||||||
method: 'POST',
|
method: 'POST',
|
||||||
|
|
@ -421,23 +357,6 @@ export default {
|
||||||
})
|
})
|
||||||
return res[1].data;
|
return res[1].data;
|
||||||
},
|
},
|
||||||
async insuranceUserList(params) {
|
|
||||||
let res = await uni.request({
|
|
||||||
url: '/insurance/user/app/list',
|
|
||||||
method: 'POST',
|
|
||||||
data: params
|
|
||||||
})
|
|
||||||
return res[1].data;
|
|
||||||
},
|
|
||||||
async insuranceUserAdd(params) {
|
|
||||||
let res = await uni.request({
|
|
||||||
url: '/insurance/user/add',
|
|
||||||
method: 'POST',
|
|
||||||
data: params,
|
|
||||||
hideLoading: true
|
|
||||||
})
|
|
||||||
return res[1].data;
|
|
||||||
},
|
|
||||||
async addGoods(params) {
|
async addGoods(params) {
|
||||||
let res = await uni.request({
|
let res = await uni.request({
|
||||||
url: '/goods/goods/addGoods',
|
url: '/goods/goods/addGoods',
|
||||||
|
|
@ -515,9 +434,7 @@ export default {
|
||||||
data: params,
|
data: params,
|
||||||
header: {
|
header: {
|
||||||
pageNum: params.pageNum,
|
pageNum: params.pageNum,
|
||||||
pageSize: params.pageSize,
|
pageSize: params.pageSize
|
||||||
orderByColumn: params.orderByColumn ? params.orderByColumn : "",
|
|
||||||
isAsc: params.isAsc ? params.isAsc : ""
|
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
return res[1].data;
|
return res[1].data;
|
||||||
|
|
@ -534,11 +451,7 @@ export default {
|
||||||
let res = await uni.request({
|
let res = await uni.request({
|
||||||
url: '/order/app/mix/order/list',
|
url: '/order/app/mix/order/list',
|
||||||
method: 'POST',
|
method: 'POST',
|
||||||
data: params,
|
data: params
|
||||||
header: {
|
|
||||||
orderByColumn: params.orderByColumn ? params.orderByColumn : "",
|
|
||||||
isAsc: params.isAsc ? params.isAsc : ""
|
|
||||||
}
|
|
||||||
})
|
})
|
||||||
return res[1].data;
|
return res[1].data;
|
||||||
},
|
},
|
||||||
|
|
@ -546,11 +459,7 @@ export default {
|
||||||
let res = await uni.request({
|
let res = await uni.request({
|
||||||
url: '/order/app/mix/after/list',
|
url: '/order/app/mix/after/list',
|
||||||
method: 'POST',
|
method: 'POST',
|
||||||
data: params,
|
data: params
|
||||||
header: {
|
|
||||||
orderByColumn: params.orderByColumn ? params.orderByColumn : "",
|
|
||||||
isAsc: params.isAsc ? params.isAsc : ""
|
|
||||||
}
|
|
||||||
})
|
})
|
||||||
return res[1].data;
|
return res[1].data;
|
||||||
},
|
},
|
||||||
|
|
@ -578,14 +487,6 @@ export default {
|
||||||
})
|
})
|
||||||
return res[1].data;
|
return res[1].data;
|
||||||
},
|
},
|
||||||
async checkOrderInsurance(params = {}) {
|
|
||||||
let res = await uni.request({
|
|
||||||
url: '/order/master/orderInsurance?orderCode='+params.orderCode,
|
|
||||||
method: 'POST',
|
|
||||||
data: params
|
|
||||||
})
|
|
||||||
return res[1].data;
|
|
||||||
},
|
|
||||||
async qryDetailOrderPage(params = {}) {
|
async qryDetailOrderPage(params = {}) {
|
||||||
let res = await uni.request({
|
let res = await uni.request({
|
||||||
url: '/order/detail/app/list',
|
url: '/order/detail/app/list',
|
||||||
|
|
@ -593,9 +494,7 @@ export default {
|
||||||
data: params,
|
data: params,
|
||||||
header: {
|
header: {
|
||||||
pageNum: params.pageNum,
|
pageNum: params.pageNum,
|
||||||
pageSize: params.pageSize,
|
pageSize: params.pageSize
|
||||||
orderByColumn: params.orderByColumn ? params.orderByColumn : "",
|
|
||||||
isAsc: params.isAsc ? params.isAsc : ""
|
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
return res[1].data;
|
return res[1].data;
|
||||||
|
|
@ -763,36 +662,6 @@ export default {
|
||||||
})
|
})
|
||||||
return res[1].data;
|
return res[1].data;
|
||||||
},
|
},
|
||||||
async rejectMasterOrderWhenAccepted(params = {}) {
|
|
||||||
let res = await uni.request({
|
|
||||||
url: '/order/master/console/cancel',
|
|
||||||
method: 'POST',
|
|
||||||
data: params
|
|
||||||
})
|
|
||||||
return res[1].data;
|
|
||||||
},
|
|
||||||
async goodsOrderRefund(params = {}) {
|
|
||||||
let res = await uni.request({
|
|
||||||
url: '/order/master/goodsOrderRefund',
|
|
||||||
method: 'POST',
|
|
||||||
data: params,
|
|
||||||
header: {
|
|
||||||
'content-type': 'application/x-www-form-urlencoded'
|
|
||||||
}
|
|
||||||
})
|
|
||||||
return res[1].data;
|
|
||||||
},
|
|
||||||
async deleteAttachPrice(params = {}) {
|
|
||||||
let res = await uni.request({
|
|
||||||
url: '/order/attach/deleteByDetailId',
|
|
||||||
method: 'POST',
|
|
||||||
data: params,
|
|
||||||
header: {
|
|
||||||
'content-type': 'application/x-www-form-urlencoded'
|
|
||||||
}
|
|
||||||
})
|
|
||||||
return res[1].data;
|
|
||||||
},
|
|
||||||
async changeOrderPrice(params = {}) {
|
async changeOrderPrice(params = {}) {
|
||||||
let res = await uni.request({
|
let res = await uni.request({
|
||||||
url: '/order/detail/app/change/price',
|
url: '/order/detail/app/change/price',
|
||||||
|
|
@ -817,14 +686,6 @@ export default {
|
||||||
})
|
})
|
||||||
return res[1].data;
|
return res[1].data;
|
||||||
},
|
},
|
||||||
async editOrder(params = {}) {
|
|
||||||
let res = await uni.request({
|
|
||||||
url: '/order/detail/app/edit',
|
|
||||||
method: 'POST',
|
|
||||||
data: params
|
|
||||||
})
|
|
||||||
return res[1].data;
|
|
||||||
},
|
|
||||||
async editAfterServiceRecord(params = {}) {
|
async editAfterServiceRecord(params = {}) {
|
||||||
let res = await uni.request({
|
let res = await uni.request({
|
||||||
url: '/worker/record/edit',
|
url: '/worker/record/edit',
|
||||||
|
|
@ -837,14 +698,6 @@ export default {
|
||||||
})
|
})
|
||||||
return res[1].data;
|
return res[1].data;
|
||||||
},
|
},
|
||||||
async allocateServiceMoney(params) {
|
|
||||||
let res = await uni.request({
|
|
||||||
url: '/order/generate/service/order',
|
|
||||||
method: 'POST',
|
|
||||||
data: params
|
|
||||||
})
|
|
||||||
return res[1].data;
|
|
||||||
},
|
|
||||||
async checkAuth(authScope, callbackName, callbackSuccessKey) {
|
async checkAuth(authScope, callbackName, callbackSuccessKey) {
|
||||||
let _this = this;
|
let _this = this;
|
||||||
// 通过 wx.getSetting 先查询一下用户是否授权了authScope
|
// 通过 wx.getSetting 先查询一下用户是否授权了authScope
|
||||||
|
|
@ -884,8 +737,7 @@ export default {
|
||||||
},
|
},
|
||||||
async wxGetLocation() {
|
async wxGetLocation() {
|
||||||
let errCode = null;
|
let errCode = null;
|
||||||
return new Promise((resolve, reject) => {
|
let res = await wx.getLocation({
|
||||||
wx.getLocation({
|
|
||||||
type: 'gcj02',
|
type: 'gcj02',
|
||||||
fail: async (result) => {
|
fail: async (result) => {
|
||||||
if (result.errCode === 2) {
|
if (result.errCode === 2) {
|
||||||
|
|
@ -895,15 +747,15 @@ export default {
|
||||||
duration: 2500
|
duration: 2500
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
reject(null)
|
|
||||||
},
|
},
|
||||||
success: async (result) => {
|
success: async (result) => {
|
||||||
console.log("success", result);
|
console.log("success");
|
||||||
resolve(result)
|
return result;
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
})
|
// res.latitude, res.longitude
|
||||||
|
console.log(res)
|
||||||
|
return res;
|
||||||
},
|
},
|
||||||
|
|
||||||
async callCustomer(params = {}) {
|
async callCustomer(params = {}) {
|
||||||
|
|
@ -913,200 +765,5 @@ export default {
|
||||||
data: params
|
data: params
|
||||||
})
|
})
|
||||||
return res[1].data;
|
return res[1].data;
|
||||||
},
|
|
||||||
|
|
||||||
async callDetailCustomer(params = {}) {
|
|
||||||
let res = await uni.request({
|
|
||||||
url: '/order/detail/callCustomer',
|
|
||||||
method: 'POST',
|
|
||||||
data: params
|
|
||||||
})
|
|
||||||
return res[1].data;
|
|
||||||
},
|
|
||||||
|
|
||||||
async addOrderAttach(params = {}) {
|
|
||||||
let res = await uni.request({
|
|
||||||
url: '/order/attach/appAdd',
|
|
||||||
method: 'POST',
|
|
||||||
data: params,
|
|
||||||
header: {
|
|
||||||
'content-type': 'application/x-www-form-urlencoded'
|
|
||||||
}
|
}
|
||||||
})
|
|
||||||
return res[1].data;
|
|
||||||
},
|
|
||||||
// 操作流程节点
|
|
||||||
async addOrderOperate(params = {}) {
|
|
||||||
let res = await uni.request({
|
|
||||||
url: '/order/operate/app/add',
|
|
||||||
method: 'POST',
|
|
||||||
data: params
|
|
||||||
})
|
|
||||||
return res[1].data;
|
|
||||||
},
|
|
||||||
|
|
||||||
async returnOrder(params = {}) {
|
|
||||||
let res = await uni.request({
|
|
||||||
url: '/order/detail/app/return',
|
|
||||||
method: 'POST',
|
|
||||||
data: params
|
|
||||||
})
|
|
||||||
return res[1].data;
|
|
||||||
},
|
|
||||||
|
|
||||||
// 获取操作流程节点列表
|
|
||||||
async getOrderOperate(params = {}) {
|
|
||||||
let res = await uni.request({
|
|
||||||
url: '/order/operate/app/list',
|
|
||||||
method: 'POST',
|
|
||||||
data: params
|
|
||||||
})
|
|
||||||
return res[1].data;
|
|
||||||
},
|
|
||||||
// 验证接单用户保险信息
|
|
||||||
async certNoTwoElementVerification(params) {
|
|
||||||
let res = await uni.request({
|
|
||||||
url: '/tool/ali/certNoTwoElementVerification',
|
|
||||||
method: 'POST',
|
|
||||||
data: params
|
|
||||||
})
|
|
||||||
return res[1].data;
|
|
||||||
},
|
|
||||||
async getShopAddressList(params = {}) {
|
|
||||||
let res = await uni.request({
|
|
||||||
url: '/shop/list',
|
|
||||||
method: 'GET',
|
|
||||||
data: params
|
|
||||||
})
|
|
||||||
return res[1].data;
|
|
||||||
},
|
|
||||||
async getMasterShopAddressList(workerId) {
|
|
||||||
let res = await uni.request({
|
|
||||||
url: '/shop/worker/'+workerId,
|
|
||||||
method: 'GET'
|
|
||||||
})
|
|
||||||
return res[1].data;
|
|
||||||
},
|
|
||||||
async addShopAddressList(params = {}) {
|
|
||||||
let res = await uni.request({
|
|
||||||
url: '/shop/add',
|
|
||||||
method: 'POST',
|
|
||||||
data: params
|
|
||||||
})
|
|
||||||
return res[1].data;
|
|
||||||
},
|
|
||||||
async editShopAddressList(params = {}) {
|
|
||||||
let res = await uni.request({
|
|
||||||
url: '/shop/update',
|
|
||||||
method: 'POST',
|
|
||||||
data: params
|
|
||||||
})
|
|
||||||
return res[1].data;
|
|
||||||
},
|
|
||||||
async delShopAddressList(customerAddressId) {
|
|
||||||
let res = await uni.request({
|
|
||||||
url: '/shop/delete/'+customerAddressId,
|
|
||||||
method: 'POST'
|
|
||||||
})
|
|
||||||
return res[1].data;
|
|
||||||
},
|
|
||||||
async changeInvoiceStatus(params = {}) {
|
|
||||||
let res = await uni.request({
|
|
||||||
url: '/order/master/changeInvoiceStatus',
|
|
||||||
method: 'POST',
|
|
||||||
data: params
|
|
||||||
})
|
|
||||||
return res[1].data;
|
|
||||||
},
|
|
||||||
async transferOrder(params = {}) {
|
|
||||||
let res = await uni.request({
|
|
||||||
url: '/order/master/transferOrder',
|
|
||||||
method: 'POST',
|
|
||||||
data: params
|
|
||||||
})
|
|
||||||
return res[1].data;
|
|
||||||
},
|
|
||||||
async getByCustomerAddressId(customerAddressId) {
|
|
||||||
let res = await uni.request({
|
|
||||||
url: '/customer/address/getByCustomerAddressId',
|
|
||||||
method: 'POST',
|
|
||||||
data: {
|
|
||||||
customerAddressId: customerAddressId
|
|
||||||
},
|
|
||||||
header: {
|
|
||||||
'content-type': 'application/x-www-form-urlencoded'
|
|
||||||
}
|
|
||||||
})
|
|
||||||
return res[1].data;
|
|
||||||
},
|
|
||||||
async getShopDetailWithDistance(params = {}) {
|
|
||||||
let res = await uni.request({
|
|
||||||
url: '/shop/getShopDetailWithDistance',
|
|
||||||
method: 'POST',
|
|
||||||
data: params
|
|
||||||
})
|
|
||||||
return res[1].data;
|
|
||||||
},
|
|
||||||
async getShopsByGoodsId(params = {}) {
|
|
||||||
let res = await uni.request({
|
|
||||||
url: '/goods/goods/getShopsByGoodsId',
|
|
||||||
method: 'POST',
|
|
||||||
data: params
|
|
||||||
})
|
|
||||||
return res[1].data;
|
|
||||||
},
|
|
||||||
async getDeliveryFlow(trackingNumber) {
|
|
||||||
// "trackingNumber": "YT8774104632324",
|
|
||||||
let res = await uni.request({
|
|
||||||
url: '/order/logistics/query/'+trackingNumber,
|
|
||||||
method: 'GET',
|
|
||||||
data: {}
|
|
||||||
})
|
|
||||||
return res[1].data;
|
|
||||||
},
|
|
||||||
async workerResendPlan(params = {}) {
|
|
||||||
let res = await uni.request({
|
|
||||||
url: '/worker/record/workerResendPlan',
|
|
||||||
method: 'POST',
|
|
||||||
data: params
|
|
||||||
})
|
|
||||||
return res[1].data;
|
|
||||||
},
|
|
||||||
async editAfterServiceGoodsRecord(params = {}) {
|
|
||||||
let res = await uni.request({
|
|
||||||
url: '/worker/record/editGoods',
|
|
||||||
method: 'POST',
|
|
||||||
data: params,
|
|
||||||
header: {
|
|
||||||
pageNum: params.pageNum,
|
|
||||||
pageSize: params.pageSize
|
|
||||||
}
|
|
||||||
})
|
|
||||||
return res[1].data;
|
|
||||||
},
|
|
||||||
async saveMasterWorkerRemark(params = {}) {
|
|
||||||
let res = await uni.request({
|
|
||||||
url: '/order/master/saveMasterWorkerRemark',
|
|
||||||
method: 'POST',
|
|
||||||
data: params
|
|
||||||
})
|
|
||||||
return res[1].data;
|
|
||||||
},
|
|
||||||
async getAndSetWorkerInfo(workerId) {
|
|
||||||
let res = await uni.request({
|
|
||||||
url: '/worker/detail/'+ workerId,
|
|
||||||
method: 'GET'
|
|
||||||
})
|
|
||||||
let curUserInfo = res[1].data.data;
|
|
||||||
uni.setStorageSync('userProfile', curUserInfo);
|
|
||||||
return res[1].data;
|
|
||||||
},
|
|
||||||
async workerConfirmReceive(params = {}) {
|
|
||||||
let res = await uni.request({
|
|
||||||
url: '/worker/record/workerConfirmReceive',
|
|
||||||
method: 'POST',
|
|
||||||
data: params
|
|
||||||
})
|
|
||||||
return res[1].data;
|
|
||||||
},
|
|
||||||
}
|
}
|
||||||
|
|
@ -15,9 +15,6 @@ export default {
|
||||||
}
|
}
|
||||||
return true;
|
return true;
|
||||||
},
|
},
|
||||||
validPhone: function(email) {
|
|
||||||
return contactNumRegex.test(email);
|
|
||||||
},
|
|
||||||
|
|
||||||
validIdCard: function(idCardNum) {
|
validIdCard: function(idCardNum) {
|
||||||
return idCardRegex.test(idCardNum);
|
return idCardRegex.test(idCardNum);
|
||||||
|
|
|
||||||
|
|
@ -1,54 +0,0 @@
|
||||||
export default {
|
|
||||||
data() {
|
|
||||||
return {
|
|
||||||
//设置默认的分享参数
|
|
||||||
share: {
|
|
||||||
title: '工盟互联',
|
|
||||||
path: '/pages/index/index',
|
|
||||||
imageUrl: '',
|
|
||||||
desc: '',
|
|
||||||
content: ''
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
onShareAppMessage(res) {
|
|
||||||
return {
|
|
||||||
title: this.share.title,
|
|
||||||
path: this.share.path,
|
|
||||||
imageUrl: this.share.imageUrl,
|
|
||||||
desc: this.share.desc,
|
|
||||||
content: this.share.content,
|
|
||||||
success(res) {
|
|
||||||
uni.showToast({
|
|
||||||
title: '分享成功'
|
|
||||||
})
|
|
||||||
},
|
|
||||||
fail(res) {
|
|
||||||
uni.showToast({
|
|
||||||
title: '分享失败',
|
|
||||||
icon: 'none'
|
|
||||||
})
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
onShareTimeline() {
|
|
||||||
return {
|
|
||||||
title: this.share.title,
|
|
||||||
path: this.share.path,
|
|
||||||
imageUrl: this.share.imageUrl,
|
|
||||||
desc: this.share.desc,
|
|
||||||
content: this.share.content,
|
|
||||||
success(res) {
|
|
||||||
uni.showToast({
|
|
||||||
title: '分享成功'
|
|
||||||
})
|
|
||||||
},
|
|
||||||
fail(res) {
|
|
||||||
uni.showToast({
|
|
||||||
title: '分享失败',
|
|
||||||
icon: 'none'
|
|
||||||
})
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
}
|
|
||||||
|
|
@ -4,28 +4,11 @@
|
||||||
</view>
|
</view>
|
||||||
<view class="margin-left-sm product-content">
|
<view class="margin-left-sm product-content">
|
||||||
<view>
|
<view>
|
||||||
<view class="text-black">{{product.totalName}}</view>
|
<view class="text-black">{{product.goodsName}}</view>
|
||||||
<view class="text-sm" v-if="ifShowComments">{{product.remark}}</view>
|
<view class="text-sm" v-if="ifShowComments">{{product.remark}}</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="flex align-center" v-if="product.goods">
|
<view class="flex justify-between align-center">
|
||||||
<view class='cu-tag round bg-orange light' v-if="product.goods.installService">
|
<view class="flex justify-start align-center" v-if="product.payMoney">
|
||||||
<text class="text-black">{{getInstallServiceName(product.goods.installService)}}</text>
|
|
||||||
</view>
|
|
||||||
<view class='cu-tag round bg-orange light' v-if="product.goods.deliveryService">
|
|
||||||
<text class="text-black">{{getDeliveryName(product.goods.deliveryService)}}</text>
|
|
||||||
</view>
|
|
||||||
<template v-if="product.goods.storeService">
|
|
||||||
<view class='cu-tag round bg-orange light' v-if="product.goods.storeService == 1">
|
|
||||||
<text class="text-black">到店服务</text>
|
|
||||||
</view>
|
|
||||||
<view class='cu-tag round bg-orange light' v-if="product.goods.storeService == 2">
|
|
||||||
<text class="text-black">到店+配送(服务)</text>
|
|
||||||
</view>
|
|
||||||
<view class='cu-tag round bg-orange light' v-if="product.goods.storeService == 3">
|
|
||||||
<text class="text-black">到店+上门(服务)</text>
|
|
||||||
</view>
|
|
||||||
</template>
|
|
||||||
<!-- <view class="flex justify-start align-center" v-if="product.payMoney">
|
|
||||||
<text class="text-price text-red text-bold text-xl">{{product.payMoney}}</text>
|
<text class="text-price text-red text-bold text-xl">{{product.payMoney}}</text>
|
||||||
</view>
|
</view>
|
||||||
<view v-else-if="product.discountPrice" class="flex justify-start align-center">
|
<view v-else-if="product.discountPrice" class="flex justify-start align-center">
|
||||||
|
|
@ -46,7 +29,7 @@
|
||||||
</view>
|
</view>
|
||||||
<view class="padding-xs" v-if="product.type">
|
<view class="padding-xs" v-if="product.type">
|
||||||
<view class='cu-tag light bg-blue'>{{product.type}}</view>
|
<view class='cu-tag light bg-blue'>{{product.type}}</view>
|
||||||
</view> -->
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view v-if="ifShowServArea">
|
<view v-if="ifShowServArea">
|
||||||
<view class="cu-capsule">
|
<view class="cu-capsule">
|
||||||
|
|
@ -54,7 +37,7 @@
|
||||||
<text class='cuIcon-locationfill'></text>
|
<text class='cuIcon-locationfill'></text>
|
||||||
</view>
|
</view>
|
||||||
<view class="cu-tag line-main-color sm">
|
<view class="cu-tag line-main-color sm">
|
||||||
{{product.orderType === 1 ? '发货区域' : '服务区域'}}
|
服务区域
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<text v-for="(item,index) in product.goodsAreaList" v-if="ifShowServArea">
|
<text v-for="(item,index) in product.goodsAreaList" v-if="ifShowServArea">
|
||||||
|
|
@ -75,37 +58,17 @@
|
||||||
},
|
},
|
||||||
ifShowComments: {
|
ifShowComments: {
|
||||||
type: Boolean,
|
type: Boolean,
|
||||||
default: false
|
default: true
|
||||||
},
|
},
|
||||||
product: {
|
product: {
|
||||||
type: Object,
|
type: Object,
|
||||||
default: () => {}
|
default: {}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
|
|
||||||
}
|
}
|
||||||
},
|
|
||||||
methods: {
|
|
||||||
getDeliveryName(deliveryService) {
|
|
||||||
if(deliveryService === 1) {
|
|
||||||
return '包邮'
|
|
||||||
} else if(deliveryService === 2) {
|
|
||||||
return '同城包送'
|
|
||||||
} else if(deliveryService === 3) {
|
|
||||||
return '邮费自付/自提'
|
|
||||||
}
|
|
||||||
},
|
|
||||||
getInstallServiceName(installService) {
|
|
||||||
if(installService === 1) {
|
|
||||||
return '包安装'
|
|
||||||
} else if(installService === 2) {
|
|
||||||
return '不包安装'
|
|
||||||
} else if(installService === 3) {
|
|
||||||
return '自费安装'
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
|
||||||
|
|
@ -41,10 +41,6 @@
|
||||||
type: Boolean,
|
type: Boolean,
|
||||||
default: true
|
default: true
|
||||||
},
|
},
|
||||||
isAutoClose: {
|
|
||||||
type: Boolean,
|
|
||||||
default: true
|
|
||||||
},
|
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
|
|
@ -61,9 +57,7 @@
|
||||||
},
|
},
|
||||||
confirmCallback(e) {
|
confirmCallback(e) {
|
||||||
this.$emit('confirm');
|
this.$emit('confirm');
|
||||||
if(this.isAutoClose) {
|
this.hideModal();
|
||||||
this.isShow = false;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -7,23 +7,19 @@
|
||||||
<input class="uni-combox__input" type="text" :placeholder="placeholder" @click="toggleSelector" disabled
|
<input class="uni-combox__input" type="text" :placeholder="placeholder" @click="toggleSelector" disabled
|
||||||
placeholder-class="uni-combox__input-plac" v-model="inputVal[showField]" @input="onInput" @focus="onFocus"
|
placeholder-class="uni-combox__input-plac" v-model="inputVal[showField]" @input="onInput" @focus="onFocus"
|
||||||
@blur="onBlur" />
|
@blur="onBlur" />
|
||||||
<uni-icons v-if="showClear && inputVal" type="clear" size="20" style="margin-right: 20rpx;" color="#999" @click="clearChosen">
|
|
||||||
</uni-icons>
|
|
||||||
<uni-icons :type="showSelector? 'top' : 'bottom'" size="14" color="#999" @click="toggleSelector">
|
<uni-icons :type="showSelector? 'top' : 'bottom'" size="14" color="#999" @click="toggleSelector">
|
||||||
</uni-icons>
|
</uni-icons>
|
||||||
</view>
|
</view>
|
||||||
<view class="uni-combox__selector" v-if="showSelector">
|
<view class="uni-combox__selector" v-if="showSelector">
|
||||||
<view class="uni-popper__arrow"></view>
|
<view class="uni-popper__arrow"></view>
|
||||||
<scroll-view scroll-y="true" class="uni-combox__selector-scroll" :style="{maxHeight: screenMaxHeight}">
|
<scroll-view scroll-y="true" class="uni-combox__selector-scroll">
|
||||||
|
<view class="uni-combox__selector-empty" v-if="filterCandidatesLength === 0">
|
||||||
|
<text>{{emptyTips}}</text>
|
||||||
|
</view>
|
||||||
<view class="uni-combox__selector-item" v-for="(item,index) in filterCandidates" :key="index"
|
<view class="uni-combox__selector-item" v-for="(item,index) in filterCandidates" :key="index"
|
||||||
@click="onSelectorClick(index)">
|
@click="onSelectorClick(index)">
|
||||||
<text>{{item[showField]}}</text>
|
<text>{{item[showField]}}</text>
|
||||||
</view>
|
</view>
|
||||||
<view class="uni-combox__selector-empty" v-if="filterCandidatesLength === 0 || alwaysShowEmpty">
|
|
||||||
<slot name="empty">
|
|
||||||
<text>{{emptyTips}}</text>
|
|
||||||
</slot>
|
|
||||||
</view>
|
|
||||||
</scroll-view>
|
</scroll-view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
@ -49,14 +45,6 @@
|
||||||
type: Boolean,
|
type: Boolean,
|
||||||
default: true
|
default: true
|
||||||
},
|
},
|
||||||
showClear: {
|
|
||||||
type: Boolean,
|
|
||||||
default: false
|
|
||||||
},
|
|
||||||
alwaysShowEmpty: {
|
|
||||||
type: Boolean,
|
|
||||||
default: false
|
|
||||||
},
|
|
||||||
label: {
|
label: {
|
||||||
type: String,
|
type: String,
|
||||||
default: ''
|
default: ''
|
||||||
|
|
@ -95,10 +83,6 @@
|
||||||
default: ''
|
default: ''
|
||||||
},
|
},
|
||||||
// #endif
|
// #endif
|
||||||
screenMaxHeight: {
|
|
||||||
type: String,
|
|
||||||
default: '200px'
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
|
|
@ -165,12 +149,6 @@
|
||||||
this.$emit('input', this.inputVal)
|
this.$emit('input', this.inputVal)
|
||||||
this.$emit('update:modelValue', this.inputVal)
|
this.$emit('update:modelValue', this.inputVal)
|
||||||
})
|
})
|
||||||
},
|
|
||||||
clearChosen() {
|
|
||||||
setTimeout(() => {
|
|
||||||
this.$emit('input', '')
|
|
||||||
this.$emit('update:modelValue', '')
|
|
||||||
})
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -9,7 +9,7 @@
|
||||||
</view>
|
</view>
|
||||||
<view class="cu-bar bg-white solid-top">
|
<view class="cu-bar bg-white solid-top">
|
||||||
<view class="action margin-0 flex-sub text-black" data-modal="showTakeCertifiedModal"
|
<view class="action margin-0 flex-sub text-black" data-modal="showTakeCertifiedModal"
|
||||||
@tap="hideModal">{{text}}</view>
|
@tap="hideModal">以后绑定</view>
|
||||||
<view class="action margin-0 flex-sub text-main-color solid-left"
|
<view class="action margin-0 flex-sub text-main-color solid-left"
|
||||||
data-modal="showTakeCertifiedModal" @tap="hideModal" @click="goToBindBank">立即绑定</view>
|
data-modal="showTakeCertifiedModal" @tap="hideModal" @click="goToBindBank">立即绑定</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
@ -21,13 +21,7 @@
|
||||||
<script>
|
<script>
|
||||||
export default {
|
export default {
|
||||||
name: 'vertify-bank-bind',
|
name: 'vertify-bank-bind',
|
||||||
emits: ['reload', 'stillAcceptOrder'],
|
emits: ['reload'],
|
||||||
props: {
|
|
||||||
text: {
|
|
||||||
type: String,
|
|
||||||
default: '以后绑定'
|
|
||||||
}
|
|
||||||
},
|
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
isShow: false
|
isShow: false
|
||||||
|
|
@ -39,9 +33,6 @@
|
||||||
},
|
},
|
||||||
hideModal(e) {
|
hideModal(e) {
|
||||||
this.isShow = false;
|
this.isShow = false;
|
||||||
if(this.text == '仍然接单') {
|
|
||||||
this.$emit('stillAcceptOrder')
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
goToBindBank() {
|
goToBindBank() {
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
|
|
|
||||||
|
|
@ -9,7 +9,7 @@
|
||||||
</view>
|
</view>
|
||||||
<view class="cu-bar bg-white solid-top">
|
<view class="cu-bar bg-white solid-top">
|
||||||
<view class="action margin-0 flex-sub text-black" data-modal="showTakeCertifiedModal"
|
<view class="action margin-0 flex-sub text-black" data-modal="showTakeCertifiedModal"
|
||||||
@tap="hideModal">{{text}}</view>
|
@tap="hideModal">以后认证</view>
|
||||||
<view class="action margin-0 flex-sub text-main-color solid-left"
|
<view class="action margin-0 flex-sub text-main-color solid-left"
|
||||||
data-modal="showTakeCertifiedModal" @tap="hideModal" @click="goToCertify">立即认证</view>
|
data-modal="showTakeCertifiedModal" @tap="hideModal" @click="goToCertify">立即认证</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
@ -21,13 +21,7 @@
|
||||||
<script>
|
<script>
|
||||||
export default {
|
export default {
|
||||||
name: 'vertify-certify',
|
name: 'vertify-certify',
|
||||||
emits: ['reload', 'stillAcceptOrder'],
|
emits: ['reload'],
|
||||||
props: {
|
|
||||||
text: {
|
|
||||||
type: String,
|
|
||||||
default: '以后认证'
|
|
||||||
}
|
|
||||||
},
|
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
isShow: false
|
isShow: false
|
||||||
|
|
@ -39,9 +33,6 @@
|
||||||
},
|
},
|
||||||
hideModal(e) {
|
hideModal(e) {
|
||||||
this.isShow = false;
|
this.isShow = false;
|
||||||
if(this.text == '仍然接单') {
|
|
||||||
this.$emit('stillAcceptOrder')
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
goToCertify() {
|
goToCertify() {
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
|
|
|
||||||
|
|
@ -5,10 +5,10 @@
|
||||||
<view class="cu-dialog">
|
<view class="cu-dialog">
|
||||||
<view class="padding-xl">
|
<view class="padding-xl">
|
||||||
<view class="cuIcon-discover big-icon padding-tb text-main-color"></view>
|
<view class="cuIcon-discover big-icon padding-tb text-main-color"></view>
|
||||||
<view>请您选择供应类型!提供服务类型的请选--服务商!提供商品类型的请选--货品商!</view>
|
<view>请您选择供应类型!到家服务类请选-服务商;商品销售类请选-品牌商。</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="cu-bar bg-white">
|
<view class="cu-bar bg-white">
|
||||||
<view class="action margin-0 flex-sub text-black" data-modal="isShowSteer" @click="chooseEntryType(1)">货品商
|
<view class="action margin-0 flex-sub text-black" data-modal="isShowSteer" @click="chooseEntryType(1)">品牌商
|
||||||
</view>
|
</view>
|
||||||
<view class="action margin-0 flex-sub text-main-color solid-left"
|
<view class="action margin-0 flex-sub text-main-color solid-left"
|
||||||
data-modal="isShowSteer" @click="chooseEntryType(0)">服务商</view>
|
data-modal="isShowSteer" @click="chooseEntryType(0)">服务商</view>
|
||||||
|
|
@ -37,21 +37,18 @@
|
||||||
this.hideModal();
|
this.hideModal();
|
||||||
let curUserInfo = this.$request.getCurUserInfo();
|
let curUserInfo = this.$request.getCurUserInfo();
|
||||||
if (typeCode === 1) {
|
if (typeCode === 1) {
|
||||||
// if (curUserInfo && curUserInfo.storeStatus == 1) {
|
if (curUserInfo && curUserInfo.storeStatus == 1) {
|
||||||
// uni.navigateTo({
|
|
||||||
// url: '/pages/index/index?menuCode=supplyChainPage'
|
|
||||||
// })
|
|
||||||
// } else {
|
|
||||||
// uni.navigateTo({
|
|
||||||
// url: '/pages/my/apply-shop'
|
|
||||||
// })
|
|
||||||
// }
|
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url: '/pages/my/master-settled-info?type=2'
|
url: '/pages/index/index?menuCode=supplyChainPage'
|
||||||
})
|
})
|
||||||
|
} else {
|
||||||
|
uni.navigateTo({
|
||||||
|
url: '/pages/my/apply-shop'
|
||||||
|
})
|
||||||
|
}
|
||||||
} else if (typeCode === 0) {
|
} else if (typeCode === 0) {
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url: '/pages/my/master-settled-info?type=1'
|
url: '/pages/my/master-settled-info'
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
4
main.js
4
main.js
|
|
@ -49,10 +49,6 @@ Vue.prototype.$calcUtil = calcUtil;
|
||||||
Vue.prototype.$commonFun = commonFun;
|
Vue.prototype.$commonFun = commonFun;
|
||||||
Vue.prototype.$request = request;
|
Vue.prototype.$request = request;
|
||||||
|
|
||||||
import share from 'common/mixin/share.js'//我命名为share.js
|
|
||||||
Vue.mixin(share)
|
|
||||||
|
|
||||||
|
|
||||||
Vue.config.productionTip = false
|
Vue.config.productionTip = false
|
||||||
|
|
||||||
App.mpType = 'app'
|
App.mpType = 'app'
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name" : "dingdong-master",
|
"name" : "dingdong-master",
|
||||||
"appid" : "__UNI__EF8108C",
|
"appid" : "",
|
||||||
"description" : "",
|
"description" : "",
|
||||||
"versionName" : "1.0.0",
|
"versionName" : "1.0.0",
|
||||||
"versionCode" : "100",
|
"versionCode" : "100",
|
||||||
|
|
@ -52,7 +52,8 @@
|
||||||
"quickapp" : {},
|
"quickapp" : {},
|
||||||
/* 快应用特有相关 */
|
/* 快应用特有相关 */
|
||||||
"mp-weixin" : {
|
"mp-weixin" : {
|
||||||
"appid" : "wx105ce607b514ff2a",
|
/* 小程序特有相关 */
|
||||||
|
"appid" : "wxc2920b79d0980f8b",
|
||||||
"setting" : {
|
"setting" : {
|
||||||
"urlCheck" : false,
|
"urlCheck" : false,
|
||||||
"minified" : true,
|
"minified" : true,
|
||||||
|
|
@ -62,11 +63,8 @@
|
||||||
"permission" : {
|
"permission" : {
|
||||||
"scope.userLocation" : {
|
"scope.userLocation" : {
|
||||||
"desc" : "因涉及上门家政服务,需获取地理位置"
|
"desc" : "因涉及上门家政服务,需获取地理位置"
|
||||||
},
|
|
||||||
"scope.writeClipboard" : {
|
|
||||||
"desc" : "剪贴板写入权限"
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"requiredPrivateInfos" : [ "getLocation", "chooseLocation" ]
|
"requiredPrivateInfos" : [ "getLocation" ]
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
12
pages.json
12
pages.json
|
|
@ -27,27 +27,19 @@
|
||||||
"root": "pages/order-manage/",
|
"root": "pages/order-manage/",
|
||||||
"pages": [{
|
"pages": [{
|
||||||
"path": "order-manage"
|
"path": "order-manage"
|
||||||
}, {
|
|
||||||
"path": "order-manage-parts"
|
|
||||||
}, {
|
}, {
|
||||||
"path": "serv-detail"
|
"path": "serv-detail"
|
||||||
}, {
|
}, {
|
||||||
"path": "finish-order"
|
"path": "finish-order"
|
||||||
}, {
|
}, {
|
||||||
"path": "cancel-order"
|
"path": "cancel-order"
|
||||||
}, {
|
|
||||||
"path": "choose-shop"
|
|
||||||
}]
|
}]
|
||||||
}, {
|
}, {
|
||||||
"root": "pages/my/",
|
"root": "pages/my/",
|
||||||
"pages": [{
|
"pages": [{
|
||||||
"path": "new-serv"
|
"path": "new-serv"
|
||||||
},{
|
|
||||||
"path": "new-serv-parts"
|
|
||||||
}, {
|
}, {
|
||||||
"path": "master-occupancy"
|
"path": "master-occupancy"
|
||||||
}, {
|
|
||||||
"path": "master-occupancy-parts"
|
|
||||||
}, {
|
}, {
|
||||||
"path": "withdraw"
|
"path": "withdraw"
|
||||||
}, {
|
}, {
|
||||||
|
|
@ -68,10 +60,6 @@
|
||||||
"path": "certification"
|
"path": "certification"
|
||||||
}, {
|
}, {
|
||||||
"path": "apply-shop"
|
"path": "apply-shop"
|
||||||
},{
|
|
||||||
"path": "shop-list"
|
|
||||||
},{
|
|
||||||
"path": "edit-shop-address"
|
|
||||||
}]
|
}]
|
||||||
}],
|
}],
|
||||||
"globalStyle": {
|
"globalStyle": {
|
||||||
|
|
|
||||||
|
|
@ -50,7 +50,7 @@
|
||||||
<view class="cu-bar bg-white tabbar border shop fixed-bottom-bar">
|
<view class="cu-bar bg-white tabbar border shop fixed-bottom-bar">
|
||||||
<view class="left-grid text-center" data-modal="takeRateSet" @click="showModalByRef('setTakeRateModal')">
|
<view class="left-grid text-center" data-modal="takeRateSet" @click="showModalByRef('setTakeRateModal')">
|
||||||
<view>设置扣点</view>
|
<view>设置扣点</view>
|
||||||
<view v-if="curUserInfo.leaderTeamRate && !backIndex">(扣点:<text
|
<view v-if="curUserInfo.leaderTeamRate">(扣点:<text
|
||||||
class="text-red">{{Number(curUserInfo.leaderTeamRate)*100}}%</text>)</view>
|
class="text-red">{{Number(curUserInfo.leaderTeamRate)*100}}%</text>)</view>
|
||||||
</view>
|
</view>
|
||||||
<!-- <view class="bg-main-color submit" @click="showModalByRef('inviteMasterModal')">邀请团队</view> -->
|
<!-- <view class="bg-main-color submit" @click="showModalByRef('inviteMasterModal')">邀请团队</view> -->
|
||||||
|
|
|
||||||
|
|
@ -27,7 +27,7 @@
|
||||||
:value="areaMultiIndex" :range-key="'areaName'" :range="areaList">
|
:value="areaMultiIndex" :range-key="'areaName'" :range="areaList">
|
||||||
<view class="flex justify-start">
|
<view class="flex justify-start">
|
||||||
<view class="text-cut search-nav-item-text">
|
<view class="text-cut search-nav-item-text">
|
||||||
{{chosenArea && chosenArea.length ? chosenArea[chosenArea.length - 1].areaName : item.title}}
|
{{chosenArea && chosenArea.length ? chosenArea[2].areaName : item.title}}
|
||||||
</view>
|
</view>
|
||||||
<text class="text-lg"><text class="cuIcon-triangledownfill"></text></text>
|
<text class="text-lg"><text class="cuIcon-triangledownfill"></text></text>
|
||||||
</view>
|
</view>
|
||||||
|
|
@ -38,7 +38,7 @@
|
||||||
:range="categoryList">
|
:range="categoryList">
|
||||||
<view class="flex justify-start">
|
<view class="flex justify-start">
|
||||||
<view class="text-cut search-nav-item-text">
|
<view class="text-cut search-nav-item-text">
|
||||||
{{chosenCategory && chosenCategory.length ? chosenCategory[chosenCategory.length - 1].goodsCategoryName : item.title}}
|
{{chosenCategory && chosenCategory.length ? chosenCategory[2].goodsCategoryName : item.title}}
|
||||||
</view>
|
</view>
|
||||||
<text class="text-lg"><text class="cuIcon-triangledownfill"></text></text>
|
<text class="text-lg"><text class="cuIcon-triangledownfill"></text></text>
|
||||||
</view>
|
</view>
|
||||||
|
|
@ -57,7 +57,7 @@
|
||||||
</view>
|
</view>
|
||||||
<!-- 任务单 -->
|
<!-- 任务单 -->
|
||||||
<view class="margin-lr-sm margin-bottom-lg">
|
<view class="margin-lr-sm margin-bottom-lg">
|
||||||
<view v-for="(task, index) in tasks" :key="index" class="padding bg-white margin-top-sm">
|
<view v-for="(task, index) in tasks" class="padding bg-white margin-top-sm">
|
||||||
<view class="flex justify-between">
|
<view class="flex justify-between">
|
||||||
<view class="text-lg text-bold text-cut" style="width: 70%;">{{task.goodsName}}</view>
|
<view class="text-lg text-bold text-cut" style="width: 70%;">{{task.goodsName}}</view>
|
||||||
<view class="text-right">
|
<view class="text-right">
|
||||||
|
|
@ -68,50 +68,23 @@
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="flex justify-start" v-if="task.tag">
|
<view class="flex justify-start" v-if="task.tag">
|
||||||
<view v-for="(tagContent, index1) in task.tag" :key="index1" class='cu-tag margin-right-xs'>{{tagContent}}</view>
|
<view v-for="(tagContent, index1) in task.tag" class='cu-tag margin-right-xs'>{{tagContent}}</view>
|
||||||
</view>
|
|
||||||
<view>
|
|
||||||
<view v-if="task.consultMode === '01'" class='cu-tag margin-right-xs radius line-main-color margin-top-xs'>合约单</view>
|
|
||||||
<view v-if="task.payType === 1 && task.consultMode !== '01'" class='cu-tag margin-right-xs radius line-main-color margin-top-xs'>到付单</view>
|
|
||||||
<template v-if="task.consultMode === '01'">
|
|
||||||
<view v-if="task.changeMoney" class='cu-tag margin-right-xs radius line-red margin-top-xs'>有待付款</view>
|
|
||||||
<view v-else class='cu-tag margin-right-xs radius line-red margin-top-xs'>款已付清</view>
|
|
||||||
</template>
|
|
||||||
<template v-else>
|
|
||||||
<view v-if="task.changeMoney || task.payStatus != 1" class='cu-tag margin-right-xs radius line-red margin-top-xs'>有待付款</view>
|
|
||||||
<view v-else class='cu-tag margin-right-xs radius line-red margin-top-xs'>款已付清</view>
|
|
||||||
</template>
|
|
||||||
</view>
|
|
||||||
<view class="float-clear"></view>
|
|
||||||
<view class="margin-top-sm order-name">
|
|
||||||
<view>
|
|
||||||
<text class="text-main-color text-lg margin-right-xs"><text class="cuIcon-people"></text></text>
|
|
||||||
<text>姓名:{{task.customerName}}</text>
|
|
||||||
</view>
|
|
||||||
<view v-if="task.insuranceId">
|
|
||||||
<text style="padding-right: 20rpx;">保险要求</text>
|
|
||||||
<text class="text-main-color" data-modal="showInsuranceDetail" @click="showModal($event, task)"> 详情...</text>
|
|
||||||
</view>
|
|
||||||
|
|
||||||
</view>
|
</view>
|
||||||
<view class="margin-top-sm">
|
<view class="margin-top-sm">
|
||||||
<text class="text-main-color text-lg margin-right-xs"><text
|
<text class="text-main-color text-lg margin-right-xs"><text
|
||||||
class="cuIcon-locationfill"></text></text>
|
class="cuIcon-locationfill"></text></text>
|
||||||
<text>{{task.provinceName + task.cityName + task.countryName + task.streetName + task.address}}</text>
|
<text>{{task.address}}</text>
|
||||||
</view>
|
</view>
|
||||||
<view class="margin-top-sm">
|
<view class="margin-top-sm">
|
||||||
<text class="text-main-color text-lg margin-right-xs"><text class="cuIcon-timefill"></text></text>
|
<text class="text-main-color text-lg margin-right-xs"><text class="cuIcon-timefill"></text></text>
|
||||||
<text v-if="task.expectTimeEndFront">期望时间:{{task.expectTimeStartFront + '~' + task.expectTimeEndFront}}</text>
|
<text v-if="task.expectTimeEndFront">{{task.expectTimeStartFront + '~' + task.expectTimeEndFront}}</text>
|
||||||
<text v-else>期望时间:{{task.expectTimeStartFront}}</text>
|
<text v-else>{{task.expectTimeStartFront}}</text>
|
||||||
</view>
|
</view>
|
||||||
<view class="margin-top-sm">
|
<view class="margin-top-sm">
|
||||||
<text class="text-main-color text-lg margin-right-xs"><text class="cuIcon-phone"></text></text>
|
<text class="text-main-color text-lg margin-right-xs"><text class="cuIcon-phone"></text></text>
|
||||||
<text class="margin-right-xs">{{task.customerName}}</text>
|
<text class="margin-right-xs">{{task.customerName}}</text>
|
||||||
<text>{{task.customerPhone.substring(0, 3) + "****" + task.customerPhone.substring(7)}}</text>
|
<text>{{task.customerPhone.substring(0, 3) + "****" + task.customerPhone.substring(7)}}</text>
|
||||||
</view>
|
</view>
|
||||||
<!-- <view class="margin-top-sm" v-if="task.customerRemark">
|
|
||||||
备注:{{task.customerRemark}}
|
|
||||||
</view> -->
|
|
||||||
<view class="padding-top-sm flex justify-end">
|
<view class="padding-top-sm flex justify-end">
|
||||||
<button class="cu-btn bg-main-color margin-right-xs shadow-blur" data-modal="showForwardModal"
|
<button class="cu-btn bg-main-color margin-right-xs shadow-blur" data-modal="showForwardModal"
|
||||||
@click="showModal($event, task)">转发</button>
|
@click="showModal($event, task)">转发</button>
|
||||||
|
|
@ -214,25 +187,21 @@
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<!-- 账户及实名弹窗 -->
|
<!-- 账户及实名弹窗 -->
|
||||||
<vertify-bank-bind ref="vertifyBankBind" text="仍然接单" @stillAcceptOrder="stillAccept"></vertify-bank-bind>
|
<vertify-bank-bind ref="vertifyBankBind"></vertify-bank-bind>
|
||||||
<vertify-certify ref="vertifyCertify" text="仍然接单" @stillAcceptOrder="stillAccept"></vertify-certify>
|
<vertify-certify ref="vertifyCertify"></vertify-certify>
|
||||||
<insurance-detail v-if="showInsuranceDetail" :show="showInsuranceDetail" :data="curTask" @close="showInsuranceDetail = false"></insurance-detail>
|
|
||||||
</view>
|
</view>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import loadStatusBar from '@/components/custom-bar/load-status-bar.vue';
|
import loadStatusBar from '@/components/custom-bar/load-status-bar.vue';
|
||||||
import insuranceDetail from '@/pages/order-manage/modal/insurance-detail.vue';
|
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
components: {
|
components: {
|
||||||
loadStatusBar,
|
loadStatusBar
|
||||||
insuranceDetail
|
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
tabCur: 0,
|
tabCur: 0,
|
||||||
orderType: 0,
|
|
||||||
scrollLeft: 0,
|
scrollLeft: 0,
|
||||||
stickyTop: this.CustomBar,
|
stickyTop: this.CustomBar,
|
||||||
pageNum: 1,
|
pageNum: 1,
|
||||||
|
|
@ -261,7 +230,7 @@
|
||||||
}, {
|
}, {
|
||||||
code: 'reset',
|
code: 'reset',
|
||||||
type: 1,
|
type: 1,
|
||||||
title: '重置/刷新',
|
title: '重置',
|
||||||
action: 'resetConditions'
|
action: 'resetConditions'
|
||||||
}],
|
}],
|
||||||
originTaskConditions: [{
|
originTaskConditions: [{
|
||||||
|
|
@ -307,28 +276,15 @@
|
||||||
chosenCategory: [],
|
chosenCategory: [],
|
||||||
bankCard: null,
|
bankCard: null,
|
||||||
certifyInfo: null,
|
certifyInfo: null,
|
||||||
hasNotice: false,
|
hasNotice: false
|
||||||
workerCityIds: [],
|
|
||||||
workerDistrictIds: [],
|
|
||||||
workerStreetIds: [],
|
|
||||||
workerFirstCategoryIds: [],
|
|
||||||
workerSecondCategoryIds: [],
|
|
||||||
workerThirdCategoryIds: [],
|
|
||||||
showInsuranceDetail: false,
|
|
||||||
workerProvinceIds: []
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
onLoad(option) {
|
onShow() {
|
||||||
if(option && option.orderType) {
|
|
||||||
this.orderType = option.orderType
|
|
||||||
}
|
|
||||||
this.loadData();
|
this.loadData();
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
async loadData() {
|
async loadData() {
|
||||||
this.curUserInfo = this.$request.getCurUserInfo();
|
this.curUserInfo = this.$request.getCurUserInfo();
|
||||||
this.getWorkerAreaIds();
|
|
||||||
await this.getWorkerDataCategoryIds();
|
|
||||||
// this.checkBankAndCertify();
|
// this.checkBankAndCertify();
|
||||||
// this.tasks = await this.$api.data('tasks');
|
// this.tasks = await this.$api.data('tasks');
|
||||||
this.reloadMasterOrderPage();
|
this.reloadMasterOrderPage();
|
||||||
|
|
@ -349,8 +305,6 @@
|
||||||
this.certifyInfo = certifyInfoRes.data;
|
this.certifyInfo = certifyInfoRes.data;
|
||||||
|
|
||||||
let res = true;
|
let res = true;
|
||||||
// this.$refs.vertifyCertify.showModal();
|
|
||||||
// res = false;
|
|
||||||
if (!this.bankCard || !this.bankCard.bankNum) {
|
if (!this.bankCard || !this.bankCard.bankNum) {
|
||||||
this.$refs.vertifyBankBind.showModal();
|
this.$refs.vertifyBankBind.showModal();
|
||||||
res = false;
|
res = false;
|
||||||
|
|
@ -361,75 +315,12 @@
|
||||||
}
|
}
|
||||||
return res;
|
return res;
|
||||||
},
|
},
|
||||||
async getWorkerAreaIds() {
|
|
||||||
let res = await this.$request.getWorkerArea({
|
|
||||||
workerId: this.curUserInfo.workerId,
|
|
||||||
serviceType: this.orderType == 0 ? 1 : 2
|
|
||||||
});
|
|
||||||
|
|
||||||
if(this.orderType == 0 ) {
|
|
||||||
let cityIds = [];
|
|
||||||
let districtIds = [];
|
|
||||||
let streetIds = [];
|
|
||||||
for(let i = 0; i < res.data.length; i++) {
|
|
||||||
if (cityIds.indexOf(res.data[i].cityId) === -1) {
|
|
||||||
cityIds.push(res.data[i].cityId)
|
|
||||||
}
|
|
||||||
if (districtIds.indexOf(res.data[i].districtId) === -1) {
|
|
||||||
districtIds.push(res.data[i].districtId)
|
|
||||||
}
|
|
||||||
if (streetIds.indexOf(res.data[i].streetId) === -1) {
|
|
||||||
streetIds.push(res.data[i].streetId)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
this.workerCityIds = cityIds;
|
|
||||||
this.workerDistrictIds = districtIds;
|
|
||||||
this.workerStreetIds = streetIds;
|
|
||||||
} else {
|
|
||||||
let provinceIds = [];
|
|
||||||
let cityIds = [];
|
|
||||||
for(let i = 0; i < res.data.length; i++) {
|
|
||||||
if (cityIds.indexOf(res.data[i].cityId) === -1) {
|
|
||||||
cityIds.push(res.data[i].cityId)
|
|
||||||
}
|
|
||||||
if (provinceIds.indexOf(res.data[i].provinceId) === -1) {
|
|
||||||
provinceIds.push(res.data[i].provinceId)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
this.workerProvinceIds = provinceIds;
|
|
||||||
this.workerCityIds = cityIds;
|
|
||||||
}
|
|
||||||
},
|
|
||||||
async getWorkerDataCategoryIds() {
|
|
||||||
let res = await this.$request.getWorkerGoodsCategory({
|
|
||||||
workerId: this.curUserInfo.workerId,
|
|
||||||
serviceType: this.orderType == 0 ? 1 : 2
|
|
||||||
});
|
|
||||||
let firstGoodsCategoryIds = [];
|
|
||||||
let secondGoodsCategoryIds = [];
|
|
||||||
let thirdGoodsCategoryIds = [];
|
|
||||||
for(let i = 0; i < res.data.length; i++) {
|
|
||||||
if (firstGoodsCategoryIds.indexOf(res.data[i].goodsCategoryId) === -1) {
|
|
||||||
firstGoodsCategoryIds.push(res.data[i].goodsCategoryId)
|
|
||||||
}
|
|
||||||
if (secondGoodsCategoryIds.indexOf(res.data[i].goodsCategoryId) === -1) {
|
|
||||||
secondGoodsCategoryIds.push(res.data[i].goodsCategoryId)
|
|
||||||
}
|
|
||||||
if (thirdGoodsCategoryIds.indexOf(res.data[i].goodsCategoryId) === -1) {
|
|
||||||
thirdGoodsCategoryIds.push(res.data[i].goodsCategoryId)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
this.workerFirstCategoryIds = firstGoodsCategoryIds;
|
|
||||||
this.workerSecondCategoryIds = secondGoodsCategoryIds;
|
|
||||||
this.workerThirdCategoryIds = thirdGoodsCategoryIds;
|
|
||||||
},
|
|
||||||
async loadMasterOrderPage(params = {}) {
|
async loadMasterOrderPage(params = {}) {
|
||||||
params.pageSize = this.$globalData.initPageSize;
|
params.pageSize = this.$globalData.initPageSize;
|
||||||
params.pageNum = this.pageNum;
|
params.pageNum = this.pageNum;
|
||||||
params.orderStatus = 0;
|
params.orderStatus = 0;
|
||||||
params.workerId = -1;
|
params.workerId = -1;
|
||||||
params.goodsName = this.inputGoodsName;
|
params.goodsName = this.inputGoodsName;
|
||||||
params.orderType = this.orderType;
|
|
||||||
this.taskConditions.forEach((condition) => {
|
this.taskConditions.forEach((condition) => {
|
||||||
if (condition.type === 2) {
|
if (condition.type === 2) {
|
||||||
params[condition.code] = condition.value;
|
params[condition.code] = condition.value;
|
||||||
|
|
@ -439,36 +330,6 @@
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
// 区域条件
|
|
||||||
params.cityIds = this.workerCityIds;
|
|
||||||
if (this.chosenArea.length === 1) {
|
|
||||||
// 选中了区列表中的全部选项
|
|
||||||
params.cityIds = [this.chosenArea[0].areaId]
|
|
||||||
} else if (this.chosenArea.length === 2) {
|
|
||||||
// 选中了街道列表中的全部选项
|
|
||||||
params.districtIds = [this.chosenArea[1].areaId]
|
|
||||||
} else if (this.chosenArea.length === 3) {
|
|
||||||
// 选中了某个具体的街道
|
|
||||||
params.districtIds = [this.chosenArea[1].areaId];
|
|
||||||
params.streetIds = [this.chosenArea[2].areaId];
|
|
||||||
}
|
|
||||||
|
|
||||||
// 类目条件
|
|
||||||
params.thirdGoodsCategoryIds = this.workerThirdCategoryIds;
|
|
||||||
if (this.chosenCategory.length === 1) {
|
|
||||||
// 选了一级类目
|
|
||||||
params.firstGoodsCategoryIds = [this.chosenCategory[0].goodsCategoryId];
|
|
||||||
} else if (this.chosenCategory.length === 2) {
|
|
||||||
// 选了二级类目
|
|
||||||
params.firstGoodsCategoryIds = [this.chosenCategory[0].goodsCategoryId];
|
|
||||||
params.secondGoodsCategoryIds = [this.chosenCategory[1].goodsCategoryId];
|
|
||||||
} else if (this.chosenArea.length === 3) {
|
|
||||||
// 选了三级类目
|
|
||||||
params.firstGoodsCategoryIds = [this.chosenCategory[0].goodsCategoryId];
|
|
||||||
params.secondGoodsCategoryIds = [this.chosenCategory[1].goodsCategoryId];
|
|
||||||
params.thirdGoodsCategoryIds = [this.chosenCategory[2].goodsCategoryId];
|
|
||||||
}
|
|
||||||
|
|
||||||
this.$refs.loadStatusBar.showLoading();
|
this.$refs.loadStatusBar.showLoading();
|
||||||
try {
|
try {
|
||||||
let res = await this.$request.qryMasterOrderPage(params);
|
let res = await this.$request.qryMasterOrderPage(params);
|
||||||
|
|
@ -513,109 +374,51 @@
|
||||||
},
|
},
|
||||||
async loadCategoryList(idArr) {
|
async loadCategoryList(idArr) {
|
||||||
let typeList = await this.$request.listByStep({
|
let typeList = await this.$request.listByStep({
|
||||||
type: this.orderType == 0 ? 1 : 2
|
type: 1
|
||||||
});
|
});
|
||||||
typeList = typeList.data;
|
typeList = typeList.data;
|
||||||
let col1Id = idArr ? idArr[0] : typeList[0].goodsCategoryId;
|
let col1Id = idArr ? idArr[0] : typeList[0].goodsCategoryId;
|
||||||
let subTypeList = await this.$request.listByStep({
|
let subTypeList = await this.$request.listByStep({
|
||||||
type: this.orderType == 0 ? 1 : 2,
|
type: 1,
|
||||||
goodsCategoryId: col1Id
|
goodsCategoryId: col1Id
|
||||||
});
|
});
|
||||||
subTypeList = subTypeList.data;
|
subTypeList = subTypeList.data;
|
||||||
let col2Id = idArr ? idArr[1] : subTypeList[0].goodsCategoryId;
|
let col2Id = idArr ? idArr[1] : subTypeList[0].goodsCategoryId;
|
||||||
let subSubTypeList = await this.$request.listByStep({
|
let subSubTypeList = await this.$request.listByStep({
|
||||||
type: this.orderType == 0 ? 1 : 2,
|
type: 1,
|
||||||
goodsCategoryId: col2Id
|
goodsCategoryId: col2Id
|
||||||
});
|
});
|
||||||
subSubTypeList = subSubTypeList.data;
|
subSubTypeList = subSubTypeList.data;
|
||||||
let col3Id = idArr ? idArr[2] : subSubTypeList[0].goodsCategoryId;
|
let col3Id = idArr ? idArr[2] : subSubTypeList[0].goodsCategoryId;
|
||||||
let thirdTypeList = await this.$request.listByStep({
|
let thirdTypeList = await this.$request.listByStep({
|
||||||
type: this.orderType == 0 ? 1 : 2,
|
type: 1,
|
||||||
goodsCategoryId: col3Id
|
goodsCategoryId: col3Id
|
||||||
});
|
});
|
||||||
thirdTypeList = thirdTypeList.data;
|
thirdTypeList = thirdTypeList.data;
|
||||||
|
|
||||||
// 加上“全部”节点
|
|
||||||
subTypeList.unshift({
|
|
||||||
goodsCategoryName: '全部',
|
|
||||||
goodsCategoryId: -1
|
|
||||||
});
|
|
||||||
subSubTypeList.unshift({
|
|
||||||
goodsCategoryName: '全部',
|
|
||||||
goodsCategoryId: -1
|
|
||||||
});
|
|
||||||
thirdTypeList.unshift({
|
|
||||||
goodsCategoryName: '全部',
|
|
||||||
goodsCategoryId: -1
|
|
||||||
});
|
|
||||||
this.categoryList.push(subTypeList);
|
this.categoryList.push(subTypeList);
|
||||||
this.categoryList.push(subSubTypeList);
|
this.categoryList.push(subSubTypeList);
|
||||||
this.categoryList.push(thirdTypeList);
|
this.categoryList.push(thirdTypeList);
|
||||||
},
|
},
|
||||||
async loadRegionList() {
|
async loadRegionList() {
|
||||||
if(this.orderType == 0) {
|
let regionList = await this.$request.areaListByStep();
|
||||||
let regionList = await this.$request.areaListByStep({
|
|
||||||
areaIds: this.workerCityIds,
|
|
||||||
parentCode: ''
|
|
||||||
});
|
|
||||||
regionList = regionList.data;
|
regionList = regionList.data;
|
||||||
let subRegionList = [];
|
let subRegionList = [];
|
||||||
let subSubRegionList = [];
|
let subSubRegionList = [];
|
||||||
if (regionList && regionList.length > 0) {
|
if (regionList && regionList.length > 0) {
|
||||||
subRegionList = await this.$request.areaListByStep({
|
subRegionList = await this.$request.areaListByStep({
|
||||||
parentCode: regionList[0].areaCode,
|
parentCode: regionList[0].areaCode
|
||||||
areaIds: this.workerDistrictIds
|
|
||||||
});
|
});
|
||||||
subRegionList = subRegionList.data;
|
subRegionList = subRegionList.data;
|
||||||
}
|
}
|
||||||
if (subRegionList && subRegionList.length > 0) {
|
if (subRegionList && subRegionList.length > 0) {
|
||||||
subSubRegionList = await this.$request.areaListByStep({
|
subSubRegionList = await this.$request.areaListByStep({
|
||||||
parentCode: subRegionList[0].areaCode,
|
parentCode: subRegionList[0].areaCode
|
||||||
areaIds: this.workerStreetIds
|
|
||||||
});
|
});
|
||||||
subSubRegionList = subSubRegionList.data;
|
subSubRegionList = subSubRegionList.data;
|
||||||
}
|
}
|
||||||
// 加上“全部”节点
|
|
||||||
regionList.unshift({
|
|
||||||
areaName: '全部',
|
|
||||||
areaId: -1
|
|
||||||
});
|
|
||||||
subRegionList.unshift({
|
|
||||||
areaName: '全部',
|
|
||||||
areaId: -1
|
|
||||||
});
|
|
||||||
subSubRegionList.unshift({
|
|
||||||
areaName: '全部',
|
|
||||||
areaId: -1
|
|
||||||
});
|
|
||||||
this.areaList.push(regionList);
|
this.areaList.push(regionList);
|
||||||
this.areaList.push(subRegionList);
|
this.areaList.push(subRegionList);
|
||||||
this.areaList.push(subSubRegionList);
|
this.areaList.push(subSubRegionList);
|
||||||
} else {
|
|
||||||
let regionList = await this.$request.areaListByStep({
|
|
||||||
areaIds: this.workerProvinceIds,
|
|
||||||
parentCode: ''
|
|
||||||
});
|
|
||||||
regionList = regionList.data;
|
|
||||||
let subRegionList = [];
|
|
||||||
if (regionList && regionList.length > 0) {
|
|
||||||
subRegionList = await this.$request.areaListByStep({
|
|
||||||
parentCode: regionList[0].areaCode,
|
|
||||||
areaIds: this.workerCityIds
|
|
||||||
});
|
|
||||||
subRegionList = subRegionList.data;
|
|
||||||
}
|
|
||||||
regionList.unshift({
|
|
||||||
areaName: '全部',
|
|
||||||
areaId: -1
|
|
||||||
});
|
|
||||||
subRegionList.unshift({
|
|
||||||
areaName: '全部',
|
|
||||||
areaId: -1
|
|
||||||
});
|
|
||||||
this.areaList.push(regionList);
|
|
||||||
this.areaList.push(subRegionList);
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
searchTasks() {
|
searchTasks() {
|
||||||
this.reloadMasterOrderPage();
|
this.reloadMasterOrderPage();
|
||||||
|
|
@ -634,41 +437,23 @@
|
||||||
this.areaMultiIndex = e.detail.value;
|
this.areaMultiIndex = e.detail.value;
|
||||||
let chosenArea = [];
|
let chosenArea = [];
|
||||||
for (let i = 0; i < this.areaList.length; i++) {
|
for (let i = 0; i < this.areaList.length; i++) {
|
||||||
if (this.areaMultiIndex[i] === 0) {
|
|
||||||
// 选中了全部节点
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
chosenArea.push(this.areaList[i][this.areaMultiIndex[i]]);
|
chosenArea.push(this.areaList[i][this.areaMultiIndex[i]]);
|
||||||
}
|
}
|
||||||
this.chosenArea = chosenArea;
|
this.chosenArea = chosenArea;
|
||||||
// this.taskConditions[this.tabCur].value = chosenArea[chosenArea.length - 1].areaId;
|
this.taskConditions[this.tabCur].value = chosenArea[chosenArea.length - 1].areaId;
|
||||||
this.searchTasks();
|
this.searchTasks();
|
||||||
},
|
},
|
||||||
async regionColChange(e) {
|
async regionColChange(e) {
|
||||||
let colObj = e.detail;
|
let colObj = e.detail;
|
||||||
if(this.orderType == 0) {
|
|
||||||
if (colObj.column == 0) {
|
if (colObj.column == 0) {
|
||||||
// 通过一级查二级
|
// 通过一级查二级
|
||||||
let subAreaList = await this.$request.areaListByStep({parentCode: this.areaList[0][colObj.value].areaCode, areaIds: this.workerDistrictIds});
|
let subAreaList = await this.$request.areaListByStep({parentCode: this.areaList[0][colObj.value].areaCode});
|
||||||
subAreaList = subAreaList.data;
|
subAreaList = subAreaList.data;
|
||||||
let subSubAreaList = [];
|
let subSubAreaList = [];
|
||||||
if (subAreaList.length) {
|
if (subAreaList.length) {
|
||||||
subSubAreaList = await this.$request.areaListByStep({parentCode: subAreaList[0].areaCode, areaIds: this.workerStreetIds});
|
subSubAreaList = await this.$request.areaListByStep({parentCode: subAreaList[0].areaCode});
|
||||||
subSubAreaList = subSubAreaList.data;
|
subSubAreaList = subSubAreaList.data;
|
||||||
}
|
}
|
||||||
// 加上“全部”节点
|
|
||||||
if (subAreaList.length > 0) {
|
|
||||||
subAreaList.unshift({
|
|
||||||
areaName: '全部',
|
|
||||||
areaId: -1
|
|
||||||
});
|
|
||||||
}
|
|
||||||
if (subSubAreaList.length > 0) {
|
|
||||||
subSubAreaList.unshift({
|
|
||||||
areaName: '全部',
|
|
||||||
areaId: -1
|
|
||||||
});
|
|
||||||
}
|
|
||||||
this.areaList.pop();
|
this.areaList.pop();
|
||||||
this.areaList.pop();
|
this.areaList.pop();
|
||||||
this.areaList.push(subAreaList);
|
this.areaList.push(subAreaList);
|
||||||
|
|
@ -676,35 +461,21 @@
|
||||||
this.areaMultiIndex = [colObj.value, 0, 0];
|
this.areaMultiIndex = [colObj.value, 0, 0];
|
||||||
} else if (colObj.column == 1) {
|
} else if (colObj.column == 1) {
|
||||||
// 通过二级查三级
|
// 通过二级查三级
|
||||||
let subAreaList = await this.$request.areaListByStep({parentCode: this.areaList[1][colObj.value].areaCode, areaIds: this.workerStreetIds});
|
let subAreaList = await this.$request.areaListByStep({parentCode: this.areaList[1][colObj.value].areaCode});
|
||||||
subAreaList = subAreaList.data;
|
subAreaList = subAreaList.data;
|
||||||
// 加上“全部”节点
|
|
||||||
if (subAreaList.length > 0) {
|
|
||||||
subAreaList.unshift({
|
|
||||||
areaName: '全部',
|
|
||||||
areaId: -1
|
|
||||||
});
|
|
||||||
}
|
|
||||||
this.areaList.pop();
|
this.areaList.pop();
|
||||||
this.areaList.push(subAreaList);
|
this.areaList.push(subAreaList);
|
||||||
this.areaMultiIndex = [this.areaMultiIndex[0], colObj.value, 0];
|
this.areaMultiIndex = [this.areaMultiIndex[0], colObj.value, 0];
|
||||||
}
|
}
|
||||||
} else {
|
|
||||||
// 商品改变
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
async categoryChange(e) {
|
async categoryChange(e) {
|
||||||
this.categoryMultiIndex = e.detail.value;
|
this.categoryMultiIndex = e.detail.value;
|
||||||
let chosenCategory = [];
|
let chosenCategory = [];
|
||||||
for (let i = 0; i < this.categoryList.length; i++) {
|
for (let i = 0; i < this.categoryList.length; i++) {
|
||||||
if (this.categoryMultiIndex[i] === 0) {
|
|
||||||
// 选中了全部节点
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
chosenCategory.push(this.categoryList[i][this.categoryMultiIndex[i]]);
|
chosenCategory.push(this.categoryList[i][this.categoryMultiIndex[i]]);
|
||||||
}
|
}
|
||||||
this.chosenCategory = chosenCategory;
|
this.chosenCategory = chosenCategory;
|
||||||
// this.taskConditions[this.tabCur].value = chosenCategory[chosenCategory.length - 1].goodsCategoryId;
|
this.taskConditions[this.tabCur].value = chosenCategory[chosenCategory.length - 1].goodsCategoryId;
|
||||||
this.searchTasks();
|
this.searchTasks();
|
||||||
},
|
},
|
||||||
async categoryColChange(e) {
|
async categoryColChange(e) {
|
||||||
|
|
@ -712,27 +483,18 @@
|
||||||
if (colObj.column == 0) {
|
if (colObj.column == 0) {
|
||||||
// 通过一级查询二级
|
// 通过一级查询二级
|
||||||
let subTypeList = await this.$request.listByStep({
|
let subTypeList = await this.$request.listByStep({
|
||||||
type: this.orderType == 0 ? 1 : 2,
|
type: 1,
|
||||||
goodsCategoryId: this.categoryList[0][colObj.value].goodsCategoryId
|
goodsCategoryId: this.categoryList[0][colObj.value].goodsCategoryId
|
||||||
});
|
});
|
||||||
subTypeList = subTypeList.data;
|
subTypeList = subTypeList.data;
|
||||||
let subSubTypeList = [];
|
let subSubTypeList = [];
|
||||||
if (subTypeList && subTypeList.length) {
|
if (subTypeList && subTypeList.length) {
|
||||||
subSubTypeList = await this.$request.listByStep({
|
subSubTypeList = await this.$request.listByStep({
|
||||||
type: this.orderType == 0 ? 1 : 2,
|
type: 1,
|
||||||
goodsCategoryId: subTypeList[0].goodsCategoryId
|
goodsCategoryId: subTypeList[0].goodsCategoryId
|
||||||
});
|
});
|
||||||
subSubTypeList = subSubTypeList.data;
|
subSubTypeList = subSubTypeList.data;
|
||||||
}
|
}
|
||||||
// 加上“全部”节点
|
|
||||||
subTypeList.unshift({
|
|
||||||
goodsCategoryName: '全部',
|
|
||||||
goodsCategoryId: -1
|
|
||||||
});
|
|
||||||
subSubTypeList.unshift({
|
|
||||||
goodsCategoryName: '全部',
|
|
||||||
goodsCategoryId: -1
|
|
||||||
});
|
|
||||||
this.categoryList.pop();
|
this.categoryList.pop();
|
||||||
this.categoryList.pop();
|
this.categoryList.pop();
|
||||||
this.categoryList.push(subTypeList);
|
this.categoryList.push(subTypeList);
|
||||||
|
|
@ -741,15 +503,10 @@
|
||||||
} else if (colObj.column == 1) {
|
} else if (colObj.column == 1) {
|
||||||
// 通过二级查三级
|
// 通过二级查三级
|
||||||
let subSubTypeList = await this.$request.listByStep({
|
let subSubTypeList = await this.$request.listByStep({
|
||||||
type: this.orderType == 0 ? 1 : 2,
|
type: 1,
|
||||||
goodsCategoryId: this.categoryList[1][colObj.value].goodsCategoryId
|
goodsCategoryId: this.categoryList[1][colObj.value].goodsCategoryId
|
||||||
});
|
});
|
||||||
subSubTypeList = subSubTypeList.data;
|
subSubTypeList = subSubTypeList.data;
|
||||||
// 加上“全部”节点
|
|
||||||
subSubTypeList.unshift({
|
|
||||||
goodsCategoryName: '全部',
|
|
||||||
goodsCategoryId: -1
|
|
||||||
});
|
|
||||||
this.categoryList.pop();
|
this.categoryList.pop();
|
||||||
this.categoryList.push(subSubTypeList);
|
this.categoryList.push(subSubTypeList);
|
||||||
this.categoryMultiIndex = [this.categoryMultiIndex[0], colObj.value, 0];
|
this.categoryMultiIndex = [this.categoryMultiIndex[0], colObj.value, 0];
|
||||||
|
|
@ -757,8 +514,7 @@
|
||||||
},
|
},
|
||||||
showDemandDetail(e, task) {
|
showDemandDetail(e, task) {
|
||||||
let paramObj = {
|
let paramObj = {
|
||||||
orderMasterId: task.orderMasterId,
|
orderMasterId: task.orderMasterId
|
||||||
orderType: this.orderType
|
|
||||||
}
|
}
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url: '/pages/demand-center/demand-detail?paramObj=' + encodeURIComponent(JSON.stringify(
|
url: '/pages/demand-center/demand-detail?paramObj=' + encodeURIComponent(JSON.stringify(
|
||||||
|
|
@ -766,7 +522,6 @@
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
async takeTask(e, task) {
|
async takeTask(e, task) {
|
||||||
this.curTask = task;
|
|
||||||
if (!this.hasNotice) {
|
if (!this.hasNotice) {
|
||||||
let checkRes = await this.checkBankAndCertify();
|
let checkRes = await this.checkBankAndCertify();
|
||||||
this.hasNotice = true;
|
this.hasNotice = true;
|
||||||
|
|
@ -787,40 +542,13 @@
|
||||||
}
|
}
|
||||||
this.showModal(e, task);
|
this.showModal(e, task);
|
||||||
},
|
},
|
||||||
async stillAccept() {
|
|
||||||
// this.showModal({currentTarget:{dataset: {modal : 'showTakeSuccessModal'}}}, this.curTask);
|
|
||||||
// console.log('still order',{
|
|
||||||
// workerId: this.curUserInfo.workerId,
|
|
||||||
// id: this.curTask.orderMasterId,
|
|
||||||
// orderStatus: 1
|
|
||||||
// });
|
|
||||||
// return;
|
|
||||||
// 已认证可直接接单
|
|
||||||
let res = await this.$request.updateOrder({
|
|
||||||
workerId: this.curUserInfo.workerId,
|
|
||||||
id: this.curTask.orderMasterId,
|
|
||||||
orderStatus: 1
|
|
||||||
});
|
|
||||||
if(res.code !== 0) return;
|
|
||||||
this.reloadMasterOrderPage();
|
|
||||||
this.showModal({currentTarget:{dataset: {modal : 'showTakeSuccessModal'}}}, this.curTask);
|
|
||||||
},
|
|
||||||
contactCustomer(e) {
|
contactCustomer(e) {
|
||||||
// uni.makePhoneCall({
|
// uni.makePhoneCall({
|
||||||
// phoneNumber: this.curTask.customerPhone
|
// phoneNumber: this.curTask.customerPhone
|
||||||
// })
|
// })
|
||||||
// uni.navigateTo({
|
|
||||||
// url: '/pages/order-manage/order-manage'
|
|
||||||
// })
|
|
||||||
if(this.orderType == 0) {
|
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url: '/pages/order-manage/order-manage?orderType=0'
|
url: '/pages/order-manage/order-manage'
|
||||||
})
|
})
|
||||||
} else {
|
|
||||||
uni.navigateTo({
|
|
||||||
url: '/pages/order-manage/order-manage-parts?orderType=1'
|
|
||||||
})
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
goToCertify() {
|
goToCertify() {
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
|
|
|
||||||
|
|
@ -20,12 +20,12 @@
|
||||||
</view>
|
</view>
|
||||||
<view class="margin-top-sm">
|
<view class="margin-top-sm">
|
||||||
<text class="text-main-color text-lg margin-right-xs"><text class="cuIcon-locationfill"></text></text>
|
<text class="text-main-color text-lg margin-right-xs"><text class="cuIcon-locationfill"></text></text>
|
||||||
<text>{{order.provinceName + order.cityName + order.countryName + order.streetName + order.address}}</text>
|
<text>{{order.address}}</text>
|
||||||
</view>
|
</view>
|
||||||
<view class="margin-top-sm">
|
<view class="margin-top-sm">
|
||||||
<text class="text-main-color text-lg margin-right-xs"><text class="cuIcon-timefill"></text></text>
|
<text class="text-main-color text-lg margin-right-xs"><text class="cuIcon-timefill"></text></text>
|
||||||
<text v-if="order.expectTimeEndFront">期望时间:{{order.expectTimeStartFront + '~' + order.expectTimeEndFront}}</text>
|
<text v-if="order.expectTimeEndFront">{{order.expectTimeStartFront + '~' + order.expectTimeEndFront}}</text>
|
||||||
<text v-else>期望时间:{{order.expectTimeStartFront}}</text>
|
<text v-else>{{order.expectTimeStartFront}}</text>
|
||||||
</view>
|
</view>
|
||||||
<view class="margin-top-sm">
|
<view class="margin-top-sm">
|
||||||
<text class="text-main-color text-lg margin-right-xs"><text class="cuIcon-phone"></text></text>
|
<text class="text-main-color text-lg margin-right-xs"><text class="cuIcon-phone"></text></text>
|
||||||
|
|
@ -48,7 +48,7 @@
|
||||||
</view>
|
</view>
|
||||||
<view class="margin-bottom-sm"><text class="text-bold">订单编码:</text>{{order.orderMasterCode}}</view>
|
<view class="margin-bottom-sm"><text class="text-bold">订单编码:</text>{{order.orderMasterCode}}</view>
|
||||||
<view class="margin-bottom-sm"><text class="text-bold">订单时间:</text>{{order.createTime}}</view>
|
<view class="margin-bottom-sm"><text class="text-bold">订单时间:</text>{{order.createTime}}</view>
|
||||||
<view class="margin-bottom-sm"><text class="text-bold">备注:</text>{{order.customerRemark}}</view>
|
<view class="margin-bottom-sm"><text class="text-bold">备注:</text>{{order.remark}}</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="cu-bar tabbar border shop fixed-bottom-bar">
|
<view class="cu-bar tabbar border shop fixed-bottom-bar">
|
||||||
|
|
@ -188,16 +188,9 @@
|
||||||
// uni.makePhoneCall({
|
// uni.makePhoneCall({
|
||||||
// phoneNumber: this.order.customerPhone
|
// phoneNumber: this.order.customerPhone
|
||||||
// })
|
// })
|
||||||
|
|
||||||
if(this.initParam.orderType === 1) {
|
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url: '/pages/order-manage/order-manage-parts?orderType=1'
|
url: '/pages/order-manage/order-manage'
|
||||||
})
|
})
|
||||||
} else {
|
|
||||||
uni.navigateTo({
|
|
||||||
url: '/pages/order-manage/order-manage?orderType=0'
|
|
||||||
})
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -7,104 +7,16 @@
|
||||||
</cu-custom>
|
</cu-custom>
|
||||||
<!-- 规则内容 -->
|
<!-- 规则内容 -->
|
||||||
<view class="padding bg-white">
|
<view class="padding bg-white">
|
||||||
<view v-if="!hasCheckedRule">
|
|
||||||
<!-- v-if="hasCheckedRule" -->
|
|
||||||
<text style="color: red;">进入接单大厅前,请先阅读并了解本服务规则标准,有利于以良好的服务定位进行服务工作,阅读学习后请打勾并确认。本规则后续可在主页右上角“服务规则”处查看。</text>
|
|
||||||
</view>
|
|
||||||
<view style="padding: 10upx 0;">
|
|
||||||
<text style="font-weight: 500;">接单规则:【晚19点至早8点不计超时】</text>
|
|
||||||
</view>
|
|
||||||
<checkbox-group class="block" @change="checkRule">
|
<checkbox-group class="block" @change="checkRule">
|
||||||
<view class="flex justify-start align-start margin-top-xs" v-for="(item, index) in masterRules" :key="index">
|
<view class="flex justify-start align-start margin-top-xs" v-for="(item, index) in masterRules">
|
||||||
<checkbox style="transform:scale(0.7)" class="main-color" :checked="hasCheckedRule" value='1'>
|
<checkbox style="transform:scale(0.7)" class="main-color" :checked="hasCheckedRule" value='1'>
|
||||||
</checkbox>
|
</checkbox>
|
||||||
<text>{{item}}</text>
|
<text>{{item}}</text>
|
||||||
</view>
|
</view>
|
||||||
<view style="padding: 10upx 0;">
|
|
||||||
<text style="font-weight: 500;">服务流程:</text>
|
|
||||||
</view>
|
|
||||||
<view class="flex justify-start align-start margin-top-xs">
|
|
||||||
<checkbox style="transform:scale(0.7)" class="main-color" :checked="hasCheckedRule" value='1'>
|
|
||||||
</checkbox>
|
|
||||||
<text>对话文明有礼(电话及上门会面时)、工服/鞋套/口罩齐备、设备工具/防护/地垫齐全;事前有试机、流程有沟通有确认、问题指出留证据、完工有复查、卫生全干净、客户现场给意见/验收/评价到位再出门(杜绝二次上门及投诉发生率)</text>
|
|
||||||
</view>
|
|
||||||
<view style="padding: 10upx 0;">
|
|
||||||
<text style="font-weight: 500;">异常处理:</text>
|
|
||||||
</view>
|
|
||||||
<view class="flex justify-start align-start margin-top-xs">
|
|
||||||
<checkbox style="transform:scale(0.7)" class="main-color" :checked="hasCheckedRule" value='1'>
|
|
||||||
</checkbox>
|
|
||||||
<text>客户异常:不同时间段多次联系未成功,短信留言客户,并点“无法排单”上传拔打记录或短信截图,均定性为客户原因;约定的上门不成功的,与客户重新约定重新排单。</text>
|
|
||||||
</view>
|
|
||||||
<view class="flex justify-start align-start margin-top-xs">
|
|
||||||
<checkbox style="transform:scale(0.7)" class="main-color" :checked="hasCheckedRule" value='1'>
|
|
||||||
</checkbox>
|
|
||||||
<text>师傅异常:因故未能上门,提前与客户协商,同意后点“重新排单”改上门时间,未能谈妥的,报客服处;被投诉无故迟到或未上门或完全不同意师傅的上门时间,你全责。</text>
|
|
||||||
</view>
|
|
||||||
<view class="flex justify-start align-start margin-top-xs">
|
|
||||||
<checkbox style="transform:scale(0.7)" class="main-color" :checked="hasCheckedRule" value='1'>
|
|
||||||
</checkbox>
|
|
||||||
<text>异常通报:非师傅原因的服务有问题时,对客户表达到位,否则可能被定义为技能差从而投诉,非师傅的异常,指出后留证据先报至平台,避免师傅责任!</text>
|
|
||||||
</view>
|
|
||||||
<view style="padding: 10upx 0;">
|
|
||||||
<text style="font-weight: 500;">六不红线:</text>
|
|
||||||
</view>
|
|
||||||
<view class="flex justify-start align-start margin-top-xs">
|
|
||||||
<checkbox style="transform:scale(0.7)" class="main-color" :checked="hasCheckedRule" value='1'>
|
|
||||||
</checkbox>
|
|
||||||
<text>①代表品牌上门时,不以其它身份沟通;</text>
|
|
||||||
</view>
|
|
||||||
<view class="flex justify-start align-start margin-top-xs">
|
|
||||||
<checkbox style="transform:scale(0.7)" class="main-color" :checked="hasCheckedRule" value='1'>
|
|
||||||
</checkbox>
|
|
||||||
<text>②不谈论产品价格及服务费用;</text>
|
|
||||||
</view>
|
|
||||||
<view class="flex justify-start align-start margin-top-xs">
|
|
||||||
<checkbox style="transform:scale(0.7)" class="main-color" :checked="hasCheckedRule" value='1'>
|
|
||||||
</checkbox>
|
|
||||||
<text>③不发表与服务无关的言论;</text>
|
|
||||||
</view>
|
|
||||||
<view class="flex justify-start align-start margin-top-xs">
|
|
||||||
<checkbox style="transform:scale(0.7)" class="main-color" :checked="hasCheckedRule" value='1'>
|
|
||||||
</checkbox>
|
|
||||||
<text>④不撬订单,否则一定会被品牌方追究;</text>
|
|
||||||
</view>
|
|
||||||
<view class="flex justify-start align-start margin-top-xs">
|
|
||||||
<checkbox style="transform:scale(0.7)" class="main-color" :checked="hasCheckedRule" value='1'>
|
|
||||||
</checkbox>
|
|
||||||
<text>⑤不得发生争吵,争吵无论对错,师傅全责;</text>
|
|
||||||
</view>
|
|
||||||
<view class="flex justify-start align-start margin-top-xs">
|
|
||||||
<checkbox style="transform:scale(0.7)" class="main-color" :checked="hasCheckedRule" value='1'>
|
|
||||||
</checkbox>
|
|
||||||
<text>⑥不得使用客户家里损耗类物品。</text>
|
|
||||||
</view>
|
|
||||||
|
|
||||||
<view style="padding: 10upx 0;">
|
|
||||||
<text style="font-weight: 500;">沟通原则:</text>
|
|
||||||
</view>
|
|
||||||
<view class="flex justify-start align-start margin-top-xs">
|
|
||||||
<checkbox style="transform:scale(0.7)" class="main-color" :checked="hasCheckedRule" value='1'>
|
|
||||||
</checkbox>
|
|
||||||
<text>服务前及服务中,存在沟通分岐问题不能说“不知道”、“不关我事”、“你退单”等缺失服务水平言语,有分岐应该客气和平的处理,不要反复去证明客户错了,遇事只提出你的积极解决方案,以解决完事为准则。如超能力处理范围或客户要求确实过份可说“抱歉,这个问题我现在反映给公司为您处理”,公司或平台客服接手后,须离开的与客户打个招呼,否则未确认接手及未打招呼离开或丢下不管,客诉你全责。</text>
|
|
||||||
</view>
|
|
||||||
|
|
||||||
<view style="padding: 10upx 0;">
|
|
||||||
<text style="font-weight: 500;">客诉界定:</text>
|
|
||||||
</view>
|
|
||||||
<view class="flex justify-start align-start margin-top-xs">
|
|
||||||
<checkbox style="transform:scale(0.7)" class="main-color" :checked="hasCheckedRule" value='1'>
|
|
||||||
</checkbox>
|
|
||||||
<text>客诉无小事,重要不属师傅的责任,那都不是事。属师傅责任,那就都是事。有责的客诉,将被追责,最高按订单额10%-50%或1000元处罚或赔偿损失(以实际事实为准)。</text>
|
|
||||||
</view>
|
|
||||||
|
|
||||||
</checkbox-group>
|
</checkbox-group>
|
||||||
<view class="margin-top-xl">总结【约单迅速,上门准时,友好客气,分清责任,不踩红线,流程沟通,验收评价,完单复查,前后确认】</view>
|
<view class="margin-top-xl">总结【约单迅速,上门准时,友好客气,分清责任,不踩红线,流程沟通,验收评价,完单复查,前后确认】</view>
|
||||||
<!-- 操作按钮 -->
|
<!-- 操作按钮 -->
|
||||||
<view class="margin-top-lg" style="text-align: center;" v-if="!hasCheckedRule">
|
<view class="cu-bar tabbar border shop margin-top-lg">
|
||||||
<text>我已认真阅读并知晓规则</text>
|
|
||||||
</view>
|
|
||||||
<view class="cu-bar tabbar border shop">
|
|
||||||
<button class="cu-btn bg-main-color long-btn margin-lr-sm" type="" :disabled="hasCheckedRule"
|
<button class="cu-btn bg-main-color long-btn margin-lr-sm" type="" :disabled="hasCheckedRule"
|
||||||
@click="acceptRules">{{hasCheckedRule ? '已同意' : '同意'}}</button>
|
@click="acceptRules">{{hasCheckedRule ? '已同意' : '同意'}}</button>
|
||||||
</view>
|
</view>
|
||||||
|
|
@ -146,22 +58,19 @@
|
||||||
checkedTimes++;
|
checkedTimes++;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (checkedTimes === 17) {
|
if (checkedTimes === this.masterRules.length) {
|
||||||
uni.showToast({
|
uni.showToast({
|
||||||
icon: 'success',
|
icon: 'success',
|
||||||
mask: true
|
mask: true
|
||||||
})
|
})
|
||||||
uni.setStorageSync('hasCheckedRule', 1)
|
|
||||||
if (this.navigate) {
|
if (this.navigate) {
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url: '/pages/demand-center/accept-demand-center'
|
url: '/pages/demand-center/accept-demand-center'
|
||||||
})
|
})
|
||||||
} else {
|
|
||||||
uni.navigateBack()
|
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
uni.showToast({
|
uni.showToast({
|
||||||
title: '请逐条阅读并在框内打勾,完成规则学习',
|
title: '请逐条阅读,并在框内打勾,完成规则学习',
|
||||||
icon: 'none',
|
icon: 'none',
|
||||||
mask: true
|
mask: true
|
||||||
})
|
})
|
||||||
|
|
|
||||||
|
|
@ -18,15 +18,14 @@
|
||||||
<!-- 条件筛选栏 -->
|
<!-- 条件筛选栏 -->
|
||||||
<view class="padding bg-white solid-bottom">
|
<view class="padding bg-white solid-bottom">
|
||||||
<view class="flex justify-between align-center">
|
<view class="flex justify-between align-center">
|
||||||
<input class="line-input radius-input" v-model="keywords" :placeholder="tabCur == 0 ? '可搜索服务名称/标题或城市名或区县名' : '可搜索商品名称/标题或城市名或区县名'"></input>
|
<input class="line-input radius-input" v-model="formData.keywords" placeholder="请输入关键字"></input>
|
||||||
<button class="cu-btn bg-main-color shadow-blur" @click="reloadData">搜索</button>
|
<button class="cu-btn bg-main-color shadow-blur">搜索</button>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<!-- tab content -->
|
<!-- tab content -->
|
||||||
<view>
|
<view>
|
||||||
<view class="padding bg-white margin-top-sm margin-lr-sm name-card" v-for="(good, index) in goodsList" :key="good.id">
|
<view class="padding bg-white margin-top-sm margin-lr-sm name-card" v-for="(good, index) in goodsList" v-if="good.status !== 2">
|
||||||
<template v-if="good.status !== 2">
|
|
||||||
<view class="flex justify-start">
|
<view class="flex justify-start">
|
||||||
<view class="cu-avatar xxl-view" :style="'background-image:url(' + good.goodsImgUrl + ');'"></view>
|
<view class="cu-avatar xxl-view" :style="'background-image:url(' + good.goodsImgUrl + ');'"></view>
|
||||||
<view class="margin-left-sm flex-column-between">
|
<view class="margin-left-sm flex-column-between">
|
||||||
|
|
@ -40,7 +39,7 @@
|
||||||
<text class="text-price text-red text-bold text-lg">{{good.goodsStandardList[0].goodsPrice}}</text>
|
<text class="text-price text-red text-bold text-lg">{{good.goodsStandardList[0].goodsPrice}}</text>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<!-- <view class="text-gray" v-if="good.remark">{{good.remark}}</view> -->
|
<view class="text-gray" v-if="good.remark">{{good.remark}}</view>
|
||||||
<view v-if="good.goodsAreaList && good.goodsAreaList.length">
|
<view v-if="good.goodsAreaList && good.goodsAreaList.length">
|
||||||
<view class="cu-capsule">
|
<view class="cu-capsule">
|
||||||
<view class='cu-tag bg-main-color sm'>
|
<view class='cu-tag bg-main-color sm'>
|
||||||
|
|
@ -50,7 +49,7 @@
|
||||||
服务区域
|
服务区域
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<text v-for="(item,index) in good.goodsAreaList" :key="item.goodsId">
|
<text v-for="(item,index) in good.goodsAreaList">
|
||||||
<text class="margin-lr-xs text-sm">{{item.areaName}}<text v-if="index != good.goodsAreaList.length - 1">,</text></text>
|
<text class="margin-lr-xs text-sm">{{item.areaName}}<text v-if="index != good.goodsAreaList.length - 1">,</text></text>
|
||||||
</text>
|
</text>
|
||||||
</view>
|
</view>
|
||||||
|
|
@ -64,15 +63,14 @@
|
||||||
<view class="text-xs">金牌服务</view>
|
<view class="text-xs">金牌服务</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view v-if="good.goodsId">
|
<view>
|
||||||
<button class="cu-btn line-main-color margin-right-xs margin-top-sm" @click="() => addEditGood(good.goodsId)">编辑</button>
|
<button class="cu-btn line-main-color margin-right-xs margin-top-sm" @click="addEditGood(good)">编辑</button>
|
||||||
<button class="cu-btn line-main-color margin-right-xs margin-top-sm" v-if="good.status === 0" @click="() => offGood(good)">下架</button>
|
<button class="cu-btn line-main-color margin-right-xs margin-top-sm" v-if="good.status === 0" @click="offGood(good)">下架</button>
|
||||||
<button class="cu-btn line-main-color margin-right-xs margin-top-sm" v-if="good.status === 1" @click="() => onGood(good)">上架</button>
|
<button class="cu-btn line-main-color margin-right-xs margin-top-sm" v-if="good.status === 1" @click="onGood(good)">上架</button>
|
||||||
<!-- <button class="cu-btn line-main-color margin-right-xs margin-top-sm" @click="copyGood(good)">复制</button> -->
|
<!-- <button class="cu-btn line-main-color margin-right-xs margin-top-sm" @click="copyGood(good)">复制</button> -->
|
||||||
<!-- <button class="cu-btn line-main-color margin-right-xs margin-top-sm">优惠券</button> -->
|
<!-- <button class="cu-btn line-main-color margin-right-xs margin-top-sm">优惠券</button> -->
|
||||||
<!-- <button class="cu-btn line-red shadow-blur margin-right-xs margin-top-sm" @click="delGood(good)">删除</button> -->
|
<!-- <button class="cu-btn line-red shadow-blur margin-right-xs margin-top-sm" @click="delGood(good)">删除</button> -->
|
||||||
</view>
|
</view>
|
||||||
</template>
|
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
@ -80,7 +78,7 @@
|
||||||
<view class="margin-bottom-with-bar"></view>
|
<view class="margin-bottom-with-bar"></view>
|
||||||
<!-- 底部操作栏 -->
|
<!-- 底部操作栏 -->
|
||||||
<view class="padding-tb-sm flex justify-around padding-tb-sm fixed-bottom-bar-with-bar bg-back">
|
<view class="padding-tb-sm flex justify-around padding-tb-sm fixed-bottom-bar-with-bar bg-back">
|
||||||
<button class="cu-btn bg-main-color lg shadow-blur margin-left-xs" @click="addEditGood(null)">新增{{tabCur === 0 ? '服务' : '货品'}}</button>
|
<button class="cu-btn bg-main-color lg shadow-blur margin-left-xs" @click="addEditGood(null)">新增服务</button>
|
||||||
<button class="cu-btn bg-main-color lg shadow-blur" disabled type="">优惠券</button>
|
<button class="cu-btn bg-main-color lg shadow-blur" disabled type="">优惠券</button>
|
||||||
<button class="cu-btn bg-main-color lg shadow-blur" disabled type="">暂停售卖</button>
|
<button class="cu-btn bg-main-color lg shadow-blur" disabled type="">暂停售卖</button>
|
||||||
<!-- <button class="cu-btn bg-main-color lg shadow-blur margin-right-xs" data-modal="communityModal" @tap="showModal">社区</button> -->
|
<!-- <button class="cu-btn bg-main-color lg shadow-blur margin-right-xs" data-modal="communityModal" @tap="showModal">社区</button> -->
|
||||||
|
|
@ -133,14 +131,13 @@
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
keywords: '',
|
|
||||||
tabCur: 0,
|
tabCur: 0,
|
||||||
tabHeaders: [{
|
tabHeaders: [{
|
||||||
code: 1,
|
code: 0,
|
||||||
name: '服务商品'
|
name: '服务商品'
|
||||||
}, {
|
}, {
|
||||||
code: 2,
|
code: 1,
|
||||||
name: '货物商品'
|
name: '配件商品'
|
||||||
}],
|
}],
|
||||||
scrollLeft: 0,
|
scrollLeft: 0,
|
||||||
stickyTop: this.CustomBar,
|
stickyTop: this.CustomBar,
|
||||||
|
|
@ -183,13 +180,9 @@
|
||||||
params.pageNum = this.pageNum;
|
params.pageNum = this.pageNum;
|
||||||
params.pageSize = this.pageSize;
|
params.pageSize = this.pageSize;
|
||||||
params.workerId = this.$request.getCurUserInfo().workerId;
|
params.workerId = this.$request.getCurUserInfo().workerId;
|
||||||
params.keyword = this.keywords;
|
|
||||||
this.$refs.loadStatusBar.showLoading();
|
this.$refs.loadStatusBar.showLoading();
|
||||||
try {
|
try {
|
||||||
let res = await this.$request.qryProductPage({
|
let res = await this.$request.qryProductPage(params);
|
||||||
...params,
|
|
||||||
type: this.tabHeaders[this.tabCur].code
|
|
||||||
});
|
|
||||||
let rowsLength = res.rows.length;
|
let rowsLength = res.rows.length;
|
||||||
if (rowsLength > 0) {
|
if (rowsLength > 0) {
|
||||||
this.goodsList = this.goodsList.concat(res.rows);
|
this.goodsList = this.goodsList.concat(res.rows);
|
||||||
|
|
@ -216,7 +209,6 @@
|
||||||
tabSelect(e) {
|
tabSelect(e) {
|
||||||
this.tabCur = e.currentTarget.dataset.id;
|
this.tabCur = e.currentTarget.dataset.id;
|
||||||
this.scrollLeft = (e.currentTarget.dataset.id - 1) * 60
|
this.scrollLeft = (e.currentTarget.dataset.id - 1) * 60
|
||||||
this.reloadData()
|
|
||||||
},
|
},
|
||||||
showModal(e) {
|
showModal(e) {
|
||||||
let modalName = e.currentTarget.dataset.modal;
|
let modalName = e.currentTarget.dataset.modal;
|
||||||
|
|
@ -287,23 +279,14 @@
|
||||||
comfirmCommunity() {
|
comfirmCommunity() {
|
||||||
|
|
||||||
},
|
},
|
||||||
addEditGood(goodsId) {
|
addEditGood(servItem) {
|
||||||
let params = '?type='+this.tabHeaders[this.tabCur].code;
|
let params = '';
|
||||||
const curType = this.tabHeaders[this.tabCur].code
|
if (servItem != null) {
|
||||||
if (goodsId != null) {
|
params = '?goodId=' + servItem.goodsId
|
||||||
params = '?goodId=' + goodsId + '&type='+curType
|
|
||||||
}
|
}
|
||||||
console.log(params);
|
|
||||||
if(curType === 1) {
|
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url: '/pages/my/new-serv' + params
|
url: '/pages/my/new-serv' + params
|
||||||
})
|
})
|
||||||
} else {
|
|
||||||
uni.navigateTo({
|
|
||||||
url: '/pages/my/new-serv-parts' + params
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -19,19 +19,19 @@
|
||||||
</view> -->
|
</view> -->
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="right-tag padding-lr padding-tb-xs" @click="showMasterRule">服务规则</view>
|
<!-- <view class="right-tag padding-lr padding-tb-xs" @click="showMasterRule">师傅规则</view> -->
|
||||||
</view>
|
</view>
|
||||||
<!-- 未预约,未派单,上门超时 -->
|
<!-- 未预约,未派单,上门超时 -->
|
||||||
<view class="cu-list grid no-border col-3 margin-top-sm" style="background-color: inherit;">
|
<view class="cu-list grid no-border col-3 margin-top-sm" style="background-color: inherit;">
|
||||||
<view class="cu-item" @click="gotoOrderNew">
|
<view class="cu-item">
|
||||||
<view class="margin-bottom-xs text-xxl">{{orderStatistics.newOrderNum}}</view>
|
<view class="margin-bottom-xs text-xxl">{{orderStatistics.newOrderNum}}</view>
|
||||||
<view>新订单</view>
|
<view>新订单</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="cu-item" @click="goToOrder">
|
<view class="cu-item">
|
||||||
<view class="margin-bottom-xs text-xxl">{{orderStatistics.planOrderNum}}</view>
|
<view class="margin-bottom-xs text-xxl">{{orderStatistics.planOrderNum}}</view>
|
||||||
<view>未排单</view>
|
<view>未排单</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="cu-item" @click="goToOrder">
|
<view class="cu-item">
|
||||||
<view class="margin-bottom-xs text-xxl">0</view>
|
<view class="margin-bottom-xs text-xxl">0</view>
|
||||||
<view>上门超时</view>
|
<view>上门超时</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
@ -43,13 +43,13 @@
|
||||||
<view class="cu-bar margin-top-sm solid-bottom">
|
<view class="cu-bar margin-top-sm solid-bottom">
|
||||||
<view class="action bar-first-action">
|
<view class="action bar-first-action">
|
||||||
<view class="cuIcon-title text-main-color"></view>
|
<view class="cuIcon-title text-main-color"></view>
|
||||||
<text>今日待处理({{waitServOrderToday.length}})</text>
|
<text>今日待上门({{waitServOrderToday.length}})</text>
|
||||||
</view>
|
</view>
|
||||||
<view class="flex justify-end text-sm align-center"
|
<view class="flex justify-end text-sm align-center"
|
||||||
@click="clickServModule({
|
@click="clickServModule({
|
||||||
pageUrl: waitServOrderToday[0].orderType === 1 ? '/pages/order-manage/order-manage-parts' : '/pages/order-manage/order-manage'
|
pageUrl: '/pages/order-manage/order-manage'
|
||||||
})">
|
})">
|
||||||
<text>即将处理订单</text>
|
<text>即将上门订单</text>
|
||||||
<text class="cuIcon-right"></text>
|
<text class="cuIcon-right"></text>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
@ -73,7 +73,7 @@
|
||||||
</swiper-item>
|
</swiper-item>
|
||||||
</swiper>
|
</swiper>
|
||||||
<view v-else class="screen-swiper padding text-center text-gray">
|
<view v-else class="screen-swiper padding text-center text-gray">
|
||||||
今日无待处理订单
|
今日无待上门订单
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<!-- 每周公告 -->
|
<!-- 每周公告 -->
|
||||||
|
|
@ -96,15 +96,9 @@
|
||||||
<view hover-class="none" class="nav-li serv-module" @click="clickServModule(item)"
|
<view hover-class="none" class="nav-li serv-module" @click="clickServModule(item)"
|
||||||
:class="'bg-'+item.color" :style="[{animation: 'show ' + ((index+1)*0.2+1) + 's 1'}]"
|
:class="'bg-'+item.color" :style="[{animation: 'show ' + ((index+1)*0.2+1) + 's 1'}]"
|
||||||
v-for="(item,index) in servModules " :key="index">
|
v-for="(item,index) in servModules " :key="index">
|
||||||
<!-- <template v-if="item.id !== 4"> -->
|
|
||||||
<view :class="index === 0 ? 'text-xxl' : 'text-xl'">{{item.title}}</view>
|
<view :class="index === 0 ? 'text-xxl' : 'text-xl'">{{item.title}}</view>
|
||||||
<!-- <view class="nav-name">{{item.name}}</view> -->
|
<!-- <view class="nav-name">{{item.name}}</view> -->
|
||||||
<text :class="'cuIcon-' + item.cuIcon"></text>
|
<text :class="'cuIcon-' + item.cuIcon"></text>
|
||||||
<!-- </template> -->
|
|
||||||
<!-- <button data-name="shareBtn" open-type="share" hover-class="none" v-else>
|
|
||||||
<view :class="index === 0 ? 'text-xxl' : 'text-xl'">{{item.title}}</view>
|
|
||||||
<text :class="'cuIcon-' + item.cuIcon"></text>
|
|
||||||
</button> -->
|
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
@ -135,28 +129,26 @@
|
||||||
checkLogin: true
|
checkLogin: true
|
||||||
}, {
|
}, {
|
||||||
id: 2,
|
id: 2,
|
||||||
title: '服务订单',
|
title: '我的订单',
|
||||||
name: '查看详情',
|
name: '查看详情',
|
||||||
color: 'orange',
|
color: 'orange',
|
||||||
cuIcon: 'text',
|
cuIcon: 'text',
|
||||||
pageUrl: '/pages/order-manage/order-manage?orderType=0',
|
pageUrl: '/pages/order-manage/order-manage',
|
||||||
checkLogin: true
|
checkLogin: true
|
||||||
}, {
|
}, {
|
||||||
id: 3,
|
id: 3,
|
||||||
title: '商品订单',
|
title: '叮咚学院',
|
||||||
name: '查看详情',
|
name: '查看详情',
|
||||||
color: 'cyan',
|
color: 'cyan',
|
||||||
cuIcon: 'emoji',
|
cuIcon: 'emoji',
|
||||||
pageUrl: '/pages/order-manage/order-manage-parts?orderType=1',
|
pageUrl: ''
|
||||||
checkLogin: true
|
|
||||||
}, {
|
}, {
|
||||||
id: 4,
|
id: 4,
|
||||||
title: '商品大厅',
|
title: '邀请师傅',
|
||||||
name: '查看详情',
|
name: '查看详情',
|
||||||
color: 'pink',
|
color: 'pink',
|
||||||
cuIcon: 'profile',
|
cuIcon: 'profile',
|
||||||
pageUrl: '/pages/demand-center/accept-demand-center?orderType=1',
|
pageUrl: ''
|
||||||
checkLogin: true
|
|
||||||
}, {
|
}, {
|
||||||
id: 5,
|
id: 5,
|
||||||
title: '区域代理',
|
title: '区域代理',
|
||||||
|
|
@ -167,7 +159,7 @@
|
||||||
checkLogin: true
|
checkLogin: true
|
||||||
}],
|
}],
|
||||||
curUserInfo: {},
|
curUserInfo: {},
|
||||||
// myInfo: {},
|
myInfo: {},
|
||||||
waitServOrderToday: [],
|
waitServOrderToday: [],
|
||||||
orderStatistics: {},
|
orderStatistics: {},
|
||||||
isShowSteer: false,
|
isShowSteer: false,
|
||||||
|
|
@ -180,12 +172,14 @@
|
||||||
this.loadData();
|
this.loadData();
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
test() {
|
||||||
|
|
||||||
|
},
|
||||||
async authLogin() {
|
async authLogin() {
|
||||||
// 更新缓存中的userInfo
|
// 更新缓存中的userInfo
|
||||||
// let res = await this.$request.storageExistUser();
|
// let res = await this.$request.storageExistUser();
|
||||||
// 获取缓存中的userInfo
|
// 获取缓存中的userInfo
|
||||||
let curUserInfo = this.$request.getCurUserInfo();
|
let curUserInfo = this.$request.getCurUserInfo();
|
||||||
console.log(curUserInfo);
|
|
||||||
// 校验提示登录
|
// 校验提示登录
|
||||||
// if (!curUserInfo || !curUserInfo.openId) {
|
// if (!curUserInfo || !curUserInfo.openId) {
|
||||||
// this.$refs.vertifyLogin.showModal();
|
// this.$refs.vertifyLogin.showModal();
|
||||||
|
|
@ -218,23 +212,20 @@
|
||||||
this.$refs.vertifyWorkerType.showModal();
|
this.$refs.vertifyWorkerType.showModal();
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
// if(Object.keys('orderStatistics').length === 0) {
|
this.loadData();
|
||||||
// this.loadData();
|
|
||||||
// }
|
|
||||||
return true;
|
return true;
|
||||||
},
|
},
|
||||||
async loadData() {
|
async loadData() {
|
||||||
// 获取缓存中的userInfo
|
// 获取缓存中的userInfo
|
||||||
this.curUserInfo = this.$request.getCurUserInfo();
|
this.curUserInfo = this.$request.getCurUserInfo();
|
||||||
// this.myInfo = await this.$api.data('myInfo');
|
this.myInfo = await this.$api.data('myInfo');
|
||||||
// this.isShowSteer = !this.myInfo.entryType;
|
// this.isShowSteer = !this.myInfo.entryType;
|
||||||
const hasCheckedRule = !!uni.getStorageSync('hasCheckedRule')
|
|
||||||
let newServModules = this.servModules.concat();
|
let newServModules = this.servModules.concat();
|
||||||
if (hasCheckedRule) {
|
if (this.myInfo.hasCheckedRule) {
|
||||||
newServModules[0].pageUrl = '/pages/demand-center/accept-demand-center?orderType=0';
|
newServModules[0].pageUrl = '/pages/demand-center/accept-demand-center';
|
||||||
} else {
|
} else {
|
||||||
let paramObj = {
|
let paramObj = {
|
||||||
hasCheckedRule: hasCheckedRule,
|
hasCheckedRule: this.myInfo.hasCheckedRule,
|
||||||
navigate: true
|
navigate: true
|
||||||
}
|
}
|
||||||
newServModules[0].pageUrl = '/pages/demand-center/rule?paramObj=' + encodeURIComponent(JSON
|
newServModules[0].pageUrl = '/pages/demand-center/rule?paramObj=' + encodeURIComponent(JSON
|
||||||
|
|
@ -251,9 +242,7 @@
|
||||||
let waitServRes = await this.$request.qryDetailOrderPage({
|
let waitServRes = await this.$request.qryDetailOrderPage({
|
||||||
orderStatus: 2,
|
orderStatus: 2,
|
||||||
expectTimeStart: date.getFullYear() + '-' + (date.getMonth() + 1) + '-' + date.getDate() + " 00:00:00",
|
expectTimeStart: date.getFullYear() + '-' + (date.getMonth() + 1) + '-' + date.getDate() + " 00:00:00",
|
||||||
expectTimeEnd: date.getFullYear() + '-' + (date.getMonth() + 1) + '-' + date.getDate() + " 23:59:59",
|
expectTimeEnd: date.getFullYear() + '-' + (date.getMonth() + 1) + '-' + date.getDate() + " 23:59:59"
|
||||||
orderByColumn: "expectTimeStart",
|
|
||||||
isAsc: "desc"
|
|
||||||
});
|
});
|
||||||
this.waitServOrderToday = waitServRes.rows;
|
this.waitServOrderToday = waitServRes.rows;
|
||||||
},
|
},
|
||||||
|
|
@ -265,9 +254,8 @@
|
||||||
this[e.currentTarget.dataset.modal] = false;
|
this[e.currentTarget.dataset.modal] = false;
|
||||||
},
|
},
|
||||||
showMasterRule() {
|
showMasterRule() {
|
||||||
const hasCheckedRule = !!uni.getStorageSync('hasCheckedRule')
|
|
||||||
let paramObj = {
|
let paramObj = {
|
||||||
hasCheckedRule: hasCheckedRule,
|
hasCheckedRule: this.myInfo.hasCheckedRule,
|
||||||
navigate: false
|
navigate: false
|
||||||
}
|
}
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
|
|
@ -276,61 +264,21 @@
|
||||||
},
|
},
|
||||||
async clickServModule(pageObj) {
|
async clickServModule(pageObj) {
|
||||||
if (pageObj && !pageObj.pageUrl) {
|
if (pageObj && !pageObj.pageUrl) {
|
||||||
if(pageObj.id !== 4) {
|
|
||||||
uni.showToast({
|
uni.showToast({
|
||||||
icon: 'none',
|
icon: 'none',
|
||||||
title: '功能开发中'
|
title: '功能开发中'
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
}
|
|
||||||
if (pageObj.checkLogin) {
|
if (pageObj.checkLogin) {
|
||||||
let res = await this.authLogin();
|
let res = await this.authLogin();
|
||||||
if (res) {
|
if (res) {
|
||||||
// uni.navigateTo({
|
uni.navigateTo({
|
||||||
// url: pageObj.pageUrl
|
url: pageObj.pageUrl
|
||||||
// })
|
|
||||||
this.toNewPath(pageObj.pageUrl)
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
// uni.navigateTo({
|
|
||||||
// url: pageObj.pageUrl
|
|
||||||
// })
|
|
||||||
this.toNewPath(pageObj.pageUrl)
|
|
||||||
}
|
|
||||||
},
|
|
||||||
gotoOrderNew() {
|
|
||||||
// uni.navigateTo({
|
|
||||||
// url: '/pages/order-manage/order-manage?stateCur=6'
|
|
||||||
// })
|
|
||||||
this.toNewPath('/pages/order-manage/order-manage?stateCur=6')
|
|
||||||
},
|
|
||||||
goToOrder() {
|
|
||||||
// uni.navigateTo({
|
|
||||||
// url: '/pages/order-manage/order-manage'
|
|
||||||
// })
|
|
||||||
this.toNewPath('/pages/order-manage/order-manage')
|
|
||||||
},
|
|
||||||
async toNewPath(path) {
|
|
||||||
const res = await this.$request.getAndSetWorkerInfo(this.curUserInfo.workerId)
|
|
||||||
if(res.data.loginStatus == 1) {
|
|
||||||
// 禁止登录,退出登录
|
|
||||||
uni.clearStorageSync('userProfile');
|
|
||||||
uni.showToast({
|
|
||||||
icon: 'none',
|
|
||||||
title: '您已被禁止登录',
|
|
||||||
duration: 3000,
|
|
||||||
success() {
|
|
||||||
setTimeout(() => {
|
|
||||||
uni.reLaunch({
|
|
||||||
url: '/pages/login/login'
|
|
||||||
})
|
})
|
||||||
}, 3000)
|
|
||||||
}
|
}
|
||||||
})
|
|
||||||
return
|
|
||||||
} else {
|
} else {
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url: path
|
url: pageObj.pageUrl
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -376,21 +324,6 @@
|
||||||
line-height: 195rpx;
|
line-height: 195rpx;
|
||||||
}
|
}
|
||||||
|
|
||||||
.nav-li button{
|
|
||||||
padding: 0;
|
|
||||||
margin: 0;
|
|
||||||
border: none;
|
|
||||||
background-color: transparent;
|
|
||||||
line-height: inherit;
|
|
||||||
color: inherit;
|
|
||||||
position: static;
|
|
||||||
text-align: left;
|
|
||||||
}
|
|
||||||
.nav-li button::after {
|
|
||||||
border: none;
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
.nav-li {
|
.nav-li {
|
||||||
padding: 30rpx;
|
padding: 30rpx;
|
||||||
border-radius: 12rpx;
|
border-radius: 12rpx;
|
||||||
|
|
|
||||||
|
|
@ -35,24 +35,14 @@
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
moduleBarInfos: [],
|
moduleBarInfos: [],
|
||||||
curPageCode: '',
|
curPageCode: 'indexPage',
|
||||||
forwardingPageCode: null
|
forwardingPageCode: null
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
onLoad(options) {
|
onLoad(options) {
|
||||||
|
|
||||||
let curUserInfo = this.$request.getCurUserInfo();
|
|
||||||
if(!curUserInfo) {
|
|
||||||
uni.reLaunch({
|
|
||||||
url: '/pages/login/login'
|
|
||||||
})
|
|
||||||
return
|
|
||||||
}
|
|
||||||
this.loadData();
|
this.loadData();
|
||||||
if (options && options.menuCode) {
|
if (options && options.menuCode) {
|
||||||
this.changeCurPageCode(options.menuCode)
|
this.changeCurPageCode(options.menuCode)
|
||||||
} else {
|
|
||||||
this.curPageCode = 'indexPage'
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
|
|
||||||
|
|
@ -18,7 +18,7 @@
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="paper-drawer-bar margin-bottom-with-bar padding-bottom-lg">
|
<view class="paper-drawer-bar margin-bottom-with-bar">
|
||||||
<view class="margin-lr-sm cu-list grid no-border col-4 shadow-warp">
|
<view class="margin-lr-sm cu-list grid no-border col-4 shadow-warp">
|
||||||
<view class="cu-item">
|
<view class="cu-item">
|
||||||
<view class="cuIcon-remind margin-bottom-xs middle-icon"
|
<view class="cuIcon-remind margin-bottom-xs middle-icon"
|
||||||
|
|
@ -44,7 +44,7 @@
|
||||||
<view class="bg-white">
|
<view class="bg-white">
|
||||||
<view class="margin-top margin-lr-sm">
|
<view class="margin-top margin-lr-sm">
|
||||||
<view class="flex justify-between align-center solid-bottom padding padding-lr-lg text-lg"
|
<view class="flex justify-between align-center solid-bottom padding padding-lr-lg text-lg"
|
||||||
v-for="(item, index) in menuList" :key="index" @click="clickMenuItem(item)"
|
v-for="(item, index) in menuList" @click="clickMenuItem(item)"
|
||||||
v-if="item.show || (item.showByStatus ? curUserInfo.status != -1 : false)">
|
v-if="item.show || (item.showByStatus ? curUserInfo.status != -1 : false)">
|
||||||
<view class="flex justify-start align-center">
|
<view class="flex justify-start align-center">
|
||||||
<view class="margin-right-sm text-main-color text-xl"><view :class="'cuIcon-' + item.icon"></view></view>
|
<view class="margin-right-sm text-main-color text-xl"><view :class="'cuIcon-' + item.icon"></view></view>
|
||||||
|
|
@ -55,17 +55,6 @@
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
<confirm-modal ref="focusModal" :showCancel="false" :isAutoClose="false" confirmMsg="已关注" @confirm="checkIfFollow()">
|
|
||||||
<template #contentView>
|
|
||||||
<view style="display: flex;flex-direction: column;justify-content: center;align-items: center;">
|
|
||||||
<text style="font-size: 30rpx;margin-bottom: 30rpx;font-weight: 500;">先关注公众号,绑定订单通知!</text>
|
|
||||||
<image style="width: 400upx;height: 400upx;margin-bottom: 20upx;" :show-menu-by-longpress="true" src="http://gqz.opsoul.com/qrcode_for_gh_e1c9ac86741f_860.jpg" mode="aspectFill"></image>
|
|
||||||
<text style="margin-bottom: 20upx;">操作方式</text>
|
|
||||||
<text>长按二维码,前往公众号点关注</text>
|
|
||||||
</view>
|
|
||||||
</template>
|
|
||||||
</confirm-modal>
|
|
||||||
</view>
|
</view>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
|
|
@ -92,27 +81,13 @@
|
||||||
}, {
|
}, {
|
||||||
name: '服务明细',
|
name: '服务明细',
|
||||||
icon: 'calendar'
|
icon: 'calendar'
|
||||||
},
|
}, {
|
||||||
{
|
name: '师傅入驻',
|
||||||
name: '服务入驻',
|
|
||||||
icon: 'profile',
|
icon: 'profile',
|
||||||
pageUrl: '/pages/my/master-settled-info?type=1',
|
pageUrl: '/pages/my/master-settled-info',
|
||||||
show: true
|
show: true
|
||||||
},
|
}, {
|
||||||
{
|
name: '个人信息',
|
||||||
name: '商品入驻',
|
|
||||||
icon: 'profile',
|
|
||||||
pageUrl: '/pages/my/master-settled-info?type=2',
|
|
||||||
show: true
|
|
||||||
},
|
|
||||||
{
|
|
||||||
name: '订单通知绑定',
|
|
||||||
icon: 'roundcheck',
|
|
||||||
show: true,
|
|
||||||
prefixFun: 'showFollowBox'
|
|
||||||
},
|
|
||||||
{
|
|
||||||
name: '商家信息',
|
|
||||||
icon: 'lock',
|
icon: 'lock',
|
||||||
pageUrl: '/pages/my/personal-info',
|
pageUrl: '/pages/my/personal-info',
|
||||||
show: true
|
show: true
|
||||||
|
|
@ -140,8 +115,7 @@
|
||||||
icon: 'exit',
|
icon: 'exit',
|
||||||
pageUrl: '/pages/login/login',
|
pageUrl: '/pages/login/login',
|
||||||
show: true
|
show: true
|
||||||
}],
|
}]
|
||||||
isSixSecord: false
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
onReady() {
|
onReady() {
|
||||||
|
|
@ -149,7 +123,6 @@
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
async loadData() {
|
async loadData() {
|
||||||
await this.$request.refreshCurUserCache();
|
|
||||||
this.curUserInfo = this.$request.getCurUserInfo();
|
this.curUserInfo = this.$request.getCurUserInfo();
|
||||||
let res = await this.$request.getWorkerCertify();
|
let res = await this.$request.getWorkerCertify();
|
||||||
this.curCertifyInfo = res.data;
|
this.curCertifyInfo = res.data;
|
||||||
|
|
@ -169,51 +142,6 @@
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url: pageUrl
|
url: pageUrl
|
||||||
})
|
})
|
||||||
},
|
|
||||||
async showFollowBox() {
|
|
||||||
const status = await this.checkBeforeFollow()
|
|
||||||
if(!status) {
|
|
||||||
this.$refs.focusModal.showModal();
|
|
||||||
setTimeout(() => {
|
|
||||||
this.isSixSecord = true
|
|
||||||
}, 6000)
|
|
||||||
} else {
|
|
||||||
uni.showToast({
|
|
||||||
title: '您已绑定消息通知',
|
|
||||||
icon: 'none'
|
|
||||||
})
|
|
||||||
}
|
|
||||||
},
|
|
||||||
async checkBeforeFollow() {
|
|
||||||
const wxLoginRes = await wx.login();
|
|
||||||
console.log(wxLoginRes);
|
|
||||||
const wxAuthRes = await uni.request({
|
|
||||||
url: '/wx/neCheck',
|
|
||||||
header: {
|
|
||||||
code: wxLoginRes.code
|
|
||||||
}
|
|
||||||
})
|
|
||||||
// const wxAuthRes = await uni.request({
|
|
||||||
// url: '/wx/auth',
|
|
||||||
// header: {
|
|
||||||
// code: wxLoginRes.code
|
|
||||||
// }
|
|
||||||
// })
|
|
||||||
return wxAuthRes[1].data.data
|
|
||||||
},
|
|
||||||
async checkIfFollow() {
|
|
||||||
if(!this.isSixSecord) {
|
|
||||||
const status = await this.checkBeforeFollow()
|
|
||||||
if(!status) {
|
|
||||||
uni.showToast({
|
|
||||||
title: '请先关注公众号',
|
|
||||||
icon: 'none'
|
|
||||||
})
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
this.$refs.focusModal.hideModal();
|
|
||||||
return;
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -52,7 +52,7 @@
|
||||||
</view>
|
</view>
|
||||||
<view class="cu-form-group margin-top">
|
<view class="cu-form-group margin-top">
|
||||||
<view class="title">验证码</view>
|
<view class="title">验证码</view>
|
||||||
<input class="radius-input" type="digit" name="registerCode" v-model="formData.registerCode"
|
<input class="radius-input" type="number" name="registerCode" v-model="formData.registerCode"
|
||||||
placeholder="请输入验证码"></input>
|
placeholder="请输入验证码"></input>
|
||||||
<view v-if="countDownNum === 0" class="cu-btn bg-blue round-btn margin-left-xs shadow-blur" @click="sendVertifyCode">发送验证码
|
<view v-if="countDownNum === 0" class="cu-btn bg-blue round-btn margin-left-xs shadow-blur" @click="sendVertifyCode">发送验证码
|
||||||
</view>
|
</view>
|
||||||
|
|
@ -83,23 +83,12 @@
|
||||||
<!-- 加入师傅团队提示 -->
|
<!-- 加入师傅团队提示 -->
|
||||||
<!-- <invite-master ref="inviteMasterModal" :inviteMasterObj="inviter" @confirm="inviteMaster"></invite-master> -->
|
<!-- <invite-master ref="inviteMasterModal" :inviteMasterObj="inviter" @confirm="inviteMaster"></invite-master> -->
|
||||||
<confirm-modal ref="inviteMasterModal" :content="'是否确认加入' + inviter.name + '的团队?'" @confirm="inviteMaster(inviter)"></confirm-modal>
|
<confirm-modal ref="inviteMasterModal" :content="'是否确认加入' + inviter.name + '的团队?'" @confirm="inviteMaster(inviter)"></confirm-modal>
|
||||||
|
|
||||||
<confirm-modal ref="focusModal" cancelMsg="返回" :isAutoClose="false" confirmMsg="已关注,继续注册" @cancel="cancelFollow" @confirm="checkIfFollow()">
|
|
||||||
<template #contentView>
|
|
||||||
<view style="display: flex;flex-direction: column;justify-content: center;align-items: center;">
|
|
||||||
<text style="font-size: 30rpx;margin-bottom: 30rpx;font-weight: 500;">先关注公众号,绑定订单通知!</text>
|
|
||||||
<image style="width: 400upx;height: 400upx;margin-bottom: 20upx;" :show-menu-by-longpress="true" src="http://gqz.opsoul.com/qrcode_for_gh_e1c9ac86741f_860.jpg" mode="aspectFill"></image>
|
|
||||||
<text style="margin-bottom: 20upx;">操作方式</text>
|
|
||||||
<text>长按二维码,前往公众号点关注</text>
|
|
||||||
</view>
|
|
||||||
</template>
|
|
||||||
</confirm-modal>
|
|
||||||
</view>
|
</view>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
// import inviteMaster from '../area-proxy/modal/invite-master.vue'
|
// import inviteMaster from '../area-proxy/modal/invite-master.vue'
|
||||||
// 18929577155 qq880920 13386441744
|
|
||||||
export default {
|
export default {
|
||||||
components: {
|
components: {
|
||||||
// inviteMaster
|
// inviteMaster
|
||||||
|
|
@ -111,8 +100,7 @@
|
||||||
countDownNum: 0,
|
countDownNum: 0,
|
||||||
agreeContract: false,
|
agreeContract: false,
|
||||||
formData: {},
|
formData: {},
|
||||||
inviter: {},
|
inviter: {}
|
||||||
isSixSecord: false
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
onLoad(options) {
|
onLoad(options) {
|
||||||
|
|
@ -129,19 +117,11 @@
|
||||||
changeAgreeContract() {
|
changeAgreeContract() {
|
||||||
this.agreeContract = !this.agreeContract;
|
this.agreeContract = !this.agreeContract;
|
||||||
},
|
},
|
||||||
async changeOperType() {
|
changeOperType() {
|
||||||
this.reset();
|
this.reset();
|
||||||
this.operType = this.operType === 0 ? 1 : 0;
|
this.operType = this.operType === 0 ? 1 : 0;
|
||||||
if (this.operType === 1) {
|
if (this.operType === 1) {
|
||||||
// const status = await this.checkBeforeFollow()
|
this.authLogin();
|
||||||
// if(!status) {
|
|
||||||
this.$refs.focusModal.showModal();
|
|
||||||
setTimeout(() => {
|
|
||||||
this.isSixSecord = true
|
|
||||||
}, 6000)
|
|
||||||
// } else {
|
|
||||||
// this.authLogin();
|
|
||||||
// }
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
reset() {
|
reset() {
|
||||||
|
|
@ -330,36 +310,6 @@
|
||||||
icon: 'error'
|
icon: 'error'
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
},
|
|
||||||
cancelFollow() {
|
|
||||||
this.reset();
|
|
||||||
this.operType = 0;
|
|
||||||
this.$refs.focusModal.isShow = false;
|
|
||||||
},
|
|
||||||
|
|
||||||
async checkBeforeFollow() {
|
|
||||||
const wxLoginRes = await wx.login();
|
|
||||||
const wxAuthRes = await uni.request({
|
|
||||||
url: '/wx/check',
|
|
||||||
header: {
|
|
||||||
code: wxLoginRes.code
|
|
||||||
}
|
|
||||||
})
|
|
||||||
return wxAuthRes[1].data.data
|
|
||||||
},
|
|
||||||
async checkIfFollow() {
|
|
||||||
if(!this.isSixSecord) {
|
|
||||||
const res = await this.checkBeforeFollow()
|
|
||||||
if(!res) {
|
|
||||||
uni.showToast({
|
|
||||||
title: '请先关注公众号',
|
|
||||||
icon: 'error'
|
|
||||||
})
|
|
||||||
return
|
|
||||||
}
|
|
||||||
}
|
|
||||||
this.$refs.focusModal.isShow = false;
|
|
||||||
this.authLogin();
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|
@ -419,6 +369,5 @@
|
||||||
position: relative;
|
position: relative;
|
||||||
height: 60rpx;
|
height: 60rpx;
|
||||||
line-height: 60rpx;
|
line-height: 60rpx;
|
||||||
flex-basis: 140rpx;
|
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|
|
||||||
|
|
@ -119,19 +119,15 @@
|
||||||
placeholder="请输入公司执照号码"></input>
|
placeholder="请输入公司执照号码"></input>
|
||||||
</view>
|
</view>
|
||||||
<view class="cu-form-group">
|
<view class="cu-form-group">
|
||||||
<view class="title">公司区域</view>
|
<view class="title">公司地址</view>
|
||||||
<view class="flex-column-between">
|
<view class="flex-column-between flex-view">
|
||||||
<picker :mode="'multiSelector'" @change="regionChange" @columnchange="regionColChange"
|
<picker :mode="'multiSelector'" @change="regionChange" @columnchange="regionColChange"
|
||||||
:value="multiIndex" :range-key="'areaName'" :range="areaList">
|
:value="multiIndex" :range-key="'areaName'" :range="areaList">
|
||||||
<view class="picker">
|
<view class="picker">
|
||||||
{{realNameInfo.companyArea && realNameInfo.companyArea.length ? realNameInfo.companyArea[0].areaName + '-' + realNameInfo.companyArea[1].areaName + '-' + realNameInfo.companyArea[2].areaName : '请选择'}}
|
{{realNameInfo.companyArea && realNameInfo.companyArea.length ? realNameInfo.companyArea[0].areaName + '-' + realNameInfo.companyArea[1].areaName + '-' + realNameInfo.companyArea[2].areaName : '请选择'}}
|
||||||
</view>
|
</view>
|
||||||
</picker>
|
</picker>
|
||||||
</view>
|
<!-- <view><input name="companyAddress" v-model="realNameInfo.companyAddress" placeholder="请输入营业执照地址/经营地址/服务网点"></input></view> -->
|
||||||
</view>
|
|
||||||
<view class="cu-form-group">
|
|
||||||
<view class="title">公司地址</view>
|
|
||||||
<view class="flex-column-between flex-view">
|
|
||||||
<textarea name="companyAddress" class="solid padding-sm" maxlength="-1"
|
<textarea name="companyAddress" class="solid padding-sm" maxlength="-1"
|
||||||
v-model="realNameInfo.companyAddress" placeholder="请输入营业执照地址/经营地址/服务网点" />
|
v-model="realNameInfo.companyAddress" placeholder="请输入营业执照地址/经营地址/服务网点" />
|
||||||
</view>
|
</view>
|
||||||
|
|
@ -396,7 +392,6 @@
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
curUserInfo: null,
|
curUserInfo: null,
|
||||||
hasJoinedTeam: false,
|
|
||||||
curCertifyInfo: null,
|
curCertifyInfo: null,
|
||||||
servSpecialSkills: null,
|
servSpecialSkills: null,
|
||||||
curStep: 0,
|
curStep: 0,
|
||||||
|
|
@ -442,7 +437,6 @@
|
||||||
methods: {
|
methods: {
|
||||||
async loadData() {
|
async loadData() {
|
||||||
this.curUserInfo = this.$request.getCurUserInfo();
|
this.curUserInfo = this.$request.getCurUserInfo();
|
||||||
this.checkedHasJoinedTeam();
|
|
||||||
let res = await this.$request.getWorkerCertify();
|
let res = await this.$request.getWorkerCertify();
|
||||||
this.curCertifyInfo = res.data;
|
this.curCertifyInfo = res.data;
|
||||||
if (this.curCertifyInfo && this.curCertifyInfo.workerCertificationId) {
|
if (this.curCertifyInfo && this.curCertifyInfo.workerCertificationId) {
|
||||||
|
|
@ -461,13 +455,6 @@
|
||||||
this.loadSpecialSkillType();
|
this.loadSpecialSkillType();
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
async checkedHasJoinedTeam() {
|
|
||||||
let params = {
|
|
||||||
hasRegistered: true
|
|
||||||
}
|
|
||||||
let res = await this.$request.getTeamPage(params);
|
|
||||||
this.hasJoinedTeam = res.rows.length > 0 ? true : false;
|
|
||||||
},
|
|
||||||
async showForm() {
|
async showForm() {
|
||||||
this.loadAreaList();
|
this.loadAreaList();
|
||||||
this.loadSpecialSkillType();
|
this.loadSpecialSkillType();
|
||||||
|
|
@ -709,15 +696,14 @@
|
||||||
this.specialSkill[index].insurEndDate = e[1];
|
this.specialSkill[index].insurEndDate = e[1];
|
||||||
},
|
},
|
||||||
async chooseImage(e, imgList, count) {
|
async chooseImage(e, imgList, count) {
|
||||||
uni.chooseMedia({
|
uni.chooseImage({
|
||||||
count: count && count > 0 ? count : 1, //默认9
|
count: count && count > 0 ? count : 1, //默认9
|
||||||
mediaType: ['image'],
|
|
||||||
sizeType: ['original', 'compressed'], //可以指定是原图还是压缩图,默认二者都有
|
sizeType: ['original', 'compressed'], //可以指定是原图还是压缩图,默认二者都有
|
||||||
sourceType: ['album'], //从相册选择
|
sourceType: ['album'], //从相册选择
|
||||||
success: (res) => {
|
success: (res) => {
|
||||||
// 上传图片
|
// 上传图片
|
||||||
res.tempFiles.forEach((fileObj) => {
|
res.tempFilePaths.forEach((tmpPath) => {
|
||||||
this.$request.uploadFile(fileObj.tempFilePath).then((url) => {
|
this.$request.uploadFile(tmpPath).then((url) => {
|
||||||
// 存入缓存
|
// 存入缓存
|
||||||
imgList.push(url);
|
imgList.push(url);
|
||||||
});
|
});
|
||||||
|
|
@ -748,8 +734,19 @@
|
||||||
validData() {
|
validData() {
|
||||||
let teamParams = this.realNameInfo;
|
let teamParams = this.realNameInfo;
|
||||||
let errMsg = null;
|
let errMsg = null;
|
||||||
if (!this.hasJoinedTeam) {
|
if (teamParams.companySize == null || teamParams.companySize == undefined) {
|
||||||
if (!teamParams.licenseImgList || !teamParams.licenseImgList.length) {
|
errMsg = "请选择经营主体规模";
|
||||||
|
} else if (!teamParams.brandName) {
|
||||||
|
errMsg = "请填写品牌名称"
|
||||||
|
} else if (!teamParams.idCardImgList || !teamParams.idCardImgList.length) {
|
||||||
|
errMsg = "请上传身份证照片"
|
||||||
|
} else if (!teamParams.surname) {
|
||||||
|
errMsg = "请填写姓氏"
|
||||||
|
} else if (!teamParams.name) {
|
||||||
|
errMsg = "请填写名字"
|
||||||
|
} else if (!teamParams.idCardNum) {
|
||||||
|
errMsg = "请填写身份证号";
|
||||||
|
} else if (!teamParams.licenseImgList || !teamParams.licenseImgList.length) {
|
||||||
errMsg = "请上传公司营业执照";
|
errMsg = "请上传公司营业执照";
|
||||||
} else if (!teamParams.companyName) {
|
} else if (!teamParams.companyName) {
|
||||||
errMsg = "请填写公司名称";
|
errMsg = "请填写公司名称";
|
||||||
|
|
@ -764,20 +761,6 @@
|
||||||
} else if (!teamParams.legalPersionPhoneNum) {
|
} else if (!teamParams.legalPersionPhoneNum) {
|
||||||
errMsg = "请填写法人联系电话";
|
errMsg = "请填写法人联系电话";
|
||||||
}
|
}
|
||||||
}
|
|
||||||
if (teamParams.companySize == null || teamParams.companySize == undefined) {
|
|
||||||
errMsg = "请选择经营主体规模";
|
|
||||||
} else if (!teamParams.brandName) {
|
|
||||||
errMsg = "请填写品牌名称"
|
|
||||||
} else if (!teamParams.idCardImgList || !teamParams.idCardImgList.length) {
|
|
||||||
errMsg = "请上传身份证照片"
|
|
||||||
} else if (!teamParams.surname) {
|
|
||||||
errMsg = "请填写姓氏"
|
|
||||||
} else if (!teamParams.name) {
|
|
||||||
errMsg = "请填写名字"
|
|
||||||
} else if (!teamParams.idCardNum) {
|
|
||||||
errMsg = "请填写身份证号";
|
|
||||||
}
|
|
||||||
if (errMsg) {
|
if (errMsg) {
|
||||||
uni.showToast({
|
uni.showToast({
|
||||||
icon: 'none',
|
icon: 'none',
|
||||||
|
|
@ -890,7 +873,7 @@
|
||||||
position: relative;
|
position: relative;
|
||||||
height: 60rpx;
|
height: 60rpx;
|
||||||
line-height: 60rpx;
|
line-height: 60rpx;
|
||||||
flex-basis: 55%;
|
flex-basis: 40%;
|
||||||
}
|
}
|
||||||
|
|
||||||
.form-opt {
|
.form-opt {
|
||||||
|
|
|
||||||
|
|
@ -1,420 +0,0 @@
|
||||||
<template>
|
|
||||||
<view>
|
|
||||||
<!-- 顶部操作条 -->
|
|
||||||
<cu-custom :bgColor="'bg-main-color'" :isBack="true">
|
|
||||||
<block slot="backText">返回</block>
|
|
||||||
<block slot="content">{{mode === 1 ? '新增' : '编辑'}}店铺</block>
|
|
||||||
</cu-custom>
|
|
||||||
<!-- 地址信息form -->
|
|
||||||
<view class="bg-white margin-top-sm">
|
|
||||||
<form @submit="submit">
|
|
||||||
<view style="padding: 0 30rpx;">
|
|
||||||
<view class="padding-tb-sm flex justify-between align-center">
|
|
||||||
<text>店铺门头</text>
|
|
||||||
<text style="font-size: 20rpx;">1张门头照+3张店内照 (至少1张,门头照排前)</text>
|
|
||||||
</view>
|
|
||||||
<view>
|
|
||||||
<div class="grid col-3 grid-square">
|
|
||||||
<view class="bg-img" v-for="(item,index) in imgList" :key="index"
|
|
||||||
@tap="viewImage($event, imgList)" :data-url="item">
|
|
||||||
<image :src="item" mode="aspectFill"></image>
|
|
||||||
<view class="cu-tag bg-red" @tap.stop="delImg($event, imgList)" :data-index="index">
|
|
||||||
<text class='cuIcon-close'></text>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="solids" @tap="chooseImage" v-if="imgList.length < 6">
|
|
||||||
<text class='cuIcon-cameraadd'></text>
|
|
||||||
</view>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<!-- #ifndef H5 || APP-PLUS || MP-ALIPAY -->
|
|
||||||
<view class="cu-form-group">
|
|
||||||
<view class="title">联系地址</view>
|
|
||||||
<picker :mode="'multiSelector'" @change="regionChange" @columnchange="regionColChange" :value="multiIndex" :range-key="'areaName'" :range="areaList">
|
|
||||||
<view class="picker">
|
|
||||||
{{formData.area && formData.area.length ? formData.area[0].areaName + '-' + formData.area[1].areaName + '-' + formData.area[2].areaName + '-' + formData.area[3].areaName : '请选择'}}
|
|
||||||
</view>
|
|
||||||
</picker>
|
|
||||||
</view>
|
|
||||||
<!-- #endif -->
|
|
||||||
<view class="cu-form-group">
|
|
||||||
<view class="title">详细地址</view>
|
|
||||||
<input name="address" v-model="formData.address"></input>
|
|
||||||
<view class="text-blue" @click="getLocation">定位上传</view>
|
|
||||||
</view>
|
|
||||||
<view class="cu-form-group">
|
|
||||||
<view class="title">门店名称</view>
|
|
||||||
<input name="shopName" v-model="formData.shopName"></input>
|
|
||||||
</view>
|
|
||||||
<view class="cu-form-group">
|
|
||||||
<view class="title">门店电话</view>
|
|
||||||
<input name="phone" v-model="formData.phone" placeholder="请输入门店客户接待电话"></input>
|
|
||||||
</view>
|
|
||||||
<!-- 底部操作栏 -->
|
|
||||||
<view class="cu-bar tabbar border shop fixed-bottom-bar">
|
|
||||||
<button class="cu-btn bg-main-color long-btn margin-lr-sm shadow-blur" form-type="submit">保存</button>
|
|
||||||
</view>
|
|
||||||
</form>
|
|
||||||
</view>
|
|
||||||
|
|
||||||
|
|
||||||
<!-- <view class="cu-modal" :class="isLocationShow?'show':''">
|
|
||||||
<view class="cu-dialog bg-white">
|
|
||||||
<view class="cu-bar bg-white justify-end solid-bottom">
|
|
||||||
<view class="content">提示</view>
|
|
||||||
<view class="action" @click="isLocationShow = false">
|
|
||||||
<text class="cuIcon-close text-red"></text>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="padding-xl text-left bg-white">
|
|
||||||
<view>
|
|
||||||
点击确定定位,会按你当前位置上传。(添加店铺本次定位上传时,请在店铺内操作)!
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="cu-bar bg-white solid-top">
|
|
||||||
<view class="action margin-0 flex-sub text-black" @tap="isLocationShow = false">关闭</view>
|
|
||||||
<view class="action margin-0 flex-sub text-main-color solid-left"
|
|
||||||
@click="getLocation">确定定位</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view> -->
|
|
||||||
|
|
||||||
<!-- 前往授权设置 -->
|
|
||||||
<!-- <view class="cu-modal" :class="isShowPrivSetting?'show':''">
|
|
||||||
<view class="cu-dialog">
|
|
||||||
<view class="padding-xl text-left">
|
|
||||||
<view>需先授权定位功能才可正常使用功能</view>
|
|
||||||
</view>
|
|
||||||
<view class="cu-bar bg-white">
|
|
||||||
<navigator class="modal-bottom-oper margin-0 flex-sub text-black" open-type="exit"
|
|
||||||
target="miniProgram">拒绝授权
|
|
||||||
</navigator>
|
|
||||||
<button class="cu-btn modal-bottom-oper margin-0 flex-sub text-main-color bg-white solid-left"
|
|
||||||
open-type="openSetting" @opensetting="authLocationCallback">前往授权</button>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view> -->
|
|
||||||
</view>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<script>
|
|
||||||
export default {
|
|
||||||
data() {
|
|
||||||
return {
|
|
||||||
areaList: [],
|
|
||||||
multiIndex: [0, 0, 0],
|
|
||||||
formData: {
|
|
||||||
},
|
|
||||||
mode: 1, // 1为新增,0为修改
|
|
||||||
imgList: [],
|
|
||||||
isLocationShow: false,
|
|
||||||
isShowPrivSetting: false
|
|
||||||
}
|
|
||||||
},
|
|
||||||
onLoad(options) {
|
|
||||||
let params = JSON.parse(decodeURIComponent(options.params));
|
|
||||||
this.mode = params ? params.mode : this.mode;
|
|
||||||
console.log(this.mode)
|
|
||||||
if (this.mode === 0) {
|
|
||||||
// 修改
|
|
||||||
this.fillForm(params.addressInfo);
|
|
||||||
} else {
|
|
||||||
this.formData = {
|
|
||||||
area: [],
|
|
||||||
shopName: '',
|
|
||||||
address: '',
|
|
||||||
phone: '',
|
|
||||||
provinceId: '',
|
|
||||||
provinceName: '',
|
|
||||||
cityId: '',
|
|
||||||
cityName: '',
|
|
||||||
countryId: '',
|
|
||||||
countryName: '',
|
|
||||||
streetId: '',
|
|
||||||
streetName: '',
|
|
||||||
longitude: '',
|
|
||||||
latitude: ''
|
|
||||||
}
|
|
||||||
}
|
|
||||||
this.loadData();
|
|
||||||
},
|
|
||||||
methods: {
|
|
||||||
chooseImage(e) {
|
|
||||||
uni.chooseMedia({
|
|
||||||
count: 1, //默认9
|
|
||||||
mediaType: ['image'],
|
|
||||||
sizeType: ['original', 'compressed'], //可以指定是原图还是压缩图,默认二者都有
|
|
||||||
sourceType: ['album'], //从相册选择
|
|
||||||
success: (res) => {
|
|
||||||
uni.showLoading({
|
|
||||||
title: '上传中',
|
|
||||||
mask: true
|
|
||||||
});
|
|
||||||
res.tempFiles.forEach((fileObj, index) => {
|
|
||||||
this.$request.uploadFile(fileObj.tempFilePath).then((url) => {
|
|
||||||
this.imgList.push(url);
|
|
||||||
if (index === res.tempFiles.length - 1) {
|
|
||||||
uni.hideLoading();
|
|
||||||
}
|
|
||||||
});
|
|
||||||
});
|
|
||||||
}
|
|
||||||
});
|
|
||||||
},
|
|
||||||
viewImage(e, imgList) {
|
|
||||||
uni.previewImage({
|
|
||||||
urls: imgList,
|
|
||||||
current: e.currentTarget.dataset.url
|
|
||||||
});
|
|
||||||
},
|
|
||||||
delImg(e, imgList) {
|
|
||||||
uni.showModal({
|
|
||||||
title: '',
|
|
||||||
content: '确定要删除这张图片吗?',
|
|
||||||
cancelText: '取消',
|
|
||||||
confirmText: '确定',
|
|
||||||
success: res => {
|
|
||||||
if (res.confirm) {
|
|
||||||
imgList.splice(e.currentTarget.dataset.index, 1)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
})
|
|
||||||
},
|
|
||||||
async loadData() {
|
|
||||||
// this.areaList = await this.$api.data('areaList');
|
|
||||||
this.loadAreaList();
|
|
||||||
},
|
|
||||||
fillForm(addressInfo) {
|
|
||||||
this.formData = addressInfo && Object.keys(addressInfo).length > 0 ? addressInfo : this.formData;
|
|
||||||
this.imgList = addressInfo.imageUrl ? addressInfo.imageUrl.split(',') : []
|
|
||||||
},
|
|
||||||
// async authLocationCallback(res) {
|
|
||||||
// if (res.detail.authSetting['scope.userLocation']) {
|
|
||||||
// this.isShowPrivSetting = false;
|
|
||||||
// this.getLocation();
|
|
||||||
// }
|
|
||||||
// },
|
|
||||||
async getLocation() {
|
|
||||||
// let res = await wx.getSetting();
|
|
||||||
// console.log(res);
|
|
||||||
// if (res && !res.authSetting['scope.userLocation']) {
|
|
||||||
// wx.authorize({
|
|
||||||
// scope: 'scope.userLocation',
|
|
||||||
// success: () => {
|
|
||||||
// this.getLocation()
|
|
||||||
// },
|
|
||||||
// fail: () => {
|
|
||||||
// this.isShowPrivSetting = true;
|
|
||||||
// }
|
|
||||||
// });
|
|
||||||
// return;
|
|
||||||
// }
|
|
||||||
// const res = await this.$request.GetCurrentLocation()
|
|
||||||
wx.chooseLocation({
|
|
||||||
success: async (res1) => {
|
|
||||||
const res = await this.$request.TransformLocation(res1)
|
|
||||||
console.log(res);
|
|
||||||
this.formData.area = [res.provinceArea, res.cityArea, res.countryArea, res.streetArea]
|
|
||||||
this.formData.provinceId = res.provinceArea.areaId;
|
|
||||||
this.formData.provinceName = res.provinceArea.areaName;
|
|
||||||
this.formData.cityId = res.cityArea.areaId;
|
|
||||||
this.formData.cityName = res.cityArea.areaName;
|
|
||||||
this.formData.countryId = res.countryArea.areaId;
|
|
||||||
this.formData.countryName = res.countryArea.areaName;
|
|
||||||
this.formData.streetId = res.streetArea.areaId;
|
|
||||||
this.formData.streetName = res.streetArea.areaName;
|
|
||||||
this.formData.latitude = res.latitude;
|
|
||||||
this.formData.longitude = res.longitude;
|
|
||||||
this.isLocationShow = false
|
|
||||||
},
|
|
||||||
fail: (err) => {
|
|
||||||
console.error('选择位置失败', err);
|
|
||||||
// uni.showModal({
|
|
||||||
// title: '提示',
|
|
||||||
// content: '定位获取失败,请确认是否开启定位',
|
|
||||||
// cancelText: '取消',
|
|
||||||
// confirmText: '重试',
|
|
||||||
// success: res => {
|
|
||||||
// if (res.confirm) {
|
|
||||||
// this.getLocation();
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// })
|
|
||||||
}
|
|
||||||
});
|
|
||||||
},
|
|
||||||
async loadAreaList(idArr) {
|
|
||||||
let areaList = await this.$request.areaListByStep();
|
|
||||||
areaList = areaList.data;
|
|
||||||
let col1Code = idArr ? idArr[0] : areaList[0].areaCode;
|
|
||||||
let subAreaList = await this.$request.areaListByStep({ parentCode: col1Code });
|
|
||||||
subAreaList = subAreaList.data;
|
|
||||||
let col2Code = idArr ? idArr[1] : subAreaList[0].areaCode;
|
|
||||||
let subSubAreaList = await this.$request.areaListByStep({ parentCode: col2Code });
|
|
||||||
subSubAreaList = subSubAreaList.data;
|
|
||||||
let col3Code = idArr ? idArr[2] : subSubAreaList[0].areaCode;
|
|
||||||
let subSub2AreaList = await this.$request.areaListByStep({ parentCode: col3Code });
|
|
||||||
subSub2AreaList = subSub2AreaList.data;
|
|
||||||
this.areaList.push(areaList);
|
|
||||||
this.areaList.push(subAreaList);
|
|
||||||
this.areaList.push(subSubAreaList);
|
|
||||||
this.areaList.push(subSub2AreaList);
|
|
||||||
},
|
|
||||||
regionChange(e) {
|
|
||||||
this.multiIndex = e.detail.value;
|
|
||||||
let chosenArea = [];
|
|
||||||
for(let i = 0; i < this.areaList.length; i++) {
|
|
||||||
chosenArea.push(this.areaList[i][this.multiIndex[i]]);
|
|
||||||
}
|
|
||||||
this.formData.area = chosenArea;
|
|
||||||
this.formData.provinceId = chosenArea[0].areaId;
|
|
||||||
this.formData.provinceName = chosenArea[0].areaName;
|
|
||||||
this.formData.cityId = chosenArea[1].areaId;
|
|
||||||
this.formData.cityName = chosenArea[1].areaName;
|
|
||||||
this.formData.countryId = chosenArea[2].areaId;
|
|
||||||
this.formData.countryName = chosenArea[2].areaName;
|
|
||||||
this.formData.streetId = chosenArea[3].areaId;
|
|
||||||
this.formData.streetName = chosenArea[3].areaName;
|
|
||||||
},
|
|
||||||
async regionColChange(e) {
|
|
||||||
let colObj = e.detail;
|
|
||||||
if (colObj.column == 0) {
|
|
||||||
let subSubAreaList = [], subSub2AreaList = [];
|
|
||||||
// 通过一级查询二级,通过二级查三级
|
|
||||||
let subAreaList = await this.$request.areaListByStep({parentCode: this.areaList[0][colObj.value].areaCode});
|
|
||||||
subAreaList = subAreaList.data;
|
|
||||||
if (subAreaList && subAreaList.length) {
|
|
||||||
subSubAreaList = await this.$request.areaListByStep({parentCode: subAreaList[0].areaCode});
|
|
||||||
subSubAreaList = subSubAreaList.data;
|
|
||||||
if(subSubAreaList && subSubAreaList.length) {
|
|
||||||
subSub2AreaList = await this.$request.areaListByStep({parentCode: subSubAreaList[0].areaCode});
|
|
||||||
subSub2AreaList = subSub2AreaList.data;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
this.areaList[1] = subAreaList
|
|
||||||
this.areaList[2] = subSubAreaList
|
|
||||||
this.areaList[3] = subSub2AreaList
|
|
||||||
this.multiIndex = [colObj.value, 0, 0, 0];
|
|
||||||
} else if (colObj.column == 1) {
|
|
||||||
let subSub2AreaList = []
|
|
||||||
// 通过二级查三级
|
|
||||||
let subSubAreaList = await this.$request.areaListByStep({parentCode: this.areaList[1][colObj.value].areaCode});
|
|
||||||
subSubAreaList = subSubAreaList.data;
|
|
||||||
if (subSubAreaList && subSubAreaList.length) {
|
|
||||||
subSub2AreaList = await this.$request.areaListByStep({parentCode: subSubAreaList[0].areaCode});
|
|
||||||
subSub2AreaList = subSub2AreaList.data;
|
|
||||||
}
|
|
||||||
this.areaList[2] = subSubAreaList
|
|
||||||
this.areaList[3] = subSub2AreaList
|
|
||||||
this.multiIndex = [this.multiIndex[0], colObj.value, 0, 0];
|
|
||||||
} else if (colObj.column == 2) {
|
|
||||||
// 通过二级查三级
|
|
||||||
let subSubAreaList = await this.$request.areaListByStep({parentCode: this.areaList[2][colObj.value].areaCode});
|
|
||||||
subSubAreaList = subSubAreaList.data;
|
|
||||||
this.areaList[3] = subSubAreaList;
|
|
||||||
this.multiIndex = [this.multiIndex[0], this.multiIndex[1], colObj.value, 0];
|
|
||||||
}
|
|
||||||
},
|
|
||||||
validateForm(addressInfo) {
|
|
||||||
console.log(addressInfo);
|
|
||||||
if(this.imgList.length === 0) {
|
|
||||||
uni.showToast({
|
|
||||||
title: '请至少上传一张门头图',
|
|
||||||
icon: 'none',
|
|
||||||
mask: true
|
|
||||||
})
|
|
||||||
return false
|
|
||||||
}
|
|
||||||
if(!addressInfo.latitude || !addressInfo.longitude) {
|
|
||||||
uni.showToast({
|
|
||||||
title: '请先点击定位上传',
|
|
||||||
icon: 'none',
|
|
||||||
mask: true
|
|
||||||
})
|
|
||||||
return false
|
|
||||||
}
|
|
||||||
|
|
||||||
if(!addressInfo.area || addressInfo.area.length === 0) {
|
|
||||||
uni.showToast({
|
|
||||||
title: '请选择联系地址',
|
|
||||||
icon: 'none',
|
|
||||||
mask: true
|
|
||||||
})
|
|
||||||
return false
|
|
||||||
}
|
|
||||||
|
|
||||||
if (!addressInfo.address) {
|
|
||||||
uni.showToast({
|
|
||||||
title: '请填写详细地址',
|
|
||||||
icon: 'none',
|
|
||||||
mask: true
|
|
||||||
})
|
|
||||||
return false
|
|
||||||
}
|
|
||||||
if (!addressInfo.shopName) {
|
|
||||||
uni.showToast({
|
|
||||||
title: '请输入门店名称',
|
|
||||||
icon: 'none',
|
|
||||||
mask: true
|
|
||||||
})
|
|
||||||
return false
|
|
||||||
}
|
|
||||||
if (!this.$validate.validContactNum(addressInfo.phone)) {
|
|
||||||
uni.showToast({
|
|
||||||
title: '联系号码格式错误',
|
|
||||||
icon: 'none',
|
|
||||||
mask: true
|
|
||||||
})
|
|
||||||
return false
|
|
||||||
}
|
|
||||||
return true;
|
|
||||||
},
|
|
||||||
async submit(e) {
|
|
||||||
const confirmFormData = {...this.formData}
|
|
||||||
console.log(confirmFormData);
|
|
||||||
let formValid = this.validateForm(confirmFormData);
|
|
||||||
if (formValid) {
|
|
||||||
let isSuccess = false;
|
|
||||||
if (this.mode === 1) {
|
|
||||||
let res = await this.$request.addShopAddressList({
|
|
||||||
...this.formData,
|
|
||||||
imageUrl: this.imgList.toString(),
|
|
||||||
workerId: this.$request.getCurUserInfo().workerId
|
|
||||||
});
|
|
||||||
if (res.code === 0) {
|
|
||||||
isSuccess = true;
|
|
||||||
}
|
|
||||||
} else if (this.mode === 0) {
|
|
||||||
let res = await this.$request.editShopAddressList({
|
|
||||||
...this.formData,
|
|
||||||
imageUrl: this.imgList.toString(),
|
|
||||||
workerId: this.$request.getCurUserInfo().workerId,
|
|
||||||
});
|
|
||||||
if (res.code === 0) {
|
|
||||||
isSuccess = true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if (isSuccess) {
|
|
||||||
uni.showToast({
|
|
||||||
title: '保存成功',
|
|
||||||
icon: 'success',
|
|
||||||
mask: true
|
|
||||||
})
|
|
||||||
uni.navigateBack()
|
|
||||||
} else {
|
|
||||||
uni.showToast({
|
|
||||||
title: '保存失败',
|
|
||||||
icon: 'error',
|
|
||||||
mask: true
|
|
||||||
})
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
</script>
|
|
||||||
|
|
||||||
<style>
|
|
||||||
</style>
|
|
||||||
|
|
@ -1,741 +0,0 @@
|
||||||
<template>
|
|
||||||
<view>
|
|
||||||
<!-- 顶部操作条 -->
|
|
||||||
<cu-custom :bgColor="'bg-main-color'" :isBack="true">
|
|
||||||
<block slot="backText">返回</block>
|
|
||||||
<block slot="content">师傅入驻信息填写</block>
|
|
||||||
</cu-custom>
|
|
||||||
<!-- 步骤条 -->
|
|
||||||
<view class="bg-white padding">
|
|
||||||
<view class="cu-steps">
|
|
||||||
<view class="cu-item" :class="index>curStep?'':'text-main-color'" v-for="(stepName, index) in stepList" :key="stepName">
|
|
||||||
<text class='cuIcon-radioboxfill'></text> {{stepName}}
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<!-- 服务区域 -->
|
|
||||||
<view v-if="curStep === 0">
|
|
||||||
<view class="margin-bottom-with-bar">
|
|
||||||
<view class="bg-white margin-top-sm" v-for="(item, index) in servArea" :key="index">
|
|
||||||
<view class="cu-bar padding-lr solid-bottom">
|
|
||||||
<view class="text-lg">
|
|
||||||
<text class="cuIcon-titles"></text>
|
|
||||||
<text>发货区域{{index + 1}}(将按服务范围派单)</text>
|
|
||||||
</view>
|
|
||||||
<view @click="delServArea(index)">
|
|
||||||
<text class="text-main-color">删除</text>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="padding">
|
|
||||||
<view class="flex">
|
|
||||||
<my-uni-combox class="flex-sub margin-right-xs" :candidates="provinceList"
|
|
||||||
:showField="'areaName'" placeholder="选择省份" v-model="servArea[index].provinceObj"
|
|
||||||
@input="chooseRegion($event, 0, index)"></my-uni-combox>
|
|
||||||
<!-- <my-uni-combox class="flex-sub margin-right-xs" :candidates="servArea[index].cityList"
|
|
||||||
:showField="'areaName'" placeholder="选择城市" v-model="servArea[index].cityObj"
|
|
||||||
@input="chooseRegion($event, 1, index)" @tap="reloadTargetArea(1, index)"></my-uni-combox> -->
|
|
||||||
<!-- <my-uni-combox class="flex-sub" :candidates="servArea[index].districtList"
|
|
||||||
:showField="'areaName'" placeholder="选择地区" v-model="servArea[index].districtObj"
|
|
||||||
@input="chooseRegion($event, 2, index)" @tap="reloadTargetArea(2, index)"></my-uni-combox> -->
|
|
||||||
</view>
|
|
||||||
<checkbox-group @change="checkCity($event, index)" class="grid col-2 margin-top-xs">
|
|
||||||
<view v-for="(item0, index0) in servArea[index].cityList" :key="item0.areaCode" class="margin-tb-xs">
|
|
||||||
<checkbox style="transform:scale(1)" class="main-color margin-right-xs"
|
|
||||||
:value="item0.areaCode"
|
|
||||||
:checked="servArea[index].cityIds.indexOf(item0.areaId) !== -1 ? true : false">
|
|
||||||
</checkbox>
|
|
||||||
<text>{{item0.areaName}}</text>
|
|
||||||
</view>
|
|
||||||
</checkbox-group>
|
|
||||||
<!-- <checkbox-group @change="checkStreet($event, index)" class="grid col-2 margin-top-xs">
|
|
||||||
<view v-for="(item0, index0) in servArea[index].streetList" class="margin-tb-xs">
|
|
||||||
<checkbox style="transform:scale(1)" class="main-color margin-right-xs"
|
|
||||||
:value="item0.areaCode"
|
|
||||||
:checked="servArea[index].streetIds.indexOf(String(item0.areaCode)) !== -1 ? true : false">
|
|
||||||
</checkbox>
|
|
||||||
<text>{{item0.areaName}}</text>
|
|
||||||
</view>
|
|
||||||
</checkbox-group> -->
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="text-center margin-top">
|
|
||||||
<button class="cu-btn bg-main-color light" @click="addServArea">
|
|
||||||
<text class="margin-right-xs"><text class="cuIcon-add"></text></text>
|
|
||||||
<text>继续添加发货区域</text>
|
|
||||||
</button>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="bottom-site-bar"></view>
|
|
||||||
<!-- 下一步 -->
|
|
||||||
<view class="cu-bar tabbar border shop fixed-bottom-bar bg-back">
|
|
||||||
<button class="margin-lr cu-btn bg-main-color shadow-blur long-btn" @click="nextStep">下一步</button>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<!-- 服务技能 -->
|
|
||||||
<view v-if="curStep === 1">
|
|
||||||
<view class="margin-bottom-with-bar">
|
|
||||||
<view class="bg-white margin-top-sm" v-for="(item, index) in servSkill" :key="index">
|
|
||||||
<view class="cu-bar padding-lr solid-bottom">
|
|
||||||
<view class="text-lg">
|
|
||||||
<text class="cuIcon-titles"></text>
|
|
||||||
<text>货品类别{{index + 1}}(将按服务技能派单)</text>
|
|
||||||
</view>
|
|
||||||
<view @click="delServSkill(index)">
|
|
||||||
<text class="text-main-color">删除</text>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="padding">
|
|
||||||
<view class="flex">
|
|
||||||
<my-uni-combox class="flex-sub margin-right-xs" :candidates="typeList"
|
|
||||||
:showField="'goodsCategoryName'" placeholder="请选择" v-model="servSkill[index].typeObj"
|
|
||||||
@input="chooseType($event, 0, index)"></my-uni-combox>
|
|
||||||
<my-uni-combox class="flex-sub" :candidates="servSkill[index].subTypeList"
|
|
||||||
:showField="'goodsCategoryName'" placeholder="请选择" v-model="servSkill[index].subTypeObj"
|
|
||||||
@input="chooseType($event, 1, index)" @tap="reloadTargetCategory(1, index)"></my-uni-combox>
|
|
||||||
</view>
|
|
||||||
<checkbox-group @change="checkGoodType($event, index)" class="grid col-3 margin-top-xs">
|
|
||||||
<view v-for="(item0, index0) in servSkill[index].subSubTypeList" :key="item0.goodsCategoryId" class="margin-tb-xs">
|
|
||||||
<checkbox style="transform:scale(1)" class="main-color margin-right-xs"
|
|
||||||
:value="item0.goodsCategoryId"
|
|
||||||
:checked="servSkill[index].subSubTypeIds.indexOf(String(item0.goodsCategoryId)) !== -1 ? true : false">
|
|
||||||
</checkbox>
|
|
||||||
<text>{{item0.goodsCategoryName}}</text>
|
|
||||||
</view>
|
|
||||||
</checkbox-group>
|
|
||||||
<!-- <view>
|
|
||||||
<input type="text" class="radius-input" placeholder="输入其他服务,用“,”隔开。"
|
|
||||||
v-model="servSkill[index].otherServSkill">
|
|
||||||
</view> -->
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="text-center margin-top">
|
|
||||||
<button class="cu-btn bg-main-color light" @click="addServSkill">
|
|
||||||
<text class="margin-right-xs"><text class="cuIcon-add"></text></text>
|
|
||||||
<text>继续添加货品类别</text>
|
|
||||||
</button>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="bottom-site-bar"></view>
|
|
||||||
<!-- 下一步 -->
|
|
||||||
<view class="cu-bar tabbar border shop fixed-bottom-bar bg-back">
|
|
||||||
<button class="margin-lr-sm cu-btn bg-white shadow-blur long-btn" @click="preStep">上一步</button>
|
|
||||||
<!-- <button class="bg-main-color long-btn margin-lr" @click="nextStep">下一步</button> -->
|
|
||||||
<button class="margin-lr-sm cu-btn bg-main-color shadow-blur long-btn" @click="submit">提交</button>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view v-if="false" class="margin-top-sm">
|
|
||||||
<view class="margin-bottom-with-bar">
|
|
||||||
<view class="bg-white margin-top-sm" v-for="(item, index) in specialSkill" :key="index">
|
|
||||||
<view class="cu-bar padding-lr solid-bottom">
|
|
||||||
<view class="text-lg">
|
|
||||||
<text class="cuIcon-titles"></text>
|
|
||||||
<text>特殊技能{{index + 1}}(特殊工种如空调安装等请上传)</text>
|
|
||||||
</view>
|
|
||||||
<view @click="delSpecialSkill(index)">
|
|
||||||
<text class="text-main-color">删除</text>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="padding">
|
|
||||||
<view>
|
|
||||||
<text>特殊技能:</text>
|
|
||||||
<view>
|
|
||||||
<view class="flex align-center margin-bottom-xs">
|
|
||||||
<my-uni-combox class="flex-sub margin-right-xs" :candidates="specialTypeList"
|
|
||||||
:showField="'goodsCategoryName'" placeholder="请选择"
|
|
||||||
v-model="specialSkill[index].specialTypeObj" @input="chooseSpecialSkill($event, 0, index)">
|
|
||||||
</my-uni-combox>
|
|
||||||
<my-uni-combox class="flex-sub margin-right-xs"
|
|
||||||
:candidates="specialSkill[index].specialSubTypeList" :showField="'goodsCategoryName'"
|
|
||||||
placeholder="请选择" v-model="specialSkill[index].specialSubTypeObj"
|
|
||||||
@input="chooseSpecialSkill($event, 1, index)"></my-uni-combox>
|
|
||||||
<my-uni-combox class="flex-sub" :candidates="specialSkill[index].specialSubSubTypeList"
|
|
||||||
:showField="'goodsCategoryName'" placeholder="请选择"
|
|
||||||
v-model="specialSkill[index].specialSubSubTypeObj"
|
|
||||||
@input="chooseSpecialSkill($event, 2, index)"></my-uni-combox>
|
|
||||||
</view>
|
|
||||||
<my-uni-combox :candidates="specialSkill[index].specialSkillList"
|
|
||||||
:showField="'specialSkillName'" placeholder="请选择"
|
|
||||||
v-model="specialSkill[index].specialSkillObj"
|
|
||||||
@input="chooseSpecialSkill($event, 3, index)"></my-uni-combox>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="flex justify-start align-center margin-top-sm">
|
|
||||||
<view>技能证书:</view>
|
|
||||||
<view class="grid col-1 upload-pic-grid grid-square flex-sub">
|
|
||||||
<view class="bg-img" v-for="(url, index0) in specialSkill[index].skillCert" :key="index0"
|
|
||||||
@tap="viewImage($event, specialSkill[index].skillCert)" :data-url="url">
|
|
||||||
<image :src="url" mode="aspectFill"></image>
|
|
||||||
<view class="cu-tag bg-red" @tap.stop="delImg($event, specialSkill[index].skillCert)" :data-index="index0">
|
|
||||||
<text class='cuIcon-close'></text>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="solids" @tap="chooseImage($event, specialSkill[index].skillCert)" v-if="specialSkill[index].skillCert.length < 1">
|
|
||||||
<text class='cuIcon-cameraadd'></text>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="flex justify-start align-center margin-top-sm">
|
|
||||||
<view>保险证明:</view>
|
|
||||||
<view class="grid col-1 upload-pic-grid grid-square flex-sub">
|
|
||||||
<view class="bg-img" v-for="(url, index0) in specialSkill[index].insurCert" :key="index0"
|
|
||||||
@tap="viewImage($event, specialSkill[index].insurCert)" :data-url="url">
|
|
||||||
<image :src="url" mode="aspectFill"></image>
|
|
||||||
<view class="cu-tag bg-red" @tap.stop="delImg($event, specialSkill[index].insurCert)" :data-index="index0">
|
|
||||||
<text class='cuIcon-close'></text>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="solids" @tap="chooseImage($event, specialSkill[index].insurCert)" v-if="specialSkill[index].insurCert.length < 1">
|
|
||||||
<text class='cuIcon-cameraadd'></text>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="flex justify-start align-center">
|
|
||||||
<view>保险日期:</view>
|
|
||||||
<uni-datetime-picker style="width: 75%;"
|
|
||||||
:value="[specialSkill[index].insurStartDate, specialSkill[index].insurEndDate]"
|
|
||||||
type="datetimerange" rangeSeparator="~" @change="changeInsurDate($event, index)" />
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="text-center margin-top">
|
|
||||||
<button class="cu-btn bg-main-color light" @click="addSpecialSkill">
|
|
||||||
<text class="margin-right-xs"><text class="cuIcon-add"></text></text>
|
|
||||||
<text>继续添加特殊技能</text>
|
|
||||||
</button>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="bottom-site-bar"></view>
|
|
||||||
<!-- 下一步 -->
|
|
||||||
<view class="cu-bar tabbar border shop fixed-bottom-bar bg-back">
|
|
||||||
<button class="bg-white long-btn margin-lr" @click="preStep">上一步</button>
|
|
||||||
<button class="bg-main-color long-btn margin-lr" @click="submit">提交</button>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<script>
|
|
||||||
import myUniCombox from '@/components/uni-combox/my-uni-combox.vue';
|
|
||||||
|
|
||||||
export default {
|
|
||||||
components: {
|
|
||||||
myUniCombox
|
|
||||||
},
|
|
||||||
onLoad() {
|
|
||||||
this.loadData();
|
|
||||||
},
|
|
||||||
data() {
|
|
||||||
return {
|
|
||||||
curUserInfo: {},
|
|
||||||
curStep: 0,
|
|
||||||
// stepList: ['服务范围', '服务技能', '特殊技能'],
|
|
||||||
stepList: ['服务范围', '商品类目'],
|
|
||||||
provinceList: [],
|
|
||||||
servArea: [{
|
|
||||||
cityList: [],
|
|
||||||
districtList: [],
|
|
||||||
streetList: [],
|
|
||||||
provinceObj: {},
|
|
||||||
cityObj: {},
|
|
||||||
districtObj: {},
|
|
||||||
streetIds: [],
|
|
||||||
cityIds: []
|
|
||||||
}],
|
|
||||||
typeList: [],
|
|
||||||
servSkill: [{
|
|
||||||
subTypeList: [],
|
|
||||||
subSubTypeList: [],
|
|
||||||
typeObj: {},
|
|
||||||
subTypeObj: {},
|
|
||||||
subSubTypeIds: [],
|
|
||||||
otherServSkill: null
|
|
||||||
}],
|
|
||||||
specialTypeList: [],
|
|
||||||
specialSkill: [{
|
|
||||||
specialSubTypeList: [],
|
|
||||||
specialSubSubTypeList: [],
|
|
||||||
specialTypeObj: {},
|
|
||||||
specialSubTypeObj: {},
|
|
||||||
specialSubSubTypeObj: {},
|
|
||||||
specialSkillList: [],
|
|
||||||
specialSkillObj: {},
|
|
||||||
skillCert: [],
|
|
||||||
insurCert: [],
|
|
||||||
insurStartDate: '',
|
|
||||||
insurEndDate: ''
|
|
||||||
}],
|
|
||||||
}
|
|
||||||
},
|
|
||||||
methods: {
|
|
||||||
async loadData() {
|
|
||||||
this.curUserInfo = this.$request.getCurUserInfo();
|
|
||||||
await this.loadProvinceList();
|
|
||||||
await this.loadTypeList();
|
|
||||||
await this.loadExistData();
|
|
||||||
// this.loadSpecialSkill();
|
|
||||||
},
|
|
||||||
async loadExistData() {
|
|
||||||
this.loadServAreas();
|
|
||||||
this.loadServSkills();
|
|
||||||
},
|
|
||||||
async loadServAreas() {
|
|
||||||
let res = await this.$request.getWorkerAreaEdit({
|
|
||||||
workerId: this.curUserInfo.workerId,
|
|
||||||
type: 2
|
|
||||||
});
|
|
||||||
let servArea = [];
|
|
||||||
for(let i = 0; i < res.data.length; i++) {
|
|
||||||
let item = res.data[i];
|
|
||||||
let cityListRes = await this.$request.areaListByStep({
|
|
||||||
parentCode: item.provinceArea.areaCode
|
|
||||||
});
|
|
||||||
servArea.push({
|
|
||||||
cityList: cityListRes.data,
|
|
||||||
cityIds: item.cityIds,
|
|
||||||
districtList: [],
|
|
||||||
streetList: [],
|
|
||||||
provinceObj: item.provinceArea,
|
|
||||||
cityObj: item.cityArea,
|
|
||||||
districtObj: {},
|
|
||||||
streetIds: []
|
|
||||||
})
|
|
||||||
}
|
|
||||||
if (servArea.length > 0) {
|
|
||||||
this.servArea = servArea;
|
|
||||||
}
|
|
||||||
},
|
|
||||||
async loadServSkills() {
|
|
||||||
let res = await this.$request.getWorkerGoodsCategoryEdit({
|
|
||||||
workerId: this.curUserInfo.workerId,
|
|
||||||
type: 2
|
|
||||||
});
|
|
||||||
let servSkill = [];
|
|
||||||
if(res.data) {
|
|
||||||
for(let i = 0; i < res.data.length; i++) {
|
|
||||||
let item = res.data[i];
|
|
||||||
let subSubTypeRes = await this.$request.listByStep({
|
|
||||||
goodsCategoryId: item.twoGoodsCategory.goodsCategoryId,
|
|
||||||
type: 2
|
|
||||||
});
|
|
||||||
servSkill.push({
|
|
||||||
subTypeList: [],
|
|
||||||
subSubTypeList: subSubTypeRes.data,
|
|
||||||
typeObj: item.oneGoodsCategory,
|
|
||||||
subTypeObj: item.twoGoodsCategory,
|
|
||||||
subSubTypeIds: item.categoryIds
|
|
||||||
})
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if (servSkill.length > 0) {
|
|
||||||
this.servSkill = servSkill;
|
|
||||||
}
|
|
||||||
},
|
|
||||||
/* 服务区域 start */
|
|
||||||
async loadProvinceList() {
|
|
||||||
let res = await this.$request.areaListByStep();
|
|
||||||
this.provinceList = res.data;
|
|
||||||
},
|
|
||||||
async chooseRegion(e, type, index) {
|
|
||||||
let res = await this.$request.areaListByStep({
|
|
||||||
parentCode: e.areaCode
|
|
||||||
});
|
|
||||||
if (res.code == 0) {
|
|
||||||
switch (type) {
|
|
||||||
case 0: {
|
|
||||||
this.servArea[index].cityList = res.data;
|
|
||||||
this.servArea[index].districtList = [];
|
|
||||||
this.servArea[index].streetList = [];
|
|
||||||
this.servArea[index].cityObj = {};
|
|
||||||
this.servArea[index].districtObj = {};
|
|
||||||
this.servArea[index].streetIds = [];
|
|
||||||
this.servArea[index].cityIds = [];
|
|
||||||
}
|
|
||||||
break;
|
|
||||||
case 1: {
|
|
||||||
this.servArea[index].districtList = res.data;
|
|
||||||
this.servArea[index].streetList = [];
|
|
||||||
this.servArea[index].districtObj = {};
|
|
||||||
this.servArea[index].streetIds = [];
|
|
||||||
this.servArea[index].cityIds = [];
|
|
||||||
}
|
|
||||||
break;
|
|
||||||
case 2: {
|
|
||||||
this.servArea[index].streetList = res.data;
|
|
||||||
this.servArea[index].streetIds = [];
|
|
||||||
this.servArea[index].cityIds = [];
|
|
||||||
}
|
|
||||||
break;
|
|
||||||
default:
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
checkStreet(e, index) {
|
|
||||||
let checkedIndexArr = e.detail.value;
|
|
||||||
this.servArea[index].streetIds = checkedIndexArr;
|
|
||||||
},
|
|
||||||
checkCity(e, index) {
|
|
||||||
let checkedIndexArr = e.detail.value;
|
|
||||||
this.servArea[index].cityIds = checkedIndexArr;
|
|
||||||
},
|
|
||||||
addServArea() {
|
|
||||||
this.servArea.push({
|
|
||||||
cityList: [],
|
|
||||||
districtList: [],
|
|
||||||
streetList: [],
|
|
||||||
provinceObj: {},
|
|
||||||
cityObj: {},
|
|
||||||
districtObj: {},
|
|
||||||
streetIds: [],
|
|
||||||
cityIds: [],
|
|
||||||
});
|
|
||||||
},
|
|
||||||
delServArea(index) {
|
|
||||||
this.servArea.splice(index, 1);
|
|
||||||
},
|
|
||||||
async reloadTargetArea(colIndex, areaIndex) {
|
|
||||||
switch(colIndex) {
|
|
||||||
case 1: {
|
|
||||||
if (this.servArea[areaIndex].provinceObj
|
|
||||||
&& (!this.servArea[areaIndex].cityList
|
|
||||||
|| this.servArea[areaIndex].cityList.length === 0)) {
|
|
||||||
let res = await this.$request.areaListByStep({
|
|
||||||
parentCode: this.servArea[areaIndex].provinceObj.areaCode,
|
|
||||||
});
|
|
||||||
this.servArea[areaIndex].cityList = res.data;
|
|
||||||
}
|
|
||||||
} break;
|
|
||||||
case 2: {
|
|
||||||
if (this.servArea[areaIndex].cityObj
|
|
||||||
&& (!this.servArea[areaIndex].districtList
|
|
||||||
|| this.servArea[areaIndex].districtList.length === 0)) {
|
|
||||||
let res = await this.$request.areaListByStep({
|
|
||||||
parentCode: this.servArea[areaIndex].cityObj.areaCode,
|
|
||||||
});
|
|
||||||
this.servArea[areaIndex].districtList = res.data;
|
|
||||||
}
|
|
||||||
} break;
|
|
||||||
default: break;
|
|
||||||
}
|
|
||||||
},
|
|
||||||
/* 服务区域 end */
|
|
||||||
/* 服务技能 start */
|
|
||||||
async loadTypeList() {
|
|
||||||
let res = await this.$request.listByStep({
|
|
||||||
type: 2
|
|
||||||
});
|
|
||||||
res = res.data;
|
|
||||||
let typeList = await this.$request.listByStep({
|
|
||||||
type: 2,
|
|
||||||
goodsCategoryId: res[0].goodsCategoryId
|
|
||||||
});
|
|
||||||
this.typeList = typeList.data;
|
|
||||||
},
|
|
||||||
async chooseType(e, type, index) {
|
|
||||||
let res = await this.$request.listByStep({
|
|
||||||
goodsCategoryId: e.goodsCategoryId,
|
|
||||||
type: 2
|
|
||||||
});
|
|
||||||
if (res.code == 0) {
|
|
||||||
switch (type) {
|
|
||||||
case 0: {
|
|
||||||
this.servSkill[index].subTypeList = res.data;
|
|
||||||
this.servSkill[index].subSubTypeList = [];
|
|
||||||
this.servSkill[index].subTypeObj = {};
|
|
||||||
this.servSkill[index].subSubTypeIds = [];
|
|
||||||
}
|
|
||||||
break;
|
|
||||||
case 1: {
|
|
||||||
this.servSkill[index].subSubTypeList = res.data;
|
|
||||||
this.servSkill[index].subSubTypeIds = [];
|
|
||||||
}
|
|
||||||
break;
|
|
||||||
default:
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
checkGoodType(e, index) {
|
|
||||||
let checkedIndexArr = e.detail.value;
|
|
||||||
this.servSkill[index].subSubTypeIds = checkedIndexArr;
|
|
||||||
},
|
|
||||||
addServSkill() {
|
|
||||||
this.servSkill.push({
|
|
||||||
subTypeList: [],
|
|
||||||
subSubTypeList: [],
|
|
||||||
typeObj: {},
|
|
||||||
subTypeObj: {},
|
|
||||||
subSubTypeIds: [],
|
|
||||||
otherServSkill: null
|
|
||||||
});
|
|
||||||
},
|
|
||||||
delServSkill(index) {
|
|
||||||
this.servSkill.splice(index, 1);
|
|
||||||
},
|
|
||||||
async reloadTargetCategory(colIndex, servSkillIndex) {
|
|
||||||
switch(colIndex) {
|
|
||||||
case 1: {
|
|
||||||
if (this.servSkill[servSkillIndex].typeObj
|
|
||||||
&& (!this.servSkill[servSkillIndex].subTypeList
|
|
||||||
|| this.servSkill[servSkillIndex].subTypeList.length === 0)) {
|
|
||||||
let res = await this.$request.listByStep({
|
|
||||||
goodsCategoryId: this.servSkill[servSkillIndex].typeObj.goodsCategoryId,
|
|
||||||
type: 2
|
|
||||||
});
|
|
||||||
this.servSkill[servSkillIndex].subTypeList = res.data;
|
|
||||||
}
|
|
||||||
} break;
|
|
||||||
default: break;
|
|
||||||
}
|
|
||||||
},
|
|
||||||
/* 服务技能 end */
|
|
||||||
/* 特殊技能 start */
|
|
||||||
async loadSpecialSkill() {
|
|
||||||
let res = await this.$request.listByStep({
|
|
||||||
type: 2
|
|
||||||
});
|
|
||||||
res = res.data;
|
|
||||||
let typeList = await this.$request.listByStep({
|
|
||||||
type: 2,
|
|
||||||
goodsCategoryId: res[0].goodsCategoryId
|
|
||||||
});
|
|
||||||
this.specialTypeList = typeList.data;
|
|
||||||
},
|
|
||||||
async chooseSpecialSkill(e, type, index) {
|
|
||||||
let funName = "listByStep";
|
|
||||||
if (type === 2) {
|
|
||||||
funName = "qrySpecialSkillList";
|
|
||||||
}
|
|
||||||
let res = await this.$request[funName]({
|
|
||||||
goodsCategoryId: e.goodsCategoryId,
|
|
||||||
type: 2
|
|
||||||
});
|
|
||||||
if (res.code == 0) {
|
|
||||||
switch (type) {
|
|
||||||
case 0: {
|
|
||||||
this.specialSkill[index].specialSubTypeList = res.data;
|
|
||||||
this.specialSkill[index].specialSubSubTypeList = [];
|
|
||||||
this.specialSkill[index].specialSubTypeObj = {};
|
|
||||||
this.specialSkill[index].specialSubSubTypeObj = {};
|
|
||||||
}
|
|
||||||
break;
|
|
||||||
case 1: {
|
|
||||||
this.specialSkill[index].specialSubSubTypeList = res.data;
|
|
||||||
this.specialSkill[index].specialSubSubTypeObj = {};
|
|
||||||
}
|
|
||||||
case 2: {
|
|
||||||
this.specialSkill[index].specialSkillList = res.data;
|
|
||||||
this.specialSkill[index].specialSkillObj = {};
|
|
||||||
}
|
|
||||||
break;
|
|
||||||
default:
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
addSpecialSkill() {
|
|
||||||
this.specialSkill.push({
|
|
||||||
specialSubTypeList: [],
|
|
||||||
specialSubSubTypeList: [],
|
|
||||||
specialTypeObj: {},
|
|
||||||
specialSubTypeObj: {},
|
|
||||||
specialSubSubTypeObj: {},
|
|
||||||
skillCert: [],
|
|
||||||
insurCert: [],
|
|
||||||
insurStartDate: '',
|
|
||||||
insurEndDate: ''
|
|
||||||
});
|
|
||||||
},
|
|
||||||
delSpecialSkill(index) {
|
|
||||||
this.specialSkill.splice(index, 1);
|
|
||||||
},
|
|
||||||
changeInsurDate(e, index) {
|
|
||||||
this.specialSkill[index].insurStartDate = e[0];
|
|
||||||
this.specialSkill[index].insurEndDate = e[1];
|
|
||||||
},
|
|
||||||
async chooseImage(e, imgList) {
|
|
||||||
uni.chooseMedia({
|
|
||||||
count: 1, //默认9
|
|
||||||
mediaType: ['image'],
|
|
||||||
sizeType: ['original', 'compressed'], //可以指定是原图还是压缩图,默认二者都有
|
|
||||||
sourceType: ['album'], //从相册选择
|
|
||||||
success: (res) => {
|
|
||||||
// 上传图片
|
|
||||||
res.tempFiles.forEach((fileObj) => {
|
|
||||||
this.$request.uploadFile(fileObj.tempFilePath).then((url) => {
|
|
||||||
// 存入缓存
|
|
||||||
imgList.push(url);
|
|
||||||
});
|
|
||||||
})
|
|
||||||
}
|
|
||||||
});
|
|
||||||
},
|
|
||||||
viewImage(e, imgList) {
|
|
||||||
uni.previewImage({
|
|
||||||
urls: imgList,
|
|
||||||
current: e.currentTarget.dataset.url
|
|
||||||
});
|
|
||||||
},
|
|
||||||
delImg(e, imgList) {
|
|
||||||
uni.showModal({
|
|
||||||
title: '',
|
|
||||||
content: '确定要删除这张图片吗?',
|
|
||||||
cancelText: '取消',
|
|
||||||
confirmText: '确定',
|
|
||||||
success: res => {
|
|
||||||
if (res.confirm) {
|
|
||||||
imgList.splice(e.currentTarget.dataset.index, 1)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
})
|
|
||||||
},
|
|
||||||
/* 特殊技能 end */
|
|
||||||
nextStep() {
|
|
||||||
let workerAreas = [];
|
|
||||||
// 区域参数
|
|
||||||
this.servArea.forEach((item) => {
|
|
||||||
item.cityIds.forEach((cityId) => {
|
|
||||||
workerAreas.push({
|
|
||||||
provinceId: item.provinceObj.areaId,
|
|
||||||
cityId: cityId,
|
|
||||||
districtId: '',
|
|
||||||
streetId: ''
|
|
||||||
})
|
|
||||||
});
|
|
||||||
// item.streetIds.forEach((streetId) => {
|
|
||||||
// workerAreas.push({
|
|
||||||
// provinceId: item.provinceObj.areaId,
|
|
||||||
// cityId: item.cityObj.areaId,
|
|
||||||
// districtId: item.districtObj.areaId,
|
|
||||||
// streetId: streetId
|
|
||||||
// })
|
|
||||||
// });
|
|
||||||
});
|
|
||||||
let params = {
|
|
||||||
workerGoodsAreas: workerAreas
|
|
||||||
}
|
|
||||||
if (this.curStep === 0 && !this.validData(params)) {
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
this.curStep = this.curStep === this.stepList.length - 1 ? this.curStep : ++this.curStep;
|
|
||||||
},
|
|
||||||
preStep() {
|
|
||||||
this.curStep = this.curStep === 0 ? 0 : --this.curStep;
|
|
||||||
},
|
|
||||||
validData(data) {
|
|
||||||
let errMsg = null;
|
|
||||||
if (!data.workerGoodsAreas || !data.workerGoodsAreas.length) {
|
|
||||||
errMsg = '请至少添加一个服务区域(需要勾选到城市)';
|
|
||||||
}
|
|
||||||
if (this.curStep > 0) {
|
|
||||||
if (!data.goodsCategoryIds || !data.goodsCategoryIds.length) {
|
|
||||||
errMsg = '请至少添加一个服务技能(需要勾选到三级类目)';
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if (errMsg) {
|
|
||||||
uni.showToast({
|
|
||||||
icon: 'none',
|
|
||||||
title: errMsg,
|
|
||||||
duration: 3000
|
|
||||||
})
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
return true;
|
|
||||||
},
|
|
||||||
async submit() {
|
|
||||||
let workerId = this.curUserInfo.workerId;
|
|
||||||
let workerAreas = [];
|
|
||||||
let goodsCategories = [];
|
|
||||||
// let specialSkills = [];
|
|
||||||
// 区域参数
|
|
||||||
this.servArea.forEach((item) => {
|
|
||||||
// item.streetIds.forEach((streetId) => {
|
|
||||||
// workerAreas.push({
|
|
||||||
// workerId: workerId,
|
|
||||||
// provinceId: item.provinceObj.areaId,
|
|
||||||
// cityId: item.cityObj.areaId,
|
|
||||||
// districtId: item.districtObj.areaId,
|
|
||||||
// streetId: streetId
|
|
||||||
// })
|
|
||||||
// });
|
|
||||||
item.cityIds.forEach((cityId) => {
|
|
||||||
workerAreas.push({
|
|
||||||
workerId: workerId,
|
|
||||||
provinceId: item.provinceObj.areaId,
|
|
||||||
cityId: cityId,
|
|
||||||
districtId: '',
|
|
||||||
streetId: ''
|
|
||||||
})
|
|
||||||
});
|
|
||||||
});
|
|
||||||
// 服务品类参数
|
|
||||||
this.servSkill.forEach((item) => {
|
|
||||||
item.subSubTypeIds.forEach((goodsCategoryId) => {
|
|
||||||
// goodsCategories.push({
|
|
||||||
// workerId: workerId,
|
|
||||||
// goodsCategoryId: goodsCategoryId
|
|
||||||
// });
|
|
||||||
goodsCategories.push(goodsCategoryId)
|
|
||||||
});
|
|
||||||
});
|
|
||||||
// 特殊技能参数
|
|
||||||
// this.specialSkill.forEach((item) => {
|
|
||||||
// specialSkills.push({
|
|
||||||
// workerId: workerId,
|
|
||||||
// specialSkillId: item.specialSkillObj.specialSkillId,
|
|
||||||
// credential: item.skillCert[0],
|
|
||||||
// insurance: item.insurCert[0],
|
|
||||||
// insuranceStart: item.insurStartDate,
|
|
||||||
// insuranceEnd: item.insurEndDate
|
|
||||||
// });
|
|
||||||
// });
|
|
||||||
|
|
||||||
let params = {
|
|
||||||
workerId: workerId,
|
|
||||||
workerGoodsAreas: workerAreas,
|
|
||||||
goodsCategoryIds: goodsCategories,
|
|
||||||
// specialSkills: specialSkills
|
|
||||||
}
|
|
||||||
|
|
||||||
if (!this.validData(params)) {
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
let res = await this.$request.workerSettled(params);
|
|
||||||
if (res && res.code === 0) {
|
|
||||||
uni.showToast({
|
|
||||||
icon: 'success',
|
|
||||||
title: '提交成功',
|
|
||||||
duration: 2000
|
|
||||||
})
|
|
||||||
// 更新当前缓存的用户信息
|
|
||||||
let newUserInfo = await this.$request.getCurUserNoCache();
|
|
||||||
this.$request.updateCache('userProfile', newUserInfo);
|
|
||||||
uni.navigateBack({
|
|
||||||
delta: -1
|
|
||||||
})
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
}
|
|
||||||
</script>
|
|
||||||
|
|
||||||
<style scoped>
|
|
||||||
/deep/ .uni-combox__selector {
|
|
||||||
z-index: 99 !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
.grid.col-1.grid-square.upload-pic-grid>view {
|
|
||||||
padding-bottom: 35%;
|
|
||||||
height: 0;
|
|
||||||
margin-right: 20rpx;
|
|
||||||
}
|
|
||||||
|
|
||||||
.grid.col-1.upload-pic-grid>view {
|
|
||||||
width: 35%;
|
|
||||||
}
|
|
||||||
|
|
||||||
/deep/ .uni-date__x-input {
|
|
||||||
height: 36px;
|
|
||||||
}
|
|
||||||
</style>
|
|
||||||
|
|
@ -270,8 +270,7 @@
|
||||||
},
|
},
|
||||||
async loadServAreas() {
|
async loadServAreas() {
|
||||||
let res = await this.$request.getWorkerAreaEdit({
|
let res = await this.$request.getWorkerAreaEdit({
|
||||||
workerId: this.curUserInfo.workerId,
|
workerId: this.curUserInfo.workerId
|
||||||
type: 1
|
|
||||||
});
|
});
|
||||||
let servArea = [];
|
let servArea = [];
|
||||||
for(let i = 0; i < res.data.length; i++) {
|
for(let i = 0; i < res.data.length; i++) {
|
||||||
|
|
@ -295,8 +294,7 @@
|
||||||
},
|
},
|
||||||
async loadServSkills() {
|
async loadServSkills() {
|
||||||
let res = await this.$request.getWorkerGoodsCategoryEdit({
|
let res = await this.$request.getWorkerGoodsCategoryEdit({
|
||||||
workerId: this.curUserInfo.workerId,
|
workerId: this.curUserInfo.workerId
|
||||||
type: 1
|
|
||||||
});
|
});
|
||||||
let servSkill = [];
|
let servSkill = [];
|
||||||
for(let i = 0; i < res.data.length; i++) {
|
for(let i = 0; i < res.data.length; i++) {
|
||||||
|
|
@ -533,15 +531,14 @@
|
||||||
this.specialSkill[index].insurEndDate = e[1];
|
this.specialSkill[index].insurEndDate = e[1];
|
||||||
},
|
},
|
||||||
async chooseImage(e, imgList) {
|
async chooseImage(e, imgList) {
|
||||||
uni.chooseMedia({
|
uni.chooseImage({
|
||||||
count: 1, //默认9
|
count: 1, //默认9
|
||||||
mediaType: ['image'],
|
|
||||||
sizeType: ['original', 'compressed'], //可以指定是原图还是压缩图,默认二者都有
|
sizeType: ['original', 'compressed'], //可以指定是原图还是压缩图,默认二者都有
|
||||||
sourceType: ['album'], //从相册选择
|
sourceType: ['album'], //从相册选择
|
||||||
success: (res) => {
|
success: (res) => {
|
||||||
// 上传图片
|
// 上传图片
|
||||||
res.tempFiles.forEach((fileObj) => {
|
res.tempFilePaths.forEach((tmpPath) => {
|
||||||
this.$request.uploadFile(fileObj.tempFilePath).then((url) => {
|
this.$request.uploadFile(tmpPath).then((url) => {
|
||||||
// 存入缓存
|
// 存入缓存
|
||||||
imgList.push(url);
|
imgList.push(url);
|
||||||
});
|
});
|
||||||
|
|
@ -594,13 +591,12 @@
|
||||||
this.curStep = this.curStep === 0 ? 0 : --this.curStep;
|
this.curStep = this.curStep === 0 ? 0 : --this.curStep;
|
||||||
},
|
},
|
||||||
validData(data) {
|
validData(data) {
|
||||||
console.log(data);
|
|
||||||
let errMsg = null;
|
let errMsg = null;
|
||||||
if (!data.workerAreas || !data.workerAreas.length) {
|
if (!data.workerAreas || !data.workerAreas.length) {
|
||||||
errMsg = '请至少添加一个服务区域(需要勾选到服务街道)';
|
errMsg = '请至少添加一个服务区域(需要勾选到服务街道)';
|
||||||
}
|
}
|
||||||
if (this.curStep > 0) {
|
if (this.curStep > 0) {
|
||||||
if (!(data.serviceCategoryIds && data.serviceCategoryIds.length)) {
|
if (!data.goodsCategories || !data.goodsCategories.length) {
|
||||||
errMsg = '请至少添加一个服务技能(需要勾选到三级类目)';
|
errMsg = '请至少添加一个服务技能(需要勾选到三级类目)';
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -634,11 +630,10 @@
|
||||||
// 服务品类参数
|
// 服务品类参数
|
||||||
this.servSkill.forEach((item) => {
|
this.servSkill.forEach((item) => {
|
||||||
item.subSubTypeIds.forEach((goodsCategoryId) => {
|
item.subSubTypeIds.forEach((goodsCategoryId) => {
|
||||||
// goodsCategories.push({
|
goodsCategories.push({
|
||||||
// workerId: workerId,
|
workerId: workerId,
|
||||||
// goodsCategoryId: goodsCategoryId
|
goodsCategoryId: goodsCategoryId
|
||||||
// });
|
});
|
||||||
goodsCategories.push(goodsCategoryId)
|
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
// 特殊技能参数
|
// 特殊技能参数
|
||||||
|
|
@ -656,7 +651,7 @@
|
||||||
let params = {
|
let params = {
|
||||||
workerId: workerId,
|
workerId: workerId,
|
||||||
workerAreas: workerAreas,
|
workerAreas: workerAreas,
|
||||||
serviceCategoryIds: goodsCategories,
|
goodsCategories: goodsCategories,
|
||||||
// specialSkills: specialSkills
|
// specialSkills: specialSkills
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -8,14 +8,14 @@
|
||||||
<view v-if="(servSkills && servSkills.length) || (servAreas && servAreas.length) " class="margin bg-white">
|
<view v-if="(servSkills && servSkills.length) || (servAreas && servAreas.length) " class="margin bg-white">
|
||||||
<view class="padding">
|
<view class="padding">
|
||||||
<view class="text-black text-bold">服务区域:</view>
|
<view class="text-black text-bold">服务区域:</view>
|
||||||
<view v-for="(item,index) in servAreas" :key="index">
|
<view v-for="(item,index) in servAreas">
|
||||||
<text>{{strReplace(item.mergerName, "-", ",")}}</text>
|
<text>{{strReplace(item.mergerName, "-", ",")}}</text>
|
||||||
<!-- <text v-if="index !== servAreas.length - 1">,</text> -->
|
<!-- <text v-if="index !== servAreas.length - 1">,</text> -->
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="padding">
|
<view class="padding">
|
||||||
<view class="text-black text-bold">服务技能:</view>
|
<view class="text-black text-bold">服务技能:</view>
|
||||||
<view v-for="(item,index) in servSkills" :key="index">
|
<view v-for="(item,index) in servSkills">
|
||||||
<text>{{item.mergeName}}</text>
|
<text>{{item.mergeName}}</text>
|
||||||
<!-- <text v-if="index !== servSkills.length - 1">,</text> -->
|
<!-- <text v-if="index !== servSkills.length - 1">,</text> -->
|
||||||
</view>
|
</view>
|
||||||
|
|
@ -60,15 +60,12 @@
|
||||||
curUserInfo: {},
|
curUserInfo: {},
|
||||||
servAreas: [],
|
servAreas: [],
|
||||||
servSkills: [],
|
servSkills: [],
|
||||||
servSpecialSkills: [],
|
servSpecialSkills: []
|
||||||
serviceType: null
|
|
||||||
}
|
|
||||||
},
|
|
||||||
onLoad(options) {
|
|
||||||
if(options.type) {
|
|
||||||
this.serviceType = options.type
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
// onLoad() {
|
||||||
|
// this.loadData();
|
||||||
|
// },
|
||||||
onShow() {
|
onShow() {
|
||||||
this.loadData();
|
this.loadData();
|
||||||
},
|
},
|
||||||
|
|
@ -77,26 +74,23 @@
|
||||||
this.curUserInfo = await this.$request.getCurUserNoCache();
|
this.curUserInfo = await this.$request.getCurUserNoCache();
|
||||||
this.loadServAreas();
|
this.loadServAreas();
|
||||||
this.loadServSkills();
|
this.loadServSkills();
|
||||||
// this.loadSpecialSkills();
|
this.loadSpecialSkills();
|
||||||
},
|
},
|
||||||
async loadServAreas() {
|
async loadServAreas() {
|
||||||
let res = await this.$request.getWorkerArea({
|
let res = await this.$request.getWorkerArea({
|
||||||
workerId: this.curUserInfo.workerId,
|
workerId: this.curUserInfo.workerId
|
||||||
serviceType: this.serviceType
|
|
||||||
});
|
});
|
||||||
this.servAreas = res.data;
|
this.servAreas = res.data;
|
||||||
},
|
},
|
||||||
async loadServSkills() {
|
async loadServSkills() {
|
||||||
let res = await this.$request.getWorkerGoodsCategory({
|
let res = await this.$request.getWorkerGoodsCategory({
|
||||||
workerId: this.curUserInfo.workerId,
|
workerId: this.curUserInfo.workerId
|
||||||
serviceType: this.serviceType
|
|
||||||
});
|
});
|
||||||
this.servSkills = res.data;
|
this.servSkills = res.data;
|
||||||
},
|
},
|
||||||
async loadSpecialSkills() {
|
async loadSpecialSkills() {
|
||||||
let res = await this.$request.getWorkerSpecialSkill({
|
let res = await this.$request.getWorkerSpecialSkill({
|
||||||
workerId: this.curUserInfo.workerId,
|
workerId: this.curUserInfo.workerId
|
||||||
serviceType: this.serviceType
|
|
||||||
});
|
});
|
||||||
this.servSpecialSkills = res.data;
|
this.servSpecialSkills = res.data;
|
||||||
},
|
},
|
||||||
|
|
@ -107,15 +101,9 @@
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
navigate2ApplySettled() {
|
navigate2ApplySettled() {
|
||||||
if(this.serviceType == 1) {
|
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url: '/pages/my/master-occupancy'
|
url: '/pages/my/master-occupancy'
|
||||||
})
|
})
|
||||||
} else {
|
|
||||||
uni.navigateTo({
|
|
||||||
url: '/pages/my/master-occupancy-parts'
|
|
||||||
})
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
strReplace(wholeStr, newStr, oldStr) {
|
strReplace(wholeStr, newStr, oldStr) {
|
||||||
if (wholeStr && wholeStr.length > 0) {
|
if (wholeStr && wholeStr.length > 0) {
|
||||||
|
|
|
||||||
|
|
@ -32,7 +32,7 @@
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<uni-collapse ref="collapse">
|
<uni-collapse ref="collapse">
|
||||||
<uni-collapse-item ref="collapseItem" :showArrow="false" v-for="(billItem, index) in bill" :key="index" :open="openStatusArr[index] === '0' ? true : false" >
|
<uni-collapse-item ref="collapseItem" :showArrow="false" v-for="(billItem, index) in bill" :open="openStatusArr[index] === '0' ? true : false" >
|
||||||
<template v-slot:title>
|
<template v-slot:title>
|
||||||
<view class="padding bg-white" :data-index="index" @click="showStatement">
|
<view class="padding bg-white" :data-index="index" @click="showStatement">
|
||||||
<view class="margin-bottom-xs">{{billItem.createTime}}</view>
|
<view class="margin-bottom-xs">{{billItem.createTime}}</view>
|
||||||
|
|
@ -46,7 +46,6 @@
|
||||||
</template>
|
</template>
|
||||||
<view class="content">
|
<view class="content">
|
||||||
<view v-for="(item, index1) in billItem.statement"
|
<view v-for="(item, index1) in billItem.statement"
|
||||||
:key="index1"
|
|
||||||
class="bg-white padding flex justify-between align-center solid-bottom" @click="showDetail(bill[index].statement[index1])">
|
class="bg-white padding flex justify-between align-center solid-bottom" @click="showDetail(bill[index].statement[index1])">
|
||||||
<view>
|
<view>
|
||||||
<view class="flex">
|
<view class="flex">
|
||||||
|
|
|
||||||
File diff suppressed because it is too large
Load Diff
|
|
@ -29,15 +29,15 @@
|
||||||
</picker>
|
</picker>
|
||||||
</view>
|
</view>
|
||||||
<view v-if="formData.specsList && formData.specsList.length > 0">
|
<view v-if="formData.specsList && formData.specsList.length > 0">
|
||||||
<view :class="isShowAllSpecs ? '' : 'certern-height'">
|
<checkbox-group class="padding-lr bg-white" @change="checkSpecs"
|
||||||
<checkbox-group class="padding-lr bg-white" @change="checkSpecs">
|
:class="isShowAllSpecs ? '' : 'certern-height'">
|
||||||
<view v-for="(item, index) in formData.specsList" :key="index" class="padding-tb-sm">
|
<view v-for="(item, index) in formData.specsList" class="padding-tb-sm">
|
||||||
<view class="flex">
|
<view class="flex">
|
||||||
<view class="flex-sub">
|
<view class="flex-sub">
|
||||||
<checkbox style="transform:scale(1)" class="margin-right-xs"
|
<checkbox style="transform:scale(1)" class="margin-right-xs"
|
||||||
:value="index" :checked="item.checked" :class="goodsId && item.checked ? 'grey' : 'main-color'" :disabled="goodsId && item.checked"></checkbox>
|
:value="index" :checked="item.checked" :class="goodsId && item.checked ? 'grey' : 'main-color'" :disabled="goodsId && item.checked"></checkbox>
|
||||||
<text>{{item.goodsCategoryName}}</text>
|
<text>{{item.goodsCategoryName}}</text>
|
||||||
</view>
|
</view>`
|
||||||
<view class="flex-sub">
|
<view class="flex-sub">
|
||||||
<input class="sm radius-input"
|
<input class="sm radius-input"
|
||||||
@input="inputSpecs($event, index, 'goodsStandardName')"
|
@input="inputSpecs($event, index, 'goodsStandardName')"
|
||||||
|
|
@ -46,11 +46,11 @@
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="flex margin-top-xs">
|
<view class="flex margin-top-xs">
|
||||||
<view class="margin-right-xs" style="flex-basis: 30%;">
|
<view class="margin-right-xs">
|
||||||
<view class='text-red' style="position: absolute; z-index: 0;">*</view>
|
<view class='text-red' style="position: absolute; z-index: 0;">*</view>
|
||||||
<zb-tooltip
|
<zb-tooltip
|
||||||
:content="'平' + parseInt(item.deptRate * 100) + '%+¥' + $calcUtil.curNumPlaces(item.deptMoney, 3) + '销' + parseInt((Number(item.oneRate) + Number(item.twoRate) + Number(item.threeRate) + Number(item.retainRate)) * 100) + '%+¥' + $calcUtil.curNumPlaces(item.retainMoney, 3)"
|
:content="'平' + parseInt(item.deptRate * 100) + '%+¥' + $calcUtil.curNumPlaces(item.deptMoney, 3) + '销' + parseInt((Number(item.oneRate) + Number(item.twoRate) + Number(item.threeRate) + Number(item.retainRate)) * 100) + '%+¥' + $calcUtil.curNumPlaces(item.retainMoney, 3)"
|
||||||
placement="top" ref="goodsPriceTip">
|
placement="right" ref="goodsPriceTip">
|
||||||
<input type="number" class="radius-input xs" @input="inputSpecs($event, index, 'goodsPrice')"
|
<input type="number" class="radius-input xs" @input="inputSpecs($event, index, 'goodsPrice')"
|
||||||
:value="item.goodsPrice" placeholder="价格"
|
:value="item.goodsPrice" placeholder="价格"
|
||||||
@blur="hideTips('goodsPriceTip', index)"></input>
|
@blur="hideTips('goodsPriceTip', index)"></input>
|
||||||
|
|
@ -68,22 +68,14 @@
|
||||||
<input class="radius-input xs" @input="inputSpecs($event, index, 'goodsUnit')"
|
<input class="radius-input xs" @input="inputSpecs($event, index, 'goodsUnit')"
|
||||||
:value="item.goodsUnit" placeholder="单位"></input>
|
:value="item.goodsUnit" placeholder="单位"></input>
|
||||||
</view>
|
</view>
|
||||||
<view class="margin-right-xs" style="flex-basis: 14%;">
|
<view style="flex-basis: 14%;">
|
||||||
<view class='text-red' style="position: absolute; absolute; z-index: 0;">*</view>
|
<view class='text-red' style="position: absolute; absolute; z-index: 0;">*</view>
|
||||||
<input type="number" class="radius-input xs" @input="inputSpecs($event, index, 'goodsNum')"
|
<input type="number" class="radius-input xs" @input="inputSpecs($event, index, 'goodsNum')"
|
||||||
:value="item.goodsNum" placeholder="库存数"></input>
|
:value="item.goodsNum" placeholder="库存数"></input>
|
||||||
</view>
|
</view>
|
||||||
<view style="flex-basis: 10%;">
|
|
||||||
<view style="border: 1px solid #0081ff;text-align: center;" class="radius-input" @click="chooseImgList($event, 'specsList:'+index, 500, 500)">
|
|
||||||
<image v-if="item.imageUrl" :src="item.imageUrl" style="width: 40rpx;height: 40rpx;" alt="" mode="aspectFit" ></image>
|
|
||||||
<image v-else src="/static/add-img.png" style="width: 40rpx;height: 40rpx;" alt="" mode="aspectFit" ></image>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</checkbox-group>
|
</checkbox-group>
|
||||||
</view>
|
|
||||||
|
|
||||||
<view class="text-bold text-gray text-lg text-center bg-white padding-tb-sm"
|
<view class="text-bold text-gray text-lg text-center bg-white padding-tb-sm"
|
||||||
@click="showAllSpecs()"><text :class="'cuIcon-' + (isShowAllSpecs ? 'fold' : 'unfold')"></text>
|
@click="showAllSpecs()"><text :class="'cuIcon-' + (isShowAllSpecs ? 'fold' : 'unfold')"></text>
|
||||||
</view>
|
</view>
|
||||||
|
|
@ -143,24 +135,6 @@
|
||||||
v-model="formData.expectDuration">
|
v-model="formData.expectDuration">
|
||||||
</my-uni-combox>
|
</my-uni-combox>
|
||||||
</view>
|
</view>
|
||||||
<view class="cu-form-group justify-start">
|
|
||||||
<view class="title">到店服务</view>
|
|
||||||
<my-uni-combox class="form-val-area" :showClear="true" :candidates="storeServiceList" placeholder="必须到店服务才选此项"
|
|
||||||
v-model="formData.storeService">
|
|
||||||
</my-uni-combox>
|
|
||||||
</view>
|
|
||||||
<view class="cu-form-group justify-start" v-if="formData.storeService">
|
|
||||||
<view class="title">服务店铺<text class="text-red">*</text></view>
|
|
||||||
<my-uni-combox class="form-val-area" :candidates="myShopList" placeholder="请选择" :alwaysShowEmpty="true"
|
|
||||||
v-model="formData.shopId">
|
|
||||||
<template v-slot:empty>
|
|
||||||
<view>
|
|
||||||
<span>无匹配项,</span>
|
|
||||||
<span class="text-blue" @click="goToShopList">点击增加</span>
|
|
||||||
</view>
|
|
||||||
</template>
|
|
||||||
</my-uni-combox>
|
|
||||||
</view>
|
|
||||||
<view class="solid-top">
|
<view class="solid-top">
|
||||||
<view class="cu-form-group">
|
<view class="cu-form-group">
|
||||||
<view class="title">上架区域<text class="text-red">*</text></view>
|
<view class="title">上架区域<text class="text-red">*</text></view>
|
||||||
|
|
@ -175,7 +149,7 @@
|
||||||
</view>
|
</view>
|
||||||
<view class="padding-lr bg-white">
|
<view class="padding-lr bg-white">
|
||||||
<checkbox-group @change="checkDistirct" class="grid col-3">
|
<checkbox-group @change="checkDistirct" class="grid col-3">
|
||||||
<view v-for="(item, index) in formData.districtList" :key="index" class="margin-tb-xs">
|
<view v-for="(item, index) in formData.districtList" class="margin-tb-xs">
|
||||||
<checkbox style="transform:scale(1)" class="main-color margin-right-xs" :value="index"
|
<checkbox style="transform:scale(1)" class="main-color margin-right-xs" :value="index"
|
||||||
:checked="item.checked"></checkbox>
|
:checked="item.checked"></checkbox>
|
||||||
<text>{{item.areaName}}</text>
|
<text>{{item.areaName}}</text>
|
||||||
|
|
@ -191,7 +165,7 @@
|
||||||
v-model="formData.areaDesc" maxlength="-1" placeholder="如:XX区XX街道未覆盖或XX区仅服务XX街道"></textarea>
|
v-model="formData.areaDesc" maxlength="-1" placeholder="如:XX区XX街道未覆盖或XX区仅服务XX街道"></textarea>
|
||||||
</view>
|
</view>
|
||||||
<!-- 多城市 -->
|
<!-- 多城市 -->
|
||||||
<view v-for="(item,index) in servArea" :key="index" class="bg-white">
|
<view v-for="(item,index) in servArea" class="bg-white">
|
||||||
<view class="solid-top">
|
<view class="solid-top">
|
||||||
<view @click="delServArea(index)">
|
<view @click="delServArea(index)">
|
||||||
<button class="cu-btn bg-red light">
|
<button class="cu-btn bg-red light">
|
||||||
|
|
@ -203,19 +177,19 @@
|
||||||
<view class="title">上架区域<text class="text-red">*</text></view>
|
<view class="title">上架区域<text class="text-red">*</text></view>
|
||||||
<picker :mode="'multiSelector'" @change="multiRegionChange($event, index)"
|
<picker :mode="'multiSelector'" @change="multiRegionChange($event, index)"
|
||||||
@columnchange="multiRegionColChange($event, index)"
|
@columnchange="multiRegionColChange($event, index)"
|
||||||
:value="item.regionMultiIndex" :range-key="'areaName'"
|
:value="servArea[index].regionMultiIndex" :range-key="'areaName'"
|
||||||
:range="item.regionList">
|
:range="servArea[index].regionList">
|
||||||
<input disabled class="line-input radius-input" v-if="item.region"
|
<input disabled class="line-input radius-input" v-if="servArea[index].region"
|
||||||
:value="item.region && item.region.length ? item.region[0].areaName + '-' + item.region[1].areaName : ''"
|
:value="servArea[index].region && servArea[index].region.length ? servArea[index].region[0].areaName + '-' + servArea[index].region[1].areaName : ''"
|
||||||
placeholder="请选择区域"></input>
|
placeholder="请选择区域"></input>
|
||||||
</picker>
|
</picker>
|
||||||
</view>
|
</view>
|
||||||
<view class="padding-lr bg-white">
|
<view class="padding-lr bg-white">
|
||||||
<checkbox-group @change="multiAreaCheckDistirct($event, index)" class="grid col-3">
|
<checkbox-group @change="multiAreaCheckDistirct($event, index)" class="grid col-3">
|
||||||
<view v-for="(item1, index1) in item.districtList" :key="item1.id" class="margin-tb-xs">
|
<view v-for="(item, index1) in servArea[index].districtList" class="margin-tb-xs">
|
||||||
<checkbox style="transform:scale(1)" class="main-color margin-right-xs" :value="index1"
|
<checkbox style="transform:scale(1)" class="main-color margin-right-xs" :value="index1"
|
||||||
:checked="item1.checked"></checkbox>
|
:checked="item.checked"></checkbox>
|
||||||
<text>{{item1.areaName}}</text>
|
<text>{{item.areaName}}</text>
|
||||||
</view>
|
</view>
|
||||||
</checkbox-group>
|
</checkbox-group>
|
||||||
</view>
|
</view>
|
||||||
|
|
@ -224,7 +198,6 @@
|
||||||
<view class="action text-black">区域描述<text class="text-red">*</text></view>
|
<view class="action text-black">区域描述<text class="text-red">*</text></view>
|
||||||
</view>
|
</view>
|
||||||
<view class="padding-lr-sm padding-bottom-sm">
|
<view class="padding-lr-sm padding-bottom-sm">
|
||||||
<!-- :adjust-position="false" -->
|
|
||||||
<textarea name="areaDesc" style="width: 100%; height: 150rpx;"
|
<textarea name="areaDesc" style="width: 100%; height: 150rpx;"
|
||||||
class="solid radius text-left padding-sm" v-model="servArea[index].areaDesc" maxlength="-1"
|
class="solid radius text-left padding-sm" v-model="servArea[index].areaDesc" maxlength="-1"
|
||||||
placeholder="如:XX区XX街道未覆盖或XX区仅服务XX街道"></textarea>
|
placeholder="如:XX区XX街道未覆盖或XX区仅服务XX街道"></textarea>
|
||||||
|
|
@ -354,7 +327,6 @@
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
goodsId: null,
|
goodsId: null,
|
||||||
type: 1,
|
|
||||||
formData: {
|
formData: {
|
||||||
servName: '',
|
servName: '',
|
||||||
servDesc: '',
|
servDesc: '',
|
||||||
|
|
@ -370,10 +342,7 @@
|
||||||
detailDesc: '',
|
detailDesc: '',
|
||||||
descImgList: [],
|
descImgList: [],
|
||||||
coverImgList: [],
|
coverImgList: [],
|
||||||
videoList: [],
|
videoList: []
|
||||||
shopId: '',
|
|
||||||
shopName: '',
|
|
||||||
storeService: ''
|
|
||||||
},
|
},
|
||||||
servArea: [],
|
servArea: [],
|
||||||
sysInfo: null,
|
sysInfo: null,
|
||||||
|
|
@ -435,40 +404,22 @@
|
||||||
}],
|
}],
|
||||||
warrantyPeriodList: [{
|
warrantyPeriodList: [{
|
||||||
code: 1,
|
code: 1,
|
||||||
name: '即时验收'
|
|
||||||
}, {
|
|
||||||
code: 2,
|
|
||||||
name: '验收后离店'
|
|
||||||
}, {
|
|
||||||
code: 3,
|
|
||||||
name: '完工24小时'
|
|
||||||
}, {
|
|
||||||
code: 4,
|
|
||||||
name: '3天'
|
|
||||||
}, {
|
|
||||||
code: 5,
|
|
||||||
name: '7天'
|
|
||||||
}, {
|
|
||||||
code: 6,
|
|
||||||
name: '15天'
|
name: '15天'
|
||||||
}, {
|
}, {
|
||||||
code: 7,
|
code: 2,
|
||||||
name: '30天'
|
name: '30天'
|
||||||
}, {
|
}, {
|
||||||
code: 8,
|
code: 3,
|
||||||
name: '45天'
|
name: '45天'
|
||||||
}, {
|
}, {
|
||||||
code: 9,
|
code: 4,
|
||||||
name: '3个月'
|
name: '3个月'
|
||||||
}, {
|
}, {
|
||||||
code: 10,
|
code: 5,
|
||||||
name: '6个月'
|
name: '6个月'
|
||||||
}, {
|
}, {
|
||||||
code: 11,
|
code: 6,
|
||||||
name: '12个月'
|
name: '12个月'
|
||||||
}, {
|
|
||||||
code: 12,
|
|
||||||
name: '24个月'
|
|
||||||
}],
|
}],
|
||||||
expectDurationList: [{
|
expectDurationList: [{
|
||||||
name: '12点前下单,预计当天下午上门/服务'
|
name: '12点前下单,预计当天下午上门/服务'
|
||||||
|
|
@ -478,41 +429,18 @@
|
||||||
name: '现时下单,预计次日上门/服务'
|
name: '现时下单,预计次日上门/服务'
|
||||||
}, {
|
}, {
|
||||||
name: '现时下单,预计后日上门/服务'
|
name: '现时下单,预计后日上门/服务'
|
||||||
}, {
|
|
||||||
name: '到店服务,按预约服务',
|
|
||||||
}, {
|
|
||||||
name: '到店服务,到达即服务'
|
|
||||||
}],
|
}],
|
||||||
storeServiceList: [
|
|
||||||
{
|
|
||||||
code: 1,
|
|
||||||
name: '到店服务'
|
|
||||||
}, {
|
|
||||||
code: 2,
|
|
||||||
name: '到店+配送(服务)'
|
|
||||||
}, {
|
|
||||||
code: 3,
|
|
||||||
name: '到店+上门(服务)'
|
|
||||||
}
|
|
||||||
],
|
|
||||||
curUserInfo: {},
|
curUserInfo: {},
|
||||||
bankCard: null,
|
bankCard: null,
|
||||||
certifyInfo: null,
|
certifyInfo: null
|
||||||
myShopList: []
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
onLoad(options) {
|
onLoad(options) {
|
||||||
if (options && options.goodId) {
|
if (options && options.goodId) {
|
||||||
this.goodsId = options.goodId;
|
this.goodsId = options.goodId;
|
||||||
}
|
}
|
||||||
if(options && options.type) {
|
|
||||||
this.type = options.type
|
|
||||||
}
|
|
||||||
this.loadData(this.goodsId);
|
this.loadData(this.goodsId);
|
||||||
},
|
},
|
||||||
onShow() {
|
|
||||||
this.loadShopList();
|
|
||||||
},
|
|
||||||
methods: {
|
methods: {
|
||||||
async loadData(goodId) {
|
async loadData(goodId) {
|
||||||
this.sysInfo = uni.getSystemInfoSync();
|
this.sysInfo = uni.getSystemInfoSync();
|
||||||
|
|
@ -527,15 +455,6 @@
|
||||||
// this.categoryList = await this.$api.data('categoryList');
|
// this.categoryList = await this.$api.data('categoryList');
|
||||||
// this.regionList = await this.$api.data('regionList');
|
// this.regionList = await this.$api.data('regionList');
|
||||||
},
|
},
|
||||||
async loadShopList() {
|
|
||||||
let res = await this.$request.getMasterShopAddressList(this.$request.getCurUserInfo().workerId);
|
|
||||||
this.myShopList = res.data.map(item => {return {name: item.shopName, code: item.shopId}});
|
|
||||||
},
|
|
||||||
goToShopList() {
|
|
||||||
uni.navigateTo({
|
|
||||||
url: '/pages/my/shop-list'
|
|
||||||
})
|
|
||||||
},
|
|
||||||
async getCurGoodsInfo(goodsId) {
|
async getCurGoodsInfo(goodsId) {
|
||||||
let res1 = await this.$request.qryProductDetail({
|
let res1 = await this.$request.qryProductDetail({
|
||||||
goodsId: goodsId
|
goodsId: goodsId
|
||||||
|
|
@ -549,7 +468,7 @@
|
||||||
});
|
});
|
||||||
// 查询选中的第三级类目下的所有规格
|
// 查询选中的第三级类目下的所有规格
|
||||||
let res2 = await this.$request.listByStep({
|
let res2 = await this.$request.listByStep({
|
||||||
type: this.type,
|
type: 1,
|
||||||
goodsCategoryId: goods.deptGoodsCategoryId
|
goodsCategoryId: goods.deptGoodsCategoryId
|
||||||
});
|
});
|
||||||
let specsList = res2.data;
|
let specsList = res2.data;
|
||||||
|
|
@ -584,11 +503,6 @@
|
||||||
});
|
});
|
||||||
console.log(newAreaList)
|
console.log(newAreaList)
|
||||||
|
|
||||||
let stopService = null
|
|
||||||
if(goods.storeService) {
|
|
||||||
stopService = this.storeServiceList.find(i => i.code == goods.storeService)
|
|
||||||
}
|
|
||||||
|
|
||||||
this.formData = {
|
this.formData = {
|
||||||
servName: goods.goodsName,
|
servName: goods.goodsName,
|
||||||
servDesc: goods.goodsDesc,
|
servDesc: goods.goodsDesc,
|
||||||
|
|
@ -616,8 +530,6 @@
|
||||||
descImgList: goods.detailUrl,
|
descImgList: goods.detailUrl,
|
||||||
videoList: goods.goodsVideoUrl ? [goods.goodsVideoUrl] : [],
|
videoList: goods.goodsVideoUrl ? [goods.goodsVideoUrl] : [],
|
||||||
// status: 0,
|
// status: 0,
|
||||||
shopId: goods.shopId ? {code: goods.shopId, name: goods.shopName} : null,
|
|
||||||
storeService: goods.storeService ? stopService : null
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
async checkBankAndCertify() {
|
async checkBankAndCertify() {
|
||||||
|
|
@ -640,24 +552,24 @@
|
||||||
},
|
},
|
||||||
async loadCategoryList(idArr) {
|
async loadCategoryList(idArr) {
|
||||||
let typeList = await this.$request.listByStep({
|
let typeList = await this.$request.listByStep({
|
||||||
type: this.type
|
type: 1
|
||||||
});
|
});
|
||||||
typeList = typeList.data;
|
typeList = typeList.data;
|
||||||
let col1Id = idArr ? idArr[0] : typeList[0].goodsCategoryId;
|
let col1Id = idArr ? idArr[0] : typeList[0].goodsCategoryId;
|
||||||
let subTypeList = await this.$request.listByStep({
|
let subTypeList = await this.$request.listByStep({
|
||||||
type: this.type,
|
type: 1,
|
||||||
goodsCategoryId: col1Id
|
goodsCategoryId: col1Id
|
||||||
});
|
});
|
||||||
subTypeList = subTypeList.data;
|
subTypeList = subTypeList.data;
|
||||||
let col2Id = idArr ? idArr[1] : subTypeList[0].goodsCategoryId;
|
let col2Id = idArr ? idArr[1] : subTypeList[0].goodsCategoryId;
|
||||||
let subSubTypeList = await this.$request.listByStep({
|
let subSubTypeList = await this.$request.listByStep({
|
||||||
type: this.type,
|
type: 1,
|
||||||
goodsCategoryId: col2Id
|
goodsCategoryId: col2Id
|
||||||
});
|
});
|
||||||
subSubTypeList = subSubTypeList.data;
|
subSubTypeList = subSubTypeList.data;
|
||||||
let col3Id = idArr ? idArr[2] : subSubTypeList[0].goodsCategoryId;
|
let col3Id = idArr ? idArr[2] : subSubTypeList[0].goodsCategoryId;
|
||||||
let thirdTypeList = await this.$request.listByStep({
|
let thirdTypeList = await this.$request.listByStep({
|
||||||
type: this.type,
|
type: 1,
|
||||||
goodsCategoryId: col3Id
|
goodsCategoryId: col3Id
|
||||||
});
|
});
|
||||||
thirdTypeList = thirdTypeList.data;
|
thirdTypeList = thirdTypeList.data;
|
||||||
|
|
@ -691,7 +603,7 @@
|
||||||
|
|
||||||
// 查询最后一级品类
|
// 查询最后一级品类
|
||||||
let res = await this.$request.listByStep({
|
let res = await this.$request.listByStep({
|
||||||
type: this.type,
|
type: 1,
|
||||||
goodsCategoryId: chosenCategory[chosenCategory.length - 1].goodsCategoryId
|
goodsCategoryId: chosenCategory[chosenCategory.length - 1].goodsCategoryId
|
||||||
});
|
});
|
||||||
this.formData.specsList = res.data;
|
this.formData.specsList = res.data;
|
||||||
|
|
@ -701,14 +613,14 @@
|
||||||
if (colObj.column == 0) {
|
if (colObj.column == 0) {
|
||||||
// 通过一级查询二级,通过二级查三级
|
// 通过一级查询二级,通过二级查三级
|
||||||
let subTypeList = await this.$request.listByStep({
|
let subTypeList = await this.$request.listByStep({
|
||||||
type: this.type,
|
type: 1,
|
||||||
goodsCategoryId: this.categoryList[0][colObj.value].goodsCategoryId
|
goodsCategoryId: this.categoryList[0][colObj.value].goodsCategoryId
|
||||||
});
|
});
|
||||||
subTypeList = subTypeList.data;
|
subTypeList = subTypeList.data;
|
||||||
let subSubTypeList = [];
|
let subSubTypeList = [];
|
||||||
if (subTypeList && subTypeList.length) {
|
if (subTypeList && subTypeList.length) {
|
||||||
subSubTypeList = await this.$request.listByStep({
|
subSubTypeList = await this.$request.listByStep({
|
||||||
type: this.type,
|
type: 1,
|
||||||
goodsCategoryId: subTypeList[0].goodsCategoryId
|
goodsCategoryId: subTypeList[0].goodsCategoryId
|
||||||
});
|
});
|
||||||
subSubTypeList = subSubTypeList.data;
|
subSubTypeList = subSubTypeList.data;
|
||||||
|
|
@ -721,7 +633,7 @@
|
||||||
} else if (colObj.column == 1) {
|
} else if (colObj.column == 1) {
|
||||||
// 通过二级查三级
|
// 通过二级查三级
|
||||||
let subSubTypeList = await this.$request.listByStep({
|
let subSubTypeList = await this.$request.listByStep({
|
||||||
type: this.type,
|
type: 1,
|
||||||
goodsCategoryId: this.categoryList[1][colObj.value].goodsCategoryId
|
goodsCategoryId: this.categoryList[1][colObj.value].goodsCategoryId
|
||||||
});
|
});
|
||||||
subSubTypeList = subSubTypeList.data;
|
subSubTypeList = subSubTypeList.data;
|
||||||
|
|
@ -832,14 +744,13 @@
|
||||||
chooseImgList(e, imgListField, cropWidth, cropHeight) {
|
chooseImgList(e, imgListField, cropWidth, cropHeight) {
|
||||||
this.cropWidth = cropWidth && cropWidth > 0 ? cropWidth : this.sysInfo.windowWidth * 2;
|
this.cropWidth = cropWidth && cropWidth > 0 ? cropWidth : this.sysInfo.windowWidth * 2;
|
||||||
this.cropHeight = cropHeight && cropHeight > 0 ? cropHeight : this.sysInfo.windowWidth * 2 * 1.15;
|
this.cropHeight = cropHeight && cropHeight > 0 ? cropHeight : this.sysInfo.windowWidth * 2 * 1.15;
|
||||||
uni.chooseMedia({
|
uni.chooseImage({
|
||||||
count: 1, //默认9
|
count: 1, //默认9
|
||||||
mediaType: ['image'],
|
|
||||||
sizeType: ['original', 'compressed'], //可以指定是原图还是压缩图,默认二者都有
|
sizeType: ['original', 'compressed'], //可以指定是原图还是压缩图,默认二者都有
|
||||||
sourceType: ['album'], //从相册选择
|
sourceType: ['album'], //从相册选择
|
||||||
success: (res) => {
|
success: (res) => {
|
||||||
res.tempFiles.forEach((fileObj, index) => {
|
res.tempFilePaths.forEach((tmpUrl, index) => {
|
||||||
this.url2Crop = fileObj.tempFilePath;
|
this.url2Crop = tmpUrl;
|
||||||
this.curImgListField = imgListField;
|
this.curImgListField = imgListField;
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
@ -851,15 +762,7 @@
|
||||||
mask: true
|
mask: true
|
||||||
});
|
});
|
||||||
this.$request.uploadFile(ev.path).then((url) => {
|
this.$request.uploadFile(ev.path).then((url) => {
|
||||||
if(this.curImgListField.indexOf('specsList') > -1) {
|
|
||||||
// 规格上传图片
|
|
||||||
const specsListIndex = this.curImgListField.split(':')[1]
|
|
||||||
const temp = this.formData.specsList[specsListIndex]
|
|
||||||
temp.imageUrl = url
|
|
||||||
this.$set(this.formData.specsList, specsListIndex, temp)
|
|
||||||
} else {
|
|
||||||
this.formData[this.curImgListField].push(url);
|
this.formData[this.curImgListField].push(url);
|
||||||
}
|
|
||||||
uni.hideLoading();
|
uni.hideLoading();
|
||||||
});
|
});
|
||||||
// url设置为空,隐藏控件
|
// url设置为空,隐藏控件
|
||||||
|
|
@ -870,9 +773,8 @@
|
||||||
this.url2Crop = "";
|
this.url2Crop = "";
|
||||||
},
|
},
|
||||||
chooseImgNoCrop(e, imgListField) {
|
chooseImgNoCrop(e, imgListField) {
|
||||||
uni.chooseMedia({
|
uni.chooseImage({
|
||||||
count: 9, //默认9
|
count: 9, //默认9
|
||||||
mediaType: ['image'],
|
|
||||||
sizeType: ['original', 'compressed'], //可以指定是原图还是压缩图,默认二者都有
|
sizeType: ['original', 'compressed'], //可以指定是原图还是压缩图,默认二者都有
|
||||||
sourceType: ['album'], //从相册选择
|
sourceType: ['album'], //从相册选择
|
||||||
success: (res) => {
|
success: (res) => {
|
||||||
|
|
@ -880,10 +782,10 @@
|
||||||
title: '上传中',
|
title: '上传中',
|
||||||
mask: true
|
mask: true
|
||||||
});
|
});
|
||||||
res.tempFiles.forEach((fileObj, index) => {
|
res.tempFilePaths.forEach((tmpUrl, index) => {
|
||||||
this.$request.uploadFile(fileObj.tempFilePath).then((url) => {
|
this.$request.uploadFile(tmpUrl).then((url) => {
|
||||||
this.formData[imgListField].push(url);
|
this.formData[imgListField].push(url);
|
||||||
if (index === res.tempFiles.length - 1) {
|
if (index === res.tempFilePaths.length - 1) {
|
||||||
uni.hideLoading();
|
uni.hideLoading();
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
@ -954,8 +856,6 @@
|
||||||
errMsg = '服务活动不能为空';
|
errMsg = '服务活动不能为空';
|
||||||
} else if (!data.expectDuration) {
|
} else if (!data.expectDuration) {
|
||||||
errMsg = '服务时效不能为空';
|
errMsg = '服务时效不能为空';
|
||||||
} else if(data.storeService && !data.shopId) {
|
|
||||||
errMsg = '到店店铺不能为空';
|
|
||||||
} else if (!data.goodsAreaList || !data.goodsAreaList.length) {
|
} else if (!data.goodsAreaList || !data.goodsAreaList.length) {
|
||||||
errMsg = '上架区域填写不完整';
|
errMsg = '上架区域填写不完整';
|
||||||
} else if (!data.areaDesc) {
|
} else if (!data.areaDesc) {
|
||||||
|
|
@ -1102,16 +1002,9 @@
|
||||||
goodsVideoUrl: goodsVideoUrl,
|
goodsVideoUrl: goodsVideoUrl,
|
||||||
status: 0,
|
status: 0,
|
||||||
remark: this.formData.detailDesc,
|
remark: this.formData.detailDesc,
|
||||||
areaDesc: this.formData.areaDesc,
|
areaDesc: this.formData.areaDesc
|
||||||
type: this.type,
|
|
||||||
shopId: this.formData.shopId ? this.formData.shopId.code : '',
|
|
||||||
shopName: this.formData.shopId ? this.formData.shopId.name : '',
|
|
||||||
storeService: this.formData.storeService ? this.formData.storeService.code : ''
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// console.log(params);
|
|
||||||
// return
|
|
||||||
|
|
||||||
let res = null;
|
let res = null;
|
||||||
if (this.goodsId) {
|
if (this.goodsId) {
|
||||||
res = await this.$request.editGoods({
|
res = await this.$request.editGoods({
|
||||||
|
|
@ -1179,7 +1072,6 @@
|
||||||
.certern-height {
|
.certern-height {
|
||||||
max-height: 520rpx;
|
max-height: 520rpx;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
position: relative;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.long-btn {
|
.long-btn {
|
||||||
|
|
|
||||||
|
|
@ -3,18 +3,13 @@
|
||||||
<!-- 顶部操作条 -->
|
<!-- 顶部操作条 -->
|
||||||
<cu-custom :bgColor="'bg-main-color'" :isBack="true">
|
<cu-custom :bgColor="'bg-main-color'" :isBack="true">
|
||||||
<block slot="backText">返回</block>
|
<block slot="backText">返回</block>
|
||||||
<block slot="content">商家信息</block>
|
<block slot="content">个人信息</block>
|
||||||
</cu-custom>
|
</cu-custom>
|
||||||
<form @submit="submit">
|
<form @submit="submit">
|
||||||
<view class="text-center padding-tb-lg">
|
|
||||||
<button class="cu-avatar round"
|
|
||||||
:style="'width: 120rpx; height: 120rpx; background-image:url(' + curUserInfo.workerLogoUrl + ');'"
|
|
||||||
open-type="chooseAvatar" @chooseavatar="onChooseAvatar"></button>
|
|
||||||
</view>
|
|
||||||
<view class="margin-top-sm bg-white">
|
<view class="margin-top-sm bg-white">
|
||||||
<view class="cu-form-group">
|
<view class="cu-form-group">
|
||||||
<view class="title">商家昵称</view>
|
<view class="title">用户昵称</view>
|
||||||
<input name="name" v-model="curUserInfo.name"></input>
|
<input name="name" :value="curUserInfo.name"></input>
|
||||||
</view>
|
</view>
|
||||||
<view class="cu-form-group">
|
<view class="cu-form-group">
|
||||||
<view class="title">公司名称</view>
|
<view class="title">公司名称</view>
|
||||||
|
|
@ -28,11 +23,6 @@
|
||||||
<view class="title">电子邮箱</view>
|
<view class="title">电子邮箱</view>
|
||||||
<input name="email" :value="curUserInfo.email"></input>
|
<input name="email" :value="curUserInfo.email"></input>
|
||||||
</view>
|
</view>
|
||||||
<view class="cu-form-group" @click="showShopList">
|
|
||||||
<view class="title">店铺管理</view>
|
|
||||||
<view class="text-lg"><text class="cuIcon-right"></text></view>
|
|
||||||
</view>
|
|
||||||
|
|
||||||
</view>
|
</view>
|
||||||
<view class="margin-top-sm bg-white">
|
<view class="margin-top-sm bg-white">
|
||||||
<view class="cu-form-group" @click="showAccountSecurity">
|
<view class="cu-form-group" @click="showAccountSecurity">
|
||||||
|
|
@ -41,9 +31,9 @@
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<!-- 底部操作栏 -->
|
<!-- 底部操作栏 -->
|
||||||
<view class="cu-bar tabbar border shop fixed-bottom-bar">
|
<!-- <view class="cu-bar tabbar border shop fixed-bottom-bar">
|
||||||
<button class="cu-btn bg-main-color long-btn margin-lr-sm shadow-blur" form-type="submit">保存</button>
|
<button class="cu-btn bg-main-color long-btn margin-lr-sm shadow-blur" form-type="submit">保存</button>
|
||||||
</view>
|
</view> -->
|
||||||
</form>
|
</form>
|
||||||
</view>
|
</view>
|
||||||
</template>
|
</template>
|
||||||
|
|
@ -52,19 +42,13 @@
|
||||||
export default {
|
export default {
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
curUserInfo: {},
|
curUserInfo: {}
|
||||||
avatarUrl: '',
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
onLoad() {
|
onLoad() {
|
||||||
this.loadData();
|
this.loadData();
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
onChooseAvatar(e) {
|
|
||||||
this.$request.uploadFile(e.detail.avatarUrl).then((url) => {
|
|
||||||
this.curUserInfo.workerLogoUrl = url;
|
|
||||||
});
|
|
||||||
},
|
|
||||||
async loadData() {
|
async loadData() {
|
||||||
this.curUserInfo = await this.$request.getCurUserNoCache();
|
this.curUserInfo = await this.$request.getCurUserNoCache();
|
||||||
},
|
},
|
||||||
|
|
@ -72,30 +56,6 @@
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url: '/pages/my/account-security'
|
url: '/pages/my/account-security'
|
||||||
})
|
})
|
||||||
},
|
|
||||||
showShopList() {
|
|
||||||
uni.navigateTo({
|
|
||||||
url: '/pages/my/shop-list'
|
|
||||||
})
|
|
||||||
},
|
|
||||||
async submit() {
|
|
||||||
let res = await this.$request.updateWorker({
|
|
||||||
workerId: this.curUserInfo.workerId,
|
|
||||||
name: this.curUserInfo.name,
|
|
||||||
workerLogoUrl: this.curUserInfo.workerLogoUrl
|
|
||||||
})
|
|
||||||
if (res && res.code === 0) {
|
|
||||||
uni.showToast({
|
|
||||||
icon: 'success',
|
|
||||||
title: '更新成功'
|
|
||||||
})
|
|
||||||
let timeout = setTimeout(() => {
|
|
||||||
uni.navigateTo({
|
|
||||||
url: '/pages/index/index?menuCode=myPage'
|
|
||||||
})
|
|
||||||
clearTimeout(timeout);
|
|
||||||
}, 1500);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,130 +0,0 @@
|
||||||
<template>
|
|
||||||
<view>
|
|
||||||
<!-- 顶部操作条 -->
|
|
||||||
<cu-custom :bgColor="'bg-main-color'" :isBack="true">
|
|
||||||
<block slot="backText">返回</block>
|
|
||||||
<block slot="content">店铺管理</block>
|
|
||||||
</cu-custom>
|
|
||||||
<!-- 店铺管理列表 -->
|
|
||||||
<view class="margin-bottom-with-bar">
|
|
||||||
<view class="padding margin-lr-sm margin-top-sm bg-white flex justify-between align-center" v-for="(item, index) in myAddressList" :key="index">
|
|
||||||
<view class="flex flex-sub align-center">
|
|
||||||
<image class="bg-img-container" :src="item.imageUrl.split(',')[0]" mode="aspectFill"></image>
|
|
||||||
<view class="flex-sub">
|
|
||||||
<view class="flex justify-start align-center">
|
|
||||||
<view class="text-gray margin-right-xs">{{item.provinceName}}</view>
|
|
||||||
<view class="text-gray margin-right-xs">{{item.cityName}}</view>
|
|
||||||
<view class="text-gray margin-right-xs">{{item.countryName}}</view>
|
|
||||||
<view class="text-gray margin-right-xs">{{item.streetName || ''}}</view>
|
|
||||||
</view>
|
|
||||||
<view class="text-lg margin-tb-sm">{{item.address}}</view>
|
|
||||||
<view class="text-gray">
|
|
||||||
<text class="margin-right">门店名称:</text>
|
|
||||||
<text>{{item.shopName}}</text>
|
|
||||||
</view>
|
|
||||||
<view class="text-gray">
|
|
||||||
<text class="margin-right">门店电话:</text>
|
|
||||||
<text>{{item.phone}}</text>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="oper-column text-xl flex justify-end flex-direction">
|
|
||||||
<view class="cuIcon-edit padding-lr-xs padding-tb-xs" @click="addEditAddress(item)"></view>
|
|
||||||
<view class="cuIcon-close padding-lr-xs padding-tb-xs" @click="confirm2DelAddress(item)"></view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<!-- 底部新增地址按钮 -->
|
|
||||||
<view class="cu-bar tabbar border shop fixed-bottom-bar bg-back">
|
|
||||||
<button class="cu-btn bg-main-color long-btn margin-lr-sm shadow-blur" @click="addEditAddress(null)">新增店铺</button>
|
|
||||||
</view>
|
|
||||||
<!-- 模态框 -->
|
|
||||||
<confirm-modal ref="confirmModal" :content="'是否确定删除?'" @confirm="delAddress"></confirm-modal>
|
|
||||||
</view>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<script>
|
|
||||||
export default {
|
|
||||||
data() {
|
|
||||||
return {
|
|
||||||
myAddressList: [],
|
|
||||||
modalName: '',
|
|
||||||
delAddressInfo: {},
|
|
||||||
}
|
|
||||||
},
|
|
||||||
onLoad(options) {
|
|
||||||
|
|
||||||
},
|
|
||||||
onShow() {
|
|
||||||
this.loadData();
|
|
||||||
},
|
|
||||||
methods: {
|
|
||||||
async loadData() {
|
|
||||||
let res = await this.$request.getMasterShopAddressList(this.$request.getCurUserInfo().workerId);
|
|
||||||
this.myAddressList = res.data;
|
|
||||||
},
|
|
||||||
addEditAddress(addressInfo) {
|
|
||||||
let url = null;
|
|
||||||
let params = null;
|
|
||||||
if (addressInfo) {
|
|
||||||
// 修改
|
|
||||||
addressInfo.area = [
|
|
||||||
{
|
|
||||||
areaId: addressInfo.cityId,
|
|
||||||
areaName: addressInfo.cityName
|
|
||||||
},{
|
|
||||||
areaId: addressInfo.provinceId,
|
|
||||||
areaName: addressInfo.provinceName
|
|
||||||
},{
|
|
||||||
areaId: addressInfo.countryId,
|
|
||||||
areaName: addressInfo.countryName
|
|
||||||
},{
|
|
||||||
areaId: addressInfo.streetId || 0,
|
|
||||||
areaName: addressInfo.streetName
|
|
||||||
}]
|
|
||||||
params = {
|
|
||||||
addressInfo: addressInfo,
|
|
||||||
mode: 0
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
// 新增
|
|
||||||
params = {
|
|
||||||
mode: 1
|
|
||||||
}
|
|
||||||
}
|
|
||||||
uni.navigateTo({
|
|
||||||
url: '/pages/my/edit-shop-address?params=' + encodeURIComponent(JSON.stringify(params))
|
|
||||||
})
|
|
||||||
},
|
|
||||||
confirm2DelAddress(addressInfo) {
|
|
||||||
this.delAddressInfo = addressInfo;
|
|
||||||
this.$refs.confirmModal.showModal();
|
|
||||||
},
|
|
||||||
async delAddress() {
|
|
||||||
let res = await this.$request.delShopAddressList(this.delAddressInfo.shopId);
|
|
||||||
if (res.code === 0) {
|
|
||||||
this.loadData();
|
|
||||||
uni.showToast({
|
|
||||||
title: '删除成功',
|
|
||||||
icon: 'success',
|
|
||||||
mask: true
|
|
||||||
})
|
|
||||||
} else {
|
|
||||||
uni.showToast({
|
|
||||||
title: '删除失败',
|
|
||||||
icon: 'error',
|
|
||||||
mask: true
|
|
||||||
})
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
</script>
|
|
||||||
|
|
||||||
<style scoped>
|
|
||||||
.bg-img-container{
|
|
||||||
width: 140rpx;
|
|
||||||
height: 140rpx;
|
|
||||||
margin-right: 14rpx;
|
|
||||||
}
|
|
||||||
</style>
|
|
||||||
|
|
@ -108,20 +108,15 @@
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
chooseImage(e) {
|
chooseImage(e) {
|
||||||
uni.chooseMedia({
|
uni.chooseImage({
|
||||||
count: 9, //默认9
|
count: 9, //默认9
|
||||||
mediaType: ['image'],
|
|
||||||
sizeType: ['original', 'compressed'], //可以指定是原图还是压缩图,默认二者都有
|
sizeType: ['original', 'compressed'], //可以指定是原图还是压缩图,默认二者都有
|
||||||
sourceType: ['album'], //从相册选择
|
sourceType: ['album'], //从相册选择
|
||||||
success: (res) => {
|
success: (res) => {
|
||||||
let tempFilePaths = [];
|
|
||||||
res.tempFiles.forEach((fileObj) => {
|
|
||||||
tempFilePaths.push(fileObj.tempFilePath)
|
|
||||||
})
|
|
||||||
if (this.imgList.length != 0) {
|
if (this.imgList.length != 0) {
|
||||||
this.imgList = this.imgList.concat(tempFilePaths)
|
this.imgList = this.imgList.concat(res.tempFilePaths)
|
||||||
} else {
|
} else {
|
||||||
this.imgList = tempFilePaths
|
this.imgList = res.tempFilePaths
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
|
||||||
|
|
@ -5,7 +5,7 @@
|
||||||
<block slot="backText">返回</block>
|
<block slot="backText">返回</block>
|
||||||
<block slot="content">申请退单</block>
|
<block slot="content">申请退单</block>
|
||||||
</cu-custom>
|
</cu-custom>
|
||||||
<!-- <view class="padding flex justify-start margin-top-sm bg-white">
|
<view class="padding flex justify-start margin-top-sm bg-white">
|
||||||
<view class="cu-avatar xxl-view" :style="'background-image:url(' + good.picUrl + ');'"></view>
|
<view class="cu-avatar xxl-view" :style="'background-image:url(' + good.picUrl + ');'"></view>
|
||||||
<view class="flex flex-column-between margin-left-sm">
|
<view class="flex flex-column-between margin-left-sm">
|
||||||
<view class="text-black text-lg">{{good.servTitle}}</view>
|
<view class="text-black text-lg">{{good.servTitle}}</view>
|
||||||
|
|
@ -14,21 +14,20 @@
|
||||||
{{item}}</view>
|
{{item}}</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view> -->
|
</view>
|
||||||
<view class="margin-top-sm padding flex justify-between bg-white">
|
<view class="margin-top-sm padding flex justify-between bg-white">
|
||||||
<view>申请原因</view>
|
<view>申请原因</view>
|
||||||
<picker @change="reasonChange" :range="cancelReasonList" :range-key="'reasonName'">
|
<picker @change="reasonChange" :range="cancelReasonList" :range-key="'reasonName'">
|
||||||
<view class="picker">
|
<view class="picker">
|
||||||
{{formData.returnReason ? formData.returnReason : '请选择' }}
|
{{formData.reasonObj.reasonId ? formData.reasonObj.reasonName : '请选择' }}
|
||||||
<text class="text-gray text-lg margin-left-xs"><text class="cuIcon-right"></text></text>
|
<text class="text-gray text-lg margin-left-xs"><text class="cuIcon-right"></text></text>
|
||||||
</view>
|
</view>
|
||||||
</picker>
|
</picker>
|
||||||
</view>
|
</view>
|
||||||
<view class="margin-top-sm padding bg-white">
|
<view class="margin-top-sm padding bg-white">
|
||||||
<view class="margin-bottom-sm">具体原因<text class="text-gray margin-left-xs">(请填写退单退货的原因)</text></view>
|
<view class="margin-bottom-sm">具体原因</view>
|
||||||
<textarea style="width: 100%;" class="solid radius text-left padding-sm" v-model="formData.returnReasonDetail" maxlength="-1"
|
<textarea style="width: 100%;" class="solid radius text-left padding-sm" v-model="formData.detailDesc" maxlength="-1"
|
||||||
placeholder-style="color: #d2d1d1;"
|
placeholder="本次原因请如实填写。无故退单,无理由退单引起客诉的你有责,订单大多数由推荐/分销人员带单产生,注意不要产生私自成交,撬单等行为,造成订单销售人员的佣金损失,不利于长远合作。被带单销售人员发现恶意违规破坏合作的,将追责3000元/单。"></textarea>
|
||||||
placeholder="无故退单,无理由退单引起客诉你将有责,本次原因请如实填写。订单大多数由推荐分销人员带单产生,注意不要产生私自成交、撬单等行为,造成订单销售人员的佣金损失,不利于长远合作。被带单销售人员发现恶意违规破坏合作的,将追责3000元/单。"></textarea>
|
|
||||||
</view>
|
</view>
|
||||||
<view class="margin-top-sm padding bg-white">
|
<view class="margin-top-sm padding bg-white">
|
||||||
<view class="margin-bottom-sm">上传凭证(选填)</view>
|
<view class="margin-bottom-sm">上传凭证(选填)</view>
|
||||||
|
|
@ -46,7 +45,7 @@
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="cu-bar tabbar fixed-bottom-bar bg-back">
|
<view class="cu-bar tabbar fixed-bottom-bar bg-back">
|
||||||
<button class="bg-main-color cu-btn lg shadow-warp long-btn margin-lr" @click="submitCancelOrder">提交退单</button>
|
<button class="bg-main-color cu-btn lg shadow-warp long-btn margin-lr" @click="nextStep">提交退单</button>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</template>
|
</template>
|
||||||
|
|
@ -55,71 +54,61 @@
|
||||||
export default {
|
export default {
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
// good: {},
|
good: {},
|
||||||
formData: {
|
formData: {
|
||||||
imgList: [],
|
imgList: [],
|
||||||
returnReason: '',
|
reasonObj: {}
|
||||||
returnReasonDetail: ''
|
|
||||||
},
|
},
|
||||||
cancelReasonList: [],
|
cancelReasonList: [{
|
||||||
orderId: null,
|
reasonId: 1,
|
||||||
orderType: null,
|
reasonName: '客户的时间我无法配合'
|
||||||
detailPlaceholder: '',
|
}, {
|
||||||
isDetailOrder: null,
|
reasonId: 2,
|
||||||
isSelfAcceptOrder: false
|
reasonName: '客户多次爽约'
|
||||||
|
}, {
|
||||||
|
reasonId: 3,
|
||||||
|
reasonName: '客户不能确定时间'
|
||||||
|
}, {
|
||||||
|
reasonId: 4,
|
||||||
|
reasonName: '客户多天未能联系上'
|
||||||
|
}, {
|
||||||
|
reasonId: 5,
|
||||||
|
reasonName: '客户说无此服务'
|
||||||
|
}, {
|
||||||
|
reasonId: 6,
|
||||||
|
reasonName: '客户要求已超出服务范围'
|
||||||
|
}, {
|
||||||
|
reasonId: 7,
|
||||||
|
reasonName: '环境问题无法施工'
|
||||||
|
}, {
|
||||||
|
reasonId: 8,
|
||||||
|
reasonName: '技能原因无法完成'
|
||||||
|
}, {
|
||||||
|
reasonId: 9,
|
||||||
|
reasonName: '分岐未能谈妥'
|
||||||
|
}, {
|
||||||
|
reasonId: 10,
|
||||||
|
reasonName: '不愿支付费用'
|
||||||
|
}]
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
onLoad(options) {
|
onLoad(options) {
|
||||||
// if (options && options.params) {
|
if (options && options.params) {
|
||||||
// this.good = JSON.parse(decodeURIComponent(options.params)).orderInfo;
|
this.good = JSON.parse(decodeURIComponent(options.params)).orderInfo;
|
||||||
// }
|
|
||||||
|
|
||||||
if (options && options.orderId) {
|
|
||||||
this.orderId = options.orderId
|
|
||||||
}
|
}
|
||||||
if(options && options.orderType) {
|
|
||||||
let reasonList
|
|
||||||
if(options.orderType === '1') {
|
|
||||||
reasonList = ['商家原因,没时间备货!', '商家原因,缺货了!', '商家原因,发货时间迟了!', '商家原因,物流原因,长时间滞留路途!', '客户原因,无法接受质量!', '客户原因,商品无法满足期望!']
|
|
||||||
} else {
|
|
||||||
reasonList = ['师傅原因,时间排不上!', '师傅原因,技术不能解决问题!', '师傅原因,迟到了无法服务!', '客户原因,约好时间没遵守!', '客户原因,要求无法达成,无法沟通。']
|
|
||||||
}
|
|
||||||
this.cancelReasonList = reasonList.map((i , index)=> {
|
|
||||||
return {
|
|
||||||
reasonId: index + 1,
|
|
||||||
reasonName: i
|
|
||||||
}
|
|
||||||
})
|
|
||||||
this.orderType = options.orderType
|
|
||||||
}
|
|
||||||
if(options && options.isDetailOrder) {
|
|
||||||
this.isDetailOrder = options.isDetailOrder
|
|
||||||
}
|
|
||||||
if(options && options.isSelfAcceptOrder) {
|
|
||||||
this.isSelfAcceptOrder = options.isSelfAcceptOrder
|
|
||||||
}
|
|
||||||
|
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
chooseImgList(e) {
|
chooseImgList(e) {
|
||||||
uni.chooseMedia({
|
uni.chooseImage({
|
||||||
count: 9, //默认9
|
count: 9, //默认9
|
||||||
mediaType: ['image'],
|
|
||||||
sizeType: ['original', 'compressed'], //可以指定是原图还是压缩图,默认二者都有
|
sizeType: ['original', 'compressed'], //可以指定是原图还是压缩图,默认二者都有
|
||||||
sourceType: ['album'], //从相册选择
|
sourceType: ['album'], //从相册选择
|
||||||
success: (res) => {
|
success: (res) => {
|
||||||
uni.showLoading({
|
if (this.formData.imgList.length != 0) {
|
||||||
title: '上传中',
|
this.formData.imgList = this.formData.imgList.concat(res.tempFilePaths)
|
||||||
mask: true
|
} else {
|
||||||
});
|
this.formData.imgList = res.tempFilePaths
|
||||||
res.tempFiles.forEach((fileObj, index) => {
|
|
||||||
this.$request.uploadFile(fileObj.tempFilePath).then((url) => {
|
|
||||||
this.formData.imgList.push(url);
|
|
||||||
if (index === res.tempFiles.length - 1) {
|
|
||||||
uni.hideLoading();
|
|
||||||
}
|
}
|
||||||
});
|
|
||||||
});
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
|
@ -143,71 +132,7 @@
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
reasonChange(e) {
|
reasonChange(e) {
|
||||||
this.formData.returnReason = this.cancelReasonList[e.detail.value].reasonName
|
this.formData.reasonObj = this.cancelReasonList[e.detail.value]
|
||||||
},
|
|
||||||
submitCancelOrder() {
|
|
||||||
if(!this.formData.returnReason) {
|
|
||||||
uni.showToast({
|
|
||||||
title: '请选择申请原因',
|
|
||||||
icon: 'none'
|
|
||||||
})
|
|
||||||
return
|
|
||||||
}
|
|
||||||
if(!this.formData.returnReasonDetail) {
|
|
||||||
uni.showToast({
|
|
||||||
title: '请填写具体原因',
|
|
||||||
icon: 'none'
|
|
||||||
})
|
|
||||||
return
|
|
||||||
}
|
|
||||||
|
|
||||||
// if(this.isDetailOrder == 1 && this.isSelfAcceptOrder) {
|
|
||||||
// uni.showModal({
|
|
||||||
// title: '提示',
|
|
||||||
// content: this.orderType == 1 ? '确认后订单回到你拣货/发货栏,你可重新派单或操作彻底退单' : '确认后订单回到你未约/未排栏,你可重新派单或操作彻底退单',
|
|
||||||
// success: (res) => {
|
|
||||||
// if(res.confirm) {
|
|
||||||
// this.cancelSend()
|
|
||||||
// }
|
|
||||||
// },
|
|
||||||
// })
|
|
||||||
// } else {
|
|
||||||
this.cancelSend()
|
|
||||||
// }
|
|
||||||
},
|
|
||||||
async cancelSend() {
|
|
||||||
const params = {
|
|
||||||
id: this.orderId,
|
|
||||||
returnImages: this.formData.imgList.length ? this.formData.imgList.toString() : '',
|
|
||||||
returnReason: this.formData.returnReason,
|
|
||||||
returnReasonDetail: this.formData.returnReasonDetail
|
|
||||||
}
|
|
||||||
let funcName = 'rejectMasterOrderWhenAccepted'
|
|
||||||
if(this.isDetailOrder == 1) {
|
|
||||||
funcName = 'rejectDetailOrder'
|
|
||||||
}
|
|
||||||
let res = await this.$request[funcName](params);
|
|
||||||
if (res && res.code === 0) {
|
|
||||||
uni.showToast({
|
|
||||||
icon: 'none',
|
|
||||||
title: '退单成功',
|
|
||||||
duration: 1000
|
|
||||||
})
|
|
||||||
await this.$request.addOrderOperate({
|
|
||||||
orderId: this.orderId,
|
|
||||||
orderType: '01',
|
|
||||||
content: '师傅退单'
|
|
||||||
})
|
|
||||||
uni.navigateBack({
|
|
||||||
delta: -1
|
|
||||||
})
|
|
||||||
} else {
|
|
||||||
uni.showToast({
|
|
||||||
icon: 'none',
|
|
||||||
title: res.msg,
|
|
||||||
duration: 2000
|
|
||||||
})
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,163 +0,0 @@
|
||||||
<template>
|
|
||||||
<view>
|
|
||||||
<!-- 顶部操作条 -->
|
|
||||||
<cu-custom :bgColor="'bg-main-color'" :isBack="true" :isBackHome="true" :homePageUrl="'/pages/index/index'">
|
|
||||||
<block slot="content">选择门店</block>
|
|
||||||
</cu-custom>
|
|
||||||
<!-- 产品列表 -->
|
|
||||||
<view class="padding-lr padding-top bg-white solid-top">
|
|
||||||
<view class="solid-bottom margin-bottom-sm padding-bottom-sm"
|
|
||||||
v-for="(item, index) in productList" :key="item.id">
|
|
||||||
<view class="flex-sub flex margin-top-sm">
|
|
||||||
<view style="height: 150rpx;line-height: 150rpx;margin-right: 10px;">
|
|
||||||
<radio class="main-color" :checked="chooseShopInfo && chooseShopInfo.shopId === item.shopId" @click="chooseShopInfo = item" />
|
|
||||||
</view>
|
|
||||||
<!-- <checkbox style="transform:scale(0.8);" class="main-color" :checked="chooseShopId === item.shopId" @click.stop="chooseShopId = item.shopId"></checkbox> -->
|
|
||||||
<view style="width: 150rpx;height: 150rpx;margin-right:10px;display: flex;flex-direction: row;justify-content: center;">
|
|
||||||
<image style="width: 100%;height: 100%;" :src="item.imageUrl" mode="aspectFill"></image>
|
|
||||||
</view>
|
|
||||||
<view class="flex-sub">
|
|
||||||
<view class="text-bold" style="text-overflow: ellipsis;overflow: hidden;display: -webkit-box;-webkit-box-orient: vertical;-webkit-line-clamp: 1;">{{item.shopName}}</view>
|
|
||||||
<view>
|
|
||||||
<view style="text-overflow: ellipsis;overflow: hidden;display: -webkit-box;-webkit-box-orient: vertical;-webkit-line-clamp: 1;">{{item.provinceName + item.cityName + item.countryName + item.streetName + item.address}}</view>
|
|
||||||
<view class="margin-lr-sm" style="display: inline-block;" v-if="item.distance">
|
|
||||||
<view class="cu-tag bg-red" style="padding: 0 2px;height: auto;">距离客户</view>
|
|
||||||
<text class="text-gray" style="vertical-align: middle;">{{item.distance}}</text>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
|
|
||||||
<view v-if="index == 0">
|
|
||||||
<text style="font-size: 24rpx;color: #0081ff;">您购买的商品的店铺所属服务点(距离近可优先选择)</text>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
|
|
||||||
<!-- 底部新增地址按钮 -->
|
|
||||||
<view class="cu-bar tabbar border shop fixed-bottom-bar bg-back">
|
|
||||||
<button class="cu-btn bg-main-color long-btn margin-lr-sm shadow-blur" @click="selectShop">确定</button>
|
|
||||||
</view>
|
|
||||||
<!-- <view class="margin-bottom-lg">
|
|
||||||
<view v-if="hasMoreData" class="text-center bg-main-color padding-tb text-lg" @click="loadProductData">
|
|
||||||
<text class="margin-right-xs">查看更多</text>
|
|
||||||
<text class="text-bold cuIcon-unfold"></text>
|
|
||||||
</view>
|
|
||||||
<view class="cu-load" :class="loadMoreStatus"></view>
|
|
||||||
</view> -->
|
|
||||||
</view>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<script>
|
|
||||||
|
|
||||||
export default {
|
|
||||||
data() {
|
|
||||||
return {
|
|
||||||
productList: [],
|
|
||||||
loadMoreStatus: '',
|
|
||||||
hasMoreData: false,
|
|
||||||
pageNum: this.$globalData.initPageNum,
|
|
||||||
pageSize: this.$globalData.initPageSize,
|
|
||||||
inputGoodsName: null,
|
|
||||||
goodsId: null,
|
|
||||||
shopId: null,
|
|
||||||
chooseShopInfo: null,
|
|
||||||
addressFull: null,
|
|
||||||
}
|
|
||||||
},
|
|
||||||
async onLoad(options) {
|
|
||||||
this.goodsId = options.goodsId;
|
|
||||||
this.shopId = options.shopId;
|
|
||||||
this.addressFullObj = JSON.parse(options.addressFullObj)
|
|
||||||
|
|
||||||
this.loadData();
|
|
||||||
},
|
|
||||||
methods: {
|
|
||||||
async loadData() {
|
|
||||||
this.pageNum = this.$globalData.initPageNum;
|
|
||||||
this.pageSize = this.$globalData.initPageSize;
|
|
||||||
this.loadProductData();
|
|
||||||
},
|
|
||||||
loadCategoryList(type = 1) {},
|
|
||||||
async loadProductData(params = {}) {
|
|
||||||
params.pageNum = this.pageNum;
|
|
||||||
params.pageSize = this.pageSize;
|
|
||||||
// if(this.addressLatitude && this.addressLongitude) {
|
|
||||||
// params.latitude = this.addressLatitude
|
|
||||||
// params.longitude = this.addressLongitude
|
|
||||||
// }
|
|
||||||
params.provinceName = this.addressFullObj.provinceName,
|
|
||||||
params.cityName = this.addressFullObj.cityName,
|
|
||||||
params.countryName = this.addressFullObj.countryName,
|
|
||||||
params.streetName = this.addressFullObj.streetName,
|
|
||||||
params.address = this.addressFullObj.address
|
|
||||||
params.goodsId = this.goodsId
|
|
||||||
// params.goodsId = 2089
|
|
||||||
|
|
||||||
this.loadMoreStatus = 'loading bg-main-color padding-tb text-lg';
|
|
||||||
this.hasMoreData = false;
|
|
||||||
try {
|
|
||||||
await this.loadShopPage(params);
|
|
||||||
this.loadMoreStatus = this.hasMoreData ? '' : 'over bg-grey padding-tb text-lg';
|
|
||||||
} catch (e) {
|
|
||||||
this.loadMoreStatus = 'erro bg-red padding-tb text-lg'
|
|
||||||
}
|
|
||||||
},
|
|
||||||
reloadShopPage() {
|
|
||||||
this.pageNum = this.$globalData.initPageNum;
|
|
||||||
this.pageSize = this.$globalData.initPageSize;
|
|
||||||
this.pageNumOfOtherCityPage = this.$globalData.initPageNum;
|
|
||||||
this.productList = [];
|
|
||||||
this.loadProductData();
|
|
||||||
},
|
|
||||||
async loadShopPage(params) {
|
|
||||||
let res = await this.$request.getShopsByGoodsId(params);
|
|
||||||
// let rowsLength = res[1].data.rows.length;
|
|
||||||
// if (rowsLength === this.pageSize) {
|
|
||||||
// this.hasMoreData = true;
|
|
||||||
// }
|
|
||||||
// if (this.pageNum === this.$globalData.initPageNum) {
|
|
||||||
// this.productList = res[1].data.rows;
|
|
||||||
// } else {
|
|
||||||
// this.productList = this.productList.concat(res[1].data.rows);
|
|
||||||
// }
|
|
||||||
// this.pageNum++;
|
|
||||||
|
|
||||||
this.productList = res.data.serviceShops
|
|
||||||
this.chooseShopInfo = res.data.serviceShops.find(i => i.shopId == this.shopId)
|
|
||||||
console.log(this.productList);
|
|
||||||
},
|
|
||||||
searchGoods() {
|
|
||||||
this.reloadShopPage();
|
|
||||||
},
|
|
||||||
selectShop() {
|
|
||||||
uni.$emit('chooseShop', this.chooseShopInfo);
|
|
||||||
uni.navigateBack({
|
|
||||||
delta: -1
|
|
||||||
})
|
|
||||||
}
|
|
||||||
},
|
|
||||||
}
|
|
||||||
</script>
|
|
||||||
|
|
||||||
<style scoped>
|
|
||||||
.search-nav-item-text {
|
|
||||||
width: 100rpx;
|
|
||||||
}
|
|
||||||
|
|
||||||
.nav .cu-item {
|
|
||||||
height: 90rpx;
|
|
||||||
display: inline-block;
|
|
||||||
line-height: 90rpx;
|
|
||||||
margin: 0;
|
|
||||||
padding: 0 10rpx;
|
|
||||||
width: 180rpx;
|
|
||||||
background-color: transparent;
|
|
||||||
}
|
|
||||||
|
|
||||||
.cu-load {
|
|
||||||
display: block;
|
|
||||||
line-height: unset;
|
|
||||||
text-align: center;
|
|
||||||
}
|
|
||||||
</style>
|
|
||||||
|
|
@ -1,261 +0,0 @@
|
||||||
<template>
|
|
||||||
<view v-if="afterServiceRecord">
|
|
||||||
<view v-if="afterServiceRecord.createBy == 1" class="padding-tb solid-top">
|
|
||||||
<view class='cu-tag bg-main-color radius light'>售后发起中</view>
|
|
||||||
<view class="text-gray text-sm margin-bottom-xs">您需快速操作反馈,24小时内不操作将自动同意!</view>
|
|
||||||
<view v-if="afterServiceRecord.operType === 1">
|
|
||||||
<view class="flex justify-start align-end">
|
|
||||||
<text>退款申请:</text>
|
|
||||||
<uni-countdown :show-colon="false" :backgroundColor="'#eee'"
|
|
||||||
:day="$dateUtil.countDownDiff($dateUtil.addHours(afterServiceRecord.createTime, 24)).day"
|
|
||||||
:hour="$dateUtil.countDownDiff($dateUtil.addHours(afterServiceRecord.createTime, 24)).hour"
|
|
||||||
:minute="$dateUtil.countDownDiff($dateUtil.addHours(afterServiceRecord.createTime, 24)).min"
|
|
||||||
:second="$dateUtil.countDownDiff($dateUtil.addHours(afterServiceRecord.createTime, 24)).seconds">
|
|
||||||
</uni-countdown>
|
|
||||||
</view>
|
|
||||||
<view>
|
|
||||||
<text>退款金额:</text>
|
|
||||||
<text v-if="afterServiceRecord.refund">{{afterServiceRecord.refund}}</text>
|
|
||||||
<text v-else-if="order.payMoney">{{order.payMoney}}</text>
|
|
||||||
</view>
|
|
||||||
<view>
|
|
||||||
<text>退款原因:</text>
|
|
||||||
<text v-if="afterServiceRecord.customerReasonType === 1">上门/服务不守时</text>
|
|
||||||
<text v-else-if="afterServiceRecord.customerReasonType === 2">态度不友好,无法继续</text>
|
|
||||||
<text v-else-if="afterServiceRecord.customerReasonType === 3">服务效果差,未达到合格</text>
|
|
||||||
<text v-else-if="afterServiceRecord.customerReasonType === 4">技能水平问题,未妥善完成</text>
|
|
||||||
<text v-else-if="afterServiceRecord.customerReasonType === 5">要求加费用,费用不合理</text>
|
|
||||||
<text v-else-if="afterServiceRecord.customerReasonType === 6">订单拖太久了</text>
|
|
||||||
<text v-else-if="afterServiceRecord.customerReasonType === 7">超了些服务内容,师傅不接受</text>
|
|
||||||
<text v-else-if="afterServiceRecord.customerReasonType === 8">客户/我时间不方便了</text>
|
|
||||||
<text v-else-if="afterServiceRecord.customerReasonType === 9">客户/我已让别的师傅服务了</text>
|
|
||||||
</view>
|
|
||||||
<view>
|
|
||||||
<text>具体原因:</text>
|
|
||||||
<text v-if="afterServiceRecord.customerReason">{{afterServiceRecord.customerReason}}</text>
|
|
||||||
</view>
|
|
||||||
<view class="grid col-3 grid-square flex-sub margin-top-sm">
|
|
||||||
<view class="bg-img" v-for="(imgObj, imgIndex) in afterServiceRecord.imgsList" :key="imgIndex" v-if="imgObj.imgUploadBy === 1">
|
|
||||||
<image :src="imgObj.imgUrl" @tap="viewImage($event, [imgObj.imgUrl])" :data-url="imgObj.imgUrl" mode="aspectFill"></image>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view>
|
|
||||||
<text class="text-red" v-if="order.workerId == order.masterWorkerId && !order.isOnlyServ && order.payMoney < afterServiceRecord.refund && afterServiceRecord.customerFinalCheck == null">警报:退单金额大于该师傅接单金额,但客户发起的退款金额有效,您需介入处理,如让接单师傅系统上操作同意退款,系统最大按该单派单额退回客户,其余需人工处理!如属于师傅责任引起的退单,建议重做,重做后让客户撤消退单!</text>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view v-else-if="afterServiceRecord.operType === 2">
|
|
||||||
<view class="flex justify-start align-end">
|
|
||||||
<text>待处理售后:</text>
|
|
||||||
<uni-countdown :show-colon="false" :backgroundColor="'#eee'"
|
|
||||||
:day="$dateUtil.countDownDiff($dateUtil.addHours(afterServiceRecord.createTime, 24)).day"
|
|
||||||
:hour="$dateUtil.countDownDiff($dateUtil.addHours(afterServiceRecord.createTime, 24)).hour"
|
|
||||||
:minute="$dateUtil.countDownDiff($dateUtil.addHours(afterServiceRecord.createTime, 24)).min"
|
|
||||||
:second="$dateUtil.countDownDiff($dateUtil.addHours(afterServiceRecord.createTime, 24)).seconds">
|
|
||||||
</uni-countdown>
|
|
||||||
</view>
|
|
||||||
<view>
|
|
||||||
<text>售后原因:</text>
|
|
||||||
<text v-if="afterServiceRecord.customerReasonType === 1">上门/服务不守时</text>
|
|
||||||
<text v-else-if="afterServiceRecord.customerReasonType === 2">态度不友好,无法继续</text>
|
|
||||||
<text v-else-if="afterServiceRecord.customerReasonType === 3">服务效果差,未达到合格</text>
|
|
||||||
<text v-else-if="afterServiceRecord.customerReasonType === 4">技能水平问题,未妥善完成</text>
|
|
||||||
<text v-else-if="afterServiceRecord.customerReasonType === 5">要求加费用,费用不合理</text>
|
|
||||||
<text v-else-if="afterServiceRecord.customerReasonType === 6">订单拖太久了</text>
|
|
||||||
<text v-else-if="afterServiceRecord.customerReasonType === 7">超了些服务内容,师傅不接受</text>
|
|
||||||
<text v-else-if="afterServiceRecord.customerReasonType === 8">客户/我时间不方便了</text>
|
|
||||||
<text v-else-if="afterServiceRecord.customerReasonType === 9">客户/我已让别的师傅服务了</text>
|
|
||||||
</view>
|
|
||||||
<view>
|
|
||||||
<text>具体原因:</text>
|
|
||||||
<text v-if="afterServiceRecord.customerReason">{{afterServiceRecord.customerReason}}</text>
|
|
||||||
</view>
|
|
||||||
<view>
|
|
||||||
<text>完成操作:点击“操作处理”提交由客服回访!</text>
|
|
||||||
</view>
|
|
||||||
<view class="grid col-3 grid-square flex-sub margin-top-sm">
|
|
||||||
<view class="bg-img" v-for="(imgObj, imgIndex) in afterServiceRecord.imgsList" :key="imgIndex" v-if="imgObj.imgUploadBy === 1">
|
|
||||||
<image :src="imgObj.imgUrl" @tap="viewImage($event, [imgObj.imgUrl])" :data-url="imgObj.imgUrl" mode="aspectFill"></image>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="flex justify-end align-end margin-tb-sm" v-if="!afterServiceRecord.updateBy && afterServiceRecord.workerFeedbackResult === null && showActionBtn">
|
|
||||||
<button class="cu-btn sm bg-yellow margin-right-sm" @tap="$emit('redoGoHome')">上门重做</button>
|
|
||||||
<button class="cu-btn sm bg-yellow margin-right-sm" @tap="$emit('callModal', 'rejectAfterSale')">拒绝处理</button>
|
|
||||||
<button class="cu-btn sm bg-yellow margin-right-sm" @tap="$emit('callModal', 'agreeAfterSale')">操作处理</button>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view v-if="afterServiceRecord.updateBy == 2" class="padding-tb solid-top">
|
|
||||||
<view class='cu-tag bg-main-color radius light'>师傅反馈</view>
|
|
||||||
<view>
|
|
||||||
<view class="margin-top-xs">
|
|
||||||
<text>师傅反馈结果:</text>
|
|
||||||
<text v-if="afterServiceRecord.workerFeedbackResult === 0">拒绝</text>
|
|
||||||
<text v-else-if="afterServiceRecord.workerFeedbackResult === 1">同意</text>
|
|
||||||
<text v-else-if="afterServiceRecord.workerFeedbackResult === 2 || afterServiceRecord.workerFeedbackResult === 3">上门重做/补做</text>
|
|
||||||
</view>
|
|
||||||
<view v-if="afterServiceRecord.workerFeedbackResult === 1">
|
|
||||||
<text>同意退款金额:</text>
|
|
||||||
<text>{{afterServiceRecord.agreedRefund ? afterServiceRecord.agreedRefund : afterServiceRecord.refund}}</text>
|
|
||||||
</view>
|
|
||||||
<view style="padding-left: 196upx;" v-if="afterServiceRecord.workerFeedbackResult === 2 || afterServiceRecord.workerFeedbackResult === 3">
|
|
||||||
<view>客户同意则本次退款金额为0元</view>
|
|
||||||
<view>客户同意的需马上处理并重新提交</view>
|
|
||||||
<view class="text-right" v-if="afterServiceRecord.customerAgreeRedo === 1">
|
|
||||||
<view class='cu-tag bg-main-color radius light'>客户同意方案</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<template v-if="afterServiceRecord.workerFeedbackResult == 0 || afterServiceRecord.workerFeedbackResult == 1">
|
|
||||||
<view>
|
|
||||||
<text>师傅反馈:</text>
|
|
||||||
<text v-if="afterServiceRecord.workerFeedbackReasonType === 1">客户原因</text>
|
|
||||||
<text v-else-if="afterServiceRecord.workerFeedbackReasonType === 2">师傅原因</text>
|
|
||||||
<text v-else-if="afterServiceRecord.workerFeedbackReasonType === 3">其他</text>
|
|
||||||
<text v-if="afterServiceRecord.workerFeedbackReason">
|
|
||||||
<text v-if="afterServiceRecord.workerFeedbackReasonType">,</text>
|
|
||||||
{{afterServiceRecord.workerFeedbackReason}}
|
|
||||||
</text>
|
|
||||||
</view>
|
|
||||||
<view class="grid col-3 grid-square flex-sub margin-top-sm" v-if="afterServiceRecord.workerFeedbackImages">
|
|
||||||
<view class="bg-img" v-for="(imgUrl, imgIndex) in afterServiceRecord.workerFeedbackImages.split(',')" :key="imgIndex">
|
|
||||||
<image :src="imgUrl" @tap="viewImage($event, [imgUrl])" :data-url="imgUrl" mode="aspectFill"></image>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</template>
|
|
||||||
<template v-else-if="afterServiceRecord.workerFeedbackResult === 3">
|
|
||||||
<view class="margin-top-xs">
|
|
||||||
<text>师傅重做/补做提交:</text>
|
|
||||||
</view>
|
|
||||||
<view class="grid col-3 grid-square flex-sub margin-top-sm" v-if="afterServiceRecord.redoCompleteImages">
|
|
||||||
<view class="bg-img" v-for="(imgUrl, imgIndex) in afterServiceRecord.redoCompleteImages.split(',')" :key="imgIndex">
|
|
||||||
<image :src="imgUrl" @tap="viewImage($event, [imgUrl])" :data-url="imgUrl" mode="aspectFill"></image>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="margin-bottom-xs">
|
|
||||||
<text>{{afterServiceRecord.redoCompleteRemark}}</text>
|
|
||||||
</view>
|
|
||||||
</template>
|
|
||||||
</view>
|
|
||||||
|
|
||||||
<view style="border-top: 1px solid gainsboro;padding-top: 10upx;" v-if="afterServiceRecord.customerFinalCheck == null && afterServiceRecord.redoCompleteTime && (afterServiceRecord.workerFeedbackResult === 0 || afterServiceRecord.workerFeedbackResult === 1 || afterServiceRecord.workerFeedbackResult === 3)">
|
|
||||||
<text class="text-gray" style="font-size: 20upx;">待客户验收或审核,36小时未操作将自动取消本次售后</text>
|
|
||||||
<view class="flex align-center margin-top-sm">
|
|
||||||
<text>工单时限:</text>
|
|
||||||
<uni-countdown :show-colon="false" :backgroundColor="'#eee'"
|
|
||||||
:day="$dateUtil.countDownDiff($dateUtil.addHours(afterServiceRecord.redoCompleteTime, 36)).day"
|
|
||||||
:hour="$dateUtil.countDownDiff($dateUtil.addHours(afterServiceRecord.redoCompleteTime, 36)).hour"
|
|
||||||
:minute="$dateUtil.countDownDiff($dateUtil.addHours(afterServiceRecord.redoCompleteTime, 36)).min"
|
|
||||||
:second="$dateUtil.countDownDiff($dateUtil.addHours(afterServiceRecord.redoCompleteTime, 36)).seconds">
|
|
||||||
</uni-countdown>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
|
|
||||||
|
|
||||||
<view class="flex justify-end align-end margin-tb-sm" v-if="afterServiceRecord.workerFeedbackResult === 2 && showActionBtn">
|
|
||||||
<button class="cu-btn sm bg-yellow margin-right-sm" @tap="$emit('callModal', 'showReFinishSubmit')">重做/补做提交</button>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view v-if="afterServiceRecord.customerFinalCheck != null" class="padding-tb solid-top">
|
|
||||||
<template v-if="order.afterPlatformServiceStatus === 0 || order.afterPlatformServiceStatus == 1">
|
|
||||||
<view class='cu-tag bg-main-color radius light'>客户最终确认</view>
|
|
||||||
<view class="margin-top-xs">
|
|
||||||
{{afterServiceRecord.customerFinalCheck === 1 ? '同意' : '不同意'}}
|
|
||||||
<text v-if="afterServiceRecord.isAutoProcessed == 1 && afterServiceRecord.customerFinalCheck === 1">(超时系统自动同意)</text>
|
|
||||||
</view>
|
|
||||||
<view v-if="afterServiceRecord.customerFinalCheck === 0">
|
|
||||||
<view class="grid col-3 grid-square flex-sub margin-top-sm" v-if="afterServiceRecord.customerDisagreeImages">
|
|
||||||
<view class="bg-img" v-for="imgUrl in afterServiceRecord.customerDisagreeImages.split(',')" :key="imgUrl">
|
|
||||||
<image :src="imgUrl" @tap="viewImage($event, [imgUrl])" :data-url="imgUrl" mode="aspectFill"></image>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="margin-bottom-xs" v-if="afterServiceRecord.customerDisagreeReason">
|
|
||||||
<text>不同意理由:{{afterServiceRecord.customerDisagreeReason}}</text>
|
|
||||||
</view>
|
|
||||||
<view class="text-red" v-if="afterServiceRecord.customerFinalCheck === 0">订单交由平台协商处理</view>
|
|
||||||
<view v-if="afterServiceRecord.customerFinalCheck === 0">系统提示您,如能协商尽可能与客户协商一致(能重新协商则按双方认可方案重新发起)!可让客户撤单最佳。</view>
|
|
||||||
</view>
|
|
||||||
<view v-else-if="afterServiceRecord.customerFinalCheck === 1">
|
|
||||||
<template v-if="afterServiceRecord.workerFeedbackResult !== 0">
|
|
||||||
<view v-if="(afterServiceRecord.agreedRefund > 0 || afterServiceRecord.originalRefund > 0) && order.refundPayStatus == 1">
|
|
||||||
<view>
|
|
||||||
<text>本单退款,系统已发起按客户支付的帐户原路退回</text>
|
|
||||||
<text class="text-red">{{afterServiceRecord.originalRefund || afterServiceRecord.agreedRefund}}</text>
|
|
||||||
<text>元,银行按工作日退款,节假日顺延到帐。遇客户问询,请其耐心等待,到账时会在客户端”客户最终确认“处有到账时间。</text>
|
|
||||||
</view>
|
|
||||||
<view>退款支付到账:{{afterServiceRecord.refundApplyTime}}</view>
|
|
||||||
</view>
|
|
||||||
<view v-else-if="order.refundPayStatus == 0">
|
|
||||||
<text v-if="afterServiceRecord.workerFeedbackResult === 3">本次售后已重新补做并验收完成(退款额为0)。</text>
|
|
||||||
<text v-else>本单已退款<text class="text-red">{{afterServiceRecord.originalRefund || afterServiceRecord.agreedRefund}}</text>元,因未实际支付,实退为0元。未退部分继续完成订单及正常支付!</text>
|
|
||||||
</view>
|
|
||||||
</template>
|
|
||||||
<view v-else>
|
|
||||||
<text>本次售后已操作完毕,售后申请已结束!</text>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</template>
|
|
||||||
<template v-else-if="order.afterPlatformServiceStatus === 2 || order.afterPlatformServiceStatus === 3">
|
|
||||||
<view class='cu-tag bg-main-color radius light'>客户最终确认</view>
|
|
||||||
<view class="margin-top-xs">
|
|
||||||
{{order.afterPlatformServiceStatus === 2 ? '同意' : '取消售后'}}
|
|
||||||
(平台操作)
|
|
||||||
</view>
|
|
||||||
<view v-if="afterServiceRecord.platformHandleReason">
|
|
||||||
<text>平台意见:{{afterServiceRecord.platformHandleReason}}</text>
|
|
||||||
</view>
|
|
||||||
<view v-if="order.afterPlatformServiceStatus === 3">
|
|
||||||
<text>本次售后已操作完毕,售后申请已结束!</text>
|
|
||||||
</view>
|
|
||||||
<template v-else>
|
|
||||||
<view v-if="(afterServiceRecord.platformRefund || afterServiceRecord.agreedRefund) && order.refundPayStatus == 1">
|
|
||||||
<view>
|
|
||||||
<text>本单退款,系统已发起按客户支付的帐户原路退回</text>
|
|
||||||
<text class="text-red">{{afterServiceRecord.platformRefund || afterServiceRecord.agreedRefund}}</text>
|
|
||||||
<text>元,银行按工作日退款,节假日顺延到帐。遇客户问询,请其耐心等待,到账时会在客户端”客户最终确认“处有到账时间。</text>
|
|
||||||
</view>
|
|
||||||
<view>退款支付到账:{{afterServiceRecord.refundApplyTime}}</view>
|
|
||||||
</view>
|
|
||||||
<view v-else-if="order.refundPayStatus == 0">
|
|
||||||
<text>本单已退款<text class="text-red">{{afterServiceRecord.platformRefund || afterServiceRecord.agreedRefund || 0}}</text>元,因未实际支付,实退为0元。未退部分继续完成订单及正常支付!</text>
|
|
||||||
</view>
|
|
||||||
</template>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<script>
|
|
||||||
export default {
|
|
||||||
emits: ['redoGoHome', 'callModal'],
|
|
||||||
props: {
|
|
||||||
afterServiceRecord: {
|
|
||||||
type: Object,
|
|
||||||
default: () => {}
|
|
||||||
},
|
|
||||||
order: {
|
|
||||||
type: Object,
|
|
||||||
default: () => {}
|
|
||||||
},
|
|
||||||
showActionBtn: {
|
|
||||||
type: Boolean,
|
|
||||||
default: true
|
|
||||||
}
|
|
||||||
},
|
|
||||||
data() {
|
|
||||||
return {
|
|
||||||
|
|
||||||
}
|
|
||||||
},
|
|
||||||
methods: {
|
|
||||||
viewImage(e, imgList) {
|
|
||||||
uni.previewImage({
|
|
||||||
urls: imgList,
|
|
||||||
current: e.currentTarget.dataset.url
|
|
||||||
});
|
|
||||||
},
|
|
||||||
}
|
|
||||||
}
|
|
||||||
</script>
|
|
||||||
|
|
||||||
<style>
|
|
||||||
</style>
|
|
||||||
|
|
@ -1,394 +0,0 @@
|
||||||
<template>
|
|
||||||
<view v-if="afterServiceRecord">
|
|
||||||
<view v-if="afterServiceRecord.createBy == 1" class="padding-tb solid-top">
|
|
||||||
<view class='cu-tag bg-main-color radius light'>售后发起中</view>
|
|
||||||
<view class="text-gray text-sm margin-bottom-xs">您需快速操作反馈,24小时内不操作将自动同意!</view>
|
|
||||||
<view v-if="afterServiceRecord.operType === 1">
|
|
||||||
<view class="flex justify-start align-end">
|
|
||||||
<text>{{afterServiceRecord.operType === 1 ? '退款申请:' : '待处理售后:'}}</text>
|
|
||||||
<uni-countdown :show-colon="false" :backgroundColor="'#eee'"
|
|
||||||
:day="$dateUtil.countDownDiff($dateUtil.addHours(afterServiceRecord.createTime, 24)).day"
|
|
||||||
:hour="$dateUtil.countDownDiff($dateUtil.addHours(afterServiceRecord.createTime, 24)).hour"
|
|
||||||
:minute="$dateUtil.countDownDiff($dateUtil.addHours(afterServiceRecord.createTime, 24)).min"
|
|
||||||
:second="$dateUtil.countDownDiff($dateUtil.addHours(afterServiceRecord.createTime, 24)).seconds">
|
|
||||||
</uni-countdown>
|
|
||||||
</view>
|
|
||||||
<view>
|
|
||||||
<text>退款金额:</text>
|
|
||||||
<text v-if="afterServiceRecord.refund">{{afterServiceRecord.refund}}</text>
|
|
||||||
<text v-else-if="order.payMoney">{{order.payMoney}}</text>
|
|
||||||
</view>
|
|
||||||
<view>
|
|
||||||
<text>售后类型:</text>
|
|
||||||
<text v-if="afterServiceRecord.afterServiceType === 1">未收到货,我要退单退款!</text>
|
|
||||||
<text v-else-if="afterServiceRecord.afterServiceType === 2">未收到货(发货在途),我要退款!</text>
|
|
||||||
<text v-else-if="afterServiceRecord.afterServiceType === 3">已收到货,我要退款退货!</text>
|
|
||||||
</view>
|
|
||||||
<view>
|
|
||||||
<text>申请原因:</text>
|
|
||||||
<text v-if="afterServiceRecord.customerReasonType === 1">不想要了</text>
|
|
||||||
<text v-else-if="afterServiceRecord.customerReasonType === 2">买错型号尺寸了</text>
|
|
||||||
<text v-else-if="afterServiceRecord.customerReasonType === 3">材质与商品描述不符</text>
|
|
||||||
<text v-else-if="afterServiceRecord.customerReasonType === 4">大小尺寸与商品描述不符</text>
|
|
||||||
<text v-else-if="afterServiceRecord.customerReasonType === 5">颜色、款式、型号与描述不符</text>
|
|
||||||
<text v-else-if="afterServiceRecord.customerReasonType === 6">出现质量问题</text>
|
|
||||||
<text v-else-if="afterServiceRecord.customerReasonType === 7">收到商品少件(少配件)</text>
|
|
||||||
<text v-else-if="afterServiceRecord.customerReasonType === 8">商家发错货</text>
|
|
||||||
<text v-else-if="afterServiceRecord.customerReasonType === 9">商品破损或污渍</text>
|
|
||||||
<text v-else-if="afterServiceRecord.customerReasonType === 10">未按承诺时间发货</text>
|
|
||||||
<text v-else-if="afterServiceRecord.customerReasonType === 11">未见快递/物流有信息</text>
|
|
||||||
<text v-else-if="afterServiceRecord.customerReasonType === 12">其它原因</text>
|
|
||||||
</view>
|
|
||||||
<view>
|
|
||||||
<text>具体原因:</text>
|
|
||||||
<text v-if="afterServiceRecord.customerReason">{{afterServiceRecord.customerReason}}</text>
|
|
||||||
</view>
|
|
||||||
<view v-if="afterServiceRecord.operType === 2">
|
|
||||||
<text>完成操作:点击“操作处理”提交由客服回访!</text>
|
|
||||||
</view>
|
|
||||||
<view class="grid col-3 grid-square flex-sub margin-top-sm">
|
|
||||||
<view class="bg-img" v-for="(imgObj, imgIndex) in afterServiceRecord.imgsList" :key="imgIndex" v-if="imgObj.imgUploadBy === 1">
|
|
||||||
<image :src="imgObj.imgUrl" @tap="viewImage($event, [imgObj.imgUrl])" :data-url="imgObj.imgUrl" mode="aspectFill"></image>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view>
|
|
||||||
<text class="text-red" v-if="order.workerId == order.masterWorkerId && !order.isOnlyServ && order.payMoney < afterServiceRecord.refund && afterServiceRecord.customerFinalCheck == null">警报:退单金额大于该师傅接单金额,但客户发起的退款金额有效,您需介入处理,如让接单师傅系统上操作同意退款,系统最大按该单派单额退回客户,其余需人工处理!如属于师傅责任引起的退单,建议重做,重做后让客户撤消退单!</text>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<!-- <view class="flex justify-end align-end margin-tb-sm" v-if="!afterServiceRecord.updateBy || afterServiceRecord.updateBy == 1">
|
|
||||||
<button class="cu-btn sm bg-yellow margin-right-sm" @tap="showModalByRef('sure2Revisit', order, null)">重发/补发</button>
|
|
||||||
<button class="cu-btn sm bg-yellow margin-right-sm" data-modal="rejectAfterSale" @tap="showModal($event, order)">拒绝处理</button>
|
|
||||||
<button class="cu-btn sm bg-yellow margin-right-sm" data-modal="agreeAfterSale" @tap="showModal($event, order)">操作处理</button>
|
|
||||||
</view> -->
|
|
||||||
<!-- {{!afterServiceRecord.updateBy}}
|
|
||||||
{{afterServiceRecord.workerFeedbackResult === null}}
|
|
||||||
{{showActionBtn}} -->
|
|
||||||
<view class="flex justify-end align-end margin-tb-sm" v-if="(!afterServiceRecord.updateBy || afterServiceRecord.updateBy == 1) && afterServiceRecord.workerFeedbackResult === null && showActionBtn">
|
|
||||||
<button class="cu-btn sm bg-yellow margin-right-sm" @tap="$emit('redoGoHome')">重发/补发</button>
|
|
||||||
<button class="cu-btn sm bg-yellow margin-right-sm" @tap="$emit('callModal', 'rejectAfterSale')">拒绝处理</button>
|
|
||||||
<button class="cu-btn sm bg-yellow margin-right-sm" @tap="$emit('callModal', 'agreeAfterSale')">操作处理</button>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view v-if="afterServiceRecord.updateBy != 1" class="padding-tb solid-top">
|
|
||||||
<view class='cu-tag bg-main-color radius light'>商家反馈</view>
|
|
||||||
<view>
|
|
||||||
<view class="margin-top-xs">
|
|
||||||
<text>商家反馈结果:</text>
|
|
||||||
<text v-if="afterServiceRecord.workerFeedbackResult === 0">拒绝</text>
|
|
||||||
<text v-else-if="afterServiceRecord.workerFeedbackResult === 1">同意</text>
|
|
||||||
<text v-else-if="afterServiceRecord.workerFeedbackResult === 2 || afterServiceRecord.workerFeedbackResult === 3">{{order.orderType == 1 ? '重发/补发商品' : '上门重做/补做'}}</text>
|
|
||||||
</view>
|
|
||||||
<template v-if="afterServiceRecord.workerFeedbackResult === 1">
|
|
||||||
<view>
|
|
||||||
<text>同意退款金额:</text>
|
|
||||||
<text>{{afterServiceRecord.agreedRefund ? afterServiceRecord.agreedRefund : afterServiceRecord.refund}}</text>
|
|
||||||
</view>
|
|
||||||
<view v-if="afterServiceRecord.workerReceiveStatus">
|
|
||||||
<text>收货状态:</text>
|
|
||||||
<text v-if="afterServiceRecord.workerReceiveStatus == 1">未发货</text>
|
|
||||||
<text v-else-if="afterServiceRecord.workerReceiveStatus == 2">已发货在途</text>
|
|
||||||
<text v-else-if="afterServiceRecord.workerReceiveStatus == 3">已收货</text>
|
|
||||||
<text v-else-if="afterServiceRecord.workerReceiveStatus == 4">售后保障期</text>
|
|
||||||
</view>
|
|
||||||
<view v-if="afterServiceRecord.workerAgreeType">
|
|
||||||
<text>同意选项:</text>
|
|
||||||
<text v-if="afterServiceRecord.workerAgreeType == 1">同意即时退单退款</text>
|
|
||||||
<text v-else-if="afterServiceRecord.workerAgreeType == 2">同意货物拦截后退单退款</text>
|
|
||||||
<text v-else-if="afterServiceRecord.workerAgreeType == 3">同意快递返回货物后退单退款</text>
|
|
||||||
<text v-else-if="afterServiceRecord.workerAgreeType == 4">同意您退回货物后退单退款</text>
|
|
||||||
</view>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<view v-if="afterServiceRecord.workerFeedbackResult === 2 || afterServiceRecord.workerFeedbackResult === 3" style="padding-left: 196upx;">
|
|
||||||
<view v-if="afterServiceRecord.workerResendPlan">
|
|
||||||
<text v-if="afterServiceRecord.workerResendPlan == 1">重发/补发,您无需退货</text>
|
|
||||||
<text v-if="afterServiceRecord.workerResendPlan == 2">重发/补发前,您需先退货</text>
|
|
||||||
<text v-if="afterServiceRecord.workerResendPlan == 3">请您退回商品,给你换货</text>
|
|
||||||
<text v-if="afterServiceRecord.workerResendPlan == 4">请退回商品,为您售后换货</text>
|
|
||||||
</view>
|
|
||||||
<view>客户同意则本次退款金额为0元</view>
|
|
||||||
<view>客户同意的需马上处理并重新提交</view>
|
|
||||||
</view>
|
|
||||||
<view v-if="afterServiceRecord.workerFeedbackResult !== 2 && afterServiceRecord.workerFeedbackResult !== 3">
|
|
||||||
<text>商家反馈:</text>
|
|
||||||
<text v-if="afterServiceRecord.workerFeedbackReasonType === 1">客户原因</text>
|
|
||||||
<text v-else-if="afterServiceRecord.workerFeedbackReasonType === 2">商家原因</text>
|
|
||||||
<text v-else-if="afterServiceRecord.workerFeedbackReasonType === 3">其他</text>
|
|
||||||
<text v-if="afterServiceRecord.workerFeedbackReason">
|
|
||||||
<text v-if="afterServiceRecord.workerFeedbackReasonType">,</text>
|
|
||||||
{{afterServiceRecord.workerFeedbackReason}}
|
|
||||||
</text>
|
|
||||||
</view>
|
|
||||||
|
|
||||||
<view class="grid col-3 grid-square flex-sub margin-top-sm" v-if="afterServiceRecord.workerFeedbackImages">
|
|
||||||
<view class="bg-img" v-for="(imgUrl, imgIndex) in afterServiceRecord.workerFeedbackImages.split(',')" :key="imgIndex">
|
|
||||||
<image :src="imgUrl" @tap="viewImage($event, [imgUrl])" :data-url="imgUrl" mode="aspectFill"></image>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
|
|
||||||
<view class="text-right" v-if="afterServiceRecord.customerAgreeRedo === 1">
|
|
||||||
<!-- 同意售后并且同意类型需要退货;;重发补发以及重发方案为需要退货 -->
|
|
||||||
<view class='cu-tag bg-main-color radius light' v-if="(afterServiceRecord.workerFeedbackResult === 1 && (afterServiceRecord.workerAgreeType == 2 || afterServiceRecord.workerAgreeType == 3 || afterServiceRecord.workerAgreeType == 4)) || ((afterServiceRecord.workerFeedbackResult === 2 || afterServiceRecord.workerFeedbackResult === 3) && (afterServiceRecord.workerResendPlan === 2 || afterServiceRecord.workerResendPlan === 3 || afterServiceRecord.workerResendPlan === 4))">客户反馈未收货,货在途</view>
|
|
||||||
<view class='cu-tag bg-main-color radius light' v-else>客户同意方案</view>
|
|
||||||
</view>
|
|
||||||
|
|
||||||
<template v-if="afterServiceRecord.returnType">
|
|
||||||
<view class="margin-top-xs">
|
|
||||||
<text>客户已退货:</text>
|
|
||||||
</view>
|
|
||||||
<view class="flex justify-between align-center">
|
|
||||||
<text>发货方式:{{afterServiceRecord.returnType == 1 ? '发快递/物流': (afterServiceRecord.returnType == 2 ? '送货上门' : '客户自提')}}</text>
|
|
||||||
<text v-if="afterServiceRecord.returnType == 1" @click="copyData(afterServiceRecord.returnTrackingNumber)">{{afterServiceRecord.returnTrackingNumber}}<text class="cuIcon-copy"></text><text class="text-main-color margin-left-sm" @click.stop="getDeliveryFlow(afterServiceRecord.returnTrackingNumber)">查询</text></text>
|
|
||||||
</view>
|
|
||||||
<view class="grid col-3 grid-square flex-sub margin-top-sm" v-if="afterServiceRecord.returnImages">
|
|
||||||
<view class="bg-img" v-for="(imgUrl, imgIndex) in afterServiceRecord.returnImages.split(',')" :key="imgIndex">
|
|
||||||
<image :src="imgUrl" @tap="viewImage($event, [imgUrl])" :data-url="imgUrl" mode="aspectFill"></image>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="margin-bottom-xs" v-if="afterServiceRecord.returnRemark">
|
|
||||||
<text>发货备注:{{afterServiceRecord.returnRemark}}</text>
|
|
||||||
</view>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<template v-if="afterServiceRecord.workerFeedbackResult === 3 && afterServiceRecord.workerResendType">
|
|
||||||
<view class="margin-top-xs">
|
|
||||||
<text>商家重发/补发提交:</text>
|
|
||||||
</view>
|
|
||||||
<view class="flex justify-between align-center">
|
|
||||||
<text>发货方式:{{afterServiceRecord.workerResendType == 1 ? '发快递/物流': (afterServiceRecord.workerResendType == 2 ? '送货上门' : '客户自提')}}</text>
|
|
||||||
<text v-if="afterServiceRecord.workerResendType == 1" @click="copyData(afterServiceRecord.workerResendTrackingNumber)">{{afterServiceRecord.workerResendTrackingNumber}}<text class="cuIcon-copy"></text></text>
|
|
||||||
</view>
|
|
||||||
<view class="grid col-3 grid-square flex-sub margin-top-sm" v-if="afterServiceRecord.workerResendImages">
|
|
||||||
<view class="bg-img" v-for="(imgUrl, imgIndex) in afterServiceRecord.workerResendImages.split(',')" :key="imgIndex">
|
|
||||||
<image :src="imgUrl" @tap="viewImage($event, [imgUrl])" :data-url="imgUrl" mode="aspectFill"></image>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="margin-bottom-xs" v-if="afterServiceRecord.workerResendRemark">
|
|
||||||
<text>发货备注:{{afterServiceRecord.workerResendRemark}}</text>
|
|
||||||
</view>
|
|
||||||
</template>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
|
|
||||||
<view style="border-top: 1px solid gainsboro;padding-top: 10upx;" v-if="afterServiceRecord.customerFinalCheck == null && afterServiceRecord.workerResendType">
|
|
||||||
<view v-if="afterServiceRecord.workerResendType == 1">
|
|
||||||
<text class="text-gray" style="font-size: 20upx;">待客户验收或审核,4天内未操作将自动完成本次售后!</text>
|
|
||||||
<view class="flex align-center margin-top-sm">
|
|
||||||
<text>操作时限:</text>
|
|
||||||
<uni-countdown :show-colon="false" :backgroundColor="'#eee'"
|
|
||||||
:day="$dateUtil.countDownDiff($dateUtil.addDays(afterServiceRecord.workerResendTime, 4)).day"
|
|
||||||
:hour="$dateUtil.countDownDiff($dateUtil.addDays(afterServiceRecord.workerResendTime, 4)).hour"
|
|
||||||
:minute="$dateUtil.countDownDiff($dateUtil.addDays(afterServiceRecord.workerResendTime, 4)).min"
|
|
||||||
:second="$dateUtil.countDownDiff($dateUtil.addDays(afterServiceRecord.workerResendTime, 4)).seconds">
|
|
||||||
</uni-countdown>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view v-else>
|
|
||||||
<text class="text-gray" style="font-size: 20upx;">待客户验收或审核,24小时未操作将自动同意本售后!</text>
|
|
||||||
<view class="flex align-center margin-top-sm">
|
|
||||||
<text>操作时限:</text>
|
|
||||||
<uni-countdown :show-colon="false" :backgroundColor="'#eee'"
|
|
||||||
:day="$dateUtil.countDownDiff($dateUtil.addHours(afterServiceRecord.workerResendTime, 24)).day"
|
|
||||||
:hour="$dateUtil.countDownDiff($dateUtil.addHours(afterServiceRecord.workerResendTime, 24)).hour"
|
|
||||||
:minute="$dateUtil.countDownDiff($dateUtil.addHours(afterServiceRecord.workerResendTime, 24)).min"
|
|
||||||
:second="$dateUtil.countDownDiff($dateUtil.addHours(afterServiceRecord.workerResendTime, 24)).seconds">
|
|
||||||
</uni-countdown>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
|
|
||||||
<view style="border-top: 1px solid gainsboro;padding-top: 10upx;" v-if="afterServiceRecord.customerFinalCheck == null && (afterServiceRecord.workerFeedbackResult === 0 || afterServiceRecord.workerFeedbackResult === 1 || afterServiceRecord.workerFeedbackResult === 3 || (afterServiceRecord.workerFeedbackResult === 2 && (afterServiceRecord.workerResendPlan === 2 || afterServiceRecord.workerResendPlan === 3)))">
|
|
||||||
<template v-if="afterServiceRecord.workerFeedbackResult === 1 && afterServiceRecord.customerOperationTime">
|
|
||||||
<text class="text-gray" style="font-size: 20upx;">您需跟踪客户退货或物流返货,收到后第一时间操作“结单”键退款!</text>
|
|
||||||
<view class="flex align-center margin-top-sm">
|
|
||||||
<text>工单时限:</text>
|
|
||||||
<uni-countdown :show-colon="false" :backgroundColor="'#eee'"
|
|
||||||
:day="$dateUtil.countDownDiff($dateUtil.addDays(afterServiceRecord.customerOperationTime, 6)).day"
|
|
||||||
:hour="$dateUtil.countDownDiff($dateUtil.addDays(afterServiceRecord.customerOperationTime, 6)).hour"
|
|
||||||
:minute="$dateUtil.countDownDiff($dateUtil.addDays(afterServiceRecord.customerOperationTime, 6)).min"
|
|
||||||
:second="$dateUtil.countDownDiff($dateUtil.addDays(afterServiceRecord.customerOperationTime, 6)).seconds">
|
|
||||||
</uni-countdown>
|
|
||||||
</view>
|
|
||||||
</template>
|
|
||||||
<template v-if="afterServiceRecord.workerFeedbackResult === 2 && afterServiceRecord.workerResendPlanTime">
|
|
||||||
<text class="text-gray" style="font-size: 20upx;">待客户验收或审核,36小时未操作将自动取消本次售后</text>
|
|
||||||
<view class="flex align-center margin-top-sm">
|
|
||||||
<text>工单时限:</text>
|
|
||||||
<uni-countdown :show-colon="false" :backgroundColor="'#eee'"
|
|
||||||
:day="$dateUtil.countDownDiff($dateUtil.addHours(afterServiceRecord.workerResendPlanTime, 36)).day"
|
|
||||||
:hour="$dateUtil.countDownDiff($dateUtil.addHours(afterServiceRecord.workerResendPlanTime, 36)).hour"
|
|
||||||
:minute="$dateUtil.countDownDiff($dateUtil.addHours(afterServiceRecord.workerResendPlanTime, 36)).min"
|
|
||||||
:second="$dateUtil.countDownDiff($dateUtil.addHours(afterServiceRecord.workerResendPlanTime, 36)).seconds">
|
|
||||||
</uni-countdown>
|
|
||||||
</view>
|
|
||||||
</template>
|
|
||||||
<template v-else-if="afterServiceRecord.redoCompleteTime">
|
|
||||||
<text class="text-gray" style="font-size: 20upx;">待客户验收或审核,36小时未操作将自动取消本次售后</text>
|
|
||||||
<view class="flex align-center margin-top-sm">
|
|
||||||
<text>工单时限:</text>
|
|
||||||
<uni-countdown :show-colon="false" :backgroundColor="'#eee'"
|
|
||||||
:day="$dateUtil.countDownDiff($dateUtil.addHours(afterServiceRecord.redoCompleteTime, 36)).day"
|
|
||||||
:hour="$dateUtil.countDownDiff($dateUtil.addHours(afterServiceRecord.redoCompleteTime, 36)).hour"
|
|
||||||
:minute="$dateUtil.countDownDiff($dateUtil.addHours(afterServiceRecord.redoCompleteTime, 36)).min"
|
|
||||||
:second="$dateUtil.countDownDiff($dateUtil.addHours(afterServiceRecord.redoCompleteTime, 36)).seconds">
|
|
||||||
</uni-countdown>
|
|
||||||
</view>
|
|
||||||
</template>
|
|
||||||
</view>
|
|
||||||
|
|
||||||
<!-- <view class="flex justify-end align-end margin-tb-sm" v-if="afterServiceRecord.workerFeedbackResult === 2">
|
|
||||||
<button class="cu-btn sm bg-yellow margin-right-sm" data-modal="showDeliverGoods" @tap="showModal($event, order)">立即重发/补发</button>
|
|
||||||
</view> -->
|
|
||||||
<template v-if="afterServiceRecord.customerFinalCheck === null">
|
|
||||||
<view class="flex justify-end align-end margin-tb-sm" v-if="afterServiceRecord.workerFeedbackResult === 2 && showActionBtn">
|
|
||||||
<button class="cu-btn sm bg-yellow margin-right-sm" @tap="$emit('callModal', 'showDeliverGoods')">立即重发/补发</button>
|
|
||||||
</view>
|
|
||||||
<view class="flex justify-end align-end margin-tb-sm" v-if="afterServiceRecord.workerFeedbackResult === 1 && (afterServiceRecord.workerAgreeType == 2 || afterServiceRecord.workerAgreeType == 3 || afterServiceRecord.workerAgreeType == 4) && afterServiceRecord.workerReceiveStatus != 3 && showActionBtn">
|
|
||||||
<button class="cu-btn sm bg-yellow margin-right-sm" @tap="workerReceived">货已收到,结单</button>
|
|
||||||
</view>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
|
|
||||||
<view v-if="afterServiceRecord.customerFinalCheck != null" class="padding-tb solid-top">
|
|
||||||
<template v-if="order.afterPlatformServiceStatus === 0 || order.afterPlatformServiceStatus == 1">
|
|
||||||
<view class='cu-tag bg-main-color radius light'>{{afterServiceRecord.workerReceiveConfirm === 1 ? '商家确认' : '客户最终确认'}}</view>
|
|
||||||
<view class="margin-top-xs" v-if="afterServiceRecord.workerReceiveConfirm === 1">
|
|
||||||
<view>已收货,结单</view>
|
|
||||||
<view>本单已退货并结束售后!</view>
|
|
||||||
</view>
|
|
||||||
<template v-else>
|
|
||||||
<view class="margin-top-xs" v-if="afterServiceRecord.customerFinalCheck === 2">
|
|
||||||
取消
|
|
||||||
<text v-if="afterServiceRecord.isAutoProcessed == 1">(超时系统自动取消)</text>
|
|
||||||
</view>
|
|
||||||
<view class="margin-top-xs" v-else>
|
|
||||||
{{afterServiceRecord.customerFinalCheck === 1 ? '同意' : '不同意'}}
|
|
||||||
<text v-if="afterServiceRecord.isAutoProcessed == 1 && afterServiceRecord.customerFinalCheck === 1">(超时系统自动同意)</text>
|
|
||||||
</view>
|
|
||||||
</template>
|
|
||||||
<view v-if="afterServiceRecord.customerFinalCheck === 0">
|
|
||||||
<view class="grid col-3 grid-square flex-sub margin-top-sm" v-if="afterServiceRecord.customerDisagreeImages">
|
|
||||||
<view class="bg-img" v-for="imgUrl in afterServiceRecord.customerDisagreeImages.split(',')" :key="imgUrl">
|
|
||||||
<image :src="imgUrl" @tap="viewImage($event, [imgUrl])" :data-url="imgUrl" mode="aspectFill"></image>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="margin-bottom-xs" v-if="afterServiceRecord.customerDisagreeReason">
|
|
||||||
<text>不同意理由:{{afterServiceRecord.customerDisagreeReason}}</text>
|
|
||||||
</view>
|
|
||||||
<view class="text-red" v-if="afterServiceRecord.customerFinalCheck === 0">订单交由平台协商处理</view>
|
|
||||||
<view v-if="afterServiceRecord.customerFinalCheck === 0">
|
|
||||||
系统提示您,如能协商尽可能与客户协商一致(能重新协商则按双方认可方案重新发起)!可让客户撤单最佳(售后内已重新发货的则客户无法操作撤单)!
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view v-else-if="afterServiceRecord.customerFinalCheck === 1">
|
|
||||||
<template v-if="afterServiceRecord.workerFeedbackResult !== 0">
|
|
||||||
<view v-if="(afterServiceRecord.agreedRefund > 0 || afterServiceRecord.originalRefund > 0) && order.refundPayStatus == 1">
|
|
||||||
<view>
|
|
||||||
<text>本单退款,系统已发起按客户支付的帐户原路退回</text>
|
|
||||||
<text class="text-red">{{afterServiceRecord.originalRefund || afterServiceRecord.agreedRefund}}</text>
|
|
||||||
<text>元,银行按工作日退款,节假日顺延到帐。遇客户问询,请其耐心等待,到账时会在客户端”客户最终确认“处有到账时间。</text>
|
|
||||||
</view>
|
|
||||||
<view>退款支付到账:{{afterServiceRecord.refundApplyTime}}</view>
|
|
||||||
</view>
|
|
||||||
<view v-else-if="order.refundPayStatus == 0">
|
|
||||||
<text v-if="afterServiceRecord.workerFeedbackResult === 3">{{order.orderType == 1 ? '本次售后已重发/补发并验收完成(退款为0)' : '本次售后已重新补做并验收完成(退款额为0)。'}}</text>
|
|
||||||
<text v-else>本单已退款<text class="text-red">{{afterServiceRecord.originalRefund || afterServiceRecord.agreedRefund || 0}}</text>元,因未实际支付,实退为0元。未退部分继续完成订单及正常支付!</text>
|
|
||||||
</view>
|
|
||||||
</template>
|
|
||||||
<view v-else>
|
|
||||||
<text>本次售后已操作完毕,售后申请已结束!</text>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</template>
|
|
||||||
<template v-else-if="order.afterPlatformServiceStatus === 2 || order.afterPlatformServiceStatus === 3">
|
|
||||||
<view class='cu-tag bg-main-color radius light'>客户最终确认</view>
|
|
||||||
<view class="margin-top-xs">
|
|
||||||
{{order.afterPlatformServiceStatus === 2 ? '同意' : '取消售后'}}
|
|
||||||
(平台操作)
|
|
||||||
</view>
|
|
||||||
<view v-if="afterServiceRecord.platformHandleReason">
|
|
||||||
<text>平台意见:{{afterServiceRecord.platformHandleReason}}</text>
|
|
||||||
</view>
|
|
||||||
<view v-if="order.afterPlatformServiceStatus === 3">
|
|
||||||
<text>本次售后已操作完毕,售后申请已结束!</text>
|
|
||||||
</view>
|
|
||||||
<template v-else>
|
|
||||||
<view v-if="(afterServiceRecord.platformRefund || afterServiceRecord.agreedRefund) && order.refundPayStatus == 1">
|
|
||||||
<view>
|
|
||||||
<text>本单退款,系统已发起按客户支付的帐户原路退回</text>
|
|
||||||
<text class="text-red">{{afterServiceRecord.platformRefund || afterServiceRecord.agreedRefund}}</text>
|
|
||||||
<text>元,银行按工作日退款,节假日顺延到帐。遇客户问询,请其耐心等待,到账时会在客户端”客户最终确认“处有到账时间。</text>
|
|
||||||
</view>
|
|
||||||
<view>退款支付到账:{{afterServiceRecord.refundApplyTime}}</view>
|
|
||||||
</view>
|
|
||||||
<view v-else-if="order.refundPayStatus == 0">
|
|
||||||
<text>本单已退款<text class="text-red">{{afterServiceRecord.platformRefund || afterServiceRecord.agreedRefund || 0}}</text>元,因未实际支付,实退为0元。未退部分继续完成订单及正常支付!</text>
|
|
||||||
</view>
|
|
||||||
</template>
|
|
||||||
</template>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<script>
|
|
||||||
export default {
|
|
||||||
props: {
|
|
||||||
afterServiceRecord: {
|
|
||||||
type: Object,
|
|
||||||
default: () => {}
|
|
||||||
},
|
|
||||||
order: {
|
|
||||||
type: Object,
|
|
||||||
default: () => {}
|
|
||||||
},
|
|
||||||
showActionBtn: {
|
|
||||||
type: Boolean,
|
|
||||||
default: true
|
|
||||||
}
|
|
||||||
},
|
|
||||||
data() {
|
|
||||||
|
|
||||||
},
|
|
||||||
methods: {
|
|
||||||
viewImage(e, imgList) {
|
|
||||||
uni.previewImage({
|
|
||||||
urls: imgList,
|
|
||||||
current: e.currentTarget.dataset.url
|
|
||||||
});
|
|
||||||
},
|
|
||||||
copyData(data) {
|
|
||||||
uni.setClipboardData({
|
|
||||||
data: data,
|
|
||||||
success() {
|
|
||||||
uni.showToast({
|
|
||||||
title: '复制成功'
|
|
||||||
})
|
|
||||||
}
|
|
||||||
});
|
|
||||||
},
|
|
||||||
getDeliveryFlow(returnTrackingNumber) {
|
|
||||||
console.log(returnTrackingNumber);
|
|
||||||
this.$emit('getDeliveryFlow', returnTrackingNumber)
|
|
||||||
},
|
|
||||||
workerReceived() {
|
|
||||||
uni.showModal({
|
|
||||||
confirmText: '确认',
|
|
||||||
cancelText: '取消',
|
|
||||||
content: "确认后结束售后单,退款按支付原路退回,退款额最大按本单商品金额为限,存在退额不足且未满足客户诉求的将由您与您的派单公司按订单总额另行与客户对接后再结单!",
|
|
||||||
success: async (res) => {
|
|
||||||
if(res.confirm) {
|
|
||||||
await this.$request.workerConfirmReceive({
|
|
||||||
id: this.afterServiceRecord.id
|
|
||||||
})
|
|
||||||
this.$emit('refreshOrderList')
|
|
||||||
}
|
|
||||||
}
|
|
||||||
})
|
|
||||||
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
</script>
|
|
||||||
|
|
||||||
<style>
|
|
||||||
</style>
|
|
||||||
|
|
@ -12,8 +12,7 @@
|
||||||
<view class='cu-tag padding basis-lg'>{{item.goodsName}}</view>
|
<view class='cu-tag padding basis-lg'>{{item.goodsName}}</view>
|
||||||
<view class="flex justify-end basis-df text-center align-center">
|
<view class="flex justify-end basis-df text-center align-center">
|
||||||
<view class="basis-df">{{item.goodsNum}}</view>
|
<view class="basis-df">{{item.goodsNum}}</view>
|
||||||
<view class="basis-df" v-if="orderMode === 'transferOrder'">{{item.goodsNum}}</view>
|
<view class="basis-df">
|
||||||
<view class="basis-df" v-else>
|
|
||||||
<uni-number-box :min="0" :max="item.goodsNum" v-model="item.toAssignNum" @change="changePiecesNum($event, item)">
|
<uni-number-box :min="0" :max="item.goodsNum" v-model="item.toAssignNum" @change="changePiecesNum($event, item)">
|
||||||
</uni-number-box>
|
</uni-number-box>
|
||||||
</view>
|
</view>
|
||||||
|
|
@ -25,7 +24,7 @@
|
||||||
</view>
|
</view>
|
||||||
<view class="padding-bottom-sm flex justify-between align-center">
|
<view class="padding-bottom-sm flex justify-between align-center">
|
||||||
<text class="margin-right-sm" style="width: 150rpx;">派单价格</text>
|
<text class="margin-right-sm" style="width: 150rpx;">派单价格</text>
|
||||||
<input type="digit" class="line-input radius-input" v-model="dispatchTotalPrice" :placeholder="orderMode === 'transferOrder'?'请输入派出总额(转出后在监控单查看)' : '请输入派出总额'"></input>
|
<input type="digit" class="line-input radius-input" v-model="dispatchTotalPrice" placeholder="请输入派出总额"></input>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="solid-top padding-top-sm flex justify-between align-center">
|
<view class="solid-top padding-top-sm flex justify-between align-center">
|
||||||
|
|
@ -36,18 +35,6 @@
|
||||||
</view>
|
</view>
|
||||||
<!-- 可指派成员 -->
|
<!-- 可指派成员 -->
|
||||||
<scroll-view class="certern-height-with-scroll" :scroll-y="true" :scroll-with-animation="true">
|
<scroll-view class="certern-height-with-scroll" :scroll-y="true" :scroll-with-animation="true">
|
||||||
<view v-if="orderMode === 'transferOrder'">
|
|
||||||
<view class="bg-white padding">
|
|
||||||
<view class="flex justify-between align-center">
|
|
||||||
<view class="flex justify-start align-center">
|
|
||||||
<view class="text-lg margin-left-sm">转入大厅</view>
|
|
||||||
</view>
|
|
||||||
<view>
|
|
||||||
<button class="cu-btn bg-main-color shadow-blur" @click="assignTransfer">转大厅</button>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view v-if="searchedMembers && searchedMembers.length > 0">
|
<view v-if="searchedMembers && searchedMembers.length > 0">
|
||||||
<view class="bg-white padding" v-for="(member, index) in searchedMembers">
|
<view class="bg-white padding" v-for="(member, index) in searchedMembers">
|
||||||
<view class="flex justify-between align-center">
|
<view class="flex justify-between align-center">
|
||||||
|
|
@ -128,10 +115,6 @@
|
||||||
orderNow: {
|
orderNow: {
|
||||||
type: Boolean,
|
type: Boolean,
|
||||||
default: false
|
default: false
|
||||||
},
|
|
||||||
orderMode: {
|
|
||||||
type: String,
|
|
||||||
default: ''
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
|
|
@ -188,36 +171,7 @@
|
||||||
});
|
});
|
||||||
this.searchedMembers = res.rows;
|
this.searchedMembers = res.rows;
|
||||||
},
|
},
|
||||||
assignTransfer(member) {
|
|
||||||
let goodsToAssign = [];
|
|
||||||
this.pickedList.forEach((item) => {
|
|
||||||
goodsToAssign.push({
|
|
||||||
goodsStandardId: item.goodsStandardId,
|
|
||||||
num: item.goodsNum
|
|
||||||
})
|
|
||||||
});
|
|
||||||
if (this.dispatchTotalPrice) {
|
|
||||||
let params = {
|
|
||||||
goodsList: goodsToAssign,
|
|
||||||
workerId: member ? member.workerId : null,
|
|
||||||
totalPay: this.dispatchTotalPrice,
|
|
||||||
orderMasterId: this.curOrder.orderMasterId,
|
|
||||||
isAll: 1,
|
|
||||||
workerName: member ? member.workerName : null
|
|
||||||
}
|
|
||||||
this.$emit('assignWork', params);
|
|
||||||
} else {
|
|
||||||
uni.showToast({
|
|
||||||
title: '请填写派单价格',
|
|
||||||
icon: 'none'
|
|
||||||
})
|
|
||||||
}
|
|
||||||
},
|
|
||||||
assignWork(member) {
|
assignWork(member) {
|
||||||
if(this.orderMode === 'transferOrder') {
|
|
||||||
this.assignTransfer(member)
|
|
||||||
return
|
|
||||||
}
|
|
||||||
let goodsToAssign = [];
|
let goodsToAssign = [];
|
||||||
// 标识是否派完所有goods,1为派完,0为未派完
|
// 标识是否派完所有goods,1为派完,0为未派完
|
||||||
let isAll = 1;
|
let isAll = 1;
|
||||||
|
|
@ -239,8 +193,7 @@
|
||||||
workerId: member.workerId,
|
workerId: member.workerId,
|
||||||
totalPay: this.dispatchTotalPrice,
|
totalPay: this.dispatchTotalPrice,
|
||||||
orderMasterId: this.curOrder.orderMasterId,
|
orderMasterId: this.curOrder.orderMasterId,
|
||||||
isAll: isAll,
|
isAll: isAll
|
||||||
workerName: member.workerName || member.name
|
|
||||||
}
|
}
|
||||||
this.$emit('assignWork', params);
|
this.$emit('assignWork', params);
|
||||||
} else {
|
} else {
|
||||||
|
|
|
||||||
|
|
@ -21,7 +21,7 @@
|
||||||
<view class="margin-top-sm bg-white padding">
|
<view class="margin-top-sm bg-white padding">
|
||||||
<!-- 服务指标 -->
|
<!-- 服务指标 -->
|
||||||
<checkbox-group class="block" @change="changeServIndexChecked">
|
<checkbox-group class="block" @change="changeServIndexChecked">
|
||||||
<view style="min-width: 50%;" class="flex justify-start align-center margin-top-sm float-left" v-for="(item, index) in servIndex" :key="index">
|
<view style="min-width: 50%;" class="flex justify-start align-center margin-top-sm float-left" v-for="(item, index) in servIndex">
|
||||||
<checkbox style="transform:scale(1)" class="main-color margin-right-xs" :value="item.code">
|
<checkbox style="transform:scale(1)" class="main-color margin-right-xs" :value="item.code">
|
||||||
</checkbox>
|
</checkbox>
|
||||||
<text class="text-sm">{{item.desc}}</text>
|
<text class="text-sm">{{item.desc}}</text>
|
||||||
|
|
@ -96,9 +96,8 @@
|
||||||
this.order = orderInfo;
|
this.order = orderInfo;
|
||||||
},
|
},
|
||||||
chooseImgList(e, imgList) {
|
chooseImgList(e, imgList) {
|
||||||
uni.chooseMedia({
|
uni.chooseImage({
|
||||||
count: 12 - imgList.length, //默认9
|
count: 12 - imgList.length, //默认9
|
||||||
mediaType: ['image'],
|
|
||||||
sizeType: ['original', 'compressed'], //可以指定是原图还是压缩图,默认二者都有
|
sizeType: ['original', 'compressed'], //可以指定是原图还是压缩图,默认二者都有
|
||||||
sourceType: ['album'], //从相册选择
|
sourceType: ['album'], //从相册选择
|
||||||
success: (res) => {
|
success: (res) => {
|
||||||
|
|
@ -106,10 +105,10 @@
|
||||||
title: '上传中',
|
title: '上传中',
|
||||||
mask: true
|
mask: true
|
||||||
});
|
});
|
||||||
res.tempFiles.forEach((fileObj, index) => {
|
res.tempFilePaths.forEach((tmpUrl, index) => {
|
||||||
this.$request.uploadFile(fileObj.tempFilePath).then((url) => {
|
this.$request.uploadFile(tmpUrl).then((url) => {
|
||||||
imgList.push(url);
|
imgList.push(url);
|
||||||
if (index === res.tempFiles.length - 1) {
|
if (index === res.tempFilePaths.length - 1) {
|
||||||
uni.hideLoading();
|
uni.hideLoading();
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
@ -152,11 +151,6 @@
|
||||||
}
|
}
|
||||||
return true;
|
return true;
|
||||||
},
|
},
|
||||||
// 添加操作节点
|
|
||||||
async addOrderOperate(params = {}) {
|
|
||||||
let res = await this.$request.addOrderOperate(params);
|
|
||||||
return res;
|
|
||||||
},
|
|
||||||
async finishOrder() {
|
async finishOrder() {
|
||||||
if (!this.validData()) {
|
if (!this.validData()) {
|
||||||
return;
|
return;
|
||||||
|
|
@ -174,13 +168,10 @@
|
||||||
title: '提交成功',
|
title: '提交成功',
|
||||||
duration: 1500
|
duration: 1500
|
||||||
})
|
})
|
||||||
this.addOrderOperate({
|
|
||||||
orderId: this.order.orderDetailId,
|
|
||||||
orderType: '02',
|
|
||||||
content: '师傅完工'
|
|
||||||
})
|
|
||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
uni.navigateBack()
|
uni.navigateTo({
|
||||||
|
url: '/pages/order-manage/order-manage?tabCur=3'
|
||||||
|
})
|
||||||
}, 1500);
|
}, 1500);
|
||||||
} else if (res && res.msg) {
|
} else if (res && res.msg) {
|
||||||
uni.showToast({
|
uni.showToast({
|
||||||
|
|
|
||||||
|
|
@ -6,15 +6,8 @@
|
||||||
<view class="padding-xl">
|
<view class="padding-xl">
|
||||||
<view class="cuIcon-roundcheck big-icon padding-tb text-main-color"></view>
|
<view class="cuIcon-roundcheck big-icon padding-tb text-main-color"></view>
|
||||||
<view class="text-bold text-lg margin-bottom-sm">接单成功</view>
|
<view class="text-bold text-lg margin-bottom-sm">接单成功</view>
|
||||||
<template v-if="data.orderType == 1">
|
|
||||||
<view v-if="data.payType == 0">接单成功,请在30分钟内发货或排发货时间,超时3倍未排可能被平台处罚,该订单款项在流程结束后将由银联自动结算至你帐户。</view>
|
|
||||||
<view v-else-if="data.payType == 1">接单成功,货到付款单,交货时按单内二维码收款或客户在其帐户端支付。接单后请在请在30分钟内发货或排发货时间,超时3倍未排可能被平台处罚,该订单款项在流程结束后将由银联自动结算至你帐户。</view>
|
|
||||||
</template>
|
|
||||||
<template v-else>
|
|
||||||
<view v-if="data.payType == 0">请在30分钟内联系客户,预约好上门时间,并在订单中操作排单时间,超时6倍将受平台处罚管理;该订单款项在任务流程结束后由银联自动结算至您帐户! </view>
|
<view v-if="data.payType == 0">请在30分钟内联系客户,预约好上门时间,并在订单中操作排单时间,超时6倍将受平台处罚管理;该订单款项在任务流程结束后由银联自动结算至您帐户! </view>
|
||||||
<view v-else-if="data.payType == 1">该单需上门收款。请在30分钟内联系客户,并告知客户属上门收款单(金额以客户端弹出的金额为准或上门后师傅端弹出的二维码内金额支付)预约好上门时间,并在订单中操作排单时间,超时6倍将受平台处罚管理;该订单款项在任务流程结束后由银联自动结算至您帐户! </view>
|
<view v-else-if="data.payType == 1">该单需上门收款。请在30分钟内联系客户,并告知客户属上门收款单(金额以客户端弹出的金额为准或上门后师傅端弹出的二维码内金额支付)预约好上门时间,并在订单中操作排单时间,超时6倍将受平台处罚管理;该订单款项在任务流程结束后由银联自动结算至您帐户! </view>
|
||||||
</template>
|
|
||||||
|
|
||||||
</view>
|
</view>
|
||||||
<view class="cu-bar bg-white solid-top">
|
<view class="cu-bar bg-white solid-top">
|
||||||
<view class="action margin-0 flex-sub text-main-color" data-modal="showAcceptOrderNoticeModal"
|
<view class="action margin-0 flex-sub text-main-color" data-modal="showAcceptOrderNoticeModal"
|
||||||
|
|
@ -30,7 +23,7 @@
|
||||||
<script>
|
<script>
|
||||||
export default {
|
export default {
|
||||||
name: 'acceptOrderNotice',
|
name: 'acceptOrderNotice',
|
||||||
emits: ['confirmFeedback', 'close'],
|
emits: ['confirmFeedback'],
|
||||||
props: {
|
props: {
|
||||||
show: {
|
show: {
|
||||||
type: Boolean,
|
type: Boolean,
|
||||||
|
|
@ -38,7 +31,7 @@
|
||||||
},
|
},
|
||||||
data: {
|
data: {
|
||||||
type: Object,
|
type: Object,
|
||||||
default: () => {}
|
default: {}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
|
|
@ -46,8 +39,8 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
hideModal() {
|
hideModal(e) {
|
||||||
this.$emit('close');
|
uni.$emit(this.$globalFun.HIDE_MODAL, e);
|
||||||
},
|
},
|
||||||
contactCustomer(e) {
|
contactCustomer(e) {
|
||||||
this.hideModal(e);
|
this.hideModal(e);
|
||||||
|
|
|
||||||
|
|
@ -1,240 +0,0 @@
|
||||||
<template>
|
|
||||||
<view class="cu-modal" :class="show?'show':''">
|
|
||||||
<view class="cu-dialog bg-white">
|
|
||||||
<view class="cu-bar">
|
|
||||||
<view class="content">同意售后</view>
|
|
||||||
<view class="action" data-modal="agreeAfterSale" @click="hideModal">
|
|
||||||
<text class="cuIcon-close text-red"></text>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="padding text-left">
|
|
||||||
<view class="text-lg">
|
|
||||||
<text>退款金额:</text>
|
|
||||||
<text class="text-price text-red">{{data.afterServiceRecordList[0].refund ? data.afterServiceRecordList[0].refund : data.payMoney}}</text>
|
|
||||||
</view>
|
|
||||||
<view v-if="!data.isOnlyServ && data.afterServiceRecordList[0].refund && data.payMoney < data.afterServiceRecordList[0].refund" class="padding-top text-red">
|
|
||||||
警报:该单关联其它订单,客户申请的退款金额有效,有疑问可先沟通派单公司(详情处电话),如确认同意,最大退款额以本单接单额原路退回,其余需退的或你仍有收益则由派单公司处理,如更改退单额,需先协商一致,余额部分完单后计入你账户。
|
|
||||||
</view>
|
|
||||||
<view class="flex justify-start align-center margin-top-sm">
|
|
||||||
<view class="title">收货状态:</view>
|
|
||||||
<my-uni-combox class="form-val-area inline-input" :candidates="workerReceiveStatusArr" placeholder="请选择" :showField="'name'"
|
|
||||||
v-model="workerReceiveStatus">
|
|
||||||
</my-uni-combox>
|
|
||||||
</view>
|
|
||||||
<view class="flex justify-start align-center margin-top-sm">
|
|
||||||
<view class="title">同意选项:</view>
|
|
||||||
<my-uni-combox class="form-val-area inline-input" :candidates="workerAgreeTypeArr" placeholder="请选择" :showField="'name'"
|
|
||||||
v-model="workerAgreeType">
|
|
||||||
</my-uni-combox>
|
|
||||||
</view>
|
|
||||||
<view class="text-lg padding-top flex justify-start align-center">
|
|
||||||
<text>更改退款金额:</text>
|
|
||||||
<input type="digit" class="radius-input inline-input" style="flex-basis:25%" v-model="agreedRefund"></input>
|
|
||||||
<text class="margin-left-xs">元</text>
|
|
||||||
</view>
|
|
||||||
<view class="padding-top">
|
|
||||||
<view class="flex justify-start">
|
|
||||||
<view>原因选择:</view>
|
|
||||||
<radio-group @change="changeReasonRadio">
|
|
||||||
<label class="radio margin-right-sm">
|
|
||||||
<radio style="transform:scale(0.7)" class="main-color" :value="1" :checked="data.reasonType === 1"/>
|
|
||||||
<text>客户原因</text>
|
|
||||||
</label>
|
|
||||||
<label class="radio">
|
|
||||||
<radio style="transform:scale(0.7)" class="main-color" :value="2" :checked="data.reasonType === 2"/>
|
|
||||||
<text>师傅原因</text>
|
|
||||||
</label>
|
|
||||||
<label class="radio">
|
|
||||||
<radio style="transform:scale(0.7)" class="main-color" :value="3" :checked="data.reasonType === 3"/>
|
|
||||||
<text>其他</text>
|
|
||||||
</label>
|
|
||||||
</radio-group>
|
|
||||||
</view>
|
|
||||||
<view class="margin-top">
|
|
||||||
<textarea style="width: 100%; height: 200rpx;" fixed="true" class="solid radius text-left padding-sm"
|
|
||||||
v-model="remark" maxlength="-1"
|
|
||||||
placeholder="请输入同意原因或更改金额原因(更改退单金额需与客户协商一致,或请订单详情处“派单公司”介入,否则可能被拒绝或引起客诉升级)"></textarea>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="cu-bar solid-top">
|
|
||||||
<view class="action margin-0 flex-sub text-black" data-modal="agreeAfterSale" @click="hideModal">取消</view>
|
|
||||||
<view class="action margin-0 flex-sub text-main-color solid-left" data-modal="agreeAfterSale"
|
|
||||||
@click="showNotice">确认</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
|
|
||||||
<confirm-modal ref="notice" :content="'本单款项银联确认已发起支付,款项已到达或即将到达您所绑定帐户,需退款的同意后您线下与客户操作退款,系统无法提供原路返回退款!'" :confirmMsg="'同意'" @confirm="noticeConfirm" @cancel="noticeCancel"></confirm-modal>
|
|
||||||
</view>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<script>
|
|
||||||
import myUniCombox from '@/components/uni-combox/my-uni-combox.vue';
|
|
||||||
export default {
|
|
||||||
name: 'agreeAfterSale',
|
|
||||||
components: {
|
|
||||||
myUniCombox
|
|
||||||
},
|
|
||||||
props: {
|
|
||||||
show: {
|
|
||||||
type: Boolean,
|
|
||||||
default: false
|
|
||||||
},
|
|
||||||
data: {
|
|
||||||
type: Object,
|
|
||||||
default: () => {}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
data() {
|
|
||||||
return {
|
|
||||||
agreedRefund: null,
|
|
||||||
reasonType: null,
|
|
||||||
remark: null,
|
|
||||||
workerReceiveStatus: null,
|
|
||||||
workerAgreeType: null,
|
|
||||||
workerReceiveStatusArr: [
|
|
||||||
{
|
|
||||||
code: 1,
|
|
||||||
name: '未发货'
|
|
||||||
},
|
|
||||||
{
|
|
||||||
code: 2,
|
|
||||||
name: '已发货在途'
|
|
||||||
},
|
|
||||||
{
|
|
||||||
code: 3,
|
|
||||||
name: '已收货'
|
|
||||||
},
|
|
||||||
{
|
|
||||||
code: 4,
|
|
||||||
name: '售后保障期'
|
|
||||||
},
|
|
||||||
],
|
|
||||||
workerAgreeTypeArr: [
|
|
||||||
{
|
|
||||||
code: 1,
|
|
||||||
name: '同意即时退单退款'
|
|
||||||
},
|
|
||||||
{
|
|
||||||
code: 2,
|
|
||||||
name: '同意货物拦截后退单退款'
|
|
||||||
},
|
|
||||||
{
|
|
||||||
code: 3,
|
|
||||||
name: '同意快递返回货物后退单退款'
|
|
||||||
},
|
|
||||||
{
|
|
||||||
code: 4,
|
|
||||||
name: '同意您退回货物后退单退款'
|
|
||||||
}
|
|
||||||
]
|
|
||||||
}
|
|
||||||
},
|
|
||||||
methods: {
|
|
||||||
hideModal(e) {
|
|
||||||
this.resetData();
|
|
||||||
this.$emit('close', e);
|
|
||||||
},
|
|
||||||
resetData() {
|
|
||||||
// this.data = null;
|
|
||||||
this.agreedRefund = null;
|
|
||||||
this.reasonType = null;
|
|
||||||
this.remark = null;
|
|
||||||
this.workerReceiveStatus = null;
|
|
||||||
this.workerAgreeType = null;
|
|
||||||
},
|
|
||||||
changeReasonRadio(e) {
|
|
||||||
this.reasonType = e.detail.value;
|
|
||||||
},
|
|
||||||
showNotice(e) {
|
|
||||||
if (this.data.drawCashStatus != null && this.data.drawCashStatus >= 1) {
|
|
||||||
this.$refs.notice.showModal();
|
|
||||||
} else {
|
|
||||||
this.submit(e);
|
|
||||||
}
|
|
||||||
},
|
|
||||||
noticeConfirm() {
|
|
||||||
this.submit({
|
|
||||||
currentTarget: {
|
|
||||||
dataset: {
|
|
||||||
modal: 'agreeAfterSale'
|
|
||||||
}
|
|
||||||
}
|
|
||||||
});
|
|
||||||
},
|
|
||||||
noticeCancel() {
|
|
||||||
this.hideModal({
|
|
||||||
currentTarget: {
|
|
||||||
dataset: {
|
|
||||||
modal: 'agreeAfterSale'
|
|
||||||
}
|
|
||||||
}
|
|
||||||
});
|
|
||||||
},
|
|
||||||
async submit(e) {
|
|
||||||
if(!this.workerReceiveStatus) {
|
|
||||||
uni.showToast({
|
|
||||||
title: '请选择收货状态',
|
|
||||||
icon: 'none',
|
|
||||||
duration: 1500
|
|
||||||
})
|
|
||||||
return
|
|
||||||
}
|
|
||||||
if(!this.workerAgreeType) {
|
|
||||||
uni.showToast({
|
|
||||||
title: '请选择同意选项',
|
|
||||||
icon: 'none',
|
|
||||||
duration: 1500
|
|
||||||
})
|
|
||||||
return
|
|
||||||
}
|
|
||||||
let agreedRefund = this.agreedRefund;
|
|
||||||
if (!agreedRefund && this.data.afterServiceRecordList[0].refund != null) {
|
|
||||||
agreedRefund = this.data.afterServiceRecordList[0].refund;
|
|
||||||
} else if (!agreedRefund) {
|
|
||||||
agreedRefund = this.data.payMoney;
|
|
||||||
}
|
|
||||||
console.log({
|
|
||||||
id: this.data.afterServiceRecordList[0].id,
|
|
||||||
workerFeedbackReasonType: this.reasonType,
|
|
||||||
agreedRefund: agreedRefund,
|
|
||||||
workerFeedbackReason: this.remark,
|
|
||||||
workerFeedbackResult: 1,
|
|
||||||
updateBy: 2,
|
|
||||||
workerReceiveStatus: this.workerReceiveStatus.code,
|
|
||||||
workerAgreeType: this.workerAgreeType.code
|
|
||||||
});
|
|
||||||
let res = await this.$request.editAfterServiceGoodsRecord({
|
|
||||||
id: this.data.afterServiceRecordList[0].id,
|
|
||||||
workerFeedbackReasonType: this.reasonType,
|
|
||||||
agreedRefund: agreedRefund,
|
|
||||||
workerFeedbackReason: this.remark,
|
|
||||||
workerFeedbackResult: 1,
|
|
||||||
updateBy: 2,
|
|
||||||
workerReceiveStatus: this.workerReceiveStatus.code,
|
|
||||||
workerAgreeType: this.workerAgreeType.code
|
|
||||||
});
|
|
||||||
if (res && res.code === 0) {
|
|
||||||
uni.showToast({
|
|
||||||
icon: 'success',
|
|
||||||
title: '提交成功',
|
|
||||||
duration: 1000
|
|
||||||
})
|
|
||||||
this.hideModal(e);
|
|
||||||
this.$emit('confirmFeedback');
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
uni.showToast({
|
|
||||||
icon: 'error',
|
|
||||||
duration: 1000,
|
|
||||||
title: '提交失败',
|
|
||||||
})
|
|
||||||
}
|
|
||||||
},
|
|
||||||
}
|
|
||||||
</script>
|
|
||||||
<style scoped>
|
|
||||||
.inline-input {
|
|
||||||
flex-basis: 74%;
|
|
||||||
}
|
|
||||||
</style>
|
|
||||||
|
|
@ -79,7 +79,7 @@
|
||||||
methods: {
|
methods: {
|
||||||
hideModal(e) {
|
hideModal(e) {
|
||||||
this.resetData();
|
this.resetData();
|
||||||
this.$emit('close', e);
|
uni.$emit(this.$globalFun.HIDE_MODAL, e);
|
||||||
},
|
},
|
||||||
resetData() {
|
resetData() {
|
||||||
// this.data = null;
|
// this.data = null;
|
||||||
|
|
|
||||||
|
|
@ -1,129 +0,0 @@
|
||||||
<template>
|
|
||||||
<view class="cu-modal" :class="show?'show':''">
|
|
||||||
<view class="cu-dialog bg-white">
|
|
||||||
<view class="cu-bar">
|
|
||||||
<view class="content">分配服务金额</view>
|
|
||||||
<view class="action" data-modal="agreeAfterSale" @click="hideModal">
|
|
||||||
<text class="cuIcon-close text-red"></text>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="padding text-left">
|
|
||||||
<view class="padding-top">
|
|
||||||
<view class="flex justify-start flex-direction">
|
|
||||||
<view>本单商品已设置包安装/包施工类服务</view>
|
|
||||||
<view>请预置分配安装或服务费/工时费:</view>
|
|
||||||
</view>
|
|
||||||
<view class="margin-top solid radius text-left padding-sm">
|
|
||||||
<input type="digit" style="width: 100%;" placeholder="请输入本单服务费,工时费可撤回或修改" v-model="serviceMoney">
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="cu-bar solid-top">
|
|
||||||
<view class="action margin-0 flex-sub text-black" data-modal="agreeAfterSale" @click="hideModal">关闭/返回查看商品</view>
|
|
||||||
<view class="action margin-0 flex-sub text-main-color solid-left" data-modal="agreeAfterSale"
|
|
||||||
@click="noticeConfirm">继续接单</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
|
|
||||||
<confirm-modal ref="notice" :content="'本单款项银联确认已发起支付,款项已到达或即将到达您所绑定帐户,需退款的同意后您线下与客户操作退款,系统无法提供原路返回退款!'" :confirmMsg="'同意'" @confirm="noticeConfirm" @cancel="noticeCancel"></confirm-modal>
|
|
||||||
</view>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<script>
|
|
||||||
export default {
|
|
||||||
name: 'agreeAfterSale',
|
|
||||||
props: {
|
|
||||||
show: {
|
|
||||||
type: Boolean,
|
|
||||||
default: false
|
|
||||||
},
|
|
||||||
data: {
|
|
||||||
type: Object,
|
|
||||||
default: {}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
data() {
|
|
||||||
return {
|
|
||||||
agreedRefund: null,
|
|
||||||
reasonType: null,
|
|
||||||
remark: null,
|
|
||||||
serviceMoney: null
|
|
||||||
}
|
|
||||||
},
|
|
||||||
methods: {
|
|
||||||
hideModal(e) {
|
|
||||||
this.resetData();
|
|
||||||
this.$emit('close', e);
|
|
||||||
},
|
|
||||||
resetData() {
|
|
||||||
this.serviceMoney = null;
|
|
||||||
},
|
|
||||||
showNotice(e) {
|
|
||||||
if (this.data.drawCashStatus != null && this.data.drawCashStatus >= 1) {
|
|
||||||
this.$refs.notice.showModal();
|
|
||||||
} else {
|
|
||||||
this.submit(e);
|
|
||||||
}
|
|
||||||
},
|
|
||||||
noticeConfirm() {
|
|
||||||
this.submit({
|
|
||||||
currentTarget: {
|
|
||||||
dataset: {
|
|
||||||
modal: 'agreeAfterSale'
|
|
||||||
}
|
|
||||||
}
|
|
||||||
});
|
|
||||||
},
|
|
||||||
noticeCancel() {
|
|
||||||
this.hideModal({
|
|
||||||
currentTarget: {
|
|
||||||
dataset: {
|
|
||||||
modal: 'agreeAfterSale'
|
|
||||||
}
|
|
||||||
}
|
|
||||||
});
|
|
||||||
},
|
|
||||||
async submit(e) {
|
|
||||||
if (!this.serviceMoney) {
|
|
||||||
uni.showToast({
|
|
||||||
title: '请输入本单服务费',
|
|
||||||
icon: 'none'
|
|
||||||
});
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
if(parseFloat(this.serviceMoney) > this.data.serverMoney) {
|
|
||||||
uni.showToast({
|
|
||||||
title: '本单服务费不能大于订单服务金额',
|
|
||||||
icon: 'none'
|
|
||||||
});
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
let res = await this.$request.allocateServiceMoney({
|
|
||||||
id: this.data.orderMasterId,
|
|
||||||
serverGoodsMoney: this.serviceMoney
|
|
||||||
});
|
|
||||||
if (res && res.code === 0) {
|
|
||||||
uni.showToast({
|
|
||||||
icon: 'success',
|
|
||||||
title: '提交成功',
|
|
||||||
duration: 1000
|
|
||||||
})
|
|
||||||
this.hideModal(e);
|
|
||||||
this.$emit('confirmFeedback');
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
uni.showToast({
|
|
||||||
icon: 'error',
|
|
||||||
duration: 1000,
|
|
||||||
title: '提交失败',
|
|
||||||
})
|
|
||||||
}
|
|
||||||
},
|
|
||||||
}
|
|
||||||
</script>
|
|
||||||
|
|
||||||
<style scoped>
|
|
||||||
.inline-input {
|
|
||||||
flex-basis: 25%;
|
|
||||||
}
|
|
||||||
</style>
|
|
||||||
|
|
@ -1,348 +0,0 @@
|
||||||
<template>
|
|
||||||
<view>
|
|
||||||
<view class="cu-modal" :class="show?'show':''">
|
|
||||||
<view class="cu-dialog" style="margin-top: 180rpx;vertical-align: initial;">
|
|
||||||
<view class="cu-bar bg-white justify-end solid-bottom">
|
|
||||||
<view class="content">申请订单加价/预付款</view>
|
|
||||||
<view class="action" data-modal="applyExtraChargeModal" @click="hideModal">
|
|
||||||
<text class="cuIcon-close text-red"></text>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="bg-white padding text-left">
|
|
||||||
<view class="text-lg padding-top flex justify-start align-center">
|
|
||||||
<text class="title-input">加价金额:</text>
|
|
||||||
<input type="digit" class="radius-input inline-input" placeholder="请输入加价总金额" v-model="moneyAmount"></input>
|
|
||||||
</view>
|
|
||||||
<view class="text-lg padding-top flex justify-start align-center">
|
|
||||||
<text class="title-input">加价原因:</text>
|
|
||||||
<picker style="width: 75%;" @change="bindPickerChange" :value="chooseIndex" :range="array">
|
|
||||||
<view class="flex justify-between align-center radius-input inline-input custom-input">
|
|
||||||
<view>{{array[chooseIndex]}}</view>
|
|
||||||
<text class="cuIcon-right"></text>
|
|
||||||
</view>
|
|
||||||
</picker>
|
|
||||||
</view>
|
|
||||||
<view class="text-lg padding-top flex justify-start align-center" v-if="array[chooseIndex].indexOf('含') > -1">
|
|
||||||
<text class="title-input">{{array[chooseIndex].split('含')[1]}}:</text>
|
|
||||||
<input type="digit" class="radius-input inline-input" placeholder="请输入该费用实际金额" v-model="extraAmount"></input>
|
|
||||||
</view>
|
|
||||||
<view>
|
|
||||||
<view class="padding-tb-sm">凭证上传</view>
|
|
||||||
<view class="grid col-3 grid-square">
|
|
||||||
<view class="bg-img" v-for="(item,index) in imgList" :key="index"
|
|
||||||
@tap="viewImage($event, imgList)" :data-url="item">
|
|
||||||
<image :src="item" mode="aspectFill"></image>
|
|
||||||
<view class="cu-tag bg-red" @tap.stop="delImg($event, imgList)" :data-index="index">
|
|
||||||
<text class='cuIcon-close'></text>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="solids" @tap="chooseImage" v-if="imgList.length < 6">
|
|
||||||
<text class='cuIcon-cameraadd'></text>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view>
|
|
||||||
<view class="padding-tb-sm">申请原因</view>
|
|
||||||
<view class="solid">
|
|
||||||
<textarea style="width: 100%; height: 150rpx;" fixed="true" class="radius text-left padding-sm"
|
|
||||||
v-model="remark" maxlength="-1" :placeholder="`请输入理由或备注`"></textarea>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view style="padding-top: 10px;">
|
|
||||||
<view style="font-size: 24rpx;color: #666;white-space: pre-wrap;">
|
|
||||||
加价提示\n1、加价所有费用需经系统支付!加价报价以双方约定输入总价。含配件类物料类的全额到你帐户(银行手续费自付);\n2、申请加价时,客户端仅看到加价总额,总额内的配件类物料类金额与凭证均看不到(网点与商家可见);
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="cu-btn line-main-color margin-top-sm long-btn" v-if="hasReacord" @click="clearCurAddedPrice">
|
|
||||||
清空加价</view>
|
|
||||||
</view>
|
|
||||||
<view class="cu-bar bg-white solid-top">
|
|
||||||
<view class="action margin-0 flex-sub text-black" data-modal="applyChargeModal"
|
|
||||||
@click="hideModal">{{ hasReacord ? '退出/待二次上门' : '取消'}}</view>
|
|
||||||
<view class="action margin-0 flex-sub text-main-color solid-left" data-modal="applyChargeModal" v-if="!hasReacord"
|
|
||||||
@click="submit">确认</view>
|
|
||||||
<view class="action margin-0 flex-sub text-main-color solid-left" data-modal="applyChargeModal" v-else
|
|
||||||
@click="makePayQrcode">请客户支付</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
|
|
||||||
<pay-qrcode ref="payQrcode" :show="showPayQrcodeModal" :data="data" @finishQrPay="finishQrPay"></pay-qrcode>
|
|
||||||
</view>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<script>
|
|
||||||
import payQrcode from '@/pages/order-manage/modal/pay-qrcode.vue';
|
|
||||||
export default {
|
|
||||||
components: {payQrcode},
|
|
||||||
name: 'applyCharge',
|
|
||||||
props: {
|
|
||||||
show: {
|
|
||||||
type: Boolean,
|
|
||||||
default: false
|
|
||||||
},
|
|
||||||
data: {
|
|
||||||
type: Object,
|
|
||||||
default: () => {}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
data() {
|
|
||||||
return {
|
|
||||||
// array: ['加单加价','加急费','拆机/拆换费','搬运费','清理费','远程费','施工费','垫付金','奖励金','质保金','客户押金','工具押金','物品押金'],
|
|
||||||
array: ['加单加价', '加急费', '加时费', '奖励金', '拆机/换机费', '搬运费', '打孔费', '额外服务费', '检查检测费', '清理费', '运输吊装费', '加价含物料费', '加价含垫付金', '加价含配件费', '加价含好评费', '加价含远程费', '加价含高空费', '加价含质保金', '加价含客户押金', '加价含工具押金', '加价含物品押金'],
|
|
||||||
chooseIndex: 0,
|
|
||||||
imgList: [],
|
|
||||||
moneyAmount: '',
|
|
||||||
reason: '1',
|
|
||||||
extraAmount: '',
|
|
||||||
remark: '',
|
|
||||||
hasReacord: false,
|
|
||||||
showPayQrcodeModal: false
|
|
||||||
}
|
|
||||||
},
|
|
||||||
methods: {
|
|
||||||
async initPriceData() {
|
|
||||||
const cur_reacord = await this.resetPriceChangedInfo()
|
|
||||||
if(cur_reacord) {
|
|
||||||
this.hasReacord = true
|
|
||||||
this.init(cur_reacord);
|
|
||||||
} else {
|
|
||||||
this.hasReacord = false
|
|
||||||
}
|
|
||||||
},
|
|
||||||
init(priceObj) {
|
|
||||||
console.log(priceObj);
|
|
||||||
if (!priceObj || priceObj.payStatus == 1) {
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
this.moneyAmount = priceObj.changeMoney + (priceObj.attachmentMoney || 0)
|
|
||||||
this.extraAmount = priceObj.attachmentMoney;
|
|
||||||
this.remark = priceObj.remark;
|
|
||||||
this.chooseIndex = priceObj.reason ? this.array.findIndex(i => i == priceObj.reason) : 0;
|
|
||||||
this.imgList = priceObj.urls ? priceObj.urls.split(',') : []
|
|
||||||
this.priceObj = priceObj;
|
|
||||||
},
|
|
||||||
bindPickerChange(e) {
|
|
||||||
this.chooseIndex = parseInt(e.detail.value)
|
|
||||||
},
|
|
||||||
hideModal(e) {
|
|
||||||
this.$emit('close', e);
|
|
||||||
},
|
|
||||||
chooseImage(e) {
|
|
||||||
uni.chooseMedia({
|
|
||||||
count: 1, //默认9
|
|
||||||
mediaType: ['image'],
|
|
||||||
sizeType: ['original', 'compressed'], //可以指定是原图还是压缩图,默认二者都有
|
|
||||||
sourceType: ['album'], //从相册选择
|
|
||||||
success: (res) => {
|
|
||||||
uni.showLoading({
|
|
||||||
title: '上传中',
|
|
||||||
mask: true
|
|
||||||
});
|
|
||||||
res.tempFiles.forEach((fileObj, index) => {
|
|
||||||
this.$request.uploadFile(fileObj.tempFilePath).then((url) => {
|
|
||||||
this.imgList.push(url);
|
|
||||||
if (index === res.tempFiles.length - 1) {
|
|
||||||
uni.hideLoading();
|
|
||||||
}
|
|
||||||
});
|
|
||||||
});
|
|
||||||
}
|
|
||||||
});
|
|
||||||
},
|
|
||||||
viewImage(e, imgList) {
|
|
||||||
uni.previewImage({
|
|
||||||
urls: imgList,
|
|
||||||
current: e.currentTarget.dataset.url
|
|
||||||
});
|
|
||||||
},
|
|
||||||
delImg(e, imgList) {
|
|
||||||
uni.showModal({
|
|
||||||
title: '',
|
|
||||||
content: '确定要删除这张图片吗?',
|
|
||||||
cancelText: '取消',
|
|
||||||
confirmText: '确定',
|
|
||||||
success: res => {
|
|
||||||
if (res.confirm) {
|
|
||||||
imgList.splice(e.currentTarget.dataset.index, 1)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
})
|
|
||||||
},
|
|
||||||
async resetPriceChangedInfo() {
|
|
||||||
let res = await this.$request.getChangeOrderPrice(this.data);
|
|
||||||
if (res && res.code === 0) {
|
|
||||||
return res.data
|
|
||||||
}
|
|
||||||
},
|
|
||||||
resetData() {
|
|
||||||
this.chooseIndex = 0
|
|
||||||
this.imgList = []
|
|
||||||
this.moneyAmount = ''
|
|
||||||
this.extraAmount = ''
|
|
||||||
this.remark = ''
|
|
||||||
this.hasReacord = false
|
|
||||||
},
|
|
||||||
async submit(e) {
|
|
||||||
const res = await this.resetPriceChangedInfo()
|
|
||||||
if (res && res.type != 1) {
|
|
||||||
uni.showToast({
|
|
||||||
icon: 'none',
|
|
||||||
title: '你有加价未付款,请客户支付后再加或在原加价上增加金额!',
|
|
||||||
duration: 2500
|
|
||||||
})
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (!this.moneyAmount) {
|
|
||||||
uni.showToast({
|
|
||||||
title: '请输入本次加价总金额',
|
|
||||||
icon: 'none'
|
|
||||||
});
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
if (this.array[this.chooseIndex].indexOf('含') > -1 && !this.extraAmount) {
|
|
||||||
uni.showToast({
|
|
||||||
title: '请输入该费用实际金额',
|
|
||||||
icon: 'none'
|
|
||||||
});
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
if(this.array[this.chooseIndex].indexOf('含') > -1 && this.imgList.length === 0) {
|
|
||||||
uni.showToast({
|
|
||||||
title: '请上传凭证,至少一张',
|
|
||||||
icon: 'none'
|
|
||||||
});
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
const num_moneyAmount = parseInt(this.moneyAmount)
|
|
||||||
const num_extraAmount = parseInt(this.extraAmount)
|
|
||||||
if(this.array[this.chooseIndex].indexOf('含') > -1 && num_extraAmount > num_moneyAmount) {
|
|
||||||
uni.showToast({
|
|
||||||
title: '费用实际金额不能大于本次加价总金额',
|
|
||||||
icon: 'none'
|
|
||||||
});
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
if(this.array[this.chooseIndex].indexOf('含') === -1) {
|
|
||||||
console.log('调用详情接口',{
|
|
||||||
orderDetailId: this.data.orderDetailId,
|
|
||||||
attachMoney: this.moneyAmount,
|
|
||||||
type: '01'
|
|
||||||
});
|
|
||||||
// 调用后端接口,添加附加费
|
|
||||||
let res = await this.$request.changeOrderPrice({
|
|
||||||
orderDetailId: this.data.orderDetailId,
|
|
||||||
changeMoney: this.moneyAmount,
|
|
||||||
type: 1,
|
|
||||||
remark: this.remark,
|
|
||||||
urls: this.imgList.toString(),
|
|
||||||
reason: this.array[this.chooseIndex]
|
|
||||||
});
|
|
||||||
if (res.code === 0) {
|
|
||||||
uni.showToast({
|
|
||||||
title: '操作成功',
|
|
||||||
icon: 'success'
|
|
||||||
});
|
|
||||||
// this.$emit('callAgain')
|
|
||||||
this.initPriceData()
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
// 直接修改配件费
|
|
||||||
let type1_price, type2_price;
|
|
||||||
type2_price = num_extraAmount
|
|
||||||
type1_price = num_moneyAmount - num_extraAmount
|
|
||||||
console.log('调用列表接口',{
|
|
||||||
orderDetailId: this.data.orderDetailId,
|
|
||||||
changeMoney: type1_price,
|
|
||||||
type: 1,
|
|
||||||
remark: this.remark,
|
|
||||||
urls: this.imgList.toString()
|
|
||||||
});
|
|
||||||
let res2 = await this.$request.changeOrderPrice({
|
|
||||||
orderDetailId: this.data.orderDetailId,
|
|
||||||
changeMoney: type1_price,
|
|
||||||
type: 1,
|
|
||||||
remark: this.remark,
|
|
||||||
urls: this.imgList.toString(),
|
|
||||||
reason: this.array[this.chooseIndex]
|
|
||||||
});
|
|
||||||
if (res2.code != 0) return
|
|
||||||
const newData = await this.resetPriceChangedInfo()
|
|
||||||
console.log('调用详情接口',{
|
|
||||||
orderDetailId: this.data.orderDetailId,
|
|
||||||
attachMoney: type2_price,
|
|
||||||
type: '01'
|
|
||||||
});
|
|
||||||
let res1 = await this.$request.addOrderAttach({
|
|
||||||
orderDetailId: this.data.orderDetailId,
|
|
||||||
attachMoney: type2_price,
|
|
||||||
type: '01',
|
|
||||||
financialChangeRecordId: newData.id,
|
|
||||||
remark: this.remark,
|
|
||||||
});
|
|
||||||
if (res1.code != 0) return
|
|
||||||
uni.showToast({
|
|
||||||
icon: 'success',
|
|
||||||
title: '操作成功'
|
|
||||||
})
|
|
||||||
// this.$emit('callAgain')
|
|
||||||
this.initPriceData()
|
|
||||||
}
|
|
||||||
},
|
|
||||||
async makePayQrcode(e) {
|
|
||||||
let res = await this.$request.priceAddedQrPay(this.data);
|
|
||||||
if (res && res.code === 0) {
|
|
||||||
this.showPayQrcodeModal = true;
|
|
||||||
this.$refs.payQrcode.showQrcode(res.data.expend.qrcode_url);
|
|
||||||
}
|
|
||||||
},
|
|
||||||
finishQrPay(e) {
|
|
||||||
this.showPayQrcodeModal = false;
|
|
||||||
// this.$emit('callAgain')
|
|
||||||
this.initPriceData()
|
|
||||||
},
|
|
||||||
async clearCurAddedPrice() {
|
|
||||||
await this.$request.deleteAttachPrice({
|
|
||||||
orderDetailId: this.data.orderDetailId
|
|
||||||
})
|
|
||||||
let res = await this.$request.changeOrderPrice({
|
|
||||||
orderDetailId: this.data.orderDetailId,
|
|
||||||
changeMoney: 0,
|
|
||||||
type: 1,
|
|
||||||
remark: '客户清空加价',
|
|
||||||
urls: '',
|
|
||||||
reason: ''
|
|
||||||
});
|
|
||||||
if (res && res.code === 0) {
|
|
||||||
uni.showToast({
|
|
||||||
icon: 'success',
|
|
||||||
title: '操作成功'
|
|
||||||
})
|
|
||||||
// this.$emit('callAgain')
|
|
||||||
this.initPriceData()
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
</script>
|
|
||||||
|
|
||||||
<style scoped>
|
|
||||||
.grid.col-3.grid-square>view {
|
|
||||||
padding-bottom: calc((100% - 40rpx)/3);
|
|
||||||
height: 0;
|
|
||||||
width: calc((100% - 40rpx)/3);
|
|
||||||
}
|
|
||||||
|
|
||||||
.inline-input {
|
|
||||||
flex-basis: 70%;
|
|
||||||
}
|
|
||||||
.title-input {
|
|
||||||
display: inline-block;
|
|
||||||
width: 165rpx;
|
|
||||||
}
|
|
||||||
.custom-input {
|
|
||||||
height: 1.4rem;
|
|
||||||
min-height: 1.4rem;
|
|
||||||
}
|
|
||||||
</style>
|
|
||||||
|
|
@ -1,150 +0,0 @@
|
||||||
<template>
|
|
||||||
<view class="cu-modal" :class="show?'show':''">
|
|
||||||
<view class="cu-dialog">
|
|
||||||
<view class="cu-bar bg-white justify-end solid-bottom">
|
|
||||||
<view class="content">附加费用申请</view>
|
|
||||||
<view class="action" data-modal="applyExtraChargeModal" @click="hideModal">
|
|
||||||
<text class="cuIcon-close text-red"></text>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="bg-white padding text-left">
|
|
||||||
<view class="text-lg padding-top flex justify-start align-center">
|
|
||||||
<text>金额:</text>
|
|
||||||
<input type="digit" class="radius-input inline-input" v-model="moneyAmount"></input>
|
|
||||||
</view>
|
|
||||||
<view class="text-lg padding-top flex justify-start align-center">
|
|
||||||
<text>原因:</text>
|
|
||||||
<input type="text" class="radius-input inline-input" v-model="reason" disabled value="配件费"></input>
|
|
||||||
</view>
|
|
||||||
<view>
|
|
||||||
<view class="padding-tb-sm">上传图片</view>
|
|
||||||
<view class="grid col-3 grid-square">
|
|
||||||
<view class="bg-img" v-for="(item,index) in imgList" :key="index"
|
|
||||||
@tap="viewImage($event, imgList)" :data-url="item">
|
|
||||||
<image :src="item" mode="aspectFill"></image>
|
|
||||||
<view class="cu-tag bg-red" @tap.stop="delImg($event, imgList)" :data-index="index">
|
|
||||||
<text class='cuIcon-close'></text>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="solids" @tap="chooseImage" v-if="imgList.length < 1">
|
|
||||||
<text class='cuIcon-cameraadd'></text>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view>
|
|
||||||
<view class="padding-tb-sm">申请原因</view>
|
|
||||||
<view class="solid">
|
|
||||||
<textarea style="width: 100%; height: 200rpx;" fixed="true" class="radius text-left padding-sm"
|
|
||||||
v-model="remark" maxlength="-1"></textarea>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="cu-bar bg-white solid-top">
|
|
||||||
<view class="action margin-0 flex-sub text-black" data-modal="applyExtraChargeModal"
|
|
||||||
@click="hideModal">取消</view>
|
|
||||||
<view class="action margin-0 flex-sub text-main-color solid-left" data-modal="applyExtraChargeModal"
|
|
||||||
@click="submit">确认</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<script>
|
|
||||||
export default {
|
|
||||||
name: 'applyExtraCharge',
|
|
||||||
props: {
|
|
||||||
show: {
|
|
||||||
type: Boolean,
|
|
||||||
default: false
|
|
||||||
},
|
|
||||||
data: {
|
|
||||||
type: Object,
|
|
||||||
default: {}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
data() {
|
|
||||||
return {
|
|
||||||
imgList: [],
|
|
||||||
moneyAmount: '',
|
|
||||||
reason: ''
|
|
||||||
}
|
|
||||||
},
|
|
||||||
methods: {
|
|
||||||
hideModal(e) {
|
|
||||||
this.$emit('close', e);
|
|
||||||
},
|
|
||||||
chooseImage(e) {
|
|
||||||
uni.chooseMedia({
|
|
||||||
count: 1, //默认9
|
|
||||||
mediaType: ['image'],
|
|
||||||
sizeType: ['original', 'compressed'], //可以指定是原图还是压缩图,默认二者都有
|
|
||||||
sourceType: ['album'], //从相册选择
|
|
||||||
success: (res) => {
|
|
||||||
let tempFilePaths = [];
|
|
||||||
res.tempFiles.forEach((fileObj) => {
|
|
||||||
tempFilePaths.push(fileObj.tempFilePath)
|
|
||||||
})
|
|
||||||
if (this.imgList.length != 0) {
|
|
||||||
this.imgList = this.imgList.concat(tempFilePaths)
|
|
||||||
} else {
|
|
||||||
this.imgList = tempFilePaths
|
|
||||||
}
|
|
||||||
}
|
|
||||||
});
|
|
||||||
},
|
|
||||||
viewImage(e, imgList) {
|
|
||||||
uni.previewImage({
|
|
||||||
urls: imgList,
|
|
||||||
current: e.currentTarget.dataset.url
|
|
||||||
});
|
|
||||||
},
|
|
||||||
delImg(e, imgList) {
|
|
||||||
uni.showModal({
|
|
||||||
title: '',
|
|
||||||
content: '确定要删除这张图片吗?',
|
|
||||||
cancelText: '取消',
|
|
||||||
confirmText: '确定',
|
|
||||||
success: res => {
|
|
||||||
if (res.confirm) {
|
|
||||||
imgList.splice(e.currentTarget.dataset.index, 1)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
})
|
|
||||||
},
|
|
||||||
async submit(e) {
|
|
||||||
if (!this.moneyAmount) {
|
|
||||||
uni.showToast({
|
|
||||||
title: '请输入金额',
|
|
||||||
icon: 'none'
|
|
||||||
});
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
// 调用后端接口,添加附加费
|
|
||||||
let res = await this.$request.addOrderAttach({
|
|
||||||
orderDetailId: this.data.orderDetailId,
|
|
||||||
attachMoney: this.moneyAmount,
|
|
||||||
type: '01'
|
|
||||||
});
|
|
||||||
if (res.code === 0) {
|
|
||||||
uni.showToast({
|
|
||||||
title: '操作成功',
|
|
||||||
icon: 'success'
|
|
||||||
});
|
|
||||||
this.hideModal(e);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
</script>
|
|
||||||
|
|
||||||
<style scoped>
|
|
||||||
.grid.col-3.grid-square>view {
|
|
||||||
padding-bottom: calc((100% - 40rpx)/3);
|
|
||||||
height: 0;
|
|
||||||
width: calc((100% - 40rpx)/3);
|
|
||||||
}
|
|
||||||
|
|
||||||
.inline-input {
|
|
||||||
flex-basis: 75%;
|
|
||||||
}
|
|
||||||
</style>
|
|
||||||
|
|
@ -1,207 +0,0 @@
|
||||||
<template>
|
|
||||||
<!-- popup -->
|
|
||||||
<view>
|
|
||||||
<uni-popup ref="deliveryOrderPopup" type="bottom" @change="changePopup">
|
|
||||||
<view class="text-bold text-gray text-lg text-center left-top-sm-bar" data-popup="deliveryOrderPopup" @click="closePopup"><text
|
|
||||||
class="cuIcon-close"></text></view>
|
|
||||||
<view class="bg-white padding" style="padding-top: 74rpx; min-height: 1000rpx;">
|
|
||||||
<view class="text-xxl text-center">发货类型</view>
|
|
||||||
<radio-group class="flex padding-tb-sm flex-direction" style="gap: 10rpx">
|
|
||||||
<label @click="form.deliveryType = 1">
|
|
||||||
<radio class="main-color" :value="1" :checked="form.deliveryType === 1" /><text class="margin-left-sm">发快递/物流</text>
|
|
||||||
</label>
|
|
||||||
<view style="padding-left: 70rpx;">
|
|
||||||
<input type="text" v-model="form.trackingNumber" class="custom-input radius-input" placeholder="请输入快递/物流单号">
|
|
||||||
</view>
|
|
||||||
<label @click="form.deliveryType = 2">
|
|
||||||
<radio class="main-color" :value="2" :checked="form.deliveryType === 2"/><text class="margin-left-sm">送货上门</text>
|
|
||||||
</label>
|
|
||||||
<label @click="form.deliveryType = 3">
|
|
||||||
<radio class="main-color" :value="3" :checked="form.deliveryType === 3"/><text class="margin-left-sm">客户自提</text>
|
|
||||||
</label>
|
|
||||||
</radio-group>
|
|
||||||
<view class="text-lg text-left">出货拍照存档(非必填):</view>
|
|
||||||
<view>
|
|
||||||
<div class="grid col-3 grid-square">
|
|
||||||
<view class="bg-img" v-for="(item,index) in imgList" :key="index"
|
|
||||||
@tap="viewImage($event, imgList)" :data-url="item">
|
|
||||||
<image :src="item" mode="aspectFill"></image>
|
|
||||||
<view class="cu-tag bg-red" @tap.stop="delImg($event, imgList)" :data-index="index">
|
|
||||||
<text class='cuIcon-close'></text>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="solids" @tap="chooseImage" v-if="imgList.length < 6">
|
|
||||||
<text class='cuIcon-cameraadd'></text>
|
|
||||||
</view>
|
|
||||||
</div>
|
|
||||||
</view>
|
|
||||||
<view style="margin-bottom: 10rpx;">
|
|
||||||
<textarea style="width: 100%;box-sizing: border-box;" class="custom-input radius-input" placeholder="发货备注(非必填)" cols="30" rows="10" v-model="form.deliveryRemark"></textarea>
|
|
||||||
</view>
|
|
||||||
<view class="cu-bar bg-white solid-top">
|
|
||||||
<view class="action margin-0 flex-sub text-black" @tap="closePopup">取消</view>
|
|
||||||
<view class="action margin-0 flex-sub text-main-color solid-left" @click="Submit">确认发货</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</uni-popup>
|
|
||||||
</view>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<script>
|
|
||||||
export default {
|
|
||||||
emits: ['confirmFeedback', 'close'],
|
|
||||||
props: {
|
|
||||||
show: {
|
|
||||||
type: Boolean,
|
|
||||||
default: false
|
|
||||||
},
|
|
||||||
data: {
|
|
||||||
type: Object,
|
|
||||||
default: () => {}
|
|
||||||
},
|
|
||||||
isQuicklyDelivery: {
|
|
||||||
type: String,
|
|
||||||
default: '0'
|
|
||||||
}
|
|
||||||
},
|
|
||||||
watch: {
|
|
||||||
show: {
|
|
||||||
handler(newVal) {
|
|
||||||
if(newVal) {
|
|
||||||
this.$nextTick(() => {
|
|
||||||
this.$refs.deliveryOrderPopup.open()
|
|
||||||
})
|
|
||||||
}
|
|
||||||
},
|
|
||||||
immediate: true
|
|
||||||
}
|
|
||||||
},
|
|
||||||
data() {
|
|
||||||
return {
|
|
||||||
form: {
|
|
||||||
deliveryType: 1,
|
|
||||||
deliveryRemark: '',
|
|
||||||
deliveryImages: '',
|
|
||||||
trackingNumber: ''
|
|
||||||
},
|
|
||||||
imgList: [],
|
|
||||||
clicked: false
|
|
||||||
}
|
|
||||||
},
|
|
||||||
methods: {
|
|
||||||
chooseImage(e) {
|
|
||||||
uni.chooseMedia({
|
|
||||||
count: 1, //默认9
|
|
||||||
mediaType: ['image'],
|
|
||||||
sizeType: ['original', 'compressed'], //可以指定是原图还是压缩图,默认二者都有
|
|
||||||
sourceType: ['album'], //从相册选择
|
|
||||||
success: (res) => {
|
|
||||||
uni.showLoading({
|
|
||||||
title: '上传中',
|
|
||||||
mask: true
|
|
||||||
});
|
|
||||||
res.tempFiles.forEach((fileObj, index) => {
|
|
||||||
this.$request.uploadFile(fileObj.tempFilePath).then((url) => {
|
|
||||||
this.imgList.push(url);
|
|
||||||
if (index === res.tempFiles.length - 1) {
|
|
||||||
uni.hideLoading();
|
|
||||||
}
|
|
||||||
});
|
|
||||||
});
|
|
||||||
}
|
|
||||||
});
|
|
||||||
},
|
|
||||||
viewImage(e, imgList) {
|
|
||||||
uni.previewImage({
|
|
||||||
urls: imgList,
|
|
||||||
current: e.currentTarget.dataset.url
|
|
||||||
});
|
|
||||||
},
|
|
||||||
delImg(e, imgList) {
|
|
||||||
uni.showModal({
|
|
||||||
title: '',
|
|
||||||
content: '确定要删除这张图片吗?',
|
|
||||||
cancelText: '取消',
|
|
||||||
confirmText: '确定',
|
|
||||||
success: res => {
|
|
||||||
if (res.confirm) {
|
|
||||||
imgList.splice(e.currentTarget.dataset.index, 1)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
})
|
|
||||||
},
|
|
||||||
changePopup(e) {
|
|
||||||
console.log(e);
|
|
||||||
if(!e.show) {
|
|
||||||
this.closePopup()
|
|
||||||
}
|
|
||||||
},
|
|
||||||
closePopup() {
|
|
||||||
this.$emit('close')
|
|
||||||
},
|
|
||||||
changeRadio(e) {
|
|
||||||
this.form.deliveryType = e.target.value
|
|
||||||
},
|
|
||||||
async Submit() {
|
|
||||||
if(this.clicked) return;
|
|
||||||
this.clicked = true;
|
|
||||||
if(this.form.deliveryType == 1 && !this.form.trackingNumber) {
|
|
||||||
uni.showToast({
|
|
||||||
title: '请填写物流/快递单号',
|
|
||||||
icon: 'none'
|
|
||||||
})
|
|
||||||
this.clicked = false;
|
|
||||||
return
|
|
||||||
}
|
|
||||||
const isAfterService = this.data.afterServiceRecordList && this.data.afterServiceRecordList.length !== 0
|
|
||||||
let res;
|
|
||||||
if(isAfterService && this.isQuicklyDelivery === '0') {
|
|
||||||
const updateGoodsParams = {
|
|
||||||
id: this.data.afterServiceRecordList[0].id,
|
|
||||||
workerFeedbackResult: 3, // 已重发/补发
|
|
||||||
workerResendType: this.form.deliveryType, // 1-快递/物流
|
|
||||||
workerResendTrackingNumber: this.form.trackingNumber, // 必填
|
|
||||||
workerResendRemark: this.form.deliveryRemark,
|
|
||||||
workerResendImages: this.imgList.length ? this.imgList.toString() : ''
|
|
||||||
}
|
|
||||||
res = await this.$request.editAfterServiceGoodsRecord(updateGoodsParams);
|
|
||||||
} else {
|
|
||||||
// 确定方法名
|
|
||||||
let reqFunName = "updateOrder", id, isQuicklyDelivery;
|
|
||||||
if (this.data.orderDetailId == null) {
|
|
||||||
id = this.data.orderMasterId;
|
|
||||||
} else {
|
|
||||||
reqFunName = "updateDetailOrder";
|
|
||||||
id = this.data.orderDetailId;
|
|
||||||
isQuicklyDelivery = 1
|
|
||||||
}
|
|
||||||
const updateOrderParams = {
|
|
||||||
...this.form,
|
|
||||||
id: id,
|
|
||||||
deliveryImages: this.imgList.length ? this.imgList.toString() : ''
|
|
||||||
}
|
|
||||||
|
|
||||||
if(isQuicklyDelivery) {
|
|
||||||
updateOrderParams.isQuicklyDelivery = isQuicklyDelivery;
|
|
||||||
updateOrderParams.orderStatus = 3
|
|
||||||
}
|
|
||||||
|
|
||||||
res = await this.$request[reqFunName](updateOrderParams);
|
|
||||||
}
|
|
||||||
this.clicked = false;
|
|
||||||
if (res.code === 0) {
|
|
||||||
this.$emit('confirmFeedback')
|
|
||||||
} else {
|
|
||||||
uni.showToast({
|
|
||||||
title: '操作失败',
|
|
||||||
icon: 'none',
|
|
||||||
duration: 2000
|
|
||||||
})
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
</script>
|
|
||||||
|
|
||||||
<style>
|
|
||||||
</style>
|
|
||||||
|
|
@ -1,70 +0,0 @@
|
||||||
<template>
|
|
||||||
<view>
|
|
||||||
<!-- 模态框 -->
|
|
||||||
<view class="cu-modal" :class="show?'show':''">
|
|
||||||
<view class="cu-dialog">
|
|
||||||
<view class="padding-xl" style="background-color: #ffffff;">
|
|
||||||
<view class="text-bold text-lg margin-bottom-sm">物流信息</view>
|
|
||||||
|
|
||||||
<view class="cu-timeline" style="max-height: 600upx;overflow-y: auto;">
|
|
||||||
<view class="cu-item text-main-color" v-for="(item, index) in flowArr" :key="index">
|
|
||||||
<view class="content shadow-blur" style="text-align: left;padding: 15upx 20upx;">
|
|
||||||
<view><text style="color: black;">{{item.description}}</text></view>
|
|
||||||
<text style="color: #999999;font-size: 24upx;">{{item.time}}</text>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="cu-bar bg-white solid-top">
|
|
||||||
<view class="action margin-0 flex-sub text-black solid-left" data-modal="deliveryFlowDetail"
|
|
||||||
@tap="hideModal">关闭</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<script>
|
|
||||||
export default {
|
|
||||||
name: 'deliveryFlowDetail',
|
|
||||||
emits: ['confirmFeedback'],
|
|
||||||
props: {
|
|
||||||
show: {
|
|
||||||
type: Boolean,
|
|
||||||
default: false
|
|
||||||
},
|
|
||||||
trackingNumber: {
|
|
||||||
type: String
|
|
||||||
}
|
|
||||||
},
|
|
||||||
watch: {
|
|
||||||
show: {
|
|
||||||
handler(newVal) {
|
|
||||||
if(newVal) {
|
|
||||||
this.$nextTick(() => {
|
|
||||||
this.getFLows()
|
|
||||||
})
|
|
||||||
}
|
|
||||||
},
|
|
||||||
immediate: true
|
|
||||||
}
|
|
||||||
},
|
|
||||||
data() {
|
|
||||||
return {
|
|
||||||
flowArr: []
|
|
||||||
}
|
|
||||||
},
|
|
||||||
methods: {
|
|
||||||
async getFLows() {
|
|
||||||
const res = await this.$request.getDeliveryFlow(this.trackingNumber)
|
|
||||||
this.flowArr = res.data.traces ? res.data.traces.reverse() : [];
|
|
||||||
},
|
|
||||||
hideModal(e) {
|
|
||||||
this.$emit('close', e);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
</script>
|
|
||||||
|
|
||||||
<style>
|
|
||||||
</style>
|
|
||||||
|
|
@ -1,271 +0,0 @@
|
||||||
<template>
|
|
||||||
<!-- popup -->
|
|
||||||
<view>
|
|
||||||
<uni-popup ref="deliveryOrderPopup" type="bottom" @change="changePopup">
|
|
||||||
<view class="text-bold text-gray text-lg text-center left-top-sm-bar" style="position: absolute;top: 15px;right: 20px;" data-popup="deliveryOrderPopup" @click="closePopup"><text
|
|
||||||
class="cuIcon-close"></text></view>
|
|
||||||
<view class="bg-white padding" style="padding-top: 30rpx;width: 100%;">
|
|
||||||
<view class="text-center">
|
|
||||||
<text class="text-black" style="font-size: 34upx;">包安装/包服务商品安装确认</text>
|
|
||||||
</view>
|
|
||||||
<view>
|
|
||||||
<view class="solid-bottom padding-bottom-sm">
|
|
||||||
<view v-if="columnTitleArr.length" class="flex justify-between margin-tb-sm">
|
|
||||||
<view class="basis-df">{{columnTitleArr[0]}}</view>
|
|
||||||
<view class="flex justify-end text-center basis-df">
|
|
||||||
<view v-for="(title, index) in columnTitleArr" v-if="index >= 1" class="basis-df">{{title}}</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="flex justify-between margin-tb-xs align-center" v-for="(item,index) in pickedList" :key="index">
|
|
||||||
<view class='cu-tag padding basis-lg'>{{item.goodsName}}</view>
|
|
||||||
<view class="flex justify-end basis-df text-center align-center">
|
|
||||||
<view class="basis-df">{{item.goodsNum}}</view>
|
|
||||||
<view class="basis-df">{{item.goodsNum}}
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="padding-top-sm padding-bottom-xs flex justify-between align-center">
|
|
||||||
<text class="margin-right-sm">本单可派服务金额:<text class="text-red text-lg">{{curOrder.serverMoney}}</text></text>
|
|
||||||
</view>
|
|
||||||
<view class="padding-bottom-sm flex justify-between align-center">
|
|
||||||
<text class="margin-right-sm" style="width: 150rpx;">服务金额</text>
|
|
||||||
<input type="digit" class="line-input radius-input" v-model="dispatchTotalPrice" placeholder="请输入服务总金额 (你对服务单跟进负责)"></input>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
|
|
||||||
<view class="padding-tb" v-if="serviceShop">
|
|
||||||
<view class="text-black text-bold flex justify-between">
|
|
||||||
<text>安装/服务/施工门店</text>
|
|
||||||
<text @click="goChooseShop">更多></text>
|
|
||||||
</view>
|
|
||||||
<view class="flex-sub flex margin-top-sm" @click="openShopLocation(serviceShop)">
|
|
||||||
<view style="width: 150rpx;height: 150rpx;margin-right:10px;">
|
|
||||||
<image style="width: 100%;height: 100%;" :src="serviceShop.imageUrl" mode="aspectFill"></image>
|
|
||||||
</view>
|
|
||||||
<view class="flex-sub">
|
|
||||||
<view class="text-bold" style="text-overflow: ellipsis;overflow: hidden;display: -webkit-box;-webkit-box-orient: vertical;-webkit-line-clamp: 1;">
|
|
||||||
客户已选: {{serviceShop.shopName}}
|
|
||||||
</view>
|
|
||||||
<view class="padding-tb-xs" style="position: relative;">
|
|
||||||
<!-- <view class='cu-tag round bg-orange light'>
|
|
||||||
<text class="text-black" v-if="pickedProductList[0].product[0].storeService == 1">到店服务</text>
|
|
||||||
<text class="text-black" v-if="pickedProductList[0].product[0].storeService == 2">到店+配送(服务)</text>
|
|
||||||
<text class="text-black" v-if="pickedProductList[0].product[0].storeService == 3">到店+上门(服务)</text>
|
|
||||||
</view> -->
|
|
||||||
<view class="margin-lr-sm" style="display: inline-block;" v-if="serviceShop.distance">
|
|
||||||
<view class="cu-tag bg-red" style="padding: 0 2px;height: auto;">距离客户</view>
|
|
||||||
<text class="text-gray" style="vertical-align: middle;">{{serviceShop.distance}}</text>
|
|
||||||
</view>
|
|
||||||
<image src="/static/navigation.png" style="width: 50rpx;height: 50rpx;display: inline-block;position: absolute;top: 5px;right: -10px;"></image>
|
|
||||||
</view>
|
|
||||||
<view style="text-overflow: ellipsis;overflow: hidden;display: -webkit-box;-webkit-box-orient: vertical;-webkit-line-clamp: 1;">{{serviceShop.provinceName + serviceShop.cityName + serviceShop.countryName + serviceShop.streetName + serviceShop.address}}</view>
|
|
||||||
<view class="flex justify-between align-center margin-bottom-xs padding-top">
|
|
||||||
<view>
|
|
||||||
<text class="text-bold text-lg margin-lr-xs">店长:{{serviceShop.phone}}</text>
|
|
||||||
</view>
|
|
||||||
<button class="cu-btn line-main-color" @click.stop="makePhoneCall(serviceShop.phone)">拨打</button>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="cu-bar bg-white solid-top">
|
|
||||||
<view class="action margin-0 flex-sub text-black" @tap="closePopup">取消</view>
|
|
||||||
<view class="action margin-0 flex-sub text-main-color solid-left" @click="assignWork">提交</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</uni-popup>
|
|
||||||
</view>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<script>
|
|
||||||
export default {
|
|
||||||
emits: ['confirmFeedback', 'close'],
|
|
||||||
props: {
|
|
||||||
show: {
|
|
||||||
type: Boolean,
|
|
||||||
default: false
|
|
||||||
},
|
|
||||||
data: {
|
|
||||||
type: Object,
|
|
||||||
default: () => {}
|
|
||||||
},
|
|
||||||
product: {
|
|
||||||
type: Object,
|
|
||||||
default: {}
|
|
||||||
},
|
|
||||||
orderType: {
|
|
||||||
type: Number,
|
|
||||||
default: 0
|
|
||||||
}
|
|
||||||
},
|
|
||||||
watch: {
|
|
||||||
show: {
|
|
||||||
handler(newVal) {
|
|
||||||
if(newVal) {
|
|
||||||
this.$nextTick(() => {
|
|
||||||
this.$refs.deliveryOrderPopup.open()
|
|
||||||
this.loadData(this.data)
|
|
||||||
})
|
|
||||||
}
|
|
||||||
},
|
|
||||||
immediate: true
|
|
||||||
}
|
|
||||||
},
|
|
||||||
data() {
|
|
||||||
return {
|
|
||||||
dispatchTotalPrice: null,
|
|
||||||
showDispatchPriceModal: false,
|
|
||||||
columnTitleArr: ['购买机型', '待派单', '派单量'],
|
|
||||||
curOrder: {},
|
|
||||||
pickedList: [],
|
|
||||||
workerName: null,
|
|
||||||
curUserInfo: null,
|
|
||||||
serviceShop: null,
|
|
||||||
serviceCancelled: null
|
|
||||||
}
|
|
||||||
},
|
|
||||||
onReady() {
|
|
||||||
uni.$on('chooseShop', this.chooseShop)
|
|
||||||
},
|
|
||||||
onUnload() {
|
|
||||||
uni.$off('chooseShop');
|
|
||||||
},
|
|
||||||
methods: {
|
|
||||||
changePopup(e) {
|
|
||||||
console.log(e);
|
|
||||||
if(!e.show) {
|
|
||||||
this.closePopup()
|
|
||||||
}
|
|
||||||
},
|
|
||||||
closePopup() {
|
|
||||||
this.$emit('close')
|
|
||||||
},
|
|
||||||
dateChange(e) {
|
|
||||||
this.date = e.detail.value;
|
|
||||||
this.changeExpectTime();
|
|
||||||
},
|
|
||||||
openShopLocation(item) {
|
|
||||||
// const gcj02Coord = wgs84ToGcj02(item.shop.longitude, item.shop.latitude)
|
|
||||||
// const gcj02Coord = wgs84ToGcj02(102.80154676649306, 24.969456922743056)
|
|
||||||
// const gcj02Coord = [102.82868680950929, 24.864792838337802]
|
|
||||||
const gcj02Coord = [item.longitude, item.latitude]
|
|
||||||
wx.openLocation({
|
|
||||||
latitude: gcj02Coord[1],
|
|
||||||
longitude: gcj02Coord[0],
|
|
||||||
scale: 18,
|
|
||||||
name: item.shopName,
|
|
||||||
address: `${item.provinceName}${item.cityName}${item.countryName}${item.streetName}${item.address}`
|
|
||||||
})
|
|
||||||
},
|
|
||||||
showModal(e) {
|
|
||||||
this[e.currentTarget.dataset.modal] = true;
|
|
||||||
},
|
|
||||||
hideModal(e) {
|
|
||||||
this[e.currentTarget.dataset.modal] = false;
|
|
||||||
},
|
|
||||||
changePiecesNum(curNum, curItem) {
|
|
||||||
curItem.toAssignNum = curNum;
|
|
||||||
},
|
|
||||||
resetData() {
|
|
||||||
this.dispatchTotalPrice = null;
|
|
||||||
this.pickedList = [];
|
|
||||||
this.curOrder = {};
|
|
||||||
this.curUserInfo = null;
|
|
||||||
},
|
|
||||||
loadData(order) {
|
|
||||||
this.resetData();
|
|
||||||
this.curUserInfo = this.$request.getCurUserInfo();
|
|
||||||
this.getCanAssignList(order);
|
|
||||||
// init defalut shop
|
|
||||||
this.initShop()
|
|
||||||
},
|
|
||||||
async getCanAssignList(order) {
|
|
||||||
// 获取最新的订单信息
|
|
||||||
let getOrderRes = await this.$request.getOrderMasterDetail({
|
|
||||||
id: order.orderMasterId,
|
|
||||||
});
|
|
||||||
let res = await this.$request.getCanAssignList({
|
|
||||||
orderMasterId: order.orderMasterId,
|
|
||||||
generateServiceOrder: getOrderRes.data.serviceCancelled
|
|
||||||
});
|
|
||||||
this.serviceCancelled = getOrderRes.data.serviceCancelled;
|
|
||||||
let pickedList = res.data;
|
|
||||||
this.curOrder = getOrderRes.data;
|
|
||||||
this.pickedList = pickedList;
|
|
||||||
},
|
|
||||||
async initShop() {
|
|
||||||
const {provinceName, cityName, countryName, streetName, address, serviceShopId} = this.data
|
|
||||||
let res = await this.$request.getShopDetailWithDistance({
|
|
||||||
shopId: serviceShopId,
|
|
||||||
provinceName,
|
|
||||||
cityName,
|
|
||||||
countryName,
|
|
||||||
streetName,
|
|
||||||
address
|
|
||||||
});
|
|
||||||
this.serviceShop = res.data;
|
|
||||||
},
|
|
||||||
chooseShop(shopInfo) {
|
|
||||||
this.serviceShop = shopInfo;
|
|
||||||
},
|
|
||||||
goChooseShop() {
|
|
||||||
const {provinceName, cityName, countryName, streetName, address, goodsId, goods, serviceShopId} = this.data
|
|
||||||
const addressFullObj = {
|
|
||||||
provinceName,
|
|
||||||
cityName,
|
|
||||||
countryName,
|
|
||||||
streetName,
|
|
||||||
address
|
|
||||||
}
|
|
||||||
const gotGoodsId = goods ? goods.goodsId : goodsId
|
|
||||||
uni.navigateTo({
|
|
||||||
url: '/pages/order-manage/choose-shop?goodsId='+gotGoodsId+'&addressFullObj='+JSON.stringify(addressFullObj)+'&shopId='+serviceShopId
|
|
||||||
})
|
|
||||||
},
|
|
||||||
async assignWork() {
|
|
||||||
if (this.dispatchTotalPrice) {
|
|
||||||
let res = await this.$request.allocateServiceMoney({
|
|
||||||
id: this.data.orderMasterId,
|
|
||||||
serverGoodsMoney: this.dispatchTotalPrice,
|
|
||||||
serviceShopId: this.serviceShop.shopId
|
|
||||||
});
|
|
||||||
if (res && res.code === 0) {
|
|
||||||
setTimeout(() => {
|
|
||||||
uni.showToast({
|
|
||||||
icon: 'success',
|
|
||||||
title: this.serviceCancelled == 1 ? '已安装确认' : '现已安装确认,请操作接单',
|
|
||||||
duration: 2000
|
|
||||||
})
|
|
||||||
}, 1500)
|
|
||||||
this.$emit('confirmFeedback');
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
uni.showToast({
|
|
||||||
title: '请输入服务总金额',
|
|
||||||
icon: 'none'
|
|
||||||
})
|
|
||||||
}
|
|
||||||
},
|
|
||||||
makePhoneCall(customerPhone) {
|
|
||||||
uni.makePhoneCall({
|
|
||||||
phoneNumber: customerPhone
|
|
||||||
})
|
|
||||||
},
|
|
||||||
}
|
|
||||||
}
|
|
||||||
</script>
|
|
||||||
|
|
||||||
<style scoped>
|
|
||||||
|
|
||||||
.relative-view {
|
|
||||||
position: relative;
|
|
||||||
}
|
|
||||||
|
|
||||||
.input-arrow {
|
|
||||||
position: absolute;
|
|
||||||
right: 10rpx;
|
|
||||||
top: 25%;
|
|
||||||
}
|
|
||||||
</style>
|
|
||||||
|
|
@ -1,323 +0,0 @@
|
||||||
<template>
|
|
||||||
<!-- popup -->
|
|
||||||
<view>
|
|
||||||
<uni-popup ref="deliveryOrderPopup" type="bottom" @change="changePopup">
|
|
||||||
<view class="text-bold text-gray text-lg text-center left-top-sm-bar" data-popup="deliveryOrderPopup" @click="closePopup"><text
|
|
||||||
class="cuIcon-close"></text></view>
|
|
||||||
<view class="bg-white padding" style="padding-top: 74rpx; min-height: 1000rpx;">
|
|
||||||
<view>
|
|
||||||
<view class="solid-bottom padding-bottom-sm">
|
|
||||||
<view v-if="columnTitleArr.length" class="flex justify-between margin-tb-sm">
|
|
||||||
<view class="basis-df">{{columnTitleArr[0]}}</view>
|
|
||||||
<view class="flex justify-end text-center basis-df">
|
|
||||||
<view v-for="(title, index) in columnTitleArr" v-if="index >= 1" class="basis-df">{{title}}</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="flex justify-between margin-tb-xs align-center" v-for="(item,index) in pickedList" :key="index">
|
|
||||||
<view class='cu-tag padding basis-lg'>{{item.goodsName}}</view>
|
|
||||||
<view class="flex justify-end basis-df text-center align-center">
|
|
||||||
<view class="basis-df">{{item.goodsNum}}</view>
|
|
||||||
<view class="basis-df">
|
|
||||||
<uni-number-box :min="0" :max="item.goodsNum" v-model="item.toAssignNum" @change="changePiecesNum($event, item)">
|
|
||||||
</uni-number-box>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="padding-top-sm padding-bottom-xs flex justify-between align-center">
|
|
||||||
<text class="margin-right-sm">本单可派任务金额:<text class="text-red text-lg">{{curOrder.serverMoney}}</text></text>
|
|
||||||
</view>
|
|
||||||
<view class="padding-bottom-sm flex justify-between align-center">
|
|
||||||
<text class="margin-right-sm" style="width: 150rpx;">派单价格</text>
|
|
||||||
<input type="digit" class="line-input radius-input" v-model="dispatchTotalPrice" placeholder="请输入派出总额"></input>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
|
|
||||||
<view class="solid-bottom padding padding-bottom-sm">
|
|
||||||
<view class="flex justify-between align-center margin-bottom-xs padding-top">
|
|
||||||
<view>
|
|
||||||
<text class="text-xxl text-main-color"><text class="cuIcon-phone"></text></text>
|
|
||||||
<text class="text-bold text-lg margin-lr-xs">{{data.customerPhone.substring(0, 3) + "****" + data.customerPhone.substring(7)}}</text>
|
|
||||||
</view>
|
|
||||||
<button class="cu-btn line-main-color" @click="makePhoneCall(data.customerPhone)">拨打</button>
|
|
||||||
</view>
|
|
||||||
<view class="text-sm">
|
|
||||||
{{orderType === 1 ? '分次发货,请输入发货日期与时间,然后在”发货预约“栏按时发货。' : '拨打电话,按与客户约定的时间填入,完成排单,未完成排单将导致排单超时!'}}
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
|
|
||||||
<view class="padding">
|
|
||||||
<view class="margin-bottom-xs">
|
|
||||||
<view class="margin-bottom-xs">选择日期:</view>
|
|
||||||
<picker class="relative-view" mode="date" :value="date" :start="curDate" @change="dateChange">
|
|
||||||
<input class="radius-input" v-model="date" disabled>
|
|
||||||
<view class="text-lg input-arrow"><text class="cuIcon-triangledownfill"></text></view>
|
|
||||||
</input>
|
|
||||||
</picker>
|
|
||||||
</view>
|
|
||||||
<view>
|
|
||||||
<view class="margin-bottom-xs">选择时间:</view>
|
|
||||||
<view class="flex justify-start align-center">
|
|
||||||
<picker class="relative-view" :class="disableTime ? 'readonlyPicker' : ''" mode="selector" :value="timeIndex" :range="timeList"
|
|
||||||
@change="timeChange" @click="showTime">
|
|
||||||
<input class="custom-input radius-input" v-model="time" disabled>
|
|
||||||
<view class="text-lg input-arrow"><text class="cuIcon-triangledownfill"></text></view>
|
|
||||||
</input>
|
|
||||||
</picker>
|
|
||||||
<text class="margin-lr-xs">或</text>
|
|
||||||
<picker class="relative-view" :class="!disableTime ? 'readonlyPicker' : ''" mode="selector" :value="timeRangeIndex" :range="timeRangeList"
|
|
||||||
@change="timeRangeChange" @click="showDuration">
|
|
||||||
<input class="custom-input radius-input" v-model="timeRange" disabled>
|
|
||||||
<view class="text-lg input-arrow"><text class="cuIcon-triangledownfill"></text></view>
|
|
||||||
</input>
|
|
||||||
</picker>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="cu-bar bg-white solid-top">
|
|
||||||
<view class="action margin-0 flex-sub text-black" @tap="closePopup">取消</view>
|
|
||||||
<view class="action margin-0 flex-sub text-main-color solid-left" @click="assignWork">提交</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</uni-popup>
|
|
||||||
</view>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<script>
|
|
||||||
export default {
|
|
||||||
emits: ['confirmFeedback', 'close'],
|
|
||||||
props: {
|
|
||||||
show: {
|
|
||||||
type: Boolean,
|
|
||||||
default: false
|
|
||||||
},
|
|
||||||
data: {
|
|
||||||
type: Object,
|
|
||||||
default: () => {}
|
|
||||||
},
|
|
||||||
product: {
|
|
||||||
type: Object,
|
|
||||||
default: {}
|
|
||||||
},
|
|
||||||
orderType: {
|
|
||||||
type: Number,
|
|
||||||
default: 0
|
|
||||||
}
|
|
||||||
},
|
|
||||||
watch: {
|
|
||||||
show: {
|
|
||||||
handler(newVal) {
|
|
||||||
if(newVal) {
|
|
||||||
this.$nextTick(() => {
|
|
||||||
this.$refs.deliveryOrderPopup.open()
|
|
||||||
this.loadData(this.data)
|
|
||||||
})
|
|
||||||
}
|
|
||||||
},
|
|
||||||
immediate: true
|
|
||||||
}
|
|
||||||
},
|
|
||||||
data() {
|
|
||||||
return {
|
|
||||||
dispatchTotalPrice: null,
|
|
||||||
showDispatchPriceModal: false,
|
|
||||||
columnTitleArr: ['购买机型', '待派单', '派单量'],
|
|
||||||
curOrder: {},
|
|
||||||
pickedList: [],
|
|
||||||
workerName: null,
|
|
||||||
curUserInfo: null,
|
|
||||||
date: null,
|
|
||||||
time: null,
|
|
||||||
timeList: [],
|
|
||||||
timeIndex: 0,
|
|
||||||
timeRangeList: [],
|
|
||||||
timeRange: null,
|
|
||||||
timeRangeIndex: 0,
|
|
||||||
expectTimeStart: null,
|
|
||||||
expectTimeEnd: null,
|
|
||||||
disableTime: false
|
|
||||||
}
|
|
||||||
},
|
|
||||||
onReady() {
|
|
||||||
this.timeRangeList = this.$globalData.timeRangeList;
|
|
||||||
this.timeList = this.$globalData.timeList;
|
|
||||||
},
|
|
||||||
methods: {
|
|
||||||
changePopup(e) {
|
|
||||||
console.log(e);
|
|
||||||
if(!e.show) {
|
|
||||||
this.closePopup()
|
|
||||||
}
|
|
||||||
},
|
|
||||||
closePopup() {
|
|
||||||
this.$emit('close')
|
|
||||||
},
|
|
||||||
dateChange(e) {
|
|
||||||
this.date = e.detail.value;
|
|
||||||
this.changeExpectTime();
|
|
||||||
},
|
|
||||||
showTime() {
|
|
||||||
this.disableTime = false;
|
|
||||||
},
|
|
||||||
showDuration() {
|
|
||||||
this.disableTime = true;
|
|
||||||
},
|
|
||||||
timeChange(e) {
|
|
||||||
this.timeIndex = e.detail.value;
|
|
||||||
this.time = this.timeList[this.timeIndex];
|
|
||||||
this.timeRange = null;
|
|
||||||
this.changeExpectTime();
|
|
||||||
},
|
|
||||||
timeRangeChange(e) {
|
|
||||||
this.timeRangeIndex = e.detail.value;
|
|
||||||
this.timeRange = this.timeRangeList[this.timeRangeIndex];
|
|
||||||
this.time = null;
|
|
||||||
this.changeExpectTime();
|
|
||||||
},
|
|
||||||
changeExpectTime() {
|
|
||||||
let time = this.time != null ? this.time : this.timeRange;
|
|
||||||
if (time != null) {
|
|
||||||
let timeRangeSplit = this.$globalData.timeRangeSplit;
|
|
||||||
let timeArr = time.split(timeRangeSplit);
|
|
||||||
this.expectTimeStart = this.date + ' ' + timeArr[0] + ':00';
|
|
||||||
this.expectTimeEnd = this.date + ' ' + timeArr[1] + ':00';
|
|
||||||
}
|
|
||||||
},
|
|
||||||
showModal(e) {
|
|
||||||
this[e.currentTarget.dataset.modal] = true;
|
|
||||||
},
|
|
||||||
hideModal(e) {
|
|
||||||
this[e.currentTarget.dataset.modal] = false;
|
|
||||||
},
|
|
||||||
changePiecesNum(curNum, curItem) {
|
|
||||||
curItem.toAssignNum = curNum;
|
|
||||||
},
|
|
||||||
resetData() {
|
|
||||||
this.dispatchTotalPrice = null;
|
|
||||||
this.pickedList = [];
|
|
||||||
this.curOrder = {};
|
|
||||||
this.curUserInfo = null;
|
|
||||||
this.date = null;
|
|
||||||
this.time = null;
|
|
||||||
this.timeRange = null;
|
|
||||||
this.timeRangeIndex = 0;
|
|
||||||
this.expectTimeStart = null,
|
|
||||||
this.expectTimeEnd = null;
|
|
||||||
},
|
|
||||||
loadData(order) {
|
|
||||||
this.resetData();
|
|
||||||
this.curUserInfo = this.$request.getCurUserInfo();
|
|
||||||
this.getCanAssignList(order);
|
|
||||||
},
|
|
||||||
async getCanAssignList(order) {
|
|
||||||
// 获取最新的订单信息
|
|
||||||
let getOrderRes = await this.$request.getOrderMasterDetail({
|
|
||||||
id: order.orderMasterId
|
|
||||||
});
|
|
||||||
|
|
||||||
let res = await this.$request.getCanAssignList({
|
|
||||||
orderMasterId: order.orderMasterId
|
|
||||||
});
|
|
||||||
let pickedList = res.data;
|
|
||||||
this.curOrder = getOrderRes.data;
|
|
||||||
this.pickedList = pickedList;
|
|
||||||
},
|
|
||||||
assignWork() {
|
|
||||||
let goodsToAssign = [];
|
|
||||||
// 标识是否派完所有goods,1为派完,0为未派完
|
|
||||||
let isAll = 1;
|
|
||||||
this.pickedList.forEach((item) => {
|
|
||||||
if (item.toAssignNum && item.goodsNum !== item.toAssignNum) {
|
|
||||||
isAll = 0;
|
|
||||||
}
|
|
||||||
if (item.toAssignNum) {
|
|
||||||
goodsToAssign.push({
|
|
||||||
goodsStandardId: item.goodsStandardId,
|
|
||||||
num: item.toAssignNum
|
|
||||||
})
|
|
||||||
}
|
|
||||||
});
|
|
||||||
if (goodsToAssign.length > 0) {
|
|
||||||
if (this.dispatchTotalPrice) {
|
|
||||||
if (!(this.time || this.timeRange)) {
|
|
||||||
uni.showToast({
|
|
||||||
title: '请选择预约时间',
|
|
||||||
icon: 'none'
|
|
||||||
})
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
this.UpdateTime()
|
|
||||||
let params = {
|
|
||||||
goodsList: goodsToAssign,
|
|
||||||
workerId: this.curUserInfo.workerId,
|
|
||||||
totalPay: this.dispatchTotalPrice,
|
|
||||||
orderMasterId: this.curOrder.orderMasterId,
|
|
||||||
isAll: isAll,
|
|
||||||
workerName: this.curUserInfo.realName
|
|
||||||
}
|
|
||||||
this.$emit('assignWork', params);
|
|
||||||
} else {
|
|
||||||
uni.showToast({
|
|
||||||
title: '请填写派单价格',
|
|
||||||
icon: 'none'
|
|
||||||
})
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
uni.showToast({
|
|
||||||
title: '请至少选择一种规格',
|
|
||||||
icon: 'none'
|
|
||||||
})
|
|
||||||
}
|
|
||||||
},
|
|
||||||
makePhoneCall(customerPhone) {
|
|
||||||
uni.makePhoneCall({
|
|
||||||
phoneNumber: customerPhone
|
|
||||||
})
|
|
||||||
},
|
|
||||||
async UpdateTime() {
|
|
||||||
const datetimeArr = [this.expectTimeStart, this.expectTimeEnd];
|
|
||||||
let reqFunName = "updateOrder", id;
|
|
||||||
if (this.data.orderDetailId == null) {
|
|
||||||
id = this.data.orderMasterId;
|
|
||||||
} else {
|
|
||||||
reqFunName = "updateDetailOrder";
|
|
||||||
id = this.data.orderDetailId;
|
|
||||||
}
|
|
||||||
// 确定参数
|
|
||||||
let params = datetimeArr && datetimeArr.length > 1 ? {
|
|
||||||
id: id,
|
|
||||||
expectTimeStart: datetimeArr[0],
|
|
||||||
expectTimeEnd: datetimeArr[1],
|
|
||||||
useTimeNotRange: datetimeArr[1] == null ? true : false
|
|
||||||
} : {
|
|
||||||
id: id,
|
|
||||||
revTime: datetime
|
|
||||||
}
|
|
||||||
|
|
||||||
let res = await this.$request[reqFunName](params);
|
|
||||||
if (res.code === 0) {
|
|
||||||
this.$emit('confirmFeedback')
|
|
||||||
} else {
|
|
||||||
uni.showToast({
|
|
||||||
title: '操作失败',
|
|
||||||
icon: 'none',
|
|
||||||
duration: 2000
|
|
||||||
})
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
</script>
|
|
||||||
|
|
||||||
<style scoped>
|
|
||||||
|
|
||||||
.relative-view {
|
|
||||||
position: relative;
|
|
||||||
}
|
|
||||||
|
|
||||||
.input-arrow {
|
|
||||||
position: absolute;
|
|
||||||
right: 10rpx;
|
|
||||||
top: 25%;
|
|
||||||
}
|
|
||||||
</style>
|
|
||||||
|
|
@ -15,7 +15,7 @@
|
||||||
<button class="cu-btn line-main-color" @click="makePhoneCall(data.customerPhone)">拨打</button>
|
<button class="cu-btn line-main-color" @click="makePhoneCall(data.customerPhone)">拨打</button>
|
||||||
</view>
|
</view>
|
||||||
<view class="text-sm">
|
<view class="text-sm">
|
||||||
{{ orderType === 1 ? '修改或重排发货时间,需与客户协商一致并同意,否则引起客诉你负全责。' : '拨打电话,按与客户约定的时间填入,完成排单,未完成排单将导致排单超时!'}}
|
拨打电话,按与客户约定的时间填入,完成排单,未完成排单将导致排单超时!
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="padding">
|
<view class="padding">
|
||||||
|
|
@ -57,7 +57,7 @@
|
||||||
</label>
|
</label>
|
||||||
<label class="radio">
|
<label class="radio">
|
||||||
<radio style="transform:scale(0.7)" class="main-color" value="master" />
|
<radio style="transform:scale(0.7)" class="main-color" value="master" />
|
||||||
<text>{{orderType === 1 ? '商家原因' : '师傅原因'}}</text>
|
<text>师傅原因</text>
|
||||||
</label>
|
</label>
|
||||||
</radio-group>
|
</radio-group>
|
||||||
</view>
|
</view>
|
||||||
|
|
@ -68,7 +68,7 @@
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="cu-bar bg-white solid-top">
|
<view class="cu-bar bg-white solid-top">
|
||||||
<view class="action margin-0 flex-sub text-black" data-modal="showEditTimeArrangeModal" @click="cannotArrangeTime">{{orderType === 1 ? '取消' : '无法排单'}}</view>
|
<view class="action margin-0 flex-sub text-black" data-modal="showEditTimeArrangeModal" @click="cannotArrangeTime">无法排单</view>
|
||||||
<view class="action margin-0 flex-sub text-main-color solid-left" data-modal="showEditTimeArrangeModal"
|
<view class="action margin-0 flex-sub text-main-color solid-left" data-modal="showEditTimeArrangeModal"
|
||||||
@click="arrangeTime">确认</view>
|
@click="arrangeTime">确认</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
@ -79,7 +79,7 @@
|
||||||
<script>
|
<script>
|
||||||
export default {
|
export default {
|
||||||
name: 'edit-time-arrange',
|
name: 'edit-time-arrange',
|
||||||
emits: ['showArrangeFailTime', 'editServTime', 'close'],
|
emits: ['showArrangeFailTime', 'editServTime'],
|
||||||
props: {
|
props: {
|
||||||
show: {
|
show: {
|
||||||
type: Boolean,
|
type: Boolean,
|
||||||
|
|
@ -87,7 +87,7 @@
|
||||||
},
|
},
|
||||||
data: {
|
data: {
|
||||||
type: Object,
|
type: Object,
|
||||||
default: () => {}
|
default: {}
|
||||||
},
|
},
|
||||||
curDate: {
|
curDate: {
|
||||||
type: String,
|
type: String,
|
||||||
|
|
@ -96,10 +96,6 @@
|
||||||
ifRollback2WS: {
|
ifRollback2WS: {
|
||||||
type: Boolean,
|
type: Boolean,
|
||||||
default: false
|
default: false
|
||||||
},
|
|
||||||
orderType: {
|
|
||||||
type: Number,
|
|
||||||
default: 0
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
|
|
@ -165,15 +161,11 @@
|
||||||
},
|
},
|
||||||
hideModal(e) {
|
hideModal(e) {
|
||||||
this.resetData();
|
this.resetData();
|
||||||
this.$emit('close', e);
|
uni.$emit(this.$globalFun.HIDE_MODAL, e);
|
||||||
},
|
},
|
||||||
cannotArrangeTime(e) {
|
cannotArrangeTime(e) {
|
||||||
this.resetData();
|
this.resetData();
|
||||||
if(this.orderType === 1) {
|
|
||||||
this.hideModal(e)
|
|
||||||
} else {
|
|
||||||
this.$emit('showArrangeFailTime', e)
|
this.$emit('showArrangeFailTime', e)
|
||||||
}
|
|
||||||
},
|
},
|
||||||
async arrangeTime(e) {
|
async arrangeTime(e) {
|
||||||
if (!(this.time || this.timeRange)) {
|
if (!(this.time || this.timeRange)) {
|
||||||
|
|
|
||||||
|
|
@ -1,153 +0,0 @@
|
||||||
<template>
|
|
||||||
<!-- popup -->
|
|
||||||
<view>
|
|
||||||
<uni-popup ref="deliveryOrderPopup" type="bottom" @change="changePopup">
|
|
||||||
<view class="text-bold text-gray text-lg text-center left-top-sm-bar" data-popup="deliveryOrderPopup" @click="closePopup"><text
|
|
||||||
class="cuIcon-close"></text></view>
|
|
||||||
<view class="bg-white padding" style="padding-top: 74rpx; min-height: 1000rpx;">
|
|
||||||
<view class="text-xxl text-center">交货记录</view>
|
|
||||||
<view class="text-lg text-left">上传交货照片(非必填):</view>
|
|
||||||
<view>
|
|
||||||
<div class="grid col-3 grid-square">
|
|
||||||
<view class="bg-img" v-for="(item,index) in imgList" :key="index"
|
|
||||||
@tap="viewImage($event, imgList)" :data-url="item">
|
|
||||||
<image :src="item" mode="aspectFill"></image>
|
|
||||||
<view class="cu-tag bg-red" @tap.stop="delImg($event, imgList)" :data-index="index">
|
|
||||||
<text class='cuIcon-close'></text>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="solids" @tap="chooseImage" v-if="imgList.length < 6">
|
|
||||||
<text class='cuIcon-cameraadd'></text>
|
|
||||||
</view>
|
|
||||||
</div>
|
|
||||||
</view>
|
|
||||||
<view class="text-lg text-left">备注:</view>
|
|
||||||
<view style="margin-bottom: 10rpx;">
|
|
||||||
<textarea style="width: 100%;box-sizing: border-box;" class="custom-input radius-input" placeholder="温馨提示:服务过程中有分歧存在客诉隐患或未能及时处理彻底的,请急报说明情况,将由平台客服一起协调沟通,否则造成你有责任的客诉将不利于服务评价。" cols="30" rows="10" v-model="form.handoverRemark"></textarea>
|
|
||||||
</view>
|
|
||||||
<view class="cu-bar bg-white solid-top">
|
|
||||||
<view class="action margin-0 flex-sub text-black" @tap="closePopup">取消</view>
|
|
||||||
<view class="action margin-0 flex-sub text-main-color solid-left" @click="Submit">提交</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</uni-popup>
|
|
||||||
</view>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<script>
|
|
||||||
export default {
|
|
||||||
emits: ['confirmFeedback', 'close'],
|
|
||||||
props: {
|
|
||||||
show: {
|
|
||||||
type: Boolean,
|
|
||||||
default: false
|
|
||||||
},
|
|
||||||
data: {
|
|
||||||
type: Object,
|
|
||||||
default: () => {}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
watch: {
|
|
||||||
show: {
|
|
||||||
handler(newVal) {
|
|
||||||
if(newVal) {
|
|
||||||
this.$nextTick(() => {
|
|
||||||
this.$refs.deliveryOrderPopup.open()
|
|
||||||
})
|
|
||||||
}
|
|
||||||
},
|
|
||||||
immediate: true
|
|
||||||
}
|
|
||||||
},
|
|
||||||
data() {
|
|
||||||
return {
|
|
||||||
form: {
|
|
||||||
handoverRemark: '',
|
|
||||||
handoverImages: '',
|
|
||||||
},
|
|
||||||
imgList: [],
|
|
||||||
}
|
|
||||||
},
|
|
||||||
methods: {
|
|
||||||
chooseImage(e) {
|
|
||||||
uni.chooseMedia({
|
|
||||||
count: 1, //默认9
|
|
||||||
mediaType: ['image'],
|
|
||||||
sizeType: ['original', 'compressed'], //可以指定是原图还是压缩图,默认二者都有
|
|
||||||
sourceType: ['album'], //从相册选择
|
|
||||||
success: (res) => {
|
|
||||||
uni.showLoading({
|
|
||||||
title: '上传中',
|
|
||||||
mask: true
|
|
||||||
});
|
|
||||||
res.tempFiles.forEach((fileObj, index) => {
|
|
||||||
this.$request.uploadFile(fileObj.tempFilePath).then((url) => {
|
|
||||||
this.imgList.push(url);
|
|
||||||
if (index === res.tempFiles.length - 1) {
|
|
||||||
uni.hideLoading();
|
|
||||||
}
|
|
||||||
});
|
|
||||||
});
|
|
||||||
}
|
|
||||||
});
|
|
||||||
},
|
|
||||||
viewImage(e, imgList) {
|
|
||||||
uni.previewImage({
|
|
||||||
urls: imgList,
|
|
||||||
current: e.currentTarget.dataset.url
|
|
||||||
});
|
|
||||||
},
|
|
||||||
delImg(e, imgList) {
|
|
||||||
uni.showModal({
|
|
||||||
title: '',
|
|
||||||
content: '确定要删除这张图片吗?',
|
|
||||||
cancelText: '取消',
|
|
||||||
confirmText: '确定',
|
|
||||||
success: res => {
|
|
||||||
if (res.confirm) {
|
|
||||||
imgList.splice(e.currentTarget.dataset.index, 1)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
})
|
|
||||||
},
|
|
||||||
changePopup(e) {
|
|
||||||
console.log(e);
|
|
||||||
if(!e.show) {
|
|
||||||
this.closePopup()
|
|
||||||
}
|
|
||||||
},
|
|
||||||
closePopup() {
|
|
||||||
this.$emit('close')
|
|
||||||
},
|
|
||||||
async Submit() {
|
|
||||||
// 确定方法名
|
|
||||||
let reqFunName = "updateOrder", id;
|
|
||||||
if (this.data.orderDetailId == null) {
|
|
||||||
id = this.data.orderMasterId;
|
|
||||||
} else {
|
|
||||||
reqFunName = "updateDetailOrder";
|
|
||||||
id = this.data.orderDetailId;
|
|
||||||
}
|
|
||||||
const updateOrderParams = {
|
|
||||||
...this.form,
|
|
||||||
id: id,
|
|
||||||
handoverImages: this.imgList.length ? this.imgList.toString() : ''
|
|
||||||
}
|
|
||||||
|
|
||||||
let res = await this.$request[reqFunName](updateOrderParams);
|
|
||||||
if (res.code === 0) {
|
|
||||||
this.$emit('confirmFeedback')
|
|
||||||
} else {
|
|
||||||
uni.showToast({
|
|
||||||
title: '操作失败',
|
|
||||||
icon: 'none',
|
|
||||||
duration: 2000
|
|
||||||
})
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
</script>
|
|
||||||
|
|
||||||
<style>
|
|
||||||
</style>
|
|
||||||
|
|
@ -1,70 +0,0 @@
|
||||||
<template>
|
|
||||||
<view>
|
|
||||||
<!-- 模态框 -->
|
|
||||||
<view class="cu-modal" :class="show?'show':''">
|
|
||||||
<view class="cu-dialog">
|
|
||||||
<view class="padding-xl" style="text-align: left;">
|
|
||||||
<view class="text-bold text-lg margin-bottom-sm">本订单属指定保险全程保障的订单</view>
|
|
||||||
<view>1、本订单已打通保险系统,根据接单人员信息自动生效保险保单(立即生效)</view>
|
|
||||||
<view>2、确保上门人员与系统接单人员为同一人,便能成功将上门人员纳入保险系统承保。</view>
|
|
||||||
<view>3、接单后需派单下级人员 (或改派换人)下级需进系统接单,其保险方能生效! </view>
|
|
||||||
<view style="font-size: 15px;padding-top: 20rpx;">雇佣保险:{{data.insuranceManager.insuranceName}}<text class="text-main-color" style="margin-left: 20rpx;" @click="goInfo(data.insuranceManager.insuranceUrl)">详情条款</text></view>
|
|
||||||
<view style="padding-top: 20rpx;">
|
|
||||||
<checkbox style="transform:scale(0.6)" class="main-color" :checked="true" disabled>
|
|
||||||
</checkbox>
|
|
||||||
<text class="margin-left-xs">
|
|
||||||
<text class="text-red">如未按规则办理,心存侥幸,导致上门人员脱保将负全责!</text>
|
|
||||||
</text>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="cu-bar bg-white solid-top">
|
|
||||||
<view class="action margin-0 flex-sub text-main-color" data-modal="showAcceptOrderNoticeModal"
|
|
||||||
@click="hideModal">同意/确认</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<script>
|
|
||||||
export default {
|
|
||||||
name: 'acceptOrderNotice',
|
|
||||||
emits: ['close'],
|
|
||||||
props: {
|
|
||||||
show: {
|
|
||||||
type: Boolean,
|
|
||||||
default: false
|
|
||||||
},
|
|
||||||
data: {
|
|
||||||
type: Object,
|
|
||||||
default: () => {}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
data() {
|
|
||||||
return {
|
|
||||||
}
|
|
||||||
},
|
|
||||||
methods: {
|
|
||||||
hideModal() {
|
|
||||||
this.$emit('close');
|
|
||||||
},
|
|
||||||
goInfo(url) {
|
|
||||||
uni.setClipboardData({
|
|
||||||
data: url,
|
|
||||||
success: () => {
|
|
||||||
uni.showToast({
|
|
||||||
icon: 'none',
|
|
||||||
title: '链接已复制,请在浏览器打开'
|
|
||||||
});
|
|
||||||
},
|
|
||||||
fail(e) {
|
|
||||||
console.log(e);
|
|
||||||
}
|
|
||||||
});
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
</script>
|
|
||||||
|
|
||||||
<style>
|
|
||||||
</style>
|
|
||||||
|
|
@ -1,201 +0,0 @@
|
||||||
<template>
|
|
||||||
<view>
|
|
||||||
<!-- 模态框 -->
|
|
||||||
<view class="cu-modal" :class="show?'show':''">
|
|
||||||
<view class="cu-dialog">
|
|
||||||
<view class="padding-xl" style="text-align: left;" v-if="data.orderDetailId">
|
|
||||||
<view class="text-bold text-lg margin-bottom-sm">本订单属全程保险保障订单</view>
|
|
||||||
<view class="text-red" style="padding-bottom: 10rpx;">本单所有同行人员 (师傅/徒弟/随行),未在系统有账号的接单人员均需填写保险承保信息!
|
|
||||||
</view>
|
|
||||||
|
|
||||||
<view class="oneStaff solid-top" v-for="item in showList" :key="item.phone">
|
|
||||||
<view class="oneLine">
|
|
||||||
<view>
|
|
||||||
<text>同行人员姓名:</text>
|
|
||||||
<view style="margin-top: 10rpx">
|
|
||||||
{{item.name}}
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view>
|
|
||||||
<text>同行人员联系号码:</text>
|
|
||||||
<view style="margin-top: 10rpx">
|
|
||||||
{{item.phone}}
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view style="padding-top: 10rpx;">
|
|
||||||
<text>身份证号码:</text>
|
|
||||||
<view style="margin-top: 10rpx">
|
|
||||||
{{item.idCardNum}}
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="tag">保险已生效</view>
|
|
||||||
</view>
|
|
||||||
|
|
||||||
<view class="oneStaff solid-top">
|
|
||||||
<view class="oneLine">
|
|
||||||
<view>
|
|
||||||
<text>同行人员姓名:</text>
|
|
||||||
<view style="margin-top: 10rpx">
|
|
||||||
<input class="radius-input inline-input" type="text" placeholder="输入真实姓名"
|
|
||||||
v-model="oneData.name">
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view>
|
|
||||||
<text>同行人员联系号码:</text>
|
|
||||||
<view style="margin-top: 10rpx">
|
|
||||||
<input class="radius-input inline-input" type="text" placeholder="必须本人号码"
|
|
||||||
v-model="oneData.phone">
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view style="padding-top: 10rpx;">
|
|
||||||
<text>身份证号码:</text>
|
|
||||||
<view style="margin-top: 10rpx">
|
|
||||||
<input class="radius-input inline-input" type="text" placeholder="请输入身份证号码并反复确认无误"
|
|
||||||
v-model="oneData.idCardNum">
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view style="text-align: center;padding: 10rpx 0;">
|
|
||||||
<text class="text-main-color" @click="submitAdd">添加同行人员+</text>
|
|
||||||
</view>
|
|
||||||
<view style="padding-top: 20rpx;">
|
|
||||||
<checkbox style="transform:scale(0.6)" class="main-color" :checked="true" disabled>
|
|
||||||
</checkbox>
|
|
||||||
<text class="margin-left-xs">
|
|
||||||
<text class="text-red">未录入者/与订单无关者,一律不得上门。根据法律法规以上资料必须实真有效且无误方能被保险承保。</text>
|
|
||||||
</text>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
|
|
||||||
<view class="padding-xl" style="text-align: left;" v-else>
|
|
||||||
<view class="text-bold text-lg margin-bottom-sm">本订单属全程保险保障订单</view>
|
|
||||||
<view>本订单指定全程保险,但凡有随行人员均需录入增员信息,以纳入保险承保。排单后请在“待上门”或“进行中”状态点“保险增员”按键操作;订单指派下级人员的,下级接单人员亦可同样操作。</view>
|
|
||||||
</view>
|
|
||||||
<view class="cu-bar bg-white solid-top">
|
|
||||||
<view class="action margin-0 flex-sub text-main-color"
|
|
||||||
data-modal="showAcceptOrderNoticeModal" @click="hideModal">退出页面</view>
|
|
||||||
<!-- <view v-else class="action margin-0 flex-sub text-main-color"
|
|
||||||
data-modal="showAcceptOrderNoticeModal" @click="hideModal">我已知晓</view> -->
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<script>
|
|
||||||
import validRule from '@/common/js/validate.js'
|
|
||||||
export default {
|
|
||||||
name: 'acceptOrderNotice',
|
|
||||||
emits: ['close'],
|
|
||||||
props: {
|
|
||||||
show: {
|
|
||||||
type: Boolean,
|
|
||||||
default: false
|
|
||||||
},
|
|
||||||
data: {
|
|
||||||
type: Object,
|
|
||||||
default: () => {}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
data() {
|
|
||||||
return {
|
|
||||||
oneData: {
|
|
||||||
name: "",
|
|
||||||
phone: "",
|
|
||||||
idCardNum: ""
|
|
||||||
},
|
|
||||||
showList: []
|
|
||||||
}
|
|
||||||
},
|
|
||||||
methods: {
|
|
||||||
hideModal() {
|
|
||||||
this.$emit('close');
|
|
||||||
},
|
|
||||||
async initData() {
|
|
||||||
let res = await this.$request.insuranceUserList({
|
|
||||||
orderDetailId: this.data.orderDetailId
|
|
||||||
})
|
|
||||||
this.showList = res.rows
|
|
||||||
},
|
|
||||||
async submitAdd() {
|
|
||||||
if (!this.oneData.name) {
|
|
||||||
uni.showToast({
|
|
||||||
title: '请输入姓名',
|
|
||||||
icon: 'none',
|
|
||||||
duration: 2000
|
|
||||||
})
|
|
||||||
return
|
|
||||||
}
|
|
||||||
if (!validRule.validPhone(this.oneData.phone)) {
|
|
||||||
uni.showToast({
|
|
||||||
title: '请输入手机号码',
|
|
||||||
icon: 'none',
|
|
||||||
duration: 2000
|
|
||||||
})
|
|
||||||
return
|
|
||||||
}
|
|
||||||
if (!validRule.validIdCard(this.oneData.idCardNum)) {
|
|
||||||
uni.showToast({
|
|
||||||
title: '请输入正确的身份证号码',
|
|
||||||
icon: 'none',
|
|
||||||
duration: 2000
|
|
||||||
})
|
|
||||||
return
|
|
||||||
}
|
|
||||||
uni.showToast({
|
|
||||||
title: '保险生成中,可能需要几秒或最多三分钟,请等待!', // 要显示的文字
|
|
||||||
icon: 'none', // 设置图标为'none',只显示文字
|
|
||||||
duration: 10 * 60 * 1000,
|
|
||||||
});
|
|
||||||
// 510121198705063377
|
|
||||||
const res = await this.$request.insuranceUserAdd({
|
|
||||||
...this.oneData,
|
|
||||||
orderDetailId: this.data.orderDetailId
|
|
||||||
})
|
|
||||||
if (res.code === 0) {
|
|
||||||
uni.showToast({
|
|
||||||
title: '增员完毕,保险已生效',
|
|
||||||
icon: 'none',
|
|
||||||
duration: 2000
|
|
||||||
})
|
|
||||||
this.initData()
|
|
||||||
this.oneData = {
|
|
||||||
name: "",
|
|
||||||
phone: "",
|
|
||||||
idCardNum: ""
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
</script>
|
|
||||||
|
|
||||||
<style scoped>
|
|
||||||
.oneStaff {
|
|
||||||
padding: 20rpx 0;
|
|
||||||
position: relative;
|
|
||||||
}
|
|
||||||
|
|
||||||
.oneStaff .tag {
|
|
||||||
position: absolute;
|
|
||||||
right: 0;
|
|
||||||
bottom: 20rpx;
|
|
||||||
color: #0081ff;
|
|
||||||
}
|
|
||||||
|
|
||||||
.oneLine {
|
|
||||||
display: flex;
|
|
||||||
flex-direction: row;
|
|
||||||
gap: 10px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.oneLine>view {
|
|
||||||
flex: 1;
|
|
||||||
}
|
|
||||||
|
|
||||||
.oneLine text {
|
|
||||||
padding-bottom: 10rpx;
|
|
||||||
}
|
|
||||||
</style>
|
|
||||||
|
|
@ -1,114 +0,0 @@
|
||||||
<template>
|
|
||||||
<view>
|
|
||||||
<!-- 模态框 -->
|
|
||||||
<view class="cu-modal" :class="show?'show':''">
|
|
||||||
<view class="cu-dialog">
|
|
||||||
<view class="padding-xl" style="text-align: left;">
|
|
||||||
<view class="text-bold text-lg margin-bottom-sm">绑定本帐号保险人员信息</view>
|
|
||||||
<view class="text-red" style="padding-bottom: 10rpx;">请绑定本帐号操作者身份信息,用于含保险订单的保单投保 (自动实时投保)!
|
|
||||||
</view>
|
|
||||||
<view class="oneStaff solid-top">
|
|
||||||
<view>
|
|
||||||
<text>您的姓名:</text>
|
|
||||||
<view style="margin-top: 10rpx">
|
|
||||||
<input class="radius-input inline-input" type="text" placeholder="输入真实姓名"
|
|
||||||
v-model="oneData.certName">
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view style="padding-top: 10rpx;">
|
|
||||||
<text>身份证号码:</text>
|
|
||||||
<view style="margin-top: 10rpx">
|
|
||||||
<input class="radius-input inline-input" type="text" placeholder="请输入身份证号码并反复确认无误"
|
|
||||||
v-model="oneData.certNo">
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view style="padding-top: 20rpx;">
|
|
||||||
<checkbox style="transform:scale(0.6)" class="main-color" :checked="true" disabled>
|
|
||||||
</checkbox>
|
|
||||||
<text class="margin-left-xs">
|
|
||||||
<text class="text-red">各自在自己账号上绑定即可,在参与上门服务或客户作业服务过程中,操作订单时会自动对接保险系统!</text>
|
|
||||||
</text>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
|
|
||||||
<view class="cu-bar bg-white solid-top">
|
|
||||||
<view class="action margin-0 flex-sub text-main-color"
|
|
||||||
data-modal="showAcceptOrderNoticeModal" @click="submitAdd">确认资料</view>
|
|
||||||
<!-- <view v-else class="action margin-0 flex-sub text-main-color"
|
|
||||||
data-modal="showAcceptOrderNoticeModal" @click="hideModal">我已知晓</view> -->
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<script>
|
|
||||||
import validRule from '@/common/js/validate.js'
|
|
||||||
export default {
|
|
||||||
name: 'acceptOrderNotice',
|
|
||||||
emits: ['close', 'success'],
|
|
||||||
props: {
|
|
||||||
show: {
|
|
||||||
type: Boolean,
|
|
||||||
default: false
|
|
||||||
},
|
|
||||||
data: {
|
|
||||||
type: Object,
|
|
||||||
default: () => {}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
data() {
|
|
||||||
return {
|
|
||||||
oneData: {
|
|
||||||
certName: "",
|
|
||||||
certNo: ""
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
methods: {
|
|
||||||
hideModal() {
|
|
||||||
this.$emit('close');
|
|
||||||
},
|
|
||||||
async submitAdd() {
|
|
||||||
if (!this.oneData.certName) {
|
|
||||||
uni.showToast({
|
|
||||||
title: '请输入姓名',
|
|
||||||
icon: 'none',
|
|
||||||
duration: 2000
|
|
||||||
})
|
|
||||||
return
|
|
||||||
}
|
|
||||||
if (!validRule.validIdCard(this.oneData.certNo)) {
|
|
||||||
uni.showToast({
|
|
||||||
title: '请输入正确的身份证号码',
|
|
||||||
icon: 'none',
|
|
||||||
duration: 2000
|
|
||||||
})
|
|
||||||
return
|
|
||||||
}
|
|
||||||
this.$emit('success', this.oneData)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
</script>
|
|
||||||
|
|
||||||
<style scoped>
|
|
||||||
.oneStaff {
|
|
||||||
padding: 20rpx 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
.oneLine {
|
|
||||||
display: flex;
|
|
||||||
flex-direction: row;
|
|
||||||
gap: 10px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.oneLine>view {
|
|
||||||
flex: 1;
|
|
||||||
}
|
|
||||||
|
|
||||||
.oneLine text {
|
|
||||||
padding-bottom: 10rpx;
|
|
||||||
}
|
|
||||||
</style>
|
|
||||||
|
|
@ -21,15 +21,12 @@
|
||||||
<view>上门有加单,请客户支付</view>
|
<view>上门有加单,请客户支付</view>
|
||||||
<view class="flex justify-start margin-top-sm align-center">
|
<view class="flex justify-start margin-top-sm align-center">
|
||||||
<text>加单总额:</text>
|
<text>加单总额:</text>
|
||||||
<input class="radius-input inline-input" type="digit" :disabled="hadSetPriceChange" v-model="newPriceForA1"></input>
|
<input class="radius-input inline-input" type="digit" v-model="newPriceForA1"></input>
|
||||||
<text class="margin-left-xs">元</text>
|
<text class="margin-left-xs">元</text>
|
||||||
<template v-if="!hadSetPriceChange">
|
<view class="cu-btn line-main-color sm margin-left" v-if="priceObj && priceObj.type == 1"
|
||||||
<view class="cu-btn line-main-color sm margin-left"
|
@click="changeOrderPrice(newPriceForA1)">修改报价</view>
|
||||||
v-if="priceObj && priceObj.type == 1" @click="changeOrderPrice(newPriceForA1)">修改报价
|
|
||||||
</view>
|
|
||||||
<view class="cu-btn line-main-color sm margin-left" v-else
|
<view class="cu-btn line-main-color sm margin-left" v-else
|
||||||
@click="changeOrderPrice(newPriceForA1)">确认报价</view>
|
@click="changeOrderPrice(newPriceForA1)">确认报价</view>
|
||||||
</template>
|
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
@ -39,15 +36,12 @@
|
||||||
<view>上门报价类,给现场客户的报价</view>
|
<view>上门报价类,给现场客户的报价</view>
|
||||||
<view class="flex justify-start margin-top-sm align-center">
|
<view class="flex justify-start margin-top-sm align-center">
|
||||||
<text>报价总额:</text>
|
<text>报价总额:</text>
|
||||||
<input class="radius-input inline-input" type="digit" :disabled="hadSetPriceChange" v-model="newPriceForA2"></input>
|
<input class="radius-input inline-input" type="digit" v-model="newPriceForA2"></input>
|
||||||
<text class="margin-left-xs">元</text>
|
<text class="margin-left-xs">元</text>
|
||||||
<template v-if="!hadSetPriceChange">
|
<view class="cu-btn line-main-color sm margin-left" v-if="priceObj && priceObj.type == 2"
|
||||||
<view class="cu-btn line-main-color sm margin-left"
|
@click="changeOrderPrice(newPriceForA2)">修改报价</view>
|
||||||
v-if="priceObj && priceObj.type == 2" @click="changeOrderPrice(newPriceForA2)">修改报价
|
|
||||||
</view>
|
|
||||||
<view class="cu-btn line-main-color sm margin-left" v-else
|
<view class="cu-btn line-main-color sm margin-left" v-else
|
||||||
@click="changeOrderPrice(newPriceForA2)">确认报价</view>
|
@click="changeOrderPrice(newPriceForA2)">确认报价</view>
|
||||||
</template>
|
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
@ -57,28 +51,15 @@
|
||||||
v-model="remark" maxlength="-1"
|
v-model="remark" maxlength="-1"
|
||||||
placeholder="报价额需符合双方约定,并把关键内容附上。如保内维修XX含配件XXX等,分别XX元。如约定下单方寄配件,则订单内“申请配件发起”。"></textarea>
|
placeholder="报价额需符合双方约定,并把关键内容附上。如保内维修XX含配件XXX等,分别XX元。如约定下单方寄配件,则订单内“申请配件发起”。"></textarea>
|
||||||
</view>
|
</view>
|
||||||
<view class="cu-btn line-main-color margin-top-sm long-btn" v-if="priceObj" @click="clearCurAddedPrice">
|
<view class="cu-btn line-main-color margin-top-sm long-btn" v-if="priceObj" @click="clearCurAddedPrice">清空加价</view>
|
||||||
清空加价</view>
|
|
||||||
</view>
|
</view>
|
||||||
<view class="cu-bar bg-white solid-top">
|
<view class="cu-bar bg-white solid-top">
|
||||||
<view class="action margin-0 flex-sub text-black" data-modal="showNewServPriceOfflineModal"
|
<view class="action margin-0 flex-sub text-black" data-modal="showNewServPriceOfflineModal"
|
||||||
@click="hideModal">退出/再次上门</view>
|
@click="hideModal">退出/再次上门</view>
|
||||||
<!-- <view class="action margin-0 flex-sub text-black" data-modal="showNewServPriceOfflineModal"
|
<view class="action margin-0 flex-sub text-main-color solid-left" v-if="(priceObj && priceObj.payStatus === 0) || data.payStatus === 0"
|
||||||
@click="directlyFinish" v-if="data.consultMode === '01' && data.changeMoney != 0">直接完单</view> -->
|
|
||||||
<template v-if="data.consultMode === '01'">
|
|
||||||
<view class="action margin-0 flex-sub text-main-color solid-left"
|
|
||||||
v-if="(priceObj && priceObj.payStatus === 0) || data.changeMoney != 0"
|
|
||||||
data-modal="showPayQrcodeModal" @tap="makePayQrcode($event)">请客户支付</view>
|
data-modal="showPayQrcodeModal" @tap="makePayQrcode($event)">请客户支付</view>
|
||||||
<view class="action margin-0 flex-sub text-main-color solid-left"
|
<view class="action margin-0 flex-sub text-main-color solid-left"
|
||||||
data-modal="showNewServPriceOnlineModal" @tap="hideModal" @click="goFinishOrder" v-else>去完单</view>
|
data-modal="showNewServPriceOfflineModal" @tap="hideModal" @click="goFinishOrder" v-else>去完单</view>
|
||||||
</template>
|
|
||||||
<template v-else>
|
|
||||||
<view class="action margin-0 flex-sub text-main-color solid-left"
|
|
||||||
v-if="(priceObj && priceObj.payStatus === 0) || data.payStatus === 0"
|
|
||||||
data-modal="showPayQrcodeModal" @tap="makePayQrcode($event)">请客户支付</view>
|
|
||||||
<view class="action margin-0 flex-sub text-main-color solid-left"
|
|
||||||
data-modal="showNewServPriceOnlineModal" @tap="hideModal" @click="goFinishOrder" v-else>去完单</view>
|
|
||||||
</template>
|
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<pay-qrcode ref="payQrcode" :show="showPayQrcodeModal" :data="data" @finishQrPay="finishQrPay"></pay-qrcode>
|
<pay-qrcode ref="payQrcode" :show="showPayQrcodeModal" :data="data" @finishQrPay="finishQrPay"></pay-qrcode>
|
||||||
|
|
@ -100,7 +81,7 @@
|
||||||
},
|
},
|
||||||
data: {
|
data: {
|
||||||
type: Object,
|
type: Object,
|
||||||
default: () => {}
|
default: {}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
|
|
@ -111,8 +92,7 @@
|
||||||
newPriceForA1: null,
|
newPriceForA1: null,
|
||||||
newPrice: null,
|
newPrice: null,
|
||||||
showPayQrcodeModal: false,
|
showPayQrcodeModal: false,
|
||||||
remark: "",
|
remark: ""
|
||||||
hadSetPriceChange: false
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
|
@ -126,13 +106,10 @@
|
||||||
this.payAction = priceObj.type;
|
this.payAction = priceObj.type;
|
||||||
let money = priceObj.changeMoney;
|
let money = priceObj.changeMoney;
|
||||||
if (this.payAction === 1) {
|
if (this.payAction === 1) {
|
||||||
this.newPriceForA1 = money + (this.priceObj.attachmentMoney || 0);
|
this.newPriceForA1 = money;
|
||||||
} else if (this.payAction === 2) {
|
} else if (this.payAction === 2) {
|
||||||
this.newPriceForA2 = money;
|
this.newPriceForA2 = money;
|
||||||
}
|
}
|
||||||
this.hadSetPriceChange = true
|
|
||||||
} else {
|
|
||||||
this.hadSetPriceChange = false
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
resetData() {
|
resetData() {
|
||||||
|
|
@ -145,7 +122,7 @@
|
||||||
},
|
},
|
||||||
hideModal(e) {
|
hideModal(e) {
|
||||||
this.resetData();
|
this.resetData();
|
||||||
this.$emit('close', e);
|
uni.$emit(this.$globalFun.HIDE_MODAL, e);
|
||||||
},
|
},
|
||||||
async resetPriceChangedInfo() {
|
async resetPriceChangedInfo() {
|
||||||
let res = await this.$request.getChangeOrderPrice(this.data);
|
let res = await this.$request.getChangeOrderPrice(this.data);
|
||||||
|
|
@ -155,7 +132,6 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
changePayAction(payAction) {
|
changePayAction(payAction) {
|
||||||
if(this.hadSetPriceChange) return
|
|
||||||
this.payAction = payAction;
|
this.payAction = payAction;
|
||||||
},
|
},
|
||||||
async changeOrderPrice(newPrice) {
|
async changeOrderPrice(newPrice) {
|
||||||
|
|
@ -184,19 +160,6 @@
|
||||||
}, 1500);
|
}, 1500);
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
async directlyFinish(e) {
|
|
||||||
let res = await this.$request.editOrder({
|
|
||||||
id: this.data.orderDetailId,
|
|
||||||
orderStatus: 5
|
|
||||||
});
|
|
||||||
if (res && res.code === 0) {
|
|
||||||
uni.showToast({
|
|
||||||
icon: 'success',
|
|
||||||
title: '操作成功'
|
|
||||||
})
|
|
||||||
this.hideModal(e)
|
|
||||||
}
|
|
||||||
},
|
|
||||||
async makePayQrcode(e) {
|
async makePayQrcode(e) {
|
||||||
let res = await this.$request.priceAddedQrPay(this.data);
|
let res = await this.$request.priceAddedQrPay(this.data);
|
||||||
if (res && res.code === 0) {
|
if (res && res.code === 0) {
|
||||||
|
|
@ -211,13 +174,8 @@
|
||||||
goFinishOrder() {
|
goFinishOrder() {
|
||||||
this.$emit('finishOrder', this.data);
|
this.$emit('finishOrder', this.data);
|
||||||
},
|
},
|
||||||
async clearCurAddedPrice() {
|
clearCurAddedPrice() {
|
||||||
if(this.priceObj.attachmentMoney) {
|
this.changeOrderPrice(0);
|
||||||
await this.$request.deleteAttachPrice({
|
|
||||||
orderDetailId: this.data.orderDetailId
|
|
||||||
})
|
|
||||||
}
|
|
||||||
this.changeOrderPrice(0)
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -21,14 +21,12 @@
|
||||||
<view>上门有加单,请客户支付</view>
|
<view>上门有加单,请客户支付</view>
|
||||||
<view class="flex justify-start margin-top-sm align-center">
|
<view class="flex justify-start margin-top-sm align-center">
|
||||||
<text>加单总额:</text>
|
<text>加单总额:</text>
|
||||||
<input class="radius-input inline-input" type="digit" :disabled="hadSetPriceChange" v-model="newPriceForA1"></input>
|
<input class="radius-input inline-input" type="digit" v-model="newPriceForA1"></input>
|
||||||
<text class="margin-left-xs">元</text>
|
<text class="margin-left-xs">元</text>
|
||||||
<template v-if="!hadSetPriceChange">
|
|
||||||
<view class="cu-btn line-main-color sm margin-left" v-if="priceObj && priceObj.type == 1"
|
<view class="cu-btn line-main-color sm margin-left" v-if="priceObj && priceObj.type == 1"
|
||||||
@click="changeOrderPrice(newPriceForA1)">修改报价</view>
|
@click="changeOrderPrice(newPriceForA1)">修改报价</view>
|
||||||
<view class="cu-btn line-main-color sm margin-left" v-else
|
<view class="cu-btn line-main-color sm margin-left" v-else
|
||||||
@click="changeOrderPrice(newPriceForA1)">确认报价</view>
|
@click="changeOrderPrice(newPriceForA1)">确认报价</view>
|
||||||
</template>
|
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
@ -38,14 +36,12 @@
|
||||||
<view>上门报价类,给下单方报价</view>
|
<view>上门报价类,给下单方报价</view>
|
||||||
<view class="flex justify-start margin-top-sm align-center">
|
<view class="flex justify-start margin-top-sm align-center">
|
||||||
<text>报价总额:</text>
|
<text>报价总额:</text>
|
||||||
<input class="radius-input inline-input" type="digit" :disabled="hadSetPriceChange" v-model="newPriceForA2"></input>
|
<input class="radius-input inline-input" type="digit" v-model="newPriceForA2"></input>
|
||||||
<text class="margin-left-xs">元</text>
|
<text class="margin-left-xs">元</text>
|
||||||
<template v-if="!hadSetPriceChange">
|
|
||||||
<view class="cu-btn line-main-color sm margin-left" v-if="priceObj && priceObj.type == 2"
|
<view class="cu-btn line-main-color sm margin-left" v-if="priceObj && priceObj.type == 2"
|
||||||
@click="changeOrderPrice(newPriceForA2)">修改报价</view>
|
@click="changeOrderPrice(newPriceForA2)">修改报价</view>
|
||||||
<view class="cu-btn line-main-color sm margin-left" v-else
|
<view class="cu-btn line-main-color sm margin-left" v-else
|
||||||
@click="changeOrderPrice(newPriceForA2)">确认报价</view>
|
@click="changeOrderPrice(newPriceForA2)">确认报价</view>
|
||||||
</template>
|
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
@ -60,22 +56,10 @@
|
||||||
<view class="cu-bar bg-white solid-top">
|
<view class="cu-bar bg-white solid-top">
|
||||||
<view class="action margin-0 flex-sub text-black" data-modal="showNewServPriceOnlineModal"
|
<view class="action margin-0 flex-sub text-black" data-modal="showNewServPriceOnlineModal"
|
||||||
@click="hideModal">退出/再次上门</view>
|
@click="hideModal">退出/再次上门</view>
|
||||||
<!-- <view class="action margin-0 flex-sub text-black" data-modal="showNewServPriceOfflineModal"
|
<view class="action margin-0 flex-sub text-main-color solid-left" v-if="(priceObj && priceObj.payStatus === 0) || data.payStatus === 0"
|
||||||
@click="directlyFinish" v-if="data.consultMode === '01'">直接完单</view> -->
|
|
||||||
<template v-if="data.consultMode === '01'">
|
|
||||||
<view class="action margin-0 flex-sub text-main-color solid-left"
|
|
||||||
v-if="(priceObj && priceObj.payStatus === 0) || data.changeMoney != 0"
|
|
||||||
data-modal="showPayQrcodeModal" @tap="makePayQrcode($event)">请客户支付</view>
|
data-modal="showPayQrcodeModal" @tap="makePayQrcode($event)">请客户支付</view>
|
||||||
<view class="action margin-0 flex-sub text-main-color solid-left"
|
<view class="action margin-0 flex-sub text-main-color solid-left"
|
||||||
data-modal="showNewServPriceOnlineModal" @tap="hideModal" @click="goFinishOrder" v-else>去完单</view>
|
data-modal="showNewServPriceOnlineModal" @tap="hideModal" @click="goFinishOrder" v-else>去完单</view>
|
||||||
</template>
|
|
||||||
<template v-else>
|
|
||||||
<view class="action margin-0 flex-sub text-main-color solid-left"
|
|
||||||
v-if="(priceObj && priceObj.payStatus === 0) || data.payStatus === 0"
|
|
||||||
data-modal="showPayQrcodeModal" @tap="makePayQrcode($event)">请客户支付</view>
|
|
||||||
<view class="action margin-0 flex-sub text-main-color solid-left"
|
|
||||||
data-modal="showNewServPriceOnlineModal" @tap="hideModal" @click="goFinishOrder" v-else>去完单</view>
|
|
||||||
</template>
|
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<pay-qrcode ref="payQrcode" :show="showPayQrcodeModal" :data="data" @finishQrPay="finishQrPay"></pay-qrcode>
|
<pay-qrcode ref="payQrcode" :show="showPayQrcodeModal" :data="data" @finishQrPay="finishQrPay"></pay-qrcode>
|
||||||
|
|
@ -97,7 +81,7 @@
|
||||||
},
|
},
|
||||||
data: {
|
data: {
|
||||||
type: Object,
|
type: Object,
|
||||||
default: () => {}
|
default: {}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
|
|
@ -108,8 +92,7 @@
|
||||||
newPriceForA1: null,
|
newPriceForA1: null,
|
||||||
newPrice: null,
|
newPrice: null,
|
||||||
showPayQrcodeModal: false,
|
showPayQrcodeModal: false,
|
||||||
remark: "",
|
remark: ""
|
||||||
hadSetPriceChange: false
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
|
@ -123,15 +106,11 @@
|
||||||
this.payAction = priceObj.type;
|
this.payAction = priceObj.type;
|
||||||
let money = priceObj.changeMoney;
|
let money = priceObj.changeMoney;
|
||||||
if (this.payAction === 1) {
|
if (this.payAction === 1) {
|
||||||
this.newPriceForA1 = money + (this.priceObj.attachmentMoney || 0);
|
this.newPriceForA1 = money;
|
||||||
} else if (this.payAction === 2) {
|
} else if (this.payAction === 2) {
|
||||||
this.newPriceForA2 = money;
|
this.newPriceForA2 = money;
|
||||||
}
|
}
|
||||||
this.hadSetPriceChange = true
|
|
||||||
} else {
|
|
||||||
this.hadSetPriceChange = false
|
|
||||||
}
|
}
|
||||||
console.log(this.hadSetPriceChange);
|
|
||||||
},
|
},
|
||||||
resetData() {
|
resetData() {
|
||||||
this.payAction = 0;
|
this.payAction = 0;
|
||||||
|
|
@ -143,7 +122,7 @@
|
||||||
},
|
},
|
||||||
hideModal(e) {
|
hideModal(e) {
|
||||||
this.resetData();
|
this.resetData();
|
||||||
this.$emit('close', e);
|
uni.$emit(this.$globalFun.HIDE_MODAL, e);
|
||||||
},
|
},
|
||||||
async resetPriceChangedInfo() {
|
async resetPriceChangedInfo() {
|
||||||
let res = await this.$request.getChangeOrderPrice(this.data);
|
let res = await this.$request.getChangeOrderPrice(this.data);
|
||||||
|
|
@ -153,22 +132,8 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
changePayAction(payAction) {
|
changePayAction(payAction) {
|
||||||
if(this.hadSetPriceChange) return
|
|
||||||
this.payAction = payAction;
|
this.payAction = payAction;
|
||||||
},
|
},
|
||||||
async directlyFinish(e) {
|
|
||||||
let res = await this.$request.editOrder({
|
|
||||||
id: this.data.orderDetailId,
|
|
||||||
orderStatus: 5
|
|
||||||
});
|
|
||||||
if (res && res.code === 0) {
|
|
||||||
uni.showToast({
|
|
||||||
icon: 'success',
|
|
||||||
title: '操作成功'
|
|
||||||
})
|
|
||||||
this.hideModal(e)
|
|
||||||
}
|
|
||||||
},
|
|
||||||
async changeOrderPrice(newPrice) {
|
async changeOrderPrice(newPrice) {
|
||||||
if (this.priceObj && this.payAction != this.priceObj.type) {
|
if (this.priceObj && this.payAction != this.priceObj.type) {
|
||||||
uni.showToast({
|
uni.showToast({
|
||||||
|
|
@ -185,7 +150,6 @@
|
||||||
type: this.payAction,
|
type: this.payAction,
|
||||||
remark: this.remark
|
remark: this.remark
|
||||||
});
|
});
|
||||||
|
|
||||||
if (res && res.code === 0) {
|
if (res && res.code === 0) {
|
||||||
uni.showToast({
|
uni.showToast({
|
||||||
icon: 'success',
|
icon: 'success',
|
||||||
|
|
@ -210,13 +174,8 @@
|
||||||
goFinishOrder() {
|
goFinishOrder() {
|
||||||
this.$emit('finishOrder', this.data);
|
this.$emit('finishOrder', this.data);
|
||||||
},
|
},
|
||||||
async clearCurAddedPrice() {
|
clearCurAddedPrice() {
|
||||||
if(this.priceObj.attachmentMoney) {
|
this.changeOrderPrice(0);
|
||||||
await this.$request.deleteAttachPrice({
|
|
||||||
orderDetailId: this.data.orderDetailId
|
|
||||||
})
|
|
||||||
}
|
|
||||||
this.changeOrderPrice(0)
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -38,7 +38,7 @@
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: 'onDoorImmediately',
|
name: 'onDoorImmediately',
|
||||||
emits: ['confirmFeedback', 'close'],
|
emits: ['confirmFeedback'],
|
||||||
props: {
|
props: {
|
||||||
show: {
|
show: {
|
||||||
type: Boolean,
|
type: Boolean,
|
||||||
|
|
@ -46,7 +46,7 @@
|
||||||
},
|
},
|
||||||
data: {
|
data: {
|
||||||
type: Object,
|
type: Object,
|
||||||
default: () => {}
|
default: {}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
components: {
|
components: {
|
||||||
|
|
@ -59,17 +59,12 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
hideModal() {
|
hideModal(e) {
|
||||||
this.$emit('close');
|
uni.$emit(this.$globalFun.HIDE_MODAL, e);
|
||||||
},
|
},
|
||||||
minChange(e) {
|
minChange(e) {
|
||||||
this.waitMin = this.minList[e.detail.value];
|
this.waitMin = this.minList[e.detail.value];
|
||||||
},
|
},
|
||||||
// 添加操作节点
|
|
||||||
async addOrderOperate(params = {}) {
|
|
||||||
let res = await this.$request.addOrderOperate(params);
|
|
||||||
return res;
|
|
||||||
},
|
|
||||||
async workBegin(e) {
|
async workBegin(e) {
|
||||||
let order = this.data;
|
let order = this.data;
|
||||||
let curDate = new Date();
|
let curDate = new Date();
|
||||||
|
|
@ -87,11 +82,6 @@
|
||||||
icon: 'success',
|
icon: 'success',
|
||||||
duration: 1000
|
duration: 1000
|
||||||
})
|
})
|
||||||
this.addOrderOperate({
|
|
||||||
orderId: order.orderDetailId,
|
|
||||||
orderType: '02',
|
|
||||||
content: '师傅上门'
|
|
||||||
})
|
|
||||||
this.hideModal(e);
|
this.hideModal(e);
|
||||||
this.$emit('confirmFeedback');
|
this.$emit('confirmFeedback');
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,154 +0,0 @@
|
||||||
<template>
|
|
||||||
<!-- popup -->
|
|
||||||
<view>
|
|
||||||
<uni-popup ref="reFinishPopup" type="bottom" @change="changePopup">
|
|
||||||
<view class="text-bold text-gray text-lg text-center left-top-sm-bar" data-popup="reFinishPopup" @click="closePopup"><text
|
|
||||||
class="cuIcon-close"></text></view>
|
|
||||||
<view class="bg-white padding" style="padding-top: 74rpx; min-height: 1000rpx;">
|
|
||||||
<view class="text-xxl text-center">上门重做补做提交</view>
|
|
||||||
<view class="text-lg text-left">本次售后必须确认已与客户协商一致,并已处理到位,严禁出现再次客诉!现提交给客户验收并结单?</view>
|
|
||||||
<view>
|
|
||||||
<div class="grid col-3 grid-square">
|
|
||||||
<view class="bg-img" v-for="(item,index) in imgList" :key="index"
|
|
||||||
@tap="viewImage($event, imgList)" :data-url="item">
|
|
||||||
<image :src="item" mode="aspectFill"></image>
|
|
||||||
<view class="cu-tag bg-red" @tap.stop="delImg($event, imgList)" :data-index="index">
|
|
||||||
<text class='cuIcon-close'></text>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="solids" @tap="chooseImage" v-if="imgList.length < 6">
|
|
||||||
<text class='cuIcon-cameraadd'></text>
|
|
||||||
</view>
|
|
||||||
</div>
|
|
||||||
</view>
|
|
||||||
<view style="margin-bottom: 10rpx;">
|
|
||||||
<textarea style="width: 100%;box-sizing: border-box;" class="custom-input radius-input" placeholder="请输入理由或备注" cols="30" rows="10" v-model="form.redoCompleteRemark"></textarea>
|
|
||||||
</view>
|
|
||||||
<view class="cu-bar bg-white solid-top">
|
|
||||||
<view class="action margin-0 flex-sub text-black" @tap="closePopup">取消</view>
|
|
||||||
<view class="action margin-0 flex-sub text-main-color solid-left" @click="Submit">确认</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</uni-popup>
|
|
||||||
</view>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<script>
|
|
||||||
export default {
|
|
||||||
emits: ['confirmFeedback', 'close'],
|
|
||||||
props: {
|
|
||||||
show: {
|
|
||||||
type: Boolean,
|
|
||||||
default: false
|
|
||||||
},
|
|
||||||
curOrder: {
|
|
||||||
type: Object,
|
|
||||||
default: () => {}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
watch: {
|
|
||||||
show: {
|
|
||||||
handler(newVal) {
|
|
||||||
if(newVal) {
|
|
||||||
this.$nextTick(() => {
|
|
||||||
this.$refs.reFinishPopup.open()
|
|
||||||
})
|
|
||||||
}
|
|
||||||
},
|
|
||||||
immediate: true
|
|
||||||
}
|
|
||||||
},
|
|
||||||
data() {
|
|
||||||
return {
|
|
||||||
form: {
|
|
||||||
redoCompleteRemark: '',
|
|
||||||
redoCompleteImages: '',
|
|
||||||
},
|
|
||||||
imgList: [],
|
|
||||||
}
|
|
||||||
},
|
|
||||||
methods: {
|
|
||||||
chooseImage(e) {
|
|
||||||
uni.chooseMedia({
|
|
||||||
count: 1, //默认9
|
|
||||||
mediaType: ['image'],
|
|
||||||
sizeType: ['original', 'compressed'], //可以指定是原图还是压缩图,默认二者都有
|
|
||||||
sourceType: ['album'], //从相册选择
|
|
||||||
success: (res) => {
|
|
||||||
uni.showLoading({
|
|
||||||
title: '上传中',
|
|
||||||
mask: true
|
|
||||||
});
|
|
||||||
res.tempFiles.forEach((fileObj, index) => {
|
|
||||||
this.$request.uploadFile(fileObj.tempFilePath).then((url) => {
|
|
||||||
this.imgList.push(url);
|
|
||||||
if (index === res.tempFiles.length - 1) {
|
|
||||||
uni.hideLoading();
|
|
||||||
}
|
|
||||||
});
|
|
||||||
});
|
|
||||||
}
|
|
||||||
});
|
|
||||||
},
|
|
||||||
viewImage(e, imgList) {
|
|
||||||
uni.previewImage({
|
|
||||||
urls: imgList,
|
|
||||||
current: e.currentTarget.dataset.url
|
|
||||||
});
|
|
||||||
},
|
|
||||||
delImg(e, imgList) {
|
|
||||||
uni.showModal({
|
|
||||||
title: '',
|
|
||||||
content: '确定要删除这张图片吗?',
|
|
||||||
cancelText: '取消',
|
|
||||||
confirmText: '确定',
|
|
||||||
success: res => {
|
|
||||||
if (res.confirm) {
|
|
||||||
imgList.splice(e.currentTarget.dataset.index, 1)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
})
|
|
||||||
},
|
|
||||||
changePopup(e) {
|
|
||||||
console.log(e);
|
|
||||||
if(!e.show) {
|
|
||||||
this.closePopup()
|
|
||||||
}
|
|
||||||
},
|
|
||||||
closePopup() {
|
|
||||||
this.$emit('close')
|
|
||||||
},
|
|
||||||
changeRadio(e) {
|
|
||||||
this.form.deliveryType = e.target.value
|
|
||||||
},
|
|
||||||
async Submit() {
|
|
||||||
const updateOrderParams = {
|
|
||||||
id: this.curOrder.afterServiceRecordList[0].id,
|
|
||||||
workerFeedbackResult: 3,
|
|
||||||
redoCompleteRemark: this.form.redoCompleteRemark,
|
|
||||||
redoCompleteImages: this.imgList.length ? this.imgList.toString() : ''
|
|
||||||
}
|
|
||||||
|
|
||||||
let res = await this.$request.editAfterServiceRecord(updateOrderParams)
|
|
||||||
|
|
||||||
if (res.code === 0) {
|
|
||||||
uni.showToast({
|
|
||||||
icon: 'success',
|
|
||||||
title: '提交成功',
|
|
||||||
duration: 1000
|
|
||||||
})
|
|
||||||
this.$emit('confirmFeedback')
|
|
||||||
} else {
|
|
||||||
uni.showToast({
|
|
||||||
title: '操作失败',
|
|
||||||
icon: 'none',
|
|
||||||
duration: 2000
|
|
||||||
})
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
</script>
|
|
||||||
|
|
||||||
<style>
|
|
||||||
</style>
|
|
||||||
|
|
@ -10,7 +10,7 @@
|
||||||
<view class="padding text-left">
|
<view class="padding text-left">
|
||||||
<view>
|
<view>
|
||||||
<view class="flex justify-start">
|
<view class="flex justify-start">
|
||||||
<view><text class="text-red">*</text>原因选择:</view>
|
<view>原因选择:</view>
|
||||||
<radio-group @change="changeReasonRadio">
|
<radio-group @change="changeReasonRadio">
|
||||||
<label class="radio margin-right-sm">
|
<label class="radio margin-right-sm">
|
||||||
<radio style="transform:scale(0.7)" class="main-color" value="1" :checked="data.reasonType === 1"/>
|
<radio style="transform:scale(0.7)" class="main-color" value="1" :checked="data.reasonType === 1"/>
|
||||||
|
|
@ -29,7 +29,7 @@
|
||||||
<view class="margin-top">
|
<view class="margin-top">
|
||||||
<textarea style="width: 100%; height: 200rpx;" class="solid radius text-left padding-sm"
|
<textarea style="width: 100%; height: 200rpx;" class="solid radius text-left padding-sm"
|
||||||
v-model="remark" maxlength="-1"
|
v-model="remark" maxlength="-1"
|
||||||
placeholder="拒绝原因:发生纠纷,建议了解清楚客户诉求,积极协商和平处理(让客户撤单更佳)。否则升级重大客诉可能被平台处罚!确实属客户问题且无法协商请输入具体情况!"></textarea>
|
placeholder="请输入具体原因或直接同意,更改到帐金额需与客户协商一致,否则可能被拒绝或引起客诉升级"></textarea>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<!-- 上传图片 -->
|
<!-- 上传图片 -->
|
||||||
|
|
@ -42,7 +42,7 @@
|
||||||
<text class='cuIcon-close'></text>
|
<text class='cuIcon-close'></text>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="solids" @click.stop="chooseImgList(e, imgList)" v-if="imgList.length < 3">
|
<view class="solids" @tap="chooseImgList(e, imgList)" v-if="imgList.length < 3">
|
||||||
<text class='cuIcon-cameraadd'></text>
|
<text class='cuIcon-cameraadd'></text>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
@ -67,7 +67,7 @@
|
||||||
},
|
},
|
||||||
data: {
|
data: {
|
||||||
type: Object,
|
type: Object,
|
||||||
default: () => {}
|
default: {}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
|
|
@ -80,7 +80,7 @@
|
||||||
methods: {
|
methods: {
|
||||||
hideModal(e) {
|
hideModal(e) {
|
||||||
this.resetData();
|
this.resetData();
|
||||||
this.$emit('close', e);
|
uni.$emit(this.$globalFun.HIDE_MODAL, e);
|
||||||
},
|
},
|
||||||
resetData() {
|
resetData() {
|
||||||
this.data = null;
|
this.data = null;
|
||||||
|
|
@ -91,9 +91,8 @@
|
||||||
this.reasonType = e.detail.value;
|
this.reasonType = e.detail.value;
|
||||||
},
|
},
|
||||||
chooseImgList(e, imgList) {
|
chooseImgList(e, imgList) {
|
||||||
uni.chooseMedia({
|
uni.chooseImage({
|
||||||
count: 3 - imgList.length, //默认9
|
count: 3 - imgList.length, //默认9
|
||||||
mediaType: ['image'],
|
|
||||||
sizeType: ['original', 'compressed'], //可以指定是原图还是压缩图,默认二者都有
|
sizeType: ['original', 'compressed'], //可以指定是原图还是压缩图,默认二者都有
|
||||||
sourceType: ['album'], //从相册选择
|
sourceType: ['album'], //从相册选择
|
||||||
success: (res) => {
|
success: (res) => {
|
||||||
|
|
@ -101,10 +100,10 @@
|
||||||
title: '上传中',
|
title: '上传中',
|
||||||
mask: true
|
mask: true
|
||||||
});
|
});
|
||||||
res.tempFiles.forEach((fileObj, index) => {
|
res.tempFilePaths.forEach((tmpUrl, index) => {
|
||||||
this.$request.uploadFile(fileObj.tempFilePath).then((url) => {
|
this.$request.uploadFile(tmpUrl).then((url) => {
|
||||||
imgList.push(url);
|
imgList.push(url);
|
||||||
if (index === res.tempFiles.length - 1) {
|
if (index === res.tempFilePaths.length - 1) {
|
||||||
uni.hideLoading();
|
uni.hideLoading();
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
@ -132,20 +131,19 @@
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
async submit(e) {
|
async submit(e) {
|
||||||
if(!this.remark) {
|
let imgObjList = [];
|
||||||
uni.showToast({
|
this.imgList.forEach(url => {
|
||||||
icon: 'none',
|
imgObjList.push({
|
||||||
duration: 3000,
|
imgUrl: url,
|
||||||
title: '请输入拒绝原因'
|
imgUploadBy: 2
|
||||||
|
})
|
||||||
})
|
})
|
||||||
return
|
|
||||||
}
|
|
||||||
let res = await this.$request.editAfterServiceRecord({
|
let res = await this.$request.editAfterServiceRecord({
|
||||||
id: this.data.afterServiceRecordList[0].id,
|
id: this.data.afterServiceRecordList[0].id,
|
||||||
workerFeedbackReasonType: this.reasonType,
|
workerFeedbackReasonType: this.reasonType,
|
||||||
workerFeedbackReason: this.remark,
|
workerFeedbackReason: this.remark,
|
||||||
workerFeedbackResult: 0,
|
workerFeedbackResult: 0,
|
||||||
workerFeedbackImages: this.imgList.length ? this.imgList.toString() : '',
|
imgsList: imgObjList,
|
||||||
updateBy: 2
|
updateBy: 2
|
||||||
});
|
});
|
||||||
if (res && res.code === 0) {
|
if (res && res.code === 0) {
|
||||||
|
|
|
||||||
|
|
@ -1,54 +0,0 @@
|
||||||
<template>
|
|
||||||
<view>
|
|
||||||
<!-- 模态框 -->
|
|
||||||
<view class="cu-modal" :class="show?'show':''">
|
|
||||||
<view class="cu-dialog">
|
|
||||||
<view class="padding-xl" style="background-color: #ffffff;">
|
|
||||||
<view class="text-bold text-lg margin-bottom-sm">任务进度</view>
|
|
||||||
|
|
||||||
<view class="cu-timeline">
|
|
||||||
<view class="cu-item text-main-color" v-for="(item, index) in arr" :key="index">
|
|
||||||
<view class="content shadow-blur" style="text-align: left;padding: 15upx 20upx;">
|
|
||||||
<view><text style="color: black;">{{item.content}}</text></view>
|
|
||||||
<text style="color: #999999;font-size: 24upx;">{{item.createTime}}</text>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="cu-bar bg-white solid-top">
|
|
||||||
<view class="action margin-0 flex-sub text-black solid-left" data-modal="taskProcessDetail"
|
|
||||||
@tap="hideModal">关闭</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<script>
|
|
||||||
export default {
|
|
||||||
name: 'taskProcessDetail',
|
|
||||||
emits: ['confirmFeedback'],
|
|
||||||
props: {
|
|
||||||
show: {
|
|
||||||
type: Boolean,
|
|
||||||
default: false
|
|
||||||
},
|
|
||||||
arr: {
|
|
||||||
type: Array,
|
|
||||||
default: () => []
|
|
||||||
}
|
|
||||||
},
|
|
||||||
data() {
|
|
||||||
return {
|
|
||||||
}
|
|
||||||
},
|
|
||||||
methods: {
|
|
||||||
hideModal(e) {
|
|
||||||
this.$emit('close', e);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
</script>
|
|
||||||
|
|
||||||
<style>
|
|
||||||
</style>
|
|
||||||
|
|
@ -64,7 +64,7 @@
|
||||||
},
|
},
|
||||||
data: {
|
data: {
|
||||||
type: Object,
|
type: Object,
|
||||||
default: () => {}
|
default: {}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
|
|
@ -76,23 +76,18 @@
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
hideModal(e) {
|
hideModal(e) {
|
||||||
this.$emit('close', e);
|
uni.$emit(this.$globalFun.HIDE_MODAL, e);
|
||||||
},
|
},
|
||||||
chooseImage(e) {
|
chooseImage(e) {
|
||||||
uni.chooseMedia({
|
uni.chooseImage({
|
||||||
count: 1, //默认9
|
count: 1, //默认9
|
||||||
mediaType: ['image'],
|
|
||||||
sizeType: ['original', 'compressed'], //可以指定是原图还是压缩图,默认二者都有
|
sizeType: ['original', 'compressed'], //可以指定是原图还是压缩图,默认二者都有
|
||||||
sourceType: ['album'], //从相册选择
|
sourceType: ['album'], //从相册选择
|
||||||
success: (res) => {
|
success: (res) => {
|
||||||
let tempFilePaths = [];
|
|
||||||
res.tempFiles.forEach((fileObj) => {
|
|
||||||
tempFilePaths.push(fileObj.tempFilePath)
|
|
||||||
})
|
|
||||||
if (this.imgList.length != 0) {
|
if (this.imgList.length != 0) {
|
||||||
this.imgList = this.imgList.concat(tempFilePaths)
|
this.imgList = this.imgList.concat(res.tempFilePaths)
|
||||||
} else {
|
} else {
|
||||||
this.imgList = tempFilePaths
|
this.imgList = res.tempFilePaths
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
|
||||||
|
|
@ -15,7 +15,7 @@
|
||||||
<button class="cu-btn line-main-color" @click="makePhoneCall(data)">拨打</button>
|
<button class="cu-btn line-main-color" @click="makePhoneCall(data)">拨打</button>
|
||||||
</view>
|
</view>
|
||||||
<view class="text-sm">
|
<view class="text-sm">
|
||||||
{{orderType === 0 ? '拨打电话,按与客户约定的时间填入,完成排单,未完成排单将导致排单超时!' : '需排货的,请输入发货日期与发货时间,发货期将同步通知客户,系统会提醒您发货!'}}
|
拨打电话,按与客户约定的时间填入,完成排单,未完成排单将导致排单超时!
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="padding">
|
<view class="padding">
|
||||||
|
|
@ -48,10 +48,9 @@
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="cu-bar bg-white solid-top">
|
<view class="cu-bar bg-white solid-top">
|
||||||
<view class="action margin-0 flex-sub text-black" @click="cannotArrangeTime" v-if="orderType === 0">无法排单</view>
|
<view class="action margin-0 flex-sub text-black" @click="cannotArrangeTime">无法排单</view>
|
||||||
<view class="action margin-0 flex-sub text-black" data-modal="showTimeArrangeModal" @click="eightClockDelivery" v-if="orderType === 1">今日20点前发货</view>
|
|
||||||
<view class="action margin-0 flex-sub text-black solid-left" data-modal="showTimeArrangeModal"
|
<view class="action margin-0 flex-sub text-black solid-left" data-modal="showTimeArrangeModal"
|
||||||
@click="hideModal" v-if="orderType === 0">按原时间上门</view>
|
@click="hideModal">按原时间上门</view>
|
||||||
<view class="action margin-0 flex-sub text-main-color solid-left" data-modal="showTimeArrangeModal"
|
<view class="action margin-0 flex-sub text-main-color solid-left" data-modal="showTimeArrangeModal"
|
||||||
@click="arrangeTime">确认</view>
|
@click="arrangeTime">确认</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
@ -62,7 +61,7 @@
|
||||||
<script>
|
<script>
|
||||||
export default {
|
export default {
|
||||||
name: 'time-arrange',
|
name: 'time-arrange',
|
||||||
emits: ['showArrangeFailTime', 'editServTime', 'close'],
|
emits: ['showArrangeFailTime', 'editServTime'],
|
||||||
props: {
|
props: {
|
||||||
show: {
|
show: {
|
||||||
type: Boolean,
|
type: Boolean,
|
||||||
|
|
@ -75,10 +74,6 @@
|
||||||
curDate: {
|
curDate: {
|
||||||
type: String,
|
type: String,
|
||||||
default: ''
|
default: ''
|
||||||
},
|
|
||||||
orderType: {
|
|
||||||
type: Number,
|
|
||||||
default: 0
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
|
|
@ -144,7 +139,7 @@
|
||||||
},
|
},
|
||||||
hideModal(e) {
|
hideModal(e) {
|
||||||
this.resetData();
|
this.resetData();
|
||||||
this.$emit('close', e);
|
uni.$emit(this.$globalFun.HIDE_MODAL, e);
|
||||||
},
|
},
|
||||||
cannotArrangeTime(e) {
|
cannotArrangeTime(e) {
|
||||||
this.resetData();
|
this.resetData();
|
||||||
|
|
@ -161,25 +156,12 @@
|
||||||
this.$emit('editServTime', this.data.orderMasterId, [this.expectTimeStart, this.expectTimeEnd], false, this.data);
|
this.$emit('editServTime', this.data.orderMasterId, [this.expectTimeStart, this.expectTimeEnd], false, this.data);
|
||||||
this.hideModal(e);
|
this.hideModal(e);
|
||||||
},
|
},
|
||||||
eightClockDelivery(e) {
|
|
||||||
let nowDate = new Date();
|
|
||||||
const today = nowDate.getFullYear() + '-' + (nowDate.getMonth() + 1) + '-' + nowDate.getDate()
|
|
||||||
const expectStart = today + ' 19:00:00';
|
|
||||||
const expectEnd = today + ' 20:00:00';
|
|
||||||
this.$emit('editServTime', this.data.orderMasterId, [expectStart, expectEnd], false, this.data);
|
|
||||||
this.hideModal(e);
|
|
||||||
},
|
|
||||||
makePhoneCall(order) {
|
makePhoneCall(order) {
|
||||||
if (order.orderDetailId == null) {
|
if (order.orderDetailId == null) {
|
||||||
this.$request.callCustomer({
|
this.$request.callCustomer({
|
||||||
id: order.orderMasterId,
|
id: order.orderMasterId,
|
||||||
isCall: '02'
|
isCall: '02'
|
||||||
});
|
});
|
||||||
} else {
|
|
||||||
this.$request.callDetailCustomer({
|
|
||||||
id: order.orderDetailId,
|
|
||||||
isCall: '02'
|
|
||||||
});
|
|
||||||
}
|
}
|
||||||
uni.makePhoneCall({
|
uni.makePhoneCall({
|
||||||
phoneNumber: order.customerPhone
|
phoneNumber: order.customerPhone
|
||||||
|
|
|
||||||
|
|
@ -73,20 +73,15 @@
|
||||||
this.toWho = toWho;
|
this.toWho = toWho;
|
||||||
},
|
},
|
||||||
chooseImgList(e) {
|
chooseImgList(e) {
|
||||||
uni.chooseMedia({
|
uni.chooseImage({
|
||||||
count: 9, //默认9
|
count: 9, //默认9
|
||||||
mediaType: ['image'],
|
|
||||||
sizeType: ['original', 'compressed'], //可以指定是原图还是压缩图,默认二者都有
|
sizeType: ['original', 'compressed'], //可以指定是原图还是压缩图,默认二者都有
|
||||||
sourceType: ['album'], //从相册选择
|
sourceType: ['album'], //从相册选择
|
||||||
success: (res) => {
|
success: (res) => {
|
||||||
let tempFilePaths = [];
|
|
||||||
res.tempFiles.forEach((fileObj) => {
|
|
||||||
tempFilePaths.push(fileObj.tempFilePath);
|
|
||||||
})
|
|
||||||
if (this.imgList.length != 0) {
|
if (this.imgList.length != 0) {
|
||||||
this.imgList = this.imgList.concat(tempFilePaths)
|
this.imgList = this.imgList.concat(res.tempFilePaths)
|
||||||
} else {
|
} else {
|
||||||
this.imgList = tempFilePaths
|
this.imgList = res.tempFilePaths
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
|
||||||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
Binary file not shown.
|
Before Width: | Height: | Size: 470 B |
|
|
@ -237,7 +237,7 @@
|
||||||
}
|
}
|
||||||
|
|
||||||
.cu-form-group textarea {
|
.cu-form-group textarea {
|
||||||
margin: 20rpx 0 !important;
|
margin: 0 0 20rpx 0 !important;
|
||||||
padding: 20rpx !important;
|
padding: 20rpx !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -236,7 +236,7 @@
|
||||||
position: absolute;
|
position: absolute;
|
||||||
border-radius: 4px;
|
border-radius: 4px;
|
||||||
font-size: 12px;
|
font-size: 12px;
|
||||||
padding: 5px 3px;
|
padding: 10px;
|
||||||
min-width: 10px;
|
min-width: 10px;
|
||||||
word-wrap: break-word;
|
word-wrap: break-word;
|
||||||
display: inline-block;
|
display: inline-block;
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue