whychdw
2021-07-31 bf29f1dea2b4c4d3aeaffc380b129793f11e91f2
Merge branch 'hdw' of http://118.89.139.230:10101/r/admin_manage into hdw
5个文件已修改
262 ■■■■■ 已修改文件
src/assets/js/const/const_aio.js 14 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/pages/dataTest/components/activateDialogContent.vue 64 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/pages/dataTest/js/draw_diagram.js 174 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/pages/dataTest/realTimeAio.vue 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
项目需求.md 8 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/assets/js/const/const_aio.js
@@ -175,11 +175,11 @@
        },
        //放电时长
        DisTime: {
            pattern: /^[0-9]{1,3}(\.[0-9]{0,3})?$/,
            pattern: /^[0-9]{1,4}(\.[0-9]{0,3})?$/,
            regVal: true,
            min: 0,
            max: 500,
            msg: '取值范围0~500'
            max: 6000,
            msg: '取值范围0~6000'
        },
        //充完静置
        DisWaitTime: {
@@ -215,7 +215,7 @@
        },
        //单体上限数量
        MonVolHightLimitCount: {
            pattern: /^[0-9]{1,3}(\.[0-9]{0,3})?$/,
            pattern: /^[0-9]{1,3}$/,
            regVal: true,
            min: 1,
            max: 300,
@@ -223,11 +223,11 @@
        },
        //单体下限数量
        MonomerLowCount: {
            pattern: /^[0-9]{1,3}(\.[0-9]{0,3})?$/,
            pattern: /^[0-9]{1,3}$/,
            regVal: true,
            min: 1,
            max: 240,
            msg: '取值范围0~240'
            max: 300,
            msg: '取值范围1~300'
        },
        //放电过温
        MonomerTmp_High: {
src/pages/dataTest/components/activateDialogContent.vue
@@ -53,8 +53,8 @@
                                </el-form-item>
                            </div>
                            <div class="table-cell pr16">
                                <el-form-item label="浮充电压(V)" prop="AutoTestStartVol">
                                    <el-input v-model="params.AutoTestStartVol"></el-input>
                                <el-form-item label="充电时长(分钟)" prop="CharTimeLong">
                                    <el-input v-model="params.CharTimeLong"></el-input>
                                </el-form-item>
                            </div>
                            <!-- <div class="table-cell">
@@ -65,8 +65,18 @@
                        </div>
                        <div class="table-row">
                            <div class="table-cell pr16">
                                <el-form-item label="截止电流(A)" prop="CharSotpCurr">
                                <el-form-item label="浮充电压(V)" prop="AutoTestStartVol">
                                    <el-input v-model="params.AutoTestStartVol"></el-input>
                                </el-form-item>
                            </div>
                            <div class="table-cell pr16">
                                <el-form-item label="浮充电流(A)" prop="CharSotpCurr">
                                    <el-input v-model="params.CharSotpCurr"></el-input>
                                </el-form-item>
                            </div>
                            <div class="table-cell pr16">
                                <el-form-item label="浮充时长(分钟)" prop="FloatCharTimeLong">
                                    <el-input v-model="params.FloatCharTimeLong"></el-input>
                                </el-form-item>
                            </div>
                            <!-- <div class="table-cell pr16">
@@ -74,31 +84,21 @@
                                    <el-input v-model.number="params.CharCap"></el-input>
                                </el-form-item>
                            </div> -->
                        </div>
                        <div class="table-row">
                            <div class="table-cell pr16">
                                <el-form-item label="单体上限(V)" prop="MonVolHightLimit">
                                    <el-input v-model="params.MonVolHightLimit"></el-input>
                                </el-form-item>
                            </div>
                            <div class="table-cell">
                                <el-form-item label="组端上限(V)" prop="DCVolHighLimit">
                                    <el-input v-model="params.DCVolHighLimit"></el-input>
                                </el-form-item>
                            </div>
                        </div>
                        <div class="table-row">
                            <div class="table-cell pr16">
                                <el-form-item label="单体上限数量(个)" prop="MonVolHightLimitCount">
                                    <el-input v-model="params.MonVolHightLimitCount"></el-input>
                                </el-form-item>
                            </div>
                            <div class="table-cell pr16">
                                <el-form-item label="充电时长(分钟)" prop="CharTimeLong">
                                    <el-input v-model="params.CharTimeLong"></el-input>
                                </el-form-item>
                            </div>
                            <div class="table-cell pr16">
                                <el-form-item label="浮充时长(分钟)" prop="FloatCharTimeLong">
                                    <el-input v-model="params.FloatCharTimeLong"></el-input>
                                <el-form-item label="组端上限(V)" prop="DCVolHighLimit">
                                    <el-input v-model="params.DCVolHighLimit"></el-input>
                                </el-form-item>
                            </div>
                        </div>
@@ -287,6 +287,7 @@
} from "@/assets/js/const"
import config from "@/assets/js/config";
// import checkFace from "@/components/checkFace";
let rules = const_aio.dischargeRules;
export default {
    name: "dischargeParams",
    components: {
@@ -307,7 +308,6 @@
    data() {
        let cmd = const_aio.cmd;
        let testType = const_aio.testType;
        let rules = const_aio.dischargeRules;
        let cycleStart = const_aio.cycleStart;
        let HourRate = const_aio.HourRate;
        let batt = this.batt;
@@ -320,6 +320,14 @@
        rules.MonomerVol_Low.min = (batt.MonVolStd*0.9).toHold(1);
        rules.MonomerVol_Low.max = (batt.MonVolStd*1.2).toHold(1);
        rules.MonomerVol_Low.msg = "取值范围"+rules.MonomerVol_Low.min+"~"+rules.MonomerVol_Low.max+"(保留一位小数)";
        // å•体下限数量
        rules.MonomerLowCount.max = batt.MonCount;
        rules.MonomerLowCount.msg = "取值范围" + rules.MonomerLowCount.min + "~" + rules.MonomerLowCount.max;
        // å•体上限数量
        rules.MonVolHightLimitCount.max = batt.MonCount;
        rules.MonVolHightLimitCount.msg = '取值范围' + rules.MonVolHightLimitCount.min + '~' + rules.MonVolHightLimitCount.max;
        return {
            setFaceShow: false,
@@ -341,7 +349,7 @@
                CharTimeLong: 0,        //充电时长
                CharWaitTime: 0,        //放完静置
                ChargeCurrSet: 0,       //充电电流
                DCVolHighLimit: 0,      //组端上限
                DCVolHighLimit: 5,      //组端上限
                DisCap: 0,              //放电容量
                DisCurr: 0,             //放电电流
                DisPower: 0,            //预放功率
@@ -526,6 +534,22 @@
            },
        }
    },
    watch: {
        "params.OnLineVol_Low" (n) {
            // ä¿®æ”¹ç»„端上限的取值范围
            rules.DCVolHighLimit.min = n;
            rules.DCVolHighLimit.msg = "取值范围" + rules.DCVolHighLimit.min + "~" + rules.DCVolHighLimit.max;
            this.params.DCVolHighLimit = (n * 1 + 5) ? (n * 1 + 5) : 5;
            this.rules.DCVolHighLimit = [{
                validator(rule, value, callback) {
                    testVal(rule, value, callback, rules.DCVolHighLimit);
                },
                trigger: 'change'
            }];
        }
    },
    methods: {
        initParams() {
            // åˆå§‹åŒ–参数
@@ -538,7 +562,7 @@
                CharTimeLong: 0,        //充电时长
                CharWaitTime: 0,        //放完静置
                ChargeCurrSet: 0,       //充电电流
                DCVolHighLimit: 0,      //组端上限
                DCVolHighLimit: 5,      //组端上限
                DisCap: 0,              //放电容量
                DisCurr: 0,             //放电电流
                DisPower: 0,            //预放功率
src/pages/dataTest/js/draw_diagram.js
@@ -13,41 +13,6 @@
Img_load.src = loadImage;
Img_batt.src = battImage;
// console.log(Date.now(), 'init')
// if (Img_batt.complete) {
//     console.log(Date.now(), 'batt');
// } else {
//     Img_batt.addEventListener('load', () => {
//         console.log(Date.now(), 'batt load');
//     });
// }
// let Img_screen = 'url(' + screenImage + ')';
// let Img_load = 'url(' + loadImage + ')';
// let Img_batt = 'url(' + battImage + ')';
// function getDataUrl (img) {
//     let can = document.createElement('canvas');
//     let offCtx = can.getContext('2d');
//     let width = img.width;
//     let height = img.height;
//     can.width = width;
//     can.height = height;
//     console.dir(img);
//     if (img.complete) {
//         offCtx.drawImage(img, 0, 0, width, height);
//     } else {
//         img.addEventListener('load', () => {
//             offCtx.drawImage(img, 0, 0, width, height);
//         });
//     }
//     return can;
// }
// console.log(getDataUrl(Img_batt));
let timer = new Timeout();
const BALLCOLOR = '#00f7f9';
let list = {
@@ -61,12 +26,12 @@
    }
    // äºŒæžç®¡
    ,'diode_1': {
        x: 628
        x: 800
        ,y: 254
        ,method: 'drawDiode'
    }
    ,'diode_2': {
        x: 628
        x: 800
        ,y: 552
        ,method: 'drawDiode'
    }
@@ -79,74 +44,14 @@
    }
    // ç”µé˜»
    ,'resistance_0': {
        x: 800
        ,y: 216
        // x: 800
        x: 490
        ,y: 180
        ,name: 'R1'
        ,method: 'drawResistance'
    }
    // ,'switch_0': {
    //     x: 300
    //     ,y: 120
    //     ,distance: 60
    //     ,method: 'drawSwitch'
    //     ,isOn: false
    //     ,name: 'K1'
    //     ,description: '80A'
    // }
    // ,'switch_1': {
    //     x: 300
    //     ,y: 330
    //     ,distance: 60
    //     ,method: 'drawSwitch'
    //     ,isOn: false
    //     ,name: 'K2'
    //     ,description: '80A'
    // }
    // ,'switch_2': {
    //     x: 300
    //     ,y: 420
    //     ,distance: 60
    //     ,method: 'drawSwitch'
    //     ,isOn: false
    //     ,name: 'K3'
    //     ,description: '80A'
    // }
    // ,'switch_3': {
    //     x: 820
    //     ,y: 60
    //     ,distance: 60
    //     ,method: 'drawSwitch'
    //     ,isOn: false
    //     ,name: 'K4'
    //     // ,description: '80A'
    // }
    // ,'switch_4': {
    //     x: 660
    //     ,y: 420
    //     ,distance: 60
    //     ,method: 'drawSwitch'
    //     ,isOn: false
    //     ,name: 'K5'
    //     ,description: '80A'
    // }
    // ,'switch_5': {
    //     x: 580
    //     ,y: 220
    //     ,distance: 60
    //     ,method: 'drawSwitch'
    //     ,isOn: false
    //     ,direction: 'ver'
    // }
    // ,'switch_6': {
    //     x: 580
    //     ,y: 520
    //     ,distance: 60
    //     ,method: 'drawSwitch'
    //     ,isOn: false
    //     ,direction: 'ver'
    // }
    ,'inductance_0': {
        x: 404
        x: 530
        ,y: 420
        ,method: 'drawInductance'
        ,name: 'L1'
@@ -210,19 +115,20 @@
        ,method: 'drawLine'
    }
    ,'line_5': {
        points: [[364, 120], [805, 120], [805, 216]]
        points: [[364, 120], [752, 120]]
        ,method: 'drawLine'
    }
    ,'line_6': {
        points: [[805, 276], [805, 420], [724, 420]]
        points: [[495, 364], [495, 420]]
        // points: [[805, 276], [805, 420], [724, 420]]
        ,method: 'drawLine'
    }
    ,'line_7': {
        points: [[452, 420], [656, 420]]
        points: [[578, 420], [752, 420]]
        ,method: 'drawLine'
    }
    ,'line_8': {
        points: [[364, 420], [404, 420]]
        points: [[364, 420], [530, 420]]
        ,method: 'drawLine'
    }
    ,'line_9': {
@@ -238,31 +144,31 @@
        ,method: 'drawLine'
    }
    ,'line_12': {
        points: [[580, 120], [580, 216]]
        points: [[752, 120], [752, 216]]
        ,method: 'drawLine'
    }
    ,'line_13': {
        points: [[580, 284], [580, 516]]
        points: [[752, 284], [752, 516]]
        ,method: 'drawLine'
    }
    ,'line_14': {
        points: [[580, 584], [580, 700]]
        points: [[752, 584], [752, 700]]
        ,method: 'drawLine'
    }
    ,'line_15': {
        points: [[580, 196], [638, 196], [638, 244]]
        points: [[752, 196], [810, 196], [810, 244]]
        ,method: 'drawLine'
    }
    ,'line_16': {
        points: [[638, 254], [638, 304], [580, 304]]
        points: [[810, 254], [810, 304], [752, 304]]
        ,method: 'drawLine'
    }
    ,'line_17': {
        points: [[580, 496], [638, 496], [638, 542]]
        points: [[752, 496], [810, 496], [810, 542]]
        ,method: 'drawLine'
    }
    ,'line_18': {
        points: [[638, 552], [638, 604], [580, 604]]
        points: [[810, 552], [810, 604], [752, 604]]
        ,method: 'drawLine'
    }
    ,'line_19': {
@@ -271,6 +177,14 @@
    }
    ,'line_20': {
        points: [[990, 440], [990, 700]]
        ,method: 'drawLine'
    }
    ,'line_21': {
        points: [[495, 120], [495, 180]]
        ,method: 'drawLine'
    }
    ,'line_22': {
        points: [[495, 296], [495, 240]]
        ,method: 'drawLine'
    }
};
@@ -363,16 +277,17 @@
    const list1 = [
        {points: [47, 480, 47, 420], direction: status.state == 2 ? 'top' : 'bottom', fillStyle: BALLCOLOR, ballNum: 1}
        ,{points: [47, 420, 580, 420], direction: status.state == 2 ? 'right' : 'left', fillStyle: BALLCOLOR, ballNum: 4}
        ,{points: [580, 420, 580, 700], direction: status.state == 2 ? 'bottom' : 'top', fillStyle: BALLCOLOR, ballNum: 3}
        ,{points: [47, 420, 752, 420], direction: status.state == 2 ? 'right' : 'left', fillStyle: BALLCOLOR, ballNum: 5}
        ,{points: [752, 420, 752, 700], direction: status.state == 2 ? 'bottom' : 'top', fillStyle: BALLCOLOR, ballNum: 3}
    ];
    
    const list2 = [
        {points: [580, 420, 580, 120], direction: 'top', fillStyle: BALLCOLOR, ballNum: 3}
        ,{points: [580, 120, 805, 120], direction: 'right', fillStyle: BALLCOLOR, ballNum: 2}
        ,{points: [805, 120, 805, 216], direction: 'bottom', fillStyle: BALLCOLOR, ballNum: 1}
        ,{points: [805, 276, 805, 420], direction: 'bottom', fillStyle: BALLCOLOR, ballNum: 1}
        ,{points: [580, 420, 805, 420], direction: 'left', fillStyle: BALLCOLOR, ballNum: 2}
        {points: [495, 420, 495, 240], direction: 'top', fillStyle: BALLCOLOR, ballNum: 2}
        ,{points: [495, 120, 495, 180], direction: 'top', fillStyle: BALLCOLOR, ballNum: 1}
        ,{points: [495, 120, 752, 120], direction: 'right', fillStyle: BALLCOLOR, ballNum: 2}
        ,{points: [752, 120, 752, 216], direction: 'bottom', fillStyle: BALLCOLOR, ballNum: 1}
        ,{points: [752, 276, 752, 420], direction: 'bottom', fillStyle: BALLCOLOR, ballNum: 1}
        ,{points: [495, 420, 752, 420], direction: 'left', fillStyle: BALLCOLOR, ballNum: 2}
    ];
    
    const list3 = [
@@ -380,25 +295,25 @@
        ,{points: [47, 60, 1222, 60], direction: 'right', fillStyle: BALLCOLOR, ballNum: 10}
        ,{points: [1222, 323, 1222, 60], direction: 'bottom', fillStyle: BALLCOLOR, ballNum: 3}
        ,{points: [1222, 458, 1222, 700], direction: 'bottom', fillStyle: BALLCOLOR, ballNum: 3}
        ,{points: [580, 700, 1222, 700], direction: 'left', fillStyle: BALLCOLOR, ballNum: 5}
        ,{points: [752, 700, 1222, 700], direction: 'left', fillStyle: BALLCOLOR, ballNum: 4}
    ];
    // list1与list3公共第二部分
    const list30 = [
        {points: [47, 700, 580, 700], direction: status.state == 2 ? 'left' : 'right', fillStyle: BALLCOLOR, ballNum: 4}
        {points: [47, 700, 752, 700], direction: status.state == 2 ? 'left' : 'right', fillStyle: BALLCOLOR, ballNum: 5}
        ,{points: [47, 624, 47, 700], direction: status.state == 2 ? 'top' : 'bottom', fillStyle: BALLCOLOR, ballNum: 1}
    ];
    const list31 = [
        {points: [47, 700, 580, 700], direction: 'left', fillStyle: BALLCOLOR, ballNum: 4}
        {points: [47, 700, 752, 700], direction: 'left', fillStyle: BALLCOLOR, ballNum: 5}
        ,{points: [47, 624, 47, 700], direction: 'top', fillStyle: BALLCOLOR, ballNum: 1}
    ];
    
    const list4 = [
        {points: [154, 162, 154, 120], direction: 'top', fillStyle: BALLCOLOR, ballNum: 1}
        ,{points: [154, 120, 580, 120], direction: 'right', fillStyle: BALLCOLOR, ballNum: 4}
        ,{points: [580, 420, 580, 120], direction: 'bottom', fillStyle: BALLCOLOR, ballNum: 3}
        ,{points: [580, 420, 384, 420], direction: 'left', fillStyle: BALLCOLOR, ballNum: 2}
        ,{points: [154, 120, 752, 120], direction: 'right', fillStyle: BALLCOLOR, ballNum: 5}
        ,{points: [752, 420, 752, 120], direction: 'bottom', fillStyle: BALLCOLOR, ballNum: 3}
        ,{points: [752, 420, 384, 420], direction: 'left', fillStyle: BALLCOLOR, ballNum: 3}
        ,{points: [384, 330, 384, 420], direction: 'top', fillStyle: BALLCOLOR, ballNum: 1}
        ,{points: [154, 330, 384, 330], direction: 'left', fillStyle: BALLCOLOR, ballNum: 2}
        ,{points: [154, 330, 154, 260], direction: 'top', fillStyle: BALLCOLOR, ballNum: 1}
@@ -422,7 +337,7 @@
        ,description: '80A'
    });
    stateL.draw_switch({
        x: 580
        x: 752
        ,y: 520
        ,distance: 60
        ,method: 'drawSwitch'
@@ -431,17 +346,18 @@
    });
    stateL.draw_switch({
        x: 660
        ,y: 420
        x: 495
        ,y: 300
        ,distance: 60
        ,method: 'drawSwitch'
        ,isOn: Q2
        ,name: 'K5'
        ,description: '80A'
        ,direction: 'ver'
    });
    stateL.draw_switch({
        x: 580
        x: 752
        ,y: 220
        ,distance: 60
        ,method: 'drawSwitch'
src/pages/dataTest/realTimeAio.vue
@@ -514,7 +514,7 @@
                return list;
            }
            let batt_state_text = this.diagram.powerCut?"停电放电":obj[this.inputs.batt_state];
            list.batt_state = batt_state_text+this.diagram.desc;
            list.batt_state = batt_state_text + '(' + this.diagram.desc + ')';
            list.group_online_vol =
                `在线:${this.inputs.online_vol.toFixed(2)}V; ç»„端:${this.inputs.group_vol.toFixed(2)}V`;
            list.group_curr = this.inputs.group_curr.toFixed(2) + "A";
ÏîÄ¿ÐèÇó.md
@@ -113,3 +113,11 @@
```
一体机参数设置不显示放电过温  å……电过温
```
####2021/7/31
```
一体机参数设置 å……电电压改变时 ç»„端上限为 å……电电压 + 5
组端上限范围为充电电压 ~ 300
单体上限数量范围  1 ~ å•体数
单体下限数量范围  1 ~ å•体数
```