guhongwei 4 rokov pred
rodič
commit
aa0c463704
1 zmenil súbory, kde vykonal 6 pridanie a 6 odobranie
  1. 6 6
      src/store/topic.js

+ 6 - 6
src/store/topic.js

@@ -3,32 +3,32 @@ import Vuex from 'vuex';
 import _ from 'lodash';
 Vue.use(Vuex);
 const api = {
-  thumbs: `/api/article/thumbs`,
+  topic: `/api/article/topic`,
 };
 const state = () => ({});
 const mutations = {};
 
 const actions = {
   async query({ commit }, { skip = 0, limit, ...info } = {}) {
-    const res = await this.$axios.$get(api.thumbs, { skip, limit, ...info });
+    const res = await this.$axios.$get(api.topic, { skip, limit, ...info });
     return res;
   },
   async create({ commit }, payload) {
-    const res = await this.$axios.$post(`${api.thumbs}`, payload);
+    const res = await this.$axios.$post(`${api.topic}`, payload);
     return res;
   },
   async fetch({ commit }, payload) {
-    const res = await this.$axios.$get(`${api.thumbs}/${payload}`);
+    const res = await this.$axios.$get(`${api.topic}/${payload}`);
     return res;
   },
   async update({ commit }, { id, ...info } = {}) {
-    const res = await this.$axios.$post(`${api.thumbs}/update/${id}`, {
+    const res = await this.$axios.$post(`${api.topic}/update/${id}`, {
       ...info,
     });
     return res;
   },
   async delete({ commit }, payload) {
-    const res = await this.$axios.$delete(`${api.thumbs}/${payload}`);
+    const res = await this.$axios.$delete(`${api.topic}/${payload}`);
     return res;
   },
 };