Mini.Crm/Mini.Web/Areas/Admin/Views/QDOutHHuser/Find.cshtml

135 lines
4.7 KiB
Plaintext
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

@using Mini.Web.WebHelper;
@{
ViewBag.Title = "Index";
Layout = "~/Areas/Admin/Views/Shared/_content.cshtml";
}
<div class="layui-fluid" style="padding-left:0px;">
<div class="layui-card" id="topcard" style="width:100%;">
<div class="layui-card-body " id="contentBody">
<form class="layui-form " id="myform">
<div class="layui-form-item">
客服手机号:
<div class="layui-inline">
<input type="text" name="myphone" required lay-verify="required" placeholder="输入客服企业微信手机号码" autocomplete="off" class="layui-input">
</div>
客户:
<div class="layui-inline">
<input type="text" name="name" required lay-verify="required" placeholder="昵称/备注/手机号" autocomplete="off" class="layui-input">
<input type="hidden" name="companycode" value="@Html.Raw(ViewBag.companycode)" />
</div>
<div class="layui-inline">
<input class="layui-btn layui-btn-sm layui-btn-ok" data-method="search" type="button" value="查询" /><input class="layui-btn layui-btn-sm layui-btn-reset" type="reset" value="清空" />
</div>
</div>
</form>
<table class="layui-hide" id="tab_kefuzhuangtaiyi1" lay-filter="wochao"></table>
</div>
</div>
</div>
<!--确定宽度-->
<script>
var table;
</script>
<script>
layui.use('laydate', function () {
var laydate = layui.laydate;
//执行一个laydate实例
laydate.render({
elem: '#start' //指定元素
});
//执行一个laydate实例
laydate.render({
elem: '#end' //指定元素
});
});
var selectRow = {};
var winindex;
var layer;
var rowid;
//注意:选项卡 依赖 element 模块,否则无法进行功能性操作
layui.use('element', function () {
var element = layui.element;
element.on('tab(tonghuajiankong)', function (n) {
$(".bodytable").addClass("hidden");
$("#kefuzhuangtai" + (n.index + 1)).removeClass("hidden");
});
element.on('tab(maintab)', function (n) {
if (n.index == 0)
$("#bottomcard").removeClass("hidden");
else
$("#bottomcard").addClass("hidden");
});
});
layui.use(['laypage', 'layer', 'table', 'laydate'], function () {
var laydate = layui.laydate;
layer = layui.layer;
table = layui.table;
table.render({
id: 'listReload'//列表别名ID
, elem: '#tab_kefuzhuangtaiyi1'
//, url: 'GetOuterHtmlList'
, data: []
, method: 'POST'
, cellMinWidth: 80 //全局定义常规单元格的最小宽度layui 2.2.1 新增
, page: true
, limit: 30
, height: "full-160"
, cols: [[
{ field: 'numbers', type: 'numbers' }
, { field: 'corpname', title: '企业号' }
, { field: 'userid', title: '客服ID' }
, { field: 'uname', title: '客服名称' }
, { field: 'name', title: '客户名称' }
, { field: 'remark', title: '客户备注' }
, { field: 'createtime', title: '时间' }
, { field: 'remark_mobiles', title: '备注号码' }
]]
, where: $("#myform").serializeFormJSON()
});
//监听行单击事件单击事件为rowDouble
table.on('row(wochao)', function (obj) {
var data = obj.data;
//标注选中样式
obj.tr.addClass('self-table-click').siblings().removeClass('self-table-click');
selectRow = data;
});
var active = {
search: function () {
var param = $("#myform").serializeFormJSON();
table.reload('listReload', {
url: 'GetFindHtmlList',
where: param
});
}
};
$('.layui-btn').on('click', function () {
var othis = $(this), method = othis.data('method');
console.log(method);
active[method] ? active[method].call(this, othis) : '';
});
});
function Closed() {
layer.close(winindex);
}
function TableReload() {
table.reload('listReload', {
});
}
</script>
<script type="text/html" id="agentTpl">
{{# if(d.ISOUTERAGENT == '1'){ }}
{{# } else if(d.ISOUTERAGENT == '0') { }}
{{# } }}
</script>