
30 changed files with 4322 additions and 578 deletions
@ -0,0 +1,115 @@ |
|||||
|
import request from '@/utils/request' |
||||
|
|
||||
|
export default { |
||||
|
// 查询分页列表
|
||||
|
listPage: function(params) { |
||||
|
return request({ |
||||
|
url: '/as/v1/asserviceitemapply/listPage', |
||||
|
method: 'post', |
||||
|
data: params, |
||||
|
headers: { 'Content-Type': 'application/json' } |
||||
|
}) |
||||
|
}, |
||||
|
// 初始化
|
||||
|
init: function(data) { |
||||
|
return request({ |
||||
|
url: '/as/v1/asserviceitemapply/applyInit', |
||||
|
method: 'post', |
||||
|
data: data, |
||||
|
headers: { 'Content-Type': 'application/json' } |
||||
|
}) |
||||
|
}, |
||||
|
// 回显
|
||||
|
fetchDetailsBySid: function(data) { |
||||
|
return request({ |
||||
|
url: '/as/v1/asserviceitemapply/fetchDetailsBySid/' + data, |
||||
|
method: 'get' |
||||
|
}) |
||||
|
}, |
||||
|
saveOrUpdate: function(data) { |
||||
|
return request({ |
||||
|
url: '/as/v1/asserviceitemapply/save', |
||||
|
method: 'post', |
||||
|
data: data, |
||||
|
headers: { 'Content-Type': 'application/json' } |
||||
|
}) |
||||
|
}, |
||||
|
deleteBySids: function(data) { |
||||
|
return request({ |
||||
|
url: '/as/v1/asserviceitemapply/delBySids', |
||||
|
method: 'DELETE', |
||||
|
data: data, |
||||
|
headers: { 'Content-Type': 'application/json' } |
||||
|
}) |
||||
|
}, |
||||
|
// 提交流程
|
||||
|
submit: function(params) { |
||||
|
return request({ |
||||
|
url: '/as/v1/asserviceitemapply/submitApply', |
||||
|
method: 'post', |
||||
|
data: params, |
||||
|
headers: { 'Content-Type': 'application/json' } |
||||
|
}) |
||||
|
}, |
||||
|
// 流程审批(同意)
|
||||
|
complete: function(params) { |
||||
|
return request({ |
||||
|
url: '/as/v1/asserviceitemapply/complete', |
||||
|
method: 'post', |
||||
|
data: params, |
||||
|
headers: { 'Content-Type': 'application/json' } |
||||
|
}) |
||||
|
}, |
||||
|
// 流程审批(加签)
|
||||
|
delegate: function(params) { |
||||
|
return request({ |
||||
|
url: '/as/v1/asserviceitemapply/delegate', |
||||
|
method: 'post', |
||||
|
data: params, |
||||
|
headers: { 'Content-Type': 'application/json' } |
||||
|
}) |
||||
|
}, |
||||
|
// 流程审批(驳回)
|
||||
|
reject: function(params) { |
||||
|
return request({ |
||||
|
url: '/as/v1/asserviceitemapply/reject', |
||||
|
method: 'post', |
||||
|
data: params, |
||||
|
headers: { 'Content-Type': 'application/json' } |
||||
|
}) |
||||
|
}, |
||||
|
// 流程审批(终止)
|
||||
|
breakProcess: function(params) { |
||||
|
return request({ |
||||
|
url: '/as/v1/asserviceitemapply/breakProcess', |
||||
|
method: 'post', |
||||
|
data: params, |
||||
|
headers: { 'Content-Type': 'application/json' } |
||||
|
}) |
||||
|
}, |
||||
|
// 流程审批(撤回)
|
||||
|
revokeProcess: function(params) { |
||||
|
return request({ |
||||
|
url: '/as/v1/asserviceitemapply/revokeProcess', |
||||
|
method: 'post', |
||||
|
data: params, |
||||
|
headers: { 'Content-Type': 'application/json' } |
||||
|
}) |
||||
|
}, |
||||
|
// 审批流程(同意)获取下一环节
|
||||
|
getNextNodesForSubmit: function(data) { |
||||
|
return request({ |
||||
|
url: '/as/v1/asserviceitemapply/getNextNodesForSubmit', |
||||
|
method: 'get', |
||||
|
params: data |
||||
|
}) |
||||
|
}, |
||||
|
// 审批流程(驳回)获取上一环节
|
||||
|
getPreviousNodesForReject: function(data) { |
||||
|
return request({ |
||||
|
url: '/as/v1/asserviceitemapply/getPreviousNodesForReject', |
||||
|
method: 'get', |
||||
|
params: data |
||||
|
}) |
||||
|
} |
||||
|
} |
@ -1,49 +0,0 @@ |
|||||
import request from '@/utils/request' |
|
||||
|
|
||||
export default { |
|
||||
|
|
||||
// 选择工单初始化数据
|
|
||||
initBill: function(data) { |
|
||||
return request({ |
|
||||
url: '/as/v1/AsBusrepairInventorybill/init', |
|
||||
method: 'get', |
|
||||
params: data |
|
||||
}); |
|
||||
}, |
|
||||
|
|
||||
|
|
||||
// 查询分页列表
|
|
||||
getGoodsListPage: function(params) { |
|
||||
return request({ |
|
||||
url: '/wms/apiadmin/WmsOutBill/getInventoryList', |
|
||||
method: 'post', |
|
||||
data: params, |
|
||||
headers: { |
|
||||
'Content-Type': 'application/json' |
|
||||
} |
|
||||
}) |
|
||||
}, |
|
||||
|
|
||||
// 新增、保存
|
|
||||
saveBill: function(data) { |
|
||||
return request({ |
|
||||
url: '/as/v1/AsBusrepairInventorybill/quitBill', |
|
||||
method: 'post', |
|
||||
data: data, |
|
||||
headers: { |
|
||||
'Content-Type': 'application/json' |
|
||||
} |
|
||||
}); |
|
||||
}, |
|
||||
|
|
||||
|
|
||||
// 详情
|
|
||||
detailsBill: function(data) { |
|
||||
return request({ |
|
||||
url: '/as/v1/AsBusrepairInventorybill/details', |
|
||||
method: 'get', |
|
||||
params: data |
|
||||
}); |
|
||||
}, |
|
||||
|
|
||||
} |
|
@ -0,0 +1,326 @@ |
|||||
|
<template> |
||||
|
<div class="app-container"> |
||||
|
<!--列表页面--> |
||||
|
<div v-show="viewState == 1"> |
||||
|
<button-bar view-title="维修项目备案管理" ref="btnbar" :btndisabled="btndisabled" @btnhandle="btnHandle"/> |
||||
|
<!--Start查询列表部分--> |
||||
|
<div class="main-content"> |
||||
|
<div class="searchcon"> |
||||
|
<el-button size="small" class="searchbtn" @click="clicksearchShow">{{ searchxianshitit }}</el-button> |
||||
|
<div v-show="isSearchShow" class="search"> |
||||
|
<el-form ref="listQueryform" :inline="true" :model="listQuery" label-width="100px" class="tab-header"> |
||||
|
<el-form-item label="分公司"> |
||||
|
<el-input v-model="listQuery.params.useOrgName" placeholder="" clearable/> |
||||
|
</el-form-item> |
||||
|
<el-form-item label="申请部门"> |
||||
|
<el-input v-model="listQuery.params.deptName" placeholder="" clearable/> |
||||
|
</el-form-item> |
||||
|
<el-form-item label="申请人"> |
||||
|
<el-input v-model="listQuery.params.createByName" placeholder="" clearable/> |
||||
|
</el-form-item> |
||||
|
<el-form-item label="单据编号"> |
||||
|
<el-input v-model="listQuery.params.billNo" placeholder="" clearable/> |
||||
|
</el-form-item> |
||||
|
<el-form-item label="申请日期"> |
||||
|
<el-date-picker v-model="listQuery.params.createDateStart" value-format="yyyy-MM-dd" format="yyyy-MM-dd" type="date" placeholder="选择日期"></el-date-picker> |
||||
|
<span style="padding: 0 8px">至</span> |
||||
|
<el-date-picker v-model="listQuery.params.createDateEnd" value-format="yyyy-MM-dd" format="yyyy-MM-dd" type="date" placeholder="选择日期"></el-date-picker> |
||||
|
</el-form-item> |
||||
|
<el-form-item label="办结日期"> |
||||
|
<el-date-picker v-model="listQuery.params.closingDateEnd" value-format="yyyy-MM-dd" format="yyyy-MM-dd" type="date" placeholder="选择日期"></el-date-picker> |
||||
|
<span style="padding: 0 8px">至</span> |
||||
|
<el-date-picker v-model="listQuery.params.closingDateStart" value-format="yyyy-MM-dd" format="yyyy-MM-dd" type="date" placeholder="选择日期"></el-date-picker> |
||||
|
</el-form-item> |
||||
|
</el-form> |
||||
|
<div class="btn" style="text-align: center;"> |
||||
|
<el-button type="primary" icon="el-icon-search" size="small" @click="handleFilter">查询</el-button> |
||||
|
<el-button type="primary" icon="el-icon-refresh" size="small" @click="handleReset">重置</el-button> |
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
<!--End查询列表部分--> |
||||
|
<div class="listtop"> |
||||
|
<div class="tit">维修项目备案申请列表</div> |
||||
|
<pageye v-show="list.length > 0" :total="listQuery.total" :page.sync="listQuery.current" :limit.sync="listQuery.size" class="pagination" @pagination="getList"/> |
||||
|
</div> |
||||
|
<!--Start 主页面主要部分 --> |
||||
|
<div class=""> |
||||
|
<el-table :key="tableKey" v-loading="listLoading" :data="list" :border="true" style="width: 100%;" @selection-change="handleSelectionChange"> |
||||
|
<el-table-column type="selection" align="center" width="50" /> |
||||
|
<el-table-column label="序号" type="index" width="80" :index="indexMethod" align="center" /> |
||||
|
<el-table-column label="操作" width="180" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
<el-button type="primary" size="mini" @click="toEdit(scope.row)" :disabled="scope.row.nodeState =='发起申请' ? false : scope.row.nodeState == '待提交' ? false : true">办理</el-button> |
||||
|
<el-button type="primary" size="mini" @click="toInfo(scope.row)">查看</el-button> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="流程状态" width="180" header-align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span v-if="scope.row.nodeState=='待提交'" type="primary" size="mini">待提交</span> |
||||
|
<span v-else @click="flowRecord(scope.row)" class="bluezi">{{ scope.row.nodeState }}</span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column prop="billNo" label="单据编号" align="center" width="180" /> |
||||
|
<el-table-column prop="useOrgName" label="分公司" align="center" min-width="120" /> |
||||
|
<el-table-column prop="deptName" label="申请部门" align="center" min-width="120" /> |
||||
|
<el-table-column prop="createByName" label="申请人" align="center" width="120" /> |
||||
|
<el-table-column prop="createTime" label="申请日期" align="center" width="120" /> |
||||
|
<el-table-column prop="closingDate" label="办结日期" align="center" width="120" /> |
||||
|
</el-table> |
||||
|
</div> |
||||
|
<!--End 主页面主要部分--> |
||||
|
<div class="pages"> |
||||
|
<div class="tit"/> |
||||
|
<!-- 翻页 --> |
||||
|
<pagination v-show="list.length > 0" :total="listQuery.total" :page.sync="listQuery.current" :limit.sync="listQuery.size" class="pagination" @pagination="getList"/> |
||||
|
</div> |
||||
|
<!--End查询列表部分--> |
||||
|
</div> |
||||
|
</div> |
||||
|
<!--新增及修改 --> |
||||
|
<maintenanceProjectRecordAdd v-show="viewState == 2 || viewState == 3" ref="divAdd" @doback="resetState" @reloadlist="getList" /> |
||||
|
<!-- 详情 --> |
||||
|
<maintenanceProjectRecordInfo v-show="viewState == 4" ref="divInfo" @doback="resetState" /> |
||||
|
<!-- 流程审批记录 --> |
||||
|
<el-dialog title="" :visible.sync="centerDialogVisible" width="78%" height="1%" :before-close="closeIt" center> |
||||
|
<iframe frameborder="0" id="iframe" style="width:100%;" scrolling="no" :src="this.centerDialogVisible === true ? url :''"></iframe> |
||||
|
</el-dialog> |
||||
|
</div> |
||||
|
</template> |
||||
|
|
||||
|
<script> |
||||
|
import Pagination from '@/components/pagination' |
||||
|
import pageye from '@/components/pagination/pageye' |
||||
|
import ButtonBar from '@/components/ButtonBar' |
||||
|
import req from '@/api/basicinformation/maintenanceProjectRecord' |
||||
|
import { getStorage } from '@/utils/auth' |
||||
|
import maintenanceProjectRecordAdd from './maintenanceProjectRecordAdd' |
||||
|
import maintenanceProjectRecordInfo from './maintenanceProjectRecordInfo' |
||||
|
|
||||
|
export default { |
||||
|
name: 'MaintenanceProjectRecord', |
||||
|
components: { |
||||
|
Pagination, |
||||
|
pageye, |
||||
|
ButtonBar, |
||||
|
maintenanceProjectRecordAdd, |
||||
|
maintenanceProjectRecordInfo |
||||
|
}, |
||||
|
data() { |
||||
|
return { |
||||
|
url: '', |
||||
|
dialogHeight: '80%', |
||||
|
centerDialogVisible: false, |
||||
|
btndisabled: false, |
||||
|
btnList: [ |
||||
|
{ |
||||
|
type: 'danger', |
||||
|
size: 'small', |
||||
|
icon: 'del', |
||||
|
btnKey: 'doDel', |
||||
|
btnLabel: '删除' |
||||
|
}, |
||||
|
{ |
||||
|
type: 'info', |
||||
|
size: 'small', |
||||
|
icon: 'cross', |
||||
|
btnKey: 'doClose', |
||||
|
btnLabel: '关闭' |
||||
|
} |
||||
|
], |
||||
|
isSearchShow: false, |
||||
|
searchxianshitit: '显示查询条件', |
||||
|
viewState: 1, // 1、列表 2、新增 3、编辑 4、查看 |
||||
|
tableKey: 0, |
||||
|
list: [], |
||||
|
sids: [], // 用于导出的时候保存已选择的SIDs |
||||
|
FormLoading: false, |
||||
|
listLoading: false, |
||||
|
// 翻页 |
||||
|
listQuery: { |
||||
|
current: 1, |
||||
|
size: 5, |
||||
|
total: 0, |
||||
|
params: { |
||||
|
billNo: '', |
||||
|
closingDateEnd: '', |
||||
|
closingDateStart: '', |
||||
|
createByName: '', |
||||
|
createDateEnd: '', |
||||
|
createDateStart: '', |
||||
|
deptName: '', |
||||
|
menuUrl: '', |
||||
|
orgPath: '', |
||||
|
useOrgName: '', |
||||
|
userSid: '' |
||||
|
} |
||||
|
} |
||||
|
} |
||||
|
}, |
||||
|
created() { |
||||
|
// 初始化变量 |
||||
|
this.getList() |
||||
|
}, |
||||
|
mounted() { |
||||
|
// 在外部vue的window上添加postMessage的监听,而且绑定处理函数handleMessage |
||||
|
window.addEventListener('message', this.handleMessage) |
||||
|
this.$refs['btnbar'].setButtonList(this.btnList) |
||||
|
}, |
||||
|
methods: { |
||||
|
async handleMessage(event) { |
||||
|
var code = '' |
||||
|
if (event.data.params !== null && event.data.params !== undefined) { |
||||
|
code = event.data.params.code |
||||
|
} |
||||
|
if (code === 1) { |
||||
|
this.centerDialogVisible = false |
||||
|
} else if (code === 2) { |
||||
|
this.dialogHeight = event.data.params.data |
||||
|
this.setIframeHeight(document.getElementById('iframe')) |
||||
|
} |
||||
|
}, |
||||
|
closeIt() { |
||||
|
this.url = '' |
||||
|
this.centerDialogVisible = false |
||||
|
}, |
||||
|
setIframeHeight(iframe) { |
||||
|
iframe.height = this.dialogHeight |
||||
|
}, |
||||
|
flowRecord(row) { |
||||
|
this.centerDialogVisible = true |
||||
|
var params = { |
||||
|
deployId: row.procDefId, |
||||
|
procInsId: row.procInstId, |
||||
|
token: getStorage() |
||||
|
} |
||||
|
this.url = '/#/flow/flowRecordForBusiness?data=' + encodeURI((JSON.stringify(params))) |
||||
|
}, |
||||
|
// 搜索条件效果 |
||||
|
clicksearchShow() { |
||||
|
this.isSearchShow = !this.isSearchShow |
||||
|
if (this.isSearchShow) { |
||||
|
this.searchxianshitit = '隐藏查询条件' |
||||
|
} else { |
||||
|
this.searchxianshitit = '显示查询条件' |
||||
|
} |
||||
|
}, |
||||
|
btnHandle(btnKey) { |
||||
|
console.log('XXXXXXXXXXXXXXX ' + btnKey) |
||||
|
switch (btnKey) { |
||||
|
case 'doDel': |
||||
|
this.doDel() |
||||
|
break |
||||
|
case 'doClose': |
||||
|
this.doClose() |
||||
|
break |
||||
|
default: |
||||
|
break |
||||
|
} |
||||
|
}, |
||||
|
// 信息条数 获取点击时当前的sid |
||||
|
handleSelectionChange(row) { |
||||
|
const aa = [] |
||||
|
row.forEach(element => { |
||||
|
aa.push(element.sid) |
||||
|
}) |
||||
|
this.sids = aa |
||||
|
}, |
||||
|
// 表中序号 |
||||
|
indexMethod(index) { |
||||
|
var pagestart = (this.listQuery.current - 1) * this.listQuery.size |
||||
|
var pageindex = index + 1 + pagestart |
||||
|
return pageindex |
||||
|
}, |
||||
|
// 查询列表信息 |
||||
|
getList() { |
||||
|
this.listLoading = true |
||||
|
this.listQuery.params.createBySid = window.sessionStorage.getItem('userSid') |
||||
|
this.listQuery.params.orgPath = window.sessionStorage.getItem('defaultOrgPath') |
||||
|
req.listPage(this.listQuery).then((response) => { |
||||
|
this.listLoading = false |
||||
|
if (response.success) { |
||||
|
this.list = response.data.records |
||||
|
this.listQuery.total = response.data.total |
||||
|
} else { |
||||
|
this.list = [] |
||||
|
this.listQuery.total = 0 |
||||
|
} |
||||
|
}) |
||||
|
}, |
||||
|
// 查询按钮 |
||||
|
handleFilter() { |
||||
|
this.listQuery.current = 1 |
||||
|
this.getList() |
||||
|
}, |
||||
|
// 点击重置 |
||||
|
handleReset() { |
||||
|
this.listQuery = { |
||||
|
current: 1, |
||||
|
size: 5, |
||||
|
total: 0, |
||||
|
params: { |
||||
|
billNo: '', |
||||
|
closingDateEnd: '', |
||||
|
closingDateStart: '', |
||||
|
createByName: '', |
||||
|
createDateEnd: '', |
||||
|
createDateStart: '', |
||||
|
deptName: '', |
||||
|
menuUrl: '', |
||||
|
orgPath: '', |
||||
|
useOrgName: '', |
||||
|
userSid: '' |
||||
|
} |
||||
|
} |
||||
|
this.getList() |
||||
|
}, |
||||
|
toEdit(row) { |
||||
|
this.viewState = 3 |
||||
|
this.$refs['divAdd'].showEdit(row) |
||||
|
}, |
||||
|
toInfo(row) { |
||||
|
this.viewState = 4 |
||||
|
this.$refs['divInfo'].showInfo(row) |
||||
|
}, |
||||
|
doDel() { |
||||
|
if (this.sids.length === 0) { |
||||
|
this.$message({ showClose: true, type: 'error', message: '请选择至少一条记录进行删除操作' }) |
||||
|
return |
||||
|
} |
||||
|
const tip = '请确认是否删除所选 ' + this.sids.length + ' 条记录?' |
||||
|
this.$confirm(tip, '提示', { |
||||
|
confirmButtonText: '确定', |
||||
|
cancelButtonText: '取消', |
||||
|
type: 'warning' |
||||
|
}).then(() => { |
||||
|
const loading = this.$loading({ |
||||
|
lock: true, |
||||
|
text: 'Loading', |
||||
|
spinner: 'el-icon-loading', |
||||
|
background: 'rgba(0, 0, 0, 0.7)' |
||||
|
}) |
||||
|
req.deleteBySids(this.sids).then(resp => { |
||||
|
if (resp.success) { |
||||
|
this.$message({ type: 'success', message: resp.msg, showClose: true }) |
||||
|
} |
||||
|
this.getList() |
||||
|
loading.close() |
||||
|
}).catch(e => { |
||||
|
loading.close() |
||||
|
}) |
||||
|
}).catch(() => { |
||||
|
}) |
||||
|
}, |
||||
|
// 修改、编辑、详情返回列表页面 |
||||
|
resetState() { |
||||
|
this.viewState = 1 |
||||
|
}, |
||||
|
doClose() { |
||||
|
this.$store.dispatch('tagsView/delView', this.$route) |
||||
|
this.$router.go(-1) |
||||
|
} |
||||
|
} |
||||
|
} |
||||
|
</script> |
||||
|
<style scoped> |
||||
|
</style> |
@ -0,0 +1,223 @@ |
|||||
|
<template> |
||||
|
<div class="app-container"> |
||||
|
<div v-show="viewState == 1"> |
||||
|
<div class="tab-header webtop"> |
||||
|
<div>{{ viewTitle }}</div> |
||||
|
<div> |
||||
|
<el-button type="primary" size="small" :disabled="submitdisabled" @click="saveOrUpdate()">保存</el-button> |
||||
|
<el-button type="primary" size="small" :disabled="submitdisabled">提交</el-button> |
||||
|
<el-button type="info" size="small" @click="handleReturn()">关闭</el-button> |
||||
|
</div> |
||||
|
</div> |
||||
|
<div class="listconadd"> |
||||
|
<el-form ref="form_obj" :model="formobj" :rules="rules" class="formaddcopy02"> |
||||
|
<el-row style="border-top: 1px solid #e0e3eb"> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">申请部门</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.deptName }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">申请人</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.createByName }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">申请日期</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.createTime }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="24"> |
||||
|
<div class="span-sty">备注</div> |
||||
|
<el-form-item><el-input class="addinputInfo" style="width: 80%" v-model="formobj.remarks" clearable placeholder="" /></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="24"> |
||||
|
<div class="span-sty">附件</div> |
||||
|
<el-form-item> |
||||
|
<uploadImg ref="uploadImg" class="addinputInfo" v-model="formobj.file" :limit="50" bucket="map" :upload-data="{ type: '0001' }"/> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<div class="title">开票索赔单列表</div> |
||||
|
<el-table :key="tableKey" :data="formobj.sitemsVos" :index="index" border style="width: 100%"> |
||||
|
<el-table-column fixed width="60" label="序号" type="index" :index="index + 1" align="center"/> |
||||
|
<el-table-column prop="sitemName" label="项目名称" align="center" width="170" /> |
||||
|
<el-table-column prop="serviceType" label="工种" align="center" width="170" /> |
||||
|
<el-table-column prop="subjectName" label="科目" align="center" width="100" /> |
||||
|
<el-table-column prop="hourPrice" label="工时单价" align="center" width="100" /> |
||||
|
<el-table-column prop="hours" label="工时数" align="center" width="100" /> |
||||
|
<el-table-column prop="cost" label="外协成本" align="center" width="120" /> |
||||
|
<el-table-column prop="price" label="销售价" align="center" width="120" /> |
||||
|
<el-table-column prop="examineHourPrice" label="工时提成" align="center" width="120" /> |
||||
|
<el-table-column prop="remarks" label="备注" align="center" min-width="200" /> |
||||
|
<el-table-column label="预约项目" align="center" width="120"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span>{{ scope.row.isReserve == '1' ? '是' : scope.row.isReserve == '0' ? '否' : '' }}</span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="洗车项目" align="center" width="120"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span>{{ scope.row.isClean == '1' ? '是' : scope.row.isClean == '0' ? '否' : '' }}</span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
</el-table> |
||||
|
</el-form> |
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
</template> |
||||
|
|
||||
|
<script> |
||||
|
import req from '@/api/basicinformation/maintenanceProjectRecord' |
||||
|
import uploadImg from '@/components/uploadFile/uploadImg' |
||||
|
import { getOrgSidByPath, fetchBySid } from '@/api/Common/dictcommons' |
||||
|
|
||||
|
export default { |
||||
|
name: 'MaintenanceProjectRecordAdd', |
||||
|
components: { |
||||
|
uploadImg |
||||
|
}, |
||||
|
data() { |
||||
|
return { |
||||
|
viewTitle: '', |
||||
|
viewState: 1, |
||||
|
submitdisabled: false, |
||||
|
tableKey: 1, |
||||
|
index: 0, |
||||
|
formobj: { |
||||
|
createByName: '', |
||||
|
createBySid: '', |
||||
|
createOrgName: '', |
||||
|
createOrgSid: '', |
||||
|
createTime: '', |
||||
|
deptName: '', |
||||
|
deptSid: '', |
||||
|
file: [], |
||||
|
instanceId: '', |
||||
|
sid: '', |
||||
|
sitemsVos: [], |
||||
|
taskId: '', |
||||
|
useOrgName: '', |
||||
|
useOrgSid: '' |
||||
|
}, |
||||
|
rules: {} |
||||
|
} |
||||
|
}, |
||||
|
methods: { |
||||
|
showAdd(val) { |
||||
|
this.viewTitle = '【新增】维修项目备案申请' |
||||
|
this.$nextTick(() => { |
||||
|
this.$refs['form_obj'].clearValidate() |
||||
|
}) |
||||
|
req.init(val).then((res) => { |
||||
|
if (res.success) { |
||||
|
this.formobj = res.data |
||||
|
this.formobj.createByName = window.sessionStorage.getItem('name') |
||||
|
this.formobj.createBySid = window.sessionStorage.getItem('userSid') |
||||
|
this.formobj.deptName = window.sessionStorage.getItem('defaultOrgPathName').substring(window.sessionStorage.getItem('defaultOrgPathName').lastIndexOf('/') + 1) |
||||
|
this.formobj.deptSid = window.sessionStorage.getItem('defaultOrgPath').substring(window.sessionStorage.getItem('defaultOrgPath').lastIndexOf('/') + 1) |
||||
|
this.formobj.createOrgSid = this.formobj.deptSid |
||||
|
this.formobj.createOrgName = this.formobj.deptName |
||||
|
var nowDate = new Date() |
||||
|
var date = { |
||||
|
year: nowDate.getFullYear(), |
||||
|
month: nowDate.getMonth() + 1, |
||||
|
day: nowDate.getDate() |
||||
|
} |
||||
|
this.formobj.createTime = date.year + '-' + (date.month >= 10 ? date.month : '0' + date.month) + '-' + (date.day >= 10 ? date.day : '0' + date.day) |
||||
|
getOrgSidByPath({ orgPath: window.sessionStorage.getItem('defaultOrgPath') }).then((resp) => { |
||||
|
if (resp.success) { |
||||
|
this.formobj.useOrgSid = resp.data |
||||
|
fetchBySid(resp.data).then((respsone) => { |
||||
|
if (respsone.success) { |
||||
|
this.formobj.useOrgName = respsone.data.name |
||||
|
} |
||||
|
}) |
||||
|
} |
||||
|
}) |
||||
|
} |
||||
|
}) |
||||
|
}, |
||||
|
showEdit(row) { |
||||
|
this.viewTitle = '【编辑】维修项目备案申请' |
||||
|
this.$nextTick(() => { |
||||
|
this.$refs['form_obj'].clearValidate() |
||||
|
}) |
||||
|
req.fetchDetailsBySid(row.sid).then((res) => { |
||||
|
if (res.success) { |
||||
|
this.formobj = res.data |
||||
|
} |
||||
|
}) |
||||
|
}, |
||||
|
saveOrUpdate() { |
||||
|
this.$refs['form_obj'].validate((valid) => { |
||||
|
if (valid) { |
||||
|
this.submitdisabled = true |
||||
|
req.saveOrUpdate(this.formobj).then((res) => { |
||||
|
if (res.success) { |
||||
|
this.$message({ showClose: true, type: 'success', message: '保存成功' }) |
||||
|
this.handleReturn('true') |
||||
|
} else { |
||||
|
this.submitdisabled = false |
||||
|
} |
||||
|
}).catch(() => { |
||||
|
this.submitdisabled = false |
||||
|
}) |
||||
|
} |
||||
|
}) |
||||
|
}, |
||||
|
submit() { |
||||
|
this.$refs['form_obj'].validate((valid) => { |
||||
|
if (valid) { |
||||
|
this.submitdisabled = true |
||||
|
req.submit(this.formobj).then((res) => { |
||||
|
if (res.success) { |
||||
|
this.$message({ showClose: true, type: 'success', message: '提交成功' }) |
||||
|
this.handleReturn('true') |
||||
|
} else { |
||||
|
this.submitdisabled = false |
||||
|
} |
||||
|
}).catch(() => { |
||||
|
this.submitdisabled = false |
||||
|
}) |
||||
|
} |
||||
|
}) |
||||
|
}, |
||||
|
handleReturn(isreload) { |
||||
|
if (isreload === 'true') this.$emit('reloadlist') |
||||
|
this.formobj = { |
||||
|
createByName: '', |
||||
|
createBySid: '', |
||||
|
createOrgName: '', |
||||
|
createOrgSid: '', |
||||
|
createTime: '', |
||||
|
deptName: '', |
||||
|
deptSid: '', |
||||
|
file: [], |
||||
|
instanceId: '', |
||||
|
sid: '', |
||||
|
sitemsVos: [], |
||||
|
taskId: '', |
||||
|
useOrgName: '', |
||||
|
useOrgSid: '' |
||||
|
|
||||
|
} |
||||
|
this.submitdisabled = false |
||||
|
this.$emit('doback') |
||||
|
} |
||||
|
} |
||||
|
} |
||||
|
</script> |
||||
|
|
||||
|
<style scoped> |
||||
|
.span-sty { |
||||
|
width: 130px !important; |
||||
|
} |
||||
|
.addinputInfo { |
||||
|
margin-left: 120px !important; |
||||
|
} |
||||
|
/deep/ .el-form-item__error { |
||||
|
margin-left: 120px !important; |
||||
|
} |
||||
|
</style> |
@ -0,0 +1,146 @@ |
|||||
|
<template> |
||||
|
<div class="app-container"> |
||||
|
<div v-show="viewState == 1"> |
||||
|
<div class="tab-header webtop"> |
||||
|
<div>{{ viewTitle }}</div> |
||||
|
<div> |
||||
|
<el-button type="info" size="small" @click="handleReturn()">关闭</el-button> |
||||
|
</div> |
||||
|
</div> |
||||
|
<div class="listconadd"> |
||||
|
<el-form ref="form_obj" :model="formobj" :rules="rules" class="formaddcopy02"> |
||||
|
<el-row style="border-top: 1px solid #e0e3eb"> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">申请部门</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.deptName }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">申请人</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.createByName }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">申请日期</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.createTime }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="24"> |
||||
|
<div class="span-sty">备注</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.remarks }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="24"> |
||||
|
<div class="span-sty">附件</div> |
||||
|
<el-form-item><el-image class="addinputInfo" style="width: 150px;height: 150px" v-for="(item, index) in formobj.file" :key="index" :src="item" :preview-src-list="formobj.file" /></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<div class="title">开票索赔单列表</div> |
||||
|
<el-table :key="tableKey" :data="formobj.sitemsVos" :index="index" border style="width: 100%"> |
||||
|
<el-table-column fixed width="60" label="序号" type="index" :index="index + 1" align="center"/> |
||||
|
<el-table-column prop="sitemName" label="项目名称" align="center" width="170" /> |
||||
|
<el-table-column prop="serviceType" label="工种" align="center" width="170" /> |
||||
|
<el-table-column prop="subjectName" label="科目" align="center" width="100" /> |
||||
|
<el-table-column prop="hourPrice" label="工时单价" align="center" width="100" /> |
||||
|
<el-table-column prop="hours" label="工时数" align="center" width="100" /> |
||||
|
<el-table-column prop="cost" label="外协成本" align="center" width="120" /> |
||||
|
<el-table-column prop="price" label="销售价" align="center" width="120" /> |
||||
|
<el-table-column prop="examineHourPrice" label="工时提成" align="center" width="120" /> |
||||
|
<el-table-column prop="remarks" label="备注" align="center" min-width="200" /> |
||||
|
<el-table-column label="预约项目" align="center" width="120"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span>{{ scope.row.isReserve == '1' ? '是' : scope.row.isReserve == '0' ? '否' : '' }}</span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="洗车项目" align="center" width="120"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span>{{ scope.row.isClean == '1' ? '是' : scope.row.isClean == '0' ? '否' : '' }}</span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
</el-table> |
||||
|
</el-form> |
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
</template> |
||||
|
|
||||
|
<script> |
||||
|
import req from '@/api/basicinformation/maintenanceProjectRecord' |
||||
|
|
||||
|
export default { |
||||
|
name: 'MaintenanceProjectRecordInfo', |
||||
|
data() { |
||||
|
return { |
||||
|
viewTitle: '', |
||||
|
viewState: 1, |
||||
|
tableKey: 1, |
||||
|
index: 0, |
||||
|
formobj: { |
||||
|
createByName: '', |
||||
|
createBySid: '', |
||||
|
createOrgName: '', |
||||
|
createOrgSid: '', |
||||
|
createTime: '', |
||||
|
deptName: '', |
||||
|
deptSid: '', |
||||
|
file: [], |
||||
|
instanceId: '', |
||||
|
sid: '', |
||||
|
sitemsVos: [], |
||||
|
taskId: '', |
||||
|
useOrgName: '', |
||||
|
useOrgSid: '' |
||||
|
}, |
||||
|
rules: {} |
||||
|
} |
||||
|
}, |
||||
|
methods: { |
||||
|
showInfo(row) { |
||||
|
this.viewTitle = '维修项目备案申请详情' |
||||
|
this.$nextTick(() => { |
||||
|
this.$refs['form_obj'].clearValidate() |
||||
|
}) |
||||
|
req.fetchDetailsBySid(row.sid).then((res) => { |
||||
|
if (res.success) { |
||||
|
this.formobj = res.data |
||||
|
if (this.formobj.file.length > 0) { |
||||
|
const aa = [] |
||||
|
this.formobj.file.forEach((e) => { |
||||
|
aa.push(e.url) |
||||
|
}) |
||||
|
this.formobj.file = aa |
||||
|
} |
||||
|
} |
||||
|
}) |
||||
|
}, |
||||
|
handleReturn() { |
||||
|
this.formobj = { |
||||
|
createByName: '', |
||||
|
createBySid: '', |
||||
|
createOrgName: '', |
||||
|
createOrgSid: '', |
||||
|
createTime: '', |
||||
|
deptName: '', |
||||
|
deptSid: '', |
||||
|
file: [], |
||||
|
instanceId: '', |
||||
|
sid: '', |
||||
|
sitemsVos: [], |
||||
|
taskId: '', |
||||
|
useOrgName: '', |
||||
|
useOrgSid: '' |
||||
|
} |
||||
|
this.$emit('doback') |
||||
|
} |
||||
|
} |
||||
|
} |
||||
|
</script> |
||||
|
|
||||
|
<style scoped> |
||||
|
.span-sty { |
||||
|
width: 130px !important; |
||||
|
} |
||||
|
.addinputInfo { |
||||
|
margin-left: 120px !important; |
||||
|
} |
||||
|
</style> |
@ -1,205 +0,0 @@ |
|||||
<template> |
|
||||
<div class="app-container"> |
|
||||
<div> |
|
||||
<div class="tab-header webtop"> |
|
||||
<div>选择维修工单</div> |
|
||||
<div> |
|
||||
<!-- <el-button type="primary" size="small" @click="AddUpdateReturn">确定</el-button> --> |
|
||||
<el-button type="info" size="small" @click="handleReturn()">关闭</el-button> |
|
||||
</div> |
|
||||
</div> |
|
||||
<div class=""> |
|
||||
<div class="searchcon"> |
|
||||
<el-button size="small" class="searchbtn" @click="clicksearchShow">{{ searchxianshitit }}</el-button> |
|
||||
<div v-show="isSearchShow" class="search"> |
|
||||
<el-form ref="listQueryform" :inline="true" :model="listQuery" label-width="120px" class="tab-header"> |
|
||||
<el-form-item label="工单编号" class="searchlist"> |
|
||||
<el-input v-model="listQuery.params.billNo" placeholder="" clearable /> |
|
||||
</el-form-item> |
|
||||
<el-form-item label="客户名称" class="searchlist"> |
|
||||
<el-input v-model="listQuery.params.customerName" placeholder="" clearable /> |
|
||||
</el-form-item> |
|
||||
<el-form-item label="车牌号" class="searchlist"> |
|
||||
<el-input v-model="listQuery.params.vehMark" placeholder="" clearable /> |
|
||||
</el-form-item> |
|
||||
<el-form-item label="进厂日期"> |
|
||||
<el-date-picker v-model="listQuery.params.entryStartTime" type="date" placeholder="选择日期" |
|
||||
format="yyyy-MM-dd" value-format="yyyy-MM-dd" style="width: 200px;"> |
|
||||
</el-date-picker>至 |
|
||||
<el-date-picker v-model="listQuery.params.entryEndTime" type="date" placeholder="选择日期" |
|
||||
format="yyyy-MM-dd" value-format="yyyy-MM-dd" style="width: 200px;"> |
|
||||
</el-date-picker> |
|
||||
</el-form-item> |
|
||||
</el-form> |
|
||||
<div class="btn" style="text-align: center;"> |
|
||||
<el-button type="primary" icon="el-icon-search" @click="handleFilter" size="small">查询</el-button> |
|
||||
<el-button type="primary" icon="el-icon-refresh" @click="handleReset" size="small">重置</el-button> |
|
||||
</div> |
|
||||
</div> |
|
||||
</div> |
|
||||
<div class="listtop"> |
|
||||
<div class="tit">维修工单列表</div> |
|
||||
<!-- <pageye v-show="list.length > 0" :total="listQuery.total" :page.sync="listQuery.current" :limit.sync="listQuery.size" class="pagination" @pagination="getList"/>--> |
|
||||
</div> |
|
||||
<div class=""> |
|
||||
<el-table :key="tableKey" ref="multipleTable" v-loading="listLoading" :data="list" border style="width: 100%"> |
|
||||
<!-- @selection-change="handleSelectionChange"> --> |
|
||||
<!-- <el-table-column width="50px" type="selection" align="center"/> --> |
|
||||
<el-table-column width="80px" label="序号" type="index" :index="indexMethod" align="center" /> |
|
||||
<el-table-column fixed label="操作" width="100" align="center"> |
|
||||
<template slot-scope="scope"> |
|
||||
<el-button type="primary" size="mini" @click="toInfo(scope.row)">确认</el-button> |
|
||||
</template> |
|
||||
</el-table-column> |
|
||||
<el-table-column prop="billNo" label="工单编号" align="center" /> |
|
||||
<el-table-column prop="billType" label="工单类型" align="center" /> |
|
||||
<el-table-column prop="customerName" label="客户名称" align="center" /> |
|
||||
<el-table-column prop="mobile" label="联系电话" align="center" /> |
|
||||
<el-table-column prop="vinNo" label="车架号" align="center" /> |
|
||||
<el-table-column prop="vehMark" label="车牌号" align="center" /> |
|
||||
<el-table-column prop="entryTime" label="进厂日期" align="center" /> |
|
||||
</el-table> |
|
||||
</div> |
|
||||
<div class="pages"> |
|
||||
<div class="tit" /> |
|
||||
<!-- 翻页 --> |
|
||||
<Pagination v-show="list.length > 0" :total="listQuery.total" :page.sync="listQuery.current" |
|
||||
:limit.sync="listQuery.size" class="pagination" @pagination="getList" /> |
|
||||
</div> |
|
||||
</div> |
|
||||
</div> |
|
||||
</div> |
|
||||
</template> |
|
||||
|
|
||||
<script> |
|
||||
import Pagination from '@/components/pagination' |
|
||||
import { |
|
||||
getAsBusrepairBill |
|
||||
} from '@/api/Common/dictcommons' |
|
||||
|
|
||||
export default { |
|
||||
name: 'SelectVehicle', |
|
||||
components: { |
|
||||
Pagination |
|
||||
}, |
|
||||
data() { |
|
||||
return { |
|
||||
isSearchShow: false, |
|
||||
searchxianshitit: '隐藏查询条件', |
|
||||
tableKey: 0, |
|
||||
sids: [], |
|
||||
list: [], |
|
||||
number: '', |
|
||||
listLoading: false, |
|
||||
listQuery: { |
|
||||
current: 1, |
|
||||
size: 10, |
|
||||
params: { |
|
||||
nodeCode: 3, |
|
||||
billNo: '', |
|
||||
customerName: '', |
|
||||
vehMark: '', |
|
||||
entryStartTime: '', |
|
||||
entryEndTime: '' |
|
||||
}, |
|
||||
total: 0 |
|
||||
} |
|
||||
} |
|
||||
}, |
|
||||
methods: { |
|
||||
// 搜索条件效果 |
|
||||
clicksearchShow() { |
|
||||
this.isSearchShow = !this.isSearchShow |
|
||||
if (this.isSearchShow) { |
|
||||
this.searchxianshitit = '隐藏查询条件' |
|
||||
} else { |
|
||||
this.searchxianshitit = '显示查询条件' |
|
||||
} |
|
||||
}, |
|
||||
indexMethod(index) { |
|
||||
var pagestart = (this.listQuery.current - 1) * this.listQuery.size |
|
||||
var pageindex = index + 1 + pagestart |
|
||||
return pageindex |
|
||||
}, |
|
||||
// 查询列表信息 |
|
||||
getList() { |
|
||||
this.listLoading = true |
|
||||
this.listQuery.params.userSid = window.sessionStorage.getItem('userSid') |
|
||||
this.listQuery.params.orgPath = window.sessionStorage.getItem('defaultOrgPath') |
|
||||
// this.listQuery.params.menuUrl = this.$route.path |
|
||||
this.listQuery.params.menuUrl = "" |
|
||||
getAsBusrepairBill(this.listQuery).then((response) => { |
|
||||
this.listLoading = false |
|
||||
if (response.success) { |
|
||||
this.listQuery.total = response.data.total |
|
||||
this.list = response.data.records |
|
||||
} |
|
||||
}) |
|
||||
}, |
|
||||
// 查询按钮 |
|
||||
handleFilter() { |
|
||||
this.listQuery.current = 1 |
|
||||
this.getList() |
|
||||
}, |
|
||||
// 重置按钮 |
|
||||
handleReset() { |
|
||||
this.listQuery = { |
|
||||
current: 1, |
|
||||
size: 10, |
|
||||
params: { |
|
||||
nodeCode: 3, |
|
||||
billNo: '', |
|
||||
customerName: '', |
|
||||
vehMark: '', |
|
||||
entryStartTime: '', |
|
||||
entryEndTime: '' |
|
||||
}, |
|
||||
total: 0 |
|
||||
} |
|
||||
this.getList() |
|
||||
}, |
|
||||
handleSelectionChange(row) { |
|
||||
this.sids = row |
|
||||
}, |
|
||||
showData(value, createOrgSid) { |
|
||||
// const aa = [] |
|
||||
// if (value.length > 0) { |
|
||||
// for (var i = 0; i < value.length; i++) { |
|
||||
// aa.push(value[i].saleVehSid) |
|
||||
// } |
|
||||
// this.listQuery.params.saleVehSids = aa |
|
||||
// } else { |
|
||||
// this.listQuery.params.saleVehSids = [] |
|
||||
// }`` |
|
||||
this.listQuery.params.createOrgSid = createOrgSid |
|
||||
this.listQuery.current = 1 |
|
||||
this.listQuery.size = 10 |
|
||||
this.listQuery.total = 0 |
|
||||
this.getList() |
|
||||
}, |
|
||||
// 添加修改返回 |
|
||||
AddUpdateReturn() { |
|
||||
if (this.sids.length > 0) { |
|
||||
this.$emit('backData', this.sids) |
|
||||
} else { |
|
||||
this.$notify({ |
|
||||
title: '提示', |
|
||||
message: '请至少选择一条记录进行操作', |
|
||||
type: 'error', |
|
||||
duration: 2000 |
|
||||
}) |
|
||||
} |
|
||||
}, |
|
||||
|
|
||||
toInfo(row){ |
|
||||
this.$emit('backData', row.sid) |
|
||||
}, |
|
||||
// 返回 |
|
||||
handleReturn() { |
|
||||
this.$emit('doback') |
|
||||
} |
|
||||
} |
|
||||
} |
|
||||
</script> |
|
||||
<style scoped> |
|
||||
</style> |
|
@ -0,0 +1,392 @@ |
|||||
|
<template> |
||||
|
<div class="app-container"> |
||||
|
<div v-show="viewState == 1"> |
||||
|
<button-bar ref="btnbar" view-title="维修领料" :btndisabled="btndisabled" @btnhandle="btnHandle" /> |
||||
|
<div class="main-content"> |
||||
|
<div class="searchcon"> |
||||
|
<el-button size="small" class="searchbtn" @click="clicksearchShow"> |
||||
|
{{ searchxianshitit }} |
||||
|
</el-button> |
||||
|
<div v-show="isSearchShow" class="search"> |
||||
|
<el-form :inline="true" class="tab-header"> |
||||
|
<el-form-item label="维修状态"> |
||||
|
<el-select v-model="queryParams.params.repairState" filterable clearable placeholder="请选择" |
||||
|
style="width:100%"> |
||||
|
<el-option v-for="item in repairTypeList" :key="item.sid" :label="item.name" :value="item.name"> |
||||
|
</el-option> |
||||
|
</el-select> |
||||
|
</el-form-item> |
||||
|
<el-form-item label="工单编号"> |
||||
|
<el-input v-model="queryParams.params.billNo" placeholder="" clearable /> |
||||
|
</el-form-item> |
||||
|
<el-form-item label="工单类型"> |
||||
|
<el-select v-model="queryParams.params.billType" filterable clearable placeholder="请选择" |
||||
|
style="width:100%"> |
||||
|
<el-option v-for="item in billTypeList" :key="item.dictKey" :label="item.dictValue" |
||||
|
:value="item.dictValue"> |
||||
|
</el-option> |
||||
|
</el-select> |
||||
|
</el-form-item> |
||||
|
<el-form-item label="科目"> |
||||
|
<el-select v-model="queryParams.params.subject" filterable clearable placeholder="请选择" |
||||
|
style="width:100%"> |
||||
|
<el-option v-for="item in subjectList" :key="item.subjectSid" :label="item.subject" |
||||
|
:value="item.subject"> |
||||
|
</el-option> |
||||
|
</el-select> |
||||
|
</el-form-item> |
||||
|
<el-form-item label="客户名称"> |
||||
|
<el-input v-model="queryParams.params.customerName" placeholder="" clearable /> |
||||
|
</el-form-item> |
||||
|
<el-form-item label="车牌号"> |
||||
|
<el-input v-model="queryParams.params.vehMark" placeholder="" clearable /> |
||||
|
</el-form-item> |
||||
|
<el-form-item label="车架号"> |
||||
|
<el-input v-model="queryParams.params.vinNo" placeholder="" clearable /> |
||||
|
</el-form-item> |
||||
|
<el-form-item label="进厂日期"> |
||||
|
<el-date-picker v-model="queryParams.params.createTimeStart" type="date" placeholder="选择日期" |
||||
|
format="yyyy-MM-dd" value-format="yyyy-MM-dd" style="width: 200px;"> |
||||
|
</el-date-picker> |
||||
|
至 |
||||
|
<el-date-picker v-model="queryParams.params.createTimeEnd" type="date" placeholder="选择日期" |
||||
|
format="yyyy-MM-dd" value-format="yyyy-MM-dd" style="width: 200px;"> |
||||
|
</el-date-picker> |
||||
|
</el-form-item> |
||||
|
|
||||
|
</el-form> |
||||
|
<div class="btn" style="text-align: center;"> |
||||
|
<el-button type="primary" size="small" icon="el-icon-search" @click="dosearch">查询</el-button> |
||||
|
<el-button type="primary" size="small" icon="el-icon-refresh" @click="resetQuery">重置</el-button> |
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
<!-- Start 项目列表头部 --> |
||||
|
<div class="listtop"> |
||||
|
<div class="tit">维修领料列表</div> |
||||
|
</div> |
||||
|
<!-- End 项目列表头部 --> |
||||
|
<!-- Start 项目列表 --> |
||||
|
<div class=""> |
||||
|
<el-table v-loading="tableLoading" :data="dataList" border style="width: 100%" |
||||
|
@selection-change="selectionLineChangeHandle"> |
||||
|
<el-table-column fixed width="50" type="selection" align="center" /> |
||||
|
<el-table-column fixed width="80" label="序号" type="index" :index="indexMethod" align="center" /> |
||||
|
<el-table-column prop="repairState" label="维修状态" align="center" /> |
||||
|
<el-table-column label="工单编号" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
<div style="color: #1890FF; text-decoration: underline ;" @click="showResult(scope.row)"> |
||||
|
{{ scope.row.billNo }} |
||||
|
</div> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column prop="billTypeValue" label="工单类型" align="center" /> |
||||
|
<el-table-column prop="subjectValue" label="科目" align="center" /> |
||||
|
<el-table-column prop="isGoOut" label="是否外出" align="center" /> |
||||
|
<el-table-column prop="customerName" label="客户名称" align="center" /> |
||||
|
<el-table-column prop="mobile" label="联系电话" align="center" /> |
||||
|
<el-table-column prop="vehMark" label="车架号" align="center" /> |
||||
|
<el-table-column prop="vinNo" label="车牌号" align="center" /> |
||||
|
<el-table-column prop="entryTime" label="进厂日期" align="center" /> |
||||
|
|
||||
|
</el-table> |
||||
|
</div> |
||||
|
<!-- End 项目列表 --> |
||||
|
<div class="pages"> |
||||
|
<div class="tit" /> |
||||
|
<!-- 翻页 --> |
||||
|
<pagination v-show="dataList.length > 0" :total="queryParams.total" :page.sync="queryParams.current" |
||||
|
:limit.sync="queryParams.size" class="pagination" @pagination="loadList" /> |
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
<!-- End 查询和其列表部分 --> |
||||
|
<!-- 新增修改部分组件 --> |
||||
|
<divOutInfo v-show="viewState == 2 " ref="divOutInfo" @doback="resetState" @reloadlist="loadList" /> |
||||
|
<divReturnInfo v-show="viewState == 3" ref="divReturnInfo" @doback="resetState" @reloadlist="loadList" /> |
||||
|
<divConfirmInfo v-show="viewState ==4" ref="divConfirmInfo" @doback="resetState" @reloadlist="loadList" /> |
||||
|
<divInfo v-show="viewState == 5" ref="divInfo" @doback="resetState" @reloadlist="loadList" /> |
||||
|
|
||||
|
</div> |
||||
|
</template> |
||||
|
|
||||
|
<script> |
||||
|
import req from '@/api/maintenanceReceive/maintenanceReceive.js' |
||||
|
import { |
||||
|
selSubjectInfo, |
||||
|
typeValues |
||||
|
} from '@/api/Common/dictcommons' |
||||
|
import ButtonBar from '@/components/ButtonBar' |
||||
|
import Pagination from '@/components/pagination' |
||||
|
import pageye from '@/components/pagination/pageye' |
||||
|
import divOutInfo from './maintenanceOutbound.vue' |
||||
|
import divReturnInfo from './maintenanceReturnBound.vue' |
||||
|
import divConfirmInfo from './maintenanceConfirm.vue' |
||||
|
import divInfo from './repairbillInfo.vue' |
||||
|
export default { |
||||
|
components: { |
||||
|
ButtonBar, |
||||
|
Pagination, |
||||
|
pageye, |
||||
|
divOutInfo, |
||||
|
divReturnInfo, |
||||
|
divConfirmInfo, |
||||
|
divInfo, |
||||
|
|
||||
|
}, |
||||
|
data() { |
||||
|
return { |
||||
|
dialogVisible: false, |
||||
|
btndisabled: false, |
||||
|
viewState: 1, // 1、列表 2、添加 3、修改 4、查看 |
||||
|
isSearchShow: false, |
||||
|
searchxianshitit: '显示查询条件', |
||||
|
tableLoading: false, |
||||
|
dataList: [], |
||||
|
btnList: [{ |
||||
|
type: 'primary', |
||||
|
size: 'small', |
||||
|
icon: 'plus', |
||||
|
btnKey: 'toOut', |
||||
|
btnLabel: '领料出库' |
||||
|
}, |
||||
|
{ |
||||
|
type: 'primary', |
||||
|
size: 'small', |
||||
|
icon: 'plus', |
||||
|
btnKey: 'toReturn', |
||||
|
btnLabel: '领料退库' |
||||
|
}, |
||||
|
{ |
||||
|
type: 'primary', |
||||
|
size: 'small', |
||||
|
icon: 'plus', |
||||
|
btnKey: 'toConfirm', |
||||
|
btnLabel: '商品出库确认' |
||||
|
}, |
||||
|
{ |
||||
|
type: 'info', |
||||
|
size: 'small', |
||||
|
icon: 'cross', |
||||
|
btnKey: 'doClose', |
||||
|
btnLabel: '关闭' |
||||
|
} |
||||
|
], |
||||
|
queryParams: { |
||||
|
current: 1, |
||||
|
size: 10, |
||||
|
total: 0, |
||||
|
params: { |
||||
|
"repairState": "", |
||||
|
"billNo": "", |
||||
|
"billType": "", |
||||
|
"subject": "", |
||||
|
"customerName": "", |
||||
|
"vehMark": "", |
||||
|
"vinNo": "", |
||||
|
"createTimeStart": "", |
||||
|
"createTimeEnd": "", |
||||
|
} |
||||
|
}, |
||||
|
|
||||
|
sids: [], |
||||
|
selectionList: [], |
||||
|
repairTypeList: [{ |
||||
|
name: "维修中", |
||||
|
sid: "1" |
||||
|
}, |
||||
|
{ |
||||
|
name: "维修完成", |
||||
|
sid: "2" |
||||
|
} |
||||
|
], |
||||
|
billTypeList: [], |
||||
|
subjectList: [] |
||||
|
} |
||||
|
}, |
||||
|
mounted() { |
||||
|
this.$refs['btnbar'].setButtonList(this.btnList) |
||||
|
}, |
||||
|
created() { |
||||
|
this.loadList() |
||||
|
this.init() |
||||
|
}, |
||||
|
methods: { |
||||
|
|
||||
|
init() { |
||||
|
typeValues({ |
||||
|
type: 'billType' |
||||
|
}).then((res) => { |
||||
|
if (res.success) { |
||||
|
this.billTypeList = res.data |
||||
|
} |
||||
|
}) |
||||
|
selSubjectInfo({ |
||||
|
useOrgSid: window.sessionStorage.getItem('defaultOrgPath').substring(window.sessionStorage.getItem( |
||||
|
'defaultOrgPath').lastIndexOf('/') + 1) |
||||
|
}).then((resp) => { |
||||
|
if (resp.success) { |
||||
|
this.subjectList = resp.data |
||||
|
} |
||||
|
}) |
||||
|
|
||||
|
}, |
||||
|
|
||||
|
selectionLineChangeHandle(val) { |
||||
|
console.log("val", val); |
||||
|
|
||||
|
this.selectionList = val |
||||
|
const aa = [] |
||||
|
val.forEach(element => { |
||||
|
aa.push(element.sid) |
||||
|
}) |
||||
|
this.sids = aa |
||||
|
|
||||
|
}, |
||||
|
// 搜索条件效果 |
||||
|
clicksearchShow() { |
||||
|
this.isSearchShow = !this.isSearchShow |
||||
|
if (this.isSearchShow) { |
||||
|
this.searchxianshitit = '隐藏查询条件' |
||||
|
} else { |
||||
|
this.searchxianshitit = '显示查询条件' |
||||
|
} |
||||
|
}, |
||||
|
btnHandle(btnKey) { |
||||
|
switch (btnKey) { |
||||
|
case 'toOut': |
||||
|
this.toOut() |
||||
|
break |
||||
|
case 'toReturn': |
||||
|
this.toReturn() |
||||
|
break |
||||
|
case 'toConfirm': |
||||
|
this.toConfirm() |
||||
|
break |
||||
|
case 'doClose': |
||||
|
this.doClose() |
||||
|
break |
||||
|
default: |
||||
|
break |
||||
|
} |
||||
|
}, |
||||
|
|
||||
|
toOut() { |
||||
|
// this.$refs['divOutInfo'].showAdd('236195bd-2c76-4e39-aacb-e6ed89b4ca3d') |
||||
|
// this.viewState = 2 |
||||
|
if (this.sids.length === 1) { |
||||
|
this.viewState = 2 |
||||
|
this.$refs['divOutInfo'].showAdd(this.sids[0]) |
||||
|
} else { |
||||
|
this.$message({ |
||||
|
showClose: true, |
||||
|
type: 'warning', |
||||
|
message: '请选择一条记录进行操作' |
||||
|
}) |
||||
|
} |
||||
|
}, |
||||
|
toReturn() { |
||||
|
// this.$refs['divReturnInfo'].showAdd('4e2b2a7d-d86c-415f-aa69-65e311a73c50') |
||||
|
// this.viewState = 3 |
||||
|
if (this.sids.length === 1) { |
||||
|
this.viewState = 3 |
||||
|
this.$refs['divReturnInfo'].showAdd(this.sids[0]) |
||||
|
} else { |
||||
|
this.$message({ |
||||
|
showClose: true, |
||||
|
type: 'warning', |
||||
|
message: '请选择一条记录进行操作' |
||||
|
}) |
||||
|
} |
||||
|
}, |
||||
|
toConfirm() { |
||||
|
// this.viewState = 4 |
||||
|
// this.$refs['divConfirmInfo'].showAdd('4e2b2a7d-d86c-415f-aa69-65e311a73c50') |
||||
|
if (this.sids.length === 1) { |
||||
|
|
||||
|
if (this.selectionList[0].repairState == '2') { |
||||
|
|
||||
|
this.viewState = 4 |
||||
|
this.$refs['divConfirmInfo'].showAdd(this.sids[0]) |
||||
|
} else { |
||||
|
this.$message({ |
||||
|
showClose: true, |
||||
|
type: 'warning', |
||||
|
message: '只能选择维修完成的工单' |
||||
|
}) |
||||
|
} |
||||
|
|
||||
|
} else { |
||||
|
this.$message({ |
||||
|
showClose: true, |
||||
|
type: 'warning', |
||||
|
message: '请选择一条记录进行操作' |
||||
|
}) |
||||
|
} |
||||
|
}, |
||||
|
doClose() { |
||||
|
this.$store.dispatch('tagsView/delView', this.$route) |
||||
|
this.$router.go(-1) |
||||
|
}, |
||||
|
|
||||
|
loadList() { |
||||
|
this.tableLoading = true |
||||
|
req.listPage(this.queryParams).then((resp) => { |
||||
|
this.tableLoading = false |
||||
|
if (resp.success) { |
||||
|
const data = resp.data |
||||
|
this.queryParams.total = data.total |
||||
|
this.dataList = data.records |
||||
|
} else { |
||||
|
// 根据resp.code进行异常情况处理 |
||||
|
this.dataList = [] |
||||
|
this.queryParams.total = 0 |
||||
|
} |
||||
|
}).catch(() => { |
||||
|
this.tableLoading = false |
||||
|
}) |
||||
|
}, |
||||
|
|
||||
|
// 序号 |
||||
|
indexMethod(index) { |
||||
|
var pagestart = (this.queryParams.current - 1) * this.queryParams.size |
||||
|
var pageindex = index + 1 + pagestart |
||||
|
return pageindex |
||||
|
}, |
||||
|
dosearch() { |
||||
|
this.queryParams.current = 1 |
||||
|
this.loadList() |
||||
|
}, |
||||
|
resetQuery() { |
||||
|
this.queryParams = { |
||||
|
current: 1, |
||||
|
size: 10, |
||||
|
total: 0, |
||||
|
params: { |
||||
|
"repairState": "", |
||||
|
"billNo": "", |
||||
|
"billType": "", |
||||
|
"subject": "", |
||||
|
"customerName": "", |
||||
|
"vehMark": "", |
||||
|
"vinNo": "", |
||||
|
"createTimeStart": "", |
||||
|
"createTimeEnd": "", |
||||
|
} |
||||
|
} |
||||
|
this.loadList() |
||||
|
}, |
||||
|
|
||||
|
resetState() { |
||||
|
this.viewState = 1 |
||||
|
}, |
||||
|
|
||||
|
showResult(row) { |
||||
|
this.viewState = 5 |
||||
|
this.$refs['divAdd'].showAdd(row.sid) |
||||
|
}, |
||||
|
} |
||||
|
} |
||||
|
</script> |
||||
|
<style scoped> |
||||
|
</style> |
@ -0,0 +1,323 @@ |
|||||
|
<template> |
||||
|
<div class="app-container"> |
||||
|
<div v-show="viewState == 1"> |
||||
|
|
||||
|
<div class="tab-header webtop"> |
||||
|
<!-- 标题 --> |
||||
|
<div>商品出库确认</div> |
||||
|
<!-- start 添加修改按钮 --> |
||||
|
<div> |
||||
|
<el-button type="primary" size="small" :disabled="submitdisabled" @click="saveOrUpdate">确认</el-button> |
||||
|
<el-button type="info" size="small" @click="handleReturn()">关闭</el-button> |
||||
|
</div> |
||||
|
<!-- end 添加修改按钮 --> |
||||
|
<!-- end 详情按钮 --> |
||||
|
</div> |
||||
|
|
||||
|
<div class="listconadd"> |
||||
|
|
||||
|
<el-form ref="form_obj" :model="formobj" class="formaddcopy02"> |
||||
|
<!-- <div class="title"> |
||||
|
<div>基础信息</div> |
||||
|
</div> --> |
||||
|
<el-row class="first_row"> |
||||
|
|
||||
|
<el-col :span="24"> |
||||
|
<div class="span-sty">备注</div> |
||||
|
<el-form-item> |
||||
|
<el-input v-model="confirmInfo.remarks" placeholder="备注" class="addinputw addinputInfo" clearable /> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
|
||||
|
</el-row> |
||||
|
|
||||
|
<div class="title titleOne"> |
||||
|
<div>维修工单</div> |
||||
|
</div> |
||||
|
|
||||
|
<el-row> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">维修工单编号</div> |
||||
|
<el-form-item> |
||||
|
<span class="addinputw addinputInfo">{{formobj.sourceBillNo}}</span> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
|
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">单据日期</div> |
||||
|
<el-form-item> |
||||
|
<span class="addinputw addinputInfo">{{formobj.billDate}}</span> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
|
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">服务顾问</div> |
||||
|
<el-form-item> |
||||
|
<el-form-item><span class="addinputw addinputInfo">{{ formobj.waitorName }}</span></el-form-item> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
|
||||
|
<el-row> |
||||
|
|
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">工单类型</div> |
||||
|
<el-form-item> |
||||
|
<span class="addinputw addinputInfo">{{formobj.billType}}</span> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
|
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">科目</div> |
||||
|
<el-form-item> |
||||
|
<span class="addinputw addinputInfo">{{formobj.subject}}</span> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
|
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">是否外出</div> |
||||
|
<el-form-item> |
||||
|
<el-radio-group class="addinputw addinputInfo" :disabled="true" v-model="formobj.isGoOut"> |
||||
|
<el-radio :label="1">是</el-radio> |
||||
|
<el-radio :label="0">否</el-radio> |
||||
|
</el-radio-group> |
||||
|
|
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
|
||||
|
<el-row> |
||||
|
|
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">客户名称</div> |
||||
|
<el-form-item> |
||||
|
<span class="addinputw addinputInfo">{{formobj.customerName}}</span> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
|
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">车牌号/车架号</div> |
||||
|
<el-form-item> |
||||
|
<span class="addinputw addinputInfo">{{formobj.vehMark}}/{{formobj.vinNo}}</span> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
|
||||
|
<!-- <el-col :span="8"> |
||||
|
<div class="span-sty">客户单位</div> |
||||
|
<el-form-item> |
||||
|
<el-form-item><span class="addinputw addinputInfo">{{ formobj.customerOrg }}</span></el-form-item> |
||||
|
</el-form-item> |
||||
|
</el-col> --> |
||||
|
</el-row> |
||||
|
|
||||
|
<div class="title titleOne"> |
||||
|
<div>服务项目</div> |
||||
|
</div> |
||||
|
<el-table v-loading="listLoading" :data="formobj.sitemVoList" border> |
||||
|
<!-- <el-table-column type="selection" align="center" width="50"/> --> |
||||
|
<el-table-column label="序号" type="index" width="80" :index="indexMethod" align="center" /> |
||||
|
<el-table-column label="服务项目" prop="serviceItem" align="center" /> |
||||
|
<el-table-column label="工种" prop="serviceType" align="center" /> |
||||
|
<el-table-column label="科目" prop="subject" align="center" /> |
||||
|
<el-table-column label="维修人" prop="repairerName" align="center" /> |
||||
|
<el-table-column label="工时提成" prop="examineHourPrice" align="center" /> |
||||
|
<el-table-column label="工时单价" prop="hourPrice" align="center" /> |
||||
|
<el-table-column label="工时数" prop="hours" align="center" /> |
||||
|
<el-table-column label="销售价" prop="price" align="center" /> |
||||
|
<el-table-column label="折扣" prop="discount" align="center" /> |
||||
|
<el-table-column label="优惠" prop="discountAmount" align="center" /> |
||||
|
<el-table-column label="金额" prop="amount" align="center" /> |
||||
|
<el-table-column label="备注" prop="remarks" align="center" /> |
||||
|
</el-table> |
||||
|
|
||||
|
<div class="title titleOne"> |
||||
|
<div>商品列表</div> |
||||
|
</div> |
||||
|
<el-row> |
||||
|
<el-col :span="24"> |
||||
|
<div class="span-sty span-sty-one" style="width: 300px;!important;">前台登记时对商品要求备注</div> |
||||
|
<el-form-item><el-input class="addinputInfo-one" style="width: 70%" v-model="formobj.registerRemarks" |
||||
|
clearable placeholder="" :disabled="true" /></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-table v-loading="listLoading" :data="formobj.detailList" border> |
||||
|
<!-- <el-table-column type="selection" align="center" width="50"/> --> |
||||
|
<el-table-column label="序号" type="index" width="80" :index="indexMethod" align="center" /> |
||||
|
<el-table-column label="项目名称" prop="serviceItem" align="center" /> |
||||
|
<el-table-column label="商品名称" prop="goodsSpuName" align="center" /> |
||||
|
<el-table-column label="商品编码" prop="goodsSkuCode" align="center" /> |
||||
|
<el-table-column label="规格" prop="goodsSkuOwnSpec" align="center" /> |
||||
|
<el-table-column label="单位" prop="unit" align="center" /> |
||||
|
<el-table-column label="仓库" prop="warehouseName" align="center" /> |
||||
|
<el-table-column label="库位" prop="warehouseRackCode" align="center" /> |
||||
|
|
||||
|
<!-- <el-table-column label="仓库" align="center" width="180"> |
||||
|
<template slot-scope="scope"> |
||||
|
<el-select v-model="scope.row.warehouseName" placeholder="请选择" clearable |
||||
|
@change="selectWarehouseName(scope.row,$event)"> |
||||
|
<el-option v-for="(item,i) in warehouseList" :key="i" :label="item.warehouseName" :value="item.sid"> |
||||
|
</el-option> |
||||
|
</el-select> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="库位" align="center" width="180"> |
||||
|
<template slot-scope="scope"> |
||||
|
<el-select v-model="scope.row.warehouseRackCode" :disabled="scope.row.warehouseName==''" clearable |
||||
|
@focus="getWarehouseAreaList(scope.row.warehouseSid)" placeholder="请选择" |
||||
|
@change="selectWarehouseAreaCode(scope.row,$event)"> |
||||
|
<el-option v-for="(item,i) in warehouseRackList" :key="i" :label="item.areaCode" :value="item.sid"> |
||||
|
</el-option> |
||||
|
</el-select> |
||||
|
</template> |
||||
|
</el-table-column> --> |
||||
|
<el-table-column label="销售单价" prop="price" align="center" /> |
||||
|
<el-table-column label="库存数量" prop="inventoryNum" align="center" /> |
||||
|
<el-table-column label="出库数量" prop="outboundCount" align="center" /> |
||||
|
<el-table-column label="备注" prop="remarks" align="center" /> |
||||
|
<!-- <el-table-column label="出库数量" align="center" width="120"> |
||||
|
<template slot-scope="scope"> |
||||
|
<el-input v-model="scope.row.count" clearable placeholder="" |
||||
|
oninput="value=value.replace(/^(0+)|[^\d]+/g,'')" /> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="备注" align="center" width="220"> |
||||
|
<template slot-scope="scope"> |
||||
|
<el-input v-model="scope.row.remarks" clearable placeholder="" /> |
||||
|
</template> |
||||
|
</el-table-column> --> |
||||
|
</el-table> |
||||
|
|
||||
|
</el-form> |
||||
|
|
||||
|
</div> |
||||
|
</div> |
||||
|
|
||||
|
</div> |
||||
|
</template> |
||||
|
|
||||
|
<script> |
||||
|
import req from '@/api/maintenanceReceive/maintenanceReceive.js' |
||||
|
export default { |
||||
|
components: {}, |
||||
|
data() { |
||||
|
return { |
||||
|
viewState: 1, |
||||
|
listLoading: false, |
||||
|
submitdisabled: false, |
||||
|
formobj: {}, |
||||
|
confirmInfo: { |
||||
|
sid: "", |
||||
|
remarks: "" |
||||
|
} |
||||
|
} |
||||
|
}, |
||||
|
created() {}, |
||||
|
methods: { |
||||
|
showAdd(sid) { |
||||
|
|
||||
|
this.confirmInfo.sid = sid |
||||
|
|
||||
|
var params = { |
||||
|
sid: sid |
||||
|
} |
||||
|
req.initBill(params) |
||||
|
.then(resp => { |
||||
|
if (resp.success) { |
||||
|
console.log('>>>>>>>>>initBill', resp) |
||||
|
|
||||
|
this.formobj = resp.data |
||||
|
|
||||
|
|
||||
|
} else { |
||||
|
// 根据resp.code进行异常情况处理 |
||||
|
} |
||||
|
}) |
||||
|
.catch(() => {}) |
||||
|
|
||||
|
}, |
||||
|
|
||||
|
resetState() { |
||||
|
this.viewState = 1 |
||||
|
}, |
||||
|
saveOrUpdate() { |
||||
|
console.log('>>>>>>>>>saveOrUpdate', this.confirmInfo) |
||||
|
|
||||
|
req.saveConfirm(this.confirmInfo) |
||||
|
.then(resp => { |
||||
|
if (resp.success) { |
||||
|
this.$message({ |
||||
|
showClose: true, |
||||
|
type: 'success', |
||||
|
message: resp.msg |
||||
|
}) |
||||
|
this.handleReturn('true') |
||||
|
} else { |
||||
|
// 根据resp.code进行异常情况处理 |
||||
|
} |
||||
|
}) |
||||
|
.catch(() => {}) |
||||
|
|
||||
|
}, |
||||
|
|
||||
|
handleReturn(isreload) { |
||||
|
if (isreload === 'true') this.$emit('reloadlist') |
||||
|
this.formobj = {} |
||||
|
this.submitdisabled = false |
||||
|
this.$emit('doback') |
||||
|
}, |
||||
|
indexMethod(index) { |
||||
|
return index + 1 |
||||
|
}, |
||||
|
|
||||
|
} |
||||
|
|
||||
|
} |
||||
|
</script> |
||||
|
<style scoped> |
||||
|
/deep/ .el-form-item__error { |
||||
|
margin-left: 120px !important; |
||||
|
} |
||||
|
|
||||
|
.must { |
||||
|
color: #f00; |
||||
|
} |
||||
|
|
||||
|
.span-sty { |
||||
|
width: 130px !important; |
||||
|
} |
||||
|
|
||||
|
.addinputInfo { |
||||
|
margin-left: 120px !important; |
||||
|
} |
||||
|
|
||||
|
.formaddcopy02 .el-row .el-col /deep/ .el-form-item .addinputw { |
||||
|
margin-left: 120px !important; |
||||
|
width: calc(100% - 115px); |
||||
|
} |
||||
|
|
||||
|
.first_row { |
||||
|
border-top: 1px solid #E0E3EB; |
||||
|
} |
||||
|
|
||||
|
.titleOne { |
||||
|
padding: 7px; |
||||
|
display: flex; |
||||
|
flex-direction: row; |
||||
|
justify-content: space-between; |
||||
|
align-items: center; |
||||
|
} |
||||
|
|
||||
|
.el-radio /deep/ .el-radio__label { |
||||
|
|
||||
|
font-size: 14px !important; |
||||
|
|
||||
|
} |
||||
|
|
||||
|
.addinputInfo-one { |
||||
|
margin-left: 170px !important; |
||||
|
} |
||||
|
|
||||
|
.span-sty-one { |
||||
|
width: 180px !important; |
||||
|
} |
||||
|
</style> |
@ -0,0 +1,638 @@ |
|||||
|
<template> |
||||
|
<div class="app-container"> |
||||
|
<div v-show="viewState == 1"> |
||||
|
<div class="tab-header webtop"> |
||||
|
<div>{{ viewTitle }}</div> |
||||
|
<div> |
||||
|
<el-button type="primary" size="small" @click="negativeSettlement()">反结算</el-button> |
||||
|
<el-button type="info" size="small" @click="handleReturn()">关闭</el-button> |
||||
|
</div> |
||||
|
</div> |
||||
|
<div class="listconadd"> |
||||
|
<el-form ref="form_obj" :model="formobj" :rules="rules" class="formaddcopy02"> |
||||
|
<el-row style="border-top: 1px solid #e0e3eb"> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">制单人</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.createByName }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">制单部门</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.deptName }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">制单日期</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.createDate }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">工单类型</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.billType }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">科目</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.subject }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">索赔厂家</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.claimManufacturer }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">是否外出</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.isGoOut == '1' ? '是' : '否' }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">进厂时间</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.entryTime }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">预计完工</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.estimatedFinishTime }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">服务顾问</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.waitorName }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">班组</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.groupName }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">主修人</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.mainRepairers }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">备注(打印)</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.printRemarks }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">备注</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.remarks }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">特殊标注</div> |
||||
|
<el-form-item><span |
||||
|
class="addinputInfo">{{ formobj.isSpecialSign == '1' ? '有' : '否' }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-collapse v-model="activeNames"> |
||||
|
<el-collapse-item title="客户信息" name="1"> |
||||
|
<el-row style="border-top: 1px solid #e0e3eb"> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">客户</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.customerName }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">联系电话</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.mobile }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">客户来源</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.customerSource }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">车牌号</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.vehMark }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">车架号</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.vinNo }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">车型</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.vehModel }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">行驶里程(Km)</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.mileage }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">油量(L)</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.oil }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">当前里程(Km)</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.currentMileage }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
</el-collapse-item> |
||||
|
<el-collapse-item title="对接人信息" name="2"> |
||||
|
<el-row style="border-top: 1px solid #e0e3eb"> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">对接人姓名</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.dockingPeople }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="16"> |
||||
|
<div class="span-sty">对接人电话</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.dockingPhone }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
</el-collapse-item> |
||||
|
<el-collapse-item title="保险信息" name="3"> |
||||
|
<el-row style="border-top: 1px solid #e0e3eb"> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">责任划分</div> |
||||
|
<el-form-item><span |
||||
|
class="addinputInfo">{{ formobj.insuranceVo.responsibility }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">责任比例</div> |
||||
|
<el-form-item><span |
||||
|
class="addinputInfo">{{ formobj.insuranceVo.responsibilityRatio }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">是否存在人伤</div> |
||||
|
<el-form-item><span |
||||
|
class="addinputInfo">{{ formobj.insuranceVo.isPersonInjuries == '1' ? '是' : formobj.insuranceVo.isPersonInjuries == '0' ? '否' : '' }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-table :key="insuranceKey" :data="formobj.insuranceVo.insuranceList" :index="index" border |
||||
|
style="width: 100%"> |
||||
|
<el-table-column fixed width="60" label="序号" type="index" :index="index + 1" align="center" /> |
||||
|
<el-table-column prop="useInsurer" label="使用保险方" align="center" min-width="150" /> |
||||
|
<el-table-column prop="insuranceType" label="使用险种" align="center" min-width="150" /> |
||||
|
<el-table-column prop="insuranceCompany" label="保险公司" align="center" min-width="150" /> |
||||
|
<el-table-column prop="claimBillNo" label="报案号" align="center" min-width="180" /> |
||||
|
<el-table-column prop="investigator" label="勘察员及电话" align="center" min-width="220" /> |
||||
|
<el-table-column prop="lossAdjuster" label="定损员及电话" align="center" min-width="220" /> |
||||
|
</el-table> |
||||
|
</el-collapse-item> |
||||
|
<el-collapse-item title="发票信息" name="4"> |
||||
|
<el-row style="border-top: 1px solid #e0e3eb"> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">是否开发票</div> |
||||
|
<el-form-item><span |
||||
|
class="addinputInfo">{{ formobj.invoiceVo.isInvoicing == '1' ? '是' : formobj.invoiceVo.isInvoicing == '0' ? '否' : '' }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">发票类型</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.invoiceVo.invoiceType }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">开票单位</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.invoiceVo.invoiceCompany }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
</el-collapse-item> |
||||
|
</el-collapse> |
||||
|
<div class="title">服务项目</div> |
||||
|
<el-table :key="serviceKey" :data="formobj.sitemVos" :index="index" border style="width: 100%"> |
||||
|
<el-table-column fixed width="60" label="序号" type="index" :index="index + 1" align="center" /> |
||||
|
<el-table-column prop="serviceItem" label="服务项目" align="center" width="200" /> |
||||
|
<el-table-column prop="serviceType" label="工种" align="center" width="150" /> |
||||
|
<el-table-column prop="repairerName" label="维修人" width="200" align="center" /> |
||||
|
<el-table-column prop="examineHourPrice" label="工时提成" align="center" width="100" /> |
||||
|
<el-table-column prop="hourPrice" label="工时单价" align="center" width="150" /> |
||||
|
<el-table-column prop="hours" label="工时数" align="center" width="100" /> |
||||
|
<el-table-column prop="price" label="销售价" align="center" width="150" /> |
||||
|
<el-table-column prop="discount" label="折扣" align="center" width="100" /> |
||||
|
<el-table-column prop="discountAmount" label="优惠" align="center" width="150" /> |
||||
|
<el-table-column prop="amount" label="金额" align="center" width="150" /> |
||||
|
<el-table-column prop="remarks" label="备注" align="center" min-width="300" /> |
||||
|
</el-table> |
||||
|
<div class="title">商品</div> |
||||
|
<el-row> |
||||
|
<el-col :span="24"> |
||||
|
<div class="span-sty span-sty-one" style="width: 300px;!important;">前台登记时对商品要求备注</div> |
||||
|
<el-form-item><span class="addinputInfo-one">{{ formobj.registerRemarks }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-table :key="tableKey" :data="formobj.goodsDetailsVos" :index="index" border style="width: 100%"> |
||||
|
<el-table-column fixed width="60" label="序号" type="index" :index="index + 1" align="center" /> |
||||
|
<el-table-column prop="goodsSpuName" label="商品名称" width="100" align="center" /> |
||||
|
<el-table-column prop="goodsSkuCode" label="图号" width="100" align="center" /> |
||||
|
<el-table-column prop="goodsSkuOwnSpec" label="规格" width="100" align="center" /> |
||||
|
<el-table-column prop="unit" label="单位" width="100" align="center" /> |
||||
|
<el-table-column prop="warehouseName" label="仓库" width="100" align="center" /> |
||||
|
<el-table-column prop="warehouseRackCode" label="库位" width="100" align="center" /> |
||||
|
<el-table-column prop="price" label="销售价" align="center" width="150" /> |
||||
|
<el-table-column prop="count" label="数量" width="100" align="center" /> |
||||
|
<el-table-column prop="discount" label="折扣" align="center" width="100" /> |
||||
|
<el-table-column prop="discountAmount" label="优惠" width="100" align="center" /> |
||||
|
<el-table-column prop="amount" label="金额" width="100" align="center" /> |
||||
|
<el-table-column prop="remarks" label="备注" align="center" min-width="300" /> |
||||
|
</el-table> |
||||
|
<div class="title">附加项目</div> |
||||
|
<el-row> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">外出费(元)</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.outAmount }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="16"> |
||||
|
<div class="span-sty">备注</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.outRemarks }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">厂家补助(元)</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.subsidyAmount }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="16"> |
||||
|
<div class="span-sty">备注</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.subsidyRemarks }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">施救费(元)</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.rescueAmount }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">备注</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.rescueRemarks }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="8"> |
||||
|
<span></span> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-table :key="subjoinKey" :data="formobj.aitemVos" :index="index" border style="width: 100%"> |
||||
|
<el-table-column fixed width="60" label="序号" type="index" :index="index + 1" align="center" /> |
||||
|
<el-table-column prop="aitemName" label="其它附加项目" align="center" width="200" /> |
||||
|
<el-table-column prop="price" label="销售价" align="center" width="150" /> |
||||
|
<el-table-column prop="remarks" label="备注" align="center" min-width="200" /> |
||||
|
</el-table> |
||||
|
<el-row> |
||||
|
<el-col :span="24"> |
||||
|
<div class="span-sty" style="border-right: 0px">应收合计:</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ ysTotal }} = 工时费:{{ gsfTotal }} + 材料费:{{ clfTotal }} + |
||||
|
附加费:{{ fjfTotal }} + 税额:0</span></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="24"> |
||||
|
<div class="span-sty" style="border-right: 0px">实收合计:</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ ssTotal }} = 应收合计:{{ ysTotal }} - |
||||
|
优惠:{{ yhTotal }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
</el-form> |
||||
|
</div> |
||||
|
</div> |
||||
|
<!-- <workslrsettlementAdd v-show="viewState == 2" ref="divFJS" @doback="resetState" /> --> |
||||
|
</div> |
||||
|
</template> |
||||
|
|
||||
|
<script> |
||||
|
import req from '@/api/operation/repairbill' |
||||
|
// import workslrsettlementAdd from '../workslrsettlement/workslrsettlementAdd' |
||||
|
|
||||
|
export default { |
||||
|
name: 'RepairBillInfo', |
||||
|
components: { |
||||
|
// workslrsettlementAdd |
||||
|
}, |
||||
|
data() { |
||||
|
return { |
||||
|
viewTitle: '', |
||||
|
viewState: 1, |
||||
|
activeNames: '1', |
||||
|
tableKey: 0, |
||||
|
index: 0, |
||||
|
// service服务 |
||||
|
serviceKey: 1, |
||||
|
// subjoin附加项目 |
||||
|
subjoinKey: 2, |
||||
|
// insuranceKey保险信息 |
||||
|
insuranceKey: 3, |
||||
|
formobj: { |
||||
|
sid: '', |
||||
|
registerRemarks: '', |
||||
|
billNo: '', |
||||
|
createByName: '', |
||||
|
deptName: '', |
||||
|
createDate: '', |
||||
|
billTypeKey: '', |
||||
|
billType: '', |
||||
|
subjectSid: '', |
||||
|
subject: '', |
||||
|
claimManufacturerSid: '', |
||||
|
claimManufacturer: '', |
||||
|
isGoOut: '', |
||||
|
estimatedFinishTime: '', |
||||
|
entryTime: '', |
||||
|
nodeName: '', |
||||
|
waitorName: '', |
||||
|
waitorSid: '', |
||||
|
groupSid: '', |
||||
|
groupName: '', |
||||
|
mainRepairers: '', |
||||
|
printRemarks: '', |
||||
|
remarks: '', |
||||
|
isSpecialSign: '', |
||||
|
discountAmount: '', |
||||
|
coupon: '', |
||||
|
scoreDeduct: '', |
||||
|
nodeTime: '', |
||||
|
outDoorState: '', |
||||
|
outDoorTime: '', |
||||
|
customerSid: '', |
||||
|
customerName: '', |
||||
|
mobile: '', |
||||
|
customerOrg: '', |
||||
|
customerSource: '', |
||||
|
memberCardSid: '', |
||||
|
memberCarNumber: '', |
||||
|
vehMark: '', |
||||
|
vinNo: '', |
||||
|
vehModel: '', |
||||
|
mileage: '', |
||||
|
oil: '', |
||||
|
currentMileage: '', |
||||
|
dockingPeopleSid: '', |
||||
|
dockingPeople: '', |
||||
|
dockingPhone: '', |
||||
|
invoiceVo: { |
||||
|
isInvoicing: '', |
||||
|
invoiceType: '', |
||||
|
invoiceTypeKey: '', |
||||
|
invoiceCompanySid: '', |
||||
|
invoiceCompany: '' |
||||
|
}, |
||||
|
insuranceVo: { |
||||
|
responsibility: '', |
||||
|
responsibilityKey: '', |
||||
|
isPersonInjuries: '', |
||||
|
responsibilityRatioKey: '', |
||||
|
responsibilityRatio: '', |
||||
|
insuranceList: [] |
||||
|
}, |
||||
|
sitemVos: [], |
||||
|
aitemVos: [], |
||||
|
goodsDetailsVos: [], |
||||
|
createBySid: '', |
||||
|
operatorSid: '', |
||||
|
nodeCode: '', |
||||
|
settleVo: { |
||||
|
payerNo: '', |
||||
|
payerName: '', |
||||
|
receivableAmount: '', |
||||
|
depositdeductAmount: '', |
||||
|
settleKey: '', |
||||
|
settleValue: '', |
||||
|
settleAmount: '', |
||||
|
otherSettleKey: '', |
||||
|
otherSettleValue: '', |
||||
|
debts: '', |
||||
|
settleTime: '', |
||||
|
otherSettleAmount: '' |
||||
|
}, |
||||
|
showReSettleBtn: true, |
||||
|
hourAmount: '', |
||||
|
otherAmount: '', |
||||
|
goodsAmount: '', |
||||
|
addAmount: '', |
||||
|
taxAmount: '', |
||||
|
outAmount: '', |
||||
|
subsidyAmount: '', |
||||
|
rescueAmount: '', |
||||
|
actualAmount: '', |
||||
|
receivableAmount: '', |
||||
|
subsidyRemarks: '', |
||||
|
rescueRemarks: '', |
||||
|
outRemarks: '', |
||||
|
fileName: '', |
||||
|
operator: '', |
||||
|
useOrgSid: '', |
||||
|
createOrgSid: '' |
||||
|
}, |
||||
|
rules: {} |
||||
|
} |
||||
|
}, |
||||
|
computed: { |
||||
|
// 计算工时费 = 服务项目列表中所有销售价之和 |
||||
|
gsfTotal() { |
||||
|
let gsf = '0' |
||||
|
if (this.formobj.sitemVos.length > 0) { |
||||
|
this.formobj.sitemVos.forEach((e) => { |
||||
|
if (e.serviceItem !== '') { |
||||
|
gsf = Math.round((parseFloat(gsf) + parseFloat(e.price !== '' ? e.price : '0')) * 100) / 100 |
||||
|
} |
||||
|
}) |
||||
|
} |
||||
|
return gsf |
||||
|
}, |
||||
|
// 计算材料费 = 商品列表中所有销售价 * 数量的和 |
||||
|
clfTotal() { |
||||
|
let clf = '0' |
||||
|
if (this.formobj.goodsDetailsVos.length > 0) { |
||||
|
this.formobj.goodsDetailsVos.forEach((e) => { |
||||
|
if (e.goodsSpuName !== '') { |
||||
|
clf = Math.round((parseFloat(clf) + (parseFloat(e.price !== '' ? e.price : '0') * parseFloat(e |
||||
|
.count !== '' ? e.count : '0'))) * 100) / 100 |
||||
|
} |
||||
|
}) |
||||
|
} |
||||
|
return clf |
||||
|
}, |
||||
|
// 计算附加费 == 外出费 + 厂家补助 + 施救费 + 附加项目列表中所有销售价之和 |
||||
|
fjfTotal() { |
||||
|
let fjf = '0' |
||||
|
fjf = parseFloat(this.formobj.outAmount !== '' ? this.formobj.outAmount : '0') + parseFloat(this.formobj |
||||
|
.subsidyAmount !== '' ? this.formobj.subsidyAmount : '0') + parseFloat(this.formobj.rescueAmount !== '' ? |
||||
|
this.formobj.rescueAmount : '0') |
||||
|
if (this.formobj.aitemVos.length > 0) { |
||||
|
this.formobj.aitemVos.forEach((e) => { |
||||
|
if (e.aitemName !== '') { |
||||
|
fjf = Math.round((parseFloat(fjf) + parseFloat(e.price !== '' ? e.price : '0')) * 100) / 100 |
||||
|
} |
||||
|
}) |
||||
|
} |
||||
|
return fjf |
||||
|
}, |
||||
|
// 计算应收合计 = 工时费 + 材料费 + 附加费 + 税额 |
||||
|
ysTotal() { |
||||
|
let ys = '0' |
||||
|
ys = Math.round((parseFloat(ys) + parseFloat(this.gsfTotal) + parseFloat(this.clfTotal) + parseFloat(this |
||||
|
.fjfTotal)) * 100) / 100 |
||||
|
return ys |
||||
|
}, |
||||
|
// 优惠 = 服务项目列表中的所有优惠之和 + 商品列表中所有优惠之和 |
||||
|
yhTotal() { |
||||
|
let yh = '0' |
||||
|
if (this.formobj.sitemVos.length > 0) { |
||||
|
this.formobj.sitemVos.forEach((e) => { |
||||
|
if (e.serviceItem !== '') { |
||||
|
yh = Math.round((parseFloat(yh) + parseFloat(e.discountAmount !== '' ? e.discountAmount : '0')) * |
||||
|
100) / 100 |
||||
|
} |
||||
|
}) |
||||
|
} |
||||
|
if (this.formobj.goodsDetailsVos.length > 0) { |
||||
|
this.formobj.goodsDetailsVos.forEach((e) => { |
||||
|
if (e.goodsSpuName !== '') { |
||||
|
yh = Math.round((parseFloat(yh) + parseFloat(e.discountAmount !== '' ? e.discountAmount : '0')) * |
||||
|
100) / 100 |
||||
|
} |
||||
|
}) |
||||
|
} |
||||
|
return yh |
||||
|
}, |
||||
|
// 计算实收合计 = 应收合计 - 优惠 |
||||
|
ssTotal() { |
||||
|
let ysje = '0' |
||||
|
ysje = Math.round((parseFloat(ysje) + parseFloat(this.ysTotal) - parseFloat(this.yhTotal)) * 100) / 100 |
||||
|
return ysje |
||||
|
} |
||||
|
}, |
||||
|
methods: { |
||||
|
showInfo(sid) { |
||||
|
this.viewTitle = '维修单详情' |
||||
|
this.$nextTick(() => { |
||||
|
this.$refs['form_obj'].clearValidate() |
||||
|
}) |
||||
|
req.fetchBySid(sid).then((res) => { |
||||
|
if (res.success) { |
||||
|
this.formobj = res.data |
||||
|
if (this.formobj.sitemVos.length > 0) { |
||||
|
this.formobj.sitemVos.forEach((e) => { |
||||
|
if (e.staffNameList.length > 0) { |
||||
|
e.repairerName = e.staffNameList.join(',') |
||||
|
} |
||||
|
}) |
||||
|
} |
||||
|
} |
||||
|
}) |
||||
|
}, |
||||
|
resetState() { |
||||
|
this.viewState = 1 |
||||
|
}, |
||||
|
negativeSettlement() { |
||||
|
this.viewState = 2 |
||||
|
this.$refs['divFJS'].showAdd(this.formobj.sid) |
||||
|
}, |
||||
|
handleReturn() { |
||||
|
this.formobj = { |
||||
|
sid: '', |
||||
|
registerRemarks: '', |
||||
|
billNo: '', |
||||
|
createByName: '', |
||||
|
deptName: '', |
||||
|
createDate: '', |
||||
|
billTypeKey: '', |
||||
|
billType: '', |
||||
|
subjectSid: '', |
||||
|
subject: '', |
||||
|
claimManufacturerSid: '', |
||||
|
claimManufacturer: '', |
||||
|
isGoOut: '', |
||||
|
estimatedFinishTime: '', |
||||
|
entryTime: '', |
||||
|
nodeName: '', |
||||
|
waitorName: '', |
||||
|
waitorSid: '', |
||||
|
groupSid: '', |
||||
|
groupName: '', |
||||
|
mainRepairers: '', |
||||
|
printRemarks: '', |
||||
|
remarks: '', |
||||
|
isSpecialSign: '', |
||||
|
discountAmount: '', |
||||
|
coupon: '', |
||||
|
scoreDeduct: '', |
||||
|
nodeTime: '', |
||||
|
outDoorState: '', |
||||
|
outDoorTime: '', |
||||
|
customerSid: '', |
||||
|
customerName: '', |
||||
|
mobile: '', |
||||
|
customerOrg: '', |
||||
|
customerSource: '', |
||||
|
memberCardSid: '', |
||||
|
memberCarNumber: '', |
||||
|
vehMark: '', |
||||
|
vinNo: '', |
||||
|
vehModel: '', |
||||
|
mileage: '', |
||||
|
oil: '', |
||||
|
currentMileage: '', |
||||
|
dockingPeopleSid: '', |
||||
|
dockingPeople: '', |
||||
|
dockingPhone: '', |
||||
|
invoiceVo: { |
||||
|
isInvoicing: '', |
||||
|
invoiceType: '', |
||||
|
invoiceTypeKey: '', |
||||
|
invoiceCompanySid: '', |
||||
|
invoiceCompany: '' |
||||
|
}, |
||||
|
insuranceVo: { |
||||
|
responsibility: '', |
||||
|
responsibilityKey: '', |
||||
|
isPersonInjuries: '', |
||||
|
responsibilityRatioKey: '', |
||||
|
responsibilityRatio: '', |
||||
|
insuranceList: [] |
||||
|
}, |
||||
|
sitemVos: [], |
||||
|
aitemVos: [], |
||||
|
goodsDetailsVos: [], |
||||
|
createBySid: '', |
||||
|
operatorSid: '', |
||||
|
nodeCode: '', |
||||
|
settleVo: { |
||||
|
payerNo: '', |
||||
|
payerName: '', |
||||
|
receivableAmount: '', |
||||
|
depositdeductAmount: '', |
||||
|
settleKey: '', |
||||
|
settleValue: '', |
||||
|
settleAmount: '', |
||||
|
otherSettleKey: '', |
||||
|
otherSettleValue: '', |
||||
|
debts: '', |
||||
|
settleTime: '', |
||||
|
otherSettleAmount: '' |
||||
|
}, |
||||
|
showReSettleBtn: true, |
||||
|
hourAmount: '', |
||||
|
otherAmount: '', |
||||
|
goodsAmount: '', |
||||
|
addAmount: '', |
||||
|
taxAmount: '', |
||||
|
outAmount: '', |
||||
|
subsidyAmount: '', |
||||
|
rescueAmount: '', |
||||
|
actualAmount: '', |
||||
|
receivableAmount: '', |
||||
|
subsidyRemarks: '', |
||||
|
rescueRemarks: '', |
||||
|
outRemarks: '', |
||||
|
fileName: '', |
||||
|
operator: '', |
||||
|
useOrgSid: '', |
||||
|
createOrgSid: '' |
||||
|
} |
||||
|
this.$emit('doback') |
||||
|
} |
||||
|
} |
||||
|
} |
||||
|
</script> |
||||
|
|
||||
|
<style scoped> |
||||
|
.span-sty { |
||||
|
width: 130px !important; |
||||
|
} |
||||
|
|
||||
|
.addinputInfo { |
||||
|
margin-left: 120px !important; |
||||
|
} |
||||
|
|
||||
|
.span-sty-one { |
||||
|
width: 180px !important; |
||||
|
} |
||||
|
|
||||
|
.addinputInfo-one { |
||||
|
margin-left: 170px !important; |
||||
|
} |
||||
|
</style> |
@ -0,0 +1,389 @@ |
|||||
|
<template> |
||||
|
<div class="app-container"> |
||||
|
<div v-show="viewState == 1"> |
||||
|
<div class="tab-header webtop"> |
||||
|
<div>{{ viewTitle }}</div> |
||||
|
<div> |
||||
|
<el-button type="info" size="small" @click="handleReturn()">关闭</el-button> |
||||
|
</div> |
||||
|
</div> |
||||
|
<div class="listconadd"> |
||||
|
<el-form ref="form_obj" :model="formobj" :rules="rules" class="formaddcopy02"> |
||||
|
<el-row style="border-top: 1px solid #e0e3eb"> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">申请部门</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.deptName }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">申请人</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.createByName }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">申请日期</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.createTime }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">采购方式</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.purchaseTypeValue }}<span |
||||
|
v-show="formobj.purchaseTypeValue == '代理库'" |
||||
|
style="margin-left: 20px">{{ formobj.operateBrandValue }}</span></span></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">采购原因</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.purchaseReasonValue }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">付款方式</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.payTypeValue }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">供应商</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.supplierName }}<span |
||||
|
v-show="formobj.purchaseTypeValue == '代理库'" |
||||
|
style="margin-left: 20px">{{ formobj.warehouseTypeValue }}</span></span></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">是否开发票</div> |
||||
|
<el-form-item><span |
||||
|
class="addinputInfo">{{ formobj.purchaseBillInvoice.isInvoicing == '1' ? '是' : '否' }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="8"> |
||||
|
<div v-show="formobj.purchaseBillInvoice.isInvoicing == '1'"> |
||||
|
<div class="span-sty">发票类型(税率)</div> |
||||
|
<el-form-item><span |
||||
|
class="addinputInfo">{{ formobj.purchaseBillInvoice.billType }}{{ formobj.purchaseBillInvoice.taxRate == '' ? '' : '(' + formobj.purchaseBillInvoice.taxRate + '%)' }}</span></el-form-item> |
||||
|
</div> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row v-show="formobj.payTypeValue == '预付款'"> |
||||
|
<el-col :span="24"> |
||||
|
<div class="span-sty">预付款情况</div> |
||||
|
<el-form-item><span class="addinputInfo">当前预付款项金额(元):{{ formobj.prepaymentAmount }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row v-show="formobj.payTypeValue == '月结'"> |
||||
|
<el-col :span="24"> |
||||
|
<div class="span-sty">月结欠款情况</div> |
||||
|
<el-form-item><span class="addinputInfo">累计欠款金额(元):{{ formobj.owedAmount }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="16"> |
||||
|
<div class="span-sty">备注</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.remarks }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">预计到货日期</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.deliveryDate }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<div v-if="formobj.payTypeValue == '单笔付款'"> |
||||
|
<div class="title">订金及付款申请</div> |
||||
|
<el-row> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">是否先付货款</div> |
||||
|
<el-form-item><span |
||||
|
class="addinputInfo">{{ formobj.purchasePay.isFirstPay == '1' ? '是' : '否' }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="8" v-if="formobj.purchasePay.isFirstPay == '0'"> |
||||
|
<div class="span-sty">审批通过后付订金</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.purchasePay.deposit }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="8" v-if="formobj.purchasePay.isFirstPay == '0'"> |
||||
|
<div class="span-sty">验货后付货款</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.purchasePay.goodsMoney }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="16" v-else> |
||||
|
<div class="span-sty">审批通过后付货款</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.purchasePay.goodsMoney }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">收款账户名称</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.purchasePay.accountName }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">开户行</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.purchasePay.bankName }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">银行账号</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.purchasePay.bankAccount }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="16"> |
||||
|
<div class="span-sty">其他费用名称</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.purchasePay.otherAmountName }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">其他费用合计</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.purchasePay.otherAmount }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="24"> |
||||
|
<div class="span-sty">付款备注</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.purchasePay.payRemark }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="24"> |
||||
|
<div class="span-sty">附件</div> |
||||
|
<el-form-item><el-image class="addinputInfo" style="width: 150px;height: 150px" |
||||
|
v-for="(item, index) in formobj.purchasePay.filePaths" :key="index" :src="item" |
||||
|
:preview-src-list="formobj.purchasePay.filePaths" /></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
</div> |
||||
|
<div class="title ">商品列表</div> |
||||
|
<el-table :key="tableKey" :data="formobj.pmsPurchaseBillDetailList" :index="index" border style="width: 100%"> |
||||
|
<el-table-column fixed width="60" label="序号" type="index" :index="index + 1" align="center" /> |
||||
|
<el-table-column prop="goodsSpuName" label="商品名称" align="center" width="300" /> |
||||
|
<el-table-column prop="goodsSkuCode" label="图号" align="center" width="200" /> |
||||
|
<el-table-column prop="goodsSkuOwnSpec" label="规格" align="center" width="200" /> |
||||
|
<el-table-column prop="unit" label="单位" align="center" width="100" /> |
||||
|
<el-table-column prop="count" label="采购数量" align="center" width="150" /> |
||||
|
<el-table-column prop="taxPrice" v-if="formobj.purchaseBillInvoice.isInvoicing == '1'" label="含税单价(元)" |
||||
|
align="center" min-width="150" /> |
||||
|
<el-table-column prop="taxPrice" v-else label="不含税单价(元)" align="center" min-width="150" /> |
||||
|
<el-table-column prop="amount" label="采购金额(元)" align="center" width="200" /> |
||||
|
</el-table> |
||||
|
<el-row> |
||||
|
<el-col :span="24"> |
||||
|
<div class="span-sty" style="border-right: 0px">数量:</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ slTotal }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="24"> |
||||
|
<div class="span-sty" style="border-right: 0px">应付金额:</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ yfTotal }} = 采购金额:{{ cgTotal }} + 运费:{{ formobj.freight }} - |
||||
|
优惠:{{ formobj.discountAmount }} + 误差调整:{{ formobj.errorAmount }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
</el-form> |
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
</template> |
||||
|
|
||||
|
<script> |
||||
|
import req from '@/api/purchase/procurement' |
||||
|
|
||||
|
export default { |
||||
|
name: 'ProcurementInfo', |
||||
|
data() { |
||||
|
return { |
||||
|
viewTitle: '', |
||||
|
viewState: 1, |
||||
|
tableKey: 1, |
||||
|
index: 0, |
||||
|
formobj: { |
||||
|
sid: '', |
||||
|
remarks: '', |
||||
|
createBySid: '', |
||||
|
createByName: '', |
||||
|
createTime: '', |
||||
|
sourceBillSid: '', |
||||
|
sourceBillNo: '', |
||||
|
billNo: '', |
||||
|
purchaseTypeKey: '', |
||||
|
purchaseTypeValue: '', |
||||
|
purchaseReasonKey: '', |
||||
|
purchaseReasonValue: '', |
||||
|
payTypeKey: '', |
||||
|
payTypeValue: '', |
||||
|
errorAmount: '', |
||||
|
supplierSid: '', |
||||
|
supplierName: '', |
||||
|
supplierPhone: '', |
||||
|
purchaserSid: '', |
||||
|
purchaserName: '', |
||||
|
deliveryDate: '', |
||||
|
freight: '', |
||||
|
discountAmount: '', |
||||
|
payableAmount: '', |
||||
|
prepaymentAmount: '', |
||||
|
owedAmount: '', |
||||
|
deptSid: '', |
||||
|
deptName: '', |
||||
|
procDefId: '', |
||||
|
nodeId: '', |
||||
|
procInstId: '', |
||||
|
nodeState: '', |
||||
|
taskId: '', |
||||
|
finishTime: '', |
||||
|
useOrgSid: '', |
||||
|
useOrgName: '', |
||||
|
createOrgSid: '', |
||||
|
createOrgName: '', |
||||
|
operateBrandKey: '', |
||||
|
operateBrandValue: '', |
||||
|
warehouseTypeKey: '', |
||||
|
warehouseTypeValue: '', |
||||
|
purchasePay: { |
||||
|
sid: '', |
||||
|
billSid: '', |
||||
|
isFirstPay: '', |
||||
|
deposit: '', |
||||
|
goodsMoney: '', |
||||
|
accountName: '', |
||||
|
bankName: '', |
||||
|
bankAccount: '', |
||||
|
otherAmountName: '', |
||||
|
otherAmount: '', |
||||
|
payRemark: '', |
||||
|
filePaths: [] |
||||
|
}, |
||||
|
purchaseBillInvoice: { |
||||
|
billSid: '', |
||||
|
isInvoicing: '', |
||||
|
billTypeKey: '', |
||||
|
billType: '', |
||||
|
taxRate: '' |
||||
|
}, |
||||
|
pmsPurchaseBillDetailList: [] |
||||
|
}, |
||||
|
rules: {} |
||||
|
} |
||||
|
}, |
||||
|
computed: { |
||||
|
// 数量 |
||||
|
slTotal() { |
||||
|
let sl = '0' |
||||
|
if (this.formobj.pmsPurchaseBillDetailList.length > 0) { |
||||
|
this.formobj.pmsPurchaseBillDetailList.forEach((e) => { |
||||
|
if (e.goodsSpuName !== '') { |
||||
|
sl = Math.round((parseFloat(sl) + parseFloat(e.count !== '' ? e.count : '0')) * 100) / 100 |
||||
|
} |
||||
|
}) |
||||
|
} |
||||
|
return sl |
||||
|
}, |
||||
|
// 采购金额 |
||||
|
cgTotal() { |
||||
|
let cg = '0' |
||||
|
if (this.formobj.pmsPurchaseBillDetailList.length > 0) { |
||||
|
this.formobj.pmsPurchaseBillDetailList.forEach((e) => { |
||||
|
if (e.goodsSpuName !== '') { |
||||
|
cg = Math.round((parseFloat(cg) + parseFloat(e.amount !== '' ? e.amount : '0')) * 100) / 100 |
||||
|
} |
||||
|
}) |
||||
|
} |
||||
|
return cg |
||||
|
}, |
||||
|
yfTotal() { |
||||
|
let yf = '0' |
||||
|
yf = Math.round((parseFloat(yf) + parseFloat(this.cgTotal) + parseFloat(this.formobj.freight !== '' ? this |
||||
|
.formobj.freight : '0') - parseFloat(this.formobj.discountAmount !== '' ? this.formobj.discountAmount : |
||||
|
'0') + parseFloat(this.formobj.errorAmount !== '' ? this.formobj.errorAmount : '0')) * 100) / 100 |
||||
|
return yf |
||||
|
} |
||||
|
}, |
||||
|
methods: { |
||||
|
showInfo(sid) { |
||||
|
this.viewTitle = '采购单详情' |
||||
|
this.$nextTick(() => { |
||||
|
this.$refs['form_obj'].clearValidate() |
||||
|
}) |
||||
|
req.fetchDetailsBySid(sid).then((res) => { |
||||
|
if (res.success) { |
||||
|
this.formobj = res.data |
||||
|
if (this.formobj.purchasePay.filePaths.length > 0) { |
||||
|
const aa = [] |
||||
|
this.formobj.purchasePay.filePaths.forEach((e) => { |
||||
|
aa.push(e.url) |
||||
|
}) |
||||
|
this.formobj.purchasePay.filePaths = aa |
||||
|
} |
||||
|
} |
||||
|
}) |
||||
|
}, |
||||
|
handleReturn() { |
||||
|
this.formobj = { |
||||
|
sid: '', |
||||
|
remarks: '', |
||||
|
createBySid: '', |
||||
|
createByName: '', |
||||
|
createTime: '', |
||||
|
sourceBillSid: '', |
||||
|
sourceBillNo: '', |
||||
|
billNo: '', |
||||
|
purchaseTypeKey: '', |
||||
|
purchaseTypeValue: '', |
||||
|
purchaseReasonKey: '', |
||||
|
purchaseReasonValue: '', |
||||
|
payTypeKey: '', |
||||
|
payTypeValue: '', |
||||
|
errorAmount: '', |
||||
|
supplierSid: '', |
||||
|
supplierName: '', |
||||
|
supplierPhone: '', |
||||
|
purchaserSid: '', |
||||
|
purchaserName: '', |
||||
|
deliveryDate: '', |
||||
|
freight: '', |
||||
|
discountAmount: '', |
||||
|
payableAmount: '', |
||||
|
prepaymentAmount: '', |
||||
|
owedAmount: '', |
||||
|
deptSid: '', |
||||
|
deptName: '', |
||||
|
procDefId: '', |
||||
|
nodeId: '', |
||||
|
procInstId: '', |
||||
|
nodeState: '', |
||||
|
taskId: '', |
||||
|
finishTime: '', |
||||
|
useOrgSid: '', |
||||
|
useOrgName: '', |
||||
|
createOrgSid: '', |
||||
|
createOrgName: '', |
||||
|
operateBrandKey: '', |
||||
|
operateBrandValue: '', |
||||
|
warehouseTypeKey: '', |
||||
|
warehouseTypeValue: '', |
||||
|
purchasePay: { |
||||
|
sid: '', |
||||
|
billSid: '', |
||||
|
isFirstPay: '', |
||||
|
deposit: '', |
||||
|
goodsMoney: '', |
||||
|
accountName: '', |
||||
|
bankName: '', |
||||
|
bankAccount: '', |
||||
|
otherAmountName: '', |
||||
|
otherAmount: '', |
||||
|
payRemark: '', |
||||
|
filePaths: [] |
||||
|
}, |
||||
|
purchaseBillInvoice: { |
||||
|
billSid: '', |
||||
|
isInvoicing: '', |
||||
|
billTypeKey: '', |
||||
|
billType: '', |
||||
|
taxRate: '' |
||||
|
}, |
||||
|
pmsPurchaseBillDetailList: [] |
||||
|
} |
||||
|
this.$emit('doback') |
||||
|
} |
||||
|
} |
||||
|
} |
||||
|
</script> |
||||
|
|
||||
|
<style scoped> |
||||
|
.span-sty { |
||||
|
width: 130px !important; |
||||
|
} |
||||
|
|
||||
|
.addinputInfo { |
||||
|
margin-left: 120px !important; |
||||
|
} |
||||
|
</style> |
@ -0,0 +1,413 @@ |
|||||
|
<template> |
||||
|
<div class="app-container"> |
||||
|
<div v-show="viewState == 1"> |
||||
|
<div class="tab-header webtop"> |
||||
|
<div>{{ viewTitle }}</div> |
||||
|
<div> |
||||
|
<el-button type="primary" size="small" @click="openCountersign('加签')">加 签</el-button> |
||||
|
<el-button type="primary" size="small" @click="openAgree('同意')">同 意</el-button> |
||||
|
<el-button type="danger" size="small" @click="openReject('驳回')">驳 回</el-button> |
||||
|
<el-button type="danger" size="small" @click="openStop('终止')">终 止</el-button> |
||||
|
</div> |
||||
|
</div> |
||||
|
<div class=""> |
||||
|
<el-form ref="form_obj" :model="formobj" :rules="rules" class="formaddcopy02"> |
||||
|
<el-row style="border-top: 1px solid #e0e3eb"> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">申请部门</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.deptName }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">申请人</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.createByName }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">申请日期</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.createTime }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="24"> |
||||
|
<div class="span-sty">备注</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.remarks }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="24"> |
||||
|
<div class="span-sty">附件</div> |
||||
|
<el-form-item><el-image class="addinputInfo" style="width: 150px;height: 150px" v-for="(item, index) in formobj.file" :key="index" :src="item" :preview-src-list="formobj.file" /></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<div class="title">开票索赔单列表</div> |
||||
|
<el-table :key="tableKey" :data="formobj.sitemsVos" :index="index" border style="width: 100%"> |
||||
|
<el-table-column fixed width="60" label="序号" type="index" :index="index + 1" align="center"/> |
||||
|
<el-table-column prop="sitemName" label="项目名称" align="center" width="170" /> |
||||
|
<el-table-column prop="serviceType" label="工种" align="center" width="170" /> |
||||
|
<el-table-column prop="subjectName" label="科目" align="center" width="100" /> |
||||
|
<el-table-column prop="hourPrice" label="工时单价" align="center" width="100" /> |
||||
|
<el-table-column prop="hours" label="工时数" align="center" width="100" /> |
||||
|
<el-table-column prop="cost" label="外协成本" align="center" width="120" /> |
||||
|
<el-table-column prop="price" label="销售价" align="center" width="120" /> |
||||
|
<el-table-column prop="examineHourPrice" label="工时提成" align="center" width="120" /> |
||||
|
<el-table-column prop="remarks" label="备注" align="center" min-width="200" /> |
||||
|
<el-table-column label="预约项目" align="center" width="120"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span>{{ scope.row.isReserve == '1' ? '是' : scope.row.isReserve == '0' ? '否' : '' }}</span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="洗车项目" align="center" width="120"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span>{{ scope.row.isClean == '1' ? '是' : scope.row.isClean == '0' ? '否' : '' }}</span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
</el-table> |
||||
|
</el-form> |
||||
|
</div> |
||||
|
</div> |
||||
|
<!-- 选择待办人 的弹出框--> |
||||
|
<el-dialog title="填写审批意见" :visible.sync="nodeDialogVisible" width="80%"> |
||||
|
<el-form class="formadd" > |
||||
|
<el-row v-show="countersignLink" style="border-top: 1px solid #e0e3eb"> |
||||
|
<el-col :span="4" class="tleftb"> |
||||
|
<span class="icon">*</span>加签人员: |
||||
|
</el-col> |
||||
|
<el-col :span="20"> |
||||
|
<el-form-item> |
||||
|
<el-select v-model="countersign.assignee" placeholder="请选择" filterable> |
||||
|
<el-option v-for="item in options" :key="item.userSid" :label="item.staffName" :value="item.userSid"> |
||||
|
</el-option> |
||||
|
</el-select> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row v-show="currentLink" style="border-top: 1px solid #e0e3eb"> |
||||
|
<el-col :span="4" class="tleftb"> |
||||
|
<span>当前环节:</span> |
||||
|
</el-col> |
||||
|
<el-col :span="20"> |
||||
|
<el-form-item><span>{{ current.taskName }}->{{ nextNode.name }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row :class="{rowClass:!currentLink}"> |
||||
|
<el-col :span="4" class="tleftb"> |
||||
|
<span>意见:</span> |
||||
|
</el-col> |
||||
|
<el-col :span="20"> |
||||
|
<el-form-item><el-input size="small" v-model="dialogList.comment" placeholder="审批意见" class="addinputw" type="textarea" :autosize="{ minRows: 1, maxRows: 10}" clearable ></el-input></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<div style="text-align:center;margin-top: 20px;"> |
||||
|
<el-button type="primary" size="mini" @click="reject">确 定</el-button> |
||||
|
<el-button type="info " size="mini" @click="nodeDialogVisible = false">取 消</el-button> |
||||
|
</div> |
||||
|
</el-form> |
||||
|
</el-dialog> |
||||
|
</div> |
||||
|
</template> |
||||
|
|
||||
|
<script> |
||||
|
import req from '@/api/basicinformation/maintenanceProjectRecord' |
||||
|
import { selectStaffListss } from '@/api/Common/dictcommons' |
||||
|
|
||||
|
export default { |
||||
|
name: 'MaintenanceProjectRecordDaiBan', |
||||
|
data() { |
||||
|
return { |
||||
|
viewTitle: '', |
||||
|
viewState: 1, |
||||
|
tableKey: 1, |
||||
|
index: 0, |
||||
|
formobj: { |
||||
|
createByName: '', |
||||
|
createBySid: '', |
||||
|
createOrgName: '', |
||||
|
createOrgSid: '', |
||||
|
createTime: '', |
||||
|
deptName: '', |
||||
|
deptSid: '', |
||||
|
file: [], |
||||
|
instanceId: '', |
||||
|
sid: '', |
||||
|
sitemsVos: [], |
||||
|
taskId: '', |
||||
|
useOrgName: '', |
||||
|
useOrgSid: '' |
||||
|
}, |
||||
|
rules: {}, |
||||
|
options: [], |
||||
|
operation: '', // 点击操作按钮 |
||||
|
dialogList: { |
||||
|
comment: '' |
||||
|
}, |
||||
|
startTask: true, |
||||
|
current: { |
||||
|
taskDefKey: '', |
||||
|
taskName: '' // 当前环节名称 |
||||
|
}, |
||||
|
nextNode: {}, // 下一环节 |
||||
|
nodeDialogVisible: false, |
||||
|
currentLink: true, |
||||
|
countersignLink: false, |
||||
|
// 环节所需参数 |
||||
|
linkByParameter: { |
||||
|
businessSid: '', |
||||
|
comment: '', |
||||
|
instanceId: '', |
||||
|
taskId: '', |
||||
|
orgSidPath: '', |
||||
|
taskDefKey: '', |
||||
|
userSid: '' |
||||
|
}, |
||||
|
// 加签按钮所需参数 |
||||
|
countersign: { |
||||
|
taskId: '', |
||||
|
assignee: '', |
||||
|
userSid: '', |
||||
|
instanceId: '', |
||||
|
views: '' |
||||
|
} |
||||
|
} |
||||
|
}, |
||||
|
created() { |
||||
|
console.log('url:' + window.location.href) |
||||
|
var one = window.location.href.indexOf('&data') + 6 |
||||
|
const data = window.location.href.substr(one) // url解码unescape()已从web中移除,尽量不使用 |
||||
|
const obj = JSON.parse(decodeURIComponent(data)) |
||||
|
console.log('iframe页面获取的obj:', obj) |
||||
|
// 点击(同意、终止、驳回、驳回)操作时所需的参数 |
||||
|
this.linkByParameter.businessSid = obj.businessSid |
||||
|
this.linkByParameter.instanceId = obj.instanceId |
||||
|
this.linkByParameter.taskId = obj.taskId |
||||
|
this.linkByParameter.taskDefKey = obj.taskDefKey |
||||
|
// this.linkByParameter.orgSidPath = window.sessionStorage.getItem('orgSidPath') |
||||
|
this.linkByParameter.userSid = window.sessionStorage.getItem('userSid') |
||||
|
this.current.taskDefKey = obj.taskDefKey |
||||
|
this.current.taskName = obj.taskName |
||||
|
// 加签参数 |
||||
|
this.countersign.taskId = obj.taskId |
||||
|
this.countersign.userSid = window.sessionStorage.getItem('userSid') |
||||
|
this.countersign.instanceId = obj.instanceId |
||||
|
// 加载表单数据 |
||||
|
this.showInfo(obj.businessSid) |
||||
|
}, |
||||
|
mounted() { |
||||
|
window.parent.postMessage({ |
||||
|
cmd: 'returnHeight', |
||||
|
params: { |
||||
|
// 告诉父级页面,子页面的弹框高度。 |
||||
|
code: 2, |
||||
|
data: 400 + 'px' |
||||
|
} |
||||
|
}, '*') |
||||
|
}, |
||||
|
methods: { |
||||
|
showInfo(sid) { |
||||
|
this.viewTitle = '维修项目备案申请详情' |
||||
|
this.$nextTick(() => { |
||||
|
this.$refs['form_obj'].clearValidate() |
||||
|
}) |
||||
|
req.fetchDetailsBySid(sid).then((res) => { |
||||
|
if (res.success) { |
||||
|
this.formobj = res.data |
||||
|
if (this.formobj.file.length > 0) { |
||||
|
const aa = [] |
||||
|
this.formobj.file.forEach((e) => { |
||||
|
aa.push(e.url) |
||||
|
}) |
||||
|
this.formobj.file = aa |
||||
|
} |
||||
|
} |
||||
|
}) |
||||
|
selectStaffListss().then((res) => { |
||||
|
if (res.success) { |
||||
|
this.options = res.data |
||||
|
} |
||||
|
}) |
||||
|
}, |
||||
|
// 加签 |
||||
|
openCountersign(val) { |
||||
|
this.operation = val |
||||
|
this.currentLink = true |
||||
|
this.countersignLink = true |
||||
|
this.dialogList.comment = '' |
||||
|
req.getNextNodesForSubmit({ taskDefKey: this.current.taskDefKey, businessSid: this.linkByParameter.businessSid }).then((resp) => { |
||||
|
if (resp.success) { |
||||
|
var arr = resp.data |
||||
|
this.nextNode = arr[0] |
||||
|
this.nodeDialogVisible = true |
||||
|
} |
||||
|
this.submitdisabled = false |
||||
|
}) |
||||
|
}, |
||||
|
// 同意 |
||||
|
openAgree(val) { |
||||
|
this.operation = val |
||||
|
this.currentLink = true |
||||
|
this.countersignLink = false |
||||
|
this.dialogList.comment = '同意' |
||||
|
req.getNextNodesForSubmit({ taskDefKey: this.current.taskDefKey, businessSid: this.linkByParameter.businessSid }).then((resp) => { |
||||
|
if (resp.success) { |
||||
|
var arr = resp.data |
||||
|
this.nextNode = arr[0] |
||||
|
this.nodeDialogVisible = true |
||||
|
} |
||||
|
this.submitdisabled = false |
||||
|
}) |
||||
|
}, |
||||
|
// 驳回 |
||||
|
openReject(val) { |
||||
|
this.operation = val |
||||
|
this.currentLink = true |
||||
|
this.countersignLink = false |
||||
|
this.dialogList.comment = '' |
||||
|
req.getPreviousNodesForReject({ taskDefKey: this.current.taskDefKey, businessSid: this.linkByParameter.businessSid }).then((resp) => { |
||||
|
if (resp.success) { |
||||
|
var arr = resp.data |
||||
|
this.nextNode = arr[0] |
||||
|
this.nodeDialogVisible = true |
||||
|
} |
||||
|
this.submitdisabled = false |
||||
|
}) |
||||
|
}, |
||||
|
// 终止 |
||||
|
openStop(val) { |
||||
|
this.operation = val |
||||
|
this.currentLink = false |
||||
|
this.countersignLink = false |
||||
|
this.dialogList.comment = '' |
||||
|
this.nodeDialogVisible = true |
||||
|
}, |
||||
|
reject() { |
||||
|
if (this.operation === '同意') { |
||||
|
this.handleAgree() |
||||
|
} else if (this.operation === '驳回') { |
||||
|
if (this.dialogList.comment === '') { |
||||
|
this.$message({ showClose: true, type: 'error', message: '请填写审批意见' }) |
||||
|
} else { |
||||
|
this.handleReject() |
||||
|
} |
||||
|
} else if (this.operation === '终止') { |
||||
|
if (this.dialogList.comment === '') { |
||||
|
this.$message({ showClose: true, type: 'error', message: '请填写审批意见' }) |
||||
|
} else { |
||||
|
this.handleStop() |
||||
|
} |
||||
|
} else if (this.operation === '加签') { |
||||
|
this.handleCountersign() |
||||
|
} |
||||
|
}, |
||||
|
/** 加签 */ |
||||
|
handleCountersign() { |
||||
|
if (this.countersign.assignee === '') { |
||||
|
this.$message({ showClose: true, type: 'error', message: '请选择加签人员' }) |
||||
|
return |
||||
|
} |
||||
|
if (this.dialogList.comment === '') { |
||||
|
this.$message({ showClose: true, type: 'error', message: '请填写审批意见' }) |
||||
|
return |
||||
|
} |
||||
|
this.countersign.views = this.dialogList.comment |
||||
|
req.delegate(this.countersign).then((response) => { |
||||
|
if (response.success) { |
||||
|
this.$notify({ |
||||
|
title: '提示', |
||||
|
message: '执行成功', |
||||
|
type: 'success', |
||||
|
duration: 2000 |
||||
|
}) |
||||
|
this.nodeDialogVisible = false |
||||
|
// 子页面向父级页面传递值 |
||||
|
window.parent.postMessage({ |
||||
|
cmd: 'returnHeight', |
||||
|
params: { |
||||
|
// 操作成功,告诉父级页面关闭弹框 |
||||
|
code: 1 |
||||
|
} |
||||
|
}, '*') |
||||
|
} |
||||
|
}) |
||||
|
}, |
||||
|
/** 同意任务 */ |
||||
|
handleAgree() { |
||||
|
this.linkByParameter.comment = this.dialogList.comment |
||||
|
req.complete(this.linkByParameter).then((response) => { |
||||
|
if (response.success) { |
||||
|
this.$notify({ |
||||
|
title: '提示', |
||||
|
message: '执行成功', |
||||
|
type: 'success', |
||||
|
duration: 2000 |
||||
|
}) |
||||
|
this.nodeDialogVisible = false |
||||
|
// 子页面向父级页面传递值 |
||||
|
window.parent.postMessage({ |
||||
|
cmd: 'returnHeight', |
||||
|
params: { |
||||
|
// 操作成功,告诉父级页面关闭弹框 |
||||
|
code: 1 |
||||
|
} |
||||
|
}, '*') |
||||
|
} |
||||
|
}) |
||||
|
}, |
||||
|
/** 驳回任务 */ |
||||
|
handleReject() { |
||||
|
this.linkByParameter.comment = this.dialogList.comment |
||||
|
req.reject(this.linkByParameter).then((response) => { |
||||
|
if (response.success) { |
||||
|
this.$notify({ |
||||
|
title: '提示', |
||||
|
message: '执行成功', |
||||
|
type: 'success', |
||||
|
duration: 2000 |
||||
|
}) |
||||
|
this.nodeDialogVisible = false |
||||
|
// 子页面向父级页面传递值 |
||||
|
window.parent.postMessage({ |
||||
|
cmd: 'returnHeight', |
||||
|
params: { |
||||
|
// 操作成功,告诉父级页面关闭弹框 |
||||
|
code: 1 |
||||
|
} |
||||
|
}, '*') |
||||
|
} |
||||
|
}) |
||||
|
}, |
||||
|
/** 终止任务 */ |
||||
|
handleStop() { |
||||
|
this.linkByParameter.comment = this.dialogList.comment |
||||
|
req.breakProcess(this.linkByParameter).then((response) => { |
||||
|
if (response.success) { |
||||
|
this.$notify({ |
||||
|
title: '提示', |
||||
|
message: '执行成功', |
||||
|
type: 'success', |
||||
|
duration: 2000 |
||||
|
}) |
||||
|
this.nodeDialogVisible = false |
||||
|
// 子页面向父级页面传递值 |
||||
|
window.parent.postMessage({ |
||||
|
cmd: 'returnHeight', |
||||
|
params: { |
||||
|
// 操作成功,告诉父级页面关闭弹框 |
||||
|
code: 1 |
||||
|
} |
||||
|
}, '*') |
||||
|
} |
||||
|
}) |
||||
|
} |
||||
|
} |
||||
|
} |
||||
|
</script> |
||||
|
|
||||
|
<style scoped> |
||||
|
.span-sty { |
||||
|
width: 130px !important; |
||||
|
} |
||||
|
.addinputInfo { |
||||
|
margin-left: 120px !important; |
||||
|
} |
||||
|
.rowClass{ |
||||
|
border-top: 1px solid #E0E3EB; |
||||
|
} |
||||
|
</style> |
@ -0,0 +1,196 @@ |
|||||
|
<template> |
||||
|
<div class="app-container"> |
||||
|
<div v-show="viewState == 1"> |
||||
|
<div class="tab-header webtop"> |
||||
|
<div>{{ viewTitle }}</div> |
||||
|
<div> |
||||
|
<el-button type="primary" size="small" :disabled="submitdisabled" @click="saveOrUpdate()">保存</el-button> |
||||
|
<el-button type="primary" size="small" :disabled="submitdisabled" @click="submit()">提交</el-button> |
||||
|
</div> |
||||
|
</div> |
||||
|
<div class=""> |
||||
|
<el-form ref="form_obj" :model="formobj" :rules="rules" class="formaddcopy02"> |
||||
|
<el-row style="border-top: 1px solid #e0e3eb"> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">申请部门</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.deptName }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">申请人</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.createByName }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">申请日期</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.createTime }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="24"> |
||||
|
<div class="span-sty">备注</div> |
||||
|
<el-form-item><el-input class="addinputInfo" style="width: 80%" v-model="formobj.remarks" clearable placeholder="" /></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="24"> |
||||
|
<div class="span-sty">附件</div> |
||||
|
<el-form-item> |
||||
|
<uploadImg ref="uploadImg" class="addinputInfo" v-model="formobj.file" :limit="50" bucket="map" :upload-data="{ type: '0001' }"/> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<div class="title">开票索赔单列表</div> |
||||
|
<el-table :key="tableKey" :data="formobj.sitemsVos" :index="index" border style="width: 100%"> |
||||
|
<el-table-column fixed width="60" label="序号" type="index" :index="index + 1" align="center"/> |
||||
|
<el-table-column prop="sitemName" label="项目名称" align="center" width="170" /> |
||||
|
<el-table-column prop="serviceType" label="工种" align="center" width="170" /> |
||||
|
<el-table-column prop="subjectName" label="科目" align="center" width="100" /> |
||||
|
<el-table-column prop="hourPrice" label="工时单价" align="center" width="100" /> |
||||
|
<el-table-column prop="hours" label="工时数" align="center" width="100" /> |
||||
|
<el-table-column prop="cost" label="外协成本" align="center" width="120" /> |
||||
|
<el-table-column prop="price" label="销售价" align="center" width="120" /> |
||||
|
<el-table-column prop="examineHourPrice" label="工时提成" align="center" width="120" /> |
||||
|
<el-table-column prop="remarks" label="备注" align="center" min-width="200" /> |
||||
|
<el-table-column label="预约项目" align="center" width="120"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span>{{ scope.row.isReserve == '1' ? '是' : scope.row.isReserve == '0' ? '否' : '' }}</span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="洗车项目" align="center" width="120"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span>{{ scope.row.isClean == '1' ? '是' : scope.row.isClean == '0' ? '否' : '' }}</span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
</el-table> |
||||
|
</el-form> |
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
</template> |
||||
|
|
||||
|
<script> |
||||
|
import req from '@/api/basicinformation/maintenanceProjectRecord' |
||||
|
import uploadImg from '@/components/uploadFile/uploadImg' |
||||
|
|
||||
|
export default { |
||||
|
name: 'MaintenanceProjectRecordEdit', |
||||
|
components: { |
||||
|
uploadImg |
||||
|
}, |
||||
|
data() { |
||||
|
return { |
||||
|
viewTitle: '', |
||||
|
viewState: 1, |
||||
|
submitdisabled: false, |
||||
|
tableKey: 1, |
||||
|
index: 0, |
||||
|
formobj: { |
||||
|
createByName: '', |
||||
|
createBySid: '', |
||||
|
createOrgName: '', |
||||
|
createOrgSid: '', |
||||
|
createTime: '', |
||||
|
deptName: '', |
||||
|
deptSid: '', |
||||
|
file: [], |
||||
|
instanceId: '', |
||||
|
sid: '', |
||||
|
sitemsVos: [], |
||||
|
taskId: '', |
||||
|
useOrgName: '', |
||||
|
useOrgSid: '' |
||||
|
}, |
||||
|
rules: {} |
||||
|
} |
||||
|
}, |
||||
|
created() { |
||||
|
console.log('url:' + window.location.href) |
||||
|
var one = window.location.href.indexOf('&data') + 6 |
||||
|
const data = window.location.href.substr(one) // url解码unescape()已从web中移除,尽量不使用 |
||||
|
const obj = JSON.parse(decodeURIComponent(data)) |
||||
|
this.showInfo(obj.businessSid) |
||||
|
}, |
||||
|
mounted() { |
||||
|
window.parent.postMessage({ |
||||
|
cmd: 'returnHeight', |
||||
|
params: { |
||||
|
// 告诉父级页面,子页面的弹框高度。 |
||||
|
code: 2, |
||||
|
data: 400 + 'px' |
||||
|
} |
||||
|
}, '*') |
||||
|
}, |
||||
|
methods: { |
||||
|
showInfo(sid) { |
||||
|
this.viewTitle = '【编辑】维修项目备案申请' |
||||
|
this.$nextTick(() => { |
||||
|
this.$refs['form_obj'].clearValidate() |
||||
|
}) |
||||
|
req.fetchDetailsBySid(sid).then((res) => { |
||||
|
if (res.success) { |
||||
|
this.formobj = res.data |
||||
|
} |
||||
|
}) |
||||
|
}, |
||||
|
saveOrUpdate() { |
||||
|
this.$refs['form_obj'].validate((valid) => { |
||||
|
if (valid) { |
||||
|
this.submitdisabled = true |
||||
|
req.saveOrUpdate(this.formobj).then((res) => { |
||||
|
if (res.success) { |
||||
|
this.$message({ showClose: true, type: 'success', message: '保存成功' }) |
||||
|
// 子页面向父级页面传递值(关闭弹框) |
||||
|
window.parent.postMessage({ |
||||
|
cmd: 'returnHeight', |
||||
|
params: { |
||||
|
// 操作成功,告诉父级页面关闭弹框 |
||||
|
code: 1 |
||||
|
} |
||||
|
}, '*') |
||||
|
} else { |
||||
|
this.submitdisabled = false |
||||
|
} |
||||
|
}).catch(() => { |
||||
|
this.submitdisabled = false |
||||
|
}) |
||||
|
} |
||||
|
}) |
||||
|
}, |
||||
|
submit() { |
||||
|
this.$refs['form_obj'].validate((valid) => { |
||||
|
if (valid) { |
||||
|
this.submitdisabled = true |
||||
|
req.submit(this.formobj).then((res) => { |
||||
|
if (res.success) { |
||||
|
this.$message({ showClose: true, type: 'success', message: '提交成功' }) |
||||
|
// 子页面向父级页面传递值(关闭弹框) |
||||
|
window.parent.postMessage({ |
||||
|
cmd: 'returnHeight', |
||||
|
params: { |
||||
|
// 操作成功,告诉父级页面关闭弹框 |
||||
|
code: 1 |
||||
|
} |
||||
|
}, '*') |
||||
|
} else { |
||||
|
this.submitdisabled = false |
||||
|
} |
||||
|
}).catch(() => { |
||||
|
this.submitdisabled = false |
||||
|
}) |
||||
|
} |
||||
|
}) |
||||
|
} |
||||
|
} |
||||
|
} |
||||
|
</script> |
||||
|
|
||||
|
<style scoped> |
||||
|
.span-sty { |
||||
|
width: 130px !important; |
||||
|
} |
||||
|
.addinputInfo { |
||||
|
margin-left: 120px !important; |
||||
|
} |
||||
|
/deep/ .el-form-item__error { |
||||
|
margin-left: 120px !important; |
||||
|
} |
||||
|
</style> |
@ -0,0 +1,199 @@ |
|||||
|
<template> |
||||
|
<div class="app-container"> |
||||
|
<div v-show="viewState == 1"> |
||||
|
<div class="tab-header webtop"> |
||||
|
<div>{{ viewTitle }}</div> |
||||
|
<div> |
||||
|
<el-button type="danger" size="small" @click="openRevoke()">撤回</el-button> |
||||
|
</div> |
||||
|
</div> |
||||
|
<div class=""> |
||||
|
<el-form ref="form_obj" :model="formobj" :rules="rules" class="formaddcopy02"> |
||||
|
<el-row style="border-top: 1px solid #e0e3eb"> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">申请部门</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.deptName }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">申请人</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.createByName }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="8"> |
||||
|
<div class="span-sty">申请日期</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.createTime }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="24"> |
||||
|
<div class="span-sty">备注</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.remarks }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="24"> |
||||
|
<div class="span-sty">附件</div> |
||||
|
<el-form-item><el-image class="addinputInfo" style="width: 150px;height: 150px" v-for="(item, index) in formobj.file" :key="index" :src="item" :preview-src-list="formobj.file" /></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<div class="title">开票索赔单列表</div> |
||||
|
<el-table :key="tableKey" :data="formobj.sitemsVos" :index="index" border style="width: 100%"> |
||||
|
<el-table-column fixed width="60" label="序号" type="index" :index="index + 1" align="center"/> |
||||
|
<el-table-column prop="sitemName" label="项目名称" align="center" width="170" /> |
||||
|
<el-table-column prop="serviceType" label="工种" align="center" width="170" /> |
||||
|
<el-table-column prop="subjectName" label="科目" align="center" width="100" /> |
||||
|
<el-table-column prop="hourPrice" label="工时单价" align="center" width="100" /> |
||||
|
<el-table-column prop="hours" label="工时数" align="center" width="100" /> |
||||
|
<el-table-column prop="cost" label="外协成本" align="center" width="120" /> |
||||
|
<el-table-column prop="price" label="销售价" align="center" width="120" /> |
||||
|
<el-table-column prop="examineHourPrice" label="工时提成" align="center" width="120" /> |
||||
|
<el-table-column prop="remarks" label="备注" align="center" min-width="200" /> |
||||
|
<el-table-column label="预约项目" align="center" width="120"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span>{{ scope.row.isReserve == '1' ? '是' : scope.row.isReserve == '0' ? '否' : '' }}</span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="洗车项目" align="center" width="120"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span>{{ scope.row.isClean == '1' ? '是' : scope.row.isClean == '0' ? '否' : '' }}</span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
</el-table> |
||||
|
</el-form> |
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
</template> |
||||
|
|
||||
|
<script> |
||||
|
import req from '@/api/basicinformation/maintenanceProjectRecord' |
||||
|
|
||||
|
export default { |
||||
|
name: 'MaintenanceProjectRecordYiBan', |
||||
|
data() { |
||||
|
return { |
||||
|
viewTitle: '', |
||||
|
viewState: 1, |
||||
|
tableKey: 1, |
||||
|
index: 0, |
||||
|
formobj: { |
||||
|
createByName: '', |
||||
|
createBySid: '', |
||||
|
createOrgName: '', |
||||
|
createOrgSid: '', |
||||
|
createTime: '', |
||||
|
deptName: '', |
||||
|
deptSid: '', |
||||
|
file: [], |
||||
|
instanceId: '', |
||||
|
sid: '', |
||||
|
sitemsVos: [], |
||||
|
taskId: '', |
||||
|
useOrgName: '', |
||||
|
useOrgSid: '' |
||||
|
}, |
||||
|
rules: {}, |
||||
|
// 环节所需参数 |
||||
|
linkByParameter: { |
||||
|
businessSid: '', |
||||
|
comment: '', |
||||
|
instanceId: '', |
||||
|
taskId: '', |
||||
|
orgSidPath: '', |
||||
|
taskDefKey: '', |
||||
|
userSid: '' |
||||
|
} |
||||
|
} |
||||
|
}, |
||||
|
created() { |
||||
|
console.log('url:' + window.location.href) |
||||
|
var one = window.location.href.indexOf('&data') + 6 |
||||
|
const data = window.location.href.substr(one) // url解码unescape()已从web中移除,尽量不使用 |
||||
|
const obj = JSON.parse(decodeURIComponent(data)) |
||||
|
console.log('iframe页面获取的obj:', obj) |
||||
|
// 点击(同意、终止、驳回、驳回)操作时所需的参数 |
||||
|
this.linkByParameter.businessSid = obj.businessSid |
||||
|
this.linkByParameter.instanceId = obj.instanceId |
||||
|
this.linkByParameter.taskId = obj.taskId |
||||
|
this.linkByParameter.taskDefKey = obj.taskDefKey |
||||
|
this.linkByParameter.userSid = window.sessionStorage.getItem('userSid') |
||||
|
// 加载表单数据 |
||||
|
this.showInfo(obj.businessSid) |
||||
|
}, |
||||
|
mounted() { |
||||
|
window.parent.postMessage({ |
||||
|
cmd: 'returnHeight', |
||||
|
params: { |
||||
|
// 告诉父级页面,子页面的弹框高度。 |
||||
|
code: 2, |
||||
|
data: 400 + 'px' |
||||
|
} |
||||
|
}, '*') |
||||
|
}, |
||||
|
methods: { |
||||
|
showInfo(sid) { |
||||
|
this.viewTitle = '维修项目备案申请详情' |
||||
|
this.$nextTick(() => { |
||||
|
this.$refs['form_obj'].clearValidate() |
||||
|
}) |
||||
|
req.fetchDetailsBySid(sid).then((res) => { |
||||
|
if (res.success) { |
||||
|
this.formobj = res.data |
||||
|
if (this.formobj.file.length > 0) { |
||||
|
const aa = [] |
||||
|
this.formobj.file.forEach((e) => { |
||||
|
aa.push(e.url) |
||||
|
}) |
||||
|
this.formobj.file = aa |
||||
|
} |
||||
|
} |
||||
|
}) |
||||
|
}, |
||||
|
/** 确认撤回任务 */ |
||||
|
openRevoke() { |
||||
|
this.$confirm('是否确认执行撤回操作', '提示', { |
||||
|
confirmButtonText: '确定', |
||||
|
cancelButtonText: '取消', |
||||
|
type: 'warning' |
||||
|
}).then(() => { |
||||
|
this.handleRevoke() |
||||
|
}).catch(() => { |
||||
|
this.$message({ |
||||
|
type: 'info', |
||||
|
message: '已取消撤回' |
||||
|
}) |
||||
|
}) |
||||
|
}, |
||||
|
/** 撤回任务 */ |
||||
|
handleRevoke() { |
||||
|
req.revokeProcess(this.linkByParameter).then((response) => { |
||||
|
if (response.success) { |
||||
|
this.$notify({ |
||||
|
title: '提示', |
||||
|
message: '执行成功', |
||||
|
type: 'success', |
||||
|
duration: 2000 |
||||
|
}) |
||||
|
this.nodeDialogVisible = false |
||||
|
// 子页面向父级页面传递值 |
||||
|
window.parent.postMessage({ |
||||
|
cmd: 'returnHeight', |
||||
|
params: { |
||||
|
// 操作成功,告诉父级页面关闭弹框 |
||||
|
code: 1 |
||||
|
} |
||||
|
}, '*') |
||||
|
} |
||||
|
}) |
||||
|
} |
||||
|
} |
||||
|
} |
||||
|
</script> |
||||
|
|
||||
|
<style scoped> |
||||
|
.span-sty { |
||||
|
width: 130px !important; |
||||
|
} |
||||
|
.addinputInfo { |
||||
|
margin-left: 120px !important; |
||||
|
} |
||||
|
</style> |
Loading…
Reference in new issue