<template>
  <div class="app-container">
    <el-card class="box-card" shadow="never">
      <el-form :model="queryParams" ref="queryForm" @submit.native.prevent :inline="true" v-show="showSearch" label-width="100px">
        <el-form-item label="卡号" prop="cardNo">
          <el-input v-model="queryParams.cardNo" placeholder="请输入卡号" clearable prefix-icon="el-icon-document" style="width: 240px"
            @keyup.enter.native="handleQuery" />
        </el-form-item>
        <el-form-item label="批次号" prop="batchNo">
          <el-input v-model="queryParams.batchNo" placeholder="请输入批次号" clearable prefix-icon="el-icon-tickets" style="width: 240px"
            @keyup.enter.native="handleQuery" />
        </el-form-item>
        <el-form-item label="所属企业" prop="companyName">
          <el-select v-model="queryParams.companyName" placeholder="请选择企业" clearable>
            <el-option v-for="company in companyData" :key="company.id" :label="company.name" :value="company.name" />
          </el-select>
        </el-form-item>
        <el-form-item label="订单号" prop="orderNo">
          <el-input v-model="queryParams.orderNo" placeholder="请输入充值订单号" clearable prefix-icon="el-icon-document" style="width: 240px"
            @keyup.enter.native="handleQuery" />
        </el-form-item>
        <!-- <el-form-item label="使用状态" prop="rechargeStatus">
          <el-select v-model="queryParams.rechargeStatus" placeholder="请选择使用状态" clearable style="width: 240px">
            <el-option v-for="dict in dict.type.recharge_use_status" :key="dict.value" :label="dict.label" :value="dict.value" />
          </el-select>
        </el-form-item> -->
        <el-form-item label="充值时间">
          <el-date-picker v-model="daterangeRechargeTime" style="width: 240px" value-format="yyyy-MM-dd" type="daterange" range-separator="至"
            start-placeholder="开始日期" end-placeholder="结束日期" />
        </el-form-item>
        <el-form-item label="激活时间">
          <el-date-picker v-model="daterangeGiveActiveTime" style="width: 240px" value-format="yyyy-MM-dd" type="daterange" range-separator="至"
            start-placeholder="开始日期" end-placeholder="结束日期" />
        </el-form-item>
        <el-form-item label="到期时间">
          <el-date-picker v-model="daterangeExpireTime" style="width: 240px" value-format="yyyy-MM-dd" type="daterange" range-separator="至"
            start-placeholder="开始日期" end-placeholder="结束日期" />
        </el-form-item>
        <el-form-item label="制卡时间">
          <el-date-picker v-model="daterangeCreateTime" style="width: 240px" value-format="yyyy-MM-dd" type="daterange" range-separator="至"
            start-placeholder="开始日期" end-placeholder="结束日期" />
        </el-form-item>
        <el-form-item>
          <el-button type="primary" icon="el-icon-search" @click="handleQuery">搜索</el-button>
          <el-button icon="el-icon-refresh" @click="resetQuery">重置</el-button>
        </el-form-item>
      </el-form>
    </el-card>

    <el-card class="box-card table-card" shadow="never">
      <div slot="header" class="clearfix">
        <el-row :gutter="10" class="mb8">
          <el-col :span="1.5">
            <el-button type="info" plain icon="el-icon-upload2" @click="handleImport(1)" v-hasPermi="['system:user:import']">充值卡导入</el-button>
          </el-col>
          <el-col :span="1.5">
            <el-button type="info" plain icon="el-icon-upload2" @click="handleImport(2)" v-hasPermi="['system:user:import']">用户直充导入</el-button>
          </el-col>
          <el-col :span="1.5">
            <el-button type="warning" plain icon="el-icon-download" @click="handleExport" v-hasPermi="['recharge:card:export']">导出</el-button>
          </el-col>
          <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
        </el-row>
      </div>
      <el-tabs v-model="queryParams.rechargeStatus" @tab-click="getList">
        <el-tab-pane :label="item.label" :name="item.value" v-for="(item, i) in dict.type.recharge_use_status" :key="i"></el-tab-pane>
      </el-tabs>
      <Page uri="/mapi/recharge/card/list" :request-params="queryParams" ref="pagination">
        <el-table-column label="卡号" align="center" prop="cardNo" min-width="180" fixed="left" :show-overflow-tooltip="true" />
        <el-table-column label="批次号" align="center" prop="batchNo" min-width="150" :show-overflow-tooltip="true">
          <template slot-scope="scope">
            {{ scope.row.batchNo || '--' }}
          </template>
        </el-table-column>
        <el-table-column label="所属企业" align="center" prop="companyName" min-width="130" :show-overflow-tooltip="true" />
        <el-table-column label="归属门店" align="center" prop="rechargeStoreName" min-width="150" :show-overflow-tooltip="true" />
        <el-table-column label="充值金额" align="center" min-width="120">
          <template slot-scope="scope">
            <span class="amount">{{ scope.row.rechargeAmount }}</span>
          </template>
        </el-table-column>
        <el-table-column label="卡内金额" align="center" min-width="200">
          <template slot-scope="scope">
            <div class="amount-info">
              <el-tag size="mini" type="success">现金：¥{{ scope.row.rechargeAmount }}</el-tag>
              <el-tag size="mini" type="warning">赠送：¥{{ scope.row.giveAmount }}</el-tag>
              <el-tag size="mini" type="info">福利：¥{{ scope.row.welfareAmount }}</el-tag>
            </div>
          </template>
        </el-table-column>
        <el-table-column label="卡内余额" align="center" min-width="200">
          <template slot-scope="scope">
            <div class="amount-info">
              <el-tag size="mini" type="success">现金：¥{{ scope.row.rechargeBalance }}</el-tag>
              <el-tag size="mini" type="warning">赠送：¥{{ scope.row.giveBalance }}</el-tag>
              <el-tag size="mini" type="info">福利：¥{{ scope.row.welfareBalance }}</el-tag>
            </div>
          </template>
        </el-table-column>
        <el-table-column label="赠送积分" align="center" min-width="120">
          <template slot-scope="scope">
            <span class="points">{{ scope.row.givePointAmount || '0' }}</span>
          </template>
        </el-table-column>
        <el-table-column label="使用状态" align="center" width="100">
          <template slot-scope="scope">
            <dict-tag :options="dict.type.recharge_use_status" :value="scope.row.rechargeStatus" />
          </template>
        </el-table-column>
        <el-table-column label="充值用户" align="center" min-width="120">
          <template slot-scope="scope">
            <el-tag size="mini" type="info" v-if="!scope.row.rechargeUserName">未激活</el-tag>
            <span v-else>{{ scope.row.rechargeUserName }}</span>
          </template>
        </el-table-column>
        <el-table-column label="充值时间" align="center" width="160">
          <template slot-scope="scope">
            <span>{{ scope.row.rechargeTime || '--' }}</span>
          </template>
        </el-table-column>
        <el-table-column label="储值门店" align="center" min-width="150" :show-overflow-tooltip="true">
          <template slot-scope="scope">
            {{ scope.row.useBindStoreName || '--' }}
          </template>
        </el-table-column>
        <el-table-column label="赠送金额激活时间" align="center" width="160">
          <template slot-scope="scope">
            <el-tag size="mini" type="info" v-if="!scope.row.giveActiveTime">未激活</el-tag>
            <span v-else>{{ scope.row.giveActiveTime }}</span>
          </template>
        </el-table-column>
        <el-table-column label="制卡人" align="center" prop="createBy" min-width="120" />
        <el-table-column label="制卡时间" align="center" prop="createTime" width="160" />
        <el-table-column label="操作" align="center" width="120" fixed="right">
          <template slot-scope="scope">
            <el-button type="text" icon="el-icon-tickets" @click="handleDetail(scope.row)" >消费明细</el-button>
          </template>
        </el-table-column>
      </Page>
    </el-card>

    <!-- 充值卡导入对话框 -->
    <el-dialog :title="upload.title" :visible.sync="upload.open" width="700px" append-to-body destroy-on-close :close-on-click-modal="false">
      <el-card class="box-card" shadow="never">
        <el-form ref="importForm" :model="importForm" :rules="rules" label-width="110px">
          <el-form-item label="批次名称" prop="batchName">
            <el-input v-model="importForm.batchName" placeholder="请输入批次名称" />
          </el-form-item>
          <el-form-item label="批次备注" prop="remark">
            <el-input type="textarea" v-model="importForm.remark" placeholder="请输入批次备注" />
          </el-form-item>
          <el-form-item label="激活过期时间" prop="expireTime" v-if="this.upload.title == '充值卡导入'">
            <el-date-picker v-model="importForm.expireTime" type="date" value-format="yyyy-MM-dd" placeholder="选择日期" style="width: 100%" />
          </el-form-item>
        </el-form>
      </el-card>

      <el-upload ref="upload" :limit="1" accept=".xlsx, .xls" :headers="upload.headers"
        :action="num == 1 ? upload.url + '?batchName=' + importForm.batchName + '&expireTime=' + importForm.expireTime + '&remark=' + importForm.remark : upload.url2 + '?batchName=' + importForm.batchName + '&expireTime=' + importForm.expireTime + '&remark=' + importForm.remark"
        :disabled="upload.isUploading" :on-progress="handleFileUploadProgress" :on-success="handleFileSuccess" :auto-upload="false" drag>
        <i class="el-icon-upload"></i>
        <div class="el-upload__text">将文件拖到此处，或<em>点击上传</em></div>
        <div class="el-upload__tip text-center" slot="tip">
          <span>仅允许导入xls、xlsx格式文件。</span>
          <el-link type="primary" :underline="false" style="font-size: 12px; vertical-align: baseline" @click="importTemplate">下载模板</el-link>
        </div>
      </el-upload>
      <div slot="footer" class="dialog-footer">
        <el-button type="primary" @click="submitFileForm">确 定</el-button>
        <el-button @click="upload.open = false">取 消</el-button>
      </div>
    </el-dialog>

    <!-- 消费明细对话框 -->
    <el-dialog :title="title" :visible.sync="open" width="800px" append-to-body destroy-on-close :close-on-click-modal="false">
      <el-timeline v-for="detail in billMstrDataList" :key="detail.id">
        <el-timeline-item :timestamp="handleTitle(detail)" placement="top">
          <el-card class="box-card" shadow="never">
            <el-descriptions :column="2" border>
              <el-descriptions-item label="订单类型">
                <dict-tag :options="dict.type.order_type" :value="detail.orderType" />
              </el-descriptions-item>
              <el-descriptions-item label="支付方式">
                <dict-tag :options="dict.type.recharge_pay_type" :value="detail.payType" />
              </el-descriptions-item>
              <el-descriptions-item label="消费类型">
                {{ detail.billType == 0 ? '支出' : '充值' }}
              </el-descriptions-item>
              <el-descriptions-item label="消费来源">
                {{ detail.orgName || 'APP' }}
              </el-descriptions-item>
            </el-descriptions>

            <div class="amount-info" style="margin-top: 15px">
              <el-tag size="mini" type="danger" v-if="detail.cashPayAmount != 0"> 现金支付：¥{{ formatAmount(detail.cashPayAmount, detail.isRefund) }}
              </el-tag>
              <el-tag size="mini" type="success" v-if="detail.rechargePayAmount != 0">
                充值余额：¥{{ formatAmount(detail.rechargePayAmount, detail.isRefund) }} </el-tag>
              <el-tag size="mini" type="warning" v-if="detail.givePayAmount != 0"> 赠送余额：¥{{ formatAmount(detail.givePayAmount, detail.isRefund) }}
              </el-tag>
              <el-tag size="mini" type="info" v-if="detail.welfarePayAmount != 0"> 福利余额：¥{{ formatAmount(detail.welfarePayAmount, detail.isRefund) }}
              </el-tag>
            </div>
          </el-card>
        </el-timeline-item>
      </el-timeline>
    </el-dialog>
  </div>
</template>

<script>
import { listCard, getCard, delCard, addCard, updateCard, updateCardStatus, getCardBillMstrInfo } from '@/api/recharge/card'
import { getToken } from '@/utils/auth'
import { getRechargeRecordByUserId } from '@/api/recharge/order'

export default {
  name: 'Card',
  dicts: ['recharge_use_status', 'recharge_pay_type', 'order_type'],
  data() {
    return {
      // 遮罩层
      loading: true,
      // 选中数组
      ids: [],
      // 非单个禁用
      single: true,
      // 非多个禁用
      multiple: true,
      // 显示搜索条件
      showSearch: true,
      // 总条数
      total: 0,
      // 密码充值卡管理表格数据
      cardList: [],
      // 弹出层标题
      title: '',
      // 是否显示弹出层
      open: false,
      // 赠送积分时间范围
      daterangeRechargeTime: [],
      // 赠送积分时间范围
      daterangeExpireTime: [],
      // 赠送积分时间范围
      daterangeCreateTime: [],
      // 赠送积分时间范围
      daterangeGiveActiveTime: [],
      companyData: [],
      // 查询参数
      queryParams: {
        cardNo: null,
        rechargeStatus: 0,
        rechargeTime: null,
        expireTime: null,
        createTime: null
      },
      // 表单参数
      form: {},
      importForm: {},
      importRechargeForm: {},
      // 表单校验
      rules: {
        cardNo: [{ required: true, message: '卡号不能为空', trigger: 'blur' }],
        password: [{ required: true, message: '卡密不能为空', trigger: 'blur' }],
        rechargeAmount: [{ required: true, message: '充值金额不能为空', trigger: 'blur' }],
        giveAmount: [{ required: true, message: '赠送金额不能为空', trigger: 'blur' }],
        givePointAmount: [{ required: true, message: '赠送积分不能为空', trigger: 'blur' }],
        rechargeStatus: [{ required: true, message: '使用状态不能为空', trigger: 'blur' }],
        batchName: [
          { required: true, message: '请输入批次名称', trigger: 'blur' },
          { min: 2, max: 50, message: '批次名称长度在 2 到 50 个字符', trigger: 'blur' }
        ],
        remark: [{ max: 200, message: '备注长度不能超过200个字符', trigger: 'blur' }],
        expireTime: [
          { required: true, message: '请选择过期时间', trigger: 'blur' }
        ]
      },
      // 充值卡导入参数
      upload: {
        // 是否显示弹出层（充值卡导入）
        open: false,
        // 弹出层标题（充值卡导入）
        title: '',
        // 是否禁用上传
        isUploading: false,
        // 是否更新已经存在的充值卡数据
        // updateSupport: 0,
        batchName: '',
        expireTime: null,
        level: 0,
        starLevel: 0,
        // 设置上传的请求头部
        headers: { Authorization: 'Bearer ' + getToken() },
        // 上传的地址
        url: process.env.VUE_APP_BASE_API + '/mapi/recharge/card/importData',
        url2: process.env.VUE_APP_BASE_API + '/mapi/recharge/card/directChargingImportData'
      },
      num: null,
      billMstrDataList: [], // 消费记录
      datePickerOptions: {
        shortcuts: [
          {
            text: '最近一周',
            onClick(picker) {
              const end = new Date()
              const start = new Date()
              start.setTime(start.getTime() - 3600 * 1000 * 24 * 7)
              picker.$emit('pick', [start, end])
            }
          },
          {
            text: '最近一个月',
            onClick(picker) {
              const end = new Date()
              const start = new Date()
              start.setTime(start.getTime() - 3600 * 1000 * 24 * 30)
              picker.$emit('pick', [start, end])
            }
          },
          {
            text: '最近三个月',
            onClick(picker) {
              const end = new Date()
              const start = new Date()
              start.setTime(start.getTime() - 3600 * 1000 * 24 * 90)
              picker.$emit('pick', [start, end])
            }
          }
        ]
      }
    }
  },
  computed: {
    uploadDisabled() {
      return !this.importForm.batchName || this.upload.isUploading
    }
  },
  created() {
    this.getList()
    this.getCompanyData()
  },
  methods: {
    handleTitle(detail) {
      let tOrder = '订单编号:' + detail.orderNo
      let tPay = detail.isRefund == 'Y' && detail.payTotalAmount.toString() != '0' ? '退款总金额：' + detail.payTotalAmount.toString().replace('-', '') + '元' : '\u00a0\u00a0\u00a0\u00a0\u00a0 总支付金额：' + detail.payTotalAmount.toString().replace('-', '') + '元'
      let tTime = '\u00a0\u00a0\u00a0\u00a0\u00a0消费时间：' + detail.createTime

      return tOrder + tPay + tTime
    },
    /** 查询密码充值卡管理列表 */
    getList() {
      this.loading = true
      this.queryParams.params = {}
      if (null != this.daterangeRechargeTime && '' != this.daterangeRechargeTime) {
        this.queryParams['beginRechargeTime'] = this.daterangeRechargeTime[0]
        this.queryParams['endRechargeTime'] = this.daterangeRechargeTime[1]
      } else {
        delete this.queryParams.beginRechargeTime
        delete this.queryParams.endRechargeTime
      }
      if (null != this.daterangeGiveActiveTime && '' != this.daterangeGiveActiveTime) {
        this.queryParams['beginGiveActiveTime'] = this.daterangeGiveActiveTime[0]
        this.queryParams['endGiveActiveTime'] = this.daterangeGiveActiveTime[1]
      } else {
        delete this.queryParams.beginGiveActiveTime
        delete this.queryParams.endGiveActiveTime
      }
      if (null != this.daterangeExpireTime && '' != this.daterangeExpireTime) {
        this.queryParams['beginExpireTime'] = this.daterangeExpireTime[0]
        this.queryParams['endExpireTime'] = this.daterangeExpireTime[1]
      } else {
        delete this.queryParams.beginExpireTime
        delete this.queryParams.endExpireTime
      }
      if (null != this.daterangeCreateTime && '' != this.daterangeCreateTime) {
        this.queryParams['beginCreateTime'] = this.daterangeCreateTime[0]
        this.queryParams['endCreateTime'] = this.daterangeCreateTime[1]
      } else {
        delete this.queryParams.beginCreateTime
        delete this.queryParams.endCreateTime
      }
      this.$nextTick(() => {
        this.$refs.pagination.handleSearch(true)
      })
    },
    // 取消按钮
    cancel() {
      this.open = false
      this.reset()
    },
    // 表单重置
    reset() {
      this.form = {
        id: null,
        cardNo: null,
        password: null,
        cardVersionId: null,
        rechargeAmount: null,
        giveAmount: null,
        givePointAmount: null,
        rechargeBalance: null,
        giveBalance: null,
        welfareBalance: null,
        pointBalance: null,
        rechargeStatus: '0',
        rechargeTime: null,
        rechargeStoreId: null,
        rechargeUserId: null,
        expireTime: null,
        orderNo: null,
        createById: null,
        createBy: null,
        createTime: null,
        updateById: null,
        updateBy: null,
        updateTime: null,
        remark: null
      }
      this.resetForm('form')
    },
    /** 搜索按钮操作 */
    handleQuery() {
      this.getList()
    },
        getCompanyData() {
      this.getGroupData("company_info").then((res) => {
        this.companyData = res.data
      })
    },
    /** 重置按钮操作 */
    resetQuery() {
      this.daterangeRechargeTime = []
      this.daterangeExpireTime = []
      this.daterangeCreateTime = []
      this.resetForm('queryForm')
      this.handleQuery()
    },
    // 多选框选中数据
    handleSelectionChange(selection) {
      this.ids = selection.map((item) => item.id)
      this.single = selection.length !== 1
      this.multiple = !selection.length
    },
    /** 导出按钮操作 */
    handleExport() {
      this.download(
        'mapi/recharge/card/export',
        {
          ...this.queryParams
        },
        `card_${new Date().getTime()}.xlsx`
      )
    },
    checkClose(done) {
      this.$confirm('是否关闭表单，关闭后数据将丢失？')
        .then(function () {
          done()
        })
        .then(() => { })
        .catch(() => { })
    },
    /** 导入按钮操作 */
    handleImport(num) {
      this.num = num
      this.importForm = {
        level: 0,
        starLevel: 1,
        batchName: '',
        remark: '',
        expireTime: ''
      }
      this.upload.title = num === 1 ? '充值卡导入' : '用户直充导入'
      this.upload.open = true
    },
    /** 下载模板操作 */
    importTemplate() {
      if (this.num == 1) {
        this.download('mapi/recharge/card/importTemplate', {}, `recharge_card_template_${new Date().getTime()}.xlsx`)
      } else {
        this.download('mapi/recharge/card/importDirectChargingTemplate', {}, `direct_recharge_template_${new Date().getTime()}.xlsx`)
      }
    },
    // 文件上传中处理
    handleFileUploadProgress(event, file, fileList) {
      this.upload.isUploading = true
    },
    // 文件上传成功处理
    handleFileSuccess(response, file, fileList) {
      this.upload.open = false
      this.upload.isUploading = false
      this.$refs.upload.clearFiles()
      var respMsg = response.code == '200' ? '' : '导入失败！'
      this.$alert("<div style='overflow: auto;overflow-x: hidden;max-height: 70vh;padding: 10px 20px 0;'>" + respMsg + '<br/>' + response.msg + '</div>', '导入结果', { dangerouslyUseHTMLString: true })
      this.getList()
    },
    // 提交上传文件
    submitFileForm() {
      if (!this.importForm.batchName) {
        this.$modal.msgError('请输入批次名称')
        return false
      }
      if (!this.importForm.expireTime) {
        this.$modal.msgError('请选择过期时间')
        return false
      }
      this.$refs.upload.submit()
    },
    /** 消费明细详情 */
    handleDetail(row) {
      this.reset()
      getCardBillMstrInfo(row.id).then((response) => {
        this.billMstrDataList = response.data
        this.open = true
        this.title = '消费明细详情'
      })
    },
    /** 格式化金额显示 */
    formatAmount(amount, isRefund = false) {
      if (!amount) return '0.00'
      const value = parseFloat(amount.toString().replace('-', '')).toFixed(2)
      return isRefund ? `退款：${value}` : value
    },
    /** 处理时间范围变化 */
    handleTimeRangeChange(val, type) {
      if (!val) {
        switch (type) {
          case 'recharge':
            delete this.queryParams.beginRechargeTime
            delete this.queryParams.endRechargeTime
            break
          case 'giveActive':
            delete this.queryParams.beginGiveActiveTime
            delete this.queryParams.endGiveActiveTime
            break
          case 'expire':
            delete this.queryParams.beginExpireTime
            delete this.queryParams.endExpireTime
            break
          case 'create':
            delete this.queryParams.beginCreateTime
            delete this.queryParams.endCreateTime
            break
        }
      }
    }
  }
}
</script>

