Commit 442d4cce authored by 刘学辉's avatar 刘学辉

物料主数据调整和首页物料任务查看更多信息

parent 8222605a
...@@ -48,6 +48,16 @@ function showTasksMore(taskKind){ ...@@ -48,6 +48,16 @@ function showTasksMore(taskKind){
} }
} }
function showSpecialTask(taskKind){
// alert("showSpecialTask111");
//if(parent.showTaskCenter){
// parent.showTaskCenter(taskKind);
//}else{
var url = web_app.name + '/bsnMessage/forwardBsnMessage.do?viewTaskKind='+taskKind;
UICtrl.addTabItem({tabid: 'SpecialTaskCenter', text: '物料任务查询', url: url});
//}
}
function sendEmail() { function sendEmail() {
UICtrl.showAjaxDialog({ UICtrl.showAjaxDialog({
title: '邮件发送预览', title: '邮件发送预览',
......
...@@ -48,7 +48,7 @@ ...@@ -48,7 +48,7 @@
<h3 class="box-title">非产品/非本成品类物料任务</h3> <h3 class="box-title">非产品/非本成品类物料任务</h3>
<div class="box-tools pull-right"> <div class="box-tools pull-right">
<button type="button" class="btn btn-box-tool" title="刷新" onclick="reloadSpecialTaskGrid()"><i class="fa fa-repeat"></i></button> <button type="button" class="btn btn-box-tool" title="刷新" onclick="reloadSpecialTaskGrid()"><i class="fa fa-repeat"></i></button>
<button type="button" class="btn btn-box-tool" title="更多" onclick="showTask(1)"><i class="fa fa-bars"></i></button> <button type="button" class="btn btn-box-tool" title="更多" onclick="showSpecialTask(1)"><i class="fa fa-bars"></i></button>
</div> </div>
</div> </div>
<div class="box-body"> <div class="box-body">
......
var gridManager = null;
$(document).ready(function () {
initializateUI()
loadBsnMessageListGrid();
})
function initializateUI() {
UICtrl.layout("#layout", {leftWidth: 3});
}
function loadBsnMessageListGrid() {
var toolbarOptions = UICtrl.getDefaultToolbarOptions({
// addHandler: function (){
// addHandler()
// },
});
gridManager = UICtrl.grid("#bsnMessageListGrid", {
columns: [
// {display: "业务编码", name: "businessCode", width: 120, minWidth: 60, type: "date", align: "left"},
{display: "创建日期", name: "updateDate", width: 140, minWidth: 60, type: "string", align: "left"},
//{display: "完成日期", name: "finishedDate", width: 140, minWidth: 60, type: "date", align: "left"},
{display: "任务描述", name: "taskDescribe", width: 550, minWidth: 60, type: "string", align: "left"},
{display: "物料描述", name: "title", width: 500, minWidth: 60, type: "string", align: "left"}
],
dataAction: "server",
url: web_app.name + '/bsnMessage/slicedBsnMessageList.ajax',
pageSize: 20,
usePager: true,
toolbar: toolbarOptions,
width: "100%",
height: "100%",
heightDiff: -8,
checkbox: true,
async: false,
fixedCellHeight: true,
selectRowButtonOnly: true,
onDblClickRow: function (data, rowindex, rowobj) {
doView(data.id,data.businessId,data.executorUrl);
},
onAfterShowData: function (data){
console.log(data)
}
});
UICtrl.setSearchAreaToggle(gridManager);
}
function query(obj) {
var param = $(obj).formToJSON();
UICtrl.gridSearch(gridManager, param);
}
function reloadGrid() {
gridManager.loadData();
}
function resetForm(obj) {
$(obj).formClean();
}
function doView(id,businessId,url) {
var title="维护申请";
//if (maintenanceType=="modify"){
// title="变更申请";
// } else if (maintenanceType=="extend") {
// title="扩展申请";
// }
var signal = (url.indexOf("?") >= 0) ? "&" : "?";
UICtrl.addTabItem({
tabid: 'showNonProdApply'+id,
text: "非产品/非本成品类物料主数据"+title+"详情",
url: web_app.name+'/'+ url+signal+'bizId='+businessId+'&taskId='+id
//url: web_app.name + '/sapNonProdApply/showNonProdApply.job?isReadOnly=true&bizId='+id+"&isDetailPage=true"
});
}
<%@ page contentType="text/html; charset=utf-8" language="java" %>
<%@ taglib uri="/WEB-INF/taglib.tld" prefix="x" %>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<html>
<head>
<x:base include="layout,dialog,grid,tree,combox,commonTree"/>
<x:script src='/biz/topsun/sap/base/bsnMessageList.js'/>
</head>
<body>
<div class="container-fluid">
<%-- <x:button value="next" onclick="next()" icon="fa-save"/>--%>
<div class="ui-hide">
<x:select name="processType" dictionary="processType"/>
<x:select name="yesorno" dictionary="yesorno"/>
</div>
<div id="layout">
<x:title title="common.button.search" hideTable="queryMainForm" isHide="true"/>
<form class="hg-form ui-hide" method="post" action="" id="queryMainForm">
<x:inputC name="taskDescribe" required="false" label="任务描述" labelCol="1"/>
<x:inputC name="title" required="false" label="物料描述" labelCol="1"/>
<x:searchButtons/>
</form>
<div class="blank_div clearfix"></div>
<div id="bsnMessageListGrid" style="margin: 2px;"></div>
</div>
</div>
</div>
</body>
</html>
\ No newline at end of file
...@@ -17,9 +17,9 @@ ...@@ -17,9 +17,9 @@
<div position="center" title="非本成品类物料主数据维护申请表查询"> <div position="center" title="非本成品类物料主数据维护申请表查询">
<x:title title="common.button.search" hideTable="queryMainForm" isHide="true"/> <x:title title="common.button.search" hideTable="queryMainForm" isHide="true"/>
<form class="hg-form ui-hide" method="post" action="" id="queryMainForm"> <form class="hg-form ui-hide" method="post" action="" id="queryMainForm">
<x:inputC name="proofingApplyNo" required="false" label="申请单号" labelCol="1"/> <x:inputC name="billCode" required="false" label="申请单号" labelCol="1"/>
<x:inputC name="genericName" required="false" label="通用品名" labelCol="1"/>
<x:inputC name="matnr" required="false" label="物料编码" labelCol="1"/> <x:inputC name="matnr" required="false" label="物料编码" labelCol="1"/>
<x:inputC name="genericName" required="false" label="通用品名" labelCol="1"/>
<x:inputC name="maktx" required="false" label="汉语品名" labelCol="1"/> <x:inputC name="maktx" required="false" label="汉语品名" labelCol="1"/>
<x:selectC name="maintenanceType" label="维护类型" labelCol="1" fieldCol="2" dictionary="maintainType"/> <x:selectC name="maintenanceType" label="维护类型" labelCol="1" fieldCol="2" dictionary="maintainType"/>
<x:selectC name="status" label="审批状态" labelCol="1" fieldCol="2" dictionary="bizBillStatus"/> <x:selectC name="status" label="审批状态" labelCol="1" fieldCol="2" dictionary="bizBillStatus"/>
......
...@@ -149,7 +149,7 @@ function loadGrid() { ...@@ -149,7 +149,7 @@ function loadGrid() {
}, },
{ display: "人员Id", name: "userCode", width: 260, minWidth: 60, type: "string", align: "left",hide: true { display: "人员Id", name: "userCode", width: 260, minWidth: 60, type: "string", align: "left",hide: true
}, },
{ display: "是否处理", name: "active", width: 160, minWidth: 60, type: "string", align: "left",disable: "true" { display: "是否处理", name: "active", width: 160, minWidth: 60, type: "string", align: "center",disable: "true"
,render:function(item){ ,render:function(item){
var result = "否"; var result = "否";
if (item.active === "1"){ if (item.active === "1"){
...@@ -158,6 +158,8 @@ function loadGrid() { ...@@ -158,6 +158,8 @@ function loadGrid() {
return result; return result;
} }
}, },
{ display: "分发时间", name: "updateDate", width: 140, minWidth: 60, type: "string", align: "left"},
{ display: "完成时间", name: "finishedDate", width: 140, minWidth: 60, type: "string", align: "left"}
], ],
dataAction: "server", dataAction: "server",
url: web_app.name + '/sapNonProdApplyNext/slicedDeptList.ajax', url: web_app.name + '/sapNonProdApplyNext/slicedDeptList.ajax',
......
...@@ -153,13 +153,13 @@ ...@@ -153,13 +153,13 @@
fieldCol="5" disabled="true"/--> fieldCol="5" disabled="true"/-->
<!--x:checkboxListC name="businessUsage" label="业务用途" list="businessUsageUnSeledList" labelCol="1" <!--x:checkboxListC name="businessUsage" label="业务用途" list="businessUsageUnSeledList" labelCol="1"
fieldCol="5"/--> fieldCol="5"/-->
<c:if test="${applyType==2&&active==1}"> <c:if test="${applyType==2}">
<div class="hg-form-row"> <div class="hg-form-row">
<x:checkboxListC name="businessUsage" label="业务用途" dictionary="serviceusage" labelCol="1" <x:checkboxListC name="businessUsage" label="业务用途" dictionary="serviceusage" labelCol="1"
fieldCol="11"/> fieldCol="11"/>
</div> </div>
</c:if> </c:if>
<c:if test="${applyType==1||active==2}"> <c:if test="${applyType==1}">
<div class="hg-form-row"> <div class="hg-form-row">
<x:checkboxListC name="businessUsage" label="业务用途" dictionary="serviceusage" labelCol="1" <x:checkboxListC name="businessUsage" label="业务用途" dictionary="serviceusage" labelCol="1"
fieldCol="11" disabled="true"/> fieldCol="11" disabled="true"/>
......
...@@ -3,6 +3,7 @@ package com.huigou.topsun.base.bsnMessage.appliction; ...@@ -3,6 +3,7 @@ package com.huigou.topsun.base.bsnMessage.appliction;
import com.huigou.topsun.base.bsnMessage.domain.BsnMessageExecute; import com.huigou.topsun.base.bsnMessage.domain.BsnMessageExecute;
import com.huigou.topsun.base.bsnMessage.domain.BsnMessageReject; import com.huigou.topsun.base.bsnMessage.domain.BsnMessageReject;
import com.huigou.topsun.base.bsnMessage.domain.BsnMessageSponsor; import com.huigou.topsun.base.bsnMessage.domain.BsnMessageSponsor;
import com.huigou.topsun.base.bsnMessage.domain.query.BsnMessageQueryRequest;
import com.huigou.uasp.bmp.bizconfig.model.ObjectKindEnum; import com.huigou.uasp.bmp.bizconfig.model.ObjectKindEnum;
import java.util.List; import java.util.List;
...@@ -71,6 +72,8 @@ public interface BsnMessageApplication { ...@@ -71,6 +72,8 @@ public interface BsnMessageApplication {
*/ */
Map<String,Object> queryExecuteBsnMessage(); Map<String,Object> queryExecuteBsnMessage();
Map<String, Object> queryExecuteBsnMessage(BsnMessageQueryRequest query);
/** /**
* 当前登录用户是否以任务发起人的身份发起过任务如果有 * 当前登录用户是否以任务发起人的身份发起过任务如果有
* 且分发到的各单位已完成处理,则返回该任务 * 且分发到的各单位已完成处理,则返回该任务
......
...@@ -4,12 +4,14 @@ import com.huigou.data.query.model.QueryDescriptor; ...@@ -4,12 +4,14 @@ import com.huigou.data.query.model.QueryDescriptor;
import com.huigou.data.query.model.QueryModel; import com.huigou.data.query.model.QueryModel;
import com.huigou.topsun.base.bsnMessage.appliction.BsnMessageApplication; import com.huigou.topsun.base.bsnMessage.appliction.BsnMessageApplication;
import com.huigou.topsun.base.bsnMessage.domain.*; import com.huigou.topsun.base.bsnMessage.domain.*;
import com.huigou.topsun.base.bsnMessage.domain.query.BsnMessageQueryRequest;
import com.huigou.topsun.base.bsnMessage.repository.BsnMessageExecuteRepository; import com.huigou.topsun.base.bsnMessage.repository.BsnMessageExecuteRepository;
import com.huigou.topsun.base.bsnMessage.repository.BsnMessageRejectRepository; import com.huigou.topsun.base.bsnMessage.repository.BsnMessageRejectRepository;
import com.huigou.topsun.base.bsnMessage.repository.BsnMessageSponsorRepository; import com.huigou.topsun.base.bsnMessage.repository.BsnMessageSponsorRepository;
import com.huigou.topsun.sap.nonProdApply.domain.SapNonProdApplyDept; import com.huigou.topsun.sap.nonProdApply.domain.SapNonProdApplyDept;
import com.huigou.uasp.bmp.bizconfig.model.ObjectKindEnum; import com.huigou.uasp.bmp.bizconfig.model.ObjectKindEnum;
import com.huigou.uasp.bmp.common.application.BaseApplication; import com.huigou.uasp.bmp.common.application.BaseApplication;
import com.huigou.util.StringUtil;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
import org.springframework.data.domain.Sort; import org.springframework.data.domain.Sort;
...@@ -140,6 +142,7 @@ public class BsnMessageApplicationImpl extends BaseApplication implements BsnMes ...@@ -140,6 +142,7 @@ public class BsnMessageApplicationImpl extends BaseApplication implements BsnMes
public void submitTask(String meId) { public void submitTask(String meId) {
BsnMessageExecute execute = this.getExecuteByMeId(meId); BsnMessageExecute execute = this.getExecuteByMeId(meId);
execute.setActive(ActiveStatus.FINISHED.getValue()); execute.setActive(ActiveStatus.FINISHED.getValue());
execute.setFinishedDate(new Date());
this.saveBsnMessageExecute(execute); this.saveBsnMessageExecute(execute);
} }
...@@ -178,6 +181,29 @@ public class BsnMessageApplicationImpl extends BaseApplication implements BsnMes ...@@ -178,6 +181,29 @@ public class BsnMessageApplicationImpl extends BaseApplication implements BsnMes
return this.sqlExecutorDao.executeSlicedQuery(queryModel); return this.sqlExecutorDao.executeSlicedQuery(queryModel);
} }
@Override
public Map<String, Object> queryExecuteBsnMessage(BsnMessageQueryRequest query) {
QueryDescriptor queryDescriptor = this.sqlExecutorDao.getQuery(QUERY_XML_FILE_PATH, "queryExecuteBsnMessage");
// QueryModel queryModel = new QueryModel();
QueryModel queryModel = this.sqlExecutorDao.getQueryModel(queryDescriptor, query);
queryModel.setSql(queryDescriptor.getSql());
if (StringUtil.isNotBlank(query.getTaskDescribe())) {
queryModel.addCriteria(" and t.task_describe like:taskDescribe");
queryModel.putLikeParam("taskDescribe", query.getTaskDescribe());
}
if (StringUtil.isNotBlank(query.getTitle())) {
queryModel.addCriteria(" and ad.maktx like:title");
queryModel.putLikeParam("title", query.getTitle());
}
queryModel.setSortFieldName("updateDate");
queryModel.setSortOrder("desc");
queryModel.putParam("taskExecute", this.getOperator().getUserId());
queryModel.putParam("addText", "[驳回]");
return this.sqlExecutorDao.executeSlicedQuery(queryModel);
}
@Override @Override
public List<BsnMessageSponsor> queryFinishBsnMessageSponsor() { public List<BsnMessageSponsor> queryFinishBsnMessageSponsor() {
QueryDescriptor queryDescriptor = this.sqlExecutorDao.getQuery(QUERY_XML_FILE_PATH, "queryFinishBsnMessageSponsor"); QueryDescriptor queryDescriptor = this.sqlExecutorDao.getQuery(QUERY_XML_FILE_PATH, "queryFinishBsnMessageSponsor");
......
package com.huigou.topsun.base.bsnMessage.controller;
import com.huigou.context.Operator;
import com.huigou.context.OrgUnit;
import com.huigou.topsun.base.bsnMessage.appliction.BsnMessageApplication;
import com.huigou.topsun.base.bsnMessage.domain.query.BsnMessageQueryRequest;
import com.huigou.topsun.sap.costCenter.application.CostCenterApplication;
import com.huigou.topsun.sap.costCenter.domain.CostCenter;
import com.huigou.topsun.sap.costCenter.domain.query.CostCenterQueryRequest;
import com.huigou.topsun.sap.costCenter.domain.vo.CostCenterVo;
import com.huigou.uasp.annotation.ControllerMapping;
import com.huigou.uasp.client.CommonController;
import com.huigou.util.DateUtil;
import com.huigou.util.SDO;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.data.domain.PageRequest;
import org.springframework.stereotype.Controller;
/**
* @Auther: lxh
* @Date: 2024/04/13/11:36
* @Description:
*/
@Controller
@ControllerMapping("/bsnMessage")
public class BsnMessageController extends CommonController {
@Autowired
private BsnMessageApplication bsnMessageApplication;
@Override
protected String getPagePath() {
return "/biz/topsun/sap/base/";
}
/**
* 跳转到任务中心查询列表
*
* @return
*/
public String forwardBsnMessage() {
return forward("bsnMessageList");
}
public String slicedBsnMessageList() {
SDO sdo = this.getSDO();
BsnMessageQueryRequest queryRequest= sdo.toQueryRequest(BsnMessageQueryRequest.class);
return toResult(bsnMessageApplication.queryExecuteBsnMessage(queryRequest));
}
}
package com.huigou.topsun.base.bsnMessage.domain.query;
import com.huigou.data.domain.query.QueryAbstractRequest;
import lombok.Data;
@Data
public class BsnMessageQueryRequest extends QueryAbstractRequest {
private String taskDescribe;
private String title;
}
...@@ -81,6 +81,7 @@ public class NonProdApplyApplicationImpl extends FlowBroker implements NonProdA ...@@ -81,6 +81,7 @@ public class NonProdApplyApplicationImpl extends FlowBroker implements NonProdA
boolean isNew=nonProdApplyBaseInfo.isNew(); boolean isNew=nonProdApplyBaseInfo.isNew();
if (nonProdApplyBaseInfo.isNew()) { if (nonProdApplyBaseInfo.isNew()) {
nonProdApplyBaseInfo.setStatusId(BizBillStatus.APPLYING.getId()); nonProdApplyBaseInfo.setStatusId(BizBillStatus.APPLYING.getId());
nonProdApplyBaseInfo.setDistribute(0);
if (StringUtil.isNotBlank(nonProdApplyBaseInfo.getSourceId())){ //有数据来源ID的 表示是变更或扩展的 if (StringUtil.isNotBlank(nonProdApplyBaseInfo.getSourceId())){ //有数据来源ID的 表示是变更或扩展的
sapNonProdApplyDept=nonProdApplyDeptApplication.getNonProdApplyDeptByBaseInfoId(nonProdApplyBaseInfo.getSourceId()); sapNonProdApplyDept=nonProdApplyDeptApplication.getNonProdApplyDeptByBaseInfoId(nonProdApplyBaseInfo.getSourceId());
} }
...@@ -98,6 +99,7 @@ public class NonProdApplyApplicationImpl extends FlowBroker implements NonProdA ...@@ -98,6 +99,7 @@ public class NonProdApplyApplicationImpl extends FlowBroker implements NonProdA
ClassHelper.copyProperties(sapNonProdApplyDept, newSapNonProdApplyDept); ClassHelper.copyProperties(sapNonProdApplyDept, newSapNonProdApplyDept);
} else { //扩展的 设置默认基本字段 } else { //扩展的 设置默认基本字段
newSapNonProdApplyDept.setMatnr(sapNonProdApplyDept.getMatnr()); newSapNonProdApplyDept.setMatnr(sapNonProdApplyDept.getMatnr());
newSapNonProdApplyDept.setMatkl(sapNonProdApplyDept.getMatkl());
newSapNonProdApplyDept.setMtart(sapNonProdApplyDept.getMtart()); newSapNonProdApplyDept.setMtart(sapNonProdApplyDept.getMtart());
newSapNonProdApplyDept.setLvorm(sapNonProdApplyDept.getLvorm()); newSapNonProdApplyDept.setLvorm(sapNonProdApplyDept.getLvorm());
newSapNonProdApplyDept.setSpart(sapNonProdApplyDept.getSpart()); newSapNonProdApplyDept.setSpart(sapNonProdApplyDept.getSpart());
...@@ -119,6 +121,28 @@ public class NonProdApplyApplicationImpl extends FlowBroker implements NonProdA ...@@ -119,6 +121,28 @@ public class NonProdApplyApplicationImpl extends FlowBroker implements NonProdA
newSapNonProdApplyDept.setIprkz(sapNonProdApplyDept.getIprkz()); newSapNonProdApplyDept.setIprkz(sapNonProdApplyDept.getIprkz());
newSapNonProdApplyDept.setMhdrz(sapNonProdApplyDept.getMhdrz()); newSapNonProdApplyDept.setMhdrz(sapNonProdApplyDept.getMhdrz());
newSapNonProdApplyDept.setMhdhb(sapNonProdApplyDept.getMhdhb()); newSapNonProdApplyDept.setMhdhb(sapNonProdApplyDept.getMhdhb());
newSapNonProdApplyDept.setWerks(sapNonProdApplyDept.getWerks());
newSapNonProdApplyDept.setLgort(sapNonProdApplyDept.getLgort());
newSapNonProdApplyDept.setVkorg(sapNonProdApplyDept.getVkorg());
newSapNonProdApplyDept.setVtweg(sapNonProdApplyDept.getVtweg());
newSapNonProdApplyDept.setLgnum(sapNonProdApplyDept.getLgnum());
newSapNonProdApplyDept.setLgtyp(sapNonProdApplyDept.getLgtyp());
newSapNonProdApplyDept.setMatklName(sapNonProdApplyDept.getMatklName());
newSapNonProdApplyDept.setSpartName(sapNonProdApplyDept.getSpartName());
newSapNonProdApplyDept.setWerksName(sapNonProdApplyDept.getWerksName());
newSapNonProdApplyDept.setLgortName(sapNonProdApplyDept.getLgortName());
newSapNonProdApplyDept.setVkorgName(sapNonProdApplyDept.getVkorgName());
newSapNonProdApplyDept.setVtwegName(sapNonProdApplyDept.getVtwegName());
newSapNonProdApplyDept.setLgnumName(sapNonProdApplyDept.getLgnumName());
newSapNonProdApplyDept.setLgtypName(sapNonProdApplyDept.getLgtypName());
newSapNonProdApplyDept.setEkgrpName(sapNonProdApplyDept.getEkgrpName());
newSapNonProdApplyDept.setRaubeName(sapNonProdApplyDept.getRaubeName());
newSapNonProdApplyDept.setDispoName(sapNonProdApplyDept.getDispoName());
newSapNonProdApplyDept.setMinbeName(sapNonProdApplyDept.getMinbeName());
newSapNonProdApplyDept.setLadgrName(sapNonProdApplyDept.getLadgrName());
//销售组织 //销售组织
// newSapNonProdApplyDept.setVkorg(sapNonProdApplyDept.getVkorg()); // newSapNonProdApplyDept.setVkorg(sapNonProdApplyDept.getVkorg());
// newSapNonProdApplyDept.setVkorgName(sapNonProdApplyDept.getVkorgName()); // newSapNonProdApplyDept.setVkorgName(sapNonProdApplyDept.getVkorgName());
...@@ -320,6 +344,10 @@ public class NonProdApplyApplicationImpl extends FlowBroker implements NonProdA ...@@ -320,6 +344,10 @@ public class NonProdApplyApplicationImpl extends FlowBroker implements NonProdA
model.addCriteria(" and ad.maktx like:maktx"); model.addCriteria(" and ad.maktx like:maktx");
model.putLikeParam("maktx", query.getMaktx()); model.putLikeParam("maktx", query.getMaktx());
} }
if (query.getBillCode() != null) {
model.addCriteria(" and t.bill_code like:billCode");
model.putLikeParam("billCode", query.getBillCode());
}
model.putDictionary("maintenanceType", DictUtil.getDictionary("maintainType")); model.putDictionary("maintenanceType", DictUtil.getDictionary("maintainType"));
model.putDictionary("baseUnit", DictUtil.getDictionary("measuringUnit")); model.putDictionary("baseUnit", DictUtil.getDictionary("measuringUnit"));
......
...@@ -306,6 +306,7 @@ public class NonProdApplyDeptApplicationImpl extends BaseApplication implements ...@@ -306,6 +306,7 @@ public class NonProdApplyDeptApplicationImpl extends BaseApplication implements
backMap.put("businessId", baseInfo.getId()); backMap.put("businessId", baseInfo.getId());
backMap.put("parameter", JSON.toJSONString(map)); backMap.put("parameter", JSON.toJSONString(map));
backMap.put("sequence", backMap.get("row")); backMap.put("sequence", backMap.get("row"));
backMap.put("type", "E");
try { try {
String result = defaultHttpClient.execute(mapList, url); String result = defaultHttpClient.execute(mapList, url);
List<Map<String, Object>> resultList = objectMapper.readValue(result, new TypeReference<List<Map<String, Object>>>() { List<Map<String, Object>> resultList = objectMapper.readValue(result, new TypeReference<List<Map<String, Object>>>() {
...@@ -318,7 +319,7 @@ public class NonProdApplyDeptApplicationImpl extends BaseApplication implements ...@@ -318,7 +319,7 @@ public class NonProdApplyDeptApplicationImpl extends BaseApplication implements
if ("S".equals(backMap.get("TYPE"))) { if ("S".equals(backMap.get("TYPE"))) {
backMap.put("type", "S"); backMap.put("type", "S");
backMap.put("message", applyDept.getMatnr()+":"+backMap.get("MESSAGE")); backMap.put("MESSAGE", applyDept.getMatnr()+":"+backMap.get("MESSAGE"));
if (!"product".equals(baseInfo.getKind())) { if (!"product".equals(baseInfo.getKind())) {
applyDept.setMatnr((String) backMap.get("MESSAGE_V1")); applyDept.setMatnr((String) backMap.get("MESSAGE_V1"));
} }
...@@ -333,8 +334,7 @@ public class NonProdApplyDeptApplicationImpl extends BaseApplication implements ...@@ -333,8 +334,7 @@ public class NonProdApplyDeptApplicationImpl extends BaseApplication implements
//throw new RuntimeException(backStr); //throw new RuntimeException(backStr);
} }
} catch (Exception e) { } catch (Exception e) {
backMap.put("type", "E"); backMap.put("MESSAGE",applyDept.getMatnr()+":"+e.getMessage());
backMap.put("message",applyDept.getMatnr()+":"+e.getMessage());
//sapMutualEpLogApplication.saveSapMutualEpLog(resultMap); //sapMutualEpLogApplication.saveSapMutualEpLog(resultMap);
backStr="传输失败:" + e.getMessage(); backStr="传输失败:" + e.getMessage();
throw new RuntimeException(backStr); throw new RuntimeException(backStr);
...@@ -342,7 +342,7 @@ public class NonProdApplyDeptApplicationImpl extends BaseApplication implements ...@@ -342,7 +342,7 @@ public class NonProdApplyDeptApplicationImpl extends BaseApplication implements
sapMutualEpLogApplication.saveSapMutualEpLog(backMap); sapMutualEpLogApplication.saveSapMutualEpLog(backMap);
// String createdById = "5EEB2DC861694A65933CB4CE9A8D870A@C18E23AAAA6940E09DF7C122332C51E0"; // String createdById = "5EEB2DC861694A65933CB4CE9A8D870A@C18E23AAAA6940E09DF7C122332C51E0";
Operator operator = operatorApplication.createOperatorByPersonMemberId(baseInfo.getPersonMemberId()); Operator operator = operatorApplication.createOperatorByPersonMemberId(baseInfo.getPersonMemberId());
saveBsnMessageData(baseInfo,applyDept,operator,backMap.get("message").toString()); saveBsnMessageData(baseInfo,applyDept,operator,backMap.get("MESSAGE").toString());
return backStr; return backStr;
} }
......
...@@ -177,6 +177,8 @@ public class NonProdApplyNextController extends CommonController { ...@@ -177,6 +177,8 @@ public class NonProdApplyNextController extends CommonController {
Org org = orgApplication.loadMainOrgByPersonId(executor.getTaskExecute()); Org org = orgApplication.loadMainOrgByPersonId(executor.getTaskExecute());
resultMap.put("userName", org.getName()); resultMap.put("userName", org.getName());
resultMap.put("active",executor.getActive().toString()); resultMap.put("active",executor.getActive().toString());
resultMap.put("updateDate", executor.getUpdateDate().toString().substring(0,19));
resultMap.put("finishedDate",executor.getFinishedDate()!=null?executor.getFinishedDate().toString().substring(0,19):"");
break; break;
} }
} }
......
...@@ -2,6 +2,7 @@ package com.huigou.topsun.sap.nonProdApply.domain; ...@@ -2,6 +2,7 @@ package com.huigou.topsun.sap.nonProdApply.domain;
import com.huigou.data.domain.model.FlowBillAbstractEntity; import com.huigou.data.domain.model.FlowBillAbstractEntity;
import lombok.Data; import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;
import javax.persistence.*; import javax.persistence.*;
import java.util.Date; import java.util.Date;
...@@ -140,4 +141,6 @@ public class NonProdApplyBaseInfo extends FlowBillAbstractEntity { ...@@ -140,4 +141,6 @@ public class NonProdApplyBaseInfo extends FlowBillAbstractEntity {
*/ */
@Transient @Transient
private String businessUsageSeled; private String businessUsageSeled;
} }
\ No newline at end of file
...@@ -96,5 +96,7 @@ public class NonProdApplyBaseInfoQueryRequest extends FlowBillSuperQueryRequest ...@@ -96,5 +96,7 @@ public class NonProdApplyBaseInfoQueryRequest extends FlowBillSuperQueryRequest
//汉语品名 //汉语品名
private String maktx; private String maktx;
private String billCode;
} }
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment