Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Sign in
Toggle navigation
T
tamp_fund
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
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
周鹏
tamp_fund
Commits
385f0d7b
Commit
385f0d7b
authored
Apr 29, 2021
by
张亚辉
Browse files
Options
Browse Files
Download
Plain Diff
merge
parents
03465534
709f82bb
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
519 additions
and
348 deletions
+519
-348
ProductApi.java
src/main/java/com/tanpu/fund/api/ProductApi.java
+4
-0
ProductController.java
...ain/java/com/tanpu/fund/controller/ProductController.java
+5
-0
IfaImportedNonavFund.java
...com/tanpu/fund/entity/generator/IfaImportedNonavFund.java
+38
-108
IfaImportedNonavFundExample.java
...pu/fund/entity/generator/IfaImportedNonavFundExample.java
+299
-1
IfaImportedNonavFundMapper.java
...npu/fund/mapper/generator/IfaImportedNonavFundMapper.java
+19
-39
ProductService.java
src/main/java/com/tanpu/fund/service/ProductService.java
+3
-0
ProductServiceImpl.java
.../java/com/tanpu/fund/service/impl/ProductServiceImpl.java
+23
-0
IfaImportedNonavFundMapper.xml
...esources/mybatis/generator/IfaImportedNonavFundMapper.xml
+128
-200
No files found.
src/main/java/com/tanpu/fund/api/ProductApi.java
View file @
385f0d7b
...
@@ -44,6 +44,10 @@ public interface ProductApi {
...
@@ -44,6 +44,10 @@ public interface ProductApi {
@GetMapping
(
"/product/list"
)
@GetMapping
(
"/product/list"
)
CommonResp
<
List
<
ProductInfoVO
>>
getProductList
(
@ApiParam
(
"产品id"
)
@RequestParam
(
"ids"
)
List
<
String
>
ids
);
CommonResp
<
List
<
ProductInfoVO
>>
getProductList
(
@ApiParam
(
"产品id"
)
@RequestParam
(
"ids"
)
List
<
String
>
ids
);
@ApiOperation
(
"获取产品详情"
)
@GetMapping
(
"/product/not/net"
)
CommonResp
<
List
<
ProductInfoVO
>>
getProductListNotNetInfo
(
@ApiParam
(
"产品id"
)
@RequestParam
(
"ids"
)
List
<
String
>
ids
);
@ApiOperation
(
"单位净值"
)
@ApiOperation
(
"单位净值"
)
@GetMapping
(
"/unit/net"
)
@GetMapping
(
"/unit/net"
)
CommonResp
<
UnitNetVO
>
getUnitNetInfo
(
@ApiParam
(
"产品id"
)
@RequestParam
(
"id"
)
String
id
,
@ApiParam
(
"对比基金id"
)
@RequestParam
(
value
=
"ratioId"
,
required
=
false
)
String
ratioId
,
CommonResp
<
UnitNetVO
>
getUnitNetInfo
(
@ApiParam
(
"产品id"
)
@RequestParam
(
"id"
)
String
id
,
@ApiParam
(
"对比基金id"
)
@RequestParam
(
value
=
"ratioId"
,
required
=
false
)
String
ratioId
,
...
...
src/main/java/com/tanpu/fund/controller/ProductController.java
View file @
385f0d7b
...
@@ -48,6 +48,11 @@ public class ProductController implements ProductApi {
...
@@ -48,6 +48,11 @@ public class ProductController implements ProductApi {
return
CommonResp
.
success
(
this
.
productService
.
getProductDetail
(
id
));
return
CommonResp
.
success
(
this
.
productService
.
getProductDetail
(
id
));
}
}
@Override
public
CommonResp
<
List
<
ProductInfoVO
>>
getProductListNotNetInfo
(
List
<
String
>
ids
)
{
return
CommonResp
.
success
(
this
.
productService
.
getProductListNotNet
(
ids
));
}
@Override
@Override
public
CommonResp
<
List
<
ProductInfoVO
>>
getProductList
(
List
<
String
>
ids
)
{
public
CommonResp
<
List
<
ProductInfoVO
>>
getProductList
(
List
<
String
>
ids
)
{
return
CommonResp
.
success
(
this
.
productService
.
getProductList
(
ids
));
return
CommonResp
.
success
(
this
.
productService
.
getProductList
(
ids
));
...
...
src/main/java/com/tanpu/fund/entity/generator/IfaImportedNonavFund.java
View file @
385f0d7b
package
com
.
tanpu
.
fund
.
entity
.
generator
;
package
com
.
tanpu
.
fund
.
entity
.
generator
;
import
java.util.Date
;
import
java.util.Date
;
import
lombok.AllArgsConstructor
;
import
lombok.Builder
;
import
lombok.Data
;
import
lombok.NoArgsConstructor
;
/**
* @author: zhoupeng
* <p>
* =========================================
* =========================================
* ======== ========
* ======= ========== ======= =======
* ====== ===== == ==== ======
* ===== ===== == === =====
* ===== ===== == === =====
* ===== ===== == === =====
* ====== ========== == ======
* ======= =======
* =========================================
* =========================================
* <p>
* @email: zhoupeng_08@163.com
*/
@Data
@Builder
@AllArgsConstructor
@NoArgsConstructor
public
class
IfaImportedNonavFund
{
public
class
IfaImportedNonavFund
{
/**
/**
* id
* id
...
@@ -18,6 +44,16 @@ public class IfaImportedNonavFund {
...
@@ -18,6 +44,16 @@ public class IfaImportedNonavFund {
*/
*/
private
String
startEndDate
;
private
String
startEndDate
;
/**
* 产品概要
*/
private
String
summary
;
/**
* 产品详情
*/
private
String
detail
;
/**
/**
* 创建时间
* 创建时间
*/
*/
...
@@ -43,16 +79,6 @@ public class IfaImportedNonavFund {
...
@@ -43,16 +79,6 @@ public class IfaImportedNonavFund {
*/
*/
private
String
orgId
;
private
String
orgId
;
/**
* 产品概要
*/
private
String
summary
;
/**
* 产品详情
*/
private
String
detail
;
/**
/**
* 基金附件pdf
* 基金附件pdf
*/
*/
...
@@ -62,100 +88,4 @@ public class IfaImportedNonavFund {
...
@@ -62,100 +88,4 @@ public class IfaImportedNonavFund {
* 基金图片
* 基金图片
*/
*/
private
String
fundPng
;
private
String
fundPng
;
}
public
String
getId
()
{
return
id
;
}
public
void
setId
(
String
id
)
{
this
.
id
=
id
;
}
public
String
getFundName
()
{
return
fundName
;
}
public
void
setFundName
(
String
fundName
)
{
this
.
fundName
=
fundName
;
}
public
String
getStartEndDate
()
{
return
startEndDate
;
}
public
void
setStartEndDate
(
String
startEndDate
)
{
this
.
startEndDate
=
startEndDate
;
}
public
Date
getCreateTime
()
{
return
createTime
;
}
public
void
setCreateTime
(
Date
createTime
)
{
this
.
createTime
=
createTime
;
}
public
Date
getUpdateTime
()
{
return
updateTime
;
}
public
void
setUpdateTime
(
Date
updateTime
)
{
this
.
updateTime
=
updateTime
;
}
public
Integer
getDeleteTag
()
{
return
deleteTag
;
}
public
void
setDeleteTag
(
Integer
deleteTag
)
{
this
.
deleteTag
=
deleteTag
;
}
public
String
getIfaId
()
{
return
ifaId
;
}
public
void
setIfaId
(
String
ifaId
)
{
this
.
ifaId
=
ifaId
;
}
public
String
getOrgId
()
{
return
orgId
;
}
public
void
setOrgId
(
String
orgId
)
{
this
.
orgId
=
orgId
;
}
public
String
getSummary
()
{
return
summary
;
}
public
void
setSummary
(
String
summary
)
{
this
.
summary
=
summary
;
}
public
String
getDetail
()
{
return
detail
;
}
public
void
setDetail
(
String
detail
)
{
this
.
detail
=
detail
;
}
public
String
getFundFile
()
{
return
fundFile
;
}
public
void
setFundFile
(
String
fundFile
)
{
this
.
fundFile
=
fundFile
;
}
public
String
getFundPng
()
{
return
fundPng
;
}
public
void
setFundPng
(
String
fundPng
)
{
this
.
fundPng
=
fundPng
;
}
}
\ No newline at end of file
src/main/java/com/tanpu/fund/entity/generator/IfaImportedNonavFundExample.java
View file @
385f0d7b
This diff is collapsed.
Click to expand it.
src/main/java/com/tanpu/fund/mapper/generator/IfaImportedNonavFundMapper.java
View file @
385f0d7b
...
@@ -6,70 +6,50 @@ import java.util.List;
...
@@ -6,70 +6,50 @@ import java.util.List;
import
org.apache.ibatis.annotations.Mapper
;
import
org.apache.ibatis.annotations.Mapper
;
import
org.apache.ibatis.annotations.Param
;
import
org.apache.ibatis.annotations.Param
;
/**
* @author: zhoupeng
* <p>
* =========================================
* =========================================
* ======== ========
* ======= ========== ======= =======
* ====== ===== == ==== ======
* ===== ===== == === =====
* ===== ===== == === =====
* ===== ===== == === =====
* ====== ========== == ======
* ======= =======
* =========================================
* =========================================
* <p>
* @email: zhoupeng_08@163.com
*/
@Mapper
@Mapper
public
interface
IfaImportedNonavFundMapper
{
public
interface
IfaImportedNonavFundMapper
{
long
countByExample
(
IfaImportedNonavFundExample
example
);
long
countByExample
(
IfaImportedNonavFundExample
example
);
int
deleteByExample
(
IfaImportedNonavFundExample
example
);
int
deleteByExample
(
IfaImportedNonavFundExample
example
);
/**
* delete by primary key
* @param id primaryKey
* @return deleteCount
*/
int
deleteByPrimaryKey
(
String
id
);
int
deleteByPrimaryKey
(
String
id
);
/**
* insert record to table
* @param record the record
* @return insert count
*/
int
insert
(
IfaImportedNonavFund
record
);
int
insert
(
IfaImportedNonavFund
record
);
int
insertOrUpdate
(
IfaImportedNonavFund
record
);
int
insertOrUpdate
(
IfaImportedNonavFund
record
);
int
insertOrUpdateSelective
(
IfaImportedNonavFund
record
);
int
insertOrUpdateSelective
(
IfaImportedNonavFund
record
);
int
insertOrUpdateWithBLOBs
(
IfaImportedNonavFund
record
);
/**
* insert record to table selective
* @param record the record
* @return insert count
*/
int
insertSelective
(
IfaImportedNonavFund
record
);
int
insertSelective
(
IfaImportedNonavFund
record
);
List
<
IfaImportedNonavFund
>
selectByExampleWithBLOBs
(
IfaImportedNonavFundExample
example
);
List
<
IfaImportedNonavFund
>
selectByExample
(
IfaImportedNonavFundExample
example
);
List
<
IfaImportedNonavFund
>
selectByExample
(
IfaImportedNonavFundExample
example
);
/**
* select by primary key
* @param id primary key
* @return object by primary key
*/
IfaImportedNonavFund
selectByPrimaryKey
(
String
id
);
IfaImportedNonavFund
selectByPrimaryKey
(
String
id
);
int
updateByExampleSelective
(
@Param
(
"record"
)
IfaImportedNonavFund
record
,
@Param
(
"example"
)
IfaImportedNonavFundExample
example
);
int
updateByExampleSelective
(
@Param
(
"record"
)
IfaImportedNonavFund
record
,
@Param
(
"example"
)
IfaImportedNonavFundExample
example
);
int
updateByExampleWithBLOBs
(
@Param
(
"record"
)
IfaImportedNonavFund
record
,
@Param
(
"example"
)
IfaImportedNonavFundExample
example
);
int
updateByExample
(
@Param
(
"record"
)
IfaImportedNonavFund
record
,
@Param
(
"example"
)
IfaImportedNonavFundExample
example
);
int
updateByExample
(
@Param
(
"record"
)
IfaImportedNonavFund
record
,
@Param
(
"example"
)
IfaImportedNonavFundExample
example
);
/**
* update record selective
* @param record the updated record
* @return update count
*/
int
updateByPrimaryKeySelective
(
IfaImportedNonavFund
record
);
int
updateByPrimaryKeySelective
(
IfaImportedNonavFund
record
);
int
updateByPrimaryKeyWithBLOBs
(
IfaImportedNonavFund
record
);
/**
* update record
* @param record the updated record
* @return update count
*/
int
updateByPrimaryKey
(
IfaImportedNonavFund
record
);
int
updateByPrimaryKey
(
IfaImportedNonavFund
record
);
int
updateBatch
(
List
<
IfaImportedNonavFund
>
list
);
int
updateBatch
(
List
<
IfaImportedNonavFund
>
list
);
...
@@ -77,4 +57,4 @@ public interface IfaImportedNonavFundMapper {
...
@@ -77,4 +57,4 @@ public interface IfaImportedNonavFundMapper {
int
updateBatchSelective
(
List
<
IfaImportedNonavFund
>
list
);
int
updateBatchSelective
(
List
<
IfaImportedNonavFund
>
list
);
int
batchInsert
(
@Param
(
"list"
)
List
<
IfaImportedNonavFund
>
list
);
int
batchInsert
(
@Param
(
"list"
)
List
<
IfaImportedNonavFund
>
list
);
}
}
\ No newline at end of file
src/main/java/com/tanpu/fund/service/ProductService.java
View file @
385f0d7b
...
@@ -38,6 +38,7 @@ public interface ProductService {
...
@@ -38,6 +38,7 @@ public interface ProductService {
Page
<
NetVO
>
getNetList
(
NetReq
req
);
Page
<
NetVO
>
getNetList
(
NetReq
req
);
List
<
BonusRatioVO
>
getBonusRatio
(
String
id
);
List
<
BonusRatioVO
>
getBonusRatio
(
String
id
);
List
<
TrackRecordVO
>
getTrackRecord
(
String
id
);
List
<
TrackRecordVO
>
getTrackRecord
(
String
id
);
...
@@ -68,6 +69,8 @@ public interface ProductService {
...
@@ -68,6 +69,8 @@ public interface ProductService {
List
<
ProductInfoVO
>
getPrivateFundList
(
List
<
String
>
ids
);
List
<
ProductInfoVO
>
getPrivateFundList
(
List
<
String
>
ids
);
List
<
ProductInfoVO
>
getProductListNotNet
(
List
<
String
>
ids
);
List
<
FundInfoSimpleListResp
>
getSimpleList
(
List
<
String
>
idList
);
List
<
FundInfoSimpleListResp
>
getSimpleList
(
List
<
String
>
idList
);
List
<
FundInfoSimpleListResp
>
getPrivateSimpleList
(
List
<
String
>
idList
);
List
<
FundInfoSimpleListResp
>
getPrivateSimpleList
(
List
<
String
>
idList
);
...
...
src/main/java/com/tanpu/fund/service/impl/ProductServiceImpl.java
View file @
385f0d7b
package
com
.
tanpu
.
fund
.
service
.
impl
;
package
com
.
tanpu
.
fund
.
service
.
impl
;
import
cn.hutool.core.collection.CollUtil
;
import
cn.hutool.core.date.DateField
;
import
cn.hutool.core.date.DateField
;
import
cn.hutool.core.date.DatePattern
;
import
cn.hutool.core.date.DatePattern
;
import
cn.hutool.core.date.DateTime
;
import
cn.hutool.core.date.DateTime
;
...
@@ -122,6 +123,9 @@ public class ProductServiceImpl implements ProductService, Constant {
...
@@ -122,6 +123,9 @@ public class ProductServiceImpl implements ProductService, Constant {
@Resource
@Resource
private
FeignForProduct
product
;
private
FeignForProduct
product
;
@Resource
private
IfaImportedNonavFundMapper
ifaImportedNonavFundMapper
;
@Override
@Override
public
Page
<
ProductInfoVO
>
getProductList
(
ProductInfoReq
req
)
{
public
Page
<
ProductInfoVO
>
getProductList
(
ProductInfoReq
req
)
{
...
@@ -1555,6 +1559,25 @@ public class ProductServiceImpl implements ProductService, Constant {
...
@@ -1555,6 +1559,25 @@ public class ProductServiceImpl implements ProductService, Constant {
multiply100
(
fundCount
.
getStddevIncep
()),
multiply100
(
fundCount
.
getSharperatioIncep
()),
multiply100
(
fundCount
.
getRetIncepA
())));
multiply100
(
fundCount
.
getStddevIncep
()),
multiply100
(
fundCount
.
getSharperatioIncep
()),
multiply100
(
fundCount
.
getRetIncepA
())));
}
}
@Override
public
List
<
ProductInfoVO
>
getProductListNotNet
(
List
<
String
>
ids
)
{
IfaImportedNonavFundExample
example
=
new
IfaImportedNonavFundExample
();
example
.
createCriteria
().
andIdIn
(
ids
).
andDeleteTagEqualTo
(
0
);
List
<
IfaImportedNonavFund
>
ifaImportedNonavFunds
=
this
.
ifaImportedNonavFundMapper
.
selectByExample
(
example
);
if
(
CollUtil
.
isEmpty
(
ifaImportedNonavFunds
))
{
return
new
ArrayList
<>(
0
);
}
return
ifaImportedNonavFunds
.
stream
().
map
(
ls
->
{
ProductInfoVO
vo
=
new
ProductInfoVO
();
vo
.
setFundId
(
ls
.
getId
());
vo
.
setProductType
(
4
);
vo
.
setFundName
(
ls
.
getFundName
());
vo
.
setProductName
(
ls
.
getFundName
());
vo
.
setFundFile
(
ls
.
getFundFile
());
return
vo
;
}).
collect
(
Collectors
.
toList
());
}
@Override
@Override
public
List
<
ProductInfoVO
>
getPrivateFundList
(
List
<
String
>
ids
)
{
public
List
<
ProductInfoVO
>
getPrivateFundList
(
List
<
String
>
ids
)
{
...
...
src/main/resources/mybatis/generator/IfaImportedNonavFundMapper.xml
View file @
385f0d7b
This diff is collapsed.
Click to expand it.
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