package com.xunhong.erp.turbo.biz.infrastructure.convert;

import com.xunhong.erp.turbo.api.biz.dto.common.OrderVehicle;
import com.xunhong.erp.turbo.biz.infrastructure.entity.OrderVehicleDO;
import org.mapstruct.Mapper;
import org.mapstruct.Mapping;
import org.mapstruct.NullValueCheckStrategy;

/**
 * @author shenyifei
 */
@Mapper(componentModel = "spring", nullValueCheckStrategy = NullValueCheckStrategy.ALWAYS, uses = {OrderDealerConvert.class})
public interface OrderVehicleConvert {
	@Mapping(target = "vehicleId", ignore = true)
	@Mapping(target = "version", ignore = true)
	@Mapping(target = "updatedAt", ignore = true)
	@Mapping(target = "isDelete", ignore = true)
	@Mapping(target = "createdAt", ignore = true)
	OrderVehicleDO toOrderVehicleDO(OrderVehicle orderVehicle);

	OrderVehicle toOrderVehicle(OrderVehicleDO orderVehicleDO);
}
