Created
October 14, 2019 19:35
-
-
Save LucasBadico/4583d49b40ec040f9cb7f6ab06b5a967 to your computer and use it in GitHub Desktop.
create method on serviço
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
export default class GarageService { | |
constructor(garageRepo) { | |
this.repository = garageRepo; | |
} | |
async create(data) { | |
return this.repository.create({ | |
...data, | |
id: 'mockid' | |
}) | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment