Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
I
intel_promotion_manage
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
张伯涛
intel_promotion_manage
Commits
796582f4
Commit
796582f4
authored
Jul 12, 2024
by
张伯涛
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
bug修改
parent
78f673a5
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
55 additions
and
45 deletions
+55
-45
index.vue
src/views/contentManagement/videoInformation/info/index.vue
+55
-45
No files found.
src/views/contentManagement/videoInformation/info/index.vue
View file @
796582f4
...
...
@@ -172,6 +172,7 @@ export default {
},
data
()
{
return
{
uploadSucess
:
false
,
videoShow
:
false
,
isDelFile
:
false
,
fileList
:
[],
...
...
@@ -330,12 +331,14 @@ export default {
})
},
handleUploadVideo
(
file
)
{
this
.
uploadSucess
=
false
const
formData
=
new
FormData
()
formData
.
append
(
'file'
,
file
.
file
)
formData
.
append
(
'temp'
,
'videoInformation'
)
uploadPublic
(
formData
).
then
(
res
=>
{
console
.
log
(
'handleUploadVideo'
,
res
)
this
.
$message
.
success
(
'上传成功'
)
this
.
uploadSucess
=
true
this
.
videoUrl
=
res
.
data
.
businessId
this
.
form
.
videoUrlId
=
res
.
data
.
businessId
this
.
fileList
=
[]
...
...
@@ -496,54 +499,61 @@ export default {
},
// 发布方法
publish
()
{
// 拷贝form
const
form
=
JSON
.
parse
(
JSON
.
stringify
(
this
.
form
))
// 转换时间格式
this
.
pubLoading
=
true
this
.
$refs
.
deviceFormRef
.
validate
(
valid
=>
{
if
(
valid
)
{
if
(
this
.
form
.
businessId
!==
undefined
)
{
// 编辑
form
.
videoType
=
'1'
form
.
unitId
=
this
.
$route
.
query
.
unitId
updateSysContentNewsInformation
(
form
).
then
(
res
=>
{
if
(
res
.
code
===
200
)
{
this
.
$message
({
message
:
'保存成功'
,
type
:
'success'
})
if
(
this
.
uploadSucess
===
true
)
{
// 拷贝form
const
form
=
JSON
.
parse
(
JSON
.
stringify
(
this
.
form
))
console
.
log
(
'11111'
,
this
.
form
.
videoUrlId
)
// 转换时间格式
this
.
pubLoading
=
true
this
.
$refs
.
deviceFormRef
.
validate
(
valid
=>
{
if
(
valid
)
{
if
(
this
.
form
.
businessId
!==
undefined
)
{
// 编辑
form
.
videoType
=
'1'
form
.
unitId
=
this
.
$route
.
query
.
unitId
updateSysContentNewsInformation
(
form
).
then
(
res
=>
{
if
(
res
.
code
===
200
)
{
this
.
$message
({
message
:
'保存成功'
,
type
:
'success'
})
this
.
pubLoading
=
false
this
.
$router
.
push
({
path
:
'/contentManagement/videoInformation/index'
})
}
}).
catch
(()
=>
{
this
.
pubLoading
=
false
this
.
$router
.
push
({
path
:
'/contentManagement/videoInformation/index'
})
}
}).
catch
(()
=>
{
this
.
pubLoading
=
false
})
}
else
{
form
.
videoType
=
'1'
form
.
tenant
=
this
.
userId
form
.
unitId
=
this
.
$route
.
query
.
unitId
addSysContentNewsInformation
(
form
).
then
(
res
=>
{
if
(
res
.
code
===
200
)
{
this
.
$message
({
message
:
'保存成功'
,
type
:
'success'
})
})
}
else
{
form
.
videoType
=
'1'
form
.
tenant
=
this
.
userId
form
.
unitId
=
this
.
$route
.
query
.
unitId
addSysContentNewsInformation
(
form
).
then
(
res
=>
{
if
(
res
.
code
===
200
)
{
this
.
$message
(
{
message
:
'保存成功'
,
type
:
'success'
})
this
.
pubLoading
=
false
this
.
$router
.
push
(
{
path
:
'/contentManagement/videoInformation/index'
})
}
}).
catch
(()
=>
{
this
.
pubLoading
=
false
this
.
$router
.
push
({
path
:
'/contentManagement/videoInformation/index'
})
}
}).
catch
(()
=>
{
this
.
pubLoading
=
false
})
})
}
}
else
{
this
.
pubLoading
=
false
}
}
else
{
this
.
pubLoading
=
false
}
})
})
}
else
{
this
.
$message
({
type
:
'error'
,
message
:
'请等上传完视频再发布'
})
}
}
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
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 comment