Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
江名洋
/
linkwe-scrm
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit eb6b80db
authored
Jun 24, 2023
by
xinla
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
智能表单选择问题,render props重名冲突问题
1 parent
09e8a410
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
29 additions
and
24 deletions
vue3-lw-pc/package.json
vue3-lw-pc/src/views/drainageCode/smartForms/build/DraggableItem.vue
vue3-lw-pc/src/views/drainageCode/smartForms/build/RightPanel.vue
vue3-lw-pc/src/views/drainageCode/smartForms/build/generator/config.js
vue3-lw-pc/src/views/drainageCode/smartForms/build/generator/render.jsx
vue3-lw-pc/package.json
View file @
eb6b80d
...
@@ -25,7 +25,7 @@
...
@@ -25,7 +25,7 @@
"crypto-js"
:
"^4.1.1"
,
"crypto-js"
:
"^4.1.1"
,
"driver.js"
:
"^0.9.8"
,
"driver.js"
:
"^0.9.8"
,
"echarts"
:
"^5.4.2"
,
"echarts"
:
"^5.4.2"
,
"element-plus"
:
"^2.3.
6
"
,
"element-plus"
:
"^2.3.
7
"
,
"fabric"
:
"^5.3.0"
,
"fabric"
:
"^5.3.0"
,
"file-saver"
:
"^2.0.5"
,
"file-saver"
:
"^2.0.5"
,
"fuse.js"
:
"^6.6.2"
,
"fuse.js"
:
"^6.6.2"
,
...
...
vue3-lw-pc/src/views/drainageCode/smartForms/build/DraggableItem.vue
View file @
eb6b80d
...
@@ -61,13 +61,7 @@ const layouts = {
...
@@ -61,13 +61,7 @@ const layouts = {
:
''
:
''
}
><
/div
>
}
><
/div
>
<
div
class
=
{
element
.
formCodeId
==
'1'
&&
!
element
.
src
?
'nullC'
:
''
}
>
<
div
class
=
{
element
.
formCodeId
==
'1'
&&
!
element
.
src
?
'nullC'
:
''
}
>
<
render
<
render
key
=
{
element
.
renderKey
}
conf
=
{
element
}
/
>
key
=
{
element
.
renderKey
}
conf
=
{
element
}
onInput
=
{(
event
)
=>
{
element
.
defaultValue
=
event
}}
/
>
<
/div
>
<
/div
>
<
/div
>
<
/div
>
<
div
class
=
{
element
.
formCodeId
==
4
?
'elementInputNum'
:
'nullC'
}
>
<
div
class
=
{
element
.
formCodeId
==
4
?
'elementInputNum'
:
'nullC'
}
>
...
...
vue3-lw-pc/src/views/drainageCode/smartForms/build/RightPanel.vue
View file @
eb6b80d
...
@@ -537,7 +537,11 @@ import TreeNodeDialog from './TreeNodeDialog'
...
@@ -537,7 +537,11 @@ import TreeNodeDialog from './TreeNodeDialog'
import
{
isNumberStr
}
from
'@/utils/index'
import
{
isNumberStr
}
from
'@/utils/index'
import
IconsDialog
from
'./IconsDialog'
import
IconsDialog
from
'./IconsDialog'
import
draggable
from
'vuedraggable'
import
draggable
from
'vuedraggable'
import
{
inputComponents
,
selectComponents
,
layoutComponents
}
from
'./generator/config'
import
{
inputComponents
,
// selectComponents,
layoutComponents
,
}
from
'./generator/config'
const
dateTimeFormat
=
{
const
dateTimeFormat
=
{
date
:
'YYYY-MM-DD'
,
date
:
'YYYY-MM-DD'
,
...
@@ -696,18 +700,18 @@ export default {
...
@@ -696,18 +700,18 @@ export default {
}
}
return
[]
return
[]
},
},
tagList
()
{
//
tagList() {
return
[
//
return [
{
//
{
label
:
'输入型组件'
,
//
label: '输入型组件',
options
:
inputComponents
,
//
options: inputComponents,
},
//
},
{
//
{
label
:
'选择型组件'
,
//
label: '选择型组件',
options
:
selectComponents
,
//
options: selectComponents,
},
//
},
]
//
]
},
//
},
},
},
methods
:
{
methods
:
{
numberChange
(
val
,
max
)
{
numberChange
(
val
,
max
)
{
...
...
vue3-lw-pc/src/views/drainageCode/smartForms/build/generator/config.js
View file @
eb6b80d
This diff is collapsed.
Click to expand it.
vue3-lw-pc/src/views/drainageCode/smartForms/build/generator/render.jsx
View file @
eb6b80d
...
@@ -46,9 +46,9 @@ function vModel(self, dataObject, defaultValue) {
...
@@ -46,9 +46,9 @@ function vModel(self, dataObject, defaultValue) {
// }
// }
// console.log('dataObject.props', dataObject.props)
// console.log('dataObject.props', dataObject.props)
dataObject
[
'model
-value'
]
=
defaultValue
dataObject
[
'model
Value'
]
=
self
.
conf
.
defaultValue
dataObject
.
onInput
=
(
val
)
=>
{
dataObject
[
'onUpdate:modelValue'
]
=
(
val
)
=>
{
self
.
$emit
(
'input'
,
val
)
self
.
conf
.
defaultValue
=
val
}
}
}
}
...
@@ -165,6 +165,13 @@ export default {
...
@@ -165,6 +165,13 @@ export default {
}
}
Object
.
assign
(
dataObject
,
confClone
)
Object
.
assign
(
dataObject
,
confClone
)
for
(
const
key
in
dataObject
.
_props
)
{
if
(
Object
.
hasOwnProperty
.
call
(
dataObject
.
_props
,
key
))
{
dataObject
[
key
]
=
dataObject
.
_props
[
key
];
}
}
delete
dataObject
.
_props
// Object.keys(confClone).forEach((key) => {
// Object.keys(confClone).forEach((key) => {
// const val = confClone[key]
// const val = confClone[key]
// if (key === 'style') {
// if (key === 'style') {
...
...
Write
Preview
Markdown
is supported
Attach a file
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 post a comment