123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149 |
- <template>
- <view class="detail-view">
- <u-form label-width="150" :model="form" ref="uForm">
- <view class="form-model-view">
- <u-form-item label="退款单位">
- <view class="form-value">{{ detail_data.unitName }}</view>
- </u-form-item>
- <u-form-item label="业务类型">
- <view class="form-value">{{ detail_data.financeType }}</view>
- </u-form-item>
- <u-form-item label="所属店铺">
- <view class="form-value">{{ detail_data.shopName }}</view>
- </u-form-item>
- <u-form-item label="制单人">
- <view class="form-value">{{ detail_data.currentAccountName }}</view>
- </u-form-item>
- <u-form-item label="单据日期">
- <view class="form-value">{{ $u.timeFormat(detail_data.createTime, 'yyyy-mm-dd') }}</view>
- </u-form-item>
- <u-form-item label="单据状态">
- <view class="form-value">
- <text class="success-status" v-if="detail_data.auditStatus === 2">已审核</text>
- <text class="warning-status" v-else>待审核</text>
- </view>
- </u-form-item>
- </view>
- <view class="detail-ul">
- <view class="detail-li" v-for="(item,index) in detail_data.accountList" :key="index">
- <view class="other-ul">
- <view class="other-li">结算账户:{{ item.accountName || '--' }}</view>
- <!-- <view class="other-li">退款方式:{{ item.accountName||'--' }}</view> -->
- <view class="other-li">
- 实际退款金额:
- <text class="money">{{ $utils.formattedNumber(item.money) }}</text>
- </view>
- </view>
- <view class="remark">备注:{{ item.remark || '无' }}</view>
- </view>
- </view>
- </u-form>
- <view class="detail-bottom" v-if="detail_data.auditStatus !== 2 && $accessCheck($Access.RefundFormupdateRefundStatus)">
- <view class="handel-btn" @click="openModel('确定要审核通过该退款单吗?', '审核')">审核</view>
- </view>
- <u-modal v-model="model_show" :show-cancel-button="true" :content="model_content" @confirm="modelConfirm" @cancel="modelCancel"></u-modal>
- </view>
- </template>
- <script>
- export default {
- data() {
- return {
- model_tag: '',
- model_show: false,
- model_content: '',
- createTime: '',
- id: '',
- detail_data: []
- };
- },
- onLoad(options) {
- this.id = options.id;
- this.createTime = options.createTime;
- },
- onShow() {
- this.getRefundInfo();
- },
- onPullDownRefresh() {
- this.getRefundInfo();
- },
- methods: {
- getRefundInfo() {
- this.$u.api
- .getRefundInfo({
- id: this.id,
- createTime: this.createTime
- })
- .then(res => {
- this.detail_data = res.data;
- });
- },
- // 打开提示框
- openModel(content, tag) {
- this.model_content = content;
- this.model_show = true;
- this.model_tag = tag;
- },
- modelConfirm() {
- switch (this.model_tag) {
- case '审核':
- this.updateRefundStatus();
- break;
- }
- },
- updateRefundStatus() {
- this.$u.api
- .updateRefundStatus({
- id: this.id,
- createTime: this.detail_data.createTime
- })
- .then(res => {
- this.$u.toast('操作成功');
- this.getRefundInfo();
- });
- }
- }
- };
- </script>
- <style lang="scss">
- .detail-ul {
- .detail-li {
- width: 710rpx;
- margin: 20rpx auto;
- background-color: #ffffff;
- border-radius: 20rpx;
- padding: 20rpx 24rpx;
- .title {
- font-weight: bold;
- }
- .other-ul {
- // display: flex;
- padding-top: 20rpx;
- .other-li {
- // flex: 3;
- font-size: 24rpx;
- line-height: 40rpx;
- // text-align: center;
- .money {
- font-size: 28rpx;
- font-weight: bold;
- color: $uni-color-error;
- }
- &:first-child {
- text-align: left;
- }
- &:last-child {
- // text-align: right;
- }
- }
- }
- .remark {
- border-top: 1px solid #eeeeee;
- padding-top: 20rpx;
- margin-top: 20rpx;
- }
- }
- }
- </style>
|