分支自 SuZhouGuanHong/TaiYuanTaiZhong

dengjunjie
2024-07-19 7a4c218909936721fe281737491d10efc7378e09
优化工单信息页面
已修改10个文件
已添加4个文件
790 ■■■■ 文件已修改
代码管理/PCS/WCS_Client/src/extension/widesea_wcs/tomes/WorkOrderGridFooter.vue 113 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
代码管理/PCS/WCS_Client/src/extension/widesea_wcs/tomes/WorkOrderModelBody.vue 165 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
代码管理/PCS/WCS_Client/src/extension/widesea_wcs/tomes/dt_mes_head.js 40 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
代码管理/PCS/WCS_Client/src/views/widesea_wcs/tomes/dt_mes_head.vue 383 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
代码管理/PCS/WCS_Server/WIDESEA_Core/BaseProvider/ServiceBase.cs 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
代码管理/PCS/WCS_Server/WIDESEA_Entity/DomainModels/ToMES/dt_mes_detail.cs 5 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
代码管理/PCS/WCS_Server/WIDESEA_Entity/DomainModels/ToMES/dt_mes_head.cs 34 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
代码管理/PCS/WCS_Server/WIDESEA_WCS/Common/Gantry.cs 11 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
代码管理/PCS/WCS_Server/WIDESEA_WCS/JobsPart/Common/AutoUpdateWork.cs 6 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
代码管理/PCS/WCS_Server/WIDESEA_WCS/Services/ToMES/Partial/dt_mes_headService.cs 21 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
代码管理/PCS/WCS_Server/WIDESEA_WCS/ToMES/ToMesServer.cs 6 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
代码管理/PCS/WCS_Server/WIDESEA_WebApi/Download/ExcelExport/20240719/工单信息20240719174950.xlsx 补丁 | 查看 | 原始文档 | blame | 历史
代码管理/PCS/WCS_Server/WIDESEA_WebApi/Download/ExcelExport/20240719/工单明细20240719175850.xlsx 补丁 | 查看 | 原始文档 | blame | 历史
代码管理/PCS/WCS_Server/WIDESEA_WebApi/appsettings.json 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
´úÂë¹ÜÀí/PCS/WCS_Client/src/extension/widesea_wcs/tomes/WorkOrderGridFooter.vue
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,113 @@
<template>
  <div style="padding: 0 4px; border-top: 10px solid #eee">
    <h3>
      <i class="ivu-icon ivu-icon-ios-information-circle-outline"></i>工单明细
    </h3>
    <div style="padding: 10px; background: white; padding-top: 0">
      <vol-table
        ref="tableList"
        :loadKey="true"
        :columns="columns"
        :pagination-hide="true"
        :height="210"
        :defaultLoadPage="false"
        @loadBefore="loadBefore"
        url="/api/dt_mes_head/getDetailPage"
        :row-index="true"
        :index="false"
      ></vol-table>
    </div>
  </div>
</template>
<script>
import VolTable from "@/components/basic/VolTable.vue";
export default {
  components: {
    VolTable,
  },
  methods: {
    loadBefore(params, callback) {
      return callback(true);
    },
  },
  data() {
    return {
      tableData: [],
      //从生成的代码sellorder2.vue里面把明细配置复制过来就能用
      columns: [
      {
            field: "mes_detail_id",
            title: "工单明细ID",
            type: "guid",
            width: 110,
            hidden: true,
            readonly: true,
            require: true,
            align: "left",
          },
          {
            field: "jobID",
            title: "工单编号",
            type: "string",
            width: 110,
            align: "left",
            sort: true,
          },
          {
            field: "heatID",
            title: "炉代号",
            type: "string",
            width: 110,
            align: "left",
          },
          {
            field: "billetID",
            title: "钢坯号",
            type: "int",
            width: 110,
            require: true,
            align: "left",
          },
          {
            field: "SN",
            title: "车轮SN号",
            type: "string",
            width: 110,
            align: "left",
          },
          {
            field: "heatBatchID",
            title: "热处理批次",
            type: "string",
            width: 110,
            align: "left",
          },
          {
            field: "Status",
            title: "工单状态",
            type: "string",
            width: 110,
            align: "left",
          },
          {
            field: "FinishTime",
            title: "完成时间",
            type: "datetime",
            width: 150,
            align: "left",
          },
      ],
    };
  },
};
</script>
<style scoped>
h3 {
  font-weight: 500;
  padding-left: 10px;
  background: white;
  margin-top: 8px;
  padding-bottom: 5px;
}
</style>
´úÂë¹ÜÀí/PCS/WCS_Client/src/extension/widesea_wcs/tomes/WorkOrderModelBody.vue
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,165 @@
<template>
  <VolBox v-model="model" title="选择数据" :lazy="true" :height="530" :width="1100" :padding="10">
    <!-- è®¾ç½®æŸ¥è¯¢æ¡ä»¶ -->
    <div style="padding-bottom: 10px">
      <span style="margin-right: 20px">请选择数据</span>
      <el-input placeholder="工单编号" style="width: 200px" v-model="jobID" />
      <el-button type="primary" plain style="margin-left: 10px" icon="Search" @click="search">搜索</el-button>
    </div>
    <!-- vol-table配置的这些属性见VolTable组件api文件 -->
    <vol-table ref="mytable" :loadKey="true" :columns="columns" :pagination="pagination" :pagination-hide="false"
      :max-height="380" :url="url" :index="true" :single="false" :defaultLoadPage="false"
      @loadBefore="loadTableBefore"></vol-table>
    <template #footer>
      <div>
        <el-button plain type="primary" @click="addRow">选择数据</el-button>
        <el-button @click="model = false">关闭</el-button>
      </div>
    </template>
  </VolBox>
