cz пре 1 година
родитељ
комит
394320316e

+ 3 - 2
package.json

@@ -1,8 +1,8 @@
 {
   "name": "ruoyi",
   "version": "3.8.5",
-  "description": "SANFAN MES制造执行系统",
-  "author": "SANFAN MES制造执行系统",
+  "description": "SANFAN MES",
+  "author": "SANFAN MES",
   "license": "MIT",
   "scripts": {
     "dev": "vite",
@@ -38,6 +38,7 @@
     "echarts-gl": "^2.0.9",
     "element-plus": "2.2.27",
     "file-saver": "^2.0.5",
+    "xlsx": "^0.18.5",
     "fuse.js": "6.6.2",
     "html2canvas": "^1.4.1",
     "jquery": "^3.7.0",

+ 1 - 0
src/assets/icons/svg/baojia.svg

@@ -0,0 +1 @@
+<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg t="1706440388644" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="32864" xmlns:xlink="http://www.w3.org/1999/xlink" width="300" height="300"><path d="M831.488 956.0064H203.776A50.176 50.176 0 0 1 153.6 905.728V152.6272C153.6 124.8768 176.128 102.4 203.776 102.4h512.3584l165.5296 175.7184v627.6608a50.176 50.176 0 0 1-50.176 50.176zM630.5792 265.5744L517.632 463.36 404.6336 265.5744h-75.264L467.3536 491.52H341.9136v62.7712h138.0352v62.7712H341.9136v62.7712h138.0352v112.9472h75.3152v-112.9472h138.0864v-62.7712h-138.0864v-62.7712h138.0864V491.52h-125.4912l138.0864-225.9456h-75.3152z m87.8592-112.9472v100.4032c0 13.824 11.264 25.088 25.088 25.088h100.4032l-125.4912-125.4912z" fill="#7566F0" p-id="32865"></path></svg>

Разлика између датотеке није приказан због своје велике величине
+ 0 - 0
src/assets/icons/svg/chuku.svg


Разлика између датотеке није приказан због своје велике величине
+ 0 - 0
src/assets/icons/svg/renling.svg


Разлика између датотеке није приказан због своје велике величине
+ 0 - 0
src/assets/icons/svg/ruku.svg


+ 1 - 0
src/assets/icons/svg/touchang.svg

@@ -0,0 +1 @@
+<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg t="1706432185326" class="icon" viewBox="0 0 1097 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="16019" xmlns:xlink="http://www.w3.org/1999/xlink" width="321.38671875" height="300"><path d="M641.314999 873.425705L361.938784 358.649162a200.208842 200.208842 0 0 0 37.724412-63.05366h286.004933l9.538887 9.592779c82.885922 83.90987 152.945543 135.807882 197.136997 135.268962 57.125538-0.377244 122.011526-32.928022 179.783767-111.287014l0.862273-1.077841a32.658562 32.658562 0 0 0-8.730507-45.269294 34.975919 34.975919 0 0 0-47.586651 7.922127c-46.347134 62.568631-83.694302 83.209274-124.54445 83.424841-24.251408 0-72.323086-40.850149-137.694103-105.412784V187.434225c72.053626-79.921861 125.460615-121.257038 138.125239-120.664226 39.933984 1.616761 71.999734 7.922126 126.107319 68.820105a35.083703 35.083703 0 0 0 48.502815 3.610766 32.33521 32.33521 0 0 0 4.796389-45.538755l-1.023948-1.239516C1005.409464 18.590536 941.43964 2.261255 892.290121 0.051682c-44.730374-1.886221-104.550512 47.856111-198.376514 153.10722l-8.461046 9.484995h-285.627689a205.75972 205.75972 0 0 0-194.01126-132.951605C92.155349 29.746184 0 119.045255 0 229.200538s92.155349 199.400462 205.75972 199.400461a354.501686 354.501686 0 0 0 48.502815-3.341305l239.71169 448.166011H0V1024h1097.349244v-150.574295z" p-id="16020" fill="#FF9315"></path></svg>

+ 2 - 1
src/components/process/SF/ContractChange.vue

@@ -563,7 +563,8 @@ const formConfig = computed(() => {
       propsTreeLabel: "deptName",
       propsTreeValue: "deptId",
       itemWidth: 50,
-      disabled: !isEditList.value,
+      disabled:
+        !isEditList.value || route.query.flowKey == "contract_update_flow",
       fn: () => {
         formData.data.contractProductList = [];
       },

+ 31 - 5
src/views/EHSD/saleContract/dailyReport/index.vue

@@ -22,24 +22,26 @@
           <el-button type="primary" @click="onQuery" class="query">搜索</el-button>
           <el-button @click="onReset">重置</el-button>
           <!-- <el-button @click="aa">定位到今日</el-button> -->
+          <el-button type="primary" @click="exportExcel">导出Excel</el-button>
+
         </el-form-item>
       </el-form>
     </div>
     <div style="background:#fff;padding:15px;margin-top:10px">
-      <el-table :data="sourceList.data" :height="tableHeight" style="width: 100%" v-loading="loading" border>
-        <el-table-column prop="groupName" label="组别" min-width="110" fixed="left" />
+      <el-table :data="sourceList.data" :height="tableHeight" style="width: 100%" v-loading="loading" border id="my-table">
+        <el-table-column prop="groupName" label="组别" width="110" fixed="left" />
         <el-table-column prop="saleUserName" label="业务员" width="80" fixed="left" />
 
         <template v-if="dayList && dayList.length>0">
-          <el-table-column v-for="col in dayList" :key="col" :label="col" align="center" :class-name="today==col?'isToday':''">
-            <el-table-column prop="address" label="系统" width="100" align="right" :class-name="today==col?'isToday':''">
+          <el-table-column v-for="col in dayList" :key="col" :label="col" align="center">
+            <el-table-column prop="address" label="系统" min-width="100" align="right">
               <template #default="{ row, $index }">
                 <div style="width: 100%" :class="today==col?'isToday':''" v-if="row[col] && row[col].sumContractAmount">
                   {{moneyFormat(row[col].sumContractAmount,2)}}
                 </div>
               </template>
             </el-table-column>
-            <el-table-column prop="address" label="聚水潭" width="100" align="right" :class-name="today==col?'isToday':''">
+            <el-table-column prop="address" label="聚水潭" min-width="100" align="right">
               <template #default="{ row, $index }">
                 <div style="width: 100%" :class="today==col?'isToday':''" v-if="row[col] && row[col].sumJstAmount">
                   {{moneyFormat(row[col].sumJstAmount,2)}}
@@ -116,6 +118,8 @@
 import byTable from "@/components/byTable/index";
 import { getMonthBetween } from "@/utils/date.js";
 import moment from "moment";
+import FileSaver from "file-saver";
+import * as XLSX from "xlsx";
 const { proxy } = getCurrentInstance();
 const tableHeight = ref(0);
 const getTableHeight = () => {
@@ -217,6 +221,28 @@ const aa = () => {
     eles[0].scrollIntoView();
   }
 };
+
+const exportExcel = () => {
+  proxy.msgTip("请稍后", 2);
+  const wb = XLSX.utils.table_to_book(document.querySelector("#my-table")); // 关联dom节点
+  /* get binary string as output */
+  const wbout = XLSX.write(wb, {
+    bookType: "xlsx",
+    bookSST: true,
+    type: "array",
+  });
+  try {
+    FileSaver.saveAs(
+      new Blob([wbout], {
+        type: "application/octet-stream",
+      }),
+      "销售报表.xlsx"
+    );
+  } catch (e) {
+    console.log(e, wbout);
+  }
+  return wbout;
+};
 </script>
 
 <style lang="scss" scoped>

+ 1 - 1
src/views/MES/supplementaryOrder/index.vue

@@ -337,7 +337,7 @@ getList();
   padding: 4px;
 }
 .tag-2 {
-  background: rgb(239 227 51);
+  background: rgb(255, 189, 131);
   color: #fff;
   border-radius: 2px;
   padding: 4px;

+ 311 - 39
src/views/index.vue

@@ -1,32 +1,149 @@
 <template>
-  <div class="app-container home">
+  <div class="app-container ">
     <div class="stat-warp">
+      <div style="margin-bottom:15px">
+        <TitleInfo :content="'工作事项'"></TitleInfo>
+      </div>
       <ul>
-        <li class="theme1" @click="toUrl('Backlog', 1)">
+        <li class="theme1" @click="toUrl(1)">
           <div class="num">{{ toBeProcessedData.total }}</div>
-          <div class="label">我的待审批</div>
+          <div class="label">待审批</div>
           <div class="icon-box">
             <i class="icon iconfont icon-iconm_waixht"></i>
           </div>
         </li>
-        <li class="theme2" @click="toUrl('DealWith', 2)">
+        <li class="theme2" @click="toUrl(2)">
           <div class="num">{{ haveInitiatedData.total }}</div>
-          <div class="label">我的发起(未结束)</div>
+          <div class="label">待报价</div>
+          <div class="icon-box">
+            <svg-icon :icon-class="'baojia'" className="svg-class1" />
+          </div>
+        </li>
+        <li class="theme3" @click="toUrl(3)">
+          <div class="num">{{ pushInfo.total }}</div>
+          <div class="label">待投产</div>
+          <div class="icon-box">
+            <svg-icon :icon-class="'touchang'" className="svg-class" />
+          </div>
+        </li>
+        <li class="theme4" @click="toUrl(4)">
+          <div class="num">{{ pushInfo.total }}</div>
+          <div class="label">待入库</div>
+          <div class="icon-box">
+            <svg-icon :icon-class="'ruku'" className="svg-class1" />
+          </div>
+        </li>
+        <li class="theme5" @click="toUrl(5)">
+          <div class="num">{{ pushInfo.total }}</div>
+          <div class="label">待出库</div>
           <div class="icon-box">
-            <i class="icon iconfont icon-iconm_wofqd"></i>
+            <svg-icon :icon-class="'chuku'" className="svg-class1" />
           </div>
         </li>
-        <li class="theme3">
+        <li class="theme6" @click="toUrl(6)">
           <div class="num">{{ pushInfo.total }}</div>
-          <div class="label">未读消息</div>
+          <div class="label">待认领</div>
           <div class="icon-box">
-            <i class="icon iconfont icon-iconm_unread"></i>
+            <svg-icon :icon-class="'renling'" className="svg-class1" />
           </div>
         </li>
       </ul>
+      <div class="table-card">
+        <el-card style="width:32%">
+          <TitleInfo :content="'待审批'"></TitleInfo>
+          <el-table :data="tableData" style="width: 100%" :height="tableHeight">
+            <el-table-column prop="date" label="Date" />
+            <el-table-column prop="name" label="Name" />
+            <el-table-column prop="address" label="Address" />
+          </el-table>
+
+        </el-card>
+        <el-card style="width:32%">
+          <TitleInfo :content="'待报价'"></TitleInfo>
+          <el-table :data="tableData" style="width: 100%" :height="tableHeight">
+            <el-table-column prop="date" label="Date" />
+            <el-table-column prop="name" label="Name" />
+            <el-table-column prop="address" label="Address" />
+          </el-table>
+
+        </el-card>
+        <el-card style="width:32%">
+          <TitleInfo :content="'待投产'"></TitleInfo>
+          <el-table :data="tableData" style="width: 100%" :height="tableHeight">
+            <el-table-column prop="date" label="Date" />
+            <el-table-column prop="name" label="Name" />
+            <el-table-column prop="address" label="Address" />
+          </el-table>
+
+        </el-card>
+      </div>
+
+      <div class="table-card ">
+        <el-card style="width:32%">
+          <TitleInfo :content="'待入库'"></TitleInfo>
+          <el-table :data="tableData" style="width: 100%" :height="tableHeight">
+            <el-table-column prop="date" label="Date" />
+            <el-table-column prop="name" label="Name" />
+            <el-table-column prop="address" label="Address" />
+          </el-table>
+
+        </el-card>
+        <el-card style="width:32%">
+          <TitleInfo :content="'待出库'"></TitleInfo>
+          <el-table :data="tableData" style="width: 100%" :height="tableHeight">
+            <el-table-column prop="date" label="Date" />
+            <el-table-column prop="name" label="Name" />
+            <el-table-column prop="address" label="Address" />
+          </el-table>
+
+        </el-card>
+        <el-card style="width:32%">
+          <TitleInfo :content="'待认领'"></TitleInfo>
+          <el-table :data="tableData" style="width: 100%" :height="tableHeight">
+            <el-table-column prop="date" label="Date" />
+            <el-table-column prop="name" label="Name" />
+            <el-table-column prop="address" label="Address" />
+          </el-table>
+
+        </el-card>
+      </div>
+
     </div>
     <div class="table-warp">
-      <div class="card odd">
+      <div style="margin-bottom:15px">
+        <TitleInfo :content="'监控告警'"></TitleInfo>
+      </div>
+      <el-card style="margin-bottom:20px">
+        <TitleInfo :content="'逾期订单'"></TitleInfo>
+        <el-table :data="tableData" style="width: 100%" :height="tableHeightOne">
+          <el-table-column prop="date" label="Date" />
+          <el-table-column prop="name" label="Name" />
+          <el-table-column prop="address" label="Address" />
+        </el-table>
+      </el-card>
+      <el-card style="margin-bottom:20px">
+        <TitleInfo :content="'报损情况(近30天)'"></TitleInfo>
+        <div class="baosun">
+          <div class="theme2 q" @click="toUrl(7)">
+            <span class="label">补单</span>
+            <span class="num">{{ toBeProcessedData.total }}</span>
+          </div>
+          <div class="theme3 q" @click="toUrl(7)">
+            <span class="label">丢失</span>
+            <span class="num">{{ haveInitiatedData.total }}</span>
+          </div>
+        </div>
+      </el-card>
+      <el-card>
+        <TitleInfo :content="'设备运行情况'"></TitleInfo>
+        <div style="display:flex;align-items:center">
+          <div style="width:100px;font-size:12px">
+            设备名称:设备1 <br><br> 当天标刻数量:10<br><br>在线工作时长(分钟):1000
+          </div>
+          <div style="height:190px;width:calc(100% - 100px)" ref="pie_1"></div>
+        </div>
+      </el-card>
+      <!-- <div class="card odd">
         <div class="commons-title">我的待审批</div>
         <el-table :data="toBeProcessedData.rows" style="width: 100%">
           <el-table-column prop="flowName" label="流程类型" width="100" />
@@ -69,7 +186,7 @@
             <div class="content">{{ i.content }}</div>
           </li>
         </ul>
-      </div>
+      </div> -->
     </div>
     <!-- <byTableDemo></byTableDemo> -->
     <!-- <el-input type="number" v-model='aaa' v-mousewheel></el-input> -->
@@ -82,6 +199,18 @@ import { createApp, onMounted, ref } from "vue";
 import byTableDemo from "../components/byTable/demo";
 import html2canvas from "html2canvas";
 import JsPDF from "jspdf";
+import * as echarts from "echarts";
+
+const tableHeight = ref(0);
+const tableHeightOne = ref(0);
+const getTableHeight = () => {
+  tableHeight.value = (window.innerHeight - 390) / 2;
+  tableHeightOne.value = window.innerHeight - 610;
+};
+getTableHeight();
+window.addEventListener("resize", () => {
+  getTableHeight();
+});
 
 const aaa = ref(1);
 function goTarget(url) {
@@ -192,26 +321,110 @@ const getData = () => {
       pushInfo.value = res;
     });
 };
-const toUrl = (name, type) => {
+const toUrl = (att) => {
   //获取name为name的路由的基础信息
   // const route = proxy.$router.resolve({ name: name, params: {} });
-  if (type === 1) {
-    proxy.$router.push({
-      name,
-      query: {},
-    });
-  } else if (type === 2) {
-    proxy.$router.push({
-      name,
-      query: {
-        type: 1,
-      },
-    });
-  }
+
+  let pageObj = {
+    1: "Backlog",
+    2:
+      proxy.useUserStore().user.companyId == "100"
+        ? "PriceSheetEHSD"
+        : "PriceSheetEstimate",
+    3: "ProductionOrder",
+    4: "WaitingForStorage",
+    5: "WaitingForDelivery",
+    6: "Claim",
+    7: "SupplementaryOrder",
+  };
+
+  proxy.$router.push({
+    name: pageObj[att],
+  });
 };
 getData();
 // ​
-onMounted(() => {});
+const getOption = () => {
+  return {
+    title: {
+      show: true,
+      text: "",
+      bottom: "0%",
+      left: "center",
+      textStyle: {
+        color: "#fff",
+        fontSize: 12,
+        fontWeight: 400,
+      },
+    },
+    tooltip: {
+      trigger: "item",
+    },
+    grid: {
+      show: false,
+      bottom: 0,
+    },
+    // legend: {
+    //   top: "0%",
+    //   left: "center",
+    // },
+    series: [
+      {
+        name: "设备1",
+        type: "pie",
+        // center: ["50%", "50%"],
+        radius: ["45%", "75%"],
+        top: "0%",
+        bottom: "0%",
+        avoidLabelOverlap: false,
+        label: {
+          show: false,
+          position: "center",
+        },
+        emphasis: {
+          label: {
+            show: true,
+            fontSize: 14,
+            fontWeight: "bold",
+            color: "#fff",
+          },
+        },
+        labelLine: {
+          show: false,
+        },
+        data: [
+          {
+            value: 1000,
+            name: "工作时长",
+            itemStyle: {
+              color: "#F9CB19",
+            },
+          },
+          {
+            value: 440,
+            name: "",
+            itemStyle: {
+              color: "#268EFF",
+            },
+          },
+        ],
+      },
+    ],
+  };
+};
+
+const pie_1 = ref(null);
+let pie_1Chart = null;
+let option1 = {};
+onMounted(() => {
+  option1 = getOption();
+  pie_1Chart = echarts.init(pie_1.value);
+  window.addEventListener("resize", () => {
+    pie_1Chart.resize();
+  });
+  pie_1Chart.setOption(option1);
+  pie_1Chart.resize();
+});
 </script>
 <style>
 .table-warp .el-table .cell {
@@ -220,7 +433,11 @@ onMounted(() => {});
 </style>
 <style scoped lang="scss">
 .app-container {
-  height: 100%;
+  display: flex;
+  width: 100vw;
+  padding: 10px;
+  font-size: 14px !important;
+  // height: 100%;
   .announcement {
     padding: 0;
     margin: 0;
@@ -245,9 +462,36 @@ onMounted(() => {});
     }
   }
   .table-warp {
+    width: 400px;
     //页面全屏,占据剩下的位置
-    height: calc(100% - 137px);
-    border-radius: 5px;
+    height: calc(100vh - 120px);
+    background: #fff;
+    padding: 10px;
+    // border-radius: 5px;
+    .baosun {
+      display: flex;
+      justify-content: space-between;
+      margin-top: 15px;
+      .q {
+        padding: 10px;
+        min-width: 150px;
+        display: flex;
+        cursor: pointer;
+        justify-content: space-between;
+        border-radius: 10px;
+        .num {
+          font-size: 20px;
+          font-weight: 700;
+        }
+      }
+      .theme2 {
+        background: linear-gradient(180deg, #eae8fb 0%, #ded9ff 100%);
+      }
+      //#FFF1E1 #FF9315
+      .theme3 {
+        background: #fff1e1;
+      }
+    }
 
     .card {
       height: calc(50% - 10px);
@@ -275,12 +519,16 @@ onMounted(() => {});
     }
   }
   .stat-warp {
-    margin-bottom: 10px;
+    width: calc(100% - 400px - 10px);
+    height: calc(100vh - 120px);
+    margin-right: 10px;
+    // margin-bottom: 10px;
     background: #fff;
-    padding: 20px;
-    overflow: hidden;
-    position: relative;
-    border-radius: 5px;
+    padding: 10px;
+    // padding: 20px;
+    // overflow: hidden;
+    // position: relative;
+    // border-radius: 5px;
 
     .title {
       height: 60px;
@@ -304,17 +552,23 @@ onMounted(() => {});
     }
     ul {
       padding: 0;
-      overflow: hidden;
+      // overflow: hidden;
       margin: 0;
+      display: flex;
+      width: 100%;
+      flex-wrap: nowrap;
+      overflow: hidden;
+      justify-content: space-between;
       li {
+        flex: 1;
         list-style: none;
-        min-width: 285px;
+        min-width: 150px;
         box-sizing: border-box;
         margin-right: 20px;
         background: linear-gradient(360deg, #c7e3fe 0%, #dfecff 100%);
-        float: left;
-        overflow: hidden;
-        padding: 20px;
+        // float: left;
+        // overflow: hidden;
+        padding: 10px;
         color: #333333;
         position: relative;
         border-radius: 10px;
@@ -421,6 +675,24 @@ onMounted(() => {});
       }
     }
   }
+  .table-card {
+    display: flex;
+    justify-content: space-between;
+    margin-top: 20px;
+  }
+}
+
+:deep(
+    .el-table .el-table__header-wrapper th,
+    .el-table .el-table__fixed-header-wrapper th
+  ) {
+  height: auto !important;
+}
+.svg-class {
+  font-size: 16px;
+}
+.svg-class1 {
+  font-size: 19px;
 }
 </style>
 

+ 3 - 10
src/views/process/processApproval/index.vue

@@ -12,15 +12,6 @@
           <PriceSheet ref="makeDom" :queryData="queryData.data"></PriceSheet>
         </template>
 
-        <!-- 样品单 -->
-        <template v-else-if="flowForm.flowKey == 'sample_flow'">
-          <SampleEHSD ref="makeDom" :queryData="queryData.data"></SampleEHSD>
-        </template>
-        <!-- 样品单变更 -->
-        <template v-else-if="flowForm.flowKey == 'sample_update_flow'">
-          <SampleChangeEHSD ref="makeDom" :queryData="queryData.data"></SampleChangeEHSD>
-        </template>
-
         <!-- 销售合同 -->
         <Contract ref="makeDom" :queryData="queryData.data" v-else-if="flowForm.flowKey == 'contract_flow'"></Contract>
 
@@ -153,7 +144,6 @@ import useTagsViewStore from "@/store/modules/tagsView.js";
 import { useRouter, useRoute } from "vue-router";
 
 import PriceSheet from "@/components/process/SF/PriceSheet";
-
 import Contract from "@/components/process/SF/Contract";
 import ContractChange from "@/components/process/SF/ContractChange";
 
@@ -161,6 +151,9 @@ import Subscribe from "@/components/process/SF/Subscribe";
 import Purchase from "@/components/process/SF/Purchase";
 import PurchaseChange from "@/components/process/SF/PurchaseChange";
 
+import PurchasePayment from "@/components/process/PurchasePayment";
+import SendFunds from "@/components/process/SendFunds";
+
 // 消息提示
 import { ElMessage, ElMessageBox } from "element-plus";
 //决策辅助

+ 4 - 3
src/views/process/processConfig/index.vue

@@ -1,9 +1,9 @@
 <template>
   <div class="user">
-    <div class="tree">
+    <!-- <div class="tree">
       <treeList :data="treeListData" v-model="sourceList.pagination.tenantId" node-key="id" @change="treeChange">
       </treeList>
-    </div>
+    </div> -->
     <div class="content">
       <byTable :source="sourceList.data" :pagination="sourceList.pagination" :config="config" :loading="loading" highlight-current-row
                :selectConfig="selectConfig" :table-events="{
@@ -351,7 +351,8 @@ getList();
     width: 300px;
   }
   .content {
-    width: calc(100% - 310px);
+    width: 100%;
+    // width: calc(100% - 310px);
   }
 }
 </style>

Неке датотеке нису приказане због велике количине промена