| | |
| | | import com.lf.server.entity.sys.UserEntity; |
| | | import com.lf.server.helper.StringHelper; |
| | | import com.lf.server.helper.WebHelper; |
| | | import com.lf.server.service.data.LayerService; |
| | | import com.lf.server.service.data.PublishService; |
| | | import com.lf.server.service.sys.TokenService; |
| | | import io.swagger.annotations.Api; |
| | |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import javax.annotation.Resource; |
| | | import javax.servlet.http.HttpServletRequest; |
| | | import java.util.List; |
| | | |
| | |
| | | @RestController |
| | | @RequestMapping("/publish") |
| | | public class PublishController extends BaseController { |
| | | @Autowired |
| | | @Resource |
| | | PublishService publishService; |
| | | |
| | | @Autowired |
| | | @Resource |
| | | TokenService tokenService; |
| | | |
| | | @Resource |
| | | LayerService layerService; |
| | | |
| | | @SysLog() |
| | | @ApiOperation(value = "分页查询元数据") |
| | |
| | | |
| | | String method = getConvertMethod(entity.getType()); |
| | | long count = publishService.postForPub(entity, method, req); |
| | | if (count > 0) { |
| | | layerService.clearCache(); |
| | | } |
| | | |
| | | return success(count); |
| | | } catch (Exception ex) { |
| | |
| | | |
| | | publishService.deleteFiles(list); |
| | | int count = publishService.deletes(ids, req); |
| | | if (count > 0) { |
| | | layerService.clearCache(); |
| | | } |
| | | |
| | | return success(count); |
| | | } catch (Exception ex) { |
| | |
| | | } |
| | | |
| | | int count = publishService.update(entity); |
| | | if (count > 0) { |
| | | layerService.clearCache(); |
| | | } |
| | | |
| | | return success(count); |
| | | } catch (Exception ex) { |