realname
This commit is contained in:
parent
ced1ff01cc
commit
7b150b4436
|
@ -36,6 +36,7 @@ type SyncCheckin struct {
|
|||
type Checkin struct {
|
||||
Id string `json:"id"`
|
||||
Username string `json:"username"`
|
||||
Realname string `json:"realname"`
|
||||
Day string `json:"day"`
|
||||
Month string `json:"month"`
|
||||
Exception string `json:"exception"`
|
||||
|
|
|
@ -20,7 +20,12 @@ func (c *Checkin) List(sess *session.AdminSession, req *api.ListCheckin) (int64,
|
|||
items := make([]*api.Checkin, 0)
|
||||
for _, checkin := range checkts {
|
||||
ch := new(api.Checkin)
|
||||
|
||||
ch.From(checkin)
|
||||
user, _ := dao.NewStaffUserDao().GetByUsername(checkin.CorpId, checkin.Username)
|
||||
if user != nil {
|
||||
ch.Realname = user.Realname
|
||||
}
|
||||
items = append(items, ch)
|
||||
}
|
||||
return total, items
|
||||
|
|
Loading…
Reference in New Issue