This commit is contained in:
1 parent
c2f5d753c2
commit
a4d7e60ea9
1 file changed
+49
-24
@@ -6,8 +6,7 @@
|
|||||||
<div class="flex justify-between items-end mb-1">
|
<div class="flex justify-between items-end mb-1">
|
||||||
<div></div>
|
<div></div>
|
||||||
<div>
|
<div>
|
||||||
{{ formatDate(new Date(receiptData.time), "YYYY年 mm月 dd日") || " 年 月 日".replace(/ /g, " ")
|
{{ formatDate(new Date(receiptData.time), "YYYY年 mm月 dd日") || " 年 月 日".replace(/ /g, " ") }}
|
||||||
}}
|
|
||||||
</div>
|
</div>
|
||||||
<span>
|
<span>
|
||||||
<span>No. </span>
|
<span>No. </span>
|
||||||
@@ -20,8 +19,12 @@
|
|||||||
<tr>
|
<tr>
|
||||||
<td class="border border-gray-600 px-2 w-3/12 h-[0.75cm]">交款单位(或个人)</td>
|
<td class="border border-gray-600 px-2 w-3/12 h-[0.75cm]">交款单位(或个人)</td>
|
||||||
<td class="border border-gray-600 px-2 w-9/12 h-[0.75cm] text-sm text-blue-800" colspan="4">
|
<td class="border border-gray-600 px-2 w-9/12 h-[0.75cm] text-sm text-blue-800" colspan="4">
|
||||||
<input type="text" v-model="receiptData.deptOrUser"
|
<input
|
||||||
class="caret-red-600 w-full h-full bg-transparent text-center" ref="deptOrUserInput" />
|
type="text"
|
||||||
|
v-model="receiptData.deptOrUser"
|
||||||
|
class="caret-red-600 w-full h-full bg-transparent text-center"
|
||||||
|
ref="deptOrUserInput"
|
||||||
|
/>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
@@ -58,10 +61,15 @@
|
|||||||
<td class="border border-gray-600 px-2 w-1/6 h-[0.75cm]">收款单位<br />(盖章)</td>
|
<td class="border border-gray-600 px-2 w-1/6 h-[0.75cm]">收款单位<br />(盖章)</td>
|
||||||
<td class="border border-gray-600 px-2 text-left w-1/6 h-[0.75cm] text-sm text-blue-800">
|
<td class="border border-gray-600 px-2 text-left w-1/6 h-[0.75cm] text-sm text-blue-800">
|
||||||
<!-- <input type="text" v-model="receiptData.payeeDept" class="w-full h-full bg-transparent" /> -->
|
<!-- <input type="text" v-model="receiptData.payeeDept" class="w-full h-full bg-transparent" /> -->
|
||||||
<img v-if="receiptData.picUrl" class="w-[2.5cm] h-[2.5cm] absolute -top-2 left-[140px]"
|
<img
|
||||||
:class="{ stamping: isStamping }" draggable="false"
|
v-if="receiptData.picUrl || isStamping"
|
||||||
|
class="w-[2.5cm] h-[2.5cm] absolute -top-2 left-[140px]"
|
||||||
|
:class="{ stamping: isStamping }"
|
||||||
|
draggable="false"
|
||||||
style="-webkit-user-drag: none; user-select: none; pointer-events: none"
|
style="-webkit-user-drag: none; user-select: none; pointer-events: none"
|
||||||
oncontextmenu="return false" src="/@/assets/receiptStamp.png" />
|
oncontextmenu="return false"
|
||||||
|
src="/@/assets/receiptStamp.png"
|
||||||
|
/>
|
||||||
</td>
|
</td>
|
||||||
<td class="border border-gray-600 px-2 w-1/6 h-[0.75cm]">开票人<br />(签名)</td>
|
<td class="border border-gray-600 px-2 w-1/6 h-[0.75cm]">开票人<br />(签名)</td>
|
||||||
<td class="border border-gray-600 px-2 text-left w-1/6 h-[0.75cm] text-sm text-blue-800">
|
<td class="border border-gray-600 px-2 text-left w-1/6 h-[0.75cm] text-sm text-blue-800">
|
||||||
@@ -71,15 +79,16 @@
|
|||||||
<td class="border border-gray-600 px-2 text-left align-text-top w-1/3 h-[0.75cm]">
|
<td class="border border-gray-600 px-2 text-left align-text-top w-1/3 h-[0.75cm]">
|
||||||
<div class="flex">
|
<div class="flex">
|
||||||
<span class="whitespace-nowrap">备注:</span>
|
<span class="whitespace-nowrap">备注:</span>
|
||||||
<textarea v-model="receiptData.remark"
|
<textarea
|
||||||
class="flex-1 text-sm text-blue-800 w-full h-full my-1 bg-transparent resize-none overflow-y-hidden" />
|
v-model="receiptData.remark"
|
||||||
|
class="flex-1 text-sm text-blue-800 w-full h-full my-1 bg-transparent resize-none overflow-y-hidden"
|
||||||
|
/>
|
||||||
</div>
|
</div>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
</table>
|
</table>
|
||||||
<div class="flex items-center absolute bottom-0 top-0 right-0">
|
<div class="flex items-center absolute bottom-0 top-0 right-0">
|
||||||
<span class="text-gray-500 text-sm whitespace-nowrap"
|
<span class="text-gray-500 text-sm whitespace-nowrap" style="writing-mode: vertical-rl; letter-spacing: 0.2em">
|
||||||
style="writing-mode: vertical-rl; letter-spacing: 0.2em">
|
|
||||||
{{ "第一联 存根联".replace(/ /g, " ") }}
|
{{ "第一联 存根联".replace(/ /g, " ") }}
|
||||||
</span>
|
</span>
|
||||||
</div>
|
</div>
|
||||||
@@ -87,20 +96,39 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="h-6">
|
<div class="h-6">
|
||||||
<el-progress :percentage="progressPercent" v-if="progressPercent > 30" :stroke-width="6" status="success"
|
<el-progress
|
||||||
striped striped-flow :duration="20" />
|
:percentage="progressPercent"
|
||||||
|
v-if="progressPercent > 30"
|
||||||
|
:stroke-width="6"
|
||||||
|
status="success"
|
||||||
|
striped
|
||||||
|
striped-flow
|
||||||
|
:duration="20"
|
||||||
|
/>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<template #footer>
|
<template #footer>
|
||||||
<el-button @click="handleClose" :disabled="loading">关闭</el-button>
|
<el-button @click="handleClose" :disabled="loading">关闭</el-button>
|
||||||
<el-button v-if="!receiptData.picUrl" v-auth="'wallet_walletRechargeApply_receiptStamp'" type="primary"
|
<el-button
|
||||||
@click="stampReceipt" :disabled="loading">
|
v-if="!receiptData.picUrl"
|
||||||
|
v-auth="'wallet_walletRechargeApply_receiptStamp'"
|
||||||
|
type="primary"
|
||||||
|
@click="stampReceipt"
|
||||||
|
:disabled="loading"
|
||||||
|
>
|
||||||
盖章
|
盖章
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button v-if="receiptData.picUrl" v-auth="'wallet_walletRechargeApply_back'" type="primary"
|
<el-button
|
||||||
@click="backInvoice" :disabled="loadingBack">作废</el-button>
|
v-if="receiptData.picUrl"
|
||||||
<el-button v-auth="'wallet_walletRechargeApply_receiptSave'" type="primary" @click="saveReceipt"
|
v-auth="'wallet_walletRechargeApply_back'"
|
||||||
:disabled="loading">保存</el-button>
|
type="primary"
|
||||||
|
plain
|
||||||
|
@click="backInvoice"
|
||||||
|
:disabled="loadingBack"
|
||||||
|
>
|
||||||
|
作废
|
||||||
|
</el-button>
|
||||||
|
<el-button v-auth="'wallet_walletRechargeApply_receiptSave'" type="primary" @click="saveReceipt" :disabled="loading">保存</el-button>
|
||||||
<el-button v-if="receiptData.picUrl" type="primary" @click="handlePrint" :disabled="loading">打印</el-button>
|
<el-button v-if="receiptData.picUrl" type="primary" @click="handlePrint" :disabled="loading">打印</el-button>
|
||||||
</template>
|
</template>
|
||||||
</el-dialog>
|
</el-dialog>
|
||||||
@@ -196,7 +224,7 @@ const backInvoice = async () => {
|
|||||||
emit("refresh")
|
emit("refresh")
|
||||||
useMessage().success("作废成功")
|
useMessage().success("作废成功")
|
||||||
} catch (error: any) {
|
} catch (error: any) {
|
||||||
console.error(error);
|
console.error(error)
|
||||||
useMessage().error(error.msg)
|
useMessage().error(error.msg)
|
||||||
} finally {
|
} finally {
|
||||||
loadingBack.value = false
|
loadingBack.value = false
|
||||||
@@ -230,10 +258,7 @@ const genImageUpload = async (): Promise<string | void> => {
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
})
|
})
|
||||||
if (code == 0) {
|
if (code == 0) return data.url
|
||||||
useMessage().success("盖章成功")
|
|
||||||
return data.url
|
|
||||||
}
|
|
||||||
useMessage().error(data.msg || "上传失败")
|
useMessage().error(data.msg || "上传失败")
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
useMessage().error(error as string)
|
useMessage().error(error as string)
|
||||||
|
|||||||
Reference in new issue
Block a user