Commit 97c2b5b4 by caoyanzhi

update: 计费规则保存添加loading

parent aebf8515
......@@ -112,11 +112,11 @@
<div class="flex_column">
<p>AI电话</p>
<p>
<span class="fz22">{{ recharge.callTime || 0 }}</span>
<span class="fz22">{{ recharge.aiCount || 0 }}</span>
分钟
</p>
</div>
<p class="regular-font-color">合计费用:¥{{ (recharge.callFee / 1000) | amount }}</p>
<p class="regular-font-color">合计费用:¥{{ (recharge.aiFee / 1000) | amount }}</p>
</div>
</div>
</el-col>
......
......@@ -82,10 +82,10 @@
<div class="mark" />
AI营销
</h2>
<el-form-item label="AI电话(包含短信):" prop="" class="mb20">
<el-radio-group>
<el-radio>会员所属服务门店</el-radio>
<el-radio>活动创建人</el-radio>
<el-form-item label="AI电话(包含短信):" prop="aiRule" class="mb20">
<el-radio-group v-model="form.aiRule">
<el-radio :label="2">会员所属服务门店</el-radio>
<el-radio :label="3">活动创建人</el-radio>
</el-radio-group>
</el-form-item>
</template>
......@@ -93,7 +93,7 @@
</el-form>
<div class="footer">
<el-button @click="close">取 消</el-button>
<el-button type="primary" @click="save">保 存</el-button>
<el-button type="primary" :loading="loading" @click="save">保 存</el-button>
</div>
</el-drawer>
</template>
......@@ -112,6 +112,7 @@ export default {
cb();
}
return {
loading: false,
form: {
status: 0, // 是否多账户
smsPlanRule: 2, // 短信营销
......@@ -120,7 +121,8 @@ export default {
smsOpenCardRule: 1, // 认证
smsHaobanRule: 4, // 好办
callRule: 4, // 双向呼叫
gytRule: 1 // 观云台小程序
gytRule: 1, // 观云台小程序
aiRule: 3 // AI营销
},
isMoreAccount: false,
rules: {
......@@ -130,7 +132,8 @@ export default {
smsOpenCardRule: [{ required: true, validator: (rule, val, cb) => validate(val, cb, [1]) }],
gytRule: [{ required: true, validator: (rule, val, cb) => validate(val, cb, [1]) }],
smsHaobanRule: [{ required: true, validator: (rule, val, cb) => validate(val, cb, [4]) }],
callRule: [{ required: true, validator: (rule, val, cb) => validate(val, cb, [3, 4]) }]
callRule: [{ required: true, validator: (rule, val, cb) => validate(val, cb, [3, 4]) }],
aiRule: [{ required: true, validator: (rule, val, cb) => validate(val, cb, [2, 3]) }]
}
};
},
......@@ -148,9 +151,10 @@ export default {
const para = this.form.status ? this.form : {};
// 比较字段值是否有改变
if (this.compareIsEdit(para, this.data)) {
this.loading = true;
if (!this.isMoreAccount) {
await this.$confirm('开启多账户计费模式次日凌晨生效,并且开启后不允许关闭', '确认开启多账户模式?', options1);
await saveAccountRule(para);
await saveAccountRule(para).finally(() => (this.loading = false));
this.$emit('getNewData', !this.isMoreAccount);
try {
await this.$confirm('赶紧去设置不同的计费账户吧,也可点击【计费中心-账户明细】配置不同的计费账户', '保存成功', options2);
......@@ -160,7 +164,7 @@ export default {
return false;
}
} else {
await saveAccountRule(para);
await saveAccountRule(para).finally(() => (this.loading = false));
this.$emit('getNewData', this.isMoreAccount);
this.$emit('update:visible', false);
return this.$message.success('保存成功');
......
......@@ -16,7 +16,7 @@
<el-option label="会员验证码" value="1"></el-option>
<el-option label="导购验证码" value="2"></el-option>
</el-select>
<el-select v-if="$route.params.type == 'marketing'" placeholder="请选择营销类型" style="width: 160px">
<el-select v-if="$route.params.type == 'marketing'" placeholder="请选择营销类型" clearable style="width: 160px" v-model="listParams.source" @change="onSearch">
<el-option v-for="el in marketingTypeList" :key="el.value" :label="el.label" :value="el.value"></el-option>
</el-select>
<select-depart v-if="isMoreAccount && config.showAllDepartment" :data="deparment" @load="load" @getDepartId="getDepartId" @remote-search="remoteSearch" :loading="deparment.loading" />
......@@ -54,7 +54,9 @@
<p class="gray">{{ scope.row.storeGroupName }}</p>
</template>
</el-table-column>
<el-table-column min-width="90" label="营销类型"></el-table-column>
<el-table-column min-width="90" label="营销类型" prop="sourceType">
<template slot-scope="{ row }">{{ row.sourceType == 1 ? '智能营销' : row.sourceType == 5 ? 'AI营销' : '短信群发' }}</template>
</el-table-column>
<el-table-column label="触发计划名称" :show-overflow-tooltip="true" align="left" min-width="110" prop="sourceName">
<template slot-scope="{ row }">{{ row.sourceName || '--' }}</template>
</el-table-column>
......@@ -300,8 +302,8 @@ export default {
return {
marketingTypeList: [
{ label: '智能营销', value: '1' },
{ label: 'AI营销', value: '2' },
{ label: '短信群发', value: '3' }
{ label: 'AI营销', value: '5' },
{ label: '短信群发', value: '2' }
],
// eslint-disable-next-line
defaultAvatar: require('../../assets/img/head_default.png'),
......@@ -317,7 +319,8 @@ export default {
beginTime: '',
endTime: '',
searchParam: '',
channelType: ''
channelType: '',
source: ''
},
total: 0,
taskType: '',
......
......@@ -31,7 +31,7 @@
<p class="fz12 gray line-height2">1、我们提供在线充值服务(目前仅支持微信)</p>
<p class="fz12 gray line-height2">2、请尽量保障账户余额大于您日常使用的额度,避免因余额不足导致业务中断</p>
<p class="fz12 gray line-height2">3、若未能及时充值或其他问题,请联系客户经理或客服人员</p>
<p class="fz12 gray line-height2">4、各项服务单价:国内短信验证码0.050元/条,国际短信验证码0.500元/条,双向呼叫0.420元/分钟,AI电话0.4元/分钟</p>
<p class="fz12 gray line-height2">4、各项服务单价:国内短信验证码0.050元/条,国际短信验证码0.500元/条,双向呼叫0.420元/分钟,AI电话0.020元/分钟</p>
<!-- <p class="fz12 gray line-height2">5、通话录音存储收费标准:「三个月{{ allUnitFee.storageThreeFee }}元/分钟」「六个月{{ allUnitFee.storageSixFee }}元/分钟」「十二个月{{ allUnitFee.storageTwelveFee }}元/分钟」,不满一分钟按一分钟收费</p> -->
</div>
</article>
......
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