debug on RFM

This commit is contained in:
edmondlang
2022-03-24 12:39:24 +08:00
parent 727ebb99ed
commit 9cb0d37f24
@@ -53,14 +53,14 @@
</div>
<div class="col-12 col-md-auto d-flex align-items-center flex-md-column justify-content-center">
<button type="button" class="btn btn-lg btn-primary fs-11 w-100 d-block m-r-5 mr-md-0 mb-md-1 mb-0" @click="submitSearch()">Search</button>
<button type="button" class="btn btn-lg btn-secondary fs-11 w-100 d-block m-l-5 ml-md-0 mt-md-1 0t-0" @click="reserSearch()">Reset</button>
<button type="button" class="btn btn-lg btn-secondary fs-11 w-100 d-block m-l-5 ml-md-0 mt-md-1 0t-0" @click="resetSarch()">Reset</button>
</div>
</div>
</div>
</div>
<div class="row no-margin" v-show="search" :key="serachSectionKey">
<div class="col bg-white padding-25">
<list-component :section="section" :endpoint="route('api.company.list')" :options="{'with_total_payments': true, 'recency': recency, 'frequency': frequency, 'monetary': monetary, 'business_type': 2, with_bookings:true, order_by:{ column:'total_payments', DESC:true}}">
<list-component :section="section" :endpoint="route('api.company.list')" :options="{'with_total_payments': true, 'recency': parameters.recency, 'frequency': parameters.frequency, 'monetary': parameters.monetary, 'business_type': 2, with_bookings:true, order_by:{ column:'total_payments', DESC:true}}">
<template slot="list" slot-scope="{data}">
<company-component :data="data"></company-component>
</template>
@@ -96,10 +96,11 @@ export default {
},
methods: {
submitSearch(){
this.search = true;
this.serachSectionKey ++;
this.search = true;
},
reserSearch() {
resetSarch() {
this.search = false;
this.parameters.recency = '2022-02-15';
this.parameters.frequency = 0;
this.parameters.frequencyDateFrom ='2021-01-01';
@@ -107,7 +108,6 @@ export default {
this.parameters.monetary = 0;
this.parameters.monetaryDateFrom = '2021-01-01';
this.parameters.monetaryDateTo = '2022-02-15';
this.serachSectionKey ++;
}
},
validations: {