Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
P
patzn-cloud-web-back-soil
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wangweidong
patzn-cloud-web-back-soil
Commits
2643fecb
Commit
2643fecb
authored
Jun 15, 2020
by
lichengming
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改了分包样品管理分包出库
parent
95d6ff2e
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
206 additions
and
1 deletions
+206
-1
MeterSubSampleManage.vue
...eter-subcontract/subpackage-task/MeterSubSampleManage.vue
+19
-1
SubOutWarehouse.vue
pages/meter-subcontract/subpackage-task/SubOutWarehouse.vue
+187
-0
No files found.
pages/meter-subcontract/subpackage-task/MeterSubSampleManage.vue
View file @
2643fecb
...
@@ -58,14 +58,17 @@
...
@@ -58,14 +58,17 @@
</div>
</div>
</Modal>
</Modal>
<MeterSubSampleEdit
ref=
"batchEditModal"
@
on-result-change=
"_page"
></MeterSubSampleEdit>
<MeterSubSampleEdit
ref=
"batchEditModal"
@
on-result-change=
"_page"
></MeterSubSampleEdit>
<SubOutWarehouse
ref=
"OutWarehouseModal"
></SubOutWarehouse>
</div>
</div>
</template>
</template>
<
script
>
<
script
>
import
{
meterSample
}
from
'../../../api'
import
{
meterSample
}
from
'../../../api'
import
MeterSubSampleEdit
from
'./MeterSubSampleEdit'
import
MeterSubSampleEdit
from
'./MeterSubSampleEdit'
import
SubOutWarehouse
from
'./SubOutWarehouse'
export
default
{
export
default
{
components
:
{
components
:
{
MeterSubSampleEdit
MeterSubSampleEdit
,
SubOutWarehouse
// FoodSampleGovernDetail,
// FoodSampleGovernDetail,
// CopyModal,
// CopyModal,
// FoodSampleGovernLYEdits
// FoodSampleGovernLYEdits
...
@@ -100,6 +103,11 @@ export default {
...
@@ -100,6 +103,11 @@ export default {
type
:
'success'
,
type
:
'success'
,
id
:
''
,
id
:
''
,
name
:
'取消分包'
name
:
'取消分包'
},
{
type
:
'success'
,
id
:
''
,
name
:
'分包出库'
}
}
],
],
options
:
[
options
:
[
...
@@ -167,6 +175,9 @@ export default {
...
@@ -167,6 +175,9 @@ export default {
this
.
currentComponent
=
componentName
this
.
currentComponent
=
componentName
this
.
$nextTick
(
function
()
{
this
.
$nextTick
(
function
()
{
switch
(
msg
)
{
switch
(
msg
)
{
case
'分包出库'
:
this
.
_outWarehouse
()
break
case
'分包信息登记'
:
case
'分包信息登记'
:
this
.
_batchEpiboly
()
this
.
_batchEpiboly
()
break
break
...
@@ -188,6 +199,13 @@ export default {
...
@@ -188,6 +199,13 @@ export default {
}
}
})
})
},
},
_outWarehouse
()
{
if
(
this
.
selectIds
.
length
===
0
)
{
this
.
$Message
.
warning
(
'请选择一条或多条数据!'
)
}
else
{
this
.
$refs
.
OutWarehouseModal
.
_open
(
this
.
selectIds
,
this
.
selectData
)
}
},
_batchEpiboly
()
{
_batchEpiboly
()
{
if
(
this
.
selectIds
.
length
===
0
)
{
if
(
this
.
selectIds
.
length
===
0
)
{
this
.
$Message
.
warning
(
'请选择一条或多条数据!'
)
this
.
$Message
.
warning
(
'请选择一条或多条数据!'
)
...
...
pages/meter-subcontract/subpackage-task/SubOutWarehouse.vue
0 → 100644
View file @
2643fecb
<
template
>
<div>
<Modal
v-model=
"showModal"
:mask-closable=
"false"
width=
"700"
>
<p
slot=
"header"
>
分包出库
</p>
<div>
<Form
id=
"batch-edit-form"
ref=
"formObj"
:model=
"formObj"
:rules=
"ruleValidate"
:label-width=
"90"
>
<Form-item
label=
"出库人:"
prop=
"outPerson"
>
<!--
<InputNumber
v-model
.
number=
"formObj.outFee"
:min=
"0"
:step=
"1"
--
>
<!-- name="outFee" style="width:100%" placeholder="">-->
<!--
</InputNumber>
-->
<Input
v-model=
"formObj.outPerson"
name=
"outPerson"
></Input>
</Form-item>
<Form-item
label=
"出库时间:"
prop=
"subcontractor"
>
<el-time-picker
v-model=
"formObj.outTime"
placeholder=
"任意时间点"
>
</el-time-picker>
<!--
<div
style=
"display: flex"
>
-->
<!--
<AutoCompletes
:value=
"formObj.subcontractor"
:down-data=
"labList"
@
on-result-change=
"_labChange"
--
>
<!-- name="subcontractorName"-->
<!-- show-key="name" placeholder="请输入或选择分包实验室" style="width: 94%">
</AutoCompletes>
-->
<!--
<Icon
@
click=
"_labSel"
type=
"ios-arrow-forward"
size=
"24"
color=
"#00a0e9"
style=
"margin-top: 5px;margin-left: 5px"
/>
-->
<!--
</div>
-->
<input
v-model=
"formObj.subcontractorId"
type=
"hidden"
name=
"subcontractorId"
/>
</Form-item>
<Form-item
label=
"备注"
prop=
"remark"
>
<Input
v-model=
"formObj.remark"
:rows=
"3"
type=
"textarea"
name=
"remark"
placeholder=
"请输入备注"
/>
</Form-item>
</Form>
</div>
<div
slot=
"footer"
>
<ModalFooter
ref=
"footerModal"
:footer=
"footerList"
@
on-result-change=
"_footerResult"
></ModalFooter>
</div>
</Modal>
<!--选择实验室-->
<EditLabSelect
ref=
"labModal"
@
on-result-change=
"_labResult"
></EditLabSelect>
</div>
</
template
>
<
script
>
import
global
from
'../../../api/sys/sys-user'
import
ModalFooter
from
'../../../components/base/modalFooter'
// import AutoCompletes from '../../../components/base/AutoCompletes'
import
{
meterSample
,
meterSubcontractor
}
from
'../../../api'
import
EditLabSelect
from
'./EditLabSelect'
/**
* 添加编辑分包信息
*/
const
defVal
=
{
subcontractor
:
undefined
,
subcontractorId
:
undefined
,
outReason
:
undefined
,
outFee
:
undefined
,
outPerson
:
undefined
,
outTime
:
undefined
,
remark
:
undefined
}
export
default
{
components
:
{
EditLabSelect
,
ModalFooter
// AutoCompletes
},
data
()
{
return
{
ids
:
[],
selectData
:
[],
formObj
:
defVal
,
ruleValidate
:
{
// price: [{required: true, message: '分包价不能为空', trigger: 'blur', type: 'number'}],
},
showModal
:
false
,
footerList
:
[
{
id
:
''
,
name
:
'取消'
,
type
:
''
},
{
id
:
''
,
name
:
'保存'
,
type
:
'primary'
}
],
labList
:
[]
}
},
methods
:
{
_footerResult
(
name
)
{
switch
(
name
)
{
case
'取消'
:
this
.
_cancel
()
break
case
'保存'
:
this
.
_ok
()
break
}
},
_hideLoading
()
{
this
.
$refs
.
footerModal
.
_hideLoading
()
},
_ok
()
{
console
.
log
(
'_ok----'
,
this
.
formObj
)
console
.
log
(
'_ok----'
,
this
.
ids
)
// this._subpackageInfoReg({ ids: this.ids, reg: this.formObj })
this
.
_hideLoading
()
},
_subpackageInfoReg
:
async
function
(
data
)
{
const
result
=
await
meterSample
.
subpackageInfoReg
(
data
)
if
(
result
)
{
this
.
$Message
.
success
(
'登记成功!'
)
this
.
_hideLoading
()
this
.
$emit
(
'on-result-change'
)
this
.
showModal
=
false
}
},
_cancel
()
{
this
.
showModal
=
false
},
_open
(
ids
,
selectData
)
{
this
.
formObj
=
{
subcontractor
:
undefined
,
subcontractorId
:
undefined
,
outReason
:
undefined
,
outFee
:
undefined
,
outPerson
:
undefined
,
outTime
:
undefined
,
remark
:
undefined
}
this
.
_userInfo
()
this
.
_getLab
()
this
.
_hideLoading
()
this
.
$refs
.
formObj
.
resetFields
()
this
.
formObj
.
subcontractorId
=
''
this
.
showModal
=
true
this
.
ids
=
ids
this
.
selectData
=
selectData
},
_labChange
(
msg
,
data
)
{
switch
(
msg
)
{
case
'select'
:
this
.
formObj
.
subcontractor
=
data
.
name
this
.
formObj
.
subcontractorId
=
data
.
id
break
case
'query'
:
this
.
formObj
.
subcontractor
=
data
.
name
this
.
_getLab
(
data
.
name
)
break
}
},
_userInfo
:
async
function
()
{
const
result
=
await
global
.
getUserInfo
()
console
.
log
(
'人员信息'
,
result
)
if
(
result
)
{
this
.
formObj
.
outPerson
=
result
.
realname
}
},
_getLab
:
async
function
(
name
)
{
const
data
=
{}
if
(
name
)
{
data
.
name
=
name
}
// this.$store.dispatch('FoodSubcontracter/getLab', data).then(() => {
// this.labList = this.$store.state.FoodSubcontracter.list
// })
// Object.assign(this.formObj, this.$refs.pageTable._searchParams())
// console.log('this.formObj', this.formObj)
const
result
=
await
meterSubcontractor
.
page
(
data
)
console
.
log
(
'实验室名称'
,
result
)
if
(
result
)
{
console
.
log
(
result
.
records
)
this
.
labList
=
result
.
records
console
.
log
(
this
.
labList
)
}
},
_labSel
()
{
const
voList
=
[]
for
(
let
i
=
0
;
i
<
this
.
selectData
.
length
;
i
++
)
{
voList
.
push
({
itemName
:
this
.
selectData
[
i
].
itemName
,
testBasis
:
this
.
selectData
[
i
].
testBasis
})
}
this
.
$refs
.
labModal
.
_open
(
voList
,
'batch-lab-form'
)
},
_labResult
(
result
)
{
this
.
formObj
.
subcontractorId
=
result
.
id
this
.
formObj
.
subcontractor
=
result
.
name
}
}
}
</
script
>
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment