Exemplo n.º 1
0
 protected void grvSoleVendorRequestList_RowDataBound(object sender, GridViewRowEventArgs e)
 {
     if (e.Row.DataItem != null)
     {
         SoleVendorRequest soleVendorRequest = e.Row.DataItem as SoleVendorRequest;
         if (soleVendorRequest.CurrentStatus == "Rejected")
         {
             e.Row.ForeColor = System.Drawing.Color.Red;
         }
     }
 }
        public void SaveOrUpdateSoleVendorRequest(int PRID)
        {
            PurchaseRequest   thePurchaseRequest = _controller.GetPurchaseRequestbyPuID(PRID).PurchaseRequest;
            SoleVendorRequest soleVendorRequest  = CurrentSoleVendorRequest;

            soleVendorRequest.PurchaseRequest = thePurchaseRequest;
            soleVendorRequest.RequestNo       = View.GetRequestNo;
            soleVendorRequest.RequestDate     = Convert.ToDateTime(DateTime.Today);
            soleVendorRequest.Comment         = View.GetComment;
            soleVendorRequest.AppUser         = _adminController.GetUser(CurrentUser().Id);
            soleVendorRequest.ProgressStatus  = ProgressStatus.InProgress.ToString();

            if (CurrentSoleVendorRequest.SoleVendorRequestStatuses.Count == 0)
            {
                SaveSoleVendorRequestStatus();
            }
            GetCurrentApprover();

            _controller.SaveOrUpdateEntity(soleVendorRequest);
            _controller.CurrentObject = null;
            //Notify the Purchase requester that bid process is initiated
            SendEmailToRequester();
        }
        public void SaveOrUpdateSoleVendorRequest()
        {
            SoleVendorRequest soleVendorRequest = CurrentSoleVendorRequest;

            soleVendorRequest.RequestNo              = View.GetRequestNo;
            soleVendorRequest.RequestDate            = Convert.ToDateTime(DateTime.Today);
            soleVendorRequest.ContactPersonNumber    = View.GetContactPersonNumber;
            soleVendorRequest.ProposedPurchasedPrice = View.GetProposedPurchasedPrice;
            //  if (View.GetProposedSupplier != 0)
            soleVendorRequest.Supplier = _settingController.GetSupplier(View.GetProposedSupplier);
            soleVendorRequest.SoleSourceJustificationPreparedBy = View.GetSoleSourceJustificationPreparedBy;
            soleVendorRequest.SoleVendorJustificationType       = View.GetSoleVendorJustificationType;
            soleVendorRequest.Comment        = View.GetComment;
            soleVendorRequest.ProgressStatus = ProgressStatus.InProgress.ToString();
            if (View.GetProjectId != 0)
            {
                soleVendorRequest.Project = _settingController.GetProject(View.GetProjectId);
            }
            if (View.GetGrantId != 0)
            {
                soleVendorRequest.Grant = _settingController.GetGrant(View.GetGrantId);
            }
            //_settingController.GetGrant(View.GetGrantId);
            soleVendorRequest.AppUser = _adminController.GetUser(CurrentUser().Id);

            if (CurrentSoleVendorRequest.SoleVendorRequestStatuses.Count == 0)
            {
                SaveSoleVendorRequestStatus();
            }
            GetCurrentApprover();

            soleVendorRequest.PurchaseRequest = _controller.GetPurchaseRequest(View.GetPurchaseRequestId);

            _controller.SaveOrUpdateEntity(soleVendorRequest);
            _controller.CurrentObject = null;
        }
Exemplo n.º 4
0
 public void DeleteSoleVendorRequest(SoleVendorRequest SoleVendorRequest)
 {
     _controller.DeleteEntity(SoleVendorRequest);
 }
Exemplo n.º 5
0
 public void SaveOrUpdateSoleVendorRequest(SoleVendorRequest SoleVendorRequest)
 {
     _controller.SaveOrUpdateEntity(SoleVendorRequest);
 }