Advertisement
Guest User

Untitled

a guest
Jul 21st, 2017
49
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.32 KB | None | 0 0
  1. router.get('/', controller.index);
  2.  
  3. export function index(req, res) {
  4. return Driver.find().exec()
  5. .then(respondWithResult(res))
  6. .catch(handleError(res));
  7. }
  8.  
  9. export function DriverResource($resource) {
  10. 'ngInject';
  11.  
  12. return $resource('/api/drivers/:id');
  13. }
  14.  
  15. this.driverList = Driver.query({company: 'foo'});
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement