Merge branch 'main' of git.zdool.com:xs/yyx/web

This commit is contained in:
lnn19986213 2023-12-28 16:09:10 +08:00
commit 1de5690826
6 changed files with 124 additions and 176 deletions

View File

@ -77,7 +77,7 @@ export default {
} }
http.get("/api/association/zcqk", parame).then((res) => { http.get("/api/association/zcqk", parame).then((res) => {
if (res.code == 200) { if (res.code == 200) {
console.log(res.data) // console.log(res.data)
this.tableData = res.data.records this.tableData = res.data.records
this.total = res.data.total this.total = res.data.total
this.currentPage = res.data.current this.currentPage = res.data.current

View File

@ -72,7 +72,7 @@ export default {
} }
http.get("/api/works/list", parame).then((res) => { http.get("/api/works/list", parame).then((res) => {
if (res.code == 200) { if (res.code == 200) {
console.log(res.data) // console.log(res.data)
this.tableData = res.data.records this.tableData = res.data.records
this.total = res.data.total this.total = res.data.total
this.currentPage = res.data.current this.currentPage = res.data.current

View File

@ -7,6 +7,9 @@
<div style="margin-left: 10px;"> <div style="margin-left: 10px;">
<div><el-button type="primary" icon="el-icon-search" @click="getData">搜索</el-button></div> <div><el-button type="primary" icon="el-icon-search" @click="getData">搜索</el-button></div>
</div> </div>
<div style="margin-left: 10px;">
<div><el-button type="primary" icon="el-icon-search" @click="getdetail('批量审核', ids)">批量审核</el-button></div>
</div>
</div> </div>
</el-header> </el-header>
<div class="scTable" ref="scTableMain" v-loading="loading"> <div class="scTable" ref="scTableMain" v-loading="loading">
@ -15,13 +18,28 @@
@selection-change="handleSelectionChange"> @selection-change="handleSelectionChange">
<el-table-column type="selection" width="55"></el-table-column> <el-table-column type="selection" width="55"></el-table-column>
<el-table-column type="index" label="序号" width="80"> </el-table-column> <el-table-column type="index" label="序号" width="80"> </el-table-column>
<el-table-column prop="title" label="标题"> </el-table-column> <el-table-column prop="name" label="标题"> </el-table-column>
<el-table-column prop="content" label="简介"> </el-table-column>
<el-table-column prop="cover" label="封面图片" width="280"> <el-table-column prop="cover" label="封面图片" width="280">
<template #default="scope"> <template #default="scope">
<el-image :src="scope.row.cover"></el-image> <el-image :src="scope.row.cover"></el-image>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column prop="type" label="类型">
<template #default="scope">
<span v-if="scope.row.type == 'locality'">本地视频</span>
<span v-else>腾讯视频</span>
</template>
</el-table-column>
<el-table-column prop="type" label="视频链接">
<template #default="scope">
<div v-if="scope.row.type == 'locality'">
<el-link :href="scope.row.file" target="_blank">{{ scope.row.file }}</el-link>
</div>
<div v-else>
<el-link :href="scope.row.linkPath" target="_blank">{{ scope.row.linkPath }}</el-link>
</div>
</template>
</el-table-column>
<el-table-column label="操作" width="100"> <el-table-column label="操作" width="100">
<template #default="scope"> <template #default="scope">
<span style="font-size: 14px;color: #409eff;margin-right: 10px;cursor: pointer;" <span style="font-size: 14px;color: #409eff;margin-right: 10px;cursor: pointer;"
@ -115,7 +133,6 @@ export default {
arr.push(item.id) arr.push(item.id)
}) })
this.ids = arr.join(',') this.ids = arr.join(',')
console.log(this.ids, arr)
}, },
// //
getData() { getData() {
@ -156,7 +173,22 @@ export default {
this.formState.resource = true this.formState.resource = true
}, },
onFinish() { onFinish() {
// let parame = {
// ids: this.ids,
// examineState: this.formState.resource
// }
http.post("/api/exhibition/examine?examineState=" + this.formState.resource + '&ids=' + this.ids).then((res) => {
if (res.code == 200) {
this.tableData = []
this.total = 0
this.currentPage = 1
this.loading = true
this.open = false
this.getData()
}
}).catch(err => {
console.log(err)
});
}, },
getdetail(title, value) { getdetail(title, value) {
this.title = title this.title = title

View File

@ -7,6 +7,9 @@
<div style="margin-left: 10px;"> <div style="margin-left: 10px;">
<div><el-button type="primary" icon="el-icon-search" @click="getData">搜索</el-button></div> <div><el-button type="primary" icon="el-icon-search" @click="getData">搜索</el-button></div>
</div> </div>
<div style="margin-left: 10px;">
<div><el-button type="primary" icon="el-icon-search" @click="getdetail('批量审核', ids)">批量审核</el-button></div>
</div>
</div> </div>
</el-header> </el-header>
<div class="scTable" ref="scTableMain" v-loading="loading"> <div class="scTable" ref="scTableMain" v-loading="loading">
@ -115,7 +118,7 @@ export default {
arr.push(item.id) arr.push(item.id)
}) })
this.ids = arr.join(',') this.ids = arr.join(',')
console.log(this.ids, arr) // console.log(this.ids, arr)
}, },
// //
getData() { getData() {
@ -156,7 +159,22 @@ export default {
this.formState.resource = true this.formState.resource = true
}, },
onFinish() { onFinish() {
// let parame = {
// ids: this.ids,
// examineState: this.formState.resource
// }
http.post("/api/hall/examine?examineState=" + this.formState.resource + '&ids=' + this.ids).then((res) => {
if (res.code == 200) {
this.tableData = []
this.total = 0
this.currentPage = 1
this.loading = true
this.open = false
this.getData()
}
}).catch(err => {
console.log(err)
});
}, },
getdetail(title, value) { getdetail(title, value) {
this.title = title this.title = title

View File

@ -2,31 +2,35 @@
<el-header> <el-header>
<div style="display: flex;"> <div style="display: flex;">
<div style="margin-left: 10px;"> <div style="margin-left: 10px;">
<el-input v-model="value1" placeholder="请输入用户名" :input-style="inputStyle" clearable></el-input> <el-input v-model="value1" placeholder="请输入标题" :input-style="inputStyle" clearable></el-input>
</div> </div>
<div style="margin-left: 10px;"> <div style="margin-left: 10px;">
<div><el-button type="primary" icon="el-icon-search" @click="getData">搜索</el-button></div> <div><el-button type="primary" icon="el-icon-search" @click="getData">搜索</el-button></div>
</div> </div>
<div style="margin-left: 10px;">
<div><el-button type="primary" icon="el-icon-search" @click="getdetail('批量审核', ids)">批量审核</el-button></div>
</div>
</div> </div>
</el-header> </el-header>
<div class="scTable" ref="scTableMain" v-loading="loading"> <div class="scTable" ref="scTableMain" v-loading="loading">
<div class="scTable-table"> <div class="scTable-table">
<el-table :data="tableData" style="width: 100%" ref="scTable" :height="tableHeight"> <el-table :data="tableData" style="width: 100%" ref="scTable" :height="tableHeight"
<el-table-column type="index" label="序号" width="100"> </el-table-column> @selection-change="handleSelectionChange">
<el-table-column prop="name" label="作品名称"> </el-table-column> <el-table-column type="selection" width="55"></el-table-column>
<el-table-column prop="introduce" label="作品描述"> </el-table-column> <el-table-column type="index" label="序号" width="80"> </el-table-column>
<!-- <el-table-column prop="artAtt" label="简介"> <el-table-column prop="name" label="标题"> </el-table-column>
<template #default="scope"> <el-table-column prop="introduce" label="简介"> </el-table-column>
<div v-html="scope.row.artAtt"></div>
</template>
</el-table-column> -->
<el-table-column prop="userName" label="作者"> </el-table-column> <el-table-column prop="userName" label="作者"> </el-table-column>
<el-table-column label="操作"> <el-table-column prop="workTag" label="标签"> </el-table-column>
<el-table-column prop="typeName" label="类型">
<template #default="scope">
<span>{{ scope.row.typeName }} - {{ scope.row.typesName }}</span>
</template>
</el-table-column>
<el-table-column label="操作" width="100">
<template #default="scope"> <template #default="scope">
<span style="font-size: 14px;color: #409eff;margin-right: 10px;cursor: pointer;" <span style="font-size: 14px;color: #409eff;margin-right: 10px;cursor: pointer;"
@click.stop="getdetail('详情', scope.row.id)">详情</span> @click.stop="getdetail('审核', scope.row.id)">审核</span>
<span style="font-size: 14px;color: #409eff;margin-right: 10px;cursor: pointer;"
@click.stop="getdetail('修改', scope.row.id)">修改</span>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
@ -44,31 +48,15 @@
</div> </div>
<el-dialog v-model="open" :title="title" destroy-on-close :before-close="before" width="50%"> <el-dialog v-model="open" :title="title" destroy-on-close :before-close="before" width="50%">
<el-form :model="formState" label-width="100px"> <el-form :model="formState" label-width="100px">
<el-form-item label="姓名" name="userName"> <el-form-item label="状态" name="userName">
<el-input v-model="formState.userName" readonly /> <el-radio-group v-model="formState.resource">
</el-form-item> <el-radio :label="true">通过</el-radio>
<el-form-item label="简介" name="artAtt"> <el-radio :label="false">不通过</el-radio>
<sc-editor v-model="formState.artAtt" :height="350"></sc-editor> </el-radio-group>
</el-form-item>
<el-form-item label="代表作" name="opus">
<div v-for="(item, index) in formState.opus" :key="index" style="margin-bottom: 20px;">
<div style="display: flex;">
<el-input v-model="item.name" style="width: 220px;margin-right: 20px;" />
<el-button type="primary" @click="AddItem('0')">增加</el-button>
<el-button v-if="index > 0" type="error" @click="delItem('0', index)">删除</el-button>
</div>
<sc-upload-multiple :accept="''" v-model="item.value"></sc-upload-multiple>
</div>
</el-form-item>
<el-form-item label="荣誉奖项" name="greats">
<div v-for="(val, g) in formState.greats" :key="g" style="margin-bottom: 20px;">
<div style="display: flex;">
<el-input v-model="formState.greats[g]" style="width: 220px;margin-right: 20px;" />
<el-button type="primary" @click="AddItem('1')">增加</el-button>
<el-button v-if="g > 0" type="error" @click="delItem('1', g)">删除</el-button>
</div>
</div>
</el-form-item> </el-form-item>
<!-- <el-form-item label="简介" name="artAtt">
<el-input type="textarea" v-model="formState.desc"></el-input>
</el-form-item> -->
</el-form> </el-form>
<template #footer> <template #footer>
<span class="dialog-footer"> <span class="dialog-footer">
@ -95,7 +83,7 @@ export default {
paddingRight: '30px' paddingRight: '30px'
}, },
tableData: [], tableData: [],
pageSize: 100, pageSize: 20,
total: 0, total: 0,
currentPage: 1, currentPage: 1,
loading: false, loading: false,
@ -104,7 +92,12 @@ export default {
value1: '', value1: '',
open: false, open: false,
title: '修改', title: '修改',
formState: {}, formState: {
resource: true,
desc: ''
},
multipleSelection: [],
ids: '',
} }
}, },
created() { created() {
@ -120,42 +113,24 @@ export default {
upTableHeight() { upTableHeight() {
this.tableHeight = (this.$refs.scTableMain.offsetHeight - 50) + "px" this.tableHeight = (this.$refs.scTableMain.offsetHeight - 50) + "px"
}, },
handleSelectionChange(val) {
this.multipleSelection = val;
let arr = []
this.multipleSelection.forEach(item => {
arr.push(item.id)
})
this.ids = arr.join(',')
},
// //
getData() { getData() {
let parame = { let parame = {
name: this.value1, title: this.value1,
page: this.currentPage, page: this.currentPage,
size: this.pageSize size: this.pageSize
} }
http.get("/api/works/listssssssss", parame).then((res) => { http.get("/api/works/examineList", parame).then((res) => {
if (res.code == 200) { if (res.code == 200) {
this.tableData = res.data.records this.tableData = res.data.records
// records.forEach(element => {
// let arr1 = []
// let arr2 = []
// let arr3 = []
// if(element.greats){
// arr2 = JSON.parse(res.data.greats)
// element.greats = arr2.split(',')
// }else{
// element.greats = []
// }
// if(element.opus){
// arr3 = JSON.parse(res.data.opus)
// if(arr3.length > 0){
// arr3.forEach(item => {
// if(item.value.length > 0){
// item.value.forEach(v =>{
// arr1.push(v)
// })
// }
// })
// }
// element.opus = arr1
// }else{
// element.opus = []
// }
// });
this.total = res.data.total this.total = res.data.total
this.currentPage = res.data.current this.currentPage = res.data.current
this.loading = false this.loading = false
@ -175,115 +150,38 @@ export default {
this.loading = true this.loading = true
this.getData() this.getData()
}, },
//
getdetail(title, value) {
this.title = title
let _this = this
http.get("/api/user/artistsDetails", { id: value }).then((res) => {
if (res.code == 200) {
this.formState = res.data
if (res.data.greats == "") {
this.formState.greats = ['']
} else {
this.formState.greats = JSON.parse(res.data.greats)
}
if (res.data.opuss.length == 0) {
this.formState.opus = [{
name: '',
value: []
}]
} else {
this.formState.opus = []
res.data.opuss.forEach(item => {
let img = []
if(item.value.length > 0){
item.value.forEach(ele => {
img.push({
path: ele,
preview: ele
})
})
}
_this.formState.opus.push({
name: item.name,
value: img
})
})
console.log(this.formState.opuss)
}
this.open = true
}
}).catch(err => {
console.log(err)
});
},
//
outPut() {
let url = '/api/association/sign_export?name=' + this.value1
http.download(url);
},
before() { before() {
this.open = false; this.open = false;
// router.replace(); // router.replace();
}, },
handleClose() { handleClose() {
this.open = false; this.open = false;
this.formState.desc = ''
this.formState.resource = true
}, },
onFinish() { onFinish() {
if (this.title == '详情') { // let parame = {
this.open = false // ids: this.ids,
} else { // examineState: this.formState.resource
let opu = [] // }
this.formState.opus.forEach(element => { http.post("/api/works/examine?examineState=" + this.formState.resource + '&ids=' + this.ids).then((res) => {
let arr = []
if (element.value) {
arr = element.value.split(',')
opu.push({
name: element.name,
value: arr
})
} else {
opu.push({
name: element.name,
value: []
})
}
element.value = arr
});
let parmes = {
id: this.formState.id,
artAtt: this.formState.artAtt,
greats: JSON.stringify(this.formState.greats),
opus: JSON.stringify(opu),
}
http.post("/api/user/edit", parmes).then((res) => {
if (res.code == 200) { if (res.code == 200) {
this.tableData = []
this.total = 0
this.currentPage = 1
this.loading = true
this.open = false this.open = false
this.getData() this.getData()
} }
}).catch(err => { }).catch(err => {
console.log(err) console.log(err)
}); });
}
}, },
delItem(Edkey, num) { getdetail(title, value) {
if (Edkey == '0') { this.title = title
this.formState.opus.splice(num, 1) this.open = true
} else { this.ids = value
this.formState.greats.splice(num, 1)
} }
},
AddItem(Edkey) {
if (Edkey == '0') {
this.formState.opus.push({
name: '',
value: []
})
} else {
this.formState.greats.push("")
}
},
} }
} }
</script> </script>

View File

@ -207,7 +207,7 @@ export default {
value: img value: img
}) })
}) })
console.log(this.formState.opuss) // console.log(this.formState.opuss)
} }
this.open = true this.open = true
} }