移除sqlite支持
This commit is contained in:
parent
c9a3d41325
commit
16c7f007c6
@ -11,12 +11,12 @@ import java.util.List;
|
|||||||
@Repository
|
@Repository
|
||||||
public interface RoleMapper {
|
public interface RoleMapper {
|
||||||
|
|
||||||
@Insert("INSERT INTO role (name, authority, createTime, updateTime) VALUES" +
|
@Insert("INSERT INTO user_role (name, authority, createTime, updateTime) VALUES" +
|
||||||
"('${name}', '${authority}', '${createTime}', '${updateTime}')")
|
"('${name}', '${authority}', '${createTime}', '${updateTime}')")
|
||||||
int add(Role role);
|
int add(Role role);
|
||||||
|
|
||||||
@Update(value = {" <script>" +
|
@Update(value = {" <script>" +
|
||||||
"UPDATE role " +
|
"UPDATE user_role " +
|
||||||
"SET updateTime='${updateTime}' " +
|
"SET updateTime='${updateTime}' " +
|
||||||
"<if test=\"name != null\">, name='${name}'</if>" +
|
"<if test=\"name != null\">, name='${name}'</if>" +
|
||||||
"<if test=\"authority != null\">, authority='${authority}'</if>" +
|
"<if test=\"authority != null\">, authority='${authority}'</if>" +
|
||||||
@ -24,12 +24,12 @@ public interface RoleMapper {
|
|||||||
" </script>"})
|
" </script>"})
|
||||||
int update(Role role);
|
int update(Role role);
|
||||||
|
|
||||||
@Delete("DELETE FROM role WHERE id != 1 and id=#{id}")
|
@Delete("DELETE FROM user_role WHERE id != 1 and id=#{id}")
|
||||||
int delete(int id);
|
int delete(int id);
|
||||||
|
|
||||||
@Select("select * FROM role WHERE id=#{id}")
|
@Select("select * FROM user_role WHERE id=#{id}")
|
||||||
Role selectById(int id);
|
Role selectById(int id);
|
||||||
|
|
||||||
@Select("select * FROM role")
|
@Select("select * FROM user_role")
|
||||||
List<Role> selectAll();
|
List<Role> selectAll();
|
||||||
}
|
}
|
||||||
|
@ -19,23 +19,12 @@ spring:
|
|||||||
# [可选] jdbc数据库配置, 项目使用sqlite作为数据库,一般不需要配置
|
# [可选] jdbc数据库配置, 项目使用sqlite作为数据库,一般不需要配置
|
||||||
datasource:
|
datasource:
|
||||||
# 使用mysql 打开23-28行注释, 删除29-36行
|
# 使用mysql 打开23-28行注释, 删除29-36行
|
||||||
# name: wvp
|
name: wvp
|
||||||
# url: jdbc:mysql://127.0.0.1:3306/wvp?useUnicode=true&characterEncoding=UTF8&rewriteBatchedStatements=true&allowMultiQueries=true
|
url: jdbc:mysql://127.0.0.1:3306/wvp?useUnicode=true&characterEncoding=UTF8&rewriteBatchedStatements=true&allowMultiQueries=true
|
||||||
# username:
|
|
||||||
# password:
|
|
||||||
# type: com.alibaba.druid.pool.DruidDataSource
|
|
||||||
# driver-class-name: com.mysql.cj.jdbc.Driver
|
|
||||||
name: eiot
|
|
||||||
url: jdbc:sqlite::resource:wvp.sqlite
|
|
||||||
username:
|
username:
|
||||||
password:
|
password:
|
||||||
type: com.alibaba.druid.pool.DruidDataSource
|
type: com.alibaba.druid.pool.DruidDataSource
|
||||||
driver-class-name: org.sqlite.JDBC
|
driver-class-name: com.mysql.cj.jdbc.Driver
|
||||||
journal_mode: WAL
|
|
||||||
synchronous: NORMAL
|
|
||||||
transaction_mode: IMMEDIATE
|
|
||||||
max-active: 1
|
|
||||||
min-idle: 1
|
|
||||||
|
|
||||||
# [可选] WVP监听的HTTP端口, 网页和接口调用都是这个端口
|
# [可选] WVP监听的HTTP端口, 网页和接口调用都是这个端口
|
||||||
server:
|
server:
|
||||||
|
@ -19,23 +19,12 @@ spring:
|
|||||||
# [可选] jdbc数据库配置, 项目使用sqlite作为数据库,一般不需要配置
|
# [可选] jdbc数据库配置, 项目使用sqlite作为数据库,一般不需要配置
|
||||||
datasource:
|
datasource:
|
||||||
# 使用mysql 打开23-28行注释, 删除29-36行
|
# 使用mysql 打开23-28行注释, 删除29-36行
|
||||||
# name: wvp
|
name: wvp
|
||||||
# url: jdbc:mysql://127.0.0.1:3306/wvp?useUnicode=true&characterEncoding=UTF8&rewriteBatchedStatements=true&allowMultiQueries=true
|
url: jdbc:mysql://127.0.0.1:3306/wvp?useUnicode=true&characterEncoding=UTF8&rewriteBatchedStatements=true&allowMultiQueries=true
|
||||||
# username:
|
username: root
|
||||||
# password:
|
password: root
|
||||||
# type: com.alibaba.druid.pool.DruidDataSource
|
type: com.alibaba.druid.pool.DruidDataSource
|
||||||
# driver-class-name: com.mysql.cj.jdbc.Driver
|
driver-class-name: com.mysql.cj.jdbc.Driver
|
||||||
name: eiot
|
|
||||||
url: jdbc:sqlite::resource:wvp.sqlite
|
|
||||||
username:
|
|
||||||
password:
|
|
||||||
type: com.alibaba.druid.pool.DruidDataSource
|
|
||||||
driver-class-name: org.sqlite.JDBC
|
|
||||||
journal_mode: WAL
|
|
||||||
synchronous: NORMAL
|
|
||||||
transaction_mode: IMMEDIATE
|
|
||||||
max-active: 1
|
|
||||||
min-idle: 1
|
|
||||||
|
|
||||||
# [可选] WVP监听的HTTP端口, 网页和接口调用都是这个端口
|
# [可选] WVP监听的HTTP端口, 网页和接口调用都是这个端口
|
||||||
server:
|
server:
|
||||||
|
Binary file not shown.
Loading…
Reference in New Issue
Block a user