AsistenteConfigIdDespacho.cs
3 using sage.ew.ewbase;
4 using sage.ew.functions;
5 using System;
6 using System.Collections.Generic;
7 using System.ComponentModel;
8 using System.Data;
9 using System.Drawing;
10 using System.Linq;
11 using System.Text;
12 using System.Windows.Forms;
13 
14 namespace sage.addons.portalcli.Visual.UserControls
15 {
19  public partial class AsistenteConfigIdDespacho : UserControl
20  {
21  #region PROPIEDADES
22 
26  public string _IdDespacho
27  {
28  get { return txtIdentificador.Text.Trim(); }
29  }
30 
34  public string _Error_Message { get; set; }
35 
39  private CfgPortalCli _oPortalCli
40  {
41  get { return ((FormAsistentePortal)this.FindForm())._PortalCli; }
42  }
43 
44  #endregion PROPIEDADES
45 
46 
47  #region CONSTRUCTOR
48 
53  {
54  InitializeComponent();
55  }
56 
57  #endregion CONSTRUCTOR
58 
59 
60  #region METODOS
61 
67  private void AsistenteConfigIdDespacho_Load(object sender, EventArgs e)
68  {
69  // Cargar Datos
70  txtIdentificador.Text = _oPortalCli._CfgConnect._IdDespacho;
71  txtIdentificador.ReadOnly = !string.IsNullOrWhiteSpace(txtIdentificador.Text);
72  }
73 
78  public bool _Valid()
79  {
80  if (string.IsNullOrWhiteSpace(_IdDespacho))
81  {
82  FUNCTIONS._MessageBox("Para poder seguir con el asistente debe indicar el identificador del despacho.", "Asistente de configuración", MessageBoxButtons.OK, MessageBoxIcon.Information);
83  return false;
84  }
85 
86  _oPortalCli._CfgConnect._IdDespacho = _IdDespacho;
87 
88  // Tenemos que guardarlo, ya que la primera vez que se configura hay algun caso donde se necesita el id despacho y aún no está disponible.
89  return _Save();
90  }
91 
96  public bool _Save()
97  {
98  bool llOk = true;
99 
100  llOk = _oPortalCli._CfgConnect._Save();
101  if (!llOk)
102  _Error_Message = _oPortalCli._CfgConnect._MensajeError;
103 
104  return llOk;
105  }
106 
112  private void linkLabelSageConecta_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
113  {
114  System.Diagnostics.Process.Start("https://www.sageconecta.com/url-register-client");
115  }
116 
117  #endregion METODOS
118 
119 
120  }
121 }
Este es el espacio de nombres de su módulo. Puede encontrar más información y ayuda en el fichero rea...
Usercontrol para la página del IDENTIFICADOR DESPACHO
Asistente para la configuración acceso Portal Cliente con Sage Despachos
Clase principal de configuraciones para el Add-on del Portal del Cliente Contendrá instancias a las c...
Definition: CfgPortalCli.cs:14
bool _Valid()
Método para realizar validaciones antes se salir de la página