正在显示
1 个修改的文件
包含
3 行增加
和
1 行删除
@@ -12,6 +12,7 @@ import ( | @@ -12,6 +12,7 @@ import ( | ||
12 | "oppmg/utils/signature" | 12 | "oppmg/utils/signature" |
13 | "strconv" | 13 | "strconv" |
14 | "strings" | 14 | "strings" |
15 | + "time" | ||
15 | 16 | ||
16 | "github.com/astaxie/beego/orm" | 17 | "github.com/astaxie/beego/orm" |
17 | ) | 18 | ) |
@@ -22,7 +23,7 @@ func GetAuditListForExcel(param protocol.RequestAuditList, companyid int64, user | @@ -22,7 +23,7 @@ func GetAuditListForExcel(param protocol.RequestAuditList, companyid int64, user | ||
22 | log.Error("GetUserCompanyBy(userid, companyid) err:%s", err) | 23 | log.Error("GetUserCompanyBy(userid, companyid) err:%s", err) |
23 | return nil, nil | 24 | return nil, nil |
24 | } | 25 | } |
25 | - | 26 | + queryBegin := time.Now() |
26 | _, datasql, cond := GetAuditListSql(param, companyid, userid, usercompany.Id) | 27 | _, datasql, cond := GetAuditListSql(param, companyid, userid, usercompany.Id) |
27 | var soureData []orm.Params | 28 | var soureData []orm.Params |
28 | err = utils.ExecuteQueryValue(&soureData, datasql, cond...) | 29 | err = utils.ExecuteQueryValue(&soureData, datasql, cond...) |
@@ -31,6 +32,7 @@ func GetAuditListForExcel(param protocol.RequestAuditList, companyid int64, user | @@ -31,6 +32,7 @@ func GetAuditListForExcel(param protocol.RequestAuditList, companyid int64, user | ||
31 | return nil, nil | 32 | return nil, nil |
32 | } | 33 | } |
33 | 34 | ||
35 | + log.Debug("查询耗时:%d 毫秒,数据量:%d", time.Since(queryBegin).Milliseconds(), len(soureData)) | ||
34 | // SELECT a.id,a.department_id,a.audit_template_id,a.chance_type_id | 36 | // SELECT a.id,a.department_id,a.audit_template_id,a.chance_type_id |
35 | // ,a.publish_status,a.create_at,a.review_status,a.status | 37 | // ,a.publish_status,a.create_at,a.review_status,a.status |
36 | // ,a.discovery_score,a.comment_total ,a.code,d.nick_name,d.id as user_id | 38 | // ,a.discovery_score,a.comment_total ,a.code,d.nick_name,d.id as user_id |
-
请 注册 或 登录 后发表评论