Commit 9813ae2a by lichengming

修改了送出检委托单选择合同

parent 172fc0c8
<template>
<div >
<header-menu :crumbs="crumbsList" @on-result-change="_headerMenuResult"/>
<div v-if="show" :class="{'shrink-iview-layout-nuxt':isShrink}" class="iview-layout-nuxt">
<nuxt />
<div :class="{'shrink-iview-layout-nuxt':isShrink}" class="iview-layout-nuxt">
<nuxt v-if="isRouterAlive" />
</div>
</div>
</template>
......@@ -19,7 +19,8 @@ export default {
return {
isShrink: false,
crumbsList: [],
show: false
show: false,
isRouterAlive: false
}
},
watch: {
......@@ -28,16 +29,27 @@ export default {
}
},
mounted() {
this.show = true
// this.show = true
this._setBreadCrumb(this.$route)
this._initLoad()
this.$nextTick(() => {
this._initLoad()
})
},
methods: {
// 刷新
_reload() {
this.isRouterAlive = false
this.$nextTick(() => {
this.isRouterAlive = true
})
},
// 初始化加载
_initLoad() {
if (!Global.getLn()) {
// 暂时没有登录-跳到首页
window.location.href = Global.ssoURL
} else {
this._reload()
}
},
// 设置面包屑
......
<template>
<div>
<Modal v-model="showUserGroupModal">
<Modal v-model="showUserGroupModal" width="800">
<p slot="header">
{{ modalTitle }}
</p>
......@@ -29,7 +29,6 @@
</Col>
<Col span="24" style="margin-bottom: 10px">
<el-table
:height="300"
:data="getPage"
border
size="small"
......@@ -96,9 +95,10 @@ export default {
pageParams: { rows: 20 },
pageColumns: [
{ title: '合同编号', key: 'salesCode', width: 120 },
{ title: '委托单位', key: 'client', width: 200 },
{ title: '联系人', key: 'person', width: 120 },
{ title: '联系电话', key: 'tel', width: 120 }
{ title: '委托单位', key: 'client' },
{ title: '联系人', key: 'person' },
{ title: '联系电话', key: 'tel' },
{ title: '样品名称', key: 'samples', width: 140 }
// { title: '传真', key: 'fax', width: 120 },
// { title: '详细地址', key: 'address', width: 250 },
// { title: '登记日期', key: 'edate', width: 120, date: true },
......
......@@ -50,7 +50,7 @@
</Form-item>
<Form-item label="合同号:" prop="contractCode" class="width-48">
<Input v-model="formObj.contractCode" name="contractCode" placeholder="请输入合同号" style="width: 465px;"/>
<span @click="_selectcontractCode" style="font-size: 20px;color: #00b5ec;cursor: pointer" class="">+</span>
<span v-if="showBtn" @click="_selectcontractCode" style="font-size: 20px;color: #00b5ec;cursor: pointer" class="">+</span>
</Form-item>
<Form-item label="备注:" prop="remark" style="width: 99.8%">
<Input v-model="formObj.remark" :rows="3" name="remark" type="textarea"
......@@ -223,6 +223,7 @@ export default {
getPage: {
records: []
},
showBtn: true,
testedCityData: [],
customerData: [],
searchOpen: true,
......@@ -451,6 +452,7 @@ export default {
},
_backData(data) {
console.log(typeof this.index)
console.log(data)
this.getPage.records[this.index].name = data.name
this.getPage.records[this.index].aptitudeId = data.id
this.getPage.records[this.index].verification = data.code + data.basis
......@@ -472,6 +474,11 @@ export default {
this.formObj.odate = new Date(data.odate)
this.formObj.contractCode = data.salesCode
this.formObj.operation.fee = data.discountPrice
if (data.sampleQuoteList) {
this.getPage.records = data.sampleQuoteList
} else {
this.getPage.records = []
}
},
_selectjudgeBasis(index) {
this.index = index
......@@ -650,6 +657,7 @@ export default {
const saveData = this.formObj
saveData.sampleList = this.getPage.records
// 编辑
console.log(saveData)
this._edit(saveData)
}
} else {
......@@ -682,6 +690,7 @@ export default {
this.showModal = false
},
_open() {
this.showBtn = true
this.showModal = true
this._getList()
this.$refs.formObj.resetFields()
......@@ -696,6 +705,7 @@ export default {
},
_openEdit(formObj) {
this.showBtn = false
this._getList()
this.getPage.records = []
this.showModal = true
......
<template>
<div>
<Modal v-model="showUserGroupModal" width="600">
<Modal v-model="showUserGroupModal" width="800">
<p slot="header">
{{ modalTitle }}
</p>
......@@ -12,31 +12,30 @@
<Form-item :label-width="70" label="授权资质仪器名称" >
<Input
v-model="code"
@on-enter="_pageChange(1)"
placeholder="授权资质仪器名称"
style="width: 100%"
@on-enter="_pageChange(1)"
/>
</Form-item>
<Form-item label="检测依据名称">
<Input
v-model="name"
@on-enter="_pageChange(1)"
placeholder="请输入检测依据名称"
style="width: 100%"
@on-enter="_pageChange(1)"
/>
</Form-item>
</Form>
</Col>
<Col span="24" style="margin-bottom: 10px">
<el-table
:height="300"
:data="getPage"
@row-click="_rowChange"
@row-dblclick="_dbClick"
border
size="small"
highlight-current-row
style="width: 100%"
@row-click="_rowChange"
@row-dblclick="_dbClick"
>
<el-table-column
v-for="item in pageColumns"
......@@ -59,21 +58,21 @@
<Page
:total="getPage.total"
:page-size="getPage.size"
@on-change="_pageChange"
@on-page-size-change="_pageRows"
placement="top"
show-total
show-elevator
show-sizer
@on-change="_pageChange"
@on-page-size-change="_pageRows"
/>
<div style="clear: both" />
</Col>
</Row>
<div slot="footer" class="btn-width">
<Button style="margin-left: 8px" @click="_cancel">
<Button @click="_cancel" style="margin-left: 8px">
取消
</Button>
<Button type="primary" @click="_ok">
<Button @click="_ok" type="primary">
确定
</Button>
</div>
......@@ -96,9 +95,10 @@ export default {
pageParams: { rows: 20 },
pageColumns: [
{ title: '合同编号', key: 'salesCode', width: 120 },
{ title: '委托单位', key: 'client', width: 200 },
{ title: '联系人', key: 'person', width: 120 },
{ title: '联系电话', key: 'tel', width: 120 }
{ title: '委托单位', key: 'client' },
{ title: '联系人', key: 'person' },
{ title: '联系电话', key: 'tel' },
{ title: '样品名称', key: 'samples', width: 140 }
// { title: '传真', key: 'fax', width: 120 },
// { title: '详细地址', key: 'address', width: 250 },
// { title: '登记日期', key: 'edate', width: 120, date: true },
......@@ -132,7 +132,6 @@ export default {
const result = await meterContract.pageContractForEntrust(this.formObj)
if (result) {
this.getPage = result.records
console.log(this.getPage)
this.loading = false
}
},
......
......@@ -51,7 +51,7 @@
</Form-item>
<Form-item label="合同号:" prop="contractCode" class="width-96">
<Input v-model="formObj.contractCode" name="contractCode" placeholder="请输入合同号" style="width: 495px;"/>
<span @click="_selectcontractCode" style="font-size: 20px;color: #00b5ec;cursor: pointer" class="">+</span>
<span v-if="showBtn" @click="_selectcontractCode" style="font-size: 20px;color: #00b5ec;cursor: pointer" class="">+</span>
</Form-item>
<Form-item label="备注:" prop="remark" style="width: 99.8%">
<Input v-model="formObj.remark" :rows="3" name="remark" type="textarea"
......@@ -205,6 +205,7 @@ export default {
getPage: {
records: []
},
showBtn: true,
customerData: [],
cityData: [],
searchOpen: true,
......@@ -473,6 +474,11 @@ export default {
this.formObj.odate = new Date(data.odate)
this.formObj.contractCode = data.salesCode
this.formObj.operation.fee = data.discountPrice
if (data.sampleQuoteList) {
this.getPage.records = data.sampleQuoteList
} else {
this.getPage.records = []
}
},
_add() {
const data = {
......@@ -663,6 +669,7 @@ export default {
this.showModal = false
},
_open(formObj) {
this.showBtn = true
this.showModal = true
this._getList()
this.$refs.formObj.resetFields()
......@@ -685,6 +692,7 @@ export default {
}
},
_openEdit(formObj) {
this.showBtn = false
this._getList()
this.getPage.records = []
this.showModal = true
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment