protected void btnSave_Click(object sender, EventArgs e) { BusinessLayer.Common.MemberBill objBill = new BusinessLayer.Common.MemberBill(); Entity.Common.MemberBill bill = new Entity.Common.MemberBill(); bill.Month = Convert.ToInt32(ddlMonth.SelectedValue); bill.Year = Convert.ToInt32(ddlYear.SelectedValue); bill.MemberId = Convert.ToInt32(ddlMember.SelectedValue); bill.CreatedBy = Convert.ToInt32(Session["UserId"].ToString()); objBill.DevelopmentFeeGenerate(bill); Message.IsSuccess = true; Message.Text = "Bill Generated Successfully"; Message.Show = true; //LoadDevelopmentFeeDetails(); }
private void GoDevelopmentFeeGenerate() { DateTime dateTime = DateTime.Now.AddHours(12).AddMinutes(30); Entity.Common.MemberBill bill = new Entity.Common.MemberBill(); bill.Month = dateTime.Month; bill.Year = dateTime.Year; bill.MemberId = 0; bill.CreatedBy = Convert.ToInt32(Session["UserId"].ToString()); //Int32.Parse(Context.User.Identity.Name); BusinessLayer.Common.MemberBill objBill = new BusinessLayer.Common.MemberBill(); bool IsGenerate = objBill.CheckingDevelopmentFeeGeneration(bill); if (IsGenerate == false) { objBill.DevelopmentFeeGenerate(bill); BusinessLayer.Common.FeeNotification notification = new BusinessLayer.Common.FeeNotification(); notification.MailToMember(); } }