Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using Alphafolio.Tools.Configuration;
- using Alphafolio.Tools.Formatting;
- using System;
- using System.Linq;
- using System.Collections.Generic;
- namespace Alphafolio.DAL.Model
- {
- public partial class ContractCommitment
- {
- #region Contract
- public String EP_Code
- {
- get
- {
- return this.Contract.Code;
- }
- }
- public String EP_ContractContractor
- {
- get
- {
- return this.Contract?.EP_Contractor;
- }
- }
- public Guid? EP_ContractorId
- {
- get
- {
- return this.Contract?.EP_ContractorId;
- }
- }
- #endregion Contract
- public Decimal? EP_AmountUSD
- {
- get
- {
- if (this.Amount.HasValue && this.ExchangeRate.HasValue)
- return this.Amount * this.ExchangeRate;
- return null;
- }
- }
- public Decimal? EP_Contract_AmountUSD
- {
- get
- {
- Decimal? result = null;
- if (this.Contract != null)
- {
- result = this.Contract.EP_AmountUSD;
- }
- return result;
- }
- }
- public Decimal? EP_Contract_Amount
- {
- get
- {
- Decimal? result = null;
- if (this.Contract != null)
- {
- result = this.Contract.Amount;
- }
- return result;
- }
- }
- public Decimal? EP_Contract_ExchangeRate
- {
- get
- {
- Decimal? result = null;
- if (this.Contract != null)
- {
- result = this.Contract.ExchangeRate;
- }
- return result;
- }
- }
- public int? EP_Year
- {
- get
- {
- if (this.Date.HasValue == false)
- {
- return null;
- }
- return this.Date.Value.Year;
- }
- }
- public String EP_Trimester
- {
- get
- {
- String result = "";
- if (this.Date.HasValue == false)
- {
- return null;
- }
- if (this.Date.Value.Month == 1 || this.Date.Value.Month == 2 || this.Date.Value.Month == 3)
- {
- result = "T1";
- }
- if (this.Date.Value.Month == 4 || this.Date.Value.Month == 5 || this.Date.Value.Month == 6)
- {
- result = "T2";
- }
- if (this.Date.Value.Month == 7 || this.Date.Value.Month == 8 || this.Date.Value.Month == 9)
- {
- result = "T3";
- }
- if (this.Date.Value.Month == 110 || this.Date.Value.Month == 11 || this.Date.Value.Month == 12)
- {
- result = "T4";
- }
- return result;
- }
- }
- public decimal? EP_DifferenceUSD
- {
- set
- {
- EP_DifferenceUSD = 10;
- }
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement