markus / MarkupToPDF / Common / GetUserSign.cs @ 53880c83
이력 | 보기 | 이력해설 | 다운로드 (1.61 KB)
1 |
using KCOMDataModel.Common; |
---|---|
2 |
using KCOMDataModel.DataModel; |
3 |
using System; |
4 |
using System.Collections.Generic; |
5 |
using System.IO; |
6 |
using System.Linq; |
7 |
using System.ServiceModel; |
8 |
using System.Text; |
9 |
|
10 |
namespace MarkupToPDF.Common |
11 |
{ |
12 |
public class GetUserSign |
13 |
{ |
14 |
public BasicHttpBinding _binding; |
15 |
public EndpointAddress _EndPoint; |
16 |
/// <summary> |
17 |
/// get signature of given user of given project |
18 |
/// </summary> |
19 |
/// <param name="UserID"></param> |
20 |
/// <param name="ProjectNo"></param> |
21 |
/// <returns></returns> |
22 |
public string GetSign(string UserID, string ProjectNo) |
23 |
{ |
24 |
|
25 |
_binding = new BasicHttpBinding(BasicHttpSecurityMode.TransportCredentialOnly); |
26 |
_binding.MaxBufferSize = 2147483647; |
27 |
_binding.MaxReceivedMessageSize = 2147483647; |
28 |
_binding.OpenTimeout = new TimeSpan(0, 1, 0); |
29 |
_binding.ReceiveTimeout = new TimeSpan(0, 10, 0); |
30 |
_binding.CloseTimeout = new TimeSpan(0, 5, 0); |
31 |
_binding.SendTimeout = new TimeSpan(0, 5, 0); |
32 |
_binding.TextEncoding = System.Text.Encoding.UTF8; |
33 |
_binding.TransferMode = TransferMode.Buffered; |
34 |
|
35 |
string sBaseServiceURL = global::MarkupToPDF.Properties.Settings.Default.BaseClientAddress; |
36 |
_EndPoint = new EndpointAddress(string.Format("{0}/ServiceDeepView.svc", sBaseServiceURL)); |
37 |
|
38 |
markus_api.ServiceDeepViewClient client = new markus_api.ServiceDeepViewClient(_binding, _EndPoint); |
39 |
var _sign = client.GetSignData(ProjectNo, UserID); |
40 |
|
41 |
return _sign; |
42 |
} |
43 |
} |
44 |
} |