router.js 380 B

123456789101112
  1. 'use strict';
  2. /**
  3. * @param {Egg.Application} app - egg application
  4. */
  5. module.exports = app => {
  6. const { router, controller } = app;
  7. router.get('/', controller.home.index);
  8. router.post('/:appid/upload', controller.files.upload);
  9. router.post('/:appid/:catalog/upload', controller.files.upload);
  10. router.post('/:appid/:catalog/:item/upload', controller.files.upload);
  11. };