提交 56f74fe7 编写于 作者: llz's avatar llz

update

上级 c9d92888
...@@ -85,30 +85,38 @@ export const uploadImg = (file) => request({ ...@@ -85,30 +85,38 @@ export const uploadImg = (file) => request({
headers: { "Content-Type": "multipart/form-data" } headers: { "Content-Type": "multipart/form-data" }
}); });
export const addObj = (data) => request({ export const addObj = (data) => {
url: url + '/bladevisuals/save', return new Promise((resolve, reject) => {
method: 'post', request({
data: { url: url + '/bladevisuals/save',
password: data.password, method: 'post',
category: data.category, data: {
status: data.status, password: data.password,
title: data.title, category: data.category,
config: { status: data.status,
detail: JSON.stringify({ title: data.title,
name: data.title, config: {
width: data.width, detail: JSON.stringify({
height: data.height, name: data.title,
scale: 1, width: data.width,
backgroundImage: '/img/bg/bg1.png', height: data.height,
url: '', scale: 1,
mark: {}, backgroundImage: '/img/bg/bg1.png',
gradeShow: false, url: '',
gradeLen: 30, mark: {},
}), gradeShow: false,
component: '[]' gradeLen: 30,
}),
component: '[]'
}
} }
} }).then((response) => {
}); resolve(response);
}).catch((response) => {
reject(response);
});
})
}
export const updateComponent = (data) => request({ export const updateComponent = (data) => request({
url: url + '/visual/update', url: url + '/visual/update',
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册