|
@@ -18,7 +18,7 @@
|
|
|
<button @click="actionHandle">actionHandle</button>
|
|
|
|
|
|
<h1>用户模块:{{$store.state.userModule.count}}</h1>
|
|
|
- <button @click="$store.commit('userModule/addUser')">用户模块加法操作</button>
|
|
|
+ <button @click="actionFun">用户模块加法操作</button>
|
|
|
</div>
|
|
|
</template>
|
|
|
<script>
|
|
@@ -37,6 +37,8 @@ export default {
|
|
|
},
|
|
|
actionFun(){
|
|
|
this.$store.dispatch("actionHandle");
|
|
|
+ // this.$store.commit("addUser");
|
|
|
+ this.$store.commit("userModule/addUser");
|
|
|
}
|
|
|
},
|
|
|
computed:{
|
|
@@ -48,3 +50,6 @@ export default {
|
|
|
}
|
|
|
}
|
|
|
</script>
|
|
|
+<style>
|
|
|
+
|
|
|
+</style>
|