From f3406b5d603b0b8ac026cda734739262207d6065 Mon Sep 17 00:00:00 2001
From: yangle <admin@YINMOU>
Date: 星期二, 20 十二月 2022 16:27:11 +0800
Subject: [PATCH] 器具维修记录单 源单类型 (手工录入 维修派工单 故障登记单 ) 根据类型去选择相对应的单据 带出数据 器具维修记录单 子表两个 页签  (维修信息 配件信息)--参考设备维修记录单

---
 WebAPI/App_Start/WebApiConfig.cs |    6 +++++-
 1 files changed, 5 insertions(+), 1 deletions(-)

diff --git a/WebAPI/App_Start/WebApiConfig.cs b/WebAPI/App_Start/WebApiConfig.cs
index 059fbdc..511fe89 100644
--- a/WebAPI/App_Start/WebApiConfig.cs
+++ b/WebAPI/App_Start/WebApiConfig.cs
@@ -2,6 +2,8 @@
 using System.Collections.Generic;
 using System.Linq;
 using System.Web.Http;
+using System.Web.Http.Cors;
+using WebAPI.Dapper;
 
 namespace WebAPI
 {
@@ -13,7 +15,9 @@
             GlobalConfiguration.Configuration.Formatters.XmlFormatter.SupportedMediaTypes.Clear();
             // Web API 璺敱
             config.MapHttpAttributeRoutes();
-
+            new SqlPools();
+            var corsAttr = new EnableCorsAttribute("*", "*", "*");
+            config.EnableCors(corsAttr);
             config.Routes.MapHttpRoute(
                 name: "DefaultApi",
                 routeTemplate: "api/{controller}/{id}",

--
Gitblit v1.9.1