index.vue 23.8 KB
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734
<template>
  <div>
    <div class="g-left-right">
      <div class="left g-card">
        <div class="title">
          <div class="title-name">表单分组</div>
          <div class="title-btn" @click="addGroup">添加</div>
        </div>
        <div class="item-list">
          <div
            class="item"
            v-for="(group, key) in groupList"
            :class="{ active: groupIndex == key }"
            :key="group.id"
            @click="switchGroup(key, group)">
            <div class="name">{{ group.name }}</div>
            <el-dropdown
              v-if="groupIndex == key && group.flag === 0"
              class="dropdown"
              @command="onGroupCommand($event, group)">
              <div v-if="group">
                <span class="dot" v-if="group.name != '默认分组'">
                  <!-- <img :src="require('@/assets/drainageCode/more.png')" alt=""> -->
                  <i class="el-icon-more"></i>
                </span>
                <el-dropdown-menu slot="dropdown">
                  <el-dropdown-item command="edit">修改分组</el-dropdown-item>
                  <el-dropdown-item command="remove">删除分组</el-dropdown-item>
                </el-dropdown-menu>
              </div>
            </el-dropdown>
          </div>
        </div>
      </div>
      <div class="right">
        <el-form :inline="true" label-width="" label-position="left" class="top-search">
          <el-form-item label="表单ID">
            <el-input
              onkeyup="value=value.replace(/[^\d]/g,'')"
              v-model="query.id"
              placeholder="请输入表单ID"
              clearable
              @keyup.enter.native="search()" />
          </el-form-item>
          <el-form-item label="表单名称">
            <!-- readonly -->
            <el-input
              v-model="query.surveyName"
              clearable
              placeholder="请输入表单名称"
              @keyup.enter.native="search()" />
          </el-form-item>
          <el-form-item label="创建时间">
            <el-date-picker
              v-model="dateRange"
              value-format="yyyy-MM-dd"
              type="daterange"
              :picker-options="pickerOptions"
              range-separator="-"
              start-placeholder="开始日期"
              end-placeholder="结束日期"></el-date-picker>
            <!-- <el-date-picker
                  v-model="query.createTime"
                  type="daterange"
                  default-time="['00:00:00','00:00:00']"
                  value-format="yyyy-MM-dd HH:mm:ss"
                  placeholder="选择时间"></el-date-picker> -->
          </el-form-item>
          <el-form-item label="选择状态" prop="addState">
            <el-select v-model="query.surveyState">
              <el-option label="未发布" :value="0"></el-option>
              <el-option label="收集中" :value="1"></el-option>
              <el-option label="已暂停" :value="2"></el-option>
              <el-option label="已结束" :value="3"></el-option>
              <!-- <el-option label="待通过" :value="3">
              		</el-option> -->
            </el-select>
          </el-form-item>
          <el-form-item label-width="0">
            <el-button type="primary" @click="search()">查询</el-button>
            <el-button @click="resetQuery">重置</el-button>
          </el-form-item>
        </el-form>
        <div class="g-card">
          <div class="mid-action">
            <el-button type="primary" @click="goRoute('add')">新建表单</el-button>
            <div>
              <el-button type="primary" plain @click="removeFn('mult')">删除</el-button>
              <!-- <el-button type="primary" plain @click="downloadBatch()"
                  >批量下载</el-button
                > -->
            </div>
          </div>
          <el-table v-loading="loading" :data="list" @selection-change="handleSelectionChange" style="width: 100%">
            <el-table-column type="selection" width="50" align="center" />
            <el-table-column label="表单ID&名称" min-width="170" align="center" prop="id" show-overflow-tooltip>
              <template slot-scope="{ row }">
                <div>ID:{{ row.id }}</div>
                <div>名称:{{ row.surveyName }}</div>
              </template>
            </el-table-column>
            <el-table-column label="表单分组" align="center" min-width="100" prop="groupName" show-overflow-tooltip>
              <template slot-scope="{ row }">
                <div style="overflow: hidden; text-overflow: ellipsis; white-space: nowrap">
                  {{ row.groupName }}
                </div>
              </template>
            </el-table-column>
            <el-table-column label="创建人&时间" align="center" min-width="130" prop="createTime" show-overflow-tooltip>
              <template slot-scope="{ row }">
                <div>{{ row.createBy }}</div>
                <div>{{ row.createTime }}</div>
              </template>
            </el-table-column>
            <el-table-column
              label="收集开始&结束时间"
              align="center"
              min-width="200"
              prop="qrUserInfos"
              show-overflow-tooltip>
              <template slot-scope="{ row }">
                <div>
                  开始时间:{{ row.timingStart }}
                  <span v-if="!row.timingStart">永久</span>
                </div>
                <div>
                  结束时间:{{ row.timingEnd }}
                  <span v-if="!row.timingEnd">永久</span>
                </div>
              </template>
            </el-table-column>

            <el-table-column label="表单状态" align="center" min-width="100" prop="qrGroupName" show-overflow-tooltip>
              <template slot-scope="{ row }">
                <div v-if="row.surveyState == 0">未发布</div>
                <div v-if="row.surveyState == 1">收集中</div>
                <div v-if="row.surveyState == 2">已暂停</div>
                <div v-if="row.surveyState == 3">已结束</div>
              </template>
            </el-table-column>
            <el-table-column
              label="总访问量/有效收集量"
              align="center"
              min-width="180"
              prop="qrGroupName"
              show-overflow-tooltip>
              <template slot="header" slot-scope="scope">
                <div style="display: flex; align-items: center">
                  <div>总访问量/有效收集量</div>
                  <div style="margin-left: 10px">
                    <el-popover width="250" trigger="hover">
                      <p>总访问量:PV;</p>
                      <p>有效收集量:成功提交表单的UV</p>
                      <i slot="reference" class="el-icon-question"></i>
                    </el-popover>
                  </div>
                </div>
              </template>
              <template slot-scope="{ row }">
                <div>{{ row.totalVisits }}/{{ row.collectionVolume }}</div>
              </template>
            </el-table-column>

            <el-table-column
              label="最近操作人&时间"
              align="center"
              min-width="130"
              prop="qrGroupName"
              show-overflow-tooltip>
              <template slot-scope="{ row }">
                <div>{{ row.updateBy }}</div>
                <div>{{ row.updateTime }}</div>
              </template>
            </el-table-column>

            <el-table-column
              label="操作"
              align="center"
              fixed="right"
              width="260"
              class-name="small-padding fixed-width">
              <template slot-scope="{ row }">
                <!-- <el-button type="text" @click="goRoute('staffDetail', row.id)">详情|统计</el-button> -->
                <el-button type="text" @click.stop="openPreview(row.id)">预览</el-button>
                <el-button
                  v-if="[0, 2].includes(+row.surveyState)"
                  type="text"
                  @click="updateSurveyStatus(row.id, 1, row)">
                  开启
                </el-button>
                <el-button v-if="row.surveyState == 0" type="text" @click="goRoute('add', '', row.id)">编辑</el-button>
                <el-button v-if="[1, 2].includes(+row.surveyState)" @click.stop="openChannels(row.id)" type="text">
                  分享
                </el-button>
                <el-button
                  v-if="[1, 4].includes(+row.surveyState)"
                  type="text"
                  @click="updateSurveyStatus(row.id, 2, row)">
                  暂停
                </el-button>
                <el-button
                  v-if="[1, 2].includes(+row.surveyState)"
                  type="text"
                  @click="updateSurveyStatus(row.id, 3, row)">
                  结束
                </el-button>
                <el-button v-if="row.surveyState != 1" type="text" @click="removeFn('single', row.id)">删除</el-button>
                <el-button v-if="row.surveyState != 0" type="text" @click="goRoute('smartFormStatistics', row.id)">
                  统计
                </el-button>
                <!-- <el-dropdown style="margin-left: 10px">
                  <el-button type="text">
                    <i class="el-icon-more"></i>
                  </el-button>
                  <el-dropdown-menu slot="dropdown">
                    <el-dropdown-item>
                      <el-button type="text" @click="download(row.id, row.qrGroupName, row.name)">下载</el-button>
                    </el-dropdown-item>
                    <el-dropdown-item>
                      <el-button type="text" @click="removeFn('single', row.id)">删除</el-button>
                    </el-dropdown-item>
                  </el-dropdown-menu>
                </el-dropdown> -->
              </template>
            </el-table-column>
          </el-table>
          <!-- <div class="bottom"> -->

          <pagination :total="total" :page.sync="query.pageNum" :limit.sync="query.pageSize" @pagination="getList()" />
          <!-- </div> -->
        </div>
      </div>
    </div>

    <!-- 批量新建弹窗 -->
    <!--   <SelectUser
      :visible.sync="dialogVisible"
      title="组织架构"
      :defaultValues="userArray"
      @success="getSelectUser"
    ></SelectUser> -->

    <el-dialog :title="`${groupForm.id ? '修改' : '新建'}分组`" :visible.sync="groupVisible" width="30%">
      <el-form :model="groupForm" :rules="rules" ref="groupForm">
        <el-form-item label="分组名称" prop="name" label-width="80px">
          <el-input v-model="groupForm.name" clearable autocomplete="off" maxlength="15" show-word-limit></el-input>
        </el-form-item>
      </el-form>
      <div slot="footer" class="dialog-footer">
        <el-button @click="groupVisible = false">取 消</el-button>
        <el-button type="primary" @click="onAddOrUpdateGroup">确 定</el-button>
      </div>
    </el-dialog>

    <el-dialog title="表单预览" :visible.sync="Preview" width="auto" destroy-on-close>
      <FormsDetail style="margin: -20px 5px 0" :FormIdY="FormIdY" id="y" :key="FormIdY"></FormsDetail>
    </el-dialog>

    <el-dialog title="表单分享" :visible.sync="ifChannels" width="auto" destroy-on-close>
      <Channels style="margin-top: -20px" :FormIdY="FormIdY" :key="FormIdY"></Channels>
    </el-dialog>
  </div>
</template>

<script>
import {
  surveyList,
  deleteInfoToSurvey,
  updateSurveyStatus,
  updateInfoToSurvey,
  // updateSurveyGroup
} from '@/api/drainageCode/smartForms.js'
import { dateFormat } from '@/utils/index'
import FormsDetail from './build/formsDetail.vue'
import Channels from './components/Channels.vue'
import {
  getList,
  downloadBatch,
  getCodeCategoryList,
  addCodeCategory,
  updateCodeCategory,
  removeCodeCategory,
} from '@/api/drainageCode/staff'

const groupForm = {
  mediaType: 15,
  name: '',
}
export default {
  name: 'CodeStaff',
  components: {
    FormsDetail,
    Channels,
  },
  data() {
    return {
      //当前时间戳
      newData: '',
      //分享显示
      ifChannels: false,
      newGroupId: '',
      //预览表单id
      FormIdY: '',
      //预览显示
      Preview: false,
      //默认分组id
      DefaultGroupingId: '',
      // 查询参数
      seachDate: '',
      query: {
        createTime: '',
        pageNum: 1,
        pageSize: 10,
        groupId: '',
        surveyName: '',
        surveyState: undefined,

        // qrName: '', // 活码名称
        // qrUserName: undefined,
        // orderByColumn: 'wqc.update_time',
        // isAsc: 'desc',
      },
      // 日期范围
      dateRange: [],
      userArray: [], // 选择人员
      userArrayStr: '',
      dialogVisible: false,
      // 遮罩层
      loading: false,
      // 选中数组
      ids: [],
      // 总条数
      total: 0,
      // 表格数据
      list: [],
      // 表单参数
      form: {
        codeType: 3,
        qrcode: '',
        isJoinConfirmFriends: 0,
        weEmpleCodeTags: [],
        weEmpleCodeUseScops: [],
      },
      groupList: [],
      groupVisible: false,
      groupForm: JSON.parse(JSON.stringify(groupForm)),
      rules: {
        name: [
          {
            required: true,
            message: '请输入分组名称',
            trigger: 'blur',
          },
          {
            min: 1,
            max: 15,
            message: '长度在 1 到 15 个字符',
            trigger: 'blur',
          },
        ],
      },
      groupIndex: 0,
    }
  },
  created() {
    this.getCodeCategoryListFn()
    // this.$store.dispatch(
    //   'app/setBusininessDesc',
    //   `
    //   <div>支持单人、批量单人及多人方式新建员工活码,客户可以通过扫描员工活码添加员工为好友,并支持自动给客户打标签和发送欢迎语。</div>
    // `
    // )
  },
  mounted() {},
  methods: {
    openPreview(id) {
      this.FormIdY = id
      this.Preview = true
    },
    openChannels(id) {
      this.FormIdY = id
      this.ifChannels = true
    },
    //更新表单状态
    updateInfoToSurvey(data) {
      updateInfoToSurvey(data)
        .then((res) => {
          console.log('更改状态返回值', res)
        })
        .catch(() => {})
    },
    //开启表单
    updateSurveyStatus(id, surveyState, row, style) {
      let that = this
      console.log('row', row.surveyState, row.timingStart, row)

      if (row.surveyState == 0 && !row.timingStart) {
        let data = {
          id: id,
          timingStart: dateFormat(new Date()),
        }
        console.log('data', data)
        this.updateInfoToSurvey(data)
      } else if (row.surveyState == 0 && row.timingStart) {
        let data = {
          id: id,
          timingStart: row.timingStart,
          timingEnd: row.timingEnd,
        }
        console.log('data', data)
        this.updateInfoToSurvey(data)
      }
      if (surveyState == 1) {
        if (row.timingStart) {
          let newData = new Date()
          if (newData < new Date(row.timingStart)) {
            surveyState = 1
            let data = {
              id: id,
              timingStart: dateFormat(new Date()),
              timingEnd: row.timingEnd,
            }
            this.updateInfoToSurvey(data)
          }
        }
        if (row.timingEnd) {
          let newData = new Date()
          if (newData > new Date(row.timingEnd)) {
            surveyState = 3
          }
        }
      }
      console.log('surveyState', surveyState)
      console.log('row.timingStart', row.timingStart)
      if (surveyState == 3) {
        let newData = new Date()
        let data = {
          id: id,
          timingEnd: dateFormat(new Date()),
        }
        this.updateInfoToSurvey(data)
      }
      let data = {
        id: id,
        surveyState: surveyState,
      }
      updateSurveyStatus(data)
        .then((res) => {
          if ([1, 2, 3].includes(surveyState) && style != 'no') {
            this.msgSuccess('操作成功')
          }

          that.getList()
        })
        .catch(() => {})
    },
    addGroup() {
      this.groupForm = JSON.parse(JSON.stringify(groupForm))
      this.groupVisible = true
    },
    getCodeCategoryListFn() {
      getCodeCategoryList({ mediaType: groupForm.mediaType }).then(({ data }) => {
        this.groupList = data
        let groupId = this.$route.query && this.$route.query.groupId
        let groupIndex = data.findIndex((e) => e.id === groupId)
        if (groupId && groupIndex != -1) {
          this.query.groupId = groupId
          this.query.groupName = data[groupIndex].name
          this.groupIndex = groupIndex
        } else {
          this.query.groupId = undefined
          this.query.groupName = undefined
          this.groupIndex = undefined
        }
        this.query.pageNum = 1
        for (let i = 0; i < data.length; i++) {
          if (data[i].name == '默认分组') {
            this.newGroupId = data[i].id
          }
        }
        this.getList()
      })
    },
    switchGroup(index, data) {
      console.log('data', data)
      this.groupIndex = index
      this.query.groupName = data.name
      this.$router.replace({
        query: {
          groupId: data.id,
        },
      })

      this.query.groupId = data.id
      this.search()
    },
    getSelectUser(data) {
      this.userArray = data
      this.query.qrUserName = this.userArray
        .map(function (obj, index) {
          return obj.name
        })
        .join(',')
    },
    search() {
      this.query.pageNum = 1
      this.getList()
    },
    getList() {
      if (this.dateRange) {
        this.query.startDate = this.dateRange[0]
        this.query.endDate = this.dateRange[1]
      } else {
        this.query.startDate = ''
        this.query.endDate = ''
      }
      this.loading = true
      surveyList(this.query)
        .then((res) => {
          this.total = Number(res.total)
          this.list = res.rows
          for (let i = 0; i < this.list.length; i++) {
            if (this.list[i].surveyState == 4) {
              if (this.list[i].timingStart) {
                let newData = new Date()
                if (newData < new Date(this.list[i].timingStart)) {
                  this.list[i].surveyState = 4
                } else {
                  this.list[i].surveyState = 1
                  this.updateSurveyStatus(this.list[i].id, 1, this.list[i], 'no')
                }
              }
              if (this.list[i].timingEnd) {
                let newData = new Date()
                if (newData > new Date(this.list[i].timingEnd)) {
                  this.list[i].surveyState = 3
                }
              }
            }
            // this.list[i].createTime=this.list[i].createTime.substr(0,10);
          }
          this.loading = false
          this.ids = []
        })
        .catch(() => {
          this.loading = false
        })
    },
    /** 重置按钮操作 */
    resetQuery() {
      // this.query.qrName = ''
      this.query.createTime = ''
      this.query.surveyState = ''
      this.query.surveyName = ''
      this.query.id = ''
      // this.userArray = []
      // this.query.addState = ''
      // this.query.userArrayStr = ''
      this.search()
    },
    goRoute(path, id, formId, currentActiveA, currentActiveB) {
      this.$router.push({
        path: path,
        query: {
          id,
          formId,
          currentActiveA,
          currentActiveB,
          groupId: this.query.groupId,
        },
      })
    },
    // 多选框选中数据
    handleSelectionChange(selection) {
      console.log('selection', selection)
      this.ids = selection.map((item) => item.id)
    },
    /** 删除按钮操作 */
    removeFn(type, id) {
      if (type === 'mult' && !this.ids.length) {
        this.msgInfo('请选择要删除项!')
        return
      }
      const ids = id || this.ids.join(',')
      this.$confirm('是否确定删除当前问卷?该操作同步删除所有数据,且不可恢复,请谨慎操作?', '提示', {
        confirmButtonText: '确定',
        cancelButtonText: '取消',
        type: 'warning',
      })
        .then(() => {
          return deleteInfoToSurvey(ids)
        })
        .then(() => {
          this.search()
          this.msgSuccess('删除成功')
        })
        .catch(function () {})
    },
    download(id, userName, qrName) {
      let name = userName + '-' + qrName + '.png'
      downloadBatch(id).then((res) => {
        if (res != null) {
          let blob = new Blob([res], {
            type: 'application/zip',
          })
          let url = window.URL.createObjectURL(blob)
          const link = document.createElement('a') // 创建a标签
          link.href = url
          link.download = name // 重命名文件
          link.click()
          URL.revokeObjectURL(url) // 释放内存
        }
      })
    },
    /** 下载 */
    downloadBatch(qrCode) {
      if (!this.ids.length) {
        this.msgInfo('请先勾选下载项!')
        return
      }
      this.$confirm('是否确认下载所有图片吗?', '警告', {
        confirmButtonText: '确定',
        cancelButtonText: '取消',
        type: 'warning',
      })
        .then(() => {
          return downloadBatch(this.ids.join(','))
        })
        .then((res) => {
          if (res != null) {
            let blob = new Blob([res], {
              type: 'application/zip',
            })
            let url = window.URL.createObjectURL(blob)
            const link = document.createElement('a') // 创建a标签
            link.href = url
            link.download = '批量员工活码.zip' // 重命名文件
            link.click()
            URL.revokeObjectURL(url) // 释放内存
          }
        })
        .catch(function () {})
    },
    // 新增分组
    onAddOrUpdateGroup() {
      this.$refs.groupForm.validate((validate) => {
        console.log(this.groupForm)
        if (this.groupForm.id) {
          let obj = {
            id: this.groupForm.id,
            name: this.groupForm.name,
            mediaType: groupForm.mediaType,
          }
          this.groupForm = obj
        }
        if (validate) {
          ;(this.groupForm.id ? updateCodeCategory : addCodeCategory)(this.groupForm).then((res) => {
            this.groupVisible = false
            this.groupForm = JSON.parse(JSON.stringify(groupForm))
            this.$refs.groupForm.clearValidate()
            this.msgSuccess('操作成功')
            this.getCodeCategoryListFn()
          })
        }
      })
    },
    onGroupCommand(e, group) {
      if (group.id === '1') {
        this.msgInfo('默认分组不可操作!')
        return
      }
      if (e == 'edit') {
        this.editGroup(group)
      } else if (e == 'remove') {
        this.removeGroup(group.id)
      }
    },
    editGroup(group) {
      this.groupForm = JSON.parse(JSON.stringify(group))
      this.groupVisible = true
    },
    removeGroup(id) {
      let that = this
      this.$confirm('是否确认删除当前分组,删除后所有表单将设置为默认分组,该操作不可撤销,请谨慎操作。', '提示', {
        confirmButtonText: '确定',
        cancelButtonText: '取消',
        type: 'warning',
      })
        .then(() => {
          let data = {
            groupId: id,
            newGroupId: that.newGroupId,
          }
          console.log('updateSurveyGroup')
          removeCodeCategory(id).then((res) => {
            this.msgSuccess('操作成功')
            that.getCodeCategoryListFn()
          })
          // updateSurveyGroup(that.$qs.stringify(data)).then((res) => {
          // })
        })
        .catch(() => {})
    },
  },
}
</script>

<style lang="scss" scoped>
.bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.my-divider {
  display: block;
  height: 1px;
  width: 100%;
  background-color: #dcdfe6;
}

.hover-item {
  font-size: 12px;

  font-weight: 400;
  color: var(--color);
  padding: 6px 15px;
  cursor: pointer;

  &:hover {
    background-color: #f5f8fe;
  }
}
</style>