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
51b1512b
Commit
51b1512b
authored
Jun 17, 2024
by
yukang
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'origin/dev' into dev
parents
7c4a9a64
6a8e49bf
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
135 additions
and
38 deletions
+135
-38
HGSC007.java
src/main/java/com/baosight/hggp/hg/sc/domain/HGSC007.java
+2
-1
HGSC007POJO.java
...main/java/com/baosight/hggp/hg/sc/domain/HGSC007POJO.java
+0
-0
ServiceHGSC007.java
.../java/com/baosight/hggp/hg/sc/service/ServiceHGSC007.java
+90
-33
HGSC007.xml
src/main/java/com/baosight/hggp/hg/sc/sql/HGSC007.xml
+0
-0
HGXSOrg.xml
src/main/java/com/baosight/hggp/hg/xs/sql/HGXSOrg.xml
+2
-0
DateUtil.java
src/main/java/com/baosight/hggp/util/DateUtil.java
+6
-2
HGYX001.js
src/main/webapp/HG/YX/HGYX001.js
+17
-0
HGYX001.jsp
src/main/webapp/HG/YX/HGYX001.jsp
+1
-1
HGYX002.js
src/main/webapp/HG/YX/HGYX002.js
+16
-0
HGYX002.jsp
src/main/webapp/HG/YX/HGYX002.jsp
+1
-1
No files found.
src/main/java/com/baosight/hggp/hg/sc/domain/HGSC007.java
View file @
51b1512b
...
...
@@ -115,7 +115,8 @@ public class HGSC007 extends DaoEPBase {
public
static
final
String
UPDATE
=
"HGSC007.update"
;
public
static
final
String
DELETE
=
"HGSC007.delete"
;
public
static
final
String
QUERY_SUM_WT
=
"HGSC007.querySumWt"
;
/*查询累计产量*/
public
static
final
String
QUERY_DAY_WT
=
"HGSC007.queryDayWt"
;
/*查询工序产量*/
public
static
final
String
QUERY_DAY_WT
=
"HGSC007.queryDayWt"
;
/*查询工序日产量*/
public
static
final
String
QUERY_MONTH_WT
=
"HGSC007.queryMonthWt"
;
/*查询工序月产量*/
public
static
final
String
QUERY_PROJ_CODE_WT
=
"HGSC007.queryProjCodeWt"
;
/*查询项目产量*/
private
Long
id
=
new
Long
(
0
);
...
...
src/main/java/com/baosight/hggp/hg/sc/domain/HGSC007POJO.java
0 → 100644
View file @
51b1512b
This diff is collapsed.
Click to expand it.
src/main/java/com/baosight/hggp/hg/sc/service/ServiceHGSC007.java
View file @
51b1512b
...
...
@@ -22,10 +22,7 @@ import com.baosight.iplat4j.core.service.impl.ServiceEPBase;
import
org.apache.commons.collections.CollectionUtils
;
import
org.apache.commons.lang.StringUtils
;
import
java.util.ArrayList
;
import
java.util.HashMap
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.*
;
/**
...
...
@@ -96,13 +93,12 @@ import java.util.Map;
if
(
CollectionUtils
.
isEmpty
(
orgs
))
{
return
new
ArrayList
<>();
}
for
(
Org
org
:
orgs
)
{
List
<
Map
>
org1
=
DaoBase
.
getInstance
().
query
(
"HGXSOrg.queryFactoryComboBox"
,
new
HashMap
<
String
,
Object
>(){{
put
(
Org
.
FIELD_PARENT_ORG_ID
,
org
.
getOrgId
());
}});
factoryCodes
.
addAll
(
org1
);
for
(
Org
org
:
orgs
)
{
Map
<
String
,
String
>
map
=
new
HashMap
<>();
map
.
put
(
Org
.
FIELD_ORG_ID
,
org
.
getFactoryCode
());
map
.
put
(
Org
.
FIELD_ORG_CNAME
,
org
.
getFactoryName
());
factoryCodes
.
add
(
map
);
}
}
catch
(
Exception
e
){
LogUtils
.
setDetailMsg
(
inInfo
,
e
,
"APP查询工厂失败"
);
...
...
@@ -111,48 +107,109 @@ import java.util.Map;
}
/**
* app查询工序累计产量
*/
@OperationLogAnnotation
(
operModul
=
"生产任务"
,
operType
=
"APP查询工序累计产量"
,
operDesc
=
"APP查询工序累计产量"
)
public
EiInfo
getProcessSumWt
(
EiInfo
inInfo
)
{
try
{
EiBlock
queryRow
=
inInfo
.
getBlock
(
EiConstant
.
queryBlock
);
UserVO
userVO
=
HGCWTools
.
HgCw002
.
getUserCompany
();
String
companyCode
=
queryRow
.
getCellStr
(
ACConstants
.
ROW_CODE_0
,
HGSC007
.
FIELD_company_code
);
if
(
StringUtils
.
isEmpty
(
companyCode
))
{
queryRow
.
setCell
(
ACConstants
.
ROW_CODE_0
,
HGSC007
.
FIELD_company_code
,
userVO
.
getUsercode
());
}
inInfo
=
super
.
query
(
inInfo
,
HGSC007
.
QUERY_SUM_WT
);
}
catch
(
PlatException
e
)
{
LogUtils
.
setDetailMsg
(
inInfo
,
e
,
"查询失败"
);
}
return
inInfo
;
}
/**
* app查询工序产量
*/
@OperationLogAnnotation
(
operModul
=
"生产任务"
,
operType
=
"APP查询产量"
,
operDesc
=
"APP查询产量"
)
public
Map
<
String
,
List
>
getWt
(
EiInfo
inInfo
)
{
Map
<
String
,
List
>
map
=
new
HashMap
<>();
@OperationLogAnnotation
(
operModul
=
"生产任务"
,
operType
=
"APP查询工序产量"
,
operDesc
=
"APP查询工序产量"
)
public
EiInfo
getProcessWt
(
EiInfo
inInfo
)
{
try
{
EiBlock
queryRow
=
inInfo
.
getBlock
(
EiConstant
.
queryBlock
);
UserVO
userVO
=
HGCWTools
.
HgCw002
.
getUserCompany
();
String
companyCode
=
queryRow
.
getCellStr
(
ACConstants
.
ROW_CODE_0
,
HGSC007
.
FIELD_company_code
);
if
(
StringUtils
.
isEmpty
(
companyCode
))
{
queryRow
.
setCell
(
ACConstants
.
ROW_CODE_0
,
HGSC007
.
FIELD_company_code
,
userVO
.
getUsercode
());
}
inInfo
=
super
.
query
(
inInfo
,
HGSC007
.
QUERY_DAY_WT
);
}
catch
(
PlatException
e
)
{
LogUtils
.
setDetailMsg
(
inInfo
,
e
,
"查询失败"
);
}
return
inInfo
;
}
/**
* app查询工序日产量
*/
@OperationLogAnnotation
(
operModul
=
"生产任务"
,
operType
=
"APP查询工序日产量"
,
operDesc
=
"APP查询工序日产量"
)
public
EiInfo
getProcessDayWt
(
EiInfo
inInfo
)
{
try
{
EiBlock
queryRow
=
inInfo
.
getBlock
(
EiConstant
.
queryBlock
);
UserVO
userVO
=
HGCWTools
.
HgCw002
.
getUserCompany
();
String
companyCode
=
queryRow
.
getCellStr
(
ACConstants
.
ROW_CODE_0
,
HGSC007
.
FIELD_company_code
);
String
endDate
=
queryRow
.
getCellStr
(
ACConstants
.
ROW_CODE_0
,
ACConstants
.
SQL_END_DATE
);
if
(
StringUtils
.
isNotEmpty
(
endDate
))
{
String
startDate
=
DateUtil
.
dateSubStr
(
endDate
,-
7
);
queryRow
.
setCell
(
ACConstants
.
ROW_CODE_0
,
ACConstants
.
SQL_START_DATE
,
startDate
);
}
if
(
StringUtils
.
isEmpty
(
companyCode
))
{
queryRow
.
setCell
(
ACConstants
.
ROW_CODE_0
,
HGSC007
.
FIELD_company_code
,
userVO
.
getUsercode
());
}
inInfo
=
super
.
query
(
inInfo
,
HGSC007
.
QUERY_DAY_WT
);
}
catch
(
PlatException
e
)
{
LogUtils
.
setDetailMsg
(
inInfo
,
e
,
"查询失败"
);
}
return
inInfo
;
}
/**
* app查询工序日产量
*/
@OperationLogAnnotation
(
operModul
=
"生产任务"
,
operType
=
"APP查询工序日产量"
,
operDesc
=
"APP查询工序日产量"
)
public
EiInfo
getProcessMonthWt
(
EiInfo
inInfo
)
{
try
{
EiBlock
queryRow
=
inInfo
.
getBlock
(
EiConstant
.
queryBlock
);
UserVO
userVO
=
HGCWTools
.
HgCw002
.
getUserCompany
();
Map
queryRow
=
EiInfoUtils
.
getFirstRow
(
inInfo
);
Object
companyCode
=
queryRow
.
get
(
HGSC007
.
FIELD_company_code
);
if
(
companyCode
==
null
)
{
queryRow
.
put
(
HGSC007
.
FIELD_company_code
,
userVO
.
getUsercode
()
);
//queryRow.put(HGSC007.FIELD_company_name,userVO.getUsername()
);
}
List
sumList
=
DaoBase
.
getInstance
().
query
(
HGSC007
.
QUERY_SUM_WT
,
queryRow
);
List
dayList
=
DaoBase
.
getInstance
().
query
(
HGSC007
.
QUERY_DAY_WT
,
queryRow
);
map
.
put
(
"sumList"
,
sumList
);
map
.
put
(
"dayList"
,
dayList
);
String
companyCode
=
queryRow
.
getCellStr
(
ACConstants
.
ROW_CODE_0
,
HGSC007
.
FIELD_company_code
);
String
endDate
=
queryRow
.
getCellStr
(
ACConstants
.
ROW_CODE_0
,
ACConstants
.
SQL_END_DATE
);
if
(
StringUtils
.
isNotEmpty
(
endDate
)
)
{
String
startDate
=
DateUtil
.
getMonthOfDays
(
endDate
,-
6
,
DateUtil
.
DATE8_PATTERN
);
queryRow
.
setCell
(
ACConstants
.
ROW_CODE_0
,
ACConstants
.
SQL_START_DATE
,
startDate
);
}
if
(
StringUtils
.
isEmpty
(
companyCode
))
{
queryRow
.
setCell
(
ACConstants
.
ROW_CODE_0
,
HGSC007
.
FIELD_company_code
,
userVO
.
getUsercode
()
);
}
inInfo
=
super
.
query
(
inInfo
,
HGSC007
.
QUERY_MONTH_WT
);
}
catch
(
PlatException
e
)
{
LogUtils
.
setDetailMsg
(
inInfo
,
e
,
"查询失败"
);
}
return
map
;
return
inInfo
;
}
/**
* app查询工序产量
*/
@OperationLogAnnotation
(
operModul
=
"生产任务"
,
operType
=
"APP查询项目产量"
,
operDesc
=
"APP查询项目产量"
)
public
List
getProjCodeWt
(
EiInfo
inInfo
)
{
List
sumList
=
null
;
public
EiInfo
getProjCodeWt
(
EiInfo
inInfo
)
{
try
{
EiBlock
queryRow
=
inInfo
.
getBlock
(
EiConstant
.
queryBlock
);
UserVO
userVO
=
HGCWTools
.
HgCw002
.
getUserCompany
();
Map
queryRow
=
EiInfoUtils
.
getFirstRow
(
inInfo
);
Object
companyCode
=
queryRow
.
get
(
HGSC007
.
FIELD_company_code
);
if
(
companyCode
==
null
)
{
queryRow
.
put
(
HGSC007
.
FIELD_company_code
,
userVO
.
getUsercode
());
//queryRow.put(HGSC007.FIELD_company_name,userVO.getUsername());
//Map queryRow = EiInfoUtils.getFirstRow(inInfo);
String
companyCode
=
queryRow
.
getCellStr
(
ACConstants
.
ROW_CODE_0
,
HGSC007
.
FIELD_company_code
);
if
(
StringUtils
.
isEmpty
(
companyCode
))
{
queryRow
.
setCell
(
ACConstants
.
ROW_CODE_0
,
HGSC007
.
FIELD_company_code
,
userVO
.
getUsercode
());
}
sumList
=
DaoBase
.
getInstance
().
query
(
HGSC007
.
QUERY_PROJ_CODE_WT
,
queryRow
);
inInfo
=
super
.
query
(
inInfo
,
HGSC007
.
QUERY_PROJ_CODE_WT
);
}
catch
(
PlatException
e
)
{
LogUtils
.
setDetailMsg
(
inInfo
,
e
,
"查询失败"
);
}
return
sumList
;
return
inInfo
;
}
}
...
...
src/main/java/com/baosight/hggp/hg/sc/sql/HGSC007.xml
View file @
51b1512b
This diff is collapsed.
Click to expand it.
src/main/java/com/baosight/hggp/hg/xs/sql/HGXSOrg.xml
View file @
51b1512b
...
...
@@ -228,7 +228,9 @@
A.ORG_TYPE AS "orgType",
A.ACCOUNT_CODE AS "accounCcode",
A.FACTORY_CODE AS "factoryCode",
A.FACTORY_NAME AS "factoryName",
A.COMPANY_CODE AS "companyCode",
A.COMPANY_NAME AS "companyName",
A.PARENT_ORG_ID as "parentOrgId"
FROM ${platSchema}.TXSOG01 A, ${platSchema}.TXSOG02 B, ${platSchema}.XS_USER C
WHERE 1=1
...
...
src/main/java/com/baosight/hggp/util/DateUtil.java
View file @
51b1512b
...
...
@@ -80,9 +80,13 @@ public class DateUtil {
* @return
*/
public
static
String
getMonthOfDays
(
String
date
){
return
getMonthOfDays
(
date
,
-
1
,
DATE10_PATTERN
);
}
public
static
String
getMonthOfDays
(
String
date
,
int
month
,
String
pattern
){
Calendar
calendar
=
Calendar
.
getInstance
();
//日历对象
calendar
.
setTime
(
Objects
.
requireNonNull
(
DateUtil
.
toDate
(
date
,
DATE10_PATTERN
)));
//设置当前日期
calendar
.
add
(
Calendar
.
MONTH
,
-
1
);
//月份减一
calendar
.
setTime
(
Objects
.
requireNonNull
(
DateUtil
.
toDate
(
date
,
pattern
)));
//设置当前日期
calendar
.
add
(
Calendar
.
MONTH
,
month
);
//月份减一
return
DateUtil
.
toDateStr
(
calendar
.
getTime
(),
DATE8_PATTERN
);
//输出上个月的日期
}
...
...
src/main/webapp/HG/YX/HGYX001.js
View file @
51b1512b
...
...
@@ -16,6 +16,8 @@ $(function () {
if
(
!
isBlank
(
item
.
id
)){
template
+=
'<a style="cursor: pointer;display: inline-flex;justify-content: center;margin:auto 5px" '
+
'onclick="showDetail('
+
item
.
id
+
')" >发货详情</a>'
;
template
+=
'<a style="cursor: pointer;display: inline-flex;justify-content: center;margin:auto 5px" '
+
'onclick="showUploadFile('
+
item
.
id
+
')" >附件详情</a>'
;
/*if (auditStatus == 0) {
template += '<a style="cursor: pointer;display: inline-flex;justify-content: center;margin:auto 5px" ' +
'onclick="updateStatus(' + item.id + ',1)" >审核</a>';
...
...
@@ -335,6 +337,21 @@ function commit() {
}
/**
* 显示附件清单
*
* @param id
*/
function
showUploadFile
(
id
)
{
JSColorbox
.
open
({
href
:
"HGSB099?methodName=initLoad&inqu_status-0-matId="
+
id
+
"&inqu_status-0-bizType=YX001"
,
title
:
"<div style='text-align: center;'>附件详情</div>"
,
width
:
"70%"
,
height
:
"50%"
,
//callbackName: uploadFileCallback
});
}
function
windowCallback
(
ei
)
{
if
(
ei
.
getStatus
()
>=
0
)
{
// 刷新列表
...
...
src/main/webapp/HG/YX/HGYX001.jsp
View file @
51b1512b
...
...
@@ -44,7 +44,7 @@
<EF:EFRegion id="result" title="明细信息">
<EF:EFGrid blockId="result" autoDraw="override" isFloat="true" checkMode="row" copyToAdd="false">
<EF:EFColumn ename="id" cname="内码" hidden="true"/>
<EF:EFColumn ename="operator" cname="操作" locked="true" enable="false" width="1
2
0" align="center"/>
<EF:EFColumn ename="operator" cname="操作" locked="true" enable="false" width="1
4
0" align="center"/>
<EF:EFComboColumn ename="companyCode" enable="true" cname="公司名称" width="110" align="center"
filter="contains" readonly="true" required="true">
<EF:EFOptions blockId="companyBox_block_id" valueField="valueField" textField="textField"/>
...
...
src/main/webapp/HG/YX/HGYX002.js
View file @
51b1512b
...
...
@@ -16,6 +16,8 @@ $(function () {
if
(
!
isBlank
(
item
.
id
)){
template
+=
'<a style="cursor: pointer;display: inline-flex;justify-content: center;margin:auto 5px" '
+
'onclick="showDetail('
+
item
.
id
+
')" >退货详情</a>'
;
template
+=
'<a style="cursor: pointer;display: inline-flex;justify-content: center;margin:auto 5px" '
+
'onclick="showUploadFile('
+
item
.
id
+
')" >附件详情</a>'
;
/*if (auditStatus == 0) {
template += '<a style="cursor: pointer;display: inline-flex;justify-content: center;margin:auto 5px" ' +
'onclick="updateStatus(' + item.id + ',1)" >审核</a>';
...
...
@@ -213,3 +215,17 @@ function windowCallback(ei) {
JSColorbox
.
close
();
}
}
/**
* 显示附件清单
*
* @param id
*/
function
showUploadFile
(
id
)
{
JSColorbox
.
open
({
href
:
"HGSB099?methodName=initLoad&inqu_status-0-matId="
+
id
+
"&inqu_status-0-bizType=YX002"
,
title
:
"<div style='text-align: center;'>附件详情</div>"
,
width
:
"70%"
,
height
:
"50%"
,
//callbackName: uploadFileCallback
});
}
src/main/webapp/HG/YX/HGYX002.jsp
View file @
51b1512b
...
...
@@ -31,7 +31,7 @@
<EF:EFRegion id="result" title="明细信息">
<EF:EFGrid blockId="result" autoDraw="override" isFloat="true" checkMode="row" copyToAdd="false">
<EF:EFColumn ename="id" cname="内码" hidden="true"/>
<EF:EFColumn ename="operator" cname="操作" locked="true" enable="false" width="1
2
0" align="center"/>
<EF:EFColumn ename="operator" cname="操作" locked="true" enable="false" width="1
4
0" align="center"/>
<EF:EFComboColumn ename="projCode" enable="true" cname="项目名称" width="110" align="center"
filter="contains" readonly="true" required="true">
<EF:EFOptions blockId="proj_record_block_id" valueField="valueField" textField="textField"/>
...
...
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