private string GetVendorName(int?vendorId) { var vendor = VendorDataProvider.GetVendor(graph, vendorId); return(vendor == null ? string.Empty : $"{vendor.AcctCD}-{vendor.AcctName}"); }
protected bool AreThereAnyLienWaiverRecipientsForVendorClass(int?vendorId, int?projectId) { var vendor = VendorDataProvider.GetVendor(Graph, vendorId); var lienWaiverRecipient = LienWaiverRecipientDataProvider.GetLienWaiverRecipient(Graph, vendor.VendorClassID, projectId); return(PXCache <Vendor> .GetExtension <VendorExtension>(vendor).ShouldGenerateLienWaivers == true && lienWaiverRecipient != null); }
private PXResultset <NotificationRecipient> GetNotificationRecipientsQuery( NotificationSource notificationSource, int?vendorId) { var classId = VendorDataProvider.GetVendor(PrintEmailLienWaiversProcess, vendorId).ClassID; return(SelectFrom <NotificationRecipient> .Where <NotificationRecipient.setupID.IsEqual <P.AsGuid> .And <NotificationRecipient.sourceID.IsEqual <P.AsInt> .Or <NotificationRecipient.classID.IsEqual <P.AsString> > > > .View .Select(PrintEmailLienWaiversProcess, notificationSource.SetupID, notificationSource.SourceID, classId)); }
protected bool DoesCommitmentAmountExceedMinimumCommitmentAmount(int?vendorId, APTran transaction) { var commitment = GetCommitment(transaction); if (commitment == null) { return(false); } var vendor = VendorDataProvider.GetVendor(Graph, vendorId); var projectId = LienWaiverProjectDataProvider.GetProjectId(Graph, transaction); var lienWaiverRecipient = LienWaiverRecipientDataProvider.GetLienWaiverRecipient(Graph, vendor.VendorClassID, projectId); return(commitment.CuryOrderTotal > lienWaiverRecipient.MinimumCommitmentAmount); }