diff --git a/nladmin-system/src/main/java/org/nl/AppRun.java b/nladmin-system/src/main/java/org/nl/AppRun.java index 1e1b2cb3f..fcbe866e9 100644 --- a/nladmin-system/src/main/java/org/nl/AppRun.java +++ b/nladmin-system/src/main/java/org/nl/AppRun.java @@ -1,9 +1,9 @@ package org.nl; +import cn.dev33.satoken.annotation.SaIgnore; import com.alicp.jetcache.anno.config.EnableCreateCacheAnnotation; import com.alicp.jetcache.anno.config.EnableMethodCache; import io.swagger.annotations.Api; -import org.nl.modules.common.annotation.rest.AnonymousGetMapping; import org.nl.wql.util.SpringContextHolder; import org.springframework.boot.SpringApplication; import org.springframework.boot.autoconfigure.SpringBootApplication; @@ -14,6 +14,7 @@ import org.springframework.context.annotation.Bean; import org.springframework.data.jpa.repository.config.EnableJpaAuditing; import org.springframework.scheduling.annotation.EnableAsync; import org.springframework.transaction.annotation.EnableTransactionManagement; +import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.RestController; /** @@ -58,7 +59,8 @@ public class AppRun { * * @return / */ - @AnonymousGetMapping("/") + @GetMapping("/") + @SaIgnore public String index() { return "Backend service started successfully"; } diff --git a/nladmin-system/src/main/java/org/nl/modules/common/annotation/AnonymousAccess.java b/nladmin-system/src/main/java/org/nl/modules/common/annotation/AnonymousAccess.java deleted file mode 100644 index 679568ff4..000000000 --- a/nladmin-system/src/main/java/org/nl/modules/common/annotation/AnonymousAccess.java +++ /dev/null @@ -1,30 +0,0 @@ -/* - * 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.modules.common.annotation; - -import java.lang.annotation.*; - -/** - * @author jacky - * 用于标记匿名访问方法 - */ -@Inherited -@Documented -@Target({ElementType.METHOD,ElementType.ANNOTATION_TYPE}) -@Retention(RetentionPolicy.RUNTIME) -public @interface AnonymousAccess { - -} diff --git a/nladmin-system/src/main/java/org/nl/modules/common/annotation/rest/AnonymousDeleteMapping.java b/nladmin-system/src/main/java/org/nl/modules/common/annotation/rest/AnonymousDeleteMapping.java deleted file mode 100644 index dedeeb4d4..000000000 --- a/nladmin-system/src/main/java/org/nl/modules/common/annotation/rest/AnonymousDeleteMapping.java +++ /dev/null @@ -1,86 +0,0 @@ -/* - * Copyright 2002-2016 the original author or authors. - * - * 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.modules.common.annotation.rest; - -import org.nl.annotation.AnonymousAccess; -import org.springframework.core.annotation.AliasFor; -import org.springframework.web.bind.annotation.RequestMapping; -import org.springframework.web.bind.annotation.RequestMethod; - -import java.lang.annotation.*; - -/** - * Annotation for mapping HTTP {@code DELETE} requests onto specific handler - * methods. - * 支持匿名访问 DeleteMapping - * - * @author liaojinlong - * @see AnonymousGetMapping - * @see AnonymousPostMapping - * @see AnonymousPutMapping - * @see AnonymousPatchMapping - * @see RequestMapping - */ -@AnonymousAccess -@Target(ElementType.METHOD) -@Retention(RetentionPolicy.RUNTIME) -@Documented -@RequestMapping(method = RequestMethod.DELETE) -public @interface AnonymousDeleteMapping { - - /** - * Alias for {@link RequestMapping#name}. - */ - @AliasFor(annotation = RequestMapping.class) - String name() default ""; - - /** - * Alias for {@link RequestMapping#value}. - */ - @AliasFor(annotation = RequestMapping.class) - String[] value() default {}; - - /** - * Alias for {@link RequestMapping#path}. - */ - @AliasFor(annotation = RequestMapping.class) - String[] path() default {}; - - /** - * Alias for {@link RequestMapping#params}. - */ - @AliasFor(annotation = RequestMapping.class) - String[] params() default {}; - - /** - * Alias for {@link RequestMapping#headers}. - */ - @AliasFor(annotation = RequestMapping.class) - String[] headers() default {}; - - /** - * Alias for {@link RequestMapping#consumes}. - */ - @AliasFor(annotation = RequestMapping.class) - String[] consumes() default {}; - - /** - * Alias for {@link RequestMapping#produces}. - */ - @AliasFor(annotation = RequestMapping.class) - String[] produces() default {}; - -} diff --git a/nladmin-system/src/main/java/org/nl/modules/common/annotation/rest/AnonymousGetMapping.java b/nladmin-system/src/main/java/org/nl/modules/common/annotation/rest/AnonymousGetMapping.java deleted file mode 100644 index 0588a58e0..000000000 --- a/nladmin-system/src/main/java/org/nl/modules/common/annotation/rest/AnonymousGetMapping.java +++ /dev/null @@ -1,86 +0,0 @@ -/* - * Copyright 2002-2016 the original author or authors. - * - * 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.modules.common.annotation.rest; - -import org.nl.annotation.AnonymousAccess; -import org.springframework.core.annotation.AliasFor; -import org.springframework.web.bind.annotation.RequestMapping; -import org.springframework.web.bind.annotation.RequestMethod; - -import java.lang.annotation.*; - -/** - * Annotation for mapping HTTP {@code GET} requests onto specific handler - * methods. - *
- * 支持匿名访问 GetMapping
- *
- * @author liaojinlong
- * @see RequestMapping
- */
-@AnonymousAccess
-@Target(ElementType.METHOD)
-@Retention(RetentionPolicy.RUNTIME)
-@Documented
-@RequestMapping(method = RequestMethod.GET)
-public @interface AnonymousGetMapping {
-
- /**
- * Alias for {@link RequestMapping#name}.
- */
- @AliasFor(annotation = RequestMapping.class)
- String name() default "";
-
- /**
- * Alias for {@link RequestMapping#value}.
- */
- @AliasFor(annotation = RequestMapping.class)
- String[] value() default {};
-
- /**
- * Alias for {@link RequestMapping#path}.
- */
- @AliasFor(annotation = RequestMapping.class)
- String[] path() default {};
-
- /**
- * Alias for {@link RequestMapping#params}.
- */
- @AliasFor(annotation = RequestMapping.class)
- String[] params() default {};
-
- /**
- * Alias for {@link RequestMapping#headers}.
- */
- @AliasFor(annotation = RequestMapping.class)
- String[] headers() default {};
-
- /**
- * Alias for {@link RequestMapping#consumes}.
- *
- * @since 4.3.5
- */
- @AliasFor(annotation = RequestMapping.class)
- String[] consumes() default {};
-
- /**
- * Alias for {@link RequestMapping#produces}.
- */
- @AliasFor(annotation = RequestMapping.class)
- String[] produces() default {};
-
-}
diff --git a/nladmin-system/src/main/java/org/nl/modules/common/annotation/rest/AnonymousPatchMapping.java b/nladmin-system/src/main/java/org/nl/modules/common/annotation/rest/AnonymousPatchMapping.java
deleted file mode 100644
index 515ddd1ed..000000000
--- a/nladmin-system/src/main/java/org/nl/modules/common/annotation/rest/AnonymousPatchMapping.java
+++ /dev/null
@@ -1,87 +0,0 @@
-/*
- * Copyright 2002-2016 the original author or authors.
- *
- * 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.modules.common.annotation.rest;
-
-import org.nl.annotation.AnonymousAccess;
-import org.springframework.core.annotation.AliasFor;
-import org.springframework.web.bind.annotation.RequestMapping;
-import org.springframework.web.bind.annotation.RequestMethod;
-
-import java.lang.annotation.*;
-
-/**
- * Annotation for mapping HTTP {@code PATCH} requests onto specific handler
- * methods.
- * * 支持匿名访问 PatchMapping
- *
- * @author liaojinlong
- * @see AnonymousGetMapping
- * @see AnonymousPostMapping
- * @see AnonymousPutMapping
- * @see AnonymousDeleteMapping
- * @see RequestMapping
- */
-@AnonymousAccess
-@Target(ElementType.METHOD)
-@Retention(RetentionPolicy.RUNTIME)
-@Documented
-@RequestMapping(method = RequestMethod.PATCH)
-public @interface AnonymousPatchMapping {
-
- /**
- * Alias for {@link RequestMapping#name}.
- */
- @AliasFor(annotation = RequestMapping.class)
- String name() default "";
-
- /**
- * Alias for {@link RequestMapping#value}.
- */
- @AliasFor(annotation = RequestMapping.class)
- String[] value() default {};
-
- /**
- * Alias for {@link RequestMapping#path}.
- */
- @AliasFor(annotation = RequestMapping.class)
- String[] path() default {};
-
- /**
- * Alias for {@link RequestMapping#params}.
- */
- @AliasFor(annotation = RequestMapping.class)
- String[] params() default {};
-
- /**
- * Alias for {@link RequestMapping#headers}.
- */
- @AliasFor(annotation = RequestMapping.class)
- String[] headers() default {};
-
- /**
- * Alias for {@link RequestMapping#consumes}.
- */
- @AliasFor(annotation = RequestMapping.class)
- String[] consumes() default {};
-
- /**
- * Alias for {@link RequestMapping#produces}.
- */
- @AliasFor(annotation = RequestMapping.class)
- String[] produces() default {};
-
-}
diff --git a/nladmin-system/src/main/java/org/nl/modules/common/annotation/rest/AnonymousPostMapping.java b/nladmin-system/src/main/java/org/nl/modules/common/annotation/rest/AnonymousPostMapping.java
deleted file mode 100644
index 326e9b17c..000000000
--- a/nladmin-system/src/main/java/org/nl/modules/common/annotation/rest/AnonymousPostMapping.java
+++ /dev/null
@@ -1,87 +0,0 @@
-/*
- * Copyright 2002-2016 the original author or authors.
- *
- * 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.modules.common.annotation.rest;
-
-import org.nl.annotation.AnonymousAccess;
-import org.springframework.core.annotation.AliasFor;
-import org.springframework.web.bind.annotation.RequestMapping;
-import org.springframework.web.bind.annotation.RequestMethod;
-
-import java.lang.annotation.*;
-
-/**
- * Annotation for mapping HTTP {@code POST} requests onto specific handler
- * methods.
- * 支持匿名访问 PostMapping
- *
- * @author liaojinlong
- * @see AnonymousGetMapping
- * @see AnonymousPostMapping
- * @see AnonymousPutMapping
- * @see AnonymousDeleteMapping
- * @see RequestMapping
- */
-@AnonymousAccess
-@Target(ElementType.METHOD)
-@Retention(RetentionPolicy.RUNTIME)
-@Documented
-@RequestMapping(method = RequestMethod.POST)
-public @interface AnonymousPostMapping {
-
- /**
- * Alias for {@link RequestMapping#name}.
- */
- @AliasFor(annotation = RequestMapping.class)
- String name() default "";
-
- /**
- * Alias for {@link RequestMapping#value}.
- */
- @AliasFor(annotation = RequestMapping.class)
- String[] value() default {};
-
- /**
- * Alias for {@link RequestMapping#path}.
- */
- @AliasFor(annotation = RequestMapping.class)
- String[] path() default {};
-
- /**
- * Alias for {@link RequestMapping#params}.
- */
- @AliasFor(annotation = RequestMapping.class)
- String[] params() default {};
-
- /**
- * Alias for {@link RequestMapping#headers}.
- */
- @AliasFor(annotation = RequestMapping.class)
- String[] headers() default {};
-
- /**
- * Alias for {@link RequestMapping#consumes}.
- */
- @AliasFor(annotation = RequestMapping.class)
- String[] consumes() default {};
-
- /**
- * Alias for {@link RequestMapping#produces}.
- */
- @AliasFor(annotation = RequestMapping.class)
- String[] produces() default {};
-
-}
diff --git a/nladmin-system/src/main/java/org/nl/modules/common/annotation/rest/AnonymousPutMapping.java b/nladmin-system/src/main/java/org/nl/modules/common/annotation/rest/AnonymousPutMapping.java
deleted file mode 100644
index bef341b20..000000000
--- a/nladmin-system/src/main/java/org/nl/modules/common/annotation/rest/AnonymousPutMapping.java
+++ /dev/null
@@ -1,87 +0,0 @@
-/*
- * Copyright 2002-2016 the original author or authors.
- *
- * 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.modules.common.annotation.rest;
-
-import org.nl.annotation.AnonymousAccess;
-import org.springframework.core.annotation.AliasFor;
-import org.springframework.web.bind.annotation.RequestMapping;
-import org.springframework.web.bind.annotation.RequestMethod;
-
-import java.lang.annotation.*;
-
-/**
- * Annotation for mapping HTTP {@code PUT} requests onto specific handler
- * methods.
- * * 支持匿名访问 PutMapping
- *
- * @author liaojinlong
- * @see AnonymousGetMapping
- * @see AnonymousPostMapping
- * @see AnonymousPutMapping
- * @see AnonymousDeleteMapping
- * @see RequestMapping
- */
-@AnonymousAccess
-@Target(ElementType.METHOD)
-@Retention(RetentionPolicy.RUNTIME)
-@Documented
-@RequestMapping(method = RequestMethod.PUT)
-public @interface AnonymousPutMapping {
-
- /**
- * Alias for {@link RequestMapping#name}.
- */
- @AliasFor(annotation = RequestMapping.class)
- String name() default "";
-
- /**
- * Alias for {@link RequestMapping#value}.
- */
- @AliasFor(annotation = RequestMapping.class)
- String[] value() default {};
-
- /**
- * Alias for {@link RequestMapping#path}.
- */
- @AliasFor(annotation = RequestMapping.class)
- String[] path() default {};
-
- /**
- * Alias for {@link RequestMapping#params}.
- */
- @AliasFor(annotation = RequestMapping.class)
- String[] params() default {};
-
- /**
- * Alias for {@link RequestMapping#headers}.
- */
- @AliasFor(annotation = RequestMapping.class)
- String[] headers() default {};
-
- /**
- * Alias for {@link RequestMapping#consumes}.
- */
- @AliasFor(annotation = RequestMapping.class)
- String[] consumes() default {};
-
- /**
- * Alias for {@link RequestMapping#produces}.
- */
- @AliasFor(annotation = RequestMapping.class)
- String[] produces() default {};
-
-}
diff --git a/nladmin-system/src/main/java/org/nl/modules/quartz/task/wql/QS_PERFORMANCE.wql b/nladmin-system/src/main/java/org/nl/modules/quartz/task/wql/QS_PERFORMANCE.wql
deleted file mode 100644
index 77bbc003a..000000000
--- a/nladmin-system/src/main/java/org/nl/modules/quartz/task/wql/QS_PERFORMANCE.wql
+++ /dev/null
@@ -1,245 +0,0 @@
-[交易说明]
- 交易名: 业绩指标
- 所属模块:
- 功能简述:
- 版权所有:
- 表引用:
- 版本经历:
-
-[数据库]
- --指定数据库,为空采用默认值,默认为db.properties中列出的第一个库
-
-[IO定义]
- #################################################
- ## 表字段对应输入参数
- #################################################
- 输入.flag TYPEAS s_string
- 输入.where TYPEAS f_string
-
-
-[临时表]
- --这边列出来的临时表就会在运行期动态创建
-
-[临时变量]
- --所有中间过程变量均可在此处定义
-
-[业务过程]
-
- ##########################################
- # 1、输入输出检查 #
- ##########################################
-
-
- ##########################################
- # 2、主过程前处理 #
- ##########################################
-
-
- ##########################################
- # 3、业务主过程 #
- ##########################################
-
- IF 输入.flag = "1"
- QUERY
- SELECT
- work.workorder_id,
- task.material_id,
- task.pcsn
- FROM
- PDM_BI_WorkOrder work
- LEFT JOIN PDM_BI_WorkTask task ON work.workorder_id = task.workorder_id
- WHERE
- work.is_delete = '0'
- AND task.status = '99'
- AND task.workprocedure_code = 'GX003'
- AND task.nextworkprocedure_id = task.workprocedure_id
- AND (
- work.create_time>=date(now()) and work.create_time