mirror of
https://gitee.com/dromara/RuoYi-Vue-Plus.git
synced 2026-09-20 02:08:15 +08:00
复制文本功能
This commit is contained in:
parent
71817249c8
commit
7a39478e83
@ -82,7 +82,12 @@
|
|||||||
</router-link>
|
</router-link>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="应用密钥" align="center" prop="accessKey" />
|
<el-table-column label="应用密钥" align="center" prop="accessKey">
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<span>{{ scope.row.accessKey }} </span>
|
||||||
|
<i class="el-icon-copy-document" style="color: #4A8DFF" @click="handleCopy(scope.row.accessKey)" title="复制"/>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
<el-table-column label="更新者" align="center" prop="updateBy" />
|
<el-table-column label="更新者" align="center" prop="updateBy" />
|
||||||
<el-table-column label="更新时间" align="center" prop="updateTime" width="180">
|
<el-table-column label="更新时间" align="center" prop="updateTime" width="180">
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
@ -254,6 +259,19 @@ export default {
|
|||||||
this.title = "修改应用信息";
|
this.title = "修改应用信息";
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
// 复制ak
|
||||||
|
handleCopy(data) {
|
||||||
|
let oInput = document.createElement('input')
|
||||||
|
oInput.value = data
|
||||||
|
document.body.appendChild(oInput)
|
||||||
|
oInput.select()
|
||||||
|
document.execCommand('copy')
|
||||||
|
this.$message({
|
||||||
|
message: '复制成功',
|
||||||
|
type: 'success'
|
||||||
|
})
|
||||||
|
oInput.remove()
|
||||||
|
},
|
||||||
/** 提交按钮 */
|
/** 提交按钮 */
|
||||||
submitForm() {
|
submitForm() {
|
||||||
this.$refs["form"].validate(valid => {
|
this.$refs["form"].validate(valid => {
|
||||||
|
|||||||
@ -88,7 +88,12 @@
|
|||||||
<el-table-column type="selection" width="55" align="center" :selectable="selectable"/>
|
<el-table-column type="selection" width="55" align="center" :selectable="selectable"/>
|
||||||
<el-table-column label="应用服务ID" align="center" prop="appServiceId" v-if="false"/>
|
<el-table-column label="应用服务ID" align="center" prop="appServiceId" v-if="false"/>
|
||||||
<el-table-column label="服务名称" align="left" prop="serviceName" />
|
<el-table-column label="服务名称" align="left" prop="serviceName" />
|
||||||
<el-table-column label="虚拟地址" align="left" prop="virtualAddr" />
|
<el-table-column label="虚拟地址" align="left" prop="virtualAddr">
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<span :title="scope.row.virtualAddr" v-text="handleVirtualAddr(scope.row.virtualAddr)"></span>
|
||||||
|
<i class="el-icon-copy-document" style="color: #4A8DFF" @click="handleCopy(scope.row.virtualAddr)" title="复制"/>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
<el-table-column label="审核状态" align="center" prop="status" width="100">
|
<el-table-column label="审核状态" align="center" prop="status" width="100">
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<dict-tag :options="statusOptions" :value="scope.row.status"/>
|
<dict-tag :options="statusOptions" :value="scope.row.status"/>
|
||||||
@ -256,7 +261,9 @@ export default {
|
|||||||
pageSize: 10,
|
pageSize: 10,
|
||||||
enabled: undefined,
|
enabled: undefined,
|
||||||
status: undefined,
|
status: undefined,
|
||||||
applicationId: undefined
|
applicationId: undefined,
|
||||||
|
orderByColumn: 'update_time',
|
||||||
|
isAsc: 'desc'
|
||||||
},
|
},
|
||||||
applicationName: undefined,
|
applicationName: undefined,
|
||||||
applicationId: undefined,
|
applicationId: undefined,
|
||||||
@ -399,6 +406,23 @@ export default {
|
|||||||
this.title = "应用服务续期";
|
this.title = "应用服务续期";
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
// 复制地址
|
||||||
|
handleCopy(data) {
|
||||||
|
let oInput = document.createElement('input')
|
||||||
|
oInput.value = data
|
||||||
|
document.body.appendChild(oInput)
|
||||||
|
oInput.select()
|
||||||
|
document.execCommand('copy')
|
||||||
|
this.$message({
|
||||||
|
message: '复制成功',
|
||||||
|
type: 'success'
|
||||||
|
})
|
||||||
|
oInput.remove()
|
||||||
|
},
|
||||||
|
// 处理虚拟地址
|
||||||
|
handleVirtualAddr(data) {
|
||||||
|
return data.length > 40 ? data.substring(0, 37) + '...' : data;
|
||||||
|
},
|
||||||
/** 提交按钮 */
|
/** 提交按钮 */
|
||||||
submitForm() {
|
submitForm() {
|
||||||
this.$refs["form"].validate(valid => {
|
this.$refs["form"].validate(valid => {
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user