Complete the text translation of the 'Framework Thread Pool' module (#1140)

pull/1141/head
Svamei 1 year ago committed by GitHub
parent 13d90653fc
commit de7a965b7b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -18,7 +18,8 @@ export default {
selectMessage: 'Please select a {target}', selectMessage: 'Please select a {target}',
NoDeletionPermissionTip: 'Contact the administrator to delete it', NoDeletionPermissionTip: 'Contact the administrator to delete it',
emptyWarning: "The '{name}' cannot be empty", emptyWarning: "The '{name}' cannot be empty",
queryFailure: 'The query fails. Please refresh the page' queryFailure: 'The query fails. Please refresh the page',
updateFailure:'Failed to modify thread pool'
}, },
// 公共 // 公共
@ -133,5 +134,12 @@ export default {
ipPort: 'IP : Port', ipPort: 'IP : Port',
ipPortRequired: 'IP : Port(Required)', ipPortRequired: 'IP : Port(Required)',
noResultsYet: 'No results yet' noResultsYet: 'No results yet'
},
//框架线程池
frameworkThreadPool : {
threadPoolIDRequired: 'ThreadPool ID(Required)',
threadPoolID: 'ThreadPool ID',
threadPoolType: 'ThreadPool Type'
} }
} }

@ -18,7 +18,8 @@ export default {
selectMessage: '请选择{target}', selectMessage: '请选择{target}',
NoDeletionPermissionTip: '请联系管理员删除', NoDeletionPermissionTip: '请联系管理员删除',
emptyWarning: "{name}不允许为空", emptyWarning: "{name}不允许为空",
queryFailure: '查询失败,请尝试刷新页面' queryFailure: '查询失败,请尝试刷新页面',
updateFailure:'修改线程池失败'
}, },
// 公共 // 公共
@ -134,5 +135,12 @@ export default {
ipPort: 'IP : Port', ipPort: 'IP : Port',
ipPortRequired: 'IP : Port必填', ipPortRequired: 'IP : Port必填',
noResultsYet: '暂无结果' noResultsYet: '暂无结果'
},
//框架线程池
frameworkThreadPool : {
threadPoolIDRequired: '线程池标识(必填)',
threadPoolID: '线程池标识',
threadPoolType: '线程池类型'
} }
} }

@ -3,7 +3,7 @@
<div class="filter-container"> <div class="filter-container">
<el-select <el-select
v-model="listQuery.tenantId" v-model="listQuery.tenantId"
placeholder="租户(必填)" :placeholder="$t('tenantManage.tenantRequired')"
style="width: 220px" style="width: 220px"
filterable filterable
class="filter-item" class="filter-item"
@ -18,7 +18,7 @@
</el-select> </el-select>
<el-select <el-select
v-model="listQuery.itemId" v-model="listQuery.itemId"
placeholder="项目(必填)" :placeholder="$t('projectManage.itemRequired')"
style="width: 220px" style="width: 220px"
filterable filterable
class="filter-item" class="filter-item"
@ -33,7 +33,7 @@
</el-select> </el-select>
<el-select <el-select
v-model="listQuery.threadPoolKey" v-model="listQuery.threadPoolKey"
placeholder="线程池标识(必填)" :placeholder="$t('frameworkThreadPool.threadPoolIDRequired')"
style="width: 220px" style="width: 220px"
filterable filterable
class="filter-item" class="filter-item"
@ -52,7 +52,7 @@
icon="el-icon-search" icon="el-icon-search"
@click="fetchData" @click="fetchData"
> >
搜索 {{ $t('common.query') }}
</el-button> </el-button>
<el-button <el-button
v-waves v-waves
@ -62,7 +62,7 @@
icon="el-icon-refresh" icon="el-icon-refresh"
@click="refreshData" @click="refreshData"
> >
重置 {{ $t('common.reset') }}
</el-button> </el-button>
</div> </div>
<el-table <el-table
@ -74,32 +74,32 @@
max-height="714" max-height="714"
highlight-current-row highlight-current-row
> >
<el-table-column label="序号" width="95"> <el-table-column :label="$t('common.num')" fixed width="95">
<template slot-scope="scope">{{ scope.$index + 1 }}</template> <template slot-scope="scope">{{ scope.$index + 1 }}</template>
</el-table-column> </el-table-column>
<el-table-column label="实例标识" width="260"> <el-table-column :label="$t('threadPoolInstance.instanceID')" width="260">
<template slot-scope="scope"> <template slot-scope="scope">
<el-link type="primary" :underline="false">{{ scope.row.identify }}</el-link> <el-link type="primary" :underline="false">{{ scope.row.identify }}</el-link>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="Active"> <el-table-column :label="$t('threadPoolInstance.active')" width="120">
<template slot-scope="scope"> <template slot-scope="scope">
<el-tag :type="scope.row.active | statusFilter"> <el-tag :type="scope.row.active | statusFilter">
{{ scope.row.active }} {{ scope.row.active }}
</el-tag> </el-tag>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="线程池标识"> <el-table-column :label="$t('frameworkThreadPool.threadPoolID')">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.threadPoolKey }} {{ scope.row.threadPoolKey }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="核心线程"> <el-table-column :label="$t('threadPool.coreSize')">
<template slot-scope="scope"> <template slot-scope="scope">
<el-link type="success" :underline="false">{{ scope.row.coreSize }}</el-link> <el-link type="success" :underline="false">{{ scope.row.coreSize }}</el-link>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="最大线程"> <el-table-column :label="$t('threadPool.maximumSize')" width="120">
<template slot-scope="scope"> <template slot-scope="scope">
<el-link type="danger" :underline="false">{{ scope.row.maximumSize }}</el-link> <el-link type="danger" :underline="false">{{ scope.row.maximumSize }}</el-link>
</template> </template>
@ -110,7 +110,7 @@
<el-table-column label="队列容量" > <el-table-column label="队列容量" >
<template slot-scope="scope">{{ scope.row.queueCapacity }}</template> <template slot-scope="scope">{{ scope.row.queueCapacity }}</template>
</el-table-column>--> </el-table-column>-->
<el-table-column label="操作" width="180" class-name="small-padding fixed-width"> <el-table-column :label="$t('common.operation')" width="180" class-name="small-padding fixed-width">
<template slot-scope="{ row }"> <template slot-scope="{ row }">
<!--<el-dropdown trigger="click"> <!--<el-dropdown trigger="click">
<span class="el-dropdown-link"> <span class="el-dropdown-link">
@ -121,7 +121,7 @@
<el-dropdown-item @click.native="handleUpdate(row)">编辑</el-dropdown-item> <el-dropdown-item @click.native="handleUpdate(row)">编辑</el-dropdown-item>
</el-dropdown-menu> </el-dropdown-menu>
</el-dropdown>--> </el-dropdown>-->
<el-button type="text" size="small" @click="handleUpdate(row)"> </el-button> <el-button type="text" size="small" @click="handleUpdate(row)"> {{ $t('common.edit') }} </el-button>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
@ -134,7 +134,7 @@
label-position="left" label-position="left"
label-width="110px" label-width="110px"
> >
<el-form-item label="核心线程" prop="coreSize"> <el-form-item :label="$t('threadPool.coreSize')" prop="coreSize">
<template> <template>
<el-input-number <el-input-number
v-model="temp.coreSize" v-model="temp.coreSize"
@ -144,7 +144,7 @@
></el-input-number> ></el-input-number>
</template> </template>
</el-form-item> </el-form-item>
<el-form-item label="最大线程" prop="maximumSize"> <el-form-item :label="$t('threadPool.maximumSize')" prop="maximumSize">
<template> <template>
<el-input-number <el-input-number
v-model="temp.maximumSize" v-model="temp.maximumSize"
@ -154,13 +154,13 @@
></el-input-number> ></el-input-number>
</template> </template>
</el-form-item> </el-form-item>
<el-form-item label="全部修改" prop="allUpdate"> <el-form-item :label="$t('threadPoolInstance.changeAll')" prop="allUpdate">
<el-switch v-model="temp.allUpdate"></el-switch> <el-switch v-model="temp.allUpdate"></el-switch>
</el-form-item> </el-form-item>
</el-form> </el-form>
<div slot="footer" class="dialog-footer"> <div slot="footer" class="dialog-footer">
<el-button @click="dialogFormVisible = false"> 取消 </el-button> <el-button @click="dialogFormVisible = false"> {{ $t('common.cancel') }} </el-button>
<el-button type="primary" @click="updateData()"> </el-button> <el-button type="primary" @click="updateData()"> {{$t('common.confirm')}} </el-button>
</div> </div>
</el-dialog> </el-dialog>
<el-dialog :visible.sync="dialogPluginVisible" title="Reading statistics"> <el-dialog :visible.sync="dialogPluginVisible" title="Reading statistics">
@ -283,19 +283,19 @@ export default {
}, },
fetchData() { fetchData() {
if (!this.listQuery.mark) { if (!this.listQuery.mark) {
this.$message.warning('线程池类型不允许为空'); this.$message.warning(this.$t('message.emptyWarning', { name: this. $t('frameworkThreadPool.threadPoolType') }));
return; return;
} }
if (!this.listQuery.tenantId) { if (!this.listQuery.tenantId) {
this.$message.warning('租户不允许为空'); this.$message.warning(this.$t('message.emptyWarning', { name: this.$t('tenantManage.tenant') }));
return; return;
} }
if (!this.listQuery.itemId) { if (!this.listQuery.itemId) {
this.$message.warning('项目不允许为空'); this.$message.warning(this.$t('message.emptyWarning', { name: this.$t('projectManage.item') }));
return; return;
} }
if (!this.listQuery.threadPoolKey) { if (!this.listQuery.threadPoolKey) {
this.$message.warning('线程池标识不允许为空'); this.$message.warning(this.$t('message.emptyWarning', { name: this. $t('frameworkThreadPool.threadPoolID') }));
return; return;
} }
this.listLoading = true; this.listLoading = true;
@ -333,7 +333,7 @@ export default {
if (valid) { if (valid) {
if (parseInt(this.temp.maximumSize) < parseInt(this.temp.coreSize)) { if (parseInt(this.temp.maximumSize) < parseInt(this.temp.coreSize)) {
this.$message({ this.$message({
message: '最大线程必须大于等于核心线程', message: this.$t('threadPool.threadsNumErrorTip'),
type: 'warning', type: 'warning',
}); });
return; return;
@ -385,13 +385,13 @@ export default {
}) })
.catch((error) => { .catch((error) => {
console.log(error); console.log(error);
this.$message.error('修改线程池失败'); this.$message.error(this.$t('message.updateFailure'));
}); });
}, },
openDelConfirm(name) { openDelConfirm(name) {
return this.$confirm(`此操作将删除 ${name}, 是否继续?`, '提示', { return this.$confirm(this.$t('message.deleteMessage', { name }), this.$t('common.hint'), {
confirmButtonText: '确定', confirmButtonText: this.$t('common.ok'),
cancelButtonText: '取消', cancelButtonText: this.$t('common.cancel'),
type: 'warning', type: 'warning',
}); });
}, },
@ -497,7 +497,7 @@ export default {
}) })
.catch((error) => { .catch((error) => {
console.log(error); console.log(error);
this.$message.error('查询失败,请尝试刷新页面'); this.$message.error(this.$t('message.queryFailure'));
}); });
}, },
}, },

@ -3,7 +3,7 @@
<div class="filter-container"> <div class="filter-container">
<el-select <el-select
v-model="listQuery.tenantId" v-model="listQuery.tenantId"
placeholder="租户(必填)" :placeholder="$t('tenantManage.tenantRequired')"
style="width: 220px" style="width: 220px"
filterable filterable
class="filter-item" class="filter-item"
@ -18,7 +18,7 @@
</el-select> </el-select>
<el-select <el-select
v-model="listQuery.itemId" v-model="listQuery.itemId"
placeholder="项目(必填)" :placeholder="$t('projectManage.itemRequired')"
style="width: 220px" style="width: 220px"
filterable filterable
class="filter-item" class="filter-item"
@ -33,7 +33,7 @@
</el-select> </el-select>
<el-select <el-select
v-model="listQuery.threadPoolKey" v-model="listQuery.threadPoolKey"
placeholder="线程池标识(必填)" :placeholder="$t('frameworkThreadPool.threadPoolIDRequired')"
style="width: 220px" style="width: 220px"
filterable filterable
class="filter-item" class="filter-item"
@ -52,7 +52,7 @@
icon="el-icon-search" icon="el-icon-search"
@click="fetchData" @click="fetchData"
> >
搜索 {{ $t('common.query') }}
</el-button> </el-button>
<el-button <el-button
v-waves v-waves
@ -62,7 +62,7 @@
icon="el-icon-refresh" icon="el-icon-refresh"
@click="refreshData" @click="refreshData"
> >
重置 {{ $t('common.reset') }}
</el-button> </el-button>
</div> </div>
<el-table <el-table
@ -74,32 +74,32 @@
max-height="714" max-height="714"
highlight-current-row highlight-current-row
> >
<el-table-column label="序号" width="95"> <el-table-column :label="$t('common.num')" fixed width="95">
<template slot-scope="scope">{{ scope.$index + 1 }}</template> <template slot-scope="scope">{{ scope.$index + 1 }}</template>
</el-table-column> </el-table-column>
<el-table-column label="实例标识" width="260"> <el-table-column :label="$t('threadPoolInstance.instanceID')" width="260">
<template slot-scope="scope"> <template slot-scope="scope">
<el-link type="primary" :underline="false">{{ scope.row.identify }}</el-link> <el-link type="primary" :underline="false">{{ scope.row.identify }}</el-link>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="Active"> <el-table-column :label="$t('threadPoolInstance.active')" width="120">
<template slot-scope="scope"> <template slot-scope="scope">
<el-tag :type="scope.row.active | statusFilter"> <el-tag :type="scope.row.active | statusFilter">
{{ scope.row.active }} {{ scope.row.active }}
</el-tag> </el-tag>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="线程池标识"> <el-table-column :label="$t('frameworkThreadPool.threadPoolID')">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.threadPoolKey }} {{ scope.row.threadPoolKey }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="核心线程"> <el-table-column :label="$t('threadPool.coreSize')">
<template slot-scope="scope"> <template slot-scope="scope">
<el-link type="success" :underline="false">{{ scope.row.coreSize }}</el-link> <el-link type="success" :underline="false">{{ scope.row.coreSize }}</el-link>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="最大线程"> <el-table-column :label="$t('threadPool.maximumSize')" width="120">
<template slot-scope="scope"> <template slot-scope="scope">
<el-link type="danger" :underline="false">{{ scope.row.maximumSize }}</el-link> <el-link type="danger" :underline="false">{{ scope.row.maximumSize }}</el-link>
</template> </template>
@ -110,7 +110,7 @@
<el-table-column label="队列容量" > <el-table-column label="队列容量" >
<template slot-scope="scope">{{ scope.row.queueCapacity }}</template> <template slot-scope="scope">{{ scope.row.queueCapacity }}</template>
</el-table-column>--> </el-table-column>-->
<el-table-column label="操作" width="180" class-name="small-padding fixed-width"> <el-table-column :label="$t('common.operation')" width="180" class-name="small-padding fixed-width">
<template slot-scope="{ row }"> <template slot-scope="{ row }">
<!--<el-dropdown trigger="click"> <!--<el-dropdown trigger="click">
<span class="el-dropdown-link"> <span class="el-dropdown-link">
@ -121,7 +121,7 @@
<el-dropdown-item @click.native="handleUpdate(row)">编辑</el-dropdown-item> <el-dropdown-item @click.native="handleUpdate(row)">编辑</el-dropdown-item>
</el-dropdown-menu> </el-dropdown-menu>
</el-dropdown>--> </el-dropdown>-->
<el-button type="text" size="small" @click="handleUpdate(row)"> </el-button> <el-button type="text" size="small" @click="handleUpdate(row)"> {{ $t('common.edit') }} </el-button>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
@ -134,7 +134,7 @@
label-position="left" label-position="left"
label-width="110px" label-width="110px"
> >
<el-form-item label="核心线程" prop="coreSize"> <el-form-item :label="$t('threadPool.coreSize')" prop="coreSize">
<template> <template>
<el-input-number <el-input-number
v-model="temp.coreSize" v-model="temp.coreSize"
@ -144,7 +144,7 @@
></el-input-number> ></el-input-number>
</template> </template>
</el-form-item> </el-form-item>
<el-form-item label="最大线程" prop="maximumSize"> <el-form-item :label="$t('threadPool.maximumSize')" prop="maximumSize">
<template> <template>
<el-input-number <el-input-number
v-model="temp.maximumSize" v-model="temp.maximumSize"
@ -154,13 +154,13 @@
></el-input-number> ></el-input-number>
</template> </template>
</el-form-item> </el-form-item>
<el-form-item label="全部修改" prop="allUpdate"> <el-form-item :label="$t('threadPoolInstance.changeAll')" prop="allUpdate">
<el-switch v-model="temp.allUpdate"></el-switch> <el-switch v-model="temp.allUpdate"></el-switch>
</el-form-item> </el-form-item>
</el-form> </el-form>
<div slot="footer" class="dialog-footer"> <div slot="footer" class="dialog-footer">
<el-button @click="dialogFormVisible = false"> 取消 </el-button> <el-button @click="dialogFormVisible = false"> {{ $t('common.cancel') }} </el-button>
<el-button type="primary" @click="updateData()"> </el-button> <el-button type="primary" @click="updateData()"> {{$t('common.confirm')}} </el-button>
</div> </div>
</el-dialog> </el-dialog>
<el-dialog :visible.sync="dialogPluginVisible" title="Reading statistics"> <el-dialog :visible.sync="dialogPluginVisible" title="Reading statistics">
@ -283,19 +283,19 @@ export default {
}, },
fetchData() { fetchData() {
if (!this.listQuery.mark) { if (!this.listQuery.mark) {
this.$message.warning('线程池类型不允许为空'); this.$message.warning(this.$t('message.emptyWarning', { name: this. $t('frameworkThreadPool.threadPoolType') }));
return; return;
} }
if (!this.listQuery.tenantId) { if (!this.listQuery.tenantId) {
this.$message.warning('租户不允许为空'); this.$message.warning(this.$t('message.emptyWarning', { name: this.$t('tenantManage.tenant') }));
return; return;
} }
if (!this.listQuery.itemId) { if (!this.listQuery.itemId) {
this.$message.warning('项目不允许为空'); this.$message.warning(this.$t('message.emptyWarning', { name: this.$t('projectManage.item') }));
return; return;
} }
if (!this.listQuery.threadPoolKey) { if (!this.listQuery.threadPoolKey) {
this.$message.warning('线程池标识不允许为空'); this.$message.warning(this.$t('message.emptyWarning', { name: this. $t('frameworkThreadPool.threadPoolID') }));
return; return;
} }
this.listLoading = true; this.listLoading = true;
@ -333,7 +333,7 @@ export default {
if (valid) { if (valid) {
if (parseInt(this.temp.maximumSize) < parseInt(this.temp.coreSize)) { if (parseInt(this.temp.maximumSize) < parseInt(this.temp.coreSize)) {
this.$message({ this.$message({
message: '最大线程必须大于等于核心线程', message: this.$t('threadPool.threadsNumErrorTip'),
type: 'warning', type: 'warning',
}); });
return; return;
@ -385,13 +385,13 @@ export default {
}) })
.catch((error) => { .catch((error) => {
console.log(error); console.log(error);
this.$message.error('修改线程池失败'); this.$message.error(this.$t('message.updateFailure'));
}); });
}, },
openDelConfirm(name) { openDelConfirm(name) {
return this.$confirm(`此操作将删除 ${name}, 是否继续?`, '提示', { return this.$confirm(this.$t('message.deleteMessage', { name }), this.$t('common.hint'), {
confirmButtonText: '确定', confirmButtonText: this.$t('common.ok'),
cancelButtonText: '取消', cancelButtonText: this.$t('common.cancel'),
type: 'warning', type: 'warning',
}); });
}, },
@ -497,7 +497,7 @@ export default {
}) })
.catch((error) => { .catch((error) => {
console.log(error); console.log(error);
this.$message.error('查询失败,请尝试刷新页面'); this.$message.error(this.$t('message.queryFailure'));
}); });
}, },
}, },

@ -3,7 +3,7 @@
<div class="filter-container"> <div class="filter-container">
<el-select <el-select
v-model="listQuery.tenantId" v-model="listQuery.tenantId"
placeholder="租户(必填)" :placeholder="$t('tenantManage.tenantRequired')"
style="width: 220px" style="width: 220px"
filterable filterable
class="filter-item" class="filter-item"
@ -18,7 +18,7 @@
</el-select> </el-select>
<el-select <el-select
v-model="listQuery.itemId" v-model="listQuery.itemId"
placeholder="项目(必填)" :placeholder="$t('projectManage.itemRequired')"
style="width: 220px" style="width: 220px"
filterable filterable
class="filter-item" class="filter-item"
@ -33,7 +33,7 @@
</el-select> </el-select>
<el-select <el-select
v-model="listQuery.threadPoolKey" v-model="listQuery.threadPoolKey"
placeholder="线程池标识(必填)" :placeholder="$t('frameworkThreadPool.threadPoolIDRequired')"
style="width: 220px" style="width: 220px"
filterable filterable
class="filter-item" class="filter-item"
@ -52,7 +52,7 @@
icon="el-icon-search" icon="el-icon-search"
@click="fetchData" @click="fetchData"
> >
搜索 {{ $t('common.query') }}
</el-button> </el-button>
<el-button <el-button
v-waves v-waves
@ -62,7 +62,7 @@
icon="el-icon-refresh" icon="el-icon-refresh"
@click="refreshData" @click="refreshData"
> >
重置 {{ $t('common.reset') }}
</el-button> </el-button>
</div> </div>
<el-table <el-table
@ -74,32 +74,32 @@
max-height="714" max-height="714"
highlight-current-row highlight-current-row
> >
<el-table-column label="序号" width="95"> <el-table-column :label="$t('common.num')" fixed width="95">
<template slot-scope="scope">{{ scope.$index + 1 }}</template> <template slot-scope="scope">{{ scope.$index + 1 }}</template>
</el-table-column> </el-table-column>
<el-table-column label="实例标识" width="260"> <el-table-column :label="$t('threadPoolInstance.instanceID')" width="260">
<template slot-scope="scope"> <template slot-scope="scope">
<el-link type="primary" :underline="false">{{ scope.row.identify }}</el-link> <el-link type="primary" :underline="false">{{ scope.row.identify }}</el-link>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="Active"> <el-table-column :label="$t('threadPoolInstance.active')" width="120">
<template slot-scope="scope"> <template slot-scope="scope">
<el-tag :type="scope.row.active | statusFilter"> <el-tag :type="scope.row.active | statusFilter">
{{ scope.row.active }} {{ scope.row.active }}
</el-tag> </el-tag>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="线程池标识"> <el-table-column :label="$t('frameworkThreadPool.threadPoolID')">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.threadPoolKey }} {{ scope.row.threadPoolKey }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="核心线程"> <el-table-column :label="$t('threadPool.coreSize')">
<template slot-scope="scope"> <template slot-scope="scope">
<el-link type="success" :underline="false">{{ scope.row.coreSize }}</el-link> <el-link type="success" :underline="false">{{ scope.row.coreSize }}</el-link>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="最大线程"> <el-table-column :label="$t('threadPool.maximumSize')" width="120">
<template slot-scope="scope"> <template slot-scope="scope">
<el-link type="danger" :underline="false">{{ scope.row.maximumSize }}</el-link> <el-link type="danger" :underline="false">{{ scope.row.maximumSize }}</el-link>
</template> </template>
@ -110,7 +110,7 @@
<el-table-column label="队列容量" > <el-table-column label="队列容量" >
<template slot-scope="scope">{{ scope.row.queueCapacity }}</template> <template slot-scope="scope">{{ scope.row.queueCapacity }}</template>
</el-table-column>--> </el-table-column>-->
<el-table-column label="操作" width="180" class-name="small-padding fixed-width"> <el-table-column :label="$t('common.operation')" width="180" class-name="small-padding fixed-width">
<template slot-scope="{ row }"> <template slot-scope="{ row }">
<!--<el-dropdown trigger="click"> <!--<el-dropdown trigger="click">
<span class="el-dropdown-link"> <span class="el-dropdown-link">
@ -121,7 +121,7 @@
<el-dropdown-item @click.native="handleUpdate(row)">编辑</el-dropdown-item> <el-dropdown-item @click.native="handleUpdate(row)">编辑</el-dropdown-item>
</el-dropdown-menu> </el-dropdown-menu>
</el-dropdown>--> </el-dropdown>-->
<el-button type="text" size="small" @click="handleUpdate(row)"> </el-button> <el-button type="text" size="small" @click="handleUpdate(row)"> {{ $t('common.edit') }} </el-button>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
@ -134,7 +134,7 @@
label-position="left" label-position="left"
label-width="110px" label-width="110px"
> >
<el-form-item label="核心线程" prop="coreSize"> <el-form-item :label="$t('threadPool.coreSize')" prop="coreSize">
<template> <template>
<el-input-number <el-input-number
v-model="temp.coreSize" v-model="temp.coreSize"
@ -144,7 +144,7 @@
></el-input-number> ></el-input-number>
</template> </template>
</el-form-item> </el-form-item>
<el-form-item label="最大线程" prop="maximumSize"> <el-form-item :label="$t('threadPool.maximumSize')" prop="maximumSize">
<template> <template>
<el-input-number <el-input-number
v-model="temp.maximumSize" v-model="temp.maximumSize"
@ -154,13 +154,13 @@
></el-input-number> ></el-input-number>
</template> </template>
</el-form-item> </el-form-item>
<el-form-item label="全部修改" prop="allUpdate"> <el-form-item :label="$t('threadPoolInstance.changeAll')" prop="allUpdate">
<el-switch v-model="temp.allUpdate"></el-switch> <el-switch v-model="temp.allUpdate"></el-switch>
</el-form-item> </el-form-item>
</el-form> </el-form>
<div slot="footer" class="dialog-footer"> <div slot="footer" class="dialog-footer">
<el-button @click="dialogFormVisible = false"> 取消 </el-button> <el-button @click="dialogFormVisible = false"> {{ $t('common.cancel') }} </el-button>
<el-button type="primary" @click="updateData()"> </el-button> <el-button type="primary" @click="updateData()"> {{$t('common.confirm')}} </el-button>
</div> </div>
</el-dialog> </el-dialog>
<el-dialog :visible.sync="dialogPluginVisible" title="Reading statistics"> <el-dialog :visible.sync="dialogPluginVisible" title="Reading statistics">
@ -283,19 +283,19 @@ export default {
}, },
fetchData() { fetchData() {
if (!this.listQuery.mark) { if (!this.listQuery.mark) {
this.$message.warning('线程池类型不允许为空'); this.$message.warning(this.$t('message.emptyWarning', { name: this. $t('frameworkThreadPool.threadPoolType') }));
return; return;
} }
if (!this.listQuery.tenantId) { if (!this.listQuery.tenantId) {
this.$message.warning('租户不允许为空'); this.$message.warning(this.$t('message.emptyWarning', { name: this.$t('tenantManage.tenant') }));
return; return;
} }
if (!this.listQuery.itemId) { if (!this.listQuery.itemId) {
this.$message.warning('项目不允许为空'); this.$message.warning(this.$t('message.emptyWarning', { name: this.$t('projectManage.item') }));
return; return;
} }
if (!this.listQuery.threadPoolKey) { if (!this.listQuery.threadPoolKey) {
this.$message.warning('线程池标识不允许为空'); this.$message.warning(this.$t('message.emptyWarning', { name: this. $t('frameworkThreadPool.threadPoolID') }));
return; return;
} }
this.listLoading = true; this.listLoading = true;
@ -333,7 +333,7 @@ export default {
if (valid) { if (valid) {
if (parseInt(this.temp.maximumSize) < parseInt(this.temp.coreSize)) { if (parseInt(this.temp.maximumSize) < parseInt(this.temp.coreSize)) {
this.$message({ this.$message({
message: '最大线程必须大于等于核心线程', message: this.$t('threadPool.threadsNumErrorTip'),
type: 'warning', type: 'warning',
}); });
return; return;
@ -385,13 +385,13 @@ export default {
}) })
.catch((error) => { .catch((error) => {
console.log(error); console.log(error);
this.$message.error('修改线程池失败'); this.$message.error(this.$t('message.updateFailure'));
}); });
}, },
openDelConfirm(name) { openDelConfirm(name) {
return this.$confirm(`此操作将删除 ${name}, 是否继续?`, '提示', { return this.$confirm(this.$t('message.deleteMessage', { name }), this.$t('common.hint'), {
confirmButtonText: '确定', confirmButtonText: this.$t('common.ok'),
cancelButtonText: '取消', cancelButtonText: this.$t('common.cancel'),
type: 'warning', type: 'warning',
}); });
}, },
@ -497,7 +497,7 @@ export default {
}) })
.catch((error) => { .catch((error) => {
console.log(error); console.log(error);
this.$message.error('查询失败,请尝试刷新页面'); this.$message.error(this.$t('message.queryFailure'));
}); });
}, },
}, },

@ -3,7 +3,7 @@
<div class="filter-container"> <div class="filter-container">
<el-select <el-select
v-model="listQuery.tenantId" v-model="listQuery.tenantId"
placeholder="租户(必填)" :placeholder="$t('tenantManage.tenantRequired')"
style="width: 220px" style="width: 220px"
filterable filterable
class="filter-item" class="filter-item"
@ -18,7 +18,7 @@
</el-select> </el-select>
<el-select <el-select
v-model="listQuery.itemId" v-model="listQuery.itemId"
placeholder="项目(必填)" :placeholder="$t('projectManage.itemRequired')"
style="width: 220px" style="width: 220px"
filterable filterable
class="filter-item" class="filter-item"
@ -33,7 +33,7 @@
</el-select> </el-select>
<el-select <el-select
v-model="listQuery.threadPoolKey" v-model="listQuery.threadPoolKey"
placeholder="线程池标识(必填)" :placeholder="$t('frameworkThreadPool.threadPoolIDRequired')"
style="width: 220px" style="width: 220px"
filterable filterable
class="filter-item" class="filter-item"
@ -52,7 +52,7 @@
icon="el-icon-search" icon="el-icon-search"
@click="fetchData" @click="fetchData"
> >
搜索 {{ $t('common.query') }}
</el-button> </el-button>
<el-button <el-button
v-waves v-waves
@ -62,7 +62,7 @@
icon="el-icon-refresh" icon="el-icon-refresh"
@click="refreshData" @click="refreshData"
> >
重置 {{ $t('common.reset') }}
</el-button> </el-button>
</div> </div>
<el-table <el-table
@ -74,32 +74,32 @@
max-height="714" max-height="714"
highlight-current-row highlight-current-row
> >
<el-table-column label="序号" width="95"> <el-table-column :label="$t('common.num')" fixed width="95">
<template slot-scope="scope">{{ scope.$index + 1 }}</template> <template slot-scope="scope">{{ scope.$index + 1 }}</template>
</el-table-column> </el-table-column>
<el-table-column label="实例标识" width="260"> <el-table-column :label="$t('threadPoolInstance.instanceID')" width="260">
<template slot-scope="scope"> <template slot-scope="scope">
<el-link type="primary" :underline="false">{{ scope.row.identify }}</el-link> <el-link type="primary" :underline="false">{{ scope.row.identify }}</el-link>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="Active"> <el-table-column :label="$t('threadPoolInstance.active')" width="120">
<template slot-scope="scope"> <template slot-scope="scope">
<el-tag :type="scope.row.active | statusFilter"> <el-tag :type="scope.row.active | statusFilter">
{{ scope.row.active }} {{ scope.row.active }}
</el-tag> </el-tag>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="线程池标识"> <el-table-column :label="$t('frameworkThreadPool.threadPoolID')">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.threadPoolKey }} {{ scope.row.threadPoolKey }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="核心线程"> <el-table-column :label="$t('threadPool.coreSize')">
<template slot-scope="scope"> <template slot-scope="scope">
<el-link type="success" :underline="false">{{ scope.row.coreSize }}</el-link> <el-link type="success" :underline="false">{{ scope.row.coreSize }}</el-link>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="最大线程"> <el-table-column :label="$t('threadPool.maximumSize')" width="120">
<template slot-scope="scope"> <template slot-scope="scope">
<el-link type="danger" :underline="false">{{ scope.row.maximumSize }}</el-link> <el-link type="danger" :underline="false">{{ scope.row.maximumSize }}</el-link>
</template> </template>
@ -110,7 +110,7 @@
<el-table-column label="队列容量" > <el-table-column label="队列容量" >
<template slot-scope="scope">{{ scope.row.queueCapacity }}</template> <template slot-scope="scope">{{ scope.row.queueCapacity }}</template>
</el-table-column>--> </el-table-column>-->
<el-table-column label="操作" width="180" class-name="small-padding fixed-width"> <el-table-column :label="$t('common.operation')" width="180" class-name="small-padding fixed-width">
<template slot-scope="{ row }"> <template slot-scope="{ row }">
<!--<el-dropdown trigger="click"> <!--<el-dropdown trigger="click">
<span class="el-dropdown-link"> <span class="el-dropdown-link">
@ -121,7 +121,7 @@
<el-dropdown-item @click.native="handleUpdate(row)">编辑</el-dropdown-item> <el-dropdown-item @click.native="handleUpdate(row)">编辑</el-dropdown-item>
</el-dropdown-menu> </el-dropdown-menu>
</el-dropdown>--> </el-dropdown>-->
<el-button type="text" size="small" @click="handleUpdate(row)"> </el-button> <el-button type="text" size="small" @click="handleUpdate(row)"> {{ $t('common.edit') }} </el-button>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
@ -133,7 +133,7 @@
label-position="left" label-position="left"
label-width="110px" label-width="110px"
> >
<el-form-item label="核心线程" prop="coreSize"> <el-form-item :label="$t('threadPool.coreSize')" prop="coreSize">
<template> <template>
<el-input-number <el-input-number
v-model="temp.coreSize" v-model="temp.coreSize"
@ -143,7 +143,7 @@
></el-input-number> ></el-input-number>
</template> </template>
</el-form-item> </el-form-item>
<el-form-item label="最大线程" prop="maximumSize"> <el-form-item :label="$t('threadPool.maximumSize')" prop="maximumSize">
<template> <template>
<el-input-number <el-input-number
v-model="temp.maximumSize" v-model="temp.maximumSize"
@ -153,13 +153,13 @@
></el-input-number> ></el-input-number>
</template> </template>
</el-form-item> </el-form-item>
<el-form-item label="全部修改" prop="allUpdate"> <el-form-item :label="$t('threadPoolInstance.changeAll')" prop="allUpdate">
<el-switch v-model="temp.allUpdate"></el-switch> <el-switch v-model="temp.allUpdate"></el-switch>
</el-form-item> </el-form-item>
</el-form> </el-form>
<div slot="footer" class="dialog-footer"> <div slot="footer" class="dialog-footer">
<el-button @click="dialogFormVisible = false"> 取消 </el-button> <el-button @click="dialogFormVisible = false"> {{ $t('common.cancel') }} </el-button>
<el-button type="primary" @click="updateData()"> </el-button> <el-button type="primary" @click="updateData()"> {{$t('common.confirm')}} </el-button>
</div> </div>
</el-dialog> </el-dialog>
<el-dialog :visible.sync="dialogPluginVisible" title="Reading statistics"> <el-dialog :visible.sync="dialogPluginVisible" title="Reading statistics">
@ -282,19 +282,19 @@ export default {
}, },
fetchData() { fetchData() {
if (!this.listQuery.mark) { if (!this.listQuery.mark) {
this.$message.warning('线程池类型不允许为空'); this.$message.warning(this.$t('message.emptyWarning', { name: this. $t('frameworkThreadPool.threadPoolType') }));
return; return;
} }
if (!this.listQuery.tenantId) { if (!this.listQuery.tenantId) {
this.$message.warning('租户不允许为空'); this.$message.warning(this.$t('message.emptyWarning', { name: this.$t('tenantManage.tenant') }));
return; return;
} }
if (!this.listQuery.itemId) { if (!this.listQuery.itemId) {
this.$message.warning('项目不允许为空'); this.$message.warning(this.$t('message.emptyWarning', { name: this.$t('projectManage.item') }));
return; return;
} }
if (!this.listQuery.threadPoolKey) { if (!this.listQuery.threadPoolKey) {
this.$message.warning('线程池标识不允许为空'); this.$message.warning(this.$t('message.emptyWarning', { name: this. $t('frameworkThreadPool.threadPoolID') }));
return; return;
} }
this.listLoading = true; this.listLoading = true;
@ -332,7 +332,7 @@ export default {
if (valid) { if (valid) {
if (parseInt(this.temp.maximumSize) < parseInt(this.temp.coreSize)) { if (parseInt(this.temp.maximumSize) < parseInt(this.temp.coreSize)) {
this.$message({ this.$message({
message: '最大线程必须大于等于核心线程', message: this.$t('threadPool.threadsNumErrorTip'),
type: 'warning', type: 'warning',
}); });
return; return;
@ -384,13 +384,13 @@ export default {
}) })
.catch((error) => { .catch((error) => {
console.log(error); console.log(error);
this.$message.error('修改线程池失败'); this.$message.error(this.$t('message.updateFailure'));
}); });
}, },
openDelConfirm(name) { openDelConfirm(name) {
return this.$confirm(`此操作将删除 ${name}, 是否继续?`, '提示', { return this.$confirm(this.$t('message.deleteMessage', { name }), this.$t('common.hint'), {
confirmButtonText: '确定', confirmButtonText: this.$t('common.ok'),
cancelButtonText: '取消', cancelButtonText: this.$t('common.cancel'),
type: 'warning', type: 'warning',
}); });
}, },
@ -496,7 +496,7 @@ export default {
}) })
.catch((error) => { .catch((error) => {
console.log(error); console.log(error);
this.$message.error('查询失败,请尝试刷新页面'); this.$message.error(this.$t('message.queryFailure'));
}); });
}, },
}, },

@ -3,7 +3,7 @@
<div class="filter-container"> <div class="filter-container">
<el-select <el-select
v-model="listQuery.tenantId" v-model="listQuery.tenantId"
placeholder="租户(必填)" :placeholder="$t('tenantManage.tenantRequired')"
style="width: 220px" style="width: 220px"
filterable filterable
class="filter-item" class="filter-item"
@ -18,7 +18,7 @@
</el-select> </el-select>
<el-select <el-select
v-model="listQuery.itemId" v-model="listQuery.itemId"
placeholder="项目(必填)" :placeholder="$t('projectManage.itemRequired')"
style="width: 220px" style="width: 220px"
filterable filterable
class="filter-item" class="filter-item"
@ -33,7 +33,7 @@
</el-select> </el-select>
<el-select <el-select
v-model="listQuery.threadPoolKey" v-model="listQuery.threadPoolKey"
placeholder="线程池标识(必填)" :placeholder="$t('frameworkThreadPool.threadPoolIDRequired')"
style="width: 220px" style="width: 220px"
filterable filterable
class="filter-item" class="filter-item"
@ -52,7 +52,7 @@
icon="el-icon-search" icon="el-icon-search"
@click="fetchData" @click="fetchData"
> >
搜索 {{ $t('common.query') }}
</el-button> </el-button>
<el-button <el-button
v-waves v-waves
@ -62,7 +62,7 @@
icon="el-icon-refresh" icon="el-icon-refresh"
@click="refreshData" @click="refreshData"
> >
重置 {{ $t('common.reset') }}
</el-button> </el-button>
</div> </div>
<el-table <el-table
@ -74,32 +74,32 @@
max-height="714" max-height="714"
highlight-current-row highlight-current-row
> >
<el-table-column label="序号" width="95"> <el-table-column :label="$t('common.num')" fixed width="95">
<template slot-scope="scope">{{ scope.$index + 1 }}</template> <template slot-scope="scope">{{ scope.$index + 1 }}</template>
</el-table-column> </el-table-column>
<el-table-column label="实例标识" width="260"> <el-table-column :label="$t('threadPoolInstance.instanceID')" width="260">
<template slot-scope="scope"> <template slot-scope="scope">
<el-link type="primary" :underline="false">{{ scope.row.identify }}</el-link> <el-link type="primary" :underline="false">{{ scope.row.identify }}</el-link>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="Active"> <el-table-column :label="$t('threadPoolInstance.active')" width="120">
<template slot-scope="scope"> <template slot-scope="scope">
<el-tag :type="scope.row.active | statusFilter"> <el-tag :type="scope.row.active | statusFilter">
{{ scope.row.active }} {{ scope.row.active }}
</el-tag> </el-tag>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="线程池标识"> <el-table-column :label="$t('frameworkThreadPool.threadPoolID')">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.threadPoolKey }} {{ scope.row.threadPoolKey }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="核心线程"> <el-table-column :label="$t('threadPool.coreSize')">
<template slot-scope="scope"> <template slot-scope="scope">
<el-link type="success" :underline="false">{{ scope.row.coreSize }}</el-link> <el-link type="success" :underline="false">{{ scope.row.coreSize }}</el-link>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="最大线程"> <el-table-column :label="$t('threadPool.maximumSize')" width="120">
<template slot-scope="scope"> <template slot-scope="scope">
<el-link type="danger" :underline="false">{{ scope.row.maximumSize }}</el-link> <el-link type="danger" :underline="false">{{ scope.row.maximumSize }}</el-link>
</template> </template>
@ -110,7 +110,7 @@
<el-table-column label="队列容量" > <el-table-column label="队列容量" >
<template slot-scope="scope">{{ scope.row.queueCapacity }}</template> <template slot-scope="scope">{{ scope.row.queueCapacity }}</template>
</el-table-column>--> </el-table-column>-->
<el-table-column label="操作" width="180" class-name="small-padding fixed-width"> <el-table-column :label="$t('common.operation')" width="180" class-name="small-padding fixed-width">
<template slot-scope="{ row }"> <template slot-scope="{ row }">
<!--<el-dropdown trigger="click"> <!--<el-dropdown trigger="click">
<span class="el-dropdown-link"> <span class="el-dropdown-link">
@ -121,7 +121,7 @@
<el-dropdown-item @click.native="handleUpdate(row)">编辑</el-dropdown-item> <el-dropdown-item @click.native="handleUpdate(row)">编辑</el-dropdown-item>
</el-dropdown-menu> </el-dropdown-menu>
</el-dropdown>--> </el-dropdown>-->
<el-button type="text" size="small" @click="handleUpdate(row)"> </el-button> <el-button type="text" size="small" @click="handleUpdate(row)"> {{ $t('common.edit') }} </el-button>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
@ -134,7 +134,7 @@
label-position="left" label-position="left"
label-width="110px" label-width="110px"
> >
<el-form-item label="核心线程" prop="coreSize"> <el-form-item :label="$t('threadPool.coreSize')" prop="coreSize">
<template> <template>
<el-input-number <el-input-number
v-model="temp.coreSize" v-model="temp.coreSize"
@ -144,7 +144,7 @@
></el-input-number> ></el-input-number>
</template> </template>
</el-form-item> </el-form-item>
<el-form-item label="最大线程" prop="maximumSize"> <el-form-item :label="$t('threadPool.maximumSize')" prop="maximumSize">
<template> <template>
<el-input-number <el-input-number
v-model="temp.maximumSize" v-model="temp.maximumSize"
@ -154,13 +154,13 @@
></el-input-number> ></el-input-number>
</template> </template>
</el-form-item> </el-form-item>
<el-form-item label="全部修改" prop="allUpdate"> <el-form-item :label="$t('threadPoolInstance.changeAll')" prop="allUpdate">
<el-switch v-model="temp.allUpdate"></el-switch> <el-switch v-model="temp.allUpdate"></el-switch>
</el-form-item> </el-form-item>
</el-form> </el-form>
<div slot="footer" class="dialog-footer"> <div slot="footer" class="dialog-footer">
<el-button @click="dialogFormVisible = false"> 取消 </el-button> <el-button @click="dialogFormVisible = false"> {{ $t('common.cancel') }} </el-button>
<el-button type="primary" @click="updateData()"> </el-button> <el-button type="primary" @click="updateData()"> {{$t('common.confirm')}} </el-button>
</div> </div>
</el-dialog> </el-dialog>
<el-dialog :visible.sync="dialogPluginVisible" title="Reading statistics"> <el-dialog :visible.sync="dialogPluginVisible" title="Reading statistics">
@ -283,19 +283,19 @@ export default {
}, },
fetchData() { fetchData() {
if (!this.listQuery.mark) { if (!this.listQuery.mark) {
this.$message.warning('线程池类型不允许为空'); this.$message.warning(this.$t('message.emptyWarning', { name: this. $t('frameworkThreadPool.threadPoolType') }));
return; return;
} }
if (!this.listQuery.tenantId) { if (!this.listQuery.tenantId) {
this.$message.warning('租户不允许为空'); this.$message.warning(this.$t('message.emptyWarning', { name: this.$t('tenantManage.tenant') }));
return; return;
} }
if (!this.listQuery.itemId) { if (!this.listQuery.itemId) {
this.$message.warning('项目不允许为空'); this.$message.warning(this.$t('message.emptyWarning', { name: this.$t('projectManage.item') }));
return; return;
} }
if (!this.listQuery.threadPoolKey) { if (!this.listQuery.threadPoolKey) {
this.$message.warning('线程池标识不允许为空'); this.$message.warning(this.$t('message.emptyWarning', { name: this. $t('frameworkThreadPool.threadPoolID') }));
return; return;
} }
this.listLoading = true; this.listLoading = true;
@ -333,7 +333,7 @@ export default {
if (valid) { if (valid) {
if (parseInt(this.temp.maximumSize) < parseInt(this.temp.coreSize)) { if (parseInt(this.temp.maximumSize) < parseInt(this.temp.coreSize)) {
this.$message({ this.$message({
message: '最大线程必须大于等于核心线程', message: this.$t('threadPool.threadsNumErrorTip'),
type: 'warning', type: 'warning',
}); });
return; return;
@ -381,13 +381,13 @@ export default {
}) })
.catch((error) => { .catch((error) => {
console.log(error); console.log(error);
this.$message.error('修改线程池失败'); this.$message.error(this.$t('message.updateFailure'));
}); });
}, },
openDelConfirm(name) { openDelConfirm(name) {
return this.$confirm(`此操作将删除 ${name}, 是否继续?`, '提示', { return this.$confirm(this.$t('message.deleteMessage', { name }), this.$t('common.hint'), {
confirmButtonText: '确定', confirmButtonText: this.$t('common.ok'),
cancelButtonText: '取消', cancelButtonText: this.$t('common.cancel'),
type: 'warning', type: 'warning',
}); });
}, },
@ -493,7 +493,7 @@ export default {
}) })
.catch((error) => { .catch((error) => {
console.log(error); console.log(error);
this.$message.error('查询失败,请尝试刷新页面'); this.$message.error(this.$t('message.queryFailure'));
}); });
}, },
}, },

@ -3,7 +3,7 @@
<div class="filter-container"> <div class="filter-container">
<el-select <el-select
v-model="listQuery.tenantId" v-model="listQuery.tenantId"
placeholder="租户(必填)" :placeholder="$t('tenantManage.tenantRequired')"
style="width: 220px" style="width: 220px"
filterable filterable
class="filter-item" class="filter-item"
@ -18,7 +18,7 @@
</el-select> </el-select>
<el-select <el-select
v-model="listQuery.itemId" v-model="listQuery.itemId"
placeholder="项目(必填)" :placeholder="$t('projectManage.itemRequired')"
style="width: 220px" style="width: 220px"
filterable filterable
class="filter-item" class="filter-item"
@ -33,7 +33,7 @@
</el-select> </el-select>
<el-select <el-select
v-model="listQuery.threadPoolKey" v-model="listQuery.threadPoolKey"
placeholder="线程池标识(必填)" :placeholder="$t('frameworkThreadPool.threadPoolIDRequired')"
style="width: 220px" style="width: 220px"
filterable filterable
class="filter-item" class="filter-item"
@ -52,7 +52,7 @@
icon="el-icon-search" icon="el-icon-search"
@click="fetchData" @click="fetchData"
> >
搜索 {{ $t('common.query') }}
</el-button> </el-button>
<el-button <el-button
v-waves v-waves
@ -62,7 +62,7 @@
icon="el-icon-refresh" icon="el-icon-refresh"
@click="refreshData" @click="refreshData"
> >
重置 {{ $t('common.reset') }}
</el-button> </el-button>
</div> </div>
<el-table <el-table
@ -74,32 +74,32 @@
max-height="714" max-height="714"
highlight-current-row highlight-current-row
> >
<el-table-column label="序号" width="95"> <el-table-column :label="$t('common.num')" fixed width="95">
<template slot-scope="scope">{{ scope.$index + 1 }}</template> <template slot-scope="scope">{{ scope.$index + 1 }}</template>
</el-table-column> </el-table-column>
<el-table-column label="实例标识" width="260"> <el-table-column :label="$t('threadPoolInstance.instanceID')" width="260">
<template slot-scope="scope"> <template slot-scope="scope">
<el-link type="primary" :underline="false">{{ scope.row.identify }}</el-link> <el-link type="primary" :underline="false">{{ scope.row.identify }}</el-link>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="Active"> <el-table-column :label="$t('threadPoolInstance.active')" width="120">
<template slot-scope="scope"> <template slot-scope="scope">
<el-tag :type="scope.row.active | statusFilter"> <el-tag :type="scope.row.active | statusFilter">
{{ scope.row.active }} {{ scope.row.active }}
</el-tag> </el-tag>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="线程池标识"> <el-table-column :label="$t('frameworkThreadPool.threadPoolID')">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.threadPoolKey }} {{ scope.row.threadPoolKey }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="核心线程"> <el-table-column :label="$t('threadPool.coreSize')">
<template slot-scope="scope"> <template slot-scope="scope">
<el-link type="success" :underline="false">{{ scope.row.coreSize }}</el-link> <el-link type="success" :underline="false">{{ scope.row.coreSize }}</el-link>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="最大线程"> <el-table-column :label="$t('threadPool.maximumSize')" width="120">
<template slot-scope="scope"> <template slot-scope="scope">
<el-link type="danger" :underline="false">{{ scope.row.maximumSize }}</el-link> <el-link type="danger" :underline="false">{{ scope.row.maximumSize }}</el-link>
</template> </template>
@ -110,7 +110,7 @@
<el-table-column label="队列容量" > <el-table-column label="队列容量" >
<template slot-scope="scope">{{ scope.row.queueCapacity }}</template> <template slot-scope="scope">{{ scope.row.queueCapacity }}</template>
</el-table-column>--> </el-table-column>-->
<el-table-column label="操作" width="180" class-name="small-padding fixed-width"> <el-table-column :label="$t('common.operation')" width="180" class-name="small-padding fixed-width">
<template slot-scope="{ row }"> <template slot-scope="{ row }">
<!--<el-dropdown trigger="click"> <!--<el-dropdown trigger="click">
<span class="el-dropdown-link"> <span class="el-dropdown-link">
@ -121,7 +121,7 @@
<el-dropdown-item @click.native="handleUpdate(row)">编辑</el-dropdown-item> <el-dropdown-item @click.native="handleUpdate(row)">编辑</el-dropdown-item>
</el-dropdown-menu> </el-dropdown-menu>
</el-dropdown>--> </el-dropdown>-->
<el-button type="text" size="small" @click="handleUpdate(row)"> </el-button> <el-button type="text" size="small" @click="handleUpdate(row)"> {{ $t('common.edit') }} </el-button>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
@ -133,7 +133,7 @@
label-position="left" label-position="left"
label-width="110px" label-width="110px"
> >
<el-form-item label="核心线程" prop="coreSize"> <el-form-item :label="$t('threadPool.coreSize')" prop="coreSize">
<template> <template>
<el-input-number <el-input-number
v-model="temp.coreSize" v-model="temp.coreSize"
@ -143,7 +143,7 @@
></el-input-number> ></el-input-number>
</template> </template>
</el-form-item> </el-form-item>
<el-form-item label="最大线程" prop="maximumSize"> <el-form-item :label="$t('threadPool.maximumSize')" prop="maximumSize">
<template> <template>
<el-input-number <el-input-number
v-model="temp.maximumSize" v-model="temp.maximumSize"
@ -153,13 +153,13 @@
></el-input-number> ></el-input-number>
</template> </template>
</el-form-item> </el-form-item>
<el-form-item label="全部修改" prop="allUpdate"> <el-form-item :label="$t('threadPoolInstance.changeAll')" prop="allUpdate">
<el-switch v-model="temp.allUpdate"></el-switch> <el-switch v-model="temp.allUpdate"></el-switch>
</el-form-item> </el-form-item>
</el-form> </el-form>
<div slot="footer" class="dialog-footer"> <div slot="footer" class="dialog-footer">
<el-button @click="dialogFormVisible = false"> 取消 </el-button> <el-button @click="dialogFormVisible = false"> {{ $t('common.cancel') }} </el-button>
<el-button type="primary" @click="updateData()"> </el-button> <el-button type="primary" @click="updateData()"> {{$t('common.confirm')}} </el-button>
</div> </div>
</el-dialog> </el-dialog>
<el-dialog :visible.sync="dialogPluginVisible" title="Reading statistics"> <el-dialog :visible.sync="dialogPluginVisible" title="Reading statistics">
@ -282,19 +282,19 @@ export default {
}, },
fetchData() { fetchData() {
if (!this.listQuery.mark) { if (!this.listQuery.mark) {
this.$message.warning('线程池类型不允许为空'); this.$message.warning(this.$t('message.emptyWarning', { name: this. $t('frameworkThreadPool.threadPoolType') }));
return; return;
} }
if (!this.listQuery.tenantId) { if (!this.listQuery.tenantId) {
this.$message.warning('租户不允许为空'); this.$message.warning(this.$t('message.emptyWarning', { name: this.$t('tenantManage.tenant') }));
return; return;
} }
if (!this.listQuery.itemId) { if (!this.listQuery.itemId) {
this.$message.warning('项目不允许为空'); this.$message.warning(this.$t('message.emptyWarning', { name: this.$t('projectManage.item') }));
return; return;
} }
if (!this.listQuery.threadPoolKey) { if (!this.listQuery.threadPoolKey) {
this.$message.warning('线程池标识不允许为空'); this.$message.warning(this.$t('message.emptyWarning', { name: this. $t('frameworkThreadPool.threadPoolID') }));
return; return;
} }
this.listLoading = true; this.listLoading = true;
@ -332,7 +332,7 @@ export default {
if (valid) { if (valid) {
if (parseInt(this.temp.maximumSize) < parseInt(this.temp.coreSize)) { if (parseInt(this.temp.maximumSize) < parseInt(this.temp.coreSize)) {
this.$message({ this.$message({
message: '最大线程必须大于等于核心线程', message: this.$t('threadPool.threadsNumErrorTip'),
type: 'warning', type: 'warning',
}); });
return; return;
@ -384,13 +384,13 @@ export default {
}) })
.catch((error) => { .catch((error) => {
console.log(error); console.log(error);
this.$message.error('修改线程池失败'); this.$message.error(this.$t('message.updateFailure'));
}); });
}, },
openDelConfirm(name) { openDelConfirm(name) {
return this.$confirm(`此操作将删除 ${name}, 是否继续?`, '提示', { return this.$confirm(this.$t('message.deleteMessage', { name }), this.$t('common.hint'), {
confirmButtonText: '确定', confirmButtonText: this.$t('common.ok'),
cancelButtonText: '取消', cancelButtonText: this.$t('common.cancel'),
type: 'warning', type: 'warning',
}); });
}, },
@ -496,7 +496,7 @@ export default {
}) })
.catch((error) => { .catch((error) => {
console.log(error); console.log(error);
this.$message.error('查询失败,请尝试刷新页面'); this.$message.error(this.$t('message.queryFailure'));
}); });
}, },
}, },

@ -3,7 +3,7 @@
<div class="filter-container"> <div class="filter-container">
<el-select <el-select
v-model="listQuery.tenantId" v-model="listQuery.tenantId"
placeholder="租户(必填)" :placeholder="$t('tenantManage.tenantRequired')"
style="width: 220px" style="width: 220px"
filterable filterable
class="filter-item" class="filter-item"
@ -18,7 +18,7 @@
</el-select> </el-select>
<el-select <el-select
v-model="listQuery.itemId" v-model="listQuery.itemId"
placeholder="项目(必填)" :placeholder="$t('projectManage.itemRequired')"
style="width: 220px" style="width: 220px"
filterable filterable
class="filter-item" class="filter-item"
@ -33,7 +33,7 @@
</el-select> </el-select>
<el-select <el-select
v-model="listQuery.threadPoolKey" v-model="listQuery.threadPoolKey"
placeholder="线程池标识(必填)" :placeholder="$t('frameworkThreadPool.threadPoolIDRequired')"
style="width: 220px" style="width: 220px"
filterable filterable
class="filter-item" class="filter-item"
@ -52,7 +52,7 @@
icon="el-icon-search" icon="el-icon-search"
@click="fetchData" @click="fetchData"
> >
搜索 {{ $t('common.query') }}
</el-button> </el-button>
<el-button <el-button
v-waves v-waves
@ -62,7 +62,7 @@
icon="el-icon-refresh" icon="el-icon-refresh"
@click="refreshData" @click="refreshData"
> >
重置 {{ $t('common.reset') }}
</el-button> </el-button>
</div> </div>
<el-table <el-table
@ -74,32 +74,32 @@
max-height="714" max-height="714"
highlight-current-row highlight-current-row
> >
<el-table-column label="序号" width="95"> <el-table-column :label="$t('common.num')" fixed width="95">
<template slot-scope="scope">{{ scope.$index + 1 }}</template> <template slot-scope="scope">{{ scope.$index + 1 }}</template>
</el-table-column> </el-table-column>
<el-table-column label="实例标识" width="260"> <el-table-column :label="$t('threadPoolInstance.instanceID')" width="260">
<template slot-scope="scope"> <template slot-scope="scope">
<el-link type="primary" :underline="false">{{ scope.row.identify }}</el-link> <el-link type="primary" :underline="false">{{ scope.row.identify }}</el-link>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="Active"> <el-table-column :label="$t('threadPoolInstance.active')" width="120">
<template slot-scope="scope"> <template slot-scope="scope">
<el-tag :type="scope.row.active | statusFilter"> <el-tag :type="scope.row.active | statusFilter">
{{ scope.row.active }} {{ scope.row.active }}
</el-tag> </el-tag>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="线程池标识"> <el-table-column :label="$t('frameworkThreadPool.threadPoolID')">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.threadPoolKey }} {{ scope.row.threadPoolKey }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="核心线程"> <el-table-column :label="$t('threadPool.coreSize')">
<template slot-scope="scope"> <template slot-scope="scope">
<el-link type="success" :underline="false">{{ scope.row.coreSize }}</el-link> <el-link type="success" :underline="false">{{ scope.row.coreSize }}</el-link>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="最大线程"> <el-table-column :label="$t('threadPool.maximumSize')" width="120">
<template slot-scope="scope"> <template slot-scope="scope">
<el-link type="danger" :underline="false">{{ scope.row.maximumSize }}</el-link> <el-link type="danger" :underline="false">{{ scope.row.maximumSize }}</el-link>
</template> </template>
@ -110,7 +110,7 @@
<el-table-column label="队列容量" > <el-table-column label="队列容量" >
<template slot-scope="scope">{{ scope.row.queueCapacity }}</template> <template slot-scope="scope">{{ scope.row.queueCapacity }}</template>
</el-table-column>--> </el-table-column>-->
<el-table-column label="操作" width="180" class-name="small-padding fixed-width"> <el-table-column :label="$t('common.operation')" width="180" class-name="small-padding fixed-width">
<template slot-scope="{ row }"> <template slot-scope="{ row }">
<!--<el-dropdown trigger="click"> <!--<el-dropdown trigger="click">
<span class="el-dropdown-link"> <span class="el-dropdown-link">
@ -121,7 +121,7 @@
<el-dropdown-item @click.native="handleUpdate(row)">编辑</el-dropdown-item> <el-dropdown-item @click.native="handleUpdate(row)">编辑</el-dropdown-item>
</el-dropdown-menu> </el-dropdown-menu>
</el-dropdown>--> </el-dropdown>-->
<el-button type="text" size="small" @click="handleUpdate(row)"> </el-button> <el-button type="text" size="small" @click="handleUpdate(row)"> {{ $t('common.edit') }} </el-button>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
@ -134,7 +134,7 @@
label-position="left" label-position="left"
label-width="110px" label-width="110px"
> >
<el-form-item label="核心线程" prop="coreSize"> <el-form-item :label="$t('threadPool.coreSize')" prop="coreSize">
<template> <template>
<el-input-number <el-input-number
v-model="temp.coreSize" v-model="temp.coreSize"
@ -144,7 +144,7 @@
></el-input-number> ></el-input-number>
</template> </template>
</el-form-item> </el-form-item>
<el-form-item label="最大线程" prop="maximumSize"> <el-form-item :label="$t('threadPool.maximumSize')" prop="maximumSize">
<template> <template>
<el-input-number <el-input-number
v-model="temp.maximumSize" v-model="temp.maximumSize"
@ -154,13 +154,13 @@
></el-input-number> ></el-input-number>
</template> </template>
</el-form-item> </el-form-item>
<el-form-item label="全部修改" prop="allUpdate"> <el-form-item :label="$t('threadPoolInstance.changeAll')" prop="allUpdate">
<el-switch v-model="temp.allUpdate"></el-switch> <el-switch v-model="temp.allUpdate"></el-switch>
</el-form-item> </el-form-item>
</el-form> </el-form>
<div slot="footer" class="dialog-footer"> <div slot="footer" class="dialog-footer">
<el-button @click="dialogFormVisible = false"> 取消 </el-button> <el-button @click="dialogFormVisible = false"> {{ $t('common.cancel') }} </el-button>
<el-button type="primary" @click="updateData()"> </el-button> <el-button type="primary" @click="updateData()"> {{$t('common.confirm')}} </el-button>
</div> </div>
</el-dialog> </el-dialog>
<el-dialog :visible.sync="dialogPluginVisible" title="Reading statistics"> <el-dialog :visible.sync="dialogPluginVisible" title="Reading statistics">
@ -283,19 +283,19 @@ export default {
}, },
fetchData() { fetchData() {
if (!this.listQuery.mark) { if (!this.listQuery.mark) {
this.$message.warning('线程池类型不允许为空'); this.$message.warning(this.$t('message.emptyWarning', { name: this. $t('frameworkThreadPool.threadPoolType') }));
return; return;
} }
if (!this.listQuery.tenantId) { if (!this.listQuery.tenantId) {
this.$message.warning('租户不允许为空'); this.$message.warning(this.$t('message.emptyWarning', { name: this.$t('tenantManage.tenant') }));
return; return;
} }
if (!this.listQuery.itemId) { if (!this.listQuery.itemId) {
this.$message.warning('项目不允许为空'); this.$message.warning(this.$t('message.emptyWarning', { name: this.$t('projectManage.item') }));
return; return;
} }
if (!this.listQuery.threadPoolKey) { if (!this.listQuery.threadPoolKey) {
this.$message.warning('线程池标识不允许为空'); this.$message.warning(this.$t('message.emptyWarning', { name: this. $t('frameworkThreadPool.threadPoolID') }));
return; return;
} }
this.listLoading = true; this.listLoading = true;
@ -333,7 +333,7 @@ export default {
if (valid) { if (valid) {
if (parseInt(this.temp.maximumSize) < parseInt(this.temp.coreSize)) { if (parseInt(this.temp.maximumSize) < parseInt(this.temp.coreSize)) {
this.$message({ this.$message({
message: '最大线程必须大于等于核心线程', message: this.$t('threadPool.threadsNumErrorTip'),
type: 'warning', type: 'warning',
}); });
return; return;
@ -385,13 +385,13 @@ export default {
}) })
.catch((error) => { .catch((error) => {
console.log(error); console.log(error);
this.$message.error('修改线程池失败'); this.$message.error(this.$t('message.updateFailure'));
}); });
}, },
openDelConfirm(name) { openDelConfirm(name) {
return this.$confirm(`此操作将删除 ${name}, 是否继续?`, '提示', { return this.$confirm(this.$t('message.deleteMessage', { name }), this.$t('common.hint'), {
confirmButtonText: '确定', confirmButtonText: this.$t('common.ok'),
cancelButtonText: '取消', cancelButtonText: this.$t('common.cancel'),
type: 'warning', type: 'warning',
}); });
}, },
@ -497,7 +497,7 @@ export default {
}) })
.catch((error) => { .catch((error) => {
console.log(error); console.log(error);
this.$message.error('查询失败,请尝试刷新页面'); this.$message.error(this.$t('message.queryFailure'));
}); });
}, },
}, },

Loading…
Cancel
Save