Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
visualcloud
/
Vmatrix-client
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Wiki
Members
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
e7076f82
authored
Dec 19, 2019
by
hank
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
解析group 类型
parent
83c3a523
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
56 additions
and
3 deletions
+56
-3
src/views/tempaltes/editMenu.vue
+55
-2
src/views/tempaltes/editMore.vue
+1
-1
No files found.
src/views/tempaltes/editMenu.vue
View file @
e7076f82
...
...
@@ -30,11 +30,33 @@
class=
"edit-input"
type=
"text"
@
blur=
"onBlur"
@
change=
"valueChange2()"
v-model=
"schemaData[item.dataKey].value"
@
keyup=
"valueChange2()"
/>
<textarea
v-if=
"item.type === 'textarea'"
class=
"edit-input-area"
@
blur=
"onBlur"
v-model=
"schemaData[item.dataKey].value"
@
keyup=
"valueChange2()"
@
input=
"valueChange2()"
cols=
"30"
rows=
"5"
></textarea>
</div>
<div
v-if=
"item.type === 'group'"
>
<div
v-for=
"(children, index) in item.itemList"
:key=
"index"
>
<editMenu
:isIos=
"isIos"
:itemList=
"item.itemList"
:item=
"children"
:schemaData=
"schemaData"
:frameUrl=
"frameUrl"
@
setList=
"setList"
></editMenu>
</div>
</div>
<div
class=
"list-container"
v-if=
"item.type === 'list'"
>
<div
class=
"create-btn-container"
...
...
@@ -58,6 +80,17 @@
v-model=
"item2[index3]"
@
keyup=
"valueChange2()"
/>
<textarea
cols=
"30"
rows=
"5"
v-if=
"item.modelSchema[isSchemaIndex(item2)][index3].type === 'textarea'"
:placeholder=
"item.modelSchema[isSchemaIndex(item2)][index3].description"
class=
"edit-input-area edit-input-list-item"
type=
"text"
@
blur=
"onBlur"
v-model=
"item2[index3]"
@
keyup=
"valueChange2()"
/>
<div>
<van-uploader
result-type=
"dataUrl"
...
...
@@ -210,10 +243,22 @@ export default {
});
},
onBlur
()
{
var
top
=
window
.
scrollY
console
.
log
(
top
)
window
.
scrollTo
(
0
,
0
);
var
time
=
setTimeout
(()
=>
{
window
.
scrollTo
(
0
,
top
);
clearTimeout
(
time
)
},
100
)
},
valueChange2
()
{
console
.
log
(
this
.
schemaData
);
console
.
log
(
this
.
schemaData
)
setTimeout
(()
=>
{
this
.
$emit
(
"setList"
,
this
.
schemaData
);
},
100
)
this
.
$emit
(
"setList"
,
this
.
schemaData
);
},
setList
()
{
this
.
$emit
(
"setList"
,
this
.
schemaData
);
},
uploadItem
(
key
)
{
...
...
@@ -477,6 +522,14 @@ export default {
color
:
rgba
(
51
,
51
,
51
,
1
);
margin-top
:
0
;
}
.edit-input-area
{
width
:
97%
;
background
:
#f5f5f5
;
border-radius
:
6px
;
font-size
:
14px
;
color
:
rgba
(
51
,
51
,
51
,
1
);
margin-top
:
0
;
}
}
</
style
>
src/views/tempaltes/editMore.vue
View file @
e7076f82
...
...
@@ -208,7 +208,7 @@
</div>
<div
class=
"content-right"
>
<!--
<div
class=
"title"
>
编辑栏
</div>
-->
<div
class=
"edit-area"
:class=
"
{'fixed-edit-area': clip
i
mg}">
<div
class=
"edit-area"
:class=
"
{'fixed-edit-area': clip
I
mg}">
<div
v-if=
"templateData.listData[currentPage]"
>
<editMenu
v-if=
"loaded "
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment