fix: pcf新增编辑表单数据组装异常,上传超时30s
This commit is contained in:
@@ -241,6 +241,7 @@ export async function uploadFileToNE(
|
|||||||
neType,
|
neType,
|
||||||
neId,
|
neId,
|
||||||
},
|
},
|
||||||
|
timeout: 30_000,
|
||||||
});
|
});
|
||||||
return transferToNeFileRes;
|
return transferToNeFileRes;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -280,10 +280,28 @@ function fnModalVisibleByEdit(row?: Record<string, any>) {
|
|||||||
getRule(neID, row.imsi)
|
getRule(neID, row.imsi)
|
||||||
.then(res => {
|
.then(res => {
|
||||||
if (res.code === RESULT_CODE_SUCCESS) {
|
if (res.code === RESULT_CODE_SUCCESS) {
|
||||||
Object.assign(modalState.from, res.data, {
|
Object.assign(modalState.from, res.data);
|
||||||
pccRules: res.data.pccRules.split('|'),
|
|
||||||
sessRules: res.data.sessRules.split('|'),
|
let pccRules = res.data.pccRules;
|
||||||
});
|
if (!pccRules) {
|
||||||
|
pccRules = [];
|
||||||
|
} else if (pccRules.includes('|')) {
|
||||||
|
pccRules = pccRules.split('|');
|
||||||
|
} else {
|
||||||
|
pccRules = [pccRules];
|
||||||
|
}
|
||||||
|
modalState.from.pccRules = pccRules;
|
||||||
|
let sessRules = res.data.sessRules;
|
||||||
|
if (!sessRules) {
|
||||||
|
sessRules = [];
|
||||||
|
} else if (sessRules.includes('|')) {
|
||||||
|
sessRules = sessRules.split('|');
|
||||||
|
} else {
|
||||||
|
sessRules = [sessRules];
|
||||||
|
}
|
||||||
|
modalState.from.sessRules = sessRules;
|
||||||
|
console.log(modalState.from);
|
||||||
|
|
||||||
modalState.title = t('views.neUser.pcf.updateTitle', {
|
modalState.title = t('views.neUser.pcf.updateTitle', {
|
||||||
imsi: row.imsi,
|
imsi: row.imsi,
|
||||||
});
|
});
|
||||||
@@ -309,8 +327,23 @@ function fnModalOk() {
|
|||||||
const from = JSON.parse(JSON.stringify(modalState.from));
|
const from = JSON.parse(JSON.stringify(modalState.from));
|
||||||
from.neId = queryParams.neId || '-';
|
from.neId = queryParams.neId || '-';
|
||||||
from.rfsp = Number(from.rfsp) || 0;
|
from.rfsp = Number(from.rfsp) || 0;
|
||||||
from.pccRules = modalState.from.pccRules.join('|');
|
console.log(from);
|
||||||
from.sessRules = modalState.from.sessRules.join('|');
|
let pccRules = modalState.from.pccRules;
|
||||||
|
if (Array.isArray(pccRules)) {
|
||||||
|
pccRules = pccRules.join('|');
|
||||||
|
} else {
|
||||||
|
pccRules = '';
|
||||||
|
}
|
||||||
|
from.pccRules = pccRules;
|
||||||
|
|
||||||
|
let sessRules = modalState.from.sessRules;
|
||||||
|
if (Array.isArray(sessRules)) {
|
||||||
|
sessRules = sessRules.join('|');
|
||||||
|
} else {
|
||||||
|
sessRules = '';
|
||||||
|
}
|
||||||
|
from.sessRules = sessRules;
|
||||||
|
|
||||||
let validateArr = ['imsi', 'msisdn'];
|
let validateArr = ['imsi', 'msisdn'];
|
||||||
if (modalState.isBatch) {
|
if (modalState.isBatch) {
|
||||||
validateArr.push('num');
|
validateArr.push('num');
|
||||||
@@ -988,7 +1021,6 @@ onMounted(() => {
|
|||||||
v-model:value="modalState.from.pccRules"
|
v-model:value="modalState.from.pccRules"
|
||||||
allow-clear
|
allow-clear
|
||||||
mode="tags"
|
mode="tags"
|
||||||
:token-separators="['|']"
|
|
||||||
:options="pcfRuleOption.pccOpt"
|
:options="pcfRuleOption.pccOpt"
|
||||||
:title="t('views.neUser.pcf.pccRuleTip')"
|
:title="t('views.neUser.pcf.pccRuleTip')"
|
||||||
/>
|
/>
|
||||||
@@ -1000,7 +1032,6 @@ onMounted(() => {
|
|||||||
v-model:value="modalState.from.sessRules"
|
v-model:value="modalState.from.sessRules"
|
||||||
allow-clear
|
allow-clear
|
||||||
mode="tags"
|
mode="tags"
|
||||||
:token-separators="['|']"
|
|
||||||
:options="pcfRuleOption.sessOpt"
|
:options="pcfRuleOption.sessOpt"
|
||||||
:title="t('views.neUser.pcf.sessRuleTip')"
|
:title="t('views.neUser.pcf.sessRuleTip')"
|
||||||
/>
|
/>
|
||||||
|
|||||||
Reference in New Issue
Block a user