Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
P
pptist
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
viitto
pptist
Commits
3ffc7951
Commit
3ffc7951
authored
Feb 29, 2024
by
zhengke
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
优化 最近 分享给我的操作
parent
de57bf49
Hide whitespace changes
Inline
Side-by-side
Showing
11 changed files
with
128 additions
and
96 deletions
+128
-96
App.vue
src/App.vue
+5
-1
index.vue
src/views/Editor/EditorHeader/index.vue
+32
-7
index.vue
src/views/Editor/Thumbnails/index.vue
+4
-20
index.vue
src/views/Editor/index.vue
+1
-1
Share.vue
src/views/SellTemplate/Share.vue
+5
-6
CopyFile.vue
src/views/SellTemplate/components/CopyFile.vue
+21
-21
HistoricalVersion.vue
src/views/SellTemplate/components/HistoricalVersion.vue
+10
-9
SearchDocument.vue
src/views/SellTemplate/components/SearchDocument.vue
+1
-0
TreeFile.vue
src/views/SellTemplate/components/TreeFile.vue
+3
-5
TreeFileRecover.vue
src/views/SellTemplate/components/TreeFileRecover.vue
+1
-1
journeyAdsList.vue
src/views/SellTemplate/components/journeyAdsList.vue
+45
-25
No files found.
src/App.vue
View file @
3ffc7951
...
...
@@ -90,6 +90,7 @@ const userLoginHandler = async ()=>{
if
(
ConfigId
>
0
&&
model
!=
2
)
await
GetTripConfig
(
ConfigId
)
}
catch
(
error
)
{}
if
(
userId
>
0
)
isFinish
.
value
=
true
if
(
param
.
ViewSlideshow
)
{
searchData
.
value
.
ViewSlideshow
=
param
.
ViewSlideshow
try
{
...
...
@@ -124,10 +125,13 @@ const sellHistoryTripTemplate = async (sellId:any,LogId:any) => {
let
queryMsg
let
dataRes
if
(
!
LogId
){
queryMsg
=
{
Id
:
sellId
,
Status
:
searchData
.
value
.
ViewSlideshow
==
1
?
1
:
0
}
// 行程广告浏览记录
if
(
queryMsg
.
Status
==
0
)
await
ConfigService
.
SetTripBrowse
({
FileId
:
sellId
});
dataRes
=
await
ConfigService
.
sellGetTemplateDetails
(
queryMsg
);
}
else
{
queryMsg
=
{
...
...
@@ -167,6 +171,7 @@ const sellHistoryTripTemplate = async (sellId:any,LogId:any) => {
ScreenStore
.
setScreening
(
true
)
enterScreeningFromStart
slidesStore
.
updateSlideIndex
(
0
)
}
else
{
loading
.
value
=
true
ShareTips
.
value
=
dataRes
.
data
.
message
...
...
@@ -176,7 +181,6 @@ const sellHistoryTripTemplate = async (sellId:any,LogId:any) => {
}
}
// 销售分享模版数据
const
sellShareTemplate
=
async
()
=>
{
...
...
src/views/Editor/EditorHeader/index.vue
View file @
3ffc7951
...
...
@@ -70,7 +70,7 @@
<IconUpload
class=
"icon"
/>
</div>
</div>
<div
class=
"menu-item"
v-tooltip=
"'导出'"
@
click=
"setDialogForExport('image')"
>
<div
v-if=
"!searchData.noExportPermission"
class=
"menu-item"
v-tooltip=
"'导出'"
@
click=
"setDialogForExport('image')"
>
<IconDownload
class=
"icon"
/>
</div>
<el-button
type=
"primary"
...
...
@@ -85,7 +85,7 @@
</
template
>
</el-button>
<
template
v-if=
"model==2"
>
<el-dropdown
v-if=
"searchData.sellId>0"
split-button
<el-dropdown
v-if=
"searchData.sellId>0
&&!searchData.noCopyPermission
"
split-button
size=
"small"
type=
"primary"
@
click=
"setTemplate(0)"
>
保存
<template
#
dropdown
>
...
...
@@ -109,7 +109,7 @@
</el-dropdown-menu>
</
template
>
</el-dropdown>
<el-button
v-if=
"!searchData.sellId"
type=
"primary"
<el-button
v-if=
"!searchData.sellId
||(searchData.sellId>0&&searchData.noCopyPermission)
"
type=
"primary"
size=
"small"
:loading=
"datas.loading"
style=
"color: #ffff;margin-left: 10px;"
@
click=
"setTemplate(0)"
>
...
...
@@ -129,6 +129,12 @@
<FullscreenSpin
:loading=
"exporting"
tip=
"正在导入..."
/>
<Psd-Upload
:visible=
"psdVisibleStatus"
@
closed=
"psdVisibleStatus=false"
></Psd-Upload>
<CopyFile
v-if=
"isCopyTo"
:details=
"journeyAdsDetails"
:type=
"2"
@
close=
"() => {journeyAdsDetails = '';isCopyTo=false;datas.loading = false}"
@
success=
"(FolderId:Number)=>SetSellTemplate(1,FolderId)"
></CopyFile>
</div>
</template>
...
...
@@ -167,7 +173,7 @@ import { PPTImageElement } from '@/types/slides'
import
AliyunUpload
from
'@/utils/upload/aliyun'
import
{
ElLoading
,
ElMessage
}
from
'element-plus'
import
ThumbnailSlide
from
'@/views/components/ThumbnailSlide/index.vue'
import
CopyFile
from
"@/views/SellTemplate/components/CopyFile.vue"
;
const
mainStore
=
useMainStore
()
const
slidesStore
=
useSlidesStore
()
...
...
@@ -208,6 +214,8 @@ const TempIdStore = useScreenStore()
const
ConfigIdStore
=
useScreenStore
()
const
loadingInstance
=
ref
<
any
>
(
null
)
const
thumbnails
=
ref
<
string
[]
>
()
const
isCopyTo
=
ref
(
false
)
const
journeyAdsDetails
=
ref
<
Object
>
()
const
psdVisibleStatus
=
ref
(
false
)
const
{
market
,
model
,
ConfigId
,
CoverImg
,
dataLoading
,
TempId
,
SourceLoading
}
=
storeToRefs
(
useScreenStore
())
...
...
@@ -275,7 +283,8 @@ const UploadPsdHandler = () => {
}
// 销售新增修改行程、广告
const
SetSellTemplate
=
async
(
type
)
=>
{
const
SetSellTemplate
=
async
(
type
:
Number
,
FolderId
:
Number
)
=>
{
if
(
FolderId
>=
0
)
datas
.
loading
=
true
try
{
let
TempId
=
0
if
(
queryObj
.
value
.
TempId
)
TempId
=
queryObj
.
value
.
TempId
...
...
@@ -296,11 +305,15 @@ const SetSellTemplate = async (type) => {
Title
:
queryObj
.
value
.
Title
,
OWidth
:
0
,
OHeight
:
0
,
FolderId
:
FolderId
>=
0
?
FolderId
:
searchData
.
value
.
ParentFileId
}
if
(
queryObj
.
value
.
TemplateType
==
2
){
queryMsg
.
OWidth
=
queryObj
.
value
.
Width
queryMsg
.
OHeight
=
queryObj
.
value
.
Height
}
journeyAdsDetails
.
value
=
''
isCopyTo
.
value
=
false
console
.
log
(
queryMsg
,
'------queryMsg销售保存'
)
let
TemplateRes
=
await
ConfigService
.
sellSetTemplate
(
queryMsg
);
if
(
TemplateRes
.
data
.
resultCode
==
1
)
{
ElMessage
({
...
...
@@ -460,7 +473,7 @@ const SetTripTemplateConfig = async () => {
// 保存
const
setTemplate
=
async
(
type
)
=>
{
queryObj
.
value
.
Title
=
title
.
value
datas
.
loading
=
true
if
(
SourceLoading
.
value
)
setNewDatasList
(
datas
.
DataSource
)
await
uploadImageHandler
()
...
...
@@ -526,11 +539,23 @@ const setTemplate = async (type) =>{
queryObj
.
value
.
TempData
=
JSON
.
stringify
(
arr
)
if
(
model
.
value
==
1
&&
userInfo
.
value
.
IsEditTripTemplate
==
1
){
datas
.
loading
=
true
await
SetTripTemplateSlide
()
}
else
if
(
ConfigId
.
value
&&
model
.
value
!=
2
){
datas
.
loading
=
true
await
SetTripTemplateConfig
()
}
else
if
(
model
.
value
==
2
&&
SalesEditor
.
value
>
0
){
await
SetSellTemplate
(
type
)
if
(
type
==
1
){
let
obj
=
{
FileName
:
queryObj
.
value
.
Title
,
FileType
:
queryObj
.
value
.
TemplateType
}
journeyAdsDetails
.
value
=
obj
isCopyTo
.
value
=
true
}
else
{
datas
.
loading
=
true
await
SetSellTemplate
(
type
)
}
}
}
...
...
src/views/Editor/Thumbnails/index.vue
View file @
3ffc7951
...
...
@@ -60,7 +60,7 @@ import useScreening from '@/hooks/useScreening'
import
useLoadSlides
from
'@/hooks/useLoadSlides'
import
{
injectKeyDataSource
,
injectKeyTemplate
}
from
'@/types/injectKey'
import
ConfigService
from
'@/services/ConfigService'
import
{
getHtmlPlainText
}
from
'@/utils/common'
import
{
getHtmlPlainText
,
query
}
from
'@/utils/common'
import
useEditor
from
'@/utils/Editor/index'
import
{
VIEWPORT_SIZE
,
VIEWPORT_VER_SIZE
}
from
'@/configs/canvas'
...
...
@@ -505,9 +505,10 @@ const sellGetTripTemplate = async () =>{
let
queryMsg
=
{
Id
:
Id
}
// 行程广告浏览记录
await
ConfigService
.
SetTripBrowse
({
FileId
:
searchData
.
value
.
sellId
});
let
dataRes
=
await
ConfigService
.
sellGetTemplateDetails
(
queryMsg
);
if
(
dataRes
.
data
.
resultCode
==
1
)
{
RecordBrowsing
()
if
(
searchData
.
value
.
TempId
)
queryObj
.
value
.
TempId
=
searchData
.
value
.
TempId
else
if
(
searchData
.
value
.
TempId2
&&!
searchData
.
value
.
TempId
)
queryObj
.
value
.
TempId
=
searchData
.
value
.
TempId2
else
if
(
searchData
.
value
.
sellTempId
)
queryObj
.
value
.
TempId
=
searchData
.
value
.
sellTempId
...
...
@@ -551,23 +552,6 @@ const sellGetTripTemplate = async () =>{
}
}
/**
* 行程广告浏览记录
*/
const
RecordBrowsing
=
async
()
=>
{
try
{
let
queryMsg
=
{
FileId
:
searchData
.
value
.
sellId
}
let
datasRes
=
await
ConfigService
.
SetTripBrowse
(
queryMsg
);
if
(
datasRes
.
data
.
resultCode
==
1
&&
datasRes
.
data
.
data
&&
datasRes
.
data
.
data
.
TempId
)
{
}
}
catch
(
error
)
{
}
}
// 页面被切换时
const
thumbnailsRef
=
ref
<
InstanceType
<
typeof
Draggable
>>
()
...
...
@@ -755,7 +739,7 @@ const contextmenusThumbnailItem = (): ContextmenuItem[] => {
]
}
if
(
searchData
.
value
.
sellId
&&!
searchData
.
value
.
TempId
)
sellGetTripTemplate
()
GetTripTemplate
()
if
(
!
query
().
ViewSlideshow
)
GetTripTemplate
()
</
script
>
...
...
src/views/Editor/index.vue
View file @
3ffc7951
...
...
@@ -174,7 +174,7 @@ const GetTripFiled = async () =>{
console
.
log
(
"TemplateGetTripFiled"
,
error
);
}
}
if
(
searchData
.
value
.
TemplateType
!=
2
)
GetTripFiled
()
if
(
searchData
.
value
.
TemplateType
!=
2
&&!
query
().
ViewSlideshow
)
GetTripFiled
()
const
mainStore
=
useMainStore
()
...
...
src/views/SellTemplate/Share.vue
View file @
3ffc7951
...
...
@@ -72,7 +72,7 @@
{{
formatDateTimeToRead
(
scope
.
row
.
UpdateTime
&&
scope
.
row
.
UpdateTime
!=
''
?
scope
.
row
.
UpdateTime
:
scope
.
row
.
CreateTime
)
}}
</
template
>
</el-table-column>
<el-table-column
label=
"分享人"
prop=
"CreateName"
width=
"1
0
0"
/>
<el-table-column
label=
"分享人"
prop=
"CreateName"
width=
"1
8
0"
/>
<el-table-column
label=
"操作"
width=
"120"
>
<
template
#
default=
"scope"
>
<div
class=
"row items-center"
:class=
"
{'hover':showItemId!=scope.row.FileId}">
...
...
@@ -148,7 +148,6 @@ const tempFilterName = ref('')
const
currentRootDom
=
ref
()
const
hgihlightId
=
ref
(
0
)
const
dataTableRef
=
ref
()
const
lastKeyword
=
ref
(
''
)
const
backInquireHandler
=
()
=>
{
let
Navigation
=
navigations
.
value
[
navigations
.
value
.
length
-
2
];
...
...
@@ -179,11 +178,14 @@ const editorFileHandler = (item:any)=>{
searchData
.
value
.
sellId
=
item
.
FileId
;
searchData
.
value
.
sellTempId
=
item
.
TempId
;
searchData
.
value
.
TemplateType
=
item
.
FileType
;
if
(
item
.
IsDownload
==
0
)
searchData
.
value
.
noExportPermission
=
true
else
searchData
.
value
.
noExportPermission
=
false
if
(
item
.
IsView
==
0
)
searchData
.
value
.
noCopyPermission
=
true
else
searchData
.
value
.
noCopyPermission
=
false
SalesEditorStore
.
setSalesEditor
(
2
);
marketStore
.
setMarket
(
false
);
}
const
getDocumentData
=
async
()
=>
{
lastKeyword
.
value
=
queryObj
.
FileName
if
(
loading
.
value
)
return
loading
.
value
=
true
try
{
...
...
@@ -375,9 +377,6 @@ getDocumentData()
text-overflow
:ellipsis
!
important
;
width
:
100%
;
}
.el-table
.caret-wrapper
{
height
:
12px
!
important
;
}
/* .sample-table th:nth-child(2) .cell{
padding-left: 0 !important;
} */
...
...
src/views/SellTemplate/components/CopyFile.vue
View file @
3ffc7951
...
...
@@ -2,8 +2,8 @@
<el-dialog
v-model=
"show"
v-loading=
"loading"
:show-close=
"false"
:close-on-press-escape=
"false"
:close-on-click-modal=
"false"
style=
"width: 260px"
>
<template
#
header
>
<div
class=
"row overflow-hide"
@
click=
"OffEdit"
>
<div>
<div
class=
"row overflow-hide"
>
<div
@
click=
"OffEdit"
>
<img
v-if=
"details.FileType > 0"
class=
"q-px-md"
:src=
"details.FileType == 1 ? datas.pdfImg : datas.adsImg"
style=
"height: 43px"
/>
<img
v-else
class=
"q-px-md"
src=
"@/assets/img/file.png"
style=
"height: 43px"
/>
...
...
@@ -20,11 +20,12 @@
{{ details.FileName }}
</div>
</el-tooltip>
<el-input
class=
"journeyAds-Input"
v-model=
"details.FileName"
autosize
type=
"textarea"
<el-input
v-model=
"details.FileName"
autosize
type=
"textarea"
placeholder=
"Please input"
maxlength=
"500"
size=
"small"
v-if=
"datas.editTitle"
@
blur=
"
handleUpdateTitle
"
/>
@
blur=
"
OffEdit
"
/>
</div>
<div
class=
"text-small text-5B5D62 q-pt-sm"
>
<div
class=
"text-small text-5B5D62 q-pt-sm"
v-if=
"details.CreateByName||details.CreateName"
@
click=
"OffEdit"
>
创建者:
<
template
v-if=
"type == 1"
>
{{
details
.
CreateByName
}}
...
...
@@ -37,7 +38,7 @@
</div>
</template>
<div
class=
"TreeFile-container"
@
click=
"!type?OffEdit:''"
>
<div
class=
"TreeFile-container"
>
<el-tree-select
placeholder=
"请选择文件"
node-key=
"FileId"
...
...
@@ -48,7 +49,7 @@
:render-after-expand=
"false"
style=
"width: 220px"
filterable
@
che
ck=
"handleTreeNodeClick"
@
node-cli
ck=
"handleTreeNodeClick"
class=
"auto-width-tree"
/>
...
...
@@ -57,10 +58,9 @@
<
template
#
footer
>
<div
@
click=
"OffEdit"
>
<span
class=
"dialog-footer"
>
<el-button
@
click=
"() => closedhandler()"
>
关闭
</el-button>
<el-button
type=
"primary"
@
click=
"() => save()"
>
保存
<template
v-if=
"type == 1"
>
另存
</
template
>
<
template
v-else-if=
"type == 2"
>
替换
</
template
>
<el-button
@
click
.
stop=
"() => closedhandler()"
>
关闭
</el-button>
<el-button
type=
"primary"
@
click
.
stop=
"() => save()"
>
保存
<template
v-if=
"type"
>
另存
</
template
>
<
template
v-else
>
复制
</
template
>
</el-button>
</span>
...
...
@@ -125,21 +125,17 @@ const dataList = ref([]);
const
OffEdit
=
()
=>
{
datas
.
editTitle
=
false
;
};
const
handleUpdateTitle
=
()
=>
{
OffEdit
();
};
const
closedhandler
=
()
=>
{
emit
(
"close"
);
emit
(
"close"
);
};
const
handleTreeNodeClick
=
(
data
:
any
,
checkObj
:
any
)
=>
{
datas
.
FolderObj
=
data
;
OffEdit
();
if
(
checkObj
.
checkedKeys
.
length
!=
0
)
{
datas
.
FolderObj
=
data
;
}
};
const
save
=
()
=>
{
let
title
=
props
.
details
.
FileName
;
if
(
props
.
type
)
title
=
props
.
type
==
1
?
"另存"
:
"替换
"
;
if
(
props
.
type
)
title
=
"另存
"
;
else
title
=
title
+
"复制"
;
ElMessageBox
.
confirm
(
`此操作将
${
title
}
到
${
datas
.
FolderObj
.
FileName
?
datas
.
FolderObj
.
FileName
:
"根目录"
...
...
@@ -153,8 +149,12 @@ const save = () => {
)
.
then
(
async
()
=>
{
try
{
if
(
props
.
type
)
SaveOverlay
(
title
);
else
CopyId
();
if
(
props
.
type
==
1
)
SaveOverlay
(
title
);
else
if
(
props
.
type
==
2
)
{
let
FolderId
=
datas
.
FolderId
!=
null
?
datas
.
FolderId
:
0
emit
(
'success'
,
FolderId
);
}
else
if
(
!
props
.
type
)
CopyId
();
}
catch
(
error
)
{
}
})
.
catch
(()
=>
{
});
...
...
src/views/SellTemplate/components/HistoricalVersion.vue
View file @
3ffc7951
...
...
@@ -45,18 +45,18 @@
</td>
<td
class=
"text-light text-5B5D62"
><span>
{{
item
.
FileSize
}}
KB
</span></td>
<td
class=
"text-light"
>
<span
:class=
"[item.
NewTitle
?'active':'text-5B5D62']"
>
{{
item
.
NewTitle
?
item
.
NewTitle
:
''
}}
</span>
<span
:class=
"[item.
LogId==0
?'active':'text-5B5D62']"
>
{{
item
.
LogId
==
0
?
'当前版本'
:
''
}}
</span>
</td>
<td
class=
"text-center"
>
<span
class=
"hoverShow"
>
<span
class=
"hoverShow
row items-center
"
>
<el-button
type=
"primary"
icon=
"View"
size=
"small"
@
click
.
stop=
"clickControls(item)"
>
查看
</el-button>
<el-dropdown
class=
"q-pl-md"
trigger=
"click"
>
<el-icon
size=
"16"
color=
"#b1b7cf"
><MoreFilled
/></el-icon>
<template
#
dropdown
>
<el-dropdown-menu
class=
"q-pa-md"
@
click
.
stop=
"OffEdit"
>
<el-dropdown-item
icon=
"Promotion"
@
click
.
stop=
"clickControls(item,1)"
>
另存
</el-dropdown-item>
<el-dropdown-item
v-if=
"
!item.NewTitle
"
icon=
"Switch"
@
click
.
stop=
"clickControls(item,2)"
>
替换
</el-dropdown-item>
<el-dropdown-item
v-if=
"
item.LogId!=0
"
icon=
"Switch"
@
click
.
stop=
"clickControls(item,2)"
>
替换
</el-dropdown-item>
</el-dropdown-menu>
</
template
>
</el-dropdown>
...
...
@@ -65,9 +65,9 @@
</tr>
</template>
</table>
<div
v-if=
"dataList.length == 0 && !loading"
class=
"bg-white rounded"
style=
"padding:
0
10px;"
>
<el-empty
:image-size=
"
60"
description=
"暂无数据
"
/>
<div
v-if=
"dataList.length == 0 && !loading"
class=
"bg-white rounded
col
"
style=
"padding:
40px
10px;"
>
<el-empty
:image-size=
"
150"
description=
"文档没有历史版本
"
/>
</div>
<el-divider
class=
"no-bg q-mt-lg"
v-if=
'dataList.length>0 && queryObj.pageCount == queryObj.pageIndex && !loading && queryObj.pageCount != 1'
>
<span
class=
"text-small bg-white"
style=
"padding: 0 10px;color:#a3a3a3"
>
已加载完成所有数据
</span>
...
...
@@ -132,7 +132,6 @@ import CopyFile from "./CopyFile.vue";
pageSize
:
10
,
pageCount
:
0
,
//总页数
FileId
:
props
.
details
.
FileId
,
UpdateTime
:
''
})
const
journeyAdsDetails
=
ref
(
''
);
const
isCopyTo
=
ref
(
false
);
...
...
@@ -212,11 +211,13 @@ import CopyFile from "./CopyFile.vue";
};
arrList
(
pageRes
.
data
.
data
.
pageData
);
dataList
.
value
=
dataList
.
value
.
concat
(
pageRes
.
data
.
data
.
pageData
);
dataList
.
value
[
0
].
NewTitle
=
'当前版本'
queryObj
.
pageCount
=
pageRes
.
data
.
data
.
pageCount
;
}
loading
.
value
=
false
}
catch
(
error
)
{
ElMessage
.
error
({
message
:
'数据加载异常,请刷新页面'
})
loading
.
value
=
false
}
}
...
...
src/views/SellTemplate/components/SearchDocument.vue
View file @
3ffc7951
...
...
@@ -121,6 +121,7 @@ const editorFileHandler = (item:any)=>{
searchData
.
value
.
sellId
=
item
.
FileId
;
searchData
.
value
.
sellTempId
=
item
.
TempId
;
searchData
.
value
.
TemplateType
=
item
.
FileType
;
searchData
.
value
.
ParentFileId
=
item
.
FolderId
SalesEditorStore
.
setSalesEditor
(
2
);
marketStore
.
setMarket
(
false
);
}
...
...
src/views/SellTemplate/components/TreeFile.vue
View file @
3ffc7951
...
...
@@ -60,7 +60,7 @@
:render-after-expand=
"false"
style=
"width: 220px"
filterable
@
c
heck
=
"handleTreeNodeClick"
@
c
urrent-change
=
"handleTreeNodeClick"
class=
"auto-width-tree"
/>
...
...
@@ -139,9 +139,7 @@ import FolderService from "@/services/FolderService";
const
handleTreeNodeClick
=
(
data
:
any
,
checkObj
:
any
)
=>
{
// 共两个参数,依次为:传递给 data 属性的数组中该节点所对应的对象、树目前的选中状态对象
// 树目前的选中状态对象,包含 checkedNodes、checkedKeys、halfCheckedNodes、halfCheckedKeys 四个属性
if
(
checkObj
.
checkedKeys
.
length
!=
0
)
{
datas
.
FolderObj
=
data
}
datas
.
FolderObj
=
data
}
const
filterNode
=
(
value
:
string
,
data
:
Tree
)
=>
{
if
(
!
value
)
return
true
...
...
@@ -169,7 +167,7 @@ import FolderService from "@/services/FolderService";
})
}
ElMessageBox
.
confirm
(
`此操作将
${
title
}
移动到
${
datas
.
FolderObj
.
FileName
}
,是否确定?`
,
"提示"
,
{
ElMessageBox
.
confirm
(
`此操作将
${
title
}
移动到
${
datas
.
FolderObj
.
FileName
?
datas
.
FolderObj
.
FileName
:
'根目录'
}
,是否确定?`
,
"提示"
,
{
confirmButtonText
:
"确定"
,
cancelButtonText
:
"取消"
,
type
:
"warning"
,
...
...
src/views/SellTemplate/components/TreeFileRecover.vue
View file @
3ffc7951
...
...
@@ -139,7 +139,7 @@ import FolderService from "@/services/FolderService";
}
const
save
=
()
=>
{
let
title
=
props
.
details
.
FileName
ElMessageBox
.
confirm
(
`此操作将
${
title
}
恢复到
${
datas
.
FolderObj
.
FileName
}
,是否确定?`
,
"提示"
,
{
ElMessageBox
.
confirm
(
`此操作将
${
title
}
恢复到
${
datas
.
FolderObj
.
FileName
?
datas
.
FolderObj
.
FileName
:
'根目录'
}
,是否确定?`
,
"提示"
,
{
confirmButtonText
:
"确定"
,
cancelButtonText
:
"取消"
,
type
:
"warning"
,
...
...
src/views/SellTemplate/components/journeyAdsList.vue
View file @
3ffc7951
<
template
>
<el-table
ref=
"dataTableRef"
highlight-current-row
class=
"sample-table"
v-load-more=
"tableScrollHandler"
:data=
"dataList"
style=
"width: 100%"
<el-table
v-loading=
"loading"
ref=
"dataTableRef"
highlight-current-row
class=
"sample-table"
v-load-more=
"tableScrollHandler"
:data=
"dataList"
style=
"width: 100%"
@
sort-change=
"sortHandler"
:default-sort=
"
{ prop: 'CreateTime', order: 'descending' }"
@selection-change="handleSelectionChange">
<el-table-column
type=
"selection"
width=
"20"
v-if=
"currentMenu==3||currentMenu==4"
/>
...
...
@@ -55,24 +55,29 @@
</div>
</template>
</el-table-column>
<el-table-column
:label=
"datas.Title"
width=
"150"
sortable=
"custom"
prop=
""
>
<el-table-column
:label=
"datas.Title"
width=
"150"
sortable=
"custom"
prop=
"
CreateTime
"
>
<
template
#
default=
"scope"
>
{{
formatDateTimeToRead
(
scope
.
row
.
UpdateTime
&&
scope
.
row
.
UpdateTime
!=
''
?
scope
.
row
.
UpdateTime
:
scope
.
row
.
CreateTime
)
}}
</
template
>
</el-table-column>
<el-table-column
label=
"创建人"
prop=
"CreateName"
width=
"100"
/>
<el-table-column
label=
"创建人"
prop=
""
width=
"180"
>
<
template
#
default=
"scope"
>
{{
scope
.
row
.
CreateName
}}
<span
class=
"text-info"
v-if=
"datas.loggedder!=scope.row.CreateName"
>
分享的
</span>
</
template
>
</el-table-column>
<el-table-column
label=
"操作"
width=
"120"
>
<
template
#
default=
"scope"
>
<div
class=
"row items-center"
:class=
"
{'hover':showItemId!=scope.row.FileId}">
<el-button
v-if=
"currentMenu!=-1"
type=
"primary"
:icon=
"Edit"
size=
"small"
@
click
.
stop=
"editDelete(scope.row)"
>
编辑
</el-button>
<el-button
v-
else
type=
"primary"
icon=
"Position"
size=
"small"
@
click
.
stop=
"recover(scope.row)"
>
恢复
</el-button>
<el-button
v-if=
"currentMenu!=-1
&&scope.row.IsEdit
"
type=
"primary"
:icon=
"Edit"
size=
"small"
@
click
.
stop=
"editDelete(scope.row)"
>
编辑
</el-button>
<el-button
v-
if=
"currentMenu==-1"
type=
"primary"
icon=
"Position"
size=
"small"
@
click
.
stop=
"recover(scope.row)"
>
恢复
</el-button>
<el-dropdown
class=
"q-pl-md"
trigger=
"click"
@
visible-change=
"(val:boolean)=>dropdownChange(val,scope.row.FileId)"
v-if=
"
scope.row.FileType||currentMenu!=-1
"
>
v-if=
"
(datas.loggedder==scope.row.CreateName&&(scope.row.FileType||currentMenu!=-1))||scope.row.IsDownload||scope.row.IsView
"
>
<el-icon
size=
"16"
color=
"#b1b7cf"
><MoreFilled
/></el-icon>
<template
#
dropdown
>
<el-dropdown-menu
class=
"q-pa-md"
@
click
.
stop=
"OffEdit"
>
<el-dropdown-item
v-if=
"scope.row.FileType>0"
icon=
"View"
@
click=
"viewTemplate(scope.row)"
>
查看
</el-dropdown-item>
<template
v-if=
"currentMenu!=-1"
>
<el-dropdown-item
v-if=
"scope.row.FileType>0
&&scope.row.IsView
"
icon=
"View"
@
click=
"viewTemplate(scope.row)"
>
查看
</el-dropdown-item>
<template
v-if=
"currentMenu!=-1
&&datas.loggedder==scope.row.CreateName
"
>
<el-dropdown-item
v-if=
"scope.row.FileType"
icon=
"EditPen"
@
click
.
stop=
"startEditTitle(scope.row)"
>
重命名
</el-dropdown-item>
<el-dropdown-item
v-if=
"scope.row.FileType"
icon=
"Clock"
@
click
.
stop=
"history(scope.row)"
>
历史版本
</el-dropdown-item>
<el-dropdown-item
icon=
"Position"
@
click
.
stop=
"()=>setFileShareHandler(scope.row)"
>
分享
</el-dropdown-item>
...
...
@@ -85,10 +90,10 @@
<span>
{{
scope
.
row
.
IsCollect
?
'取消收藏'
:
'收藏'
}}
</span>
</span>
</el-dropdown-item>
<el-dropdown-item
v-if=
"scope.row.FileType!=0&¤tMenu!=-1"
icon=
"Download"
@
click=
"exportDocument(scope.row)"
>
导出
</el-dropdown-item>
<el-dropdown-item
v-if=
"scope.row.FileType"
icon=
"CopyDocument"
@
click
.
stop=
"CopyTo(scope.row)"
>
复制到
</el-dropdown-item>
<el-dropdown-item
icon=
"Delete"
@
click=
"editDelete(scope.row,1)"
>
删除
</el-dropdown-item>
</
template
>
<el-dropdown-item
v-if=
"scope.row.FileType!=0&¤tMenu!=-1&&scope.row.IsDownLoad"
icon=
"Download"
@
click=
"exportDocument(scope.row)"
>
导出
</el-dropdown-item>
<el-dropdown-item
v-if=
"scope.row.FileType&&scope.row.IsView"
icon=
"CopyDocument"
@
click
.
stop=
"CopyTo(scope.row)"
>
复制到
</el-dropdown-item>
</el-dropdown-menu>
</template>
...
...
@@ -100,7 +105,7 @@
<el-empty
:image-size=
"150"
v-if=
"(!dataList || dataList.length==0) && !loading"
:description=
"datas.emptyTitle"
/>
</
template
>
</el-table>
</el-table>
<ShareForm
:id=
"shareId"
:file-type=
"shareFileType"
...
...
@@ -148,6 +153,8 @@
emit('success')}"
></TreeFileRecover>
</template>
<
script
setup
lang=
"ts"
>
import
{
userStore
}
from
'@/store/user'
;
import
{
storeToRefs
}
from
'pinia'
;
import
{
ApiResult
}
from
'@/configs/axios'
;
import
OrgService
from
'@/services/OrgService'
;
import
{
ref
,
reactive
,
watch
,
inject
,
nextTick
,
PropType
}
from
'vue'
;
...
...
@@ -208,6 +215,7 @@ import CopyFile from "./CopyFile.vue";
type
:
number
;
}
>
({
id
:
-
1
,
name
:
""
,
parentId
:
0
,
number
:
1
});
const
datas
=
reactive
({
loggedder
:
''
,
emptyTitle
:
''
,
Title
:
''
,
selectAll
:
false
as
any
,
...
...
@@ -222,11 +230,14 @@ import CopyFile from "./CopyFile.vue";
});
const
SalesEditorStore
=
useSellTemplateStore
();
const
marketStore
=
useScreenStore
();
const
{
userInfo
}
=
storeToRefs
(
userStore
())
datas
.
loggedder
=
userInfo
.
value
.
emName
const
dataList
=
ref
([]
as
Array
<
any
>
);
dataList
.
value
=
props
.
list
const
queryObj
=
ref
({}
as
any
);
queryObj
.
value
=
props
.
msg
const
loading
=
ref
(
false
)
as
Boolean
const
shareId
=
ref
(
0
);
const
shareFileType
=
ref
(
0
)
...
...
@@ -291,12 +302,6 @@ import CopyFile from "./CopyFile.vue";
}
emit
(
'refreshHandler'
,
obj
)
}
const
clickSort
=
(
type
:
any
)
=>
{
let
obj
=
{
OrderByType
:
queryObj
.
value
.
OrderByType
==
2
?
1
:
2
}
emit
(
'refreshHandler'
,
obj
)
}
const
sortHandler
=
(
val
:
any
)
=>
{
queryObj
.
value
.
OrderByType
=
val
.
order
==
'descending'
?
2
:
1
let
obj
=
{
...
...
@@ -554,6 +559,13 @@ import CopyFile from "./CopyFile.vue";
searchData
.
value
.
sellId
=
row
.
FileId
;
searchData
.
value
.
sellTempId
=
row
.
TempId
;
searchData
.
value
.
TemplateType
=
row
.
FileType
;
searchData
.
value
.
ParentFileId
=
row
.
ParentFileId
;
if
(
props
.
currentMenu
==
0
&&
datas
.
loggedder
!=
row
.
CreateName
){
if
(
row
.
IsDownLoad
==
0
)
searchData
.
value
.
noExportPermission
=
true
else
searchData
.
value
.
noExportPermission
=
false
if
(
row
.
IsView
==
0
)
searchData
.
value
.
noCopyPermission
=
true
else
searchData
.
value
.
noCopyPermission
=
false
}
SalesEditorStore
.
setSalesEditor
(
2
);
marketStore
.
setMarket
(
false
);
}
else
{
...
...
@@ -607,13 +619,21 @@ import CopyFile from "./CopyFile.vue";
}
},
500
)
}
loading
.
value
=
true
setTimeout
(()
=>
{
loading
.
value
=
false
},
300
)
watch
(()
=>
props
.
list
,
(
n
,
o
)
=>
{
loading
.
value
=
true
if
(
props
.
list
)
{
nextTick
(()
=>
{
dataList
.
value
=
props
.
list
setCurrentRow
()
})
}
setTimeout
(()
=>
{
loading
.
value
=
false
},
300
)
})
watch
(()
=>
props
.
navigations
,
(
n
,
o
)
=>
{
...
...
@@ -626,14 +646,14 @@ import CopyFile from "./CopyFile.vue";
padding
:
0
;
}
.journeyAds-Input
{
padding-right
:
20px
;
position
:
relative
;
margin-bottom
:
2px
;
::v-deep
(
.el-textarea__inner
)
{
padding
:
5px
;
background
:
#f5f5f5
;
}
}
padding-right
:
20px
;
position
:
relative
;
margin-bottom
:
2px
;
::v-deep
(
.el-textarea__inner
)
{
padding
:
5px
;
background
:
#f5f5f5
;
}
}
.el-table
{
height
:
100%
!
important
;
}
...
...
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