Commit 12e7016d by caoyanzhi

update: 客户展示设置

parent 56bdc90e
......@@ -61,7 +61,7 @@ export default {
data() {
const valiStoreType = (rules, value, callback) => {
const data = value.filter(el => !this.selectedTypes.includes(el));
if (this.myCustomData.storeType.includes('-1')) {
if (this.myCustomData.storeType.includes('-999')) {
return callback();
}
if (this.storeTypes.every(el => this.selectedTypes.includes(el.value))) {
......@@ -74,7 +74,7 @@ export default {
};
return {
// 门店类型(0:自营,1:联营,2:代理(加盟),3:代销,4:托管)
// -1:全部,也就是通用策略、默认策略
// -999:全部,也就是通用策略、默认策略
storeTypes: [
{ label: '自营', value: '0' },
{ label: '联营', value: '1' },
......@@ -87,7 +87,7 @@ export default {
myCustomData: {
memberManageSettingId: '', // 会员设置id,更新时必传
strategyName: '',
storeType: [], //门店类型 -1:全部;1:自营;2:联营;3:代理;4:代销;5:托管
storeType: [], //门店类型 -999:全部;1:自营;2:联营;3:代理;4:代销;5:托管
mainStoreFlag: 0, // 服务门店显示,1显示0不现实
minorStoreFlag: 0, // 协管门店显示,1显示0不显示
openCardStoreFlag: 0, // 开卡门店显示,1显示0不显示
......@@ -119,7 +119,7 @@ export default {
}
// storeType = -1时为通用策略
// 通用策略不能修改门店类型
if (this.myCustomData.storeType.includes('-1')) return;
if (this.myCustomData.storeType.includes('-999')) return;
if (Array.isArray(result)) {
this.selectedTypes = result.reduce((types, el) => {
if (typeof el.storeType == 'string' && el.memberManageSettingId != this.myCustomData.memberManageSettingId) {
......@@ -180,10 +180,10 @@ export default {
});
// storeType = -1时为通用策略
// 通用策略不能修改门店类型
if (storeType == -'1') {
if (storeType == '-999') {
this.selectedTypes = this.storeTypes.map(el => el.value);
this.myCustomData.storeType = this.storeTypes.map(el => el.value);
this.myCustomData.storeType.push('-1');
this.myCustomData.storeType.push('-999');
}
this.$nextTick(() => {
this.rules.options.trigger = 'change';
......
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