Commit 23dfbb54 authored by 沈翠玲's avatar 沈翠玲

优化

parent dd965c2c
...@@ -8,7 +8,7 @@ import { setupDirectives } from '@/plugins/directives'; ...@@ -8,7 +8,7 @@ import { setupDirectives } from '@/plugins/directives';
import { setupVxeTabele } from './plugins/vxe-table'; import { setupVxeTabele } from './plugins/vxe-table';
import ProTable from '@/components/ProTable/index.vue'; import ProTable from '@/components/ProTable/index.vue';
import { download } from '@/utils/http/index'; import { download } from '@/utils/http/index';
import './styles/element-variables.scss' import './styles/element-variables.scss';
export async function bootstrapInstall() { export async function bootstrapInstall() {
const app = createApp(App); const app = createApp(App);
......
// element-variables.scss // element-variables.scss
@import 'element-plus/theme-chalk/src/index.scss';
@import "element-plus/theme-chalk/src/index.scss"; $--font-size: 13px;
$--font-size: 13px;
\ No newline at end of file
...@@ -155,8 +155,12 @@ ...@@ -155,8 +155,12 @@
<el-form inline :model="form" :rules="rules" label-width="110px" label-position="left"> <el-form inline :model="form" :rules="rules" label-width="110px" label-position="left">
<el-form-item class="w-full" label="通话录音:" prop="code"> <el-form-item class="w-full" label="通话录音:" prop="code">
<el-icon> <el-icon>
<Download v-for="(item, index) in form.voices" :key="index" @click="download(item)" /> <Download
</el-icon> v-for="(item, index) in form.voices"
:key="index"
@click="download(item)"
/>
</el-icon>
<el-upload <el-upload
class="avatar-uploader" class="avatar-uploader"
:action="url" :action="url"
...@@ -165,7 +169,9 @@ ...@@ -165,7 +169,9 @@
:disabled="props.mode !== 'handle'" :disabled="props.mode !== 'handle'"
:auto-upload="true" :auto-upload="true"
> >
<el-button type="primary" plain :icon="Upload" :disabled="props.mode !== 'handle'">上传录音文件</el-button> <el-button type="primary" plain :icon="Upload" :disabled="props.mode !== 'handle'"
>上传录音文件</el-button
>
</el-upload> </el-upload>
<!-- 进度条 --> <!-- 进度条 -->
<!-- <el-progress v-if="progressFlag" :percentage="loadProgress" /> --> <!-- <el-progress v-if="progressFlag" :percentage="loadProgress" /> -->
...@@ -247,7 +253,7 @@ ...@@ -247,7 +253,7 @@
import { computed, inject } from 'vue'; import { computed, inject } from 'vue';
import { reactive, ref } from 'vue'; import { reactive, ref } from 'vue';
import { ElInputNumber, ElMessage } from 'element-plus'; import { ElInputNumber, ElMessage } from 'element-plus';
import { Upload,Download } from '@element-plus/icons-vue'; import { Upload, Download } from '@element-plus/icons-vue';
import { getAppEnvConfig } from '@/utils/env'; import { getAppEnvConfig } from '@/utils/env';
import { saveTrackRecord } from '@/api/property'; import { saveTrackRecord } from '@/api/property';
import { auditAudit } from '@/api/audit'; import { auditAudit } from '@/api/audit';
...@@ -384,15 +390,15 @@ ...@@ -384,15 +390,15 @@
} }
}; };
const handleFileSuccess = (response, file, fileList) => { const handleFileSuccess = (response, file, fileList) => {
if(file.uid) { if (file.uid) {
const item = form.voices.find((v) => v.uid === file.uid); const item = form.voices.find((v) => v.uid === file.uid);
item.url = envs.VITE_GLOB_API_URL_PREFIX + '/sys/static/' + response.message item.url = envs.VITE_GLOB_API_URL_PREFIX + '/sys/static/' + response.message;
} }
}; };
const handleFileSuccess1 = (response, file, fileList) => { const handleFileSuccess1 = (response, file, fileList) => {
if(file.uid) { if (file.uid) {
const item = form.images.find((v) => v.uid === file.uid); const item = form.images.find((v) => v.uid === file.uid);
item.url = envs.VITE_GLOB_API_URL_PREFIX + '/sys/static/' + response.message item.url = envs.VITE_GLOB_API_URL_PREFIX + '/sys/static/' + response.message;
} }
}; };
const handleRemove1 = (uploadFile, uploadFiles) => { const handleRemove1 = (uploadFile, uploadFiles) => {
...@@ -401,20 +407,20 @@ ...@@ -401,20 +407,20 @@
}; };
const handleFileSuccess2 = (response, file, fileList) => { const handleFileSuccess2 = (response, file, fileList) => {
// console.log(response, file); // console.log(response, file);
if(file.uid) { if (file.uid) {
const item = form.notes.find((v) => v.uid === file.uid); const item = form.notes.find((v) => v.uid === file.uid);
item.url = envs.VITE_GLOB_API_URL_PREFIX + '/sys/static/' + response.message item.url = envs.VITE_GLOB_API_URL_PREFIX + '/sys/static/' + response.message;
}; }
}; };
const handleRemove2 = (uploadFile, uploadFiles) => { const handleRemove2 = (uploadFile, uploadFiles) => {
const index = form.notes.findIndex((v) => v.name === uploadFile.name); const index = form.notes.findIndex((v) => v.name === uploadFile.name);
form.notes.splice(index, 1); form.notes.splice(index, 1);
}; };
const handleFileSuccess3 = (response, file, fileList) => { const handleFileSuccess3 = (response, file, fileList) => {
if(file.uid) { if (file.uid) {
const item = form.others.find((v) => v.uid === file.uid); const item = form.others.find((v) => v.uid === file.uid);
item.url = envs.VITE_GLOB_API_URL_PREFIX + '/sys/static/' + response.message item.url = envs.VITE_GLOB_API_URL_PREFIX + '/sys/static/' + response.message;
}; }
}; };
const download = (item) => { const download = (item) => {
const name = item.slice(item.lastIndexOf('/') + 1, item.length); const name = item.slice(item.lastIndexOf('/') + 1, item.length);
...@@ -496,22 +502,22 @@ ...@@ -496,22 +502,22 @@
console.log('formform', form); console.log('formform', form);
}; };
const submitForm = (type) => { const submitForm = (type) => {
let voices = JSON.parse(JSON.stringify(form.voices.map(v => v.url))) let voices = JSON.parse(JSON.stringify(form.voices.map((v) => v.url)));
let images = JSON.parse(JSON.stringify(form.images.map(v => v.url))) let images = JSON.parse(JSON.stringify(form.images.map((v) => v.url)));
let notes = JSON.parse(JSON.stringify(form.notes.map(v => v.url))) let notes = JSON.parse(JSON.stringify(form.notes.map((v) => v.url)));
let others = JSON.parse(JSON.stringify(form.others.map(v => v.url))) let others = JSON.parse(JSON.stringify(form.others.map((v) => v.url)));
voices = voices.map(v => { voices = voices.map((v) => {
return v.replace(envs.VITE_GLOB_API_URL_PREFIX + '/sys/static/', '') return v.replace(envs.VITE_GLOB_API_URL_PREFIX + '/sys/static/', '');
}) });
images = images.map(v => { images = images.map((v) => {
return v.replace(envs.VITE_GLOB_API_URL_PREFIX + '/sys/static/', '') return v.replace(envs.VITE_GLOB_API_URL_PREFIX + '/sys/static/', '');
}) });
notes = notes.map(v => { notes = notes.map((v) => {
return v.replace(envs.VITE_GLOB_API_URL_PREFIX + '/sys/static/', '') return v.replace(envs.VITE_GLOB_API_URL_PREFIX + '/sys/static/', '');
}) });
others = others.map(v => { others = others.map((v) => {
return v.replace(envs.VITE_GLOB_API_URL_PREFIX + '/sys/static/', '') return v.replace(envs.VITE_GLOB_API_URL_PREFIX + '/sys/static/', '');
}) });
saveTrackRecord({ saveTrackRecord({
loans: tabledata.value, loans: tabledata.value,
id: currentInfo.value.id, id: currentInfo.value.id,
......
...@@ -330,7 +330,12 @@ ...@@ -330,7 +330,12 @@
field: 'code', field: 'code',
title: '操作', title: '操作',
width: 80, width: 80,
visible: activeName.value === 'audit' || activeName.value === 'complete' || activeName.value === 'rejected' ? true : false, visible:
activeName.value === 'audit' ||
activeName.value === 'complete' ||
activeName.value === 'rejected'
? true
: false,
slots: { slots: {
default: ({ row, rowIndex }) => { default: ({ row, rowIndex }) => {
if (activeName.value === 'audit' || activeName.value === 'rejected') { if (activeName.value === 'audit' || activeName.value === 'rejected') {
......
...@@ -240,9 +240,9 @@ ...@@ -240,9 +240,9 @@
}; };
const openModal = (info, detail, type) => { const openModal = (info, detail, type) => {
showModal.value = true; showModal.value = true;
form.realRepayAmount = '' form.realRepayAmount = '';
form.files = [] form.files = [];
form.realRepayTime = dayjs().format('YYYY-MM-DD HH:mm:ss') form.realRepayTime = dayjs().format('YYYY-MM-DD HH:mm:ss');
currentInfo.value = info; currentInfo.value = info;
console.log('currentInfo', currentInfo.value); console.log('currentInfo', currentInfo.value);
currentDetail.value = detail; currentDetail.value = detail;
...@@ -282,7 +282,7 @@ ...@@ -282,7 +282,7 @@
flowStatus: 'pending', flowStatus: 'pending',
repayStatus: 'over', repayStatus: 'over',
status: 'enable', status: 'enable',
} };
if (currentType.value === '分期还款') { if (currentType.value === '分期还款') {
param['stages'] = { param['stages'] = {
borrower: currentInfo.value.borrower, borrower: currentInfo.value.borrower,
...@@ -293,11 +293,13 @@ ...@@ -293,11 +293,13 @@
firstApplyDate: currentDetail.value.firstApplyDate, firstApplyDate: currentDetail.value.firstApplyDate,
effectiveTime: currentDetail.value.effectiveTime, effectiveTime: currentDetail.value.effectiveTime,
loans: currentDetail.value.loans, loans: currentDetail.value.loans,
flowStatus: 'pending' flowStatus: 'pending',
} };
const item = currentDetail.value.byStagesRecords.find(v=>currentInfo.value.period === v.period) const item = currentDetail.value.byStagesRecords.find(
item['repayStatus'] = 'over' (v) => currentInfo.value.period === v.period
param['stages']['byStagesRecords'] = currentDetail.value.byStagesRecords );
item['repayStatus'] = 'over';
param['stages']['byStagesRecords'] = currentDetail.value.byStagesRecords;
} }
saveRepayRecord(param).then((res) => { saveRepayRecord(param).then((res) => {
console.log('res', res); console.log('res', res);
......
...@@ -101,7 +101,12 @@ ...@@ -101,7 +101,12 @@
</el-form> </el-form>
</div> </div>
<div class="w-3/5"> <div class="w-3/5">
<ProTable :config="splitconfig" :data="splitdata" :showPagination="false" :showToolBar="false"> <ProTable
:config="splitconfig"
:data="splitdata"
:showPagination="false"
:showToolBar="false"
>
<template #table_top> <template #table_top>
<div class="flex justify-end"> <div class="flex justify-end">
<el-button type="primary" @click="editOrConfirm" class="mr-1 my-2">{{ <el-button type="primary" @click="editOrConfirm" class="mr-1 my-2">{{
......
...@@ -17,7 +17,13 @@ ...@@ -17,7 +17,13 @@
</el-col> </el-col>
<el-col :span="24"> <el-col :span="24">
<el-form-item class="w-full" label="所属区域" prop="orgName"> <el-form-item class="w-full" label="所属区域" prop="orgName">
<el-cascader v-model="form.arealist" class="w-full" :checkStrictly="true" :options="citydata" clearable /> <el-cascader
v-model="form.arealist"
class="w-full"
:checkStrictly="true"
:options="citydata"
clearable
/>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="24"> <el-col :span="24">
......
...@@ -41,7 +41,7 @@ ...@@ -41,7 +41,7 @@
enum: citydata, enum: citydata,
title: '所属区域', title: '所属区域',
fieldNames: { label: 'label', value: 'value' }, fieldNames: { label: 'label', value: 'value' },
search: { el: 'cascader', props: { clearable: true, checkStrictly: true} }, search: { el: 'cascader', props: { clearable: true, checkStrictly: true } },
slots: { slots: {
default: ({ row }) => { default: ({ row }) => {
return ( return (
......
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