CouponList.js 2.58 KB
/**
 * Created by yoho on 2016/6/20.
 */
module.exports = function (app) {
    /*************************************优惠券管理--庞洁*************************************/
    //列表页
    app.get("/market/couponList/index", "marketing.CouponList.Index",function(){
        this.$extend={
            moduleName:'营销管理',
            pageName:'优惠券管理',
        }
    });

    //优惠券列表
    app.post("/coupon/queryCouponList", "CouponList_queryCouponList");

   //添加页
    app.get("/market/couponList/add", "marketing.CouponList.AddOrUpdate",function(){
        this.$extend={
            moduleName:'营销管理',
            pageName:'新增优惠券',
            title: "新增优惠券",
            type: "add",
            action: "/coupon/add"
        }
    });

    //编辑页
    app.get("/market/couponList/update/:id", "marketing.CouponList.AddOrUpdate",function(){
        this.$extend={
            moduleName:'营销管理',
            pageName:'修改优惠券',
            title: "修改优惠券",
            type: "update",
            action: "/coupon/update"
        }
    });

    //单张详情
    app.post("/coupon/getCouponDetailById", "CouponList_getCouponDetailById");

    //新增优惠券
    app.post("/coupon/add", "CouponList_addOrUpdate");

    //编辑优惠券
    app.post("/coupon/update", "CouponList_addOrUpdate");


    //驳回
    app.post("/coupon/reject", "CouponList_reject");

    //通过
    app.post("/coupon/approve", "CouponList_approve");

    //作废
    app.post("/coupon/invalid", "CouponList_invalid");

    // 查询优惠券操作记录
    app.post("/coupon/getOperationRecords", "CouponList_getOperationRecords");

    // 更新第三方信息
    app.post("/coupon/updateCouponsUseRule", "CouponList_updateCouponsUseRule");

    // 更新微信卡券H5链接
    app.post("/coupon/updateH5Link", "CouponList_updateH5Link");

    //清除指定商品
    app.post("/coupon/cleanPrdLimit", "CouponList_cleanPrdLimit");

    // 更新微信卡券H5链接
    app.post("/coupon/updateH5Link", "CouponList_updateH5Link");

    app.get("/market/department/index", "marketing.CouponList.DepartmentIndex",function(){
        this.$extend={
            moduleName:'营销管理',
            pageName:'费用承担部门管理',
        }
    });
    //新增部门
    app.post("/coupon/insertDepartment", "Department_add");

    //修改部门
    app.post("/coupon/updateDepartment", "Department_update");

    app.post("/coupon/queryDepartmentList","Department_list");

    app.post("/coupon/queryDepartmentById","Department_queryById");
};