medal management

This commit is contained in:
xiaomlove
2022-01-19 23:54:55 +08:00
parent 3fa8fd19c0
commit 64a1f2bb0c
39 changed files with 1282 additions and 171 deletions
+22 -1
View File
@@ -72,6 +72,24 @@ const api = {
deleteExam: (id) => {
return axios.delete('exams/' + id);
},
listMedal: (params = {}) => {
return axios.get('medals', {params: params});
},
storeMedal: (params = {}) => {
return axios.post('medals', params);
},
updateMedal: (id, params = {}) => {
return axios.put('medals/' + id, params);
},
getMedal: (id) => {
return axios.get('medals/' + id);
},
deleteMedal: (id) => {
return axios.delete('medals/' + id);
},
listClass: (params = {}) => {
return axios.get('user-classes', {params: params});
},
@@ -107,7 +125,10 @@ const api = {
},
listSystemInfo: () => {
return axios.get('dashboard/system-info')
}
},
removeUserMedal: (id) => {
return axios.delete('user-medals/' + id);
},
}
+2
View File
@@ -47,4 +47,6 @@ export const pathMap = {
'exam-form': 'Exam form',
'exam-user': 'Exam user',
'setting': "Setting",
'medal': 'Medal',
'medal-form': 'Medal form',
}