package com.iformall;

import com.ulisesbocchio.jasyptspringboot.annotation.EnableEncryptableProperties;
import org.mybatis.spring.annotation.MapperScan;
import org.rocketmq.starter.annotation.EnableRocketMQ;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.context.annotation.Bean;

/**
 * @author Stormeye
 * @date   2019-08-08
 */
@SpringBootApplication
@MapperScan(basePackages = {"com.iformall.mapper"})
@EnableEncryptableProperties
@EnableRocketMQ
public class PosApplication {

	@Value("${fm.exception}")
	private boolean fmException;

    @Value("${fm.exception_emails}")
    private String fmExceptionEmails;

    @Value("${fm.open}")
    private boolean fmOpen;

    @Value("${fm.upload_dir}")
    private String uploadDir;

    @Bean
    public boolean isFmException() {
        return fmException;
    }

    @Bean
    public String fmExceptionEmails() {
        return fmExceptionEmails;
    }

    @Bean
    public boolean isFmOpen() {
        return fmOpen;
    }

    @Bean
    public String fmUploadDir() {
        return uploadDir;
    }


	public static void main(String[] args) {
		SpringApplication.run(PosApplication.class, args);
	}
}
