master
parent
aef7c4d74e
commit
e24c38c652
|
@ -2,7 +2,6 @@ package com.muyu.gen.mapper;
|
||||||
|
|
||||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||||
import com.muyu.gen.domain.GenTableColumn;
|
import com.muyu.gen.domain.GenTableColumn;
|
||||||
import org.apache.ibatis.annotations.Param;
|
|
||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
|
@ -19,7 +18,7 @@ public interface GenTableColumnMapper extends BaseMapper<GenTableColumn> {
|
||||||
*
|
*
|
||||||
* @return 列信息
|
* @return 列信息
|
||||||
*/
|
*/
|
||||||
List<GenTableColumn> selectDbTableColumnsByName (@Param("tableName") String tableName);
|
List<GenTableColumn> selectDbTableColumnsByName (String tableName);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 查询业务字段列表
|
* 查询业务字段列表
|
||||||
|
@ -28,7 +27,7 @@ public interface GenTableColumnMapper extends BaseMapper<GenTableColumn> {
|
||||||
*
|
*
|
||||||
* @return 业务字段集合
|
* @return 业务字段集合
|
||||||
*/
|
*/
|
||||||
List<GenTableColumn> selectGenTableColumnListByTableId (@Param("tableId") Long tableId);
|
List<GenTableColumn> selectGenTableColumnListByTableId (Long tableId);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 新增业务字段
|
* 新增业务字段
|
||||||
|
@ -55,7 +54,7 @@ public interface GenTableColumnMapper extends BaseMapper<GenTableColumn> {
|
||||||
*
|
*
|
||||||
* @return 结果
|
* @return 结果
|
||||||
*/
|
*/
|
||||||
int deleteGenTableColumns (@Param("genTableColumns") List<GenTableColumn> genTableColumns);
|
int deleteGenTableColumns (List<GenTableColumn> genTableColumns);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 批量删除业务字段
|
* 批量删除业务字段
|
||||||
|
@ -64,5 +63,5 @@ public interface GenTableColumnMapper extends BaseMapper<GenTableColumn> {
|
||||||
*
|
*
|
||||||
* @return 结果
|
* @return 结果
|
||||||
*/
|
*/
|
||||||
int deleteGenTableColumnByIds (@Param("ids") Long[] ids);
|
int deleteGenTableColumnByIds (Long[] ids);
|
||||||
}
|
}
|
||||||
|
|
|
@ -2,7 +2,6 @@ package com.muyu.gen.mapper;
|
||||||
|
|
||||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||||
import com.muyu.gen.domain.GenTable;
|
import com.muyu.gen.domain.GenTable;
|
||||||
import org.apache.ibatis.annotations.Param;
|
|
||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
|
@ -37,7 +36,7 @@ public interface GenTableMapper extends BaseMapper<GenTable> {
|
||||||
*
|
*
|
||||||
* @return 数据库表集合
|
* @return 数据库表集合
|
||||||
*/
|
*/
|
||||||
List<GenTable> selectDbTableListByNames (@Param("tableNames") String[] tableNames);
|
List<GenTable> selectDbTableListByNames (String[] tableNames);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 查询所有表信息
|
* 查询所有表信息
|
||||||
|
@ -53,7 +52,7 @@ public interface GenTableMapper extends BaseMapper<GenTable> {
|
||||||
*
|
*
|
||||||
* @return 业务信息
|
* @return 业务信息
|
||||||
*/
|
*/
|
||||||
GenTable selectGenTableById (@Param("id") Long id);
|
GenTable selectGenTableById (Long id);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 查询表名称业务信息
|
* 查询表名称业务信息
|
||||||
|
@ -62,7 +61,7 @@ public interface GenTableMapper extends BaseMapper<GenTable> {
|
||||||
*
|
*
|
||||||
* @return 业务信息
|
* @return 业务信息
|
||||||
*/
|
*/
|
||||||
GenTable selectGenTableByName (@Param("tableName") String tableName);
|
GenTable selectGenTableByName (String tableName);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 新增业务
|
* 新增业务
|
||||||
|
@ -89,5 +88,5 @@ public interface GenTableMapper extends BaseMapper<GenTable> {
|
||||||
*
|
*
|
||||||
* @return 结果
|
* @return 结果
|
||||||
*/
|
*/
|
||||||
int deleteGenTableByIds (@Param("ids") Long[] ids);
|
int deleteGenTableByIds (Long[] ids);
|
||||||
}
|
}
|
||||||
|
|
|
@ -142,14 +142,14 @@
|
||||||
|
|
||||||
<delete id="deleteGenTableColumnByIds" parameterType="Long">
|
<delete id="deleteGenTableColumnByIds" parameterType="Long">
|
||||||
delete from gen_table_column where table_id in
|
delete from gen_table_column where table_id in
|
||||||
<foreach collection="ids" item="tableId" open="(" separator="," close=")">
|
<foreach collection="array" item="tableId" open="(" separator="," close=")">
|
||||||
#{tableId}
|
#{tableId}
|
||||||
</foreach>
|
</foreach>
|
||||||
</delete>
|
</delete>
|
||||||
|
|
||||||
<delete id="deleteGenTableColumns">
|
<delete id="deleteGenTableColumns">
|
||||||
delete from gen_table_column where column_id in
|
delete from gen_table_column where column_id in
|
||||||
<foreach collection="genTableColumns" item="item" open="(" separator="," close=")">
|
<foreach collection="list" item="item" open="(" separator="," close=")">
|
||||||
#{item.columnId}
|
#{item.columnId}
|
||||||
</foreach>
|
</foreach>
|
||||||
</delete>
|
</delete>
|
||||||
|
|
|
@ -119,7 +119,7 @@
|
||||||
select table_name, table_comment, create_time, update_time from information_schema.tables
|
select table_name, table_comment, create_time, update_time from information_schema.tables
|
||||||
where table_name NOT LIKE 'qrtz_%' and table_name NOT LIKE 'gen_%' and table_schema = (select database())
|
where table_name NOT LIKE 'qrtz_%' and table_name NOT LIKE 'gen_%' and table_schema = (select database())
|
||||||
and table_name in
|
and table_name in
|
||||||
<foreach collection="tableNames" item="name" open="(" separator="," close=")">
|
<foreach collection="array" item="name" open="(" separator="," close=")">
|
||||||
#{name}
|
#{name}
|
||||||
</foreach>
|
</foreach>
|
||||||
</select>
|
</select>
|
||||||
|
@ -309,7 +309,7 @@
|
||||||
|
|
||||||
<delete id="deleteGenTableByIds" parameterType="Long">
|
<delete id="deleteGenTableByIds" parameterType="Long">
|
||||||
delete from gen_table where table_id in
|
delete from gen_table where table_id in
|
||||||
<foreach collection="ids" item="tableId" open="(" separator="," close=")">
|
<foreach collection="array" item="tableId" open="(" separator="," close=")">
|
||||||
#{tableId}
|
#{tableId}
|
||||||
</foreach>
|
</foreach>
|
||||||
</delete>
|
</delete>
|
||||||
|
|
Loading…
Reference in New Issue