From 220d2c325fe8206a26dfe6969d76344e9c1a18b3 Mon Sep 17 00:00:00 2001 From: dougang <78125310@kidgrow.com> Date: Fri, 18 Dec 2020 15:34:31 +0800 Subject: [PATCH] 优化样式 --- kidgrow-web/kidgrow-web-manager/src/main/resources/static/pages/opration/doctor.html | 112 ++++++++++++++++++++++++++++++-------------------------- 1 files changed, 60 insertions(+), 52 deletions(-) diff --git a/kidgrow-web/kidgrow-web-manager/src/main/resources/static/pages/opration/doctor.html b/kidgrow-web/kidgrow-web-manager/src/main/resources/static/pages/opration/doctor.html index 7ba3270..89e1d22 100644 --- a/kidgrow-web/kidgrow-web-manager/src/main/resources/static/pages/opration/doctor.html +++ b/kidgrow-web/kidgrow-web-manager/src/main/resources/static/pages/opration/doctor.html @@ -10,14 +10,14 @@ <div class="layui-form toolbar"> <div class="layui-form-item"> <div class="layui-inline" style="margin-bottom: -25px;"> - <input id="doctorTel" class="layui-input search-input" type="text" placeholder="按手机号..." />  - <input id="doctorName" class="layui-input search-input" type="text" placeholder="按医生名..." />  + <input id="doctorTel" class="layui-input search-input" type="text" placeholder="按手机号" />  + <input id="doctorName" class="layui-input search-input" type="text" placeholder="按医生名" />  <select id="doctorState" lay-filter="role_clients"> <option value="">-医院状态-</option> - <option value="true">正常</option> - <option value="false">试用</option> + <option value="1">正常</option> + <option value="0">试用</option> </select>  - <input name="hospitalName" id="hospitalName-seach" placeholder="请输入医院名称" type="text" + <input name="hospitalName" id="hospitalName-seach" placeholder="按医院名称" type="text" class="layui-input search-input" maxlength="50" autocomplete="off" />  </div> <button id="app-btn-search" class="layui-btn icon-btn permissions" layt="abc" @@ -35,12 +35,14 @@ <!-- 表格操作列 --> <script type="text/html" id="doctor-table-bar"> - <a class="layui-btn layui-btn-primary layui-btn-xs" lay-event="detail">查看详情</a> + <a class="layui-btn layui-btn-primary layui-btn-xs" lay-event="detail">详情</a> + {{# if (d.doctorType !=2){}} <button class="layui-btn layui-btn-primary layui-btn-xs permissions" permissions="users-edit" lay-event="reset">重置密码</button> + {{#}}} <button class="layui-btn layui-btn-primary layui-btn-xs permissions" permissions="sysdoctor-edit" lay-event="edit">修改</button> - <button class="layui-btn layui-btn-xs permissions" permissions="sysdoctor-del" lay-event="del">删除</button> + <button class="layui-btn layui-btn-danger layui-btn-xs permissions" permissions="sysdoctor-del" lay-event="del">删除</button> </script> <!-- 表格状态列 --> @@ -134,8 +136,8 @@ <div class="layui-inline"> <label class="layui-form-label">Email</label> <div class="layui-input-block" style="width: 150px;"> - <input name="doctorEmail" type="text" class="layui-input" maxlength="20" - lay-verify="required|email" required /> + <input name="doctorEmail" type="text" class="layui-input" maxlength="50" + lay-verify="email" autocomplete="off"/> </div> </div> </div> @@ -145,7 +147,7 @@ <label class="layui-form-label">医生简介</label> <div class="layui-input-block"> <textarea name="doctorAbout" id="doctorAbout" class="layui-textarea" maxlength="300" - style="width: 650px;"></textarea> + style="width: 697px;"></textarea> </div> </div> </div> @@ -281,7 +283,7 @@ } else { layer.msg(data.msg, { icon: 2, - time: 500 + time: 2000 }); } }, 'Post'); @@ -299,12 +301,6 @@ // 修改company状态 var updata_enable = function (obj) { - - // alert('确定审核通过吗',{icon: 3, title:'提示'}, function(index){ - // console.log("111111111111111111111",index) - // layer.close(index); - // }); - layer.confirm('确定审核通过吗?', function (i) { admin.req('api-user/sysdoctor/enable', JSON.stringify({ id: obj.id, @@ -314,13 +310,13 @@ if (data.code == 0) { layer.msg(data.msg, { icon: 1, - time: 500 + time: 2000 }); parent.layui.table.reload('app-table', {}); } else { layer.msg(data.msg, { icon: 2, - time: 500 + time: 2000 }); $(obj.elem).prop('checked', !obj.elem.checked); form.render('checkbox'); @@ -351,7 +347,7 @@ } else { layer.msg(data.msg, { icon: 2, - time: 500 + time: 2000 }); } }, 'Post'); @@ -364,14 +360,13 @@ user = data.data; $.each(data.data, function (index, item) { //往下拉菜单里添加元素 - console.log(item.nickname) $('#serverUserId-add').append(new Option(item.nickname, item.id, false, false)); }) } else { layer.msg(data.msg, { icon: 2, - time: 500 + time: 2000 }); } }, 'get'); @@ -403,32 +398,40 @@ cols: [ [{ field: 'hospitalName', - width: 180, - title: '医院名称' + width: "200", + title: '医院名称', + fixed: 'left' + }, + { + field: 'departmentName', + width: "150", + title: '科室', + fixed: 'left' }, { field: 'doctorName', - width: 120, - title: '医生姓名' + width: "100", + title: '医生姓名', + fixed: 'left' }, { field: 'doctorRank', - width: 100, + width: "100", title: '职称' }, { field: 'username', - width: 150, + width: "150", title: '登录帐号' }, { field: 'doctorTel', - width: 150, + width: "150", title: '联系方式' }, { field: 'isAnswer', - width: 100, + width: "75", title: '医答', templet: function (d) { return d.isAnswer ? "是" : "否" @@ -436,37 +439,38 @@ }, { field: 'isSigning', - width: 100, + width: "75", title: '签约', templet: function (d) { return d.isSigning ? "是" : "否" } }, - // { - // field: 'enabled', - // width: 100, - // align: 'center', - // templet: '#doctor-tpl-state', - // title: '状态' - // }, - // { field: 'createTime', width: 150, title: '创建时间', templet: "<div>{{layui.util.toDateString(d.createTime, 'yyyy-MM-dd HH:mm')}}</div>" }, + { + field: 'isAdminUser', + width: "100", + title: '是否管理员', + templet: function (d) { + return d.isAdminUser ? "管理员" : "普通医生" + } + }, { field: 'createTime', - width: 150, + width: "120", sort: true, title: '创建时间', templet: "<div>{{layui.util.toDateString(d.createTime, 'yyyy/MM/dd HH:mm')}}</div>" }, { field: 'serverUserName', - width: 100, + width: "120", title: '销售代表' }, { - width: 350, + width: "260", align: 'center', toolbar: '#doctor-table-bar', - title: '操作' + title: '操作', + fixed: 'right' }, ] ], @@ -517,6 +521,7 @@ } form.val('app-form', data); $('#app-form').find('input,select,textarea').prop('readonly', true); + $('#app-form').find('select').prop('disabled', true); $('#app-form').find('input[type="radio"]').prop('disabled', true); $('#app-form').attr('method', 'POST'); form.render(); @@ -544,20 +549,19 @@ data) { layer.closeAll('loading'); if (data.code == 0) { - layer.msg(data.msg, { - icon: 1, - time: 500 + layer.alert("密码重置为:" + data.data, { + icon: 1 }); } else { layer.msg(data.msg, { icon: 2, - time: 500 + time: 2000 }); } }, 'PUT'); }); } else if (layEvent === 'edit') { - showEditModel_add("编辑",data); + showEditModel_add("编辑", data); } else if (layEvent === 'del') { layer.confirm('确定删除此用户吗?', function (i) { layer.close(i); @@ -567,13 +571,13 @@ if (data.code == 0) { layer.msg(data.msg, { icon: 1, - time: 500 + time: 2000 }); table.reload('app-table', {}); } else { layer.msg(data.msg, { icon: 2, - time: 500 + time: 2000 }); } }, 'delete'); @@ -596,17 +600,21 @@ hospitalName: hospitalName, doctorTel: doctorTel, doctorName: doctorName - } + }, + page: { + curr: 1 + } }); }); // 显示新增弹窗 - var showEditModel_add = function (title,data) { + var showEditModel_add = function (title, data) { admin.putTempData('t_doctor', data); admin.popupCenter({ title: title, path: 'pages/opration/doctor_form.html', area: '900px', + offset: '0px', finish: function () {} }); }; -- Gitblit v1.8.0