2023-09-21 18:46:30 +00:00
|
|
|
<html login="false" auth="false">
|
|
|
|
<head>
|
|
|
|
<meta charset="UTF-8">
|
|
|
|
<title>热线等级</title>
|
|
|
|
</head>
|
|
|
|
<body>
|
|
|
|
<div widget="toolbar" style="padding:5px;border:0;">
|
|
|
|
|
|
|
|
|
|
|
|
<input widget="combox" name="orgname" label="分公司" url="rush/hot/getOrgList"
|
|
|
|
emptyText="请选择" textField="text" valueField="text" allowInput="false"
|
|
|
|
showNullItem="true"/>
|
|
|
|
<input widget="edit" name="custname" label="客户名称"/>
|
|
|
|
<input widget="edit" name="custtaxno" label="客户税号"/>
|
|
|
|
<input widget="edit" name="mobile" label="联系电话"/>
|
|
|
|
<input name="state" widget=combox allowinput="f" style="width: 200px;" showNullItem="true"
|
|
|
|
data="[{id:'0',text:'无效'},{id:'1',text:'有效'}]" emptyText="请选择" label="状态">
|
2023-09-26 00:20:25 +00:00
|
|
|
|
|
|
|
<input widget="combox" name="mprice" label="价格" url="rush/hot/getmprice" multiSelect="true"
|
|
|
|
emptyText="请选择" textField="text" valueField="text" allowInput="false"
|
|
|
|
showNullItem="true"/>
|
|
|
|
|
|
|
|
<input widget="combox" name="mlevel" label="等级" url="rush/hot/getmlevel" multiSelect="true"
|
|
|
|
emptyText="请选择" textField="text" valueField="text" allowInput="false"
|
|
|
|
showNullItem="true"/>
|
|
|
|
|
2023-09-21 18:46:30 +00:00
|
|
|
<a widget="button" iconCls="icon-search" onclick="search()">查询</a>
|
|
|
|
<a widget="button" iconCls="icon-add" onclick="add">新增</a>
|
2023-09-25 10:43:17 +00:00
|
|
|
<a widget="button" iconCls="icon-save" onclick="weihu">维护</a>
|
2023-09-21 18:46:30 +00:00
|
|
|
</div>
|
|
|
|
<div widget="autosize">
|
2023-09-25 10:43:17 +00:00
|
|
|
<div widget="datagrid" name="grid" style="width: 100%; height: 100%;" url="rush/hot/getlist" onrowdblclick="pay()">
|
2023-09-21 18:46:30 +00:00
|
|
|
<div type="indexcolumn" width="35" header="序号"></div>
|
|
|
|
<div field="id" visible="id"></div>
|
|
|
|
<div field="khid" visible="id"></div>
|
|
|
|
<div field="custname" width="60" header="客户名称" align="center"></div>
|
|
|
|
<div field="custtaxno" width="60" header="客户税号" align="center"></div>
|
|
|
|
<div field="createdate" width="60" header="创建日期" align="center"></div>
|
|
|
|
<div field="mobile" width="50" header="联系电话" align="center"></div>
|
|
|
|
<div field="enddate" width="35" header="到期日期" align="center"></div>
|
|
|
|
<div field="orgname" width="50" header="分公司" align="center"></div>
|
|
|
|
<div field="state" width="30" header="状态" renderer="statetype" align="center"></div>
|
|
|
|
<div field="mlevel" width="30" header="等级" align="center"></div>
|
|
|
|
<div field="mprice" width="40" header="金额" align="center"></div>
|
|
|
|
<div field="caozuo" width="45" align="center" renderer="onRenderer" header="操作"></div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</body>
|
|
|
|
|
|
|
|
<script type="text/javascript">
|
|
|
|
|
|
|
|
var grid = aos.get('grid');
|
|
|
|
function search() {
|
|
|
|
var grid = aos.get('grid');
|
|
|
|
var params = {
|
|
|
|
mobile: aos.get('mobile').getValue(),
|
|
|
|
custname: aos.get('custname').getValue(),
|
|
|
|
custtaxno: aos.get('custtaxno').getValue(),
|
|
|
|
orgname: aos.get('orgname').getValue(),
|
2023-09-26 00:20:25 +00:00
|
|
|
mlevel: aos.get('mlevel').getValue(),
|
|
|
|
mprice: aos.get('mprice').getValue(),
|
2023-09-21 18:46:30 +00:00
|
|
|
state: aos.get('state').getValue()
|
|
|
|
};
|
|
|
|
grid.load(params);
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
function onRenderer(e) {
|
|
|
|
if (e.row.state == '0') {
|
|
|
|
return "<a href='javascript:void(0)' style='text-decoration:none' onclick='huifu(\"" + e.row.id + "\")'>" + "恢复";
|
|
|
|
}
|
|
|
|
if (e.row.state=='1') {
|
2023-09-25 10:43:17 +00:00
|
|
|
return "<a href='javascript:void(0)' onclick='rekp(\"" + e.row.id + "\")'>" + "删除(状态==>无效)";
|
2023-09-21 18:46:30 +00:00
|
|
|
}
|
|
|
|
return "暂无操作";
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
function rekp(id) {
|
|
|
|
aos.post({
|
|
|
|
url: 'rush/hot/delete',
|
|
|
|
data: {id: id},
|
|
|
|
success: function () {
|
|
|
|
grid.reload();
|
|
|
|
}
|
|
|
|
|
|
|
|
});
|
|
|
|
}
|
|
|
|
|
|
|
|
function huifu(id) {
|
|
|
|
aos.post({
|
|
|
|
url: 'rush/hot/huifu',
|
|
|
|
data: {id: id},
|
|
|
|
success: function () {
|
|
|
|
grid.reload();
|
|
|
|
}
|
|
|
|
|
|
|
|
});
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
function statetype(e) {
|
|
|
|
var row = e.row;
|
|
|
|
var value = row.state;
|
|
|
|
if (value == '0') {
|
|
|
|
return '<p style="color:red;">无效</p>';
|
|
|
|
}
|
|
|
|
if (value == '1') {
|
|
|
|
return '<p style="color:green;">有效</p>';
|
|
|
|
|
|
|
|
} else {
|
|
|
|
return value;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
function add() {
|
|
|
|
var param = {};
|
|
|
|
aos.showWindow('canvas/bureau/hotadd', param, '600px', '500px', '热线数据新增', function(rtnValue){
|
|
|
|
grid.reload();
|
|
|
|
});
|
|
|
|
}
|
|
|
|
|
2023-09-25 10:43:17 +00:00
|
|
|
function weihu() {
|
|
|
|
var param = {};
|
|
|
|
aos.showWindow('canvas/bureau/weihu', param, '600px', '800px', '热线维护', function(rtnValue){
|
|
|
|
grid.reload();
|
|
|
|
});
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
function pay(){
|
|
|
|
var data = grid.getSelected();
|
|
|
|
if(!data){
|
|
|
|
aos.alert('请选择一条数据!');
|
|
|
|
return;
|
|
|
|
}
|
|
|
|
var param = {};
|
|
|
|
param['pageState'] = 'editold';
|
|
|
|
param['id'] = data.id ;
|
|
|
|
param['khid'] = data.khid;
|
|
|
|
param['custname'] = data.custname;
|
|
|
|
param['custtaxno'] = data.custtaxno;
|
|
|
|
param['mobile'] = data.mobile;
|
|
|
|
param['enddate'] = data.enddate;
|
|
|
|
param['orgname'] = data.orgname;
|
|
|
|
param['state'] = data.state;
|
|
|
|
param['mlevel'] = data.mlevel;
|
|
|
|
param['mprice'] = data.mprice;
|
|
|
|
dakai(param);
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
function dakai(param){
|
|
|
|
aos.showWindow('canvas/bureau/hotupdate', param, '600', '590px', '热线等级更新', function(rtnValue){
|
|
|
|
grid.reload();
|
|
|
|
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
}
|
|
|
|
|
2023-09-21 18:46:30 +00:00
|
|
|
</script>
|
|
|
|
</html>
|