forked from github/dataease
Merge remote-tracking branch 'origin/main' into main
This commit is contained in:
commit
cb1c4c0ba7
@ -21,6 +21,8 @@ public class DatasetTable implements Serializable {
|
||||
|
||||
private Long createTime;
|
||||
|
||||
private String syncStatus;
|
||||
|
||||
private String info;
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
@ -643,6 +643,76 @@ public class DatasetTableExample {
|
||||
addCriterion("create_time not between", value1, value2, "createTime");
|
||||
return (Criteria) this;
|
||||
}
|
||||
|
||||
public Criteria andSyncStatusIsNull() {
|
||||
addCriterion("sync_status is null");
|
||||
return (Criteria) this;
|
||||
}
|
||||
|
||||
public Criteria andSyncStatusIsNotNull() {
|
||||
addCriterion("sync_status is not null");
|
||||
return (Criteria) this;
|
||||
}
|
||||
|
||||
public Criteria andSyncStatusEqualTo(String value) {
|
||||
addCriterion("sync_status =", value, "syncStatus");
|
||||
return (Criteria) this;
|
||||
}
|
||||
|
||||
public Criteria andSyncStatusNotEqualTo(String value) {
|
||||
addCriterion("sync_status <>", value, "syncStatus");
|
||||
return (Criteria) this;
|
||||
}
|
||||
|
||||
public Criteria andSyncStatusGreaterThan(String value) {
|
||||
addCriterion("sync_status >", value, "syncStatus");
|
||||
return (Criteria) this;
|
||||
}
|
||||
|
||||
public Criteria andSyncStatusGreaterThanOrEqualTo(String value) {
|
||||
addCriterion("sync_status >=", value, "syncStatus");
|
||||
return (Criteria) this;
|
||||
}
|
||||
|
||||
public Criteria andSyncStatusLessThan(String value) {
|
||||
addCriterion("sync_status <", value, "syncStatus");
|
||||
return (Criteria) this;
|
||||
}
|
||||
|
||||
public Criteria andSyncStatusLessThanOrEqualTo(String value) {
|
||||
addCriterion("sync_status <=", value, "syncStatus");
|
||||
return (Criteria) this;
|
||||
}
|
||||
|
||||
public Criteria andSyncStatusLike(String value) {
|
||||
addCriterion("sync_status like", value, "syncStatus");
|
||||
return (Criteria) this;
|
||||
}
|
||||
|
||||
public Criteria andSyncStatusNotLike(String value) {
|
||||
addCriterion("sync_status not like", value, "syncStatus");
|
||||
return (Criteria) this;
|
||||
}
|
||||
|
||||
public Criteria andSyncStatusIn(List<String> values) {
|
||||
addCriterion("sync_status in", values, "syncStatus");
|
||||
return (Criteria) this;
|
||||
}
|
||||
|
||||
public Criteria andSyncStatusNotIn(List<String> values) {
|
||||
addCriterion("sync_status not in", values, "syncStatus");
|
||||
return (Criteria) this;
|
||||
}
|
||||
|
||||
public Criteria andSyncStatusBetween(String value1, String value2) {
|
||||
addCriterion("sync_status between", value1, value2, "syncStatus");
|
||||
return (Criteria) this;
|
||||
}
|
||||
|
||||
public Criteria andSyncStatusNotBetween(String value1, String value2) {
|
||||
addCriterion("sync_status not between", value1, value2, "syncStatus");
|
||||
return (Criteria) this;
|
||||
}
|
||||
}
|
||||
|
||||
public static class Criteria extends GeneratedCriteria {
|
||||
|
@ -10,6 +10,7 @@
|
||||
<result column="mode" jdbcType="INTEGER" property="mode" />
|
||||
<result column="create_by" jdbcType="VARCHAR" property="createBy" />
|
||||
<result column="create_time" jdbcType="BIGINT" property="createTime" />
|
||||
<result column="sync_status" jdbcType="VARCHAR" property="syncStatus" />
|
||||
</resultMap>
|
||||
<resultMap extends="BaseResultMap" id="ResultMapWithBLOBs" type="io.dataease.base.domain.DatasetTable">
|
||||
<result column="info" jdbcType="LONGVARCHAR" property="info" />
|
||||
@ -73,7 +74,7 @@
|
||||
</where>
|
||||
</sql>
|
||||
<sql id="Base_Column_List">
|
||||
id, `name`, scene_id, data_source_id, `type`, `mode`, create_by, create_time
|
||||
id, `name`, scene_id, data_source_id, `type`, `mode`, create_by, create_time, sync_status
|
||||
</sql>
|
||||
<sql id="Blob_Column_List">
|
||||
info
|
||||
@ -129,12 +130,12 @@
|
||||
<insert id="insert" parameterType="io.dataease.base.domain.DatasetTable">
|
||||
insert into dataset_table (id, `name`, scene_id,
|
||||
data_source_id, `type`, `mode`,
|
||||
create_by, create_time, info
|
||||
)
|
||||
create_by, create_time, sync_status,
|
||||
info)
|
||||
values (#{id,jdbcType=VARCHAR}, #{name,jdbcType=VARCHAR}, #{sceneId,jdbcType=VARCHAR},
|
||||
#{dataSourceId,jdbcType=VARCHAR}, #{type,jdbcType=VARCHAR}, #{mode,jdbcType=INTEGER},
|
||||
#{createBy,jdbcType=VARCHAR}, #{createTime,jdbcType=BIGINT}, #{info,jdbcType=LONGVARCHAR}
|
||||
)
|
||||
#{createBy,jdbcType=VARCHAR}, #{createTime,jdbcType=BIGINT}, #{syncStatus,jdbcType=VARCHAR},
|
||||
#{info,jdbcType=LONGVARCHAR})
|
||||
</insert>
|
||||
<insert id="insertSelective" parameterType="io.dataease.base.domain.DatasetTable">
|
||||
insert into dataset_table
|
||||
@ -163,6 +164,9 @@
|
||||
<if test="createTime != null">
|
||||
create_time,
|
||||
</if>
|
||||
<if test="syncStatus != null">
|
||||
sync_status,
|
||||
</if>
|
||||
<if test="info != null">
|
||||
info,
|
||||
</if>
|
||||
@ -192,6 +196,9 @@
|
||||
<if test="createTime != null">
|
||||
#{createTime,jdbcType=BIGINT},
|
||||
</if>
|
||||
<if test="syncStatus != null">
|
||||
#{syncStatus,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="info != null">
|
||||
#{info,jdbcType=LONGVARCHAR},
|
||||
</if>
|
||||
@ -230,6 +237,9 @@
|
||||
<if test="record.createTime != null">
|
||||
create_time = #{record.createTime,jdbcType=BIGINT},
|
||||
</if>
|
||||
<if test="record.syncStatus != null">
|
||||
sync_status = #{record.syncStatus,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="record.info != null">
|
||||
info = #{record.info,jdbcType=LONGVARCHAR},
|
||||
</if>
|
||||
@ -248,6 +258,7 @@
|
||||
`mode` = #{record.mode,jdbcType=INTEGER},
|
||||
create_by = #{record.createBy,jdbcType=VARCHAR},
|
||||
create_time = #{record.createTime,jdbcType=BIGINT},
|
||||
sync_status = #{record.syncStatus,jdbcType=VARCHAR},
|
||||
info = #{record.info,jdbcType=LONGVARCHAR}
|
||||
<if test="_parameter != null">
|
||||
<include refid="Update_By_Example_Where_Clause" />
|
||||
@ -262,7 +273,8 @@
|
||||
`type` = #{record.type,jdbcType=VARCHAR},
|
||||
`mode` = #{record.mode,jdbcType=INTEGER},
|
||||
create_by = #{record.createBy,jdbcType=VARCHAR},
|
||||
create_time = #{record.createTime,jdbcType=BIGINT}
|
||||
create_time = #{record.createTime,jdbcType=BIGINT},
|
||||
sync_status = #{record.syncStatus,jdbcType=VARCHAR}
|
||||
<if test="_parameter != null">
|
||||
<include refid="Update_By_Example_Where_Clause" />
|
||||
</if>
|
||||
@ -291,6 +303,9 @@
|
||||
<if test="createTime != null">
|
||||
create_time = #{createTime,jdbcType=BIGINT},
|
||||
</if>
|
||||
<if test="syncStatus != null">
|
||||
sync_status = #{syncStatus,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="info != null">
|
||||
info = #{info,jdbcType=LONGVARCHAR},
|
||||
</if>
|
||||
@ -306,6 +321,7 @@
|
||||
`mode` = #{mode,jdbcType=INTEGER},
|
||||
create_by = #{createBy,jdbcType=VARCHAR},
|
||||
create_time = #{createTime,jdbcType=BIGINT},
|
||||
sync_status = #{syncStatus,jdbcType=VARCHAR},
|
||||
info = #{info,jdbcType=LONGVARCHAR}
|
||||
where id = #{id,jdbcType=VARCHAR}
|
||||
</update>
|
||||
@ -317,7 +333,8 @@
|
||||
`type` = #{type,jdbcType=VARCHAR},
|
||||
`mode` = #{mode,jdbcType=INTEGER},
|
||||
create_by = #{createBy,jdbcType=VARCHAR},
|
||||
create_time = #{createTime,jdbcType=BIGINT}
|
||||
create_time = #{createTime,jdbcType=BIGINT},
|
||||
sync_status = #{syncStatus,jdbcType=VARCHAR}
|
||||
where id = #{id,jdbcType=VARCHAR}
|
||||
</update>
|
||||
</mapper>
|
@ -1,10 +1,7 @@
|
||||
package io.dataease.config;
|
||||
|
||||
import com.github.pagehelper.PageInterceptor;
|
||||
import io.dataease.base.domain.ApiTestReportDetail;
|
||||
import io.dataease.base.domain.AuthSource;
|
||||
import io.dataease.base.domain.FileContent;
|
||||
import io.dataease.base.domain.TestResource;
|
||||
import io.dataease.base.domain.*;
|
||||
import io.dataease.commons.utils.CompressUtils;
|
||||
import io.dataease.commons.utils.MybatisInterceptorConfig;
|
||||
import io.dataease.interceptor.MybatisInterceptor;
|
||||
@ -45,7 +42,7 @@ public class MybatisConfig {
|
||||
List<MybatisInterceptorConfig> configList = new ArrayList<>();
|
||||
configList.add(new MybatisInterceptorConfig(FileContent.class, "file", CompressUtils.class, "zip", "unzip"));
|
||||
configList.add(new MybatisInterceptorConfig(ApiTestReportDetail.class, "content", CompressUtils.class, "compress", "decompress"));
|
||||
configList.add(new MybatisInterceptorConfig(TestResource.class, "configuration"));
|
||||
configList.add(new MybatisInterceptorConfig(Datasource.class, "configuration"));
|
||||
configList.add(new MybatisInterceptorConfig(AuthSource.class, "configuration"));
|
||||
interceptor.setInterceptorConfigList(configList);
|
||||
return interceptor;
|
||||
|
@ -3,6 +3,7 @@ package io.dataease.listener;
|
||||
import io.dataease.base.domain.DatasetTableTask;
|
||||
import io.dataease.datasource.service.DatasourceService;
|
||||
import io.dataease.service.ScheduleService;
|
||||
import io.dataease.service.dataset.DataSetTableService;
|
||||
import io.dataease.service.dataset.DataSetTableTaskService;
|
||||
import org.springframework.boot.context.event.ApplicationReadyEvent;
|
||||
import org.springframework.context.ApplicationListener;
|
||||
@ -17,9 +18,12 @@ import java.util.List;
|
||||
public class DataSourceInitStartListener implements ApplicationListener<ApplicationReadyEvent> {
|
||||
@Resource
|
||||
private DatasourceService datasourceService;
|
||||
@Resource
|
||||
private DataSetTableService dataSetTableService;
|
||||
|
||||
@Override
|
||||
public void onApplicationEvent(ApplicationReadyEvent applicationReadyEvent) {
|
||||
datasourceService.initAllDataSourceConnectionPool();
|
||||
dataSetTableService.updateDatasetTableStatus();
|
||||
}
|
||||
}
|
||||
|
@ -876,4 +876,12 @@ public class DataSetTableService {
|
||||
List<String[]> data = jdbcProvider.getData(datasourceRequest);
|
||||
return CollectionUtils.isNotEmpty(data);
|
||||
}
|
||||
|
||||
public void updateDatasetTableStatus(){
|
||||
DatasetTable record = new DatasetTable();
|
||||
record.setSyncStatus(JobStatus.Completed.name());
|
||||
DatasetTableExample example = new DatasetTableExample();
|
||||
example.createCriteria().andSyncStatusEqualTo(JobStatus.Underway.name());
|
||||
datasetTableMapper.updateByExampleSelective(record, example);
|
||||
}
|
||||
}
|
||||
|
@ -2,6 +2,7 @@ package io.dataease.service.dataset;
|
||||
|
||||
import com.google.gson.Gson;
|
||||
import io.dataease.base.domain.*;
|
||||
import io.dataease.base.mapper.DatasetTableMapper;
|
||||
import io.dataease.base.mapper.DatasourceMapper;
|
||||
import io.dataease.commons.constants.JobStatus;
|
||||
import io.dataease.commons.constants.ScheduleType;
|
||||
@ -93,6 +94,8 @@ public class ExtractDataService {
|
||||
private DataSetTableTaskService dataSetTableTaskService;
|
||||
@Resource
|
||||
private DatasourceMapper datasourceMapper;
|
||||
@Resource
|
||||
private DatasetTableMapper datasetTableMapper;
|
||||
|
||||
private static String lastUpdateTime = "${__last_update_time__}";
|
||||
private static String currentUpdateTime = "${__current_update_time__}";
|
||||
@ -172,12 +175,17 @@ public class ExtractDataService {
|
||||
}
|
||||
|
||||
public void extractData(String datasetTableId, String taskId, String type) {
|
||||
DatasetTable datasetTable = dataSetTableService.get(datasetTableId);
|
||||
datasetTable.setSyncStatus(JobStatus.Underway.name());
|
||||
DatasetTableExample example = new DatasetTableExample();
|
||||
example.createCriteria().andIdEqualTo(datasetTableId);
|
||||
if (datasetTableMapper.updateByExampleSelective(datasetTable, example) == 0) {
|
||||
return;
|
||||
}
|
||||
DatasetTableTaskLog datasetTableTaskLog = new DatasetTableTaskLog();
|
||||
UpdateType updateType = UpdateType.valueOf(type);
|
||||
DatasetTable datasetTable = null;
|
||||
Datasource datasource = new Datasource();
|
||||
try {
|
||||
datasetTable = dataSetTableService.get(datasetTableId);
|
||||
if (StringUtils.isNotEmpty(datasetTable.getDataSourceId())) {
|
||||
datasource = datasourceMapper.selectByPrimaryKey(datasetTable.getDataSourceId());
|
||||
} else {
|
||||
@ -261,6 +269,10 @@ public class ExtractDataService {
|
||||
datasetTableTask.setRate(ScheduleType.SIMPLE_COMPLETE.toString());
|
||||
dataSetTableTaskService.update(datasetTableTask);
|
||||
}
|
||||
datasetTable.setSyncStatus(JobStatus.Completed.name());
|
||||
example.clear();
|
||||
example.createCriteria().andIdEqualTo(datasetTableId);
|
||||
datasetTableMapper.updateByExampleSelective(datasetTable, example);
|
||||
}
|
||||
}
|
||||
|
||||
@ -273,6 +285,8 @@ public class ExtractDataService {
|
||||
}
|
||||
|
||||
private void extractData(DatasetTable datasetTable, String extractType) throws Exception {
|
||||
|
||||
|
||||
KettleFileRepository repository = CommonBeanFactory.getBean(KettleFileRepository.class);
|
||||
RepositoryDirectoryInterface repositoryDirectoryInterface = repository.loadRepositoryDirectoryTree();
|
||||
JobMeta jobMeta = null;
|
||||
|
@ -74,7 +74,7 @@
|
||||
<!-- </table>-->
|
||||
<!-- <table tableName="v_dataset"/>-->
|
||||
<!-- <table tableName="sys_auth_detail"/>-->
|
||||
<table tableName="panel_group"/>
|
||||
<table tableName="dataset_table"/>
|
||||
|
||||
|
||||
</context>
|
||||
|
@ -83,8 +83,8 @@ export default {
|
||||
thirdpartyTips: 'Can not be simulated on local, so please combine you own business simulation! ! !',
|
||||
expires: 'Login token expired, please login again',
|
||||
tokenError: 'Token error, please login again',
|
||||
username_error: 'Please enter the correct user name',
|
||||
password_error: 'The password can not be less than 6 digits'
|
||||
username_error: 'Please enter the correct ID',
|
||||
password_error: 'The password can not be less than 8 digits'
|
||||
},
|
||||
commons: {
|
||||
close: 'Close',
|
||||
@ -816,6 +816,8 @@ export default {
|
||||
input_limit_0_50: '0-50 chars'
|
||||
},
|
||||
panel: {
|
||||
no_auth_role: 'Unshared roles',
|
||||
auth_role: 'Shared roles',
|
||||
picture_limit: 'Only pictures can be inserted',
|
||||
drag_here: 'Please drag the left field here',
|
||||
copy_link_passwd: 'Copy link and password',
|
||||
|
@ -83,8 +83,8 @@ export default {
|
||||
thirdpartyTips: '本地不能模拟,请结合自己业务进行模拟!!!',
|
||||
expires: '登陸信息过期,请重新登陸',
|
||||
tokenError: '信息错误,请重新登陸',
|
||||
username_error: '請輸入正確的用戶名',
|
||||
password_error: '密碼不小於6位'
|
||||
username_error: '請輸入正確的ID',
|
||||
password_error: '密碼不小於8位'
|
||||
},
|
||||
commons: {
|
||||
icon: '圖標',
|
||||
@ -815,6 +815,8 @@ export default {
|
||||
input_limit_0_50: '0-50字符'
|
||||
},
|
||||
panel: {
|
||||
no_auth_role: '未分享角色',
|
||||
auth_role: '已分享角色',
|
||||
picture_limit: '只能插入圖片',
|
||||
drag_here: '請將左側字段拖至此處',
|
||||
copy_link_passwd: '複製鏈接及密碼',
|
||||
|
@ -83,8 +83,8 @@ export default {
|
||||
thirdpartyTips: '本地不能模拟,请结合自己业务进行模拟!!!',
|
||||
expires: '登录token过期,请重新登录',
|
||||
tokenError: 'token错误,请重新登录',
|
||||
username_error: '请输入正确的用户名',
|
||||
password_error: '密码不小于6位'
|
||||
username_error: '请输入正确的ID',
|
||||
password_error: '密码不小于8位'
|
||||
},
|
||||
commons: {
|
||||
close: '关闭',
|
||||
@ -817,6 +817,8 @@ export default {
|
||||
input_limit_0_50: '0-50字符'
|
||||
},
|
||||
panel: {
|
||||
no_auth_role: '未分享角色',
|
||||
auth_role: '已分享角色',
|
||||
picture_limit: '只能插入图片',
|
||||
drag_here: '请将左侧字段拖至此处',
|
||||
copy_link_passwd: '复制链接及密码',
|
||||
|
@ -39,6 +39,7 @@ $menuHover: rgba(158, 158, 158, 0.2);
|
||||
$subMenuBg:#1f2d3d;
|
||||
// $subMenuHover:#001528;
|
||||
$subMenuHover:#0a7be0;
|
||||
$colorBg:rgba(10,123,224,.1);
|
||||
|
||||
$sideBarWidth: 210px;
|
||||
$topBarHeight: 56px;
|
||||
|
@ -1,5 +1,5 @@
|
||||
<template>
|
||||
<el-col>
|
||||
<el-col ref="container" style="width: 100%;height:100%">
|
||||
<span>{{ table.name }}</span>
|
||||
<ux-grid
|
||||
ref="plxTable"
|
||||
@ -36,7 +36,7 @@ export default {
|
||||
return {
|
||||
fields: [],
|
||||
data: [],
|
||||
height: 500
|
||||
height: 'auto'
|
||||
}
|
||||
},
|
||||
watch: {
|
||||
@ -45,12 +45,12 @@ export default {
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
window.onresize = () => {
|
||||
return (() => {
|
||||
this.height = window.innerHeight / 3
|
||||
})()
|
||||
}
|
||||
this.height = window.innerHeight / 3
|
||||
// window.onresize = () => {
|
||||
// return (() => {
|
||||
// this.height = window.innerHeight / 3
|
||||
// })()
|
||||
// }
|
||||
// this.height = window.innerHeight / 3
|
||||
this.initData()
|
||||
},
|
||||
methods: {
|
||||
@ -62,11 +62,11 @@ export default {
|
||||
this.fields = response.data.fields
|
||||
this.data = response.data.data
|
||||
const datas = this.data
|
||||
if(response.data.status === 'warnning'){
|
||||
this.$warning(response.data.msg, 3000);
|
||||
if (response.data.status === 'warnning') {
|
||||
this.$warning(response.data.msg, 3000)
|
||||
}
|
||||
if(response.data.status === 'error'){
|
||||
this.$error(response.data.msg, 3000);
|
||||
if (response.data.status === 'error') {
|
||||
this.$error(response.data.msg, 3000)
|
||||
}
|
||||
this.$refs.plxTable.reloadData(datas)
|
||||
})
|
||||
|
@ -8,13 +8,12 @@
|
||||
<img v-if="!loginLogoUrl" src="@/assets/DataEase-color.png" alt="">
|
||||
<img v-else :src="loginLogoUrl" alt="">
|
||||
</div>
|
||||
<div class="login-border" />
|
||||
<div class="login-welcome">
|
||||
{{ $t('login.welcome') + (uiInfo && uiInfo['ui.title'] && uiInfo['ui.title'].paramValue || 'DATAEASE') }}
|
||||
</div>
|
||||
<div class="login-form">
|
||||
<el-form-item prop="username">
|
||||
<el-input v-model="loginForm.username" :placeholder="$t('login.username')" autofocus />
|
||||
<el-input v-model="loginForm.username" placeholder="ID" autofocus />
|
||||
</el-form-item>
|
||||
<el-form-item prop="password">
|
||||
<el-input
|
||||
@ -73,7 +72,7 @@ export default {
|
||||
// }
|
||||
}
|
||||
const validatePassword = (rule, value, callback) => {
|
||||
if (value.length < 6) {
|
||||
if (value.length < 8) {
|
||||
callback(this.$t('login.password_error'))
|
||||
} else {
|
||||
callback()
|
||||
@ -180,9 +179,11 @@ export default {
|
||||
@media only screen and (max-width: 1280px) {
|
||||
margin-top: 20px;
|
||||
}
|
||||
|
||||
img {
|
||||
height: 45px;
|
||||
img{
|
||||
width: 240px;
|
||||
@media only screen and (max-width: 1280px) {
|
||||
width: 200px;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -210,9 +211,9 @@ export default {
|
||||
}
|
||||
|
||||
.login-welcome {
|
||||
margin-top: 50px;
|
||||
margin-top: 20px;
|
||||
font-size: 14px;
|
||||
color: #999999;
|
||||
color: $--color-primary;
|
||||
letter-spacing: 0;
|
||||
line-height: 18px;
|
||||
text-align: center;
|
||||
@ -222,20 +223,25 @@ export default {
|
||||
}
|
||||
|
||||
.login-form {
|
||||
margin-top: 40px;
|
||||
margin-top: 80px;
|
||||
padding: 0 40px;
|
||||
|
||||
@media only screen and (max-width: 1280px) {
|
||||
margin-top: 20px;
|
||||
margin-top: 40px;
|
||||
}
|
||||
|
||||
& ::v-deep .el-input__inner {
|
||||
border-radius: 0;
|
||||
border-radius: 20px;
|
||||
border: 1px solid transparent;
|
||||
background: $colorBg;
|
||||
}
|
||||
& :focus {
|
||||
border: 1px solid $--color-primary;
|
||||
}
|
||||
}
|
||||
|
||||
.login-btn {
|
||||
margin-top: 40px;
|
||||
margin-top: 22px;
|
||||
padding: 0 40px;
|
||||
@media only screen and (max-width: 1280px) {
|
||||
margin-top: 20px;
|
||||
@ -243,7 +249,7 @@ export default {
|
||||
|
||||
.submit {
|
||||
width: 100%;
|
||||
border-radius: 0;
|
||||
border-radius: 20px;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -162,7 +162,7 @@ export default {
|
||||
const rows = this.$refs.table.store.states.selection
|
||||
const request = this.buildRequest(rows)
|
||||
saveShare(request).then(res => {
|
||||
this.$success('保存成功')
|
||||
this.$success(this.$t('commons.save_success'))
|
||||
return true
|
||||
}).catch(err => {
|
||||
this.$error(err.message)
|
||||
|
@ -33,9 +33,9 @@ export default {
|
||||
data() {
|
||||
return {
|
||||
data: [],
|
||||
defaultHeadName: '全部',
|
||||
defaultHeadName: this.$t('commons.all'),
|
||||
columnLabel: null,
|
||||
filter_options: [{ text: '未分享角色', value: 0 }, { text: '已分享角色', value: 1 }],
|
||||
filter_options: [{ text: this.$t('panel.no_auth_role'), value: 0 }, { text: this.$t('panel.auth_role'), value: 1 }],
|
||||
fieldName: 'name',
|
||||
type: 1, // 类型1代表角色
|
||||
shares: []
|
||||
|
@ -11,7 +11,7 @@
|
||||
<template :id="scope.row.storeId" slot-scope="scope">
|
||||
<div class="start-item">
|
||||
<div class="filter-db-row star-item-content" @click="showPanel(scope.row)">
|
||||
<i class="el-icon-s-data" />
|
||||
<svg-icon icon-class="panel" class="ds-icon-scene" />
|
||||
<span> {{ scope.row.name }}</span>
|
||||
</div>
|
||||
<div class="star-item-close">
|
||||
|
@ -14,7 +14,7 @@
|
||||
<!-- <fu-table-button v-permission="['user:add']" icon="el-icon-circle-plus-outline" :label="$t('user.create')" @click="create" /> -->
|
||||
</template>
|
||||
|
||||
<el-table-column prop="username" :label="$t('commons.name')" />
|
||||
<el-table-column prop="username" label="ID" />
|
||||
<el-table-column prop="nickName" :label="$t('commons.nick_name')" />
|
||||
<el-table-column prop="gender" :label="$t('commons.gender')" />
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user