package com.artfess.manage.material.manager.mapper;

import com.artfess.manage.material.manager.dto.CmgtMaterialWarehouseInoutDetailDto;
import com.artfess.manage.material.model.CmgtMaterialWarehouseInoutDetail;
import java.util.ArrayList;
import java.util.List;
import javax.annotation.Generated;
import org.springframework.stereotype.Component;

@Generated(
    value = "org.mapstruct.ap.MappingProcessor",
    date = "2023-05-08T09:35:57+0800",
    comments = "version: 1.2.0.Final, compiler: javac, environment: Java 1.8.0_71 (Oracle Corporation)"
)
@Component
public class CmgtMaterialWarehouseInoutDetailDtoMapperImpl implements CmgtMaterialWarehouseInoutDetailDtoMapper {

    @Override
    public CmgtMaterialWarehouseInoutDetail toEntity(CmgtMaterialWarehouseInoutDetailDto dto) {
        if ( dto == null ) {
            return null;
        }

        CmgtMaterialWarehouseInoutDetail cmgtMaterialWarehouseInoutDetail = new CmgtMaterialWarehouseInoutDetail();

        cmgtMaterialWarehouseInoutDetail.setCreateBy( dto.getCreateBy() );
        cmgtMaterialWarehouseInoutDetail.setCreateOrgId( dto.getCreateOrgId() );
        cmgtMaterialWarehouseInoutDetail.setCreateTime( dto.getCreateTime() );
        cmgtMaterialWarehouseInoutDetail.setUpdateBy( dto.getUpdateBy() );
        cmgtMaterialWarehouseInoutDetail.setUpdateTime( dto.getUpdateTime() );
        cmgtMaterialWarehouseInoutDetail.setId( dto.getId() );
        cmgtMaterialWarehouseInoutDetail.setWarehouseInoutId( dto.getWarehouseInoutId() );
        cmgtMaterialWarehouseInoutDetail.setMaterialInfoId( dto.getMaterialInfoId() );
        cmgtMaterialWarehouseInoutDetail.setQuantityId( dto.getQuantityId() );
        cmgtMaterialWarehouseInoutDetail.setName( dto.getName() );
        cmgtMaterialWarehouseInoutDetail.setUnit( dto.getUnit() );
        cmgtMaterialWarehouseInoutDetail.setModel( dto.getModel() );
        cmgtMaterialWarehouseInoutDetail.setQuantity( dto.getQuantity() );
        cmgtMaterialWarehouseInoutDetail.setAvailableQuantity( dto.getAvailableQuantity() );
        cmgtMaterialWarehouseInoutDetail.setPrice( dto.getPrice() );
        cmgtMaterialWarehouseInoutDetail.setAmount( dto.getAmount() );
        cmgtMaterialWarehouseInoutDetail.setSupplier( dto.getSupplier() );
        cmgtMaterialWarehouseInoutDetail.setDescription( dto.getDescription() );
        cmgtMaterialWarehouseInoutDetail.setSn( dto.getSn() );
        cmgtMaterialWarehouseInoutDetail.setMemo( dto.getMemo() );
        cmgtMaterialWarehouseInoutDetail.setOrgId( dto.getOrgId() );
        cmgtMaterialWarehouseInoutDetail.setWarehouse( dto.getWarehouse() );
        cmgtMaterialWarehouseInoutDetail.setApplicant( dto.getApplicant() );
        cmgtMaterialWarehouseInoutDetail.setApplicantId( dto.getApplicantId() );
        cmgtMaterialWarehouseInoutDetail.setInoutDate( dto.getInoutDate() );
        cmgtMaterialWarehouseInoutDetail.setStatus( dto.getStatus() );
        cmgtMaterialWarehouseInoutDetail.setVersion( dto.getVersion() );
        cmgtMaterialWarehouseInoutDetail.setLastTime( dto.getLastTime() );

        return cmgtMaterialWarehouseInoutDetail;
    }

