...
|
...
|
@@ -3,6 +3,7 @@ package dao |
|
|
import (
|
|
|
"fmt"
|
|
|
|
|
|
"github.com/go-pg/pg/v10"
|
|
|
pgTransaction "github.com/linmadan/egglib-go/transaction/pg"
|
|
|
)
|
|
|
|
...
|
...
|
@@ -64,7 +65,7 @@ func (d *BoardShowDao) OnDutyCount(companyId int, orgId int, workshopId int) (in |
|
|
and sign_in>to_date(to_char(now(), 'YYYY-MM-DD'),'YYYY-MM-DD')`
|
|
|
var cnt int
|
|
|
tx := d.transactionContext.PgTx
|
|
|
_, err := tx.QueryOne(&cnt, sqlStr, companyId, orgId, workshopId)
|
|
|
_, err := tx.QueryOne(pg.Scan(&cnt), sqlStr, companyId, orgId, workshopId)
|
|
|
return cnt, err
|
|
|
}
|
|
|
|
...
|
...
|
@@ -349,7 +350,7 @@ func (d *BoardShowDao) WorkshopPlanCompletionCurrent(companyId int, orgId int, w |
|
|
}
|
|
|
var result string
|
|
|
tx := d.transactionContext.PgTx
|
|
|
_, err := tx.QueryOne(&result, sqlStr, condition...)
|
|
|
_, err := tx.QueryOne(pg.Scan(&result), sqlStr, condition...)
|
|
|
return result, err
|
|
|
}
|
|
|
|
...
|
...
|
|