<template>
  <div class="content-box">
    <div class="left">
      <!-- <el-icon :size="23" class="camera"><VideoCameraFilled /></el-icon> -->
      <span class="cameratxt">流程管理</span>
    </div>
    <div class="changeItems">
      <div
        class="changeItem"
        :class="changeIndex == 1 ? 'changeItem_active' : ''"
        @click="changeItem(1)"
      >
        申请记录
      </div>
      <div
        class="changeItem"
        v-if="flagBtn.guizeshezhi == 1"
        :class="changeIndex == 2 ? 'changeItem_active' : ''"
        @click="changeItem(2)"
      >
        规则设置
      </div>
    </div>
    <div v-if="changeIndex == 2" class="regulation">
      <!-- <div class="condition">
        <span>可见范围&nbsp;&nbsp; </span>
        <el-select
          :clearable="false"
          v-model="regulation.scope"
          class="m-2"
          placeholder="请选择可见范围"
          style="width: 280px"
        >
          <el-option label="全部" :value="0" />
          <el-option label="领导" :value="1" />
          <el-option label="教师" :value="2" />
        </el-select>
      </div> -->
      <div class="condition">
        <span>指定终点 &nbsp;&nbsp;</span>
        <el-select
          :clearable="false"
          v-model="regulation.destination"
          class="m-2"
          placeholder="请选择指定终点"
          style="width: 280px"
          @change="destinationChange"
        >
          <el-option label="最上级审批" :value="1" />
          <el-option label="依次审批" :value="2" />
        </el-select>
      </div>
      <div class="condition hint">
        注：审批流程顺序从下至上，如多个上级，只需一个上级同意即可
      </div>
    </div>
    <div class="middle" v-if="changeIndex == 1">
      <div class="search">
        <div class="filter">
          <div class="condition">
            <span>提交时间 : </span>
            <!-- <el-date-picker
              v-model="searchInput.submitTime"
              type="date"
              format="YYYY-MM-DD"
              value-format="YYYY-MM-DD"
              :prefix-icon="Calendar"
              placeholder="请选择日期"
              style="width: 150px"
            /> -->
            <el-date-picker
              v-model="searchInput.submitTime"
              type="datetimerange"
              unlink-panels
              range-separator="-"
              start-placeholder="起始时间"
              end-placeholder="结束时间"
              format="YYYY-MM-DD HH:mm:ss"
              value-format="YYYY-MM-DD  HH:mm:ss"
              :prefix-icon="Calendar"
              @change="searchBtn"
            />
          </div>
          <div class="condition">
            <span>审批时间 : </span>
            <!-- <el-date-picker
              v-model="searchInput.approvalTime"
              type="date"
              format="YYYY-MM-DD"
              value-format="YYYY-MM-DD"
              :prefix-icon="Calendar"
              placeholder="请选择日期"
              style="width: 150px"
            /> -->
            <el-date-picker
              v-model="searchInput.approvalTime"
              type="datetimerange"
              unlink-panels
              range-separator="-"
              start-placeholder="起始时间"
              end-placeholder="结束时间"
              format="YYYY-MM-DD HH:mm:ss"
              value-format="YYYY-MM-DD  HH:mm:ss"
              :prefix-icon="Calendar"
              @change="searchBtn"
            />
          </div>
          <div class="condition">
            <span>审批状态 : </span>
            <el-select
              :clearable="false"
              v-model="searchInput.status"
              class="m-2"
              placeholder="请选择审批状态"
              style="width: 150px"
              @change="searchBtn"
            >
              <el-option label="全部" :value="10" />
              <el-option label="已拒绝" :value="0" />
              <el-option label="待审批" :value="1" />
              <el-option label="处理中" :value="2" />
              <el-option label="已同意" :value="3" />
            </el-select>
          </div>
          <div class="condition">
            <span>审批流程类型 : </span>
            <el-select
              :clearable="false"
              v-model="searchInput.flowType"
              class="m-2"
              placeholder="请选择审批流程类型"
              style="width: 150px"
              @change="flowTypeSearchBtn"
            >
              <!-- <el-option label="换课流程" :value="1" /> -->
              <el-option label="临时人员流程" :value="2" />
            </el-select>
          </div>
          <div class="condition">
            <span>部门 : </span>
            <el-select
              :clearable="true"
              v-model="searchInput.orgId"
              class="m-2"
              placeholder="请选择部门"
              multiple
              collapse-tags
              collapse-tags-tooltip
              style="width: 400px"
              @change="searchBtn"
            >
              <el-option
                v-for="i in organizations"
                :label="i.name"
                :value="i.id"
              />
            </el-select>
          </div>
        </div>
        <div class="inputSearch">
          <el-input
            :clearable="true"
            @clear="searchBtn"
            v-model.trim="searchInput.keyWord"
            class="w-50 m-2"
            placeholder="请输入关键字查询"
            style="width: 230px"
          />
          <el-button
            style="margin-left: 20px"
            color="rgba(41, 109, 227, 1)"
            type="primary"
            class="search"
            @click="searchBtn"
            ><el-icon>
              <Search />
            </el-icon>
            <span>查询</span></el-button
          >
        </div>
      </div>

      <div class="scroll">
        <div class="footer" v-loading="loading">
          <el-table
            :row-class-name="tableRowClassName"
            :data="tableData.list"
            @selection-change="handleSelectionChange"
            style="width: 100%"
            :header-cell-style="{
              background: 'rgba(240, 243, 247, 1)',
              height: '50px',
              border: 0,
            }"
          >
            <!-- <el-table-column
              align="center"
              prop="orderNum"
              width="180"
              label="审批编号"
            >
              <template #default="{ row }">
                <div class="orderNum">
                  {{ row.id }}
                </div>
              </template>
            </el-table-column> -->
            <el-table-column
              align="center"
              prop="submissionTime"
              label="提交时间"
              width="180"
            />
            <el-table-column align="center" prop="houseCount" width="150" label="申请房间数量" />
            <el-table-column align="center" prop="usersName" label="提交人" />
            <el-table-column align="center" prop="orgName" width="120" label="部门" />
            <el-table-column
              align="center"
              prop="reasonApplication"
              label="申请原因"
              show-overflow-tooltip
              width="200"
            />
            <el-table-column
              align="center"
              prop="examineAndApproveTime"
              label="审批时间"
              width="180"
            />
            <el-table-column
              align="center"
              prop="examineAndApproveRemark"
              label="审批备注"
              show-overflow-tooltip
              width="200"
            />

            <el-table-column
              align="center"
              prop="secondaryExamineAndApproveTime"
              label="次级审批时间"
              width="180"
            />
            <el-table-column
              align="center"
              prop="secondaryExamineAndApproveRemark"
              label="次级审批备注"
              show-overflow-tooltip
              width="150"
            />
            <el-table-column
              align="center"
              prop="payTime"
              label="时间"
              width="200"
            >
              <template #default="{ row }">
                {{ row.startTime }} - {{ row.endTime }}
              </template>
            </el-table-column>
            <el-table-column
              align="center"
              prop="approverName"
              label="审批人"
            />
            <el-table-column align="center" width="100" label="状态"
              ><template #default="{ row }">
                <span v-if="row.status == 0" style="color: red">已拒绝</span>
                <span v-if="row.status == 1">待审批</span>
                <span v-if="row.status == 2">处理中</span>
                <span v-if="row.status == 3" style="color: green">已同意</span>
              </template>
            </el-table-column>
            <el-table-column
              align="center"
              fixed="right"
              label="操作"
              width="150"
            >
              <template #default="{ row }">
                <div class="options">
                  <!-- T0级  最上级审批 -->
                  <div
                    class="options"
                    v-if="adminMenuParentId == 0 && destinatio == 1"
                  >
                    <div
                      class="agree"
                      v-if="
                        (row.status == 1 || row.status == 2) &&
                        flagBtn.tongyi == 1
                      "
                      @click="agreeRemarksClick(row)"
                    >
                      同意
                    </div>
                    <div
                      class="reject"
                      v-if="
                        (row.status == 1 || row.status == 2) &&
                        flagBtn.bohui == 1
                      "
                      @click="rejectRemarksClick(row)"
                    >
                      驳回
                    </div>
                  </div>
                  <!-- T0级  依次审批 -->
                  <div
                    class="options"
                    v-if="adminMenuParentId == 0 && destinatio == 2"
                  >
                    <div
                      class="agree"
                      v-if="
                        (row.status == 1 || row.status == 2) &&
                        flagBtn.tongyi == 1
                      "
                      @click="agreeRemarksClick(row)"
                    >
                      同意
                    </div>
                    <div
                      class="reject"
                      v-if="
                        (row.status == 1 || row.status == 2) &&
                        flagBtn.bohui == 1
                      "
                      @click="rejectRemarksClick(row)"
                    >
                      驳回
                    </div>
                  </div>
                  <!-- T1级  最上级审批 -->
                  <div
                    class="options"
                    v-if="adminMenuParentId == 1 && destinatio == 1"
                  ></div>
                  <!-- T1级  依次审批 -->
                  <div
                    class="options"
                    v-if="adminMenuParentId == 1 && destinatio == 2"
                  >
                    <div
                      class="agree"
                      v-if="row.status == 1 && flagBtn.tongyi == 1"
                      @click="agreeRemarksClick(row)"
                    >
                      同意
                    </div>
                    <div
                      class="reject"
                      v-if="row.status == 1 && flagBtn.bohui == 1"
                      @click="rejectRemarksClick(row)"
                    >
                      驳回
                    </div>
                  </div>
                </div>
              </template>
            </el-table-column>
          </el-table>
        </div>
        <!-- 分页组件 -->
        <div class="pageSize">
          <span></span>
          <el-pagination
            background
            :current-page="currentPage"
            :page-size="pageSize"
            layout="total, prev, pager, next, jumper, slot"
            :total="total"
            @update:current-page="handleCurrentChange"
          />
        </div>
      </div>
      <el-dialog
        class="remarks"
        v-model="remarksVisible"
        :close-on-click-modal="false"
        :close-on-press-escape="false"
        :title="remarksTitle"
        align-center
        width="550"
        :before-close="cancelRemarks"
      >
        <el-form
          ref="remarksRuleFormRef"
          :model="remarksRuleForm"
          :rules="remarksRules"
          label-width="100px"
          class="demo-ruleForm"
          size="default"
          label-position="left"
          status-icon
          :inline="true"
        >
          <el-form-item label="审批备注 :" prop="remarks">
            <el-input
              v-model.trim="remarksRuleForm.remarks"
              :rows="8"
              show-word-limit
              maxlength="50"
              type="textarea"
              placeholder="请输入审批备注"
            />
          </el-form-item>
        </el-form>
        <div class="options">
          <el-button
            color="rgba(41, 109, 227, 1)"
            class="queding"
            type="primary"
            @click="submitRemarks(remarksRuleFormRef)"
          >
            确认
          </el-button>
          <el-button type="primary" plain @click="cancelRemarks"
            >取消</el-button
          >
        </div>
      </el-dialog>
    </div>
  </div>
</template>

<script setup>
import {
  ref,
  reactive,
  nextTick,
  watch,
  onBeforeMount,
  onUnmounted,
} from "vue";
import { useRouter } from "vue-router";
import { ElMessage, ElMessageBox } from "element-plus";
import { Calendar } from "@element-plus/icons-vue";
import vidiconsApi from "@/api/vidicons.js";
import { dayjs } from "element-plus";
import lodash from "lodash";
import axios from "axios";
import { useStore } from "vuex";
const store = useStore();
const api = ref("");
const router = useRouter();

const organizations=ref();// 部门数据

const flagBtn = ref(); // 按钮权限
const adminMenuParentId = ref(); // 判断是 T0级 还是 T1级
const destinatio = ref(); // 判断是什么规则审批 (1最上级审批) (2依次审批)
const changeIndex = ref(1); // 申请记录 规则设置 切换

const searchInput = reactive({
  keyWord: "", // 关键字
  submitTime: "", // 提交时间
  approvalTime: "", // 审批时间
  status: 10, // 审批状态
  flowType: 2, // 审批流程类型
  orgId: [], // 部门
}); // 搜索按钮数据

const nowDay = ref(dayjs().format("YYYY-MM-DD HH:mm:ss"));
// 表格数据
const loading = ref(false);
const tableData = reactive({
  list: [],
});
const departmentData = ref([
  { name: "学生", id: 1 },
  { name: "教职工", id: 4 },
  { name: "校友", id: 5 },
  { name: "访客应用身份", id: 6 },
  { name: "临时人员", id: 7 },
  { name: "其他", id: 0 },
]); // 部门数据
const currentPage = ref(1); // 当前页
const pageSize = ref(9);
const total = ref(); // 当前总数

