123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172 |
- {extend name="common/base"/}
- {block name="style"}
- <style>
- .layui-td-gray-2{
- text-align: center;
- }
- .footer{
- display: none;
- }
- </style>
- {/block}
- <!-- 主体 -->
- {block name="body"}
- <form class="layui-form p-4">
- <h3 class="pb-3">新建业主</h3>
- <table class="layui-table layui-table-form">
- <tr>
- <td class="layui-td-gray-2">业主名称<font>*</font></td>
- <td><input type="text" name="title" lay-verify="required" lay-reqText="请完善名称" value=""
- autocomplete="off" placeholder="请输入名称" class="layui-input"></td>
- <td class="layui-td-gray-2">电话<font>*</font></td>
- <td><input type="text" name="phone" lay-verify="required" lay-reqText="请完善电话" value=""
- autocomplete="off" placeholder="请输入电话" class="layui-input"></td>
- </tr>
- <tr>
- <td class="layui-td-gray-2">业主类型<font>*</font></td>
- <td><input type="text" name="company_type" lay-verify="required" lay-reqText="请完善送审单位类型" value=""
- autocomplete="off" placeholder="请输入送审单位类型" class="layui-input"></td>
- <td class="layui-td-gray-2">业主地址<font>*</font></td>
- <td><input type="text" name="address" lay-verify="required" lay-reqText="请完善送审单位地址" value=""
- autocomplete="off" placeholder="请输入送审单位类型" class="layui-input"></td>
- <td colspan='2'></td>
- </tr>
- </table>
- <div class="pt-3">
- <input type="hidden" name="" value="0"/>
- <button class="layui-btn layui-btn-normal" lay-submit="" lay-filter="webform">立即提交</button>
- <button type="reset" class="layui-btn layui-btn-primary">重置</button>
- </div>
- </form>
- {/block}
- <!-- /主体 -->
- <!-- 脚本 -->
- {block name="script"}
- <script>
- var moduleInit = ['tool'];
- function gouguInit() {
- var form = layui.form, tool = layui.tool;
- let a = 1;
- //监听提交
- form.on('submit(webform)', function (data) {
- if(a){
- let callback = function (e) {
- layer.msg(e.msg);
- if (e.code == 0) {
- tool.sideClose(1000);
- a = 1
- }
- }
- tool.post("/admin/cpuser.institution/add", data.field, callback);
- }
-
- a = 0
- return false;
- });
- }
- </script>
- {/block}
- <!-- /脚本 -->
|