权限控制

master
Caps 6 years ago
parent 9338a1102c
commit 8f3a81b68d

@ -46,9 +46,8 @@
companyList: [], companyList: [],
columns1: [ columns1: [
{ {
type: 'index',
title: '序号', title: '序号',
key: 'id' key: 'index'
}, },
{ {
title: '零售公司名称', title: '零售公司名称',
@ -117,6 +116,7 @@
} }
if (data.code === '0000') { if (data.code === '0000') {
that.companyList.push({id:'-1',name:"全部"}); that.companyList.push({id:'-1',name:"全部"});
that.selectedCompany = "-1";
data.results.forEach(da => { data.results.forEach(da => {
that.companyList.push(da); that.companyList.push(da);
}) })
@ -149,6 +149,9 @@
} }
if (data.code === '0000') { if (data.code === '0000') {
that.data1 = data.results.dataVOS; that.data1 = data.results.dataVOS;
for(let i = 0; i < that.data1.length;i++){
that.data1[i].index = i+1;
}
that.totalSize = data.results.sizeNum; that.totalSize = data.results.sizeNum;
} }
}) })

@ -66,9 +66,8 @@
staffList: [], staffList: [],
columns1: [ columns1: [
{ {
type: 'index',
title: '序号', title: '序号',
key: 'id' key: 'index'
}, },
{ {
title: '导购名称', title: '导购名称',
@ -96,7 +95,20 @@
}, },
{ {
title: '总好友数(去重)', title: '总好友数(去重)',
key: 'effectiveCustomer' key: 'effectiveCustomer',
render: (h, params) => {
let that = this;
if(that.data1[params.index].effectiveCustomer != null){
return h('div', [
h('span', {}, that.data1[params.index].effectiveCustomer),
])
}else {
return h('div', [
h('span', {}, '0'),
])
}
}
}, },
{ {
title: '新增好友数', title: '新增好友数',
@ -147,6 +159,7 @@
} }
if (data.code === '0000') { if (data.code === '0000') {
that.companyList.push({id:'-1',name:"全部"}); that.companyList.push({id:'-1',name:"全部"});
that.selectedCompany = "-1";
data.results.forEach(da => { data.results.forEach(da => {
that.companyList.push(da); that.companyList.push(da);
}) })
@ -170,6 +183,7 @@
id:'-1', id:'-1',
name:"全部" name:"全部"
}) })
that.selectedStore = '-1';
data.results.forEach(da => { data.results.forEach(da => {
that.storeList.push(da); that.storeList.push(da);
}) })
@ -192,7 +206,8 @@
that.staffList.push({ that.staffList.push({
id:'-1', id:'-1',
name:"全部" name:"全部"
}) });
that.selectedStaff = '-1';
data.results.forEach(da => { data.results.forEach(da => {
that.staffList.push(da); that.staffList.push(da);
}) })
@ -220,7 +235,8 @@
that.storeList.push({ that.storeList.push({
id:'-1', id:'-1',
name:"全部" name:"全部"
}) });
that.selectedStore = '-1';
data.results.forEach(da => { data.results.forEach(da => {
that.storeList.push(da); that.storeList.push(da);
}) })
@ -248,7 +264,8 @@
that.staffList.push({ that.staffList.push({
id:'-1', id:'-1',
name:"全部" name:"全部"
}) });
that.selectedStaff = '-1';
data.results.forEach(da => { data.results.forEach(da => {
that.staffList.push(da); that.staffList.push(da);
}) })
@ -279,6 +296,9 @@
} }
if (data.code === '0000') { if (data.code === '0000') {
that.data1 = data.results.dataVOS; that.data1 = data.results.dataVOS;
for(let i = 0; i < that.data1.length;i++){
that.data1[i].index = i+1;
}
that.totalSize = data.results.sizeNum; that.totalSize = data.results.sizeNum;
} }
}) })

@ -56,8 +56,7 @@
columns1: [ columns1: [
{ {
title: '序号', title: '序号',
key: 'id', key: 'index',
type: 'index'
}, },
{ {
title: '店铺', title: '店铺',
@ -131,6 +130,7 @@
} }
if (data.code === '0000') { if (data.code === '0000') {
that.companyList.push({id:'-1',name:"全部"}); that.companyList.push({id:'-1',name:"全部"});
that.selectedCompany = "-1";
data.results.forEach(da => { data.results.forEach(da => {
that.companyList.push(da); that.companyList.push(da);
}) })
@ -153,7 +153,8 @@
that.storeList.push({ that.storeList.push({
id:'-1', id:'-1',
name:"全部" name:"全部"
}) });
that.selectedStore = '-1';
data.results.forEach(da => { data.results.forEach(da => {
that.storeList.push(da); that.storeList.push(da);
}) })
@ -181,7 +182,8 @@
that.storeList.push({ that.storeList.push({
id:'-1', id:'-1',
name:"全部" name:"全部"
}) });
that.selectedStore = '-1';
data.results.forEach(da => { data.results.forEach(da => {
that.storeList.push(da); that.storeList.push(da);
}) })
@ -218,7 +220,11 @@
return; return;
} }
if(data.code === '0000'){ if(data.code === '0000'){
debugger
that.data1 = data.results.dataVOS; that.data1 = data.results.dataVOS;
for(let i = 0; i < that.data1.length;i++){
that.data1[i].index = i+1;
}
that.totalSize = data.results.sizeNum; that.totalSize = data.results.sizeNum;
} }
}) })

@ -224,9 +224,10 @@
if (data.code === '0000') { if (data.code === '0000') {
data = data.results; data = data.results;
that.roleList.push({ that.roleList.push({
id:0, id:"0",
name:"全部" name:"全部"
}); });
that.changeRoleId = "0";
for (let i = 0; i < data.length; i++) { for (let i = 0; i < data.length; i++) {
let row = data[i]; let row = data[i];
that.roleList.push(row); that.roleList.push(row);
@ -252,6 +253,7 @@
id:'-1', id:'-1',
name:"全部" name:"全部"
}); });
that.changeShopId = '-1';
data = data.results; data = data.results;
for (let i = 0; i < data.length; i++) { for (let i = 0; i < data.length; i++) {
let row = data[i]; let row = data[i];

Loading…
Cancel
Save