From 6f8253d572bb4fd768266043ad5a049bf537ec24 Mon Sep 17 00:00:00 2001 From: vishalkanojiya Date: Fri, 28 Sep 2018 17:45:10 +0530 Subject: [PATCH 1/4] add socket --- client/src/pages/flow/List.vue | 19 ++++++++++++++++++- 1 file changed, 18 insertions(+), 1 deletion(-) diff --git a/client/src/pages/flow/List.vue b/client/src/pages/flow/List.vue index 7a43d9e..54e2792 100644 --- a/client/src/pages/flow/List.vue +++ b/client/src/pages/flow/List.vue @@ -516,7 +516,8 @@ export default { return days + ' Days' } } - ] + ], + entriesTotal: 10 } }, mounted () { @@ -534,6 +535,22 @@ export default { console.log(error) }) } + }, + 'flowz': { + created (data) { + if (this.total < this.entriesTotal) { + this.flowzList.push(data) + } else { + this.total = ((this.total) + 1) + } + }, + updated (data) { + if (this.flowzList < this.entriesTotal) { + let inx = _.findIndex(this.flowzList, (o) => { return o.id === data.id }) + this.flowzList.splice(inx, 1) + this.flowzList.push(data) + } + } } }, methods: { From e2c3e4a94e05c641328431cd9144499210eeec52 Mon Sep 17 00:00:00 2001 From: vishalkanojiya Date: Mon, 1 Oct 2018 12:19:13 +0530 Subject: [PATCH 2/4] add socket --- client/src/pages/flow/List.vue | 103 ++++++++++++++++++--------------- 1 file changed, 55 insertions(+), 48 deletions(-) diff --git a/client/src/pages/flow/List.vue b/client/src/pages/flow/List.vue index 54e2792..e34da6f 100644 --- a/client/src/pages/flow/List.vue +++ b/client/src/pages/flow/List.vue @@ -34,6 +34,10 @@