apiGroup.go 770 字节
Newer Older
E
eoLinker API Management 已提交
1 2
package api

Y
Your Name 已提交
3 4
//AddAPIGroup 新建接口分组
func AddAPIGroup(groupName string, projectID, parentGroupID int) (bool, interface{}, error) {
Y
Your Name 已提交
5
	return apiGroupDao.AddAPIGroup(groupName, projectID, parentGroupID)
E
eoLinker API Management 已提交
6 7
}

Y
Your Name 已提交
8 9
//EditAPIGroup 修改接口分组
func EditAPIGroup(groupName string, groupID, projectID int) (bool, string, error) {
Y
Your Name 已提交
10
	return apiGroupDao.EditAPIGroup(groupName, groupID, projectID)
E
eoLinker API Management 已提交
11 12
}

Y
Your Name 已提交
13 14
//DeleteAPIGroup 删除接口分组
func DeleteAPIGroup(projectID, groupID int) (bool, string, error) {
Y
Your Name 已提交
15
	flag, result, err := apiGroupDao.DeleteAPIGroup(projectID, groupID)
Y
Your Name 已提交
16

E
eoLinker API Management 已提交
17 18 19
	return flag, result, err
}

Y
Your Name 已提交
20 21
//GetAPIGroupList 获取接口分组列表
func GetAPIGroupList(projectID int) (bool, []map[string]interface{}, error) {
Y
Your Name 已提交
22
	return apiGroupDao.GetAPIGroupList(projectID)
E
eoLinker API Management 已提交
23
}