#
whycq
2022-05-12 1423cf4834aa03da31ed75a0757268a4c3939154
#
1个文件已添加
1个文件已修改
100 ■■■■■ 已修改文件
Monitor-APP/pages/index/data.js 30 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Monitor-APP/pages/index/index.vue 70 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Monitor-APP/pages/index/data.js
New file
@@ -0,0 +1,30 @@
 // {"msg":"操作成功","code":200,"data":"拣料出库(4426)\n源库位:1200101\n目标站:186\n1101842-10000-22047518517\n\n"}
 // "拣料出库(4426)\n源库位:1200101\n目标站:186\n1101842-10000-22047518517\n\n"
// {"msg":"操作成功",
//     "code":200,
//     "data":[{
//         "title":"全板出库",
//         "workNo":7016,
//         "ioType":101, 101 全板出库  103 检料出库
//         "staNo":181,
//         "sourceStaNo":null,
//         "locNo":null,
//         "sourceLocNo":"0900107",
//         "matDtos":[
//             {"matnr":"1100349-10000","maknx":"C5S-4-M03/333/KS","batch":"22037502300","count":1.0},
//             {"matnr":"1100349-10000","maknx":"C5S-4-M03/333/KS","batch":"22037505146","count":1.0},
//             {"matnr":"1100349-10000","maknx":"C5S-4-M03/333/KS","batch":"22027504801","count":1.0},
//             {"matnr":"1100349-10000","maknx":"C5S-4-M03/333/KS","batch":"22027507729","count":1.0},
//             {"matnr":"1100349-10000","maknx":"C5S-4-M03/333/KS","batch":"22027507727","count":1.0},
//             {"matnr":"1100349-10000","maknx":"C5S-4-M03/333/KS","batch":"22027507731","count":1.0},
//             {"matnr":"1100349-10000","maknx":"C5S-4-M03/333/KS","batch":"22027504807","count":1.0},
//             {"matnr":"1100349-10000","maknx":"C5S-4-M03/333/KS","batch":"22027504805","count":1.0},
//             {"matnr":"1100349-10000","maknx":"C5S-4-M03/333/KS","batch":"22027504797","count":1.0},
//             {"matnr":"1100349-10000","maknx":"C5S-4-M03/333/KS","batch":"22027504794","count":1.0},
//             {"matnr":"1100349-10000","maknx":"C5S-4-M03/333/KS","batch":"22027504791","count":1.0},
//             {"matnr":"1100349-10000","maknx":"C5S-4-M03/333/KS","batch":"22027504793","count":1.0},
//             {"matnr":"1100349-10000","maknx":"C5S-4-M03/333/KS","batch":"22037505141","count":1.0},
//             {"matnr":"1100349-10000","maknx":"C5S-4-M03/333/KS","batch":"22027507728","count":1.0},
//             {"matnr":"1100349-10000","maknx":"C5S-4-M03/333/KS","batch":"22027504810","count":1.0},
//             {"matnr":"1100349-10000","maknx":"C5S-4-M03/333/KS","batch":"22037505148","count":1.0}],
//             "emptyMk":false}]}
Monitor-APP/pages/index/index.vue
@@ -1,38 +1,8 @@
<template>
    <!-- {"msg":"操作成功","code":200,"data":"拣料出库(4426)\n源库位:1200101\n目标站:186\n1101842-10000-22047518517\n\n"} -->
    <!-- "拣料出库(4426)\n源库位:1200101\n目标站:186\n1101842-10000-22047518517\n\n" -->
    <!-- {"msg":"操作成功",
    "code":200,
    "data":[{
        "title":"全板出库",
        "workNo":7016,
        "ioType":101, 101 全板出库  103 检料出库
        "staNo":181,
        "sourceStaNo":null,
        "locNo":null,
        "sourceLocNo":"0900107",
        "matDtos":[
            {"matnr":"1100349-10000","maknx":"C5S-4-M03/333/KS","batch":"22037502300","count":1.0},
            {"matnr":"1100349-10000","maknx":"C5S-4-M03/333/KS","batch":"22037505146","count":1.0},
            {"matnr":"1100349-10000","maknx":"C5S-4-M03/333/KS","batch":"22027504801","count":1.0},
            {"matnr":"1100349-10000","maknx":"C5S-4-M03/333/KS","batch":"22027507729","count":1.0},
            {"matnr":"1100349-10000","maknx":"C5S-4-M03/333/KS","batch":"22027507727","count":1.0},
            {"matnr":"1100349-10000","maknx":"C5S-4-M03/333/KS","batch":"22027507731","count":1.0},
            {"matnr":"1100349-10000","maknx":"C5S-4-M03/333/KS","batch":"22027504807","count":1.0},
            {"matnr":"1100349-10000","maknx":"C5S-4-M03/333/KS","batch":"22027504805","count":1.0},
            {"matnr":"1100349-10000","maknx":"C5S-4-M03/333/KS","batch":"22027504797","count":1.0},
            {"matnr":"1100349-10000","maknx":"C5S-4-M03/333/KS","batch":"22027504794","count":1.0},
            {"matnr":"1100349-10000","maknx":"C5S-4-M03/333/KS","batch":"22027504791","count":1.0},
            {"matnr":"1100349-10000","maknx":"C5S-4-M03/333/KS","batch":"22027504793","count":1.0},
            {"matnr":"1100349-10000","maknx":"C5S-4-M03/333/KS","batch":"22037505141","count":1.0},
            {"matnr":"1100349-10000","maknx":"C5S-4-M03/333/KS","batch":"22027507728","count":1.0},
            {"matnr":"1100349-10000","maknx":"C5S-4-M03/333/KS","batch":"22027504810","count":1.0},
            {"matnr":"1100349-10000","maknx":"C5S-4-M03/333/KS","batch":"22037505148","count":1.0}],
            "emptyMk":false}]} -->
    <view class="container">
        <view class="floor-screen" :class="floorMove" >
            <view class="head">
                <text>自动仓库WCS监控平台</text>
                <text @click="port()">自动仓库WCS监控平台</text>
                <view class="time-tools">{{year}}-{{month}}-{{day}}&nbsp{{hours}}:{{minutes}}:{{seconds}}&nbsp{{week}}</view>
                <view class="button-left" @click="url()"></view>
                <view class="button-right" @click="ledId()"></view>
@@ -59,7 +29,7 @@
        </view>
        <view class="top-screen" :class="topMove">
            <view class="head">
                <text>自动仓库WCS监控平台</text>
                <text @click="port()">自动仓库WCS监控平台</text>
                <view class="time-tools">{{year}}-{{month}}-{{day}}&nbsp{{hours}}:{{minutes}}:{{seconds}}&nbsp{{week}}</view>
                <view class="button-left" @click="url()"></view>
                <view class="button-right" @click="ledId()"></view>
@@ -213,15 +183,22 @@
        <view>
            <!-- 输入url -->
            <uni-popup ref="url" type="dialog">
                <uni-popup-dialog ref="inputClose" mode="input" title="配置url" value=""
                <uni-popup-dialog ref="inputClose" mode="input" title="配置url" :value="baseUrl"
                    placeholder="示例:192.168.1.1" @confirm="baseUrlConfirm"></uni-popup-dialog>
            </uni-popup>
        </view>
        <view>
            <!-- 输入ledId -->
            <uni-popup ref="ledId" type="dialog">
                <uni-popup-dialog ref="inputClose" mode="input" title="配置ledId" value=""
                <uni-popup-dialog ref="inputClose" mode="input" title="配置ledId" :value="baseLedId"
                    placeholder="示例:188" @confirm="ledIdConfirm"></uni-popup-dialog>
            </uni-popup>
        </view>
        <view>
            <!-- 输入port -->
            <uni-popup ref="port" type="dialog">
                <uni-popup-dialog ref="inputClose" mode="input" title="配置端口号" :value="basePort"
                    placeholder="示例:9090" @confirm="portConfirm"></uni-popup-dialog>
            </uni-popup>
        </view>
    </view>
@@ -237,6 +214,7 @@
                styles: {},
                baseUrl:'10.10.0.200',
                baseLedId:'',
                basePort:'',
                value: '',
                xDistance: 0,
                yDistance:0,
@@ -282,19 +260,15 @@
            let that = this
            const BaseUrl = uni.getStorageSync('BaseUrl');
            const BaseLedId = uni.getStorageSync('BaseLedId');
            const BasePort = uni.getStorageSync('BasePort');
            if (BaseUrl && BaseLedId) {
                that.baseUrl = BaseUrl
                that.baseLedId = BaseLedId
                that.basePort = BasePort
            } else {
                that.baseUrl = ''
                that.baseLedId = ''
            }
        },
        onLoad() {
            var that=this
            plus.runtime.getProperty( plus.runtime.appid, function ( wgtinfo ) {
                that.version=wgtinfo.version
            });
        },
        onReady() {
            setTimeout(() => {
@@ -313,11 +287,17 @@
                this.animation();
            },1000)
        },
        onLoad() {
            // var that=this
            // plus.runtime.getProperty( plus.runtime.appid, function ( wgtinfo ) {
            //     that.version=wgtinfo.version
            // });
        },
        methods: {
            getPakin () {
                let that = this
                uni.request({
                    url: "http://" + that.baseUrl + ":9090/jkwcs/monitor/led",
                    url: "http://" + that.baseUrl + ":" + that.basePort + "/jkwcs/monitor/led",
                    data: {
                        ledId:that.baseLedId
                    },
@@ -413,12 +393,14 @@
                    }
                })
            },
            port() {
                this.$refs.port.open()
            },
            url() {
                this.$refs.url.open()
            },
            ledId() {
                this.$refs.ledId.open()
                // this.$refs.ledId.open()
            },
            baseUrlConfirm(val) {
                this.baseUrl = val
@@ -428,6 +410,10 @@
                this.baseLedId = val
                uni.setStorageSync('BaseLedId', this.baseLedId);
            },
            portConfirm(val) {
                this.basePort = val
                uni.setStorageSync('BasePort',this.basePort);
            },
            getServerData() {
                this.chartsDataLine1=JSON.parse(JSON.stringify(this.chartsData.Line))
                this.chartsDataPie2=JSON.parse(JSON.stringify(this.chartsData.Pie))