Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
glsx-web
/
glsx-oss-task
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 4c2fb9fc
authored
Oct 26, 2022
by
前端
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
修改bug
1 parent
931751ba
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
11 additions
and
48 deletions
src/components/GLEditor/index.vue
src/views/task/addTask/index.vue
src/views/task/taskList/index.vue
src/components/GLEditor/index.vue
View file @
4c2fb9f
...
...
@@ -263,10 +263,12 @@
ref=
"file"
class=
"welcome-input upload-img"
:accept=
"item.accept || 'image/png, image/jpeg, image/jpg'"
title=
""
@
change=
"(e) => handleImgChange(e)"
/>
<input
v-else-if=
"item.type == 'video'"
title=
""
type=
"file"
style=
"opacity: 0"
:id=
"item.type + 'file'"
...
...
@@ -381,13 +383,6 @@ export default {
}
},
mounted
()
{
// document.addEventListener('click', (e) => {
// console.log(e.target.className)
// if (e.target.className != 'emotion-item') {
// this.emotionStatus = false
// }
// })
console
.
log
(
this
.
previewList
)
if
(
this
.
previewList
.
length
)
{
// this.updateList(this.previewList, 1)
this
.
previewList
.
map
((
item
)
=>
{
...
...
@@ -523,7 +518,6 @@ export default {
}
})
this
.
previewList
=
newList
console
.
log
(
this
.
previewList
)
}
var
reader
=
new
FileReader
()
var
file
=
e
.
srcElement
.
files
[
0
]
...
...
@@ -576,7 +570,6 @@ export default {
// const base64 = file.name.split('.')[1] + '@' + imgFile.split(',')[1]
this
.
imageList
.
uploadApi
({
file
:
fileUrl
}).
then
((
res
)
=>
{
if
(
res
)
{
console
.
log
(
this
.
previewList
)
let
len
=
this
.
previewList
.
length
-
1
this
.
previewList
[
len
].
materialContent
=
res
.
data
.
data
document
.
querySelector
(
'.upload-img'
).
value
=
''
...
...
@@ -590,7 +583,6 @@ export default {
},
// 上传视频
async
handleVideoChange
(
e
)
{
console
.
log
(
111
)
let
videoFlag
=
false
this
.
previewList
.
map
((
item
)
=>
{
if
(
...
...
@@ -601,7 +593,6 @@ export default {
}
return
videoFlag
})
console
.
log
(
videoFlag
,
'videoFlag'
)
let
newList
=
[]
if
(
videoFlag
)
{
this
.
previewList
.
map
((
item
,
index
)
=>
{
...
...
@@ -630,7 +621,6 @@ export default {
// const base64 = file.name.split('.')[1] + '@' + imgFile.split(',')[1]
this
.
videoList
.
uploadApi
({
file
:
fileUrl
}).
then
((
res
)
=>
{
if
(
res
)
{
console
.
log
(
this
.
previewList
)
this
.
previewList
.
push
({
materialType
:
this
.
ATT_TYPE
.
VEDIO
,
materialContent
:
res
.
data
.
data
,
...
...
@@ -638,9 +628,7 @@ export default {
}
})
}
}
catch
(
err
)
{
console
.
log
(
err
)
}
}
catch
(
err
)
{}
},
// 上传链接弹框
handleLinkChange
()
{
...
...
@@ -666,16 +654,12 @@ export default {
})
this
.
previewList
=
newList
}
console
.
log
(
this
.
previewList
,
'this.previewList'
)
this
.
previewList
.
push
({
materialType
:
this
.
ATT_TYPE
.
LINK
,
materialContent
:
value
,
})
console
.
log
(
this
.
previewList
)
})
.
catch
((
err
)
=>
{
console
.
log
(
err
)
})
.
catch
((
err
)
=>
{})
},
uploadFileVideo
(
e
)
{
const
_this
=
this
...
...
@@ -888,7 +872,6 @@ export default {
this
.
previewList
=
utils
.
deepClone
(
val
)
const
obj
=
val
.
find
((
item
)
=>
item
.
materialType
==
this
.
ATT_TYPE
.
TEXT
)
if
(
obj
)
{
console
.
log
(
obj
,
'obj'
)
let
materialContent
if
(
status
)
{
materialContent
=
obj
.
materialContent
.
replace
(
...
...
@@ -929,7 +912,6 @@ export default {
document
.
querySelector
(
'.w-textarea_input'
).
innerHTML
=
htm
},
100
)
}
else
{
console
.
log
(
343434343333
)
this
.
textValue
=
''
}
},
...
...
src/views/task/addTask/index.vue
View file @
4c2fb9f
...
...
@@ -475,7 +475,6 @@ export default {
},
mounted
()
{
this
.
$root
.
eventBus
.
$on
(
'params'
,
(
params
)
=>
{
console
.
log
(
params
,
'000'
)
// 判断是否是编辑
if
(
params
&&
params
.
type
)
{
this
.
isEditor
=
true
...
...
@@ -530,7 +529,6 @@ export default {
params
.
merchantAccountType
=
4
params
.
merchantName
=
query
taskApi
.
findMerchantByScene
(
params
).
then
((
res
)
=>
{
console
.
log
(
res
)
if
(
res
.
code
==
0
)
{
this
.
merchantList
=
res
.
data
}
...
...
@@ -555,13 +553,11 @@ export default {
},
1000
),
// 选择活动
selectActivity
(
selectItem
)
{
console
.
log
(
selectItem
)
this
.
basicForm
.
activityId
=
selectItem
.
id
this
.
basicForm
.
activityName
=
selectItem
.
activityName
this
.
startTime
=
selectItem
.
startTime
this
.
endTime
=
selectItem
.
endTime
this
.
activityImage
=
selectItem
.
activityImg
console
.
log
(
this
.
activityImage
)
this
.
setHouseRatesColumn
(
selectItem
.
startTime
,
selectItem
.
endTime
)
},
// 任务tab切换
...
...
@@ -726,14 +722,12 @@ export default {
this
.
taskList
[
dateTaskIndex
].
missionList
.
splice
(
taskIndex
,
1
)
},
handleBlur
(
dateTask
)
{
console
.
log
(
dateTask
.
repeatCount
)
if
(
dateTask
.
repeatCount
)
{
dateTask
.
repeatFlag
=
false
}
},
// 重复次数选择框改变
repeatChange
(
dateTask
,
type
)
{
console
.
log
(
dateTask
,
type
)
// dateTask.repeatFlag = !dateTask.repeatFlag
// this.$nextTick(() => {
if
(
type
)
{
...
...
@@ -743,25 +737,20 @@ export default {
// dateTask.repeatCount = ''
// dateTask.repeatFlag = false
// })
console
.
log
(
111
)
this
.
$nextTick
(()
=>
{
dateTask
.
repeatCount
=
''
this
.
$set
(
dateTask
,
'repeatFlag'
,
false
)
})
}
console
.
log
(
dateTask
)
// })
// console.log(task, task.repeatCount)
// console.log(task.repeatCount == '-1')
// // dateTask -- 具体哪一天的任务对象
// // dateTaskIndex -- 具体哪一天的任务对象索引
// // task -- 具体哪个任务
// // taskIndex -- 具体任务索引
// if (task.repeatCount) {
// // this.taskList[dateTaskIndex].missionList[taskIndex].repeatCount = ''
// console.log(111)
// this.$set(
// this.taskList[dateTaskIndex].missionList[taskIndex],
// 'repeatCount',
...
...
@@ -775,9 +764,6 @@ export default {
// -1
// )
// }
// console.log(
// this.taskList[dateTaskIndex].missionList[taskIndex].repeatCount
// )
},
// 获取任务信息详情
findMissionDeail
(
taskId
)
{
...
...
@@ -829,7 +815,6 @@ export default {
},
// 奖励模式切换
rewardTypeChange
(
itm
)
{
console
.
log
(
itm
)
if
(
itm
.
rewardType
==
2
)
{
this
.
$nextTick
(()
=>
{
this
.
$set
(
itm
,
'triggerValue'
,
''
)
...
...
@@ -862,9 +847,7 @@ export default {
// 基础信息表单验证
basicFormValidate
()
{
this
.
$refs
[
'basicForm'
].
validate
((
valid
)
=>
{
console
.
log
(
valid
)
if
(
!
valid
)
{
console
.
log
(
111
)
// return all
throw
'必须选定一个值'
}
...
...
@@ -879,7 +862,6 @@ export default {
if
(
!
valid
)
validFlag
=
validFlag
+
1
})
dayIndex
=
index
console
.
log
(
validFlag
,
'000'
)
// 检测到未填写跳转到未填写页面
if
(
validFlag
>
0
)
{
return
false
...
...
@@ -910,7 +892,6 @@ export default {
}
let
validFlag
=
this
.
taskFormValidate
()
console
.
log
(
validFlag
,
'11'
)
if
(
validFlag
[
0
]
>
0
)
{
this
.
$alert
(
'第'
+
(
validFlag
[
1
]
+
1
)
+
'天填写未完成'
,
'警告'
,
{
confirmButtonText
:
'知道了'
,
...
...
@@ -934,11 +915,9 @@ export default {
}
params
.
missionDateList
=
this
.
taskList
params
.
id
=
this
.
taskId
console
.
log
(
params
,
'params'
)
// 创建
if
(
!
this
.
isEditor
)
{
taskApi
.
creatMission
(
params
).
then
((
res
)
=>
{
console
.
log
(
res
)
if
(
res
&&
res
.
code
==
0
)
{
this
.
$root
.
to
([
'任务中心'
,
...
...
src/views/task/taskList/index.vue
View file @
4c2fb9f
...
...
@@ -238,9 +238,6 @@ export default {
status
:
false
,
}
},
mounted
()
{
console
.
log
(
this
.
status
)
},
methods
:
{
// 搜索框搜索
handleSearch
()
{
...
...
@@ -266,10 +263,15 @@ export default {
type
,
}
this
.
$root
.
to
(
[
'任务中心'
,
'任务平台'
,
'任务管理'
,
'任务模板管理'
,
'*添加任务模板'
],
[
'任务中心(自测)'
,
'任务平台'
,
'任务管理'
,
'任务模板管理'
,
'*添加任务模板'
,
],
para
)
// console.log(this.$root)
this
.
$root
.
close
(
'任务管理列表'
)
},
// 删除
...
...
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