프로젝트

일반

사용자정보

통계
| 브랜치(Branch): | 개정판:

markus / KCOM_API / PemssService.svc.cs @ b7645ccc

이력 | 보기 | 이력해설 | 다운로드 (2.89 KB)

1
using KCOMDataModel.DataModel;
2
using System;
3
using System.Collections.Generic;
4
using System.Linq;
5
using System.Runtime.Serialization;
6
using System.ServiceModel;
7
using System.ServiceModel.Activation;
8
using System.ServiceModel.Web;
9
using System.Text;
10

    
11
namespace KCOM_API
12
{
13
    [ServiceContract(Namespace = "")]
14
    [AspNetCompatibilityRequirements(RequirementsMode = AspNetCompatibilityRequirementsMode.Allowed)]
15
    public class PemssService : System.Web.Services.WebService
16
    {
17
        private string PemssUri;
18

    
19
        public PemssService()
20
        {
21
            PemssUri = Properties.Settings.Default.PEMSS_URL;
22
        }
23

    
24
        [OperationContract]
25
        public List<PemssAPI.DataModel.Requirement> GetrequirementList(string pId, string dId)
26
        {
27
            KCOM_API.PemssApi api = new KCOM_API.PemssApi(PemssUri);
28
            return api.GetRequirementItems(pId,dId);
29
        }
30

    
31
        [OperationContract]
32
        public bool SetRequirementComment(string pId, string dId, string mdId, string commentId, string comment, bool condition, string uId)
33
        {
34
            KCOM_API.PemssApi api = new KCOM_API.PemssApi(PemssUri);
35
            return api.SetRequirementComment(pId,dId,mdId,commentId,comment,condition,uId);
36
        }
37

    
38
        [OperationContract]
39
        public bool RemoveRequirementComment(string pId, string dId, string mdId, string commentId, string uId)
40
        {
41
            KCOM_API.PemssApi api = new KCOM_API.PemssApi(PemssUri);
42
            return api.RemoveRequirementComment(pId, dId, mdId, commentId, uId);
43
        }
44

    
45
        [OperationContract]
46
        public List<PemssAPI.DataModel.Bidders> GetBidderstList(string pId, string dId)
47
        {
48
            KCOM_API.PemssApi api = new KCOM_API.PemssApi(PemssUri);
49
            return api.GetBiddesItems(pId, dId);
50
        }
51

    
52
        [OperationContract]
53
        public bool SetBiddersComment(string pId, string dId, string bdId, string commentId, string comment, bool condition, string uId)
54
        {
55
            KCOM_API.PemssApi api = new KCOM_API.PemssApi(PemssUri);
56
            return api.SetBiddersComment(pId, dId, bdId, commentId, comment, condition, uId);
57
        }
58

    
59
        [OperationContract]
60
        public bool RemoveBiddersComment(string pId, string dId, string bdId, string commentId, string uId)
61
        {
62
            KCOM_API.PemssApi api = new KCOM_API.PemssApi(PemssUri);
63
            return api.RemoveBiddersComment(pId, dId, bdId, commentId, uId);
64
        }
65

    
66
        [OperationContract]
67
        public PemssAPI.DataModel.DocumentInfo GetDocumentInfo(string pId,string dId)
68
        {
69
            try
70
            {
71
                KCOM_API.PemssApi api = new KCOM_API.PemssApi(PemssUri);
72
                return api.GetDocumentInfo(pId, dId);
73
            }
74
            catch (Exception ex)
75
            {
76
                throw new FaultException($"GetDocumentInfo PemssUri : {PemssUri} pId : {pId}   dId : {dId}  {ex.Message}");
77
            }
78
        }
79
    }
80
}
클립보드 이미지 추가 (최대 크기: 500 MB)