mirror of
https://github.com/Tencent/tmagic-editor.git
synced 2025-11-30 22:42:09 +08:00
refactor(editor): 调整表单配置
This commit is contained in:
parent
d59428d2d6
commit
1cb2d57ade
@ -55,7 +55,7 @@ const config = computed<GroupListConfig>(() => ({
|
|||||||
{
|
{
|
||||||
type: 'table',
|
type: 'table',
|
||||||
name: 'cond',
|
name: 'cond',
|
||||||
operateColWidth: 100,
|
operateColWidth: 80,
|
||||||
enableToggleMode: false,
|
enableToggleMode: false,
|
||||||
items: [
|
items: [
|
||||||
parentFields.value.length
|
parentFields.value.length
|
||||||
@ -93,7 +93,7 @@ const config = computed<GroupListConfig>(() => ({
|
|||||||
type: 'cond-op-select',
|
type: 'cond-op-select',
|
||||||
parentFields: parentFields.value,
|
parentFields: parentFields.value,
|
||||||
label: '条件',
|
label: '条件',
|
||||||
width: 160,
|
width: 140,
|
||||||
name: 'op',
|
name: 'op',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|||||||
@ -4,7 +4,7 @@
|
|||||||
<span class="help-txt" v-if="item.text">{{ item.text }}</span>
|
<span class="help-txt" v-if="item.text">{{ item.text }}</span>
|
||||||
<span class="next-input">
|
<span class="next-input">
|
||||||
<input
|
<input
|
||||||
v-model="model[item.name]"
|
:model-value="model[item.name]"
|
||||||
placeholder="0"
|
placeholder="0"
|
||||||
:title="model[item.name]"
|
:title="model[item.name]"
|
||||||
:disabled="disabled"
|
:disabled="disabled"
|
||||||
|
|||||||
@ -3,7 +3,7 @@
|
|||||||
<div v-for="(item, index) in list" :key="index" :class="item.class">
|
<div v-for="(item, index) in list" :key="index" :class="item.class">
|
||||||
<span class="next-input">
|
<span class="next-input">
|
||||||
<input
|
<input
|
||||||
v-model="model[item.name]"
|
:model-value="model[item.name]"
|
||||||
placeholder="0"
|
placeholder="0"
|
||||||
:title="model[item.name]"
|
:title="model[item.name]"
|
||||||
:disabled="disabled"
|
:disabled="disabled"
|
||||||
|
|||||||
@ -574,8 +574,6 @@ class Editor extends BaseService {
|
|||||||
nodes.splice(targetIndex, 1, newConfig);
|
nodes.splice(targetIndex, 1, newConfig);
|
||||||
this.set('nodes', [...nodes]);
|
this.set('nodes', [...nodes]);
|
||||||
|
|
||||||
// update后会触发依赖收集,收集完后会掉stage.update方法
|
|
||||||
|
|
||||||
if (isPage(newConfig) || isPageFragment(newConfig)) {
|
if (isPage(newConfig) || isPageFragment(newConfig)) {
|
||||||
this.set('page', newConfig as MPage | MPageFragment);
|
this.set('page', newConfig as MPage | MPageFragment);
|
||||||
}
|
}
|
||||||
@ -591,6 +589,7 @@ class Editor extends BaseService {
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 更新节点
|
* 更新节点
|
||||||
|
* update后会触发依赖收集,收集完后会掉stage.update方法
|
||||||
* @param config 新的节点配置,配置中需要有id信息
|
* @param config 新的节点配置,配置中需要有id信息
|
||||||
* @returns 更新后的节点配置
|
* @returns 更新后的节点配置
|
||||||
*/
|
*/
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user