Commit e33d14cd authored by 陈前坚's avatar 陈前坚

perf: 七参数

parent 7213e1ef
......@@ -52,7 +52,13 @@ const SevenParams = props => {
};
// 提交七参数,根据转换类型提交不同的参数
const submitSevenParams = () => {
const sevenFormData = new FormData();
const sevenFormData = {
append(key, value) {
// eslint-disable-next-line react/no-this-in-sfc
this[key] = value;
},
};
// const sevenFormData = {};
sevenFormData.append('ellipseType', sevenForm.getFieldValue('ellipseType'));
sevenFormData.append('transType', sevenForm.getFieldValue('transType'));
sevenFormData.append('middleLine', sevenForm.getFieldValue('middleLine'));
......@@ -166,6 +172,7 @@ const SevenParams = props => {
sevenFormData.append('x_off', sevenForm.getFieldValue('x_off'));
sevenFormData.append('y_off', sevenForm.getFieldValue('y_off'));
}
delete sevenFormData.append;
postSevenParams(sevenFormData)
.then(res => {
......
import { get, post } from '@/services/index';
import qs from 'qs';
/** ***网站配置*** */
// 七参数初始化
......@@ -18,7 +19,13 @@ export const getSevenParamsByTransType = value =>
export const postSevenParams = sevenFormData =>
post(
`/Cityinterface/rest/services/OMS.svc/M_SetSevenParams?_version=9999`,
sevenFormData,
// sevenFormData,
qs.stringify(sevenFormData),
{
headers: {
'content-Type': 'application/x-www-form-urlencoded; charset=UTF-8',
},
},
);
/** ***菜单管理*** */
......
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