quwangxin 2 yıl önce
ebeveyn
işleme
5c499ab91b
5 değiştirilmiş dosya ile 1246 ekleme ve 250 silme
  1. 2 0
      package.json
  2. 860 0
      src/components/print/OrderPrint.vue
  3. 77 0
      src/utils/pdf.js
  4. 305 248
      src/views/produceOrder/detail.vue
  5. 2 2
      vue.config.js

+ 2 - 0
package.json

@@ -26,8 +26,10 @@
     "ele-admin": "^1.11.2",
     "element-ui": "2.15.7",
     "github-markdown-css": "^5.1.0",
+    "html2canvas": "^1.4.1",
     "jsbarcode": "^3.11.5",
     "json-bigint": "^1.0.0",
+    "jspdf": "^2.5.1",
     "nprogress": "^0.2.0",
     "tinymce": "^5.10.5",
     "vue": "^2.7.10",

+ 860 - 0
src/components/print/OrderPrint.vue

@@ -0,0 +1,860 @@
+<template>
+  <ele-modal :visible.sync="visible" type="工单打印" width="80vw">
+    <div class="print-container" ref="pagesRef">
+      <el-row class="main-data mb-16">
+        <el-col :span="6">
+          <div class="bg"> 生产工单号 </div>
+          <div class="code">条码区</div>
+          <div class="value">21122403906633005</div>
+        </el-col>
+        <el-col :span="5">
+          <div class="bg">生产版本</div>
+          <div class="value">X011 挤压</div>
+          <div class="bg">产品编码</div>
+          <div class="value">W05363955011</div>
+        </el-col>
+        <el-col :span="5">
+          <div class="bg">计划编号</div>
+          <div class="value">YU21122400039</div>
+          <div class="bg">产品名称</div>
+          <div class="value">木工刀</div>
+        </el-col>
+        <el-col :span="4">
+          <div class="bg">计划类型</div>
+          <div class="value">内销计划</div>
+          <div class="bg">要求成型数量</div>
+          <div class="value">1000 PCS</div>
+        </el-col>
+        <el-col :span="4">
+          <div class="bg">要求成型日期</div>
+          <div class="value">2023/08/20</div>
+          <div class="bg">要求成型重量</div>
+          <div class="value">850.5 KG</div>
+        </el-col>
+      </el-row>
+
+      <el-row class="processes-data">
+        <el-col :span="14" class="bg top"
+          ><div class="title">10 挤压成型</div></el-col
+        >
+        <el-col :span="10" class="bg top">备注:</el-col>
+        <el-col
+          :span="item.span"
+          :class="item.class"
+          v-for="item in extrusion"
+          :key="item.label"
+        >
+          {{ item.label }}:{{ item.key }}
+        </el-col>
+      </el-row>
+      <el-row class="processes-data">
+        <el-col :span="14" class="bg top"
+          ><div class="title">20 自然干燥</div></el-col
+        >
+        <el-col :span="10" class="bg top">备注:</el-col>
+        <el-col
+          :span="item.span"
+          :class="item.class"
+          v-for="item in drying"
+          :key="item.label"
+        >
+          {{ item.label }}:{{ item.key }}
+        </el-col>
+      </el-row>
+      <el-row class="processes-data">
+        <el-col :span="14" class="bg top"
+          ><div class="title">30 升温干燥</div></el-col
+        >
+        <el-col :span="10" class="bg top">备注:</el-col>
+        <el-col
+          :span="item.span"
+          :class="item.class"
+          v-for="item in temperature"
+          :key="item.label"
+        >
+          {{ item.label }}:{{ item.key }}
+        </el-col>
+      </el-row>
+      <el-row class="processes-data">
+        <el-col :span="14" class="bg top"
+          ><div class="title">40 半加定长</div></el-col
+        >
+        <el-col :span="10" class="bg top">备注:</el-col>
+        <el-col
+          :span="item.span"
+          :class="item.class"
+          v-for="item in halflong"
+          :key="item.label"
+        >
+          {{ item.label }}:{{ item.key }}
+        </el-col>
+      </el-row>
+      <el-row class="processes-data">
+        <el-col :span="14" class="bg top"
+          ><div class="title">50 备炉</div></el-col
+        >
+        <el-col :span="10" class="bg top">备注:</el-col>
+        <el-col
+          :span="item.span"
+          :class="item.class"
+          v-for="item in furnace"
+          :key="item.label"
+        >
+          {{ item.label }}:{{ item.key }}
+        </el-col>
+      </el-row>
+      <el-row class="processes-data">
+        <el-col :span="14" class="bg top"
+          ><div class="title">60 烧结</div></el-col
+        >
+        <el-col :span="10" class="bg top">备注:</el-col>
+        <el-col
+          :span="item.span"
+          :class="item.class"
+          v-for="item in sinter"
+          :key="item.label"
+        >
+          {{ item.label }}:{{ item.key }}
+        </el-col>
+      </el-row>
+      <el-row class="processes-data">
+        <el-col :span="14" class="bg top"
+          ><div class="title">70 质检</div></el-col
+        >
+        <el-col :span="10" class="bg top">备注:</el-col>
+        <el-col
+          :span="item.span"
+          :class="item.class"
+          v-for="item in quality"
+          :key="item.label"
+        >
+          {{ item.label }}:{{ item.key }}
+        </el-col>
+      </el-row>
+      <el-row class="processes-data">
+        <el-col :span="14" class="bg top"
+          ><div class="title">80 深加工(精磨)</div></el-col
+        >
+        <el-col :span="10" class="bg top">备注:</el-col>
+        <el-col
+          :span="item.span"
+          :class="item.class"
+          v-for="item in deepProcesse"
+          :key="item.label"
+        >
+          {{ item.label }}:{{ item.key }}
+        </el-col>
+      </el-row>
+      <el-row class="processes-data">
+        <el-col :span="14" class="bg top"
+          ><div class="title">90 包装</div></el-col
+        >
+        <el-col :span="10" class="bg top">备注:</el-col>
+        <el-col
+          :span="item.span"
+          :class="item.class"
+          v-for="item in packageOpt"
+          :key="item.label"
+        >
+          {{ item.label }}:{{ item.key }}
+        </el-col>
+      </el-row>
+      <el-row class="processes-data">
+        <el-col :span="14" class="bg top"
+          ><div class="title">110 预缴库</div></el-col
+        >
+        <el-col :span="10" class="bg top">备注:</el-col>
+        <el-col
+          :span="item.span"
+          :class="item.class"
+          v-for="item in preStorage"
+          :key="item.label"
+        >
+          {{ item.label }}:{{ item.key }}
+        </el-col>
+      </el-row>
+    </div>
+    <div slot="footer">
+      <el-button type="primary" @click="handlePrint">打印</el-button>
+      <el-button>取消</el-button>
+    </div>
+  </ele-modal>
+</template>
+
+<script>
+  import { downloadPDF } from '@/utils/pdf.js';
+  export default {
+    data () {
+      return {
+        visible: false,
+        // 挤压成型
+        extrusion: [
+          {
+            label: '原料牌号',
+            key: 'xxx',
+            span: 8,
+            class: 'border-dashed-right border-dashed-bottom'
+          },
+          {
+            label: '原料批号',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-right border-dashed-bottom'
+          },
+          {
+            label: '投料数量(KG)',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-right border-dashed-bottom'
+          },
+          {
+            label: '合格数',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-right border-dashed-bottom'
+          },
+          {
+            label: '不合格数',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-bottom'
+          },
+
+          {
+            label: '设备号',
+            key: 'xxx',
+            span: 8,
+            class: 'border-dashed-right border-dashed-bottom'
+          },
+          {
+            label: '模具编号/型号',
+            key: 'xxx',
+            span: 8,
+            class: 'border-dashed-right border-dashed-bottom'
+          },
+          {
+            label: '舟皿名称',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-right border-dashed-bottom'
+          },
+          {
+            label: '舟皿数量',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-bottom'
+          },
+
+          {
+            label: '冲压次数',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-right'
+          },
+          {
+            label: '员工号',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-right'
+          },
+          {
+            label: '日期',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-right'
+          },
+          {
+            label: '清缸时长',
+            key: 'xxx',
+            span: 8
+          }
+        ],
+        // 自然干燥
+        drying: [
+          {
+            label: '干燥时长(分钟)',
+            key: 'xxx',
+            span: 8,
+            class: 'border-dashed-right border-dashed-bottom'
+          },
+          {
+            label: '合格数',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-right border-dashed-bottom'
+          },
+          {
+            label: '不合格数',
+            key: 'xxx',
+            span: 4,
+            class: ' border-dashed-right border-dashed-bottom'
+          },
+          {
+            label: '区域编号',
+            key: 'xxx',
+            span: 8,
+            class: 'border-dashed-bottom'
+          },
+
+          {
+            label: '周转车编码',
+            key: 'xxx',
+            span: 8,
+            class: 'border-dashed-right '
+          },
+          {
+            label: '员工号',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-right '
+          },
+          {
+            label: '日期',
+            key: 'xxx',
+            span: 8
+          }
+        ],
+        // 升温燥
+        temperature: [
+          {
+            label: '升温曲线',
+            key: 'xxx',
+            span: 8,
+            class: 'border-dashed-right border-dashed-bottom'
+          },
+          {
+            label: '干燥时长(分钟)',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-right border-dashed-bottom'
+          },
+          {
+            label: '合格数',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-right border-dashed-bottom'
+          },
+          {
+            label: '不合格数',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-right border-dashed-bottom'
+          },
+          {
+            label: '设备号',
+            key: 'xxx',
+            span: 4,
+            class: ' border-dashed-bottom'
+          },
+
+          {
+            label: '周转车编码',
+            key: 'xxx',
+            span: 8,
+            class: 'border-dashed-right'
+          },
+          {
+            label: '员工号',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-right'
+          },
+          {
+            label: '日期',
+            key: 'xxx',
+            span: 8
+          }
+        ],
+        // 半加定长
+        halflong: [
+          {
+            label: '长度(mm)',
+            key: 'xxx',
+            span: 8,
+            class: 'border-dashed-right border-dashed-bottom'
+          },
+          {
+            label: '合格数',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-right border-dashed-bottom'
+          },
+          {
+            label: '不合格数',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-right border-dashed-bottom'
+          },
+          {
+            label: '设备号',
+            key: 'xxx',
+            span: 8,
+            class: ' border-dashed-bottom'
+          },
+
+          {
+            label: '舟皿名称',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-right'
+          },
+          {
+            label: '舟皿数量',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-right'
+          },
+          {
+            label: '员工号',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-right'
+          },
+          {
+            label: '日期',
+            key: 'xxx',
+            span: 8
+          }
+        ],
+        // 备炉
+        furnace: [
+          {
+            label: '产品数量',
+            key: 'xxx',
+            span: 8,
+            class: 'border-dashed-right'
+          },
+          {
+            label: '设备号',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-right'
+          },
+          {
+            label: '员工号',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-right'
+          },
+          {
+            label: '日期',
+            key: 'xxx',
+            span: 8,
+            class: ' '
+          }
+        ],
+        // 烧结
+        sinter: [
+          {
+            label: '烧结曲线',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-right border-dashed-bottom'
+          },
+          {
+            label: '合格数',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-right border-dashed-bottom'
+          },
+          {
+            label: '合格数',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-right border-dashed-bottom'
+          },
+          {
+            label: '不合格数',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-right border-dashed-bottom'
+          },
+          {
+            label: '设备号',
+            key: 'xxx',
+            span: 8,
+            class: 'border-dashed-right border-dashed-bottom'
+          },
+          {
+            label: '员工号',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-right'
+          },
+          {
+            label: '日期',
+            key: 'xxx',
+            span: 8,
+            class: ''
+          }
+        ],
+        // 质检
+        quality: [
+          {
+            label: '半检结果',
+            key: 'xxx',
+            span: 12,
+            class: 'border-dashed-right border-dashed-bottom'
+          },
+          {
+            label: '员工号',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-right border-dashed-bottom'
+          },
+          {
+            label: '日期',
+            key: 'xxx',
+            span: 8,
+            class: 'border-dashed-bottom'
+          },
+          {
+            label: '成检结果',
+            key: 'xxx',
+            span: 12,
+            class: 'border-dashed-right border-dashed-bottom'
+          },
+          {
+            label: '员工号',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-right border-dashed-bottom'
+          },
+          {
+            label: '日期',
+            key: 'xxx',
+            span: 8,
+            class: 'border-dashed-bottom'
+          },
+          {
+            label: '外径',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-right border-dashed-bottom'
+          },
+          {
+            label: '长度',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-right border-dashed-bottom'
+          },
+          {
+            label: '垂直度',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-right border-dashed-bottom'
+          },
+          {
+            label: '圆度',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-right border-dashed-bottom'
+          },
+          {
+            label: '跳动',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-bottom'
+          },
+          {
+            label: '抗拆/损伤',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-right border-dashed-bottom'
+          },
+          {
+            label: '直线度',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-right border-dashed-bottom'
+          },
+          {
+            label: '粗糙度',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-right border-dashed-bottom'
+          },
+          {
+            label: '其它',
+            key: 'xxx',
+            span: 4,
+            class: ' border-dashed-bottom border-dashed-right '
+          },
+          {
+            label: '合格数',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-right border-dashed-bottom'
+          },
+          {
+            label: '合格数',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-right border-dashed-bottom'
+          },
+          {
+            label: '待处理',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-right border-dashed-bottom'
+          },
+          {
+            label: '让步',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-right border-dashed-bottom'
+          },
+          {
+            label: '可修',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-bottom'
+          },
+          {
+            label: '员工号',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-right border-dashed-bottom'
+          },
+          {
+            label: '日期',
+            key: 'xxx',
+            span: 12,
+            class: 'border-dashed-bottom'
+          }
+        ],
+        // 深加工
+        deepProcesse: [
+          {
+            label: '合格数',
+            key: 'xxx',
+            span: 8,
+            class: 'border-dashed-right'
+          },
+          {
+            label: '不合格数',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-right'
+          },
+          {
+            label: '设备号',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-right'
+          },
+          {
+            label: '员工号',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-right'
+          },
+          {
+            label: '日期',
+            key: 'xxx',
+            span: 4,
+            class: ' '
+          }
+        ],
+        // 深加工
+        packageOpt: [
+          {
+            label: '包装要求',
+            key: 'xxx',
+            span: 24,
+            class: 'border-dashed-right border-dashed-bottom'
+          },
+          {
+            label: '包装单位',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-right border-dashed-bottom'
+          },
+          {
+            label: '包装数量',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-right border-dashed-bottom'
+          },
+          {
+            label: '最小包装单元',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-right border-dashed-bottom'
+          },
+          {
+            label: '净重',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-right border-dashed-bottom'
+          },
+          {
+            label: '毛重',
+            key: 'xxx',
+            span: 4,
+            class: ' border-dashed-bottom'
+          },
+          {
+            label: '物料编码',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-right border-dashed-bottom'
+          },
+          {
+            label: '物料名称',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-right border-dashed-bottom'
+          },
+          {
+            label: '物料数量',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-right border-dashed-bottom'
+          },
+          {
+            label: '尾料',
+            key: 'xxx',
+            span: 8,
+            class: 'border-dashed-right border-dashed-bottom'
+          },
+          {
+            label: '物料编码',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-right border-dashed-bottom'
+          },
+          {
+            label: '物料名称',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-right border-dashed-bottom'
+          },
+          {
+            label: '物料数量',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-right border-dashed-bottom'
+          },
+          {
+            label: '员工号',
+            key: 'xxx',
+            span: 8,
+            class: 'border-dashed-right border-dashed-bottom'
+          },
+          {
+            label: '日期',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-bottom'
+          }
+        ],
+        // 预缴库
+        preStorage: [
+          {
+            label: '产品数量',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-right border-dashed-bottom'
+          },
+          {
+            label: '员工号',
+            key: 'xxx',
+            span: 4,
+            class: 'border-dashed-right border-dashed-bottom'
+          },
+          {
+            label: '日期',
+            key: 'xxx',
+            span: 16,
+            class: ' border-dashed-bottom'
+          }
+        ]
+      };
+    },
+
+    methods: {
+      open () {
+        this.visible = true;
+        this.init();
+      },
+      init () {},
+      //打印
+      handlePrint () {
+        this.PrintLoading = true;
+        downloadPDF(this.$refs.pagesRef, 'l').then((res) => {
+          this.PrintLoading = false;
+        });
+      }
+    }
+  };
+</script>
+<style media="print" scoped>
+  @page {
+    size: auto; /* auto is the initial value */
+    margin-bottom: 10mm; /* this affects the margin in the printer settings */
+  }
+</style>
+<style scoped lang="scss">
+  $heihgt: 36px;
+  $border: 1px solid #ddd;
+  * {
+    box-sizing: border-box;
+  }
+  .bg {
+    background-color: #f1f1f1;
+    line-height: $heihgt - 2px;
+    height: $heihgt;
+  }
+
+  .border-dashed-right {
+    border-right: $border;
+  }
+  .border-dashed-bottom {
+    border-bottom: $border;
+  }
+  .main-data {
+    .bg {
+      text-align: center;
+      border-right: $border;
+      border-bottom: $border;
+    }
+
+    .value {
+      line-height: $heihgt - 2px;
+      height: $heihgt;
+      border-right: $border;
+      border-bottom: $border;
+    }
+    .code {
+      line-height: 2 * $heihgt;
+      height: 2 * $heihgt;
+      border-right: $border;
+      border-bottom: $border;
+      text-align: center;
+    }
+  }
+
+  .print-container {
+    border-top: $border;
+    border-left: $border;
+    border-right: $border;
+    font-size: 20px;
+  }
+
+  .processes-data {
+    .title {
+      color: #000;
+      font-weight: bold;
+    }
+    :deep(.el-col) {
+      line-height: $heihgt - 2px;
+      height: $heihgt;
+      padding-left: 10px;
+    }
+    .top {
+      border-top: $border;
+      border-bottom: $border;
+    }
+  }
+</style>

