username@email.com
2024-11-15 f47da9571d16108fcab2bf6d55279a08ce2e7cbf
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using CY.IDAL;
using System.Data.SqlClient;
using System.Data;
using CY.Model;
using System.Transactions;
namespace CY.SQLDAL
{
    //简历信息
    public class OA_StaffResumeDAL : IOA_StaffResumeDAL
    {
        private Database _dataBase = null;
 
        public OA_StaffResumeDAL()
        {
            _dataBase = new Database();
        }
 
        public OA_StaffResumeDAL(Database dataBase)
        {
            _dataBase = dataBase;
        }
 
        /// <summary>
        /// 新增
        /// </summary>
        /// <param name="model"></param>
        /// <returns></returns>
        public bool InserModel(Infrastructure.Domain.IAggregateRoot model)
        {
            Model.OA_StaffResume trueModel = model as Model.OA_StaffResume;
            if (trueModel == null)
            {
                return false;
            }
            IList<SqlParameter> sqlParms = new List<SqlParameter>()
            {                new SqlParameter("@Memberid", trueModel.Memberid) ,            
                            new SqlParameter("@R_G_Avatar", trueModel.R_G_Avatar) ,            
                            new SqlParameter("@R_G_Name", trueModel.R_G_Name) ,            
                            new SqlParameter("@R_G_Sex", trueModel.R_G_Sex) ,            
                            new SqlParameter("@R_G_WorkYear", trueModel.R_G_WorkYear) ,            
                            new SqlParameter("@R_G_Degree", trueModel.R_G_Degree) ,            
                            new SqlParameter("@R_G_DocumentsType", trueModel.R_G_DocumentsType) ,            
                            new SqlParameter("@R_G_DocumentsNumber", trueModel.R_G_DocumentsNumber) ,            
                            new SqlParameter("@R_G_Email", trueModel.R_G_Email) ,            
                            new SqlParameter("@R_G_Moblie", trueModel.R_G_Moblie) ,            
                            new SqlParameter("@R_G_WorkPhone", trueModel.R_G_WorkPhone) ,            
                            new SqlParameter("@R_G_HomePhone", trueModel.R_G_HomePhone) ,            
                            new SqlParameter("@R_G_NowProvince", trueModel.R_G_NowProvince) ,            
                            new SqlParameter("@R_G_NowCity", trueModel.R_G_NowCity) ,            
                            new SqlParameter("@R_G_NowArea", trueModel.R_G_NowArea) ,            
                            new SqlParameter("@R_G_NowAddress", trueModel.R_G_NowAddress) ,            
                            new SqlParameter("@R_G_OldProvence", trueModel.R_G_OldProvence) ,            
                            new SqlParameter("@R_G_OldCity", trueModel.R_G_OldCity) ,            
                            new SqlParameter("@R_G_OldArea", trueModel.R_G_OldArea) ,            
                            new SqlParameter("@R_G_OldAdress", trueModel.R_G_OldAdress) ,            
                            new SqlParameter("@R_G_CreatTime", trueModel.R_G_CreatTime) ,            
                            new SqlParameter("@R_G_Language", trueModel.R_G_Language) ,            
                            new SqlParameter("@R_G_YearsMoney", trueModel.R_G_YearsMoney) ,            
                            new SqlParameter("@R_G_WorkStatus", trueModel.R_G_WorkStatus) ,            
                            new SqlParameter("@R_G_QQ", trueModel.R_G_QQ) ,            
                            new SqlParameter("@R_G_YouHome", trueModel.R_G_YouHome) ,            
                            new SqlParameter("@R_G_YouHeight", trueModel.R_G_YouHeight) ,            
                            new SqlParameter("@R_G_YouWeight", trueModel.R_G_YouWeight) ,            
                            new SqlParameter("@R_G_MarryStatus", trueModel.R_G_MarryStatus) ,            
                            new SqlParameter("@R_G_YouPolitical", trueModel.R_G_YouPolitical) ,            
                            new SqlParameter("@R_G_Status", trueModel.R_G_Status) ,            
                            new SqlParameter("@OrderNum", trueModel.OrderNum) ,            
                            new SqlParameter("@LastUpdateTime", trueModel.LastUpdateTime) ,            
                            new SqlParameter("@Operator", trueModel.Operator)             
                     };
            try
            {
                _dataBase.Query("sp_OA_StaffResume_Insert", CommandType.StoredProcedure, sqlParms.ToArray<SqlParameter>());
            }
            catch (Exception ex)
            {
                throw ex;
            }
            return true;
        }
 
