Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
saas
/
scrm-micro-link
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 a637768c
authored
Jul 20, 2023
by
杨明
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
fixed
1 parent
cbaf032f
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
91 additions
and
45 deletions
src/mixins/draw.js
src/setup/qiankun.js
src/store/modules/marketing.js
src/views/activityLink/components/GPTAnalysis.vue
src/views/activityLink/components/MarketingContent.vue
src/views/activityLink/components/MarketingTask.vue
src/views/activityLink/components/PhoneView.vue
src/views/activityLink/components/Process.vue
src/mixins/draw.js
View file @
a637768
...
@@ -2,7 +2,7 @@
...
@@ -2,7 +2,7 @@
* @Author: yangming yangming@didihu.com.cn
* @Author: yangming yangming@didihu.com.cn
* @Date: 2023-05-19 13:46:20
* @Date: 2023-05-19 13:46:20
* @LastEditors: yangming yangming@didihu.com.cn
* @LastEditors: yangming yangming@didihu.com.cn
* @LastEditTime: 2023-07-
14 21:38:37
* @LastEditTime: 2023-07-
20 10:46:23
* @FilePath: \scrm-micro-home\src\mixins\gpt.js
* @FilePath: \scrm-micro-home\src\mixins\gpt.js
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
*/
*/
...
@@ -32,12 +32,12 @@ export default {
...
@@ -32,12 +32,12 @@ export default {
async
createBig
(
info
,
logoInfo
,
titleStyle
,
subTitleStyle
)
{
async
createBig
(
info
,
logoInfo
,
titleStyle
,
subTitleStyle
)
{
console
.
log
(
info
)
console
.
log
(
info
)
this
.
loading
=
true
this
.
loading
=
true
const
{
backgroundImage
,
detailImage
,
merchantLog
,
marketingTitle
,
marketingSubtitle
}
=
info
const
{
backgroundImage
,
detailImage
,
merchantLog
o
,
marketingTitle
,
marketingSubtitle
}
=
info
if
(
!
backgroundImage
)
return
if
(
!
backgroundImage
)
return
try
{
try
{
const
res
=
await
Promise
.
all
([
this
.
getImgInfo
(
backgroundImage
),
this
.
getImgInfo
(
detailImage
),
this
.
getImgInfo
(
merchantLog
)])
const
res
=
await
Promise
.
all
([
this
.
getImgInfo
(
backgroundImage
),
this
.
getImgInfo
(
detailImage
),
this
.
getImgInfo
(
merchantLog
o
)])
const
h
=
(
res
[
0
].
dh
/
res
[
0
].
dw
)
*
WIDTH
+
(
res
[
1
].
dh
/
res
[
1
].
dw
)
*
WIDTH
const
h
=
(
res
[
0
].
dh
/
res
[
0
].
dw
)
*
WIDTH
+
(
res
[
1
].
dh
/
res
[
1
].
dw
)
*
WIDTH
this
.
logoInfo
=
{
url
:
merchantLog
,
...
logoInfo
}
this
.
logoInfo
=
{
url
:
merchantLog
o
,
...
logoInfo
}
const
drawfun
=
new
Drawing
(
document
.
getElementById
(
'canvasId'
),
{
const
drawfun
=
new
Drawing
(
document
.
getElementById
(
'canvasId'
),
{
width
:
WIDTH
,
width
:
WIDTH
,
height
:
h
height
:
h
...
@@ -104,22 +104,34 @@ export default {
...
@@ -104,22 +104,34 @@ export default {
console
.
log
(
e
)
console
.
log
(
e
)
}
}
},
},
async
createMain
(
h
,
url
,
draggableList
)
{
async
createMain
(
info
,
draggableList
)
{
const
style1
=
draggableList
[
0
]
const
style1
=
draggableList
[
0
]
const
style2
=
draggableList
[
1
]
const
style2
=
draggableList
[
1
]
const
drawfun
=
new
Drawing
(
document
.
getElementById
(
'canvasId'
),
{
const
drawfun
=
new
Drawing
(
document
.
getElementById
(
'canvasId'
),
{
width
:
WIDTH
,
width
:
WIDTH
,
height
:
h
height
:
info
.
backgroundHeight
+
info
.
detailHeight
})
})
const
imageList
=
[
const
imageList
=
[
{
{
url
,
url
:
info
.
backgroundImage
,
x
:
0
,
x
:
0
,
y
:
0
,
y
:
0
,
width
:
WIDTH
,
width
:
WIDTH
,
height
:
h
height
:
info
.
backgroundHeight
}
}
]
]
if
(
info
.
detailImage
)
{
imageList
.
push
({
url
:
info
.
detailImage
,
x
:
0
,
y
:
info
.
backgroundHeight
,
width
:
WIDTH
,
height
:
info
.
detailHeight
})
}
if
(
info
.
merchantLogo
)
{
imageList
.
push
({
...
info
.
logoInfo
,
url
:
info
.
merchantLogo
})
}
const
textList
=
[
const
textList
=
[
{
x
:
style1
.
x
,
y
:
style1
.
y
,
fontSize
:
style1
.
size
,
width
:
style1
.
width
,
text
:
style1
.
content
,
color
:
style1
.
color
,
font
:
style1
.
font
},
{
x
:
style1
.
x
,
y
:
style1
.
y
,
fontSize
:
style1
.
size
,
width
:
style1
.
width
,
text
:
style1
.
content
,
color
:
style1
.
color
,
font
:
style1
.
font
},
{
x
:
style2
.
x
,
y
:
style2
.
y
,
fontSize
:
style2
.
size
,
width
:
style2
.
width
,
text
:
style2
.
content
,
color
:
style2
.
color
,
font
:
style2
.
font
}
{
x
:
style2
.
x
,
y
:
style2
.
y
,
fontSize
:
style2
.
size
,
width
:
style2
.
width
,
text
:
style2
.
content
,
color
:
style2
.
color
,
font
:
style2
.
font
}
...
...
src/setup/qiankun.js
View file @
a637768
...
@@ -2,7 +2,7 @@
...
@@ -2,7 +2,7 @@
* @Author: 前端 qianduan01@didihu.com.cn
* @Author: 前端 qianduan01@didihu.com.cn
* @Date: 2022-12-13 09:23:57
* @Date: 2022-12-13 09:23:57
* @LastEditors: yangming yangming@didihu.com.cn
* @LastEditors: yangming yangming@didihu.com.cn
* @LastEditTime: 2023-07-1
3 20:56:0
7
* @LastEditTime: 2023-07-1
9 17:32:1
7
* @FilePath: \scrm-micro-link\src\setup\qiankun.js
* @FilePath: \scrm-micro-link\src\setup\qiankun.js
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
*/
*/
...
@@ -20,13 +20,14 @@ let instance = null
...
@@ -20,13 +20,14 @@ 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
,
request_gpt
,
request_merchant
}
=
await
fetchConfig
(
common
)
const
{
response
,
request
,
sign
,
secret
,
sign_common
,
request_common
,
request_gpt
,
request_merchant
,
messageModel
}
=
await
fetchConfig
(
common
)
Vue
.
prototype
.
$history
=
history
Vue
.
prototype
.
$history
=
history
Vue
.
prototype
.
$messenger
=
messenger
Vue
.
prototype
.
$messenger
=
messenger
Vue
.
prototype
.
$globalState
=
globalState
Vue
.
prototype
.
$globalState
=
globalState
Vue
.
prototype
.
$common
=
common
Vue
.
prototype
.
$common
=
common
Vue
.
prototype
.
$message
=
message
Vue
.
prototype
.
$message
=
message
Vue
.
prototype
.
$messageBox
=
messageBox
Vue
.
prototype
.
$messageBox
=
messageBox
Vue
.
prototype
.
$messageModel
=
messageModel
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
.
$http_merchant
=
new
common
.
Http
({
response
,
request
:
request_merchant
,
sign
,
secret
,
alert
:
ElementUI
.
Message
.
error
,
headers
:
{
token
:
globalState
.
session
.
token
}
})
Vue
.
prototype
.
$http_merchant
=
new
common
.
Http
({
response
,
request
:
request_merchant
,
sign
,
secret
,
alert
:
ElementUI
.
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
}
})
...
...
src/store/modules/marketing.js
View file @
a637768
...
@@ -2,7 +2,7 @@
...
@@ -2,7 +2,7 @@
* @Author: yangming yangming@didihu.com.cn
* @Author: yangming yangming@didihu.com.cn
* @Date: 2023-05-16 17:13:33
* @Date: 2023-05-16 17:13:33
* @LastEditors: yangming yangming@didihu.com.cn
* @LastEditors: yangming yangming@didihu.com.cn
* @LastEditTime: 2023-07-
18 15:17:25
* @LastEditTime: 2023-07-
20 10:07:34
* @FilePath: \scrm-micro-home\src\store\modules\marketing.js
* @FilePath: \scrm-micro-home\src\store\modules\marketing.js
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
*/
*/
...
@@ -46,10 +46,6 @@ export default {
...
@@ -46,10 +46,6 @@ export default {
},
},
// 设置活动信息
// 设置活动信息
SET_ACTIVITY_INFO
(
state
,
data
)
{
SET_ACTIVITY_INFO
(
state
,
data
)
{
if
(
data
.
activityBigImg
)
{
data
.
backgroundImage
=
data
.
activityBigImg
data
.
merchantAddress
=
data
.
activityAddressDetailName
}
state
.
activityInfo
=
Object
.
assign
({},
data
)
state
.
activityInfo
=
Object
.
assign
({},
data
)
},
},
SET_KET_WORDs
(
state
,
data
)
{
SET_KET_WORDs
(
state
,
data
)
{
...
...
src/views/activityLink/components/GPTAnalysis.vue
deleted
100644 → 0
View file @
cbaf032
This diff is collapsed.
Click to expand it.
src/views/activityLink/components/MarketingContent.vue
View file @
a637768
...
@@ -2,7 +2,7 @@
...
@@ -2,7 +2,7 @@
* @Author: yangming yangming@didihu.com.cn
* @Author: yangming yangming@didihu.com.cn
* @Date: 2023-06-29 21:24:27
* @Date: 2023-06-29 21:24:27
* @LastEditors: yangming yangming@didihu.com.cn
* @LastEditors: yangming yangming@didihu.com.cn
* @LastEditTime: 2023-07-
18 23:51:09
* @LastEditTime: 2023-07-
20 13:35:26
* @FilePath: \scrm-micro-link\src\views\activityLink\components\MarketingContent.vue
* @FilePath: \scrm-micro-link\src\views\activityLink\components\MarketingContent.vue
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
-->
-->
...
@@ -13,7 +13,7 @@
...
@@ -13,7 +13,7 @@
<el-button
:size=
"size"
icon=
"el-icon-plus"
@
click=
"modelVisible = true"
>
选择模板
</el-button>
<el-button
:size=
"size"
icon=
"el-icon-plus"
@
click=
"modelVisible = true"
>
选择模板
</el-button>
</div>
</div>
<div
slot=
"marketingTitle"
class=
"input-slot"
>
<div
slot=
"marketingTitle"
class=
"input-slot"
>
<el-input
placeholder=
"请输入营销主题"
v-model=
"editForm.marketingTitle"
style=
"width:400px"
maxlength=
"1
2
"
show-word-limit
></el-input>
<el-input
placeholder=
"请输入营销主题"
v-model=
"editForm.marketingTitle"
style=
"width:400px"
maxlength=
"1
0
"
show-word-limit
></el-input>
<label
@
click=
"getGPTitle(1)"
v-if=
"GPTList"
>
ChatGPT重新生成
</label>
<label
@
click=
"getGPTitle(1)"
v-if=
"GPTList"
>
ChatGPT重新生成
</label>
<label
v-else
class=
"disabled-label"
>
ChatGPT重新生成
</label>
<label
v-else
class=
"disabled-label"
>
ChatGPT重新生成
</label>
</div>
</div>
...
@@ -58,7 +58,7 @@ export default {
...
@@ -58,7 +58,7 @@ export default {
activityTime
:
[],
activityTime
:
[],
backgroundImage
:
''
,
backgroundImage
:
''
,
detailImage
:
''
,
detailImage
:
''
,
merchantLog
:
''
merchantLog
o
:
''
},
},
editFormData
:
[
editFormData
:
[
{
{
...
@@ -71,7 +71,7 @@ export default {
...
@@ -71,7 +71,7 @@ export default {
name
:
'marketingTitle'
,
name
:
'marketingTitle'
,
addHtml
:
'marketingTitle'
,
addHtml
:
'marketingTitle'
,
type
:
'input'
,
type
:
'input'
,
maxlength
:
1
2
maxlength
:
1
0
},
},
{
{
label
:
'营销副标题'
,
label
:
'营销副标题'
,
...
@@ -165,14 +165,14 @@ export default {
...
@@ -165,14 +165,14 @@ export default {
},
},
{
{
label
:
'门店Logo'
,
label
:
'门店Logo'
,
name
:
'merchantLog'
,
name
:
'merchantLog
o
'
,
type
:
'upload'
,
type
:
'upload'
,
width
:
'320px'
,
width
:
'320px'
,
mark
:
'建议尺寸:最大1M,尺寸216*60'
,
mark
:
'建议尺寸:最大1M,尺寸216*60'
,
style
:
'color: #999999;'
,
style
:
'color: #999999;'
,
limitSize
:
5
,
limitSize
:
5
,
maxPhotoNum
:
1
,
maxPhotoNum
:
1
,
suffixSlot
:
'merchantLog'
,
suffixSlot
:
'merchantLog
o
'
,
handleUpload
:
(
e
,
file
,
targetItem
)
=>
{
handleUpload
:
(
e
,
file
,
targetItem
)
=>
{
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
]
...
@@ -278,7 +278,7 @@ export default {
...
@@ -278,7 +278,7 @@ export default {
activityTime
:
[],
activityTime
:
[],
backgroundImage
:
''
,
backgroundImage
:
''
,
detailImage
:
''
,
detailImage
:
''
,
merchantLog
:
''
,
merchantLog
o
:
''
,
merchantname
:
this
.
merchantInfo
.
merchantName
,
merchantname
:
this
.
merchantInfo
.
merchantName
,
merchantAddress
:
this
.
merchantInfo
.
merchantAddress
merchantAddress
:
this
.
merchantInfo
.
merchantAddress
}
}
...
@@ -300,13 +300,16 @@ export default {
...
@@ -300,13 +300,16 @@ export default {
return
return
}
}
console
.
log
(
888
)
console
.
log
(
888
)
this
.
editForm
=
Object
.
assign
({
merchantLog
:
''
},
info
)
this
.
editForm
=
Object
.
assign
({
merchantLog
o
:
''
},
info
)
if
(
info
.
activityName
)
{
if
(
info
.
activityName
)
{
this
.
$set
(
this
.
editForm
,
'marketingTitle'
,
info
.
activityName
)
this
.
$set
(
this
.
editForm
,
'marketingTitle'
,
info
.
activityName
)
}
}
if
(
info
.
subTitle
)
{
if
(
info
.
subTitle
)
{
this
.
$set
(
this
.
editForm
,
'marketingSubtitle'
,
info
.
subTitle
)
this
.
$set
(
this
.
editForm
,
'marketingSubtitle'
,
info
.
subTitle
)
}
}
this
.
editForm
.
backgroundImage
=
info
.
mainImage
||
info
.
activityBigImg
this
.
editForm
.
merchantAddress
=
info
.
activityAddressDetailName
if
(
info
.
starttime
)
{
if
(
info
.
starttime
)
{
this
.
$set
(
this
.
editForm
,
'activityTime'
,
[
info
.
starttime
.
replace
(
/-/g
,
'/'
),
info
.
endtime
.
replace
(
/-/g
,
'/'
)])
this
.
$set
(
this
.
editForm
,
'activityTime'
,
[
info
.
starttime
.
replace
(
/-/g
,
'/'
),
info
.
endtime
.
replace
(
/-/g
,
'/'
)])
}
}
...
@@ -326,7 +329,7 @@ export default {
...
@@ -326,7 +329,7 @@ export default {
...
info
,
...
info
,
merchantname
:
this
.
merchantInfo
.
merchantName
,
merchantname
:
this
.
merchantInfo
.
merchantName
,
merchantAddress
:
this
.
merchantInfo
.
merchantAddress
,
merchantAddress
:
this
.
merchantInfo
.
merchantAddress
,
merchantLog
:
''
,
merchantLog
o
:
''
,
mainColor
:
''
mainColor
:
''
}
}
console
.
log
(
this
.
editForm
,
9
)
console
.
log
(
this
.
editForm
,
9
)
...
@@ -343,6 +346,7 @@ export default {
...
@@ -343,6 +346,7 @@ export default {
param
.
starttime
=
d
[
0
]
param
.
starttime
=
d
[
0
]
param
.
endtime
=
d
[
1
]
param
.
endtime
=
d
[
1
]
}
}
param
.
mainImage
=
param
.
backgroundImage
delete
param
.
createdTime
delete
param
.
createdTime
delete
param
.
activityPrice
delete
param
.
activityPrice
delete
param
.
giftId
delete
param
.
giftId
...
...
src/views/activityLink/components/MarketingTask.vue
View file @
a637768
...
@@ -117,7 +117,7 @@
...
@@ -117,7 +117,7 @@
</el-select>
</el-select>
</el-form-item>
</el-form-item>
<el-form-item
label=
"营销短信:"
:size=
"size"
>
<el-form-item
label=
"营销短信:"
:size=
"size"
>
<el-input
v-model=
"configForm.messageContent"
type=
"textarea"
:disabled=
"true"
></el-input>
<el-input
v-model=
"configForm.messageContent"
type=
"textarea"
:disabled=
"true"
rows=
"3"
></el-input>
</el-form-item>
</el-form-item>
</el-form>
</el-form>
</div>
</div>
...
@@ -126,10 +126,6 @@
...
@@ -126,10 +126,6 @@
</template>
</template>
<
script
>
<
script
>
const
config
=
Object
.
freeze
({
talkId
:
''
,
messageContent
:
'【广汇汽车】诚邀您参与{0},请尽快点击链接参与,谨防错过哦! {1} 谨防错过退订回T。'
})
const
taskData
=
{
tableData
:
[],
expand
:
true
,
assignType
:
0
,
customerNumTotal
:
0
,
lastFollowStaffList
:
[],
staffList
:
[],
excelUrl
:
''
,
isFinish
:
false
}
const
taskData
=
{
tableData
:
[],
expand
:
true
,
assignType
:
0
,
customerNumTotal
:
0
,
lastFollowStaffList
:
[],
staffList
:
[],
excelUrl
:
''
,
isFinish
:
false
}
import
{
mapActions
,
mapState
,
mapMutations
}
from
'vuex'
import
{
mapActions
,
mapState
,
mapMutations
}
from
'vuex'
export
default
{
export
default
{
...
@@ -146,7 +142,14 @@ export default {
...
@@ -146,7 +142,14 @@ export default {
},
},
isQrcodeVisible
:
false
,
isQrcodeVisible
:
false
,
configVisible
:
false
,
configVisible
:
false
,
configForm
:
config
,
config
:
{
talkId
:
''
,
messageContent
:
this
.
$messageModel
},
configForm
:
{
talkId
:
''
,
messageContent
:
this
.
$messageModel
},
tableData
:
[],
tableData
:
[],
roobList
:
[]
roobList
:
[]
}
}
...
@@ -295,8 +298,8 @@ export default {
...
@@ -295,8 +298,8 @@ export default {
this
.
roobList
=
res
.
list
||
[]
this
.
roobList
=
res
.
list
||
[]
this
.
$nextTick
(()
=>
{
this
.
$nextTick
(()
=>
{
this
.
configForm
=
{
this
.
configForm
=
{
talkId
:
row
.
row
.
talkId
?
row
.
row
.
talkId
:
config
.
talkId
,
talkId
:
row
.
row
.
talkId
?
row
.
row
.
talkId
:
this
.
config
.
talkId
,
messageContent
:
row
.
row
.
messageContent
?
row
.
row
.
messageContent
:
config
.
messageContent
messageContent
:
row
.
row
.
messageContent
?
row
.
row
.
messageContent
:
this
.
config
.
messageContent
}
}
})
})
})
})
...
@@ -356,7 +359,7 @@ export default {
...
@@ -356,7 +359,7 @@ export default {
merchantId
:
i
.
merchantNo
,
merchantId
:
i
.
merchantNo
,
staffPhone
:
i
.
staffPhone
,
staffPhone
:
i
.
staffPhone
,
staffName
:
i
.
staffName
,
staffName
:
i
.
staffName
,
messageContent
:
i
.
messageContent
?
i
.
messageContent
.
replace
(
/
广汇汽车/
,
this
.
$globalState
.
session
.
merchantName
)
:
''
,
messageContent
:
i
.
messageContent
?
i
.
messageContent
.
replace
(
/
^【
\S
+
?
】/
,
`【
${
this
.
$globalState
.
session
.
merchantName
}
】`
)
:
''
,
registerStatus
:
i
.
registerStatus
,
registerStatus
:
i
.
registerStatus
,
talkId
:
i
.
talkId
,
talkId
:
i
.
talkId
,
createdBy
:
i
.
createdBy
createdBy
:
i
.
createdBy
...
...
src/views/activityLink/components/PhoneView.vue
View file @
a637768
...
@@ -2,7 +2,7 @@
...
@@ -2,7 +2,7 @@
* @Author: 前端 qianduan01@didihu.com.cn
* @Author: 前端 qianduan01@didihu.com.cn
* @Date: 2023-05-15 15:08:32
* @Date: 2023-05-15 15:08:32
* @LastEditors: yangming yangming@didihu.com.cn
* @LastEditors: yangming yangming@didihu.com.cn
* @LastEditTime: 2023-07-
17 17:47:36
* @LastEditTime: 2023-07-
20 11:46:14
* @FilePath: \scrm-micro-home\src\views\home\components\Marketing\MarketingRight.vue
* @FilePath: \scrm-micro-home\src\views\home\components\Marketing\MarketingRight.vue
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
-->
-->
...
@@ -13,7 +13,8 @@
...
@@ -13,7 +13,8 @@
<img
src=
"@/assets/seckillActivity/phone.png"
class=
"review-phone"
/>
<img
src=
"@/assets/seckillActivity/phone.png"
class=
"review-phone"
/>
<div
class=
"review-title_top"
>
{{
detail
.
marketingTitle
||
detail
.
activityName
}}
</div>
<div
class=
"review-title_top"
>
{{
detail
.
marketingTitle
||
detail
.
activityName
}}
</div>
<div
class=
"review-content"
>
<div
class=
"review-content"
>
<div
class=
"review-main"
v-if=
"backgroundHeight"
:style=
"
{ height: backgroundHeight + 'px' }">
<template
v-if=
"backgroundHeight"
>
<div
class=
"review-main"
:style=
"
{ height: backgroundHeight + 'px' }">
<template
v-for=
"item in draggableList"
>
<template
v-for=
"item in draggableList"
>
<vue-draggable-resizable
<vue-draggable-resizable
:customId=
"item.customId"
:customId=
"item.customId"
...
@@ -38,9 +39,16 @@
...
@@ -38,9 +39,16 @@
</vue-draggable-resizable>
</vue-draggable-resizable>
</
template
>
</
template
>
<div
class=
"review-bg-img"
>
<div
class=
"review-bg-img"
>
<img
:src=
"detail.backgroundImage"
v-if=
"detail.backgroundImage"
/>
<img
:src=
"detail.backgroundImage || detail.mainImage"
v-if=
"detail.backgroundImage || detail.mainImage"
/>
</div>
<div
class=
"review-logo-img"
:style=
"{ height: logoInfo.height + 'px', width: logoInfo.width + 'px', top: logoInfo.y + 'px', left: logoInfo.x + 'px' }"
>
<img
:src=
"detail.merchantLogo"
v-if=
"detail.merchantLogo"
/>
</div>
</div>
</div>
</div>
<div
class=
"review-main-img"
>
<img
:src=
"detail.detailImage"
v-if=
"detail.detailImage"
/>
</div>
</template>
<div
class=
"review-main"
v-else
>
<div
class=
"review-main"
v-else
>
<div
class=
"review-bg-img"
>
<div
class=
"review-bg-img"
>
<img
:src=
"detail.activityBigImg"
v-if=
"detail.activityBigImg"
/>
<img
:src=
"detail.activityBigImg"
v-if=
"detail.activityBigImg"
/>
...
@@ -128,7 +136,7 @@
...
@@ -128,7 +136,7 @@
<img
:src=
"detail.detailImage"
v-if=
"detail.detailImage"
/>
<img
:src=
"detail.detailImage"
v-if=
"detail.detailImage"
/>
</div>
</div>
<div
class=
"review-logo-img"
:style=
"
{ height: logoInfo.height + 'px', width: logoInfo.width + 'px', top: logoInfo.y + 'px', left: logoInfo.x + 'px' }">
<div
class=
"review-logo-img"
:style=
"
{ height: logoInfo.height + 'px', width: logoInfo.width + 'px', top: logoInfo.y + 'px', left: logoInfo.x + 'px' }">
<img
:src=
"detail.merchantLog
"
v-if=
"detail.merchantLog
"
/>
<img
:src=
"detail.merchantLog
o"
v-if=
"detail.merchantLogo
"
/>
</div>
</div>
</
template
>
</
template
>
</div>
</div>
...
@@ -306,6 +314,7 @@ export default {
...
@@ -306,6 +314,7 @@ export default {
data
()
{
data
()
{
return
{
return
{
backgroundHeight
:
0
,
backgroundHeight
:
0
,
detailHeight
:
0
,
logoHeight
:
0
,
logoHeight
:
0
,
currentIndex
:
0
,
currentIndex
:
0
,
isFestival
:
false
,
isFestival
:
false
,
...
@@ -404,7 +413,9 @@ export default {
...
@@ -404,7 +413,9 @@ export default {
handler
(
val
)
{
handler
(
val
)
{
const
info
=
this
.
$common
.
utils
.
deepClone
(
val
)
const
info
=
this
.
$common
.
utils
.
deepClone
(
val
)
if
(
this
.
routerInfo
.
addOrEdit
==
'edit'
)
{
if
(
this
.
routerInfo
.
addOrEdit
==
'edit'
)
{
this
.
showActivity
(
info
)
info
.
marketingTitle
=
info
.
activityName
info
.
marketingSubtitle
=
info
.
subTitle
this
.
validActivity
(
info
)
}
}
},
},
deep
:
true
,
deep
:
true
,
...
@@ -412,6 +423,7 @@ export default {
...
@@ -412,6 +423,7 @@ export default {
},
},
process
:
{
process
:
{
handler
(
val
)
{
handler
(
val
)
{
this
.
detailHeight
=
0
const
detail
=
{
...
this
.
detail
,
...
val
[
2
]
}
const
detail
=
{
...
this
.
detail
,
...
val
[
2
]
}
detail
.
activityPrice
=
val
[
1
].
activityPrice
detail
.
activityPrice
=
val
[
1
].
activityPrice
if
(
this
.
routerInfo
.
addOrEdit
==
'edit'
)
{
if
(
this
.
routerInfo
.
addOrEdit
==
'edit'
)
{
...
@@ -449,7 +461,8 @@ export default {
...
@@ -449,7 +461,8 @@ export default {
if
(
RENEWAL
.
includes
(
this
.
detail
.
codeId
))
{
if
(
RENEWAL
.
includes
(
this
.
detail
.
codeId
))
{
this
.
modelNum
=
this
.
detail
.
codeId
this
.
modelNum
=
this
.
detail
.
codeId
this
.
isRenewal
=
true
this
.
isRenewal
=
true
this
.
backgroundHeight
=
await
this
.
getImgH
(
this
.
detail
.
backgroundImage
)
this
.
backgroundHeight
=
await
this
.
getImgH
(
this
.
detail
.
backgroundImage
||
this
.
detail
.
mainImage
)
if
(
this
.
detail
.
detailImage
)
this
.
detailHeight
=
await
this
.
getImgH
(
this
.
detail
.
detailImage
)
const
style1
=
JSON
.
parse
(
this
.
detail
.
titleStyle
)
const
style1
=
JSON
.
parse
(
this
.
detail
.
titleStyle
)
const
style2
=
JSON
.
parse
(
this
.
detail
.
subTitleStyle
)
const
style2
=
JSON
.
parse
(
this
.
detail
.
subTitleStyle
)
const
styles
=
[
style1
,
style2
]
const
styles
=
[
style1
,
style2
]
...
@@ -459,8 +472,8 @@ export default {
...
@@ -459,8 +472,8 @@ export default {
style
.
size
=
parseInt
(
style
.
size
*
RATIO
)
style
.
size
=
parseInt
(
style
.
size
*
RATIO
)
style
.
width
=
parseInt
(
style
.
width
*
RATIO
)
style
.
width
=
parseInt
(
style
.
width
*
RATIO
)
}
}
Object
.
assign
(
this
.
draggableList
[
0
],
{
content
:
this
.
detail
.
marketingTitle
,
...
style1
,
color
:
style1
.
style
.
color
,
font
:
style1
.
font
})
Object
.
assign
(
this
.
draggableList
[
0
],
{
content
:
this
.
detail
.
marketingTitle
,
...
style1
,
color
:
style1
.
style
.
color
,
font
:
style1
.
font
,
height
:
'auto'
})
Object
.
assign
(
this
.
draggableList
[
1
],
{
content
:
this
.
detail
.
marketingSubtitle
,
...
style2
,
color
:
style2
.
style
.
color
,
font
:
style2
.
font
})
Object
.
assign
(
this
.
draggableList
[
1
],
{
content
:
this
.
detail
.
marketingSubtitle
,
...
style2
,
color
:
style2
.
style
.
color
,
font
:
style2
.
font
,
height
:
'auto'
})
}
}
if
(
FESTIVAL
.
includes
(
this
.
detail
.
codeId
))
{
if
(
FESTIVAL
.
includes
(
this
.
detail
.
codeId
))
{
const
style1
=
JSON
.
parse
(
this
.
detail
.
titleStyle
)
const
style1
=
JSON
.
parse
(
this
.
detail
.
titleStyle
)
...
@@ -497,8 +510,8 @@ export default {
...
@@ -497,8 +510,8 @@ export default {
})
})
})
})
this
.
isFestival
=
true
this
.
isFestival
=
true
this
.
logoInfo
=
await
this
.
getImgWH
(
this
.
detail
.
merchantLog
)
}
}
if
(
this
.
detail
.
merchantLogo
)
this
.
logoInfo
=
await
this
.
getImgWH
(
this
.
detail
.
merchantLogo
)
})
})
},
},
formatPrice
(
val
)
{
formatPrice
(
val
)
{
...
...
src/views/activityLink/components/Process.vue
View file @
a637768
...
@@ -36,6 +36,8 @@
...
@@ -36,6 +36,8 @@
<
script
>
<
script
>
const
RENEWAL
=
[
1
,
2
,
3
,
4
,
5
,
6
,
7
,
8
]
const
RENEWAL
=
[
1
,
2
,
3
,
4
,
5
,
6
,
7
,
8
]
const
FESTIVAL
=
[
9
,
10
]
const
FESTIVAL
=
[
9
,
10
]
const
WIDTH
=
244
const
RATIO
=
375
/
WIDTH
import
{
mapState
,
mapMutations
}
from
'vuex'
import
{
mapState
,
mapMutations
}
from
'vuex'
import
phoneView
from
'./PhoneView'
import
phoneView
from
'./PhoneView'
import
draw
from
'@/mixins/draw'
import
draw
from
'@/mixins/draw'
...
@@ -133,12 +135,27 @@ export default {
...
@@ -133,12 +135,27 @@ export default {
this
.
loading
=
true
this
.
loading
=
true
const
{
const
{
backgroundHeight
,
backgroundHeight
,
detail
:
{
backgroundImage
,
titleStyle
,
subTitleStyle
},
detailHeight
,
logoInfo
,
detail
:
{
backgroundImage
,
detailImage
,
merchantLogo
,
titleStyle
,
subTitleStyle
},
draggableList
draggableList
}
=
this
.
$refs
.
viewForm
}
=
this
.
$refs
.
viewForm
let
url
=
backgroundImage
let
url
=
backgroundImage
if
(
RENEWAL
.
includes
(
params
.
codeId
)
&&
this
.
routerInfo
.
addOrEdit
!=
'edit'
)
{
if
(
RENEWAL
.
includes
(
params
.
codeId
))
{
url
=
await
this
.
createMain
(
backgroundHeight
,
backgroundImage
,
draggableList
)
//合并主图、文字
url
=
await
this
.
createMain
({
backgroundHeight
,
detailHeight
,
logoInfo
,
backgroundImage
,
detailImage
,
merchantLogo
},
draggableList
)
//合并主图、文字
const
style1
=
draggableList
[
0
]
const
style2
=
draggableList
[
1
]
const
titleStyle
=
JSON
.
parse
(
params
.
titleStyle
)
const
subTitleStyle
=
JSON
.
parse
(
params
.
subTitleStyle
)
const
styles
=
[
style1
,
style2
]
for
(
const
style
of
styles
)
{
style
.
x
=
parseInt
(
style
.
x
*
RATIO
)
style
.
y
=
parseInt
(
style
.
y
*
RATIO
)
style
.
size
=
parseInt
(
style
.
size
*
RATIO
)
style
.
width
=
parseInt
(
style
.
width
*
RATIO
)
}
params
.
titleStyle
=
JSON
.
stringify
(
Object
.
assign
(
titleStyle
,
{
x
:
style1
.
x
,
y
:
style1
.
y
,
size
:
style1
.
size
,
width
:
style1
.
width
}))
params
.
subTitleStyle
=
JSON
.
stringify
(
Object
.
assign
(
subTitleStyle
,
{
x
:
style2
.
x
,
y
:
style2
.
y
,
size
:
style2
.
size
,
width
:
style2
.
width
}))
}
}
if
(
FESTIVAL
.
includes
(
params
.
codeId
)
&&
this
.
routerInfo
.
addOrEdit
!=
'edit'
)
{
if
(
FESTIVAL
.
includes
(
params
.
codeId
)
&&
this
.
routerInfo
.
addOrEdit
!=
'edit'
)
{
url
=
await
this
.
createBig
(
this
.
$refs
.
viewForm
.
detail
,
this
.
logoInfo
,
JSON
.
parse
(
titleStyle
),
JSON
.
parse
(
subTitleStyle
))
//合并主图、背景图、logo、文字
url
=
await
this
.
createBig
(
this
.
$refs
.
viewForm
.
detail
,
this
.
logoInfo
,
JSON
.
parse
(
titleStyle
),
JSON
.
parse
(
subTitleStyle
))
//合并主图、背景图、logo、文字
...
...
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