<!--
 * @Descripttion:
 * @version:
 * @Author: kBank
 * @Date: 2022-11-08 10:29:48
-->
<!--
 * @Descripttion:
 * @version:
 * @Author: kBank
 * @Date: 2022-11-08 10:26:10
-->
<template>
  <div class="page">
    <div class="main">
      <div class="form_all">
        <el-form ref="select" :model="select" label-width="auto">
          <el-row :gutter="10">
            <!-- 一层 -->
            <el-col :span="4">
              <el-form-item :label="'商品名称'">
                <el-input
                  clearable
                  v-model="select.waresName"
                  :placeholder="'请输入'"
                ></el-input>
              </el-form-item>
            </el-col>
            <el-col :span="4">
              <el-form-item :label="'商品编码'">
                <el-input
                  clearable
                  v-model="select.waresCode"
                  :placeholder="'请输入'"
                ></el-input>
              </el-form-item>
            </el-col>
            <el-col :span="4">
              <el-form-item :label="$t('系统类型')">
                <el-select clearable v-model="select.systemType">
                  <el-option
                    v-for="item in systemTypes"
                    :key="item.value"
                    :label="item.label"
                    :value="item.value"
                  ></el-option>
                </el-select>
              </el-form-item>
            </el-col>
            <el-col :span="4">
              <el-form-item :label="'上架状态'">
                <el-select clearable v-model="select.isPutOn">
                  <el-option
                    v-for="item in agreeList"
                    :key="item.val"
                    :label="item.text"
                    :value="item.val"
                  ></el-option>
                </el-select>
              </el-form-item>
            </el-col>
            <el-col :span="4">
              <el-form-item :label="'预售状态'">
                <el-select clearable v-model="select.preSaleStatus">
                  <el-option
                    v-for="item in presaleList"
                    :key="item.value"
                    :label="item.label"
                    :value="item.value"
                  ></el-option>
                </el-select>
              </el-form-item>
            </el-col>
            <el-col :span="4">
              <el-form-item :label="'供应方式'">
                <el-select clearable v-model="select.operateScope">
                  <el-option
                    v-for="item in gyList"
                    :key="item.value"
                    :label="item.label"
                    :value="item.value"
                  ></el-option>
                </el-select>
              </el-form-item>
            </el-col>
            <!-- 二层 -->
            <el-col :span="4">
              <el-form-item :label="'商品分类'">
                <el-cascader
                  clearable
                  @change="flChange"
                  :key="refreshItem"
                  :show-all-levels="false"
                  v-model="pkAreaClassifys"
                  :options="hierarchyList"
                ></el-cascader>
              </el-form-item>
            </el-col>
            <el-col :span="4">
              <el-form-item :label="'所属专区'">
                <el-select clearable v-model="select.specialArea">
                  <el-option
                    v-for="item in areaList"
                    :key="item.value"
                    :label="item.label"
                    :value="item.value"
                  ></el-option>
                </el-select>
              </el-form-item>
            </el-col>
            <el-col :span="4">
              <el-form-item :label="'销售状态'">
                <el-select clearable v-model="select.isSale">
                  <el-option
                    v-for="item in xsList"
                    :key="item.val"
                    :label="item.text"
                    :value="item.val"
                  ></el-option>
                </el-select>
              </el-form-item>
            </el-col>
            <el-col :span="4">
              <el-form-item :label="'套餐类型'">
                <el-select clearable v-model="select.isSingle">
                  <el-option
                    v-for="item in tcList"
                    :key="item.val"
                    :label="item.text"
                    :value="item.val"
                  ></el-option>
                </el-select>
              </el-form-item>
            </el-col>
            <el-col :span="4">
              <el-form-item :label="'包邮类型'">
                <el-select clearable v-model="select.isFreeMail">
                  <el-option
                    v-for="item in postList"
                    :key="item.val"
                    :label="item.text"
                    :value="item.val"
                  ></el-option>
                </el-select>
              </el-form-item>
            </el-col>
            <el-col :span="4">
              <el-form-item :label="'是否推荐'">
                <el-select clearable v-model="select.isRecommend">
                  <el-option
                    v-for="item in isTj"
                    :key="item.value"
                    :label="item.label"
                    :value="item.value"
                  ></el-option>
                </el-select>
              </el-form-item>
            </el-col>
          </el-row>
          <!-- <el-col :span="4">
            <el-form-item label="商品价格">
              <el-input clearable  v-model="select.waresPrice"
                        :placeholder="'请输入'"></el-input>
            </el-form-item>
          </el-col> -->
          <!-- 三层 -->
          <el-collapse-transition>
            <div v-show="isActive">
              <!-- <el-col :span="4">
                <el-form-item label="商品业绩">
                  <el-input clearable  v-model="select.waresAchieve"
                            :placeholder="'请输入'"></el-input>
                </el-form-item>
              </el-col>
              <el-col :span="4">
                <el-form-item :label="'虚拟销量'">
                  <el-input clearable  v-model="select.sales"
                            :placeholder="'请输入'"></el-input>
                </el-form-item>
              </el-col>
              <el-col :span="4">
                <el-form-item :label="'实际销量'">
                  <el-input clearable  v-model="select.name"></el-input>
                </el-form-item>
              </el-col> -->
              <el-row :gutter="10">
                <el-col :span="8">
                  <el-form-item :label="'创建日期'">
                    <el-date-picker
                      v-model="creationTime1"
                      @change="changeTime1"
                      value-format="yyyy-MM-dd HH:mm:ss"
                      type="datetimerange"
                      :range-separator="'至'"
                      :start-placeholder="'开始日期'"
                      :end-placeholder="'结束日期'"
                    >
                    </el-date-picker>
                  </el-form-item>
                </el-col>
                <el-col :span="8">
                  <el-form-item label="上架时间">
                    <el-date-picker
                      v-model="creationTime2"
                      @change="changeTime2"
                      value-format="yyyy-MM-dd HH:mm:ss"
                      type="datetimerange"
                      :range-separator="'至'"
                      :start-placeholder="'开始日期'"
                      :end-placeholder="'结束日期'"
                    >
                    </el-date-picker>
                  </el-form-item>
                </el-col>
                <el-col :span="8">
                  <el-form-item label="下架时间">
                    <el-date-picker
                      v-model="creationTime3"
                      @change="changeTime3"
                      value-format="yyyy-MM-dd HH:mm:ss"
                      type="datetimerange"
                      :range-separator="'至'"
                      :start-placeholder="'开始日期'"
                      :end-placeholder="'结束日期'"
                    >
                    </el-date-picker>
                  </el-form-item>
                </el-col>
              </el-row>
            </div>
          </el-collapse-transition>
          <el-col :span="4" style="">
            <el-button type="primary" @click="getDataList">
              {{ '搜索' }}
            </el-button>
            <el-button type="" class="resetBtn" @click="reset">
              {{ '重置' }}
            </el-button>
          </el-col>
          <!-- </el-row> -->
        </el-form>
        <div class="openClose" @click="changeActive">
          <i :class="isActive ? 'el-icon-arrow-up' : 'el-icon-arrow-down'"></i>
          <div>{{ isActive ? '点击收起' : '点击展开' }}</div>
        </div>
      </div>
      <div class="maintop">
        <div class="mainbtn">
          <el-button
            size="small"
            v-hasButtons="['GoodsListAdd']"
            @click="openDig"
            class="addBtn"
            >{{ '添加' }}
          </el-button>
          <el-button
            size="small"
            @click="handleExport"
            v-hasButtons="['GoodsListExport']"
            class="exportBtn"
          >
            {{ '导出' }}
          </el-button>
          <el-button
            size="small"
            :disabled="isCopy"
            @click="toCopy"
            v-hasButtons="['GoodsListCopy']"
            class="copyBtn"
            >{{ '复制' }}
          </el-button>
        </div>
      </div>
      <div class="maintable">
        <el-table
          :data="tableData"
          v-loading="loading"
          style="width: 100%"
          height="100%"
          :header-cell-style="{ background: '#EEEEEE' }"
          :row-class-name="tableRowClassName"
          @selection-change="handleSelectionChange"
        >
          <el-table-column type="selection" width="55"></el-table-column>
          <!-- <el-table-column
            align="center"
            prop="sort"
            sortable
            width="100"
            :label="'排序'"
          >
          </el-table-column> -->
          <el-table-column align="center" prop="cover" :label="'商品主图'">
            <template slot-scope="scope">
              <img class="bgImg" :src="scope.row.cover" alt="" />
            </template>
          </el-table-column>
          <el-table-column
            align="center"
            width="200"
            prop="waresName"
            :label="'商品名称'"
          >
          </el-table-column>
          <el-table-column
            align="center"
            prop="waresCode"
            width="200"
            :label="'商品编码'"
          >
          </el-table-column>
          <el-table-column
            align="center"
            prop="waresPrice"
            :label="'商品价格'"
          >
          </el-table-column>
          <el-table-column
            align="center"
            prop="waresAchieve"
            :label="'商品业绩'"
          >
          </el-table-column>
          <el-table-column align="center" prop="tempName" label="支付比例">
          </el-table-column>
          <el-table-column
            align="center"
            prop="makerIncome"
            label="发起人收益(￥)"
            width="120"
          >
          </el-table-column>
          <el-table-column
            align="center"
            prop="authorityTypeVal"
            label="可见类型"
          >
          </el-table-column>
          <el-table-column
            align="center"
            prop="memberCode"
            label="团队编号"
            width="120"
          >
          </el-table-column>
          <el-table-column
            align="center"
            prop="memberName"
            label="团队姓名"
            width="120"
          >
          </el-table-column>
          <el-table-column
            align="center"
            prop="productName"
            label=""
            width="600"
          >
            <template slot="header" slot-scope="scope">
              <div class="goodTit">
                <div class="line1">产品名称</div>
                <div class="line2">产品编号</div>
                <div class="line3">产品数量</div>
              </div>
            </template>
            <template slot-scope="scope">
              <div class="goodLine">
                <div
                  class="goodLine_c"
                  v-for="(item, index) in scope.row.waresDetailList"
                  :key="index"
                >
                  <div class="line1">
                    {{ item.productName }}
                  </div>
                  <div class="line2">
                    {{ item.productCode }}
                  </div>
                  <div class="line3">
                    {{ item.productQuantity }}
                  </div>
                </div>
              </div>
            </template>
          </el-table-column>
          <!-- <el-table-column align="center" prop="productCode" label="产品编号"  width="180">
            <template slot-scope="scope">
              <div class="goodLine"
                v-for="(item, index) in scope.row.waresDetailList"
                :key="index"
              >
                {{ item.productCode }}
              </div>
            </template>
          </el-table-column>
          <el-table-column align="center" prop="productQuantity" width="120" label="产品数量">
            <template slot-scope="scope">
              <div class="goodLine"
                v-for="(item, index) in scope.row.waresDetailList"
                :key="index"
              >
                {{ item.productQuantity }}
              </div>
            </template>
          </el-table-column> -->

          <el-table-column
            align="center"
            prop="specialArea"
            :label="'所属专区'"
          >
            <template slot-scope="scope">
              <div
                v-for="item in areaList"
                :key="item.value"
                v-if="scope.row.specialArea == item.value"
              >
                {{ item.label }}
              </div>
            </template>
          </el-table-column>
          <el-table-column
            align="center"
            prop="isSingle"
            :label="'套餐类型'"
          >
            <template slot-scope="scope">
              <div
                v-for="item in tcList"
                :key="item.val"
                v-if="scope.row.isSingle == item.val"
              >
                {{ item.text }}
              </div>
            </template>
          </el-table-column>
          <el-table-column
            align="center"
            prop="isFreeMail"
            :label="'包邮类型'"
          >
            <template slot-scope="scope">
              <div
                v-for="item in postList"
                :key="item.val"
                v-if="scope.row.isFreeMail == item.val"
              >
                {{ item.text }}
              </div>
            </template>
          </el-table-column>
          <el-table-column
            align="center"
            prop="classifyName"
            width="120"
            :label="'商品分类'"
          >
          </el-table-column>
          <el-table-column
            align="center"
            prop="isMakerGiftVal"
            width="120"
            label="商品类型"
          >
          </el-table-column>
          <el-table-column
            align="center"
            prop="isRecommendVal"
            :label="'是否推荐'"
          >
          </el-table-column>
          <el-table-column
            align="center"
            prop="operateScope"
            :label="'供应方式'"
          >
            <template slot-scope="scope">
              <div
                v-for="item in gyList"
                :key="item.value"
                v-if="scope.row.operateScope == item.value"
              >
                {{ item.label }}
              </div>
            </template>
          </el-table-column>
          <el-table-column
            align="center"
            prop="isSale"
            :label="'销售状态'"
          >
            <template slot-scope="scope">
              <div
                v-for="item in xsList"
                :key="item.val"
                v-if="scope.row.isSale == item.val"
              >
                {{ item.text }}
              </div>
            </template>
          </el-table-column>
          <el-table-column
            align="center"
            prop="isPutOn"
            :label="'上架状态'"
          >
            <template slot-scope="scope">
              <div
                v-for="item in agreeList"
                :key="item.val"
                v-if="scope.row.isPutOn == item.val"
              >
                {{ item.text }}
              </div>
            </template>
          </el-table-column>
          <el-table-column
            align="center"
            prop="preSaleStatus"
            :label="'预售状态'"
          >
            <template slot-scope="scope">
              <div
                v-for="item in presaleList"
                :key="item.value"
                v-if="scope.row.preSaleStatus == item.value"
              >
                {{ item.label }}
              </div>
            </template>
          </el-table-column>
          <el-table-column
            align="center"
            prop="sales"
            :label="'虚拟销量'"
          >
          </el-table-column>
          <el-table-column
            align="center"
            prop="actualSales"
            :label="'实际销量'"
          >
          </el-table-column>
          <el-table-column
            align="center"
            prop="systemType"
            :label="$t('系统类型')"
          >
            <template slot-scope="scope">
              <div
                v-for="item in systemTypes"
                :key="item.value"
                v-if="scope.row.systemType == item.value"
              >
                {{ item.label }}
              </div>
            </template>
          </el-table-column>
          <el-table-column
            align="center"
            width="120"
            prop="waresStatusVal"
            :label="$t('审核状态')"
          >
            <template slot-scope="scope">
              <el-tag
                type="success"
                effect="plain"
                v-if="scope.row.waresStatus == 5"
              >
                {{ scope.row.waresStatusVal }}</el-tag
              >
              <el-tag type="danger" effect="plain" v-else>
                {{ scope.row.waresStatusVal }}</el-tag
              >
            </template>
          </el-table-column>
          <el-table-column
            align="center"
            width="170"
            prop="arrivalTime"
            :label="'预计发货时间'"
          >
          </el-table-column>
          <el-table-column
            align="center"
            width="170"
            prop="putOnTime"
            label="预计上架时间"
          >
          </el-table-column>
          <el-table-column
            align="center"
            width="170"
            prop="putOffTime"
            label="预计下架时间"
          >
          </el-table-column>
          <el-table-column
            align="center"
            width="170"
            prop="creationTime"
            :label="'创建日期'"
          >
          </el-table-column>
          <el-table-column
            align="center"
            prop="listingTime"
            width="120"
            label="上架时间"
          >
          </el-table-column>
          <el-table-column
            align="center"
            prop="removalTime"
            width="120"
            label="下架时间"
          >
          </el-table-column>
          <el-table-column
            align="center"
            prop="time"
            width="120"
            :label="'操作'"
            fixed="right"
          >
            <template slot-scope="scope">
              <div class="btnHeng">
                <div
                  @click="toChecked(scope.row.pkWares, 1)"
                  type="text"
                  v-hasButtons="['GoodsListUpdate']"
                  style="color: #f3a900"
                  size="small"
                >
                  {{ '修改' }}
                </div>
                <div
                  @click="toChecked(scope.row.pkWares, 0)"
                  type="text"
                  style="color: #48b2fd"
                  size="small"
                >
                  {{ '查看' }}
                </div>
                <div
                  @click="handleDelete(scope.row.pkWares)"
                  type="text"
                  v-hasButtons="['GoodsListDelete']"
                  size="small"
                  style="color: #c8161d"
                >
                  {{ '删除' }}
                </div>
                <div
                  v-if="scope.row.waresStatus != 5"
                  @click="handleWares(scope.row.pkWares)"
                  type="text"
                  v-hasButtons="['GoodsListWares']"
                  size="small"
                  style="color: #c8161d"
                >
                  {{ $t("审核") }}
                </div>
              </div>
              <div class="btnHeng">
                <!-- <div
                  @click="upEdit(scope.row.pkWares, 0)"
                  type="text"
                  v-hasButtons="['GoodsListUp']"
                  size="small"
                  style="color: #c73030"
                >
                  {{ '上移' }}
                </div>
                <div
                  @click="upEdit(scope.row.pkWares, 1)"
                  type="text"
                  size="small"
                  v-hasButtons="['GoodsListDown']"
                  style="color: #c73030"
                >
                  {{ '下移' }}
                </div> -->
                <div
                  @click="topEdit(scope.row.pkWares)"
                  type="text"
                  size="small"
                  v-hasButtons="['GoodsListTop']"
                  style="color: #c73030"
                >
                  {{ '置顶' }}
                </div>
                <div
                  @click="topEdit1(scope.row.pkWares)"
                  type="text"
                  size="small"
                  v-hasButtons="['GoodsListBottom']"
                  style="color: #c73030"
                >
                  置底
                </div>
              </div>
            </template>
          </el-table-column>
        </el-table>
      </div>
    </div>
    <pagination
      v-show="total > 0"
      :total="total"
      :page.sync="queryParams.pageNum"
      :limit.sync="queryParams.pageSize"
      @pagination="getDataList"
    />
  </div>
</template>

<script>
import topBar from "@/components/topBar";
import * as api from "@/api/product.js";
import { accountSave, accountUpdate } from "@/api/configManage";
import { getToken } from "@/utils/auth";
import { specialArea } from "@/api/configManage";

export default {
  name: "ProductList",
  components: {
    topBar,
  },
  filters: {
    isAgree(val) {
      if (!val) {
        return '允许';
      } else {
        return '禁止';
      }
    },
  },
  data() {
    return {
      refreshItem: 0,
      // 折叠搜索框
      isActive: false,
      select: {},
      // 查询参数
      queryParams: {
        pageNum: 1,
        pageSize: 50,
      },
      addOrEdit: "",
      total: 0,
      // 套餐类型
      tcList: [
        {
          text: '套装',
          val: 0,
        },
        {
          text: '单品',
          val: 1,
        },
      ],
      postList: [
        {
          text: '包邮',
          val: 0,
        },
        {
          text: '不包邮',
          val: 1,
        },
      ],
      xsList: [
        {
          text: '允许出售',
          val: 0,
        },
        {
          text: '禁止出售',
          val: 1,
        },
      ],
      loading: false,
      tableData: [],
      agreeList: [
        {
          text: '允许',
          val: 0,
        },
        {
          text: '禁止',
          val: 1,
        },
      ],
      isTj: [
        {
          label: '推荐',
          value: 0,
        },
        {
          label: '不推荐',
          value: 1,
        },
      ],
      form: {},
      creationTime1: [],
      creationTime2: [],
      creationTime3: [],
      isCopy: true,
      selPkId: "",
      // 预售状态
      presaleList: [],
      //供应方式
      gyList: [],
      //商品分类
      hierarchyList: [],
      // 所属专区
      areaList: [],
      pkAreaClassifys: [],
    };
  },
  mounted() {
    // 获取专区
    this.getArea();
    // 获取列表
    this.getDataList();
    //  查询预售状态
    this.presale_status();
    //  查询预售状态
    this.supply_way();
    //查询分类父子级关系
    this.get_hierarchy_list();
  },
  methods: {
    reset() {
      this.select = {};
      this.creationTime1 = [];
      this.creationTime2 = [];
      this.creationTime3 = [];
      this.pkAreaClassifys = [];
      this.refreshItem++;
      this.getDataList();
    },
    // 商品分类赋值
    flChange(value) {
      console.log(
        "%c [ value ]-533",
        "font-size:13px; background:#5a4930; color:#9e8d74;",
        value
      );
      this.select.pkAreaClassify = value[value.length - 1];
    },
    // 获取专区
    getArea() {
      specialArea().then((res) => {
        this.areaList = res.data;
      });
    },
    // 查询分类父子级关系
    get_hierarchy_list() {
      api.get_hierarchy_list().then((res) => {
        this.hierarchyList = res.data;
      });
    },
    //  供应方式
    supply_way() {
      api.supply_way().then((res) => {
        this.gyList = res.data;
      });
    },
    //  查询预售状态
    presale_status() {
      api.presale_status().then((res) => {
        this.presaleList = res.data;
      });
    },
    changeTime1(val) {
      this.select.startCreateDate = val ? val[0] : "";
      this.select.endCreateDate = val ? val[1] : "";
    },
    changeTime2(val) {
      this.select.startPutOnTime = val ? val[0] : "";
      this.select.endPutOnTime = val ? val[1] : "";
    },
    changeTime3(val) {
      this.select.startPutOffTime = val ? val[0] : "";
      this.select.endPutOffTime = val ? val[1] : "";
    },
    // 展开折叠
    changeActive() {
      this.isActive = !this.isActive;
    },
    handleWares(id) {
      this.$confirm(this.$t("确认审核？"), '提示', {
        confirmButtonText: '确定',
        cancelButtonText: '取消',
        type: "warning",
      }).then(() => {
        api.productWaresApprove({ pkWares: id }).then((res) => {
          if (res.code == 200) {
            this.$message({
              message: res.msg,
              type: "success",
            });
            this.getDataList();
          }
        });
      });
    },
    // 删除
    handleDelete(id) {
      this.$confirm('确认删除?', '提示', {
        confirmButtonText: '确定',
        cancelButtonText: '取消',
        type: "warning",
      }).then(() => {
        api.waresDel(id).then((res) => {
          // 获取列表
          this.getDataList();
        });
      });
    },
    openDig() {
      this.$router.push({
        path: "/goodsManage/goodsRelease/jcsz",
      });
    },
    // // 点击修改
    // toFixed(id) {
    //   this.$router.push({
    //     path: '/goodsManage/goodsList/goodsEdit/jcsz',
    //     query: {
    //       id: id,
    //       methods: 1,
    //     },
    //   })
    // },
    // 查看 0，编辑1,复制2
    toChecked(id, index) {
      this.$router.push({
        path: "/goodsManage/goodsList/goodsEdit/jcsz",
        query: {
          id: id,
          methods: index,
        },
      });
    },
    upEdit(id, index) {
      api
        .waresMove({
          waresId: id,
          waresMoveType: index,
          specialArea: this.select.specialArea,
        })
        .then((res) => {
          this.getDataList();
        });
    },
    topEdit(id) {
      api
        .waresTop({
          waresId: id,
        })
        .then((res) => {
          this.getDataList();
        });
    },
    topEdit1(id) {
      api
        .waresBottom({
          waresId: id,
        })
        .then((res) => {
          this.getDataList();
        });
    },
    // 获取列表
    getDataList() {
      this.loading = true;
      api
        .waresList(Object.assign({}, this.queryParams, this.select))
        .then((res) => {
          this.loading = false;
          this.tableData = res.rows;
          this.total = res.total;
        });
    },
    toCopy() {
      this.toChecked(this.selPkId, 2);
    },
    /** 导出按钮操作 */
    handleExport() {
      this.$confirm('是否确认导出所有数据项?', '警告', {
        confirmButtonText: '确定',
        cancelButtonText: '取消',
        type: "warning",
      }).then((_) => {
        this.download(
          "sale/manage/wares/export",
          Object.assign({}, this.queryParams, this.select),
          `商品列表${new Date().getTime()}.xlsx`
        );
      });
    },
    handleSelectionChange(val) {
      if (val.length > 0) {
        this.selPkId = val[0].pkWares;
        this.isCopy = false;
      } else {
        this.isCopy = true;
      }
    },
    tableRowClassName({ row, rowIndex }) {
      if (rowIndex % 2 == 1) {
        return "warning-row";
      } else if (rowIndex % 2 == 0) {
        return "success-row";
      }
      return "";
    },
  },
};
</script>
<style scoped lang="scss">
::v-deep .el-table .warning-row {
  background: #f9f9f9;
}

::v-deep .el-table .success-row {
  background: #ffffff;
}

::v-deep .el-table thead {
  color: #000000;
}

::v-deep .el-select {
  width: 100%;
}

::v-deep .el-date-editor.el-input,
.el-date-editor.el-input__inner {
  width: 100%;
}

.uploadIcon ::v-deep .el-upload--picture-card {
  display: none !important; /* 上传按钮隐藏 */
}

.page {
  padding: 20px;
  background: #f9f9f9;
  font-size: 14px;

  .main {
    display: flex;
    flex-direction: column;
    border-radius: 8px;
    box-shadow: 0px 2px 20px 0px rgba(238, 238, 238, 0.5);

    .form_all {
      padding: 5px 10px;
      margin-bottom: 10px;
      background: #fff;
      border-radius: 8px;
    }

    .maintop {
      display: flex;
      padding: 0px 0 3px 0;
      justify-content: space-between;
      align-items: center;
      background: #fff;

      .mainbtn {
        .thebtn1 {
          background: #3181e5;
          color: #ffffff;
        }

        .thebtn2 {
          background: #ffad41;
          color: #ffffff;
        }

        .thebtn3 {
          background: #6962f6;
          color: #ffffff;
        }
      }

      .maintitle {
        font-size: 10px;
        font-family: MicrosoftYaHei;
        color: #999999;
      }
    }

    .maintable {
      flex: 1;
      overflow-y: auto;
    }
  }

  .tem {
    display: flex;
    align-items: center;
    justify-content: center;

    img {
      width: 28px;
      height: 20px;
      margin-right: 3px;
    }
  }

  .isRed {
    color: #ed1d25;
  }

  .isGreen {
    color: #1ab62b;
  }

  .bgImg {
    width: 48px;
    height: 48px;
  }
}

.openClose {
  margin-right: 10px;
  color: #666666;
  text-align: center;
}

.btnHeng {
  display: flex;
  justify-content: space-around;
  font-size: 12px;
  cursor: pointer;
}

.goodLine_c {
  display: flex;
  align-items: center;
  border-bottom: 1px solid #eee;

  justify-content: center;
  padding: 0 10px;

  .line1 {
    width: 50%;
  }

  .line2 {
    width: 30%;
  }

  .line3 {
    width: 20%;
  }
}

.goodTit {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 10px;

  .line1 {
    width: 50%;
  }

  .line2 {
    width: 30%;
  }

  .line3 {
    width: 20%;
  }
}

.goodLine {
  :last-child {
    border-bottom: none;
  }
}
</style>