        /// <summary>
        /// 保存简历
        /// </summary>
        /// <param name="m_OA_StaffResume"></param>
        /// <param name="m_OA_StaffResumeIntention"></param>
        /// <param name="m_OA_StaffResumeEducationList"></param>
        /// <param name="m_OA_StaffResumeWorkList"></param>
        /// <returns></returns>
        public bool SaveResume(OA_StaffResume m_OA_StaffResume, OA_StaffResumeIntention m_OA_StaffResumeIntention, List<OA_StaffResumeEducation> m_OA_StaffResumeEducationList, List<OA_StaffResumeWork> m_OA_StaffResumeWorkList)
        {
            try
            {
                OA_StaffResumeIntentionDAL dal_OA_StaffResumeIntentionDAL = new OA_StaffResumeIntentionDAL(_dataBase);
                OA_StaffResumeEducationDAL dal_OA_StaffResumeEducationDAL = new OA_StaffResumeEducationDAL(_dataBase);
                OA_StaffResumeWorkDAL dal_OA_StaffResumeWorkDAL = new OA_StaffResumeWorkDAL(_dataBase);
                bool IsSuccess = true;
                using (TransactionScope t_TransactionScope = new TransactionScope())
                {
                    if (IsSuccess)
                    {
                        if (m_OA_StaffResume.Keyid > 0)
                            IsSuccess = this.UpdateModel(m_OA_StaffResume);
                        else
                            IsSuccess = this.InserModel(m_OA_StaffResume);
 
                        if (IsSuccess)
                        {
                            if (m_OA_StaffResumeIntention.Keyid > 0)
                                IsSuccess = dal_OA_StaffResumeIntentionDAL.UpdateModel(m_OA_StaffResumeIntention);
                            else
                                IsSuccess = dal_OA_StaffResumeIntentionDAL.InserModel(m_OA_StaffResumeIntention);
                        }
 
                        if (IsSuccess)
                        {
                            IList<SqlParameter> sqlParms = new List<SqlParameter>() { new SqlParameter("@Memberid", m_OA_StaffResume.Memberid) };
                            _dataBase.Query("sp_OA_StaffResumeEducation_DeleteRows", CommandType.StoredProcedure, sqlParms.ToArray<SqlParameter>());
                            IList<SqlParameter> sqlParms1 = new List<SqlParameter>() { new SqlParameter("@Memberid", m_OA_StaffResume.Memberid) };
                            _dataBase.Query("sp_OA_StaffResumeWork_DeleteRows", CommandType.StoredProcedure, sqlParms1.ToArray<SqlParameter>());
                        }
 
                        if (IsSuccess)
                        {
                            foreach (var item in m_OA_StaffResumeEducationList)
                            {
                                if (IsSuccess)
                                    IsSuccess = dal_OA_StaffResumeEducationDAL.InserModel(item);
                                else
                                    return false;
                            }
                        }
 
                        if (IsSuccess)
                        {
                            foreach (var item in m_OA_StaffResumeWorkList)
                            {
                                if (IsSuccess)
                                    IsSuccess = dal_OA_StaffResumeWorkDAL.InserModel(item);
                                else
                                    return false;
                            }
                        }
                        if (IsSuccess)
                        {
                            t_TransactionScope.Complete();
                        }
                    }
                }
                return IsSuccess;
            }
            catch (Exception ex)
            {
                throw ex;
            }
        }
 
        /// <summary>
        /// 修改
        /// </summary>
        /// <param name="model"></param>
        /// <returns></returns>
        public bool UpdateModel(Infrastructure.Domain.IAggregateRoot model)
        {
            Model.OA_StaffResume trueModel = model as Model.OA_StaffResume;
            if (trueModel == null)
            {
                return false;
            }
            IList<SqlParameter> sqlParms = new List<SqlParameter>()
            {                new SqlParameter("@Keyid", trueModel.Keyid) ,            
                            new SqlParameter("@Memberid", trueModel.Memberid) ,            
                            new SqlParameter("@R_G_Avatar", trueModel.R_G_Avatar) ,            
                            new SqlParameter("@R_G_Name", trueModel.R_G_Name) ,            
                            new SqlParameter("@R_G_Sex", trueModel.R_G_Sex) ,            
                            new SqlParameter("@R_G_WorkYear", trueModel.R_G_WorkYear) ,            
                            new SqlParameter("@R_G_Degree", trueModel.R_G_Degree) ,            
                            new SqlParameter("@R_G_DocumentsType", trueModel.R_G_DocumentsType) ,            
                            new SqlParameter("@R_G_DocumentsNumber", trueModel.R_G_DocumentsNumber) ,            
                            new SqlParameter("@R_G_Email", trueModel.R_G_Email) ,            
                            new SqlParameter("@R_G_Moblie", trueModel.R_G_Moblie) ,            
                            new SqlParameter("@R_G_WorkPhone", trueModel.R_G_WorkPhone) ,            
                            new SqlParameter("@R_G_HomePhone", trueModel.R_G_HomePhone) ,            
                            new SqlParameter("@R_G_NowProvince", trueModel.R_G_NowProvince) ,            
                            new SqlParameter("@R_G_NowCity", trueModel.R_G_NowCity) ,            
                            new SqlParameter("@R_G_NowArea", trueModel.R_G_NowArea) ,            
                            new SqlParameter("@R_G_NowAddress", trueModel.R_G_NowAddress) ,            
                            new SqlParameter("@R_G_OldProvence", trueModel.R_G_OldProvence) ,            
                            new SqlParameter("@R_G_OldCity", trueModel.R_G_OldCity) ,            
                            new SqlParameter("@R_G_OldArea", trueModel.R_G_OldArea) ,            
                            new SqlParameter("@R_G_OldAdress", trueModel.R_G_OldAdress) ,            
                            new SqlParameter("@R_G_CreatTime", trueModel.R_G_CreatTime) ,            
                            new SqlParameter("@R_G_Language", trueModel.R_G_Language) ,            
                            new SqlParameter("@R_G_YearsMoney", trueModel.R_G_YearsMoney) ,            
                            new SqlParameter("@R_G_WorkStatus", trueModel.R_G_WorkStatus) ,            
                            new SqlParameter("@R_G_QQ", trueModel.R_G_QQ) ,            
                            new SqlParameter("@R_G_YouHome", trueModel.R_G_YouHome) ,            
                            new SqlParameter("@R_G_YouHeight", trueModel.R_G_YouHeight) ,            
                            new SqlParameter("@R_G_YouWeight", trueModel.R_G_YouWeight) ,            
                            new SqlParameter("@R_G_MarryStatus", trueModel.R_G_MarryStatus) ,            
                            new SqlParameter("@R_G_YouPolitical", trueModel.R_G_YouPolitical) ,            
                            new SqlParameter("@R_G_Status", trueModel.R_G_Status) ,            
                            new SqlParameter("@OrderNum", trueModel.OrderNum) ,            
                            new SqlParameter("@LastUpdateTime", trueModel.LastUpdateTime) ,            
                            new SqlParameter("@Operator", trueModel.Operator)             
                     };
            try
            {
                _dataBase.Query("sp_OA_StaffResume_Update", CommandType.StoredProcedure, sqlParms.ToArray<SqlParameter>());
            }
            catch (Exception ex)
            {
                throw ex;
            }
            return true;
        }
 
