sh-view 1.5.3 → 1.6.0
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/package.json +7 -6
- package/packages/components/global-components/sh-code-editor/index.vue +1 -1
- package/packages/components/global-components/sh-icon/index.vue +1 -1
- package/packages/components/global-components/sh-iv-form/index.vue +1 -1
- package/packages/components/global-components/sh-upload/components/u-list.vue +1 -1
- package/packages/components/global-components/sh-upload/index.vue +1 -1
- package/packages/components/global-components/sh-vxe-table/index.vue +1 -1
- package/packages/components/global-components/sh-vxe-tree/index.vue +2 -2
- package/packages/components/global-components/sh-vxe-tree/vxe-direct-tree.vue +1 -1
- package/packages/components/global-components/sh-vxe-tree/vxe-select-tree.vue +1 -1
- package/packages/components/global-components/sh-word/index.vue +6 -10
- package/packages/components/index.js +25 -25
- package/packages/components/other-components/sh-menu-card/index.vue +1 -1
- package/packages/vxeTable/index.js +1 -1
- package/packages/vxeTable/render/{globalRenders.js → globalRenders.jsx} +22 -22
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "sh-view",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.6.0",
|
|
4
4
|
"description": "基于vxe-table、view-ui-plus二次封装",
|
|
5
5
|
"main": "packages/index.js",
|
|
6
6
|
"scripts": {
|
|
@@ -19,25 +19,26 @@
|
|
|
19
19
|
"@tinymce/tinymce-vue": "^5.0.0",
|
|
20
20
|
"babel-polyfill": "^6.26.0",
|
|
21
21
|
"codemirror": "^6.0.1",
|
|
22
|
-
"core-js": "^3.
|
|
22
|
+
"core-js": "^3.32.0",
|
|
23
23
|
"cron-parser": "^4.8.1",
|
|
24
|
-
"docx-preview": "^0.1.
|
|
24
|
+
"docx-preview": "^0.1.18",
|
|
25
25
|
"exceljs": "^4.3.0",
|
|
26
26
|
"file-saver": "^2.0.5",
|
|
27
27
|
"jspdf": "^2.5.1",
|
|
28
28
|
"jszip": "^3.10.1",
|
|
29
|
-
"tinymce": "^5.10.5",
|
|
30
29
|
"sh-tools": "^1.2.0",
|
|
30
|
+
"tinymce": "^5.10.5",
|
|
31
31
|
"view-ui-plus": "^1.3.14",
|
|
32
32
|
"vue": "^3.3.4",
|
|
33
|
+
"vue-masonry": "^0.16.0",
|
|
33
34
|
"vue-ripple-directive": "^2.0.1",
|
|
34
35
|
"vue-router": "^4.2.2",
|
|
35
|
-
"vue-masonry": "^0.16.0",
|
|
36
36
|
"vuex": "^4.1.0",
|
|
37
|
-
"vxe-table": "^4.5.0-beta.
|
|
37
|
+
"vxe-table": "^4.5.0-beta.16",
|
|
38
38
|
"vxe-table-plugin-export-pdf": "^3.0.4",
|
|
39
39
|
"vxe-table-plugin-export-xlsx": "^3.0.5",
|
|
40
40
|
"xe-clipboard": "^1.10.2",
|
|
41
|
+
"xe-utils": "^3.5.11",
|
|
41
42
|
"xlsx": "^0.18.5"
|
|
42
43
|
},
|
|
43
44
|
"devDependencies": {
|
|
@@ -198,7 +198,7 @@ export default {
|
|
|
198
198
|
let result = '',
|
|
199
199
|
error = null
|
|
200
200
|
try {
|
|
201
|
-
if (typeof modelValue === 'object') {
|
|
201
|
+
if (typeof modelValue === 'object' && value) {
|
|
202
202
|
result = out ? JSON.parse(value, null, indent) : JSON.stringify(value, null, indent)
|
|
203
203
|
} else {
|
|
204
204
|
result = value
|
|
@@ -178,7 +178,7 @@
|
|
|
178
178
|
import defaultData from './mixin/defaultData'
|
|
179
179
|
import props from './js/props'
|
|
180
180
|
import methods from './js/methods'
|
|
181
|
-
import importModal from './components/importModal'
|
|
181
|
+
import importModal from './components/importModal.vue'
|
|
182
182
|
export default {
|
|
183
183
|
name: 'ShTable',
|
|
184
184
|
components: {
|
|
@@ -13,8 +13,8 @@
|
|
|
13
13
|
</template>
|
|
14
14
|
|
|
15
15
|
<script>
|
|
16
|
-
import vxeDirectTree from './vxe-direct-tree'
|
|
17
|
-
import vxeSelectTree from './vxe-select-tree'
|
|
16
|
+
import vxeDirectTree from './vxe-direct-tree.vue'
|
|
17
|
+
import vxeSelectTree from './vxe-select-tree.vue'
|
|
18
18
|
import props from './js/props'
|
|
19
19
|
export default {
|
|
20
20
|
name: 'ShTree',
|
|
@@ -22,7 +22,7 @@
|
|
|
22
22
|
|
|
23
23
|
<script>
|
|
24
24
|
import defaultData from './mixin/defaultData'
|
|
25
|
-
import tableTree from './components/table-tree'
|
|
25
|
+
import tableTree from './components/table-tree.vue'
|
|
26
26
|
import treeMethods from './js/treeMethods'
|
|
27
27
|
export default {
|
|
28
28
|
name: 'ShDirectTree',
|
|
@@ -44,7 +44,7 @@
|
|
|
44
44
|
|
|
45
45
|
<script>
|
|
46
46
|
import defaultData from './mixin/defaultData'
|
|
47
|
-
import tableTree from './components/table-tree'
|
|
47
|
+
import tableTree from './components/table-tree.vue'
|
|
48
48
|
import treeMethods from './js/treeMethods'
|
|
49
49
|
export default {
|
|
50
50
|
name: 'ShSelectTree',
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
</template>
|
|
4
4
|
|
|
5
5
|
<script>
|
|
6
|
-
|
|
6
|
+
import * as docx from 'docx-preview'
|
|
7
7
|
export default {
|
|
8
8
|
name: 'ShWord',
|
|
9
9
|
props: {
|
|
@@ -82,17 +82,13 @@ export default {
|
|
|
82
82
|
},
|
|
83
83
|
methods: {
|
|
84
84
|
async wordRender() {
|
|
85
|
-
|
|
85
|
+
if(!this.url) return
|
|
86
86
|
try {
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
.renderAsync(content, that.$refs[that.wordRef], null, that.wordOption)
|
|
91
|
-
.then(res => {})
|
|
92
|
-
.catch(err => {})
|
|
93
|
-
}
|
|
87
|
+
let content = await this.getFileContent()
|
|
88
|
+
let res = await docx.renderAsync(content, this.$refs[this.wordRef], null, this.wordOption)
|
|
89
|
+
console.log(res)
|
|
94
90
|
} catch (e) {
|
|
95
|
-
|
|
91
|
+
this.msgerror(`初始化失败:${e.message}`)
|
|
96
92
|
}
|
|
97
93
|
},
|
|
98
94
|
// 获取文件流
|
|
@@ -1,29 +1,29 @@
|
|
|
1
1
|
// 全局公共封装组件
|
|
2
|
-
import ShCard from './global-components/sh-card'
|
|
3
|
-
import ShCodeEditor from './global-components/sh-code-editor'
|
|
4
|
-
import ShCorner from './global-components/sh-corner'
|
|
5
|
-
import ShCountTo from './global-components/sh-count-to'
|
|
6
|
-
import ShEmpty from './global-components/sh-empty'
|
|
7
|
-
import ShHeader from './global-components/sh-header'
|
|
8
|
-
import ShIcon from './global-components/sh-icon'
|
|
9
|
-
import ShIvForm from './global-components/sh-iv-form'
|
|
10
|
-
import ShLayout from './global-components/sh-layout'
|
|
11
|
-
import ShLoading from './global-components/sh-loading'
|
|
12
|
-
import ShNoticeBar from './global-components/sh-noticebar'
|
|
13
|
-
import ShPreview from './global-components/sh-preview'
|
|
14
|
-
import ShPullRefresh from './global-components/sh-pull-refresh'
|
|
15
|
-
import ShResult from './global-components/sh-result'
|
|
16
|
-
import ShSheet from './global-components/sh-sheet'
|
|
17
|
-
import ShUpload from './global-components/sh-upload'
|
|
18
|
-
import ShForm from './global-components/sh-vxe-form'
|
|
19
|
-
import ShList from './global-components/sh-vxe-list'
|
|
20
|
-
import ShModal from './global-components/sh-vxe-modal'
|
|
21
|
-
import ShQuery from './global-components/sh-vxe-query'
|
|
22
|
-
import ShTable from './global-components/sh-vxe-table'
|
|
23
|
-
import ShToolbar from './global-components/sh-vxe-toolbar'
|
|
24
|
-
import ShTree from './global-components/sh-vxe-tree'
|
|
25
|
-
import ShWaterFall from './global-components/sh-water-fall'
|
|
26
|
-
import ShWord from './global-components/sh-word'
|
|
2
|
+
import ShCard from './global-components/sh-card/index.vue'
|
|
3
|
+
import ShCodeEditor from './global-components/sh-code-editor/index.vue'
|
|
4
|
+
import ShCorner from './global-components/sh-corner/index.vue'
|
|
5
|
+
import ShCountTo from './global-components/sh-count-to/index.vue'
|
|
6
|
+
import ShEmpty from './global-components/sh-empty/index.vue'
|
|
7
|
+
import ShHeader from './global-components/sh-header/index.vue'
|
|
8
|
+
import ShIcon from './global-components/sh-icon/index.vue'
|
|
9
|
+
import ShIvForm from './global-components/sh-iv-form/index.vue'
|
|
10
|
+
import ShLayout from './global-components/sh-layout/index.vue'
|
|
11
|
+
import ShLoading from './global-components/sh-loading/index.vue'
|
|
12
|
+
import ShNoticeBar from './global-components/sh-noticebar/index.vue'
|
|
13
|
+
import ShPreview from './global-components/sh-preview/index.vue'
|
|
14
|
+
import ShPullRefresh from './global-components/sh-pull-refresh/index.vue'
|
|
15
|
+
import ShResult from './global-components/sh-result/index.vue'
|
|
16
|
+
import ShSheet from './global-components/sh-sheet/index.vue'
|
|
17
|
+
import ShUpload from './global-components/sh-upload/index.vue'
|
|
18
|
+
import ShForm from './global-components/sh-vxe-form/index.vue'
|
|
19
|
+
import ShList from './global-components/sh-vxe-list/index.vue'
|
|
20
|
+
import ShModal from './global-components/sh-vxe-modal/index.vue'
|
|
21
|
+
import ShQuery from './global-components/sh-vxe-query/index.vue'
|
|
22
|
+
import ShTable from './global-components/sh-vxe-table/index.vue'
|
|
23
|
+
import ShToolbar from './global-components/sh-vxe-toolbar/index.vue'
|
|
24
|
+
import ShTree from './global-components/sh-vxe-tree/index.vue'
|
|
25
|
+
import ShWaterFall from './global-components/sh-water-fall/index.vue'
|
|
26
|
+
import ShWord from './global-components/sh-word/index.vue'
|
|
27
27
|
|
|
28
28
|
const components = {
|
|
29
29
|
ShCard,
|
|
@@ -3,7 +3,7 @@ import './css/index.scss'
|
|
|
3
3
|
import VXETablePluginExportXLSX from 'vxe-table-plugin-export-xlsx'
|
|
4
4
|
import VXETablePluginExportPDF from 'vxe-table-plugin-export-pdf'
|
|
5
5
|
import XEClipboard from 'xe-clipboard'
|
|
6
|
-
import { defaultPublicRenders, defaultExtraRenders, defaultFilterRenders, defaultPublicRendersNames } from './render/globalRenders'
|
|
6
|
+
import { defaultPublicRenders, defaultExtraRenders, defaultFilterRenders, defaultPublicRendersNames } from './render/globalRenders.jsx'
|
|
7
7
|
|
|
8
8
|
let vxeOptions = {
|
|
9
9
|
zIndex: 599,
|
|
@@ -1,32 +1,32 @@
|
|
|
1
1
|
// 渲染器组件封装
|
|
2
|
-
import vxeRenderInput from './cell/vxe-render-input'
|
|
3
|
-
import vxeRenderTextarea from './cell/vxe-render-textarea'
|
|
4
|
-
import vxeRenderSelect from './cell/vxe-render-select'
|
|
5
|
-
import vxeRenderTree from './cell/vxe-render-tree'
|
|
6
|
-
import vxeRenderTime from './cell/vxe-render-time'
|
|
7
|
-
import vxeRenderProgress from './cell/vxe-render-progress'
|
|
8
|
-
import vxeRenderSwitch from './cell/vxe-render-switch'
|
|
9
|
-
import vxeRenderMoney from './cell/vxe-render-money'
|
|
10
|
-
import vxeRenderCheckbox from './cell/vxe-render-checkbox'
|
|
11
|
-
import vxeRenderCheckgroup from './cell/vxe-render-checkgroup'
|
|
12
|
-
import vxeRenderRadio from './cell/vxe-render-radio'
|
|
13
|
-
import vxeRenderRadiogroup from './cell/vxe-render-radiogroup'
|
|
14
|
-
import vxeRenderTable from './cell/vxe-render-table'
|
|
15
|
-
import vxeRenderImg from './cell/vxe-render-img'
|
|
16
|
-
import vxeRenderHref from './cell/vxe-render-href'
|
|
17
|
-
import vxeRenderUpload from './cell/vxe-render-upload'
|
|
18
|
-
import vxeRenderCode from './cell/vxe-render-code'
|
|
19
|
-
import vxeRenderGoption from './cell/vxe-render-goption'
|
|
2
|
+
import vxeRenderInput from './cell/vxe-render-input.vue'
|
|
3
|
+
import vxeRenderTextarea from './cell/vxe-render-textarea.vue'
|
|
4
|
+
import vxeRenderSelect from './cell/vxe-render-select.vue'
|
|
5
|
+
import vxeRenderTree from './cell/vxe-render-tree.vue'
|
|
6
|
+
import vxeRenderTime from './cell/vxe-render-time.vue'
|
|
7
|
+
import vxeRenderProgress from './cell/vxe-render-progress.vue'
|
|
8
|
+
import vxeRenderSwitch from './cell/vxe-render-switch.vue'
|
|
9
|
+
import vxeRenderMoney from './cell/vxe-render-money.vue'
|
|
10
|
+
import vxeRenderCheckbox from './cell/vxe-render-checkbox.vue'
|
|
11
|
+
import vxeRenderCheckgroup from './cell/vxe-render-checkgroup.vue'
|
|
12
|
+
import vxeRenderRadio from './cell/vxe-render-radio.vue'
|
|
13
|
+
import vxeRenderRadiogroup from './cell/vxe-render-radiogroup.vue'
|
|
14
|
+
import vxeRenderTable from './cell/vxe-render-table.vue'
|
|
15
|
+
import vxeRenderImg from './cell/vxe-render-img.vue'
|
|
16
|
+
import vxeRenderHref from './cell/vxe-render-href.vue'
|
|
17
|
+
import vxeRenderUpload from './cell/vxe-render-upload.vue'
|
|
18
|
+
import vxeRenderCode from './cell/vxe-render-code.vue'
|
|
19
|
+
import vxeRenderGoption from './cell/vxe-render-goption.vue'
|
|
20
20
|
|
|
21
21
|
// 头部渲染器封装
|
|
22
|
-
import vxeHeaderMoney from './header/vxe-header-money'
|
|
22
|
+
import vxeHeaderMoney from './header/vxe-header-money.vue'
|
|
23
23
|
|
|
24
24
|
// 底部渲染器封装
|
|
25
|
-
import vxeFooterInput from './footer/vxe-footer-input'
|
|
26
|
-
import vxeFooterMoney from './footer/vxe-footer-money'
|
|
25
|
+
import vxeFooterInput from './footer/vxe-footer-input.vue'
|
|
26
|
+
import vxeFooterMoney from './footer/vxe-footer-money.vue'
|
|
27
27
|
|
|
28
28
|
// 过滤器组件封装
|
|
29
|
-
import vxeFilterInput from './filters/vxe-filter-input'
|
|
29
|
+
import vxeFilterInput from './filters/vxe-filter-input.vue'
|
|
30
30
|
|
|
31
31
|
// 系统图片
|
|
32
32
|
import imgPlaceholder from '../../assets/img/square-image.png'
|