Commit 805507f5 by caoyanzhi

Merge branch 'feature/12月迭代' into dev

parents 879db072 bfa62c12
......@@ -18,7 +18,6 @@ export default {
return {
load: false,
phoneNameNick: "",
isdot: false,
bodyHeight:
document.body.clientHeight || document.documentElement.clientHeight,
storeId: this.$route.query.storeId || "",
......@@ -28,7 +27,7 @@ export default {
navpath: [
{ name: "首页", path: "" },
{ name: "会员列表", path: "/wechatmembers" },
{ name: "回收站门店会员", path: "" }
{ name: "待处理客户列表", path: "" }
],
sceneValue: "member",
tableData: [],
......@@ -96,9 +95,6 @@ export default {
mainStoreId: ""
},
storeName: "",
dialogProcessVisible: false,
processList: [],
timer: null,
dialogSubStoreVisible: false,
storeForm: {
remark: "",
......@@ -120,22 +116,6 @@ export default {
]
},
subStoreList: [],
singleInfo: {
sex: 0,
age: 0,
cardNo: 0,
mainStoreName: "dd",
costFee: 0,
costTimes: 0,
lastCost: 0,
numOfSale: 0,
numOfmarket: 0,
couponCount: 0,
status: 0,
wxStatus: 0,
phoneStatus: 0,
authStatus: 0
},
integralFlag: ""
};
},
......@@ -262,19 +242,6 @@ export default {
}
},
watch: {
processList(newValue,oldValue) {
if(newValue.length <= 0) {
let self = this;
clearInterval(self.timer);
this.getAjaxMembers();
}else {
let self = this;
clearInterval(self.timer);
this.timer = setInterval(() => {
this.getProcessList();
},5000);
}
},
phoneNameCard(newVal) {
sessionStorage.setItem("phoneNameCard", newVal);
}
......@@ -335,34 +302,9 @@ export default {
linkDetail(memberId) {
this.$router.push({
path: "/wechatmemberDetail",
query: { memberId: memberId }
query: { memberId: memberId, channel: 'wxMember' }
});
},
showSingleInfo(memberId) {
this.singleInfo = "";
doFetch(url.singleInfo, {
memberId: memberId
})
.then(res => {
if (res.data.errorCode === 0) {
let ret = res.data.result.memberSingle;
this.singleInfo = {
...ret,
sex: ret.sex == 0 ? "性别未知" : ret.sex == 1 ? "男" : "女",
age: ret.age != 0 ? ret.age : "年龄未知",
cardNo: !!ret.cardNo ? ret.cardNo : "无会员卡",
mainStoreName: !!ret.mainStoreName
? ret.mainStoreName
: "服务门店未知"
};
} else {
checkFalse(res.data.message);
}
})
.catch(err => {
checkStatus(err);
});
},
changeSubStore() {
if (this.storeForm.subOptType == 1) {
this.storeForm.modefiySubStoreName = "";
......@@ -432,23 +374,12 @@ export default {
phoneNameNick: this.phoneNameNick
})
.then(res => {
this.$refs[formName].resetFields();
if (res.data.errorCode === 0) {
checkSuccess();
this.dialogSubStoreVisible = false;
this.batchHanleSuccess();
} else {
checkFalse(res.data.message);
this.dialogSubStoreVisible = false;
return false;
}
})
.then(() => {
setTimeout(() => {
this.getProcessList();
}, 30);
})
.catch(err => {
checkStatus(err);
}).finally(() => {
this.dialogSubStoreVisible = false;
this.$refs[formName].resetFields();
});
......@@ -486,33 +417,6 @@ export default {
checkStatus(err);
});
},
closeProcess() {
clearInterval(this.timer);
},
getBatchProcess() {
this.dialogProcessVisible = true;
},
// 移动触发处理进度
callProcess() {
this.getProcessList();
},
getProcessList() {
doFetch(url.batchProcess)
.then(res => {
if (res.data.errorCode === 0) {
this.isdot = res.data.result.list.length > 0 ? true : false;
this.processList = res.data.result.list.map(ele => ({
...ele,
name: ele.name ? ele.name : "未知"
}));
} else {
checkFalse(res.data.message);
}
})
.catch(err => {
checkStatus(err);
});
},
// 修改服务门店
submitMainStore(formName) {
this.$refs[formName].validate(valid => {
......@@ -543,31 +447,20 @@ export default {
listSignId: this.storeId,
sortField: "",
phoneNameNick: this.phoneNameNick,
memberListType: 2
// memberListType: 2
})
.then(res => {
this.$refs[formName].resetFields();
this.storeName = "";
if (res.data.errorCode === 0) {
checkSuccess();
this.getAjaxMembers();
this.dialogMainstoreVisible = false;
this.storeName = "";
this.sortColName = "";
this.sortType = "desc";
this.phoneNameCard = "";
this.getAjaxMembers();
this.batchHanleSuccess();
} else {
checkFalse(res.data.message);
this.dialogMainstoreVisible = false;
return false;
}
})
.then(() => {
setTimeout(() => {
this.getProcessList();
}, 30);
})
.catch(err => {
checkStatus(err);
}).finally(() => {
this.dialogMainstoreVisible = false;
this.$refs[formName].resetFields();
});
......@@ -577,6 +470,15 @@ export default {
}
});
},
batchHanleSuccess() {
this.$confirm('任务发起成功,请去【企业管理】-【任务中心】查看处理结果和执行进度', '任务发起成功', {
type: 'success',
confirmButtonText: '去任务中心'
}).then(() => {
// window.open('');
console.log('hello')
});
},
handleStore() {
if (this.mainstoreForm.mainOptType == 4) {
this.showStoreDialog = true;
......@@ -642,13 +544,7 @@ export default {
this.dialogGradeVisible = false;
return false;
}
})
.then(() => {
setTimeout(() => {
this.getProcessList();
}, 30);
})
.catch(err => {
}).catch(err => {
checkStatus(err);
this.dialogGradeVisible = false;
this.$refs[formName].resetFields();
......@@ -733,11 +629,6 @@ export default {
.then(res => {
this.IntegralForm.settlementStoreId = "";
this.dialogIntegralVisible = false;
if (res) {
setTimeout(() => {
this.getProcessList();
}, 30);
}
})
.catch(err => {
checkStatus(err);
......@@ -900,8 +791,7 @@ export default {
listSign: "MemberProcessed",
pageSize: this.page.pageSize,
currentPage: this.page.currentPage,
phoneNameNick: this.phoneNameNick,
memberListType: 2
phoneNameNick: this.phoneNameNick
})
.then(res => {
this.load = true;
......@@ -983,7 +873,6 @@ export default {
if (!this.storeImageUrl) {
this.$store.dispatch("getStorePicture");
}
this.getProcessList();
this.initialize();
this.$store.commit("mutations-slide", false);
},
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment