Commit 615b09d9 by 张立顺

Merge branch 'v4.37.6-0417' into 'V4.38.1-0422'

版本合并上线

See merge request !305
2 parents b3f528ab c158bfd7
...@@ -10,31 +10,38 @@ import request from "./request" ...@@ -10,31 +10,38 @@ import request from "./request"
// 获取所有主营品牌列表 // 获取所有主营品牌列表
export function brandList(data) { export function brandList(data) {
data.method = "dj.api.smartcarlife.common.car.brand.list" data.method = "dj.api.smartcarlife.common.car.brand.list"
return request(data) return request(data, 'post')
} }
// 查询4s店列表 // 查询4s店列表
export function listShop4sByRef(data) { export function listShop4sByRef(data) {
data.method = "dj.api.scenemerchantref.listShop4sByRef" data.method = "dj.api.scenemerchantref.listShop4sByRef"
return request(data) return request(data, 'post')
} }
// 渗透率报表(分页) // 渗透率报表(分页)会员权益
export function permeabilityList(data) { export function permeabilityList(data) {
data.method = "dj.api.smarcarlife.permeability.report.page" data.method = "dj.api.smarcarlife.permeability.report.page"
return request(data) return request(data, 'post')
} }
// 渗透率报表导出 // 渗透率报表导出 会员权益
export function permeabilityExport(data) { export function permeabilityExport(data) {
data.method = "dj.api.smartcarlife.permeability.report.exportAsync" data.method = "dj.api.smartcarlife.permeability.report.exportAsync"
return request(data) return request(data, 'post')
} }
// 渗透率报表填报明细列表(分页) // 渗透率报表填报明细列表(分页)
export function permeabilityDetail(data) { export function permeabilityDetail(data) {
data.method = "dj.api.smarcarlife.permeability.report.detail.page" data.method = "dj.api.smarcarlife.permeability.report.detail.page"
return request(data) return request(data, 'post')
} }
// 渗透率报表详情导出 // 渗透率报表详情导出
export function permeabilityDetailExport(data) { export function permeabilityDetailExport(data) {
data.method = "dj.api.smartcarlife.permeability.report.detail.exportAsync" data.method = "dj.api.smartcarlife.permeability.report.detail.exportAsync"
return request(data) return request(data, 'post')
}
// 渗透率报表(分页)精品升级
export function permeabilityBoutiqueList(data) {
// data.method = "dj.api.smarcarlife.permeability.report.page"
data.method = "dj.api.smarcarlife.boutique.permeability.report.page"
return request(data, 'post')
} }
...@@ -57,7 +57,7 @@ ...@@ -57,7 +57,7 @@
:filterable="!item.noFilter" :disabled="item.isDisabled" :no-data-text="item.noDataText || '无数据'" :filterable="!item.noFilter" :disabled="item.isDisabled" :no-data-text="item.noDataText || '无数据'"
:multiple="item.multiple" :multiple-limit="item.multipleLimit || 0" :collapse-tags="item.collapseTags" :multiple="item.multiple" :multiple-limit="item.multipleLimit || 0" :collapse-tags="item.collapseTags"
@change="selectAddAttr($event, item)"> @change="selectAddAttr($event, item)">
<el-option v-for="subItem in item.optionList" :key="subItem[item.optionId]" <el-option v-for="(subItem, subIndex) in item.optionList" :key="subIndex"
:label="subItem[item.optionLabel]" :value="subItem[item.optionId]" /> :label="subItem[item.optionLabel]" :value="subItem[item.optionId]" />
</el-select> </el-select>
<el-date-picker v-else-if="item.type === 'datePicker'" v-model="searchForm[item.name]" <el-date-picker v-else-if="item.type === 'datePicker'" v-model="searchForm[item.name]"
......
...@@ -14,16 +14,30 @@ ...@@ -14,16 +14,30 @@
<div class="header"> <div class="header">
<d2-search <d2-search
:search-form="searchForm" :search-form="searchForm"
class="show-search"
label-width="140px"
:search-select-obj="searchSelectObj" :search-select-obj="searchSelectObj"
:form-data="showFormData" :form-data="showFormData"
> >
<template slot="reportDate">
<el-date-picker
size="mini"
v-model="searchForm.reportDate"
type="daterange"
range-separator="至"
start-placeholder="开始日期"
end-placeholder="结束日期"
value-format="yyyy-MM-dd"
:picker-options="pickerOptions"
/>
</template>
<div class="up-btns">
<el-button :id="tableParams.btnId" size="small" type="primary">
查询
</el-button>
<el-button size="small" @click="handleReset"> 重置 </el-button>
</div>
</d2-search> </d2-search>
<div class="up-btns">
<el-button :id="tableParams.btnId" size="small" type="primary">
查询
</el-button>
<el-button size="small" @click="handleReset"> 重置 </el-button>
</div>
</div> </div>
<div class="d2-container-content"> <div class="d2-container-content">
<div class="table-header"> <div class="table-header">
...@@ -58,6 +72,7 @@ export default { ...@@ -58,6 +72,7 @@ export default {
name: "DetailDialog", name: "DetailDialog",
components: {}, components: {},
data() { data() {
let timeOptionRange = null
return { return {
getListApi: permeabilityDetail, getListApi: permeabilityDetail,
countObj: {}, countObj: {},
...@@ -77,6 +92,11 @@ export default { ...@@ -77,6 +92,11 @@ export default {
name: "createdDate", name: "createdDate",
type: "datePicker", type: "datePicker",
valueFormat: "yyyy-MM-dd" valueFormat: "yyyy-MM-dd"
},
{
label: "日报时间",
name: "reportDate",
addHtml: 'reportDate'
} }
], ],
// getListApi: getReportByGoods, // getListApi: getReportByGoods,
...@@ -93,7 +113,10 @@ export default { ...@@ -93,7 +113,10 @@ export default {
}, },
{ {
label: "填报交付数", label: "填报交付数",
prop: "deliveryCount" prop: "deliveryCount",
formatter: (cellValue) => {
return (cellValue.deliveryCount ?? '') === '' ? '-' : cellValue.deliveryCount
}
}, },
{ {
label: "填报时间", label: "填报时间",
...@@ -105,7 +128,29 @@ export default { ...@@ -105,7 +128,29 @@ export default {
} }
] ]
}, },
baseData: {} baseData: {},
pickerOptions: {
disabledDate: (time) => {
// 可选范围是今天及之前且最大可选跨度是31天
const secondNum = 30 * 24 * 60 * 60 * 1000;
const today = new Date();
const [year, month, date] = [today.getFullYear(), today.getMonth(), today.getDate()]
const yesterdayStamp = new Date(year, month, date).getTime()
if (timeOptionRange) {
return time.getTime() > timeOptionRange.getTime() + secondNum || time.getTime() < timeOptionRange.getTime() - secondNum || time.getTime() > yesterdayStamp
} else {
return time.getTime() > yesterdayStamp
}
},
onPick: (dateRange) => {
if (dateRange.minDate && !dateRange.maxDate) {
timeOptionRange = dateRange.minDate
}
if (dateRange.maxDate) {
timeOptionRange = null
}
}
}
} }
}, },
...@@ -125,6 +170,10 @@ export default { ...@@ -125,6 +170,10 @@ export default {
merchantName: { merchantName: {
type: String, type: String,
default: "" default: ""
},
sceneType: {
type: String,
default: '0'
} }
}, },
...@@ -156,6 +205,13 @@ export default { ...@@ -156,6 +205,13 @@ export default {
dayjs(this.searchFormSearch.createdDate[1]).format("YYYY-MM-DD") + dayjs(this.searchFormSearch.createdDate[1]).format("YYYY-MM-DD") +
" 23:59:59" " 23:59:59"
} }
if (this.searchFormSearch.reportDate) {
this.searchFormSearch.reportStartDate =
dayjs(this.searchFormSearch.reportDate[0]).format("YYYY-MM-DD")
this.searchFormSearch.reportEndDate =
dayjs(this.searchFormSearch.reportDate[1]).format("YYYY-MM-DD")
}
this.searchFormSearch.sceneType = this.sceneType
return this.searchFormSearch return this.searchFormSearch
}, },
handleExport() { handleExport() {
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!