You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
71 lines
1.9 KiB
71 lines
1.9 KiB
using EasyBL.WebApi.Message;
|
|
using EasyBL.WEBAPP.WSM;
|
|
using Entity.Sugar;
|
|
using Entity.ViewModels;
|
|
using SqlSugar;
|
|
using SqlSugar.Base;
|
|
using System;
|
|
using System.Collections.Generic;
|
|
|
|
namespace EasyBL.WEBAPP.SYS
|
|
{
|
|
public class BookingItemMaintain_QryService : ServiceBase
|
|
{
|
|
|
|
#region 預訂項目管理(以 ID 查詢)
|
|
|
|
/// <summary>
|
|
/// 預訂項目管理(以 ID 查詢)
|
|
/// </summary>
|
|
/// <param name="i_crm"></param>
|
|
/// <returns></returns>
|
|
///
|
|
|
|
public List<SETB_SAL_Booking_Item> QueryByIDs(RequestMessage i_crm, string sBookingID) {
|
|
|
|
|
|
|
|
ResponseMessage rm = null;
|
|
string sMsg = null;
|
|
var db = SugarBase.GetIntance();
|
|
|
|
var saItemList = new List<SETB_SAL_Booking_Item>();
|
|
|
|
try
|
|
{
|
|
do
|
|
{
|
|
|
|
saItemList = db.Queryable<SETB_SAL_Booking_Item>()
|
|
.Where(t1 => t1.OrgID == i_crm.ORIGID && t1.DelStatus != "Y")
|
|
.Where(t1 => t1.Effective == "Y")
|
|
.Where(t1 => t1.BookingID == sBookingID).ToList();
|
|
|
|
rm = new SuccessResponseMessage(null, i_crm);
|
|
rm.DATA.Add(BLWording.REL, saItemList);
|
|
|
|
} while (false);
|
|
}
|
|
catch (Exception ex)
|
|
{
|
|
sMsg = Util.GetLastExceptionMsg(ex);
|
|
LogAndSendEmail(sMsg + "Params:" + JsonToString(i_crm), ex, i_crm.ORIGID, i_crm.USERID, nameof(BookingMaintain_QryService), "", "QueryByIDs 預訂項目管理(以 ID 查詢)", "", "", "");
|
|
}
|
|
finally
|
|
{
|
|
if (null != sMsg)
|
|
{
|
|
rm = new ErrorResponseMessage(sMsg, i_crm);
|
|
}
|
|
}
|
|
|
|
|
|
|
|
return saItemList;
|
|
|
|
}
|
|
|
|
#endregion 預訂項目管理(以 ID 查詢)
|
|
|
|
}
|
|
}
|