瀏覽代碼

调整代码

xz
zhoujie 9 月之前
父節點
當前提交
e0ff47cfcc

+ 4
- 7
.env.development 查看文件

# VITE_APP_BASE_URL = 'https://qtzl.etcjz.cn/dev/' #试运行环境/青云环境/生成环境地址 # VITE_APP_BASE_URL = 'https://qtzl.etcjz.cn/dev/' #试运行环境/青云环境/生成环境地址
# VITE_APP_BASE_URL = 'http://100.65.11.2:8086/nDev/' #线上地址 nDev # VITE_APP_BASE_URL = 'http://100.65.11.2:8086/nDev/' #线上地址 nDev
# VITE_APP_BASE_URL = 'http://100.64.2.104:8087/nDev/' #线上地址 nDev # VITE_APP_BASE_URL = 'http://100.64.2.104:8087/nDev/' #线上地址 nDev

VITE_APP_BASE_URL = 'http://100.65.11.2:8086/ndev/' #线上地址 nDev

#VITE_APP_BASE_URL = 'http://100.65.11.2:8086/ndev/' #线上地址 nDev
VITE_APP_BASE_URL = 'http://100.65.11.2:8086/prod/' #线上地址 nDev
# VITE_APP_BASE_URL = 'http://100.64.2.104:8086/html/' # VITE_APP_BASE_URL = 'http://100.64.2.104:8086/html/'
# VITE_APP_BASE_URL = 'http://100.64.2.111:50001/' #宇轩给测试环境 # VITE_APP_BASE_URL = 'http://100.64.2.111:50001/' #宇轩给测试环境
# VITE_APP_BASE_URL = 'https://192.168.124.43:50001/' #宇轩服务器 # VITE_APP_BASE_URL = 'https://192.168.124.43:50001/' #宇轩服务器
# VITE_APP_BASE_URL = 'http://192.168.124.56:50001/' #试运行环境/青云环境/生成环境地址 # VITE_APP_BASE_URL = 'http://192.168.124.56:50001/' #试运行环境/青云环境/生成环境地址


VITE_APP_BASE_URL_N = 'http://100.65.11.2:8086/ndev/' # 新地址 prod
# VITE_APP_BASE_URL_N = 'http://100.65.11.2:8086/prod/' # 新地址 prod
#VITE_APP_BASE_URL_N = 'http://100.65.11.2:8086/ndev/' # 新地址 prod
VITE_APP_BASE_URL_N = 'http://100.65.11.2:8086/prod/' # 新地址 prod
# VITE_APP_BASE_URL_N = 'http://100.64.2.104:8087/nDev/' #线上地址 nDev # VITE_APP_BASE_URL_N = 'http://100.64.2.104:8087/nDev/' #线上地址 nDev
# VITE_APP_BASE_URL_N = 'https://qtzl.etcjz.cn/ndev/' # 新地址 # VITE_APP_BASE_URL_N = 'https://qtzl.etcjz.cn/ndev/' # 新地址
# VITE_APP_BASE_URL_N = 'http://100.65.11.2:8086/nDev/' # 新地址 # VITE_APP_BASE_URL_N = 'http://100.65.11.2:8086/nDev/' # 新地址

+ 4
- 1
src/views/optionalSystem/optionUtils.ts 查看文件

import BaseService from "@/utils/baseService"; import BaseService from "@/utils/baseService";
import moment from "moment"; import moment from "moment";
export const optionExportFn = (api, params, fileName: string = "") => {
export const optionExportFn = (api, params, fileName: string = "",call=()=>{}) => {
BaseService.post(api, params).then((res: any) => { BaseService.post(api, params).then((res: any) => {
call()
if (res && res.statusCode === 0) { if (res && res.statusCode === 0) {
let bizContent = JSON.parse(JSON.parse(res.bizContent).bizContent) let bizContent = JSON.parse(JSON.parse(res.bizContent).bizContent)
// 接口参数返回不一致问题 // 接口参数返回不一致问题
} else { } else {
ElMessage.error("导出失败," + res.message); ElMessage.error("导出失败," + res.message);
} }
}).catch(()=>{
call()
}); });
}; };

+ 15
- 10
src/views/optionalSystem/settlementManagement/dailyAccountsReceivable/index.vue 查看文件

