VIEW-BASE.vue.ftl 1.3 KB
Newer Older
ibizdev's avatar
ibizdev committed
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40
<#ibizinclude>
../@MACRO/LAYOUTPANEL_VIEW.template.ftl
</#ibizinclude>

<#ibizinclude>
../@MACRO/VIEW_HEADER-BASE.vue.ftl
</#ibizinclude>

<#ibizinclude>
../@MACRO/VIEW_CONTENT-BASE.vue.ftl
</#ibizinclude>

    /**
     * 搜索值
     *
     * @type {string}
     * @memberof ${srfclassname('${view.name}')}
     */
    public query: string = '';

    /**
     * 是否展开搜索表单
     *
     * @type {boolean}
     * @memberof ${srfclassname('${view.name}')}
     */
    public isExpandSearchForm: boolean = ${view.isExpandSearchForm()?c};

    /**
     * 快速搜索
     *
     * @param {*} $event
     * @memberof ${srfclassname('${view.name}')}
     */
    public onSearch($event: any): void {
        const refs: any = this.$refs;
        if (refs.chart) {
            refs.chart.refresh({});
        }
    }
KK's avatar
KK committed
41 42
<#if view.hasPSControl('searchform')>
<#assign searchform = view.getPSControl('searchform')>
KK's avatar
KK committed
43 44 45 46 47 48
    /**
     * 重置搜索表单
     *
     * @memberof ${srfclassname('${view.name}')}Base
     */
    public onReset(): void {
KK's avatar
KK committed
49
        const form: any = this.$refs.searchform;
KK's avatar
KK committed
50 51 52 53
        if (form) {
            form.onReset();
        }
    }
KK's avatar
KK committed
54
</#if>
ibizdev's avatar
ibizdev committed
55 56 57 58 59 60 61
<#ibizinclude>
../@MACRO/VIEW_BOTTOM-BASE.vue.ftl
</#ibizinclude>

<#ibizinclude>
../@MACRO/VIEW-BASE.style.ftl
</#ibizinclude>