diff --git a/src/components/entity/Entity.vue b/src/components/entity/Entity.vue
new file mode 100644
index 00000000..483d54f6
--- /dev/null
+++ b/src/components/entity/Entity.vue
@@ -0,0 +1,55 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/components/entity/EntityField.vue b/src/components/entity/EntityField.vue
new file mode 100644
index 00000000..9fb40fc7
--- /dev/null
+++ b/src/components/entity/EntityField.vue
@@ -0,0 +1,54 @@
+
+
+
+
+
+
+
+
+ {{ title }}
+
+
+ {{ title }}
+
+
+
+
+
+
+
+
+ {{ description }}
+
+
+
+
+
diff --git a/src/modules/contents/attachments/AttachmentList.vue b/src/modules/contents/attachments/AttachmentList.vue
index 3eafb259..30317bc4 100644
--- a/src/modules/contents/attachments/AttachmentList.vue
+++ b/src/modules/contents/attachments/AttachmentList.vue
@@ -7,7 +7,6 @@ import {
IconDatabase2Line,
IconGrid,
IconList,
- IconSettings,
IconUpload,
VButton,
VCard,
@@ -36,6 +35,8 @@ import cloneDeep from "lodash.clonedeep";
import { isImage } from "@/utils/image";
import { useRouteQuery } from "@vueuse/router";
import { useFetchAttachmentGroup } from "./composables/use-attachment-group";
+import Entity from "@/components/entity/Entity.vue";
+import EntityField from "@/components/entity/EntityField.vue";
const policyVisible = ref(false);
const uploadVisible = ref(false);
@@ -555,47 +556,35 @@ onMounted(() => {
role="list"
>
-
-
-
-
-
-
-
-
-
-
-
- {{ getPolicyName(attachment.spec.policyRef?.name) }}
-
+
+
+
+
+
+
+
-
- {{ attachment.spec.uploadedBy?.name }}
-
+ {{ attachment.spec.uploadedBy?.name }}
-
+
+
+
+
-
-
-
-
删除中
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+ 删除
+
+
diff --git a/src/modules/contents/pages/FunctionalPageList.vue b/src/modules/contents/pages/FunctionalPageList.vue
index 39a8b152..7fe9bfc4 100644
--- a/src/modules/contents/pages/FunctionalPageList.vue
+++ b/src/modules/contents/pages/FunctionalPageList.vue
@@ -3,6 +3,8 @@ import { ref } from "vue";
import { VEmpty, VSpace, VButton, IconAddCircle } from "@halo-dev/components";
import type { PagesPublicState } from "@halo-dev/admin-shared";
import { useExtensionPointsState } from "@/composables/usePlugins";
+import Entity from "@/components/entity/Entity.vue";
+import EntityField from "@/components/entity/EntityField.vue";
const pagesPublicState = ref({
functionalPages: [],
@@ -38,27 +40,15 @@ useExtensionPointsState("PAGES", pagesPublicState);
:key="index"
v-permission="page.permissions"
>
-
-
-
-
-
- {{ page.name }}
-
-
-
-
- {{ page.url }}
-
-
-
-
-
+
+
+
+
+
diff --git a/src/modules/contents/pages/SinglePageList.vue b/src/modules/contents/pages/SinglePageList.vue
index 56e3f675..fc40001a 100644
--- a/src/modules/contents/pages/SinglePageList.vue
+++ b/src/modules/contents/pages/SinglePageList.vue
@@ -3,7 +3,6 @@ import {
IconArrowDown,
IconArrowLeft,
IconArrowRight,
- IconSettings,
IconEye,
IconEyeOff,
IconTeam,
@@ -30,6 +29,8 @@ import { apiClient } from "@halo-dev/admin-shared";
import { formatDatetime } from "@/utils/date";
import { RouterLink } from "vue-router";
import cloneDeep from "lodash.clonedeep";
+import Entity from "../../../components/entity/Entity.vue";
+import EntityField from "../../../components/entity/EntityField.vue";
enum SinglePagePhase {
DRAFT = "未发布",
@@ -332,68 +333,47 @@ const handleSelectUser = (user?: User) => {
role="list"
>
-
-
-
-
-
-
-
-
-
-
- {{ singlePage.page.status?.permalink }}
-
-
-
-
-
+
+
+
+
+
+
+
+
+
- {{ finalStatus(singlePage.page) }}
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- 设置
-
-
- 删除
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 设置
+
+
+ 删除
+
+
+
diff --git a/src/modules/contents/posts/PostList.vue b/src/modules/contents/posts/PostList.vue
index daa24466..03cb69bf 100644
--- a/src/modules/contents/posts/PostList.vue
+++ b/src/modules/contents/posts/PostList.vue
@@ -7,7 +7,6 @@ import {
IconBookRead,
IconEye,
IconEyeOff,
- IconSettings,
IconTeam,
IconCloseCircle,
useDialog,
@@ -21,6 +20,8 @@ import {
} from "@halo-dev/components";
import UserDropdownSelector from "@/components/dropdown-selector/UserDropdownSelector.vue";
import PostSettingModal from "./components/PostSettingModal.vue";
+import Entity from "@/components/entity/Entity.vue";
+import EntityField from "@/components/entity/EntityField.vue";
import PostTag from "../posts/tags/components/PostTag.vue";
import { onMounted, ref, watch, watchEffect } from "vue";
import type {
@@ -738,64 +739,43 @@ function handleContributorFilterItemChange(user?: User) {
role="list"
>
-
-
-
-
-
-
-
-
-
-
- {{ post.post.spec.title }}
-
-
+
+
+
+
+
+
+
-
-
-
-
-
-
-
- 当前有内容已保存,但还未发布。
-
-
+
+
+
-
-
-
-
-
+
+
+
+
+
+
-
- {{ finalStatus(post.post) }}
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- 设置
-
-
- 删除
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 设置
+
+
+ 删除
+
+
+
diff --git a/src/modules/contents/posts/categories/components/CategoryListItem.vue b/src/modules/contents/posts/categories/components/CategoryListItem.vue
index 31aa1349..002db8cc 100644
--- a/src/modules/contents/posts/categories/components/CategoryListItem.vue
+++ b/src/modules/contents/posts/categories/components/CategoryListItem.vue
@@ -1,9 +1,11 @@
-
-
-
-
-
-
-
- {{ plugin?.spec.displayName }}
-
-
+
+
+
+
{{ isStarted ? "已启用" : "未启用" }}
-
-
-
-
- {{ plugin?.spec.description }}
-
-
- @{{ plugin?.spec.author }} {{ plugin?.spec.version }}
-
-
-
-
-
-
-
+
+
+
+
+
+
-
-
-
-
- {{ plugin?.status?.reason }}:
- {{ plugin?.status?.message }}
-
-
+
+
+
+
+
+
@{{ plugin?.spec.author }}
-
- {{ plugin?.spec.version }}
-
-
+
+
+
+
+
+
-
-
-
-
-
-
-
- 卸载
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+ 卸载
+
+
+
diff --git a/src/modules/system/roles/RoleList.vue b/src/modules/system/roles/RoleList.vue
index 70a51718..29bd86b5 100644
--- a/src/modules/system/roles/RoleList.vue
+++ b/src/modules/system/roles/RoleList.vue
@@ -7,7 +7,6 @@ import type { Role } from "@halo-dev/api-client";
import {
IconAddCircle,
IconArrowDown,
- IconSettings,
IconShieldUser,
useDialog,
VButton,
@@ -18,6 +17,8 @@ import {
VTag,
} from "@halo-dev/components";
import RoleEditingModal from "./components/RoleEditingModal.vue";
+import Entity from "@/components/entity/Entity.vue";
+import EntityField from "@/components/entity/EntityField.vue";
// constants
import { rbacAnnotations } from "@/constants/annotations";
@@ -199,114 +200,75 @@ const handleDelete = async (role: Role) => {
-
-
-
-
-
-
-
- {{
- role.metadata.annotations?.[
- rbacAnnotations.DISPLAY_NAME
- ] || role.metadata.name
- }}
-
-
-
-
-
- 包含
- {{
+
+
+
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
系统保留
-
-
-
-
-
-
-
-
- 编辑
-
-
- 删除
-
-
- 基于此角色创建
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+ 编辑
+
+
+ 删除
+
+
+ 基于此角色创建
+
+
+
diff --git a/src/modules/system/users/UserList.vue b/src/modules/system/users/UserList.vue
index e9d8a929..69a849e5 100644
--- a/src/modules/system/users/UserList.vue
+++ b/src/modules/system/users/UserList.vue
@@ -2,7 +2,6 @@
import {
IconAddCircle,
IconArrowDown,
- IconSettings,
IconUserFollow,
IconUserSettings,
VButton,
@@ -21,6 +20,8 @@ import type { User, UserList } from "@halo-dev/api-client";
import { rbacAnnotations } from "@/constants/annotations";
import { formatDatetime } from "@/utils/date";
import { useRouteQuery } from "@vueuse/router";
+import Entity from "@/components/entity/Entity.vue";
+import EntityField from "@/components/entity/EntityField.vue";
const checkAll = ref(false);
const editingModal = ref(false);
@@ -275,104 +276,70 @@ onMounted(() => {
-
-
-
-
-
-
-
-
-
-
-
-
-
- {{ user.spec.displayName }}
-
- {{ user.metadata.name }}
-
-
-
-
- {{ user.metadata.name }}
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
{{ role }}
-
-
-
-
-
-
-
-
- 修改资料
-
-
- 修改密码
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+ 修改资料
+
+
+ 修改密码
+
+
+