|
|
@@ -4,10 +4,13 @@ import cn.hutool.core.date.DatePattern;
|
|
|
import cn.hutool.core.date.LocalDateTimeUtil;
|
|
|
import com.aliyun.dts.subscribe.clients.record.OperationType;
|
|
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
|
|
+import com.kxs.product.api.model.KxsBrand;
|
|
|
+import com.kxs.transfer.api.mapper.product.KxsBrandMapper;
|
|
|
import com.kxs.transfer.api.mapper.user.KxsUserProfitMapper;
|
|
|
import com.kxs.transfer.api.model.table.DMLData;
|
|
|
import com.kxs.user.api.model.KxsUserProfit;
|
|
|
import com.kxs.user.api.model.KxsUserReReal;
|
|
|
+import lombok.RequiredArgsConstructor;
|
|
|
import org.springframework.stereotype.Service;
|
|
|
|
|
|
import java.math.BigDecimal;
|
|
|
@@ -21,7 +24,9 @@ import java.util.Map;
|
|
|
* @since 2024-07-22 11:44:59
|
|
|
*/
|
|
|
@Service("kxsUserProfitService")
|
|
|
+@RequiredArgsConstructor
|
|
|
public class KxsUserProfitService extends ServiceImpl<KxsUserProfitMapper, KxsUserProfit> {
|
|
|
+ private final KxsBrandMapper kxsBrandMapper;
|
|
|
|
|
|
public void changeData(DMLData dmlData) {
|
|
|
//修改的字段值
|
|
|
@@ -62,6 +67,10 @@ public class KxsUserProfitService extends ServiceImpl<KxsUserProfitMapper, KxsUs
|
|
|
break;
|
|
|
case "BrandId":
|
|
|
userProfit.setBrandId(Integer.valueOf(validFieldDataMap.get(field).toString()));
|
|
|
+ KxsBrand brand = kxsBrandMapper.selectById(userProfit.getBrandId());
|
|
|
+ if(brand != null){
|
|
|
+ userProfit.setBrandName(brand.getName());
|
|
|
+ }
|
|
|
break;
|
|
|
case "ProfitAmount":
|
|
|
userProfit.setProfitAmt(new BigDecimal(validFieldDataMap.get(field).toString()));
|