chenrui  3 anni fa
parent
commit
429733c94a

+ 1 - 1
src/App.vue

@@ -62,7 +62,7 @@ export default {
         PageSize: 8,
       };
       alarmInformationhos(params).then((res) => {
-        this.agreepersonlist = res.resultData.result;
+        this.agreepersonlist = res.resultData;
         if (this.agreepersonlist.length > 0) {
           this.start = 1;
         } else {

+ 25 - 16
src/components/orderConfigpop/index.vue

@@ -68,7 +68,7 @@
             <el-form-item label="车辆匹配">
               <el-input
                 v-model="form.car_name"
-                type="number"
+                onkeyup="this.value = this.value.replace(/[^\d.]/g,'')"
                 placeholder="请输入来源"
               ></el-input>
             </el-form-item>
@@ -79,7 +79,7 @@
             <el-form-item label="站点匹配">
               <el-input
                 v-model="form.station_name"
-                type="number"
+                onkeyup="this.value = this.value.replace(/[^\d.]/g,'')"
                 placeholder="请输入标签"
               ></el-input>
             </el-form-item>
@@ -88,7 +88,8 @@
             <el-form-item label="匹配订单号" prop="order_id">
               <el-input
                 v-model="form.order_id"
-                type="number"
+                maxlength="10"
+                onkeyup="this.value = this.value.replace(/[^\d.]/g,'')"
                 placeholder="请输入来源(必填)"
               ></el-input>
             </el-form-item>
@@ -178,16 +179,24 @@ export default {
       this.$refs["form"].validate((valid) => {
         if (valid) {
           this.form.tagname = this.form.tagname.replace(/\s*/g, "");
-          this.form.destination = this.form.destination.replace(/\s*/g, "");
-          this.form.bagtag = this.form.bagtag.replace(/\s*/g, "");
-          this.form.securite_result = this.form.securite_result.replace(
-            /\s*/g,
-            ""
-          );
-          this.form.securite_tagname = this.form.securite_tagname.replace(
-            /\s*/g,
-            ""
-          );
+          if (this.form.destination) {
+            this.form.destination = this.form.destination.replace(/\s*/g, "");
+          }
+          if (this.form.bagtag) {
+            this.form.bagtag = this.form.bagtag.replace(/\s*/g, "");
+          }
+          if (this.form.securite_result) {
+            this.form.securite_result = this.form.securite_result.replace(
+              /\s*/g,
+              ""
+            );
+          }
+          if (this.form.securite_tagname) {
+            this.form.securite_tagname = this.form.securite_tagname.replace(
+              /\s*/g,
+              ""
+            );
+          }
           // this.form.car_name = this.form.car_name.replace(/\s*/g,"")
           // this.form.station_name = this.form.station_name.replace(/\s*/g,"")
           // this.form.order_id = this.form.order_id.replace(/\s*/g,"")
@@ -199,7 +208,7 @@ export default {
                   message: res.resultMsg,
                   type: "success",
                 });
-                (this.form = {
+                this.form = {
                   tagname: null,
                   destination: null,
                   bagtag: null,
@@ -208,8 +217,8 @@ export default {
                   car_name: null,
                   station_name: null,
                   order_id: null,
-                }),
-                  this.$emit("oderadd");
+                };
+                this.$emit("oderadd");
               } else {
                 this.$message.error(res.resultMsg);
                 this.form = {

+ 6 - 6
src/pages/Alarm/History/index.vue

@@ -105,8 +105,8 @@ export default {
         PageSize: 13,
       };
       alarmInformationhos(params).then((res) => {
-        this.tableData = res.resultData.result;
-        this.pageCount = res.pageNumber;
+        this.tableData = res.resultData;
+        this.pageCount = res.pageNumber * 10;
         // console.log(this.timeFor(this.tableData[0].alarm_date))
         // for (let index in this.tableData) {
         //   this.tableData[index].alarm_date = this.timeFor(
@@ -200,10 +200,10 @@ export default {
 
 <style lang="less" scoped>
 /deep/.el-pagination {
-  position: absolute;
-  bottom: 0;
-  left: 0;
-  right: 0;
+  // position: absolute;
+  // bottom: 0;
+  // left: 0;
+  // right: 0;
   z-index: 9999;
   display: flex;
   justify-content: center;

+ 6 - 6
src/pages/Alarm/RealTime/index.vue

@@ -166,8 +166,8 @@ export default {
         PageSize: 13,
       };
       alarmInformationhos(params).then((res) => {
-        this.tableData = res.resultData.result;
-        this.pageCount = res.pageNumber;
+        this.tableData = res.resultData;
+        this.pageCount = res.pageNumber * 10;
         // for (let index in this.tableData) {
         //   this.tableData[index].alarm_date = this.timeFor(
         //     this.tableData[index].alarm_date
@@ -257,10 +257,10 @@ export default {
 
 <style lang="less" scoped>
 /deep/.el-pagination {
-  position: absolute;
-  bottom: 0;
-  left: 0;
-  right: 0;
+  // position: absolute;
+  // bottom: 0;
+  // left: 0;
+  // right: 0;
   z-index: 9999;
   display: flex;
   justify-content: center;

+ 1 - 1
src/pages/Common/home.vue

@@ -889,7 +889,7 @@ export default {
         PageSize: 8,
       };
       alarmInformationhos(params).then((res) => {
-        this.agreepersonlist = res.resultData.result;
+        this.agreepersonlist = res.resultData;
         // let audio = new Audio();
         // audio.src = "../viper.mp3";
         // // audio.play();

+ 11 - 4
src/pages/SystemSet/User/index.vue

@@ -166,6 +166,7 @@
       @next-click="changePage"
       layout="prev, pager, next"
       :total="totalPages"
+      :current-page.sync="pageSize"
     >
     </el-pagination>
     <!-- <el-table :data="userTableData" ref='userTableData' id="userTableData" style="width: 100%;color: #2DAFF5;max-height: 100%;overflow-y: auto;background-color: none;">
@@ -475,6 +476,8 @@ export default {
       } else if (this.actives == 1) {
         this.orderConfig();
       } else if (this.actives == 2) {
+        this.labelConfig();
+      } else if (this.actives == 3) {
         this.giveAn();
       }
     },
@@ -486,7 +489,7 @@ export default {
       };
       networkConfiguration(params).then((res) => {
         this.tableData = res.resultData;
-        this.totalPages = res.pageNumber;
+        this.totalPages = res.pageNumber * 10;
       });
     },
     //修改网络配置
@@ -516,7 +519,7 @@ export default {
       };
       orderConfiguration(params).then((res) => {
         this.tableData = res.resultData;
-        this.totalPages = res.pageNumber;
+        this.totalPages = res.pageNumber * 10;
       });
     },
     //订单修改
@@ -549,7 +552,7 @@ export default {
           res.states = res.state == 1 ? "启用" : "停用";
         });
         this.tableData = res.resultData;
-        this.totalPages = res.pageNumber;
+        this.totalPages = res.pageNumber * 10;
       });
     },
     //标签配置修改
@@ -579,7 +582,7 @@ export default {
       };
       alarmConfiguration(params).then((res) => {
         this.tableData = res.resultData;
-        this.totalPages = res.pageNumber;
+        this.totalPages = res.pageNumber * 10;
       });
     },
     //新增告警/网络/订单
@@ -646,21 +649,25 @@ export default {
     },
     //告警关闭
     arlem() {
+      this.listdata = {};
       this.dialogVisibledarm = false;
       this.giveAn();
     },
     //关闭新增网络配置
     workConadd() {
+      this.listdata = {};
       this.dialogVisiblenetwork = false;
       this.network();
     },
     //关闭订单
     oderadd() {
+      this.listdata = {};
       this.dialogVisibledoder = false;
       this.orderConfig();
     },
     //关闭标签
     labeladd() {
+      this.listdata = {};
       this.dialogVisibledlabe = false;
       this.labelConfig();
     },

+ 3 - 4
src/pages/admin.vue

@@ -196,7 +196,7 @@ export default {
   mounted() {
     this.monitorfullScreen();
     this.refersh();
-    this.userName = JSON.parse(sessionStorage.getItem("userData")).userName;
+    // this.userName = JSON.parse(sessionStorage.getItem("userData")).userName;
     let that = this;
     setInterval(() => {
       //实时更新数据
@@ -211,11 +211,10 @@ export default {
         PageIndex: 1,
         PageSize: 8,
       };
-      debugger;
       alarmInformationhos(params).then((res) => {
-        this.agreepersonlist = res.resultData.result;
+        this.agreepersonlist = res.resultData;
         AlarmSon().then((item) => {
-          this.agreepersonlist = res.resultData.result;
+          this.agreepersonlist = res.resultData;
           let audio = new Audio();
           audio.src = item.resultData;
           // audio.play();

+ 1 - 1
src/pages/login.vue

@@ -162,7 +162,7 @@ export default {
       // console.log(this.$store.state.login.userData)
 
       Home(loginData).then((res) => {
-        if (res.resultCode == 0) {
+        if (res.token) {
           setCodeToken(res.token);
           this.$router.push({ path: "/admin" });
         } else {

+ 2 - 2
static/serve.js

@@ -1,5 +1,5 @@
 window.g = {
-  url: `http://192.168.30.249:3420`,// 配置服务器地址
-  // url: `http://139.198.181.133:5000`,// 配置服务器地址
+  // url: `http://192.168.30.249:3420`,// 配置服务器地址
+  url: `http://139.198.181.133:5000`,// 配置服务器地址
   mapURL: `http://192.168.30.250:3420/api` // 地图地址
 }