no message
parent
5c6f1c117a
commit
8d773f3630
|
|
@ -2,15 +2,26 @@ package com.youchain.utils;
|
|||
|
||||
import cn.hutool.json.JSONObject;
|
||||
import cn.hutool.json.JSONUtil;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.apache.commons.compress.utils.IOUtils;
|
||||
|
||||
import javax.net.ssl.HttpsURLConnection;
|
||||
import javax.net.ssl.SSLContext;
|
||||
import javax.net.ssl.TrustManager;
|
||||
import javax.net.ssl.X509TrustManager;
|
||||
import java.io.BufferedReader;
|
||||
import java.io.DataOutputStream;
|
||||
import java.io.InputStream;
|
||||
import java.io.InputStreamReader;
|
||||
import java.net.HttpURLConnection;
|
||||
import java.net.URL;
|
||||
import java.net.URLConnection;
|
||||
import java.security.cert.CertificateException;
|
||||
import java.security.cert.X509Certificate;
|
||||
|
||||
@Slf4j
|
||||
public class HttpPostUtil {
|
||||
public static String sendPostReq(String api_url, String request){
|
||||
public static String sendPostReq(String api_url, String request) {
|
||||
InputStream instr = null;
|
||||
String str = "";
|
||||
try {
|
||||
|
|
@ -35,9 +46,41 @@ public class HttpPostUtil {
|
|||
System.out.println("返回空");
|
||||
}
|
||||
str = ResponseString;
|
||||
}catch (Exception e){
|
||||
System.out.println("接口异常!");
|
||||
// throw new Error(e.getMessage());
|
||||
} catch (Exception e) {
|
||||
log.info("接口异常");
|
||||
// throw new Error(e.getMessage());
|
||||
}
|
||||
return str;
|
||||
}
|
||||
|
||||
public static String sendPostReq(String api_url, String request, String token) {
|
||||
InputStream instr = null;
|
||||
String str = "";
|
||||
try {
|
||||
URL url = new URL(api_url);
|
||||
URLConnection urlCon = url.openConnection();
|
||||
urlCon.setConnectTimeout(3000);
|
||||
byte[] xmlData = request.getBytes();
|
||||
urlCon.setDoOutput(true);
|
||||
urlCon.setDoInput(true);
|
||||
urlCon.setUseCaches(false);
|
||||
urlCon.setRequestProperty("token", token);
|
||||
urlCon.setRequestProperty("content-Type", "application/json");
|
||||
urlCon.setRequestProperty("charset", "UTF-8");
|
||||
urlCon.setRequestProperty("Content-length", String.valueOf(xmlData.length));
|
||||
DataOutputStream printout = new DataOutputStream(urlCon.getOutputStream());
|
||||
printout.write(xmlData);
|
||||
printout.flush();
|
||||
printout.close();
|
||||
instr = urlCon.getInputStream();
|
||||
byte[] bis = IOUtils.toByteArray(instr);
|
||||
String ResponseString = new String(bis, "UTF-8");
|
||||
if ((ResponseString == null) || ("".equals(ResponseString.trim()))) {
|
||||
System.out.println("返回空");
|
||||
}
|
||||
str = ResponseString;
|
||||
} catch (Exception e) {
|
||||
log.info("接口异常");
|
||||
}
|
||||
return str;
|
||||
}
|
||||
|
|
|
|||
Binary file not shown.
|
|
@ -1,3 +0,0 @@
|
|||
artifactId=youchain-common
|
||||
groupId=com.youchain
|
||||
version=2.6
|
||||
|
|
@ -1,73 +0,0 @@
|
|||
com\youchain\exception\handler\GlobalExceptionHandler.class
|
||||
com\youchain\base\BaseDTO.class
|
||||
com\youchain\exception\BadRequestException.class
|
||||
com\youchain\utils\ElAdminConstant$Url.class
|
||||
com\youchain\utils\QueryHelp$1.class
|
||||
com\youchain\config\SwaggerDataConfig$Page.class
|
||||
com\youchain\utils\PageUtil.class
|
||||
com\youchain\utils\StringUtils.class
|
||||
com\youchain\config\RsaProperties.class
|
||||
com\youchain\utils\enums\DataScopeEnum.class
|
||||
com\youchain\utils\ThrowableUtil.class
|
||||
com\youchain\exception\BadConfigurationException.class
|
||||
com\youchain\exception\EntityNotFoundException.class
|
||||
com\youchain\annotation\AnonymousAccess.class
|
||||
com\youchain\config\SwaggerConfig.class
|
||||
com\youchain\utils\RedisUtils.class
|
||||
com\youchain\utils\SecurityUtils.class
|
||||
com\youchain\base\BaseEntity.class
|
||||
com\youchain\config\RedisConfig.class
|
||||
com\youchain\annotation\rest\AnonymousPostMapping.class
|
||||
com\youchain\utils\CallBack.class
|
||||
com\youchain\utils\MyExcelWriter.class
|
||||
com\youchain\config\SwaggerDataConfig.class
|
||||
com\youchain\utils\EncryptUtils.class
|
||||
com\youchain\utils\RequestHolder.class
|
||||
com\youchain\annotation\Query$Type.class
|
||||
com\youchain\utils\RsaUtils$RsaKeyPair.class
|
||||
com\youchain\aspect\LimitAspect.class
|
||||
com\youchain\base\BaseMapper.class
|
||||
com\youchain\config\ElPermissionConfig.class
|
||||
com\youchain\config\FileProperties.class
|
||||
com\youchain\config\StringRedisSerializer.class
|
||||
com\youchain\annotation\Query.class
|
||||
com\youchain\annotation\Limit.class
|
||||
com\youchain\annotation\rest\AnonymousGetMapping.class
|
||||
com\youchain\annotation\rest\AnonymousPatchMapping.class
|
||||
com\youchain\utils\CodeForYmYtil.class
|
||||
com\youchain\base\BaseEntity$Create.class
|
||||
com\youchain\annotation\DataPermission.class
|
||||
com\youchain\config\RedisConfig$1.class
|
||||
com\youchain\utils\CloseUtil.class
|
||||
com\youchain\utils\SpringContextHolder.class
|
||||
com\youchain\utils\ValidationUtil.class
|
||||
com\youchain\base\BaseEntity$Update.class
|
||||
com\youchain\annotation\rest\AnonymousPutMapping.class
|
||||
com\youchain\config\FileProperties$ElPath.class
|
||||
com\youchain\config\FastJsonRedisSerializer.class
|
||||
com\youchain\exception\handler\ApiResult.class
|
||||
com\youchain\utils\FileUtil.class
|
||||
org\apache\poi\util\XMLHelper$DocHelperErrorHandler.class
|
||||
com\youchain\utils\RsaUtils.class
|
||||
com\youchain\utils\DateUtil.class
|
||||
com\youchain\config\ElAdminProperties.class
|
||||
com\youchain\utils\QueryHelp.class
|
||||
com\youchain\utils\enums\RequestMethodEnum.class
|
||||
com\youchain\utils\CacheKey.class
|
||||
com\youchain\utils\enums\CodeEnum.class
|
||||
com\youchain\aspect\LimitType.class
|
||||
com\youchain\config\AuditorConfig.class
|
||||
org\apache\poi\xssf\streaming\SXSSFCreationHelper.class
|
||||
com\youchain\utils\enums\CodeBiEnum.class
|
||||
com\youchain\config\SwaggerDataConfig$1.class
|
||||
com\youchain\annotation\rest\AnonymousDeleteMapping.class
|
||||
com\youchain\exception\EntityExistException.class
|
||||
com\youchain\annotation\Query$Join.class
|
||||
org\apache\poi\util\XMLHelper$SecurityFeature.class
|
||||
com\youchain\utils\ElAdminConstant.class
|
||||
com\youchain\utils\TranslatorUtil.class
|
||||
com\youchain\exception\handler\ApiError.class
|
||||
org\apache\poi\util\XMLHelper$SecurityProperty.class
|
||||
org\apache\poi\util\XMLHelper.class
|
||||
com\youchain\utils\HttpPostUtil.class
|
||||
org\apache\poi\util\XMLHelper$1.class
|
||||
|
|
@ -1,55 +0,0 @@
|
|||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\main\java\com\youchain\annotation\rest\AnonymousPostMapping.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\main\java\com\youchain\utils\enums\DataScopeEnum.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\main\java\com\youchain\config\AuditorConfig.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\main\java\com\youchain\exception\handler\ApiError.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\main\java\com\youchain\utils\MyExcelWriter.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\main\java\com\youchain\config\ElAdminProperties.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\main\java\com\youchain\annotation\rest\AnonymousPatchMapping.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\main\java\com\youchain\exception\handler\GlobalExceptionHandler.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\main\java\com\youchain\exception\BadConfigurationException.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\main\java\com\youchain\exception\EntityNotFoundException.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\main\java\com\youchain\exception\handler\ApiResult.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\main\java\com\youchain\annotation\Query.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\main\java\com\youchain\utils\enums\RequestMethodEnum.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\main\java\com\youchain\annotation\AnonymousAccess.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\main\java\com\youchain\base\BaseEntity.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\main\java\com\youchain\exception\BadRequestException.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\main\java\com\youchain\config\RsaProperties.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\main\java\com\youchain\exception\EntityExistException.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\main\java\com\youchain\utils\RedisUtils.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\main\java\com\youchain\annotation\rest\AnonymousGetMapping.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\main\java\com\youchain\config\FileProperties.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\main\java\com\youchain\aspect\LimitType.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\main\java\com\youchain\utils\CallBack.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\main\java\com\youchain\base\BaseDTO.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\main\java\com\youchain\utils\DateUtil.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\main\java\com\youchain\annotation\Limit.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\main\java\org\apache\poi\xssf\streaming\SXSSFCreationHelper.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\main\java\com\youchain\utils\ThrowableUtil.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\main\java\com\youchain\utils\SecurityUtils.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\main\java\com\youchain\utils\TranslatorUtil.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\main\java\org\apache\poi\util\XMLHelper.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\main\java\com\youchain\utils\SpringContextHolder.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\main\java\com\youchain\config\ElPermissionConfig.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\main\java\com\youchain\utils\enums\CodeBiEnum.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\main\java\com\youchain\aspect\LimitAspect.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\main\java\com\youchain\base\BaseMapper.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\main\java\com\youchain\config\SwaggerConfig.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\main\java\com\youchain\utils\CloseUtil.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\main\java\com\youchain\utils\FileUtil.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\main\java\com\youchain\utils\HttpPostUtil.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\main\java\com\youchain\config\RedisConfig.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\main\java\com\youchain\utils\ElAdminConstant.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\main\java\com\youchain\annotation\rest\AnonymousDeleteMapping.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\main\java\com\youchain\utils\QueryHelp.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\main\java\com\youchain\annotation\DataPermission.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\main\java\com\youchain\utils\RsaUtils.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\main\java\com\youchain\utils\RequestHolder.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\main\java\com\youchain\utils\EncryptUtils.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\main\java\com\youchain\utils\CodeForYmYtil.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\main\java\com\youchain\utils\PageUtil.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\main\java\com\youchain\utils\CacheKey.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\main\java\com\youchain\utils\StringUtils.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\main\java\com\youchain\annotation\rest\AnonymousPutMapping.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\main\java\com\youchain\utils\enums\CodeEnum.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\main\java\com\youchain\utils\ValidationUtil.java
|
||||
|
|
@ -1,4 +0,0 @@
|
|||
com\youchain\utils\FileUtilTest.class
|
||||
com\youchain\utils\EncryptUtilsTest.class
|
||||
com\youchain\utils\StringUtilsTest.class
|
||||
com\youchain\utils\DateUtilsTest.class
|
||||
|
|
@ -1,4 +0,0 @@
|
|||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\test\java\com\youchain\utils\EncryptUtilsTest.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\test\java\com\youchain\utils\StringUtilsTest.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\test\java\com\youchain\utils\DateUtilsTest.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-common\src\test\java\com\youchain\utils\FileUtilTest.java
|
||||
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
|
|
@ -1,3 +0,0 @@
|
|||
artifactId=youchain-generator
|
||||
groupId=com.youchain
|
||||
version=2.6
|
||||
|
|
@ -1,13 +0,0 @@
|
|||
com\youchain\repository\ColumnInfoRepository.class
|
||||
com\youchain\domain\GenConfig.class
|
||||
com\youchain\rest\GenConfigController.class
|
||||
com\youchain\service\impl\GenConfigServiceImpl.class
|
||||
com\youchain\service\impl\GeneratorServiceImpl.class
|
||||
com\youchain\service\GeneratorService.class
|
||||
com\youchain\utils\GenUtil.class
|
||||
com\youchain\service\GenConfigService.class
|
||||
com\youchain\domain\vo\TableInfo.class
|
||||
com\youchain\repository\GenConfigRepository.class
|
||||
com\youchain\utils\ColUtil.class
|
||||
com\youchain\domain\ColumnInfo.class
|
||||
com\youchain\rest\GeneratorController.class
|
||||
|
|
@ -1,13 +0,0 @@
|
|||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-generator\src\main\java\com\youchain\utils\GenUtil.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-generator\src\main\java\com\youchain\service\GeneratorService.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-generator\src\main\java\com\youchain\utils\ColUtil.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-generator\src\main\java\com\youchain\service\impl\GenConfigServiceImpl.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-generator\src\main\java\com\youchain\rest\GeneratorController.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-generator\src\main\java\com\youchain\domain\ColumnInfo.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-generator\src\main\java\com\youchain\service\GenConfigService.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-generator\src\main\java\com\youchain\service\impl\GeneratorServiceImpl.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-generator\src\main\java\com\youchain\repository\GenConfigRepository.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-generator\src\main\java\com\youchain\repository\ColumnInfoRepository.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-generator\src\main\java\com\youchain\domain\GenConfig.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-generator\src\main\java\com\youchain\rest\GenConfigController.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-generator\src\main\java\com\youchain\domain\vo\TableInfo.java
|
||||
Binary file not shown.
|
|
@ -9,7 +9,7 @@ import org.springframework.stereotype.Component;
|
|||
|
||||
@Generated(
|
||||
value = "org.mapstruct.ap.MappingProcessor",
|
||||
date = "2024-04-07T17:46:39+0800",
|
||||
date = "2024-04-11T14:17:39+0800",
|
||||
comments = "version: 1.4.2.Final, compiler: javac, environment: Java 1.8.0_202 (Oracle Corporation)"
|
||||
)
|
||||
@Component
|
||||
|
|
|
|||
|
|
@ -9,7 +9,7 @@ import org.springframework.stereotype.Component;
|
|||
|
||||
@Generated(
|
||||
value = "org.mapstruct.ap.MappingProcessor",
|
||||
date = "2024-04-07T17:46:40+0800",
|
||||
date = "2024-04-11T14:17:40+0800",
|
||||
comments = "version: 1.4.2.Final, compiler: javac, environment: Java 1.8.0_202 (Oracle Corporation)"
|
||||
)
|
||||
@Component
|
||||
|
|
|
|||
|
|
@ -1,3 +0,0 @@
|
|||
artifactId=youchain-logging
|
||||
groupId=com.youchain
|
||||
version=2.6
|
||||
|
|
@ -1,14 +0,0 @@
|
|||
com\youchain\repository\LogRepository.class
|
||||
com\youchain\service\mapstruct\LogErrorMapperImpl.class
|
||||
com\youchain\service\impl\LogServiceImpl.class
|
||||
com\youchain\rest\LogController.class
|
||||
com\youchain\service\mapstruct\LogErrorMapper.class
|
||||
com\youchain\service\dto\LogSmallDTO.class
|
||||
com\youchain\service\dto\LogQueryCriteria.class
|
||||
com\youchain\service\LogService.class
|
||||
com\youchain\service\mapstruct\LogSmallMapper.class
|
||||
com\youchain\service\dto\LogErrorDTO.class
|
||||
com\youchain\domain\Log.class
|
||||
com\youchain\annotation\Log.class
|
||||
com\youchain\aspect\LogAspect.class
|
||||
com\youchain\service\mapstruct\LogSmallMapperImpl.class
|
||||
|
|
@ -1,12 +0,0 @@
|
|||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-logging\src\main\java\com\youchain\service\mapstruct\LogErrorMapper.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-logging\src\main\java\com\youchain\rest\LogController.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-logging\src\main\java\com\youchain\domain\Log.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-logging\src\main\java\com\youchain\service\LogService.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-logging\src\main\java\com\youchain\service\dto\LogErrorDTO.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-logging\src\main\java\com\youchain\service\impl\LogServiceImpl.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-logging\src\main\java\com\youchain\repository\LogRepository.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-logging\src\main\java\com\youchain\service\mapstruct\LogSmallMapper.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-logging\src\main\java\com\youchain\aspect\LogAspect.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-logging\src\main\java\com\youchain\service\dto\LogQueryCriteria.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-logging\src\main\java\com\youchain\service\dto\LogSmallDTO.java
|
||||
E:\WMS_Project\hefeihvac\hefeihvac_java\youchain-logging\src\main\java\com\youchain\annotation\Log.java
|
||||
Binary file not shown.
|
|
@ -0,0 +1,192 @@
|
|||
/*
|
||||
* Copyright 2019-2020 Zheng Jie
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
package com.youchain.businessdata.domain;
|
||||
|
||||
import com.youchain.base.BaseEntity;
|
||||
import com.youchain.basicdata.domain.Item;
|
||||
import com.youchain.basicdata.service.dto.ItemDto;
|
||||
import lombok.Data;
|
||||
import cn.hutool.core.bean.BeanUtil;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import cn.hutool.core.bean.copier.CopyOptions;
|
||||
|
||||
import javax.persistence.*;
|
||||
import javax.validation.constraints.*;
|
||||
import java.sql.Timestamp;
|
||||
import java.io.Serializable;
|
||||
|
||||
/**
|
||||
* @author huojin
|
||||
* @website https://eladmin.vip
|
||||
* @description /
|
||||
* @date 2024-04-10
|
||||
**/
|
||||
@Entity
|
||||
@Data
|
||||
@Table(name = "data_mo")
|
||||
public class Mo extends BaseEntity implements Serializable {
|
||||
|
||||
@Id
|
||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||
@Column(name = "`id`")
|
||||
@ApiModelProperty(value = "id")
|
||||
private Integer id;
|
||||
|
||||
@Column(name = "`label_no`", unique = true)
|
||||
@ApiModelProperty(value = "MO票")
|
||||
private String labelNo;
|
||||
|
||||
@Column(name = "`label_type`")
|
||||
@ApiModelProperty(value = "标签类型")
|
||||
private String labelType;
|
||||
|
||||
@Column(name = "`label_state`")
|
||||
@ApiModelProperty(value = "标签状态")
|
||||
private String labelState;
|
||||
|
||||
@Column(name = "`delivery_header_id`")
|
||||
@ApiModelProperty(value = "送货单头ID;通过该字段能找到002接口送货单")
|
||||
private Integer deliveryHeaderId;
|
||||
|
||||
@Column(name = "`source_system`")
|
||||
@ApiModelProperty(value = "来源系统")
|
||||
private String sourceSystem;
|
||||
|
||||
@Column(name = "`qty`")
|
||||
@ApiModelProperty(value = "可用数量")
|
||||
private Double qty;
|
||||
|
||||
@Column(name = "`work_order_id`")
|
||||
@ApiModelProperty(value = "工单Id")
|
||||
private Integer workOrderId;
|
||||
|
||||
@Column(name = "`work_order_name`")
|
||||
@ApiModelProperty(value = "工单编号")
|
||||
private String workOrderName;
|
||||
|
||||
@Column(name = "`self_work_order_id`")
|
||||
@ApiModelProperty(value = "自制件工单id")
|
||||
private Integer selfWorkOrderId;
|
||||
|
||||
@Column(name = "`self_work_order_name`")
|
||||
@ApiModelProperty(value = "自制件工单编号")
|
||||
private String selfWorkOrderName;
|
||||
|
||||
@Column(name = "`order_no`")
|
||||
@ApiModelProperty(value = "工单号")
|
||||
private String orderNo;
|
||||
|
||||
|
||||
@OneToOne
|
||||
@JoinColumn(name = "`item_id`",nullable = false)
|
||||
@NotNull
|
||||
@ApiModelProperty(value = "物料")
|
||||
private Item item;
|
||||
|
||||
@Column(name = "`check_result`")
|
||||
@ApiModelProperty(value = "检验状态")
|
||||
private String checkResult;
|
||||
|
||||
@Column(name = "`delete_flag`")
|
||||
@ApiModelProperty(value = "数据有效性")
|
||||
private Boolean deleteFlag;
|
||||
|
||||
@Column(name = "`workshop_code`")
|
||||
@ApiModelProperty(value = "车间编号")
|
||||
private String workshopCode;
|
||||
|
||||
@Column(name = "`workshop_name`")
|
||||
@ApiModelProperty(value = "车间描述")
|
||||
private String workshopName;
|
||||
|
||||
@Column(name = "`mo_line_code`")
|
||||
@ApiModelProperty(value = "产线编码")
|
||||
private String moLineCode;
|
||||
|
||||
@Column(name = "`mo_line_name`")
|
||||
@ApiModelProperty(value = "产线描述")
|
||||
private String moLineName;
|
||||
|
||||
@Column(name = "`inv_code`")
|
||||
@ApiModelProperty(value = "MLS子库")
|
||||
private String invCode;
|
||||
|
||||
@Column(name = "`goods_area_code`")
|
||||
@ApiModelProperty(value = "MLS货区")
|
||||
private String goodsAreaCode;
|
||||
|
||||
@Column(name = "`goods_location_code`")
|
||||
@ApiModelProperty(value = "MLS货位")
|
||||
private String goodsLocationCode;
|
||||
|
||||
@Column(name = "`datetime_stock_in`")
|
||||
@ApiModelProperty(value = "MLS入库时间")
|
||||
private Timestamp datetimeStockIn;
|
||||
|
||||
@Column(name = "`mls_create_time`")
|
||||
@ApiModelProperty(value = "MLS创建时间")
|
||||
private Timestamp mlsCreateTime;
|
||||
|
||||
@Column(name = "`mls_update_time`")
|
||||
@ApiModelProperty(value = "MLS修改时间")
|
||||
private Timestamp mlsUpdateTime;
|
||||
|
||||
@Column(name = "`create_user_code`")
|
||||
@ApiModelProperty(value = "MLS创建人")
|
||||
private String createUserCode;
|
||||
|
||||
@Column(name = "`update_user_code`")
|
||||
@ApiModelProperty(value = "MLS修改人")
|
||||
private String updateUserCode;
|
||||
|
||||
|
||||
public void copy(Mo source) {
|
||||
BeanUtil.copyProperties(source, this, CopyOptions.create().setIgnoreNullValue(true));
|
||||
}
|
||||
|
||||
public Mo(){
|
||||
|
||||
}
|
||||
|
||||
public Mo(String labelNo, String labelType, String labelState, Integer deliveryHeaderId, String sourceSystem, Double qty, Integer workOrderId, String workOrderName, Integer selfWorkOrderId, String selfWorkOrderName, String orderNo, Item item, String checkResult, Boolean deleteFlag, String workshopCode, String workshopName, String moLineCode, String moLineName, String invCode, String goodsAreaCode, String goodsLocationCode, Timestamp datetimeStockIn, Timestamp mlsCreateTime, Timestamp mlsUpdateTime, String createUserCode, String updateUserCode) {
|
||||
this.labelNo = labelNo;
|
||||
this.labelType = labelType;
|
||||
this.labelState = labelState;
|
||||
this.deliveryHeaderId = deliveryHeaderId;
|
||||
this.sourceSystem = sourceSystem;
|
||||
this.qty = qty;
|
||||
this.workOrderId = workOrderId;
|
||||
this.workOrderName = workOrderName;
|
||||
this.selfWorkOrderId = selfWorkOrderId;
|
||||
this.selfWorkOrderName = selfWorkOrderName;
|
||||
this.orderNo = orderNo;
|
||||
this.item = item;
|
||||
this.checkResult = checkResult;
|
||||
this.deleteFlag = deleteFlag;
|
||||
this.workshopCode = workshopCode;
|
||||
this.workshopName = workshopName;
|
||||
this.moLineCode = moLineCode;
|
||||
this.moLineName = moLineName;
|
||||
this.invCode = invCode;
|
||||
this.goodsAreaCode = goodsAreaCode;
|
||||
this.goodsLocationCode = goodsLocationCode;
|
||||
this.datetimeStockIn = datetimeStockIn;
|
||||
this.mlsCreateTime = mlsCreateTime;
|
||||
this.mlsUpdateTime = mlsUpdateTime;
|
||||
this.createUserCode = createUserCode;
|
||||
this.updateUserCode = updateUserCode;
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,167 @@
|
|||
/*
|
||||
* Copyright 2019-2020 Zheng Jie
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
package com.youchain.businessdata.domain;
|
||||
|
||||
import com.youchain.base.BaseEntity;
|
||||
import lombok.Data;
|
||||
import cn.hutool.core.bean.BeanUtil;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import cn.hutool.core.bean.copier.CopyOptions;
|
||||
|
||||
import javax.persistence.*;
|
||||
import javax.validation.constraints.*;
|
||||
import java.io.Serializable;
|
||||
import java.sql.Timestamp;
|
||||
|
||||
/**
|
||||
* @author huojin
|
||||
* @website https://eladmin.vip
|
||||
* @description /
|
||||
* @date 2024-04-08
|
||||
**/
|
||||
@Entity
|
||||
@Data
|
||||
@Table(name = "data_order")
|
||||
public class Order extends BaseEntity implements Serializable {
|
||||
|
||||
@Id
|
||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||
@Column(name = "`id`")
|
||||
@ApiModelProperty(value = "id")
|
||||
private Integer id;
|
||||
|
||||
@Column(name = "`delivery_header_id`")
|
||||
@ApiModelProperty(value = "送货单头ID和003接口关联")
|
||||
private Integer deliveryHeaderId;
|
||||
|
||||
@Column(name = "`delivery_line_id`")
|
||||
@ApiModelProperty(value = "送货单行ID")
|
||||
private Integer deliveryLineId;
|
||||
|
||||
@Column(name = "`delivery_notify_line_id`")
|
||||
@ApiModelProperty(value = "送货通知单行ID")
|
||||
private Integer deliveryNotifyLineId;
|
||||
|
||||
@Column(name = "`delivery_number`")
|
||||
@ApiModelProperty(value = "送货单号")
|
||||
private String deliveryNumber;
|
||||
|
||||
@Column(name = "`barcode_number`", unique = true)
|
||||
@NotBlank
|
||||
@ApiModelProperty(value = "送货单条码号")
|
||||
private String barcodeNumber;
|
||||
|
||||
@Column(name = "`delivery_status`")
|
||||
@ApiModelProperty(value = "送货单状态")
|
||||
private String deliveryStatus;
|
||||
|
||||
@Column(name = "`received_inv_code`")
|
||||
@ApiModelProperty(value = "mls接收子库编码")
|
||||
private String receivedInvCode;
|
||||
|
||||
@Column(name = "`received_inv_name`")
|
||||
@ApiModelProperty(value = "mls接收子库名称")
|
||||
private String receivedInvName;
|
||||
|
||||
@Column(name = "`received_area_code`")
|
||||
@ApiModelProperty(value = "mls接收货区编码")
|
||||
private String receivedAreaCode;
|
||||
|
||||
@Column(name = "`received_area_name`")
|
||||
@ApiModelProperty(value = "mls接收货区名称")
|
||||
private String receivedAreaName;
|
||||
|
||||
@Column(name = "`received_location_code`")
|
||||
@ApiModelProperty(value = "mls货位编码")
|
||||
private String receivedLocationCode;
|
||||
|
||||
@Column(name = "`received_location_name`")
|
||||
@ApiModelProperty(value = "mls货位名称")
|
||||
private String receivedLocationName;
|
||||
|
||||
@Column(name = "`item_code`")
|
||||
@ApiModelProperty(value = "物料编码")
|
||||
private String itemCode;
|
||||
|
||||
@Column(name = "`delivery_qty`")
|
||||
@ApiModelProperty(value = "计划数量")
|
||||
private Double deliveryQty;
|
||||
|
||||
@Column(name = "`in_inspector`")
|
||||
@ApiModelProperty(value = "检验员")
|
||||
private String inInspector;
|
||||
|
||||
@Column(name = "`received_qty`")
|
||||
@ApiModelProperty(value = "实际接收数量")
|
||||
private Double receivedQty;
|
||||
|
||||
@Column(name = "`is_iqc_inspected`")
|
||||
@ApiModelProperty(value = "Y-已检验N-未检验")
|
||||
private String isIqcInspected;
|
||||
|
||||
@Column(name = "`iqc_result`")
|
||||
@ApiModelProperty(value = "检验结果(不合格:REJECT,合格:ACCEPT)")
|
||||
private String iqcResult;
|
||||
|
||||
@Column(name = "`is_created_label`")
|
||||
@ApiModelProperty(value = "是否已生成标签")
|
||||
private String isCreatedLabel;
|
||||
|
||||
@Column(name = "`supplier_code`")
|
||||
@ApiModelProperty(value = "供应商编码")
|
||||
private String supplierCode;
|
||||
|
||||
@Column(name = "`supplier_name`")
|
||||
@ApiModelProperty(value = "供应商名称")
|
||||
private String supplierName;
|
||||
|
||||
@Column(name = "`mls_update_time`")
|
||||
@ApiModelProperty(value = "MLS修改时间")
|
||||
private Timestamp mlsUpdateTime;
|
||||
|
||||
public void copy(Order source) {
|
||||
BeanUtil.copyProperties(source, this, CopyOptions.create().setIgnoreNullValue(true));
|
||||
}
|
||||
|
||||
public Order() {
|
||||
|
||||
}
|
||||
|
||||
public Order(Integer deliveryHeaderId, Integer deliveryLineId, Integer deliveryNotifyLineId, String deliveryNumber, String barcodeNumber, String deliveryStatus, String receivedInvCode, String receivedInvName, String receivedAreaCode, String receivedAreaName, String receivedLocationCode, String receivedLocationName, String itemCode, Double deliveryQty, String inInspector, Double receivedQty, String isIqcInspected, String iqcResult, String isCreatedLabel, String supplierCode, String supplierName, Timestamp mlsUpdateTime) {
|
||||
this.deliveryHeaderId = deliveryHeaderId;
|
||||
this.deliveryLineId = deliveryLineId;
|
||||
this.deliveryNotifyLineId = deliveryNotifyLineId;
|
||||
this.deliveryNumber = deliveryNumber;
|
||||
this.barcodeNumber = barcodeNumber;
|
||||
this.deliveryStatus = deliveryStatus;
|
||||
this.receivedInvCode = receivedInvCode;
|
||||
this.receivedInvName = receivedInvName;
|
||||
this.receivedAreaCode = receivedAreaCode;
|
||||
this.receivedAreaName = receivedAreaName;
|
||||
this.receivedLocationCode = receivedLocationCode;
|
||||
this.receivedLocationName = receivedLocationName;
|
||||
this.itemCode = itemCode;
|
||||
this.deliveryQty = deliveryQty;
|
||||
this.inInspector = inInspector;
|
||||
this.receivedQty = receivedQty;
|
||||
this.isIqcInspected = isIqcInspected;
|
||||
this.iqcResult = iqcResult;
|
||||
this.isCreatedLabel = isCreatedLabel;
|
||||
this.supplierCode = supplierCode;
|
||||
this.supplierName = supplierName;
|
||||
this.mlsUpdateTime = mlsUpdateTime;
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,30 @@
|
|||
package com.youchain.businessdata.inputJson;
|
||||
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* MO票入参
|
||||
*/
|
||||
@Data
|
||||
public class MoInfo {
|
||||
@ApiModelProperty(value = "接口编码")
|
||||
@Schema(example = "MLS-WQ-003")
|
||||
String ifaceCode;
|
||||
|
||||
@ApiModelProperty(value = "来源系统")
|
||||
@Schema(example = "WQ")
|
||||
String sourceSystem;
|
||||
|
||||
@ApiModelProperty(value = "当前页码")
|
||||
@Schema(example = "1")
|
||||
int pageNo;
|
||||
|
||||
@ApiModelProperty(value = "每页记录数")
|
||||
@Schema(example = "100")
|
||||
int pageSize;
|
||||
|
||||
@ApiModelProperty(value = "参数")
|
||||
Params params;
|
||||
}
|
||||
|
|
@ -0,0 +1,34 @@
|
|||
package com.youchain.businessdata.inputJson;
|
||||
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import io.swagger.annotations.ApiParam;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* 送货单入参
|
||||
*/
|
||||
@Data
|
||||
public class OrderInfo {
|
||||
@ApiModelProperty(value = "接口编码")
|
||||
@Schema(example = "MLS-WQ-002")
|
||||
String ifaceCode;
|
||||
|
||||
@ApiModelProperty(value = "来源系统")
|
||||
@Schema(example = "WQ")
|
||||
String sourceSystem;
|
||||
|
||||
@ApiModelProperty(value = "参数")
|
||||
Params params;
|
||||
|
||||
public OrderInfo() {
|
||||
|
||||
}
|
||||
|
||||
public OrderInfo(String ifaceCode, String sourceSystem, Params params) {
|
||||
this.ifaceCode = ifaceCode;
|
||||
this.sourceSystem = sourceSystem;
|
||||
this.params = params;
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,52 @@
|
|||
package com.youchain.businessdata.inputJson;
|
||||
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
|
||||
import java.util.Set;
|
||||
|
||||
@Data
|
||||
public class Params {
|
||||
@ApiModelProperty(value = "库存组织id")
|
||||
@Schema(example = "100059")
|
||||
int orgId;
|
||||
|
||||
@ApiModelProperty(value = "子库编码")
|
||||
@Schema(example = "[\"MA1181\", \"MA1181\"]")
|
||||
Set invCodes;
|
||||
|
||||
@ApiModelProperty(value = "检验结果")
|
||||
String iqcResult;
|
||||
|
||||
@ApiModelProperty(value = "开始时间")
|
||||
@Schema(example = "2023-07-03 00:00:00")
|
||||
String startTime;
|
||||
|
||||
@ApiModelProperty(value = "结束时间")
|
||||
@Schema(example = "2023-07-03 23:59:59")
|
||||
String endTime;
|
||||
|
||||
@ApiModelProperty(value = "当前页码")
|
||||
@Schema(example = "1")
|
||||
int pageNo;
|
||||
|
||||
@ApiModelProperty(value = "每页记录数")
|
||||
@Schema(example = "100")
|
||||
int pageSize;
|
||||
|
||||
public Params(){
|
||||
|
||||
}
|
||||
|
||||
public Params(int orgId, Set invCodes, String iqcResult, String startTime, String endTime,int pageNo,int pageSize) {
|
||||
this.orgId = orgId;
|
||||
this.invCodes = invCodes;
|
||||
this.iqcResult = iqcResult;
|
||||
this.startTime = startTime;
|
||||
this.endTime = endTime;
|
||||
this.pageNo = pageNo;
|
||||
this.pageSize = pageSize;
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,29 @@
|
|||
/*
|
||||
* Copyright 2019-2020 Zheng Jie
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
package com.youchain.businessdata.repository;
|
||||
|
||||
import com.youchain.businessdata.domain.Mo;
|
||||
import org.springframework.data.jpa.repository.JpaRepository;
|
||||
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
|
||||
|
||||
/**
|
||||
* @website https://eladmin.vip
|
||||
* @author huojin
|
||||
* @date 2024-04-10
|
||||
**/
|
||||
public interface MoRepository extends JpaRepository<Mo, Integer>, JpaSpecificationExecutor<Mo> {
|
||||
|
||||
}
|
||||
|
|
@ -13,28 +13,16 @@
|
|||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
package ${package}.repository;
|
||||
package com.youchain.businessdata.repository;
|
||||
|
||||
import ${package}.domain.${className};
|
||||
import com.youchain.businessdata.domain.Order;
|
||||
import org.springframework.data.jpa.repository.JpaRepository;
|
||||
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
|
||||
|
||||
/**
|
||||
* @website https://eladmin.vip
|
||||
* @author ${author}
|
||||
* @date ${date}
|
||||
* @author huojin
|
||||
* @date 2024-04-08
|
||||
**/
|
||||
public interface ${className}Repository extends JpaRepository<${className}, ${pkColumnType}>, JpaSpecificationExecutor<${className}> {
|
||||
<#if columns??>
|
||||
<#list columns as column>
|
||||
<#if column.columnKey = 'UNI'>
|
||||
/**
|
||||
* 根据 ${column.capitalColumnName} 查询
|
||||
* @param ${column.columnName} /
|
||||
* @return /
|
||||
*/
|
||||
${className} findBy${column.capitalColumnName}(${column.columnType} ${column.columnName});
|
||||
</#if>
|
||||
</#list>
|
||||
</#if>
|
||||
public interface OrderRepository extends JpaRepository<Order, Integer>, JpaSpecificationExecutor<Order> {
|
||||
}
|
||||
|
|
@ -0,0 +1,71 @@
|
|||
package com.youchain.businessdata.rest;
|
||||
|
||||
import com.youchain.annotation.AnonymousAccess;
|
||||
import com.youchain.annotation.Log;
|
||||
import com.youchain.appupdate.inputJson.MissionStateCallback;
|
||||
import com.youchain.businessdata.inputJson.MoInfo;
|
||||
import com.youchain.businessdata.inputJson.OrderInfo;
|
||||
import com.youchain.businessdata.service.MlsService;
|
||||
import com.youchain.exception.handler.ApiResult;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.http.HttpStatus;
|
||||
import org.springframework.http.ResponseEntity;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestBody;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
|
||||
import static org.springframework.http.HttpStatus.BAD_REQUEST;
|
||||
import static org.springframework.http.HttpStatus.OK;
|
||||
|
||||
@RestController
|
||||
@RequiredArgsConstructor
|
||||
@Api(tags = "MLS")
|
||||
@RequestMapping("/api/mls/")
|
||||
@Slf4j
|
||||
public class MlsController {
|
||||
|
||||
private final MlsService mlsService;
|
||||
|
||||
@PostMapping("/getOrderInfo")
|
||||
@Log("获取送货单信息")
|
||||
@ApiOperation("获取送货单信息")
|
||||
@AnonymousAccess
|
||||
public ResponseEntity<Object> getOrderInfo(@RequestBody OrderInfo orderInfo) {
|
||||
String resultJson = mlsService.getOrderJson(orderInfo);
|
||||
if (resultJson == null || resultJson.length() == 0) {
|
||||
return new ResponseEntity<>(ApiResult.success(BAD_REQUEST.value(), "接口异常!", ""), HttpStatus.BAD_REQUEST);
|
||||
} else {
|
||||
try {
|
||||
mlsService.getOrderInfo(resultJson);
|
||||
return new ResponseEntity<>(ApiResult.success(OK.value(), "", resultJson), HttpStatus.OK);
|
||||
} catch (Exception e) {
|
||||
return new ResponseEntity<>(ApiResult.success(BAD_REQUEST.value(), e.getMessage(), ""), HttpStatus.BAD_REQUEST);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@PostMapping("/getMoInfo")
|
||||
@AnonymousAccess
|
||||
@Log("获取Mo票信息")
|
||||
@ApiOperation("获取Mo票信息")
|
||||
public ResponseEntity<Object> getMoInfo(@RequestBody MoInfo moInfo) {
|
||||
String resultJson = mlsService.getMoJson(moInfo);
|
||||
if (resultJson == null || resultJson.length() == 0) {
|
||||
return new ResponseEntity<>(ApiResult.success(BAD_REQUEST.value(), "接口异常!", ""), HttpStatus.BAD_REQUEST);
|
||||
} else {
|
||||
try {
|
||||
mlsService.getMoInfo(resultJson);
|
||||
return new ResponseEntity<>(ApiResult.success(OK.value(), "", resultJson), HttpStatus.OK);
|
||||
} catch (Exception e) {
|
||||
return new ResponseEntity<>(ApiResult.success(BAD_REQUEST.value(), e.getMessage(), ""), HttpStatus.BAD_REQUEST);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,87 @@
|
|||
/*
|
||||
* Copyright 2019-2020 Zheng Jie
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
package com.youchain.businessdata.rest;
|
||||
|
||||
import com.youchain.annotation.Log;
|
||||
import com.youchain.businessdata.domain.Mo;
|
||||
import com.youchain.businessdata.service.MoService;
|
||||
import com.youchain.businessdata.service.dto.MoQueryCriteria;
|
||||
import org.springframework.data.domain.Pageable;
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import org.springframework.http.HttpStatus;
|
||||
import org.springframework.http.ResponseEntity;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import io.swagger.annotations.*;
|
||||
import java.io.IOException;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
|
||||
/**
|
||||
* @website https://eladmin.vip
|
||||
* @author huojin
|
||||
* @date 2024-04-10
|
||||
**/
|
||||
@RestController
|
||||
@RequiredArgsConstructor
|
||||
@Api(tags = "mo管理")
|
||||
@RequestMapping("/api/mo")
|
||||
public class MoController {
|
||||
|
||||
private final MoService moService;
|
||||
|
||||
@Log("导出数据")
|
||||
@ApiOperation("导出数据")
|
||||
@GetMapping(value = "/download")
|
||||
@PreAuthorize("@el.check('mo:list')")
|
||||
public void exportMo(HttpServletResponse response, MoQueryCriteria criteria) throws IOException {
|
||||
moService.download(moService.queryAll(criteria), response);
|
||||
}
|
||||
|
||||
@GetMapping
|
||||
@Log("查询mo")
|
||||
@ApiOperation("查询mo")
|
||||
@PreAuthorize("@el.check('mo:list')")
|
||||
public ResponseEntity<Object> queryMo(MoQueryCriteria criteria, Pageable pageable){
|
||||
return new ResponseEntity<>(moService.queryAll(criteria,pageable),HttpStatus.OK);
|
||||
}
|
||||
|
||||
@PostMapping
|
||||
@Log("新增mo")
|
||||
@ApiOperation("新增mo")
|
||||
@PreAuthorize("@el.check('mo:add')")
|
||||
public ResponseEntity<Object> createMo(@Validated @RequestBody Mo resources){
|
||||
return new ResponseEntity<>(moService.create(resources),HttpStatus.CREATED);
|
||||
}
|
||||
|
||||
@PutMapping
|
||||
@Log("修改mo")
|
||||
@ApiOperation("修改mo")
|
||||
@PreAuthorize("@el.check('mo:edit')")
|
||||
public ResponseEntity<Object> updateMo(@Validated @RequestBody Mo resources){
|
||||
moService.update(resources);
|
||||
return new ResponseEntity<>(HttpStatus.NO_CONTENT);
|
||||
}
|
||||
|
||||
@DeleteMapping
|
||||
@Log("删除mo")
|
||||
@ApiOperation("删除mo")
|
||||
@PreAuthorize("@el.check('mo:del')")
|
||||
public ResponseEntity<Object> deleteMo(@RequestBody Integer[] ids) {
|
||||
moService.deleteAll(ids);
|
||||
return new ResponseEntity<>(HttpStatus.OK);
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,87 @@
|
|||
/*
|
||||
* Copyright 2019-2020 Zheng Jie
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
package com.youchain.businessdata.rest;
|
||||
|
||||
import com.youchain.annotation.Log;
|
||||
import com.youchain.businessdata.domain.Order;
|
||||
import com.youchain.businessdata.service.OrderService;
|
||||
import com.youchain.businessdata.service.dto.OrderQueryCriteria;
|
||||
import org.springframework.data.domain.Pageable;
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import org.springframework.http.HttpStatus;
|
||||
import org.springframework.http.ResponseEntity;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import io.swagger.annotations.*;
|
||||
import java.io.IOException;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
|
||||
/**
|
||||
* @website https://eladmin.vip
|
||||
* @author huojin
|
||||
* @date 2024-04-08
|
||||
**/
|
||||
@RestController
|
||||
@RequiredArgsConstructor
|
||||
@Api(tags = "order管理")
|
||||
@RequestMapping("/api/order")
|
||||
public class OrderController {
|
||||
|
||||
private final OrderService orderService;
|
||||
|
||||
@Log("导出数据")
|
||||
@ApiOperation("导出数据")
|
||||
@GetMapping(value = "/download")
|
||||
@PreAuthorize("@el.check('order:list')")
|
||||
public void exportOrder(HttpServletResponse response, OrderQueryCriteria criteria) throws IOException {
|
||||
orderService.download(orderService.queryAll(criteria), response);
|
||||
}
|
||||
|
||||
@GetMapping
|
||||
@Log("查询order")
|
||||
@ApiOperation("查询order")
|
||||
@PreAuthorize("@el.check('order:list')")
|
||||
public ResponseEntity<Object> queryOrder(OrderQueryCriteria criteria, Pageable pageable){
|
||||
return new ResponseEntity<>(orderService.queryAll(criteria,pageable),HttpStatus.OK);
|
||||
}
|
||||
|
||||
@PostMapping
|
||||
@Log("新增order")
|
||||
@ApiOperation("新增order")
|
||||
@PreAuthorize("@el.check('order:add')")
|
||||
public ResponseEntity<Object> createOrder(@Validated @RequestBody Order resources){
|
||||
return new ResponseEntity<>(orderService.create(resources),HttpStatus.CREATED);
|
||||
}
|
||||
|
||||
@PutMapping
|
||||
@Log("修改order")
|
||||
@ApiOperation("修改order")
|
||||
@PreAuthorize("@el.check('order:edit')")
|
||||
public ResponseEntity<Object> updateOrder(@Validated @RequestBody Order resources){
|
||||
orderService.update(resources);
|
||||
return new ResponseEntity<>(HttpStatus.NO_CONTENT);
|
||||
}
|
||||
|
||||
@DeleteMapping
|
||||
@Log("删除order")
|
||||
@ApiOperation("删除order")
|
||||
@PreAuthorize("@el.check('order:del')")
|
||||
public ResponseEntity<Object> deleteOrder(@RequestBody Integer[] ids) {
|
||||
orderService.deleteAll(ids);
|
||||
return new ResponseEntity<>(HttpStatus.OK);
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,37 @@
|
|||
package com.youchain.businessdata.service;
|
||||
|
||||
import com.youchain.annotation.Log;
|
||||
import com.youchain.businessdata.inputJson.MoInfo;
|
||||
import com.youchain.businessdata.inputJson.OrderInfo;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
|
||||
/**
|
||||
* MLS接口
|
||||
*/
|
||||
public interface MlsService {
|
||||
|
||||
/**
|
||||
* 获取送货单JSON
|
||||
* @return
|
||||
*/
|
||||
String getOrderJson(OrderInfo orderInfo);
|
||||
|
||||
/**
|
||||
* 获取送货单信息JSON
|
||||
* @return
|
||||
*/
|
||||
void getOrderInfo(String resultJson);
|
||||
|
||||
|
||||
/**
|
||||
* 获取MO票JSON
|
||||
* @return
|
||||
*/
|
||||
String getMoJson(MoInfo moInfo);
|
||||
|
||||
/**
|
||||
* 获取MO票信息
|
||||
* @return
|
||||
*/
|
||||
void getMoInfo(String resultJson);
|
||||
}
|
||||
|
|
@ -13,11 +13,11 @@
|
|||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
package ${package}.service;
|
||||
package com.youchain.businessdata.service;
|
||||
|
||||
import ${package}.domain.${className};
|
||||
import ${package}.service.dto.${className}Dto;
|
||||
import ${package}.service.dto.${className}QueryCriteria;
|
||||
import com.youchain.businessdata.domain.Mo;
|
||||
import com.youchain.businessdata.service.dto.MoDto;
|
||||
import com.youchain.businessdata.service.dto.MoQueryCriteria;
|
||||
import org.springframework.data.domain.Pageable;
|
||||
import java.util.Map;
|
||||
import java.util.List;
|
||||
|
|
@ -27,10 +27,10 @@ import javax.servlet.http.HttpServletResponse;
|
|||
/**
|
||||
* @website https://eladmin.vip
|
||||
* @description 服务接口
|
||||
* @author ${author}
|
||||
* @date ${date}
|
||||
* @author huojin
|
||||
* @date 2024-04-10
|
||||
**/
|
||||
public interface ${className}Service {
|
||||
public interface MoService {
|
||||
|
||||
/**
|
||||
* 查询数据分页
|
||||
|
|
@ -38,40 +38,40 @@ public interface ${className}Service {
|
|||
* @param pageable 分页参数
|
||||
* @return Map<String,Object>
|
||||
*/
|
||||
Map<String,Object> queryAll(${className}QueryCriteria criteria, Pageable pageable);
|
||||
Map<String,Object> queryAll(MoQueryCriteria criteria, Pageable pageable);
|
||||
|
||||
/**
|
||||
* 查询所有数据不分页
|
||||
* @param criteria 条件参数
|
||||
* @return List<${className}Dto>
|
||||
* @return List<MoDto>
|
||||
*/
|
||||
List<${className}Dto> queryAll(${className}QueryCriteria criteria);
|
||||
List<MoDto> queryAll(MoQueryCriteria criteria);
|
||||
|
||||
/**
|
||||
* 根据ID查询
|
||||
* @param ${pkChangeColName} ID
|
||||
* @return ${className}Dto
|
||||
* @param id ID
|
||||
* @return MoDto
|
||||
*/
|
||||
${className}Dto findById(${pkColumnType} ${pkChangeColName});
|
||||
MoDto findById(Integer id);
|
||||
|
||||
/**
|
||||
* 创建
|
||||
* @param resources /
|
||||
* @return ${className}Dto
|
||||
* @return MoDto
|
||||
*/
|
||||
${className}Dto create(${className} resources);
|
||||
MoDto create(Mo resources);
|
||||
|
||||
/**
|
||||
* 编辑
|
||||
* @param resources /
|
||||
*/
|
||||
void update(${className} resources);
|
||||
void update(Mo resources);
|
||||
|
||||
/**
|
||||
* 多选删除
|
||||
* @param ids /
|
||||
*/
|
||||
void deleteAll(${pkColumnType}[] ids);
|
||||
void deleteAll(Integer[] ids);
|
||||
|
||||
/**
|
||||
* 导出数据
|
||||
|
|
@ -79,5 +79,5 @@ public interface ${className}Service {
|
|||
* @param response /
|
||||
* @throws IOException /
|
||||
*/
|
||||
void download(List<${className}Dto> all, HttpServletResponse response) throws IOException;
|
||||
void download(List<MoDto> all, HttpServletResponse response) throws IOException;
|
||||
}
|
||||
|
|
@ -0,0 +1,84 @@
|
|||
/*
|
||||
* Copyright 2019-2020 Zheng Jie
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
package com.youchain.businessdata.service;
|
||||
|
||||
import com.youchain.businessdata.domain.Order;
|
||||
import com.youchain.businessdata.service.dto.OrderDto;
|
||||
import com.youchain.businessdata.service.dto.OrderQueryCriteria;
|
||||
import org.springframework.data.domain.Pageable;
|
||||
import java.util.Map;
|
||||
import java.util.List;
|
||||
import java.io.IOException;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
|
||||
/**
|
||||
* @website https://eladmin.vip
|
||||
* @description 服务接口
|
||||
* @author huojin
|
||||
* @date 2024-04-08
|
||||
**/
|
||||
public interface OrderService {
|
||||
|
||||
/**
|
||||
* 查询数据分页
|
||||
* @param criteria 条件
|
||||
* @param pageable 分页参数
|
||||
* @return Map<String,Object>
|
||||
*/
|
||||
Map<String,Object> queryAll(OrderQueryCriteria criteria, Pageable pageable);
|
||||
|
||||
/**
|
||||
* 查询所有数据不分页
|
||||
* @param criteria 条件参数
|
||||
* @return List<OrderDto>
|
||||
*/
|
||||
List<OrderDto> queryAll(OrderQueryCriteria criteria);
|
||||
|
||||
/**
|
||||
* 根据ID查询
|
||||
* @param id ID
|
||||
* @return OrderDto
|
||||
*/
|
||||
OrderDto findById(Integer id);
|
||||
|
||||
/**
|
||||
* 创建
|
||||
* @param resources /
|
||||
* @return OrderDto
|
||||
*/
|
||||
OrderDto create(Order resources);
|
||||
|
||||
/**
|
||||
* 编辑
|
||||
* @param resources /
|
||||
*/
|
||||
void update(Order resources);
|
||||
|
||||
/**
|
||||
* 多选删除
|
||||
* @param ids /
|
||||
*/
|
||||
void deleteAll(Integer[] ids);
|
||||
|
||||
/**
|
||||
* 导出数据
|
||||
* @param all 待导出的数据
|
||||
* @param response /
|
||||
* @throws IOException /
|
||||
*/
|
||||
void download(List<OrderDto> all, HttpServletResponse response) throws IOException;
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,12 @@
|
|||
package com.youchain.businessdata.service;
|
||||
|
||||
/**
|
||||
* ToKen服务接口
|
||||
*/
|
||||
public interface ToKenService {
|
||||
/**
|
||||
* 获取ToKen
|
||||
* @return
|
||||
*/
|
||||
String getToKen();
|
||||
}
|
||||
|
|
@ -0,0 +1,129 @@
|
|||
/*
|
||||
* Copyright 2019-2020 Zheng Jie
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
package com.youchain.businessdata.service.dto;
|
||||
|
||||
import com.youchain.basicdata.service.dto.ItemDto;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import javax.persistence.Column;
|
||||
import javax.persistence.GeneratedValue;
|
||||
import javax.persistence.GenerationType;
|
||||
import javax.persistence.Id;
|
||||
import java.sql.Timestamp;
|
||||
import java.io.Serializable;
|
||||
|
||||
/**
|
||||
* @website https://eladmin.vip
|
||||
* @description /
|
||||
* @author huojin
|
||||
* @date 2024-04-10
|
||||
**/
|
||||
@Data
|
||||
public class MoDto implements Serializable {
|
||||
|
||||
private Integer id;
|
||||
|
||||
/** MO票 */
|
||||
private String labelNo;
|
||||
|
||||
/** 标签类型 */
|
||||
private String labelType;
|
||||
|
||||
/** 标签状态 */
|
||||
private String labelState;
|
||||
|
||||
/** 送货单头ID;通过该字段能找到002接口送货单 */
|
||||
private Integer deliveryHeaderId;
|
||||
|
||||
/** 来源系统 */
|
||||
private String sourceSystem;
|
||||
|
||||
/** 可用数量 */
|
||||
private Double qty;
|
||||
|
||||
/** 工单Id */
|
||||
private Integer workOrderId;
|
||||
|
||||
/** 工单编号 */
|
||||
private String workOrderName;
|
||||
|
||||
/** 自制件工单id */
|
||||
private Integer selfWorkOrderId;
|
||||
|
||||
/** 自制件工单编号 */
|
||||
private String selfWorkOrderName;
|
||||
|
||||
/** 工单号 */
|
||||
private String orderNo;
|
||||
|
||||
/** 物料 */
|
||||
private ItemDto item;
|
||||
|
||||
/** 检验状态 */
|
||||
private String checkResult;
|
||||
|
||||
/** 数据有效性 */
|
||||
private Boolean deleteFlag;
|
||||
|
||||
/** 车间编号 */
|
||||
private String workshopCode;
|
||||
|
||||
/** 车间描述 */
|
||||
private String workshopName;
|
||||
|
||||
/** 产线编码 */
|
||||
private String moLineCode;
|
||||
|
||||
/** 产线描述 */
|
||||
private String moLineName;
|
||||
|
||||
/** MLS子库 */
|
||||
private String invCode;
|
||||
|
||||
/** MLS货区 */
|
||||
private String goodsAreaCode;
|
||||
|
||||
/** MLS货位 */
|
||||
private String goodsLocationCode;
|
||||
|
||||
/** MLS入库时间 */
|
||||
private Timestamp datetimeStockIn;
|
||||
|
||||
/** MLS创建时间 */
|
||||
private Timestamp mlsCreateTime;
|
||||
|
||||
/** MLS修改时间 */
|
||||
private Timestamp mlsUpdateTime;
|
||||
|
||||
/** MLS创建人 */
|
||||
private String createUserCode;
|
||||
|
||||
/** MLS修改人 */
|
||||
private String updateUserCode;
|
||||
|
||||
/** 创建人 */
|
||||
private String createBy;
|
||||
|
||||
/** 修改人 */
|
||||
private String updateBy;
|
||||
|
||||
/** 创建时间 */
|
||||
private Timestamp createTime;
|
||||
|
||||
/** 修改时间 */
|
||||
private Timestamp updateTime;
|
||||
}
|
||||
|
|
@ -0,0 +1,29 @@
|
|||
/*
|
||||
* Copyright 2019-2020 Zheng Jie
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
package com.youchain.businessdata.service.dto;
|
||||
|
||||
import lombok.Data;
|
||||
import java.util.List;
|
||||
import com.youchain.annotation.Query;
|
||||
|
||||
/**
|
||||
* @website https://eladmin.vip
|
||||
* @author huojin
|
||||
* @date 2024-04-10
|
||||
**/
|
||||
@Data
|
||||
public class MoQueryCriteria{
|
||||
}
|
||||
|
|
@ -0,0 +1,114 @@
|
|||
/*
|
||||
* Copyright 2019-2020 Zheng Jie
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
package com.youchain.businessdata.service.dto;
|
||||
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import javax.persistence.Column;
|
||||
import javax.validation.constraints.NotBlank;
|
||||
import java.io.Serializable;
|
||||
import java.sql.Timestamp;
|
||||
|
||||
/**
|
||||
* @website https://eladmin.vip
|
||||
* @description /
|
||||
* @author huojin
|
||||
* @date 2024-04-08
|
||||
**/
|
||||
@Data
|
||||
public class OrderDto implements Serializable {
|
||||
|
||||
private Integer id;
|
||||
|
||||
/** 送货单头ID和003接口关联 */
|
||||
private Integer deliveryHeaderId;
|
||||
|
||||
/** 送货单行ID */
|
||||
private Integer deliveryLineId;
|
||||
|
||||
/** 送货通知单行ID */
|
||||
private Integer deliveryNotifyLineId;
|
||||
|
||||
/** 送货单号 */
|
||||
private String deliveryNumber;
|
||||
|
||||
/** 送货单条码号 */
|
||||
private String barcodeNumber;
|
||||
|
||||
/** 送货单状态 */
|
||||
private String deliveryStatus;
|
||||
|
||||
/** mls接收子库编码 */
|
||||
private String receivedInvCode;
|
||||
|
||||
/** mls接收子库名称 */
|
||||
private String receivedInvName;
|
||||
|
||||
/** mls接收货区编码 */
|
||||
private String receivedAreaCode;
|
||||
|
||||
/** mls接收货区名称 */
|
||||
private String receivedAreaName;
|
||||
|
||||
/** mls货位编码 */
|
||||
private String receivedLocationCode;
|
||||
|
||||
/** mls货位名称 */
|
||||
private String receivedLocationName;
|
||||
|
||||
/** 物料编码 */
|
||||
private String itemCode;
|
||||
|
||||
/** 计划数量 */
|
||||
private Double deliveryQty;
|
||||
|
||||
/** 检验员 */
|
||||
private String inInspector;
|
||||
|
||||
/** 实际接收数量 */
|
||||
private Double receivedQty;
|
||||
|
||||
/** Y-已检验N-未检验 */
|
||||
private String isIqcInspected;
|
||||
|
||||
/** 检验结果(不合格:REJECT,合格:ACCEPT) */
|
||||
private String iqcResult;
|
||||
|
||||
/** 是否已生成标签 */
|
||||
private String isCreatedLabel;
|
||||
|
||||
/** 供应商编码 */
|
||||
private String supplierCode;
|
||||
|
||||
/** 供应商名称 */
|
||||
private String supplierName;
|
||||
|
||||
/** mls修改人 */
|
||||
private Timestamp mlsUpdateTime;
|
||||
|
||||
/** 创建人 */
|
||||
private String createBy;
|
||||
|
||||
/** 修改人 */
|
||||
private String updateBy;
|
||||
|
||||
/** 创建时间 */
|
||||
private Timestamp createTime;
|
||||
|
||||
/** 修改时间 */
|
||||
private Timestamp updateTime;
|
||||
}
|
||||
|
|
@ -0,0 +1,45 @@
|
|||
/*
|
||||
* Copyright 2019-2020 Zheng Jie
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
package com.youchain.businessdata.service.dto;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
import java.sql.Timestamp;
|
||||
import java.util.List;
|
||||
import com.youchain.annotation.Query;
|
||||
|
||||
/**
|
||||
* @website https://eladmin.vip
|
||||
* @author huojin
|
||||
* @date 2024-04-08
|
||||
**/
|
||||
@Data
|
||||
public class OrderQueryCriteria{
|
||||
/** 送货单条码号 */
|
||||
@Query(type = Query.Type.INNER_LIKE)
|
||||
private String barcodeNumber;
|
||||
|
||||
/** 物料编号 */
|
||||
@Query(type = Query.Type.INNER_LIKE)
|
||||
private String itemCode;
|
||||
|
||||
/** 送货单状态 */
|
||||
@Query(type = Query.Type.EQUAL)
|
||||
private String deliveryStatus;
|
||||
|
||||
@Query(type = Query.Type.BETWEEN)
|
||||
private List<Timestamp> createTime;
|
||||
}
|
||||
|
|
@ -0,0 +1,240 @@
|
|||
package com.youchain.businessdata.service.impl;
|
||||
|
||||
import cn.hutool.core.date.DateUtil;
|
||||
import com.alibaba.fastjson.JSON;
|
||||
import com.alibaba.fastjson.JSONArray;
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
import com.youchain.basicdata.domain.Item;
|
||||
import com.youchain.basicdata.service.ItemService;
|
||||
import com.youchain.businessdata.domain.Mo;
|
||||
import com.youchain.businessdata.domain.Order;
|
||||
import com.youchain.businessdata.inputJson.MoInfo;
|
||||
import com.youchain.businessdata.inputJson.OrderInfo;
|
||||
import com.youchain.businessdata.service.MlsService;
|
||||
import com.youchain.businessdata.service.MoService;
|
||||
import com.youchain.businessdata.service.OrderService;
|
||||
import com.youchain.businessdata.service.ToKenService;
|
||||
import com.youchain.modules.system.domain.Dept;
|
||||
import com.youchain.modules.system.service.DeptService;
|
||||
import com.youchain.modules.system.service.dto.DeptDto;
|
||||
import com.youchain.utils.HttpPostUtil;
|
||||
import com.youchain.utils.UrlApi;
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
|
||||
import javax.persistence.EntityManager;
|
||||
import javax.persistence.Query;
|
||||
import java.util.*;
|
||||
|
||||
@Service
|
||||
@RequiredArgsConstructor
|
||||
@Slf4j
|
||||
public class MlsServiceImpl implements MlsService {
|
||||
private final ToKenService toKenService;
|
||||
private final OrderService orderService;
|
||||
private final ItemService itemService;
|
||||
private final DeptService deptService;
|
||||
private final MoService moService;
|
||||
private final EntityManager entityMapper;
|
||||
|
||||
/**
|
||||
* 获取送货单JSON
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public String getOrderJson(OrderInfo orderInfo) {
|
||||
JSONObject jsonObject = new JSONObject(new LinkedHashMap<>());
|
||||
Map<String, Object> objMap = new LinkedHashMap<>();
|
||||
objMap.put("ifaceCode", orderInfo.getIfaceCode());//获取送货单信息
|
||||
objMap.put("sourceSystem", orderInfo.getSourceSystem());//来源系统
|
||||
objMap.put("params", orderInfo.getParams());
|
||||
jsonObject.putAll(objMap);
|
||||
String resultJson = HttpPostUtil.sendPostReq(UrlApi.publicApi, jsonObject.toString(), toKenService.getToKen());//返回ResponseJson*/
|
||||
return resultJson;
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取送货单信息
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public synchronized void getOrderInfo(String resultJson) {
|
||||
if (resultJson != null && resultJson.length() > 0) {
|
||||
JSONObject resulObject = JSON.parseObject(resultJson);
|
||||
String code = resulObject.getString("code") == null ? "" : resulObject.getString("code");
|
||||
String msg = resulObject.getString("msg") == null ? "" : resulObject.getString("msg");
|
||||
if ("0".equals(code)) {
|
||||
String data = resulObject.getString("data") == null ? "" : resulObject.getString("data");
|
||||
JSONObject dataObject = JSON.parseObject(data);
|
||||
JSONArray details = dataObject.getJSONArray("list");
|
||||
for (int i = 0; i < details.size(); i++) {
|
||||
JSONObject detail = details.getJSONObject(i);
|
||||
String barcodeNumber = detail.getString("barcodeNumber");//送货单条码号
|
||||
String isCreatedLabel = detail.getString("isCreatedLabel");//是否已生成标签N
|
||||
String itemCode = detail.getString("itemCode");//物料编码
|
||||
String iqcResult = detail.getString("iqcResult");//检验结果(不合格:REJECT,合格:ACCEPT)
|
||||
String supplierCode = detail.getString("supplierCode");//供应商编码
|
||||
//String dispatchNumber=detail.getString("dispatchNumber");//文档没有该字段
|
||||
String receivedLocationName = detail.getString("receivedLocationName");//LMES货位名称
|
||||
String receivedInvCode = detail.getString("receivedInvCode");//LMES接收子库编码
|
||||
//Integer deliveryNotifyLineId = detail.getInteger("deliveryNotifyLineId");//送货通知单行ID
|
||||
String deliveryNumber = detail.getString("deliveryNumber");//送货单号
|
||||
String receivedAreaCode = detail.getString("receivedAreaCode");//LMES接收货区编码
|
||||
String supplierName = detail.getString("supplierName");//供应商名称
|
||||
String isIqcInspected = detail.getString("isIqcInspected");//Y-已检验N-未检验
|
||||
Double deliveryQty = detail.getDouble("deliveryQty");//计划数量
|
||||
//String deliveryType=detail.getString("deliveryType");//文档没有该字段
|
||||
String receivedLocationCode = detail.getString("receivedLocationCode");//LMES货位编码
|
||||
String mlsUpdateTime = detail.getString("updateTime");//更新时间
|
||||
String receivedInvName = detail.getString("receivedInvName");//LMES接收子库名称
|
||||
Double receivedQty = detail.getDouble("receivedQty");//实际接收数量
|
||||
//Integer deliveryLineId = detail.getInteger("deliveryLineId");//送货单行ID
|
||||
String inInspector = detail.getString("inInspector");//检验员
|
||||
Integer deliveryHeaderId = detail.getInteger("deliveryHeaderId");//送货单头ID和003接口关联
|
||||
String receivedAreaName = detail.getString("receivedAreaName");//mls接收货区名称
|
||||
String deliveryStatus = detail.getString("deliveryStatus");//送货单状态
|
||||
|
||||
//直接接收已合格的送货单
|
||||
if ("Y".equals(isIqcInspected)) {
|
||||
|
||||
String order_hql = " from Order order where order.barcodeNumber= :barcodeNumber ";
|
||||
Query query = entityMapper.createQuery(order_hql);
|
||||
query.setParameter("barcodeNumber", barcodeNumber);
|
||||
List<Order> orderList = query.getResultList();
|
||||
if (orderList.size() > 0) {
|
||||
//更新
|
||||
Order order = orderList.get(0);
|
||||
order.setDeliveryStatus(deliveryStatus);
|
||||
orderService.update(order);
|
||||
} else {
|
||||
//创建
|
||||
Order newOrder = new Order(deliveryHeaderId, null, null,
|
||||
deliveryNumber, barcodeNumber, deliveryStatus, receivedInvCode, receivedInvName,
|
||||
receivedAreaCode, receivedAreaName, receivedLocationCode, receivedLocationName,
|
||||
itemCode, deliveryQty, inInspector, receivedQty, isIqcInspected, iqcResult, isCreatedLabel,
|
||||
supplierCode, supplierName,mlsUpdateTime == null ? null : DateUtil.parse(mlsUpdateTime).toTimestamp()
|
||||
);
|
||||
orderService.create(newOrder);
|
||||
}
|
||||
}
|
||||
}
|
||||
} else {
|
||||
throw new RuntimeException("MLS异常信息:" + msg);
|
||||
}
|
||||
} else {
|
||||
throw new RuntimeException("获取送货单接口失败!");
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getMoJson(MoInfo moInfo) {
|
||||
JSONObject jsonObject = new JSONObject(new LinkedHashMap<>());
|
||||
Map<String, Object> objMap = new LinkedHashMap<>();
|
||||
objMap.put("ifaceCode", moInfo.getIfaceCode());//获取送货单信息
|
||||
objMap.put("sourceSystem", moInfo.getSourceSystem());//来源系统
|
||||
objMap.put("params", moInfo.getParams());
|
||||
jsonObject.putAll(objMap);
|
||||
String resultJson = HttpPostUtil.sendPostReq(UrlApi.publicApi, jsonObject.toString(), toKenService.getToKen());//返回ResponseJson*/
|
||||
return resultJson;
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取MO票信息
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public synchronized void getMoInfo(String resultJson) {
|
||||
if (resultJson != null && resultJson.length() > 0) {
|
||||
JSONObject resulObject = JSON.parseObject(resultJson);
|
||||
String code = resulObject.getString("code") == null ? "" : resulObject.getString("code");
|
||||
String msg = resulObject.getString("msg") == null ? "" : resulObject.getString("msg");
|
||||
if ("0".equals(code)) {
|
||||
String data = resulObject.getString("data") == null ? "" : resulObject.getString("data");
|
||||
JSONObject dataObject = JSON.parseObject(data);
|
||||
JSONArray details = dataObject.getJSONArray("list");
|
||||
for (int i = 0; i < details.size(); i++) {
|
||||
JSONObject detail = details.getJSONObject(i);
|
||||
Integer selfWorkOrderId = detail.getInteger("selfWorkOrderId");//自制件工单id
|
||||
String sourceSystem = detail.getString("sourceSystem");//来源系统
|
||||
String selfWorkOrderName = detail.getString("selfWorkOrderName");//自制件工单编号
|
||||
String itemCode = detail.getString("itemCode");//物料编码
|
||||
String labelType = detail.getString("labelType");//标签类型
|
||||
String goodsAreaCode = detail.getString("goodsAreaCode");//MLS货区
|
||||
String checkResult = detail.getString("checkResult");//检验状态
|
||||
String datetimeStockIn = detail.getString("datetimeStockin");//入库时间
|
||||
String deleteFlag = detail.getString("deleteFlag");//数据有效性;有效0,无效1
|
||||
String uom = detail.getString("uom");//单位
|
||||
String createUserCode = detail.getString("createUserCode");//创建人
|
||||
String mlsUpdateTime = detail.getString("updateTime");//修改时间
|
||||
String itemDesc = detail.getString("itemDesc");//物料描述
|
||||
String labelNo = detail.getString("labelNo");//MO票
|
||||
Long itemId = detail.getLong("itemId");//物料id
|
||||
String updateUserCode = detail.getString("updateUserCode");//修改人
|
||||
String mlsCreateTime = detail.getString("createTime");//创建时间
|
||||
Double qty = detail.getDouble("qty");//可用数量
|
||||
String labelState = detail.getString("labelState");//标签状态
|
||||
Integer deliveryHeaderId = detail.getInteger("deliveryHeaderId");//送货单头ID;通过该字段能找到002接口送货单
|
||||
String workOrderName = detail.getString("workOrderName");//工单编号
|
||||
Integer workOrderId = detail.getInteger("workOrderId");//工单Id
|
||||
String goodsLocationCode = detail.getString("goodsLocationCode");//MLS货位
|
||||
String invCode = detail.getString("invCode");//MLS子库
|
||||
|
||||
//接收有效的MO票
|
||||
if ("0".equals(deleteFlag)) {
|
||||
//判断物料是否存在;不存在新增;
|
||||
Item item = null;
|
||||
String item_hql = " from Item item where item.code='" + itemCode + "' ";
|
||||
Query item_query = entityMapper.createQuery(item_hql);
|
||||
List<Item> itemList = item_query.getResultList();
|
||||
if (itemList.size() > 0) {
|
||||
item = itemList.get(0);
|
||||
} else {
|
||||
item = new Item();
|
||||
item.setCode(itemCode);
|
||||
item.setName(itemDesc);
|
||||
item.setUnit(uom);
|
||||
DeptDto deptDto= deptService.findById(7L);
|
||||
Dept dept= deptService.toEntity(deptDto);
|
||||
item.setDept(dept);
|
||||
item.setSourceName(sourceSystem);
|
||||
item.setSourceId(itemId);
|
||||
itemService.create(item);
|
||||
}
|
||||
|
||||
//判断MO票是否存在;不存在新增;存在更新
|
||||
String mo_hql = " from Mo mo where mo.labelNo='" + labelNo + "' ";
|
||||
Query mo_query = entityMapper.createQuery(mo_hql);
|
||||
List<Mo> moList = mo_query.getResultList();
|
||||
if (moList.size() > 0) {
|
||||
Mo mo = moList.get(0);
|
||||
} else {
|
||||
Mo mo = new Mo(labelNo, labelType, labelState, deliveryHeaderId, sourceSystem, qty,
|
||||
workOrderId, workOrderName, selfWorkOrderId, selfWorkOrderName, null, item,
|
||||
checkResult, Boolean.parseBoolean(deleteFlag), null, null, null, null, invCode, goodsAreaCode, goodsLocationCode,
|
||||
datetimeStockIn == null ? null : DateUtil.parse(datetimeStockIn).toTimestamp(),
|
||||
mlsCreateTime == null ? null : DateUtil.parse(mlsCreateTime).toTimestamp(),
|
||||
mlsUpdateTime == null ? null : DateUtil.parse(mlsUpdateTime).toTimestamp(),
|
||||
createUserCode, updateUserCode
|
||||
);
|
||||
moService.create(mo);
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
} else {
|
||||
throw new RuntimeException("MLS异常信息:" + msg);
|
||||
}
|
||||
} else {
|
||||
throw new RuntimeException("获取MO票接口失败!");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,106 @@
|
|||
/*
|
||||
* Copyright 2019-2020 Zheng Jie
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
package com.youchain.businessdata.service.impl;
|
||||
|
||||
import com.youchain.businessdata.domain.Mo;
|
||||
import com.youchain.exception.EntityExistException;
|
||||
import com.youchain.utils.FileUtil;
|
||||
import com.youchain.utils.PageUtil;
|
||||
import com.youchain.utils.QueryHelp;
|
||||
import com.youchain.utils.ValidationUtil;
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import com.youchain.businessdata.repository.MoRepository;
|
||||
import com.youchain.businessdata.service.MoService;
|
||||
import com.youchain.businessdata.service.dto.MoDto;
|
||||
import com.youchain.businessdata.service.dto.MoQueryCriteria;
|
||||
import com.youchain.businessdata.service.mapstruct.MoMapper;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
import org.springframework.data.domain.Page;
|
||||
import org.springframework.data.domain.Pageable;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.io.IOException;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import java.util.ArrayList;
|
||||
import java.util.LinkedHashMap;
|
||||
|
||||
/**
|
||||
* @website https://eladmin.vip
|
||||
* @description 服务实现
|
||||
* @author huojin
|
||||
* @date 2024-04-10
|
||||
**/
|
||||
@Service
|
||||
@RequiredArgsConstructor
|
||||
public class MoServiceImpl implements MoService {
|
||||
|
||||
private final MoRepository moRepository;
|
||||
private final MoMapper moMapper;
|
||||
|
||||
@Override
|
||||
public Map<String,Object> queryAll(MoQueryCriteria criteria, Pageable pageable){
|
||||
Page<Mo> page = moRepository.findAll((root, criteriaQuery, criteriaBuilder) -> QueryHelp.getPredicate(root,criteria,criteriaBuilder),pageable);
|
||||
return PageUtil.toPage(page.map(moMapper::toDto));
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<MoDto> queryAll(MoQueryCriteria criteria){
|
||||
return moMapper.toDto(moRepository.findAll((root, criteriaQuery, criteriaBuilder) -> QueryHelp.getPredicate(root,criteria,criteriaBuilder)));
|
||||
}
|
||||
|
||||
@Override
|
||||
@Transactional
|
||||
public MoDto findById(Integer id) {
|
||||
Mo mo = moRepository.findById(id).orElseGet(Mo::new);
|
||||
ValidationUtil.isNull(mo.getId(),"Mo","id",id);
|
||||
return moMapper.toDto(mo);
|
||||
}
|
||||
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public MoDto create(Mo resources) {
|
||||
return moMapper.toDto(moRepository.save(resources));
|
||||
}
|
||||
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public void update(Mo resources) {
|
||||
Mo mo = moRepository.findById(resources.getId()).orElseGet(Mo::new);
|
||||
ValidationUtil.isNull( mo.getId(),"Mo","id",resources.getId());
|
||||
mo.copy(resources);
|
||||
moRepository.save(mo);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void deleteAll(Integer[] ids) {
|
||||
for (Integer id : ids) {
|
||||
moRepository.deleteById(id);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void download(List<MoDto> all, HttpServletResponse response) throws IOException {
|
||||
List<Map<String, Object>> list = new ArrayList<>();
|
||||
for (MoDto mo : all) {
|
||||
Map<String,Object> map = new LinkedHashMap<>();
|
||||
map.put("自制件工单id", mo.getSelfWorkOrderId());
|
||||
|
||||
list.add(map);
|
||||
}
|
||||
FileUtil.downloadExcel(list, response);
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,112 @@
|
|||
/*
|
||||
* Copyright 2019-2020 Zheng Jie
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
package com.youchain.businessdata.service.impl;
|
||||
|
||||
import com.youchain.businessdata.domain.AsnDetail;
|
||||
import com.youchain.businessdata.domain.Order;
|
||||
import com.youchain.utils.FileUtil;
|
||||
import com.youchain.utils.PageUtil;
|
||||
import com.youchain.utils.QueryHelp;
|
||||
import com.youchain.utils.ValidationUtil;
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import com.youchain.businessdata.repository.OrderRepository;
|
||||
import com.youchain.businessdata.service.OrderService;
|
||||
import com.youchain.businessdata.service.dto.OrderDto;
|
||||
import com.youchain.businessdata.service.dto.OrderQueryCriteria;
|
||||
import com.youchain.businessdata.service.mapstruct.OrderMapper;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
import org.springframework.data.domain.Page;
|
||||
import org.springframework.data.domain.Pageable;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.io.IOException;
|
||||
import javax.persistence.EntityManager;
|
||||
import javax.persistence.Query;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import java.util.ArrayList;
|
||||
import java.util.LinkedHashMap;
|
||||
|
||||
/**
|
||||
* @author huojin
|
||||
* @website https://eladmin.vip
|
||||
* @description 服务实现
|
||||
* @date 2024-04-08
|
||||
**/
|
||||
@Service
|
||||
@RequiredArgsConstructor
|
||||
public class OrderServiceImpl implements OrderService {
|
||||
|
||||
private final OrderRepository orderRepository;
|
||||
private final OrderMapper orderMapper;
|
||||
|
||||
|
||||
@Override
|
||||
public Map<String, Object> queryAll(OrderQueryCriteria criteria, Pageable pageable) {
|
||||
Page<Order> page = orderRepository.findAll((root, criteriaQuery, criteriaBuilder) -> QueryHelp.getPredicate(root, criteria, criteriaBuilder), pageable);
|
||||
return PageUtil.toPage(page.map(orderMapper::toDto));
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<OrderDto> queryAll(OrderQueryCriteria criteria) {
|
||||
return orderMapper.toDto(orderRepository.findAll((root, criteriaQuery, criteriaBuilder) -> QueryHelp.getPredicate(root, criteria, criteriaBuilder)));
|
||||
}
|
||||
|
||||
@Override
|
||||
@Transactional
|
||||
public OrderDto findById(Integer id) {
|
||||
Order order = orderRepository.findById(id).orElseGet(Order::new);
|
||||
ValidationUtil.isNull(order.getId(), "Order", "id", id);
|
||||
return orderMapper.toDto(order);
|
||||
}
|
||||
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public OrderDto create(Order resources) {
|
||||
return orderMapper.toDto(orderRepository.save(resources));
|
||||
}
|
||||
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public void update(Order resources) {
|
||||
Order order = orderRepository.findById(resources.getId()).orElseGet(Order::new);
|
||||
ValidationUtil.isNull(order.getId(), "Order", "id", resources.getId());
|
||||
order.copy(resources);
|
||||
orderRepository.save(order);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void deleteAll(Integer[] ids) {
|
||||
for (Integer id : ids) {
|
||||
orderRepository.deleteById(id);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void download(List<OrderDto> all, HttpServletResponse response) throws IOException {
|
||||
List<Map<String, Object>> list = new ArrayList<>();
|
||||
for (OrderDto order : all) {
|
||||
Map<String, Object> map = new LinkedHashMap<>();
|
||||
map.put("送货单条码号", order.getBarcodeNumber());
|
||||
|
||||
list.add(map);
|
||||
}
|
||||
FileUtil.downloadExcel(list, response);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,42 @@
|
|||
package com.youchain.businessdata.service.impl;
|
||||
|
||||
import com.alibaba.fastjson.JSON;
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
import com.youchain.businessdata.service.ToKenService;
|
||||
import com.youchain.utils.HttpPostUtil;
|
||||
import com.youchain.utils.UrlApi;
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.util.LinkedHashMap;
|
||||
import java.util.Map;
|
||||
|
||||
@Service
|
||||
@RequiredArgsConstructor
|
||||
@Slf4j
|
||||
public class ToKenServiceImpl implements ToKenService {
|
||||
|
||||
@Override
|
||||
public String getToKen() {
|
||||
String toKen="";
|
||||
String mlsUser="WMS";
|
||||
String mlsPwd="EDlsFOvn3xaJm*EH";
|
||||
JSONObject jsonObject = new JSONObject(new LinkedHashMap<>());
|
||||
Map<String, Object> objMap = new LinkedHashMap<>();
|
||||
objMap.put("mlsUser", mlsUser);//快码代码
|
||||
objMap.put("mlsPwd", mlsPwd);//快码值
|
||||
jsonObject.putAll(objMap);
|
||||
String resultJson = HttpPostUtil.sendPostReq(UrlApi.extSignIn, jsonObject.toString());//返回ResponseJson*/
|
||||
JSONObject resulObject = JSON.parseObject(resultJson);
|
||||
String code = resulObject.getString("code") == null ? "" : resulObject.getString("code");
|
||||
String msg = resulObject.getString("msg") == null ? "" : resulObject.getString("msg");
|
||||
|
||||
if("0".equals(code)){
|
||||
toKen = resulObject.getString("data") == null ? "" : resulObject.getString("data");
|
||||
return toKen;
|
||||
}else{
|
||||
throw new RuntimeException("MLS异常信息:"+msg);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -13,20 +13,20 @@
|
|||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
package ${package}.service.mapstruct;
|
||||
package com.youchain.businessdata.service.mapstruct;
|
||||
|
||||
import com.youchain.base.BaseMapper;
|
||||
import ${package}.domain.${className};
|
||||
import ${package}.service.dto.${className}Dto;
|
||||
import com.youchain.businessdata.domain.Mo;
|
||||
import com.youchain.businessdata.service.dto.MoDto;
|
||||
import org.mapstruct.Mapper;
|
||||
import org.mapstruct.ReportingPolicy;
|
||||
|
||||
/**
|
||||
* @website https://eladmin.vip
|
||||
* @author ${author}
|
||||
* @date ${date}
|
||||
* @author huojin
|
||||
* @date 2024-04-10
|
||||
**/
|
||||
@Mapper(componentModel = "spring", unmappedTargetPolicy = ReportingPolicy.IGNORE)
|
||||
public interface ${className}Mapper extends BaseMapper<${className}Dto, ${className}> {
|
||||
public interface MoMapper extends BaseMapper<MoDto, Mo> {
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,32 @@
|
|||
/*
|
||||
* Copyright 2019-2020 Zheng Jie
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
package com.youchain.businessdata.service.mapstruct;
|
||||
|
||||
import com.youchain.base.BaseMapper;
|
||||
import com.youchain.businessdata.domain.Order;
|
||||
import com.youchain.businessdata.service.dto.OrderDto;
|
||||
import org.mapstruct.Mapper;
|
||||
import org.mapstruct.ReportingPolicy;
|
||||
|
||||
/**
|
||||
* @website https://eladmin.vip
|
||||
* @author huojin
|
||||
* @date 2024-04-08
|
||||
**/
|
||||
@Mapper(componentModel = "spring", unmappedTargetPolicy = ReportingPolicy.IGNORE)
|
||||
public interface OrderMapper extends BaseMapper<OrderDto, Order> {
|
||||
|
||||
}
|
||||
|
|
@ -1,67 +0,0 @@
|
|||
package com.youchain.modules.quartz.task;
|
||||
|
||||
import com.alibaba.fastjson.JSON;
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
import com.youchain.businessdata.domain.AgvTask;
|
||||
import com.youchain.businessdata.repository.AgvTaskRepository;
|
||||
import com.youchain.businessdata.service.AgvTaskService;
|
||||
import com.youchain.utils.BizStatus;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.HashSet;
|
||||
import java.util.List;
|
||||
import java.util.Set;
|
||||
|
||||
/**
|
||||
* 入库料箱任务
|
||||
*/
|
||||
@Slf4j
|
||||
@Service
|
||||
public class asnTask {
|
||||
@Autowired
|
||||
public AgvTaskRepository agvTaskRepository;
|
||||
|
||||
@Autowired
|
||||
public AgvTaskService agvTaskService;
|
||||
|
||||
private static final int MAX_TASK_COUNT = 4;
|
||||
private static final long TIMEOUT_MS = 2*60*1000; // 2分钟,以毫秒为单位
|
||||
private long lastTaskTime = System.currentTimeMillis();
|
||||
|
||||
public void asnTask() {
|
||||
|
||||
//查询待执行已扫描的入库AGV任务
|
||||
List<AgvTask> agvTasks = agvTaskRepository.queryByAgvTask(null, BizStatus.OPEN,BizStatus.ASN,1,"PICKER_MOVE");
|
||||
if(agvTasks.size()>0){
|
||||
if (agvTasks.size() == MAX_TASK_COUNT) {
|
||||
log.info("小件入库料箱任务已满足,当前任务数:" + agvTasks.size());
|
||||
String resultJson=agvTaskService.sendAgvTaskLXImpl(agvTasks);
|
||||
log.info(resultJson);
|
||||
lastTaskTime = System.currentTimeMillis();
|
||||
} else if (System.currentTimeMillis() - lastTaskTime >=TIMEOUT_MS) {
|
||||
if(agvTasks.size()>4){
|
||||
List<AgvTask> newAgvTask = agvTasks.subList(0,4);
|
||||
log.info("2分钟未满足4个小件入库料箱任务,当前任务数:" + newAgvTask.size());
|
||||
String resultJson=agvTaskService.sendAgvTaskLXImpl(newAgvTask);
|
||||
log.info(resultJson);
|
||||
}else{
|
||||
log.info("2分钟未满足4个小件入库料箱任务,当前任务数:" + agvTasks.size());
|
||||
String resultJson=agvTaskService.sendAgvTaskLXImpl(agvTasks);
|
||||
log.info(resultJson);
|
||||
lastTaskTime = System.currentTimeMillis();
|
||||
}
|
||||
}else{
|
||||
log.info("小件入库料箱任务未满足条件!");
|
||||
}
|
||||
}else{
|
||||
log.info("无小件入库料箱任务!");
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
|
|
@ -1,93 +0,0 @@
|
|||
package com.youchain.modules.quartz.task;
|
||||
|
||||
import com.youchain.basicdata.domain.Point;
|
||||
import com.youchain.basicdata.service.PointService;
|
||||
import com.youchain.businessdata.domain.AgvTask;
|
||||
import com.youchain.businessdata.repository.AgvTaskRepository;
|
||||
import com.youchain.businessdata.service.AgvTaskService;
|
||||
import com.youchain.modules.quartz.utils.TimeNumberUtils;
|
||||
import com.youchain.utils.BaseStatus;
|
||||
import com.youchain.utils.BizStatus;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 滚筒任务
|
||||
*/
|
||||
@Slf4j
|
||||
@Service
|
||||
public class gtcTask {
|
||||
|
||||
@Autowired
|
||||
public AgvTaskRepository agvTaskRepository;
|
||||
|
||||
@Autowired
|
||||
public AgvTaskService agvTaskService;
|
||||
|
||||
@Autowired
|
||||
public PointService pointService;
|
||||
|
||||
|
||||
public void gtcTask() {
|
||||
//查询缓存输送线上的已扫描成功的满箱任务!
|
||||
List<AgvTask> agvTaskList1 = agvTaskRepository.queryByAgvTask(null, BizStatus.OPEN, BizStatus.PICK, 1, "ROLLER_MOVE");
|
||||
if (agvTaskList1.size() > 0) {
|
||||
if (agvTaskList1.size() > 2) {
|
||||
List<AgvTask> newAgvTask = agvTaskList1.subList(0, 2);
|
||||
this.isussTask(newAgvTask);
|
||||
} else {
|
||||
this.isussTask(agvTaskList1);
|
||||
}
|
||||
|
||||
} else {
|
||||
log.info("无出库滚筒输送线任务!");
|
||||
}
|
||||
}
|
||||
|
||||
public void isussTask(List<AgvTask> agvTaskList1) {
|
||||
List<AgvTask> agvTaskList2 = new ArrayList<>();//空箱任务
|
||||
for (AgvTask agvTask : agvTaskList1) {
|
||||
try {
|
||||
//满箱任务的终点是线边空箱的起点;获取线边点位
|
||||
Point startPoint = pointService.findByCode(agvTask.getEndSlotCode(), null, null, null, null);
|
||||
String taskCode = startPoint.getName() + "2";//线边名称;2代表空箱输送线;
|
||||
|
||||
//出库缓存出库缓存滚筒输送线满箱接驳口为终点
|
||||
Point endPoint = pointService.getPoint("", BaseStatus.FREE, BaseStatus.BOX, "出库缓存滚筒输送线满箱接驳口");
|
||||
if (endPoint == null) {
|
||||
log.info("出库缓存滚筒输送线满箱接驳口点位没有维护!");
|
||||
return;
|
||||
}
|
||||
|
||||
//线边任务执行中,不追加空箱任务
|
||||
if (agvTaskService.findByendSlotCode(agvTask.getEndSlotCode(), BizStatus.EMPTY_OUT, "ROLLER_MOVE")) {
|
||||
int count = agvTaskService.QueryCount(taskCode);//查询线边空箱的数量
|
||||
if (count > 2) {
|
||||
count = 2;
|
||||
}
|
||||
if (count > 0) {
|
||||
//生成反空箱滚筒任务任务
|
||||
for (int i = 0; i < count; i++) {
|
||||
if (agvTaskList2.size() < 2) {
|
||||
AgvTask newAgvTask = new AgvTask(BizStatus.EMPTY_OUT, TimeNumberUtils.getKLXTaskCode(), startPoint.getCode(), endPoint.getCode(), BizStatus.OPEN, "ROLLER_MOVE");
|
||||
agvTaskService.create(newAgvTask);
|
||||
agvTaskList2.add(newAgvTask);
|
||||
}
|
||||
}
|
||||
}
|
||||
} else {
|
||||
log.info("线边任务执行中,不追加空箱任务!");
|
||||
}
|
||||
|
||||
} catch (Exception e) {
|
||||
log.info(e.getMessage());
|
||||
}
|
||||
}
|
||||
String resultJson = agvTaskService.sendAgvTaskGTImpl(agvTaskList1, agvTaskList2);
|
||||
log.info(resultJson);
|
||||
}
|
||||
}
|
||||
|
|
@ -1,62 +0,0 @@
|
|||
package com.youchain.modules.quartz.task;
|
||||
|
||||
import com.youchain.basicdata.domain.Point;
|
||||
import com.youchain.basicdata.service.PointService;
|
||||
import com.youchain.businessdata.domain.AgvTask;
|
||||
import com.youchain.businessdata.service.AgvTaskService;
|
||||
import com.youchain.modules.quartz.utils.TimeNumberUtils;
|
||||
import com.youchain.utils.BaseStatus;
|
||||
import com.youchain.utils.BizStatus;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 料箱回空箱
|
||||
*/
|
||||
@Slf4j
|
||||
@Service
|
||||
public class hkxTask {
|
||||
@Autowired
|
||||
public AgvTaskService agvTaskService;
|
||||
|
||||
@Autowired
|
||||
public PointService pointService;
|
||||
|
||||
|
||||
public void hkxTask() {
|
||||
|
||||
//有没有回入库空箱的任务
|
||||
if (agvTaskService.findByendSlotCode("S-001-002-001-001",BizStatus.EMPTY_IN,"PICKER_MOVE")) {
|
||||
int queryCount = agvTaskService.QueryCount("6x2");
|
||||
if (queryCount >= 4 && queryCount <=6){
|
||||
//起点
|
||||
Point startPoint = pointService.getPoint("", BaseStatus.FREE, BaseStatus.BOX, "出库缓存输送线空箱接驳口");
|
||||
|
||||
//终点
|
||||
Point endPoint = pointService.getPoint("", BaseStatus.FREE, BaseStatus.BOX, "入库输送线空箱接驳口");
|
||||
|
||||
//生成反空箱料箱任务任务
|
||||
List<AgvTask> agvTaskList = new ArrayList<>();
|
||||
for (int i = 0; i < queryCount; i++) {
|
||||
AgvTask newAgvTask = new AgvTask(BizStatus.EMPTY_IN, TimeNumberUtils.getKLXTaskCode(), startPoint.getCode(), endPoint.getCode(), BizStatus.OPEN, "PICKER_MOVE");
|
||||
agvTaskService.create(newAgvTask);
|
||||
agvTaskList.add(newAgvTask);
|
||||
}
|
||||
String rul=agvTaskService.sendAgvTaskLXImpl(agvTaskList);
|
||||
log.info(rul);
|
||||
}else{
|
||||
log.info("出库缓存输送线下层空箱不满足条件,不下发任务!");
|
||||
}
|
||||
|
||||
|
||||
}else{
|
||||
log.info("有执行中回空箱的料箱入库任务!");
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,57 @@
|
|||
package com.youchain.modules.quartz.task;
|
||||
|
||||
import cn.hutool.core.date.DateUtil;
|
||||
import com.youchain.businessdata.inputJson.OrderInfo;
|
||||
import com.youchain.businessdata.inputJson.Params;
|
||||
import com.youchain.businessdata.rest.MlsController;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
|
||||
import java.util.Date;
|
||||
import java.util.HashSet;
|
||||
import java.util.Set;
|
||||
|
||||
/**
|
||||
* 获取送货单定时任务
|
||||
*/
|
||||
|
||||
@Slf4j
|
||||
@Service
|
||||
public class orderTask {
|
||||
|
||||
private final MlsController mlsController;
|
||||
|
||||
@Autowired
|
||||
public orderTask(MlsController mlsController) {
|
||||
this.mlsController = mlsController;
|
||||
}
|
||||
|
||||
public void orderTask(){
|
||||
Date date=new Date();
|
||||
OrderInfo orderInfo=new OrderInfo();
|
||||
orderInfo.setIfaceCode("MLS-WQ-002");
|
||||
orderInfo.setSourceSystem("WQ");
|
||||
|
||||
Set invCodes=new HashSet<>();
|
||||
invCodes.add("MA1181");
|
||||
invCodes.add("MD2211");
|
||||
|
||||
String startTime=DateUtil.format(DateUtil.beginOfDay(date), "yyyy-MM-dd HH:mm:ss");
|
||||
String endTime=DateUtil.format(DateUtil.endOfDay(date), "yyyy-MM-dd HH:mm:ss");
|
||||
Params params=new Params(100059,invCodes,"",startTime,endTime,1,100);
|
||||
|
||||
orderInfo.setParams(params);
|
||||
|
||||
try{
|
||||
log.info("获取送货单信息");
|
||||
mlsController.getOrderInfo(orderInfo);
|
||||
}catch (Exception e){
|
||||
throw new RuntimeException("MLS异常信息:" + e);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
|
@ -15,6 +15,8 @@
|
|||
*/
|
||||
package com.youchain.modules.system.service;
|
||||
|
||||
import com.youchain.basicdata.domain.Item;
|
||||
import com.youchain.basicdata.service.dto.ItemDto;
|
||||
import com.youchain.modules.system.domain.Dept;
|
||||
import com.youchain.modules.system.service.dto.DeptDto;
|
||||
import com.youchain.modules.system.service.dto.DeptQueryCriteria;
|
||||
|
|
@ -86,6 +88,13 @@ public interface DeptService {
|
|||
*/
|
||||
void download(List<DeptDto> queryAll, HttpServletResponse response) throws IOException;
|
||||
|
||||
/**
|
||||
*dto转实体
|
||||
* @param deptDto
|
||||
* @return
|
||||
*/
|
||||
Dept toEntity(DeptDto deptDto);
|
||||
|
||||
/**
|
||||
* 获取待删除的部门
|
||||
* @param deptList /
|
||||
|
|
@ -121,4 +130,4 @@ public interface DeptService {
|
|||
* @param deptDtos /
|
||||
*/
|
||||
void verification(Set<DeptDto> deptDtos);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -161,6 +161,11 @@ public class DeptServiceImpl implements DeptService {
|
|||
FileUtil.downloadExcel(list, response);
|
||||
}
|
||||
|
||||
@Override
|
||||
public Dept toEntity(DeptDto deptDto) {
|
||||
return deptMapper.toEntity(deptDto);
|
||||
}
|
||||
|
||||
@Override
|
||||
public Set<DeptDto> getDeleteDepts(List<Dept> menuList, Set<DeptDto> deptDtos) {
|
||||
for (Dept dept : menuList) {
|
||||
|
|
|
|||
|
|
@ -31,5 +31,14 @@ public class UrlApi {
|
|||
*/
|
||||
public static String QueryCount="http://10.177.188.11:4080/webapi/mes/QueryCount";
|
||||
|
||||
/**
|
||||
* 获取ToKen
|
||||
*/
|
||||
public static String extSignIn="https://apiuat.midea.com/mls/system/extSignIn";
|
||||
|
||||
/**
|
||||
* MLS接口
|
||||
*/
|
||||
public static String publicApi="https://apiuat.midea.com/mls/mlsapi/public/publicApi";
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,7 +1,11 @@
|
|||
package com.youchain;
|
||||
|
||||
import com.youchain.businessdata.domain.AgvTask;
|
||||
import com.youchain.businessdata.service.MlsService;
|
||||
import com.youchain.businessdata.service.ToKenService;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.junit.jupiter.api.Test;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.boot.test.context.SpringBootTest;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
|
@ -9,6 +13,7 @@ import java.util.concurrent.ArrayBlockingQueue;
|
|||
import java.util.concurrent.BlockingQueue;
|
||||
|
||||
@SpringBootTest(webEnvironment = SpringBootTest.WebEnvironment.RANDOM_PORT)
|
||||
@Slf4j
|
||||
public class EladminSystemApplicationTests {
|
||||
|
||||
@Test
|
||||
|
|
@ -23,6 +28,10 @@ public class EladminSystemApplicationTests {
|
|||
private long lastTaskTime = System.currentTimeMillis();
|
||||
private List<Integer> taskQueue = new ArrayList<>(MAX_TASK_COUNT);
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@Test
|
||||
public void test(){
|
||||
List<Integer> taskLists=new ArrayList<>();
|
||||
|
|
@ -51,5 +60,6 @@ public class EladminSystemApplicationTests {
|
|||
System.out.println(id);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -1,8 +0,0 @@
|
|||
_ _ _
|
||||
| | | | (_)
|
||||
___| |______ __ _ __| |_ __ ___ _ _ __
|
||||
/ _ | |______/ _` |/ _` | '_ ` _ \| | '_ \
|
||||
| __| | | (_| | (_| | | | | | | | | | |
|
||||
\___|_| \__,_|\__,_|_| |_| |_|_|_| |_|
|
||||
|
||||
:: Spring Boot :: (v2.6.4)
|
||||
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue