package com.hotent.portal.config;

import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

import com.hotent.base.conf.WebSecurityExtend;

@Configuration
public class PortalWebSecurityExtend {

	@Bean
	WebSecurityExtend getPortalExtend() {
		return new WebSecurityExtend() {

			@Override
			public String[] getIgnoringPostUrl() {
				return new String[] { "/sys/sysLogs/v1/loginLogs", "/sys/sysLogs/v1/saveLogs" };
			}

			@Override
			public String[] getIgnoringGetUrl() {
				return new String[] {
						"/sys/sysRoleAuth/v1/getMethodRoleAuth",
						"/sys/sysLogsSettings/v1/getSysLogsSettingStatusMap",
						"/system/file/v1/getLogoFile",
						"/system/file/v1/getImage",
						//"/system/file/v1/downloadFile", 
						//"/file/onlinePreviewController/v1/getFileByPathAndId**",
						//"/file/onlinePreviewController/v1/getFileById**", 
						"/portal/main/v1/appProperties",
						"/sys/sysProperties/v1/getByAlias",
						"/sys/sysProperties/v1/getDecryptBySysSetting",
		                "/portal/shorturlManage/v1/getLongUrlByShortUrl"
					};
			}

		};
	}

}
