提交 1dcdff50 authored 作者: wangjiahao's avatar wangjiahao

Merge remote-tracking branch 'origin/main' into main

FROM registry.fit2cloud.com/fit2cloud3/fabric8-java-alpine-openjdk8-jre FROM registry.cn-qingdao.aliyuncs.com/fit2cloud3/fabric8-java-alpine-openjdk8-jre
ARG IMAGE_TAG ARG IMAGE_TAG
......
...@@ -60,10 +60,18 @@ public class F2CRealm extends AuthorizingRealm { ...@@ -60,10 +60,18 @@ public class F2CRealm extends AuthorizingRealm {
CacheUtils.get("lic_info", "lic"); CacheUtils.get("lic_info", "lic");
}catch (Exception e) { }catch (Exception e) {
LogUtil.error(e); LogUtil.error(e);
throw new AuthenticationException("lic error");
} }
String token = (String) auth.getCredentials(); TokenInfo tokenInfo = null;
// 解密获得username,用于和数据库进行对比 String token = null;
TokenInfo tokenInfo = JWTUtils.tokenInfoByToken(token); try {
token = (String) auth.getCredentials();
// 解密获得username,用于和数据库进行对比
tokenInfo = JWTUtils.tokenInfoByToken(token);
}catch (Exception e) {
throw new AuthenticationException(e);
}
Long userId = tokenInfo.getUserId(); Long userId = tokenInfo.getUserId();
String username = tokenInfo.getUsername(); String username = tokenInfo.getUsername();
if (username == null) { if (username == null) {
......
...@@ -25,6 +25,8 @@ public class DatasetTable implements Serializable { ...@@ -25,6 +25,8 @@ public class DatasetTable implements Serializable {
private String syncStatus; private String syncStatus;
private Long lastUpdateTime;
private String info; private String info;
private static final long serialVersionUID = 1L; private static final long serialVersionUID = 1L;
......
...@@ -783,6 +783,66 @@ public class DatasetTableExample { ...@@ -783,6 +783,66 @@ public class DatasetTableExample {
addCriterion("sync_status not between", value1, value2, "syncStatus"); addCriterion("sync_status not between", value1, value2, "syncStatus");
return (Criteria) this; return (Criteria) this;
} }
public Criteria andLastUpdateTimeIsNull() {
addCriterion("last_update_time is null");
return (Criteria) this;
}
public Criteria andLastUpdateTimeIsNotNull() {
addCriterion("last_update_time is not null");
return (Criteria) this;
}
public Criteria andLastUpdateTimeEqualTo(Long value) {
addCriterion("last_update_time =", value, "lastUpdateTime");
return (Criteria) this;
}
public Criteria andLastUpdateTimeNotEqualTo(Long value) {
addCriterion("last_update_time <>", value, "lastUpdateTime");
return (Criteria) this;
}
public Criteria andLastUpdateTimeGreaterThan(Long value) {
addCriterion("last_update_time >", value, "lastUpdateTime");
return (Criteria) this;
}
public Criteria andLastUpdateTimeGreaterThanOrEqualTo(Long value) {
addCriterion("last_update_time >=", value, "lastUpdateTime");
return (Criteria) this;
}
public Criteria andLastUpdateTimeLessThan(Long value) {
addCriterion("last_update_time <", value, "lastUpdateTime");
return (Criteria) this;
}
public Criteria andLastUpdateTimeLessThanOrEqualTo(Long value) {
addCriterion("last_update_time <=", value, "lastUpdateTime");
return (Criteria) this;
}
public Criteria andLastUpdateTimeIn(List<Long> values) {
addCriterion("last_update_time in", values, "lastUpdateTime");
return (Criteria) this;
}
public Criteria andLastUpdateTimeNotIn(List<Long> values) {
addCriterion("last_update_time not in", values, "lastUpdateTime");
return (Criteria) this;
}
public Criteria andLastUpdateTimeBetween(Long value1, Long value2) {
addCriterion("last_update_time between", value1, value2, "lastUpdateTime");
return (Criteria) this;
}
public Criteria andLastUpdateTimeNotBetween(Long value1, Long value2) {
addCriterion("last_update_time not between", value1, value2, "lastUpdateTime");
return (Criteria) this;
}
} }
public static class Criteria extends GeneratedCriteria { public static class Criteria extends GeneratedCriteria {
......
...@@ -12,6 +12,7 @@ ...@@ -12,6 +12,7 @@
<result column="create_time" jdbcType="BIGINT" property="createTime" /> <result column="create_time" jdbcType="BIGINT" property="createTime" />
<result column="qrtz_instance" jdbcType="VARCHAR" property="qrtzInstance" /> <result column="qrtz_instance" jdbcType="VARCHAR" property="qrtzInstance" />
<result column="sync_status" jdbcType="VARCHAR" property="syncStatus" /> <result column="sync_status" jdbcType="VARCHAR" property="syncStatus" />
<result column="last_update_time" jdbcType="BIGINT" property="lastUpdateTime" />
</resultMap> </resultMap>
<resultMap extends="BaseResultMap" id="ResultMapWithBLOBs" type="io.dataease.base.domain.DatasetTable"> <resultMap extends="BaseResultMap" id="ResultMapWithBLOBs" type="io.dataease.base.domain.DatasetTable">
<result column="info" jdbcType="LONGVARCHAR" property="info" /> <result column="info" jdbcType="LONGVARCHAR" property="info" />
...@@ -76,7 +77,7 @@ ...@@ -76,7 +77,7 @@
</sql> </sql>
<sql id="Base_Column_List"> <sql id="Base_Column_List">
id, `name`, scene_id, data_source_id, `type`, `mode`, create_by, create_time, qrtz_instance, id, `name`, scene_id, data_source_id, `type`, `mode`, create_by, create_time, qrtz_instance,
sync_status sync_status, last_update_time
</sql> </sql>
<sql id="Blob_Column_List"> <sql id="Blob_Column_List">
info info
...@@ -133,11 +134,13 @@ ...@@ -133,11 +134,13 @@
insert into dataset_table (id, `name`, scene_id, insert into dataset_table (id, `name`, scene_id,
data_source_id, `type`, `mode`, data_source_id, `type`, `mode`,
create_by, create_time, qrtz_instance, create_by, create_time, qrtz_instance,
sync_status, info) sync_status, last_update_time, info
)
values (#{id,jdbcType=VARCHAR}, #{name,jdbcType=VARCHAR}, #{sceneId,jdbcType=VARCHAR}, values (#{id,jdbcType=VARCHAR}, #{name,jdbcType=VARCHAR}, #{sceneId,jdbcType=VARCHAR},
#{dataSourceId,jdbcType=VARCHAR}, #{type,jdbcType=VARCHAR}, #{mode,jdbcType=INTEGER}, #{dataSourceId,jdbcType=VARCHAR}, #{type,jdbcType=VARCHAR}, #{mode,jdbcType=INTEGER},
#{createBy,jdbcType=VARCHAR}, #{createTime,jdbcType=BIGINT}, #{qrtzInstance,jdbcType=VARCHAR}, #{createBy,jdbcType=VARCHAR}, #{createTime,jdbcType=BIGINT}, #{qrtzInstance,jdbcType=VARCHAR},
#{syncStatus,jdbcType=VARCHAR}, #{info,jdbcType=LONGVARCHAR}) #{syncStatus,jdbcType=VARCHAR}, #{lastUpdateTime,jdbcType=BIGINT}, #{info,jdbcType=LONGVARCHAR}
)
</insert> </insert>
<insert id="insertSelective" parameterType="io.dataease.base.domain.DatasetTable"> <insert id="insertSelective" parameterType="io.dataease.base.domain.DatasetTable">
insert into dataset_table insert into dataset_table
...@@ -172,6 +175,9 @@ ...@@ -172,6 +175,9 @@
<if test="syncStatus != null"> <if test="syncStatus != null">
sync_status, sync_status,
</if> </if>
<if test="lastUpdateTime != null">
last_update_time,
</if>
<if test="info != null"> <if test="info != null">
info, info,
</if> </if>
...@@ -207,6 +213,9 @@ ...@@ -207,6 +213,9 @@
<if test="syncStatus != null"> <if test="syncStatus != null">
#{syncStatus,jdbcType=VARCHAR}, #{syncStatus,jdbcType=VARCHAR},
</if> </if>
<if test="lastUpdateTime != null">
#{lastUpdateTime,jdbcType=BIGINT},
</if>
<if test="info != null"> <if test="info != null">
#{info,jdbcType=LONGVARCHAR}, #{info,jdbcType=LONGVARCHAR},
</if> </if>
...@@ -251,6 +260,9 @@ ...@@ -251,6 +260,9 @@
<if test="record.syncStatus != null"> <if test="record.syncStatus != null">
sync_status = #{record.syncStatus,jdbcType=VARCHAR}, sync_status = #{record.syncStatus,jdbcType=VARCHAR},
</if> </if>
<if test="record.lastUpdateTime != null">
last_update_time = #{record.lastUpdateTime,jdbcType=BIGINT},
</if>
<if test="record.info != null"> <if test="record.info != null">
info = #{record.info,jdbcType=LONGVARCHAR}, info = #{record.info,jdbcType=LONGVARCHAR},
</if> </if>
...@@ -271,6 +283,7 @@ ...@@ -271,6 +283,7 @@
create_time = #{record.createTime,jdbcType=BIGINT}, create_time = #{record.createTime,jdbcType=BIGINT},
qrtz_instance = #{record.qrtzInstance,jdbcType=VARCHAR}, qrtz_instance = #{record.qrtzInstance,jdbcType=VARCHAR},
sync_status = #{record.syncStatus,jdbcType=VARCHAR}, sync_status = #{record.syncStatus,jdbcType=VARCHAR},
last_update_time = #{record.lastUpdateTime,jdbcType=BIGINT},
info = #{record.info,jdbcType=LONGVARCHAR} info = #{record.info,jdbcType=LONGVARCHAR}
<if test="_parameter != null"> <if test="_parameter != null">
<include refid="Update_By_Example_Where_Clause" /> <include refid="Update_By_Example_Where_Clause" />
...@@ -287,7 +300,8 @@ ...@@ -287,7 +300,8 @@
create_by = #{record.createBy,jdbcType=VARCHAR}, create_by = #{record.createBy,jdbcType=VARCHAR},
create_time = #{record.createTime,jdbcType=BIGINT}, create_time = #{record.createTime,jdbcType=BIGINT},
qrtz_instance = #{record.qrtzInstance,jdbcType=VARCHAR}, qrtz_instance = #{record.qrtzInstance,jdbcType=VARCHAR},
sync_status = #{record.syncStatus,jdbcType=VARCHAR} sync_status = #{record.syncStatus,jdbcType=VARCHAR},
last_update_time = #{record.lastUpdateTime,jdbcType=BIGINT}
<if test="_parameter != null"> <if test="_parameter != null">
<include refid="Update_By_Example_Where_Clause" /> <include refid="Update_By_Example_Where_Clause" />
</if> </if>
...@@ -322,6 +336,9 @@ ...@@ -322,6 +336,9 @@
<if test="syncStatus != null"> <if test="syncStatus != null">
sync_status = #{syncStatus,jdbcType=VARCHAR}, sync_status = #{syncStatus,jdbcType=VARCHAR},
</if> </if>
<if test="lastUpdateTime != null">
last_update_time = #{lastUpdateTime,jdbcType=BIGINT},
</if>
<if test="info != null"> <if test="info != null">
info = #{info,jdbcType=LONGVARCHAR}, info = #{info,jdbcType=LONGVARCHAR},
</if> </if>
...@@ -339,6 +356,7 @@ ...@@ -339,6 +356,7 @@
create_time = #{createTime,jdbcType=BIGINT}, create_time = #{createTime,jdbcType=BIGINT},
qrtz_instance = #{qrtzInstance,jdbcType=VARCHAR}, qrtz_instance = #{qrtzInstance,jdbcType=VARCHAR},
sync_status = #{syncStatus,jdbcType=VARCHAR}, sync_status = #{syncStatus,jdbcType=VARCHAR},
last_update_time = #{lastUpdateTime,jdbcType=BIGINT},
info = #{info,jdbcType=LONGVARCHAR} info = #{info,jdbcType=LONGVARCHAR}
where id = #{id,jdbcType=VARCHAR} where id = #{id,jdbcType=VARCHAR}
</update> </update>
...@@ -352,7 +370,8 @@ ...@@ -352,7 +370,8 @@
create_by = #{createBy,jdbcType=VARCHAR}, create_by = #{createBy,jdbcType=VARCHAR},
create_time = #{createTime,jdbcType=BIGINT}, create_time = #{createTime,jdbcType=BIGINT},
qrtz_instance = #{qrtzInstance,jdbcType=VARCHAR}, qrtz_instance = #{qrtzInstance,jdbcType=VARCHAR},
sync_status = #{syncStatus,jdbcType=VARCHAR} sync_status = #{syncStatus,jdbcType=VARCHAR},
last_update_time = #{lastUpdateTime,jdbcType=BIGINT}
where id = #{id,jdbcType=VARCHAR} where id = #{id,jdbcType=VARCHAR}
</update> </update>
</mapper> </mapper>
\ No newline at end of file
...@@ -1055,6 +1055,11 @@ public class DataSetTableService { ...@@ -1055,6 +1055,11 @@ public class DataSetTableService {
DatasetTableTaskLogExample datasetTableTaskLogExample = new DatasetTableTaskLogExample(); DatasetTableTaskLogExample datasetTableTaskLogExample = new DatasetTableTaskLogExample();
datasetTableTaskLogExample.createCriteria().andStatusEqualTo(JobStatus.Underway.name()).andTableIdIn(jobStoppeddDatasetTables.stream().map(DatasetTable::getId).collect(Collectors.toList())); datasetTableTaskLogExample.createCriteria().andStatusEqualTo(JobStatus.Underway.name()).andTableIdIn(jobStoppeddDatasetTables.stream().map(DatasetTable::getId).collect(Collectors.toList()));
datasetTableTaskLogMapper.updateByExampleSelective(datasetTableTaskLog, datasetTableTaskLogExample); datasetTableTaskLogMapper.updateByExampleSelective(datasetTableTaskLog, datasetTableTaskLogExample);
for (DatasetTable jobStoppeddDatasetTable : jobStoppeddDatasetTables) {
extractDataService.deleteFile("all_scope", jobStoppeddDatasetTable.getId());
extractDataService.deleteFile("incremental_add", jobStoppeddDatasetTable.getId());
extractDataService.deleteFile("incremental_delete", jobStoppeddDatasetTable.getId());
}
} }
} }
ALTER TABLE `dataset_table` ADD COLUMN `last_update_time` BIGINT(13) NULL DEFAULT 0 AFTER `sync_status`;
<template>
<de-complex-operator v-model="operator" :label="label" :operators="operators" :size="configSize">
<el-input v-model="value" :placeholder="$t('fu.search_bar.please_input')" :size="configSize" v-bind="$attrs" />
</de-complex-operator>
</template>
<script>
import { ComplexCondition } from 'fit2cloud-ui/src/components/search-bar/model'
// import mixins from 'fit2cloud-ui/src/components/search-bar/complex-components/mixins'
import DeComplexOperator from './DeComplexOperator.vue'
import Cookies from 'js-cookie'
export default {
name: 'DeComplexInput',
components: { DeComplexOperator },
// mixins: [mixins],
props: {
field: String,
label: String,
defaultOperator: {
type: String,
default: 'like'
}
},
data() {
return {
operator: this.defaultOperator,
value: '',
operators: [{
label: 'fu.search_bar.like',
value: 'like'
}, {
label: 'fu.search_bar.eq',
value: 'eq'
}]
}
},
computed: {
configSize() {
return Cookies.get('size') || 'medium'
}
},
methods: {
getCondition() {
if (!this.value) return
const { field, label, operator, operatorLabel, value } = this
return new ComplexCondition({ field, label, operator, operatorLabel, value })
},
init() {
this.value = ''
}
}
}
</script>
<template>
<div class="fu-operator-component">
<div :class="['fu-operator-component__label', 'fu-operator-component__label--' + configSize]">
{{ label }}
</div>
<div class="fu-operator-component__operator">
<el-select
v-model="value"
class="search-operator"
:placeholder="$t('fu.search_bar.please_select')"
:size="configSize"
@change="change"
@input="change"
>
<el-option v-for="o in operators" :key="o.value" :label="$t(o.label)" :value="o.value" />
</el-select>
</div>
<div class="fu-operator-component__value">
<slot />
</div>
</div>
</template>
<script>
import Cookies from 'js-cookie'
export default {
name: 'DeComplexOperator',
model: {
prop: 'operator',
event: 'change'
},
props: {
label: String,
operator: String,
operators: Array
},
data() {
return {
value: this.operator
}
},
computed: {
configSize() {
return Cookies.get('size') || 'medium'
}
},
watch: {
operator: function(v) {
this.value = v
}
},
methods: {
change(value) {
this.$emit('change', value)
}
}
}
</script>
<style scoped>
</style>
...@@ -20,6 +20,7 @@ import widgets from '@/components/widget' ...@@ -20,6 +20,7 @@ import widgets from '@/components/widget'
import Treeselect from '@riophae/vue-treeselect' import Treeselect from '@riophae/vue-treeselect'
import '@riophae/vue-treeselect/dist/vue-treeselect.css' import '@riophae/vue-treeselect/dist/vue-treeselect.css'
import './utils/dialog' import './utils/dialog'
import DeComplexInput from '@/components/business/condition-table/DeComplexInput'
import '@/components/canvas/custom-component' // 注册自定义组件 import '@/components/canvas/custom-component' // 注册自定义组件
Vue.config.productionTip = false Vue.config.productionTip = false
...@@ -69,6 +70,7 @@ Vue.use(filter) ...@@ -69,6 +70,7 @@ Vue.use(filter)
Vue.use(directives) Vue.use(directives)
Vue.use(message) Vue.use(message)
Vue.component('Treeselect', Treeselect) Vue.component('Treeselect', Treeselect)
Vue.component('DeComplexInput', DeComplexInput)
Vue.config.productionTip = false Vue.config.productionTip = false
Vue.prototype.hasDataPermission = function(pTarget, pSource) { Vue.prototype.hasDataPermission = function(pTarget, pSource) {
......
...@@ -162,7 +162,6 @@ ...@@ -162,7 +162,6 @@
<script> <script>
import LayoutContent from '@/components/business/LayoutContent' import LayoutContent from '@/components/business/LayoutContent'
import ComplexTable from '@/components/business/complex-table' import ComplexTable from '@/components/business/complex-table'
// import { checkPermission } from '@/utils/permission' // import { checkPermission } from '@/utils/permission'
import { formatCondition, formatQuickCondition, addOrder, formatOrders } from '@/utils/index' import { formatCondition, formatQuickCondition, addOrder, formatOrders } from '@/utils/index'
import { PHONE_REGEX } from '@/utils/validate' import { PHONE_REGEX } from '@/utils/validate'
...@@ -199,7 +198,7 @@ export default { ...@@ -199,7 +198,7 @@ export default {
useComplexSearch: true, useComplexSearch: true,
quickPlaceholder: '按姓名搜索', quickPlaceholder: '按姓名搜索',
components: [ components: [
{ field: 'nick_name', label: '姓名', component: 'FuComplexInput' }, { field: 'nick_name', label: '姓名', component: 'DeComplexInput' },
{ {
field: 'u.enabled', field: 'u.enabled',
label: '状态', label: '状态',
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论