Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
H
hp-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
hp-smart
Commits
ec46009f
Commit
ec46009f
authored
Jan 26, 2024
by
wancheng
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'origin/dev' into dev
parents
96e76f04
9976fe97
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
55 additions
and
15 deletions
+55
-15
HPSC002.java
src/main/java/com/baosight/hpjx/hp/sc/domain/HPSC002.java
+14
-1
ServiceHPSC002.java
.../java/com/baosight/hpjx/hp/sc/service/ServiceHPSC002.java
+9
-5
HPSC002.xml
src/main/java/com/baosight/hpjx/hp/sc/sql/HPSC002.xml
+24
-8
HPSC003.xml
src/main/java/com/baosight/hpjx/hp/sc/sql/HPSC003.xml
+1
-1
HPSC002.js
src/main/webapp/HP/SC/HPSC002.js
+6
-0
HPSC002.jsp
src/main/webapp/HP/SC/HPSC002.jsp
+1
-0
No files found.
src/main/java/com/baosight/hpjx/hp/sc/domain/HPSC002.java
View file @
ec46009f
...
@@ -52,6 +52,7 @@ public class HPSC002 extends DaoEPBase {
...
@@ -52,6 +52,7 @@ public class HPSC002 extends DaoEPBase {
private
String
updatedBy
=
" "
;
/* 更新人*/
private
String
updatedBy
=
" "
;
/* 更新人*/
private
String
updatedTime
;
/* 更新时间*/
private
String
updatedTime
;
/* 更新时间*/
private
String
remark
=
" "
;
/* 备注*/
private
String
remark
=
" "
;
/* 备注*/
private
Integer
level
=
0
;
/*层级*/
/**
/**
* initialize the metadata
* initialize the metadata
...
@@ -186,7 +187,9 @@ public class HPSC002 extends DaoEPBase {
...
@@ -186,7 +187,9 @@ public class HPSC002 extends DaoEPBase {
eiColumn
.
setDescName
(
"备注"
);
eiColumn
.
setDescName
(
"备注"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
"level"
);
eiColumn
.
setDescName
(
"层级"
);
eiMetadata
.
addMeta
(
eiColumn
);
}
}
/**
/**
...
@@ -646,6 +649,14 @@ public class HPSC002 extends DaoEPBase {
...
@@ -646,6 +649,14 @@ public class HPSC002 extends DaoEPBase {
this
.
remark
=
remark
;
this
.
remark
=
remark
;
}
}
public
Integer
getLevel
()
{
return
level
;
}
public
void
setLevel
(
Integer
level
)
{
this
.
level
=
level
;
}
/**
/**
* get the value from Map
* get the value from Map
*/
*/
...
@@ -681,6 +692,7 @@ public class HPSC002 extends DaoEPBase {
...
@@ -681,6 +692,7 @@ public class HPSC002 extends DaoEPBase {
setUpdatedBy
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
"updatedBy"
)),
updatedBy
));
setUpdatedBy
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
"updatedBy"
)),
updatedBy
));
setUpdatedTime
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
"updatedTime"
)),
updatedTime
));
setUpdatedTime
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
"updatedTime"
)),
updatedTime
));
setRemark
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
"remark"
)),
remark
));
setRemark
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
"remark"
)),
remark
));
setLevel
(
NumberUtils
.
toInteger
(
StringUtils
.
toString
(
map
.
get
(
"level"
)),
level
));
}
}
/**
/**
...
@@ -719,6 +731,7 @@ public class HPSC002 extends DaoEPBase {
...
@@ -719,6 +731,7 @@ public class HPSC002 extends DaoEPBase {
map
.
put
(
"updatedBy"
,
StringUtils
.
toString
(
updatedBy
,
eiMetadata
.
getMeta
(
"updatedBy"
)));
map
.
put
(
"updatedBy"
,
StringUtils
.
toString
(
updatedBy
,
eiMetadata
.
getMeta
(
"updatedBy"
)));
map
.
put
(
"updatedTime"
,
StringUtils
.
toString
(
updatedTime
,
eiMetadata
.
getMeta
(
"updatedTime"
)));
map
.
put
(
"updatedTime"
,
StringUtils
.
toString
(
updatedTime
,
eiMetadata
.
getMeta
(
"updatedTime"
)));
map
.
put
(
"remark"
,
StringUtils
.
toString
(
remark
,
eiMetadata
.
getMeta
(
"remark"
)));
map
.
put
(
"remark"
,
StringUtils
.
toString
(
remark
,
eiMetadata
.
getMeta
(
"remark"
)));
map
.
put
(
"level"
,
StringUtils
.
toString
(
level
,
eiMetadata
.
getMeta
(
"level"
)));
return
map
;
return
map
;
...
...
src/main/java/com/baosight/hpjx/hp/sc/service/ServiceHPSC002.java
View file @
ec46009f
...
@@ -5,7 +5,6 @@ import com.baosight.hpjx.common.DdynamicEnum;
...
@@ -5,7 +5,6 @@ import com.baosight.hpjx.common.DdynamicEnum;
import
com.baosight.hpjx.core.constant.CommonConstant
;
import
com.baosight.hpjx.core.constant.CommonConstant
;
import
com.baosight.hpjx.core.dao.DaoUtils
;
import
com.baosight.hpjx.core.dao.DaoUtils
;
import
com.baosight.hpjx.hp.constant.HPConstant
;
import
com.baosight.hpjx.hp.constant.HPConstant
;
import
com.baosight.hpjx.hp.kc.domain.HPKC003
;
import
com.baosight.hpjx.hp.pz.tools.HPPZTools
;
import
com.baosight.hpjx.hp.pz.tools.HPPZTools
;
import
com.baosight.hpjx.hp.sc.domain.HPSC003
;
import
com.baosight.hpjx.hp.sc.domain.HPSC003
;
import
com.baosight.hpjx.hp.sc.domain.HPSC004
;
import
com.baosight.hpjx.hp.sc.domain.HPSC004
;
...
@@ -18,7 +17,6 @@ import com.baosight.iplat4j.core.ei.EiConstant;
...
@@ -18,7 +17,6 @@ import com.baosight.iplat4j.core.ei.EiConstant;
import
com.baosight.iplat4j.core.ei.EiInfo
;
import
com.baosight.iplat4j.core.ei.EiInfo
;
import
com.baosight.iplat4j.core.exception.PlatException
;
import
com.baosight.iplat4j.core.exception.PlatException
;
import
com.baosight.iplat4j.core.service.impl.ServiceBase
;
import
com.baosight.iplat4j.core.service.impl.ServiceBase
;
import
com.baosight.iplat4j.core.util.DateUtil
;
import
com.baosight.iplat4j.core.util.NumberUtils
;
import
com.baosight.iplat4j.core.util.NumberUtils
;
import
com.baosight.iplat4j.core.web.threadlocal.UserSession
;
import
com.baosight.iplat4j.core.web.threadlocal.UserSession
;
import
com.baosight.iplat4j.ed.util.SequenceGenerator
;
import
com.baosight.iplat4j.ed.util.SequenceGenerator
;
...
@@ -88,10 +86,16 @@ public class ServiceHPSC002 extends ServiceBase {
...
@@ -88,10 +86,16 @@ public class ServiceHPSC002 extends ServiceBase {
if
(
StringUtils
.
isNotEmpty
(
hppz002
.
getPrdtCode
())
&&
!
hppz002
.
getParentId
().
equals
(
"root"
))
{
if
(
StringUtils
.
isNotEmpty
(
hppz002
.
getPrdtCode
())
&&
!
hppz002
.
getParentId
().
equals
(
"root"
))
{
hppz002
.
setPrdtName
(
HPPZTools
.
getPz004ByCode
(
hppz002
.
getPrdtCode
()).
getInventName
());
hppz002
.
setPrdtName
(
HPPZTools
.
getPz004ByCode
(
hppz002
.
getPrdtCode
()).
getInventName
());
}
}
DaoUtils
.
insert
(
"HPSC002.insert"
,
hppz002
.
toMap
());
if
(
hppz002
.
getParentId
().
equals
(
"root"
)){
if
(!
hppz002
.
getParentId
().
equals
(
"root"
))
{
hppz002
.
setLevel
(
new
Integer
(
1
));
this
.
checkTreeNodeLeaf
(
new
Long
(
hppz002
.
getParentId
()));
}
else
{
Integer
level
=
(
Integer
)
this
.
dao
.
get
(
"HPSC002.queryLevel"
,
"id"
,
hppz002
.
getParentId
());
hppz002
.
setLevel
(
level
);
}
}
DaoUtils
.
insert
(
"HPSC002.insert"
,
hppz002
.
toMap
());
// if (!hppz002.getParentId().equals("root")) {
// this.checkTreeNodeLeaf(new Long(hppz002.getParentId()));
// }
}
}
inInfo
.
setStatus
(
EiConstant
.
STATUS_SUCCESS
);
inInfo
.
setStatus
(
EiConstant
.
STATUS_SUCCESS
);
inInfo
.
setMsg
(
"新增成功!"
);
inInfo
.
setMsg
(
"新增成功!"
);
...
...
src/main/java/com/baosight/hpjx/hp/sc/sql/HPSC002.xml
View file @
ec46009f
...
@@ -67,7 +67,8 @@
...
@@ -67,7 +67,8 @@
CREATED_TIME as "createdTime",
<!-- 创建时间 -->
CREATED_TIME as "createdTime",
<!-- 创建时间 -->
UPDATED_BY as "updatedBy",
<!-- 更新人 -->
UPDATED_BY as "updatedBy",
<!-- 更新人 -->
UPDATED_TIME as "updatedTime",
<!-- 更新时间 -->
UPDATED_TIME as "updatedTime",
<!-- 更新时间 -->
REMARK as "remark"
<!-- 备注 -->
REMARK as "remark",
<!-- 备注 -->
LEVEL as "level"
FROM hpjx.t_hpsc002 WHERE 1=1
FROM hpjx.t_hpsc002 WHERE 1=1
AND PARENT_ID NOT IN ('root')
AND PARENT_ID NOT IN ('root')
AND DEL_STATUS = 0
AND DEL_STATUS = 0
...
@@ -95,6 +96,9 @@
...
@@ -95,6 +96,9 @@
<isNotEmpty
prepend=
" AND "
property=
"status"
>
<isNotEmpty
prepend=
" AND "
property=
"status"
>
STATUS = #status#
STATUS = #status#
</isNotEmpty>
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"level"
>
LEVEL = #level#
</isNotEmpty>
ORDER BY ID DESC
ORDER BY ID DESC
<!-- <dynamic prepend="ORDER BY">-->
<!-- <dynamic prepend="ORDER BY">-->
<!-- <isEmpty property="orderBy">-->
<!-- <isEmpty property="orderBy">-->
...
@@ -132,6 +136,9 @@
...
@@ -132,6 +136,9 @@
<isNotEmpty
prepend=
" AND "
property=
"status"
>
<isNotEmpty
prepend=
" AND "
property=
"status"
>
STATUS = #status#
STATUS = #status#
</isNotEmpty>
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"level"
>
LEVEL = #level#
</isNotEmpty>
</select>
</select>
<!--
<!--
...
@@ -251,9 +258,10 @@
...
@@ -251,9 +258,10 @@
CREATED_TIME,
<!-- 创建时间 -->
CREATED_TIME,
<!-- 创建时间 -->
UPDATED_BY,
<!-- 更新人 -->
UPDATED_BY,
<!-- 更新人 -->
UPDATED_TIME,
<!-- 更新时间 -->
UPDATED_TIME,
<!-- 更新时间 -->
REMARK
<!-- 备注 -->
REMARK,
<!-- 备注 -->
LEVEL
)
)
VALUES (#id#, #companyCode#, #deptCode#, #projCode#, #projName#, #parentId#, #parentPrdtName#, #type#, #leaf#, #sort#, #icon#, #prdtType#, #prdtCode#, #prdtName#, #inventRecordId#, #num#, #unitWt#, #totalWt#, #filePath1#, #filePath2#, #filePath3#, #filePath4#, #filePath5#, #status#, #delStatus#, #createdBy#, #createdTime#, #updatedBy#, #updatedTime#, #remark#)
VALUES (#id#, #companyCode#, #deptCode#, #projCode#, #projName#, #parentId#, #parentPrdtName#, #type#, #leaf#, #sort#, #icon#, #prdtType#, #prdtCode#, #prdtName#, #inventRecordId#, #num#, #unitWt#, #totalWt#, #filePath1#, #filePath2#, #filePath3#, #filePath4#, #filePath5#, #status#, #delStatus#, #createdBy#, #createdTime#, #updatedBy#, #updatedTime#, #remark#
, #level#
)
</insert>
</insert>
<delete
id=
"delete"
>
<delete
id=
"delete"
>
...
@@ -313,7 +321,8 @@
...
@@ -313,7 +321,8 @@
TYPE as "type",
<!-- 类别 -->
TYPE as "type",
<!-- 类别 -->
LEAF as "leaf",
<!-- 是否有叶子节点 -->
LEAF as "leaf",
<!-- 是否有叶子节点 -->
SORT as "sort",
<!-- 排序字段 -->
SORT as "sort",
<!-- 排序字段 -->
ICON as "icon"
<!-- 图片地址 -->
ICON as "icon",
<!-- 图片地址 -->
LEVEL as "level"
FROM
FROM
hpjx.t_hpsc002
hpjx.t_hpsc002
WHERE
WHERE
...
@@ -358,7 +367,8 @@
...
@@ -358,7 +367,8 @@
CREATED_TIME as "createdTime",
<!-- 创建时间 -->
CREATED_TIME as "createdTime",
<!-- 创建时间 -->
UPDATED_BY as "updatedBy",
<!-- 更新人 -->
UPDATED_BY as "updatedBy",
<!-- 更新人 -->
UPDATED_TIME as "updatedTime",
<!-- 更新时间 -->
UPDATED_TIME as "updatedTime",
<!-- 更新时间 -->
REMARK as "remark"
<!-- 备注 -->
REMARK as "remark",
<!-- 备注 -->
LEVEL as "level"
FROM hpjx.t_hpsc002
FROM hpjx.t_hpsc002
WHERE 1 = 1
WHERE 1 = 1
<isNotEmpty
prepend=
" AND "
property=
"id"
>
<isNotEmpty
prepend=
" AND "
property=
"id"
>
...
@@ -402,7 +412,8 @@
...
@@ -402,7 +412,8 @@
CREATED_TIME as "createdTime",
<!-- 创建时间 -->
CREATED_TIME as "createdTime",
<!-- 创建时间 -->
UPDATED_BY as "updatedBy",
<!-- 更新人 -->
UPDATED_BY as "updatedBy",
<!-- 更新人 -->
UPDATED_TIME as "updatedTime",
<!-- 更新时间 -->
UPDATED_TIME as "updatedTime",
<!-- 更新时间 -->
REMARK as "remark"
<!-- 备注 -->
REMARK as "remark",
<!-- 备注 -->
LEVEL as "level"
FROM hpjx.t_hpsc002 WHERE 1 = 1
FROM hpjx.t_hpsc002 WHERE 1 = 1
<isNotEmpty
prepend=
" AND "
property=
"id"
>
<isNotEmpty
prepend=
" AND "
property=
"id"
>
ID = #id#
ID = #id#
...
@@ -430,16 +441,21 @@
...
@@ -430,16 +441,21 @@
WHERE 1 = 1
WHERE 1 = 1
AND PARENT_ID != 'root'
AND PARENT_ID != 'root'
AND `STATUS` = 0
AND `STATUS` = 0
<isNotEmpty
prepend=
" AND "
property=
"p
arentId
"
>
<isNotEmpty
prepend=
" AND "
property=
"p
rojCode
"
>
PROJ_CODE = #projCode#
PROJ_CODE = #projCode#
</isNotEmpty>
</isNotEmpty>
</select>
</select>
<select
id=
"queryLevel"
resultClass=
"int"
>
SELECT LEVEL from hpjx.t_hpsc002
WHERE ID = #id#
</select>
<select
id=
"checkExamineNum1Count"
resultClass=
"int"
>
<select
id=
"checkExamineNum1Count"
resultClass=
"int"
>
SELECT COUNT(1) from hpjx.t_hpsc002
SELECT COUNT(1) from hpjx.t_hpsc002
WHERE 1 = 1
WHERE 1 = 1
AND PARENT_ID != 'root'
AND PARENT_ID != 'root'
<isNotEmpty
prepend=
" AND "
property=
"p
arentId
"
>
<isNotEmpty
prepend=
" AND "
property=
"p
rojCode
"
>
PROJ_CODE = #projCode#
PROJ_CODE = #projCode#
</isNotEmpty>
</isNotEmpty>
</select>
</select>
...
...
src/main/java/com/baosight/hpjx/hp/sc/sql/HPSC003.xml
View file @
ec46009f
...
@@ -104,7 +104,7 @@
...
@@ -104,7 +104,7 @@
FROM
FROM
hpjx.T_HPSC004
hpjx.T_HPSC004
WHERE
WHERE
PROJ_CODE = hpjx.T_HPSC003.PROJ_CODE
PARENT_ID = hpjx.T_HPSC003.PLAN_INFO_NO
),'%') AS "schedule"
),'%') AS "schedule"
FROM hpjx.T_HPSC003 WHERE 1=1
FROM hpjx.T_HPSC003 WHERE 1=1
<include
refid=
"condition"
/>
<include
refid=
"condition"
/>
...
...
src/main/webapp/HP/SC/HPSC002.js
View file @
ec46009f
...
@@ -79,6 +79,12 @@ $(function () {
...
@@ -79,6 +79,12 @@ $(function () {
});
});
},
},
onSuccess
:
function
(
e
)
{
if
(
e
.
eiInfo
.
extAttr
.
methodName
==
'update'
||
e
.
eiInfo
.
extAttr
.
methodName
==
'insert'
){
query
();
}
},
query
:
function
()
{
query
:
function
()
{
var
ei
=
new
EiInfo
();
var
ei
=
new
EiInfo
();
ei
.
set
(
"inqu_status-0-prdtType"
,
$
(
"#inqu_status-0-prdtType"
).
val
());
ei
.
set
(
"inqu_status-0-prdtType"
,
$
(
"#inqu_status-0-prdtType"
).
val
());
...
...
src/main/webapp/HP/SC/HPSC002.jsp
View file @
ec46009f
...
@@ -43,6 +43,7 @@
...
@@ -43,6 +43,7 @@
<EF:EFRegion
id=
"result"
title=
"明细信息"
>
<EF:EFRegion
id=
"result"
title=
"明细信息"
>
<EF:EFGrid
blockId=
"result"
autoDraw=
"no"
checkMode=
"single"
>
<EF:EFGrid
blockId=
"result"
autoDraw=
"no"
checkMode=
"single"
>
<EF:EFColumn
ename=
"id"
cname=
"主键"
hidden=
"true"
/>
<EF:EFColumn
ename=
"id"
cname=
"主键"
hidden=
"true"
/>
<EF:EFColumn
ename=
"level"
cname=
"层级"
hidden=
"true"
/>
<EF:EFColumn
enable=
"false"
ename=
"projCode"
cname=
"项目编码"
/>
<EF:EFColumn
enable=
"false"
ename=
"projCode"
cname=
"项目编码"
/>
<EF:EFColumn
enable=
"false"
ename=
"projName"
cname=
"项目名称"
/>
<EF:EFColumn
enable=
"false"
ename=
"projName"
cname=
"项目名称"
/>
<EF:EFComboColumn
cname=
"产品类型"
ename=
"prdtType"
width=
"90"
align=
"center"
required=
"true"
>
<EF:EFComboColumn
cname=
"产品类型"
ename=
"prdtType"
width=
"90"
align=
"center"
required=
"true"
>
...
...
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