sohelp-eleplus 1.1.26 → 1.1.28
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/components.js +1 -0
- package/icons/flag/README.md +2 -2
- package/icons/flag/index.js +0 -1
- package/package.json +1 -1
- package/sohelp-ace-editor/README.md +32 -42
- package/sohelp-ace-editor/index.vue +166 -156
- package/sohelp-api-doc/README.md +36 -0
- package/sohelp-api-doc/index.vue +160 -0
- package/sohelp-application-select/README.md +9 -7
- package/sohelp-application-select/index.vue +10 -13
- package/sohelp-autocode/README.md +14 -26
- package/sohelp-calendar-view/README.md +9 -7
- package/sohelp-calendar-view/index.vue +10 -9
- package/sohelp-card/README.md +15 -17
- package/sohelp-card/index.vue +1 -1
- package/sohelp-card-view/README.md +9 -7
- package/sohelp-card-view/index.vue +10 -9
- package/sohelp-condition/README.md +29 -49
- package/sohelp-condition/index.vue +2 -1
- package/sohelp-country-select/README.md +15 -123
- package/sohelp-country-select/index.vue +1 -1
- package/sohelp-cry-input/README.md +19 -195
- package/sohelp-cry-input/index.vue +6 -2
- package/sohelp-date/README.md +12 -15
- package/sohelp-datetime/README.md +15 -17
- package/sohelp-datetime-picker/README.md +18 -18
- package/sohelp-datetime-picker/index.vue +11 -4
- package/sohelp-datetime-range/README.md +20 -23
- package/sohelp-demo-block/README.md +43 -0
- package/sohelp-demo-block/index.vue +229 -0
- package/sohelp-dict/README.md +28 -23
- package/sohelp-dict/index.vue +17 -17
- package/sohelp-drawer/README.md +28 -26
- package/sohelp-drop-card/README.md +29 -28
- package/sohelp-drop-card/index.vue +0 -1
- package/sohelp-dyn-select/README.md +31 -16
- package/sohelp-dyn-select/index.vue +65 -67
- package/sohelp-dyn-tree/README.md +26 -20
- package/sohelp-dyn-tree/index.vue +2 -2
- package/sohelp-dyn-tree-select/README.md +28 -19
- package/sohelp-dyn-tree-select/index.vue +23 -7
- package/sohelp-entity-form/README.md +65 -30
- package/sohelp-entity-form/index.vue +3 -2
- package/sohelp-entity-grid/README.md +13 -11
- package/sohelp-entity-grid/index.vue +1 -1
- package/sohelp-file-upload/README.md +25 -27
- package/sohelp-file-upload/index.vue +1 -1
- package/sohelp-filter-scheme/README.md +34 -30
- package/sohelp-filter-scheme/index.vue +2 -2
- package/sohelp-grid/README.md +52 -33
- package/sohelp-grid/index.vue +41 -39
- package/sohelp-grid/js/SohelpGridConfig.js +3 -3
- package/sohelp-grid/js/useSohelpGridConfig.js +4 -6
- package/sohelp-grid-select/README.md +32 -27
- package/sohelp-grid-select/index.vue +6 -5
- package/sohelp-grid-view/README.md +51 -22
- package/sohelp-grid-view-select/README.md +33 -25
- package/sohelp-grid-view-select/index.vue +2 -1
- package/sohelp-group-view/README.md +14 -4
- package/sohelp-group-view/index.vue +10 -9
- package/sohelp-icon-select/README.md +14 -12
- package/sohelp-image-upload/README.md +27 -27
- package/sohelp-image-upload/index.vue +2 -2
- package/sohelp-import/README.md +25 -24
- package/sohelp-input/README.md +27 -11
- package/sohelp-input/index.vue +15 -2
- package/sohelp-input-tag/README.md +53 -0
- package/sohelp-input-tag/index.vue +337 -0
- package/sohelp-modal/README.md +42 -16
- package/sohelp-modal/index.vue +21 -4
- package/sohelp-modal-select/README.md +745 -0
- package/sohelp-modal-select/index.vue +705 -0
- package/sohelp-module/README.md +24 -13
- package/sohelp-number-input/README.md +15 -8
- package/sohelp-number-input/index.vue +3 -0
- package/sohelp-number-range/README.md +22 -12
- package/sohelp-number-range/index.vue +3 -11
- package/sohelp-org-modal-select/README.md +47 -0
- package/sohelp-org-modal-select/index.vue +411 -0
- package/sohelp-org-select/README.md +23 -10
- package/sohelp-org-select/index.vue +41 -24
- package/sohelp-org-tree/README.md +19 -7
- package/sohelp-org-tree/index.vue +1 -2
- package/sohelp-org-tree-select/README.md +22 -11
- package/sohelp-org-tree-select/index.vue +1 -2
- package/sohelp-org-user-tree/README.md +19 -7
- package/sohelp-org-user-tree/index.vue +1 -2
- package/sohelp-org-user-tree-select/README.md +8 -3
- package/sohelp-org-user-tree-select/index.vue +8 -7
- package/sohelp-page/README.md +20 -11
- package/sohelp-page/index.vue +1 -1
- package/sohelp-pagination/README.md +14 -6
- package/sohelp-pagination/index.vue +1 -1
- package/sohelp-power/README.md +34 -19
- package/sohelp-power/index.vue +2 -2
- package/sohelp-pro-form/README.md +64 -21
- package/sohelp-pro-layout/README.md +10 -4
- package/sohelp-pro-layout/index.vue +8 -7
- package/sohelp-pro-table/README.md +30 -6
- package/sohelp-process/README.md +26 -13
- package/sohelp-process/index.vue +6 -6
- package/sohelp-rate/README.md +24 -12
- package/sohelp-rate/index.vue +5 -1
- package/sohelp-relation/README.md +10 -4
- package/sohelp-relation/index.vue +8 -7
- package/sohelp-relation-modal-select/README.md +41 -0
- package/sohelp-relation-modal-select/index.vue +70 -0
- package/sohelp-rich-text/README.md +29 -11
- package/sohelp-rich-text/index.vue +21 -20
- package/sohelp-richtext/README.md +12 -2
- package/sohelp-richtext/index.vue +8 -6
- package/sohelp-role-modal-select/README.md +45 -0
- package/sohelp-role-modal-select/index.vue +111 -0
- package/sohelp-role-select/README.md +18 -10
- package/sohelp-role-select/index.vue +36 -27
- package/sohelp-search/README.md +12 -4
- package/sohelp-search/index.vue +2 -2
- package/sohelp-search-pro-form/README.md +15 -1
- package/sohelp-search-pro-form/index.vue +2 -1
- package/sohelp-select/README.md +31 -30
- package/sohelp-select/index.vue +79 -84
- package/sohelp-split-panel/README.md +17 -18
- package/sohelp-switch/README.md +21 -19
- package/sohelp-switch/index.vue +34 -33
- package/sohelp-table/README.md +35 -27
- package/sohelp-table/index.vue +110 -109
- package/sohelp-table-select/README.md +55 -0
- package/sohelp-tenant-select/README.md +19 -18
- package/sohelp-tenant-select/index.vue +105 -109
- package/sohelp-text/README.md +16 -10
- package/sohelp-text/index.vue +5 -5
- package/sohelp-textarea-input/README.md +19 -12
- package/sohelp-time/README.md +11 -10
- package/sohelp-tree/README.md +24 -19
- package/sohelp-tree/index.vue +21 -23
- package/sohelp-tree-select/README.md +23 -10
- package/sohelp-user-modal-select/README.md +739 -0
- package/sohelp-user-modal-select/index.vue +87 -0
- package/sohelp-user-select/README.md +26 -15
- package/sohelp-user-select/index.vue +6 -2
- package/sohelp-user-tag/README.md +5 -7
- package/sohelp-user-tag/index.vue +8 -8
- package/sohelp-user-tree/README.md +5 -8
- package/sohelp-user-tree/index.vue +8 -7
- package/sohelp-vform-drawer/README.md +36 -18
- package/sohelp-vform-drawer/index.vue +2 -2
- package/sohelp-vform-eleplus/README.md +33 -31
- package/sohelp-vform-eleplus/index.vue +2 -2
- package/sohelp-vform-eleplus/tinymce/langs/zh_CN.js +461 -461
- package/sohelp-vform-eleplus/tinymce/langs/zh_TW.js +418 -418
- package/sohelp-vform-eleplus/tinymce/skins/content/dark/content.css +72 -72
- package/sohelp-vform-eleplus/tinymce/skins/content/dark/content.min.css +7 -7
- package/sohelp-vform-eleplus/tinymce/skins/content/default/content.css +67 -67
- package/sohelp-vform-eleplus/tinymce/skins/content/default/content.min.css +7 -7
- package/sohelp-vform-eleplus/tinymce/skins/content/document/content.css +72 -72
- package/sohelp-vform-eleplus/tinymce/skins/content/document/content.min.css +7 -7
- package/sohelp-vform-eleplus/tinymce/skins/content/writer/content.css +68 -68
- package/sohelp-vform-eleplus/tinymce/skins/content/writer/content.min.css +7 -7
- package/sohelp-vform-eleplus/tinymce/skins/ui/oxide/content.css +732 -732
- package/sohelp-vform-eleplus/tinymce/skins/ui/oxide/content.inline.css +726 -726
- package/sohelp-vform-eleplus/tinymce/skins/ui/oxide/content.inline.min.css +7 -7
- package/sohelp-vform-eleplus/tinymce/skins/ui/oxide/content.min.css +7 -7
- package/sohelp-vform-eleplus/tinymce/skins/ui/oxide/content.mobile.css +29 -29
- package/sohelp-vform-eleplus/tinymce/skins/ui/oxide/content.mobile.min.css +7 -7
- package/sohelp-vform-eleplus/tinymce/skins/ui/oxide/skin.css +3047 -3047
- package/sohelp-vform-eleplus/tinymce/skins/ui/oxide/skin.min.css +7 -7
- package/sohelp-vform-eleplus/tinymce/skins/ui/oxide/skin.mobile.css +673 -673
- package/sohelp-vform-eleplus/tinymce/skins/ui/oxide/skin.mobile.min.css +7 -7
- package/sohelp-vform-eleplus/tinymce/skins/ui/oxide/skin.shadowdom.css +37 -37
- package/sohelp-vform-eleplus/tinymce/skins/ui/oxide/skin.shadowdom.min.css +7 -7
- package/sohelp-vform-eleplus/tinymce/skins/ui/oxide-dark/content.css +714 -714
- package/sohelp-vform-eleplus/tinymce/skins/ui/oxide-dark/content.inline.css +726 -726
- package/sohelp-vform-eleplus/tinymce/skins/ui/oxide-dark/content.inline.min.css +7 -7
- package/sohelp-vform-eleplus/tinymce/skins/ui/oxide-dark/content.min.css +7 -7
- package/sohelp-vform-eleplus/tinymce/skins/ui/oxide-dark/content.mobile.css +29 -29
- package/sohelp-vform-eleplus/tinymce/skins/ui/oxide-dark/content.mobile.min.css +7 -7
- package/sohelp-vform-eleplus/tinymce/skins/ui/oxide-dark/skin.css +3047 -3047
- package/sohelp-vform-eleplus/tinymce/skins/ui/oxide-dark/skin.min.css +7 -7
- package/sohelp-vform-eleplus/tinymce/skins/ui/oxide-dark/skin.mobile.css +673 -673
- package/sohelp-vform-eleplus/tinymce/skins/ui/oxide-dark/skin.mobile.min.css +7 -7
- package/sohelp-vform-eleplus/tinymce/skins/ui/oxide-dark/skin.shadowdom.css +37 -37
- package/sohelp-vform-eleplus/tinymce/skins/ui/oxide-dark/skin.shadowdom.min.css +7 -7
- package/sohelp-vform-modal/README.md +36 -18
- package/sohelp-vform-modal/index.vue +2 -2
- package/sohelp-vform-select/README.md +9 -7
- package/sohelp-vform-select/index.vue +8 -7
- package/sohelp-vxe-grid/DefaultGridOptions.js +5 -3
- package/sohelp-vxe-grid/DefaultProps.js +0 -1
- package/sohelp-vxe-grid/README.md +540 -35
- package/sohelp-vxe-grid/SohelpGridConfig.js +8 -6
- package/sohelp-vxe-grid/index.vue +141 -94
- package/sohelp-vxe-grid-select/README.md +41 -26
- package/sohelp-vxe-table/README.md +23 -20
- package/sohelp-vxe-table/index.vue +5 -4
- package/sohelp-workflow/README.md +21 -17
- package/sohelp-workflow/index.vue +25 -22
- package/sohelp-workflow-drawer/README.md +41 -28
- package/sohelp-workflow-drawer/components/table.vue +7 -1
- package/sohelp-workflow-drawer/index.vue +86 -71
- package/sohelp-workflow-drawer/js/index.js +15 -13
- package/style/index.scss +0 -0
- package/utils/safe-eval.js +89 -0
- package/sohelp-dyn-select/props.js +0 -67
- package/sohelp-user-select/index.vue~ +0 -53
- package/sohelp-user-select/props.js +0 -71
|
@@ -1,30 +1,47 @@
|
|
|
1
1
|
<template>
|
|
2
|
-
<sohelp-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
2
|
+
<div class="sohelp-org-select">
|
|
3
|
+
<sohelp-dyn-select
|
|
4
|
+
v-bind="$attrs"
|
|
5
|
+
:url="url"
|
|
6
|
+
:labelField="labelField"
|
|
7
|
+
:valueField="valueField"
|
|
8
|
+
:datasource="datasource"
|
|
9
|
+
v-model="modelValue"
|
|
10
|
+
></sohelp-dyn-select>
|
|
11
|
+
</div>
|
|
8
12
|
</template>
|
|
13
|
+
<script setup>
|
|
14
|
+
import SohelpDynSelect from '../sohelp-dyn-select/index.vue';
|
|
15
|
+
|
|
16
|
+
const modelValue = defineModel('modelValue', { type: [String, Number, Array], default: '' });
|
|
17
|
+
|
|
18
|
+
const props = defineProps({
|
|
19
|
+
datasource: {
|
|
20
|
+
type: [Array, Function, Promise],
|
|
21
|
+
required: false
|
|
22
|
+
},
|
|
23
|
+
url: {
|
|
24
|
+
type: String,
|
|
25
|
+
default: '/engine/web/org/list'
|
|
26
|
+
},
|
|
27
|
+
labelField: {
|
|
28
|
+
type: String,
|
|
29
|
+
default: 'org_name'
|
|
30
|
+
},
|
|
31
|
+
valueField: {
|
|
32
|
+
type: String,
|
|
33
|
+
default: 'id'
|
|
34
|
+
}
|
|
35
|
+
});
|
|
36
|
+
defineExpose({});
|
|
37
|
+
</script>
|
|
9
38
|
<script>
|
|
10
39
|
export default {
|
|
11
|
-
name: 'SohelpOrgSelect'
|
|
12
|
-
components: {},
|
|
13
|
-
props: {
|
|
14
|
-
url: {
|
|
15
|
-
type: String,
|
|
16
|
-
default: '/engine/web/org/list'
|
|
17
|
-
},
|
|
18
|
-
labelField: {
|
|
19
|
-
type: String,
|
|
20
|
-
default: 'org_name'
|
|
21
|
-
},
|
|
22
|
-
valueField: {
|
|
23
|
-
type: String,
|
|
24
|
-
default: 'id'
|
|
25
|
-
}
|
|
26
|
-
},
|
|
27
|
-
setup(props, { emit, attrs }) {}
|
|
40
|
+
name: 'SohelpOrgSelect'
|
|
28
41
|
};
|
|
29
42
|
</script>
|
|
30
|
-
<style
|
|
43
|
+
<style>
|
|
44
|
+
.sohelp-org-select{
|
|
45
|
+
width: 100%;
|
|
46
|
+
}
|
|
47
|
+
</style>
|
|
@@ -1,18 +1,30 @@
|
|
|
1
1
|
# SohelpOrgTree 组织机构树
|
|
2
2
|
|
|
3
|
-
基于 `sohelp-dyn-tree`
|
|
3
|
+
基于 `sohelp-dyn-tree` 封装,预设组织机构列表接口地址,用于展示组织机构树形结构。
|
|
4
4
|
|
|
5
5
|
## 基础用法
|
|
6
6
|
|
|
7
|
-
```
|
|
8
|
-
<
|
|
7
|
+
```vue
|
|
8
|
+
<template>
|
|
9
|
+
<sohelp-org-tree @node-click="handleNodeClick" />
|
|
10
|
+
</template>
|
|
11
|
+
|
|
12
|
+
<script setup>
|
|
13
|
+
const handleNodeClick = (data, node, el) => {
|
|
14
|
+
console.log('选中组织:', data);
|
|
15
|
+
};
|
|
16
|
+
</script>
|
|
9
17
|
```
|
|
10
18
|
|
|
11
19
|
## 属性 (Props)
|
|
12
20
|
|
|
13
|
-
| 属性名 | 类型 | 默认值 | 说明 |
|
|
14
|
-
|
|
|
21
|
+
| 属性名 | 类型 | 默认值 | 必填 | 说明 |
|
|
22
|
+
| :--- | :--- | :--- | :--- | :--- |
|
|
23
|
+
| url | String | `/engine/web/org/list` | 否 | 组织机构数据接口地址 |
|
|
24
|
+
| ...attrs | - | - | 否 | 支持所有 `sohelp-dyn-tree` 属性透传 |
|
|
15
25
|
|
|
16
|
-
##
|
|
26
|
+
## 事件 (Events)
|
|
17
27
|
|
|
18
|
-
|
|
28
|
+
| 事件名 | 回调参数 | 说明 |
|
|
29
|
+
| :--- | :--- | :--- |
|
|
30
|
+
| node-click | `(data, node, el)` | 节点被点击时触发(透传自 `sohelp-dyn-tree`) |
|
|
@@ -1,22 +1,33 @@
|
|
|
1
1
|
# SohelpOrgTreeSelect 组织机构树选择器
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
基于 `sohelp-tree-select` 封装的组织机构下拉树选择组件。自动从接口加载扁平数据并转换为树形结构,支持只读模式和自定义数据源。
|
|
4
4
|
|
|
5
5
|
## 基础用法
|
|
6
6
|
|
|
7
|
-
```
|
|
8
|
-
<
|
|
7
|
+
```vue
|
|
8
|
+
<template>
|
|
9
|
+
<sohelp-org-tree-select v-model="orgId" />
|
|
10
|
+
</template>
|
|
11
|
+
|
|
12
|
+
<script setup>
|
|
13
|
+
import { ref } from 'vue';
|
|
14
|
+
const orgId = ref('');
|
|
15
|
+
</script>
|
|
9
16
|
```
|
|
10
17
|
|
|
11
18
|
## 属性 (Props)
|
|
12
19
|
|
|
13
|
-
| 属性名 | 类型 | 默认值 | 说明 |
|
|
14
|
-
|
|
|
15
|
-
|
|
|
16
|
-
|
|
|
17
|
-
|
|
|
18
|
-
|
|
|
20
|
+
| 属性名 | 类型 | 默认值 | 必填 | 说明 |
|
|
21
|
+
| :--- | :--- | :--- | :--- | :--- |
|
|
22
|
+
| modelValue (v-model) | String / Number / Array | `""` | 否 | 绑定值 |
|
|
23
|
+
| data (v-model:data) | Object | `{}` | 否 | 当前选中项的完整数据对象 |
|
|
24
|
+
| url | String | `/engine/web/org/list` | 否 | 数据接口地址 |
|
|
25
|
+
| datasource | Array / Function / Object | - | 否 | 自定义数据源,优先级高于 url;支持数组、返回数组的函数或 Promise |
|
|
26
|
+
| readonly | Boolean | `false` | 否 | 是否只读模式(只读时显示 `org_name` 文本) |
|
|
27
|
+
| ...attrs | - | - | 否 | 支持所有 `sohelp-tree-select` 属性透传 |
|
|
19
28
|
|
|
20
|
-
##
|
|
29
|
+
## 公开方法 (Expose)
|
|
21
30
|
|
|
22
|
-
|
|
31
|
+
- `treeProps` - 树形配置对象(含 data 数组)
|
|
32
|
+
- `modelValue` - 当前选中值
|
|
33
|
+
- `dataMap` - 以 id 为 key 的扁平数据映射
|
|
@@ -1,18 +1,30 @@
|
|
|
1
1
|
# SohelpOrgUserTree 组织人员树
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
基于 `sohelp-dyn-tree` 封装,预设组织人员列表接口地址,用于展示组织机构及人员的树形结构。
|
|
4
4
|
|
|
5
5
|
## 基础用法
|
|
6
6
|
|
|
7
|
-
```
|
|
8
|
-
<
|
|
7
|
+
```vue
|
|
8
|
+
<template>
|
|
9
|
+
<sohelp-org-user-tree @node-click="handleNodeClick" />
|
|
10
|
+
</template>
|
|
11
|
+
|
|
12
|
+
<script setup>
|
|
13
|
+
const handleNodeClick = (data, node, el) => {
|
|
14
|
+
console.log('选中节点:', data);
|
|
15
|
+
};
|
|
16
|
+
</script>
|
|
9
17
|
```
|
|
10
18
|
|
|
11
19
|
## 属性 (Props)
|
|
12
20
|
|
|
13
|
-
| 属性名 | 类型 | 默认值 | 说明 |
|
|
14
|
-
|
|
|
21
|
+
| 属性名 | 类型 | 默认值 | 必填 | 说明 |
|
|
22
|
+
| :--- | :--- | :--- | :--- | :--- |
|
|
23
|
+
| url | String | `/engine/web/org/list` | 否 | 数据接口地址 |
|
|
24
|
+
| ...attrs | - | - | 否 | 支持所有 `sohelp-dyn-tree` 属性透传 |
|
|
15
25
|
|
|
16
|
-
##
|
|
26
|
+
## 事件 (Events)
|
|
17
27
|
|
|
18
|
-
|
|
28
|
+
| 事件名 | 回调参数 | 说明 |
|
|
29
|
+
| :--- | :--- | :--- |
|
|
30
|
+
| node-click | `(data, node, el)` | 节点被点击时触发(透传自 `sohelp-dyn-tree`) |
|
|
@@ -1,7 +1,12 @@
|
|
|
1
1
|
# SohelpOrgUserTreeSelect 组织人员树选择器
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
组织人员树选择器组件,用于在下拉面板中选择组织机构下的用户。当前版本为占位组件,功能待实现。
|
|
4
4
|
|
|
5
|
-
##
|
|
5
|
+
## 基础用法
|
|
6
6
|
|
|
7
|
-
|
|
7
|
+
```vue
|
|
8
|
+
<template>
|
|
9
|
+
<!-- 当前版本为占位组件,功能待实现 -->
|
|
10
|
+
<sohelp-org-user-tree-select />
|
|
11
|
+
</template>
|
|
12
|
+
```
|
|
@@ -1,11 +1,12 @@
|
|
|
1
1
|
<template>
|
|
2
|
-
<div>
|
|
2
|
+
<div class="sohelp-org-user-tree-select">
|
|
3
|
+
<!-- TODO: 待实现 - 组织用户树选择器(继承SohelpOrgUserTree和SohelpSelect) -->
|
|
4
|
+
<el-empty description="组织用户树选择器 - 待实现" />
|
|
5
|
+
</div>
|
|
3
6
|
</template>
|
|
7
|
+
<script setup>
|
|
8
|
+
// TODO: 待实现
|
|
9
|
+
</script>
|
|
4
10
|
<script>
|
|
5
|
-
export default {
|
|
6
|
-
name: "SohelpOrgUserTreeModal"
|
|
7
|
-
}
|
|
11
|
+
export default { name: 'SohelpOrgUserTreeSelect' };
|
|
8
12
|
</script>
|
|
9
|
-
<style scoped>
|
|
10
|
-
|
|
11
|
-
</style>
|
package/sohelp-page/README.md
CHANGED
|
@@ -1,21 +1,30 @@
|
|
|
1
|
-
# SohelpPage
|
|
1
|
+
# SohelpPage 页面容器
|
|
2
2
|
|
|
3
|
-
基于 `ele-page`
|
|
3
|
+
基于 `ele-page` 封装的页面容器组件,默认启用弹性表格布局并隐藏页脚。
|
|
4
4
|
|
|
5
5
|
## 基础用法
|
|
6
6
|
|
|
7
|
-
```
|
|
8
|
-
<
|
|
9
|
-
|
|
10
|
-
|
|
7
|
+
```vue
|
|
8
|
+
<template>
|
|
9
|
+
<sohelp-page>
|
|
10
|
+
<div>页面内容</div>
|
|
11
|
+
</sohelp-page>
|
|
12
|
+
</template>
|
|
11
13
|
```
|
|
12
14
|
|
|
13
15
|
## 属性 (Props)
|
|
14
16
|
|
|
15
|
-
|
|
16
|
-
| flex-table | Boolean | true | 是否开启 Flex 布局适配表格高度 |
|
|
17
|
-
| hide-footer | Boolean | true | 是否隐藏底部区域 |
|
|
17
|
+
组件透传所有属性到内部 `ele-page`,并设置以下默认值:
|
|
18
18
|
|
|
19
|
-
|
|
19
|
+
| 属性名 | 类型 | 默认值 | 必填 | 说明 |
|
|
20
|
+
| --- | --- | --- | --- | --- |
|
|
21
|
+
| flex-table | Boolean | `true` | 否 | 启用弹性表格布局 |
|
|
22
|
+
| hide-footer | Boolean | `true` | 否 | 隐藏页脚区域 |
|
|
20
23
|
|
|
21
|
-
支持 `ele-page`
|
|
24
|
+
> 支持 `ele-page` 的所有属性,通过 `$attrs` 透传。
|
|
25
|
+
|
|
26
|
+
## 插槽 (Slots)
|
|
27
|
+
|
|
28
|
+
| 插槽名 | 说明 |
|
|
29
|
+
| --- | --- |
|
|
30
|
+
| default | 页面主体内容 |
|
package/sohelp-page/index.vue
CHANGED
|
@@ -1,13 +1,21 @@
|
|
|
1
|
-
# SohelpPagination
|
|
1
|
+
# SohelpPagination 分页
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
继承 `ElePagination` 的分页组件。
|
|
4
4
|
|
|
5
5
|
## 基础用法
|
|
6
6
|
|
|
7
|
-
```
|
|
8
|
-
<
|
|
7
|
+
```vue
|
|
8
|
+
<template>
|
|
9
|
+
<sohelp-pagination :total="100" v-model:currentPage="page" v-model:pageSize="limit" />
|
|
10
|
+
</template>
|
|
11
|
+
|
|
12
|
+
<script setup>
|
|
13
|
+
import { ref } from 'vue';
|
|
14
|
+
const page = ref(1);
|
|
15
|
+
const limit = ref(10);
|
|
16
|
+
</script>
|
|
9
17
|
```
|
|
10
18
|
|
|
11
|
-
##
|
|
19
|
+
## 属性 (Props)
|
|
12
20
|
|
|
13
|
-
|
|
21
|
+
继承 `ElePagination` 的所有属性,请参考 ElePagination 文档。
|
package/sohelp-power/README.md
CHANGED
|
@@ -1,27 +1,42 @@
|
|
|
1
|
-
# SohelpPower
|
|
1
|
+
# SohelpPower 数据查看范围选择器
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
基于 `sohelp-select` 封装的数据权限范围选择组件,支持预设的多种查看范围,包括自定义用户选择。
|
|
4
4
|
|
|
5
5
|
## 基础用法
|
|
6
6
|
|
|
7
|
-
```
|
|
8
|
-
<
|
|
7
|
+
```vue
|
|
8
|
+
<template>
|
|
9
|
+
<sohelp-power @change="onPowerChange" />
|
|
10
|
+
</template>
|
|
11
|
+
|
|
12
|
+
<script setup>
|
|
13
|
+
const onPowerChange = (val) => {
|
|
14
|
+
console.log('查看范围:', val);
|
|
15
|
+
};
|
|
16
|
+
</script>
|
|
9
17
|
```
|
|
10
18
|
|
|
19
|
+
## 属性 (Props)
|
|
20
|
+
|
|
21
|
+
组件无自定义 props,内部默认选中"全部数据"(值为 `"0"`)。
|
|
22
|
+
|
|
23
|
+
预设查看范围选项:
|
|
24
|
+
|
|
25
|
+
| 值 | 说明 |
|
|
26
|
+
| --- | --- |
|
|
27
|
+
| 0 | 全部数据 |
|
|
28
|
+
| 1 | 我负责的 |
|
|
29
|
+
| 2 | 下属负责的 |
|
|
30
|
+
| 3 | 仅限本部门 |
|
|
31
|
+
| 4 | 本公司 |
|
|
32
|
+
| 5 | 下属部门 |
|
|
33
|
+
| 6 | 本人及下属 |
|
|
34
|
+
| 7 | 本部门及下属部门 |
|
|
35
|
+
| 8 | 仅限本岗位 |
|
|
36
|
+
| 9 | 自定义(弹出用户选择) |
|
|
37
|
+
|
|
11
38
|
## 事件 (Events)
|
|
12
39
|
|
|
13
|
-
| 事件名 |
|
|
14
|
-
|
|
|
15
|
-
|
|
16
|
-
## 数据选项
|
|
17
|
-
|
|
18
|
-
- 0: 全部数据
|
|
19
|
-
- 1: 我负责的
|
|
20
|
-
- 2: 下属负责的
|
|
21
|
-
- 3: 仅限本部门
|
|
22
|
-
- 4: 本公司
|
|
23
|
-
- 5: 下属部门
|
|
24
|
-
- 6: 本人及下属
|
|
25
|
-
- 7: 本部门及下属部门
|
|
26
|
-
- 8: 仅限本岗位
|
|
27
|
-
- 9: 自定义 (弹出用户选择框)
|
|
40
|
+
| 事件名 | 回调参数 | 说明 |
|
|
41
|
+
| --- | --- | --- |
|
|
42
|
+
| change | `value: string \| { power: 9, powerUsers: Array }` | 选择查看范围后触发;选择"自定义"时返回对象包含用户列表 |
|
package/sohelp-power/index.vue
CHANGED
|
@@ -1,35 +1,78 @@
|
|
|
1
|
-
# SohelpProForm
|
|
1
|
+
# SohelpProForm 高级表单
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
基于 Element Plus `ElForm` 封装的配置化高级表单组件,支持栅格布局、表单验证、动态表单项和底栏操作按钮。
|
|
4
4
|
|
|
5
5
|
## 基础用法
|
|
6
6
|
|
|
7
|
-
```
|
|
8
|
-
<
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
7
|
+
```vue
|
|
8
|
+
<template>
|
|
9
|
+
<sohelp-pro-form
|
|
10
|
+
:model="formData"
|
|
11
|
+
:items="formItems"
|
|
12
|
+
:footer="true"
|
|
13
|
+
@submit="handleSubmit"
|
|
14
|
+
@reset="handleReset"
|
|
15
|
+
/>
|
|
16
|
+
</template>
|
|
17
|
+
|
|
18
|
+
<script setup>
|
|
19
|
+
import { ref } from 'vue';
|
|
20
|
+
const formData = ref({ name: '', age: '' });
|
|
21
|
+
const formItems = [
|
|
22
|
+
{ prop: 'name', type: 'SohelpInput', label: '姓名', required: true },
|
|
23
|
+
{ prop: 'age', type: 'SohelpNumberInput', label: '年龄' }
|
|
24
|
+
];
|
|
25
|
+
const handleSubmit = (model) => { console.log(model); };
|
|
26
|
+
const handleReset = () => {};
|
|
27
|
+
</script>
|
|
13
28
|
```
|
|
14
29
|
|
|
15
30
|
## 属性 (Props)
|
|
16
31
|
|
|
17
|
-
| 属性名 | 类型 | 默认值 | 说明 |
|
|
18
|
-
|
|
|
19
|
-
|
|
|
20
|
-
|
|
|
21
|
-
|
|
|
22
|
-
|
|
|
23
|
-
|
|
|
24
|
-
|
|
|
32
|
+
| 属性名 | 类型 | 默认值 | 必填 | 说明 |
|
|
33
|
+
| --- | --- | --- | --- | --- |
|
|
34
|
+
| model | Object | - | 是 | 表单数据对象 |
|
|
35
|
+
| items | Array | - | 是 | 表单项配置数组 |
|
|
36
|
+
| data | Object | - | 否 | 表单关联数据对象 |
|
|
37
|
+
| rules | Object | - | 否 | 表单验证规则 |
|
|
38
|
+
| labelWidth | String / Number | '80px' | 否 | 标签宽度 |
|
|
39
|
+
| statusIcon | Boolean | - | 否 | 是否显示校验结果图标 |
|
|
40
|
+
| size | String | - | 否 | 表单尺寸 |
|
|
41
|
+
| disabled | Boolean | - | 否 | 是否禁用表单 |
|
|
42
|
+
| readonly | Boolean | false | 否 | 是否只读 |
|
|
43
|
+
| grid | Boolean / Object | - | 否 | 栅格布局配置,true 默认 span=12,或传入 ElCol 属性对象 |
|
|
44
|
+
| rowProps | Object | - | 否 | ElRow 属性,仅在 grid 模式下生效 |
|
|
45
|
+
| footer | Boolean | - | 否 | 是否显示底栏提交/重置按钮 |
|
|
46
|
+
| footerProps | Object | - | 否 | 底栏 ElFormItem 属性 |
|
|
47
|
+
| footerSlots | Object | - | 否 | 底栏 ElFormItem 插槽 |
|
|
48
|
+
| footerColProps | Object | { span: 24 } | 否 | 底栏 ElCol 属性 |
|
|
49
|
+
| submitText | String | '提交' | 否 | 提交按钮文本 |
|
|
50
|
+
| resetText | String | '重置' | 否 | 重置按钮文本 |
|
|
51
|
+
| saveParams | Object | {} | 否 | 保存时附加参数 |
|
|
25
52
|
|
|
26
53
|
## 事件 (Events)
|
|
27
54
|
|
|
28
|
-
| 事件名 |
|
|
29
|
-
|
|
|
30
|
-
|
|
|
31
|
-
|
|
|
55
|
+
| 事件名 | 回调参数 | 说明 |
|
|
56
|
+
| --- | --- | --- |
|
|
57
|
+
| updateValue | (prop: string, value: any) | 表单项值更新时触发 |
|
|
58
|
+
| submit | (model: Object) | 表单提交且验证通过时触发 |
|
|
59
|
+
| reset | - | 表单重置时触发 |
|
|
60
|
+
|
|
61
|
+
## 插槽 (Slots)
|
|
62
|
+
|
|
63
|
+
| 插槽名 | 说明 |
|
|
64
|
+
| --- | --- |
|
|
65
|
+
| topExtra | 表单顶部额外内容 |
|
|
66
|
+
| bottomExtra | 表单底部额外内容 |
|
|
67
|
+
| footer | 自定义底栏内容 |
|
|
68
|
+
| [动态插槽] | 透传至 ProFormItem 的自定义字段插槽 |
|
|
32
69
|
|
|
33
70
|
## 公开方法 (Expose)
|
|
34
71
|
|
|
35
|
-
- `
|
|
72
|
+
- `formRef` - 内部 ElForm 实例引用
|
|
73
|
+
- `validate()` - 验证整个表单,返回 Promise
|
|
74
|
+
- `validateField(props, callback)` - 验证指定字段
|
|
75
|
+
- `resetFields(props?)` - 重置表单字段
|
|
76
|
+
- `scrollToField(prop)` - 滚动到指定字段
|
|
77
|
+
- `clearValidate(props?)` - 清除验证信息
|
|
78
|
+
- `getRef(propName)` - 获取指定字段的 ProFormItem 组件实例
|
|
@@ -1,7 +1,13 @@
|
|
|
1
|
-
# SohelpProLayout
|
|
1
|
+
# SohelpProLayout 界面布局
|
|
2
2
|
|
|
3
|
-
基于 `EleProLayout`
|
|
3
|
+
基于 `EleProLayout` 的界面布局组件(待实现)。
|
|
4
4
|
|
|
5
|
-
##
|
|
5
|
+
## 基础用法
|
|
6
6
|
|
|
7
|
-
|
|
7
|
+
```vue
|
|
8
|
+
<template>
|
|
9
|
+
<sohelp-pro-layout />
|
|
10
|
+
</template>
|
|
11
|
+
```
|
|
12
|
+
|
|
13
|
+
> 该组件当前为占位状态,功能待实现。
|
|
@@ -1,11 +1,12 @@
|
|
|
1
1
|
<template>
|
|
2
|
-
<div
|
|
2
|
+
<div class="sohelp-pro-layout">
|
|
3
|
+
<!-- TODO: 待实现 - 界面布局(继承EleProLayout) -->
|
|
4
|
+
<el-empty description="界面布局 - 待实现" />
|
|
5
|
+
</div>
|
|
3
6
|
</template>
|
|
7
|
+
<script setup>
|
|
8
|
+
// TODO: 待实现
|
|
9
|
+
</script>
|
|
4
10
|
<script>
|
|
5
|
-
export default {
|
|
6
|
-
name: "SohelpProLayout"
|
|
7
|
-
}
|
|
11
|
+
export default { name: 'SohelpProLayout' };
|
|
8
12
|
</script>
|
|
9
|
-
<style scoped>
|
|
10
|
-
|
|
11
|
-
</style>
|
|
@@ -1,13 +1,37 @@
|
|
|
1
|
-
# SohelpProTable
|
|
1
|
+
# SohelpProTable 专业表格
|
|
2
2
|
|
|
3
|
-
基于
|
|
3
|
+
基于 ele-pro-table 的透传封装组件。将所有属性(`$attrs`)和插槽(`$slots`)直接透传到 ele-pro-table,提供统一的组件命名入口。
|
|
4
4
|
|
|
5
5
|
## 基础用法
|
|
6
6
|
|
|
7
|
-
```
|
|
8
|
-
<
|
|
7
|
+
```vue
|
|
8
|
+
<template>
|
|
9
|
+
<sohelp-pro-table
|
|
10
|
+
:columns="columns"
|
|
11
|
+
:datasource="datasource"
|
|
12
|
+
row-key="id"
|
|
13
|
+
>
|
|
14
|
+
<template #action="{ row }">
|
|
15
|
+
<el-button size="small" @click="handleEdit(row)">编辑</el-button>
|
|
16
|
+
</template>
|
|
17
|
+
</sohelp-pro-table>
|
|
18
|
+
</template>
|
|
19
|
+
|
|
20
|
+
<script setup>
|
|
21
|
+
const columns = [
|
|
22
|
+
{ prop: 'name', label: '名称' },
|
|
23
|
+
{ prop: 'status', label: '状态' }
|
|
24
|
+
];
|
|
25
|
+
const datasource = async ({ page, limit, where }) => {
|
|
26
|
+
// 返回 { total, results } 格式数据
|
|
27
|
+
};
|
|
28
|
+
</script>
|
|
9
29
|
```
|
|
10
30
|
|
|
11
|
-
##
|
|
31
|
+
## 属性 (Props)
|
|
32
|
+
|
|
33
|
+
所有属性透传到 ele-pro-table,请参考 ele-pro-table 文档。
|
|
34
|
+
|
|
35
|
+
## 插槽 (Slots)
|
|
12
36
|
|
|
13
|
-
|
|
37
|
+
所有插槽透传到 ele-pro-table,请参考 ele-pro-table 文档。
|