mirror of
https://gitee.com/ssssssss-team/magic-boot.git
synced 2025-01-31 17:12:49 +08:00
34 lines
946 B
Plaintext
34 lines
946 B
Plaintext
{
|
|
"properties" : { },
|
|
"id" : "d6d05df1e8b14a6ebc270113b2cdd1ed",
|
|
"script" : null,
|
|
"groupId" : "67b2ce258e24491194b74992958c74aa",
|
|
"name" : "保存",
|
|
"createTime" : null,
|
|
"updateTime" : 1641219427227,
|
|
"lock" : "0",
|
|
"method" : "POST",
|
|
"path" : "/save",
|
|
"parameters" : [ ],
|
|
"option" : "[{\"name\":\"wrap_request_parameter\",\"value\":\"data\",\"description\":\"包装请求参数到一个变量中\"}]",
|
|
"requestBody" : "{}",
|
|
"headers" : [ ],
|
|
"paths" : [ ],
|
|
"responseBody" : null,
|
|
"description" : null,
|
|
"requestBodyDefinition" : null,
|
|
"responseBodyDefinition" : null,
|
|
"optionMap" : {
|
|
"wrap_request_parameter" : "data"
|
|
}
|
|
}
|
|
================================
|
|
import org.ssssssss.magicapi.cache.SqlCache;
|
|
import '@get:/menu/cache/delete' as cacheDelete;
|
|
|
|
SqlCache.delete('permissions:1')
|
|
if(data.id){
|
|
var menuId = data.id
|
|
cacheDelete();
|
|
}
|
|
return db.table("sys_menu").primary("id").saveOrUpdate(data); |