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

搜索表单搜索&重置操作

上级 63aaa672
......@@ -82,7 +82,7 @@
<#-- 搜索表单:BEGIN -->
<#if view.hasPSControl('searchform')>
<ion-menu side="start" content-id="main-content" ref='searchform<#if view.getName()??>${view.getName()}</#if>'>
<ion-menu side="start" content-id="main-content" ref='searchform<#if view.getName()??>${view.getName()?lower_case}</#if>'>
<ion-header>
<ion-toolbar translucent>
<ion-title>条件搜索</ion-title>
......@@ -93,8 +93,8 @@
</ion-content>
<ion-footer>
<div class="search-btn">
<ion-button class="search-btn-item" shape="round" size="small" expand="full" color="light">重置</ion-button>
<ion-button class="search-btn-item" shape="round" size="small" expand="full">搜索</ion-button>
<ion-button class="search-btn-item" shape="round" size="small" expand="full" color="light" @click="onReset">重置</ion-button>
<ion-button class="search-btn-item" shape="round" size="small" expand="full" @click="onSearch">搜索</ion-button>
</div>
</ion-footer>
</ion-menu>
......
......@@ -54,6 +54,7 @@
if (form) {
form.onReset();
}
this.closeSearchform();
}
</#if>
<#-- 输出快速搜索:BEGIN -->
......@@ -193,9 +194,21 @@
* @memberof ${srfclassname('${view.name}')}Base
*/
public openSearchform() {
let xData :any = this.$refs.searchform<#if view.getName()??>${view.getName()}</#if>;
if(xData){
xData.open();
let search :any = this.$refs.searchform<#if view.getName()??>${view.getName()?lower_case}</#if>;
if(search){
search.open();
}
}
/**
* 关闭搜索表单
*
* @memberof ${srfclassname('${view.name}')}Base
*/
public closeSearchform(){
let search :any = this.$refs.searchform<#if view.getName()??>${view.getName()?lower_case}</#if>;
if(search){
search.close();
}
}
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册