Commit 2306df58 by huaying

Merge branch 'feature/act-code' into dev

parents 82a60a34 af598897
......@@ -83,12 +83,6 @@ import { postJsonRequest } from '@/api/api';
export default {
name: 'actCodeRecord',
components: {},
props: {
hmId: {
type: String,
default: ''
}
},
data() {
return {
loading: false,
......@@ -152,31 +146,19 @@ export default {
async getTableList() {
const that = this;
that.loading = true;
let para = {};
let api = '';
if (this.$route.query.hmId) {
api = '/haoban-manage3-web/hm/qrcode/wxUserAddLog/list';
para = {
pageNum: that.currentPage, // 当前页
pageSize: that.pageSize, // 一页显示个数
hmId: that.$route.query.hmId,
createTimeOrder: that.sortType || ''
};
} else if (this.$route.query.linkId) {
const { startTime, endTime, clerkId, linkId } = this.$route.query;
api = '/haoban-manage3-web/hm/link/statistics/log';
para = {
pageNum: that.currentPage, // 当前页
pageSize: that.pageSize, // 一页显示个数
linkId,
clerkId,
startTime,
endTime,
createTimeOrder: that.sortType || ''
};
}
// console.log(para);
postJsonRequest(api, para)
const { startTime, endTime, clerkId, linkId, hmId } = this.$route.query;
let para = {
pageNum: that.currentPage, // 当前页
pageSize: that.pageSize, // 一页显示个数
linkId,
hmId,
clerkId,
startTime,
endTime,
addChannel: linkId ? 1 : hmId ? 2 : 0,
createTimeOrder: that.sortType || ''
};
postJsonRequest('/haoban-manage3-web/hm/qrcode/wxUserAddLog/list', para)
.then(res => {
let resData = res.data;
that.loading = false;
......
......@@ -47,7 +47,6 @@ export default {
};
},
created() {
console.log(this.$route.query.hmId, 'this.$route.query.hmId');
if (this.$route.query.hmId) {
this.getActCodeInfo();
}
......
......@@ -62,8 +62,8 @@ export default {
// name: '', // 名称
hmGroupId: '', //活码分组id
passFlag: true, // 1自动通过 0否
memberLabelId: 'fd6b44967aa647bcadfad10706244c56', //会员活动标签id
memberLabelName: '测试121212-木瑾0630测试标签值50',
memberLabelId: '', //会员活动标签id
memberLabelName: '',
welcomeId: '' // 欢迎语id
// clerkIdList: '', // 选择导购id
// storeId: '' //门店id
......@@ -86,6 +86,7 @@ export default {
},
created() {
this.searchGroup();
console.log(this.form, 400);
},
methods: {
handleTagCloseTag() {
......@@ -140,7 +141,6 @@ export default {
},
// 保存按钮
save() {
console.log(this.form, 'this.form');
if (!this.$refs.welcomeItem.submit()) {
return;
}
......@@ -157,7 +157,7 @@ export default {
handler: function(val) {
if (val) {
this.form.hmGroupId = val.hmGroupId;
this.form.passFlag = val.passFlag == 1 ? true : false;
// this.form.passFlag = val.passFlag == 1 ? true : false;
this.form.memberLabelId = val.memberLabelId ? val.memberLabelId : '';
this.form.memberLabelName = val.memberLabelName ? val.memberLabelName : '';
this.form.welcomeId = val.welcomeId;
......
......@@ -238,18 +238,14 @@ export default {
});
},
lookRecords(row) {
if (row.hmId) {
this.$router.push(`/actCodeRecord?hmId=${row.hmId}`);
} else if (row.linkId) {
const { clerkId, linkId } = row;
const startTime = this.dateDefault && this.dateDefault.length ? this.dateDefault[0] : undefined;
const endTime = this.dateDefault && this.dateDefault.length ? this.dateDefault[1] : undefined;
const { clerkId, linkId, hmId } = row;
const startTime = this.dateDefault && this.dateDefault.length ? this.dateDefault[0] : undefined;
const endTime = this.dateDefault && this.dateDefault.length ? this.dateDefault[1] : undefined;
let query = { linkId, clerkId };
startTime ? (query.startTime = startTime) : '';
endTime ? (query.endTime = endTime) : '';
this.$router.push({ path: '/actCodeRecord', query: query });
}
let query = { linkId, clerkId, hmId };
startTime ? (query.startTime = startTime) : '';
endTime ? (query.endTime = endTime) : '';
this.$router.push({ path: '/actCodeRecord', query: query });
}
}
};
......
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