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

快速搜索调整

上级 44605c3b
<#if view.hasPSControl('pickupviewpanel')> <#if view.hasPSControl('pickupviewpanel')>
<#assign view_enableQuickSearch> <#assign view_enableQuickSearch>
<ion-searchbar style="height: 36px; padding: 0 25px 0 50px;;" :placeholder="$t('app.fastsearch')" debounce="500" @ionChange="quickValueChange($event)" show-cancel-button="focus" :cancel-button-text="$t('app.button.cancel')"></ion-searchbar> <van-search
v-model="quickValue"
:placeholder="$t('app.fastsearch')"
@input="quickValueChange($event)"
/>
</#assign> </#assign>
<#assign view_content> <#assign view_content>
${P.getCtrlCode('pickupviewpanel', 'CONTROL.html').code} ${P.getCtrlCode('pickupviewpanel', 'CONTROL.html').code}
......
...@@ -42,11 +42,6 @@ ...@@ -42,11 +42,6 @@
</ion-buttons> </ion-buttons>
</#if> </#if>
<#-- 输出右侧工具栏左:END --> <#-- 输出右侧工具栏左:END -->
<#-- 自定义头部快速搜索:BEGIN -->
<#if view_enableQuickSearch??>
${view_enableQuickSearch}
</#if>
<#-- 自定义头部快速搜索:END -->
</ion-toolbar> </ion-toolbar>
<#-- 输出工具栏分组:BEGIN --> <#-- 输出工具栏分组:BEGIN -->
<#list view.getAllPSControls() as ctrl> <#list view.getAllPSControls() as ctrl>
...@@ -77,6 +72,11 @@ ...@@ -77,6 +72,11 @@
<ion-button class="filter-btn" size="small" slot="end" @click="openSearchform"><ion-icon slot="end" name="filter-outline"></ion-icon>过滤</ion-button> <ion-button class="filter-btn" size="small" slot="end" @click="openSearchform"><ion-icon slot="end" name="filter-outline"></ion-icon>过滤</ion-button>
</#if> </#if>
</ion-toolbar> </ion-toolbar>
<#-- 自定义头部快速搜索:BEGIN -->
<#if view_enableQuickSearch??>
${view_enableQuickSearch}
</#if>
<#-- 自定义头部快速搜索:END -->
</#if> </#if>
<#-- 输出快速搜索:END --> <#-- 输出快速搜索:END -->
<#-- 自定义头部按钮:BEGIN --> <#-- 自定义头部按钮:BEGIN -->
......
...@@ -53,20 +53,22 @@ ...@@ -53,20 +53,22 @@
this.$emit('close', null); this.$emit('close', null);
} }
/**
* 快速搜索值
*
* @memberof ${srfclassname('${view.name}')}
*/
public quickValue = "";
/** /**
* 快速搜索 * 快速搜索
* *
* @memberof ${srfclassname('${view.name}')} * @memberof ${srfclassname('${view.name}')}
*/ */
public async quickValueChange(event: any) { public async quickValueChange(event: any) {
let { detail } = event;
if (!detail) {
return;
}
let { value } = detail;
const pickupviewpanel: any = this.$refs.pickupviewpanel; const pickupviewpanel: any = this.$refs.pickupviewpanel;
if (pickupviewpanel) { if (pickupviewpanel) {
let response = await pickupviewpanel.quickSearch(value); let response = await pickupviewpanel.quickSearch(this.quickValue);
if (response) { if (response) {
} }
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册