Browse Source

供应商问题处理

yzc 1 year ago
parent
commit
7d811d6cc5

+ 7 - 2
hx-supply/src/main/java/com/fjhx/supply/service/supplier/impl/SupplierInfoServiceImpl.java

@@ -131,8 +131,11 @@ public class SupplierInfoServiceImpl extends ServiceImpl<SupplierInfoMapper, Sup
         //供应商营业执照附件
         //供应商营业执照附件
         ObsFileUtil.saveFile(supplierInfoDto.getLicenseFileList(), supplierInfoDto.getId(), 10);
         ObsFileUtil.saveFile(supplierInfoDto.getLicenseFileList(), supplierInfoDto.getId(), 10);
 
 
+
         //其他联系人
         //其他联系人
-        supplierContactService.editLinked(supplierInfoDto.getContactList(), SupplierContact::getSupplierId, supplierInfoDto.getId());
+        List<SupplierContact> contactList = supplierInfoDto.getContactList();
+        contactList.forEach(item -> item.setSupplierId(supplierInfoDto.getId()));
+        supplierContactService.editLinked(contactList, SupplierContact::getSupplierId, supplierInfoDto.getId());
     }
     }
 
 
     @DSTransactional
     @DSTransactional
@@ -153,7 +156,9 @@ public class SupplierInfoServiceImpl extends ServiceImpl<SupplierInfoMapper, Sup
         ObsFileUtil.editFile(supplierInfoDto.getLicenseFileList(), supplierInfoDto.getId(), 10);
         ObsFileUtil.editFile(supplierInfoDto.getLicenseFileList(), supplierInfoDto.getId(), 10);
 
 
         //其他联系人
         //其他联系人
-        supplierContactService.editLinked(supplierInfoDto.getContactList(), SupplierContact::getSupplierId, supplierInfoDto.getId());
+        List<SupplierContact> contactList = supplierInfoDto.getContactList();
+        contactList.forEach(item -> item.setSupplierId(supplierInfoDto.getId()));
+        supplierContactService.editLinked(contactList, SupplierContact::getSupplierId, supplierInfoDto.getId());
     }
     }
 
 
     @DSTransactional
     @DSTransactional

+ 1 - 1
hx-supply/src/main/java/com/fjhx/supply/service/supplier/impl/SupplierPriceServiceImpl.java

@@ -86,7 +86,7 @@ public class SupplierPriceServiceImpl extends ServiceImpl<SupplierPriceMapper, S
             item.setDefinition(product.getDefinition());
             item.setDefinition(product.getDefinition());
             item.setProductClassifyId(product.getProductClassifyId());
             item.setProductClassifyId(product.getProductClassifyId());
             item.setProductType(product.getType());
             item.setProductType(product.getType());
-            item.setProductCode(product.getCode());
+            item.setProductCode(product.getCustomCode());
             item.setProductName(product.getName());
             item.setProductName(product.getName());
             item.setProductSpec(product.getSpec());
             item.setProductSpec(product.getSpec());
             item.setProductUnit(product.getUnit());
             item.setProductUnit(product.getUnit());

+ 2 - 1
hx-supply/src/main/resources/mapper/supplier/SupplierPriceMapper.xml

@@ -8,7 +8,8 @@
                sp.price,
                sp.price,
                si.name supplierName,
                si.name supplierName,
                si.type supplierType,
                si.type supplierType,
-               sp.company_id
+               sp.company_id,
+               sp.including_tax_price
         from supplier_price sp
         from supplier_price sp
                  inner join supplier_info si on sp.supplier_info_id = si.id
                  inner join supplier_info si on sp.supplier_info_id = si.id
             ${ew.customSqlSegment}
             ${ew.customSqlSegment}