// 审批弹窗
const remarksRuleFormRef = ref();
const remarksVisible = ref(false);
const remarksTitle = ref("同意审核");
const remarksRuleForm = reactive({
  remarks: "", // 审批备注
  id: "",
});
// 表单验证
const remarksRules = reactive({
  remarks: [{ required: true, message: "审批备注不能为空", trigger: "blur" }],
});

const regulation = reactive({
  scope: "", // 可见范围
  destination: "", // 指定终点
  id: "",
});

// 切换 申请记录 规则设置
const changeItem = (ind) => {
  changeIndex.value = ind;
  if (ind == 1) {
    getList();
  } else if (ind == 2) {
    ruleInfo();
  }
};
// 规则设置 （------------------------------------------------------）
const ruleInfo = async () => {
  let res = await axios({
    method: "get",
    url: api.value + "/application-procedure-setting/list",
    headers: {
      token: sessionStorage.getItem("token"),
      user_head: sessionStorage.getItem("user_head"),
    },
    params: {
      permissionSettingId: sessionStorage.getItem("permissionSettingId"),
    },
  });
  console.log(res, "规则设置");
  if (res.data.code == 200) {
    regulation.destination = Number(res.data.data.approverType);
    regulation.id = res.data.data.id;
  } else {
    ElMessage({
      type: "error",
      showClose: true,
      message: res.data.message,
      center: true,
    });
  }
};
// 改变规则
const destinationChange = async () => {
  let res = await axios({
    method: "post",
    url: api.value + "/application-procedure-setting/update",
    headers: {
      token: sessionStorage.getItem("token"),
      user_head: sessionStorage.getItem("user_head"),
    },
    data: {
      adminMenuId: sessionStorage.getItem("permissionSettingId"),
      id: regulation.id,
      approverType: regulation.destination,
    },
  });
  console.log(res, "规则设置");
  if (res.data.code == 200) {
    ElMessage({
      type: "success",
      showClose: true,
      message: res.data.message,
      center: true,
    });
  } else {
    ElMessage({
      type: "error",
      showClose: true,
      message: res.data.message,
      center: true,
    });
  }
};

// 查看员工列表
const getList = async () => {
  loading.value = true;
  let data = {
    page: currentPage.value, // 当前页
    size: pageSize.value, // 一页数据条数
    key: searchInput.keyWord,
    department: searchInput.department,
    adminMenuId: sessionStorage.getItem("permissionSettingId"),
    OrgIds:searchInput.orgId.join(',')
  };
  if (searchInput.submitTime) {
    data.submissionStartTime = searchInput.submitTime[0];
    data.submissionEndTime = searchInput.submitTime[1];
  }
  if (searchInput.approvalTime) {
    data.examineAndApproveStartTime = searchInput.approvalTime[0];
    data.examineAndApproveEndTime = searchInput.approvalTime[1];
  }
  if (searchInput.status == 10) {
    data.type = "";
  } else {
    data.type = searchInput.status;
  }
  let res = "";
  // 换课流程
  if (searchInput.flowType == 1) {
    res = await axios({
      method: "get",
      url: api.value + "/application-procedure/list",
      headers: {
        token: sessionStorage.getItem("token"),
        user_head: sessionStorage.getItem("user_head"),
      },
      params: data,
    });
  }
  // 临时人员流程
  else {
    res = await axios({
      method: "get",
      url: api.value + "/application-procedure-temporary/list",
      headers: {
        token: sessionStorage.getItem("token"),
        user_head: sessionStorage.getItem("user_head"),
      },
      params: data,
    });
  }
  console.log(res, "申请记录");
  if (res.data.code == 200) {
    tableData.list = res.data.data.list;
    total.value = res.data.data.totalCount;
    loading.value = false;
    // ElMessage({
    //   type: "success",
    //   showClose: true,
    //   message: res.data.message,
    //   center: true,
    // });
  } else {
    loading.value = false;
    ElMessage({
      type: "error",
      showClose: true,
      message: res.data.message,
      center: true,
    });
  }
};

