-
Notifications
You must be signed in to change notification settings - Fork 25
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
13 changed files
with
47 additions
and
28 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
3 changes: 1 addition & 2 deletions
3
src/main/java/com/pig4cloud/plugin/impl/dm/ConfigInfoTagMapperByDm.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
33 changes: 33 additions & 0 deletions
33
src/main/java/com/pig4cloud/plugin/impl/dm/DmAbstractMapper.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
package com.pig4cloud.plugin.impl.dm; | ||
|
||
import com.alibaba.nacos.plugin.datasource.mapper.AbstractMapper; | ||
import com.pig4cloud.plugin.constants.DataSourceConstant; | ||
|
||
/** | ||
* DM 抽象映射器 | ||
* | ||
* @author lengleng | ||
* @date 2024/08/25 | ||
*/ | ||
public abstract class DmAbstractMapper extends AbstractMapper { | ||
|
||
/** | ||
* 获取数据源 | ||
* @return {@link String } | ||
*/ | ||
@Override | ||
public String getDataSource() { | ||
return DataSourceConstant.DM; | ||
} | ||
|
||
/** | ||
* get 函数 | ||
* @param functionName 函数名称 | ||
* @return {@link String } | ||
*/ | ||
@Override | ||
public String getFunction(String functionName) { | ||
return "NOW()"; | ||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
9 changes: 1 addition & 8 deletions
9
src/main/java/com/pig4cloud/plugin/impl/dm/TenantInfoMapperByDm.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,20 +1,13 @@ | ||
package com.pig4cloud.plugin.impl.dm; | ||
|
||
import com.alibaba.nacos.plugin.datasource.constants.TableConstant; | ||
import com.alibaba.nacos.plugin.datasource.mapper.AbstractMapper; | ||
import com.alibaba.nacos.plugin.datasource.mapper.TenantInfoMapper; | ||
import com.pig4cloud.plugin.constants.DataSourceConstant; | ||
|
||
public class TenantInfoMapperByDm extends AbstractMapper implements TenantInfoMapper { | ||
public class TenantInfoMapperByDm extends DmAbstractMapper implements TenantInfoMapper { | ||
|
||
@Override | ||
public String getTableName() { | ||
return TableConstant.TENANT_INFO; | ||
} | ||
|
||
@Override | ||
public String getDataSource() { | ||
return DataSourceConstant.DM; | ||
} | ||
|
||
} |