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
c798cd9b
Commit
c798cd9b
authored
Oct 23, 2024
by
liuyang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
2024-10-23 委外制造加工表
parent
ab598c48
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
120 additions
and
0 deletions
+120
-0
ServiceHGSC012.java
.../java/com/baosight/hggp/hg/sc/service/ServiceHGSC012.java
+11
-0
HGSC012.xml
src/main/java/com/baosight/hggp/hg/sc/sql/HGSC012.xml
+109
-0
No files found.
src/main/java/com/baosight/hggp/hg/sc/service/ServiceHGSC012.java
View file @
c798cd9b
package
com
.
baosight
.
hggp
.
hg
.
sc
.
service
;
package
com
.
baosight
.
hggp
.
hg
.
sc
.
service
;
import
com.baosight.iplat4j.core.ei.EiInfo
;
import
com.baosight.iplat4j.core.service.impl.ServiceEPBase
;
import
com.baosight.iplat4j.core.service.impl.ServiceEPBase
;
/**
/**
...
@@ -8,4 +9,14 @@ import com.baosight.iplat4j.core.service.impl.ServiceEPBase;
...
@@ -8,4 +9,14 @@ import com.baosight.iplat4j.core.service.impl.ServiceEPBase;
* @description 委外制造加工表
* @description 委外制造加工表
*/
*/
public
class
ServiceHGSC012
extends
ServiceEPBase
{
public
class
ServiceHGSC012
extends
ServiceEPBase
{
@Override
public
EiInfo
initLoad
(
EiInfo
inInfo
)
{
return
inInfo
;
}
@Override
public
EiInfo
query
(
EiInfo
inInfo
)
{
return
super
.
query
(
inInfo
,
"HGSC012.query"
);
}
}
}
src/main/java/com/baosight/hggp/hg/sc/sql/HGSC012.xml
View file @
c798cd9b
...
@@ -2,4 +2,112 @@
...
@@ -2,4 +2,112 @@
<!DOCTYPE sqlMap PUBLIC "-//ibatis.apache.org//DTD SQL Map 2.0//EN" "http://ibatis.apache.org/dtd/sql-map-2.dtd">
<!DOCTYPE sqlMap PUBLIC "-//ibatis.apache.org//DTD SQL Map 2.0//EN" "http://ibatis.apache.org/dtd/sql-map-2.dtd">
<sqlMap
namespace=
"HGSC012"
>
<sqlMap
namespace=
"HGSC012"
>
<select
id=
"query"
parameterClass=
"java.util.HashMap"
resultClass=
"java.util.HashMap"
>
select
h.COMPANY_CODE as "companyCode",
<!-- 公司编码 -->
h.COMPANY_NAME as "companyName",
<!-- 公司名称 -->
h.CONTRACT_DATE as "contractDate",
<!-- 委托日期 -->
h.CONTRACT_CODE as "contractCode",
<!-- 委托单号 -->
h.SUP_CODE as "supCode",
<!-- 供应商编码 -->
h.SUP_NAME as "supName",
<!-- 供应商名称 -->
h.INVENT_CODE as "lcinventCode",
<!-- 原料编码 -->
h.INVENT_NAME as "lcinventName",
<!-- 原料名称 -->
h.SPEC_CL as "lcspec",
h.OUT_QTY as "jhckQty",
<!-- 出库数量 -->
h.OUT_WEIGHT as "jhckWeight",
<!-- 出库重量 -->
hd.OUT_DATE as "outDate",
<!-- 出库日期 -->
hd.OUT_QTY as "sjckoutQty",
<!-- 出库数量 -->
hd.OUT_WEIGHT as "sjckoutWeight",
<!-- 出库重量 -->
h.PRODUCT_CODE as "productCode",
<!-- 成品编码 -->
h.PRODUCT_NAME as "productName",
<!-- 成品名称 -->
h.SPEC_CP as "rkspec",
<!-- 规格 -->
h.DEPOSIT_QTY as "jhrkdepositQty",
<!-- 计划入库数量 -->
h.DEPOSIT_WEIGHT as "jhrkdepositWeight",
<!-- 计划入库重量 -->
hc.DEPOSIT_DATE as "depositDate",
<!-- 入库日期 -->
hc.ACTUAL_QTY as "actualQty",
<!-- 实际入库数量 -->
hc.DEPOSIT_WEIGHT as "depositWeight"
<!-- 实际入库重量 -->
from (
select
h.COMPANY_CODE ,
h.COMPANY_NAME ,
h.CONTRACT_DATE ,
h.CONTRACT_CODE ,
h.SUP_CODE ,
h.SUP_NAME ,
h.SUB_STATUS,
hb.INVENT_CODE ,
hb.INVENT_NAME ,
hb.SPEC as "SPEC_CL",
hb.OUT_QTY ,
hb.OUT_WEIGHT ,
ha.PRODUCT_CODE ,
ha.PRODUCT_NAME ,
ha.SPEC as "SPEC_CP",
ha.DEPOSIT_QTY ,
ha.DEPOSIT_WEIGHT
from hggp.hgsc010 h
left join hggp.hgsc010a ha on h.ID = ha.PARENT_ID AND h.ACCOUNT_CODE = ha.ACCOUNT_CODE
left join hggp.hgsc010b hb on h.ID = hb.PARENT_ID AND h.ACCOUNT_CODE = ha.ACCOUNT_CODE and ha.INVENT_CODE = hb.INVENT_CODE
where h.SUB_STATUS = 1
<isNotEmpty
prepend=
" AND "
property=
"accountCode"
>
h.ACCOUNT_CODE = #accountCode#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"companyCode"
>
h.COMPANY_CODE = #companyCode#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"companyName"
>
h.COMPANY_NAME = #companyName#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"contractDate"
>
h.CONTRACT_DATE = #contractDate#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"contractCode"
>
h.CONTRACT_CODE like concat('%',#contractCode#,'%')
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"supCode"
>
h.SUP_CODE = #supCode#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"supName"
>
h.SUP_NAME = #supName#
</isNotEmpty>
) h
left join (
select
h2.OUT_DATE,
ha2.CONTRACT_CODE ,
ha2.INVENT_CODE ,
ha2.INVENT_NAME ,
ha2.SPEC,
ha2.OUT_QTY ,
ha2.OUT_WEIGHT
from hggp.hgkc015 h2
inner join hggp.hgkc015a ha2 on h2.OUT_CODE = ha2.OUT_CODE
where STATUS = 1 and h2.DELETE_FLAG = 0
<isNotEmpty
prepend=
" AND "
property=
"accountCode"
>
h2.ACCOUNT_CODE = #accountCode#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"contractCode"
>
h2.CONTRACT_CODE like concat('%',#contractCode#,'%')
</isNotEmpty>
) hd on h.CONTRACT_CODE = hd.CONTRACT_CODE and h.INVENT_CODE = hd.INVENT_CODE
left join (
select
h2.DEPOSIT_DATE,
ha2.CONTRACT_CODE,
ha2.PRODUCT_CODE,
ha2.PRODUCT_NAME,
ha2.SPEC,
ha2.ACTUAL_QTY,
ha2.ACTUAL_QTY*ha2.DEPOSIT_UNIT_WEIGHT as "DEPOSIT_WEIGHT"
from hggp.hgkc014 h2
inner join hggp.hgkc014a ha2 on h2.DEPOSIT_CODE = ha2.DEPOSIT_CODE
where h2.STATUS = 3 and h2.DELETE_FLAG = 0
<isNotEmpty
prepend=
" AND "
property=
"accountCode"
>
h2.ACCOUNT_CODE = #accountCode#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"contractCode"
>
h2.CONTRACT_CODE like concat('%',#contractCode#,'%')
</isNotEmpty>
) hc on h.CONTRACT_CODE = hc.CONTRACT_CODE and h.PRODUCT_CODE = hc.PRODUCT_CODE
</select>
</sqlMap>
</sqlMap>
\ No newline at end of file
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