提交 a0fc5fba 编写于 作者: KK's avatar KK

zk——表单项 显示更多模式

上级 226d9462
...@@ -87,6 +87,11 @@ ...@@ -87,6 +87,11 @@
</template> </template>
</a > </a >
</template> </template>
<template v-if="isManageContainer">
<a slot='extra' @click="doManageContainer">
<span class='manageContainer'>{{manageContainerStatus?$t('components.appFormGroup.hide'):$t('components.appFormGroup.show')}}</span>
</a>
</template>
<template v-if="Object.is(layoutType, 'FLEX')"> <template v-if="Object.is(layoutType, 'FLEX')">
<slot></slot> <slot></slot>
</template> </template>
...@@ -115,6 +120,22 @@ export default class AppFormGroup extends Vue { ...@@ -115,6 +120,22 @@ export default class AppFormGroup extends Vue {
*/ */
@Prop() public caption?: string; @Prop() public caption?: string;
/**
* 是否为管理容器
*
* @type {string}
* @memberof AppFormGroup
*/
@Prop({ default: false }) public isManageContainer?: boolean;
/**
* 管理容器状态
*
* @type {string}
* @memberof AppFormGroup
*/
@Prop({ default: false }) public manageContainerStatus?: boolean;
/** /**
* 内置界面样式 * 内置界面样式
* *
...@@ -244,6 +265,16 @@ export default class AppFormGroup extends Vue { ...@@ -244,6 +265,16 @@ export default class AppFormGroup extends Vue {
public doUIAction($event: any, item: any): void { public doUIAction($event: any, item: any): void {
this.$emit('groupuiactionclick', { event: $event, item: item }); this.$emit('groupuiactionclick', { event: $event, item: item });
} }
/**
* 操作管理容器
*
* @param {*} $event
* @memberof AppFormGroup
*/
public doManageContainer(){
this.$emit('managecontainerclick');
}
} }
</script> </script>
<style lang='less'> <style lang='less'>
......
...@@ -169,4 +169,8 @@ export default { ...@@ -169,4 +169,8 @@ export default {
YouYuan: 'YouYuan', YouYuan: 'YouYuan',
}, },
}, },
appFormGroup: {
hide: 'hide',
show: 'show',
},
}; };
\ No newline at end of file
...@@ -170,4 +170,8 @@ export default { ...@@ -170,4 +170,8 @@ export default {
YouYuan: '幼圆', YouYuan: '幼圆',
}, },
}, },
appFormGroup: {
hide: '隐藏',
show: '显示',
},
}; };
\ No newline at end of file
...@@ -39,7 +39,7 @@ export class FormGroupPanelModel extends FormDetailModel { ...@@ -39,7 +39,7 @@ export class FormGroupPanelModel extends FormDetailModel {
* @type {*} * @type {*}
* @memberof FormGroupPanelModel * @memberof FormGroupPanelModel
*/ */
public ManageContainerStatus: boolean = true; public manageContainerStatus: boolean = true;
/** /**
* Creates an instance of FormGroupPanelModel. * Creates an instance of FormGroupPanelModel.
...@@ -62,6 +62,6 @@ export class FormGroupPanelModel extends FormDetailModel { ...@@ -62,6 +62,6 @@ export class FormGroupPanelModel extends FormDetailModel {
* @memberof FormGroupPanelModel * @memberof FormGroupPanelModel
*/ */
public setManageContainerStatus(state: boolean): void { public setManageContainerStatus(state: boolean): void {
this.ManageContainerStatus = state; this.manageContainerStatus = state;
} }
} }
\ No newline at end of file
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册