feat: 更新业务需求
This commit is contained in:
@@ -266,4 +266,8 @@ export interface orderChargeDetailForm extends BaseEntity {
|
|||||||
* 收费状态
|
* 收费状态
|
||||||
*/
|
*/
|
||||||
chargeStatus?: string | number;
|
chargeStatus?: string | number;
|
||||||
|
/**
|
||||||
|
* 租赁单位
|
||||||
|
*/
|
||||||
|
unitName?: string;
|
||||||
}
|
}
|
||||||
|
@@ -86,6 +86,10 @@ export interface RentalOrderVO {
|
|||||||
*/
|
*/
|
||||||
signTime: string;
|
signTime: string;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 单位名称
|
||||||
|
*/
|
||||||
|
unitName: string;
|
||||||
}
|
}
|
||||||
|
|
||||||
export interface RentalOrderForm extends BaseEntity {
|
export interface RentalOrderForm extends BaseEntity {
|
||||||
@@ -173,7 +177,6 @@ export interface RentalOrderForm extends BaseEntity {
|
|||||||
* 签署时间
|
* 签署时间
|
||||||
*/
|
*/
|
||||||
signTime?: string;
|
signTime?: string;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
export interface RentalOrderQuery extends PageQuery {
|
export interface RentalOrderQuery extends PageQuery {
|
||||||
|
@@ -159,11 +159,11 @@ export const modalSchema: FormSchemaGetter = () => [
|
|||||||
},
|
},
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: '手机缴费',
|
label: '付费方式',
|
||||||
fieldName: 'isMobilePay',
|
fieldName: 'paymentMode',
|
||||||
component: 'Select',
|
component: 'Select',
|
||||||
componentProps: {
|
componentProps: {
|
||||||
options: getDictOptions('pro_mobile_payment'),
|
options: getDictOptions('wy_fffs'),
|
||||||
},
|
},
|
||||||
rules: 'selectRequired',
|
rules: 'selectRequired',
|
||||||
},
|
},
|
||||||
|
@@ -1,17 +1,18 @@
|
|||||||
import type { FormSchemaGetter } from '#/adapter/form';
|
import type { FormSchemaGetter } from '#/adapter/form';
|
||||||
import type { VxeGridProps } from '#/adapter/vxe-table';
|
import type { VxeGridProps } from '#/adapter/vxe-table';
|
||||||
import {getDictOptions} from "#/utils/dict";
|
import { getDictOptions } from '#/utils/dict';
|
||||||
import {renderDict} from "#/utils/render";
|
import { renderDict } from '#/utils/render';
|
||||||
import {costItemSettingList} from "#/api/property/costManagement/costItemSetting";
|
import { costItemSettingList } from '#/api/property/costManagement/costItemSetting';
|
||||||
import { h } from 'vue';
|
import { h } from 'vue';
|
||||||
|
import { resident_unitList } from '#/api/property/resident/unit';
|
||||||
|
|
||||||
export const querySchema: FormSchemaGetter = () => [
|
export const querySchema: FormSchemaGetter = () => [
|
||||||
{
|
{
|
||||||
component: 'ApiSelect',
|
component: 'ApiSelect',
|
||||||
componentProps: {
|
componentProps: {
|
||||||
api: async () => {
|
api: async () => {
|
||||||
return (await costItemSettingList({pageSize: 1000, pageNum: 1}))?.rows
|
return (await costItemSettingList({ pageSize: 1000, pageNum: 1 }))
|
||||||
|
?.rows;
|
||||||
},
|
},
|
||||||
afterFetch: (data: { chargeItem: string; id: string }[]) => {
|
afterFetch: (data: { chargeItem: string; id: string }[]) => {
|
||||||
return data.map((item: any) => ({
|
return data.map((item: any) => ({
|
||||||
@@ -28,9 +29,26 @@ export const querySchema: FormSchemaGetter = () => [
|
|||||||
fieldName: 'chargeStatus',
|
fieldName: 'chargeStatus',
|
||||||
label: '缴费状态',
|
label: '缴费状态',
|
||||||
componentProps: {
|
componentProps: {
|
||||||
options: getDictOptions('wy_fyshzt')
|
options: getDictOptions('wy_fyshzt'),
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
component: 'ApiSelect',
|
||||||
|
componentProps: {
|
||||||
|
api: async () => {
|
||||||
|
const rows = await resident_unitList({
|
||||||
|
pageSize: 1000000000,
|
||||||
|
pageNum: 1,
|
||||||
|
});
|
||||||
|
return rows;
|
||||||
|
},
|
||||||
|
resultField: 'rows',
|
||||||
|
labelField: 'name',
|
||||||
|
valueField: 'id',
|
||||||
|
},
|
||||||
|
fieldName: 'residentUnitId',
|
||||||
|
label: '单位',
|
||||||
|
},
|
||||||
];
|
];
|
||||||
export const columns: VxeGridProps['columns'] = [
|
export const columns: VxeGridProps['columns'] = [
|
||||||
{ type: 'checkbox', width: 60 },
|
{ type: 'checkbox', width: 60 },
|
||||||
@@ -41,7 +59,7 @@ export const columns: VxeGridProps['columns'] = [
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '收费项目',
|
title: '收费项目',
|
||||||
field: 'costItemsId',
|
field: 'chargeItemText',
|
||||||
width: 150,
|
width: 150,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@@ -53,11 +71,13 @@ export const columns: VxeGridProps['columns'] = [
|
|||||||
title: '计费开始时间',
|
title: '计费开始时间',
|
||||||
field: 'startTime',
|
field: 'startTime',
|
||||||
width: 150,
|
width: 150,
|
||||||
|
slots: { default: 'startTime' },
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '计费结束时间',
|
title: '计费结束时间',
|
||||||
field: 'endTime',
|
field: 'endTime',
|
||||||
width: 150,
|
width: 150,
|
||||||
|
slots: { default: 'endTime' },
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '缴费状态',
|
title: '缴费状态',
|
||||||
@@ -65,9 +85,9 @@ export const columns: VxeGridProps['columns'] = [
|
|||||||
width: 150,
|
width: 150,
|
||||||
slots: {
|
slots: {
|
||||||
default: ({ row }) => {
|
default: ({ row }) => {
|
||||||
return renderDict(row.chargeStatus, 'wy_fyshzt')
|
return renderDict(row.chargeStatus, 'wy_fyshzt');
|
||||||
}
|
},
|
||||||
}
|
},
|
||||||
},
|
},
|
||||||
// {
|
// {
|
||||||
// title: '状态',
|
// title: '状态',
|
||||||
@@ -107,8 +127,7 @@ export const modalSchema: FormSchemaGetter = () => [
|
|||||||
label: '单位',
|
label: '单位',
|
||||||
fieldName: 'residentUnitId',
|
fieldName: 'residentUnitId',
|
||||||
component: 'Select',
|
component: 'Select',
|
||||||
componentProps: {
|
componentProps: {},
|
||||||
},
|
|
||||||
rules: 'selectRequired',
|
rules: 'selectRequired',
|
||||||
formItemClass: 'col-span-2',
|
formItemClass: 'col-span-2',
|
||||||
},
|
},
|
||||||
@@ -136,16 +155,14 @@ export const modalSchema: FormSchemaGetter = () => [
|
|||||||
label: '业主',
|
label: '业主',
|
||||||
fieldName: 'personId',
|
fieldName: 'personId',
|
||||||
component: 'ApiSelect',
|
component: 'ApiSelect',
|
||||||
componentProps: {
|
componentProps: {},
|
||||||
},
|
|
||||||
rules: 'selectRequired',
|
rules: 'selectRequired',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: '费用类型',
|
label: '费用类型',
|
||||||
fieldName: 'costType',
|
fieldName: 'costType',
|
||||||
component: 'Select',
|
component: 'Select',
|
||||||
componentProps: {
|
componentProps: {},
|
||||||
},
|
|
||||||
rules: 'selectRequired',
|
rules: 'selectRequired',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@@ -201,7 +218,7 @@ export const modalSchemaUpdate: FormSchemaGetter = () => [
|
|||||||
fieldName: 'payType',
|
fieldName: 'payType',
|
||||||
component: 'Select',
|
component: 'Select',
|
||||||
componentProps: {
|
componentProps: {
|
||||||
options:getDictOptions('wy_zffs')
|
options: getDictOptions('wy_zffs'),
|
||||||
},
|
},
|
||||||
rules: 'selectRequired',
|
rules: 'selectRequired',
|
||||||
},
|
},
|
||||||
@@ -212,12 +229,13 @@ export const modalSchemaUpdate: FormSchemaGetter = () => [
|
|||||||
componentProps: {
|
componentProps: {
|
||||||
min: 1,
|
min: 1,
|
||||||
precision: 0,
|
precision: 0,
|
||||||
placeholder:'请输入缴费周期(月)'
|
placeholder: '请输入缴费周期(月)',
|
||||||
},
|
},
|
||||||
suffix: () => h('span', { style: {fontSize: '0.875rem',fontWeight:500,} }, '月'),
|
suffix: () =>
|
||||||
|
h('span', { style: { fontSize: '0.875rem', fontWeight: 500 } }, '月'),
|
||||||
rules: 'selectRequired',
|
rules: 'selectRequired',
|
||||||
},
|
},
|
||||||
]
|
];
|
||||||
export const modalSchemaRefund: FormSchemaGetter = () => [
|
export const modalSchemaRefund: FormSchemaGetter = () => [
|
||||||
{
|
{
|
||||||
label: '主键',
|
label: '主键',
|
||||||
@@ -233,6 +251,6 @@ export const modalSchemaRefund: FormSchemaGetter = () => [
|
|||||||
fieldName: 'reason',
|
fieldName: 'reason',
|
||||||
component: 'Textarea',
|
component: 'Textarea',
|
||||||
formItemClass: 'col-span-2',
|
formItemClass: 'col-span-2',
|
||||||
rules:'required'
|
rules: 'required',
|
||||||
},
|
},
|
||||||
]
|
];
|
||||||
|
@@ -39,6 +39,11 @@ async function handleOpenChange(open: boolean) {
|
|||||||
}
|
}
|
||||||
modalApi.modalLoading(false);
|
modalApi.modalLoading(false);
|
||||||
}
|
}
|
||||||
|
function formatDate(dateString: string) {
|
||||||
|
if (!dateString) return '';
|
||||||
|
const date = new Date(dateString);
|
||||||
|
return date.toISOString().split('T')[0];
|
||||||
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<template>
|
<template>
|
||||||
@@ -57,7 +62,7 @@ async function handleOpenChange(open: boolean) {
|
|||||||
/>
|
/>
|
||||||
</DescriptionsItem>
|
</DescriptionsItem>
|
||||||
<DescriptionsItem label="计费时间">
|
<DescriptionsItem label="计费时间">
|
||||||
{{ houseChargeDetail.startTime + ' 至 ' + houseChargeDetail.endTime }}
|
{{ formatDate(houseChargeDetail.startTime) + ' 至 ' + formatDate(houseChargeDetail.endTime) }}
|
||||||
</DescriptionsItem>
|
</DescriptionsItem>
|
||||||
<DescriptionsItem label="单位">
|
<DescriptionsItem label="单位">
|
||||||
{{ houseChargeDetail?.residentUnitText }}
|
{{ houseChargeDetail?.residentUnitText }}
|
||||||
|
@@ -125,7 +125,11 @@ function handleMultiDelete() {
|
|||||||
},
|
},
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
function formatDate(dateString: string) {
|
||||||
|
if (!dateString) return '';
|
||||||
|
const date = new Date(dateString);
|
||||||
|
return date.toISOString().split('T')[0];
|
||||||
|
}
|
||||||
function handleDownloadExcel() {
|
function handleDownloadExcel() {
|
||||||
commonDownloadExcel(houseChargeExport, '房屋收费数据', tableApi.formApi.form.values, {
|
commonDownloadExcel(houseChargeExport, '房屋收费数据', tableApi.formApi.form.values, {
|
||||||
fieldMappingTime: formOptions.fieldMappingTime,
|
fieldMappingTime: formOptions.fieldMappingTime,
|
||||||
@@ -161,6 +165,14 @@ function handleDownloadExcel() {
|
|||||||
</a-button>
|
</a-button>
|
||||||
</Space>
|
</Space>
|
||||||
</template>
|
</template>
|
||||||
|
<template #startTime="{row}">
|
||||||
|
{{ formatDate(row.startTime) }}
|
||||||
|
|
||||||
|
</template>
|
||||||
|
<template #endTime="{row}">
|
||||||
|
{{ formatDate(row.endTime) }}
|
||||||
|
|
||||||
|
</template>
|
||||||
<template #action="{ row }">
|
<template #action="{ row }">
|
||||||
<Space>
|
<Space>
|
||||||
<ghost-button
|
<ghost-button
|
||||||
|
@@ -2,7 +2,8 @@ import type { FormSchemaGetter } from '#/adapter/form';
|
|||||||
import type { VxeGridProps } from '#/adapter/vxe-table';
|
import type { VxeGridProps } from '#/adapter/vxe-table';
|
||||||
import { getDictOptions } from '#/utils/dict';
|
import { getDictOptions } from '#/utils/dict';
|
||||||
import { renderDict } from '#/utils/render';
|
import { renderDict } from '#/utils/render';
|
||||||
import {rentalOrderList} from "#/api/property/rentalOrder";
|
import { rentalOrderList } from '#/api/property/rentalOrder';
|
||||||
|
import { resident_unitList } from '#/api/property/resident/unit';
|
||||||
|
|
||||||
export const querySchema: FormSchemaGetter = () => [
|
export const querySchema: FormSchemaGetter = () => [
|
||||||
{
|
{
|
||||||
@@ -70,47 +71,47 @@ export const columns: VxeGridProps['columns'] = [
|
|||||||
return (rowIndex + 1).toString();
|
return (rowIndex + 1).toString();
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
minWidth: '120'
|
minWidth: '120',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '订单号',
|
title: '订单号',
|
||||||
field: 'orderId',
|
field: 'orderId',
|
||||||
minWidth: '120'
|
minWidth: '120',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '租赁合同编号',
|
title: '租赁合同编号',
|
||||||
field: 'userId',
|
field: 'userId',
|
||||||
minWidth: '120'
|
minWidth: '120',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '租赁人',
|
title: '租赁人',
|
||||||
field: 'userName',
|
field: 'userName',
|
||||||
minWidth: '120'
|
minWidth: '120',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '租金',
|
title: '租金',
|
||||||
field: 'rent',
|
field: 'rent',
|
||||||
minWidth: '120'
|
minWidth: '120',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '押金',
|
title: '押金',
|
||||||
field: 'deposit',
|
field: 'deposit',
|
||||||
minWidth: '120'
|
minWidth: '120',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '违约金',
|
title: '违约金',
|
||||||
field: 'penalty',
|
field: 'penalty',
|
||||||
minWidth: '120'
|
minWidth: '120',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '总金额',
|
title: '总金额',
|
||||||
field: 'totalAmount',
|
field: 'totalAmount',
|
||||||
minWidth: '120'
|
minWidth: '120',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '收费日期',
|
title: '收费日期',
|
||||||
field: 'chargeDate',
|
field: 'chargeDate',
|
||||||
minWidth: '120'
|
minWidth: '120',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '支付方式',
|
title: '支付方式',
|
||||||
@@ -120,7 +121,7 @@ export const columns: VxeGridProps['columns'] = [
|
|||||||
return renderDict(row.paymentMethod, 'pro_payment_method');
|
return renderDict(row.paymentMethod, 'pro_payment_method');
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
minWidth: '120'
|
minWidth: '120',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '开票状态',
|
title: '开票状态',
|
||||||
@@ -130,7 +131,7 @@ export const columns: VxeGridProps['columns'] = [
|
|||||||
return renderDict(row.invoiceStatus, 'pro_invoice_status');
|
return renderDict(row.invoiceStatus, 'pro_invoice_status');
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
minWidth: '120'
|
minWidth: '120',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '发票类型',
|
title: '发票类型',
|
||||||
@@ -140,7 +141,7 @@ export const columns: VxeGridProps['columns'] = [
|
|||||||
return renderDict(row.invoiceType, 'pro_invoice_type');
|
return renderDict(row.invoiceType, 'pro_invoice_type');
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
minWidth: '120'
|
minWidth: '120',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '收费状态',
|
title: '收费状态',
|
||||||
@@ -150,12 +151,12 @@ export const columns: VxeGridProps['columns'] = [
|
|||||||
return renderDict(row.chargeStatus, 'pro_charging_status');
|
return renderDict(row.chargeStatus, 'pro_charging_status');
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
minWidth: '120'
|
minWidth: '120',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '创建时间',
|
title: '创建时间',
|
||||||
field: 'createTime',
|
field: 'createTime',
|
||||||
minWidth: '120'
|
minWidth: '120',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
field: 'action',
|
field: 'action',
|
||||||
@@ -203,7 +204,24 @@ export const modalSchema: FormSchemaGetter = () => [
|
|||||||
{
|
{
|
||||||
label: '租赁人',
|
label: '租赁人',
|
||||||
fieldName: 'userName',
|
fieldName: 'userName',
|
||||||
component: "Select",
|
component: 'Select',
|
||||||
|
rules: 'selectRequired',
|
||||||
|
},
|
||||||
|
{
|
||||||
|
component: 'ApiSelect',
|
||||||
|
fieldName: 'unitId',
|
||||||
|
label: '租赁单位',
|
||||||
|
componentProps: {
|
||||||
|
api: getUnitList,
|
||||||
|
resultField: 'data',
|
||||||
|
labelField: 'label',
|
||||||
|
valueField: 'value',
|
||||||
|
immediate: true,
|
||||||
|
debounceTime: 500,
|
||||||
|
allowClear: true,
|
||||||
|
placeholder: '请选择租赁单位',
|
||||||
|
filterOption: true,
|
||||||
|
},
|
||||||
rules: 'selectRequired',
|
rules: 'selectRequired',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@@ -213,7 +231,7 @@ export const modalSchema: FormSchemaGetter = () => [
|
|||||||
rules: 'required',
|
rules: 'required',
|
||||||
componentProps: {
|
componentProps: {
|
||||||
precision: 2,
|
precision: 2,
|
||||||
}
|
},
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: '押金',
|
label: '押金',
|
||||||
@@ -222,7 +240,7 @@ export const modalSchema: FormSchemaGetter = () => [
|
|||||||
rules: 'required',
|
rules: 'required',
|
||||||
componentProps: {
|
componentProps: {
|
||||||
precision: 2,
|
precision: 2,
|
||||||
}
|
},
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: '违约金',
|
label: '违约金',
|
||||||
@@ -231,7 +249,7 @@ export const modalSchema: FormSchemaGetter = () => [
|
|||||||
rules: 'required',
|
rules: 'required',
|
||||||
componentProps: {
|
componentProps: {
|
||||||
precision: 2,
|
precision: 2,
|
||||||
}
|
},
|
||||||
},
|
},
|
||||||
// {
|
// {
|
||||||
// label: '总金额',
|
// label: '总金额',
|
||||||
@@ -287,3 +305,21 @@ export const modalSchema: FormSchemaGetter = () => [
|
|||||||
rules: 'required',
|
rules: 'required',
|
||||||
},
|
},
|
||||||
];
|
];
|
||||||
|
export async function getUnitList(): Promise<
|
||||||
|
{ value: number; label: string }[]
|
||||||
|
> {
|
||||||
|
const queryParam = {
|
||||||
|
pageNum: 1,
|
||||||
|
pageSize: 1000,
|
||||||
|
};
|
||||||
|
const res = await resident_unitList(queryParam);
|
||||||
|
const data: { value: number; label: string }[] = [];
|
||||||
|
|
||||||
|
res.rows.forEach((r: any) => {
|
||||||
|
data.push({
|
||||||
|
value: r.id,
|
||||||
|
label: r.name,
|
||||||
|
});
|
||||||
|
});
|
||||||
|
return data;
|
||||||
|
}
|
||||||
|
@@ -7,7 +7,7 @@ import dayjs from 'dayjs';
|
|||||||
import duration from 'dayjs/plugin/duration';
|
import duration from 'dayjs/plugin/duration';
|
||||||
import relativeTime from 'dayjs/plugin/relativeTime';
|
import relativeTime from 'dayjs/plugin/relativeTime';
|
||||||
import { orderChargeInfo } from '#/api/property/chargeManagement';
|
import { orderChargeInfo } from '#/api/property/chargeManagement';
|
||||||
import {renderDict} from "#/utils/render";
|
import { renderDict } from '#/utils/render';
|
||||||
dayjs.extend(duration);
|
dayjs.extend(duration);
|
||||||
dayjs.extend(relativeTime);
|
dayjs.extend(relativeTime);
|
||||||
|
|
||||||
@@ -33,8 +33,19 @@ async function handleOpenChange(open: boolean) {
|
|||||||
</script>
|
</script>
|
||||||
|
|
||||||
<template>
|
<template>
|
||||||
<BasicModal :footer="false" :fullscreen-button="false" title="查看收费" class="w-[70%]">
|
<BasicModal
|
||||||
<Descriptions v-if="orderChargeDetail" size="small" :column="2" bordered :labelStyle="{width:'100px'}">
|
:footer="false"
|
||||||
|
:fullscreen-button="false"
|
||||||
|
title="查看收费"
|
||||||
|
class="w-[70%]"
|
||||||
|
>
|
||||||
|
<Descriptions
|
||||||
|
v-if="orderChargeDetail"
|
||||||
|
size="small"
|
||||||
|
:column="2"
|
||||||
|
bordered
|
||||||
|
:labelStyle="{ width: '100px' }"
|
||||||
|
>
|
||||||
<DescriptionsItem label="订单号">
|
<DescriptionsItem label="订单号">
|
||||||
{{ orderChargeDetail.orderId }}
|
{{ orderChargeDetail.orderId }}
|
||||||
</DescriptionsItem>
|
</DescriptionsItem>
|
||||||
@@ -44,6 +55,9 @@ async function handleOpenChange(open: boolean) {
|
|||||||
<DescriptionsItem label="租赁人">
|
<DescriptionsItem label="租赁人">
|
||||||
{{ orderChargeDetail.userName }}
|
{{ orderChargeDetail.userName }}
|
||||||
</DescriptionsItem>
|
</DescriptionsItem>
|
||||||
|
<DescriptionsItem label="租赁单位">
|
||||||
|
{{ orderChargeDetail.unitName }}
|
||||||
|
</DescriptionsItem>
|
||||||
<DescriptionsItem label="租金">
|
<DescriptionsItem label="租金">
|
||||||
{{ orderChargeDetail.rent }}
|
{{ orderChargeDetail.rent }}
|
||||||
</DescriptionsItem>
|
</DescriptionsItem>
|
||||||
@@ -53,32 +67,53 @@ async function handleOpenChange(open: boolean) {
|
|||||||
<DescriptionsItem label="违约金">
|
<DescriptionsItem label="违约金">
|
||||||
{{ orderChargeDetail.penalty }}
|
{{ orderChargeDetail.penalty }}
|
||||||
</DescriptionsItem>
|
</DescriptionsItem>
|
||||||
<DescriptionsItem label="开票状态" v-if="orderChargeDetail.invoiceStatus!=null">
|
<DescriptionsItem
|
||||||
|
label="开票状态"
|
||||||
|
v-if="orderChargeDetail.invoiceStatus != null"
|
||||||
|
>
|
||||||
<component
|
<component
|
||||||
:is="renderDict(orderChargeDetail.invoiceStatus,'pro_invoice_status')"
|
:is="
|
||||||
|
renderDict(orderChargeDetail.invoiceStatus, 'pro_invoice_status')
|
||||||
|
"
|
||||||
/>
|
/>
|
||||||
</DescriptionsItem>
|
</DescriptionsItem>
|
||||||
<DescriptionsItem label="发票类型" v-if="orderChargeDetail.invoiceType!=null">
|
<DescriptionsItem
|
||||||
|
label="发票类型"
|
||||||
|
v-if="orderChargeDetail.invoiceType != null"
|
||||||
|
>
|
||||||
<component
|
<component
|
||||||
:is="renderDict(orderChargeDetail.invoiceType, 'pro_invoice_type')"
|
:is="renderDict(orderChargeDetail.invoiceType, 'pro_invoice_type')"
|
||||||
/>
|
/>
|
||||||
</DescriptionsItem>
|
</DescriptionsItem>
|
||||||
<DescriptionsItem label="收费状态" v-if="orderChargeDetail.chargeStatus!=null">
|
<DescriptionsItem
|
||||||
|
label="收费状态"
|
||||||
|
v-if="orderChargeDetail.chargeStatus != null"
|
||||||
|
>
|
||||||
<component
|
<component
|
||||||
:is="renderDict(orderChargeDetail.chargeStatus,'pro_charging_status')"
|
:is="
|
||||||
|
renderDict(orderChargeDetail.chargeStatus, 'pro_charging_status')
|
||||||
|
"
|
||||||
/>
|
/>
|
||||||
</DescriptionsItem>
|
</DescriptionsItem>
|
||||||
<DescriptionsItem label="产品编号">
|
<DescriptionsItem label="产品编号">
|
||||||
{{ orderChargeDetail.rentalOrder.productList.map(item => item.plantCode).join('、') }}
|
{{
|
||||||
|
orderChargeDetail.rentalOrder.productList
|
||||||
|
.map((item) => item.plantCode)
|
||||||
|
.join('、')
|
||||||
|
}}
|
||||||
</DescriptionsItem>
|
</DescriptionsItem>
|
||||||
<DescriptionsItem label="购买植物">
|
<DescriptionsItem label="购买植物">
|
||||||
{{ orderChargeDetail.rentalOrder.productList.map(item => item.plantName).join('、') }}
|
{{
|
||||||
|
orderChargeDetail.rentalOrder.productList
|
||||||
|
.map((item) => item.plantName)
|
||||||
|
.join('、')
|
||||||
|
}}
|
||||||
</DescriptionsItem>
|
</DescriptionsItem>
|
||||||
<DescriptionsItem label="总金额">
|
<DescriptionsItem label="总金额">
|
||||||
{{ orderChargeDetail.totalAmount }}
|
{{ orderChargeDetail.totalAmount }}
|
||||||
</DescriptionsItem>
|
</DescriptionsItem>
|
||||||
<DescriptionsItem label="产品图片">
|
<DescriptionsItem label="产品图片">
|
||||||
<img :src="orderChargeDetail.createTime" alt="">
|
<img :src="orderChargeDetail.createTime" alt="" />
|
||||||
</DescriptionsItem>
|
</DescriptionsItem>
|
||||||
</Descriptions>
|
</Descriptions>
|
||||||
</BasicModal>
|
</BasicModal>
|
||||||
|
@@ -1,5 +1,4 @@
|
|||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
|
|
||||||
import { ref, shallowRef } from 'vue';
|
import { ref, shallowRef } from 'vue';
|
||||||
|
|
||||||
import { useVbenModal } from '@vben/common-ui';
|
import { useVbenModal } from '@vben/common-ui';
|
||||||
@@ -9,11 +8,11 @@ import dayjs from 'dayjs';
|
|||||||
import duration from 'dayjs/plugin/duration';
|
import duration from 'dayjs/plugin/duration';
|
||||||
import relativeTime from 'dayjs/plugin/relativeTime';
|
import relativeTime from 'dayjs/plugin/relativeTime';
|
||||||
|
|
||||||
import {renderDict} from "#/utils/render";
|
import { renderDict } from '#/utils/render';
|
||||||
import type {RentalOrderVO} from "#/api/property/rentalOrder/model";
|
import type { RentalOrderVO } from '#/api/property/rentalOrder/model';
|
||||||
import {rentalOrderInfo} from "#/api/property/rentalOrder";
|
import { rentalOrderInfo } from '#/api/property/rentalOrder';
|
||||||
import {rentalColumns} from "./data";
|
import { rentalColumns } from './data';
|
||||||
import {Table} from "ant-design-vue";
|
import { Table } from 'ant-design-vue';
|
||||||
|
|
||||||
dayjs.extend(duration);
|
dayjs.extend(duration);
|
||||||
dayjs.extend(relativeTime);
|
dayjs.extend(relativeTime);
|
||||||
@@ -38,17 +37,26 @@ async function handleOpenChange(open: boolean) {
|
|||||||
const { id } = modalApi.getData() as { id: number | string };
|
const { id } = modalApi.getData() as { id: number | string };
|
||||||
// 赋值
|
// 赋值
|
||||||
orderDetail.value = await rentalOrderInfo(id);
|
orderDetail.value = await rentalOrderInfo(id);
|
||||||
planProducts.value=orderDetail.value?.productList
|
planProducts.value = orderDetail.value?.productList;
|
||||||
|
|
||||||
modalApi.modalLoading(false);
|
modalApi.modalLoading(false);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<template>
|
<template>
|
||||||
<BasicModal :footer="false" :fullscreen-button="false" title="租赁订单信息" class="w-[70%]">
|
<BasicModal
|
||||||
<Descriptions v-if="orderDetail" size="small" :column="2" bordered :labelStyle="{width:'100px'}">
|
:footer="false"
|
||||||
|
:fullscreen-button="false"
|
||||||
|
title="租赁订单信息"
|
||||||
|
class="w-[70%]"
|
||||||
|
>
|
||||||
|
<Descriptions
|
||||||
|
v-if="orderDetail"
|
||||||
|
size="small"
|
||||||
|
:column="2"
|
||||||
|
bordered
|
||||||
|
:labelStyle="{ width: '100px' }"
|
||||||
|
>
|
||||||
<DescriptionsItem label="订单号">
|
<DescriptionsItem label="订单号">
|
||||||
{{ orderDetail.orderNo }}
|
{{ orderDetail.orderNo }}
|
||||||
</DescriptionsItem>
|
</DescriptionsItem>
|
||||||
@@ -56,23 +64,26 @@ async function handleOpenChange(open: boolean) {
|
|||||||
{{ orderDetail.customerName }}
|
{{ orderDetail.customerName }}
|
||||||
</DescriptionsItem>
|
</DescriptionsItem>
|
||||||
<DescriptionsItem label="客户类型" v-if="orderDetail.type != null">
|
<DescriptionsItem label="客户类型" v-if="orderDetail.type != null">
|
||||||
<component
|
<component :is="renderDict(orderDetail.customerType, 'wy_khlx')" />
|
||||||
:is="renderDict(orderDetail.customerType,'wy_khlx')"
|
</DescriptionsItem>
|
||||||
/>
|
<DescriptionsItem label="租赁单位">
|
||||||
|
{{ orderDetail.unitName }}
|
||||||
</DescriptionsItem>
|
</DescriptionsItem>
|
||||||
<DescriptionsItem label="租赁周期">
|
<DescriptionsItem label="租赁周期">
|
||||||
{{ orderDetail.rentalPeriod }}
|
{{ orderDetail.rentalPeriod }}
|
||||||
</DescriptionsItem>
|
</DescriptionsItem>
|
||||||
<DescriptionsItem label="租赁时间" :span="2">
|
<DescriptionsItem label="租赁时间" :span="2">
|
||||||
{{dayjs(orderDetail.startTime).format("YYYY-MM-DD")+' 至 '+dayjs(orderDetail.endTime).format("YYYY-MM-DD")}}
|
{{
|
||||||
|
dayjs(orderDetail.startTime).format('YYYY-MM-DD') +
|
||||||
|
' 至 ' +
|
||||||
|
dayjs(orderDetail.endTime).format('YYYY-MM-DD')
|
||||||
|
}}
|
||||||
</DescriptionsItem>
|
</DescriptionsItem>
|
||||||
<DescriptionsItem label="总金额">
|
<DescriptionsItem label="总金额">
|
||||||
{{ orderDetail.totalAmount +"元"}}
|
{{ orderDetail.totalAmount + '元' }}
|
||||||
</DescriptionsItem>
|
</DescriptionsItem>
|
||||||
<DescriptionsItem label="租赁方式">
|
<DescriptionsItem label="租赁方式">
|
||||||
<component
|
<component :is="renderDict(orderDetail.rentalType, 'wy_zlfs')" />
|
||||||
:is="renderDict(orderDetail.rentalType,'wy_zlfs')"
|
|
||||||
/>
|
|
||||||
</DescriptionsItem>
|
</DescriptionsItem>
|
||||||
<!-- <DescriptionsItem label="支付状态">-->
|
<!-- <DescriptionsItem label="支付状态">-->
|
||||||
<!-- <component-->
|
<!-- <component-->
|
||||||
@@ -80,28 +91,33 @@ async function handleOpenChange(open: boolean) {
|
|||||||
<!-- />-->
|
<!-- />-->
|
||||||
<!-- </DescriptionsItem>-->
|
<!-- </DescriptionsItem>-->
|
||||||
<DescriptionsItem label="是否续租">
|
<DescriptionsItem label="是否续租">
|
||||||
<component
|
<component :is="renderDict(orderDetail.isRelet, 'wy_sf')" />
|
||||||
:is="renderDict(orderDetail.isRelet,'wy_sf')"
|
|
||||||
/>
|
|
||||||
</DescriptionsItem>
|
</DescriptionsItem>
|
||||||
<DescriptionsItem label="合同状态">
|
<DescriptionsItem label="合同状态">
|
||||||
<component
|
<component :is="renderDict(orderDetail.contractStatus, 'wy_htzt')" />
|
||||||
:is="renderDict(orderDetail.contractStatus,'wy_htzt')"
|
|
||||||
/>
|
|
||||||
</DescriptionsItem>
|
</DescriptionsItem>
|
||||||
<DescriptionsItem label="合同编号" v-if="orderDetail.contractStatus!='1'">
|
<DescriptionsItem
|
||||||
|
label="合同编号"
|
||||||
|
v-if="orderDetail.contractStatus != '1'"
|
||||||
|
>
|
||||||
{{ orderDetail.contractCode ?? '无' }}
|
{{ orderDetail.contractCode ?? '无' }}
|
||||||
</DescriptionsItem>
|
</DescriptionsItem>
|
||||||
<DescriptionsItem label="签署时间" v-if="orderDetail.contractStatus!='1'">
|
<DescriptionsItem
|
||||||
|
label="签署时间"
|
||||||
|
v-if="orderDetail.contractStatus != '1'"
|
||||||
|
>
|
||||||
{{ orderDetail.signTime ?? '无' }}
|
{{ orderDetail.signTime ?? '无' }}
|
||||||
</DescriptionsItem>
|
</DescriptionsItem>
|
||||||
</Descriptions>
|
</Descriptions>
|
||||||
<div v-if="planProducts.length">
|
<div v-if="planProducts.length">
|
||||||
<div style="margin: 10px 0;font-weight: 500">
|
<div style="margin: 10px 0; font-weight: 500">订单产品详情</div>
|
||||||
订单产品详情
|
<Table
|
||||||
</div>
|
:dataSource="planProducts"
|
||||||
<Table :dataSource="planProducts" :columns="rentalColumns" :pagination="false"
|
:columns="rentalColumns"
|
||||||
bordered size="small">
|
:pagination="false"
|
||||||
|
bordered
|
||||||
|
size="small"
|
||||||
|
>
|
||||||
<template #bodyCell="{ column, record, index }">
|
<template #bodyCell="{ column, record, index }">
|
||||||
<template v-if="column.field === 'id'">
|
<template v-if="column.field === 'id'">
|
||||||
{{ index + 1 }}
|
{{ index + 1 }}
|
||||||
|
@@ -20,6 +20,7 @@ import type {PropertyVO} from "#/api/property/productManagement/model";
|
|||||||
import type {RentalPlanVO} from "#/api/property/rentalPlan/model";
|
import type {RentalPlanVO} from "#/api/property/rentalPlan/model";
|
||||||
import {planInfoColumns} from './data';
|
import {planInfoColumns} from './data';
|
||||||
import {Table} from "ant-design-vue";
|
import {Table} from "ant-design-vue";
|
||||||
|
import { resident_unitList } from '#/api/property/resident/unit'
|
||||||
|
|
||||||
const emit = defineEmits<{ reload: [] }>();
|
const emit = defineEmits<{ reload: [] }>();
|
||||||
|
|
||||||
@@ -57,6 +58,23 @@ const modalSchema = [
|
|||||||
options: getDictOptions('wy_khlx')
|
options: getDictOptions('wy_khlx')
|
||||||
},
|
},
|
||||||
rules: 'selectRequired',
|
rules: 'selectRequired',
|
||||||
|
},
|
||||||
|
{
|
||||||
|
component: 'ApiSelect',
|
||||||
|
fieldName: 'unitId',
|
||||||
|
label: '租赁单位',
|
||||||
|
componentProps: {
|
||||||
|
api: getUnitList,
|
||||||
|
resultField: 'data',
|
||||||
|
labelField: 'label',
|
||||||
|
valueField: 'value',
|
||||||
|
immediate: true,
|
||||||
|
debounceTime: 500,
|
||||||
|
allowClear: true,
|
||||||
|
placeholder: '请选择租赁单位',
|
||||||
|
filterOption: true,
|
||||||
|
},
|
||||||
|
rules:'selectRequired',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: '租赁周期',
|
label: '租赁周期',
|
||||||
@@ -300,7 +318,22 @@ const [BasicModal, modalApi] = useVbenModal({
|
|||||||
modalApi.modalLoading(false);
|
modalApi.modalLoading(false);
|
||||||
},
|
},
|
||||||
});
|
});
|
||||||
|
async function getUnitList(){
|
||||||
|
const queryParam = {
|
||||||
|
pageNum: 1,
|
||||||
|
pageSize: 1000,
|
||||||
|
}
|
||||||
|
const res = await resident_unitList(queryParam)
|
||||||
|
const data: { value: number; label: string }[] = []
|
||||||
|
|
||||||
|
res.rows.forEach((r: any) => {
|
||||||
|
data.push({
|
||||||
|
value: r.id,
|
||||||
|
label: r.name,
|
||||||
|
})
|
||||||
|
})
|
||||||
|
return data;
|
||||||
|
}
|
||||||
async function handleConfirm() {
|
async function handleConfirm() {
|
||||||
try {
|
try {
|
||||||
modalApi.lock(true);
|
modalApi.lock(true);
|
||||||
|
Reference in New Issue
Block a user