diff --git a/QMPlusServer/controller/api/exa_customer.go b/QMPlusServer/controller/api/exa_customer.go index 4f15896457918e3696763464da5a4d2d3bcccd19..da5c5222c21b6bb018eadce84d84a3dd490fbeb4 100644 --- a/QMPlusServer/controller/api/exa_customer.go +++ b/QMPlusServer/controller/api/exa_customer.go @@ -58,11 +58,11 @@ func DeleteExaCustomer(c *gin.Context) { // @Produce application/json // @Param data body dbModel.ExaCustomer true "创建客户" // @Success 200 {string} string "{"success":true,"data":{},"msg":"获取成功"}" -// @Router /customer/updataExaCustomer [post] -func UpdataExaCustomer(c *gin.Context) { +// @Router /customer/updateExaCustomer [post] +func UpdateExaCustomer(c *gin.Context) { var cu dbModel.ExaCustomer _ = c.ShouldBindJSON(&cu) - err := cu.UpdataExaCustomer() + err := cu.UpdateExaCustomer() if err != nil { servers.ReportFormat(c, false, fmt.Sprintf("创建失败:%v", err), gin.H{}) } else { diff --git a/QMPlusServer/controller/api/sys_api.go b/QMPlusServer/controller/api/sys_api.go index eae8ff6bafdb1eb2e2a3909882713465d1a625d0..92ea88c7821456881bad8a8d1fdf215c03c4c9aa 100644 --- a/QMPlusServer/controller/api/sys_api.go +++ b/QMPlusServer/controller/api/sys_api.go @@ -121,11 +121,11 @@ func GetApiById(c *gin.Context) { // @Produce application/json // @Param data body api.CreateApiParams true "创建api" // @Success 200 {string} string "{"success":true,"data":{},"msg":"获取成功"}" -// @Router /api/updataApi [post] -func UpdataApi(c *gin.Context) { +// @Router /api/updateApi [post] +func UpdateApi(c *gin.Context) { var api sysModel.SysApi _ = c.ShouldBindJSON(&api) - err := api.UpdataApi() + err := api.UpdateApi() if err != nil { servers.ReportFormat(c, false, fmt.Sprintf("修改数据失败,%v", err), gin.H{}) } else { diff --git a/QMPlusServer/controller/api/sys_casbin.go b/QMPlusServer/controller/api/sys_casbin.go index b7d8d0c1c9f13ababfb2903fd8d1da1553f86f11..2eff771a7da95401fa55f2727c61d6ebfe85c711 100644 --- a/QMPlusServer/controller/api/sys_casbin.go +++ b/QMPlusServer/controller/api/sys_casbin.go @@ -14,11 +14,11 @@ import ( // @Produce application/json // @Param data body sysModel.CasbinInReceive true "更改角色api权限" // @Success 200 {string} string "{"success":true,"data":{},"msg":"获取成功"}" -// @Router /casbin/casbinPUpdata [post] -func CasbinPUpdata(c *gin.Context) { +// @Router /casbin/casbinPUpdate [post] +func CasbinPUpdate(c *gin.Context) { var cmr sysModel.CasbinInReceive _ = c.ShouldBindJSON(&cmr) - err := new(sysModel.CasbinModel).CasbinPUpdata(cmr.AuthorityId, cmr.CasbinInfos) + err := new(sysModel.CasbinModel).CasbinPUpdate(cmr.AuthorityId, cmr.CasbinInfos) if err != nil { servers.ReportFormat(c, false, fmt.Sprintf("添加规则失败,%v", err), gin.H{}) } else { diff --git a/QMPlusServer/controller/api/sys_menu.go b/QMPlusServer/controller/api/sys_menu.go index f60623c7015453b5755bb6680b669ca968f23baa..57ed6a7967c6c69fc973bde3fe4abb532676f724 100644 --- a/QMPlusServer/controller/api/sys_menu.go +++ b/QMPlusServer/controller/api/sys_menu.go @@ -163,11 +163,11 @@ func DeleteBaseMenu(c *gin.Context) { // @Produce application/json // @Param data body sysModel.SysBaseMenu true "更新菜单" // @Success 200 {string} string "{"success":true,"data":{},"msg":"获取成功"}" -// @Router /menu/updataBaseMen [post] -func UpdataBaseMenu(c *gin.Context) { +// @Router /menu/updateBaseMen [post] +func UpdateBaseMenu(c *gin.Context) { var menu sysModel.SysBaseMenu _ = c.ShouldBindJSON(&menu) - err := menu.UpdataBaseMenu() + err := menu.UpdateBaseMenu() if err != nil { servers.ReportFormat(c, false, fmt.Sprintf("修改失败:%v", err), gin.H{}) } else { diff --git a/QMPlusServer/db/qmplus.sql b/QMPlusServer/db/qmplus.sql index c750d49c9a6872d51165f042fe0eefef2c6bc25e..7624f99349ca35af4ea175709d2201df8d846759 100644 --- a/QMPlusServer/db/qmplus.sql +++ b/QMPlusServer/db/qmplus.sql @@ -101,7 +101,7 @@ INSERT INTO `apis` VALUES (4, '2019-09-28 14:09:04', '2019-09-28 17:05:59', NULL INSERT INTO `apis` VALUES (5, '2019-09-28 14:15:50', '2019-09-28 17:05:53', NULL, NULL, '/api/getApiById', '获取api详细信息', 'api'); INSERT INTO `apis` VALUES (6, '2019-09-28 14:19:08', '2019-09-28 17:05:48', NULL, NULL, '/api/setAuthAndApi', '设置api和角色关系', 'api'); INSERT INTO `apis` VALUES (7, '2019-09-28 14:19:26', '2019-09-28 17:05:44', NULL, NULL, '/api/deleteApi', '删除Api', 'api'); -INSERT INTO `apis` VALUES (8, '2019-09-28 14:19:48', '2019-09-28 17:05:39', NULL, NULL, '/api/updataApi', '更新Api', 'api'); +INSERT INTO `apis` VALUES (8, '2019-09-28 14:19:48', '2019-09-28 17:05:39', NULL, NULL, '/api/updateApi', '更新Api', 'api'); INSERT INTO `apis` VALUES (9, '2019-09-30 15:04:55', '2019-09-30 15:04:55', NULL, NULL, '/api/getAuthAndApi', '获取api和角色关系', 'api'); INSERT INTO `apis` VALUES (10, '2019-09-30 15:05:38', '2019-09-30 15:05:38', NULL, NULL, '/api/getAllApis', '获取所有api', 'api'); INSERT INTO `apis` VALUES (11, '2019-09-30 15:23:09', '2019-09-30 15:23:09', NULL, NULL, '/authority/createAuthority', '创建角色', 'authority'); @@ -114,7 +114,7 @@ INSERT INTO `apis` VALUES (17, '2019-09-30 15:25:25', '2019-09-30 15:25:25', NUL INSERT INTO `apis` VALUES (18, '2019-09-30 15:25:53', '2019-09-30 15:25:53', NULL, NULL, '/menu/addMenuAuthority', '增加menu和角色关联关系', 'menu'); INSERT INTO `apis` VALUES (19, '2019-09-30 15:26:20', '2019-09-30 15:26:20', NULL, NULL, '/menu/getMenuAuthority', '获取指定角色menu', 'menu'); INSERT INTO `apis` VALUES (20, '2019-09-30 15:26:43', '2019-09-30 15:26:43', NULL, NULL, '/menu/deleteBaseMenu', '删除菜单', 'menu'); -INSERT INTO `apis` VALUES (21, '2019-09-30 15:28:05', '2019-09-30 15:28:05', NULL, NULL, '/menu/updataBaseMenu', '更新菜单', 'menu'); +INSERT INTO `apis` VALUES (21, '2019-09-30 15:28:05', '2019-09-30 15:28:05', NULL, NULL, '/menu/updateBaseMenu', '更新菜单', 'menu'); INSERT INTO `apis` VALUES (22, '2019-09-30 15:28:21', '2019-09-30 15:28:21', NULL, NULL, '/menu/getBaseMenuById', '根据id获取菜单', 'menu'); INSERT INTO `apis` VALUES (23, '2019-09-30 15:29:19', '2019-09-30 15:29:19', NULL, NULL, '/user/changePassword', '修改密码', 'user'); INSERT INTO `apis` VALUES (24, '2019-09-30 15:29:33', '2019-09-30 15:29:33', NULL, NULL, '/user/uploadHeaderImg', '上传头像', 'user'); @@ -217,7 +217,7 @@ INSERT INTO `casbin_rule` VALUES ('p', '8881', '/api/createApi', 'POST', '', '', INSERT INTO `casbin_rule` VALUES ('p', '8881', '/api/getApiList', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '8881', '/api/getApiById', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '8881', '/api/deleteApi', 'POST', '', '', ''); -INSERT INTO `casbin_rule` VALUES ('p', '8881', '/api/updataApi', 'POST', '', '', ''); +INSERT INTO `casbin_rule` VALUES ('p', '8881', '/api/updateApi', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '8881', '/api/getAllApis', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '8881', '/authority/createAuthority', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '8881', '/authority/deleteAuthority', 'POST', '', '', ''); @@ -230,7 +230,7 @@ INSERT INTO `casbin_rule` VALUES ('p', '8881', '/menu/getBaseMenuTree', 'POST', INSERT INTO `casbin_rule` VALUES ('p', '8881', '/menu/addMenuAuthority', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '8881', '/menu/getMenuAuthority', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '8881', '/menu/deleteBaseMenu', 'POST', '', '', ''); -INSERT INTO `casbin_rule` VALUES ('p', '8881', '/menu/updataBaseMenu', 'POST', '', '', ''); +INSERT INTO `casbin_rule` VALUES ('p', '8881', '/menu/updateBaseMenu', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '8881', '/menu/getBaseMenuById', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '8881', '/user/changePassword', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '8881', '/user/uploadHeaderImg', 'POST', '', '', ''); @@ -240,13 +240,13 @@ INSERT INTO `casbin_rule` VALUES ('p', '8881', '/user/setUserAuthority', 'POST', INSERT INTO `casbin_rule` VALUES ('p', '8881', '/fileUploadAndDownload/upload', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '8881', '/fileUploadAndDownload/getFileList', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '8881', '/fileUploadAndDownload/deleteFile', 'POST', '', '', ''); -INSERT INTO `casbin_rule` VALUES ('p', '8881', '/casbin/casbinPUpdata', 'POST', '', '', ''); +INSERT INTO `casbin_rule` VALUES ('p', '8881', '/casbin/casbinPUpdate', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '8881', '/casbin/getPolicyPathByAuthorityId', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '8881', '/jwt/jsonInBlacklist', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '8881', '/system/getSystemConfig', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '8881', '/system/setSystemConfig', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '8881', '/customer/createExaCustomer', 'POST', '', '', ''); -INSERT INTO `casbin_rule` VALUES ('p', '8881', '/customer/updataExaCustomer', 'POST', '', '', ''); +INSERT INTO `casbin_rule` VALUES ('p', '8881', '/customer/updateExaCustomer', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '8881', '/customer/deleteExaCustomer', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '8881', '/customer/getExaCustomer', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '8881', '/customer/getExaCustomerList', 'POST', '', '', ''); @@ -256,7 +256,7 @@ INSERT INTO `casbin_rule` VALUES ('p', '9528', '/api/createApi', 'POST', '', '', INSERT INTO `casbin_rule` VALUES ('p', '9528', '/api/getApiList', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '9528', '/api/getApiById', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '9528', '/api/deleteApi', 'POST', '', '', ''); -INSERT INTO `casbin_rule` VALUES ('p', '9528', '/api/updataApi', 'POST', '', '', ''); +INSERT INTO `casbin_rule` VALUES ('p', '9528', '/api/updateApi', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '9528', '/api/getAllApis', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '9528', '/authority/createAuthority', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '9528', '/authority/deleteAuthority', 'POST', '', '', ''); @@ -269,7 +269,7 @@ INSERT INTO `casbin_rule` VALUES ('p', '9528', '/menu/getBaseMenuTree', 'POST', INSERT INTO `casbin_rule` VALUES ('p', '9528', '/menu/addMenuAuthority', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '9528', '/menu/getMenuAuthority', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '9528', '/menu/deleteBaseMenu', 'POST', '', '', ''); -INSERT INTO `casbin_rule` VALUES ('p', '9528', '/menu/updataBaseMenu', 'POST', '', '', ''); +INSERT INTO `casbin_rule` VALUES ('p', '9528', '/menu/updateBaseMenu', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '9528', '/menu/getBaseMenuById', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '9528', '/user/changePassword', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '9528', '/user/uploadHeaderImg', 'POST', '', '', ''); @@ -279,13 +279,13 @@ INSERT INTO `casbin_rule` VALUES ('p', '9528', '/user/setUserAuthority', 'POST', INSERT INTO `casbin_rule` VALUES ('p', '9528', '/fileUploadAndDownload/upload', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '9528', '/fileUploadAndDownload/getFileList', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '9528', '/fileUploadAndDownload/deleteFile', 'POST', '', '', ''); -INSERT INTO `casbin_rule` VALUES ('p', '9528', '/casbin/casbinPUpdata', 'POST', '', '', ''); +INSERT INTO `casbin_rule` VALUES ('p', '9528', '/casbin/casbinPUpdate', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '9528', '/casbin/getPolicyPathByAuthorityId', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '9528', '/jwt/jsonInBlacklist', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '9528', '/system/getSystemConfig', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '9528', '/system/setSystemConfig', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '9528', '/customer/createExaCustomer', 'POST', '', '', ''); -INSERT INTO `casbin_rule` VALUES ('p', '9528', '/customer/updataExaCustomer', 'POST', '', '', ''); +INSERT INTO `casbin_rule` VALUES ('p', '9528', '/customer/updateExaCustomer', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '9528', '/customer/deleteExaCustomer', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '9528', '/customer/getExaCustomer', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '9528', '/customer/getExaCustomerList', 'POST', '', '', ''); @@ -296,7 +296,7 @@ INSERT INTO `casbin_rule` VALUES ('p', '888', '/api/createApi', 'POST', '', '', INSERT INTO `casbin_rule` VALUES ('p', '888', '/api/getApiList', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '888', '/api/getApiById', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '888', '/api/deleteApi', 'POST', '', '', ''); -INSERT INTO `casbin_rule` VALUES ('p', '888', '/api/updataApi', 'POST', '', '', ''); +INSERT INTO `casbin_rule` VALUES ('p', '888', '/api/updateApi', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '888', '/api/getAllApis', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '888', '/authority/createAuthority', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '888', '/authority/deleteAuthority', 'POST', '', '', ''); @@ -309,7 +309,7 @@ INSERT INTO `casbin_rule` VALUES ('p', '888', '/menu/getBaseMenuTree', 'POST', ' INSERT INTO `casbin_rule` VALUES ('p', '888', '/menu/addMenuAuthority', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '888', '/menu/getMenuAuthority', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '888', '/menu/deleteBaseMenu', 'POST', '', '', ''); -INSERT INTO `casbin_rule` VALUES ('p', '888', '/menu/updataBaseMenu', 'POST', '', '', ''); +INSERT INTO `casbin_rule` VALUES ('p', '888', '/menu/updateBaseMenu', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '888', '/menu/getBaseMenuById', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '888', '/user/changePassword', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '888', '/user/uploadHeaderImg', 'POST', '', '', ''); @@ -319,14 +319,14 @@ INSERT INTO `casbin_rule` VALUES ('p', '888', '/user/setUserAuthority', 'POST', INSERT INTO `casbin_rule` VALUES ('p', '888', '/fileUploadAndDownload/upload', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '888', '/fileUploadAndDownload/getFileList', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '888', '/fileUploadAndDownload/deleteFile', 'POST', '', '', ''); -INSERT INTO `casbin_rule` VALUES ('p', '888', '/casbin/casbinPUpdata', 'POST', '', '', ''); +INSERT INTO `casbin_rule` VALUES ('p', '888', '/casbin/casbinPUpdate', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '888', '/casbin/getPolicyPathByAuthorityId', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '888', '/casbin/casbinTest/:pathParam', 'GET', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '888', '/jwt/jsonInBlacklist', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '888', '/system/getSystemConfig', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '888', '/system/setSystemConfig', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '888', '/customer/createExaCustomer', 'POST', '', '', ''); -INSERT INTO `casbin_rule` VALUES ('p', '888', '/customer/updataExaCustomer', 'POST', '', '', ''); +INSERT INTO `casbin_rule` VALUES ('p', '888', '/customer/updateExaCustomer', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '888', '/customer/deleteExaCustomer', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '888', '/customer/getExaCustomer', 'POST', '', '', ''); INSERT INTO `casbin_rule` VALUES ('p', '888', '/customer/getExaCustomerList', 'POST', '', '', ''); @@ -4159,7 +4159,7 @@ INSERT INTO `sys_apis` VALUES (3, '2019-09-28 11:33:41', '2019-12-11 16:51:41', INSERT INTO `sys_apis` VALUES (4, '2019-09-28 14:09:04', '2019-09-28 17:05:59', NULL, NULL, '/api/getApiList', '获取api列表', 'api', 'POST'); INSERT INTO `sys_apis` VALUES (5, '2019-09-28 14:15:50', '2019-09-28 17:05:53', NULL, NULL, '/api/getApiById', '获取api详细信息', 'api', 'POST'); INSERT INTO `sys_apis` VALUES (7, '2019-09-28 14:19:26', '2019-09-28 17:05:44', NULL, NULL, '/api/deleteApi', '删除Api', 'api', 'POST'); -INSERT INTO `sys_apis` VALUES (8, '2019-09-28 14:19:48', '2019-09-28 17:05:39', NULL, NULL, '/api/updataApi', '更新Api', 'api', 'POST'); +INSERT INTO `sys_apis` VALUES (8, '2019-09-28 14:19:48', '2019-09-28 17:05:39', NULL, NULL, '/api/updateApi', '更新Api', 'api', 'POST'); INSERT INTO `sys_apis` VALUES (10, '2019-09-30 15:05:38', '2019-09-30 15:05:38', NULL, NULL, '/api/getAllApis', '获取所有api', 'api', 'POST'); INSERT INTO `sys_apis` VALUES (11, '2019-09-30 15:23:09', '2019-09-30 15:23:09', NULL, NULL, '/authority/createAuthority', '创建角色', 'authority', 'POST'); INSERT INTO `sys_apis` VALUES (12, '2019-09-30 15:23:33', '2019-09-30 15:23:33', NULL, NULL, '/authority/deleteAuthority', '删除角色', 'authority', 'POST'); @@ -4171,7 +4171,7 @@ INSERT INTO `sys_apis` VALUES (17, '2019-09-30 15:25:25', '2019-09-30 15:25:25', INSERT INTO `sys_apis` VALUES (18, '2019-09-30 15:25:53', '2019-09-30 15:25:53', NULL, NULL, '/menu/addMenuAuthority', '增加menu和角色关联关系', 'menu', 'POST'); INSERT INTO `sys_apis` VALUES (19, '2019-09-30 15:26:20', '2019-09-30 15:26:20', NULL, NULL, '/menu/getMenuAuthority', '获取指定角色menu', 'menu', 'POST'); INSERT INTO `sys_apis` VALUES (20, '2019-09-30 15:26:43', '2019-09-30 15:26:43', NULL, NULL, '/menu/deleteBaseMenu', '删除菜单', 'menu', 'POST'); -INSERT INTO `sys_apis` VALUES (21, '2019-09-30 15:28:05', '2019-09-30 15:28:05', NULL, NULL, '/menu/updataBaseMenu', '更新菜单', 'menu', 'POST'); +INSERT INTO `sys_apis` VALUES (21, '2019-09-30 15:28:05', '2019-09-30 15:28:05', NULL, NULL, '/menu/updateBaseMenu', '更新菜单', 'menu', 'POST'); INSERT INTO `sys_apis` VALUES (22, '2019-09-30 15:28:21', '2019-09-30 15:28:21', NULL, NULL, '/menu/getBaseMenuById', '根据id获取菜单', 'menu', 'POST'); INSERT INTO `sys_apis` VALUES (23, '2019-09-30 15:29:19', '2019-09-30 15:29:19', NULL, NULL, '/user/changePassword', '修改密码', 'user', 'POST'); INSERT INTO `sys_apis` VALUES (24, '2019-09-30 15:29:33', '2019-09-30 15:29:33', NULL, NULL, '/user/uploadHeaderImg', '上传头像', 'user', 'POST'); @@ -4180,7 +4180,7 @@ INSERT INTO `sys_apis` VALUES (28, '2019-10-09 15:15:17', '2019-10-09 15:17:07', INSERT INTO `sys_apis` VALUES (29, '2019-10-09 23:01:40', '2019-10-09 23:01:40', NULL, NULL, '/user/setUserAuthority', '修改用户角色', 'user', 'POST'); INSERT INTO `sys_apis` VALUES (30, '2019-10-26 20:14:38', '2019-10-26 20:14:38', NULL, NULL, '/fileUploadAndDownload/upload', '文件上传示例', 'fileUploadAndDownload', 'POST'); INSERT INTO `sys_apis` VALUES (31, '2019-10-26 20:14:59', '2019-10-26 20:14:59', NULL, NULL, '/fileUploadAndDownload/getFileList', '获取上传文件列表', 'fileUploadAndDownload', 'POST'); -INSERT INTO `sys_apis` VALUES (32, '2019-12-12 13:28:47', '2019-12-12 13:28:47', NULL, NULL, '/casbin/casbinPUpdata', '更改角色api权限', 'casbin', 'POST'); +INSERT INTO `sys_apis` VALUES (32, '2019-12-12 13:28:47', '2019-12-12 13:28:47', NULL, NULL, '/casbin/casbinPUpdate', '更改角色api权限', 'casbin', 'POST'); INSERT INTO `sys_apis` VALUES (33, '2019-12-12 13:28:59', '2019-12-12 13:28:59', NULL, NULL, '/casbin/getPolicyPathByAuthorityId', '获取权限列表', 'casbin', 'POST'); INSERT INTO `sys_apis` VALUES (34, '2019-12-12 17:02:15', '2019-12-12 17:02:15', NULL, NULL, '/fileUploadAndDownload/deleteFile', '删除文件', 'fileUploadAndDownload', 'POST'); INSERT INTO `sys_apis` VALUES (35, '2019-12-28 18:18:07', '2019-12-28 18:18:07', NULL, NULL, '/jwt/jsonInBlacklist', 'jwt加入黑名单', 'jwt', 'POST'); @@ -4188,7 +4188,7 @@ INSERT INTO `sys_apis` VALUES (36, '2020-01-06 17:56:36', '2020-01-06 17:56:36', INSERT INTO `sys_apis` VALUES (37, '2020-01-13 14:04:05', '2020-01-13 14:04:05', NULL, NULL, '/system/getSystemConfig', '获取配置文件内容', 'system', 'POST'); INSERT INTO `sys_apis` VALUES (38, '2020-01-13 15:02:06', '2020-01-13 15:02:06', NULL, NULL, '/system/setSystemConfig', '设置配置文件内容', 'system', 'POST'); INSERT INTO `sys_apis` VALUES (39, '2020-02-25 15:32:39', '2020-02-25 15:32:39', NULL, NULL, '/customer/createExaCustomer', '创建客户', 'customer', 'POST'); -INSERT INTO `sys_apis` VALUES (40, '2020-02-25 15:32:51', '2020-02-25 15:34:56', NULL, NULL, '/customer/updataExaCustomer', '更新客户', 'customer', 'POST'); +INSERT INTO `sys_apis` VALUES (40, '2020-02-25 15:32:51', '2020-02-25 15:34:56', NULL, NULL, '/customer/updateExaCustomer', '更新客户', 'customer', 'POST'); INSERT INTO `sys_apis` VALUES (41, '2020-02-25 15:33:57', '2020-02-25 15:33:57', NULL, NULL, '/customer/deleteExaCustomer', '删除客户', 'customer', 'POST'); INSERT INTO `sys_apis` VALUES (42, '2020-02-25 15:36:48', '2020-02-25 15:37:16', NULL, NULL, '/customer/getExaCustomer', '获取单一客户', 'customer', 'POST'); INSERT INTO `sys_apis` VALUES (43, '2020-02-25 15:37:06', '2020-02-25 15:37:06', NULL, NULL, '/customer/getExaCustomerList', '获取客户列表', 'customer', 'POST'); diff --git a/QMPlusServer/docs/docs.go b/QMPlusServer/docs/docs.go index 9537f99cd68671ed2a2e9dff4a4d352c15bfb854..cd90ac5fa7e07cb00cf97d5ff4e435ba94d8c131 100644 --- a/QMPlusServer/docs/docs.go +++ b/QMPlusServer/docs/docs.go @@ -209,7 +209,7 @@ var doc = `{ } } }, - "/api/updataApi": { + "/api/updateApi": { "post": { "security": [ { @@ -559,7 +559,7 @@ var doc = `{ } } }, - "/casbin/casbinPUpdata": { + "/casbin/casbinPUpdate": { "post": { "security": [ { @@ -793,7 +793,7 @@ var doc = `{ } } }, - "/customer/updataExaCustomer": { + "/customer/updateExaCustomer": { "post": { "security": [ { @@ -1345,7 +1345,7 @@ var doc = `{ } } }, - "/menu/updataBaseMen": { + "/menu/updateBaseMen": { "post": { "security": [ { diff --git a/QMPlusServer/docs/swagger.json b/QMPlusServer/docs/swagger.json index 622be52ff6a0171ec59e93aec8f9971eb0ae7aa1..caf4663053d60bed9935f273654b3890ba335b4b 100644 --- a/QMPlusServer/docs/swagger.json +++ b/QMPlusServer/docs/swagger.json @@ -192,7 +192,7 @@ } } }, - "/api/updataApi": { + "/api/updateApi": { "post": { "security": [ { @@ -542,7 +542,7 @@ } } }, - "/casbin/casbinPUpdata": { + "/casbin/casbinPUpdate": { "post": { "security": [ { @@ -776,7 +776,7 @@ } } }, - "/customer/updataExaCustomer": { + "/customer/updateExaCustomer": { "post": { "security": [ { @@ -1328,7 +1328,7 @@ } } }, - "/menu/updataBaseMen": { + "/menu/updateBaseMen": { "post": { "security": [ { diff --git a/QMPlusServer/docs/swagger.yaml b/QMPlusServer/docs/swagger.yaml index 78c28848050d697a51a6208f41d436fdf747ccd5..f9ab111be83f705dd15e2540dbc2eb12e17ebc18 100644 --- a/QMPlusServer/docs/swagger.yaml +++ b/QMPlusServer/docs/swagger.yaml @@ -420,7 +420,7 @@ paths: summary: 分页获取API列表 tags: - SysApi - /api/updataApi: + /api/updateApi: post: consumes: - application/json @@ -636,7 +636,7 @@ paths: summary: casb RBAC RESTFUL测试路由 tags: - casbin - /casbin/casbinPUpdata: + /casbin/casbinPUpdate: post: consumes: - application/json @@ -780,7 +780,7 @@ paths: summary: 获取权限客户列表 tags: - SysApi - /customer/updataExaCustomer: + /customer/updateExaCustomer: post: consumes: - application/json @@ -1118,7 +1118,7 @@ paths: summary: 分页获取基础menu列表 tags: - menu - /menu/updataBaseMen: + /menu/updateBaseMen: post: consumes: - application/json diff --git a/QMPlusServer/model/dbModel/exa_customer.go b/QMPlusServer/model/dbModel/exa_customer.go index 2c2e93a622699e91ef89b62cb467f2f25576d95f..4d2ac8a16f08f3691eebe987be009bedc97f7f85 100644 --- a/QMPlusServer/model/dbModel/exa_customer.go +++ b/QMPlusServer/model/dbModel/exa_customer.go @@ -30,7 +30,7 @@ func (e *ExaCustomer)DeleteExaCustomer()(err error){ } //更新用户 -func (e *ExaCustomer)UpdataExaCustomer()(err error){ +func (e *ExaCustomer)UpdateExaCustomer()(err error){ err = qmsql.DEFAULTDB.Save(e).Error return err } diff --git a/QMPlusServer/model/sysModel/sys_api.go b/QMPlusServer/model/sysModel/sys_api.go index 7886715115b9d62d01de16ab4d9c748419dc64d2..12224bbda779a2f69f3cf3cb24692659f6447497 100644 --- a/QMPlusServer/model/sysModel/sys_api.go +++ b/QMPlusServer/model/sysModel/sys_api.go @@ -35,7 +35,7 @@ func (a *SysApi) DeleteApi() (err error) { } //更新api -func (a *SysApi) UpdataApi() (err error) { +func (a *SysApi) UpdateApi() (err error) { var oldA SysApi flag := qmsql.DEFAULTDB.Where("path = ?", a.Path).RecordNotFound() if !flag { @@ -45,7 +45,7 @@ func (a *SysApi) UpdataApi() (err error) { if err != nil { return err } else { - err = new(CasbinModel).CasbinApiUpdata(oldA.Path, a.Path) + err = new(CasbinModel).CasbinApiUpdate(oldA.Path, a.Path) if err != nil { return err } else { diff --git a/QMPlusServer/model/sysModel/sys_base_menu.go b/QMPlusServer/model/sysModel/sys_base_menu.go index 66e0581d88dd3f53ff24663f67e403c298187b2c..c2a25e1d479dcfe09b8c4ee6a844dda9b7810eb6 100644 --- a/QMPlusServer/model/sysModel/sys_base_menu.go +++ b/QMPlusServer/model/sysModel/sys_base_menu.go @@ -48,7 +48,7 @@ func (b *SysBaseMenu) DeleteBaseMenu(id float64) (err error) { } //更新路由 -func (b *SysBaseMenu) UpdataBaseMenu() (err error) { +func (b *SysBaseMenu) UpdateBaseMenu() (err error) { upDataMap := make(map[string]interface{}) upDataMap["parent_id"] = b.ParentId upDataMap["path"] = b.Path diff --git a/QMPlusServer/model/sysModel/sys_casbin.go b/QMPlusServer/model/sysModel/sys_casbin.go index f4ec53b8275783f407df2bf554040465adf7f263..49d74af6ce866fb2c38d38595479f20975c13a54 100644 --- a/QMPlusServer/model/sysModel/sys_casbin.go +++ b/QMPlusServer/model/sysModel/sys_casbin.go @@ -31,7 +31,7 @@ type CasbinInReceive struct { } // 更新权限 -func (c *CasbinModel) CasbinPUpdata(AuthorityId string, casbinInfos []CasbinInfo) error { +func (c *CasbinModel) CasbinPUpdate(AuthorityId string, casbinInfos []CasbinInfo) error { c.clearCasbin(0, AuthorityId) for _, v := range casbinInfos { cm := CasbinModel{ @@ -50,7 +50,7 @@ func (c *CasbinModel) CasbinPUpdata(AuthorityId string, casbinInfos []CasbinInfo } // API更新随动 -func (c *CasbinModel) CasbinApiUpdata(oldPath string, newPath string) error { +func (c *CasbinModel) CasbinApiUpdate(oldPath string, newPath string) error { var cs []CasbinModel err := qmsql.DEFAULTDB.Table("casbin_rule").Where("v1 = ?", oldPath).Find(&cs).Update("v1", newPath).Error return err diff --git a/QMPlusServer/router/exp_customer.go b/QMPlusServer/router/exp_customer.go index 6bf149db13d7de9183bd92f0824e9a7e1663e236..bee0d562891ca219875e5bb6304f5d9682d92829 100644 --- a/QMPlusServer/router/exp_customer.go +++ b/QMPlusServer/router/exp_customer.go @@ -10,7 +10,7 @@ func InitCustomerRouter(Router *gin.RouterGroup) { ApiRouter := Router.Group("customer").Use(middleware.JWTAuth()).Use(middleware.CasbinHandler()) { ApiRouter.POST("createExaCustomer", api.CreateExaCustomer) // 创建客户 - ApiRouter.POST("updataExaCustomer", api.UpdataExaCustomer) // 更新客户 + ApiRouter.POST("updateExaCustomer", api.UpdateExaCustomer) // 更新客户 ApiRouter.POST("deleteExaCustomer", api.DeleteExaCustomer) // 删除客户 ApiRouter.POST("getExaCustomer", api.GetExaCustomer) // 获取单一客户信息 ApiRouter.POST("getExaCustomerList", api.GetExaCustomerList) // 获取客户列表 diff --git a/QMPlusServer/router/sys_api.go b/QMPlusServer/router/sys_api.go index 74e93a90e86d150c4ece32cf3cec58cbff7fe500..61fefc65a3bca000dc8ab5dfe9c2fef1b6600736 100644 --- a/QMPlusServer/router/sys_api.go +++ b/QMPlusServer/router/sys_api.go @@ -13,7 +13,7 @@ func InitApiRouter(Router *gin.RouterGroup) { ApiRouter.POST("deleteApi", api.DeleteApi) //删除Api ApiRouter.POST("getApiList", api.GetApiList) //获取Api列表 ApiRouter.POST("getApiById", api.GetApiById) //获取单条Api消息 - ApiRouter.POST("updataApi", api.UpdataApi) //更新api + ApiRouter.POST("updateApi", api.UpdateApi) //更新api ApiRouter.POST("getAllApis", api.GetAllApis) // 获取所有api } } diff --git a/QMPlusServer/router/sys_casbin.go b/QMPlusServer/router/sys_casbin.go index c24702fd39bd743141ee1e466e02b44de4cb861d..409b9840aff8f246b2c0b1d821a8b7c6185b3c1b 100644 --- a/QMPlusServer/router/sys_casbin.go +++ b/QMPlusServer/router/sys_casbin.go @@ -9,7 +9,7 @@ import ( func InitCasbinRouter(Router *gin.RouterGroup) { CasbinRouter := Router.Group("casbin").Use(middleware.JWTAuth()).Use(middleware.CasbinHandler()) { - CasbinRouter.POST("casbinPUpdata", api.CasbinPUpdata) + CasbinRouter.POST("casbinPUpdate", api.CasbinPUpdate) CasbinRouter.POST("getPolicyPathByAuthorityId", api.GetPolicyPathByAuthorityId) CasbinRouter.GET("casbinTest/:pathParam", api.CasbinTest) } diff --git a/QMPlusServer/router/sys_menu.go b/QMPlusServer/router/sys_menu.go index 8103ad65b7adf6545affac40ee6fe900f917ecfe..63111dc71dd8bf5d6e916979216753b0b8f7c2f3 100644 --- a/QMPlusServer/router/sys_menu.go +++ b/QMPlusServer/router/sys_menu.go @@ -16,7 +16,7 @@ func InitMenuRouter(Router *gin.RouterGroup) (R gin.IRoutes) { MenuRouter.POST("addMenuAuthority", api.AddMenuAuthority) // 增加menu和角色关联关系 MenuRouter.POST("getMenuAuthority", api.GetMenuAuthority) // 获取指定角色menu MenuRouter.POST("deleteBaseMenu", api.DeleteBaseMenu) // 删除菜单 - MenuRouter.POST("updataBaseMenu", api.UpdataBaseMenu) // 更新菜单 + MenuRouter.POST("updateBaseMenu", api.UpdateBaseMenu) // 更新菜单 MenuRouter.POST("getBaseMenuById", api.GetBaseMenuById) //根据id获取菜单 } return MenuRouter diff --git a/QMPlusVuePage/src/api/api.js b/QMPlusVuePage/src/api/api.js index 30b452ca01ee34d1ba1b906789c0e47ebd5ac13d..bb443bea7b5733edf482b3193cc644bfcdb77c3e 100644 --- a/QMPlusVuePage/src/api/api.js +++ b/QMPlusVuePage/src/api/api.js @@ -61,10 +61,10 @@ export const getApiById = (data) => { // @Produce application/json // @Param data body api.CreateApiParams true "更新api" // @Success 200 {string} json "{"success":true,"data":{},"msg":"更新成功"}" -// @Router /api/updataApi [post] -export const updataApi = (data) => { +// @Router /api/updateApi [post] +export const updateApi = (data) => { return service({ - url: "/api/updataApi", + url: "/api/updateApi", method: 'post', data }) diff --git a/QMPlusVuePage/src/api/casbin.js b/QMPlusVuePage/src/api/casbin.js index f990514a396502afcd8eab796bf8da35276b8afe..9b3010ec38146992440838c5ae41758d6e5bfb5a 100644 --- a/QMPlusVuePage/src/api/casbin.js +++ b/QMPlusVuePage/src/api/casbin.js @@ -7,11 +7,11 @@ import service from '@/utils/request' // @Produce application/json // @Param data body api.CreateAuthorityPatams true "更改角色api权限" // @Success 200 {string} json "{"success":true,"data":{},"msg":"获取成功"}" -// @Router /casbin/casbinPUpdata [post] +// @Router /casbin/casbinPUpdate [post] -export const casbinPUpdata = (data) => { +export const casbinPUpdate = (data) => { return service({ - url: "/casbin/casbinPUpdata", + url: "/casbin/casbinPUpdate", method: 'post', data }) diff --git a/QMPlusVuePage/src/api/customer.js b/QMPlusVuePage/src/api/customer.js index 90a098b05e37a87cd45c48b29e439f799b8f21b2..97b10e5e4cd4a29e8e02988fbce40c99e0c4a0ac 100644 --- a/QMPlusVuePage/src/api/customer.js +++ b/QMPlusVuePage/src/api/customer.js @@ -25,10 +25,10 @@ export const createExaCustomer = (data) => { // @Produce application/json // @Param data body dbModel.ExaCustomer true "更新客户信息" // @Success 200 {string} string "{"success":true,"data":{},"msg":"获取成功"}" -// @Router /customer/updataExaCustomer [post] -export const updataExaCustomer = (data) => { +// @Router /customer/updateExaCustomer [post] +export const updateExaCustomer = (data) => { return service({ - url: "/customer/updataExaCustomer", + url: "/customer/updateExaCustomer", method: 'post', data }) diff --git a/QMPlusVuePage/src/api/menu.js b/QMPlusVuePage/src/api/menu.js index 7182b76783241b1604a459881b2796fce074bd2a..cf512fbe8c54ecb7bb5706bddffc4d9dd8e76ca2 100644 --- a/QMPlusVuePage/src/api/menu.js +++ b/QMPlusVuePage/src/api/menu.js @@ -90,10 +90,10 @@ export const deleteBaseMenu = (data) => { // @Summary 修改menu列表 // @Produce application/json // @Param menu Object -// @Router /menu/updataBaseMenu [post] -export const updataBaseMenu = (data) => { +// @Router /menu/updateBaseMenu [post] +export const updateBaseMenu = (data) => { return service({ - url: "/menu/updataBaseMenu", + url: "/menu/updateBaseMenu", method: 'post', data }) diff --git a/QMPlusVuePage/src/view/example/customer/customer.vue b/QMPlusVuePage/src/view/example/customer/customer.vue index 51bdf1c610a665325e590e0c9566fa762eea4db6..d74dd5d7cbd56e666552abaea6f8dcd056eab059 100644 --- a/QMPlusVuePage/src/view/example/customer/customer.vue +++ b/QMPlusVuePage/src/view/example/customer/customer.vue @@ -25,7 +25,7 @@