Commit ff5ea28d authored by 杨硕's avatar 杨硕

商家下拉框过滤停用的商家

parent a85fb3c4
...@@ -17,7 +17,15 @@ body .el-table th.gutter{ ...@@ -17,7 +17,15 @@ body .el-table th.gutter{
.el-upload__input { .el-upload__input {
display: none; display: none;
} }
.el-tag.el-tag--info {
max-width: 90%;
.el-select__tags-text{
max-width: 90%;
display: inline-flex;
overflow: hidden;
text-overflow: ellipsis;
}
}
// to fixed https://github.com/ElemeFE/element/issues/2461 // to fixed https://github.com/ElemeFE/element/issues/2461
// 弹出框dialog 公共样式修改 // 弹出框dialog 公共样式修改
......
...@@ -695,7 +695,7 @@ export default { ...@@ -695,7 +695,7 @@ export default {
getDeptList() { getDeptList() {
listAllShop().then(res => { listAllShop().then(res => {
if (res.code === 200) { if (res.code === 200) {
this.deptList = res.data this.deptList = res.data.filter(item => item.flag === '1')
if (res.data && res.data.length > 0) { if (res.data && res.data.length > 0) {
if (!this.clearable) { if (!this.clearable) {
this.queryParams.deptId = res.data[0].businessId this.queryParams.deptId = res.data[0].businessId
......
...@@ -63,7 +63,7 @@ ...@@ -63,7 +63,7 @@
<div style="padding:5px 10px"> <div style="padding:5px 10px">
<el-table v-loading="loading" border :data="cmsBannerList"> <el-table v-loading="loading" border :data="cmsBannerList">
<el-table-column type="index" label="序号" width="100px" align="center" /> <el-table-column type="index" label="序号" width="100px" align="center" />
<el-table-column label="图片" prop="bannerPicture" > <el-table-column label="图片" prop="bannerPicture">
<template slot-scope="scope"> <template slot-scope="scope">
<div :id="step(scope.$index)"> <div :id="step(scope.$index)">
<el-image <el-image
...@@ -102,12 +102,12 @@ ...@@ -102,12 +102,12 @@
{{ scope.row.type === '0' ? '是' : '否' }} {{ scope.row.type === '0' ? '是' : '否' }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="排序" prop="weight" :show-overflow-tooltip="true" > <el-table-column label="排序" prop="weight" :show-overflow-tooltip="true">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.weight || '-' }} {{ scope.row.weight || '-' }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="状态" prop="flag"> <el-table-column label="状态" prop="flag">
<template slot-scope="scope"> <template slot-scope="scope">
<el-switch <el-switch
v-model="scope.row.flag" v-model="scope.row.flag"
...@@ -369,7 +369,7 @@ export default { ...@@ -369,7 +369,7 @@ export default {
getDeptList() { getDeptList() {
listAllShop().then(res => { listAllShop().then(res => {
if (res.code === 200) { if (res.code === 200) {
this.deptList = res.data this.deptList = res.data.filter(item => item.flag === '1')
if (res.data && res.data.length > 0) { if (res.data && res.data.length > 0) {
if (!this.clearable) { if (!this.clearable) {
this.queryParams.unitId = res.data[0].businessId this.queryParams.unitId = res.data[0].businessId
......
...@@ -82,7 +82,7 @@ ...@@ -82,7 +82,7 @@
</template> </template>
</el-table-column> </el-table-column>
<el-table-column align="left" prop="title" label="标题" show-overflow-tooltip /> <el-table-column align="left" prop="title" label="标题" show-overflow-tooltip />
<el-table-column align="left" prop="title" label="类型" show-overflow-tooltip> <el-table-column align="left" prop="title" label="类型" show-overflow-tooltip>
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.type === '1' ? '视频' : '新闻' }} {{ scope.row.type === '1' ? '视频' : '新闻' }}
</template> </template>
...@@ -801,7 +801,7 @@ import { ...@@ -801,7 +801,7 @@ import {
} from '@/api/try/teaTrialCourse' } from '@/api/try/teaTrialCourse'
import { getDict } from '@/api/system/dict/data' import { getDict } from '@/api/system/dict/data'
import { validOpenCourse } from '@/api/classManagement' import { validOpenCourse } from '@/api/classManagement'
import {importSpokesmanExcel, importSysUserExcel, importTemplateSysuser, listByIdentity} from '@/api/system/user' import { importSpokesmanExcel, importSysUserExcel, importTemplateSysuser, listByIdentity } from '@/api/system/user'
import { listAllShop, listCourseAll } from '@/api/sysUnit' import { listAllShop, listCourseAll } from '@/api/sysUnit'
import { mapGetters } from 'vuex' import { mapGetters } from 'vuex'
import { import {
...@@ -1046,7 +1046,7 @@ export default { ...@@ -1046,7 +1046,7 @@ export default {
console.log('this.clearable', this.clearable) console.log('this.clearable', this.clearable)
listAllShop().then(res => { listAllShop().then(res => {
if (res.code === 200) { if (res.code === 200) {
this.deptList = res.data this.deptList = res.data.filter(item => item.flag === '1')
if (res.data && res.data.length > 0) { if (res.data && res.data.length > 0) {
if (!this.clearable) { if (!this.clearable) {
this.queryParams.unitId = res.data[0].businessId this.queryParams.unitId = res.data[0].businessId
......
...@@ -556,7 +556,7 @@ export default { ...@@ -556,7 +556,7 @@ export default {
getDeptList() { getDeptList() {
listAllShop().then(res => { listAllShop().then(res => {
if (res.code === 200) { if (res.code === 200) {
this.deptList = res.data this.deptList = res.data.filter(item => item.flag === '1')
if (res.data && res.data.length > 0) { if (res.data && res.data.length > 0) {
if (!this.clearable) { if (!this.clearable) {
this.queryParams.unitId = res.data[0].businessId this.queryParams.unitId = res.data[0].businessId
...@@ -610,6 +610,8 @@ export default { ...@@ -610,6 +610,8 @@ export default {
this.queryParams.rows = 10 this.queryParams.rows = 10
this.queryParams.title = '' this.queryParams.title = ''
this.dateRange = [] this.dateRange = []
this.queryParams.beginTime = ''
this.queryParams.endTime = ''
if (this.clearable) { if (this.clearable) {
this.queryParams.unitId = '' this.queryParams.unitId = ''
} }
......
...@@ -89,7 +89,7 @@ ...@@ -89,7 +89,7 @@
<!-- <span>{{ scope.row.isForntPage === 1 ? '是' : '否' }}</span>--> <!-- <span>{{ scope.row.isForntPage === 1 ? '是' : '否' }}</span>-->
<!-- </template>--> <!-- </template>-->
<!-- </el-table-column>--> <!-- </el-table-column>-->
<el-table-column align="left" prop="isRecommended" label="是否为推荐视频" show-overflow-tooltip> <el-table-column align="left" prop="isRecommended" label="是否为推荐视频" show-overflow-tooltip>
<template slot-scope="scope"> <template slot-scope="scope">
<span>{{ scope.row.homeDisplay === '1' ? '是' : '否' }}</span> <span>{{ scope.row.homeDisplay === '1' ? '是' : '否' }}</span>
</template> </template>
...@@ -401,7 +401,7 @@ export default { ...@@ -401,7 +401,7 @@ export default {
getDeptList() { getDeptList() {
listAllShop().then(res => { listAllShop().then(res => {
if (res.code === 200) { if (res.code === 200) {
this.deptList = res.data this.deptList = res.data.filter(item => item.flag === '1')
if (res.data && res.data.length > 0) { if (res.data && res.data.length > 0) {
if (!this.clearable) { if (!this.clearable) {
this.queryParams.unitId = res.data[0].businessId this.queryParams.unitId = res.data[0].businessId
...@@ -451,9 +451,11 @@ export default { ...@@ -451,9 +451,11 @@ export default {
/** 重置按钮操作 */ /** 重置按钮操作 */
resetQuery() { resetQuery() {
this.queryParams.page = 1, this.queryParams.page = 1
this.queryParams.rows = 10, this.queryParams.rows = 10
this.queryParams.videoTitle = '', this.queryParams.beginTime = ''
this.queryParams.endTime = ''
this.queryParams.videoTitle = ''
this.dateRange = [] this.dateRange = []
if (this.clearable) { if (this.clearable) {
this.queryParams.unitId = '' this.queryParams.unitId = ''
......
...@@ -4,9 +4,9 @@ ...@@ -4,9 +4,9 @@
<div class="topTitle"> <div class="topTitle">
<span class="topTitleText">{{ title }}</span> <span class="topTitleText">{{ title }}</span>
</div> </div>
<!-- <div class="twoTitle">--> <!-- <div class="twoTitle">-->
<!-- <el-tag v-if="form.flag==='1'" type="success">已发布</el-tag>--> <!-- <el-tag v-if="form.flag==='1'" type="success">已发布</el-tag>-->
<!-- </div>--> <!-- </div>-->
<div class="updateBoby"> <div class="updateBoby">
<el-form ref="deviceFormRef" :model="form" :rules="rules" label-position="right" label-width="auto"> <el-form ref="deviceFormRef" :model="form" :rules="rules" label-position="right" label-width="auto">
<el-row> <el-row>
...@@ -104,11 +104,12 @@ ...@@ -104,11 +104,12 @@
class="avatar-uploader" class="avatar-uploader"
action="#" action="#"
drag drag
:show-file-list="false" :show-file-list="true"
:http-request="handleUploadVideo" :http-request="handleUploadVideo"
:on-success="handleAvatarSuccessVideo" :on-success="handleAvatarSuccessVideo"
:before-upload="beforeAvatarUploadVideo" :before-upload="beforeAvatarUploadVideo"
:on-preview="previewVideo" :on-preview="previewVideo"
:on-remove="handleRemove"
> >
<i class="el-icon-upload" /> <i class="el-icon-upload" />
<div class="el-upload__text">将文件拖到此处,或<em>点击上传</em></div> <div class="el-upload__text">将文件拖到此处,或<em>点击上传</em></div>
...@@ -155,6 +156,7 @@ export default { ...@@ -155,6 +156,7 @@ export default {
data() { data() {
return { return {
videoShow: false, videoShow: false,
fileList: [],
// 视频配置 // 视频配置
playerOptions: { playerOptions: {
height: '100%', height: '100%',
...@@ -300,6 +302,7 @@ export default { ...@@ -300,6 +302,7 @@ export default {
}) })
}, },
handleUploadVideo(file) { handleUploadVideo(file) {
this.fileList = []
const formData = new FormData() const formData = new FormData()
formData.append('file', file.file) formData.append('file', file.file)
formData.append('temp', 'videoInformation') formData.append('temp', 'videoInformation')
...@@ -308,6 +311,7 @@ export default { ...@@ -308,6 +311,7 @@ export default {
this.$message.success('上传成功') this.$message.success('上传成功')
this.videoUrl = res.data.businessId this.videoUrl = res.data.businessId
this.form.videoUrlId = res.data.businessId this.form.videoUrlId = res.data.businessId
this.fileList.push(res.data)
// this.playerOptions.sources[0].src = urlDecrypt(res.data.url) // this.playerOptions.sources[0].src = urlDecrypt(res.data.url)
}) })
}, },
...@@ -380,7 +384,19 @@ export default { ...@@ -380,7 +384,19 @@ export default {
this.videoShow = true this.videoShow = true
}) })
}, },
handleRemove(file, fileList) {
console.log('file', file)
console.log('fileList', fileList)
this.fileList = []
if (fileList.length <= 0) {
this.videoUrl = ''
}
},
beforeAvatarUploadVideo(file) { beforeAvatarUploadVideo(file) {
if (this.fileList.length > 0) {
this.$message.error('一次只能上传一个视频!')
return false
}
console.log('KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK') console.log('KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK')
const allowedExtensions = ['mp4'] const allowedExtensions = ['mp4']
const extension = file.name.slice((file.name.lastIndexOf('.') - 1 >>> 0) + 2).toLowerCase() const extension = file.name.slice((file.name.lastIndexOf('.') - 1 >>> 0) + 2).toLowerCase()
......
...@@ -106,11 +106,11 @@ ...@@ -106,11 +106,11 @@
style="width: 100%" style="width: 100%"
class="top" class="top"
> >
<el-table-column type="index" label="序号" width="50" :show-overflow-tooltip="true"/> <el-table-column type="index" label="序号" width="50" :show-overflow-tooltip="true" />
<el-table-column prop="name" label="姓名" width="80" :show-overflow-tooltip="true"/> <el-table-column prop="name" label="姓名" width="80" :show-overflow-tooltip="true" />
<el-table-column prop="phone" label="手机号" :show-overflow-tooltip="true"/> <el-table-column prop="phone" label="手机号" :show-overflow-tooltip="true" />
<el-table-column prop="clickThroughRate" label="推广次数" width="80" :show-overflow-tooltip="true"/> <el-table-column prop="clickThroughRate" label="推广次数" width="80" :show-overflow-tooltip="true" />
<el-table-column prop="price" label="金额" width="50" :show-overflow-tooltip="true"/> <el-table-column prop="price" label="金额" width="50" :show-overflow-tooltip="true" />
</el-table> </el-table>
<vue-seamless-scroll <vue-seamless-scroll
:data="list" :data="list"
...@@ -123,11 +123,11 @@ ...@@ -123,11 +123,11 @@
style="width: 100%" style="width: 100%"
class="bottom" class="bottom"
> >
<el-table-column type="index" label="序号" width="50" :show-overflow-tooltip="true"/> <el-table-column type="index" label="序号" width="50" :show-overflow-tooltip="true" />
<el-table-column prop="name" label="姓名" width="80" :show-overflow-tooltip="true"/> <el-table-column prop="name" label="姓名" width="80" :show-overflow-tooltip="true" />
<el-table-column prop="phone" label="手机号" :show-overflow-tooltip="true" /> <el-table-column prop="phone" label="手机号" :show-overflow-tooltip="true" />
<el-table-column prop="clickThroughRate" label="推广次数" width="80" :show-overflow-tooltip="true"/> <el-table-column prop="clickThroughRate" label="推广次数" width="80" :show-overflow-tooltip="true" />
<el-table-column prop="price" label="金额" width="50" :show-overflow-tooltip="true"/> <el-table-column prop="price" label="金额" width="50" :show-overflow-tooltip="true" />
</el-table> </el-table>
</vue-seamless-scroll> </vue-seamless-scroll>
...@@ -146,7 +146,7 @@ ...@@ -146,7 +146,7 @@
<div class="videNum">视频总推广次数:</div> <div class="videNum">视频总推广次数:</div>
</div> </div>
</div> </div>
<div v-show="pieShow" id="echarts-textPieChart" class="span_1" v-loading="loading"> <div v-show="pieShow" id="echarts-textPieChart" v-loading="loading" class="span_1">
<div id="dataCharts_textPieChart" style="height: 16vh" /> <div id="dataCharts_textPieChart" style="height: 16vh" />
</div> </div>
<div v-show="!pieShow" class="nodata" style="height: 16vh"> <div v-show="!pieShow" class="nodata" style="height: 16vh">
...@@ -174,7 +174,7 @@ ...@@ -174,7 +174,7 @@
</el-button> </el-button>
</div> </div>
</el-row> </el-row>
<div v-show="promotionShow" id="echarts-leaveMessage" class="span_1" v-loading="loading"> <div v-show="promotionShow" id="echarts-leaveMessage" v-loading="loading" class="span_1">
<div id="dataCharts_leaveMessage" style="height: 10vh" /> <div id="dataCharts_leaveMessage" style="height: 10vh" />
</div> </div>
<div v-show="!promotionShow" class="nodata" style="height: 10vh"> <div v-show="!promotionShow" class="nodata" style="height: 10vh">
...@@ -323,7 +323,7 @@ export default { ...@@ -323,7 +323,7 @@ export default {
return new Promise(resolve => { return new Promise(resolve => {
listAllShop().then(res => { listAllShop().then(res => {
if (res.code === 200) { if (res.code === 200) {
this.deptList = res.data this.deptList = res.data.filter(item => item.flag === '1')
this.company = this.deptList[0].businessId this.company = this.deptList[0].businessId
this.companyName = this.deptList[0].unitName this.companyName = this.deptList[0].unitName
this.getTableData() // 代言人,文章,视频数据 this.getTableData() // 代言人,文章,视频数据
......
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