diff --git a/src/operation/gateway.go b/src/operation/gateway.go index 2d69ba7..3f7f7b4 100644 --- a/src/operation/gateway.go +++ b/src/operation/gateway.go @@ -28,8 +28,6 @@ type Gateway struct { func (s Gateway) List(m *ice.Message, arg ...string) { if s.ValueList(m, arg); s.IsLeader(m) { m.PushAction(s.CreateProject, s.ScanProject, s.Open, s.Modify) - } else if s.IsWorker(m) { - m.PushAction(s.CreateProject) } else { m.PushAction() } diff --git a/src/operation/product.go b/src/operation/product.go index 8db5a38..649a172 100644 --- a/src/operation/product.go +++ b/src/operation/product.go @@ -29,7 +29,7 @@ func (s product) Scan(m *ice.Message, arg ...string) { }) } func (s product) List(m *ice.Message, arg ...string) { - if s.ValueList(m, arg); s.IsWorker(m) { + if s.ValueList(m, arg); s.IsLeader(m) { m.PushAction(s.Open, s.Remove) } else { m.PushAction(s.Open) diff --git a/src/operation/project.go b/src/operation/project.go index a307799..18ed2e5 100644 --- a/src/operation/project.go +++ b/src/operation/project.go @@ -40,8 +40,10 @@ func (s project) Scan(m *ice.Message, arg ...string) { }) } func (s project) List(m *ice.Message, arg ...string) { - if s.ValueList(m, arg); s.IsWorker(m) { + if s.ValueList(m, arg); s.IsLeader(m) { m.PushAction(s.ScanProduct, s.Open, s.Remove) + } else if s.IsWorker(m) { + m.PushAction(s.ScanProduct, s.Open) } else { m.PushAction() } diff --git a/src/operation/studio.go b/src/operation/studio.go index af358f4..85621cd 100644 --- a/src/operation/studio.go +++ b/src/operation/studio.go @@ -19,7 +19,7 @@ type studio struct { } func (s studio) List(m *ice.Message, arg ...string) { - m.Cmdy(s.PrefixPortal(m)).Action().Display("") + m.Cmdy(s.PrefixPortal(m)).Action().Display("").DisplayCSS("") } func (s studio) Gateway(m *ice.Message, arg ...string) { if len(arg) < 3 { diff --git a/src/operation/studio.js b/src/operation/studio.js index d38444b..bdddedd 100644 --- a/src/operation/studio.js +++ b/src/operation/studio.js @@ -4,16 +4,21 @@ Volcanos(chat.ONIMPORT, { }, place: function(can, msg) { msg.Table(function(value) { - can.onimport.item(can, {name: value.cloud_name, _hash: [value.cloud_uid.slice(0, 12)]}, function(event, item, show, target) { can.db.cloud_uid = value.cloud_uid + can.onimport.item(can, {icon: "bi bi-phone", name: value.cloud_name, _hash: [value.cloud_uid.slice(0, 12)]}, function(event, item, show, target) { can.db.cloud_uid = value.cloud_uid show === undefined && can.runAction(event, "gateway", [value.cloud_uid], function(msg) { can.onimport.gateway(can, msg, target, value.cloud_uid) }) + return true + }, function(event, item, target) { + return {meta: { + open: function() { can.user.open("/s/"+can.misc.Search(can, ice.POD)+"/c/"+"web.team.operation.portal"+"?cloud_uid="+value.cloud_uid) }, + }} }) }) }, gateway: function(can, msg, target, cloud_uid) { can.onimport.itemlist(can, msg.Table(function(value) { - return {name: value.title, _hash: target._item._hash.concat([value.space.slice(0, 12)]), action: "gateway", cloud_uid: cloud_uid, uid: value.uid, space: can.core.Keys(value.cluster_space, value.space)} + return {icon: "bi bi-window-desktop", name: value.title, _hash: target._item._hash.concat([value.space.slice(0, 12)]), action: "gateway", cloud_uid: cloud_uid, uid: value.uid, space: can.core.Keys(value.cluster_space, value.space)} }), function(event, item, show, target) { can.db.gateway_uid = item.uid show === undefined && can.runAction(event, "project", [cloud_uid, item.uid], function(msg) { if (msg.Length() == 0) { @@ -22,13 +27,14 @@ Volcanos(chat.ONIMPORT, { can.onimport.project(can, msg, target, cloud_uid) } }) + return true }, function(event, item, target) { return can.onimport.contexts(can, item, target) }, target) }, project: function(can, msg, target, cloud_uid) { can.onimport.itemlist(can, msg.Table(function(value) { - return {name: value.name, _hash: target._item._hash.concat([value.name]), action: "project", cloud_uid: cloud_uid, uid: value.uid, space: can.core.Keys(target._item.space, value.name)} + return {icon: "bi bi-window-sidebar", name: value.name, _hash: target._item._hash.concat([value.name]), action: "project", cloud_uid: cloud_uid, uid: value.uid, space: can.core.Keys(target._item.space, value.name)} }), function(event, item, show, target) { can.db.project_uid = item.uid show === undefined && can.runAction(event, "product", [cloud_uid, item.uid], function(msg) { if (msg.Length() == 0) { @@ -37,22 +43,27 @@ Volcanos(chat.ONIMPORT, { can.onimport.product(can, msg, target, cloud_uid) } }) + return true }, function(event, item, target) { return can.onimport.contexts(can, item, target) }, target) }, product: function(can, msg, target, cloud_uid) { can.onimport.itemlist(can, msg.Table(function(value) { - return {name: value.name, _hash: target._item._hash.concat([value.index]), action: "product", cloud_uid: cloud_uid, uid: value.uid, space: target._item.space, index: value.index} + return {icon: "bi bi-phone", name: value.name, _hash: target._item._hash.concat([value.index]), action: "product", cloud_uid: cloud_uid, uid: value.uid, space: target._item.space, index: value.index} }), function(event, item, show, target) { can.db.product_uid = item.uid can.onimport.plugin(can, item, target) - }, function() {}, target) + }, function(event, item, target) { + return {meta: { + open: function() { can.user.open("/s/"+item.space+"/c/"+item.index) }, + }} + }, target) }, contexts: function(can, item, target) { return {meta: { portal: function() { can.onappend.plugin(can._root.Action, {index: web.CHAT_IFRAME, args: "/s/"+item.space+"/c/portal", style: html.FLOAT, title: item.name}) }, desktop: function() { can.onimport.plugin(can, item, target, web.DESKTOP) }, - admin: function() { can.onappend.plugin(can._root.Action, {index: web.CHAT_IFRAME, args: "/s/"+item.space, style: html.FLOAT, title: item.name}) }, + admin: function() { can.onappend.plugin(can._root.Action, {index: web.CHAT_IFRAME, args: "/s/"+item.space+"/c/admin", style: html.FLOAT, title: item.name}) }, word: function() { can.onimport.plugin(can, item, target, web.WORD) }, vimer: function() { can.onimport.plugin(can, item, target, web.VIMER) }, runtime: function() { can.onimport.plugin(can, item, target, cli.RUNTIME) }, @@ -72,7 +83,9 @@ Volcanos(chat.ONIMPORT, { height: can.ConfHeight(), width: can.ConfWidth()-can.ui.project.offsetWidth, style: can.base.isIn(index, cli.XTERM, web.DESKTOP)? html.OUTPUT: "", title: index == web.DESKTOP? item.name: "", }, function(sub) { - sub.run = function(event, cmds, cb) { can.runAction(event, item.action, [item.cloud_uid, item.uid, index].concat(cmds), cb) } + sub.run = function(event, cmds, cb) { var msg = can.request(event); delete(msg.pod) + can.runAction(event, item.action, [item.cloud_uid, item.uid, index].concat(cmds), cb) + } can._plugins = (can._plugins||[]).concat(sub) }, can.ui.content) }) diff --git a/src/production/case.go b/src/production/case.go index c7f3334..628f051 100644 --- a/src/production/case.go +++ b/src/production/case.go @@ -9,7 +9,7 @@ import ( type Case struct { Table - order string `data:"3"` + order string `data:"4"` fields string `data:"title,content,case_status,process_time,finish_time,plan_uid,user_uid"` create string `name:"create title* content*" role:"leader,worker"` modify string `name:"modify title* content*" role:"leader,worker"` diff --git a/src/production/portal.json b/src/production/portal.json index 0ed5046..e03eb22 100644 --- a/src/production/portal.json +++ b/src/production/portal.json @@ -1,6 +1,6 @@ { "portal": "产品迭代", "member": "项目成员", - "plan": "迭代计划", "issue": "产品需求", "task": "开发任务", "case": "测试用例", + "plan": "迭代计划", "issue": "产品需求", "design": "界面设计", "task": "开发任务", "case": "测试用例", "planBind": "绑定计划", "process": "开始", "issueCreate": "创建需求", "taskCreate": "创建任务", "caseCreate": "创建用例", "style": { @@ -13,6 +13,7 @@ "icons": { "plan": "https://img.icons8.com/officel/80/timeline-week.png", "issue": "https://img.icons8.com/officel/80/communication.png", + "design": "https://img.icons8.com/officel/80/web-design.png", "task": "https://img.icons8.com/officel/80/tasks.png", "case": "https://img.icons8.com/officel/80/faq.png" }, diff --git a/src/production/task.go b/src/production/task.go index 645e6bf..f4bfeaf 100644 --- a/src/production/task.go +++ b/src/production/task.go @@ -10,7 +10,7 @@ import ( type task struct { Table Case Case - order string `data:"3"` + order string `data:"4"` fields string `data:"title,content,task_status,case_count,begin_time,end_time,process_time,finish_time,issue_uid,plan_uid,user_uid"` create string `name:"create title* content* begin_time:select@date end_time:select@date" role:"leader,worker"` modify string `name:"modify title* content* begin_time*:select@date end_time*:select@date" role:"leader,worker"` diff --git a/src/template/web.code.go/demo.go b/src/template/web.code.go/demo.go index be5ba81..88cf1e5 100644 --- a/src/template/web.code.go/demo.go +++ b/src/template/web.code.go/demo.go @@ -1,4 +1,4 @@ -package gonganxitong +package {{.Option "zone"}} import "shylinux.com/x/ice" diff --git a/usr/local/export/web.team.dashboard.portal/hash.json b/usr/local/export/web.team.dashboard.portal/hash.json index 21a3dc4..cb15fe8 100644 --- a/usr/local/export/web.team.dashboard.portal/hash.json +++ b/usr/local/export/web.team.dashboard.portal/hash.json @@ -103,7 +103,7 @@ "85e9ad5c568cceaa0aa273431f2cfcc2": { "meta": { "auth": "issued", - "icons": "https://img.icons8.com/officel/50/documents.png", + "icons": "https://img.icons8.com/officel/80/documents.png", "index": "web.team.dashboard.document", "name": "在线文档", "order": "93", @@ -176,7 +176,7 @@ "e3b889de9ace6b7f42008f8e0732effc": { "meta": { "auth": "issued", - "icons": "https://img.icons8.com/officel/50/ios-photos.png", + "icons": "https://img.icons8.com/officel/80/ios-photos.png", "index": "web.team.dashboard.photo", "name": "在线相册", "order": "95", diff --git a/usr/local/export/web.team.development.portal/hash.json b/usr/local/export/web.team.development.portal/hash.json index 65044a6..d89303a 100644 --- a/usr/local/export/web.team.development.portal/hash.json +++ b/usr/local/export/web.team.development.portal/hash.json @@ -89,7 +89,7 @@ "8922cdd711b3060411b079fa8f39ba72": { "meta": { "auth": "issued", - "icons": "https://img.icons8.com/officel/50/ios-photos.png", + "icons": "https://img.icons8.com/officel/80/ios-photos.png", "index": "web.team.development.photo", "name": "在线相册", "order": "95", @@ -180,7 +180,7 @@ "e347aded50c684b8e3118ba359a56039": { "meta": { "auth": "issued", - "icons": "https://img.icons8.com/officel/50/documents.png", + "icons": "https://img.icons8.com/officel/80/documents.png", "index": "web.team.development.document", "name": "在线文档", "order": "93", diff --git a/usr/local/export/web.team.gonganxitong.portal/hash.json b/usr/local/export/web.team.gonganxitong.portal/hash.json index 518da91..6afa4c4 100644 --- a/usr/local/export/web.team.gonganxitong.portal/hash.json +++ b/usr/local/export/web.team.gonganxitong.portal/hash.json @@ -21,7 +21,7 @@ "22574299a657140d473f0216b8d83710": { "meta": { "auth": "issued", - "icons": "https://img.icons8.com/officel/50/documents.png", + "icons": "https://img.icons8.com/officel/80/documents.png", "index": "web.team.gonganxitong.document", "name": "在线文档", "order": "93", @@ -73,7 +73,7 @@ "882a999b4a72a9866d9e4eef110d335a": { "meta": { "auth": "issued", - "icons": "https://img.icons8.com/officel/50/ios-photos.png", + "icons": "https://img.icons8.com/officel/80/ios-photos.png", "index": "web.team.gonganxitong.photo", "name": "在线相册", "order": "95", diff --git a/usr/local/export/web.team.guanlixitong.portal/hash.json b/usr/local/export/web.team.guanlixitong.portal/hash.json index 77a83f3..2e2db92 100644 --- a/usr/local/export/web.team.guanlixitong.portal/hash.json +++ b/usr/local/export/web.team.guanlixitong.portal/hash.json @@ -128,7 +128,7 @@ "8548d5ce3faee7bd508d2fb53d57f35b": { "meta": { "auth": "issued", - "icons": "https://img.icons8.com/officel/50/ios-photos.png", + "icons": "https://img.icons8.com/officel/80/ios-photos.png", "index": "web.team.guanlixitong.photo", "name": "在线相册", "order": "95", @@ -240,7 +240,7 @@ "e595a0bbefbcfaa89f45dd875cc6fe0b": { "meta": { "auth": "issued", - "icons": "https://img.icons8.com/officel/50/documents.png", + "icons": "https://img.icons8.com/officel/80/documents.png", "index": "web.team.guanlixitong.document", "name": "在线文档", "order": "93", diff --git a/usr/local/export/web.team.operation.portal/hash.json b/usr/local/export/web.team.operation.portal/hash.json index 4193c8d..f1de4c9 100644 --- a/usr/local/export/web.team.operation.portal/hash.json +++ b/usr/local/export/web.team.operation.portal/hash.json @@ -1,4 +1,15 @@ { + "03acc6ed03fa47e9639f1e5c459c3b50": { + "meta": { + "auth": "issued", + "icons": "https://img.icons8.com/officel/80/activity-grid.png", + "index": "web.team.operation.template", + "name": "云模板", + "order": "2", + "role": "leader,worker", + "time": "2025-03-14 20:51:15.546" + } + }, "03f7f410d292fb30026cbcd99290e943": { "meta": { "auth": "issued", @@ -48,7 +59,7 @@ "icons": "https://img.icons8.com/officel/80/activity-grid.png", "index": "web.team.operation.product", "name": "云服务", - "order": "4", + "order": "5", "time": "2025-03-05 10:40:39.748" } }, @@ -80,7 +91,7 @@ "icons": "https://img.icons8.com/officel/80/activity-grid.png", "index": "web.team.operation.project", "name": "云项目", - "order": "3", + "order": "4", "role": "leader,worker", "time": "2025-03-05 10:40:39.740" } @@ -99,7 +110,7 @@ "meta": { "auth": "issued", "enable": "false", - "icons": "https://img.icons8.com/officel/50/ios-photos.png", + "icons": "https://img.icons8.com/officel/80/ios-photos.png", "index": "web.team.operation.photo", "name": "在线相册", "order": "95", @@ -171,7 +182,7 @@ "icons": "https://img.icons8.com/officel/80/activity-grid.png", "index": "web.team.operation.gateway", "name": "云主机", - "order": "2", + "order": "3", "portal": "true", "time": "2025-03-05 12:13:06.405" } @@ -180,7 +191,7 @@ "meta": { "auth": "issued", "enable": "false", - "icons": "https://img.icons8.com/officel/50/documents.png", + "icons": "https://img.icons8.com/officel/80/documents.png", "index": "web.team.operation.document", "name": "在线文档", "order": "93", diff --git a/usr/local/export/web.team.production.portal/hash.json b/usr/local/export/web.team.production.portal/hash.json index f4c9cb5..97616ed 100644 --- a/usr/local/export/web.team.production.portal/hash.json +++ b/usr/local/export/web.team.production.portal/hash.json @@ -98,10 +98,19 @@ "time": "2024-09-03 15:44:28.507" } }, + "73b81840f26d2885c065d19e08e923f1": { + "meta": { + "icons": "https://img.icons8.com/officel/80/web-design.png", + "index": "web.team.production.design", + "name": "界面设计", + "order": "3", + "time": "2025-03-21 08:49:22.166" + } + }, "7cf76afacb83fabb3d6a6ffaf48b6066": { "meta": { "auth": "issued", - "icons": "https://img.icons8.com/officel/50/documents.png", + "icons": "https://img.icons8.com/officel/80/documents.png", "index": "web.team.production.document", "name": "在线文档", "order": "93", @@ -180,7 +189,7 @@ "c9559beab992f8b46b9cfa4a196e61e8": { "meta": { "auth": "issued", - "icons": "https://img.icons8.com/officel/50/ios-photos.png", + "icons": "https://img.icons8.com/officel/80/ios-photos.png", "index": "web.team.production.photo", "name": "在线相册", "order": "95", diff --git a/usr/local/export/web.team.renzhengshouquan.portal/hash.json b/usr/local/export/web.team.renzhengshouquan.portal/hash.json index ce8b58c..36a446c 100644 --- a/usr/local/export/web.team.renzhengshouquan.portal/hash.json +++ b/usr/local/export/web.team.renzhengshouquan.portal/hash.json @@ -2,7 +2,7 @@ "015b4784c16b63975824abbb3ff4ec9f": { "meta": { "auth": "issued", - "icons": "https://img.icons8.com/officel/50/ios-photos.png", + "icons": "https://img.icons8.com/officel/80/ios-photos.png", "index": "web.team.renzhengshouquan.photo", "name": "在线相册", "order": "95", @@ -23,7 +23,7 @@ "1c4fee90e6a7bdb8ab6f1ccb23f3273f": { "meta": { "auth": "issued", - "icons": "https://img.icons8.com/officel/50/documents.png", + "icons": "https://img.icons8.com/officel/80/documents.png", "index": "web.team.renzhengshouquan.document", "name": "在线文档", "order": "93", diff --git a/usr/local/export/web.team.storage.portal/hash.json b/usr/local/export/web.team.storage.portal/hash.json index eecad9e..86059a4 100644 --- a/usr/local/export/web.team.storage.portal/hash.json +++ b/usr/local/export/web.team.storage.portal/hash.json @@ -129,7 +129,7 @@ "ceaca87cf0d112aec124ad24298e189e": { "meta": { "auth": "issued", - "icons": "https://img.icons8.com/officel/50/ios-photos.png", + "icons": "https://img.icons8.com/officel/80/ios-photos.png", "index": "web.team.storage.photo", "name": "在线相册", "order": "95", @@ -190,7 +190,7 @@ "f6f77c7a5e247a742c2699564c4507a1": { "meta": { "auth": "issued", - "icons": "https://img.icons8.com/officel/50/documents.png", + "icons": "https://img.icons8.com/officel/80/documents.png", "index": "web.team.storage.document", "name": "在线文档", "order": "93",