+ 77 - 0
src/utils/pdf.js

@@ -0,0 +1,77 @@
+import html2canvas from 'html2canvas';
+import jsPDF from 'jspdf';
+
+const ratio = 2.5; //放大 兼容低分辨率屏幕清晰度
+let pdf = null;
+export const downloadPDF = (page, direction) => {
+  // direction : 方向
+  return new Promise((resolve, reject) => {
+    let canvasList = [];
+    async function fn () {
+      await html2canvas(page, { scale: ratio }).then(function (canvas) {
+        canvasList.push(canvas);
+      });
+      canvasList.forEach((n) => {
+        canvas2PDF(n, direction);
+      });
+      pdf.save('条码.pdf');
+      const blob = pdf.output('blob');
+      var blob_url = URL.createObjectURL(blob);
+      window.open(blob_url);
+      pdf = null;
+      resolve();
+    }
+    fn();
+  });
+};
+
+const canvas2PDF = (canvas, direction = 'l') => {
+  // direction : 方向
+  let contentWidth = canvas.width;
+  let contentHeight = canvas.height;
+  let imgWidth = prasePxToCm(contentWidth);
+  let imgHeight = prasePxToCm(contentHeight);
+  // 第一个参数: l:横向  p:纵向
+  // 第二个参数:测量单位("pt","mm", "cm", "m", "in" or "px")
+  if (!pdf) {
+    pdf = new jsPDF(direction, 'cm', [imgWidth, imgHeight]);
+    pdf.addImage(
+      canvas.toDataURL('image/jpeg', 1.0),
+      'JPEG',
+      0,
+      0,
+      imgWidth,
+      imgHeight
+    );
+  } else {
+    pdf.addPage();
+    pdf.addImage(
+      canvas.toDataURL('image/jpeg', 1.0),
+      'JPEG',
+      0,
+      0,
+      imgWidth,
+      imgHeight
+    );
+  }
+};
+function prasePxToCm (px) {
+  var targetEleWidth = 1,
+    cm;
+  var createEle = document.createElement('input');
+  var body = document.getElementsByTagName('body');
+  createEle.setAttribute(
+    'style',
+    'width:1cm !important;height:1cm !important;border-width:0px !important;padding:0px !important;margin:10px !important;'
+  );
+  createEle.id = 'elementId_' + new Date().getTime();
+  createEle.type = 'hidden';
+  body[0].appendChild(createEle);
+  var targetEle = document.getElementById(createEle.id);
+  targetEleWidth = window
+    .getComputedStyle(targetEle)
+    .width.match(/^\d+\.?\d*/)[0];
+  cm = px / targetEleWidth / ratio;
+  targetEle.parentNode.removeChild(targetEle);
+  return cm.toFixed(3);
+}

Dosya farkı çok büyük olduğundan ihmal edildi
+ 305 - 248
src/views/produceOrder/detail.vue


+ 2 - 2
vue.config.js

@@ -31,12 +31,12 @@ module.exports = {
     proxy: {
       // 当我们的本地的请求 有/api的时候,就会代理我们的请求地址向另外一个服务器发出请求
       '/api': {
-        target: 'http://192.168.3.51:18086', // 测试
+        // target: 'http://192.168.3.51:18086', // 测试
 
         // target: 'http://192.168.3.35:8080', // kang杨威
         // target: 'http://192.168.3.25:8080', // 黄峥嵘
         // target: 'http://192.168.3.41:8080', // 何江鹏
-        // target: 'http://192.168.3.33:8080', // 谢一平
+        target: 'http://192.168.3.33:8080', // 谢一平
 
         changeOrigin: true, // 只有这个值为true的情况下 才表示开启跨域
         pathRewrite: {

Bu fark içinde çok fazla dosya değişikliği olduğu için bazı dosyalar gösterilmiyor