Merge branch 'dev-3.10' of git.mesalab.cn:nezha/nezha-fronted into dev-3.10

This commit is contained in:
zyh
2024-05-28 10:00:09 +08:00
66 changed files with 3728 additions and 3 deletions

View File

@@ -40,7 +40,62 @@ export const sidebar = {
},
]
},
{
text: 'table',
link: '/table',
items: [
{
text: 'nzDataList',
link: '/nzDataList',
items:[
{text:'searchBox', link: '/searchBox'},
{text:'searchInput', link: '/searchInput'},
{text:'bottomBox', link: '/bottomBox'},
]
},
{ text: 'nzDetailView', link: '/nzDetailView',},
{ text: 'deleteButton', link: '/deleteButton',},
{ text: 'rightBox', link: '/rightBox',},
]
}
],
},
{
text: '其他组件',
items:[
{text:'clickSearch', link: '/clickSearch'},
{text:'promqlInput', link: '/promqlInput'},
{
text:'pickTime',
link: '/pickTime',
items: [
{text:'multipleTime', link: '/multipleTime'}
]
},
]
},
{
text: '引用插件',
items:[
{text:'le5le', link: '/le5le'},
{text:'map', link: '/map'},
{text:'xterm', link: '/xterm'},
{text:'时间插件', link: '/time'},
{text:'Quill', link: '/quill'},
{text:'D3', link: '/d3'},
{text:'selectpage', link: '/selectpage'},
]
},
{
text: '注意事项',
link: '/note',
items: [
{text:'dashboard 流程'},
{text:'主题简单使用教程'},
{text:'国际化使用教程'},
]
}
],
};

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@@ -61,5 +61,6 @@ const props = withDefaults(defineProps<{
<template>
<div>
</div>
</template>

View File

@@ -0,0 +1,14 @@
---
map:
path: /d3
---
基于svg的可视化插件
# 官方地址
https://observablehq.com/@d3/gallery?utm_source=d3js-org&utm_medium=nav&utm_campaign=try-observable
<API src="./index.vue" lang="en"></API>

View File

@@ -0,0 +1,12 @@
<script lang="ts" setup>
const props = withDefaults(defineProps<{
}>(), {
})
</script>
<template>
<div>
</div>
</template>

View File

@@ -0,0 +1,14 @@
---
map:
path: /d3
---
基于svg的可视化插件
# 官方地址
https://observablehq.com/@d3/gallery?utm_source=d3js-org&utm_medium=nav&utm_campaign=try-observable
<API src="./index.vue" lang="en"></API>

View File

@@ -0,0 +1,32 @@
---
map:
path: /le5le
---
拓扑图
# 官方文档
https://doc.le5le.com/document/119882449
# 注意事项
1. 图片在本地无法显示,若需要显示 可以在图片url前添加对应的网址
2. 鼠标框选错位
原因
父 dom 元素 css 还没渲染完就加载画布确认方式new Meta2d 时,查看父 dom 的 clientWidth 和 clientHeight 是否存在;
修改了父 dom 元素位置,可能是存在动画
解决方案
等待父 dom 元素 css 加载完成后在 new Meta2d
确定画布位置已经稳定时,修正画布位置: meta2d.resize();
3. 报错pen无calculative属性
是否使用了 meta2d.data() 获取的pens进行操作 meta2d.data() 仅仅用于文件保存。改用 meta2d.store.data.pens 获取画布中的对象即可。
<API src="./index.vue" lang="en"></API>

View File

@@ -0,0 +1,12 @@
<script lang="ts" setup>
const props = withDefaults(defineProps<{
}>(), {
})
</script>
<template>
<div>
</div>
</template>

View File

@@ -0,0 +1,32 @@
---
map:
path: /le5le
---
拓扑图
# 官方文档
https://doc.le5le.com/document/119882449
# 注意事项
1. 图片在本地无法显示,若需要显示 可以在图片url前添加对应的网址
2. 鼠标框选错位
原因
父 dom 元素 css 还没渲染完就加载画布确认方式new Meta2d 时,查看父 dom 的 clientWidth 和 clientHeight 是否存在;
修改了父 dom 元素位置,可能是存在动画
解决方案
等待父 dom 元素 css 加载完成后在 new Meta2d
确定画布位置已经稳定时,修正画布位置: meta2d.resize();
3. 报错pen无calculative属性
是否使用了 meta2d.data() 获取的pens进行操作 meta2d.data() 仅仅用于文件保存。改用 meta2d.store.data.pens 获取画布中的对象即可。
<API src="./index.vue" lang="zh"></API>

View File

@@ -0,0 +1,24 @@
---
map:
path: /map
---
地图插件
# 官方文档
api: https://maplibre.org/maplibre-gl-js/docs/API/
examples: https://maplibre.org/maplibre-gl-js/docs/examples/
style: https://cloud.maptiler.com/auth/widget?next=https://cloud.maptiler.com/maps/
# 注意事项
1. 开发时可以先参考examples找到对应的例子 再通过api查看详细设置
2. 地图样式支持配置 需要登陆 maptilerCloud 注册对应账号 即可查看
3. 修改样式可以在 cloud 编辑对应样式 左侧页面查看 之后保存对应的json
4. 注意引用时 新增一些图层可能需要新的外部文件
<API src="./index.vue" lang="en"></API>

View File

@@ -0,0 +1,12 @@
<script lang="ts" setup>
const props = withDefaults(defineProps<{
}>(), {
})
</script>
<template>
<div>
</div>
</template>

View File

@@ -0,0 +1,24 @@
---
map:
path: /map
---
地图插件
# 官方文档
api: https://maplibre.org/maplibre-gl-js/docs/API/
examples: https://maplibre.org/maplibre-gl-js/docs/examples/
style: https://cloud.maptiler.com/auth/widget?next=https://cloud.maptiler.com/maps/
# 注意事项
1. 开发时可以先参考examples找到对应的例子 再通过api查看详细设置
2. 地图样式支持配置 需要登陆 maptilerCloud 注册对应账号 即可查看
3. 修改样式可以在 cloud 编辑对应样式 左侧页面查看 之后保存对应的json
4. 注意引用时 新增一些图层可能需要新的外部文件
<API src="./index.vue" lang="en"></API>

View File

@@ -0,0 +1,14 @@
---
map:
path: /quill
---
富文本
# 官方地址
https://github.com/quilljs/quill
<API src="./index.vue" lang="en"></API>

View File

@@ -0,0 +1,12 @@
<script lang="ts" setup>
const props = withDefaults(defineProps<{
}>(), {
})
</script>
<template>
<div>
</div>
</template>

View File

@@ -0,0 +1,12 @@
---
map:
path: /quill
---
富文本
# 官方地址
https://github.com/quilljs/quill
<API src="./index.vue" lang="zh"></API>

View File

@@ -0,0 +1,15 @@
---
map:
path: /selectpage
---
下拉选择组件
# 官方地址
https://github.com/TerryZ/v-selectpage/tree/dev-vue-2
# 注意事项
因多选选择以及回显有问题 已将源码复制到本地并修改

View File

@@ -0,0 +1,12 @@
<script lang="ts" setup>
const props = withDefaults(defineProps<{
}>(), {
})
</script>
<template>
<div>
</div>
</template>

View File

@@ -0,0 +1,14 @@
---
map:
path: /selectpage
---
下拉选择组件
# 官方地址
https://github.com/TerryZ/v-selectpage/tree/dev-vue-2
# 注意事项
因多选选择以及回显有问题 已将源码复制到本地并修改

View File

@@ -0,0 +1,13 @@
---
map:
path: /time
---
# 官方地址
https://momentjs.com/timezone/
# 注意事项
使用时建议全部转化为时间戳
<API src="./index.vue" lang="en"></API>

View File

@@ -0,0 +1,12 @@
<script lang="ts" setup>
const props = withDefaults(defineProps<{
}>(), {
})
</script>
<template>
<div>
</div>
</template>

View File

@@ -0,0 +1,13 @@
---
map:
path: /time
---
# 官方地址
https://momentjs.com/timezone/
# 注意事项
使用时建议全部转化为时间戳
<API src="./index.vue" lang="zh"></API>

View File

@@ -0,0 +1,17 @@
---
map:
path: /xterm
---
前端shell
# 官方地址
https://xtermjs.org/
# 注意事项
api 可以在xterm.js 的 TypeScript 声明文件中找到
宽高必须计算好 否则会导致换行错误
<API src="./index.vue" lang="en"></API>

View File

@@ -0,0 +1,12 @@
<script lang="ts" setup>
const props = withDefaults(defineProps<{
}>(), {
})
</script>
<template>
<div>
</div>
</template>

View File

@@ -0,0 +1,17 @@
---
map:
path: /xterm
---
前端shell
# 官方地址
https://xtermjs.org/
# 注意事项
api 可以在xterm.js 的 TypeScript 声明文件中找到
宽高必须计算好 否则会导致换行错误
<API src="./index.vue" lang="zh"></API>

View File

@@ -0,0 +1,6 @@
---
map:
path: /note
---

View File

@@ -0,0 +1,12 @@
<script lang="ts" setup>
const props = withDefaults(defineProps<{
}>(), {
})
</script>
<template>
<div>
</div>
</template>

View File

@@ -0,0 +1,17 @@
---
map:
path: /note
---
1. 图表类型新增 需要后端增加相应的类型<br>
2. 新增颜色类型相关的样式 需要同事增加两个主题色 或者使用原有主题色 <br>
位置<br> src/assets/css/themes/theme-dark.scss <br> src/assets/css/themes/theme-light.scss<br>
3. 国际化更改后需要跟告知后端 后端需要更新相应数据库<br>
4. 图表相关的国际化 需要保存到本地 或者一直维持最新避免快照国际化错误<br>
5. 快照图标需要转化为base64才能显示对应图标。 所以iconfont 需要将相应内容转化为base64 <br>
6. 搜索框新增查询条件时 无法回显 需要查看 routerPathParams.js 以及 查看 datalist.js 的 created <br>位置<br> /src/components/common/mixin<br>
7. element-ui 的表格组件的气泡组件不建议使用 容易引起表格卡顿 建议换为一个弹窗组件 传对应的实例完成<br>
8.

View File

@@ -0,0 +1,9 @@
---
map:
path: /clickSearch
---
综合搜索组件 目前只用于 asset 以及 endpoint
<API src="./index.vue" lang="en"></API>

View File

@@ -0,0 +1,20 @@
<script lang="ts" setup>
const props = withDefaults(defineProps<{
/**
* 相关搜索参数
*/
titleSearchList?: Array<any>,
/**
* 当前选中的值
*/
selectValue?: Array<any>,
}>(), {
})
</script>
<template>
<div>
</div>
</template>

View File

@@ -0,0 +1,10 @@
---
map:
path: /clickSearch
---
综合搜索组件 目前只用于 asset 以及 endpoint
<API src="./index.vue" lang="zh"></API>

View File

@@ -0,0 +1,20 @@
---
map:
path: /promqlInput
---
promql 输入组件
# 相关链接
codemirror : https://github.com/codemirror/codemirror5 <br>
codemirror-promql : https://github.com/prometheus/codemirror-promql
# 注意事项
api文档比较少 可以查看源码看下一些其他的配置
<API src="./index.vue" lang="en"></API>

View File

@@ -0,0 +1,44 @@
<script lang="ts" setup>
const props = withDefaults(defineProps<{
/**
* 当前所有已输入的表达式列表
*/
expressionList?: Array<any>,
/**
* 表示是当前输入的第几个
*/
index?: Array<any>,
/**
* 状态 查询时是否使用
*/
state?: number,
/**
* 当前显示的样式 主要两种 右侧弹窗 以及 explore的位置
*/
styleType?: number,
/**
* 历史信息查询条件
*/
historyParam?: {},
/**
* 是否显示删除
*/
showRemove?: boolean,
/**
* 是否必填
*/
required?: boolean,
/**
* 类型 metric 或者 log 为空时视为metric
*/
type?: string,
}>(), {
})
</script>
<template>
<div>
</div>
</template>

View File

@@ -0,0 +1,20 @@
---
map:
path: /promqlInput
---
promql 输入组件
# 相关链接
codemirror : https://github.com/codemirror/codemirror5 <br>
codemirror-promql : https://github.com/prometheus/codemirror-promql
# 注意事项
api文档比较少 可以查看源码看下一些其他的配置
<API src="./index.vue" lang="zh"></API>

View File

@@ -0,0 +1,26 @@
---
map:
path: /multipleTime
---
时间选择器 同比组件
# 示例代码
```vue
<multipleTime
:stepSearchTime="searchTime"
class="multiple-time margin-r-10"
@change="dateChange(searchTime)"
/>
```
# 注意事项
回显需要赋值之后再次设置相应时间
<API src="./index.vue" lang="en"></API>

View File

@@ -0,0 +1,14 @@
<script lang="ts" setup>
const props = withDefaults(defineProps<{
}>(), {
})
</script>
<template>
<div>
</div>
</template>

View File

@@ -0,0 +1,27 @@
---
map:
path: /multipleTime
---
时间选择器 同比组件
# 示例代码
```vue
<multipleTime
:stepSearchTime="searchTime"
class="multiple-time margin-r-10"
@change="dateChange(searchTime)"
/>
```
# 注意事项
回显需要赋值之后再次设置相应时间
<API src="./index.vue" lang="zh"></API>

View File

@@ -0,0 +1,30 @@
---
map:
path: /pickTime
---
时间选择器组件
# 示例代码
```vue
<pick-time
v-model="searchTime"
sign="message"
:default-pick="defaultPick"
:refresh-data-func="dateChange"
:show-empty="true"
:use-chart-unit="false"
:use-refresh="true"
></pick-time>
```
# 注意事项
回显需要赋值之后再次设置相应时间
<API src="./index.vue" lang="en"></API>

View File

@@ -0,0 +1,56 @@
<script lang="ts" setup>
const props = withDefaults(defineProps<{
/**
* 绑定的时间数组
*/
model?: Array<any>,
/**
* 刷新函数
*/
refreshDataFunc?: Function,
/**
* 是否显示刷新
*/
useRefresh?: boolean
/**
* 是否显示chart单位
*/
useChartUnit?: boolean
/**
* 是否显示时间选择则
*/
showTimePicker?: boolean
/**
* 是否显示时间同比
*/
showMultiple?: boolean,
/**
* 默认显示时间
*/
defaultPick?: Number,
/**
* 是否可以设置为空
*/
showEmpty?: boolean,
/**
* 唯一id
*/
id?: String,
/**
* 标识 用于区分是底弹窗 还是主页面
*/
sign?: [Number, String],
/**
* 是否显示锁定
*/
showLocked?: boolean,
}>(), {
})
</script>
<template>
<div>
</div>
</template>

View File

@@ -0,0 +1,30 @@
---
map:
path: /pickTime
---
时间选择器组件
# 示例代码
```vue
<pick-time
v-model="searchTime"
sign="message"
:default-pick="defaultPick"
:refresh-data-func="dateChange"
:show-empty="true"
:use-chart-unit="false"
:use-refresh="true"
></pick-time>
```
# 注意事项
回显需要赋值之后再次设置相应时间
<API src="./index.vue" lang="zh"></API>

View File

@@ -0,0 +1,9 @@
<script lang="ts" setup>
</script>
<template>
<div></div>
</template>
<style>
</style>

View File

@@ -0,0 +1,58 @@
---
map:
path: /table
---
# 关联组件
以asset为例子 其他表格 将asset换为对应名称
1. deleteButton 删除组件
2. nzDataList table组件公共部分
3. assetBox 对应的新增 编辑
4. detailViewTopSearch 详细视图搜索框
5. assetDetail 详细视图
6. assetTable 对应table组件
7. clickSearch 详细搜索框
8. topToolMoreOptions 右侧工具菜单
9. alertSilenceBox 告警静默弹窗
10. nzDetailView 详细视图 公共部分
# 示例
```vue
<div>
<nz-detail-view>
<template v-slot:top-tool-left>
<detailViewTopSearch />
</template>
<template v-slot:top-tool-right>
<top-tool-more-options></top-tool-more-options>
</template>
<template v-slot:nz-detail-view-list>
<asset-detail></asset-detail>
</template>
<!-- 分页组件 -->
<template v-slot:pagination>
<el-pagination></el-pagination>
</template>
</nz-detail-view>
<nz-data-list>
<template v-slot:top-tool-right>
<top-tool-more-options></top-tool-more-options>
</template>
<template v-slot:search >
<click-search />
</template>
<template v-slot:default="slotProps">
<asset-table></asset-table>
</template>
<!-- 分页组件 -->
<template v-slot:pagination>
<Pagination ref="Pagination" :pageObj="pageObj" :tableId="tableId" @pageNo='pageNo' @pageSize='pageSize'></Pagination>
</template>
</nz-data-list>
<transition name="right-box">
<asset-box />
</transition>
</div>
```

View File

@@ -0,0 +1,39 @@
<script lang="ts" setup>
const props = withDefaults(defineProps<{
/**
* chart相关信息 如id 位置等
*/
chartInfo?: string,
/**
* 是否报错
*/
isError?: boolean,
/**
* chart相关数据 若报错 取 item.error
*/
chartData?: { },
/**
* 是否显示全部数据
*/
showAllData?: boolean,
/**
* 全部数据的长度
*/
allDataLength?: number,
/**
* 是否为快照
*/
isExportHtml?: boolean,
/**
* 是否为预览
*/
isPreview?: boolean,
}>(), {
})
</script>
<template>
<div>
</div>
</template>

View File

@@ -0,0 +1,59 @@
---
map:
path: /table
---
# 关联组件
以asset为例子 其他表格 将asset换为对应名称
1. deleteButton 删除组件
2. nzDataList table组件公共部分
3. assetBox 对应的新增 编辑
4. detailViewTopSearch 详细视图搜索框
5. assetDetail 详细视图
6. assetTable 对应table组件
7. clickSearch 详细搜索框
8. topToolMoreOptions 右侧工具菜单
9. alertSilenceBox 告警静默弹窗
10. nzDetailView 详细视图 公共部分
# 示例
```vue
<div>
<nz-detail-view>
<template v-slot:top-tool-left>
<detailViewTopSearch />
</template>
<template v-slot:top-tool-right>
<top-tool-more-options></top-tool-more-options>
</template>
<template v-slot:nz-detail-view-list>
<asset-detail></asset-detail>
</template>
<!-- 分页组件 -->
<template v-slot:pagination>
<el-pagination></el-pagination>
</template>
</nz-detail-view>
<nz-data-list>
<template v-slot:top-tool-right>
<top-tool-more-options></top-tool-more-options>
</template>
<template v-slot:search >
<click-search />
<click-search />
</template>
<template v-slot:default="slotProps">
<asset-table></asset-table>
</template>
<!-- 分页组件 -->
<template v-slot:pagination>
<Pagination ref="Pagination" :pageObj="pageObj" :tableId="tableId" @pageNo='pageNo' @pageSize='pageSize'></Pagination>
</template>
</nz-data-list>
<transition name="right-box">
<asset-box />
</transition>
</div>
```

View File

@@ -0,0 +1,7 @@
---
map:
path: /deleteButton
---
<API src="./index.vue" lang="en"></API>

View File

@@ -0,0 +1,39 @@
<script lang="ts" setup>
const props = withDefaults(defineProps<{
/**
* 是否显示强制删除
*/
forceDeleteShow?: boolean,
/**
* 需要删除的数组
*/
deleteObjs?: Array,
/**
* 删除接口
*/
api?: string,
/**
* 唯一id
*/
id?: string,
/**
* 删除按钮的样式 是按钮 还是文字
*/
type?: string,
/**
* 删除的标题
*/
deleteTitle?: string,
/**
* 是否需要强制删除
*/
single?: boolean,
}>(), {
})
</script>
<template>
<div>
</div>
</template>

View File

@@ -0,0 +1,8 @@
---
map:
path: /deleteButton
---
<API src="./index.vue" lang="zh"></API>

View File

@@ -0,0 +1,14 @@
---
map:
path: /bottomBox
---
底弹窗公共组件
# 关联组件
1. 对应的Tab组件 如 assetTab
<API src="./index.vue" lang="en"></API>

View File

@@ -0,0 +1,39 @@
<script lang="ts" setup>
const props = withDefaults(defineProps<{
/**
* 是否全屏
*/
isFullScreen: boolean,
/**
* resize时用v-show="subResizeShow"控制页面内容是否显示
*/
subResizeShow: boolean,
/**
* 关联的实体对象
*/
obj: Object,
/**
* 来自哪个页面
*/
from: String,
/**
* 动态页签列表
*/
tabList: Array<any>,
/**
* 展示哪个页签
*/
targetTab: String,
/**
* pickTime历史记录的唯一标识
*/
sign: [Number, String]
}>(), {
})
</script>
<template>
<div>
</div>
</template>

View File

@@ -0,0 +1,12 @@
---
map:
path: /bottomBox
---
底弹窗公共组件
# 关联组件
1. 对应的Tab组件 如 assetTab
<API src="./index.vue" lang="zh"></API>

View File

@@ -0,0 +1,18 @@
---
map:
path: /searchBox
---
公共搜索组件
部分写死的搜索条件可以去下方文件查看
nezha-fronted/src/components/common/searchBox/searchBoxInfo.js
# 示例代码
```vue
<search-box />
```
<API src="./index.vue" lang="en"></API>

View File

@@ -0,0 +1,27 @@
<script lang="ts" setup>
const props = withDefaults(defineProps<{
/**
* 默认搜索条件
*/
searchMsg?: {},
/**
* 来自那个页面
*/
from: string,
/**
* 当前搜索框位置 如表格 底弹窗 弹窗等
*/
position: {},
/**
* 当前所选择的查询条件
*/
targetTab: {}
}>(), {
})
</script>
<template>
<div>
</div>
</template>

View File

@@ -0,0 +1,17 @@
---
map:
path: /searchBox
---
公共搜索组件
部分写死的搜索条件可以去下方文件查看
nezha-fronted/src/components/common/searchBox/searchBoxInfo.js
# 示例代码
```vue
<search-box />
```
<API src="./index.vue" lang="zh"></API>

View File

@@ -0,0 +1,18 @@
---
map:
path: /searchInput
---
公共搜索组件(新 目前只用于alertMessage
部分写死的搜索条件可以去下方文件查看
nezha-fronted/src/components/common/searchBox/searchBoxInfo.js
# 示例代码
```vue
<search-input />
```
<API src="./index.vue" lang="en"></API>

View File

@@ -0,0 +1,19 @@
<script lang="ts" setup>
const props = withDefaults(defineProps<{
/**
* 默认搜索条件
*/
searchMsg?: {},
/**
* 当前所选择的查询条件
*/
targetTab: {}
}>(), {
})
</script>
<template>
<div>
</div>
</template>

View File

@@ -0,0 +1,17 @@
---
map:
path: /searchInput
---
公共搜索组件(新 目前只用于alertMessage
部分写死的搜索条件可以去下方文件查看
nezha-fronted/src/components/common/searchBox/searchBoxInfo.js
# 示例代码
```vue
<search-input />
```
<API src="./index.vue" lang="zh"></API>

View File

@@ -0,0 +1,82 @@
---
map:
path: /nzDataList
---
# 关联组件
1. SearchBox
2. bottomBox
3. panelChart
4. deleteButton
5. diagnosisTab
6. configSync
# 示例代码
```vue
<div :class="from" class="list-page">
<!-- 主页面 -->
<div class="main-list">
<!-- 顶部工具栏 -->
<div class="main-container">
<div class="top-tools">
<div class="top-tool-left" >
<search-box></search-box>
<slot name="top-tool-left"></slot>
</div>
<div class="top-tool-right">
<div>
<search-input ></search-input>
</div>
<template>
<slot name="top-tool-right"></slot>
</template>
<button v-if="showLayout.indexOf('elementSet') > -1" class="top-tool-btn table-column-setting"
type="button" @click="tools.showCustomTableTitle = true" :title="$t('overall.selectColumns')">
<i class="nz-icon-gear nz-icon"></i>
</button>
<el-dropdown>
<button class="top-tool-btn table-column-setting"
type="button" :title="$t('overall.switchView')">
<i class="nz-icon nz-icon-list-view" />
</button>
<el-dropdown-menu slot="dropdown" class="right-public-box-dropdown-top right-box-select-top">
<el-dropdown-item :command="'list'" :class="detailType === 'list' ? 'active' : ''">{{$t('asset.detail.list')}}</el-dropdown-item>
<el-dropdown-item :command="'view'" :class="detailType === 'view' ? 'active' : ''">{{$t('asset.detail.detail')}}</el-dropdown-item>
</el-dropdown-menu>
</el-dropdown>
</div>
<!-- 顶部分页组件当打开底部上滑框时出现 -->
<!-- <div v-if="showLayout.indexOf('pagination') > -1" class="pagination-top pagination-top-hide display-none"></div>-->
</div>
<div >
<slot name="search"></slot>
</div>
<div>
<slot v-bind:mainResizeShow="bottomBox.mainResizeShow"></slot>
</div>
<div>
<slot name="pagination"></slot>
</div>
</div>
<!-- 自定义table列 -->
<transition name="el-zoom-in-top">
<element-set></element-set>
</transition>
</div>
<transition name="el-zoom-in-bottom">
<bottom-box ></bottom-box>
</transition>
<delete-button></delete-button>
<diagnosis-tab></diagnosis-tab>
<config-sync></config-sync>
</div>
```
<API src="./index.vue" lang="en"></API>

View File

@@ -0,0 +1,50 @@
<script lang="ts" setup>
const props = withDefaults(defineProps<{
/**
* 当前展示类型
*/
detailType?: string,
/**
* 表格标题
*/
tableTitle?: Array<any>,
/**
* 编辑后的表格标题
*/
customTableTitle?: Array<any>,
/**
* 当前使用的插槽
*/
layout?: Array<any>,
/**
* 搜索框使用的相关参数
*/
searchMsg?: Array<any>,
/**
* 当前底弹窗加header的高度
*/
nzTableHeightOffset?: number,
/**
* 是否隐藏删除
*/
hideDelete?: boolean,
/**
* 搜索框位置
*/
searchRight?: boolean
}>(), {
})
</script>
<template>
<div>
<!-- 这里是默认插槽可以插入自定义内容 -->
<slot name="top-tool-left">{ 213123 }</slot>
<slot name="top-tool-right">{{ 213123 }}</slot>
<slot name="search">{{ 213123 }}</slot>
<slot name="pagination">{{ 213123 }}</slot>
<slot name="default">{{ 213123 }}</slot>
</div>
</template>

View File

@@ -0,0 +1,82 @@
---
map:
path: /nzDataList
---
# 关联组件
1. SearchBox
2. bottomBox
3. panelChart
4. deleteButton
5. diagnosisTab
6. configSync
# 示例代码
```vue
<div :class="from" class="list-page">
<!-- 主页面 -->
<div class="main-list">
<!-- 顶部工具栏 -->
<div class="main-container">
<div class="top-tools">
<div class="top-tool-left" >
<search-box></search-box>
<slot name="top-tool-left"></slot>
</div>
<div class="top-tool-right">
<div>
<search-input ></search-input>
</div>
<template>
<slot name="top-tool-right"></slot>
</template>
<button v-if="showLayout.indexOf('elementSet') > -1" class="top-tool-btn table-column-setting"
type="button" @click="tools.showCustomTableTitle = true" :title="$t('overall.selectColumns')">
<i class="nz-icon-gear nz-icon"></i>
</button>
<el-dropdown>
<button class="top-tool-btn table-column-setting"
type="button" :title="$t('overall.switchView')">
<i class="nz-icon nz-icon-list-view" />
</button>
<el-dropdown-menu slot="dropdown" class="right-public-box-dropdown-top right-box-select-top">
<el-dropdown-item :command="'list'" :class="detailType === 'list' ? 'active' : ''">{{$t('asset.detail.list')}}</el-dropdown-item>
<el-dropdown-item :command="'view'" :class="detailType === 'view' ? 'active' : ''">{{$t('asset.detail.detail')}}</el-dropdown-item>
</el-dropdown-menu>
</el-dropdown>
</div>
<!-- 顶部分页组件当打开底部上滑框时出现 -->
<!-- <div v-if="showLayout.indexOf('pagination') > -1" class="pagination-top pagination-top-hide display-none"></div>-->
</div>
<div >
<slot name="search"></slot>
</div>
<div>
<slot v-bind:mainResizeShow="bottomBox.mainResizeShow"></slot>
</div>
<div>
<slot name="pagination"></slot>
</div>
</div>
<!-- 自定义table列 -->
<transition name="el-zoom-in-top">
<element-set></element-set>
</transition>
</div>
<transition name="el-zoom-in-bottom">
<bottom-box ></bottom-box>
</transition>
<delete-button></delete-button>
<diagnosis-tab></diagnosis-tab>
<config-sync></config-sync>
</div>
```
<API src="./index.vue" lang="zh"></API>

View File

@@ -0,0 +1,8 @@
---
map:
path: /nzDetailView
---
基本类似 nzDataList
<API src="./index.vue" lang="en"></API>

View File

@@ -0,0 +1,13 @@
<script lang="ts" setup>
const props = withDefaults(defineProps<{
}>(), {
})
</script>
<template>
<div>
</div>
</template>

View File

@@ -0,0 +1,8 @@
---
map:
path: /nzDetailView
---
基本类似 nzDataList
<API src="./index.vue" lang="zh"></API>

View File

@@ -0,0 +1,17 @@
---
map:
path: /rightBox
---
新增编辑 批量新增编辑的公共组件
使用时 找到对应的 [name]Box 如 assetBox
父页面的blankObject 最好包含全部属性 否则可能会导致 element 部分组件不支持编辑
# 示例代码
```vue
<right-box />
```
<API src="./index.vue" lang="en"></API>

View File

@@ -0,0 +1,16 @@
<script lang="ts" setup>
const props = withDefaults(defineProps<{
/**
* 相应对象的实例
*/
obj?: object,
}>(), {
})
</script>
<template>
<div>
</div>
</template>

View File

@@ -0,0 +1,17 @@
---
map:
path: /rightBox
---
新增编辑 批量新增编辑的公共组件
使用时 找到对应的 [name]Box 如 assetBox
父页面的blankObject 最好包含全部属性 否则可能会导致 element 部分组件不支持编辑
# 示例代码
```vue
<right-box />
```
<API src="./index.vue" lang="zh"></API>

View File

@@ -1 +1 @@
{"baseUrl":"http://192.168.44.22/", "version": "23.06" , "showVideo": 1}
{"baseUrl":"http://192.168.44.22/", "version": "23.06" }