summaryrefslogtreecommitdiff
path: root/Gestor.Application/Drawers/Ajuda
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.Application/Drawers/Ajuda
parent674ca83ba9243a9e95a7568c797668dab6aee26a (diff)
downloadgestor-1f4e14b2e973ee7de337fd4866d9a5ceff5cb6d1.tar.gz
gestor-1f4e14b2e973ee7de337fd4866d9a5ceff5cb6d1.zip
chore: location
Diffstat (limited to 'Gestor.Application/Drawers/Ajuda')
-rw-r--r--Gestor.Application/Drawers/Ajuda/BoletosNotasDrawerView.cs174
-rw-r--r--Gestor.Application/Drawers/Ajuda/ContratosDrawerView.cs69
-rw-r--r--Gestor.Application/Drawers/Ajuda/InstalacaoDrawerView.cs181
3 files changed, 0 insertions, 424 deletions
diff --git a/Gestor.Application/Drawers/Ajuda/BoletosNotasDrawerView.cs b/Gestor.Application/Drawers/Ajuda/BoletosNotasDrawerView.cs
deleted file mode 100644
index 5426bb0..0000000
--- a/Gestor.Application/Drawers/Ajuda/BoletosNotasDrawerView.cs
+++ /dev/null
@@ -1,174 +0,0 @@
-using Agger.Registro;
-using Gestor.Application.Helpers;
-using Gestor.Application.Model.Ajuda;
-using Gestor.Application.ViewModels.Drawer.Ajuda;
-using Gestor.Application.ViewModels.Generic;
-using Gestor.Application.Views.Generic;
-using System;
-using System.CodeDom.Compiler;
-using System.ComponentModel;
-using System.Diagnostics;
-using System.Runtime.CompilerServices;
-using System.Windows;
-using System.Windows.Controls;
-using System.Windows.Controls.Primitives;
-using System.Windows.Markup;
-
-namespace Gestor.Application.Drawers.Ajuda
-{
- public class BoletosNotasDrawerView : BaseUserControl, IComponentConnector, IStyleConnector
- {
- internal System.Windows.Controls.ProgressBar ProgressBar;
-
- internal ComboBox StatusCbo;
-
- internal DataGrid BoletosGrid;
-
- internal DataGridTemplateColumn BaixarBoletoColumn;
-
- internal DataGridTextColumn PagamentoColumn;
-
- internal ItemsControl BoletoDisponivel;
-
- internal TextBlock TxtBoletoDisponivel;
-
- private bool _contentLoaded;
-
- public BoletosNotasViewModel ViewModel
- {
- get;
- set;
- }
-
- public BoletosNotasDrawerView()
- {
- this.ViewModel = new BoletosNotasViewModel();
- base.DataContext = this.ViewModel;
- this.InitializeComponent();
- this.StatusCbo.SelectedIndex = 0;
- }
-
- private void ExibirBoleto_OnClick(object sender, RoutedEventArgs e)
- {
- Boleto selectedItem = (Boleto)this.BoletosGrid.SelectedItem;
- if ((selectedItem.Vencimento - Funcoes.GetNetworkTime()).TotalDays > 10)
- {
- return;
- }
- Process.Start(string.Format("{0}billet/id/{1}", Address.get_ApiBoletoAgger(), selectedItem.IdBoleto));
- }
-
- private void ExibirNota_OnClick(object sender, RoutedEventArgs e)
- {
- Process.Start(((Boleto)this.BoletosGrid.SelectedItem).Nota ?? "");
- }
-
- private void Fechar_OnClick(object sender, RoutedEventArgs e)
- {
- this.ViewModel.CloseDrawer();
- }
-
- [DebuggerNonUserCode]
- [GeneratedCode("PresentationBuildTasks", "4.0.0.0")]
- public void InitializeComponent()
- {
- if (this._contentLoaded)
- {
- return;
- }
- this._contentLoaded = true;
- System.Windows.Application.LoadComponent(this, new Uri("/Gestor.Application;component/drawers/ajuda/boletosnotasdrawerview.xaml", UriKind.Relative));
- }
-
- private void SelectedStatus_OnSelectionChanged(object sender, SelectionChangedEventArgs e)
- {
- if (this.StatusCbo.SelectedItem == null)
- {
- return;
- }
- this.ViewModel.WorkOnSelectedStatus(this.StatusCbo.SelectedItem.ToString());
- this.PagamentoColumn.Visibility = (this.StatusCbo.SelectedItem.ToString() == "PENDENTES" ? System.Windows.Visibility.Collapsed : System.Windows.Visibility.Visible);
- this.BaixarBoletoColumn.Visibility = (this.StatusCbo.SelectedItem.ToString() == "PENDENTES" ? System.Windows.Visibility.Visible : System.Windows.Visibility.Collapsed);
- this.BoletoDisponivel.Visibility = (this.StatusCbo.SelectedItem.ToString() == "PENDENTES" ? System.Windows.Visibility.Visible : System.Windows.Visibility.Collapsed);
- }
-
- [DebuggerNonUserCode]
- [EditorBrowsable(EditorBrowsableState.Never)]
- [GeneratedCode("PresentationBuildTasks", "4.0.0.0")]
- void System.Windows.Markup.IComponentConnector.Connect(int connectionId, object target)
- {
- switch (connectionId)
- {
- case 1:
- {
- this.ProgressBar = (System.Windows.Controls.ProgressBar)target;
- return;
- }
- case 2:
- {
- ((Button)target).Click += new RoutedEventHandler(this.Fechar_OnClick);
- return;
- }
- case 3:
- {
- this.StatusCbo = (ComboBox)target;
- this.StatusCbo.SelectionChanged += new SelectionChangedEventHandler(this.SelectedStatus_OnSelectionChanged);
- return;
- }
- case 4:
- {
- this.BoletosGrid = (DataGrid)target;
- return;
- }
- case 5:
- {
- this.BaixarBoletoColumn = (DataGridTemplateColumn)target;
- return;
- }
- case 6:
- case 7:
- {
- this._contentLoaded = true;
- return;
- }
- case 8:
- {
- this.PagamentoColumn = (DataGridTextColumn)target;
- return;
- }
- case 9:
- {
- this.BoletoDisponivel = (ItemsControl)target;
- return;
- }
- case 10:
- {
- this.TxtBoletoDisponivel = (TextBlock)target;
- return;
- }
- default:
- {
- this._contentLoaded = true;
- return;
- }
- }
- }
-
- [DebuggerNonUserCode]
- [EditorBrowsable(EditorBrowsableState.Never)]
- [GeneratedCode("PresentationBuildTasks", "4.0.0.0")]
- void System.Windows.Markup.IStyleConnector.Connect(int connectionId, object target)
- {
- if (connectionId == 6)
- {
- ((Button)target).Click += new RoutedEventHandler(this.ExibirBoleto_OnClick);
- return;
- }
- if (connectionId != 7)
- {
- return;
- }
- ((Button)target).Click += new RoutedEventHandler(this.ExibirNota_OnClick);
- }
- }
-} \ No newline at end of file
diff --git a/Gestor.Application/Drawers/Ajuda/ContratosDrawerView.cs b/Gestor.Application/Drawers/Ajuda/ContratosDrawerView.cs
deleted file mode 100644
index 3a3c153..0000000
--- a/Gestor.Application/Drawers/Ajuda/ContratosDrawerView.cs
+++ /dev/null
@@ -1,69 +0,0 @@
-using Gestor.Application.ViewModels.Drawer.Ajuda;
-using Gestor.Application.ViewModels.Generic;
-using Gestor.Application.Views.Generic;
-using System;
-using System.CodeDom.Compiler;
-using System.ComponentModel;
-using System.Diagnostics;
-using System.Runtime.CompilerServices;
-using System.Windows;
-using System.Windows.Controls;
-using System.Windows.Markup;
-
-namespace Gestor.Application.Drawers.Ajuda
-{
- public class ContratosDrawerView : BaseUserControl, IComponentConnector
- {
- internal DataGrid ContratosGrid;
-
- private bool _contentLoaded;
-
- public ContratosViewModel ViewModel
- {
- get;
- set;
- }
-
- public ContratosDrawerView()
- {
- this.ViewModel = new ContratosViewModel();
- base.DataContext = this.ViewModel;
- this.InitializeComponent();
- }
-
- private void Fechar_OnClick(object sender, RoutedEventArgs e)
- {
- this.ViewModel.CloseDrawer();
- }
-
- [DebuggerNonUserCode]
- [GeneratedCode("PresentationBuildTasks", "4.0.0.0")]
- public void InitializeComponent()
- {
- if (this._contentLoaded)
- {
- return;
- }
- this._contentLoaded = true;
- System.Windows.Application.LoadComponent(this, new Uri("/Gestor.Application;component/drawers/ajuda/contratosdrawerview.xaml", UriKind.Relative));
- }
-
- [DebuggerNonUserCode]
- [EditorBrowsable(EditorBrowsableState.Never)]
- [GeneratedCode("PresentationBuildTasks", "4.0.0.0")]
- void System.Windows.Markup.IComponentConnector.Connect(int connectionId, object target)
- {
- if (connectionId == 1)
- {
- ((Button)target).Click += new RoutedEventHandler(this.Fechar_OnClick);
- return;
- }
- if (connectionId != 2)
- {
- this._contentLoaded = true;
- return;
- }
- this.ContratosGrid = (DataGrid)target;
- }
- }
-} \ No newline at end of file
diff --git a/Gestor.Application/Drawers/Ajuda/InstalacaoDrawerView.cs b/Gestor.Application/Drawers/Ajuda/InstalacaoDrawerView.cs
deleted file mode 100644
index 9721288..0000000
--- a/Gestor.Application/Drawers/Ajuda/InstalacaoDrawerView.cs
+++ /dev/null
@@ -1,181 +0,0 @@
-using Gestor.Application.Model.Ajuda;
-using Gestor.Application.ViewModels.Drawer.Ajuda;
-using Gestor.Application.ViewModels.Generic;
-using Gestor.Application.Views.Generic;
-using Gestor.Common.Validation;
-using System;
-using System.CodeDom.Compiler;
-using System.Collections.Generic;
-using System.ComponentModel;
-using System.Diagnostics;
-using System.Runtime.CompilerServices;
-using System.Threading.Tasks;
-using System.Windows;
-using System.Windows.Controls;
-using System.Windows.Controls.Primitives;
-using System.Windows.Markup;
-
-namespace Gestor.Application.Drawers.Ajuda
-{
- public class InstalacaoDrawerView : BaseUserControl, IComponentConnector, IStyleConnector
- {
- internal System.Windows.Controls.ProgressBar ProgressBar;
-
- internal DataGrid GestorGrid;
-
- internal DataGrid AggilizadorGrid;
-
- private bool _contentLoaded;
-
- public InstalacaoViewModel ViewModel
- {
- get;
- set;
- }
-
- [DebuggerNonUserCode]
- [GeneratedCode("PresentationBuildTasks", "4.0.0.0")]
- internal Delegate _CreateDelegate(Type delegateType, string handler)
- {
- return Delegate.CreateDelegate(delegateType, this, handler);
- }
-
- public InstalacaoDrawerView()
- {
- this.ViewModel = new InstalacaoViewModel();
- base.DataContext = this.ViewModel;
- this.InitializeComponent();
- }
-
- private void AutoCompleteBox_OnTextChanged(object sender, RoutedEventArgs e)
- {
- if (!string.IsNullOrWhiteSpace(((AutoCompleteBox)sender).get_Text()))
- {
- return;
- }
- this.ViewModel.FiltrarInstalacao("");
- }
-
- private void AutoCompleteBox_Populating(object sender, PopulatingEventArgs e)
- {
- e.set_Cancel(true);
- this.ViewModel.Filtrar(ValidationHelper.RemoveDiacritics(e.get_Parameter().Trim())).ContinueWith((Task<List<Instalacao>> searchResult) => {
- if (searchResult.Result == null)
- {
- return;
- }
- AutoCompleteBox autoCompleteBox = (AutoCompleteBox)sender;
- autoCompleteBox.set_ItemsSource(searchResult.Result);
- autoCompleteBox.PopulateComplete();
- }, TaskScheduler.FromCurrentSynchronizationContext());
- }
-
- private async void ExcluirInstalacaoAggilizadorGrid_OnClick(object sender, RoutedEventArgs e)
- {
- Instalacao selectedItem;
- if (this.AggilizadorGrid.SelectedItem != null)
- {
- selectedItem = (Instalacao)this.AggilizadorGrid.SelectedItem;
- if (await this.ViewModel.ShowMessage(string.Concat("DESEJA REALMENTE EXCLUIR A INSTALAÇÃO DA MÁQUINA ", selectedItem.Maquina.ToUpper()), "SIM", "NÃO", false))
- {
- this.ViewModel.Excluir(selectedItem.Id);
- }
- }
- selectedItem = null;
- }
-
- private async void ExcluirInstalacaoGestorGrid_OnClick(object sender, RoutedEventArgs e)
- {
- Instalacao selectedItem;
- if (this.GestorGrid.SelectedItem != null)
- {
- selectedItem = (Instalacao)this.GestorGrid.SelectedItem;
- if (await this.ViewModel.ShowMessage(string.Concat("DESEJA REALMENTE EXCLUIR A INSTALAÇÃO DA MÁQUINA ", selectedItem.Maquina.ToUpper()), "SIM", "NÃO", false))
- {
- this.ViewModel.Excluir(selectedItem.Id);
- }
- }
- selectedItem = null;
- }
-
- private void Fechar_OnClick(object sender, RoutedEventArgs e)
- {
- this.ViewModel.CloseDrawer();
- }
-
- [DebuggerNonUserCode]
- [GeneratedCode("PresentationBuildTasks", "4.0.0.0")]
- public void InitializeComponent()
- {
- if (this._contentLoaded)
- {
- return;
- }
- this._contentLoaded = true;
- System.Windows.Application.LoadComponent(this, new Uri("/Gestor.Application;component/drawers/ajuda/instalacaodrawerview.xaml", UriKind.Relative));
- }
-
- [DebuggerNonUserCode]
- [EditorBrowsable(EditorBrowsableState.Never)]
- [GeneratedCode("PresentationBuildTasks", "4.0.0.0")]
- void System.Windows.Markup.IComponentConnector.Connect(int connectionId, object target)
- {
- switch (connectionId)
- {
- case 1:
- {
- this.ProgressBar = (System.Windows.Controls.ProgressBar)target;
- return;
- }
- case 2:
- {
- ((Button)target).Click += new RoutedEventHandler(this.Fechar_OnClick);
- return;
- }
- case 3:
- {
- ((AutoCompleteBox)target).add_Populating(new PopulatingEventHandler(this, InstalacaoDrawerView.AutoCompleteBox_Populating));
- ((AutoCompleteBox)target).add_TextChanged(new RoutedEventHandler(this.AutoCompleteBox_OnTextChanged));
- return;
- }
- case 4:
- {
- this.GestorGrid = (DataGrid)target;
- return;
- }
- case 5:
- {
- this._contentLoaded = true;
- return;
- }
- case 6:
- {
- this.AggilizadorGrid = (DataGrid)target;
- return;
- }
- default:
- {
- this._contentLoaded = true;
- return;
- }
- }
- }
-
- [DebuggerNonUserCode]
- [EditorBrowsable(EditorBrowsableState.Never)]
- [GeneratedCode("PresentationBuildTasks", "4.0.0.0")]
- void System.Windows.Markup.IStyleConnector.Connect(int connectionId, object target)
- {
- if (connectionId == 5)
- {
- ((Button)target).Click += new RoutedEventHandler(this.ExcluirInstalacaoGestorGrid_OnClick);
- return;
- }
- if (connectionId != 7)
- {
- return;
- }
- ((Button)target).Click += new RoutedEventHandler(this.ExcluirInstalacaoAggilizadorGrid_OnClick);
- }
- }
-} \ No newline at end of file