Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
E
ElectricitySheep
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
黄媛媛
ElectricitySheep
Commits
4fe69012
Commit
4fe69012
authored
Jun 29, 2020
by
黄奎
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
新增多选
parent
b4603283
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
590 additions
and
565 deletions
+590
-565
materialMan.vue
src/components/CommodityMan/materialMan.vue
+579
-555
ChooseImg.vue
src/components/global/ChooseImg.vue
+10
-9
index.js
src/plug/index.js
+1
-1
No files found.
src/components/CommodityMan/materialMan.vue
View file @
4fe69012
...
@@ -3,7 +3,8 @@
...
@@ -3,7 +3,8 @@
<div
class=
"head-title"
>
<div
class=
"head-title"
>
<span
class=
"point"
@
click=
"SelectRecycled(1)"
:class=
"scgroupMsg.Recycled==2 ? 'blue' :''"
>
素材管理
</span>
<span
class=
"point"
@
click=
"SelectRecycled(1)"
:class=
"scgroupMsg.Recycled==2 ? 'blue' :''"
>
素材管理
</span>
<span
v-if=
"scgroupMsg.Recycled==2"
>
/ 回收站
</span>
<span
v-if=
"scgroupMsg.Recycled==2"
>
/ 回收站
</span>
<el-button
@
click=
"SelectRecycled(2)"
style=
"float:right;margin-top: -5px;"
size=
"small"
type=
"primary"
>
回收站
</el-button>
<el-button
@
click=
"SelectRecycled(2)"
style=
"float:right;margin-top: -5px;"
size=
"small"
type=
"primary"
>
回收站
</el-button>
</div>
</div>
<div
v-loading=
"loading"
style=
"margin-top:10px;background:#fff;padding:20px"
>
<div
v-loading=
"loading"
style=
"margin-top:10px;background:#fff;padding:20px"
>
<div
class=
"TabDiv"
>
<div
class=
"TabDiv"
>
...
@@ -21,11 +22,14 @@
...
@@ -21,11 +22,14 @@
<div
class=
"el-scrollbar"
style=
"width: 100%;height:670px"
>
<div
class=
"el-scrollbar"
style=
"width: 100%;height:670px"
>
<div
class=
"el-scrollbar__wrap"
style=
"margin-bottom: -8px; margin-right: -8px;"
>
<div
class=
"el-scrollbar__wrap"
style=
"margin-bottom: -8px; margin-right: -8px;"
>
<div
class=
"el-scrollbar__view"
>
<div
class=
"el-scrollbar__view"
>
<li
:class=
"PageMsg.GroupId==0?'selectActive' : ''"
@
click=
"SelectGroup(0)"
class=
"el-menu-item"
style=
"padding-left: 10px;padding-right: 10px;"
>
<li
:class=
"PageMsg.GroupId==0?'selectActive' : ''"
@
click=
"SelectGroup(0)"
class=
"el-menu-item"
style=
"padding-left: 10px;padding-right: 10px;"
>
<i
class=
"el-icon-tickets"
></i>
<i
class=
"el-icon-tickets"
></i>
<span>
全部
</span>
<span>
全部
</span>
</li>
</li>
<li
:class=
"PageMsg.GroupId==item.Id?'selectActive' : ''"
@
click=
"SelectGroup(item.Id)"
v-for=
"(item,index) in groupList"
:key=
"index"
class=
"el-menu-item"
style=
"padding-left: 10px;padding-right: 10px;"
>
<li
:class=
"PageMsg.GroupId==item.Id?'selectActive' : ''"
@
click=
"SelectGroup(item.Id)"
v-for=
"(item,index) in groupList"
:key=
"index"
class=
"el-menu-item"
style=
"padding-left: 10px;padding-right: 10px;"
>
<div
flex=
"dir:left box:last"
>
<div
flex=
"dir:left box:last"
>
<el-col
:span=
"18"
style=
"overflow: hidden; text-overflow: ellipsis;"
>
<el-col
:span=
"18"
style=
"overflow: hidden; text-overflow: ellipsis;"
>
<i
class=
"el-icon-tickets"
></i>
<i
class=
"el-icon-tickets"
></i>
...
@@ -52,13 +56,17 @@
...
@@ -52,13 +56,17 @@
<span>
全部
</span>
<span>
全部
</span>
<div
style=
"display:inline-block;float:right"
>
<div
style=
"display:inline-block;float:right"
>
<div
style=
"margin-left: 20px;display:inline-block;"
class=
"appendInput"
>
<div
style=
"margin-left: 20px;display:inline-block;"
class=
"appendInput"
>
<el-input
@
keyup
.
enter
.
native=
"GetPageList()"
size=
"small"
style=
"width:250px"
placeholder=
"请输入内容"
v-model=
"PageMsg.Name"
>
<el-input
@
keyup
.
enter
.
native=
"GetPageList()"
size=
"small"
style=
"width:250px"
placeholder=
"请输入内容"
v-model=
"PageMsg.Name"
>
<el-button
@
click=
"GetPageList"
slot=
"append"
icon=
"el-icon-search"
></el-button>
<el-button
@
click=
"GetPageList"
slot=
"append"
icon=
"el-icon-search"
></el-button>
</el-input>
</el-input>
</div>
</div>
<el-checkbox
style=
"margin-left:12px"
:indeterminate=
"isIndeterminate"
v-model=
"checkAll"
@
change=
"CheckAllChange"
>
全选
</el-checkbox>
<el-checkbox
style=
"margin-left:12px"
:indeterminate=
"isIndeterminate"
v-model=
"checkAll"
<el-button
v-if=
"PageMsg.Recycled==1"
@
click=
"HsPage"
style=
"margin:0 12px"
size=
"small"
>
删除
</el-button>
@
change=
"CheckAllChange"
>
全选
</el-checkbox>
<el-button
v-if=
"PageMsg.Recycled==2"
@
click=
"HYPage"
style=
"margin-left:12px"
size=
"small"
>
还原
</el-button>
<el-button
v-if=
"PageMsg.Recycled==1"
@
click=
"HsPage"
style=
"margin:0 12px"
size=
"small"
>
删除
</el-button>
<el-button
v-if=
"PageMsg.Recycled==2"
@
click=
"HYPage"
style=
"margin-left:12px"
size=
"small"
>
还原
</el-button>
<el-button
v-if=
"PageMsg.Recycled==2"
@
click=
"DeletePage"
size=
"small"
>
删除
</el-button>
<el-button
v-if=
"PageMsg.Recycled==2"
@
click=
"DeletePage"
size=
"small"
>
删除
</el-button>
<el-dropdown
v-if=
"scgroupMsg.Recycled==1"
size=
"small"
split-button
>
<el-dropdown
v-if=
"scgroupMsg.Recycled==1"
size=
"small"
split-button
>
移动至
移动至
...
@@ -76,16 +84,17 @@
...
@@ -76,16 +84,17 @@
<template
v-if=
"PageMsg.Type==1"
>
<template
v-if=
"PageMsg.Type==1"
>
<div
class=
"material-item material-upload"
>
<div
class=
"material-item material-upload"
>
<div
class=
"app-upload"
flex=
"main:center cross:center"
style=
"width: 140px; height: 140px;"
>
<div
class=
"app-upload"
flex=
"main:center cross:center"
style=
"width: 140px; height: 140px;"
>
<el-upload
class=
"avatar-uploader"
action=
""
<el-upload
class=
"avatar-uploader"
action=
""
accept=
"image/jpeg,image/gif,image/png,image/bmp"
accept=
"image/jpeg,image/gif,image/png,image/bmp"
:show-file-list=
"false"
:http-request=
"UploadImage"
multiple
>
:show-file-list=
"false"
:http-request=
"UploadImage"
>
<i
class=
"el-icon-upload"
></i>
<i
class=
"el-icon-upload"
></i>
</el-upload>
</el-upload>
</div>
</div>
</div>
</div>
<el-tooltip
v-for=
"(item,index) in PageList"
:key=
"index"
class=
"item"
effect=
"dark"
:content=
"item.Name"
placement=
"top-start"
>
<el-tooltip
v-for=
"(item,index) in PageList"
:key=
"index"
class=
"item"
effect=
"dark"
<div
@
click=
"PageSelect(item,index)"
:class=
"item.Selected ? 'selected' :''"
class=
"el-tooltip item material-item "
>
:content=
"item.Name"
placement=
"top-start"
>
<div
@
click=
"PageSelect(item,index)"
:class=
"item.Selected ? 'selected' :''"
class=
"el-tooltip item material-item "
>
<img
:src=
"getIconLink(item.Path)"
class=
"material-img"
style=
"width: 140px; height: 140px;"
>
<img
:src=
"getIconLink(item.Path)"
class=
"material-img"
style=
"width: 140px; height: 140px;"
>
<div
flex=
"dir:left"
style=
"margin-top: 5px;"
>
<div
flex=
"dir:left"
style=
"margin-top: 5px;"
>
<div
class=
"material-name"
>
{{
item
.
Name
}}
</div>
<div
class=
"material-name"
>
{{
item
.
Name
}}
</div>
...
@@ -102,18 +111,20 @@
...
@@ -102,18 +111,20 @@
<
template
v-if=
"PageMsg.Type==2"
>
<
template
v-if=
"PageMsg.Type==2"
>
<div
class=
"material-item material-upload"
>
<div
class=
"material-item material-upload"
>
<div
class=
"app-upload"
flex=
"main:center cross:center"
style=
"width: 140px; height: 140px;"
>
<div
class=
"app-upload"
flex=
"main:center cross:center"
style=
"width: 140px; height: 140px;"
>
<el-upload
class=
"avatar-uploader"
action=
""
<el-upload
class=
"avatar-uploader"
action=
""
:before-upload=
"beforeAvatarUpload"
:before-upload=
"beforeAvatarUpload"
accept=
"video/mp4,video/ogg,video/webm"
:show-file-list=
"false"
:http-request=
"UploadImage"
multiple
>
accept=
"video/mp4,video/ogg,video/webm"
:show-file-list=
"false"
:http-request=
"UploadImage"
>
<i
class=
"el-icon-upload"
></i>
<i
class=
"el-icon-upload"
></i>
</el-upload>
</el-upload>
</div>
</div>
</div>
</div>
<el-tooltip
v-for=
"(item,index) in PageList"
:key=
"index"
class=
"item"
effect=
"dark"
:content=
"item.Name"
placement=
"top-start"
>
<el-tooltip
v-for=
"(item,index) in PageList"
:key=
"index"
class=
"item"
effect=
"dark"
<div
@
click=
"PageSelect(item,index)"
:class=
"item.Selected ? 'selected' :''"
class=
"el-tooltip item material-item "
>
:content=
"item.Name"
placement=
"top-start"
>
<img
:src=
"getIconLink(item.Path)+'?x-oss-process=video/snapshot,t_9,f_jpg,w_299,h_0,m_fast'"
class=
"material-img"
style=
"width: 140px; height: 140px;"
>
<div
@
click=
"PageSelect(item,index)"
:class=
"item.Selected ? 'selected' :''"
<div
class=
"material-video-info"
><i
class=
"el-icon-video-play"
></i>
<span>
{{
Time
(
item
.
VideoTime
)
}}
</span></div>
class=
"el-tooltip item material-item "
>
<img
:src=
"getIconLink(item.Path)+'?x-oss-process=video/snapshot,t_9,f_jpg,w_299,h_0,m_fast'"
class=
"material-img"
style=
"width: 140px; height: 140px;"
>
<div
class=
"material-video-info"
><i
class=
"el-icon-video-play"
></i>
<span>
{{
Time
(
item
.
VideoTime
)
}}
</span></div>
<div
flex=
"dir:left"
style=
"margin-top: 5px;"
>
<div
flex=
"dir:left"
style=
"margin-top: 5px;"
>
<div
class=
"material-name"
>
{{
item
.
Name
}}
</div>
<div
class=
"material-name"
>
{{
item
.
Name
}}
</div>
<div
style=
"margin: 0px 5px;"
>
|
</div>
<div
style=
"margin: 0px 5px;"
>
|
</div>
...
@@ -130,13 +141,9 @@
...
@@ -130,13 +141,9 @@
</div>
</div>
<div
style=
"padding-right:10px"
>
<div
style=
"padding-right:10px"
>
<el-pagination
style=
"text-align:right"
<el-pagination
style=
"text-align:right"
background
:current-page=
"currentPage4"
background
@
current-change=
"handleCurrentChange"
:page-size=
"PageMsg.pageSize"
:current-page=
"currentPage4"
layout=
"prev, pager, next,jumper"
:total=
"total"
>
@
current-change=
"handleCurrentChange"
:page-size=
"PageMsg.pageSize"
layout=
"prev, pager, next,jumper"
:total=
"total"
>
</el-pagination>
</el-pagination>
</div>
</div>
</div>
</div>
...
@@ -154,14 +161,8 @@
...
@@ -154,14 +161,8 @@
<el-dialog
title=
"分组管理"
:visible
.
sync=
"addGroupMsgDig"
width=
"400px"
>
<el-dialog
title=
"分组管理"
:visible
.
sync=
"addGroupMsgDig"
width=
"400px"
>
<el-form
:model=
"addGroupMsg"
:rules=
"addGroupMsgrules"
ref=
"addGroupMsg"
label-width=
"100px"
>
<el-form
:model=
"addGroupMsg"
:rules=
"addGroupMsgrules"
ref=
"addGroupMsg"
label-width=
"100px"
>
<el-form-item
label=
"分组名称"
prop=
"Name"
>
<el-form-item
label=
"分组名称"
prop=
"Name"
>
<el-input
<el-input
size=
"small"
type=
"text"
placeholder=
"请输入内容"
v-model=
"addGroupMsg.Name"
maxlength=
"8"
size=
"small"
show-word-limit
>
type=
"text"
placeholder=
"请输入内容"
v-model=
"addGroupMsg.Name"
maxlength=
"8"
show-word-limit
>
</el-input>
</el-input>
</el-form-item>
</el-form-item>
<el-form-item
label=
"排序"
prop=
"Sort"
>
<el-form-item
label=
"排序"
prop=
"Sort"
>
...
@@ -177,12 +178,7 @@
...
@@ -177,12 +178,7 @@
<el-dialog
title=
"图片名称修改"
:visible
.
sync=
"pageMsgDig"
width=
"400px"
>
<el-dialog
title=
"图片名称修改"
:visible
.
sync=
"pageMsgDig"
width=
"400px"
>
<el-form
:model=
"addpageMsg"
:rules=
"addpageMsg"
ref=
"addpageMsg"
label-width=
"100px"
>
<el-form
:model=
"addpageMsg"
:rules=
"addpageMsg"
ref=
"addpageMsg"
label-width=
"100px"
>
<el-form-item
label=
"图片名称"
prop=
"Name"
>
<el-form-item
label=
"图片名称"
prop=
"Name"
>
<el-input
<el-input
size=
"small"
type=
"text"
placeholder=
"请输入内容"
v-model=
"addpageMsg.Name"
>
size=
"small"
type=
"text"
placeholder=
"请输入内容"
v-model=
"addpageMsg.Name"
>
</el-input>
</el-input>
</el-form-item>
</el-form-item>
</el-form>
</el-form>
...
@@ -197,31 +193,31 @@
...
@@ -197,31 +193,31 @@
</template>
</template>
<
script
>
<
script
>
export
default
{
export
default
{
name
:
'ChooseImg'
,
name
:
'ChooseImg'
,
data
()
{
data
()
{
return
{
return
{
loading
:
false
,
loading
:
false
,
commonType
:
1
,
commonType
:
1
,
activeName
:
'first'
,
activeName
:
'first'
,
val
:
''
,
val
:
''
,
Id
:
''
,
Id
:
''
,
currentPage4
:
1
,
currentPage4
:
1
,
scgroupMsg
:{
scgroupMsg
:
{
Id
:
0
,
Id
:
0
,
Name
:
''
,
Name
:
''
,
Type
:
1
,
Type
:
1
,
Recycled
:
1
,
Recycled
:
1
,
},
},
isIndeterminate
:
false
,
isIndeterminate
:
false
,
groupList
:[],
groupList
:
[],
addGroupMsg
:{
addGroupMsg
:
{
Id
:
0
,
Id
:
0
,
Name
:
''
,
Name
:
''
,
Type
:
''
,
Type
:
''
,
Sort
:
''
,
Sort
:
''
,
},
},
addGroupMsgrules
:{
addGroupMsgrules
:
{
Name
:
[{
Name
:
[{
required
:
true
,
required
:
true
,
message
:
'请填写分组名称'
,
message
:
'请填写分组名称'
,
...
@@ -233,212 +229,217 @@ export default {
...
@@ -233,212 +229,217 @@ export default {
trigger
:
'blur'
trigger
:
'blur'
}],
}],
},
},
addGroupMsgDig
:
false
,
addGroupMsgDig
:
false
,
PageMsg
:{
PageMsg
:
{
Id
:
0
,
Id
:
0
,
Name
:
''
,
Name
:
''
,
Type
:
1
,
Type
:
1
,
Recycled
:
1
,
Recycled
:
1
,
pageIndex
:
1
,
pageIndex
:
1
,
pageSize
:
20
,
pageSize
:
20
,
GroupId
:
0
,
GroupId
:
0
,
},
},
PageList
:[],
PageList
:
[],
total
:
0
,
total
:
0
,
addpageMsg
:{
addpageMsg
:
{
Id
:
0
,
Id
:
0
,
Name
:
''
,
Name
:
''
,
Type
:
1
,
Type
:
1
,
GroupId
:
0
,
GroupId
:
0
,
Path
:
''
,
Path
:
''
,
Image
:
''
,
Image
:
''
,
VideoTime
:
0
,
VideoTime
:
0
,
WithHeight
:
0
,
WithHeight
:
0
,
},
},
pageMsgDig
:
false
,
pageMsgDig
:
false
,
checkList
:[],
checkList
:
[],
checkAllList
:[],
checkAllList
:
[],
checkAll
:
false
,
checkAll
:
false
,
}
}
},
},
created
()
{
created
()
{
this
.
GetMemberGradeList
();
this
.
GetMemberGradeList
();
this
.
GetPageList
();
this
.
GetPageList
();
},
},
mounted
(){
mounted
()
{
},
},
methods
:{
methods
:
{
Time
(
value
){
Time
(
value
)
{
var
theTime
=
parseInt
(
value
);
// 秒
var
theTime
=
parseInt
(
value
);
// 秒
var
middle
=
0
;
// 分
var
middle
=
0
;
// 分
var
hour
=
0
;
// 小时
var
hour
=
0
;
// 小时
if
(
theTime
>
60
)
{
if
(
theTime
>
60
)
{
middle
=
parseInt
(
theTime
/
60
);
middle
=
parseInt
(
theTime
/
60
);
theTime
=
parseInt
(
theTime
%
60
);
theTime
=
parseInt
(
theTime
%
60
);
if
(
middle
>
60
)
{
if
(
middle
>
60
)
{
hour
=
parseInt
(
middle
/
60
);
hour
=
parseInt
(
middle
/
60
);
middle
=
parseInt
(
middle
%
60
);
middle
=
parseInt
(
middle
%
60
);
}
}
}
}
var
result
=
""
+
parseInt
(
theTime
);
var
result
=
""
+
parseInt
(
theTime
);
if
(
theTime
<
10
){
if
(
theTime
<
10
)
{
result
=
"0"
+
parseInt
(
theTime
);
result
=
"0"
+
parseInt
(
theTime
);
}
}
if
(
middle
>
0
)
{
if
(
middle
>
0
)
{
result
=
""
+
parseInt
(
middle
)
+
":"
+
result
;
result
=
""
+
parseInt
(
middle
)
+
":"
+
result
;
}
}
else
{
else
{
result
=
"00:"
+
result
;
result
=
"00:"
+
result
;
}
}
if
(
hour
>
0
)
{
if
(
hour
>
0
)
{
result
=
""
+
parseInt
(
hour
)
+
"小时"
+
result
;
result
=
""
+
parseInt
(
hour
)
+
"小时"
+
result
;
}
}
return
result
;
return
result
;
},
},
SelectPageId
(
item
)
{
SelectPageId
(
item
){
this
.
PageList
.
forEach
(
item
=>
{
this
.
PageList
.
forEach
(
item
=>
{
if
(
item
.
Selected
)
{
if
(
item
.
Selected
){
this
.
checkList
.
push
(
item
.
Id
)
this
.
checkList
.
push
(
item
.
Id
)
}
}
})
})
if
(
this
.
checkList
.
length
==
0
)
{
if
(
this
.
checkList
.
length
==
0
)
{
this
.
Error
(
"至少选择一项!"
);
this
.
Error
(
"至少选择一项!"
);
return
;
return
;
}
}
let
MaterialIds
=
this
.
checkList
.
join
(
","
);
let
MaterialIds
=
this
.
checkList
.
join
(
","
);
let
msg
=
{
let
msg
=
{
MaterialIds
:
MaterialIds
,
MaterialIds
:
MaterialIds
,
GroupId
:
item
.
Id
,
GroupId
:
item
.
Id
,
Type
:
this
.
commonType
Type
:
this
.
commonType
}
}
this
.
apipost
(
"/api/product/SetMaterialInfoTransfer"
,
msg
,
res
=>
{
this
.
apipost
(
"/api/product/SetMaterialInfoTransfer"
,
msg
,
res
=>
{
this
.
loading
=
false
;
this
.
loading
=
false
;
if
(
res
.
data
.
resultCode
==
1
)
{
if
(
res
.
data
.
resultCode
==
1
)
{
this
.
GetPageList
();
this
.
GetPageList
();
this
.
checkList
=
[];
this
.
checkList
=
[];
}
}
})
})
},
},
// 全选
// 全选
CheckAllChange
(
val
)
{
CheckAllChange
(
val
)
{
this
.
PageList
.
forEach
(
item
=>
{
this
.
PageList
.
forEach
(
item
=>
{
if
(
val
)
{
if
(
val
)
{
item
.
Selected
=
true
;
item
.
Selected
=
true
;
}
else
{
}
else
{
item
.
Selected
=
false
;
item
.
Selected
=
false
;
}
}
})
})
},
},
// 删除
// 删除
DeletePage
()
{
DeletePage
()
{
this
.
checkList
=
[];
this
.
checkList
=
[];
this
.
PageList
.
forEach
(
item
=>
{
this
.
PageList
.
forEach
(
item
=>
{
if
(
item
.
Selected
)
{
if
(
item
.
Selected
)
{
this
.
checkList
.
push
(
item
.
Id
)
this
.
checkList
.
push
(
item
.
Id
)
}
}
})
})
if
(
this
.
checkList
.
length
==
0
)
{
if
(
this
.
checkList
.
length
==
0
)
{
this
.
Error
(
"至少选择一项!"
);
this
.
Error
(
"至少选择一项!"
);
return
;
return
;
}
}
let
MaterialIds
=
this
.
checkList
.
join
(
","
);
let
MaterialIds
=
this
.
checkList
.
join
(
","
);
this
.
loading
=
true
;
this
.
loading
=
true
;
this
.
apipost
(
"/api/product/DelMaterialInfo"
,{
MaterialIds
:
MaterialIds
},
res
=>
{
this
.
apipost
(
"/api/product/DelMaterialInfo"
,
{
this
.
loading
=
false
;
MaterialIds
:
MaterialIds
if
(
res
.
data
.
resultCode
==
1
){
},
res
=>
{
this
.
loading
=
false
;
if
(
res
.
data
.
resultCode
==
1
)
{
this
.
GetPageList
();
this
.
GetPageList
();
this
.
checkList
=
[];
this
.
checkList
=
[];
}
}
})
})
},
},
// 还原
// 还原
HYPage
()
{
HYPage
()
{
this
.
checkList
=
[];
this
.
checkList
=
[];
this
.
PageList
.
forEach
(
item
=>
{
this
.
PageList
.
forEach
(
item
=>
{
if
(
item
.
Selected
)
{
if
(
item
.
Selected
)
{
this
.
checkList
.
push
(
item
.
Id
)
this
.
checkList
.
push
(
item
.
Id
)
}
}
})
})
if
(
this
.
checkList
.
length
==
0
)
{
if
(
this
.
checkList
.
length
==
0
)
{
this
.
Error
(
"至少选择一项!"
);
this
.
Error
(
"至少选择一项!"
);
return
;
return
;
}
}
let
MaterialIds
=
this
.
checkList
.
join
(
","
);
let
MaterialIds
=
this
.
checkList
.
join
(
","
);
this
.
loading
=
true
;
this
.
loading
=
true
;
this
.
apipost
(
"/api/product/SetMaterialInfoRestore"
,{
MaterialIds
:
MaterialIds
},
res
=>
{
this
.
apipost
(
"/api/product/SetMaterialInfoRestore"
,
{
this
.
loading
=
false
;
MaterialIds
:
MaterialIds
if
(
res
.
data
.
resultCode
==
1
){
},
res
=>
{
this
.
loading
=
false
;
if
(
res
.
data
.
resultCode
==
1
)
{
this
.
GetPageList
();
this
.
GetPageList
();
this
.
checkList
=
[];
this
.
checkList
=
[];
}
}
})
})
},
},
// 回收
// 回收
HsPage
()
{
HsPage
()
{
this
.
checkList
=
[];
this
.
checkList
=
[];
this
.
PageList
.
forEach
(
item
=>
{
this
.
PageList
.
forEach
(
item
=>
{
if
(
item
.
Selected
)
{
if
(
item
.
Selected
)
{
this
.
checkList
.
push
(
item
.
Id
)
this
.
checkList
.
push
(
item
.
Id
)
}
}
})
})
if
(
this
.
checkList
.
length
==
0
)
{
if
(
this
.
checkList
.
length
==
0
)
{
this
.
Error
(
"至少选择一项!"
);
this
.
Error
(
"至少选择一项!"
);
return
;
return
;
}
}
let
MaterialIds
=
this
.
checkList
.
join
(
","
);
let
MaterialIds
=
this
.
checkList
.
join
(
","
);
this
.
loading
=
true
;
this
.
loading
=
true
;
this
.
apipost
(
"/api/product/SetMaterialInfoRecycled"
,{
MaterialIds
:
MaterialIds
},
res
=>
{
this
.
apipost
(
"/api/product/SetMaterialInfoRecycled"
,
{
this
.
loading
=
false
;
MaterialIds
:
MaterialIds
if
(
res
.
data
.
resultCode
==
1
){
},
res
=>
{
this
.
loading
=
false
;
if
(
res
.
data
.
resultCode
==
1
)
{
this
.
GetPageList
();
this
.
GetPageList
();
this
.
checkList
=
[];
this
.
checkList
=
[];
}
}
})
})
},
},
// 单个删除
// 单个删除
PageSelect
(
item
,
index
)
{
PageSelect
(
item
,
index
)
{
item
.
Selected
=
!
item
.
Selected
;
item
.
Selected
=
!
item
.
Selected
;
},
},
// 数组去重
// 数组去重
unique
(
arr
)
{
unique
(
arr
)
{
return
arr
.
filter
(
function
(
item
,
index
,
arr
)
{
return
arr
.
filter
(
function
(
item
,
index
,
arr
)
{
//当前元素,在原始数组中的第一个索引==当前索引值,否则返回当前元素
//当前元素,在原始数组中的第一个索引==当前索引值,否则返回当前元素
return
arr
.
indexOf
(
item
,
0
)
===
index
;
return
arr
.
indexOf
(
item
,
0
)
===
index
;
});
});
},
},
SelectGroup
(
id
)
{
SelectGroup
(
id
)
{
this
.
PageMsg
.
GroupId
=
id
;
this
.
PageMsg
.
GroupId
=
id
;
this
.
addpageMsg
.
GroupId
=
id
;
this
.
addpageMsg
.
GroupId
=
id
;
this
.
GetPageList
();
this
.
GetPageList
();
},
},
EditPage
(
item
)
{
EditPage
(
item
)
{
this
.
pageMsgDig
=
true
;
this
.
pageMsgDig
=
true
;
this
.
addpageMsg
=
{
this
.
addpageMsg
=
{
Id
:
item
.
Id
,
Id
:
item
.
Id
,
Name
:
item
.
Name
,
Name
:
item
.
Name
,
Type
:
item
.
Type
,
Type
:
item
.
Type
,
GroupId
:
item
.
GroupId
,
GroupId
:
item
.
GroupId
,
Path
:
item
.
Path
,
Path
:
item
.
Path
,
Image
:
item
.
Image
,
Image
:
item
.
Image
,
VideoTime
:
item
.
VideoTime
,
VideoTime
:
item
.
VideoTime
,
WithHeight
:
item
.
WithHeight
,
WithHeight
:
item
.
WithHeight
,
}
}
},
},
pagesubmitForm
(
formName
)
{
pagesubmitForm
(
formName
)
{
this
.
$refs
[
formName
].
validate
((
valid
)
=>
{
this
.
$refs
[
formName
].
validate
((
valid
)
=>
{
if
(
valid
)
{
if
(
valid
)
{
this
.
apipost
(
'/api/product/SetMaterialInfo'
,
this
.
addpageMsg
,
this
.
apipost
(
'/api/product/SetMaterialInfo'
,
this
.
addpageMsg
,
res
=>
{
res
=>
{
if
(
res
.
data
.
resultCode
===
1
)
{
if
(
res
.
data
.
resultCode
===
1
)
{
this
.
GetPageList
();
this
.
GetPageList
();
this
.
Success
(
res
.
data
.
message
)
this
.
Success
(
res
.
data
.
message
)
this
.
pageMsgDig
=
false
;
this
.
pageMsgDig
=
false
;
}
else
{
}
else
{
this
.
Error
(
res
.
data
.
message
);
this
.
Error
(
res
.
data
.
message
);
...
@@ -461,13 +462,13 @@ export default {
...
@@ -461,13 +462,13 @@ export default {
var
audioElement
=
new
Audio
(
url
);
var
audioElement
=
new
Audio
(
url
);
audioElement
.
addEventListener
(
"loadedmetadata"
,
(
_event
)
=>
{
audioElement
.
addEventListener
(
"loadedmetadata"
,
(
_event
)
=>
{
this
.
audioDuration
=
parseInt
(
audioElement
.
duration
);
this
.
audioDuration
=
parseInt
(
audioElement
.
duration
);
this
.
addpageMsg
.
VideoTime
=
this
.
audioDuration
;
this
.
addpageMsg
.
VideoTime
=
this
.
audioDuration
;
});
});
},
},
UploadImage
(
file
)
{
UploadImage
(
file
)
{
this
.
UploadFileToTencent
(
this
.
FileType
().
GoodsImg
,
file
.
file
,
res
=>
{
this
.
UploadFileToTencent
(
this
.
FileType
().
GoodsImg
,
file
.
file
,
res
=>
{
if
(
res
.
resultCode
==
1
)
{
if
(
res
.
resultCode
==
1
)
{
if
(
this
.
addpageMsg
.
Type
==
2
)
{
if
(
this
.
addpageMsg
.
Type
==
2
)
{
this
.
addpageMsg
.
Image
=
res
.
FileUrl
;
this
.
addpageMsg
.
Image
=
res
.
FileUrl
;
}
}
this
.
addpageMsg
.
Path
=
res
.
FileUrl
;
this
.
addpageMsg
.
Path
=
res
.
FileUrl
;
...
@@ -477,37 +478,39 @@ export default {
...
@@ -477,37 +478,39 @@ export default {
})
})
},
},
// 新增素材信息
// 新增素材信息
addPageList
()
{
addPageList
()
{
this
.
apipost
(
"/api/product/SetMaterialInfo"
,
this
.
addpageMsg
,
res
=>
{
this
.
apipost
(
"/api/product/SetMaterialInfo"
,
this
.
addpageMsg
,
res
=>
{
if
(
res
.
data
.
resultCode
==
1
)
{
if
(
res
.
data
.
resultCode
==
1
)
{
this
.
GetPageList
();
this
.
GetPageList
();
}
}
})
})
},
},
SelectRecycled
(
num
)
{
SelectRecycled
(
num
)
{
this
.
scgroupMsg
.
Recycled
=
num
;
this
.
scgroupMsg
.
Recycled
=
num
;
this
.
PageMsg
.
Recycled
=
num
;
this
.
PageMsg
.
Recycled
=
num
;
this
.
GetMemberGradeList
();
this
.
GetMemberGradeList
();
this
.
GetPageList
();
this
.
GetPageList
();
},
},
EditGroup
(
item
)
{
EditGroup
(
item
)
{
this
.
addGroupMsgDig
=
true
;
this
.
addGroupMsgDig
=
true
;
this
.
addGroupMsg
=
{
this
.
addGroupMsg
=
{
Id
:
item
.
Id
,
Id
:
item
.
Id
,
Name
:
item
.
Name
,
Name
:
item
.
Name
,
Type
:
item
.
Type
,
Type
:
item
.
Type
,
Sort
:
item
.
Sort
,
Sort
:
item
.
Sort
,
}
}
},
},
HYGroup
(
item
)
{
HYGroup
(
item
)
{
let
that
=
this
;
let
that
=
this
;
that
.
$confirm
(
'是否还原?'
,
'提示'
,
{
that
.
$confirm
(
'是否还原?'
,
'提示'
,
{
confirmButtonText
:
'确定'
,
confirmButtonText
:
'确定'
,
cancelButtonText
:
'取消'
,
cancelButtonText
:
'取消'
,
type
:
'warning'
type
:
'warning'
}).
then
(()
=>
{
}).
then
(()
=>
{
this
.
apipost
(
'/api/product/SetMaterialGroupRestore'
,{
GroupId
:
item
.
Id
},
this
.
apipost
(
'/api/product/SetMaterialGroupRestore'
,
{
GroupId
:
item
.
Id
},
res
=>
{
res
=>
{
if
(
res
.
data
.
resultCode
===
1
)
{
if
(
res
.
data
.
resultCode
===
1
)
{
this
.
GetMemberGradeList
();
this
.
GetMemberGradeList
();
...
@@ -523,14 +526,16 @@ export default {
...
@@ -523,14 +526,16 @@ export default {
});
});
},
},
HsGroup
(
item
)
{
HsGroup
(
item
)
{
let
that
=
this
;
let
that
=
this
;
that
.
$confirm
(
'是否删除?'
,
'提示'
,
{
that
.
$confirm
(
'是否删除?'
,
'提示'
,
{
confirmButtonText
:
'确定'
,
confirmButtonText
:
'确定'
,
cancelButtonText
:
'取消'
,
cancelButtonText
:
'取消'
,
type
:
'warning'
type
:
'warning'
}).
then
(()
=>
{
}).
then
(()
=>
{
this
.
apipost
(
'/api/product/SetMaterialGroupRecycled'
,{
GroupId
:
item
.
Id
},
this
.
apipost
(
'/api/product/SetMaterialGroupRecycled'
,
{
GroupId
:
item
.
Id
},
res
=>
{
res
=>
{
if
(
res
.
data
.
resultCode
===
1
)
{
if
(
res
.
data
.
resultCode
===
1
)
{
this
.
GetMemberGradeList
();
this
.
GetMemberGradeList
();
...
@@ -546,14 +551,16 @@ export default {
...
@@ -546,14 +551,16 @@ export default {
});
});
},
},
DeleteGroup
(
item
)
{
DeleteGroup
(
item
)
{
let
that
=
this
;
let
that
=
this
;
that
.
$confirm
(
'是否删除?'
,
'提示'
,
{
that
.
$confirm
(
'是否删除?'
,
'提示'
,
{
confirmButtonText
:
'确定'
,
confirmButtonText
:
'确定'
,
cancelButtonText
:
'取消'
,
cancelButtonText
:
'取消'
,
type
:
'warning'
type
:
'warning'
}).
then
(()
=>
{
}).
then
(()
=>
{
this
.
apipost
(
'/api/product/DelMaterialGroupInfo'
,{
GroupId
:
item
.
Id
},
this
.
apipost
(
'/api/product/DelMaterialGroupInfo'
,
{
GroupId
:
item
.
Id
},
res
=>
{
res
=>
{
if
(
res
.
data
.
resultCode
===
1
)
{
if
(
res
.
data
.
resultCode
===
1
)
{
this
.
GetMemberGradeList
();
this
.
GetMemberGradeList
();
...
@@ -569,25 +576,25 @@ export default {
...
@@ -569,25 +576,25 @@ export default {
});
});
},
},
addGroup
()
{
addGroup
()
{
this
.
addGroupMsgDig
=
true
;
this
.
addGroupMsgDig
=
true
;
this
.
addGroupMsg
=
{
this
.
addGroupMsg
=
{
Id
:
0
,
Id
:
0
,
Name
:
''
,
Name
:
''
,
Type
:
this
.
commonType
,
Type
:
this
.
commonType
,
Sort
:
''
,
Sort
:
''
,
}
}
},
},
GroupsubmitForm
(
formName
)
{
GroupsubmitForm
(
formName
)
{
this
.
$refs
[
formName
].
validate
((
valid
)
=>
{
this
.
$refs
[
formName
].
validate
((
valid
)
=>
{
if
(
valid
)
{
if
(
valid
)
{
this
.
apipost
(
'/api/product/SetMaterialGroupInfo'
,
this
.
addGroupMsg
,
this
.
apipost
(
'/api/product/SetMaterialGroupInfo'
,
this
.
addGroupMsg
,
res
=>
{
res
=>
{
if
(
res
.
data
.
resultCode
===
1
)
{
if
(
res
.
data
.
resultCode
===
1
)
{
this
.
GetMemberGradeList
();
this
.
GetMemberGradeList
();
this
.
Success
(
res
.
data
.
message
)
this
.
Success
(
res
.
data
.
message
)
this
.
addGroupMsgDig
=
false
;
this
.
addGroupMsgDig
=
false
;
}
else
{
}
else
{
this
.
Error
(
res
.
data
.
message
);
this
.
Error
(
res
.
data
.
message
);
...
@@ -600,34 +607,34 @@ export default {
...
@@ -600,34 +607,34 @@ export default {
}
}
});
});
},
},
GetMemberGradeList
()
{
GetMemberGradeList
()
{
this
.
loading
=
true
;
this
.
loading
=
true
;
this
.
apipost
(
"/api/product/GetMaterialGroupList"
,
this
.
scgroupMsg
,
res
=>
{
this
.
apipost
(
"/api/product/GetMaterialGroupList"
,
this
.
scgroupMsg
,
res
=>
{
this
.
loading
=
false
;
this
.
loading
=
false
;
this
.
groupList
=
res
.
data
.
data
;
this
.
groupList
=
res
.
data
.
data
;
})
})
},
},
GetPageList
()
{
GetPageList
()
{
this
.
loading
=
true
;
this
.
loading
=
true
;
this
.
apipost
(
"/api/product/GetMaterialInfoPageList"
,
this
.
PageMsg
,
res
=>
{
this
.
apipost
(
"/api/product/GetMaterialInfoPageList"
,
this
.
PageMsg
,
res
=>
{
this
.
loading
=
false
;
this
.
loading
=
false
;
this
.
total
=
res
.
data
.
data
.
count
;
this
.
total
=
res
.
data
.
data
.
count
;
let
data
=
res
.
data
.
data
.
pageData
;
let
data
=
res
.
data
.
data
.
pageData
;
this
.
checkAllList
=
[];
this
.
checkAllList
=
[];
data
.
forEach
(
item
=>
{
data
.
forEach
(
item
=>
{
this
.
checkAllList
.
push
(
item
.
Id
)
this
.
checkAllList
.
push
(
item
.
Id
)
item
.
Selected
=
false
;
item
.
Selected
=
false
;
})
})
this
.
PageList
=
data
;
this
.
PageList
=
data
;
})
})
},
},
handleClick
(
val
)
{
handleClick
(
val
)
{
this
.
commonType
=
val
;
this
.
commonType
=
val
;
this
.
scgroupMsg
.
Type
=
val
;
this
.
scgroupMsg
.
Type
=
val
;
this
.
PageMsg
.
Type
=
val
;
this
.
PageMsg
.
Type
=
val
;
this
.
addpageMsg
.
Type
=
val
;
this
.
addpageMsg
.
Type
=
val
;
this
.
GetMemberGradeList
();
this
.
GetMemberGradeList
();
this
.
GetPageList
();
this
.
GetPageList
();
...
@@ -638,11 +645,12 @@ export default {
...
@@ -638,11 +645,12 @@ export default {
},
},
},
},
}
}
</
script
>
</
script
>
<
style
>
<
style
>
.materialMan
.material-video-info
{
.materialMan
.material-video-info
{
background
:
rgba
(
0
,
0
,
0
,
.35
);
background
:
rgba
(
0
,
0
,
0
,
.35
);
color
:
#fff
;
color
:
#fff
;
position
:
absolute
;
position
:
absolute
;
...
@@ -650,31 +658,37 @@ export default {
...
@@ -650,31 +658,37 @@ export default {
bottom
:
31px
;
bottom
:
31px
;
padding
:
1px
3px
;
padding
:
1px
3px
;
font-size
:
14px
;
font-size
:
14px
;
}
}
.materialMan
.TabDiv
.spanActive
{
.materialMan
.TabDiv
.spanActive
{
border-bottom
:
2px
solid
#409EFF
;
border-bottom
:
2px
solid
#409EFF
;
color
:
#409EFF
;
color
:
#409EFF
;
}
}
.materialMan
.TabDiv
span
{
.materialMan
.TabDiv
span
{
font-size
:
14px
;
font-size
:
14px
;
margin-right
:
20px
;
margin-right
:
20px
;
display
:
inline-block
;
display
:
inline-block
;
height
:
100%
;
height
:
100%
;
cursor
:
pointer
;
cursor
:
pointer
;
}
}
.materialMan
.TabDiv
{
.materialMan
.TabDiv
{
height
:
40px
;
height
:
40px
;
line-height
:
40px
;
line-height
:
40px
;
border-bottom
:
2px
solid
#f3f3f3
;
border-bottom
:
2px
solid
#f3f3f3
;
margin-bottom
:
20px
;
margin-bottom
:
20px
;
}
}
.materialMan
.selectActive
.el-icon-tickets
{
.materialMan
.selectActive
.el-icon-tickets
{
color
:
#409EFF
;
color
:
#409EFF
;
}
}
.materialMan
.selectActive
{
.materialMan
.selectActive
{
color
:
#409EFF
;
color
:
#409EFF
;
}
}
.materialMan
.material-name
{
.materialMan
.material-name
{
color
:
#666666
;
color
:
#666666
;
font-size
:
13px
;
font-size
:
13px
;
margin-top
:
0px
;
margin-top
:
0px
;
...
@@ -685,17 +699,21 @@ export default {
...
@@ -685,17 +699,21 @@ export default {
-webkit-box-orient
:
vertical
;
-webkit-box-orient
:
vertical
;
-webkit-line-clamp
:
1
;
-webkit-line-clamp
:
1
;
overflow
:
hidden
;
overflow
:
hidden
;
}
}
.materialMan
.material-item.checked
,
.material-item.selected
{
.materialMan
.material-item.checked
,
.material-item.selected
{
box-shadow
:
0
0
0
1px
#1ed0ff
;
box-shadow
:
0
0
0
1px
#1ed0ff
;
background
:
#daf5ff
;
background
:
#daf5ff
;
border-radius
:
5px
;
border-radius
:
5px
;
}
}
.materialMan
.material-upload
i
{
.materialMan
.material-upload
i
{
font-size
:
30px
;
font-size
:
30px
;
color
:
#909399
;
color
:
#909399
;
}
}
.materialMan
.material-item
{
.materialMan
.material-item
{
display
:
inline-block
;
display
:
inline-block
;
cursor
:
pointer
;
cursor
:
pointer
;
position
:
relative
;
position
:
relative
;
...
@@ -705,29 +723,35 @@ export default {
...
@@ -705,29 +723,35 @@ export default {
margin
:
7.5px
;
margin
:
7.5px
;
text-align
:
center
;
text-align
:
center
;
padding
:
10px
10px
0
;
padding
:
10px
10px
0
;
}
}
.materialMan
.material-upload
{
.materialMan
.material-upload
{
box-shadow
:
none
;
box-shadow
:
none
;
border
:
1px
dashed
#b2b6bd
;
border
:
1px
dashed
#b2b6bd
;
height
:
140px
;
height
:
140px
;
width
:
140px
;
width
:
140px
;
margin
:
17.5px
;
margin
:
17.5px
;
padding
:
0
;
padding
:
0
;
}
}
.ChooseImg
.app-attachment-list
{
.ChooseImg
.app-attachment-list
{
padding
:
5px
;
padding
:
5px
;
}
}
.materialMan
.appendInput
.el-input.is-active
.el-input__inner
,
.materialMan
.appendInput
.el-input__inner
:focus
{
.materialMan
.appendInput
.el-input.is-active
.el-input__inner
,
.materialMan
.appendInput
.el-input__inner
:focus
{
border-color
:
#DCDFE6
;
border-color
:
#DCDFE6
;
}
}
.ChooseImg
.appendInput
.el-input__inner
{
.ChooseImg
.appendInput
.el-input__inner
{
border-right
:
none
;
border-right
:
none
;
outline
:
none
;
outline
:
none
;
}
}
.ChooseImg
.appendInput
.el-input-group__append
{
background-color
:
#fff
!important
;
.ChooseImg
.appendInput
.el-input-group__append
{
background-color
:
#fff
!important
;
border-left
:
none
;
border-left
:
none
;
padding
:
0
15px
;
padding
:
0
15px
;
}
}
</
style
>
</
style
>
src/components/global/ChooseImg.vue
View file @
4fe69012
...
@@ -48,8 +48,8 @@
...
@@ -48,8 +48,8 @@
</div>
</div>
</el-upload>
</el-upload>
</div>
</div>
<el-tooltip
v-for=
"(item,index) in PageList"
:key=
"index"
class=
"item"
effect=
"dark"
:content=
"'双击选中【'+item.Name+'】'"
<el-tooltip
v-for=
"(item,index) in PageList"
:key=
"index"
class=
"item"
effect=
"dark"
placement=
"top-start"
>
:content=
"'双击选中【'+item.Name+'】'"
placement=
"top-start"
>
<div
@
click=
"PageSelect(item,1)"
@
dblclick=
"PageSelect(item,2)"
:class=
"selectId==item.Id ? 'selected' :''"
<div
@
click=
"PageSelect(item,1)"
@
dblclick=
"PageSelect(item,2)"
:class=
"selectId==item.Id ? 'selected' :''"
class=
"el-tooltip item app-attachment-item"
>
class=
"el-tooltip item app-attachment-item"
>
<img
:src=
"getIconLink(item.Path)"
class=
"app-attachment-img"
style=
"width: 100px; height: 100px;"
>
<img
:src=
"getIconLink(item.Path)"
class=
"app-attachment-img"
style=
"width: 100px; height: 100px;"
>
...
@@ -91,6 +91,8 @@
...
@@ -91,6 +91,8 @@
<
script
>
<
script
>
export
default
{
export
default
{
//是否多选
props
:
[
"IsMultiple"
],
name
:
'ChooseImg'
,
name
:
'ChooseImg'
,
data
()
{
data
()
{
return
{
return
{
...
@@ -199,18 +201,17 @@
...
@@ -199,18 +201,17 @@
this
.
apipost
(
"/api/product/SetMaterialInfo"
,
this
.
addpageMsg
,
res
=>
{
this
.
apipost
(
"/api/product/SetMaterialInfo"
,
this
.
addpageMsg
,
res
=>
{
if
(
res
.
data
.
resultCode
==
1
)
{
if
(
res
.
data
.
resultCode
==
1
)
{
this
.
GetPageList
();
this
.
GetPageList
();
}
}
})
})
},
},
// clickType 1单击 2双击
// clickType 1单击 2双击
PageSelect
(
item
,
clickType
)
{
PageSelect
(
item
,
clickType
)
{
this
.
emitmsg
=
{
this
.
emitmsg
=
{
selectId
:
item
.
Id
,
selectId
:
item
.
Id
,
url
:
item
.
Path
url
:
item
.
Path
}
}
this
.
selectId
=
item
.
Id
;
this
.
selectId
=
item
.
Id
;
if
(
clickType
==
2
)
{
if
(
clickType
==
2
)
{
this
.
SelectImgId
();
this
.
SelectImgId
();
}
}
},
},
...
@@ -282,7 +283,7 @@
...
@@ -282,7 +283,7 @@
},
},
SelectGroup
(
id
)
{
SelectGroup
(
id
)
{
this
.
PageMsg
.
GroupId
=
id
;
this
.
PageMsg
.
GroupId
=
id
;
this
.
addpageMsg
.
GroupId
=
id
;
this
.
addpageMsg
.
GroupId
=
id
;
this
.
GetPageList
();
this
.
GetPageList
();
},
},
handleCurrentChange
(
val
)
{
handleCurrentChange
(
val
)
{
...
...
src/plug/index.js
View file @
4fe69012
...
@@ -132,7 +132,7 @@ export default {
...
@@ -132,7 +132,7 @@ export default {
var
filename
=
fileObj
.
name
;
var
filename
=
fileObj
.
name
;
var
index
=
filename
.
lastIndexOf
(
"."
);
var
index
=
filename
.
lastIndexOf
(
"."
);
var
suffix
=
filename
.
substr
(
index
);
var
suffix
=
filename
.
substr
(
index
);
var
timestamp1
=
Date
.
parse
(
new
Date
());
var
timestamp1
=
Date
.
parse
(
new
Date
())
+
"_"
+
(
Math
.
ceil
(
Math
.
random
()
*
1000
))
;
let
str
=
''
;
let
str
=
''
;
if
(
this
.
isOnline
())
{
if
(
this
.
isOnline
())
{
str
=
"/Test"
str
=
"/Test"
...
...
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