feat: 迁移 Vue3 + Vite + view-ui-plus(对齐 NoticeFront 框架)
- 构建:Vue CLI 4 → Vite 5,入口迁至根 index.html(含 env-config + 主题通道 loader)
- 技术栈:Vue 2.6 → Vue 3.4,view-design → view-ui-plus 1.3.24,vue-router 3 → 4(hash)
- 壳层重写:App.vue / components/layout.vue 对齐 Notice 骨架(logo-badge、icon-* 通道图标、resolveMenuPage、crumb-home 基线)
- 机械转换:具名 slot → template #x、.sync → v-model:、@click.native、$set、beforeDestroy、/deep/ → :deep()
- render:h('Button')/h('Input') → 真组件 + 扁平 props/onClick
- 组件适配:vuedraggable 4 的 #item 插槽;vue-treeselect → @zanmato/vue3-treeselect;Page 分页改 v-model + pageSize 显式回写
- 清理:删除 Vue2 死代码(layout_old/bak/child、App.Net、codeModal、未引用组件)
- 修复:深链接首次加载被重定向到首个模块(router.isReady)
验证:vite build 通过;headless CDP 全 15 路由无异常;教师列表 2 行渲染、操作列按钮点击弹窗正常。
This commit is contained in:
@@ -51,7 +51,7 @@
|
||||
<div class="page-area">
|
||||
<span style="margin-right: 12px">共 {{ total }} 条</span>
|
||||
<Page
|
||||
:current.sync="pageNum"
|
||||
v-model="pageNum"
|
||||
:page-size="pageSize"
|
||||
:total="total"
|
||||
:page-size-opts="[10,20,40]"
|
||||
@@ -74,15 +74,16 @@
|
||||
<my-tree :treeData="targetTreeData" @on-tree-click="treeLink"></my-tree>
|
||||
</div>
|
||||
</div>
|
||||
<div slot="footer" align="right">
|
||||
<template #footer><div align="right">
|
||||
<Button @click="moveModalVisible = false">取消</Button>
|
||||
<Button type="primary" @click="submitMove">提交</Button>
|
||||
</div>
|
||||
</div></template>
|
||||
</Modal>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { Button } from "view-ui-plus";
|
||||
import myTree from "../../components/my_tree";
|
||||
import { self_viewport } from "@/mixins/self_viewport";
|
||||
export default {
|
||||
@@ -183,10 +184,8 @@ export default {
|
||||
align: 'center',
|
||||
width: 100,
|
||||
render: (h, params) => {
|
||||
return h('Button', {
|
||||
props: { type: 'text' },
|
||||
on: { click: () => this.openMoveModal(params.row) }
|
||||
},'转入')
|
||||
return h(Button, {type: 'text',
|
||||
onClick: () => this.openMoveModal(params.row)},'转入')
|
||||
}
|
||||
}
|
||||
]
|
||||
@@ -320,7 +319,7 @@ export default {
|
||||
flex: 1;
|
||||
min-height: 0;
|
||||
}
|
||||
.table-scroll-wrap >>> .ivu-table {
|
||||
.table-scroll-wrap :deep(.ivu-table) {
|
||||
height: 100%;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user