Commit 63ef3e7f697337259ef749a9aed6781b5c679b28
1 parent
b0222bb0
v1.9 加入天麟收据模版
Showing
14 changed files
with
1563 additions
and
20 deletions
src/api/fee/printPayFeeApi.js
| @@ -53,4 +53,58 @@ export function queryFeePrintSpec(params) { | @@ -53,4 +53,58 @@ export function queryFeePrintSpec(params) { | ||
| 53 | reject(error) | 53 | reject(error) |
| 54 | }) | 54 | }) |
| 55 | }) | 55 | }) |
| 56 | +} | ||
| 57 | + | ||
| 58 | +// 查询费用详情折扣 | ||
| 59 | +export function queryFeeDetailDiscount(params) { | ||
| 60 | + return new Promise((resolve, reject) => { | ||
| 61 | + request({ | ||
| 62 | + url: '/feeDiscount/queryFeeDetailDiscount', | ||
| 63 | + method: 'get', | ||
| 64 | + params: { | ||
| 65 | + ...params, | ||
| 66 | + communityId: getCommunityId() | ||
| 67 | + } | ||
| 68 | + }).then(response => { | ||
| 69 | + resolve(response.data) | ||
| 70 | + }).catch(error => { | ||
| 71 | + reject(error) | ||
| 72 | + }) | ||
| 73 | + }) | ||
| 74 | +} | ||
| 75 | + | ||
| 76 | +// 查询业主车辆 | ||
| 77 | +export function queryOwnerCars(params) { | ||
| 78 | + return new Promise((resolve, reject) => { | ||
| 79 | + request({ | ||
| 80 | + url: '/owner.queryOwnerCars', | ||
| 81 | + method: 'get', | ||
| 82 | + params: { | ||
| 83 | + ...params, | ||
| 84 | + communityId: getCommunityId() | ||
| 85 | + } | ||
| 86 | + }).then(response => { | ||
| 87 | + resolve(response.data) | ||
| 88 | + }).catch(error => { | ||
| 89 | + reject(error) | ||
| 90 | + }) | ||
| 91 | + }) | ||
| 92 | +} | ||
| 93 | + | ||
| 94 | +// 查询房屋信息 | ||
| 95 | +export function queryRooms(params) { | ||
| 96 | + return new Promise((resolve, reject) => { | ||
| 97 | + request({ | ||
| 98 | + url: '/room.queryRooms', | ||
| 99 | + method: 'get', | ||
| 100 | + params: { | ||
| 101 | + ...params, | ||
| 102 | + communityId: getCommunityId() | ||
| 103 | + } | ||
| 104 | + }).then(response => { | ||
| 105 | + resolve(response.data) | ||
| 106 | + }).catch(error => { | ||
| 107 | + reject(error) | ||
| 108 | + }) | ||
| 109 | + }) | ||
| 56 | } | 110 | } |
| 57 | \ No newline at end of file | 111 | \ No newline at end of file |
src/components/fee/addFeeConfig.vue
| @@ -96,7 +96,7 @@ | @@ -96,7 +96,7 @@ | ||
| 96 | </el-col> | 96 | </el-col> |
| 97 | 97 | ||
| 98 | <el-col :span="24"> | 98 | <el-col :span="24"> |
| 99 | - <el-form-item :label="$t('feeConfigManage.formula')" prop="computingFormula" required> | 99 | + <el-form-item :label="$t('feeConfigManage.formula')" prop="computingFormula" > |
| 100 | <el-select v-model="form.computingFormula" :placeholder="$t('feeConfigManage.selectFormula')" | 100 | <el-select v-model="form.computingFormula" :placeholder="$t('feeConfigManage.selectFormula')" |
| 101 | class="full-width-select"> | 101 | class="full-width-select"> |
| 102 | <el-option v-for="item in computingFormulas" :key="item.statusCd" :label="item.name" | 102 | <el-option v-for="item in computingFormulas" :key="item.statusCd" :label="item.name" |
| @@ -107,7 +107,7 @@ | @@ -107,7 +107,7 @@ | ||
| 107 | 107 | ||
| 108 | <template v-if="shouldShowUnitPrice"> | 108 | <template v-if="shouldShowUnitPrice"> |
| 109 | <el-col :span="24"> | 109 | <el-col :span="24"> |
| 110 | - <el-form-item :label="$t('feeConfigManage.unitPrice')" prop="squarePrice" required> | 110 | + <el-form-item :label="$t('feeConfigManage.unitPrice')" prop="squarePrice" > |
| 111 | <el-input v-model="form.squarePrice" :placeholder="$t('feeConfigManage.enterUnitPrice')" /> | 111 | <el-input v-model="form.squarePrice" :placeholder="$t('feeConfigManage.enterUnitPrice')" /> |
| 112 | </el-form-item> | 112 | </el-form-item> |
| 113 | </el-col> | 113 | </el-col> |
| @@ -115,7 +115,7 @@ | @@ -115,7 +115,7 @@ | ||
| 115 | 115 | ||
| 116 | <template v-if="shouldShowAdditionalAmount"> | 116 | <template v-if="shouldShowAdditionalAmount"> |
| 117 | <el-col :span="24"> | 117 | <el-col :span="24"> |
| 118 | - <el-form-item :label="additionalAmountLabel" prop="additionalAmount" required> | 118 | + <el-form-item :label="additionalAmountLabel" prop="additionalAmount" > |
| 119 | <el-input v-model="form.additionalAmount" :placeholder="$t('feeConfigManage.enterAdditionalFee')" /> | 119 | <el-input v-model="form.additionalAmount" :placeholder="$t('feeConfigManage.enterAdditionalFee')" /> |
| 120 | </el-form-item> | 120 | </el-form-item> |
| 121 | </el-col> | 121 | </el-col> |
| @@ -123,7 +123,7 @@ | @@ -123,7 +123,7 @@ | ||
| 123 | 123 | ||
| 124 | <template v-if="form.computingFormula == '7007'"> | 124 | <template v-if="form.computingFormula == '7007'"> |
| 125 | <el-col :span="24"> | 125 | <el-col :span="24"> |
| 126 | - <el-form-item :label="$t('feeConfigManage.formula')" prop="computingFormulaText" required> | 126 | + <el-form-item :label="$t('feeConfigManage.formula')" prop="computingFormulaText" > |
| 127 | <el-input type="textarea" v-model="form.computingFormulaText" | 127 | <el-input type="textarea" v-model="form.computingFormulaText" |
| 128 | :placeholder="$t('feeConfigManage.enterFormula')" :rows="4" /> | 128 | :placeholder="$t('feeConfigManage.enterFormula')" :rows="4" /> |
| 129 | </el-form-item> | 129 | </el-form-item> |
| @@ -195,8 +195,6 @@ export default { | @@ -195,8 +195,6 @@ export default { | ||
| 195 | prepaymentPeriod: [{ required: true, message: this.$t('feeConfigManage.enterPrepaymentPeriod'), trigger: 'blur' }], | 195 | prepaymentPeriod: [{ required: true, message: this.$t('feeConfigManage.enterPrepaymentPeriod'), trigger: 'blur' }], |
| 196 | units: [{ required: true, message: this.$t('feeConfigManage.enterUnit'), trigger: 'blur' }], | 196 | units: [{ required: true, message: this.$t('feeConfigManage.enterUnit'), trigger: 'blur' }], |
| 197 | computingFormula: [{ required: true, message: this.$t('feeConfigManage.selectFormula'), trigger: 'change' }], | 197 | computingFormula: [{ required: true, message: this.$t('feeConfigManage.selectFormula'), trigger: 'change' }], |
| 198 | - squarePrice: [{ required: true, message: this.$t('feeConfigManage.enterUnitPrice'), trigger: 'blur' }], | ||
| 199 | - additionalAmount: [{ required: true, message: this.$t('feeConfigManage.enterAdditionalFee'), trigger: 'blur' }], | ||
| 200 | computingFormulaText: [{ required: true, message: this.$t('feeConfigManage.enterFormula'), trigger: 'blur' }] | 198 | computingFormulaText: [{ required: true, message: this.$t('feeConfigManage.enterFormula'), trigger: 'blur' }] |
| 201 | } | 199 | } |
| 202 | } | 200 | } |
src/components/fee/editFeeConfig.vue
| 1 | <template> | 1 | <template> |
| 2 | <el-dialog :title="$t('common.edit')" :visible.sync="visible" width="80%" @close="resetForm"> | 2 | <el-dialog :title="$t('common.edit')" :visible.sync="visible" width="80%" @close="resetForm"> |
| 3 | - <el-form :model="form" label-width="150px" ref="form"> | 3 | + <el-form :model="form" :rules="rules" label-width="150px" ref="form"> |
| 4 | <el-row :gutter="20"> | 4 | <el-row :gutter="20"> |
| 5 | <el-col :span="12"> | 5 | <el-col :span="12"> |
| 6 | - <el-form-item :label="$t('feeConfigManage.feeType')" prop="feeTypeCd" required> | 6 | + <el-form-item :label="$t('feeConfigManage.feeType')" prop="feeTypeCd" > |
| 7 | <el-select | 7 | <el-select |
| 8 | v-model="form.feeTypeCd" | 8 | v-model="form.feeTypeCd" |
| 9 | :disabled="form.isDefault === 'T'" | 9 | :disabled="form.isDefault === 'T'" |
| @@ -15,13 +15,13 @@ | @@ -15,13 +15,13 @@ | ||
| 15 | </el-form-item> | 15 | </el-form-item> |
| 16 | </el-col> | 16 | </el-col> |
| 17 | <el-col :span="12"> | 17 | <el-col :span="12"> |
| 18 | - <el-form-item :label="$t('feeConfigManage.feeItem')" prop="feeName" required> | 18 | + <el-form-item :label="$t('feeConfigManage.feeItem')" prop="feeName" > |
| 19 | <el-input v-model="form.feeName" :disabled="form.isDefault === 'T'" | 19 | <el-input v-model="form.feeName" :disabled="form.isDefault === 'T'" |
| 20 | :placeholder="$t('feeConfigManage.enterFeeItem')" /> | 20 | :placeholder="$t('feeConfigManage.enterFeeItem')" /> |
| 21 | </el-form-item> | 21 | </el-form-item> |
| 22 | </el-col> | 22 | </el-col> |
| 23 | <el-col :span="12"> | 23 | <el-col :span="12"> |
| 24 | - <el-form-item :label="$t('feeConfigManage.feeFlag')" prop="feeFlag" required> | 24 | + <el-form-item :label="$t('feeConfigManage.feeFlag')" prop="feeFlag" > |
| 25 | <el-select | 25 | <el-select |
| 26 | v-model="form.feeFlag" | 26 | v-model="form.feeFlag" |
| 27 | :disabled="form.isDefault === 'T'" | 27 | :disabled="form.isDefault === 'T'" |
| @@ -33,7 +33,7 @@ | @@ -33,7 +33,7 @@ | ||
| 33 | </el-form-item> | 33 | </el-form-item> |
| 34 | </el-col> | 34 | </el-col> |
| 35 | <el-col :span="12"> | 35 | <el-col :span="12"> |
| 36 | - <el-form-item :label="$t('feeConfigManage.paymentType')" prop="paymentCd" required> | 36 | + <el-form-item :label="$t('feeConfigManage.paymentType')" prop="paymentCd" > |
| 37 | <el-select | 37 | <el-select |
| 38 | v-model="form.paymentCd" | 38 | v-model="form.paymentCd" |
| 39 | :placeholder="$t('feeConfigManage.selectPaymentType')" | 39 | :placeholder="$t('feeConfigManage.selectPaymentType')" |
| @@ -45,12 +45,12 @@ | @@ -45,12 +45,12 @@ | ||
| 45 | </el-col> | 45 | </el-col> |
| 46 | 46 | ||
| 47 | <el-col :span="12" v-if="form.feeFlag != '2006012'"> | 47 | <el-col :span="12" v-if="form.feeFlag != '2006012'"> |
| 48 | - <el-form-item :label="$t('feeConfigManage.paymentCycle')" prop="paymentCycle" required> | 48 | + <el-form-item :label="$t('feeConfigManage.paymentCycle')" prop="paymentCycle" > |
| 49 | <el-input v-model="form.paymentCycle" :placeholder="$t('feeConfigManage.enterPaymentCycle')" /> | 49 | <el-input v-model="form.paymentCycle" :placeholder="$t('feeConfigManage.enterPaymentCycle')" /> |
| 50 | </el-form-item> | 50 | </el-form-item> |
| 51 | </el-col> | 51 | </el-col> |
| 52 | <el-col :span="12" v-if="form.paymentCd == '1200'"> | 52 | <el-col :span="12" v-if="form.paymentCd == '1200'"> |
| 53 | - <el-form-item :label="$t('feeConfigManage.prepaymentPeriod')" prop="prepaymentPeriod" required> | 53 | + <el-form-item :label="$t('feeConfigManage.prepaymentPeriod')" prop="prepaymentPeriod" > |
| 54 | <el-input v-model="form.prepaymentPeriod" :placeholder="$t('feeConfigManage.enterPrepaymentPeriod')" /> | 54 | <el-input v-model="form.prepaymentPeriod" :placeholder="$t('feeConfigManage.enterPrepaymentPeriod')" /> |
| 55 | </el-form-item> | 55 | </el-form-item> |
| 56 | </el-col> | 56 | </el-col> |
| @@ -109,7 +109,7 @@ | @@ -109,7 +109,7 @@ | ||
| 109 | </el-col> | 109 | </el-col> |
| 110 | 110 | ||
| 111 | <el-col :span="24"> | 111 | <el-col :span="24"> |
| 112 | - <el-form-item :label="$t('feeConfigManage.formula')" prop="computingFormula" required> | 112 | + <el-form-item :label="$t('feeConfigManage.formula')" prop="computingFormula" > |
| 113 | <el-select | 113 | <el-select |
| 114 | v-model="form.computingFormula" | 114 | v-model="form.computingFormula" |
| 115 | :disabled="form.isDefault === 'T'" | 115 | :disabled="form.isDefault === 'T'" |
| @@ -123,7 +123,7 @@ | @@ -123,7 +123,7 @@ | ||
| 123 | 123 | ||
| 124 | <template v-if="shouldShowUnitPrice"> | 124 | <template v-if="shouldShowUnitPrice"> |
| 125 | <el-col :span="24"> | 125 | <el-col :span="24"> |
| 126 | - <el-form-item :label="$t('feeConfigManage.unitPrice')" prop="squarePrice" required> | 126 | + <el-form-item :label="$t('feeConfigManage.unitPrice')" prop="squarePrice" > |
| 127 | <el-input v-model="form.squarePrice" :placeholder="$t('feeConfigManage.enterUnitPrice')" /> | 127 | <el-input v-model="form.squarePrice" :placeholder="$t('feeConfigManage.enterUnitPrice')" /> |
| 128 | </el-form-item> | 128 | </el-form-item> |
| 129 | </el-col> | 129 | </el-col> |
| @@ -131,7 +131,7 @@ | @@ -131,7 +131,7 @@ | ||
| 131 | 131 | ||
| 132 | <template v-if="shouldShowAdditionalAmount"> | 132 | <template v-if="shouldShowAdditionalAmount"> |
| 133 | <el-col :span="24"> | 133 | <el-col :span="24"> |
| 134 | - <el-form-item :label="additionalAmountLabel" prop="additionalAmount" required> | 134 | + <el-form-item :label="additionalAmountLabel" prop="additionalAmount" > |
| 135 | <el-input v-model="form.additionalAmount" :placeholder="$t('feeConfigManage.enterAdditionalFee')" /> | 135 | <el-input v-model="form.additionalAmount" :placeholder="$t('feeConfigManage.enterAdditionalFee')" /> |
| 136 | </el-form-item> | 136 | </el-form-item> |
| 137 | </el-col> | 137 | </el-col> |
| @@ -139,7 +139,7 @@ | @@ -139,7 +139,7 @@ | ||
| 139 | 139 | ||
| 140 | <template v-if="form.computingFormula == '7007'"> | 140 | <template v-if="form.computingFormula == '7007'"> |
| 141 | <el-col :span="24"> | 141 | <el-col :span="24"> |
| 142 | - <el-form-item :label="$t('feeConfigManage.formula')" prop="computingFormulaText" required> | 142 | + <el-form-item :label="$t('feeConfigManage.formula')" prop="computingFormulaText" > |
| 143 | <el-input type="textarea" v-model="form.computingFormulaText" | 143 | <el-input type="textarea" v-model="form.computingFormulaText" |
| 144 | :placeholder="$t('feeConfigManage.enterFormula')" :rows="4" /> | 144 | :placeholder="$t('feeConfigManage.enterFormula')" :rows="4" /> |
| 145 | </el-form-item> | 145 | </el-form-item> |
| @@ -199,10 +199,22 @@ export default { | @@ -199,10 +199,22 @@ export default { | ||
| 199 | state: 'Y', | 199 | state: 'Y', |
| 200 | communityId: this.getCommunityId() | 200 | communityId: this.getCommunityId() |
| 201 | }, | 201 | }, |
| 202 | + | ||
| 202 | feeTypeCds: [], | 203 | feeTypeCds: [], |
| 203 | computingFormulas: [], | 204 | computingFormulas: [], |
| 204 | feeFlags: [], | 205 | feeFlags: [], |
| 205 | - paymentCds: [] | 206 | + paymentCds: [], |
| 207 | + rules: { | ||
| 208 | + feeTypeCd: [{ required: true, message: this.$t('feeConfigManage.feeType'), trigger: 'change' }], | ||
| 209 | + feeName: [{ required: true, message: this.$t('feeConfigManage.enterFeeItem'), trigger: 'blur' }], | ||
| 210 | + feeFlag: [{ required: true, message: this.$t('feeConfigManage.selectFeeFlag'), trigger: 'change' }], | ||
| 211 | + paymentCd: [{ required: true, message: this.$t('feeConfigManage.selectPaymentType'), trigger: 'change' }], | ||
| 212 | + paymentCycle: [{ required: true, message: this.$t('feeConfigManage.enterPaymentCycle'), trigger: 'blur' }], | ||
| 213 | + prepaymentPeriod: [{ required: true, message: this.$t('feeConfigManage.enterPrepaymentPeriod'), trigger: 'blur' }], | ||
| 214 | + units: [{ required: true, message: this.$t('feeConfigManage.enterUnit'), trigger: 'blur' }], | ||
| 215 | + computingFormula: [{ required: true, message: this.$t('feeConfigManage.selectFormula'), trigger: 'change' }], | ||
| 216 | + computingFormulaText: [{ required: true, message: this.$t('feeConfigManage.enterFormula'), trigger: 'blur' }] | ||
| 217 | + } | ||
| 206 | } | 218 | } |
| 207 | }, | 219 | }, |
| 208 | computed: { | 220 | computed: { |
src/i18n/feeI18n.js
| @@ -9,6 +9,9 @@ import { messages as listApplyRoomDiscountRecordMessages } from '../views/fee/li | @@ -9,6 +9,9 @@ import { messages as listApplyRoomDiscountRecordMessages } from '../views/fee/li | ||
| 9 | import { messages as feeReceiptMessages } from '../views/fee/feeReceiptLang' | 9 | import { messages as feeReceiptMessages } from '../views/fee/feeReceiptLang' |
| 10 | import { messages as printPayFeeMessages } from '../views/fee/printPayFeeLang' | 10 | import { messages as printPayFeeMessages } from '../views/fee/printPayFeeLang' |
| 11 | import { messages as printPayFeeBangTaiMessages } from '../views/fee/printPayFeeBangTaiLang' | 11 | import { messages as printPayFeeBangTaiMessages } from '../views/fee/printPayFeeBangTaiLang' |
| 12 | +import { messages as printPayFeeXiangyunMessages } from '../views/fee/printPayFeeXiangyunLang' | ||
| 13 | +import { messages as printPayFeeXinShiDaiMessages } from '../views/fee/printPayFeeXinShiDaiLang' | ||
| 14 | +import { messages as printPayFeeTianlinMessages } from '../views/fee/printPayFeeTianlinLang' | ||
| 12 | import { messages as printSmallPayFeeMessages } from '../views/fee/printSmallPayFeeLang' | 15 | import { messages as printSmallPayFeeMessages } from '../views/fee/printSmallPayFeeLang' |
| 13 | import { messages as floorShareMessages } from '../views/fee/floorShareLang' | 16 | import { messages as floorShareMessages } from '../views/fee/floorShareLang' |
| 14 | import { messages as shareReadingMessages } from '../views/fee/shareReadingLang' | 17 | import { messages as shareReadingMessages } from '../views/fee/shareReadingLang' |
| @@ -52,6 +55,9 @@ export const messages = { | @@ -52,6 +55,9 @@ export const messages = { | ||
| 52 | ...feeReceiptMessages.en, | 55 | ...feeReceiptMessages.en, |
| 53 | ...printPayFeeMessages.en, | 56 | ...printPayFeeMessages.en, |
| 54 | ...printPayFeeBangTaiMessages.en, | 57 | ...printPayFeeBangTaiMessages.en, |
| 58 | + ...printPayFeeXiangyunMessages.en, | ||
| 59 | + ...printPayFeeXinShiDaiMessages.en, | ||
| 60 | + ...printPayFeeTianlinMessages.en, | ||
| 55 | ...printSmallPayFeeMessages.en, | 61 | ...printSmallPayFeeMessages.en, |
| 56 | ...floorShareMessages.en, | 62 | ...floorShareMessages.en, |
| 57 | ...shareReadingMessages.en, | 63 | ...shareReadingMessages.en, |
| @@ -94,6 +100,9 @@ export const messages = { | @@ -94,6 +100,9 @@ export const messages = { | ||
| 94 | ...feeReceiptMessages.zh, | 100 | ...feeReceiptMessages.zh, |
| 95 | ...printPayFeeMessages.zh, | 101 | ...printPayFeeMessages.zh, |
| 96 | ...printPayFeeBangTaiMessages.zh, | 102 | ...printPayFeeBangTaiMessages.zh, |
| 103 | + ...printPayFeeXiangyunMessages.zh, | ||
| 104 | + ...printPayFeeXinShiDaiMessages.zh, | ||
| 105 | + ...printPayFeeTianlinMessages.zh, | ||
| 97 | ...printSmallPayFeeMessages.zh, | 106 | ...printSmallPayFeeMessages.zh, |
| 98 | ...floorShareMessages.zh, | 107 | ...floorShareMessages.zh, |
| 99 | ...shareReadingMessages.zh, | 108 | ...shareReadingMessages.zh, |
src/router/index.js
| @@ -694,6 +694,21 @@ const routes = [ | @@ -694,6 +694,21 @@ const routes = [ | ||
| 694 | component: () => import('@/views/fee/printPayFeeBangTaiList.vue') | 694 | component: () => import('@/views/fee/printPayFeeBangTaiList.vue') |
| 695 | }, | 695 | }, |
| 696 | { | 696 | { |
| 697 | + path: '/pages/property/printPayFeeXiangyun', | ||
| 698 | + name: '/pages/property/printPayFeeXiangyun', | ||
| 699 | + component: () => import('@/views/fee/printPayFeeXiangyun.vue') | ||
| 700 | + }, | ||
| 701 | + { | ||
| 702 | + path: '/pages/property/printPayFeeXinShiDai', | ||
| 703 | + name: '/pages/property/printPayFeeXinShiDai', | ||
| 704 | + component: () => import('@/views/fee/printPayFeeXinShiDai.vue') | ||
| 705 | + }, | ||
| 706 | + { | ||
| 707 | + path: '/pages/property/printPayFeeTianlin', | ||
| 708 | + name: '/pages/property/printPayFeeTianlin', | ||
| 709 | + component: () => import('@/views/fee/printPayFeeTianlin.vue') | ||
| 710 | + }, | ||
| 711 | + { | ||
| 697 | path: '/pages/property/printSmallPayFee', | 712 | path: '/pages/property/printSmallPayFee', |
| 698 | name: '/pages/property/printSmallPayFee', | 713 | name: '/pages/property/printSmallPayFee', |
| 699 | component: () => import('@/views/fee/printSmallPayFeeList.vue') | 714 | component: () => import('@/views/fee/printSmallPayFeeList.vue') |
src/views/fee/payFeeConfigDiscountManageList.vue
| 1 | <template> | 1 | <template> |
| 2 | + <div class="padding"> | ||
| 2 | <el-card class="pay-fee-config-discount-manage"> | 3 | <el-card class="pay-fee-config-discount-manage"> |
| 3 | <div slot="header"> | 4 | <div slot="header"> |
| 4 | <el-row type="flex" justify="space-between" align="middle"> | 5 | <el-row type="flex" justify="space-between" align="middle"> |
| @@ -69,6 +70,7 @@ | @@ -69,6 +70,7 @@ | ||
| 69 | <add-pay-fee-config-discount ref="addModal" @success="fetchData" /> | 70 | <add-pay-fee-config-discount ref="addModal" @success="fetchData" /> |
| 70 | <delete-pay-fee-config-discount ref="deleteModal" @success="fetchData" /> | 71 | <delete-pay-fee-config-discount ref="deleteModal" @success="fetchData" /> |
| 71 | </el-card> | 72 | </el-card> |
| 73 | +</div> | ||
| 72 | </template> | 74 | </template> |
| 73 | 75 | ||
| 74 | <script> | 76 | <script> |
src/views/fee/printPayFeeTianlin.md
0 → 100644
| 1 | +html | ||
| 2 | +```html | ||
| 3 | +<div> | ||
| 4 | + <div class="top-1 flex justify-between "> | ||
| 5 | + <div class="top-left" style="width: 80%;"> | ||
| 6 | + <h1 class="text-center" style="color:#000;font-weight: 400;">{{printPayFeeInfo.storeName}}收据单</h1> | ||
| 7 | + <div class="flex justify-around" style="color:#000;font-size:20px"> | ||
| 8 | + <div style="width: 25%;">小区名称:{{printPayFeeInfo.communityName}}</div> | ||
| 9 | + <div style="width: 25%;">栋号:{{printPayFeeInfo.roomInfo.floorNum}}栋</div> | ||
| 10 | + <div style="width: 25%;">建筑面积:{{printPayFeeInfo.fees && printPayFeeInfo.fees.length>0?printPayFeeInfo.fees[0].area:'无'}}</div> | ||
| 11 | + </div> | ||
| 12 | + <div class="flex justify-around" style="color:#000;font-size:20px"> | ||
| 13 | + <div style="width: 25%;">户主姓名:{{printPayFeeInfo.payObjName}}</div> | ||
| 14 | + <div style="width: 25%;">房号:{{printPayFeeInfo.roomInfo.roomNum}}</div> | ||
| 15 | + <div style="width: 25%;">房屋编号:{{printPayFeeInfo.fees && printPayFeeInfo.fees.length>0?printPayFeeInfo.fees[0].objName:'无'}}</div> | ||
| 16 | + </div> | ||
| 17 | + </div> | ||
| 18 | + <div class="top-right"> | ||
| 19 | + <img :src="printPayFeeInfo.qrImg" width="100px" height="100px"> | ||
| 20 | + </div> | ||
| 21 | + </div> | ||
| 22 | + | ||
| 23 | + <div class="context-1"> | ||
| 24 | + <table class="table vc-table-border" style="color:#000;font-size:20px"> | ||
| 25 | + <thead> | ||
| 26 | + <tr> | ||
| 27 | + <th scope="col" class="text-center" width="80px"><span><vc:i18n name="费用名称" namespace="printPayFeeBangTai"></vc:i18n></span></th> | ||
| 28 | + <th scope="col" class="text-center"><span><vc:i18n name="起始日期" namespace="printPayFeeBangTai"></vc:i18n></span></th> | ||
| 29 | + <th scope="col" class="text-center"><span><vc:i18n name="结束日期" namespace="printPayFeeBangTai"></vc:i18n></span></th> | ||
| 30 | + <th scope="col" class="text-center"><span><vc:i18n name="上期读数" namespace="printPayFeeBangTai"></vc:i18n></span></th> | ||
| 31 | + <th scope="col" class="text-center"><span><vc:i18n name="本期读数" namespace="printPayFeeBangTai"></vc:i18n></span></th> | ||
| 32 | + <th scope="col" class="text-center"><span><vc:i18n name="本期用量" namespace="printPayFeeBangTai"></vc:i18n></span></th> | ||
| 33 | + <th scope="col" class="text-center"><span><vc:i18n name="单位" namespace="printPayFeeBangTai"></vc:i18n></span></th> | ||
| 34 | + <th scope="col" class="text-center"><span><vc:i18n name="单价" namespace="printPayFeeBangTai"></vc:i18n></span></th> | ||
| 35 | + <th scope="col" class="text-center"><span><vc:i18n name="小计(元)" namespace="printPayFeeBangTai"></vc:i18n></span></th> | ||
| 36 | + </tr> | ||
| 37 | + </thead> | ||
| 38 | + <tbody class="vc-table-border" style="color:#000;font-size:20px"> | ||
| 39 | + <tr v-for="(item,index) in printPayFeeInfo.fees" class="vc-table-border"> | ||
| 40 | + <td scope="row" class="text-center">{{item.feeName}}</td> | ||
| 41 | + <td class="text-center">{{vc.dateFormat(item.startTime)}}</td> | ||
| 42 | + <td class="text-center">{{vc.dateFormat(item.endTime)}}</td> | ||
| 43 | + <td class="text-center" v-if="item.preDegrees">{{item.preDegrees}} </td> | ||
| 44 | + <td class="text-center" v-else>-</td> | ||
| 45 | + <td class="text-center" v-if="item.preDegrees">{{item.curDegrees}}</td> | ||
| 46 | + <td class="text-center" v-else>-</td> | ||
| 47 | + <td class="text-center" v-if="item.preDegrees">{{item.curDegrees - item.preDegrees}}</td> | ||
| 48 | + <td class="text-center" v-else>-</td> | ||
| 49 | + <td class="text-center">{{item.units}}</td> | ||
| 50 | + <td class="text-center">{{item.squarePrice}}</td> | ||
| 51 | + <td class="text-center">{{item.amount}}</td> | ||
| 52 | + </tr> | ||
| 53 | + <tr> | ||
| 54 | + <td colspan="5" class="text-right "><span><vc:i18n name="合计:" namespace="printPayFeeBangTai"></vc:i18n></span></td> | ||
| 55 | + <td colspan="3" class="text-center ">{{vc.changeNumMoneyToChinese(printPayFeeInfo.amount)}} | ||
| 56 | + </td> | ||
| 57 | + <td class="text-center ">{{printPayFeeInfo.amount}}</td> | ||
| 58 | + </tr> | ||
| 59 | + <tr> | ||
| 60 | + <td scope="row" class="text-center">物业费预存日期</td> | ||
| 61 | + <td scope="row" class="text-center"></td> | ||
| 62 | + <td scope="row" class="text-center">上期预存</td> | ||
| 63 | + <td scope="row" class="text-center">0.00</td> | ||
| 64 | + <td scope="row" class="text-center">预存剩余</td> | ||
| 65 | + <td scope="row" class="text-center">0.00</td> | ||
| 66 | + <td colspan="2" scope="row" class="text-center">抵扣预存后应缴</td> | ||
| 67 | + <td scope="row" class="text-center">{{printPayFeeInfo.amount}}</td> | ||
| 68 | + </tr> | ||
| 69 | + <tr height="60px"> | ||
| 70 | + <td scope="row" class="text-center">备注1</td> | ||
| 71 | + <td colspan="8"> | ||
| 72 | + <p> | ||
| 73 | + <!-- {{printPayFeeInfo.content}} --> | ||
| 74 | + <div v-html="printPayFeeInfo.content"></div> | ||
| 75 | + </p> | ||
| 76 | + </td> | ||
| 77 | + | ||
| 78 | + </tr> | ||
| 79 | + <tr height="60px"> | ||
| 80 | + <td scope="row" class="text-center">备注2</td> | ||
| 81 | + <td colspan="8"> | ||
| 82 | + <p> | ||
| 83 | + | ||
| 84 | + </p> | ||
| 85 | + </td> | ||
| 86 | + | ||
| 87 | + </tr> | ||
| 88 | + </tbody> | ||
| 89 | + </table> | ||
| 90 | + </div> | ||
| 91 | + <div class="flex justify-around " style="color:#000;font-size:20px"> | ||
| 92 | + <div style="width: 20%;">制单人:{{printPayFeeInfo.userName}}</div> | ||
| 93 | + <div style="width: 20%;">复核人:</div> | ||
| 94 | + <div style="width: 20%;">客服管家:</div> | ||
| 95 | + <div style="width: 20%;">缴费方式:{{printPayFeeInfo.fees && printPayFeeInfo.fees.length>0?printPayFeeInfo.fees[0].primeRate:'无'}}</div> | ||
| 96 | + </div> | ||
| 97 | + <div class="flex justify-around " style="color:#000;font-size:20px"> | ||
| 98 | + <div style="width: 20%;">日期:{{vc.dateFormat(new Date())}}</div> | ||
| 99 | + <div style="width: 20%;"></div> | ||
| 100 | + <div style="width: 20%;">手机/微信号:</div> | ||
| 101 | + <div style="width: 20%;">实缴日期:{{printPayFeeInfo.feeTime}}</div> | ||
| 102 | + </div> | ||
| 103 | + <div class="text-right margin-top" style="color:#000;font-size:20px"> | ||
| 104 | + <div>{{printPayFeeInfo.storeName}}</div> | ||
| 105 | + <div>物业服务中心</div> | ||
| 106 | + </div> | ||
| 107 | + <div class="text-right" id="print-btn"> | ||
| 108 | + <button class="btn btn-primary float-right" type="button" v-on:click="_printPurchaseApplyDiv()"> | ||
| 109 | + <i class="fa fa-check"></i> 打印 | ||
| 110 | + </button> | ||
| 111 | + <button type="button" class="btn btn-warning float-right" style="margin-right:20px;" v-on:click="_closePage()"><span><vc:i18n name="取消" namespace="printPayFeeBangTai"></vc:i18n></span> | ||
| 112 | + </button> | ||
| 113 | + </div> | ||
| 114 | +</div> | ||
| 115 | +``` | ||
| 116 | +js | ||
| 117 | +```js | ||
| 118 | +(function(vc) { | ||
| 119 | + | ||
| 120 | + vc.extends({ | ||
| 121 | + data: { | ||
| 122 | + printPayFeeInfo: { | ||
| 123 | + communityName: '', | ||
| 124 | + receiptId: '', | ||
| 125 | + receiptIds: '', | ||
| 126 | + detailIds: '', | ||
| 127 | + roomName: '', | ||
| 128 | + amount: 0.00, | ||
| 129 | + fees: [], | ||
| 130 | + feeTime: '', | ||
| 131 | + wechatName: '', | ||
| 132 | + content: '', | ||
| 133 | + qrImg: '', | ||
| 134 | + payObjName: '', | ||
| 135 | + feeReceipt: [], | ||
| 136 | + apply: 'N', | ||
| 137 | + userName: vc.getData('/nav/getUserInfo').name, | ||
| 138 | + storeName: '', | ||
| 139 | + roomInfo: { | ||
| 140 | + | ||
| 141 | + } | ||
| 142 | + }, | ||
| 143 | + printFlag: '0' | ||
| 144 | + }, | ||
| 145 | + _initMethod: function() { | ||
| 146 | + //vc.component._initPrintPurchaseApplyDateInfo(); | ||
| 147 | + | ||
| 148 | + $that.printPayFeeInfo.receiptId = vc.getParam('receiptId'); | ||
| 149 | + $that.printPayFeeInfo.receiptIds = vc.getParam('receiptIds'); | ||
| 150 | + $that.printPayFeeInfo.detailIds = vc.getParam('detailIds'); | ||
| 151 | + $that.printPayFeeInfo.apply = vc.getParam('apply'); | ||
| 152 | + $that.printPayFeeInfo.merge = vc.getParam('merge'); | ||
| 153 | + | ||
| 154 | + | ||
| 155 | + //$that.printPayFeeInfo.feeTime = vc.dateTimeFormat(new Date()); | ||
| 156 | + | ||
| 157 | + $that.printPayFeeInfo.communityName = vc.getCurrentCommunity().name; | ||
| 158 | + | ||
| 159 | + $that._loadReceipt(); | ||
| 160 | + | ||
| 161 | + $that._loadPrintSpec(); | ||
| 162 | + }, | ||
| 163 | + _initEvent: function() { | ||
| 164 | + | ||
| 165 | + | ||
| 166 | + }, | ||
| 167 | + methods: { | ||
| 168 | + _initPayFee: function() { | ||
| 169 | + | ||
| 170 | + }, | ||
| 171 | + _loadReceipt: function() { | ||
| 172 | + | ||
| 173 | + var param = { | ||
| 174 | + params: { | ||
| 175 | + page: 1, | ||
| 176 | + row: 30, | ||
| 177 | + receiptId: $that.printPayFeeInfo.receiptId, | ||
| 178 | + receiptIds: $that.printPayFeeInfo.receiptIds, | ||
| 179 | + detailIds: $that.printPayFeeInfo.detailIds, | ||
| 180 | + communityId: vc.getCurrentCommunity().communityId | ||
| 181 | + } | ||
| 182 | + }; | ||
| 183 | + | ||
| 184 | + //发送get请求 | ||
| 185 | + vc.http.apiGet('/feeReceipt/queryFeeReceipt', | ||
| 186 | + param, | ||
| 187 | + function(json, res) { | ||
| 188 | + var _feeReceiptManageInfo = JSON.parse(json); | ||
| 189 | + let _feeReceipt = _feeReceiptManageInfo.data; | ||
| 190 | + let _amount = 0; | ||
| 191 | + _feeReceipt.forEach(item => { | ||
| 192 | + _amount += parseFloat(item.amount) | ||
| 193 | + }); | ||
| 194 | + | ||
| 195 | + $that.printPayFeeInfo.amount = _amount.toFixed(2); | ||
| 196 | + $that.printPayFeeInfo.roomName = _feeReceipt[0].objName; | ||
| 197 | + $that.printPayFeeInfo.feeTime = _feeReceipt[0].createTime; | ||
| 198 | + //$that.printPayFeeInfo.receiptNum = _feeReceipt[0].receiptId; | ||
| 199 | + $that.printPayFeeInfo.payObjName = _feeReceipt[0].payObjName; | ||
| 200 | + $that.printPayFeeInfo.storeName = _feeReceipt[0].storeName; | ||
| 201 | + $that.printPayFeeInfo.feeReceipt = _feeReceipt; | ||
| 202 | + | ||
| 203 | + $that.listRoom(_feeReceipt[0].objId); | ||
| 204 | + | ||
| 205 | + $that._loadReceiptDetail(); | ||
| 206 | + | ||
| 207 | + }, | ||
| 208 | + function(errInfo, error) { | ||
| 209 | + console.log('请求失败处理'); | ||
| 210 | + } | ||
| 211 | + ); | ||
| 212 | + }, | ||
| 213 | + _loadReceiptDetail: function() { | ||
| 214 | + | ||
| 215 | + let param = { | ||
| 216 | + params: { | ||
| 217 | + page: 1, | ||
| 218 | + row: 100, | ||
| 219 | + receiptId: $that.printPayFeeInfo.receiptId, | ||
| 220 | + receiptIds: $that.printPayFeeInfo.receiptIds, | ||
| 221 | + detailIds: $that.printPayFeeInfo.detailIds, | ||
| 222 | + communityId: vc.getCurrentCommunity().communityId, | ||
| 223 | + mergeFee:$that.printPayFeeInfo.merge | ||
| 224 | + } | ||
| 225 | + }; | ||
| 226 | + | ||
| 227 | + //发送get请求 | ||
| 228 | + vc.http.apiGet('/feeReceipt/queryFeeReceiptDetail', | ||
| 229 | + param, | ||
| 230 | + function(json, res) { | ||
| 231 | + var _feeReceiptManageInfo = JSON.parse(json); | ||
| 232 | + let _feeReceiptDetails = _feeReceiptManageInfo.data; | ||
| 233 | + $that.printPayFeeInfo.receiptNum = _feeReceiptDetails[0].receiptId + "(" + _feeReceiptDetails[0].payOrderId + ")"; | ||
| 234 | + _feeReceiptDetails.forEach(item => { | ||
| 235 | + $that.printPayFeeInfo.feeReceipt.forEach(im => { | ||
| 236 | + if (item.receiptId == im.receiptId) { | ||
| 237 | + item.objName = im.objName; | ||
| 238 | + item.feeTypeCd = im.feeTypeCd; | ||
| 239 | + } | ||
| 240 | + }) | ||
| 241 | + }) | ||
| 242 | + $that.printPayFeeInfo.fees = _feeReceiptDetails; | ||
| 243 | + | ||
| 244 | + | ||
| 245 | + }, | ||
| 246 | + function(errInfo, error) { | ||
| 247 | + console.log('请求失败处理'); | ||
| 248 | + } | ||
| 249 | + ); | ||
| 250 | + }, | ||
| 251 | + _loadPrintSpec: function() { | ||
| 252 | + var param = { | ||
| 253 | + params: { | ||
| 254 | + page: 1, | ||
| 255 | + row: 1, | ||
| 256 | + specCd: 2020, | ||
| 257 | + communityId: vc.getCurrentCommunity().communityId | ||
| 258 | + } | ||
| 259 | + }; | ||
| 260 | + | ||
| 261 | + //发送get请求 | ||
| 262 | + vc.http.apiGet('/feePrintSpec/queryFeePrintSpec', | ||
| 263 | + param, | ||
| 264 | + function(json, res) { | ||
| 265 | + var _json = JSON.parse(json); | ||
| 266 | + var _data = _json.data; | ||
| 267 | + if (_data.length > 0) { | ||
| 268 | + $that.printPayFeeInfo.content = _data[0].content; | ||
| 269 | + $that.printPayFeeInfo.qrImg = _data[0].qrImg; | ||
| 270 | + if (_data[0].printName) { | ||
| 271 | + $that.printPayFeeInfo.communityName = _data[0].printName; | ||
| 272 | + } | ||
| 273 | + } | ||
| 274 | + }, | ||
| 275 | + function(errInfo, error) { | ||
| 276 | + console.log('请求失败处理'); | ||
| 277 | + } | ||
| 278 | + ); | ||
| 279 | + | ||
| 280 | + }, | ||
| 281 | + | ||
| 282 | + _printPurchaseApplyDiv: function() { | ||
| 283 | + | ||
| 284 | + $that.printFlag = '1'; | ||
| 285 | + console.log('console.log($that.printFlag);', $that.printFlag); | ||
| 286 | + document.getElementById("print-btn").style.display = "none"; //隐藏 | ||
| 287 | + | ||
| 288 | + window.print(); | ||
| 289 | + //$that.printFlag = false; | ||
| 290 | + window.opener = null; | ||
| 291 | + window.close(); | ||
| 292 | + }, | ||
| 293 | + _closePage: function() { | ||
| 294 | + window.opener = null; | ||
| 295 | + window.close(); | ||
| 296 | + }, | ||
| 297 | + | ||
| 298 | + listRoom: function(_roomId) { | ||
| 299 | + let param = { | ||
| 300 | + params: { | ||
| 301 | + page: 1, | ||
| 302 | + row: 1, | ||
| 303 | + communityId: vc.getCurrentCommunity().communityId, | ||
| 304 | + roomId: _roomId | ||
| 305 | + } | ||
| 306 | + }; | ||
| 307 | + //发送get请求 | ||
| 308 | + vc.http.apiGet('/room.queryRooms', | ||
| 309 | + param, | ||
| 310 | + function(json, res) { | ||
| 311 | + let listRoomData = JSON.parse(json); | ||
| 312 | + if (!listRoomData.rooms || listRoomData.rooms.length < 1) { | ||
| 313 | + return; | ||
| 314 | + } | ||
| 315 | + vc.component.printPayFeeInfo.roomInfo = listRoomData.rooms[0]; | ||
| 316 | + }, | ||
| 317 | + function(errInfo, error) { | ||
| 318 | + console.log('请求失败处理'); | ||
| 319 | + } | ||
| 320 | + ); | ||
| 321 | + }, | ||
| 322 | + | ||
| 323 | + } | ||
| 324 | + }); | ||
| 325 | + | ||
| 326 | +})(window.vc); | ||
| 327 | +``` |
src/views/fee/printPayFeeTianlin.vue
0 → 100644
| 1 | +<template> | ||
| 2 | + <div class="print-pay-fee-tianlin-container"> | ||
| 3 | + <el-row class="top-section"> | ||
| 4 | + <el-col :span="20"> | ||
| 5 | + <h1 class="text-center" style="color:#000;font-weight: 400;"> | ||
| 6 | + {{ printPayFeeInfo.storeName }}{{ $t('printPayFeeTianlin.receiptTitle') }} | ||
| 7 | + </h1> | ||
| 8 | + <el-row style="color:#000;font-size:20px"> | ||
| 9 | + <el-col :span="8">{{ $t('printPayFeeTianlin.communityName') }}:{{ printPayFeeInfo.communityName }}</el-col> | ||
| 10 | + <el-col :span="8">{{ $t('printPayFeeTianlin.buildingNum') }}:{{ printPayFeeInfo.roomInfo.floorNum }}{{ $t('printPayFeeTianlin.building') }}</el-col> | ||
| 11 | + <el-col :span="8">{{ $t('printPayFeeTianlin.buildingArea') }}:{{ printPayFeeInfo.fees && printPayFeeInfo.fees.length > 0 ? printPayFeeInfo.fees[0].area : $t('printPayFeeTianlin.none') }}</el-col> | ||
| 12 | + </el-row> | ||
| 13 | + <el-row style="color:#000;font-size:20px"> | ||
| 14 | + <el-col :span="8">{{ $t('printPayFeeTianlin.ownerName') }}:{{ printPayFeeInfo.payObjName }}</el-col> | ||
| 15 | + <el-col :span="8">{{ $t('printPayFeeTianlin.roomNum') }}:{{ printPayFeeInfo.roomInfo.roomNum }}</el-col> | ||
| 16 | + <el-col :span="8">{{ $t('printPayFeeTianlin.houseCode') }}:{{ printPayFeeInfo.fees && printPayFeeInfo.fees.length > 0 ? printPayFeeInfo.fees[0].objName : $t('printPayFeeTianlin.none') }}</el-col> | ||
| 17 | + </el-row> | ||
| 18 | + </el-col> | ||
| 19 | + <el-col :span="4" class="text-center"> | ||
| 20 | + <img v-if="printPayFeeInfo.qrImg" :src="printPayFeeInfo.qrImg" width="100px" height="100px"> | ||
| 21 | + </el-col> | ||
| 22 | + </el-row> | ||
| 23 | + | ||
| 24 | + <table class="table vc-table-border" style="color:#000;font-size:20px"> | ||
| 25 | + <thead> | ||
| 26 | + <tr> | ||
| 27 | + <th class="text-center" width="80px">{{ $t('printPayFeeTianlin.feeName') }}</th> | ||
| 28 | + <th class="text-center">{{ $t('printPayFeeTianlin.startDate') }}</th> | ||
| 29 | + <th class="text-center">{{ $t('printPayFeeTianlin.endDate') }}</th> | ||
| 30 | + <th class="text-center">{{ $t('printPayFeeTianlin.preDegrees') }}</th> | ||
| 31 | + <th class="text-center">{{ $t('printPayFeeTianlin.curDegrees') }}</th> | ||
| 32 | + <th class="text-center">{{ $t('printPayFeeTianlin.usage') }}</th> | ||
| 33 | + <th class="text-center">{{ $t('printPayFeeTianlin.unit') }}</th> | ||
| 34 | + <th class="text-center">{{ $t('printPayFeeTianlin.unitPrice') }}</th> | ||
| 35 | + <th class="text-center">{{ $t('printPayFeeTianlin.subtotal') }}</th> | ||
| 36 | + </tr> | ||
| 37 | + </thead> | ||
| 38 | + <tbody class="vc-table-border" style="color:#000;font-size:20px"> | ||
| 39 | + <tr v-for="(item, index) in printPayFeeInfo.fees" :key="index" class="vc-table-border"> | ||
| 40 | + <td class="text-center">{{ item.feeName }}</td> | ||
| 41 | + <td class="text-center">{{ dateFormat(item.startTime) }}</td> | ||
| 42 | + <td class="text-center">{{ dateFormat(item.endTime) }}</td> | ||
| 43 | + <td class="text-center" v-if="item.preDegrees">{{ item.preDegrees }}</td> | ||
| 44 | + <td class="text-center" v-else>-</td> | ||
| 45 | + <td class="text-center" v-if="item.preDegrees">{{ item.curDegrees }}</td> | ||
| 46 | + <td class="text-center" v-else>-</td> | ||
| 47 | + <td class="text-center" v-if="item.preDegrees">{{ item.curDegrees - item.preDegrees }}</td> | ||
| 48 | + <td class="text-center" v-else>-</td> | ||
| 49 | + <td class="text-center">{{ item.units }}</td> | ||
| 50 | + <td class="text-center">{{ item.squarePrice }}</td> | ||
| 51 | + <td class="text-center">{{ item.amount }}</td> | ||
| 52 | + </tr> | ||
| 53 | + <tr> | ||
| 54 | + <td colspan="5" class="text-right">{{ $t('printPayFeeTianlin.total') }}</td> | ||
| 55 | + <td colspan="3" class="text-center">{{ changeNumMoneyToChinese(printPayFeeInfo.amount) }}</td> | ||
| 56 | + <td class="text-center">{{ printPayFeeInfo.amount }}</td> | ||
| 57 | + </tr> | ||
| 58 | + <tr> | ||
| 59 | + <td class="text-center">{{ $t('printPayFeeTianlin.advanceDate') }}</td> | ||
| 60 | + <td class="text-center"></td> | ||
| 61 | + <td class="text-center">{{ $t('printPayFeeTianlin.lastAdvance') }}</td> | ||
| 62 | + <td class="text-center">0.00</td> | ||
| 63 | + <td class="text-center">{{ $t('printPayFeeTianlin.advanceRemain') }}</td> | ||
| 64 | + <td class="text-center">0.00</td> | ||
| 65 | + <td colspan="2" class="text-center">{{ $t('printPayFeeTianlin.payableAfterDeduction') }}</td> | ||
| 66 | + <td class="text-center">{{ printPayFeeInfo.amount }}</td> | ||
| 67 | + </tr> | ||
| 68 | + <tr height="60px"> | ||
| 69 | + <td class="text-center">{{ $t('printPayFeeTianlin.remark1') }}</td> | ||
| 70 | + <td colspan="8"> | ||
| 71 | + <div v-html="printPayFeeInfo.content"></div> | ||
| 72 | + </td> | ||
| 73 | + </tr> | ||
| 74 | + <tr height="60px"> | ||
| 75 | + <td class="text-center">{{ $t('printPayFeeTianlin.remark2') }}</td> | ||
| 76 | + <td colspan="8"> | ||
| 77 | + <p></p> | ||
| 78 | + </td> | ||
| 79 | + </tr> | ||
| 80 | + </tbody> | ||
| 81 | + </table> | ||
| 82 | + | ||
| 83 | + <el-row style="color:#000;font-size:20px;margin-top:10px;"> | ||
| 84 | + <el-col :span="6">{{ $t('printPayFeeTianlin.creator') }}:{{ printPayFeeInfo.userName }}</el-col> | ||
| 85 | + <el-col :span="6">{{ $t('printPayFeeTianlin.reviewer') }}:</el-col> | ||
| 86 | + <el-col :span="6">{{ $t('printPayFeeTianlin.butler') }}:</el-col> | ||
| 87 | + <el-col :span="6">{{ $t('printPayFeeTianlin.paymentMethod') }}:{{ printPayFeeInfo.fees && printPayFeeInfo.fees.length > 0 ? printPayFeeInfo.fees[0].primeRate : $t('printPayFeeTianlin.none') }}</el-col> | ||
| 88 | + </el-row> | ||
| 89 | + <el-row style="color:#000;font-size:20px;margin-top:10px;"> | ||
| 90 | + <el-col :span="6">{{ $t('printPayFeeTianlin.date') }}:{{ currentDate }}</el-col> | ||
| 91 | + <el-col :span="6"></el-col> | ||
| 92 | + <el-col :span="6">{{ $t('printPayFeeTianlin.phoneWechat') }}:</el-col> | ||
| 93 | + <el-col :span="6">{{ $t('printPayFeeTianlin.actualPayDate') }}:{{ printPayFeeInfo.feeTime }}</el-col> | ||
| 94 | + </el-row> | ||
| 95 | + <div class="text-right margin-top" style="color:#000;font-size:20px"> | ||
| 96 | + <div>{{ printPayFeeInfo.storeName }}</div> | ||
| 97 | + <div>{{ $t('printPayFeeTianlin.serviceCenter') }}</div> | ||
| 98 | + </div> | ||
| 99 | + | ||
| 100 | + <el-row id="print-btn"> | ||
| 101 | + <el-col :span="24" class="text-right"> | ||
| 102 | + <el-button type="primary" class="float-right" @click="handlePrint"> | ||
| 103 | + <i class="fa fa-check"></i> {{ $t('common.print') }} | ||
| 104 | + </el-button> | ||
| 105 | + <el-button type="warning" class="float-right" style="margin-right:20px;" @click="handleClose"> | ||
| 106 | + {{ $t('common.cancel') }} | ||
| 107 | + </el-button> | ||
| 108 | + </el-col> | ||
| 109 | + </el-row> | ||
| 110 | + </div> | ||
| 111 | +</template> | ||
| 112 | + | ||
| 113 | +<script> | ||
| 114 | +import { getCommunityId, getCommunityName } from '@/api/community/communityApi' | ||
| 115 | +import { queryFeeReceipt, queryFeeReceiptDetail, queryFeePrintSpec, queryRooms } from '@/api/fee/printPayFeeApi' | ||
| 116 | +import { getUserName } from '@/api/user/userApi' | ||
| 117 | +import { dateFormat } from '@/utils/dateUtil' | ||
| 118 | +import { changeNumMoneyToChinese } from '@/utils/moneyUtil' | ||
| 119 | + | ||
| 120 | +export default { | ||
| 121 | + name: 'PrintPayFeeTianlin', | ||
| 122 | + data() { | ||
| 123 | + return { | ||
| 124 | + printPayFeeInfo: { | ||
| 125 | + communityName: '', | ||
| 126 | + receiptId: '', | ||
| 127 | + receiptIds: '', | ||
| 128 | + detailIds: '', | ||
| 129 | + roomName: '', | ||
| 130 | + amount: 0.00, | ||
| 131 | + fees: [], | ||
| 132 | + feeTime: '', | ||
| 133 | + wechatName: '', | ||
| 134 | + content: '', | ||
| 135 | + qrImg: '', | ||
| 136 | + payObjName: '', | ||
| 137 | + feeReceipt: [], | ||
| 138 | + apply: 'N', | ||
| 139 | + userName: '', | ||
| 140 | + storeName: '', | ||
| 141 | + merge: '', | ||
| 142 | + roomInfo: { | ||
| 143 | + floorNum: '', | ||
| 144 | + roomNum: '' | ||
| 145 | + } | ||
| 146 | + }, | ||
| 147 | + printFlag: '0', | ||
| 148 | + communityId: '', | ||
| 149 | + currentDate: '' | ||
| 150 | + } | ||
| 151 | + }, | ||
| 152 | + created() { | ||
| 153 | + this.communityId = getCommunityId() | ||
| 154 | + this.printPayFeeInfo.userName = getUserName() | ||
| 155 | + this.currentDate = dateFormat(new Date()) | ||
| 156 | + this.initData() | ||
| 157 | + }, | ||
| 158 | + methods: { | ||
| 159 | + initData() { | ||
| 160 | + this.printPayFeeInfo.receiptId = this.$route.query.receiptId | ||
| 161 | + this.printPayFeeInfo.receiptIds = this.$route.query.receiptIds | ||
| 162 | + this.printPayFeeInfo.detailIds = this.$route.query.detailIds | ||
| 163 | + this.printPayFeeInfo.apply = this.$route.query.apply || 'N' | ||
| 164 | + this.printPayFeeInfo.merge = this.$route.query.merge | ||
| 165 | + this.printPayFeeInfo.communityName = getCommunityName() | ||
| 166 | + | ||
| 167 | + this.loadReceipt() | ||
| 168 | + this.loadPrintSpec() | ||
| 169 | + }, | ||
| 170 | + loadReceipt() { | ||
| 171 | + const params = { | ||
| 172 | + page: 1, | ||
| 173 | + row: 30, | ||
| 174 | + receiptId: this.printPayFeeInfo.receiptId, | ||
| 175 | + receiptIds: this.printPayFeeInfo.receiptIds, | ||
| 176 | + detailIds: this.printPayFeeInfo.detailIds, | ||
| 177 | + communityId: this.communityId | ||
| 178 | + } | ||
| 179 | + | ||
| 180 | + queryFeeReceipt(params).then(response => { | ||
| 181 | + const feeReceipt = response.data | ||
| 182 | + let amount = 0 | ||
| 183 | + feeReceipt.forEach(item => { | ||
| 184 | + amount += parseFloat(item.amount) | ||
| 185 | + }) | ||
| 186 | + | ||
| 187 | + this.printPayFeeInfo.amount = amount.toFixed(2) | ||
| 188 | + this.printPayFeeInfo.roomName = feeReceipt[0].objName | ||
| 189 | + this.printPayFeeInfo.feeTime = feeReceipt[0].createTime | ||
| 190 | + this.printPayFeeInfo.payObjName = feeReceipt[0].payObjName | ||
| 191 | + this.printPayFeeInfo.storeName = feeReceipt[0].storeName || '' | ||
| 192 | + this.printPayFeeInfo.feeReceipt = feeReceipt | ||
| 193 | + | ||
| 194 | + // 查询房屋信息 | ||
| 195 | + this.loadRoom(feeReceipt[0].objId) | ||
| 196 | + | ||
| 197 | + this.loadReceiptDetail() | ||
| 198 | + }).catch(error => { | ||
| 199 | + console.error('请求失败处理', error) | ||
| 200 | + }) | ||
| 201 | + }, | ||
| 202 | + loadReceiptDetail() { | ||
| 203 | + const params = { | ||
| 204 | + page: 1, | ||
| 205 | + row: 100, | ||
| 206 | + receiptId: this.printPayFeeInfo.receiptId, | ||
| 207 | + receiptIds: this.printPayFeeInfo.receiptIds, | ||
| 208 | + detailIds: this.printPayFeeInfo.detailIds, | ||
| 209 | + communityId: this.communityId, | ||
| 210 | + mergeFee: this.printPayFeeInfo.merge | ||
| 211 | + } | ||
| 212 | + | ||
| 213 | + queryFeeReceiptDetail(params).then(response => { | ||
| 214 | + const feeReceiptDetails = response.data | ||
| 215 | + | ||
| 216 | + feeReceiptDetails.forEach(item => { | ||
| 217 | + this.printPayFeeInfo.feeReceipt.forEach(im => { | ||
| 218 | + if (item.receiptId == im.receiptId) { | ||
| 219 | + item.objName = im.objName | ||
| 220 | + item.feeTypeCd = im.feeTypeCd | ||
| 221 | + } | ||
| 222 | + }) | ||
| 223 | + }) | ||
| 224 | + this.printPayFeeInfo.fees = feeReceiptDetails | ||
| 225 | + }).catch(error => { | ||
| 226 | + console.error('请求失败处理', error) | ||
| 227 | + }) | ||
| 228 | + }, | ||
| 229 | + loadPrintSpec() { | ||
| 230 | + const params = { | ||
| 231 | + page: 1, | ||
| 232 | + row: 1, | ||
| 233 | + specCd: 2020, | ||
| 234 | + communityId: this.communityId | ||
| 235 | + } | ||
| 236 | + | ||
| 237 | + queryFeePrintSpec(params).then(response => { | ||
| 238 | + const data = response.data | ||
| 239 | + if (data.length > 0) { | ||
| 240 | + this.printPayFeeInfo.content = data[0].content | ||
| 241 | + this.printPayFeeInfo.qrImg = data[0].qrImg | ||
| 242 | + if (data[0].printName) { | ||
| 243 | + this.printPayFeeInfo.communityName = data[0].printName | ||
| 244 | + } | ||
| 245 | + } | ||
| 246 | + }).catch(error => { | ||
| 247 | + console.error('请求失败处理', error) | ||
| 248 | + }) | ||
| 249 | + }, | ||
| 250 | + loadRoom(roomId) { | ||
| 251 | + const params = { | ||
| 252 | + page: 1, | ||
| 253 | + row: 1, | ||
| 254 | + roomId: roomId | ||
| 255 | + } | ||
| 256 | + | ||
| 257 | + queryRooms(params).then(response => { | ||
| 258 | + const rooms = response.rooms | ||
| 259 | + if (rooms && rooms.length > 0) { | ||
| 260 | + this.printPayFeeInfo.roomInfo = rooms[0] | ||
| 261 | + } | ||
| 262 | + }).catch(error => { | ||
| 263 | + console.error('查询房屋失败', error) | ||
| 264 | + }) | ||
| 265 | + }, | ||
| 266 | + dateFormat(date) { | ||
| 267 | + if (!date) return '' | ||
| 268 | + return dateFormat(date) | ||
| 269 | + }, | ||
| 270 | + changeNumMoneyToChinese, | ||
| 271 | + handlePrint() { | ||
| 272 | + this.printFlag = '1' | ||
| 273 | + document.getElementById("print-btn").style.display = "none" | ||
| 274 | + window.print() | ||
| 275 | + window.opener = null | ||
| 276 | + window.close() | ||
| 277 | + }, | ||
| 278 | + handleClose() { | ||
| 279 | + window.opener = null | ||
| 280 | + window.close() | ||
| 281 | + } | ||
| 282 | + } | ||
| 283 | +} | ||
| 284 | +</script> | ||
| 285 | + | ||
| 286 | +<style scoped> | ||
| 287 | +.print-pay-fee-tianlin-container { | ||
| 288 | + padding: 20px; | ||
| 289 | +} | ||
| 290 | + | ||
| 291 | +.top-section { | ||
| 292 | + margin-bottom: 20px; | ||
| 293 | +} | ||
| 294 | + | ||
| 295 | +.text-center { | ||
| 296 | + text-align: center; | ||
| 297 | +} | ||
| 298 | + | ||
| 299 | +.text-right { | ||
| 300 | + text-align: right; | ||
| 301 | +} | ||
| 302 | + | ||
| 303 | +.float-right { | ||
| 304 | + float: right; | ||
| 305 | +} | ||
| 306 | + | ||
| 307 | +.margin-top { | ||
| 308 | + margin-top: 20px; | ||
| 309 | +} | ||
| 310 | + | ||
| 311 | +.table { | ||
| 312 | + width: 100%; | ||
| 313 | + margin-bottom: 1rem; | ||
| 314 | + color: #212529; | ||
| 315 | + border-collapse: collapse; | ||
| 316 | +} | ||
| 317 | + | ||
| 318 | +.vc-table-border { | ||
| 319 | + border: 1px solid #000; | ||
| 320 | +} | ||
| 321 | + | ||
| 322 | +.vc-table-border th, | ||
| 323 | +.vc-table-border td { | ||
| 324 | + border: 1px solid #000; | ||
| 325 | + padding: 8px; | ||
| 326 | +} | ||
| 327 | + | ||
| 328 | +@media print { | ||
| 329 | + #print-btn { | ||
| 330 | + display: none !important; | ||
| 331 | + } | ||
| 332 | +} | ||
| 333 | +</style> | ||
| 334 | + |
src/views/fee/printPayFeeTianlinLang.js
0 → 100644
| 1 | +export const messages = { | ||
| 2 | + en: { | ||
| 3 | + printPayFeeTianlin: { | ||
| 4 | + receiptTitle: ' Receipt', | ||
| 5 | + communityName: 'Community Name', | ||
| 6 | + buildingNum: 'Building No.', | ||
| 7 | + building: '', | ||
| 8 | + buildingArea: 'Building Area', | ||
| 9 | + ownerName: 'Owner Name', | ||
| 10 | + roomNum: 'Room No.', | ||
| 11 | + houseCode: 'House Code', | ||
| 12 | + none: 'None', | ||
| 13 | + feeName: 'Fee Name', | ||
| 14 | + startDate: 'Start Date', | ||
| 15 | + endDate: 'End Date', | ||
| 16 | + preDegrees: 'Previous Reading', | ||
| 17 | + curDegrees: 'Current Reading', | ||
| 18 | + usage: 'Usage', | ||
| 19 | + unit: 'Unit', | ||
| 20 | + unitPrice: 'Unit Price', | ||
| 21 | + subtotal: 'Subtotal (Yuan)', | ||
| 22 | + total: 'Total:', | ||
| 23 | + advanceDate: 'Property Fee Advance Date', | ||
| 24 | + lastAdvance: 'Last Advance', | ||
| 25 | + advanceRemain: 'Advance Remaining', | ||
| 26 | + payableAfterDeduction: 'Payable After Deduction', | ||
| 27 | + remark1: 'Remark 1', | ||
| 28 | + remark2: 'Remark 2', | ||
| 29 | + creator: 'Creator', | ||
| 30 | + reviewer: 'Reviewer', | ||
| 31 | + butler: 'Customer Butler', | ||
| 32 | + paymentMethod: 'Payment Method', | ||
| 33 | + date: 'Date', | ||
| 34 | + phoneWechat: 'Phone/WeChat', | ||
| 35 | + actualPayDate: 'Actual Payment Date', | ||
| 36 | + serviceCenter: 'Property Service Center' | ||
| 37 | + } | ||
| 38 | + }, | ||
| 39 | + zh: { | ||
| 40 | + printPayFeeTianlin: { | ||
| 41 | + receiptTitle: '收据单', | ||
| 42 | + communityName: '小区名称', | ||
| 43 | + buildingNum: '栋号', | ||
| 44 | + building: '栋', | ||
| 45 | + buildingArea: '建筑面积', | ||
| 46 | + ownerName: '户主姓名', | ||
| 47 | + roomNum: '房号', | ||
| 48 | + houseCode: '房屋编号', | ||
| 49 | + none: '无', | ||
| 50 | + feeName: '费用名称', | ||
| 51 | + startDate: '起始日期', | ||
| 52 | + endDate: '结束日期', | ||
| 53 | + preDegrees: '上期读数', | ||
| 54 | + curDegrees: '本期读数', | ||
| 55 | + usage: '本期用量', | ||
| 56 | + unit: '单位', | ||
| 57 | + unitPrice: '单价', | ||
| 58 | + subtotal: '小计(元)', | ||
| 59 | + total: '合计:', | ||
| 60 | + advanceDate: '物业费预存日期', | ||
| 61 | + lastAdvance: '上期预存', | ||
| 62 | + advanceRemain: '预存剩余', | ||
| 63 | + payableAfterDeduction: '抵扣预存后应缴', | ||
| 64 | + remark1: '备注1', | ||
| 65 | + remark2: '备注2', | ||
| 66 | + creator: '制单人', | ||
| 67 | + reviewer: '复核人', | ||
| 68 | + butler: '客服管家', | ||
| 69 | + paymentMethod: '缴费方式', | ||
| 70 | + date: '日期', | ||
| 71 | + phoneWechat: '手机/微信号', | ||
| 72 | + actualPayDate: '实缴日期', | ||
| 73 | + serviceCenter: '物业服务中心' | ||
| 74 | + } | ||
| 75 | + } | ||
| 76 | +} | ||
| 77 | + |
src/views/fee/printPayFeeXiangyun.vue
0 → 100644
| 1 | +<template> | ||
| 2 | + <div class="print-pay-fee-xiangyun-container"> | ||
| 3 | + <div class="text-center"> | ||
| 4 | + <div style="color:#000;font-size:36px"> | ||
| 5 | + {{ printPayFeeInfo.communityName }} {{ printPayFeeInfo.apply == 'Y' ? $t('printPayFeeXiangyun.applyForm') : $t('printPayFeeXiangyun.receiptForm') }} | ||
| 6 | + </div> | ||
| 7 | + </div> | ||
| 8 | + <div style="color:#000;font-size:20px;text-align:right;margin-bottom:10px;"> | ||
| 9 | + <span>{{ $t('printPayFeeXiangyun.receiptNum') }}:{{ printPayFeeInfo.receiptNum }}</span> | ||
| 10 | + </div> | ||
| 11 | + <el-row style="color:#000;font-size:20px;margin-bottom:10px;"> | ||
| 12 | + <el-col :span="12" class="text-left"> | ||
| 13 | + <span>{{ $t('printPayFeeXiangyun.owner') }}:{{ printPayFeeInfo.payObjName }}</span> | ||
| 14 | + </el-col> | ||
| 15 | + <el-col :span="12" style="text-align:right;"> | ||
| 16 | + <span>{{ $t('printPayFeeXiangyun.payTime') }}:{{ printPayFeeInfo.feeTime }}</span> | ||
| 17 | + </el-col> | ||
| 18 | + </el-row> | ||
| 19 | + | ||
| 20 | + <table class="table vc-table-border" style="color:#000;font-size:20px"> | ||
| 21 | + <thead> | ||
| 22 | + <tr> | ||
| 23 | + <th scope="col" class="text-center" width="80px"> | ||
| 24 | + {{ $t('printPayFeeXiangyun.serialNumber') }} | ||
| 25 | + </th> | ||
| 26 | + <th scope="col" class="text-center"> | ||
| 27 | + {{ $t('printPayFeeXiangyun.feeItem') }} | ||
| 28 | + </th> | ||
| 29 | + <th scope="col" class="text-center"> | ||
| 30 | + {{ $t('printPayFeeXiangyun.houseCar') }} | ||
| 31 | + </th> | ||
| 32 | + <th scope="col" class="text-center"> | ||
| 33 | + {{ $t('printPayFeeXiangyun.feeRange') }} | ||
| 34 | + </th> | ||
| 35 | + <th scope="col" class="text-center"> | ||
| 36 | + {{ $t('printPayFeeXiangyun.cycle') }} | ||
| 37 | + </th> | ||
| 38 | + <th scope="col" class="text-center"> | ||
| 39 | + {{ $t('printPayFeeXiangyun.unitPriceFixed') }} | ||
| 40 | + </th> | ||
| 41 | + <th scope="col" class="text-center"> | ||
| 42 | + {{ $t('printPayFeeXiangyun.areaUsage') }} | ||
| 43 | + </th> | ||
| 44 | + <th scope="col" class="text-center"> | ||
| 45 | + {{ $t('printPayFeeXiangyun.paymentMethod') }} | ||
| 46 | + </th> | ||
| 47 | + <th scope="col" class="text-center"> | ||
| 48 | + {{ $t('printPayFeeXiangyun.amount') }} | ||
| 49 | + </th> | ||
| 50 | + <th scope="col" class="text-center"> | ||
| 51 | + {{ $t('printPayFeeXiangyun.discountAmount') }} | ||
| 52 | + </th> | ||
| 53 | + <th scope="col" class="text-center"> | ||
| 54 | + {{ $t('printPayFeeXiangyun.remark') }} | ||
| 55 | + </th> | ||
| 56 | + </tr> | ||
| 57 | + </thead> | ||
| 58 | + <tbody class="vc-table-border" style="color:#000;font-size:20px"> | ||
| 59 | + <tr v-for="(item, index) in printPayFeeInfo.fees" :key="index" class="vc-table-border"> | ||
| 60 | + <th scope="row" class="text-center">{{ index + 1 }}</th> | ||
| 61 | + <td class="text-center">{{ item.feeName }}</td> | ||
| 62 | + <td class="text-center">{{ item.objName }}</td> | ||
| 63 | + <td class="text-center" v-if="item.preDegrees"> | ||
| 64 | + {{ dateFormat(item.startTime) }}{{ $t('printPayFeeXiangyun.to') }}{{ dateFormat(item.endTime) }}<br /> | ||
| 65 | + {{ item.preDegrees }} {{ $t('printPayFeeXiangyun.to') }} {{ item.curDegrees }} | ||
| 66 | + </td> | ||
| 67 | + <!-- 根据山东需求 如果为押金时 显示为无--> | ||
| 68 | + <td class="text-center" v-else-if="item.feeTypeCd == '888800010006'"> | ||
| 69 | + {{ $t('printPayFeeXiangyun.none') }} | ||
| 70 | + </td> | ||
| 71 | + <td class="text-center" v-else> | ||
| 72 | + {{ dateFormat(item.startTime) }}{{ $t('printPayFeeXiangyun.to') }}{{ dateFormat(item.endTime) }} | ||
| 73 | + </td> | ||
| 74 | + <td class="text-center">{{ item.cycle }}</td> | ||
| 75 | + <td class="text-center">{{ item.squarePrice }}</td> | ||
| 76 | + <td class="text-center">{{ item.area }}</td> | ||
| 77 | + <td class="text-center">{{ item.primeRate }}</td> | ||
| 78 | + <td class="text-center">{{ item.amount }}</td> | ||
| 79 | + <td class="text-center">{{ item.discountPrice }}</td> | ||
| 80 | + <td class="text-center" width="200px">{{ item.remark }}</td> | ||
| 81 | + </tr> | ||
| 82 | + <tr> | ||
| 83 | + <td colspan="3" class="text-center"> | ||
| 84 | + {{ $t('printPayFeeXiangyun.capitalRMB') }}(元) | ||
| 85 | + </td> | ||
| 86 | + <td colspan="4" class="text-center"> | ||
| 87 | + {{ changeNumMoneyToChinese(printPayFeeInfo.amount) }} | ||
| 88 | + </td> | ||
| 89 | + <td colspan="4" class="text-center">{{ printPayFeeInfo.amount }}</td> | ||
| 90 | + </tr> | ||
| 91 | + <tr height="60px" v-if="printPayFeeInfo.content || printPayFeeInfo.qrImg"> | ||
| 92 | + <td colspan="7"> | ||
| 93 | + <div style="max-width: 600px;" v-html="printPayFeeInfo.content"></div> | ||
| 94 | + </td> | ||
| 95 | + <td colspan="4"> | ||
| 96 | + <img v-if="printPayFeeInfo.qrImg" :src="printPayFeeInfo.qrImg" width="100px" height="100px"> | ||
| 97 | + </td> | ||
| 98 | + </tr> | ||
| 99 | + </tbody> | ||
| 100 | + </table> | ||
| 101 | + | ||
| 102 | + <el-row style="color:#000;font-size:20px;margin-top:20px;"> | ||
| 103 | + <el-col :span="20"> | ||
| 104 | + <el-row> | ||
| 105 | + <el-col :span="6">{{ $t('printPayFeeXiangyun.departmentHead') }}:</el-col> | ||
| 106 | + <el-col :span="6">{{ $t('printPayFeeXiangyun.operator') }}:</el-col> | ||
| 107 | + <el-col :span="6">{{ $t('printPayFeeXiangyun.financeReceipt') }}:</el-col> | ||
| 108 | + <el-col :span="6">{{ $t('printPayFeeXiangyun.customerConfirm') }}:</el-col> | ||
| 109 | + </el-row> | ||
| 110 | + </el-col> | ||
| 111 | + <el-col :span="4" id="print-btn"> | ||
| 112 | + <el-button type="primary" class="float-right" @click="handlePrint"> | ||
| 113 | + <i class="fa fa-check"></i> {{ $t('common.print') }} | ||
| 114 | + </el-button> | ||
| 115 | + <el-button type="warning" class="float-right" style="margin-right:20px;" @click="handleClose"> | ||
| 116 | + {{ $t('common.cancel') }} | ||
| 117 | + </el-button> | ||
| 118 | + </el-col> | ||
| 119 | + </el-row> | ||
| 120 | + </div> | ||
| 121 | +</template> | ||
| 122 | + | ||
| 123 | +<script> | ||
| 124 | +import { getCommunityId, getCommunityName } from '@/api/community/communityApi' | ||
| 125 | +import { queryFeeReceipt, queryFeeReceiptDetail, queryFeePrintSpec } from '@/api/fee/printPayFeeApi' | ||
| 126 | +import { dateFormat } from '@/utils/dateUtil' | ||
| 127 | +import { changeNumMoneyToChinese } from '@/utils/moneyUtil' | ||
| 128 | + | ||
| 129 | +export default { | ||
| 130 | + name: 'PrintPayFeeXiangyun', | ||
| 131 | + data() { | ||
| 132 | + return { | ||
| 133 | + printPayFeeInfo: { | ||
| 134 | + communityName: '', | ||
| 135 | + receiptId: '', | ||
| 136 | + receiptIds: '', | ||
| 137 | + detailIds: '', | ||
| 138 | + roomName: '', | ||
| 139 | + amount: 0.00, | ||
| 140 | + fees: [], | ||
| 141 | + feeTime: '', | ||
| 142 | + wechatName: '', | ||
| 143 | + content: '', | ||
| 144 | + qrImg: '', | ||
| 145 | + payObjName: '', | ||
| 146 | + feeReceipt: [], | ||
| 147 | + apply: 'N', | ||
| 148 | + receiptNum: '', | ||
| 149 | + merge: '' | ||
| 150 | + }, | ||
| 151 | + printFlag: '0', | ||
| 152 | + communityId: '' | ||
| 153 | + } | ||
| 154 | + }, | ||
| 155 | + created() { | ||
| 156 | + this.communityId = getCommunityId() | ||
| 157 | + this.initData() | ||
| 158 | + }, | ||
| 159 | + methods: { | ||
| 160 | + initData() { | ||
| 161 | + this.printPayFeeInfo.receiptId = this.$route.query.receiptId | ||
| 162 | + this.printPayFeeInfo.receiptIds = this.$route.query.receiptIds | ||
| 163 | + this.printPayFeeInfo.detailIds = this.$route.query.detailIds | ||
| 164 | + this.printPayFeeInfo.apply = this.$route.query.apply || 'N' | ||
| 165 | + this.printPayFeeInfo.merge = this.$route.query.merge | ||
| 166 | + this.printPayFeeInfo.communityName = getCommunityName() | ||
| 167 | + | ||
| 168 | + this.loadReceipt() | ||
| 169 | + this.loadPrintSpec() | ||
| 170 | + }, | ||
| 171 | + loadReceipt() { | ||
| 172 | + const params = { | ||
| 173 | + page: 1, | ||
| 174 | + row: 30, | ||
| 175 | + receiptId: this.printPayFeeInfo.receiptId, | ||
| 176 | + receiptIds: this.printPayFeeInfo.receiptIds, | ||
| 177 | + detailIds: this.printPayFeeInfo.detailIds, | ||
| 178 | + communityId: this.communityId | ||
| 179 | + } | ||
| 180 | + | ||
| 181 | + queryFeeReceipt(params).then(response => { | ||
| 182 | + const feeReceipt = response.data | ||
| 183 | + let amount = 0 | ||
| 184 | + feeReceipt.forEach(item => { | ||
| 185 | + amount += parseFloat(item.amount) | ||
| 186 | + }) | ||
| 187 | + | ||
| 188 | + this.printPayFeeInfo.amount = amount.toFixed(2) | ||
| 189 | + this.printPayFeeInfo.roomName = feeReceipt[0].objName | ||
| 190 | + this.printPayFeeInfo.feeTime = feeReceipt[0].createTime | ||
| 191 | + this.printPayFeeInfo.payObjName = feeReceipt[0].payObjName | ||
| 192 | + this.printPayFeeInfo.feeReceipt = feeReceipt | ||
| 193 | + this.printPayFeeInfo.receiptNum = feeReceipt[0].receiptCode | ||
| 194 | + | ||
| 195 | + this.loadReceiptDetail() | ||
| 196 | + }).catch(error => { | ||
| 197 | + console.error('请求失败处理', error) | ||
| 198 | + }) | ||
| 199 | + }, | ||
| 200 | + loadReceiptDetail() { | ||
| 201 | + const params = { | ||
| 202 | + page: 1, | ||
| 203 | + row: 100, | ||
| 204 | + receiptId: this.printPayFeeInfo.receiptId, | ||
| 205 | + receiptIds: this.printPayFeeInfo.receiptIds, | ||
| 206 | + detailIds: this.printPayFeeInfo.detailIds, | ||
| 207 | + communityId: this.communityId, | ||
| 208 | + mergeFee: this.printPayFeeInfo.merge | ||
| 209 | + } | ||
| 210 | + | ||
| 211 | + queryFeeReceiptDetail(params).then(response => { | ||
| 212 | + const feeReceiptDetails = response.data | ||
| 213 | + this.printPayFeeInfo.receiptNum = this.printPayFeeInfo.receiptNum + "(" + feeReceiptDetails[0].payOrderId + ")" | ||
| 214 | + | ||
| 215 | + feeReceiptDetails.forEach(item => { | ||
| 216 | + this.printPayFeeInfo.feeReceipt.forEach(im => { | ||
| 217 | + if (item.receiptId == im.receiptId) { | ||
| 218 | + item.objName = im.objName | ||
| 219 | + item.feeTypeCd = im.feeTypeCd | ||
| 220 | + } | ||
| 221 | + }) | ||
| 222 | + }) | ||
| 223 | + this.printPayFeeInfo.fees = feeReceiptDetails | ||
| 224 | + }).catch(error => { | ||
| 225 | + console.error('请求失败处理', error) | ||
| 226 | + }) | ||
| 227 | + }, | ||
| 228 | + loadPrintSpec() { | ||
| 229 | + const params = { | ||
| 230 | + page: 1, | ||
| 231 | + row: 1, | ||
| 232 | + specCd: 2020, | ||
| 233 | + communityId: this.communityId | ||
| 234 | + } | ||
| 235 | + | ||
| 236 | + queryFeePrintSpec(params).then(response => { | ||
| 237 | + const data = response.data | ||
| 238 | + if (data.length > 0) { | ||
| 239 | + this.printPayFeeInfo.content = data[0].content | ||
| 240 | + this.printPayFeeInfo.qrImg = data[0].qrImg | ||
| 241 | + if (data[0].printName) { | ||
| 242 | + this.printPayFeeInfo.communityName = data[0].printName | ||
| 243 | + } | ||
| 244 | + } | ||
| 245 | + }).catch(error => { | ||
| 246 | + console.error('请求失败处理', error) | ||
| 247 | + }) | ||
| 248 | + }, | ||
| 249 | + dateFormat(date) { | ||
| 250 | + if (!date) return '' | ||
| 251 | + return dateFormat(date) | ||
| 252 | + }, | ||
| 253 | + changeNumMoneyToChinese, | ||
| 254 | + handlePrint() { | ||
| 255 | + this.printFlag = '1' | ||
| 256 | + console.log('printFlag:', this.printFlag) | ||
| 257 | + document.getElementById("print-btn").style.display = "none" | ||
| 258 | + window.print() | ||
| 259 | + window.opener = null | ||
| 260 | + window.close() | ||
| 261 | + }, | ||
| 262 | + handleClose() { | ||
| 263 | + window.opener = null | ||
| 264 | + window.close() | ||
| 265 | + } | ||
| 266 | + } | ||
| 267 | +} | ||
| 268 | +</script> | ||
| 269 | + | ||
| 270 | +<style scoped> | ||
| 271 | +.print-pay-fee-xiangyun-container { | ||
| 272 | + padding: 20px; | ||
| 273 | +} | ||
| 274 | + | ||
| 275 | +.text-center { | ||
| 276 | + text-align: center; | ||
| 277 | +} | ||
| 278 | + | ||
| 279 | +.text-right { | ||
| 280 | + text-align: right; | ||
| 281 | +} | ||
| 282 | + | ||
| 283 | +.float-left { | ||
| 284 | + float: left; | ||
| 285 | +} | ||
| 286 | + | ||
| 287 | +.float-right { | ||
| 288 | + float: right; | ||
| 289 | +} | ||
| 290 | + | ||
| 291 | +.table { | ||
| 292 | + width: 100%; | ||
| 293 | + margin-bottom: 1rem; | ||
| 294 | + color: #212529; | ||
| 295 | + border-collapse: collapse; | ||
| 296 | +} | ||
| 297 | + | ||
| 298 | +.vc-table-border { | ||
| 299 | + border: 1px solid #000; | ||
| 300 | +} | ||
| 301 | + | ||
| 302 | +.vc-table-border th, | ||
| 303 | +.vc-table-border td { | ||
| 304 | + border: 1px solid #000; | ||
| 305 | + padding: 8px; | ||
| 306 | +} | ||
| 307 | + | ||
| 308 | +@media print { | ||
| 309 | + #print-btn { | ||
| 310 | + display: none !important; | ||
| 311 | + } | ||
| 312 | +} | ||
| 313 | +</style> |
src/views/fee/printPayFeeXiangyunLang.js
0 → 100644
| 1 | +export const messages = { | ||
| 2 | + en: { | ||
| 3 | + printPayFeeXiangyun: { | ||
| 4 | + applyForm: 'Application Form', | ||
| 5 | + receiptForm: 'Receipt Form', | ||
| 6 | + receiptNum: 'Receipt No.', | ||
| 7 | + payTime: 'Payment Time', | ||
| 8 | + owner: 'Owner', | ||
| 9 | + serialNumber: 'No.', | ||
| 10 | + feeItem: 'Fee Item', | ||
| 11 | + houseCar: 'House/Car', | ||
| 12 | + feeRange: 'Fee Range', | ||
| 13 | + cycle: 'Cycle', | ||
| 14 | + unitPriceFixed: 'Unit Price/Fixed Fee', | ||
| 15 | + areaUsage: 'Area/Usage', | ||
| 16 | + paymentMethod: 'Payment Method', | ||
| 17 | + amount: 'Amount', | ||
| 18 | + discountAmount: 'Discount Amount', | ||
| 19 | + remark: 'Remark', | ||
| 20 | + to: ' to ', | ||
| 21 | + none: 'None', | ||
| 22 | + capitalRMB: 'Capital RMB', | ||
| 23 | + departmentHead: 'Department Head', | ||
| 24 | + operator: 'Operator', | ||
| 25 | + financeReceipt: 'Finance Receipt', | ||
| 26 | + customerConfirm: 'Customer Confirm' | ||
| 27 | + } | ||
| 28 | + }, | ||
| 29 | + zh: { | ||
| 30 | + printPayFeeXiangyun: { | ||
| 31 | + applyForm: '申请单', | ||
| 32 | + receiptForm: '收据单', | ||
| 33 | + receiptNum: '单号', | ||
| 34 | + payTime: '缴费时间', | ||
| 35 | + owner: '业主', | ||
| 36 | + serialNumber: '编号', | ||
| 37 | + feeItem: '收费项目', | ||
| 38 | + houseCar: '房屋/车辆', | ||
| 39 | + feeRange: '收费范围', | ||
| 40 | + cycle: '周期', | ||
| 41 | + unitPriceFixed: '单价/固定费', | ||
| 42 | + areaUsage: '面积/用量', | ||
| 43 | + paymentMethod: '支付方式', | ||
| 44 | + amount: '金额', | ||
| 45 | + discountAmount: '优惠金额', | ||
| 46 | + remark: '备注', | ||
| 47 | + to: '至', | ||
| 48 | + none: '无', | ||
| 49 | + capitalRMB: '大写人民币', | ||
| 50 | + departmentHead: '部门负责人', | ||
| 51 | + operator: '经办人', | ||
| 52 | + financeReceipt: '财务收款', | ||
| 53 | + customerConfirm: '客户确认' | ||
| 54 | + } | ||
| 55 | + } | ||
| 56 | +} | ||
| 57 | + |
src/views/fee/printPayFeeXinShiDai.vue
0 → 100644
| 1 | +<template> | ||
| 2 | + <div class="print-pay-fee-xinshidai-container"> | ||
| 3 | + <div style="color:#000;font-size:20px;margin-top: 90px; height: 60px;"> | ||
| 4 | + <el-row> | ||
| 5 | + <el-col :span="14"> | ||
| 6 | + <div style="margin-left: 40px;">{{ printPayFeeInfo.payObjName }}</div> | ||
| 7 | + </el-col> | ||
| 8 | + <el-col :span="10" class="text-center" v-if="printPayFeeInfo.feeReceipt && printPayFeeInfo.feeReceipt.length > 0"> | ||
| 9 | + <span>{{ printPayFeeInfo.feeReceipt[0].objName }}</span> | ||
| 10 | + </el-col> | ||
| 11 | + </el-row> | ||
| 12 | + </div> | ||
| 13 | + | ||
| 14 | + <table class="table" style="color:#000;font-size:20px;border:0;"> | ||
| 15 | + <thead> | ||
| 16 | + <tr style="border: 0px;"> | ||
| 17 | + <th scope="col" class="text-center" style="border: 0px;width: 30%"> | ||
| 18 | + {{ $t('printPayFeeXinShiDai.feeItem') }} | ||
| 19 | + </th> | ||
| 20 | + <th scope="col" class="text-center" style="border: 0px;width: 30%"> | ||
| 21 | + {{ $t('printPayFeeXinShiDai.summary') }} | ||
| 22 | + </th> | ||
| 23 | + <th scope="col" class="text-center" style="border: 0px;width: 20%"> | ||
| 24 | + {{ $t('printPayFeeXinShiDai.lateFee') }} | ||
| 25 | + </th> | ||
| 26 | + <th scope="col" class="text-left" style="border: 0px;width: 20%"> | ||
| 27 | + {{ $t('printPayFeeXinShiDai.amount') }} | ||
| 28 | + </th> | ||
| 29 | + <th scope="col" class="text-center" style="border: 0px;"></th> | ||
| 30 | + </tr> | ||
| 31 | + </thead> | ||
| 32 | + <tbody style="color:#000;font-size:20px;border: 0px;"> | ||
| 33 | + <tr v-for="(item, index) in printPayFeeInfo.fees" :key="index" style="border: 0px;"> | ||
| 34 | + <td class="text-center" style="border: 0px;">{{ item.feeName }}</td> | ||
| 35 | + <td class="text-center" v-if="item.preDegrees" style="border: 0px;"> | ||
| 36 | + {{ dateFormat(item.startTime) }}{{ $t('printPayFeeXinShiDai.to') }}{{ dateFormat(item.endTime) }}<br /> | ||
| 37 | + {{ item.preDegrees }} {{ $t('printPayFeeXinShiDai.to') }} {{ item.curDegrees }} | ||
| 38 | + </td> | ||
| 39 | + <!-- 根据山东需求 如果为押金时 显示为无--> | ||
| 40 | + <td class="text-center" style="border: 0px;" v-else-if="item.feeTypeCd == '888800010006'"> | ||
| 41 | + {{ $t('printPayFeeXinShiDai.none') }} | ||
| 42 | + </td> | ||
| 43 | + <td class="text-center" style="border: 0px;" v-else> | ||
| 44 | + {{ dateFormat(item.startTime) }}{{ $t('printPayFeeXinShiDai.to') }}{{ dateFormat(item.endTime) }} | ||
| 45 | + </td> | ||
| 46 | + <td class="text-center" style="border: 0px;">{{ item.discountPrice || 0 }}</td> | ||
| 47 | + <td class="text-left" style="border: 0px;">{{ item.amount }}</td> | ||
| 48 | + <td class="text-center" style="border: 0px;"></td> | ||
| 49 | + </tr> | ||
| 50 | + <tr style="border: 0px;"> | ||
| 51 | + <td class="text-center" style="border: 0px;"></td> | ||
| 52 | + <td class="text-center" style="border: 0px;"> | ||
| 53 | + ({{ $t('printPayFeeXinShiDai.capitalFormat') }}){{ changeNumMoneyToChinese(printPayFeeInfo.amount) }} | ||
| 54 | + </td> | ||
| 55 | + <td class="text-center" style="border: 0px;">: </td> | ||
| 56 | + <td colspan="1" class="text-left" style="border: 0px;">{{ printPayFeeInfo.amount }}</td> | ||
| 57 | + <td class="text-center" style="border: 0px;"></td> | ||
| 58 | + </tr> | ||
| 59 | + <tr style="border: 0px;"> | ||
| 60 | + <td class="text-center" style="border: 0px;"></td> | ||
| 61 | + <td class="text-center" style="border: 0px;"></td> | ||
| 62 | + <td colspan="1" class="text-center" style="border: 0px;">{{ printPayFeeInfo.feeTime }}</td> | ||
| 63 | + <td class="text-center" style="border: 0px;"></td> | ||
| 64 | + </tr> | ||
| 65 | + <tr style="border: 0px;"> | ||
| 66 | + <td class="text-center" style="border: 0px;"></td> | ||
| 67 | + <td class="text-center" style="border: 0px;">{{ $t('printPayFeeXinShiDai.receiptNum') }}</td> | ||
| 68 | + <td colspan="1" class="text-center" style="border: 0px;">{{ printPayFeeInfo.receiptNum }}</td> | ||
| 69 | + <td class="text-center" style="border: 0px;"></td> | ||
| 70 | + </tr> | ||
| 71 | + <tr style="border: 0px;" v-if="printPayFeeInfo.carName"> | ||
| 72 | + <td class="text-center" style="border: 0px;"></td> | ||
| 73 | + <td class="text-center" style="border: 0px;">{{ $t('printPayFeeXinShiDai.vehicle') }}</td> | ||
| 74 | + <td colspan="1" class="text-center" style="border: 0px;">{{ printPayFeeInfo.carName }}</td> | ||
| 75 | + <td class="text-center" style="border: 0px;"></td> | ||
| 76 | + </tr> | ||
| 77 | + <tr style="border: 0px;"> | ||
| 78 | + <td class="text-center" style="border: 0px;"></td> | ||
| 79 | + <td class="text-center" style="border: 0px;"></td> | ||
| 80 | + <td colspan="1" class="text-center" style="border: 0px;"></td> | ||
| 81 | + <td class="text-center" style="border: 0px;"></td> | ||
| 82 | + </tr> | ||
| 83 | + <tr style="border: 0px;"> | ||
| 84 | + <td class="text-center" style="border: 0px;"></td> | ||
| 85 | + <td class="text-center" style="border: 0px;"></td> | ||
| 86 | + <td colspan="1" class="text-center" style="border: 0px;">{{ printPayFeeInfo.userName }}</td> | ||
| 87 | + <td class="text-center" style="border: 0px;"></td> | ||
| 88 | + </tr> | ||
| 89 | + </tbody> | ||
| 90 | + </table> | ||
| 91 | + | ||
| 92 | + <el-row id="print-btn"> | ||
| 93 | + <el-col :span="24" class="text-right"> | ||
| 94 | + <el-button type="primary" class="float-right" @click="handlePrint"> | ||
| 95 | + <i class="fa fa-check"></i> {{ $t('common.print') }} | ||
| 96 | + </el-button> | ||
| 97 | + <el-button type="warning" class="float-right" style="margin-right:20px;" @click="handleClose"> | ||
| 98 | + {{ $t('common.cancel') }} | ||
| 99 | + </el-button> | ||
| 100 | + </el-col> | ||
| 101 | + </el-row> | ||
| 102 | + </div> | ||
| 103 | +</template> | ||
| 104 | + | ||
| 105 | +<script> | ||
| 106 | +import { getCommunityId, getCommunityName } from '@/api/community/communityApi' | ||
| 107 | +import { queryFeeReceipt, queryFeeReceiptDetail, queryFeeDetailDiscount, queryOwnerCars } from '@/api/fee/printPayFeeApi' | ||
| 108 | +import { getUserName } from '@/api/user/userApi' | ||
| 109 | +import { dateFormat } from '@/utils/dateUtil' | ||
| 110 | +import { changeNumMoneyToChinese } from '@/utils/moneyUtil' | ||
| 111 | + | ||
| 112 | +export default { | ||
| 113 | + name: 'PrintPayFeeXinShiDai', | ||
| 114 | + data() { | ||
| 115 | + return { | ||
| 116 | + printPayFeeInfo: { | ||
| 117 | + communityName: '', | ||
| 118 | + receiptId: '', | ||
| 119 | + receiptIds: '', | ||
| 120 | + roomName: '', | ||
| 121 | + amount: 0.00, | ||
| 122 | + fees: [], | ||
| 123 | + feeTime: '', | ||
| 124 | + wechatName: '', | ||
| 125 | + content: '', | ||
| 126 | + qrImg: '', | ||
| 127 | + payObjName: '', | ||
| 128 | + feeReceipt: [], | ||
| 129 | + apply: 'N', | ||
| 130 | + userName: '', | ||
| 131 | + receiptNum: '', | ||
| 132 | + carName: '' | ||
| 133 | + }, | ||
| 134 | + printFlag: '0', | ||
| 135 | + communityId: '' | ||
| 136 | + } | ||
| 137 | + }, | ||
| 138 | + created() { | ||
| 139 | + this.communityId = getCommunityId() | ||
| 140 | + this.printPayFeeInfo.userName = getUserName() | ||
| 141 | + this.initData() | ||
| 142 | + }, | ||
| 143 | + methods: { | ||
| 144 | + initData() { | ||
| 145 | + this.printPayFeeInfo.receiptId = this.$route.query.receiptId | ||
| 146 | + this.printPayFeeInfo.receiptIds = this.$route.query.receiptIds | ||
| 147 | + this.printPayFeeInfo.apply = this.$route.query.apply || 'N' | ||
| 148 | + this.printPayFeeInfo.communityName = getCommunityName() | ||
| 149 | + | ||
| 150 | + this.loadReceipt() | ||
| 151 | + }, | ||
| 152 | + loadReceipt() { | ||
| 153 | + const params = { | ||
| 154 | + page: 1, | ||
| 155 | + row: 30, | ||
| 156 | + receiptId: this.printPayFeeInfo.receiptId, | ||
| 157 | + receiptIds: this.printPayFeeInfo.receiptIds, | ||
| 158 | + communityId: this.communityId | ||
| 159 | + } | ||
| 160 | + | ||
| 161 | + queryFeeReceipt(params).then(response => { | ||
| 162 | + const feeReceipt = response.data | ||
| 163 | + let amount = 0 | ||
| 164 | + feeReceipt.forEach(item => { | ||
| 165 | + amount += parseFloat(item.amount) | ||
| 166 | + }) | ||
| 167 | + | ||
| 168 | + this.printPayFeeInfo.amount = amount.toFixed(2) | ||
| 169 | + this.printPayFeeInfo.roomName = feeReceipt[0].objName | ||
| 170 | + this.printPayFeeInfo.feeTime = feeReceipt[0].createTime | ||
| 171 | + this.printPayFeeInfo.payObjName = feeReceipt[0].payObjName | ||
| 172 | + this.printPayFeeInfo.feeReceipt = feeReceipt | ||
| 173 | + | ||
| 174 | + this.loadReceiptDetail() | ||
| 175 | + | ||
| 176 | + // 如果是车位,查询车辆信息 | ||
| 177 | + if (feeReceipt[0].objType == '6666') { | ||
| 178 | + this.printPayFeeInfo.carName = feeReceipt[0].objName | ||
| 179 | + this.listOwnerCar(feeReceipt[0].objId) | ||
| 180 | + } | ||
| 181 | + }).catch(error => { | ||
| 182 | + console.error('请求失败处理', error) | ||
| 183 | + }) | ||
| 184 | + }, | ||
| 185 | + loadReceiptDetail() { | ||
| 186 | + const params = { | ||
| 187 | + page: 1, | ||
| 188 | + row: 100, | ||
| 189 | + receiptId: this.printPayFeeInfo.receiptId, | ||
| 190 | + receiptIds: this.printPayFeeInfo.receiptIds, | ||
| 191 | + communityId: this.communityId | ||
| 192 | + } | ||
| 193 | + | ||
| 194 | + queryFeeReceiptDetail(params).then(response => { | ||
| 195 | + const feeReceiptDetails = response.data | ||
| 196 | + console.log('收据详情数据:', feeReceiptDetails) | ||
| 197 | + this.printPayFeeInfo.receiptNum = feeReceiptDetails[0].receiptId + "(" + feeReceiptDetails[0].payOrderId + ")" | ||
| 198 | + | ||
| 199 | + feeReceiptDetails.forEach(item => { | ||
| 200 | + console.log('费用项数据:', item) | ||
| 201 | + this.printPayFeeInfo.feeReceipt.forEach(im => { | ||
| 202 | + if (item.receiptId == im.receiptId) { | ||
| 203 | + item.objName = im.objName | ||
| 204 | + item.feeTypeCd = im.feeTypeCd | ||
| 205 | + } | ||
| 206 | + }) | ||
| 207 | + // 查询滞纳金折扣信息 | ||
| 208 | + this.loadFeeDetailDiscount(item.detailId, item) | ||
| 209 | + }) | ||
| 210 | + | ||
| 211 | + // 使用 Vue.set 确保响应式 | ||
| 212 | + this.$set(this.printPayFeeInfo, 'fees', feeReceiptDetails) | ||
| 213 | + | ||
| 214 | + // 延迟刷新以确保折扣信息加载完成 | ||
| 215 | + setTimeout(() => { | ||
| 216 | + console.log('强制更新前的fees:', this.printPayFeeInfo.fees) | ||
| 217 | + this.$forceUpdate() | ||
| 218 | + }, 2000) | ||
| 219 | + }).catch(error => { | ||
| 220 | + console.error('请求失败处理', error) | ||
| 221 | + }) | ||
| 222 | + }, | ||
| 223 | + loadFeeDetailDiscount(detailId, item) { | ||
| 224 | + const params = { | ||
| 225 | + page: 1, | ||
| 226 | + row: 100, | ||
| 227 | + detailId: detailId | ||
| 228 | + } | ||
| 229 | + | ||
| 230 | + queryFeeDetailDiscount(params).then(response => { | ||
| 231 | + const feeReceiptDetails = response.data | ||
| 232 | + if (feeReceiptDetails && feeReceiptDetails.length > 0) { | ||
| 233 | + feeReceiptDetails.forEach(data => { | ||
| 234 | + if (data.discountType == '2002') { | ||
| 235 | + this.$set(item, 'discountPrice', parseFloat(data.discountPrice) * -1) | ||
| 236 | + } else { | ||
| 237 | + this.$set(item, 'discountPrice', 0) | ||
| 238 | + } | ||
| 239 | + }) | ||
| 240 | + } else { | ||
| 241 | + this.$set(item, 'discountPrice', 0) | ||
| 242 | + } | ||
| 243 | + }).catch(error => { | ||
| 244 | + console.error('查询折扣失败', error) | ||
| 245 | + this.$set(item, 'discountPrice', 0) | ||
| 246 | + }) | ||
| 247 | + }, | ||
| 248 | + listOwnerCar(carId) { | ||
| 249 | + const params = { | ||
| 250 | + page: 1, | ||
| 251 | + row: 1, | ||
| 252 | + carId: carId | ||
| 253 | + } | ||
| 254 | + | ||
| 255 | + queryOwnerCars(params).then(response => { | ||
| 256 | + const ownerCar = response.data[0] | ||
| 257 | + if (ownerCar && ownerCar.roomName) { | ||
| 258 | + const roomName = ownerCar.roomName.replace('栋', '-').replace("单元", '-').replace('室', '') | ||
| 259 | + this.$set(this.printPayFeeInfo.feeReceipt[0], 'objName', roomName) | ||
| 260 | + } | ||
| 261 | + }).catch(error => { | ||
| 262 | + console.error('查询车位房屋失败', error) | ||
| 263 | + }) | ||
| 264 | + }, | ||
| 265 | + dateFormat(date) { | ||
| 266 | + if (!date) return '' | ||
| 267 | + return dateFormat(date) | ||
| 268 | + }, | ||
| 269 | + changeNumMoneyToChinese, | ||
| 270 | + handlePrint() { | ||
| 271 | + this.printFlag = '1' | ||
| 272 | + console.log('printFlag:', this.printFlag) | ||
| 273 | + document.getElementById("print-btn").style.display = "none" | ||
| 274 | + window.print() | ||
| 275 | + window.opener = null | ||
| 276 | + window.close() | ||
| 277 | + }, | ||
| 278 | + handleClose() { | ||
| 279 | + window.opener = null | ||
| 280 | + window.close() | ||
| 281 | + } | ||
| 282 | + } | ||
| 283 | +} | ||
| 284 | +</script> | ||
| 285 | + | ||
| 286 | +<style scoped> | ||
| 287 | +.print-pay-fee-xinshidai-container { | ||
| 288 | + padding: 20px; | ||
| 289 | +} | ||
| 290 | + | ||
| 291 | +.text-center { | ||
| 292 | + text-align: center; | ||
| 293 | +} | ||
| 294 | + | ||
| 295 | +.text-left { | ||
| 296 | + text-align: left; | ||
| 297 | +} | ||
| 298 | + | ||
| 299 | +.float-right { | ||
| 300 | + float: right; | ||
| 301 | +} | ||
| 302 | + | ||
| 303 | +.table { | ||
| 304 | + width: 100%; | ||
| 305 | + margin-bottom: 1rem; | ||
| 306 | + color: #212529; | ||
| 307 | + border-collapse: collapse; | ||
| 308 | +} | ||
| 309 | + | ||
| 310 | +@media print { | ||
| 311 | + #print-btn { | ||
| 312 | + display: none !important; | ||
| 313 | + } | ||
| 314 | +} | ||
| 315 | +</style> | ||
| 316 | + |
src/views/fee/printPayFeeXinShiDaiLang.js
0 → 100644
| 1 | +export const messages = { | ||
| 2 | + en: { | ||
| 3 | + printPayFeeXinShiDai: { | ||
| 4 | + feeItem: 'Fee Item', | ||
| 5 | + summary: 'Summary', | ||
| 6 | + lateFee: 'Late Fee', | ||
| 7 | + amount: 'Amount', | ||
| 8 | + to: ' to ', | ||
| 9 | + none: 'None', | ||
| 10 | + capitalFormat: 'Capital', | ||
| 11 | + receiptNum: 'Receipt No.', | ||
| 12 | + vehicle: 'Vehicle' | ||
| 13 | + } | ||
| 14 | + }, | ||
| 15 | + zh: { | ||
| 16 | + printPayFeeXinShiDai: { | ||
| 17 | + feeItem: '收费项目', | ||
| 18 | + summary: '摘要', | ||
| 19 | + lateFee: '滞纳金', | ||
| 20 | + amount: '金额', | ||
| 21 | + to: '至', | ||
| 22 | + none: '无', | ||
| 23 | + capitalFormat: '大写', | ||
| 24 | + receiptNum: '单号', | ||
| 25 | + vehicle: '车辆' | ||
| 26 | + } | ||
| 27 | + } | ||
| 28 | +} | ||
| 29 | + |
src/views/user/login/Login.vue
| @@ -44,8 +44,8 @@ export default { | @@ -44,8 +44,8 @@ export default { | ||
| 44 | logo: '', | 44 | logo: '', |
| 45 | companyName:'', | 45 | companyName:'', |
| 46 | loginForm: { | 46 | loginForm: { |
| 47 | - username: '', | ||
| 48 | - passwd: '', | 47 | + username: 'wuxw', |
| 48 | + passwd: 'admin', | ||
| 49 | validateCode: '' | 49 | validateCode: '' |
| 50 | }, | 50 | }, |
| 51 | captchaUrl: '', | 51 | captchaUrl: '', |