        /// <summary>
        /// 删除
        /// </summary>
        /// <param name="model"></param>
        /// <returns></returns>
        public bool DeleteModel(Infrastructure.Domain.IAggregateRoot model)
        {
            Model.OA_StaffResume trueModel = model as Model.OA_StaffResume;
            if (trueModel == null)
            {
                return false;
            }
            IList<SqlParameter> sqlParms = new List<SqlParameter>()
                {
                    new SqlParameter("@Keyid",trueModel.Keyid)
                };
            try
            {
                _dataBase.Query("sp_OA_StaffResume_DeleteRow", CommandType.StoredProcedure, sqlParms.ToArray<SqlParameter>());
            }
            catch (Exception ex)
            {
                throw ex;
            }
 
            return true;
        }
 
        /// <summary>
        /// 分页查询
        /// </summary>
        /// <param name="query"></param>
        /// <param name="pagination"></param>
        /// <returns></returns>
        public IEnumerable<Model.OA_StaffResume> SelectModelPage(Infrastructure.Query.Query query, Infrastructure.Query.Pagination pagination)
        {
            throw new NotImplementedException();
        }
 
        /// <summary>
        /// 单个查询
        /// </summary>
        /// <param name="query"></param>
        /// <returns></returns>
        public IEnumerable<Model.OA_StaffResume> SelectAllModel(Infrastructure.Query.Query query)
        {
            throw new NotImplementedException();
        }
 
        /// <summary>
        /// 根据编号获得信息
        /// </summary>
        /// <param name="Keyid">编号</param>
        /// <returns></returns>
        public OA_StaffResume GetModelByKeyid(int? Keyid)
        {
            try
            {
                if (Keyid == null || Keyid < 0)
                    return null;//错误数据返会空 
 
                IList<OA_StaffResume> result = _dataBase.SelectModel<OA_StaffResume>(" * ", " OA_StaffResume ", string.Format(" Keyid='{0}'", Keyid)) as IList<OA_StaffResume>;//执行查询
 
                return (null == result || result.Count == 0) ? null : result[0];//返回结果
            }
            catch (Exception ex)
            {
                throw ex;
            }
        }
 
        /// <summary>
        /// 根据厂商编号获得信息
        /// </summary>
        /// <param name="Memberid">厂商编号</param>
        /// <returns></returns>
        public OA_StaffResume GetModelByMemberid(Guid Memberid)
        {
            try
            {
                if (Memberid == null || Memberid == Guid.Empty)
                    return null;//错误数据返会空 
 
                IList<OA_StaffResume> result = _dataBase.SelectModel<OA_StaffResume>(" * ", " OA_StaffResume ", string.Format(" Memberid='{0}'", Memberid)) as IList<OA_StaffResume>;//执行查询
 
                return (null == result || result.Count == 0) ? null : result[0];//返回结果
            }
            catch (Exception ex)
            {
                throw ex;
            }
        }
 
        /// <summary>
        /// 分页查询
        /// </summary>
        /// <param name="pagination"></param>
        /// <returns></returns>
        public IEnumerable<Model.OA_StaffResume> SelectModelPage(Infrastructure.Query.Pagination pagination, Guid _Memberid, string _R_G_Avatar, string _R_G_Name, string _R_G_Sex, string _R_G_WorkYear, string _R_G_Degree, string _R_G_DocumentsType, string _R_G_DocumentsNumber, string _R_G_Email, string _R_G_Moblie, string _R_G_WorkPhone, string _R_G_HomePhone, string _R_G_NowProvince, string _R_G_NowCity, string _R_G_NowArea, string _R_G_NowAddress, string _R_G_OldProvence, string _R_G_OldCity, string _R_G_OldArea, string _R_G_OldAdress, DateTime? _BeginR_G_CreatTime, DateTime? _EndR_G_CreatTime, int? _R_G_Language, string _R_G_YearsMoney, string _R_G_WorkStatus, string _R_G_QQ, string _R_G_YouHome, int? _R_G_YouHeight, int? _R_G_YouWeight, int? _R_G_MarryStatus, string _R_G_YouPolitical, int? _R_G_Status, int? _OrderNum, DateTime? _BeginLastUpdateTime, DateTime? _EndLastUpdateTime, string _Operator)
        {
            try
            {
                string condition = " 1=1 ";
 
                if (_Memberid != Guid.Empty)
                    condition += " and Memberid = '" + _Memberid + "' ";
 
                if (!string.IsNullOrEmpty(_R_G_Avatar))
                    condition += " and R_G_Avatar = '" + _R_G_Avatar + "' ";
 
                if (!string.IsNullOrEmpty(_R_G_Name))
                    condition += " and R_G_Name = '" + _R_G_Name + "' ";
 
                if (!string.IsNullOrEmpty(_R_G_Sex))
                    condition += " and R_G_Sex = '" + _R_G_Sex + "' ";
 
                if (!string.IsNullOrEmpty(_R_G_WorkYear))
                    condition += " and R_G_WorkYear = '" + _R_G_WorkYear + "' ";
 
                if (!string.IsNullOrEmpty(_R_G_Degree))
                    condition += " and R_G_Degree = '" + _R_G_Degree + "' ";
 
                if (!string.IsNullOrEmpty(_R_G_DocumentsType))
                    condition += " and R_G_DocumentsType = '" + _R_G_DocumentsType + "' ";
 
                if (!string.IsNullOrEmpty(_R_G_DocumentsNumber))
                    condition += " and R_G_DocumentsNumber = '" + _R_G_DocumentsNumber + "' ";
 
                if (!string.IsNullOrEmpty(_R_G_Email))
                    condition += " and R_G_Email = '" + _R_G_Email + "' ";
 
                if (!string.IsNullOrEmpty(_R_G_Moblie))
                    condition += " and R_G_Moblie = '" + _R_G_Moblie + "' ";
 
                if (!string.IsNullOrEmpty(_R_G_WorkPhone))
                    condition += " and R_G_WorkPhone = '" + _R_G_WorkPhone + "' ";
 
                if (!string.IsNullOrEmpty(_R_G_HomePhone))
                    condition += " and R_G_HomePhone = '" + _R_G_HomePhone + "' ";
 
                if (!string.IsNullOrEmpty(_R_G_NowProvince))
                    condition += " and R_G_NowProvince = '" + _R_G_NowProvince + "' ";
 
                if (!string.IsNullOrEmpty(_R_G_NowCity))
                    condition += " and R_G_NowCity = '" + _R_G_NowCity + "' ";
 
                if (!string.IsNullOrEmpty(_R_G_NowArea))
                    condition += " and R_G_NowArea = '" + _R_G_NowArea + "' ";
 
                if (!string.IsNullOrEmpty(_R_G_NowAddress))
                    condition += " and R_G_NowAddress = '" + _R_G_NowAddress + "' ";
 
                if (!string.IsNullOrEmpty(_R_G_OldProvence))
                    condition += " and R_G_OldProvence = '" + _R_G_OldProvence + "' ";
 
                if (!string.IsNullOrEmpty(_R_G_OldCity))
                    condition += " and R_G_OldCity = '" + _R_G_OldCity + "' ";
 
                if (!string.IsNullOrEmpty(_R_G_OldArea))
                    condition += " and R_G_OldArea = '" + _R_G_OldArea + "' ";
 
                if (!string.IsNullOrEmpty(_R_G_OldAdress))
                    condition += " and R_G_OldAdress = '" + _R_G_OldAdress + "' ";
 
                if (_BeginR_G_CreatTime.HasValue)
                    condition += string.Format(" and CAST(R_G_CreatTime AS DATE) >='{0}'", _BeginR_G_CreatTime);
 
                if (_EndR_G_CreatTime.HasValue)
                    condition += string.Format(" and CAST(R_G_CreatTime AS DATE) <='{0}'", _EndR_G_CreatTime);
 
                if (_R_G_Language.HasValue)
                    condition += " and R_G_Language = '" + _R_G_Language + "' ";
 
                if (!string.IsNullOrEmpty(_R_G_YearsMoney))
                    condition += " and R_G_YearsMoney = '" + _R_G_YearsMoney + "' ";
 
                if (!string.IsNullOrEmpty(_R_G_WorkStatus))
                    condition += " and R_G_WorkStatus = '" + _R_G_WorkStatus + "' ";
 
                if (!string.IsNullOrEmpty(_R_G_QQ))
                    condition += " and R_G_QQ = '" + _R_G_QQ + "' ";
 
                if (!string.IsNullOrEmpty(_R_G_YouHome))
                    condition += " and R_G_YouHome = '" + _R_G_YouHome + "' ";
 
                if (_R_G_YouHeight.HasValue)
                    condition += " and R_G_YouHeight = '" + _R_G_YouHeight + "' ";
 
                if (_R_G_YouWeight.HasValue)
                    condition += " and R_G_YouWeight = '" + _R_G_YouWeight + "' ";
 
                if (_R_G_MarryStatus.HasValue)
                    condition += " and R_G_MarryStatus = '" + _R_G_MarryStatus + "' ";
 
                if (!string.IsNullOrEmpty(_R_G_YouPolitical))
                    condition += " and R_G_YouPolitical = '" + _R_G_YouPolitical + "' ";
 
                if (_R_G_Status.HasValue)
                    condition += " and R_G_Status = '" + _R_G_Status + "' ";
 
                if (_OrderNum.HasValue)
                    condition += " and OrderNum = '" + _OrderNum + "' ";
 
                if (_BeginLastUpdateTime.HasValue)
                    condition += string.Format(" and CAST(LastUpdateTime AS DATE) >='{0}'", _BeginLastUpdateTime);
 
                if (_EndLastUpdateTime.HasValue)
                    condition += string.Format(" and CAST(LastUpdateTime AS DATE) <='{0}'", _EndLastUpdateTime);
 
                if (!string.IsNullOrEmpty(_Operator))
                    condition += " and Operator = '" + _Operator + "' ";
 
                return _dataBase.SelectModelPage<Model.OA_StaffResume>(pagination, " * ", " OA_StaffResume ", " Keyid desc", " Keyid desc ", condition);
            }
            catch (Exception ex)
            {
                throw ex;
            }
        }
 
