...
|
...
|
@@ -52,19 +52,13 @@ func (ptr *CooperationStatisticsService) cooperationCompanyStatistics(userBaseId |
|
|
|
|
|
// 2.相关合约统计
|
|
|
cooperationContractRelevantRepository, _ := repository.NewCooperationContractUndertakerRepository(ptr.transactionContext)
|
|
|
cooperationContractCount, _, err := cooperationContractRelevantRepository.Find(map[string]interface{}{"userBaseId": userBaseId,
|
|
|
cooperationContractCount, _, err := cooperationContractRelevantRepository.Find(map[string]interface{}{"userBaseId": userBaseId, "orgId": orgId,
|
|
|
"limit": 1})
|
|
|
if err != nil {
|
|
|
return nil, err
|
|
|
}
|
|
|
|
|
|
// 3.个人分红统计
|
|
|
type response struct {
|
|
|
Total float64 `json:"total"`
|
|
|
Accounting float64 `json:"accounting"`
|
|
|
Accounted float64 `json:"accounted"`
|
|
|
Paid float64 `json:"paid"`
|
|
|
}
|
|
|
creditAccountDao, _ := dao.NewCreditAccountDao(ptr.transactionContext)
|
|
|
var allDividends = &CreditAccountStatisticsResponse{}
|
|
|
if err := creditAccountDao.DividendsStatistics(map[string]interface{}{"userBaseId": userBaseId, "orgId": orgId}, allDividends); err != nil {
|
...
|
...
|
|