package com.mortals.xhx.module.basics.web;

import com.mortals.framework.model.Context;
import com.mortals.xhx.common.code.YesNoEnum;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import com.mortals.framework.web.BaseCRUDJsonMappingController;
import com.mortals.xhx.module.basics.model.BasicsInfoEntity;
import com.mortals.xhx.module.basics.service.BasicsInfoService;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import java.util.Map;


/**
* <p>Title: 一件事基础表</p>
* <p>Description: BasicsInfoController  </p>
* <p>Copyright: Copyright &reg;  </p>
* <p>Company: </p>
* @author zxfei
* @version 1.0.0
*/
@RestController
@RequestMapping("basics/info")
public class BasicsInfoController extends BaseCRUDJsonMappingController<BasicsInfoService,BasicsInfoForm,BasicsInfoEntity,Long> {

    public BasicsInfoController(){
        super.setFormClass(BasicsInfoForm.class);
        super.setModuleDesc("一件事基础表");
    }

    @Override
    protected void init(HttpServletRequest request, HttpServletResponse response, BasicsInfoForm form, Map<String, Object> model, Context context) {
        this.addDict(model, "isChargesShow", YesNoEnum.getEnumMap());
    }
}