public void SaveOrUpdateCostSharingRequest()
        {
            CostSharingRequest CostSharingRequest = CurrentCostSharingRequest;

            CostSharingRequest.RequestNo            = View.GetRequestNo;
            CostSharingRequest.RequestDate          = Convert.ToDateTime(DateTime.Today.ToShortDateString());
            CostSharingRequest.Payee                = View.GetPayee;
            CostSharingRequest.Description          = View.GetDescription;
            CostSharingRequest.EstimatedTotalAmount = View.EstimatedTotalAmount;
            CostSharingRequest.ItemAccount          = _settingController.GetItemAccount(View.ItemAccountId);
            CostSharingRequest.VoucherNo            = View.GetVoucherNo;
            CostSharingRequest.PaymentMethod        = View.GetPaymentMethod;
            CostSharingRequest.ProgressStatus       = ProgressStatus.InProgress.ToString();
            CostSharingRequest.AppUser              = _adminController.GetUser(CurrentUser().Id);
            if (View.GetAmountType != "Actual Amount")
            {
                CostSharingRequest.PaymentReimbursementStatus = "Not Retired";
            }
            else
            {
                CostSharingRequest.PaymentReimbursementStatus = "Retired";
                CostSharingRequest.ActualTotalAmount          = CostSharingRequest.EstimatedTotalAmount;
            }

            CostSharingRequest.ExportStatus = "Not Exported";
            if (CurrentCostSharingRequest.CostSharingRequestStatuses.Count == 0)
            {
                SaveCostSharingRequestStatus();
            }

            SaveCostSharingDetail();
        }
Esempio n. 2
0
 public ItemAccount GetItemAccount(int ItemAccountId)
 {
     return(_settingController.GetItemAccount(ItemAccountId));
 }
 public ItemAccount GetItemAccountById(int id)
 {
     return(_controller.GetItemAccount(id));
 }