Commit acb9ebdb authored by lanbaoming's avatar lanbaoming

Merge branch 'dev'

parents 7e29b5c2 d3eb5c5f
...@@ -19,3 +19,12 @@ export function exportExcel(data) { ...@@ -19,3 +19,12 @@ export function exportExcel(data) {
responseType: 'blob' responseType: 'blob'
}) })
} }
export function exportExcel2(data) {
return request({
url: '/Report/CustomerAnalysis/exportExcel2',
method: 'get',
params: data,
responseType: 'blob'
})
}
...@@ -18,3 +18,13 @@ export function exportExcel(query) { ...@@ -18,3 +18,13 @@ export function exportExcel(query) {
responseType: 'blob' responseType: 'blob'
}) })
} }
//获取统计汇总数据 lanbm 2024-05-04 add
export function getStatisticalSummary(query) {
return request({
url: '/Report/SalesAnalysis/getStatisticalSummary',
method: 'get',
params: query
})
}
...@@ -49,3 +49,12 @@ export function exportExcel(query) { ...@@ -49,3 +49,12 @@ export function exportExcel(query) {
responseType: 'blob' responseType: 'blob'
}) })
} }
//测试功能
export function test(query) {
return request({
url: '/ecwVz/vz/Test',
method: 'get',
params: query
})
}
...@@ -133,7 +133,8 @@ ...@@ -133,7 +133,8 @@
</el-table-column> </el-table-column>
<el-table-column prop="price" :label="$t('金额')" align="center"></el-table-column> <el-table-column prop="price" :label="$t('金额')" align="center"></el-table-column>
<el-table-column prop="payPrice" :label="$t('实付金额')" align="center"></el-table-column> <el-table-column prop="payPrice" :label="$t('实付金额')" align="center"></el-table-column>
<el-table-column prop="payTime" :label="$t('实付日期')" align="center"> <el-table-column prop="payTime" :label="$t('创建日期')" align="center">
<!--实付日期 改为 创建日期 lanbm 2024-05-06 add-->
<template slot-scope="scope"> <template slot-scope="scope">
<span v-if="scope.row.payTime">{{formatDate(scope.row.payTime)}}</span> <span v-if="scope.row.payTime">{{formatDate(scope.row.payTime)}}</span>
</template> </template>
......
...@@ -376,7 +376,8 @@ ...@@ -376,7 +376,8 @@
</template> </template>
</el-table-column> </el-table-column>
<el-table-column :label="$t('期望收款汇率')" align="center"> <el-table-column :label="$t('期望收款汇率')" align="center">
<template slot-scope="scope"> <!--lanbm 2024-05-06 汇率保留小数增加到6位,为了方便显示,加宽此列的显示-->
<template slot-scope="scope" style="width: 200px;">
<el-form-item <el-form-item
v-if="scope.row.type !== 'total'" v-if="scope.row.type !== 'total'"
label="" label=""
......
<template> <template>
<div class="app-container"> <div class="app-container">
<div slot="header" class="card-title">{{ $t('付款单') }}</div> <div slot="header" class="card-title">{{ $t("付款单") }}</div>
<!-- 搜索工作栏 --> <!-- 搜索工作栏 -->
<el-card v-show="showSearch" class="card"> <el-card v-show="showSearch" class="card">
<el-form <el-form
:model="queryParams" :model="queryParams"
ref="queryForm" ref="queryForm"
size="small" size="small"
label-width="100px" label-width="150px"
class="card" class="card"
> >
<el-row :gutter="10"> <el-row :gutter="10">
<el-col :span="4"> <el-form-item :label="$t('付款单号')"> <el-col :span="4">
<el-input <el-form-item :label="$t('付款单号')">
clearable <el-input
style="max-width: 188px" clearable
v-model="queryParams.paymentNo" style="max-width: 188px;"
:placeholder="$t('请输入付款单号')" v-model="queryParams.paymentNo"
clearable :placeholder="$t('请输入付款单号')"
@keyup.enter.native="handleQuery" clearable
/> @keyup.enter.native="handleQuery"
</el-form-item></el-col> /> </el-form-item
<el-col :span="4"><el-form-item :label="$t('供应商')"> ></el-col>
<el-select <el-col :span="4"
clearable ><el-form-item :label="$t('供应商')">
v-model="queryParams.supplierId" <el-select
:placeholder="$t('请选择供应商')" clearable
> v-model="queryParams.supplierId"
<el-option :placeholder="$t('请选择供应商')"
v-for="supplier in allSupplier" >
:key="supplier.id" <el-option
:label="supplier.companyZh" v-for="supplier in allSupplier"
:value="supplier.id" :key="supplier.id"
></el-option> :label="supplier.companyZh"
</el-select> :value="supplier.id"
</el-form-item></el-col> ></el-option>
<el-col :span="4"><el-form-item :label="$t('业务员')"> </el-select> </el-form-item
<!-- <el-select v-model="form.salesmanId" :placeholder="$t('请选择业务员')"> ></el-col>
<el-col :span="4"
><el-form-item :label="$t('业务员')">
<!-- <el-select v-model="form.salesmanId" :placeholder="$t('请选择业务员')">
<el-option <el-option
v-for="item in creatorData" v-for="item in creatorData"
:key="item.id" :key="item.id"
...@@ -44,82 +47,116 @@ ...@@ -44,82 +47,116 @@
:value="item.id" :value="item.id"
/> />
</el-select> --> </el-select> -->
<el-select v-model="queryParams.salesmanName" filterable :placeholder="$t('请选择业务员')" <el-select
clearable v-model="queryParams.salesmanName"
> filterable
<el-option :placeholder="$t('请选择业务员')"
v-for="item in creatorData" clearable
:key="item.id" >
:label="item.nickname" <el-option
:value="item.nickname" v-for="item in creatorData"
/> :key="item.id"
</el-select> :label="item.nickname"
</el-form-item> </el-col> :value="item.nickname"
<el-col :span="6"><el-form-item :label="$t('创建时间')"> />
<el-date-picker </el-select>
v-model="queryParams.beginCreateTime" </el-form-item>
type="datetimerange" </el-col>
value-format="yyyy-MM-dd" <el-col :span="6"
range-separator="到" ><el-form-item :label="$t('创建时间')">
:start-placeholder="$t('请选择日期')" <el-date-picker
:end-placeholder="$t('请选择日期')"> v-model="queryParams.beginCreateTime"
</el-date-picker> type="datetimerange"
</el-form-item></el-col> value-format="yyyy-MM-dd"
range-separator="到"
:start-placeholder="$t('请选择日期')"
:end-placeholder="$t('请选择日期')"
>
</el-date-picker> </el-form-item
></el-col>
</el-row> </el-row>
<el-row :gutter="10"> <el-row :gutter="10">
<el-col :span="4"> <el-col :span="4">
<el-form-item :label="$t('状态')"> <el-form-item :label="$t('状态')">
<dict-selector clearable :type="DICT_TYPE.ECW_PAYMENT_STATE" v-model="queryParams.state"/> <dict-selector
clearable
:type="DICT_TYPE.ECW_PAYMENT_STATE"
v-model="queryParams.state"
/>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="4"><el-form-item :label="$t('发票状态')"> <el-col :span="4"
<el-select ><el-form-item :label="$t('发票状态')">
clearable <el-select
v-model="queryParams.invoiceStatus" clearable
:placeholder="$t('请选择是否开票')" v-model="queryParams.invoiceStatus"
> :placeholder="$t('请选择是否开票')"
<el-option :label="$t('未开票')" value="0"/> >
<el-option :label="$t('已开票')" value="1"/> <el-option :label="$t('未开票')" value="0" />
</el-select> <el-option :label="$t('已开票')" value="1" />
</el-form-item></el-col> </el-select> </el-form-item
<el-col :span="6"><el-form-item> ></el-col>
<el-button type="primary" @click="handleQuery">{{ $t('查找') }}</el-button> <el-col :span="6"
<el-button ><el-form-item>
style="margin-left: 10px" <el-button type="primary" @click="handleQuery">{{
type="success" $t("查找")
v-hasPermi="['ecw:paymentVoucher:create']" }}</el-button>
@click="handleAdd(0)" <!--lanbm 2024-05-06 改 “新增请款单” 为 “新增付款单” -->
>{{ $t('新增请款单') }}</el-button <el-button
> style="margin-left: 10px"
</el-form-item></el-col> type="success"
v-hasPermi="['ecw:paymentVoucher:create']"
@click="handleAdd(0)"
>{{ $t("新增付款单") }}</el-button
>
</el-form-item></el-col
>
</el-row> </el-row>
</el-form> </el-form>
</el-card> </el-card>
<el-table v-loading="loadings" :data="list" border class="card"> <el-table v-loading="loadings" :data="list" border class="card">
<el-table-column :label="$t('序号')" align="center" prop="id" type="index"> <el-table-column
:label="$t('序号')"
align="center"
prop="id"
type="index"
>
<template slot-scope="scope"> <template slot-scope="scope">
<span>{{ scope.$index + 1 }}</span> <span>{{ scope.$index + 1 }}</span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column :label="$t('付款单号')" align="center" prop="paymentNo"> <el-table-column :label="$t('付款单号')" align="center" prop="paymentNo">
<template slot-scope="scope"> <template slot-scope="scope">
<span style="color: #1890ff;" @click="paymentDetail(scope.row)">{{ scope.row.paymentNo }}</span> <span style="color: #1890ff" @click="paymentDetail(scope.row)">{{
scope.row.paymentNo
}}</span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column :label="$t('供应商')" align="center" prop="supplierName"/> <el-table-column
:label="$t('供应商')"
align="center"
prop="supplierName"
/>
<el-table-column :label="$t('创建时间')" align="center" prop="createTime"> <el-table-column :label="$t('创建时间')" align="center" prop="createTime">
<template slot-scope="scope"> <template slot-scope="scope">
<span>{{ parseTime(scope.row.createTime, '{y}-{m}-{d}') }}</span> <span>{{ parseTime(scope.row.createTime, "{y}-{m}-{d}") }}</span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column :label="$t('最后付款时间')" align="center" prop="latestPayAt"> <el-table-column
:label="$t('最后付款时间')"
align="center"
prop="latestPayAt"
>
<template slot-scope="scope"> <template slot-scope="scope">
<span>{{ parseTime(scope.row.latestPayAt, '{y}-{m}-{d}') }}</span> <span>{{ parseTime(scope.row.latestPayAt, "{y}-{m}-{d}") }}</span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column :label="$t('发票')" align="center" prop="invoiceStatus"> <el-table-column :label="$t('发票')" align="center" prop="invoiceStatus">
<template slot-scope="scope"> <template slot-scope="scope">
<span>{{ scope.row.invoiceStatus === 0 ? $t('未开票') : $t('已开票') }}</span> <span>{{
scope.row.invoiceStatus === 0 ? $t("未开票") : $t("已开票")
}}</span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column :label="$t('状态')" align="center"> <el-table-column :label="$t('状态')" align="center">
...@@ -128,7 +165,11 @@ ...@@ -128,7 +165,11 @@
:type="DICT_TYPE.ECW_PAYMENT_STATE" :type="DICT_TYPE.ECW_PAYMENT_STATE"
:value="scope.row.state" :value="scope.row.state"
/> />
<span v-if="[2,4,6].includes(scope.row.state) && scope.row.comment" :title="scope.row.comment"><i class="el-icon-question"></i></span> <span
v-if="[2, 4, 6].includes(scope.row.state) && scope.row.comment"
:title="scope.row.comment"
><i class="el-icon-question"></i
></span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column <el-table-column
...@@ -136,37 +177,107 @@ ...@@ -136,37 +177,107 @@
align="center" align="center"
class-name="small-padding fixed-width" class-name="small-padding fixed-width"
> >
<template v-slot="{row}"> <template v-slot="{ row }">
<el-button v-if="[0,2].includes(row.state)" size="mini" @click="handleAdd(row.id)" <el-button
v-hasPermi="['ecw:paymentVoucher:edit']" type="text">{{ $t('编辑') }} v-if="[0, 2].includes(row.state)"
size="mini"
@click="handleAdd(row.id)"
v-hasPermi="['ecw:paymentVoucher:edit']"
type="text"
>{{ $t("编辑") }}
</el-button> </el-button>
<!-- <el-button v-if="[1,3].includes(row.state)" size="mini" v-hasPermi="['ecw:paymentVoucher:process']" type="text" @click="examineClick(scope.row.id)">{{ $t('审核') }}</el-button>--> <!-- <el-button v-if="[1,3].includes(row.state)" size="mini" v-hasPermi="['ecw:paymentVoucher:process']" type="text" @click="examineClick(scope.row.id)">{{ $t('审核') }}</el-button>-->
<el-button size="mini" type="text" v-show="[1].includes(row.state)" v-hasPermi="['ecw:paymentVoucher:Unapprove']" @click="bridgeFn(1, $t('取消审核'),row)"> <el-button
{{ $t('取消审核') }} size="mini"
type="text"
v-show="[1].includes(row.state)"
v-hasPermi="['ecw:paymentVoucher:Unapprove']"
@click="bridgeFn(1, $t('取消审核'), row)"
>
{{ $t("取消审核") }}
</el-button> </el-button>
<el-button size="mini" type="text" v-show="[7,3,1,5].includes(row.state)" v-hasPermi="['ecw:paymentVoucher:details']" @click="$router.push({path:'/bpm/process-instance/detail',query:{id:row.bmpId}})" >{{ $t('审核详情') }}</el-button> <el-button
<el-button size="mini" type="text" v-if="[3].includes(row.state)" v-hasPermi="['ecw:paymentVoucher:Cancel-De-approval']" @click="bridgeFn(2, $t('取消付款单反审核'),row)" >{{ $t('取消反审核') }}</el-button> size="mini"
<el-button size="mini" type="text" v-if="[5].includes(row.state)" v-hasPermi="['ecw:paymentVoucher:Cancel-Write-off']" @click="bridgeFn(3, $t('取消付款单核销'),row)" >{{ $t('取消核销') }}</el-button> type="text"
v-show="[7, 3, 1, 5].includes(row.state)"
v-hasPermi="['ecw:paymentVoucher:details']"
@click="
$router.push({
path: '/bpm/process-instance/detail',
query: { id: row.bmpId },
})
"
>{{ $t("审核详情") }}</el-button
>
<el-button
size="mini"
type="text"
v-if="[3].includes(row.state)"
v-hasPermi="['ecw:paymentVoucher:Cancel-De-approval']"
@click="bridgeFn(2, $t('取消付款单反审核'), row)"
>{{ $t("取消反审核") }}</el-button
>
<el-button
size="mini"
type="text"
v-if="[5].includes(row.state)"
v-hasPermi="['ecw:paymentVoucher:Cancel-Write-off']"
@click="bridgeFn(3, $t('取消付款单核销'), row)"
>{{ $t("取消核销") }}</el-button
>
<el-button v-if="[4].includes(row.state)" size="mini" type="text" v-hasPermi="['ecw:paymentVoucher:De-approval']" <el-button
@click="bridgeFn(4, $t('反审核'),row)">{{ $t('反审核') }} v-if="[4].includes(row.state)"
size="mini"
type="text"
v-hasPermi="['ecw:paymentVoucher:De-approval']"
@click="bridgeFn(4, $t('反审核'), row)"
>{{ $t("反审核") }}
</el-button> </el-button>
<el-button v-if="[4].includes(row.state)" size="mini" type="text" v-hasPermi="['ecw:paymentVoucher:writeOff']" <el-button
@click="bridgeFn(5, $t('核销'),row)">{{ $t('核销') }} v-if="[4].includes(row.state)"
size="mini"
type="text"
v-hasPermi="['ecw:paymentVoucher:writeOff']"
@click="bridgeFn(5, $t('核销'), row)"
>{{ $t("核销") }}
</el-button> </el-button>
<el-button v-if="[6].includes(row.state)" size="mini" type="text" <el-button
v-hasPermi="['ecw:paymentVoucher:cancelWriteOff']" @click="bridgeFn(6, $t('反核销'),row)"> v-if="[6].includes(row.state)"
{{ $t('反核销') }} size="mini"
type="text"
v-hasPermi="['ecw:paymentVoucher:cancelWriteOff']"
@click="bridgeFn(6, $t('反核销'), row)"
>
{{ $t("反核销") }}
</el-button> </el-button>
<el-button v-if="[7].includes(row.state)" v-hasPermi="['ecw:paymentVoucher:Cancel-Cancelling-Write-off']" size="mini" type="text" @click="bridgeFn(7, $t('取消付款单反核销'),row)" > {{ $t('取消反核销') }}</el-button> <el-button
v-if="[7].includes(row.state)"
v-hasPermi="['ecw:paymentVoucher:Cancel-Cancelling-Write-off']"
size="mini"
type="text"
@click="bridgeFn(7, $t('取消付款单反核销'), row)"
>
{{ $t("取消反核销") }}</el-button
>
<!-- <el-button v-if="scope.row.state == 3" size="mini" type="text">{{ $t('开票') }}</el-button> --> <!-- <el-button v-if="scope.row.state == 3" size="mini" type="text">{{ $t('开票') }}</el-button> -->
<el-button v-if="[6,4].includes(row.state)" size="mini" type="text" @click="toprint(row.id)" <el-button
v-hasPermi="['ecw:paymentVoucher:print']">{{ $t('打印') }} v-if="[6, 4].includes(row.state)"
size="mini"
type="text"
@click="toprint(row.id)"
v-hasPermi="['ecw:paymentVoucher:print']"
>{{ $t("打印") }}
</el-button> </el-button>
<el-button v-if="[0,2].includes(row.state)" size="mini" type="text" v-hasPermi="['ecw:paymentVoucher:delete']" <el-button
@click="deleteClick(row)">{{ $t('删除') }} v-if="[0, 2].includes(row.state)"
size="mini"
type="text"
v-hasPermi="['ecw:paymentVoucher:delete']"
@click="deleteClick(row)"
>{{ $t("删除") }}
</el-button> </el-button>
<!-- <el-button size="mini" type="text" @click="open = true">{{ $t('导出订单') }}</el-button> --> <!-- <el-button size="mini" type="text" @click="open = true">{{ $t('导出订单') }}</el-button> -->
</template> </template>
...@@ -193,44 +304,53 @@ ...@@ -193,44 +304,53 @@
class="card-title" class="card-title"
style="border-bottom: 2px solid #f8f8f8" style="border-bottom: 2px solid #f8f8f8"
> >
<span>{{ $t('导出账单') }}</span> <span>{{ $t("导出账单") }}</span>
<i class="el-icon-close" @click="cancel"></i> <i class="el-icon-close" @click="cancel"></i>
</div> </div>
<div class="dialog-footer"> <div class="dialog-footer">
<el-button type="primary" style="width: 130px" @click="submitForm" <el-button type="primary" style="width: 130px" @click="submitForm"
>{{ $t('国内账单') }} >{{ $t("国内账单") }}
</el-button </el-button>
>
<el-button <el-button
plain plain
type="primary" type="primary"
style="width: 130px; margin: 0" style="width: 130px; margin: 0"
@click="submitForm" @click="submitForm"
>Debite note >Debite note
</el-button </el-button>
>
</div> </div>
</el-dialog> </el-dialog>
<!--对话框 审核 --> <!--对话框 审核 -->
<el-dialog width="30%" @close="cancelReason = ''" :title="examineTitle" :visible.sync="examineShow"> <el-dialog
width="30%"
@close="cancelReason = ''"
:title="examineTitle"
:visible.sync="examineShow"
>
<div class="cancel_content"> <div class="cancel_content">
<span>{{ $t('申请理由') }}</span> <span>{{ $t("申请理由") }}</span>
<el-input type="textarea" :rows="6" v-model="cancelReason" :placeholder="$t('请输入取消理由')"></el-input> <el-input
type="textarea"
:rows="6"
v-model="cancelReason"
:placeholder="$t('请输入取消理由')"
></el-input>
</div> </div>
<span slot="footer" class="dialog-footers"> <span slot="footer" class="dialog-footers">
<el-button type="primary" @click="cancelWriteOffClick()">{{ $t('提交') }}</el-button> <el-button type="primary" @click="cancelWriteOffClick()">{{
<el-button @click="examineShow = false;">{{ $t('取消') }}</el-button> $t("提交")
}}</el-button>
<el-button @click="examineShow = false">{{ $t("取消") }}</el-button>
</span> </span>
</el-dialog> </el-dialog>
</div> </div>
</template> </template>
<script> <script>
import {userList, listSimpleUsers} from "@/api/system/user"; import { userList, listSimpleUsers } from "@/api/system/user";
import {DICT_TYPE} from "@/utils/dict"; import { DICT_TYPE } from "@/utils/dict";
import CustomerSelector from "@/components/CustomerSelector"; import CustomerSelector from "@/components/CustomerSelector";
import {getSupplierPage} from "@/api/ecw/supplier"; import { getSupplierPage } from "@/api/ecw/supplier";
import { import {
getPaymentList, getPaymentList,
deletePayment, deletePayment,
...@@ -240,8 +360,9 @@ import { ...@@ -240,8 +360,9 @@ import {
cancelFinancePaymentApproval, cancelFinancePaymentApproval,
cancelFinancePaymentApprovalNo, cancelFinancePaymentApprovalNo,
cancelFinancePaymentWriteOff, cancelFinancePaymentWriteOff,
cancelFinancePaymentWriteOffNo, paymentCancelFinancePaymentWriteOffNo cancelFinancePaymentWriteOffNo,
} from "@/api/ecw/financial" paymentCancelFinancePaymentWriteOffNo,
} from "@/api/ecw/financial";
export default { export default {
name: "EcwFinancialPaymentvoucher", name: "EcwFinancialPaymentvoucher",
...@@ -251,10 +372,10 @@ export default { ...@@ -251,10 +372,10 @@ export default {
data() { data() {
return { return {
examineShow: false, examineShow: false,
examineTitle: '', examineTitle: "",
examineIndex: 0, examineIndex: 0,
examineData: {}, examineData: {},
cancelReason: '', cancelReason: "",
open: false, open: false,
showSearch: true, showSearch: true,
loadings: false, loadings: false,
...@@ -291,25 +412,29 @@ export default { ...@@ -291,25 +412,29 @@ export default {
}; };
}, },
activated() { activated() {
this.handleQuery() this.handleQuery();
}, },
created() { created() {
let that = this; let that = this;
listSimpleUsers().then((res) => (that.creatorData = res.data)); listSimpleUsers().then((res) => (that.creatorData = res.data));
// userList("salesman").then((res) => (that.creatorData = res.data)); // userList("salesman").then((res) => (that.creatorData = res.data));
getSupplierPage({pageNo: "1", pageSize: "10000"}).then((res) => { getSupplierPage({ pageNo: "1", pageSize: "10000" }).then((res) => {
const {data} = res; const { data } = res;
this.allSupplier = data.list; this.allSupplier = data.list;
}); });
this.getList() this.getList();
}, },
methods: { methods: {
/** 查询列表 */ /** 查询列表 */
getList() { getList() {
this.loading = true; this.loading = true;
// 处理查询参数 // 处理查询参数
let params = {...this.queryParams}; let params = { ...this.queryParams };
this.addBeginAndEndTime(params, this.queryParams.beginCreateTime, "createTime"); this.addBeginAndEndTime(
params,
this.queryParams.beginCreateTime,
"createTime"
);
// 执行查询 // 执行查询
getPaymentList(params).then((response) => { getPaymentList(params).then((response) => {
this.list = response.data.list; this.list = response.data.list;
...@@ -329,13 +454,13 @@ export default { ...@@ -329,13 +454,13 @@ export default {
stateMap(state) { stateMap(state) {
switch (state) { switch (state) {
case 1: case 1:
return this.$t('待审核') return this.$t("待审核");
case 2: case 2:
return this.$t('已审核待核销') return this.$t("已审核待核销");
case 3: case 3:
return this.$t('审批驳回') return this.$t("审批驳回");
case 4: case 4:
return this.$t('已核销') return this.$t("已核销");
} }
}, },
/** 新增按钮操作 */ /** 新增按钮操作 */
...@@ -347,43 +472,55 @@ export default { ...@@ -347,43 +472,55 @@ export default {
}, },
deleteClick(row) { deleteClick(row) {
const id = row.id; const id = row.id;
this.$modal.confirm(this.$t('是否确认删除该付款单') + '?').then(function () { this.$modal
return deletePayment(id); .confirm(this.$t("是否确认删除该付款单") + "?")
}).then(() => { .then(function () {
this.getList(); return deletePayment(id);
this.$modal.msgSuccess(this.$t('删除成功')); })
}).catch(() => { .then(() => {
}); this.getList();
this.$modal.msgSuccess(this.$t("删除成功"));
})
.catch(() => {});
}, },
verificationClick(row) { verificationClick(row) {
const id = row.id; const id = row.id;
this.$modal.confirm(this.$t('您确认要核销吗') + '?').then(function () { this.$modal
return paymentVerification(id); .confirm(this.$t("您确认要核销吗") + "?")
}).then(() => { .then(function () {
this.getList(); return paymentVerification(id);
this.$modal.msgSuccess(this.$t('核销成功')); })
}).catch(() => { .then(() => {
}); this.getList();
this.$modal.msgSuccess(this.$t("核销成功"));
})
.catch(() => {});
}, },
verificationCancelClick(row) { verificationCancelClick(row) {
const id = row.id; const id = row.id;
this.$modal.confirm(this.$t('您确认要反核销吗') + '?').then(function () { this.$modal
return paymentVerificationCancel(id); .confirm(this.$t("您确认要反核销吗") + "?")
}).then(() => { .then(function () {
this.getList(); return paymentVerificationCancel(id);
this.$modal.msgSuccess(this.$t('反核销成功')); })
}).catch(() => { .then(() => {
}); this.getList();
this.$modal.msgSuccess(this.$t("反核销成功"));
})
.catch(() => {});
}, },
verifyCancelClick(row) { verifyCancelClick(row) {
const id = row.id; const id = row.id;
this.$modal.confirm(this.$t('您确认要反审核吗') + '?').then(function () { this.$modal
return paymentVerifyCancel(id); .confirm(this.$t("您确认要反审核吗") + "?")
}).then(() => { .then(function () {
this.getList(); return paymentVerifyCancel(id);
this.$modal.msgSuccess(this.$t('反审核成功')); })
}).catch(() => { .then(() => {
}); this.getList();
this.$modal.msgSuccess(this.$t("反审核成功"));
})
.catch(() => {});
}, },
toprint(id) { toprint(id) {
return this.$router.push("printPaymentVoucher?id=" + id); return this.$router.push("printPaymentVoucher?id=" + id);
...@@ -402,52 +539,76 @@ export default { ...@@ -402,52 +539,76 @@ export default {
this.examineShow = true; this.examineShow = true;
}, },
cancelWriteOffClick() { cancelWriteOffClick() {
if(!this.cancelReason){ if (!this.cancelReason) {
return this.$message.warning(this.$t('请输入申请理由!')) return this.$message.warning(this.$t("请输入申请理由!"));
} }
let resolve = (val = this.$t('操作成功吗!')) => { let resolve = (val = this.$t("操作成功吗!")) => {
this.getList(); this.getList();
this.$message.success(val); this.$message.success(val);
this.examineShow = false; this.examineShow = false;
} };
let reject = () => { let reject = () => {
this.examineShow = false; this.examineShow = false;
} };
let {id: paymentId,paymentNo} = this.examineData let { id: paymentId, paymentNo } = this.examineData;
let p = {paymentId, remark: this.cancelReason, paymentNo, reason:this.cancelReason } let p = {
paymentId,
remark: this.cancelReason,
paymentNo,
reason: this.cancelReason,
};
switch (this.examineIndex) { switch (this.examineIndex) {
case 1: case 1:
// 取消审核 // 取消审核
cancelFinancePaymentApproval(p).then(()=>resolve(this.$t('取消付款单审核成功!')),reject) cancelFinancePaymentApproval(p).then(
break () => resolve(this.$t("取消付款单审核成功!")),
reject
);
break;
// 取消付款单反审核 // 取消付款单反审核
case 2: case 2:
cancelFinancePaymentApprovalNo(p).then(()=>resolve(this.$t('取消付款单反审核成功!')),reject) cancelFinancePaymentApprovalNo(p).then(
() => resolve(this.$t("取消付款单反审核成功!")),
reject
);
break; break;
case 3: case 3:
//取消付款单核销 //取消付款单核销
cancelFinancePaymentWriteOffNo(p).then(()=>resolve(this.$t('取消付款单核销成功!')),reject) cancelFinancePaymentWriteOffNo(p).then(
break () => resolve(this.$t("取消付款单核销成功!")),
reject
);
break;
case 4: case 4:
// 反审核 // 反审核
paymentVerifyCancel(p).then(()=>resolve(this.$t('提交付款单反审核成功,请耐心等待审核结果!')),reject) paymentVerifyCancel(p).then(
() => resolve(this.$t("提交付款单反审核成功,请耐心等待审核结果!")),
reject
);
break; break;
case 5: case 5:
// 核销 // 核销
paymentVerification(p).then(()=>resolve(this.$t('提交付款单核销成功,请耐心等待审核结果!')),reject); paymentVerification(p).then(
() => resolve(this.$t("提交付款单核销成功,请耐心等待审核结果!")),
reject
);
break; break;
case 6: case 6:
// 反核销 // 反核销
paymentVerificationCancel(p).then(()=>resolve(this.$t('提交付款单反核销成功,请耐心等待审核结果!')),reject) paymentVerificationCancel(p).then(
() => resolve(this.$t("提交付款单反核销成功,请耐心等待审核结果!")),
reject
);
break; break;
case 7: case 7:
// 取消反核销 // 取消反核销
paymentCancelFinancePaymentWriteOffNo(p).then(()=>resolve(this.$t('取消付款单反核销成功!')),reject) paymentCancelFinancePaymentWriteOffNo(p).then(
() => resolve(this.$t("取消付款单反核销成功!")),
reject
);
break; break;
} }
} },
}, },
}; };
</script> </script>
......
...@@ -88,7 +88,7 @@ export default { ...@@ -88,7 +88,7 @@ export default {
}, },
computed:{ computed:{
orderInfoForCopy(){ orderInfoForCopy(){
return `订单号:${this.order.orderNo}\n唛头:${this.order.marks}\n提货点:${this.order.logisticsInfoDto?.destTitleZh}\n送货地址:${this.order.logisticsInfoDto?.startAddressZh}` return `订单号:${this.order.orderNo}\n唛头:${this.order.marks}\n提货点:${this.order.logisticsInfoDto?.destTitleZh}\n送货地址:${this.order.logisticsInfoDto?.startAddressZh}\n仓库电话: ${this.order.logisticsInfoDto?.startTell}`
} }
}, },
async created(){ async created(){
......
...@@ -249,7 +249,7 @@ ...@@ -249,7 +249,7 @@
size="mini" size="mini"
@click="handleExport" @click="handleExport"
:loading="exportLoading" :loading="exportLoading"
v-show="objEcwReportPermission.exportdataq == 1" v-show="false"
> >
{{ $t("导出") }}</el-button {{ $t("导出") }}</el-button
> >
...@@ -264,9 +264,9 @@ ...@@ -264,9 +264,9 @@
size="mini" size="mini"
@click="handleExport2" @click="handleExport2"
:loading="exportLoading" :loading="exportLoading"
v-show="false" v-show="objEcwReportPermission.exportdataq == 1"
> >
{{ $t("导出测试") }}</el-button {{ $t("导出") }}</el-button
> >
</el-form-item> </el-form-item>
</el-form> </el-form>
...@@ -327,12 +327,24 @@ ...@@ -327,12 +327,24 @@
<el-table-column label="泡货占比" align="center" prop="phSumZb" /> <el-table-column label="泡货占比" align="center" prop="phSumZb" />
<el-table-column label="控货总V值" align="center" prop="khSumV" /> <el-table-column label="控货总V值" align="center" prop="khSumV" />
<el-table-column label="控货占比" align="center" prop="khSumZb" /> <el-table-column label="控货占比" align="center" prop="khSumZb" />
<el-table-column label="是否首次成交" align="center" prop="isFirst" /> <!--2024-05-06和张工确认这几个参数无取数逻辑,暂时隐藏-->
<el-table-column label="首次成交时间" align="center" prop="firstDate"> <el-table-column
label="是否首次成交"
v-show="false"
align="center"
prop="isFirst"
/>
<el-table-column
label="首次成交时间"
v-show="false"
align="center"
prop="firstDate"
>
<template slot-scope="scope"> <template slot-scope="scope">
<span>{{ parseTime(scope.row.firstDate) }}</span> <span>{{ parseTime(scope.row.firstDate) }}</span>
</template> </template>
</el-table-column> </el-table-column>
<!--2024-05-06和张工确认这几个参数无取数逻辑,暂时隐藏-->
<el-table-column label="提货率" align="center" prop="thL" /> <el-table-column label="提货率" align="center" prop="thL" />
<el-table-column label="客户业绩类型" align="center" prop="cusYjType" /> <el-table-column label="客户业绩类型" align="center" prop="cusYjType" />
<el-table-column label="客户来源" align="center" prop="sourcename" /> <el-table-column label="客户来源" align="center" prop="sourcename" />
...@@ -367,7 +379,11 @@ import Treeselect from "@riophae/vue-treeselect"; ...@@ -367,7 +379,11 @@ import Treeselect from "@riophae/vue-treeselect";
//自定义目录数样式 //自定义目录数样式
import "@/assets/styles/vue-treeselect.css"; import "@/assets/styles/vue-treeselect.css";
import { listSimpleDepts } from "@/api/system/dept"; import { listSimpleDepts } from "@/api/system/dept";
import { getListPage, exportExcel } from "@/api/report/customeranalysis"; import {
getListPage,
exportExcel,
exportExcel2,
} from "@/api/report/customeranalysis";
import { import {
getCurUserPermission, getCurUserPermission,
getDeptChild, getDeptChild,
...@@ -517,50 +533,20 @@ export default { ...@@ -517,50 +533,20 @@ export default {
getCountryListAll().then((r) => { getCountryListAll().then((r) => {
this.countryList = r.data; this.countryList = r.data;
}); });
this.doLoadData();
//获取当前用户报表权限 },
getCurUserPermission().then((response) => { watch: {
//复制对象 $route(to) {
Object.assign(this.objEcwReportPermission, response.data); //lanbm 2024-05-06 解决重新进入参数不刷新的问题
//this.objEcwReportPermission = response.data; if (this.$route.name == "客户分析") {
if (this.objEcwReportPermission.permissionFw == 1) { this.doLoadData();
//只能看自己的,不能选择部门和客户经理
this.showCustomsManage = false;
this.showDept = false;
}
//获取页面传参
let sSalesmanid = this.$route.query.salesmanid;
let sDeptid = this.$route.query.deptid;
let s = this.$route.query.sDate;
let e = this.$route.query.eDate;
let bd = this.$route.query.duibiYear;
//客户编号
let number = this.$route.query.number;
if (sSalesmanid != undefined && sSalesmanid != null) {
this.queryParams.salesmanid = parseInt(sSalesmanid);
}
if (sDeptid != undefined && sDeptid != null) {
this.queryParams.deptid = parseInt(sDeptid);
}
if (s != undefined && s != null) {
this.queryParams.sdate = s + "-01";
}
if (e != undefined && s != null) {
let lastDay = getLastDay(e + "-01");
this.queryParams.edate = e + "-" + lastDay;
}
if (bd != undefined && bd != null) {
this.queryParams.duibiYear = bd;
}
if (number != undefined && number != null) {
this.queryParams.searchtype = "eq";
this.queryParams.name = number;
} }
this.getTreeselect(); },
this.getList(); },
}); computed: {
//这几个函数的执行顺序
//created ------> computed ------> mounted ------> watch
}, },
computed: {},
methods: { methods: {
/** 查询列表 */ /** 查询列表 */
getList() { getList() {
...@@ -582,6 +568,49 @@ export default { ...@@ -582,6 +568,49 @@ export default {
this.loading = false; this.loading = false;
}); });
}, },
doLoadData() {
//获取当前用户报表权限
getCurUserPermission().then((response) => {
//复制对象
Object.assign(this.objEcwReportPermission, response.data);
//this.objEcwReportPermission = response.data;
if (this.objEcwReportPermission.permissionFw == 1) {
//只能看自己的,不能选择部门和客户经理
this.showCustomsManage = false;
this.showDept = false;
}
//获取页面传参
let sSalesmanid = this.$route.query.salesmanid;
let sDeptid = this.$route.query.deptid;
let s = this.$route.query.sDate;
let e = this.$route.query.eDate;
let bd = this.$route.query.duibiYear;
//客户编号
let number = this.$route.query.number;
if (sSalesmanid != undefined && sSalesmanid != null) {
this.queryParams.salesmanid = parseInt(sSalesmanid);
}
if (sDeptid != undefined && sDeptid != null) {
this.queryParams.deptid = parseInt(sDeptid);
}
if (s != undefined && s != null) {
this.queryParams.sdate = s + "-01";
}
if (e != undefined && s != null) {
let lastDay = getLastDay(e + "-01");
this.queryParams.edate = e + "-" + lastDay;
}
if (bd != undefined && bd != null) {
this.queryParams.duibiYear = bd;
}
if (number != undefined && number != null) {
this.queryParams.searchtype = "eq";
this.queryParams.name = number;
}
this.getTreeselect();
this.getList();
});
},
isChinese() { isChinese() {
//基础函数,判断系统显示语言是中文还是英文 //基础函数,判断系统显示语言是中文还是英文
return this.$i18n.locale === "zh_CN"; return this.$i18n.locale === "zh_CN";
...@@ -688,7 +717,7 @@ export default { ...@@ -688,7 +717,7 @@ export default {
.confirm("是否确认导出所有数据项?") .confirm("是否确认导出所有数据项?")
.then(() => { .then(() => {
this.exportLoading = true; this.exportLoading = true;
return exportExcel(this.queryParams); return exportExcel2(this.queryParams);
}) })
.then((response) => { .then((response) => {
//放入后台队列需要注释此行代码 //放入后台队列需要注释此行代码
......
...@@ -68,10 +68,9 @@ ...@@ -68,10 +68,9 @@
v-model="queryParams.fhNumber" v-model="queryParams.fhNumber"
placeholder="请输入发货人编号" placeholder="请输入发货人编号"
clearable clearable
@keyup.enter.native="handleQuery"
/> />
</el-form-item> </el-form-item>
<el-form-item label="收货人编号" prop="delFlag"> <el-form-item label="收货人编号" prop="shNumber">
<el-select <el-select
v-model="queryParams.SearchType4" v-model="queryParams.SearchType4"
clearable clearable
...@@ -86,18 +85,29 @@ ...@@ -86,18 +85,29 @@
</el-select> </el-select>
<el-input <el-input
style="width: 200px" style="width: 200px"
v-model="queryParams.fhNumber" v-model="queryParams.shNumber"
placeholder="请输入收货人编号" placeholder="请输入收货人编号"
clearable clearable
@keyup.enter.native="handleQuery"
/> />
</el-form-item> </el-form-item>
<el-form-item label="唛头" prop="remark"> <el-form-item label="唛头" prop="remark">
<el-select
v-model="queryParams.SearchType5"
clearable
style="width: 100px"
>
<el-option
v-for="dict in SearchType"
:key="dict.value"
:label="dict.label"
:value="dict.value"
/>
</el-select>
<el-input <el-input
v-model="queryParams.remark" v-model="queryParams.marks"
placeholder="请输入唛头" placeholder="请输入唛头"
style="width: 200px"
clearable clearable
@keyup.enter.native="handleQuery"
/> />
</el-form-item> </el-form-item>
<el-form-item label="客户经理" prop="salesmanId"> <el-form-item label="客户经理" prop="salesmanId">
...@@ -190,13 +200,11 @@ ...@@ -190,13 +200,11 @@
></el-option> ></el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item :label="$t('控货')" prop="isCargoControl"> <el-form-item :label="$t('是否控货')" prop="isCargoControl">
<dict-selector <el-select v-model="queryParams.isCargoControl" clearable>
v-model="queryParams.isCargoControl" <el-option label="是" value="1"></el-option>
:type="DICT_TYPE.INFRA_BOOLEAN_STRING" <el-option label="否" value="0"></el-option>
fomatter="bool" </el-select>
clearable
/>
</el-form-item> </el-form-item>
<el-form-item label="重泡类型" prop="remark"> <el-form-item label="重泡类型" prop="remark">
<el-select v-model="queryParams.zpType" clearable> <el-select v-model="queryParams.zpType" clearable>
...@@ -235,21 +243,30 @@ ...@@ -235,21 +243,30 @@
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item label="数据筛选" prop="remark"> <el-form-item label="数据筛选" prop="remark">
<el-select v-model="queryParams.dataSearch1" clearable style="width: 150px"> <el-select
v-model="queryParams.dataSearch1"
clearable
style="width: 150px"
>
<el-option label="入仓箱数" value="1"></el-option> <el-option label="入仓箱数" value="1"></el-option>
<el-option label="入仓体积" value="2"></el-option> <el-option label="入仓体积" value="2"></el-option>
<el-option label="入仓重量" value="3"></el-option> <el-option label="入仓重量" value="3"></el-option>
<el-option label="重/泡标准" value="3"></el-option> <el-option label="重/泡标准" value="3"></el-option>
<el-option label="提货率" value="4"></el-option> <el-option label="提货率" value="4"></el-option>
</el-select> </el-select>
<el-select v-model="queryParams.dataSearch2" clearable style="width: 150px"> <el-select
v-model="queryParams.dataSearch2"
clearable
style="width: 150px"
>
<el-option label="大于等于" value="1"></el-option> <el-option label="大于等于" value="1"></el-option>
<el-option label="等于" value="2"></el-option> <el-option label="等于" value="2"></el-option>
<el-option label="小于等于" value="3"></el-option> <el-option label="小于等于" value="3"></el-option>
</el-select> </el-select>
<el-input style="width: 100px" <el-input
style="width: 100px"
v-model="queryParams.dataSearch3" v-model="queryParams.dataSearch3"
placeholder="请输入数值" placeholder="请输入数值"
clearable clearable
@keyup.enter.native="handleQuery" @keyup.enter.native="handleQuery"
/> />
...@@ -292,21 +309,64 @@ ...@@ -292,21 +309,64 @@
> >
</el-form-item> </el-form-item>
</el-form> </el-form>
<el-row :gutter="32"> <el-row>
<el-col :xs="24" :sm="24" :lg="8"> <el-col :span="24" class="card-box">
<div class="chart-wrapper">总箱数 总方数 总重量 总V值</div> <el-card>
</el-col> <div class="el-table el-table--enable-row-hover el-table--medium">
</el-row> <table cellspacing="0" style="width: 100%">
<el-row :gutter="32"> <tbody>
<el-col :xs="24" :sm="24" :lg="8"> <tr>
<div class="chart-wrapper">新客户 总箱数 总方数 总重量 总V值</div> <td><div class="cell"></div></td>
</el-col> <td>
</el-row> <div class="cell">总箱数:{{ StatisticalSummary.sumBox }}</div>
<el-row :gutter="32"> </td>
<el-col :xs="24" :sm="24" :lg="8"> <td>
<div class="chart-wrapper">旧客户 总箱数 总方数 总重量 总V值</div> <div class="cell">总方数:{{ StatisticalSummary.sumM3 }}</div>
</td>
<td>
<div class="cell">总重量:{{ StatisticalSummary.sumKG }}</div>
</td>
<td>
<div class="cell">总V值:{{ StatisticalSummary.sumV }}</div>
</td>
</tr>
<tr>
<td><div class="cell">新客户</div></td>
<td>
<div class="cell">总箱数:{{ StatisticalSummary.sumBoxNew }}</div>
</td>
<td>
<div class="cell">总方数:{{ StatisticalSummary.sumM3New }}</div>
</td>
<td>
<div class="cell">总重量:{{ StatisticalSummary.sumKGNew }}</div>
</td>
<td>
<div class="cell">总V值:{{ StatisticalSummary.sumVNew }}</div>
</td>
</tr>
<tr>
<td><div class="cell">旧客户</div></td>
<td>
<div class="cell">总箱数:{{ StatisticalSummary.sumBoxOld }}</div>
</td>
<td>
<div class="cell">总方数:{{ StatisticalSummary.sumM3Old }}</div>
</td>
<td>
<div class="cell">总重量:{{ StatisticalSummary.sumKGOld }}</div>
</td>
<td>
<div class="cell">总V值:{{ StatisticalSummary.sumVOld }}</div>
</td>
</tr>
</tbody>
</table>
</div>
</el-card>
</el-col> </el-col>
</el-row> </el-row>
<!-- 列表 --> <!-- 列表 -->
<el-table v-loading="loading" :data="list"> <el-table v-loading="loading" :data="list">
<el-table-column label="排名" align="center" prop="px" /> <el-table-column label="排名" align="center" prop="px" />
...@@ -383,7 +443,7 @@ ...@@ -383,7 +443,7 @@
<el-table-column label="入仓箱数" align="center" prop="sumquantity" /> <el-table-column label="入仓箱数" align="center" prop="sumquantity" />
<el-table-column label="体积" align="center" prop="sumvolume" /> <el-table-column label="体积" align="center" prop="sumvolume" />
<el-table-column label="重量" align="center" prop="sumweight" /> <el-table-column label="重量" align="center" prop="sumweight" />
<el-table-column label="控货" align="center" prop="iscargocontrol" /> <el-table-column label="是否控货" align="center" prop="iscargocontrol" />
<el-table-column label="重货/泡货" align="center" prop="ordertypeShow" /> <el-table-column label="重货/泡货" align="center" prop="ordertypeShow" />
<el-table-column label="重货/泡货标准" align="center" prop="zpUnitShow" /> <el-table-column label="重货/泡货标准" align="center" prop="zpUnitShow" />
<el-table-column label="付款方" align="center" prop="draweeName" /> <el-table-column label="付款方" align="center" prop="draweeName" />
...@@ -421,7 +481,7 @@ import { getCountryListAll } from "@/api/ecw/country"; ...@@ -421,7 +481,7 @@ import { getCountryListAll } from "@/api/ecw/country";
import Treeselect from "@riophae/vue-treeselect"; import Treeselect from "@riophae/vue-treeselect";
import "@/assets/styles/vue-treeselect.css"; import "@/assets/styles/vue-treeselect.css";
import { getWarehouseList } from "@/api/ecw/warehouse"; import { getWarehouseList } from "@/api/ecw/warehouse";
import { getListPage, exportExcel } from "@/api/report/salesanalysis"; import { getListPage, exportExcel,getStatisticalSummary } from "@/api/report/salesanalysis";
import { getCurUserPermission } from "@/api/report/EcwReportPermission"; import { getCurUserPermission } from "@/api/report/EcwReportPermission";
import { getAllChannelList, getChannelList } from "@/api/ecw/channel"; import { getAllChannelList, getChannelList } from "@/api/ecw/channel";
import { listSimpleDepts } from "@/api/system/dept"; import { listSimpleDepts } from "@/api/system/dept";
...@@ -464,19 +524,20 @@ export default { ...@@ -464,19 +524,20 @@ export default {
queryParams: { queryParams: {
pageNo: 1, pageNo: 1,
pageSize: 10, pageSize: 10,
SearchType3: undefined, SearchType3: "eq",
fhNumber: undefined, //发货客户编号 fhNumber: undefined, //发货客户编号
SearchType3: undefined, SearchType4: "eq",
shNumber: undefined, //收货客户编号 shNumber: undefined, //收货客户编号
startWarehouseId: undefined, //始发仓 startWarehouseId: undefined, //始发仓
muDiGuo: undefined, //目的国 muDiGuo: undefined, //目的国
muDiShi: undefined, //目的城市 muDiShi: undefined, //目的城市
dstwarehousename: undefined, //目的仓 dstwarehousename: undefined, //目的仓
transportId: undefined, //运输方式 transportId: undefined, //运输方式
SearchType1: undefined, //订单编号查询类型 SearchType1: "eq", //订单编号查询类型
orderNo: undefined, //订单编号 orderNo: undefined, //订单编号
SearchType2: undefined, //提单号的查询类别 SearchType2: "eq", //提单号的查询类别
tidanNo: undefined, //提单号 tidanNo: undefined, //提单号
SearchType5: "in",
marks: undefined, //唛头 marks: undefined, //唛头
status: undefined, //订单状态 status: undefined, //订单状态
salesmanId: undefined, //客户经理 salesmanId: undefined, //客户经理
...@@ -488,9 +549,9 @@ export default { ...@@ -488,9 +549,9 @@ export default {
dateSearch1: undefined, //时间筛选类型 dateSearch1: undefined, //时间筛选类型
sdate1: undefined, //开始时间 sdate1: undefined, //开始时间
edate2: undefined, //结束时间 edate2: undefined, //结束时间
dataSearch1:undefined,//数据类型筛选 dataSearch1: undefined, //数据类型筛选
dataSearch2:undefined,//比较符号设置 dataSearch2: undefined, //比较符号设置
dataSearch3:undefined,//数据值 dataSearch3: undefined, //数据值
}, },
channelList: [], channelList: [],
countryList: [], countryList: [],
...@@ -504,6 +565,20 @@ export default { ...@@ -504,6 +565,20 @@ export default {
DeptEx: { id: undefined, name: undefined, parentId: undefined }, DeptEx: { id: undefined, name: undefined, parentId: undefined },
showWarehouseInItemId: undefined, showWarehouseInItemId: undefined,
type: 1, type: 1,
StatisticalSummary:{
sumBox:0,
sumM3:0,
sumKG:0,
sumV:0,
sumBoxNew:0,
sumM3New:0,
sumKGNew:0,
sumVNew:0,
sumBoxOld:0,
sumM3Old:0,
sumKGOld:0,
sumVOld:0,
}
}; };
}, },
created() { created() {
...@@ -511,9 +586,7 @@ export default { ...@@ -511,9 +586,7 @@ export default {
getCountryListAll().then((r) => { getCountryListAll().then((r) => {
this.countryList = r.data; this.countryList = r.data;
}); });
getAllChannelList().then((res) => (this.channelList = res.data)); getAllChannelList().then((res) => (this.channelList = res.data));
getWarehouseList().then((res) => (this.warehouseList = res.data)); getWarehouseList().then((res) => (this.warehouseList = res.data));
this.loading = false; this.loading = false;
//获取当前用户报表权限 //获取当前用户报表权限
...@@ -555,6 +628,12 @@ export default { ...@@ -555,6 +628,12 @@ export default {
this.total = response.data.total; this.total = response.data.total;
this.loading = false; this.loading = false;
}); });
//获取统计数据
getStatisticalSummary(params).then((response) => {
this.StatisticalSummary = response.data;
});
}, },
/** 表单重置 */ /** 表单重置 */
...@@ -591,14 +670,17 @@ export default { ...@@ -591,14 +670,17 @@ export default {
params.pageSize = undefined; params.pageSize = undefined;
// 执行导出 // 执行导出
this.$modal this.$modal
.confirm("是否确认导出所数据?") .confirm("是否确认导出所数据?")
.then(() => { .then(() => {
this.exportLoading = true; this.exportLoading = true;
return exportExcel(params); return exportExcel(params);
}) })
.then((response) => { .then((response) => {
this.$download.excel(response, "销售分析数据报表.xls"); //this.$download.excel(response, "销售分析数据报表.xls");
this.exportLoading = false; this.exportLoading = false;
this.$message.success(
this.$t("已加入导出队列,请稍后在下载日志中下载")
);
}) })
.catch(() => {}); .catch(() => {});
}, },
......
...@@ -59,6 +59,17 @@ ...@@ -59,6 +59,17 @@
{{ $t("导出") }}</el-button {{ $t("导出") }}</el-button
> >
</el-col> </el-col>
<el-col :span="1.5">
<el-button
type="primary"
plain
icon="el-icon-plus" v-show="false"
size="mini"
@click="TestFun"
>
{{ $t("测试功能") }}</el-button
>
</el-col>
<right-toolbar <right-toolbar
:showSearch.sync="showSearch" :showSearch.sync="showSearch"
@queryTable="getList" @queryTable="getList"
...@@ -149,6 +160,7 @@ import { ...@@ -149,6 +160,7 @@ import {
getModel, getModel,
getPageList, getPageList,
exportExcel, exportExcel,
test,
} from "@/api/report/vz"; } from "@/api/report/vz";
import Treeselect from "@riophae/vue-treeselect"; import Treeselect from "@riophae/vue-treeselect";
import "@/assets/styles/vue-treeselect.css"; import "@/assets/styles/vue-treeselect.css";
...@@ -305,7 +317,7 @@ export default { ...@@ -305,7 +317,7 @@ export default {
if (!valid) { if (!valid) {
return; return;
} }
// 修改的提交 // 修改的提交
if (this.form.id != null) { if (this.form.id != null) {
update(this.form).then((response) => { update(this.form).then((response) => {
...@@ -337,6 +349,11 @@ export default { ...@@ -337,6 +349,11 @@ export default {
}) })
.catch(() => {}); .catch(() => {});
}, },
TestFun() {
test().then((response) => {
this.$modal.msgSuccess("测试发送");
});
},
/** 导出按钮操作 */ /** 导出按钮操作 */
handleExport() { handleExport() {
// 处理查询参数 // 处理查询参数
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment