Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
H
hp-smart
Overview
Overview
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
platform
hp-smart
Commits
fc9a31e9
Commit
fc9a31e9
authored
Jan 22, 2024
by
江和松
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
1.采购入库单功能提交
parent
bfdf0642
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
40 additions
and
39 deletions
+40
-39
ServiceHPKC001.java
.../java/com/baosight/hpjx/hp/kc/service/ServiceHPKC001.java
+4
-10
ServiceHPPZ006.java
.../java/com/baosight/hpjx/hp/pz/service/ServiceHPPZ006.java
+28
-12
HPKC001.js
src/main/webapp/HP/KC/HPKC001.js
+5
-5
HPKC001.jsp
src/main/webapp/HP/KC/HPKC001.jsp
+3
-12
No files found.
src/main/java/com/baosight/hpjx/hp/kc/service/ServiceHPKC001.java
View file @
fc9a31e9
...
...
@@ -6,16 +6,11 @@ import com.baosight.hpjx.common.InventTypeEnun;
import
com.baosight.hpjx.core.dao.DaoUtils
;
import
com.baosight.hpjx.hp.constant.HPConstant
;
import
com.baosight.hpjx.hp.kc.domain.HPKC001
;
import
com.baosight.hpjx.hp.kc.domain.HPKC001
;
import
com.baosight.hpjx.hp.kc.domain.HPKC005
;
import
com.baosight.hpjx.hp.kc.domain.HPKC009
;
import
com.baosight.hpjx.hp.pz.domain.HPPZ007
;
import
com.baosight.hpjx.hp.pz.domain.THppz004
;
import
com.baosight.hpjx.util.AssertUtils
;
import
com.baosight.hpjx.util.CommonMethod
;
import
com.baosight.hpjx.util.LogUtils
;
import
com.baosight.hpjx.util.StringUtil
;
import
com.baosight.hpjx.util.contants.ACConstants
;
import
com.baosight.iplat4j.core.ei.EiBlock
;
import
com.baosight.iplat4j.core.ei.EiConstant
;
import
com.baosight.iplat4j.core.ei.EiInfo
;
...
...
@@ -25,7 +20,6 @@ import com.baosight.iplat4j.ed.util.SequenceGenerator;
import
org.apache.commons.lang3.StringUtils
;
import
java.util.*
;
import
java.util.stream.Collectors
;
/**
* @author YK
...
...
@@ -41,7 +35,7 @@ public class ServiceHPKC001 extends ServiceBase {
try
{
CommonMethod
.
initBlock
(
inInfo
,
Arrays
.
asList
(
DdynamicEnum
.
WH_RECORD_BLOCK_ID
),
null
);
CommonMethod
.
initBlock
(
inInfo
,
Arrays
.
asList
(
DdynamicEnum
.
WH_RECORD_QUERY_BLOCK_ID
),
null
);
CommonMethod
.
initBlock
(
inInfo
,
Arrays
.
asList
(
DdynamicEnum
.
MATERIAL_RECORD
_BLOCK_ID
),
null
);
CommonMethod
.
initBlock
(
inInfo
,
Arrays
.
asList
(
DdynamicEnum
.
INVENT_NAME
_BLOCK_ID
),
null
);
CommonMethod
.
initBlock
(
inInfo
,
Arrays
.
asList
(
DdynamicEnum
.
INVENT_SPEC_BLOCK_ID
),
null
);
inInfo
.
addBlock
(
EiConstant
.
resultBlock
).
addBlockMeta
(
new
HPKC001
().
eiMetadata
);
inInfo
.
setBlock
(
InventTypeEnun
.
generatorEiBlock
());
...
...
@@ -91,7 +85,7 @@ public class ServiceHPKC001 extends ServiceBase {
insertEntity
.
setDocumentTime
(
StringUtil
.
removeHorizontalLine
(
insertEntity
.
getDocumentTime
()));
insertEntity
.
setStatus
(
1
);
insertEntity
.
setApprovalStatus
(
0
);
DaoUtils
.
insert
(
"HPKC001.insert"
,
insertEntity
);
dao
.
insert
(
"HPKC001.insert"
,
insertEntity
);
}
inInfo
=
this
.
query
(
inInfo
);
inInfo
.
setStatus
(
EiConstant
.
STATUS_DEFAULT
);
...
...
@@ -146,7 +140,7 @@ public class ServiceHPKC001 extends ServiceBase {
updateEntity
.
setWhName
(((
HPPZ007
)
query
.
get
(
0
)).
getWhName
());
//物料类型
updateEntity
.
setMaterialTypeName
(
InventTypeEnun
.
getNameByCode
(
updateEntity
.
getMaterialType
()));
DaoUtils
.
update
(
"HPKC001.update"
,
updateEntity
);
dao
.
insert
(
"HPKC001.update"
,
updateEntity
);
}
inInfo
=
this
.
query
(
inInfo
);
inInfo
.
setStatus
(
EiConstant
.
STATUS_DEFAULT
);
...
...
@@ -156,7 +150,7 @@ public class ServiceHPKC001 extends ServiceBase {
inInfo
.
setStatus
(
EiConstant
.
STATUS_FAILURE
);
inInfo
.
setMsg
(
"操作失败!原因参见详细错误描述!"
);
inInfo
.
setDetailMsg
(
e
.
getMessage
());
logError
(
"
新增
失败"
,
e
.
getMessage
());
logError
(
"
修改
失败"
,
e
.
getMessage
());
return
inInfo
;
}
return
query
(
inInfo
);
...
...
src/main/java/com/baosight/hpjx/hp/pz/service/ServiceHPPZ006.java
View file @
fc9a31e9
...
...
@@ -15,17 +15,14 @@ import com.baosight.iplat4j.core.ei.EiInfo;
import
com.baosight.iplat4j.core.exception.PlatException
;
import
com.baosight.iplat4j.core.service.impl.ServiceBase
;
import
java.util.ArrayList
;
import
java.util.Arrays
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.*
;
/**
* @author:songx
* @date:2024/1/22,15:17
*/
public
class
ServiceHPPZ006
extends
ServiceBase
{
/**
* 画面初始化
*
...
...
@@ -42,7 +39,7 @@ public class ServiceHPPZ006 extends ServiceBase {
}
return
inInfo
;
}
/**
* 查询操作.
*/
...
...
@@ -55,7 +52,7 @@ public class ServiceHPPZ006 extends ServiceBase {
}
return
inInfo
;
}
/**
* 新增操作
*
...
...
@@ -84,7 +81,7 @@ public class ServiceHPPZ006 extends ServiceBase {
}
return
inInfo
;
}
/**
* 校验保存的数据
*
...
...
@@ -98,7 +95,7 @@ public class ServiceHPPZ006 extends ServiceBase {
AssertUtils
.
isNull
(
fPz006
.
getInventCode
(),
"存货名称不能为空"
);
}
}
/**
* 修改操作
*
...
...
@@ -123,7 +120,7 @@ public class ServiceHPPZ006 extends ServiceBase {
}
return
inInfo
;
}
/**
* 删除操作
*
...
...
@@ -144,7 +141,7 @@ public class ServiceHPPZ006 extends ServiceBase {
}
return
inInfo
;
}
/**
* 规格下拉框
*
...
...
@@ -161,5 +158,24 @@ public class ServiceHPPZ006 extends ServiceBase {
}
return
inInfo
;
}
public
EiInfo
queryComboBox
(
EiInfo
eiInfo
)
{
Map
map
=
new
HashMap
();
map
.
put
(
"inventType"
,
eiInfo
.
getString
(
"inventType"
));
List
<
DdynamicEnum
>
list
=
new
ArrayList
<>();
list
.
add
(
DdynamicEnum
.
INVENT_RECORD_BLOCK_ID
);
CommonMethod
.
initBlock
(
eiInfo
,
list
,
map
);
return
eiInfo
;
}
public
EiInfo
queryMaterialComboBox
(
EiInfo
eiInfo
)
{
Map
map
=
new
HashMap
();
map
.
put
(
"inventType"
,
eiInfo
.
getString
(
"inventType"
));
List
<
DdynamicEnum
>
list
=
new
ArrayList
<>();
list
.
add
(
DdynamicEnum
.
MATERIAL_RECORD_BLOCK_ID
);
CommonMethod
.
initBlock
(
eiInfo
,
list
,
map
);
return
eiInfo
;
}
}
src/main/webapp/HP/KC/HPKC001.js
View file @
fc9a31e9
...
...
@@ -36,9 +36,9 @@ $(function() {
eiInfo
.
set
(
"inventType"
,
options
.
model
[
"materialType"
]);
var
dataSource
;
EiCommunicator
.
send
(
"HPPZ00
6"
,
"queryMaterial
ComboBox"
,
eiInfo
,
{
EiCommunicator
.
send
(
"HPPZ00
4"
,
"query
ComboBox"
,
eiInfo
,
{
onSuccess
:
function
(
ei
)
{
dataSource
=
ei
.
getBlock
(
"
material_record
_block_id"
).
getMappedRows
();
dataSource
=
ei
.
getBlock
(
"
invent_name
_block_id"
).
getMappedRows
();
materialCodeGlobalData
=
dataSource
;
},
onFail
:
function
(
ei
)
{
}
...
...
@@ -222,10 +222,10 @@ $(function() {
*/
$
(
window
).
load
(
function
()
{
// 存货名称
let
in
Info
=
new
EiInfo
();
EiCommunicator
.
send
(
"HPPZ00
6"
,
"queryMaterialComboBox"
,
in
Info
,
{
let
ei
Info
=
new
EiInfo
();
EiCommunicator
.
send
(
"HPPZ00
4"
,
"queryComboBox"
,
ei
Info
,
{
onSuccess
:
function
(
ei
)
{
materialCodeGlobalData
=
ei
.
getBlock
(
"material_record
_block_id"
).
getMappedRows
();
inventNameGlobalData
=
ei
.
getBlock
(
"invent_name
_block_id"
).
getMappedRows
();
},
onFail
:
function
(
ei
)
{
}
...
...
src/main/webapp/HP/KC/HPKC001.jsp
View file @
fc9a31e9
...
...
@@ -26,22 +26,13 @@
<EF:EFColumn
ename=
"id"
cname=
"主键id"
hidden=
"true"
/>
<EF:EFColumn
ename=
"documentTime"
cname=
"单据日期"
editType=
"date"
dateFormat=
"yyyy-MM-dd"
parseFormats=
"['yyyy-MM-dd']"
width=
"100"
required=
"true"
/>
<EF:EFColumn
ename=
"documentCode"
cname=
"采购入库单号"
width=
"100"
readonly=
"false"
align=
"center"
required=
"false"
enable=
"false"
/>
<EF:EFComboColumn
ename=
"materialType"
cname=
"物料类型"
columnTemplate=
"#=textField#"
itemTemplate=
"#=textField#"
blockName=
"customer_type_block_id"
textField=
"textField"
valueField=
"valueField"
align=
"center"
filter=
"contains"
width=
"100"
>
<EF:EFComboColumn
ename=
"materialType"
cname=
"物料类型"
width=
"90"
align=
"center"
>
<EF:EFCodeOption
codeName=
"hpjx.hpkc.inventType"
/>
</EF:EFComboColumn>
<EF:EFColumn
ename=
"whCode"
cname=
"仓库名称"
width=
"100"
readonly=
"false"
required=
"true"
/>
<EF:EFColumn
ename=
"whName"
cname=
"仓库名称"
width=
"100"
readonly=
"false"
hidden=
"true"
/>
<EF:EFColumn
ename=
"materialCode"
cname=
"物料编码"
width=
"100"
readonly=
"false"
required=
"true"
/>
<EF:EFColumn
ename=
"materialName"
cname=
"物料名称"
width=
"100"
readonly=
"false"
enable=
"false"
required=
"true"
/>
<EF:EFColumn
ename=
"materialName"
cname=
"物料名称"
width=
"100"
readonly=
"false"
enable=
"false"
hidden=
"true"
required=
"true"
/>
<EF:EFColumn
ename=
"unit"
cname=
"单位"
width=
"80"
readonly=
"false"
align=
"center"
enable=
"false"
required=
"true"
/>
<EF:EFColumn
ename=
"spec"
cname=
"规格"
width=
"120"
readonly=
"false"
align=
"center"
required=
"true"
/>
<EF:EFColumn
ename=
"quantity"
cname=
"数量"
width=
"80"
defaultValue=
"0"
data-regex=
"/^[0-9]\\\d*$/"
data-errorprompt=
"请输入正整数"
readonly=
"false"
align=
"right"
required=
"true"
/>
...
...
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