summaryrefslogtreecommitdiff
path: root/src/store/modules/node.js
diff options
context:
space:
mode:
Diffstat (limited to 'src/store/modules/node.js')
-rw-r--r--src/store/modules/node.js28
1 files changed, 28 insertions, 0 deletions
diff --git a/src/store/modules/node.js b/src/store/modules/node.js
new file mode 100644
index 0000000..ef737df
--- /dev/null
+++ b/src/store/modules/node.js
@@ -0,0 +1,28 @@
+const store = {
+ namespaced: true,
+ state: {
+ startTraffic: false,
+ endTraffic: false,
+ },
+ getters: {
+ getStartTraffic: state => state.startTraffic,
+ getEndTraffic: state => state.endTraffic
+ },
+ mutations: {
+ setStartTraffic(state, startTraffic) {
+ state.startTraffic = startTraffic
+ },
+ setEndTraffic(state, endTraffic) {
+ state.endTraffic = endTraffic
+ }
+ },
+ actions: {
+ setStartTrafficAction(context, startTraffic) {
+ context.commit('setStartTraffic', startTraffic)
+ },
+ setEndTrafficAction(context, endTraffic) {
+ context.commit('setEndTraffic', endTraffic)
+ }
+ }
+}
+export default store \ No newline at end of file