Compare commits

..

No commits in common. "fb7870876409fdb54d35ff5002231be0259e54b6" and "589110be501834b41f1f594e09747e435dcf1810" have entirely different histories.

7 changed files with 13 additions and 125 deletions

View File

@ -336,19 +336,16 @@ BoardResponse boardResponse = null;
/* [1]. QSP API (url + fileNo) Setting */
String url = null;
if("NO".equals(zipYn)) {
url = QSP_API_URL + "/api/file/downloadFile2?encodeFileNo=" + keyNo;
url = QSP_API_URL + "/api/file/downloadFile2";
}else{
url = QSP_API_URL + "/api/file/downloadFile";
if ("Y".equals(zipYn)) {
url += "?noticeNo=" + keyNo;
} else {
url += "?fileNo=" + keyNo;
}
}
if ("Y".equals(zipYn)) {
url += "?noticeNo=" + keyNo;
} else {
url += "?fileNo=" + keyNo;
}
/* [2]. QSP API CALL -> Response */
Map<String, String> result = new HashMap<String, String>();

View File

@ -103,11 +103,4 @@ public class EstimateController {
public EstimateApiResponse selectAgencyCustList(PriceRequest priceRequest) throws Exception {
return estimateService.selectAgencyCustList(priceRequest);
}
@Operation(description = "견적서를 삭제한다.")
@PostMapping("/delete-estimate")
@ResponseStatus(HttpStatus.CREATED)
public void deleteEstimate(@RequestBody EstimateRequest estimateRequest) throws Exception {
estimateService.deleteEstimate(estimateRequest);
}
}

View File

@ -146,8 +146,4 @@ public interface EstimateMapper {
// 견적서 수정일 변경
public int updateEstimateLastEditDate(EstimateRequest estimateRequest);
public int updateEstimateInit(EstimateRequest estimateRequest);
public int updateEstimateInfoInit(EstimateRequest estimateRequest);
}

View File

@ -1490,7 +1490,6 @@ public class EstimateService {
pwrGnrSimResponse.setGuideInfo(pwrGnrSimGuideInfo.getData());
}
} catch (Exception e) {
log.error(e.toString());
}
}
@ -1508,7 +1507,6 @@ public class EstimateService {
byte[] drawingImg1 = Util.toByteArray(imageInputStream);
estimateResponse.setDrawingImg1(drawingImg1);
}
log.debug("url1 ::: {}", url);
// File file = new File(drawingDirPath + File.separator + baseDrawingImgName + "_1.png");
// if (file.exists()) {
// InputStream imageInputStream =
@ -1526,7 +1524,6 @@ public class EstimateService {
byte[] drawingImg2 = Util.toByteArray(imageInputStream2);
estimateResponse.setDrawingImg2(drawingImg2);
}
log.debug("url2 ::: {}", url2);
// file = new File(drawingDirPath + File.separator + baseDrawingImgName + "_2.png");
// if (file.exists()) {
// InputStream imageInputStream2 =
@ -1628,7 +1625,7 @@ public class EstimateService {
}
} catch (Exception e) {
log.error("Failed to excelDownload estimate. Request: {}", request, e);
e.printStackTrace();
throw new QcastException(ErrorCode.INTERNAL_SERVER_ERROR);
}
}
@ -2327,47 +2324,4 @@ public class EstimateService {
return response;
}
/**
* 견적서 삭제 (복사이후 배치면 저장)
* @param estimateRequest
* @throws Exception
*/
public void deleteEstimate(EstimateRequest estimateRequest) throws Exception{
if (StringUtils.isEmpty(estimateRequest.getObjectNo())) {
throw new QcastException(ErrorCode.INVALID_INPUT_VALUE,
message.getMessage("common.message.required.data", "Object No"));
}
if (StringUtils.isEmpty(estimateRequest.getPlanNo())) {
throw new QcastException(ErrorCode.INVALID_INPUT_VALUE,
message.getMessage("common.message.required.data", "Plan No"));
}
if (StringUtils.isEmpty(estimateRequest.getSaleStoreId())) {
throw new QcastException(ErrorCode.INVALID_INPUT_VALUE,
message.getMessage("common.message.required.data", "Sale Store ID"));
}
if (StringUtils.isEmpty(estimateRequest.getUserId())) {
throw new QcastException(ErrorCode.INVALID_INPUT_VALUE,
message.getMessage("common.message.required.data", "User ID"));
}
try {
// T_PLAN
int cnt = estimateMapper.updateEstimateInit(estimateRequest);
// T_PLAN_INFO
int cnt2 = estimateMapper.updateEstimateInfoInit(estimateRequest);
// 견적서 모든 아이템 제거
int cnt3 = estimateMapper.deleteEstimateItemList(estimateRequest);
int cnt4 = estimateMapper.deleteEstimateInfoItemList(estimateRequest);
} catch (Exception e) {
log.error("Failed to delete estimate. Request: {}", estimateRequest, e);
throw e; // 예외를 재던지기하여 상위 계층에서도 예외를 처리할 있도록
}
}
}

View File

@ -280,8 +280,7 @@ public class PwrGnrSimService {
try {
pwrGnrSimRes = this.calcResults(pwrGnrSimReq, roofLength);
} catch (Exception e) {
log.error(e.toString());
//e.printStackTrace();
e.printStackTrace();
}
// DecimalFormat 객체 생성
@ -498,9 +497,7 @@ public class PwrGnrSimService {
}
// 결과 확인용
//System.err.println("hatsudenryou_all 결과 ::: " + Arrays.toString(hatsudenryou_all));
log.debug("hatsudenryou_all ::: " + Arrays.toString(hatsudenryou_all));
System.err.println("hatsudenryou_all 결과 ::: " + Arrays.toString(hatsudenryou_all));
// System.err.println("hatsudenryou_all_snow 결과 ::: " +
// Arrays.toString(hatsudenryou_all_snow));
// System.err.println(
@ -618,7 +615,7 @@ public class PwrGnrSimService {
double[] peakcutResult = new double[2];
peakcutResult[0] = amp_peakcut_result;
peakcutResult[1] = Math.min(watt_peakcut_result, amp_peakcut_result);
log.debug("peakcutResult ::: {}", peakcutResult);
return peakcutResult;
}
@ -1186,13 +1183,13 @@ public class PwrGnrSimService {
i++;
}
log.debug(Arrays.toString(IsbyTotal));
log.error(Arrays.toString(IsbyTotal));
// 직달, 산란, 지면 반사를 매월 합계
for (int m = 0; m < 12; m++) {
shamenNissha[m] = IsbyTotal[m] + IbbyTotal[m] + IrbyTotal[m];
}
}
log.debug("shamenNissha ::: {}", shamenNissha);
return shamenNissha;
}

View File

@ -64,7 +64,7 @@ file:
root.path: /home/development/public/files
ini.root.path: /home/development/public/files/NewEstimate
ini.base.filename: 料金シミュレーション.ini
ini.drawing.img.path: https://files.hanasys.jp/Drawing
ini.drawing.img.path: /home/development/public/files/NewEstimate/Drawing
front:
url: http://1.248.227.176:3000

View File

@ -729,32 +729,6 @@
AND PLAN_NO = #{planNo}
</update>
<update id="updateEstimateInit" parameterType="com.interplug.qcast.biz.estimate.dto.EstimateRequest">
/* sqlid : com.interplug.qcast.biz.estimate.updateEstimate */
UPDATE T_PLAN
SET
CONSTRUCT_SPECIFICATION = NULL
,SETUP_HEIGHT = NULL
,WEATHER_POINT = NULL
,SLOPE = NULL
,ROOF_MATERIAL_ID = NULL
,SUPPORT_METHOD_ID = NULL
,MODULE_MODEL = NULL
,DRAWING_ESTIMATE_CREATE_DATE = NULL
,ESTIMATE_VALIDITY_TERM = NULL
,CAPACITY = NULL
,SNOWFALL = NULL
,STANDARD_WIND_SPEED_ID = NULL
,PC_TYPE_NO = NULL
,ROOF_MATERIAL_ID_MULTI = NULL
,SUPPORT_MEAKER_MULTI = NULL
,SUPPORT_METHOD_ID_MULTI = NULL
,LAST_EDIT_DATETIME = GETDATE()
,LAST_EDIT_USER = #{userId}
WHERE OBJECT_NO = #{objectNo}
AND PLAN_NO = #{planNo}
</update>
<update id="updateEstimateInfoReset" parameterType="com.interplug.qcast.biz.estimate.dto.EstimateRequest">
/* sqlid : com.interplug.qcast.biz.estimate.updateEstimateInfoReset */
UPDATE T_PLAN_INFO
@ -771,29 +745,6 @@
AND PLAN_NO = #{planNo}
</update>
<update id="updateEstimateInfoInit" parameterType="com.interplug.qcast.biz.estimate.dto.EstimateRequest">
/* sqlid : com.interplug.qcast.biz.estimate.updateEstimateInfoReset */
UPDATE T_PLAN_INFO
SET
CONSTRUCT_SPECIFICATION_MULTI = NULL
, SURFACE_TYPE = NULL
, ANGLE = NULL
, ESTIMATE_DATE = NULL
, ESTIMATE_TYPE = NULL
, FILE_FLG = 0
, ESTIMATE_OPTION = NULL
, PKG_ASP = NULL
, DOC_NO = NULL
, PRICE_CD = NULL
, REMARKS = NULL
, TEMP_FLG = 1
, LOCK_FLG = 0
, SYNC_FLG = NULL
, SEC_SAP_SALES_STORE_CD = NULL
WHERE OBJECT_NO = #{objectNo}
AND PLAN_NO = #{planNo}
</update>
<update id="updateEstimateLock" parameterType="com.interplug.qcast.biz.estimate.dto.EstimateRequest">
/* sqlid : com.interplug.qcast.biz.estimate.updateEstimateLock */
UPDATE T_PLAN_INFO