作者 tangxvhui

修复bug 部门下的人员

@@ -55,6 +55,7 @@ func addAchievementChance(addData []protocol.AchievementChance, achievementId in @@ -55,6 +55,7 @@ func addAchievementChance(addData []protocol.AchievementChance, achievementId in
55 return err 55 return err
56 } 56 }
57 57
  58 +//计算剩余的分数
58 func achievementGraspScoreRemain(graspScore, userGraspScore, providerScoreAll float64) float64 { 59 func achievementGraspScoreRemain(graspScore, userGraspScore, providerScoreAll float64) float64 {
59 return graspScore - userGraspScore - providerScoreAll 60 return graspScore - userGraspScore - providerScoreAll
60 } 61 }
@@ -388,8 +388,8 @@ func GetDepartmentUser(companyid int64, departmentid int64) ([]protocol.DepartUs @@ -388,8 +388,8 @@ func GetDepartmentUser(companyid int64, departmentid int64) ([]protocol.DepartUs
388 } 388 }
389 const dataSql string = `SELECT a.user_company_id,b.user_id 389 const dataSql string = `SELECT a.user_company_id,b.user_id
390 FROM user_department AS a 390 FROM user_department AS a
391 - LEFT JOIN user_company AS b ON a.user_company_id = b.id  
392 - WHERE a.department_id=? AND b.delete_at=0 AND a.enable_status = 1 ` 391 + JOIN user_company AS b ON a.user_company_id = b.id
  392 + WHERE a.department_id=? AND b.delete_at=0 AND a.enable_status = 1 AND b.enable = 1 `
393 393
394 err = utils.ExecuteQueryAll(&returnData, dataSql, department.Id) 394 err = utils.ExecuteQueryAll(&returnData, dataSql, department.Id)
395 if err != nil { 395 if err != nil {