Commit c57ac995 by 匡雅琴

提交

1 parent 5539d9c9
...@@ -66,7 +66,8 @@ const materialDelete = params => { ...@@ -66,7 +66,8 @@ const materialDelete = params => {
url: 'rop-scrm-marketing/router', url: 'rop-scrm-marketing/router',
method: 'post', method: 'post',
data: params, data: params,
sign: true sign: true,
returnAll: true
}) })
} }
......
...@@ -6,7 +6,7 @@ ...@@ -6,7 +6,7 @@
<el-input v-model="materialGroupAddForm.materialGroupName" maxlength="8" show-word-limit :size="size" placeholder="客户跟进" style="width: 567px"></el-input> <el-input v-model="materialGroupAddForm.materialGroupName" maxlength="8" show-word-limit :size="size" placeholder="客户跟进" style="width: 567px"></el-input>
</el-form-item> </el-form-item>
<el-form-item label="业务类型:" prop="businessType"> <el-form-item label="业务类型:" prop="businessType">
<el-checkbox-group class="checkbox-group" v-model="materialGroupAddForm.businessType"> <el-checkbox-group class="checkbox-group" :max="3" v-model="materialGroupAddForm.businessType">
<el-checkbox v-for="item in businessTypes" :key="item.id" :label="item.dictLabel"></el-checkbox> <el-checkbox v-for="item in businessTypes" :key="item.id" :label="item.dictLabel"></el-checkbox>
</el-checkbox-group> </el-checkbox-group>
</el-form-item> </el-form-item>
......
...@@ -18,7 +18,7 @@ export default { ...@@ -18,7 +18,7 @@ export default {
return { return {
url, url,
searchForm: { searchForm: {
materialId: this.materialId, materialId: this.$route.query.id,
employeeName: '' employeeName: ''
}, },
staffSendFormData: [ staffSendFormData: [
...@@ -70,7 +70,7 @@ export default { ...@@ -70,7 +70,7 @@ export default {
handleReset() { handleReset() {
this.searchForm = { this.searchForm = {
staffName: '', staffName: '',
materialId: this.materialId materialId: this.$route.query.id,
} }
this.handleSearch() this.handleSearch()
} }
......
...@@ -10,8 +10,9 @@ export default { ...@@ -10,8 +10,9 @@ export default {
name: 'textBox', name: 'textBox',
data() { data() {
return { return {
editor: '',
content: '', content: '',
editorOption: {}, editorOption: {}
} }
}, },
mounted() { mounted() {
...@@ -19,21 +20,26 @@ export default { ...@@ -19,21 +20,26 @@ export default {
}, },
methods: { methods: {
getEdit() { getEdit() {
var editor = new E('#div-demo') this.editor = new E('#div-demo')
editor.config.uploadImgShowBase64 = true this.editor.config.uploadImgShowBase64 = true
editor.config.showMenuTooltips = true this.editor.config.showMenuTooltips = true
editor.config.menuTooltipPosition = 'down' this.editor.config.menuTooltipPosition = 'down'
editor.config.height = 400 this.editor.config.height = 400
editor.config.width = 500 this.editor.config.width = 500
editor.config.uploadVideoServer = '/api/upload-video' this.editor.config.uploadVideoServer = '/api/upload-video'
editor.config.excludeMenus = ['code'] this.editor.config.excludeMenus = ['code']
editor.config.onchange = (html) => { this.editor.config.onchange = html => {
// console.log(html); // console.log(html);
this.content = html // 绑定当前逐渐地值 this.content = html // 绑定当前逐渐地值
this.$emit('change', this.content) // 将内容同步到父组件中 this.$emit('change', this.content) // 将内容同步到父组件中
} }
editor.config.onchangeTimeout = 5000; this.editor.config.onchangeTimeout = 5000
editor.create() this.editor.create()
},
setEdit(html) {
this.$nextTick(() => {
this.editor.txt.html(html)
})
} }
} }
} }
...@@ -43,7 +49,7 @@ export default { ...@@ -43,7 +49,7 @@ export default {
#div-demo { #div-demo {
margin: 16px 300px 0 0; margin: 16px 300px 0 0;
} }
.el-form .editor{ .el-form .editor {
margin-top: 20px; margin-top: 20px;
} }
.myQuillEditor { .myQuillEditor {
...@@ -51,3 +57,8 @@ export default { ...@@ -51,3 +57,8 @@ export default {
height: 200px; height: 200px;
} }
</style> </style>
<style>
.w-e-text-container {
z-index: 1!important;
}
</style>
\ No newline at end of file \ No newline at end of file
...@@ -15,7 +15,7 @@ ...@@ -15,7 +15,7 @@
<glsx-combi-form ref="materialFormRef1" :isEdit="isEdit" :formObj="searchForm" :formData="materialFormData1" :inline="true"></glsx-combi-form> <glsx-combi-form ref="materialFormRef1" :isEdit="isEdit" :formObj="searchForm" :formData="materialFormData1" :inline="true"></glsx-combi-form>
<glsx-combi-form ref="materialFormRef2" :isEdit="isEdit" :formObj="searchForm" :formData="materialFormData2" :inline="true"> <glsx-combi-form ref="materialFormRef2" :isEdit="isEdit" :formObj="searchForm" :formData="materialFormData2" :inline="true">
<span slot="footer" slot-scope="scope" class="select-pro"> <span slot="footer" slot-scope="scope" class="select-pro">
<el-button type="primary" :size="size" @click="handleSearch(scope)">查询</el-button> <el-button type="primary" :size="size" @click="getListApi">查询</el-button>
<el-button type="default" :size="size" @click="handleReset(scope)">重置</el-button> <el-button type="default" :size="size" @click="handleReset(scope)">重置</el-button>
</span> </span>
</glsx-combi-form> </glsx-combi-form>
...@@ -30,19 +30,23 @@ ...@@ -30,19 +30,23 @@
<el-col :span="19"> <el-col :span="19">
<div class="right" :style="{ height: boxHeight }"> <div class="right" :style="{ height: boxHeight }">
<div class="groupTitle">{{ materialGroupName ? materialGroupName : '新车素材组' }}(共{{ materialTableData.length }}条数据)</div> <div class="groupTitle">{{ materialGroupName ? materialGroupName : '新车素材组' }}(共{{ materialTableData.length }}条数据)</div>
<GLTable ref="materialRef" :getListApi="getListApi" :noDataImg="url" :searchForm="searchForm" :tableParams="tableParams" :tableData="materialTableData" :pageConf="pageConf" :tableTotal="tableTotal" @sortChange="sortChange" :isCustomHead="true" :customHeadShowList="customHeadShowList"> <GLTable ref="materialRef" :noDataImg="url" :searchForm="searchForm" :tableParams="tableParams" :tableData="materialTableData" :pageConf="pageConf" :tableTotal="tableTotal" @sortChange="sortChange" :isCustomHead="true" :customHeadShowList="customHeadShowList">
<!-- 素材内容 --> <!-- 素材内容 -->
<div slot="materialContentRpcResponse" slot-scope="scope"> <div slot="materialContentRpcResponse" slot-scope="scope" style="text-align: center">
<!-- 素材为PDF --> <!-- 素材为PDF -->
<span v-if="scope.scope.materialType == 1"> <span v-if="scope.scope.materialType == 1" class="material-content">
<span>{{ scope.scope.materialContentRpcResponse.materialName }}</span> <el-tooltip effect="dark" placement="top" :content="scope.scope.materialContentRpcResponse.materialName" :disabled="scope.scope.materialContentRpcResponse.materialName < 16">
<span class="hide-content">{{ scope.scope.materialContentRpcResponse.materialName }}</span>
</el-tooltip>
<img src="@/assets/material/pdf.png" alt=""> <img src="@/assets/material/pdf.png" alt="">
</span> </span>
<!-- 素材为自定义链接 --> <!-- 素材为自定义链接 -->
<span v-if="scope.scope.materialType == 2"></span> <span v-if="scope.scope.materialType == 2"></span>
<!-- 图文 --> <!-- 图文 -->
<span v-if="scope.scope.materialType == 3"> <span v-if="scope.scope.materialType == 3" class="material-content">
<el-tooltip effect="dark" placement="top" :content="scope.scope.materialContentRpcResponse.materialName" :disabled="scope.scope.materialContentRpcResponse.materialName < 16">
<span>{{ scope.scope.materialContentRpcResponse.materialName }}</span> <span>{{ scope.scope.materialContentRpcResponse.materialName }}</span>
</el-tooltip>
<img src="@/assets/material/car.png" alt=""> <img src="@/assets/material/car.png" alt="">
</span> </span>
</div> </div>
...@@ -111,7 +115,6 @@ export default { ...@@ -111,7 +115,6 @@ export default {
introductionDialog: false, introductionDialog: false,
boxHeight: '', boxHeight: '',
businessTypes: [], businessTypes: [],
getListApi: this.$apis.material.materialList,
materialGroupName: '', materialGroupName: '',
materialFormData1: [ materialFormData1: [
{ {
...@@ -305,7 +308,8 @@ export default { ...@@ -305,7 +308,8 @@ export default {
this.boxHeight = clientHeight - offTop + 'px' this.boxHeight = clientHeight - offTop + 'px'
this.findAllDictData('business_type') this.findAllDictData('business_type')
this.firstCome() this.firstCome()
this.getListApi()
console.log(this.$refs.materialRef, '12312');
}, },
methods: { methods: {
// 判断是否第一次进入 // 判断是否第一次进入
...@@ -316,9 +320,9 @@ export default { ...@@ -316,9 +320,9 @@ export default {
} }
}, },
// 搜索 // 搜索
handleSearch() { // handleSearch() {
this.$refs.materialRef.refreshTable() // this.$refs.materialRef.refreshTable()
}, // },
// 重置 // 重置
handleReset() { handleReset() {
this.searchForm = { this.searchForm = {
...@@ -327,7 +331,7 @@ export default { ...@@ -327,7 +331,7 @@ export default {
status: '', status: '',
materialName: '' materialName: ''
} }
this.handleSearch() this.getListApi()
}, },
// 获取所有业务类型 // 获取所有业务类型
findAllDictData(dictType) { findAllDictData(dictType) {
...@@ -404,6 +408,18 @@ export default { ...@@ -404,6 +408,18 @@ export default {
this.materialTableData = this.materialTableData.sort((a, b) => a[fieldName] - b[fieldName]) this.materialTableData = this.materialTableData.sort((a, b) => a[fieldName] - b[fieldName])
} }
}, },
getParams() {
var params = JSON.parse(JSON.stringify(this.searchForm))
return params
},
getListApi() {
var params = this.getParams()
params.pageSize = 10,
params.pageNum = 1
this.$apis.material.materialList(params).then(res => {
this.materialTableData = res.data
})
},
// 点击素材组获取素材组素材 // 点击素材组获取素材组素材
getList(params, item) { getList(params, item) {
console.log(item, '7758') console.log(item, '7758')
...@@ -412,7 +428,7 @@ export default { ...@@ -412,7 +428,7 @@ export default {
this.$apis.material.materialList(params).then(res => { this.$apis.material.materialList(params).then(res => {
this.materialTableData = res.data this.materialTableData = res.data
}) })
this.handleSearch() // this.handleSearch()
}, },
// 功能介绍弹框 // 功能介绍弹框
showIntroductionDialog() { showIntroductionDialog() {
...@@ -436,7 +452,7 @@ export default { ...@@ -436,7 +452,7 @@ export default {
}) })
if (res.code == '0') { if (res.code == '0') {
fn && fn() fn && fn()
this.handleSearch() this.getListApi()
} }
}) })
} }
...@@ -492,4 +508,19 @@ export default { ...@@ -492,4 +508,19 @@ export default {
.btn-more { .btn-more {
margin-left: 10px; margin-left: 10px;
} }
.material-content {
display: flex;
justify-content: space-between;
.hide-content {
display: inline-block;
max-width: 200px;
text-overflow: ellipsis;
overflow: hidden;
white-space: nowrap;
}
img {
width: 36px;
height: 36px;
}
}
</style>> </style>>
\ No newline at end of file \ No newline at end of file
...@@ -53,8 +53,8 @@ ...@@ -53,8 +53,8 @@
<div class="content-item-desc" v-if="detailInfo.materialType == 3" v-html="detailInfo.materialUrl"></div> <div class="content-item-desc" v-if="detailInfo.materialType == 3" v-html="detailInfo.materialUrl"></div>
</div> </div>
<div class="content-item-image"> <div class="content-item-image">
<img src="@/assets/material/car.png" alt="" v-if="detailInfo.materialType == 3"> <img src="@/assets/material/car.png" alt="" v-if="detailInfo.materialType == 3" />
<img src="@/assets/material/pdf.png" alt="" v-if="detailInfo.materialType == 1"> <img src="@/assets/material/pdf.png" alt="" v-if="detailInfo.materialType == 1" />
</div> </div>
</div> </div>
</div> </div>
...@@ -139,7 +139,16 @@ ...@@ -139,7 +139,16 @@
</div> </div>
</div> </div>
<el-dialog :visible.sync="visibleImg" width="50%" :before-close="handleClose"> <el-dialog :visible.sync="visibleImg" width="50%" :before-close="handleClose">
<div slot="title" style="height: 18px"></div> <div slot="title" class="phone-view">
<img class="img-phone" src="@/assets/phone.png" alt="" />
<div class="phone-content">
<div>{{ detailInfo.materialName }}</div>
<div v-if="detailInfo.materialType == 3" v-html="detailInfo.materialUrl"></div>
<div>
<img src="@/assets/material/car.png" alt="" />
</div>
</div>
</div>
</el-dialog> </el-dialog>
<GLFooter> <GLFooter>
<el-button @click="goback" type="primary">返回</el-button> <el-button @click="goback" type="primary">返回</el-button>
...@@ -161,7 +170,7 @@ export default { ...@@ -161,7 +170,7 @@ export default {
return { return {
activeName: 'staffSendDetail', activeName: 'staffSendDetail',
detailVisible: true, detailVisible: true,
visibleImg: true, visibleImg: false,
selectTime: [], selectTime: [],
routerInfo: '', routerInfo: '',
detailInfo: {}, detailInfo: {},
...@@ -179,7 +188,7 @@ export default { ...@@ -179,7 +188,7 @@ export default {
var params = {} var params = {}
params.id = this.routerInfo.id params.id = this.routerInfo.id
this.$apis.material.materialDetail(params).then(res => { this.$apis.material.materialDetail(params).then(res => {
console.log(res, 'dhakfh'); console.log(res, 'dhakfh')
this.detailInfo = res this.detailInfo = res
}) })
}, },
...@@ -204,9 +213,7 @@ export default { ...@@ -204,9 +213,7 @@ export default {
this.overviewInfo = res this.overviewInfo = res
}) })
}, },
handleClick() { handleClick() {},
},
detailShowVisible() { detailShowVisible() {
this.detailVisible = !this.detailVisible this.detailVisible = !this.detailVisible
}, },
...@@ -220,7 +227,11 @@ export default { ...@@ -220,7 +227,11 @@ export default {
<style lang="scss" scoped> <style lang="scss" scoped>
.materialDetail, .materialDetail,
.summarization-containner { .summarization-containner {
background-color: #fff;
background-color: #fff;
&:nth-child(2) {
margin-bottom: 80px;
}
} }
.matrial-detail-unfold { .matrial-detail-unfold {
cursor: pointer; cursor: pointer;
...@@ -346,12 +357,13 @@ export default { ...@@ -346,12 +357,13 @@ export default {
color: #333333; color: #333333;
line-height: 21px; line-height: 21px;
} }
h4 { h2 {
height: 26px; height: 26px;
font-size: 26px; font-size: 26px;
font-weight: bold; font-weight: bold;
color: #333333; color: #333333;
line-height: 31px; line-height: 30px;
margin: 10px 0px;
} }
&-num { &-num {
font-size: 16px; font-size: 16px;
...@@ -393,4 +405,20 @@ export default { ...@@ -393,4 +405,20 @@ export default {
color: #999999; color: #999999;
line-height: 20px; line-height: 20px;
} }
.phone-view {
height: 600px;
position: relative;
.img-phone {
height: 80%;
width: 40%;
position: absolute;
top: 10%;
left: 25%;
}
.phone-content {
position: absolute;
top: 20%;
left: 30%;
}
}
</style> </style>
\ No newline at end of file \ No newline at end of file
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!