aboutsummaryrefslogtreecommitdiff
path: root/Source
diff options
context:
space:
mode:
Diffstat (limited to 'Source')
-rw-r--r--Source/AddIn/AddIn.cs8
-rw-r--r--Source/Assistant/HttpClientUtil.cs2
-rw-r--r--Source/DataExport/Exporter.cs4
-rw-r--r--Source/Ribbon/RibbonController.cs5
4 files changed, 11 insertions, 8 deletions
diff --git a/Source/AddIn/AddIn.cs b/Source/AddIn/AddIn.cs
index 5255e2e..e29c070 100644
--- a/Source/AddIn/AddIn.cs
+++ b/Source/AddIn/AddIn.cs
@@ -17,8 +17,8 @@ namespace RehauSku
public class AddIn : IExcelAddIn
{
public static readonly HttpClient httpClient = new HttpClient();
- public static ResponseOrder responseOrder;
- public static string priceListPath;
+ public static ResponseOrder StoreResponse { get; set; }
+ public static string PriceListPath { get; set; }
public void AutoOpen()
{
@@ -46,8 +46,8 @@ namespace RehauSku
.OpenSubKey("REHAU")
.OpenSubKey("SkuAssist");
- responseOrder = (ResponseOrder)addInKeys.GetValue("ResponseOrder");
- priceListPath = (string)addInKeys.GetValue("PriceListPath");
+ StoreResponse = (ResponseOrder)addInKeys.GetValue("ResponseOrder");
+ PriceListPath = (string)addInKeys.GetValue("PriceListPath");
}
}
}
diff --git a/Source/Assistant/HttpClientUtil.cs b/Source/Assistant/HttpClientUtil.cs
index 95a90e9..131bd7f 100644
--- a/Source/Assistant/HttpClientUtil.cs
+++ b/Source/Assistant/HttpClientUtil.cs
@@ -36,7 +36,7 @@ namespace RehauSku.Assistant
baseUri.Path = "/catalogsearch/result/index/";
string cleanedRequest = request.CleanRequest();
- switch (AddIn.responseOrder)
+ switch (AddIn.StoreResponse)
{
case ResponseOrder.Relevance:
baseUri.Query = "dir=asc&order=relevance&q=" + cleanedRequest;
diff --git a/Source/DataExport/Exporter.cs b/Source/DataExport/Exporter.cs
index 5a691b7..cc7621e 100644
--- a/Source/DataExport/Exporter.cs
+++ b/Source/DataExport/Exporter.cs
@@ -76,7 +76,7 @@ namespace RehauSku.DataExport
public void FillPriceList()
{
string exportFile = _GetExportFullPath();
- File.Copy(AddIn.priceListPath, exportFile, true);
+ File.Copy(AddIn.PriceListPath, exportFile, true);
Workbook wb = xlApp.Workbooks.Open(exportFile);
Worksheet ws = wb.ActiveSheet;
@@ -94,7 +94,7 @@ namespace RehauSku.DataExport
private string _GetExportFullPath()
{
- string fileExtension = Path.GetExtension(AddIn.priceListPath);
+ string fileExtension = Path.GetExtension(AddIn.PriceListPath);
return Path.GetTempFileName() + fileExtension;
}
diff --git a/Source/Ribbon/RibbonController.cs b/Source/Ribbon/RibbonController.cs
index 94d3b0d..39cf71a 100644
--- a/Source/Ribbon/RibbonController.cs
+++ b/Source/Ribbon/RibbonController.cs
@@ -34,7 +34,10 @@ namespace RehauSku.Ribbon
{
if (!dw.IsRangeValid())
{
- MessageBox.Show("Выделен неверный диапазон!", "Неверный диапазон", MessageBoxButtons.OK, MessageBoxIcon.Information);
+ MessageBox.Show("Выделен неверный диапазон!",
+ "Неверный диапазон",
+ MessageBoxButtons.OK,
+ MessageBoxIcon.Information);
return;
}