Browse Source

上传文件

master
ruanqi 5 years ago
parent
commit
9f0367f12a
  1. 6
      src/views/orderBoard.vue
  2. 25
      src/views/productOutBoard.vue
  3. 7
      src/views/reportAbnormal.vue
  4. 5
      src/views/scheduledBoard.vue

6
src/views/orderBoard.vue

@ -140,9 +140,13 @@ export default {
let data_temp = data.rows; let data_temp = data.rows;
this.boardLoading(data_temp); this.boardLoading(data_temp);
} else { } else {
alert.msg(data.msg);
this.jump();
} }
},
error: () => {
this.jump();
} }
}) })
}, },
boardLoading(data_temp) { boardLoading(data_temp) {

25
src/views/productOutBoard.vue

@ -22,8 +22,9 @@
</template> </template>
<script> <script>
import TimeC from "./time"
export default {
import TimeC from "./time"
export default {
name: "productOutBoard", name: "productOutBoard",
data() { data() {
return { return {
@ -54,7 +55,7 @@ export default {
let jumpTime = Number(data.rows); let jumpTime = Number(data.rows);
if (jumpTime > 0) { if (jumpTime > 0) {
that.countTimer = window.setTimeout(() => { that.countTimer = window.setTimeout(() => {
that.jump()
that.jump();
}, 1000 * jumpTime); }, 1000 * jumpTime);
} }
@ -96,12 +97,12 @@ export default {
let refreshTime = Number(data.rows); let refreshTime = Number(data.rows);
if (refreshTime > 0) { if (refreshTime > 0) {
that.loader = window.setInterval(() => { that.loader = window.setInterval(() => {
that.refresh()
that.refresh();
}, 1000 * refreshTime); }, 1000 * refreshTime);
} }
} else { } else {
that.loader = window.setInterval(() => { that.loader = window.setInterval(() => {
that.refresh()
that.refresh();
}, 10000); }, 10000);
} }
}, },
@ -116,12 +117,20 @@ export default {
data: {}, data: {},
dataType: "json", dataType: "json",
success: function (data) { success: function (data) {
if (data.success) {
that.data1 = {"total": data.rows1.length, "rows": data.rows1}; that.data1 = {"total": data.rows1.length, "rows": data.rows1};
that.data2 = {"total": data.rows2.length, "rows": data.rows2}; that.data2 = {"total": data.rows2.length, "rows": data.rows2};
$('#table1').bootstrapTable('load', that.data1); $('#table1').bootstrapTable('load', that.data1);
$('#table2').bootstrapTable('load', that.data2); $('#table2').bootstrapTable('load', that.data2);
} else {
this.jump();
}
}, },
error: () => {
this.jump();
}
}) })
}, },
@ -258,11 +267,11 @@ export default {
beforeDestroy() { beforeDestroy() {
}, },
}
}
</script> </script>
<style scoped> <style scoped>
.container {
.container {
height: 100%; height: 100%;
}
}
</style> </style>

7
src/views/reportAbnormal.vue

@ -137,6 +137,7 @@ export default {
data: {}, data: {},
dataType: "json", dataType: "json",
success: function (data) { success: function (data) {
if (data.success) {
that.data1 = {"total": data.rows1.length, "rows": data.rows1}; that.data1 = {"total": data.rows1.length, "rows": data.rows1};
that.data2 = {"total": data.rows2.length, "rows": data.rows2}; that.data2 = {"total": data.rows2.length, "rows": data.rows2};
that.data3 = {"total": data.rows3.length, "rows": data.rows3}; that.data3 = {"total": data.rows3.length, "rows": data.rows3};
@ -168,7 +169,13 @@ export default {
clearInterval(that.handler); clearInterval(that.handler);
} }
}, 1000 * that.refreshTime) }, 1000 * that.refreshTime)
} else {
this.jump();
}
}, },
error: () => {
this.jump();
}
}) })
}, },

5
src/views/scheduledBoard.vue

@ -166,8 +166,11 @@ export default {
let data_temp = data.rows; let data_temp = data.rows;
this.boardLoading(data_temp); this.boardLoading(data_temp);
} else { } else {
alert.msg(data.msg);
this.jump();
} }
},
error: () => {
this.jump();
} }
}); });
}, },

Loading…
Cancel
Save