// 搜索功能
const searchBtn = lodash.debounce(async () => {
  getList();
}, 300);
const flowTypeSearchBtn = lodash.debounce(async () => {
  currentPage.value = 1;
  getList();
}, 300);

// 同意审核
const agreeRemarksClick = (row) => {
  console.log(row);
  remarksVisible.value = true;
  remarksTitle.value = "同意审核";
  remarksRuleForm.id = row.id;
};
// 驳回审核
const rejectRemarksClick = (row) => {
  console.log(row);
  remarksVisible.value = true;
  remarksTitle.value = "驳回审核";
  remarksRuleForm.id = row.id;
};
const submitRemarks = lodash.debounce(async (formEl) => {
  if (!formEl) return;
  await formEl.validate(async (valid, fields) => {
    if (valid) {
      let data = {
        id: remarksRuleForm.id, //审批表id
        adminMenuId: sessionStorage.getItem("permissionSettingId"), //权限表id,也是登入时传的permissionSettingId
        // status: 1, //审批状态   1：同意 0：拒绝
        adminId: sessionStorage.getItem("id"), //当前登入人id
        remark: remarksRuleForm.remarks, //审批备注
      };
      if (remarksTitle.value == "同意审核") {
        data.status = 1;
      } else {
        data.status = 0;
      }
      let res = "";
      // 换课流程
      console.log(data, "同意审核参数");
      if (searchInput.flowType == 1) {
        res = await axios({
          method: "post",
          url: api.value + "/application-procedure/update",
          headers: {
            token: sessionStorage.getItem("token"),
            user_head: sessionStorage.getItem("user_head"),
          },
          data: data,
        });
      }
      // 临时人员流程
      else {
        res = await axios({
          method: "post",
          url: api.value + "/application-procedure-temporary/update",
          headers: {
            token: sessionStorage.getItem("token"),
            user_head: sessionStorage.getItem("user_head"),
          },
          data: data,
        });
      }
      console.log(res, "审核");
      if (res.data.code == 200) {
        getList();
        ElMessage({
          type: "success",
          showClose: true,
          message: res.data.message,
          center: true,
        });
        remarksVisible.value = false;
        remarksRuleFormRef.value.resetFields();
      } else {
        ElMessage({
          type: "error",
          showClose: true,
          message: res.data.message,
          center: true,
        });
      }
    } else {
      console.log("error submit!", fields);
    }
  });
}, 1000);
const cancelRemarks = () => {
  remarksRuleFormRef.value.resetFields();
  remarksVisible.value = false;
};

// 表格斑马纹颜色修改
const tableRowClassName = ({ row, rowIndex }) => {
  if (rowIndex % 2 === 0) {
    return "even";
  } else if (rowIndex % 2 !== 0) {
    return "odd";
  }
  return "";
};
// 分页
const handleCurrentChange = (value) => {
  // console.log(value);
  currentPage.value = value;
  getList();
};

