| | |
| | | import com.doumee.core.model.PageData; |
| | | import com.doumee.core.model.PageWrap; |
| | | import com.doumee.dao.business.model.Company; |
| | | import com.doumee.dao.business.model.dto.CompanyCreatOrUpdateRequest; |
| | | import com.doumee.service.business.CompanyService; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import org.apache.shiro.authz.annotation.RequiresPermissions; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import javax.validation.Valid; |
| | | |
| | | /** |
| | | * @author AA |
| | |
| | | @ApiOperation("新建") |
| | | @PostMapping("/create") |
| | | @RequiresPermissions("company:company:create") |
| | | public ApiResponse create(@RequestBody Company company) { |
| | | public ApiResponse create(@RequestBody @Valid CompanyCreatOrUpdateRequest company) { |
| | | return ApiResponse.success(companyService.create(company)); |
| | | } |
| | | |