@eleva-io/erp-sdk
Version:
SDK oficial para el ERP de Eleva
30 lines • 982 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.CommunitiesEmployeesAPI = void 0;
const crud_1 = require("../../../../utils/crud");
class _CommunityEmployeeCRUD extends crud_1.CRUD {
}
class CommunitiesEmployeesAPI {
_httpClient;
_baseUrl;
_crud;
constructor(_httpClient, _baseUrl) {
this._httpClient = _httpClient;
this._baseUrl = _baseUrl;
this._crud = new _CommunityEmployeeCRUD(this._httpClient, { basePath: this._baseUrl });
}
create(data) {
return this._crud.create(data);
}
update(id, typeId, data) {
return this._httpClient.patch(`${this._baseUrl}/${typeId}/employee/${id}`, data);
}
delete(id, typeId) {
return this._httpClient.delete(`${this._baseUrl}/${typeId}/employee/${id}`);
}
find(query) {
return this._crud.find(query);
}
}
exports.CommunitiesEmployeesAPI = CommunitiesEmployeesAPI;
//# sourceMappingURL=employees.js.map