Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
D
data-center-auto
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
bltdc
data-center-auto
Commits
0fd53f7a
Commit
0fd53f7a
authored
Feb 14, 2019
by
lizefeng
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
aims 周转表,调拨在途点击查看明细
parent
5cab1cee
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
76 additions
and
10 deletions
+76
-10
daily.cs
AutoTurnOver.DB/daily.cs
+0
-0
dc_auto_turnover.cs
AutoTurnOver.DB/dc_auto_turnover.cs
+2
-1
dc_base_stock.cs
AutoTurnOver.Models/dc_base_stock.cs
+10
-0
dc_purchase_daily_dto.cs
AutoTurnOver.Models/dc_purchase_daily_dto.cs
+26
-8
DailyServices.cs
AutoTurnOver.Services/DailyServices.cs
+12
-0
DailyController.cs
AutoTurnOver/Controllers/DailyController.cs
+26
-1
No files found.
AutoTurnOver.DB/daily.cs
View file @
0fd53f7a
This diff is collapsed.
Click to expand it.
AutoTurnOver.DB/dc_auto_turnover.cs
View file @
0fd53f7a
...
...
@@ -40,7 +40,8 @@ sum(dat.quantity_transfer) as 'quantity_transfer',
sum(t2.oneday_sales) as 'oneday_sales',
sum(t2.forecast_oneday_sales) as 'forecast_oneday_sales2',
sum(dat.quantity_final_advise) as 'quantity_final_advise',
sum(dat.quantity_promotion) as 'quantity_promotion'
sum(dat.quantity_promotion) as 'quantity_promotion',
sum(dat.quantity_safe_inventory) as 'quantity_safe_inventory'
from dc_auto_turnover as dat
left join dc_auto_sales as t2 on t2.bailun_sku=dat.bailun_sku and dat.warehouse_code = t2.warehouse_code
left join dc_base_warehouse as t3 on dat.warehouse_code = t3.warehouse_code
...
...
AutoTurnOver.Models/dc_base_stock.cs
View file @
0fd53f7a
...
...
@@ -186,5 +186,15 @@ namespace AutoTurnOver.Models
/// 产品内部编码
/// </summary>
public
string
product_inner_code
{
get
;
set
;
}
/// <summary>
/// 实时采购在途
/// </summary>
public
int
realtime_quantity_purchase
{
get
;
set
;
}
/// <summary>
/// 实时调拨在途
/// </summary>
public
int
realtime_quantity_transfer
{
get
;
set
;
}
}
}
AutoTurnOver.Models/dc_purchase_daily_dto.cs
View file @
0fd53f7a
...
...
@@ -33,23 +33,41 @@ namespace AutoTurnOver.Models
/// </summary>
public
string
purchase_id
{
get
;
set
;
}
/// <summary>
///
采购
数量
///
在途
数量
/// </summary>
public
int
purchase
Quantity
{
get
;
set
;
}
public
int
daily
Quantity
{
get
;
set
;
}
/// <summary>
///
入库数量
///
预计到货
/// </summary>
public
int
inboundQuantity
{
get
;
set
;
}
public
DateTime
?
estimated_arrival_time
{
get
;
set
;
}
}
/// <summary>
/// 调拨明细
/// </summary>
public
class
dc_transfer_daily_dto
{
public
string
bailun_sku
{
get
;
set
;
}
public
string
warehouse_code
{
get
;
set
;
}
public
string
transfer_order_id
{
get
;
set
;
}
public
string
estimated_arrival_time
{
get
;
set
;
}
public
string
create_time
{
get
;
set
;
}
/// <summary>
/// 在途数量
/// </summary>
public
int
dailyQuantity
{
get
{
return
purchaseQuantity
-
inboundQuantity
;
}
}
public
string
count
{
get
;
set
;
}
public
string
warehouse_name
{
get
;
set
;
}
}
}
AutoTurnOver.Services/DailyServices.cs
View file @
0fd53f7a
...
...
@@ -21,6 +21,18 @@ namespace AutoTurnOver.Services
return
DB
.
daily
.
List
(
sku
,
warehouse_code
);
}
/// <summary>
/// 查询调拨在途数据
/// </summary>
/// <param name="sku">sku</param>
/// <param name="warehouse_code">仓库编码</param>
/// <returns></returns>
public
IEnumerable
<
dc_transfer_daily_dto
>
TransferList
(
string
sku
,
string
warehouse_code
)
{
return
DB
.
daily
.
TransferList
(
sku
,
warehouse_code
);
}
public
IEnumerable
<
dc_base_stock_dto
>
RealtimeList
(
string
sku
,
string
warehouse_code
,
string
product_inner_code
,
string
sku_title_cn
,
int
offset
,
int
limit
,
ref
int
total
,
string
warehousetype
,
int
?
warehousearea
)
{
return
DB
.
daily
.
RealtimeList
(
sku
,
warehouse_code
,
product_inner_code
,
sku_title_cn
,
offset
,
limit
,
ref
total
,
warehousetype
,
warehousearea
);
...
...
AutoTurnOver/Controllers/DailyController.cs
View file @
0fd53f7a
...
...
@@ -31,6 +31,28 @@ namespace AutoTurnOver.Controllers
}
/// <summary>
/// 调拨在途
/// </summary>
/// <param name="warehousecode"></param>
/// <param name="sku"></param>
/// <returns></returns>
[
HttpGet
]
public
JsonResult
TransferList
(
string
warehousecode
,
string
sku
)
{
var
service
=
new
Services
.
DailyServices
();
var
list
=
service
.
TransferList
(
sku
,
warehousecode
);
return
new
JsonResult
(
new
{
rows
=
list
,
total
=
list
.
Count
()
});
}
/// <summary>
/// 实时库存
/// </summary>
/// <param name="sku"></param>
...
...
@@ -65,7 +87,7 @@ namespace AutoTurnOver.Controllers
var
list
=
services
.
RealtimeList
(
sku
,
warehousecode
,
product_inner_code
,
sku_title_cn
,
0
,
int
.
MaxValue
,
ref
total
,
warehousetype
,
warehousearea
);
DataTable
table
=
new
DataTable
();
string
[]
cols
=
new
string
[]
{
"Sku"
,
"采购名称"
,
"中文名"
,
"英文名称"
,
"内部编码"
,
"仓库编码"
,
"仓库名称"
,
"货主编码"
string
[]
cols
=
new
string
[]
{
"Sku"
,
"采购名称"
,
"中文名"
,
"英文名称"
,
"内部编码"
,
"仓库编码"
,
"仓库名称"
,
"货主编码"
,
"实时采购在途"
,
"实时调拨在途"
,
"订货数量"
,
"运输在途"
,
"中转仓库存"
,
"冻结库存"
,
"供应商库存"
,
"预售库存"
,
"不良品库存"
,
"在途库存"
,
"收货待检"
,
"待上架"
,
"可配库存"
,
"销售可用库存(聚合)"
,
"销售可用库存(私有)"
,
"销售可用库存(共享)"
,
"在仓库存(共享)"
,
"在仓库存(私有)"
,
"在仓库存(聚合)"
,
"仓库占用(共享)"
,
"仓库占用(私有)"
,
"仓库占用(聚合)"
,
"活动占用"
,
"单占用(私有)"
,
"订单占用(共享)"
,
"订单占用(聚合)"
,
"环球更新时间"
...
...
@@ -113,6 +135,9 @@ namespace AutoTurnOver.Controllers
row
[
"订单占用(聚合)"
]
=
itemData
.
occupy_order_share
;
row
[
"环球更新时间"
]
=
itemData
.
update_time
;
row
[
"实时采购在途"
]
=
itemData
.
realtime_quantity_purchase
;
row
[
"实时调拨在途"
]
=
itemData
.
realtime_quantity_transfer
;
table
.
Rows
.
Add
(
row
);
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment