yangys
2025-09-02 d762a77d9238eef17c66c35b06955fca20160043
表单未清空修复
已添加1个文件
已修改6个文件
287 ■■■■■ 文件已修改
src/views/basesetting/machine.vue 2 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/flowmgr/processQuery1.vue 3 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/flowmgr/processQuery2.vue 5 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/flowmgr/taskassign.vue 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/flowmgr/taskassigntemp.vue 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/statreport/sendrecord.vue 263 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/wel/gongkong.vue 10 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/basesetting/machine.vue
@@ -521,6 +521,8 @@
          this.$message({type: 'error',message: res.data.msg});
        }
        done();
      }).catch(e=>{
        done();
      });
    },
    handleView() {
src/views/flowmgr/processQuery1.vue
@@ -20,8 +20,7 @@
                <!-- <el-button type="primary" plain @click="exportWebSite">导出回传涉密网</el-button> -->
                <!-- <el-button type="primary" plain @click="reassign">挂载车床程序库</el-button> -->
                <!-- <el-button type="primary" plain @click="exportExcel">导出到EXCEL</el-button> -->
                <el-button type="primary" plain @click="reassign">重新指派
                </el-button>
                <!-- <el-button type="primary" plain @click="reassign">重新指派</el-button>-->
            </template>
            <template #menu="scope">
                <el-button type="primary" text size="default" @click.stop="customView(scope.row, scope.index, 0)">查看
src/views/flowmgr/processQuery2.vue
@@ -17,15 +17,14 @@
            <template #menu="scope">
                <el-button type="primary" text size="default" @click.stop="customView(scope.row, scope.index, 0)">查看
                </el-button>
                <!--
               <el-button type="primary" text size="default" v-if="scope.row.processDefinitionKey === 'dispatch'"
                    @click.stop="handleApproveTable(scope.row, scope.index)">审批表
                </el-button>
                 <!--
                  v-if="scope.row.processDefinitionKey === 'program-cure'"
                -->
                <el-button type="primary" text size="default" v-if="scope.row.processDefinitionKey === 'program-cure'"
                    @click.stop="handleConfirmTable(scope.row, scope.index)">确认表
                </el-button>
                -->
            </template>
        </avue-crud>
        <el-dialog title="指派" append-to-body v-model="reassignBox" width="30%">
src/views/flowmgr/taskassign.vue
@@ -300,7 +300,7 @@
            type: 'success',
            message: '操作成功!',
          });
          //this.$refs.form.resetForm();
          this.$refs.form.resetForm();
          this.attachForm = this.defaultForm;
          done();
        },
src/views/flowmgr/taskassigntemp.vue
@@ -275,7 +275,7 @@
            type: 'success',
            message: '操作成功!',
          });
          //this.$refs.form.resetForm();
          this.$refs.form.resetForm();
          this.attachForm = this.defaultForm;
          done();
        },
src/views/statreport/sendrecord.vue
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,263 @@
<template>
      <basic-container>
        <avue-crud
          :addBtn="false"
          :option="option"
          :table-loading="loading"
          :data="data"
          ref="crud"
          v-model:search="search"
          v-model:page="mypage"
          @search-change="searchChange"
          @search-reset="searchReset"
          @current-change="currentChange"
          @size-change="sizeChange"
          @refresh-change="refreshChange"
          @on-load="onLoad"
        >
      <template #search="{ disabled, size }">
      </template>
          <template #menu-left>
            <div class="menuLeft">
              <el-button type="primary" size="default" icon="el-icon-circle-plus" plain @click="handleExport">导出</el-button>
              <el-button type="primary" size="default" icon="el-icon-compass" plain @click="preMonth">上月</el-button>
              <el-button type="primary" size="default" icon="el-icon-aim" plain @click="thisMonth">本月</el-button>
            </div>
          </template>
        </avue-crud>
      </basic-container>
