| | |
| | | import com.ruoyi.common.core.web.domain.AjaxResult; |
| | | import com.ruoyi.other.enums.ShareAddType; |
| | | import com.ruoyi.other.api.domain.Share; |
| | | import com.ruoyi.other.enums.ShareAuditStatus; |
| | | import com.ruoyi.other.service.ShareService; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiImplicitParam; |
| | |
| | | @PostMapping |
| | | public AjaxResult add(@RequestBody Share share){ |
| | | share.setAddType(ShareAddType.STORE.getCode()); |
| | | share.setAuditStatus(ShareAuditStatus.WAIT.getCode()); |
| | | share.setDelFlag(0); |
| | | share.setAppletShare(1); |
| | | return toAjax(shareService.save(share)); |
| | | } |
| | | |
| | |
| | | @ApiOperation(value = "分享编辑", tags = {"分享"}) |
| | | @PutMapping |
| | | public AjaxResult edit(@RequestBody Share share){ |
| | | share.setAuditStatus(ShareAuditStatus.WAIT.getCode()); |
| | | return toAjax(shareService.updateById(share)); |
| | | } |
| | | |