Commit 8e038027 by wangweidong

整体优化

parent cca6e3b6
...@@ -8,11 +8,8 @@ ...@@ -8,11 +8,8 @@
<Col span="24" style="margin-top: 10px"> <Col span="24" style="margin-top: 10px">
<Form id="formId" v-show="searchOpen" :label-width="90" inline onsubmit="return false"> <Form id="formId" v-show="searchOpen" :label-width="90" inline onsubmit="return false">
<label class="label-sign"></label> <label class="label-sign"></label>
<Form-item class="search-item" label="实验室名称:"> <Form-item class="search-item" label="委托单位:">
<Input v-model="formObj.name" @on-enter="_formSearch" name="name" placeholder="请输入实验室名称" clearable/> <Input v-model="formObj.client" @on-enter="_formSearch" name="name" placeholder="请输入委托单位" clearable/>
</Form-item>
<Form-item class="search-item" label="资质:">
<Input v-model="formObj.aptitude" @on-enter="_formSearch" name="aptitude" placeholder="请输入资质" clearable/>
</Form-item> </Form-item>
<Form-item class="search-btn"> <Form-item class="search-btn">
<Button @click="_formSearch" type="primary">搜索</Button> <Button @click="_formSearch" type="primary">搜索</Button>
...@@ -94,8 +91,7 @@ export default { ...@@ -94,8 +91,7 @@ export default {
} }
], ],
formObj: { formObj: {
name: undefined, client: undefined
aptitude: undefined
}, },
selectIds: [], selectIds: [],
getPage: {}, getPage: {},
......
...@@ -6,29 +6,26 @@ ...@@ -6,29 +6,26 @@
<Row> <Row>
<!--查询--> <!--查询-->
<Col span="24" style="margin-top: 10px"> <Col span="24" style="margin-top: 10px">
<Form id="formId" v-show="searchOpen" :label-width="90" inline onsubmit="return false"> <Form v-show="searchOpen" id="formId" :label-width="90" inline onsubmit="return false">
<label class="label-sign"></label> <label class="label-sign"></label>
<Form-item class="search-item" label="实验室名称:"> <Form-item class="search-item" label="委托单位:">
<Input v-model="formObj.name" @on-enter="_formSearch" name="name" placeholder="请输入实验室名称" clearable/> <Input v-model="formObj.client" name="name" placeholder="请输入委托单位" clearable @on-enter="_formSearch"/>
</Form-item>
<Form-item class="search-item" label="资质:">
<Input v-model="formObj.aptitude" @on-enter="_formSearch" name="aptitude" placeholder="请输入资质" clearable/>
</Form-item> </Form-item>
<Form-item class="search-btn"> <Form-item class="search-btn">
<Button @click="_formSearch" type="primary">搜索</Button> <Button type="primary" @click="_formSearch">搜索</Button>
</Form-item> </Form-item>
</Form> </Form>
</Col> </Col>
<!--操作--> <!--操作-->
<Col span="24"> <Col span="24">
<btn-list :msg="btn" :open="searchOpen" :show-search-btn="true" @on-result-change="_btnClick" <btn-list :msg="btn" :open="searchOpen" :show-search-btn="true" class="contHide"
class="contHide"></btn-list> @on-result-change="_btnClick"></btn-list>
</Col> </Col>
<!--表格--> <!--表格-->
<Col span="24"> <Col span="24">
<PTVXETable ref="pageTable" :table-height="tableHeight" :form-id="formId" :loading="true" <PTVXETable ref="pageTable" :table-height="tableHeight" :form-id="formId" :loading="true"
:get-page="getPage" :icon-msg="iconMsg" @on-result-change="_tableResultChange" hide-checkbox> :get-page="getPage" :icon-msg="iconMsg" hide-checkbox @on-result-change="_tableResultChange">
<vxe-table-column <vxe-table-column
v-for="item in pageColumns" v-for="item in pageColumns"
:key="item.key" :key="item.key"
...@@ -45,47 +42,56 @@ ...@@ -45,47 +42,56 @@
</Row> </Row>
</div> </div>
</div> </div>
<FileManage ref="FileManage"></FileManage>
<subSampleManage ref="subSampleManage"></subSampleManage>
<operationModal ref="operationModal"></operationModal>
</div> </div>
</template> </template>
<script> <script>
import { meterEntrust, meterSubcontractor } from '../../../api' import { meterEntrust, meterSubcontractor } from '../../../api'
import operationModal from '../../../components/operation/Operation'
import subSampleManage from './MeterSubSampleManage'
export default { export default {
components: {}, components: { subSampleManage, operationModal },
data() { data() {
return { return {
currentComponent: '', currentComponent: '',
formId: 'meterSubpackageTaskHisFormId', formId: 'meterSubpackageTaskFormId',
searchOpen: false, searchOpen: false,
btn: [ btn: [
{ // {
type: 'success', // // meter-review-entrust-pass-btn
id: 'meter-subcontractor-add-btn', // type: 'success',
name: '添加' // id: '',
} // name: '通过'
// },
// // meter-review-entrust-back-btn
// {
// type: 'success',
// id: '',
// name: '驳回'
// }
], ],
iconMsg: [ iconMsg: [
{ {
type: 'ios-clock', type: 'md-paper',
id: '', id: '',
name: '编辑' name: '编辑'
}, },
{ {
type: 'ios-clock', type: 'ios-beaker',
id: '', id: '',
name: '资质项目' name: '分包样品管理'
}, },
{ type: 'ios-clock', id: '', name: '附件' }, { type: 'md-cloud', id: '', name: '附件' },
{ type: 'ios-clock', id: '', name: '删除' },
{ {
type: 'ios-clock', type: 'md-book',
id: '', id: '',
name: '操作日志' name: '操作日志'
} }
], ],
formObj: { formObj: {
name: undefined, client: undefined
aptitude: undefined
}, },
selectIds: [], selectIds: [],
getPage: {}, getPage: {},
...@@ -134,6 +140,9 @@ export default { ...@@ -134,6 +140,9 @@ export default {
this.currentComponent = componentName this.currentComponent = componentName
this.$nextTick(function() { this.$nextTick(function() {
switch (res) { switch (res) {
case '分包样品管理':
this.subSampleManage(data)
break
case '编辑': case '编辑':
this._editModal(true, data.id) this._editModal(true, data.id)
break break
...@@ -152,8 +161,12 @@ export default { ...@@ -152,8 +161,12 @@ export default {
} }
}) })
}, },
subSampleManage(data) {
// 管理样品
this.$refs.subSampleManage._open(data.id)
},
_record(id) { _record(id) {
this.$refs.refModal._open(id) this.$refs.operationModal._open(id)
}, },
_tableResultChange(msg, data) { _tableResultChange(msg, data) {
switch (msg) { switch (msg) {
...@@ -171,7 +184,7 @@ export default { ...@@ -171,7 +184,7 @@ export default {
_page: async function() { _page: async function() {
Object.assign(this.formObj, this.$refs.pageTable._searchParams()) Object.assign(this.formObj, this.$refs.pageTable._searchParams())
console.log('this.formObj', this.formObj) console.log('this.formObj', this.formObj)
const result = await meterEntrust.pageSendEntrust(this.formObj) const result = await meterEntrust.pageSubpackageInputEntrust(this.formObj)
if (result) { if (result) {
this.$refs.pageTable._hideLoading() this.$refs.pageTable._hideLoading()
this.getPage = result this.getPage = result
...@@ -208,7 +221,7 @@ export default { ...@@ -208,7 +221,7 @@ export default {
_upload(id) { _upload(id) {
// 上传文件 // 上传文件
this.$refs.refModal._open(id, 'subcontractorId') this.$refs.FileManage._open(id, 'subcontractorId')
}, },
_getById: async function(id) { _getById: async function(id) {
const result = await meterSubcontractor.getById(id) const result = await meterSubcontractor.getById(id)
......
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