Skip to content

Instantly share code, notes, and snippets.

@novalagung
Last active April 8, 2018 01:50
Show Gist options
  • Save novalagung/c53e13d609732a82f99cf8a812bfc6cc to your computer and use it in GitHub Desktop.
Save novalagung/c53e13d609732a82f99cf8a812bfc6cc to your computer and use it in GitHub Desktop.

mas Wishnu

1. list semua menu yg ada, masukkan ke collection menu (hari ini)
2. buat back end untuk user (sudah ada, sesuaikan aja jika perlu)
3. buat back end untuk roles

mas Sarif

1. siapkan UI untuk user (mulai ngerjakan ini)
2. roles
3. menu (grid & tree)
type UserMaster struct {
	Id           string `bson:"_id",json:"_id"`           // autogenerated
	UserName     string `bson:"UserName",json:"UserName"` // unique
	FullName     string `bson:"FullName",json:"FullName"`
	Email        string `bson:"Email",json:"Email"`       // unique
	Departement  string `bson:"Departement",json:"Departement"`
	Status       int    `bson:"Status",json:"Status"`
	PasswordHash string `bson:"PasswordHash",json:"PasswordHash"`
	Roles        string `bson:"Roles",json:"Roles"`

    CreateBy     string    `bson:"createBy",json:"createBy"`
	CreateTime   time.Time `bson:"createTime",json:"createTime"`
	UpdateBy     string    `bson:"updateBy",json:"updateBy"`
	UpdateTime   time.Time `bson:"updateTime",json:"updateTime"`
}

type RoleData struct {
	Id         string       `bson:"_id",json:"_id"` // autogenerated
	NameRole   string       `bson:"nameRole",json:"nameRole"`
    Menu       []string     `bson:"menu",json:"menu"`

	CreateBy   string       `bson:"createBy",json:"createBy"`
	CreateTime time.Time    `bson:"createTime",json:"createTime"`
	UpdateBy   string       `bson:"updateBy",json:"updateBy"`
	UpdateTime time.Time    `bson:"updateTime",json:"updateTime"`
}

type MenuMaster struct {
	Id          string `bson:"idFolder",json:"idFolder"`
	Name        string `bson:"titleFolder",json:"titleFolder"`
	URL         bool   `bson:"delData",json:"delData"`
	ParentId    string `bson:"parentId",json:"parentId"`
	OrderIndex  bool   `bson:"edData",json:"edData"`
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment