提交 d107657e 编写于 作者: Skyeye云's avatar Skyeye云

ERP调拨单修改

上级 7c59d68f
...@@ -179,7 +179,7 @@ layui.config({ ...@@ -179,7 +179,7 @@ layui.config({
remark: $("#remark").val(), remark: $("#remark").val(),
depotheadStr: JSON.stringify(tableData) depotheadStr: JSON.stringify(tableData)
}; };
AjaxPostUtil.request({url: reqBasePath + "allocation002", params: params, type: 'json', callback: function(json) { AjaxPostUtil.request({url: flowableBasePath + "allocation002", params: params, type: 'json', callback: function(json) {
if(json.returnCode == 0) { if(json.returnCode == 0) {
parent.layer.close(index); parent.layer.close(index);
parent.refreshCode = '0'; parent.refreshCode = '0';
......
...@@ -12,7 +12,7 @@ layui.config({ ...@@ -12,7 +12,7 @@ layui.config({
showGrid({ showGrid({
id: "showForm", id: "showForm",
url: reqBasePath + "erpcommon001", url: flowableBasePath + "erpcommon001",
params: {rowId: parent.rowId}, params: {rowId: parent.rowId},
pagination: false, pagination: false,
template: beanTemplate, template: beanTemplate,
......
...@@ -26,7 +26,7 @@ layui.config({ ...@@ -26,7 +26,7 @@ layui.config({
var orderObject = []; var orderObject = [];
showGrid({ showGrid({
id: "showForm", id: "showForm",
url: reqBasePath + "allocation003", url: flowableBasePath + "allocation003",
params: {rowId: parent.rowId}, params: {rowId: parent.rowId},
pagination: false, pagination: false,
template: beanTemplate, template: beanTemplate,
...@@ -169,7 +169,6 @@ layui.config({ ...@@ -169,7 +169,6 @@ layui.config({
} }
form.on('submit(formEditBean)', function(data) { form.on('submit(formEditBean)', function(data) {
if(winui.verifyForm(data.elem)) { if(winui.verifyForm(data.elem)) {
//获取已选商品数据 //获取已选商品数据
var rowTr = $("#useTable tr"); var rowTr = $("#useTable tr");
...@@ -224,7 +223,7 @@ layui.config({ ...@@ -224,7 +223,7 @@ layui.config({
depotheadStr: JSON.stringify(tableData), depotheadStr: JSON.stringify(tableData),
rowId: parent.rowId rowId: parent.rowId
}; };
AjaxPostUtil.request({url: reqBasePath + "allocation004", params: params, type: 'json', callback: function(json) { AjaxPostUtil.request({url: flowableBasePath + "allocation004", params: params, type: 'json', callback: function(json) {
if(json.returnCode == 0) { if(json.returnCode == 0) {
parent.layer.close(index); parent.layer.close(index);
parent.refreshCode = '0'; parent.refreshCode = '0';
......
var rowId = ""; var rowId = "";
//单据的开始时间、结束时间
var startTime = "", endTime = "";
layui.config({ layui.config({
base: basePath, base: basePath,
version: skyeyeVersion version: skyeyeVersion
...@@ -27,7 +24,7 @@ layui.config({ ...@@ -27,7 +24,7 @@ layui.config({
id: 'messageTable', id: 'messageTable',
elem: '#messageTable', elem: '#messageTable',
method: 'post', method: 'post',
url: reqBasePath + 'allocation001', url: flowableBasePath + 'allocation001',
where: getTableParams(), where: getTableParams(),
even: true, even: true,
page: true, page: true,
...@@ -78,43 +75,35 @@ layui.config({ ...@@ -78,43 +75,35 @@ layui.config({
} }
}); });
form.render(); // 删除
form.on('submit(formSearch)', function (data) {
if (winui.verifyForm(data.elem)) {
loadTable();
}
return false;
});
//删除
function deletemember(data){ function deletemember(data){
layer.confirm(systemLanguage["com.skyeye.deleteOperationMsg"][languageType], {icon: 3, title: systemLanguage["com.skyeye.deleteOperation"][languageType]}, function(index){ layer.confirm(systemLanguage["com.skyeye.deleteOperationMsg"][languageType], {icon: 3, title: systemLanguage["com.skyeye.deleteOperation"][languageType]}, function(index){
AjaxPostUtil.request({url:reqBasePath + "delcommon011", params: {rowId: data.id}, type:'json', callback:function(json){ AjaxPostUtil.request({url: flowableBasePath + "delcommon011", params: {rowId: data.id}, type: 'json', callback: function(json){
if(json.returnCode == 0){ if(json.returnCode == 0){
winui.window.msg(systemLanguage["com.skyeye.deleteOperationSuccessMsg"][languageType], {icon: 1,time: 2000}); winui.window.msg(systemLanguage["com.skyeye.deleteOperationSuccessMsg"][languageType], {icon: 1, time: 2000});
loadTable(); loadTable();
}else{ }else{
winui.window.msg(json.returnMessage, {icon: 2,time: 2000}); winui.window.msg(json.returnMessage, {icon: 2, time: 2000});
} }
}}); }});
}); });
} }
//提交审批 // 提交审批
function subExamine(data){ function subExamine(data){
layer.confirm('确认要提交审核吗?', { icon: 3, title: '提交审核操作' }, function (index) { layer.confirm('确认要提交审核吗?', { icon: 3, title: '提交审核操作' }, function (index) {
AjaxPostUtil.request({url:reqBasePath + "allocation006", params: {rowId: data.id}, type:'json', callback:function(json){ AjaxPostUtil.request({url: flowableBasePath + "allocation006", params: {rowId: data.id}, type: 'json', callback: function(json){
if(json.returnCode == 0){ if(json.returnCode == 0){
winui.window.msg("提交成功。", {icon: 1,time: 2000}); winui.window.msg("提交成功。", {icon: 1, time: 2000});
loadTable(); loadTable();
}else{ }else{
winui.window.msg(json.returnMessage, {icon: 2,time: 2000}); winui.window.msg(json.returnMessage, {icon: 2, time: 2000});
} }
}}); }});
}); });
} }
//编辑 // 编辑
function edit(data){ function edit(data){
rowId = data.id; rowId = data.id;
_openNewWindows({ _openNewWindows({
...@@ -132,7 +121,7 @@ layui.config({ ...@@ -132,7 +121,7 @@ layui.config({
}}); }});
} }
//详情 // 详情
function details(data){ function details(data){
rowId = data.id; rowId = data.id;
_openNewWindows({ _openNewWindows({
...@@ -144,7 +133,7 @@ layui.config({ ...@@ -144,7 +133,7 @@ layui.config({
}}); }});
} }
//添加 // 添加
$("body").on("click", "#addBean", function(){ $("body").on("click", "#addBean", function(){
_openNewWindows({ _openNewWindows({
url: "../../tpl/allocation/allocationadd.html", url: "../../tpl/allocation/allocationadd.html",
...@@ -161,40 +150,38 @@ layui.config({ ...@@ -161,40 +150,38 @@ layui.config({
}}); }});
}); });
// 导出excel
$("body").on("click", "#downloadExcel", function () {
postDownLoadFile({
url : flowableBasePath + 'allocation005?userToken=' + getCookie('userToken') + '&loginPCIp=' + returnCitySN["cip"],
params: getTableParams(),
method : 'post'
});
});
form.render();
form.on('submit(formSearch)', function (data) {
if (winui.verifyForm(data.elem)) {
table.reload("messageTable", {page: {curr: 1}, where: getTableParams()})
}
return false;
});
$("body").on("click", "#reloadTable", function() { $("body").on("click", "#reloadTable", function() {
loadTable(); loadTable();
}); });
$("body").on("click", "#formSearch", function () { // 刷新
refreshTable();
});
//刷新
function loadTable(){ function loadTable(){
table.reload("messageTable", {where: getTableParams()}); table.reload("messageTable", {where: getTableParams()});
} }
//搜索
function refreshTable(){
table.reload("messageTable", {page: {curr: 1}, where: getTableParams()})
}
//导出excel
$("body").on("click", "#downloadExcel", function () {
postDownLoadFile({
url : reqBasePath + 'allocation005?userToken=' + getCookie('userToken') + '&loginPCIp=' + returnCitySN["cip"],
params: getTableParams(),
method : 'post'
});
});
function getTableParams(){ function getTableParams(){
if(isNull($("#operTime").val())){//一定要记得,当createTime为空时 // 单据的开始时间、结束时间
startTime = ""; var startTime = "", endTime = "";
endTime = ""; if(!isNull($("#operTime").val())){//一定要记得,当createTime为空时
}else { startTime = $("#operTime").val().split('~')[0].trim() + ' 00:00:00';
startTime = $("#operTime").val().split('~')[0].trim() + ' 00:00:00'; endTime = $("#operTime").val().split('~')[1].trim() + ' 23:59:59';
endTime = $("#operTime").val().split('~')[1].trim() + ' 23:59:59';
} }
return { return {
defaultNumber: $("#defaultNumber").val(), defaultNumber: $("#defaultNumber").val(),
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册