Enhance price set import functionality with preview options and update handling. Added new endpoints for previewing product library pulls and Excel imports, along with support for update-only imports. Updated internationalization messages for import success and error scenarios.

This commit is contained in:
wuweihua
2026-09-30 16:15:44 +08:00
parent 90cde8da4a
commit 6e301ecee7
19 changed files with 1260 additions and 260 deletions
@@ -80,13 +80,20 @@ public class PrcPriceSetSaveAsyncRunner
/** Background import of quote Excel into package detail prices. */
@Async("threadPoolTaskExecutor")
public void runImportPrices(String taskId, Long priceSetId, Long psvId, byte[] bytes, String filename, String operName)
{
runImportPrices(taskId, priceSetId, psvId, bytes, filename, operName, false);
}
@Async("threadPoolTaskExecutor")
public void runImportPrices(String taskId, Long priceSetId, Long psvId, byte[] bytes, String filename, String operName,
boolean updateOnly)
{
try
{
put(taskId, PrcPriceSetSaveTask.STATUS_RUNNING, 10, "parsing excel", priceSetId, null);
String message = priceSetService.importDetailPrices(priceSetId, psvId, bytes, filename, operName, taskId);
String message = priceSetService.importDetailPrices(priceSetId, psvId, bytes, filename, operName, taskId, updateOnly);
put(taskId, PrcPriceSetSaveTask.STATUS_SUCCESS, 100, message, priceSetId, null);
log.info("async import prices done, taskId={}, priceSetId={}", taskId, priceSetId);
log.info("async import prices done, taskId={}, priceSetId={}, updateOnly={}", taskId, priceSetId, updateOnly);
}
catch (Exception e)
{