|
@@ -842,9 +842,9 @@ func RefreshUserYearTable(pageStartTime time.Time, pageEndTime time.Time) { |
|
|
repoInfo := getRepoDetailInfo(DetailInfoMap, dateRecordAll.ID, MostDownloadMap) |
|
|
repoInfo := getRepoDetailInfo(DetailInfoMap, dateRecordAll.ID, MostDownloadMap) |
|
|
dataSetInfo, datasetscore := getDataSetInfo(dateRecordAll.ID, CreatedDataset, dataSetDownloadMap, CommitDatasetNumMap, CollectedDataset) |
|
|
dataSetInfo, datasetscore := getDataSetInfo(dateRecordAll.ID, CreatedDataset, dataSetDownloadMap, CommitDatasetNumMap, CollectedDataset) |
|
|
scoreMap["datasetscore"] = datasetscore |
|
|
scoreMap["datasetscore"] = datasetscore |
|
|
codeInfo, codescore := getCodeInfo(dateRecordAll) |
|
|
|
|
|
|
|
|
codeInfo, codescore := getCodeInfo(&dateRecordAll) |
|
|
scoreMap["codescore"] = codescore |
|
|
scoreMap["codescore"] = codescore |
|
|
cloudBrainInfo := getCloudBrainInfo(dateRecordAll, CloudBrainTaskItemMap, scoreMap) |
|
|
|
|
|
|
|
|
cloudBrainInfo := getCloudBrainInfo(&dateRecordAll, CloudBrainTaskItemMap, scoreMap) |
|
|
playARoll := getPlayARoll(bonusMap, dateRecordAll.Name, scoreMap) |
|
|
playARoll := getPlayARoll(bonusMap, dateRecordAll.Name, scoreMap) |
|
|
re := &UserSummaryCurrentYear{ |
|
|
re := &UserSummaryCurrentYear{ |
|
|
ID: dateRecordAll.ID, |
|
|
ID: dateRecordAll.ID, |
|
@@ -1028,7 +1028,7 @@ func getPlayARoll(bonusMap map[string]map[string]int, userName string, scoreMap |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
func getCloudBrainInfo(dateRecordAll UserBusinessAnalysisAll, CloudBrainTaskItemMap map[string]int, scoreMap map[string]float64) string { |
|
|
|
|
|
|
|
|
func getCloudBrainInfo(dateRecordAll *UserBusinessAnalysisAll, CloudBrainTaskItemMap map[string]int, scoreMap map[string]float64) string { |
|
|
trainscore := 0.0 |
|
|
trainscore := 0.0 |
|
|
debugscore := 0.0 |
|
|
debugscore := 0.0 |
|
|
runtime := 0.0 |
|
|
runtime := 0.0 |
|
@@ -1063,7 +1063,7 @@ func getCloudBrainInfo(dateRecordAll UserBusinessAnalysisAll, CloudBrainTaskItem |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
func getCodeInfo(dateRecordAll UserBusinessAnalysisAll) (string, float64) { |
|
|
|
|
|
|
|
|
func getCodeInfo(dateRecordAll *UserBusinessAnalysisAll) (string, float64) { |
|
|
if dateRecordAll.CommitCount > 0 { |
|
|
if dateRecordAll.CommitCount > 0 { |
|
|
codeInfo := make(map[string]string) |
|
|
codeInfo := make(map[string]string) |
|
|
codeInfo["commit_count"] = fmt.Sprint(dateRecordAll.CommitCount) |
|
|
codeInfo["commit_count"] = fmt.Sprint(dateRecordAll.CommitCount) |
|
|