| | |
| | | </view> |
| | | </view> |
| | | <!-- 仅非“审批通过”的台账展示删除按钮 --> |
| | | <view |
| | | class="detail-row" |
| | | v-if="item.approvalStatus !== 3" |
| | | style="justify-content: flex-end; margin-top: 8px;" |
| | | > |
| | | <up-button |
| | | type="error" |
| | | size="small" |
| | | plain |
| | | @click.stop="handleDelete(item)" |
| | | > |
| | | <view class="detail-row" |
| | | v-if="item.approvalStatus !== 3" |
| | | style="justify-content: flex-end; margin-top: 8px;"> |
| | | <up-button type="error" |
| | | size="small" |
| | | plain |
| | | @click.stop="handleDelete(item)"> |
| | | 删除 |
| | | </up-button> |
| | | </view> |
| | |
| | | import { onShow } from "@dcloudio/uni-app"; |
| | | import useUserStore from "@/store/modules/user"; |
| | | import PageHeader from "@/components/PageHeader.vue"; |
| | | import { purchaseListPage, delPurchase } from "@/api/procurementManagement/procurementLedger"; |
| | | import { |
| | | purchaseListPage, |
| | | delPurchase, |
| | | } from "@/api/procurementManagement/procurementLedger"; |
| | | const userStore = useUserStore(); |
| | | const approvalStatusText = { |
| | | 1: "待审核", |
| | |
| | | try { |
| | | // 设置操作类型 |
| | | uni.setStorageSync("operationType", type); |
| | | uni.removeStorageSync("editData"); |
| | | |
| | | // 如果是查看或编辑操作 |
| | | if (type !== "add") { |
| | |
| | | // 只有在真正异常时,才在这里兜底提示 |
| | | const msg = |
| | | (error && error.msg) || |
| | | (error && error.response && error.response.data && error.response.data.msg) || |
| | | (error && |
| | | error.response && |
| | | error.response.data && |
| | | error.response.data.msg) || |
| | | (error && error.message) || |
| | | "删除失败"; |
| | | uni.showToast({ |