프로젝트

일반

사용자정보

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

markus / ConvertService / ServiceController / StationControllerService / DataService.svc.cs @ aa42c9c1

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

1 5c387707 semi
using System;
2
using System.Collections.Generic;
3
using System.Data.Entity.Core.Objects;
4
using System.Linq;
5
using System.Runtime.Serialization;
6
using System.ServiceModel;
7
using System.Text;
8
9
namespace StationControllerService
10
{
11
    // 참고: "리팩터링" 메뉴에서 "이름 바꾸기" 명령을 사용하여 코드, svc 및 config 파일에서 클래스 이름 "DataService"을 변경할 수 있습니다.
12
    // 참고: 이 서비스를 테스트하기 위해 WCF 테스트 클라이언트를 시작하려면 솔루션 탐색기에서 DataService.svc나 DataService.svc.cs를 선택하고 디버깅을 시작하십시오.
13
    public class DataService : IDataService
14
    {
15 64e36f82 semi
16 aa42c9c1 semi
        public List<SELECT_CONVERT_ITEM_Result> GET_SELECT_CONVERT_ITEM(string p_ID, string p_PROJECT_NO, string p_DOCUMENT_ID, Nullable<int> p_STATUS, Nullable<int> p_TAKE_COUNT, Nullable<System.DateTime> p_BEGIN_CREATE_DATETIME, Nullable<System.DateTime> p_FINISH_CREATE_DATETIME, Nullable<System.DateTime> p_BEGIN_START_DATETIE, Nullable<System.DateTime> p_FINISH_START_DATETIME, Nullable<System.DateTime> p_BEGIN_END_DATETIME, Nullable<System.DateTime> p_FINISH_END_DATETIME, string p_GROUP_NO, string p_DOCUMENT_NAME, string p_DOCUMENT_NO, string p_REVISION, string p_SERVICE_ID, Nullable<int> p_RECONVERTER, string p_DOCUMENT_URL, Nullable<int> p_ExcptionCheck)
17 5c387707 semi
        {
18
            List<SELECT_CONVERT_ITEM_Result> result = new List<SELECT_CONVERT_ITEM_Result>();
19
20
            try
21
            {
22 8f148d28 semi
                ///var connectionstring = Properties.Resources.ConnectionString;
23 5c387707 semi
24 8f148d28 semi
                using (markusEntities entities = new markusEntities())
25 5c387707 semi
                {
26
                    result = entities.SELECT_CONVERT_ITEM(p_ID, p_PROJECT_NO, p_DOCUMENT_ID, p_STATUS, p_TAKE_COUNT, p_BEGIN_CREATE_DATETIME, p_FINISH_CREATE_DATETIME, p_BEGIN_START_DATETIE, p_FINISH_START_DATETIME, p_BEGIN_END_DATETIME, p_FINISH_END_DATETIME, p_GROUP_NO, p_DOCUMENT_NAME, p_DOCUMENT_NO, p_REVISION, p_SERVICE_ID, p_RECONVERTER, p_DOCUMENT_URL, p_ExcptionCheck).ToList();
27
28
                    //System.Diagnostics.Debug.WriteLine("GET_SELECT_CONVERT_ITEM result count :" + result.Count());
29
                }
30
            }
31
            catch (Exception)
32
            {
33
                throw new FaultException("GET_SELECT_CONVERT_ITEM");
34
            }
35
36
            return result;
37
        }
38
39
        public int GET_SELECT_RERECONVERT_ITEM(string p_ID, Nullable<int> p_RECONVERTER, Nullable<System.DateTime> p_CREATE_DATETIME, Nullable<int> p_STATUS, Nullable<System.DateTime> p_END_DATETIME)
40
        {
41
            int result;
42
43
            try
44
            {
45 8f148d28 semi
                //var connectionstring = Properties.Resources.ConnectionString;
46 5c387707 semi
47 8f148d28 semi
                using (markusEntities entities = new markusEntities())
48 5c387707 semi
                {
49
                    result = entities.SELECT_RERECONVERT_ITEM(p_ID, p_RECONVERTER, p_CREATE_DATETIME, p_STATUS, p_END_DATETIME);
50
                }
51
            }
52
            catch (Exception)
53
            {
54
                throw new FaultException("GET_SELECT_RERECONVERT_ITEM");
55
            }
56
57
            return result;
58
        }
59
60
        public int GET_SELECT_CONVERT_DELETE(string p_ID)
61
        {
62
            int result;
63
64
            try
65
            {
66 8f148d28 semi
                //var connectionstring = Properties.Resources.ConnectionString;
67 5c387707 semi
68 8f148d28 semi
                using (markusEntities entities = new markusEntities())
69 5c387707 semi
                {
70
                    result = entities.SELECT_CONVERT_DELETE(p_ID);
71
                }
72
            }
73
            catch (Exception)
74
            {
75
                throw new FaultException("GET_SELECT_CONVERT_DELETE");
76
            }
77
78
            return result;
79
        }
80
81
        public List<SELECT_RUN_PROJECTS_Result> GET_SELECT_RUN_PROJECTS(int p_RUN_PROJECTS)
82
        {
83
            List<SELECT_RUN_PROJECTS_Result> result = new List<SELECT_RUN_PROJECTS_Result>();
84
85
            try
86
            {
87 8f148d28 semi
                //var connectionstring = Properties.Resources.ConnectionString;
88 5c387707 semi
89 8f148d28 semi
                using (markusEntities entities = new markusEntities())
90 5c387707 semi
                {
91
                    result = entities.SELECT_RUN_PROJECTS(p_RUN_PROJECTS).ToList();
92
                }
93
            }
94 be7b18b6 semi
            catch (Exception ex)
95 5c387707 semi
            {
96 be7b18b6 semi
                System.Diagnostics.Debug.WriteLine(ex);
97 5c387707 semi
                throw new FaultException("GET_SELECT_RUN_PROJECTS");
98
            }
99
100
            return result;
101
        }
102
103
        public int GET_SELECT_CONVERT_INSERT(string p_ID, string p_PROJECT_NO, string p_DOCUMENT_URL, string p_DOCUMENT_ID)
104
        {
105
            int result;
106
107
            try
108
            {
109 8f148d28 semi
                //var connectionstring = Properties.Resources.ConnectionString;
110 5c387707 semi
111 8f148d28 semi
                using (markusEntities entities = new markusEntities())
112 5c387707 semi
                {
113
                    result = entities.SELECT_CONVERT_INSERT(p_ID, p_PROJECT_NO, p_DOCUMENT_URL, p_DOCUMENT_ID);
114
                }
115
            }
116
            catch (Exception)
117
            {
118
                throw new FaultException("GET_SELECT_FINAL_PDF_INSERT");
119
            }
120
121
            return result;
122
        }
123
124 aa42c9c1 semi
        public List<SELECT_FINAL_PDF_ITEM_Result> GET_SELECT_FINAL_PDF_ITEM(string p_ID, string p_PROJECT_NO, string p_DOCUMENT_ID, string p_MARKUPINFO_ID, string p_DOCINFO_ID, string p_DOCUMENT_NAME, string p_DOCUMENT_NO, string p_CREATE_USER_ID, Nullable<int> p_STATUS, Nullable<int> p_TAKE_COUNT, string p_GROUP_NO, string p_REVISION, Nullable<System.DateTime> p_BEGIN_CREATE_DATETIME, Nullable<System.DateTime> p_FINISH_CREATE_DATETIME, Nullable<System.DateTime> p_BEGIN_START_DATETIE, Nullable<System.DateTime> p_FINISH_START_DATETIME, Nullable<System.DateTime> p_BEGIN_END_DATETIME, Nullable<System.DateTime> p_FINISH_END_DATETIME, string p_DOCUMENT_URL, Nullable<int> p_ExcptionCheck)
125 5c387707 semi
        {
126
            List<SELECT_FINAL_PDF_ITEM_Result> result = new List<SELECT_FINAL_PDF_ITEM_Result>();
127
128
            try
129
            {
130 8f148d28 semi
                //var connectionstring = Properties.Resources.ConnectionString;
131 5c387707 semi
132 8f148d28 semi
                using (markusEntities entities = new markusEntities())
133 5c387707 semi
                {
134
                    result = entities.SELECT_FINAL_PDF_ITEM(p_ID, p_PROJECT_NO, p_DOCUMENT_ID, p_MARKUPINFO_ID, p_DOCINFO_ID, p_DOCUMENT_NAME, p_DOCUMENT_NO, p_CREATE_USER_ID, p_STATUS, p_TAKE_COUNT, p_GROUP_NO, p_REVISION, p_BEGIN_CREATE_DATETIME, p_FINISH_CREATE_DATETIME, p_BEGIN_START_DATETIE, p_FINISH_START_DATETIME, p_BEGIN_END_DATETIME, p_FINISH_END_DATETIME, p_DOCUMENT_URL, p_ExcptionCheck).ToList();
135
                }
136
            }
137
            catch (Exception)
138
            {
139
                throw new FaultException("GET_SELECT_FINAL_PDF_ITEM");
140
            }
141
142
            return result;
143
        }
144
145
        public int GET_SELECT_FINAL_PDF_DELETE(string p_ID)
146
        {
147
            int result;
148
149
            try
150
            {
151 8f148d28 semi
                //var connectionstring = Properties.Resources.ConnectionString;
152 5c387707 semi
153 8f148d28 semi
                using (markusEntities entities = new markusEntities())
154 5c387707 semi
                {
155
                    result = entities.SELECT_FINAL_PDF_DELETE(p_ID);
156
                }
157
            }
158
            catch (Exception)
159
            {
160
                throw new FaultException("GET_SELECT_FINAL_PDF_DELETE");
161
            }
162
163
            return result;
164
        }
165
166
        public int GET_SELECT_FINAL_PDF_INSERT(string p_ID, string p_PROJECT_NO, string p_DOCUMENT_URL, string p_DOCUMENT_ID)
167
        {
168
            int result;
169
170
            try
171
            {
172 8f148d28 semi
                //var connectionstring = Properties.Resources.ConnectionString;
173 5c387707 semi
174 8f148d28 semi
                using (markusEntities entities = new markusEntities())
175 5c387707 semi
                {
176
                    result = entities.SELECT_FINAL_PDF_INSERT(p_ID, p_PROJECT_NO, p_DOCUMENT_URL, p_DOCUMENT_ID);
177
                }
178
            }
179
            catch (Exception)
180
            {
181
                throw new FaultException("GET_SELECT_FINAL_PDF_INSERT");
182
            }
183
184
            return result;
185
        }
186
187
        public List<FINALPDF_COUNT_Result> GET_FINALPDF_COUNT(Nullable<int> p_STATUS, Nullable<System.DateTime> p_BEGIN_CREATE_DATETIME, Nullable<System.DateTime> p_FINISH_CREATE_DATETIME)
188
        {
189
190
            List<FINALPDF_COUNT_Result> result = new List<FINALPDF_COUNT_Result>();
191
192
            try
193
            {
194 8f148d28 semi
                //var connectionstring = Properties.Resources.ConnectionString;
195 5c387707 semi
196 8f148d28 semi
                using (markusEntities entities = new markusEntities())
197 5c387707 semi
                {
198
                    result = entities.FINALPDF_COUNT(p_STATUS, p_BEGIN_CREATE_DATETIME, p_FINISH_CREATE_DATETIME).ToList();
199
                }
200
            }
201
            catch (Exception)
202
            {
203
                throw new FaultException("GET_FINALPDF_COUNT");
204
            }
205
206
            return result;
207
        }
208
209
        public List<CONVERT_COUNT_Result> GET_CONVERT_COUNT(Nullable<int> p_STATUS, Nullable<System.DateTime> p_BEGIN_CREATE_DATETIME, Nullable<System.DateTime> p_FINISH_CREATE_DATETIME)
210
        {
211
212
            List<CONVERT_COUNT_Result> result = new List<CONVERT_COUNT_Result>();
213
214
            try
215
            {
216 8f148d28 semi
                //var connectionstring = Properties.Resources.ConnectionString;
217 5c387707 semi
218 8f148d28 semi
                using (markusEntities entities = new markusEntities())
219 5c387707 semi
                {
220
                    result = entities.CONVERT_COUNT(p_STATUS, p_BEGIN_CREATE_DATETIME, p_FINISH_CREATE_DATETIME).ToList();
221
                }
222
            }
223
            catch (Exception)
224
            {
225
                throw new FaultException("GET_CONVERT_COUNT");
226
            }
227
228
            return result;
229
        }
230
231 64e36f82 semi
        public List<SELECT_DOCUMENT_ITEM_Result> GET_DOCUMENT_ITEM(Nullable<int> p_TAKE_COUNT, string p_REVISION, string p_DOCUMENT_N0, string p_DOCUMENT_NAME, string p_GROUP_N0, string p_ORIGINAL_FILE, string p_DOCUMENT_ID, string p_PROJECT_NO)
232 5c387707 semi
        {
233
234
            List<SELECT_DOCUMENT_ITEM_Result> result = new List<SELECT_DOCUMENT_ITEM_Result>();
235
236
            try
237
            {
238 8f148d28 semi
                //var connectionstring = Properties.Resources.ConnectionString;
239 5c387707 semi
240 8f148d28 semi
                using (markusEntities entities = new markusEntities())
241 5c387707 semi
                {
242
                    result = entities.SELECT_DOCUMENT_ITEM(p_TAKE_COUNT, p_REVISION, p_DOCUMENT_N0, p_DOCUMENT_NAME, p_GROUP_N0, p_ORIGINAL_FILE, p_DOCUMENT_ID, p_PROJECT_NO).ToList();
243
                }
244
            }
245 5c6aea78 semi
            catch (Exception ex)
246 5c387707 semi
            {
247 5c6aea78 semi
                System.Diagnostics.Debug.WriteLine(ex.ToString());
248 5c387707 semi
                throw new FaultException("GET_DOCUMENT_ITEM");
249
            }
250
251
            return result;
252
        }
253 64e36f82 semi
254
        public List<SELECT_PROPERTIES_RUN_PROJECTS_Result> GET_PROPERTIES_RUN_PROJECTS(string p_PROJECT_NO)
255
        {
256
257
            List<SELECT_PROPERTIES_RUN_PROJECTS_Result> result = new List<SELECT_PROPERTIES_RUN_PROJECTS_Result>();
258
259
            try
260
            {
261
                //var connectionstring = Properties.Resources.ConnectionString;
262
263
                using (markusEntities entities = new markusEntities())
264
                {
265
                    result = entities.SELECT_PROPERTIES_RUN_PROJECTS(p_PROJECT_NO).ToList();
266
                }
267
            }
268
            catch (Exception ex)
269
            {
270
                System.Diagnostics.Debug.WriteLine(ex.ToString());
271
                throw new FaultException("GET_PROPERTIES_RUN_PROJECTS");
272
            }
273
274
            return result;
275
        }
276
277 a11f76e7 semi
        public int GET_RUNANDPROPERTY_INSERT(string p_PROJECT_NO, string p_PROJECT_NAME, string p_TYPE_InitialCatalog, string p_VALUE_InitialCatalog, string p_TYPE_TileSorceStorage,
278
            string p_VALUE_TileSorceStorage, string p_TYPE_TileSourcePath, string p_VALUE_TileSourcePath, string p_TYPE_FinalPDFStorageRemote, string p_VALUE_FinalPDFStorageRemote, 
279
            string p_TYPE_FinalPDFStorageLocal, string p_VALUE_FinalPDFStorageLocal, string p_TYPE_UpLoadServiceUrl, string p_VALUE_UpLoadServiceUrl, Nullable<int> p_IS_ACTIVITY)
280 64e36f82 semi
        {
281 4a41c345 semi
282 64e36f82 semi
            int result;
283
284
            try
285
            {
286
                //var connectionstring = Properties.Resources.ConnectionString;
287
288
                using (markusEntities entities = new markusEntities())
289
                {
290 4a41c345 semi
                    result = entities.SELECT_RUNANDPROPERTY_INSERT(p_PROJECT_NO, p_PROJECT_NAME, p_TYPE_InitialCatalog, p_VALUE_InitialCatalog, p_TYPE_TileSorceStorage, p_VALUE_TileSorceStorage, p_TYPE_TileSourcePath, p_VALUE_TileSourcePath, p_TYPE_FinalPDFStorageRemote,
291 a11f76e7 semi
                        p_VALUE_FinalPDFStorageRemote, p_TYPE_FinalPDFStorageLocal, p_VALUE_FinalPDFStorageLocal, p_TYPE_UpLoadServiceUrl, p_VALUE_UpLoadServiceUrl, p_IS_ACTIVITY);
292 64e36f82 semi
                }
293
            }
294
            catch (Exception ex)
295
            {
296
                System.Diagnostics.Debug.WriteLine(ex.ToString());
297 4a41c345 semi
                throw new FaultException("GET_RUNANDPROPERTY_INSERT");
298 64e36f82 semi
            }
299
300
            return result;
301 4a41c345 semi
302 64e36f82 semi
        }
303 4a41c345 semi
304 5c387707 semi
    }
305
}
클립보드 이미지 추가 (최대 크기: 500 MB)