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
4853573f
Commit
4853573f
authored
May 23, 2024
by
wuwenlong
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
bugfix;
parent
c52075a2
Hide whitespace changes
Inline
Side-by-side
Showing
18 changed files
with
2837 additions
and
222 deletions
+2837
-222
HGConstant.java
src/main/java/com/baosight/hggp/hg/constant/HGConstant.java
+2
-0
HGSqlConstant.java
...ain/java/com/baosight/hggp/hg/constant/HGSqlConstant.java
+7
-6
HGSC005A.java
src/main/java/com/baosight/hggp/hg/sc/domain/HGSC005A.java
+153
-25
HGSC006.java
src/main/java/com/baosight/hggp/hg/sc/domain/HGSC006.java
+1
-0
HGSC006A.java
src/main/java/com/baosight/hggp/hg/sc/domain/HGSC006A.java
+148
-30
HGSC007.java
src/main/java/com/baosight/hggp/hg/sc/domain/HGSC007.java
+1110
-0
ServiceHGSC001.java
.../java/com/baosight/hggp/hg/sc/service/ServiceHGSC001.java
+2
-0
ServiceHGSC006C.java
...java/com/baosight/hggp/hg/sc/service/ServiceHGSC006C.java
+207
-0
HGSC005A.xml
src/main/java/com/baosight/hggp/hg/sc/sql/HGSC005A.xml
+49
-7
HGSC006.xml
src/main/java/com/baosight/hggp/hg/sc/sql/HGSC006.xml
+18
-0
HGSC006A.xml
src/main/java/com/baosight/hggp/hg/sc/sql/HGSC006A.xml
+217
-104
HGSC007.xml
src/main/java/com/baosight/hggp/hg/sc/sql/HGSC007.xml
+476
-0
HGSCTools.java
src/main/java/com/baosight/hggp/hg/sc/tools/HGSCTools.java
+174
-2
HGSC001.js
src/main/webapp/HG/SC/HGSC001.js
+65
-45
HGSC002.js
src/main/webapp/HG/SC/HGSC002.js
+5
-3
HGSC006A.jsp
src/main/webapp/HG/SC/HGSC006A.jsp
+4
-0
HGSC006C.js
src/main/webapp/HG/SC/HGSC006C.js
+141
-0
HGSC006C.jsp
src/main/webapp/HG/SC/HGSC006C.jsp
+58
-0
No files found.
src/main/java/com/baosight/hggp/hg/constant/HGConstant.java
View file @
4853573f
...
...
@@ -69,6 +69,8 @@ public class HGConstant {
public
static
final
String
HGSC005_PLAN_CODE
=
"HGSC005_PLAN_CODE"
;
//生产订单
public
static
final
String
HGSC006_ORDER_CODE
=
"HGSC006_ORDER_CODE"
;
//生产任务
public
static
final
String
HGSC007_TASCK_CODE
=
"HGSC007_TASCK_CODE"
;
//生产任务订单
public
static
final
String
PROD_TASK_NO
=
"PROD_TASK_NO"
;
//售后维修单号
...
...
src/main/java/com/baosight/hggp/hg/constant/HGSqlConstant.java
View file @
4853573f
...
...
@@ -503,17 +503,18 @@ public class HGSqlConstant {
* @author:songx
* @date:2024/2/5,10:16
*/
public
class
H
PSC005
{
public
class
H
GSC006A
{
// 锁
public
static
final
String
LOCK
=
"HPSC005.lock"
;
// 查询
public
static
final
String
UPDATE_ASSIGN_NUM
=
"HPSC005.updateAssignNum"
;
public
static
final
String
LOCK
=
"HGSC006A.lock"
;
}
public
static
final
String
DELETE_BY_MAT
=
"HPSC005.deleteByMat"
;
public
class
HGSC007
{
// 锁
public
static
final
String
LOCK
=
"HGSC007.lock"
;
}
/**
* @author:songx
* @date:2024/2/5,10:16
...
...
src/main/java/com/baosight/hggp/hg/sc/domain/HGSC005A.java
View file @
4853573f
...
...
@@ -3,6 +3,8 @@ package com.baosight.hggp.hg.sc.domain;
import
com.baosight.iplat4j.core.util.NumberUtils
;
import
com.baosight.iplat4j.core.ei.EiColumn
;
import
com.baosight.iplat4j.core.data.DaoEPBase
;
import
java.math.BigDecimal
;
import
java.util.HashMap
;
import
java.util.Map
;
import
com.baosight.iplat4j.core.util.StringUtils
;
...
...
@@ -19,7 +21,7 @@ import com.baosight.iplat4j.core.util.StringUtils;
*/
public
class
HGSC005A
extends
DaoEPBase
{
private
static
final
long
serialVersionUID
=
1L
;
private
static
final
long
serialVersionUID
=
1L
;
public
static
final
String
FIELD_id
=
"id"
;
public
static
final
String
FIELD_mat_id
=
"matId"
;
/* 物料清单ID*/
...
...
@@ -27,10 +29,10 @@ public class HGSC005A extends DaoEPBase {
public
static
final
String
FIELD_tech_flow_id
=
"techFlowId"
;
/* 工艺流程ID*/
public
static
final
String
FIELD_tech_flow_name
=
"techFlowName"
;
/* 工艺流程名称*/
public
static
final
String
FIELD_invent_process_id
=
"inventProcessId"
;
/* 存货工序ID,对应HGPZ005A.id*/
public
static
final
String
FIELD_process_code
=
"processCode"
;
/* 工序
名称
*/
public
static
final
String
FIELD_process_code
=
"processCode"
;
/* 工序
编码
*/
public
static
final
String
FIELD_process_name
=
"processName"
;
/* 工序名称*/
public
static
final
String
FIELD_process_order
=
"processOrder"
;
/* 加工顺序*/
public
static
final
String
FIELD_company_code
=
"companyCode"
;
/* 公司编码*/
public
static
final
String
FIELD_process_order
=
"processOrder"
;
/* 加工顺序*/
public
static
final
String
FIELD_company_name
=
"companyName"
;
/* 公司名称*/
public
static
final
String
FIELD_dep_code
=
"depCode"
;
/* 部门编码*/
public
static
final
String
FIELD_dep_name
=
"depName"
;
/* 部门名称*/
...
...
@@ -46,6 +48,10 @@ public class HGSC005A extends DaoEPBase {
public
static
final
String
FIELD_quantity
=
"quantity"
;
/* 数量*/
public
static
final
String
FIELD_finish_quantity
=
"finishQuantity"
;
/* 完工数量*/
public
static
final
String
FIELD_unfinish_quantity
=
"unfinishQuantity"
;
/* 未完工数量*/
public
static
final
String
FIELD_single_weight
=
"singleWeight"
;
/* 单重*/
public
static
final
String
FIELD_total_weight
=
"totalWeight"
;
/* 总重*/
public
static
final
String
FIELD_finish_weight
=
"finishWeight"
;
/* 完工重量*/
public
static
final
String
FIELD_unfinish_weight
=
"unfinishWeight"
;
/* 未完工重量*/
public
static
final
String
FIELD_account_code
=
"accountCode"
;
/* 帐套*/
public
static
final
String
FIELD_created_by
=
"createdBy"
;
/* 创建人*/
public
static
final
String
FIELD_created_name
=
"createdName"
;
/* 创建人名称*/
...
...
@@ -60,10 +66,10 @@ public class HGSC005A extends DaoEPBase {
public
static
final
String
COL_tech_flow_id
=
"tech_flow_id"
;
/* 工艺流程ID*/
public
static
final
String
COL_tech_flow_name
=
"tech_flow_name"
;
/* 工艺流程名称*/
public
static
final
String
COL_invent_process_id
=
"invent_process_id"
;
/* 存货工序ID,对应HGPZ005A.id*/
public
static
final
String
COL_process_code
=
"process_code"
;
/* 工序
名称
*/
public
static
final
String
COL_process_code
=
"process_code"
;
/* 工序
编码
*/
public
static
final
String
COL_process_name
=
"process_name"
;
/* 工序名称*/
public
static
final
String
COL_process_order
=
"processOrder"
;
/* 加工顺序*/
public
static
final
String
COL_company_code
=
"company_code"
;
/* 公司编码*/
public
static
final
String
COL_process_order
=
"process_order"
;
/* 加工顺序*/
public
static
final
String
COL_company_name
=
"company_name"
;
/* 公司名称*/
public
static
final
String
COL_dep_code
=
"dep_code"
;
/* 部门编码*/
public
static
final
String
COL_dep_name
=
"dep_name"
;
/* 部门名称*/
...
...
@@ -79,6 +85,10 @@ public class HGSC005A extends DaoEPBase {
public
static
final
String
COL_quantity
=
"quantity"
;
/* 数量*/
public
static
final
String
COL_finish_quantity
=
"finish_quantity"
;
/* 完工数量*/
public
static
final
String
COL_unfinish_quantity
=
"unfinish_quantity"
;
/* 未完工数量*/
public
static
final
String
COL_single_weight
=
"single_weight"
;
/* 单重*/
public
static
final
String
COL_total_weight
=
"total_weight"
;
/* 总重*/
public
static
final
String
COL_finish_weight
=
"finish_weight"
;
/* 完工重量*/
public
static
final
String
COL_unfinish_weight
=
"unfinish_weight"
;
/* 未完工重量*/
public
static
final
String
COL_account_code
=
"account_code"
;
/* 帐套*/
public
static
final
String
COL_created_by
=
"created_by"
;
/* 创建人*/
public
static
final
String
COL_created_name
=
"created_name"
;
/* 创建人名称*/
...
...
@@ -100,10 +110,10 @@ public class HGSC005A extends DaoEPBase {
private
Long
techFlowId
=
new
Long
(
0
);
/* 工艺流程ID*/
private
Long
techFlowName
=
new
Long
(
0
);
/* 工艺流程名称*/
private
Long
inventProcessId
=
new
Long
(
0
);
/* 存货工序ID,对应HGPZ005A.id*/
private
String
processCode
=
" "
;
/* 工序
名称
*/
private
String
processCode
=
" "
;
/* 工序
编码
*/
private
String
processName
=
" "
;
/* 工序名称*/
private
Long
processOrder
=
new
Long
(
0
);
private
String
companyCode
=
" "
;
/* 公司编码*/
private
Long
processOrder
=
new
Long
(
0
);
/* 加工顺序*/
private
String
companyName
=
" "
;
/* 公司名称*/
private
String
depCode
=
" "
;
/* 部门编码*/
private
String
depName
=
" "
;
/* 部门名称*/
...
...
@@ -119,6 +129,10 @@ public class HGSC005A extends DaoEPBase {
private
Integer
quantity
=
new
Integer
(
0
);
/* 数量*/
private
Integer
finishQuantity
=
new
Integer
(
0
);
/* 完工数量*/
private
Integer
unfinishQuantity
=
new
Integer
(
0
);
/* 未完工数量*/
private
BigDecimal
singleWeight
=
new
BigDecimal
(
"0"
);
/* 单重*/
private
BigDecimal
totalWeight
=
new
BigDecimal
(
"0"
);
/* 总重*/
private
BigDecimal
finishWeight
=
new
BigDecimal
(
"0"
);
/* 完工重量*/
private
BigDecimal
unfinishWeight
=
new
BigDecimal
(
"0"
);
/* 未完工重量*/
private
String
accountCode
=
" "
;
/* 帐套*/
private
String
createdBy
=
" "
;
/* 创建人*/
private
String
createdName
=
" "
;
/* 创建人名称*/
...
...
@@ -166,14 +180,14 @@ public class HGSC005A extends DaoEPBase {
eiColumn
.
setDescName
(
"工序名称"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_process_order
);
eiColumn
.
setDescName
(
"加工顺序"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_company_code
);
eiColumn
.
setDescName
(
"公司编码"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_process_order
);
eiColumn
.
setDescName
(
"加工顺序"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_company_name
);
eiColumn
.
setDescName
(
"公司名称"
);
eiMetadata
.
addMeta
(
eiColumn
);
...
...
@@ -234,6 +248,34 @@ public class HGSC005A extends DaoEPBase {
eiColumn
.
setDescName
(
"未完工数量"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_single_weight
);
eiColumn
.
setType
(
"N"
);
eiColumn
.
setScaleLength
(
3
);
eiColumn
.
setFieldLength
(
20
);
eiColumn
.
setDescName
(
"单重"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_total_weight
);
eiColumn
.
setType
(
"N"
);
eiColumn
.
setScaleLength
(
3
);
eiColumn
.
setFieldLength
(
20
);
eiColumn
.
setDescName
(
"总重"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_finish_weight
);
eiColumn
.
setType
(
"N"
);
eiColumn
.
setScaleLength
(
3
);
eiColumn
.
setFieldLength
(
20
);
eiColumn
.
setDescName
(
"完工重量"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_unfinish_weight
);
eiColumn
.
setType
(
"N"
);
eiColumn
.
setScaleLength
(
3
);
eiColumn
.
setFieldLength
(
20
);
eiColumn
.
setDescName
(
"未完工重量"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_account_code
);
eiColumn
.
setDescName
(
"帐套"
);
eiMetadata
.
addMeta
(
eiColumn
);
...
...
@@ -368,15 +410,22 @@ public class HGSC005A extends DaoEPBase {
public
void
setInventProcessId
(
Long
inventProcessId
)
{
this
.
inventProcessId
=
inventProcessId
;
}
/**
* get the processCode - 工序编码.
* @return the processCode
*/
public
String
getProcessCode
()
{
return
processCode
;
return
this
.
processCode
;
}
/**
* set the processCode - 工序编码.
*
* @param processCode - 工序编码
*/
public
void
setProcessCode
(
String
processCode
)
{
this
.
processCode
=
processCode
;
}
/**
* get the processName - 工序名称.
* @return the processName
...
...
@@ -393,15 +442,6 @@ public class HGSC005A extends DaoEPBase {
public
void
setProcessName
(
String
processName
)
{
this
.
processName
=
processName
;
}
public
Long
getProcessOrder
()
{
return
processOrder
;
}
public
void
setProcessOrder
(
Long
processOrder
)
{
this
.
processOrder
=
processOrder
;
}
/**
* get the companyCode - 公司编码.
* @return the companyCode
...
...
@@ -419,6 +459,22 @@ public class HGSC005A extends DaoEPBase {
this
.
companyCode
=
companyCode
;
}
/**
* get the processOrder - 加工顺序.
* @return the processOrder
*/
public
Long
getProcessOrder
()
{
return
this
.
processOrder
;
}
/**
* set the processOrder - 加工顺序.
*
* @param processOrder - 加工顺序
*/
public
void
setProcessOrder
(
Long
processOrder
)
{
this
.
processOrder
=
processOrder
;
}
/**
* get the companyName - 公司名称.
* @return the companyName
*/
...
...
@@ -659,6 +715,70 @@ public class HGSC005A extends DaoEPBase {
this
.
unfinishQuantity
=
unfinishQuantity
;
}
/**
* get the singleWeight - 单重.
* @return the singleWeight
*/
public
BigDecimal
getSingleWeight
()
{
return
this
.
singleWeight
;
}
/**
* set the singleWeight - 单重.
*
* @param singleWeight - 单重
*/
public
void
setSingleWeight
(
BigDecimal
singleWeight
)
{
this
.
singleWeight
=
singleWeight
;
}
/**
* get the totalWeight - 总重.
* @return the totalWeight
*/
public
BigDecimal
getTotalWeight
()
{
return
this
.
totalWeight
;
}
/**
* set the totalWeight - 总重.
*
* @param totalWeight - 总重
*/
public
void
setTotalWeight
(
BigDecimal
totalWeight
)
{
this
.
totalWeight
=
totalWeight
;
}
/**
* get the finishWeight - 完工重量.
* @return the finishWeight
*/
public
BigDecimal
getFinishWeight
()
{
return
this
.
finishWeight
;
}
/**
* set the finishWeight - 完工重量.
*
* @param finishWeight - 完工重量
*/
public
void
setFinishWeight
(
BigDecimal
finishWeight
)
{
this
.
finishWeight
=
finishWeight
;
}
/**
* get the unfinishWeight - 未完工重量.
* @return the unfinishWeight
*/
public
BigDecimal
getUnfinishWeight
()
{
return
this
.
unfinishWeight
;
}
/**
* set the unfinishWeight - 未完工重量.
*
* @param unfinishWeight - 未完工重量
*/
public
void
setUnfinishWeight
(
BigDecimal
unfinishWeight
)
{
this
.
unfinishWeight
=
unfinishWeight
;
}
/**
* get the accountCode - 帐套.
* @return the accountCode
*/
...
...
@@ -786,8 +906,8 @@ public class HGSC005A extends DaoEPBase {
setInventProcessId
(
NumberUtils
.
toLong
(
StringUtils
.
toString
(
map
.
get
(
FIELD_invent_process_id
)),
inventProcessId
));
setProcessCode
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_process_code
)),
processCode
));
setProcessName
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_process_name
)),
processName
));
setProcessOrder
(
NumberUtils
.
toLong
(
StringUtils
.
toString
(
map
.
get
(
FIELD_process_order
)),
processOrder
));
setCompanyCode
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_company_code
)),
companyCode
));
setProcessOrder
(
NumberUtils
.
toLong
(
StringUtils
.
toString
(
map
.
get
(
FIELD_process_order
)),
processOrder
));
setCompanyName
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_company_name
)),
companyName
));
setDepCode
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_dep_code
)),
depCode
));
setDepName
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_dep_name
)),
depName
));
...
...
@@ -803,6 +923,10 @@ public class HGSC005A extends DaoEPBase {
setQuantity
(
NumberUtils
.
toInteger
(
StringUtils
.
toString
(
map
.
get
(
FIELD_quantity
)),
quantity
));
setFinishQuantity
(
NumberUtils
.
toInteger
(
StringUtils
.
toString
(
map
.
get
(
FIELD_finish_quantity
)),
finishQuantity
));
setUnfinishQuantity
(
NumberUtils
.
toInteger
(
StringUtils
.
toString
(
map
.
get
(
FIELD_unfinish_quantity
)),
unfinishQuantity
));
setSingleWeight
(
NumberUtils
.
toBigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_single_weight
)),
singleWeight
));
setTotalWeight
(
NumberUtils
.
toBigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_total_weight
)),
totalWeight
));
setFinishWeight
(
NumberUtils
.
toBigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_finish_weight
)),
finishWeight
));
setUnfinishWeight
(
NumberUtils
.
toBigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_unfinish_weight
)),
unfinishWeight
));
setAccountCode
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_account_code
)),
accountCode
));
setCreatedBy
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_created_by
)),
createdBy
));
setCreatedName
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_created_name
)),
createdName
));
...
...
@@ -827,8 +951,8 @@ public class HGSC005A extends DaoEPBase {
map
.
put
(
FIELD_invent_process_id
,
StringUtils
.
toString
(
inventProcessId
,
eiMetadata
.
getMeta
(
FIELD_invent_process_id
)));
map
.
put
(
FIELD_process_code
,
StringUtils
.
toString
(
processCode
,
eiMetadata
.
getMeta
(
FIELD_process_code
)));
map
.
put
(
FIELD_process_name
,
StringUtils
.
toString
(
processName
,
eiMetadata
.
getMeta
(
FIELD_process_name
)));
map
.
put
(
FIELD_process_order
,
StringUtils
.
toString
(
id
,
eiMetadata
.
getMeta
(
FIELD_process_order
)));
map
.
put
(
FIELD_company_code
,
StringUtils
.
toString
(
companyCode
,
eiMetadata
.
getMeta
(
FIELD_company_code
)));
map
.
put
(
FIELD_process_order
,
StringUtils
.
toString
(
processOrder
,
eiMetadata
.
getMeta
(
FIELD_process_order
)));
map
.
put
(
FIELD_company_name
,
StringUtils
.
toString
(
companyName
,
eiMetadata
.
getMeta
(
FIELD_company_name
)));
map
.
put
(
FIELD_dep_code
,
StringUtils
.
toString
(
depCode
,
eiMetadata
.
getMeta
(
FIELD_dep_code
)));
map
.
put
(
FIELD_dep_name
,
StringUtils
.
toString
(
depName
,
eiMetadata
.
getMeta
(
FIELD_dep_name
)));
...
...
@@ -844,6 +968,10 @@ public class HGSC005A extends DaoEPBase {
map
.
put
(
FIELD_quantity
,
StringUtils
.
toString
(
quantity
,
eiMetadata
.
getMeta
(
FIELD_quantity
)));
map
.
put
(
FIELD_finish_quantity
,
StringUtils
.
toString
(
finishQuantity
,
eiMetadata
.
getMeta
(
FIELD_finish_quantity
)));
map
.
put
(
FIELD_unfinish_quantity
,
StringUtils
.
toString
(
unfinishQuantity
,
eiMetadata
.
getMeta
(
FIELD_unfinish_quantity
)));
map
.
put
(
FIELD_single_weight
,
StringUtils
.
toString
(
singleWeight
,
eiMetadata
.
getMeta
(
FIELD_single_weight
)));
map
.
put
(
FIELD_total_weight
,
StringUtils
.
toString
(
totalWeight
,
eiMetadata
.
getMeta
(
FIELD_total_weight
)));
map
.
put
(
FIELD_finish_weight
,
StringUtils
.
toString
(
finishWeight
,
eiMetadata
.
getMeta
(
FIELD_finish_weight
)));
map
.
put
(
FIELD_unfinish_weight
,
StringUtils
.
toString
(
unfinishWeight
,
eiMetadata
.
getMeta
(
FIELD_unfinish_weight
)));
map
.
put
(
FIELD_account_code
,
StringUtils
.
toString
(
accountCode
,
eiMetadata
.
getMeta
(
FIELD_account_code
)));
map
.
put
(
FIELD_created_by
,
StringUtils
.
toString
(
createdBy
,
eiMetadata
.
getMeta
(
FIELD_created_by
)));
map
.
put
(
FIELD_created_name
,
StringUtils
.
toString
(
createdName
,
eiMetadata
.
getMeta
(
FIELD_created_name
)));
...
...
src/main/java/com/baosight/hggp/hg/sc/domain/HGSC006.java
View file @
4853573f
...
...
@@ -65,6 +65,7 @@ public class HGSC006 extends DaoEPBase {
public
static
final
String
INSERT
=
"HGSC006.insert"
;
public
static
final
String
UPDATE
=
"HGSC006.update"
;
public
static
final
String
DELETE
=
"HGSC006.delete"
;
public
static
final
String
UPDATE_ASSIGN_STATUS
=
"HGSC006.update_assign_status"
;
private
Long
id
=
new
Long
(
0
);
private
Long
matId
=
new
Long
(
0
);
/* 物料清单ID*/
...
...
src/main/java/com/baosight/hggp/hg/sc/domain/HGSC006A.java
View file @
4853573f
...
...
@@ -3,6 +3,8 @@ package com.baosight.hggp.hg.sc.domain;
import
com.baosight.iplat4j.core.util.NumberUtils
;
import
com.baosight.iplat4j.core.ei.EiColumn
;
import
com.baosight.iplat4j.core.data.DaoEPBase
;
import
java.math.BigDecimal
;
import
java.util.HashMap
;
import
java.util.Map
;
import
com.baosight.iplat4j.core.util.StringUtils
;
...
...
@@ -21,7 +23,7 @@ public class HGSC006A extends DaoEPBase {
private
static
final
long
serialVersionUID
=
1L
;
public
static
final
String
FIELD_id
=
"id"
;
public
static
final
String
FIELD_id
=
"id"
;
public
static
final
String
FIELD_plan_id
=
"planId"
;
/* 生产计划ID*/
public
static
final
String
FIELD_plan_detail_id
=
"planDetailId"
;
/* 生产计划明细ID*/
public
static
final
String
FIELD_tech_flow_id
=
"techFlowId"
;
/* 工艺流程ID*/
...
...
@@ -40,12 +42,16 @@ public class HGSC006A extends DaoEPBase {
public
static
final
String
FIELD_product_type
=
"productType"
;
/* 产品类型*/
public
static
final
String
FIELD_product_code
=
"productCode"
;
/* 产品编号*/
public
static
final
String
FIELD_product_name
=
"productName"
;
/* 产品名称*/
public
static
final
String
FIELD_assign_date
=
"assignDate"
;
/* 派工日期*/
public
static
final
String
FIELD_plan_start_date
=
"planStartDate"
;
/* 计划开始日期*/
public
static
final
String
FIELD_plan_end_date
=
"planEndDate"
;
/* 计划结束日期*/
public
static
final
String
FIELD_quantity
=
"quantity"
;
/* 数量*/
public
static
final
String
FIELD_assign_quantity
=
"assignQuantity"
;
/* 派工数量*/
public
static
final
String
FIELD_unassign_quantity
=
"unassignQuantity"
;
/* 未派工数量*/
public
static
final
String
FIELD_single_weight
=
"singleWeight"
;
/* 单重*/
public
static
final
String
FIELD_total_weight
=
"totalWeight"
;
/* 总重*/
public
static
final
String
FIELD_assign_weight
=
"assignWeight"
;
/* 派工重量*/
public
static
final
String
FIELD_unassign_weight
=
"unassignWeight"
;
/* 未派工重量*/
public
static
final
String
FIELD_assign_status
=
"assignStatus"
;
/* 派工状态 0待派工;1部分派工;2已派工*/
public
static
final
String
FIELD_account_code
=
"accountCode"
;
/* 帐套*/
public
static
final
String
FIELD_created_by
=
"createdBy"
;
/* 创建人*/
public
static
final
String
FIELD_created_name
=
"createdName"
;
/* 创建人名称*/
...
...
@@ -54,7 +60,7 @@ public class HGSC006A extends DaoEPBase {
public
static
final
String
FIELD_updated_name
=
"updatedName"
;
/* 修改人名称*/
public
static
final
String
FIELD_updated_time
=
"updatedTime"
;
/* 更新时间*/
public
static
final
String
COL_id
=
"id"
;
public
static
final
String
COL_id
=
"id"
;
public
static
final
String
COL_plan_id
=
"plan_id"
;
/* 生产计划ID*/
public
static
final
String
COL_plan_detail_id
=
"plan_detail_id"
;
/* 生产计划明细ID*/
public
static
final
String
COL_tech_flow_id
=
"tech_flow_id"
;
/* 工艺流程ID*/
...
...
@@ -73,12 +79,16 @@ public class HGSC006A extends DaoEPBase {
public
static
final
String
COL_product_type
=
"product_type"
;
/* 产品类型*/
public
static
final
String
COL_product_code
=
"product_code"
;
/* 产品编号*/
public
static
final
String
COL_product_name
=
"product_name"
;
/* 产品名称*/
public
static
final
String
COL_assign_date
=
"assign_date"
;
/* 派工日期*/
public
static
final
String
COL_plan_start_date
=
"plan_start_date"
;
/* 计划开始日期*/
public
static
final
String
COL_plan_end_date
=
"plan_end_date"
;
/* 计划结束日期*/
public
static
final
String
COL_quantity
=
"quantity"
;
/* 数量*/
public
static
final
String
COL_assign_quantity
=
"assign_quantity"
;
/* 派工数量*/
public
static
final
String
COL_unassign_quantity
=
"unassign_quantity"
;
/* 未派工数量*/
public
static
final
String
COL_single_weight
=
"single_weight"
;
/* 单重*/
public
static
final
String
COL_total_weight
=
"total_weight"
;
/* 总重*/
public
static
final
String
COL_assign_weight
=
"assign_weight"
;
/* 派工重量*/
public
static
final
String
COL_unassign_weight
=
"unassign_weight"
;
/* 未派工重量*/
public
static
final
String
COL_assign_status
=
"assign_status"
;
/* 派工状态 0待派工;1部分派工;2已派工*/
public
static
final
String
COL_account_code
=
"account_code"
;
/* 帐套*/
public
static
final
String
COL_created_by
=
"created_by"
;
/* 创建人*/
public
static
final
String
COL_created_name
=
"created_name"
;
/* 创建人名称*/
...
...
@@ -92,8 +102,11 @@ public class HGSC006A extends DaoEPBase {
public
static
final
String
INSERT
=
"HGSC006A.insert"
;
public
static
final
String
UPDATE
=
"HGSC006A.update"
;
public
static
final
String
DELETE
=
"HGSC006A.delete"
;
public
static
final
String
UPDATE_ASSIGN_NUM
=
"HGSC006A.update_assign_num"
;
public
static
final
String
QUERY_OTHER
=
"HGSC006A.query_other"
;
private
Long
id
=
new
Long
(
0
);
private
Long
id
=
new
Long
(
0
);
private
Long
planId
=
new
Long
(
0
);
/* 生产计划ID*/
private
Long
planDetailId
=
new
Long
(
0
);
/* 生产计划明细ID*/
private
Long
techFlowId
=
new
Long
(
0
);
/* 工艺流程ID*/
...
...
@@ -112,12 +125,16 @@ public class HGSC006A extends DaoEPBase {
private
Integer
productType
=
new
Integer
(
0
);
/* 产品类型*/
private
String
productCode
=
" "
;
/* 产品编号*/
private
String
productName
=
" "
;
/* 产品名称*/
private
String
assignDate
=
" "
;
/* 派工日期*/
private
String
planStartDate
=
" "
;
/* 计划开始日期*/
private
String
planEndDate
=
" "
;
/* 计划结束日期*/
private
Integer
quantity
=
new
Integer
(
0
);
/* 数量*/
private
Integer
assignQuantity
=
new
Integer
(
0
);
/* 派工数量*/
private
Integer
unassignQuantity
=
new
Integer
(
0
);
/* 未派工数量*/
private
BigDecimal
singleWeight
=
new
BigDecimal
(
"0"
);
/* 单重*/
private
BigDecimal
totalWeight
=
new
BigDecimal
(
"0"
);
/* 总重*/
private
BigDecimal
assignWeight
=
new
BigDecimal
(
"0"
);
/* 派工重量*/
private
BigDecimal
unassignWeight
=
new
BigDecimal
(
"0"
);
/* 未派工重量*/
private
Integer
assignStatus
=
new
Integer
(
0
);
/* 派工状态 0待派工;1部分派工;2已派工*/
private
String
accountCode
=
" "
;
/* 帐套*/
private
String
createdBy
=
" "
;
/* 创建人*/
private
String
createdName
=
" "
;
/* 创建人名称*/
...
...
@@ -209,10 +226,6 @@ public class HGSC006A extends DaoEPBase {
eiColumn
.
setDescName
(
"产品名称"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_assign_date
);
eiColumn
.
setDescName
(
"派工日期"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_plan_start_date
);
eiColumn
.
setDescName
(
"计划开始日期"
);
eiMetadata
.
addMeta
(
eiColumn
);
...
...
@@ -233,6 +246,38 @@ public class HGSC006A extends DaoEPBase {
eiColumn
.
setDescName
(
"未派工数量"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_single_weight
);
eiColumn
.
setType
(
"N"
);
eiColumn
.
setScaleLength
(
3
);
eiColumn
.
setFieldLength
(
20
);
eiColumn
.
setDescName
(
"单重"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_total_weight
);
eiColumn
.
setType
(
"N"
);
eiColumn
.
setScaleLength
(
3
);
eiColumn
.
setFieldLength
(
20
);
eiColumn
.
setDescName
(
"总重"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_assign_weight
);
eiColumn
.
setType
(
"N"
);
eiColumn
.
setScaleLength
(
3
);
eiColumn
.
setFieldLength
(
20
);
eiColumn
.
setDescName
(
"派工重量"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_unassign_weight
);
eiColumn
.
setType
(
"N"
);
eiColumn
.
setScaleLength
(
3
);
eiColumn
.
setFieldLength
(
20
);
eiColumn
.
setDescName
(
"未派工重量"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_assign_status
);
eiColumn
.
setDescName
(
"派工状态 0待派工;1部分派工;2已派工"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_account_code
);
eiColumn
.
setDescName
(
"帐套"
);
eiMetadata
.
addMeta
(
eiColumn
);
...
...
@@ -282,7 +327,7 @@ public class HGSC006A extends DaoEPBase {
/**
* set the id .
*
* @param id
* @param id
*/
public
void
setId
(
Long
id
)
{
this
.
id
=
id
;
...
...
@@ -576,22 +621,6 @@ public class HGSC006A extends DaoEPBase {
this
.
productName
=
productName
;
}
/**
* get the assignDate - 派工日期.
* @return the assignDate
*/
public
String
getAssignDate
()
{
return
this
.
assignDate
;
}
/**
* set the assignDate - 派工日期.
*
* @param assignDate - 派工日期
*/
public
void
setAssignDate
(
String
assignDate
)
{
this
.
assignDate
=
assignDate
;
}
/**
* get the planStartDate - 计划开始日期.
* @return the planStartDate
*/
...
...
@@ -672,6 +701,86 @@ public class HGSC006A extends DaoEPBase {
this
.
unassignQuantity
=
unassignQuantity
;
}
/**
* get the singleWeight - 单重.
* @return the singleWeight
*/
public
BigDecimal
getSingleWeight
()
{
return
this
.
singleWeight
;
}
/**
* set the singleWeight - 单重.
*
* @param singleWeight - 单重
*/
public
void
setSingleWeight
(
BigDecimal
singleWeight
)
{
this
.
singleWeight
=
singleWeight
;
}
/**
* get the totalWeight - 总重.
* @return the totalWeight
*/
public
BigDecimal
getTotalWeight
()
{
return
this
.
totalWeight
;
}
/**
* set the totalWeight - 总重.
*
* @param totalWeight - 总重
*/
public
void
setTotalWeight
(
BigDecimal
totalWeight
)
{
this
.
totalWeight
=
totalWeight
;
}
/**
* get the assignWeight - 派工重量.
* @return the assignWeight
*/
public
BigDecimal
getAssignWeight
()
{
return
this
.
assignWeight
;
}
/**
* set the assignWeight - 派工重量.
*
* @param assignWeight - 派工重量
*/
public
void
setAssignWeight
(
BigDecimal
assignWeight
)
{
this
.
assignWeight
=
assignWeight
;
}
/**
* get the unassignWeight - 未派工重量.
* @return the unassignWeight
*/
public
BigDecimal
getUnassignWeight
()
{
return
this
.
unassignWeight
;
}
/**
* set the unassignWeight - 未派工重量.
*
* @param unassignWeight - 未派工重量
*/
public
void
setUnassignWeight
(
BigDecimal
unassignWeight
)
{
this
.
unassignWeight
=
unassignWeight
;
}
/**
* get the assignStatus - 派工状态 0待派工;1部分派工;2已派工.
* @return the assignStatus
*/
public
Integer
getAssignStatus
()
{
return
this
.
assignStatus
;
}
/**
* set the assignStatus - 派工状态 0待派工;1部分派工;2已派工.
*
* @param assignStatus - 派工状态 0待派工;1部分派工;2已派工
*/
public
void
setAssignStatus
(
Integer
assignStatus
)
{
this
.
assignStatus
=
assignStatus
;
}
/**
* get the accountCode - 帐套.
* @return the accountCode
*/
...
...
@@ -810,12 +919,16 @@ public class HGSC006A extends DaoEPBase {
setProductType
(
NumberUtils
.
toInteger
(
StringUtils
.
toString
(
map
.
get
(
FIELD_product_type
)),
productType
));
setProductCode
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_product_code
)),
productCode
));
setProductName
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_product_name
)),
productName
));
setAssignDate
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_assign_date
)),
assignDate
));
setPlanStartDate
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_plan_start_date
)),
planStartDate
));
setPlanEndDate
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_plan_end_date
)),
planEndDate
));
setQuantity
(
NumberUtils
.
toInteger
(
StringUtils
.
toString
(
map
.
get
(
FIELD_quantity
)),
quantity
));
setAssignQuantity
(
NumberUtils
.
toInteger
(
StringUtils
.
toString
(
map
.
get
(
FIELD_assign_quantity
)),
assignQuantity
));
setUnassignQuantity
(
NumberUtils
.
toInteger
(
StringUtils
.
toString
(
map
.
get
(
FIELD_unassign_quantity
)),
unassignQuantity
));
setSingleWeight
(
NumberUtils
.
toBigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_single_weight
)),
singleWeight
));
setTotalWeight
(
NumberUtils
.
toBigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_total_weight
)),
totalWeight
));
setAssignWeight
(
NumberUtils
.
toBigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_assign_weight
)),
assignWeight
));
setUnassignWeight
(
NumberUtils
.
toBigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_unassign_weight
)),
unassignWeight
));
setAssignStatus
(
NumberUtils
.
toInteger
(
StringUtils
.
toString
(
map
.
get
(
FIELD_assign_status
)),
assignStatus
));
setAccountCode
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_account_code
)),
accountCode
));
setCreatedBy
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_created_by
)),
createdBy
));
setCreatedName
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_created_name
)),
createdName
));
...
...
@@ -851,12 +964,16 @@ public class HGSC006A extends DaoEPBase {
map
.
put
(
FIELD_product_type
,
StringUtils
.
toString
(
productType
,
eiMetadata
.
getMeta
(
FIELD_product_type
)));
map
.
put
(
FIELD_product_code
,
StringUtils
.
toString
(
productCode
,
eiMetadata
.
getMeta
(
FIELD_product_code
)));
map
.
put
(
FIELD_product_name
,
StringUtils
.
toString
(
productName
,
eiMetadata
.
getMeta
(
FIELD_product_name
)));
map
.
put
(
FIELD_assign_date
,
StringUtils
.
toString
(
assignDate
,
eiMetadata
.
getMeta
(
FIELD_assign_date
)));
map
.
put
(
FIELD_plan_start_date
,
StringUtils
.
toString
(
planStartDate
,
eiMetadata
.
getMeta
(
FIELD_plan_start_date
)));
map
.
put
(
FIELD_plan_end_date
,
StringUtils
.
toString
(
planEndDate
,
eiMetadata
.
getMeta
(
FIELD_plan_end_date
)));
map
.
put
(
FIELD_quantity
,
StringUtils
.
toString
(
quantity
,
eiMetadata
.
getMeta
(
FIELD_quantity
)));
map
.
put
(
FIELD_assign_quantity
,
StringUtils
.
toString
(
assignQuantity
,
eiMetadata
.
getMeta
(
FIELD_assign_quantity
)));
map
.
put
(
FIELD_unassign_quantity
,
StringUtils
.
toString
(
unassignQuantity
,
eiMetadata
.
getMeta
(
FIELD_unassign_quantity
)));
map
.
put
(
FIELD_single_weight
,
StringUtils
.
toString
(
singleWeight
,
eiMetadata
.
getMeta
(
FIELD_single_weight
)));
map
.
put
(
FIELD_total_weight
,
StringUtils
.
toString
(
totalWeight
,
eiMetadata
.
getMeta
(
FIELD_total_weight
)));
map
.
put
(
FIELD_assign_weight
,
StringUtils
.
toString
(
assignWeight
,
eiMetadata
.
getMeta
(
FIELD_assign_weight
)));
map
.
put
(
FIELD_unassign_weight
,
StringUtils
.
toString
(
unassignWeight
,
eiMetadata
.
getMeta
(
FIELD_unassign_weight
)));
map
.
put
(
FIELD_assign_status
,
StringUtils
.
toString
(
assignStatus
,
eiMetadata
.
getMeta
(
FIELD_assign_status
)));
map
.
put
(
FIELD_account_code
,
StringUtils
.
toString
(
accountCode
,
eiMetadata
.
getMeta
(
FIELD_account_code
)));
map
.
put
(
FIELD_created_by
,
StringUtils
.
toString
(
createdBy
,
eiMetadata
.
getMeta
(
FIELD_created_by
)));
map
.
put
(
FIELD_created_name
,
StringUtils
.
toString
(
createdName
,
eiMetadata
.
getMeta
(
FIELD_created_name
)));
...
...
@@ -867,4 +984,4 @@ public class HGSC006A extends DaoEPBase {
return
map
;
}
}
}
\ No newline at end of file
src/main/java/com/baosight/hggp/hg/sc/domain/HGSC007.java
0 → 100644
View file @
4853573f
package
com
.
baosight
.
hggp
.
hg
.
sc
.
domain
;
import
com.baosight.iplat4j.core.util.NumberUtils
;
import
com.baosight.iplat4j.core.ei.EiColumn
;
import
com.baosight.iplat4j.core.data.DaoEPBase
;
import
java.math.BigDecimal
;
import
java.util.HashMap
;
import
java.util.Map
;
import
com.baosight.iplat4j.core.util.StringUtils
;
/**
* Project: <br>
* Title:HGSC007.java <br>
* Description: <br>
*
* Copyrigth:Baosight Software LTD.co Copyright (c) 2019. <br>
*
* @version 1.0
* @history 2024-05-23 14:24:01 create
*/
public
class
HGSC007
extends
DaoEPBase
{
private
static
final
long
serialVersionUID
=
1L
;
public
static
final
String
FIELD_id
=
"id"
;
public
static
final
String
FIELD_mat_id
=
"matId"
;
/* 物料清单ID*/
public
static
final
String
FIELD_order_id
=
"orderId"
;
/* 生产计划ID*/
public
static
final
String
FIELD_order_detail_id
=
"orderDetailId"
;
/* 生产计划明细ID*/
public
static
final
String
FIELD_tech_flow_id
=
"techFlowId"
;
/* 工艺流程ID*/
public
static
final
String
FIELD_tech_flow_name
=
"techFlowName"
;
/* 工艺流程名称*/
public
static
final
String
FIELD_invent_process_id
=
"inventProcessId"
;
/* 存货工序ID,对应HGPZ005A.id*/
public
static
final
String
FIELD_process_code
=
"processCode"
;
/* 工序编码*/
public
static
final
String
FIELD_process_name
=
"processName"
;
/* 工序名称*/
public
static
final
String
FIELD_process_order
=
"processOrder"
;
/* 加工顺序*/
public
static
final
String
FIELD_company_code
=
"companyCode"
;
/* 公司编码*/
public
static
final
String
FIELD_company_name
=
"companyName"
;
/* 公司名称*/
public
static
final
String
FIELD_dep_code
=
"depCode"
;
/* 部门编码*/
public
static
final
String
FIELD_dep_name
=
"depName"
;
/* 部门名称*/
public
static
final
String
FIELD_proj_code
=
"projCode"
;
/* 项目编码*/
public
static
final
String
FIELD_proj_name
=
"projName"
;
/* 项目名称*/
public
static
final
String
FIELD_task_code
=
"taskCode"
;
/* 任务编码*/
public
static
final
String
FIELD_product_type
=
"productType"
;
/* 产品类型*/
public
static
final
String
FIELD_product_code
=
"productCode"
;
/* 产品编号*/
public
static
final
String
FIELD_product_name
=
"productName"
;
/* 产品名称*/
public
static
final
String
FIELD_plan_start_date
=
"planStartDate"
;
/* 计划开始日期*/
public
static
final
String
FIELD_plan_end_date
=
"planEndDate"
;
/* 计划结束日期*/
public
static
final
String
FIELD_factory_code
=
"factoryCode"
;
/* 工厂编号*/
public
static
final
String
FIELD_factory_name
=
"factoryName"
;
/* 工厂名称*/
public
static
final
String
FIELD_group_code
=
"groupCode"
;
/* 工作组编号*/
public
static
final
String
FIELD_group_name
=
"groupName"
;
/* 工作组名称*/
public
static
final
String
FIELD_complete_date
=
"completeDate"
;
/* 完工日期*/
public
static
final
String
FIELD_quantity
=
"quantity"
;
/* 数量*/
public
static
final
String
FIELD_finish_quantity
=
"finishQuantity"
;
/* 完工数量*/
public
static
final
String
FIELD_unfinish_quantity
=
"unfinishQuantity"
;
/* 未完工数量*/
public
static
final
String
FIELD_single_weight
=
"singleWeight"
;
/* 单重*/
public
static
final
String
FIELD_total_weight
=
"totalWeight"
;
/* 总重*/
public
static
final
String
FIELD_finish_weight
=
"finishWeight"
;
/* 完工重量*/
public
static
final
String
FIELD_unfinish_weight
=
"unfinishWeight"
;
/* 未完工重量*/
public
static
final
String
FIELD_account_code
=
"accountCode"
;
/* 帐套*/
public
static
final
String
FIELD_created_by
=
"createdBy"
;
/* 创建人*/
public
static
final
String
FIELD_created_name
=
"createdName"
;
/* 创建人名称*/
public
static
final
String
FIELD_created_time
=
"createdTime"
;
/* 创建时间*/
public
static
final
String
FIELD_updated_by
=
"updatedBy"
;
/* 更新人*/
public
static
final
String
FIELD_updated_name
=
"updatedName"
;
/* 修改人名称*/
public
static
final
String
FIELD_updated_time
=
"updatedTime"
;
/* 更新时间*/
public
static
final
String
COL_id
=
"id"
;
public
static
final
String
COL_mat_id
=
"mat_id"
;
/* 物料清单ID*/
public
static
final
String
COL_order_id
=
"order_id"
;
/* 生产计划ID*/
public
static
final
String
COL_order_detail_id
=
"order_detail_id"
;
/* 生产计划明细ID*/
public
static
final
String
COL_tech_flow_id
=
"tech_flow_id"
;
/* 工艺流程ID*/
public
static
final
String
COL_tech_flow_name
=
"tech_flow_name"
;
/* 工艺流程名称*/
public
static
final
String
COL_invent_process_id
=
"invent_process_id"
;
/* 存货工序ID,对应HGPZ005A.id*/
public
static
final
String
COL_process_code
=
"process_code"
;
/* 工序编码*/
public
static
final
String
COL_process_name
=
"process_name"
;
/* 工序名称*/
public
static
final
String
COL_process_order
=
"process_order"
;
/* 加工顺序*/
public
static
final
String
COL_company_code
=
"company_code"
;
/* 公司编码*/
public
static
final
String
COL_company_name
=
"company_name"
;
/* 公司名称*/
public
static
final
String
COL_dep_code
=
"dep_code"
;
/* 部门编码*/
public
static
final
String
COL_dep_name
=
"dep_name"
;
/* 部门名称*/
public
static
final
String
COL_proj_code
=
"proj_code"
;
/* 项目编码*/
public
static
final
String
COL_proj_name
=
"proj_name"
;
/* 项目名称*/
public
static
final
String
COL_task_code
=
"task_code"
;
/* 任务编码*/
public
static
final
String
COL_product_type
=
"product_type"
;
/* 产品类型*/
public
static
final
String
COL_product_code
=
"product_code"
;
/* 产品编号*/
public
static
final
String
COL_product_name
=
"product_name"
;
/* 产品名称*/
public
static
final
String
COL_plan_start_date
=
"plan_start_date"
;
/* 计划开始日期*/
public
static
final
String
COL_plan_end_date
=
"plan_end_date"
;
/* 计划结束日期*/
public
static
final
String
COL_factory_code
=
"factory_code"
;
/* 工厂编号*/
public
static
final
String
COL_factory_name
=
"factory_name"
;
/* 工厂名称*/
public
static
final
String
COL_group_code
=
"group_code"
;
/* 工作组编号*/
public
static
final
String
COL_group_name
=
"group_name"
;
/* 工作组名称*/
public
static
final
String
COL_complete_date
=
"complete_date"
;
/* 完工日期*/
public
static
final
String
COL_quantity
=
"quantity"
;
/* 数量*/
public
static
final
String
COL_finish_quantity
=
"finish_quantity"
;
/* 完工数量*/
public
static
final
String
COL_unfinish_quantity
=
"unfinish_quantity"
;
/* 未完工数量*/
public
static
final
String
COL_single_weight
=
"single_weight"
;
/* 单重*/
public
static
final
String
COL_total_weight
=
"total_weight"
;
/* 总重*/
public
static
final
String
COL_finish_weight
=
"finish_weight"
;
/* 完工重量*/
public
static
final
String
COL_unfinish_weight
=
"unfinish_weight"
;
/* 未完工重量*/
public
static
final
String
COL_account_code
=
"account_code"
;
/* 帐套*/
public
static
final
String
COL_created_by
=
"created_by"
;
/* 创建人*/
public
static
final
String
COL_created_name
=
"created_name"
;
/* 创建人名称*/
public
static
final
String
COL_created_time
=
"created_time"
;
/* 创建时间*/
public
static
final
String
COL_updated_by
=
"updated_by"
;
/* 更新人*/
public
static
final
String
COL_updated_name
=
"updated_name"
;
/* 修改人名称*/
public
static
final
String
COL_updated_time
=
"updated_time"
;
/* 更新时间*/
public
static
final
String
QUERY
=
"HGSC007.query"
;
public
static
final
String
COUNT
=
"HGSC007.count"
;
public
static
final
String
INSERT
=
"HGSC007.insert"
;
public
static
final
String
UPDATE
=
"HGSC007.update"
;
public
static
final
String
DELETE
=
"HGSC007.delete"
;
private
Long
id
=
new
Long
(
0
);
private
Long
matId
=
new
Long
(
0
);
/* 物料清单ID*/
private
Long
orderId
=
new
Long
(
0
);
/* 生产计划ID*/
private
Long
orderDetailId
=
new
Long
(
0
);
/* 生产计划明细ID*/
private
Long
techFlowId
=
new
Long
(
0
);
/* 工艺流程ID*/
private
Long
techFlowName
=
new
Long
(
0
);
/* 工艺流程名称*/
private
Long
inventProcessId
=
new
Long
(
0
);
/* 存货工序ID,对应HGPZ005A.id*/
private
String
processCode
=
" "
;
/* 工序编码*/
private
String
processName
=
" "
;
/* 工序名称*/
private
Long
processOrder
=
new
Long
(
0
);
/* 加工顺序*/
private
String
companyCode
=
" "
;
/* 公司编码*/
private
String
companyName
=
" "
;
/* 公司名称*/
private
String
depCode
=
" "
;
/* 部门编码*/
private
String
depName
=
" "
;
/* 部门名称*/
private
String
projCode
=
" "
;
/* 项目编码*/
private
String
projName
=
" "
;
/* 项目名称*/
private
String
taskCode
=
" "
;
/* 任务编码*/
private
Integer
productType
=
new
Integer
(
0
);
/* 产品类型*/
private
String
productCode
=
" "
;
/* 产品编号*/
private
String
productName
=
" "
;
/* 产品名称*/
private
String
planStartDate
=
" "
;
/* 计划开始日期*/
private
String
planEndDate
=
" "
;
/* 计划结束日期*/
private
String
factoryCode
=
" "
;
/* 工厂编号*/
private
String
factoryName
=
" "
;
/* 工厂名称*/
private
String
groupCode
=
" "
;
/* 工作组编号*/
private
String
groupName
=
" "
;
/* 工作组名称*/
private
String
completeDate
=
" "
;
/* 完工日期*/
private
Integer
quantity
=
new
Integer
(
0
);
/* 数量*/
private
Integer
finishQuantity
=
new
Integer
(
0
);
/* 完工数量*/
private
Integer
unfinishQuantity
=
new
Integer
(
0
);
/* 未完工数量*/
private
BigDecimal
singleWeight
=
new
BigDecimal
(
"0"
);
/* 单重*/
private
BigDecimal
totalWeight
=
new
BigDecimal
(
"0"
);
/* 总重*/
private
BigDecimal
finishWeight
=
new
BigDecimal
(
"0"
);
/* 完工重量*/
private
BigDecimal
unfinishWeight
=
new
BigDecimal
(
"0"
);
/* 未完工重量*/
private
String
accountCode
=
" "
;
/* 帐套*/
private
String
createdBy
=
" "
;
/* 创建人*/
private
String
createdName
=
" "
;
/* 创建人名称*/
private
String
createdTime
=
" "
;
/* 创建时间*/
private
String
updatedBy
=
" "
;
/* 更新人*/
private
String
updatedName
=
" "
;
/* 修改人名称*/
private
String
updatedTime
=
" "
;
/* 更新时间*/
/**
* initialize the metadata.
*/
public
void
initMetaData
()
{
EiColumn
eiColumn
;
eiColumn
=
new
EiColumn
(
FIELD_id
);
eiColumn
.
setPrimaryKey
(
true
);
eiColumn
.
setDescName
(
" "
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_mat_id
);
eiColumn
.
setDescName
(
"物料清单ID"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_order_id
);
eiColumn
.
setDescName
(
"生产计划ID"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_order_detail_id
);
eiColumn
.
setDescName
(
"生产计划明细ID"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_tech_flow_id
);
eiColumn
.
setDescName
(
"工艺流程ID"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_tech_flow_name
);
eiColumn
.
setDescName
(
"工艺流程名称"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_invent_process_id
);
eiColumn
.
setDescName
(
"存货工序ID,对应HGPZ005A.id"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_process_code
);
eiColumn
.
setDescName
(
"工序编码"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_process_name
);
eiColumn
.
setDescName
(
"工序名称"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_process_order
);
eiColumn
.
setDescName
(
"加工顺序"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_company_code
);
eiColumn
.
setDescName
(
"公司编码"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_company_name
);
eiColumn
.
setDescName
(
"公司名称"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_dep_code
);
eiColumn
.
setDescName
(
"部门编码"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_dep_name
);
eiColumn
.
setDescName
(
"部门名称"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_proj_code
);
eiColumn
.
setDescName
(
"项目编码"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_proj_name
);
eiColumn
.
setDescName
(
"项目名称"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_task_code
);
eiColumn
.
setDescName
(
"任务编码"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_product_type
);
eiColumn
.
setDescName
(
"产品类型"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_product_code
);
eiColumn
.
setDescName
(
"产品编号"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_product_name
);
eiColumn
.
setDescName
(
"产品名称"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_plan_start_date
);
eiColumn
.
setDescName
(
"计划开始日期"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_plan_end_date
);
eiColumn
.
setDescName
(
"计划结束日期"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_factory_code
);
eiColumn
.
setDescName
(
"工厂编号"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_factory_name
);
eiColumn
.
setDescName
(
"工厂名称"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_group_code
);
eiColumn
.
setDescName
(
"工作组编号"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_group_name
);
eiColumn
.
setDescName
(
"工作组名称"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_complete_date
);
eiColumn
.
setDescName
(
"完工日期"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_quantity
);
eiColumn
.
setDescName
(
"数量"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_finish_quantity
);
eiColumn
.
setDescName
(
"完工数量"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_unfinish_quantity
);
eiColumn
.
setDescName
(
"未完工数量"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_single_weight
);
eiColumn
.
setType
(
"N"
);
eiColumn
.
setScaleLength
(
3
);
eiColumn
.
setFieldLength
(
20
);
eiColumn
.
setDescName
(
"单重"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_total_weight
);
eiColumn
.
setType
(
"N"
);
eiColumn
.
setScaleLength
(
3
);
eiColumn
.
setFieldLength
(
20
);
eiColumn
.
setDescName
(
"总重"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_finish_weight
);
eiColumn
.
setType
(
"N"
);
eiColumn
.
setScaleLength
(
3
);
eiColumn
.
setFieldLength
(
20
);
eiColumn
.
setDescName
(
"完工重量"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_unfinish_weight
);
eiColumn
.
setType
(
"N"
);
eiColumn
.
setScaleLength
(
3
);
eiColumn
.
setFieldLength
(
20
);
eiColumn
.
setDescName
(
"未完工重量"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_account_code
);
eiColumn
.
setDescName
(
"帐套"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_created_by
);
eiColumn
.
setDescName
(
"创建人"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_created_name
);
eiColumn
.
setDescName
(
"创建人名称"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_created_time
);
eiColumn
.
setDescName
(
"创建时间"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_updated_by
);
eiColumn
.
setDescName
(
"更新人"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_updated_name
);
eiColumn
.
setDescName
(
"修改人名称"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_updated_time
);
eiColumn
.
setDescName
(
"更新时间"
);
eiMetadata
.
addMeta
(
eiColumn
);
}
/**
* the constructor.
*/
public
HGSC007
()
{
initMetaData
();
}
/**
* get the id .
* @return the id
*/
public
Long
getId
()
{
return
this
.
id
;
}
/**
* set the id .
*
* @param id
*/
public
void
setId
(
Long
id
)
{
this
.
id
=
id
;
}
/**
* get the matId - 物料清单ID.
* @return the matId
*/
public
Long
getMatId
()
{
return
this
.
matId
;
}
/**
* set the matId - 物料清单ID.
*
* @param matId - 物料清单ID
*/
public
void
setMatId
(
Long
matId
)
{
this
.
matId
=
matId
;
}
/**
* get the orderId - 生产计划ID.
* @return the orderId
*/
public
Long
getOrderId
()
{
return
this
.
orderId
;
}
/**
* set the orderId - 生产计划ID.
*
* @param orderId - 生产计划ID
*/
public
void
setOrderId
(
Long
orderId
)
{
this
.
orderId
=
orderId
;
}
/**
* get the orderDetailId - 生产计划明细ID.
* @return the orderDetailId
*/
public
Long
getOrderDetailId
()
{
return
this
.
orderDetailId
;
}
/**
* set the orderDetailId - 生产计划明细ID.
*
* @param orderDetailId - 生产计划明细ID
*/
public
void
setOrderDetailId
(
Long
orderDetailId
)
{
this
.
orderDetailId
=
orderDetailId
;
}
/**
* get the techFlowId - 工艺流程ID.
* @return the techFlowId
*/
public
Long
getTechFlowId
()
{
return
this
.
techFlowId
;
}
/**
* set the techFlowId - 工艺流程ID.
*
* @param techFlowId - 工艺流程ID
*/
public
void
setTechFlowId
(
Long
techFlowId
)
{
this
.
techFlowId
=
techFlowId
;
}
/**
* get the techFlowName - 工艺流程名称.
* @return the techFlowName
*/
public
Long
getTechFlowName
()
{
return
this
.
techFlowName
;
}
/**
* set the techFlowName - 工艺流程名称.
*
* @param techFlowName - 工艺流程名称
*/
public
void
setTechFlowName
(
Long
techFlowName
)
{
this
.
techFlowName
=
techFlowName
;
}
/**
* get the inventProcessId - 存货工序ID,对应HGPZ005A.id.
* @return the inventProcessId
*/
public
Long
getInventProcessId
()
{
return
this
.
inventProcessId
;
}
/**
* set the inventProcessId - 存货工序ID,对应HGPZ005A.id.
*
* @param inventProcessId - 存货工序ID,对应HGPZ005A.id
*/
public
void
setInventProcessId
(
Long
inventProcessId
)
{
this
.
inventProcessId
=
inventProcessId
;
}
/**
* get the processCode - 工序编码.
* @return the processCode
*/
public
String
getProcessCode
()
{
return
this
.
processCode
;
}
/**
* set the processCode - 工序编码.
*
* @param processCode - 工序编码
*/
public
void
setProcessCode
(
String
processCode
)
{
this
.
processCode
=
processCode
;
}
/**
* get the processName - 工序名称.
* @return the processName
*/
public
String
getProcessName
()
{
return
this
.
processName
;
}
/**
* set the processName - 工序名称.
*
* @param processName - 工序名称
*/
public
void
setProcessName
(
String
processName
)
{
this
.
processName
=
processName
;
}
/**
* get the processOrder - 加工顺序.
* @return the processOrder
*/
public
Long
getProcessOrder
()
{
return
this
.
processOrder
;
}
/**
* set the processOrder - 加工顺序.
*
* @param processOrder - 加工顺序
*/
public
void
setProcessOrder
(
Long
processOrder
)
{
this
.
processOrder
=
processOrder
;
}
/**
* get the companyCode - 公司编码.
* @return the companyCode
*/
public
String
getCompanyCode
()
{
return
this
.
companyCode
;
}
/**
* set the companyCode - 公司编码.
*
* @param companyCode - 公司编码
*/
public
void
setCompanyCode
(
String
companyCode
)
{
this
.
companyCode
=
companyCode
;
}
/**
* get the companyName - 公司名称.
* @return the companyName
*/
public
String
getCompanyName
()
{
return
this
.
companyName
;
}
/**
* set the companyName - 公司名称.
*
* @param companyName - 公司名称
*/
public
void
setCompanyName
(
String
companyName
)
{
this
.
companyName
=
companyName
;
}
/**
* get the depCode - 部门编码.
* @return the depCode
*/
public
String
getDepCode
()
{
return
this
.
depCode
;
}
/**
* set the depCode - 部门编码.
*
* @param depCode - 部门编码
*/
public
void
setDepCode
(
String
depCode
)
{
this
.
depCode
=
depCode
;
}
/**
* get the depName - 部门名称.
* @return the depName
*/
public
String
getDepName
()
{
return
this
.
depName
;
}
/**
* set the depName - 部门名称.
*
* @param depName - 部门名称
*/
public
void
setDepName
(
String
depName
)
{
this
.
depName
=
depName
;
}
/**
* get the projCode - 项目编码.
* @return the projCode
*/
public
String
getProjCode
()
{
return
this
.
projCode
;
}
/**
* set the projCode - 项目编码.
*
* @param projCode - 项目编码
*/
public
void
setProjCode
(
String
projCode
)
{
this
.
projCode
=
projCode
;
}
/**
* get the projName - 项目名称.
* @return the projName
*/
public
String
getProjName
()
{
return
this
.
projName
;
}
/**
* set the projName - 项目名称.
*
* @param projName - 项目名称
*/
public
void
setProjName
(
String
projName
)
{
this
.
projName
=
projName
;
}
/**
* get the taskCode - 任务编码.
* @return the taskCode
*/
public
String
getTaskCode
()
{
return
this
.
taskCode
;
}
/**
* set the taskCode - 任务编码.
*
* @param taskCode - 任务编码
*/
public
void
setTaskCode
(
String
taskCode
)
{
this
.
taskCode
=
taskCode
;
}
/**
* get the productType - 产品类型.
* @return the productType
*/
public
Integer
getProductType
()
{
return
this
.
productType
;
}
/**
* set the productType - 产品类型.
*
* @param productType - 产品类型
*/
public
void
setProductType
(
Integer
productType
)
{
this
.
productType
=
productType
;
}
/**
* get the productCode - 产品编号.
* @return the productCode
*/
public
String
getProductCode
()
{
return
this
.
productCode
;
}
/**
* set the productCode - 产品编号.
*
* @param productCode - 产品编号
*/
public
void
setProductCode
(
String
productCode
)
{
this
.
productCode
=
productCode
;
}
/**
* get the productName - 产品名称.
* @return the productName
*/
public
String
getProductName
()
{
return
this
.
productName
;
}
/**
* set the productName - 产品名称.
*
* @param productName - 产品名称
*/
public
void
setProductName
(
String
productName
)
{
this
.
productName
=
productName
;
}
/**
* get the planStartDate - 计划开始日期.
* @return the planStartDate
*/
public
String
getPlanStartDate
()
{
return
this
.
planStartDate
;
}
/**
* set the planStartDate - 计划开始日期.
*
* @param planStartDate - 计划开始日期
*/
public
void
setPlanStartDate
(
String
planStartDate
)
{
this
.
planStartDate
=
planStartDate
;
}
/**
* get the planEndDate - 计划结束日期.
* @return the planEndDate
*/
public
String
getPlanEndDate
()
{
return
this
.
planEndDate
;
}
/**
* set the planEndDate - 计划结束日期.
*
* @param planEndDate - 计划结束日期
*/
public
void
setPlanEndDate
(
String
planEndDate
)
{
this
.
planEndDate
=
planEndDate
;
}
/**
* get the factoryCode - 工厂编号.
* @return the factoryCode
*/
public
String
getFactoryCode
()
{
return
this
.
factoryCode
;
}
/**
* set the factoryCode - 工厂编号.
*
* @param factoryCode - 工厂编号
*/
public
void
setFactoryCode
(
String
factoryCode
)
{
this
.
factoryCode
=
factoryCode
;
}
/**
* get the factoryName - 工厂名称.
* @return the factoryName
*/
public
String
getFactoryName
()
{
return
this
.
factoryName
;
}
/**
* set the factoryName - 工厂名称.
*
* @param factoryName - 工厂名称
*/
public
void
setFactoryName
(
String
factoryName
)
{
this
.
factoryName
=
factoryName
;
}
/**
* get the groupCode - 工作组编号.
* @return the groupCode
*/
public
String
getGroupCode
()
{
return
this
.
groupCode
;
}
/**
* set the groupCode - 工作组编号.
*
* @param groupCode - 工作组编号
*/
public
void
setGroupCode
(
String
groupCode
)
{
this
.
groupCode
=
groupCode
;
}
/**
* get the groupName - 工作组名称.
* @return the groupName
*/
public
String
getGroupName
()
{
return
this
.
groupName
;
}
/**
* set the groupName - 工作组名称.
*
* @param groupName - 工作组名称
*/
public
void
setGroupName
(
String
groupName
)
{
this
.
groupName
=
groupName
;
}
/**
* get the completeDate - 完工日期.
* @return the completeDate
*/
public
String
getCompleteDate
()
{
return
this
.
completeDate
;
}
/**
* set the completeDate - 完工日期.
*
* @param completeDate - 完工日期
*/
public
void
setCompleteDate
(
String
completeDate
)
{
this
.
completeDate
=
completeDate
;
}
/**
* get the quantity - 数量.
* @return the quantity
*/
public
Integer
getQuantity
()
{
return
this
.
quantity
;
}
/**
* set the quantity - 数量.
*
* @param quantity - 数量
*/
public
void
setQuantity
(
Integer
quantity
)
{
this
.
quantity
=
quantity
;
}
/**
* get the finishQuantity - 完工数量.
* @return the finishQuantity
*/
public
Integer
getFinishQuantity
()
{
return
this
.
finishQuantity
;
}
/**
* set the finishQuantity - 完工数量.
*
* @param finishQuantity - 完工数量
*/
public
void
setFinishQuantity
(
Integer
finishQuantity
)
{
this
.
finishQuantity
=
finishQuantity
;
}
/**
* get the unfinishQuantity - 未完工数量.
* @return the unfinishQuantity
*/
public
Integer
getUnfinishQuantity
()
{
return
this
.
unfinishQuantity
;
}
/**
* set the unfinishQuantity - 未完工数量.
*
* @param unfinishQuantity - 未完工数量
*/
public
void
setUnfinishQuantity
(
Integer
unfinishQuantity
)
{
this
.
unfinishQuantity
=
unfinishQuantity
;
}
/**
* get the singleWeight - 单重.
* @return the singleWeight
*/
public
BigDecimal
getSingleWeight
()
{
return
this
.
singleWeight
;
}
/**
* set the singleWeight - 单重.
*
* @param singleWeight - 单重
*/
public
void
setSingleWeight
(
BigDecimal
singleWeight
)
{
this
.
singleWeight
=
singleWeight
;
}
/**
* get the totalWeight - 总重.
* @return the totalWeight
*/
public
BigDecimal
getTotalWeight
()
{
return
this
.
totalWeight
;
}
/**
* set the totalWeight - 总重.
*
* @param totalWeight - 总重
*/
public
void
setTotalWeight
(
BigDecimal
totalWeight
)
{
this
.
totalWeight
=
totalWeight
;
}
/**
* get the finishWeight - 完工重量.
* @return the finishWeight
*/
public
BigDecimal
getFinishWeight
()
{
return
this
.
finishWeight
;
}
/**
* set the finishWeight - 完工重量.
*
* @param finishWeight - 完工重量
*/
public
void
setFinishWeight
(
BigDecimal
finishWeight
)
{
this
.
finishWeight
=
finishWeight
;
}
/**
* get the unfinishWeight - 未完工重量.
* @return the unfinishWeight
*/
public
BigDecimal
getUnfinishWeight
()
{
return
this
.
unfinishWeight
;
}
/**
* set the unfinishWeight - 未完工重量.
*
* @param unfinishWeight - 未完工重量
*/
public
void
setUnfinishWeight
(
BigDecimal
unfinishWeight
)
{
this
.
unfinishWeight
=
unfinishWeight
;
}
/**
* get the accountCode - 帐套.
* @return the accountCode
*/
public
String
getAccountCode
()
{
return
this
.
accountCode
;
}
/**
* set the accountCode - 帐套.
*
* @param accountCode - 帐套
*/
public
void
setAccountCode
(
String
accountCode
)
{
this
.
accountCode
=
accountCode
;
}
/**
* get the createdBy - 创建人.
* @return the createdBy
*/
public
String
getCreatedBy
()
{
return
this
.
createdBy
;
}
/**
* set the createdBy - 创建人.
*
* @param createdBy - 创建人
*/
public
void
setCreatedBy
(
String
createdBy
)
{
this
.
createdBy
=
createdBy
;
}
/**
* get the createdName - 创建人名称.
* @return the createdName
*/
public
String
getCreatedName
()
{
return
this
.
createdName
;
}
/**
* set the createdName - 创建人名称.
*
* @param createdName - 创建人名称
*/
public
void
setCreatedName
(
String
createdName
)
{
this
.
createdName
=
createdName
;
}
/**
* get the createdTime - 创建时间.
* @return the createdTime
*/
public
String
getCreatedTime
()
{
return
this
.
createdTime
;
}
/**
* set the createdTime - 创建时间.
*
* @param createdTime - 创建时间
*/
public
void
setCreatedTime
(
String
createdTime
)
{
this
.
createdTime
=
createdTime
;
}
/**
* get the updatedBy - 更新人.
* @return the updatedBy
*/
public
String
getUpdatedBy
()
{
return
this
.
updatedBy
;
}
/**
* set the updatedBy - 更新人.
*
* @param updatedBy - 更新人
*/
public
void
setUpdatedBy
(
String
updatedBy
)
{
this
.
updatedBy
=
updatedBy
;
}
/**
* get the updatedName - 修改人名称.
* @return the updatedName
*/
public
String
getUpdatedName
()
{
return
this
.
updatedName
;
}
/**
* set the updatedName - 修改人名称.
*
* @param updatedName - 修改人名称
*/
public
void
setUpdatedName
(
String
updatedName
)
{
this
.
updatedName
=
updatedName
;
}
/**
* get the updatedTime - 更新时间.
* @return the updatedTime
*/
public
String
getUpdatedTime
()
{
return
this
.
updatedTime
;
}
/**
* set the updatedTime - 更新时间.
*
* @param updatedTime - 更新时间
*/
public
void
setUpdatedTime
(
String
updatedTime
)
{
this
.
updatedTime
=
updatedTime
;
}
/**
* get the value from Map.
*
* @param map - source data map
*/
@Override
public
void
fromMap
(
Map
map
)
{
setId
(
NumberUtils
.
toLong
(
StringUtils
.
toString
(
map
.
get
(
FIELD_id
)),
id
));
setMatId
(
NumberUtils
.
toLong
(
StringUtils
.
toString
(
map
.
get
(
FIELD_mat_id
)),
matId
));
setOrderId
(
NumberUtils
.
toLong
(
StringUtils
.
toString
(
map
.
get
(
FIELD_order_id
)),
orderId
));
setOrderDetailId
(
NumberUtils
.
toLong
(
StringUtils
.
toString
(
map
.
get
(
FIELD_order_detail_id
)),
orderDetailId
));
setTechFlowId
(
NumberUtils
.
toLong
(
StringUtils
.
toString
(
map
.
get
(
FIELD_tech_flow_id
)),
techFlowId
));
setTechFlowName
(
NumberUtils
.
toLong
(
StringUtils
.
toString
(
map
.
get
(
FIELD_tech_flow_name
)),
techFlowName
));
setInventProcessId
(
NumberUtils
.
toLong
(
StringUtils
.
toString
(
map
.
get
(
FIELD_invent_process_id
)),
inventProcessId
));
setProcessCode
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_process_code
)),
processCode
));
setProcessName
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_process_name
)),
processName
));
setProcessOrder
(
NumberUtils
.
toLong
(
StringUtils
.
toString
(
map
.
get
(
FIELD_process_order
)),
processOrder
));
setCompanyCode
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_company_code
)),
companyCode
));
setCompanyName
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_company_name
)),
companyName
));
setDepCode
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_dep_code
)),
depCode
));
setDepName
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_dep_name
)),
depName
));
setProjCode
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_proj_code
)),
projCode
));
setProjName
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_proj_name
)),
projName
));
setTaskCode
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_task_code
)),
taskCode
));
setProductType
(
NumberUtils
.
toInteger
(
StringUtils
.
toString
(
map
.
get
(
FIELD_product_type
)),
productType
));
setProductCode
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_product_code
)),
productCode
));
setProductName
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_product_name
)),
productName
));
setPlanStartDate
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_plan_start_date
)),
planStartDate
));
setPlanEndDate
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_plan_end_date
)),
planEndDate
));
setFactoryCode
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_factory_code
)),
factoryCode
));
setFactoryName
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_factory_name
)),
factoryName
));
setGroupCode
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_group_code
)),
groupCode
));
setGroupName
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_group_name
)),
groupName
));
setCompleteDate
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_complete_date
)),
completeDate
));
setQuantity
(
NumberUtils
.
toInteger
(
StringUtils
.
toString
(
map
.
get
(
FIELD_quantity
)),
quantity
));
setFinishQuantity
(
NumberUtils
.
toInteger
(
StringUtils
.
toString
(
map
.
get
(
FIELD_finish_quantity
)),
finishQuantity
));
setUnfinishQuantity
(
NumberUtils
.
toInteger
(
StringUtils
.
toString
(
map
.
get
(
FIELD_unfinish_quantity
)),
unfinishQuantity
));
setSingleWeight
(
NumberUtils
.
toBigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_single_weight
)),
singleWeight
));
setTotalWeight
(
NumberUtils
.
toBigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_total_weight
)),
totalWeight
));
setFinishWeight
(
NumberUtils
.
toBigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_finish_weight
)),
finishWeight
));
setUnfinishWeight
(
NumberUtils
.
toBigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_unfinish_weight
)),
unfinishWeight
));
setAccountCode
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_account_code
)),
accountCode
));
setCreatedBy
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_created_by
)),
createdBy
));
setCreatedName
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_created_name
)),
createdName
));
setCreatedTime
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_created_time
)),
createdTime
));
setUpdatedBy
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_updated_by
)),
updatedBy
));
setUpdatedName
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_updated_name
)),
updatedName
));
setUpdatedTime
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_updated_time
)),
updatedTime
));
}
/**
* set the value to Map.
*/
@Override
public
Map
toMap
()
{
Map
map
=
new
HashMap
();
map
.
put
(
FIELD_id
,
StringUtils
.
toString
(
id
,
eiMetadata
.
getMeta
(
FIELD_id
)));
map
.
put
(
FIELD_mat_id
,
StringUtils
.
toString
(
matId
,
eiMetadata
.
getMeta
(
FIELD_mat_id
)));
map
.
put
(
FIELD_order_id
,
StringUtils
.
toString
(
orderId
,
eiMetadata
.
getMeta
(
FIELD_order_id
)));
map
.
put
(
FIELD_order_detail_id
,
StringUtils
.
toString
(
orderDetailId
,
eiMetadata
.
getMeta
(
FIELD_order_detail_id
)));
map
.
put
(
FIELD_tech_flow_id
,
StringUtils
.
toString
(
techFlowId
,
eiMetadata
.
getMeta
(
FIELD_tech_flow_id
)));
map
.
put
(
FIELD_tech_flow_name
,
StringUtils
.
toString
(
techFlowName
,
eiMetadata
.
getMeta
(
FIELD_tech_flow_name
)));
map
.
put
(
FIELD_invent_process_id
,
StringUtils
.
toString
(
inventProcessId
,
eiMetadata
.
getMeta
(
FIELD_invent_process_id
)));
map
.
put
(
FIELD_process_code
,
StringUtils
.
toString
(
processCode
,
eiMetadata
.
getMeta
(
FIELD_process_code
)));
map
.
put
(
FIELD_process_name
,
StringUtils
.
toString
(
processName
,
eiMetadata
.
getMeta
(
FIELD_process_name
)));
map
.
put
(
FIELD_process_order
,
StringUtils
.
toString
(
processOrder
,
eiMetadata
.
getMeta
(
FIELD_process_order
)));
map
.
put
(
FIELD_company_code
,
StringUtils
.
toString
(
companyCode
,
eiMetadata
.
getMeta
(
FIELD_company_code
)));
map
.
put
(
FIELD_company_name
,
StringUtils
.
toString
(
companyName
,
eiMetadata
.
getMeta
(
FIELD_company_name
)));
map
.
put
(
FIELD_dep_code
,
StringUtils
.
toString
(
depCode
,
eiMetadata
.
getMeta
(
FIELD_dep_code
)));
map
.
put
(
FIELD_dep_name
,
StringUtils
.
toString
(
depName
,
eiMetadata
.
getMeta
(
FIELD_dep_name
)));
map
.
put
(
FIELD_proj_code
,
StringUtils
.
toString
(
projCode
,
eiMetadata
.
getMeta
(
FIELD_proj_code
)));
map
.
put
(
FIELD_proj_name
,
StringUtils
.
toString
(
projName
,
eiMetadata
.
getMeta
(
FIELD_proj_name
)));
map
.
put
(
FIELD_task_code
,
StringUtils
.
toString
(
taskCode
,
eiMetadata
.
getMeta
(
FIELD_task_code
)));
map
.
put
(
FIELD_product_type
,
StringUtils
.
toString
(
productType
,
eiMetadata
.
getMeta
(
FIELD_product_type
)));
map
.
put
(
FIELD_product_code
,
StringUtils
.
toString
(
productCode
,
eiMetadata
.
getMeta
(
FIELD_product_code
)));
map
.
put
(
FIELD_product_name
,
StringUtils
.
toString
(
productName
,
eiMetadata
.
getMeta
(
FIELD_product_name
)));
map
.
put
(
FIELD_plan_start_date
,
StringUtils
.
toString
(
planStartDate
,
eiMetadata
.
getMeta
(
FIELD_plan_start_date
)));
map
.
put
(
FIELD_plan_end_date
,
StringUtils
.
toString
(
planEndDate
,
eiMetadata
.
getMeta
(
FIELD_plan_end_date
)));
map
.
put
(
FIELD_factory_code
,
StringUtils
.
toString
(
factoryCode
,
eiMetadata
.
getMeta
(
FIELD_factory_code
)));
map
.
put
(
FIELD_factory_name
,
StringUtils
.
toString
(
factoryName
,
eiMetadata
.
getMeta
(
FIELD_factory_name
)));
map
.
put
(
FIELD_group_code
,
StringUtils
.
toString
(
groupCode
,
eiMetadata
.
getMeta
(
FIELD_group_code
)));
map
.
put
(
FIELD_group_name
,
StringUtils
.
toString
(
groupName
,
eiMetadata
.
getMeta
(
FIELD_group_name
)));
map
.
put
(
FIELD_complete_date
,
StringUtils
.
toString
(
completeDate
,
eiMetadata
.
getMeta
(
FIELD_complete_date
)));
map
.
put
(
FIELD_quantity
,
StringUtils
.
toString
(
quantity
,
eiMetadata
.
getMeta
(
FIELD_quantity
)));
map
.
put
(
FIELD_finish_quantity
,
StringUtils
.
toString
(
finishQuantity
,
eiMetadata
.
getMeta
(
FIELD_finish_quantity
)));
map
.
put
(
FIELD_unfinish_quantity
,
StringUtils
.
toString
(
unfinishQuantity
,
eiMetadata
.
getMeta
(
FIELD_unfinish_quantity
)));
map
.
put
(
FIELD_single_weight
,
StringUtils
.
toString
(
singleWeight
,
eiMetadata
.
getMeta
(
FIELD_single_weight
)));
map
.
put
(
FIELD_total_weight
,
StringUtils
.
toString
(
totalWeight
,
eiMetadata
.
getMeta
(
FIELD_total_weight
)));
map
.
put
(
FIELD_finish_weight
,
StringUtils
.
toString
(
finishWeight
,
eiMetadata
.
getMeta
(
FIELD_finish_weight
)));
map
.
put
(
FIELD_unfinish_weight
,
StringUtils
.
toString
(
unfinishWeight
,
eiMetadata
.
getMeta
(
FIELD_unfinish_weight
)));
map
.
put
(
FIELD_account_code
,
StringUtils
.
toString
(
accountCode
,
eiMetadata
.
getMeta
(
FIELD_account_code
)));
map
.
put
(
FIELD_created_by
,
StringUtils
.
toString
(
createdBy
,
eiMetadata
.
getMeta
(
FIELD_created_by
)));
map
.
put
(
FIELD_created_name
,
StringUtils
.
toString
(
createdName
,
eiMetadata
.
getMeta
(
FIELD_created_name
)));
map
.
put
(
FIELD_created_time
,
StringUtils
.
toString
(
createdTime
,
eiMetadata
.
getMeta
(
FIELD_created_time
)));
map
.
put
(
FIELD_updated_by
,
StringUtils
.
toString
(
updatedBy
,
eiMetadata
.
getMeta
(
FIELD_updated_by
)));
map
.
put
(
FIELD_updated_name
,
StringUtils
.
toString
(
updatedName
,
eiMetadata
.
getMeta
(
FIELD_updated_name
)));
map
.
put
(
FIELD_updated_time
,
StringUtils
.
toString
(
updatedTime
,
eiMetadata
.
getMeta
(
FIELD_updated_time
)));
return
map
;
}
}
\ No newline at end of file
src/main/java/com/baosight/hggp/hg/sc/service/ServiceHGSC001.java
View file @
4853573f
...
...
@@ -155,6 +155,8 @@ public class ServiceHGSC001 extends ServiceBase {
AssertUtils
.
isEmpty
(
hgsc001
.
getPermissStartDate
(),
"请选择准许开工日期!"
);
AssertUtils
.
isEmpty
(
hgsc001
.
getStartDate
(),
"请选择开工日期!"
);
AssertUtils
.
isEmpty
(
hgsc001
.
getEndDate
(),
"请选择完工日期!"
);
AssertUtils
.
isTrue
(
DateUtil
.
toDate
(
hgsc001
.
getEndDate
(),
DateUtil
.
DATE10_PATTERN
).
compareTo
(
DateUtil
.
toDate
(
hgsc001
.
getStartDate
(),
DateUtil
.
DATE10_PATTERN
))>
0
,
"完工日期不能大于开工日期!"
);
AssertUtils
.
isNull
(
hgsc001
.
getProjStatus
(),
"请选择项目状态!"
);
AssertUtils
.
isEmpty
(
hgsc001
.
getContractWorkTxt
(),
"请填写合同工作量!"
);
...
...
src/main/java/com/baosight/hggp/hg/sc/service/ServiceHGSC006C.java
0 → 100644
View file @
4853573f
package
com
.
baosight
.
hggp
.
hg
.
sc
.
service
;
import
com.baosight.hggp.aspect.annotation.OperationLogAnnotation
;
import
com.baosight.hggp.core.constant.CommonConstant
;
import
com.baosight.hggp.core.dao.DaoUtils
;
import
com.baosight.hggp.hg.constant.HGConstant
;
import
com.baosight.hggp.hg.sc.domain.HGSC006
;
import
com.baosight.hggp.hg.sc.domain.HGSC006A
;
import
com.baosight.hggp.hg.sc.domain.HGSC007
;
import
com.baosight.hggp.hg.sc.tools.HGSCTools
;
import
com.baosight.hggp.hg.xs.tools.HGXSTools
;
import
com.baosight.hggp.util.*
;
import
com.baosight.iplat4j.core.ei.EiConstant
;
import
com.baosight.iplat4j.core.ei.EiInfo
;
import
com.baosight.iplat4j.core.service.impl.ServiceBase
;
import
com.baosight.iplat4j.ed.util.SequenceGenerator
;
import
java.math.BigDecimal
;
import
java.util.Arrays
;
import
java.util.List
;
import
java.util.Map
;
/**
* 拆单派工
*
*/
public
class
ServiceHGSC006C
extends
ServiceBase
{
/**
* 画面初始化.
*
* @param inInfo
* @return
*/
@OperationLogAnnotation
(
operModul
=
"拆单派工"
,
operType
=
"查询"
,
operDesc
=
"生产订单-拆单派工-初始化"
)
public
EiInfo
initLoad
(
EiInfo
inInfo
)
{
try
{
Map
queryMap
=
EiInfoUtils
.
getFirstRow
(
inInfo
);
String
orderDetailId
=
MapUtils
.
getString
(
queryMap
,
HGSC006A
.
FIELD_id
);
HGSC006A
hgsc006A
=
HGSCTools
.
THGSC006A
.
getById
(
Long
.
valueOf
(
orderDetailId
));
inInfo
.
addBlock
(
CommonConstant
.
Field
.
DETAIL
).
addRow
(
hgsc006A
);
inInfo
.
addBlock
(
EiConstant
.
resultBlock
).
addBlockMeta
(
new
HGSC007
().
eiMetadata
);
}
catch
(
Exception
e
)
{
LogUtils
.
setMsg
(
inInfo
,
e
,
"初始化失败"
);
inInfo
.
setStatus
(
500
);
}
return
inInfo
;
}
/**
* 查询操作.
*
* @param inInfo
* @return
*/
@OperationLogAnnotation
(
operModul
=
"拆单派工"
,
operType
=
"查询"
,
operDesc
=
"生产订单-拆单派工-查询"
)
@Override
public
EiInfo
query
(
EiInfo
inInfo
)
{
try
{
inInfo
=
super
.
query
(
inInfo
,
HGSC007
.
QUERY
,
new
HGSC007
());
}
catch
(
Throwable
e
)
{
LogUtils
.
setDetailMsg
(
inInfo
,
e
,
"查询失败"
);
inInfo
.
setStatus
(
500
);
}
return
inInfo
;
}
/**
* 新增操作.
*
* @param inInfo
* @return
*/
@OperationLogAnnotation
(
operModul
=
"拆单派工"
,
operType
=
"新增"
,
operDesc
=
"生产订单-拆单派工A-新增操作"
)
public
EiInfo
save
(
EiInfo
inInfo
)
{
try
{
Map
detailMap
=
EiInfoUtils
.
getFirstRow
(
inInfo
,
CommonConstant
.
Field
.
DETAIL
);
String
orderCode
=
MapUtils
.
getString
(
detailMap
,
HGSC006A
.
FIELD_order_code
);
Long
orderDetailId
=
Long
.
valueOf
(
MapUtils
.
getString
(
detailMap
,
HGSC006A
.
FIELD_id
));
List
<
Map
>
resultRows
=
inInfo
.
getBlock
(
EiConstant
.
resultBlock
).
getRows
();
// 生产任务号
List
<
Long
>
taskIds
=
ObjectUtils
.
listKey
(
resultRows
,
HGSC007
.
FIELD_id
);
// 锁主单号
HGSCTools
.
THGSC006A
.
lock
(
orderDetailId
);
// 锁子单
HGSCTools
.
THGSC007
.
lock
(
taskIds
);
// 查询订单信息
HGSC006
hgsc006
=
HGSCTools
.
THGSC006
.
getByOrderCode
(
orderCode
);
HGSC006A
hgsc006A
=
HGSCTools
.
THGSC006A
.
getById
(
orderDetailId
);
// 查询任务信息
List
<
HGSC007
>
hgsc007List
=
HGSCTools
.
THGSC007
.
list
(
taskIds
);
// 写入数据
for
(
Map
resultRow
:
resultRows
)
{
HGSC007
hgsc007
=
new
HGSC007
();
hgsc007
.
fromMap
(
resultRow
);
if
(
hgsc007
.
getId
()
==
null
||
hgsc007
.
getId
()
==
0
)
{
this
.
add
(
hgsc006
,
hgsc006A
,
hgsc007
);
}
else
{
this
.
modify
(
hgsc006A
,
hgsc007
,
hgsc007List
);
}
}
inInfo
=
this
.
query
(
inInfo
);
// 刷新主订单信息
inInfo
=
this
.
refreshOrderInfo
(
inInfo
,
orderDetailId
);
inInfo
.
setStatus
(
EiConstant
.
STATUS_DEFAULT
);
inInfo
.
setMsg
(
"操作成功!本次对["
+
resultRows
.
size
()
+
"]条数据操作成功!"
);
}
catch
(
Exception
e
)
{
LogUtils
.
setMsg
(
inInfo
,
e
,
"新增失败"
);
inInfo
.
setStatus
(
500
);
}
return
inInfo
;
}
/**
* 新增
*
* @param hgsc006A
* @param hgsc007
*/
private
void
add
(
HGSC006
hgsc006
,
HGSC006A
hgsc006A
,
HGSC007
hgsc007
)
{
Long
orderDetailId
=
hgsc006A
.
getId
();
// 数据校验
AssertUtils
.
isEmpty
(
hgsc007
.
getFactoryCode
(),
"请选择厂区"
);
AssertUtils
.
isEmpty
(
hgsc007
.
getGroupCode
(),
"请选择生产组"
);
// 更新订单主表数量
HGSCTools
.
checkAssignedNum
(
orderDetailId
,
hgsc007
.
getQuantity
());
hgsc007
.
setTaskCode
(
SequenceGenerator
.
getNextSequence
(
HGConstant
.
SequenceId
.
HGSC007_TASCK_CODE
));
hgsc007
.
setOrderId
(
hgsc006
.
getId
());
hgsc007
.
setMatId
(
hgsc006
.
getMatId
());
hgsc007
.
setOrderDetailId
(
hgsc006A
.
getId
());
hgsc007
.
setTotalWeight
(
hgsc007
.
getSingleWeight
().
multiply
(
new
BigDecimal
(
hgsc007
.
getQuantity
())));
DaoUtils
.
insert
(
HGSC007
.
INSERT
,
hgsc007
);
}
/**
* 修改数据
*
* @param hgsc006A
* @param hgsc007
* @param hgsc007List
*/
private
void
modify
(
HGSC006A
hgsc006A
,
HGSC007
hgsc007
,
List
<
HGSC007
>
hgsc007List
)
{
Long
orderDetailId
=
hgsc006A
.
getId
();
// 数据校验
HGSC007
dbSc007
=
hgsc007List
.
stream
().
filter
(
o
->
o
.
getId
().
compareTo
(
hgsc007
.
getId
())==
0
).
findAny
().
get
();
AssertUtils
.
isGt
(
new
BigDecimal
(
dbSc007
.
getFinishQuantity
()),
new
BigDecimal
(
hgsc007
.
getQuantity
()),
String
.
format
(
"任务[%s]修改后的数量不能小于已完工的数量"
,
hgsc007
.
getTaskCode
()));
// 计算差异数量
Integer
diffNum
=
hgsc007
.
getQuantity
()
-
dbSc007
.
getQuantity
();
// 更新订单主表数量
HGSCTools
.
checkAssignedNum
(
orderDetailId
,
diffNum
);
// 更新子单
hgsc007
.
setTotalWeight
(
hgsc007
.
getSingleWeight
().
multiply
(
new
BigDecimal
(
hgsc007
.
getQuantity
())));
DaoUtils
.
update
(
HGSC007
.
UPDATE
,
dbSc007
);
}
/**
* 删除操作.
*
* @param inInfo
* @return
*/
@OperationLogAnnotation
(
operModul
=
"拆单派工"
,
operType
=
"删除"
,
operDesc
=
"生产订单-拆单派工A-删除操作"
)
public
EiInfo
delete
(
EiInfo
inInfo
)
{
try
{
Map
detailMap
=
EiInfoUtils
.
getFirstRow
(
inInfo
,
CommonConstant
.
Field
.
DETAIL
);
Long
orderDetailId
=
Long
.
valueOf
(
MapUtils
.
getString
(
detailMap
,
HGSC006A
.
FIELD_id
));
List
<
Map
>
resultRows
=
inInfo
.
getBlock
(
EiConstant
.
resultBlock
).
getRows
();
for
(
Map
resultRow
:
resultRows
)
{
HGSC007
hgsc007
=
new
HGSC007
();
hgsc007
.
fromMap
(
resultRow
);
HGSC007
dbsc007
=
HGSCTools
.
THGSC007
.
getById
(
hgsc007
.
getId
());
AssertUtils
.
isGt
(
new
BigDecimal
(
dbsc007
.
getFinishQuantity
()),
BigDecimal
.
ZERO
,
String
.
format
(
"任务[%s]已存在完工数量不能删除"
,
dbsc007
.
getTaskCode
()));
// 更新订单主表数量
HGSCTools
.
checkAssignedNum
(
orderDetailId
,
-
hgsc007
.
getQuantity
());
// 删除子单
DaoUtils
.
update
(
HGSC007
.
DELETE
,
hgsc007
);
}
inInfo
=
this
.
query
(
inInfo
);
// 刷新主订单信息
inInfo
=
this
.
refreshOrderInfo
(
inInfo
,
orderDetailId
);
inInfo
.
setStatus
(
EiConstant
.
STATUS_DEFAULT
);
inInfo
.
setMsg
(
"操作成功!本次对["
+
resultRows
.
size
()
+
"]条数据删除成功!"
);
}
catch
(
Exception
e
)
{
LogUtils
.
setMsg
(
inInfo
,
e
,
"删除失败"
);
inInfo
.
setStatus
(
500
);
}
return
inInfo
;
}
/**
* 刷新主订单信息
*
* @param inInfo
* @return
*/
private
EiInfo
refreshOrderInfo
(
EiInfo
inInfo
,
Long
orderDetailId
)
{
HGSC006A
hgsc006A
=
HGSCTools
.
THGSC006A
.
getById
(
orderDetailId
);
inInfo
.
addBlock
(
CommonConstant
.
Field
.
DETAIL
).
addRow
(
hgsc006A
);
return
inInfo
;
}
}
src/main/java/com/baosight/hggp/hg/sc/sql/HGSC005A.xml
View file @
4853573f
...
...
@@ -115,6 +115,18 @@
<isNotEmpty
prepend=
" AND "
property=
"unfinishQuantity"
>
unfinish_quantity = #unfinishQuantity#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"singleWeight"
>
single_weight = #singleWeight#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"totalWeight"
>
total_weight = #totalWeight#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"finishWeight"
>
finish_weight = #finishWeight#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"unfinishWeight"
>
unfinish_weight = #unfinishWeight#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"accountCode"
>
account_code = #accountCode#
</isNotEmpty>
...
...
@@ -152,8 +164,8 @@
invent_process_id as "inventProcessId",
<!-- 存货工序ID,对应HGPZ005A.id -->
process_code as "processCode",
<!-- 工序编码 -->
process_name as "processName",
<!-- 工序名称 -->
process_order as "processOrder",
<!-- 加工顺序 -->
company_code as "companyCode",
<!-- 公司编码 -->
process_order as "processOrder",
<!-- 加工顺序 -->
company_name as "companyName",
<!-- 公司名称 -->
dep_code as "depCode",
<!-- 部门编码 -->
dep_name as "depName",
<!-- 部门名称 -->
...
...
@@ -169,6 +181,10 @@
quantity as "quantity",
<!-- 数量 -->
finish_quantity as "finishQuantity",
<!-- 完工数量 -->
unfinish_quantity as "unfinishQuantity",
<!-- 未完工数量 -->
single_weight as "singleWeight",
<!-- 单重 -->
total_weight as "totalWeight",
<!-- 总重 -->
finish_weight as "finishWeight",
<!-- 完工重量 -->
unfinish_weight as "unfinishWeight",
<!-- 未完工重量 -->
account_code as "accountCode",
<!-- 帐套 -->
created_by as "createdBy",
<!-- 创建人 -->
created_name as "createdName",
<!-- 创建人名称 -->
...
...
@@ -183,7 +199,7 @@
$orderBy$
</isNotEmpty>
<isEmpty
property=
"orderBy"
>
product_type asc ,plan_start_date
asc
id
asc
</isEmpty>
</dynamic>
...
...
@@ -213,12 +229,18 @@
<isNotEmpty prepend=" AND " property="inventProcessId">
invent_process_id = #inventProcessId#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="processCode">
process_code = #processCode#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="processName">
process_name = #processName#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="companyCode">
company_code = #companyCode#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="processOrder">
process_order = #processOrder#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="companyName">
company_name = #companyName#
</isNotEmpty>
...
...
@@ -264,6 +286,18 @@
<isNotEmpty prepend=" AND " property="unfinishQuantity">
unfinish_quantity = #unfinishQuantity#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="singleWeight">
single_weight = #singleWeight#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="totalWeight">
total_weight = #totalWeight#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="finishWeight">
finish_weight = #finishWeight#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="unfinishWeight">
unfinish_weight = #unfinishWeight#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="accountCode">
account_code = #accountCode#
</isNotEmpty>
...
...
@@ -294,10 +328,10 @@
tech_flow_id,
<!-- 工艺流程ID -->
tech_flow_name,
<!-- 工艺流程名称 -->
invent_process_id,
<!-- 存货工序ID,对应HGPZ005A.id -->
process_code,
<!-- 工序
名称
-->
process_code,
<!-- 工序
编码
-->
process_name,
<!-- 工序名称 -->
process_order,
<!-- 工序名称 -->
company_code,
<!-- 公司编码 -->
process_order,
<!-- 加工顺序 -->
company_name,
<!-- 公司名称 -->
dep_code,
<!-- 部门编码 -->
dep_name,
<!-- 部门名称 -->
...
...
@@ -313,6 +347,10 @@
quantity,
<!-- 数量 -->
finish_quantity,
<!-- 完工数量 -->
unfinish_quantity,
<!-- 未完工数量 -->
single_weight,
<!-- 单重 -->
total_weight,
<!-- 总重 -->
finish_weight,
<!-- 完工重量 -->
unfinish_weight,
<!-- 未完工重量 -->
account_code,
<!-- 帐套 -->
created_by,
<!-- 创建人 -->
created_name,
<!-- 创建人名称 -->
...
...
@@ -321,7 +359,7 @@
updated_name,
<!-- 修改人名称 -->
updated_time
<!-- 更新时间 -->
)
VALUES (#id#, #matId#, #matDetailId#, #techFlowId#, #techFlowName#, #inventProcessId#, #processCode#, #processName#, #
processOrder#, #companyCode#, #companyName#, #depCode#, #depName#, #projCode#, #projName#, #planCode#, #productType#, #productCode#, #productName#, #finishDate#, #planStartDate#, #planEndDate#, #quantity#, #finishQuantity#, #unfinishQuantity
#, #accountCode#, #createdBy#, #createdName#, #createdTime#, #updatedBy#, #updatedName#, #updatedTime#)
VALUES (#id#, #matId#, #matDetailId#, #techFlowId#, #techFlowName#, #inventProcessId#, #processCode#, #processName#, #
companyCode#, #processOrder#, #companyName#, #depCode#, #depName#, #projCode#, #projName#, #planCode#, #productType#, #productCode#, #productName#, #finishDate#, #planStartDate#, #planEndDate#, #quantity#, #finishQuantity#, #unfinishQuantity#, #singleWeight#, #totalWeight#, #finishWeight#, #unfinishWeight
#, #accountCode#, #createdBy#, #createdName#, #createdTime#, #updatedBy#, #updatedName#, #updatedTime#)
</insert>
<delete
id=
"delete"
>
...
...
@@ -337,10 +375,10 @@
tech_flow_id = #techFlowId#,
<!-- 工艺流程ID -->
tech_flow_name = #techFlowName#,
<!-- 工艺流程名称 -->
invent_process_id = #inventProcessId#,
<!-- 存货工序ID,对应HGPZ005A.id -->
process_code = #processCode#,
<!-- 工序
名称
-->
process_code = #processCode#,
<!-- 工序
编码
-->
process_name = #processName#,
<!-- 工序名称 -->
process_order = #processOrder#,
<!-- 工序名称 -->
company_code = #companyCode#,
<!-- 公司编码 -->
process_order = #processOrder#,
<!-- 加工顺序 -->
company_name = #companyName#,
<!-- 公司名称 -->
dep_code = #depCode#,
<!-- 部门编码 -->
dep_name = #depName#,
<!-- 部门名称 -->
...
...
@@ -356,6 +394,10 @@
quantity = #quantity#,
<!-- 数量 -->
finish_quantity = #finishQuantity#,
<!-- 完工数量 -->
unfinish_quantity = #unfinishQuantity#,
<!-- 未完工数量 -->
single_weight = #singleWeight#,
<!-- 单重 -->
total_weight = #totalWeight#,
<!-- 总重 -->
finish_weight = #finishWeight#,
<!-- 完工重量 -->
unfinish_weight = #unfinishWeight#,
<!-- 未完工重量 -->
account_code = #accountCode#,
<!-- 帐套 -->
created_by = #createdBy#,
<!-- 创建人 -->
created_name = #createdName#,
<!-- 创建人名称 -->
...
...
src/main/java/com/baosight/hggp/hg/sc/sql/HGSC006.xml
View file @
4853573f
...
...
@@ -228,4 +228,22 @@
id = #id#
</update>
<!-- 公共修改字段 -->
<sql
id=
"updateRevise"
>
updated_by = #updatedBy#,
<!-- 修改人 -->
updated_name = #updatedName#,
<!-- 修改人名称 -->
updated_time = #updatedTime#
<!-- 修改时间 -->
</sql>
<update
id=
"update_assign_status"
>
UPDATE ${hggpSchema}.HGSC006
SET
assign_status = #assignStatus#,
<!-- 派工状态 0待派工;1部分派工;2已派工 -->
assign_quantity = #assignQuantity#,
<!-- 派工数量 -->
unassign_quantity = #unassignQuantity#,
<!-- 未派工数量 -->
<include
refid=
"updateRevise"
/>
WHERE order_code = #orderCode#
</update>
</sqlMap>
src/main/java/com/baosight/hggp/hg/sc/sql/HGSC006A.xml
View file @
4853573f
...
...
@@ -117,6 +117,21 @@
<isNotEmpty
prepend=
" AND "
property=
"unassignQuantity"
>
unassign_quantity = #unassignQuantity#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"singleWeight"
>
single_weight = #singleWeight#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"totalWeight"
>
total_weight = #totalWeight#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"assignWeight"
>
assign_weight = #assignWeight#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"unassignWeight"
>
unassign_weight = #unassignWeight#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"assignStatus"
>
assign_status = #assignStatus#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"accountCode"
>
account_code = #accountCode#
</isNotEmpty>
...
...
@@ -140,49 +155,97 @@
</isNotEmpty>
</sql>
<select
id=
"query_other"
parameterClass=
"java.util.HashMap"
resultClass=
"com.baosight.hggp.hg.sc.domain.HGSC006A"
>
SELECT
id as "id",
plan_id as "planId",
<!-- 生产计划ID -->
plan_detail_id as "planDetailId",
<!-- 生产计划明细ID -->
tech_flow_id as "techFlowId",
<!-- 工艺流程ID -->
tech_flow_name as "techFlowName",
<!-- 工艺流程名称 -->
invent_process_id as "inventProcessId",
<!-- 存货工序ID,对应HGPZ005A.id -->
process_code as "processCode",
<!-- 工序编码 -->
process_name as "processName",
<!-- 工序名称 -->
process_order as "processOrder",
<!-- 加工顺序 -->
company_code as "companyCode",
<!-- 公司编码 -->
company_name as "companyName",
<!-- 公司名称 -->
dep_code as "depCode",
<!-- 部门编码 -->
dep_name as "depName",
<!-- 部门名称 -->
proj_code as "projCode",
<!-- 项目编码 -->
proj_name as "projName",
<!-- 项目名称 -->
order_code as "orderCode",
<!-- 订单编码 -->
product_type as "productType",
<!-- 产品类型 -->
product_code as "productCode",
<!-- 产品编号 -->
product_name as "productName",
<!-- 产品名称 -->
plan_start_date as "planStartDate",
<!-- 计划开始日期 -->
plan_end_date as "planEndDate",
<!-- 计划结束日期 -->
quantity as "quantity",
<!-- 数量 -->
assign_quantity as "assignQuantity",
<!-- 派工数量 -->
unassign_quantity as "unassignQuantity",
<!-- 未派工数量 -->
single_weight as "singleWeight",
<!-- 单重 -->
total_weight as "totalWeight",
<!-- 总重 -->
assign_weight as "assignWeight",
<!-- 派工重量 -->
unassign_weight as "unassignWeight",
<!-- 未派工重量 -->
assign_status as "assignStatus",
<!-- 派工状态 0待派工;1部分派工;2已派工 -->
account_code as "accountCode",
<!-- 帐套 -->
created_by as "createdBy",
<!-- 创建人 -->
created_name as "createdName",
<!-- 创建人名称 -->
created_time as "createdTime",
<!-- 创建时间 -->
updated_by as "updatedBy",
<!-- 更新人 -->
updated_name as "updatedName",
<!-- 修改人名称 -->
updated_time as "updatedTime"
<!-- 更新时间 -->
FROM ${hggpSchema}.HGSC006A
WHERE order_code = #orderCode#
AND ID != #id#
</select>
<select
id=
"query"
parameterClass=
"java.util.HashMap"
resultClass=
"com.baosight.hggp.hg.sc.domain.HGSC006A"
>
SELECT
id as "id",
plan_id as "planId",
<!-- 生产计划ID -->
plan_detail_id as "planDetailId",
<!-- 生产计划明细ID -->
tech_flow_id as "techFlowId",
<!-- 工艺流程ID -->
tech_flow_name as "techFlowName",
<!-- 工艺流程名称 -->
invent_process_id as "inventProcessId",
<!-- 存货工序ID,对应HGPZ005A.id -->
process_code as "processCode",
<!-- 工序编码 -->
process_name as "processName",
<!-- 工序名称 -->
process_order as "processOrder",
<!-- 加工顺序 -->
company_code as "companyCode",
<!-- 公司编码 -->
company_name as "companyName",
<!-- 公司名称 -->
dep_code as "depCode",
<!-- 部门编码 -->
dep_name as "depName",
<!-- 部门名称 -->
proj_code as "projCode",
<!-- 项目编码 -->
proj_name as "projName",
<!-- 项目名称 -->
order_code as "orderCode",
<!-- 订单编码 -->
product_type as "productType",
<!-- 产品类型 -->
product_code as "productCode",
<!-- 产品编号 -->
product_name as "productName",
<!-- 产品名称 -->
assign_date as "assignDate",
<!-- 派工日期 -->
plan_start_date as "planStartDate",
<!-- 计划开始日期 -->
plan_end_date as "planEndDate",
<!-- 计划结束日期 -->
quantity as "quantity",
<!-- 数量 -->
assign_quantity as "assignQuantity",
<!-- 派工数量 -->
unassign_quantity as "unassignQuantity",
<!-- 未派工数量 -->
account_code as "accountCode",
<!-- 帐套 -->
created_by as "createdBy",
<!-- 创建人 -->
created_name as "createdName",
<!-- 创建人名称 -->
created_time as "createdTime",
<!-- 创建时间 -->
updated_by as "updatedBy",
<!-- 更新人 -->
updated_name as "updatedName",
<!-- 修改人名称 -->
updated_time as "updatedTime"
<!-- 更新时间 -->
id as "id",
plan_id as "planId",
<!-- 生产计划ID -->
plan_detail_id as "planDetailId",
<!-- 生产计划明细ID -->
tech_flow_id as "techFlowId",
<!-- 工艺流程ID -->
tech_flow_name as "techFlowName",
<!-- 工艺流程名称 -->
invent_process_id as "inventProcessId",
<!-- 存货工序ID,对应HGPZ005A.id -->
process_code as "processCode",
<!-- 工序编码 -->
process_name as "processName",
<!-- 工序名称 -->
process_order as "processOrder",
<!-- 加工顺序 -->
company_code as "companyCode",
<!-- 公司编码 -->
company_name as "companyName",
<!-- 公司名称 -->
dep_code as "depCode",
<!-- 部门编码 -->
dep_name as "depName",
<!-- 部门名称 -->
proj_code as "projCode",
<!-- 项目编码 -->
proj_name as "projName",
<!-- 项目名称 -->
order_code as "orderCode",
<!-- 订单编码 -->
product_type as "productType",
<!-- 产品类型 -->
product_code as "productCode",
<!-- 产品编号 -->
product_name as "productName",
<!-- 产品名称 -->
plan_start_date as "planStartDate",
<!-- 计划开始日期 -->
plan_end_date as "planEndDate",
<!-- 计划结束日期 -->
quantity as "quantity",
<!-- 数量 -->
assign_quantity as "assignQuantity",
<!-- 派工数量 -->
unassign_quantity as "unassignQuantity",
<!-- 未派工数量 -->
single_weight as "singleWeight",
<!-- 单重 -->
total_weight as "totalWeight",
<!-- 总重 -->
assign_weight as "assignWeight",
<!-- 派工重量 -->
unassign_weight as "unassignWeight",
<!-- 未派工重量 -->
assign_status as "assignStatus",
<!-- 派工状态 0待派工;1部分派工;2已派工 -->
account_code as "accountCode",
<!-- 帐套 -->
created_by as "createdBy",
<!-- 创建人 -->
created_name as "createdName",
<!-- 创建人名称 -->
created_time as "createdTime",
<!-- 创建时间 -->
updated_by as "updatedBy",
<!-- 更新人 -->
updated_name as "updatedName",
<!-- 修改人名称 -->
updated_time as "updatedTime"
<!-- 更新时间 -->
FROM ${hggpSchema}.HGSC006A WHERE 1=1
<include
refid=
"condition"
/>
<include
refid=
"condition"
/>
<dynamic
prepend=
"ORDER BY"
>
<isNotEmpty
property=
"orderBy"
>
$orderBy$
$orderBy$
</isNotEmpty>
<isEmpty
property=
"orderBy"
>
id asc
id asc
</isEmpty>
</dynamic>
...
...
@@ -190,7 +253,7 @@
<select
id=
"count"
resultClass=
"int"
>
SELECT COUNT(*) FROM ${hggpSchema}.HGSC006A WHERE 1=1
<include
refid=
"condition"
/>
<include
refid=
"condition"
/>
</select>
<!--
...
...
@@ -251,9 +314,6 @@
<isNotEmpty prepend=" AND " property="productName">
product_name = #productName#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="assignDate">
assign_date = #assignDate#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="planStartDate">
plan_start_date = #planStartDate#
</isNotEmpty>
...
...
@@ -269,6 +329,21 @@
<isNotEmpty prepend=" AND " property="unassignQuantity">
unassign_quantity = #unassignQuantity#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="singleWeight">
single_weight = #singleWeight#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="totalWeight">
total_weight = #totalWeight#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="assignWeight">
assign_weight = #assignWeight#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="unassignWeight">
unassign_weight = #unassignWeight#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="assignStatus">
assign_status = #assignStatus#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="accountCode">
account_code = #accountCode#
</isNotEmpty>
...
...
@@ -294,39 +369,43 @@
<insert
id=
"insert"
>
INSERT INTO ${hggpSchema}.HGSC006A (id,
plan_id,
<!-- 生产计划ID -->
plan_detail_id,
<!-- 生产计划明细ID -->
tech_flow_id,
<!-- 工艺流程ID -->
tech_flow_name,
<!-- 工艺流程名称 -->
invent_process_id,
<!-- 存货工序ID,对应HGPZ005A.id -->
process_code,
<!-- 工序编码 -->
process_name,
<!-- 工序名称 -->
process_order,
<!-- 加工顺序 -->
company_code,
<!-- 公司编码 -->
company_name,
<!-- 公司名称 -->
dep_code,
<!-- 部门编码 -->
dep_name,
<!-- 部门名称 -->
proj_code,
<!-- 项目编码 -->
proj_name,
<!-- 项目名称 -->
order_code,
<!-- 订单编码 -->
product_type,
<!-- 产品类型 -->
product_code,
<!-- 产品编号 -->
product_name,
<!-- 产品名称 -->
assign_date,
<!-- 派工日期 -->
plan_start_date,
<!-- 计划开始日期 -->
plan_end_date,
<!-- 计划结束日期 -->
quantity,
<!-- 数量 -->
assign_quantity,
<!-- 派工数量 -->
unassign_quantity,
<!-- 未派工数量 -->
account_code,
<!-- 帐套 -->
created_by,
<!-- 创建人 -->
created_name,
<!-- 创建人名称 -->
created_time,
<!-- 创建时间 -->
updated_by,
<!-- 更新人 -->
updated_name,
<!-- 修改人名称 -->
updated_time
<!-- 更新时间 -->
)
VALUES (#id#, #planId#, #planDetailId#, #techFlowId#, #techFlowName#, #inventProcessId#, #processCode#, #processName#, #processOrder#, #companyCode#, #companyName#, #depCode#, #depName#, #projCode#, #projName#, #orderCode#, #productType#, #productCode#, #productName#, #assignDate#, #planStartDate#, #planEndDate#, #quantity#, #assignQuantity#, #unassignQuantity#, #accountCode#, #createdBy#, #createdName#, #createdTime#, #updatedBy#, #updatedName#, #updatedTime#)
plan_id,
<!-- 生产计划ID -->
plan_detail_id,
<!-- 生产计划明细ID -->
tech_flow_id,
<!-- 工艺流程ID -->
tech_flow_name,
<!-- 工艺流程名称 -->
invent_process_id,
<!-- 存货工序ID,对应HGPZ005A.id -->
process_code,
<!-- 工序编码 -->
process_name,
<!-- 工序名称 -->
process_order,
<!-- 加工顺序 -->
company_code,
<!-- 公司编码 -->
company_name,
<!-- 公司名称 -->
dep_code,
<!-- 部门编码 -->
dep_name,
<!-- 部门名称 -->
proj_code,
<!-- 项目编码 -->
proj_name,
<!-- 项目名称 -->
order_code,
<!-- 订单编码 -->
product_type,
<!-- 产品类型 -->
product_code,
<!-- 产品编号 -->
product_name,
<!-- 产品名称 -->
plan_start_date,
<!-- 计划开始日期 -->
plan_end_date,
<!-- 计划结束日期 -->
quantity,
<!-- 数量 -->
assign_quantity,
<!-- 派工数量 -->
unassign_quantity,
<!-- 未派工数量 -->
single_weight,
<!-- 单重 -->
total_weight,
<!-- 总重 -->
assign_weight,
<!-- 派工重量 -->
unassign_weight,
<!-- 未派工重量 -->
assign_status,
<!-- 派工状态 0待派工;1部分派工;2已派工 -->
account_code,
<!-- 帐套 -->
created_by,
<!-- 创建人 -->
created_name,
<!-- 创建人名称 -->
created_time,
<!-- 创建时间 -->
updated_by,
<!-- 更新人 -->
updated_name,
<!-- 修改人名称 -->
updated_time
<!-- 更新时间 -->
)
VALUES (#id#, #planId#, #planDetailId#, #techFlowId#, #techFlowName#, #inventProcessId#, #processCode#, #processName#, #processOrder#, #companyCode#, #companyName#, #depCode#, #depName#, #projCode#, #projName#, #orderCode#, #productType#, #productCode#, #productName#, #planStartDate#, #planEndDate#, #quantity#, #assignQuantity#, #unassignQuantity#, #singleWeight#, #totalWeight#, #assignWeight#, #unassignWeight#, #assignStatus#, #accountCode#, #createdBy#, #createdName#, #createdTime#, #updatedBy#, #updatedName#, #updatedTime#)
</insert>
<delete
id=
"delete"
>
...
...
@@ -337,39 +416,73 @@
<update
id=
"update"
>
UPDATE ${hggpSchema}.HGSC006A
SET
plan_id = #planId#,
<!-- 生产计划ID -->
plan_detail_id = #planDetailId#,
<!-- 生产计划明细ID -->
tech_flow_id = #techFlowId#,
<!-- 工艺流程ID -->
tech_flow_name = #techFlowName#,
<!-- 工艺流程名称 -->
invent_process_id = #inventProcessId#,
<!-- 存货工序ID,对应HGPZ005A.id -->
process_code = #processCode#,
<!-- 工序编码 -->
process_name = #processName#,
<!-- 工序名称 -->
process_order = #processOrder#,
<!-- 加工顺序 -->
company_code = #companyCode#,
<!-- 公司编码 -->
company_name = #companyName#,
<!-- 公司名称 -->
dep_code = #depCode#,
<!-- 部门编码 -->
dep_name = #depName#,
<!-- 部门名称 -->
proj_code = #projCode#,
<!-- 项目编码 -->
proj_name = #projName#,
<!-- 项目名称 -->
order_code = #orderCode#,
<!-- 订单编码 -->
product_type = #productType#,
<!-- 产品类型 -->
product_code = #productCode#,
<!-- 产品编号 -->
product_name = #productName#,
<!-- 产品名称 -->
assign_date = #assignDate#,
<!-- 派工日期 -->
plan_start_date = #planStartDate#,
<!-- 计划开始日期 -->
plan_end_date = #planEndDate#,
<!-- 计划结束日期 -->
quantity = #quantity#,
<!-- 数量 -->
assign_quantity = #assignQuantity#,
<!-- 派工数量 -->
unassign_quantity = #unassignQuantity#,
<!-- 未派工数量 -->
account_code = #accountCode#,
<!-- 帐套 -->
created_by = #createdBy#,
<!-- 创建人 -->
created_name = #createdName#,
<!-- 创建人名称 -->
created_time = #createdTime#,
<!-- 创建时间 -->
updated_by = #updatedBy#,
<!-- 更新人 -->
updated_name = #updatedName#,
<!-- 修改人名称 -->
updated_time = #updatedTime#
<!-- 更新时间 -->
WHERE
plan_id = #planId#,
<!-- 生产计划ID -->
plan_detail_id = #planDetailId#,
<!-- 生产计划明细ID -->
tech_flow_id = #techFlowId#,
<!-- 工艺流程ID -->
tech_flow_name = #techFlowName#,
<!-- 工艺流程名称 -->
invent_process_id = #inventProcessId#,
<!-- 存货工序ID,对应HGPZ005A.id -->
process_code = #processCode#,
<!-- 工序编码 -->
process_name = #processName#,
<!-- 工序名称 -->
process_order = #processOrder#,
<!-- 加工顺序 -->
company_code = #companyCode#,
<!-- 公司编码 -->
company_name = #companyName#,
<!-- 公司名称 -->
dep_code = #depCode#,
<!-- 部门编码 -->
dep_name = #depName#,
<!-- 部门名称 -->
proj_code = #projCode#,
<!-- 项目编码 -->
proj_name = #projName#,
<!-- 项目名称 -->
order_code = #orderCode#,
<!-- 订单编码 -->
product_type = #productType#,
<!-- 产品类型 -->
product_code = #productCode#,
<!-- 产品编号 -->
product_name = #productName#,
<!-- 产品名称 -->
plan_start_date = #planStartDate#,
<!-- 计划开始日期 -->
plan_end_date = #planEndDate#,
<!-- 计划结束日期 -->
quantity = #quantity#,
<!-- 数量 -->
assign_quantity = #assignQuantity#,
<!-- 派工数量 -->
unassign_quantity = #unassignQuantity#,
<!-- 未派工数量 -->
single_weight = #singleWeight#,
<!-- 单重 -->
total_weight = #totalWeight#,
<!-- 总重 -->
assign_weight = #assignWeight#,
<!-- 派工重量 -->
unassign_weight = #unassignWeight#,
<!-- 未派工重量 -->
assign_status = #assignStatus#,
<!-- 派工状态 0待派工;1部分派工;2已派工 -->
account_code = #accountCode#,
<!-- 帐套 -->
created_by = #createdBy#,
<!-- 创建人 -->
created_name = #createdName#,
<!-- 创建人名称 -->
created_time = #createdTime#,
<!-- 创建时间 -->
updated_by = #updatedBy#,
<!-- 更新人 -->
updated_name = #updatedName#,
<!-- 修改人名称 -->
updated_time = #updatedTime#
<!-- 更新时间 -->
WHERE
id = #id#
</update>
<!-- 行锁 -->
<update
id=
"lock"
>
UPDATE ${hggpSchema}.HGSC006A
SET CREATED_TIME = CREATED_TIME
WHERE 1=1
<isNotEmpty
prepend=
" AND "
property=
"id"
>
id = #id#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"ids"
>
id IN
<iterate
close=
")"
open=
"("
conjunction=
","
property=
"ids"
>
#ids[]#
</iterate>
</isNotEmpty>
</update>
<!-- 公共修改字段 -->
<sql
id=
"updateRevise"
>
updated_by = #updatedBy#,
<!-- 修改人 -->
updated_name = #updatedName#,
<!-- 修改人名称 -->
updated_time = #updatedTime#
<!-- 修改时间 -->
</sql>
<update
id=
"update_assign_num"
>
UPDATE ${hggpSchema}.HGSC006A
SET
assign_status = #assignStatus#,
<!-- 派工状态 0待派工;1部分派工;2已派工 -->
assign_quantity = #assignQuantity#,
<!-- 派工数量 -->
unassign_quantity = #unassignQuantity#,
<!-- 未派工数量 -->
<include
refid=
"updateRevise"
/>
WHERE id = #id#
</update>
</sqlMap>
src/main/java/com/baosight/hggp/hg/sc/sql/HGSC007.xml
0 → 100644
View file @
4853573f
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE sqlMap PUBLIC "-//ibatis.apache.org//DTD SQL Map 2.0//EN" "http://ibatis.apache.org/dtd/sql-map-2.dtd">
<!-- table information
Generate time : 2024-05-23 17:55:59
Version : 1.0
schema : hggp
tableName : HGSC007
id BIGINT NOT NULL primarykey,
order_id BIGINT NOT NULL,
order_detail_id BIGINT NOT NULL,
tech_flow_id BIGINT,
tech_flow_name BIGINT,
invent_process_id BIGINT,
process_code VARCHAR,
process_name VARCHAR,
process_order BIGINT,
company_code VARCHAR NOT NULL,
company_name VARCHAR NOT NULL,
dep_code VARCHAR,
dep_name VARCHAR,
proj_code VARCHAR,
proj_name VARCHAR,
task_code VARCHAR,
product_type TINYINT,
product_code VARCHAR,
product_name VARCHAR,
plan_start_date VARCHAR,
plan_end_date VARCHAR,
factory_code VARCHAR,
factory_name VARCHAR,
group_code VARCHAR,
group_name VARCHAR,
complete_date VARCHAR,
quantity TINYINT,
finish_quantity TINYINT,
unfinish_quantity TINYINT,
single_weight DECIMAL,
total_weight DECIMAL,
finish_weight DECIMAL,
unfinish_weight DECIMAL,
account_code VARCHAR NOT NULL,
created_by VARCHAR,
created_name VARCHAR,
created_time VARCHAR,
updated_by VARCHAR,
updated_name VARCHAR,
updated_time VARCHAR
-->
<sqlMap
namespace=
"HGSC007"
>
<sql
id=
"condition"
>
<isNotEmpty
prepend=
" AND "
property=
"id"
>
id = #id#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"matId"
>
mat_id = #matId#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"orderId"
>
order_id = #orderId#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"orderDetailId"
>
order_detail_id = #orderDetailId#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"techFlowId"
>
tech_flow_id = #techFlowId#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"techFlowName"
>
tech_flow_name = #techFlowName#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"inventProcessId"
>
invent_process_id = #inventProcessId#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"processCode"
>
process_code = #processCode#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"processName"
>
process_name = #processName#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"processOrder"
>
process_order = #processOrder#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"companyCode"
>
company_code = #companyCode#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"companyName"
>
company_name = #companyName#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"depCode"
>
dep_code = #depCode#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"depName"
>
dep_name = #depName#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"projCode"
>
proj_code = #projCode#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"projName"
>
proj_name = #projName#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"taskCode"
>
task_code = #taskCode#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"productType"
>
product_type = #productType#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"productCode"
>
product_code = #productCode#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"productName"
>
product_name = #productName#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"planStartDate"
>
plan_start_date = #planStartDate#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"planEndDate"
>
plan_end_date = #planEndDate#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"factoryCode"
>
factory_code = #factoryCode#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"factoryName"
>
factory_name = #factoryName#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"groupCode"
>
group_code = #groupCode#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"groupName"
>
group_name = #groupName#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"completeDate"
>
complete_date = #completeDate#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"quantity"
>
quantity = #quantity#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"finishQuantity"
>
finish_quantity = #finishQuantity#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"unfinishQuantity"
>
unfinish_quantity = #unfinishQuantity#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"singleWeight"
>
single_weight = #singleWeight#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"totalWeight"
>
total_weight = #totalWeight#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"finishWeight"
>
finish_weight = #finishWeight#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"unfinishWeight"
>
unfinish_weight = #unfinishWeight#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"accountCode"
>
account_code = #accountCode#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"createdBy"
>
created_by = #createdBy#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"createdName"
>
created_name = #createdName#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"createdTime"
>
created_time = #createdTime#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"updatedBy"
>
updated_by = #updatedBy#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"updatedName"
>
updated_name = #updatedName#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"updatedTime"
>
updated_time = #updatedTime#
</isNotEmpty>
</sql>
<select
id=
"query"
parameterClass=
"java.util.HashMap"
resultClass=
"com.baosight.hggp.hg.sc.domain.HGSC007"
>
SELECT
id as "id",
mat_id as "matId",
<!-- 物料清单ID -->
order_id as "orderId",
<!-- 生产计划ID -->
order_detail_id as "orderDetailId",
<!-- 生产计划明细ID -->
tech_flow_id as "techFlowId",
<!-- 工艺流程ID -->
tech_flow_name as "techFlowName",
<!-- 工艺流程名称 -->
invent_process_id as "inventProcessId",
<!-- 存货工序ID,对应HGPZ005A.id -->
process_code as "processCode",
<!-- 工序编码 -->
process_name as "processName",
<!-- 工序名称 -->
process_order as "processOrder",
<!-- 加工顺序 -->
company_code as "companyCode",
<!-- 公司编码 -->
company_name as "companyName",
<!-- 公司名称 -->
dep_code as "depCode",
<!-- 部门编码 -->
dep_name as "depName",
<!-- 部门名称 -->
proj_code as "projCode",
<!-- 项目编码 -->
proj_name as "projName",
<!-- 项目名称 -->
task_code as "taskCode",
<!-- 任务编码 -->
product_type as "productType",
<!-- 产品类型 -->
product_code as "productCode",
<!-- 产品编号 -->
product_name as "productName",
<!-- 产品名称 -->
plan_start_date as "planStartDate",
<!-- 计划开始日期 -->
plan_end_date as "planEndDate",
<!-- 计划结束日期 -->
factory_code as "factoryCode",
<!-- 工厂编号 -->
factory_name as "factoryName",
<!-- 工厂名称 -->
group_code as "groupCode",
<!-- 工作组编号 -->
group_name as "groupName",
<!-- 工作组名称 -->
complete_date as "completeDate",
<!-- 完工日期 -->
quantity as "quantity",
<!-- 数量 -->
finish_quantity as "finishQuantity",
<!-- 完工数量 -->
unfinish_quantity as "unfinishQuantity",
<!-- 未完工数量 -->
single_weight as "singleWeight",
<!-- 单重 -->
total_weight as "totalWeight",
<!-- 总重 -->
finish_weight as "finishWeight",
<!-- 完工重量 -->
unfinish_weight as "unfinishWeight",
<!-- 未完工重量 -->
account_code as "accountCode",
<!-- 帐套 -->
created_by as "createdBy",
<!-- 创建人 -->
created_name as "createdName",
<!-- 创建人名称 -->
created_time as "createdTime",
<!-- 创建时间 -->
updated_by as "updatedBy",
<!-- 更新人 -->
updated_name as "updatedName",
<!-- 修改人名称 -->
updated_time as "updatedTime"
<!-- 更新时间 -->
FROM ${hggpSchema}.HGSC007 WHERE 1=1
<include
refid=
"condition"
/>
<dynamic
prepend=
"ORDER BY"
>
<isNotEmpty
property=
"orderBy"
>
$orderBy$
</isNotEmpty>
<isEmpty
property=
"orderBy"
>
id asc
</isEmpty>
</dynamic>
</select>
<select
id=
"count"
resultClass=
"int"
>
SELECT COUNT(*) FROM ${hggpSchema}.HGSC007 WHERE 1=1
<include
refid=
"condition"
/>
</select>
<!--
<isNotEmpty prepend=" AND " property="id">
id = #id#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="matId">
mat_id = #matId#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="orderId">
order_id = #orderId#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="orderDetailId">
order_detail_id = #orderDetailId#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="techFlowId">
tech_flow_id = #techFlowId#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="techFlowName">
tech_flow_name = #techFlowName#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="inventProcessId">
invent_process_id = #inventProcessId#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="processCode">
process_code = #processCode#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="processName">
process_name = #processName#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="processOrder">
process_order = #processOrder#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="companyCode">
company_code = #companyCode#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="companyName">
company_name = #companyName#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="depCode">
dep_code = #depCode#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="depName">
dep_name = #depName#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="projCode">
proj_code = #projCode#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="projName">
proj_name = #projName#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="taskCode">
task_code = #taskCode#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="productType">
product_type = #productType#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="productCode">
product_code = #productCode#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="productName">
product_name = #productName#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="planStartDate">
plan_start_date = #planStartDate#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="planEndDate">
plan_end_date = #planEndDate#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="factoryCode">
factory_code = #factoryCode#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="factoryName">
factory_name = #factoryName#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="groupCode">
group_code = #groupCode#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="groupName">
group_name = #groupName#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="completeDate">
complete_date = #completeDate#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="quantity">
quantity = #quantity#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="finishQuantity">
finish_quantity = #finishQuantity#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="unfinishQuantity">
unfinish_quantity = #unfinishQuantity#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="singleWeight">
single_weight = #singleWeight#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="totalWeight">
total_weight = #totalWeight#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="finishWeight">
finish_weight = #finishWeight#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="unfinishWeight">
unfinish_weight = #unfinishWeight#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="accountCode">
account_code = #accountCode#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="createdBy">
created_by = #createdBy#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="createdName">
created_name = #createdName#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="createdTime">
created_time = #createdTime#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="updatedBy">
updated_by = #updatedBy#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="updatedName">
updated_name = #updatedName#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="updatedTime">
updated_time = #updatedTime#
</isNotEmpty>
-->
<insert
id=
"insert"
>
INSERT INTO ${hggpSchema}.HGSC007 (id,
mat_id,
<!-- 物料清单ID -->
order_id,
<!-- 生产计划ID -->
order_detail_id,
<!-- 生产计划明细ID -->
tech_flow_id,
<!-- 工艺流程ID -->
tech_flow_name,
<!-- 工艺流程名称 -->
invent_process_id,
<!-- 存货工序ID,对应HGPZ005A.id -->
process_code,
<!-- 工序编码 -->
process_name,
<!-- 工序名称 -->
process_order,
<!-- 加工顺序 -->
company_code,
<!-- 公司编码 -->
company_name,
<!-- 公司名称 -->
dep_code,
<!-- 部门编码 -->
dep_name,
<!-- 部门名称 -->
proj_code,
<!-- 项目编码 -->
proj_name,
<!-- 项目名称 -->
task_code,
<!-- 任务编码 -->
product_type,
<!-- 产品类型 -->
product_code,
<!-- 产品编号 -->
product_name,
<!-- 产品名称 -->
plan_start_date,
<!-- 计划开始日期 -->
plan_end_date,
<!-- 计划结束日期 -->
factory_code,
<!-- 工厂编号 -->
factory_name,
<!-- 工厂名称 -->
group_code,
<!-- 工作组编号 -->
group_name,
<!-- 工作组名称 -->
complete_date,
<!-- 完工日期 -->
quantity,
<!-- 数量 -->
finish_quantity,
<!-- 完工数量 -->
unfinish_quantity,
<!-- 未完工数量 -->
single_weight,
<!-- 单重 -->
total_weight,
<!-- 总重 -->
finish_weight,
<!-- 完工重量 -->
unfinish_weight,
<!-- 未完工重量 -->
account_code,
<!-- 帐套 -->
created_by,
<!-- 创建人 -->
created_name,
<!-- 创建人名称 -->
created_time,
<!-- 创建时间 -->
updated_by,
<!-- 更新人 -->
updated_name,
<!-- 修改人名称 -->
updated_time
<!-- 更新时间 -->
)
VALUES (#id#, #matId#, #orderId#, #orderDetailId#, #techFlowId#, #techFlowName#, #inventProcessId#, #processCode#, #processName#, #processOrder#, #companyCode#, #companyName#, #depCode#, #depName#, #projCode#, #projName#, #taskCode#, #productType#, #productCode#, #productName#, #planStartDate#, #planEndDate#, #factoryCode#, #factoryName#, #groupCode#, #groupName#, #completeDate#, #quantity#, #finishQuantity#, #unfinishQuantity#, #singleWeight#, #totalWeight#, #finishWeight#, #unfinishWeight#, #accountCode#, #createdBy#, #createdName#, #createdTime#, #updatedBy#, #updatedName#, #updatedTime#)
</insert>
<delete
id=
"delete"
>
DELETE FROM ${hggpSchema}.HGSC007 WHERE
id = #id#
</delete>
<update
id=
"update"
>
UPDATE ${hggpSchema}.HGSC007
SET
mat_id = #matId#,
<!-- 物料清单ID -->
order_id = #orderId#,
<!-- 生产计划ID -->
order_detail_id = #orderDetailId#,
<!-- 生产计划明细ID -->
tech_flow_id = #techFlowId#,
<!-- 工艺流程ID -->
tech_flow_name = #techFlowName#,
<!-- 工艺流程名称 -->
invent_process_id = #inventProcessId#,
<!-- 存货工序ID,对应HGPZ005A.id -->
process_code = #processCode#,
<!-- 工序编码 -->
process_name = #processName#,
<!-- 工序名称 -->
process_order = #processOrder#,
<!-- 加工顺序 -->
company_code = #companyCode#,
<!-- 公司编码 -->
company_name = #companyName#,
<!-- 公司名称 -->
dep_code = #depCode#,
<!-- 部门编码 -->
dep_name = #depName#,
<!-- 部门名称 -->
proj_code = #projCode#,
<!-- 项目编码 -->
proj_name = #projName#,
<!-- 项目名称 -->
task_code = #taskCode#,
<!-- 任务编码 -->
product_type = #productType#,
<!-- 产品类型 -->
product_code = #productCode#,
<!-- 产品编号 -->
product_name = #productName#,
<!-- 产品名称 -->
plan_start_date = #planStartDate#,
<!-- 计划开始日期 -->
plan_end_date = #planEndDate#,
<!-- 计划结束日期 -->
factory_code = #factoryCode#,
<!-- 工厂编号 -->
factory_name = #factoryName#,
<!-- 工厂名称 -->
group_code = #groupCode#,
<!-- 工作组编号 -->
group_name = #groupName#,
<!-- 工作组名称 -->
complete_date = #completeDate#,
<!-- 完工日期 -->
quantity = #quantity#,
<!-- 数量 -->
finish_quantity = #finishQuantity#,
<!-- 完工数量 -->
unfinish_quantity = #unfinishQuantity#,
<!-- 未完工数量 -->
single_weight = #singleWeight#,
<!-- 单重 -->
total_weight = #totalWeight#,
<!-- 总重 -->
finish_weight = #finishWeight#,
<!-- 完工重量 -->
unfinish_weight = #unfinishWeight#,
<!-- 未完工重量 -->
account_code = #accountCode#,
<!-- 帐套 -->
created_by = #createdBy#,
<!-- 创建人 -->
created_name = #createdName#,
<!-- 创建人名称 -->
created_time = #createdTime#,
<!-- 创建时间 -->
updated_by = #updatedBy#,
<!-- 更新人 -->
updated_name = #updatedName#,
<!-- 修改人名称 -->
updated_time = #updatedTime#
<!-- 更新时间 -->
WHERE
id = #id#
</update>
<!-- 行锁 -->
<update
id=
"lock"
>
UPDATE ${hggpSchema}.HGSC007
SET CREATED_TIME = CREATED_TIME
WHERE 1=1
<isNotEmpty
prepend=
" AND "
property=
"id"
>
id = #id#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"ids"
>
id IN
<iterate
close=
")"
open=
"("
conjunction=
","
property=
"ids"
>
#ids[]#
</iterate>
</isNotEmpty>
</update>
</sqlMap>
src/main/java/com/baosight/hggp/hg/sc/tools/HGSCTools.java
View file @
4853573f
...
...
@@ -9,6 +9,7 @@ import com.baosight.hggp.core.dao.DaoBase;
import
com.baosight.hggp.core.dao.DaoUtils
;
import
com.baosight.hggp.core.security.UserSessionUtils
;
import
com.baosight.hggp.hg.constant.HGConstant
;
import
com.baosight.hggp.hg.constant.HGSqlConstant
;
import
com.baosight.hggp.hg.pz.domain.HGPZ005
;
import
com.baosight.hggp.hg.pz.domain.HGPZ005A
;
import
com.baosight.hggp.hg.pz.tools.HGPZTools
;
...
...
@@ -18,6 +19,7 @@ import com.baosight.hggp.hg.sj.tools.HGSJTools;
import
com.baosight.hggp.util.AssertUtils
;
import
com.baosight.hggp.util.BeanUtils
;
import
com.baosight.hggp.util.DateUtil
;
import
com.baosight.iplat4j.core.exception.PlatException
;
import
com.baosight.iplat4j.ed.util.SequenceGenerator
;
import
org.apache.commons.collections.CollectionUtils
;
import
org.apache.commons.collections.MapUtils
;
...
...
@@ -29,6 +31,7 @@ import java.util.*;
import
java.util.concurrent.atomic.AtomicReference
;
import
java.util.stream.Collectors
;
import
static
com
.
baosight
.
hggp
.
common
.
AssignStatusEnum
.*;
import
static
java
.
math
.
BigDecimal
.
ROUND_DOWN
;
/**
...
...
@@ -37,6 +40,84 @@ import static java.math.BigDecimal.ROUND_DOWN;
*/
public
class
HGSCTools
{
/**
* 拆单数量校正
*
* @param orderDetailId 生产订单编码
* @param assignNum 分派数量
*/
public
static
void
checkAssignedNum
(
Long
orderDetailId
,
Integer
assignNum
)
{
// 生产订单
HGSC006A
hgsc006A
=
HGSCTools
.
THGSC006A
.
getById
(
orderDetailId
);
Integer
jhNum
=
hgsc006A
.
getQuantity
();
// 子单
Map
queryMap
=
new
HashMap
();
queryMap
.
put
(
HGSC007
.
FIELD_order_detail_id
,
orderDetailId
);
List
<
HGSC007
>
hgsc007List
=
DaoBase
.
getInstance
().
query
(
HGSC007
.
QUERY
,
queryMap
,
0
,
-
999999
);
Integer
totalNum
=
assignNum
;
if
(
CollectionUtils
.
isNotEmpty
(
hgsc007List
)){
for
(
HGSC007
dbsc007
:
hgsc007List
){
totalNum
=
totalNum
+
dbsc007
.
getQuantity
();
}
}
// 判断数量是否超过订单数量
AssertUtils
.
isGt
(
new
BigDecimal
(
totalNum
),
new
BigDecimal
(
jhNum
),
"拆单的分派数量不能大于生产订单数量!"
);
Map
updateMap
=
new
HashMap
();
updateMap
.
put
(
hgsc006A
.
FIELD_id
,
hgsc006A
.
getId
());
updateMap
.
put
(
HGSC006A
.
FIELD_quantity
,
totalNum
);
updateMap
.
put
(
HGSC006A
.
FIELD_unassign_quantity
,
jhNum
-
totalNum
);
// 0.未派工,1.部分派工,2.全部派工
AssignStatusEnum
orderDetailAssignStatus
;
if
(
jhNum
-
totalNum
==
0
)
{
orderDetailAssignStatus
=
ASSIGNED
;
}
else
if
(
totalNum
>
0
)
{
orderDetailAssignStatus
=
PARTIAL_ASSIGN
;
}
else
{
orderDetailAssignStatus
=
UNASSIGN
;
}
updateMap
.
put
(
HGSC006A
.
FIELD_assign_status
,
orderDetailAssignStatus
.
getCode
());
DaoUtils
.
update
(
HGSC006A
.
UPDATE_ASSIGN_NUM
,
updateMap
);
handleOrderAssignStatus
(
hgsc006A
,
orderDetailAssignStatus
);
}
private
static
void
handleOrderAssignStatus
(
HGSC006A
hgsc006A
,
AssignStatusEnum
orderDetailAssignStatus
){
List
<
HGSC006A
>
otherSc006AList
=
HGSCTools
.
THGSC006A
.
otherById
(
hgsc006A
.
getOrderCode
(),
hgsc006A
.
getId
());
int
unassignQuantity
=
0
;
int
totalQuantity
=
0
;
if
(
CollectionUtils
.
isNotEmpty
(
otherSc006AList
)){
unassignQuantity
=
otherSc006AList
.
stream
().
mapToInt
(
HGSC006A:
:
getUnassignQuantity
).
sum
();
totalQuantity
=
otherSc006AList
.
stream
().
mapToInt
(
HGSC006A:
:
getQuantity
).
sum
();
}
AssignStatusEnum
orderAssignStatus
;
switch
(
orderDetailAssignStatus
){
case
UNASSIGN:
if
(
unassignQuantity
==
totalQuantity
){
orderAssignStatus
=
UNASSIGN
;
}
else
{
orderAssignStatus
=
PARTIAL_ASSIGN
;
}
break
;
case
PARTIAL_ASSIGN:
orderAssignStatus
=
PARTIAL_ASSIGN
;
break
;
case
ASSIGNED:
if
(
unassignQuantity
==
totalQuantity
){
orderAssignStatus
=
ASSIGNED
;
}
else
{
orderAssignStatus
=
PARTIAL_ASSIGN
;
}
break
;
default
:
throw
new
PlatException
(
"派工状态异常!"
);
}
Map
updateMap
=
new
HashMap
();
updateMap
.
put
(
HGSC006
.
FIELD_order_code
,
hgsc006A
.
getOrderCode
());
updateMap
.
put
(
HGSC006
.
FIELD_assign_status
,
orderAssignStatus
.
getCode
());
DaoUtils
.
update
(
HGSC006
.
UPDATE_ASSIGN_STATUS
,
updateMap
);
}
public
static
class
THGSC001A
{
/**
...
...
@@ -92,7 +173,7 @@ public class HGSCTools {
public
static
void
deleteByProIds
(
List
<
Long
>
projIds
){
if
(
CollectionUtils
.
isNotEmpty
(
projIds
))
{
//删除历史数据
DaoUtils
.
update
(
HGSC001A
.
DELETE_BY_PROJIDS
,
new
HashMap
<
String
,
Object
>(){{
put
(
"proIds"
,
projIds
);}});
DaoUtils
.
update
(
HGSC001A
.
DELETE_BY_PROJIDS
,
new
HashMap
<
String
,
Object
>(){{
put
(
"pro
j
Ids"
,
projIds
);}});
}
}
}
...
...
@@ -349,6 +430,7 @@ public class HGSCTools {
hgsc005a
.
setFinishDate
(
hgsc005
.
getFinishDate
());
hgsc005a
.
setUnfinishQuantity
(
hgsc005a
.
getQuantity
());
hgsc005a
.
setFinishQuantity
(
0
);
hgsc005a
.
setUnfinishWeight
(
hgsc005a
.
getTotalWeight
());
return
hgsc005a
;
}
...
...
@@ -466,12 +548,40 @@ public class HGSCTools {
hgsc006
.
setCompanyName
(
hgsc005
.
getCompanyName
());
hgsc006
.
setProjCode
(
hgsc005
.
getProjCode
());
hgsc006
.
setProjName
(
hgsc005
.
getProjName
());
hgsc006
.
setAssignStatus
(
AssignStatusEnum
.
UNASSIGN
.
getCode
());
hgsc006
.
setAssignStatus
(
UNASSIGN
.
getCode
());
return
hgsc006
;
}
public
static
HGSC006
getByOrderCode
(
String
orderCode
)
{
AssertUtils
.
isEmpty
(
orderCode
,
"订单编号不能为空!"
);
HGSC006
results
=
(
HGSC006
)
DaoBase
.
getInstance
().
get
(
HGSC006
.
QUERY
,
HGSC006
.
FIELD_order_code
,
orderCode
);
return
results
;
}
}
public
static
class
THGSC006A
{
/**
* 锁
*
* @param orderDetailId
* @return
*/
public
static
void
lock
(
Long
orderDetailId
)
{
if
(
Objects
.
isNull
(
orderDetailId
)||
orderDetailId
<=
0
)
{
return
;
}
Map
queryMap
=
new
HashMap
();
queryMap
.
put
(
HGSC006A
.
FIELD_id
,
orderDetailId
);
DaoBase
.
getInstance
().
update
(
HGSqlConstant
.
HGSC006A
.
LOCK
,
queryMap
);
}
public
static
HGSC006A
getById
(
Long
orderDetailId
){
AssertUtils
.
isTrue
(
Objects
.
isNull
(
orderDetailId
)||
orderDetailId
<=
0
,
"订单明细ID不能为空!"
);
HGSC006A
results
=
(
HGSC006A
)
DaoBase
.
getInstance
().
get
(
HGSC006A
.
QUERY
,
HGSC006A
.
FIELD_id
,
orderDetailId
);
return
results
;
}
public
static
List
<
HGSC006A
>
constructObj
(
HGSC006
hgsc006
,
List
<
HGSC005A
>
hgsc005AList
){
List
<
HGSC006A
>
result
=
new
ArrayList
<>();
hgsc005AList
.
forEach
(
o
->
{
...
...
@@ -497,10 +607,72 @@ public class HGSCTools {
hgsc006a
.
setQuantity
(
o
.
getQuantity
());
hgsc006a
.
setUnassignQuantity
(
o
.
getQuantity
());
hgsc006a
.
setAssignQuantity
(
0
);
hgsc006a
.
setSingleWeight
(
o
.
getSingleWeight
());
hgsc006a
.
setTotalWeight
(
o
.
getTotalWeight
());
hgsc006a
.
setUnassignWeight
(
hgsc006a
.
getTotalWeight
());
result
.
add
(
hgsc006a
);
});
return
result
;
}
public
static
List
<
HGSC006A
>
getByOrderCode
(
String
orderCode
)
{
AssertUtils
.
isEmpty
(
orderCode
,
"订单编号不能为空!"
);
Map
paramMap
=
new
HashMap
();
paramMap
.
put
(
HGSC006A
.
FIELD_order_code
,
orderCode
);
List
<
HGSC006A
>
results
=
DaoBase
.
getInstance
().
query
(
HGSC006A
.
QUERY
,
paramMap
);
return
CollectionUtils
.
isEmpty
(
results
)
?
null
:
results
;
}
public
static
List
<
HGSC006A
>
otherById
(
String
orderCode
,
Long
orderDetailId
)
{
AssertUtils
.
isEmpty
(
orderCode
,
"订单编号不能为空!"
);
AssertUtils
.
isTrue
(
Objects
.
isNull
(
orderDetailId
)||
orderDetailId
<=
0
,
"生产订单明细ID不能为空!"
);
Map
paramMap
=
new
HashMap
();
paramMap
.
put
(
HGSC006A
.
FIELD_order_code
,
orderCode
);
paramMap
.
put
(
HGSC006A
.
FIELD_id
,
orderDetailId
);
List
<
HGSC006A
>
results
=
DaoBase
.
getInstance
().
query
(
HGSC006A
.
QUERY_OTHER
,
paramMap
);
return
CollectionUtils
.
isEmpty
(
results
)
?
null
:
results
;
}
}
public
static
class
THGSC007
{
public
static
HGSC007
getById
(
Long
taskId
){
AssertUtils
.
isTrue
(
Objects
.
isNull
(
taskId
)||
taskId
<=
0
,
"生产任务ID不能为空!"
);
HGSC007
results
=
(
HGSC007
)
DaoBase
.
getInstance
().
get
(
HGSC006A
.
QUERY
,
HGSC007
.
FIELD_id
,
taskId
);
return
results
;
}
/**
* 锁
*
* @param taskIds
* @return
*/
public
static
void
lock
(
List
<
Long
>
taskIds
)
{
if
(
CollectionUtils
.
isEmpty
(
taskIds
))
{
return
;
}
Map
queryMap
=
new
HashMap
();
queryMap
.
put
(
"ids"
,
taskIds
);
DaoBase
.
getInstance
().
update
(
HGSqlConstant
.
HGSC007
.
LOCK
,
queryMap
);
}
/**
* 查询信息
*
* @param taskIds
* @return
*/
public
static
List
<
HGSC007
>
list
(
List
<
Long
>
taskIds
)
{
if
(
CollectionUtils
.
isEmpty
(
taskIds
))
{
return
null
;
}
Map
queryMap
=
new
HashMap
();
queryMap
.
put
(
"ids"
,
taskIds
);
return
DaoBase
.
getInstance
().
query
(
HGSC007
.
QUERY
,
queryMap
);
}
}
}
src/main/webapp/HG/SC/HGSC001.js
View file @
4853573f
...
...
@@ -93,7 +93,7 @@ function update() {
return
;
}
if
(
rows
[
0
].
approvalStatus
>
0
){
message
(
"修改"
,
"项目已提交不可修改!"
);
message
2
(
"修改"
,
"项目已提交不可修改!"
);
return
;
}
let
id
=
rows
[
0
].
id
;
...
...
@@ -112,29 +112,39 @@ function remove() {
message2
(
"删除"
,
"没有选中的行"
);
return
;
}
IPLAT
.
confirm
({
title
:
'删除'
,
message
:
'确认删除此数据么?'
,
okFn
:
function
()
{
var
post
=
new
EiInfo
();
post
.
addBlock
(
resultGrid
.
getCheckedBlockData
());
post
.
set
(
"recursion"
,
true
);
EiCommunicator
.
send
(
"HGSC001"
,
"delete"
,
post
,{
onSuccess
:
function
(
ei
)
{
if
(
ei
.
getStatus
()
>=
0
)
{
NotificationUtil
(
ei
);
resultGrid
.
dataSource
.
query
();
}
else
{
NotificationUtil
(
ei
,
"error"
);
}
},
onFail
:
function
(
ei
)
{
// 发生异常
NotificationUtil
(
"操作失败,原因["
+
ei
+
"]"
,
"error"
);
}
});
let
flag
=
true
;
$
.
each
(
rows
,
function
(
index
,
item
)
{
if
(
item
.
approvalStatus
>
0
){
message2
(
"完工"
,
"项目已提交不可删除!"
);
flag
=
false
;
return
;
}
})
});
if
(
flag
)
{
IPLAT
.
confirm
({
title
:
'删除'
,
message
:
'确认删除此数据么?'
,
okFn
:
function
()
{
var
post
=
new
EiInfo
();
post
.
addBlock
(
resultGrid
.
getCheckedBlockData
());
post
.
set
(
"recursion"
,
true
);
EiCommunicator
.
send
(
"HGSC001"
,
"delete"
,
post
,
{
onSuccess
:
function
(
ei
)
{
if
(
ei
.
getStatus
()
>=
0
)
{
NotificationUtil
(
ei
);
resultGrid
.
dataSource
.
query
();
}
else
{
NotificationUtil
(
ei
,
"error"
);
}
},
onFail
:
function
(
ei
)
{
// 发生异常
NotificationUtil
(
"操作失败,原因["
+
ei
+
"]"
,
"error"
);
}
});
}
});
}
}
function
complete
()
{
...
...
@@ -143,29 +153,39 @@ function complete() {
message2
(
"完工"
,
"没有选中的行"
);
return
;
}
IPLAT
.
confirm
({
title
:
'完工'
,
message
:
'确认完工此数据么?'
,
okFn
:
function
()
{
var
post
=
new
EiInfo
();
post
.
addBlock
(
resultGrid
.
getCheckedBlockData
());
post
.
set
(
"recursion"
,
true
);
EiCommunicator
.
send
(
"HGSC001"
,
"complete"
,
post
,{
onSuccess
:
function
(
ei
)
{
if
(
ei
.
getStatus
()
>=
0
)
{
NotificationUtil
(
ei
);
resultGrid
.
dataSource
.
query
();
}
else
{
NotificationUtil
(
ei
,
"error"
);
}
},
onFail
:
function
(
ei
)
{
// 发生异常
NotificationUtil
(
"操作失败,原因["
+
ei
+
"]"
,
"error"
);
}
});
let
flag
=
true
;
$
.
each
(
rows
,
function
(
index
,
item
)
{
if
(
item
.
approvalStatus
===
'0'
){
message2
(
"完工"
,
"项目未提交不可完工!"
);
flag
=
false
;
return
;
}
})
});
if
(
flag
)
{
IPLAT
.
confirm
({
title
:
'完工'
,
message
:
'确认完工此数据么?'
,
okFn
:
function
()
{
var
post
=
new
EiInfo
();
post
.
addBlock
(
resultGrid
.
getCheckedBlockData
());
post
.
set
(
"recursion"
,
true
);
EiCommunicator
.
send
(
"HGSC001"
,
"complete"
,
post
,
{
onSuccess
:
function
(
ei
)
{
if
(
ei
.
getStatus
()
>=
0
)
{
NotificationUtil
(
ei
);
resultGrid
.
dataSource
.
query
();
}
else
{
NotificationUtil
(
ei
,
"error"
);
}
},
onFail
:
function
(
ei
)
{
// 发生异常
NotificationUtil
(
"操作失败,原因["
+
ei
+
"]"
,
"error"
);
}
});
}
});
}
}
function
commit
()
{
...
...
src/main/webapp/HG/SC/HGSC002.js
View file @
4853573f
...
...
@@ -132,9 +132,11 @@ function save(){
});
}
function
saveCallBack
(){
// 刷新列表
resultGrid
.
dataSource
.
page
(
1
);
function
saveCallBack
(
ei
){
if
(
ei
.
getStatus
()
>=
0
)
{
// 刷新列表
resultGrid
.
dataSource
.
page
(
1
);
}
}
/**
...
...
src/main/webapp/HG/SC/HGSC006A.jsp
View file @
4853573f
...
...
@@ -41,6 +41,10 @@
dateFormat=
"yyyy-MM-dd"
parseFormats=
"['yyyy-MM-dd']"
/>
<EF:EFColumn
ename=
"assignQuantity"
cname=
"派工数量"
width=
"120"
enable=
"true"
align=
"center"
readOnly=
"true"
/>
<EF:EFColumn
ename=
"unassignQuantity"
cname=
"待派工数量"
width=
"120"
enable=
"true"
align=
"center"
readOnly=
"true"
/>
<EF:EFComboColumn
ename=
"assignStatus"
cname=
"派工状态"
width=
"80"
align=
"center"
readonly=
"true"
>
<EF:EFCodeOption
codeName=
"hggp.assignStatus"
/>
</EF:EFComboColumn>
</EF:EFGrid>
</EF:EFRegion>
</EF:EFPage>
src/main/webapp/HG/SC/HGSC006C.js
0 → 100644
View file @
4853573f
let
factoryGroupGlobalData
=
[];
$
(
function
()
{
IPLATUI
.
EFGrid
=
{
"result"
:
{
pageable
:
{
pageSize
:
20
,
pageSizes
:
[
10
,
20
,
50
,
70
,
100
],
},
columns
:
[{
field
:
"groupName"
,
attributes
:
{
class
:
"i-input-readonly"
}
},
{
field
:
"groupCode"
,
template
:
function
(
dataItem
)
{
for
(
let
i
=
0
;
i
<
factoryGroupGlobalData
.
length
;
i
++
)
{
if
(
factoryGroupGlobalData
[
i
][
'valueField'
]
===
dataItem
[
'orgNo'
])
{
return
factoryGroupGlobalData
[
i
][
'textField'
];
}
}
return
""
;
},
editor
:
function
(
container
,
options
)
{
let
inInfo
=
new
EiInfo
();
inInfo
.
set
(
"result-0-parentOrgId"
,
options
.
model
[
"factoryCode"
]);
// 1:生产组
inInfo
.
set
(
"inqu_status-0-productType"
,
'prodGroup'
);
inInfo
.
set
(
"serviceName"
,
"HPXSOrg"
);
inInfo
.
set
(
"methodName"
,
"queryGroupComboBox"
);
inInfo
.
set
(
"blockId"
,
"group_record_block_id"
);
inInfo
.
set
(
"field"
,
options
.
field
);
refreshSelect
(
container
,
inInfo
);
}
},{
field
:
"createdTime"
,
attributes
:
{
class
:
"i-input-readonly"
},
defaultValue
:
function
()
{
return
currShortDate
();
}
}],
onSave
:
function
(
e
)
{
// 阻止后台保存请求,使用自定义保存
e
.
preventDefault
();
save
();
},
onDelete
:
function
(
e
)
{
// 阻止后台删除请求,使用自定义删除
e
.
preventDefault
();
deleteFunc
();
},
onSuccess
:
function
(
e
)
{
if
(
e
.
eiInfo
.
extAttr
.
methodName
==
'save'
||
e
.
eiInfo
.
extAttr
.
methodName
==
'delete'
){
query
();
}
}
}
}
$
(
"#QUERY"
).
on
(
"click"
,
query
);
downKeyUp
();
});
/**
* 页面加载时执行
*/
$
(
window
).
load
(
function
()
{
// 生产组名称
let
inInfo
=
new
EiInfo
();
inInfo
.
set
(
"inqu_status-0-productType"
,
'prodGroup'
);
EiCommunicator
.
send
(
"HPXSOrg"
,
"queryGroupComboBox"
,
inInfo
,
{
onSuccess
:
function
(
ei
)
{
factoryGroupGlobalData
=
ei
.
getBlock
(
"group_record_block_id"
).
getMappedRows
();
},
onFail
:
function
(
ei
)
{
}
},
{
async
:
false
});
// 查询
query
();
});
/**
* 查询
*/
function
query
()
{
resultGrid
.
dataSource
.
page
(
1
);
}
/**
* 保存
*/
let
save
=
function
()
{
let
rows
=
resultGrid
.
getCheckedRows
();
if
(
rows
.
length
<
1
)
{
message
(
"请选择数据"
);
return
;
}
for
(
let
i
=
0
;
i
<
rows
.
length
;
i
++
)
{
if
(
isBlank
(
rows
[
i
][
'factoryCode'
]))
{
message
(
"勾选的第"
+
(
i
+
1
)
+
"行
\"
厂区
\"
,不能为空"
);
return
;
}
if
(
isBlank
(
rows
[
i
][
'groupCode'
]))
{
message
(
"勾选的第"
+
(
i
+
1
)
+
"行
\"
生产组
\"
,不能为空"
);
return
;
}
if
(
isBlank
(
rows
[
i
][
'quantity'
]))
{
message
(
"勾选的第"
+
(
i
+
1
)
+
"行
\"
分派数量
\"
,不能为空"
);
return
;
}
if
(
!
isPositiveInteger
(
rows
[
i
][
'quantity'
]))
{
message
(
"勾选的第"
+
(
i
+
1
)
+
"行
\"
分派数量
\"
必须是大于0的整数"
);
return
;
}
}
JSUtils
.
confirm
(
"确定对勾选中的["
+
rows
.
length
+
"]条数据做
\"
保存
\"
操作? "
,
{
ok
:
function
()
{
JSUtils
.
submitGridsData
(
"result"
,
"HGSC006C"
,
"save"
,
true
);
}
});
}
/**
* 删除
*/
let
deleteFunc
=
function
()
{
let
rows
=
resultGrid
.
getCheckedRows
();
if
(
rows
.
length
<
1
)
{
message
(
"请选择数据"
);
return
;
}
JSUtils
.
confirm
(
"确定对勾选中的["
+
rows
.
length
+
"]条数据做
\"
删除
\"
操作? "
,
{
ok
:
function
()
{
JSUtils
.
submitGridsData
(
"result"
,
"HGSC006C"
,
"delete"
,
true
);
}
});
}
src/main/webapp/HG/SC/HGSC006C.jsp
0 → 100644
View file @
4853573f
<!DOCTYPE html>
<
%@
page
contentType=
"text/html; charset=UTF-8"
%
>
<
%@
taglib
uri=
"http://java.sun.com/jsp/jstl/core"
prefix=
"c"
%
>
<
%@
taglib
prefix=
"EF"
tagdir=
"/WEB-INF/tags/EF"
%
>
<c:set
var=
"ctx"
value=
"${pageContext.request.contextPath}"
/>
<EF:EFPage
title=
"拆单派工"
>
<EF:EFRegion
id=
"inqu"
title=
"订单详情"
>
<EF:EFInput
ename=
"inqu_status-0-projCode"
cname=
"项目号"
type=
"hidden"
/>
<EF:EFInput
ename=
"inqu_status-0-productType"
cname=
"产品类型"
type=
"hidden"
/>
<EF:EFInput
ename=
"detail-0-id"
cname=
"订单明细ID"
type=
"hidden"
/>
<div
class=
"row"
>
<EF:EFInput
ename=
"detail-0-projCode"
cname=
"项目号"
colWidth=
"4"
readonly=
"true"
/>
<EF:EFInput
ename=
"detail-0-projName"
cname=
"项目名称"
colWidth=
"4"
readonly=
"true"
/>
<EF:EFInput
ename=
"detail-0-orderNo"
cname=
"生产订单号"
colWidth=
"4"
readonly=
"true"
/>
</div>
<div
class=
"row"
>
<EF:EFInput
ename=
"detail-0-productCode"
cname=
"产品编码"
colWidth=
"4"
readonly=
"true"
/>
<EF:EFInput
ename=
"detail-0-productName"
cname=
"产品名称"
colWidth=
"4"
readonly=
"true"
/>
<EF:EFInput
ename=
"detail-0-processName"
cname=
"工序"
colWidth=
"4"
readonly=
"true"
/>
</div>
<div
class=
"row"
>
<EF:EFInput
ename=
"detail-0-planCompletionDate"
cname=
"计划完成日期"
colWidth=
"4"
readonly=
"true"
/>
<EF:EFInput
ename=
"detail-0-quantity"
cname=
"计划数量"
colWidth=
"4"
readonly=
"true"
/>
<EF:EFInput
ename=
"detail-0-totalWeight"
cname=
"计划重量(kg)"
colWidth=
"4"
readonly=
"true"
/>
</div>
<div
class=
"row"
>
<EF:EFInput
ename=
"detail-0-assignQuantity"
cname=
"已派工数量"
colWidth=
"4"
readonly=
"true"
/>
<EF:EFInput
ename=
"detail-0-unassignQuantity"
cname=
"待派工数量"
colWidth=
"4"
readonly=
"true"
/>
<EF:EFSelect
ename=
"detail-0-assignStatus"
cname=
"状态"
colWidth=
"4"
readonly=
"true"
>
<EF:EFCodeOption
codeName=
"hggp.assignStatus"
/>
</EF:EFSelect>
</div>
</EF:EFRegion>
<EF:EFRegion
id=
"result"
title=
"明细信息"
>
<EF:EFGrid
blockId=
"result"
autoDraw=
"override"
checkMode=
"row"
isFloat=
"true"
>
<EF:EFColumn
ename=
"id"
cname=
"任务ID"
enable=
"false"
width=
"80"
align=
"center"
/>
<EF:EFColumn
ename=
"taskCode"
cname=
"任务单号"
enable=
"false"
hidden=
"true"
/>
<EF:EFComboColumn
ename=
"factoryCode"
cname=
"厂区"
width=
"110"
align=
"center"
defaultValue=
""
required=
"true"
filter=
"contains"
readonly=
"true"
>
<EF:EFOptions
blockId=
"factory_record_block_id"
valueField=
"valueField"
textField=
"textField"
/>
</EF:EFComboColumn>
<EF:EFColumn
ename=
"factoryName"
cname=
"工厂"
enable=
"false"
align=
"center"
hidden=
"true"
/>
<EF:EFComboColumn
ename=
"groupCode"
cname=
"生产组"
width=
"110"
align=
"center"
defaultValue=
""
required=
"true"
filter=
"contains"
readonly=
"true"
>
<EF:EFOptions
blockId=
"group_record_block_id"
valueField=
"valueField"
textField=
"textField"
/>
</EF:EFComboColumn>
<EF:EFColumn
ename=
"groupName"
cname=
"生产组名称"
enable=
"false"
align=
"center"
hidden=
"true"
/>
<EF:EFColumn
ename=
"createdTime"
cname=
"派工时间"
enable=
"false"
width=
"100"
align=
"center"
editType=
"date"
dateFormat=
"yyyy-MM-dd"
parseFormats=
"['yyyyMMdd']"
required=
"true"
/>
<EF:EFColumn
ename=
"quantity"
cname=
"分派数量"
format=
"{0:N0}"
required=
"true"
/>
</EF:EFGrid>
<br/>
<span
style=
'color: red;font-size: 13px;'
>
说明:厂区和生产组仅新增的时候可以编辑
</span>
</EF:EFRegion>
</EF:EFPage>
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