index.vue 24.7 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 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 784 785
<template>
  <div class="app-container">
    <el-form
      :model="queryParams"
      ref="queryForm"
      size="small"
      :inline="true"
      v-show="showSearch"
      label-width="100px"
    >
      <el-form-item label="订单编号" prop="name">
        <el-select
          v-model="queryParams.SearchType1"
          clearable
          style="width: 100px"
        >
          <el-option
            v-for="dict in SearchType"
            :key="dict.value"
            :label="dict.label"
            :value="dict.value"
          />
        </el-select>
        <el-input
          style="width: 200px"
          v-model="queryParams.orderNo"
          placeholder="请输入订单编号"
          clearable
          @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="提单号" prop="tidanNo">
        <el-select
          v-model="queryParams.SearchType2"
          clearable
          style="width: 100px"
        >
          <el-option
            v-for="dict in SearchType"
            :key="dict.value"
            :label="dict.label"
            :value="dict.value"
          />
        </el-select>
        <el-input
          style="width: 200px"
          v-model="queryParams.tidanNo"
          placeholder="请输入提单号"
          clearable
          @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="发货人编号">
        <el-select
          v-model="queryParams.SearchType3"
          clearable
          style="width: 100px"
        >
          <el-option
            v-for="dict in SearchType"
            :key="dict.value"
            :label="dict.label"
            :value="dict.value"
          />
        </el-select>
        <el-input
          style="width: 200px"
          v-model="queryParams.fhNumber"
          placeholder="请输入发货人编号"
          clearable
        />
      </el-form-item>
      <el-form-item label="收货人编号" prop="shNumber">
        <el-select
          v-model="queryParams.SearchType4"
          clearable
          style="width: 100px"
        >
          <el-option
            v-for="dict in SearchType"
            :key="dict.value"
            :label="dict.label"
            :value="dict.value"
          />
        </el-select>
        <el-input
          style="width: 200px"
          v-model="queryParams.shNumber"
          placeholder="请输入收货人编号"
          clearable
        />
      </el-form-item>
      <el-form-item label="唛头" prop="remark">
        <el-select
          v-model="queryParams.SearchType5"
          clearable
          style="width: 100px"
        >
          <el-option
            v-for="dict in SearchType"
            :key="dict.value"
            :label="dict.label"
            :value="dict.value"
          />
        </el-select>
        <el-input
          v-model="queryParams.marks"
          placeholder="请输入唛头"
          style="width: 200px"
          clearable
        />
      </el-form-item>
      <el-form-item label="客户经理" prop="salesmanId">
        <user-selector
          manage
          v-model="queryParams.salesmanId"
          clearable
          @change="handleQuery"
          :prepend="{ id: 0, nickname: $t('未分配客户经理') }"
        />
      </el-form-item>
      <el-form-item label="部门" prop="remark">
        <treeselect
          v-model="queryParams.deptid"
          :options="deptOptions"
          :show-count="true"
          :placeholder="$t('请选择部门')"
          :normalizer="normalizer"
        />
      </el-form-item>

      <el-form-item :label="$t('订单状态')" prop="status">
        <dict-selector
          :type="DICT_TYPE.ORDER_STATUS"
          v-model="queryParams.status"
          @keyup.enter.native="handleQuery"
          clearable
        />
      </el-form-item>

      <el-form-item :label="$t('运输方式')" prop="transportId">
        <dict-selector
          :type="DICT_TYPE.ECW_TRANSPORT_TYPE"
          v-model.number="queryParams.transportId"
          clearable
          @change="handleQuery"
        />
      </el-form-item>

      <el-form-item :label="$t('始发仓')" prop="startWarehouseId">
        <el-select
          v-model="queryParams.startWarehouseId"
          :placeholder="$t('请选择始发仓')"
          clearable
          @change="handleQuery"
        >
          <el-option
            v-for="item in exportWarehouseList"
            :label="$l(item, 'title')"
            :value="item.id"
            :key="item.id"
          ></el-option>
        </el-select>
      </el-form-item>

      <el-form-item label="目的国" prop="muDiGuo">
        <el-select
          clearable
          v-model="queryParams.muDiGuo"
          :placeholder="$t('请选择国家')"
        >
          <el-option
            v-for="dict in countryList"
            :key="dict.id"
            :label="isChinese ? dict.nameZh : dict.nameEn"
            :value="parseInt(dict.id)"
          />
        </el-select>
      </el-form-item>
      <el-form-item label="目的城市" prop="muDiShi">
        <el-input
          v-model="queryParams.muDiShi"
          placeholder="选择目的城市"
          clearable
          @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item :label="$t('目的仓')" prop="destWarehouseId">
        <el-select
          v-model="queryParams.destWarehouseId"
          :placeholder="$t('请选择目的仓')"
          clearable
          @change="handleQuery"
        >
          <el-option
            v-for="item in importWarehouseList"
            :label="$l(item, 'title')"
            :value="item.id"
            :key="item.id"
          ></el-option>
        </el-select>
      </el-form-item>
      <el-form-item :label="$t('是否控货')" prop="isCargoControl">
        <el-select v-model="queryParams.isCargoControl" clearable>
          <el-option label="是" value="1"></el-option>
          <el-option label="否" value="0"></el-option>
        </el-select>
      </el-form-item>
      <el-form-item label="重泡类型" prop="remark">
        <el-select v-model="queryParams.zpType" clearable>
          <el-option label="重货" value="2"></el-option>
          <el-option label="泡货" value="3"></el-option>
          <el-option label="普货" value="1"></el-option>
        </el-select>
      </el-form-item>
      <el-form-item label="付款方" prop="remark">
        <el-select v-model="queryParams.drawee" clearable>
          <el-option label="发货方" value="1"></el-option>
          <el-option label="收货方" value="2"></el-option>
          <el-option label="自定义" value="3"></el-option>
        </el-select>
      </el-form-item>
      <el-form-item label="渠道" prop="remark">
        <el-select v-model="queryParams.shippingChannelId" clearable>
          <el-option
            v-for="item in channelList"
            :key="item.id"
            :label="$l(item, 'name')"
            :value="item.channelId"
          />
        </el-select>
      </el-form-item>
      <el-form-item label="资源类型" prop="ResourceType">
        <el-select v-model="queryParams.ResourceType" clearable>
          <el-option label="开发客户" value="1"></el-option>
          <el-option label="公司客户" value="2"></el-option>
        </el-select>
      </el-form-item>
      <el-form-item label="业绩类型" prop="YeJiType">
        <el-select v-model="queryParams.YeJiType" clearable>
          <el-option label="新客户" value="1"></el-option>
          <el-option label="老客户" value="2"></el-option>
        </el-select>
      </el-form-item>
      <el-form-item label="数据筛选" prop="remark">
        <el-select
          v-model="queryParams.dataSearch1"
          clearable
          style="width: 150px"
        >
          <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-option label="提货率" value="4"></el-option>
        </el-select>
        <el-select
          v-model="queryParams.dataSearch2"
          clearable
          style="width: 150px"
        >
          <el-option label="大于等于" value="1"></el-option>
          <el-option label="等于" value="2"></el-option>
          <el-option label="小于等于" value="3"></el-option>
        </el-select>
        <el-input
          style="width: 100px"
          v-model="queryParams.dataSearch3"
          placeholder="请输入数值"
          clearable
          @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="时间筛选" prop="dateSearch">
        <el-select v-model="queryParams.dateSearch1" clearable>
          <el-option label="订单创建时间" value="1"></el-option>
          <el-option label="业绩创建时间" value="2"></el-option>
          <el-option label="首次入仓时间" value="3"></el-option>
        </el-select>
        <el-date-picker
          v-model="queryParams.sdate1"
          type="date"
          value-format="yyyy-MM-dd"
          clearable
          placeholder="请输入起始日期"
        />
        <el-date-picker
          v-model="queryParams.edate1"
          type="date"
          value-format="yyyy-MM-dd"
          clearable
          placeholder="请输截止日期"
        />
      </el-form-item>
      <el-form-item>
        <el-button type="primary" icon="el-icon-search" @click="handleQuery"
          >搜索</el-button
        >
        <el-button icon="el-icon-refresh" @click="resetQuery">重置</el-button>
        <el-button
          type="warning"
          plain
          icon="el-icon-download"
          size="mini"
          @click="handleExport"
          :loading="exportLoading"
          v-show="objEcwReportPermission.exportdataq == 1"
          >导出</el-button
        >
      </el-form-item>
    </el-form>
    <el-row>
      <el-col :span="24" class="card-box">
        <el-card>
          <div class="el-table el-table--enable-row-hover el-table--medium">
            <table cellspacing="0" style="width: 100%">
              <tbody>
                <tr>
                  <td><div class="cell"></div></td>
                  <td>
                    <div class="cell">
                      总箱数:{{ StatisticalSummary.sumBox }}
                    </div>
                  </td>
                  <td>
                    <div class="cell">
                      总方数:{{ StatisticalSummary.sumM3 }}
                    </div>
                  </td>
                  <td>
                    <div class="cell">
                      总重量:{{ StatisticalSummary.sumKG }}
                    </div>
                  </td>
                  <td>
                    <div class="cell">总V值:{{ StatisticalSummary.sumV }}</div>
                  </td>
                </tr>
                <tr>
                  <td><div class="cell">新客户</div></td>
                  <td>
                    <div class="cell">
                      总箱数:{{ StatisticalSummary.sumBoxNew }}
                    </div>
                  </td>
                  <td>
                    <div class="cell">
                      总方数:{{ StatisticalSummary.sumM3New }}
                    </div>
                  </td>
                  <td>
                    <div class="cell">
                      总重量:{{ StatisticalSummary.sumKGNew }}
                    </div>
                  </td>
                  <td>
                    <div class="cell">
                      总V值:{{ StatisticalSummary.sumVNew }}
                    </div>
                  </td>
                </tr>
                <tr>
                  <td><div class="cell">旧客户</div></td>
                  <td>
                    <div class="cell">
                      总箱数:{{ StatisticalSummary.sumBoxOld }}
                    </div>
                  </td>
                  <td>
                    <div class="cell">
                      总方数:{{ StatisticalSummary.sumM3Old }}
                    </div>
                  </td>
                  <td>
                    <div class="cell">
                      总重量:{{ StatisticalSummary.sumKGOld }}
                    </div>
                  </td>
                  <td>
                    <div class="cell">
                      总V值:{{ StatisticalSummary.sumVOld }}
                    </div>
                  </td>
                </tr>
              </tbody>
            </table>
          </div>
        </el-card>
      </el-col>
    </el-row>
    <!-- 列表 -->
    <el-table v-loading="loading" :data="list">
      <el-table-column label="排名" align="center" prop="px" />
      <el-table-column label="订单编号" align="center" prop="orderNo">
        <template slot-scope="scope">
          <router-link
            :to="{
              path: '/order/detail',
              query: { orderId: scope.row.orderId },
            }"
            class="link-type"
          >
            <span>{{ scope.row.orderNo }}</span>
          </router-link>
        </template>
      </el-table-column>
      <el-table-column label="提单号" align="center" prop="tidanNo">
        <template slot-scope="scope">
          <router-link
            :to="{
              path: '/order/detail',
              query: { orderId: scope.row.orderId },
            }"
            class="link-type"
          >
            <span>{{ scope.row.tidanNo }}</span>
          </router-link>
        </template>
      </el-table-column>
      <el-table-column label="发货人编号" align="center" prop="fhNumber">
        <template slot-scope="{ row }">
          <el-link
            type="primary"
            @click.native="$router.push('/customer/query/' + row.cfCustomerId)"
            >{{ row.fhNumber }}</el-link
          >
        </template>
      </el-table-column>
      <el-table-column label="收货人编号" align="center" prop="shNumber">
        <template slot-scope="{ row }">
          <el-link
            type="primary"
            @click.native="$router.push('/customer/query/' + row.shCustomerId)"
            >{{ row.shNumber }}</el-link
          >
        </template>
      </el-table-column>
      <el-table-column label="客户经理" align="center" prop="salesmanidName">
      </el-table-column>
      <el-table-column label="订单状态" align="center" prop="statusName" />
      <el-table-column label="运输方式" align="center" prop="transportIdName" />
      <el-table-column
        label="始发仓"
        align="center"
        prop="startwarehousename"
      />
      <el-table-column label="目的国" align="center" prop="muDiGuo" />
      <el-table-column label="目的城市" align="center" prop="muDiShi" />
      <el-table-column label="目的仓" align="center" prop="dstwarehousename" />
      <el-table-column label="渠道" align="center" prop="channelidName" />
      <el-table-column label="创建时间" align="center" prop="createtime" />
      <el-table-column
        label="业绩创建时间"
        align="center"
        prop="businesstime"
      />
      <el-table-column
        label="资源类型"
        align="center"
        prop="showResourceType"
      />
      <el-table-column label="业绩类型" align="center" prop="showYeJiType" />
      <el-table-column label="唛头" align="center" prop="marks" />
      <el-table-column label="入仓箱数" align="center" prop="sumquantity" />
      <el-table-column label="体积" align="center" prop="sumvolume" />
      <el-table-column label="重量" align="center" prop="sumweight" />
      <el-table-column label="是否控货" align="center" prop="iscargocontrol" />
      <el-table-column label="重货/泡货" align="center" prop="ordertypeShow" />
      <el-table-column label="重货/泡货标准" align="center" prop="zpUnitShow" />
      <el-table-column label="付款方" align="center" prop="draweeName" />
      <el-table-column label="首次入仓时间" align="center" prop="firstInTime" />
      <el-table-column label="提货率" align="center" prop="showThl">
      </el-table-column>
      <el-table-column label="入仓记录" align="center" prop="orderId">
        <template slot-scope="{ row }">
          <el-link type="primary" @click.native="showWarehouseLogs(row, 1)">
            入仓记录
          </el-link>
        </template>
      </el-table-column>
    </el-table>
    <!-- 分页组件 -->
    <pagination
      v-show="total > 0"
      :total="total"
      :page.sync="queryParams.pageNo"
      :limit.sync="queryParams.pageSize"
      @pagination="getList"
    />

    <warehouse-detail
      :order="order"
      :orderItemId="showWarehouseInItemId"
      :type="type"
      @openPackHistory="openPackHistory"
      v-if="showWarehouseInItemId"
      @close="showWarehouseInItemId = null"
    />
  </div>
</template>
  
  <script>
import UserSelector from "@/components/UserSelector";
import { getCountryListAll } from "@/api/ecw/country";
import Treeselect from "@riophae/vue-treeselect";
import "@/assets/styles/vue-treeselect.css";
import { getWarehouseList } from "@/api/ecw/warehouse";
import {
  getListPage,
  exportExcel,
  getStatisticalSummary,
} from "@/api/report/salesanalysis";
import { getCurUserPermission } from "@/api/report/EcwReportPermission";
import { getAllChannelList, getChannelList } from "@/api/ecw/channel";
import { listSimpleDepts } from "@/api/system/dept";
import { getOrder } from "@/api/ecw/order";
//入仓记录页面
import WarehouseDetail from "@/views/report/WarehouseInDetail/index.vue";

//2024-05-01合并
export default {
  name: "ReportSales_analysisIndex",
  components: {
    UserSelector,
    Treeselect,
    WarehouseDetail,
  },
  data() {
    return {
      // 遮罩层
      loading: true,
      // 导出遮罩层
      exportLoading: false,
      // 显示搜索条件
      showSearch: true,
      // 总条数
      total: 0,
      // 测试列表
      list: [],
      // 弹出层标题
      title: "",
      // 是否显示弹出层
      open: false,
      showDetail: false,
      deptOptions: undefined,
      dateRangeCreateTime: [],
      SearchType: [
        { value: "in", label: "包含" },
        { value: "notin", label: "不包含" },
        { value: "eq", label: "等于" },
        { value: "noeq", label: "不等于" },
      ],
      // 查询参数
      queryParams: {
        pageNo: 1,
        pageSize: 10,
        SearchType3: "eq",
        fhNumber: undefined, //发货客户编号
        SearchType4: "eq",
        shNumber: undefined, //收货客户编号
        startWarehouseId: undefined, //始发仓
        muDiGuo: undefined, //目的国
        muDiShi: undefined, //目的城市
        dstwarehousename: undefined, //目的仓
        transportId: undefined, //运输方式
        SearchType1: "eq", //订单编号查询类型
        orderNo: undefined, //订单编号
        SearchType2: "eq", //提单号的查询类别
        tidanNo: undefined, //提单号
        SearchType5: "in",
        marks: undefined, //唛头
        status: undefined, //订单状态
        salesmanId: undefined, //客户经理
        isCargoControl: undefined, //是否控货
        deptid: undefined, //部门
        drawee: undefined, //付款方
        zpType: undefined, //货物类型,1普货,2重货,3泡货
        YeJiType: undefined, //业绩类型 新客户,老客户
        dateSearch1: undefined, //时间筛选类型
        sdate1: undefined, //开始时间
        edate2: undefined, //结束时间
        dataSearch1: undefined, //数据类型筛选
        dataSearch2: undefined, //比较符号设置
        dataSearch3: undefined, //数据值
      },
      channelList: [],
      countryList: [],
      // 表单参数
      form: {},
      // 表单校验
      rules: {},
      warehouseList: [],
      //报表权限信息
      objEcwReportPermission: {},
      DeptEx: { id: undefined, name: undefined, parentId: undefined },
      showWarehouseInItemId: undefined,
      order: null,
      type: 1,
      StatisticalSummary: {
        sumBox: 0,
        sumM3: 0,
        sumKG: 0,
        sumV: 0,
        sumBoxNew: 0,
        sumM3New: 0,
        sumKGNew: 0,
        sumVNew: 0,
        sumBoxOld: 0,
        sumM3Old: 0,
        sumKGOld: 0,
        sumVOld: 0,
      },
    };
  },
  created() {
    //获取国家列表
    getCountryListAll().then((r) => {
      this.countryList = r.data;
    });
    getAllChannelList().then((res) => (this.channelList = res.data));
    getWarehouseList().then((res) => (this.warehouseList = res.data));
    this.loading = false;
    //获取当前用户报表权限
    getCurUserPermission().then((response) => {
      //复制对象
      Object.assign(this.objEcwReportPermission, response.data);
      if (this.objEcwReportPermission.permissionFw == 1) {
        //只能看自己的,不能选择部门和客户经理
        // this.showCustomsManage = false;
        // this.showDept = false;
      }
      this.getTreeselect();
      this.getList();
    });
  },
  computed: {
    exportWarehouseList() {
      //始发仓列表
      return this.warehouseList.filter(
        (item) => item.tradeType == 2 || item.tradeType == 3
      );
    },
    importWarehouseList() {
      //目的仓列表
      return this.warehouseList.filter(
        (item) => item.tradeType == 1 || item.tradeType == 3
      );
    },
  },
  methods: {
    /** 查询列表 */
    getList() {
      this.loading = true;
      // 处理查询参数
      let params = { ...this.queryParams };
      // 执行查询
      getListPage(params).then((response) => {
        this.list = response.data.list;
        this.total = response.data.total;
        this.loading = false;
      });

      //获取统计数据
      getStatisticalSummary(params).then((response) => {
        this.StatisticalSummary = response.data;
      });
    },

    /** 表单重置 */
    reset() {
      this.form = {
        id: undefined,
        name: undefined,
        empGender: undefined,
        age: undefined,
        email: undefined,
      };
      this.resetForm("form");
    },
    isChinese() {
      //基础函数,判断系统显示语言是中文还是英文
      return this.$i18n.locale === "zh_CN";
    },
    /** 搜索按钮操作 */
    handleQuery() {
      this.queryParams.pageNo = 1;
      this.getList();
    },
    /** 重置按钮操作 */
    resetQuery() {
      this.dateRangeCreateTime = [];
      this.resetForm("queryForm");
      this.handleQuery();
    },
    /** 导出按钮操作 */
    handleExport() {
      // 处理查询参数
      let params = { ...this.queryParams };
      params.pageNo = undefined;
      params.pageSize = undefined;
      // 执行导出
      this.$modal
        .confirm("是否确认导出所有数据?")
        .then(() => {
          this.exportLoading = true;
          return exportExcel(params);
        })
        .then((response) => {
          //this.$download.excel(response, "销售分析数据报表.xls");
          this.exportLoading = false;
          this.$message.success(
            this.$t("已加入导出队列,请稍后在下载日志中下载")
          );
        })
        .catch(() => {});
    },
    // 显示入仓记录
    showWarehouseLogs(row, type) {
      getOrder(row.orderId).then((response) => {
        this.order = response.data;//组件中只用到了此参数
        this.type = 2;
        this.showWarehouseInItemId = 1;
      });
    },
    openPackHistory(id) {
      //查询打包历史
      //this.shopPackId = id
    },
    /** 查询部门下拉树结构 + 岗位下拉 */
    getTreeselect() {
      if (this.objEcwReportPermission.permissionFw == 3) {
        listSimpleDepts().then((response) => {
          // 处理 deptOptions 参数
          this.deptOptions = [];
          this.deptOptions.push(...this.handleTree(response.data, "id"));
        });
      } else if (this.objEcwReportPermission.permissionFw == 2) {
        this.DeptEx.id = this.objEcwReportPermission.deptId;
        getDeptChild(this.DeptEx).then((response) => {
          this.deptOptions = [];
          this.deptOptions.push(...this.handleTree(response.data, "id"));
        });
      }
    },
    normalizer(node) {
      //格式化部门的下拉框
      return {
        id: node.id,
        label: node.name,
        children: node.children,
      };
    },
  },
};
</script>

<style lang="scss" scoped>
.dashboard-editor-container {
  padding: 32px;
  background-color: rgb(240, 242, 245);
  position: relative;

  .chart-wrapper {
    background: #fff;
    padding: 32px 32px 0;
    margin-bottom: 32px;
    margin-left: 32px;
  }
}

@media (max-width: 1024px) {
  .chart-wrapper {
    padding: 8px;
  }
}
/* .my-process-designer {
  height: calc(100vh - 200px);
} */

.box-card {
  width: 100%;
  margin-bottom: 20px;
}
</style>