Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
H
hg-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
hg-smart
Commits
e3fc65ee
Commit
e3fc65ee
authored
Jun 22, 2024
by
江和松
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
采购入库流程逻辑修改
入库质检后直接生成采购入库单,采购入库单提交后才进入实时库存,并且修改采购单信息
parent
fc7ddf93
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
214 additions
and
22 deletions
+214
-22
HGKC001.java
src/main/java/com/baosight/hggp/hg/kc/domain/HGKC001.java
+0
-0
ServiceHGKC001.java
.../java/com/baosight/hggp/hg/kc/service/ServiceHGKC001.java
+48
-6
HGKC001.xml
src/main/java/com/baosight/hggp/hg/kc/sql/HGKC001.xml
+41
-3
HGKCTools.java
src/main/java/com/baosight/hggp/hg/kc/tools/HGKCTools.java
+48
-1
ServiceHGZL001.java
.../java/com/baosight/hggp/hg/zl/service/ServiceHGZL001.java
+13
-10
HGKC001.js
src/main/webapp/HG/KC/HGKC001.js
+59
-1
HGKC001.jsp
src/main/webapp/HG/KC/HGKC001.jsp
+5
-1
No files found.
src/main/java/com/baosight/hggp/hg/kc/domain/HGKC001.java
View file @
e3fc65ee
This diff is collapsed.
Click to expand it.
src/main/java/com/baosight/hggp/hg/kc/service/ServiceHGKC001.java
View file @
e3fc65ee
...
@@ -7,15 +7,15 @@ import com.baosight.hggp.core.enums.DeleteFlagEnum;
...
@@ -7,15 +7,15 @@ import com.baosight.hggp.core.enums.DeleteFlagEnum;
import
com.baosight.hggp.hg.cg.tools.HGCGTools
;
import
com.baosight.hggp.hg.cg.tools.HGCGTools
;
import
com.baosight.hggp.hg.constant.HGConstant
;
import
com.baosight.hggp.hg.constant.HGConstant
;
import
com.baosight.hggp.hg.kc.domain.HGKC001
;
import
com.baosight.hggp.hg.kc.domain.HGKC001
;
import
com.baosight.hggp.hg.kc.domain.HGKC003
;
import
com.baosight.hggp.hg.kc.tools.HGKCTools
;
import
com.baosight.hggp.hg.kc.utils.HGKCUtils
;
import
com.baosight.hggp.hg.kc.utils.HGKCUtils
;
import
com.baosight.hggp.util.AssertUtils
;
import
com.baosight.hggp.util.*
;
import
com.baosight.hggp.util.CommonMethod
;
import
com.baosight.iplat4j.core.ei.EiBlock
;
import
com.baosight.hggp.util.EiInfoUtils
;
import
com.baosight.hggp.util.LogUtils
;
import
com.baosight.hggp.util.MapUtils
;
import
com.baosight.iplat4j.core.ei.EiConstant
;
import
com.baosight.iplat4j.core.ei.EiConstant
;
import
com.baosight.iplat4j.core.ei.EiInfo
;
import
com.baosight.iplat4j.core.ei.EiInfo
;
import
com.baosight.iplat4j.core.exception.PlatException
;
import
com.baosight.iplat4j.core.exception.PlatException
;
import
com.baosight.iplat4j.core.resource.I18nMessages
;
import
com.baosight.iplat4j.core.service.impl.ServiceBase
;
import
com.baosight.iplat4j.core.service.impl.ServiceBase
;
import
java.util.Arrays
;
import
java.util.Arrays
;
...
@@ -116,7 +116,7 @@ public class ServiceHGKC001 extends ServiceBase {
...
@@ -116,7 +116,7 @@ public class ServiceHGKC001 extends ServiceBase {
*/
*/
private
void
saveData
(
List
<
HGKC001
>
fCg004s
,
Map
<
String
,
HGKC001
>
dbCg004Map
)
{
private
void
saveData
(
List
<
HGKC001
>
fCg004s
,
Map
<
String
,
HGKC001
>
dbCg004Map
)
{
for
(
HGKC001
fCg004
:
fCg004s
)
{
for
(
HGKC001
fCg004
:
fCg004s
)
{
String
depositNo
=
fCg004
.
getDepositNo
(
);
DaoUtils
.
update
(
HGKC001
.
UPDATE_WH_CODE
,
fCg004
);
}
}
}
}
...
@@ -179,4 +179,46 @@ public class ServiceHGKC001 extends ServiceBase {
...
@@ -179,4 +179,46 @@ public class ServiceHGKC001 extends ServiceBase {
}
}
}
}
/**
* 修改提交状态
* @param inInfo
* @return
*/
public
EiInfo
updateSubmitStatus
(
EiInfo
inInfo
){
int
i
=
0
;
try
{
HGKC001
hgkc001
=
new
HGKC001
();
EiBlock
eiBlock
=
inInfo
.
getBlock
(
EiConstant
.
resultBlock
);
for
(
i
=
0
;
i
<
eiBlock
.
getRowCount
();
i
++)
{
Map
<?,
?>
map
=
eiBlock
.
getRow
(
i
);
hgkc001
.
fromMap
(
map
);
hgkc001
=
HGKCTools
.
HgKc001
.
getId
(
hgkc001
.
getId
());
hgkc001
.
setSubmitStatus
(
HGConstant
.
ProductStatus
.
YTJ
);
// 校验数据
this
.
checkSubmitData
(
hgkc001
);
DaoUtils
.
update
(
HGKC001
.
UPDATE_SUBMIT_STATUS
,
hgkc001
);
// 更新库存数量
HGKCUtils
.
HgKc010
.
updateInv
(
hgkc001
.
getCompanyCode
(),
hgkc001
.
getWhCode
(),
hgkc001
.
getInventCode
(),
hgkc001
.
getDepositQty
(),
hgkc001
.
getDepositUnitWeight
(),
hgkc001
.
getDepositWeight
());
// 更新收货单状态
HGCGTools
.
HgCg003
.
updateStatus
(
hgkc001
.
getReceiveNo
(),
HGConstant
.
CgReceiveStatus
.
S_5
);
}
inInfo
.
setStatus
(
EiConstant
.
STATUS_SUCCESS
);
inInfo
.
setMsgByKey
(
"ep.1000"
,
new
String
[]{
String
.
valueOf
(
i
),
I18nMessages
.
getText
(
"label.update"
,
"提交"
)});
}
catch
(
PlatException
e
)
{
e
.
printStackTrace
();
inInfo
.
setStatus
(
EiConstant
.
STATUS_FAILURE
);
ErrorCodeUtils
.
handleUpdateException
(
inInfo
,
i
,
e
);
logError
(
"修改失败"
,
e
.
getMessage
());
return
inInfo
;
}
return
inInfo
;
}
private
void
checkSubmitData
(
HGKC001
hgkc001
)
{
AssertUtils
.
isEmpty
(
hgkc001
.
getWhCode
(),
"仓库编码不能为空!"
);
AssertUtils
.
isEmpty
(
hgkc001
.
getWhName
(),
"仓库名称不能为空!"
);
}
}
}
src/main/java/com/baosight/hggp/hg/kc/sql/HGKC001.xml
View file @
e3fc65ee
...
@@ -34,7 +34,10 @@
...
@@ -34,7 +34,10 @@
THICK as "thick",
<!-- 厚度 -->
THICK as "thick",
<!-- 厚度 -->
DEPOSIT_QTY as "depositQty",
<!-- 入库数量 -->
DEPOSIT_QTY as "depositQty",
<!-- 入库数量 -->
DEPOSIT_UNIT_WEIGHT as "depositUnitWeight",
<!-- 入库单重 -->
DEPOSIT_UNIT_WEIGHT as "depositUnitWeight",
<!-- 入库单重 -->
DEPOSIT_WEIGHT as "depositWeight"
<!-- 入库重量 -->
DEPOSIT_WEIGHT as "depositWeight",
<!-- 入库重量 -->
STORAGE_TYPE as "storageType",
<!-- 入库类型:1:入库 2:退回 -->
IS_RETURN as "isReturn",
<!-- 是否退回:0:否 1:是 -->
SUBMIT_STATUS as "submitStatus"
<!-- 提交状态 -->
</sql>
</sql>
<sql
id=
"condition"
>
<sql
id=
"condition"
>
...
@@ -93,6 +96,15 @@
...
@@ -93,6 +96,15 @@
<isNotEmpty
prepend=
" AND "
property=
"unit"
>
<isNotEmpty
prepend=
" AND "
property=
"unit"
>
UNIT = #unit#
UNIT = #unit#
</isNotEmpty>
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"submitStatus"
>
SUBMIT_STATUS = #submitStatus#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"isReturn"
>
IS_RETURN = #isReturn#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"storageType"
>
STORAGE_TYPE = #storageType#
</isNotEmpty>
</sql>
</sql>
<sql
id=
"idCondition"
>
<sql
id=
"idCondition"
>
...
@@ -173,13 +185,17 @@
...
@@ -173,13 +185,17 @@
THICK,
<!-- 厚度 -->
THICK,
<!-- 厚度 -->
DEPOSIT_QTY,
<!-- 入库数量 -->
DEPOSIT_QTY,
<!-- 入库数量 -->
DEPOSIT_UNIT_WEIGHT,
<!-- 入库单重 -->
DEPOSIT_UNIT_WEIGHT,
<!-- 入库单重 -->
DEPOSIT_WEIGHT
<!-- 入库重量 -->
DEPOSIT_WEIGHT,
<!-- 入库重量 -->
STORAGE_TYPE,
<!-- 入库类型:1:入库 2:退回 -->
IS_RETURN,
<!-- 是否退回:0:否 1:是 -->
SUBMIT_STATUS
) VALUES (
) VALUES (
#accountCode#, #depCode#, #createdBy#, #createdName#, #createdTime#,
#accountCode#, #depCode#, #createdBy#, #createdName#, #createdTime#,
#deleteFlag#, #companyCode#, #companyName#, #depositDate#, #depositNo#,
#deleteFlag#, #companyCode#, #companyName#, #depositDate#, #depositNo#,
#receiveNo#, #planNo#, #contractNo#, #whCode#, #whName#, #inventType#,
#receiveNo#, #planNo#, #contractNo#, #whCode#, #whName#, #inventType#,
#inventCode#, #inventName#, #specId#, #spec#, #material#,
#inventCode#, #inventName#, #specId#, #spec#, #material#,
#unit#, #length#, #width#, #thick#, #depositQty#, #depositUnitWeight#, #depositWeight#
#unit#, #length#, #width#, #thick#, #depositQty#, #depositUnitWeight#, #depositWeight#,
#storageType#, #isReturn#,#submitStatus#
)
)
</insert>
</insert>
...
@@ -199,6 +215,17 @@
...
@@ -199,6 +215,17 @@
<include
refid=
"idCondition"
/>
<include
refid=
"idCondition"
/>
</update>
</update>
<update
id=
"updateWhCode"
>
UPDATE ${hggpSchema}.HGKC001
SET
WH_CODE = #whCode#,
WH_NAME = #whName#,
UPDATED_BY = #updatedBy#,
UPDATED_NAME = #updatedName#,
UPDATED_TIME = #updatedTime#
WHERE DEPOSIT_NO = #depositNo#
</update>
<!-- 统计库存 -->
<!-- 统计库存 -->
<select
id=
"statDate"
resultClass=
"com.baosight.hggp.hg.kc.domain.HGKC001"
>
<select
id=
"statDate"
resultClass=
"com.baosight.hggp.hg.kc.domain.HGKC001"
>
SELECT
SELECT
...
@@ -218,4 +245,15 @@
...
@@ -218,4 +245,15 @@
GROUP BY COMPANY_CODE, DEP_CODE, WH_CODE, INVENT_TYPE, INVENT_CODE,SPEC_ID
GROUP BY COMPANY_CODE, DEP_CODE, WH_CODE, INVENT_TYPE, INVENT_CODE,SPEC_ID
</select>
</select>
<update
id=
"updateSubmitStatus"
>
UPDATE ${hggpSchema}.HGKC001
SET
UPDATED_BY = #updatedBy#,
<!-- 更新人 -->
UPDATED_NAME = #updatedName#,
<!-- 更新人名称 -->
UPDATED_TIME = #updatedTime#,
<!-- 更新时间 -->
SUBMIT_STATUS = #submitStatus#
<!-- 提交状态 -->
WHERE
ID = #id#
</update>
</sqlMap>
</sqlMap>
src/main/java/com/baosight/hggp/hg/kc/tools/HGKCTools.java
View file @
e3fc65ee
...
@@ -6,6 +6,8 @@ import com.baosight.hggp.core.constant.CommonConstant;
...
@@ -6,6 +6,8 @@ import com.baosight.hggp.core.constant.CommonConstant;
import
com.baosight.hggp.core.dao.DaoBase
;
import
com.baosight.hggp.core.dao.DaoBase
;
import
com.baosight.hggp.core.dao.DaoUtils
;
import
com.baosight.hggp.core.dao.DaoUtils
;
import
com.baosight.hggp.core.enums.DeleteFlagEnum
;
import
com.baosight.hggp.core.enums.DeleteFlagEnum
;
import
com.baosight.hggp.hg.cg.domain.HGCG003
;
import
com.baosight.hggp.hg.cg.utils.HGCGUtils
;
import
com.baosight.hggp.hg.constant.HGConstant
;
import
com.baosight.hggp.hg.constant.HGConstant
;
import
com.baosight.hggp.hg.constant.HGSqlConstant
;
import
com.baosight.hggp.hg.constant.HGSqlConstant
;
import
com.baosight.hggp.hg.kc.domain.*
;
import
com.baosight.hggp.hg.kc.domain.*
;
...
@@ -14,6 +16,7 @@ import com.baosight.hggp.hg.pz.tools.HGPZTools;
...
@@ -14,6 +16,7 @@ import com.baosight.hggp.hg.pz.tools.HGPZTools;
import
com.baosight.hggp.hg.zl.domain.HGZL002
;
import
com.baosight.hggp.hg.zl.domain.HGZL002
;
import
com.baosight.hggp.hg.zl.domain.HGZL004
;
import
com.baosight.hggp.hg.zl.domain.HGZL004
;
import
com.baosight.hggp.util.AssertUtils
;
import
com.baosight.hggp.util.AssertUtils
;
import
com.baosight.hggp.util.BeanUtils
;
import
com.baosight.hggp.util.DateUtils
;
import
com.baosight.hggp.util.DateUtils
;
import
com.baosight.hggp.util.StringUtils
;
import
com.baosight.hggp.util.StringUtils
;
import
com.baosight.iplat4j.core.ei.EiConstant
;
import
com.baosight.iplat4j.core.ei.EiConstant
;
...
@@ -42,6 +45,21 @@ public class HGKCTools {
...
@@ -42,6 +45,21 @@ public class HGKCTools {
public
static
class
HgKc001
{
public
static
class
HgKc001
{
/**
/**
* 生产入库单信息
*
* @param id
* @return
*/
public
static
HGKC001
getId
(
Long
id
)
{
AssertUtils
.
isEmpty
(
Collections
.
singleton
(
id
),
"采购入库单为空!"
);
Map
<
String
,
Object
>
paramMap
=
new
HashMap
();
paramMap
.
put
(
"id"
,
id
);
paramMap
.
put
(
"deleteFlag"
,
0
);
List
<
HGKC001
>
list
=
DaoBase
.
getInstance
().
query
(
HGKC001
.
QUERY
,
paramMap
);
AssertUtils
.
isEmpty
(
list
,
"采购入库单为空!"
);
return
list
.
get
(
0
);
}
/**
* 锁
* 锁
*
*
* @param depositNos
* @param depositNos
...
@@ -80,6 +98,35 @@ public class HGKCTools {
...
@@ -80,6 +98,35 @@ public class HGKCTools {
return
results
.
stream
().
collect
(
Collectors
.
toMap
(
HGKC001:
:
getDepositNo
,
item
->
item
));
return
results
.
stream
().
collect
(
Collectors
.
toMap
(
HGKC001:
:
getDepositNo
,
item
->
item
));
}
}
/**
* 生产入库(入库质检单)
* @param receiveNo
*/
public
static
void
putInStorageData
(
String
receiveNo
)
{
List
<
String
>
receiveNoList
=
new
LinkedList
<>();
receiveNoList
.
add
(
receiveNo
);
// db数据
Map
<
String
,
HGCG003
>
dbCg003Map
=
HGCGUtils
.
HgCg003
.
lockGetData
(
receiveNoList
);
HGCG003
dbCg003
=
dbCg003Map
.
get
(
receiveNo
);
HGKC001
newKc001
=
BeanUtils
.
copy
(
dbCg003
,
HGKC001
.
class
);
newKc001
.
setDepositDate
(
DateUtils
.
shortDate
());
newKc001
.
setDepositNo
(
SequenceGenerator
.
getNextSequence
(
HGConstant
.
SequenceId
.
CG_DEPOSIT_NO
));
newKc001
.
setDepositQty
(
dbCg003
.
getDepositQty
());
newKc001
.
setDepositUnitWeight
(
dbCg003
.
getReceiveUnitWeight
());
newKc001
.
setDepositWeight
(
dbCg003
.
getDepositQty
().
multiply
(
dbCg003
.
getReceiveUnitWeight
()));
newKc001
.
setDeleteFlag
(
DeleteFlagEnum
.
UN_REMOVE
.
getCode
());
newKc001
.
setSpecId
(
dbCg003
.
getSpecId
());
newKc001
.
setSubmitStatus
(
HGConstant
.
ProductStatus
.
WTJ
);
newKc001
.
setStorageType
(
HGConstant
.
StorageType
.
RK
);
newKc001
.
setIsReturn
(
CommonConstant
.
YesNo
.
NO_0
);
DaoUtils
.
insert
(
HGKC001
.
INSERT
,
newKc001
);
// 更新库存数量
// HGKCUtils.HgKc010.updateInv(newKc001.getCompanyCode(), newKc001.getWhCode(), newKc001.getInventCode(),
// newKc001.getDepositQty(), newKc001.getDepositUnitWeight(), newKc001.getDepositWeight());
// 更新收货单状态
// HGCGTools.HgCg003.updateStatus(receiveNo, HGConstant.CgReceiveStatus.S_5);
}
}
}
/**
/**
...
@@ -700,7 +747,7 @@ public class HGKCTools {
...
@@ -700,7 +747,7 @@ public class HGKCTools {
*
*
* @param companyCode
* @param companyCode
* @param whCode
* @param whCode
* @param
specId
* @param
inventCode
* @return
* @return
*/
*/
public
static
void
lock
(
String
companyCode
,
String
whCode
,
String
inventCode
)
{
public
static
void
lock
(
String
companyCode
,
String
whCode
,
String
inventCode
)
{
...
...
src/main/java/com/baosight/hggp/hg/zl/service/ServiceHGZL001.java
View file @
e3fc65ee
...
@@ -7,6 +7,7 @@ import com.baosight.hggp.core.dao.DaoUtils;
...
@@ -7,6 +7,7 @@ import com.baosight.hggp.core.dao.DaoUtils;
import
com.baosight.hggp.core.enums.DeleteFlagEnum
;
import
com.baosight.hggp.core.enums.DeleteFlagEnum
;
import
com.baosight.hggp.hg.cg.tools.HGCGTools
;
import
com.baosight.hggp.hg.cg.tools.HGCGTools
;
import
com.baosight.hggp.hg.constant.HGSqlConstant
;
import
com.baosight.hggp.hg.constant.HGSqlConstant
;
import
com.baosight.hggp.hg.kc.tools.HGKCTools
;
import
com.baosight.hggp.hg.zl.domain.HGZL001
;
import
com.baosight.hggp.hg.zl.domain.HGZL001
;
import
com.baosight.hggp.hg.zl.utils.HGZLUtils
;
import
com.baosight.hggp.hg.zl.utils.HGZLUtils
;
import
com.baosight.hggp.util.AssertUtils
;
import
com.baosight.hggp.util.AssertUtils
;
...
@@ -27,7 +28,7 @@ import java.util.Map;
...
@@ -27,7 +28,7 @@ import java.util.Map;
* @date 2024年01月09日 10:18
* @date 2024年01月09日 10:18
*/
*/
public
class
ServiceHGZL001
extends
ServiceBase
{
public
class
ServiceHGZL001
extends
ServiceBase
{
/**
/**
* 画面初始化
* 画面初始化
*
*
...
@@ -47,7 +48,7 @@ public class ServiceHGZL001 extends ServiceBase {
...
@@ -47,7 +48,7 @@ public class ServiceHGZL001 extends ServiceBase {
}
}
return
inInfo
;
return
inInfo
;
}
}
/**
/**
* 查询操作
* 查询操作
*
*
...
@@ -66,7 +67,7 @@ public class ServiceHGZL001 extends ServiceBase {
...
@@ -66,7 +67,7 @@ public class ServiceHGZL001 extends ServiceBase {
}
}
return
inInfo
;
return
inInfo
;
}
}
/**
/**
* 新增操作
* 新增操作
*
*
...
@@ -98,7 +99,7 @@ public class ServiceHGZL001 extends ServiceBase {
...
@@ -98,7 +99,7 @@ public class ServiceHGZL001 extends ServiceBase {
}
}
return
inInfo
;
return
inInfo
;
}
}
/**
/**
* 修改操作
* 修改操作
*
*
...
@@ -128,7 +129,7 @@ public class ServiceHGZL001 extends ServiceBase {
...
@@ -128,7 +129,7 @@ public class ServiceHGZL001 extends ServiceBase {
}
}
return
inInfo
;
return
inInfo
;
}
}
/**
/**
* 设置基础信息
* 设置基础信息
*
*
...
@@ -147,7 +148,7 @@ public class ServiceHGZL001 extends ServiceBase {
...
@@ -147,7 +148,7 @@ public class ServiceHGZL001 extends ServiceBase {
// fZl001.setCheckUser(UserSession.getLoginName());
// fZl001.setCheckUser(UserSession.getLoginName());
// fZl001.setCheckUserName(UserSession.getLoginCName());
// fZl001.setCheckUserName(UserSession.getLoginCName());
}
}
/**
/**
* 删除操作
* 删除操作
*
*
...
@@ -175,7 +176,7 @@ public class ServiceHGZL001 extends ServiceBase {
...
@@ -175,7 +176,7 @@ public class ServiceHGZL001 extends ServiceBase {
}
}
return
inInfo
;
return
inInfo
;
}
}
/**
/**
* 已处理
* 已处理
*
*
...
@@ -199,7 +200,7 @@ public class ServiceHGZL001 extends ServiceBase {
...
@@ -199,7 +200,7 @@ public class ServiceHGZL001 extends ServiceBase {
}
}
return
inInfo
;
return
inInfo
;
}
}
/**
/**
* 校验数据
* 校验数据
*
*
...
@@ -216,7 +217,7 @@ public class ServiceHGZL001 extends ServiceBase {
...
@@ -216,7 +217,7 @@ public class ServiceHGZL001 extends ServiceBase {
String
.
format
(
"质检单[%s]的合格数量加不合格数量必须等于收货数量"
,
checkNo
));
String
.
format
(
"质检单[%s]的合格数量加不合格数量必须等于收货数量"
,
checkNo
));
}
}
}
}
/**
/**
* 保存数据
* 保存数据
*
*
...
@@ -233,7 +234,9 @@ public class ServiceHGZL001 extends ServiceBase {
...
@@ -233,7 +234,9 @@ public class ServiceHGZL001 extends ServiceBase {
DaoUtils
.
update
(
HGSqlConstant
.
HgZl001
.
PROCESS
,
dbZl001
);
DaoUtils
.
update
(
HGSqlConstant
.
HgZl001
.
PROCESS
,
dbZl001
);
// 更新收货单状态
// 更新收货单状态
HGCGTools
.
HgCg003
.
updateCheck
(
dbZl001
);
HGCGTools
.
HgCg003
.
updateCheck
(
dbZl001
);
//生成采购入库单
HGKCTools
.
HgKc001
.
putInStorageData
(
dbZl001
.
getReceiveNo
());
}
}
}
}
}
}
src/main/webapp/HG/KC/HGKC001.js
View file @
e3fc65ee
...
@@ -7,7 +7,28 @@ $(function () {
...
@@ -7,7 +7,28 @@ $(function () {
pageSize
:
20
,
pageSize
:
20
,
pageSizes
:
[
20
,
50
,
70
,
100
],
pageSizes
:
[
20
,
50
,
70
,
100
],
},
},
columns
:
[],
columns
:
[
{
field
:
"operator"
,
title
:
"操作"
,
template
:
function
(
item
)
{
let
status
=
item
.
submitStatus
;
let
isReturn
=
item
.
isReturn
;
let
template
=
''
;
if
(
item
.
id
){
if
(
status
==
0
)
{
template
+=
'<a style="cursor: pointer;display: inline-flex;justify-content: center;margin:auto 5px" '
+
'onclick="updateSubmitStatus('
+
item
.
id
+
')" >提交</a>'
;
}
// if (status == 1 && isReturn == 0) {
// template += '<a style="cursor: pointer;display: inline-flex;justify-content: center;margin:auto 5px" '
// + 'onclick="sendBack(' + item.id + ')" >退回</a>';
// }
}
return
template
;
}
}
],
loadComplete
:
function
(
grid
)
{
loadComplete
:
function
(
grid
)
{
// 确认
// 确认
$
(
"#CONFIRM"
).
on
(
"click"
,
confirm
);
$
(
"#CONFIRM"
).
on
(
"click"
,
confirm
);
...
@@ -133,3 +154,40 @@ let selectReceiveCallback = function () {
...
@@ -133,3 +154,40 @@ let selectReceiveCallback = function () {
// 关闭弹窗
// 关闭弹窗
JSColorbox
.
close
();
JSColorbox
.
close
();
}
}
/**
* 提交
* @param id
* @param status
*/
function
updateSubmitStatus
(
id
)
{
let
inEiInfo
=
new
EiInfo
();
inEiInfo
.
set
(
"result-0-id"
,
id
);
JSUtils
.
confirm
(
"确定提交此采购入库单吗? "
,
{
ok
:
function
()
{
EiCommunicator
.
send
(
'HGKC001'
,
'updateSubmitStatus'
,
inEiInfo
,
{
onSuccess
:
function
(
ei
)
{
if
(
ei
.
getStatus
()
>=
0
)
{
try
{
query
();
}
catch
(
e
)
{
}
if
(
ei
.
getStatus
()
==
0
)
{
NotificationUtil
(
ei
,
'warning'
);
}
else
{
NotificationUtil
(
ei
);
}
}
else
{
NotificationUtil
(
ei
,
"error"
);
}
},
onFail
:
function
(
ei
)
{
// 发生异常
NotificationUtil
(
"操作失败,原因["
+
ei
+
"]"
,
"error"
);
}
}
);
}
});
}
src/main/webapp/HG/KC/HGKC001.jsp
View file @
e3fc65ee
...
@@ -46,13 +46,14 @@
...
@@ -46,13 +46,14 @@
<EF:EFRegion
id=
"result"
title=
"明细信息"
>
<EF:EFRegion
id=
"result"
title=
"明细信息"
>
<EF:EFGrid
blockId=
"result"
autoDraw=
"override"
isFloat=
"true"
checkMode=
"row"
>
<EF:EFGrid
blockId=
"result"
autoDraw=
"override"
isFloat=
"true"
checkMode=
"row"
>
<EF:EFColumn
ename=
"id"
cname=
"内码"
hidden=
"true"
/>
<EF:EFColumn
ename=
"id"
cname=
"内码"
hidden=
"true"
/>
<EF:EFColumn
ename=
"operator"
cname=
"操作"
locked=
"true"
width=
"80"
enable=
"false"
align=
"center"
readonly=
"false"
/>
<EF:EFColumn
ename=
"companyCode"
cname=
"公司编码"
enable=
"false"
width=
"100"
align=
"center"
hidden=
"true"
/>
<EF:EFColumn
ename=
"companyCode"
cname=
"公司编码"
enable=
"false"
width=
"100"
align=
"center"
hidden=
"true"
/>
<EF:EFColumn
ename=
"companyName"
cname=
"公司名称"
enable=
"false"
width=
"130"
align=
"center"
/>
<EF:EFColumn
ename=
"companyName"
cname=
"公司名称"
enable=
"false"
width=
"130"
align=
"center"
/>
<EF:EFColumn
ename=
"depositDate"
cname=
"入库日期"
enable=
"false"
width=
"100"
align=
"center"
editType=
"date"
<EF:EFColumn
ename=
"depositDate"
cname=
"入库日期"
enable=
"false"
width=
"100"
align=
"center"
editType=
"date"
dateFormat=
"yyyy-MM-dd"
parseFormats=
"['yyyyMMdd']"
/>
dateFormat=
"yyyy-MM-dd"
parseFormats=
"['yyyyMMdd']"
/>
<EF:EFColumn
ename=
"depositNo"
cname=
"入库单号"
enable=
"false"
width=
"120"
align=
"center"
/>
<EF:EFColumn
ename=
"depositNo"
cname=
"入库单号"
enable=
"false"
width=
"120"
align=
"center"
/>
<EF:EFColumn
ename=
"receiveNo"
cname=
"收货单号"
enable=
"false"
width=
"120"
align=
"center"
/>
<EF:EFColumn
ename=
"receiveNo"
cname=
"收货单号"
enable=
"false"
width=
"120"
align=
"center"
/>
<EF:EFComboColumn
ename=
"whCode"
cname=
"仓库名称"
enable=
"
fals
e"
width=
"120"
align=
"left"
defaultValue=
""
<EF:EFComboColumn
ename=
"whCode"
cname=
"仓库名称"
enable=
"
tru
e"
width=
"120"
align=
"left"
defaultValue=
""
filter=
"contains"
required=
"true"
>
filter=
"contains"
required=
"true"
>
<EF:EFOptions
blockId=
"wh_record_block_id"
valueField=
"valueField"
textField=
"textField"
/>
<EF:EFOptions
blockId=
"wh_record_block_id"
valueField=
"valueField"
textField=
"textField"
/>
</EF:EFComboColumn>
</EF:EFComboColumn>
...
@@ -71,6 +72,9 @@
...
@@ -71,6 +72,9 @@
<EF:EFColumn
ename=
"createdName"
cname=
"创建人"
enable=
"false"
width=
"100"
align=
"center"
/>
<EF:EFColumn
ename=
"createdName"
cname=
"创建人"
enable=
"false"
width=
"100"
align=
"center"
/>
<EF:EFColumn
ename=
"createdTime"
cname=
"创建时间"
enable=
"false"
width=
"140"
align=
"center"
<EF:EFColumn
ename=
"createdTime"
cname=
"创建时间"
enable=
"false"
width=
"140"
align=
"center"
editType=
"datetime"
parseFormats=
"['yyyyMMddHHmmss']"
/>
editType=
"datetime"
parseFormats=
"['yyyyMMddHHmmss']"
/>
<EF:EFComboColumn
cname=
"提交状态"
ename=
"submitStatus"
width=
"90"
align=
"center"
required=
"false"
>
<EF:EFCodeOption
codeName=
"hggp.sc.productStatus"
/>
</EF:EFComboColumn>
</EF:EFGrid>
</EF:EFGrid>
</EF:EFRegion>
</EF:EFRegion>
<EF:EFRegion
title=
"提示"
>
<EF:EFRegion
title=
"提示"
>
...
...
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