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
c13e830a
Commit
c13e830a
authored
May 17, 2024
by
yukang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
合同管理
parent
6c8f42bf
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
85 additions
and
94 deletions
+85
-94
HGCW002.java
src/main/java/com/baosight/hggp/hg/cw/domain/HGCW002.java
+0
-3
ServiceHGCW002.java
.../java/com/baosight/hggp/hg/cw/service/ServiceHGCW002.java
+3
-0
ServiceHGCW002B.java
...java/com/baosight/hggp/hg/cw/service/ServiceHGCW002B.java
+1
-5
ServiceHGCW003.java
.../java/com/baosight/hggp/hg/cw/service/ServiceHGCW003.java
+27
-61
ServiceHGCW999.java
.../java/com/baosight/hggp/hg/cw/service/ServiceHGCW999.java
+34
-16
HGCW002A.js
src/main/webapp/HG/CW/HGCW002A.js
+6
-6
HGCW002B.js
src/main/webapp/HG/CW/HGCW002B.js
+0
-0
HGCW002B.jsp
src/main/webapp/HG/CW/HGCW002B.jsp
+4
-2
HGCW099.js
src/main/webapp/HG/CW/HGCW099.js
+10
-1
No files found.
src/main/java/com/baosight/hggp/hg/cw/domain/HGCW002.java
View file @
c13e830a
...
...
@@ -267,9 +267,6 @@ public class HGCW002 extends DaoEPBase {
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_TAX_POINTS
);
eiColumn
.
setType
(
"N"
);
eiColumn
.
setScaleLength
(
3
);
eiColumn
.
setFieldLength
(
15
);
eiColumn
.
setDescName
(
"税点"
);
eiMetadata
.
addMeta
(
eiColumn
);
...
...
src/main/java/com/baosight/hggp/hg/cw/service/ServiceHGCW002.java
View file @
c13e830a
...
...
@@ -96,6 +96,9 @@ public class ServiceHGCW002 extends ServiceBase {
HGCWTools
.
HgCw003
.
save
(
detail1Rows
,
contractNumber
,
userVO
);
HGCWTools
.
HgCw999
.
batchUpdate
(
detail2Rows
,
HGCW002
.
getId
());
}
else
{
HGCW002
.
setPlanStartDate
(
DateUtils
.
formatShort
(
HGCW002
.
getPlanStartDate
()));
HGCW002
.
setPlanEndDate
(
DateUtils
.
formatShort
(
HGCW002
.
getPlanEndDate
()));
HGCW002
.
setSigningDate
(
DateUtils
.
formatShort
(
HGCW002
.
getSigningDate
()));
this
.
modify
(
HGCW002
);
}
}
...
...
src/main/java/com/baosight/hggp/hg/cw/service/ServiceHGCW002B.java
View file @
c13e830a
...
...
@@ -38,14 +38,10 @@ public class ServiceHGCW002B extends ServiceBase {
@OperationLogAnnotation
(
operModul
=
"修改合同"
,
operType
=
"查询"
,
operDesc
=
"初始化"
)
public
EiInfo
initLoad
(
EiInfo
inInfo
)
{
try
{
CommonMethod
.
initBlock
(
inInfo
,
Arrays
.
asList
(
DdynamicEnum
.
PROJECT_CODE_BOX_BLOCK_ID
),
null
,
false
);
String
id
=
inInfo
.
getString
(
"id"
);
HGCW002
HGCW002
=
HGCWTools
.
HgCw002
.
getId
(
id
);
inInfo
.
addBlock
(
EiConstant
.
resultBlock
).
addRow
(
HGCW002
);
CommonMethod
.
initBlock
(
inInfo
,
Arrays
.
asList
(
DdynamicEnum
.
PROJECT_CODE_BOX_BLOCK_ID
),
new
HashMap
<
String
,
Object
>(){
{
put
(
"projCode"
,
HGCW002
.
getProjCode
());}
},
false
);
//获取清单
List
<
HGCW003
>
hgcw003List
=
HGCWTools
.
HgCw003
.
queryByContractNumber
(
HGCW002
.
getContractNumber
());
inInfo
.
addBlock
(
"detail1"
).
addRows
(
hgcw003List
);
...
...
src/main/java/com/baosight/hggp/hg/cw/service/ServiceHGCW003.java
View file @
c13e830a
...
...
@@ -4,6 +4,7 @@ import com.baosight.hggp.aspect.annotation.OperationLogAnnotation;
import
com.baosight.hggp.common.DdynamicEnum
;
import
com.baosight.hggp.core.dao.DaoUtils
;
import
com.baosight.hggp.hg.cw.domain.HGCW003
;
import
com.baosight.hggp.hg.cw.tools.HGCWTools
;
import
com.baosight.hggp.util.CommonMethod
;
import
com.baosight.hggp.util.DateUtils
;
import
com.baosight.hggp.util.LogUtils
;
...
...
@@ -67,25 +68,29 @@ public class ServiceHGCW003 extends ServiceBase {
*/
@OperationLogAnnotation
(
operModul
=
"合同清单"
,
operType
=
"保存"
,
operDesc
=
"保存"
)
public
EiInfo
save
(
EiInfo
inInfo
)
{
EiInfo
eiInfo
=
new
EiInfo
();
try
{
List
<
Map
>
resultRows
=
inInfo
.
getBlock
(
EiConstant
.
resultBlock
).
getRows
();
List
<
Map
>
resultRows
=
inInfo
.
getBlock
(
"detail1"
).
getRows
();
String
contractNumber
=
""
;
// 写入数据
for
(
int
i
=
0
;
i
<
resultRows
.
size
();
i
++)
{
HGCW003
HGCW003
=
new
HGCW003
();
HGCW003
.
fromMap
(
resultRows
.
get
(
i
));
contractNumber
=
HGCW003
.
getContractNumber
();
if
(
HGCW003
.
getId
()
==
null
||
HGCW003
.
getId
()
==
0
)
{
this
.
add
(
HGCW003
);
}
else
{
this
.
modify
(
HGCW003
);
}
}
// inInfo = this.query(inInfo);
inInfo
.
setStatus
(
EiConstant
.
STATUS_DEFAULT
);
inInfo
.
setMsg
(
"操作成功!本次对["
+
resultRows
.
size
()
+
"]条数据保存成功!"
);
List
<
HGCW003
>
hgcw003List
=
HGCWTools
.
HgCw003
.
queryByContractNumber
(
contractNumber
);
eiInfo
.
addBlock
(
"detail1"
).
addRows
(
hgcw003List
);
eiInfo
.
setStatus
(
EiConstant
.
STATUS_DEFAULT
);
eiInfo
.
setMsg
(
"操作成功!本次对["
+
resultRows
.
size
()
+
"]条数据保存成功!"
);
}
catch
(
Exception
e
)
{
LogUtils
.
setDetailMsg
(
inInfo
,
e
,
"保存失败"
);
}
return
in
Info
;
return
ei
Info
;
}
/**
...
...
@@ -107,57 +112,11 @@ public class ServiceHGCW003 extends ServiceBase {
public
void
modify
(
HGCW003
HGCW003
)
{
DaoUtils
.
update
(
"HGCW003.update"
,
HGCW003
);
}
/**
* 新增操作
*
* @param inInfo
* @return
*/
@OperationLogAnnotation
(
operModul
=
"合同清单"
,
operType
=
"新增"
,
operDesc
=
"新增"
)
@Override
public
EiInfo
insert
(
EiInfo
inInfo
)
{
try
{
List
<
Map
>
resultRows
=
inInfo
.
getBlock
(
EiConstant
.
resultBlock
).
getRows
();
// 数据写入
for
(
int
i
=
0
;
i
<
resultRows
.
size
();
i
++)
{
HGCW003
HGCW003
=
new
HGCW003
();
HGCW003
.
fromMap
(
resultRows
.
get
(
i
));
DaoUtils
.
insert
(
"HGCW003.insert"
,
HGCW003
);
}
inInfo
=
this
.
query
(
inInfo
);
inInfo
.
setStatus
(
EiConstant
.
STATUS_DEFAULT
);
inInfo
.
setMsg
(
"操作成功!本次对["
+
resultRows
.
size
()
+
"]条数据新增成功!"
);
}
catch
(
Exception
e
)
{
LogUtils
.
setDetailMsg
(
inInfo
,
e
,
"新增失败"
);
}
return
inInfo
;
}
/**
* 修改操作
*
* @param inInfo
* @return
*/
@OperationLogAnnotation
(
operModul
=
"合同清单"
,
operType
=
"修改"
,
operDesc
=
"修改"
)
public
EiInfo
update
(
EiInfo
inInfo
)
{
try
{
List
<
Map
>
resultRows
=
inInfo
.
getBlock
(
EiConstant
.
resultBlock
).
getRows
();
for
(
int
i
=
0
;
i
<
resultRows
.
size
();
i
++)
{
HGCW003
HGCW003
=
new
HGCW003
();
HGCW003
.
fromMap
(
resultRows
.
get
(
i
));
DaoUtils
.
update
(
"HGCW003.update"
,
HGCW003
);
}
inInfo
=
this
.
query
(
inInfo
);
inInfo
.
setStatus
(
EiConstant
.
STATUS_DEFAULT
);
inInfo
.
setMsg
(
"操作成功!本次对["
+
resultRows
.
size
()
+
"]条数据修改成功!"
);
}
catch
(
Exception
e
)
{
LogUtils
.
setDetailMsg
(
inInfo
,
e
,
"修改失败"
);
}
return
inInfo
;
public
void
deleteEntity
(
HGCW003
HGCW003
)
{
DaoUtils
.
update
(
"HGCW003.delete"
,
HGCW003
);
}
/**
* 删除操作
*
...
...
@@ -166,18 +125,25 @@ public class ServiceHGCW003 extends ServiceBase {
*/
@OperationLogAnnotation
(
operModul
=
"合同清单"
,
operType
=
"删除"
,
operDesc
=
"删除"
)
public
EiInfo
delete
(
EiInfo
inInfo
)
{
EiInfo
eiInfo
=
new
EiInfo
();
try
{
List
<
Map
>
resultRows
=
inInfo
.
getBlock
(
EiConstant
.
resultBlock
).
getRows
();
List
<
Map
>
resultRows
=
inInfo
.
getBlock
(
"detail1"
).
getRows
();
String
contractNumber
=
""
;
// 写入数据
for
(
int
i
=
0
;
i
<
resultRows
.
size
();
i
++)
{
DaoUtils
.
update
(
"HGCW003.delete"
,
resultRows
.
get
(
i
));
HGCW003
HGCW003
=
new
HGCW003
();
HGCW003
.
fromMap
(
resultRows
.
get
(
i
));
contractNumber
=
HGCW003
.
getContractNumber
();
this
.
deleteEntity
(
HGCW003
);
}
inInfo
=
this
.
query
(
inInfo
);
inInfo
.
setStatus
(
EiConstant
.
STATUS_DEFAULT
);
inInfo
.
setMsg
(
"操作成功!本次对["
+
resultRows
.
size
()
+
"]条数据删除成功!"
);
List
<
HGCW003
>
hgcw003List
=
HGCWTools
.
HgCw003
.
queryByContractNumber
(
contractNumber
);
eiInfo
.
addBlock
(
"detail1"
).
addRows
(
hgcw003List
);
eiInfo
.
setStatus
(
EiConstant
.
STATUS_DEFAULT
);
eiInfo
.
setMsg
(
"操作成功!本次对["
+
resultRows
.
size
()
+
"]条数据删除成功!"
);
}
catch
(
Exception
e
)
{
LogUtils
.
setDetailMsg
(
inInfo
,
e
,
"删除失败"
);
}
return
in
Info
;
return
ei
Info
;
}
/**
...
...
src/main/java/com/baosight/hggp/hg/cw/service/ServiceHGCW999.java
View file @
c13e830a
...
...
@@ -3,7 +3,9 @@ package com.baosight.hggp.hg.cw.service;
import
com.baosight.hggp.aspect.annotation.OperationLogAnnotation
;
import
com.baosight.hggp.core.constant.CommonConstant
;
import
com.baosight.hggp.core.dao.DaoUtils
;
import
com.baosight.hggp.hg.cw.domain.HGCW003
;
import
com.baosight.hggp.hg.cw.domain.HGCW999
;
import
com.baosight.hggp.hg.cw.tools.HGCWTools
;
import
com.baosight.hggp.hg.ds.domain.HGDS002
;
import
com.baosight.hggp.util.FileUtils
;
import
com.baosight.hggp.util.LogUtils
;
...
...
@@ -88,7 +90,17 @@ public class ServiceHGCW999 extends ServiceEPBase {
}
return
inInfo
;
}
public
void
add
(
HGCW999
HGCW999
)
{
DaoUtils
.
insert
(
"HGCW999.insert"
,
HGCW999
);
}
public
void
deleteEntity
(
HGCW999
HGCW999
)
{
DaoUtils
.
update
(
"HGCW999.delete"
,
HGCW999
);
}
/**
* 新增操作
*
...
...
@@ -98,19 +110,24 @@ public class ServiceHGCW999 extends ServiceEPBase {
@OperationLogAnnotation
(
operModul
=
"附件清单"
,
operType
=
"新增"
,
operDesc
=
"物料清单-附件清单A-新增操作"
)
@Override
public
EiInfo
insert
(
EiInfo
inInfo
)
{
EiInfo
eiInfo
=
new
EiInfo
();
try
{
Long
matId
=
null
;
List
<
Map
>
resultRows
=
inInfo
.
getBlock
(
EiConstant
.
resultBlock
).
getRows
();
for
(
int
i
=
0
;
i
<
resultRows
.
size
();
i
++)
{
HGCW999
fSc002A
=
new
HGCW999
();
fSc002A
.
fromMap
(
resultRows
.
get
(
i
));
DaoUtils
.
insert
(
HGCW999
.
INSERT
,
fSc002A
);
matId
=
fSc002A
.
getMatId
();
this
.
add
(
fSc002A
);
}
inInfo
.
setStatus
(
EiConstant
.
STATUS_DEFAULT
);
inInfo
.
setMsg
(
"操作成功!本次对["
+
resultRows
.
size
()
+
"]条数据新增成功!"
);
List
<
HGCW999
>
hgcw999List
=
HGCWTools
.
HgCw999
.
queryByBiz
(
matId
,
"HT"
);
eiInfo
.
addBlock
(
"detail2"
).
addRows
(
hgcw999List
);
eiInfo
.
setStatus
(
EiConstant
.
STATUS_DEFAULT
);
eiInfo
.
setMsg
(
"操作成功!本次对["
+
resultRows
.
size
()
+
"]条数据新增成功!"
);
}
catch
(
Exception
e
)
{
LogUtils
.
setDetailMsg
(
in
Info
,
e
,
"新增失败"
);
LogUtils
.
setDetailMsg
(
ei
Info
,
e
,
"新增失败"
);
}
return
in
Info
;
return
ei
Info
;
}
/**
...
...
@@ -121,23 +138,24 @@ public class ServiceHGCW999 extends ServiceEPBase {
*/
@OperationLogAnnotation
(
operModul
=
"附件清单"
,
operType
=
"删除"
,
operDesc
=
"物料清单-附件清单A-删除操作"
)
public
EiInfo
delete
(
EiInfo
inInfo
)
{
EiInfo
eiInfo
=
new
EiInfo
();
try
{
List
<
Map
>
resultRows
=
inInfo
.
getBlock
(
EiConstant
.
resultBlock
).
getRows
();
Long
matId
=
null
;
List
<
Map
>
resultRows
=
inInfo
.
getBlock
(
"detail2"
).
getRows
();
for
(
int
i
=
0
;
i
<
resultRows
.
size
();
i
++)
{
HGCW999
fSc002A
=
new
HGCW999
();
fSc002A
.
fromMap
(
resultRows
.
get
(
i
));
DaoUtils
.
update
(
HGCW999
.
DELETE
,
fSc002A
);
// if (!fSc002A.getDocId().isEmpty()) {
// this.delectDoc(fSc002A.getDocId());
// }
matId
=
fSc002A
.
getMatId
();
this
.
deleteEntity
(
fSc002A
);
}
inInfo
=
this
.
query
(
inInfo
);
inInfo
.
setStatus
(
EiConstant
.
STATUS_DEFAULT
);
inInfo
.
setMsg
(
"操作成功!本次对["
+
resultRows
.
size
()
+
"]条数据删除成功!"
);
List
<
HGCW999
>
hgcw999List
=
HGCWTools
.
HgCw999
.
queryByBiz
(
matId
,
"HT"
);
eiInfo
.
addBlock
(
"detail2"
).
addRows
(
hgcw999List
);
eiInfo
.
setStatus
(
EiConstant
.
STATUS_DEFAULT
);
eiInfo
.
setMsg
(
"操作成功!本次对["
+
resultRows
.
size
()
+
"]条数据删除成功!"
);
}
catch
(
Exception
e
)
{
LogUtils
.
setDetailMsg
(
in
Info
,
e
,
"删除失败"
);
LogUtils
.
setDetailMsg
(
ei
Info
,
e
,
"删除失败"
);
}
return
in
Info
;
return
ei
Info
;
}
/**
...
...
src/main/webapp/HG/CW/HGCW002A.js
View file @
c13e830a
...
...
@@ -33,10 +33,10 @@ $(function() {
var
totalPriceIncluding
=
0
;
var
valueAddedTax
=
0
;
allRows
.
forEach
(
function
(
row
,
index
)
{
totalPriceExcluding
+=
row
.
totalPriceExcluding
;
totalPriceIncluding
+=
row
.
totalPriceIncluding
;
totalPriceExcluding
+=
parseFloat
(
row
.
totalPriceExcluding
)
;
totalPriceIncluding
+=
parseFloat
(
row
.
totalPriceIncluding
)
;
});
valueAddedTax
=
totalPriceIncluding
-
totalPriceExcluding
;
valueAddedTax
=
parseFloat
(
totalPriceIncluding
)
-
parseFloat
(
totalPriceExcluding
)
;
$
(
"#result-0-totalContractPriceExcluding"
).
val
(
totalPriceExcluding
.
toFixed
(
3
))
$
(
"#result-0-totalContractPriceIncluding"
).
val
(
totalPriceIncluding
.
toFixed
(
3
))
$
(
"#result-0-valueAddedTax"
).
val
(
valueAddedTax
.
toFixed
(
3
))
...
...
@@ -230,10 +230,10 @@ function uploadFileFunc() {
*
* @param docId
*/
function
uploadFileCallback
(
d
ocId
)
{
function
uploadFileCallback
(
d
ata
)
{
let
inEiInfo
=
new
EiInfo
();
inEiInfo
.
set
(
"result-0-docId"
,
docId
);
inEiInfo
.
set
(
"result-0-bizType"
,
$
(
"#inqu_status-0-bizType"
).
val
()
);
inEiInfo
.
set
(
"result-0-docId"
,
d
ata
.
d
ocId
);
inEiInfo
.
set
(
"result-0-bizType"
,
data
.
bizType
);
EiCommunicator
.
send
(
'HGCW999'
,
'insert'
,
inEiInfo
,
{
onSuccess
(
response
)
{
if
(
response
.
status
===
0
)
{
...
...
src/main/webapp/HG/CW/HGCW002B.js
View file @
c13e830a
This diff is collapsed.
Click to expand it.
src/main/webapp/HG/CW/HGCW002B.jsp
View file @
c13e830a
...
...
@@ -9,6 +9,8 @@
<EF:EFPage
title=
"修改合同"
>
<EF:EFRegion
id=
"inqu1"
title=
"基本信息"
>
<div
class=
"row"
>
<EF:EFInput
ename=
"result-0-id"
cname=
"id"
type=
"hidden"
/>
<EF:EFSelect
cname=
"项目编号"
ename=
"projCodeBox"
colWidth=
"4"
required=
"true"
filter=
"contains"
>
<EF:EFOption
label=
"-- 请选择 --"
value=
""
/>
<EF:EFOptions
...
...
@@ -111,8 +113,8 @@
</EF:EFRegion>
<EF:EFRegion
id=
"detail1"
title=
"合同清单"
>
<EF:EFGrid
blockId=
"detail1"
autoDraw=
"override"
checkMode=
"row"
isFloat=
"true"
>
<EF:EFColumn
ename=
"rowNo"
cname=
"行号"
hidden=
"true"
/>
<EF:EFColumn
ename=
"id"
cname=
"主键"
hidden=
"true"
/>
<EF:EFColumn
ename=
"contractNumber"
cname=
"合同号"
hidden=
"true"
/>
<EF:EFColumn
ename=
"inventory"
cname=
"清单"
align=
"center"
/>
<EF:EFColumn
ename=
"unit"
cname=
"单位"
align=
"center"
/>
<EF:EFColumn
ename=
"provisionalQuantity"
cname=
"暂定工程量"
format=
"{0:N3}"
align=
"center"
/>
...
...
@@ -126,8 +128,8 @@
</EF:EFRegion>
<EF:EFRegion
id=
"detail2"
title=
"附件信息"
>
<EF:EFGrid
blockId=
"detail2"
autoDraw=
"override"
checkMode=
"row"
isFloat=
"true"
>
<EF:EFColumn
ename=
"rowNo"
cname=
"行号"
hidden=
"true"
/>
<EF:EFColumn
ename=
"id"
cname=
"ID"
hidden=
"true"
/>
<EF:EFColumn
ename=
"matId"
cname=
"matId"
hidden=
"true"
/>
<EF:EFColumn
ename=
"docId"
cname=
"文件ID"
enable=
"false"
width=
"150"
/>
<EF:EFColumn
ename=
"docName"
cname=
"文件名称"
enable=
"false"
width=
"150"
/>
<EF:EFColumn
ename=
"createdTime"
cname=
"创建时间"
enable=
"false"
width=
"140"
align=
"center"
...
...
src/main/webapp/HG/CW/HGCW099.js
View file @
c13e830a
...
...
@@ -10,10 +10,19 @@ $(function () {
}
$
(
"#fileDocId"
).
val
(
docId
);
NotificationUtil
(
"附件上传成功"
);
var
matId
=
$
(
"#inqu_status-0-matId"
).
val
();
var
bizType
=
$
(
"#inqu_status-0-bizType"
).
val
();
console
.
log
(
$
(
"#fileDocId"
).
val
())
console
.
log
(
$
(
"#inqu_status-0-matId"
).
val
())
console
.
log
(
$
(
"#inqu_status-0-bizType"
).
val
())
var
data
=
{
docId
:
docId
,
matId
:
matId
,
bizType
:
bizType
}
// saveTemp(e);
try
{
parent
.
JSColorbox
.
setValueCallback
(
d
ocId
);
parent
.
JSColorbox
.
setValueCallback
(
d
ata
);
}
catch
(
e
){
}
},
...
...
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