Commit e79fd5ca authored by 姜登's avatar 姜登

init

parent 56e46f6d
......@@ -2,11 +2,16 @@
const Controller = require('egg').Controller;
class HomeController extends Controller {
class PriceController extends Controller {
async index() {
const { ctx } = this;
ctx.body = 'hi, egg';
}
async create() {
const { ctx } = this;
ctx.body = 'hi, egg';
}
}
module.exports = HomeController;
module.exports = PriceController;
'use strict';
const Controller = require('egg').Controller;
class RechargeController extends Controller {
async index() {
const { ctx } = this;
ctx.body = 'hi, egg';
}
async create() {
const { ctx } = this;
ctx.body = 'hi, egg';
}
}
module.exports = RechargeController;
'use strict';
const Controller = require('egg').Controller;
class RemissionController extends Controller {
async index() {
const { ctx } = this;
ctx.body = 'hi, egg';
}
async create() {
const { ctx } = this;
ctx.body = 'hi, egg';
}
}
module.exports = RemissionController;
......@@ -2,11 +2,18 @@
const Controller = require('egg').Controller;
class HomeController extends Controller {
class UserController extends Controller {
async index() {
const { ctx } = this;
ctx.body = 'hi, egg';
}
async update() {
const { ctx } = this;
ctx.body = 'hi, egg';
}
}
module.exports = HomeController;
module.exports = UserController;
......@@ -6,13 +6,9 @@
module.exports = app => {
const { controller } = app;
const router = app.router.namespace(app.config.projectRootPath);
router.get('/account', controller.user.index); // 获取合作方列表
router.put('/account', controller.user.index); // 修改合作方账号状态
router.get('/user_sercie', controller.user.index); // 获取合作方服务信息
router.get('/price_detail', controller.user.index); // 获取appKey价格明细
router.post('/price_detail', controller.user.index); // 增加价格明细
router.get('/recharge', controller.user.index); // 获取合作方充值信息
router.post('/recharge', controller.user.index); // 增加充值信息
router.get('/remission', controller.user.index); // 获取appKey减免信息
router.post('/remission', controller.user.index); // 增加充值信息
router.resources('/account', controller.user); // 用户信息
router.get('/user_service', controller.user.index); // 获取合作方服务信息
router.resources('/price_detail', controller.user); // 价格明细
router.resources('/recharge', controller.user); // 充值信息
router.resources('/remission', controller.user); // 减免信息
};
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment