houyaf vor 3 Jahren
Ursprung
Commit
ea81b18663

+ 37 - 11
repositories/oc_repo.go

@@ -51,13 +51,16 @@ func (d *OcRepo) GetPage(m map[string]interface{})(*viewmodels.PageResult, error
 	limit     := m["limit"].(int)
 	page      := m["page"].(int)
 	
-	sqlSelect := ` SELECT  A.oc_id,
+	sqlSelect := ` SELECT   A.oc_id,
 							A.oc_name,
 							A.oc_type_id,
+                            B.oc_type_title,
+                            A.oc_cat_id,
+                            C.oc_cat_title,
 							A.root_id,
 							A.parent_id,
 							A.admin_id,
-							B.account_name AS admin_name,
+							D.account_name AS admin_name,
 							A.group_id,
 							A.node_left,
 							A.node_right,
@@ -66,13 +69,23 @@ func (d *OcRepo) GetPage(m map[string]interface{})(*viewmodels.PageResult, error
 							A.status,
 							A.if_lic   `
 	sqlFrom  := ` FROM      oc       AS A
-                  LEFT JOIN account  AS B ON(A.oc_admin_id = B.account_id) `
+                  LEFT JOIN oc_type  AS B ON (A.oc_type_id = B.oc_type_id)
+                  LEFT JOIN oc_cat   AS C ON (A.oc_type_id = C.oc_type_id AND A.oc_cat_id = C.oc_cat_id)
+                  LEFT JOIN account  AS D ON (A.admin_id   = D.account_id) `
 	sqlWhere := ` WHERE A.deleted_flag = 0 `
 
 	if keywords, ok := m["keywords"]; ok {
 		sqlWhere += ` AND A.oc_name like ` + "'%" + fmt.Sprintf("%s", keywords) + "%'"
 	}
-
+	
+	if ocTypeId, ok := m["ocTypeId"]; ok {
+		sqlWhere += fmt.Sprintf(" AND A.oc_type_id = %d", ocTypeId)
+	}
+	
+	if ocCatId, ok := m["ocCatId"]; ok {
+		sqlWhere += fmt.Sprintf(" AND A.oc_cat_id = %d", ocCatId)
+	}
+	
 	sqlCount := ` SELECT COUNT(*)  `
 	total, err1 := d.engine.SQL(sqlCount + sqlFrom + sqlWhere).Count()
 	if err1 != nil {
@@ -80,7 +93,7 @@ func (d *OcRepo) GetPage(m map[string]interface{})(*viewmodels.PageResult, error
 	}
 
 	pageStart  := (page - 1) * limit
-	sqlOrderBy := " ORDER BY oc_id ASC "
+	sqlOrderBy := " ORDER BY A.oc_id "
 	sqlLimit   := fmt.Sprintf(" LIMIT %d OFFSET %d  ", limit, pageStart)
 	
 	datalist := make([]viewmodels.OcInfo, 0)
@@ -98,29 +111,42 @@ func (d *OcRepo) GetPage(m map[string]interface{})(*viewmodels.PageResult, error
 }
 
 func (d *OcRepo) GetList(m map[string]interface{})([]viewmodels.OcInfo, error) {
-	sqlSelect := `  SELECT  A.oc_id,
+	sqlSelect := ` SELECT   A.oc_id,
 							A.oc_name,
 							A.oc_type_id,
+                            B.oc_type_title,
+                            A.oc_cat_id,
+                            C.oc_cat_title,
 							A.root_id,
 							A.parent_id,
 							A.admin_id,
-							B.account_name AS admin_name,
+							D.account_name AS admin_name,
 							A.group_id,
 							A.node_left,
 							A.node_right,
 							A.node_level,
 							A.is_leaf,
 							A.status,
-							A.if_lic
-                  `
+							A.if_lic   `
 	sqlFrom  := ` FROM      oc       AS A
-                  LEFT JOIN account  AS B ON(A.oc_admin_id = B.account_id) `
+                  LEFT JOIN oc_type  AS B ON (A.oc_type_id = B.oc_type_id)
+                  LEFT JOIN oc_cat   AS C ON (A.oc_type_id = C.oc_type_id AND A.oc_cat_id = C.oc_cat_id)
+                  LEFT JOIN account  AS D ON (A.admin_id   = D.account_id) `
 	sqlWhere := ` WHERE A.deleted_flag = 0 `
 	
 	if keywords, ok := m["keywords"]; ok {
 		sqlWhere += ` AND   A.oc_name like ` + "'%" + fmt.Sprintf("%s", keywords) + "%'"
 	}
-	sqlOrderBy := " ORDER BY oc_id ASC "
+	
+	if ocTypeId, ok := m["ocTypeId"]; ok {
+		sqlWhere += fmt.Sprintf(" AND A.oc_type_id = %d", ocTypeId)
+	}
+	
+	if ocCatId, ok := m["ocCatId"]; ok {
+		sqlWhere += fmt.Sprintf(" AND A.oc_cat_id = %d", ocCatId)
+	}
+	
+	sqlOrderBy := " ORDER BY A.oc_id "
 	
 	datalist := make([]viewmodels.OcInfo, 0)
 	err := d.engine.SQL(sqlSelect + sqlFrom + sqlWhere + sqlOrderBy).Find(&datalist)

+ 8 - 3
repositories/oc_type_repo.go

@@ -60,7 +60,7 @@ func (d *OcTypeRepo) GetList(m map[string]interface{}) ([]viewmodels.OcTypeInfo,
     if keywords, ok := m["keywords"]; ok {
         sqlWhere += " AND A.oc_type_title like " + "'%" + fmt.Sprintf("%s", keywords) + "%'"
     }
-    sqlOrderBy := " ORDER BY oc_type_id DESC "
+    sqlOrderBy := " ORDER BY A.oc_type_id "
     
     datalist := make([]viewmodels.OcTypeInfo, 0)
     err := d.engine.SQL(sqlSelect + sqlFrom + sqlWhere + sqlOrderBy).Find(&datalist)
@@ -72,9 +72,14 @@ func (d *OcTypeRepo) GetList(m map[string]interface{}) ([]viewmodels.OcTypeInfo,
 }
 
 func (d *OcTypeRepo) GetById(ocTypeId int64) (*viewmodels.OcTypeInfo, error) {
+    sqlSelect := ` SELECT  A.*              `
+    sqlFrom   := ` FROM  oc_type   AS A     `
+    sqlWhere  := ` WHERE A.deleted_flag = 0 `
+    sqlWhere  += fmt.Sprintf(" AND A.oc_type_id = %d", ocTypeId)
+    
     data := &viewmodels.OcTypeInfo{}
-    ok, err := d.engine.Where("oc_type_id = ?", ocTypeId).Get(data)
-    if !ok || err != nil {
+    has, err := d.engine.SQL(sqlSelect + sqlFrom + sqlWhere).Get(data)
+    if !has || err != nil {
         return nil, err
     } else {
         return data, nil

+ 7 - 4
repositories/position_repo.go

@@ -75,11 +75,14 @@ func (d *PositionRepo) GetList(m map[string]interface{}) ([]viewmodels.PositionI
 }
 
 func (d *PositionRepo) GetById(ocId int64, positionId int64) (*viewmodels.PositionInfo, error) {
+	sqlSelect := ` SELECT A.* `
+	sqlFrom   := ` FROM   s_position AS A   `
+	sqlWhere  := fmt.Sprintf(` WHERE A.deleted_flag = 0 and A.oc_id = %d`, ocId)
+	sqlWhere  += fmt.Sprintf(" AND A.position_id = %d", positionId)
+	
 	data := &viewmodels.PositionInfo{}
-	data.OcId       = ocId
-	data.PositionId = positionId
-	ok, err := d.engine.Get(data)
-	if !ok || err != nil {
+	has, err := d.engine.SQL(sqlSelect + sqlFrom + sqlWhere).Get(data)
+	if !has || err != nil {
 		return nil, err
 	} else {
 		return data, nil

+ 14 - 2
repositories/role_repo.go

@@ -88,9 +88,21 @@ func (d *RoleRepo) GetList(m map[string]interface{}) ([]viewmodels.RoleInfo, err
 }
 
 func (d *RoleRepo) GetById(roleId int64) (*viewmodels.RoleInfo, error) {
+	sqlSelect := ` SELECT  A.role_id ,
+                           A.role_name,
+                           A.role_desc,
+                           A.role_type_id,
+                           B.role_type_title,
+                           A.sort_no,
+                           A.status,
+                           A.is_fixed `
+	sqlFrom := ` FROM      s_role       AS A
+                 LEFT JOIN s_role_type  AS B ON (A.role_type_id = B.role_type_id )`
+	sqlWhere := `WHERE A.deleted_flag = 0 `
+	sqlWhere += fmt.Sprintf(" AND A.role_id = %d ", roleId)
 	data := &viewmodels.RoleInfo{RoleId: roleId}
-	ok, err := d.engine.Get(data)
-	if !ok && err != nil {
+	has, err := d.engine.SQL(sqlSelect + sqlFrom + sqlWhere).Get(data)
+	if !has || err != nil {
 		return nil, err
 	} else {
 		return data, nil

+ 0 - 52
service/partner_cat_service.go

@@ -1,52 +0,0 @@
-package service
-
-import (
-    "xps/datamodels"
-    "xps/datasource"
-    "xps/repositories"
-    "xps/viewmodels"
-)
-
-type PartnerCatService interface {
-	GetList(m map[string]interface{}) ([]viewmodels.PartnerCatInfo, error)
-	GetPage(m map[string]interface{}) (*viewmodels.PageResult, error)
-	GetById(partnerCatId int64) (*viewmodels.PartnerCatInfo, error)
-	Create(d *datamodels.PartnerCat) error
-	Update(d *datamodels.PartnerCat) error
-	Delete(m map[string]interface{}) error
-}
-
-type partnerCatService struct {
-	repo *repositories.PartnerCatRepo
-}
-
-func NewPartnerCatService() PartnerCatService {
-	return &partnerCatService{
-		repo: repositories.NewPartnerCatRepo(datasource.InstanceMaster()),
-	}
-}
-
-func (s *partnerCatService) GetList(m map[string]interface{}) ([]viewmodels.PartnerCatInfo, error) {
-	return s.repo.GetList(m)
-}
-
-func (s *partnerCatService) GetPage(m map[string]interface{}) (*viewmodels.PageResult, error) {
-	return s.repo.GetPage(m)
-}
-
-func (s *partnerCatService) GetById(partnerCatId int64) (*viewmodels.PartnerCatInfo, error) {
-	return s.repo.GetById(partnerCatId)
-}
-
-func (s *partnerCatService) Create(PartnerCat *datamodels.PartnerCat) error {
-	PartnerCat.PartnerCatId = NewID()
-	return s.repo.Create(PartnerCat)
-}
-
-func (s *partnerCatService) Update(PartnerCat *datamodels.PartnerCat) error {
-	return s.repo.Update(PartnerCat)
-}
-
-func (s *partnerCatService) Delete(m map[string]interface{}) error {
-	return s.repo.Delete(m)
-}

+ 20 - 16
viewmodels/oc_info.go

@@ -2,21 +2,25 @@ package viewmodels
 
 // OcInfo Oc Info
 type OcInfo struct {
-	OcId      int64  `json:"ocId"          form:"ocTypeId"        xorm:"'oc_id'       bigint    pk  comment('主键ID')       " `
-	OcName    string `json:"ocName"        form:"ocName"          xorm:"'oc_name'     varchar(127)  comment('ENT类型名称')   " `
-	OcTypeId  int64  `json:"ocTypeId"      form:"ocTypeId"        xorm:"'oc_type_id'  bigint        comment('Type ID')      " `
-	OcCatId   int64  `json:"ocCatId"       form:"ocCatId"         xorm:"'oc_cat_id'   bigint        comment('Cat ID')       " `
-	
-	RootId    int64  `json:"rootId"        form:"rootId"          xorm:"'root_id'     bigint        comment('Root ID')      " `
-	ParentId  int64  `json:"parentId"      form:"parentId"        xorm:"'parent_id'   bigint        comment('Parent ID')    " `
-	AdminId   int64  `json:"adminId"       form:"adminId"         xorm:"'admin_id'    bigint        comment('Admin ID')     " `
-	AdminName string `json:"adminName"     form:"adminName"       xorm:"'admin_name'  varchar(127)  comment('Admin Name')   " `
-	GroupId   int64  `json:"groupId"       form:"groupId"         xorm:"'group_id'    bigint        comment('Root Group Id')" `
-	IfLic     int    `json:"ifLic"         form:"ifLic"           xorm:"'if_lic'      int           comment('Admin ID')     " `
+	OcId        int64   `json:"ocId"         xorm:"'oc_id'          bigint    pk  comment('主键ID')       " `
+	OcName      string  `json:"ocName"       xorm:"'oc_name'        varchar(127)  comment('ENT类型名称')   " `
+	OcTypeId    int64   `json:"ocTypeId"     xorm:"'oc_type_id'     bigint        comment('Type ID')      " `
+    OcTypeTitle string  `json:"ocTypeTitle"  xorm:"'oc_type_title'  varchar(50)   comment('群组类型名称')   " `
+	OcCatId     int64   `json:"ocCatId"      xorm:"'oc_cat_id'      bigint        comment('Cat ID')       " `
+	OcCatTitle  string  `json:"ocCatTitle"   xorm:"'oc_cat_title'   varchar(50)   comment('群组类型名称')   "`
+	RootId      int64   `json:"rootId"       xorm:"'root_id'        bigint        comment('Root ID')      " `
+	ParentId    int64   `json:"parentId"     xorm:"'parent_id'      bigint        comment('Parent ID')    " `
+	AdminId     int64   `json:"adminId"      xorm:"'admin_id'       bigint        comment('Admin ID')     " `
+	AdminName   string  `json:"adminName"    xorm:"'admin_name'     varchar(127)  comment('Admin Name')   " `
+	GroupId     int64   `json:"groupId"      xorm:"'group_id'       bigint        comment('Root Group Id')" `
+	IfLic       int     `json:"ifLic"        xorm:"'if_lic'         int           comment('Admin ID')     " `
+	NodeLeft    int     `json:"nodeLeft"     xorm:"'node_left'      int           comment('Admin ID')     " `
+	NodeRight   int     `json:"nodeRight"    xorm:"'node_right'     int           comment('Admin ID')     " `
+	IsLeaf      int     `json:"isLeaf"       xorm:"'is_leaf'        int           comment('Admin ID')     " `
+	NodeLevel   int     `json:"nodeLevel"    xorm:"'node_level'     int           comment('Admin ID')     " `
+	Status      int     `json:"status"       xorm:"'status'         int           comment('OC Status')    " `
+}
 
-	NodeLeft  int   `json:"nodeLeft"       form:"nodeLeft"        xorm:"'node_left'   int           comment('Admin ID')     " `
-	NodeRight int   `json:"nodeRight"      form:"nodeRight"       xorm:"'node_right'  int           comment('Admin ID')     " `
-	IsLeaf    int   `json:"isLeaf"         form:"isLeaf"          xorm:"'is_leaf'     int           comment('Admin ID')     " `
-	NodeLevel int   `json:"nodeLevel"      form:"nodeLevel"       xorm:"'node_level'  int           comment('Admin ID')     " `
-	Status    int   `json:"status"         form:"status"          xorm:"'status'      int           comment('OC Status')    " `
+func (t *OcInfo) TableName() string {
+	return "oc"
 }

+ 0 - 94
web/controllers/ent_cat_controller.go

@@ -1,94 +0,0 @@
-package controllers
-
-import (
-    "github.com/kataras/iris/v12/mvc"
-    "xps/datamodels"
-    "xps/service"
-)
-
-type EntCatController struct {
-	Base
-	Service service.EntCatService
-}
-
-func (c *EntCatController) BeforeActivation(b mvc.BeforeActivation) {
-	b.Handle("GET",         "/",                        "GetList"   )
-	b.Handle("GET",         "/page",                    "GetPage"   )
-	b.Handle("GET",         "/{entCatId:int64}",        "GetById"   )
-	b.Handle("POST",        "/add",                     "Create"    )
-	b.Handle("PUT",         "/update",                  "Update"    )
-	b.Handle("DELETE",      "/{entCatId:int64}",        "DeleteByID")
-}
-
-func (c *EntCatController) GetList() *JsonResult {
-	params    := c.buildParams()
-	data, err := c.Service.GetList(params)
-	if err != nil {
-		return ResultErr(err.Error(), nil)
-	} else {
-		return ResultOk("获取成功", data)
-	}
-}
-
-func (c *EntCatController) GetPage() *JsonResult {
-	params    := c.buildParams()
-	data, err := c.Service.GetPage(params)
-	if err != nil {
-		return ResultErr(err.Error(), nil)
-	} else {
-		return ResultOk("获取成功", data)
-	}
-}
-
-func (c *EntCatController) GetById(entCatId int64) *JsonResult {
-	data, err := c.Service.GetById(entCatId)
-	if err != nil {
-		return ResultErr(err.Error(), nil)
-	} else {
-		return ResultOk("获取成功", data)
-	}
-}
-
-func (c *EntCatController) Create() *JsonResult {
-	userId := c.GetCurUserId()
-	
-	entCat := datamodels.EntCat{}
-	entCat.CreatedBy = userId
-	if err := c.Ctx.ReadJSON(&entCat); err != nil {
-		return ResultErr("读取数据失败", nil)
-	}
-	
-	if err := c.Service.Create(&entCat); err != nil {
-		return ResultErr(err.Error(), nil)
-	} else {
-		return ResultOk("新增成功", nil)
-	}
-}
-
-func (c *EntCatController) Update() *JsonResult {
-	userId := c.GetCurUserId()
-	entCat := datamodels.EntCat{}
-	if err := c.Ctx.ReadJSON(&entCat); err != nil {
-		return ResultErr("读取数据失败", nil)
-	}
-
-	entCat.UpdatedBy = userId
-	if err := c.Service.Update(&entCat); err != nil {
-		return ResultErr(err.Error(), nil)
-	} else {
-		return ResultOk("更新成功", nil)
-	}
-}
-
-func (c *EntCatController) DeleteByID(entCatId int64) *JsonResult {
-	userId := c.GetCurUserId()
-	
-	m := make(map[string]interface{})
-	m["entCatId"]  = entCatId
-	m["deletedBy"] = userId
-	if err := c.Service.Delete(m); err != nil {
-		return ResultErr(err.Error(), nil)
-	} else {
-		return ResultOk("删除成功", nil)
-	}
-}

+ 18 - 0
web/controllers/oc_controller.go

@@ -22,6 +22,15 @@ func (c *OcController) BeforeActivation(b mvc.BeforeActivation) {
 
 func (c *OcController) GetList() *JsonResult {
     params    := c.buildParams()
+    ocTypeId := c.Ctx.URLParamInt64Default("ocTypeId", 0)
+    if ocTypeId > 0 {
+        params["ocTypeId"] = ocTypeId
+    }
+    
+    ocCatId := c.Ctx.URLParamInt64Default("ocCatId", 0)
+    if ocCatId > 0 {
+        params["ocCatId"] = ocCatId
+    }
     data, err := c.Service.GetList(params)
     if err != nil {
         return ResultErr(err.Error(), nil)
@@ -32,6 +41,15 @@ func (c *OcController) GetList() *JsonResult {
 
 func (c *OcController) GetPage() *JsonResult {
     params    := c.buildParams()
+    ocTypeId := c.Ctx.URLParamInt64Default("ocTypeId", 0)
+    if ocTypeId > 0 {
+        params["ocTypeId"] = ocTypeId
+    }
+    
+    ocCatId := c.Ctx.URLParamInt64Default("ocCatId", 0)
+    if ocCatId > 0 {
+        params["ocCatId"] = ocCatId
+    }
     data, err := c.Service.GetPage(params)
     if err != nil {
         return ResultErr(err.Error(), nil)

+ 0 - 95
web/controllers/partner_cat_controller.go

@@ -1,95 +0,0 @@
-package controllers
-
-import (
-    "github.com/kataras/iris/v12/mvc"
-    "xps/datamodels"
-    "xps/service"
-)
-
-type PartnerCatController struct {
-	Base
-	Service service.PartnerCatService
-}
-
-func (c *PartnerCatController) BeforeActivation(b mvc.BeforeActivation) {
-	b.Handle("GET",         "/",                        "GetList"   )
-	b.Handle("GET",         "/page",                    "GetPage"   )
-	b.Handle("GET",         "/{partnerCatId:int64}",    "GetById"   )
-	b.Handle("POST",        "/add",                     "Create"    )
-	b.Handle("PUT",         "/update",                  "Update"    )
-	b.Handle("DELETE",      "/{partnerCatId:int64}",    "DeleteByID")
-}
-
-func (c *PartnerCatController) GetList() *JsonResult {
-	params    := c.buildParams()
-	data, err := c.Service.GetList(params)
-	if err != nil {
-		return ResultErr(err.Error(), nil)
-	} else {
-		return ResultOk("获取成功", data)
-	}
-}
-
-func (c *PartnerCatController) GetPage() *JsonResult {
-	params    := c.buildParams()
-	data, err := c.Service.GetPage(params)
-	if err != nil {
-		return ResultErr(err.Error(), nil)
-	} else {
-		return ResultOk("获取成功", data)
-	}
-}
-
-func (c *PartnerCatController) GetById(partnerCatId int64) *JsonResult {
-	data, err := c.Service.GetById(partnerCatId)
-	if err != nil {
-		return ResultErr(err.Error(), nil)
-	} else {
-		return ResultOk("获取成功", data)
-	}
-}
-
-func (c *PartnerCatController) Create() *JsonResult {
-	userId     := c.GetCurUserId()
-	
-	partnerCat := datamodels.PartnerCat{}
-	if err := c.Ctx.ReadJSON(&partnerCat); err != nil {
-		return ResultErr("读取数据失败", nil)
-	}
-	
-	partnerCat.CreatedBy = userId
-	if err := c.Service.Create(&partnerCat); err != nil {
-		return ResultErr(err.Error(), nil)
-	} else {
-		return ResultOk("新增成功", nil)
-	}
-}
-
-func (c *PartnerCatController) Update() *JsonResult {
-	userId     := c.GetCurUserId()
-	
-	partnerCat := datamodels.PartnerCat{}
-	if err := c.Ctx.ReadJSON(&partnerCat); err != nil {
-		return ResultErr("读取数据失败", nil)
-	}
-
-	partnerCat.UpdatedBy = userId
-	if err := c.Service.Update(&partnerCat); err != nil {
-		return ResultErr(err.Error(), nil)
-	} else {
-		return ResultOk("更新成功", nil)
-	}
-}
-
-func (c *PartnerCatController) DeleteByID(partnerCatId int64) *JsonResult {
-	userId := c.GetCurUserId()
-	
-	m := make(map[string]interface{})
-	m["partnerCatId"] = partnerCatId
-	m["deletedBy"] = userId
-	if err := c.Service.Delete(m); err != nil {
-		return ResultErr(err.Error(), nil)
-	} else {
-		return ResultOk("删除成功", nil)
-	}
-}

+ 19 - 18
web/router/routes.go

@@ -118,25 +118,26 @@ func Configure(b *bootstrap.Bootstrapper) {
 		taskCatApp.Register(taskCatService)
 		taskCatApp.Handle(new(controllers.TaskCatController))
 	}
-
-	// EntCat
-	entCatParty := b.Party("/ent", crs).AllowMethods(iris.MethodOptions)
-	{
-		entCatParty.Use(middleware.AuthToken)
-		entCatService := service.NewEntCatService()
-		entCatApp := mvc.New(entCatParty.Party("/cat"))
-		entCatApp.Register(entCatService)
-		entCatApp.Handle(new(controllers.EntCatController))
-	}
-
-	// PartnerCat
-	partnerCatParty := b.Party("/partner", crs).AllowMethods(iris.MethodOptions)
+	
+	// oc
+	ocParty := b.Party("/oc", crs).AllowMethods(iris.MethodOptions)
 	{
-		partnerCatParty.Use(middleware.AuthToken)
-		partnerCatService := service.NewPartnerCatService()
-		partnerCatApp := mvc.New(partnerCatParty.Party("/cat"))
-		partnerCatApp.Register(partnerCatService)
-		partnerCatApp.Handle(new(controllers.PartnerCatController))
+		ocParty.Use(middleware.AuthToken)
+		
+		ocService := service.NewOcService()
+		ocApp := mvc.New(ocParty.Party(""))
+		ocApp.Register(ocService)
+		ocApp.Handle(new(controllers.OcController))
+		
+		ocTypeService := service.NewOcTypeService()
+		ocTypeApp := mvc.New(ocParty.Party("/type"))
+		ocTypeApp.Register(ocTypeService)
+		ocTypeApp.Handle(new(controllers.OcTypeController))
+		
+		ocCatService := service.NewOcCatService()
+		ocCatApp := mvc.New(ocParty.Party("/cat"))
+		ocCatApp.Register(ocCatService)
+		ocCatApp.Handle(new(controllers.OcCatController))
 	}
 
 	// Model