</template>
<script>
import { exportBlob } from '@/api/common';
import { getToken } from '@/utils/auth';
import NProgress from 'nprogress';
import dayjs from 'dayjs';
import { downloadXls } from '@/utils/util';
import 'nprogress/nprogress.css';
import { getDeptLazyTree } from '@/api/system/dept';
export default {
  data() {
    var that = this;
    return {
      /*
      treeOption: {
        nodeKey: 'id',
        lazy: true,
        treeLoad: function (node, resolve) {
          const parentId = node.level === 0 ? 0 : node.data.id;
          getDeptLazyTree(parentId).then(res => {
            resolve(
              res.data.data.map(item => {
                return {
                  ...item,
                  leaf: !item.hasChildren,
                };
              })
            );
          });
        },
        addBtn: false,
        menu: false,
        size: 'small',
        props: {
          labelText: '标题',
          label: 'title',
          value: 'value',
          children: 'children',
        },
      },*/
      treeData: [],
      treePropsConfig: {
        value:  'id',
        label: 'title',
        children: 'children'
      },
      organizationTreeList: [],
      search: {
      },
      loading: true,
      mypage: {
        size: 10,
        current: 1,
        total: 0,
      },
      option: {
        index: true,
        addBtn: false,
        editBtn: false,
        delBtn: false,
        labelWidth: 120,
        emptyBtn: false,
        searchSpan: 8,
        searchEnter:true,
        menu:false,
        column: [
          {
            label: '程序名称',
            search: true,
            prop: 'name',
          },
          {
            label: '机床编号',
            prop: 'machineCode'
          },
          {
            label: '下发人员',
            prop: 'createUserName',
          },
          {
            label: '下发时间',
            prop: 'createTime',
            type: "datetime",
            format: 'YYYY-MM-DD HH:mm:ss',
          },
          {
            label: '下发时间',
            prop: 'createTime',
            type: "datetime",
            format: 'YYYY-MM-DD',
            valueFormat: 'YYYY-MM-DD',
            hide:true,
            search: true,
            searchRange: true,
          },
        ],
      },
      data: [],
    };
  },
  methods: {
    handleChange(a,b,c) {
      console.log(a,b,c);
    },
    nodeClick(data) {
      //this.treeDeptId = data.id;
      this.mypage.current = 1;
      this.onLoad(this.page);
    },
    getQueryObj(){
        let param = this.search;
        if(param.createTime){
          param.createTimeBegin = param.createTime[0];
          param.createTimeEnd = param.createTime[1];
        }
        return param;
    },
    handleExport() {
      this.$confirm('是否导出?', '提示', {
        confirmButtonText: '确定',
        cancelButtonText: '取消',
        type: 'warning',
      }).then(() => {
        NProgress.start();
        let q = this.getQueryObj();
        let param = this.search;
        if(param.createTime){
          param.createTimeBegin = param.createTime[0];
          param.createTimeEnd = param.createTime[1];
        }
        exportBlob(
          `/blade-mdm/machinefile/sendrecord/export-excel?${this.website.tokenHeader}=${getToken()}`,
          q
        ).then(res => {
          downloadXls(res.data, `下发记录表${this.$dayjs().format('YYYY-MM-DD HH:mm:ss')}.xlsx`);
          NProgress.done();
        });
      });
    },
    searchReset() {
      //this.onLoad(this.mypage);
    },
    searchChange(params, done) {
      this.mypage.current = 1;
      this.onLoad();
      done();
    },
    currentChange(current) {
      this.mypage.current = current;
    },
    sizeChange(size) {
      this.mypage.size = size;
    },
    refreshChange() {
    },
    preMonth(){
      let now = dayjs();
      let prevMonthstart = now.subtract(1,'month').startOf( 'month').format('YYYY-MM-DD');
      let prevMonthEnd = now.subtract(1,'month').endOf('month').format('YYYY-MM-DD');
      this.search.createTime = [prevMonthstart,prevMonthEnd];
    },
    thisMonth(){
      let now = dayjs();
      let start = now.startOf( 'month').format('YYYY-MM-DD');
      let end = now.endOf('month').format('YYYY-MM-DD');
      this.search.createTime = [start,end];
    },
    onLoad() {
      let q = this.getQueryObj();
      axios({
          url: '/blade-mdm/machinefile/sendrecord/page',
          method: 'get',
          params: q,
        }).then(
          res => {
            const data = res.data.data;
            this.mypage.total = data.total;
            this.data = data.records;
            this.loading = false;
          },
          error => {
          }
        );
    },
    traversalLabelValueToTree(tree) {  //遍历数组
      return tree.map(node => {
        // 1. æ·»åŠ  label å’Œ value å­—段
        const newNode = {
          ...node,
          label: node.fullName,
          value: node.id,
        };
        // 2. å¦‚果有 children,递归处理
        if (node.children && node.children.length > 0) {
          newNode.children = this.traversalLabelValueToTree(node.children);
        }
        return newNode;
      });
    }
  },
  mounted() {
    //所属组织 /api/blade-system/dept/tree
    axios({url: '/blade-system/dept/tree',method: 'get'}).then(resp => {
      this.organizationTreeList = this.traversalLabelValueToTree(resp.data.data);
    })
  }
};
</script>
<style lang="scss">
.upload-demo {
  display: inline-block;
  margin-left: 6px;
  margin-right: 6px;
}
.menuLeft {
  display: flex;
  align-items: center;
}
</style>
src/views/wel/gongkong.vue
@@ -36,11 +36,11 @@
        </el-col>
      </el-row>
      <el-table :data="treecFileData" style="width: 100%">
        <el-table-column prop="name" label="名称" />
            <el-table-column prop="fileModifyTime" label="创建日期" />
        <el-table-column prop="fileModifyTime" label="修改日期" />
        <el-table-column prop="fileSizeDisplay" label="大小" />
        <el-table-column fixed="right" label="操作" min-width="120">
        <el-table-column prop="name" label="名称"/>
            <el-table-column prop="fileModifyTime" label="创建日期"  width="160"/>
        <el-table-column prop="fileModifyTime" label="修改日期"   width="160"/>
        <el-table-column prop="fileSizeDisplay" label="大小" width="80"/>
        <el-table-column fixed="right" label="操作" min-width="110">
          <template #default="scope">
            <el-button link type="primary" size="small" @click="fileView(scope.row)">查看</el-button>
            <el-button link type="primary" size="small" @click="fileEdit(scope.row)">编辑</el-button>