From 2f108a46d05e34981d52b447d73f0cfd8e8c30fd Mon Sep 17 00:00:00 2001
From: 648540858 <648540858@qq.com>
Date: 星期三, 17 十一月 2021 16:24:31 +0800
Subject: [PATCH] Merge pull request #232 from chenparty/wvp-28181-2.0
---
web_src/src/components/MediaServerManger.vue | 26 +++++++++++++++++++++++---
1 files changed, 23 insertions(+), 3 deletions(-)
diff --git a/web_src/src/components/MediaServerManger.vue b/web_src/src/components/MediaServerManger.vue
index 19674d1..07b0523 100644
--- a/web_src/src/components/MediaServerManger.vue
+++ b/web_src/src/components/MediaServerManger.vue
@@ -18,9 +18,11 @@
<div class="card-img-zlm"></div>
<div style="padding: 14px;text-align: left">
<span style="font-size: 16px">{{item.id}}</span>
+ <el-button icon="el-icon-edit" style="padding: 0;float: right;" type="text" @click="edit(item)">缂栬緫</el-button>
+ <el-button icon="el-icon-delete" style="margin-right: 10px;padding: 0;float: right;" type="text" @click="del(item)">绉婚櫎</el-button>
<div style="margin-top: 13px; line-height: 12px; ">
- <span style="font-size: 14px; color: #999; margin-top: 5px">鍒涘缓鏃堕棿锛� {{item.createTime}}</span>
- <el-button icon="el-icon-edit" style="padding: 0;float: right;" type="text" @click="edit(item)">缂栬緫</el-button>
+ <span style="font-size: 14px; color: #999; margin-top: 5px; ">{{item.ip}}</span>
+ <span style="font-size: 14px; color: #999; margin-top: 5px; float: right;">{{item.createTime}}</span>
</div>
</div>
<i v-if="item.status" class="iconfont icon-online server-card-status-online" title="鍦ㄧ嚎"></i>
@@ -88,6 +90,25 @@
edit: function (row){
this.$refs.mediaServerEdit.openDialog(row, this.initData)
},
+ del: function (row){
+ this.$confirm('纭鍒犻櫎姝よ妭鐐癸紵', '鎻愮ず', {
+ confirmButtonText: '纭畾',
+ cancelButtonText: '鍙栨秷',
+ type: 'warning'
+ }).then(() => {
+ this.mediaServerObj.delete(row.id, (data)=>{
+ if (data.code === 0) {
+ this.$message({
+ type: 'success',
+ message: '鍒犻櫎鎴愬姛!'
+ });
+ }
+ })
+
+ }).catch(() => {
+ });
+
+ },
getNumberByWidth(){
let candidateNums = [1, 2, 3, 4, 6, 8, 12, 24]
let clientWidth = window.innerWidth - 30;
@@ -106,7 +127,6 @@
}
}
- console.log("aadada: "+ resultVal)
return resultVal;
},
dateFormat: function(/** timestamp=0 **/) {
--
Gitblit v1.8.0