Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
C
confucius
Project
Project
Details
Activity
Releases
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
罗超
confucius
Commits
183715f0
Commit
183715f0
authored
May 13, 2021
by
罗超
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
新增耗材出库
parent
3c91adc3
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
315 additions
and
70 deletions
+315
-70
StockOutApplyFor.js
src/api/sale/StockOutApplyFor.js
+35
-0
addSuppliesStockOut-from.vue
src/components/sale/addSuppliesStockOut-from.vue
+160
-33
SuppliesStockOutApplyForDetail.vue
src/pages/sale/SuppliesStockOutApplyForDetail.vue
+116
-36
SuppliesStockOutApplyForMan.vue
src/pages/sale/SuppliesStockOutApplyForMan.vue
+4
-1
No files found.
src/api/sale/StockOutApplyFor.js
View file @
183715f0
...
@@ -44,4 +44,39 @@ import request from '../../utils/request_zc'
...
@@ -44,4 +44,39 @@ import request from '../../utils/request_zc'
method
:
'post'
,
method
:
'post'
,
data
data
})
})
}
/**
* 出库申请 - 出库
*
*/
export
function
SuppliesStockOut
(
data
)
{
return
request
({
url
:
'/supplies/SetSuppliesApplyForStockOut'
,
method
:
'post'
,
data
})
}
/**
* 获取仓库
*
*/
export
function
GetWareHouse
(
data
)
{
return
request
({
url
:
'/Supplies/GetWareHouseList'
,
method
:
'post'
,
data
})
}
/**
* 设置出库申请状态
*
*/
export
function
SetSuppliesStockOutApplyForState
(
data
)
{
return
request
({
url
:
'/supplies/SetSuppliesStockOutApplyForState'
,
method
:
'post'
,
data
})
}
}
\ No newline at end of file
src/components/sale/addSuppliesStockOut-from.vue
View file @
183715f0
...
@@ -19,12 +19,14 @@
...
@@ -19,12 +19,14 @@
<div
class=
"text-subtitle2 text-weight-bold q-mb-md row items-center q-pb-none"
>
<div
class=
"text-subtitle2 text-weight-bold q-mb-md row items-center q-pb-none"
>
<span>
列表
</span>
<span>
列表
</span>
<q-space
/>
<q-space
/>
<q-btn
color=
"primary"
size=
"11px"
@
click=
"showhaocai"
>
选择耗材
</q-btn>
<q-btn
color=
"primary"
size=
"11px"
@
click=
"showhaocai"
v-if=
"model.Type===2"
>
选择耗材
</q-btn>
<q-btn
color=
"primary"
size=
"11px"
@
click=
"addclass_haocai"
v-if=
"model.Type===1"
>
添加
</q-btn></q-btn>
</div>
</div>
<div
class=
"q-mt-md"
>
<div
class=
"q-mt-md"
>
<!-- 班级相关 -->
<q-table
:pagination=
"pageInfo"
no-data-label=
"暂无相关数据"
flat
<q-table
:pagination=
"pageInfo"
no-data-label=
"暂无相关数据"
flat
class=
"sticky-column-table sticky-header-table sticky-right-column-table no-bottom-table"
separator=
"none"
class=
"sticky-column-table sticky-header-table sticky-right-column-table no-bottom-table"
separator=
"none"
:data=
"dataList
"
:columns=
"model.Type===1?columns:columns2"
row-key=
"name
"
>
:data=
"dataList
_class"
:columns=
"columns"
row-key=
"name"
v-if=
"model.Type!=2
"
>
<template
v-slot:body-cell-SchoolName=
"props"
>
<template
v-slot:body-cell-SchoolName=
"props"
>
<q-td
:props=
"props"
class=
"text-negative"
>
<q-td
:props=
"props"
class=
"text-negative"
>
<q-select
dense
standout
behavior=
"menu"
filled
v-model=
"props.row.SchoolId"
ref=
"school"
<q-select
dense
standout
behavior=
"menu"
filled
v-model=
"props.row.SchoolId"
ref=
"school"
...
@@ -39,11 +41,63 @@
...
@@ -39,11 +41,63 @@
:rules=
"[val => !!val || '请选择班级']"
@
input =
'filterCourseFn($event,props.rowIndex)'
/>
:rules=
"[val => !!val || '请选择班级']"
@
input =
'filterCourseFn($event,props.rowIndex)'
/>
</q-td>
</q-td>
</
template
>
</
template
>
<
template
v-slot:body-cell-CourseName=
"props"
>
<
template
v-slot:body-cell-Name=
"props"
>
<q-td
:props=
"props"
>
<div
v-for=
"item in props.row.haocaiList"
:key=
"item.id"
class=
"td_height"
>
{{
item
.
Name
||
'/'
}}
</div>
</q-td>
</
template
>
<
template
v-slot:body-cell-BrandName=
"props"
>
<q-td
:props=
"props"
>
<div
v-for=
"item in props.row.haocaiList"
:key=
"item.id"
class=
"td_height"
>
{{
item
.
BrandName
||
'/'
}}
</div>
</q-td>
</
template
>
<
template
v-slot:body-cell-CategoryName=
"props"
>
<q-td
:props=
"props"
>
<div
v-for=
"item in props.row.haocaiList"
:key=
"item.id"
class=
"td_height"
>
{{
item
.
CategoryName
||
'/'
}}
</div>
</q-td>
</
template
>
<
template
v-slot:body-cell-SupplierName=
"props"
>
<q-td
:props=
"props"
>
<div
v-for=
"item in props.row.haocaiList"
:key=
"item.id"
class=
"td_height"
>
{{
item
.
SupplierName
||
'/'
}}
</div>
</q-td>
</
template
>
<
template
v-slot:body-cell-InventoryNum=
"props"
>
<q-td
:props=
"props"
>
<div
v-for=
"item in props.row.haocaiList"
:key=
"item.id"
class=
"td_height"
>
{{
item
.
InventoryNum
}}
</div>
</q-td>
</
template
>
<
template
v-slot:body-cell-Number=
"props"
>
<q-td
:props=
"props"
class=
"text-negative"
>
<div
v-for=
"(item,index) in props.row.haocaiList"
:key=
"item.id"
>
<q-input
standout
filled
v-model
.
number=
"item.Number"
type=
"number"
ref=
"number"
:min=
'0'
:max=
'item.InventoryNum'
dense
@
input=
"chukuNum_class(item.Number,item.InventoryNum,index,props.rowIndex)"
/>
</div>
</q-td>
</
template
>
<
template
v-slot:body-cell-caozuo=
"props"
>
<q-td
:props=
"props"
class=
"text-negative"
>
<q-td
:props=
"props"
class=
"text-negative"
>
{{
props
.
CourseName
}}
<q-btn
color=
"primary"
size=
"11px"
class=
"q-mr-md"
@
click=
"showhaocai(props.rowIndex)"
>
选择耗材
</q-btn>
<q-btn
color=
"primary"
size=
"11px"
@
click=
"delhaocai_class(props.rowIndex)"
>
删除
</q-btn>
</q-td>
</q-td>
</
template
>
</
template
>
<
template
v-slot:bottom
>
</
template
>
</q-table>
<!-- 其他业务 -->
<q-table
:pagination=
"pageInfo"
no-data-label=
"暂无相关数据"
flat
class=
"sticky-column-table sticky-header-table sticky-right-column-table no-bottom-table"
separator=
"none"
:data=
"dataList"
:columns=
"columns2"
row-key=
"name"
v-if=
"model.Type===2"
>
<
template
v-slot:body-cell-Number=
"props"
>
<
template
v-slot:body-cell-Number=
"props"
>
<q-td
:props=
"props"
class=
"text-negative"
>
<q-td
:props=
"props"
class=
"text-negative"
>
<q-input
standout
filled
v-model
.
number=
"props.row.Number"
type=
"number"
ref=
"number"
:min=
'0'
:max=
'props.row.InventoryNum'
dense
@
input=
"chukuNum(props.row.Number,props.row.InventoryNum,props.rowIndex)"
/>
<q-input
standout
filled
v-model
.
number=
"props.row.Number"
type=
"number"
ref=
"number"
:min=
'0'
:max=
'props.row.InventoryNum'
dense
@
input=
"chukuNum(props.row.Number,props.row.InventoryNum,props.rowIndex)"
/>
...
@@ -67,8 +121,8 @@
...
@@ -67,8 +121,8 @@
</q-card-actions>
</q-card-actions>
<!-- 选择耗材 -->
<!-- 选择耗材 -->
<q-dialog
v-model=
"haochaidig"
persistent
>
<q-dialog
v-model=
"haochaidig"
persistent
>
<q-card
class=
"q-px-md"
style=
"width:1000px;max-width:1000px;"
>
<q-card
class=
"q-px-md"
style=
"width:1000px;max-width:1000px;"
>
<q-card-section
class=
"row items-center q-pb-none"
>
<q-card-section
class=
"row items-center q-pb-none"
>
<div
class=
"text-h6"
>
选择耗材
</div>
<div
class=
"text-h6"
>
选择耗材
</div>
<q-space
/>
<q-space
/>
<q-btn
icon=
"close"
flat
round
dense
v-close-popup
/>
<q-btn
icon=
"close"
flat
round
dense
v-close-popup
/>
...
@@ -176,16 +230,15 @@
...
@@ -176,16 +230,15 @@
return
{
return
{
typeOption
:
[{
typeOption
:
[{
id
:
1
,
id
:
1
,
name
:
"
班级相关
"
name
:
"
主营业务
"
},
},
{
{
id
:
2
,
id
:
2
,
name
:
"其他业务"
name
:
"其他业务"
}
}
],
],
model
:
{
model
:
{
Type
:
""
,
Type
:
1
,
Remark
:
""
,
Remark
:
""
,
DetailList
:[]
DetailList
:[]
},
},
...
@@ -331,7 +384,16 @@
...
@@ -331,7 +384,16 @@
courseList
:
[],
//课程列表
courseList
:
[],
//课程列表
schoolList
:[],
schoolList
:[],
classList
:[],
classList
:[],
dataList_class
:[
{
SchoolName
:
""
,
SchoolId
:
-
1
,
ClassName
:
""
,
ClassId
:
0
,
CourseName
:
""
,
haocaiList
:[]
},
],
dataList
:
[
dataList
:
[
// {
// {
// SchoolName:"",
// SchoolName:"",
...
@@ -387,13 +449,37 @@
...
@@ -387,13 +449,37 @@
initObj
()
{
initObj
()
{
this
.
dataList
=
[]
this
.
dataList
=
[]
},
},
//
保存报价
单
//
创建出库
单
saveStockOut
()
{
saveStockOut
()
{
this
.
$refs
.
type
.
validate
();
this
.
$refs
.
type
.
validate
();
if
(
if
(
!
this
.
$refs
.
type
.
hasError
!
this
.
$refs
.
type
.
hasError
)
{
)
{
console
.
log
(
11
,
this
.
model
)
if
(
this
.
model
.
Type
===
1
){
this
.
model
.
DetailList
=
[]
this
.
dataList_class
.
map
(
item
=>
{
if
(
item
.
haocaiList
.
length
>
0
){
item
.
haocaiList
.
map
(
_item
=>
{
let
obj
=
{
SchoolName
:
item
.
SchoolName
,
SchoolId
:
item
.
SchoolId
,
ClassName
:
item
.
ClassName
,
ClassId
:
item
.
ClassId
,
CourseName
:
item
.
CourseName
,
SuppliesId
:
_item
.
Id
,
Number
:
_item
.
Number
}
this
.
model
.
DetailList
.
push
(
obj
)
})
}
else
{
return
}
})
}
else
{
this
.
model
.
DetailList
=
[]
this
.
model
.
DetailList
=
[]
this
.
dataList
.
map
(
item
=>
{
this
.
dataList
.
map
(
item
=>
{
let
obj
=
{
let
obj
=
{
...
@@ -403,14 +489,23 @@
...
@@ -403,14 +489,23 @@
ClassId
:
item
.
ClassId
,
ClassId
:
item
.
ClassId
,
CourseName
:
item
.
CourseName
,
CourseName
:
item
.
CourseName
,
SuppliesId
:
item
.
Id
,
SuppliesId
:
item
.
Id
,
Number
:
item
.
Number
Number
:
item
.
Number
||
0
}
}
this
.
model
.
DetailList
.
push
(
obj
)
this
.
model
.
DetailList
.
push
(
obj
)
})
})
}
// SuppliesStockOutApply(this.model).then(res=>{
SuppliesStockOutApply
(
this
.
model
).
then
(
res
=>
{
// console.log(res)
if
(
res
.
data
.
resultCode
===
1
){
// })
this
.
$parent
.
$parent
.
$parent
.
closePop
()
}
this
.
$q
.
notify
({
position
:
'top'
,
timeout
:
2000
,
textColor
:
'white'
,
message
:
res
.
data
.
message
,
})
})
}
}
},
},
//获取校区列表
//获取校区列表
...
@@ -450,20 +545,29 @@
...
@@ -450,20 +545,29 @@
})
})
},
},
filterSchoolFn
(
val
,
index
)
{
filterSchoolFn
(
val
,
index
)
{
console
.
log
(
val
)
let
school
=
this
.
schoolList
.
filter
(
item
=>
{
let
school
=
this
.
schoolList
.
filter
(
item
=>
{
return
item
.
SId
==
val
return
item
.
SId
==
val
})
})
this
.
dataList
[
index
].
SchoolName
=
school
[
0
].
SchoolName
if
(
this
.
model
.
Type
===
1
){
this
.
dataList_class
[
index
].
SchoolName
=
school
[
0
].
SName
}
else
{
this
.
dataList
[
index
].
SchoolName
=
school
[
0
].
SName
}
this
.
$forceUpdate
();
this
.
$forceUpdate
();
},
},
filterCourseFn
(
val
,
index
)
{
filterCourseFn
(
val
,
index
)
{
console
.
log
(
val
)
let
course
=
this
.
classList
.
filter
(
item
=>
{
let
course
=
this
.
classList
.
filter
(
item
=>
{
return
item
.
ClassId
==
val
return
item
.
ClassId
==
val
})
})
this
.
dataList
[
index
].
CourseName
=
course
[
0
].
CourseName
if
(
this
.
model
.
Type
===
1
){
this
.
dataList
[
index
].
ClassName
=
course
[
0
].
ClassName
this
.
dataList_class
[
index
].
CourseName
=
course
[
0
].
CourseName
this
.
dataList_class
[
index
].
ClassName
=
course
[
0
].
ClassName
}
else
{
this
.
dataList
[
index
].
CourseName
=
course
[
0
].
CourseName
this
.
dataList
[
index
].
ClassName
=
course
[
0
].
ClassName
}
this
.
$forceUpdate
();
this
.
$forceUpdate
();
},
},
//显示耗材列表
//显示耗材列表
...
@@ -524,22 +628,32 @@
...
@@ -524,22 +628,32 @@
this
.
hcItemList
.
push
(
item
);
this
.
hcItemList
.
push
(
item
);
});
});
if
(
this
.
model
.
Type
===
1
){
if
(
this
.
model
.
Type
===
1
){
this
.
dataList
=
Array
.
from
(
new
Set
(
this
.
hcItemList
))
let
haocaidata
=
Array
.
from
(
new
Set
(
this
.
hccheckList
))
this
.
dataList
.
forEach
(
item
=>
{
haocaidata
.
forEach
(
item
=>
{
item
.
SchoolName
=
""
item
.
Number
=
0
item
.
SchoolId
=-
1
})
item
.
ClassName
=
""
this
.
dataList_class
[
this
.
chooseHcIndex
].
haocaiList
=
haocaidata
item
.
ClassId
=
0
,
item
.
CourseName
=
""
// item.Number=0
})
}
else
if
(
this
.
model
.
Type
===
2
){
}
else
if
(
this
.
model
.
Type
===
2
){
this
.
dataList
=
Array
.
from
(
new
Set
(
this
.
hcItemList
))
this
.
dataList
=
Array
.
from
(
new
Set
(
this
.
hcItemList
))
}
}
})
})
},
},
addclass_haocai
(){
let
obj
=
{
SchoolName
:
""
,
SchoolId
:
-
1
,
ClassName
:
""
,
ClassId
:
0
,
CourseName
:
""
,
haocaiList
:[]
}
this
.
dataList_class
.
push
(
obj
)
},
//删除耗材
//删除耗材
delhaocai_class
(
index
){
this
.
dataList_class
.
splice
(
index
,
1
);
},
delhaocai
(
index
){
delhaocai
(
index
){
this
.
dataList
.
splice
(
index
,
1
);
this
.
dataList
.
splice
(
index
,
1
);
},
},
...
@@ -548,6 +662,14 @@
...
@@ -548,6 +662,14 @@
this
.
haochaimsg
.
pageIndex
=
val
;
this
.
haochaimsg
.
pageIndex
=
val
;
this
.
gethaocai
();
this
.
gethaocai
();
},
},
chukuNum_class
(
val
,
maxVal
,
index
,
rowIndex
){
if
(
val
>
maxVal
){
this
.
dataList_class
[
rowIndex
].
haocaiList
[
index
].
Number
=
maxVal
}
else
if
(
val
<
0
||!
val
){
this
.
dataList_class
[
rowIndex
].
haocaiList
[
index
].
Number
=
0
}
this
.
$forceUpdate
();
},
chukuNum
(
val
,
maxVal
,
index
){
chukuNum
(
val
,
maxVal
,
index
){
this
.
$forceUpdate
();
this
.
$forceUpdate
();
...
@@ -728,9 +850,7 @@
...
@@ -728,9 +850,7 @@
cursor
:
pointer
;
cursor
:
pointer
;
}
}
.borderTable
tr
:nth-child
(
even
)
{
/* background:#F6F9FB!important; */
}
/* .borderTable .trNobottom{
/* .borderTable .trNobottom{
...
@@ -843,4 +963,11 @@
...
@@ -843,4 +963,11 @@
color
:
#F56C6C
;
color
:
#F56C6C
;
margin-right
:
4px
;
margin-right
:
4px
;
}
}
td
.q-field--with-bottom
{
padding-bottom
:
0px
}
td
.td_height
{
height
:
40px
;
line-height
:
40px
;
}
</
style
>
</
style
>
src/pages/sale/SuppliesStockOutApplyForDetail.vue
View file @
183715f0
...
@@ -2,7 +2,7 @@
...
@@ -2,7 +2,7 @@
<div
class=
"PropertyProcurementDetails padContent ck_detail"
v-loading=
"pageLoad"
>
<div
class=
"PropertyProcurementDetails padContent ck_detail"
v-loading=
"pageLoad"
>
<div
style=
"border-bottom: 1px solid #e2e4eb; padding-bottom: 10px;display:flex;align-items:center;height:50px"
>
<div
style=
"border-bottom: 1px solid #e2e4eb; padding-bottom: 10px;display:flex;align-items:center;height:50px"
>
<span
class=
"pageTitle"
style=
"float: inherit"
>
耗材出库详情
</span>
<span
class=
"pageTitle"
style=
"float: inherit"
>
耗材出库详情
</span>
<el-button
@
click=
"backTo"
round
style=
"background-color:#
089bab
;color:#fff;margin-left:15px"
>
返回
</el-button>
<el-button
@
click=
"backTo"
round
style=
"background-color:#
2961fe
;color:#fff;margin-left:15px"
>
返回
</el-button>
</div>
</div>
<div
<div
style=
"
style=
"
...
@@ -42,7 +42,8 @@
...
@@ -42,7 +42,8 @@
</p>
</p>
</el-col>
</el-col>
<el-col
:span=
"12"
>
<el-col
:span=
"12"
>
<el-button
@
click=
"SetPropertyProcurementStockIn"
round
style=
"float: right;background-color:#089bab;color:#fff"
:disabled=
"GetDetail.StockOutStatus === 3"
>
出库
</el-button>
<el-button
@
click=
"setStockoutdig=true"
round
style=
"float: right;background-color:#2961fe;color:#fff;margin-left:10px"
v-if=
"isSelfCreate"
:disabled=
"GetDetail.AuditStatus == 2"
>
修改状态
</el-button>
<el-button
@
click=
"SetStockout"
round
style=
"float: right;background-color:#2961fe;color:#fff;"
:disabled=
"GetDetail.AuditStatus != 2||GetDetail.StockOutStatus === 3"
>
出库
</el-button>
</el-col>
</el-col>
</el-row>
</el-row>
<el-row>
<el-row>
...
@@ -72,11 +73,19 @@
...
@@ -72,11 +73,19 @@
<span>
总数量 :
</span>
<span>
总数量 :
</span>
<span>
{{
GetDetail
.
TotalNumber
}}
</span>
<span>
{{
GetDetail
.
TotalNumber
}}
</span>
</el-col>
</el-col>
<el-col
:span=
"12"
style=
"display:flex"
>
<span>
仓库 :
</span>
<div>
<q-select
filled
use-input
input-debounce=
"0"
option-value=
"Id"
option-label=
"Name"
v-model=
"GetDetail.WareHouseId"
:options=
"storeList"
dense
emit-value
map-options
>
</q-select>
</div>
</el-col>
<el-col
:span=
"24"
>
<el-col
:span=
"24"
>
<span>
备注 :
</span>
<span>
备注 :
</span>
<span>
{{
GetDetail
.
Audit
Remark
}}
</span>
<span>
{{
GetDetail
.
Remark
}}
</span>
</el-col>
</el-col>
</el-row>
</el-row>
</el-col>
</el-col>
...
@@ -119,7 +128,7 @@
...
@@ -119,7 +128,7 @@
<td>
{{
item
.
Number
}}
</td>
<td>
{{
item
.
Number
}}
</td>
<td>
{{
item
.
StockOutNum
}}
</td>
<td>
{{
item
.
StockOutNum
}}
</td>
<td>
<td>
<
el-input
v-model
.
number=
"item.WaitStockOutNum"
type=
"number"
@
input=
"inputval(item.WaitStockOutNum,item.Number,index)"
:min=
"0"
:max=
"item.Number"
:disabled=
"GetDetail.StockOutStatus === 3"
></el
-input>
<
q-input
v-model
.
number=
"item.WaitStockOutNum"
type=
"number"
@
input=
"inputval(item.WaitStockOutNum,item.Number,index)"
:min=
"0"
:max=
"item.Number"
:disable=
"GetDetail.AuditStatus != 2||GetDetail.StockOutStatus === 3"
></q
-input>
</td>
</td>
</tr>
</tr>
...
@@ -129,36 +138,97 @@
...
@@ -129,36 +138,97 @@
</tbody>
</tbody>
</table>
</table>
</div>
</div>
<q-dialog
v-model=
"setStockoutdig"
>
<q-card
class=
"q-px-md"
style=
"width:1000px;"
>
<q-card-section
class=
"row items-center q-pb-none"
>
<div
class=
"text-h6"
>
修改状态
</div>
<q-space
/>
<q-btn
icon=
"close"
flat
round
dense
v-close-popup
/>
</q-card-section>
<div
class=
"col row wrap q-mr-lg q-col-gutter-md"
>
<div
class=
"col-6 q-mt-lg"
>
<q-select
filled
use-input
input-debounce=
"0"
option-value=
"id"
label=
"类型"
option-label=
"name"
v-model=
"stateMsg.Type"
:options=
"stateOption"
emit-value
map-options
>
</q-select>
</div>
</div>
<div
class=
"col row wrap q-mr-lg q-col-gutter-md"
>
<div
class=
"col-12 q-mt-lg"
>
<q-input
v-model=
"stateMsg.Remark"
label=
"备注"
type=
"textarea"
filled
></q-input>
</div>
</div>
<div
class=
"col row wrap q-mr-lg q-col-gutter-md q-mb-lg"
>
<div
class=
"col-12 q-mt-lg"
>
<q-btn
color=
"primary"
label=
"提交"
style=
"float:right"
class=
"q-ml-sm"
@
click=
"SetStockoutState"
></q-btn>
<q-btn
text-color=
"primary"
label=
"取消"
style=
"float:right"
@
click=
"setStockoutdig=false"
></q-btn>
</div>
</div>
</q-card>
</q-dialog>
</div>
</div>
</
template
>
</
template
>
<
script
>
<
script
>
import
{
GetSuppliesStockOutApplyForDetail
}
from
'../../api/sale/StockOutApplyFor'
import
{
GetSuppliesStockOutApplyForDetail
,
SuppliesStockOut
,
GetWareHouse
,
SetSuppliesStockOutApplyForState
}
from
'../../api/sale/StockOutApplyFor'
export
default
{
export
default
{
data
()
{
data
()
{
return
{
return
{
ApplyForId
:
0
,
ApplyForId
:
0
,
isSelfCreate
:
false
,
//出库单是否是登录人创建
images
:
[],
images
:
[],
imageOptions
:
{
imageOptions
:
{
navbar
:
false
,
navbar
:
false
,
title
:
false
,
title
:
false
,
},
},
pageLoad
:
false
,
pageLoad
:
false
,
storeList
:[],
GetDetail
:
{
GetDetail
:
{
WareHouseId
:
0
,
DetailList
:
[
DetailList
:
[
],
],
},
},
uploadImgList
:
[],
uploadImgList
:
[],
setStockoutdig
:
false
,
stateMsg
:{
ApplyForId
:
0
,
Type
:
1
,
Remark
:
""
,
},
stateOption
:[
{
id
:
1
,
name
:
"取消"
},
{
id
:
2
,
name
:
"审核通过"
},
{
id
:
3
,
name
:
"审核驳回"
}
]
};
};
},
},
created
()
{
created
()
{
this
.
ApplyForId
=
this
.
$route
.
query
.
Id
;
this
.
ApplyForId
=
this
.
$route
.
query
.
Id
;
this
.
stateMsg
.
ApplyForId
=
this
.
$route
.
query
.
Id
;
this
.
getDetail
();
this
.
getDetail
();
this
.
getWareHouse
();
},
mounted
()
{
},
},
mounted
()
{},
methods
:
{
methods
:
{
getWareHouse
(){
GetWareHouse
({}).
then
(
res
=>
{
this
.
storeList
=
res
.
data
.
data
})
},
inputval
(
val
,
maxVal
,
index
){
inputval
(
val
,
maxVal
,
index
){
this
.
$forceUpdate
();
this
.
$forceUpdate
();
if
(
val
>
maxVal
){
if
(
val
>
maxVal
){
...
@@ -172,45 +242,55 @@ export default {
...
@@ -172,45 +242,55 @@ export default {
},
},
getDetail
()
{
getDetail
()
{
this
.
pageLoad
=
true
;
this
.
pageLoad
=
true
;
let
that
=
this
GetSuppliesStockOutApplyForDetail
({
ApplyForId
:
this
.
ApplyForId
}).
then
(
res
=>
{
GetSuppliesStockOutApplyForDetail
({
ApplyForId
:
this
.
ApplyForId
}).
then
(
res
=>
{
this
.
pageLoad
=
false
;
this
.
pageLoad
=
false
;
if
(
res
.
data
.
resultCode
===
1
){
if
(
res
.
data
.
resultCode
===
1
){
console
.
log
(
res
.
data
.
data
)
this
.
GetDetail
=
res
.
data
.
data
this
.
GetDetail
=
res
.
data
.
data
this
.
GetDetail
.
DetailList
.
forEach
(
item
=>
{
this
.
GetDetail
.
DetailList
.
forEach
(
item
=>
{
item
.
WaitStockOutNum
=
item
.
StockOutNum
item
.
WaitStockOutNum
=
item
.
StockOutNum
})
})
that
.
isSelf
();
}
}
})
})
},
},
//
采购单入
库
//
出
库
Set
PropertyProcurementStockIn
()
{
Set
Stockout
()
{
//
let msg = {
let
msg
=
{
// Procurement
Id: this.GetDetail.Id,
Id
:
this
.
GetDetail
.
Id
,
// StockInDate: this.GetDetail.BuyDate
,
WareHouseId
:
this
.
GetDetail
.
WareHouseId
,
//
DetailList: [],
DetailList
:
[],
//
};
};
//
this.GetDetail.DetailList.map((item) => {
this
.
GetDetail
.
DetailList
.
map
((
item
)
=>
{
//
let obj = {
let
obj
=
{
//
Id:item.Id,
Id
:
item
.
Id
,
// MaterialId: item.MaterialId,
WaitStockOutNum
:
item
.
WaitStockOutNum
// WaitStockInNum: item.WaitStockInNum,
};
// }
;
msg
.
DetailList
.
push
(
obj
)
;
// msg.DetailList.push(obj
);
}
);
// });
SuppliesStockOut
(
msg
).
then
(
res
=>
{
// this.apiJavaPost(
// "/api/supplies/SetSuppliesProcurementStockIn",
})
// msg,
// (res) => {
},
// if (res.data.resultCode === 1)
{
SetStockoutState
()
{
// this.Success(res.data.message)
SetSuppliesStockOutApplyForState
(
this
.
stateMsg
).
then
(
res
=>
{
// } else
{
if
(
res
.
data
.
resultCode
===
1
)
{
// this.Error(res.data.message);
this
.
Success
(
res
.
data
.
message
)
// }
}
else
{
// },
this
.
Error
(
res
.
data
.
message
);
// null
}
// );
})
},
},
//判断登录人是否是创建人
isSelf
(){
let
loginId
=
JSON
.
parse
(
localStorage
.
getItem
(
'loginUserInfo'
)).
data
.
Id
if
(
this
.
GetDetail
.
CreateBy
===
loginId
){
this
.
isSelfCreate
=
true
}
else
{
this
.
isSelfCreate
=
false
}
}
},
},
};
};
</
script
>
</
script
>
...
...
src/pages/sale/SuppliesStockOutApplyForMan.vue
View file @
183715f0
...
@@ -163,7 +163,7 @@
...
@@ -163,7 +163,7 @@
<
template
v-slot:top=
"props"
>
<
template
v-slot:top=
"props"
>
<div
class=
"col-2 q-table__title"
>
出库管理
</div>
<div
class=
"col-2 q-table__title"
>
出库管理
</div>
<q-space
/>
<q-space
/>
<q-btn
color=
"
primary"
size=
"11px
"
@
click=
"showAdd"
>
新增出库单
</q-btn>
<q-btn
color=
"
accent"
size=
"11px"
icon=
"add
"
@
click=
"showAdd"
>
新增出库单
</q-btn>
</
template
>
</
template
>
<
template
v-slot:body-cell-StockOutStatus=
"props"
>
<
template
v-slot:body-cell-StockOutStatus=
"props"
>
<q-td
:props=
"props"
>
<q-td
:props=
"props"
>
...
@@ -422,6 +422,9 @@
...
@@ -422,6 +422,9 @@
// 显示新增出库单
// 显示新增出库单
showAdd
(){
showAdd
(){
this
.
showaddStockOut
=
true
this
.
showaddStockOut
=
true
},
closePop
(){
this
.
showaddStockOut
=
false
}
}
}
}
}
}
...
...
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