<!--检斤管理-->
<template>
  <div>
    <BaseHeaderLayout :leftSpan="10">
      <template slot="left">
        <ws-button type="primary" @click="print('',1)"
          v-hasPermission="`acquisitionManagement.acquisitionWeight.print`">批量打印
        </ws-button>
        <el-upload style="margin-left: 8px;" class="upload-demo inline-block margin-right-10" action=""
          :on-change="handleChange" :show-file-list="false"
          accept=".csv, application/vnd.openxmlformats-officedocument.spreadsheetml.sheet, application/vnd.ms-excel"
          :auto-upload="false">
          <el-button type="primary" class="show-excel">excel导入打印</el-button>
        </el-upload>
      </template>
      <template slot="right">
        <ws-select v-model="warehouseName" placeholder="" @change="warehouseNameChange" :value="searchType"
          style="margin: 0 10px;width:400px">
          <ws-option v-for="item in warehouseList" :key="item.value" :label="item.value" :value="item.value"
            style="color: #8890b1" />
        </ws-select>
        <el-date-picker style="margin: 0 10px 0 0" value-format='yyyy-MM-dd' v-model="value2" @change='datechange'
          type="daterange" align="right" unlink-panels range-separator="至" start-placeholder="起始时间"
          end-placeholder="截止时间">
        </el-date-picker>
        <div></div>
        <ws-input class='findinput' @keyup.enter.native="find()" v-model="searchKeyWord" placeholder="可按编号、客户名、车牌号、货名查找"
          clearable maxlength="500" type="input">
        </ws-input>
        <ws-button class="find" type="primary" @click="find()"><img width="16" height="16" style="
              vertical-align: text-top;
              position: relative;
              top: 0px;
              left:-8px;
            " src="../../../public/img/sousuo.png" alt="" /></ws-button>
      </template>
    </BaseHeaderLayout>
    <el-table :data="weighingList" style="width: 100%; margin-top: 20px" ref="weighingList" border height="calc(100% - 130px)"
      @row-click="handleRowClick" @selection-change="handleSelectionChange">
      <el-table-column type="selection" width="55"></el-table-column>
      <el-table-column type="index" label="序号" width="50">
        <template scope="scope">
          <span v-if="scope.$index < 9">0{{ scope.$index + 1 }}</span>
          <span v-else>{{ scope.$index + 1 }}</span>
        </template>
      </el-table-column>
      <el-table-column prop="number" width="150" label="编号"></el-table-column>
      <el-table-column prop="customer" label="客户"></el-table-column>
      <el-table-column prop="carNumber" label="车牌号"></el-table-column>
      <!-- <el-table-column prop="boxNo" label="箱号-1">
        <template slot-scope="scope">
          <div v-if='scope.row.qualityInspectionManagement.boxNo'>{{scope.row.qualityInspectionManagement.boxNo}}</div>
        </template>
      </el-table-column>
      <el-table-column prop="boxNoOther" label="箱号-2">
        <template slot-scope="scope">
          <div v-if='scope.row.qualityInspectionManagement.boxNoOther'>
            {{scope.row.qualityInspectionManagement.boxNoOther}}
          </div>
        </template>
      </el-table-column>
      <el-table-column prop="titleNo" label="封号-1">
        <template slot-scope="scope">
          <div v-if='scope.row.qualityInspectionManagement.titleNo'>{{scope.row.qualityInspectionManagement.titleNo}}
          </div>
        </template>
      </el-table-column>
      <el-table-column prop="titleNoOther" label="封号-2">
        <template slot-scope="scope">
          <div v-if='scope.row.qualityInspectionManagement.titleNoOther'>
            {{scope.row.qualityInspectionManagement.titleNoOther}}
          </div>
        </template>
      </el-table-column> -->
      <el-table-column prop="goodsName" label="货名"></el-table-column>
      <el-table-column prop="type" label="类型"></el-table-column>
      <el-table-column prop="grossWeight" label="毛重（公斤）" width="120"></el-table-column>
      <el-table-column prop="tare" label="皮重（公斤）" width="120"></el-table-column>
      <el-table-column prop="buckleMiscellaneous" label="扣杂"></el-table-column>
      <el-table-column prop="netWeight" label="净重（公斤）" width="120"></el-table-column>
      <el-table-column prop="binNumber" label="仓位号"></el-table-column>
      <el-table-column prop="storageNumber" label="囤位号"></el-table-column>
      <el-table-column prop="secretaryWeigher" label="司称员">
        <template slot-scope="scope">
          <div v-if="scope.row.secretaryWeigher == scope.row.skinInspector">{{scope.row.skinInspector}}</div>
          <div v-else>{{scope.row.secretaryWeigher}}<span
              v-if="scope.row.skinInspector">,{{scope.row.skinInspector}}</span></div>
        </template>
      </el-table-column>
      <el-table-column prop="suqualityTestingDate" label="称重时间" width="90">
        <template slot-scope="scope">
          <div v-if="
              scope.row.status == '已称毛重'
            "> {{scope.row.grossDate}}</div>
          <div v-if="
              scope.row.status == '已称皮重'
            "> {{scope.row.tareDate}}</div>
        </template>
      </el-table-column>
      <el-table-column prop="status" label="状态"></el-table-column>
      <el-table-column width="270" prop="contractNo1" label="操作">
        <template slot-scope="scope">
          <el-button @click="weightCheck(scope.row, 1)" v-if=" scope.row.status == '已称毛重' || scope.row.status == '已质检' "
            v-hasPermission="`acquisitionManagement.acquisitionWeight.mao`">毛重</el-button>
          <!-- scope.row.paymentManagement.status == '待结算' && -->
          <el-button :disabled="scope.row.allow == 2" @click="weightCheck(scope.row, 2)"
            v-if=" (scope.row.status == '已称毛重' || scope.row.status == '已称皮重') "
            v-hasPermission="`acquisitionManagement.acquisitionWeight.weight`">皮重</el-button>
          <div style="display: inline-block;">
            <el-button @click="del(scope.row)" type="danger"
              v-hasPermission="`acquisitionManagement.acquisitionQuality.delete`">删除</el-button>
          </div>
          <el-button @click="print(scope.row)" v-if="scope.row.status == '已称皮重' ||scope.row.status == '已称毛重'"
            v-hasPermission="`acquisitionManagement.acquisitionWeight.print`">打印</el-button>
        </template>
      </el-table-column>
    </el-table>
    <div style="text-align: center;margin-top:20px">
      <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange" :current-page="currentPage"
        :page-size="deptCircularPage.pageSize" layout="total, sizes, prev, pager, next, jumper"
        :total="deptBudgetTotal">
      </el-pagination>
    </div>
    <div class="mask" v-show="isShowPrintType"></div>
    <div class="print-type" v-show="isShowPrintType">
      <div class="print-type-content">
        <div class="print-type-title">请选择打印纸张类型</div>
        <div class="print-type-checkbox">
          <el-radio-group v-model="radio">
            <el-radio label="A4" class="label-width" @change="selectType">A4</el-radio>
            <el-radio label="A5" class="label-width" @change="selectType">A5</el-radio>
          </el-radio-group>
        </div>
      </div>
      <div class="bottom-btn">
        <el-button @click="typePrintClick">确定</el-button>
        <el-button @click="typePrintCannelClick">取消</el-button>
      </div>
    </div>
    <el-dialog width="70%" class="table-content" center :visible.sync="isShowPrint" title="粮食检斤单">
      <weightCheckPrint :tableData="dialogData"></weightCheckPrint>
      <div style="text-align:center">
        <el-button type="primary" @click="isShowPrint = false">关闭</el-button>
        <el-button type="primary" @click="printSmall">打印小票</el-button>
        <el-button type="primary" @click="printBig">打印单据</el-button>
      </div>
    </el-dialog>
  </div>
</template>
<script>
  import {
    getweighingList,
    getweighingDelete,
    selectWarehouseSelf,
    getPrint
  } from '@/model/houseSelfCollect/index'
  import weightCheckPrint from './component/weightCheckPrint.vue'

  export default {
    components: {
      weightCheckPrint
    },
    watch: {},
    data() {
      return {
        //分页
        currentPage: 1,
        pageSize: 10,
        deptCircularPage: {},
        deptBudgetTotal: 0,
        paymentForm: false,
        paymentForm1: false,
        weighingList: [],
        searchKeyWord: '',
        searchType: [],
        warehouseName: '',
        value1: '', //选择时间
        warehouseList: [],
        warehouseId: '',
        cangid: '',
        monitorUrl1: '',
        monitorUrl2: '',
        isShowPrint: false, //打印弹出
        dialogData: {
          qualityInspectionManagement: {},
        },
        purchasePriceList: [],
        allowEdit: '0',
        disabled: false,
        isShowPrintType: false,
        modification: [],
        jjSelectPrintList: [],
        radio: 'A4',
        value2: [],
        startDate: '',
        endDate: '',
        excelPrintData: [],
        isExcelPrint: false,
      }
    },
    activated() {
      this.selectWarehouse()

    },
    methods: {
      selectType(val) {
        console.log(val)
        // for (let i = 0; i < this.ruleForm.type.length; i++) {
        //   switch (this.ruleForm.type[i]) {
        //     case '打印身份证（正反面）':
        //       this.isShowPrintType1 = !this.isShowPrintType1
        //       break
        //     case '打印银行卡（正反面）':
        //       this.isShowPrintType2 = !this.isShowPrintType2
        //       break
        //     case '打印结算凭证':
        //       this.isShowPrintType3 = !this.isShowPrintType3
        //     case '打印发票':
        //       this.isShowPrintType4 = !this.isShowPrintType4
        //       break
        //   }
        // }
      },
      handleChange(file, fileList) {
        this.jjSelectPrintList = []
        this.fileTemp = file.raw
        let fileName = file.raw.name
        let fileType = fileName.substring(fileName.lastIndexOf('.') + 1);
        // 判断上传文件格式
        if (this.fileTemp) {
          if ((fileType == 'xlsx') || (fileType == 'xls')) {
            this.importf(this.fileTemp)
          } else {
            this.$message({
              type: 'warning',
              message: '附件格式错误，请删除后重新上传！'
            })
          }
        } else {
          this.$message({
            type: 'warning',
            message: '请上传附件！'
          })
        }

      },
      importf(obj) {
        this.excelFreightspace = []
        this.dialogVisible = true;
        let _this = this;
        let inputDOM = this.$refs.inputer; // 通过DOM取文件数据
        this.file = event.currentTarget.files[0];
        var rABS = false; //是否将文件读取为二进制字符串
        var f = this.file;
        var reader = new FileReader();
        //if (!FileReader.prototype.readAsBinaryString) {
        FileReader.prototype.readAsBinaryString = function(f) {
          var binary = '';
          var rABS = false; //是否将文件读取为二进制字符串
          var pt = this;
          var wb; //读取完成的数据
          var outdata;
          var reader = new FileReader();
          reader.onload = function(e) {
            var bytes = new Uint8Array(reader.result);
            var length = bytes.byteLength;
            for (var i = 0; i < length; i++) {
              binary += String.fromCharCode(bytes[i]);
            }
            var XLSX = require('xlsx');
            if (rABS) {
              wb = XLSX.read(btoa(fixdata(binary)), {
                type: 'base64',
                cellDates: true
              });
            } else {
              wb = XLSX.read(binary, {
                type: 'binary'
              });
            }
            // excel导入的数据
            outdata = XLSX.utils.sheet_to_json(wb.Sheets[wb.SheetNames[0]]);
            let arr = []
            let _index = 0
            outdata.map(v => {
              _index++
              let jsonString = JSON.stringify(v).replace(/\//g, '').replace(/\s/ig, '');
              console.log(jsonString);
              v = JSON.parse(jsonString);
              let obj = {
                qualityInspectionManagement: {}
              }
              obj.compName = v.公司名
              obj.number = v.编号
              obj.customer = v.客户姓名
              obj.customerPhone = v.客户电话
              obj.carNumber = v.车牌号
              obj.compName = v.收货单位
              obj.person = v.联系人
              obj.personPhone = v.联系电话
              obj.goodsName = v.货名
              obj.type = v.类型
              obj.qualityInspectionManagement.bulkDensity = v.容重
              obj.qualityInspectionManagement.imperfectGrain = v.不完善粒
              obj.qualityInspectionManagement.grade = v.等级
              obj.qualityInspectionManagement.waterContent = v.水分
              obj.qualityInspectionManagement.jiaorenli = v.热损伤
              obj.qualityInspectionManagement.qualityDate = v.质检时间
              obj.qualityInspectionManagement.impurity = v.杂质
              obj.qualityInspectionManagement.mildewGrain = v.霉变粒
              obj.qualityInspectionManagement.buckleMiscellaneous = v.扣杂
              obj.grossWeight = v.毛重
              obj.tare = v.皮重
              obj.buckleMiscellaneous = v.扣重
              obj.netWeight = v.净重
              obj.grossDate = v.毛重检斤时间
              obj.tareDate = v.皮重检斤时间
              obj.secretaryWeigher = v.毛检
              obj.skinInspector = v.皮检

              console.log(obj)
              _this.excelPrintData.push(obj)
              if (_index == outdata.length) {
                _this.isShowPrintType = true
                _this.isExcelPrint = true
              }
            })
          }
          reader.readAsArrayBuffer(f);
        }
        if (rABS) {
          reader.readAsArrayBuffer(f);
        } else {
          reader.readAsBinaryString(f);
        }
        console.log(reader)
      },
      handleRowClick(row) {},
      handleSelectionChange(val) {
        this.modification = val
      },
      printSmall() {
        window.open('../../../../static/weightCheck.html?type=1&tableData=' + JSON.stringify(this.dialogData))
      },
      printBig(type, radioType) {
        if (type == 1) {
          localStorage.setItem('selectPrint_jjSelectPrintList', JSON.stringify(this.jjSelectPrintList))
          window.open('../../../../static/weightCheck.html?type=2&radioType=' + radioType)
        } else if (type == 2) {
          localStorage.setItem('selectPrint_jjSelectPrintList', JSON.stringify(this.excelPrintData))
          window.open('../../../../static/weightCheck.html?type=2&radioType=' + radioType)
        } else {

          window.open('../../../../static/weightCheck.html?type=2&tableData=' + JSON.stringify(this.dialogData))
        }
      },
      typePrintClick(type) {
        if (this.isExcelPrint) {
          this.printBig(2, this.radio)
          this.isExcelPrint = false

        } else {
          this.jjSelectPrintList = []
          let index1 = 0;
          for (let i = 0; i < this.modification.length; i++) {
            getPrint({
                id: this.modification[i].id
              })
              .toPromise()
              .then((response) => {
                index1++;
                if (response.compName == '黑龙江秋收有限公司') {
                  response.compName = '黑龙江中天昊元贸易有限公司'
                }
                this.jjSelectPrintList.push(response)
                if (index1 == this.modification.length) {
                  this.printBig(1, this.radio)
                }
              })
              .catch((response) => {})
          }
        }


      },
      typePrintCannelClick() {
        this.isShowPrintType = false
      },
      print(row, type, pageType) {
        if (type == 1) {
          this.isShowPrintType = true
        } else {
          getPrint({
              id: row.id
            })
            .toPromise()
            .then((response) => {
              // let printString = localStorage.getItem('ws-pf_compId') + "," + row.qualityNo + "," + this.cangid
              // getQRcode({printString}).toPromise()
              //       .then((res) => {//二维码
              this.isShowPrint = true
              this.dialogData = response
              // this.printData.qrCodeUrl = res
              // })
              if (response.compName == '黑龙江秋收有限公司') {
                this.dialogData.compName = '黑龙江中天昊元贸易有限公司'
              }
            })
            .catch((response) => {
              // EventBus.$emit('error', this.$t('showMessage.asteriskRequired'))
            })
        }

      },
      warehouseNameChange(e) {
        // this.warehouseName = e
        for (let i = 0; i < this.warehouseList.length; i++) {
          if (this.warehouseList[i].value == e) {
            this.warehouseId = this.warehouseList[i].warehouseId
            this.cangid = this.warehouseList[i].warehouseId
            this.allowEdit = this.warehouseList[i].allowEdit
            this.WAREHOUSE[2].payname = this.warehouseList[i].value
            this.common.name = this.warehouseList[i].value
            this.monitorUrl1 = this.warehouseList[i].monitorUrl1
            this.monitorUrl2 = this.warehouseList[i].monitorUrl2
            this.warehouseList[i].compId = localStorage.getItem('ws-pf_compId')
            localStorage.setItem('ck', e)
            localStorage.setItem('houseSelfCollect_house1', JSON.stringify(this.warehouseList[i]))
          }
        }
        this.getList()
      },
      isConfirmQuality(val) {
        if (val.qualityInspectionManagement.confirm == '1' && val.qualityInspectionManagement.warehouseName == '哈尔滨依兰库')
          return false;
        return true
      },
      weightCheck(row, num) {
        console.log(this.cangid)
        // 质检是否是已确定状态
        // let _isGoweightCheck = this.isConfirmQuality(row)
        let _isGoweightCheck = true
        console.log(row.qualityInspectionManagement)
        if (_isGoweightCheck) {
          this.$router.push({
            path: 'weightCheck',
            query: {
              tpyeNo: num,
              id: row.id,
              number: row.number,
              binNumber: row.binNumber,
              customer: row.customer,
              storageNumber: row.storageNumber,
              carNumber: row.carNumber,
              boxNo: row.qualityInspectionManagement.boxNo,
              boxNoOther: row.qualityInspectionManagement.boxNoOther,
              titleNo: row.qualityInspectionManagement.titleNo,
              titleNoOther: row.qualityInspectionManagement.titleNoOther,
              carModel: row.qualityInspectionManagement.carModel,
              goodsName: row.goodsName,
              grossWeight: row.grossWeight,
              tare: row.tare,
              netWeight: row.netWeight,
              relationId: row.relationId,
              warehouseId: this.warehouseId,
              monitorUrl1: this.monitorUrl1,
              monitorUrl2: this.monitorUrl2,
              allowEdit: this.allowEdit,
              cangid: this.cangid,
              warehouseName: this.warehouseName,
              paramType: row.qualityInspectionManagement.paramType,
              customerNumberCard: row.customerNumberCard,
              automaticWeightAcquisition: row.automaticWeightAcquisition
            },
          })
        } else {
          this.$message({
            message: '质检状态未确认，质检状态确认后称毛重！',
            type: 'warning',
          })
        }

      },
      del(row) {
        //删除
        this.$confirm('确定删除检斤信息？', '提示', {
            confirmButtonText: '确定',
            cancelButtonText: '取消',
            type: 'warning',
          })
          .then(() => {
            getweighingDelete({
                id: row.id,
              })
              .toPromise()
              .then((response) => {
                this.$notify.success({
                  title: '成功',
                  message: '删除成功',
                })
                this.getList()
              })
              .catch((response) => {
                // EventBus.$emit('error', this.$t('showMessage.asteriskRequired'))
              })
          })
          .catch(() => {
            return false
          })
      },
      find() {
        this.getList()
      },
      datechange() {
        if (this.value2) {
          this.startDate = this.value2[0]
          this.endDate = this.value2[1]
        } else {
          this.startDate = ''
          this.endDate = ''
        }
        this.getList()
      },
      handleSizeChange(val) {
        console.log(`每页 ${val} 条`)
        this.pageSize = val
        this.getList()
      },
      handleCurrentChange(val) {
        this.currentPage = val
        console.log(`当前页: ${val}`)
        this.getList()
      },
      selectWarehouse() {
        let _wareHouse = localStorage.getItem('houseSelfCollect_house1')
        _wareHouse = JSON.parse(_wareHouse)
        selectWarehouseSelf({
            compId: localStorage.getItem('ws-pf_compId'),
          })
          .toPromise()
          .then((response) => {
            this.warehouseList = []

            for (let i = 0; i < response.length; i++) {
              this.warehouseList.push({
                value: response[i].warehouseName,
                warehouseId: response[i].id,
                allowEdit: response[i].allowEdit,
                monitorUrl1: response[i].monitorUrl1,
                monitorUrl2: response[i].monitorUrl2,
                id: response[i].id,
                warehouseNo: response[i].commonWarehouseNo,
                compId: response[i].compId
              })
              if (_wareHouse && response[i].warehouseName == _wareHouse.value) {
                this.cangid = _wareHouse.warehouseId
                this.warehouseName = response[i].warehouseName
                this.common.name = _wareHouse.value
                this.warehouseId = _wareHouse.warehouseId
                this.warehouseNo = _wareHouse.warehouseNo
                this.monitorUrl1 = _wareHouse.monitorUrl1
                this.allowEdit = response[i].allowEdit
                this.monitorUrl2 = _wareHouse.monitorUrl2
              } else {
                if (this.cangid && this.cangid == response[i].id) {
                  this.warehouseName = response[i].warehouseName
                  this.allowEdit = response[i].allowEdit
                  this.common.name = response[i].warehouseName
                  this.warehouseId = response[i].id
                  this.warehouseNo = response[i].commonWarehouseNo
                  this.monitorUrl1 = response[i].monitorUrl1
                  this.monitorUrl2 = response[i].monitorUrl2
                }

                if (this.warehouseList.length > 0 && !this.cangid) {
                  this.warehouseName = this.warehouseList[0].value
                  this.allowEdit = this.warehouseList[0].allowEdit
                  this.cangid = this.warehouseList[0].warehouseId
                  this.warehouseId = this.warehouseList[0].warehouseId
                  this.WAREHOUSE[1].payname = this.warehouseList[0].value
                  this.common.name = this.warehouseList[0].value
                  this.monitorUrl1 = this.warehouseList[0].monitorUrl1
                  this.monitorUrl2 = this.warehouseList[0].monitorUrl2
                }
              }
            }
            localStorage.setItem('ck', this.common.name)
            this.getList()
          })
      },
      getList() {
        getweighingList({
            compId: localStorage.getItem('ws-pf_compId'),
            currentPage: this.currentPage,
            pageSize: this.pageSize,
            searchKeyWord: this.searchKeyWord,
            warehouseName: this.warehouseName,
            startDate: this.startDate,
            endDate: this.endDate,
            managementType: 1
          })
          .toPromise()
          .then((response) => {
            for (let i = 0; i < response.records.length; i++) {
              if (response.records[i].paymentManagement) {
                if (response.records[i].paymentManagement.approveStatus || response.records[i]
                  .paymentManagement.status != '待结算') {
                  response.records[i].allow = 2
                }
              } else {
                response.records[i].allow = 1
              }
            }
            this.weighingList = response.records
            this.common.commonWeighingList = response.records
            this.deptBudgetTotal = response.total
          })
          .catch((response) => {
            // EventBus.$emit('error', this.$t('showMessage.asteriskRequired'))
          })
      },
    },
  }
</script>
<style lang="scss" scoped>
  .title {
    font-size: 20px;
    font-weight: 600;
    margin: 20px;
  }

  .ws-info-table {
    border: none;
  }

  .ws-info-table .el-form-item {
    width: 50%;
    border: none;
  }

  /deep/.ws-info-table .el-form-item .el-form-item__label {
    width: 30%;
    text-align: center;
    background: #ffffff;
    color: #8890b1;
  }

  /deep/.ws-info-table .el-form-item .el-form-item__content {
    border: none;
  }

  /deep/.el-table .el-table__header .cell,
  .el-table .el-table__body .cell {
    text-align: center;
  }

  /deep/.el-table--enable-row-transition .el-table__body td {
    text-align: center;
  }

  .formItem {
    width: 51% !important;
  }

  /deep/.el-dialog__title {
    font-size: 24px !important;
  }

  /deep/.el-dialog__header {
    text-align: center !important;
    padding: 10px 0 !important;
    height: auto !important;
  }

  .number {
    text-align: right;
    margin: 0 0 10px 0;
  }

  table,
  table tr th,
  table tr td {
    border: 2px solid #333333;
    padding: 5px 0;
  }

  table {
    width: 100%;
    min-height: 25px;
    line-height: 25px;
    text-align: center;
    border-collapse: collapse;
    border: 3px solid #333333;
  }

  .col-bgc {
    background: #f6f7fb;
  }

  .bottom-row1 {
    display: flex;
    margin: 10px 0;
  }

  .bottom-row2 {
    display: flex;
    margin: 10px 0;

    .left {
      img {
        width: 41px;
        height: 41px;
        margin-right: 118px;
      }
    }

    .config {
      margin-top: 20px;
      margin-right: 240px;
    }

    .autograph {
      margin-top: 20px;
    }
  }

  .bottom-row3 {
    margin: 10px 0;
  }

  .bottom-row4 {
    margin-top: 50px;
    text-align: center;
  }

  .mask {
    background: black;
    width: 100vw;
    height: 100vh;
    position: fixed;
    top: 0;
    z-index: 99;
    opacity: 0.3;
  }

  .print-type-title {
    text-align: center;
    font-size: 18px;
    margin: 20px;
  }

  .bottom-btn {
    display: flex;
    margin-top: 20px;
    justify-content: space-around;
  }

  .print-type-checkbox {
    // padding-left: 20px;
  }

  .print-type {
    position: absolute;
    top: 0;
    bottom: 0;
    left: 0;
    right: 0;
    margin: auto;
    width: 220px;
    height: 160px;
    background: white;
    border-radius: 10px;
    z-index: 999;
  }

  /deep/.el-radio-group {
    width: 100%;
    display: flex;
  }

  /deep/.el-radio__label {
    font-size: 20px;
  }

  /deep/.el-radio__inner {
    // background: red;
    height: 20px;
    width: 20px;
  }

  .label-width {
    width: 100%;
    text-align: center;
    font-size: 20px;
  }

  .show-excel {
    opacity: 0;
  }

  /deep/.base_header_layout .find.el-button--primary {
    width: 30px;
    border-top-left-radius: 0px;
    border-bottom-left-radius: 0px;
  }

  /deep/.base_header_layout .findinput input {
    border-top-right-radius: 0px;
    border-bottom-right-radius: 0px;
  }
</style>
