Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
saas
/
scrm-micro-content
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit d959e23f
authored
Dec 14, 2022
by
前端
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
更新代码3.2.0需求代码
1 parent
6ec5298b
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
531 additions
and
211 deletions
package-lock.json
package.json
src/main.js
src/setup/qiankun.js
src/views/material/addMaterial.vue
src/views/material/components/textBox.vue
src/views/material/index.vue
package-lock.json
View file @
d959e23
...
@@ -15,6 +15,11 @@
...
@@ -15,6 +15,11 @@
"js-message"
:
"1.0.7"
"js-message"
:
"1.0.7"
}
}
},
},
"@amap/amap-jsapi-loader"
:
{
"version"
:
"1.0.1"
,
"resolved"
:
"https://registry.npmmirror.com/@amap/amap-jsapi-loader/-/amap-jsapi-loader-1.0.1.tgz"
,
"integrity"
:
"sha512-nPyLKt7Ow/ThHLkSvn2etQlUzqxmTVgK7bIgwdBRTg2HK5668oN7xVxkaiRe3YZEzGzfV2XgH5Jmu2T73ljejw=="
},
"@ampproject/remapping"
:
{
"@ampproject/remapping"
:
{
"version"
:
"2.2.0"
,
"version"
:
"2.2.0"
,
"resolved"
:
"https://registry.npmjs.org/@ampproject/remapping/-/remapping-2.2.0.tgz"
,
"resolved"
:
"https://registry.npmjs.org/@ampproject/remapping/-/remapping-2.2.0.tgz"
,
...
@@ -6437,36 +6442,36 @@
...
@@ -6437,36 +6442,36 @@
}
}
},
},
"glsx-components"
:
{
"glsx-components"
:
{
"version"
:
"1.5.
2
"
,
"version"
:
"1.5.
3
"
,
"resolved"
:
"https://registry.npm
js.org/glsx-components/-/glsx-components-1.5.2
.tgz"
,
"resolved"
:
"https://registry.npm
mirror.com/glsx-components/-/glsx-components-1.5.3
.tgz"
,
"integrity"
:
"sha512-
5/LaPu0B1uT7Kzl6oyIqyFT/NXIz2w7HNstiRtHaUQN1waSrPPPtzRRwywJg6CSSL+p994NaqPRnX696NAYzKg
=="
,
"integrity"
:
"sha512-
tj/2DSGKpbwrlP7ByBZQrgEgCcmrP2iR8p/BafY6BFr0/q4sJuxQx6of586rJuoVUasRveIIuFmUcLCkBSnQFA
=="
,
"requires"
:
{
"requires"
:
{
"@amap/amap-jsapi-loader"
:
"^1.0.1"
,
"core-js"
:
"^3.6.5"
,
"core-js"
:
"^3.6.5"
,
"element-ui"
:
"^2.15.6"
,
"element-ui"
:
"^2.15.6"
,
"glsx-common"
:
"^1.4.9"
,
"glsx-common"
:
"^1.4.9"
,
"vue"
:
"^2.6.11"
,
"vue"
:
"^2.6.11"
,
"vue-amap"
:
"^0.5.10"
,
"vuedraggable"
:
"^2.24.3"
"vuedraggable"
:
"^2.24.3"
},
},
"dependencies"
:
{
"dependencies"
:
{
"axios"
:
{
"version"
:
"0.21.4"
,
"resolved"
:
"https://registry.npmmirror.com/axios/-/axios-0.21.4.tgz"
,
"integrity"
:
"sha512-ut5vewkiu8jjGBdqpM44XxjuCjq9LAKeHVmoVfHVzy8eHgxxq8SbAVQNovDA8mVi05kP0Ea/n/UzcSHcTJQfNg=="
,
"requires"
:
{
"follow-redirects"
:
"^1.14.0"
}
},
"glsx-common"
:
{
"glsx-common"
:
{
"version"
:
"1.4.9"
,
"version"
:
"1.4.9"
,
"resolved"
:
"https://registry.npm
js.org
/glsx-common/-/glsx-common-1.4.9.tgz"
,
"resolved"
:
"https://registry.npm
mirror.com
/glsx-common/-/glsx-common-1.4.9.tgz"
,
"integrity"
:
"sha512-RQWGOGEXUPNmHkZn7n+eukkXp6L/mOfsgMo4gFtrt80ZDxGaznHMg7Isi4+IrEdvVdzp8Cju0eiCTddnZfdsJg=="
,
"integrity"
:
"sha512-RQWGOGEXUPNmHkZn7n+eukkXp6L/mOfsgMo4gFtrt80ZDxGaznHMg7Isi4+IrEdvVdzp8Cju0eiCTddnZfdsJg=="
,
"requires"
:
{
"requires"
:
{
"axios"
:
"^0.21.3"
,
"axios"
:
"^0.21.3"
,
"md5"
:
"^2.3.0"
,
"md5"
:
"^2.3.0"
,
"qs"
:
"^6.10.1"
,
"qs"
:
"^6.10.1"
,
"sha1"
:
"^1.1.1"
"sha1"
:
"^1.1.1"
},
"dependencies"
:
{
"axios"
:
{
"version"
:
"0.21.4"
,
"resolved"
:
"https://registry.npmjs.org/axios/-/axios-0.21.4.tgz"
,
"integrity"
:
"sha512-ut5vewkiu8jjGBdqpM44XxjuCjq9LAKeHVmoVfHVzy8eHgxxq8SbAVQNovDA8mVi05kP0Ea/n/UzcSHcTJQfNg=="
,
"requires"
:
{
"follow-redirects"
:
"^1.14.0"
}
}
}
}
}
}
}
}
...
@@ -11932,7 +11937,7 @@
...
@@ -11932,7 +11937,7 @@
},
},
"sortablejs"
:
{
"sortablejs"
:
{
"version"
:
"1.10.2"
,
"version"
:
"1.10.2"
,
"resolved"
:
"https://registry.npm
js.org
/sortablejs/-/sortablejs-1.10.2.tgz"
,
"resolved"
:
"https://registry.npm
mirror.com
/sortablejs/-/sortablejs-1.10.2.tgz"
,
"integrity"
:
"sha512-YkPGufevysvfwn5rfdlGyrGjt7/CRHwvRPogD/lC+TnvcN29jDpCifKP+rBqf+LRldfXSTh+0CGLcSg0VIxq3A=="
"integrity"
:
"sha512-YkPGufevysvfwn5rfdlGyrGjt7/CRHwvRPogD/lC+TnvcN29jDpCifKP+rBqf+LRldfXSTh+0CGLcSg0VIxq3A=="
},
},
"source-list-map"
:
{
"source-list-map"
:
{
...
@@ -12983,6 +12988,21 @@
...
@@ -12983,6 +12988,21 @@
"integrity"
:
"sha512-WRbjgmYzgXkCV7zNVpy5YgrHgbBv126rMALQQMrmzOVC4GM2waQ9x7xtm8VU+1yF2kWyPzI9zbZ48n4vSxwfSA=="
,
"integrity"
:
"sha512-WRbjgmYzgXkCV7zNVpy5YgrHgbBv126rMALQQMrmzOVC4GM2waQ9x7xtm8VU+1yF2kWyPzI9zbZ48n4vSxwfSA=="
,
"dev"
:
true
"dev"
:
true
},
},
"uppercamelcase"
:
{
"version"
:
"1.1.0"
,
"resolved"
:
"https://registry.npmmirror.com/uppercamelcase/-/uppercamelcase-1.1.0.tgz"
,
"integrity"
:
"sha512-C7YEMvhgrvTEKEEVqA7LXNID/1TvvIwYZqNIKLquS6y/MGSkRQAav9LnTTILlC1RqUM8eTVBOe1U/fnB652PRA=="
,
"requires"
:
{
"camelcase"
:
"^1.2.1"
},
"dependencies"
:
{
"camelcase"
:
{
"version"
:
"1.2.1"
,
"resolved"
:
"https://registry.npmmirror.com/camelcase/-/camelcase-1.2.1.tgz"
,
"integrity"
:
"sha512-wzLkDa4K/mzI1OSITC+DUyjgIl/ETNHE9QvYgy6J6Jvqyyz4C0Xfd+lQhb19sX2jMpZV4IssUn0VDVmglV+s4g=="
}
}
},
"uri-js"
:
{
"uri-js"
:
{
"version"
:
"4.4.1"
,
"version"
:
"4.4.1"
,
"resolved"
:
"https://registry.npmjs.org/uri-js/-/uri-js-4.4.1.tgz"
,
"resolved"
:
"https://registry.npmjs.org/uri-js/-/uri-js-4.4.1.tgz"
,
...
@@ -13187,6 +13207,14 @@
...
@@ -13187,6 +13207,14 @@
"csstype"
:
"^3.1.0"
"csstype"
:
"^3.1.0"
}
}
},
},
"vue-amap"
:
{
"version"
:
"0.5.10"
,
"resolved"
:
"https://registry.npmmirror.com/vue-amap/-/vue-amap-0.5.10.tgz"
,
"integrity"
:
"sha512-9ViNCev1vx32+zZ5RvF/TmUZNbwL9QrdA2/OnD2GlXMfQBkJy7D08Vb7379t6guqnopDPtWJ8K6gg72h9+4GUg=="
,
"requires"
:
{
"uppercamelcase"
:
"^1.1.0"
}
},
"vue-cli-plugin-element"
:
{
"vue-cli-plugin-element"
:
{
"version"
:
"1.0.1"
,
"version"
:
"1.0.1"
,
"resolved"
:
"https://registry.npmjs.org/vue-cli-plugin-element/-/vue-cli-plugin-element-1.0.1.tgz"
,
"resolved"
:
"https://registry.npmjs.org/vue-cli-plugin-element/-/vue-cli-plugin-element-1.0.1.tgz"
,
...
@@ -13397,7 +13425,7 @@
...
@@ -13397,7 +13425,7 @@
},
},
"vuedraggable"
:
{
"vuedraggable"
:
{
"version"
:
"2.24.3"
,
"version"
:
"2.24.3"
,
"resolved"
:
"https://registry.npm
js.org
/vuedraggable/-/vuedraggable-2.24.3.tgz"
,
"resolved"
:
"https://registry.npm
mirror.com
/vuedraggable/-/vuedraggable-2.24.3.tgz"
,
"integrity"
:
"sha512-6/HDXi92GzB+Hcs9fC6PAAozK1RLt1ewPTLjK0anTYguXLAeySDmcnqE8IC0xa7shvSzRjQXq3/+dsZ7ETGF3g=="
,
"integrity"
:
"sha512-6/HDXi92GzB+Hcs9fC6PAAozK1RLt1ewPTLjK0anTYguXLAeySDmcnqE8IC0xa7shvSzRjQXq3/+dsZ7ETGF3g=="
,
"requires"
:
{
"requires"
:
{
"sortablejs"
:
"1.10.2"
"sortablejs"
:
"1.10.2"
...
...
package.json
View file @
d959e23
...
@@ -15,7 +15,7 @@
...
@@ -15,7 +15,7 @@
"el-tree-transfer"
:
"^2.2.6"
,
"el-tree-transfer"
:
"^2.2.6"
,
"element-ui"
:
"^2.4.5"
,
"element-ui"
:
"^2.4.5"
,
"glsx-common"
:
"^2.0.4"
,
"glsx-common"
:
"^2.0.4"
,
"glsx-components"
:
"^1.
2.5
"
,
"glsx-components"
:
"^1.
5.3
"
,
"vod-js-sdk-v6"
:
"^1.5.0"
,
"vod-js-sdk-v6"
:
"^1.5.0"
,
"vue"
:
"^2.6.10"
,
"vue"
:
"^2.6.10"
,
"vue-router"
:
"^3.1.3"
,
"vue-router"
:
"^3.1.3"
,
...
...
src/main.js
View file @
d959e23
...
@@ -20,4 +20,5 @@ Vue.prototype.size = 'small'
...
@@ -20,4 +20,5 @@ Vue.prototype.size = 'small'
start
()
start
()
export
{
bootstrap
,
mount
,
unmount
}
from
'@/setup'
export
{
bootstrap
,
mount
,
unmount
}
from
'@/setup'
export
const
http
=
params
=>
Vue
.
prototype
.
$http
(
params
)
export
const
http
=
params
=>
Vue
.
prototype
.
$http
(
params
)
export
const
http2
=
params
=>
Vue
.
prototype
.
$http2
(
params
)
export
const
http_common
=
params
=>
Vue
.
prototype
.
$http_common
(
params
)
export
const
http_common
=
params
=>
Vue
.
prototype
.
$http_common
(
params
)
src/setup/qiankun.js
View file @
d959e23
...
@@ -20,7 +20,7 @@ let instance = null
...
@@ -20,7 +20,7 @@ let instance = null
Vue
.
use
(
ElementUI
)
Vue
.
use
(
ElementUI
)
Vue
.
use
(
GLTable
)
Vue
.
use
(
GLTable
)
export
async
function
bootstrap
({
history
,
common
,
messenger
,
globalState
})
{
export
async
function
bootstrap
({
history
,
common
,
messenger
,
globalState
})
{
const
{
response
,
request
,
sign
,
secret
,
sign_common
,
request_common
}
=
await
fetchConfig
()
const
{
response
,
request
,
request2
,
sign
,
secret
,
sign_common
,
request_common
}
=
await
fetchConfig
()
Vue
.
prototype
.
$history
=
history
Vue
.
prototype
.
$history
=
history
Vue
.
prototype
.
$messenger
=
messenger
Vue
.
prototype
.
$messenger
=
messenger
Vue
.
prototype
.
$globalState
=
globalState
Vue
.
prototype
.
$globalState
=
globalState
...
@@ -28,6 +28,7 @@ export async function bootstrap({ history, common, messenger, globalState }) {
...
@@ -28,6 +28,7 @@ export async function bootstrap({ history, common, messenger, globalState }) {
Vue
.
prototype
.
$message
=
message
Vue
.
prototype
.
$message
=
message
Vue
.
prototype
.
$messageBox
=
messageBox
Vue
.
prototype
.
$messageBox
=
messageBox
Vue
.
prototype
.
$http
=
new
common
.
Http
({
response
,
request
,
sign
,
secret
,
alert
:
message
.
error
,
headers
:
{
token
:
globalState
.
session
.
token
}
})
Vue
.
prototype
.
$http
=
new
common
.
Http
({
response
,
request
,
sign
,
secret
,
alert
:
message
.
error
,
headers
:
{
token
:
globalState
.
session
.
token
}
})
Vue
.
prototype
.
$http2
=
new
common
.
Http
({
response
,
request
:
request2
,
sign
,
secret
,
alert
:
message
.
error
,
headers
:
{
token
:
globalState
.
session
.
token
}
})
Vue
.
prototype
.
$http_common
=
new
common
.
Http
({
response
,
signWay
:
'md5'
,
request
:
request_common
,
sign
:
sign_common
,
secret
,
alert
:
ElementUI
.
Message
.
error
,
headers
:
{
TGT
:
globalState
.
session
.
token
}
})
Vue
.
prototype
.
$http_common
=
new
common
.
Http
({
response
,
signWay
:
'md5'
,
request
:
request_common
,
sign
:
sign_common
,
secret
,
alert
:
ElementUI
.
Message
.
error
,
headers
:
{
TGT
:
globalState
.
session
.
token
}
})
// Vue.prototype.$setGlobalState = globalState.actions.setGlobalState
// Vue.prototype.$setGlobalState = globalState.actions.setGlobalState
Vue
.
use
(
GLButton
,
{
permissions
:
globalState
.
permissions
||
[
'1-1-1-1'
,
'2-1-1-1'
,
'3-1-1-1'
]
})
Vue
.
use
(
GLButton
,
{
permissions
:
globalState
.
permissions
||
[
'1-1-1-1'
,
'2-1-1-1'
,
'3-1-1-1'
]
})
...
...
src/views/material/addMaterial.vue
View file @
d959e23
<
template
>
<
template
>
<div
class=
"container content"
>
<div
class=
"container content "
v-loading=
"loading"
>
<el-form
ref=
"materialAddForm"
:model=
"materialAddForm"
:label-width=
"defaultLabelWidth"
:rules=
"materialAddFormRules"
>
<el-form
ref=
"materialAddForm"
:model=
"materialAddForm"
:label-width=
"defaultLabelWidth"
:rules=
"materialAddFormRules"
>
<div
class=
"creat-material"
>
<div
class=
"creat-material"
>
<h4>
{{
title
}}
</h4>
<h4>
{{
title
}}
</h4>
<el-divider></el-divider>
<el-divider></el-divider>
<div
class=
"m-l-20"
>
<div
class=
"m-l-20"
>
<el-form-item
v-if=
"routeInfo.addOrEdit == 1"
label=
"选择素材组:"
prop=
"groupId"
>
<el-form-item
v-if=
"routeInfo.addOrEdit == 1"
label=
"选择素材组:"
prop=
"groupId"
>
<el-select
v-model=
"materialAddForm.groupId"
placeholder=
"全部"
:size=
"size"
>
<el-select
v-model=
"materialAddForm.groupId"
placeholder=
"全部"
:size=
"size"
>
<el-option
v-for=
"item in groupCounter"
:key=
"item.id"
:label=
"item.materialGroupName"
:value=
"item.id"
></el-option>
<el-option
v-for=
"item in groupCounter"
:key=
"item.id"
:label=
"item.materialGroupName"
:value=
"item.id"
></el-option>
</el-select>
</el-select>
</el-form-item>
</el-form-item>
<el-form-item
v-else
label=
"选择素材组:"
prop=
"selectMaterialGroupName"
>
<el-form-item
v-else
label=
"选择素材组:"
prop=
"selectMaterialGroupName"
>
<el-select
v-model=
"materialAddForm.groupName"
placeholder=
"全部"
:size=
"size"
disabled
>
<el-select
v-model=
"materialAddForm.groupName"
placeholder=
"全部"
:size=
"size"
disabled
>
<el-option
v-for=
"item in groupCounter"
:key=
"item.id"
:label=
"item.materialGroupName"
:value=
"item.id"
></el-option>
<el-option
v-for=
"item in groupCounter"
:key=
"item.id"
:label=
"item.materialGroupName"
:value=
"item.id"
></el-option>
</el-select>
</el-select>
</el-form-item>
</el-form-item>
<el-form-item
label=
"素材名称:"
prop=
"materialName"
>
<el-form-item
label=
"素材名称:"
prop=
"materialName"
>
<el-input
v-model=
"materialAddForm.materialName"
:size=
"size"
placeholder=
"请输入素材名称"
maxlength=
"30"
></el-input>
<el-input
v-model=
"materialAddForm.materialName"
:size=
"size"
placeholder=
"请输入素材名称"
maxlength=
"30"
></el-input>
</el-form-item>
</el-form-item>
<el-form-item
label=
"素材类型:"
prop=
"materialType"
>
<el-form-item
label=
"素材类型:"
prop=
"materialType"
>
<el-radio-group
v-model=
"materialAddForm.materialType"
@
change=
"radioChange"
:disabled=
"routeInfo.addOrEdit == 2 && routeInfo.status != 1"
>
<el-radio-group
v-model=
"materialAddForm.materialType"
@
change=
"radioChange"
:disabled=
"routeInfo.addOrEdit == 2 && routeInfo.status != 1"
>
<el-radio
:label=
"1"
>
PDF文件
</el-radio>
<el-radio
:label=
"1"
>
PDF文件
</el-radio>
<!--
<el-radio
:label=
"2"
>
自定义链接
</el-radio>
-->
<!--
<el-radio
:label=
"2"
>
自定义链接
</el-radio>
-->
<el-radio
:label=
"3"
>
图文
</el-radio>
<el-radio
:label=
"3"
>
图文
</el-radio>
...
@@ -27,8 +32,11 @@
...
@@ -27,8 +32,11 @@
<!-- 选择PDF -->
<!-- 选择PDF -->
<div
v-show=
"materialAddForm.materialType == 1"
>
<div
v-show=
"materialAddForm.materialType == 1"
>
<div
class=
"pdf-show"
>
<div
class=
"pdf-show"
>
<input
type=
"file"
style=
"opacity: 0"
accept=
".pdf"
:disabled=
"routeInfo.addOrEdit == 2 && routeInfo.status != 1"
@
change=
"e => handlePdfChange(e)"
/>
<input
type=
"file"
style=
"opacity: 0"
accept=
".pdf"
<el-button
icon=
"el-icon-plus"
:size=
"size"
:disabled=
"routeInfo.addOrEdit == 2 && routeInfo.status != 1"
>
选择文件
</el-button>
:disabled=
"routeInfo.addOrEdit == 2 && routeInfo.status != 1"
@
change=
"e => handlePdfChange(e)"
/>
<el-button
icon=
"el-icon-plus"
:size=
"size"
:disabled=
"routeInfo.addOrEdit == 2 && routeInfo.status != 1"
>
选择文件
</el-button>
</div>
</div>
<!--
<div
v-if=
"pdfUrl"
>
{{
pdfUrl
}}
</div>
-->
<!--
<div
v-if=
"pdfUrl"
>
{{
pdfUrl
}}
</div>
-->
<ul
v-if=
"pdfName || materialAddForm.materialUrl"
>
<ul
v-if=
"pdfName || materialAddForm.materialUrl"
>
...
@@ -49,6 +57,47 @@
...
@@ -49,6 +57,47 @@
<!-- 选择图文 -->
<!-- 选择图文 -->
<div
v-show=
"materialAddForm.materialType == 3"
>
<div
v-show=
"materialAddForm.materialType == 3"
>
<textBox
@
change=
"writeChange"
ref=
"textBox"
@
forbid=
"forbidEdit"
></textBox>
<textBox
@
change=
"writeChange"
ref=
"textBox"
@
forbid=
"forbidEdit"
></textBox>
<el-form-item
label=
"图片:"
class=
"photoWrap"
>
<div
class=
"img-div"
>
<div
class=
"put-img"
v-for=
"(item,index) in materialAddForm.urlArr"
:key=
"item"
v-show=
"materialAddForm.urlArr[index]"
>
<img
:src=
"item"
alt=
""
/>
<div
class=
"mask"
v-if=
"item"
>
<h3>
<el-popover
placement=
"top"
trigger=
"click"
>
<div>
<img
class=
"img-plus"
:src=
"item"
alt=
""
/>
</div>
<img
slot=
"reference"
src=
"@/assets/material/view.png"
alt=
""
/>
</el-popover>
<img
class=
"del-img"
src=
"@/assets/material/dele.png"
alt=
""
@
click=
"deleteImg('urlArr',item)"
/>
</h3>
</div>
</div>
<div
class=
"avatar-uploader-desc"
>
<i
class=
"el-icon-plus avatar-uploader-desc-icon"
></i>
<div
class=
"avatar-uploader-desc-word"
>
上传照片
</div>
<input
type=
"file"
style=
"opacity: 0"
accept=
".jpg, .jpeg, .png"
@
change=
"e => handleImgChange(e,'urlArr')"
/>
</div>
<!--
<div
@
click=
"phoneVisible = !phoneVisible"
class=
"view-phone"
>
查看效果>
</div>
-->
</div>
</el-form-item>
<el-form-item
label=
"视频:"
class=
"dis-in-block"
prop=
"mediaUrl"
>
<div
class=
"activity-img muti-imgs img-w-h"
>
<div
class=
"add-border"
v-show=
"!materialAddForm.mediaUrl"
>
<div
class=
"add-icon"
><i
class=
"el-icon-plus"
></i></div>
<div
class=
"add-text"
>
上传
</div>
</div>
<div
class=
"video-panel"
v-if=
"materialAddForm.mediaUrl"
>
<video
id=
"video"
width=
"100%"
height=
"100%"
preload
loop
muted
>
<source
:src=
"materialAddForm.mediaUrl"
type=
"video/mp4"
/>
</video>
<i
class=
"el-icon-video-play"
@
click=
"handleLook('video')"
></i>
<i
class=
"el-icon-close"
@
click=
"materialAddForm.mediaUrl = ''"
></i>
</div>
<input
v-if=
"!materialAddForm.mediaUrl"
type=
"file"
class=
"activity-Input img-w-h"
accept=
"video/*"
@
change=
"e => handleVideoChange(e)"
style=
"opacity: 0"
/>
</div>
</el-form-item>
</div>
</div>
<div
class=
"space"
></div>
<div
class=
"space"
></div>
</el-form-item>
</el-form-item>
...
@@ -62,55 +111,63 @@
...
@@ -62,55 +111,63 @@
<span
slot=
"label"
>
<span
slot=
"label"
>
<span
class=
"label-word"
>
<span
class=
"label-word"
>
业务类型
业务类型
<el-popover
placement=
"top-start"
width=
"200"
trigger=
"hover"
content=
"给素材添加业务类型,客户可根据业务类型筛选,也可在客户浏览了该素材时能及时提醒跟进员工,以提高客户成单率。"
>
<el-popover
placement=
"top-start"
width=
"200"
trigger=
"hover"
<img
slot=
"reference"
src=
"@/assets/question.png"
alt=
""
/>
content=
"给素材添加业务类型,客户可根据业务类型筛选,也可在客户浏览了该素材时能及时提醒跟进员工,以提高客户成单率。"
>
<img
slot=
"reference"
src=
"@/assets/question.png"
alt=
""
/>
</el-popover>
</el-popover>
:
:
</span>
</span>
</span>
</span>
<el-checkbox-group
v-model=
"materialAddForm.businessType"
>
<el-checkbox-group
v-model=
"materialAddForm.businessType"
>
<el-checkbox
v-for=
"value in businessTypes"
:key=
"value.businessName"
:label=
"value.id"
>
{{
value
.
businessName
}}
</el-checkbox>
<el-checkbox
v-for=
"value in businessTypes"
:key=
"value.businessName"
:label=
"value.id"
>
{{
value
.
businessName
}}
</el-checkbox>
</el-checkbox-group>
</el-checkbox-group>
</el-form-item>
</el-form-item>
<el-form-item
prop=
"isNotifySender"
>
<!--
<el-form-item
prop=
"isNotifySender"
>
-->
<span
slot=
"label"
>
<!--
<span
slot=
"label"
>
-->
<span
class=
"label-word"
>
<!--
<span
class=
"label-word"
>
-->
动态通知
<!-- 动态通知-->
<el-popover
placement=
"top-start"
width=
"200"
trigger=
"hover"
content=
"有效浏览:指客户在页面的停留时间超过15秒并且有交互行为,非完全静止"
>
<!--
<el-popover
placement=
"top-start"
width=
"200"
trigger=
"hover"
--
>
<img
slot=
"reference"
src=
"@/assets/question.png"
alt=
""
/>
<!-- content="有效浏览:指客户在页面的停留时间超过15秒并且有交互行为,非完全静止">-->
</el-popover>
<!--
<img
slot=
"reference"
src=
"@/assets/question.png"
alt=
""
/>
-->
:
<!--
</el-popover>
-->
</span>
<!-- :-->
</span>
<!--
</span>
-->
<el-checkbox
:value=
"materialAddForm.isNotifySender"
:checked=
"checked"
@
change=
"notifyChange"
>
客户打开素材链接时通知发送人
</el-checkbox>
<!--
</span>
-->
<span
class=
"track-tips track-info"
>
(客户不包括本商户的员工)
</span>
<!--
<el-checkbox
:value=
"materialAddForm.isNotifySender"
:checked=
"checked"
@
change=
"notifyChange"
>
-->
</el-form-item>
<!-- 客户打开素材链接时通知发送人-->
<el-form-item
prop=
"tagJson"
>
<!--
</el-checkbox>
-->
<span
slot=
"label"
>
<!--
<span
class=
"track-tips track-info"
>
(客户不包括本商户的员工)
</span>
-->
<span
class=
"label-word"
>
<!--
</el-form-item>
-->
行为标签
<!--
<el-form-item
prop=
"tagJson"
>
-->
<el-popover
placement=
"top-start"
width=
"200"
trigger=
"hover"
content=
"标签失效后在客户信息中看不到此标签,但是在素材效果统计的记录仍然存在"
>
<!--
<span
slot=
"label"
>
-->
<img
slot=
"reference"
src=
"@/assets/question.png"
alt=
""
/>
<!--
<span
class=
"label-word"
>
-->
</el-popover>
<!-- 行为标签-->
:
<!--
<el-popover
placement=
"top-start"
width=
"200"
trigger=
"hover"
--
>
</span>
<!-- content="标签失效后在客户信息中看不到此标签,但是在素材效果统计的记录仍然存在">-->
</span>
<!--
<img
slot=
"reference"
src=
"@/assets/question.png"
alt=
""
/>
-->
<span
class=
"track-behavior"
>
给浏览了素材的客户自动打上标签,并且标签在30天后自动失效
</span>
<!--
</el-popover>
-->
<span
class=
"track-tips track-info"
>
(最多支持3个标签)
</span>
<!-- :-->
<!-- 选择标签展示 -->
<!--
</span>
-->
<div
class=
"tag-show"
>
<!--
</span>
-->
<div
v-show=
"tagging.length != 0"
:key=
"key"
class=
"input-tag-wrapper"
>
<!--
<span
class=
"track-behavior"
>
给浏览了素材的客户自动打上标签,并且标签在30天后自动失效
</span>
-->
<span
v-for=
"(tag, idx) in tagging"
:key=
"idx"
>
<!--
<span
class=
"track-tips track-info"
>
(最多支持3个标签)
</span>
-->
<el-tag
v-for=
"(tagItem, idx1) in tag.labelList"
:key=
"idx1"
:size=
"size"
type=
"info"
closable
:disable-transitions=
"false"
@
close=
"removeTag(tag, idx1, idx)"
>
{{
tagItem
.
name
}}
</el-tag>
<!-- <!– 选择标签展示 –>-->
</span>
<!--
<div
class=
"tag-show"
>
-->
</div>
<!--
<div
v-show=
"tagging.length != 0"
:key=
"key"
class=
"input-tag-wrapper"
>
-->
<el-button
:size=
"size"
@
click=
"openLabel"
>
<!--
<span
v-for=
"(tag, idx) in tagging"
:key=
"idx"
>
-->
<i
class=
"el-icon-plus"
></i>
<!--
<el-tag
v-for=
"(tagItem, idx1) in tag.labelList"
:key=
"idx1"
:size=
"size"
type=
"info"
closable--
>
选择标签
<!-- :disable-transitions="false" @close="removeTag(tag, idx1, idx)">
{{
tagItem
.
name
}}
</el-tag>
-->
</el-button>
<!--
</span>
-->
</div>
<!--
</div>
-->
<div
class=
"space"
></div>
<!--
<el-button
:size=
"size"
@
click=
"openLabel"
>
-->
</el-form-item>
<!--
<i
class=
"el-icon-plus"
></i>
-->
<!-- 选择标签-->
<!--
</el-button>
-->
<!--
</div>
-->
<!--
<div
class=
"space"
></div>
-->
<!--
</el-form-item>
-->
</div>
</div>
</div>
</div>
<div
class=
"share"
>
<div
class=
"share"
>
...
@@ -134,31 +191,34 @@
...
@@ -134,31 +191,34 @@
<div
class=
"share-desc"
v-show=
"descVisible"
>
<div
class=
"share-desc"
v-show=
"descVisible"
>
<div
class=
"share-desc-left m-l-20"
>
<div
class=
"share-desc-left m-l-20"
>
<el-form-item
label=
"分享标题:"
>
<el-form-item
label=
"分享标题:"
>
<el-input
v-model=
"materialAddForm.materialTitle"
:size=
"size"
maxlength=
"30"
show-word-limit
placeholder=
"请输入自定义标题"
></el-input>
<el-input
v-model=
"materialAddForm.materialTitle"
:size=
"size"
maxlength=
"30"
show-word-limit
placeholder=
"请输入自定义标题"
></el-input>
</el-form-item>
</el-form-item>
<el-form-item
label=
"描述:"
>
<el-form-item
label=
"描述:"
>
<el-input
type=
"textarea"
v-model=
"materialAddForm.description"
:size=
"size"
maxlength=
"30"
show-word-limit
placeholder=
"请输入自定义描述"
></el-input>
<el-input
type=
"textarea"
v-model=
"materialAddForm.description"
:size=
"size"
maxlength=
"30"
show-word-limit
placeholder=
"请输入自定义描述"
></el-input>
</el-form-item>
</el-form-item>
<el-form-item
label=
"封面:"
>
<el-form-item
label=
"封面:"
>
<div
class=
"img-div"
>
<div
class=
"img-div"
>
<div
class=
"put-img"
v-show=
"materialAddForm.titleUrl"
>
<div
class=
"put-img"
v-show=
"materialAddForm.titleUrl"
>
<img
:src=
"materialAddForm.titleUrl"
alt=
""
/>
<img
:src=
"materialAddForm.titleUrl"
alt=
""
/>
<div
class=
"mask"
v-if=
"materialAddForm.titleUrl"
>
<div
class=
"mask"
v-if=
"materialAddForm.titleUrl"
>
<h3>
<h3>
<el-popover
placement=
"top"
trigger=
"click"
>
<el-popover
placement=
"top"
trigger=
"click"
>
<div>
<div>
<img
class=
"img-plus"
:src=
"materialAddForm.titleUrl"
alt=
""
/>
<img
class=
"img-plus"
:src=
"materialAddForm.titleUrl"
alt=
""
/>
</div>
</div>
<img
slot=
"reference"
src=
"@/assets/material/view.png"
alt=
""
/>
<img
slot=
"reference"
src=
"@/assets/material/view.png"
alt=
""
/>
</el-popover>
</el-popover>
<img
class=
"del-img"
src=
"@/assets/material/dele.png"
alt=
""
@
click=
"deleteImg
"
/>
<img
class=
"del-img"
src=
"@/assets/material/dele.png"
alt=
""
@
click=
"deleteImg
('titleUrl')"
/>
</h3>
</h3>
</div>
</div>
</div>
</div>
<div
class=
"avatar-uploader-desc"
>
<div
class=
"avatar-uploader-desc"
>
<i
class=
"el-icon-plus avatar-uploader-desc-icon"
></i>
<i
class=
"el-icon-plus avatar-uploader-desc-icon"
></i>
<div
class=
"avatar-uploader-desc-word"
>
上传照片
</div>
<div
class=
"avatar-uploader-desc-word"
>
上传照片
</div>
<input
type=
"file"
style=
"opacity: 0"
accept=
".jpg, .jpeg, .png"
@
change=
"e => handleImgChange(e)"
/>
<input
type=
"file"
style=
"opacity: 0"
accept=
".jpg, .jpeg, .png"
@
change=
"e => handleImgChange(e,'titleUrl')"
/>
</div>
</div>
<!--
<div
@
click=
"phoneVisible = !phoneVisible"
class=
"view-phone"
>
查看效果>
</div>
-->
<!--
<div
@
click=
"phoneVisible = !phoneVisible"
class=
"view-phone"
>
查看效果>
</div>
-->
</div>
</div>
...
@@ -166,14 +226,14 @@
...
@@ -166,14 +226,14 @@
</div>
</div>
<div
class=
"share-desc-right"
>
<div
class=
"share-desc-right"
>
<div
class=
"share-desc-right-box"
>
<div
class=
"share-desc-right-box"
>
<img
class=
"share-desc-right-box-phone"
src=
"@/assets/material/phone.png"
alt=
""
/>
<img
class=
"share-desc-right-box-phone"
src=
"@/assets/material/phone.png"
alt=
""
/>
<div
class=
"content-show"
>
<div
class=
"content-show"
>
<div>
<div>
<div
class=
"content-title"
>
{{
materialAddForm
.
materialTitle
}}
</div>
<div
class=
"content-title"
>
{{
materialAddForm
.
materialTitle
}}
</div>
<div
class=
"content-word"
>
{{
materialAddForm
.
description
}}
</div>
<div
class=
"content-word"
>
{{
materialAddForm
.
description
}}
</div>
</div>
</div>
<div
class=
"content-show-img"
v-show=
"materialAddForm.titleUrl"
>
<div
class=
"content-show-img"
v-show=
"materialAddForm.titleUrl"
>
<img
:src=
"materialAddForm.titleUrl"
alt=
""
/>
<img
:src=
"materialAddForm.titleUrl"
alt=
""
/>
</div>
</div>
</div>
</div>
</div>
</div>
...
@@ -188,18 +248,26 @@
...
@@ -188,18 +248,26 @@
<el-button
@
click=
"handleCancel"
class=
"btn-cancle"
>
取消
</el-button>
<el-button
@
click=
"handleCancel"
class=
"btn-cancle"
>
取消
</el-button>
<el-button
@
click=
"handleSubmit"
type=
"primary"
>
确定
</el-button>
<el-button
@
click=
"handleSubmit"
type=
"primary"
>
确定
</el-button>
</GLFooter>
</GLFooter>
<el-dialog
class=
"image-dialog"
:visible
.
sync=
"dialogVisibleImg"
width=
"30%"
>
<big-view
ref=
"viewForm"
v-if=
"dialogVisibleImg"
:dialogSrc=
"dialogSrc"
:dialogType=
"dialogType"
></big-view>
</el-dialog>
</div>
</div>
</
template
>
</
template
>
<
script
>
<
script
>
import
textBox
from
'@/views/material/components/textBox'
import
textBox
from
'@/views/material/components/textBox'
import
SelectLabel
from
'@/views/material/components/selectLable'
import
SelectLabel
from
'@/views/material/components/selectLable'
import
bigView
from
'@/components/big-view'
import
upload
from
'@/api/uploadApi'
import
uploadMixin
from
'@/mixins/upload'
// import pdfReviewDia from './components/pdfReviewDia.vue'
// import pdfReviewDia from './components/pdfReviewDia.vue'
export
default
{
export
default
{
name
:
'addMaterialForm'
,
name
:
'addMaterialForm'
,
mixins
:
[
uploadMixin
],
components
:
{
components
:
{
textBox
,
textBox
,
SelectLabel
SelectLabel
,
bigView
// pdfReviewDia
// pdfReviewDia
},
},
data
()
{
data
()
{
...
@@ -209,6 +277,10 @@ export default {
...
@@ -209,6 +277,10 @@ export default {
1
:
'创建营销素材'
,
1
:
'创建营销素材'
,
2
:
'编辑营销素材'
2
:
'编辑营销素材'
},
},
loading
:
false
,
dialogVisibleImg
:
false
,
dialogSrc
:
''
,
dialogType
:
''
,
routeInfo
:
{},
routeInfo
:
{},
dialogVisible
:
false
,
dialogVisible
:
false
,
tagging
:
[],
tagging
:
[],
...
@@ -228,7 +300,9 @@ export default {
...
@@ -228,7 +300,9 @@ export default {
tagJson
:
[],
// 行为标签
tagJson
:
[],
// 行为标签
materialTitle
:
''
,
// 分享标题
materialTitle
:
''
,
// 分享标题
description
:
''
,
// 描述
description
:
''
,
// 描述
titleUrl
:
''
// 封面
titleUrl
:
''
,
// 封面
urlArr
:
[],
mediaUrl
:
''
},
},
groupCounter
:
[],
groupCounter
:
[],
// 分享设置显示
// 分享设置显示
...
@@ -237,18 +311,18 @@ export default {
...
@@ -237,18 +311,18 @@ export default {
// phoneVisible: false,
// phoneVisible: false,
businessTypes
:
[],
businessTypes
:
[],
materialAddFormRules
:
{
materialAddFormRules
:
{
groupId
:
[{
required
:
true
,
message
:
'请选择素材组'
,
trigger
:
'change'
}],
groupId
:
[{
required
:
true
,
message
:
'请选择素材组'
,
trigger
:
'change'
}],
materialName
:
[
materialName
:
[
{
required
:
true
,
message
:
'请输入素材名称'
,
trigger
:
'change'
},
{
required
:
true
,
message
:
'请输入素材名称'
,
trigger
:
'change'
},
{
max
:
30
,
message
:
'素材名称长度不能超过30'
,
trigger
:
'blur'
}
{
max
:
30
,
message
:
'素材名称长度不能超过30'
,
trigger
:
'blur'
}
],
],
materialType
:
[{
required
:
true
,
message
:
'请选择素材类型'
,
trigger
:
'change'
}],
materialType
:
[{
required
:
true
,
message
:
'请选择素材类型'
,
trigger
:
'change'
}],
businessType
:
[{
required
:
true
,
message
:
'请选择业务类型'
,
trigger
:
'change'
}]
businessType
:
[{
required
:
true
,
message
:
'请选择业务类型'
,
trigger
:
'change'
}]
},
},
linkRules
:
{
linkRules
:
{
link
:
[
link
:
[
{
required
:
true
,
message
:
'请输入链接地址'
,
trigger
:
'change'
},
{
required
:
true
,
message
:
'请输入链接地址'
,
trigger
:
'change'
},
{
max
:
150
,
message
:
'链接地址长度不能超过30'
,
trigger
:
'blur'
}
{
max
:
150
,
message
:
'链接地址长度不能超过30'
,
trigger
:
'blur'
}
]
]
}
}
}
}
...
@@ -264,6 +338,41 @@ export default {
...
@@ -264,6 +338,41 @@ export default {
this
.
getListEntBusinessType
()
this
.
getListEntBusinessType
()
},
},
methods
:
{
methods
:
{
handleLook
(
type
)
{
this
.
dialogType
=
type
this
.
dialogVisibleImg
=
true
this
.
dialogSrc
=
type
==
'img'
?
this
.
materialAddForm
.
coverUrl
:
this
.
materialAddForm
.
mediaUrl
},
handleVideoChange
(
e
)
{
const
self
=
this
let
file
=
e
.
target
.
files
[
0
]
const
isLt
=
file
.
size
/
1024
/
1024
<
20
if
(
!
isLt
)
{
this
.
$message
.
error
(
'上传视频大小不能超过'
+
20
+
'MB!'
)
return
true
}
self
.
loading
=
true
upload
.
init
().
then
(
res
=>
{
if
(
res
.
status
==
0
)
{
upload
.
uploaded
(
file
)
.
then
(
res
=>
{
const
videoUrl
=
res
.
video
.
url
self
.
$set
(
self
.
materialAddForm
,
'mediaUrl'
,
videoUrl
)
self
.
loading
=
false
})
.
finally
(
end
=>
{
console
.
log
(
end
)
})
upload
.
uploadEvent
(
''
,
res
=>
{
console
.
log
(
res
,
'视频上传完成'
)
})
upload
.
uploadEvent
(
'media_progress'
,
res
=>
{
console
.
log
(
res
)
})
}
})
},
getParams
()
{
getParams
()
{
var
params
=
JSON
.
parse
(
JSON
.
stringify
(
this
.
materialAddForm
))
var
params
=
JSON
.
parse
(
JSON
.
stringify
(
this
.
materialAddForm
))
let
tagging
=
this
.
tagging
.
map
(
item
=>
{
let
tagging
=
this
.
tagging
.
map
(
item
=>
{
...
@@ -422,7 +531,7 @@ export default {
...
@@ -422,7 +531,7 @@ export default {
const
imgFile
=
e
.
target
.
result
const
imgFile
=
e
.
target
.
result
// const base64 = file.name.split('.')[1] + '@' + imgFile.split(',')[1]
// const base64 = file.name.split('.')[1] + '@' + imgFile.split(',')[1]
const
base64
=
file
.
name
.
slice
(
-
3
)
+
'@'
+
imgFile
.
split
(
','
)[
1
]
const
base64
=
file
.
name
.
slice
(
-
3
)
+
'@'
+
imgFile
.
split
(
','
)[
1
]
this
.
$apis
.
common
.
pictureUpload
({
file
:
base64
}).
then
(
res
=>
{
this
.
$apis
.
common
.
pictureUpload
({
file
:
base64
}).
then
(
res
=>
{
if
(
res
)
{
if
(
res
)
{
this
.
pdfUrl
=
res
this
.
pdfUrl
=
res
this
.
pdfName
=
file
.
name
this
.
pdfName
=
file
.
name
...
@@ -436,7 +545,7 @@ export default {
...
@@ -436,7 +545,7 @@ export default {
}
}
},
},
// 上传图片
// 上传图片
handleImgChange
(
e
)
{
handleImgChange
(
e
,
params
)
{
var
file
=
e
.
srcElement
.
files
[
0
]
var
file
=
e
.
srcElement
.
files
[
0
]
var
reader
=
new
FileReader
()
var
reader
=
new
FileReader
()
// 默认1MB
// 默认1MB
...
@@ -450,10 +559,18 @@ export default {
...
@@ -450,10 +559,18 @@ export default {
reader
.
onload
=
e
=>
{
reader
.
onload
=
e
=>
{
const
imgFile
=
e
.
target
.
result
const
imgFile
=
e
.
target
.
result
const
base64
=
file
.
name
.
split
(
'.'
)[
file
.
name
.
split
(
'.'
).
length
-
1
]
+
'@'
+
imgFile
.
split
(
','
)[
1
]
const
base64
=
file
.
name
.
split
(
'.'
)[
file
.
name
.
split
(
'.'
).
length
-
1
]
+
'@'
+
imgFile
.
split
(
','
)[
1
]
this
.
$apis
.
common
.
pictureUpload
({
file
:
base64
}).
then
(
res
=>
{
this
.
$apis
.
common
.
pictureUpload
({
file
:
base64
}).
then
(
res
=>
{
if
(
res
)
{
if
(
res
)
{
// console.log(res)
if
(
Array
.
isArray
(
this
.
materialAddForm
[
params
])){
this
.
materialAddForm
.
titleUrl
=
res
if
(
this
.
materialAddForm
[
params
].
length
>
8
){
this
.
$message
.
error
(
'图片最多可上传9张'
)
return
}
else
{
this
.
materialAddForm
[
params
].
push
(
res
)
}
}
else
{
this
.
materialAddForm
[
params
]
=
res
}
}
}
})
})
}
}
...
@@ -590,8 +707,12 @@ export default {
...
@@ -590,8 +707,12 @@ export default {
this
.
isUpdate
=
true
this
.
isUpdate
=
true
},
},
// 删除上传图片
// 删除上传图片
deleteImg
()
{
deleteImg
(
params
,
content
)
{
this
.
materialAddForm
.
titleUrl
=
''
if
(
Array
.
isArray
(
this
.
materialAddForm
[
params
])){
this
.
materialAddForm
[
params
]
=
this
.
materialAddForm
[
params
].
filter
((
item
)
=>
item
!==
content
);
}
else
{
this
.
materialAddForm
[
params
]
=
''
}
},
},
// 删除pdf
// 删除pdf
delPdf
()
{
delPdf
()
{
...
@@ -607,6 +728,10 @@ export default {
...
@@ -607,6 +728,10 @@ export default {
</
script
>
</
script
>
<
style
lang=
"scss"
scoped
>
<
style
lang=
"scss"
scoped
>
/
deep
/
.el-form-item__label
{
width
:
154px
;
}
.input-tag-wrapper
{
.input-tag-wrapper
{
max-height
:
75px
;
max-height
:
75px
;
overflow
:
auto
;
overflow
:
auto
;
...
@@ -621,18 +746,21 @@ export default {
...
@@ -621,18 +746,21 @@ export default {
align-items
:
center
;
align-items
:
center
;
margin-top
:
6px
;
margin-top
:
6px
;
font-size
:
14px
;
font-size
:
14px
;
i
{
i
{
color
:
#75acff
;
color
:
#75acff
;
margin-right
:
3px
;
margin-right
:
3px
;
font-size
:
14px
;
font-size
:
14px
;
}
}
}
}
.el-tag
{
.el-tag
{
margin-right
:
4px
;
margin-right
:
4px
;
height
:
26px
;
height
:
26px
;
line-height
:
24px
;
line-height
:
24px
;
margin-bottom
:
5px
;
margin-bottom
:
5px
;
}
}
.tag-input
{
.tag-input
{
background
:
transparent
;
background
:
transparent
;
border
:
none
!important
;
border
:
none
!important
;
...
@@ -642,6 +770,7 @@ export default {
...
@@ -642,6 +770,7 @@ export default {
padding-left
:
0
;
padding-left
:
0
;
width
:
100px
;
width
:
100px
;
}
}
.creat-material
,
.creat-material
,
.track
,
.track
,
.share
,
.share
,
...
@@ -652,6 +781,80 @@ export default {
...
@@ -652,6 +781,80 @@ export default {
.creat-material
,
.creat-material
,
.track
{
.track
{
margin-bottom
:
-10px
;
margin-bottom
:
-10px
;
.dis-in-block
{
margin-left
:
-154px
;
.activity-img
{
width
:
104px
;
height
:
104px
;
background
:
rgba
(
0
,
0
,
0
,
0.04
);
border
:
1px
solid
rgba
(
0
,
0
,
0
,
0.15
);
border-radius
:
4px
;
cursor
:
pointer
;
position
:
relative
;
input
{
cursor
:
pointer
;
font-size
:
0
;
position
:
absolute
;
top
:
0px
;
left
:
0px
;
width
:
100%
;
height
:
100%
;
}
.add-border
{
text-align
:
center
;
color
:
rgba
(
0
,
0
,
0
,
0.45
);
.add-icon
{
margin-top
:
20px
;
height
:
20px
;
font-size
:
17px
;
}
.add-text
{
height
:
30px
;
font-size
:
12px
;
}
}
}
.img-btns
,
img
{
width
:
100%
;
height
:
100%
;
}
.video-panel
{
width
:
100%
;
height
:
100%
;
display
:
flex
;
align-items
:
center
;
justify-content
:
center
;
position
:
relative
;
video
{
position
:
absolute
;
object-fit
:
fill
;
}
.el-icon-video-play
{
z-index
:
10
;
font-size
:
20px
;
color
:
#fff
;
cursor
:
pointer
;
}
.el-icon-close
{
position
:
absolute
;
top
:
0px
;
right
:
0px
;
background
:
#000000
;
color
:
#fff
;
}
}
}
}
}
.container
{
.container
{
...
@@ -661,12 +864,18 @@ export default {
...
@@ -661,12 +864,18 @@ export default {
font-weight
:
600
;
font-weight
:
600
;
color
:
rgba
(
0
,
0
,
0
,
0.85
);
color
:
rgba
(
0
,
0
,
0
,
0.85
);
margin
:
17px
0
17px
20px
;
margin
:
17px
0
17px
20px
;
&:first-child
{
&:first-child
{
padding-top
:
17px
;
padding-top
:
17px
;
margin-top
:
0
;
margin-top
:
0
;
}
}
}
}
}
}
.photoWrap
{
margin-top
:
20px
;
margin-left
:
-154px
;
}
.space
{
.space
{
margin-bottom
:
32px
;
margin-bottom
:
32px
;
}
}
...
@@ -676,9 +885,11 @@ export default {
...
@@ -676,9 +885,11 @@ export default {
font-size
:
14px
;
font-size
:
14px
;
color
:
#999999
;
color
:
#999999
;
}
}
&
-info
{
&
-info
{
margin-left
:
8px
;
margin-left
:
8px
;
}
}
&
-behavior
{
&
-behavior
{
color
:
#606266
;
color
:
#606266
;
}
}
...
@@ -686,9 +897,11 @@ export default {
...
@@ -686,9 +897,11 @@ export default {
.share
{
.share
{
margin-bottom
:
20px
;
margin-bottom
:
20px
;
&-container
{
&-container
{
display
:
flex
;
display
:
flex
;
justify-content
:
space-between
;
justify-content
:
space-between
;
.share-unfold
{
.share-unfold
{
span
{
span
{
font-size
:
12px
;
font-size
:
12px
;
...
@@ -697,6 +910,7 @@ export default {
...
@@ -697,6 +910,7 @@ export default {
}
}
}
}
}
}
&
-tips
{
&
-tips
{
color
:
#999999
;
color
:
#999999
;
font-size
:
14px
;
font-size
:
14px
;
...
@@ -707,10 +921,12 @@ export default {
...
@@ -707,10 +921,12 @@ export default {
.material-bottom
{
.material-bottom
{
height
:
78px
;
height
:
78px
;
position
:
relative
;
position
:
relative
;
.el-form-item
{
.el-form-item
{
position
:
absolute
;
position
:
absolute
;
top
:
25%
;
top
:
25%
;
left
:
40%
;
left
:
40%
;
.el-form-item__content
{
.el-form-item__content
{
margin-left
:
0
;
margin-left
:
0
;
}
}
...
@@ -722,31 +938,37 @@ export default {
...
@@ -722,31 +938,37 @@ export default {
.el-select--small
{
.el-select--small
{
width
:
432px
;
width
:
432px
;
}
}
.btn-cancle
{
.btn-cancle
{
border-color
:
#5850ff
;
border-color
:
#5850ff
;
color
:
#5850ff
;
color
:
#5850ff
;
}
}
.put-img
,
.put-img
,
.avatar-uploader-desc
,
.avatar-uploader-desc
,
.view-phone
{
.view-phone
{
float
:
left
;
float
:
left
;
margin-right
:
8px
;
margin-right
:
8px
;
.task
{
.task
{
width
:
104px
;
width
:
104px
;
height
:
104px
;
height
:
104px
;
border-radius
:
10px
;
border-radius
:
10px
;
}
}
}
}
.put-img
{
.put-img
{
width
:
104px
;
width
:
104px
;
height
:
104px
;
height
:
104px
;
border-radius
:
10px
;
border-radius
:
10px
;
display
:
inline-block
;
display
:
inline-block
;
position
:
relative
;
position
:
relative
;
img
{
img
{
width
:
104px
;
width
:
104px
;
height
:
104px
;
height
:
104px
;
}
}
.mask
{
.mask
{
position
:
absolute
;
position
:
absolute
;
background
:
rgba
(
101
,
101
,
101
,
0.6
);
background
:
rgba
(
101
,
101
,
101
,
0.6
);
...
@@ -757,34 +979,42 @@ export default {
...
@@ -757,34 +979,42 @@ export default {
width
:
100%
;
width
:
100%
;
height
:
100%
;
height
:
100%
;
border-radius
:
10px
;
border-radius
:
10px
;
h3
{
h3
{
text-align
:
center
;
text-align
:
center
;
margin-top
:
40%
;
margin-top
:
40%
;
img
{
img
{
width
:
16px
;
width
:
16px
;
height
:
16px
;
height
:
16px
;
}
}
.del-img
{
.del-img
{
padding-left
:
12px
;
padding-left
:
12px
;
}
}
}
}
}
}
}
}
.tag-show
{
.tag-show
{
margin-right
:
8px
;
margin-right
:
8px
;
margin-top
:
20px
;
margin-top
:
20px
;
.el-button
{
.el-button
{
display
:
inline-flex
;
display
:
inline-flex
;
color
:
#5850ff
;
color
:
#5850ff
;
}
}
}
}
.put-img
:hover
.mask
{
.put-img
:hover
.mask
{
opacity
:
1
;
opacity
:
1
;
}
}
.pdf-show
{
.pdf-show
{
display
:
inline-flex
;
display
:
inline-flex
;
position
:
relative
;
position
:
relative
;
height
:
32px
;
height
:
32px
;
input
{
input
{
position
:
absolute
;
position
:
absolute
;
top
:
0
;
top
:
0
;
...
@@ -793,12 +1023,14 @@ export default {
...
@@ -793,12 +1023,14 @@ export default {
height
:
100%
;
height
:
100%
;
}
}
}
}
.avatar-uploader-desc
{
.avatar-uploader-desc
{
width
:
104px
;
width
:
104px
;
height
:
104px
;
height
:
104px
;
border-radius
:
4px
;
border-radius
:
4px
;
border
:
1px
dashed
rgba
(
0
,
0
,
0
,
0.15
);
border
:
1px
dashed
rgba
(
0
,
0
,
0
,
0.15
);
position
:
relative
;
position
:
relative
;
&-icon
{
&-icon
{
width
:
16px
;
width
:
16px
;
height
:
16px
;
height
:
16px
;
...
@@ -806,12 +1038,14 @@ export default {
...
@@ -806,12 +1038,14 @@ export default {
top
:
28px
;
top
:
28px
;
left
:
44px
;
left
:
44px
;
}
}
&
-word
{
&
-word
{
position
:
absolute
;
position
:
absolute
;
top
:
58px
;
top
:
58px
;
left
:
24px
;
left
:
24px
;
color
:
#666666
;
color
:
#666666
;
}
}
input
{
input
{
position
:
absolute
;
position
:
absolute
;
top
:
0
;
top
:
0
;
...
@@ -820,28 +1054,34 @@ export default {
...
@@ -820,28 +1054,34 @@ export default {
height
:
100%
;
height
:
100%
;
}
}
}
}
.view-phone
{
.view-phone
{
margin-top
:
85px
;
margin-top
:
85px
;
color
:
#5850ff
;
color
:
#5850ff
;
}
}
.avatar
{
.avatar
{
width
:
178px
;
width
:
178px
;
height
:
178px
;
height
:
178px
;
display
:
block
;
display
:
block
;
}
}
.share-desc
{
.share-desc
{
padding-bottom
:
30px
;
padding-bottom
:
30px
;
display
:
flex
;
display
:
flex
;
justify-content
:
space-between
;
justify-content
:
space-between
;
&-right-box
{
&-right-box
{
margin-right
:
50px
;
margin-right
:
50px
;
width
:
290px
;
width
:
290px
;
height
:
566px
;
height
:
566px
;
position
:
relative
;
position
:
relative
;
&-phone
{
&-phone
{
width
:
290px
;
width
:
290px
;
height
:
566px
;
height
:
566px
;
}
}
.content-show
{
.content-show
{
background-color
:
#fff
;
background-color
:
#fff
;
width
:
160px
;
width
:
160px
;
...
@@ -853,14 +1093,17 @@ export default {
...
@@ -853,14 +1093,17 @@ export default {
left
:
71px
;
left
:
71px
;
display
:
flex
;
display
:
flex
;
justify-content
:
space-between
;
justify-content
:
space-between
;
&-img
{
&-img
{
width
:
30px
;
width
:
30px
;
height
:
30px
;
height
:
30px
;
img
{
img
{
width
:
30px
;
width
:
30px
;
height
:
30px
;
height
:
30px
;
}
}
}
}
.content-title
{
.content-title
{
color
:
#333333
;
color
:
#333333
;
max-width
:
100px
;
max-width
:
100px
;
...
@@ -870,6 +1113,7 @@ export default {
...
@@ -870,6 +1113,7 @@ export default {
font-size
:
13px
;
font-size
:
13px
;
margin-bottom
:
4px
;
margin-bottom
:
4px
;
}
}
.content-word
{
.content-word
{
color
:
#999999
;
color
:
#999999
;
line-height
:
14px
;
line-height
:
14px
;
...
@@ -885,49 +1129,64 @@ export default {
...
@@ -885,49 +1129,64 @@ export default {
}
}
}
}
}
}
.img-plus
{
.img-plus
{
width
:
200px
;
width
:
200px
;
height
:
200px
;
height
:
200px
;
}
}
.gl-footer
{
.gl-footer
{
z-index
:
999
;
z-index
:
999
;
}
}
.form-item-container
{
.form-item-container
{
margin-top
:
32px
!important
;
margin-top
:
32px
!important
;
}
}
.el-form-item
{
.el-form-item
{
display
:
flex
;
margin-bottom
:
20px
!important
;
margin-bottom
:
20px
!important
;
}
}
/
deep
/
.el-form-item__label
{
/
deep
/
.el-form-item__label
{
line-height
:
25px
;
line-height
:
25px
;
}
}
/
deep
/
.el-form-item__content
{
/
deep
/
.el-form-item__content
{
line-height
:
25px
;
line-height
:
25px
;
}
}
.label-word
{
.label-word
{
display
:
inline-block
;
display
:
inline-block
;
img
{
img
{
vertical-align
:
middle
;
vertical-align
:
middle
;
}
}
}
}
ul
{
ul
{
margin-top
:
5px
;
margin-top
:
5px
;
.pdf-show
{
.pdf-show
{
//
width
:
200px
;
//
width
:
200px
;
list-style
:
none
;
list-style
:
none
;
align-items
:
center
;
align-items
:
center
;
position
:
relative
;
position
:
relative
;
padding
:
0
8px
;
padding
:
0
8px
;
.pdf-name
{
.pdf-name
{
margin-right
:
20px
;
margin-right
:
20px
;
&:hover
{
&:hover
{
color
:
#5850ff
;
color
:
#5850ff
;
}
}
}
}
&
:hover
{
&
:hover
{
cursor
:
pointer
;
cursor
:
pointer
;
background-color
:
rgba
(
88
,
80
,
255
,
0.2
)
!important
;
background-color
:
rgba
(
88
,
80
,
255
,
0.2
)
!important
;
}
}
i
{
i
{
position
:
absolute
;
position
:
absolute
;
right
:
5px
;
right
:
5px
;
...
@@ -935,4 +1194,36 @@ ul {
...
@@ -935,4 +1194,36 @@ ul {
}
}
}
}
}
}
.video-dsialog
{
z-index
:
2001
;
position
:
fixed
;
top
:
0
;
right
:
0
;
bottom
:
0
;
left
:
0
;
overflow
:
auto
;
background
:
rgba
(
$
color
:
#000000
,
$
alpha
:
0.5
);
&-panel
{
background
:
#000000
;
position
:
absolute
;
top
:
100px
;
left
:
50%
;
transform
:
translateX
(
-50%
);
height
:
calc
(
100%
-
200px
);
width
:
auto
;
box-sizing
:
border-box
;
padding
:
10px
20px
20px
;
overflow
:
hidden
;
.video-close
{
display
:
flex
;
justify-content
:
flex-end
;
height
:
40px
;
i
{
cursor
:
pointer
;
font-size
:
25px
;
color
:
#5850ff
;
}
}
}
}
</
style
>
</
style
>
src/views/material/components/textBox.vue
View file @
d959e23
...
@@ -18,7 +18,7 @@ export default {
...
@@ -18,7 +18,7 @@ export default {
props
:
{
props
:
{
excludeMenus
:
{
excludeMenus
:
{
type
:
Array
,
type
:
Array
,
default
:
()
=>
[
'code'
]
default
:
()
=>
[
'code'
,
'video'
]
},
},
boxHeight
:{
boxHeight
:{
type
:
Number
,
type
:
Number
,
...
...
src/views/material/index.vue
View file @
d959e23
...
@@ -232,18 +232,18 @@ export default {
...
@@ -232,18 +232,18 @@ export default {
],
],
// 表格按钮
// 表格按钮
tableButtonList
:
[
tableButtonList
:
[
{
//
{
// type: 'GLButton',
//
// type: 'GLButton',
type
:
'el-button'
,
//
type: 'el-button',
name
:
'详情'
,
//
name: '详情',
attrs
:
{
//
attrs: {
type
:
'text'
,
//
type: 'text',
fn
:
'详情'
//
fn: '详情'
},
//
},
listeners
:
{
//
listeners: {
click
:
this
.
handleDetail
//
click: this.handleDetail
}
//
}
},
//
},
{
{
// type: 'GLButton',
// type: 'GLButton',
type
:
'el-button'
,
type
:
'el-button'
,
...
@@ -297,114 +297,114 @@ export default {
...
@@ -297,114 +297,114 @@ export default {
label
:
'状态'
,
label
:
'状态'
,
prop
:
'status'
,
prop
:
'status'
,
addHtml
:
'status'
,
addHtml
:
'status'
,
width
:
1
2
0
width
:
1
7
0
},
},
{
{
label
:
'类型'
,
label
:
'类型'
,
prop
:
'materialType'
,
prop
:
'materialType'
,
addHtml
:
'materialType'
,
addHtml
:
'materialType'
,
width
:
100
width
:
170
},
{
label
:
'发送次数'
,
prop
:
'sendNum'
,
sortable
:
true
,
width
:
130
,
formatter
:
cellVal
=>
{
return
cellVal
.
sendNum
},
renderHeader
:
(
h
,
{
column
,
$index
})
=>
{
return
h
(
'div'
,
{
style
:
{
display
:
'inline-flex'
,
'align-items'
:
'center'
,
padding
:
0
}
},
[
'发送次数'
,
h
(
'el-popover'
,
{
attrs
:
{
placement
:
'top-start'
,
width
:
'240'
,
trigger
:
'hover'
,
content
:
'统计该素材的发送次数(不包含在系统外部的转发次数)'
}
},
[
h
(
'img'
,
{
style
:
{
width
:
'17px'
,
height
:
'17px'
,
'vertical-align'
:
'middle'
},
attrs
:
{
src
:
iconUrl
},
slot
:
'reference'
})
]
)
]
)
}
},
{
label
:
'阅读人数'
,
prop
:
'readNum'
,
width
:
130
,
sortable
:
true
,
formatter
:
cellVal
=>
{
return
cellVal
.
readNum
},
renderHeader
:
(
h
,
{
column
,
$index
})
=>
{
return
h
(
'div'
,
{
style
:
{
display
:
'inline-flex'
,
'align-items'
:
'center'
,
padding
:
0
}
},
[
'阅读人数'
,
h
(
'el-popover'
,
{
attrs
:
{
placement
:
'top-start'
,
width
:
'240'
,
trigger
:
'hover'
,
content
:
'阅读该素材的人数,内部员工除外。'
}
},
[
h
(
'img'
,
{
style
:
{
width
:
'17px'
,
height
:
'17px'
,
'vertical-align'
:
'middle'
},
attrs
:
{
src
:
iconUrl
},
slot
:
'reference'
})
]
)
]
)
}
},
},
// {
// label: '发送次数',
// prop: 'sendNum',
// sortable: true,
// width: 130,
// formatter: cellVal => {
// return cellVal.sendNum
// },
// renderHeader: (h, { column, $index }) => {
// return h(
// 'div',
// {
// style: {
// display: 'inline-flex',
// 'align-items': 'center',
// padding: 0
// }
// },
// [
// '发送次数',
// h(
// 'el-popover',
// {
// attrs: {
// placement: 'top-start',
// width: '240',
// trigger: 'hover',
// content: '统计该素材的发送次数(不包含在系统外部的转发次数)'
// }
// },
// [
// h('img', {
// style: {
// width: '17px',
// height: '17px',
// 'vertical-align': 'middle'
// },
// attrs: {
// src: iconUrl
// },
// slot: 'reference'
// })
// ]
// )
// ]
// )
// }
// },
// {
// label: '阅读人数',
// prop: 'readNum',
// width: 130,
// sortable: true,
// formatter: cellVal => {
// return cellVal.readNum
// },
// renderHeader: (h, { column, $index }) => {
// return h(
// 'div',
// {
// style: {
// display: 'inline-flex',
// 'align-items': 'center',
// padding: 0
// }
// },
// [
// '阅读人数',
// h(
// 'el-popover',
// {
// attrs: {
// placement: 'top-start',
// width: '240',
// trigger: 'hover',
// content: '阅读该素材的人数,内部员工除外。'
// }
// },
// [
// h('img', {
// style: {
// width: '17px',
// height: '17px',
// 'vertical-align': 'middle'
// },
// attrs: {
// src: iconUrl
// },
// slot: 'reference'
// })
// ]
// )
// ]
// )
// }
// },
{
{
label
:
'更新时间'
,
label
:
'更新时间'
,
prop
:
'updatedTime'
,
prop
:
'updatedTime'
,
width
:
15
0
,
width
:
21
0
,
sortable
:
true
,
sortable
:
true
,
formatter
:
cellVal
=>
{
formatter
:
cellVal
=>
{
return
cellVal
.
updatedTime
return
cellVal
.
updatedTime
...
@@ -437,7 +437,6 @@ export default {
...
@@ -437,7 +437,6 @@ export default {
},
},
videoOpen
(
scope
)
{
videoOpen
(
scope
)
{
console
.
log
(
scope
)
this
.
dialogVisibleImg
=
true
this
.
dialogVisibleImg
=
true
let
dialogSrc
=
scope
.
materialContentRpcResponse
.
materialUrl
let
dialogSrc
=
scope
.
materialContentRpcResponse
.
materialUrl
this
.
$refs
.
VideoShowDia
.
init
(
dialogSrc
)
this
.
$refs
.
VideoShowDia
.
init
(
dialogSrc
)
...
@@ -473,7 +472,7 @@ export default {
...
@@ -473,7 +472,7 @@ export default {
// })
// })
// },
// },
getListEntBusinessType
()
{
getListEntBusinessType
()
{
var
params
=
{}
let
params
=
{}
// flag 0-跟进专员调用 1-素材调用
// flag 0-跟进专员调用 1-素材调用
params
.
flag
=
1
params
.
flag
=
1
this
.
$apis
.
material
.
getListEntBusinessType
(
params
).
then
(
res
=>
{
this
.
$apis
.
material
.
getListEntBusinessType
(
params
).
then
(
res
=>
{
...
@@ -504,7 +503,7 @@ export default {
...
@@ -504,7 +503,7 @@ export default {
},
},
// 素材禁用&启用
// 素材禁用&启用
handleForbid
(
scope
)
{
handleForbid
(
scope
)
{
var
params
=
{}
let
params
=
{}
params
.
id
=
scope
.
id
params
.
id
=
scope
.
id
if
(
scope
.
status
==
0
)
{
if
(
scope
.
status
==
0
)
{
params
.
status
=
-
1
params
.
status
=
-
1
...
@@ -520,7 +519,7 @@ export default {
...
@@ -520,7 +519,7 @@ export default {
},
},
// 1-新增素材,2-编辑素材
// 1-新增素材,2-编辑素材
addMaterial
(
addOrEdit
,
scope
)
{
addMaterial
(
addOrEdit
,
scope
)
{
var
params
=
{
let
params
=
{
addOrEdit
:
addOrEdit
,
addOrEdit
:
addOrEdit
,
$title
:
encodeURI
(
addOrEdit
==
1
?
'创建营销素材'
:
'编辑营销素材'
)
$title
:
encodeURI
(
addOrEdit
==
1
?
'创建营销素材'
:
'编辑营销素材'
)
}
}
...
@@ -532,7 +531,7 @@ export default {
...
@@ -532,7 +531,7 @@ export default {
})
})
},
},
getParams
()
{
getParams
()
{
var
params
=
JSON
.
parse
(
JSON
.
stringify
(
this
.
searchForm
))
let
params
=
JSON
.
parse
(
JSON
.
stringify
(
this
.
searchForm
))
return
params
return
params
},
},
// 获取素材列表
// 获取素材列表
...
@@ -568,7 +567,7 @@ export default {
...
@@ -568,7 +567,7 @@ export default {
},
},
// 获取所有素材
// 获取所有素材
getListApi
()
{
getListApi
()
{
var
params
=
this
.
getParams
()
let
params
=
this
.
getParams
()
// params.pageSize = this.$refs.materialRef.page.pageSize
// params.pageSize = this.$refs.materialRef.page.pageSize
// params.pageNum = this.$refs.materialRef.page.pageNum
// params.pageNum = this.$refs.materialRef.page.pageNum
params
.
pageSize
=
1000000
params
.
pageSize
=
1000000
...
...
Write
Preview
Markdown
is supported
Attach a file
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to post a comment