|
@@ -2,25 +2,25 @@
|
|
import { Search } from '@element-plus/icons-vue'
|
|
import { Search } from '@element-plus/icons-vue'
|
|
// import dropdownText from '@/components/dropdown-text/index.vue'
|
|
// import dropdownText from '@/components/dropdown-text/index.vue'
|
|
import {getInvoicePaymentList,updatePayType,setServiceAmount} from '@/api/financialStatistics'
|
|
import {getInvoicePaymentList,updatePayType,setServiceAmount} from '@/api/financialStatistics'
|
|
-import {getSellerGroupList} from '@/api/crm'
|
|
|
|
-import {getServiceList} from '@/api/financialMana'
|
|
|
|
|
|
+import {getSellerGroupList,getSellerList} from '@/api/crm'
|
|
|
|
+import {getSimpleServiceList} from '@/api/financialMana'
|
|
import {downloadByFlow} from '@/utils/common-methods'
|
|
import {downloadByFlow} from '@/utils/common-methods'
|
|
|
|
|
|
const moment = inject('$moment')
|
|
const moment = inject('$moment')
|
|
const timeTypeData=[{label:'开票日期',value:1},{label:'到款日期',value:2},{label:'开票日期&到款日期',value:3}]
|
|
const timeTypeData=[{label:'开票日期',value:1},{label:'到款日期',value:2},{label:'开票日期&到款日期',value:3}]
|
|
const dateButtonData=[{text:'近1月',tabId:1},{text:'近2月',tabId:2},{text:'近3月',tabId:3}]
|
|
const dateButtonData=[{text:'近1月',tabId:1},{text:'近2月',tabId:2},{text:'近3月',tabId:3}]
|
|
|
|
|
|
- const groupList=ref([])
|
|
|
|
- const serviceList=ref([])
|
|
|
|
|
|
+ // const groupList=ref([])
|
|
|
|
|
|
|
|
+ // sell_group_id:'',
|
|
const searchParams=reactive({
|
|
const searchParams=reactive({
|
|
current:1,
|
|
current:1,
|
|
page_size:10,
|
|
page_size:10,
|
|
keyword:'',
|
|
keyword:'',
|
|
- sell_group_id:'',
|
|
|
|
- service_type:'',
|
|
|
|
- start_date:'',
|
|
|
|
- end_date:'',
|
|
|
|
|
|
+ seller_ids:'',
|
|
|
|
+ service_types:'',
|
|
|
|
+ start_date:moment().startOf('year').format('YYYY-MM-DD') || '',
|
|
|
|
+ end_date:moment(new Date()).format('YYYY-MM-DD') || '',
|
|
// 1-开票日期&到款日期 2-开票日期 3-到款日期
|
|
// 1-开票日期&到款日期 2-开票日期 3-到款日期
|
|
time_type:"",
|
|
time_type:"",
|
|
// 1-已开票
|
|
// 1-已开票
|
|
@@ -31,7 +31,7 @@ const moment = inject('$moment')
|
|
sort_param:'',
|
|
sort_param:'',
|
|
is_export:0
|
|
is_export:0
|
|
})
|
|
})
|
|
- const searchDate=ref(null)
|
|
|
|
|
|
+ const searchDate=ref([moment().startOf('year').format('YYYY-MM-DD'),moment(new Date()).format('YYYY-MM-DD')])
|
|
const currentDateTab=ref(0)
|
|
const currentDateTab=ref(0)
|
|
|
|
|
|
|
|
|
|
@@ -63,19 +63,11 @@ const moment = inject('$moment')
|
|
// method
|
|
// method
|
|
|
|
|
|
//获取销售组别
|
|
//获取销售组别
|
|
- const getSellerGroupListFun=()=>{
|
|
|
|
- getSellerGroupList().then(res=>{
|
|
|
|
- groupList.value=res.data || []
|
|
|
|
- })
|
|
|
|
- }
|
|
|
|
- // 获取套餐列表
|
|
|
|
- const getServiceListFun=()=>{
|
|
|
|
- getServiceList().then(res=>{
|
|
|
|
- serviceList.value=res.data || []
|
|
|
|
- })
|
|
|
|
- }
|
|
|
|
-
|
|
|
|
-
|
|
|
|
|
|
+ // const getSellerGroupListFun=()=>{
|
|
|
|
+ // getSellerGroupList().then(res=>{
|
|
|
|
+ // groupList.value=res.data || []
|
|
|
|
+ // })
|
|
|
|
+ // }
|
|
const commodityPList=()=>{
|
|
const commodityPList=()=>{
|
|
// console.log(searchParams);
|
|
// console.log(searchParams);
|
|
getInvoicePaymentList(searchParams).then(res=>{
|
|
getInvoicePaymentList(searchParams).then(res=>{
|
|
@@ -155,9 +147,37 @@ const moment = inject('$moment')
|
|
}else{
|
|
}else{
|
|
invoiceIsFold.value = !invoiceIsFold.value
|
|
invoiceIsFold.value = !invoiceIsFold.value
|
|
}
|
|
}
|
|
- console.log(type,invoiceIsFold.value);
|
|
|
|
|
|
+ // console.log(type,invoiceIsFold.value);
|
|
|
|
+ }
|
|
|
|
+ // --------------------------销售选择
|
|
|
|
+
|
|
|
|
+ const sellerArray=ref([])
|
|
|
|
+ // 销售类型
|
|
|
|
+ const sellerTypeArray=ref(['','FICC销售','权益销售'])
|
|
|
|
+ const sellerChange=(value)=>{
|
|
|
|
+ searchParams.seller_ids = value.join(',')
|
|
|
|
+ searchCommodityP()
|
|
|
|
+ }
|
|
|
|
+ // 获取销售列表
|
|
|
|
+ const getSellerListFun=()=>{
|
|
|
|
+ getSellerList().then(res=>{
|
|
|
|
+ sellerArray.value = res.data?.all_list || []
|
|
|
|
+ // console.log(res);
|
|
|
|
+ })
|
|
}
|
|
}
|
|
|
|
|
|
|
|
+ // -------------------套餐选择
|
|
|
|
+ const serviceList=ref([])
|
|
|
|
+ // 获取简易套餐列表
|
|
|
|
+ const getServiceListFun=()=>{
|
|
|
|
+ getSimpleServiceList().then(res=>{
|
|
|
|
+ serviceList.value=res.data || []
|
|
|
|
+ })
|
|
|
|
+ }
|
|
|
|
+ const serviceChange=(value)=>{
|
|
|
|
+ searchParams.service_types = value.join(',')
|
|
|
|
+ searchCommodityP()
|
|
|
|
+ }
|
|
// -----------------------------------------------------弹窗
|
|
// -----------------------------------------------------弹窗
|
|
// ---------------------------------编辑付款方式
|
|
// ---------------------------------编辑付款方式
|
|
const payTypeArray=[{id:0,type:'无'},{id:1,type:'年付'},{id:2,type:'半年付'},{id:3,type:'季付'},{id:4,type:'次付'},{id:5,type:'异常'}]
|
|
const payTypeArray=[{id:0,type:'无'},{id:1,type:'年付'},{id:2,type:'半年付'},{id:3,type:'季付'},{id:4,type:'次付'},{id:5,type:'异常'}]
|
|
@@ -251,36 +271,37 @@ const moment = inject('$moment')
|
|
// --------------------------------设置套餐信息
|
|
// --------------------------------设置套餐信息
|
|
// -----------------------------------------------------弹窗
|
|
// -----------------------------------------------------弹窗
|
|
|
|
|
|
- // 初始化 开始日期和结束日期的查询条件
|
|
|
|
- try {
|
|
|
|
- searchDate.value = [moment().startOf('year').format('YYYY-MM-DD'),moment(new Date()).format('YYYY-MM-DD')]
|
|
|
|
- } catch (error) {
|
|
|
|
- console.error(error.message);
|
|
|
|
- commodityPList()
|
|
|
|
- }
|
|
|
|
|
|
|
|
// created
|
|
// created
|
|
- getSellerGroupListFun()
|
|
|
|
|
|
+ // getSellerGroupListFun()
|
|
getServiceListFun()
|
|
getServiceListFun()
|
|
-
|
|
|
|
-
|
|
|
|
-
|
|
|
|
|
|
+ commodityPList()
|
|
|
|
+ getSellerListFun()
|
|
|
|
|
|
</script>
|
|
</script>
|
|
|
|
|
|
<template>
|
|
<template>
|
|
<div id="commodity-payment-container" class="commodity-payment-container">
|
|
<div id="commodity-payment-container" class="commodity-payment-container">
|
|
<div class="search-zone">
|
|
<div class="search-zone">
|
|
- <el-input v-model="searchParams.keyword" placeholder="请输入客户名称/销售" clearable class="search-zone-item"
|
|
|
|
- @input="searchCommodityP" :prefix-icon="Search" style="width: 240px;"></el-input>
|
|
|
|
- <el-select v-model="searchParams.sell_group_id" placeholder="请选择销售组别" clearable
|
|
|
|
- @change="searchCommodityP" class="search-zone-item">
|
|
|
|
|
|
+ <el-input v-model="searchParams.keyword" placeholder="请输入客户名称" clearable class="search-item"
|
|
|
|
+ @input="searchCommodityP" :prefix-icon="Search" style="width: 240px;" ></el-input>
|
|
|
|
+ <!-- <el-select v-model="searchParams.sell_group_id" placeholder="请选择销售组别" clearable style="width: 240px;margin: 0 30px 10px 0;"
|
|
|
|
+ @change="searchCommodityP">
|
|
<el-option :label="item.group_name" :value="item.group_id" v-for="item in groupList"></el-option>
|
|
<el-option :label="item.group_name" :value="item.group_id" v-for="item in groupList"></el-option>
|
|
- </el-select>
|
|
|
|
- <el-select v-model="searchParams.service_type" placeholder="请选择套餐信息" clearable
|
|
|
|
- @change="searchCommodityP" class="search-zone-item">
|
|
|
|
|
|
+ </el-select> -->
|
|
|
|
+ <el-cascader :options="sellerArray" filterable style="width: 200px;margin: 0 0 8px 30px;"
|
|
|
|
+ @change="sellerChange" placeholder="请选择销售" clearable collapse-tags :show-all-levels="false"
|
|
|
|
+ :props="{multiple:true,label:'seller_name',value:'seller_id',children:'child',emitPath:false}" key="seller" >
|
|
|
|
+ </el-cascader>
|
|
|
|
+ <el-cascader :options="serviceList" style="width: 200px;margin: 0 0 8px 30px;" filterable
|
|
|
|
+ @change="serviceChange" placeholder="请选择套餐信息" clearable collapse-tags :show-all-levels="false"
|
|
|
|
+ :props="{multiple:true,label:'title',value:'service_template_id',children:'children',emitPath:false}"
|
|
|
|
+ collapse-tags-tooltip key="serivce" >
|
|
|
|
+ </el-cascader>
|
|
|
|
+ <!-- <el-select v-model="searchParams.service_type" placeholder="请选择套餐信息" clearable style="width: 240px;margin: 0 30px 10px 0;"
|
|
|
|
+ @change="searchCommodityP">
|
|
<el-option :label="item.title" :value="item.service_template_id" v-for="item in serviceList"></el-option>
|
|
<el-option :label="item.title" :value="item.service_template_id" v-for="item in serviceList"></el-option>
|
|
- </el-select>
|
|
|
|
|
|
+ </el-select> -->
|
|
<div class="date-box">
|
|
<div class="date-box">
|
|
<el-date-picker v-model="searchDate" type="daterange" @change="currentDateTab=0" style="max-width: 240px;margin-right: 20px;"
|
|
<el-date-picker v-model="searchDate" type="daterange" @change="currentDateTab=0" style="max-width: 240px;margin-right: 20px;"
|
|
value-format="YYYY-MM-DD" start-placeholder="开始日期" end-placeholder="结束日期"></el-date-picker>
|
|
value-format="YYYY-MM-DD" start-placeholder="开始日期" end-placeholder="结束日期"></el-date-picker>
|
|
@@ -296,12 +317,12 @@ const moment = inject('$moment')
|
|
</el-select>
|
|
</el-select>
|
|
</div>
|
|
</div>
|
|
<el-select v-model="searchParams.has_invoice" placeholder="请选择开票状态" clearable
|
|
<el-select v-model="searchParams.has_invoice" placeholder="请选择开票状态" clearable
|
|
- class="search-zone-item" @change="searchCommodityP">
|
|
|
|
|
|
+ class="search-item" @change="searchCommodityP" >
|
|
<el-option label="未开票" :value="0"></el-option>
|
|
<el-option label="未开票" :value="0"></el-option>
|
|
<el-option label="已开票" :value="1"></el-option>
|
|
<el-option label="已开票" :value="1"></el-option>
|
|
</el-select>
|
|
</el-select>
|
|
- <el-select v-model="searchParams.has_payment" placeholder="请选择到款状态" clearable
|
|
|
|
- style="margin-bottom: 10px;" @change="searchCommodityP">
|
|
|
|
|
|
+ <el-select v-model="searchParams.has_payment" class="search-item" placeholder="请选择到款状态" clearable
|
|
|
|
+ @change="searchCommodityP">
|
|
<el-option label="未到款" :value="0"></el-option>
|
|
<el-option label="未到款" :value="0"></el-option>
|
|
<el-option label="已到款" :value="1"></el-option>
|
|
<el-option label="已到款" :value="1"></el-option>
|
|
</el-select>
|
|
</el-select>
|
|
@@ -393,7 +414,12 @@ const moment = inject('$moment')
|
|
</template>
|
|
</template>
|
|
</el-table-column>
|
|
</el-table-column>
|
|
<el-table-column label="销售" prop="seller_name" align="center"></el-table-column>
|
|
<el-table-column label="销售" prop="seller_name" align="center"></el-table-column>
|
|
- <el-table-column label="组别" prop="seller_group_name" align="center"></el-table-column>
|
|
|
|
|
|
+ <el-table-column label="销售组别" prop="seller_group_name" align="center"></el-table-column>
|
|
|
|
+ <el-table-column label="销售类型" prop="seller_type" align="center">
|
|
|
|
+ <template #default="{row}">
|
|
|
|
+ {{ sellerTypeArray[row.seller_type] }}
|
|
|
|
+ </template>
|
|
|
|
+ </el-table-column>
|
|
<el-table-column label="套餐信息" prop="services_name" align="center">
|
|
<el-table-column label="套餐信息" prop="services_name" align="center">
|
|
<template #default="{row}">
|
|
<template #default="{row}">
|
|
<span v-if="row.payment_amount&&row.payment_amount!=0" @click="setServiceInfo(row)"
|
|
<span v-if="row.payment_amount&&row.payment_amount!=0" @click="setServiceInfo(row)"
|
|
@@ -469,18 +495,18 @@ const moment = inject('$moment')
|
|
min-height: 100%;
|
|
min-height: 100%;
|
|
.search-zone{
|
|
.search-zone{
|
|
margin-bottom: 20px;
|
|
margin-bottom: 20px;
|
|
|
|
+ margin-left: -30px;
|
|
display: flex;
|
|
display: flex;
|
|
align-items: center;
|
|
align-items: center;
|
|
flex-wrap: wrap;
|
|
flex-wrap: wrap;
|
|
- margin-right: -30px;
|
|
|
|
- .search-zone-item{
|
|
|
|
|
|
+ .search-item{
|
|
width: 200px;
|
|
width: 200px;
|
|
- margin: 0 30px 10px 0;
|
|
|
|
|
|
+ margin: 0 0 8px 30px;
|
|
}
|
|
}
|
|
.date-box{
|
|
.date-box{
|
|
display: flex;
|
|
display: flex;
|
|
align-items: center;
|
|
align-items: center;
|
|
- margin: 0 40px 10px 0;
|
|
|
|
|
|
+ margin: 0 0 8px 30px;
|
|
.composition-button-tabs{
|
|
.composition-button-tabs{
|
|
margin-right: 20px;
|
|
margin-right: 20px;
|
|
|
|
|