本文整理汇总了C#中OpenCBS.CoreDomain.Contracts.Loans.Loan.PendingOrPostponed方法的典型用法代码示例。如果您正苦于以下问题:C# Loan.PendingOrPostponed方法的具体用法?C# Loan.PendingOrPostponed怎么用?C# Loan.PendingOrPostponed使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类OpenCBS.CoreDomain.Contracts.Loans.Loan
的用法示例。
在下文中一共展示了Loan.PendingOrPostponed方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: buttonCreditCommiteeSaveDecision_Click
private void buttonCreditCommiteeSaveDecision_Click(object sender, EventArgs e)
{
if (buttonCreditCommiteeSaveDecision.Text.Equals(GetString("update")))
{
EnableBoxCreditCommitteeComponents(true);
buttonCreditCommiteeSaveDecision.Enabled = true;
buttonCreditCommiteeSaveDecision.Text = GetString("save");
}
else
{
OContractStatus currentCreditStatus = OContractStatus.Pending;
OContractStatus currentGuaranteeStatus = OContractStatus.Pending;
try
{
if (_credit != null)
{
OContractStatus newStatus = GetNewStatusAndValidate(ref currentCreditStatus);
_credit.ContractStatus = newStatus;
_credit.CreditCommiteeComment = textBoxCreditCommiteeComment.Text;
_credit.CreditCommiteeDate = dateTimePickerCreditCommitee.Value;
_credit.CreditCommitteeCode = tBCreditCommitteeCode.Text;
IClient client = null;
if (_oClientType == OClientTypes.Corporate) client = _corporateUserControl.Corporate;
if (_oClientType == OClientTypes.Person) client = _personUserControl.Person;
if (_oClientType == OClientTypes.Group) client = _groupUserControl.Group;
if (OContractStatus.Refused == newStatus
|| OContractStatus.Abandoned == newStatus
|| OContractStatus.Closed == newStatus
|| OContractStatus.Deleted == newStatus)
{
_credit.Closed = true;
if (client != null)
{
if (client.ActiveLoans != null)
{
if (client.ActiveLoans.Count == 0)
{
client.Active = false;
client.Status = OClientStatus.Inactive;
}
}
}
// updating guarantor status
if (_listGuarantors != null && _listGuarantors.Count > 0)
{
foreach (Guarantor guarantor in _listGuarantors)
{
guarantor.Tiers.Active = false;
guarantor.Tiers.Status = OClientStatus.Inactive;
ServicesProvider.GetInstance().GetClientServices().UpdateClientStatus(guarantor.Tiers);
}
}
}
else
{
_credit.Closed = false;
if (client != null)
{
client.Active = true;
client.Status = OClientStatus.Active;
}
}
_credit = ServicesProvider.GetInstance().GetContractServices().
UpdateContractStatus(_credit, _project, client, currentCreditStatus == OContractStatus.Validated);
DisableCommitteeDecision(OContractStatus.Validated);
if (_credit.ContractStatus != OContractStatus.Validated)
{
var pendingOrPostponed = _credit.PendingOrPostponed();
if (!pendingOrPostponed)
ServicesProvider.GetInstance().GetContractServices().UpdateTiersStatus(_credit, client);
SetGuarantorsEnabled(pendingOrPostponed);
InitializeTabPageGuaranteesDetailsButtons(_credit.Product.UseGuarantorCollateral);
}
else
{
btnEditSchedule.Enabled = false;
InitializeTabPageGuaranteesDetailsButtons(_credit.Product.UseGuarantorCollateral);
DisableContractDetails(OContractStatus.Validated);
}
InitLoanDetails(false, _credit.Disbursed, _credit.ContractStatus == OContractStatus.Validated);
tabPageLoansDetails.Enabled = true;
if (_credit.PendingOrPostponed())
{
// Enable loan details components
InitializeAmount(_credit, false);
InitializePackageInterestRate(_credit, false);
InitializePackageGracePeriod(_credit.Product, false);
InitializePackageNumberOfInstallments(_credit, false);
cmbLoanOfficer.Enabled = true;
textBoxLoanPurpose.Enabled = true;
textBoxComments.Enabled = true;
//.........这里部分代码省略.........
示例2: InitializeTabPageLoansDetails
/// <summary>
/// The method initializes values of controls of the Details tab when a contract is creating
/// </summary>
/// <param name="pPackage">Loan product</param>
private void InitializeTabPageLoansDetails(LoanProduct pPackage)
{
_credit = new Loan(User.CurrentUser, ServicesProvider.GetInstance().GetGeneralSettings(),
ServicesProvider.GetInstance().GetNonWorkingDate(),
CoreDomainProvider.GetInstance().GetProvisioningTable(),
CoreDomainProvider.GetInstance().GetChartOfAccounts());
_credit.Product = pPackage;
nudLoanAmount.Text = string.Empty;
textBoxLoanContractCode.Text = string.Empty;
ReInitializeListViewInstallment();
pnlCCStatus.Enabled = true;
InitializeFundingLine();
InitializeInstallmentTypes();
InitializeLoanOfficer();
DisableContractDetails(_credit.ContractStatus);
SetPackageValuesForLoanDetails(_credit, true);
SetSecurityForTabPageLoansDetails(true);
InitLoanDetails(true, false, false);
InitializeTabPageGuaranteesDetailsButtons(_credit.Product.UseGuarantorCollateral);
cmbLoanOfficer.Enabled = true;
textBoxLoanPurpose.Enabled = true;
textBoxComments.Enabled = true;
listViewLoanInstallments.Items.Clear();
listViewGuarantors.Items.Clear();
lblCreditCurrency.Text = MultiLanguageStrings.GetString(Ressource.ClientForm, "Currency.Text") + pPackage.Currency.Name;
lbCompulsorySavings.Enabled = false;
InitializePackageLoanCompulsorySavings(pPackage, true);
btnEditSchedule.Visible = _credit.Product.AllowFlexibleSchedule;
btnEditSchedule.Enabled = ((_credit.ContractStatus == 0 || _credit.PendingOrPostponed()) && !_credit.Disbursed);
try
{
ServiceProvider.GetContractServices().ManualScheduleBeforeDisbursement();
}
catch (Exception)
{
btnEditSchedule.Enabled = false;
}
EnableLocAmountTextBox(_credit);
EnableInsuranceTextBox(_credit);
InitializeTabPageAdvancedSettings();
bool active = _credit != null && _credit.ContractStatus == OContractStatus.Active;
numCompulsoryAmountPercent.BackColor = pPackage.UseCompulsorySavings ? Color.White : Color.LightGray;
//InitializeCustomizableFields(OCustomizableFieldEntities.Loan, _credit.Id, active);
}
示例3: EnableLocAmountTextBox
private void EnableLocAmountTextBox(Loan credit)
{
if ((credit.PendingOrPostponed() || credit.ContractStatus == 0 || credit.Disbursed
|| credit.ContractStatus == OContractStatus.Validated) &&
(credit.Product.AmountUnderLocMin.HasValue && credit.Product.AmountUnderLocMax.HasValue))
tbLocAmount.Enabled = true;
else
tbLocAmount.Enabled = false;
if (credit.Product.AmountUnderLocMin.HasValue && credit.Product.AmountUnderLocMax.HasValue)
{
labelLocMaxAmount.Text = ServicesHelper.ConvertDecimalToString(credit.Product.AmountUnderLocMax.Value);
labelLocMinAmount.Text = ServicesHelper.ConvertDecimalToString(credit.Product.AmountUnderLocMin.Value);
if (!credit.AmountUnderLoc.HasValue)
tbLocAmount.Text = credit.Product.AmountUnderLocMax.GetFormatedValue(credit.UseCents);
lblLocCurrencyMin.Text = _credit.Product.Currency.Name;
lblLocCurrencyMax.Text = _credit.Product.Currency.Name;
lblLocCurrencyMin.Visible = true;
lblLocCurrencyMax.Visible = true;
labelLocMinAmount.Visible = true;
labelLocMaxAmount.Visible = true;
labelLocMin.Visible = true;
labelLocMax.Visible = true;
}
else if (credit.Product.AmountUnderLoc.HasValue)
{
tbLocAmount.Text = credit.Product.AmountUnderLoc.GetFormatedValue(credit.UseCents);
labelLocMaxAmount.Text = ServicesHelper.ConvertDecimalToString(credit.Product.AmountUnderLoc.Value);
labelLocMinAmount.Text = ServicesHelper.ConvertDecimalToString(credit.Product.AmountUnderLoc.Value);
lblLocCurrencyMin.Text = _credit.Product.Currency.Name;
lblLocCurrencyMax.Text = _credit.Product.Currency.Name;
lblLocCurrencyMin.Visible = true;
lblLocCurrencyMax.Visible = true;
labelLocMinAmount.Visible = true;
labelLocMaxAmount.Visible = true;
labelLocMin.Visible = true;
labelLocMax.Visible = true;
}
else
{
tbLocAmount.Enabled = false;
tbLocAmount.Text = "0";
}
}
示例4: EnableInsuranceTextBox
private void EnableInsuranceTextBox(Loan credit)
{
if (credit.PendingOrPostponed() || credit.ContractStatus == 0)
{
if (credit.Product.CreditInsuranceMin == credit.Product.CreditInsuranceMax)
tbInsurance.Enabled = false;
else tbInsurance.Enabled = true;
}
else
tbInsurance.Enabled = false;
}
示例5: SaveLoanApproval
private void SaveLoanApproval()
{
var currentCreditStatus = OContractStatus.Pending;
var currentGuaranteeStatus = OContractStatus.Pending;
try
{
if (_credit != null)
{
OContractStatus newStatus = _loanApprovalControl.Status;
_credit.ContractStatus = newStatus;
_credit.CreditCommiteeComment = _loanApprovalControl.Comment;
_credit.CreditCommiteeDate = _loanApprovalControl.Date;
_credit.CreditCommitteeCode = _loanApprovalControl.Code;
IClient client = null;
if (_oClientType == OClientTypes.Corporate) client = _corporateUserControl.Corporate;
if (_oClientType == OClientTypes.Person) client = _personUserControl.Person;
if (_oClientType == OClientTypes.Group) client = _groupUserControl.Group;
if (OContractStatus.Refused == newStatus
|| OContractStatus.Abandoned == newStatus
|| OContractStatus.Closed == newStatus
|| OContractStatus.Deleted == newStatus)
{
_credit.Closed = true;
if (client != null)
{
if (client.ActiveLoans != null)
{
if (client.ActiveLoans.Count == 0)
{
client.Active = false;
client.Status = OClientStatus.Inactive;
}
}
}
// updating guarantor status
if (_listGuarantors != null && _listGuarantors.Count > 0)
{
foreach (Guarantor guarantor in _listGuarantors)
{
guarantor.Tiers.Active = false;
guarantor.Tiers.Status = OClientStatus.Inactive;
ServicesProvider.GetInstance().GetClientServices().UpdateClientStatus(guarantor.Tiers);
}
}
}
else
{
_credit.Closed = false;
if (client != null)
{
client.Active = true;
client.Status = OClientStatus.Active;
}
}
_credit = ServicesProvider.GetInstance().GetContractServices().
UpdateContractStatus(_credit, _project, client, _credit.ContractStatus != OContractStatus.Validated);
if (_credit.ContractStatus != OContractStatus.Validated)
{
var pendingOrPostponed = _credit.PendingOrPostponed();
if (!pendingOrPostponed)
ServicesProvider.GetInstance().GetContractServices().UpdateTiersStatus(_credit, client);
SetGuarantorsEnabled(pendingOrPostponed);
InitializeTabPageGuaranteesDetailsButtons(_credit.Product.UseGuarantorCollateral);
}
else
{
btnEditSchedule.Enabled = false;
InitializeTabPageGuaranteesDetailsButtons(_credit.Product.UseGuarantorCollateral);
DisableContractDetails(OContractStatus.Validated);
}
InitLoanDetails(false, _credit.Disbursed, _credit.ContractStatus == OContractStatus.Validated);
tabPageLoansDetails.Enabled = true;
if (_credit.PendingOrPostponed())
{
// Enable loan details components
InitializeAmount(_credit, false);
InitializePackageInterestRate(_credit, false);
InitializePackageGracePeriod(_credit.Product, false);
InitializePackageNumberOfInstallments(_credit, false);
_loanOfficerComboBox.Enabled = true;
textBoxLoanPurpose.Enabled = true;
textBoxComments.Enabled = true;
comboBoxLoanFundingLine.Enabled = true;
// Advanced settings tab
EnableLocAmountTextBox(_credit);
EnableInsuranceTextBox(_credit);
groupBoxEntryFees.Enabled = true;
btnEditSchedule.Enabled = true;
InitializePackageAnticipatedTotalRepaymentsPenalties(_credit.Product, false);
InitializePackageAnticipatedPartialRepaymentsPenalties(_credit.Product, false);
InitializePackageNonRepaymentPenalties(_credit.Product, false);
}
//.........这里部分代码省略.........