    @Override
    public CmgtMaterialWarehouseInoutDetailDto toDto(CmgtMaterialWarehouseInoutDetail entity) {
        if ( entity == null ) {
            return null;
        }

        CmgtMaterialWarehouseInoutDetailDto cmgtMaterialWarehouseInoutDetailDto = new CmgtMaterialWarehouseInoutDetailDto();

        cmgtMaterialWarehouseInoutDetailDto.setCreateBy( entity.getCreateBy() );
        cmgtMaterialWarehouseInoutDetailDto.setCreateOrgId( entity.getCreateOrgId() );
        cmgtMaterialWarehouseInoutDetailDto.setCreateTime( entity.getCreateTime() );
        cmgtMaterialWarehouseInoutDetailDto.setUpdateBy( entity.getUpdateBy() );
        cmgtMaterialWarehouseInoutDetailDto.setUpdateTime( entity.getUpdateTime() );
        cmgtMaterialWarehouseInoutDetailDto.setVersion( entity.getVersion() );
        cmgtMaterialWarehouseInoutDetailDto.setLastTime( entity.getLastTime() );
        cmgtMaterialWarehouseInoutDetailDto.setId( entity.getId() );
        cmgtMaterialWarehouseInoutDetailDto.setWarehouseInoutId( entity.getWarehouseInoutId() );
        cmgtMaterialWarehouseInoutDetailDto.setMaterialInfoId( entity.getMaterialInfoId() );
        cmgtMaterialWarehouseInoutDetailDto.setQuantityId( entity.getQuantityId() );
        cmgtMaterialWarehouseInoutDetailDto.setName( entity.getName() );
        cmgtMaterialWarehouseInoutDetailDto.setModel( entity.getModel() );
        cmgtMaterialWarehouseInoutDetailDto.setQuantity( entity.getQuantity() );
        cmgtMaterialWarehouseInoutDetailDto.setAvailableQuantity( entity.getAvailableQuantity() );
        cmgtMaterialWarehouseInoutDetailDto.setPrice( entity.getPrice() );
        cmgtMaterialWarehouseInoutDetailDto.setAmount( entity.getAmount() );
        cmgtMaterialWarehouseInoutDetailDto.setSupplier( entity.getSupplier() );
        cmgtMaterialWarehouseInoutDetailDto.setDescription( entity.getDescription() );
        cmgtMaterialWarehouseInoutDetailDto.setSn( entity.getSn() );
        cmgtMaterialWarehouseInoutDetailDto.setMemo( entity.getMemo() );
        cmgtMaterialWarehouseInoutDetailDto.setUnit( entity.getUnit() );
        cmgtMaterialWarehouseInoutDetailDto.setApplicant( entity.getApplicant() );
        cmgtMaterialWarehouseInoutDetailDto.setApplicantId( entity.getApplicantId() );
        cmgtMaterialWarehouseInoutDetailDto.setInoutDate( entity.getInoutDate() );
        cmgtMaterialWarehouseInoutDetailDto.setOrgId( entity.getOrgId() );
        cmgtMaterialWarehouseInoutDetailDto.setWarehouse( entity.getWarehouse() );
        cmgtMaterialWarehouseInoutDetailDto.setStatus( entity.getStatus() );

        return cmgtMaterialWarehouseInoutDetailDto;
    }

    @Override
    public List<CmgtMaterialWarehouseInoutDetail> toEntity(List<CmgtMaterialWarehouseInoutDetailDto> dtoList) {
        if ( dtoList == null ) {
            return null;
        }

        List<CmgtMaterialWarehouseInoutDetail> list = new ArrayList<CmgtMaterialWarehouseInoutDetail>( dtoList.size() );
        for ( CmgtMaterialWarehouseInoutDetailDto cmgtMaterialWarehouseInoutDetailDto : dtoList ) {
            list.add( toEntity( cmgtMaterialWarehouseInoutDetailDto ) );
        }

        return list;
    }

    @Override
    public List<CmgtMaterialWarehouseInoutDetailDto> toDto(List<CmgtMaterialWarehouseInoutDetail> entityList) {
        if ( entityList == null ) {
            return null;
        }

        List<CmgtMaterialWarehouseInoutDetailDto> list = new ArrayList<CmgtMaterialWarehouseInoutDetailDto>( entityList.size() );
        for ( CmgtMaterialWarehouseInoutDetail cmgtMaterialWarehouseInoutDetail : entityList ) {
            list.add( toDto( cmgtMaterialWarehouseInoutDetail ) );
        }

        return list;
    }
}