onBeforeMount(async () => {
  api.value = store.state.user.api;
  organizations.value = JSON.parse(sessionStorage.getItem("organizations"));
  organizations.value.forEach(i=>{
    searchInput.orgId.push(i.id)
  })
  const btnflag = JSON.parse(sessionStorage.getItem("btnflag"));
  adminMenuParentId.value = JSON.parse(
    sessionStorage.getItem("adminMenuParentId")
  );
  flagBtn.value = btnflag.process;
  console.log(flagBtn.value, "按钮权限");
  getList();
  // 判断是什么规则审批
  let res = await axios({
    method: "get",
    url: api.value + "/application-procedure-setting/list",
    headers: {
      token: sessionStorage.getItem("token"),
      user_head: sessionStorage.getItem("user_head"),
    },
    params: {
      permissionSettingId: sessionStorage.getItem("permissionSettingId"),
    },
  });
  console.log(res, "规则设置");
  if (res.data.code == 200) {
    destinatio.value = Number(res.data.data.approverType);
  } else {
    ElMessage({
      type: "error",
      showClose: true,
      message: res.data.message,
      center: true,
    });
  }
  console.log(adminMenuParentId.value, "管理员等级 0 T0级 1 T1级");
  console.log(destinatio.value, "规则 1最上级 2依次审批");

  // changeItem(changeIndex.value);
});
onUnmounted(() => {
  // document.removeEventListener("keyup", Enters);
});
</script>

