修复tab页查询
This commit is contained in:
parent
7d3edbd9de
commit
3dea06e072
|
@ -29,7 +29,7 @@ public class ReportController extends BaseController
|
||||||
**/
|
**/
|
||||||
|
|
||||||
@RequiresPermissions("system:jmreport:design")
|
@RequiresPermissions("system:jmreport:design")
|
||||||
@GetMapping("/list")
|
@GetMapping("/design")
|
||||||
public String reportDesign()
|
public String reportDesign()
|
||||||
{
|
{
|
||||||
|
|
||||||
|
|
|
@ -31,14 +31,6 @@
|
||||||
<label>客户名称:</label>
|
<label>客户名称:</label>
|
||||||
<input type="text" name="customerName" id="seasCustomerName"/>
|
<input type="text" name="customerName" id="seasCustomerName"/>
|
||||||
</li>
|
</li>
|
||||||
|
|
||||||
<li>
|
|
||||||
<label>客户状态:</label>
|
|
||||||
<select name="customerStatus" id="seasCustomerStatus" th:with="type=${@dict.getType('sys_customer_status')}">
|
|
||||||
<option value="">所有</option>
|
|
||||||
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
|
|
||||||
</select>
|
|
||||||
</li>
|
|
||||||
<li>
|
<li>
|
||||||
<label>所属行业:</label>
|
<label>所属行业:</label>
|
||||||
<select name="customerIndustry" id="seasCustomerIndustry" th:with="type=${@dict.getType('sys_industry_type')}">
|
<select name="customerIndustry" id="seasCustomerIndustry" th:with="type=${@dict.getType('sys_industry_type')}">
|
||||||
|
@ -48,7 +40,7 @@
|
||||||
</li>
|
</li>
|
||||||
<li>
|
<li>
|
||||||
<a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search('formId3','bootstrap-table3')"><i class="fa fa-search"></i> 搜索</a>
|
<a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search('formId3','bootstrap-table3')"><i class="fa fa-search"></i> 搜索</a>
|
||||||
<a class="btn btn-warning btn-rounded btn-sm" onclick="$.form.reset()"><i class="fa fa-refresh"></i> 重置</a>
|
<a class="btn btn-warning btn-rounded btn-sm" onclick="$.form.reset('formId3','bootstrap-table3')"><i class="fa fa-refresh"></i> 重置</a>
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
|
@ -78,30 +70,27 @@
|
||||||
<div id="tab-2" class="tab-pane">
|
<div id="tab-2" class="tab-pane">
|
||||||
<div class="panel-body">
|
<div class="panel-body">
|
||||||
<div class="col-sm-12 search-collapse">
|
<div class="col-sm-12 search-collapse">
|
||||||
<form id="formId1">
|
<form id="myformId">
|
||||||
<div class="select-list">
|
<div class="select-list">
|
||||||
<ul>
|
<ul>
|
||||||
<li>
|
<li>
|
||||||
<label>客户编号:</label>
|
<label>客户编号:</label>
|
||||||
<input type="text" name="customerNo"/>
|
<input type="text" name="customerNo" id="myCustomerNo"/>
|
||||||
</li>
|
</li>
|
||||||
<li>
|
<li>
|
||||||
<label>客户名称:</label>
|
<label>客户名称:</label>
|
||||||
<input type="text" name="customerName"/>
|
<input type="text" name="customerName" id="myCustomerName"/>
|
||||||
</li>
|
</li>
|
||||||
|
|
||||||
|
|
||||||
<li>
|
<li>
|
||||||
<label>所属行业:</label>
|
<label>所属行业:</label>
|
||||||
<select name="customerIndustry" th:with="type=${@dict.getType('sys_industry_type')}">
|
<select name="customerIndustry" id="myCustomerIndustry" th:with="type=${@dict.getType('sys_industry_type')}">
|
||||||
<option value="">所有</option>
|
<option value="">所有</option>
|
||||||
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
|
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
|
||||||
</select>
|
</select>
|
||||||
</li>
|
</li>
|
||||||
|
|
||||||
<li>
|
<li>
|
||||||
<a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search('formId1','table1')"><i class="fa fa-search"></i> 搜索</a>
|
<a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search('myformId','bootstrap-table1')"><i class="fa fa-search"></i> 搜索</a>
|
||||||
<a class="btn btn-warning btn-rounded btn-sm" onclick="$.form.reset()"><i class="fa fa-refresh"></i> 重置</a>
|
<a class="btn btn-warning btn-rounded btn-sm" onclick="$.form.reset('myformId','bootstrap-table1')"><i class="fa fa-refresh"></i> 重置</a>
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
|
@ -126,25 +115,25 @@
|
||||||
<ul>
|
<ul>
|
||||||
<li>
|
<li>
|
||||||
<label>客户编号:</label>
|
<label>客户编号:</label>
|
||||||
<input type="text" name="customerNo"/>
|
<input type="text" name="customerNo" id="blackCustomerNo"/>
|
||||||
</li>
|
</li>
|
||||||
<li>
|
<li>
|
||||||
<label>客户名称:</label>
|
<label>客户名称:</label>
|
||||||
<input type="text" name="customerName"/>
|
<input type="text" name="customerName" id="blackCustomerName"/>
|
||||||
</li>
|
</li>
|
||||||
|
|
||||||
|
|
||||||
<li>
|
<li>
|
||||||
<label>所属行业:</label>
|
<label>所属行业:</label>
|
||||||
<select name="customerIndustry" th:with="type=${@dict.getType('sys_industry_type')}">
|
<select name="customerIndustry" id="blackCustomerIndustry" th:with="type=${@dict.getType('sys_industry_type')}">
|
||||||
<option value="">所有</option>
|
<option value="">所有</option>
|
||||||
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
|
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
|
||||||
</select>
|
</select>
|
||||||
</li>
|
</li>
|
||||||
|
|
||||||
<li>
|
<li>
|
||||||
<a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search('formId2','table1')"><i class="fa fa-search"></i> 搜索</a>
|
<a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search('formId2','bootstrap-table2')"><i class="fa fa-search"></i> 搜索</a>
|
||||||
<a class="btn btn-warning btn-rounded btn-sm" onclick="$.form.reset()"><i class="fa fa-refresh"></i> 重置</a>
|
<a class="btn btn-warning btn-rounded btn-sm" onclick="$.form.reset('formId2','bootstrap-table2')"><i class="fa fa-refresh"></i> 重置</a>
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
|
@ -178,9 +167,7 @@
|
||||||
|
|
||||||
var visitTypeDatas = [[${@dict.getType('sys_customer_visit_type')}]];
|
var visitTypeDatas = [[${@dict.getType('sys_customer_visit_type')}]];
|
||||||
var prefix = ctx + "system/customer";
|
var prefix = ctx + "system/customer";
|
||||||
|
|
||||||
$(function() {
|
$(function() {
|
||||||
|
|
||||||
var options = {
|
var options = {
|
||||||
id:"bootstrap-table3",
|
id:"bootstrap-table3",
|
||||||
url: prefix + "/list",
|
url: prefix + "/list",
|
||||||
|
@ -191,9 +178,7 @@
|
||||||
exportUrl: prefix + "/export",
|
exportUrl: prefix + "/export",
|
||||||
modalName: "客户",
|
modalName: "客户",
|
||||||
toolbar: "toolbar1",
|
toolbar: "toolbar1",
|
||||||
queryParams:{
|
queryParams:queryParams,
|
||||||
"isHighSeas":1
|
|
||||||
},
|
|
||||||
columns: [{
|
columns: [{
|
||||||
checkbox: true
|
checkbox: true
|
||||||
},
|
},
|
||||||
|
@ -252,8 +237,17 @@
|
||||||
}]
|
}]
|
||||||
};
|
};
|
||||||
$.table.init(options);
|
$.table.init(options);
|
||||||
|
function queryParams(params) {
|
||||||
|
var search = $.table.queryParams(params);
|
||||||
|
search["isHighSeas"]=1
|
||||||
|
search.customerNo = $("#seasCustomerNo").val();
|
||||||
|
search.customerName = $("#seasCustomerName").val();
|
||||||
|
search.customerIndustry = $("#seasCustomerIndustry").val();
|
||||||
|
console.log("=======公海查询=======>"+JSON.stringify(search))
|
||||||
|
return search;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
$("#bootstrap-table").bootstrapTable('destroy');
|
|
||||||
|
|
||||||
var options1 = {
|
var options1 = {
|
||||||
id: "bootstrap-table1",
|
id: "bootstrap-table1",
|
||||||
|
@ -261,6 +255,7 @@
|
||||||
createUrl: prefix + "/visitAdd/{id}",
|
createUrl: prefix + "/visitAdd/{id}",
|
||||||
detailUrl: prefix + "/detail/{id}",
|
detailUrl: prefix + "/detail/{id}",
|
||||||
toolbar: "toolbar2",
|
toolbar: "toolbar2",
|
||||||
|
queryParams:queryParamMy,
|
||||||
detailView: true,
|
detailView: true,
|
||||||
onExpandRow : function(index, row, $detail) {
|
onExpandRow : function(index, row, $detail) {
|
||||||
initChildTable(index, row, $detail);
|
initChildTable(index, row, $detail);
|
||||||
|
@ -327,7 +322,15 @@
|
||||||
}]
|
}]
|
||||||
};
|
};
|
||||||
$.table.init(options1);
|
$.table.init(options1);
|
||||||
|
function queryParamMy(params) {
|
||||||
|
var search = $.table.queryParams(params);
|
||||||
|
search.customerNo = $("#myCustomerNo").val();
|
||||||
|
search.customerName = $("#myCustomerName").val();
|
||||||
|
search.customerIndustry = $("#myCustomerIndustry").val();
|
||||||
|
console.log("==========我的客户查询====>"+JSON.stringify(search))
|
||||||
|
return search;
|
||||||
|
|
||||||
|
}
|
||||||
var options2 = {
|
var options2 = {
|
||||||
id: "bootstrap-table2",
|
id: "bootstrap-table2",
|
||||||
url: prefix + "/list",
|
url: prefix + "/list",
|
||||||
|
@ -336,7 +339,7 @@
|
||||||
detailUrl: prefix + "/detail/{id}",
|
detailUrl: prefix + "/detail/{id}",
|
||||||
exportUrl: prefix + "/export",
|
exportUrl: prefix + "/export",
|
||||||
modalName: "客户",
|
modalName: "客户",
|
||||||
queryParams:{"customerStatus":"BLACKLIST"},
|
queryParams: queryParam,
|
||||||
columns: [{
|
columns: [{
|
||||||
checkbox: true
|
checkbox: true
|
||||||
},
|
},
|
||||||
|
@ -393,8 +396,22 @@
|
||||||
return actions.join('');
|
return actions.join('');
|
||||||
}
|
}
|
||||||
}]
|
}]
|
||||||
|
|
||||||
};
|
};
|
||||||
$.table.init(options2);
|
$.table.init(options2);
|
||||||
|
|
||||||
|
function queryParam(params) {
|
||||||
|
var search = $.table.queryParams(params);
|
||||||
|
search["customerStatus"]="BLACKLIST"
|
||||||
|
search.customerNo = $("#blackCustomerNo").val();
|
||||||
|
search.customerName = $("#blackCustomerName").val();
|
||||||
|
search.customerIndustry = $("#blackCustomerIndustry").val();
|
||||||
|
console.log("==========黑名单查询====>"+JSON.stringify(search))
|
||||||
|
return search;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
});
|
});
|
||||||
|
|
||||||
initChildTable = function(index, row, $detail) {
|
initChildTable = function(index, row, $detail) {
|
||||||
|
|
|
@ -50,7 +50,7 @@ public class CustomerStartListener extends AbstractExecutionListener<SysOaCustom
|
||||||
Long parentId = sysDept.getParentId();
|
Long parentId = sysDept.getParentId();
|
||||||
SysUser sysUser1=new SysUser();
|
SysUser sysUser1=new SysUser();
|
||||||
sysUser1.setDeptId(parentId);
|
sysUser1.setDeptId(parentId);
|
||||||
List<SysUser> sysUsers = sysUserService.selectUserList(sysUser);
|
List<SysUser> sysUsers = sysUserService.selectUserList(sysUser1);
|
||||||
if(CollectionUtils.isEmpty(sysUsers)){
|
if(CollectionUtils.isEmpty(sysUsers)){
|
||||||
setVariable("customerManager",1);
|
setVariable("customerManager",1);
|
||||||
}else {
|
}else {
|
||||||
|
|
Loading…
Reference in New Issue