package com.trs.digital.framework.operatelog.config;

import com.trs.digital.framework.operatelog.core.aop.OperateLogAspect;
import com.trs.digital.framework.operatelog.core.service.OperateLogFrameworkService;
import com.trs.digital.framework.operatelog.core.service.OperateLogFrameworkServiceImpl;
import com.trs.digital.module.system.api.logger.OperateLogApi;
import org.springframework.boot.autoconfigure.AutoConfiguration;
import org.springframework.context.annotation.Bean;

@AutoConfiguration
public class DigitalOperateLogAutoConfiguration {

    @Bean
    public OperateLogAspect operateLogAspect() {
        return new OperateLogAspect();
    }

    @Bean
    public OperateLogFrameworkService operateLogFrameworkService(OperateLogApi operateLogApi) {
        return new OperateLogFrameworkServiceImpl(operateLogApi);
    }

}
