|
@@ -25,7 +25,6 @@
|
|
|
</div>
|
|
|
<rangeDate
|
|
|
ref="rangeDate"
|
|
|
- :showTime="false"
|
|
|
:value="queryParam.time"
|
|
|
id="sfdetail-time"
|
|
|
@change="dateChange" />
|
|
@@ -33,27 +32,27 @@
|
|
|
</a-col>
|
|
|
<a-col :md="6" :sm="24">
|
|
|
<a-form-item label="记账主体">
|
|
|
- <a-input id="sfdetail-acount" v-model.trim="queryParam.salesBillNo" allowClear placeholder="请输入记账主体"/>
|
|
|
+ <custList id="sfdetail-belongDealer" dataAuthFlag="0" placeholder="请输入记账主体" ref="belongDealer" @change="belongDealerChange" />
|
|
|
</a-form-item>
|
|
|
</a-col>
|
|
|
<a-col :md="6" :sm="24">
|
|
|
<a-form-item label="业务单号">
|
|
|
- <a-input id="sfdetail-bizNo" v-model.trim="queryParam.salesBillNo" allowClear placeholder="请输入业务单号"/>
|
|
|
+ <a-input id="sfdetail-bizNo" v-model.trim="queryParam.bizNo" allowClear placeholder="请输入业务单号"/>
|
|
|
</a-form-item>
|
|
|
</a-col>
|
|
|
<template v-if="advanced">
|
|
|
<a-col :md="6" :sm="24">
|
|
|
<a-form-model-item label="客户名称">
|
|
|
- <a-input id="sfdetail-custName" v-model.trim="queryParam.salesBillNo" allowClear placeholder="请输入客户名称"/>
|
|
|
+ <custList id="sfdetail-custName" dataAuthFlag="0" placeholder="请输入客户名称" ref="custList" @change="custChange" />
|
|
|
</a-form-model-item>
|
|
|
</a-col>
|
|
|
<a-col :md="6" :sm="24">
|
|
|
<a-form-model-item label="业务类型">
|
|
|
<v-select
|
|
|
- v-model="queryParam.dealerLevel"
|
|
|
- ref="dealerLevel"
|
|
|
- id="sfdetail-dealerLevel"
|
|
|
- code="DEALER_LEVEL"
|
|
|
+ v-model="queryParam.bizType"
|
|
|
+ ref="bizType"
|
|
|
+ id="sfdetail-bizType"
|
|
|
+ code="SUBSIDY_BIZ_TYPE"
|
|
|
placeholder="请选择业务类型"
|
|
|
allowClear></v-select>
|
|
|
</a-form-model-item>
|
|
@@ -66,8 +65,8 @@
|
|
|
<a-col :md="6" :sm="24">
|
|
|
<a-form-model-item label="是否轮胎省仓">
|
|
|
<v-select
|
|
|
- v-model="queryParam.provinceFlag"
|
|
|
- id="sfdetail-provinceFlag"
|
|
|
+ v-model="queryParam.belongProvinceFlag"
|
|
|
+ id="sfdetail-belongProvinceFlag"
|
|
|
code="Flag"
|
|
|
placeholder="请选择是否轮胎省仓"
|
|
|
allowClear></v-select>
|
|
@@ -137,15 +136,13 @@
|
|
|
</template>
|
|
|
<template slot="footer">
|
|
|
<a-row :gutter="15">
|
|
|
- <a-col :md="6" :sm="24">服务费金额:{{ (totalData && (totalData.outAmount || totalData.outAmount==0)) ? toThousands(totalData.outAmount): '--' }}</a-col>
|
|
|
- <a-col :md="6" :sm="24">运费补贴金额:{{ (totalData && (totalData.rebateAmountSys || totalData.rebateAmountSys==0)) ? toThousands(totalData.rebateAmountSys): '--' }}</a-col>
|
|
|
+ <a-col :md="6" :sm="24">服务费金额:{{ (totalData && (totalData.subsidyServiceAmount || totalData.subsidyServiceAmount==0)) ? toThousands(totalData.subsidyServiceAmount): '--' }}</a-col>
|
|
|
+ <a-col :md="6" :sm="24">运费补贴金额:{{ (totalData && (totalData.subsidyShippingAmount || totalData.subsidyShippingAmount==0)) ? toThousands(totalData.subsidyShippingAmount): '--' }}</a-col>
|
|
|
</a-row>
|
|
|
</template>
|
|
|
</s-table>
|
|
|
</a-spin>
|
|
|
</a-card>
|
|
|
- <!-- 导出提示框 -->
|
|
|
- <reportModal :visible="showExport" @close="showExport=false"></reportModal>
|
|
|
</div>
|
|
|
</template>
|
|
|
|
|
@@ -159,15 +156,13 @@ import { STable, VSelect } from '@/components'
|
|
|
import rangeDate from '@/views/common/rangeDate.vue'
|
|
|
import subarea from '@/views/common/subarea.js'
|
|
|
import AreaList from '@/views/common/areaList.js'
|
|
|
-import reportModal from '@/views/common/reportModal.vue'
|
|
|
-import dealerSubareaScopeList from '@/views/common/dealerSubareaScopeList.vue'
|
|
|
import custList from '@/views/common/custList.vue'
|
|
|
// 接口
|
|
|
-import { tireFeeReportList, tireFeeReportCount, tireFeeListExport } from '@/api/reportData'
|
|
|
+import { subsidyDetailList, subsidyDetailCount, subsidyDetailExport } from '@/api/reportData'
|
|
|
export default {
|
|
|
name: 'ServiceFreightDetailList',
|
|
|
mixins: [commonMixin],
|
|
|
- components: { STable, VSelect, rangeDate, subarea, AreaList, dealerSubareaScopeList, custList, reportModal },
|
|
|
+ components: { STable, VSelect, rangeDate, subarea, AreaList, custList },
|
|
|
data () {
|
|
|
return {
|
|
|
spinning: false,
|
|
@@ -175,7 +170,6 @@ export default {
|
|
|
advanced: true, // 高级搜索 展开/关闭
|
|
|
tableHeight: 0, // 表格高度
|
|
|
exportLoading: false, // 导出按钮加载状态
|
|
|
- showExport: false, // 导出弹窗
|
|
|
// 查询条件
|
|
|
queryParam: {
|
|
|
time: [
|
|
@@ -184,18 +178,21 @@ export default {
|
|
|
], // 日期
|
|
|
beginDate: getDate.getCurrMonthDays().starttime, // 开始时间
|
|
|
endDate: getDate.getCurrMonthDays().endtime, // 结束时间
|
|
|
- customSn: undefined, // 客户sn
|
|
|
+ bizNo: undefined, // 业务单号
|
|
|
+ bizType: undefined, // 业务类型
|
|
|
+ belongProvinceFlag: undefined, // 是否轮胎省仓
|
|
|
subareaArea: {
|
|
|
- subareaSn: '', // 区域
|
|
|
- subareaAreaSn: '' // 分区
|
|
|
+ subareaSn: undefined, // 区域
|
|
|
+ subareaAreaSn: undefined // 分区
|
|
|
},
|
|
|
dealerEntity: {
|
|
|
- dealerName: undefined, // 客户名称
|
|
|
- provinceSn: undefined, // 省
|
|
|
- citySn: undefined, // 市
|
|
|
- districtSn: undefined // 区
|
|
|
+ provinceSn: undefined,
|
|
|
+ citySn: undefined,
|
|
|
+ districtSn: undefined
|
|
|
},
|
|
|
- provinceFlag: '1'// 是轮胎省仓
|
|
|
+ belongDealerSn: undefined,
|
|
|
+ transferDealerSn: undefined,
|
|
|
+ dealerSn: undefined
|
|
|
},
|
|
|
totalData: null, // 合计
|
|
|
showOutDetail: false, // 出库明细弹窗
|
|
@@ -208,8 +205,9 @@ export default {
|
|
|
this.spinning = true
|
|
|
const oldParams = Object.assign(parameter, this.queryParam)
|
|
|
const params = JSON.parse(JSON.stringify(oldParams))
|
|
|
+ delete params.time
|
|
|
// 获取列表数据 有分页
|
|
|
- return tireFeeReportList(params).then(res => {
|
|
|
+ return subsidyDetailList(params).then(res => {
|
|
|
let data
|
|
|
if (res.status == 200) {
|
|
|
data = res.data
|
|
@@ -247,16 +245,16 @@ export default {
|
|
|
{ title: '业务单号', dataIndex: 'bizNo', width: '100px', align: 'center', customRender: function (text) { return text || '--' } },
|
|
|
{ title: '区域', dataIndex: 'subareaArea.subareaName', width: '80px', align: 'center', customRender: function (text) { return text || '--' } },
|
|
|
{ title: '分区', dataIndex: 'subareaArea.subareaAreaName', width: '80px', align: 'center', customRender: function (text) { return text || '--' } },
|
|
|
- { title: '省份', scopedSlots: { customRender: 'addressInfo' }, width: '100px', align: 'center' },
|
|
|
- { title: '记账主体', dataIndex: 'bizUserName', width: '90px', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
|
|
|
- { title: '轮胎省仓', dataIndex: 'provinceFlag', width: '80px', align: 'center', customRender: function (text) { return text == '1' ? '是' : '否' } },
|
|
|
- { title: '销售数量', dataIndex: 'dealerEntity.taskNum', width: '80px', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
|
|
|
- { title: '销售金额', dataIndex: 'serviceAmountProvince', width: '10%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text) : '--') } },
|
|
|
- { title: '运费补贴', dataIndex: 'crossRegionQty', width: '80px', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
|
|
|
- { title: '运费补贴金额', dataIndex: 'serviceAmountProvince', width: '10%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text) : '--') } },
|
|
|
- { title: '客户名称', dataIndex: 'dealerEntity.dealerName', width: '150px', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
|
|
|
- { title: '发货经销商', dataIndex: 'parentDealerName', width: '150px', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
|
|
|
- { title: '业务类型', dataIndex: 'parentDealerName', width: '150px', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true }
|
|
|
+ { title: '省份', scopedSlots: { customRender: 'addressInfo' }, width: '80px', align: 'center' },
|
|
|
+ { title: '记账主体', dataIndex: 'belongDealerName', width: '150px', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
|
|
|
+ { title: '轮胎省仓', dataIndex: 'belongProvinceFlagDictValue', width: '80px', align: 'center', customRender: function (text) { return text || '--' } },
|
|
|
+ { title: '销售数量', dataIndex: 'bizQty', width: '80px', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
|
|
|
+ { title: '销售金额', dataIndex: 'bizAmount', width: '100px', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text) : '--') } },
|
|
|
+ { title: '运费补贴', dataIndex: 'subsidyShippingDiff', width: '80px', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
|
|
|
+ { title: '运费补贴金额', dataIndex: 'subsidyShippingAmount', width: '100px', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text) : '--') } },
|
|
|
+ { title: '客户名称', dataIndex: 'dealerName', width: '150px', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
|
|
|
+ { title: '发货经销商', dataIndex: 'transferDealerName', width: '150px', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
|
|
|
+ { title: '业务类型', dataIndex: 'bizTypeDictValue', width: '100px', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true }
|
|
|
]
|
|
|
return arr
|
|
|
}
|
|
@@ -281,21 +279,27 @@ export default {
|
|
|
} else {
|
|
|
this.queryParam.time = []
|
|
|
}
|
|
|
- this.queryParam.beginDate = date[0] ? date[0].replace(/-/g, '') : ''
|
|
|
- this.queryParam.endDate = date[1] ? date[1].replace(/-/g, '') : ''
|
|
|
+ this.queryParam.beginDate = date[0]
|
|
|
+ this.queryParam.endDate = date[1]
|
|
|
},
|
|
|
// 选择发货经销商
|
|
|
custTireChange (val) {
|
|
|
+ this.queryParam.transferDealerName = val.name
|
|
|
this.queryParam.transferDealerSn = val.key
|
|
|
},
|
|
|
+ // 记账主体
|
|
|
+ belongDealerChange (val) {
|
|
|
+ this.queryParam.belongDealerName = val.name
|
|
|
+ this.queryParam.belongDealerSn = val.key
|
|
|
+ },
|
|
|
// 客户名称 change
|
|
|
custChange (val) {
|
|
|
- this.queryParam.dealerEntity.dealerName = val.name
|
|
|
- this.queryParam.customSn = val.key
|
|
|
+ this.queryParam.dealerName = val.name
|
|
|
+ this.queryParam.dealerSn = val.key
|
|
|
},
|
|
|
// 统计
|
|
|
getCount (params) {
|
|
|
- tireFeeReportCount(params).then(res => {
|
|
|
+ subsidyDetailCount(params).then(res => {
|
|
|
if (res.status == 200 && res.data) {
|
|
|
this.totalData = res.data
|
|
|
} else {
|
|
@@ -303,7 +307,7 @@ export default {
|
|
|
}
|
|
|
})
|
|
|
},
|
|
|
- // 地区
|
|
|
+ // 地区省份
|
|
|
areaChange (val) {
|
|
|
this.queryParam.dealerEntity.provinceSn = val[0] ? val[0] : undefined
|
|
|
this.queryParam.dealerEntity.citySn = val[1] ? val[1] : undefined
|
|
@@ -311,25 +315,35 @@ export default {
|
|
|
},
|
|
|
// 区域分区 change
|
|
|
subareaChange (val) {
|
|
|
- this.queryParam.subareaArea.subareaSn = val[0] ? val[0] : ''
|
|
|
- this.queryParam.subareaArea.subareaAreaSn = val[1] ? val[1] : ''
|
|
|
+ this.queryParam.subareaArea.subareaSn = val[0] ? val[0] : undefined
|
|
|
+ this.queryParam.subareaArea.subareaAreaSn = val[1] ? val[1] : undefined
|
|
|
},
|
|
|
// 重置
|
|
|
resetSearchForm () {
|
|
|
+ this.queryParam.time = [
|
|
|
+ moment(getDate.getCurrMonthDays().starttime, 'YYYY-MM-DD'),
|
|
|
+ moment(getDate.getCurrMonthDays().endtime, 'YYYY-MM-DD')
|
|
|
+ ]
|
|
|
this.$refs.rangeDate.resetDate(this.queryParam.time)
|
|
|
this.queryParam.beginDate = getDate.getCurrMonthDays().starttime
|
|
|
this.queryParam.endDate = getDate.getCurrMonthDays().endtime
|
|
|
+ this.queryParam.bizNo = undefined
|
|
|
+ this.queryParam.bizType = undefined
|
|
|
+ this.queryParam.belongDealerSn = undefined
|
|
|
+ this.queryParam.transferDealerSn = undefined
|
|
|
+ this.queryParam.dealerSn = undefined
|
|
|
+ this.queryParam.belongProvinceFlag = undefined
|
|
|
this.queryParam.dealerEntity.provinceSn = undefined
|
|
|
this.queryParam.dealerEntity.citySn = undefined
|
|
|
this.queryParam.dealerEntity.districtSn = undefined
|
|
|
- this.queryParam.dealerEntity.dealerName = undefined
|
|
|
- this.queryParam.customSn = undefined
|
|
|
- this.queryParam.subareaArea.subareaSn = ''
|
|
|
- this.queryParam.subareaArea.subareaAreaSn = ''
|
|
|
- this.$refs.subarea.clearData()
|
|
|
- this.$refs.areaList.clearData()
|
|
|
+ this.queryParam.subareaArea.subareaSn = undefined
|
|
|
+ this.queryParam.subareaArea.subareaAreaSn = undefined
|
|
|
if (this.advanced) {
|
|
|
- this.$refs.dealerSubareaScopeList.resetForm()
|
|
|
+ this.$refs.dealerTireScopeList.resetForm()
|
|
|
+ this.$refs.belongDealer.resetForm()
|
|
|
+ this.$refs.custList.resetForm()
|
|
|
+ this.$refs.subarea.clearData()
|
|
|
+ this.$refs.areaList.clearData()
|
|
|
}
|
|
|
this.totalData = null
|
|
|
this.$refs.table.clearTable()
|
|
@@ -342,7 +356,7 @@ export default {
|
|
|
if (valid) {
|
|
|
_this.exportList()
|
|
|
} else {
|
|
|
- _this.$message.error('请选择查询年份')
|
|
|
+ _this.$message.error('请选择查询时间')
|
|
|
return false
|
|
|
}
|
|
|
})
|
|
@@ -353,8 +367,7 @@ export default {
|
|
|
const params = JSON.parse(JSON.stringify(_this.queryParam))
|
|
|
_this.exportLoading = true
|
|
|
_this.spinning = true
|
|
|
- _this.showExport = true
|
|
|
- hdExportExcel(tireFeeListExport, params, '轮胎年度费用报表', function () {
|
|
|
+ hdExportExcel(subsidyDetailExport, params, '轮胎服务费运费明细报表-', function () {
|
|
|
_this.exportLoading = false
|
|
|
_this.spinning = false
|
|
|
})
|