zhaowei
2025-03-26 92a6ef42fcd2069c72f6cd55b359f8751daf198e
DNC指派到设备请求参数调整
已修改1个文件
24 ■■■■ 文件已修改
src/views/dnc/base/modules/ProductStructure/Document/NcDocumentAssignModal.vue 24 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/dnc/base/modules/ProductStructure/Document/NcDocumentAssignModal.vue
@@ -30,7 +30,7 @@
            <a-table :columns="columns" :data-source="dataSource" bordered :pagination="false" :loading="loading"
                     :rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange}"
                     :rowSelection="{selectedRowKeys: selectedRowKeys,selectedRows:selectionRows, onChange: onSelectChange}"
                     @change="handleTableChange"
                     :scroll="{y:456}" :size="size" rowKey="docId">
@@ -59,7 +59,9 @@
                          :treeData="treeDataSource" @check="handleTreeNodeCheck" @expand="handleTreeNodeExpand">
                    <template slot="title" slot-scope="{ title, parentId, entity, key:treeKey,type}">
                     <span v-if="title.indexOf(searchValue) > -1">{{ title.substr(0, title.indexOf(searchValue)) }}<span
                       class="replaceSearch">{{ searchValue }}</span>{{ title.substr(title.indexOf(searchValue) + searchValue.length) }}</span>
                       class="replaceSearch">{{
                         searchValue
                       }}</span>{{ title.substr(title.indexOf(searchValue) + searchValue.length) }}</span>
                      <span v-else>{{ title }}</span>
                    </template>
                  </a-tree>
@@ -256,8 +258,19 @@
      // 指派到设备窗口点击确定指派设备后触发
      handleAssignDocumentToDevice() {
        const { checkedKeys, selectedRowKeys, dataList, $confirm, $notification, currentDocumentInfo, queryParam: { applyReason }, $destroyAll, $bus } = this
        const { publishFileId, attributionId, attributionType } = currentDocumentInfo
      const {
        checkedKeys,
        selectedRowKeys,
        selectionRows,
        dataList,
        $confirm,
        $notification,
        currentDocumentInfo,
        queryParam: { applyReason },
        $destroyAll,
        $bus
      } = this
      const { attributionId, attributionType } = currentDocumentInfo
        const paramsArray = []
        // 过滤车间key仅放入设备key
        const treeCheckedDeviceKeys = []
@@ -282,7 +295,7 @@
          onOk: () => {
            // 双重循环确定每一组设备与文档的参数
            treeCheckedDeviceKeys.forEach(deviceId => {
              selectedRowKeys.forEach(docId => {
            selectionRows.forEach(({ docId, publishFileId }) => {
                paramsArray.push({
                  docId,
                  deviceId,
@@ -419,6 +432,7 @@
        this.searchInput = ''
        this.expandedKeys = []
        this.selectedRowKeys = []
      this.selectionRows = {}
        this.checkedKeys = []
        this.filters = {}
        this.isorter = Object.assign({}, this.defaultSorter)