u
This commit is contained in:
28
src/api/attributename.js
Normal file
28
src/api/attributename.js
Normal file
@@ -0,0 +1,28 @@
|
||||
import { http } from './http.js';
|
||||
|
||||
export const attributename = {
|
||||
/** GET /api/attributename → { attributenames: Attributename[] } */
|
||||
list() {
|
||||
return http('/api/attributename');
|
||||
},
|
||||
|
||||
/** POST /api/attributename → 201 { attributename } */
|
||||
create(body) {
|
||||
return http('/api/attributename', { method: 'POST', body });
|
||||
},
|
||||
|
||||
/** PATCH /api/attributename/:id → 200 { attributename } */
|
||||
update(id, body) {
|
||||
return http(`/api/attributename/${encodeURIComponent(id)}`, { method: 'PATCH', body });
|
||||
},
|
||||
|
||||
/** DELETE /api/attributename/:id → 200 */
|
||||
delete(id) {
|
||||
return http(`/api/attributename/${encodeURIComponent(id)}`, { method: 'DELETE' });
|
||||
},
|
||||
|
||||
/** PUT /api/attributename/order → 200 */
|
||||
order(attributenameIds) {
|
||||
return http('/api/attributename/order', { method: 'PUT', body: { attributenameIds } });
|
||||
},
|
||||
};
|
||||
Reference in New Issue
Block a user