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
18c08e74
Commit
18c08e74
authored
Sep 03, 2024
by
宋祥
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'dev' of
http://129.211.46.84:8800/platform/hg-smart
parents
21ad4a95
9b5b24db
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
20 changed files
with
184 additions
and
119 deletions
+184
-119
DcUser.java
...a/com/baosight/hggp/core/extapp/decheng/model/DcUser.java
+5
-0
ServiceHGCG002.java
.../java/com/baosight/hggp/hg/cg/service/ServiceHGCG002.java
+7
-8
ServiceHGCG003A.java
...java/com/baosight/hggp/hg/cg/service/ServiceHGCG003A.java
+8
-4
HGCG002A.xml
src/main/java/com/baosight/hggp/hg/cg/sql/HGCG002A.xml
+0
-0
ServiceHGCW010.java
.../java/com/baosight/hggp/hg/cw/service/ServiceHGCW010.java
+1
-1
HGCWTools.java
src/main/java/com/baosight/hggp/hg/cw/tools/HGCWTools.java
+1
-1
ServiceHGKC001.java
.../java/com/baosight/hggp/hg/kc/service/ServiceHGKC001.java
+10
-0
ServiceHGPZ009.java
.../java/com/baosight/hggp/hg/pz/service/ServiceHGPZ009.java
+1
-1
ServiceHGXSUser.java
...java/com/baosight/hggp/hg/xs/service/ServiceHGXSUser.java
+33
-26
HGXSUser.xml
src/main/java/com/baosight/hggp/hg/xs/sql/HGXSUser.xml
+1
-0
HGXSTools.java
src/main/java/com/baosight/hggp/hg/xs/tools/HGXSTools.java
+3
-1
HGXSUtils.java
src/main/java/com/baosight/hggp/hg/xs/utils/HGXSUtils.java
+10
-0
ServiceXS0102.java
...java/com/baosight/xservices/xs/service/ServiceXS0102.java
+2
-2
HGCG002.js
src/main/webapp/HG/CG/HGCG002.js
+56
-55
HGCG002.jsp
src/main/webapp/HG/CG/HGCG002.jsp
+3
-3
HGKC001.js
src/main/webapp/HG/KC/HGKC001.js
+24
-2
HGWD001.js
src/main/webapp/HG/WD/HGWD001.js
+11
-7
HGWD001.jsp
src/main/webapp/HG/WD/HGWD001.jsp
+4
-4
HGWD001E.js
src/main/webapp/HG/WD/HGWD001E.js
+2
-2
HGWD001F.js
src/main/webapp/HG/WD/HGWD001F.js
+2
-2
No files found.
src/main/java/com/baosight/hggp/core/extapp/decheng/model/DcUser.java
View file @
18c08e74
...
...
@@ -53,4 +53,9 @@ public class DcUser {
@AliasNameAnon
(
name
=
"手机"
)
private
String
Mobile
;
/**
* 员工编号
*/
@AliasNameAnon
(
name
=
"员工编号"
)
private
String
Ygid
;
}
src/main/java/com/baosight/hggp/hg/cg/service/ServiceHGCG002.java
View file @
18c08e74
...
...
@@ -216,8 +216,6 @@ public class ServiceHGCG002 extends ServiceBase {
HGCGTools
.
HgCg001A
.
updateStatus
(
hgcg002B
.
getPlanDetailId
(),
HGConstant
.
CgPlanStatus
.
S_2
);
}
}
}
/**
...
...
@@ -244,7 +242,7 @@ public class ServiceHGCG002 extends ServiceBase {
}
return
inInfo
;
}
/**
* 数据校验
*
...
...
@@ -256,16 +254,17 @@ public class ServiceHGCG002 extends ServiceBase {
String
contractNo
=
fCg002
.
getContractNo
();
HGCG002
dbCg002
=
dbCg002AMap
.
get
(
contractNo
);
AssertUtils
.
isNull
(
dbCg002
,
String
.
format
(
"合同[%s]不存在"
,
contractNo
));
AssertUtils
.
is
True
(
StringUtils
.
isBlank
(
fCg002
.
getSupName
()
),
String
.
format
(
"合同[%s]供应商为空"
,
contractNo
));
AssertUtils
.
is
True
(
StringUtils
.
isBlank
(
fCg002
.
getPurUserName
()
),
String
.
format
(
"合同[%s]采购员为空"
,
contractNo
));
AssertUtils
.
is
Empty
(
dbCg002
.
getSupName
(
),
String
.
format
(
"合同[%s]供应商为空"
,
contractNo
));
AssertUtils
.
is
Empty
(
dbCg002
.
getPurUserName
(
),
String
.
format
(
"合同[%s]采购员为空"
,
contractNo
));
AssertUtils
.
isNotEquals
(
HGConstant
.
CgContractStatus
.
S_0
,
dbCg002
.
getStatus
(),
String
.
format
(
"合同[%s]状态不是\"待审核\",不允许操作"
,
contractNo
));
AssertUtils
.
isTrue
(
fCg002
.
getAmount
().
compareTo
(
BigDecimal
.
ZERO
)
<=
0
,
String
.
format
(
"合同[%s]不含税金额小于等于0,不允许操作"
,
contractNo
));
AssertUtils
.
isTrue
(
fCg002
.
getTaxIncludeAmount
().
compareTo
(
BigDecimal
.
ZERO
)
<=
0
,
String
.
format
(
"合同[%s]含税金额小于等于0,不允许操作"
,
contractNo
));
AssertUtils
.
isTrue
(
dbCg002
.
getAmount
().
compareTo
(
BigDecimal
.
ZERO
)
<=
0
,
String
.
format
(
"合同[%s]不含税金额小于等于0,不允许操作"
,
contractNo
));
AssertUtils
.
isTrue
(
dbCg002
.
getTaxIncludeAmount
().
compareTo
(
BigDecimal
.
ZERO
)
<=
0
,
String
.
format
(
"合同[%s]含税金额小于等于0,不允许操作"
,
contractNo
));
}
}
/**
* 提交数据
*
...
...
src/main/java/com/baosight/hggp/hg/cg/service/ServiceHGCG003A.java
View file @
18c08e74
...
...
@@ -143,22 +143,26 @@ public class ServiceHGCG003A extends ServiceBase {
Long
id
=
fCg002B
.
getId
();
HGCG002B
dbCg002b
=
dbCg002BMap
.
get
(
id
);
// 总重
BigDecimal
bcReceiveQty
=
fCg002B
.
getBcReceiveQty
();
BigDecimal
bcReceiveWeight
=
fCg002B
.
getBcReceiveWeight
();
if
(
bcReceiveWeight
==
null
||
bcReceiveWeight
.
compareTo
(
BigDecimal
.
ZERO
)
==
0
)
{
fCg002B
.
setReceiveWeight
(
fCg002B
.
getBcReceiveQty
().
multiply
(
dbCg002b
.
getPurUnitWeight
()));
fCg002B
.
setReceiveWeight
(
bcReceiveQty
.
multiply
(
dbCg002b
.
getPurUnitWeight
()));
fCg002B
.
setPurUnitWeight
(
dbCg002b
.
getPurUnitWeight
());
}
else
{
fCg002B
.
setReceiveWeight
(
bcReceiveWeight
);
fCg002B
.
setPurUnitWeight
(
bcReceiveWeight
.
divide
(
bcReceiveQty
,
3
,
RoundingMode
.
HALF_UP
));
}
// 含税总金额
BigDecimal
amount
;
if
(
HgCgConst
.
CalculationMethod
.
S1
.
equals
(
fCg002B
.
getCalculationMethod
()))
{
amount
=
fCg002B
.
getReceiveWeight
()
.
multiply
(
dbCg002b
.
getPrice
());
amount
=
bcReceiveWeight
.
multiply
(
dbCg002b
.
getPrice
());
}
else
{
amount
=
fCg002B
.
getBcReceiveQty
()
.
multiply
(
dbCg002b
.
getPrice
());
amount
=
bcReceiveQty
.
multiply
(
dbCg002b
.
getPrice
());
}
// 如果税率不为空,总金额减去税额
if
(
dbCg002b
.
getTaxRate
()
!=
null
)
{
amount
=
amount
.
subtract
(
amount
.
multiply
(
dbCg002b
.
getTaxRate
()).
divide
(
new
BigDecimal
(
"100"
)));
BigDecimal
taxRate
=
dbCg002b
.
getTaxRate
().
multiply
(
new
BigDecimal
(
"0.01"
)).
add
(
BigDecimal
.
ONE
);
amount
=
amount
.
divide
(
taxRate
,
2
,
RoundingMode
.
HALF_UP
);
}
fCg002B
.
setAmount
(
amount
);
}
...
...
src/main/java/com/baosight/hggp/hg/cg/sql/HGCG002A.xml
View file @
18c08e74
This diff is collapsed.
Click to expand it.
src/main/java/com/baosight/hggp/hg/cw/service/ServiceHGCW010.java
View file @
18c08e74
...
...
@@ -268,7 +268,7 @@ public class ServiceHGCW010 extends ServiceBase {
}
catch
(
Exception
e
)
{
LogUtils
.
setMsg
(
inInfo
,
e
,
"生成
收款单
失败"
);
LogUtils
.
setMsg
(
inInfo
,
e
,
"生成
销售开票
失败"
);
}
return
inInfo
;
}
...
...
src/main/java/com/baosight/hggp/hg/cw/tools/HGCWTools.java
View file @
18c08e74
...
...
@@ -786,7 +786,7 @@ public class HGCWTools {
List
<
HGCW011
>
results
=
DaoBase
.
getInstance
().
query
(
HGCW011
.
QUERY
,
new
HashMap
<
String
,
Object
>(){
{
put
(
"settlementNumbers"
,
settlementNumber
);}
});
AssertUtils
.
isEmpty
(
results
,
"找不到对应的销售开票记录!"
);
//
AssertUtils.isEmpty(results, "找不到对应的销售开票记录!");
BigDecimal
totalAmount
=
new
BigDecimal
(
"0"
);
for
(
HGCW011
hgcw011:
results
)
{
totalAmount
=
totalAmount
.
add
(
hgcw011
.
getTotalContractPriceIncluding
());
...
...
src/main/java/com/baosight/hggp/hg/kc/service/ServiceHGKC001.java
View file @
18c08e74
...
...
@@ -12,6 +12,8 @@ import com.baosight.hggp.hg.kc.domain.HGKC001;
import
com.baosight.hggp.hg.kc.domain.HGKC003
;
import
com.baosight.hggp.hg.kc.tools.HGKCTools
;
import
com.baosight.hggp.hg.kc.utils.HGKCUtils
;
import
com.baosight.hggp.hg.pz.domain.HGPZ007
;
import
com.baosight.hggp.hg.pz.tools.HGPZTools
;
import
com.baosight.hggp.hg.xs.domain.Company
;
import
com.baosight.hggp.util.*
;
import
com.baosight.iplat4j.core.ei.EiBlock
;
...
...
@@ -24,6 +26,8 @@ import com.baosight.iplat4j.core.service.impl.ServiceBase;
import
java.util.Arrays
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.Objects
;
import
java.util.stream.Collectors
;
/**
* @author:songx
...
...
@@ -123,7 +127,13 @@ public class ServiceHGKC001 extends ServiceBase {
* @param dbCg004Map
*/
private
void
saveData
(
List
<
HGKC001
>
fCg004s
,
Map
<
String
,
HGKC001
>
dbCg004Map
)
{
List
<
String
>
whCodeList
=
fCg004s
.
stream
().
map
(
HGKC001:
:
getWhCode
).
collect
(
Collectors
.
toList
());
Map
<
String
,
HGPZ007
>
whMap
=
HGPZTools
.
HgPz007
.
map
(
whCodeList
);
for
(
HGKC001
fCg004
:
fCg004s
)
{
HGPZ007
wh
=
whMap
.
get
(
fCg004
.
getWhCode
());
if
(
Objects
.
nonNull
(
wh
)){
fCg004
.
setWhName
(
wh
.
getWhName
());
}
DaoUtils
.
update
(
HGKC001
.
UPDATE_WH_CODE
,
fCg004
);
}
}
...
...
src/main/java/com/baosight/hggp/hg/pz/service/ServiceHGPZ009.java
View file @
18c08e74
...
...
@@ -139,7 +139,7 @@ public class ServiceHGPZ009 extends ServiceBase {
// 默认新增企业管理员账号
String
userId
=
fPz009
.
getLoginPrefix
()
+
"0000"
;
HGXSTools
.
XsUser
.
addUser
(
fPz009
.
getAccountCode
(),
userId
,
fPz009
.
getAccountName
(),
null
,
null
,
null
);
null
,
null
,
null
,
"1"
);
// 关联企业管理员角色
this
.
insertGroupMember
(
fPz009
,
userId
);
// 新增组织机构顶级
...
...
src/main/java/com/baosight/hggp/hg/xs/service/ServiceHGXSUser.java
View file @
18c08e74
...
...
@@ -21,11 +21,11 @@ import com.baosight.hggp.util.EiInfoUtils;
import
com.baosight.hggp.util.LogUtils
;
import
com.baosight.hggp.util.MapUtils
;
import
com.baosight.hggp.util.ObjectUtils
;
import
com.baosight.hggp.util.StringUtils
;
import
com.baosight.iplat4j.core.ei.EiConstant
;
import
com.baosight.iplat4j.core.ei.EiInfo
;
import
com.baosight.iplat4j.core.service.impl.ServiceBase
;
import
org.apache.commons.collections.CollectionUtils
;
import
org.apache.commons.lang.StringUtils
;
import
java.io.IOException
;
import
java.util.ArrayList
;
...
...
@@ -190,7 +190,9 @@ public class ServiceHGXSUser extends ServiceBase {
Map
queryMap
=
EiInfoUtils
.
getFirstRow
(
inInfo
);
HGPZ009
dbPz009
=
HGPZTools
.
HgPz009
.
getByCode
(
MapUtils
.
getString
(
queryMap
,
HGPZ009
.
FIELD_ACCOUNT_CODE
));
Integer
ord
=
MapUtils
.
getInteger
(
queryMap
,
"ord"
);
syncDcUserSingle
(
dbPz009
,
ord
);
DcUserList
dcUserList
=
new
DcUserList
();
dcUserList
.
setOrd
(
ord
);
syncDcUserSingle
(
dbPz009
,
dcUserList
);
inInfo
.
setStatus
(
EiConstant
.
STATUS_SUCCESS
);
inInfo
.
setMsg
(
"同步德诚用户信息成功"
);
}
catch
(
Exception
e
)
{
...
...
@@ -259,7 +261,7 @@ public class ServiceHGXSUser extends ServiceBase {
HGPZ009
dbPz009
=
HGPZTools
.
HgPz009
.
getByCode
(
accountCode
);
for
(
DcUserList
dcUserList
:
dcUserLists
)
{
try
{
syncDcUserSingle
(
dbPz009
,
dcUserList
.
getOrd
()
);
syncDcUserSingle
(
dbPz009
,
dcUserList
);
}
catch
(
Exception
e
)
{
log
.
error
(
"同步德诚用户失败:{}"
,
e
.
getMessage
(),
e
);
}
...
...
@@ -270,40 +272,42 @@ public class ServiceHGXSUser extends ServiceBase {
* 同步单个用户
*
* @param dbPz009
* @param
ord
* @param
dcUserList
* @throws IOException
*/
private
void
syncDcUserSingle
(
HGPZ009
dbPz009
,
Integer
ord
)
throws
Exception
{
private
void
syncDcUserSingle
(
HGPZ009
dbPz009
,
DcUserList
dcUserList
)
throws
Exception
{
// 获取用户详情
DcUser
zbUser
=
DcOpenApi
.
userDetail
(
ord
);
if
(
zbUser
==
null
)
{
DcUser
dcUser
=
DcOpenApi
.
userDetail
(
dcUserList
.
getOrd
()
);
if
(
dcUser
==
null
||
StringUtils
.
isBlank
(
dcUser
.
getYgid
())
)
{
return
;
}
String
userId
=
dbPz009
.
getLoginPrefix
()
+
ord
;
// 判断用户是否存在
User
dbUser
=
HGXSTools
.
XsUser
.
getByLogin
(
userId
);
User
dbUser
=
HGXSTools
.
XsUser
.
getByLogin
(
dcUser
.
getYgid
()
);
if
(
dbUser
==
null
)
{
this
.
syncDcSingleUserAdd
(
zbUser
,
dbPz009
,
userId
);
this
.
syncDcSingleUserAdd
(
dcUserList
,
dcUser
,
dbPz009
);
}
else
{
this
.
syncDcSingleUserModify
(
zbUser
,
userId
);
this
.
syncDcSingleUserModify
(
dcUserList
,
dcUser
);
}
}
/**
* 新增用户
*
* @param zbUser
* @param dcUserList
* @param dcUser
* @param dbPz009
* @param userId
* @throws Exception
*/
private
void
syncDcSingleUserAdd
(
DcUser
zbUser
,
HGPZ009
dbPz009
,
String
userId
)
throws
Exception
{
private
void
syncDcSingleUserAdd
(
DcUserList
dcUserList
,
DcUser
dcUser
,
HGPZ009
dbPz009
)
throws
Exception
{
String
userId
=
dcUser
.
getYgid
();
// -1:冻结用户,1:正常
String
isLock
=
HGXSUtils
.
XsUser
.
convertIsLock
(
dcUserList
.
getStatus
());
// 新增用户
HGXSTools
.
XsUser
.
addUser
(
dbPz009
.
getAccountCode
(),
userId
,
zbUser
.
getName
(),
zbUser
.
getSex
(),
zb
User
.
getEmail
(),
zbUser
.
getCardid
()
);
HGXSTools
.
XsUser
.
addUser
(
dbPz009
.
getAccountCode
(),
userId
,
dcUser
.
getName
(),
dcUser
.
getSex
(),
dc
User
.
getEmail
(),
dcUser
.
getCardid
(),
isLock
);
// 新增用户和组织机构关系
Map
addMap
=
new
HashMap
();
addMap
.
put
(
"orgId"
,
dbPz009
.
getLoginPrefix
()
+
zb
User
.
getOrgsid
());
addMap
.
put
(
"orgId"
,
dbPz009
.
getLoginPrefix
()
+
dc
User
.
getOrgsid
());
addMap
.
put
(
"userId"
,
userId
);
addMap
.
put
(
"recCreator"
,
"System"
);
addMap
.
put
(
"recCreateTime"
,
DateUtils
.
shortDateTime
());
...
...
@@ -311,17 +315,20 @@ public class ServiceHGXSUser extends ServiceBase {
}
/**
* @param
zbUser
* @param
userId
* @param
dcUserList
* @param
dcUser
*/
private
void
syncDcSingleUserModify
(
DcUser
zbUser
,
String
userId
)
{
private
void
syncDcSingleUserModify
(
DcUser
List
dcUserList
,
DcUser
dcUser
)
{
Map
updateMap
=
new
HashMap
();
updateMap
.
put
(
User
.
FIELD_LOGIN_NAME
,
userId
);
updateMap
.
put
(
User
.
FIELD_USER_NAME
,
zbUser
.
getName
());
updateMap
.
put
(
User
.
FIELD_GENDER
,
HGXSUtils
.
XsUser
.
convertGender
(
zbUser
.
getSex
()));
updateMap
.
put
(
User
.
FIELD_EMAIL
,
zbUser
.
getEmail
());
updateMap
.
put
(
User
.
FIELD_MOBILE
,
zbUser
.
getMobile
());
updateMap
.
put
(
User
.
FIELD_ID_CARD
,
zbUser
.
getCardid
()
==
null
?
" "
:
zbUser
.
getCardid
());
updateMap
.
put
(
User
.
FIELD_LOGIN_NAME
,
dcUser
.
getYgid
());
updateMap
.
put
(
User
.
FIELD_USER_NAME
,
dcUser
.
getName
());
updateMap
.
put
(
User
.
FIELD_GENDER
,
HGXSUtils
.
XsUser
.
convertGender
(
dcUser
.
getSex
()));
updateMap
.
put
(
User
.
FIELD_EMAIL
,
dcUser
.
getEmail
());
updateMap
.
put
(
User
.
FIELD_MOBILE
,
dcUser
.
getMobile
());
updateMap
.
put
(
User
.
FIELD_ID_CARD
,
dcUser
.
getCardid
()
==
null
?
" "
:
dcUser
.
getCardid
());
// -1:冻结用户,1:正常
String
isLock
=
HGXSUtils
.
XsUser
.
convertIsLock
(
dcUserList
.
getStatus
());
updateMap
.
put
(
User
.
FIELD_IS_LOCKED
,
isLock
);
updateMap
.
put
(
User
.
FIELD_REC_REVISOR
,
"System"
);
updateMap
.
put
(
User
.
FIELD_REC_REVISE_TIME
,
DateUtils
.
shortDateTime
());
dao
.
update
(
HgXsSqlConstant
.
HgXsUser
.
UPDATE_DC_USER
,
updateMap
);
...
...
src/main/java/com/baosight/hggp/hg/xs/sql/HGXSUser.xml
View file @
18c08e74
...
...
@@ -123,6 +123,7 @@
MOBILE = #mobile#,
EMAIL = #email#,
ID_CARD = #idCard#,
IS_LOCKED = #isLocked#,
REC_REVISOR = #recRevisor#,
REC_REVISE_TIME = #recReviseTime#
WHERE LOGIN_NAME = #loginName#
...
...
src/main/java/com/baosight/hggp/hg/xs/tools/HGXSTools.java
View file @
18c08e74
...
...
@@ -206,9 +206,11 @@ public class HGXSTools {
* @param userName
* @param gender
* @param mobile
* @param idCard
* @param isLock
*/
public
static
void
addUser
(
String
accountCode
,
String
userId
,
String
userName
,
String
gender
,
String
mobile
,
String
idCard
)
throws
Exception
{
String
idCard
,
String
isLock
)
throws
Exception
{
Map
inInfoRowMap
=
new
HashMap
();
inInfoRowMap
.
put
(
"userId"
,
userId
);
inInfoRowMap
.
put
(
"loginName"
,
userId
);
...
...
src/main/java/com/baosight/hggp/hg/xs/utils/HGXSUtils.java
View file @
18c08e74
...
...
@@ -48,6 +48,16 @@ public class HGXSUtils {
}
}
/**
* 转换锁定状态
*
* @param status
* @return
*/
public
static
String
convertIsLock
(
String
status
)
{
// -1:冻结用户,1:正常
return
"冻结"
.
equals
(
status
)
?
"-1"
:
"1"
;
}
}
/**
...
...
src/main/java/com/baosight/xservices/xs/service/ServiceXS0102.java
View file @
18c08e74
package
com
.
baosight
.
xservices
.
xs
.
service
;
import
com.baosight.hggp.core.security.UserSessionUtils
;
import
com.baosight.hggp.hg.sc.util.HGSCUtil
;
import
com.baosight.hggp.util.AssertUtils
;
import
com.baosight.hggp.util.ObjectUtils
;
import
com.baosight.iplat4j.core.ei.EiBlock
;
...
...
@@ -105,11 +104,12 @@ public class ServiceXS0102 extends ServiceEPBase implements LoginConstants {
}
}
String
userGroupEname
=
(
String
)
inInfoRowMap
.
get
(
"groupName"
);
String
isLocked
=
(
String
)
inInfoRowMap
.
get
(
"isLocked"
);
inInfoRowMap
.
put
(
"userGroupEname"
,
userGroupEname
);
inInfoRowMap
.
put
(
"password"
,
password
);
inInfoRowMap
.
put
(
"rePass"
,
rePass
);
inInfoRowMap
.
put
(
"status"
,
"1"
);
inInfoRowMap
.
put
(
"isLocked"
,
"1"
);
inInfoRowMap
.
put
(
"isLocked"
,
StringUtils
.
isBlank
(
isLocked
)
?
"1"
:
isLocked
);
inInfoRowMap
.
put
(
"recCreator"
,
UserSession
.
getUser
().
getUsername
());
inInfoRowMap
.
put
(
"recCreateTime"
,
DateUtils
.
curDateTimeStr14
());
String
accountExpireDays
=
StringUtils
.
defaultIfEmpty
(
...
...
src/main/webapp/HG/CG/HGCG002.js
View file @
18c08e74
...
...
@@ -9,68 +9,69 @@ $(function () {
pageSize
:
20
,
pageSizes
:
[
20
,
50
,
70
,
100
],
},
columns
:
[
{
field
:
"operator"
,
title
:
"操作"
,
width
:
120
,
template
:
function
(
item
)
{
let
template
=
''
;
if
(
!
isBlank
(
item
.
id
)){
columns
:
[{
field
:
"operator"
,
title
:
"操作"
,
template
:
function
(
item
)
{
let
template
=
''
;
if
(
!
isBlank
(
item
.
id
))
{
template
+=
'<a style="cursor: pointer;display: inline-flex;justify-content: center;margin:auto 5px" '
+
'onclick="showDetail('
+
item
.
id
+
', '
+
item
.
status
+
',0, '
+
item
.
source
+
')" >详情</a>'
;
}
if
(
!
isBlank
(
item
.
id
))
{
//审核通过的,可以进行合同变更
if
(
item
.
status
==
2
)
{
template
+=
'<a style="cursor: pointer;display: inline-flex;justify-content: center;margin:auto 5px" '
+
'onclick="showDetail('
+
item
.
id
+
', '
+
item
.
status
+
',0, '
+
item
.
source
+
')" >详情</a>'
;
+
'onclick="showDetail('
+
item
.
id
+
', '
+
item
.
status
+
', 1, '
+
item
.
source
+
')" >合同变更</a>'
;
}
if
(
!
isBlank
(
item
.
id
)){
//审核通过的,可以进行合同变更
if
(
item
.
status
==
2
)
template
+=
'<a style="cursor: pointer;display: inline-flex;justify-content: center;margin:auto 5px" '
+
'onclick="showDetail('
+
item
.
id
+
', '
+
item
.
status
+
', 1, '
+
item
.
source
+
')" >合同变更</a>'
;
}
return
template
;
}
},
{
field
:
"companyCode"
,
title
:
"公司编码"
,
template
:
function
(
dataItem
)
{
for
(
let
i
=
0
;
i
<
companyCodeBox
.
length
;
i
++
)
{
if
(
companyCodeBox
[
i
][
'companyCode'
]
===
dataItem
[
'companyCode'
])
{
return
companyCodeBox
[
i
][
'companyCode'
];
}
return
template
;
}
},
{
field
:
"companyCode"
,
title
:
"公司编码"
,
template
:
function
(
dataItem
)
{
for
(
let
i
=
0
;
i
<
companyCodeBox
.
length
;
i
++
)
{
if
(
companyCodeBox
[
i
][
'companyCode'
]
===
dataItem
[
'companyCode'
])
{
return
companyCodeBox
[
i
][
'companyCode'
];
}
return
dataItem
[
"companyCode"
];
}
},
{
field
:
"projCode"
,
title
:
"项目编码"
,
template
:
function
(
dataItem
)
{
for
(
let
i
=
0
;
i
<
projCodeBox
.
length
;
i
++
)
{
if
(
projCodeBox
[
i
][
'valueField'
]
===
dataItem
[
'projCode'
])
{
dataItem
[
'projName'
]
=
projCodeBox
[
i
][
'textField'
]
return
projCodeBox
[
i
][
'valueField'
];
}
return
dataItem
[
"companyCode"
];
}
},
{
field
:
"projCode"
,
title
:
"项目编码"
,
template
:
function
(
dataItem
)
{
for
(
let
i
=
0
;
i
<
projCodeBox
.
length
;
i
++
)
{
if
(
projCodeBox
[
i
][
'valueField'
]
===
dataItem
[
'projCode'
])
{
dataItem
[
'projName'
]
=
projCodeBox
[
i
][
'textField'
]
return
projCodeBox
[
i
][
'valueField'
];
}
return
dataItem
[
"projCode"
]
==
null
?
""
:
dataItem
[
"projCode"
];
},
editor
:
function
(
container
,
options
)
{
let
inInfo
=
new
EiInfo
();
inInfo
.
set
(
"inqu_status-0-companyCode"
,
options
.
model
[
"companyCode"
]);
inInfo
.
set
(
"inqu_status-0-approvalStatus"
,
2
);
inInfo
.
set
(
"field"
,
options
.
field
);
EiCommunicator
.
send
(
"HGSC003"
,
"projComboBox"
,
inInfo
,
{
onSuccess
:
function
(
ei
)
{
projCodeBox
=
ei
.
getBlock
(
"projRecordByRole_block_id"
).
getMappedRows
();
},
onFail
:
function
(
ei
)
{
}
return
dataItem
[
"projCode"
];
},
editor
:
function
(
container
,
options
)
{
let
inInfo
=
new
EiInfo
();
inInfo
.
set
(
"inqu_status-0-companyCode"
,
options
.
model
[
"companyCode"
]);
inInfo
.
set
(
"inqu_status-0-approvalStatus"
,
2
);
inInfo
.
set
(
"field"
,
options
.
field
);
EiCommunicator
.
send
(
"HGSC003"
,
"projComboBox"
,
inInfo
,
{
onSuccess
:
function
(
ei
)
{
projCodeBox
=
ei
.
getBlock
(
"projRecordByRole_block_id"
).
getMappedRows
();
},
onFail
:
function
(
ei
)
{
}
},
{
async
:
false
});
var
input
=
$
(
'<input />'
);
input
.
attr
(
"name"
,
options
.
field
);
input
.
attr
(
"id"
,
options
.
field
);
input
.
appendTo
(
container
);
input
.
kendoDropDownList
({
dataSource
:
projCodeBox
,
minLength
:
0
,
dataTextField
:
"textField"
,
},
{
async
:
false
});
var
input
=
$
(
'<input />'
);
input
.
attr
(
"name"
,
options
.
field
);
input
.
attr
(
"id"
,
options
.
field
);
input
.
appendTo
(
container
);
input
.
kendoDropDownList
({
dataSource
:
projCodeBox
,
minLength
:
0
,
dataTextField
:
"textField"
,
dataValueField
:
"valueField"
,
optionLabelTemplate
:
"[#:valueField#]#:textField#"
,
valueTemplate
:
"[#:valueField#]#:textField#"
,
...
...
src/main/webapp/HG/CG/HGCG002.jsp
View file @
18c08e74
...
...
@@ -39,7 +39,7 @@
<EF:EFRegion
id=
"result"
title=
"明细信息"
>
<EF:EFGrid
blockId=
"result"
autoDraw=
"override"
isFloat=
"true"
checkMode=
"row"
height=
"65vh"
>
<EF:EFColumn
ename=
"id"
cname=
"内码"
hidden=
"true"
/>
<EF:EFColumn
ename=
"operator"
cname=
"操作"
locked=
"true"
enable=
"false"
width=
"
8
0"
align=
"center"
/>
<EF:EFColumn
ename=
"operator"
cname=
"操作"
locked=
"true"
enable=
"false"
width=
"
11
0"
align=
"center"
/>
<EF:EFComboColumn
ename=
"source"
cname=
"数据来源"
enable=
"false"
width=
"80"
align=
"center"
defaultValue=
"1"
>
<EF:EFCodeOption
codeName=
"hggp.hpcg.receiveSource"
/>
</EF:EFComboColumn>
...
...
@@ -50,8 +50,8 @@
align=
"center"
filter=
"contains"
sort=
"true"
>
<EF:EFOptions
blockId=
"roleCompany"
textField=
"companyName"
valueField=
"companyCode"
/>
</EF:EFComboColumn>
<EF:EFColumn
ename=
"companyName"
cname=
"公司名称"
width=
"
12
0"
enable=
"false"
readonly=
"true"
align=
"center"
/>
<EF:EFColumn
ename=
"projCode"
cname=
"项目编码"
width=
"1
0
0"
align=
"center"
required=
"true"
/>
<EF:EFColumn
ename=
"companyName"
cname=
"公司名称"
width=
"
20
0"
enable=
"false"
readonly=
"true"
align=
"center"
/>
<EF:EFColumn
ename=
"projCode"
cname=
"项目编码"
width=
"1
4
0"
align=
"center"
required=
"true"
/>
<EF:EFColumn
ename=
"projName"
cname=
"项目名称"
enable=
"false"
width=
"130"
align=
"center"
/>
<EF:EFColumn
ename=
"contractDate"
cname=
"合同日期"
width=
"100"
align=
"center"
editType=
"date"
dateFormat=
"yyyy-MM-dd"
parseFormats=
"['yyyyMMdd']"
required=
"true"
/>
...
...
src/main/webapp/HG/KC/HGKC001.js
View file @
18c08e74
...
...
@@ -38,6 +38,7 @@ $(function () {
loadComplete
:
function
(
grid
)
{
// 确认
$
(
"#CONFIRM"
).
on
(
"click"
,
confirm
);
// change事件
grid
.
dataSource
.
bind
(
"change"
,
function
(
e
)
{
supCodeChange
(
e
);
...
...
@@ -59,8 +60,7 @@ $(function () {
// 查询
$
(
"#QUERY"
).
on
(
"click"
,
query
);
// 选择收货
$
(
"#SELECT_RECEIVE"
).
on
(
"click"
,
selectReceive
);
$
(
"#BTN_SUBMIT"
).
on
(
"click"
,
batchUpdateSubmitStatus
);
downKeyUp
();
});
...
...
@@ -229,3 +229,25 @@ function updateSubmitStatus(id) {
});
}
/**
* 保存
*/
let
batchUpdateSubmitStatus
=
function
()
{
let
rows
=
resultGrid
.
getCheckedRows
();
if
(
rows
.
length
<
1
)
{
message
(
"请选择数据"
);
return
;
}
for
(
let
i
=
0
;
i
<
rows
.
length
;
i
++
)
{
if
(
rows
[
i
][
'submitStatus'
]
!=
0
)
{
message
(
"勾选的第"
+
(
i
+
1
)
+
"行提交状态不是未提交"
);
return
;
}
}
JSUtils
.
confirm
(
"确定对勾选中的["
+
rows
.
length
+
"]条数据做
\"
提交
\"
操作? "
,
{
ok
:
function
()
{
JSUtils
.
submitGridsData
(
"result"
,
"HGKC001"
,
"updateSubmitStatus"
,
true
);
}
});
}
src/main/webapp/HG/WD/HGWD001.js
View file @
18c08e74
...
...
@@ -254,7 +254,7 @@ $(function () {
IPLAT
.
NotificationUtil
(
ei
.
getMsg
(),
"success"
)
$
(
"#deleteOrgWindow"
).
data
(
"kendoWindow"
).
close
();
const
tree
=
$
(
'#categoryTree'
).
data
(
'kendoTreeView'
);
const
parentId
=
$
(
"#inqu_status
3
-0-orgParentId"
).
val
();
const
parentId
=
$
(
"#inqu_status-0-orgParentId"
).
val
();
// 刷新树节点
tree
.
reload
(
parentId
);
// 展开树
...
...
@@ -322,7 +322,6 @@ $(function () {
callbackName: addCallback
});
}*/
})
$
(
"#categoryTree"
).
mousedown
(
function
(
e
)
{
...
...
@@ -511,9 +510,9 @@ let query = function () {
/**
* 新增组织机构回调
*/
let
addCallback
=
function
(
parent
Org
Id
)
{
let
addCallback
=
function
(
parentId
)
{
// 回填父级ID
$
(
"#inqu_status
2-0-parentId"
).
val
(
parentOrg
Id
);
$
(
"#inqu_status
-0-orgParentId"
).
val
(
parent
Id
);
refreshTree
();
}
...
...
@@ -522,7 +521,7 @@ let addCallback = function (parentOrgId) {
*/
let
editCallback
=
function
(
parentOrgId
)
{
// 回填父级ID
$
(
"#inqu_status2-0-p
arentId"
).
val
(
parentOrgId
);
//$("#inqu_status-0-orgP
arentId").val(parentOrgId);
refreshTree
();
}
...
...
@@ -549,7 +548,7 @@ let refreshTree = function () {
}
// 刷新树节点
const
tree
=
$
(
"#categoryTree"
).
data
(
"kendoTreeView"
);
const
treeOrgId
=
$
(
"#inqu_status
2-0-p
arentId"
).
val
()
const
treeOrgId
=
$
(
"#inqu_status
-0-orgP
arentId"
).
val
()
tree
.
reload
(
treeOrgId
)
expandTreeNode
(
tree
,
treeOrgId
)
// tree.expandPath(treeOrgId)
...
...
@@ -834,6 +833,11 @@ function uploadFile() {
});
}
/**
* 文件变更
* @param docId 文件标识
* @param bizId 业务标识
*/
function
changeFile
(
docId
,
bizId
)
{
JSColorbox
.
open
({
href
:
"HGWD099A?methodName=initLoad&inqu_status-0-bizType=WD"
+
...
...
@@ -944,7 +948,7 @@ let showAuthButton = function () {
}
/**
*
文件上传
*
变更记录
*/
function
changeResord
()
{
let
leafType
=
IPLATUI
.
EFTree
.
categoryTree
.
selectTreeNode
.
leafLevel
;
...
...
src/main/webapp/HG/WD/HGWD001.jsp
View file @
18c08e74
...
...
@@ -66,14 +66,14 @@
<EF:EFRegion
id=
"result"
title=
"附件详情"
fitHeight=
"true"
>
<EF:EFGrid
blockId=
"result"
autoDraw=
"no"
personal=
"true"
serviceName=
"HGWD099"
queryMethod=
"query"
deleteMethod=
"delete"
>
<EF:EFColumn
ename=
"id"
cname=
"ID"
hidden=
"true"
/>
<EF:EFColumn
ename=
"docId"
cname=
"文件ID"
enable=
"false"
width=
"1
5
0"
/>
<EF:EFColumn
ename=
"docName"
cname=
"文件名称"
enable=
"false"
width=
"1
5
0"
/>
<EF:EFComboColumn
ename=
"status"
cname=
"状态"
enable=
"false"
width=
"1
2
0"
align=
"center"
defaultValue=
"0"
hidden=
"false"
>
<EF:EFColumn
ename=
"docId"
cname=
"文件ID"
enable=
"false"
width=
"1
8
0"
/>
<EF:EFColumn
ename=
"docName"
cname=
"文件名称"
enable=
"false"
width=
"1
8
0"
/>
<EF:EFComboColumn
ename=
"status"
cname=
"状态"
enable=
"false"
width=
"1
0
0"
align=
"center"
defaultValue=
"0"
hidden=
"false"
>
<EF:EFCodeOption
codeName=
"hggp.hgwd.status"
/>
</EF:EFComboColumn>
<EF:EFColumn
ename=
"createdTime"
cname=
"创建时间"
enable=
"false"
width=
"140"
align=
"center"
parseFormats=
"['yyyyMMddHHmmss']"
editType=
"datetime"
dateFormat=
"yyyy-MM-dd HH:mm:ss"
/>
<EF:EFColumn
ename=
"operator"
cname=
"操作"
enable=
"false"
width=
"
20
0"
align=
"center"
/>
<EF:EFColumn
ename=
"operator"
cname=
"操作"
enable=
"false"
width=
"
14
0"
align=
"center"
/>
</EF:EFGrid>
</EF:EFRegion>
</div>
...
...
src/main/webapp/HG/WD/HGWD001E.js
View file @
18c08e74
...
...
@@ -181,8 +181,8 @@ let save = function (btnNode) {
function
(
e
)
{
var
status
=
e
.
status
;
if
(
status
!==
-
1
)
{
let
parent
OrgId
=
$
(
"#inqu_status-0-parentOrg
Id"
).
val
();
parent
.
JSColorbox
.
setValueCallback
(
parent
Org
Id
);
let
parent
Id
=
$
(
"#inqu_status-0-parent
Id"
).
val
();
parent
.
JSColorbox
.
setValueCallback
(
parentId
);
}
});
btnNode
.
attr
(
"disabled"
,
false
);
...
...
src/main/webapp/HG/WD/HGWD001F.js
View file @
18c08e74
...
...
@@ -149,8 +149,8 @@ let save = function (btnNode) {
function
(
e
)
{
var
status
=
e
.
status
;
if
(
status
!==
-
1
)
{
let
parentOrgId
=
$
(
"#inqu_status-0-parentOrg
Id"
).
val
();
parent
.
JSColorbox
.
setValueCallback
(
parentOrg
Id
);
let
fileId
=
$
(
"#inqu_status-0-file
Id"
).
val
();
parent
.
JSColorbox
.
setValueCallback
(
file
Id
);
}
}
);
...
...
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