end-placeholder="结束日期" format="YYYY-MM-DD" @change="naturalDayHandle" :clearable="false" /> end-placeholder="结束日期" format="YYYY-MM-DD" @change="naturalDayHandle" :clearable="false" />
</template> </template>
<template #searchCustomButton> <template #searchCustomButton>
<el-button type="warning" icon="Download" @click="download" class="btn">
<el-button type="warning" icon="Download" @click="download" :disabled="disableds" class="btn">
导出付款单 导出付款单
</el-button> </el-button>
</template> </template>
import $storeInitData from '@/store/initData' import $storeInitData from '@/store/initData'
import { optionExportFn } from "../../optionUtils"; import { optionExportFn } from "../../optionUtils";
// 导出手续费台账
function download() {
const params = handleParams();
optionExportFn("IF01001202412091281", {
accountDates: params.accountDates.replace("-", "").split(",").map(Number) }, "商户号分类查询");
}
const route = useRoute() const route = useRoute()
const VEHICLE_COLOR_TYPE = computed(() => { const VEHICLE_COLOR_TYPE = computed(() => {
return $storeinitData.state.dictData['VEHICLE_COLOR_TYPE'] || [] return $storeinitData.state.dictData['VEHICLE_COLOR_TYPE'] || []
}) })
const crudRef = ref() const crudRef = ref()
const searchForm : any = ref({
const disableds = ref(false);
const searchForm: any = ref({
startDate: '', startDate: '',
endDate: '', endDate: '',
}) })
function naturalDayHandle(val) { function naturalDayHandle(val) {
if (val) { if (val) {
searchForm.value.startDate = +moment(val[0]).format("YYYYMMDD"); searchForm.value.startDate = +moment(val[0]).format("YYYYMMDD");
searchForm.value.endDate = +moment(val[1]).format("YYYYMMDD");
searchForm.value.endDate = +moment(val[1]).format("YYYYMMDD");
} }
} }
// 处理请求参数 // 处理请求参数
} }
) )
} }
// 导出付款单
function download() {
const params = handleParams();
disableds.value = true;
optionExportFn("IF01001202412091282", {
startDate: params.startDate,
endDate: params.endDate
}, "付款单", () => {
disableds.value = false;
});
}
function handleCurrentChange(val: number) { function handleCurrentChange(val: number) {
field.value.paging.currentPage = val field.value.paging.currentPage = val
getList() getList()

+ 11
- 3
src/views/optionalSystem/settlementManagement/merchantNumberClassificationStatistics/index.vue 查看文件

<template #searchCustomButton> <template #searchCustomButton>
<el-date-picker style="margin-left: 50px" v-model="searchForm.accountDates" placeholder="请选择手续费月份" type="month" <el-date-picker style="margin-left: 50px" v-model="searchForm.accountDates" placeholder="请选择手续费月份" type="month"
format="YYYY年MM月" value-format="YYYY-MM" :clearable="false" /> format="YYYY年MM月" value-format="YYYY-MM" :clearable="false" />
<el-button type="warning" icon="Download" @click="download" class="btn">
<el-button type="warning" icon="Download" @click="download" :disabled="disableds" class="btn">
导出手续费台账 导出手续费台账
</el-button> </el-button>
</template> </template>
import { useRoute } from "vue-router"; import { useRoute } from "vue-router";
import { optionExportFn } from "../../optionUtils"; import { optionExportFn } from "../../optionUtils";
const route = useRoute(); const route = useRoute();
const disableds = ref(false);
const VEHICLE_COLOR_TYPE = computed(() => { const VEHICLE_COLOR_TYPE = computed(() => {
return $storeinitData.state.dictData["VEHICLE_COLOR_TYPE"] || []; return $storeinitData.state.dictData["VEHICLE_COLOR_TYPE"] || [];
}); });
// 导出手续费台账 // 导出手续费台账
function download() { function download() {
const params = handleParams(); const params = handleParams();
if (!params.accountDates) {
ElMessage.error('请选择手续费月份')
return
}
disableds.value = true;
optionExportFn("IF01001202412091281", { optionExportFn("IF01001202412091281", {
accountDates: params.accountDates.replace("-", "").split(",").map(Number) }, "商户号分类查询");
accountDates: params.accountDates.replace("-", "").split(",").map(Number) }, "比亚迪选装手续费台账",()=>{
disableds.value = false;
});
} }

+ 32
- 7
src/views/optionalSystem/settlementManagement/serviceFeeDetail/index.vue 查看文件

<el-date-picker unlink-panels v-model="value2" type="daterange" range-separator="到" start-placeholder="开始日期" <el-date-picker unlink-panels v-model="value2" type="daterange" range-separator="到" start-placeholder="开始日期"
end-placeholder="结束日期" format="YYYY-MM-DD" @change="refundDateHandle" :clearable="false" /> end-placeholder="结束日期" format="YYYY-MM-DD" @change="refundDateHandle" :clearable="false" />
</template> </template>
<template #searchCustomButton >
<el-date-picker style="margin-left: 50px;" v-model="searchForm.accountDates" placeholder="请选择收入、成本月份" type="month" format="YYYY年MM月"
value-format="YYYY-MM" :clearable="false" />
<el-button type="warning" icon="Download" @click="download" class="btn">
<template #searchCustomButton>
<el-date-picker style="margin-left: 50px;" v-model="searchForm.accountDates" placeholder="请选择收入、成本月份"
type="month" format="YYYY年MM月" value-format="YYYY-MM" :clearable="false" />
<el-button type="warning" icon="Download" @click="download" :disabled="disableds" class="btn">
导出收入、成本统计表 导出收入、成本统计表
</el-button> </el-button>
</template> </template>
import { IsPermission } from '@/router/routerUtil' import { IsPermission } from '@/router/routerUtil'
import { useRoute } from 'vue-router' import { useRoute } from 'vue-router'
import { optionExportFn } from '../../optionUtils' import { optionExportFn } from '../../optionUtils'
import { Console } from 'console'
const route = useRoute() const route = useRoute()


const VEHICLE_COLOR_TYPE = computed(() => { const VEHICLE_COLOR_TYPE = computed(() => {
return $storeinitData.state.dictData['VEHICLE_COLOR_TYPE'] || [] return $storeinitData.state.dictData['VEHICLE_COLOR_TYPE'] || []
}) })
const crudRef = ref() const crudRef = ref()
const disableds = ref(false);
const searchForm = ref<any>({ const searchForm = ref<any>({
plateNo: '', plateNo: '',
outTradeNo: '', outTradeNo: '',
optionExportFn('IF01001202412041280', params, '比亚迪服务费导出') optionExportFn('IF01001202412041280', params, '比亚迪服务费导出')
} }


// 导出手续费台账
// 导出收入、成本统计表
function download() { function download() {
const params = handleParams(); const params = handleParams();
optionExportFn("IF01001202412091284", {
accountDates: params.accountDates.replace("-", "").split(",").map(Number) }, "商户号分类查询");
if (!params.accountDates) {
ElMessage.error('请选择收入、成本月份')
return
}
disableds.value = true;
let parts = params.accountDates.split("-");
optionExportFn("IF01001202412091283", {
businessStartTime: params.accountDates + "-01",
businessEndTime: getLastDayOfMonth(parts[0], parts[1])
}, "收入、成本统计", () => {
disableds.value = false;
});
}
// 辅助函数:获取指定年月最后一天
function getLastDayOfMonth(year, month) {
// 创建一个新的日期对象,设置为下个月的第0天(实际上会回退到上个月的最后一天)
const date = new Date(year, month + 1, 0);
// 格式化日期为 "YYYY-MM-DD"
const lastDay = `${date.getFullYear()}-${date.getMonth() < 10 ? '0' + (date.getMonth() + 1) : date.getMonth() + 1}-${date.getDate() < 10 ? '0' + date.getDate() : date.getDate()}`;
// 但是由于我们只需要年月日中的年月部分加上最后一天,可以简化为:
// 注意:这里我们不需要重新格式化月份,因为月份在创建 date 对象时已经正确处理了
return `${year}-${month < 10 ? '0' + month : month}-${date.getDate()}`;

// 或者更简洁地,只返回年月和天数部分:
// return `${year}-${String(month).padStart(2, '0')}-${String(date.getDate()).padStart(2, '0')}`;
} }
onMounted(() => { onMounted(() => {
getList() getList()

Loading…
取消
儲存