Subversion Repositories SmartDukaan

Rev

Rev 35033 | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 35033 Rev 35867
Line 11... Line 11...
11
import org.springframework.format.FormatterRegistry;
11
import org.springframework.format.FormatterRegistry;
12
import org.springframework.format.datetime.standard.DateTimeFormatterRegistrar;
12
import org.springframework.format.datetime.standard.DateTimeFormatterRegistrar;
13
import org.springframework.http.MediaType;
13
import org.springframework.http.MediaType;
14
import org.springframework.http.converter.HttpMessageConverter;
14
import org.springframework.http.converter.HttpMessageConverter;
15
import org.springframework.http.converter.json.MappingJackson2HttpMessageConverter;
15
import org.springframework.http.converter.json.MappingJackson2HttpMessageConverter;
-
 
16
import org.springframework.scheduling.annotation.EnableScheduling;
16
import org.springframework.web.servlet.LocaleResolver;
17
import org.springframework.web.servlet.LocaleResolver;
17
import org.springframework.web.servlet.config.annotation.*;
18
import org.springframework.web.servlet.config.annotation.*;
18
import org.springframework.web.servlet.i18n.LocaleChangeInterceptor;
19
import org.springframework.web.servlet.i18n.LocaleChangeInterceptor;
19
import org.springframework.web.servlet.i18n.SessionLocaleResolver;
20
import org.springframework.web.servlet.i18n.SessionLocaleResolver;
20
 
21
 
21
import java.util.List;
22
import java.util.List;
22
import java.util.Locale;
23
import java.util.Locale;
23
 
24
 
24
@EnableWebMvc
25
@EnableWebMvc
-
 
26
@EnableScheduling
25
@Configuration
27
@Configuration
26
@ComponentScan({"com.spice.profitmandi.*"})
28
@ComponentScan({"com.spice.profitmandi.*"})
27
public class WebConfig extends WebMvcConfigurerAdapter {
29
public class WebConfig extends WebMvcConfigurerAdapter {
28
 
30
 
29
    private static final String RESOURCES_PATTERN = "/resources/**";
31
    private static final String RESOURCES_PATTERN = "/resources/**";
Line 53... Line 55...
53
        // registry.addInterceptor()
55
        // registry.addInterceptor()
54
        registry.addInterceptor(localeChangeInterceptor());
56
        registry.addInterceptor(localeChangeInterceptor());
55
        registry.addInterceptor(authenticationInterceptor).addPathPatterns("/**").excludePathPatterns("/hdfctest/**",
57
        registry.addInterceptor(authenticationInterceptor).addPathPatterns("/**").excludePathPatterns("/hdfctest/**",
56
                "/hdfc/**", "/spicemoney/callback", "/login", "/login/", "/forgetPassword", "/forgetPassword/", "/",
58
                "/hdfc/**", "/spicemoney/callback", "/login", "/login/", "/forgetPassword", "/forgetPassword/", "/",
57
                "/checkplans", "/12dashboard34", "/mandii", "/imei/validate", "/fundfina/**", "/virtualaccount/push-credits", "/wa-invoice-send/**",
59
                "/checkplans", "/12dashboard34", "/mandii", "/imei/validate", "/fundfina/**", "/virtualaccount/push-credits", "/wa-invoice-send/**",
58
                "/click2call/report-handler", "/click2call/report-handler/recording-url", "/click2call/push-call-log-handler", "/wa-listen", "/upsellPayment/callback", "/sales/logix");
60
                "/click2call/report-handler", "/click2call/report-handler/recording-url", "/click2call/push-call-log-handler", "/wa-listen", "/upsellPayment/callback", "/sales/logix",
-
 
61
                "/indent/rbm_call_target/update_status_by_name", "/indent/rbm_call_target/get_agent_statuses", "/indent/rbm_call_target/reload_mapping", "/indent/rbm_call_target/get_agent_mapping",
-
 
62
                "/indent/rbm_call_target/scraper/**");
59
        registry.addInterceptor(roleInterceptor).excludePathPatterns("/hdfctest/**", "/hdfc/**", "/spicemoney/callback", "/upsellPayment/callback", "/click2call/report-handler/recording-url", "/click2call/push-call-log-handler", "/click2call/report-handler",
63
        registry.addInterceptor(roleInterceptor).excludePathPatterns("/hdfctest/**", "/hdfc/**", "/spicemoney/callback", "/upsellPayment/callback", "/click2call/report-handler/recording-url", "/click2call/push-call-log-handler", "/click2call/report-handler",
60
                "/login", "/login/", "/register", "/register/", "/forgetPassword", "/forgetPassword/", "/", "",
64
                "/login", "/login/", "/register", "/register/", "/forgetPassword", "/forgetPassword/", "/", "",
61
                "/12dashboard34", "/mandii", "/imei/validate", "/fundfina/**", "/virtualaccount/push-credits", "/wa-invoice-send/**", "/wa-listen", "/sendInvoiceOnWhatsApp", "/sales/logix");
65
                "/12dashboard34", "/mandii", "/imei/validate", "/fundfina/**", "/virtualaccount/push-credits", "/wa-invoice-send/**", "/wa-listen", "/sendInvoiceOnWhatsApp", "/sales/logix",
-
 
66
                "/indent/rbm_call_target/update_status_by_name", "/indent/rbm_call_target/get_agent_statuses", "/indent/rbm_call_target/reload_mapping", "/indent/rbm_call_target/get_agent_mapping",
-
 
67
                "/indent/rbm_call_target/scraper/**");
62
        registry.addInterceptor(postInterceptor).addPathPatterns("/**").excludePathPatterns("/reports/**", "/hdfctest/**",
68
        registry.addInterceptor(postInterceptor).addPathPatterns("/**").excludePathPatterns("/reports/**", "/hdfctest/**",
63
                "/hdfc/**", "/spicemoney/callback", "/login", "/login/", "/forgetPassword", "/forgetPassword/", "/", "/checkplans", "/12dashboard34", "/mandii", "/imei/validate", "/fundfina/**", "/virtualaccount/push-credits", "/wa-invoice-send/**",
69
                "/hdfc/**", "/spicemoney/callback", "/login", "/login/", "/forgetPassword", "/forgetPassword/", "/", "/checkplans", "/12dashboard34", "/mandii", "/imei/validate", "/fundfina/**", "/virtualaccount/push-credits", "/wa-invoice-send/**",
64
                "/click2call/report-handler", "/click2call/report-handler/recording-url", "/click2call/push-call-log-handler", "/wa-listen", "/upsellPayment/callback", "/sales/logix");
70
                "/click2call/report-handler", "/click2call/report-handler/recording-url", "/click2call/push-call-log-handler", "/wa-listen", "/upsellPayment/callback", "/sales/logix",
-
 
71
                "/indent/rbm_call_target/update_status_by_name", "/indent/rbm_call_target/get_agent_statuses", "/indent/rbm_call_target/reload_mapping", "/indent/rbm_call_target/get_agent_mapping",
-
 
72
                "/indent/rbm_call_target/scraper/**");
65
    }
73
    }
66
 
74
 
67
    @Override
75
    @Override
68
    public void addFormatters(FormatterRegistry registry) {
76
    public void addFormatters(FormatterRegistry registry) {
69
        DateTimeFormatterRegistrar registrar = new DateTimeFormatterRegistrar();
77
        DateTimeFormatterRegistrar registrar = new DateTimeFormatterRegistrar();