From 036dcdcec6235d82b008f5c736d27a0d1f90d4a2 Mon Sep 17 00:00:00 2001 From: 懒羊羊 <15939171744@163.com> Date: 星期二, 14 十一月 2023 14:58:42 +0800 Subject: [PATCH] 优化 --- guns-vip-main/src/main/webapp/assets/modular/bs/materialInfo/materialInfo_edit.js | 50 ++++++++++++++++++++------------------------------ 1 files changed, 20 insertions(+), 30 deletions(-) diff --git a/guns-vip-main/src/main/webapp/assets/modular/bs/materialInfo/materialInfo_edit.js b/guns-vip-main/src/main/webapp/assets/modular/bs/materialInfo/materialInfo_edit.js index 8295ae7..fb8a3a4 100644 --- a/guns-vip-main/src/main/webapp/assets/modular/bs/materialInfo/materialInfo_edit.js +++ b/guns-vip-main/src/main/webapp/assets/modular/bs/materialInfo/materialInfo_edit.js @@ -26,38 +26,28 @@ var form = layui.form; var admin = layui.admin; - - - - - - - - - - - - - - - - - - - - - - - - - - - - //鑾峰彇璇︽儏淇℃伅锛屽~鍏呰〃鍗� var ajax = new $ax(Feng.ctxPath + "/materialInfo/detail?id=" + Feng.getUrlParam("id")); - var result = ajax.start(); - form.val('materialInfoForm', result.data); + var result1 = ajax.start(); + form.val('materialInfoForm', result1.data); + + getDictType(); + function getDictType(){ + $.ajax({ + type: "POST", + contentType: "application/json;charset=UTF-8", + url: Feng.ctxPath + '/dict/list?dictTypeId=1724238087352172546', + success: function (result) { + $.each(result.data, function (index, value) { + $('#typeL').append(new Option(value.name,value.code));// 涓嬫媺鑿滃崟閲屾坊鍔犲厓绱� + }); + $('#typeL').val(result1.data.typeL) + layui.form.render("select");//閲嶆柊娓叉煋 鍥哄畾鍐欐硶 + }, + }); + } + + //琛ㄥ崟鎻愪氦浜嬩欢 form.on('submit(btnSubmit)', function (data) { -- Gitblit v1.9.3