数据使用页面部分开发
Showing
3 changed files
with
81 additions
and
1 deletions
| ... | @@ -44,6 +44,25 @@ const routes: RouteRecordRaw[] = [ | ... | @@ -44,6 +44,25 @@ const routes: RouteRecordRaw[] = [ |
| 44 | cache: true | 44 | cache: true |
| 45 | }, | 45 | }, |
| 46 | }, | 46 | }, |
| 47 | { | ||
| 48 | path: 'data-usage-detail', | ||
| 49 | name: 'dataUsageDetail', | ||
| 50 | component: () => import('@/views/data_asset/dataUsageDetail.vue'), | ||
| 51 | meta: { | ||
| 52 | title: '详情-', | ||
| 53 | sidebar: false, | ||
| 54 | breadcrumb: false, | ||
| 55 | cache: true, | ||
| 56 | editPage: true, | ||
| 57 | reuse: true | ||
| 58 | }, | ||
| 59 | beforeEnter: (to, from) => { | ||
| 60 | if (to.query.name) { | ||
| 61 | to.meta.title = `详情-${to.query.name}`; | ||
| 62 | return; | ||
| 63 | } | ||
| 64 | } | ||
| 65 | } | ||
| 47 | ], | 66 | ], |
| 48 | }, | 67 | }, |
| 49 | ] | 68 | ] | ... | ... |
| ... | @@ -159,4 +159,8 @@ onBeforeMount(() => { | ... | @@ -159,4 +159,8 @@ onBeforeMount(() => { |
| 159 | </div> | 159 | </div> |
| 160 | </template> | 160 | </template> |
| 161 | 161 | ||
| 162 | <style lang="scss" scoped></style> | ||
| ... | \ No newline at end of file | ... | \ No newline at end of file |
| 162 | <style lang="scss" scoped> | ||
| 163 | .container_wrap { | ||
| 164 | padding: 0px 16px; | ||
| 165 | } | ||
| 166 | </style> | ||
| ... | \ No newline at end of file | ... | \ No newline at end of file | ... | ... |
src/views/data_asset/dataUsageDetail.vue
0 → 100644
| 1 | <script lang="ts" setup name="dataUsageDetail"> | ||
| 2 | import { changeNum } from '@/utils/common'; | ||
| 3 | |||
| 4 | |||
| 5 | const fullscreenloading = ref(false); | ||
| 6 | |||
| 7 | const tableInfo = ref({ | ||
| 8 | id: 'dataset-table', | ||
| 9 | rowKey: 'guid', | ||
| 10 | loading: false, | ||
| 11 | fields: [ { label: "序号", type: "index", width: 56, align: "center" }, | ||
| 12 | { label: "表中文名称", field: "tableChName", width: 150, align: "left" }, | ||
| 13 | { label: "表英文名称", field: "tableName", width: 150, align: "left" }, | ||
| 14 | { | ||
| 15 | label: "表数据总数(条)", field: "dataCount", width: 150, align: "right", getName: (scope) => { | ||
| 16 | return scope.row["dataCount"] == null ? '--' : changeNum(scope.row["dataCount"], 0) | ||
| 17 | } | ||
| 18 | }, | ||
| 19 | { label: "描述", field: "description", width: 240 }, | ||
| 20 | { label: "修改人", field: "updateUserName", width: 140 }, | ||
| 21 | { label: "修改时间", field: "updateTime", width: 180 },], | ||
| 22 | data: [], | ||
| 23 | showPage: false, | ||
| 24 | actionInfo: { | ||
| 25 | label: "操作", | ||
| 26 | type: "btn", | ||
| 27 | width: 160, | ||
| 28 | btns: (scope) => { | ||
| 29 | let btns: any = []; | ||
| 30 | //TODO。根据返回值显示按钮 | ||
| 31 | btns.push({ label: '查看', value: 'view' }); | ||
| 32 | return btns; | ||
| 33 | } | ||
| 34 | } | ||
| 35 | }); | ||
| 36 | |||
| 37 | onBeforeMount(() => { | ||
| 38 | |||
| 39 | }) | ||
| 40 | |||
| 41 | </script> | ||
| 42 | |||
| 43 | <template> | ||
| 44 | <div class="container_wrap" v-loading="fullscreenloading"> | ||
| 45 | <div class="table_panel_wrap" style="height: calc(100% - 44px);"> | ||
| 46 | <Table :tableInfo="tableInfo" /> | ||
| 47 | </div> | ||
| 48 | </div> | ||
| 49 | </template> | ||
| 50 | |||
| 51 | <style lang="scss" scoped> | ||
| 52 | |||
| 53 | .container_wrap { | ||
| 54 | padding: 0px 16px; | ||
| 55 | } | ||
| 56 | |||
| 57 | </style> | ||
| ... | \ No newline at end of file | ... | \ No newline at end of file |
-
Please register or sign in to post a comment