From e5691da42a5be755b3b2635171d82950bb528a35 Mon Sep 17 00:00:00 2001 From: zhangzq Date: Tue, 13 Aug 2024 17:24:20 +0800 Subject: [PATCH] =?UTF-8?q?fix:=E8=B7=A8=E5=9F=9F=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../java/org/nl/config/ConfigurerAdapter.java | 47 +++ .../qd/src/layout/components/Sidebar/Logo.vue | 18 +- wms_pro/qd/src/views/login.vue | 2 +- .../views/wms/dispatch_manage/task/index2.vue | 364 ++++++++++++++++++ .../warehouse/checkStorage/AddDialog.vue | 111 +++--- 5 files changed, 474 insertions(+), 68 deletions(-) create mode 100644 wms_pro/hd/nladmin-system/src/main/java/org/nl/config/ConfigurerAdapter.java create mode 100644 wms_pro/qd/src/views/wms/dispatch_manage/task/index2.vue diff --git a/wms_pro/hd/nladmin-system/src/main/java/org/nl/config/ConfigurerAdapter.java b/wms_pro/hd/nladmin-system/src/main/java/org/nl/config/ConfigurerAdapter.java new file mode 100644 index 00000000..392f9ef0 --- /dev/null +++ b/wms_pro/hd/nladmin-system/src/main/java/org/nl/config/ConfigurerAdapter.java @@ -0,0 +1,47 @@ +/* + * Copyright 2019-2020 Zheng Jie + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package org.nl.config; + +import org.springframework.context.annotation.Bean; +import org.springframework.context.annotation.Configuration; +import org.springframework.web.cors.CorsConfiguration; +import org.springframework.web.cors.UrlBasedCorsConfigurationSource; +import org.springframework.web.filter.CorsFilter; +import org.springframework.web.servlet.config.annotation.EnableWebMvc; +import org.springframework.web.servlet.config.annotation.ResourceHandlerRegistry; +import org.springframework.web.servlet.config.annotation.WebMvcConfigurer; + +/** + * WebMvcConfigurer + * + * @author Zheng Jie + * @date 2018-11-30 + */ +@Configuration +@EnableWebMvc +public class ConfigurerAdapter implements WebMvcConfigurer { + @Bean + public CorsFilter corsFilter() { + UrlBasedCorsConfigurationSource source = new UrlBasedCorsConfigurationSource(); + CorsConfiguration config = new CorsConfiguration(); + config.setAllowCredentials(true); + config.addAllowedOrigin("*"); + config.addAllowedHeader("*"); + config.addAllowedMethod("*"); + source.registerCorsConfiguration("/**", config); + return new CorsFilter(source); + } +} diff --git a/wms_pro/qd/src/layout/components/Sidebar/Logo.vue b/wms_pro/qd/src/layout/components/Sidebar/Logo.vue index ba96c841..8c127dfe 100644 --- a/wms_pro/qd/src/layout/components/Sidebar/Logo.vue +++ b/wms_pro/qd/src/layout/components/Sidebar/Logo.vue @@ -2,11 +2,11 @@