mirror of
https://github.com/certd/certd.git
synced 2026-04-23 19:57:27 +08:00
chore: project userid fixed -1
This commit is contained in:
@@ -220,6 +220,7 @@ export default {
|
||||
myProjectDetail: "Project Detail",
|
||||
projectJoin: "Join Project",
|
||||
currentProject: "Current Project",
|
||||
projectMemberManager: "Project Member",
|
||||
},
|
||||
certificateRepo: {
|
||||
title: "Certificate Repository",
|
||||
@@ -822,6 +823,9 @@ export default {
|
||||
admin: "Admin",
|
||||
},
|
||||
projectMemberStatus: "Member Status",
|
||||
|
||||
isSystem: "Is System Project",
|
||||
isSystemHelper: "System-level projects allow running admin plugins",
|
||||
},
|
||||
project: {
|
||||
noProjectJoined: "You haven't joined any projects yet",
|
||||
|
||||
@@ -220,12 +220,12 @@ export default {
|
||||
netTest: "网络测试",
|
||||
enterpriseManager: "企业管理设置",
|
||||
projectManager: "项目管理",
|
||||
projectDetail: "项目详情",
|
||||
enterpriseSetting: "企业设置",
|
||||
myProjectManager: "我的项目",
|
||||
myProjectDetail: "项目详情",
|
||||
projectJoin: "加入项目",
|
||||
currentProject: "当前项目",
|
||||
projectMemberManager: "项目成员管理",
|
||||
},
|
||||
certificateRepo: {
|
||||
title: "证书仓库",
|
||||
@@ -838,6 +838,9 @@ export default {
|
||||
admin: "管理员",
|
||||
},
|
||||
projectMemberStatus: "成员状态",
|
||||
|
||||
isSystem: "是否系统项目",
|
||||
isSystemHelper: "系统级项目允许运行管理员插件",
|
||||
},
|
||||
project: {
|
||||
noProjectJoined: "您还没有加入任何项目",
|
||||
|
||||
@@ -29,21 +29,6 @@ export const certdResources = [
|
||||
auth: true,
|
||||
},
|
||||
},
|
||||
{
|
||||
title: "certd.sysResources.currentProject",
|
||||
name: "CurrentProject",
|
||||
path: "/certd/project/detail",
|
||||
component: "/certd/project/detail/index.vue",
|
||||
meta: {
|
||||
show: () => {
|
||||
const projectStore = useProjectStore();
|
||||
return projectStore.isEnterprise;
|
||||
},
|
||||
isMenu: true,
|
||||
icon: "ion:apps",
|
||||
auth: true,
|
||||
},
|
||||
},
|
||||
{
|
||||
title: "certd.sysResources.projectJoin",
|
||||
name: "ProjectJoin",
|
||||
@@ -278,6 +263,21 @@ export const certdResources = [
|
||||
isMenu: false,
|
||||
},
|
||||
},
|
||||
{
|
||||
title: "certd.sysResources.projectMemberManager",
|
||||
name: "ProjectMemberManager",
|
||||
path: "/certd/project/detail",
|
||||
component: "/certd/project/detail/index.vue",
|
||||
meta: {
|
||||
show: () => {
|
||||
const projectStore = useProjectStore();
|
||||
return projectStore.isEnterprise;
|
||||
},
|
||||
isMenu: true,
|
||||
icon: "ion:apps",
|
||||
auth: true,
|
||||
},
|
||||
},
|
||||
],
|
||||
},
|
||||
{
|
||||
|
||||
@@ -143,7 +143,7 @@ export default function ({ crudExpose, context }: CreateCrudOptionsProps): Creat
|
||||
order: 10,
|
||||
},
|
||||
valueBuilder: ({ row, key, value }) => {
|
||||
row[key] = row.userId > 0 ? "user" : "sys";
|
||||
row[key] = row.userId != 0 ? "user" : "sys";
|
||||
},
|
||||
},
|
||||
...commonColumnsDefine,
|
||||
|
||||
@@ -121,7 +121,7 @@ export default function ({ crudExpose, context }: CreateCrudOptionsProps): Creat
|
||||
order: 10,
|
||||
},
|
||||
valueBuilder: ({ row, key, value }) => {
|
||||
row[key] = row.userId > 0 ? "user" : "sys";
|
||||
row[key] = row.userId != 0 ? "user" : "sys";
|
||||
},
|
||||
},
|
||||
...commonColumnsDefine,
|
||||
|
||||
@@ -90,35 +90,21 @@ export default function ({ crudExpose, context }: CreateCrudOptionsProps): Creat
|
||||
},
|
||||
},
|
||||
},
|
||||
disabled: {
|
||||
title: t("certd.disabled"),
|
||||
isSystem: {
|
||||
title: t("certd.ent.isSystem"),
|
||||
type: "dict-switch",
|
||||
dict: dict({
|
||||
data: [
|
||||
{ label: t("certd.enabled"), value: false, color: "success" },
|
||||
{ label: t("certd.disabledLabel"), value: true, color: "error" },
|
||||
{ label: t("common.yes"), value: true, color: "success" },
|
||||
{ label: t("common.no"), value: false, color: "error" },
|
||||
],
|
||||
}),
|
||||
form: {
|
||||
value: false,
|
||||
value: true,
|
||||
helper: t("certd.ent.isSystemHelper"),
|
||||
},
|
||||
column: {
|
||||
width: 100,
|
||||
component: {
|
||||
title: t("certd.clickToToggle"),
|
||||
on: {
|
||||
async click({ value, row }) {
|
||||
Modal.confirm({
|
||||
title: t("certd.prompt"),
|
||||
content: t("certd.confirmToggleStatus", { action: !value ? t("certd.disable") : t("certd.enable") }),
|
||||
onOk: async () => {
|
||||
await api.SetDisabled(row.id, !value);
|
||||
await crudExpose.doRefresh();
|
||||
},
|
||||
});
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
adminId: {
|
||||
|
||||
Reference in New Issue
Block a user