/**
 * Created by zhang on 2018/9/3.
 */

let express = require("express");
let monomerTemplateRouter =express.Router();
import  MonomerTemplateController from "../controllers/monomer_template_controller";
let monomerTemplateController = new MonomerTemplateController();

module.exports =function (app){

    monomerTemplateRouter.get("/main", monomerTemplateController.auth, monomerTemplateController.init, monomerTemplateController.main);
    monomerTemplateRouter.post("/addLib", monomerTemplateController.auth, monomerTemplateController.init, monomerTemplateController.addLib);
    monomerTemplateRouter.post("/findLib", monomerTemplateController.auth, monomerTemplateController.init, monomerTemplateController.findLib);
    monomerTemplateRouter.post("/saveLib", monomerTemplateController.auth, monomerTemplateController.init, monomerTemplateController.saveLib);
    monomerTemplateRouter.post("/deleteLibByID", monomerTemplateController.auth, monomerTemplateController.init, monomerTemplateController.deleteLibByID);
    monomerTemplateRouter.get("/edit/:libID", monomerTemplateController.auth, monomerTemplateController.init, monomerTemplateController.edit);
    app.use("/monomerTemplate", monomerTemplateRouter);
};


