From 812040e296e15d0637296dfec2baf1d38ccd3cb3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marko=20Tikvi=C4=87?= Date: Mon, 3 Oct 2016 11:40:57 +0200 Subject: [PATCH] hmmm --- list_config.go | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/list_config.go b/list_config.go index 366674c..7810bbb 100644 --- a/list_config.go +++ b/list_config.go @@ -12,6 +12,7 @@ type ListOptions struct { PageSize uint64 `json:"pageSize"` Pivot bool `json:"pivot"` Detail bool `json:"detail"` + Total bool `json:"total"` } type ListFilter struct { @@ -463,12 +464,12 @@ func getListOptions(db *ora.Ses, objType string) (ListOptions, error) { var stmt *ora.Stmt query := `SELECT GLOBAL_FILTER, LOCAL_FILTER, REMOTE_FILTER, PAGINATION, - PAGE_SIZE, PIVOT, DETAIL + PAGE_SIZE, PIVOT, DETAIL, TOTAL FROM LIST_CONFIG WHERE OBJECT_TYPE = '` + objType + `'` stmt, err = db.Prep(query, ora.U32, ora.U32, ora.U32, ora.U32, - ora.U64, ora.U64, ora.U32) + ora.U64, ora.U64, ora.U32, ora.U32) if err != nil { return ListOptions{}, err } @@ -486,6 +487,7 @@ func getListOptions(db *ora.Ses, objType string) (ListOptions, error) { resp.PageSize = rset.Row[4].(uint64) resp.Pivot = rset.Row[5].(uint64) != 0 resp.Detail = rset.Row[6].(uint32) != 0 + resp.Total = rset.Row[7].(uint32) != 0 } if rset.Err != nil { return ListOptions{}, rset.Err -- 1.8.1.2