Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
meet
Project
Project
Details
Activity
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
wangqinghua
meet
Commits
5422a72c
Commit
5422a72c
authored
Apr 15, 2019
by
wangqinghua
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
quiet2
parent
d509cc9b
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
34 additions
and
26 deletions
+34
-26
api.js
src/api/api.js
+3
-0
http.js
src/http.js/http.js
+4
-2
meetList.vue
src/views/meetList.vue
+24
-22
quiet2.vue
src/views/quiet2.vue
+3
-2
No files found.
src/api/api.js
View file @
5422a72c
...
...
@@ -87,6 +87,9 @@ export const removeIntentionById = params =>req('get','/intention/removeIntenti
//下载文件
export
const
downloadFile
=
params
=>
req
(
'get'
,
'/common/file/download'
,
params
);
//下载
export
const
preDownloadFile
=
params
=>
req
(
'get'
,
'/common/file/pre/download'
,
params
);
...
...
src/http.js/http.js
View file @
5422a72c
...
...
@@ -4,10 +4,12 @@ import * as types from '../store/types';
import
router
from
'../router'
;
import
{
Message
}
from
'element-ui'
;
export
const
domin
=
'/api'
//本地环境
// export const domin = '' //生产环境
//axios配置
let
instance
=
axios
.
create
({
//
baseURL:'/api',
baseURL
:
'http://172.19.1.232:8085'
,
baseURL
:
'/api'
,
//
baseURL:'http://172.19.1.232:8085',
// timeout:20000,
});
...
...
src/views/meetList.vue
View file @
5422a72c
...
...
@@ -33,7 +33,7 @@
label=
"会议名称"
width=
"180"
>
<template
slot-scope=
"scope"
>
<span
@
click=
"handleEdit(scope.row)"
class=
"pointer"
>
<span
@
click=
"handleEdit(scope.row)"
class=
"pointer"
>
{{
scope
.
row
.
title
}}
</span>
</
template
>
...
...
@@ -57,8 +57,10 @@
<span
class=
"font-size-20 pointer"
>
<i
@
click=
"handleEdit(scope.row)"
class=
"el-icon-edit-outline margin-right-20"
></i>
<i
@
click=
"handleDelete(scope.row)"
class=
"el-icon-delete margin-right-20"
></i>
<i
title=
"离线缓存"
@
click=
"downloadData(scope.row)"
class=
"el-icon-download margin-right-20"
></i>
<i
v-if=
"scope.row.preview === true"
title=
"预览"
@
click=
"previewMeet(scope.row)"
class=
"el-icon-more"
></i>
<i
title=
"离线缓存"
@
click=
"downloadData(scope.row)"
class=
"el-icon-download margin-right-20"
></i>
<i
v-if=
"scope.row.preview === true"
title=
"预览"
@
click=
"previewMeet(scope.row)"
class=
"el-icon-more"
></i>
</span>
</
template
>
</el-table-column>
...
...
@@ -79,15 +81,16 @@
</template>
<
script
>
import
{
getMeetingPage
,
removeMeetingById
,
getMeetingById
}
from
'../api/api'
import
{
getMeetingPage
,
removeMeetingById
,
preDownloadFile
}
from
'../api/api'
import
{
formatDate
}
from
"../common/date"
;
import
{
domin
}
from
"../http.js/http"
;
export
default
{
name
:
"meet-list"
,
data
()
{
return
{
currentPage
:
1
,
total
:
null
,
total
:
null
,
form
:
{
pageNo
:
'1'
,
pageSize
:
'10'
,
...
...
@@ -124,7 +127,7 @@
this
.
getList
()
},
//新增会议
handleAdd
(){
handleAdd
()
{
this
.
$router
.
push
({
path
:
'/meetManage'
,
...
...
@@ -144,8 +147,8 @@
cancelButtonText
:
'取消'
,
type
:
'warning'
}).
then
(()
=>
{
removeMeetingById
({
id
:
row
.
id
}).
then
(
(
res
)
=>
{
removeMeetingById
({
id
:
row
.
id
}).
then
(
(
res
)
=>
{
this
.
getList
()
this
.
$message
.
success
(
"删除成功"
)
}
...
...
@@ -153,19 +156,18 @@
})
},
//缓存数据
downloadData
(
row
){
row
.
preview
=
true
console
.
log
(
this
.
tableData
)
getMeetingById
({
id
:
row
.
id
}).
then
(
(
res
)
=>
{
this
.
meet
=
res
.
data
let
data
=
JSON
.
stringify
(
this
.
meet
)
localStorage
.
setItem
(
row
.
id
,
data
)
}
)
downloadData
(
row
)
{
let
url
=
domin
+
'/common/file/pre/download?id='
+
row
.
id
console
.
log
(
url
)
let
link
=
document
.
createElement
(
"a"
);
link
.
setAttribute
(
"href"
,
url
);
link
.
setAttribute
(
"download"
,
'组织部.zip'
);
document
.
body
.
appendChild
(
link
);
link
.
click
();
document
.
body
.
removeChild
(
link
);
},
//预览
previewMeet
(
row
){
previewMeet
(
row
)
{
let
newpage
=
this
.
$router
.
resolve
({
name
:
'viewFile'
,
query
:
{
previewId
:
row
.
id
}
...
...
@@ -173,10 +175,10 @@
window
.
open
(
newpage
.
href
,
'_blank'
);
}
},
filters
:{
formatDate
(
time
){
filters
:
{
formatDate
(
time
)
{
let
date
=
new
Date
(
time
);
return
formatDate
(
date
,
'yyyy-MM-dd hh:mm'
);
return
formatDate
(
date
,
'yyyy-MM-dd hh:mm'
);
}
}
...
...
src/views/quiet2.vue
View file @
5422a72c
...
...
@@ -80,6 +80,7 @@
<
script
>
import
{
getMeetingById
,
downloadFile
}
from
'../api/api'
import
{
formatDate
}
from
"../common/date"
;
import
{
domin
}
from
"../http.js/http"
;
import
pdf
from
'vue-pdf'
import
*
as
types
from
'../store/types'
...
...
@@ -142,9 +143,9 @@
let
url
if
(
name
.
saveName
.
includes
(
'.doc'
)
||
name
.
saveName
.
includes
(
'.docx'
))
{
const
fileName
=
name
.
saveName
.
split
(
'.doc'
)[
0
]
+
'.pdf'
url
=
'/api
/common/file/download?fileName='
+
fileName
url
=
domin
+
'
/common/file/download?fileName='
+
fileName
}
else
{
url
=
'/api
/common/file/download?fileName='
+
name
.
saveName
url
=
domin
+
'
/common/file/download?fileName='
+
name
.
saveName
}
this
.
src
=
pdf
.
createLoadingTask
(
url
)
...
...
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