Commit 3dd2c2d8 by lichengming

修改了报告签发

parent 8b2426ef
...@@ -108,5 +108,20 @@ export default { ...@@ -108,5 +108,20 @@ export default {
'&reason=' + '&reason=' +
data.remark data.remark
) )
.then(res => res),
// 报告签发提交
reportIssueSubmit: data =>
http
.post('soil/v1/entrust/report_issue_submit?ids=' + data)
.then(res => res),
// 报告签发退回
reportIssueBack: data =>
http
.post(
'soil/v1/entrust/report_issue_back?ids=' +
data.ids +
'&reason=' +
data.remark
)
.then(res => res) .then(res => res)
} }
...@@ -72,8 +72,8 @@ ...@@ -72,8 +72,8 @@
sortable sortable
> >
<template slot-scope="scope" @click.stop="_handleIndex(scope)"> <template slot-scope="scope" @click.stop="_handleIndex(scope)">
<span v-if="item.datetime"> <span v-if="item.date">
{{ scope.row[item.key]?$dateformat(scope.row[item.key],'yyyy-mm-dd HH:MM:ss'):'' }} {{ scope.row[item.key]?$dateformat(scope.row[item.key],'yyyy-mm-dd'):'' }}
</span> </span>
<div v-else-if="item.status"> <div v-else-if="item.status">
{{ scope.row[item.key] === undefined ? '': scope.row[item.key].display }} {{ scope.row[item.key] === undefined ? '': scope.row[item.key].display }}
...@@ -94,7 +94,7 @@ ...@@ -94,7 +94,7 @@
<script> <script>
// eslint-disable-next-line import/named // eslint-disable-next-line import/named
import { soilStatistics } from '../../../../api' import { soilSample, soilStatistics } from '../../../../api'
import global from '../../../../api/config' import global from '../../../../api/config'
import Reason from '../../../../components/base/Reason' import Reason from '../../../../components/base/Reason'
import OperationModal from '../../../../components/operation/Operation' import OperationModal from '../../../../components/operation/Operation'
...@@ -105,17 +105,22 @@ export default { ...@@ -105,17 +105,22 @@ export default {
return { return {
name: '', name: '',
pageColumns: [ pageColumns: [
{ title: '委托方', key: 'client', width: 200 }, {
{ title: '联系人', key: 'person', width: 120 }, title: '委托商',
{ title: '委托编号', key: 'entrustCode', width: 120 }, key: 'client',
{ title: '报告是否生成', key: 'reported', width: 120 }, width: 180,
{ title: '状态', key: 'progress', width: 120, status: true }, fixed: 'left'
{ title: '电话/手机', key: 'tel', width: 120 }, },
{ title: '传真', key: 'fax', width: 120 }, { title: '委托编号', key: 'entrustCode', width: 180 },
{ title: '详细地址', key: 'address', width: 250 }, { title: '报告编号', key: 'reportCode', width: 180 },
{ title: '邮箱', key: 'email' }, { title: '状态', key: 'status', width: 110, status: true },
{ title: '费用合计', key: 'fee', width: 120 }, { title: '委托日期', key: 'entrustDate', width: 180, date: true },
{ title: '备注', key: 'remark' } { title: '进度', key: 'progress', width: 110, status: true },
{ title: '钻孔位置', key: 'boreholeLocation', width: 180 },
{ title: '钻孔名称', key: 'boreholeName', width: 180 },
{ title: '水深', key: 'waterDepth', width: 180 },
{ title: '制表人', key: 'tabulater', width: 110 },
{ title: '制表日期', key: 'tabulateDate', width: 110, date: true }
], ],
btn: [ btn: [
{ id: '', type: 'primary', name: '提交' }, { id: '', type: 'primary', name: '提交' },
...@@ -128,9 +133,9 @@ export default { ...@@ -128,9 +133,9 @@ export default {
selectIds: [], selectIds: [],
selectData: [], selectData: [],
iconMsg: [ iconMsg: [
{ id: '', type: 'pt-a-view', name: '预览报告' }, { id: '', type: 'md-image', name: '预览报告' },
{ id: '', type: 'pt-a-cloud', name: '附件' }, { id: '', type: 'ios-cloud', name: '附件' },
{ id: '', type: 'pt-a-clock', name: '操作日志' } { id: '', type: 'ios-clock', name: '操作日志' }
] ]
} }
}, },
...@@ -223,7 +228,7 @@ export default { ...@@ -223,7 +228,7 @@ export default {
} }
}, },
_reportCheckBack: async function(data) { _reportCheckBack: async function(data) {
const result = await soilStatistics.entrustReportIssueBack({ const result = await soilSample.reportIssueBack({
ids: this.selectIds, ids: this.selectIds,
remark: data remark: data
}) })
...@@ -269,7 +274,7 @@ export default { ...@@ -269,7 +274,7 @@ export default {
// 接口异步 // 接口异步
_submit: async function(ids) { _submit: async function(ids) {
if (ids.length === 0) return false if (ids.length === 0) return false
const result = await soilStatistics.submitEntrustReportIssue(ids) const result = await soilSample.reportIssueSubmit(ids)
if (result) { if (result) {
this.$Message.success('提交成功!') this.$Message.success('提交成功!')
this._formSearch() this._formSearch()
...@@ -336,12 +341,13 @@ export default { ...@@ -336,12 +341,13 @@ export default {
this.$refs.operationModal._open(id) this.$refs.operationModal._open(id)
}, },
_getObjectKey: async function(data) { _getObjectKey: async function(data) {
const result = await soilStatistics.getObjectKey(data.id) const result = await soilSample.getReport(data.id)
if (result) { if (result) {
this.$openWindowModeless({ this.$openWindowModeless({
objectKey: result, objectKey: result.objectKey,
id: data.id, id: data.id,
isReport: 0 isReport: 4,
idType: 11
}) })
} }
}, },
...@@ -389,6 +395,9 @@ export default { ...@@ -389,6 +395,9 @@ export default {
this.selectIds.push(this.selectData[i].id) this.selectIds.push(this.selectData[i].id)
} }
break break
case 'iconClick':
this._iconClick(data.name, data.rowData, data.componentName)
break
default: default:
this._page() this._page()
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment