|
@@ -0,0 +1,1439 @@
|
|
|
+<template>
|
|
|
+ <n-divider dashed title-placement="left">{{wbsTypeTabKey === 'tree'?'树形结构填报':'导图结构填报'}}</n-divider>
|
|
|
+ <div class="hc-layout-box">
|
|
|
+ <div class="hc-layout-left-box" :style="'width:' + leftWidth + 'px;'" v-if="wbsTypeTabKey === 'tree'">
|
|
|
+ <div class="hc-project-box">
|
|
|
+ <div class="text-xl text-cut project-alias-box">
|
|
|
+ <i class="hcicon-xiangmu"/>
|
|
|
+ <span class="ml-2">{{projectInfo['projectAlias']}}</span>
|
|
|
+ </div>
|
|
|
+ <div class="text-xs text-cut project-name">{{projectInfo['name']}}</div>
|
|
|
+ </div>
|
|
|
+ <div class="hc-el-tree-box">
|
|
|
+ <HcTree ref="HcTreeRef" type="data-fill-wbs" :params="treeParams" :props="wbsElTreeProps" :menus="ElTreeMenu" :menuMark="TreeMark" lazy :autoExpandKeys="TreeAutoExpandKeys" isColor @node-click="wbsElTreeClick" @menuTap="ElTreeMenuClick"/>
|
|
|
+ </div>
|
|
|
+ <div class="hc-tree-foot-tip-box">
|
|
|
+ <div class="dot-view green">已审批</div>
|
|
|
+ <div class="dot-view black">未填报</div>
|
|
|
+ <div class="dot-view orange">已填报-待审批</div>
|
|
|
+ <div class="dot-view blue">已填报-未上报</div>
|
|
|
+ </div>
|
|
|
+ <!--左右拖动-->
|
|
|
+ <div class="horizontal-drag-line" @mousedown="onmousedown"/>
|
|
|
+ </div>
|
|
|
+ <div class="hc-layout-content-box">
|
|
|
+ <n-card class="hc-card-overflow-box" :segmented="{content: true}">
|
|
|
+ <template #header>
|
|
|
+ <div class="hc-card-header flex items-center" v-show="wbsTypeTabKey === 'tree' || isDrawer">
|
|
|
+ <n-popover trigger="hover" :disabled="!bubbleVal || !btn_drawings?.textInfo" v-if="btn_drawings">
|
|
|
+ <template #trigger>
|
|
|
+ <n-button type="primary" strong secondary class="px-3" @click="viewsDrawings" v-if="nodeDataInfo.fileUrl">
|
|
|
+ <i class="hcicon-Frame"/>
|
|
|
+ <span class="ml-2">查看图纸</span>
|
|
|
+ </n-button>
|
|
|
+ <n-button color="#EEEEEE" text-color="#999999" class="px-3" @click="viewsDrawingsTip" v-else>
|
|
|
+ <i class="hcicon-Frame"/>
|
|
|
+ <span class="ml-2">查看图纸</span>
|
|
|
+ </n-button>
|
|
|
+ </template>
|
|
|
+ <span>{{btn_drawings?.textInfo}}</span>
|
|
|
+ </n-popover>
|
|
|
+ <BtnTab class="ml-8" :datas="authBtnTabData" :cur="authBtnTabKey" :disabled="!nodeDataInfo?.primaryKeyId" @tabClick="authBtnTabClick"/>
|
|
|
+ </div>
|
|
|
+ </template>
|
|
|
+ <template #header-extra>
|
|
|
+ <HcTabs :datas="wbsTypeTab" :keys="wbsTypeTabKey" @change="wbsTypeTabChange"/>
|
|
|
+ </template>
|
|
|
+ <div class="data-fill-wbs-content" id="data-fill-wbs-content-target">
|
|
|
+ <div class="hc-card-max-h-box" id="hc-card-list-item" v-if="wbsTypeTabKey === 'tree'">
|
|
|
+ <ListItem ref="ListItemRef" :datas="ListItemDatas" :projectId="projectId" :contractId="contractId" :classify="authBtnTabKey" @offsetTop="ListItemOffsetTop" @uploadData="getTableDataAll"/>
|
|
|
+ </div>
|
|
|
+ <div class="hc-card-max-h-box node-tree" v-if="wbsTypeTabKey === 'map'">
|
|
|
+ <NodeTree ref="NodeTreeRef" :data="NodeTreeData" :format="NodeTreeFormat" :autoExpandKeys="TreeAutoExpandKeys" :menus="ElTreeMenu" :isMark="TreeMark" isColor
|
|
|
+ :accordion='NodeTreeAccordion' @nodeClick="NodeTreeClick" @expand="expandClick" @nodeDblClick="NodeTreeDblClick" @menuClick="NodeTreeMenuClick"/>
|
|
|
+ <div class="hc-tree-foot-tip-box bg-svg-xml">
|
|
|
+ <div class="dot-view green">已审批</div>
|
|
|
+ <div class="dot-view black">未填报</div>
|
|
|
+ <div class="dot-view orange">已填报-待审批</div>
|
|
|
+ <div class="dot-view blue">已填报-未上报</div>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ <!--填报弹窗-->
|
|
|
+ <n-drawer v-model:show="isDrawer" :width="200" :height="200" placement="top" :trap-focus="false" :block-scroll="false" to="#data-fill-wbs-content-target">
|
|
|
+ <div class="drawer-data-fill-content-box">
|
|
|
+ <n-card :segmented="{content: true}">
|
|
|
+ <div class="data-fill-content" id="hc-drawer-list-item">
|
|
|
+ <ListItem ref="ListItemsRef" :datas="ListItemDatas" :projectId="projectId" :contractId="contractId" :classify="authBtnTabKey" @offsetTop="ListItemOffsetTop" @uploadData="getTableDataAll"/>
|
|
|
+ </div>
|
|
|
+ <template #action>
|
|
|
+ <div class="data-fill-foot">
|
|
|
+ <template v-if="ListItemDatas.length > 0">
|
|
|
+ <n-popover trigger="hover" :disabled="!bubbleVal || !btn_save?.textInfo" v-if="btn_save && NodeStatus !== '3'">
|
|
|
+ <template #trigger>
|
|
|
+ <n-button type="primary" size="large" class="px-8" :disabled="NodeStatus === '3'" :loading="tableFormSaveLoading" @click="tableFormSaveClick">保存</n-button>
|
|
|
+ </template>
|
|
|
+ <span>{{btn_save?.textInfo}}</span>
|
|
|
+ </n-popover>
|
|
|
+ <n-popover trigger="hover" :disabled="!bubbleVal || !btn_preview?.textInfo" v-if="btn_preview">
|
|
|
+ <template #trigger>
|
|
|
+ <n-button type="primary" strong secondary class="px-8 ml-6" size="large" :disabled="NodeStatus === '1'" :loading="bussPdfsLoading" @click="bussPdfsClick">预览</n-button>
|
|
|
+ </template>
|
|
|
+ <span>{{btn_preview?.textInfo}}</span>
|
|
|
+ </n-popover>
|
|
|
+ <n-popover trigger="hover" :disabled="!bubbleVal || !btn_report?.textInfo" v-if="btn_report && NodeStatus !== '3'">
|
|
|
+ <template #trigger>
|
|
|
+ <n-button type="primary" strong secondary class="px-8 ml-6" size="large" :disabled="NodeStatus === '3' || NodeStatus === '1'" @click="reportModalClick">上报</n-button>
|
|
|
+ </template>
|
|
|
+ <span>{{btn_report?.textInfo}}</span>
|
|
|
+ </n-popover>
|
|
|
+ <n-popover trigger="hover" :disabled="!bubbleVal || !btn_abolish?.textInfo" v-if="btn_abolish && NodeStatus === '3'">
|
|
|
+ <template #trigger>
|
|
|
+ <n-button type="primary" strong secondary class="px-8 ml-6" size="large" @click="abolishOneClick">撤回上报流程</n-button>
|
|
|
+ </template>
|
|
|
+ <span>{{btn_abolish?.textInfo}}</span>
|
|
|
+ </n-popover>
|
|
|
+ </template>
|
|
|
+ <n-button type="primary" strong secondary class="px-8 ml-6" size="large" @click="isDrawer = false">关闭填报页面</n-button>
|
|
|
+ </div>
|
|
|
+ </template>
|
|
|
+ </n-card>
|
|
|
+ </div>
|
|
|
+ </n-drawer>
|
|
|
+ </n-card>
|
|
|
+ <div class="bg-white data-fill-foot-box" v-if="wbsTypeTabKey === 'tree' && ListItemDatas.length > 0">
|
|
|
+ <n-popover trigger="hover" :disabled="!bubbleVal || !btn_save?.textInfo" v-if="btn_save && NodeStatus !== '3'">
|
|
|
+ <template #trigger>
|
|
|
+ <n-button type="primary" size="large" class="px-8" :disabled="NodeStatus === '3'" :loading="tableFormSaveLoading" @click="tableFormSaveClick">保存</n-button>
|
|
|
+ </template>
|
|
|
+ <span>{{btn_save?.textInfo}}</span>
|
|
|
+ </n-popover>
|
|
|
+ <n-popover trigger="hover" :disabled="!bubbleVal || !btn_preview?.textInfo" v-if="btn_preview">
|
|
|
+ <template #trigger>
|
|
|
+ <n-button type="primary" strong secondary class="px-8 ml-6" size="large" :disabled="NodeStatus === '1'" :loading="bussPdfsLoading" @click="bussPdfsClick">预览</n-button>
|
|
|
+ </template>
|
|
|
+ <span>{{btn_preview?.textInfo}}</span>
|
|
|
+ </n-popover>
|
|
|
+ <n-popover trigger="hover" :disabled="!bubbleVal || !btn_report?.textInfo" v-if="btn_report && NodeStatus !== '3'">
|
|
|
+ <template #trigger>
|
|
|
+ <n-button type="primary" strong secondary class="px-8 ml-6" size="large" :disabled="NodeStatus === '3' || NodeStatus === '1'" @click="reportModalClick">上报</n-button>
|
|
|
+ </template>
|
|
|
+ <span>{{btn_report?.textInfo}}</span>
|
|
|
+ </n-popover>
|
|
|
+ <n-popover trigger="hover" :disabled="!bubbleVal || !btn_abolish?.textInfo" v-if="btn_abolish && NodeStatus === '3'">
|
|
|
+ <template #trigger>
|
|
|
+ <n-button type="primary" strong secondary class="px-8 ml-6" size="large" @click="abolishOneClick">撤回上报流程</n-button>
|
|
|
+ </template>
|
|
|
+ <span>{{btn_abolish?.textInfo}}</span>
|
|
|
+ </n-popover>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ <DragModal title="查看图纸" :isShow="drawingsShow" closeIcon tops="125" widths="380px" bg="bg-dark-3" @close="drawingsClose">
|
|
|
+ <div class="img-preview-box">
|
|
|
+ <ImgPreview :src="nodeDataInfo.fileUrl" isDom toolsSm/>
|
|
|
+ </div>
|
|
|
+ </DragModal>
|
|
|
+
|
|
|
+ <!--标记首件-->
|
|
|
+ <n-modal v-model:show="firstItemModal" class="hc-custom-card" title="标记首件制" preset="card" style="width: 600px;" size="huge" :bordered="false" :segmented="{content: 'soft', footer: 'soft'}">
|
|
|
+ <div class="text-center text-base font-bold">
|
|
|
+ <span>请确认将</span>
|
|
|
+ <span class="text-main">【{{nodeDataInfo.title}}】</span>
|
|
|
+ <span>{{nodeDataInfo.isFirst?'取消':''}}标记为首件</span>
|
|
|
+ </div>
|
|
|
+ <template #footer>
|
|
|
+ <div class="text-center">
|
|
|
+ <n-button class="px-4" @click="firstItemModal = false">取消</n-button>
|
|
|
+ <n-button type="primary" class="px-4 ml-6" :loading="firstItemLoading" @click="firstItemClick">确认</n-button>
|
|
|
+ </div>
|
|
|
+ </template>
|
|
|
+ </n-modal>
|
|
|
+
|
|
|
+ <!--编辑节点-->
|
|
|
+ <n-modal v-model:show="editNodeModal" class="hc-custom-card" title="编辑节点" preset="card" style="width: 600px;" :segmented="{content: 'soft', footer: 'soft'}">
|
|
|
+ <n-form ref="formEditNodeRef" :model="formEditNodeModel" :rules="formEditNodeRules" label-placement="left" label-width="auto" size="large">
|
|
|
+ <n-form-item label="节点名称" path="title">
|
|
|
+ <n-input v-model:value="formEditNodeModel.title" placeholder="请输入节点名称"/>
|
|
|
+ </n-form-item>
|
|
|
+ <n-form-item label="上级节点">
|
|
|
+ <n-input v-model:value="formEditNodeModel.parent.title" disabled/>
|
|
|
+ </n-form-item>
|
|
|
+ <n-form-item label="节点类型">
|
|
|
+ <n-select v-model:value="formEditNodeModel.type" :options="nodeTypeData" disabled/>
|
|
|
+ </n-form-item>
|
|
|
+ <n-form-item label="划分编号" path="partitionCode">
|
|
|
+ <n-input v-model:value="formEditNodeModel.partitionCode" placeholder="请输入划分编号"/>
|
|
|
+ </n-form-item>
|
|
|
+ </n-form>
|
|
|
+ <template #footer>
|
|
|
+ <div class="text-center">
|
|
|
+ <n-button class="px-4" @click="editNodeModal = false">取消</n-button>
|
|
|
+ <n-button type="primary" class="px-4 ml-6" :loading="editNodeLoading" @click="editNodeClick">确认</n-button>
|
|
|
+ </div>
|
|
|
+ </template>
|
|
|
+ </n-modal>
|
|
|
+
|
|
|
+ <!--复制节点-->
|
|
|
+ <n-modal v-model:show="copyNodeModal" title="复制节点" preset="card" class="hc-custom-card copy" :class="copyNodeTabKey==='1'?'one':'many'" :segmented="{content: 'soft', footer: 'soft'}">
|
|
|
+ <template #header-extra>
|
|
|
+ <HcTabs :datas="copyNodeTab" :keys="copyNodeTabKey" @change="copyNodeTabChange"/>
|
|
|
+ </template>
|
|
|
+ <n-form ref="formCopyNodeModelRef" :model="formCopyNodeModel" :rules="formCopyNodeModelRules" label-placement="left" label-width="auto" size="large" v-if="copyNodeTabKey !== '3'">
|
|
|
+ <n-form-item label="节点名称" path="title">
|
|
|
+ <n-input v-model:value="formCopyNodeModel.title" placeholder="请输入节点名称"/>
|
|
|
+ </n-form-item>
|
|
|
+ </n-form>
|
|
|
+ <template #footer v-if="copyNodeTabKey === '1'">
|
|
|
+ <div class="text-center">
|
|
|
+ <n-button class="px-4" @click="copyNodeModal = false">取消</n-button>
|
|
|
+ <n-button type="primary" class="px-4 ml-6" :loading="copyNodeLoading" @click="copyNodeClick">确认</n-button>
|
|
|
+ </div>
|
|
|
+ </template>
|
|
|
+ <div class="copy-node-many-box" v-if="copyNodeTabKey === '2'">
|
|
|
+ <div class="copy-node-many-tree">
|
|
|
+ <HcTree type="data-fill-query" :params="treeParams" :props="wbsElTreeProps" lazy idPrefix="tree-node-copy-" :isAutoRes="false" :autoExpandKeys="treeExpandKeys" @node-click="copyNodeElTreeClick"/>
|
|
|
+ </div>
|
|
|
+ <div class="copy-node-many-table">
|
|
|
+ <div class="copy-node-many-table-data">
|
|
|
+ <el-table :data="copyNodeTable" border stripe>
|
|
|
+ <el-table-column prop="title" label="复制到的位置"/>
|
|
|
+ <el-table-column prop="nodeName" label="节点名称">
|
|
|
+ <template #default="{row}">
|
|
|
+ <n-form ref="copyNodeTableRef" :model="row" :rules="copyNodeTableRules">
|
|
|
+ <n-form-item path="nodeName">
|
|
|
+ <n-input v-model:value="row.nodeName"/>
|
|
|
+ </n-form-item>
|
|
|
+ </n-form>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column prop="action" label="操作" width="120" align="center">
|
|
|
+ <template #default="{_,$index}">
|
|
|
+ <n-button type="primary" color="#e54d42" size="small" secondary @click="copyNodeTableDel($index)">删除</n-button>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ </el-table>
|
|
|
+ </div>
|
|
|
+ <div class="copy-node-many-foot-center">
|
|
|
+ <n-button class="px-4" @click="copyNodeModal = false">取消</n-button>
|
|
|
+ <n-button type="primary" class="px-4 ml-6" :loading="copyNodeLoading" @click="copyNodeClick">确认</n-button>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ <div class="copy-node-many-box" v-if="copyNodeTabKey === '3'">
|
|
|
+ <div class="copy-node-many-tree">
|
|
|
+ <HcTree type="data-fill-query" :params="treeParams" :props="wbsElTreeProps" lazy idPrefix="tree-node-copy-data-" :isAutoRes="false" :autoExpandKeys="treeExpandKeys" @node-click="copyNodeDataElTreeClick"/>
|
|
|
+ </div>
|
|
|
+ <div class="copy-node-many-table">
|
|
|
+ <div class="copy-node-many-table-data">
|
|
|
+ <el-table :data="copyNodeDataTable" border stripe>
|
|
|
+ <el-table-column prop="nodeName" label="复制到的位置"/>
|
|
|
+ <el-table-column prop="action" label="操作" width="120" align="center">
|
|
|
+ <template #default="{_,$index}">
|
|
|
+ <n-button type="primary" color="#e54d42" size="small" secondary @click="copyNodeDataTableDel($index)">删除</n-button>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ </el-table>
|
|
|
+ </div>
|
|
|
+ <div class="copy-node-many-foot-center">
|
|
|
+ <n-button class="px-4" @click="copyNodeModal = false">取消</n-button>
|
|
|
+ <n-button type="primary" class="px-4 ml-6" :loading="copyNodeDataLoading" @click="copyNodeDataClick">确认</n-button>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ </n-modal>
|
|
|
+
|
|
|
+ <!--新增子节点-->
|
|
|
+ <n-modal v-model:show="addNodeModal" class="hc-custom-card" title="新增子节点" preset="card" style="width: 720px;" :segmented="{content: 'soft', footer: 'soft'}">
|
|
|
+ <HcTreeNode :projectId="projectId" :nodeId="addTreeNodeId" :oldId="addTreeNodeOldId" @check-change="addTreeNodeCheckChange"/>
|
|
|
+ <template #footer>
|
|
|
+ <div class="hc-add-node-modal-foot-box">
|
|
|
+ <div class="left-box">
|
|
|
+ <div class="font-bold mr-4">选中方式:</div>
|
|
|
+ <el-radio-group v-model="addTreeNodeType">
|
|
|
+ <el-radio label="1" border>当前及子节点</el-radio>
|
|
|
+ <el-radio label="2" border>仅当前节点</el-radio>
|
|
|
+ </el-radio-group>
|
|
|
+ </div>
|
|
|
+ <div class="right-box">
|
|
|
+ <n-button class="px-4" @click="addNodeModal = false">取消</n-button>
|
|
|
+ <n-button type="primary" class="px-4 ml-6" :loading="addNodeLoading" @click="addNodeClick">确认</n-button>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ </template>
|
|
|
+ </n-modal>
|
|
|
+
|
|
|
+ <!--批量上报审批-->
|
|
|
+ <HcReportModal title="批量上报审批" url="informationWriteQuery/taskOne" :show="showReportModal" :projectId="projectId" :contractId="contractId"
|
|
|
+ :taskName="reportTaskName" :ids="reportIds" :addition="reportAddition" @hide="showReportModal= false" @finish="showReportFinish"/>
|
|
|
+
|
|
|
+ <!--上传图纸-->
|
|
|
+ <div class="upload-drawing" id="upload-drawing">
|
|
|
+ <n-upload :action="action" :headers="getTokenHeader()" :accept="accept" with-credentials @before-upload="beforeUpload" @finish="uploadFinish"/>
|
|
|
+ </div>
|
|
|
+
|
|
|
+ <!--调整排序-->
|
|
|
+ <n-modal v-model:show="sortNodeModal" class="hc-custom-card" title="调整排序" preset="card" style="width: 720px;" :segmented="{content: 'soft', footer: 'soft'}">
|
|
|
+ <Draggable class="sort-node-body-box list-group" ghost-class="ghost" :list="sortNodeData" item-key="id" @start="sortNodeDrag = true" @end="sortNodeDrag = false">
|
|
|
+ <template #item="{element, index}">
|
|
|
+ <div class="list-group-item">
|
|
|
+ <div class="index-box">{{index + 1}}</div>
|
|
|
+ <div class="title-box">{{element.title}}</div>
|
|
|
+ <div class="icon-box">
|
|
|
+ <i class="hcicon-wind-descending" @click="downSortClick(index)"/>
|
|
|
+ <i class="hcicon-wind-ascending" @click="upSortClick(index)"/>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ </template>
|
|
|
+ </Draggable>
|
|
|
+ <template #footer>
|
|
|
+ <div class="text-center">
|
|
|
+ <n-button class="px-4" @click="sortNodeModal = false">取消</n-button>
|
|
|
+ <n-button type="primary" class="px-4 ml-6" :loading="sortNodeLoading" @click="sortNodeClick">确认</n-button>
|
|
|
+ </div>
|
|
|
+ </template>
|
|
|
+ </n-modal>
|
|
|
+
|
|
|
+</template>
|
|
|
+
|
|
|
+<script setup>
|
|
|
+import {ref,watch,nextTick,onMounted} from "vue";
|
|
|
+import {useRoute} from 'vue-router'
|
|
|
+import router from '~src/router/index';
|
|
|
+import {useAppStore} from "~src/store/index";
|
|
|
+import {HcIcon} from "~src/plugins/renderele";
|
|
|
+import HcTabs from "~com/plugins/naive/HcTabs.vue"
|
|
|
+import HcTree from "~com/plugins/element/HcTree.vue"
|
|
|
+import BtnTab from "~com/btnTab/index.vue"
|
|
|
+import ListItem from "~com/data-fill/ListItem.vue"
|
|
|
+import NodeTree from "~com/data-fill/nodeTree/index.vue"
|
|
|
+import DragModal from "~com/dragModal/index.vue"
|
|
|
+import ImgPreview from "~com/imgPreview/index.vue"
|
|
|
+import HcReportModal from "~com/reportModal/index.vue"
|
|
|
+import HcTreeNode from "./components/HcTreeNode.vue"
|
|
|
+import wbsApi from "~api/data-fill/wbs"
|
|
|
+import {deepClone} from "~src/utils/lib/util";
|
|
|
+import {getTokenHeader} from '~src/api/request/header';
|
|
|
+import {isArray,isObjNull} from "~src/utils/lib/isApp";
|
|
|
+import {setStore,getStore} from "~src/utils/lib/storage";
|
|
|
+import Draggable from "vuedraggable";
|
|
|
+
|
|
|
+//变量
|
|
|
+const useRoutes = useRoute()
|
|
|
+const useAppState = useAppStore()
|
|
|
+const projectId = ref(useAppState.getProjectId);
|
|
|
+const contractId = ref(useAppState.getContractId);
|
|
|
+const projectInfo = ref(useAppState.getProjectInfo);
|
|
|
+const contractInfo = ref(useAppState.getContractInfo);
|
|
|
+
|
|
|
+//路由参数
|
|
|
+const routerQuery = useRoutes?.query;
|
|
|
+const MenuBarKey = routerQuery?.MenuBarKey || '';
|
|
|
+const typeName = routerQuery?.type || 'map'
|
|
|
+
|
|
|
+const TreeAutoExpandKeys = ref(getStore({name: 'wbsTreeExpandKeys'}) || [])
|
|
|
+
|
|
|
+//按钮气泡开关
|
|
|
+const bubbleVal = ref(useAppState.getBubble);
|
|
|
+
|
|
|
+//监听
|
|
|
+watch(() => [
|
|
|
+ useAppState.getProjectId,
|
|
|
+ useAppState.getContractId,
|
|
|
+ useAppState.getProjectInfo,
|
|
|
+ useAppState.getContractInfo,
|
|
|
+ useAppState.getBubble,
|
|
|
+], ([UserProjectId, UserContractId, UserProjectInfo,UserContractInfo,Bubble]) => {
|
|
|
+ //项目合同数据
|
|
|
+ projectId.value = UserProjectId
|
|
|
+ contractId.value = UserContractId
|
|
|
+ projectInfo.value = UserProjectInfo
|
|
|
+ contractInfo.value = UserContractInfo
|
|
|
+ //按钮气泡开关
|
|
|
+ bubbleVal.value = Bubble
|
|
|
+ setContractType(UserContractInfo?.contractType)
|
|
|
+})
|
|
|
+//获取气泡数据
|
|
|
+const getButtonsVal = (value) => {
|
|
|
+ return useAppState.getButtonsVal(value)
|
|
|
+}
|
|
|
+//气泡数据
|
|
|
+const btn_drawings = ref(getButtonsVal('wbs_views_drawings')) //查看图纸
|
|
|
+const btn_save = ref(getButtonsVal('wbs_save')) //保存
|
|
|
+const btn_preview = ref(getButtonsVal('wbs_preview')) //预览
|
|
|
+const btn_report = ref(getButtonsVal('wbs_report')) //上报
|
|
|
+const btn_abolish = ref(getButtonsVal('wbs_abolish')) //撤回上报流程
|
|
|
+
|
|
|
+//树菜单
|
|
|
+const tree_menu_edit = ref(getButtonsVal('wbs_tree_edit')) //编辑节点
|
|
|
+const tree_menu_mark = ref(getButtonsVal('wbs_tree_mark')) //标记为首件
|
|
|
+const tree_menu_copy = ref(getButtonsVal('wbs_tree_copy')) //复制节点
|
|
|
+const tree_menu_add = ref(getButtonsVal('wbs_tree_add')) //新增节点
|
|
|
+const tree_menu_up = ref(getButtonsVal('wbs_tree_upload')) //上传图纸
|
|
|
+const tree_menu_del = ref(getButtonsVal('wbs_tree_del')) //删除节点
|
|
|
+const tree_menu_sort = ref(getButtonsVal('wbs_tree_sort')) //调整排序
|
|
|
+
|
|
|
+
|
|
|
+//上传文件的
|
|
|
+const action = ref("/api/blade-resource/oss/endpoint/put-file")
|
|
|
+const accept = ref("image/png,image/jpg,image/jpeg")
|
|
|
+
|
|
|
+//身份按钮切换数据
|
|
|
+const authBtnTabKey = ref('1')
|
|
|
+const authBtnTabData = [
|
|
|
+ {key: "1", label: "施工质检", icon: 'hcicon-a-Frame1'},
|
|
|
+ {key: "2", label: "监理抽检", icon: 'hcicon-a-Frame2'}
|
|
|
+]
|
|
|
+const authBtnTabClick = (val) => {
|
|
|
+ authBtnTabKey.value = val
|
|
|
+ searchNodeAllTable()
|
|
|
+ queryNodeStatus()
|
|
|
+}
|
|
|
+
|
|
|
+const getTableDataAll = () => {
|
|
|
+ searchNodeAllTable()
|
|
|
+ queryNodeStatus()
|
|
|
+}
|
|
|
+
|
|
|
+//结构类型tab数据和相关处理
|
|
|
+const wbsTypeTabKey = ref(typeName)
|
|
|
+const wbsTypeTab = ref([
|
|
|
+ {key:'map', name: '导图结构填报'},
|
|
|
+ {key:'tree', name: '树形结构填报'}
|
|
|
+]);
|
|
|
+
|
|
|
+//渲染完成
|
|
|
+onMounted(()=> {
|
|
|
+ const contractType = contractInfo.value?.contractType
|
|
|
+ setContractType(contractType)
|
|
|
+ setElTreeMenu()
|
|
|
+ if (wbsTypeTabKey.value === 'map') {
|
|
|
+ queryMappingStructureTree()
|
|
|
+ }
|
|
|
+})
|
|
|
+
|
|
|
+const setContractType = (contractType) => {
|
|
|
+ //contractType, 1施工,2监理
|
|
|
+ if (contractType <= 0) {
|
|
|
+ authBtnTabKey.value = '1'
|
|
|
+ } else {
|
|
|
+ authBtnTabKey.value = contractType + ''
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+const wbsTypeTabChange = async (value) => {
|
|
|
+ wbsTypeTabKey.value = value;
|
|
|
+ isDrawer.value = false;
|
|
|
+ const keys = await NodeExpandKeys(true)
|
|
|
+ router.push({
|
|
|
+ path: useRoutes.path,
|
|
|
+ query: {
|
|
|
+ MenuBarKey: MenuBarKey,
|
|
|
+ type: value
|
|
|
+ }
|
|
|
+ })
|
|
|
+ nextTick(() => {
|
|
|
+ TreeAutoExpandKeys.value = keys
|
|
|
+ if (value === 'map') {
|
|
|
+ queryMappingStructureTree()
|
|
|
+ }
|
|
|
+ })
|
|
|
+}
|
|
|
+
|
|
|
+const NodeTreeAccordion = ref(true)
|
|
|
+
|
|
|
+//设置树菜单数据
|
|
|
+const ElTreeMenu = ref([])
|
|
|
+const TreeMark = ref(false)
|
|
|
+const setElTreeMenu = () => {
|
|
|
+ let newArr = [];
|
|
|
+ if (tree_menu_edit.value) {
|
|
|
+ newArr.push({icon: HcIcon('hcicon-bianji'), label: '编辑节点', key: "edit"})
|
|
|
+ }
|
|
|
+ if (tree_menu_mark.value) {
|
|
|
+ newArr.push({icon: HcIcon('cicon-star-o'), label: '标记为首件', key: "mark"})
|
|
|
+ TreeMark.value = true
|
|
|
+ }
|
|
|
+ if (tree_menu_copy.value) {
|
|
|
+ newArr.push({icon: HcIcon('cicon-file-copy-o'), label: '复制节点', key: "copy"})
|
|
|
+ }
|
|
|
+ if (tree_menu_add.value) {
|
|
|
+ newArr.push({icon: HcIcon('cicon-add-round-o'), label: '新增节点', key: "add"})
|
|
|
+ }
|
|
|
+ if (tree_menu_up.value) {
|
|
|
+ newArr.push({icon: HcIcon('hcicon-shangchuan'), label: '上传图纸', key: "upload"})
|
|
|
+ }
|
|
|
+ if (tree_menu_del.value) {
|
|
|
+ newArr.push({icon: HcIcon('cicon-delete-line-o'), label: '删除节点', key: "del"})
|
|
|
+ }
|
|
|
+ if (tree_menu_sort.value) {
|
|
|
+ newArr.push({icon: HcIcon('cicon-sort-order'), label: '调整排序', key: "sort"})
|
|
|
+ }
|
|
|
+ ElTreeMenu.value = newArr
|
|
|
+}
|
|
|
+
|
|
|
+//树的配置
|
|
|
+const HcTreeRef = ref(null)
|
|
|
+const wbsElTreeProps = {label: 'title', children: 'children', isLeaf: 'notExsitChild'}
|
|
|
+const treeParams = ref({contractId: contractId.value})
|
|
|
+
|
|
|
+//树被点击
|
|
|
+const wbsElTreeClick = ({node,data}) => {
|
|
|
+ nodeItemInfo.value = node
|
|
|
+ nodeDataInfo.value = data
|
|
|
+ searchNodeAllTable()
|
|
|
+ queryNodeStatus()
|
|
|
+}
|
|
|
+
|
|
|
+//导图结构数据
|
|
|
+const NodeTreeRef = ref(null)
|
|
|
+const NodeTreeFormat = ref({key: "primaryKeyId", label: "title", children: "children"})
|
|
|
+const NodeTreeData = ref({})
|
|
|
+
|
|
|
+//导图结构树节点查询
|
|
|
+const queryMappingStructureTree = () => {
|
|
|
+ wbsApi.queryMappingStructureTree({
|
|
|
+ contractId: contractId.value,
|
|
|
+ contractIdRelation: '',
|
|
|
+ parentId: '0',
|
|
|
+ wbsType: 1
|
|
|
+ }).then(({data}) => {
|
|
|
+ NodeTreeData.value = data?.data[0] || {}
|
|
|
+ })
|
|
|
+}
|
|
|
+
|
|
|
+//导图结构展开和收缩被点击
|
|
|
+const expandClick = ({node,data}) => {
|
|
|
+ if (!node.children) {
|
|
|
+ node.expanded = false;
|
|
|
+ }
|
|
|
+ node.isExpand = !node.isExpand;
|
|
|
+}
|
|
|
+
|
|
|
+//鼠标左键单击事件
|
|
|
+const NodeTreeClick = ({node,data}) => {
|
|
|
+ let ifChildren = !!(node.childNodes && node.childNodes.length > 0);
|
|
|
+ if (!ifChildren) {
|
|
|
+ node.loading = true
|
|
|
+ const cid = data?.contractIdRelation
|
|
|
+ const key = data?.primaryKeyId
|
|
|
+ const id = data?.id
|
|
|
+ wbsApi.queryMappingStructureTree({
|
|
|
+ contractId: contractId.value,
|
|
|
+ contractIdRelation: cid,
|
|
|
+ parentId: cid?key:id,
|
|
|
+ wbsType: 1
|
|
|
+ }).then((res) => {
|
|
|
+ const resData = res?.data?.data || []
|
|
|
+ node.childNodes = resData
|
|
|
+ nextTick(() => {
|
|
|
+ if (resData.length > 0) {
|
|
|
+ node.expanded = true;
|
|
|
+ node.isExpand = true;
|
|
|
+ } else {
|
|
|
+ node.expanded = false;
|
|
|
+ node.expanded = false;
|
|
|
+ }
|
|
|
+ node.loading = false
|
|
|
+ })
|
|
|
+ })
|
|
|
+ } else {
|
|
|
+ node.expanded = true;
|
|
|
+ node.isExpand = true;
|
|
|
+ node.loading = false
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+//双击事件
|
|
|
+const isDrawer = ref(false)
|
|
|
+const NodeTreeDblClick = ({node,data}) => {
|
|
|
+ nodeItemInfo.value = node
|
|
|
+ nodeDataInfo.value = data
|
|
|
+ isDrawer.value = true;
|
|
|
+ searchNodeAllTable()
|
|
|
+ queryNodeStatus()
|
|
|
+}
|
|
|
+
|
|
|
+//菜单被点击
|
|
|
+const firstItemModal = ref(false)
|
|
|
+const editNodeModal = ref(false)
|
|
|
+const nodeItemInfo = ref({})
|
|
|
+const nodeDataInfo = ref({})
|
|
|
+const treeExpandKeys = ref([])
|
|
|
+const ElTreeMenuClick = async ({key,node,data}) => {
|
|
|
+ nodeItemInfo.value = node
|
|
|
+ nodeDataInfo.value = data
|
|
|
+ if (key === 'mark' || key === 'cancel_mark') {
|
|
|
+ firstItemModal.value = true
|
|
|
+ } else if (key === 'edit') {
|
|
|
+ const parent = deepClone(node?.parent?.data || {})
|
|
|
+ formEditNodeModel.value = {...deepClone(data), parent: parent}
|
|
|
+ editNodeModal.value = true
|
|
|
+ } else if (key === 'copy') {
|
|
|
+ const parent = deepClone(node?.parent?.data || {})
|
|
|
+ formCopyNodeModel.value = {...deepClone(data), parent: parent}
|
|
|
+ copyNodeTable.value = []
|
|
|
+ copyNodeLoading.value = false
|
|
|
+ treeExpandKeys.value = await NodeExpandKeys()
|
|
|
+ copyNodeModal.value = true
|
|
|
+ } else if (key === 'add') {
|
|
|
+ addTreeNodeId.value = data?.id
|
|
|
+ addTreeNodeOldId.value = data?.oldId
|
|
|
+ addNodeLoading.value = false
|
|
|
+ addNodeModal.value = true
|
|
|
+ } else if (key === 'upload') {
|
|
|
+ const uploadDom = document.getElementById('upload-drawing');
|
|
|
+ let inputDom = uploadDom?.getElementsByTagName('input')[0];
|
|
|
+ inputDom.click()
|
|
|
+ } else if (key === 'del') {
|
|
|
+ delModalClick()
|
|
|
+ } else if (key === 'sort') {
|
|
|
+ let nodes = []
|
|
|
+ const childNodes = node?.parent?.childNodes || []
|
|
|
+ for (let i = 0; i < childNodes.length; i++) {
|
|
|
+ const res = childNodes[i]?.data
|
|
|
+ nodes.push({
|
|
|
+ id: res?.primaryKeyId,
|
|
|
+ title: res?.title
|
|
|
+ })
|
|
|
+ }
|
|
|
+ sortNodeData.value = nodes
|
|
|
+ sortNodeModal.value = true
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+const NodeExpandKeys = async (wbsTab = false) => {
|
|
|
+ let newKeysArr = [], node = nodeItemInfo.value || {}
|
|
|
+ await getNodeExpandKeys(node,newKeysArr,wbsTab)
|
|
|
+ const treeKeys = newKeysArr.reverse()
|
|
|
+ await setStore({name: 'wbsTreeExpandKeys', content: treeKeys})
|
|
|
+ return treeKeys
|
|
|
+}
|
|
|
+
|
|
|
+//处理自动展开的节点KEY
|
|
|
+const getNodeExpandKeys = async (node, newKeys, wbsTab = false) => {
|
|
|
+ const tabType = wbsTypeTabKey.value || ''
|
|
|
+ const primaryKeyId = node?.data?.primaryKeyId || ''
|
|
|
+ if (primaryKeyId) {
|
|
|
+ const nodes = node?.parentNodes || []
|
|
|
+ const parent = node?.parent || []
|
|
|
+ newKeys.push(primaryKeyId)
|
|
|
+ if (tabType === 'map' && !wbsTab) {
|
|
|
+ await getNodeExpandKeys(nodes, newKeys,wbsTab)
|
|
|
+ } else if (tabType === 'tree' && !wbsTab) {
|
|
|
+ await getNodeExpandKeys(parent, newKeys,wbsTab)
|
|
|
+ } else if (tabType === 'map' && wbsTab) {
|
|
|
+ await getNodeExpandKeys(parent, newKeys,wbsTab)
|
|
|
+ } else if (tabType === 'tree' && wbsTab) {
|
|
|
+ await getNodeExpandKeys(nodes, newKeys,wbsTab)
|
|
|
+ }
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+const NodeTreeMenuClick = async ({key,node,data}) => {
|
|
|
+ nodeItemInfo.value = node
|
|
|
+ nodeDataInfo.value = data
|
|
|
+ if (key === 'mark' || key === 'cancel_mark') {
|
|
|
+ firstItemModal.value = true
|
|
|
+ } else if (key === 'edit') {
|
|
|
+ const parent = deepClone(node?.parentNodes?.data || {})
|
|
|
+ formEditNodeModel.value = {...deepClone(data), parent: parent}
|
|
|
+ editNodeModal.value = true
|
|
|
+ } else if (key === 'copy') {
|
|
|
+ const parent = deepClone(node?.parentNodes?.data || {})
|
|
|
+ formCopyNodeModel.value = {...deepClone(data), parent: parent}
|
|
|
+ copyNodeTable.value = []
|
|
|
+ copyNodeLoading.value = false
|
|
|
+ treeExpandKeys.value = await NodeExpandKeys()
|
|
|
+ copyNodeModal.value = true
|
|
|
+ } else if (key === 'add') {
|
|
|
+ addTreeNodeId.value = data?.id
|
|
|
+ addTreeNodeOldId.value = data?.oldId
|
|
|
+ addNodeLoading.value = false
|
|
|
+ addNodeModal.value = true
|
|
|
+ } else if (key === 'upload') {
|
|
|
+ const uploadDom = document.getElementById('upload-drawing');
|
|
|
+ let inputDom = uploadDom?.getElementsByTagName('input')[0];
|
|
|
+ inputDom.click()
|
|
|
+ } else if (key === 'del') {
|
|
|
+ delModalClick()
|
|
|
+ } else if (key === 'sort') {
|
|
|
+ let nodes = []
|
|
|
+ const childNodes = node?.parentNodes?.childrenNodes || []
|
|
|
+ for (let i = 0; i < childNodes.length; i++) {
|
|
|
+ const res = childNodes[i]?.data
|
|
|
+ nodes.push({
|
|
|
+ id: res?.primaryKeyId,
|
|
|
+ title: res?.title
|
|
|
+ })
|
|
|
+ }
|
|
|
+ sortNodeData.value = nodes
|
|
|
+ sortNodeModal.value = true
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+//上传前
|
|
|
+const loadingReactive = ref(null)
|
|
|
+const beforeUpload = () => {
|
|
|
+ loadingReactive.value = window?.$message?.loading('上传中...', {
|
|
|
+ duration: 0
|
|
|
+ })
|
|
|
+ return true
|
|
|
+}
|
|
|
+
|
|
|
+//上传完成
|
|
|
+const uploadFinish = ({event}) => {
|
|
|
+ const res = JSON.parse(event?.target?.response);
|
|
|
+ const info = nodeDataInfo.value;
|
|
|
+ let link = res?.data?.link;
|
|
|
+ wbsApi.saveContractTreeDrawings({
|
|
|
+ fileUrl: link,
|
|
|
+ id: info['drawingsId'],
|
|
|
+ primaryKeyId: info['primaryKeyId']
|
|
|
+ }).then(({data}) => {
|
|
|
+ loadingReactive.value.destroy()
|
|
|
+ loadingReactive.value = null
|
|
|
+ if (data.code === 200) {
|
|
|
+ nodeDataInfo.value['drawingsId'] = data.data
|
|
|
+ nodeDataInfo.value['fileUrl'] = link
|
|
|
+ window?.$message?.success('上传成功')
|
|
|
+ } else {
|
|
|
+ window?.$message?.error(data.msg || '上传失败')
|
|
|
+ }
|
|
|
+ }).catch(erro => {
|
|
|
+ loadingReactive.value.destroy()
|
|
|
+ loadingReactive.value = null
|
|
|
+ window?.$message?.error('请求异常')
|
|
|
+ })
|
|
|
+}
|
|
|
+
|
|
|
+//确认标记为首件
|
|
|
+const firstItemLoading = ref(false)
|
|
|
+const firstItemClick = () => {
|
|
|
+ const info = nodeDataInfo.value;
|
|
|
+ const TabKey = wbsTypeTabKey.value;
|
|
|
+ wbsApi.wbsTreeFirstSave({
|
|
|
+ primaryKeyId: info['primaryKeyId'],
|
|
|
+ saveOrDeleted: !!info['isFirst']?1:0,
|
|
|
+ }).then(({data}) => {
|
|
|
+ if (data.code === 200) {
|
|
|
+ const isFirst = !info['isFirst'];
|
|
|
+ firstItemModal.value = false
|
|
|
+ nodeDataInfo.value['isFirst'] = isFirst
|
|
|
+ //处理菜单状态
|
|
|
+ if (TabKey === 'tree') {
|
|
|
+ HcTreeRef.value.setElTreeMenuMark(data?.data || [], isFirst)
|
|
|
+ } else {
|
|
|
+ setNodeTreeMenuMark(info['primaryKeyId'],data?.data || [], isFirst)
|
|
|
+ }
|
|
|
+ window?.$message?.success('操作成功')
|
|
|
+ } else {
|
|
|
+ window?.$message?.error(data.msg || '操作失败')
|
|
|
+ }
|
|
|
+ })
|
|
|
+}
|
|
|
+
|
|
|
+//设置树菜单的标记数据
|
|
|
+const setNodeTreeMenuMark = (KeyId,keys,isFirst) => {
|
|
|
+ const info = nodeItemInfo.value;
|
|
|
+ setNodeTreeParentNodes(info['parentNodes'],keys,isFirst)
|
|
|
+ setNodeTreeChildNodes(info['childrenNodes'],keys,isFirst)
|
|
|
+}
|
|
|
+
|
|
|
+//设置父级
|
|
|
+const setNodeTreeParentNodes = (parent,keys,isFirst) => {
|
|
|
+ if (keys.indexOf(parent['key']) !== -1) {
|
|
|
+ parent['data']['isFirst'] = isFirst
|
|
|
+ }
|
|
|
+ if (!isObjNull(parent['parentNodes'])) {
|
|
|
+ setNodeTreeParentNodes(parent['parentNodes'],keys,isFirst)
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+//设置子级
|
|
|
+const setNodeTreeChildNodes = (child,keys,isFirst) => {
|
|
|
+ if (child.length > 0) {
|
|
|
+ child.forEach(item => {
|
|
|
+ if (keys.indexOf(item['key']) !== -1) {
|
|
|
+ item['data']['isFirst'] = isFirst
|
|
|
+ }
|
|
|
+ if (item['childrenNodes'].length > 0) {
|
|
|
+ setNodeTreeChildNodes(item['childrenNodes'],keys,isFirst)
|
|
|
+ }
|
|
|
+ })
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+//编辑节点
|
|
|
+const nodeTypeData = ref([{label: "分项工程", value: 1}, {label: "分部工程", value: 2}])
|
|
|
+const editNodeLoading = ref(false)
|
|
|
+const formEditNodeRef = ref(null)
|
|
|
+const formEditNodeModel = ref({})
|
|
|
+const formEditNodeRules = {
|
|
|
+ title: {
|
|
|
+ required: true,
|
|
|
+ trigger: ["blur", "input"],
|
|
|
+ message: "请输入节点名称"
|
|
|
+ },
|
|
|
+}
|
|
|
+const editNodeClick = () => {
|
|
|
+ editNodeLoading.value = true
|
|
|
+ const {primaryKeyId,title,partitionCode} = formEditNodeModel.value
|
|
|
+ wbsApi.wbsTreeUpdateNode({
|
|
|
+ deptName: title,
|
|
|
+ pKeyId: primaryKeyId,
|
|
|
+ partitionCode: partitionCode||''
|
|
|
+ }).then(({data}) => {
|
|
|
+ editNodeLoading.value = false
|
|
|
+ if (data.code === 200) {
|
|
|
+ window?.$message?.success('修改成功')
|
|
|
+ nodeDataInfo.value['title'] = title || ''
|
|
|
+ nodeDataInfo.value['partitionCode'] = partitionCode || ''
|
|
|
+ editNodeModal.value = false
|
|
|
+ } else {
|
|
|
+ window?.$message?.error(data.msg || '修改失败')
|
|
|
+ }
|
|
|
+ }).catch(erro => {
|
|
|
+ editNodeLoading.value = false
|
|
|
+ window?.$message?.error('请求异常')
|
|
|
+ })
|
|
|
+}
|
|
|
+
|
|
|
+//复制节点
|
|
|
+const copyNodeModal = ref(false)
|
|
|
+
|
|
|
+//复制节点类型tab数据和相关处理
|
|
|
+const copyNodeTabKey = ref('2')
|
|
|
+const copyNodeTab = ref([
|
|
|
+ {key:'1', name: '单份复制'},
|
|
|
+ {key:'2', name: '多份复制'},
|
|
|
+ {key:'3', name: '复制数据'},
|
|
|
+]);
|
|
|
+const copyNodeTabChange = (value) => {
|
|
|
+ copyNodeTabKey.value = value;
|
|
|
+ copyNodeLoading.value = false
|
|
|
+}
|
|
|
+const copyNodeLoading = ref(false)
|
|
|
+const formCopyNodeModel = ref({})
|
|
|
+const copyNodeTable = ref([])
|
|
|
+
|
|
|
+//树被点击
|
|
|
+const copyNodeElTreeClick = ({data}) => {
|
|
|
+ const {title} = formCopyNodeModel.value;
|
|
|
+ if (!data?.notExsitChild) {
|
|
|
+ copyNodeTable.value.push({
|
|
|
+ title: data?.title || '',
|
|
|
+ nodeName: title || '',
|
|
|
+ primaryKeyId: data?.primaryKeyId || ''
|
|
|
+ })
|
|
|
+ }
|
|
|
+}
|
|
|
+//树被点击
|
|
|
+const copyNodeDataTable = ref([])
|
|
|
+const copyNodeDataElTreeClick = ({data}) => {
|
|
|
+ if (data?.notExsitChild) {
|
|
|
+ copyNodeDataTable.value.push({
|
|
|
+ nodeName: data?.title || '',
|
|
|
+ primaryKeyId: data?.primaryKeyId || ''
|
|
|
+ })
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+const formCopyNodeModelRef = ref(null)
|
|
|
+const formCopyNodeModelRules = {
|
|
|
+ title: {
|
|
|
+ required: true,
|
|
|
+ trigger: ["blur", "input"],
|
|
|
+ message: "请输入节点名称"
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+//删除选中的节点
|
|
|
+const copyNodeTableDel = (index) => {
|
|
|
+ copyNodeTable.value.splice(index,1)
|
|
|
+}
|
|
|
+const copyNodeDataTableDel = (index) => {
|
|
|
+ copyNodeDataTable.value.splice(index,1)
|
|
|
+}
|
|
|
+
|
|
|
+const copyNodeTableRef = ref(null)
|
|
|
+const copyNodeTableRules = {
|
|
|
+ nodeName: {
|
|
|
+ required: true,
|
|
|
+ trigger: ["blur", "input"],
|
|
|
+ message: "请输入节点名称"
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+const copyNodeClick = async () => {
|
|
|
+ const type = copyNodeTabKey.value
|
|
|
+ const form = formCopyNodeModel.value
|
|
|
+ const table = copyNodeTable.value
|
|
|
+ //效验数据
|
|
|
+ let validate = false
|
|
|
+ if (type === '1') {
|
|
|
+ const errors = await formCopyNodeModelRef.value?.validate()
|
|
|
+ validate = !errors
|
|
|
+ } else if (type === '2') {
|
|
|
+ if (table.length > 0) {
|
|
|
+ const errors = await copyNodeTableRef.value?.validate()
|
|
|
+ validate = !errors
|
|
|
+ } else {
|
|
|
+ validate = false
|
|
|
+ window?.$message?.warning('请先在左侧选择要复制到的节点')
|
|
|
+ }
|
|
|
+ }
|
|
|
+ //发起请求
|
|
|
+ if (validate) {
|
|
|
+ copyNodeLoading.value = true
|
|
|
+ const {data} = await wbsApi.copyContractTreeNode({
|
|
|
+ copyType: type,
|
|
|
+ needCopyNodeName: form?.title || '',
|
|
|
+ needCopyPrimaryKeyId: form?.primaryKeyId || '',
|
|
|
+ parentPrimaryKeyId: form?.parent?.primaryKeyId || '',
|
|
|
+ copyBatchToPaths: table
|
|
|
+ })
|
|
|
+ //判断状态
|
|
|
+ if (data.code === 200) {
|
|
|
+ window?.$message?.success('复制成功')
|
|
|
+ copyNodeLoading.value = false
|
|
|
+ copyNodeModal.value = false
|
|
|
+ await NodeExpandKeys()
|
|
|
+ window?.location?.reload() //刷新页面
|
|
|
+ } else {
|
|
|
+ copyNodeLoading.value = false
|
|
|
+ window?.$message?.error(data.msg || '复制失败')
|
|
|
+ }
|
|
|
+ } else {
|
|
|
+ window?.$message?.warning('请先检查相关表单是否正确填写或节点是否选择')
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+//复制数据
|
|
|
+const copyNodeDataLoading = ref(false)
|
|
|
+const copyNodeDataClick = async () => {
|
|
|
+ const form = formCopyNodeModel.value
|
|
|
+ const table = copyNodeDataTable.value
|
|
|
+ if (table.length > 0) {
|
|
|
+ copyNodeDataLoading.value = true
|
|
|
+ const {data} = await wbsApi.copyContractNodeSubmitBusinessData({
|
|
|
+ needCopyPrimaryKeyId: form?.primaryKeyId || '',
|
|
|
+ copyBatchToPaths: table
|
|
|
+ })
|
|
|
+ //判断状态
|
|
|
+ if (data && data.code === 200) {
|
|
|
+ window?.$message?.success('复制成功')
|
|
|
+ copyNodeDataLoading.value = false
|
|
|
+ copyNodeModal.value = false
|
|
|
+ await NodeExpandKeys()
|
|
|
+ window?.location?.reload() //刷新页面
|
|
|
+ } else {
|
|
|
+ copyNodeDataLoading.value = false
|
|
|
+ window?.$message?.error(data.msg || '复制失败')
|
|
|
+ }
|
|
|
+ } else {
|
|
|
+ window?.$message?.warning('请先选择节点')
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+
|
|
|
+//新增节点
|
|
|
+const addNodeModal = ref(false)
|
|
|
+const addTreeNodeId = ref('')
|
|
|
+const addTreeNodeOldId = ref('')
|
|
|
+const addTreeNodeType = ref('1')
|
|
|
+
|
|
|
+//选中的节点
|
|
|
+const allSelectedList = ref([])
|
|
|
+const halfSelectedList = ref([])
|
|
|
+const addTreeNodeCheckChange = (nodes) => {
|
|
|
+ let NodesArr = [], halfArr = []
|
|
|
+ //全选数据
|
|
|
+ const keys = nodes.checkedNodes || []
|
|
|
+ for (let i = 0; i < keys.length; i++) {
|
|
|
+ NodesArr.push({
|
|
|
+ nodeName: keys[i].title,
|
|
|
+ primaryKeyId: keys[i].primaryKeyId
|
|
|
+ })
|
|
|
+ }
|
|
|
+ allSelectedList.value = NodesArr
|
|
|
+ //半选数据
|
|
|
+ const halfNodes = nodes.halfCheckedNodes || []
|
|
|
+ for (let i = 0; i < halfNodes.length; i++) {
|
|
|
+ halfArr.push({
|
|
|
+ nodeName: halfNodes[i].title,
|
|
|
+ primaryKeyId: halfNodes[i].primaryKeyId
|
|
|
+ })
|
|
|
+ }
|
|
|
+ halfSelectedList.value = halfArr
|
|
|
+}
|
|
|
+
|
|
|
+//新增节点
|
|
|
+const addNodeLoading = ref(false)
|
|
|
+const addNodeClick = async () => {
|
|
|
+ const keys = allSelectedList.value || []
|
|
|
+ if (keys.length <= 0) {
|
|
|
+ window?.$message?.warning('请先选择节点')
|
|
|
+ } else {
|
|
|
+ //发起请求
|
|
|
+ addNodeLoading.value = true
|
|
|
+ const {data} = await wbsApi.saveContractTreeNode({
|
|
|
+ projectId: projectId.value,
|
|
|
+ contractId: contractId.value,
|
|
|
+ saveType: addTreeNodeType.value,
|
|
|
+ allSelectedList: allSelectedList.value,
|
|
|
+ halfSelectedList: halfSelectedList.value,
|
|
|
+ currentNodePrimaryKeyId: nodeDataInfo.value?.primaryKeyId
|
|
|
+ })
|
|
|
+ //判断状态
|
|
|
+ if (data.code === 200) {
|
|
|
+ window?.$message?.success('新增成功')
|
|
|
+ await NodeExpandKeys()
|
|
|
+ addNodeLoading.value = false
|
|
|
+ addNodeModal.value = false
|
|
|
+ window?.location?.reload() //刷新页面
|
|
|
+ } else {
|
|
|
+ addNodeLoading.value = false
|
|
|
+ window?.$message?.error(data.msg || '新增失败')
|
|
|
+ }
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+//删除确认弹窗
|
|
|
+const delModalClick = () => {
|
|
|
+ window?.$dialog?.error({
|
|
|
+ title: "确认此操作?",
|
|
|
+ content: "请谨慎考虑后,确认是否需要删除",
|
|
|
+ positiveText: "确认删除",
|
|
|
+ negativeText: "取消",
|
|
|
+ onPositiveClick: () => {
|
|
|
+ const info = nodeDataInfo.value;
|
|
|
+ const TabKey = wbsTypeTabKey.value;
|
|
|
+ wbsApi.removeContractTreeNode({
|
|
|
+ ids: info['primaryKeyId']
|
|
|
+ }).then(({data}) => {
|
|
|
+ if (data.code === 200) {
|
|
|
+ window?.$message?.success('删除成功')
|
|
|
+ //处理菜单状态
|
|
|
+ if (TabKey === 'tree') {
|
|
|
+ HcTreeRef.value.removeElTreeNode(info['primaryKeyId'])
|
|
|
+ } else {
|
|
|
+ removeNodeTreeNode()
|
|
|
+ }
|
|
|
+ } else {
|
|
|
+ window?.$message?.error(data.msg || '删除失败')
|
|
|
+ }
|
|
|
+ }).catch(erro => {
|
|
|
+ window?.$message?.error('请求异常')
|
|
|
+ })
|
|
|
+ }
|
|
|
+ });
|
|
|
+}
|
|
|
+const removeNodeTreeNode = () => {
|
|
|
+ const info = nodeItemInfo.value;
|
|
|
+ const parent = info['parentNodes']
|
|
|
+ const childNodes = parent['childNodes'] || []
|
|
|
+ const childrenNodes = parent['childrenNodes'] || []
|
|
|
+ //删除
|
|
|
+ for (let i = 0; i < childNodes.length; i++) {
|
|
|
+ if (info['key'] === childNodes[i]['primaryKeyId']) {
|
|
|
+ childNodes.splice(i, 1);
|
|
|
+ }
|
|
|
+ }
|
|
|
+ //删除
|
|
|
+ for (let i = 0; i < childrenNodes.length; i++) {
|
|
|
+ if (info['key'] === childrenNodes[i]['key']) {
|
|
|
+ childrenNodes.splice(i, 1);
|
|
|
+ }
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+//调整排序
|
|
|
+const sortNodeModal = ref(false)
|
|
|
+const sortNodeLoading = ref(false)
|
|
|
+const sortNodeData = ref([])
|
|
|
+const sortNodeDrag = ref(false)
|
|
|
+//向下
|
|
|
+const downSortClick = (index) => {
|
|
|
+ const indexs = index + 1
|
|
|
+ const data = sortNodeData.value || []
|
|
|
+ if(indexs !== data.length) {
|
|
|
+ const tmp = data.splice(indexs,1);
|
|
|
+ sortNodeData.value.splice(index,0,tmp[0]);
|
|
|
+ } else {
|
|
|
+ window?.$message?.warning('已经处于置底,无法下移')
|
|
|
+ }
|
|
|
+}
|
|
|
+//向上
|
|
|
+const upSortClick = (index) => {
|
|
|
+ const data = sortNodeData.value || []
|
|
|
+ if(index !== 0) {
|
|
|
+ const tmp = data.splice(index - 1,1);
|
|
|
+ sortNodeData.value.splice(index,0,tmp[0]);
|
|
|
+ } else {
|
|
|
+ window?.$message?.warning('已经处于置顶,无法上移')
|
|
|
+ }
|
|
|
+}
|
|
|
+//确认排序
|
|
|
+const sortNodeClick = async () => {
|
|
|
+ const sortList = [];
|
|
|
+ const nodes = sortNodeData.value || []
|
|
|
+ nodes.forEach(item => {
|
|
|
+ sortList.push(item?.id)
|
|
|
+ })
|
|
|
+ //发起请求
|
|
|
+ sortNodeLoading.value = true
|
|
|
+ const { data } = await wbsApi.diySortTreeNode({sortList})
|
|
|
+ //判断状态
|
|
|
+ if (data.code === 200) {
|
|
|
+ window?.$message?.success('保存成功')
|
|
|
+ await NodeExpandKeys()
|
|
|
+ sortNodeLoading.value = false
|
|
|
+ sortNodeModal.value = false
|
|
|
+ window?.location?.reload() //刷新页面
|
|
|
+ } else {
|
|
|
+ sortNodeLoading.value = false
|
|
|
+ window?.$message?.error(data.msg || '保存失败')
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+
|
|
|
+//查看图纸
|
|
|
+const drawingsShow = ref(false);
|
|
|
+const viewsDrawings = () => {
|
|
|
+ drawingsShow.value = true
|
|
|
+}
|
|
|
+const drawingsClose = (res) => {
|
|
|
+ drawingsShow.value = res
|
|
|
+}
|
|
|
+const viewsDrawingsTip = () => {
|
|
|
+ const {primaryKeyId,fileUrl} = nodeDataInfo.value
|
|
|
+ if (!primaryKeyId) {
|
|
|
+ window?.$message?.warning('请先选择树节点')
|
|
|
+ } else if (!fileUrl) {
|
|
|
+ window?.$message?.warning('该节点暂未上传图纸')
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+//数据列表
|
|
|
+const ListItemDatas = ref([]);
|
|
|
+
|
|
|
+//获取数据列表
|
|
|
+const searchNodeAllTable = () => {
|
|
|
+ const info = nodeDataInfo.value;
|
|
|
+ const cid = info?.contractIdRelation || ''
|
|
|
+ const key = info?.primaryKeyId || ''
|
|
|
+ const id = info?.id || ''
|
|
|
+ wbsApi.searchNodeAllTable({
|
|
|
+ primaryKeyId: cid?id:key,
|
|
|
+ type: authBtnTabKey.value,
|
|
|
+ projectId: projectId.value,
|
|
|
+ contractId: contractId.value
|
|
|
+ }).then(({data}) => {
|
|
|
+ if (data.code === 200) {
|
|
|
+ let tableData = isArray(data?.data)?data['data']:[]
|
|
|
+ if (tableData.length > 0) {
|
|
|
+ tableData.forEach(item => {
|
|
|
+ item.name = item.deptName
|
|
|
+ })
|
|
|
+ }
|
|
|
+ ListItemDatas.value = tableData
|
|
|
+ } else {
|
|
|
+ ListItemDatas.value = []
|
|
|
+ }
|
|
|
+ }).catch(() => {
|
|
|
+ ListItemDatas.value = []
|
|
|
+ })
|
|
|
+}
|
|
|
+
|
|
|
+//批量上报
|
|
|
+const reportIds = ref('')
|
|
|
+const reportTaskName = ref('')
|
|
|
+const reportAddition = ref({})
|
|
|
+const showReportModal = ref(false)
|
|
|
+const reportModalClick = () => {
|
|
|
+ const info = nodeDataInfo.value;
|
|
|
+ const rows = ListItemDatas.value;
|
|
|
+ reportIds.value = info?.primaryKeyId || ''
|
|
|
+ if (rows.length > 0) {
|
|
|
+ reportTaskName.value = rows.length > 1?`${rows[0].name}等${rows.length}个文件`:rows[0].name
|
|
|
+ reportAddition.value = {
|
|
|
+ classify: authBtnTabKey.value
|
|
|
+ }
|
|
|
+ showReportModal.value = true
|
|
|
+ } else {
|
|
|
+ window.$message?.warning('暂无相关数据')
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+//上报完成
|
|
|
+const showReportFinish = () => {
|
|
|
+ showReportModal.value = false
|
|
|
+ searchNodeAllTable()
|
|
|
+ queryNodeStatus()
|
|
|
+}
|
|
|
+
|
|
|
+//被展开
|
|
|
+const ListItemOffsetTop = (offsetTop) => {
|
|
|
+ if (offsetTop > 0) {
|
|
|
+ const type = wbsTypeTabKey.value || 'map'
|
|
|
+ setTimeout(() => {
|
|
|
+ if (type === 'map') {
|
|
|
+ document.getElementById('hc-drawer-list-item').scrollTop = offsetTop
|
|
|
+ } else if (type === 'tree') {
|
|
|
+ document.getElementById('hc-card-list-item').scrollTop = offsetTop
|
|
|
+ }
|
|
|
+ }, 200)
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+//查询状态
|
|
|
+const NodeStatus = ref('1')
|
|
|
+const queryNodeStatus = () => {
|
|
|
+ const info = nodeDataInfo.value;
|
|
|
+ wbsApi.queryNodeStatus({
|
|
|
+ primaryKeyId: info?.primaryKeyId || '',
|
|
|
+ classify: authBtnTabKey.value
|
|
|
+ }).then(({data}) => {
|
|
|
+ //1 未填报,2待上报,3已上报
|
|
|
+ if (data.code === 200) {
|
|
|
+ NodeStatus.value = data?.data || '1'
|
|
|
+ }
|
|
|
+ })
|
|
|
+}
|
|
|
+
|
|
|
+//撤回上报流程
|
|
|
+const abolishOneClick = () => {
|
|
|
+ window?.$dialog?.warning({
|
|
|
+ title: "确认操作",
|
|
|
+ content: "请谨慎操作",
|
|
|
+ positiveText: "确定撤回",
|
|
|
+ negativeText: "取消",
|
|
|
+ onPositiveClick: () => {
|
|
|
+ abolishOneSave()
|
|
|
+ }
|
|
|
+ });
|
|
|
+}
|
|
|
+
|
|
|
+//撤回请求
|
|
|
+const abolishOneSave = () => {
|
|
|
+ const info = nodeDataInfo.value;
|
|
|
+ wbsApi.abolishOne({
|
|
|
+ primaryKeyId: info?.primaryKeyId || '',
|
|
|
+ classify: authBtnTabKey.value
|
|
|
+ }).then(({data}) => {
|
|
|
+ if (data.code === 200) {
|
|
|
+ window.$message?.success('撤回成功')
|
|
|
+ searchNodeAllTable()
|
|
|
+ queryNodeStatus()
|
|
|
+ } else {
|
|
|
+ window.$message?.error(data.msg || '撤回失败')
|
|
|
+ searchNodeAllTable()
|
|
|
+ queryNodeStatus()
|
|
|
+ }
|
|
|
+ })
|
|
|
+}
|
|
|
+
|
|
|
+//表单变量
|
|
|
+const ListItemRef = ref(null)
|
|
|
+const ListItemsRef = ref(null)
|
|
|
+
|
|
|
+//保存
|
|
|
+const tableFormSaveLoading = ref(false)
|
|
|
+const tableFormSaveClick = () => {
|
|
|
+ let FormData = [];
|
|
|
+ if (isDrawer.value) {
|
|
|
+ FormData = ListItemsRef.value.getFormData()
|
|
|
+ } else {
|
|
|
+ FormData = ListItemRef.value.getFormData()
|
|
|
+ }
|
|
|
+ console.log(FormData)
|
|
|
+ tableFormSaveLoading.value = true
|
|
|
+ wbsApi.saveExcelBussData({
|
|
|
+ dataInfo: {orderList: FormData}
|
|
|
+ }).then(({data}) => {
|
|
|
+ if(data.code === 200) {
|
|
|
+ window?.$message?.success('保存成功')
|
|
|
+ bussPdfsClick()
|
|
|
+ searchNodeAllTable()
|
|
|
+ queryNodeStatus()
|
|
|
+ } else {
|
|
|
+ window?.$message?.warning(data.msg || '保存失败')
|
|
|
+ }
|
|
|
+ }).catch(() => {
|
|
|
+ tableFormSaveLoading.value = false
|
|
|
+ })
|
|
|
+}
|
|
|
+
|
|
|
+//多表预览
|
|
|
+const bussPdfsLoading = ref(false)
|
|
|
+const bussPdfsClick = () => {
|
|
|
+ const info = nodeDataInfo.value;
|
|
|
+ bussPdfsLoading.value = true
|
|
|
+ wbsApi.getBussPdfs({
|
|
|
+ nodeId: info?.primaryKeyId || '',
|
|
|
+ classify: authBtnTabKey.value,
|
|
|
+ projectId: projectId.value,
|
|
|
+ contractId: contractId.value
|
|
|
+ }).then(({data}) => {
|
|
|
+ tableFormSaveLoading.value = false
|
|
|
+ bussPdfsLoading.value = false
|
|
|
+ if(data.code === 200 && data?.data) {
|
|
|
+ window.open(data?.data,'_blank')
|
|
|
+ } else {
|
|
|
+ window.$message?.warning('暂无PDF')
|
|
|
+ }
|
|
|
+ }).catch(() => {
|
|
|
+ tableFormSaveLoading.value = false
|
|
|
+ bussPdfsLoading.value = false
|
|
|
+ })
|
|
|
+}
|
|
|
+
|
|
|
+
|
|
|
+//左右拖动,改变树形结构宽度
|
|
|
+const leftWidth = ref(382);
|
|
|
+const onmousedown = () => {
|
|
|
+ document.onmousemove = (ve) => {
|
|
|
+ let diffVal = ve.clientX + 2;
|
|
|
+ if(diffVal >= 310 && diffVal <= 900) {
|
|
|
+ leftWidth.value = diffVal;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ document.onmouseup = () => {
|
|
|
+ document.onmousemove = null;
|
|
|
+ document.onmouseup = null;
|
|
|
+ }
|
|
|
+}
|
|
|
+</script>
|
|
|
+
|
|
|
+<style lang="scss" scoped>
|
|
|
+@import "../../styles/data-fill/wbs.scss";
|
|
|
+.hc-add-node-modal-foot-box {
|
|
|
+ position: relative;
|
|
|
+ display: flex;
|
|
|
+ align-items: center;
|
|
|
+ .left-box {
|
|
|
+ position: relative;
|
|
|
+ flex: 1;
|
|
|
+ display: flex;
|
|
|
+ align-items: center;
|
|
|
+ }
|
|
|
+ .right-box {
|
|
|
+ position: relative;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+html.theme-dark {
|
|
|
+ .bg-svg-xml {
|
|
|
+ background-color: initial;
|
|
|
+ background-image: initial;
|
|
|
+ }
|
|
|
+ .hc-layout-box .hc-layout-content-box .hc-card-max-h-box.node-tree .hc-tree-foot-tip-box {
|
|
|
+ border-top: 1px solid #303030;
|
|
|
+ }
|
|
|
+}
|
|
|
+</style>
|
|
|
+
|
|
|
+<style lang="scss">
|
|
|
+.data-fill-wbs-content {
|
|
|
+ position: relative;
|
|
|
+ height: 100%;
|
|
|
+ .n-drawer-container {
|
|
|
+ margin: -20px -24px;
|
|
|
+ }
|
|
|
+ .n-drawer.n-drawer--top-placement {
|
|
|
+ height: auto !important;
|
|
|
+ background-color: initial;
|
|
|
+ pointer-events: none;
|
|
|
+ bottom: 0;
|
|
|
+ }
|
|
|
+ .drawer-data-fill-content-box {
|
|
|
+ position: relative;
|
|
|
+ height: 100%;
|
|
|
+ padding: 24px;
|
|
|
+ .n-card {
|
|
|
+ pointer-events: auto;
|
|
|
+ height: 100%;
|
|
|
+ overflow: auto;
|
|
|
+ }
|
|
|
+ .data-fill-content {
|
|
|
+ position: relative;
|
|
|
+ height: 100%;
|
|
|
+ overflow-y: auto;
|
|
|
+ scroll-behavior: smooth;
|
|
|
+ .data-fill-list-box .data-fill-list-item-content {
|
|
|
+ height: calc(100vh - 470px);
|
|
|
+ .data-fill-table-form-box {
|
|
|
+ height: 100%;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ .data-fill-foot {
|
|
|
+ position: relative;
|
|
|
+ text-align: center;
|
|
|
+ }
|
|
|
+ }
|
|
|
+}
|
|
|
+.n-card.hc-card-overflow-box .n-card__content {
|
|
|
+ padding: 24px;
|
|
|
+}
|
|
|
+.n-card.hc-custom-card > .n-card-header {
|
|
|
+ padding: 15px 24px;
|
|
|
+}
|
|
|
+.n-card.hc-custom-card.copy {
|
|
|
+ width: 1200px;
|
|
|
+ max-height: 90vh;
|
|
|
+ overflow: auto;
|
|
|
+ .n-card-header .n-card-header__close {
|
|
|
+ display: none;
|
|
|
+ }
|
|
|
+ &.one {
|
|
|
+ width: 600px;
|
|
|
+ }
|
|
|
+ &.many {
|
|
|
+ width: 1200px;
|
|
|
+ .copy-node-many-box {
|
|
|
+ position: relative;
|
|
|
+ height: 60vh;
|
|
|
+ display: flex;
|
|
|
+ .copy-node-many-tree {
|
|
|
+ position: relative;
|
|
|
+ flex: 1;
|
|
|
+ height: 100%;
|
|
|
+ overflow: auto;
|
|
|
+ padding-right: 20px;
|
|
|
+ border-right: 1px solid #efeff5;
|
|
|
+ }
|
|
|
+ .copy-node-many-table {
|
|
|
+ position: relative;
|
|
|
+ flex: 1;
|
|
|
+ height: 100%;
|
|
|
+ margin-left: 20px;
|
|
|
+ .copy-node-many-table-data {
|
|
|
+ position: relative;
|
|
|
+ height: calc(100% - 74px);
|
|
|
+ margin-bottom: 20px;
|
|
|
+ overflow: auto;
|
|
|
+ }
|
|
|
+ .copy-node-many-foot-center {
|
|
|
+ position: relative;
|
|
|
+ text-align: center;
|
|
|
+ padding-top: 20px;
|
|
|
+ border-top: 1px solid #efeff5;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+}
|
|
|
+.img-preview-box {
|
|
|
+ position: relative;
|
|
|
+ height: 100%;
|
|
|
+ width: 100%;
|
|
|
+ .cu-img-preview.cu-img-preview-dom .cu-img-preview-box {
|
|
|
+ height: calc(100% - 60px);
|
|
|
+ }
|
|
|
+ .cu-img-preview.cu-img-preview-dom .cu-img-preview-tools-box{
|
|
|
+ position: absolute;
|
|
|
+ }
|
|
|
+}
|
|
|
+</style>
|