提交 bd336b0f 编写于 作者: tony001's avatar tony001

适配看板视图部件无值显示内容

上级 83ed21cf
<#ibizinclude>
../@MACRO/CONTROL/LANGBASE.vue.ftl
</#ibizinclude>
<template> <template>
<#if ctrl.render??> <#if ctrl.render??>
${ctrl.render.code} ${ctrl.render.code}
<#else> <#else>
<div class="app-data-view-group<#if ctrl.getPSSysCss?? && ctrl.getPSSysCss()??><#assign singleCss = ctrl.getPSSysCss()> ${singleCss.getCssName()}</#if>"> <div class="app-data-view-group<#if ctrl.getPSSysCss?? && ctrl.getPSSysCss()??><#assign singleCss = ctrl.getPSSysCss()> ${singleCss.getCssName()}</#if>">
<template v-for="(group, index) of groups"> <template v-if="items.length > 0">
<#if ctrl.groupRender??> <template v-for="(group, index) of groups">
${ctrl.groupRender.code} <#if ctrl.groupRender??>
<#else> ${ctrl.groupRender.code}
<div :key="group + index" class="dataview-group-content" style="<#if ctrl.getGroupWidth() gt 0>width: ${ctrl.getGroupWidth()?c}px;<#else>flex-grow: 1;</#if>"> <#else>
<div class="dataview-group-header<#if ctrl.getGroupPSSysCss()??> ${ctrl.getGroupPSSysCss().getCssName()}</#if>"> <div :key="group + index" class="dataview-group-content" style="<#if ctrl.getGroupWidth() gt 0>width: ${ctrl.getGroupWidth()?c}px;<#else>flex-grow: 1;</#if>">
{{ getGroupText(group.name) }} <div class="dataview-group-header<#if ctrl.getGroupPSSysCss()??> ${ctrl.getGroupPSSysCss().getCssName()}</#if>">
<#if ctrl.getGroupPSUIActionGroup()??> {{ getGroupText(group.name) }}
<Poptip trigger="hover" content="content" placement="bottom-end" style="float: right;"> <#if ctrl.getGroupPSUIActionGroup()??>
<Icon type="md-more" /> <Poptip trigger="hover" content="content" placement="bottom-end" style="float: right;">
<div slot="content" class="group-action"> <Icon type="md-more" />
<#if ctrl.getGroupPSUIActionGroup().getPSUIActions()??> <div slot="content" class="group-action">
<#list ctrl.getGroupPSUIActionGroup().getPSUIActions() as action> <#if ctrl.getGroupPSUIActionGroup().getPSUIActions()??>
<div class="group-action-item"> <#list ctrl.getGroupPSUIActionGroup().getPSUIActions() as action>
<i-button long @click="uiAction('${action.getCodeName()}', $event)"> <div class="group-action-item">
<#if action.getPSSysImage()??> <i-button long @click="uiAction('${action.getCodeName()}', $event)">
<#if action.getPSSysImage().getImagePath()?length gt 0> <#if action.getPSSysImage()??>
<img src="${action.getPSSysImage().getImagePath()}"/> <#if action.getPSSysImage().getImagePath()?length gt 0>
<#else> <img src="${action.getPSSysImage().getImagePath()}"/>
<i class="${action.getPSSysImage().getCssClass()}"></i> <#else>
</#if> <i class="${action.getPSSysImage().getCssClass()}"></i>
</#if>
</#if>
${action.getCaption()}
</i-button>
</div>
</#list>
</#if> </#if>
${action.getCaption()}
</i-button>
</div> </div>
</#list> </Poptip>
</#if>
</div>
<draggable :list="group.items" group="${ctrl.name}" class="dataview-group-items" @change="onDragChange($event, group.name)">
<div v-for="(item, i) in group.items" :key="i" :class="{'dataview-group-item': true, 'is-select': item.isselected}" @click="handleClick(item)" @dblclick="handleDblClick(item)">
<#if ctrl.getItemPSLayoutPanel()??>
<#assign panel = ctrl.getItemPSLayoutPanel()>
<layout_${panel.getName()} name='${panel.name}' :inputData="item"></layout_${panel.getName()}>
<#elseif ctrl.itemRender??>
${ctrl.itemRender.code}
<#else>
{{ item.srfmajortext }}
</#if> </#if>
</div> </div>
</Poptip> </draggable>
</#if>
</div> </div>
<draggable :list="group.items" group="${ctrl.name}" class="dataview-group-items" @change="onDragChange($event, group.name)">
<div v-for="(item, i) in group.items" :key="i" :class="{'dataview-group-item': true, 'is-select': item.isselected}" @click="handleClick(item)" @dblclick="handleDblClick(item)">
<#if ctrl.getItemPSLayoutPanel()??>
<#assign panel = ctrl.getItemPSLayoutPanel()>
<layout_${panel.getName()} name='${panel.name}' :inputData="item"></layout_${panel.getName()}>
<#elseif ctrl.itemRender??>
${ctrl.itemRender.code}
<#else>
{{ item.srfmajortext }}
</#if>
</div>
</draggable>
</div>
</#if>
</template>
<#if ctrl.getGroupQuickPSDEToolbar()??>
<div class="quick-action">
<#if ctrl.getGroupQuickPSDEToolbar().getPSDEToolbarItems()??>
<#list ctrl.getGroupQuickPSDEToolbar().getPSDEToolbarItems() as toolbarItem>
<div class="quick-action-item" title="${toolbarItem.getCaption()}" @click="${ctrl.getGroupQuickPSDEToolbar().getName()}_click({tag: '${toolbarItem.getName()}'}, $event)">
<#if toolbarItem.getPSSysImage()??>
<#if toolbarItem.getPSSysImage().getImagePath()?length gt 0>
<img src="${toolbarItem.getPSSysImage().getImagePath()}"/>
<#else>
<i class="${toolbarItem.getPSSysImage().getCssClass()}"></i>
</#if> </#if>
<#else> </template>
<i class="el-icon-menu"></i> <#if ctrl.getGroupQuickPSDEToolbar()??>
<div class="quick-action">
<#if ctrl.getGroupQuickPSDEToolbar().getPSDEToolbarItems()??>
<#list ctrl.getGroupQuickPSDEToolbar().getPSDEToolbarItems() as toolbarItem>
<div class="quick-action-item" title="${toolbarItem.getCaption()}" @click="${ctrl.getGroupQuickPSDEToolbar().getName()}_click({tag: '${toolbarItem.getName()}'}, $event)">
<#if toolbarItem.getPSSysImage()??>
<#if toolbarItem.getPSSysImage().getImagePath()?length gt 0>
<img src="${toolbarItem.getPSSysImage().getImagePath()}"/>
<#else>
<i class="${toolbarItem.getPSSysImage().getCssClass()}"></i>
</#if>
<#else>
<i class="el-icon-menu"></i>
</#if>
</div>
</#list>
</#if> </#if>
</div> </div>
</#list>
</#if>
</div>
</#if> </#if>
</template>
<template v-else>
<span class="app-data-empty">{{ $t('<#if langbase??>${langbase}.nodata</#if>') }}</span>
</template>
</div> </div>
</#if> </#if>
</template> </template>
......
...@@ -52,6 +52,12 @@ ...@@ -52,6 +52,12 @@
border-top-width: 1px; border-top-width: 1px;
} }
} }
.app-data-empty{
margin: 0 auto;
display: flex;
align-items: center;
justify-content: center;
}
} }
<#ibizinclude> <#ibizinclude>
../@MACRO/CSS/DEFAULT.less.ftl ../@MACRO/CSS/DEFAULT.less.ftl
......
...@@ -27,7 +27,7 @@ export default { ...@@ -27,7 +27,7 @@ export default {
</#if> </#if>
<#-- 实体部件输出 --> <#-- 实体部件输出 -->
<#if item.getPSControls()??> <#if item.getPSControls()??>
<#assign ctrltypes = ['FORM', 'GRID','LIST', 'DATAVIEW', 'CHART', 'TREEGRIDEX', 'SEARCHFORM', 'TOOLBAR', 'TREEVIEW']> <#assign ctrltypes = ['FORM', 'GRID','LIST', 'DATAVIEW', 'CHART', 'KANBAN', 'TREEGRIDEX', 'SEARCHFORM', 'TOOLBAR', 'TREEVIEW']>
<#list ctrltypes as ctrltype> <#list ctrltypes as ctrltype>
<#list item.getPSControls() as ctrl> <#list item.getPSControls() as ctrl>
<#if ctrl.getControlType() == ctrltype> <#if ctrl.getControlType() == ctrltype>
...@@ -40,7 +40,7 @@ export default { ...@@ -40,7 +40,7 @@ export default {
</#list> </#list>
}, },
</#if> </#if>
<#if ctrl.getControlType() == 'LIST' || ctrl.getControlType() == 'DATAVIEW' || ctrl.getControlType() == 'CHART' || ctrl.getControlType() == 'TREEGRIDEX'> <#if ctrl.getControlType() == 'LIST' || ctrl.getControlType() == 'DATAVIEW' || ctrl.getControlType() == 'CHART'|| ctrl.getControlType() == 'KANBAN' || ctrl.getControlType() == 'TREEGRIDEX'>
nodata:"<@getEmptyTextLanguage ctrl langrestype emptyText/>", nodata:"<@getEmptyTextLanguage ctrl langrestype emptyText/>",
</#if> </#if>
<#if ctrl.getControlType() == 'GRID'> <#if ctrl.getControlType() == 'GRID'>
......
...@@ -26,7 +26,7 @@ export default { ...@@ -26,7 +26,7 @@ export default {
</#if> </#if>
<#-- 实体部件输出 --> <#-- 实体部件输出 -->
<#if item.getPSControls()??> <#if item.getPSControls()??>
<#assign ctrltypes = ['FORM', 'GRID', 'LIST', 'DATAVIEW', 'CHART', 'TREEGRIDEX', 'SEARCHFORM', 'TOOLBAR', 'TREEVIEW', 'TREEGRIDEX']> <#assign ctrltypes = ['FORM', 'GRID', 'LIST', 'DATAVIEW', 'CHART','KANBAN', 'TREEGRIDEX', 'SEARCHFORM', 'TOOLBAR', 'TREEVIEW', 'TREEGRIDEX']>
<#list ctrltypes as ctrltype> <#list ctrltypes as ctrltype>
<#list item.getPSControls() as ctrl> <#list item.getPSControls() as ctrl>
<#if ctrl.getControlType() == ctrltype> <#if ctrl.getControlType() == ctrltype>
...@@ -39,7 +39,7 @@ export default { ...@@ -39,7 +39,7 @@ export default {
</#list> </#list>
}, },
</#if> </#if>
<#if ctrl.getControlType() == 'LIST' || ctrl.getControlType() == 'DATAVIEW' || ctrl.getControlType() == 'CHART' || ctrl.getControlType() == 'TREEGRIDEX'> <#if ctrl.getControlType() == 'LIST' || ctrl.getControlType() == 'DATAVIEW' || ctrl.getControlType() == 'CHART' || ctrl.getControlType() == 'KANBAN' || ctrl.getControlType() == 'TREEGRIDEX'>
nodata:"<@getEmptyTextLanguage ctrl langrestype emptyText/>", nodata:"<@getEmptyTextLanguage ctrl langrestype emptyText/>",
</#if> </#if>
<#if ctrl.getControlType() == 'GRID'> <#if ctrl.getControlType() == 'GRID'>
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册