parent
9352b1ef29
commit
3d9c222cf4
@ -1,10 +1,104 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<html lang="zh" xmlns:th="http://www.thymeleaf.org" xmlns:shiro="http://www.pollix.at/thymeleaf/shiro">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<title>Title</title>
|
||||
<th:block th:include="include :: header('设备登记列表')" />
|
||||
</head>
|
||||
<body>
|
||||
<body class="gray-bg">
|
||||
<div class="container-div">
|
||||
<div class="row">
|
||||
<div class="col-sm-12 search-collapse">
|
||||
<form id="formId">
|
||||
<div class="select-list">
|
||||
<ul>
|
||||
<li>
|
||||
<label>资产编号:</label>
|
||||
<input type="text" name="useId"/>
|
||||
</li>
|
||||
<li>
|
||||
<label>设备品牌:</label>
|
||||
<input type="text" name="propertyBrand"/>
|
||||
</li>
|
||||
<li>
|
||||
<label>资产型号:</label>
|
||||
<input type="text" name="propertyNo"/>
|
||||
</li>
|
||||
<li>
|
||||
<a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search()"><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>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
|
||||
<div class="btn-group-sm" id="toolbar" role="group">
|
||||
|
||||
</div>
|
||||
<div class="col-sm-12 select-table table-striped">
|
||||
<table id="bootstrap-table"></table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<th:block th:include="include :: footer" />
|
||||
<script th:inline="javascript">
|
||||
var editFlag = [[${@permission.hasPermi('system:changeproperty:change')}]];
|
||||
var destoryFlag = [[${@permission.hasPermi('system:changeproperty:destory')}]];
|
||||
var removeFlag = [[${@permission.hasPermi('system:changeproperty:remove')}]];
|
||||
var propertyTypeDatas = [[${@dict.getType('sys_sm_property')}]];
|
||||
var prefix = ctx + "system/propertychange";
|
||||
|
||||
$(function() {
|
||||
var options = {
|
||||
url: prefix + "/list",
|
||||
createUrl: prefix + "/add",
|
||||
updateUrl: prefix + "/edit/{id}",
|
||||
destoryUrl: prefix + "/destory/{id}",
|
||||
removeUrl: prefix + "/remove",
|
||||
exportUrl: prefix + "/export",
|
||||
modalName: "设备登记",
|
||||
columns: [{
|
||||
checkbox: true
|
||||
},
|
||||
{
|
||||
field: 'useId',
|
||||
title: '资产编号'
|
||||
},
|
||||
{
|
||||
field: 'propertyBrand',
|
||||
title: '设备品牌'
|
||||
},
|
||||
{
|
||||
field: 'propertyType',
|
||||
title: '资产种类',
|
||||
formatter: function(value, row, index) {
|
||||
return $.table.selectDictLabel(propertyTypeDatas, value);
|
||||
}
|
||||
},
|
||||
{
|
||||
field: 'propertyNo',
|
||||
title: '资产型号'
|
||||
},
|
||||
{
|
||||
field: 'propertySn',
|
||||
title: '资产SN码'
|
||||
},
|
||||
{
|
||||
title: '操作',
|
||||
align: 'center',
|
||||
formatter: function(value, row, index) {
|
||||
var actions = [];
|
||||
actions.push('<a class="btn btn-success btn-xs ' + editFlag + '" href="javascript:void(0)" onclick="$.operate.edit(\'' + row.id + '\')"><i class="fa fa-edit"></i>变更</a> ');
|
||||
actions.push('<a class="btn btn-danger btn-xs ' + destoryFlag + '" href="javascript:void(0)" onclick="destory(\'' + row.id + '\')"><i class="fa fa-remove"></i>报废</a>');
|
||||
return actions.join('');
|
||||
}
|
||||
}]
|
||||
};
|
||||
$.table.init(options);
|
||||
});
|
||||
function destory(id) {
|
||||
var url = prefix + '/destory/' + id;
|
||||
$.modal.open("销毁资产", url);
|
||||
}
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
Loading…
Reference in new issue