优化:基础数据表单保存逻辑

master
Guo XIn 1 year ago
parent 0c2fa9586d
commit c29293b280
  1. 2
      shandan-basedata/src/main/resources/view/dynamicForm/designForm.html
  2. 8
      shandan-basedata/src/main/resources/view/dynamicForm/formList.html
  3. 2
      shandan-control/src/main/java/com/keyware/shandan/control/config/DynamicFormListener.java

@ -62,7 +62,7 @@
postRequest(`${ctx}/dynamic-form/api/form/save`, params).then(res => {
if (res.flag) {
temp_data = params;
showOkMsg('保存成功');
saveCallback && saveCallback();
} else {
showErrorMsg(res.msg)
}

@ -99,6 +99,14 @@
*/
function openFormDesignPage(id) {
openMaxLayer(`${ctx}/dynamic-form/view/form/design?formId=${id}`, {
success: function(layero, index){
let iframeWin = window[layero.find('iframe')[0]['name']];
iframeWin.saveCallback = function(){
formListTable.reload();
showOkMsg('保存成功');
layer.closeAll();
}
},
cancel: function (index, layerObj) {
let iframeWin = window[layerObj.find('iframe')[0]['name']];
if (iframeWin.isChange()) {

@ -24,7 +24,7 @@ public class DynamicFormListener implements DynamicFormEventListener {
menu.setMenuId(form.getId().toString());
menu.setParentMenu(parentMenu);
menu.setMenuParentId(parentMenu.getMenuId());
menu.setMenuName(form.getFormName() + "管理");
menu.setMenuName(form.getFormName());
menu.setMenuPath("/dynamic-data/view/data/list/" + form.getId());
menu.setSystem(parentMenu.getSystem());
menu.setMenuParentName(parentMenu.getMenuName());