gocore

package
v0.0.0-...-9e67cea Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 26, 2016 License: Apache-2.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

View Source
const (
	CONF_DB_ACL  string = "db_acl"
	CONF_DB_GDRJ string = "db_godrej"
)

Variables

View Source
var ConfigPath string

Functions

func Authenticate

func Authenticate(payload toolkit.M) (toolkit.M, error)

func ChangePass

func ChangePass(payload toolkit.M) error

func Delete

func Delete(o orm.IModel) error

func DeleteAccess

func DeleteAccess(payload toolkit.M) error

func DeleteGroup

func DeleteGroup(payload toolkit.M) error

func DeleteUser

func DeleteUser(payload toolkit.M) error

func EditGroup

func EditGroup(payload toolkit.M) (toolkit.M, error)

func EditUser

func EditUser(payload toolkit.M) (toolkit.M, error)

func FilterParse

func FilterParse(where toolkit.M) *dbox.Filter

func Find

func Find(o orm.IModel, filter *dbox.Filter) (dbox.ICursor, error)

func FindAccess

func FindAccess(payload toolkit.M) (toolkit.M, error)

func Get

func Get(o orm.IModel, id interface{}) error

func GetAccess

func GetAccess(payload toolkit.M) (toolkit.M, error)

func GetAccessGroup

func GetAccessGroup(payload toolkit.M) ([]interface{}, error)

func GetAccessMenu

func GetAccessMenu(sessionId interface{}) ([]toolkit.M, error)

func GetAccessUser

func GetAccessUser(payload toolkit.M) ([]interface{}, error)

func GetChildMenu

func GetChildMenu(sessionId interface{}, childMenu []Menu) (interface{}, error)

func GetConfig

func GetConfig(key string, args ...string) interface{}

func GetDB

func GetDB(key string) interface{}

func GetFileList

func GetFileList(search toolkit.M) ([]gdrj.UploadData, error)

func GetGroup

func GetGroup() ([]toolkit.M, error)

func GetSession

func GetSession(payload toolkit.M) (toolkit.M, error)

func GetTableList

func GetTableList() (toolkit.Ms, error)

func GetUser

func GetUser(payload toolkit.M) (toolkit.M, error)

func GetUserName

func GetUserName(sessionId interface{}) (tUser acl.User, err error)

func Getaccessdropdown

func Getaccessdropdown() ([]toolkit.M, error)

func InitialSetDatabase

func InitialSetDatabase() error

func LoginProcess

func LoginProcess(payload toolkit.M) (string, error)

func PrepareDefaultUser

func PrepareDefaultUser() (err error)

func Query

func Query(driver string, host string, other ...interface{}) *queryWrapper

func ResetPassword

func ResetPassword(payload toolkit.M) error

func Save

func Save(o orm.IModel) error

func SaveAccess

func SaveAccess(payload toolkit.M) error

func SaveGroup

func SaveGroup(payload toolkit.M) error

func SavePassword

func SavePassword(payload toolkit.M) error

func SaveUser

func SaveUser(payload toolkit.M) error

func SearchGroup

func SearchGroup(payload toolkit.M) (toolkit.M, error)

func SetConfig

func SetConfig(key string, value interface{})

func SetDB

func SetDB(value interface{})

func SetExpired

func SetExpired(payload toolkit.M) error

func SetPort

func SetPort(_port *Ports, value interface{}) error

Types

type Configuration

type Configuration struct {
	orm.ModelBase
	ID    string `json:"_id",bson:"_id"`
	Value interface{}
}

func (*Configuration) RecordID

func (a *Configuration) RecordID() interface{}

func (*Configuration) TableName

func (a *Configuration) TableName() string

type DataBrowser

type DataBrowser struct {
	orm.ModelBase
	ID         string `json:"_id",bson:"_id"`
	TableNames string
	IsAdd      bool
	IsEdit     bool
	MetaData   []*StructInfo
}

func ConnectToDatabase

func ConnectToDatabase(payload toolkit.M) (int, []toolkit.M, *DataBrowser, error)

func GetDataBrowserList

func GetDataBrowserList() ([]DataBrowser, error)

func (*DataBrowser) RecordID

func (b *DataBrowser) RecordID() interface{}

func (*DataBrowser) TableName

func (b *DataBrowser) TableName() string

type Databases

type Databases struct {
	orm.ModelBase
	ID   string      `json:"_id",bson:"_id"`
	Data interface{} `json:"data",bson:"data"`
}

func (*Databases) RecordID

func (a *Databases) RecordID() interface{}

func (*Databases) TableName

func (a *Databases) TableName() string

type Login

type Login struct {
	orm.ModelBase
	ID       string `json:"_id",bson:"_id"`
	Password string
	Salt     string
}

func (*Login) GetConnectionInfo

func (l *Login) GetConnectionInfo(db_type string) (string, *dbox.ConnectionInfo)

func (*Login) RecordID

func (l *Login) RecordID() interface{}

func (*Login) TableName

func (l *Login) TableName() string
type Menu struct {
	orm.ModelBase
	ID string `json:"_id",bson:"_id"`

	AccessId  string `json:"AccessId",bson:"AccessId"`
	Title     string `json:"title",bson:"title"`
	Childrens []Menu `json:"childrens",bson:"childrens"`
	Link      string `json:"link",bson:"link"`
}
func (a *Menu) RecordID() interface{}
func (a *Menu) TableName() string

type MetaSave

type MetaSave struct {
	// contains filtered or unexported fields
}

type Ports

type Ports struct {
	orm.ModelBase
	ID   string `json:"_id",bson:"_id"`
	Port int    `json:"port",bson:"port"`
}

func (*Ports) GetPort

func (p *Ports) GetPort() error

func (*Ports) RecordID

func (p *Ports) RecordID() interface{}

func (*Ports) TableName

func (p *Ports) TableName() string

type StructInfo

type StructInfo struct {
	Field         string
	Label         string
	DataType      string
	Format        string
	Align         string
	ShowIndex     int
	HiddenField   bool
	Lookup        bool
	Sortable      bool
	SimpleFilter  bool
	AdvanceFilter bool
	Aggregate     string
	IsAdd         bool
	IsEdit        bool
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL