Commit 302be7b2 authored by qzhxx's avatar qzhxx

测试迭代

parent 436b90c8
...@@ -90,28 +90,30 @@ ...@@ -90,28 +90,30 @@
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="操作" width="280" header-align="center" align="center"> <el-table-column label="操作" width="280" header-align="center" align="center">
<!-- 只有下架可编辑、删除,只有通过可上架、下架 -->
<template slot-scope="scope" > <template slot-scope="scope" >
<div class="table-btn-group"> <div class="table-btn-group">
<el-tooltip content="修改" placement="top"> <el-tooltip content="修改" placement="top">
<el-button circle @click="openEdit(scope.row)"> <el-button circle :disabled="scope.row.published" @click="openEdit(scope.row)">
<i class="icon-table icon-edit"></i> <i class="icon-table icon-edit"></i>
</el-button> </el-button>
</el-tooltip> </el-tooltip>
<el-tooltip content="删除" placement="top">
<el-button circle :disabled="scope.row.published" @click="handleDelete(scope.row)">
<i class="icon-table icon-del"></i>
</el-button>
</el-tooltip>
<el-tooltip content="上架" placement="top"> <el-tooltip content="上架" placement="top">
<el-button circle :disabled="!!scope.row.published" @click="handlePublish(scope.row,true)"> <el-button circle :disabled="scope.row.auditStatus !== 'APPROVED_FINAL'" v-show="!scope.row.published" @click="handlePublish(scope.row,true)">
<i class="icon-table icon-enable"></i> <i class="icon-table icon-enable"></i>
</el-button> </el-button>
</el-tooltip> </el-tooltip>
<el-tooltip content="下架" placement="top"> <el-tooltip content="下架" placement="top">
<el-button circle :disabled="!scope.row.published" @click="handlePublish(scope.row,false)"> <el-button circle :disabled="scope.row.auditStatus !== 'APPROVED_FINAL'" v-show="scope.row.published" @click="handlePublish(scope.row,false)">
<i class="icon-table icon-disable"></i> <i class="icon-table icon-disable"></i>
</el-button> </el-button>
</el-tooltip> </el-tooltip>
<el-tooltip content="删除" placement="top">
<el-button circle @click="handleDelete(scope.row)">
<i class="icon-table icon-del"></i>
</el-button>
</el-tooltip>
<el-tooltip content="详情" placement="top"> <el-tooltip content="详情" placement="top">
<el-button circle @click="displayInfo(scope.row)"> <el-button circle @click="displayInfo(scope.row)">
<i class="icon-table icon-detail"></i> <i class="icon-table icon-detail"></i>
...@@ -284,6 +286,7 @@ export default { ...@@ -284,6 +286,7 @@ export default {
}, },
// 上下架 // 上下架
handlePublish(row ,isPublish) { handlePublish(row ,isPublish) {
let _isPublish = isPublish
let _this = this; let _this = this;
_this _this
.$https({ .$https({
...@@ -294,10 +297,23 @@ export default { ...@@ -294,10 +297,23 @@ export default {
_this.$qs.stringify({isPublish:isPublish})) _this.$qs.stringify({isPublish:isPublish}))
.then( .then(
res => { res => {
_this.msgInfo = { // _this.msgInfo = {
type: "wait", // type: "wait",
des: `申请已提交,待审核…`, // des: `申请已提交,待审核…`,
}; // };
if(res.data.resultCode === "200"){
if(_isPublish){
this.$message({ type: "success", message: "上架申请已提交,待审核!" });
}else{
this.$message({ type: "success", message: "下架申请已提交,待审核!" });
}
_this.Search();
}else{
this.$message({ type: "error", message: res.data.message });
}
_this.onSearch(); _this.onSearch();
}, },
error => { error => {
......
...@@ -5,7 +5,7 @@ ...@@ -5,7 +5,7 @@
<el-form-item> <el-form-item>
<el-input <el-input
placeholder="请输入学习内容名称" placeholder="请输入学习内容名称"
v-model="form.name" v-model="form.nameOrCode"
@keyup.enter.native="Search" @keyup.enter.native="Search"
clearable clearable
></el-input> ></el-input>
...@@ -102,8 +102,9 @@ ...@@ -102,8 +102,9 @@
</el-table-column> </el-table-column>
<el-table-column label="使用状态" prop="published"> <el-table-column label="使用状态" prop="published">
<template slot-scope="scope"> <template slot-scope="scope">
<span v-if="scope.row.published">禁用</span> <!-- {{scope.row.published}} -->
<span v-else>启用</span> <span v-if="scope.row.published">启用</span>
<span v-else>禁用</span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column <el-table-column
...@@ -138,12 +139,12 @@ ...@@ -138,12 +139,12 @@
</el-button> </el-button>
</el-tooltip> </el-tooltip>
<el-tooltip content="启用" placement="top"> <el-tooltip content="启用" placement="top">
<el-button circle @click="handlePublish(scope.row, 'True')"> <el-button circle v-show="!scope.row.published" @click="handlePublish(scope.row, 'True')">
<i class="icon-table icon-enable"></i> <i class="icon-table icon-enable"></i>
</el-button> </el-button>
</el-tooltip> </el-tooltip>
<el-tooltip content="禁用" placement="top"> <el-tooltip content="禁用" placement="top">
<el-button circle @click="handlePublish(scope.row, 'False')"> <el-button circle v-show="scope.row.published" @click="handlePublish(scope.row, 'False')">
<i class="icon-table icon-disable"></i> <i class="icon-table icon-disable"></i>
</el-button> </el-button>
</el-tooltip> </el-tooltip>
...@@ -401,7 +402,7 @@ export default { ...@@ -401,7 +402,7 @@ export default {
let searchObj = { let searchObj = {
_index: 1, _index: 1,
_size: _this.page.pageSize, _size: _this.page.pageSize,
name: _this.form.name, nameOrCode: _this.form.nameOrCode,
startDate: this.value1 ? this.value1[0] : "", startDate: this.value1 ? this.value1[0] : "",
endDate: this.value1 ? this.value1[1] : "", endDate: this.value1 ? this.value1[1] : "",
}; };
......
...@@ -199,7 +199,7 @@ export default { ...@@ -199,7 +199,7 @@ export default {
}, },
rules: { rules: {
name: [ name: [
{ required: true, message: "请输入版权方名称", trigger: "blur" } { required: true, message: "请输入视频名称", trigger: "blur" }
// { min: 3, max: 5, message: "长度在 3 到 5 个字符", trigger: "blur" } // { min: 3, max: 5, message: "长度在 3 到 5 个字符", trigger: "blur" }
], ],
videoContentCopyrightOwnerId:[ videoContentCopyrightOwnerId:[
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment