Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
P
patzn-cloud-web-back-soil
Overview
Overview
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
wangweidong
patzn-cloud-web-back-soil
Commits
b9679521
Commit
b9679521
authored
Jun 28, 2020
by
lichengming
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改了业务管理和合同管理的附件
parent
bacefce2
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
107 additions
and
62 deletions
+107
-62
meter-entrust.js
api/meter/meter-entrust.js
+11
-1
FileManageCont.vue
components/file/file-manage/FileManageCont.vue
+21
-19
FilesList.vue
components/file/file-manage/FilesList.vue
+63
-38
MeterContractAccepted.vue
pages/meter-business/accepted/MeterContractAccepted.vue
+3
-1
MeterContractApproval.vue
...s/meter-business/quote-approval/MeterContractApproval.vue
+3
-1
MeterContractCheckSecond.vue
...-business/quote-check-second/MeterContractCheckSecond.vue
+3
-1
MeterContractCheck.vue
pages/meter-business/quote-check/MeterContractCheck.vue
+3
-1
No files found.
api/meter/meter-entrust.js
View file @
b9679521
...
@@ -111,5 +111,15 @@ export default {
...
@@ -111,5 +111,15 @@ export default {
// 城市
// 城市
getCity
:
data
=>
http
.
post
(
'/base/v1/city/list_'
+
data
).
then
(
res
=>
res
),
getCity
:
data
=>
http
.
post
(
'/base/v1/city/list_'
+
data
).
then
(
res
=>
res
),
// 地区
// 地区
getArea
:
data
=>
http
.
post
(
'/base/v1/area/list_'
+
data
).
then
(
res
=>
res
)
getArea
:
data
=>
http
.
post
(
'/base/v1/area/list_'
+
data
).
then
(
res
=>
res
),
// 附件列表
attachmentPage
:
(
url
,
data
)
=>
http
.
post
(
url
,
data
).
then
(
res
=>
res
),
// 附件删除
attachmentDelete
:
(
url
,
data
)
=>
http
.
delete
(
url
+
data
).
then
(
res
=>
res
),
// 预览附件
attachmentPreview
:
data
=>
http
.
post
(
'/meter/v1/contract_attachment/preview/'
+
data
).
then
(
res
=>
res
),
// 委托附件预览
entrustPreview
:
data
=>
http
.
post
(
'/meter/v1/entrust_attachment/preview/'
+
data
).
then
(
res
=>
res
)
}
}
components/file/file-manage/FileManageCont.vue
View file @
b9679521
...
@@ -27,8 +27,8 @@
...
@@ -27,8 +27,8 @@
</
template
>
</
template
>
<
script
>
<
script
>
import
ModalConfirm
from
'../../base/ModalConfirm'
import
ModalConfirm
from
'../../base/ModalConfirm'
import
{
meterEntrust
}
from
'../../../api'
import
FilesList
from
'./FilesList'
import
FilesList
from
'./FilesList'
export
default
{
export
default
{
components
:
{
components
:
{
FilesList
,
FilesList
,
...
@@ -88,13 +88,13 @@ export default {
...
@@ -88,13 +88,13 @@ export default {
this
.
contractId
=
id
this
.
contractId
=
id
this
.
urlData
=
{
this
.
urlData
=
{
msg
:
'FoodContractAttachment'
,
msg
:
'FoodContractAttachment'
,
pageUrl
:
'
FoodContractA
ttachment/page'
,
pageUrl
:
'
/meter/v1/entrust_a
ttachment/page'
,
deleteUrl
:
'
FoodContractAttachment/deleteByIds
'
,
deleteUrl
:
'
/meter/v1/entrust_attachment/?ids=
'
,
uploadFileUrl
:
'/
food/v1/contract_attachment
/'
,
uploadFileUrl
:
'/
meter/v1/entrust_attachment/upload
/'
,
downloadFileUrl
:
'/
food/v1/contrac
t_attachment/download/'
,
downloadFileUrl
:
'/
meter/v1/entrus
t_attachment/download/'
,
downloadBatch
:
'/food/v1/contract_attachment/download_batch'
,
downloadBatch
:
'/food/v1/contract_attachment/download_batch'
,
uri
:
'FoodContractAttachment/getByContractId'
,
uri
:
'FoodContractAttachment/getByContractId'
,
viewUri
:
'/
food/v1/contract_attachment/view
'
viewUri
:
'/
meter/v1/entrust_attachment/preview/
'
}
}
break
break
case
'sampleId'
:
case
'sampleId'
:
...
@@ -116,10 +116,10 @@ export default {
...
@@ -116,10 +116,10 @@ export default {
this
.
subcontractorId
=
id
this
.
subcontractorId
=
id
this
.
urlData
=
{
this
.
urlData
=
{
msg
:
'FoodSubContractAttachment'
,
msg
:
'FoodSubContractAttachment'
,
pageUrl
:
'
FoodSubContractA
ttachment/page'
,
pageUrl
:
'
/meter/v1/contract_a
ttachment/page'
,
deleteUrl
:
'FoodSubContractAttachment/deleteByIds'
,
deleteUrl
:
'FoodSubContractAttachment/deleteByIds'
,
uploadFileUrl
:
'/
food/v1/subcontractor_attachment/upload_
'
,
uploadFileUrl
:
'/
meter/v1/contract_attachment/upload/
'
,
downloadFileUrl
:
'/
food/v1/subcontractor
_attachment/download/'
,
downloadFileUrl
:
'/
meter/v1/contract
_attachment/download/'
,
downloadBatch
:
'/food/v1/subcontractor_attachment/download_batch'
,
downloadBatch
:
'/food/v1/subcontractor_attachment/download_batch'
,
uri
:
'FoodSubContractAttachment/getBySubcontractorId'
,
uri
:
'FoodSubContractAttachment/getBySubcontractorId'
,
viewUri
:
'/food/v1/subcontractor_attachment/view'
viewUri
:
'/food/v1/subcontractor_attachment/view'
...
@@ -171,16 +171,18 @@ export default {
...
@@ -171,16 +171,18 @@ export default {
this
.
modalContent
=
'确定要删除这 '
+
ids
.
length
+
' 个附件?'
this
.
modalContent
=
'确定要删除这 '
+
ids
.
length
+
' 个附件?'
this
.
$refs
.
confirmModal
.
_openModal
()
this
.
$refs
.
confirmModal
.
_openModal
()
},
},
_delPage
(
data
)
{
_delPage
:
async
function
(
data
)
{
this
.
$store
.
dispatch
(
this
.
urlData
.
deleteUrl
,
data
).
then
(()
=>
{
console
.
log
(
data
)
const
status
=
this
.
$store
.
state
[
this
.
urlData
.
msg
].
success
const
result
=
await
meterEntrust
.
attachmentDelete
(
if
(
status
)
{
this
.
urlData
.
deleteUrl
,
this
.
$Message
.
success
(
'删除成功!'
)
data
.
id
this
.
$refs
.
fileModal
.
_page
()
)
}
if
(
result
)
{
this
.
$refs
.
confirmModal
.
_closeModal
()
this
.
$Message
.
success
(
'删除成功!'
)
this
.
deleteId
=
[]
this
.
$refs
.
fileModal
.
_page
()
})
}
this
.
$refs
.
confirmModal
.
_closeModal
()
this
.
deleteId
=
[]
},
},
// 删除提示框返回
// 删除提示框返回
_modalResult
(
msg
)
{
_modalResult
(
msg
)
{
...
...
components/file/file-manage/FilesList.vue
View file @
b9679521
...
@@ -59,7 +59,7 @@
...
@@ -59,7 +59,7 @@
fixed=
"right"
>
fixed=
"right"
>
<
template
slot-scope=
"scope"
>
<
template
slot-scope=
"scope"
>
<VXEIconList
<VXEIconList
:msg=
"
$fileFormat(scope.row.type,'img')?iconMsg:iconMsgDis
"
:msg=
"
iconMsg
"
@
on-result-change=
"_iconClick"
:rowData=
"scope.row"
></VXEIconList>
@
on-result-change=
"_iconClick"
:rowData=
"scope.row"
></VXEIconList>
</
template
>
</
template
>
</vxe-table-column>
</vxe-table-column>
...
@@ -68,7 +68,7 @@
...
@@ -68,7 +68,7 @@
<!--/-->
<!--/-->
<!--缩略图 模式-->
<!--缩略图 模式-->
<div
v-show=
"viewStyle === 2"
>
<div
v-show=
"viewStyle === 2"
>
<ul
:style=
"{ 'height':
tableHeight + 'px
' }"
class=
"thumbnailStyle"
>
<ul
:style=
"{ 'height':
'auto
' }"
class=
"thumbnailStyle"
>
<CheckboxGroup
@
on-change=
"_chkVal"
v-model=
"selectIds"
>
<CheckboxGroup
@
on-change=
"_chkVal"
v-model=
"selectIds"
>
<li
v-for=
"item in getPage.records"
:key=
"item.id"
>
<li
v-for=
"item in getPage.records"
:key=
"item.id"
>
<div
class=
"thumbnailStyleImg"
>
<div
class=
"thumbnailStyleImg"
>
...
@@ -91,7 +91,7 @@
...
@@ -91,7 +91,7 @@
<!--/-->
<!--/-->
<!--列表 模式-->
<!--列表 模式-->
<div
v-show=
"viewStyle === 3"
>
<div
v-show=
"viewStyle === 3"
>
<ul
:style=
"{ 'height':
tableHeight + 'px
' }"
class=
"listStyle"
>
<ul
:style=
"{ 'height':
'auto
' }"
class=
"listStyle"
>
<CheckboxGroup
@
on-change=
"_chkVal"
v-model=
"selectIds"
>
<CheckboxGroup
@
on-change=
"_chkVal"
v-model=
"selectIds"
>
<li
v-for=
"item in getPage.records"
:key=
"item.id"
>
<li
v-for=
"item in getPage.records"
:key=
"item.id"
>
<div
class=
"listStyleCheck clearCheck"
>
<div
class=
"listStyleCheck clearCheck"
>
...
@@ -133,7 +133,7 @@
...
@@ -133,7 +133,7 @@
<
script
>
<
script
>
import
VueGallerySlideshow
from
'vue-gallery-slideshow'
import
VueGallerySlideshow
from
'vue-gallery-slideshow'
import
global
from
'../../../api/config'
import
global
from
'../../../api/config'
import
{
meterEntrust
}
from
'../../../api'
/**
/**
* 公共组件modal 弹框(支持上传,下载,预览,删除附件等操作)
* 公共组件modal 弹框(支持上传,下载,预览,删除附件等操作)
*/
*/
...
@@ -147,9 +147,9 @@ export default {
...
@@ -147,9 +147,9 @@ export default {
imgViewList
:
[],
imgViewList
:
[],
imgViewIndex
:
null
,
imgViewIndex
:
null
,
iconMsg
:
[
iconMsg
:
[
{
type
:
'
trash-a
'
,
id
:
''
,
name
:
'删除'
},
{
type
:
'
ios-download
'
,
id
:
''
,
name
:
'删除'
},
{
type
:
'ios-download'
,
id
:
''
,
name
:
'下载'
},
{
type
:
'ios-download'
,
id
:
''
,
name
:
'下载'
},
{
type
:
'i
mages
'
,
id
:
''
,
name
:
'预览'
}
{
type
:
'i
os-download
'
,
id
:
''
,
name
:
'预览'
}
],
],
iconMsgDis
:
[
iconMsgDis
:
[
{
type
:
'trash-a'
,
id
:
''
,
name
:
'删除'
},
{
type
:
'trash-a'
,
id
:
''
,
name
:
'删除'
},
...
@@ -164,6 +164,7 @@ export default {
...
@@ -164,6 +164,7 @@ export default {
{
title
:
'上传时间'
,
key
:
'ctime'
,
width
:
140
,
dateTime
:
true
}
{
title
:
'上传时间'
,
key
:
'ctime'
,
width
:
140
,
dateTime
:
true
}
// {title: '上传人', key: 'cname', width: 120},
// {title: '上传人', key: 'cname', width: 120},
],
],
formObj
:
{},
viewVal
:
1
,
viewVal
:
1
,
viewStyle
:
1
,
viewStyle
:
1
,
menusList
:
[
menusList
:
[
...
@@ -211,11 +212,25 @@ export default {
...
@@ -211,11 +212,25 @@ export default {
// this._page()
// this._page()
// })
// })
},
},
_page
:
async
function
()
{
Object
.
assign
(
this
.
formObj
,
this
.
$refs
.
pageTable
.
_searchParams
())
const
result
=
await
meterEntrust
.
attachmentPage
(
this
.
urlData
.
pageUrl
,
this
.
formObj
)
if
(
result
)
{
this
.
$refs
.
pageTable
.
_hideLoading
()
this
.
getPage
=
result
}
},
// _page: async function() {
// _page: async function() {
// Object.assign(this.formObj, this.$refs.pageTable._searchParams())
// Object.assign(this.formObj, this.$refs.pageTable._searchParams())
// console.log('this.formObj', this.formObj)
// console.log('this.formObj', this.formObj)
// const result = await meterEntrust.pageSendEntrust(this.formObj)
// const result = await meterEntrust.attachmentPage(this.formObj)
// console.log('请求结果', result)
// if (result) {
// if (result) {
// console.log(result)
// this.$refs.pageTable._hideLoading()
// this.$refs.pageTable._hideLoading()
// this.getPage = result
// this.getPage = result
// }
// }
...
@@ -270,37 +285,47 @@ export default {
...
@@ -270,37 +285,47 @@ export default {
}
}
},
},
// 预览图片(该合同下所有的)
// 预览图片(该合同下所有的)
_viewImg
(
data
)
{
_viewImg
:
async
function
(
data
)
{
this
.
$store
.
dispatch
(
this
.
urlData
.
uri
,
this
.
id
).
then
(()
=>
{
if
(
this
.
urlData
.
viewUri
===
'/meter/v1/entrust_attachment/preview/'
)
{
const
viewUri
=
this
.
urlData
.
viewUri
const
id
=
data
.
entrustId
const
result
=
this
.
$store
.
state
[
this
.
urlData
.
msg
].
list
const
result
=
await
meterEntrust
.
entrustPreview
(
id
)
const
imgViewList
=
[]
console
.
log
(
result
)
for
(
let
i
=
0
;
i
<
result
.
length
;
i
++
)
{
}
else
{
imgViewList
.
push
(
const
id
=
data
.
contractId
global
.
baseURL
+
const
result
=
await
meterEntrust
.
attachmentPreview
(
id
)
viewUri
+
console
.
log
(
result
)
'?id='
+
}
result
[
i
].
id
+
'&objectKey='
+
// this.$store.dispatch(this.urlData.uri, this.id).then(() => {
result
[
i
].
objectKey
// const viewUri = this.urlData.viewUri
)
// const result = this.$store.state[this.urlData.msg].list
}
// const imgViewList = []
this
.
imgViewList
=
imgViewList
// for (let i = 0; i
<
result
.
length
;
i
++
)
{
// 打开的是当前第几张图片
// imgViewList.push(
const
salesUri
=
// global.baseURL +
global
.
baseURL
+
// viewUri +
viewUri
+
// '?id=' +
'?id='
+
// result[i].id +
data
.
id
+
// '&objectKey=' +
'&objectKey='
+
// result[i].objectKey
data
.
objectKey
// )
const
index
=
this
.
imgViewList
.
findIndex
(
item
=>
item
===
salesUri
)
// }
if
(
index
===
-
1
)
{
// this.imgViewList = imgViewList
this
.
imgViewIndex
=
0
// // 打开的是当前第几张图片
}
else
{
// const salesUri =
this
.
imgViewIndex
=
index
// global.baseURL +
}
// viewUri +
})
// '?id=' +
// data.id +
// '&objectKey=' +
// data.objectKey
// const index = this.imgViewList.findIndex(item => item === salesUri)
// if (index === -1) {
// this.imgViewIndex = 0
// } else {
// this.imgViewIndex = index
// }
// })
},
},
// 删除
// 删除
_deleteById
(
id
)
{
_deleteById
(
id
)
{
...
...
pages/meter-business/accepted/MeterContractAccepted.vue
View file @
b9679521
...
@@ -47,6 +47,7 @@
...
@@ -47,6 +47,7 @@
<MeterSampleManage
ref=
"meterSampleManageModal"
@
on-result-change=
"_page"
></MeterSampleManage>
<MeterSampleManage
ref=
"meterSampleManageModal"
@
on-result-change=
"_page"
></MeterSampleManage>
<MeterEntrustDetail
ref=
"meterSampleEdit"
@
on-result-change=
"_page"
></MeterEntrustDetail>
<MeterEntrustDetail
ref=
"meterSampleEdit"
@
on-result-change=
"_page"
></MeterEntrustDetail>
<Operation
ref=
"operation"
></Operation>
<Operation
ref=
"operation"
></Operation>
<FileManage
ref=
"FileManage"
></FileManage>
</div>
</div>
</template>
</template>
<
script
>
<
script
>
...
@@ -278,7 +279,8 @@ export default {
...
@@ -278,7 +279,8 @@ export default {
_upload
(
id
)
{
_upload
(
id
)
{
// 上传文件
// 上传文件
this
.
$refs
.
refModal
.
_open
(
id
,
'subcontractorId'
)
// this.$refs.refModal._open(id, 'subcontractorId')
this
.
$refs
.
FileManage
.
_open
(
id
,
'subcontractorId'
)
},
},
_getById
:
async
function
(
id
)
{
_getById
:
async
function
(
id
)
{
const
result
=
await
meterSubcontractor
.
getById
(
id
)
const
result
=
await
meterSubcontractor
.
getById
(
id
)
...
...
pages/meter-business/quote-approval/MeterContractApproval.vue
View file @
b9679521
...
@@ -48,6 +48,7 @@
...
@@ -48,6 +48,7 @@
<MeterSampleManage
ref=
"meterSampleManageModal"
@
on-result-change=
"_page"
></MeterSampleManage>
<MeterSampleManage
ref=
"meterSampleManageModal"
@
on-result-change=
"_page"
></MeterSampleManage>
<MeterEntrustDetail
ref=
"meterSampleEdit"
@
on-result-change=
"_page"
></MeterEntrustDetail>
<MeterEntrustDetail
ref=
"meterSampleEdit"
@
on-result-change=
"_page"
></MeterEntrustDetail>
<Operation
ref=
"operation"
></Operation>
<Operation
ref=
"operation"
></Operation>
<FileManage
ref=
"FileManage"
></FileManage>
</div>
</div>
</template>
</template>
<
script
>
<
script
>
...
@@ -289,7 +290,8 @@ export default {
...
@@ -289,7 +290,8 @@ export default {
_upload
(
id
)
{
_upload
(
id
)
{
// 上传文件
// 上传文件
this
.
$refs
.
refModal
.
_open
(
id
,
'subcontractorId'
)
this
.
$refs
.
FileManage
.
_open
(
id
,
'subcontractorId'
)
// this.$refs.refModal._open(id, 'subcontractorId')
},
},
_getById
:
async
function
(
id
)
{
_getById
:
async
function
(
id
)
{
const
result
=
await
meterSubcontractor
.
getById
(
id
)
const
result
=
await
meterSubcontractor
.
getById
(
id
)
...
...
pages/meter-business/quote-check-second/MeterContractCheckSecond.vue
View file @
b9679521
...
@@ -48,6 +48,7 @@
...
@@ -48,6 +48,7 @@
<MeterSampleManage
ref=
"meterSampleManageModal"
@
on-result-change=
"_page"
></MeterSampleManage>
<MeterSampleManage
ref=
"meterSampleManageModal"
@
on-result-change=
"_page"
></MeterSampleManage>
<MeterEntrustDetail
ref=
"meterSampleEdit"
@
on-result-change=
"_page"
></MeterEntrustDetail>
<MeterEntrustDetail
ref=
"meterSampleEdit"
@
on-result-change=
"_page"
></MeterEntrustDetail>
<Operation
ref=
"operation"
></Operation>
<Operation
ref=
"operation"
></Operation>
<FileManage
ref=
"FileManage"
></FileManage>
</div>
</div>
</template>
</template>
<
script
>
<
script
>
...
@@ -284,7 +285,8 @@ export default {
...
@@ -284,7 +285,8 @@ export default {
_upload
(
id
)
{
_upload
(
id
)
{
// 上传文件
// 上传文件
this
.
$refs
.
refModal
.
_open
(
id
,
'subcontractorId'
)
this
.
$refs
.
FileManage
.
_open
(
id
,
'subcontractorId'
)
// this.$refs.refModal._open(id, 'subcontractorId')
},
},
_getById
:
async
function
(
id
)
{
_getById
:
async
function
(
id
)
{
const
result
=
await
meterSubcontractor
.
getById
(
id
)
const
result
=
await
meterSubcontractor
.
getById
(
id
)
...
...
pages/meter-business/quote-check/MeterContractCheck.vue
View file @
b9679521
...
@@ -44,6 +44,7 @@
...
@@ -44,6 +44,7 @@
</Row>
</Row>
</div>
</div>
</div>
</div>
<FileManage
ref=
"FileManage"
></FileManage>
<Reason
ref=
"reasonModal"
@
on-result-change=
"_reasonResult"
></Reason>
<Reason
ref=
"reasonModal"
@
on-result-change=
"_reasonResult"
></Reason>
<MeterSampleManage
ref=
"meterSampleManageModal"
@
on-result-change=
"_page"
></MeterSampleManage>
<MeterSampleManage
ref=
"meterSampleManageModal"
@
on-result-change=
"_page"
></MeterSampleManage>
<MeterEntrustDetail
ref=
"meterSampleEdit"
@
on-result-change=
"_page"
></MeterEntrustDetail>
<MeterEntrustDetail
ref=
"meterSampleEdit"
@
on-result-change=
"_page"
></MeterEntrustDetail>
...
@@ -292,7 +293,8 @@ export default {
...
@@ -292,7 +293,8 @@ export default {
_upload
(
id
)
{
_upload
(
id
)
{
// 上传文件
// 上传文件
this
.
$refs
.
refModal
.
_open
(
id
,
'subcontractorId'
)
this
.
$refs
.
FileManage
.
_open
(
id
,
'subcontractorId'
)
// this.$refs.refModal._open(id, 'subcontractorId')
},
},
_getById
:
async
function
(
id
)
{
_getById
:
async
function
(
id
)
{
const
result
=
await
meterSubcontractor
.
getById
(
id
)
const
result
=
await
meterSubcontractor
.
getById
(
id
)
...
...
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