| | |
| | | background-color: #fff; |
| | | box-shadow: 0 -1px 2px 0 rgba(0, 0, 0, .05); |
| | | } |
| | | .cool-divider { |
| | | float: left; |
| | | margin: 4px 18px; |
| | | display: inline-block; |
| | | height: 32px; |
| | | width: 1px; |
| | | vertical-align: middle; |
| | | position: relative; |
| | | top: -.06em; |
| | | box-sizing: border-box; |
| | | -webkit-tap-highlight-color: transparent; |
| | | margin-top: 5px !important; |
| | | margin-bottom: 5px !important; |
| | | background: #c8d1dabd; |
| | | } |
| | | |
| | | .card-body-item { |
| | | display: inline-block; |
| | |
| | | <div class="layui-card"> |
| | | <div class="layui-card-header"> |
| | | <span>跟进人</span> |
| | | <span id="follower-add" style="float: right;cursor: pointer;"> |
| | | <span lay-filter="followerAdd" lay-submit style="float: right;cursor: pointer;"> |
| | | <i class="layui-icon" style="font-size: 20px;color: #1890ff;"></i> |
| | | </span> |
| | | </div> |
| | |
| | | |
| | | <div class="form-group-bottom text-right"> |
| | | <button class="layui-btn" lay-filter="refresh" lay-submit><i class="layui-icon"></i> 刷新 </button> |
| | | <button class="layui-btn layui-btn-normal" lay-filter="save" lay-submit><i class="layui-icon"></i> 保存 </button> |
| | | </div> |
| | | |
| | | </form> |
| | |
| | | var follTab = table.render({ |
| | | elem: '#followersTable', |
| | | data: res.data, |
| | | limit: 999, |
| | | height: 'full-418', |
| | | cols: [[ |
| | | {field: 'userName', title: '工作人员'}, |
| | | {fixed: 'right', title:'', align: 'center', toolbar: '#followerTabOperate', width: 70} |
| | |
| | | |
| | | // 添加跟进人 |
| | | var followerLayer; |
| | | $(document).on('click', "#follower-add", function () { |
| | | form.on('submit(followerAdd)', function (data) { |
| | | if (followerLayer) {return;} |
| | | followerLayer = admin.open({ |
| | | type: 1, |
| | |
| | | layer.msg("请选择至少一条数据", {icon: 3}); |
| | | return false; |
| | | } |
| | | let loadIndex = layer.load(2); |
| | | $.ajax({ |
| | | url: baseUrl+"/cstmr/followers/add/auth", |
| | | headers: {'token': localStorage.getItem('token')}, |
| | |
| | | method: 'POST', |
| | | success: function (res) { |
| | | if (res.code === 200){ |
| | | layer.close(loadIndex); |
| | | initFollowers(cstmrId); |
| | | } else if (res.code === 403){ |
| | | top.location.href = baseUrl+"/"; |
| | |
| | | // 弹窗不出现滚动条 |
| | | $(layero).children('.layui-layer-content').css('overflow', 'visible'); |
| | | layui.form.render('select'); |
| | | }, |
| | | end: function () { |
| | | followerLayer = null; |
| | | } |
| | | }) |
| | | }) |
| | | }); |
| | | |
| | | /* 监听表单提交 */ |
| | | form.on('submit(refresh)', function (data) { |
| | | init(); |
| | | return false; |
| | | }); |
| | | form.on('submit(save)', function (elem) { |
| | | let data = elem.field; |
| | | notice.msg('正在拼命修改数据......', {icon: 4, position: "topRight"}); |
| | | $.ajax({ |
| | | url: baseUrl + "/issue/process/auth", |
| | | headers: {'token': localStorage.getItem('token')}, |
| | | contentType: 'application/json;charset=UTF-8', |
| | | method: 'POST', |
| | | data: JSON.stringify({ |
| | | id: Number(data.id), |
| | | uuid: data.uuid, |
| | | dealer: data.dealer, |
| | | settle: Number(data.settle), |
| | | endTime: top.strToDate(data.endTime$), |
| | | // lastTime: data.lastTime, |
| | | reason: data.reason, |
| | | deal: data.deal, |
| | | }), |
| | | success: function (res) { |
| | | notice.destroy(); |
| | | if (res.code === 200) { |
| | | notice.success({title: '消息通知', message: res.msg}); |
| | | $('.layui-layer-close').click(); |
| | | } else if (res.code === 403) { |
| | | top.location.href = baseUrl + "/"; |
| | | } else { |
| | | notice.error({title: '消息通知', message: res.msg}); |
| | | } |
| | | } |
| | | }) |
| | | return false; |
| | | }); |
| | | |
| | | }); |
| | | }) |
| | | </script> |