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
cab83b03
Commit
cab83b03
authored
Apr 02, 2024
by
鲁鑫
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
采购申请对订单字段进行控制
parent
3591efaf
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
121 additions
and
59 deletions
+121
-59
sapPurchaseDetail.js
.../main/webapp/biz/topsun/sap/purchase/sapPurchaseDetail.js
+81
-39
sapPurchaseDetail.jsp
...main/webapp/biz/topsun/sap/purchase/sapPurchaseDetail.jsp
+1
-0
sapZNE1PurchaseDetail.js
...n/webapp/biz/topsun/sap/purchase/sapZNE1PurchaseDetail.js
+31
-20
sapZNE1PurchaseDetail.jsp
.../webapp/biz/topsun/sap/purchase/sapZNE1PurchaseDetail.jsp
+1
-0
SapPurchaseApplicationImpl.java
...purchase/application/impl/SapPurchaseApplicationImpl.java
+1
-0
SapPurchase.java
...va/com/huigou/topsun/sap/purchase/domain/SapPurchase.java
+6
-0
No files found.
topsun-xt/src/main/webapp/biz/topsun/sap/purchase/sapPurchaseDetail.js
View file @
cab83b03
...
@@ -3,6 +3,7 @@ $(function () {
...
@@ -3,6 +3,7 @@ $(function () {
initializeCommonUI
();
initializeCommonUI
();
bindEvent
();
bindEvent
();
initItemGrid
();
initItemGrid
();
initAufnr
();
});
});
function
initializeCommonUI
()
{
function
initializeCommonUI
()
{
...
@@ -15,17 +16,58 @@ function initializeCommonUI() {
...
@@ -15,17 +16,58 @@ function initializeCommonUI() {
}
}
function
bindEvent
()
{
function
bindEvent
()
{
fillinDate
=
$
(
"#fillinDate"
).
val
();
fillinDate
=
$
(
"#fillinDate"
).
val
();
$
(
'#knttp'
).
searchbox
({
type
:
"system"
,
name
:
"knttp"
,
getParam
:
function
(
item
)
{
return
{
filterValue
:
$
(
"#bsart"
).
val
()
}
},
onChange
:
function
(
value
,
data
)
{
initAufnr
(
data
.
knttp
)
$
(
'#knttp'
).
val
(
data
.
knttp
);
}
});
}
function
initAufnr
(
knttp
){
if
(
Public
.
isBlank
(
knttp
)){
knttp
=
$
(
'#knttp'
).
val
();
}
var
columns
=
itemGridManager
.
columns
;
columns
.
some
(
column
=>
{
if
(
column
.
name
==
"aufnr"
){
column
.
hide
=
knttp
==
'F'
?
false
:
true
;
column
.
editor
.
required
=
knttp
==
'F'
?
true
:
false
;
return
true
;
}
return
false
;
})
if
(
"K"
==
knttp
){
var
rows
=
itemGridManager
.
currentData
.
Rows
;
rows
.
forEach
(
row
=>
{
itemGridManager
.
updateRow
(
row
,{
aufnr
:
""
})
})
}
columns
.
splice
(
0
,
2
)
UICtrl
.
setGridColumns
(
itemGridManager
,
columns
);
}
}
function
initItemGrid
()
{
function
initItemGrid
()
{
var
toolbar
=
UICtrl
.
getDefaultToolbarOptions
({
var
toolbar
=
UICtrl
.
getDefaultToolbarOptions
({
addHandler
:
function
()
{
addHandler
:
function
()
{
UICtrl
.
addGridRow
(
itemGridManager
,
{
if
(
Public
.
isBlank
(
$
(
"#knttp"
).
val
())){
bnfpo
:
(
itemGridManager
.
getData
().
length
+
1
)
*
10
,
Public
.
tip
(
"请先选择科目分配类别"
);
pstyp
:
pstyp
,
}
else
{
badat
:
fillinDate
,
UICtrl
.
addGridRow
(
itemGridManager
,
{
erdat
:
fillinDate
bnfpo
:
(
itemGridManager
.
getData
().
length
+
1
)
*
10
,
});
pstyp
:
pstyp
,
badat
:
fillinDate
,
erdat
:
fillinDate
,
knttp
:
$
(
"#knttp"
).
val
()
});
}
},
},
deleteHandler
:
function
()
{
deleteHandler
:
function
()
{
var
_grid
=
UICtrl
.
getGridManager
(
'#maingrid'
);
var
_grid
=
UICtrl
.
getGridManager
(
'#maingrid'
);
...
@@ -101,22 +143,22 @@ function getGridColumns() {
...
@@ -101,22 +143,22 @@ function getGridColumns() {
editor
:
{
type
:
'spinner'
,
min
:
10
,
max
:
200
,
mask
:
'nnn'
}
editor
:
{
type
:
'spinner'
,
min
:
10
,
max
:
200
,
mask
:
'nnn'
}
},);
},);
columns
.
push
({
display
:
"项次类别"
,
name
:
"pstyp"
,
width
:
"100"
,
align
:
"left"
,
type
:
"string"
,
hide
:
true
},);
columns
.
push
({
display
:
"项次类别"
,
name
:
"pstyp"
,
width
:
"100"
,
align
:
"left"
,
type
:
"string"
,
hide
:
true
},);
columns
.
push
({
//
columns.push({
display
:
"科目分配类别"
,
name
:
"knttp"
,
width
:
"100"
,
align
:
"left"
,
type
:
"string"
,
//
display: "科目分配类别", name: "knttp", width: "100", align: "left", type: "string",
editor
:
{
//
editor: {
required
:
true
,
type
:
"select"
,
//
required: true, type: "select",
data
:
{
//
data: {
type
:
'system'
,
//
type: 'system',
name
:
"knttp"
,
//
name: "knttp",
getParam
:
function
(
item
)
{
//
getParam: function (item) {
return
{
filterValue
:
$
(
"#bsart"
).
val
()}
//
return {filterValue: $("#bsart").val()}
},
//
},
back
:
{
//
back: {
knttp
:
"knttp"
//
knttp: "knttp"
}
//
}
},
//
},
}
//
}
},);
//
},);
columns
.
push
({
columns
.
push
({
display
:
"工厂"
,
name
:
"werks"
,
width
:
"100"
,
align
:
"left"
,
type
:
"string"
,
display
:
"工厂"
,
name
:
"werks"
,
width
:
"100"
,
align
:
"left"
,
type
:
"string"
,
editor
:
{
editor
:
{
...
@@ -256,7 +298,7 @@ function getGridColumns() {
...
@@ -256,7 +298,7 @@ function getGridColumns() {
columns
.
push
({
display
:
"创建者"
,
name
:
"ernam"
,
width
:
"200"
,
align
:
"left"
,
type
:
"string"
},);
columns
.
push
({
display
:
"创建者"
,
name
:
"ernam"
,
width
:
"200"
,
align
:
"left"
,
type
:
"string"
},);
columns
.
push
({
columns
.
push
({
display
:
"申请人"
,
name
:
"afnam"
,
width
:
"90"
,
align
:
"left"
,
type
:
"string"
,
display
:
"申请人"
,
name
:
"afnam"
,
width
:
"90"
,
align
:
"left"
,
type
:
"string"
,
editor
:
{
type
:
'text'
,
required
:
fals
e
},
editor
:
{
type
:
'text'
,
required
:
tru
e
},
},);
},);
columns
.
push
({
columns
.
push
({
display
:
"预估单价"
,
name
:
"preis"
,
width
:
"100"
,
align
:
"left"
,
type
:
"string"
,
display
:
"预估单价"
,
name
:
"preis"
,
width
:
"100"
,
align
:
"left"
,
type
:
"string"
,
...
@@ -309,31 +351,31 @@ function getGridColumns() {
...
@@ -309,31 +351,31 @@ function getGridColumns() {
columns
.
push
({
columns
.
push
({
display
:
"多重科目分配"
,
name
:
"vrtkz"
,
width
:
"100"
,
align
:
"left"
,
type
:
"string"
,
display
:
"多重科目分配"
,
name
:
"vrtkz"
,
width
:
"100"
,
align
:
"left"
,
type
:
"string"
,
//editor: {type: 'text'},
//editor: {type: 'text'},
render
:
function
(
item
)
{
//
render: function (item) {
//资产消耗性申购,若申请数量大于1,此处不能为空,必须选择1
//
//资产消耗性申购,若申请数量大于1,此处不能为空,必须选择1
if
(
item
.
knttp
==
"A"
&&
item
.
menge
>
1
)
{
//
if (item.knttp == "A" && item.menge > 1) {
return
item
.
vrtkz
=
1
;
//
return item.vrtkz = 1;
}
//
}
}
//
}
},);
},);
columns
.
push
({
columns
.
push
({
display
:
"部分发票"
,
name
:
"twrkz"
,
width
:
"100"
,
align
:
"left"
,
type
:
"string"
,
display
:
"部分发票"
,
name
:
"twrkz"
,
width
:
"100"
,
align
:
"left"
,
type
:
"string"
,
editor
:
{
type
:
'text'
},
editor
:
{
type
:
'text'
},
render
:
function
(
item
)
{
//
render: function (item) {
//资产消耗性申购,若申请数量大于1,此处不能为空,必须选择1
//
//资产消耗性申购,若申请数量大于1,此处不能为空,必须选择1
if
(
item
.
knttp
==
"A"
&&
item
.
menge
>
1
)
{
//
if (item.knttp == "A" && item.menge > 1) {
return
item
.
twrkz
=
1
;
//
return item.twrkz = 1;
}
//
}
}
//
}
},);
},);
columns
.
push
({
columns
.
push
({
display
:
"PR分解数量"
,
name
:
"ekbnMenge"
,
width
:
"100"
,
align
:
"left"
,
type
:
"string"
,
display
:
"PR分解数量"
,
name
:
"ekbnMenge"
,
width
:
"100"
,
align
:
"left"
,
type
:
"string"
,
editor
:
{
type
:
'text'
}
editor
:
{
type
:
'text'
}
},);
},);
columns
.
push
({
//
columns.push({
display
:
"总账科目"
,
name
:
"sakto"
,
width
:
"100"
,
align
:
"left"
,
type
:
"string"
,
//
display: "总账科目", name: "sakto", width: "100", align: "left", type: "string",
editor
:
{
type
:
'text'
,
required
:
true
}
//
editor: {type: 'text', required: true}
},);
//
},);
columns
.
push
({
columns
.
push
({
display
:
"成本中心"
,
name
:
"kostl"
,
width
:
"200"
,
align
:
"left"
,
type
:
"string"
,
display
:
"成本中心"
,
name
:
"kostl"
,
width
:
"200"
,
align
:
"left"
,
type
:
"string"
,
editor
:
{
editor
:
{
...
...
topsun-xt/src/main/webapp/biz/topsun/sap/purchase/sapPurchaseDetail.jsp
View file @
cab83b03
...
@@ -29,6 +29,7 @@
...
@@ -29,6 +29,7 @@
<div
class=
"hg-form-cols"
>
<div
class=
"hg-form-cols"
>
<div
class=
"hg-form-row"
>
<div
class=
"hg-form-row"
>
<x:selectC
name=
"bsart"
label=
"pr类型"
disabled=
"true"
labelCol=
"1"
fieldCol=
"2"
required=
"true"
/>
<x:selectC
name=
"bsart"
label=
"pr类型"
disabled=
"true"
labelCol=
"1"
fieldCol=
"2"
required=
"true"
/>
<x:inputC
name=
"knttp"
label=
"科目分配类别"
labelCol=
"1"
fieldCol=
"2"
required=
"true"
wrapper=
"select"
/>
<x:inputC
name=
"banfn"
label=
"采购申请编号"
readonly=
"true"
labelCol=
"1"
fieldCol=
"2"
required=
"false"
/>
<x:inputC
name=
"banfn"
label=
"采购申请编号"
readonly=
"true"
labelCol=
"1"
fieldCol=
"2"
required=
"false"
/>
</div>
</div>
</div>
</div>
...
...
topsun-xt/src/main/webapp/biz/topsun/sap/purchase/sapZNE1PurchaseDetail.js
View file @
cab83b03
...
@@ -16,6 +16,17 @@ function initializeCommonUI() {
...
@@ -16,6 +16,17 @@ function initializeCommonUI() {
function
bindEvent
()
{
function
bindEvent
()
{
fillinDate
=
$
(
"#fillinDate"
).
val
();
fillinDate
=
$
(
"#fillinDate"
).
val
();
$
(
'#knttp'
).
searchbox
({
type
:
"system"
,
name
:
"knttp"
,
getParam
:
function
(
item
)
{
return
{
filterValue
:
$
(
"#bsart"
).
val
()
}
},
onChange
:
function
(
value
,
data
)
{
$
(
'#knttp'
).
val
(
data
.
knttp
);
}
});
}
}
function
initItemGrid
()
{
function
initItemGrid
()
{
...
@@ -102,22 +113,22 @@ function getGridColumns() {
...
@@ -102,22 +113,22 @@ function getGridColumns() {
editor
:
{
type
:
'spinner'
,
min
:
10
,
max
:
200
,
mask
:
'nnn'
}
editor
:
{
type
:
'spinner'
,
min
:
10
,
max
:
200
,
mask
:
'nnn'
}
},);
},);
columns
.
push
({
display
:
"项次类别"
,
name
:
"pstyp"
,
width
:
"100"
,
align
:
"left"
,
type
:
"string"
,
hide
:
true
},);
columns
.
push
({
display
:
"项次类别"
,
name
:
"pstyp"
,
width
:
"100"
,
align
:
"left"
,
type
:
"string"
,
hide
:
true
},);
columns
.
push
({
//
columns.push({
display
:
"科目分配类别"
,
name
:
"knttp"
,
width
:
"100"
,
align
:
"left"
,
type
:
"string"
,
//
display: "科目分配类别", name: "knttp", width: "100", align: "left", type: "string",
editor
:
{
//
editor: {
required
:
true
,
type
:
"select"
,
//
required: true, type: "select",
data
:
{
//
data: {
type
:
'system'
,
//
type: 'system',
name
:
"knttp"
,
//
name: "knttp",
getParam
:
function
(
item
)
{
//
getParam: function (item) {
return
{
filterValue
:
$
(
"#bsart"
).
val
()}
//
return {filterValue: $("#bsart").val()}
},
//
},
back
:
{
//
back: {
knttp
:
"knttp"
//
knttp: "knttp"
}
//
}
},
//
},
}
//
}
},);
//
},);
columns
.
push
({
columns
.
push
({
display
:
"工厂"
,
name
:
"werks"
,
width
:
"100"
,
align
:
"left"
,
type
:
"string"
,
display
:
"工厂"
,
name
:
"werks"
,
width
:
"100"
,
align
:
"left"
,
type
:
"string"
,
editor
:
{
editor
:
{
...
@@ -303,10 +314,10 @@ function getGridColumns() {
...
@@ -303,10 +314,10 @@ function getGridColumns() {
display
:
"PR分解数量"
,
name
:
"ekbnMenge"
,
width
:
"100"
,
align
:
"left"
,
type
:
"string"
,
display
:
"PR分解数量"
,
name
:
"ekbnMenge"
,
width
:
"100"
,
align
:
"left"
,
type
:
"string"
,
editor
:
{
type
:
'text'
}
editor
:
{
type
:
'text'
}
},);
},);
columns
.
push
({
//
columns.push({
display
:
"总账科目"
,
name
:
"sakto"
,
width
:
"100"
,
align
:
"left"
,
type
:
"string"
,
//
display: "总账科目", name: "sakto", width: "100", align: "left", type: "string",
editor
:
{
type
:
'text'
,
required
:
false
}
//
editor: {type: 'text', required: false}
},);
//
},);
columns
.
push
({
columns
.
push
({
display
:
"资产编号"
,
name
:
"anln1"
,
width
:
"200"
,
align
:
"left"
,
type
:
"string"
,
display
:
"资产编号"
,
name
:
"anln1"
,
width
:
"200"
,
align
:
"left"
,
type
:
"string"
,
editor
:
{
editor
:
{
...
...
topsun-xt/src/main/webapp/biz/topsun/sap/purchase/sapZNE1PurchaseDetail.jsp
View file @
cab83b03
...
@@ -29,6 +29,7 @@
...
@@ -29,6 +29,7 @@
<div
class=
"hg-form-cols"
>
<div
class=
"hg-form-cols"
>
<div
class=
"hg-form-row"
>
<div
class=
"hg-form-row"
>
<x:selectC
name=
"bsart"
label=
"pr类型"
disabled=
"true"
labelCol=
"1"
fieldCol=
"2"
required=
"true"
/>
<x:selectC
name=
"bsart"
label=
"pr类型"
disabled=
"true"
labelCol=
"1"
fieldCol=
"2"
required=
"true"
/>
<x:inputC
name=
"knttp"
label=
"科目分配类别"
labelCol=
"1"
fieldCol=
"2"
required=
"true"
wrapper=
"select"
/>
<x:inputC
name=
"banfn"
label=
"采购申请编号"
readonly=
"true"
labelCol=
"1"
fieldCol=
"2"
required=
"false"
/>
<x:inputC
name=
"banfn"
label=
"采购申请编号"
readonly=
"true"
labelCol=
"1"
fieldCol=
"2"
required=
"false"
/>
</div>
</div>
</div>
</div>
...
...
topsun/src/main/java/com/huigou/topsun/sap/purchase/application/impl/SapPurchaseApplicationImpl.java
View file @
cab83b03
...
@@ -159,6 +159,7 @@ public class SapPurchaseApplicationImpl extends FlowBroker implements SapPurchas
...
@@ -159,6 +159,7 @@ public class SapPurchaseApplicationImpl extends FlowBroker implements SapPurchas
sapPurchaseItemList
.
forEach
(
sapPurchaseItem
->
{
sapPurchaseItemList
.
forEach
(
sapPurchaseItem
->
{
SapPurchaseItemVo
sapPurchaseItemVo
=
new
SapPurchaseItemVo
();
SapPurchaseItemVo
sapPurchaseItemVo
=
new
SapPurchaseItemVo
();
BeanUtil
.
copyProperties
(
sapPurchaseItem
,
sapPurchaseItemVo
);
BeanUtil
.
copyProperties
(
sapPurchaseItem
,
sapPurchaseItemVo
);
sapPurchaseItemVo
.
setKnttp
(
sapPurchase
.
getKnttp
());
sapPurchaseItemVo
.
setBillCode
(
sapPurchase
.
getBillCode
());
sapPurchaseItemVo
.
setBillCode
(
sapPurchase
.
getBillCode
());
sapPurchaseItemVo
.
setErnam
(
sapPurchase
.
getPersonMemberName
());
sapPurchaseItemVo
.
setErnam
(
sapPurchase
.
getPersonMemberName
());
if
(
sapPurchaseItem
.
getBadat
()
!=
null
){
if
(
sapPurchaseItem
.
getBadat
()
!=
null
){
...
...
topsun/src/main/java/com/huigou/topsun/sap/purchase/domain/SapPurchase.java
View file @
cab83b03
...
@@ -35,6 +35,12 @@ public class SapPurchase extends FlowBillAbstractEntity {
...
@@ -35,6 +35,12 @@ public class SapPurchase extends FlowBillAbstractEntity {
@Column
(
name
=
"FRGDT"
)
@Column
(
name
=
"FRGDT"
)
private
Date
frgdt
;
private
Date
frgdt
;
/**
* 科目分配类别
*/
@Column
(
name
=
"KNTTP"
)
private
String
knttp
;
private
static
final
long
serialVersionUID
=
1L
;
private
static
final
long
serialVersionUID
=
1L
;
@Override
@Override
...
...
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