Browse Source

看板改变

master
ruanqi 4 years ago
parent
commit
cf50abb274
  1. 19
      src/views/Home.vue
  2. 12
      src/views/orderBoard.vue
  3. 6
      src/views/productOutBoard.vue
  4. 9
      src/views/reportAbnormal.vue
  5. 11
      src/views/scheduledBoard.vue
  6. 4
      vue.config.js

19
src/views/Home.vue

@ -77,11 +77,12 @@ export default {
methods: { methods: {
// //
play() { play() {
let ip=localStorage.getItem("tvIP")
let that = this; let that = this;
$.ajax({ $.ajax({
url: "/board/getJumpConfig", url: "/board/getJumpConfig",
type: "post", type: "post",
data: {"boardName": 'home'},
data: {"boardName": 'home',"ip":ip},
dataType: "json", dataType: "json",
success: (data) => { success: (data) => {
if (data.rows2 != "" && data.rows2 != null) { if (data.rows2 != "" && data.rows2 != null) {
@ -103,6 +104,21 @@ export default {
this.play(); this.play();
}, 5000 ); }, 5000 );
}, },
getIp(){
$.ajax({
url: "/board/getIpFirst",
type: "post",
data: {},
dataType: "json",
success: (data) => {
localStorage.setItem("tvIP",data.row)
}
}).fail(() => {
localStorage.setItem("tvIP","1.1.1.1")
})
},
jump() { jump() {
$.ajax({ $.ajax({
url: "/board/kanKanYouMeiYouDiaoXian", url: "/board/kanKanYouMeiYouDiaoXian",
@ -123,6 +139,7 @@ export default {
// } // }
}, },
mounted() { mounted() {
this.getIp();
this.play(); this.play();
this.toPlay(); this.toPlay();
}, },

12
src/views/orderBoard.vue

@ -66,11 +66,12 @@ export default {
}, },
methods: { methods: {
load() { load() {
let ip=localStorage.getItem("tvIP")
let that = this; let that = this;
$.ajax({ $.ajax({
url: "/board/getJumpConfig", url: "/board/getJumpConfig",
type: "post", type: "post",
data: {"boardName": 'orderBoard'},
data: {"boardName": 'orderBoard',"ip":ip},
dataType: "json", dataType: "json",
success: (data) => { success: (data) => {
if (data.rows2 != "" && data.rows2 != null) { if (data.rows2 != "" && data.rows2 != null) {
@ -107,14 +108,13 @@ export default {
}) })
}, },
getItemNoNumber() { getItemNoNumber() {
let ip=localStorage.getItem("tvIP")
let that = this; let that = this;
$.ajax({ $.ajax({
url: "/board/getOrderBoardData", url: "/board/getOrderBoardData",
type: "POST", type: "POST",
contentType: 'application/json;charset=utf-8',
async: false, async: false,
data: null,// formid
data:{"ip":ip},
dataType: "JSON", dataType: "JSON",
success: (data) => { success: (data) => {
if (data.success) { if (data.success) {
@ -129,12 +129,12 @@ export default {
}, },
getBoardData() { getBoardData() {
let ip=localStorage.getItem("tvIP")
$.ajax({ $.ajax({
url: "/board/getOrderBoardData", url: "/board/getOrderBoardData",
type: "POST", type: "POST",
contentType: 'application/json;charset=utf-8',
async: false, async: false,
data: null,// formid
data:{"ip":ip},
dataType: "JSON", dataType: "JSON",
success: (data) => { success: (data) => {
if (data.success) { if (data.success) {

6
src/views/productOutBoard.vue

@ -42,11 +42,12 @@
}, },
methods: { methods: {
loadTime() { loadTime() {
let ip=localStorage.getItem("tvIP")
let that = this; let that = this;
$.ajax({ $.ajax({
url: "/board/getJumpConfig", url: "/board/getJumpConfig",
type: "post", type: "post",
data: {"boardName": 'productOutBoard'},
data: {"boardName": 'productOutBoard',"ip":ip},
dataType: "json", dataType: "json",
success: (data) => { success: (data) => {
if (data.rows2 != "" && data.rows2 != null) { if (data.rows2 != "" && data.rows2 != null) {
@ -111,10 +112,11 @@
}, },
refresh() { refresh() {
let that = this; let that = this;
let ip=localStorage.getItem("tvIP")
$.ajax({ $.ajax({
url: "/board/getProductOutData", url: "/board/getProductOutData",
type: "post", type: "post",
data: {},
data: {"ip":ip},
dataType: "json", dataType: "json",
success: function (data) { success: function (data) {
if (data.success) { if (data.success) {

9
src/views/reportAbnormal.vue

@ -51,12 +51,13 @@ export default {
}, },
methods: { methods: {
getDataNumber() { getDataNumber() {
let ip=localStorage.getItem("tvIP")
let that = this; let that = this;
$.ajax({ $.ajax({
url: "/board/getReportAbnormalData", url: "/board/getReportAbnormalData",
type: "POST", type: "POST",
contentType: 'application/json;charset=utf-8',
async: false, async: false,
data: {"ip":ip},
dataType: "JSON", dataType: "JSON",
success: (data) => { success: (data) => {
if (data.success) { if (data.success) {
@ -69,11 +70,12 @@ export default {
}); });
}, },
loadTime() { loadTime() {
let ip=localStorage.getItem("tvIP")
let that = this; let that = this;
$.ajax({ $.ajax({
url: "/board/getJumpConfig", url: "/board/getJumpConfig",
type: "post", type: "post",
data: {"boardName": 'reportAbnormal'},
data: {"boardName": 'reportAbnormal',"ip":ip},
dataType: "json", dataType: "json",
success: (data) => { success: (data) => {
if (data.rows2 != "" && data.rows2 != null) { if (data.rows2 != "" && data.rows2 != null) {
@ -131,10 +133,11 @@ export default {
}, },
getData() { getData() {
let that = this; let that = this;
let ip=localStorage.getItem("tvIP")
$.ajax({ $.ajax({
url: "/board/getReportAbnormalData", url: "/board/getReportAbnormalData",
type: "post", type: "post",
data: {},
data: {"ip":ip},
dataType: "json", dataType: "json",
success: function (data) { success: function (data) {
if (data.success) { if (data.success) {

11
src/views/scheduledBoard.vue

@ -75,11 +75,12 @@ export default {
}, },
methods: { methods: {
load() { load() {
let ip=localStorage.getItem("tvIP")
let that = this; let that = this;
$.ajax({ $.ajax({
url: "/board/getJumpConfig", url: "/board/getJumpConfig",
type: "post", type: "post",
data: {"boardName": 'scheduledBoard'},
data: {"boardName": 'scheduledBoard',"ip":ip},
dataType: "json", dataType: "json",
success: (data) => { success: (data) => {
if (data.rows2 != "" && data.rows2 != null) { if (data.rows2 != "" && data.rows2 != null) {
@ -120,12 +121,12 @@ export default {
getItemNoNumber() { getItemNoNumber() {
let that = this; let that = this;
let ip=localStorage.getItem("tvIP")
$.ajax({ $.ajax({
url: "/board/getBoardData", url: "/board/getBoardData",
type: "POST", type: "POST",
contentType: 'application/json;charset=utf-8',
async: false, async: false,
data: null,// formid
data: {"ip":ip},// formid
dataType: "JSON", dataType: "JSON",
success: (data) => { success: (data) => {
if (data.success) { if (data.success) {
@ -169,12 +170,12 @@ export default {
getBoardData() { getBoardData() {
let that=this; let that=this;
let ip=localStorage.getItem("tvIP")
$.ajax({ $.ajax({
url: "/board/getBoardData", url: "/board/getBoardData",
type: "POST", type: "POST",
contentType: 'application/json;charset=utf-8',
async: true, async: true,
data: null,// formid
data: {"ip":ip},// formid
dataType: "JSON", dataType: "JSON",
success: (data) => { success: (data) => {
if (data.success) { if (data.success) {

4
vue.config.js

@ -3,7 +3,7 @@ module.exports = {
lintOnSave: false, lintOnSave: false,
devServer: { devServer: {
// proxy: 'http://192.168.1.83:8089' // proxy: 'http://192.168.1.83:8089'
// proxy: 'http://localhost:8083'
proxy: 'http://172.26.68.16:8091'
proxy: 'http://localhost:8083'
// proxy: 'http://172.26.68.16:8091'
} }
} }
Loading…
Cancel
Save