Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
B
Bailun.DataCenter
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
wangwanchang
Bailun.DataCenter
Commits
bc7c674b
Commit
bc7c674b
authored
May 15, 2018
by
wangwanchang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
sku仓库列表页增加超链,订单统计任务修改
parent
096e3a5e
Show whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
521 additions
and
195 deletions
+521
-195
SkuOrderAppService.cs
...Bailun.DataCenter.Application/Order/SkuOrderAppService.cs
+15
-0
SkuStatisticAppService.cs
...ataCenter.Application/Statistic/SkuStatisticAppService.cs
+7
-3
SkuStatisticsJob.cs
...n.DataCenter.Tasks/Jobs/SkuStatistics/SkuStatisticsJob.cs
+25
-1
WarehouseStatisticsJob.cs
....Tasks/Jobs/WarehouseStatistics/WarehouseStatisticsJob.cs
+1
-1
Program.cs
trunk/Bailun.DataCenter.Tasks/Program.cs
+25
-0
Index.cshtml
...un.DataCenter.Web/Areas/Order/Views/SkuOrder/Index.cshtml
+115
-17
Index.cshtml
...taCenter.Web/Areas/Statistic/Views/SkuActive/Index.cshtml
+11
-2
skuwarehouseIndex.cshtml
...eas/Statistic/Views/SkuStatistic/skuwarehouseIndex.cshtml
+139
-100
Index.cshtml
...er.Web/Areas/Statistic/Views/WarehouseActive/Index.cshtml
+90
-57
WarehouseActiveNewIndex.cshtml
...stic/Views/WarehouseActive/WarehouseActiveNewIndex.cshtml
+93
-14
No files found.
trunk/Bailun.DataCenter.Application/Order/SkuOrderAppService.cs
View file @
bc7c674b
...
@@ -160,6 +160,16 @@ namespace Bailun.DataCenter.Application.Order
...
@@ -160,6 +160,16 @@ namespace Bailun.DataCenter.Application.Order
var
endpaytime
=
DateTime
.
Parse
(
queryParam
[
"endpaytime"
].
ToString
());
var
endpaytime
=
DateTime
.
Parse
(
queryParam
[
"endpaytime"
].
ToString
());
query
=
query
.
Where
(
t
=>
t
.
paytime
<
endpaytime
);
query
=
query
.
Where
(
t
=>
t
.
paytime
<
endpaytime
);
}
}
if
(!
queryParam
[
"shipstatus"
].
IsEmpty
())
{
var
shipstatus
=
queryParam
[
"shipstatus"
].
ToInt
();
query
=
query
.
Where
(
t
=>
t
.
shipping_status
==
shipstatus
);
}
if
(!
queryParam
[
"status"
].
IsEmpty
())
{
var
status
=
queryParam
[
"status"
].
ToInt
();
query
=
query
.
Where
(
t
=>
t
.
state
==
status
);
}
if
(!
queryParam
[
"warehousetype"
].
IsEmpty
()
&&
queryParam
[
"Warehouse"
].
IsEmpty
())
if
(!
queryParam
[
"warehousetype"
].
IsEmpty
()
&&
queryParam
[
"Warehouse"
].
IsEmpty
())
{
{
var
warehousetype
=
queryParam
[
"warehousetype"
].
ToInt
();
var
warehousetype
=
queryParam
[
"warehousetype"
].
ToInt
();
...
@@ -230,6 +240,11 @@ namespace Bailun.DataCenter.Application.Order
...
@@ -230,6 +240,11 @@ namespace Bailun.DataCenter.Application.Order
var
datasource
=
queryParam
[
"datasource"
].
ToString
();
var
datasource
=
queryParam
[
"datasource"
].
ToString
();
query
=
query
.
Where
(
t
=>
t
.
datasource
==
datasource
);
query
=
query
.
Where
(
t
=>
t
.
datasource
==
datasource
);
}
}
if
(!
queryParam
[
"shipstatus"
].
IsEmpty
())
{
var
shipstatus
=
queryParam
[
"shipstatus"
].
ToInt
();
query
=
query
.
Where
(
t
=>
t
.
shipping_status
==
shipstatus
);
}
if
(!
queryParam
[
"seller"
].
IsEmpty
())
if
(!
queryParam
[
"seller"
].
IsEmpty
())
{
{
var
seller
=
queryParam
[
"seller"
].
ToString
();
var
seller
=
queryParam
[
"seller"
].
ToString
();
...
...
trunk/Bailun.DataCenter.Application/Statistic/SkuStatisticAppService.cs
View file @
bc7c674b
...
@@ -14,6 +14,7 @@ using System.Linq.Expressions;
...
@@ -14,6 +14,7 @@ using System.Linq.Expressions;
using
System.Text
;
using
System.Text
;
using
Bailun.DataCenter.Application.Common
;
using
Bailun.DataCenter.Application.Common
;
using
MySql.Data.MySqlClient
;
using
MySql.Data.MySqlClient
;
using
Bailun.DataCenter.Application.BasicInfo
;
namespace
Bailun.DataCenter.Application.Statistic
namespace
Bailun.DataCenter.Application.Statistic
{
{
...
@@ -28,12 +29,15 @@ namespace Bailun.DataCenter.Application.Statistic
...
@@ -28,12 +29,15 @@ namespace Bailun.DataCenter.Application.Statistic
{
{
private
readonly
ISkuStatisticRepository
_skuStatisticRepository
;
private
readonly
ISkuStatisticRepository
_skuStatisticRepository
;
private
readonly
ICommonAppService
_commonAppService
;
private
readonly
ICommonAppService
_commonAppService
;
private
readonly
IWarehouseInfoAppService
_warehouseInfoAppService
;
public
SkuStatisticAppService
(
ISkuStatisticRepository
skuStatisticRepository
,
public
SkuStatisticAppService
(
ISkuStatisticRepository
skuStatisticRepository
,
ICommonAppService
commonAppService
)
ICommonAppService
commonAppService
,
IWarehouseInfoAppService
warehouseInfoAppService
)
{
{
_skuStatisticRepository
=
skuStatisticRepository
;
_skuStatisticRepository
=
skuStatisticRepository
;
_commonAppService
=
commonAppService
;
_commonAppService
=
commonAppService
;
_warehouseInfoAppService
=
warehouseInfoAppService
;
}
}
#
region
获取数据
#
region
获取数据
...
@@ -95,7 +99,7 @@ namespace Bailun.DataCenter.Application.Statistic
...
@@ -95,7 +99,7 @@ namespace Bailun.DataCenter.Application.Statistic
if
(!
queryParam
[
"warehousetype"
].
IsEmpty
()
&&
queryParam
[
"Warehouse"
].
IsEmpty
())
if
(!
queryParam
[
"warehousetype"
].
IsEmpty
()
&&
queryParam
[
"Warehouse"
].
IsEmpty
())
{
{
var
warehousetype
=
queryParam
[
"warehousetype"
].
ToInt
();
var
warehousetype
=
queryParam
[
"warehousetype"
].
ToInt
();
var
data
=
_
commonAppService
.
GetWarehouseList
().
Where
(
d
=>
d
.
WH_Type
.
ToInt
()
==
warehousetype
).
Select
(
d
=>
d
.
WareCode
).
ToList
();
var
data
=
_
warehouseInfoAppService
.
GetList
(
new
{
waretype
=
warehousetype
}.
ToJson
()
).
Select
(
d
=>
d
.
WareCode
).
ToList
();
query
=
query
.
Where
(
d
=>
data
.
Contains
(
d
.
warehouse_code
));
query
=
query
.
Where
(
d
=>
data
.
Contains
(
d
.
warehouse_code
));
}
}
}
}
...
@@ -140,7 +144,7 @@ namespace Bailun.DataCenter.Application.Statistic
...
@@ -140,7 +144,7 @@ namespace Bailun.DataCenter.Application.Statistic
if
(!
queryParam
[
"warehousetype"
].
IsEmpty
()
&&
queryParam
[
"Warehouse"
].
IsEmpty
())
if
(!
queryParam
[
"warehousetype"
].
IsEmpty
()
&&
queryParam
[
"Warehouse"
].
IsEmpty
())
{
{
var
warehousetype
=
queryParam
[
"warehousetype"
].
ToInt
();
var
warehousetype
=
queryParam
[
"warehousetype"
].
ToInt
();
var
data
=
_
commonAppService
.
GetWarehouseList
().
Where
(
d
=>
d
.
WH_Type
.
ToInt
()
==
warehousetype
).
Select
(
d
=>
d
.
WareCode
).
ToList
();
var
data
=
_
warehouseInfoAppService
.
GetList
(
new
{
waretype
=
warehousetype
}.
ToJson
()
).
Select
(
d
=>
d
.
WareCode
).
ToList
();
strsql
.
AppendFormat
(
" and warehouse_code in('{0}')"
,
string
.
Join
(
"','"
,
data
));
strsql
.
AppendFormat
(
" and warehouse_code in('{0}')"
,
string
.
Join
(
"','"
,
data
));
}
}
}
}
...
...
trunk/Bailun.DataCenter.Tasks/Jobs/SkuStatistics/SkuStatisticsJob.cs
View file @
bc7c674b
...
@@ -41,10 +41,34 @@ namespace Bailun.DataCenter.Tasks.Jobs.SkuStatistics
...
@@ -41,10 +41,34 @@ namespace Bailun.DataCenter.Tasks.Jobs.SkuStatistics
string
skuNumber
=
string
.
Empty
;
string
skuNumber
=
string
.
Empty
;
do
do
{
{
List
<
System
.
Threading
.
Tasks
.
Task
>
tasklist
=
new
List
<
System
.
Threading
.
Tasks
.
Task
>();
skuNumber
=
RedisOprate
.
Set_Pop
<
string
>(
"SkuSet"
);
skuNumber
=
RedisOprate
.
Set_Pop
<
string
>(
"SkuSet"
);
if
(!
string
.
IsNullOrEmpty
(
skuNumber
))
if
(!
string
.
IsNullOrEmpty
(
skuNumber
))
{
{
tasklist
.
Add
(
System
.
Threading
.
Tasks
.
Task
.
Factory
.
StartNew
(()
=>
{
SkuStatistics
(
skuNumber
);
}));
}
skuNumber
=
RedisOprate
.
Set_Pop
<
string
>(
"SkuSet"
);
if
(!
string
.
IsNullOrEmpty
(
skuNumber
))
{
tasklist
.
Add
(
System
.
Threading
.
Tasks
.
Task
.
Factory
.
StartNew
(()
=>
{
SkuStatistics
(
skuNumber
);
}));
}
skuNumber
=
RedisOprate
.
Set_Pop
<
string
>(
"SkuSet"
);
if
(!
string
.
IsNullOrEmpty
(
skuNumber
))
{
tasklist
.
Add
(
System
.
Threading
.
Tasks
.
Task
.
Factory
.
StartNew
(()
=>
{
SkuStatistics
(
skuNumber
);
SkuStatistics
(
skuNumber
);
}));
}
if
(
tasklist
.
Count
>
0
)
{
System
.
Threading
.
Tasks
.
Task
.
WaitAll
(
tasklist
.
ToArray
());
}
}
}
}
while
(!
string
.
IsNullOrEmpty
(
skuNumber
));
while
(!
string
.
IsNullOrEmpty
(
skuNumber
));
...
@@ -228,7 +252,7 @@ namespace Bailun.DataCenter.Tasks.Jobs.SkuStatistics
...
@@ -228,7 +252,7 @@ namespace Bailun.DataCenter.Tasks.Jobs.SkuStatistics
}
}
//已发货总量
//已发货总量
dssList
[
dssIndex
].
shipped_totalquantity
+=
item
.
shipped_quantity
;
dssList
[
dssIndex
].
shipped_totalquantity
+=
item
.
shipped_quantity
;
//
已
发货总量
//
未
发货总量
dssList
[
dssIndex
].
notshipped_totalquantity
+=
item
.
notshipped_quantity
;
dssList
[
dssIndex
].
notshipped_totalquantity
+=
item
.
notshipped_quantity
;
//已到货总量
//已到货总量
dssList
[
dssIndex
].
arrived_totalquantity
+=
item
.
arrived_quantity
;
dssList
[
dssIndex
].
arrived_totalquantity
+=
item
.
arrived_quantity
;
...
...
trunk/Bailun.DataCenter.Tasks/Jobs/WarehouseStatistics/WarehouseStatisticsJob.cs
View file @
bc7c674b
...
@@ -148,7 +148,7 @@ namespace Bailun.DataCenter.Tasks.Jobs.WarehouseStatistics
...
@@ -148,7 +148,7 @@ namespace Bailun.DataCenter.Tasks.Jobs.WarehouseStatistics
}
}
catch
(
Exception
)
catch
(
Exception
)
{
{
log
.
ErrorFormat
(
"仓库实时统计错误:仓库编码:{
1},仓库名称:{2
}"
,
item
.
warehouse_code
,
item
.
warehouse_name
);
log
.
ErrorFormat
(
"仓库实时统计错误:仓库编码:{
0},仓库名称:{1
}"
,
item
.
warehouse_code
,
item
.
warehouse_name
);
}
}
string
warehousecode
=
item
.
warehouse_code
;
string
warehousecode
=
item
.
warehouse_code
;
...
...
trunk/Bailun.DataCenter.Tasks/Program.cs
View file @
bc7c674b
...
@@ -13,6 +13,7 @@ using Bailun.DataCenter.Tasks.Jobs.SkuFbaOrder;
...
@@ -13,6 +13,7 @@ using Bailun.DataCenter.Tasks.Jobs.SkuFbaOrder;
using
Bailun.DataCenter.Tasks.Jobs.FbaSkuStock
;
using
Bailun.DataCenter.Tasks.Jobs.FbaSkuStock
;
using
Bailun.DataCenter.Common.Redis
;
using
Bailun.DataCenter.Common.Redis
;
using
Bailun.DataCenter.Tasks.Jobs.MaterialStock
;
using
Bailun.DataCenter.Tasks.Jobs.MaterialStock
;
using
System.Collections.Generic
;
namespace
Bailun.DataCenter.Tasks
namespace
Bailun.DataCenter.Tasks
{
{
...
@@ -147,10 +148,34 @@ namespace Bailun.DataCenter.Tasks
...
@@ -147,10 +148,34 @@ namespace Bailun.DataCenter.Tasks
//string skuNumber = string.Empty;
//string skuNumber = string.Empty;
//do
//do
//{
//{
// List<System.Threading.Tasks.Task> tasklist = new List<System.Threading.Tasks.Task>();
// skuNumber = RedisOprate.Set_Pop<string>("SkuSet");
// skuNumber = RedisOprate.Set_Pop<string>("SkuSet");
// if (!string.IsNullOrEmpty(skuNumber))
// if (!string.IsNullOrEmpty(skuNumber))
// {
// {
// tasklist.Add(System.Threading.Tasks.Task.Factory.StartNew(() =>
// {
// ss.SkuStatistics(skuNumber);
// }));
// }
// skuNumber = RedisOprate.Set_Pop<string>("SkuSet");
// if (!string.IsNullOrEmpty(skuNumber))
// {
// tasklist.Add(System.Threading.Tasks.Task.Factory.StartNew(() =>
// {
// ss.SkuStatistics(skuNumber);
// ss.SkuStatistics(skuNumber);
// }));
// }
// skuNumber = RedisOprate.Set_Pop<string>("SkuSet");
// if (!string.IsNullOrEmpty(skuNumber))
// {
// tasklist.Add(System.Threading.Tasks.Task.Factory.StartNew(() =>
// {
// ss.SkuStatistics(skuNumber);
// }));
// }
// if (tasklist.Count > 0)
// {
// System.Threading.Tasks.Task.WaitAll(tasklist.ToArray());
// }
// }
//}
//}
//while (!string.IsNullOrEmpty(skuNumber));
//while (!string.IsNullOrEmpty(skuNumber));
...
...
trunk/Bailun.DataCenter.Web/Areas/Order/Views/SkuOrder/Index.cshtml
View file @
bc7c674b
...
@@ -24,11 +24,27 @@
...
@@ -24,11 +24,27 @@
<td>
<td>
<div id="Warehouse" type="select" style="width: 200px;" class="ui-select"></div>
<div id="Warehouse" type="select" style="width: 200px;" class="ui-select"></div>
</td>
</td>
<td>
<label class="lb-title">
订单状态:
</label>
</td>
<td>
<div id="status" type="select" class="ui-select" style="width: 100px;"></div>
</td>
<td>
<label class="lb-title">
发货状态:
</label>
</td>
<td>
<div id="shipstatus" type="select" class="ui-select" style="width: 100px;"></div>
</td>
<td style="padding-center: 3px;">
<td style="padding-center: 3px;">
<input id="txt_Sku" type="text" class="form-control" placeholder="请输入要查询的Sku编码" style="width: 200px;"/>
<input id="txt_Sku" type="text" class="form-control" placeholder="请输入要查询的Sku编码" style="width: 200px;"
/>
</td>
</td>
<td style="padding-center: 3px;">
<td style="padding-center: 3px;">
<input id="txt_Onumber" type="text" class="form-control" placeholder="请输入要查询的订单编号" style="width: 200px;"/>
<input id="txt_Onumber" type="text" class="form-control" placeholder="请输入要查询的订单编号" style="width: 200px;"
/>
</td>
</td>
<td style="padding-center: 5px;">
<td style="padding-center: 5px;">
<a id="btn_Search" class="btn btn-primary"><i class="fa fa-search"></i>查询</a>
<a id="btn_Search" class="btn btn-primary"><i class="fa fa-search"></i>查询</a>
...
@@ -52,6 +68,50 @@
...
@@ -52,6 +68,50 @@
<script>
<script>
var warehouseList = [];
var warehouseList = [];
$(function () {
$(function () {
$("#status").ComboBox({
//url: "/ProductManage/Product/GetDeliverId",
id: "Id",
description: "全部",
text: "Name",
height: "200px",
allowSearch: false,
data: [{ Id: '1', Name: '进行中' }, { Id: '2', Name: '订单完成' }, { Id: '3', Name: '订单取消' }]
});
$("#shipstatus").ComboBox({
//url: "/ProductManage/Product/GetDeliverId",
id: "Id",
description: "全部",
text: "Name",
height: "200px",
allowSearch: false,
data: [{ Id: '1', Name: '未发货' }, { Id: '2', Name: '已发货' }, { Id: '3', Name: '部分发货' }]
});
$("#sel_warehouse_type").ComboBox({
//url: "/ProductManage/Product/GetDeliverId",
id: "Id",
description: "全部",
text: "TypeName",
height: "200px",
allowSearch: false,
data: [{ Id: '1', TypeName: '国内仓' }, { Id: '2', TypeName: '海外仓' }, { Id: '3', TypeName: 'fba仓' }, { Id: '4', TypeName: '第三方仓库' }]
});
//仓库
$("#Warehouse").ComboBox({
url: "../../Statistic/SkuStatistic/GetWarehouse",
description: "==请选择仓库==",
id: "WareCode",
text: "WH_Title",
allowSearch: true,
height: "200px",
successCallback: function (data) {
warehouseList = data;
//$("#queryWarehouseId").ComboBoxSetValue(initWareCode);
}
});
GetGrid();
GetGrid();
InitialPage();
InitialPage();
...
@@ -127,15 +187,40 @@
...
@@ -127,15 +187,40 @@
}
}
function GetPostData() {
function GetPostData() {
debugger;
var sku = request('sku');
var warehousecode = request("warehousecode");
var shipstatus = request("shipstatus");
var status = request("status");
var datasource = request("datasource");
if (sku) {
$("#txt_Sku").val(sku);
}
if (warehousecode) {
$("#Warehouse").ComboBoxSetValue(warehousecode);
}
if (status) {
$("#status").ComboBoxSetValue(status);
}
if (shipstatus) {
$("#shipstatus").ComboBoxSetValue(shipstatus);
}
if (sku || shipstatus || warehousecode || datasource || status) {
$(".titlePanel").hide();
}
var queryJson = {
var queryJson = {
Sku: $("#txt_Sku").val(),
Sku: $("#txt_Sku").val(),
Warehouse: $("#Warehouse").attr("data-value"),
Warehouse: $("#Warehouse").attr("data-value"),
Onumber: $("#txt_Onumber").val(),
Onumber: $("#txt_Onumber").val(),
datasource: "HQOMS",
seller: $("#seller").attr("data-value"),
seller: $("#seller").attr("data-value"),
startpaytime: $("#StartTime").val(),
startpaytime: $("#StartTime").val(),
endpaytime: $("#EndTime").val(),
endpaytime: $("#EndTime").val(),
warehousetype: $("#sel_warehouse_type").attr("data-value")
warehousetype: $("#sel_warehouse_type").attr("data-value"),
status: $("#status").attr("data-value"),
shipstatus: $("#shipstatus").attr("data-value")
}
if (datasource) {
queryJson.datasource = datasource;
}
}
return JSON.stringify(queryJson);
return JSON.stringify(queryJson);
}
}
...
@@ -158,10 +243,20 @@
...
@@ -158,10 +243,20 @@
autowidth: true,
autowidth: true,
height: $(window).height() - $('#gridTable').offset().top - gridHeight,
height: $(window).height() - $('#gridTable').offset().top - gridHeight,
url: "../../Order/SkuOrder/GetPageListJson",
url: "../../Order/SkuOrder/GetPageListJson",
postData: {
queryJson: GetPostData()
},
datatype: "json",
datatype: "json",
colModel: [
colModel: [
{ label: '自增编号', name: 'Id', index: 'Id', align: 'center', sortable: true,
hidden:
true },
{ label: '自增编号', name: 'Id', index: 'Id', align: 'center', sortable: true,
hidden:
true },
{ label: '流水号', name: 'so_number', index: 'so_number', align: 'center', sortable: false },
{ label: '流水号', name: 'so_number', index: 'so_number', align: 'center', sortable: false },
{
label: '订单编号', name: 'o_number', index: 'o_number', align: 'center', sortable: false,
formatter: function (cellvalue, options, rowObject) {
return '<a style="color: rgb(51, 122, 183);cursor:pointer" onclick="navigateToOrder(\'' + cellvalue + '\',\'' + rowObject.datasource + '\')">' + cellvalue + '</a>';
}
},
{ label: '外部订单编号', name: 'o_number_external', index: 'o_number_external', align: 'center', sortable: false },
{ label: 'sku编码', name: 's_number', index: 's_number', align: 'center', sortable: false },
{ label: 'sku编码', name: 's_number', index: 's_number', align: 'center', sortable: false },
{ label: '刊登sku编码', name: 's_number_publish', index: 's_number_publish', align: 'center', sortable: false },
{ label: '刊登sku编码', name: 's_number_publish', index: 's_number_publish', align: 'center', sortable: false },
{ label: '主图', name: 'S_IMAGE_MAIN', index: 'S_IMAGE_MAIN', align: 'center', sortable: false, formatter: displayImgFormatter },
{ label: '主图', name: 'S_IMAGE_MAIN', index: 'S_IMAGE_MAIN', align: 'center', sortable: false, formatter: displayImgFormatter },
...
@@ -186,17 +281,8 @@
...
@@ -186,17 +281,8 @@
} else {
} else {
return '否';
return '否';
}
}
//switch (cellvalue) {
}
// case 0:
},
// return '否';
// case 1:
// return '是';
// default:
// return '否';
//}
}},
{ label: '订单编号', name: 'o_number', index: 'o_number', align: 'center', sortable: false },
{ label: '外部订单编号', name: 'o_number_external', index: 'o_number_external', align: 'center', sortable: false },
{
{
label: '订单状态', name: 'state', index: 'state', align: 'center', sortable: true, formatter: function (cellvalue, options, rowObject) {
label: '订单状态', name: 'state', index: 'state', align: 'center', sortable: true, formatter: function (cellvalue, options, rowObject) {
switch (cellvalue) {
switch (cellvalue) {
...
@@ -219,13 +305,15 @@
...
@@ -219,13 +305,15 @@
return '未发货';
return '未发货';
case 2:
case 2:
return '已发货';
return '已发货';
case 3:
return '部分发货';
default:
default:
return '未发货';
return '未发货';
}
}
}
}
},
},
{ label: '创建时间', name: 'createtime', index: 'createtime', align: 'center', sortable: true },
{ label: '创建时间', name: 'createtime', index: 'createtime', align: 'center', sortable: true },
{ label: '更新时间', name: 'updatetime', index: 'updatetime', align: 'center', sortable: true }
,
{ label: '更新时间', name: 'updatetime', index: 'updatetime', align: 'center', sortable: true }
],
],
rowNum: 30,
rowNum: 30,
rowList: [30, 50, 100],
rowList: [30, 50, 100],
...
@@ -253,4 +341,13 @@
...
@@ -253,4 +341,13 @@
var imgUrlList = cellvalue.split(',');
var imgUrlList = cellvalue.split(',');
return "<a target='_blank' href='/ProductManage/Product/FrontInfo/" + rowObject.Id + "' href1='" + imgUrlList[0] + "' class='tooltip1'><img src='" + imgUrlList[0] + "' title='" + rowObject['Title'] + "' width='50' height='50'/></a>";
return "<a target='_blank' href='/ProductManage/Product/FrontInfo/" + rowObject.Id + "' href1='" + imgUrlList[0] + "' class='tooltip1'><img src='" + imgUrlList[0] + "' title='" + rowObject['Title'] + "' width='50' height='50'/></a>";
};
};
//跳转到采购系统
var navigateToOrder = function (orderno, datasource) {
var url = 'http://tj.oa.com/OrderList/Order/OrderIndex?orderno=' + orderno;
if (datasource.toLowerCase() == "fba") {
url = "";
}
window.open(url, '_blank');
}
</script>
</script>
\ No newline at end of file
trunk/Bailun.DataCenter.Web/Areas/Statistic/Views/SkuActive/Index.cshtml
View file @
bc7c674b
...
@@ -123,7 +123,12 @@
...
@@ -123,7 +123,12 @@
}
}
},
},
{ label: '调拨在途金额', name: 'allot_transit_money', index: 'allot_transit_money', align: 'center', sortable: true },
{ label: '调拨在途金额', name: 'allot_transit_money', index: 'allot_transit_money', align: 'center', sortable: true },
{ label: '待发货数量', name: 'plan_shipped', index: 'plan_shipped', align: 'center', sortable: true },
{
label: '待发货数量', name: 'plan_shipped', index: 'plan_shipped', align: 'center', sortable: true,
formatter: function (cellvalue, options, rowObject) {
return '<a style="color: rgb(51, 122, 183);cursor:pointer" onclick="navigateToDetail(\'' + rowObject.s_number + '\',1,4,\'订单明细\')">' + cellvalue + '</a>';
}
},
{ label: '缺货数量', name: 'out_stock', index: 'out_stock', align: 'center', sortable: true },
{ label: '缺货数量', name: 'out_stock', index: 'out_stock', align: 'center', sortable: true },
{ label: '昨日总销量', name: 'oneday_sales', index: 'oneday_sales', align: 'center', sortable: true },
{ label: '昨日总销量', name: 'oneday_sales', index: 'oneday_sales', align: 'center', sortable: true },
{ label: '昨日总销量额', name: 'oneday_salesmoney', index: 'oneday_salesmoney', align: 'center', sortable: true },
{ label: '昨日总销量额', name: 'oneday_salesmoney', index: 'oneday_salesmoney', align: 'center', sortable: true },
...
@@ -174,7 +179,7 @@
...
@@ -174,7 +179,7 @@
//{ label: 'fba库存数量', name: 'fba_stock_quantity', index: 'fba_stock_quantity', align: 'center', sortable: true },
//{ label: 'fba库存数量', name: 'fba_stock_quantity', index: 'fba_stock_quantity', align: 'center', sortable: true },
{ label: '采购在途数量', name: 'purchase_transit_quantity', index: 'purchase_transit_quantity', align: 'center', sortable: true },
{ label: '采购在途数量', name: 'purchase_transit_quantity', index: 'purchase_transit_quantity', align: 'center', sortable: true },
{ label: '调拨在途数量', name: 'allot_transit_quantity', index: 'allot_transit_quantity', align: 'center', sortable: true },
{ label: '调拨在途数量', name: 'allot_transit_quantity', index: 'allot_transit_quantity', align: 'center', sortable: true },
{
label: '待发货数量', name: 'plan_shipped', index: 'plan_shipped', align: 'center', sortable: true
},
{
label: '待发货数量', name: 'plan_shipped', index: 'plan_shipped', align: 'center', sortable: true
},
{ label: '缺货数量', name: 'out_stock', index: 'out_stock', align: 'center', sortable: true },
{ label: '缺货数量', name: 'out_stock', index: 'out_stock', align: 'center', sortable: true },
{ label: '近一日销量', name: 'oneday_sales', index: 'oneday_sales', align: 'center', sortable: true },
{ label: '近一日销量', name: 'oneday_sales', index: 'oneday_sales', align: 'center', sortable: true },
{ label: '近七日销量', name: 'sevendays_sales', index: 'sevendays_sales', align: 'center', sortable: true },
{ label: '近七日销量', name: 'sevendays_sales', index: 'sevendays_sales', align: 'center', sortable: true },
...
@@ -451,6 +456,10 @@
...
@@ -451,6 +456,10 @@
else if (type === 3) {
else if (type === 3) {
url = '/Statistic/SkuStatistic/skuwarehouseIndex?sku=' + sku;
url = '/Statistic/SkuStatistic/skuwarehouseIndex?sku=' + sku;
}
}
//销售订单
else if (type === 4) {
url = '/Order/SkuOrder/Index?sku=' + sku + '&status=' + status + '&shipstatus=1';
}
top.tablist.newTab({
top.tablist.newTab({
id: "sku_statistics",
id: "sku_statistics",
title: title,
title: title,
...
...
trunk/Bailun.DataCenter.Web/Areas/Statistic/Views/SkuStatistic/skuwarehouseIndex.cshtml
View file @
bc7c674b
...
@@ -33,9 +33,9 @@
...
@@ -33,9 +33,9 @@
<td style="padding-left: 5px;">
<td style="padding-left: 5px;">
<a id="btn_Search" class="btn btn-primary"><i class="fa fa-search"></i>查询</a>
<a id="btn_Search" class="btn btn-primary"><i class="fa fa-search"></i>查询</a>
</td>
</td>
<td style="padding-left: 5px;">
@*
<td style="padding-left: 5px;">
<label style="color:red">半成品仓库数据单独统计。没有筛选半成品仓库时,汇总不算上半成品仓库数据</label>
<label style="color:red">半成品仓库数据单独统计。没有筛选半成品仓库时,汇总不算上半成品仓库数据</label>
</td>
</td>
*@
</tr>
</tr>
</table>
</table>
</div>
</div>
...
@@ -59,17 +59,17 @@
...
@@ -59,17 +59,17 @@
$(function () {
$(function () {
//仓库
//仓库
$("#Warehouse").ComboBox({
$("#Warehouse").ComboBox({
url: "../../Statistic/
SkuStatistic/GetWarehouse
",
url: "../../Statistic/
WarehouseActive/GetWarehouseList
",
description: "
==请选择仓库==
",
description: "
全部仓库
",
id: "WareCode",
id: "WareCode",
text: "W
H_Titl
e",
text: "W
areNam
e",
allowSearch: true,
allowSearch: true,
height: "200px",
height: "200px",
successCallback: function (data) {
successCallback: function (data) {
warehouseList = data;
warehouseList = data;
//$("#queryWarehouseId").ComboBoxSetValue(initWareCode);
}
}
});
});
GetGrid();
GetGrid();
InitialPage();
InitialPage();
...
@@ -103,7 +103,7 @@
...
@@ -103,7 +103,7 @@
text: "TypeName",
text: "TypeName",
height: "200px",
height: "200px",
allowSearch: false,
allowSearch: false,
data: [{ Id: '1', TypeName: '
国内仓' }, { Id: '2', TypeName: '海外仓' }, { Id: '3', TypeName: 'fba仓' }, { Id: '4', TypeName: '第三方仓库' }, { Id: '99', TypeName: '半成品仓库
' }]
data: [{ Id: '1', TypeName: '
成品仓' }, { Id: '2', TypeName: '海外仓' }, { Id: '3', TypeName: 'fba仓' }, { Id: '4', TypeName: '第三方仓库' }, { Id: '5', TypeName: '半成品仓
' }]
});
});
$("#sel_warehouse_type").change(function () {
$("#sel_warehouse_type").change(function () {
...
@@ -111,22 +111,23 @@
...
@@ -111,22 +111,23 @@
//筛选仓库数据
//筛选仓库数据
var typeId = $(this).attr('data-value');
var typeId = $(this).attr('data-value');
var result = [];
var result = [];
if (typeId == 3) {
$(".fbadisplay").show();
} else {
$(".fbadisplay").hide();
$("#selcountry").ResetComboBox("==请选择国家==");
$("#selaccount").ResetComboBox("=选择账号=");
}
if (!typeId) {
if (!typeId) {
result = warehouseList;
result = warehouseList;
} else {
} else
if (typeId==99) {
result.push({ "WareCode": "MJYSMR", "WH_Title": "阳山美容仓" }, { "WareCode": "MJYS", "WH_Title": "阳山仓" });
} else {
result = getWarehouseByType(typeId);
result = getWarehouseByType(typeId);
}
//result = getWarehouseByType(typeId);
}
$("#Warehouse").ComboBox({
$("#Warehouse").ComboBox({
//url: "/PurchaseAdvice/PurchaseMonitor/GetWarehouseList",
//url: "/PurchaseAdvice/PurchaseMonitor/GetWarehouseList",
id: "WareCode",
id: "WareCode",
description: "全部仓库",
description: "全部仓库",
text: "W
H_Titl
e",
text: "W
areNam
e",
height: "200px",
height: "200px",
async: true,
async: true,
allowSearch: true,
allowSearch: true,
...
@@ -140,7 +141,7 @@
...
@@ -140,7 +141,7 @@
var result = [];
var result = [];
if (warehouseList) {
if (warehouseList) {
$.each(warehouseList, function (index, value) {
$.each(warehouseList, function (index, value) {
if (value.W
H_
Type === parseInt(typeid)) {
if (value.W
are
Type === parseInt(typeid)) {
result.push(value);
result.push(value);
}
}
});
});
...
@@ -165,7 +166,7 @@
...
@@ -165,7 +166,7 @@
{
{
label: 'sku编码', name: 's_number', index: 's_number', align: 'left', sortable: false,
label: 'sku编码', name: 's_number', index: 's_number', align: 'left', sortable: false,
formatter: function (cellvalue, options, rowObject) {
formatter: function (cellvalue, options, rowObject) {
return '<a style="color: rgb(51, 122, 183);cursor:pointer" onclick="navigateToDetail(\'' + cellvalue + '\')">' + cellvalue + '</a>';
return '<a style="color: rgb(51, 122, 183);cursor:pointer" onclick="navigateTo
SkuMs
Detail(\'' + cellvalue + '\')">' + cellvalue + '</a>';
}
}
},
},
{ label: '所在仓库', name: 'warehouse_name', index: 'warehouse_name', align: 'left', sortable: false },
{ label: '所在仓库', name: 'warehouse_name', index: 'warehouse_name', align: 'left', sortable: false },
...
@@ -175,98 +176,113 @@
...
@@ -175,98 +176,113 @@
{ label: '中文标题', name: 's_title_chinese', index: 's_title_chinese', align: 'left', sortable: false },
{ label: '中文标题', name: 's_title_chinese', index: 's_title_chinese', align: 'left', sortable: false },
{ label: '库存总数量', name: 'stock_quantity', index: 'stock_quantity', align: 'center', sortable: true },
{ label: '库存总数量', name: 'stock_quantity', index: 'stock_quantity', align: 'center', sortable: true },
{ label: '库存总金额', name: 'stock_money', index: 'stock_quantity', align: 'center', sortable: true },
{ label: '库存总金额', name: 'stock_money', index: 'stock_quantity', align: 'center', sortable: true },
{ label: '采购在途数量', name: 'purchase_transit_quantity', index: 'purchase_transit_quantity', align: 'center', sortable: true },
{ label: '采购在途金额', name: 'purchase_transit_money', index: 'purchase_transit_money', align: 'center', sortable: true },
{ label: '调拨在途数量', name: 'allot_transit_quantity', index: 'allot_transit_quantity', align: 'center', sortable: true },
{ label: '调拨在途金额', name: 'allot_transit_money', index: 'allot_transit_money', align: 'center', sortable: true },
{ label: '待发货数量', name: 'plan_shipped', index: 'plan_shipped', align: 'center', sortable: true },
{ label: '缺货数量', name: 'out_stock', index: 'out_stock', align: 'center', sortable: true },
{ label: '昨日总销量', name: 'oneday_sales', index: 'oneday_sales', align: 'left', sortable: true },
{ label: '昨日总销量额', name: 'oneday_salesmoney', index: 'oneday_salesmoney', align: 'left', sortable: true },
{ label: '七天总销量', name: 'sevendays_sales', index: 'sevendays_sales', align: 'left', sortable: true },
{ label: '十四天总销量', name: 'fourteendays_sales', index: 'fourteendays_sales', align: 'left', sortable: true },
{ label: '三十天总销量', name: 'thirtydays_sales', index: 'thirtydays_sales', align: 'left', sortable: true },
];
var waretype=$("#sel_warehouse_type").attr("data-value");
if(waretype==99){
columnArray=[
{ label: '自增编号', name: 'Id', index: 'Id', align: 'left', sortable: false, hidden: true },
{
label: 'sku编码', name: 's_number', index: 's_number', align: 'left', sortable: false,
formatter: function (cellvalue, options, rowObject) {
return '<a style="color: rgb(51, 122, 183);cursor:pointer" onclick="navigateToDetail(\'' + cellvalue + '\')">' + cellvalue + '</a>';
}
},
{ label: '所在仓库', name: 'warehouse_name', index: 'warehouse_name', align: 'left', sortable: false },
{ label: '英文标题', name: 's_title', index: 's_title',align: 'left', sortable: false },
{
label: '库存总数量', name: 'stock_quantity', index: 'stock_quantity', align: 'center', sortable: true},
{
label: '采购总数量', name: 'purchase_totalquantity', index: 'purchase_totalquantity', align: 'center', sortable: true,
formatter: function (cellvalue, options, rowObject) {
if (cellvalue < 0) {
return 0;
} else {
return cellvalue;
}
}
},
{
{
label: '
销售总数量', name: 'order_totalquantity', index: 'order_total
quantity', align: 'center', sortable: true,
label: '
采购在途数量', name: 'purchase_transit_quantity', index: 'purchase_transit_
quantity', align: 'center', sortable: true,
formatter: function (cellvalue, options, rowObject) {
formatter: function (cellvalue, options, rowObject) {
if (cellvalue < 0) {
return '<a style="color: rgb(51, 122, 183);cursor:pointer" onclick="navigateToDetail(\'' + rowObject.s_number + '\',\'' + rowObject.warehouse_code + '\',1,1,\'采购明细\')">' + cellvalue + '</a>';
return 0;
} else {
return cellvalue;
}
}
},
{
label: '昨日总销量', name: 'oneday_sales', index: 'oneday_sales', align: 'left', sortable: true,
formatter: function (cellvalue, options, rowObject) {
if (cellvalue < 0) {
return 0;
} else {
return cellvalue;
}
}
}
},
},
{ label: '采购在途金额', name: 'purchase_transit_money', index: 'purchase_transit_money', align: 'center', sortable: true },
{
{
label: '
七天总销量', name: 'sevendays_sales', index: 'sevendays_sales', align: 'left
', sortable: true,
label: '
调拨在途数量', name: 'allot_transit_quantity', index: 'allot_transit_quantity', align: 'center
', sortable: true,
formatter: function (cellvalue, options, rowObject) {
formatter: function (cellvalue, options, rowObject) {
if (cellvalue < 0) {
return '<a style="color: rgb(51, 122, 183);cursor:pointer" onclick="navigateToDetail(\'' + rowObject.s_number + '\',\'' + rowObject.warehouse_code + '\',1,2,\'调拨明细\')">' + cellvalue + '</a>';
return 0;
} else {
return cellvalue;
}
}
}
},
},
{ label: '调拨在途金额', name: 'allot_transit_money', index: 'allot_transit_money', align: 'center', sortable: true },
{
{
label: '
十四天总销量', name: 'fourteendays_sales', index: 'fourteendays_sales', align: 'left
', sortable: true,
label: '
待发货数量', name: 'plan_shipped', index: 'plan_shipped', align: 'center
', sortable: true,
formatter: function (cellvalue, options, rowObject) {
formatter: function (cellvalue, options, rowObject) {
if (cellvalue < 0) {
return '<a style="color: rgb(51, 122, 183);cursor:pointer" onclick="navigateToDetail(\'' + rowObject.s_number + '\',\'' + rowObject.warehouse_code + '\',1,4,\'订单明细\')">' + cellvalue + '</a>';
return 0;
} else {
return cellvalue;
}
}
}
},
},
{
{ label: '缺货数量', name: 'out_stock', index: 'out_stock', align: 'center', sortable: true },
label: '三十天总销量', name: 'thirtydays_sales', index: 'thirtydays_sales', align: 'left', sortable: true,
{ label: '昨日总销量', name: 'oneday_sales', index: 'oneday_sales', align: 'left', sortable: true },
formatter: function (cellvalue, options, rowObject) {
{ label: '昨日总销量额', name: 'oneday_salesmoney', index: 'oneday_salesmoney', align: 'left', sortable: true },
if (cellvalue < 0) {
{ label: '七天总销量', name: 'sevendays_sales', index: 'sevendays_sales', align: 'left', sortable: true },
return 0;
{ label: '十四天总销量', name: 'fourteendays_sales', index: 'fourteendays_sales', align: 'left', sortable: true },
} else {
{ label: '三十天总销量', name: 'thirtydays_sales', index: 'thirtydays_sales', align: 'left', sortable: true },
return cellvalue;
}
}
}
];
];
}
//var waretype=$("#sel_warehouse_type").attr("data-value");
//if(waretype==99){
// columnArray=[
// { label: '自增编号', name: 'Id', index: 'Id', align: 'left', sortable: false, hidden: true },
// {
// label: 'sku编码', name: 's_number', index: 's_number', align: 'left', sortable: false,
// formatter: function (cellvalue, options, rowObject) {
// return '<a style="color: rgb(51, 122, 183);cursor:pointer" onclick="navigateToDetail(\'' + cellvalue + '\')">' + cellvalue + '</a>';
// }
// },
// { label: '所在仓库', name: 'warehouse_name', index: 'warehouse_name', align: 'left', sortable: false },
// { label: '英文标题', name: 's_title', index: 's_title',align: 'left', sortable: false },
// {
// label: '库存总数量', name: 'stock_quantity', index: 'stock_quantity', align: 'center', sortable: true},
// {
// label: '采购总数量', name: 'purchase_totalquantity', index: 'purchase_totalquantity', align: 'center', sortable: true,
// formatter: function (cellvalue, options, rowObject) {
// if (cellvalue < 0) {
// return 0;
// } else {
// return cellvalue;
// }
// }
// },
// {
// label: '销售总数量', name: 'order_totalquantity', index: 'order_totalquantity', align: 'center', sortable: true,
// formatter: function (cellvalue, options, rowObject) {
// if (cellvalue < 0) {
// return 0;
// } else {
// return cellvalue;
// }
// }
// },
// {
// label: '昨日总销量', name: 'oneday_sales', index: 'oneday_sales', align: 'left', sortable: true,
// formatter: function (cellvalue, options, rowObject) {
// if (cellvalue < 0) {
// return 0;
// } else {
// return cellvalue;
// }
// }
// },
// {
// label: '七天总销量', name: 'sevendays_sales', index: 'sevendays_sales', align: 'left', sortable: true,
// formatter: function (cellvalue, options, rowObject) {
// if (cellvalue < 0) {
// return 0;
// } else {
// return cellvalue;
// }
// }
// },
// {
// label: '十四天总销量', name: 'fourteendays_sales', index: 'fourteendays_sales', align: 'left', sortable: true,
// formatter: function (cellvalue, options, rowObject) {
// if (cellvalue < 0) {
// return 0;
// } else {
// return cellvalue;
// }
// }
// },
// {
// label: '三十天总销量', name: 'thirtydays_sales', index: 'thirtydays_sales', align: 'left', sortable: true,
// formatter: function (cellvalue, options, rowObject) {
// if (cellvalue < 0) {
// return 0;
// } else {
// return cellvalue;
// }
// }
// }
// ];
//}
var url = "../../Statistic/SkuStatistic/GetPageListJson";
var url = "../../Statistic/SkuStatistic/GetPageListJson";
if (waretype == 99) {
//
if (waretype == 99) {
url = "../../Statistic/MaterialStatistic/GetPageListJson";
//
url = "../../Statistic/MaterialStatistic/GetPageListJson";
}
//
}
var selectedRowIndex = 0;
var selectedRowIndex = 0;
var $gridTable = $('#gridTable');
var $gridTable = $('#gridTable');
$gridTable.jqGrid({
$gridTable.jqGrid({
...
@@ -345,11 +361,11 @@
...
@@ -345,11 +361,11 @@
"thirtydays_sales": 0
"thirtydays_sales": 0
};
};
if (total > 0) {
if (total > 0) {
var waretype = $("#sel_warehouse_type").attr("data-value");
//
var waretype = $("#sel_warehouse_type").attr("data-value");
var url = "../../Statistic/SkuStatistic/SumSkuStatistic";
var url = "../../Statistic/SkuStatistic/SumSkuStatistic";
if (waretype == 99) {
//
if (waretype == 99) {
url = "../../Statistic/MaterialStatistic/SumSkuStatistic";
//
url = "../../Statistic/MaterialStatistic/SumSkuStatistic";
}
//
}
$.SetForm({
$.SetForm({
url:url,
url:url,
//type: 'post',
//type: 'post',
...
@@ -383,10 +399,32 @@
...
@@ -383,10 +399,32 @@
}
}
var navigateToDetail = function (sku) {
var navigateTo
SkuMs
Detail = function (sku) {
if (!isNullOrEmpty(sku)) {
if (!isNullOrEmpty(sku)) {
var url = 'http://skums.bailuntec.com/ProductManage/Product/IframeDetail?Sku='+sku;
var url = 'http://skums.bailuntec.com/ProductManage/Product/IframeDetail?Sku='+sku;
window.open(url, '_blank');
window.open(url, '_blank');
}
}
}
}
var navigateToDetail = function (sku, warehousecode, status, type, title) {
if (!isNullOrEmpty(sku)) {
var url = '../../Purchase/SkuPurchase/Index?sku=' + sku + '&status=' + status + '&warehousecode=' + warehousecode;
//调拨
if (type === 2) {
url = '/Allot/SkuAllot/Index?sku=' + sku + '&status=' + status + '&warehousecode=' + warehousecode;
}
//销售订单
else if (type === 4) {
url = '/Order/SkuOrder/Index?sku=' + sku + '&status=' + status + '&warehousecode=' + warehousecode + '&shipstatus=1';
}
top.tablist.newTab({
id: "sku_statistics",
title: title,
closed: true,
replace: true,
icon: "fa fa-file-text-o",
url: url
});
}
}
</script>
</script>
\ No newline at end of file
trunk/Bailun.DataCenter.Web/Areas/Statistic/Views/WarehouseActive/Index.cshtml
View file @
bc7c674b
...
@@ -254,7 +254,12 @@
...
@@ -254,7 +254,12 @@
}
}
},
},
{ label: '调拨在途金额', name: 'allot_transit_money', index: 'allot_transit_money', align: 'center', sortable: true },
{ label: '调拨在途金额', name: 'allot_transit_money', index: 'allot_transit_money', align: 'center', sortable: true },
{ label: '待发货数量', name: 'plan_shipped', index: 'plan_shipped', align: 'center', sortable: true },
{
label: '待发货数量', name: 'plan_shipped', index: 'plan_shipped', align: 'center', sortable: true,
formatter: function (cellvalue, options, rowObject) {
return '<a style="color: rgb(51, 122, 183);cursor:pointer" onclick="navigateToDetail(\'' + rowObject.warehouse_code + '\',1,4,\'订单明细\')">' + cellvalue + '</a>';
}
},
{ label: '缺货数量', name: 'out_stock', index: 'out_stock', align: 'center', sortable: true },
{ label: '缺货数量', name: 'out_stock', index: 'out_stock', align: 'center', sortable: true },
//{ label: '采购总量', name: 'purchase_totalquantity', index: 'purchase_totalquantity', align: 'center', sortable: true },
//{ label: '采购总量', name: 'purchase_totalquantity', index: 'purchase_totalquantity', align: 'center', sortable: true },
//{ label: '入库总量', name: 'storage_totalquantity', index: 'storage_totalquantity', align: 'center', sortable: true },
//{ label: '入库总量', name: 'storage_totalquantity', index: 'storage_totalquantity', align: 'center', sortable: true },
...
@@ -291,52 +296,6 @@
...
@@ -291,52 +296,6 @@
subGrid: true,
subGrid: true,
subGridRowExpanded: function (subgrid_id, row_id) {
subGridRowExpanded: function (subgrid_id, row_id) {
var warehousecode = $gridTable.jqGrid('getRowData', row_id)['warehouse_code'];
var warehousecode = $gridTable.jqGrid('getRowData', row_id)['warehouse_code'];
//var subgrid_table_id = subgrid_id + "_t";
//$("#" + subgrid_id).html("<table id='" + subgrid_table_id + "'></table>");
//$("#" + subgrid_table_id).jqGrid({
// autowidth: true,
// url: "../../Statistic/WarehouseActive/GetWarehouseChildList",
// postData: {
// warehouse: warehousecode
// },
// datatype: "json",
// height: "100%",
// colModel: [
// { label: 'sku编码', name: 's_number', index: 's_number', width: 150, align: 'left', sortable: false },
// { label: '采购数量', name: 'quantity', index: 'quantity', width: 60, align: 'center', sortable: true },
// { label: '已发货数量', name: 'shipped_quantity', index: 'shipped_quantity', width: 80, align: 'center', sortable: true },
// { label: '未发货数量', name: 'notshipped_quantity', index: 'notshipped_quantity', width: 80, align: 'center', sortable: true },
// { label: '已到货数量', name: 'arrived_quantity', index: 'arrived_quantity', width: 80, align: 'center', sortable: true },
// { label: '未到货数量', name: 'notarrived_quantity', index: 'notarrived_quantity', width: 80, align: 'center', sortable: true },
// { label: '校验数量', name: 'checked_quantity', index: 'checked_quantity', width: 60, align: 'center', sortable: true },
// { label: '校验通过数量', name: 'checked_passed_quantity', index: 'checked_passed_quantity', width: 90, align: 'center', sortable: true },
// { label: '校验不通过数量', name: 'checked_notpassed_quantity', index: 'checked_notpassed_quantity', width: 100, align: 'center', sortable: true },
// { label: '质检数量', name: 'testing_quantity', index: 'testing_quantity', width: 60, align: 'center', sortable: true },
// { label: '质检通过数量', name: 'testing_passed_quantity', index: 'testing_passed_quantity', width: 90, align: 'center', sortable: true },
// { label: '质检不通过数量', name: 'testing_notpassed_quantity', index: 'testing_notpassed_quantity', width: 100, align: 'center', sortable: true },
// { label: '缺失数量', name: 'deletion_quantity', index: 'deletion_quantity', width: 60, align: 'center', sortable: true },
// { label: '报损数量', name: 'damage_quantity', index: 'damage_quantity', width: 60, align: 'center', sortable: true },
// { label: '退货数量', name: 'return_quantity', index: 'return_quantity', width: 60, align: 'center', sortable: true },
// { label: '换货数量', name: 'exchange_quantity', index: 'exchange_quantity', width: 60, align: 'center', sortable: true },
// { label: '入库数量', name: 'storage_quantity', index: 'storage_quantity', width: 60, align: 'center', sortable: true },
// { label: '待调拨数量', name: 'stayallot_quantity', index: 'stayallot_quantity', width: 80, align: 'center', sortable: true },
// { label: '调拨数量', name: 'allot_quantity', index: 'allot_quantity', width: 60, align: 'center', sortable: true },
// { label: '调拨已到货', name: 'allot_arrived_quantity', index: 'allot_arrived_quantity', width: 80, align: 'center', sortable: true },
// { label: '调拨未到货', name: 'allot_notarrived_quantity', index: 'allot_notarrived_quantity', width: 80, align: 'center', sortable: true },
// { label: '调拨缺失数量', name: 'allot_deletion_quantity', index: 'allot_deletion_quantity', width: 90, align: 'center', sortable: true },
// { label: '调拨入库数量', name: 'allot_storage_quantity', index: 'allot_storage_quantity', width: 90, align: 'center', sortable: true },
// { label: '未发货数量', name: 'order_quantity', index: 'order_quantity', width: 90, align: 'center', sortable: true },
// ],
// caption: "sku状态",
// rowNum: "1000",
// rownumbers: true,
// shrinkToFit: true,
// gridview: true,
// hidegrid: false,
// loadComplete: function () {
// $(window).trigger("resize");
// },
//});
bindPurchaseSubGrid(subgrid_id, row_id, warehousecode);
bindPurchaseSubGrid(subgrid_id, row_id, warehousecode);
bindAllotSubGrid(subgrid_id, row_id, warehousecode);
bindAllotSubGrid(subgrid_id, row_id, warehousecode);
bindOrderSubGrid(subgrid_id, row_id, warehousecode);
bindOrderSubGrid(subgrid_id, row_id, warehousecode);
...
@@ -362,7 +321,7 @@
...
@@ -362,7 +321,7 @@
{
{
label: 'sku编码', name: 's_number', index: 's_number', width: 120, align: 'left', sortable: false,
label: 'sku编码', name: 's_number', index: 's_number', width: 120, align: 'left', sortable: false,
formatter: function (cellvalue, options, rowObject) {
formatter: function (cellvalue, options, rowObject) {
return '<a style="color: rgb(51, 122, 183);cursor:pointer" onclick="navigateToSku
Detail
(\'' + cellvalue + '\',1,3,\'sku仓库\')">' + cellvalue + '</a>';
return '<a style="color: rgb(51, 122, 183);cursor:pointer" onclick="navigateToSku
ms
(\'' + cellvalue + '\',1,3,\'sku仓库\')">' + cellvalue + '</a>';
}
}
},
},
{
{
...
@@ -379,11 +338,30 @@
...
@@ -379,11 +338,30 @@
},
},
{ label: '起始仓', name: 'warehouse_name_from', index: 'warehouse_name_from', align: 'left', sortable: false },
{ label: '起始仓', name: 'warehouse_name_from', index: 'warehouse_name_from', align: 'left', sortable: false },
{ label: '目标仓', name: 'warehouse_name_to', index: 'warehouse_name_to', align: 'left', sortable: false },
{ label: '目标仓', name: 'warehouse_name_to', index: 'warehouse_name_to', align: 'left', sortable: false },
{ label: '采购数量', name: 'quantity', index: 'quantity', width: 60, align: 'center', sortable: true },
{ label: '采购总数量', name: 'quantity', index: 'quantity', width: 60, align: 'center', sortable: true },
{
label: '采购下单数', name: 'quantity', index: 'quantity', width: 60, align: 'center', sortable: true,
formatter: function (cellvalue, options, rowObject) {
if (cellvalue > 0) {
return '<a style="color: rgb(51, 122, 183);cursor:pointer" onclick="navigateToSkuDetail(\'' + rowObject.s_number + '\',1,1,\'采购明细\')">' + rowObject.notshipped_quantity + '</a>';
} else {
return rowObject.notshipped_quantity;
}
}
},
//{ label: '已发货数量', name: 'shipped_quantity', index: 'shipped_quantity', width: 80, align: 'center', sortable: true },
//{ label: '已发货数量', name: 'shipped_quantity', index: 'shipped_quantity', width: 80, align: 'center', sortable: true },
{ label: '未发货数量', name: 'notshipped_quantity', index: 'notshipped_quantity', width: 80, align: 'center', sortable: true },
//
{ label: '未发货数量', name: 'notshipped_quantity', index: 'notshipped_quantity', width: 80, align: 'center', sortable: true },
//{ label: '已到货数量', name: 'arrived_quantity', index: 'arrived_quantity', width: 80, align: 'center', sortable: true },
//{ label: '已到货数量', name: 'arrived_quantity', index: 'arrived_quantity', width: 80, align: 'center', sortable: true },
{ label: '未到货数量', name: 'notarrived_quantity', index: 'notarrived_quantity', width: 80, align: 'center', sortable: true },
{
label: '未到货数量', name: 'notarrived_quantity', index: 'notarrived_quantity', width: 80, align: 'center', sortable: true,
formatter: function (cellvalue, options, rowObject) {
if (cellvalue > 0) {
return '<a style="color: rgb(51, 122, 183);cursor:pointer" onclick="navigateToSkuDetail(\'' + rowObject.s_number + '\',1,1,\'采购明细\')">' + cellvalue + '</a>';
} else {
return cellvalue;
}
}
},
//{ label: '校验数量', name: 'checked_quantity', index: 'checked_quantity', width: 60, align: 'center', sortable: true },
//{ label: '校验数量', name: 'checked_quantity', index: 'checked_quantity', width: 60, align: 'center', sortable: true },
//{ label: '校验通过数量', name: 'checked_passed_quantity', index: 'checked_passed_quantity', width: 90, align: 'center', sortable: true },
//{ label: '校验通过数量', name: 'checked_passed_quantity', index: 'checked_passed_quantity', width: 90, align: 'center', sortable: true },
{ label: '校验不通过数量', name: 'checked_notpassed_quantity', index: 'checked_notpassed_quantity', width: 100, align: 'center', sortable: true },
{ label: '校验不通过数量', name: 'checked_notpassed_quantity', index: 'checked_notpassed_quantity', width: 100, align: 'center', sortable: true },
...
@@ -426,7 +404,7 @@
...
@@ -426,7 +404,7 @@
{
{
label: 'sku编码', name: 's_number', index: 's_number', align: 'left', sortable: false,
label: 'sku编码', name: 's_number', index: 's_number', align: 'left', sortable: false,
formatter: function (cellvalue, options, rowObject) {
formatter: function (cellvalue, options, rowObject) {
return '<a style="color: rgb(51, 122, 183);cursor:pointer" onclick="navigateToSku
Detail
(\'' + cellvalue + '\',1,3,\'sku仓库\')">' + cellvalue + '</a>';
return '<a style="color: rgb(51, 122, 183);cursor:pointer" onclick="navigateToSku
ms
(\'' + cellvalue + '\',1,3,\'sku仓库\')">' + cellvalue + '</a>';
}
}
},
},
{ label: '起始仓', name: 'warehouse_name_from', index: 'warehouse_name_from', align: 'left', sortable: false },
{ label: '起始仓', name: 'warehouse_name_from', index: 'warehouse_name_from', align: 'left', sortable: false },
...
@@ -443,9 +421,18 @@
...
@@ -443,9 +421,18 @@
}
}
}
}
},
},
{ label: '调拨数量', name: 'allot_quantity', index: 'allot_quantity', align: 'center', sortable: true },
{ label: '调拨
总
数量', name: 'allot_quantity', index: 'allot_quantity', align: 'center', sortable: true },
//{ label: '已到货数量', name: 'arrived_quantity', index: 'arrived_quantity', align: 'center', sortable: true },
//{ label: '已到货数量', name: 'arrived_quantity', index: 'arrived_quantity', align: 'center', sortable: true },
{ label: '未到货数量', name: 'notarrived_quantity', index: 'notarrived_quantity', align: 'center', sortable: true },
{
label: '未到货数量', name: 'notarrived_quantity', index: 'notarrived_quantity', align: 'center', sortable: true,
formatter: function (cellvalue, options, rowObject) {
if (cellvalue > 0) {
return '<a style="color: rgb(51, 122, 183);cursor:pointer" onclick="navigateToSkuDetail(\'' + rowObject.s_number + '\',1,2,\'调拨明细\')">' + cellvalue + '</a>';
} else {
return cellvalue;
}
}
},
{ label: '缺失数量', name: 'deletion_quantity', index: 'deletion_quantity', align: 'center', sortable: true },
{ label: '缺失数量', name: 'deletion_quantity', index: 'deletion_quantity', align: 'center', sortable: true },
{ label: '入库数量', name: 'storage_quantity', index: 'storage_quantity', align: 'center', sortable: true },
{ label: '入库数量', name: 'storage_quantity', index: 'storage_quantity', align: 'center', sortable: true },
],
],
...
@@ -499,7 +486,12 @@
...
@@ -499,7 +486,12 @@
}
}
},
},
{ label: '发货仓', name: 'delivery_warehouse_name', index: 'delivery_warehouse_name', align: 'left', sortable: true },
{ label: '发货仓', name: 'delivery_warehouse_name', index: 'delivery_warehouse_name', align: 'left', sortable: true },
{ label: '未发货数量', name: 'quantity', index: 'quantity', align: 'center', sortable: true },
{
label: '未发货数量', name: 'quantity', index: 'quantity', align: 'center', sortable: true,
formatter: function (cellvalue, options, rowObject) {
return '<a style="color: rgb(51, 122, 183);cursor:pointer" onclick="navigateToSkuDetail(\'' + rowObject.s_number + '\',1,4,\'订单明细\')">' + cellvalue + '</a>';
}
},
],
],
caption: "未发货订单",
caption: "未发货订单",
rowNum: 30,
rowNum: 30,
...
@@ -552,7 +544,12 @@
...
@@ -552,7 +544,12 @@
}
}
},
},
{ label: '发货仓', name: 'delivery_warehouse_name', index: 'delivery_warehouse_name', align: 'left', sortable: true },
{ label: '发货仓', name: 'delivery_warehouse_name', index: 'delivery_warehouse_name', align: 'left', sortable: true },
{ label: '未发货数量', name: 'quantity', index: 'quantity', align: 'center', sortable: true },
{
label: '未发货数量', name: 'quantity', index: 'quantity', align: 'center', sortable: true,
formatter: function (cellvalue, options, rowObject) {
return '<a style="color: rgb(51, 122, 183);cursor:pointer" onclick="navigateToSkuDetail(\'' + rowObject.s_number + '\',1,5,\'订单明细\')">' + cellvalue + '</a>';
}
},
],
],
caption: "FBA未发货订单",
caption: "FBA未发货订单",
rowNum: 30,
rowNum: 30,
...
@@ -629,6 +626,11 @@
...
@@ -629,6 +626,11 @@
else if (type === 3) {
else if (type === 3) {
url = '/Statistic/SkuStatistic/skuwarehouseIndex?warehousecode=' + warehousecode;
url = '/Statistic/SkuStatistic/skuwarehouseIndex?warehousecode=' + warehousecode;
}
}
//销售订单
else if (type === 4) {
url = '/Order/SkuOrder/Index?warehousecode=' + warehousecode + '&status=' + status + '&shipstatus=1';
}
top.tablist.newTab({
top.tablist.newTab({
id: "sku_statistics",
id: "sku_statistics",
title: title,
title: title,
...
@@ -640,10 +642,40 @@
...
@@ -640,10 +642,40 @@
}
}
}
}
var navigateToSku
Detail
= function (sku, status, type, title) {
var navigateToSku
ms
= function (sku, status, type, title) {
if (!isNullOrEmpty(sku)) {
if (!isNullOrEmpty(sku)) {
var url = 'http://skums.bailuntec.com/ProductManage/Product/IframeDetail?Sku=' + sku;
var url = 'http://skums.bailuntec.com/ProductManage/Product/IframeDetail?Sku=' + sku;
window.open(url, '_blank');
window.open(url, '_blank');
}
}
}
}
var navigateToSkuDetail = function (sku, status, type, title) {
if (!isNullOrEmpty(sku)) {
var url = '../../Purchase/SkuPurchase/Index?sku=' + sku + '&status=' + status;
//调拨
if (type === 2) {
url = '/Allot/SkuAllot/Index?sku=' + sku + '&status=' + status;
}
//sku仓库
else if (type === 3) {
url = '/Statistic/SkuStatistic/skuwarehouseIndex?sku=' + sku;
}
//HQOMS销售订单
else if (type === 4) {
url = '/Order/SkuOrder/Index?sku=' + sku + '&status=' + status + '&shipstatus=1&datasource=HQOMS';
}
//FBA销售订单
else if (type === 5) {
url = '/Order/SkuOrder/Index?sku=' + sku + '&status=' + status + '&shipstatus=1&datasource=FBA';
}
top.tablist.newTab({
id: "sku_statistics",
title: title,
closed: true,
replace: true,
icon: "fa fa-file-text-o",
url: url
});
}
}
</script>
</script>
\ No newline at end of file
trunk/Bailun.DataCenter.Web/Areas/Statistic/Views/WarehouseActive/WarehouseActiveNewIndex.cshtml
View file @
bc7c674b
...
@@ -159,7 +159,7 @@
...
@@ -159,7 +159,7 @@
text: "WareName",
text: "WareName",
height: "200px",
height: "200px",
async: true,
async: true,
param: { queryJson:
JSON.stringify(queryjson)
},
param: { queryJson:
JSON.stringify(queryjson)
},
allowSearch: true
allowSearch: true
});
});
});
});
...
@@ -254,7 +254,12 @@
...
@@ -254,7 +254,12 @@
}
}
},
},
{ label: '调拨在途金额', name: 'allot_transit_money', index: 'allot_transit_money', align: 'center', sortable: true },
{ label: '调拨在途金额', name: 'allot_transit_money', index: 'allot_transit_money', align: 'center', sortable: true },
{ label: '待发货数量', name: 'plan_shipped', index: 'plan_shipped', align: 'center', sortable: true },
{
label: '待发货数量', name: 'plan_shipped', index: 'plan_shipped', align: 'center', sortable: true,
formatter: function (cellvalue, options, rowObject) {
return '<a style="color: rgb(51, 122, 183);cursor:pointer" onclick="navigateToDetail(\'' + rowObject.warehouse_code + '\',1,4,\'订单明细\')">' + cellvalue + '</a>';
}
},
{ label: '缺货数量', name: 'out_stock', index: 'out_stock', align: 'center', sortable: true },
{ label: '缺货数量', name: 'out_stock', index: 'out_stock', align: 'center', sortable: true },
//{ label: '采购总量', name: 'purchase_totalquantity', index: 'purchase_totalquantity', align: 'center', sortable: true },
//{ label: '采购总量', name: 'purchase_totalquantity', index: 'purchase_totalquantity', align: 'center', sortable: true },
//{ label: '入库总量', name: 'storage_totalquantity', index: 'storage_totalquantity', align: 'center', sortable: true },
//{ label: '入库总量', name: 'storage_totalquantity', index: 'storage_totalquantity', align: 'center', sortable: true },
...
@@ -316,7 +321,7 @@
...
@@ -316,7 +321,7 @@
{
{
label: 'sku编码', name: 's_number', index: 's_number', width: 120, align: 'left', sortable: false,
label: 'sku编码', name: 's_number', index: 's_number', width: 120, align: 'left', sortable: false,
formatter: function (cellvalue, options, rowObject) {
formatter: function (cellvalue, options, rowObject) {
return '<a style="color: rgb(51, 122, 183);cursor:pointer" onclick="navigateToSku
Detail
(\'' + cellvalue + '\',1,3,\'sku仓库\')">' + cellvalue + '</a>';
return '<a style="color: rgb(51, 122, 183);cursor:pointer" onclick="navigateToSku
ms
(\'' + cellvalue + '\',1,3,\'sku仓库\')">' + cellvalue + '</a>';
}
}
},
},
{
{
...
@@ -333,11 +338,30 @@
...
@@ -333,11 +338,30 @@
},
},
{ label: '起始仓', name: 'warehouse_name_from', index: 'warehouse_name_from', align: 'left', sortable: false },
{ label: '起始仓', name: 'warehouse_name_from', index: 'warehouse_name_from', align: 'left', sortable: false },
{ label: '目标仓', name: 'warehouse_name_to', index: 'warehouse_name_to', align: 'left', sortable: false },
{ label: '目标仓', name: 'warehouse_name_to', index: 'warehouse_name_to', align: 'left', sortable: false },
{ label: '采购数量', name: 'quantity', index: 'quantity', width: 60, align: 'center', sortable: true },
{ label: '采购总数量', name: 'quantity', index: 'quantity', width: 60, align: 'center', sortable: true },
{
label: '采购下单数', name: 'quantity', index: 'quantity', width: 60, align: 'center', sortable: true,
formatter: function (cellvalue, options, rowObject) {
if (cellvalue > 0) {
return '<a style="color: rgb(51, 122, 183);cursor:pointer" onclick="navigateToSkuDetail(\'' + rowObject.s_number + '\',1,1,\'采购明细\')">' + rowObject.notshipped_quantity + '</a>';
} else {
return rowObject.notshipped_quantity;
}
}
},
//{ label: '已发货数量', name: 'shipped_quantity', index: 'shipped_quantity', width: 80, align: 'center', sortable: true },
//{ label: '已发货数量', name: 'shipped_quantity', index: 'shipped_quantity', width: 80, align: 'center', sortable: true },
{ label: '未发货数量', name: 'notshipped_quantity', index: 'notshipped_quantity', width: 80, align: 'center', sortable: true },
//
{ label: '未发货数量', name: 'notshipped_quantity', index: 'notshipped_quantity', width: 80, align: 'center', sortable: true },
//{ label: '已到货数量', name: 'arrived_quantity', index: 'arrived_quantity', width: 80, align: 'center', sortable: true },
//{ label: '已到货数量', name: 'arrived_quantity', index: 'arrived_quantity', width: 80, align: 'center', sortable: true },
{ label: '未到货数量', name: 'notarrived_quantity', index: 'notarrived_quantity', width: 80, align: 'center', sortable: true },
{
label: '未到货数量', name: 'notarrived_quantity', index: 'notarrived_quantity', width: 80, align: 'center', sortable: true,
formatter: function (cellvalue, options, rowObject) {
if (cellvalue > 0) {
return '<a style="color: rgb(51, 122, 183);cursor:pointer" onclick="navigateToSkuDetail(\'' + rowObject.s_number + '\',1,1,\'采购明细\')">' + cellvalue + '</a>';
} else {
return cellvalue;
}
}
},
//{ label: '校验数量', name: 'checked_quantity', index: 'checked_quantity', width: 60, align: 'center', sortable: true },
//{ label: '校验数量', name: 'checked_quantity', index: 'checked_quantity', width: 60, align: 'center', sortable: true },
//{ label: '校验通过数量', name: 'checked_passed_quantity', index: 'checked_passed_quantity', width: 90, align: 'center', sortable: true },
//{ label: '校验通过数量', name: 'checked_passed_quantity', index: 'checked_passed_quantity', width: 90, align: 'center', sortable: true },
{ label: '校验不通过数量', name: 'checked_notpassed_quantity', index: 'checked_notpassed_quantity', width: 100, align: 'center', sortable: true },
{ label: '校验不通过数量', name: 'checked_notpassed_quantity', index: 'checked_notpassed_quantity', width: 100, align: 'center', sortable: true },
...
@@ -380,7 +404,7 @@
...
@@ -380,7 +404,7 @@
{
{
label: 'sku编码', name: 's_number', index: 's_number', align: 'left', sortable: false,
label: 'sku编码', name: 's_number', index: 's_number', align: 'left', sortable: false,
formatter: function (cellvalue, options, rowObject) {
formatter: function (cellvalue, options, rowObject) {
return '<a style="color: rgb(51, 122, 183);cursor:pointer" onclick="navigateToSku
Detail
(\'' + cellvalue + '\',1,3,\'sku仓库\')">' + cellvalue + '</a>';
return '<a style="color: rgb(51, 122, 183);cursor:pointer" onclick="navigateToSku
ms
(\'' + cellvalue + '\',1,3,\'sku仓库\')">' + cellvalue + '</a>';
}
}
},
},
{ label: '起始仓', name: 'warehouse_name_from', index: 'warehouse_name_from', align: 'left', sortable: false },
{ label: '起始仓', name: 'warehouse_name_from', index: 'warehouse_name_from', align: 'left', sortable: false },
...
@@ -397,9 +421,18 @@
...
@@ -397,9 +421,18 @@
}
}
}
}
},
},
{ label: '调拨数量', name: 'allot_quantity', index: 'allot_quantity', align: 'center', sortable: true },
{ label: '调拨
总
数量', name: 'allot_quantity', index: 'allot_quantity', align: 'center', sortable: true },
//{ label: '已到货数量', name: 'arrived_quantity', index: 'arrived_quantity', align: 'center', sortable: true },
//{ label: '已到货数量', name: 'arrived_quantity', index: 'arrived_quantity', align: 'center', sortable: true },
{ label: '未到货数量', name: 'notarrived_quantity', index: 'notarrived_quantity', align: 'center', sortable: true },
{
label: '未到货数量', name: 'notarrived_quantity', index: 'notarrived_quantity', align: 'center', sortable: true,
formatter: function (cellvalue, options, rowObject) {
if (cellvalue > 0) {
return '<a style="color: rgb(51, 122, 183);cursor:pointer" onclick="navigateToSkuDetail(\'' + rowObject.s_number + '\',1,2,\'调拨明细\')">' + cellvalue + '</a>';
} else {
return cellvalue;
}
}
},
{ label: '缺失数量', name: 'deletion_quantity', index: 'deletion_quantity', align: 'center', sortable: true },
{ label: '缺失数量', name: 'deletion_quantity', index: 'deletion_quantity', align: 'center', sortable: true },
{ label: '入库数量', name: 'storage_quantity', index: 'storage_quantity', align: 'center', sortable: true },
{ label: '入库数量', name: 'storage_quantity', index: 'storage_quantity', align: 'center', sortable: true },
],
],
...
@@ -433,7 +466,7 @@
...
@@ -433,7 +466,7 @@
{
{
label: 'sku编码', name: 's_number', index: 's_number', align: 'left', sortable: false,
label: 'sku编码', name: 's_number', index: 's_number', align: 'left', sortable: false,
formatter: function (cellvalue, options, rowObject) {
formatter: function (cellvalue, options, rowObject) {
return '<a style="color: rgb(51, 122, 183);cursor:pointer" onclick="navigateToSku
Detail
(\'' + cellvalue + '\',1,3,\'sku仓库\')">' + cellvalue + '</a>';
return '<a style="color: rgb(51, 122, 183);cursor:pointer" onclick="navigateToSku
ms
(\'' + cellvalue + '\',1,3,\'sku仓库\')">' + cellvalue + '</a>';
}
}
},
},
{ label: '平台', name: 'platform', index: 'platform', align: 'left', sortable: false },
{ label: '平台', name: 'platform', index: 'platform', align: 'left', sortable: false },
...
@@ -453,7 +486,12 @@
...
@@ -453,7 +486,12 @@
}
}
},
},
{ label: '发货仓', name: 'delivery_warehouse_name', index: 'delivery_warehouse_name', align: 'left', sortable: true },
{ label: '发货仓', name: 'delivery_warehouse_name', index: 'delivery_warehouse_name', align: 'left', sortable: true },
{ label: '未发货数量', name: 'quantity', index: 'quantity', align: 'center', sortable: true },
{
label: '未发货数量', name: 'quantity', index: 'quantity', align: 'center', sortable: true,
formatter: function (cellvalue, options, rowObject) {
return '<a style="color: rgb(51, 122, 183);cursor:pointer" onclick="navigateToSkuDetail(\'' + rowObject.s_number + '\',1,4,\'订单明细\')">' + cellvalue + '</a>';
}
},
],
],
caption: "未发货订单",
caption: "未发货订单",
rowNum: 30,
rowNum: 30,
...
@@ -486,7 +524,7 @@
...
@@ -486,7 +524,7 @@
{
{
label: 'sku编码', name: 's_number', index: 's_number', align: 'left', sortable: false,
label: 'sku编码', name: 's_number', index: 's_number', align: 'left', sortable: false,
formatter: function (cellvalue, options, rowObject) {
formatter: function (cellvalue, options, rowObject) {
return '<a style="color: rgb(51, 122, 183);cursor:pointer" onclick="navigateToSku
Detail
(\'' + cellvalue + '\',1,3,\'sku仓库\')">' + cellvalue + '</a>';
return '<a style="color: rgb(51, 122, 183);cursor:pointer" onclick="navigateToSku
ms
(\'' + cellvalue + '\',1,3,\'sku仓库\')">' + cellvalue + '</a>';
}
}
},
},
{ label: '平台', name: 'platform', index: 'platform', align: 'left', sortable: false },
{ label: '平台', name: 'platform', index: 'platform', align: 'left', sortable: false },
...
@@ -506,7 +544,12 @@
...
@@ -506,7 +544,12 @@
}
}
},
},
{ label: '发货仓', name: 'delivery_warehouse_name', index: 'delivery_warehouse_name', align: 'left', sortable: true },
{ label: '发货仓', name: 'delivery_warehouse_name', index: 'delivery_warehouse_name', align: 'left', sortable: true },
{ label: '未发货数量', name: 'quantity', index: 'quantity', align: 'center', sortable: true },
{
label: '未发货数量', name: 'quantity', index: 'quantity', align: 'center', sortable: true,
formatter: function (cellvalue, options, rowObject) {
return '<a style="color: rgb(51, 122, 183);cursor:pointer" onclick="navigateToSkuDetail(\'' + rowObject.s_number + '\',1,5,\'订单明细\')">' + cellvalue + '</a>';
}
},
],
],
caption: "FBA未发货订单",
caption: "FBA未发货订单",
rowNum: 30,
rowNum: 30,
...
@@ -583,6 +626,11 @@
...
@@ -583,6 +626,11 @@
else if (type === 3) {
else if (type === 3) {
url = '/Statistic/SkuStatistic/skuwarehouseIndex?warehousecode=' + warehousecode;
url = '/Statistic/SkuStatistic/skuwarehouseIndex?warehousecode=' + warehousecode;
}
}
//销售订单
else if (type === 4) {
url = '/Order/SkuOrder/Index?warehousecode=' + warehousecode + '&status=' + status + '&shipstatus=1';
}
top.tablist.newTab({
top.tablist.newTab({
id: "sku_statistics",
id: "sku_statistics",
title: title,
title: title,
...
@@ -594,10 +642,40 @@
...
@@ -594,10 +642,40 @@
}
}
}
}
var navigateToSku
Detail
= function (sku, status, type, title) {
var navigateToSku
ms
= function (sku, status, type, title) {
if (!isNullOrEmpty(sku)) {
if (!isNullOrEmpty(sku)) {
var url = 'http://skums.bailuntec.com/ProductManage/Product/IframeDetail?Sku=' + sku;
var url = 'http://skums.bailuntec.com/ProductManage/Product/IframeDetail?Sku=' + sku;
window.open(url, '_blank');
window.open(url, '_blank');
}
}
}
}
var navigateToSkuDetail = function (sku, status, type, title) {
if (!isNullOrEmpty(sku)) {
var url = '../../Purchase/SkuPurchase/Index?sku=' + sku + '&status=' + status;
//调拨
if (type === 2) {
url = '/Allot/SkuAllot/Index?sku=' + sku + '&status=' + status;
}
//sku仓库
else if (type === 3) {
url = '/Statistic/SkuStatistic/skuwarehouseIndex?sku=' + sku;
}
//销售订单
else if (type === 4) {
url = '/Order/SkuOrder/Index?sku=' + sku + '&status=' + status + '&shipstatus=1&datasource=HQOMS';
}
//销售订单
else if (type === 5) {
url = '/Order/SkuOrder/Index?sku=' + sku + '&status=' + status + '&shipstatus=1&datasource=FBA';
}
top.tablist.newTab({
id: "sku_statistics",
title: title,
closed: true,
replace: true,
icon: "fa fa-file-text-o",
url: url
});
}
}
</script>
</script>
\ No newline at end of file
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