Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
saas
/
scrm-micro-inventory
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit 8f592da3
authored
May 22, 2023
by
王志慧
Browse Files
Options
Browse Files
Tag
Download
Plain Diff
Merge branch 'saas+v4.20.1' into v4.22.0
2 parents
c2c8930e
4445f8f4
Show whitespace changes
Inline
Side-by-side
Showing
13 changed files
with
1379 additions
and
272 deletions
package-lock.json
src/api/modules/stockManage.js
src/components/glsx-form/index.vue
src/views/allocation/add.vue
src/views/allocation/index.vue
src/views/check/add.vue
src/views/check/index.vue
src/views/earlyWarning/index.vue
src/views/outbound/index.vue
src/views/stock/index.vue
src/views/stock/stockDetailDialog.vue
src/views/stock/stockMonthDialog.vue
src/views/warehousing/index.vue
package-lock.json
View file @
8f592da
{
{
"name"
:
"
purchase
"
,
"name"
:
"
inventory
"
,
"version"
:
"1.0.0"
,
"version"
:
"1.0.0"
,
"lockfileVersion"
:
1
,
"lockfileVersion"
:
1
,
"requires"
:
true
,
"requires"
:
true
,
...
@@ -1895,51 +1895,6 @@
...
@@ -1895,51 +1895,6 @@
"integrity"
:
"sha512-nQyp0o1/mNdbTO1PO6kHkwSrmgZ0MT/jCCpNiwbUjGoRN4dlBhqJtoQuCnEOKzgTVwg0ZWiCoQy6SxMebQVh8A=="
,
"integrity"
:
"sha512-nQyp0o1/mNdbTO1PO6kHkwSrmgZ0MT/jCCpNiwbUjGoRN4dlBhqJtoQuCnEOKzgTVwg0ZWiCoQy6SxMebQVh8A=="
,
"dev"
:
true
"dev"
:
true
},
},
"ansi-styles"
:
{
"version"
:
"4.3.0"
,
"resolved"
:
"https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz"
,
"integrity"
:
"sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg=="
,
"dev"
:
true
,
"optional"
:
true
,
"requires"
:
{
"color-convert"
:
"^2.0.1"
}
},
"chalk"
:
{
"version"
:
"4.1.2"
,
"resolved"
:
"https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz"
,
"integrity"
:
"sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA=="
,
"dev"
:
true
,
"optional"
:
true
,
"requires"
:
{
"ansi-styles"
:
"^4.1.0"
,
"supports-color"
:
"^7.1.0"
}
},
"color-convert"
:
{
"version"
:
"2.0.1"
,
"resolved"
:
"https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz"
,
"integrity"
:
"sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ=="
,
"dev"
:
true
,
"optional"
:
true
,
"requires"
:
{
"color-name"
:
"~1.1.4"
}
},
"color-name"
:
{
"version"
:
"1.1.4"
,
"resolved"
:
"https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz"
,
"integrity"
:
"sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA=="
,
"dev"
:
true
,
"optional"
:
true
},
"has-flag"
:
{
"version"
:
"4.0.0"
,
"resolved"
:
"https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz"
,
"integrity"
:
"sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ=="
,
"dev"
:
true
,
"optional"
:
true
},
"ssri"
:
{
"ssri"
:
{
"version"
:
"8.0.1"
,
"version"
:
"8.0.1"
,
"resolved"
:
"https://registry.npmjs.org/ssri/-/ssri-8.0.1.tgz"
,
"resolved"
:
"https://registry.npmjs.org/ssri/-/ssri-8.0.1.tgz"
,
...
@@ -1948,28 +1903,6 @@
...
@@ -1948,28 +1903,6 @@
"requires"
:
{
"requires"
:
{
"minipass"
:
"^3.1.1"
"minipass"
:
"^3.1.1"
}
}
},
"supports-color"
:
{
"version"
:
"7.2.0"
,
"resolved"
:
"https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz"
,
"integrity"
:
"sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw=="
,
"dev"
:
true
,
"optional"
:
true
,
"requires"
:
{
"has-flag"
:
"^4.0.0"
}
},
"vue-loader-v16"
:
{
"version"
:
"npm:vue-loader@16.8.3"
,
"resolved"
:
"https://registry.npmjs.org/vue-loader/-/vue-loader-16.8.3.tgz"
,
"integrity"
:
"sha512-7vKN45IxsKxe5GcVCbc2qFU5aWzyiLrYJyUuMz4BQLKctCj/fmCa0w6fGiiQ2cLFetNcek1ppGJQDCup0c1hpA=="
,
"dev"
:
true
,
"optional"
:
true
,
"requires"
:
{
"chalk"
:
"^4.1.0"
,
"hash-sum"
:
"^2.0.0"
,
"loader-utils"
:
"^2.0.0"
}
}
}
}
}
},
},
...
@@ -13414,6 +13347,75 @@
...
@@ -13414,6 +13347,75 @@
}
}
}
}
},
},
"vue-loader-v16"
:
{
"version"
:
"npm:vue-loader@16.8.3"
,
"resolved"
:
"https://registry.npmjs.org/vue-loader/-/vue-loader-16.8.3.tgz"
,
"integrity"
:
"sha512-7vKN45IxsKxe5GcVCbc2qFU5aWzyiLrYJyUuMz4BQLKctCj/fmCa0w6fGiiQ2cLFetNcek1ppGJQDCup0c1hpA=="
,
"dev"
:
true
,
"optional"
:
true
,
"requires"
:
{
"chalk"
:
"^4.1.0"
,
"hash-sum"
:
"^2.0.0"
,
"loader-utils"
:
"^2.0.0"
},
"dependencies"
:
{
"ansi-styles"
:
{
"version"
:
"4.3.0"
,
"resolved"
:
"https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz"
,
"integrity"
:
"sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg=="
,
"dev"
:
true
,
"optional"
:
true
,
"requires"
:
{
"color-convert"
:
"^2.0.1"
}
},
"chalk"
:
{
"version"
:
"4.1.2"
,
"resolved"
:
"https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz"
,
"integrity"
:
"sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA=="
,
"dev"
:
true
,
"optional"
:
true
,
"requires"
:
{
"ansi-styles"
:
"^4.1.0"
,
"supports-color"
:
"^7.1.0"
}
},
"color-convert"
:
{
"version"
:
"2.0.1"
,
"resolved"
:
"https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz"
,
"integrity"
:
"sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ=="
,
"dev"
:
true
,
"optional"
:
true
,
"requires"
:
{
"color-name"
:
"~1.1.4"
}
},
"color-name"
:
{
"version"
:
"1.1.4"
,
"resolved"
:
"https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz"
,
"integrity"
:
"sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA=="
,
"dev"
:
true
,
"optional"
:
true
},
"has-flag"
:
{
"version"
:
"4.0.0"
,
"resolved"
:
"https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz"
,
"integrity"
:
"sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ=="
,
"dev"
:
true
,
"optional"
:
true
},
"supports-color"
:
{
"version"
:
"7.2.0"
,
"resolved"
:
"https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz"
,
"integrity"
:
"sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw=="
,
"dev"
:
true
,
"optional"
:
true
,
"requires"
:
{
"has-flag"
:
"^4.0.0"
}
}
}
},
"vue-router"
:
{
"vue-router"
:
{
"version"
:
"3.6.5"
,
"version"
:
"3.6.5"
,
"resolved"
:
"https://registry.npmjs.org/vue-router/-/vue-router-3.6.5.tgz"
,
"resolved"
:
"https://registry.npmjs.org/vue-router/-/vue-router-3.6.5.tgz"
,
...
...
src/api/modules/stockManage.js
View file @
8f592da
import
{
http
}
from
'@/main'
import
{
http
}
from
'@/main'
const
path
=
"dj.api.smartcarlife."
const
path
=
'dj.api.smartcarlife.'
const
path2
=
"dj.api."
const
path2
=
'dj.api.'
const
path3
=
"dj.smartcarlife.api."
const
path3
=
'dj.smartcarlife.api.'
const
path4
=
"dj.api.goodsCategoryConfiguration."
const
path4
=
'dj.api.goodsCategoryConfiguration.'
// 获取当前登录账号可见的园区店列表
// 获取当前登录账号可见的园区店列表
const
getyqMerchantList
=
(
params
)
=>
{
const
getyqMerchantList
=
params
=>
{
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
routerMethod
=
`
${
path
}
permission.yqMerchant.list`
params
.
routerMethod
=
`
${
path
}
permission.yqMerchant.list`
return
http
({
return
http
({
...
@@ -17,8 +17,20 @@ const getyqMerchantList = (params) => {
...
@@ -17,8 +17,20 @@ const getyqMerchantList = (params) => {
})
})
}
}
// 根据仓库获取门店列表
const
getServicemerchantrefList
=
params
=>
{
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
routerMethod
=
`
${
path2
}
servicemerchantref.list`
return
http
({
url
:
'rop-scrm-boutiquecoupon/router'
,
method
:
'POST'
,
data
:
params
,
sign
:
true
})
}
// 入库管理列表
// 入库管理列表
const
getGoodsWarehousingList
=
(
params
)
=>
{
const
getGoodsWarehousingList
=
params
=>
{
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
routerMethod
=
`
${
path2
}
life.GoodsWarehousingInfo.list`
params
.
routerMethod
=
`
${
path2
}
life.GoodsWarehousingInfo.list`
return
http
({
return
http
({
...
@@ -30,7 +42,7 @@ const getGoodsWarehousingList = (params) => {
...
@@ -30,7 +42,7 @@ const getGoodsWarehousingList = (params) => {
}
}
// 库存记录分页查询
// 库存记录分页查询
const
getMerchantGoodsStockMonthReport
=
(
params
)
=>
{
const
getMerchantGoodsStockMonthReport
=
params
=>
{
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
routerMethod
=
`
${
path
}
MerchantGoodsStockMonthReport.page`
params
.
routerMethod
=
`
${
path
}
MerchantGoodsStockMonthReport.page`
return
http
({
return
http
({
...
@@ -42,7 +54,7 @@ const getMerchantGoodsStockMonthReport = (params) => {
...
@@ -42,7 +54,7 @@ const getMerchantGoodsStockMonthReport = (params) => {
}
}
// 月度的库存结算单
// 月度的库存结算单
const
getReportByGoods
=
(
params
)
=>
{
const
getReportByGoods
=
params
=>
{
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
routerMethod
=
`
${
path
}
MerchantGoodsStockMonthReport.listByGoods`
params
.
routerMethod
=
`
${
path
}
MerchantGoodsStockMonthReport.listByGoods`
return
http
({
return
http
({
...
@@ -54,7 +66,7 @@ const getReportByGoods = (params) => {
...
@@ -54,7 +66,7 @@ const getReportByGoods = (params) => {
}
}
// 出库记录查询
// 出库记录查询
const
getMerchantGoodsStockReduceRecord
=
(
params
)
=>
{
const
getMerchantGoodsStockReduceRecord
=
params
=>
{
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
routerMethod
=
`
${
path
}
MerchantGoodsStockReduceRecord.page`
params
.
routerMethod
=
`
${
path
}
MerchantGoodsStockReduceRecord.page`
return
http
({
return
http
({
...
@@ -66,7 +78,7 @@ const getMerchantGoodsStockReduceRecord = (params) => {
...
@@ -66,7 +78,7 @@ const getMerchantGoodsStockReduceRecord = (params) => {
}
}
// 分页查询盘点单列表
// 分页查询盘点单列表
const
stockCheckPage
=
(
params
)
=>
{
const
stockCheckPage
=
params
=>
{
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
routerMethod
=
`
${
path3
}
stock.check.page`
params
.
routerMethod
=
`
${
path3
}
stock.check.page`
return
http
({
return
http
({
...
@@ -77,7 +89,7 @@ const stockCheckPage = (params) => {
...
@@ -77,7 +89,7 @@ const stockCheckPage = (params) => {
})
})
}
}
// // 分页查询盘点详细信息
// // 分页查询盘点详细信息
const
stockCheckDetailPage
=
(
params
)
=>
{
const
stockCheckDetailPage
=
params
=>
{
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
routerMethod
=
`
${
path3
}
stock.check.detail.page`
params
.
routerMethod
=
`
${
path3
}
stock.check.detail.page`
return
http
({
return
http
({
...
@@ -89,9 +101,10 @@ const stockCheckDetailPage = (params) => {
...
@@ -89,9 +101,10 @@ const stockCheckDetailPage = (params) => {
}
}
// 商品库存列表(创建盘点、调拨时展示)
// 商品库存列表(创建盘点、调拨时展示)
const
stockRemainPage
=
(
params
)
=>
{
const
stockRemainPage
=
params
=>
{
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
routerMethod
=
`
${
path3
}
stock.remain.page`
// params.routerMethod = `${path3}stock.remain.page`
params
.
routerMethod
=
`
${
path
}
merchantShopGoodsStock.page`
return
http
({
return
http
({
url
:
'rop-scrm-boutiquecoupon/router'
,
url
:
'rop-scrm-boutiquecoupon/router'
,
method
:
'POST'
,
method
:
'POST'
,
...
@@ -101,7 +114,7 @@ const stockRemainPage = (params) => {
...
@@ -101,7 +114,7 @@ const stockRemainPage = (params) => {
}
}
// 保存盘点确认单
// 保存盘点确认单
const
saveStockCheck
=
(
params
)
=>
{
const
saveStockCheck
=
params
=>
{
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
routerMethod
=
`
${
path3
}
stock.check.save`
params
.
routerMethod
=
`
${
path3
}
stock.check.save`
return
http
({
return
http
({
...
@@ -124,7 +137,7 @@ const saveStockCheck = (params) => {
...
@@ -124,7 +137,7 @@ const saveStockCheck = (params) => {
// }
// }
// 分页查询调拨单列表
// 分页查询调拨单列表
const
stockAllocatePage
=
(
params
)
=>
{
const
stockAllocatePage
=
params
=>
{
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
routerMethod
=
`
${
path3
}
stock.allocate.page`
params
.
routerMethod
=
`
${
path3
}
stock.allocate.page`
return
http
({
return
http
({
...
@@ -136,7 +149,7 @@ const stockAllocatePage = (params) => {
...
@@ -136,7 +149,7 @@ const stockAllocatePage = (params) => {
}
}
// 分页查询调拨详细信息
// 分页查询调拨详细信息
const
stockAllocateDetailPage
=
(
params
)
=>
{
const
stockAllocateDetailPage
=
params
=>
{
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
routerMethod
=
`
${
path3
}
stock.allocate.detail.page`
params
.
routerMethod
=
`
${
path3
}
stock.allocate.detail.page`
return
http
({
return
http
({
...
@@ -147,7 +160,7 @@ const stockAllocateDetailPage = (params) => {
...
@@ -147,7 +160,7 @@ const stockAllocateDetailPage = (params) => {
})
})
}
}
//导出
//导出
const
exportExcel
=
(
params
)
=>
{
const
exportExcel
=
params
=>
{
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
routerMethod
=
`dj.api.goodsWarehousing.exportExcel`
params
.
routerMethod
=
`dj.api.goodsWarehousing.exportExcel`
return
http
({
return
http
({
...
@@ -158,7 +171,7 @@ const exportExcel = (params) => {
...
@@ -158,7 +171,7 @@ const exportExcel = (params) => {
})
})
}
}
//导出
//导出
const
exportMerchantExcel
=
(
params
)
=>
{
const
exportMerchantExcel
=
params
=>
{
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
routerMethod
=
`dj.api.smartcarlife.MerchantGoodsStockMonthReport.export`
params
.
routerMethod
=
`dj.api.smartcarlife.MerchantGoodsStockMonthReport.export`
return
http
({
return
http
({
...
@@ -169,7 +182,7 @@ const exportMerchantExcel = (params) => {
...
@@ -169,7 +182,7 @@ const exportMerchantExcel = (params) => {
})
})
}
}
//导出
//导出
const
exportReduceExcel
=
(
params
)
=>
{
const
exportReduceExcel
=
params
=>
{
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
routerMethod
=
`dj.api.smartcarlife.MerchantGoodsStockReduceRecord.export`
params
.
routerMethod
=
`dj.api.smartcarlife.MerchantGoodsStockReduceRecord.export`
return
http
({
return
http
({
...
@@ -181,7 +194,7 @@ const exportReduceExcel = (params) => {
...
@@ -181,7 +194,7 @@ const exportReduceExcel = (params) => {
}
}
//导出
//导出
const
exportCheckExcel
=
(
params
)
=>
{
const
exportCheckExcel
=
params
=>
{
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
routerMethod
=
`dj.smartcarlife.api.stock.check.export`
params
.
routerMethod
=
`dj.smartcarlife.api.stock.check.export`
return
http
({
return
http
({
...
@@ -192,7 +205,7 @@ const exportCheckExcel = (params) => {
...
@@ -192,7 +205,7 @@ const exportCheckExcel = (params) => {
})
})
}
}
//导出
//导出
const
exportaAllocateExcel
=
(
params
)
=>
{
const
exportaAllocateExcel
=
params
=>
{
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
routerMethod
=
`dj.smartcarlife.api.stock.allocate.export`
params
.
routerMethod
=
`dj.smartcarlife.api.stock.allocate.export`
return
http
({
return
http
({
...
@@ -202,7 +215,7 @@ const exportaAllocateExcel = (params) => {
...
@@ -202,7 +215,7 @@ const exportaAllocateExcel = (params) => {
sign
:
true
sign
:
true
})
})
}
}
const
exportaInventExcel
=
(
params
)
=>
{
const
exportaInventExcel
=
params
=>
{
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
routerMethod
=
`dj.api.life.InventoryWarningInfo.exportExcel`
params
.
routerMethod
=
`dj.api.life.InventoryWarningInfo.exportExcel`
return
http
({
return
http
({
...
@@ -213,9 +226,8 @@ const exportaInventExcel = (params) => {
...
@@ -213,9 +226,8 @@ const exportaInventExcel = (params) => {
})
})
}
}
// 保存调拨单
// 保存调拨单
const
saveStockAllocate
=
(
params
)
=>
{
const
saveStockAllocate
=
params
=>
{
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
routerMethod
=
`
${
path3
}
stock.allocate.save`
params
.
routerMethod
=
`
${
path3
}
stock.allocate.save`
return
http
({
return
http
({
...
@@ -226,10 +238,8 @@ const saveStockAllocate = (params) => {
...
@@ -226,10 +238,8 @@ const saveStockAllocate = (params) => {
})
})
}
}
// 调入门店
// 调入门店
const
yqRelatedList
=
(
params
)
=>
{
const
yqRelatedList
=
params
=>
{
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
routerMethod
=
`
${
path3
}
yqRelated.yqMerchant.list`
params
.
routerMethod
=
`
${
path3
}
yqRelated.yqMerchant.list`
return
http
({
return
http
({
...
@@ -251,5 +261,29 @@ export function inventoryWarningList(params) {
...
@@ -251,5 +261,29 @@ export function inventoryWarningList(params) {
sign
:
true
sign
:
true
})
})
}
}
// 获取门店库存列表
export
function
merchantShopGoodsStockPage
(
params
)
{
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
routerMethod
=
`
${
path
}
merchantShopGoodsStock.page`
// return request(data, RequestMethods.POST)
return
http
({
url
:
'rop-scrm-boutiquecoupon/router'
,
method
:
'POST'
,
data
:
params
,
sign
:
true
})
}
export
default
{
inventoryWarningList
,
exportaInventExcel
,
exportaAllocateExcel
,
exportCheckExcel
,
exportReduceExcel
,
exportMerchantExcel
,
exportExcel
,
saveStockAllocate
,
stockAllocateDetailPage
,
stockAllocatePage
,
yqRelatedList
,
saveStockCheck
,
stockRemainPage
,
stockCheckDetailPage
,
stockCheckPage
,
getMerchantGoodsStockReduceRecord
,
getReportByGoods
,
getyqMerchantList
,
getGoodsWarehousingList
,
getMerchantGoodsStockMonthReport
}
\ No newline at end of file
\ No newline at end of file
// 是否有发货主体
export
function
checkShipper
(
params
)
{
params
.
method
=
`scrm.api.boutiquecoupon.rop.router.twoCityTale`
params
.
routerMethod
=
`dj.api.smarcarlife.purchaseOrder.checkShipper`
return
http
({
url
:
'rop-scrm-boutiquecoupon/router'
,
method
:
'POST'
,
data
:
params
,
sign
:
true
,
returnAll
:
true
})
}
export
default
{
inventoryWarningList
,
exportaInventExcel
,
exportaAllocateExcel
,
exportCheckExcel
,
exportReduceExcel
,
exportMerchantExcel
,
exportExcel
,
saveStockAllocate
,
stockAllocateDetailPage
,
stockAllocatePage
,
yqRelatedList
,
saveStockCheck
,
stockRemainPage
,
stockCheckDetailPage
,
stockCheckPage
,
getMerchantGoodsStockReduceRecord
,
getReportByGoods
,
getyqMerchantList
,
getGoodsWarehousingList
,
getMerchantGoodsStockMonthReport
,
merchantShopGoodsStockPage
,
getServicemerchantrefList
,
checkShipper
}
src/components/glsx-form/index.vue
View file @
8f592da
...
@@ -368,7 +368,8 @@
...
@@ -368,7 +368,8 @@
</div>
</div>
</el-row>
</el-row>
</
template
>
</
template
>
<span
v-else
>
{{ item.name ? formData[item.name] : item.value }}
</span>
<!-- <span v-else>{{ item.name ? formData[item.name] : item.value }}</span> -->
<span
v-else
></span>
</el-form-item>
</el-form-item>
<div
v-show=
"item.tips"
<div
v-show=
"item.tips"
class=
"item-tips"
>
class=
"item-tips"
>
...
@@ -461,7 +462,7 @@ export default {
...
@@ -461,7 +462,7 @@ export default {
name
:
'D2Form'
,
name
:
'D2Form'
,
data
()
{
data
()
{
return
{
return
{
userInfo
:
{
detail
:{}
},
userInfo
:
{
detail
:
{}
},
warrantyProList
,
warrantyProList
,
merchantDisable
:
false
,
merchantDisable
:
false
,
storeSearchForm
:
{
storeSearchForm
:
{
...
...
src/views/allocation/add.vue
View file @
8f592da
<
template
>
<
template
>
<div
class=
"addWrap"
>
<div
class=
"addWrap"
>
<div
class=
"d2-container-content gl-form-min"
style=
"padding: 10px 20px"
>
<div
class=
"d2-container-content gl-form-min"
<el-form
:inline=
"true"
size=
"small"
:model=
"editAllocationForm"
ref=
"editAllocationFormRef"
:rules=
"formRules"
style=
"padding: 10px 20px"
>
<el-form
:inline=
"true"
size=
"small"
:model=
"editAllocationForm"
ref=
"editAllocationFormRef"
:rules=
"formRules"
class=
"demo-form-inline"
>
class=
"demo-form-inline"
>
<el-form-item
label=
"调出门店:"
prop=
"callOutYqMerchantId"
>
<el-form-item>
调出方
</el-form-item>
<el-select
v-model=
"editAllocationForm.callOutYqMerchantId"
style=
"width: 300px"
>
<el-form-item
label=
"调出仓库:"
<el-option
v-for=
"item in callOutYqMerchantList"
:key=
"item.merchantNo"
:label=
"item.merchantName"
prop=
"callOutYqMerchantId"
>
<el-select
v-model=
"editAllocationForm.callOutYqMerchantId"
style=
"width: 300px"
>
<el-option
v-for=
"item in callOutYqMerchantList"
:key=
"item.merchantNo"
:label=
"item.merchantName"
:value=
"item.merchantNo"
/>
:value=
"item.merchantNo"
/>
</el-select>
</el-select>
</el-form-item>
</el-form-item>
<el-form-item
label=
"调入门店:"
prop=
"callInYqMerchantId"
>
<el-form-item
label=
"调出门店:"
<el-select
v-model=
"editAllocationForm.callInYqMerchantId"
filterable
style=
"width: 300px"
>
prop=
"callOutMerchantId"
>
<el-option
v-for=
"item in callInYqMerchantList"
:key=
"item.merchantId"
:label=
"item.merchantName"
<el-select
v-model=
"editAllocationForm.callOutMerchantId"
style=
"width: 300px"
>
<el-option
v-for=
"item in callOutMerchantList"
:key=
"item.merchantId"
:label=
"item.merchantName"
:value=
"item.merchantId"
/>
</el-select>
</el-form-item>
<br
/>
<el-form-item>
调入方
</el-form-item>
<el-form-item
label=
"调入仓库:"
prop=
"callInYqMerchantId"
>
<el-select
v-model=
"editAllocationForm.callInYqMerchantId"
@
change=
"changeCallInYqMerchant(editAllocationForm.callInYqMerchantId)"
style=
"width: 300px"
>
<el-option
v-for=
"item in callInYqMerchantList"
:key=
"item.merchantNo"
:label=
"item.merchantName"
:value=
"item.merchantNo"
/>
</el-select>
</el-form-item>
<el-form-item
label=
"调入门店:"
prop=
"callInMerchantId"
>
<el-select
v-model=
"editAllocationForm.callInMerchantId"
style=
"width: 300px"
>
<el-option
v-for=
"item in callInMerchantList"
:key=
"item.merchantId"
:label=
"item.merchantName"
:value=
"item.merchantId"
/>
:value=
"item.merchantId"
/>
</el-select>
</el-select>
</el-form-item>
</el-form-item>
...
@@ -21,35 +58,62 @@
...
@@ -21,35 +58,62 @@
<div
class=
"d2-container-content"
>
<div
class=
"d2-container-content"
>
<div
style=
"padding: 15px 0"
>
<div
style=
"padding: 15px 0"
>
<div
class=
"gl-form-min"
>
<div
class=
"gl-form-min"
>
<el-form
:inline=
"true"
size=
"small"
:model=
"editAllocationForm"
>
<el-form
:inline=
"true"
size=
"small"
:model=
"editAllocationForm"
>
<el-form-item
label=
""
>
<el-form-item
label=
""
>
<el-input
v-model=
"searchForm.searchName"
style=
"width: 200px"
placeholder=
"请输入商品名称/系列"
maxlength=
"20"
<el-input
v-model=
"searchForm.upgradeGoodsNameOrSeries"
style=
"width: 200px"
placeholder=
"请输入商品名称/系列"
maxlength=
"20"
clearable
/>
clearable
/>
</el-form-item>
</el-form-item>
<el-button
@
click=
"handleSearch"
size=
"small"
type=
"primary"
style=
"marginleft: 15px"
>
查询
</el-button>
<el-button
@
click=
"handleSearch"
size=
"small"
type=
"primary"
style=
"marginleft: 15px"
>
查询
</el-button>
</el-form>
</el-form>
</div>
</div>
</div>
</div>
<GLTable
ref=
"allocationTable"
:getListApi=
"getListApi"
:pageConf=
"pageConf"
:searchForm=
"searchFormSearch"
<GLTable
ref=
"allocationTable"
:tableParams=
"tableParams"
:beforeSearchFn=
"beforeSearchFn"
>
:getListApi=
"getListApi"
<div
slot=
"auth-button"
slot-scope=
"scope"
>
:pageConf=
"pageConf"
<el-button
type=
"text"
@
click=
"allocation(scope.scope)"
:disabled=
"setDisabled(scope.scope)"
>
选择
</el-button>
:searchForm=
"searchFormSearch"
:tableParams=
"tableParams"
:beforeSearchFn=
"beforeSearchFn"
>
<div
slot=
"auth-button"
slot-scope=
"scope"
>
<el-button
type=
"text"
@
click=
"allocation(scope.scope)"
:disabled=
"setDisabled(scope.scope)"
>
选择
</el-button>
</div>
</div>
</GLTable>
</GLTable>
</div>
</div>
<div
class=
"d2-container-content"
>
<div
class=
"d2-container-content"
>
<p
class=
"title"
>
调拨确认单
</p>
<p
class=
"title"
>
调拨确认单
</p>
<GLTable
ref=
"allocationTable2"
:tableData=
"chooseDataList"
:tableParams=
"tableParams2"
:hasPage=
"false"
>
<GLTable
ref=
"allocationTable2"
<div
slot=
"auth-button"
slot-scope=
"scope"
>
:tableData=
"chooseDataList"
<el-button
type=
"text"
@
click=
"cancelAllocation(scope.row, scope.$index)"
>
取消
</el-button>
:tableParams=
"tableParams2"
:hasPage=
"false"
>
<div
slot=
"auth-button"
slot-scope=
"scope"
>
<el-button
type=
"text"
@
click=
"cancelAllocation(scope.row, scope.$index)"
>
取消
</el-button>
</div>
</div>
</GLTable>
</GLTable>
</div>
</div>
<glsx-form
ref=
"allocationForm"
:origin-data=
"editData"
:form-list=
"editForm"
form-ref=
"inveFormRef"
<glsx-form
ref=
"allocationForm"
@
handleAddConfirm=
"handleAddConfirm"
@
handleClose=
"handleAddClose"
></glsx-form>
:rules=
"allocationFormRules"
:origin-data=
"editData"
:form-list=
"editForm"
form-ref=
"inveFormRef"
@
handleAddConfirm=
"handleAddConfirm"
@
handleClose=
"handleAddClose"
></glsx-form>
<!-- 盘点 -->
<!-- 盘点 -->
<allocation-num-dialog
:allocation-num-visible=
"allocationNumVisible"
:allocation-info=
"allocationInfo"
<allocation-num-dialog
:allocation-num-visible=
"allocationNumVisible"
v-if=
"allocationNumVisible"
@
dialogClose=
"dialogClose"
/>
:allocation-info=
"allocationInfo"
v-if=
"allocationNumVisible"
@
dialogClose=
"dialogClose"
/>
</div>
</div>
</
template
>
</
template
>
...
@@ -64,10 +128,12 @@ export default {
...
@@ -64,10 +128,12 @@ export default {
data
()
{
data
()
{
return
{
return
{
callOutYqMerchantList
:
[],
callOutYqMerchantList
:
[],
membraneTypeList
:
membraneTypeList
,
callInYqMerchantList
:
[],
callInYqMerchantList
:
[],
callOutMerchantList
:
[],
callInMerchantList
:
[],
membraneTypeList
:
membraneTypeList
,
searchForm
:
{
searchForm
:
{
searchName
:
''
,
upgradeGoodsNameOrSeries
:
''
,
stockFlag
:
true
stockFlag
:
true
},
},
searchFormSearch
:
{},
searchFormSearch
:
{},
...
@@ -76,14 +142,15 @@ export default {
...
@@ -76,14 +142,15 @@ export default {
{
{
// label: '商品名称/系列',
// label: '商品名称/系列',
placeholder
:
'请输入商品名称/系列'
,
placeholder
:
'请输入商品名称/系列'
,
name
:
'
searchName
'
,
name
:
'
upgradeGoodsNameOrSeries
'
,
type
:
'input'
,
type
:
'input'
,
maxlength
:
'20'
,
maxlength
:
'20'
,
isClear
:
true
isClear
:
true
}
}
],
],
getListApi
:
this
.
$apis
.
stockManage
.
stockRemainPage
,
// getListApi: this.$apis.stockManage.stockRemainPage,
pageConf
:
{
pageSize
:
'pageSize'
,
pageNum
:
'pageNum'
,
totalCount
:
'total'
},
getListApi
:
null
,
pageConf
:
{
pageSize
:
'pageSize'
,
pageNum
:
'currentPage'
,
totalCount
:
'total'
},
tableParams
:
{
tableParams
:
{
btnId
:
new
Date
().
getTime
()
+
parseInt
(
Math
.
random
()
*
1000
),
btnId
:
new
Date
().
getTime
()
+
parseInt
(
Math
.
random
()
*
1000
),
listName
:
'list'
,
listName
:
'list'
,
...
@@ -91,7 +158,7 @@ export default {
...
@@ -91,7 +158,7 @@ export default {
tableColumns
:
[
tableColumns
:
[
{
{
label
:
'商品名称'
,
label
:
'商品名称'
,
prop
:
'
g
oodsName'
prop
:
'
upgradeG
oodsName'
},
},
{
{
label
:
'商品编码'
,
label
:
'商品编码'
,
...
@@ -100,7 +167,7 @@ export default {
...
@@ -100,7 +167,7 @@ export default {
},
},
{
{
label
:
'系列'
,
label
:
'系列'
,
prop
:
'
sourceMaterialName
'
prop
:
'
goodsSeries
'
},
},
{
{
label
:
'所属分类'
,
label
:
'所属分类'
,
...
@@ -114,8 +181,12 @@ export default {
...
@@ -114,8 +181,12 @@ export default {
}
}
},
},
{
{
label
:
'所属
门店
'
,
label
:
'所属
仓库
'
,
prop
:
'yqMerchantName'
prop
:
'yqMerchantName'
},
{
label
:
'所属门店'
,
prop
:
'merchantName'
}
}
]
]
},
},
...
@@ -165,18 +236,34 @@ export default {
...
@@ -165,18 +236,34 @@ export default {
{
{
formBlock
:
[
formBlock
:
[
{
{
name
:
'deliveryNumber'
,
label
:
'承运单号'
,
type
:
'input'
,
maxlength
:
50
,
width
:
'300px'
},
{
name
:
'deliveryCompany'
,
label
:
'承运公司'
,
type
:
'input'
,
maxlength
:
20
,
width
:
'300px'
},
{
name
:
'remark'
,
name
:
'remark'
,
label
:
'备注说明'
,
label
:
'备注说明'
,
type
:
'textarea'
,
type
:
'textarea'
,
maxlength
:
100
maxlength
:
100
}
}
,
]
]
}
}
],
],
editAllocationForm
:
{
editAllocationForm
:
{
callOutYqMerchantId
:
''
,
callOutYqMerchantId
:
''
,
//调出仓库
callInYqMerchantId
:
''
callOutMerchantId
:
''
,
//调出门店
callInYqMerchantId
:
''
,
//调入仓库
callInMerchantId
:
''
,
//调入门店
},
},
allocationNumVisible
:
false
,
allocationNumVisible
:
false
,
...
@@ -186,6 +273,13 @@ export default {
...
@@ -186,6 +273,13 @@ export default {
callOutYqMerchantId
:
[
callOutYqMerchantId
:
[
{
{
required
:
true
,
required
:
true
,
message
:
'请选择调出仓库'
,
trigger
:
'change'
}
],
callOutMerchantId
:
[
{
required
:
true
,
message
:
'请选择调出门店'
,
message
:
'请选择调出门店'
,
trigger
:
'change'
trigger
:
'change'
}
}
...
@@ -193,36 +287,180 @@ export default {
...
@@ -193,36 +287,180 @@ export default {
callInYqMerchantId
:
[
callInYqMerchantId
:
[
{
{
required
:
true
,
required
:
true
,
message
:
'请选择调入仓库'
,
trigger
:
'change'
}
],
callInMerchantId
:
[
{
required
:
true
,
message
:
'请选择调入门店'
,
message
:
'请选择调入门店'
,
trigger
:
'change'
trigger
:
'change'
}
}
]
]
},
allocationFormRules
:
{
deliveryNumber
:
[
{
required
:
true
,
message
:
'请输入承运单号'
,
trigger
:
'change'
}
}
],
deliveryCompany
:
[
{
required
:
true
,
message
:
'请输入承运公司'
,
trigger
:
'change'
}
]
},
oldyqMerchantId
:
''
,
//之前选择的调出仓库
oldMerchantId
:
''
,
//之前选择的调出门店
}
}
},
},
created
()
{
created
()
{
if
(
window
.
__POWERED_BY_QIANKUN__
)
{
// if (window.__POWERED_BY_QIANKUN__) {
this
.
callOutYqMerchantList
=
[{
merchantNo
:
this
.
$globalState
.
session
.
merchantId
+
''
,
merchantName
:
this
.
$globalState
.
session
.
merchantName
}]
// this.callOutYqMerchantList = [{ merchantNo: this.$globalState.session.merchantId + '', merchantName: this.$globalState.session.merchantName }]
// }
},
watch
:
{
'editAllocationForm.callOutYqMerchantId'
(
val
,
oldval
)
{
console
.
log
(
val
,
oldval
,
"监听callOutYqMerchantId"
);
// this.getListApi = this.$apis.stockManage.stockRemainPage
if
(
this
.
callOutYqMerchantList
.
length
==
1
)
{
//当只有一个选项时不弹提示框
// this.$refs.allocationTable.refreshTable()
}
else
{
if
(
val
!=
this
.
oldyqMerchantId
)
{
//与之前的选项不一样
this
.
editAllocationForm
.
callOutMerchantId
=
''
this
.
switchData
(
val
,
oldval
,
'yqMerchant'
)
}
}
},
'editAllocationForm.callOutMerchantId'
(
val
,
oldval
)
{
console
.
log
(
val
,
oldval
,
"监听callOutMerchantId"
);
this
.
getListApi
=
this
.
$apis
.
stockManage
.
stockRemainPage
if
(
this
.
callOutMerchantList
.
length
==
1
)
{
//当只有一个选项时不弹提示框
this
.
$refs
.
allocationTable
.
refreshTable
()
}
else
{
if
(
val
!=
this
.
oldMerchantId
)
{
//与之前的选项不一样
this
.
switchData
(
val
,
oldval
,
'merchant'
)
}
}
}
}
},
},
mounted
()
{
mounted
()
{
this
.
editAllocationForm
.
callOutYqMerchantId
=
this
.
callOutYqMerchantList
[
0
].
merchantNo
// this.editAllocationForm.callOutYqMerchantId = this.callOutYqMerchantList[0].merchantNo
//调入门店
// 调出仓库
this
.
$apis
.
stockManage
.
yqRelatedList
({
includeSelf
:
false
}).
then
(
res
=>
{
this
.
$apis
.
stockManage
.
getyqMerchantList
({
mainPartnerMerchant
:
true
}).
then
(
res
=>
{
this
.
callOutYqMerchantList
=
res
this
.
callInYqMerchantList
=
res
this
.
callInYqMerchantList
=
res
if
(
this
.
callOutYqMerchantList
&&
this
.
callOutYqMerchantList
.
length
==
1
)
{
this
.
editAllocationForm
.
callOutYqMerchantId
=
this
.
callOutYqMerchantList
[
0
].
merchantNo
this
.
getServicemerchantrefList
(
this
.
editAllocationForm
.
callOutYqMerchantId
,
'out'
)
}
if
(
this
.
callInYqMerchantList
&&
this
.
callInYqMerchantList
.
length
==
1
)
{
this
.
editAllocationForm
.
callInYqMerchantId
=
this
.
callInYqMerchantList
[
0
].
merchantNo
this
.
getServicemerchantrefList
(
this
.
editAllocationForm
.
callInYqMerchantId
,
'in'
)
}
})
})
//调入仓库
// this.$apis.stockManage.yqRelatedList({ includeSelf: false }).then(res => {
// this.callInYqMerchantList = res
// if (this.callInYqMerchantList && this.callInYqMerchantList.length == 1) {
// this.editAllocationForm.callInYqMerchantId = this.callInYqMerchantList[0].merchantId
// this.getServicemerchantrefList(this.editAllocationForm.callInYqMerchantId, 'in')
// }
// })
},
},
methods
:
{
methods
:
{
beforeSearchFn
()
{
beforeSearchFn
()
{
return
new
Promise
(
resolve
=>
{
return
new
Promise
(
resolve
=>
{
this
.
searchFormSearch
=
this
.
$common
.
utils
.
deepClone
(
this
.
searchForm
)
this
.
editAllocationForm
.
yqMerchantId
=
this
.
editAllocationForm
.
callOutYqMerchantId
this
.
editAllocationForm
.
merchantId
=
this
.
editAllocationForm
.
callOutMerchantId
let
_form
=
{
...
this
.
searchForm
,
...
this
.
editAllocationForm
}
this
.
searchFormSearch
=
this
.
$common
.
utils
.
deepClone
(
_form
)
resolve
()
resolve
()
})
})
},
},
handleSearch
()
{
handleSearch
()
{
this
.
getListApi
=
this
.
$apis
.
stockManage
.
stockRemainPage
this
.
$refs
.
allocationTable
.
refreshTable
()
this
.
$refs
.
allocationTable
.
refreshTable
()
},
},
// 获取仓库门店
getServicemerchantrefList
(
merchantId
,
type
)
{
this
.
$apis
.
stockManage
.
getServicemerchantrefList
({
yqMerchantId
:
merchantId
}).
then
(
res
=>
{
if
(
type
==
'out'
)
{
this
.
callOutMerchantList
=
res
||
[]
//总店
let
_headOffice
=
this
.
callOutYqMerchantList
.
find
(
item
=>
item
.
merchantNo
===
merchantId
)
_headOffice
.
merchantId
=
_headOffice
.
merchantNo
//门店选项中加入总店
this
.
callOutMerchantList
.
push
(
_headOffice
)
if
(
this
.
callOutMerchantList
&&
this
.
callOutMerchantList
.
length
==
1
)
{
this
.
editAllocationForm
.
callOutMerchantId
=
this
.
callOutMerchantList
[
0
].
merchantId
}
}
else
if
(
type
==
'in'
)
{
this
.
callInMerchantList
=
res
||
[]
//总店
let
_headOffice
=
this
.
callInYqMerchantList
.
find
(
item
=>
item
.
merchantNo
===
merchantId
)
_headOffice
.
merchantId
=
_headOffice
.
merchantNo
//门店选项中加入总店
this
.
callInMerchantList
.
push
(
_headOffice
)
if
(
this
.
callInMerchantList
&&
this
.
callInMerchantList
.
length
==
1
)
{
this
.
editAllocationForm
.
callInMerchantId
=
this
.
callOutMerchantList
[
0
].
merchantId
}
}
})
},
switchData
(
val
,
oldval
,
type
)
{
if
(
this
.
chooseDataList
&&
this
.
chooseDataList
.
length
>
0
)
{
//当盘存确认单有数据时提示
this
.
$confirm
(
'切换调出仓库和调出门店,自动重置已调拨内容;是否确定切换?'
,
'提示'
,
{
confirmButtonText
:
'确定'
,
cancelButtonText
:
'取消'
,
type
:
'warning'
})
.
then
(()
=>
{
if
(
type
==
'yqMerchant'
)
{
this
.
getServicemerchantrefList
(
val
,
'out'
)
}
else
{
//选择门店以后才更新盘存数据
this
.
$refs
.
allocationTable
.
refreshTable
()
}
//清空调拨确认单数据
this
.
chooseDataList
=
[]
})
.
catch
(
err
=>
{
console
.
log
(
err
)
if
(
type
==
'yqMerchant'
)
{
//调出仓库
this
.
editAllocationForm
.
callOutYqMerchantId
=
oldval
this
.
oldyqMerchantId
=
oldval
}
else
if
(
type
==
'merchant'
)
{
//调出门店
this
.
editAllocationForm
.
callOutMerchantId
=
oldval
this
.
oldMerchantId
=
oldval
}
})
}
else
{
if
(
type
==
'yqMerchant'
)
{
this
.
getServicemerchantrefList
(
val
,
'out'
)
}
else
{
//选择门店以后才更新盘存数据
this
.
$refs
.
allocationTable
.
refreshTable
()
}
}
},
changeCallInYqMerchant
(
merchantId
)
{
this
.
editAllocationForm
.
callInMerchantId
=
''
this
.
getServicemerchantrefList
(
merchantId
,
'in'
)
},
// 调拨
// 调拨
allocation
(
row
)
{
allocation
(
row
)
{
...
@@ -244,10 +482,19 @@ export default {
...
@@ -244,10 +482,19 @@ export default {
this
.
allocationNumVisible
=
!
this
.
allocationNumVisible
this
.
allocationNumVisible
=
!
this
.
allocationNumVisible
console
.
log
(
chooseData
)
console
.
log
(
chooseData
)
if
(
chooseData
)
{
if
(
chooseData
)
{
chooseData
=
this
.
fieldConvert
(
chooseData
)
this
.
chooseDataList
.
push
(
chooseData
)
this
.
chooseDataList
.
push
(
chooseData
)
}
}
},
},
//选择的数据与提交数据之间的字段转换
fieldConvert
(
obj
)
{
obj
.
goodsId
=
obj
.
upgradeGoodsId
obj
.
goodsName
=
obj
.
upgradeGoodsName
obj
.
sourceMaterialName
=
obj
.
goodsSeries
return
obj
},
// 取消
// 取消
cancelAllocation
(
row
,
index
)
{
cancelAllocation
(
row
,
index
)
{
this
.
chooseDataList
.
splice
(
index
,
1
)
this
.
chooseDataList
.
splice
(
index
,
1
)
...
@@ -268,6 +515,8 @@ export default {
...
@@ -268,6 +515,8 @@ export default {
if
(
data
.
remark
)
{
if
(
data
.
remark
)
{
params
.
remark
=
data
.
remark
params
.
remark
=
data
.
remark
}
}
params
.
deliveryNumber
=
data
.
deliveryNumber
params
.
deliveryCompany
=
data
.
deliveryCompany
params
=
{
params
=
{
...
params
,
...
params
,
...
this
.
editAllocationForm
...
this
.
editAllocationForm
...
...
src/views/allocation/index.vue
View file @
8f592da
...
@@ -2,24 +2,47 @@
...
@@ -2,24 +2,47 @@
<
template
>
<
template
>
<div
class=
"purchase"
>
<div
class=
"purchase"
>
<div
class=
"container"
>
<div
class=
"container"
>
<GLCombiForm
ref=
"showSearch"
:rowNumber=
"1"
:formObj=
"searchForm"
:formData=
"showFormData"
@
handleOk=
"handleSearch"
@
handleRest=
"handleReset"
></GLCombiForm>
<GLCombiForm
ref=
"showSearch"
:rowNumber=
"1"
:formObj=
"searchForm"
:formData=
"showFormData"
@
handleOk=
"handleSearch"
@
handleRest=
"handleReset"
></GLCombiForm>
<div
class=
"table-header"
>
<div
class=
"table-header"
>
<GLButton
type=
"primary"
size=
"small"
@
click=
"handleAdd"
fn=
"创建调拨"
>
创建调拨
</GLButton>
<GLButton
type=
"primary"
size=
"small"
@
click=
"handleAdd"
fn=
"创建调拨"
>
创建调拨
</GLButton>
<!--
<el-button
type=
"primary"
size=
"small"
@
click=
"handleAdd"
>
创建调拨
</el-button>
-->
<!--
<el-button
type=
"primary"
size=
"small"
@
click=
"handleAdd"
>
创建调拨
</el-button>
-->
<!--
<h2>
调拨列表
</h2>
-->
<!--
<h2>
调拨列表
</h2>
-->
<el-button
type=
"primary"
size=
"small"
@
click=
"exportExcel"
>
导出
</el-button>
<el-button
type=
"primary"
size=
"small"
@
click=
"exportExcel"
>
导出
</el-button>
</div>
</div>
<!-- 表格区域 开始 -->
<!-- 表格区域 开始 -->
<GLTable
ref=
"allocationRef"
:getListApi=
"getListApi"
:noDataImg=
"url"
:searchForm=
"tableSearchForm"
:tableParams=
"tableParams"
:pageConf=
"pageConf"
:beforeSearchFn=
"beforeSearchFn"
@
setTableFinishFun=
"setTableFinishFun"
>
<GLTable
ref=
"allocationRef"
<div
class=
"table-btns"
slot=
"auth-button"
slot-scope=
"scope"
>
:getListApi=
"getListApi"
<el-button
type=
"text"
@
click=
"handleDetail(scope.scope)"
>
查看
</el-button>
:noDataImg=
"url"
:searchForm=
"tableSearchForm"
:tableParams=
"tableParams"
:pageConf=
"pageConf"
:beforeSearchFn=
"beforeSearchFn"
@
setTableFinishFun=
"setTableFinishFun"
>
<div
class=
"table-btns"
slot=
"auth-button"
slot-scope=
"scope"
>
<el-button
type=
"text"
@
click=
"handleDetail(scope.scope)"
>
查看
</el-button>
</div>
</div>
</GLTable>
</GLTable>
<!-- 表格区域 end -->
<!-- 表格区域 end -->
</div>
</div>
<!-- 查看 -->
<!-- 查看 -->
<allocation-detail-dialog
:allocation-detail-visible=
"allocationDetailVisible"
:allocationInfo=
"allocationInfo"
v-if=
"allocationDetailVisible"
@
dialogClose=
"dialogClose"
/>
<allocation-detail-dialog
:allocation-detail-visible=
"allocationDetailVisible"
:allocationInfo=
"allocationInfo"
v-if=
"allocationDetailVisible"
@
dialogClose=
"dialogClose"
/>
</div>
</div>
</
template
>
</
template
>
...
@@ -40,7 +63,9 @@ export default {
...
@@ -40,7 +63,9 @@ export default {
allocateTime
:
''
,
allocateTime
:
''
,
allocateCode
:
''
,
allocateCode
:
''
,
callOutYqMerchantId
:
''
,
callOutYqMerchantId
:
''
,
callInYqMerchantId
:
''
callInYqMerchantId
:
''
,
callOutMerchantId
:
''
,
callInMerchantId
:
''
},
},
tableSearchForm
:
{},
tableSearchForm
:
{},
allocationInfo
:
{},
allocationInfo
:
{},
...
@@ -59,24 +84,54 @@ export default {
...
@@ -59,24 +84,54 @@ export default {
type
:
'datePicker'
,
type
:
'datePicker'
,
isClear
:
true
,
isClear
:
true
,
pickerOptions
:
'beforeRangePickerOptions'
pickerOptions
:
'beforeRangePickerOptions'
},
},
{
{
label
:
'调出仓库'
,
label
:
'调出门店'
,
name
:
'callOutYqMerchantId'
,
name
:
'callOutYqMerchantId'
,
type
:
'select'
,
type
:
'select'
,
optionList
:
[],
optionList
:
[],
optionId
:
'merchantNo'
,
optionLabel
:
'merchantName'
,
optionsName
:
'yqRelatedMerchantList'
,
changeAttr
:
(
value
,
targetItem
)
=>
{
value
?
this
.
getServicemerchantrefList
(
value
,
'out'
)
:
(
this
.
baseData
.
outMerchantList
=
[])
this
.
searchForm
.
callOutMerchantId
=
''
this
.
getOptionsList
(
'showFormData'
)
}
},
{
label
:
'调出门店'
,
name
:
'callOutMerchantId'
,
type
:
'select'
,
noDataText
:
'请先选择调出仓库'
,
optionList
:
[],
optionId
:
'merchantId'
,
optionId
:
'merchantId'
,
optionLabel
:
'merchantName'
,
optionLabel
:
'merchantName'
,
optionsName
:
'yqRelatedMerchantList'
optionsName
:
'outMerchantList'
},
},
{
{
label
:
'调入仓库'
,
label
:
'调入门店'
,
name
:
'callInYqMerchantId'
,
name
:
'callInYqMerchantId'
,
type
:
'select'
,
type
:
'select'
,
optionList
:
[],
optionList
:
[],
optionId
:
'merchantNo'
,
optionLabel
:
'merchantName'
,
optionsName
:
'yqRelatedMerchantList'
,
changeAttr
:
(
value
,
targetItem
)
=>
{
value
?
this
.
getServicemerchantrefList
(
value
,
'in'
)
:
(
this
.
baseData
.
inMerchantList
=
[])
this
.
searchForm
.
callInMerchantId
=
''
this
.
getOptionsList
(
'showFormData'
)
}
},
{
label
:
'调入门店'
,
name
:
'callInMerchantId'
,
type
:
'select'
,
noDataText
:
'请先选择调入仓库'
,
optionList
:
[],
optionId
:
'merchantId'
,
optionId
:
'merchantId'
,
optionLabel
:
'merchantName'
,
optionLabel
:
'merchantName'
,
optionsName
:
'
yqRelated
MerchantList'
optionsName
:
'
in
MerchantList'
}
}
],
],
// 表格
// 表格
...
@@ -93,21 +148,40 @@ export default {
...
@@ -93,21 +148,40 @@ export default {
{
{
label
:
'调拨时间'
,
label
:
'调拨时间'
,
prop
:
'allocateTime'
,
prop
:
'allocateTime'
,
width
:
170
,
formatter
:
cellValue
=>
{
formatter
:
cellValue
=>
{
return
dayjs
(
cellValue
.
allocateTime
).
format
(
'YYYY-MM-DD HH:mm:ss'
)
return
dayjs
(
cellValue
.
allocateTime
).
format
(
'YYYY-MM-DD HH:mm:ss'
)
}
}
},
},
{
{
label
:
'调拨人'
,
label
:
'调拨人'
,
prop
:
'operator'
prop
:
'operator'
,
width
:
100
},
},
{
{
label
:
'调出仓库'
,
prop
:
'callOutYqMerchantName'
,
width
:
150
},
{
label
:
'调出门店'
,
label
:
'调出门店'
,
prop
:
'callOutYqMerchantName'
prop
:
'callOutMerchantName'
,
},
width
:
150
{
},
{
label
:
'调入仓库'
,
prop
:
'callInYqMerchantName'
,
width
:
150
},
{
label
:
'调入门店'
,
label
:
'调入门店'
,
prop
:
'callInYqMerchantName'
prop
:
'callInMerchantName'
,
width
:
150
},
{
label
:
'承运单号'
,
prop
:
'deliveryNumber'
,
width
:
150
},
{
label
:
'承运公司'
,
prop
:
'deliveryCompany'
,
width
:
150
},
},
{
{
label
:
'备注'
,
label
:
'备注'
,
...
@@ -120,7 +194,9 @@ export default {
...
@@ -120,7 +194,9 @@ export default {
pageConf
:
{
pageSize
:
'pageSize'
,
pageNum
:
'currentPage'
,
totalCount
:
'total'
},
pageConf
:
{
pageSize
:
'pageSize'
,
pageNum
:
'currentPage'
,
totalCount
:
'total'
},
// 基本数据
// 基本数据
baseData
:
{
baseData
:
{
yqRelatedMerchantList
:
[]
yqRelatedMerchantList
:
[],
outMerchantList
:
[],
//调出门店
inMerchantList
:
[],
//调入门店
},
},
imgVisible
:
false
,
imgVisible
:
false
,
previewImgUrl
:
''
previewImgUrl
:
''
...
@@ -129,7 +205,11 @@ export default {
...
@@ -129,7 +205,11 @@ export default {
mounted
()
{
mounted
()
{
//调入门店
//调入门店
this
.
$apis
.
stockManage
.
yqRelatedList
({}).
then
(
res
=>
{
// this.$apis.stockManage.yqRelatedList({}).then(res => {
// this.baseData.yqRelatedMerchantList = res
// this.getOptionsList('showFormData')
// })
this
.
$apis
.
stockManage
.
getyqMerchantList
({
mainPartnerMerchant
:
true
}).
then
(
res
=>
{
this
.
baseData
.
yqRelatedMerchantList
=
res
this
.
baseData
.
yqRelatedMerchantList
=
res
this
.
getOptionsList
(
'showFormData'
)
this
.
getOptionsList
(
'showFormData'
)
})
})
...
@@ -151,6 +231,32 @@ export default {
...
@@ -151,6 +231,32 @@ export default {
resolve
()
resolve
()
})
})
},
},
// 获取仓库门店
getServicemerchantrefList
(
merchantId
,
type
)
{
this
.
$apis
.
stockManage
.
getServicemerchantrefList
({
yqMerchantId
:
merchantId
}).
then
(
res
=>
{
let
_headOffice
=
{}
if
(
type
==
'out'
)
{
//调出门店
this
.
baseData
.
outMerchantList
=
res
||
[]
//总店
_headOffice
=
this
.
baseData
.
yqRelatedMerchantList
.
find
(
item
=>
item
.
merchantNo
===
merchantId
)
_headOffice
.
merchantId
=
_headOffice
.
merchantNo
//门店选项中加入总店
this
.
baseData
.
outMerchantList
.
push
(
_headOffice
)
}
else
if
(
type
==
'in'
)
{
//调入门店
this
.
baseData
.
inMerchantList
=
res
||
[]
//总店
_headOffice
=
this
.
baseData
.
yqRelatedMerchantList
.
find
(
item
=>
item
.
merchantNo
===
merchantId
)
_headOffice
.
merchantId
=
_headOffice
.
merchantNo
//门店选项中加入总店
this
.
baseData
.
inMerchantList
.
push
(
_headOffice
)
}
this
.
getOptionsList
(
'showFormData'
)
})
},
// 查看详情
// 查看详情
handleDetail
(
row
)
{
handleDetail
(
row
)
{
this
.
allocationInfo
=
row
this
.
allocationInfo
=
row
...
@@ -204,10 +310,19 @@ export default {
...
@@ -204,10 +310,19 @@ export default {
allocateTime
:
''
,
allocateTime
:
''
,
allocateCode
:
''
,
allocateCode
:
''
,
callOutYqMerchantId
:
''
,
callOutYqMerchantId
:
''
,
callInYqMerchantId
:
''
callInYqMerchantId
:
''
,
callOutMerchantId
:
''
,
callInMerchantId
:
''
}
}
this
.
showFormData
[
this
.
findFormIdx
(
'callOutMerchantId'
)].
optionList
=
[]
this
.
showFormData
[
this
.
findFormIdx
(
'callInMerchantId'
)].
optionList
=
[]
this
.
handleSearch
()
this
.
handleSearch
()
},
},
findFormIdx
(
name
)
{
return
this
.
showFormData
.
findIndex
(
item
=>
item
.
name
===
name
)
},
handleEnlargeImg
(
url
)
{
handleEnlargeImg
(
url
)
{
if
(
url
)
{
if
(
url
)
{
this
.
previewImgUrl
=
url
this
.
previewImgUrl
=
url
...
...
src/views/check/add.vue
View file @
8f592da
<!-- 创建盘点 -->
<!-- 创建盘点 -->
<
template
>
<
template
>
<div
class=
"addWrap"
>
<div
class=
"addWrap"
>
<div
class=
"d2-container-content gl-form-min"
style=
"padding: 10px 20px"
>
<el-form
:inline=
"true"
size=
"small"
:model=
"editCheckForm"
ref=
"editCheckFormRef"
:rules=
"formRules"
class=
"demo-form-inline"
>
<el-form-item
label=
"盘点仓库:"
prop=
"yqMerchantId"
>
<el-select
v-model=
"editCheckForm.yqMerchantId"
@
change=
"changeYqMerchant(editCheckForm.yqMerchantId)"
style=
"width: 300px"
>
<el-option
v-for=
"item in yqMerchantIdList"
:key=
"item.merchantNo"
:label=
"item.merchantName"
:value=
"item.merchantNo"
/>
</el-select>
</el-form-item>
<el-form-item
label=
"盘点门店:"
prop=
"merchantId"
>
<el-select
v-model=
"editCheckForm.merchantId"
@
change=
"changeMerchant(editCheckForm.merchantId)"
style=
"width: 300px"
>
<el-option
v-for=
"item in merchantList"
:key=
"item.merchantId"
:label=
"item.merchantName"
:value=
"item.merchantId"
/>
</el-select>
</el-form-item>
</el-form>
</div>
<div
class=
"d2-container-content"
>
<div
class=
"d2-container-content"
>
<p
class=
"title"
>
盘存
</p>
<div
style=
"padding: 15px 0"
>
<div
style=
"padding: 15px 0"
>
<div
class=
"gl-form-min"
>
<div
class=
"gl-form-min"
>
<el-form
ref=
"ruleForm"
:model=
"searchForm"
size=
"small"
inline=
"true"
>
<el-form
ref=
"ruleForm"
:model=
"searchForm"
size=
"small"
inline=
"true"
>
<el-form-item
label=
""
>
<el-form-item
label=
""
>
<el-input
v-model=
"searchForm.searchName"
style=
"width: 200px"
placeholder=
"请输入商品名称/系列"
maxlength=
"20"
<el-input
v-model=
"searchForm.upgradeGoodsNameOrSeries"
style=
"width: 200px"
placeholder=
"请输入商品名称/系列"
maxlength=
"20"
clearable
/>
clearable
/>
</el-form-item>
</el-form-item>
<el-button
@
click=
"handleSearch"
size=
"small"
type=
"primary"
>
查询
</el-button>
<el-button
@
click=
"handleSearch"
size=
"small"
type=
"primary"
>
查询
</el-button>
</el-form>
</el-form>
</div>
</div>
</div>
</div>
<p
class=
"title"
>
盘存
</p>
<p
class=
"title"
>
盘存
</p>
<GLTable
ref=
"recordTable"
:getListApi=
"getListApi"
:searchForm=
"searchFormSearch"
:tableParams=
"tableParams"
<GLTable
ref=
"recordTable"
:beforeSearchFn=
"beforeSearchFn"
:pageConf=
"pageConf"
>
:getListApi=
"getListApi"
<div
slot=
"auth-button"
slot-scope=
"scope"
>
:searchForm=
"searchFormSearch"
<el-button
type=
"text"
@
click=
"inventory(scope.scope)"
:disabled=
"setDisabled(scope.scope)"
>
盘点
</el-button>
:tableParams=
"tableParams"
:beforeSearchFn=
"beforeSearchFn"
:pageConf=
"pageConf"
>
<div
slot=
"auth-button"
slot-scope=
"scope"
>
<el-button
type=
"text"
@
click=
"inventory(scope.scope)"
:disabled=
"setDisabled(scope.scope)"
>
盘点
</el-button>
</div>
</div>
</GLTable>
</GLTable>
</div>
</div>
<div
class=
"d2-container-content"
>
<div
class=
"d2-container-content"
>
<p
class=
"title"
>
盘存确认单
</p>
<p
class=
"title"
>
盘存确认单
</p>
<GLTable
ref=
"recordTable2"
:tableData=
"chooseDataList"
:tableParams=
"tableParams2"
:hasPage=
"false"
>
<GLTable
ref=
"recordTable2"
<template
slot=
"profitAndLoss"
slot-scope=
"scope"
>
:tableData=
"chooseDataList"
:tableParams=
"tableParams2"
:hasPage=
"false"
>
<template
slot=
"profitAndLoss"
slot-scope=
"scope"
>
<span
v-if=
"scope.scope.profitAndLoss || scope.scope.profitAndLoss == 0"
>
<span
v-if=
"scope.scope.profitAndLoss || scope.scope.profitAndLoss == 0"
>
<span
v-if=
"parseFloat(scope.scope.profitAndLoss) > 0"
style=
"color: blue"
>
{{
'+'
+
<span
v-if=
"parseFloat(scope.scope.profitAndLoss) > 0"
style=
"color: blue"
>
{{
'+'
+
parseFloat
(
scope
.
scope
.
profitAndLoss
).
toFixed
(
2
)
+
(
membraneTypeList
.
includes
(
scope
.
scope
.
goodsType
)
?
'米'
:
parseFloat
(
scope
.
scope
.
profitAndLoss
).
toFixed
(
2
)
+
(
membraneTypeList
.
includes
(
scope
.
scope
.
goodsType
)
?
'米'
:
'件'
)
}}
</span>
'件'
)
}}
</span>
<span
v-else-if=
"parseFloat(scope.scope.profitAndLoss)
< 0
"
style=
"color: red"
>
{{
<span
v-else-if=
"parseFloat(scope.scope.profitAndLoss)
< 0
"
style=
"color: red"
>
{{
parseFloat
(
scope
.
scope
.
profitAndLoss
).
toFixed
(
2
)
+
(
membraneTypeList
.
includes
(
scope
.
scope
.
goodsType
)
?
'米'
:
parseFloat
(
scope
.
scope
.
profitAndLoss
).
toFixed
(
2
)
+
(
membraneTypeList
.
includes
(
scope
.
scope
.
goodsType
)
?
'米'
:
'件'
)
}}
</span>
'件'
)
}}
</span>
<span
v-else
>
{{
parseFloat
(
scope
.
scope
.
profitAndLoss
).
toFixed
(
2
)
+
<span
v-else
>
{{
parseFloat
(
scope
.
scope
.
profitAndLoss
).
toFixed
(
2
)
+
...
@@ -38,16 +92,24 @@
...
@@ -38,16 +92,24 @@
</span>
</span>
<span
v-else
>
-
</span>
<span
v-else
>
-
</span>
</
template
>
</
template
>
<div
slot=
"auth-button"
slot-scope=
"scope"
>
<div
slot=
"auth-button"
<el-button
type=
"text"
@
click=
"cancelInventory(scope.row, scope.$index)"
>
取消
</el-button>
slot-scope=
"scope"
>
<el-button
type=
"text"
@
click=
"cancelInventory(scope.row, scope.$index)"
>
取消
</el-button>
</div>
</div>
</GLTable>
</GLTable>
</div>
</div>
<glsx-form
ref=
"addInventoryForm"
:origin-data=
"editData"
:form-list=
"editForm"
form-ref=
"inveFormRef"
<glsx-form
ref=
"addInventoryForm"
@
handleAddConfirm=
"handleAddConfirm"
@
handleClose=
"handleAddClose"
></glsx-form>
:origin-data=
"editData"
:form-list=
"editForm"
form-ref=
"inveFormRef"
@
handleAddConfirm=
"handleAddConfirm"
@
handleClose=
"handleAddClose"
></glsx-form>
<!-- 盘点 -->
<!-- 盘点 -->
<inventory-num-dialog
:inventory-num-visible=
"inventoryNumVisible"
:record-info=
"recordInfo"
<inventory-num-dialog
:inventory-num-visible=
"inventoryNumVisible"
v-if=
"inventoryNumVisible"
@
dialogClose=
"dialogClose"
/>
:record-info=
"recordInfo"
v-if=
"inventoryNumVisible"
@
dialogClose=
"dialogClose"
/>
</div>
</div>
</template>
</template>
...
@@ -63,12 +125,14 @@ export default {
...
@@ -63,12 +125,14 @@ export default {
return
{
return
{
membraneTypeList
:
membraneTypeList
,
membraneTypeList
:
membraneTypeList
,
searchForm
:
{
searchForm
:
{
searchName
:
''
upgradeGoodsNameOrSeries
:
''
},
},
searchFormSearch
:
{},
searchFormSearch
:
{},
searchSelectObj
:
{},
searchSelectObj
:
{},
getListApi
:
this
.
$apis
.
stockManage
.
stockRemainPage
,
// getListApi: this.$apis.stockManage.stockRemainPage,
pageConf
:
{
pageSize
:
'pageSize'
,
pageNum
:
'pageNum'
,
totalCount
:
'total'
},
getListApi
:
null
,
tableData
:
[],
pageConf
:
{
pageSize
:
'pageSize'
,
pageNum
:
'currentPage'
,
totalCount
:
'total'
},
tableParams
:
{
tableParams
:
{
btnId
:
new
Date
().
getTime
()
+
parseInt
(
Math
.
random
()
*
1000
),
btnId
:
new
Date
().
getTime
()
+
parseInt
(
Math
.
random
()
*
1000
),
listName
:
'list'
,
listName
:
'list'
,
...
@@ -76,7 +140,7 @@ export default {
...
@@ -76,7 +140,7 @@ export default {
tableColumns
:
[
tableColumns
:
[
{
{
label
:
'商品名称'
,
label
:
'商品名称'
,
prop
:
'
g
oodsName'
prop
:
'
upgradeG
oodsName'
},
},
{
{
label
:
'商品编码'
,
label
:
'商品编码'
,
...
@@ -85,7 +149,7 @@ export default {
...
@@ -85,7 +149,7 @@ export default {
},
},
{
{
label
:
'系列'
,
label
:
'系列'
,
prop
:
'
sourceMaterialName
'
prop
:
'
goodsSeries
'
},
},
{
{
label
:
'所属分类'
,
label
:
'所属分类'
,
...
@@ -99,8 +163,12 @@ export default {
...
@@ -99,8 +163,12 @@ export default {
}
}
},
},
{
{
label
:
'所属
门店
'
,
label
:
'所属
仓库
'
,
prop
:
'yqMerchantName'
prop
:
'yqMerchantName'
},
{
label
:
'所属门店'
,
prop
:
'merchantName'
}
}
]
]
},
},
...
@@ -111,8 +179,7 @@ export default {
...
@@ -111,8 +179,7 @@ export default {
tableColumns
:
[
tableColumns
:
[
{
{
label
:
'商品名称'
,
label
:
'商品名称'
,
prop
:
'goodsName'
,
prop
:
'goodsName'
width
:
'160px'
},
},
{
{
label
:
'商品编码'
,
label
:
'商品编码'
,
...
@@ -121,13 +188,11 @@ export default {
...
@@ -121,13 +188,11 @@ export default {
},
},
{
{
label
:
'系列'
,
label
:
'系列'
,
prop
:
'sourceMaterialName'
,
prop
:
'sourceMaterialName'
width
:
'250px'
},
},
{
{
label
:
'所属分类'
,
label
:
'所属分类'
,
prop
:
'goodsTypeName'
,
prop
:
'goodsTypeName'
width
:
'250px'
},
},
{
{
label
:
'系统库存'
,
label
:
'系统库存'
,
...
@@ -149,9 +214,12 @@ export default {
...
@@ -149,9 +214,12 @@ export default {
addHtml
:
'profitAndLoss'
addHtml
:
'profitAndLoss'
},
},
{
{
label
:
'所属仓库'
,
prop
:
'yqMerchantName'
},
{
label
:
'所属门店'
,
label
:
'所属门店'
,
prop
:
'yqMerchantName'
,
prop
:
'merchantName'
width
:
'200px'
}
}
]
]
},
},
...
@@ -185,14 +253,141 @@ export default {
...
@@ -185,14 +253,141 @@ export default {
inventoryNumVisible
:
false
,
inventoryNumVisible
:
false
,
recordInfo
:
null
,
recordInfo
:
null
,
chooseDataList
:
[]
chooseDataList
:
[],
editCheckForm
:
{
yqMerchantId
:
''
,
merchantId
:
''
},
formRules
:
{
yqMerchantId
:
[
{
required
:
true
,
message
:
'请选择盘点仓库'
,
trigger
:
'change'
}
],
merchantId
:
[
{
required
:
true
,
message
:
'请选择盘点门店'
,
trigger
:
'change'
}
]
},
yqMerchantIdList
:
[],
//盘点仓库
merchantList
:
[],
//盘点门店
oldyqMerchantId
:
''
,
//之前选择的仓库
oldMerchantId
:
''
,
//之前选择的门店
}
},
watch
:
{
'editCheckForm.yqMerchantId'
(
val
,
oldval
)
{
console
.
log
(
val
,
oldval
,
"监听yqMerchantId"
);
// this.getListApi = this.$apis.stockManage.stockRemainPage
if
(
this
.
yqMerchantIdList
.
length
==
1
)
{
//当只有一个选项时不弹提示框
// this.$refs.recordTable.refreshTable()
}
else
{
if
(
val
!=
this
.
oldyqMerchantId
)
{
//与之前的选项不一样
this
.
editCheckForm
.
merchantId
=
''
this
.
switchData
(
val
,
oldval
,
'yqMerchant'
)
}
}
},
'editCheckForm.merchantId'
(
val
,
oldval2
)
{
console
.
log
(
val
,
oldval2
,
"监听merchantId"
);
this
.
getListApi
=
this
.
$apis
.
stockManage
.
stockRemainPage
if
(
this
.
merchantList
.
length
==
1
)
{
this
.
$refs
.
recordTable
.
refreshTable
()
}
else
{
if
(
val
!=
this
.
oldMerchantId
)
{
//与之前的选项不一样
this
.
switchData
(
val
,
oldval2
,
'merchant'
)
}
}
}
}
},
},
mounted
()
{
// 获取当前登录账号可见的园区店列表
this
.
$apis
.
stockManage
.
getyqMerchantList
({
mainPartnerMerchant
:
true
}).
then
(
res
=>
{
this
.
yqMerchantIdList
=
res
if
(
this
.
yqMerchantIdList
&&
this
.
yqMerchantIdList
.
length
==
1
)
{
this
.
editCheckForm
.
yqMerchantId
=
this
.
yqMerchantIdList
[
0
].
merchantNo
this
.
getServicemerchantrefList
(
this
.
editCheckForm
.
yqMerchantId
)
}
})
},
methods
:
{
methods
:
{
changeYqMerchant
(
merchantId
)
{
// this.switchData(merchantId, 'yqMerchant')
},
changeMerchant
(
merchantId
)
{
// this.switchData(merchantId, 'merchant')
},
// 获取仓库门店
getServicemerchantrefList
(
merchantId
)
{
this
.
$apis
.
stockManage
.
getServicemerchantrefList
({
yqMerchantId
:
merchantId
}).
then
(
res
=>
{
this
.
merchantList
=
res
||
[]
//总店
let
_headOffice
=
this
.
yqMerchantIdList
.
find
(
item
=>
item
.
merchantNo
===
merchantId
)
_headOffice
.
merchantId
=
_headOffice
.
merchantNo
//门店选项中加入总店
this
.
merchantList
.
push
(
_headOffice
)
if
(
this
.
merchantList
&&
this
.
merchantList
.
length
==
1
)
{
this
.
editCheckForm
.
merchantId
=
this
.
merchantList
[
0
].
merchantId
}
})
},
switchData
(
val
,
oldval
,
type
)
{
if
(
this
.
chooseDataList
&&
this
.
chooseDataList
.
length
>
0
)
{
//当盘存确认单有数据时提示
this
.
$confirm
(
'切换盘点仓库和盘点门店,自动重置已盘点内容;是否确定切换?'
,
'提示'
,
{
confirmButtonText
:
'确定'
,
cancelButtonText
:
'取消'
,
type
:
'warning'
})
.
then
(()
=>
{
if
(
type
==
'yqMerchant'
)
{
this
.
getServicemerchantrefList
(
val
)
}
else
{
//选择门店以后才更新盘存数据
this
.
$refs
.
recordTable
.
refreshTable
()
}
//清空盘存确认单数据
this
.
chooseDataList
=
[]
})
.
catch
(
err
=>
{
console
.
log
(
err
)
if
(
type
==
'yqMerchant'
)
{
this
.
editCheckForm
.
yqMerchantId
=
oldval
this
.
oldyqMerchantId
=
oldval
}
else
if
(
type
==
'merchant'
)
{
this
.
editCheckForm
.
merchantId
=
oldval
this
.
oldMerchantId
=
oldval
}
})
}
else
{
if
(
type
==
'yqMerchant'
)
{
this
.
getServicemerchantrefList
(
val
)
}
else
{
//选择门店以后才更新盘存数据
this
.
$refs
.
recordTable
.
refreshTable
()
}
}
},
beforeSearchFn
()
{
beforeSearchFn
()
{
return
new
Promise
(
resolve
=>
{
return
new
Promise
(
resolve
=>
{
this
.
searchFormSearch
=
this
.
$common
.
utils
.
deepClone
(
this
.
searchForm
)
let
_form
=
{
...
this
.
searchForm
,
...
this
.
editCheckForm
}
this
.
searchFormSearch
=
this
.
$common
.
utils
.
deepClone
(
_form
)
resolve
()
resolve
()
})
})
},
},
...
@@ -212,7 +407,17 @@ export default {
...
@@ -212,7 +407,17 @@ export default {
},
},
handleSearch
()
{
handleSearch
()
{
console
.
log
(
this
.
searchFormSearch
);
if
(
this
.
searchFormSearch
.
yqMerchantId
&&
this
.
searchFormSearch
.
merchantId
)
{
this
.
getListApi
=
this
.
$apis
.
stockManage
.
stockRemainPage
this
.
$refs
.
recordTable
.
refreshTable
()
this
.
$refs
.
recordTable
.
refreshTable
()
}
else
{
this
.
$message
({
type
:
'error'
,
message
:
"请选择仓库和门店再查询数据"
})
}
},
},
// 盘点
// 盘点
...
@@ -233,17 +438,29 @@ export default {
...
@@ -233,17 +438,29 @@ export default {
dialogClose
(
chooseData
)
{
dialogClose
(
chooseData
)
{
this
.
inventoryNumVisible
=
!
this
.
inventoryNumVisible
this
.
inventoryNumVisible
=
!
this
.
inventoryNumVisible
console
.
log
(
'chooseData'
,
chooseData
);
if
(
chooseData
)
{
if
(
chooseData
)
{
chooseData
=
this
.
fieldConvert
(
chooseData
)
this
.
chooseDataList
.
push
(
chooseData
)
this
.
chooseDataList
.
push
(
chooseData
)
}
}
},
},
//选择的数据与提交数据之间的字段转换
fieldConvert
(
obj
)
{
obj
.
goodsId
=
obj
.
upgradeGoodsId
obj
.
goodsName
=
obj
.
upgradeGoodsName
obj
.
sourceMaterialName
=
obj
.
goodsSeries
return
obj
},
// 取消
// 取消
cancelInventory
(
row
,
index
)
{
cancelInventory
(
row
,
index
)
{
this
.
chooseDataList
.
splice
(
index
,
1
)
this
.
chooseDataList
.
splice
(
index
,
1
)
},
},
handleAddConfirm
(
data
)
{
handleAddConfirm
(
data
)
{
this
.
$refs
.
editCheckFormRef
.
validate
(
valid
=>
{
if
(
valid
)
{
if
(
this
.
chooseDataList
.
length
==
0
)
{
if
(
this
.
chooseDataList
.
length
==
0
)
{
this
.
$notify
({
this
.
$notify
({
type
:
'warning'
,
type
:
'warning'
,
...
@@ -259,7 +476,10 @@ export default {
...
@@ -259,7 +476,10 @@ export default {
if
(
data
.
remark
)
{
if
(
data
.
remark
)
{
params
.
remark
=
data
.
remark
params
.
remark
=
data
.
remark
}
}
// return console.log(params);
params
=
{
...
params
,
...
this
.
editCheckForm
}
this
.
$confirm
(
'盘点单保存后,系统自动按照盘点实际库存进行库存更新;是否确定保存?'
,
'提示'
,
{
this
.
$confirm
(
'盘点单保存后,系统自动按照盘点实际库存进行库存更新;是否确定保存?'
,
'提示'
,
{
confirmButtonText
:
'确定'
,
confirmButtonText
:
'确定'
,
cancelButtonText
:
'取消'
,
cancelButtonText
:
'取消'
,
...
@@ -277,6 +497,8 @@ export default {
...
@@ -277,6 +497,8 @@ export default {
.
catch
(
err
=>
{
.
catch
(
err
=>
{
console
.
log
(
err
)
console
.
log
(
err
)
})
})
}
})
},
},
handleAddClose
(
isRefresh
=
false
)
{
handleAddClose
(
isRefresh
=
false
)
{
...
@@ -309,4 +531,5 @@ export default {
...
@@ -309,4 +531,5 @@ export default {
display
:
inline-block
;
display
:
inline-block
;
box-sizing
:
border-box
;
box-sizing
:
border-box
;
margin-right
:
10px
;
margin-right
:
10px
;
}
</
style
>
}
</
style
>
src/views/check/index.vue
View file @
8f592da
...
@@ -2,31 +2,61 @@
...
@@ -2,31 +2,61 @@
<
template
>
<
template
>
<div
class=
"purchase"
>
<div
class=
"purchase"
>
<div
class=
"container"
>
<div
class=
"container"
>
<GLCombiForm
ref=
"showSearch"
:rowNumber=
"1"
:formObj=
"searchForm"
:formData=
"showFormData"
@
handleOk=
"handleSearch"
@
handleRest=
"handleReset"
></GLCombiForm>
<GLCombiForm
ref=
"showSearch"
:rowNumber=
"1"
:formObj=
"searchForm"
:formData=
"showFormData"
@
handleOk=
"handleSearch"
@
handleRest=
"handleReset"
></GLCombiForm>
<div
class=
"table-header"
>
<div
class=
"table-header"
>
<GLButton
type=
"primary"
size=
"small"
@
click=
"handleAdd"
fn=
"创建盘点"
>
创建盘点
</GLButton>
<GLButton
type=
"primary"
size=
"small"
@
click=
"handleAdd"
fn=
"创建盘点"
>
创建盘点
</GLButton>
<!--
<el-button
type=
"primary"
size=
"small"
@
click=
"handleAdd"
>
创建盘点
</el-button>
-->
<!--
<el-button
type=
"primary"
size=
"small"
@
click=
"handleAdd"
>
创建盘点
</el-button>
-->
<!--
<h2>
盘点列表
</h2>
-->
<!--
<h2>
盘点列表
</h2>
-->
<el-button
type=
"primary"
size=
"small"
@
click=
"exportExcel"
>
导出
</el-button>
<el-button
type=
"primary"
size=
"small"
@
click=
"exportExcel"
>
导出
</el-button>
</div>
</div>
<!-- 表格区域 开始 -->
<!-- 表格区域 开始 -->
<GLTable
ref=
"checkRef"
:getListApi=
"getListApi"
:noDataImg=
"url"
:searchForm=
"tableSearchForm"
:tableParams=
"tableParams"
:pageConf=
"pageConf"
:beforeSearchFn=
"beforeSearchFn"
@
setTableFinishFun=
"setTableFinishFun"
>
<GLTable
ref=
"checkRef"
<div
slot=
"img"
slot-scope=
"scope"
v-if=
"scope.scope.voucherPic"
>
:getListApi=
"getListApi"
<img
class=
"img-36"
:src=
"scope.scope.voucherPic"
@
click=
"handleEnlargeImg(scope.scope.voucherPic)"
/>
:noDataImg=
"url"
:searchForm=
"tableSearchForm"
:tableParams=
"tableParams"
:pageConf=
"pageConf"
:beforeSearchFn=
"beforeSearchFn"
@
setTableFinishFun=
"setTableFinishFun"
>
<div
slot=
"img"
slot-scope=
"scope"
v-if=
"scope.scope.voucherPic"
>
<img
class=
"img-36"
:src=
"scope.scope.voucherPic"
@
click=
"handleEnlargeImg(scope.scope.voucherPic)"
/>
</div>
</div>
<div
class=
"table-btns"
slot=
"auth-button"
slot-scope=
"scope"
>
<div
class=
"table-btns"
<el-button
type=
"text"
@
click=
"handleDetail(scope.scope)"
>
查看
</el-button>
slot=
"auth-button"
slot-scope=
"scope"
>
<el-button
type=
"text"
@
click=
"handleDetail(scope.scope)"
>
查看
</el-button>
</div>
</div>
</GLTable>
</GLTable>
<!-- 表格区域 end -->
<!-- 表格区域 end -->
</div>
</div>
<!-- 预览图片 -->
<!-- 预览图片 -->
<el-dialog
:visible=
"imgVisible"
:before-close=
"handleCloseImg"
>
<el-dialog
:visible=
"imgVisible"
<img
width=
"100%"
:src=
"previewImgUrl"
alt=
"图片"
/>
:before-close=
"handleCloseImg"
>
<img
width=
"100%"
:src=
"previewImgUrl"
alt=
"图片"
/>
</el-dialog>
</el-dialog>
<!-- 查看 -->
<!-- 查看 -->
<inventory-detail-dialog
:inventory-detail-visible=
"inventoryDetailVisible"
:recordInfo=
"recordInfo"
v-if=
"inventoryDetailVisible"
@
dialogClose=
"dialogClose"
/>
<inventory-detail-dialog
:inventory-detail-visible=
"inventoryDetailVisible"
:recordInfo=
"recordInfo"
v-if=
"inventoryDetailVisible"
@
dialogClose=
"dialogClose"
/>
</div>
</div>
</
template
>
</
template
>
...
@@ -48,7 +78,8 @@ export default {
...
@@ -48,7 +78,8 @@ export default {
searchForm
:
{
searchForm
:
{
checkTime
:
''
,
checkTime
:
''
,
checkCode
:
''
,
checkCode
:
''
,
yqMerchantId
:
''
yqMerchantId
:
''
,
merchantId
:
''
},
},
tableSearchForm
:
{},
tableSearchForm
:
{},
recordInfo
:
{},
recordInfo
:
{},
...
@@ -67,15 +98,30 @@ export default {
...
@@ -67,15 +98,30 @@ export default {
type
:
'datePicker'
,
type
:
'datePicker'
,
isClear
:
true
,
isClear
:
true
,
pickerOptions
:
'beforeRangePickerOptions'
pickerOptions
:
'beforeRangePickerOptions'
},
},
{
{
label
:
'盘点仓库'
,
label
:
'所属门店'
,
name
:
'yqMerchantId'
,
name
:
'yqMerchantId'
,
type
:
'select'
,
type
:
'select'
,
optionList
:
[],
optionList
:
[],
optionId
:
'merchantNo'
,
optionId
:
'merchantNo'
,
optionLabel
:
'merchantName'
,
optionLabel
:
'merchantName'
,
optionsName
:
'yqMerchantList'
optionsName
:
'yqMerchantList'
,
changeAttr
:
(
value
,
targetItem
)
=>
{
value
?
this
.
getServicemerchantrefList
(
value
)
:
(
this
.
baseData
.
merchantIdList
=
[])
this
.
searchForm
.
merchantId
=
''
this
.
getOptionsList
(
'showFormData'
)
}
},
{
label
:
'盘点门店'
,
name
:
'merchantId'
,
type
:
'select'
,
noDataText
:
'请先选择盘点仓库'
,
optionList
:
[],
optionId
:
'merchantId'
,
optionLabel
:
'merchantName'
,
optionsName
:
'merchantIdList'
}
}
],
],
// 表格
// 表格
...
@@ -98,10 +144,12 @@ export default {
...
@@ -98,10 +144,12 @@ export default {
{
{
label
:
'盘点人'
,
label
:
'盘点人'
,
prop
:
'operator'
prop
:
'operator'
},
},
{
{
label
:
'盘点仓库'
,
prop
:
'yqMerchantName'
,
},
{
label
:
'盘点门店'
,
label
:
'盘点门店'
,
prop
:
'
yqMerchantName'
prop
:
'
merchantName'
,
},
},
{
{
label
:
'备注'
,
label
:
'备注'
,
...
@@ -119,7 +167,8 @@ export default {
...
@@ -119,7 +167,8 @@ export default {
pageConf
:
{
pageSize
:
'pageSize'
,
pageNum
:
'currentPage'
,
totalCount
:
'total'
},
pageConf
:
{
pageSize
:
'pageSize'
,
pageNum
:
'currentPage'
,
totalCount
:
'total'
},
// 基本数据
// 基本数据
baseData
:
{
baseData
:
{
yqMerchantList
:
[]
yqMerchantList
:
[],
merchantIdList
:
[]
},
},
imgVisible
:
false
,
imgVisible
:
false
,
previewImgUrl
:
''
previewImgUrl
:
''
...
@@ -128,7 +177,7 @@ export default {
...
@@ -128,7 +177,7 @@ export default {
mounted
()
{
mounted
()
{
// 获取当前登录账号可见的园区店列表
// 获取当前登录账号可见的园区店列表
this
.
$apis
.
stockManage
.
getyqMerchantList
({}).
then
(
res
=>
{
this
.
$apis
.
stockManage
.
getyqMerchantList
({
mainPartnerMerchant
:
true
}).
then
(
res
=>
{
this
.
baseData
.
yqMerchantList
=
res
this
.
baseData
.
yqMerchantList
=
res
this
.
getOptionsList
(
'showFormData'
)
this
.
getOptionsList
(
'showFormData'
)
})
})
...
@@ -137,6 +186,8 @@ export default {
...
@@ -137,6 +186,8 @@ export default {
methods
:
{
methods
:
{
getParams
()
{
getParams
()
{
var
params
=
JSON
.
parse
(
JSON
.
stringify
(
this
.
searchForm
))
var
params
=
JSON
.
parse
(
JSON
.
stringify
(
this
.
searchForm
))
console
.
log
(
params
);
if
(
this
.
searchForm
.
checkTime
)
{
if
(
this
.
searchForm
.
checkTime
)
{
params
.
checkTimeStart
=
new
Date
(
this
.
searchForm
.
checkTime
[
0
]).
toLocaleDateString
().
replace
(
/
\/
/g
,
'-'
)
+
' 00:00:00'
params
.
checkTimeStart
=
new
Date
(
this
.
searchForm
.
checkTime
[
0
]).
toLocaleDateString
().
replace
(
/
\/
/g
,
'-'
)
+
' 00:00:00'
params
.
checkTimeEnd
=
new
Date
(
this
.
searchForm
.
checkTime
[
1
]).
toLocaleDateString
().
replace
(
/
\/
/g
,
'-'
)
+
' 23:59:59'
params
.
checkTimeEnd
=
new
Date
(
this
.
searchForm
.
checkTime
[
1
]).
toLocaleDateString
().
replace
(
/
\/
/g
,
'-'
)
+
' 23:59:59'
...
@@ -150,6 +201,22 @@ export default {
...
@@ -150,6 +201,22 @@ export default {
resolve
()
resolve
()
})
})
},
},
// 获取仓库门店
getServicemerchantrefList
(
merchantId
)
{
this
.
$apis
.
stockManage
.
getServicemerchantrefList
({
yqMerchantId
:
merchantId
}).
then
(
res
=>
{
this
.
baseData
.
merchantIdList
=
res
||
[]
//总店
let
_headOffice
=
this
.
baseData
.
yqMerchantList
.
find
(
item
=>
item
.
merchantNo
===
merchantId
)
_headOffice
.
merchantId
=
_headOffice
.
merchantNo
//门店选项中加入总店
this
.
baseData
.
merchantIdList
.
push
(
_headOffice
)
this
.
getOptionsList
(
'showFormData'
)
})
},
// 查看详情
// 查看详情
handleDetail
(
row
)
{
handleDetail
(
row
)
{
this
.
recordInfo
=
row
this
.
recordInfo
=
row
...
@@ -201,10 +268,17 @@ export default {
...
@@ -201,10 +268,17 @@ export default {
this
.
searchForm
=
{
this
.
searchForm
=
{
checkTime
:
''
,
checkTime
:
''
,
checkCode
:
''
,
checkCode
:
''
,
yqMerchantId
:
''
yqMerchantId
:
''
,
merchantId
:
''
}
}
this
.
showFormData
[
this
.
findFormIdx
(
'merchantId'
)].
optionList
=
[]
this
.
handleSearch
()
this
.
handleSearch
()
},
},
findFormIdx
(
name
)
{
return
this
.
showFormData
.
findIndex
(
item
=>
item
.
name
===
name
)
},
handleEnlargeImg
(
url
)
{
handleEnlargeImg
(
url
)
{
if
(
url
)
{
if
(
url
)
{
this
.
previewImgUrl
=
url
this
.
previewImgUrl
=
url
...
...
src/views/earlyWarning/index.vue
View file @
8f592da
...
@@ -2,17 +2,33 @@
...
@@ -2,17 +2,33 @@
<
template
>
<
template
>
<div
class=
"purchase"
>
<div
class=
"purchase"
>
<div
class=
"container"
>
<div
class=
"container"
>
<GLCombiForm
ref=
"showSearch"
:rowNumber=
"1"
:formObj=
"searchForm"
:formData=
"showFormData"
@
handleOk=
"handleSearch"
@
handleRest=
"handleReset"
></GLCombiForm>
<GLCombiForm
ref=
"showSearch"
:rowNumber=
"1"
:formObj=
"searchForm"
:formData=
"showFormData"
@
handleOk=
"handleSearch"
@
handleRest=
"handleReset"
></GLCombiForm>
<div
class=
"table-header"
>
<div
class=
"table-header"
>
<h2>
预警列表
</h2>
<h2>
预警列表
</h2>
<div>
<div>
<el-button
type=
"primary"
size=
"small"
@
click=
"gotoReplenishment"
>
去补货
</el-button>
<el-button
type=
"primary"
<el-button
type=
"primary"
size=
"small"
@
click=
"exportExcel"
>
导出
</el-button>
size=
"small"
@
click=
"gotoReplenishment"
>
去补货
</el-button>
<el-button
type=
"primary"
size=
"small"
@
click=
"exportExcel"
>
导出
</el-button>
</div>
</div>
</div>
</div>
<!-- 表格区域 开始 -->
<!-- 表格区域 开始 -->
<GLTable
ref=
"earlyWarningRef"
:getListApi=
"getListApi"
:noDataImg=
"url"
:searchForm=
"tableSearchForm"
:tableParams=
"tableParams"
:pageConf=
"pageConf"
:beforeSearchFn=
"beforeSearchFn"
@
setTableFinishFun=
"setTableFinishFun"
></GLTable>
<GLTable
ref=
"earlyWarningRef"
:getListApi=
"getListApi"
:noDataImg=
"url"
:searchForm=
"tableSearchForm"
:tableParams=
"tableParams"
:pageConf=
"pageConf"
:beforeSearchFn=
"beforeSearchFn"
@
setTableFinishFun=
"setTableFinishFun"
></GLTable>
<!-- 表格区域 end -->
<!-- 表格区域 end -->
</div>
</div>
</div>
</div>
...
@@ -31,6 +47,7 @@ export default {
...
@@ -31,6 +47,7 @@ export default {
searchForm
:
{
searchForm
:
{
upgradeGoodsName
:
''
,
upgradeGoodsName
:
''
,
yqMerchantId
:
''
,
yqMerchantId
:
''
,
merchantId
:
''
,
goodsType
:
''
,
goodsType
:
''
,
goodsSeries
:
''
,
goodsSeries
:
''
,
productCode
:
''
productCode
:
''
...
@@ -69,13 +86,29 @@ export default {
...
@@ -69,13 +86,29 @@ export default {
optionsName
:
'productTypeList'
optionsName
:
'productTypeList'
},
},
{
{
label
:
'所属
门店
'
,
label
:
'所属
仓库
'
,
name
:
'yqMerchantId'
,
name
:
'yqMerchantId'
,
type
:
'select'
,
type
:
'select'
,
optionList
:
[],
optionList
:
[],
optionId
:
'merchantNo'
,
optionId
:
'merchantNo'
,
optionLabel
:
'merchantName'
,
optionLabel
:
'merchantName'
,
optionsName
:
'yqMerchantList'
optionsName
:
'yqMerchantList'
,
changeAttr
:
(
value
,
targetItem
)
=>
{
value
?
this
.
getServicemerchantrefList
(
value
)
:
(
this
.
baseData
.
merchantIdList
=
[])
this
.
searchForm
.
merchantId
=
''
this
.
getOptionsList
(
'showFormData'
)
}
},
{
label
:
'所属门店'
,
name
:
'merchantId'
,
type
:
'select'
,
noDataText
:
'请先选择所属仓库'
,
optionList
:
[],
optionId
:
'merchantId'
,
optionLabel
:
'merchantName'
,
optionsName
:
'merchantIdList'
}
}
],
],
// 表格
// 表格
...
@@ -115,8 +148,12 @@ export default {
...
@@ -115,8 +148,12 @@ export default {
}
}
},
},
{
{
label
:
'所属
门店
'
,
label
:
'所属
仓库
'
,
prop
:
'yqMerchantName'
prop
:
'yqMerchantName'
},
{
label
:
'所属门店'
,
prop
:
'merchantName'
}
}
]
]
},
},
...
@@ -124,7 +161,8 @@ export default {
...
@@ -124,7 +161,8 @@ export default {
// 基本数据
// 基本数据
baseData
:
{
baseData
:
{
productTypeList
:
[],
productTypeList
:
[],
yqMerchantList
:
[]
yqMerchantList
:
[],
merchantIdList
:
[]
}
}
}
}
},
},
...
@@ -136,7 +174,7 @@ export default {
...
@@ -136,7 +174,7 @@ export default {
})
})
// 获取当前登录账号可见的园区店列表
// 获取当前登录账号可见的园区店列表
this
.
$apis
.
stockManage
.
getyqMerchantList
({}).
then
(
res
=>
{
this
.
$apis
.
stockManage
.
getyqMerchantList
({
mainPartnerMerchant
:
true
}).
then
(
res
=>
{
this
.
baseData
.
yqMerchantList
=
res
this
.
baseData
.
yqMerchantList
=
res
this
.
getOptionsList
(
'showFormData'
)
this
.
getOptionsList
(
'showFormData'
)
})
})
...
@@ -149,6 +187,20 @@ export default {
...
@@ -149,6 +187,20 @@ export default {
resolve
()
resolve
()
})
})
},
},
// 获取仓库门店
getServicemerchantrefList
(
merchantId
)
{
this
.
$apis
.
stockManage
.
getServicemerchantrefList
({
yqMerchantId
:
merchantId
}).
then
(
res
=>
{
this
.
baseData
.
merchantIdList
=
res
||
[]
//总店
let
_headOffice
=
this
.
baseData
.
yqMerchantList
.
find
(
item
=>
item
.
merchantNo
===
merchantId
)
_headOffice
.
merchantId
=
_headOffice
.
merchantNo
//门店选项中加入总店
this
.
baseData
.
merchantIdList
.
push
(
_headOffice
)
this
.
getOptionsList
(
'showFormData'
)
})
},
// 查看详情
// 查看详情
handleDetail
(
row
)
{
handleDetail
(
row
)
{
this
.
stockInfo
=
row
this
.
stockInfo
=
row
...
@@ -198,6 +250,27 @@ export default {
...
@@ -198,6 +250,27 @@ export default {
gotoReplenishment
()
{
gotoReplenishment
()
{
this
.
$history
.
push
(
`/purchase/purchaseOrder/add`
)
this
.
$history
.
push
(
`/purchase/purchaseOrder/add`
)
},
},
// async gotoReplenishment() {
// let result = await this.checkShipper()
// console.log(result)
// if (result) this.$history.push(`/purchase/purchaseOrder/add`)
// },
checkShipper
()
{
return
new
Promise
(
resolve
=>
{
this
.
$apis
.
stockManage
.
checkShipper
({}).
then
(
res
=>
{
console
.
log
(
res
)
if
(
res
.
code
==
-
1
)
{
this
.
$message
({
type
:
'error'
,
message
:
res
.
message
})
resolve
(
false
)
}
else
{
resolve
(
true
)
}
})
})
},
handleSearch
()
{
handleSearch
()
{
this
.
$refs
.
earlyWarningRef
.
refreshTable
()
this
.
$refs
.
earlyWarningRef
.
refreshTable
()
},
},
...
@@ -206,12 +279,18 @@ export default {
...
@@ -206,12 +279,18 @@ export default {
this
.
searchForm
=
{
this
.
searchForm
=
{
upgradeGoodsName
:
''
,
upgradeGoodsName
:
''
,
yqMerchantId
:
''
,
yqMerchantId
:
''
,
merchantId
:
''
,
goodsType
:
''
,
goodsType
:
''
,
goodsSeries
:
''
,
goodsSeries
:
''
,
productCode
:
''
productCode
:
''
}
}
this
.
showFormData
[
this
.
findFormIdx
(
'merchantId'
)].
optionList
=
[]
this
.
handleSearch
()
this
.
handleSearch
()
},
findFormIdx
(
name
)
{
return
this
.
showFormData
.
findIndex
(
item
=>
item
.
name
===
name
)
}
}
}
}
}
}
...
...
src/views/outbound/index.vue
View file @
8f592da
...
@@ -2,16 +2,27 @@
...
@@ -2,16 +2,27 @@
<
template
>
<
template
>
<div
class=
"purchase"
>
<div
class=
"purchase"
>
<div
class=
"container"
>
<div
class=
"container"
>
<GLCombiForm
ref=
"showSearch"
:rowNumber=
"1"
:formObj=
"searchForm"
:formData=
"showFormData"
@
handleOk=
"handleSearch"
<GLCombiForm
ref=
"showSearch"
:rowNumber=
"1"
:formObj=
"searchForm"
:formData=
"showFormData"
@
handleOk=
"handleSearch"
@
handleRest=
"handleReset"
></GLCombiForm>
@
handleRest=
"handleReset"
></GLCombiForm>
<div
class=
"table-header"
>
<div
class=
"table-header"
>
<h2>
出库列表
</h2>
<h2>
出库列表
</h2>
<el-button
type=
"primary"
size=
"small"
@
click=
"exportExcel"
>
导出
</el-button>
<el-button
type=
"primary"
size=
"small"
@
click=
"exportExcel"
>
导出
</el-button>
</div>
</div>
<!-- 表格区域 开始 -->
<!-- 表格区域 开始 -->
<GLTable
ref=
"outboundRef"
:getListApi=
"getListApi"
:noDataImg=
"url"
:searchForm=
"tableSearchForm"
<GLTable
ref=
"outboundRef"
:tableParams=
"tableParams"
:pageConf=
"pageConf"
:beforeSearchFn=
"beforeSearchFn"
:getListApi=
"getListApi"
:noDataImg=
"url"
:searchForm=
"tableSearchForm"
:tableParams=
"tableParams"
:pageConf=
"pageConf"
:beforeSearchFn=
"beforeSearchFn"
@
setTableFinishFun=
"setTableFinishFun"
></GLTable>
@
setTableFinishFun=
"setTableFinishFun"
></GLTable>
<!-- 表格区域 end -->
<!-- 表格区域 end -->
</div>
</div>
...
@@ -34,6 +45,7 @@ export default {
...
@@ -34,6 +45,7 @@ export default {
eventType
:
''
,
eventType
:
''
,
upgradeGoodsName
:
''
,
upgradeGoodsName
:
''
,
yqMerchantId
:
''
,
yqMerchantId
:
''
,
merchantId
:
''
,
goodsType
:
''
,
goodsType
:
''
,
businessCode
:
''
,
businessCode
:
''
,
goodsSeries
:
''
,
goodsSeries
:
''
,
...
@@ -74,15 +86,30 @@ export default {
...
@@ -74,15 +86,30 @@ export default {
isClear
:
true
isClear
:
true
},
},
{
{
label
:
'出库
门店
'
,
label
:
'出库
仓库
'
,
name
:
'yqMerchantId'
,
name
:
'yqMerchantId'
,
type
:
'select'
,
type
:
'select'
,
optionList
:
[],
optionList
:
[],
optionId
:
'merchantNo'
,
optionId
:
'merchantNo'
,
optionLabel
:
'merchantName'
,
optionLabel
:
'merchantName'
,
optionsName
:
'yqMerchantList'
optionsName
:
'yqMerchantList'
,
changeAttr
:
(
value
,
targetItem
)
=>
{
value
?
this
.
getServicemerchantrefList
(
value
)
:
(
this
.
baseData
.
merchantIdList
=
[])
this
.
searchForm
.
merchantId
=
''
this
.
getOptionsList
(
'showFormData'
)
}
},
{
label
:
'出库门店'
,
name
:
'merchantId'
,
type
:
'select'
,
noDataText
:
'请先选择出库仓库'
,
optionList
:
[],
optionId
:
'merchantId'
,
optionLabel
:
'merchantName'
,
optionsName
:
'merchantIdList'
},
},
{
{
label
:
'使用门店'
,
label
:
'使用门店'
,
name
:
'storeUsage'
,
name
:
'storeUsage'
,
...
@@ -177,11 +204,16 @@ export default {
...
@@ -177,11 +204,16 @@ export default {
prop
:
'businessCode'
prop
:
'businessCode'
},
},
{
{
label
:
'出库
门店
'
,
label
:
'出库
仓库
'
,
prop
:
'yqMerchantName'
,
prop
:
'yqMerchantName'
,
width
:
200
width
:
200
},
},
{
{
label
:
'出库门店'
,
prop
:
'merchantName'
,
width
:
200
},
{
// label: '适用门店',
// label: '适用门店',
label
:
'使用门店'
,
label
:
'使用门店'
,
prop
:
'storeUsage'
,
prop
:
'storeUsage'
,
...
@@ -210,7 +242,8 @@ export default {
...
@@ -210,7 +242,8 @@ export default {
}
}
],
],
productTypeList
:
[],
productTypeList
:
[],
yqMerchantList
:
[]
yqMerchantList
:
[],
merchantIdList
:
[]
}
}
}
}
},
},
...
@@ -222,7 +255,7 @@ export default {
...
@@ -222,7 +255,7 @@ export default {
})
})
// 获取当前登录账号可见的园区店列表
// 获取当前登录账号可见的园区店列表
this
.
$apis
.
stockManage
.
getyqMerchantList
({}).
then
(
res
=>
{
this
.
$apis
.
stockManage
.
getyqMerchantList
({
mainPartnerMerchant
:
true
}).
then
(
res
=>
{
this
.
baseData
.
yqMerchantList
=
res
this
.
baseData
.
yqMerchantList
=
res
this
.
getOptionsList
(
'showFormData'
)
this
.
getOptionsList
(
'showFormData'
)
})
})
...
@@ -244,6 +277,20 @@ export default {
...
@@ -244,6 +277,20 @@ export default {
resolve
()
resolve
()
})
})
},
},
// 获取仓库门店
getServicemerchantrefList
(
merchantId
)
{
this
.
$apis
.
stockManage
.
getServicemerchantrefList
({
yqMerchantId
:
merchantId
}).
then
(
res
=>
{
this
.
baseData
.
merchantIdList
=
res
||
[]
//总店
let
_headOffice
=
this
.
baseData
.
yqMerchantList
.
find
(
item
=>
item
.
merchantNo
===
merchantId
)
_headOffice
.
merchantId
=
_headOffice
.
merchantNo
//门店选项中加入总店
this
.
baseData
.
merchantIdList
.
push
(
_headOffice
)
this
.
getOptionsList
(
'showFormData'
)
})
},
getOptionsList
(
formName
,
hasAll
=
true
,
refreshSigle
)
{
getOptionsList
(
formName
,
hasAll
=
true
,
refreshSigle
)
{
if
(
refreshSigle
)
{
if
(
refreshSigle
)
{
var
item
=
this
[
formName
].
find
(
k
=>
k
.
name
==
refreshSigle
)
var
item
=
this
[
formName
].
find
(
k
=>
k
.
name
==
refreshSigle
)
...
@@ -289,12 +336,18 @@ export default {
...
@@ -289,12 +336,18 @@ export default {
eventType
:
''
,
eventType
:
''
,
upgradeGoodsName
:
''
,
upgradeGoodsName
:
''
,
yqMerchantId
:
''
,
yqMerchantId
:
''
,
merchantId
:
''
,
goodsType
:
''
,
goodsType
:
''
,
businessCode
:
''
,
businessCode
:
''
,
goodsSeries
:
''
,
goodsSeries
:
''
,
productCode
:
''
productCode
:
''
}
}
this
.
showFormData
[
this
.
findFormIdx
(
'merchantId'
)].
optionList
=
[]
this
.
handleSearch
()
this
.
handleSearch
()
},
findFormIdx
(
name
)
{
return
this
.
showFormData
.
findIndex
(
item
=>
item
.
name
===
name
)
}
}
}
}
}
}
...
...
src/views/stock/index.vue
View file @
8f592da
...
@@ -2,22 +2,47 @@
...
@@ -2,22 +2,47 @@
<
template
>
<
template
>
<div
class=
"purchase"
>
<div
class=
"purchase"
>
<div
class=
"container"
>
<div
class=
"container"
>
<GLCombiForm
ref=
"showSearch"
:rowNumber=
"1"
:formObj=
"searchForm"
:formData=
"showFormData"
@
handleOk=
"handleSearch"
@
handleRest=
"handleReset"
></GLCombiForm>
<GLCombiForm
ref=
"showSearch"
:rowNumber=
"1"
:formObj=
"searchForm"
:formData=
"showFormData"
@
handleOk=
"handleSearch"
@
handleRest=
"handleReset"
></GLCombiForm>
<div
class=
"table-header"
>
<div
class=
"table-header"
>
<h2>
库存列表
</h2>
<h2>
库存列表
</h2>
<el-button
type=
"primary"
size=
"small"
@
click=
"exportExcel"
>
导出
</el-button>
<el-button
type=
"primary"
size=
"small"
@
click=
"exportExcel"
>
导出
</el-button>
</div>
</div>
<!-- 表格区域 开始 -->
<!-- 表格区域 开始 -->
<GLTable
ref=
"stockRef"
:getListApi=
"getListApi"
:noDataImg=
"url"
:searchForm=
"tableSearchForm"
:tableParams=
"tableParams"
:pageConf=
"pageConf"
:beforeSearchFn=
"beforeSearchFn"
@
setTableFinishFun=
"setTableFinishFun"
>
<GLTable
ref=
"stockRef"
<div
class=
"table-btns"
slot=
"auth-button"
slot-scope=
"scope"
>
:getListApi=
"getListApi"
<el-button
type=
"text"
@
click=
"handleDetail(scope.scope)"
>
查看
</el-button>
:noDataImg=
"url"
:searchForm=
"tableSearchForm"
:tableParams=
"tableParams"
:pageConf=
"pageConf"
:beforeSearchFn=
"beforeSearchFn"
@
setTableFinishFun=
"setTableFinishFun"
>
<div
class=
"table-btns"
slot=
"auth-button"
slot-scope=
"scope"
>
<el-button
type=
"text"
@
click=
"handleInventoryDetails(scope.scope)"
>
库存明细
</el-button>
<el-button
type=
"text"
@
click=
"handleDetail(scope.scope)"
>
统计
</el-button>
</div>
</div>
</GLTable>
</GLTable>
<!-- 表格区域 end -->
<!-- 表格区域 end -->
</div>
</div>
<!-- 查看 -->
<!-- 查看 -->
<stock-month-dialog
:stock-month-visible=
"stockMonthVisible"
:stockInfo=
"stockInfo"
v-if=
"stockMonthVisible"
@
dialogClose=
"dialogClose"
/>
<stock-month-dialog
:stock-month-visible=
"stockMonthVisible"
:stockInfo=
"stockInfo"
v-if=
"stockMonthVisible"
@
dialogClose=
"dialogClose"
/>
<stockDetailDialog
:visible
.
sync=
"stockDetailDialogVisible"
:recordInfo=
"stockInfo"
v-if=
"stockDetailDialogVisible"
/>
</div>
</div>
</
template
>
</
template
>
...
@@ -26,10 +51,12 @@ import * as dayjs from 'dayjs'
...
@@ -26,10 +51,12 @@ import * as dayjs from 'dayjs'
import
url
from
'@/assets/empty.png'
import
url
from
'@/assets/empty.png'
import
{
membraneTypeList
}
from
'@/utils/constants.js'
import
{
membraneTypeList
}
from
'@/utils/constants.js'
import
stockMonthDialog
from
'./stockMonthDialog'
import
stockMonthDialog
from
'./stockMonthDialog'
import
stockDetailDialog
from
'./stockDetailDialog'
export
default
{
export
default
{
name
:
'warehousing'
,
name
:
'warehousing'
,
components
:
{
components
:
{
stockMonthDialog
stockMonthDialog
,
stockDetailDialog
},
},
data
()
{
data
()
{
return
{
return
{
...
@@ -46,6 +73,7 @@ export default {
...
@@ -46,6 +73,7 @@ export default {
tableSearchForm
:
{},
tableSearchForm
:
{},
stockInfo
:
{},
stockInfo
:
{},
stockMonthVisible
:
false
,
stockMonthVisible
:
false
,
stockDetailDialogVisible
:
false
,
showFormData
:
[
showFormData
:
[
{
{
label
:
'商品名称'
,
label
:
'商品名称'
,
...
@@ -68,7 +96,7 @@ export default {
...
@@ -68,7 +96,7 @@ export default {
isClear
:
true
isClear
:
true
},
},
{
{
label
:
'所属
门店
'
,
label
:
'所属
仓库
'
,
name
:
'yqMerchantId'
,
name
:
'yqMerchantId'
,
type
:
'select'
,
type
:
'select'
,
optionList
:
[],
optionList
:
[],
...
@@ -135,9 +163,13 @@ export default {
...
@@ -135,9 +163,13 @@ export default {
}
}
},
},
{
{
label
:
'所属
门店
'
,
label
:
'所属
仓库
'
,
prop
:
'yqMerchantName'
,
prop
:
'yqMerchantName'
,
width
:
200
width
:
200
},
{
label
:
'所属商户'
,
prop
:
'partnerMerchantName'
,
width
:
'200px'
}
}
]
]
},
},
...
@@ -157,7 +189,7 @@ export default {
...
@@ -157,7 +189,7 @@ export default {
})
})
// 获取当前登录账号可见的园区店列表
// 获取当前登录账号可见的园区店列表
this
.
$apis
.
stockManage
.
getyqMerchantList
({}).
then
(
res
=>
{
this
.
$apis
.
stockManage
.
getyqMerchantList
({
mainPartnerMerchant
:
true
}).
then
(
res
=>
{
this
.
baseData
.
yqMerchantList
=
res
this
.
baseData
.
yqMerchantList
=
res
this
.
getOptionsList
(
'showFormData'
)
this
.
getOptionsList
(
'showFormData'
)
})
})
...
@@ -171,6 +203,11 @@ export default {
...
@@ -171,6 +203,11 @@ export default {
resolve
()
resolve
()
})
})
},
},
handleInventoryDetails
(
row
)
{
this
.
stockInfo
=
row
console
.
log
(
this
.
stockInfo
);
this
.
stockDetailDialogVisible
=
true
},
// 查看详情
// 查看详情
handleDetail
(
row
)
{
handleDetail
(
row
)
{
this
.
stockInfo
=
row
this
.
stockInfo
=
row
...
@@ -235,10 +272,12 @@ export default {
...
@@ -235,10 +272,12 @@ export default {
<
style
scoped
lang=
"scss"
>
<
style
scoped
lang=
"scss"
>
@import
'@/assets/css/mixin.scss'
;
@import
'@/assets/css/mixin.scss'
;
.purchase
{
.purchase
{
.table-header
{
.table-header
{
@include
space-between_center;
@include
space-between_center;
margin-bottom
:
10px
;
margin-bottom
:
10px
;
h2
{
h2
{
font-weight
:
600
;
font-weight
:
600
;
font-size
:
16px
;
font-size
:
16px
;
...
...
src/views/stock/stockDetailDialog.vue
0 → 100644
View file @
8f592da
<!-- 库存明细弹窗 -->
<
template
>
<GLDialog
bigTitle=
"库存明细"
:visible
.
sync=
"dialogVisible"
class=
"stockMonthDailog"
width=
"30%"
mode=
"big"
:destroy-on-close=
"true"
:close-on-click-modal=
"false"
okText=
"关闭"
@
onOk=
"handleClose"
@
onCancel=
"handleClose"
>
<div>
<div
class=
"d2-container-content"
>
<GLTable
ref=
"recordTable"
:get-list-api=
"getListApi"
:search-form=
"searchForm"
:table-params=
"tableParams"
:pageConf=
"pageConf"
>
</GLTable>
</div>
</div>
<span
slot=
"footer"
class=
"dialog-footer"
>
<el-button
type=
"primary"
size=
"small"
@
click=
"handleClose"
>
关闭
</el-button>
</span>
</GLDialog>
</
template
>
<
script
>
// import { mapActions, mapState } from 'vuex'
// import { merchantShopGoodsStockPage } from '@api/stockManage'
import
{
membraneTypeList
}
from
'@/utils/constants.js'
export
default
{
name
:
'StockDetailDialog'
,
props
:
{
visible
:
{
type
:
Boolean
,
default
:
false
},
recordInfo
:
{
type
:
Object
,
default
:
()
=>
{
}
}
},
data
()
{
return
{
pageConf
:
{
pageSize
:
'pageSize'
,
pageNum
:
'currentPage'
,
totalCount
:
'total'
},
// userInfo: this.$store.state.d2admin.user.info,
membraneTypeList
:
membraneTypeList
,
searchForm
:
{
upgradeGoodsId
:
''
,
yqMerchantId
:
''
},
getListApi
:
this
.
$apis
.
stockManage
.
merchantShopGoodsStockPage
,
tableData
:
[],
tableParams
:
{
btnId
:
new
Date
().
getTime
()
+
parseInt
(
Math
.
random
()
*
1000
),
listName
:
'list'
,
// tableOption: false,
tableColumns
:
[
{
label
:
'门店'
,
prop
:
'merchantName'
,
width
:
'200px'
},
{
label
:
'当前库存'
,
prop
:
'stock'
,
// width: ''
formatter
:
(
cellValue
)
=>
{
return
(
cellValue
.
stock
||
cellValue
.
stock
==
0
)
?
parseFloat
(
cellValue
.
stock
).
toFixed
(
2
)
+
(
this
.
membraneTypeList
.
includes
(
cellValue
.
goodsType
)
?
'米'
:
'件'
)
:
'-'
}
}
]
}
}
},
computed
:
{
dialogVisible
:
{
get
()
{
return
this
.
visible
},
set
(
val
)
{
this
.
$emit
(
'update:visible'
,
val
)
}
}
},
mounted
()
{
console
.
log
(
'111'
);
if
(
this
.
recordInfo
)
{
this
.
searchForm
.
yqMerchantId
=
this
.
recordInfo
.
yqMerchantId
this
.
searchForm
.
upgradeGoodsId
=
this
.
recordInfo
.
upgradeGoodsId
}
},
methods
:
{
handleClose
()
{
this
.
dialogVisible
=
false
}
}
}
</
script
>
<
style
scoped
>
.count-txt
{
font-weight
:
700
;
color
:
#2a58ad
;
margin
:
0
2px
;
}
.stockMonthDailog
.el-dialog
{
margin-top
:
20vh
!important
;
min-width
:
700px
;
}
.stockMonthDailog
.btn-tips
img
{
width
:
18px
;
height
:
15px
;
margin-right
:
9px
;
vertical-align
:
bottom
;
}
.stockMonthDailog
.btn-tips
{
display
:
inline-block
;
font-size
:
12px
;
height
:
14px
;
line-height
:
14px
;
background-color
:
#fff2e5
;
color
:
#999999
;
margin-right
:
24px
;
padding
:
6.5px
10px
;
}
.show-search
{
margin-left
:
-65px
;
}
</
style
>
src/views/stock/stockMonthDialog.vue
View file @
8f592da
<
template
>
<
template
>
<GLDialog
class=
"stock-dialog"
v-if=
"stockMonthVisible"
:destroy-on-close=
"true"
:before-close=
"handleClose"
bigTitle=
"月度库存结算单"
mode=
"big"
okText=
"关闭"
:visible
.
sync=
"stockMonthVisible"
:close-on-click-modal=
"false"
@
onOk=
"handleClose"
@
onCancel=
"handleClose"
>
<GLDialog
class=
"stock-dialog"
<div
class=
"detail-content"
v-if=
"stockMonthVisible"
>
v-if=
"stockMonthVisible"
<el-form
:inline=
"true"
:model=
"searchForm"
size=
"small"
>
:destroy-on-close=
"true"
:before-close=
"handleClose"
bigTitle=
"月度库存结算单"
mode=
"big"
okText=
"关闭"
:visible
.
sync=
"stockMonthVisible"
:close-on-click-modal=
"false"
@
onOk=
"handleClose"
@
onCancel=
"handleClose"
>
<div
class=
"detail-content"
v-if=
"stockMonthVisible"
>
<el-form
:inline=
"true"
:model=
"searchForm"
size=
"small"
>
<el-form-item
label=
"年度:"
>
<el-form-item
label=
"年度:"
>
<el-date-picker
v-model=
"searchForm.year"
type=
"year"
placeholder=
"选择年"
value-format=
"yyyy"
format=
"yyyy"
:clearable=
"false"
:picker-options=
"pickerOption"
@
change=
"chooseYear"
></el-date-picker>
<el-date-picker
v-model=
"searchForm.year"
type=
"year"
placeholder=
"选择年"
value-format=
"yyyy"
format=
"yyyy"
:clearable=
"false"
:picker-options=
"pickerOption"
@
change=
"chooseYear"
></el-date-picker>
</el-form-item>
</el-form-item>
</el-form>
</el-form>
<div
class=
"table-class"
>
<div
class=
"table-class"
>
<GLTable
ref=
"purchaseOrderDetailTable"
:tableParams=
"tableParams"
:has-num=
"false"
:hasPage=
"false"
:tableData=
"tableData"
:pageConf=
"pageConf"
></GLTable>
<GLTable
ref=
"purchaseOrderDetailTable"
:tableParams=
"tableParams"
:has-num=
"false"
:hasPage=
"false"
:tableData=
"tableData"
:pageConf=
"pageConf"
></GLTable>
</div>
</div>
<span
class=
"btn-tips"
>
<span
class=
"btn-tips"
>
<img
src=
"@/images/icon-warn.png"
/>
<img
src=
"@/images/icon-warn.png"
/>
说明:月平均加权单价=上月结存库存金额+本月采购金额/上月结存库存数量+本月采购数量
说明:月平均加权单价=上月结存库存金额+本月采购金额/上月结存库存数量+本月采购数量
</span>
</span>
</div>
</div>
<span
slot=
"footer"
class=
"dialog-footer"
>
<span
slot=
"footer"
<el-button
type=
"primary"
size=
"small"
@
click=
"handleClose"
>
关闭
</el-button>
class=
"dialog-footer"
>
<el-button
type=
"primary"
size=
"small"
@
click=
"handleClose"
>
关闭
</el-button>
</span>
</span>
</GLDialog>
</GLDialog>
</
template
>
</
template
>
...
@@ -31,7 +59,7 @@ export default {
...
@@ -31,7 +59,7 @@ export default {
},
},
stockInfo
:
{
stockInfo
:
{
type
:
Object
,
type
:
Object
,
default
:
()
=>
{}
default
:
()
=>
{
}
}
}
},
},
data
()
{
data
()
{
...
...
src/views/warehousing/index.vue
View file @
8f592da
<
template
>
<
template
>
<div
class=
"purchase"
>
<div
class=
"purchase"
>
<div
class=
"container"
>
<div
class=
"container"
>
<GLCombiForm
ref=
"showSearch"
:rowNumber=
"1"
:formObj=
"searchForm"
:formData=
"showFormData"
@
handleOk=
"handleSearch"
@
handleRest=
"handleReset"
></GLCombiForm>
<GLCombiForm
ref=
"showSearch"
:rowNumber=
"1"
:formObj=
"searchForm"
:formData=
"showFormData"
@
handleOk=
"handleSearch"
@
handleRest=
"handleReset"
></GLCombiForm>
<div
class=
"table-header"
>
<div
class=
"table-header"
>
<h2>
入库列表
</h2>
<h2>
入库列表
</h2>
<el-button
type=
"primary"
size=
"small"
@
click=
"exportExcel"
>
导出
</el-button>
<el-button
type=
"primary"
size=
"small"
@
click=
"exportExcel"
>
导出
</el-button>
</div>
</div>
<!-- 表格区域 开始 -->
<!-- 表格区域 开始 -->
<GLTable
ref=
"warehousingRef"
:getListApi=
"getListApi"
:noDataImg=
"url"
:searchForm=
"tableSearchForm"
:tableParams=
"tableParams"
:pageConf=
"pageConf"
:beforeSearchFn=
"beforeSearchFn"
@
setTableFinishFun=
"setTableFinishFun"
></GLTable>
<GLTable
ref=
"warehousingRef"
:getListApi=
"getListApi"
:noDataImg=
"url"
:searchForm=
"tableSearchForm"
:tableParams=
"tableParams"
:pageConf=
"pageConf"
:beforeSearchFn=
"beforeSearchFn"
@
setTableFinishFun=
"setTableFinishFun"
></GLTable>
<!-- 表格区域 end -->
<!-- 表格区域 end -->
</div>
</div>
</div>
</div>
...
@@ -30,10 +33,12 @@ export default {
...
@@ -30,10 +33,12 @@ export default {
increaseStockType
:
''
,
increaseStockType
:
''
,
upgradeGoodsName
:
''
,
upgradeGoodsName
:
''
,
yqMerchantId
:
''
,
yqMerchantId
:
''
,
merchantId
:
''
,
goodsType
:
''
,
goodsType
:
''
,
businessCode
:
''
,
businessCode
:
''
,
goodsSeries
:
''
,
goodsSeries
:
''
,
productCode
:
''
productCode
:
''
,
deliveryNumber
:
''
},
},
tableSearchForm
:
{},
tableSearchForm
:
{},
paramsObj
:
{},
paramsObj
:
{},
...
@@ -70,15 +75,6 @@ export default {
...
@@ -70,15 +75,6 @@ export default {
isClear
:
true
isClear
:
true
},
},
{
{
label
:
'入库门店'
,
name
:
'yqMerchantId'
,
type
:
'select'
,
optionList
:
[],
optionId
:
'merchantNo'
,
optionLabel
:
'merchantName'
,
optionsName
:
'yqMerchantList'
},
{
label
:
'所属分类'
,
label
:
'所属分类'
,
name
:
'goodsType'
,
name
:
'goodsType'
,
type
:
'select'
,
type
:
'select'
,
...
@@ -95,11 +91,42 @@ export default {
...
@@ -95,11 +91,42 @@ export default {
isClear
:
true
isClear
:
true
},
},
{
{
label
:
'发货单号'
,
name
:
'deliveryNumber'
,
type
:
'input'
,
maxlength
:
'20'
,
isClear
:
true
},
{
label
:
'系列'
,
label
:
'系列'
,
name
:
'goodsSeries'
,
name
:
'goodsSeries'
,
type
:
'input'
,
type
:
'input'
,
maxlength
:
'20'
,
maxlength
:
'20'
,
isClear
:
true
isClear
:
true
},
{
label
:
'入库仓库'
,
name
:
'yqMerchantId'
,
type
:
'select'
,
optionList
:
[],
optionId
:
'merchantNo'
,
optionLabel
:
'merchantName'
,
optionsName
:
'yqMerchantList'
,
changeAttr
:
(
value
,
targetItem
)
=>
{
value
?
this
.
getServicemerchantrefList
(
value
)
:
(
this
.
baseData
.
merchantIdList
=
[])
this
.
searchForm
.
merchantId
=
''
this
.
getOptionsList
(
'showFormData'
)
}
},
{
label
:
'入库门店'
,
name
:
'merchantId'
,
type
:
'select'
,
noDataText
:
'请先选择入库仓库'
,
optionList
:
[],
optionId
:
'merchantId'
,
optionLabel
:
'merchantName'
,
optionsName
:
'merchantIdList'
}
}
],
],
// 表格
// 表格
...
@@ -144,7 +171,7 @@ export default {
...
@@ -144,7 +171,7 @@ export default {
label
:
'入库数量'
,
label
:
'入库数量'
,
prop
:
'increaseStockNum'
,
prop
:
'increaseStockNum'
,
formatter
:
cellValue
=>
{
formatter
:
cellValue
=>
{
return
cellValue
.
increaseStockNum
||
cellValue
.
increaseStockNum
==
0
?
parseFloat
(
cellValue
.
increaseStockNum
).
toFixed
(
2
)
+
(
this
.
membraneTypeList
.
includes
(
cellValue
.
goodsType
)
&&
cellValue
.
goodsType
!=
this
.
$purchaseType
?
'米'
:
'件'
)
:
'-'
return
cellValue
.
increaseStockNum
||
cellValue
.
increaseStockNum
==
0
?
parseFloat
(
cellValue
.
increaseStockNum
).
toFixed
(
2
)
+
(
this
.
membraneTypeList
.
includes
(
cellValue
.
goodsType
)
&&
cellValue
.
goodsType
!=
this
.
$purchaseType
?
'米'
:
'件'
)
:
'-'
},
},
width
:
120
width
:
120
},
},
...
@@ -170,9 +197,19 @@ export default {
...
@@ -170,9 +197,19 @@ export default {
minWidth
:
150
minWidth
:
150
},
},
{
{
label
:
'入库门店'
,
label
:
'关联发货单号'
,
prop
:
'deliveryNumber'
,
minWidth
:
150
},
{
label
:
'入库仓库'
,
prop
:
'yqMerchantName'
,
prop
:
'yqMerchantName'
,
width
:
200
width
:
200
},
{
label
:
'入库门店'
,
prop
:
'merchantName'
,
width
:
200
}
}
]
]
},
},
...
@@ -191,10 +228,15 @@ export default {
...
@@ -191,10 +228,15 @@ export default {
{
{
confId
:
'3'
,
confId
:
'3'
,
confLabel
:
'调拨入库'
confLabel
:
'调拨入库'
},
{
confId
:
'4'
,
confLabel
:
'订单入库'
}
}
],
],
productTypeList
:
[],
productTypeList
:
[],
yqMerchantList
:
[]
yqMerchantList
:
[],
merchantIdList
:
[]
}
}
}
}
},
},
...
@@ -206,7 +248,7 @@ export default {
...
@@ -206,7 +248,7 @@ export default {
})
})
// 获取当前登录账号可见的园区店列表
// 获取当前登录账号可见的园区店列表
this
.
$apis
.
stockManage
.
getyqMerchantList
({}).
then
(
res
=>
{
this
.
$apis
.
stockManage
.
getyqMerchantList
({
mainPartnerMerchant
:
true
}).
then
(
res
=>
{
this
.
baseData
.
yqMerchantList
=
res
this
.
baseData
.
yqMerchantList
=
res
this
.
getOptionsList
(
'showFormData'
)
this
.
getOptionsList
(
'showFormData'
)
})
})
...
@@ -229,6 +271,21 @@ export default {
...
@@ -229,6 +271,21 @@ export default {
})
})
},
},
// 获取仓库门店
getServicemerchantrefList
(
merchantId
)
{
this
.
$apis
.
stockManage
.
getServicemerchantrefList
({
yqMerchantId
:
merchantId
}).
then
(
res
=>
{
this
.
baseData
.
merchantIdList
=
res
||
[]
//总店
let
_headOffice
=
this
.
baseData
.
yqMerchantList
.
find
(
item
=>
item
.
merchantNo
===
merchantId
)
_headOffice
.
merchantId
=
_headOffice
.
merchantNo
//门店选项中加入总店
this
.
baseData
.
merchantIdList
.
push
(
_headOffice
)
this
.
getOptionsList
(
'showFormData'
)
})
},
secondConfirm
(
title
,
txt
,
apiModule
,
apiName
,
apiParams
,
fn
)
{
secondConfirm
(
title
,
txt
,
apiModule
,
apiName
,
apiParams
,
fn
)
{
this
.
$confirm
(
txt
,
title
,
{
this
.
$confirm
(
txt
,
title
,
{
confirmButtonText
:
'确定'
,
confirmButtonText
:
'确定'
,
...
@@ -312,12 +369,19 @@ export default {
...
@@ -312,12 +369,19 @@ export default {
increaseStockType
:
''
,
increaseStockType
:
''
,
upgradeGoodsName
:
''
,
upgradeGoodsName
:
''
,
yqMerchantId
:
''
,
yqMerchantId
:
''
,
merchantId
:
''
,
goodsType
:
''
,
goodsType
:
''
,
businessCode
:
''
,
businessCode
:
''
,
goodsSeries
:
''
,
goodsSeries
:
''
,
productCode
:
''
productCode
:
''
,
deliveryNumber
:
''
}
}
this
.
showFormData
[
this
.
findFormIdx
(
'merchantId'
)].
optionList
=
[]
this
.
handleSearch
()
this
.
handleSearch
()
},
findFormIdx
(
name
)
{
return
this
.
showFormData
.
findIndex
(
item
=>
item
.
name
===
name
)
}
}
}
}
}
}
...
@@ -325,10 +389,12 @@ export default {
...
@@ -325,10 +389,12 @@ export default {
<
style
scoped
lang=
"scss"
>
<
style
scoped
lang=
"scss"
>
@import
'@/assets/css/mixin.scss'
;
@import
'@/assets/css/mixin.scss'
;
.purchase
{
.purchase
{
.table-header
{
.table-header
{
@include
space-between_center;
@include
space-between_center;
margin-bottom
:
10px
;
margin-bottom
:
10px
;
h2
{
h2
{
font-weight
:
600
;
font-weight
:
600
;
font-size
:
16px
;
font-size
:
16px
;
...
...
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