package com.qqchen.deploy.backend.system.converter;

import com.qqchen.deploy.backend.system.entity.RoleTag;
import com.qqchen.deploy.backend.framework.converter.BaseConverter;
import com.qqchen.deploy.backend.system.model.RoleTagDTO;
import org.mapstruct.Mapper;
import org.mapstruct.Mapping;
import org.mapstruct.MappingTarget;
import org.mapstruct.Mappings;

@Mapper(config = BaseConverter.class)
public interface RoleTagConverter extends BaseConverter<RoleTag, RoleTagDTO> {

    @Override
    @Mappings({
        @Mapping(target = "id", ignore = true),
        @Mapping(target = "roles", ignore = true),
        @Mapping(target = "createTime", ignore = true),
        @Mapping(target = "createBy", ignore = true),
        @Mapping(target = "updateTime", ignore = true),
        @Mapping(target = "updateBy", ignore = true),
        @Mapping(target = "version", ignore = true),
        @Mapping(target = "deleted", ignore = true)
    })
    void updateEntity(@MappingTarget RoleTag entity, RoleTagDTO dto);
} 