package com.qmth.paper.library.common.config;

import com.qmth.paper.library.common.domain.FssDomain;
import com.qmth.paper.library.common.domain.SmsDomain;
import com.qmth.paper.library.common.domain.SysDomain;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

/**
 * 数据字典
 */
@Configuration
public class DictionaryConfig {

    /**
     * 系统配置
     */
    @Bean
    @ConfigurationProperties(prefix = "sys.config")
    public SysDomain sysDomain() {
        return new SysDomain();
    }

    /**
     * 短信配置
     */
    @Bean
    @ConfigurationProperties(prefix = "sms.config")
    public SmsDomain smsDomain() {
        return new SmsDomain();
    }

    /**
     * fss配置
     */
    @Bean
    @ConfigurationProperties(prefix = "com.qmth.fss", ignoreUnknownFields = false)
    public FssDomain fssDomain() {
        return new FssDomain();
    }
}
