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
c98b67dd
Commit
c98b67dd
authored
Jun 26, 2024
by
liuyang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
2024-06-26 设备管理根据角色查询公司
parent
3c08209f
Show whitespace changes
Inline
Side-by-side
Showing
35 changed files
with
280 additions
and
134 deletions
+280
-134
ServiceHGKC004.java
.../java/com/baosight/hggp/hg/kc/service/ServiceHGKC004.java
+15
-5
ServiceHGKC013.java
.../java/com/baosight/hggp/hg/kc/service/ServiceHGKC013.java
+18
-6
HGKC001.xml
src/main/java/com/baosight/hggp/hg/kc/sql/HGKC001.xml
+21
-0
HGKC004.xml
src/main/java/com/baosight/hggp/hg/kc/sql/HGKC004.xml
+6
-0
HGKC010.xml
src/main/java/com/baosight/hggp/hg/kc/sql/HGKC010.xml
+3
-0
HGKC013.xml
src/main/java/com/baosight/hggp/hg/kc/sql/HGKC013.xml
+3
-0
ServiceHGSJ003.java
.../java/com/baosight/hggp/hg/sj/service/ServiceHGSJ003.java
+10
-22
HGSJ003.xml
src/main/java/com/baosight/hggp/hg/sj/sql/HGSJ003.xml
+7
-1
ServiceHGYX001.java
.../java/com/baosight/hggp/hg/yx/service/ServiceHGYX001.java
+26
-6
ServiceHGYX001A.java
...java/com/baosight/hggp/hg/yx/service/ServiceHGYX001A.java
+19
-16
ServiceHGYX001B.java
...java/com/baosight/hggp/hg/yx/service/ServiceHGYX001B.java
+13
-6
ServiceHGYX001C.java
...java/com/baosight/hggp/hg/yx/service/ServiceHGYX001C.java
+8
-0
ServiceHGYX002.java
.../java/com/baosight/hggp/hg/yx/service/ServiceHGYX002.java
+26
-8
ServiceHGYX002A.java
...java/com/baosight/hggp/hg/yx/service/ServiceHGYX002A.java
+19
-13
ServiceHGYX002B.java
...java/com/baosight/hggp/hg/yx/service/ServiceHGYX002B.java
+19
-12
ServiceHGYX002C.java
...java/com/baosight/hggp/hg/yx/service/ServiceHGYX002C.java
+7
-0
HGYX001.xml
src/main/java/com/baosight/hggp/hg/yx/sql/HGYX001.xml
+4
-2
HGYX001A.xml
src/main/java/com/baosight/hggp/hg/yx/sql/HGYX001A.xml
+3
-0
HGYX001C.xml
src/main/java/com/baosight/hggp/hg/yx/sql/HGYX001C.xml
+3
-0
HGYX002.xml
src/main/java/com/baosight/hggp/hg/yx/sql/HGYX002.xml
+3
-0
HGYX002A.xml
src/main/java/com/baosight/hggp/hg/yx/sql/HGYX002A.xml
+3
-0
HGYX002C.xml
src/main/java/com/baosight/hggp/hg/yx/sql/HGYX002C.xml
+3
-0
ExcelUtils.java
src/main/java/com/baosight/hggp/util/ExcelUtils.java
+1
-0
HGKC004.jsp
src/main/webapp/HG/KC/HGKC004.jsp
+2
-2
HGKC013.js
src/main/webapp/HG/KC/HGKC013.js
+9
-10
HGKC013.jsp
src/main/webapp/HG/KC/HGKC013.jsp
+2
-2
HGYX001.js
src/main/webapp/HG/YX/HGYX001.js
+5
-5
HGYX001.jsp
src/main/webapp/HG/YX/HGYX001.jsp
+2
-2
HGYX001A.js
src/main/webapp/HG/YX/HGYX001A.js
+12
-8
HGYX001A.jsp
src/main/webapp/HG/YX/HGYX001A.jsp
+1
-1
HGYX002.js
src/main/webapp/HG/YX/HGYX002.js
+2
-2
HGYX002.jsp
src/main/webapp/HG/YX/HGYX002.jsp
+1
-1
HGYX002A.js
src/main/webapp/HG/YX/HGYX002A.js
+2
-2
HGYX002A.jsp
src/main/webapp/HG/YX/HGYX002A.jsp
+1
-1
HGYX002B.jsp
src/main/webapp/HG/YX/HGYX002B.jsp
+1
-1
No files found.
src/main/java/com/baosight/hggp/hg/kc/service/ServiceHGKC004.java
View file @
c98b67dd
...
...
@@ -4,6 +4,7 @@ import com.baosight.hggp.aspect.annotation.OperationLogAnnotation;
import
com.baosight.hggp.common.DdynamicEnum
;
import
com.baosight.hggp.core.constant.CommonConstant
;
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.kc.domain.HGKC004
;
...
...
@@ -12,12 +13,11 @@ import com.baosight.hggp.hg.kc.domain.HGKC010;
import
com.baosight.hggp.hg.kc.tools.HGKCTools
;
import
com.baosight.hggp.hg.pz.domain.HGPZ005
;
import
com.baosight.hggp.hg.pz.tools.HGPZTools
;
import
com.baosight.hggp.hg.sb.domain.HGSB001
;
import
com.baosight.hggp.hg.sb.domain.HGSB002
;
import
com.baosight.hggp.hg.sb.tools.HGSBTools
;
import
com.baosight.hggp.util.AssertUtils
;
import
com.baosight.hggp.util.CommonMethod
;
import
com.baosight.hggp.util.DateUtils
;
import
com.baosight.hggp.util.LogUtils
;
import
com.baosight.hggp.hg.xs.domain.Company
;
import
com.baosight.hggp.util.*
;
import
com.baosight.hggp.util.contants.ACConstants
;
import
com.baosight.iplat4j.core.ei.EiBlock
;
import
com.baosight.iplat4j.core.ei.EiConstant
;
...
...
@@ -40,7 +40,12 @@ public class ServiceHGKC004 extends ServiceEPBase {
@Override
public
EiInfo
initLoad
(
EiInfo
inInfo
)
{
EiInfo
outEiInfo
=
super
.
initLoad
(
inInfo
,
new
HGKC004
());
CommonMethod
.
initBlock
(
outEiInfo
,
Arrays
.
asList
(
DdynamicEnum
.
WH_RECORD_BLOCK_ID
,
DdynamicEnum
.
COMPANY_BOX_BLOCK_ID
),
null
,
false
);
try
{
EiInfoUtils
.
addBlock
(
outEiInfo
,
"roleCompany"
,
UserSessionUtils
.
getRoleCompany
(),
Company
.
class
);
CommonMethod
.
initBlock
(
outEiInfo
,
Arrays
.
asList
(
DdynamicEnum
.
WH_RECORD_BLOCK_ID
),
null
,
false
);
}
catch
(
Exception
e
){
LogUtils
.
setDetailMsg
(
inInfo
,
e
,
"初始化失败"
);
}
return
outEiInfo
;
}
...
...
@@ -50,6 +55,11 @@ public class ServiceHGKC004 extends ServiceEPBase {
if
(
CollectionUtils
.
isNotEmpty
(
Collections
.
singleton
(
receiptDate
)))
{
inInfo
.
setCell
(
EiConstant
.
queryBlock
,
ACConstants
.
ROW_CODE_0
,
HGKC004
.
FIELD_RECEIPT_DATE
,
DateUtils
.
formatShort
(
receiptDate
));
}
//角色公司
List
<
String
>
roleCompanyCode
=
HGSBTools
.
getRoleCompanyCode
();
if
(!
roleCompanyCode
.
isEmpty
()){
inInfo
.
setCell
(
EiConstant
.
queryBlock
,
ACConstants
.
ROW_CODE_0
,
HGSB001
.
FIELD_COMPANY_CODES
,
roleCompanyCode
);
}
return
super
.
query
(
inInfo
,
HGKC004
.
QUERY
,
new
HGKC004
());
}
...
...
src/main/java/com/baosight/hggp/hg/kc/service/ServiceHGKC013.java
View file @
c98b67dd
...
...
@@ -5,11 +5,15 @@ import com.baosight.hggp.common.DdynamicEnum;
import
com.baosight.hggp.common.InventorySource
;
import
com.baosight.hggp.core.constant.CommonConstant
;
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.cw.tools.HGCWTools
;
import
com.baosight.hggp.hg.cw.vo.UserVO
;
import
com.baosight.hggp.hg.kc.domain.*
;
import
com.baosight.hggp.hg.kc.tools.HGKCTools
;
import
com.baosight.hggp.hg.sb.domain.HGSB001
;
import
com.baosight.hggp.hg.sb.tools.HGSBTools
;
import
com.baosight.hggp.hg.xs.domain.Company
;
import
com.baosight.hggp.util.*
;
import
com.baosight.hggp.util.contants.ACConstants
;
import
com.baosight.iplat4j.core.ei.EiBlock
;
...
...
@@ -33,13 +37,16 @@ public class ServiceHGKC013 extends ServiceEPBase {
@Override
public
EiInfo
initLoad
(
EiInfo
inInfo
)
{
UserVO
userVO
=
HGCWTools
.
HgCw002
.
getUserCompany
();
inInfo
.
setCell
(
EiConstant
.
queryBlock
,
ACConstants
.
ROW_CODE_0
,
HGKC013
.
FIELD_DELETE_FLAG
,
CommonConstant
.
YesNo
.
NO_0
);
inInfo
=
super
.
query
(
inInfo
,
HGKC013
.
QUERY
,
new
HGKC013
()
);
try
{
inInfo
=
super
.
initLoad
(
inInfo
,
new
HGKC013
()
);
//UserVO userVO = HGCWTools.HgCw002.getUserCompany(
);
inInfo
.
getBlock
(
EiConstant
.
resultBlock
).
setBlockMeta
(
new
HGKC013
().
eiMetadata
);
CommonMethod
.
initBlock
(
inInfo
,
Arrays
.
asList
(
DdynamicEnum
.
COMPANY_BOX_BLOCK_ID
,
DdynamicEnum
.
WH_RECORD_BOX_BLOCK_ID
));
inInfo
.
set
(
HGKC013
.
FIELD_COMPANY_CODE
,
userVO
.
getUsercode
());
//inInfo.setCell(EiConstant.queryBlock, ACConstants.ROW_CODE_0, HGKC013.FIELD_COMPANY_CODE, userVO.getUsercode());
EiInfoUtils
.
addBlock
(
inInfo
,
"roleCompany"
,
UserSessionUtils
.
getRoleCompany
(),
Company
.
class
);
CommonMethod
.
initBlock
(
inInfo
,
Arrays
.
asList
(
DdynamicEnum
.
WH_RECORD_BOX_BLOCK_ID
));
//inInfo.set(HGKC013.FIELD_COMPANY_CODE, userVO.getUsercode());
}
catch
(
Exception
e
){
LogUtils
.
setDetailMsg
(
inInfo
,
e
,
"初始化失败"
);
}
return
inInfo
;
}
...
...
@@ -50,6 +57,11 @@ public class ServiceHGKC013 extends ServiceEPBase {
if
(
StringUtils
.
isNotEmpty
(
receiptDate
)){
inInfo
.
setCell
(
EiConstant
.
queryBlock
,
ACConstants
.
ROW_CODE_0
,
HGKC013
.
FIELD_RECEIPT_DATE
,
DateUtils
.
formatShort
(
receiptDate
));
}
//角色公司
List
<
String
>
roleCompanyCode
=
HGSBTools
.
getRoleCompanyCode
();
if
(!
roleCompanyCode
.
isEmpty
()){
inInfo
.
setCell
(
EiConstant
.
queryBlock
,
ACConstants
.
ROW_CODE_0
,
HGSB001
.
FIELD_COMPANY_CODES
,
roleCompanyCode
);
}
return
super
.
query
(
inInfo
,
HGKC013
.
QUERY
,
new
HGKC013
());
}
...
...
src/main/java/com/baosight/hggp/hg/kc/sql/HGKC001.xml
View file @
c98b67dd
...
...
@@ -266,4 +266,25 @@
ID = #id#
</update>
<select
id=
"queryList"
resultClass=
"com.baosight.hggp.hg.kc.domain.HGKC001"
>
SELECT
<include
refid=
"column"
/>
FROM ${hggpSchema}.HGKC001
WHERE 1=1 AND DELETE_FLAG = 0
<include
refid=
"HGXSDataAuth.authCondition"
/>
<isNotEmpty
prepend=
" AND "
property=
"accountCode"
>
ACCOUNT_CODE = #accountCode#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"depCode"
>
DEP_CODE = #depCode#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"companyCode"
>
COMPANY_CODE = #companyCode#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"accountPeriod"
>
LEFT(DEPOSIT_DATE,6) = #accountPeriod#
</isNotEmpty>
<include
refid=
"orderBy"
/>
</select>
</sqlMap>
src/main/java/com/baosight/hggp/hg/kc/sql/HGKC004.xml
View file @
c98b67dd
...
...
@@ -94,6 +94,9 @@
<isNotEmpty
prepend=
" AND "
property=
"saleOutCodes"
>
SALE_OUT_CODE IN
<iterate
close=
")"
open=
"("
conjunction=
","
property=
"saleOutCodes"
>
#saleOutCodes[]#
</iterate>
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"companyCodes"
>
COMPANY_CODE IN
<iterate
close=
")"
open=
"("
conjunction=
","
property=
"companyCodes"
>
#companyCodes[]#
</iterate>
</isNotEmpty>
</sql>
<!-- 公共修改字段 -->
<sql
id=
"updateRevise"
>
...
...
@@ -274,6 +277,9 @@
<isNotEmpty
prepend=
" AND "
property=
"status"
>
STATUS = #status#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"companyCodes"
>
COMPANY_CODE IN
<iterate
close=
")"
open=
"("
conjunction=
","
property=
"companyCodes"
>
#companyCodes[]#
</iterate>
</isNotEmpty>
<dynamic
prepend=
"ORDER BY"
>
<isNotEmpty
property=
"orderBy"
>
$orderBy$
...
...
src/main/java/com/baosight/hggp/hg/kc/sql/HGKC010.xml
View file @
c98b67dd
...
...
@@ -89,6 +89,9 @@
<isNotEmpty
prepend=
" AND "
property=
"isAmount"
>
INV_QTY != 0
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"companyCodes"
>
COMPANY_CODE IN
<iterate
close=
")"
open=
"("
conjunction=
","
property=
"companyCodes"
>
#companyCodes[]#
</iterate>
</isNotEmpty>
</sql>
<sql
id=
"idCondition"
>
...
...
src/main/java/com/baosight/hggp/hg/kc/sql/HGKC013.xml
View file @
c98b67dd
...
...
@@ -133,6 +133,9 @@
<isNotEmpty
prepend=
" AND "
property=
"status"
>
STATUS = #status#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"companyCodes"
>
COMPANY_CODE IN
<iterate
close=
")"
open=
"("
conjunction=
","
property=
"companyCodes"
>
#companyCodes[]#
</iterate>
</isNotEmpty>
</sql>
<!-- 公共修改字段 -->
<sql
id=
"updateRevise"
>
...
...
src/main/java/com/baosight/hggp/hg/sj/service/ServiceHGSJ003.java
View file @
c98b67dd
...
...
@@ -7,6 +7,7 @@ import com.baosight.hggp.core.dao.DaoUtils;
import
com.baosight.hggp.core.enums.OrgTypeEnum
;
import
com.baosight.hggp.core.security.UserSessionUtils
;
import
com.baosight.hggp.hg.sb.domain.HGSB001
;
import
com.baosight.hggp.hg.sb.tools.HGSBTools
;
import
com.baosight.hggp.hg.sj.domain.HGSJ002
;
import
com.baosight.hggp.hg.sj.domain.HGSJ002A
;
import
com.baosight.hggp.hg.sj.domain.HGSJ003
;
...
...
@@ -203,10 +204,10 @@ public class ServiceHGSJ003 extends ServiceEPBase {
try
{
Map
<
String
,
Object
>
params
=
new
HashMap
<>(
10
);
String
fileName
=
inInfo
.
getString
(
"fileName"
);
Map
<
String
,
Object
>
map
=
HGSJTools
.
Hgsj003
.
getCompany
(
UserSession
.
getLoginName
(),
OrgTypeEnum
.
COMPANY
.
getCode
());
//
Map<String,Object> map = HGSJTools.Hgsj003.getCompany(UserSession.getLoginName(),OrgTypeEnum.COMPANY.getCode());
params
.
put
(
HGSJ003
.
FIELD_ACCOUNT_CODE
,
UserSessionUtils
.
getAccountCode
());
params
.
put
(
HGSJ003
.
FIELD_FACTORY_CODE
,
map
.
get
(
"orgEname"
));
params
.
put
(
HGSJ003
.
FIELD_FACTORY_NAME
,
map
.
get
(
"orgCname"
));
//
params.put(HGSJ003.FIELD_FACTORY_CODE, map.get("orgEname"));
//
params.put(HGSJ003.FIELD_FACTORY_NAME, map.get("orgCname"));
//解析文件,将文件中数据传入到inInfo中
ExcelUtils
.
importFromExcel
(
inInfo
,
fileName
,
params
,
new
HGSJ003
());
}
catch
(
Exception
e
){
...
...
@@ -219,31 +220,18 @@ public class ServiceHGSJ003 extends ServiceEPBase {
@OperationLogAnnotation
(
operModul
=
"工艺单价"
,
operType
=
"下载模板"
,
operDesc
=
"下载模板"
)
public
EiInfo
downloadTemplate
(
EiInfo
inInfo
){
Map
<
String
,
Object
>
param
=
new
HashMap
<>(
4
);
List
<
Org
>
orgList
=
HGXSTools
.
XsOrg
.
queryByUser
();
if
(
CollectionUtils
.
isNotEmpty
(
orgList
)){
Org
org
=
orgList
.
get
(
0
);
if
(!
"company"
.
equals
(
org
.
getOrgType
()))
{
//如果不是公司公司,则找到上一级
List
<
Org
>
orgList1
=
HGXSTools
.
XsOrg
.
queryParent
(
org
.
getOrgId
());
for
(
Org
org1:
orgList1
)
{
if
(
"company"
.
equals
(
org1
.
getOrgType
())
&&
!
"root"
.
equals
(
org1
.
getParentOrgId
()))
{
param
.
put
(
HGSJ003
.
FIELD_FACTORY_CODE
,
org1
.
getOrgId
());
param
.
put
(
HGSJ003
.
FIELD_FACTORY_NAME
,
org1
.
getOrgCname
());
}
}
}
else
{
param
.
put
(
HGSJ003
.
FIELD_FACTORY_CODE
,
org
.
getOrgId
());
param
.
put
(
HGSJ003
.
FIELD_FACTORY_NAME
,
org
.
getOrgCname
());
}
}
//角色公司
List
<
String
>
roleCompanyCode
=
HGSBTools
.
getRoleCompanyCode
();
param
.
put
(
"factoryCodes"
,
roleCompanyCode
);
param
.
put
(
HGSJ003
.
FIELD_DELETE_FLAG
,
CommonConstant
.
YesNo
.
NO_0
);
param
.
put
(
HGSJ003
.
FIELD_STATUS
,
CommonConstant
.
YesNo
.
YES_1
);
//param.put("orgType", OrgTypeEnum.COMPANY.getCode());
//param.put("loginName",UserSession.getLoginName());
param
.
put
(
HGSJ003
.
FIELD_ACCOUNT_CODE
,
UserSessionUtils
.
getAccountCode
());
List
list
=
new
ArrayList
<>(
Arrays
.
asList
(
HGSJ003
.
FIELD_PROCESS_CODE
,
HGSJ003
.
FIELD_PROCESS_NAME
,
HGSJ003
.
FIELD_PROCESS_CLASS_NAME
,
HGSJ003
.
FIELD_UNIT
,
HGSJ003
.
FIELD_LENGTH
,
HGSJ003
.
FIELD_WIDTH
,
HGSJ003
.
FIELD_THICK
));
List
list
=
new
ArrayList
<>(
Arrays
.
asList
(
HGSJ003
.
FIELD_
FACTORY_CODE
,
HGSJ003
.
FIELD_FACTORY_NAME
,
HGSJ003
.
FIELD_
PROCESS_CODE
,
HGSJ003
.
FIELD_PROCESS_NAME
,
HGSJ003
.
FIELD_PROCESS_CLASS_NAME
,
HGSJ003
.
FIELD_UNIT
,
HGSJ003
.
FIELD_LENGTH
,
HGSJ003
.
FIELD_WIDTH
,
HGSJ003
.
FIELD_THICK
,
HGSJ003
.
FIELD_PRICE
));
return
ExcelUtils
.
exportToExcel
(
ACConstants
.
SQL_COUNT
,
ACConstants
.
SQL_TEMPLATE
,
param
,
list
,
new
HGSJ003
());
}
...
...
src/main/java/com/baosight/hggp/hg/sj/sql/HGSJ003.xml
View file @
c98b67dd
...
...
@@ -361,15 +361,21 @@
<select
id=
"template"
parameterClass=
"java.util.HashMap"
resultClass=
"java.util.HashMap"
>
select
FACTORY_CODE as "factoryCode",
FACTORY_NAME as "factoryName",
PROCESS_CODE as "processCode",
PROCESS_NAME as "processName",
'' as "processClassName",
UNIT as "unit",
'' as "length",
'' as "width",
'' as "thick"
'' as "thick",
'' as "price"
from ${hggpSchema}.hggy001
where ACCOUNT_CODE = #accountCode#
<isNotEmpty
prepend=
" AND "
property=
"factoryCodes"
>
FACTORY_CODE IN
<iterate
close=
")"
open=
"("
conjunction=
","
property=
"factoryCodes"
>
#factoryCodes[]#
</iterate>
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"deleteFlag"
>
DELETE_FLAG = #deleteFlag#
</isNotEmpty>
...
...
src/main/java/com/baosight/hggp/hg/yx/service/ServiceHGYX001.java
View file @
c98b67dd
...
...
@@ -4,6 +4,7 @@ import com.baosight.hggp.aspect.annotation.OperationLogAnnotation;
import
com.baosight.hggp.common.DdynamicEnum
;
import
com.baosight.hggp.core.constant.CommonConstant
;
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.cw.tools.HGCWTools
;
import
com.baosight.hggp.hg.cw.vo.UserVO
;
...
...
@@ -13,7 +14,10 @@ import com.baosight.hggp.hg.kc.domain.HGKC010;
import
com.baosight.hggp.hg.kc.tools.HGKCTools
;
import
com.baosight.hggp.hg.pz.domain.HGPZ005
;
import
com.baosight.hggp.hg.pz.tools.HGPZTools
;
import
com.baosight.hggp.hg.sb.domain.HGSB001
;
import
com.baosight.hggp.hg.sb.tools.HGSBTools
;
import
com.baosight.hggp.hg.sc.domain.HGSC001
;
import
com.baosight.hggp.hg.xs.domain.Company
;
import
com.baosight.hggp.hg.yx.domain.HGYX001
;
import
com.baosight.hggp.hg.yx.domain.HGYX001A
;
import
com.baosight.hggp.hg.yx.domain.HGYX002
;
...
...
@@ -45,18 +49,34 @@ public class ServiceHGYX001 extends ServiceEPBase {
@Override
public
EiInfo
initLoad
(
EiInfo
inInfo
)
{
EiInfo
outInfo
=
super
.
initLoad
(
inInfo
,
EiConstant
.
resultBlock
,
new
HGYX001
());
UserVO
userVO
=
HGCWTools
.
HgCw002
.
getUserCompany
();
outInfo
.
setCell
(
EiConstant
.
queryBlock
,
ACConstants
.
ROW_CODE_0
,
HGYX001
.
FIELD_DELETE_FLAG
,
CommonConstant
.
YesNo
.
NO_0
);
outInfo
.
getBlock
(
EiConstant
.
resultBlock
).
setBlockMeta
(
new
HGYX001
().
eiMetadata
);
CommonMethod
.
initBlock
(
outInfo
,
Arrays
.
asList
(
DdynamicEnum
.
COMPANY_BOX_BLOCK_ID
,
DdynamicEnum
.
PROJ_RECORD_BLOCK_ID
,
DdynamicEnum
.
WH_RECORD_BOX_BLOCK_ID
,
DdynamicEnum
.
CUSTOMER_RECORD_ALL_BLOCK_ID
));
outInfo
.
set
(
HGYX001
.
FIELD_COMPANY_CODE
,
userVO
.
getUsercode
());
try
{
EiInfoUtils
.
addBlock
(
outInfo
,
"roleCompany"
,
UserSessionUtils
.
getRoleCompany
(),
Company
.
class
);
CommonMethod
.
initBlock
(
outInfo
,
Arrays
.
asList
(
DdynamicEnum
.
WH_RECORD_BOX_BLOCK_ID
,
DdynamicEnum
.
CUSTOMER_RECORD_ALL_BLOCK_ID
)
);
List
<
String
>
roleCompanyCode
=
HGSBTools
.
getRoleCompanyCode
();
CommonMethod
.
initBlock
(
outInfo
,
Arrays
.
asList
(
DdynamicEnum
.
PROJ_RECORD_BLOCK_ID
),
new
HashMap
<
String
,
Object
>(){{
put
(
HGSB001
.
FIELD_COMPANY_CODES
,
roleCompanyCode
);
}}
);
}
catch
(
Exception
e
){
LogUtils
.
setDetailMsg
(
outInfo
,
e
,
"初始化失败"
);
}
return
outInfo
;
}
@Override
public
EiInfo
query
(
EiInfo
inInfo
)
{
inInfo
.
setCell
(
EiConstant
.
queryBlock
,
ACConstants
.
ROW_CODE_0
,
HGYX001
.
FIELD_DELETE_FLAG
,
CommonConstant
.
YesNo
.
NO_0
);
//角色公司
List
<
String
>
roleCompanyCode
=
HGSBTools
.
getRoleCompanyCode
();
if
(!
roleCompanyCode
.
isEmpty
()){
inInfo
.
setCell
(
EiConstant
.
queryBlock
,
ACConstants
.
ROW_CODE_0
,
HGSB001
.
FIELD_COMPANY_CODES
,
roleCompanyCode
);
}
return
super
.
query
(
inInfo
,
HGYX001
.
QUERY
,
new
HGYX001
());
}
...
...
src/main/java/com/baosight/hggp/hg/yx/service/ServiceHGYX001A.java
View file @
c98b67dd
...
...
@@ -4,15 +4,20 @@ import com.baosight.hggp.aspect.annotation.OperationLogAnnotation;
import
com.baosight.hggp.common.DdynamicEnum
;
import
com.baosight.hggp.core.constant.CommonConstant
;
import
com.baosight.hggp.core.dao.DaoUtils
;
import
com.baosight.hggp.core.security.UserSessionUtils
;
import
com.baosight.hggp.hg.cw.tools.HGCWTools
;
import
com.baosight.hggp.hg.cw.vo.UserVO
;
import
com.baosight.hggp.hg.kc.domain.HGKC010
;
import
com.baosight.hggp.hg.kc.domain.HGKC013
;
import
com.baosight.hggp.hg.kc.domain.HGKC013A
;
import
com.baosight.hggp.hg.sb.domain.HGSB001
;
import
com.baosight.hggp.hg.sb.tools.HGSBTools
;
import
com.baosight.hggp.hg.xs.domain.Company
;
import
com.baosight.hggp.hg.yx.domain.HGYX001
;
import
com.baosight.hggp.hg.yx.domain.HGYX001A
;
import
com.baosight.hggp.hg.yx.tools.HGYXTools
;
import
com.baosight.hggp.util.CommonMethod
;
import
com.baosight.hggp.util.EiInfoUtils
;
import
com.baosight.hggp.util.LogUtils
;
import
com.baosight.hggp.util.contants.ACConstants
;
import
com.baosight.iplat4j.core.ei.EiBlock
;
...
...
@@ -22,10 +27,7 @@ import com.baosight.iplat4j.core.exception.PlatException;
import
com.baosight.iplat4j.core.resource.I18nMessages
;
import
com.baosight.iplat4j.core.service.impl.ServiceEPBase
;
import
java.util.Arrays
;
import
java.util.Collections
;
import
java.util.HashMap
;
import
java.util.Map
;
import
java.util.*
;
/**
* @author LiuYang
...
...
@@ -35,9 +37,10 @@ public class ServiceHGYX001A extends ServiceEPBase {
@Override
public
EiInfo
initLoad
(
EiInfo
inInfo
)
{
EiInfo
outInfo
=
super
.
initLoad
(
inInfo
,
new
HGYX001A
());
try
{
String
id
=
inInfo
.
getCellStr
(
EiConstant
.
queryBlock
,
ACConstants
.
ROW_CODE_0
,
HGYX001A
.
FIELD_PARENT_ID
);
String
type
=
inInfo
.
getCellStr
(
EiConstant
.
queryBlock
,
ACConstants
.
ROW_CODE_0
,
"type"
);
EiInfo
outInfo
=
super
.
initLoad
(
inInfo
,
new
HGYX001A
());
outInfo
.
getBlock
(
EiConstant
.
resultBlock
).
getRows
().
clear
();
if
(
id
!=
null
)
{
HGYX001
hgYx001
=
HGYXTools
.
Hgyx001
.
getId
(
Long
.
valueOf
(
id
));
...
...
@@ -47,12 +50,9 @@ public class ServiceHGYX001A extends ServiceEPBase {
outInfo
.
getBlock
(
EiConstant
.
queryBlock
).
setRows
(
Collections
.
singletonList
(
hgYx001
));
}
outInfo
.
setCell
(
EiConstant
.
queryBlock
,
ACConstants
.
ROW_CODE_0
,
"type"
,
type
);
UserVO
userVO
=
HGCWTools
.
HgCw002
.
getUserCompany
();
outInfo
.
getBlock
(
EiConstant
.
resultBlock
).
setBlockMeta
(
new
HGYX001A
().
eiMetadata
);
CommonMethod
.
initBlock
(
outInfo
,
Arrays
.
asList
(
DdynamicEnum
.
COMPANY_BOX_BLOCK_ID
,
DdynamicEnum
.
CUSTOMER_RECORD_ALL_BLOCK_ID
));
List
<
String
>
roleCompanyCode
=
HGSBTools
.
getRoleCompanyCode
();
EiInfoUtils
.
addBlock
(
outInfo
,
"roleCompany"
,
UserSessionUtils
.
getRoleCompany
(),
Company
.
class
);
CommonMethod
.
initBlock
(
outInfo
,
Arrays
.
asList
(
DdynamicEnum
.
CUSTOMER_RECORD_ALL_BLOCK_ID
));
CommonMethod
.
initBlock
(
outInfo
,
Arrays
.
asList
(
DdynamicEnum
.
PROJ_RECORD_BLOCK_ID
,
...
...
@@ -61,19 +61,22 @@ public class ServiceHGYX001A extends ServiceEPBase {
DdynamicEnum
.
SPEC_BOX_BLOCK_ID
,
DdynamicEnum
.
WH_RECORD_BOX_BLOCK_ID
),
new
HashMap
<
String
,
Object
>(){{
put
(
HGKC013
.
FIELD_COMPANY_CODE
,
userVO
.
getUsercode
()
);
put
(
HGSB001
.
FIELD_COMPANY_CODES
,
roleCompanyCode
);
put
(
HGKC013A
.
FIELD_DELETE_FLAG
,
CommonConstant
.
YesNo
.
NO_0
);
}},
false
);
outInfo
.
setCell
(
EiConstant
.
queryBlock
,
ACConstants
.
ROW_CODE_0
,
HGYX001
.
FIELD_COMPANY_CODE
,
userVO
.
getUsercode
());
outInfo
.
setCell
(
EiConstant
.
queryBlock
,
ACConstants
.
ROW_CODE_0
,
HGYX001
.
FIELD_COMPANY_NAME
,
userVO
.
getUsername
());
//outInfo.setCell(EiConstant.queryBlock, ACConstants.ROW_CODE_0,HGYX001.FIELD_CONS_CODE, userVO.getUsercode());
//outInfo.setCell(EiConstant.queryBlock, ACConstants.ROW_CODE_0,HGYX001.FIELD_CONS_NAME, userVO.getUsername());
}
catch
(
Exception
e
){
LogUtils
.
setDetailMsg
(
outInfo
,
e
,
"初始化失败"
);
}
return
outInfo
;
}
@Override
public
EiInfo
query
(
EiInfo
inInfo
)
{
inInfo
.
setCell
(
EiConstant
.
queryBlock
,
ACConstants
.
ROW_CODE_0
,
HGYX001
.
FIELD_DELETE_FLAG
,
CommonConstant
.
YesNo
.
NO_0
);
List
<
String
>
roleCompanyCode
=
HGSBTools
.
getRoleCompanyCode
();
if
(!
roleCompanyCode
.
isEmpty
()){
inInfo
.
setCell
(
EiConstant
.
queryBlock
,
ACConstants
.
ROW_CODE_0
,
HGSB001
.
FIELD_COMPANY_CODES
,
roleCompanyCode
);
}
return
super
.
query
(
inInfo
,
HGYX001A
.
QUERY
,
new
HGYX001A
());
}
...
...
src/main/java/com/baosight/hggp/hg/yx/service/ServiceHGYX001B.java
View file @
c98b67dd
...
...
@@ -2,14 +2,19 @@ package com.baosight.hggp.hg.yx.service;
import
com.baosight.hggp.common.DdynamicEnum
;
import
com.baosight.hggp.core.constant.CommonConstant
;
import
com.baosight.hggp.core.security.UserSessionUtils
;
import
com.baosight.hggp.hg.cw.tools.HGCWTools
;
import
com.baosight.hggp.hg.cw.vo.UserVO
;
import
com.baosight.hggp.hg.kc.domain.HGKC013
;
import
com.baosight.hggp.hg.kc.domain.HGKC013A
;
import
com.baosight.hggp.hg.sb.domain.HGSB001
;
import
com.baosight.hggp.hg.sb.tools.HGSBTools
;
import
com.baosight.hggp.hg.xs.domain.Company
;
import
com.baosight.hggp.hg.yx.domain.HGYX001
;
import
com.baosight.hggp.hg.yx.domain.HGYX001A
;
import
com.baosight.hggp.hg.yx.tools.HGYXTools
;
import
com.baosight.hggp.util.CommonMethod
;
import
com.baosight.hggp.util.EiInfoUtils
;
import
com.baosight.hggp.util.StringUtils
;
import
com.baosight.hggp.util.contants.ACConstants
;
import
com.baosight.iplat4j.core.ei.EiConstant
;
...
...
@@ -19,6 +24,7 @@ import com.baosight.iplat4j.core.service.impl.ServiceEPBase;
import
java.util.Arrays
;
import
java.util.Collections
;
import
java.util.HashMap
;
import
java.util.List
;
/**
* @author LiuYang
...
...
@@ -38,7 +44,8 @@ public class ServiceHGYX001B extends ServiceEPBase {
outInfo
.
getBlock
(
EiConstant
.
queryBlock
).
setRows
(
Collections
.
singletonList
(
hgYx001
));
}
UserVO
userVO
=
HGCWTools
.
HgCw002
.
getUserCompany
();
//UserVO userVO = HGCWTools.HgCw002.getUserCompany();
List
<
String
>
roleCompanyCode
=
HGSBTools
.
getRoleCompanyCode
();
outInfo
.
getBlock
(
EiConstant
.
resultBlock
).
setBlockMeta
(
new
HGYX001
().
eiMetadata
);
CommonMethod
.
initBlock
(
outInfo
,
Arrays
.
asList
(
...
...
@@ -52,13 +59,13 @@ public class ServiceHGYX001B extends ServiceEPBase {
DdynamicEnum
.
INVENT_CODE_BOX_BLOCK_ID
,
DdynamicEnum
.
SPEC_BOX_BLOCK_ID
),
new
HashMap
<
String
,
Object
>(){{
put
(
HG
KC013
.
FIELD_COMPANY_CODE
,
userVO
.
getUsercode
()
);
put
(
HG
SB001
.
FIELD_COMPANY_CODES
,
roleCompanyCode
);
put
(
HGKC013A
.
FIELD_DELETE_FLAG
,
CommonConstant
.
YesNo
.
NO_0
);
}},
false
);
outInfo
.
setCell
(
EiConstant
.
queryBlock
,
ACConstants
.
ROW_CODE_0
,
HGYX001
.
FIELD_COMPANY_CODE
,
userVO
.
getUsercode
());
outInfo
.
setCell
(
EiConstant
.
queryBlock
,
ACConstants
.
ROW_CODE_0
,
HGYX001
.
FIELD_COMPANY_NAME
,
userVO
.
getUsername
());
outInfo
.
setCell
(
EiConstant
.
queryBlock
,
ACConstants
.
ROW_CODE_0
,
HGYX001
.
FIELD_CONS_CODE
,
userVO
.
getUsercode
());
outInfo
.
setCell
(
EiConstant
.
queryBlock
,
ACConstants
.
ROW_CODE_0
,
HGYX001
.
FIELD_CONS_NAME
,
userVO
.
getUsername
());
//
outInfo.setCell(EiConstant.queryBlock, ACConstants.ROW_CODE_0,HGYX001.FIELD_COMPANY_CODE, userVO.getUsercode());
//
outInfo.setCell(EiConstant.queryBlock, ACConstants.ROW_CODE_0,HGYX001.FIELD_COMPANY_NAME, userVO.getUsername());
//
outInfo.setCell(EiConstant.queryBlock, ACConstants.ROW_CODE_0,HGYX001.FIELD_CONS_CODE, userVO.getUsercode());
//
outInfo.setCell(EiConstant.queryBlock, ACConstants.ROW_CODE_0,HGYX001.FIELD_CONS_NAME, userVO.getUsername());
return
outInfo
;
}
...
...
src/main/java/com/baosight/hggp/hg/yx/service/ServiceHGYX001C.java
View file @
c98b67dd
...
...
@@ -5,6 +5,8 @@ import com.baosight.hggp.core.constant.CommonConstant;
import
com.baosight.hggp.hg.cw.tools.HGCWTools
;
import
com.baosight.hggp.hg.cw.vo.UserVO
;
import
com.baosight.hggp.hg.kc.domain.HGKC010
;
import
com.baosight.hggp.hg.sb.domain.HGSB001
;
import
com.baosight.hggp.hg.sb.tools.HGSBTools
;
import
com.baosight.hggp.hg.yx.domain.HGYX001
;
import
com.baosight.hggp.hg.yx.domain.HGYX001C
;
import
com.baosight.hggp.util.CommonMethod
;
...
...
@@ -15,6 +17,7 @@ import com.baosight.iplat4j.core.ei.EiInfo;
import
com.baosight.iplat4j.core.service.impl.ServiceEPBase
;
import
java.util.Arrays
;
import
java.util.List
;
/**
* @author LiuYang
...
...
@@ -44,6 +47,11 @@ public class ServiceHGYX001C extends ServiceEPBase {
@Override
public
EiInfo
query
(
EiInfo
inInfo
)
{
inInfo
.
setCell
(
EiConstant
.
queryBlock
,
ACConstants
.
ROW_CODE_0
,
HGYX001
.
FIELD_DELETE_FLAG
,
CommonConstant
.
YesNo
.
NO_0
);
//角色公司
List
<
String
>
roleCompanyCode
=
HGSBTools
.
getRoleCompanyCode
();
if
(!
roleCompanyCode
.
isEmpty
()){
inInfo
.
setCell
(
EiConstant
.
queryBlock
,
ACConstants
.
ROW_CODE_0
,
HGSB001
.
FIELD_COMPANY_CODES
,
roleCompanyCode
);
}
return
super
.
query
(
inInfo
,
HGYX001C
.
QUERY
,
new
HGYX001C
());
}
}
src/main/java/com/baosight/hggp/hg/yx/service/ServiceHGYX002.java
View file @
c98b67dd
...
...
@@ -4,18 +4,19 @@ import com.baosight.hggp.aspect.annotation.OperationLogAnnotation;
import
com.baosight.hggp.common.DdynamicEnum
;
import
com.baosight.hggp.core.constant.CommonConstant
;
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.cw.tools.HGCWTools
;
import
com.baosight.hggp.hg.cw.vo.UserVO
;
import
com.baosight.hggp.hg.kc.domain.HGKC004
;
import
com.baosight.hggp.hg.kc.domain.HGKC004A
;
import
com.baosight.hggp.hg.sb.domain.HGSB001
;
import
com.baosight.hggp.hg.sb.tools.HGSBTools
;
import
com.baosight.hggp.hg.xs.domain.Company
;
import
com.baosight.hggp.hg.yx.domain.HGYX002
;
import
com.baosight.hggp.hg.yx.domain.HGYX002A
;
import
com.baosight.hggp.hg.yx.tools.HGYXTools
;
import
com.baosight.hggp.util.AssertUtils
;
import
com.baosight.hggp.util.CommonMethod
;
import
com.baosight.hggp.util.DateUtils
;
import
com.baosight.hggp.util.LogUtils
;
import
com.baosight.hggp.util.*
;
import
com.baosight.hggp.util.contants.ACConstants
;
import
com.baosight.iplat4j.core.ei.EiBlock
;
import
com.baosight.iplat4j.core.ei.EiConstant
;
...
...
@@ -40,18 +41,35 @@ public class ServiceHGYX002 extends ServiceEPBase {
@Override
public
EiInfo
initLoad
(
EiInfo
inInfo
)
{
EiInfo
outInfo
=
super
.
initLoad
(
inInfo
,
EiConstant
.
resultBlock
,
new
HGYX002
());
UserVO
userVO
=
HGCWTools
.
HgCw002
.
getUserCompany
();
try
{
EiInfoUtils
.
addBlock
(
outInfo
,
"roleCompany"
,
UserSessionUtils
.
getRoleCompany
(),
Company
.
class
);
outInfo
.
setCell
(
EiConstant
.
queryBlock
,
ACConstants
.
ROW_CODE_0
,
HGYX002
.
FIELD_DELETE_FLAG
,
CommonConstant
.
YesNo
.
NO_0
);
outInfo
.
getBlock
(
EiConstant
.
resultBlock
).
setBlockMeta
(
new
HGYX002
().
eiMetadata
);
CommonMethod
.
initBlock
(
outInfo
,
Arrays
.
asList
(
DdynamicEnum
.
COMPANY_BOX_BLOCK_ID
,
DdynamicEnum
.
PROJ_RECORD_BLOCK_ID
,
DdynamicEnum
.
WH_RECORD_BOX_BLOCK_ID
,
DdynamicEnum
.
CUSTOMER_RECORD_ALL_BLOCK_ID
));
outInfo
.
set
(
HGYX002
.
FIELD_COMPANY_CODE
,
userVO
.
getUsercode
());
List
<
String
>
roleCompanyCode
=
HGSBTools
.
getRoleCompanyCode
();
CommonMethod
.
initBlock
(
outInfo
,
Arrays
.
asList
(
DdynamicEnum
.
PROJ_RECORD_BLOCK_ID
,
DdynamicEnum
.
WH_RECORD_BOX_BLOCK_ID
,
DdynamicEnum
.
CUSTOMER_RECORD_ALL_BLOCK_ID
),
new
HashMap
<
String
,
Object
>(){{
put
(
HGSB001
.
FIELD_COMPANY_CODES
,
roleCompanyCode
);
}}
);
//outInfo.set(HGYX002.FIELD_COMPANY_CODE, userVO.getUsercode());
}
catch
(
Exception
e
){
LogUtils
.
setDetailMsg
(
inInfo
,
e
,
"初始化失败"
);
}
return
outInfo
;
}
@Override
public
EiInfo
query
(
EiInfo
inInfo
)
{
inInfo
.
setCell
(
EiConstant
.
queryBlock
,
ACConstants
.
ROW_CODE_0
,
HGYX002
.
FIELD_DELETE_FLAG
,
CommonConstant
.
YesNo
.
NO_0
);
//角色公司
List
<
String
>
roleCompanyCode
=
HGSBTools
.
getRoleCompanyCode
();
if
(!
roleCompanyCode
.
isEmpty
()){
inInfo
.
setCell
(
EiConstant
.
queryBlock
,
ACConstants
.
ROW_CODE_0
,
HGSB001
.
FIELD_COMPANY_CODES
,
roleCompanyCode
);
}
return
super
.
query
(
inInfo
,
HGYX002
.
QUERY
,
new
HGYX002
());
}
...
...
src/main/java/com/baosight/hggp/hg/yx/service/ServiceHGYX002A.java
View file @
c98b67dd
...
...
@@ -4,14 +4,19 @@ import com.baosight.hggp.aspect.annotation.OperationLogAnnotation;
import
com.baosight.hggp.common.DdynamicEnum
;
import
com.baosight.hggp.core.constant.CommonConstant
;
import
com.baosight.hggp.core.dao.DaoUtils
;
import
com.baosight.hggp.core.security.UserSessionUtils
;
import
com.baosight.hggp.hg.cw.tools.HGCWTools
;
import
com.baosight.hggp.hg.cw.vo.UserVO
;
import
com.baosight.hggp.hg.kc.domain.HGKC013
;
import
com.baosight.hggp.hg.kc.domain.HGKC013A
;
import
com.baosight.hggp.hg.sb.domain.HGSB001
;
import
com.baosight.hggp.hg.sb.tools.HGSBTools
;
import
com.baosight.hggp.hg.xs.domain.Company
;
import
com.baosight.hggp.hg.yx.domain.HGYX002
;
import
com.baosight.hggp.hg.yx.domain.HGYX002A
;
import
com.baosight.hggp.hg.yx.tools.HGYXTools
;
import
com.baosight.hggp.util.CommonMethod
;
import
com.baosight.hggp.util.EiInfoUtils
;
import
com.baosight.hggp.util.LogUtils
;
import
com.baosight.hggp.util.contants.ACConstants
;
import
com.baosight.iplat4j.core.ei.EiBlock
;
...
...
@@ -21,10 +26,7 @@ import com.baosight.iplat4j.core.exception.PlatException;
import
com.baosight.iplat4j.core.resource.I18nMessages
;
import
com.baosight.iplat4j.core.service.impl.ServiceEPBase
;
import
java.util.Arrays
;
import
java.util.Collections
;
import
java.util.HashMap
;
import
java.util.Map
;
import
java.util.*
;
/**
* @author LiuYang
...
...
@@ -37,6 +39,7 @@ public class ServiceHGYX002A extends ServiceEPBase {
String
id
=
inInfo
.
getCellStr
(
EiConstant
.
queryBlock
,
ACConstants
.
ROW_CODE_0
,
HGYX002A
.
FIELD_PARENT_ID
);
String
type
=
inInfo
.
getCellStr
(
EiConstant
.
queryBlock
,
ACConstants
.
ROW_CODE_0
,
"type"
);
EiInfo
outInfo
=
super
.
initLoad
(
inInfo
,
new
HGYX002A
());
try
{
outInfo
.
getBlock
(
EiConstant
.
resultBlock
).
getRows
().
clear
();
if
(
id
!=
null
)
{
HGYX002
hgyx002
=
HGYXTools
.
Hgyx002
.
getId
(
Long
.
valueOf
(
id
));
...
...
@@ -46,11 +49,11 @@ public class ServiceHGYX002A extends ServiceEPBase {
outInfo
.
getBlock
(
EiConstant
.
queryBlock
).
setRows
(
Collections
.
singletonList
(
hgyx002
));
}
outInfo
.
setCell
(
EiConstant
.
queryBlock
,
ACConstants
.
ROW_CODE_0
,
"type"
,
type
);
UserVO
userVO
=
HGCWTools
.
HgCw002
.
getUserCompany
();
outInfo
.
getBlock
(
EiConstant
.
resultBlock
).
setBlockMeta
(
new
HGYX002A
().
eiMetadata
);
EiInfoUtils
.
addBlock
(
outInfo
,
"roleCompany"
,
UserSessionUtils
.
getRoleCompany
(),
Company
.
class
);
List
<
String
>
roleCompanyCode
=
HGSBTools
.
getRoleCompanyCode
();
CommonMethod
.
initBlock
(
outInfo
,
Arrays
.
asList
(
DdynamicEnum
.
COMPANY_BOX_BLOCK_ID
,
DdynamicEnum
.
WH_RECORD_BOX_BLOCK_ID
,
DdynamicEnum
.
CUSTOMER_RECORD_ALL_BLOCK_ID
));
CommonMethod
.
initBlock
(
outInfo
,
...
...
@@ -60,25 +63,28 @@ public class ServiceHGYX002A extends ServiceEPBase {
DdynamicEnum
.
INVENT_CODE_BOX_BLOCK_ID
,
DdynamicEnum
.
SPEC_BOX_BLOCK_ID
),
new
HashMap
<
String
,
Object
>(){{
put
(
HGKC013
.
FIELD_COMPANY_CODE
,
userVO
.
getUsercode
()
);
put
(
HGSB001
.
FIELD_COMPANY_CODES
,
roleCompanyCode
);
put
(
HGKC013A
.
FIELD_DELETE_FLAG
,
CommonConstant
.
YesNo
.
NO_0
);
}},
false
);
CommonMethod
.
initBlock
(
outInfo
,
Arrays
.
asList
(
DdynamicEnum
.
DELIVERY_CODE_BOX_BLOCK_ID
),
new
HashMap
<
String
,
Object
>(){{
put
(
HGKC013
.
FIELD_COMPANY_CODE
,
userVO
.
getUsercode
()
);
put
(
HGSB001
.
FIELD_COMPANY_CODES
,
roleCompanyCode
);
put
(
HGKC013A
.
FIELD_DELETE_FLAG
,
CommonConstant
.
YesNo
.
NO_0
);
}},
false
);
}
catch
(
Exception
e
){
LogUtils
.
setDetailMsg
(
inInfo
,
e
,
"初始化失败"
);
}
},
false
);
outInfo
.
setCell
(
EiConstant
.
queryBlock
,
ACConstants
.
ROW_CODE_0
,
HGYX002
.
FIELD_COMPANY_CODE
,
userVO
.
getUsercode
());
outInfo
.
setCell
(
EiConstant
.
queryBlock
,
ACConstants
.
ROW_CODE_0
,
HGYX002
.
FIELD_COMPANY_NAME
,
userVO
.
getUsername
());
//outInfo.setCell(EiConstant.queryBlock, ACConstants.ROW_CODE_0,HGYX002.FIELD_CONS_CODE, userVO.getUsercode());
//outInfo.setCell(EiConstant.queryBlock, ACConstants.ROW_CODE_0,HGYX002.FIELD_CONS_NAME, userVO.getUsername());
return
outInfo
;
}
@Override
public
EiInfo
query
(
EiInfo
inInfo
)
{
inInfo
.
setCell
(
EiConstant
.
queryBlock
,
ACConstants
.
ROW_CODE_0
,
HGYX002
.
FIELD_DELETE_FLAG
,
CommonConstant
.
YesNo
.
NO_0
);
//角色公司
List
<
String
>
roleCompanyCode
=
HGSBTools
.
getRoleCompanyCode
();
if
(!
roleCompanyCode
.
isEmpty
()){
inInfo
.
setCell
(
EiConstant
.
queryBlock
,
ACConstants
.
ROW_CODE_0
,
HGSB001
.
FIELD_COMPANY_CODES
,
roleCompanyCode
);
}
return
super
.
query
(
inInfo
,
HGYX002A
.
QUERY
,
new
HGYX002A
());
}
...
...
src/main/java/com/baosight/hggp/hg/yx/service/ServiceHGYX002B.java
View file @
c98b67dd
...
...
@@ -2,14 +2,20 @@ package com.baosight.hggp.hg.yx.service;
import
com.baosight.hggp.common.DdynamicEnum
;
import
com.baosight.hggp.core.constant.CommonConstant
;
import
com.baosight.hggp.core.security.UserSessionUtils
;
import
com.baosight.hggp.hg.cw.tools.HGCWTools
;
import
com.baosight.hggp.hg.cw.vo.UserVO
;
import
com.baosight.hggp.hg.kc.domain.HGKC013
;
import
com.baosight.hggp.hg.kc.domain.HGKC013A
;
import
com.baosight.hggp.hg.sb.domain.HGSB001
;
import
com.baosight.hggp.hg.sb.tools.HGSBTools
;
import
com.baosight.hggp.hg.xs.domain.Company
;
import
com.baosight.hggp.hg.yx.domain.HGYX002
;
import
com.baosight.hggp.hg.yx.domain.HGYX002A
;
import
com.baosight.hggp.hg.yx.tools.HGYXTools
;
import
com.baosight.hggp.util.CommonMethod
;
import
com.baosight.hggp.util.EiInfoUtils
;
import
com.baosight.hggp.util.LogUtils
;
import
com.baosight.hggp.util.StringUtils
;
import
com.baosight.hggp.util.contants.ACConstants
;
import
com.baosight.iplat4j.core.ei.EiConstant
;
...
...
@@ -19,6 +25,7 @@ import com.baosight.iplat4j.core.service.impl.ServiceEPBase;
import
java.util.Arrays
;
import
java.util.Collections
;
import
java.util.HashMap
;
import
java.util.List
;
/**
* @author LiuYang
...
...
@@ -31,6 +38,7 @@ public class ServiceHGYX002B extends ServiceEPBase {
String
id
=
inInfo
.
getCellStr
(
EiConstant
.
queryBlock
,
ACConstants
.
ROW_CODE_0
,
HGYX002A
.
FIELD_PARENT_ID
);
EiInfo
outInfo
=
super
.
initLoad
(
inInfo
,
new
HGYX002A
());
outInfo
.
getBlock
(
EiConstant
.
resultBlock
).
getRows
().
clear
();
try
{
if
(
id
!=
null
)
{
HGYX002
hgyx002
=
HGYXTools
.
Hgyx002
.
getId
(
Long
.
valueOf
(
id
));
inInfo
.
setCell
(
EiConstant
.
queryBlock
,
ACConstants
.
ROW_CODE_0
,
HGYX002
.
FIELD_DELETE_FLAG
,
CommonConstant
.
YesNo
.
NO_0
);
...
...
@@ -38,13 +46,9 @@ public class ServiceHGYX002B extends ServiceEPBase {
outInfo
.
getBlock
(
EiConstant
.
queryBlock
).
setRows
(
Collections
.
singletonList
(
hgyx002
));
}
UserVO
userVO
=
HGCWTools
.
HgCw002
.
getUserCompany
();
outInfo
.
getBlock
(
EiConstant
.
resultBlock
).
setBlockMeta
(
new
HGYX002A
().
eiMetadata
);
CommonMethod
.
initBlock
(
outInfo
,
Arrays
.
asList
(
DdynamicEnum
.
COMPANY_BOX_BLOCK_ID
,
DdynamicEnum
.
WH_RECORD_BOX_BLOCK_ID
,
DdynamicEnum
.
CUSTOMER_RECORD_ALL_BLOCK_ID
));
EiInfoUtils
.
addBlock
(
outInfo
,
"roleCompany"
,
UserSessionUtils
.
getRoleCompany
(),
Company
.
class
);
List
<
String
>
roleCompanyCode
=
HGSBTools
.
getRoleCompanyCode
();
CommonMethod
.
initBlock
(
outInfo
,
Arrays
.
asList
(
DdynamicEnum
.
WH_RECORD_BOX_BLOCK_ID
,
DdynamicEnum
.
CUSTOMER_RECORD_ALL_BLOCK_ID
));
CommonMethod
.
initBlock
(
outInfo
,
Arrays
.
asList
(
DdynamicEnum
.
PROJ_RECORD_BLOCK_ID
,
...
...
@@ -52,13 +56,16 @@ public class ServiceHGYX002B extends ServiceEPBase {
DdynamicEnum
.
INVENT_CODE_BOX_BLOCK_ID
,
DdynamicEnum
.
SPEC_BOX_BLOCK_ID
),
new
HashMap
<
String
,
Object
>(){{
put
(
HGKC013
.
FIELD_COMPANY_CODE
,
userVO
.
getUsercode
()
);
put
(
HGSB001
.
FIELD_COMPANY_CODES
,
roleCompanyCode
);
put
(
HGKC013A
.
FIELD_DELETE_FLAG
,
CommonConstant
.
YesNo
.
NO_0
);
}},
false
);
outInfo
.
setCell
(
EiConstant
.
queryBlock
,
ACConstants
.
ROW_CODE_0
,
HGYX002
.
FIELD_COMPANY_CODE
,
userVO
.
getUsercode
());
outInfo
.
setCell
(
EiConstant
.
queryBlock
,
ACConstants
.
ROW_CODE_0
,
HGYX002
.
FIELD_COMPANY_NAME
,
userVO
.
getUsername
());
outInfo
.
setCell
(
EiConstant
.
queryBlock
,
ACConstants
.
ROW_CODE_0
,
HGYX002
.
FIELD_CONS_CODE
,
userVO
.
getUsercode
());
outInfo
.
setCell
(
EiConstant
.
queryBlock
,
ACConstants
.
ROW_CODE_0
,
HGYX002
.
FIELD_CONS_NAME
,
userVO
.
getUsername
());
//outInfo.setCell(EiConstant.queryBlock, ACConstants.ROW_CODE_0,HGYX002.FIELD_COMPANY_CODE, userVO.getUsercode());
//outInfo.setCell(EiConstant.queryBlock, ACConstants.ROW_CODE_0,HGYX002.FIELD_COMPANY_NAME, userVO.getUsername());
//outInfo.setCell(EiConstant.queryBlock, ACConstants.ROW_CODE_0,HGYX002.FIELD_CONS_CODE, userVO.getUsercode());
//outInfo.setCell(EiConstant.queryBlock, ACConstants.ROW_CODE_0,HGYX002.FIELD_CONS_NAME, userVO.getUsername());
}
catch
(
Exception
e
){
LogUtils
.
setDetailMsg
(
inInfo
,
e
,
"初始化失败"
);
}
return
outInfo
;
}
...
...
src/main/java/com/baosight/hggp/hg/yx/service/ServiceHGYX002C.java
View file @
c98b67dd
...
...
@@ -2,6 +2,8 @@ package com.baosight.hggp.hg.yx.service;
import
com.baosight.hggp.common.DdynamicEnum
;
import
com.baosight.hggp.core.constant.CommonConstant
;
import
com.baosight.hggp.hg.sb.domain.HGSB001
;
import
com.baosight.hggp.hg.sb.tools.HGSBTools
;
import
com.baosight.hggp.hg.yx.domain.HGYX001
;
import
com.baosight.hggp.hg.yx.domain.HGYX001A
;
import
com.baosight.hggp.hg.yx.domain.HGYX001C
;
...
...
@@ -57,6 +59,11 @@ public class ServiceHGYX002C extends ServiceEPBase {
@Override
public
EiInfo
query
(
EiInfo
inInfo
)
{
inInfo
.
setCell
(
EiConstant
.
queryBlock
,
ACConstants
.
ROW_CODE_0
,
HGYX001
.
FIELD_DELETE_FLAG
,
CommonConstant
.
YesNo
.
NO_0
);
//角色公司
List
<
String
>
roleCompanyCode
=
HGSBTools
.
getRoleCompanyCode
();
if
(!
roleCompanyCode
.
isEmpty
()){
inInfo
.
setCell
(
EiConstant
.
queryBlock
,
ACConstants
.
ROW_CODE_0
,
HGSB001
.
FIELD_COMPANY_CODES
,
roleCompanyCode
);
}
return
super
.
query
(
inInfo
,
HGYX002C
.
QUERY
,
new
HGYX001A
());
}
}
src/main/java/com/baosight/hggp/hg/yx/sql/HGYX001.xml
View file @
c98b67dd
...
...
@@ -163,11 +163,13 @@
<isNotEmpty
prepend=
" AND "
property=
"status"
>
STATUS = #status#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"companyCodes"
>
COMPANY_CODE IN
<iterate
close=
")"
open=
"("
conjunction=
","
property=
"companyCodes"
>
#companyCodes[]#
</iterate>
</isNotEmpty>
</sql>
<select
id=
"query"
parameterClass=
"java.util.HashMap"
resultClass=
"HGYX001"
>
SELECT
<include
refid=
"column"
/>
SELECT
<include
refid=
"column"
/>
FROM ${hggpSchema}.HGYX001 WHERE 1=1
<include
refid=
"condition"
/>
<dynamic
prepend=
"ORDER BY"
>
...
...
src/main/java/com/baosight/hggp/hg/yx/sql/HGYX001A.xml
View file @
c98b67dd
...
...
@@ -118,6 +118,9 @@
<isNotEmpty
prepend=
" AND "
property=
"parentId"
>
PARENT_ID = #parentId#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"companyCodes"
>
COMPANY_CODE IN
<iterate
close=
")"
open=
"("
conjunction=
","
property=
"companyCodes"
>
#companyCodes[]#
</iterate>
</isNotEmpty>
</sql>
<select
id=
"query"
parameterClass=
"java.util.HashMap"
resultClass=
"HGYX001A"
>
...
...
src/main/java/com/baosight/hggp/hg/yx/sql/HGYX001C.xml
View file @
c98b67dd
...
...
@@ -85,6 +85,9 @@
<isNotEmpty
prepend=
" AND "
property=
"factoryName"
>
FACTORY_NAME = #factoryName#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"companyCodes"
>
COMPANY_CODE IN
<iterate
close=
")"
open=
"("
conjunction=
","
property=
"companyCodes"
>
#companyCodes[]#
</iterate>
</isNotEmpty>
</sql>
<sql
id=
"idCondition"
>
...
...
src/main/java/com/baosight/hggp/hg/yx/sql/HGYX002.xml
View file @
c98b67dd
...
...
@@ -149,6 +149,9 @@
<isNotEmpty
prepend=
" AND "
property=
"status"
>
STATUS = #status#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"companyCodes"
>
COMPANY_CODE IN
<iterate
close=
")"
open=
"("
conjunction=
","
property=
"companyCodes"
>
#companyCodes[]#
</iterate>
</isNotEmpty>
</sql>
<select
id=
"query"
parameterClass=
"HashMap"
resultClass=
"HGYX002"
>
...
...
src/main/java/com/baosight/hggp/hg/yx/sql/HGYX002A.xml
View file @
c98b67dd
...
...
@@ -136,6 +136,9 @@
<isNotEmpty
prepend=
" AND "
property=
"inventRecordIds"
>
INVENT_RECORD_ID NOT IN
<iterate
close=
")"
open=
"("
conjunction=
","
property=
"inventRecordIds"
>
#inventRecordIds[]#
</iterate>
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"companyCodes"
>
COMPANY_CODE IN
<iterate
close=
")"
open=
"("
conjunction=
","
property=
"companyCodes"
>
#companyCodes[]#
</iterate>
</isNotEmpty>
</sql>
<select
id=
"query"
parameterClass=
"HashMap"
resultClass=
"HGYX002A"
>
...
...
src/main/java/com/baosight/hggp/hg/yx/sql/HGYX002C.xml
View file @
c98b67dd
...
...
@@ -118,6 +118,9 @@
<isNotEmpty
prepend=
" AND "
property=
"ids"
>
A.ID IN
<iterate
close=
")"
open=
"("
conjunction=
","
property=
"ids"
>
#ids[]#
</iterate>
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"companyCodes"
>
A.COMPANY_CODE IN
<iterate
close=
")"
open=
"("
conjunction=
","
property=
"companyCodes"
>
#companyCodes[]#
</iterate>
</isNotEmpty>
</sql>
<select
id=
"query"
parameterClass=
"java.util.HashMap"
resultClass=
"HGYX002C"
>
...
...
src/main/java/com/baosight/hggp/util/ExcelUtils.java
View file @
c98b67dd
...
...
@@ -233,6 +233,7 @@ public class ExcelUtils {
// 去除空格
hgsj003
.
setSpec
(
StringUtils
.
trimToEmpty
(
hgsj003
.
getSpec
()));
hgsj003
.
setProcessClass
(
Integer
.
valueOf
(
processClass
));
hgsj003
.
setStatus
(
1
);
//校验
checkAddData
(
hgsj003
);
DaoUtils
.
insert
(
HGSJ003
.
INSERT
,
hgsj003
);
...
...
src/main/webapp/HG/KC/HGKC004.jsp
View file @
c98b67dd
...
...
@@ -17,7 +17,7 @@
<div class="row">
<EF:EFSelect blockId="inqu_status" row="0" ename="companyCode" cname="公司名称" colWidth="3" filter="contains">
<EF:EFOption label="全部" value=""/>
<EF:EFOptions blockId="
companyBox_block_id" textField="textField" valueField="valueField
"/>
<EF:EFOptions blockId="
roleCompany" textField="companyName" valueField="companyCode
"/>
</EF:EFSelect>
<EF:EFDatePicker blockId="inqu_status" row="0" ename="receiptDate" cname="单据日期" colWidth="3"
format="yyyy-MM-dd"/>
...
...
@@ -35,7 +35,7 @@
<EF:EFColumn ename="operator" cname="操作" locked="true" enable="false" width="210" 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
"/>
<EF:EFOptions blockId="
roleCompany" textField="companyName" valueField="companyCode
"/>
</EF:EFComboColumn>
<EF:EFColumn ename="receiptDate" cname="单据日期" enable="true" width="90" align="center"
editType="date" dateFormat="yyyy-MM-dd" parseFormats="['yyyyMMdd']" required="true"/>
...
...
src/main/webapp/HG/KC/HGKC013.js
View file @
c98b67dd
$
(
function
()
{
$
(
".row"
).
children
().
attr
(
"class"
,
"col-md-3"
);
var
companyCode
=
__eiInfo
.
get
(
"companyCode"
);
var
companyCodeBox
=
__eiInfo
.
getBlock
(
"
companyBox_block_id
"
).
getMappedRows
();
var
companyCode
=
''
;
//
__eiInfo.get("companyCode");
var
companyCodeBox
=
__eiInfo
.
getBlock
(
"
roleCompany
"
).
getMappedRows
();
var
whCodeBox
=
__eiInfo
.
getBlock
(
"wh_record_box_block_id"
).
getMappedRows
();
IPLATUI
.
EFGrid
=
{
...
...
@@ -44,12 +44,12 @@ $(function () {
template
:
function
(
item
)
{
let
calloutCompanyCode
=
item
.
calloutCompanyCode
;
for
(
let
i
=
0
;
i
<
companyCodeBox
.
length
;
i
++
)
{
if
(
calloutCompanyCode
===
companyCodeBox
[
i
][
'
valueField
'
])
{
item
[
'calloutCompanyName'
]
=
companyCodeBox
[
i
][
'
textField
'
];
if
(
calloutCompanyCode
===
companyCodeBox
[
i
][
'
companyCode
'
])
{
item
[
'calloutCompanyName'
]
=
companyCodeBox
[
i
][
'
companyName
'
];
if
(
!
isBlank
(
item
[
'allotType'
])){
item
[
'callinCompanyCode'
]
=
companyCodeBox
[
i
][
'
valueField
'
];
item
[
'callinCompanyCode'
]
=
companyCodeBox
[
i
][
'
companyCode
'
];
}
return
companyCodeBox
[
i
][
'
textField
'
];
return
companyCodeBox
[
i
][
'
companyName
'
];
}
}
return
calloutCompanyCode
;
...
...
@@ -92,9 +92,9 @@ $(function () {
template
:
function
(
item
)
{
let
callinCompanyCode
=
item
.
callinCompanyCode
;
for
(
let
i
=
0
;
i
<
companyCodeBox
.
length
;
i
++
)
{
if
(
callinCompanyCode
===
companyCodeBox
[
i
][
'
valueField
'
])
{
item
[
'callinCompanyName'
]
=
companyCodeBox
[
i
][
'
textField
'
];
return
companyCodeBox
[
i
][
'
textField
'
];
if
(
callinCompanyCode
===
companyCodeBox
[
i
][
'
companyCode
'
])
{
item
[
'callinCompanyName'
]
=
companyCodeBox
[
i
][
'
companyName
'
];
return
companyCodeBox
[
i
][
'
companyName
'
];
}
}
return
callinCompanyCode
;
...
...
@@ -185,7 +185,6 @@ $(function () {
//$("#PRINT").on("click", exportPrint);
});
/**
* 页面加载时执行
*/
...
...
src/main/webapp/HG/KC/HGKC013.jsp
View file @
c98b67dd
...
...
@@ -38,7 +38,7 @@
<EF:EFColumn ename="allotNo" cname="调拨单号" enable="false" width="120" align="center"/>
<EF:EFComboColumn ename="calloutCompanyCode" enable="true" cname="调出公司名称" width="110" align="center"
filter="contains" readonly="true" required="true">
<EF:EFOptions blockId="
companyBox_block_id" valueField="valueField" textField="textField
"/>
<EF:EFOptions blockId="
roleCompany" textField="companyName" valueField="companyCode
"/>
</EF:EFComboColumn>
<EF:EFComboColumn ename="calloutWhCode" cname="调出仓库名称" enable="true" width="120" align="center" required="true"
blockName="wh_record_box_block_id" textField="textField" valueField="valueField"
...
...
@@ -46,7 +46,7 @@
</EF:EFComboColumn>
<EF:EFComboColumn ename="callinCompanyCode" enable="true" cname="调入公司名称" width="110" align="center"
filter="contains" readonly="false" required="true">
<EF:EFOptions blockId="
companyBox_block_id" valueField="valueField" textField="textField
"/>
<EF:EFOptions blockId="
roleCompany" textField="companyName" valueField="companyCode
"/>
</EF:EFComboColumn>
<EF:EFComboColumn ename="callinWhCode" cname="调入仓库名称" enable="true" width="120" align="center" required="true"
blockName="wh_record_box_block_id" textField="textField" valueField="valueField"
...
...
src/main/webapp/HG/YX/HGYX001.js
View file @
c98b67dd
$
(
function
()
{
$
(
".row"
).
children
().
attr
(
"class"
,
"col-md-3"
);
var
companyCode
=
__eiInfo
.
get
(
"companyCode"
);
var
companyCodeBox
=
__eiInfo
.
getBlock
(
"
companyBox_block_id
"
).
getMappedRows
();
var
companyCode
=
''
;
//
__eiInfo.get("companyCode");
var
companyCodeBox
=
__eiInfo
.
getBlock
(
"
roleCompany
"
).
getMappedRows
();
var
whCodeBox
=
__eiInfo
.
getBlock
(
"wh_record_box_block_id"
).
getMappedRows
();
IPLATUI
.
EFGrid
=
{
...
...
@@ -42,9 +42,9 @@ $(function () {
template
:
function
(
item
)
{
let
calloutCompanyCode
=
item
[
"consCode"
];
for
(
let
i
=
0
;
i
<
companyCodeBox
.
length
;
i
++
)
{
if
(
calloutCompanyCode
===
companyCodeBox
[
i
][
'
valueField
'
])
{
item
[
'consName'
]
=
companyCodeBox
[
i
][
'
textField
'
];
return
companyCodeBox
[
i
][
'
textField
'
];
if
(
calloutCompanyCode
===
companyCodeBox
[
i
][
'
companyCode
'
])
{
item
[
'consName'
]
=
companyCodeBox
[
i
][
'
companyName
'
];
return
companyCodeBox
[
i
][
'
companyName
'
];
}
}
return
calloutCompanyCode
;
...
...
src/main/webapp/HG/YX/HGYX001.jsp
View file @
c98b67dd
...
...
@@ -17,7 +17,7 @@
<div class="row">
<EF:EFSelect blockId="inqu_status" row="0" ename="companyCode" cname="公司名称" colWidth="3" filter="contains">
<EF:EFOption label="全部" value=""/>
<EF:EFOptions blockId="
companyBox_block_id" textField="textField" valueField="valueField
"/>
<EF:EFOptions blockId="
roleCompany" textField="companyName" valueField="companyCode
"/>
</EF:EFSelect>
<EF:EFInput blockId="inqu_status" row="0" ename="projName" cname="项目名称" placeholder="模糊查询" colWidth="3"/>
<EF:EFInput blockId="inqu_status" row="0" ename="deliveryCode" cname="发货单号" placeholder="模糊查询" colWidth="3"/>
...
...
@@ -47,7 +47,7 @@
<EF:EFColumn ename="operator" cname="操作" locked="true" enable="false" width="140" 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
"/>
<EF:EFOptions blockId="
roleCompany" textField="companyName" valueField="companyCode
"/>
</EF:EFComboColumn>
<EF:EFComboColumn ename="projCode" enable="true" cname="项目名称" width="110" align="center"
filter="contains" readonly="true" required="true">
...
...
src/main/webapp/HG/YX/HGYX001A.js
View file @
c98b67dd
$
(
function
()
{
/*$(".row").children().attr("class", "col-md-3");*/
var
companyBox
=
__eiInfo
.
getBlock
(
"
companyBox_block_id
"
).
getMappedRows
();
var
companyBox
=
__eiInfo
.
getBlock
(
"
roleCompany
"
).
getMappedRows
();
var
projRecordBox
=
__eiInfo
.
getBlock
(
"proj_record_block_id"
).
getMappedRows
();
var
inventTypeBox
=
__eiInfo
.
getBlock
(
"invent_type_box_block_id"
).
getMappedRows
();
var
inventCodedBox
=
__eiInfo
.
getBlock
(
"invent_code_box_block_id"
).
getMappedRows
();
...
...
@@ -134,16 +134,19 @@ $(function() {
})
let
whRecord
=
_
.
filter
(
whRecordBox
,
function
(
item
)
{
return
item
[
"param1Field"
]
===
proj
[
0
][
"param1Field"
];
})
IPLAT
.
EFSelect
.
setDataSource
(
$
(
"#inqu_status-0-consWhCode"
),
whRecord
);
IPLAT
.
EFSelect
.
value
(
$
(
"#inqu_status-0-consWhCode"
),
''
);
});
let
consWhCode
=
$
(
"#inqu_status-0-consWhCode"
);
IPLAT
.
EFSelect
.
setDataSource
(
consWhCode
,
whRecord
);
IPLAT
.
EFSelect
.
value
(
consWhCode
,
''
);
let
company
=
_
.
filter
(
companyBox
,
function
(
item
)
{
return
item
[
"valueField"
]
===
proj
[
0
][
"param1Field"
];
})
IPLAT
.
EFSelect
.
setDataSource
(
$
(
"#inqu_status-0-consCode"
),
company
);
IPLAT
.
EFSelect
.
value
(
$
(
"#inqu_status-0-consCode"
),
proj
[
0
][
"param1Field"
]);
return
item
[
"companyCode"
]
===
proj
[
0
][
"param1Field"
];
});
let
consCode
=
$
(
"#inqu_status-0-consCode"
);
//IPLAT.EFSelect.setDataSource(consCode,company);
IPLAT
.
EFSelect
.
value
(
consCode
,
proj
[
0
][
"param1Field"
]);
})
$
(
"#inqu_status-0-consCode"
).
change
(
function
()
{
if
(
$
(
"#inqu_status-0-type"
).
val
()
==
"update"
){
NotificationUtil
(
"无法修改发货方!"
,
"error"
);
...
...
@@ -230,6 +233,7 @@ $(function() {
});
}
});
/**
* 保存并审核提交
*/
...
...
src/main/webapp/HG/YX/HGYX001A.jsp
View file @
c98b67dd
...
...
@@ -32,7 +32,7 @@
<div class="row">
<EF:EFSelect blockId="inqu_status" row="0" ename="consCode" cname="发货方" required="true" disabled="true" colWidth="3" filter="contains">
<EF:EFOption label="请选择" value=""/>
<EF:EFOptions blockId="
companyBox_block_id" textField="textField" valueField="valueField
"/>
<EF:EFOptions blockId="
roleCompany" textField="companyName" valueField="companyCode
"/>
</EF:EFSelect>
<EF:EFInput blockId="inqu_status" row="0" ename="consName" type="hidden" cname="发货方名称" colWidth="3"/>
<EF:EFSelect blockId="inqu_status" row="0" ename="consWhCode" cname="发货仓库" required="true" colWidth="3" filter="contains">
...
...
src/main/webapp/HG/YX/HGYX002.js
View file @
c98b67dd
$
(
function
()
{
$
(
".row"
).
children
().
attr
(
"class"
,
"col-md-3"
);
var
companyCode
=
__eiInfo
.
get
(
"companyCode"
);
var
companyCodeBox
=
__eiInfo
.
getBlock
(
"
companyBox_block_id
"
).
getMappedRows
();
//
var companyCode = __eiInfo.get("companyCode");
var
companyCodeBox
=
__eiInfo
.
getBlock
(
"
roleCompany
"
).
getMappedRows
();
var
whCodeBox
=
__eiInfo
.
getBlock
(
"wh_record_box_block_id"
).
getMappedRows
();
IPLATUI
.
EFGrid
=
{
...
...
src/main/webapp/HG/YX/HGYX002.jsp
View file @
c98b67dd
...
...
@@ -40,7 +40,7 @@
<EF:EFColumn ename="deliveryCode" cname="发货单号" enable="false" width="120" align="center" required="true"/>
<EF:EFComboColumn ename="consCode" enable="true" cname="发货方" width="110" align="center"
filter="contains" readonly="true" required="true">
<EF:EFOptions blockId="
companyBox_block_id" valueField="valueField" textField="textField
"/>
<EF:EFOptions blockId="
roleCompany" valueField="companyCode" textField="companyName
"/>
</EF:EFComboColumn>
<EF:EFComboColumn ename="receCode" enable="true" cname="收货方" width="110" align="center"
filter="contains" readonly="true" required="true">
...
...
src/main/webapp/HG/YX/HGYX002A.js
View file @
c98b67dd
$
(
function
()
{
/*$(".row").children().attr("class", "col-md-3");*/
var
companyBox
=
__eiInfo
.
getBlock
(
"
companyBox_block_id
"
).
getMappedRows
();
var
companyBox
=
__eiInfo
.
getBlock
(
"
roleCompany
"
).
getMappedRows
();
var
projRecordBox
=
__eiInfo
.
getBlock
(
"proj_record_block_id"
).
getMappedRows
();
var
inventTypeBox
=
__eiInfo
.
getBlock
(
"invent_type_box_block_id"
).
getMappedRows
();
var
inventCodedBox
=
__eiInfo
.
getBlock
(
"invent_code_box_block_id"
).
getMappedRows
();
...
...
@@ -143,7 +143,7 @@ $(function() {
IPLAT
.
EFSelect
.
setDataSource
(
$
(
"#inqu_status-0-consWhCode"
),
whRecord
);
let
company
=
_
.
filter
(
companyBox
,
function
(
item
)
{
return
item
[
"
valueField
"
]
===
proj
[
0
][
"param1Field"
];
return
item
[
"
companyCode
"
]
===
proj
[
0
][
"param1Field"
];
})
IPLAT
.
EFSelect
.
setDataSource
(
$
(
"#inqu_status-0-consCode"
),
company
);
})
...
...
src/main/webapp/HG/YX/HGYX002A.jsp
View file @
c98b67dd
...
...
@@ -36,7 +36,7 @@
<EF:EFInput blockId="inqu_status" row="0" ename="projName" cname="项目名称" type="hidden" colWidth="3"/>
<EF:EFSelect blockId="inqu_status" row="0" ename="consCode" cname="发货方" required="true" disabled="true" colWidth="3" filter="contains">
<EF:EFOption label="请选择" value=""/>
<EF:EFOptions blockId="
companyBox_block_id" textField="textField" valueField="valueField
"/>
<EF:EFOptions blockId="
roleCompany" textField="companyName" valueField="companyCode
"/>
</EF:EFSelect>
<EF:EFInput blockId="inqu_status" row="0" ename="consName" type="hidden" cname="发货方编码" colWidth="3"/>
<EF:EFInput blockId="inqu_status" row="0" ename="consWhCode" type="hidden" cname="发货仓库名称" colWidth="3"/>
...
...
src/main/webapp/HG/YX/HGYX002B.jsp
View file @
c98b67dd
...
...
@@ -28,7 +28,7 @@
<EF:EFInput blockId="inqu_status" row="0" ename="projName" cname="项目名称" type="hidden" colWidth="3"/>
<EF:EFSelect blockId="inqu_status" row="0" ename="consCode" cname="发货方" disabled="true" required="true" colWidth="3" filter="contains">
<EF:EFOption label="请选择" value=""/>
<EF:EFOptions blockId="
companyBox_block_id" textField="textField" valueField="valueField
"/>
<EF:EFOptions blockId="
roleCompany" textField="companyName" valueField="companyCode
"/>
</EF:EFSelect>
<EF:EFInput blockId="inqu_status" row="0" ename="consCode" type="hidden" cname="发货方编码" colWidth="3"/>
<EF:EFInput blockId="inqu_status" row="0" ename="consWhName" type="hidden" cname="发货仓库名称" colWidth="3"/>
...
...
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