webconfig文件增加如下配置:
<customHeaders>
<add name="Access-Control-Allow-Headers" value="TCookie,Origin,X-Requested-With,Authorization,Content-Type" />
<!--已做动态Origin处理,不要设置这个属性。详见AppConfig-->
<!--<add name="Access-Control-Allow-Origin" value="*" />-->
<!--<add name="Access-Control-Allow-Origin" value="http://test-local.www.com,http://debug.wwwww.com:8094,http://localhost:8080" />-->
<add name="Access-Control-Allow-Credentials" value="true" />
<add name="Access-Control-Allow-Methods" value="GET, POST, PUT, DELETE, OPTIONS" />
</customHeaders>