#
lty
2025-09-16 eb05511cce839cafc4dee453c94f41e0dd52bce5
Monitor-APP/pages/home/home.vue
@@ -215,11 +215,15 @@
                     <view class="text-content">
                        <!-- head -->
                        <view class="swiper-head">
                           <view style="width: 25%;">目标站:{{infoText.staNo}}</view>
                           <view style="width: 25%;">商品编号</view>
                           <view style="width: 25%;">商品名称</view>
                           <!-- <view style="width: 20%;">规格</view> -->
                           <view style="width: 25%;">数量</view>
                           <view style="width: 10vw;">目标站:{{infoText.staNo}}</view>
                           <view style="flex: 1;">商品编号</view>
                           <view style="flex: 1;">商品名称</view>
                           <view style="flex: 1;">规格</view>
                           <!-- <view style="flex: 1;">批号</view> -->
                           <view style="width: 10vw;">数量</view>
                           <!-- <view style="flex: 1;">箱码</view> -->
                           <view style="width: 10vw;">库存数量</view>
                           <view style="width: 10vw;">现存数量</view>
                        </view>
                        <!-- body -->
                        <view class="swiper-body">
@@ -231,11 +235,14 @@
                           display-multiple-items="8"
                           circular="true" :autoplay="true" :interval="3000" :duration="1000">
                              <swiper-item class="swiper-item" v-for="(item,i) in swiperList" :key="i">
                                 <view style="width: 25%;">No:{{i+1}}</view>
                                 <view style="width: 25%;">{{item.matNo}}</view>
                                 <view style="width: 25%;">{{item.maknx}}</view>
                                 <!-- <view style="width: 20%;">{{item.specs}}</view> -->
                                 <view style="width: 25%;">{{item.count}}</view>
                                 <view style="width: 10vw;">No:{{i+1}}</view>
                                 <view style="flex: 1;">{{item.matNo}}</view>
                                 <view style="flex: 1;">{{item.maknx}}</view>
                                 <view style="flex:1">{{item.specs}}</view>
                                 <view style="width: 10vw;">{{item.count}}</view>
                                 <!-- <view style="flex: 1;">{{item.zpallet}}</view> -->
                                 <view style="width: 10vw;">{{item.anfme}}</view>
                                 <view style="width: 10vw;">{{parseInt(item.anfme) - parseInt(item.count)}}</view>
                              </swiper-item>
                           </swiper>
                        </view>
@@ -245,9 +252,9 @@
            </view>
         </view>
         <!-- <view class="btn"> -->
            <!-- <button >拣料回库</button> -->
            <!-- <button  size="mini" type="primary" @click="">拣料回库</button> -->
         <!-- </view> -->
            <!-- <button >拣料回库</button>
            <button  size="mini" type="primary" @click="">盘点回库</button>
         </view> -->
      </uni-transition>
      <!-- 异常信息 -->
      <uni-transition :duration="duration" :mode-class="errorInfoMode" :show="errorInfoViewShow">
@@ -329,6 +336,7 @@
   export default {
      data() {
         return {
            commonUrl: '',
            series: [],
            homeViewShow: true,
            infoViewShow: false   ,
@@ -418,28 +426,43 @@
         that.baseLedId = BaseLedId
         that.basePort = BasePort
         that.baseCrnId = BaseCrnId
         // this.getUrl()
         this.getDate2()
         setTimeout(()=>{
            this.getServerData()
            this.initlineChart()
            this.initPieChart()
            this.getOther()
            setTimeout(()=>{
               this.getServerData()
               this.initlineChart()
               this.initPieChart()
               this.getOther()
               setTimeout(()=>{
                  this.getServerData()
                  this.initlineChart()
                  this.initPieChart()
                  this.getOther()
               },500)
            },500)
         },500)
      },
      onLoad() {
         this.getServerData()
         this.initlineChart()
         this.initPieChart()
         this.getOther()
         this.getDate2()
         this.getUrl()
         setInterval(()=>{
            this.getServerData()
            this.getDate2()
            this.getUrl()
            this.getInfo()
            this.getError()
            // this.getInfo2()
            // this.getError2()
            this.controller()
         },1000)
         setInterval(()=>{
            this.getServerData()
            this.initlineChart()
            this.initPieChart()
            this.getOther()
            this.getDate2()
         },600000)
      },
      methods: {
@@ -490,7 +513,91 @@
               data: {ledId:that.baseLedId},
               success(result) {
                  var   res = result.data
                  that.infoModel(res)
                  const res1 = {
                    "data": [
                     {
                       "ioType": 103,
                       "staNo": "STA002",
                       "workNo": "8888",
                       "matDtos": [
                        {
                          "matnr": "0050950010050001",
                          "maknx": "小厨房",
                          "proType":"电镀",
                          "batch": null,
                          "specs": "Φ35",
                          "orderNo": "WHIN2503000101",
                          "outOrderNo": "BYM2024-1007SN高霖",
                          "unit": "pcs",
                          "weight": 450,
                          "objectName": "Φ35铜小厨房",
                          "length": 20,
                          "temp1": "二号星河空心单孔(不带孔、M8螺纹孔)",
                          "temp2": "1007SN高霖",
                          "count": 1000,
                          "anfme": 1000,
                          "factArea": "高霖工厂"
                        },
                        {
                          "matnr": "0050950010050002",
                          "proType":"电镀",
                          "maknx": "大厨房",
                          "batch": "B20240521A",
                          "specs": "Φ45",
                          "orderNo": "WHIN2503000102",
                          "outOrderNo": "BYM2024-1008SN高霖",
                          "unit": "pcs",
                          "weight": 520,
                          "objectName": "Φ45铜大厨房",
                          "length": 22,
                          "temp1": "D1075000入墙喷枪龙头(57铜、体抛砂、2个螺丝孔)SH095",
                           "temp2": "1007SN高霖",
                          "count": 800,
                          "anfme": 800,
                          "factArea": "中扬工厂"
                        },
                        {
                          "matnr": "0050950010050003",
                          "proType":"电镀",
                          "maknx": "浴室配件",
                          "batch": "B20240521B",
                          "specs": "Φ28",
                          "orderNo": "WHIN2503000103",
                          "outOrderNo": "BYM2024-1009SN高霖",
                          "unit": "套",
                          "weight": 300,
                          "objectName": "Φ28镀铬套件",
                          "length": 18,
                          "temp1": "Φ28镀铬套件",
                           "temp2": "1007SN高霖",
                          "count": 600,
                          "anfme": 600,
                          "factArea": "中扬工厂"
                        },
                        {
                          "matnr": "0050950010050004",
                          "proType":"电镀",
                          "maknx": "门把手",
                          "batch": null,
                          "specs": "L200*W30",
                          "orderNo": "WHIN2503000104",
                          "outOrderNo": "BYM2024-1010SN高霖",
                          "unit": "个",
                          "weight": 180,
                          "objectName": "黑色铝门把手",
                          "length": 20,
                          "temp1": "黑色铝门把手",
                           "temp2": "1007SN高霖",
                          "count": 300,
                          "anfme": 300,
                          "factArea": "中扬工厂"
                        }
                       ]
                     }
                    ]
                  }
                  that.infoModel(res1)
               }
            })
            
@@ -529,6 +636,7 @@
         infoModel(res) {
            let that = this
            if (res.data && res.data !== "") {
               that.infoText.title = res.data[0].title
               if (that.infoType == 2 || that.infoType == 3) {
                  return;
               }
@@ -737,11 +845,14 @@
               success(result) {
                  var res = result.data
                  if (res.code === 200) {
                     that.chartsData.Line.categories = [
                        that.getDateFormat(-11),that.getDateFormat(-10),that.getDateFormat(-9),that.getDateFormat(-8),
                        that.getDateFormat(-7),that.getDateFormat(-6),that.getDateFormat(-5),that.getDateFormat(-4),
                        that.getDateFormat(-3),that.getDateFormat(-2),that.getDateFormat(-1),that.getDateFormat(0),]
                     that.chartsData.Line.series = res.data.rows
                     setTimeout(()=> {
                        that.chartsData.Line.categories = [
                           that.getDateFormat(-11),that.getDateFormat(-10),that.getDateFormat(-9),that.getDateFormat(-8),
                           that.getDateFormat(-7),that.getDateFormat(-6),that.getDateFormat(-5),that.getDateFormat(-4),
                           that.getDateFormat(-3),that.getDateFormat(-2),that.getDateFormat(-1),that.getDateFormat(0),]
                        that.chartsData.Line.series = res.data.rows
                     },1000)
                  }
               }
            })
@@ -776,7 +887,7 @@
            uni.request({
               url: that.commonUrl + "/monitor/other",
               data: {
                  crnId: that.baseCrnId,
                  crnId: that.baseCrnId,
                  ledId: that.baseLedId,
               },
               success(result) {