summaryrefslogtreecommitdiff
path: root/Gestor.Model/Model.Domain.Seguros/Consorcio.cs
diff options
context:
space:
mode:
authorLucas Faria Mendes <lucas.fariamo08@gmail.com>2026-03-30 13:38:18 +0000
committerLucas Faria Mendes <lucas.fariamo08@gmail.com>2026-03-30 13:38:18 +0000
commit1f4e14b2e973ee7de337fd4866d9a5ceff5cb6d1 (patch)
treee1c3b20ea08f0cf71122a1e73f0d395f8fd83874 /Gestor.Model/Model.Domain.Seguros/Consorcio.cs
parent674ca83ba9243a9e95a7568c797668dab6aee26a (diff)
downloadgestor-1f4e14b2e973ee7de337fd4866d9a5ceff5cb6d1.tar.gz
gestor-1f4e14b2e973ee7de337fd4866d9a5ceff5cb6d1.zip
chore: location
Diffstat (limited to 'Gestor.Model/Model.Domain.Seguros/Consorcio.cs')
-rw-r--r--Gestor.Model/Model.Domain.Seguros/Consorcio.cs191
1 files changed, 0 insertions, 191 deletions
diff --git a/Gestor.Model/Model.Domain.Seguros/Consorcio.cs b/Gestor.Model/Model.Domain.Seguros/Consorcio.cs
deleted file mode 100644
index 3efd5ad..0000000
--- a/Gestor.Model/Model.Domain.Seguros/Consorcio.cs
+++ /dev/null
@@ -1,191 +0,0 @@
-using Gestor.Model.Domain.Generic;
-using Gestor.Model.Helper;
-using Gestor.Model.Resources;
-using Newtonsoft.Json;
-using System;
-using System.Collections.Generic;
-using System.Collections.ObjectModel;
-using System.Globalization;
-using System.Runtime.CompilerServices;
-
-namespace Gestor.Model.Domain.Seguros
-{
- public class Consorcio : DomainBase, IDomain
- {
- private string _bensConsorcio;
-
- private string _grupo;
-
- private string _cota;
-
- private decimal? _valorCredito;
-
- private string _observacao;
-
- public string BensConsorcio
- {
- get
- {
- string str = this._bensConsorcio;
- if (str != null)
- {
- return str.ToUpper();
- }
- return null;
- }
- set
- {
- this._bensConsorcio = value;
- }
- }
-
- public string Cota
- {
- get
- {
- string str = this._cota;
- if (str != null)
- {
- return str.ToUpper();
- }
- return null;
- }
- set
- {
- this._cota = value;
- }
- }
-
- public string Grupo
- {
- get
- {
- string str = this._grupo;
- if (str != null)
- {
- return str.ToUpper();
- }
- return null;
- }
- set
- {
- this._grupo = value;
- }
- }
-
- public Gestor.Model.Domain.Seguros.Item Item
- {
- get;
- set;
- }
-
- public string Observacao
- {
- get
- {
- string str = this._observacao;
- if (str != null)
- {
- return str.ToUpper();
- }
- return null;
- }
- set
- {
- this._observacao = value;
- }
- }
-
- [JsonIgnore]
- public Func<List<KeyValuePair<string, string>>> ValidationEvent
- {
- get
- {
- Consorcio consorcio = this;
- return new Func<List<KeyValuePair<string, string>>>(consorcio.Validate);
- }
- }
-
- public decimal? ValorCredito
- {
- get
- {
- return this._valorCredito;
- }
- set
- {
- this._valorCredito = value;
- }
- }
-
- public Consorcio()
- {
- }
-
- public static List<TupleList> Log(Gestor.Model.Domain.Seguros.Item item)
- {
- decimal valueOrDefault;
- string str;
- List<TupleList> tupleLists = new List<TupleList>();
- TupleList tupleList = new TupleList();
- ObservableCollection<Tuple<string, string, string>> observableCollection = new ObservableCollection<Tuple<string, string, string>>()
- {
- new Tuple<string, string, string>("DESCRIÇÃO", (string.IsNullOrWhiteSpace(item.Consorcio.BensConsorcio) ? "" : item.Consorcio.BensConsorcio), ""),
- new Tuple<string, string, string>("GRUPO", (string.IsNullOrWhiteSpace(item.Consorcio.Grupo) ? "" : item.Consorcio.Grupo), ""),
- new Tuple<string, string, string>("COTA", (string.IsNullOrWhiteSpace(item.Consorcio.Cota) ? "" : item.Consorcio.Cota), "")
- };
- decimal? valorCredito = item.Consorcio.ValorCredito;
- if (!valorCredito.HasValue)
- {
- str = "";
- }
- else
- {
- valorCredito = item.Consorcio.ValorCredito;
- if (valorCredito.HasValue)
- {
- valueOrDefault = valorCredito.GetValueOrDefault();
- str = valueOrDefault.ToString("C", new CultureInfo("pt-BR", false));
- }
- else
- {
- str = null;
- }
- }
- observableCollection.Add(new Tuple<string, string, string>("GRUPO", str, ""));
- tupleList.Tuples = observableCollection;
- tupleLists.Add(tupleList);
- List<TupleList> tupleLists1 = tupleLists;
- ObservableCollection<Tuple<string, string, string>> observableCollection1 = new ObservableCollection<Tuple<string, string, string>>()
- {
- new Tuple<string, string, string>("COBERTURAS$", "", "")
- };
- foreach (Cobertura cobertura in item.Coberturas)
- {
- observableCollection1.Add(new Tuple<string, string, string>(string.Format(" COBERTURA {0}$", item.Coberturas.IndexOf(cobertura) + 1), "", ""));
- observableCollection1.Add(new Tuple<string, string, string>(" OBSERVAÇÃO", (string.IsNullOrWhiteSpace(cobertura.Observacao) ? "" : cobertura.Observacao.ToUpper()), ""));
- valueOrDefault = cobertura.Premio;
- observableCollection1.Add(new Tuple<string, string, string>(" PRÊMIO", valueOrDefault.ToString("C", new CultureInfo("pt-BR", false)), ""));
- valueOrDefault = cobertura.Franquia;
- observableCollection1.Add(new Tuple<string, string, string>(" FRANQUIA", valueOrDefault.ToString("C", new CultureInfo("pt-BR", false)), ""));
- valueOrDefault = cobertura.Lmi;
- observableCollection1.Add(new Tuple<string, string, string>(" L.M.I.", valueOrDefault.ToString("C", new CultureInfo("pt-BR", false)), ""));
- }
- tupleLists1.Add(new TupleList()
- {
- Tuples = observableCollection1
- });
- return tupleLists1;
- }
-
- public List<KeyValuePair<string, string>> Validate()
- {
- List<KeyValuePair<string, string>> keyValuePairs = ValidationHelper.AddValue();
- if (string.IsNullOrWhiteSpace(this.BensConsorcio))
- {
- keyValuePairs.AddValue<string, string>("BensConsorcio", Messages.Obrigatorio, true);
- }
- return keyValuePairs;
- }
- }
-} \ No newline at end of file