Fix actual price list parsing
This commit is contained in:
parent
ae7d81e95f
commit
97d601999c
@ -31,9 +31,14 @@ namespace RhSolutions.Api.Services
|
||||
{
|
||||
var firstCellAddress = ws.Search("Программа", System.Globalization.CompareOptions.IgnoreCase)
|
||||
.First()
|
||||
.CellLeft()
|
||||
.Address;
|
||||
|
||||
var lastCellAddress = ws.LastCellUsed().Address;
|
||||
var lastCellAddress = ws.Search("Цена брутто", System.Globalization.CompareOptions.IgnoreCase)
|
||||
.First()
|
||||
.WorksheetColumn()
|
||||
.LastCellUsed()
|
||||
.Address;
|
||||
|
||||
return ws.Range(firstCellAddress, lastCellAddress).AsTable();
|
||||
}
|
||||
@ -89,16 +94,16 @@ namespace RhSolutions.Api.Services
|
||||
productWarehouseCount = 0.0;
|
||||
}
|
||||
|
||||
string onWarehouseField = row.Field("Складская программа")
|
||||
string onWarehouseField = row.Field(0)
|
||||
.GetString();
|
||||
bool IsOnWarehouse;
|
||||
|
||||
switch (onWarehouseField)
|
||||
{
|
||||
case "x":
|
||||
case "N":
|
||||
IsOnWarehouse = true;
|
||||
break;
|
||||
case "под заказ":
|
||||
case "Z":
|
||||
IsOnWarehouse = false;
|
||||
break;
|
||||
default:
|
||||
|
Loading…
Reference in New Issue
Block a user