提交 97b8f940 编写于 作者: Shine-zwj's avatar Shine-zwj

适配日历部件无值显示内容

上级 e85bb351
<#ibizinclude> <#ibizinclude>
../../@MACRO/LANG_FUN.ftl ../../@MACRO/LANG_FUN.ftl
</#ibizinclude> </#ibizinclude>
<#ibizinclude>
../@MACRO/CONTROL/LANGBASE.vue.ftl
</#ibizinclude>
<template> <template>
<#if ctrl.render??> <#if ctrl.render??>
${ctrl.render.code} ${ctrl.render.code}
...@@ -24,6 +27,7 @@ ${ctrl.render.code} ...@@ -24,6 +27,7 @@ ${ctrl.render.code}
</#if> </#if>
<context-menu-container> <context-menu-container>
<#if ctrl.getCalendarStyle?? && ctrl.getCalendarStyle() == 'TIMELINE'> <#if ctrl.getCalendarStyle?? && ctrl.getCalendarStyle() == 'TIMELINE'>
<template v-if="events.length >0">
<el-timeline> <el-timeline>
<el-timeline-item <el-timeline-item
v-for="(item, index) in events" v-for="(item, index) in events"
...@@ -53,7 +57,12 @@ ${ctrl.render.code} ...@@ -53,7 +57,12 @@ ${ctrl.render.code}
</context-menu> </context-menu>
</el-timeline-item> </el-timeline-item>
</el-timeline> </el-timeline>
</template>
<template v-else>
<span class="app-data-empty">{{ $t('<#if langbase??>${langbase}.nodata</#if>') }}</span>
</template>
<#else> <#else>
<template v-if="events.length >0">
<div class="event-legends"> <div class="event-legends">
<#if ctrl.getPSSysCalendarItems()??> <#if ctrl.getPSSysCalendarItems()??>
<#list ctrl.getPSSysCalendarItems() as calendarItem> <#list ctrl.getPSSysCalendarItems() as calendarItem>
...@@ -86,6 +95,10 @@ ${ctrl.render.code} ...@@ -86,6 +95,10 @@ ${ctrl.render.code}
<modal v-model="modalVisible" width="250px" :title="$t('app.calendar.dateSelectModalTitle')" class-name='date-select-modal' @on-ok="gotoDate"> <modal v-model="modalVisible" width="250px" :title="$t('app.calendar.dateSelectModalTitle')" class-name='date-select-modal' @on-ok="gotoDate">
<el-date-picker style="width: 200px;" v-model="selectedGotoDate" type="date"></el-date-picker> <el-date-picker style="width: 200px;" v-model="selectedGotoDate" type="date"></el-date-picker>
</modal> </modal>
</template>
<template v-else>
<span class="app-data-empty">{{ $t('<#if langbase??>${langbase}.nodata</#if>') }}</span>
</template>
</#if> </#if>
</context-menu-container> </context-menu-container>
</div> </div>
......
...@@ -91,3 +91,11 @@ ...@@ -91,3 +91,11 @@
} }
} }
} }
.calendarClass{
.app-data-empty{
margin: 0 auto;
display: flex;
align-items: center;
justify-content: center;
}
}
\ No newline at end of file
...@@ -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', 'KANBAN', 'GANTT', 'TREEGRIDEX', 'SEARCHFORM', 'TOOLBAR', 'TREEVIEW']> <#assign ctrltypes = ['FORM', 'GRID','LIST', 'DATAVIEW', 'CHART', 'KANBAN', 'GANTT', 'TREEGRIDEX', 'SEARCHFORM', 'TOOLBAR', 'TREEVIEW', 'CALENDAR']>
<#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() == 'KANBAN'|| ctrl.getControlType() == 'GANTT' || ctrl.getControlType() == 'TREEGRIDEX'> <#if ctrl.getControlType() == 'LIST' || ctrl.getControlType() == 'DATAVIEW' || ctrl.getControlType() == 'CHART'|| ctrl.getControlType() == 'KANBAN'|| ctrl.getControlType() == 'GANTT' || ctrl.getControlType() == 'TREEGRIDEX' || ctrl.getControlType() == 'CALENDAR'>
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','KANBAN', 'GANTT', 'TREEGRIDEX', 'SEARCHFORM', 'TOOLBAR', 'TREEVIEW', 'TREEGRIDEX']> <#assign ctrltypes = ['FORM', 'GRID', 'LIST', 'DATAVIEW', 'CHART','KANBAN', 'GANTT', 'TREEGRIDEX', 'SEARCHFORM', 'TOOLBAR', 'TREEVIEW', 'TREEGRIDEX', 'CALENDAR']>
<#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() == 'KANBAN'|| ctrl.getControlType() == 'GANTT' || ctrl.getControlType() == 'TREEGRIDEX'> <#if ctrl.getControlType() == 'LIST' || ctrl.getControlType() == 'DATAVIEW' || ctrl.getControlType() == 'CHART' || ctrl.getControlType() == 'KANBAN'|| ctrl.getControlType() == 'GANTT' || ctrl.getControlType() == 'TREEGRIDEX' || ctrl.getControlType() == 'CALENDAR'>
nodata:"<@getEmptyTextLanguage ctrl langrestype emptyText/>", nodata:"<@getEmptyTextLanguage ctrl langrestype emptyText/>",
</#if> </#if>
<#if ctrl.getControlType() == 'GRID'> <#if ctrl.getControlType() == 'GRID'>
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册