diff --git a/sf-system/src/main/java/com/sf/system/deployment/service/impl/DeploymentServicePublishServiceImpl.java b/sf-system/src/main/java/com/sf/system/deployment/service/impl/DeploymentServicePublishServiceImpl.java index 1f57ddb..bde7b26 100644 --- a/sf-system/src/main/java/com/sf/system/deployment/service/impl/DeploymentServicePublishServiceImpl.java +++ b/sf-system/src/main/java/com/sf/system/deployment/service/impl/DeploymentServicePublishServiceImpl.java @@ -2,6 +2,9 @@ package com.sf.system.deployment.service.impl; import java.io.IOException; import java.util.List; + +import com.sf.common.constant.HttpStatus; +import com.sf.common.exception.ServiceException; import com.sf.common.utils.DateUtils; import com.sf.common.utils.file.QRCodeUtils; import com.sf.file.domain.SysOss; @@ -110,7 +113,7 @@ public class DeploymentServicePublishServiceImpl implements IDeploymentServicePu @Override public int publish(DeploymentServicePublish deploymentServicePublish) throws Exception { if(1 == deploymentServicePublish.getStatus()){ - return 0;//不允许重复发布 + throw new ServiceException("安装包已发布", HttpStatus.WARN); } deploymentServicePublish.setUpdateTime(DateUtils.getNowDate()); SysApkInfo sysApkInfo = iSysApkInfoService.selectSysApkInfoById(deploymentServicePublish.getApkId()); @@ -123,9 +126,9 @@ public class DeploymentServicePublishServiceImpl implements IDeploymentServicePu @Override public int soldOut(DeploymentServicePublish deploymentServicePublish) { if(2 == deploymentServicePublish.getStatus()){ - return 0;//不允许重复下架 + throw new ServiceException("安装包已下架", HttpStatus.WARN); } - deploymentServicePublish.setStatus(3L); + deploymentServicePublish.setStatus(2L); return deploymentServicePublishMapper.updateDeploymentServicePublish(deploymentServicePublish); } } diff --git a/sf-ui/nginx.conf b/sf-ui/nginx.conf index 1656774..63ce459 100644 --- a/sf-ui/nginx.conf +++ b/sf-ui/nginx.conf @@ -10,8 +10,7 @@ http { default_type application/octet-stream; sendfile on; keepalive_timeout 65; - post_max_size = 100M; - upload_max_filesize = 100M; + client_max_body_size 1024m; #gzip on;