package com.sptg.statistics.biz.receiver;

import com.sptg.permissions.api.dto.OrgDto;
import com.sptg.permissions.api.stream.OrgModifyNameReceiverInterface;
import lombok.RequiredArgsConstructor;
import lombok.extern.slf4j.Slf4j;
import org.springframework.cloud.stream.annotation.EnableBinding;
import org.springframework.cloud.stream.annotation.StreamListener;
import org.springframework.stereotype.Component;

/**
 * title: OrgModifyNameReceiver
 * description: 机构名称修改消费者
 *
 *                  
 *            
 */
@Component
@Slf4j
@RequiredArgsConstructor
@EnableBinding(value = { OrgModifyNameReceiverInterface.class})
public class OrgModifyNameReceiver {

    @StreamListener(value = OrgModifyNameReceiverInterface.INPUT)
    public void input(OrgDto dto){
        //  机构Id
        Long orgId = dto.getId();
        //  机构新名称
        String orgName = dto.getName();


    }

}
