提交 e445de01 编写于 作者: doc_wei's avatar doc_wei

我的用品领用历史重构完成

上级 ad1e6095
var rowId = "";
layui.config({
base: basePath,
version: skyeyeVersion
......@@ -12,63 +10,49 @@ layui.config({
form = layui.form,
table = layui.table;
showList();
// 我的用品领用历史列表
function showList(){
table.render({
id: 'messageTable',
elem: '#messageTable',
method: 'post',
url: flowableBasePath + 'myhasmation004',
where: getTableParams(),
even: true,
page: true,
limits: getLimits(),
limit: getLimit(),
cols: [[
{ title: systemLanguage["com.skyeye.serialNumber"][languageType], rowspan: '3', type: 'numbers' },
{ field: 'name', title: '用品名称', align: 'left', rowspan: '3', width: 120 },
{ field: 'articlesNum', title: '用品编号', align: 'left', rowspan: '3', width: 200 },
{ field: 'specifications', title: '用品规格', align: 'left', rowspan: '3', width: 80 },
{ field: 'typeName', title: '用品类型', align: 'left', rowspan: '3', width: 120 },
{ field: 'applyUseNum', title: '领用数量', align: 'left', rowspan: '3', width: 80 },
{ title: '所属单据', align: 'center', colspan: '3'}
],[
{ field: 'oddTitle', title: '单据标题', align: 'left', width: 240},
{ field: 'oddNumber', title: '单据编号', align: 'center', width: 180},
{ field: 'oddCreateTime', title: '单据日期', align: 'center', width: 140}
]],
done: function(json) {
matchingLanguage();
}
});
}
$("body").on("click", "#reloadmessageTable", function() {
loadTable();
});
form.render();
form.on('submit(formSearch)', function (data) {
if (winui.verifyForm(data.elem)) {
refreshTable();
table.render({
id: 'messageTable',
elem: '#messageTable',
method: 'post',
url: sysMainMation.admBasePath + 'myhasmation004',
where: getTableParams(),
even: true,
page: true,
limits: getLimits(),
limit: getLimit(),
cols: [[
{ title: systemLanguage["com.skyeye.serialNumber"][languageType], rowspan: '3', type: 'numbers' },
{ field: 'name', title: '用品名称', align: 'left', rowspan: '3', width: 120 },
{ field: 'articlesNum', title: '用品编号', align: 'left', rowspan: '3', width: 200 },
{ field: 'specifications', title: '用品规格', align: 'left', rowspan: '3', width: 80 },
{ field: 'typeName', title: '用品类型', align: 'left', rowspan: '3', width: 120 },
{ field: 'applyUseNum', title: '领用数量', align: 'left', rowspan: '3', width: 80 },
{ title: '所属单据', align: 'center', colspan: '3'}
],[
{ field: 'title', title: '单据标题', align: 'left', width: 240},
{ field: 'oddNumber', title: '单据编号', align: 'center', width: 180},
{ field: 'createTime', title: '单据日期', align: 'center', width: 140}
]],
done: function(json) {
matchingLanguage();
initTableSearchUtil.initAdvancedSearch(this, json.searchFilter, form, "请输入单号,用品名称", function () {
table.reloadData("messageTable", {page: {curr: 1}, where: getTableParams()});
});
}
return false;
});
function loadTable() {
table.reloadData("messageTable", {where: getTableParams()});
}
form.render();
$("body").on("click", "#reloadTable", function() {
loadTable();
});
function loadTable() {
table.reloadData("messageTable", {where: getTableParams()});
}
function refreshTable(){
table.reloadData("messageTable", {page: {curr: 1}, where: getTableParams()});
function getTableParams() {
return $.extend(true, {}, initTableSearchUtil.getSearchValue("messageTable"));
}
function getTableParams() {
return {
articlesName: $("#articlesName").val(),
articlesNum: $("#articlesNum").val()
};
}
exports('myAssetArticlesManagement', {});
});
......@@ -7,33 +7,13 @@
<link href="../../assets/lib/winui/css/winui.css" rel="stylesheet" />
</head>
<body>
<div style="margin:0 auto; height: 100%;">
<div class="txtcenter" style="margin:0 auto; padding-top: 10px;">
<form class="layui-form layui-form-pane" action="" autocomplete="off">
<div class="layui-form-item">
<div class="layui-inline">
<label class="layui-form-label">用品名称</label>
<div class="layui-input-inline">
<input type="text" id="articlesName" name="articlesName" placeholder="请输入用品名称" class="layui-input" />
</div>
<label class="layui-form-label">用品编号</label>
<div class="layui-input-inline">
<input type="text" id="articlesNum" name="articlesNum" placeholder="请输入用品编号" class="layui-input" />
</div>
<button type="reset" class="layui-btn layui-btn-primary list-form-search"><language showName="com.skyeye.reset"></language></button>
<button class="layui-btn list-form-search" lay-submit lay-filter="formSearch"><language showName="com.skyeye.search2"></language></button>
</div>
</div>
</form>
<div class="winui-toolbar">
<div class="winui-tool">
<button id="reloadTable" class="winui-toolbtn search-table-btn-right"><i class="fa fa-refresh" aria-hidden="true"></i><language showName="com.skyeye.refreshDataBtn"></language></button>
</div>
<div class="winui-toolbar">
<div class="winui-tool" style="text-align: left;">
<button id="reloadmessageTable" class="winui-toolbtn"><i class="fa fa-refresh" aria-hidden="true"></i><language showName="com.skyeye.refreshDataBtn"></language></button>
</div>
</div>
<div style="margin:auto 10px;">
<table id="messageTable" lay-filter="messageTable"></table>
</div>
</div>
<div style="margin:auto 10px;">
<table id="messageTable" lay-filter="messageTable"></table>
</div>
<script src="../../assets/lib/layui/layui.js"></script>
<script src="../../assets/lib/layui/custom.js"></script>
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册