Commit 639a8d4c by lichengming
parents a01d8130 2eb4a113
...@@ -81,6 +81,11 @@ export default { ...@@ -81,6 +81,11 @@ export default {
.post('meter/v1/sample/subpackage_out_stock?ids=' + data.ids, data.obj) .post('meter/v1/sample/subpackage_out_stock?ids=' + data.ids, data.obj)
.then(res => res), .then(res => res),
subpackageInStock: data =>
http
.post('meter/v1/sample/subpackage_in_stock?ids=' + data.ids, data.obj)
.then(res => res),
submitReceive: data => submitReceive: data =>
http.post('meter/v1/sample/submit_receive?ids=' + data).then(res => res), http.post('meter/v1/sample/submit_receive?ids=' + data).then(res => res),
......
...@@ -60,10 +60,10 @@ ...@@ -60,10 +60,10 @@
</div> </div>
</Modal> </Modal>
<MeterSubSampleEdit ref="batchEditModal" @on-result-change="_page"></MeterSubSampleEdit> <MeterSubSampleEdit ref="batchEditModal" @on-result-change="_page"></MeterSubSampleEdit>
<SubOutWarehouse ref="OutWarehouseModal" ></SubOutWarehouse> <SubOutWarehouse ref="OutWarehouseModal" @on-result-change="_page"></SubOutWarehouse>
<SubResultInput ref="ResultInputModal"></SubResultInput> <SubResultInput ref="ResultInputModal" @on-result-change="_page"></SubResultInput>
<UploadByReport ref="UploadModal"></UploadByReport> <UploadByReport ref="UploadModal" @on-result-change="_page"></UploadByReport>
<HisRevision ref="HisModal"></HisRevision> <HisRevision ref="HisModal" @on-result-change="_page"></HisRevision>
</div> </div>
</template> </template>
<script> <script>
...@@ -98,30 +98,16 @@ export default { ...@@ -98,30 +98,16 @@ export default {
// {id: '', name: '删除'}, // {id: '', name: '删除'},
// ], // ],
iconMsg: [ iconMsg: [
{ type: 'md-create', id: '', name: '检测结果录入' }, { type: 'md-create', id: '', name: '分包结果录入' },
{ type: 'ios-list', id: '', name: '历史版本' }, { type: 'ios-list', id: '', name: '历史版本' },
{ type: 'ios-cloud-upload', id: '', name: '上传' }, { type: 'ios-cloud-upload', id: '', name: '分包证书上传' },
{ type: 'compose', id: '', name: '编辑' }, { type: 'compose', id: '', name: '编辑' }
{ type: 'ios-copy', id: '', name: '复制', componentName: 'CopyModal' },
{ type: 'trash-a', id: '', name: '删除' }
], ],
btn: [ btn: [
{ {
// meter-review-entrust-pass-btn
type: 'success', type: 'success',
id: '', id: '',
name: '分包信息登记' name: '分包返库'
},
// meter-review-entrust-back-btn
{
type: 'success',
id: '',
name: '取消分包'
},
{
type: 'success',
id: '',
name: '分包出库'
} }
], ],
options: [ options: [
...@@ -151,8 +137,10 @@ export default { ...@@ -151,8 +137,10 @@ export default {
{ title: '分包费用', key: 'outFee', width: 110 }, { title: '分包费用', key: 'outFee', width: 110 },
{ title: '分包原因', key: 'outReason', width: 110 }, { title: '分包原因', key: 'outReason', width: 110 },
{ title: '分包方', key: 'subcontractor', width: 110 }, { title: '分包方', key: 'subcontractor', width: 110 },
{ title: '出库人', key: 'outer', width: 130 }, { title: '出库人', key: 'outer', width: 140 },
{ title: '出库时间', key: 'outStockTime', width: 110, dateTime: true }, { title: '出库时间', key: 'outStockTime', width: 140, dateTime: true },
{ title: '返库人', key: 'inner', width: 130 },
{ title: '返库时间', key: 'inStockTime', width: 150, dateTime: true },
{ title: '检测类型', key: 'type', width: 140 }, { title: '检测类型', key: 'type', width: 140 },
{ title: '数量', key: 'quantity', width: 140 } { title: '数量', key: 'quantity', width: 140 }
], ],
...@@ -192,7 +180,7 @@ export default { ...@@ -192,7 +180,7 @@ export default {
this.currentComponent = componentName this.currentComponent = componentName
this.$nextTick(function() { this.$nextTick(function() {
switch (msg) { switch (msg) {
case '分包库': case '分包库':
this._outWarehouse() this._outWarehouse()
break break
case '分包信息登记': case '分包信息登记':
...@@ -244,10 +232,10 @@ export default { ...@@ -244,10 +232,10 @@ export default {
case '历史版本': case '历史版本':
this._HisEdit(data) this._HisEdit(data)
break break
case '上传': case '分包证书上传':
this._upload(data) this._upload(data)
break break
case '检测结果录入': case '分包结果录入':
this._resultModal(data) this._resultModal(data)
break break
case '编辑': case '编辑':
......
...@@ -86,7 +86,6 @@ export default { ...@@ -86,7 +86,6 @@ export default {
name: '分包样品管理' name: '分包样品管理'
}, },
{ type: 'md-cloud', id: '', name: '附件' }, { type: 'md-cloud', id: '', name: '附件' },
{ type: 'md-trash', id: '', name: '删除' },
{ {
type: 'md-book', type: 'md-book',
id: '', id: '',
......
<template> <template>
<div> <div>
<Modal v-model="showModal" :mask-closable="false" width="700"> <Modal v-model="showModal" :mask-closable="false" width="700">
<p slot="header">分包</p> <p slot="header">分包</p>
<div> <div>
<Form id="batch-edit-form" ref="formObj" :model="formObj" :rules="ruleValidate" :label-width="90"> <Form id="batch-edit-form" ref="formObj" :model="formObj" :rules="ruleValidate" :label-width="90">
<Form-item label="出库人:" prop="outer"> <Form-item label="返库人:" prop="inner">
<!-- <InputNumber v-model.number="formObj.outFee" :min="0" :step="1"--> <!-- <InputNumber v-model.number="formObj.outFee" :min="0" :step="1"-->
<!-- name="outFee" style="width:100%" placeholder="">--> <!-- name="outFee" style="width:100%" placeholder="">-->
<!-- </InputNumber>--> <!-- </InputNumber>-->
<Input v-model="formObj.outer" readonly name="outer" @click.native="_selectStaff"></Input> <Input v-model="formObj.inner" readonly name="inner" @click.native="_selectStaff"></Input>
</Form-item> </Form-item>
<Form-item label="出库时间:" prop="outStockTime"> <Form-item label="返库时间:" prop="inStockTime">
<div class="block"> <div class="block">
<el-date-picker <el-date-picker
v-model="formObj.outStockTime" v-model="formObj.inStockTime"
type="datetime" type="datetime"
value-format="yyyy-MM-dd HH:mm:ss" value-format="yyyy-MM-dd HH:mm:ss"
placeholder="选择日期时间"> placeholder="选择日期时间">
...@@ -48,9 +48,9 @@ import EditLabSelect from './EditLabSelect' ...@@ -48,9 +48,9 @@ import EditLabSelect from './EditLabSelect'
* 添加编辑分包信息 * 添加编辑分包信息
*/ */
const defVal = { const defVal = {
outer: undefined, inner: undefined,
outerId: undefined, innerId: undefined,
outStockTime: undefined, inStockTime: undefined,
remark: undefined remark: undefined
} }
export default { export default {
...@@ -97,13 +97,13 @@ export default { ...@@ -97,13 +97,13 @@ export default {
console.log('当前时间', defaultDate) console.log('当前时间', defaultDate)
console.log('时间', now) console.log('时间', now)
// this.formObj.outTime = now // this.formObj.outTime = now
this.formObj.outStockTime = defaultDate this.formObj.inStockTime = defaultDate
// this.$set(this.searchFormField, 'date', defaultDate) // this.$set(this.searchFormField, 'date', defaultDate)
}, },
_userData(data, msg, contractTempData) { _userData(data, msg, contractTempData) {
if (msg === 'salesman') { if (msg === 'salesman') {
// 选择业务员 // 选择业务员
this.formObj.outPerson = data.realname this.formObj.inner = data.realname
// this.formObj.detail.salesmanId = data.userId // this.formObj.detail.salesmanId = data.userId
// this.formObj.detail.salesmanPhone = data.mobile // this.formObj.detail.salesmanPhone = data.mobile
} }
...@@ -128,10 +128,11 @@ export default { ...@@ -128,10 +128,11 @@ export default {
this._subpackageOutStock({ ids: this.ids, obj: this.formObj }) this._subpackageOutStock({ ids: this.ids, obj: this.formObj })
}, },
_subpackageOutStock: async function(data) { _subpackageOutStock: async function(data) {
const result = await meterSample.subpackageOutStock(data) const result = await meterSample.subpackageInStock(data)
if (result) { if (result) {
this.$Message.success('库成功!') this.$Message.success('库成功!')
this.$emit('on-result-change') this.$emit('on-result-change')
this.showModal = false
this._hideLoading() this._hideLoading()
} }
}, },
...@@ -141,9 +142,9 @@ export default { ...@@ -141,9 +142,9 @@ export default {
}, },
_open(ids, selectData) { _open(ids, selectData) {
this.formObj = { this.formObj = {
outer: undefined, inner: undefined,
outerId: undefined, innerId: undefined,
outStockTime: undefined, inStockTime: undefined,
remark: undefined remark: undefined
} }
this._userInfo() this._userInfo()
...@@ -164,8 +165,8 @@ export default { ...@@ -164,8 +165,8 @@ export default {
}, },
_userInfo() { _userInfo() {
const user = Global.getUserInfo('userInfo') const user = Global.getUserInfo('userInfo')
this.formObj.outer = user.realname this.formObj.inner = user.realname
this.formObj.outerId = user.id this.formObj.innerId = user.id
}, },
_labSel() { _labSel() {
......
...@@ -261,7 +261,7 @@ export default { ...@@ -261,7 +261,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 meterItem.pageTest(this.formObj) const result = await meterItem.page(this.formObj)
console.log('result', result) console.log('result', result)
if (result) { if (result) {
this.getPage = result this.getPage = result
......
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