Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
Y
yn-health-science
Project
Project
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
徐俊
yn-health-science
Commits
a1924e46
Commit
a1924e46
authored
Dec 05, 2024
by
徐俊
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
xujun
parent
11f01e8a
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
18 additions
and
7 deletions
+18
-7
ProjectKPIStatisticDTO.java
...com/yiboshi/science/param/dto/ProjectKPIStatisticDTO.java
+3
-0
ComProjectKpitDetailServiceImpl.java
...science/service/impl/ComProjectKpitDetailServiceImpl.java
+11
-6
ComProjectServiceImpl.java
...m/yiboshi/science/service/impl/ComProjectServiceImpl.java
+4
-1
No files found.
science-admin/src/main/java/com/yiboshi/science/param/dto/ProjectKPIStatisticDTO.java
View file @
a1924e46
...
@@ -6,6 +6,7 @@ import io.swagger.annotations.ApiModelProperty;
...
@@ -6,6 +6,7 @@ import io.swagger.annotations.ApiModelProperty;
import
lombok.Data
;
import
lombok.Data
;
import
java.math.BigDecimal
;
import
java.math.BigDecimal
;
import
java.util.Date
;
import
java.util.List
;
import
java.util.List
;
...
@@ -17,6 +18,8 @@ public class ProjectKPIStatisticDTO extends BaseDTO {
...
@@ -17,6 +18,8 @@ public class ProjectKPIStatisticDTO extends BaseDTO {
private
String
appUnitName
;
private
String
appUnitName
;
private
String
projAttribute
;
private
String
projAttribute
;
private
String
projDeadline
;
private
String
projDeadline
;
private
Date
startDate
;
private
Date
endDate
;
/** 总预算数 */
/** 总预算数 */
@ApiModelProperty
(
value
=
"总预算数"
,
position
=
3
)
@ApiModelProperty
(
value
=
"总预算数"
,
position
=
3
)
private
BigDecimal
totalBudget
;
private
BigDecimal
totalBudget
;
...
...
science-admin/src/main/java/com/yiboshi/science/service/impl/ComProjectKpitDetailServiceImpl.java
View file @
a1924e46
...
@@ -22,6 +22,7 @@ import org.springframework.stereotype.Service;
...
@@ -22,6 +22,7 @@ import org.springframework.stereotype.Service;
import
java.util.ArrayList
;
import
java.util.ArrayList
;
import
java.util.List
;
import
java.util.List
;
import
java.util.Objects
;
import
java.util.concurrent.TimeUnit
;
import
java.util.concurrent.TimeUnit
;
import
java.util.stream.Collectors
;
import
java.util.stream.Collectors
;
...
@@ -44,17 +45,21 @@ public class ComProjectKpitDetailServiceImpl extends BaseServiceImpl<ComProjectK
...
@@ -44,17 +45,21 @@ public class ComProjectKpitDetailServiceImpl extends BaseServiceImpl<ComProjectK
}
}
public
void
insertList
(
List
<
ComProjectKpitDetailDTO
>
list
,
String
objectId
)
{
public
void
insertList
(
List
<
ComProjectKpitDetailDTO
>
list
,
String
objectId
)
{
ComProjectKpitDetail
model
=
new
ComProjectKpitDetail
();
//
ComProjectKpitDetail model =new ComProjectKpitDetail();
model
.
setObjectId
(
objectId
);
//
model.setObjectId(objectId);
this
.
delete
(
model
);
//
this.delete(model);
if
(
null
!=
list
)
{
if
(
null
!=
list
)
{
List
<
ComProjectKpitDetail
>
iList
=
new
ArrayList
<>();
//
List<ComProjectKpitDetail> iList = new ArrayList<>();
for
(
int
i
=
0
;
i
<
list
.
size
();
i
++)
{
for
(
int
i
=
0
;
i
<
list
.
size
();
i
++)
{
ComProjectKpitDetail
item
=
convert2Entity
(
list
.
get
(
i
));
ComProjectKpitDetail
item
=
convert2Entity
(
list
.
get
(
i
));
item
.
setObjectId
(
objectId
);
item
.
setObjectId
(
objectId
);
iList
.
add
(
item
);
if
(
item
.
getId
().
equals
(
item
.
getKpitId
()))
this
.
insert
(
item
);
else
this
.
update
(
item
);
//iList.add(item);
}
}
this
.
insertBatch
(
iList
);
//
this.insertBatch(iList);
}
}
}
}
public
void
deleteByObjectId
(
String
objectId
){
public
void
deleteByObjectId
(
String
objectId
){
...
...
science-admin/src/main/java/com/yiboshi/science/service/impl/ComProjectServiceImpl.java
View file @
a1924e46
...
@@ -398,8 +398,11 @@ public class ComProjectServiceImpl extends BaseServiceImpl<ComProjectDAO, ComPro
...
@@ -398,8 +398,11 @@ public class ComProjectServiceImpl extends BaseServiceImpl<ComProjectDAO, ComPro
kpiDTO
.
setYear1Goal
(
dto
.
getYear1Goal
());
kpiDTO
.
setYear1Goal
(
dto
.
getYear1Goal
());
kpiDTO
.
setYear2Goal
(
dto
.
getYear2Goal
());
kpiDTO
.
setYear2Goal
(
dto
.
getYear2Goal
());
kpiDTO
.
setYear3Goal
(
dto
.
getYear3Goal
());
kpiDTO
.
setYear3Goal
(
dto
.
getYear3Goal
());
if
(
Objects
.
nonNull
(
dto
.
getStartDate
())
&&
Objects
.
nonNull
(
dto
.
getEndDate
()))
if
(
Objects
.
nonNull
(
dto
.
getStartDate
())
&&
Objects
.
nonNull
(
dto
.
getEndDate
()))
{
kpiDTO
.
setStartDate
(
dto
.
getStartDate
());
kpiDTO
.
setEndDate
(
dto
.
getEndDate
());
kpiDTO
.
setProjDeadline
(
DateUtils
.
FormatDate
(
dto
.
getStartDate
())
+
"至"
+
DateUtils
.
FormatDate
(
dto
.
getEndDate
()));
kpiDTO
.
setProjDeadline
(
DateUtils
.
FormatDate
(
dto
.
getStartDate
())
+
"至"
+
DateUtils
.
FormatDate
(
dto
.
getEndDate
()));
}
List
<
ComProjectBudgetDTO
>
budgetDTO
=
dto
.
getBudget
();
List
<
ComProjectBudgetDTO
>
budgetDTO
=
dto
.
getBudget
();
if
(
null
!=
budgetDTO
)
{
if
(
null
!=
budgetDTO
)
{
// 资金总额
// 资金总额
...
...
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