        /// <summary>
        /// 分页查询
        /// </summary>
        /// <param name="pagination"></param>
        /// <returns></returns>
        public IEnumerable<Model.OA_StaffResume> SelectModelPage(Infrastructure.Query.Pagination pagination, DateTime? _BeginR_G_CreatTime, string _R_G_Sex, string _R_G_WorkYear, int? _R_I_Consultants_id, string _R_I_PostName)
        {
            try
            {
                string condition = " 1=1 ";
 
                if (!string.IsNullOrEmpty(_R_G_Sex))
                    condition += " and a.R_G_Sex = '" + _R_G_Sex + "' ";
 
                if (!string.IsNullOrEmpty(_R_G_WorkYear))
                    condition += " and a.R_G_WorkYear = '" + _R_G_WorkYear + "' ";
 
                if (_BeginR_G_CreatTime.HasValue)
                    condition += string.Format(" and CAST(a.R_G_CreatTime AS DATE) >='{0}' ", _BeginR_G_CreatTime);
 
 
                if (!string.IsNullOrEmpty(_R_I_PostName))
                    condition += " and b.R_I_PostName like '%" + _R_I_PostName + "%' ";
 
                if (_R_I_Consultants_id.HasValue)
                    condition += " and b.R_I_Consultants_id = '" + _R_I_Consultants_id + "' ";
 
                condition += " and a.R_G_Status = '1' ";
 
                return _dataBase.SelectModelPage<Model.OA_StaffResume>(pagination, " a.*,b.R_I_PostName as R_I_PostName,b.R_I_HopeMoney as R_I_HopeMoney ", " OA_StaffResume as a left join OA_StaffResumeIntention as b on a.Memberid = b.Memberid ", " a.Keyid desc", " Keyid desc ", condition);
            }
            catch (Exception ex)
            {
                throw ex;
            }
        }
    }
}