Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
T
topsun-bpm
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
鲁鑫
topsun-bpm
Commits
b0a55ce2
Commit
b0a55ce2
authored
Apr 28, 2025
by
1650842865
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
客供料更新优化;采购信息记录修改功能;物料主数据禁用启用增加原因字段
parent
b370f4e6
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
24 changed files
with
1006 additions
and
50 deletions
+1006
-50
nonProdApplyNext.js
...in/webapp/biz/topsun/sap/nonProdApply/nonProdApplyNext.js
+29
-0
nonProdApplyNext.jsp
...n/webapp/biz/topsun/sap/nonProdApply/nonProdApplyNext.jsp
+2
-0
addPurchaseInfoRecordDetail.jsp
...un/sap/purchaseInfoRecord/addPurchaseInfoRecordDetail.jsp
+1
-0
purchaseInfoRecord.js
...p/biz/topsun/sap/purchaseInfoRecord/purchaseInfoRecord.js
+1
-0
purchaseInfoRecord.jsp
.../biz/topsun/sap/purchaseInfoRecord/purchaseInfoRecord.jsp
+2
-1
purchaseInfoRecordList.js
...z/topsun/sap/purchaseInfoRecord/purchaseInfoRecordList.js
+28
-0
updatePurchaseInfoRecord.js
...topsun/sap/purchaseInfoRecord/updatePurchaseInfoRecord.js
+436
-0
updatePurchaseInfoRecord.jsp
...opsun/sap/purchaseInfoRecord/updatePurchaseInfoRecord.jsp
+41
-0
updatePurchaseInfoRecordDetail.js
.../sap/purchaseInfoRecord/updatePurchaseInfoRecordDetail.js
+134
-0
updatePurchaseInfoRecordDetail.jsp
...sap/purchaseInfoRecord/updatePurchaseInfoRecordDetail.jsp
+110
-0
ClientMaterialsApplicationImpl.java
...ials/application/impl/ClientMaterialsApplicationImpl.java
+6
-3
ClientMaterialsRepository.java
...clientMaterials/repository/ClientMaterialsRepository.java
+3
-0
SapNonProdApplyDept.java
...u/topsun/sap/nonProdApply/domain/SapNonProdApplyDept.java
+12
-0
NonProdApplyBasicVo.java
...opsun/sap/nonProdApply/domain/vo/NonProdApplyBasicVo.java
+4
-0
NonProdApplyDeptBaseInfoVo.java
...ap/nonProdApply/domain/vo/NonProdApplyDeptBaseInfoVo.java
+4
-0
SapPurchaseInfoRecordItemApplication.java
...ord/application/SapPurchaseInfoRecordItemApplication.java
+2
-0
SapPurchaseInfoRecordApplicationImpl.java
...pplication/impl/SapPurchaseInfoRecordApplicationImpl.java
+27
-43
SapPurchaseInfoRecordItemApplicationImpl.java
...cation/impl/SapPurchaseInfoRecordItemApplicationImpl.java
+10
-0
SapPurchaseInfoRecordController.java
...nfoRecord/controller/SapPurchaseInfoRecordController.java
+46
-3
SapPurchaseInfoRecordItemController.java
...ecord/controller/SapPurchaseInfoRecordItemController.java
+13
-0
SapPurchaseInfoRecord.java
.../sap/purchaseInfoRecord/domain/SapPurchaseInfoRecord.java
+3
-0
SapPurchaseInfoRecordItem.java
.../purchaseInfoRecord/domain/SapPurchaseInfoRecordItem.java
+6
-0
SapPurchaseInfoRecordItemVo.java
...haseInfoRecord/domain/vo/SapPurchaseInfoRecordItemVo.java
+7
-0
sapPurchaseInfoRecordItem.xml
...n/sap/sapPurchaseInfoRecord/sapPurchaseInfoRecordItem.xml
+79
-0
No files found.
topsun-xt/src/main/webapp/biz/topsun/sap/nonProdApply/nonProdApplyNext.js
View file @
b0a55ce2
...
@@ -157,6 +157,11 @@ function initializate() {
...
@@ -157,6 +157,11 @@ function initializate() {
$
(
'input[name="isAll"]'
).
attr
(
"checked"
,
false
);
$
(
'input[name="isAll"]'
).
attr
(
"checked"
,
false
);
}
}
});
});
if
(
applyType
==
1
){
//变更
var
lvorm
=
$
(
"#lvorm"
).
val
();
bindEvent_lvorm
(
lvorm
)
}
}
}
function
initKlart
(
mtart
)
{
function
initKlart
(
mtart
)
{
...
@@ -1470,6 +1475,30 @@ function bindEvent() {
...
@@ -1470,6 +1475,30 @@ function bindEvent() {
}
}
})
})
})
})
//集团级删除、启用填写原因
$
(
"#lvorm"
).
combox
({
onChange
:
function
(
data
){
bindEvent_lvorm
(
data
.
value
)
}
});
}
function
bindEvent_lvorm
(
data
){
if
(
data
==
'X'
){
UICtrl
.
setElRequiredFlag
(
"#disableReason"
,
true
);
UICtrl
.
setElRequiredFlag
(
"#enableReason"
,
false
);
$
(
"#enableReason"
).
val
(
""
);
}
else
if
(
data
==
'0'
){
UICtrl
.
setElRequiredFlag
(
"#disableReason"
,
false
);
UICtrl
.
setElRequiredFlag
(
"#enableReason"
,
true
);
$
(
"#disableReason"
).
val
(
""
);
}
else
{
UICtrl
.
setElRequiredFlag
(
"#disableReason"
,
false
);
UICtrl
.
setElRequiredFlag
(
"#enableReason"
,
false
);
$
(
"#disableReason"
).
val
(
""
);
$
(
"#enableReason"
).
val
(
""
);
}
}
}
function
bindEvent_sale
()
{
function
bindEvent_sale
()
{
...
...
topsun-xt/src/main/webapp/biz/topsun/sap/nonProdApply/nonProdApplyNext.jsp
View file @
b0a55ce2
...
@@ -157,6 +157,8 @@
...
@@ -157,6 +157,8 @@
<x:inputC
name=
"classify"
label=
"分类"
labelCol=
"1"
fieldCol=
"2"
readonly=
"true"
/>
<x:inputC
name=
"classify"
label=
"分类"
labelCol=
"1"
fieldCol=
"2"
readonly=
"true"
/>
<c:if
test=
"
${
applyType
==
1
}
"
>
<c:if
test=
"
${
applyType
==
1
}
"
>
<x:selectC
name=
"lvorm"
label=
"集团级删除"
required=
"false"
labelCol=
"1"
fieldCol=
"2"
dictionary=
"lvorm"
/>
<x:selectC
name=
"lvorm"
label=
"集团级删除"
required=
"false"
labelCol=
"1"
fieldCol=
"2"
dictionary=
"lvorm"
/>
<x:inputC
name=
"disableReason"
label=
"禁用原因"
required=
"false"
labelCol=
"1"
fieldCol=
"2"
/>
<x:inputC
name=
"enableReason"
label=
"启用原因"
required=
"false"
labelCol=
"1"
fieldCol=
"2"
/>
</c:if>
</c:if>
</div>
</div>
</div>
</div>
...
...
topsun-xt/src/main/webapp/biz/topsun/sap/purchaseInfoRecord/addPurchaseInfoRecordDetail.jsp
View file @
b0a55ce2
...
@@ -14,6 +14,7 @@
...
@@ -14,6 +14,7 @@
<x:hidden
name=
"id"
/>
<x:hidden
name=
"id"
/>
<x:hidden
name=
"rowId"
/>
<x:hidden
name=
"rowId"
/>
<x:hidden
name=
"isReadOnly"
/>
<x:hidden
name=
"isReadOnly"
/>
<x:hidden
name=
"knumh"
/>
<x:inputC
name=
"infnr"
label=
"信息记录编号"
labelCol=
"1"
fieldCol=
"2"
required=
"false"
readonly=
"true"
/>
<x:inputC
name=
"infnr"
label=
"信息记录编号"
labelCol=
"1"
fieldCol=
"2"
required=
"false"
readonly=
"true"
/>
<x:hidden
name=
"werks"
/>
<x:hidden
name=
"werks"
/>
<x:inputC
name=
"werksName"
required=
"true"
label=
"工厂"
labelCol=
"1"
wrapper=
"select"
fieldCol=
"2"
/>
<x:inputC
name=
"werksName"
required=
"true"
label=
"工厂"
labelCol=
"1"
wrapper=
"select"
fieldCol=
"2"
/>
...
...
topsun-xt/src/main/webapp/biz/topsun/sap/purchaseInfoRecord/purchaseInfoRecord
Detail
.js
→
topsun-xt/src/main/webapp/biz/topsun/sap/purchaseInfoRecord/purchaseInfoRecord.js
View file @
b0a55ce2
...
@@ -682,6 +682,7 @@ function doSaveDefine() {
...
@@ -682,6 +682,7 @@ function doSaveDefine() {
kstbm5
:
$
(
"#kstbm5"
).
val
(),
kstbm5
:
$
(
"#kstbm5"
).
val
(),
kbetr5
:
$
(
"#kbetr5"
).
val
(),
kbetr5
:
$
(
"#kbetr5"
).
val
(),
remark
:
$
(
"#remark"
).
val
(),
remark
:
$
(
"#remark"
).
val
(),
knumh
:
$
(
"#knumh"
).
val
(),
});
});
this
.
close
();
this
.
close
();
...
...
topsun-xt/src/main/webapp/biz/topsun/sap/purchaseInfoRecord/purchaseInfoRecord
Detail
.jsp
→
topsun-xt/src/main/webapp/biz/topsun/sap/purchaseInfoRecord/purchaseInfoRecord.jsp
View file @
b0a55ce2
...
@@ -5,7 +5,7 @@
...
@@ -5,7 +5,7 @@
<html>
<html>
<head>
<head>
<x:base
include=
"layout,dialog,grid,tree,date,dateTime,combox,attachment,commonTree,comboDialog"
/>
<x:base
include=
"layout,dialog,grid,tree,date,dateTime,combox,attachment,commonTree,comboDialog"
/>
<x:script
src=
"/biz/topsun/sap/purchaseInfoRecord/purchaseInfoRecord
Detail
.js"
/>
<x:script
src=
"/biz/topsun/sap/purchaseInfoRecord/purchaseInfoRecord.js"
/>
</head>
</head>
<body>
<body>
<div
class=
"container-fluid"
>
<div
class=
"container-fluid"
>
...
@@ -27,6 +27,7 @@
...
@@ -27,6 +27,7 @@
<x:hidden
name=
"statusId"
/>
<x:hidden
name=
"statusId"
/>
<x:hidden
name=
"ids"
/>
<x:hidden
name=
"ids"
/>
<x:hidden
name=
"isReadOnly"
/>
<x:hidden
name=
"isReadOnly"
/>
<x:hidden
name=
"flag"
/>
<div
class=
"hg-form-cols"
>
<div
class=
"hg-form-cols"
>
<div
class=
"hg-form-row"
>
<div
class=
"hg-form-row"
>
</div>
</div>
...
...
topsun-xt/src/main/webapp/biz/topsun/sap/purchaseInfoRecord/purchaseInfoRecordList.js
View file @
b0a55ce2
...
@@ -42,6 +42,11 @@ function initPurchaseListGrid() {
...
@@ -42,6 +42,11 @@ function initPurchaseListGrid() {
copyQualityInfoRecord
();
copyQualityInfoRecord
();
}
}
},
},
updateHandler
:{
id
:
'updateHandler'
,
text
:
"修改"
,
img
:
'fa-edit'
,
click
:
function
(){
updateHandlerInfoRecord
();
}
}
// cancelHandler:{
// cancelHandler:{
// id: 'cancelHandler', text: "作废", img:'fa-trash-o', click: function(){
// id: 'cancelHandler', text: "作废", img:'fa-trash-o', click: function(){
// cancelHandlerInfoRecord();
// cancelHandlerInfoRecord();
...
@@ -238,6 +243,29 @@ function copyQualityInfoRecord(){
...
@@ -238,6 +243,29 @@ function copyQualityInfoRecord(){
});
});
}
}
function
updateHandlerInfoRecord
(){
var
rows
=
purchaseInfoRecordGridManager
.
getSelectedRows
();
if
(
rows
.
length
==
0
)
{
Public
.
tip
(
'请选择数据!'
);
return
;
}
var
ids
=
[];
for
(
var
i
=
0
;
i
<
rows
.
length
;
i
++
){
var
row
=
rows
[
i
];
if
(
Public
.
isBlank
(
row
.
infnr
))
{
Public
.
errorTip
(
'只能修改有采购信息记录号的数据!'
);
return
false
;
}
ids
.
push
(
row
.
id
)
}
UICtrl
.
addTabItem
({
tabid
:
'updatePurchaseInfoRecord'
+
row
.
id
,
text
:
'修改采购信息记录'
,
url
:
web_app
.
name
+
'/sapPurchaseInfoRecord/showUpdateSapPurchaseInfoRecordDetail.job?ids='
+
ids
.
join
(
","
)
})
}
function
cancelHandlerInfoRecord
(){
function
cancelHandlerInfoRecord
(){
var
row
=
purchaseInfoRecordGridManager
.
getSelectedRow
();
var
row
=
purchaseInfoRecordGridManager
.
getSelectedRow
();
if
(
!
row
)
{
if
(
!
row
)
{
...
...
topsun-xt/src/main/webapp/biz/topsun/sap/purchaseInfoRecord/updatePurchaseInfoRecord.js
0 → 100644
View file @
b0a55ce2
This diff is collapsed.
Click to expand it.
topsun-xt/src/main/webapp/biz/topsun/sap/purchaseInfoRecord/updatePurchaseInfoRecord.jsp
0 → 100644
View file @
b0a55ce2
<%--采购申请--%>
<%@ 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,date,dateTime,combox,attachment,commonTree,comboDialog"
/>
<x:script
src=
"/biz/topsun/sap/purchaseInfoRecord/updatePurchaseInfoRecord.js"
/>
</head>
<body>
<div
class=
"container-fluid"
>
<x:billTitle
title=
"修改采购信息记录"
needStatus=
"true"
needPerson=
"true"
/>
<form
class=
"hg-form"
method=
"post"
action=
""
id=
"submitForm"
>
<x:hidden
name=
"id"
/>
<x:hidden
name=
"version"
/>
<x:hidden
name=
"billCode"
/>
<x:hidden
name=
"fillinDate"
/>
<x:hidden
name=
"fullId"
/>
<x:hidden
name=
"organId"
/>
<x:hidden
name=
"organName"
/>
<x:hidden
name=
"deptId"
/>
<x:hidden
name=
"deptName"
/>
<x:hidden
name=
"positionId"
/>
<x:hidden
name=
"positionName"
/>
<x:hidden
name=
"personMemberId"
/>
<x:hidden
name=
"personMemberName"
/>
<x:hidden
name=
"statusId"
/>
<x:hidden
name=
"ids"
/>
<x:hidden
name=
"isReadOnly"
/>
<x:hidden
name=
"flag"
/>
<div
class=
"hg-form-cols"
>
<div
class=
"hg-form-row"
>
</div>
</div>
<div
id=
"maingrid"
></div>
<div
style=
"padding-top: 15px;"
>
<x:fileList
bizCode=
"purchaseInfoRecord"
bizId=
"id"
id=
"fileList"
title=
"相关资料"
/>
</div>
</form>
</div>
</body>
\ No newline at end of file
topsun-xt/src/main/webapp/biz/topsun/sap/purchaseInfoRecord/updatePurchaseInfoRecordDetail.js
0 → 100644
View file @
b0a55ce2
var
gridManager
=
null
;
var
canEdit
=
true
;
$
(
document
).
ready
(
function
()
{
initialize
();
bindDetailEvent
();
});
function
initialize
(){
UICtrl
.
layout
(
"#layout"
,
{
leftWidth
:
3
});
if
(
$
(
"#isReadOnly"
).
val
()
==
"true"
)
{
disableForm
(
"infoRecord"
,
"disable"
);
}
else
{
var
readwriteList
=
UICtrl
.
getUIElementPermissions
(
UIPO
.
READWRITE
,
UIPK
.
DETAIL
);
// alert("dsd=="+readwriteList.length); alert(TaskKind.isReplenishTask(taskKindId)); //打回的
if
((
$
(
"#statusId"
).
val
()
==
1
&&
readwriteList
.
length
>
0
&&
TaskKind
.
isReplenishTask
(
taskKindId
)
!=
true
))
{
disableForm
(
"infoRecord"
,
"disable"
);
$
.
each
(
readwriteList
,
function
(
i
,
o
)
{
$
(
"#"
+
o
).
removeAttr
(
'disabled'
);
});
}
}
}
function
disableForm
(
formId
,
isDisabled
)
{
var
attr
=
"disable"
;
if
(
!
isDisabled
){
attr
=
"enable"
;
}
$
(
"form[id='"
+
formId
+
"'] :text"
).
attr
(
"disabled"
,
isDisabled
);
$
(
"form[id='"
+
formId
+
"'] textarea"
).
attr
(
"disabled"
,
isDisabled
);
$
(
"form[id='"
+
formId
+
"'] select"
).
attr
(
"disabled"
,
isDisabled
);
$
(
"form[id='"
+
formId
+
"'] :radio"
).
attr
(
"disabled"
,
isDisabled
);
$
(
"form[id='"
+
formId
+
"'] :checkbox"
).
attr
(
"disabled"
,
isDisabled
);
//禁用jquery easyui中的下拉选(使用input生成的combox)
$
(
"#"
+
formId
+
" input[class='combobox-f combo-f']"
).
each
(
function
()
{
if
(
this
.
id
)
{
alert
(
"input"
+
this
.
id
);
$
(
"#"
+
this
.
id
).
combobox
(
attr
);
}
});
//禁用jquery easyui中的下拉选(使用select生成的combox)
$
(
"#"
+
formId
+
" select[class='combobox-f combo-f']"
).
each
(
function
()
{
if
(
this
.
id
)
{
alert
(
this
.
id
);
$
(
"#"
+
this
.
id
).
combobox
(
attr
);
}
});
//禁用jquery easyui中的日期组件dataBox
$
(
"#"
+
formId
+
" input[class='datebox-f combo-f']"
).
each
(
function
()
{
if
(
this
.
id
)
{
alert
(
this
.
id
)
$
(
"#"
+
this
.
id
).
datebox
(
attr
);
}
});
}
function
bindDetailEvent
(){
$
(
'#waersName'
).
searchbox
({
type
:
"system"
,
name
:
"selectSupplierWaers"
,
getParam
:
function
(
item
)
{
return
{
partner
:
$
(
'#lifnr'
).
val
(),
// werks: $('#werks').val()
}
},
onChange
:
function
(
value
,
data
)
{
$
(
'#waers'
).
val
(
data
.
waers
);
$
(
'#waersName'
).
val
(
data
.
waersName
);
$
(
'#ltsnr'
).
val
(
data
.
ltsnr
);
$
(
'#ltsbz'
).
val
(
data
.
ltsbz
);
//$('#name1').val(data.nameOrg1);
}
});
$
(
'#bprmeName'
).
searchbox
({
type
:
"system"
,
name
:
"dictionary"
,
getParam
:
function
(
item
)
{
return
{
fieldName
:
"MEINS"
}
},
onChange
:
function
(
value
,
data
)
{
$
(
'#bprme'
).
val
(
data
.
MSEH3
);
$
(
'#bprmeName'
).
val
(
data
.
MSEHL
);
}
});
$
(
'#urzlaName'
).
searchbox
({
type
:
"system"
,
name
:
"dictionarySelect"
,
getParam
:
function
(
item
)
{
return
{
fieldName
:
"country"
,
displayNames
:
"国家"
,
displayLens
:
"180"
}
},
onChange
:
function
(
value
,
data
)
{
$
(
'#urzla'
).
val
(
data
.
value
);
$
(
'#urzlaName'
).
val
(
data
.
name
);
}
});
$
(
'#regioName'
).
searchbox
({
type
:
"system"
,
name
:
"getArea"
,
getParam
:
function
(
item
)
{
if
(
Public
.
isBlank
(
$
(
'#urzla'
).
val
())){
Public
.
tip
(
"请先选择原产地国!"
)
return
false
;
}
return
{
LAND1
:
$
(
'#urzla'
).
val
()
}
},
onChange
:
function
(
value
,
data
)
{
$
(
'#regio'
).
val
(
data
.
BLAND
);
$
(
'#regioName'
).
val
(
data
.
BEZEI
);
}
});
$
(
'#kbetr'
).
on
(
'input'
,
function
()
{
let
inputValue
=
$
(
this
).
val
();
if
(
isNaN
(
Number
(
inputValue
)))
{
Public
.
errorTip
(
"等级金额1必须输入数字!"
);
}
else
{
if
(
Public
.
isNotBlank
(
inputValue
))
{
UICtrl
.
disable
(
$
(
'#netpr'
))
$
(
'#netpr'
).
val
(
inputValue
);
}
else
{
UICtrl
.
enable
(
$
(
'#netpr'
))
}
}
});
}
function
reloadGrid
()
{
}
\ No newline at end of file
topsun-xt/src/main/webapp/biz/topsun/sap/purchaseInfoRecord/updatePurchaseInfoRecordDetail.jsp
0 → 100644
View file @
b0a55ce2
<%@ page
language=
"java"
contentType=
"text/html; charset=utf-8"
%>
<%@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/purchaseInfoRecord/updatePurchaseInfoRecordDetail.js'
/>
</head>
<body>
<form
class=
"hg-form"
method=
"post"
action=
""
id=
"infoRecord"
>
<div
class=
"hg-form-cols"
>
<div
class=
"hg-form-row"
>
<x:hidden
name=
"id"
/>
<x:hidden
name=
"rowId"
/>
<x:hidden
name=
"isReadOnly"
/>
<x:hidden
name=
"knumh"
/>
<x:inputC
name=
"infnr"
label=
"信息记录编号"
labelCol=
"1"
fieldCol=
"2"
required=
"false"
readonly=
"true"
/>
<x:hidden
name=
"werks"
/>
<x:inputC
name=
"werksName"
required=
"true"
label=
"工厂"
labelCol=
"1"
readonly=
"true"
fieldCol=
"2"
/>
<x:hidden
name=
"ekorg"
/>
<x:inputC
name=
"ekorgName"
label=
"采购组织"
labelCol=
"1"
fieldCol=
"2"
readonly=
"true"
required=
"true"
/>
<x:inputC
name=
"lifnr"
label=
"供应商"
labelCol=
"1"
fieldCol=
"2"
required=
"true"
readonly=
"true"
/>
<x:inputC
name=
"name1"
label=
"供应商名称"
labelCol=
"1"
fieldCol=
"2"
required=
"false"
readonly=
"true"
/>
<x:inputC
name=
"idnlf"
label=
"供应商物料"
labelCol=
"1"
fieldCol=
"2"
readonly=
"true"
/>
<%--<x:inputC name="nameOrg3" label="组织名称3" labelCol="1" fieldCol="2"/>
<x:inputC name="nameOrg4" label="组织名称4" labelCol="1" fieldCol="2"/>--%>
<x:inputC
name=
"matnr"
label=
"物料编码"
labelCol=
"1"
fieldCol=
"2"
required=
"false"
readonly=
"true"
/>
<x:inputC
name=
"maktx"
label=
"物料描述"
labelCol=
"1"
fieldCol=
"2"
readonly=
"true"
/>
<x:selectC
name=
"esokz"
label=
"记录分类"
labelCol=
"1"
fieldCol=
"2"
required=
"true"
dictionary=
"esokz"
disabled=
"true"
/>
<x:hidden
name=
"ekgrp"
/>
<x:inputC
name=
"ekgrpName"
label=
"采购组"
labelCol=
"1"
fieldCol=
"2"
readonly=
"true"
required=
"true"
/>
<x:inputC
name=
"netpr"
label=
"净价"
labelCol=
"1"
fieldCol=
"2"
required=
"true"
mask=
"999999999.99"
/>
<x:inputC
name=
"freight"
label=
"运输费"
labelCol=
"1"
fieldCol=
"2"
required=
"false"
mask=
"99999999.99"
/>
<x:inputC
name=
"kbetr6"
label=
"包装费"
labelCol=
"1"
fieldCol=
"2"
required=
"false"
mask=
"99999999.99"
/>
<x:hidden
name=
"matkl"
/>
<x:inputC
name=
"matklName"
label=
"物料组"
labelCol=
"1"
fieldCol=
"2"
readonly=
"true"
/>
<x:inputC
name=
"waersName"
label=
"货币码"
labelCol=
"1"
fieldCol=
"2"
required=
"true"
wrapper=
"select"
/>
<x:hidden
name=
"waers"
/>
<x:hidden
name=
"ltsnr"
/>
<x:hidden
name=
"ltsbz"
/>
<x:inputC
name=
"peinh"
label=
"价格单位"
labelCol=
"1"
fieldCol=
"2"
required=
"true"
mask=
"99999999.99"
/>
<x:inputC
name=
"meinsName"
label=
"基本计量单位"
labelCol=
"1"
fieldCol=
"2"
required=
"false"
readonly=
"true"
/>
<x:hidden
name=
"bprme"
/>
<x:inputC
name=
"bprmeName"
label=
"订单价格单位(采购)"
labelCol=
"2"
fieldCol=
"2"
wrapper=
"select"
required=
"true"
/>
<x:selectC
name=
"mwskz"
label=
"销售/购买税代码"
labelCol=
"2"
fieldCol=
"3"
required=
"true"
dictionary=
"purchaseMwskz"
/>
</div>
<div
class=
"hg-form-row"
>
<x:hidden
name=
"meins"
/>
<x:inputC
name=
"norbm"
label=
"标准采购订单数量"
labelCol=
"2"
fieldCol=
"1"
required=
"false"
mask=
"99999999.99"
/>
<x:inputC
name=
"umren"
label=
"订单单位转换分母"
labelCol=
"1"
fieldCol=
"2"
required=
"true"
mask=
"99999999.99"
/>
<x:inputC
name=
"umrez"
label=
"订单单位转换分子"
labelCol=
"1"
fieldCol=
"2"
required=
"true"
mask=
"99999999.99"
/>
<x:inputC
name=
"datab"
required=
"true"
label=
"生效日期起"
wrapper=
"date"
labelCol=
"1"
fieldCol=
"2"
/>
<x:inputC
name=
"datbi"
required=
"true"
label=
"生效日期止"
wrapper=
"date"
labelCol=
"1"
fieldCol=
"2"
/>
<x:inputC
name=
"verkf"
label=
"销售员"
labelCol=
"1"
fieldCol=
"2"
required=
"false"
/>
<x:inputC
name=
"telf1"
label=
"电话"
labelCol=
"1"
fieldCol=
"2"
required=
"false"
/>
<x:inputC
name=
"urzlaName"
label=
"原产国"
labelCol=
"1"
fieldCol=
"2"
required=
"false"
wrapper=
"select"
/>
<x:hidden
name=
"urzla"
/>
<x:inputC
name=
"regioName"
label=
"地区"
labelCol=
"1"
fieldCol=
"2"
required=
"false"
wrapper=
"select"
/>
<x:hidden
name=
"regio"
/>
<x:selectC
name=
"loekz"
label=
"删除标志"
labelCol=
"1"
fieldCol=
"2"
required=
"false"
dictionary=
"loekz"
/>
<x:inputC
name=
"sortl"
label=
"排序字段"
labelCol=
"1"
fieldCol=
"2"
required=
"false"
readonly=
"true"
/>
<x:inputC
name=
"minbm"
label=
"最小采购订单数量"
labelCol=
"2"
fieldCol=
"1"
required=
"false"
mask=
"9999999.99"
/>
<x:inputC
name=
"aplfz"
label=
"计划交货时间(天)"
labelCol=
"2"
fieldCol=
"1"
required=
"true"
mask=
"9999999"
/>
<x:selectC
name=
"webre"
label=
"基于收货的发票验证"
labelCol=
"2"
fieldCol=
"1"
required=
"true"
dictionary=
"webre"
/>
<x:selectC
name=
"stfkz"
label=
"等级类型"
labelCol=
"1"
fieldCol=
"5"
required=
"true"
dictionary=
"stfkz"
disabled=
"true"
/>
</div>
<div
class=
"hg-form-row"
>
<x:inputC
name=
"kstbm"
label=
"等级数量1"
labelCol=
"1"
fieldCol=
"1"
required=
"false"
mask=
"9999999.99"
/>
<x:inputC
name=
"kstbm2"
label=
"等级数量2"
labelCol=
"1"
fieldCol=
"1"
required=
"false"
mask=
"9999999.99"
/>
<x:inputC
name=
"kstbm3"
label=
"等级数量3"
labelCol=
"1"
fieldCol=
"1"
required=
"false"
mask=
"9999999.99"
/>
<x:inputC
name=
"kstbm4"
label=
"等级数量4"
labelCol=
"1"
fieldCol=
"1"
required=
"false"
mask=
"9999999.99"
/>
<x:inputC
name=
"kstbm5"
label=
"等级数量5"
labelCol=
"1"
fieldCol=
"1"
required=
"false"
mask=
"9999999.99"
/>
</div>
<div
class=
"hg-form-row"
>
<x:inputC
name=
"kbetr"
label=
"等级金额1"
labelCol=
"1"
fieldCol=
"1"
required=
"false"
/>
<x:inputC
name=
"kbetr2"
label=
"等级金额2"
labelCol=
"1"
fieldCol=
"1"
required=
"false"
mask=
"9999999.99"
/>
<x:inputC
name=
"kbetr3"
label=
"等级金额3"
labelCol=
"1"
fieldCol=
"1"
required=
"false"
mask=
"9999999.99"
/>
<x:inputC
name=
"kbetr4"
label=
"等级金额4"
labelCol=
"1"
fieldCol=
"1"
required=
"false"
mask=
"9999999.99"
/>
<x:inputC
name=
"kbetr5"
label=
"等级金额5"
labelCol=
"1"
fieldCol=
"1"
required=
"false"
mask=
"9999999.99"
/>
</div>
<div
class=
"hg-form-row"
>
<x:textareaC
name=
"remark"
rows=
"3"
label=
"备注"
labelCol=
"1"
fieldCol=
"9"
/>
</div>
</div>
</form>
</body>
</html>
topsun/src/main/java/com/huigou/topsun/sap/clientMaterials/application/impl/ClientMaterialsApplicationImpl.java
View file @
b0a55ce2
...
@@ -114,9 +114,11 @@ public class ClientMaterialsApplicationImpl extends BaseApplication implements C
...
@@ -114,9 +114,11 @@ public class ClientMaterialsApplicationImpl extends BaseApplication implements C
public
void
saveClientMaterials
(
List
<
ClientMaterialsVo
>
sapClientMaterialsList
){
public
void
saveClientMaterials
(
List
<
ClientMaterialsVo
>
sapClientMaterialsList
){
//根据计划订单查询,如果没有就新增,有就修改
//根据计划订单查询,如果没有就新增,有就修改
for
(
ClientMaterialsVo
clientMaterialsVo
:
sapClientMaterialsList
)
{
for
(
ClientMaterialsVo
clientMaterialsVo
:
sapClientMaterialsList
)
{
ClientMaterials
clientMaterialsDb
=
clientMaterialsRepository
.
findByPlnum
(
clientMaterialsVo
.
getPlnum
());
//ClientMaterials clientMaterialsDb = clientMaterialsRepository.findByPlnum(clientMaterialsVo.getPlnum());
if
(
clientMaterialsDb
==
null
){
List
<
ClientMaterials
>
clientMaterialsDbs
=
clientMaterialsRepository
.
findByPlnumAndKdaufAndKdpos
(
clientMaterialsVo
.
getPlnum
(),
clientMaterialsVo
.
getKdauf
(),
clientMaterialsVo
.
getKdpos
());
clientMaterialsDb
=
new
ClientMaterials
();
if
(
CollectionUtils
.
isEmpty
(
clientMaterialsDbs
)){
ClientMaterials
clientMaterialsDb
=
new
ClientMaterials
();
BeanUtil
.
copyProperties
(
clientMaterialsVo
,
clientMaterialsDb
);
BeanUtil
.
copyProperties
(
clientMaterialsVo
,
clientMaterialsDb
);
//根据跟单员初始化创建人信息
//根据跟单员初始化创建人信息
String
partner
=
clientMaterialsVo
.
getPartner
();
String
partner
=
clientMaterialsVo
.
getPartner
();
...
@@ -140,6 +142,7 @@ public class ClientMaterialsApplicationImpl extends BaseApplication implements C
...
@@ -140,6 +142,7 @@ public class ClientMaterialsApplicationImpl extends BaseApplication implements C
//推送待办任务
//推送待办任务
this
.
pushTask
(
clientMaterialsDb
,
personMaps
);
this
.
pushTask
(
clientMaterialsDb
,
personMaps
);
}
else
{
}
else
{
ClientMaterials
clientMaterialsDb
=
clientMaterialsDbs
.
get
(
0
);
//不为空,更新数据
//不为空,更新数据
BeanUtil
.
copyProperties
(
clientMaterialsVo
,
clientMaterialsDb
);
BeanUtil
.
copyProperties
(
clientMaterialsVo
,
clientMaterialsDb
);
clientMaterialsRepository
.
save
(
clientMaterialsDb
);
clientMaterialsRepository
.
save
(
clientMaterialsDb
);
...
...
topsun/src/main/java/com/huigou/topsun/sap/clientMaterials/repository/ClientMaterialsRepository.java
View file @
b0a55ce2
...
@@ -4,6 +4,8 @@ import com.huigou.topsun.sap.clientMaterials.domain.ClientMaterials;
...
@@ -4,6 +4,8 @@ import com.huigou.topsun.sap.clientMaterials.domain.ClientMaterials;
import
com.huigou.topsun.sap.componentSupply.domain.ComponentSupply
;
import
com.huigou.topsun.sap.componentSupply.domain.ComponentSupply
;
import
org.springframework.data.jpa.repository.JpaRepository
;
import
org.springframework.data.jpa.repository.JpaRepository
;
import
java.util.List
;
/**
/**
* @Auther: LXH
* @Auther: LXH
* @Date: 2024/06/05/16:33
* @Date: 2024/06/05/16:33
...
@@ -12,4 +14,5 @@ import org.springframework.data.jpa.repository.JpaRepository;
...
@@ -12,4 +14,5 @@ import org.springframework.data.jpa.repository.JpaRepository;
public
interface
ClientMaterialsRepository
extends
JpaRepository
<
ClientMaterials
,
String
>
{
public
interface
ClientMaterialsRepository
extends
JpaRepository
<
ClientMaterials
,
String
>
{
ClientMaterials
findByPlnum
(
String
plnum
);
ClientMaterials
findByPlnum
(
String
plnum
);
List
<
ClientMaterials
>
findByPlnumAndKdaufAndKdpos
(
String
plnum
,
String
kdauf
,
String
kdpos
);
}
}
topsun/src/main/java/com/huigou/topsun/sap/nonProdApply/domain/SapNonProdApplyDept.java
View file @
b0a55ce2
...
@@ -1007,5 +1007,17 @@ public class SapNonProdApplyDept implements Serializable {
...
@@ -1007,5 +1007,17 @@ public class SapNonProdApplyDept implements Serializable {
@Column
(
name
=
"UEETK"
)
@Column
(
name
=
"UEETK"
)
private
String
ueetk
;
private
String
ueetk
;
/**
* 禁用原因
*/
@Column
(
name
=
"disable_reason"
)
private
String
disableReason
;
/**
* 启用原因
*/
@Column
(
name
=
"enable_reason"
)
private
String
enableReason
;
private
static
final
long
serialVersionUID
=
1L
;
private
static
final
long
serialVersionUID
=
1L
;
}
}
\ No newline at end of file
topsun/src/main/java/com/huigou/topsun/sap/nonProdApply/domain/vo/NonProdApplyBasicVo.java
View file @
b0a55ce2
...
@@ -690,4 +690,8 @@ public class NonProdApplyBasicVo extends NonProdApplyDeptVo {
...
@@ -690,4 +690,8 @@ public class NonProdApplyBasicVo extends NonProdApplyDeptVo {
//允许未限制的过量交货
//允许未限制的过量交货
private
String
ueetk
;
private
String
ueetk
;
private
String
disableReason
;
private
String
enableReason
;
}
}
topsun/src/main/java/com/huigou/topsun/sap/nonProdApply/domain/vo/NonProdApplyDeptBaseInfoVo.java
View file @
b0a55ce2
...
@@ -913,5 +913,9 @@ public class NonProdApplyDeptBaseInfoVo implements Serializable {
...
@@ -913,5 +913,9 @@ public class NonProdApplyDeptBaseInfoVo implements Serializable {
@Column
(
name
=
"UEETK"
)
@Column
(
name
=
"UEETK"
)
private
String
ueetk
;
private
String
ueetk
;
private
String
disableReason
;
private
String
enableReason
;
private
static
final
long
serialVersionUID
=
1L
;
private
static
final
long
serialVersionUID
=
1L
;
}
}
\ No newline at end of file
topsun/src/main/java/com/huigou/topsun/sap/purchaseInfoRecord/application/SapPurchaseInfoRecordItemApplication.java
View file @
b0a55ce2
...
@@ -26,4 +26,6 @@ public interface SapPurchaseInfoRecordItemApplication {
...
@@ -26,4 +26,6 @@ public interface SapPurchaseInfoRecordItemApplication {
void
save
(
SapPurchaseInfoRecordItem
sapPurchaseInfoRecordItem
);
void
save
(
SapPurchaseInfoRecordItem
sapPurchaseInfoRecordItem
);
Map
<
String
,
Object
>
querySapPurchaseInfoRecordItemByIds
(
SapPurchaseInfoRecordQueryRequest
request
);
Map
<
String
,
Object
>
querySapPurchaseInfoRecordItemByIds
(
SapPurchaseInfoRecordQueryRequest
request
);
Map
<
String
,
Object
>
queryUpdateSapPurchaseInfoRecordItemByIds
(
SapPurchaseInfoRecordQueryRequest
queryRequest
);
}
}
topsun/src/main/java/com/huigou/topsun/sap/purchaseInfoRecord/application/impl/SapPurchaseInfoRecordApplicationImpl.java
View file @
b0a55ce2
...
@@ -173,52 +173,35 @@ public class SapPurchaseInfoRecordApplicationImpl extends FlowBroker implements
...
@@ -173,52 +173,35 @@ public class SapPurchaseInfoRecordApplicationImpl extends FlowBroker implements
if
(
StringUtil
.
isBlank
(
sapPurchaseInfoRecordItemVo
.
getMeins
())){
if
(
StringUtil
.
isBlank
(
sapPurchaseInfoRecordItemVo
.
getMeins
())){
sapPurchaseInfoRecordItemVo
.
setMeins
(
sapPurchaseInfoRecordItemVo
.
getBprme
());
sapPurchaseInfoRecordItemVo
.
setMeins
(
sapPurchaseInfoRecordItemVo
.
getBprme
());
}
}
//物料编码为空 排序字段 传SAP FYL+7位流水号
if
(
"new"
.
equals
(
sapPurchaseInfoRecord
.
getFlag
())){
if
(
StringUtils
.
isBlank
(
sapPurchaseInfoRecordItemVo
.
getMatnr
())
//物料编码为空 排序字段 传SAP FYL+7位流水号
&&
StringUtils
.
isBlank
(
sapPurchaseInfoRecordItemVo
.
getSortl
()))
{
if
(
StringUtils
.
isBlank
(
sapPurchaseInfoRecordItemVo
.
getMatnr
())
//物料描述赋值给短文本
&&
StringUtils
.
isBlank
(
sapPurchaseInfoRecordItemVo
.
getSortl
()))
{
sapPurchaseInfoRecordItemVo
.
setTxz01
(
sapPurchaseInfoRecordItem
.
getMaktx
());
//物料描述赋值给短文本
//根据供应商和物料组来查询是否推送成功过,如果成功过 则设置序号 并累加1
sapPurchaseInfoRecordItemVo
.
setTxz01
(
sapPurchaseInfoRecordItem
.
getMaktx
());
SapPurchaseInfoRecordQueryRequest
query
=
new
SapPurchaseInfoRecordQueryRequest
();
//根据供应商和物料组来查询是否推送成功过,如果成功过 则设置序号 并累加1
query
.
setLifnr
(
sapPurchaseInfoRecordItem
.
getLifnr
());
SapPurchaseInfoRecordQueryRequest
query
=
new
SapPurchaseInfoRecordQueryRequest
();
query
.
setMatkl
(
sapPurchaseInfoRecordItem
.
getMatkl
());
query
.
setLifnr
(
sapPurchaseInfoRecordItem
.
getLifnr
());
synchronized
(
this
)
{
query
.
setMatkl
(
sapPurchaseInfoRecordItem
.
getMatkl
());
List
<
SapPurchaseInfoRecordItem
>
list
=
sapPurchaseInfoRecordItemApplication
.
querySapPurchaseInfoRecordItemByMaytkl
(
query
);
synchronized
(
this
)
{
List
<
SapPurchaseInfoRecordItem
>
list
=
sapPurchaseInfoRecordItemApplication
.
querySapPurchaseInfoRecordItemByMaytkl
(
query
);
//如果明细中有相同的供应商和物料组 ,成功后还没有写库时,需要重新计算list大小
//如果明细中有相同的供应商和物料组 ,成功后还没有写库时,需要重新计算list大小
List
<
SapPurchaseInfoRecordItem
>
sucessList
=
purchaseInfoRecordItemList
.
stream
()
List
<
SapPurchaseInfoRecordItem
>
sucessList
=
purchaseInfoRecordItemList
.
stream
()
.
filter
(
purchaseInfoRecordItem
->
"S"
.
equals
(
purchaseInfoRecordItem
.
getTYPE
())
.
filter
(
purchaseInfoRecordItem
->
"S"
.
equals
(
purchaseInfoRecordItem
.
getTYPE
())
&&
sapPurchaseInfoRecordItem
.
getLifnr
().
equals
(
purchaseInfoRecordItem
.
getLifnr
())
&&
sapPurchaseInfoRecordItem
.
getLifnr
().
equals
(
purchaseInfoRecordItem
.
getLifnr
())
&&
sapPurchaseInfoRecordItem
.
getMatkl
().
equals
(
purchaseInfoRecordItem
.
getMatkl
())
&&
sapPurchaseInfoRecordItem
.
getMatkl
().
equals
(
purchaseInfoRecordItem
.
getMatkl
())
).
collect
(
Collectors
.
toList
());
).
collect
(
Collectors
.
toList
());
list
.
addAll
(
sucessList
);
list
.
addAll
(
sucessList
);
if
(
list
.
size
()>
0
){
if
(
list
.
size
()>
0
){
sapPurchaseInfoRecordItemVo
.
setSortl
(
"FYL"
+
formatSerialNumber
(
list
.
size
()+
1
,
7
));
sapPurchaseInfoRecordItemVo
.
setSortl
(
"FYL"
+
formatSerialNumber
(
list
.
size
()+
1
,
7
));
}
else
{
}
else
{
sapPurchaseInfoRecordItemVo
.
setSortl
(
"FYL"
+
formatSerialNumber
(
1
,
7
));
sapPurchaseInfoRecordItemVo
.
setSortl
(
"FYL"
+
formatSerialNumber
(
1
,
7
));
}
}
}
}
}
sapPurchaseInfoRecordItem
.
setSortl
(
sapPurchaseInfoRecordItemVo
.
getSortl
());
// if (list.size()>0){
}
// synchronized(this) {
// String sql = "select t.* from code_rule t where t.RULE_KIND = ? for update";
// CodeRule codeRule = this.sqlExecutorDao.queryToObject(sql, CodeRule.class, "sortl");
// Integer currentValue = codeRule.getCurrentValue();
// if (currentValue == null) {
// currentValue = 0;
// }
// currentValue += 1;
// codeRule.setCurrentValue(currentValue);
// codeRule.setLastModifiedDate(DateUtil.getTimestamp());
// codeRule = codeRuleRepository.save(codeRule);
//
// String sortNo = codeRule.getPrefix() + formatSerialNumber(currentValue, 7);
// sapPurchaseInfoRecordItemVo.setSortl(sortNo);
// }
// sapPurchaseInfoRecordItem.setSortl(sapPurchaseInfoRecordItemVo.getSortl());
// }
}
sapPurchaseInfoRecordItem
.
setSortl
(
sapPurchaseInfoRecordItemVo
.
getSortl
());
SimpleDateFormat
dateFormat
=
new
SimpleDateFormat
(
"yyyyMMdd"
);
SimpleDateFormat
dateFormat
=
new
SimpleDateFormat
(
"yyyyMMdd"
);
if
(
sapPurchaseInfoRecordItem
.
getDatab
()
!=
null
){
if
(
sapPurchaseInfoRecordItem
.
getDatab
()
!=
null
){
String
datab
=
dateFormat
.
format
(
sapPurchaseInfoRecordItem
.
getDatab
());
String
datab
=
dateFormat
.
format
(
sapPurchaseInfoRecordItem
.
getDatab
());
...
@@ -251,6 +234,7 @@ public class SapPurchaseInfoRecordApplicationImpl extends FlowBroker implements
...
@@ -251,6 +234,7 @@ public class SapPurchaseInfoRecordApplicationImpl extends FlowBroker implements
sapPurchaseInfoRecordItem
.
setInfnr
(
sapResult
.
getMESSAGE_V1
());
sapPurchaseInfoRecordItem
.
setInfnr
(
sapResult
.
getMESSAGE_V1
());
sapPurchaseInfoRecordItem
.
setTYPE
(
sapResult
.
getTYPE
());
sapPurchaseInfoRecordItem
.
setTYPE
(
sapResult
.
getTYPE
());
sapPurchaseInfoRecordItem
.
setMESSAGE
(
sapResult
.
getMESSAGE
());
sapPurchaseInfoRecordItem
.
setMESSAGE
(
sapResult
.
getMESSAGE
());
sapPurchaseInfoRecordItem
.
setKnumh
(
sapResult
.
getMESSAGE_V2
());
// sapPurchaseInfoRecordItem.setInfnr();//回写信息记录编号 待确认 //?????
// sapPurchaseInfoRecordItem.setInfnr();//回写信息记录编号 待确认 //?????
sapPurchaseInfoRecordItemApplication
.
save
(
sapPurchaseInfoRecordItem
);
sapPurchaseInfoRecordItemApplication
.
save
(
sapPurchaseInfoRecordItem
);
this
.
markCancelRecordItems
(
sapPurchaseInfoRecordItem
);
this
.
markCancelRecordItems
(
sapPurchaseInfoRecordItem
);
...
...
topsun/src/main/java/com/huigou/topsun/sap/purchaseInfoRecord/application/impl/SapPurchaseInfoRecordItemApplicationImpl.java
View file @
b0a55ce2
...
@@ -60,6 +60,16 @@ public class SapPurchaseInfoRecordItemApplicationImpl extends BaseApplication im
...
@@ -60,6 +60,16 @@ public class SapPurchaseInfoRecordItemApplicationImpl extends BaseApplication im
Map
<
String
,
Object
>
map
=
this
.
sqlExecutorDao
.
executeSlicedQuery
(
queryModel
);
Map
<
String
,
Object
>
map
=
this
.
sqlExecutorDao
.
executeSlicedQuery
(
queryModel
);
return
map
;
return
map
;
}
}
@Override
public
Map
<
String
,
Object
>
queryUpdateSapPurchaseInfoRecordItemByIds
(
SapPurchaseInfoRecordQueryRequest
queryRequest
)
{
QueryDescriptor
queryDescriptor
=
this
.
sqlExecutorDao
.
getQuery
(
QUERY_XML_FILE_PATH
,
"queryUpdateSapPurchaseInfoRecordItemByIds"
);
QueryModel
queryModel
=
this
.
sqlExecutorDao
.
getQueryModel
(
queryDescriptor
,
queryRequest
);
queryModel
.
putDictionary
(
"mwskz"
,
DictUtil
.
getDictionary
(
"purchaseMwskz"
));
Map
<
String
,
Object
>
map
=
this
.
sqlExecutorDao
.
executeSlicedQuery
(
queryModel
);
return
map
;
}
@Override
@Override
public
List
<
SapPurchaseInfoRecordItem
>
querySapPurchaseInfoRecordItemByMaytkl
(
SapPurchaseInfoRecordQueryRequest
query
)
{
public
List
<
SapPurchaseInfoRecordItem
>
querySapPurchaseInfoRecordItemByMaytkl
(
SapPurchaseInfoRecordQueryRequest
query
)
{
QueryDescriptor
queryDescriptor
=
this
.
sqlExecutorDao
.
getQuery
(
QUERY_XML_FILE_PATH
,
"querySapPurchaseInfoRecordItemByMaytkl"
);
QueryDescriptor
queryDescriptor
=
this
.
sqlExecutorDao
.
getQuery
(
QUERY_XML_FILE_PATH
,
"querySapPurchaseInfoRecordItemByMaytkl"
);
...
...
topsun/src/main/java/com/huigou/topsun/sap/purchaseInfoRecord/controller/SapPurchaseInfoRecordController.java
View file @
b0a55ce2
...
@@ -68,7 +68,8 @@ public class SapPurchaseInfoRecordController extends CommonController {
...
@@ -68,7 +68,8 @@ public class SapPurchaseInfoRecordController extends CommonController {
*/
*/
Operator
operator
=
getOperator
();
Operator
operator
=
getOperator
();
sapPurchaseInfoRecord
.
setDefaultValues
(
new
OrgUnit
(
operator
.
getFullId
(),
operator
.
getFullName
()));
sapPurchaseInfoRecord
.
setDefaultValues
(
new
OrgUnit
(
operator
.
getFullId
(),
operator
.
getFullName
()));
return
forward
(
"purchaseInfoRecordDetail"
,
sapPurchaseInfoRecord
);
sapPurchaseInfoRecord
.
setFlag
(
"new"
);
return
forward
(
"purchaseInfoRecord"
,
sapPurchaseInfoRecord
);
}
}
public
String
addSapPurchaseInfoRecordDetail
()
{
public
String
addSapPurchaseInfoRecordDetail
()
{
...
@@ -90,6 +91,25 @@ public class SapPurchaseInfoRecordController extends CommonController {
...
@@ -90,6 +91,25 @@ public class SapPurchaseInfoRecordController extends CommonController {
return
forward
(
"addPurchaseInfoRecordDetail"
,
item
);
return
forward
(
"addPurchaseInfoRecordDetail"
,
item
);
}
}
public
String
updateSapPurchaseInfoRecordDetail
()
{
SDO
sdo
=
this
.
getSDO
();
String
id
=
sdo
.
getId
();
//String edit=sdo.getString("edit");
String
rowId
=
sdo
.
getString
(
"rowId"
);
SapPurchaseInfoRecordItem
item
=
JSONUtil
.
toBean
(
sdo
.
getString
(
"param"
),
SapPurchaseInfoRecordItem
.
class
);
if
(
item
!=
null
){
item
.
setRowId
(
rowId
);
if
(
id
.
equals
(
rowId
)){
item
.
setId
(
""
);
}
else
{
item
.
setId
(
id
);
}
}
this
.
putAttribute
(
"isReadOnly"
,
sdo
.
getString
(
"isReadOnly"
));
// SapPurchaseInfoRecord sapPurchaseInfoRecord = sapPurchaseInfoRecordApplication.loadSapPurchaseInfoRecord(id);
return
forward
(
"updatePurchaseInfoRecordDetail"
,
item
);
}
public
String
saveSapPurchaseInfoRecordDetail
()
{
public
String
saveSapPurchaseInfoRecordDetail
()
{
SDO
sdo
=
this
.
getSDO
();
SDO
sdo
=
this
.
getSDO
();
String
id
=
sdo
.
getId
();
String
id
=
sdo
.
getId
();
...
@@ -107,7 +127,11 @@ public class SapPurchaseInfoRecordController extends CommonController {
...
@@ -107,7 +127,11 @@ public class SapPurchaseInfoRecordController extends CommonController {
BizBillStatus
.
ABORTED
.
getId
()==
sapPurchaseInfoRecord
.
getStatusId
())){
BizBillStatus
.
ABORTED
.
getId
()==
sapPurchaseInfoRecord
.
getStatusId
())){
this
.
putAttribute
(
"isReadOnly"
,
"true"
);
this
.
putAttribute
(
"isReadOnly"
,
"true"
);
}
}
return
forward
(
"purchaseInfoRecordDetail"
,
sapPurchaseInfoRecord
);
if
(
"new"
.
equals
(
sapPurchaseInfoRecord
.
getFlag
())){
return
forward
(
"purchaseInfoRecord"
,
sapPurchaseInfoRecord
);
}
else
{
return
forward
(
"updatePurchaseInfoRecord"
,
sapPurchaseInfoRecord
);
}
}
}
public
String
copyPurchaseRecord
(){
public
String
copyPurchaseRecord
(){
...
@@ -124,7 +148,26 @@ public class SapPurchaseInfoRecordController extends CommonController {
...
@@ -124,7 +148,26 @@ public class SapPurchaseInfoRecordController extends CommonController {
sapPurchaseInfoRecord
.
setDefaultValues
(
new
OrgUnit
(
operator
.
getFullId
(),
operator
.
getFullName
()));
sapPurchaseInfoRecord
.
setDefaultValues
(
new
OrgUnit
(
operator
.
getFullId
(),
operator
.
getFullName
()));
String
nextCode
=
codeGenerator
.
getNextCode
(
"purchaseInfoRecord"
);
String
nextCode
=
codeGenerator
.
getNextCode
(
"purchaseInfoRecord"
);
sapPurchaseInfoRecord
.
setBillCode
(
nextCode
);
sapPurchaseInfoRecord
.
setBillCode
(
nextCode
);
return
forward
(
"purchaseInfoRecordDetail"
,
sapPurchaseInfoRecord
);
sapPurchaseInfoRecord
.
setFlag
(
"new"
);
return
forward
(
"purchaseInfoRecord"
,
sapPurchaseInfoRecord
);
}
public
String
showUpdateSapPurchaseInfoRecordDetail
(){
SDO
sdo
=
this
.
getSDO
();
String
ids
=
sdo
.
getString
(
"ids"
);
this
.
putAttribute
(
"processDefinitionKey"
,
SapPurchaseInfoRecordApplication
.
PROCESS_DEFINITION_KEY
);
// 新增的时候procUnitId一定要设置成Apply,不然jsp页面的所有表单元素是readonly状态
this
.
putAttribute
(
"procUnitId"
,
"Apply"
);
this
.
putAttribute
(
"ids"
,
ids
);
SapPurchaseInfoRecord
sapPurchaseInfoRecord
=
new
SapPurchaseInfoRecord
();
sapPurchaseInfoRecord
.
setId
(
null
);
sapPurchaseInfoRecord
.
setStatusId
(
BizBillStatus
.
APPLYING
.
getId
());
Operator
operator
=
getOperator
();
sapPurchaseInfoRecord
.
setDefaultValues
(
new
OrgUnit
(
operator
.
getFullId
(),
operator
.
getFullName
()));
String
nextCode
=
codeGenerator
.
getNextCode
(
"purchaseInfoRecord"
);
sapPurchaseInfoRecord
.
setBillCode
(
nextCode
);
sapPurchaseInfoRecord
.
setFlag
(
"update"
);
return
forward
(
"updatePurchaseInfoRecord"
,
sapPurchaseInfoRecord
);
}
}
public
String
cancelPurchaseRecord
(){
public
String
cancelPurchaseRecord
(){
...
...
topsun/src/main/java/com/huigou/topsun/sap/purchaseInfoRecord/controller/SapPurchaseInfoRecordItemController.java
View file @
b0a55ce2
...
@@ -39,6 +39,19 @@ public class SapPurchaseInfoRecordItemController extends CommonController {
...
@@ -39,6 +39,19 @@ public class SapPurchaseInfoRecordItemController extends CommonController {
return
toResult
(
map
);
return
toResult
(
map
);
}
}
public
String
queryUpdateSapPurchaseInfoRecordItems
(){
SDO
sdo
=
this
.
getSDO
();
Map
<
String
,
Object
>
map
=
new
HashMap
<>();
SapPurchaseInfoRecordQueryRequest
queryRequest
=
sdo
.
toQueryRequest
(
SapPurchaseInfoRecordQueryRequest
.
class
);
if
(
StringUtil
.
isNotBlank
(
queryRequest
.
getSapPurchaseInfoRecordId
())){
map
=
sapPurchaseInfoRecordItemApplication
.
querySapPurchaseInfoRecordItem
(
queryRequest
);
}
if
(
StringUtil
.
isBlank
(
queryRequest
.
getSapPurchaseInfoRecordId
())
&&
StringUtil
.
isNotBlank
(
queryRequest
.
getIds
())){
map
=
sapPurchaseInfoRecordItemApplication
.
queryUpdateSapPurchaseInfoRecordItemByIds
(
queryRequest
);
}
return
toResult
(
map
);
}
public
String
deleteSapPurchaseInfoRecordItem
(){
public
String
deleteSapPurchaseInfoRecordItem
(){
SDO
sdo
=
this
.
getSDO
();
SDO
sdo
=
this
.
getSDO
();
List
<
String
>
ids
=
sdo
.
getIds
();
List
<
String
>
ids
=
sdo
.
getIds
();
...
...
topsun/src/main/java/com/huigou/topsun/sap/purchaseInfoRecord/domain/SapPurchaseInfoRecord.java
View file @
b0a55ce2
...
@@ -3,6 +3,7 @@ package com.huigou.topsun.sap.purchaseInfoRecord.domain;
...
@@ -3,6 +3,7 @@ package com.huigou.topsun.sap.purchaseInfoRecord.domain;
import
com.huigou.data.domain.model.FlowBillAbstractEntity
;
import
com.huigou.data.domain.model.FlowBillAbstractEntity
;
import
lombok.Data
;
import
lombok.Data
;
import
javax.persistence.Column
;
import
javax.persistence.Entity
;
import
javax.persistence.Entity
;
import
javax.persistence.Table
;
import
javax.persistence.Table
;
...
@@ -15,6 +16,8 @@ import javax.persistence.Table;
...
@@ -15,6 +16,8 @@ import javax.persistence.Table;
@Entity
@Entity
@Data
@Data
public
class
SapPurchaseInfoRecord
extends
FlowBillAbstractEntity
{
public
class
SapPurchaseInfoRecord
extends
FlowBillAbstractEntity
{
@Column
(
name
=
"flag"
)
private
String
flag
;
@Override
@Override
protected
String
getCodeRuleId
()
{
protected
String
getCodeRuleId
()
{
return
"purchaseInfoRecord"
;
return
"purchaseInfoRecord"
;
...
...
topsun/src/main/java/com/huigou/topsun/sap/purchaseInfoRecord/domain/SapPurchaseInfoRecordItem.java
View file @
b0a55ce2
...
@@ -386,5 +386,11 @@ public class SapPurchaseInfoRecordItem extends AbstractEntity {
...
@@ -386,5 +386,11 @@ public class SapPurchaseInfoRecordItem extends AbstractEntity {
@Column
(
name
=
"cancel_flag"
)
@Column
(
name
=
"cancel_flag"
)
private
String
cancelFlag
;
private
String
cancelFlag
;
/**
* 定价条件号
*/
@Column
(
name
=
"KNUMH"
)
private
String
knumh
;
}
}
topsun/src/main/java/com/huigou/topsun/sap/purchaseInfoRecord/domain/vo/SapPurchaseInfoRecordItemVo.java
View file @
b0a55ce2
...
@@ -23,6 +23,13 @@ public class SapPurchaseInfoRecordItemVo implements Serializable {
...
@@ -23,6 +23,13 @@ public class SapPurchaseInfoRecordItemVo implements Serializable {
*/
*/
@JsonProperty
(
"INFNR"
)
@JsonProperty
(
"INFNR"
)
private
String
infnr
;
private
String
infnr
;
/**
* 定价条件号
*/
@JsonProperty
(
"KNUMH"
)
private
String
knumh
;
/**
/**
* 采购组织
* 采购组织
*/
*/
...
...
topsun/src/main/resources/config/topsun/sap/sapPurchaseInfoRecord/sapPurchaseInfoRecordItem.xml
View file @
b0a55ce2
...
@@ -69,6 +69,85 @@
...
@@ -69,6 +69,85 @@
<condition
column=
"id"
name=
"ids"
symbol=
"in"
alias=
"t"
/>
<condition
column=
"id"
name=
"ids"
symbol=
"in"
alias=
"t"
/>
</query>
</query>
<query
name=
"queryUpdateSapPurchaseInfoRecordItemByIds"
label=
"根据id查询"
table=
"sap_purchase_info_record_item"
>
<sql-query>
select
'' as id,
'' as sap_purchase_info_record_id,
t.ZYY,
t.LIFNR,
t.MATNR,
t.INFNR,
t.ESOKZ,
t.VERKF,
t.TELF1,
t.MEINS,
t.UMREN,
t.UMREZ,
t.URZLA,
t.ZFLAG,
t.LOEKZ,
t.EKORG,
t.WERKS,
t.APLFZ,
t.EKGRP,
t.NORBM,
t.MINBM,
t.MWSKZ,
t.WEBRE,
t.NETPR,
t.WAERS,
t.PEINH,
t.BPRME,
t.KSCHL,
t.PRDAT,
t.BPUMN,
t.BPUMZ,
t.DATAB,
t.DATBI,
t.KSTBM,
t.KONMS,
t.KBETR,
t.SEND_TIME,
t.VERSION,
t.NAME1,
t.MAKTX,
t.MATKL,
t.VERID,
t.SORTL,
t.TYPE,
t.MESSAGE,
t.REGIO,
t.STFKZ,
t.IDNLF,
t.WERKS_NAME,
t.MEINS_NAME,
t.WAERS_NAME,
t.EKGRP_NAME,
t.LIFNR_NAME,
t.EKORG_NAME,
t.BPRME_NAME,
t.MATKL_NAME,
t.REGIO_NAME,
t.KSTBM2,
t.KBETR2,
t.KSTBM3,
t.KBETR3,
t.URZLA_NAME,
t.KSTBM4,
t.KBETR4,
t.KSTBM5,
t.KBETR5,
t.FREIGHT,
t.KBETR6,
t.LTSNR,
t.LTSBZ,
t.REMARK,
t.CANCEL_FLAG,
t.KNUMH from sap_purchase_info_record_item t where 1=1
</sql-query>
<condition
column=
"id"
name=
"ids"
symbol=
"in"
alias=
"t"
/>
</query>
<query
name=
"querySapPurchaseInfoRecordItemByMaytkl"
label=
"根据物料组和供应商查询"
table=
"sap_purchase_info_record_item"
>
<query
name=
"querySapPurchaseInfoRecordItemByMaytkl"
label=
"根据物料组和供应商查询"
table=
"sap_purchase_info_record_item"
>
<sql-query>
<sql-query>
select * from sap_purchase_info_record_item t where t.type='S'
select * from sap_purchase_info_record_item t where t.type='S'
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment