zydx-plus 1.35.472 → 1.35.473
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 +1 -1
- package/src/components/biz_header/src/bizHeader.vue +28 -3
- package/src/components/editor/src/butJson.js +9 -9
- package/src/components/editor/src/editor.vue +61 -30
- package/src/components/editor2/src/editor.vue +2 -0
- package/src/components/menuTree/src/ZydxMenuTree.vue +39 -34
- package/src/components/mind/src/mind.vue +4 -0
- package/src/components/treeList/src/treeList.vue +4 -4
- package/src/index.js +1 -1
package/package.json
CHANGED
|
@@ -22,14 +22,14 @@
|
|
|
22
22
|
<template v-if="buttonInfo instanceof Object" v-for="(childButtonInfo, childButtonIndex) in buttonInfo">
|
|
23
23
|
<!-- 在课上渲染的 -->
|
|
24
24
|
<button class="defaultButton"
|
|
25
|
-
:class="childButtonIndex === getSelectBtnIndex && selectItem.level === item.level
|
|
25
|
+
:class="{'active theme-text' : (childButtonIndex === getSelectBtnIndex && selectItem.level === item.level) && (headerType === 2 && isHasDemandContent && childButtonIndex === 'demand' || headerType === 2 && childButtonIndex !== 'demand' || headerType !== 2), 'defaultDisableButton': headerType === 2 && !isHasDemandContent && childButtonIndex === 'demand' }"
|
|
26
26
|
v-if="item.level === 0 && buttonIndex === 'headLevel' && childButtonIndex !== 'default'"
|
|
27
27
|
@click="clickRightBtn(item, childButtonIndex, childButtonInfo)"
|
|
28
28
|
v-html="childButtonInfo"
|
|
29
29
|
/>
|
|
30
30
|
<!-- 单独在最低节点设置的按钮 -->
|
|
31
31
|
<button :ref="childButtonIndex + item.catalogId" class="defaultButton"
|
|
32
|
-
:class="childButtonIndex === getSelectBtnIndex && selectItem.level === item.level
|
|
32
|
+
:class="{'active theme-text' : childButtonIndex === getSelectBtnIndex && selectItem.level === item.level && (isHasResContent && childButtonIndex === 'viewResource' || childButtonIndex !== 'viewResource'), 'defaultDisableButton': !isHasResContent && childButtonIndex === 'viewResource'}"
|
|
33
33
|
v-if="item.level !== 0 && (!item.children || item.children.length === 0) && buttonIndex === 'lowLevel' && childButtonIndex !== 'default' && (tabType === 2 && childButtonIndex !=='analysis' || tabType === 0)"
|
|
34
34
|
@click="clickRightBtn(item, childButtonIndex, childButtonInfo)"
|
|
35
35
|
v-html="childButtonInfo"
|
|
@@ -102,6 +102,14 @@ export default {
|
|
|
102
102
|
headerType: {
|
|
103
103
|
type: Number,
|
|
104
104
|
required: true
|
|
105
|
+
},
|
|
106
|
+
isHasDemandContent: { // 学生端要求是否有内容
|
|
107
|
+
type: Boolean,
|
|
108
|
+
default: true
|
|
109
|
+
},
|
|
110
|
+
isHasResContent: { // 教师端-演示阅读、教学互动-模块最低节点资源列表是否有内容
|
|
111
|
+
type: Boolean,
|
|
112
|
+
default: true
|
|
105
113
|
}
|
|
106
114
|
},
|
|
107
115
|
data() {
|
|
@@ -243,7 +251,24 @@ export default {
|
|
|
243
251
|
margin: 1px;
|
|
244
252
|
box-sizing: border-box;
|
|
245
253
|
}
|
|
246
|
-
|
|
254
|
+
.defaultDisableButton {
|
|
255
|
+
width: auto;
|
|
256
|
+
min-width: 60px;
|
|
257
|
+
height: 20px;
|
|
258
|
+
font-size: 12px;
|
|
259
|
+
line-height: 20px;
|
|
260
|
+
color: #717171;
|
|
261
|
+
border: #717171 1px solid;
|
|
262
|
+
border-radius: 3px;
|
|
263
|
+
text-align: center;
|
|
264
|
+
cursor: pointer;
|
|
265
|
+
background-color: #fff;
|
|
266
|
+
user-select: none;
|
|
267
|
+
margin: 1px;
|
|
268
|
+
box-sizing: border-box;
|
|
269
|
+
pointer-events: none;
|
|
270
|
+
/*禁止点击*/
|
|
271
|
+
}
|
|
247
272
|
.active{
|
|
248
273
|
/* color: rgba(0, 255, 0, 1) !important; */
|
|
249
274
|
}
|
|
@@ -43,9 +43,9 @@ export function butJson(editor, data) {
|
|
|
43
43
|
<p data-signid="subject" style="text-align: center;margin: 80px 0 60px"><strong><span style="font-size: 24px; font-family: SimHei; color: rgb(0, 0, 0);line-height: 1;">请在此处输入标题</span></strong></p>
|
|
44
44
|
<p data-signid="lookUp"><strong><span style="font-size: 16px; font-family: SimHei; color: rgb(0, 0, 0)">请在此处输入抬头:</span></strong></p>
|
|
45
45
|
<p data-signid="text" class="indent"><span style="font-size: 14px; font-family: SimHei; color: rgb(0, 0, 0)">请在此处输入正文文本</span></p>
|
|
46
|
-
<p data-signid="title-1" class="title indent"><strong><span style="font-size: 16px; font-family: SimHei; color: rgb(0, 0, 0)">一、请在此处输入一级标题</span></strong></p>
|
|
46
|
+
<p data-signid="title-1" class="title ${randomId()} indent"><strong><span style="font-size: 16px; font-family: SimHei; color: rgb(0, 0, 0)">一、请在此处输入一级标题</span></strong></p>
|
|
47
47
|
<p data-signid="text" class="indent"><span style="font-size: 14px; font-family: SimHei; color: rgb(0, 0, 0)">请在此处输入正文文本</span></p>
|
|
48
|
-
<p data-signid="title-2" class="title indent"><strong><span style="font-size: 16px; font-family: SimHei; color: rgb(0, 0, 0)">(一)请在此处输入二级标题</span></strong></p>
|
|
48
|
+
<p data-signid="title-2" class="title ${randomId()} indent"><strong><span style="font-size: 16px; font-family: SimHei; color: rgb(0, 0, 0)">(一)请在此处输入二级标题</span></strong></p>
|
|
49
49
|
<p data-signid="text" class="indent"><span style="font-size: 14px; font-family: SimHei; color: rgb(0, 0, 0)">请在此处输入正文文本</span></p>
|
|
50
50
|
<p data-signid="paragraph" style="margin: 30px 0px 0px; text-align: right"><strong><span style="font-size: 14px; color: rgb(0, 0, 0)">请在此处输入落款</span></strong></p>
|
|
51
51
|
<p data-signid="date" style="text-align: right"><strong><span style="font-size: 14px; color: rgb(0, 0, 0)">请在此处输入日期</span></strong></p>`
|
|
@@ -57,9 +57,9 @@ export function butJson(editor, data) {
|
|
|
57
57
|
html: `<p data-signid="subject" style="text-align: center;"><strong><span style="font-size: 24px; font-family: SimHei; color: rgb(0, 0, 0);">请在此处输入标题</span></strong></p>
|
|
58
58
|
<p data-signid="author" class="author" style="text-align: center;padding-bottom: 30px;"><span style="font-size: 14px; font-family: FangSong; color: rgb(0, 0, 0);">请在此处输入作者/来源</span></p>
|
|
59
59
|
<p data-signid="text" class="indent"><span style="font-size: 14px; font-family: SimHei; color: rgb(0, 0, 0)">请在此处输入正文文本</span></p>
|
|
60
|
-
<p data-signid="title-1" class="title indent"><strong><span style="font-size: 16px; font-family: SimHei; color: rgb(0, 0, 0)">一、请在此处输入一级标题</span></strong></p>
|
|
60
|
+
<p data-signid="title-1" class="title ${randomId()} indent"><strong><span style="font-size: 16px; font-family: SimHei; color: rgb(0, 0, 0)">一、请在此处输入一级标题</span></strong></p>
|
|
61
61
|
<p data-signid="text" class="indent"><span style="font-size: 14px; font-family: SimHei; color: rgb(0, 0, 0)">请在此处输入正文文本</span></p>
|
|
62
|
-
<p data-signid="title-2" class="title indent"><strong><span style="font-size: 16px; font-family: SimHei; color: rgb(0, 0, 0)">(一)请在此处输入二级标题</span></strong></p>
|
|
62
|
+
<p data-signid="title-2" class="title ${randomId()} indent"><strong><span style="font-size: 16px; font-family: SimHei; color: rgb(0, 0, 0)">(一)请在此处输入二级标题</span></strong></p>
|
|
63
63
|
<p data-signid="text" class="indent"><span style="font-size: 14px; font-family: SimHei; color: rgb(0, 0, 0)">请在此处输入正文文本</span></p>
|
|
64
64
|
<p data-signid="paragraph" style="margin: 30px 0px 0px; text-align: right"><strong><span style="font-size: 14px; color: rgb(0, 0, 0)">请在此处输入落款</span></strong></p>
|
|
65
65
|
<p data-signid="date" style="text-align: right"><strong><span style="font-size: 14px; color: rgb(0, 0, 0)">请在此处输入日期</span></strong></p>`
|
|
@@ -73,9 +73,9 @@ export function butJson(editor, data) {
|
|
|
73
73
|
<p data-signid="abstract" class="abstract"><strong><span style="font-size: 14px; font-family: SimSun; color: rgb(0, 0, 0)">摘要:</span></strong> <span style="font-size: 14px; font-family: FangSong; color: rgb(0, 0, 0)">请在此处输入摘要文本...</span></p>
|
|
74
74
|
<p data-signid="keyword" class="keyword"><strong><span contenteditable="false" style="font-size: 14px; font-family: SimSun; color: rgb(0, 0, 0)">关键词:</span></strong> <span style="font-size: 14px; font-family: FangSong; color: rgb(0, 0, 0)"> 请在此处输入关键字...</span></p>
|
|
75
75
|
<p data-signid="text" class="indent"><span style="font-size: 14px; font-family: SimHei; color: rgb(0, 0, 0)">请在此处输入正文文本</span></p>
|
|
76
|
-
<p data-signid="title-1" class="title indent"><strong><span style="font-size: 16px; font-family: SimHei; color: rgb(0, 0, 0)">一、请在此处输入一级标题</span></strong></p>
|
|
76
|
+
<p data-signid="title-1" class="title ${randomId()} indent"><strong><span style="font-size: 16px; font-family: SimHei; color: rgb(0, 0, 0)">一、请在此处输入一级标题</span></strong></p>
|
|
77
77
|
<p data-signid="text" class="indent"><span style="font-size: 14px; font-family: SimHei; color: rgb(0, 0, 0)">请在此处输入正文文本</span></p>
|
|
78
|
-
<p data-signid="title-2" class="title indent"><strong><span style="font-size: 16px; font-family: SimH ei; color: rgb(0, 0, 0)">(一)请在此处输入二级标题</span></strong></p>
|
|
78
|
+
<p data-signid="title-2" class="title ${randomId()} indent"><strong><span style="font-size: 16px; font-family: SimH ei; color: rgb(0, 0, 0)">(一)请在此处输入二级标题</span></strong></p>
|
|
79
79
|
<p data-signid="text" class="indent"><span style="font-size: 14px; font-family: SimHei; color: rgb(0, 0, 0)">请在此处输入正文文本(复用格式建议直接复制粘贴段落)</span></p>
|
|
80
80
|
<p data-signid="splitLine" contenteditable="false" class="paging-line">分 页 线(保存文档时线下内容另起一页)</p>
|
|
81
81
|
<p data-signid="annotation" contenteditable="false" style="text-align: center;"><strong><span style="font-size: 24px; font-family: SimHei; color: rgb(0, 0, 0);">注释</span></strong></p>
|
|
@@ -210,13 +210,13 @@ export function butJson(editor, data) {
|
|
|
210
210
|
name: '一级标题',
|
|
211
211
|
key: 'firstLevelHeading',
|
|
212
212
|
menuKeys: [],
|
|
213
|
-
html: `<p data-signid="title-1" class="title indent"><strong><span style="font-size: 16px; font-family: SimHei; color: rgb(0, 0, 0)">一、请在此处输入一级标题</span></strong></p>`
|
|
213
|
+
html: `<p data-signid="title-1" class="title ${randomId()} indent"><strong><span style="font-size: 16px; font-family: SimHei; color: rgb(0, 0, 0)">一、请在此处输入一级标题</span></strong></p>`
|
|
214
214
|
},
|
|
215
215
|
secondaryHeading: {
|
|
216
216
|
name: '二级标题',
|
|
217
217
|
key: 'secondaryHeading',
|
|
218
218
|
menuKeys: [],
|
|
219
|
-
html: `<p data-signid="title-2" class="title indent"><strong><span style="font-size: 16px; font-family: SimHei; color: rgb(0, 0, 0)">(一)请在此处输入二级标题</span></strong></p>`
|
|
219
|
+
html: `<p data-signid="title-2" class="title ${randomId()} indent"><strong><span style="font-size: 16px; font-family: SimHei; color: rgb(0, 0, 0)">(一)请在此处输入二级标题</span></strong></p>`
|
|
220
220
|
},
|
|
221
221
|
paragraphBody: {
|
|
222
222
|
name: '正文文本',
|
|
@@ -470,4 +470,4 @@ function getTime() {
|
|
|
470
470
|
let month = date.getMonth() + 1
|
|
471
471
|
let day = date.getDate() < 10 ? '0' + date.getDate() : date.getDate()
|
|
472
472
|
return year + '年' + month + '月' + day + '日'
|
|
473
|
-
}
|
|
473
|
+
}
|
|
@@ -924,10 +924,9 @@ export default {
|
|
|
924
924
|
Authorization: localStorage.getItem("remember") === "1" ? localStorage.getItem('sessionId') : sessionStorage.getItem('sessionId')
|
|
925
925
|
},
|
|
926
926
|
customInsert(res, insertFn) {
|
|
927
|
-
|
|
928
|
-
|
|
929
|
-
|
|
930
|
-
},100)
|
|
927
|
+
setTimeout(() => {
|
|
928
|
+
insertFn('http://192.168.5.213:8888' + res.data)
|
|
929
|
+
},100)
|
|
931
930
|
},
|
|
932
931
|
onSuccess(file, res) {
|
|
933
932
|
console.log('图片上传成功', file, res)
|
|
@@ -1357,7 +1356,7 @@ export default {
|
|
|
1357
1356
|
// // this.close()
|
|
1358
1357
|
// })
|
|
1359
1358
|
},
|
|
1360
|
-
emits: ['confirm', 'enclosure', 'enlDownload', 'enlSee'],
|
|
1359
|
+
emits: ['confirm', 'enclosure', 'enlDownload', 'enlSee', 'changeOutlineMenu'],
|
|
1361
1360
|
methods: {
|
|
1362
1361
|
showAi() {
|
|
1363
1362
|
this.isShowAi = !this.isShowAi
|
|
@@ -2125,8 +2124,11 @@ export default {
|
|
|
2125
2124
|
this.htmlArr = []
|
|
2126
2125
|
const data = this.$refs['editing-cont'].$el.childNodes[0]?.childNodes//document.querySelectorAll('.editing-cont')[0]?.childNodes[0]?.childNodes
|
|
2127
2126
|
this.wit = this.$refs['read-only'].offsetWidth//document.getElementsByClassName('read-only')[0]?.offsetWidth + 20
|
|
2128
|
-
if (this.wit > 900)
|
|
2129
|
-
|
|
2127
|
+
if (this.wit > 900) {
|
|
2128
|
+
this.$refs['read-only'].style.width = '900px'
|
|
2129
|
+
this.wit = 900
|
|
2130
|
+
}
|
|
2131
|
+
let max = this.wit * 1.6 - 186
|
|
2130
2132
|
let pHeight = 0
|
|
2131
2133
|
let html = ''
|
|
2132
2134
|
for (let i = 0; i < data.length; i++) {
|
|
@@ -2154,7 +2156,11 @@ export default {
|
|
|
2154
2156
|
// pHeight = 0
|
|
2155
2157
|
// html = ''
|
|
2156
2158
|
// }
|
|
2157
|
-
let
|
|
2159
|
+
let top = parseInt(getComputedStyle(data[i]).paddingTop)
|
|
2160
|
+
let mtop = parseInt(getComputedStyle(data[i]).marginTop)
|
|
2161
|
+
let Bottom = parseInt(getComputedStyle(data[i]).paddingBottom)
|
|
2162
|
+
let mBottom = parseInt(getComputedStyle(data[i]).marginBottom)
|
|
2163
|
+
let text = data[i].offsetHeight+Bottom+top+mtop+mBottom
|
|
2158
2164
|
if ((pHeight + text) > max) {
|
|
2159
2165
|
const {start, end, size} = this.rows(data[i], max - pHeight)
|
|
2160
2166
|
let child = data[i].childNodes[0]
|
|
@@ -2565,16 +2571,15 @@ export default {
|
|
|
2565
2571
|
}
|
|
2566
2572
|
if (v === 'uploadImage') {
|
|
2567
2573
|
up.customInsert(res, (data) => {
|
|
2568
|
-
|
|
2569
|
-
|
|
2570
|
-
|
|
2571
|
-
|
|
2572
|
-
|
|
2573
|
-
|
|
2574
|
-
|
|
2575
|
-
|
|
2576
|
-
|
|
2577
|
-
},100)
|
|
2574
|
+
setTimeout(() => {
|
|
2575
|
+
const cla = this.randomId()
|
|
2576
|
+
const html = `<p class="imgCont ${cla}"><img src="${data}" alt="" /></p>`
|
|
2577
|
+
this.editor.chain().focus().insertContentAt(this.selection(), html).run()
|
|
2578
|
+
if (this.selection() <= 6 && this.selection() > 2) this.selectionClass2(cla)
|
|
2579
|
+
if (this.selectionClass(cla)) {
|
|
2580
|
+
this.editor.chain().focus().insertContentAt(this.selection(), '<p></p>').run()
|
|
2581
|
+
}
|
|
2582
|
+
},100)
|
|
2578
2583
|
})
|
|
2579
2584
|
}
|
|
2580
2585
|
up.onSuccess(file, res) // 上传成功回调
|
|
@@ -2826,19 +2831,19 @@ export default {
|
|
|
2826
2831
|
// 切换版式
|
|
2827
2832
|
if (data.key === 'switchingFormat') {
|
|
2828
2833
|
this.templateType = key.key
|
|
2829
|
-
if(this.templateType
|
|
2834
|
+
if (this.templateType === 'freeTypesetting') {
|
|
2830
2835
|
|
|
2831
2836
|
await this.changeTemplateType()
|
|
2832
2837
|
}
|
|
2833
|
-
if(this.templateType
|
|
2838
|
+
if (this.templateType === 'officialDocumentFormat') {
|
|
2834
2839
|
|
|
2835
2840
|
await this.changeTemplateType()
|
|
2836
2841
|
}
|
|
2837
|
-
if(this.templateType
|
|
2842
|
+
if (this.templateType === 'newsFormat') {
|
|
2838
2843
|
|
|
2839
2844
|
await this.changeTemplateType()
|
|
2840
2845
|
}
|
|
2841
|
-
if(this.templateType
|
|
2846
|
+
if (this.templateType === 'paperFormat') {
|
|
2842
2847
|
|
|
2843
2848
|
await this.changeTemplateType()
|
|
2844
2849
|
}
|
|
@@ -3067,7 +3072,6 @@ export default {
|
|
|
3067
3072
|
// 红头文件
|
|
3068
3073
|
if (data.key === 'redMenu') {
|
|
3069
3074
|
const html = butJson(this.editor, this.menusText)[data.key].html
|
|
3070
|
-
// console.log('menusHtml',menusHtml)
|
|
3071
3075
|
// const html = menusHtml.filter(item => item.key == key.key)[0].html
|
|
3072
3076
|
const r = await this.signIdData('red')
|
|
3073
3077
|
if (r === -1) {
|
|
@@ -3079,11 +3083,13 @@ export default {
|
|
|
3079
3083
|
if (data.key === 'firstLevelHeading') {
|
|
3080
3084
|
const html = butJson(this.editor, this.menusText)[data.key].html
|
|
3081
3085
|
this.editor.chain().focus().insertContentAt(this.selection(), html).run()
|
|
3086
|
+
this.$emit('changeOutlineMenu')
|
|
3082
3087
|
}
|
|
3083
3088
|
// 二级标题
|
|
3084
3089
|
if (data.key === 'secondaryHeading') {
|
|
3085
3090
|
const html = butJson(this.editor, this.menusText)[data.key].html
|
|
3086
3091
|
this.editor.chain().focus().insertContentAt(this.selection(), html).run()
|
|
3092
|
+
this.$emit('changeOutlineMenu')
|
|
3087
3093
|
}
|
|
3088
3094
|
// 正文
|
|
3089
3095
|
if (data.key === 'paragraphBody') {
|
|
@@ -3188,13 +3194,14 @@ export default {
|
|
|
3188
3194
|
if (key.key === 'text') {
|
|
3189
3195
|
this.editor.commands.setTitleId(key.key)
|
|
3190
3196
|
this.editor.commands.unsetSignId()
|
|
3191
|
-
this.editor.chain().focus().unsetBold().setTextAlign('left').run()
|
|
3197
|
+
this.editor.chain().focus().unsetBold().setFontSize('14px').setTextAlign('left').run()
|
|
3192
3198
|
} else {
|
|
3193
3199
|
const t = key.key.split('-')[0]
|
|
3194
3200
|
this.editor.commands.setSignId(key.key)
|
|
3195
3201
|
this.editor.commands.setTitleId(`${t} ${this.randomId()}`)
|
|
3196
|
-
this.editor.chain().focus().setBold().setTextAlign('left').run()
|
|
3202
|
+
this.editor.chain().focus().setBold().setFontSize('16px').setTextAlign('left').run()
|
|
3197
3203
|
}
|
|
3204
|
+
this.$emit('changeOutlineMenu')
|
|
3198
3205
|
}
|
|
3199
3206
|
// 对齐方式
|
|
3200
3207
|
if (data.key === 'alignmentMode') {
|
|
@@ -3932,9 +3939,9 @@ export default {
|
|
|
3932
3939
|
const json = this.editor.getJSON()
|
|
3933
3940
|
let jsonData = json.content.filter(item => !(/a-/.test(item.attrs.signId)))
|
|
3934
3941
|
this.editor?.commands.setContent(jsonData)
|
|
3935
|
-
this.interpositionData.forEach((item)=>{
|
|
3936
|
-
if(item.type!=='taggingMenu') return
|
|
3937
|
-
index+=1
|
|
3942
|
+
this.interpositionData.forEach((item) => {
|
|
3943
|
+
if (item.type !== 'taggingMenu') return
|
|
3944
|
+
index += 1
|
|
3938
3945
|
const t = this.signIdData('annotation')
|
|
3939
3946
|
const b = this.signIdData('annotationSplitLine') // 判断是否有分页线
|
|
3940
3947
|
const html = `<p contenteditable="false" data-signId="annotation" style="text-align: center;margin-bottom: 30px;"><span style="font-weight: 700;font-size: 16px;">注释:</span></p>`
|
|
@@ -3968,7 +3975,7 @@ export default {
|
|
|
3968
3975
|
}
|
|
3969
3976
|
},
|
|
3970
3977
|
// 删除举例说明
|
|
3971
|
-
delGiveExample(){
|
|
3978
|
+
delGiveExample() {
|
|
3972
3979
|
const json = this.editor.getJSON()
|
|
3973
3980
|
let jsonData = json.content.filter(item => !(/r-l/.test(item.attrs.signId)) && !(/a-/.test(item.attrs.signId)))
|
|
3974
3981
|
this.editor?.commands.setContent(jsonData)
|
|
@@ -4021,6 +4028,17 @@ export default {
|
|
|
4021
4028
|
}
|
|
4022
4029
|
//赋值,这样实现的效果就是用户按下非数字不会有任何反应
|
|
4023
4030
|
element.target.value = val;
|
|
4031
|
+
},
|
|
4032
|
+
goAnchors(item) {
|
|
4033
|
+
const element = document.querySelector(`.${item.anchors}`)
|
|
4034
|
+
if (element) {
|
|
4035
|
+
if (this.readOnly) {
|
|
4036
|
+
let bodys = document.querySelector(`.z-editor`)
|
|
4037
|
+
bodys.scrollTop = element.offsetTop
|
|
4038
|
+
return
|
|
4039
|
+
}
|
|
4040
|
+
element.scrollIntoView({behavior: 'smooth'});
|
|
4041
|
+
}
|
|
4024
4042
|
}
|
|
4025
4043
|
}
|
|
4026
4044
|
}
|
|
@@ -4087,7 +4105,7 @@ export default {
|
|
|
4087
4105
|
}
|
|
4088
4106
|
|
|
4089
4107
|
:deep(.read-only-p p) {
|
|
4090
|
-
line-height:
|
|
4108
|
+
line-height: 1.5;
|
|
4091
4109
|
text-align: justify;
|
|
4092
4110
|
white-space: pre-wrap;
|
|
4093
4111
|
}
|
|
@@ -4241,6 +4259,9 @@ li {
|
|
|
4241
4259
|
border: 1px solid rgba(204, 204, 204, 1);
|
|
4242
4260
|
position: relative;
|
|
4243
4261
|
width: 100%;
|
|
4262
|
+
max-height: 900px;
|
|
4263
|
+
overflow-y: auto;
|
|
4264
|
+
scrollbar-width: none;
|
|
4244
4265
|
}
|
|
4245
4266
|
|
|
4246
4267
|
.editor-header {
|
|
@@ -4573,10 +4594,12 @@ li {
|
|
|
4573
4594
|
align-items: flex-start;
|
|
4574
4595
|
font-size: 12px;
|
|
4575
4596
|
}
|
|
4597
|
+
|
|
4576
4598
|
:deep(p:has(>img)) {
|
|
4577
4599
|
line-height: 0 !important;
|
|
4578
4600
|
text-indent: 0 !important;
|
|
4579
4601
|
}
|
|
4602
|
+
|
|
4580
4603
|
.tip-btnBox > div {
|
|
4581
4604
|
width: 60px;
|
|
4582
4605
|
height: 20px;
|
|
@@ -4879,4 +4902,12 @@ li {
|
|
|
4879
4902
|
border: 1px solid #000;
|
|
4880
4903
|
border-radius: 50%;
|
|
4881
4904
|
}
|
|
4905
|
+
|
|
4906
|
+
:deep(.drag-pop-shadow){
|
|
4907
|
+
top:200px
|
|
4908
|
+
}
|
|
4909
|
+
|
|
4910
|
+
* {
|
|
4911
|
+
box-sizing: border-box;
|
|
4912
|
+
}
|
|
4882
4913
|
</style>
|
|
@@ -1023,6 +1023,7 @@ export default {
|
|
|
1023
1023
|
.ed-head {
|
|
1024
1024
|
display: flex;
|
|
1025
1025
|
justify-content: center;
|
|
1026
|
+
flex-wrap: wrap;
|
|
1026
1027
|
}
|
|
1027
1028
|
|
|
1028
1029
|
.ed-head-but {
|
|
@@ -1045,6 +1046,7 @@ export default {
|
|
|
1045
1046
|
float: right;
|
|
1046
1047
|
}
|
|
1047
1048
|
.ed-title {
|
|
1049
|
+
min-width: 120px;
|
|
1048
1050
|
flex: 1;
|
|
1049
1051
|
text-align: left;
|
|
1050
1052
|
font-size: 16px;
|
|
@@ -3,11 +3,11 @@
|
|
|
3
3
|
<slot></slot>
|
|
4
4
|
<div v-for="(item, index) in targetTree" :key="index">
|
|
5
5
|
<zydx-menu-tree-info
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
6
|
+
:menuConfig="menuConfig"
|
|
7
|
+
:nodeLevel="nodeLevel"
|
|
8
|
+
:menu-info="item"
|
|
9
|
+
:selectItem="selectItem"
|
|
10
|
+
@clickItem="clickItem"
|
|
11
11
|
></zydx-menu-tree-info>
|
|
12
12
|
</div>
|
|
13
13
|
</div>
|
|
@@ -15,6 +15,7 @@
|
|
|
15
15
|
|
|
16
16
|
<script>
|
|
17
17
|
import zydxMenuTreeInfo from "./ZydxMenuTreeInfo";
|
|
18
|
+
|
|
18
19
|
export default {
|
|
19
20
|
name: "zydx-menu-tree",
|
|
20
21
|
components: {
|
|
@@ -23,17 +24,17 @@ export default {
|
|
|
23
24
|
props: {
|
|
24
25
|
// 目录配置
|
|
25
26
|
menuConfig: {
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
27
|
+
type: Object,
|
|
28
|
+
default: function () {
|
|
29
|
+
return {
|
|
30
|
+
isShowUpDown: false, // 是否显示收起展开
|
|
31
|
+
isShowLine: false, // 是否显示下划线
|
|
32
|
+
isShowBtn: false, // 显示按钮或者图标
|
|
33
|
+
isCheckBox: false, // 是否显示复选框
|
|
34
|
+
isUnifyFontSize: false, // 字体是否需要统一字号,
|
|
35
|
+
checkBoxValue: [], // 复选款选中的值
|
|
36
|
+
};
|
|
37
|
+
}
|
|
37
38
|
},
|
|
38
39
|
// 节点设置
|
|
39
40
|
nodeLevel: {
|
|
@@ -53,22 +54,23 @@ export default {
|
|
|
53
54
|
required: true,
|
|
54
55
|
},
|
|
55
56
|
},
|
|
56
|
-
data
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
57
|
+
data() {
|
|
58
|
+
return {
|
|
59
|
+
pcatalogIds: ''
|
|
60
|
+
}
|
|
60
61
|
},
|
|
61
62
|
computed: {
|
|
62
63
|
targetTree: function () {
|
|
63
64
|
let that = this;
|
|
64
65
|
let targetTree = [];
|
|
65
66
|
let minLevel = "";
|
|
67
|
+
let pId = ''
|
|
66
68
|
that.treeData.map(function (item) {
|
|
67
69
|
if (that.menuConfig.isShowUpDown) {
|
|
68
70
|
// 如果设置收起展开, 添加控制变量
|
|
69
|
-
|
|
71
|
+
Reflect.set(item, "isShowUpDown", false);
|
|
70
72
|
} else {
|
|
71
|
-
|
|
73
|
+
Reflect.set(item, "isShowUpDown", true);
|
|
72
74
|
}
|
|
73
75
|
if (minLevel === "") {
|
|
74
76
|
minLevel = item.level;
|
|
@@ -80,7 +82,10 @@ export default {
|
|
|
80
82
|
});
|
|
81
83
|
this.treeData.map(function (item) {
|
|
82
84
|
if (item.level === minLevel) {
|
|
85
|
+
pId = item.catalogId;
|
|
83
86
|
targetTree.push(item);
|
|
87
|
+
} else {
|
|
88
|
+
item.pid = pId
|
|
84
89
|
}
|
|
85
90
|
});
|
|
86
91
|
targetTree.map(function (item) {
|
|
@@ -100,7 +105,7 @@ export default {
|
|
|
100
105
|
let that = this;
|
|
101
106
|
let newArr = [];
|
|
102
107
|
arr.map(function (item) {
|
|
103
|
-
if (item.
|
|
108
|
+
if (item.pid === obj.catalogId) {
|
|
104
109
|
newArr.push(item);
|
|
105
110
|
}
|
|
106
111
|
});
|
|
@@ -133,17 +138,17 @@ export default {
|
|
|
133
138
|
},
|
|
134
139
|
// 获取当前节点的父级id
|
|
135
140
|
getPcatalogIds: function (pcatalogId) {
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
141
|
+
let that = this
|
|
142
|
+
if (pcatalogId === '-1') {
|
|
143
|
+
that.pcatalogIds += ','
|
|
144
|
+
} else {
|
|
145
|
+
this.treeData.some(function (item) {
|
|
146
|
+
if (item.catalogId === pcatalogId) {
|
|
147
|
+
that.pcatalogIds += ',' + item.catalogId
|
|
148
|
+
that.getPcatalogIds(item.pcatalogId)
|
|
149
|
+
}
|
|
150
|
+
})
|
|
151
|
+
}
|
|
147
152
|
},
|
|
148
153
|
},
|
|
149
154
|
};
|
|
@@ -321,6 +321,10 @@ export default {
|
|
|
321
321
|
},
|
|
322
322
|
fullDel() {
|
|
323
323
|
this.fullShow = true
|
|
324
|
+
this.mindMap.view.setTransformData({
|
|
325
|
+
state : {scale: 1, x: 0, y: 0, sx: 0, sy: 0},
|
|
326
|
+
transform : {a:1,b:0,c:0,d:1,e:0,f:0,originX:0,originY:0,rotate:0,scaleX:1,scaleY:1,shear:0,translateX:0,translateY:0}
|
|
327
|
+
})
|
|
324
328
|
this.cancelFullscreen()
|
|
325
329
|
},
|
|
326
330
|
// 全屏
|
|
@@ -2,20 +2,20 @@
|
|
|
2
2
|
<div class="list-tree">
|
|
3
3
|
<div class="list-cont" v-if="list.length > 0">
|
|
4
4
|
<div :class="{'list-li':true, 'theme-text': active === index, pos: multiple}"
|
|
5
|
-
:style="{'border-bottom': (link)? '1px solid #ccc': '0'
|
|
5
|
+
:style="{'border-bottom': (link)? '1px solid #ccc': '0'}"
|
|
6
6
|
v-for="(item,index) in listCopy" :key="index" @click="listTap(item,index)">
|
|
7
7
|
<input v-if="multiple" :checked="item.box" @change="checkboxChange($event,index)" class="box-list" type="checkbox" name="boxList" />
|
|
8
8
|
<div class="list-title">
|
|
9
|
-
<span :style="{'font-size': column[0].fontSize + 'px', 'font-weight': column[0].fontWeight}" v-html="(index + 1) + '.' + (angleBrackets ? '《' : '') + item[column[0].label] + (angleBrackets ? '》' : '')"></span>
|
|
9
|
+
<span :style="{'font-size': 'fontSize' in column[0]?column[0].fontSize + 'px':'16px', 'font-weight': column[0].fontWeight, 'color': (active === index)? activeColor : '#333333'}" v-html="(index + 1) + '.' + (angleBrackets ? '《' : '') + item[column[0].label] + (angleBrackets ? '》' : '')"></span>
|
|
10
10
|
<button v-if="delShow" @click="del(item)" v-html="delText"></button>
|
|
11
11
|
</div>
|
|
12
12
|
<div class="list-cont" v-if="open">
|
|
13
|
-
<div class="list-li-cont">
|
|
13
|
+
<div class="list-li-cont" :style="{'color': (active === index)? activeColor : '#000000'}">
|
|
14
14
|
<p v-for="(it,ind) in column.slice(1, column.length)" :key="ind">{{ it.name }}:{{ item[it.label] }}</p>
|
|
15
15
|
</div>
|
|
16
16
|
</div>
|
|
17
17
|
<div class="list-cont" v-else>
|
|
18
|
-
<div class="list-li-cont" v-if="active === index">
|
|
18
|
+
<div class="list-li-cont" :style="{'color': (active === index)? activeColor : '#000000'}" v-if="active === index">
|
|
19
19
|
<p v-for="(it,ind) in column.slice(1, column.length)" :key="ind">{{ it.name }}:{{ item[it.label] }}</p>
|
|
20
20
|
</div>
|
|
21
21
|
</div>
|