<style scoped lang="scss">
.content-box {
  width: calc(100% - 40px);
  height: calc(100% - 105px);
  margin: 20px auto;
  background-color: #fff;
  color: #fff;
  display: flex;
  flex-direction: column;
  box-shadow: 0px 3px 10px rgba(0, 97, 255, 0.2);

  .left {
    // width: calc(100wh - 40px);
    display: flex;
    align-items: center;
    height: 60px;
    margin: 0 30px;
    border-bottom: 1px solid #ccc;
    color: rgb(0, 0, 0);
    font-size: 18px;
    font-weight: 600;

    span {
      display: inline-block;
      height: 60px;
      line-height: 60px;
      margin-right: 20px;
      cursor: pointer;
    }

    .is_active {
      color: rgba(111, 182, 184, 1);
    }
  }

  .top {
    width: 96%;
    height: 150px;
    margin: 20px auto;

    ul {
      padding: 0;
      margin: 0;
      height: 100%;
      list-style: none;
      display: flex;

      li {
        background-color: rgba(242, 242, 242, 1);
        border-radius: 10px;
        flex: 1;
        height: 100%;
        display: flex;
        flex-direction: column;
        justify-content: center;
        align-items: center;

        p {
          font-size: 40px;
          font-weight: 700;
          color: #000;
          margin: 0;
        }

        span {
          color: #000;
          font-size: 18px;
          font-weight: 400;
        }
      }

      li:not(:last-child) {
        margin-right: 36px;
      }
    }
  }
  //   切换 申请记录 规则设置
  .changeItems {
    width: calc(100% - 60px);
    display: flex;
    margin: 15px auto 0;
    .changeItem {
      width: 80px;
      height: 30px;
      background-color: rgba(230, 230, 230, 1);
      text-align: center;
      line-height: 30px;
      font-size: 14px;
      margin-right: 15px;
      border-radius: 3px;
      color: rgba(166, 166, 166, 1);
      cursor: pointer;
    }
    .changeItem_active {
      background-color: rgba(222, 234, 252, 1);
      color: rgba(0, 97, 255, 1);
    }
  }
  .middle {
    width: calc(100% - 60px);
    height: calc(100% - 106px);
    margin: 0 auto;
    color: #000;
    display: flex;
    flex-direction: column;
    overflow: auto;

    .filter {
      display: flex;
      flex-wrap: wrap;
      align-items: center;
      margin: 10px 0 0 0;

      .search {
        color: #fff;
      }

      .condition {
        display: flex;
        align-items: center;
        margin: 10px 20px 10px 0;
        font-size: 14px;

        :deep(.el-input .el-input__inner) {
          font-size: 14px;
        }

        span {
          margin: 0 10px 0 0;
        }
      }
    }
    .footer {
      width: 100%;
      height: calc(100% - 60px);
      // height: calc(100% - 60px);
      // margin: 10px auto 30px;
      .el-table--fit {
        height: 100%;

        :deep(.el-table__header-wrapper) {
          background-color: #000;
          font-size: 15px;

          tr {
            color: #000;
          }
        }

        :deep(.el-table__row) {
          height: 50px;
          font-size: 15px;
          color: #000;

          .orderNum {
            color: rgba(111, 182, 184, 1);
            cursor: pointer;
          }
        }

        :deep(.el-table__row):nth-child(2n) {
          .el-table-fixed-column--right {
            background-color: rgba(240, 243, 247, 1);
          }
        }

        :deep(.el-table__row td) {
          padding: 0;
          border: 0;
        }

        .el-button--primary {
          margin-left: 5px;
        }

        :deep(.el-table__body .even) {
          background-color: #fff;
        }

        :deep(.el-table__body .odd) {
          background-color: rgba(240, 243, 247, 1);
        }

        .options {
          display: flex;
          align-items: center;
          justify-content: center;
          :deep(.agree) {
            color: rgba(0, 97, 255, 1);
            cursor: pointer;
            padding: 0 5px;
            z-index: 999;
          }

          :deep(.reject) {
            color: red;
            cursor: pointer;
            padding: 0 5px;
          }
        }
      }
    }
    .scroll {
      flex: 1;
      overflow: auto;
    }
  }
  .inputSearch {
    margin-bottom: 15px;
  }
  //   规则设置页面样式
  .regulation {
    .condition {
      color: #000;
      margin: 20px 30px;
      font-size: 14px;
    }
    .hint {
      color: rgba(212, 48, 48, 1);
    }
  }

  .pageSize {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 60px;

    span {
      color: #000;
    }

    .el-pagination {
      // width: 1600px;
      :deep(.el-pagination__total) {
        color: #000;
      }

      :deep(.el-pagination__goto) {
        color: #000;
      }

      :deep(.el-pagination__classifier) {
        color: #000;
      }

      :deep(.el-input__wrapper) {
        border: 1px solid rgba(0, 0, 0, 1);
        border-radius: 5px;
        box-shadow: none;
      }

      :deep(.el-pager li) {
        margin: 0 5px;
        border: 1px solid rgba(0, 0, 0, 1);
        border-radius: 5px;
        background-color: transparent;
      }

      :deep(.el-pager li.is-active) {
        // background-color: rgba(111, 182, 184, 1);
        border: 1px solid rgba(0, 97, 255, 1);
        color: rgba(0, 97, 255, 1);
      }

      :deep(.btn-prev) {
        margin-right: 5px;
        border: 1px solid rgba(0, 0, 0, 1);
        border-radius: 5px;
        background-color: transparent;
      }

      :deep(.btn-next) {
        margin-left: 5px;
        border: 1px solid rgba(0, 0, 0, 1);
        border-radius: 5px;
        background-color: transparent;
      }
    }
  }
  // 添加房型弹窗样式
  :deep(.remarks) {
    height: 330px;
    border-radius: 11px;

    .el-dialog__header {
      border-radius: 11px 11px 0 0;
      background: rgba(237, 241, 245, 1);
      font-weight: 600;
      margin: 0;

      .el-dialog__headerbtn {
        outline: none;
      }
    }

    .el-dialog__body {
      padding: 10px 30px 10px 35px;
      .demo-ruleForm {
        width: 100%;
        .el-form-item {
          display: flex;
          margin: 10px 0 20px 0;
        }
      }
      .options {
        width: calc(100%);
        display: flex;
        justify-content: flex-end;
      }
    }
  }
}

.el-input {
  width: 192px;
}

.firstLogin {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: calc(100vh);
  background-color: rgba(0, 0, 0, 0.2);
  z-index: 1000000;
  display: flex;
  justify-content: center;
  align-items: center;

  .goInfo {
    width: 655px;
    height: 408px;
    background-color: #fff;
    border-radius: 9px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    color: #000;

    h2 {
      margin: 0;
      font-size: 28px;
    }

    p {
      margin: 60px 0;
      padding: 0;
      font-size: 18px;
    }
  }
}
</style>
