Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
saas
/
scrm-micro-purchase
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
1
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit 44269e9f
authored
Nov 17, 2023
by
chenwq
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
采购订单,膜卷号
1 parent
27ecc93d
Show whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
242 additions
and
53 deletions
src/api/modules/purchaseShopping.js
src/assets/css/public.scss
src/views/DeliverList/deliverAdd.vue
src/views/purchaseCheck/index.vue
src/views/purchaseOrder/components/FilmDialog.vue
src/views/purchaseOrder/components/orderDetailDialog.vue
src/views/purchaseOrder/into.vue
src/api/modules/purchaseShopping.js
View file @
44269e9
...
@@ -4,7 +4,7 @@ const path = 'dj.api.smarcarlife.'
...
@@ -4,7 +4,7 @@ const path = 'dj.api.smarcarlife.'
const
path2
=
'dj.api.goodsInfo.'
const
path2
=
'dj.api.goodsInfo.'
const
path3
=
'dj.api.smartcarlife.'
const
path3
=
'dj.api.smartcarlife.'
// 分页查询采购订单
// 分页查询采购订单
const
getPurchaseOrderList
=
(
params
)
=>
{
const
getPurchaseOrderList
=
params
=>
{
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
routerMethod
=
`
${
path
}
purchaseOrder.page`
params
.
routerMethod
=
`
${
path
}
purchaseOrder.page`
return
http
({
return
http
({
...
@@ -15,7 +15,7 @@ const getPurchaseOrderList = (params) => {
...
@@ -15,7 +15,7 @@ const getPurchaseOrderList = (params) => {
})
})
}
}
// 采购订单取消/审核
// 采购订单取消/审核
const
purchaseOrderCancelOrCheck
=
(
params
)
=>
{
const
purchaseOrderCancelOrCheck
=
params
=>
{
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
routerMethod
=
`
${
path
}
purchaseOrder.cancelOrCheck`
params
.
routerMethod
=
`
${
path
}
purchaseOrder.cancelOrCheck`
return
http
({
return
http
({
...
@@ -26,7 +26,7 @@ const purchaseOrderCancelOrCheck = (params) => {
...
@@ -26,7 +26,7 @@ const purchaseOrderCancelOrCheck = (params) => {
returnAll
:
true
returnAll
:
true
})
})
}
}
const
purchaseOrderDelete
=
(
params
)
=>
{
const
purchaseOrderDelete
=
params
=>
{
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
routerMethod
=
`dj.api.smarcarlife.purchaseOrder.deleteByOrderCode`
params
.
routerMethod
=
`dj.api.smarcarlife.purchaseOrder.deleteByOrderCode`
return
http
({
return
http
({
...
@@ -37,8 +37,20 @@ const purchaseOrderDelete = (params) => {
...
@@ -37,8 +37,20 @@ const purchaseOrderDelete = (params) => {
returnAll
:
true
returnAll
:
true
})
})
}
}
// 库存管理模式
const
getManageMode
=
params
=>
{
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
routerMethod
=
`dj.api.smarcarlife.stock.management.mode`
return
http
({
url
:
'rop-scrm-boutiquecoupon/router'
,
method
:
'POST'
,
data
:
params
,
sign
:
true
})
}
// 查看采购订单
// 查看采购订单
const
purchaseOrderDetail
=
(
params
)
=>
{
const
purchaseOrderDetail
=
params
=>
{
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
routerMethod
=
`
${
path
}
purchaseOrder.view`
params
.
routerMethod
=
`
${
path
}
purchaseOrder.view`
return
http
({
return
http
({
...
@@ -49,7 +61,7 @@ const purchaseOrderDetail = (params) => {
...
@@ -49,7 +61,7 @@ const purchaseOrderDetail = (params) => {
})
})
}
}
// 分页查询采购商城素材信息
// 分页查询采购商城素材信息
const
listWithPagePurchaseInfo
=
(
params
)
=>
{
const
listWithPagePurchaseInfo
=
params
=>
{
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
routerMethod
=
`
${
path2
}
listWithPage.purchaseInfo`
params
.
routerMethod
=
`
${
path2
}
listWithPage.purchaseInfo`
return
http
({
return
http
({
...
@@ -72,9 +84,8 @@ const addressGet = (params = {}) => {
...
@@ -72,9 +84,8 @@ const addressGet = (params = {}) => {
})
})
}
}
// 保存园区店商户收货地址
// 保存园区店商户收货地址
const
addressSave
=
(
params
)
=>
{
const
addressSave
=
params
=>
{
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
routerMethod
=
`
${
path
}
yqMerchantDeliveryAddress.save`
params
.
routerMethod
=
`
${
path
}
yqMerchantDeliveryAddress.save`
return
http
({
return
http
({
...
@@ -86,7 +97,7 @@ const addressSave = (params) => {
...
@@ -86,7 +97,7 @@ const addressSave = (params) => {
}
}
// 按商品类目分组获取购物车列表
// 按商品类目分组获取购物车列表
const
listGroupByGoodsType
=
(
params
)
=>
{
const
listGroupByGoodsType
=
params
=>
{
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
routerMethod
=
`
${
path
}
purchaseShoppingCar.listGroupByGoodsType`
params
.
routerMethod
=
`
${
path
}
purchaseShoppingCar.listGroupByGoodsType`
return
http
({
return
http
({
...
@@ -97,9 +108,8 @@ const listGroupByGoodsType = (params) => {
...
@@ -97,9 +108,8 @@ const listGroupByGoodsType = (params) => {
})
})
}
}
// 更新购物车商品选中标识
// 更新购物车商品选中标识
const
updateSelectedFlag
=
(
params
)
=>
{
const
updateSelectedFlag
=
params
=>
{
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
routerMethod
=
`
${
path
}
purchaseShoppingCar.updateSelectedFlag`
params
.
routerMethod
=
`
${
path
}
purchaseShoppingCar.updateSelectedFlag`
return
http
({
return
http
({
...
@@ -110,7 +120,7 @@ const updateSelectedFlag = (params) => {
...
@@ -110,7 +120,7 @@ const updateSelectedFlag = (params) => {
})
})
}
}
// 移除购物车商品
// 移除购物车商品
const
shoppingCarRemove
=
(
params
)
=>
{
const
shoppingCarRemove
=
params
=>
{
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
routerMethod
=
`
${
path
}
purchaseShoppingCar.remove`
params
.
routerMethod
=
`
${
path
}
purchaseShoppingCar.remove`
return
http
({
return
http
({
...
@@ -122,7 +132,7 @@ const shoppingCarRemove = (params) => {
...
@@ -122,7 +132,7 @@ const shoppingCarRemove = (params) => {
}
}
// 添加到购物车
// 添加到购物车
const
shoppingCarAdd
=
(
params
)
=>
{
const
shoppingCarAdd
=
params
=>
{
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
routerMethod
=
`
${
path
}
purchaseShoppingCar.add`
params
.
routerMethod
=
`
${
path
}
purchaseShoppingCar.add`
return
http
({
return
http
({
...
@@ -133,8 +143,6 @@ const shoppingCarAdd = (params) => {
...
@@ -133,8 +143,6 @@ const shoppingCarAdd = (params) => {
})
})
}
}
// 修改购物车商品数量
// 修改购物车商品数量
export
function
shoppingCarUpdateNumber
(
params
)
{
export
function
shoppingCarUpdateNumber
(
params
)
{
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
...
@@ -146,12 +154,6 @@ export function shoppingCarUpdateNumber(params) {
...
@@ -146,12 +154,6 @@ export function shoppingCarUpdateNumber(params) {
})
})
}
}
// 添加采购订单
// 添加采购订单
export
function
purchaseOrderAdd
(
params
)
{
export
function
purchaseOrderAdd
(
params
)
{
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
...
@@ -164,8 +166,6 @@ export function purchaseOrderAdd(params) {
...
@@ -164,8 +166,6 @@ export function purchaseOrderAdd(params) {
})
})
}
}
export
function
exportExcel
(
params
)
{
export
function
exportExcel
(
params
)
{
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
routerMethod
=
`dj.api.smarcarlife.purchaseOrder.export`
params
.
routerMethod
=
`dj.api.smarcarlife.purchaseOrder.export`
...
@@ -200,7 +200,7 @@ export function getMerchantList(params) {
...
@@ -200,7 +200,7 @@ export function getMerchantList(params) {
})
})
}
}
//查询园区店关联的4s店列表 -入库门店
//查询园区店关联的4s店列表 -入库门店
const
get4SRefByYqShopList
=
(
params
)
=>
{
const
get4SRefByYqShopList
=
params
=>
{
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
routerMethod
=
`dj.api.scenemerchantref.query4SRefByYqShop`
params
.
routerMethod
=
`dj.api.scenemerchantref.query4SRefByYqShop`
return
http
({
return
http
({
...
@@ -231,7 +231,7 @@ export function checkShipper(params) {
...
@@ -231,7 +231,7 @@ export function checkShipper(params) {
method
:
'POST'
,
method
:
'POST'
,
data
:
params
,
data
:
params
,
sign
:
true
,
sign
:
true
,
returnAll
:
true
returnAll
:
true
})
})
}
}
// 确认发货
// 确认发货
...
@@ -241,4 +241,4 @@ export function checkShipper(params) {
...
@@ -241,4 +241,4 @@ export function checkShipper(params) {
// return http(data)
// return http(data)
// }
// }
export
default
{
checkShipper
,
get4SRefByYqShopList
,
selectByOrderCode
,
purchaseOrderDelete
,
getMerchantList
,
purchaseOrderPutIn
,
exportExcel
,
shoppingCarUpdateNumber
,
purchaseOrderAdd
,
shoppingCarAdd
,
shoppingCarRemove
,
updateSelectedFlag
,
listGroupByGoodsType
,
getPurchaseOrderList
,
purchaseOrderCancelOrCheck
,
purchaseOrderDetail
,
listWithPagePurchaseInfo
,
addressGet
,
addressSave
}
\ No newline at end of file
\ No newline at end of file
export
default
{
checkShipper
,
get4SRefByYqShopList
,
selectByOrderCode
,
purchaseOrderDelete
,
getManageMode
,
getMerchantList
,
purchaseOrderPutIn
,
exportExcel
,
shoppingCarUpdateNumber
,
purchaseOrderAdd
,
shoppingCarAdd
,
shoppingCarRemove
,
updateSelectedFlag
,
listGroupByGoodsType
,
getPurchaseOrderList
,
purchaseOrderCancelOrCheck
,
purchaseOrderDetail
,
listWithPagePurchaseInfo
,
addressGet
,
addressSave
}
src/assets/css/public.scss
View file @
44269e9
...
@@ -5,7 +5,7 @@ html {
...
@@ -5,7 +5,7 @@ html {
margin
:
0
;
margin
:
0
;
padding
:
0
;
padding
:
0
;
overflow
:
hidden
;
overflow
:
hidden
;
background-color
:
#
F4F5FA
;
background-color
:
#
f4f5fa
;
}
}
.purchase
.container
{
.purchase
.container
{
...
@@ -21,8 +21,8 @@ html {
...
@@ -21,8 +21,8 @@ html {
.purchase
.p-t-20
{
.purchase
.p-t-20
{
padding-top
:
20px
;
padding-top
:
20px
;
}
}
.pointer
{
.pointer
{
cursor
:
pointer
;
cursor
:
pointer
;
}
}
.carIcon
{
.carIcon
{
display
:
inline-block
;
display
:
inline-block
;
...
@@ -32,6 +32,10 @@ cursor: pointer;
...
@@ -32,6 +32,10 @@ cursor: pointer;
background-size
:
100%
100%
;
background-size
:
100%
100%
;
margin-right
:
4px
;
margin-right
:
4px
;
}
}
.el-cascader-menu__wrap
{
.el-cascader-menu__wrap
{
height
:
204px
!
important
;
height
:
204px
!
important
;
}
.message-Z-zinde
{
z-index
:
9999
!
important
;
}
}
src/views/DeliverList/deliverAdd.vue
View file @
44269e9
<
template
>
<
template
>
<GLDialog
v-if=
"dialogShow"
bigTitle=
"详细信息"
mode=
"big"
:visible
.
sync=
"dialogShow"
:close-on-click-modal=
"false"
>
<div
v-if=
"dialogShow"
>
<GLDialog
bigTitle=
"详细信息"
mode=
"big"
:visible
.
sync=
"dialogShow"
:close-on-click-modal=
"false"
>
<div
class=
"detail-info"
>
<div
class=
"detail-info"
>
<div>
<div>
发货单号:
发货单号:
...
@@ -41,6 +42,16 @@
...
@@ -41,6 +42,16 @@
<
el
-
input
v
-
model
=
"scope.scope.increaseStockNum"
placeholder
=
"请输入"
@
blur
=
"handleCalculate(scope.scope, 'increaseStockNum', index)"
><
/el-input
>
<
el
-
input
v
-
model
=
"scope.scope.increaseStockNum"
placeholder
=
"请输入"
@
blur
=
"handleCalculate(scope.scope, 'increaseStockNum', index)"
><
/el-input
>
<
/el-form-item
>
<
/el-form-item
>
<
/template
>
<
/template
>
<
template
slot
=
"film"
slot
-
scope
=
"scope"
>
<
div
v
-
if
=
"manageMode && filmTypeList.includes(detailInfo.goodsType)"
>
<
el
-
button
v
-
if
=
"!scope.scope.filmRollList"
type
=
"text"
@
click
=
"handleSelectFilm(scope.scope, index, scope.index)"
>
请选择
<
/el-button
>
<
div
v
-
else
>
<
span
class
=
"film-txt"
>
...({{
scope
.
scope
.
filmRollList
.
length
}}
)
<
/span
>
<
el
-
button
type
=
"text"
@
click
=
"handleSelectFilm(scope.scope, index, scope.index)"
>
重新选择
<
/el-button
>
<
/div
>
<
/div
>
<
div
v
-
else
>--<
/div
>
<
/template
>
<!--
入库仓库
-->
<!--
入库仓库
-->
<
template
slot
=
"yqMerchantId"
slot
-
scope
=
"scope"
>
<
template
slot
=
"yqMerchantId"
slot
-
scope
=
"scope"
>
<
el
-
form
-
item
style
=
"margin-bottom: 0px"
:
prop
=
"'goodsWarehousingList.' + scope.index + '.yqMerchantId'"
:
rules
=
"rules.shopMerchantName"
>
<
el
-
form
-
item
style
=
"margin-bottom: 0px"
:
prop
=
"'goodsWarehousingList.' + scope.index + '.yqMerchantId'"
:
rules
=
"rules.shopMerchantName"
>
...
@@ -75,11 +86,14 @@
...
@@ -75,11 +86,14 @@
<
el
-
button
type
=
"primary"
size
=
"small"
@
click
=
"handleSave"
>
保存入库
<
/el-button
>
<
el
-
button
type
=
"primary"
size
=
"small"
@
click
=
"handleSave"
>
保存入库
<
/el-button
>
<
/span
>
<
/span
>
<
/GLDialog
>
<
/GLDialog
>
<
filmDialog
:
visible
.
sync
=
"filmVisible"
:
info
=
"info"
maxAddNumAttr
=
"stockAddNum"
@
handleConfirm
=
"handleFilmConfirm"
><
/filmDialog
>
<
/div
>
<
/template
>
<
/template
>
<
script
>
<
script
>
import
BigNumber
from
'bignumber.js'
import
BigNumber
from
'bignumber.js'
import
*
as
dayjs
from
'dayjs'
import
*
as
dayjs
from
'dayjs'
import
{
membraneTypeList
}
from
'@/utils/constants.js'
import
{
membraneTypeList
}
from
'@/utils/constants.js'
import
filmDialog
from
'../purchaseOrder/components/FilmDialog'
export
default
{
export
default
{
name
:
'DeliverAdd'
,
name
:
'DeliverAdd'
,
props
:
{
props
:
{
...
@@ -127,11 +141,16 @@ export default {
...
@@ -127,11 +141,16 @@ export default {
tableOption
:
true
,
tableOption
:
true
,
tableColumns
:
[
tableColumns
:
[
{
{
label
:
'入库数量'
,
label
:
'入库数量
/卷
'
,
prop
:
'increaseStockNum'
,
prop
:
'increaseStockNum'
,
addHtml
:
'increaseStockNum'
addHtml
:
'increaseStockNum'
}
,
}
,
{
{
label
:
'膜卷号'
,
prop
:
'filmRollList'
,
addHtml
:
'film'
}
,
{
label
:
'入库仓库'
,
label
:
'入库仓库'
,
prop
:
'yqMerchantId'
,
prop
:
'yqMerchantId'
,
addHtml
:
'yqMerchantId'
addHtml
:
'yqMerchantId'
...
@@ -163,10 +182,19 @@ export default {
...
@@ -163,10 +182,19 @@ export default {
}
}
]
]
}
,
}
,
tableData
:
[]
tableData
:
[],
filmVisible
:
false
,
info
:
{
}
,
filmTypeList
:
[
1
,
4
,
6
,
12
,
14
],
manageMode
:
false
}
}
}
,
}
,
created
()
{
}
,
components
:
{
filmDialog
}
,
created
()
{
this
.
getManageMode
()
}
,
methods
:
{
methods
:
{
lookNumber
(
data
)
{
lookNumber
(
data
)
{
this
.
innerVisible
=
true
this
.
innerVisible
=
true
...
@@ -175,8 +203,10 @@ export default {
...
@@ -175,8 +203,10 @@ export default {
}
)
}
)
}
,
}
,
handleCalculate
(
data
,
key
,
index
)
{
handleCalculate
(
data
,
key
,
index
)
{
if
(
data
[
key
]
>
this
.
detailInfo
.
deliveryDetailList
[
index
].
stockNum
)
{
// 膜类商品判断发货数量;其他判断可用库存数量
data
[
key
]
=
this
.
detailInfo
.
deliveryDetailList
[
index
].
stockNum
let
attr
=
this
.
filmTypeList
.
includes
(
this
.
detailInfo
.
goodsType
)
?
'purchaseNumber'
:
'stockNum'
if
(
data
[
key
]
>
this
.
detailInfo
.
deliveryDetailList
[
index
][
attr
])
{
data
[
key
]
=
this
.
detailInfo
.
deliveryDetailList
[
index
][
attr
]
return
return
}
}
data
[
key
]
=
data
[
key
]
?
new
BigNumber
(
data
[
key
]).
dp
(
2
).
toNumber
()
:
''
data
[
key
]
=
data
[
key
]
?
new
BigNumber
(
data
[
key
]).
dp
(
2
).
toNumber
()
:
''
...
@@ -187,6 +217,11 @@ export default {
...
@@ -187,6 +217,11 @@ export default {
if
(
this
.
storeUsageList
.
length
==
1
)
this
.
defaultSelect
()
if
(
this
.
storeUsageList
.
length
==
1
)
this
.
defaultSelect
()
}
)
}
)
}
,
}
,
getManageMode
()
{
this
.
$apis
.
purchaseShopping
.
getManageMode
({
}
).
then
(
res
=>
{
this
.
manageMode
=
res
}
)
}
,
defaultSelect
()
{
defaultSelect
()
{
let
{
let
{
detailInfo
:
{
deliveryDetailList
}
,
detailInfo
:
{
deliveryDetailList
}
,
...
@@ -225,6 +260,30 @@ export default {
...
@@ -225,6 +260,30 @@ export default {
}
}
}
)
}
)
}
,
}
,
filmIsVisible
()
{
this
.
filmVisible
=
!
this
.
filmVisible
}
,
handleSelectFilm
(
row
,
pIdx
,
idx
)
{
if
(
!
row
.
increaseStockNum
)
{
this
.
$message
({
message
:
'请先完善采购数量'
,
type
:
'error'
,
customClass
:
'message-Z-zinde'
}
)
return
}
this
.
filmIsVisible
()
this
.
filmIds
=
{
pIdx
:
pIdx
,
idx
:
idx
}
this
.
info
=
row
this
.
info
.
stockAddNum
=
Math
.
ceil
(
row
.
increaseStockNum
)
}
,
handleFilmConfirm
(
list
)
{
this
.
detailInfo
.
deliveryDetailList
[
this
.
filmIds
.
pIdx
].
goodsWarehousingList
[
this
.
filmIds
.
idx
].
filmRollList
=
list
this
.
filmIsVisible
()
}
,
handleDetailClose
()
{
handleDetailClose
()
{
this
.
dialogShow
=
false
this
.
dialogShow
=
false
}
,
}
,
...
@@ -301,9 +360,17 @@ export default {
...
@@ -301,9 +360,17 @@ export default {
}
}
}
)
}
)
let
params
=
{
let
params
=
{
deliveryDetailList
:
deliveryDetailList
deliveryDetailList
:
this
.
$common
.
utils
.
deepClone
(
deliveryDetailList
)
}
}
console
.
log
(
this
.
detailInfo
,
'this.detailInfo---'
)
console
.
log
(
params
,
'params----'
)
params
.
deliveryDetailList
.
forEach
(
item
=>
{
item
.
id
=
this
.
detailInfo
.
id
item
.
goodsWarehousingList
.
forEach
(
subItem
=>
{
subItem
.
increaseStockNum
=
subItem
.
increaseStockNum
*
(
item
.
stockNum
/
item
.
purchaseNumber
)
}
)
params
.
id
=
this
.
detailInfo
.
orderDeliveryId
params
.
id
=
this
.
detailInfo
.
orderDeliveryId
}
)
this
.
$apis
.
delivery
.
addPurchaseOrder
(
params
).
then
(
res
=>
{
this
.
$apis
.
delivery
.
addPurchaseOrder
(
params
).
then
(
res
=>
{
if
(
res
.
code
==
0
)
{
if
(
res
.
code
==
0
)
{
this
.
$message
({
this
.
$message
({
...
@@ -371,4 +438,16 @@ export default {
...
@@ -371,4 +438,16 @@ export default {
text
-
align
:
center
;
text
-
align
:
center
;
}
}
}
}
.
film
-
txt
{
box
-
sizing
:
border
-
box
;
height
:
32
px
;
line
-
height
:
32
px
;
background
:
#
f4f6fc
;
border
:
1
px
solid
#
eaeaec
;
font
-
weight
:
400
;
font
-
size
:
14
px
;
color
:
#
666666
;
padding
:
6
px
;
margin
-
right
:
6
px
;
}
<
/style
>
<
/style
>
src/views/purchaseCheck/index.vue
View file @
44269e9
...
@@ -24,6 +24,7 @@
...
@@ -24,6 +24,7 @@
</GLTable>
</GLTable>
<!-- 表格区域 end -->
<!-- 表格区域 end -->
</div>
</div>
<filmDialog
:visible
.
sync=
"filmVisible"
:info=
"info"
@
handleConfirm=
"handleFilmConfirm"
></filmDialog>
<rejectDialog
v-if=
"rejectDialogVisible"
:visible
.
sync=
"rejectDialogVisible"
@
handleRejectConfirm=
"handleRejectConfirm"
></rejectDialog>
<rejectDialog
v-if=
"rejectDialogVisible"
:visible
.
sync=
"rejectDialogVisible"
@
handleRejectConfirm=
"handleRejectConfirm"
></rejectDialog>
</div>
</div>
</template>
</template>
...
@@ -32,17 +33,19 @@
...
@@ -32,17 +33,19 @@
import
*
as
dayjs
from
'dayjs'
import
*
as
dayjs
from
'dayjs'
import
url
from
'@/assets/empty.png'
import
url
from
'@/assets/empty.png'
import
rejectDialog
from
'./rejectDialog'
import
rejectDialog
from
'./rejectDialog'
import
filmDialog
from
'../purchaseOrder/components/FilmDialog'
import
{
groundingCheckStatusList
,
goodsSourceOptions
}
from
'@/utils/constants.js'
import
{
groundingCheckStatusList
,
goodsSourceOptions
}
from
'@/utils/constants.js'
export
default
{
export
default
{
name
:
'purchaseCheck'
,
name
:
'purchaseCheck'
,
components
:
{
components
:
{
rejectDialog
rejectDialog
,
filmDialog
},
},
data
()
{
data
()
{
return
{
return
{
size
:
'small'
,
size
:
'small'
,
url
:
url
,
url
:
url
,
Spot
:
[
'yellowSpot'
,
'greenSpot'
,
'ashSpot'
,
'redSpot'
],
Spot
:
[
'yellowSpot'
,
'greenSpot'
,
'ashSpot'
,
'redSpot'
],
searchForm
:
{
searchForm
:
{
sortType
:
2
,
sortType
:
2
,
orderTimeStr
:
[],
orderTimeStr
:
[],
...
@@ -299,13 +302,17 @@ export default {
...
@@ -299,13 +302,17 @@ export default {
rejectDialogVisible
:
false
,
rejectDialogVisible
:
false
,
rejectObj
:
{},
rejectObj
:
{},
tipsTitleStyle
:
'style="font-size: 16px;color: #333333;"'
,
tipsTitleStyle
:
'style="font-size: 16px;color: #333333;"'
,
tipsContentStyle
:
'style="font-size: 14px;color: #666666;"'
tipsContentStyle
:
'style="font-size: 14px;color: #666666;"'
,
filmVisible
:
false
,
goodsTypeList
:
[
'自建商品-太阳膜'
,
'自建商品-车衣'
,
'自建商品-改色膜'
],
manageMode
:
false
}
}
},
},
mounted
()
{
mounted
()
{
// 获取所属分类
// 获取所属分类
this
.
getPurchaseGroundingSearchSelectData
(
1
)
this
.
getPurchaseGroundingSearchSelectData
(
1
)
this
.
getManageMode
()
},
},
methods
:
{
methods
:
{
...
@@ -325,6 +332,11 @@ export default {
...
@@ -325,6 +332,11 @@ export default {
this
.
getOptionsList
(
'showFormData'
)
this
.
getOptionsList
(
'showFormData'
)
})
})
},
},
getManageMode
()
{
this
.
$apis
.
purchaseShopping
.
getManageMode
({}).
then
(
res
=>
{
this
.
manageMode
=
res
})
},
beforeSearchFn
()
{
beforeSearchFn
()
{
return
new
Promise
(
resolve
=>
{
return
new
Promise
(
resolve
=>
{
this
.
tableSearchForm
=
this
.
getParams
()
this
.
tableSearchForm
=
this
.
getParams
()
...
@@ -357,11 +369,20 @@ export default {
...
@@ -357,11 +369,20 @@ export default {
//审核
//审核
handleCheck
(
row
)
{
handleCheck
(
row
)
{
if
(
row
?.
goodsSource
==
1
)
{
// 自营商品
if
(
row
?.
goodsSource
==
1
)
{
// 自营商品
if
(
this
.
manageMode
&&
this
.
goodsTypeList
.
includes
(
row
.
goodsTypeName
))
{
this
.
info
=
row
this
.
filmVisible
=
!
this
.
filmVisible
}
else
{
this
.
secondConfirm
(
'审核'
,
`<p
${
this
.
tipsTitleStyle
}
>是否确定审核?</p><p
${
this
.
tipsContentStyle
}
>审核通过后,系统会自动创建自采采购订单并自动入库,且无法撤回</p>`
,
'purchaseCheck'
,
'auditPurchaseCheck'
,
{
id
:
row
.
id
})
this
.
secondConfirm
(
'审核'
,
`<p
${
this
.
tipsTitleStyle
}
>是否确定审核?</p><p
${
this
.
tipsContentStyle
}
>审核通过后,系统会自动创建自采采购订单并自动入库,且无法撤回</p>`
,
'purchaseCheck'
,
'auditPurchaseCheck'
,
{
id
:
row
.
id
})
}
}
else
if
(
row
?.
goodsSource
==
0
)
{
// 嘀加商品
}
else
if
(
row
?.
goodsSource
==
0
)
{
// 嘀加商品
this
.
secondConfirm
(
'审核'
,
`<p
${
this
.
tipsTitleStyle
}
>是否确定审核?</p><p
${
this
.
tipsContentStyle
}
>审核通过后,系统会自动创建商城采购订单,且无法撤回</p>`
,
'purchaseCheck'
,
'auditPurchaseCheck'
,
{
id
:
row
.
id
})
this
.
secondConfirm
(
'审核'
,
`<p
${
this
.
tipsTitleStyle
}
>是否确定审核?</p><p
${
this
.
tipsContentStyle
}
>审核通过后,系统会自动创建商城采购订单,且无法撤回</p>`
,
'purchaseCheck'
,
'auditPurchaseCheck'
,
{
id
:
row
.
id
})
}
}
},
},
handleFilmConfirm
(
list
)
{
this
.
filmVisible
=
!
this
.
filmVisible
this
.
secondConfirm
(
'审核'
,
`<p
${
this
.
tipsTitleStyle
}
>是否确定审核?</p><p
${
this
.
tipsContentStyle
}
>审核通过后,系统会自动创建自采采购订单并自动入库,且无法撤回</p>`
,
'purchaseCheck'
,
'auditPurchaseCheck'
,
{
id
:
this
.
info
.
id
,
filmRollList
:
list
})
},
//驳回
//驳回
handleReject
(
row
)
{
handleReject
(
row
)
{
this
.
rejectObj
=
row
this
.
rejectObj
=
row
...
...
src/views/purchaseOrder/components/FilmDialog.vue
View file @
44269e9
...
@@ -7,7 +7,7 @@
...
@@ -7,7 +7,7 @@
</div>
</div>
<div>
<div>
最大可添加数量:
最大可添加数量:
<span>
{{
detailInfo
.
goodsNumber
}}
</span>
<span>
{{
detailInfo
[
maxAddNumAttr
]
}}
</span>
</div>
</div>
<div
class=
"add-btn"
@
click=
"addLineTable"
>
<div
class=
"add-btn"
@
click=
"addLineTable"
>
添加一行
添加一行
...
@@ -44,6 +44,10 @@ export default {
...
@@ -44,6 +44,10 @@ export default {
info
:
{
info
:
{
type
:
Object
,
type
:
Object
,
default
:
()
=>
{
}
default
:
()
=>
{
}
},
maxAddNumAttr
:
{
type
:
String
,
default
:
'goodsNumber'
}
}
},
},
watch
:
{
watch
:
{
...
@@ -112,7 +116,7 @@ export default {
...
@@ -112,7 +116,7 @@ export default {
}
}
},
},
addLineTable
()
{
addLineTable
()
{
if
(
this
.
filmRollList
.
length
==
this
.
detailInfo
.
goodsNumber
)
{
if
(
this
.
filmRollList
.
length
==
this
.
detailInfo
[
this
.
maxAddNumAttr
]
)
{
return
true
return
true
}
}
this
.
filmRollList
.
push
({
this
.
filmRollList
.
push
({
...
@@ -129,6 +133,14 @@ export default {
...
@@ -129,6 +133,14 @@ export default {
return
true
return
true
}
}
}
}
if
(
this
.
filmRollList
.
length
!=
this
.
detailInfo
[
this
.
maxAddNumAttr
])
{
this
.
$message
({
message
:
'请添加满足最大可添加数量的膜卷号'
,
type
:
'error'
,
customClass
:
'message-Z-zinde'
})
return
true
}
let
list
=
this
.
filmRollList
.
map
(
item
=>
item
.
filmNum
)
let
list
=
this
.
filmRollList
.
map
(
item
=>
item
.
filmNum
)
this
.
$emit
(
'handleConfirm'
,
list
)
this
.
$emit
(
'handleConfirm'
,
list
)
}
}
...
...
src/views/purchaseOrder/components/orderDetailDialog.vue
View file @
44269e9
...
@@ -24,7 +24,18 @@
...
@@ -24,7 +24,18 @@
</span>
</span>
</div>
</div>
<div
class=
"table-class"
>
<div
class=
"table-class"
>
<GLTable
ref=
"purchaseOrderDetailTable"
:tableParams=
"tableParams"
@
refreshTable=
"refreshTable"
:tableData=
"detailInfo.tableData"
:pageConf=
"pageConf"
:tableTotal=
"detailInfo.tableTotal"
></GLTable>
<GLTable
ref=
"purchaseOrderDetailTable"
:tableParams=
"tableParams"
@
refreshTable=
"refreshTable"
:tableData=
"detailInfo.tableData"
:pageConf=
"pageConf"
:tableTotal=
"detailInfo.tableTotal"
>
<template
slot=
"film"
slot-scope=
"scope"
>
<el-tooltip
v-if=
"scope.scope.filmRollList"
content=
"fjdksl"
placement=
"top"
effect=
"light"
>
<div
class=
"film-txt"
>
(...
{{
scope
.
scope
.
filmRollList
.
length
}}
)
</div>
<div
slot=
"content"
>
<div
class=
"tool-title"
>
膜卷号
</div>
<div
v-for=
"(item, index) in scope.scope.filmRollList"
:key=
"index"
>
{{
item
}}
</div>
</div>
</el-tooltip>
<div
v-else
>
--
</div>
</
template
>
</GLTable>
</div>
</div>
</div>
</div>
</GLDialog>
</GLDialog>
...
@@ -41,7 +52,7 @@ export default {
...
@@ -41,7 +52,7 @@ export default {
},
},
paramsObj
:
{
paramsObj
:
{
type
:
Object
,
type
:
Object
,
default
:
()
=>
{}
default
:
()
=>
{
}
}
}
},
},
computed
:
{
computed
:
{
...
@@ -84,7 +95,7 @@ export default {
...
@@ -84,7 +95,7 @@ export default {
{
{
label
:
'所属分类'
,
label
:
'所属分类'
,
prop
:
'goodsTypeName'
,
prop
:
'goodsTypeName'
,
width
:
1
0
0
width
:
1
5
0
},
},
{
{
label
:
'采购数量'
,
label
:
'采购数量'
,
...
@@ -97,6 +108,12 @@ export default {
...
@@ -97,6 +108,12 @@ export default {
width
:
100
width
:
100
},
},
{
{
label
:
'膜卷号'
,
prop
:
'filmRollList'
,
addHtml
:
'film'
,
width
:
100
},
{
label
:
'库存总量'
,
label
:
'库存总量'
,
prop
:
'goodsTypeName'
,
prop
:
'goodsTypeName'
,
formatter
:
cellValue
=>
{
formatter
:
cellValue
=>
{
...
@@ -125,6 +142,8 @@ export default {
...
@@ -125,6 +142,8 @@ export default {
methods
:
{
methods
:
{
dynamicParams
()
{
dynamicParams
()
{
if
(
this
.
paramsObj
.
purchaseType
==
1
)
{
if
(
this
.
paramsObj
.
purchaseType
==
1
)
{
let
idx
=
this
.
tableParams
.
tableColumns
.
findIndex
(
item
=>
item
.
label
==
'膜卷号'
)
this
.
tableParams
.
tableColumns
.
splice
(
idx
,
1
)
this
.
tableParams
.
tableColumns
.
push
(
this
.
tableParams
.
tableColumns
.
push
(
{
{
label
:
'已发货数量'
,
label
:
'已发货数量'
,
...
@@ -224,4 +243,34 @@ export default {
...
@@ -224,4 +243,34 @@ export default {
min-width
:
500px
;
min-width
:
500px
;
}
}
}
}
.film-txt
{
font-size
:
14px
;
color
:
#5850ff
;
cursor
:
pointer
;
}
.tool-title
{
font-weight
:
500
!important
;
font-size
:
12px
;
color
:
#3a3a3a
;
margin-bottom
:
4px
;
}
</
style
>
<
style
>
.el-tooltip__popper.is-light
{
background
:
#ffffff
;
border
:
1px
solid
#e5e5e5
!important
;
box-shadow
:
0
8px
20px
0
#00000033
;
width
:
177px
;
box-sizing
:
border-box
;
font-size
:
12px
;
color
:
#666666
;
line-height
:
18px
;
}
.el-tooltip__popper
[
x-placement
^=
'top'
]
.popper__arrow
{
border-color
:
#e4e7ed
!important
;
}
.el-tooltip__popper
[
x-placement
^=
'top'
]
.popper__arrow
:after
{
border-bottom-color
:
#e4e7ed
!important
;
}
</
style
>
</
style
>
src/views/purchaseOrder/into.vue
View file @
44269e9
...
@@ -20,10 +20,10 @@
...
@@ -20,10 +20,10 @@
</el-form-item>
</el-form-item>
</
template
>
</
template
>
<
template
slot=
"film"
slot-scope=
"scope"
>
<
template
slot=
"film"
slot-scope=
"scope"
>
<div
v-if=
"
scope.scope.goodsName == '太阳膜'
"
>
<div
v-if=
"
manageMode && goodsTypeList.includes(scope.scope.goodsTypeName)
"
>
<el-button
v-if=
"!scope.scope.filmRollList"
type=
"text"
@
click=
"handleSelectFilm(scope.scope, scope.index)"
>
请选择
</el-button>
<el-button
v-if=
"!scope.scope.filmRollList"
type=
"text"
@
click=
"handleSelectFilm(scope.scope, scope.index)"
>
请选择
</el-button>
<div
v-else
>
<div
v-else
>
{{
scope
.
scope
.
filmRollList
.
length
}}
<span
class=
"film-txt"
>
...(
{{
scope
.
scope
.
filmRollList
.
length
}}
)
</span>
<el-button
type=
"text"
@
click=
"handleSelectFilm(scope.scope, scope.index)"
>
重新选择
</el-button>
<el-button
type=
"text"
@
click=
"handleSelectFilm(scope.scope, scope.index)"
>
重新选择
</el-button>
</div>
</div>
</div>
</div>
...
@@ -106,7 +106,7 @@ export default {
...
@@ -106,7 +106,7 @@ export default {
putMerchantId
:
[{
required
:
true
,
message
:
'请选择入库门店'
,
trigger
:
'change'
}]
putMerchantId
:
[{
required
:
true
,
message
:
'请选择入库门店'
,
trigger
:
'change'
}]
},
},
formdata
:
{
formdata
:
{
tableData
:
[{
upgradeGoodsId
:
''
,
type
:
''
,
goodsName
:
''
,
goodsNumber
:
''
,
upgradePurchasePrice
:
''
,
goodsTotalPrice
:
''
,
putYqMerchantId
:
''
,
putYqMerchantName
:
''
,
putMerchantId
:
''
,
putMerchantName
:
''
,
refByYqShopList
:
[]
}]
tableData
:
[{
upgradeGoodsId
:
''
,
type
:
''
,
goodsName
:
''
,
goods
TypeName
:
''
,
goods
Number
:
''
,
upgradePurchasePrice
:
''
,
goodsTotalPrice
:
''
,
putYqMerchantId
:
''
,
putYqMerchantName
:
''
,
putMerchantId
:
''
,
putMerchantName
:
''
,
refByYqShopList
:
[]
}]
},
},
tableParams
:
{
tableParams
:
{
tableOption
:
true
,
tableOption
:
true
,
...
@@ -121,8 +121,8 @@ export default {
...
@@ -121,8 +121,8 @@ export default {
prop
:
'type'
prop
:
'type'
},
},
{
{
label
:
'所属
系列
'
,
label
:
'所属
分类
'
,
prop
:
'goodsName'
prop
:
'goods
Type
Name'
},
},
{
{
label
:
'采购数量'
,
label
:
'采购数量'
,
...
@@ -160,7 +160,9 @@ export default {
...
@@ -160,7 +160,9 @@ export default {
storeUsageList
:
[],
storeUsageList
:
[],
refByYqShopList
:
[],
refByYqShopList
:
[],
filmVisible
:
false
,
filmVisible
:
false
,
info
:
{}
info
:
{},
goodsTypeList
:
[
'自建商品-太阳膜'
,
'自建商品-车衣'
,
'自建商品-改色膜'
],
manageMode
:
false
}
}
},
},
components
:
{
components
:
{
...
@@ -169,6 +171,7 @@ export default {
...
@@ -169,6 +171,7 @@ export default {
created
()
{
created
()
{
this
.
getfwsGoodsList
()
this
.
getfwsGoodsList
()
this
.
getMerchantList
()
this
.
getMerchantList
()
this
.
getManageMode
()
if
(
this
.
orderCode
)
this
.
getData
()
if
(
this
.
orderCode
)
this
.
getData
()
},
},
methods
:
{
methods
:
{
...
@@ -178,6 +181,11 @@ export default {
...
@@ -178,6 +181,11 @@ export default {
if
(
this
.
storeUsageList
.
length
==
1
)
this
.
defaultSelect
()
if
(
this
.
storeUsageList
.
length
==
1
)
this
.
defaultSelect
()
})
})
},
},
getManageMode
()
{
this
.
$apis
.
purchaseShopping
.
getManageMode
({}).
then
(
res
=>
{
this
.
manageMode
=
res
})
},
defaultSelect
()
{
defaultSelect
()
{
let
{
let
{
formdata
:
{
tableData
},
formdata
:
{
tableData
},
...
@@ -208,13 +216,15 @@ export default {
...
@@ -208,13 +216,15 @@ export default {
purchaseOrderGoodsList
.
push
({
purchaseOrderGoodsList
.
push
({
upgradeGoodsId
:
item
.
upgradeGoodsId
,
upgradeGoodsId
:
item
.
upgradeGoodsId
,
goodsName
:
item
.
goodsName
,
goodsName
:
item
.
goodsName
,
goodsTypeName
:
item
.
goodsTypeName
,
goodsNumber
:
item
.
goodsNumber
,
goodsNumber
:
item
.
goodsNumber
,
upgradePurchasePrice
:
item
.
upgradePurchasePrice
,
upgradePurchasePrice
:
item
.
upgradePurchasePrice
,
goodsTotalPrice
:
item
.
goodsTotalPrice
,
goodsTotalPrice
:
item
.
goodsTotalPrice
,
putYqMerchantId
:
item
.
putYqMerchantId
,
putYqMerchantId
:
item
.
putYqMerchantId
,
putYqMerchantName
:
item
.
putYqMerchantName
,
putYqMerchantName
:
item
.
putYqMerchantName
,
putMerchantId
:
item
.
putMerchantId
,
putMerchantId
:
item
.
putMerchantId
,
putMerchantName
:
item
.
putMerchantName
putMerchantName
:
item
.
putMerchantName
,
filmRollList
:
item
.
filmRollList
})
})
})
})
let
params
=
{
let
params
=
{
...
@@ -274,6 +284,7 @@ export default {
...
@@ -274,6 +284,7 @@ export default {
if
(
item
.
upgradeGoodsId
==
id
)
{
if
(
item
.
upgradeGoodsId
==
id
)
{
data
.
type
=
item
.
type
data
.
type
=
item
.
type
data
.
goodsName
=
item
.
goodsCodeName
data
.
goodsName
=
item
.
goodsCodeName
data
.
goodsTypeName
=
item
.
goodsTypeName
}
}
})
})
},
},
...
@@ -356,6 +367,7 @@ export default {
...
@@ -356,6 +367,7 @@ export default {
upgradeGoodsId
:
''
,
upgradeGoodsId
:
''
,
type
:
''
,
type
:
''
,
goodsName
:
''
,
goodsName
:
''
,
goodsTypeName
:
''
,
goodsNumber
:
''
,
goodsNumber
:
''
,
upgradePurchasePrice
:
''
,
upgradePurchasePrice
:
''
,
goodsTotalPrice
:
''
,
goodsTotalPrice
:
''
,
...
@@ -398,5 +410,17 @@ export default {
...
@@ -398,5 +410,17 @@ export default {
/
deep
/
td
.el-table__cell
{
/
deep
/
td
.el-table__cell
{
height
:
64px
;
height
:
64px
;
}
}
.film-txt
{
box-sizing
:
border-box
;
height
:
32px
;
line-height
:
32px
;
background
:
#f4f6fc
;
border
:
1px
solid
#eaeaec
;
font-weight
:
400
;
font-size
:
14px
;
color
:
#666666
;
padding
:
6px
;
margin-right
:
6px
;
}
}
}
</
style
>
</
style
>
Write
Preview
Markdown
is supported
Attach a file
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 post a comment