Commit bbb85edb by Mr. Lan

fix bug.

parent 9c320785
<template> <template>
<el-form-item <el-form-item
:label-width="widget.options.labelWidthStatus?widgetLabelWidth + 'px': '0px'" :label-width="!widget.options.labelWidthStatus?widgetLabelWidth + 'px': '0px'"
:label="widget.type==='divider' || !widget.options.labelWidthStatus?'':widget.name" :label="widget.type==='divider' || widget.options.labelWidthStatus?'':widget.name"
:prop="widget.model" :prop="widget.model"
> >
<template v-if="widget.type == 'input'"> <template v-if="widget.type == 'input'">
......
<template> <template>
<el-form-item <el-form-item
v-if="element && element.key" v-if="element && element.key"
:label-width="element.options.labelWidthStatus?elementLabelWidth + 'px': '0px'" :label-width="!element.options.labelWidthStatus?elementLabelWidth + 'px': '0px'"
class="widget-view " class="widget-view "
:class="{active: selectWidget.key === element.key, 'is_req': element.options.required}" :class="{active: selectWidget.key === element.key, 'is_req': element.options.required}"
:label="element.type==='divider' || !element.options.labelWidthStatus?'':element.name" :label="element.type==='divider' || element.options.labelWidthStatus?'':element.name"
@click.native.stop="handleSelectWidget(index)" @click.native.stop="handleSelectWidget(index)"
> >
<template v-if="element.type == 'input'"> <template v-if="element.type == 'input'">
......
...@@ -12,7 +12,7 @@ export const basicComponents = [ ...@@ -12,7 +12,7 @@ export const basicComponents = [
disabled: false, disabled: false,
labelWidth: 100, labelWidth: 100,
labelWidthDisabled: false, labelWidthDisabled: false,
labelWidthStatus: true labelWidthStatus: false
} }
}, },
{ {
...@@ -27,7 +27,7 @@ export const basicComponents = [ ...@@ -27,7 +27,7 @@ export const basicComponents = [
placeholder: '', placeholder: '',
labelWidth: 100, labelWidth: 100,
labelWidthDisabled: false, labelWidthDisabled: false,
labelWidthStatus: true labelWidthStatus: false
} }
}, },
{ {
...@@ -44,7 +44,7 @@ export const basicComponents = [ ...@@ -44,7 +44,7 @@ export const basicComponents = [
controlsPosition: '', controlsPosition: '',
labelWidth: 100, labelWidth: 100,
labelWidthDisabled: false, labelWidthDisabled: false,
labelWidthStatus: true labelWidthStatus: false
} }
}, },
{ {
...@@ -80,7 +80,7 @@ export const basicComponents = [ ...@@ -80,7 +80,7 @@ export const basicComponents = [
disabled: false, disabled: false,
labelWidth: 100, labelWidth: 100,
labelWidthDisabled: false, labelWidthDisabled: false,
labelWidthStatus: true labelWidthStatus: false
} }
}, },
{ {
...@@ -113,7 +113,7 @@ export const basicComponents = [ ...@@ -113,7 +113,7 @@ export const basicComponents = [
disabled: false, disabled: false,
labelWidth: 100, labelWidth: 100,
labelWidthDisabled: false, labelWidthDisabled: false,
labelWidthStatus: true labelWidthStatus: false
} }
}, },
{ {
...@@ -135,7 +135,7 @@ export const basicComponents = [ ...@@ -135,7 +135,7 @@ export const basicComponents = [
width: '', width: '',
labelWidth: 100, labelWidth: 100,
labelWidthDisabled: false, labelWidthDisabled: false,
labelWidthStatus: true labelWidthStatus: false
} }
}, },
{ {
...@@ -157,7 +157,7 @@ export const basicComponents = [ ...@@ -157,7 +157,7 @@ export const basicComponents = [
width: '', width: '',
labelWidth: 100, labelWidth: 100,
labelWidthDisabled: false, labelWidthDisabled: false,
labelWidthStatus: true labelWidthStatus: false
} }
}, },
{ {
...@@ -171,7 +171,7 @@ export const basicComponents = [ ...@@ -171,7 +171,7 @@ export const basicComponents = [
required: false, required: false,
labelWidth: 100, labelWidth: 100,
labelWidthDisabled: false, labelWidthDisabled: false,
labelWidthStatus: true labelWidthStatus: false
} }
}, },
{ {
...@@ -184,7 +184,7 @@ export const basicComponents = [ ...@@ -184,7 +184,7 @@ export const basicComponents = [
required: false, required: false,
labelWidth: 100, labelWidth: 100,
labelWidthDisabled: false, labelWidthDisabled: false,
labelWidthStatus: true labelWidthStatus: false
} }
}, },
{ {
...@@ -219,7 +219,7 @@ export const basicComponents = [ ...@@ -219,7 +219,7 @@ export const basicComponents = [
remoteFunc: '', remoteFunc: '',
labelWidth: 100, labelWidth: 100,
labelWidthDisabled: false, labelWidthDisabled: false,
labelWidthStatus: true labelWidthStatus: false
} }
}, },
{ {
...@@ -231,7 +231,7 @@ export const basicComponents = [ ...@@ -231,7 +231,7 @@ export const basicComponents = [
disabled: false, disabled: false,
labelWidth: 100, labelWidth: 100,
labelWidthDisabled: false, labelWidthDisabled: false,
labelWidthStatus: true labelWidthStatus: false
} }
}, },
{ {
...@@ -249,7 +249,7 @@ export const basicComponents = [ ...@@ -249,7 +249,7 @@ export const basicComponents = [
width: '', width: '',
labelWidth: 100, labelWidth: 100,
labelWidthDisabled: false, labelWidthDisabled: false,
labelWidthStatus: true labelWidthStatus: false
} }
}, },
{ {
...@@ -261,7 +261,7 @@ export const basicComponents = [ ...@@ -261,7 +261,7 @@ export const basicComponents = [
font_weight: '500', // 粗体 font_weight: '500', // 粗体
font_family: '', // 字体属性 font_family: '', // 字体属性
defaultValue: '这是一句话', defaultValue: '这是一句话',
labelWidthStatus: true, labelWidthStatus: false,
customClass: '', customClass: '',
labelWidth: 100, labelWidth: 100,
labelWidthDisabled: false labelWidthDisabled: false
...@@ -277,7 +277,7 @@ export const advanceComponents = [ ...@@ -277,7 +277,7 @@ export const advanceComponents = [
defaultType: 'String', defaultType: 'String',
labelWidth: 100, labelWidth: 100,
labelWidthDisabled: false, labelWidthDisabled: false,
labelWidthStatus: true labelWidthStatus: false
} }
}, },
{ {
...@@ -303,7 +303,7 @@ export const advanceComponents = [ ...@@ -303,7 +303,7 @@ export const advanceComponents = [
action: 'https://jsonplaceholder.typicode.com/photos/', action: 'https://jsonplaceholder.typicode.com/photos/',
labelWidth: 100, labelWidth: 100,
labelWidthDisabled: false, labelWidthDisabled: false,
labelWidthStatus: true labelWidthStatus: false
} }
}, },
{ {
...@@ -314,7 +314,7 @@ export const advanceComponents = [ ...@@ -314,7 +314,7 @@ export const advanceComponents = [
width: '', width: '',
labelWidth: 100, labelWidth: 100,
labelWidthDisabled: false, labelWidthDisabled: false,
labelWidthStatus: true labelWidthStatus: false
} }
}, },
{ {
...@@ -336,7 +336,7 @@ export const advanceComponents = [ ...@@ -336,7 +336,7 @@ export const advanceComponents = [
remoteFunc: '', remoteFunc: '',
labelWidth: 100, labelWidth: 100,
labelWidthDisabled: false, labelWidthDisabled: false,
labelWidthStatus: true labelWidthStatus: false
} }
} }
] ]
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment