개정판 e52385b9
issue #000: BaseClientAddress MARKUS.ini File로 통합
Change-Id: I05d621ff60251bb08eb9c165e1309f4dff65a111
KCOM/App.xaml.cs | ||
---|---|---|
16 | 16 |
using System.Windows; |
17 | 17 |
using System.Xml; |
18 | 18 |
using log4net; |
19 |
using System.Text; |
|
20 |
using System.Runtime.InteropServices; |
|
19 | 21 |
|
20 | 22 |
[assembly: log4net.Config.XmlConfigurator(Watch = true)] |
21 | 23 |
namespace KCOM |
... | ... | |
67 | 69 |
} |
68 | 70 |
} |
69 | 71 |
|
72 |
[DllImport("kernel32")] |
|
73 |
private static extern int GetPrivateProfileString(string section, string key, string def, StringBuilder retVal, int size, string filePath); |
|
74 |
|
|
70 | 75 |
public static RestSharp.RestClient BaseClient { get; set; } |
71 | 76 |
public static IKCOM.KCOM_SystemInfo SystemInfo { get; set; } |
72 | 77 |
private static OpenProperties ParamDecoding(string DecodingText, System.Text.Encoding oEncoding = null) |
... | ... | |
159 | 164 |
_binding.TransferMode = TransferMode.Buffered; |
160 | 165 |
//Support.SetLicense(); |
161 | 166 |
|
162 |
string sBaseServiceURL = global::KCOM.Properties.Settings.Default.BaseClientAddress; |
|
167 |
StringBuilder BaseClientAddress = new StringBuilder(512); |
|
168 |
GetPrivateProfileString("BaseClientAddress", "URL", "(NONE)", BaseClientAddress, 512, Path.Combine(AppDataFolder, "FinalService.ini")); |
|
169 |
|
|
170 |
//string sBaseServiceURL = global::KCOM.Properties.Settings.Default.BaseClientAddress; |
|
171 |
string sBaseServiceURL = BaseClientAddress.ToString(); |
|
163 | 172 |
|
164 | 173 |
var ipaddress = DNSHelper.GetDnsAdress(); |
165 | 174 |
|
KCOM/Common/Converter/SvgConverter.cs | ||
---|---|---|
38 | 38 |
{ |
39 | 39 |
StartInfo = new ProcessStartInfo |
40 | 40 |
{ |
41 |
//FileName = @"http://cloud.devdoftech.co.kr:5977/UserData/"+ "potrace.exe", |
|
42 | 41 |
FileName = @AppDomain.CurrentDomain.BaseDirectory + "potrace.exe", |
43 |
//Arguments = "-s -u 1", //SVG |
|
44 |
//Arguments = "- -o- --svg", |
|
45 |
//Arguments = filename2 + " --backend svg", |
|
46 |
//Arguments = @AppDomain.CurrentDomain.BaseDirectory + "potrace.bmp" + " --backend svg -i", |
|
47 |
//Arguments = "-b svg -i " + @AppDomain.CurrentDomain.BaseDirectory + "potrace.bmp", |
|
48 | 42 |
Arguments = "-b svg " + @AppDomain.CurrentDomain.BaseDirectory + "potrace.bmp", |
49 | 43 |
RedirectStandardInput = true, |
50 | 44 |
RedirectStandardOutput = true, |
51 |
//RedirectStandardError = Program.IsDebug, |
|
52 | 45 |
RedirectStandardError = true, |
53 | 46 |
UseShellExecute = false, |
54 | 47 |
CreateNoWindow = true, |
KCOM/Controls/cadPanel.xaml.cs | ||
---|---|---|
120 | 120 |
//MessageBox.Show(sResult); |
121 | 121 |
if (sResult == "SUCCESS") |
122 | 122 |
{ |
123 |
// _resultpath = System.IO.Path.Combine(System.IO.Path.GetDirectoryName(AppDomain.CurrentDomain.BaseDirectory + "Cad\\" + "commentstring.json"), |
|
124 |
// System.IO.Path.GetFileNameWithoutExtension(AppDomain.CurrentDomain.BaseDirectory + "Cad\\" + "commentstring.json") + ".dwg"); |
|
125 |
|
|
126 | 123 |
CadResultViewer check = new CadResultViewer(); |
127 | 124 |
check.WindowStartupLocation = WindowStartupLocation.CenterScreen; |
128 | 125 |
check.filename = destFile; |
129 |
//check.filepath.Text = _resultpath; |
|
130 | 126 |
check.Title = "Result"; |
131 | 127 |
check.Show(); |
132 |
|
|
133 |
//clear.IsEnabled = false; |
|
134 |
//export.IsEnabled = false; |
|
135 |
|
|
136 | 128 |
} |
137 | 129 |
else |
138 | 130 |
{ |
KCOM/MARKUS.ini | ||
---|---|---|
1 |
[PDFMovePath] |
|
2 |
URL=\\192.168.0.67\finalpdf\ |
|
3 |
[ApprovedImgPath] |
|
4 |
URL=\\192.168.0.67\finalpdf\Approved.png |
|
5 |
[CheckmarkImgPath] |
|
6 |
URL=\\192.168.0.67\finalpdf\checkmark.png |
|
7 |
[BaseClientAddress] |
|
8 |
URL=http://www.devdoftech.co.kr:5979 |
MarkupToPDF/Common/GetUserSign.cs | ||
---|---|---|
4 | 4 |
using System.Collections.Generic; |
5 | 5 |
using System.IO; |
6 | 6 |
using System.Linq; |
7 |
using System.Runtime.InteropServices; |
|
7 | 8 |
using System.ServiceModel; |
8 | 9 |
using System.Text; |
9 | 10 |
|
... | ... | |
19 | 20 |
/// <param name="UserID"></param> |
20 | 21 |
/// <param name="ProjectNo"></param> |
21 | 22 |
/// <returns></returns> |
23 |
/// |
|
24 |
/// <summary> |
|
25 |
/// Application Data Folder |
|
26 |
/// </summary> |
|
27 |
/// |
|
28 |
public static string AppDataFolder |
|
29 |
{ |
|
30 |
get |
|
31 |
{ |
|
32 |
return Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.CommonApplicationData), "MARKUS"); |
|
33 |
} |
|
34 |
} |
|
35 |
|
|
36 |
[DllImport("kernel32")] |
|
37 |
private static extern int GetPrivateProfileString(string section, string key, string def, StringBuilder retVal, int size, string filePath); |
|
38 |
|
|
22 | 39 |
public string GetSign(string UserID, string ProjectNo) |
23 | 40 |
{ |
24 | 41 |
|
... | ... | |
30 | 47 |
_binding.CloseTimeout = new TimeSpan(0, 5, 0); |
31 | 48 |
_binding.SendTimeout = new TimeSpan(0, 5, 0); |
32 | 49 |
_binding.TextEncoding = System.Text.Encoding.UTF8; |
33 |
_binding.TransferMode = TransferMode.Buffered; |
|
50 |
_binding.TransferMode = TransferMode.Buffered; |
|
51 |
|
|
52 |
StringBuilder BaseClientAddress = new StringBuilder(512); |
|
53 |
GetPrivateProfileString("BaseClientAddress", "URL", "(NONE)", BaseClientAddress, 512, Path.Combine(AppDataFolder, "FinalService.ini")); |
|
54 |
|
|
55 |
//string sBaseServiceURL = global::MarkupToPDF.Properties.Settings.Default.BaseClientAddress; |
|
56 |
string sBaseServiceURL = BaseClientAddress.ToString(); |
|
34 | 57 |
|
35 |
string sBaseServiceURL = global::MarkupToPDF.Properties.Settings.Default.BaseClientAddress; |
|
36 | 58 |
_EndPoint = new EndpointAddress(string.Format("{0}/ServiceDeepView.svc", sBaseServiceURL)); |
37 | 59 |
|
38 | 60 |
markus_api.ServiceDeepViewClient client = new markus_api.ServiceDeepViewClient(_binding, _EndPoint); |
내보내기 Unified diff