</template>
<script>
import VolBox from "@/components/basic/VolBox.vue";
import VolTable from "@/components/basic/VolTable.vue";
export default {
  components: {
    VolBox: VolBox,
    VolTable: VolTable,
  },
  data() {
    return {
      model: false,
      jobID: "",
      mes_headID:null,
      //从后台接口加载数据,这里的接口用的框架自带的查询,也可以自定义接口,见App_ExpertModelBody.vue中调用的后台getSelectorDemo方法
      url: "api/dt_mes_detail/getPageData",
      columns: [
      {
            field: "mes_detail_id",
            title: "工单明细ID",
            type: "guid",
            width: 110,
            hidden: true,
            readonly: true,
            require: true,
            align: "left",
          },
          {
            field: "jobID",
            title: "工单编号",
            type: "string",
            width: 110,
            align: "left",
            sort: true,
          },
          {
            field: "heatID",
            title: "炉代号",
            type: "string",
            width: 110,
            align: "left",
          },
          {
            field: "billetID",
            title: "钢坯号",
            type: "int",
            width: 110,
            require: true,
            align: "left",
          },
          {
            field: "SN",
            title: "车轮SN号",
            type: "string",
            width: 110,
            align: "left",
          },
          {
            field: "heatBatchID",
            title: "热处理批次",
            type: "string",
            width: 110,
            align: "left",
          },
          // {
          //   field: "mes_headID",
          //   title: "工单头表ID",
          //   type: "guid",
          //   width: 110,
          //   align: "left",
          // },
          {
            field: "Status",
            title: "工单状态",
            type: "string",
            width: 110,
            align: "left",
          },
          {
            field: "FinishTime",
            title: "完成时间",
            type: "datetime",
            width: 150,
            align: "left",
            sort: true,
          },
      ],
      pagination: {},
      row: {}, //明细表选择的行
    };
  },
  methods: {
    open(row) {
      //   this.row = row;
      this.model = true;
      //打开弹出框时,加载table数据
      this.$nextTick(() => {
        this.$refs.mytable.load();
      });
    },
    search() {
      this.$refs.mytable.load();
    },
    addRow() {
      var rows = this.$refs.mytable.getSelected();
      if (!rows || rows.length == 0) {
        return this.$Message.error("请选择行数据");
      }
      //回写明细表行数据,见文档子父组件调用与获取明细表行数据:http://v2.volcore.xyz/document/api
      this.$emit('parentCall', $parent => {
        //这里可以写个判断是否已经存在明细表,找到不存在的数据
        // rows = rows.filter(c => {
        //    return !$parent.$refs.detail.rowData.some(r => { return r.xx == c.xx })
        //  });
        //生成新的对象
        rows = rows.map(c => {
          return {
            jobID: c.jobID,
            heatID: c.heatID,
            billetID: c.billetID,
            SN: c.SN,
            heatBatchID:c.heatBatchID
          }
        })
        //可以清空明细表数据
        //$parent.$refs.detail.rowData.splice(0);
        //回写到明细表格
        $parent.$refs.detail.rowData.unshift(...rows);
      })
      this.model = false;
    },
    loadTableBefore(params) {
      //查询前,设置查询条件
      params.wheres = [
        { name: "jobID", value: this.jobID, displayType: "like" },
        { name: "mes_headID", value: this.mes_headID, displayType: "like" },
      ];
      return true;
    },
  },
};
</script>
´úÂë¹ÜÀí/PCS/WCS_Client/src/extension/widesea_wcs/tomes/dt_mes_head.js
@@ -6,16 +6,17 @@
**后台操作见:http://v2.volcore.xyz/document/netCoreDev
*****************************************************************************************/
//此js文件是用来自定义扩展业务代码,可以扩展一些自定义页面或者重新配置生成的代码
import gridFooter from "./WorkOrderGridFooter.vue"
import modelBody from "./WorkOrderModelBody.vue"
let extension = {
  components: {
    //查询界面扩展组件
    gridHeader: '',
    gridBody: '',
    gridFooter: '',
    gridFooter: gridFooter,
    //新建、编辑弹出框扩展组件
    modelHeader: '',
    modelBody: '',
    modelBody: modelBody,
    modelFooter: ''
  },
  tableAction: '', //指定某张表的权限(这里填写表名,默认不用填写)
@@ -23,6 +24,10 @@
  methods: {
     //下面这些方法可以保留也可以删除
    onInit() {  //框架初始化配置前,
      //点击单元格编辑与结束编辑(默认是点击单元格编辑,鼠标离开结束编辑)
      this.detailOptions.clickEdit = true;
      //设置主表合计
      this.summary = true;
        //示例:在按钮的最前面添加一个按钮
        //   this.buttons.unshift({  //也可以用push或者splice方法来修改buttons数组
        //     name: '按钮', //按钮名称
@@ -136,6 +141,15 @@
        // this.boxOptions.labelWidth = 150;
    },
    onInited() {
      //调整界面table高度
      this.height = this.height - 310;
      this.detailOptions.buttons.unshift({
        'name': '选择数据',
        icon: "el-icon-plus",
        onClick: () => {
          this.$refs.modelBody.open();
        }
      })
      //框架初始化配置后
      //如果要配置明细表,在此方法操作
      //this.detailOptions.columns.forEach(column=>{ });
@@ -145,8 +159,16 @@
      //返回false,则不会执行查询
      return true;
    },
    searchAfter(result) {
    searchAfter(rows) {
      //查询后,result返回的查询数据,可以在显示到表格前处理表格的值
      if (rows.length) {
        // this.$nextTick(() => {
        this.$refs.gridFooter.$refs.tableList.load({ value: rows[0].mes_id })
        // })
      } else {
        //没有数据时,清空明细数据
        this.$refs.gridFooter.$refs.tableList.rowData.splice(0)
      }
      return true;
    },
    addBefore(formData) {
@@ -158,8 +180,14 @@
      return true;
    },
    rowClick({ row, column, event }) {
      //查询界面点击行事件
      // this.$refs.table.$refs.table.toggleRowSelection(row); //单击行时选中当前行;
      //取消其他行选中
      this.$refs.table.$refs.table.clearSelection();
      //设置选中当前行
      this.$refs.table.$refs.table.toggleRowSelection(row);
      if (this.$refs.gridFooter && this.$refs.gridFooter.$refs.tableList) {
        //load方法可参照voltable组件api文档
        this.$refs.gridFooter.$refs.tableList.load({ value: row.mes_id })
      }
    },
    modelOpenAfter(row) {
      //点击编辑、新建按钮弹出框后,可以在此处写逻辑,如,从后台获取数据
´úÂë¹ÜÀí/PCS/WCS_Client/src/views/widesea_wcs/tomes/dt_mes_head.vue
@@ -5,7 +5,8 @@
 *业务请在@/extension/widesea_wcs/tomes/dt_mes_head.js此处编写
 -->
<template>
    <view-grid ref="grid"
  <view-grid
    ref="grid"
               :columns="columns"
               :detail="detail"
               :editFormFields="editFormFields"
@@ -13,86 +14,316 @@
               :searchFormFields="searchFormFields"
               :searchFormOptions="searchFormOptions"
               :table="table"
               :extend="extend">
    :extend="extend"
  >
    </view-grid>
</template>
<script>
    import extend from "@/extension/widesea_wcs/tomes/dt_mes_head.js";
    import { ref, defineComponent } from "vue";
    export default defineComponent({
        setup() {
            const table = ref({
                key: 'mes_id',
                footer: "Foots",
                cnName: '工单头表',
                name: 'tomes/dt_mes_head',
                url: "/dt_mes_head/",
                sortName: "CreateTime"
            });
            const editFormFields = ref({"stackNoRange":"","skip_op_1":"","skip_op_2":"","skip_op_3":""});
            const editFormOptions = ref([
                [{"title":"打包数量","field":"stackNoRange","type":"number"}],
            [{ "dataKey": "skip_op_Status", "data": [], "title": "视觉检测1", "required": true, "field": "skip_op_1", "type": "select" }],
            [{ "dataKey": "skip_op_Status", "data": [], "title": "视觉检测2", "required": true, "field": "skip_op_2", "type": "select" }],
            [{ "dataKey": "skip_op_Status", "data": [], "title": "喷防锈液", "required": true, "field": "skip_op_3", "type": "select" }],
        //     [{
        //   title: "指定库区", field: "area",
        //   data: [
        //     { key: 9, value: "外协区" },
        //     { key: 2, value: "库区2" },
        //     { key: 3, value: "库区3" },
        //     { key: 4, value: "库区4" },
        //     //{ key: 3, value: "不允许" },
        //   ]
        //   , type: "radio"//type: "select"
        // }],
            ]);
            const searchFormFields = ref({"jobID":"","processCode":"","CreateTime":""});
            const searchFormOptions = ref([
                [{"title":"工作令号","field":"workOrder","type":"like"},{"title":"工单编号","field":"jobID","type":"like"},{"dataKey":"WorkTypes","data":[],"title":"工单类型","field":"processCode","type":"select"}],
                [{"title":"图号","field":"drawingNo","type":"like"},{"title":"创建时间","field":"CreateTime","type":"datetime"}]
            ]);
            const columns = ref([{field:'mes_id',title:'mes_id',type:'guid',width:110,hidden:true,readonly:true,require:true,align:'left'},
                       {field:'workOrder',title:'工作令号',type:'string',width:110,align:'left',sort:true},
                       {field:'jobID',title:'工单编号',type:'string',width:110,align:'left'},
                    //    {field:'reqID',title:'需求单号',type:'string',width:110,align:'left'},
                    //    {field:'reqIDLineNo',title:'需求单号行号',type:'string',width:110,align:'left'},
                    //    {field:'materialCode',title:'物料编码',type:'string',width:110,align:'left'},
                       {field:'drawingNo',title:'图号',type:'string',width:110,align:'left'},
                       {field:'drawingNoVer',title:'技术状态',type:'string',width:110,align:'left'},
                    //    {field:'productName',title:'产品名称',type:'string',width:110,align:'left'},
                       {field:'processCode',title:'工单类型',bind: { key: 'WorkTypes' },type:'string',width:110,align:'left'},
                       {field:'quantity',title:'计划数量',type:'int',width:110,align:'left'},
                       {field:'finishNum',title:'完成数量',type:'int',width:110,align:'left'},
                       {field:'area',title:'指定库区',type:'string',width:110,align:'left'},
                    //    {field:'typeID',title:'轮型代码',type:'string',width:110,align:'left'},
                       {field:'stackNoRange',title:'打包数量',type:'int',width:110,align:'left',sort:true},
                       {field:'skip_op_1',title:'视觉检测1',type:'bool',bind:{ key:'skip_op_Status',data:[]},width:110,require:true,align:'left'},
                       {field:'skip_op_2',title:'视觉检测2',type:'bool',bind:{ key:'skip_op_Status',data:[]},width:110,require:true,align:'left'},
                       {field:'skip_op_3',title:'喷防锈液',type:'bool',bind:{ key:'skip_op_Status',data:[]},width:110,require:true,align:'left'},
                    //    {field:'maxDiameterDiff',title:'轮径偏差',type:'decimal',width:110,align:'left'},
                       {field:'expectedStartTime',title:'计划开始时间',type:'datetime',width:150,align:'left',sort:true},
                       {field:'expectedFinishTime',title:'计划完成时间',type:'datetime',width:150,align:'left',sort:true},
                       {field:'CreateTime',title:'创建时间',type:'datetime',width:150,align:'left',sort:true},
                       {field:'creator',title:'创建者',type:'string',width:100,align:'left'},
                       {field:'productDesc',title:'产品描述',type:'string',width:180,align:'left'}]);
            const detail = ref({
                cnName: "#detailCnName",
                table: "#detailTable",
                columns: [],
                sortName: "",
                key: ""
            });
var vueParam={
  data() {
            return {
                table,
                extend,
                editFormFields,
                editFormOptions,
                searchFormFields,
                searchFormOptions,
                columns,
                detail,
      table: {
        key: "mes_id",
        footer: "Foots",
        cnName: "工单信息",
        name: "work/dt_mes_head",
        url: "/dt_mes_head/",
        sortName: "CreateTime",
      },
      extend: extend,
      editFormFields: {
        workOrder: "",
        jobID: "",
        drawingNo: "",
        productDesc: "",
        CreateTime:"",
        quantity:"",
      },
      editFormOptions: [
        [
          { title: "工作令号", field: "workOrder", readonly: true },
          { title: "工单编号", field: "jobID", readonly: true },
          { title: "图号", field: "drawingNo", readonly: true },
        ],
        [
          { title: "创建时间", field: "CreateTime", disabled: true },
          {
            title: "产品描述",
            field: "productDesc",
            colSize: 8,
            type: "textarea",
          },
        ],
      ],
      searchFormFields: {
        workOrder: "",
        jobID: "",
        drawingNo: "",
        productDesc: "",
        processCode:"",
      },
      searchFormOptions: [
        [
          { title: "工作令号", field: "workOrder" },
          { title: "工单编号", field: "jobID" },
          { title: "图号", field: "drawingNo" },
        ],
        [
        {
          dataKey: "WorkTypes",
          data: [],
          title: "工单类型",
          field: "processCode",
          type: "select",
        },
        { title: "创建时间", field: "CreateTime", type: "datetime" },
        ]
      ],
      columns: [
        {
          field: "mes_id",
          title: "mes_id",
          type: "guid",
          width: 110,
          hidden: true,
          readonly: true,
          require: true,
          align: "left",
        },
        {
          field: "workOrder",
          title: "工作令号",
          type: "string",
          width: 110,
          align: "left",
          sort: true,
        },
        {
          field: "jobID",
          title: "工单编号",
          type: "string",
          link: true,
          width: 110,
          align: "left",
        },
        // {
        //   field: "reqID",
        //   title: "需求单号",
        //   type: "string",
        //   width: 110,
        //   align: "left",
        // },
        // {
        //   field: "reqIDLineNo",
        //   title: "需求单号行号",
        //   type: "string",
        //   width: 110,
        //   align: "left",
        // },
        // {
        //   field: "materialCode",
        //   title: "物料编码",
        //   type: "string",
        //   width: 110,
        //   align: "left",
        // },
        {
          field: "drawingNo",
          title: "图号",
          type: "string",
          width: 110,
          align: "left",
        },
        {
          field: "drawingNoVer",
          title: "技术状态",
          type: "string",
          width: 110,
          align: "left",
        },
        // {
        //   field: "productName",
        //   title: "产品名称",
        //   type: "string",
        //   width: 110,
        //   align: "left",
        // },
        {
        field: "processCode",
        title: "工单类型",
        bind: { key: "WorkTypes" },
        type: "string",
        width: 110,
        align: "left",
      },
        {
          field: "quantity",
          title: "计划数量",
          type: "int",
          width: 110,
          require: true,
          align: "left",
        },{
        field: "finishNum",
        title: "完成数量",
        type: "int",
        width: 110,
        align: "left",
      },{
        field: "area",
        title: "指定库区",
        type: "string",
        width: 110,
        align: "left",
      },
        // {
        //   field: "typeID",
        //   title: "轮型代码",
        //   type: "string",
        //   width: 110,
        //   align: "left",
        // },
        // {
        //   field: "stackNoRange",
        //   title: "打包数量",
        //   type: "int",
        //   width: 110,
        //   align: "left",
        // },
        // {
        //   field: "maxDiameterDiff",
        //   title: "轮径偏差",
        //   type: "decimal",
        //   width: 110,
        //   align: "left",
        // },
        {
          field: "expectedStartTime",
          title: "计划开始时间",
          type: "datetime",
          width: 150,
          align: "left",
          sort: true,
        },
        {
          field: "expectedFinishTime",
          title: "计划完成时间",
          type: "datetime",
          width: 150,
          align: "left",
          sort: true,
        },
        {
          field: "CreateTime",
          title: "创建时间",
          type: "datetime",
          width: 150,
          align: "left",
          sort: true,
        },
        {
          field: "creator",
          title: "创建者",
          type: "string",
          width: 100,
          align: "left",
        },
        {
          field: "productDesc",
          title: "产品描述",
          type: "string",
          width: 180,
          align: "left",
        },
        {
          field: "FinishTime",
          title: "完成时间",
          type: "datetime",
          width: 150,
          align: "left",
          sort: true,
        },
      ],
      detail: {
        cnName: "工单明细",
        table: "dt_mes_detail",
        columns: [
          {
            field: "mes_detail_id",
            title: "工单明细ID",
            type: "guid",
            width: 110,
            hidden: true,
            readonly: true,
            require: true,
            align: "left",
          },
          {
            field: "jobID",
            title: "工单编号",
            type: "string",
            width: 110,
            align: "left",
            sort: true,
          },
          {
            field: "heatID",
            title: "炉代号",
            type: "string",
            width: 110,
            align: "left",
          },
          {
            field: "billetID",
            title: "钢坯号",
            type: "int",
            width: 110,
            require: true,
            align: "left",
          },
          {
            field: "SN",
            title: "车轮SN号",
            type: "string",
            width: 110,
            align: "left",
          },
          {
            field: "heatBatchID",
            title: "热处理批次",
            type: "string",
            width: 110,
            align: "left",
          },
          //   {
          //     field: "mes_headID",
          //     title: "工单头表ID",
          //     type: "guid",
          //     width: 110,
          //     align: "left",
          //   },
          {
            field: "Status",
            title: "工单状态",
            type: "string",
            width: 110,
            align: "left",
          },
          {
            field: "FinishTime",
            title: "完成时间",
            type: "datetime",
            width: 150,
            align: "left",
            sort: true,
          },
        ],
        sortName: "jobID",
        key: "mes_detail_id",
      },
            };
        },
    });
};
export default vueParam;
</script>
´úÂë¹ÜÀí/PCS/WCS_Server/WIDESEA_Core/BaseProvider/ServiceBase.cs
@@ -155,7 +155,7 @@
        /// </summary>
        /// <param name="pageData"></param>
        /// <param name="propertyInfo"></param>
        private Dictionary<string, QueryOrderBy> GetPageDataSort(PageDataOptions pageData, PropertyInfo[] propertyInfo)
        public Dictionary<string, QueryOrderBy> GetPageDataSort(PageDataOptions pageData, PropertyInfo[] propertyInfo)
        {
            if (base.OrderByExpression != null)
            {
´úÂë¹ÜÀí/PCS/WCS_Server/WIDESEA_Entity/DomainModels/ToMES/dt_mes_detail.cs
@@ -13,7 +13,8 @@
namespace WIDESEA_Entity.DomainModels
{
    [Entity(TableCnName = "工单详细信息", TableName = "dt_mes_detail")]
    [Table("dt_mes_detail")]
    [Entity(TableCnName = "工单明细", TableName = "dt_mes_detail")]
    public partial class dt_mes_detail : BaseEntity
    {
        /// <summary>
@@ -31,7 +32,7 @@
        [Display(Name = "mes_headID")]
        [Column(TypeName = "uniqueidentifier")]
        [Required(AllowEmptyStrings = false)]
        public Guid mes_headID { get; set; }
        public Guid mes_id { get; set; }
        /// <summary>
        ///工单单号
´úÂë¹ÜÀí/PCS/WCS_Server/WIDESEA_Entity/DomainModels/ToMES/dt_mes_head.cs
@@ -13,7 +13,8 @@
namespace WIDESEA_Entity.DomainModels
{
    [Entity(TableCnName = "工单信息", TableName = "dt_mes_head")]
    [Table("dt_mes_head")]
    [Entity(TableCnName = "工单信息", TableName = "dt_mes_head", DetailTable = new Type[] { typeof(dt_mes_detail) }, DetailTableCnName = "工单明细")]
    public partial class dt_mes_head : BaseEntity
    {
@@ -141,13 +142,6 @@
        [Editable(true)]
        public string typeID { get; set; }
        /// <summary>
        ///打包数量
        /// </summary>
        [Display(Name = "打包数量")]
        [Column(TypeName = "int")]
        [Editable(true)]
        public int? stackNoRange { get; set; }
        /// <summary>
        ///轮径偏差
@@ -202,30 +196,6 @@
        [Column(TypeName = "nvarchar(15)")]
        public string area { get; set; }
        /// <summary>
        ///视觉检测设备1
        /// </summary>
        [Display(Name = "视觉检测设备1")]
        [Column(TypeName = "bit")]
        [Editable(true)]
        public bool skip_op_1 { get; set; }
        /// <summary>
        ///视觉检测设备2
        /// </summary>
        [Display(Name = "视觉检测设备2")]
        [Column(TypeName = "bit")]
        [Editable(true)]
        public bool skip_op_2 { get; set; }
        /// <summary>
        ///链条机
        /// </summary>
        [Display(Name = "链条机")]
        [Column(TypeName = "bit")]
        [Editable(true)]
        public bool skip_op_3 { get; set; }
        /// <summary>
        ///AGV完成数量
´úÂë¹ÜÀí/PCS/WCS_Server/WIDESEA_WCS/Common/Gantry.cs
@@ -207,19 +207,10 @@
                            //client.WriteByOrder("W_i_sourceheat", "", name);
                            client.WriteByOrder("W_i_batch_id", Mes_Work.heatBatchID, name);
                            //屏蔽工艺(屏蔽视觉检测/屏蔽涂油)
                            if (name != "辊道上料查询订单")
                            {
                                client.WriteByOrder("W_i_skip_op_SJ1", name == "3单元辊道下料查询订单" ? true : mes_Head.skip_op_1, name);//屏蔽视觉检测设备1
                                client.WriteByOrder("W_i_skip_op_SJ2", name == "3单元辊道下料查询订单" ? true : mes_Head.skip_op_2, name);//屏蔽视觉检测设备2
                                client.WriteByOrder("W_i_skip_op_LT", mes_Head.skip_op_3, name);//屏蔽链条机
                            }
                            client.WriteByOrder("R_oi_on", (byte)0, name);
                            #region æ—¥å¿—记录
                            WriteLog.Write_Log(name, wp_id, "写入信息!", $"读取桁架信息:\n车轮SN:{wp_id}\n轮型ID:{wp_type}\n\n写入桁架信息:\nW_i_status:1" +
                                $"\nW_i_job_id:{Mes_Work.jobID}\nW_i_drawing_id:{Mes_Work.drawingNo}\nW_i_heat_id:{Mes_Work.heatID}\nW_i_batch_id:{Mes_Work.heatBatchID}" +
                                $"\nW_i_skip_op_SJ1:{(name == "3单元辊道下料查询订单" ? true : mes_Head.skip_op_1)}\nW_i_skip_op_SJ2:{(name == "3单元辊道下料查询订单" ? true : mes_Head.skip_op_2)}" +
                                $"\nW_i_skip_op_LT:{mes_Head.skip_op_3}\nR_oi_on:0");
                                $"\nW_i_job_id:{Mes_Work.jobID}\nW_i_drawing_id:{Mes_Work.drawingNo}\nW_i_heat_id:{Mes_Work.heatID}\nW_i_batch_id:{Mes_Work.heatBatchID}");
                            #endregion
                        }
                    }
´úÂë¹ÜÀí/PCS/WCS_Server/WIDESEA_WCS/JobsPart/Common/AutoUpdateWork.cs
@@ -148,7 +148,7 @@
                            heatID = mes_Detail.heatID,
                            jobID = mes_Detail.jobID,
                            mes_detail_id = mes_Detail.mes_detail_id,
                            mes_headID = mes_Detail.mes_headID,
                            mes_headID = mes_Detail.mes_id,
                            operatetype = string.IsNullOrEmpty(mes_Detail.Status) ? "超时清理" : operatetype,
                            SN = mes_Detail.SN,
                            Status = mes_Detail.Status,
@@ -178,10 +178,6 @@
                    operatetype = operatetype,
                    processCode = mes_Head.processCode,
                    mes_id = mes_Head.mes_id,
                    skip_op_1 = mes_Head.skip_op_1,
                    skip_op_2 = mes_Head.skip_op_2,
                    skip_op_3 = mes_Head.skip_op_3,
                    stackNoRange = mes_Head.stackNoRange,
                    productDesc = mes_Head.productDesc,
                    productName = mes_Head.productName,
                    reqID = mes_Head.reqID,
´úÂë¹ÜÀí/PCS/WCS_Server/WIDESEA_WCS/Services/ToMES/Partial/dt_mes_headService.cs
@@ -22,11 +22,14 @@
using WIDESEA_Core.ManageUser;
using WIDESEA_Comm.LogInfo;
using System.Collections.Generic;
using WIDESEA_Core.Enums;
using WIDESEA_WCS.Repositories;
namespace WIDESEA_WCS.Services
{
    public partial class dt_mes_headService
    {
        WebResponseContent webResponse = new WebResponseContent();
        private readonly IHttpContextAccessor _httpContextAccessor;
        private readonly Idt_mes_headRepository _repository;//访问数据库
@@ -42,6 +45,24 @@
            //多租户会用到这init代码,其他情况可以不用
            //base.Init(dbRepository);
        }
        public override object GetDetailPage(PageDataOptions pageData)
        {
            pageData.Sort = pageData.Sort ?? typeof(dt_mes_detail).GetKeyName();
            Dictionary<string, QueryOrderBy> orderBy = GetPageDataSort(pageData, typeof(dt_mes_detail).GetProperties());
            ////明细表自定义查询方式一:EF
            var query = dt_mes_detailRepository.Instance.IQueryablePage<dt_mes_detail>(
                 pageData.Page,
                 pageData.Rows,
                 out int count,
                 x => x.mes_id == pageData.Value.GetGuid(),
                  orderBy: x => new Dictionary<object, QueryOrderBy>() { { x.heatID, QueryOrderBy.Desc } }
                );
            PageGridData<dt_mes_detail> detailGrid = new PageGridData<dt_mes_detail>();
            detailGrid.rows = query.GetIQueryableOrderBy(orderBy).ToList();
            detailGrid.total = count;
            return detailGrid;
        }
        /// <summary>
        /// å–消工单出库外协
        /// </summary>
´úÂë¹ÜÀí/PCS/WCS_Server/WIDESEA_WCS/ToMES/ToMesServer.cs
@@ -87,15 +87,11 @@
                    quantity = workInfo.quantity,
                    reqID = workInfo.reqID,
                    reqIDLineNo = workInfo.reqIDLineNo,
                    stackNoRange = 5,
                    //stackNoRange = workInfo.stackNoRange,
                    typeID = workInfo.typeID,
                    workOrder = workInfo.workOrder,
                    processCode = workInfo.processCode,
                    finishNum = 0,
                    skip_op_1 = false,
                    skip_op_2 = false,
                    skip_op_3 = false,
                };
                freeDB.Add(mes_Head);
@@ -104,7 +100,7 @@
                    dt_mes_detail mes_Detail = new dt_mes_detail
                    {
                        mes_detail_id = Guid.NewGuid(),
                        mes_headID = head,
                        mes_id = head,
                        jobID = item.jobID,
                        billetID = item.billetID,
                        heatBatchID = item.heatBatchID,
´úÂë¹ÜÀí/PCS/WCS_Server/WIDESEA_WebApi/Download/ExcelExport/20240719/¹¤µ¥ÐÅÏ¢20240719174950.xlsx
Binary files differ
´úÂë¹ÜÀí/PCS/WCS_Server/WIDESEA_WebApi/Download/ExcelExport/20240719/¹¤µ¥Ã÷ϸ20240719175850.xlsx
Binary files differ
´úÂë¹ÜÀí/PCS/WCS_Server/WIDESEA_WebApi/appsettings.json
@@ -16,8 +16,8 @@
  "Connection": {
    "DBType": "MsSql", //MySql/MsSql/PgSql  //数据库类型,如果使用的是sqlserver此处应设置为MsSql
    //sqlserver连接字符串P@ssw0rd
    "DbConnectionString": "Data Source=192.168.12.101;Initial Catalog=WIDESEA_DB;Persist Security Info=True;User ID=sa;Password=123456;Connect Timeout=500;",
    //"DbConnectionString": "Data Source=.;Initial Catalog=WIDESEA_DB_TY_TY;Persist Security Info=True;User ID=sa;Password=123456;Connect Timeout=500;",
    //"DbConnectionString": "Data Source=192.168.12.101;Initial Catalog=WIDESEA_DB;Persist Security Info=True;User ID=sa;Password=123456;Connect Timeout=500;",
    "DbConnectionString": "Data Source=.;Initial Catalog=WIDESEA_DB_TY_TY;Persist Security Info=True;User ID=sa;Password=P@ssw0rd;Connect Timeout=500;",
    //mysql连接字符串(升级EFCore3.1到时已将mysql连接字符串修改,2019-12-20)
    // "DbConnectionString": " Data Source=127.0.0.1;Database=netcoredev;AllowLoadLocalInfile=true;User ID=root;Password=123456;allowPublicKeyRetrieval=true;pooling=true;CharSet=utf8;port=3306;sslmode=none;",