This commit is contained in:
@@ -375,7 +375,7 @@ namespace AyaNova.PlugIn.V8
|
|||||||
await ExportHeadOffices(progress);
|
await ExportHeadOffices(progress);
|
||||||
await ExportClients(progress);
|
await ExportClients(progress);
|
||||||
await ExportVendors(progress);
|
await ExportVendors(progress);
|
||||||
|
await ExportWarehouses(progress);
|
||||||
await ExportLoanItems(progress);
|
await ExportLoanItems(progress);
|
||||||
await ExportParts(progress);
|
await ExportParts(progress);
|
||||||
await ExportProjects(progress);
|
await ExportProjects(progress);
|
||||||
@@ -1591,6 +1591,41 @@ namespace AyaNova.PlugIn.V8
|
|||||||
}
|
}
|
||||||
#endregion Parts
|
#endregion Parts
|
||||||
|
|
||||||
|
|
||||||
|
#region Warehouses
|
||||||
|
private async System.Threading.Tasks.Task ExportWarehouses(ProgressForm progress)
|
||||||
|
{
|
||||||
|
ResetUniqueNames();
|
||||||
|
if (!progress.KeepGoing) return;
|
||||||
|
progress.Op("Start Part Warehouse export");
|
||||||
|
progress.SubOp("");
|
||||||
|
var ObjectTypeName = "Part Warehouse";
|
||||||
|
PartWarehouses pl = PartWarehouses.GetItems(false);
|
||||||
|
progress.Append("Exporting " + pl.Count.ToString() + " " + ObjectTypeName + "s");
|
||||||
|
foreach (PartWarehouse i in pl)
|
||||||
|
{
|
||||||
|
if (!progress.KeepGoing) return;
|
||||||
|
List<string> tags = new List<string>();
|
||||||
|
AddImportTag(tags);
|
||||||
|
dynamic d = new JObject();
|
||||||
|
d.name = GetUniqueName(i.Name);
|
||||||
|
if (IsDuplicatev7v8IdMapItem(i.ID, i.Name, progress)) continue;
|
||||||
|
progress.Op(ObjectTypeName + " " + d.name);
|
||||||
|
d.active = i.Active;
|
||||||
|
d.notes = i.Description;
|
||||||
|
TagFromv7Guid(i.RegionID, tags);
|
||||||
|
SetTags(d, tags);
|
||||||
|
var rMainObject = await util.PostAsync("part-warehouse", d.ToString());
|
||||||
|
long RavenId = util.IdFromResponse(rMainObject);
|
||||||
|
Addv7v8IdMap(i.ID, RavenId);
|
||||||
|
await util.EventLog(util.AyaType.PartWarehouse, RavenId, SafeGetUserMap(i.Creator), SafeGetUserMap(i.Modifier), i.Created, i.Modified);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
#endregion warehouses
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
#region Projects
|
#region Projects
|
||||||
private async System.Threading.Tasks.Task ExportProjects(ProgressForm progress)
|
private async System.Threading.Tasks.Task ExportProjects(ProgressForm progress)
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user