fix: 数据源错误信息

This commit is contained in:
taojinlong 2022-04-28 16:17:37 +08:00
parent 0847e5e15a
commit e5e370b9f3
2 changed files with 3 additions and 7 deletions

View File

@ -16,12 +16,8 @@ import io.dataease.provider.ProviderFactory;
import org.apache.commons.lang3.StringUtils;
import org.springframework.stereotype.Service;
import javax.annotation.PostConstruct;
import java.beans.PropertyVetoException;
import java.io.File;
import java.io.IOException;
import java.lang.reflect.Method;
import java.net.URL;
import java.sql.*;
import java.util.*;
@ -287,9 +283,9 @@ public class JdbcProvider extends DefaultJdbcProvider {
}
} catch (SQLException e) {
io.dataease.plugins.common.exception.DataEaseException.throwException("SQL ERROR" + e.getMessage());
DataEaseException.throwException("SQL ERROR" + e.getMessage());
} catch (Exception e) {
io.dataease.plugins.common.exception.DataEaseException.throwException("Data source connection exception: " + e.getMessage());
DataEaseException.throwException("Data source connection exception: " + e.getMessage());
}
return list;
}

View File

@ -495,7 +495,7 @@ export default {
changeType() {
for (let i = 0; i < this.dsTypes.length; i++) {
if (this.dsTypes[i].type === this.form.type) {
if(row.type !== 'api'){
if(this.form.type !== 'api'){
this.form.configuration.extraParams = this.dsTypes[i].extraParams
}
this.datasourceType = this.dsTypes[i]