Browse Source

修改学校计划导入

zs 10 months ago
parent
commit
9fb8642140
1 changed files with 10 additions and 0 deletions
  1. 10 0
      store/util.js

+ 10 - 0
store/util.js

@@ -12,6 +12,8 @@ const api = {
   util: `/api/train/util`,
   taskupload: `/files/task/upload`,
   exportExcel: `/api/train/exportExcel`,
+  schoolDownload: `/api/train/schoolDownload`,
+  schoolImport: `/api/train/schoolImport`,
 };
 const state = () => ({});
 const mutations = {};
@@ -36,6 +38,14 @@ const actions = {
     const res = await this.$axios.$post(`${api.exportExcel}`, payload);
     return res;
   },
+  async schoolDownload({ commit }, payload) {
+    const res = await this.$axios.$post(`${api.schoolDownload}`, payload);
+    return res;
+  },
+  async schoolImport({ commit }, payload) {
+    const res = await this.$axios.$post(`${api.schoolImport}`, { filepath: payload });
+    return res;
+  },
   async upload({ commit }, { file, uri }) {
     // const res = await this.$axios.$post(`${api.taskupload}`, payload, null, { 'Content-Type': 'multipart/form-data' });
     let param = new FormData(); //创建form对象