<template>
  <view class="container">
    <view class="content">
      <view class="content_inner">
        <view class="text_tip">
          <view class="text_tipTitle">门诊预约退款申请说明</view>
          <view>尊敬的患者</view>
          <view>1、退款申请是针对门诊历史预交金余额(<text class="colorRed">具体可退金额请查看医院的短信通知</text>)进行退费申请，需提交持卡人姓名、银行卡号、开户行、持卡人身份证信息等;</view>
          <view>2、收款户名信息需要与短信通知的持卡人姓名一致;</view>
          <view>3、友情提醒:为了保障您预交金的资金安全，线上转账退款登记完成后，医院会进行基本信息审核，校验无误后为您办理退款，办理时间约7个工作日，请您耐心等待,有疑问欢迎在工作时间拨打电话0591-83947288;</view>
          <view>4、未成年人办理退款请至医院门诊收费窗口办理。</view>
          <view>5、改善就医感受、提升患者体验，我们一直在努力!感谢您的支持与配合。</view>
        </view> 
      </view>
      <view class="content_btn backgroundCustom" @click="go('refundApplicationForm')">申请退款</view>
      <view class="public_info_list">
        <view class="public_info_item" @click="go('refundApplicationRecord')">
          <view class="public_info_tit">申请记录</view>
          <image class="public_right_img" :src="iconUrl.icon_right"></image>
        </view>
      </view>
    </view>
  </view>
</template>

<script setup lang="ts">
import { ref } from 'vue';
import { onLoad, onShow } from '@dcloudio/uni-app';
import { common } from '@/utils';
import icon from '@/utils/icon';

const iconUrl = ref(icon);
const app = getApp();
// const currentUser = ref<any>({}); // kept for consistency if needed, though unused in template

onLoad((options) => {
  common.showModal("本菜单功能仅限于收到退款提示短信且建卡时登记身份证信息的患者使用，就诊卡登记基本信息不全的或未成年人就诊卡，其预交金退款请前往医院窗口办理。",()=>{},{title:'温馨提示'})
});

onShow(() => {
  // currentUser.value = app.globalData.currentUser;
});

const go = (urlType: string) => {
  common.goToUrl(`/pagesPatient/st1/business/refund/${urlType}/${urlType}`);
};
</script>

<style lang="scss" scoped>
.public_info_list{
  background-color: #fff;
  margin: 32upx;
  border-radius: 24upx;
  padding: 0 24upx;
}
.public_info_item {
  position: relative;
  padding: 40upx 0;
  margin: 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.public_info_tit {
  font-size: 32upx;
  font-weight: 400;
  color: rgba(0, 0, 0, 1);
  width: 160upx;
}
.text_tip {
  margin: 55upx 30upx 30upx;
  font-size: 30upx;
  font-family: PingFang SC;
  /* color: rgba(153, 153, 153, 1); */
  background-color: #fff;
  padding: 28upx;
  border-radius: 24upx;
}
.text_tipTitle{
  font-weight: 700;
  text-align: center;
  font-size: 30upx;
  margin-bottom: 24upx;
}
.text_tip view {
  line-height: 50upx;
  text-align: justify;
}

.content_btn {
  margin: 30upx;
  height: 88upx;
  line-height: 88upx;
  border-radius: 44upx;
  text-align: center; 
  font-size: 36upx;
  font-weight: 500;
  color: rgba(255, 255, 255, 1);
}

.public_right_img {
  width: 30upx;
  height: 30upx;
}

.colorRed {
  color: red;
}
</style>