<style lang="scss" scoped>
.app-container {
    padding: 20px;
    background-color: #f5f7fa;

    .box-card {
        margin-bottom: 20px;
        transition: all 0.3s ease-in-out;

        &.table-card {
            margin-bottom: 0;
        }

        &:hover {
            box-shadow: 0 2px 12px 0 rgba(0, 0, 0, 0.1);
        }
    }

    :deep(.el-card__header) {
        padding: 15px 20px;
        border-bottom: 1px solid #ebeef5;
        background-color: #fafafa;
    }

    :deep(.el-card__body) {
        padding: 20px;
    }

    .amount {
        color: #f56c6c;
        font-weight: 500;
        font-size: 14px;

        &::before {
            content: '¥';
            margin-right: 2px;
            font-size: 12px;
        }
    }

    .points {
        color: #e6a23c;
        font-weight: 500;
        font-size: 14px;
    }

    .amount-info {
        .el-tag {
            margin: 0 4px;
            transition: all 0.3s ease;

            &:first-child {
                margin-left: 0;
            }

            &:last-child {
                margin-right: 0;
            }

            &:hover {
                transform: translateY(-1px);
            }
        }
    }

    :deep(.el-timeline-item__timestamp) {
        font-size: 13px !important;
        color: #606266;
    }

    :deep(.el-descriptions) {
        margin: 10px 0;

        .el-descriptions-item__label {
            width: 120px;
            font-weight: bold;
            background-color: #fafafa;
        }

        .el-descriptions-item__content {
            padding: 12px 15px;
        }
    }

    :deep(.el-table) {
        .el-table__header th {
            background-color: #fafafa;
            color: #606266;
            font-weight: bold;
        }

        .el-table__row {
            transition: all 0.3s ease;

            &:hover {
                background-color: #f5f7fa;
            }
        }
    }

    :deep(.el-upload-dragger) {
        width: 100%;
        height: 200px;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        border: 2px dashed #d9d9d9;
        border-radius: 6px;
        transition: all 0.3s ease;

        &:hover {
            border-color: #409eff;

            .el-icon-upload {
                color: #409eff;
            }
        }

        .el-icon-upload {
            font-size: 48px;
            color: #c0c4cc;
            margin-bottom: 10px;
            transition: all 0.3s ease;
        }

        .el-upload__text {
            font-size: 14px;
            color: #606266;

            em {
                color: #409eff;
                font-style: normal;
            }
        }
    }

    .dialog-footer {
        text-align: center;
        padding-top: 20px;
    }
}
</style>
