维护列表
parent
0f5c517bb2
commit
059dca0677
|
@ -62,6 +62,12 @@
|
|||
<artifactId>cloud-common-datascope</artifactId>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-starter-mail</artifactId>
|
||||
<version>2.2.6.RELEASE</version>
|
||||
</dependency>
|
||||
|
||||
<!-- MuYu Common Log -->
|
||||
<!-- <dependency>-->
|
||||
<!-- <groupId>com.muyu</groupId>-->
|
||||
|
@ -74,6 +80,15 @@
|
|||
<artifactId>cloud-common-api-doc</artifactId>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>org.springframework</groupId>
|
||||
<artifactId>spring-tx</artifactId>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>junit</groupId>
|
||||
<artifactId>junit</artifactId>
|
||||
</dependency>
|
||||
|
||||
<!-- <!– XllJob定时任务 –>-->
|
||||
<!-- <dependency>-->
|
||||
<!-- <groupId>com.muyu</groupId>-->
|
||||
|
|
|
@ -21,7 +21,7 @@ import java.util.Arrays;
|
|||
public class ClassSource {
|
||||
public static void main(String[] args) {
|
||||
//定义类名和源代码
|
||||
String className = "MyDynamicClass";
|
||||
String className = "com.muyu.calss.MyDynamicClass";
|
||||
String sourceCode = "public class" + className + "{public String name}";
|
||||
//编译代码
|
||||
JavaCompiler compiler = ToolProvider.getSystemJavaCompiler();
|
||||
|
@ -73,7 +73,5 @@ public class ClassSource {
|
|||
} catch (IOException e) {
|
||||
throw new RuntimeException(e);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
|
|
|
@ -0,0 +1,39 @@
|
|||
//package com.muyu.calss;
|
||||
//
|
||||
//import lombok.extern.log4j.Log4j2;
|
||||
//import org.slf4j.LoggerFactory;
|
||||
//import org.springframework.beans.factory.annotation.Autowired;
|
||||
//import org.springframework.beans.factory.annotation.Value;
|
||||
//import org.springframework.mail.javamail.JavaMailSender;
|
||||
//import org.springframework.mail.javamail.MimeMessageHelper;
|
||||
//import org.springframework.stereotype.Component;
|
||||
//
|
||||
//import javax.mail.MessagingException;
|
||||
//import javax.mail.internet.MimeMessage;
|
||||
//import java.util.logging.Logger;
|
||||
//
|
||||
//@Log4j2
|
||||
//@Component
|
||||
//public class MailClient {
|
||||
// private static final Logger logger = (Logger) LoggerFactory.getLogger(MailClient.class);
|
||||
//
|
||||
// @Autowired(required = false)
|
||||
// private JavaMailSender mailSender;
|
||||
//
|
||||
// @Value("${spring.mail.username}")
|
||||
// private String from;
|
||||
//
|
||||
// public void sendMail(String to, String subject, String content) {
|
||||
// try {
|
||||
// MimeMessage message = mailSender.createMimeMessage();
|
||||
// MimeMessageHelper helper = new MimeMessageHelper(message);
|
||||
// helper.setFrom("2720806930@qq.com");
|
||||
// helper.setTo("168519884@qq.com");
|
||||
// helper.setSubject("你好");
|
||||
// helper.setText("八维云计算", true);
|
||||
// mailSender.send(helper.getMimeMessage());
|
||||
// } catch (MessagingException e) {
|
||||
// log.info("发送邮件失败:{}", e.getMessage());
|
||||
// }
|
||||
// }
|
||||
//}
|
|
@ -0,0 +1,21 @@
|
|||
//package com.muyu.calss;
|
||||
//
|
||||
//import org.junit.Test;
|
||||
//import org.junit.runner.RunWith;
|
||||
//import org.springframework.beans.factory.annotation.Autowired;
|
||||
//
|
||||
//@RunWith(SpringRunner.class)
|
||||
//@SpringBootTest
|
||||
//@ContextConfiguration(classes = CommunityApplication.class)
|
||||
//
|
||||
//public class MailTests {
|
||||
// @Autowired
|
||||
// private MailClient mailClient;
|
||||
//
|
||||
// @Autowired
|
||||
// private TemplateEngine templateEngine;
|
||||
// @Test
|
||||
// public void testTextMail(){
|
||||
// mailClient.sendMail("1092010788@qq.com","Test","12345");
|
||||
// }
|
||||
//}
|
|
@ -1,6 +1,8 @@
|
|||
package com.muyu.calss;
|
||||
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
/**
|
||||
* @Author:qdm
|
||||
|
@ -10,6 +12,8 @@ import lombok.Data;
|
|||
* @Date:2024/8/30 22:01
|
||||
*/
|
||||
@Data
|
||||
@AllArgsConstructor
|
||||
@NoArgsConstructor
|
||||
public class MyDynamicClass {
|
||||
private String name;
|
||||
|
||||
|
|
|
@ -164,8 +164,9 @@ public class EngIneController extends BaseController {
|
|||
/**
|
||||
* 规则详情
|
||||
*/
|
||||
@PostMapping("/selectEngineById/{id}")
|
||||
public Result<EngineMaintenance> selectEngineById(@PathVariable("id") Long id) {
|
||||
return engineVersionService.getByIds(id);
|
||||
@PostMapping("/selectEngineById/{versionId}")
|
||||
public List<EngineMaintenance> selectEngineById(@PathVariable Integer versionId) {
|
||||
List<EngineMaintenance> engineMaintenances = engineVersionService.getByIds(versionId);
|
||||
return engineMaintenances;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -6,6 +6,8 @@ import com.muyu.domain.EngineVersion;
|
|||
import org.apache.ibatis.annotations.Mapper;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @Author:qdm
|
||||
* @Package:com.muyu.mapper
|
||||
|
@ -17,5 +19,5 @@ import org.apache.ibatis.annotations.Param;
|
|||
public interface EngineVersionMapper extends BaseMapper<EngineVersion> {
|
||||
Integer add(EngineVersion engineVersion);
|
||||
|
||||
EngineMaintenance getByIds(@Param("id") Long id);
|
||||
List<EngineMaintenance> getByIds(@Param("versionId") Integer versionId);
|
||||
}
|
||||
|
|
|
@ -42,5 +42,5 @@ public interface EngineVersionService extends IService<EngineVersion> {
|
|||
|
||||
Result<EngineVersion> add(EngineVersion engineVersion);
|
||||
|
||||
Result<EngineMaintenance> getByIds(Long id);
|
||||
List<EngineMaintenance> getByIds(Integer versionId);
|
||||
}
|
||||
|
|
|
@ -166,8 +166,8 @@ public class EngineVersionServiceImpl extends ServiceImpl<EngineVersionMapper, E
|
|||
}
|
||||
|
||||
@Override
|
||||
public Result<EngineMaintenance> getByIds(Long id) {
|
||||
EngineMaintenance list = engineVersionMapper.getByIds(id);
|
||||
return Result.success(list);
|
||||
public List<EngineMaintenance> getByIds(Integer versionId) {
|
||||
List<EngineMaintenance> list = engineVersionMapper.getByIds(versionId);
|
||||
return list;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -11,6 +11,20 @@ nacos:
|
|||
|
||||
# Spring
|
||||
spring:
|
||||
mail:
|
||||
default-encoding: UTF-8
|
||||
host: smtp.qq.com
|
||||
username: 2720806930@qq.com
|
||||
password: gvfmmfg
|
||||
protocol: smtps
|
||||
properties:
|
||||
mail:
|
||||
smtp:
|
||||
auth: true
|
||||
starttls:
|
||||
enable: true
|
||||
required: true
|
||||
port: 587
|
||||
main:
|
||||
allow-bean-definition-overriding: true
|
||||
application:
|
||||
|
|
|
@ -13,19 +13,20 @@
|
|||
</insert>
|
||||
<select id="getByIds" resultType="com.muyu.domain.EngineMaintenance">
|
||||
select id,
|
||||
name,
|
||||
type,
|
||||
scope,
|
||||
engine_code,
|
||||
is_activate,
|
||||
status,
|
||||
description,
|
||||
create_by,
|
||||
create_time,
|
||||
update_by,
|
||||
update_time,
|
||||
remark,
|
||||
version_id
|
||||
from engine_maintenance where id = #{id}
|
||||
name,
|
||||
type,
|
||||
scope,
|
||||
engine_code,
|
||||
is_activate,
|
||||
status,
|
||||
description,
|
||||
create_by,
|
||||
create_time,
|
||||
update_by,
|
||||
update_time,
|
||||
remark,
|
||||
version_id
|
||||
from engine_maintenance
|
||||
where version_id = #{versionId}
|
||||
</select>
|
||||
</mapper>
|
||||
|
|
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue