From 4f57c3e602eef9ec929a2315183fa28b21cd0987 Mon Sep 17 00:00:00 2001
From: yl <ykxkd@outlook.com>
Date: 星期三, 29 三月 2023 10:51:33 +0800
Subject: [PATCH] 订单下达获取工单语句修改、生产工单手工创建获取单据号接口
---
VueWebApi/App_Start/Startup.cs | 38 ++++++++++++++++++++++++++++++++++++--
1 files changed, 36 insertions(+), 2 deletions(-)
diff --git a/VueWebApi/App_Start/Startup.cs b/VueWebApi/App_Start/Startup.cs
index d2fc6c2..21fb9c4 100644
--- a/VueWebApi/App_Start/Startup.cs
+++ b/VueWebApi/App_Start/Startup.cs
@@ -1,4 +1,6 @@
-锘縰sing Microsoft.Owin;
+锘縰sing Microsoft.AspNet.SignalR;
+using Microsoft.Owin;
+using Microsoft.Owin.Cors;
using Owin;
using System;
using System.Collections.Generic;
@@ -11,7 +13,39 @@
{
public void Configuration(IAppBuilder app)
{
- // 閰嶇疆闆嗙嚎鍣�
+ // 鏈夊叧濡備綍閰嶇疆搴旂敤绋嬪簭鐨勮缁嗕俊鎭紝璇疯闂� https://go.microsoft.com/fwlink/?LinkID=316888
+ //鍏佽璺ㄥ煙
+ //app.UseCors(CorsOptions.AllowAll);
+ //app.MapSignalR("Hubs/chatHub", new HubConfiguration());
+ //app.MapSignalR();
+ //鑷繁璁惧畾璁块棶璺緞锛屽悓鏃惰缃瓾ub閰嶇疆椤癸紝鏃犻渶鎸囧畾鍚姩鐨凥ub绫伙紝鍥犱负瀹冧滑琚嚜鍔ㄨ瘑鍒�
+
+ // 杩炴帴鏍囪瘑
+ //app.Map("/signalr", map =>
+ //{
+ // //璺ㄥ煙
+ // map.UseCors(CorsOptions.AllowAll);
+ // var hubConfiguration = new HubConfiguration
+ // {
+ // EnableJSONP = true
+ // };
+ // //鍚姩閰嶇疆
+ // map.RunSignalR(hubConfiguration);
+ //});
+
+
+ // 杩炴帴鏍囪瘑
+ app.Map("/signalr", map =>
+ {
+ //璺ㄥ煙
+ map.UseCors(CorsOptions.AllowAll);
+ var hubConfiguration = new HubConfiguration
+ {
+ EnableJSONP = true
+ };
+ //鍚姩閰嶇疆
+ map.RunSignalR(hubConfiguration);
+ });
app.MapSignalR();
}
}
--
Gitblit v1.9.3