Tipo de persona Ventas Pv
This commit is contained in:
@@ -1690,7 +1690,7 @@ Public Class ClsClientes
|
||||
.Add("@CveFormaPago33", SqlDbType.Int).Value = CveFormaPago33
|
||||
.Add("@NumCuentaPago", SqlDbType.VarChar).Value = NumCuentaPago
|
||||
.Add("@CvePrecioLista", SqlDbType.Int).Value = CvePrecioLista
|
||||
.Add("@CvePrecioLista", SqlDbType.VarChar).Value = RegimenSociedad
|
||||
.Add("@RegimenSociedad", SqlDbType.VarChar).Value = RegimenSociedad
|
||||
.Add("@TipoPersona", SqlDbType.Bit).Value = TipoPersona
|
||||
|
||||
End With
|
||||
|
||||
@@ -1074,7 +1074,7 @@ Public Class ClsContPAQi
|
||||
StrSQL.AppendLine(" INNER JOIN Polizas p ON mp.IdPoliza = p.Id ")
|
||||
StrSQL.AppendLine(" INNER JOIN Cuentas c ON c.Id = mp.IdCuenta ")
|
||||
StrSQL.AppendLine(" INNER JOIN TiposPolizas t ON mp.TipoPol = t.Codigo ")
|
||||
StrSQL.AppendLine(" LEFT JOIN SERVIDOR.Ventas.dbo.Usuarios U ON U.CveUsuario = P.IdUsuario ")
|
||||
StrSQL.AppendLine(" LEFT JOIN SIG_Resp_2022_04_01.dbo.Usuarios U ON U.CveUsuario = P.IdUsuario ")
|
||||
StrSQL.AppendLine(" LEFT JOIN SegmentosNegocio s ON mp.IdSegNeg = s.id ")
|
||||
StrSQL.AppendLine(" WHERE (@IdPoliza = -1 OR mp.IdPoliza = @IdPoliza) ")
|
||||
StrSQL.AppendLine(" AND (@Eje = -1 OR mp.Ejercicio = @Eje) ")
|
||||
|
||||
@@ -2452,10 +2452,7 @@
|
||||
<div class="modal-dialog" style="max-height: 500px; max-width: 500px;">
|
||||
<asp:UpdatePanel ID="UpAgregarCliente" class="modal-content rowpadding" tabindex="-1" runat="server" UpdateMode="Conditional">
|
||||
<ContentTemplate>
|
||||
<fieldset>
|
||||
<%--<legend><b>Descripción</b></legend>--%>
|
||||
<table border="0" class="portlet light bordered">
|
||||
<tr>
|
||||
|
||||
|
||||
<div class="portlet-title">
|
||||
<div class="caption font-green">
|
||||
@@ -2469,10 +2466,8 @@
|
||||
</div>
|
||||
|
||||
|
||||
</tr>
|
||||
<tr>
|
||||
|
||||
|
||||
|
||||
<div class="modal-body">
|
||||
<div class="row" style="padding-left: 16px;">
|
||||
<div class="form-group form-md-line-input input-iconright col-xs-9">
|
||||
<asp:TextBox ID="TxtRFCCliente" Text="XAXX010101000" Style="text-transform: uppercase;" placeholder="Ingrese el RFC para su validación" runat="server" CssClass="form-control" MaxLength="13" CausesValidation="true"></asp:TextBox>
|
||||
@@ -2489,19 +2484,12 @@
|
||||
<div class="col-md-12">
|
||||
|
||||
|
||||
<div runat="server" id="DivTipoPersona" class="form-group form-md-line-input input-iconright">
|
||||
<div runat="server" id="DivTipoPersona" visible="false" class="form-group form-md-line-input input-iconright">
|
||||
|
||||
<%-- <asp:RadioButtonList runat="server" ID="RdTipoPersona" RepeatDirection="Horizontal" OnSelectedIndexChanged="RdTipoPersona_SelectedIndexChanged" AutoPostBack="true" CssClass="form-control input-sm">
|
||||
<asp:RadioButtonList runat="server" ID="RdTipoPersona" RepeatDirection="Horizontal" OnSelectedIndexChanged="RdTipoPersona_SelectedIndexChanged" AutoPostBack="true" CssClass="form-control">
|
||||
<asp:ListItem Value="0">Física</asp:ListItem>
|
||||
<asp:ListItem Value="1">Moral</asp:ListItem>
|
||||
</asp:RadioButtonList>--%>
|
||||
|
||||
|
||||
<asp:DropDownList runat="server" ID="RdTipoPersona" OnSelectedIndexChanged="RdTipoPersona_SelectedIndexChanged" AutoPostBack="true" CssClass="form-control input-sm select2me">
|
||||
<asp:ListItem Value="0">Física</asp:ListItem>
|
||||
<asp:ListItem Value="1">Moral</asp:ListItem>
|
||||
</asp:DropDownList>
|
||||
|
||||
</asp:RadioButtonList>
|
||||
|
||||
<label for="<%= RdTipoPersona.ClientID.ToString()%>">Tipo Persona:</label>
|
||||
<i></i>
|
||||
@@ -2630,12 +2618,17 @@
|
||||
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
</fieldset>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<div id="DivBotonesAgregarCliente" runat="server" visible="false" class="modal-footer">
|
||||
<asp:Button ID="BtnAgregarCliente" runat="server" CssClass="btn btn-primary" Text="Agregar" ValidationGroup="GrpGuardarCliente" />
|
||||
<button id="BtnCancelarCliente" runat="server" type="button" class="btn default" data-dismiss="modal">Cancelar</button>
|
||||
|
||||
@@ -7274,10 +7274,7 @@
|
||||
<div class="modal-dialog" style="max-height: 500px; max-width: 500px;">
|
||||
<asp:UpdatePanel ID="UpAgregarCliente" class="modal-content rowpadding" tabindex="-1" runat="server" UpdateMode="Conditional">
|
||||
<ContentTemplate>
|
||||
<fieldset>
|
||||
<%--<legend><b>Descripción</b></legend>--%>
|
||||
<table border="0" class="portlet light bordered">
|
||||
<tr>
|
||||
|
||||
<div class="portlet-title">
|
||||
<div class="caption font-green">
|
||||
<i class="fa fa-users font-green"></i>
|
||||
@@ -7288,8 +7285,16 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</tr>
|
||||
<tr>
|
||||
|
||||
|
||||
|
||||
<div class="modal-body">
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<div class="row" style="padding-left: 16px;">
|
||||
<div class="form-group form-md-line-input input-iconright col-xs-9">
|
||||
<asp:TextBox ID="TxtRFCCliente" Style="text-transform: uppercase;" placeholder="Ingrese el RFC para su validación" runat="server" CssClass="form-control" MaxLength="13" CausesValidation="true"></asp:TextBox>
|
||||
@@ -7300,11 +7305,50 @@
|
||||
<asp:Button ID="BtnValidarRFC" runat="server" CssClass="btn btn-success" Text="Validar" />
|
||||
</div>
|
||||
</div>
|
||||
<div id="DivNombreCliente" runat="server" visible="false" class="form-group form-md-line-input input-iconright">
|
||||
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
|
||||
|
||||
<div runat="server" id="DivTipoPersona" visible="false" class="form-group form-md-line-input input-iconright">
|
||||
|
||||
<asp:RadioButtonList runat="server" ID="RdTipoPersona" RepeatDirection="Horizontal" OnSelectedIndexChanged="RdTipoPersona_SelectedIndexChanged" AutoPostBack="true" CssClass="form-control">
|
||||
<asp:ListItem Value="0">Física</asp:ListItem>
|
||||
<asp:ListItem Value="1">Moral</asp:ListItem>
|
||||
</asp:RadioButtonList>
|
||||
|
||||
<label for="<%= RdTipoPersona.ClientID.ToString()%>">Tipo Persona:</label>
|
||||
<i></i>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
<%--<div id="DivNombreCliente" runat="server" visible="false" class="form-group form-md-line-input input-iconright">
|
||||
<asp:TextBox ID="TxtNombreCliente" CssClass="form-control " runat="server" MaxLength="150" CausesValidation="true"></asp:TextBox>
|
||||
<asp:RequiredFieldValidator ID="RFVNombreCliente" runat="server" ControlToValidate="TxtNombreCliente" CssClass="help-block errorimput" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Nombre''</b> es necesario, por favor ingréselo." ValidationGroup="GrpGuardarCliente"></asp:RequiredFieldValidator>
|
||||
<label for="<%= TxtNombreCliente.ClientID.ToString()%>">Razón Social:</label>
|
||||
</div>--%>
|
||||
|
||||
<div class="row">
|
||||
<div class="col-md-12" runat="server" id="DivRazonSocial2">
|
||||
<div id="DivNombreCliente" runat="server" visible="false" class="form-group form-md-line-input input-iconright">
|
||||
<asp:TextBox ID="TxtNombreCliente" CssClass="form-control " runat="server" MaxLength="50" CausesValidation="true"></asp:TextBox>
|
||||
<asp:RequiredFieldValidator ID="RFVNombreCliente" runat="server" ControlToValidate="TxtNombreCliente" CssClass="help-block errorimput" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Nombre''</b> es necesario, por favor ingréselo." ValidationGroup="GrpGuardarCliente"></asp:RequiredFieldValidator>
|
||||
<label for="<%= TxtNombreCliente.ClientID.ToString()%>">Razón Social:</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4" id="DVRegimenSociedad" runat="server" visible="false">
|
||||
<div runat="server" class="form-group form-md-line-input input-iconright">
|
||||
<asp:TextBox ID="TxtRegimenSociedad" CssClass="form-control " runat="server" MaxLength="50" onkeyup="fncTxt()" ClientIDMode="Static"></asp:TextBox>
|
||||
<label for="<%= TxtRegimenSociedad.ClientID.ToString()%>">Regimen Sociedad:</label>
|
||||
<i></i>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="DivDireccionCliente" runat="server" visible="false" class="form-group form-md-line-input input-iconright">
|
||||
<asp:TextBox ID="TxtDireccionCliente" CssClass="form-control " runat="server" MaxLength="90" CausesValidation="true"></asp:TextBox>
|
||||
<asp:RequiredFieldValidator ID="RFVDireccionC" runat="server" ControlToValidate="TxtDireccionCliente" CssClass="help-block errorimput" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Direccion''</b> es necesario, por favor ingréselo." ValidationGroup="GrpGuardarCliente"></asp:RequiredFieldValidator>
|
||||
@@ -7398,12 +7442,13 @@
|
||||
<label for="<%= DdlFormaCliente.ClientID.ToString()%>">Forma Pago: </label>
|
||||
<i></i>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</tr>
|
||||
</table>
|
||||
</fieldset>
|
||||
|
||||
|
||||
|
||||
|
||||
<div id="DivBotonesAgregarCliente" runat="server" visible="false" class="modal-footer">
|
||||
<asp:Button ID="BtnAgregarCliente" runat="server" CssClass="btn btn-primary" Text="Agregar" ValidationGroup="GrpGuardarCliente" />
|
||||
<button id="BtnCancelarCliente" runat="server" type="button" class="btn default" data-dismiss="modal">Cancelar</button>
|
||||
|
||||
@@ -22238,6 +22238,7 @@ Partial Class Ventas
|
||||
|
||||
Private Sub LnkAgregarCliente_Click(sender As Object, e As EventArgs) Handles LnkAgregarCliente.Click
|
||||
DivNombreCliente.Visible = False
|
||||
DivTipoPersona.Visible = False
|
||||
DivDireccionCliente.Visible = False
|
||||
DivNumeroCPCliente.Visible = False
|
||||
DivColoniaTelefonoCliente.Visible = False
|
||||
@@ -22256,6 +22257,7 @@ Partial Class Ventas
|
||||
|
||||
If TxtRFCCliente.Text.ToUpper = "XAXX010101000" Then
|
||||
DivNombreCliente.Visible = True
|
||||
DivTipoPersona.Visible = True
|
||||
DivDireccionCliente.Visible = True
|
||||
DivNumeroCPCliente.Visible = True
|
||||
DivColoniaTelefonoCliente.Visible = True
|
||||
@@ -22285,6 +22287,7 @@ Partial Class Ventas
|
||||
UpCliente.Update()
|
||||
Else
|
||||
DivNombreCliente.Visible = True
|
||||
DivTipoPersona.Visible = True
|
||||
DivDireccionCliente.Visible = True
|
||||
DivNumeroCPCliente.Visible = True
|
||||
DivColoniaTelefonoCliente.Visible = True
|
||||
@@ -22324,10 +22327,14 @@ Partial Class Ventas
|
||||
|
||||
Dim ObjCliente As New ClsClientes
|
||||
|
||||
Dim TipoPersona As Boolean = If(RdTipoPersona.SelectedValue.ToEntero = 1, True, False)
|
||||
|
||||
If ObjCliente.AgregarClienteNoFrecuente(TxtNombreCliente.Text.Trim, TxtDireccionCliente.Text.Trim, TxtNumExtCliente.Text.Trim, TxtNumIntCliente.Text.Trim,
|
||||
TxtColoniaCliente.Text.Trim, TxtLocalidadCliente.Text.Trim, TxtCiudadCliente.Text.Trim, DdlEstadoSAT.SelectedValue.ToEntero,
|
||||
TxtRFCCliente.Text.Trim, TxtCPCliente.Text.Trim, TxtTelefonoCliente.Text.Trim, TxtCorreoCliente.Text.Trim,
|
||||
DdlSubProyectoDatos.SelectedValue.ToEntero(), UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, "", -1, -1, CvePrecioLista:=CvePrecioLista) Then
|
||||
DdlSubProyectoDatos.SelectedValue.ToEntero(), UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, "", -1, -1, CvePrecioLista:=CvePrecioLista,
|
||||
RegimenSociedad:=TxtRegimenSociedad.Text, TipoPersona:=TipoPersona) Then
|
||||
|
||||
If ObjCliente.DtResultados.Rows.Count > 0 Then
|
||||
RegistraScript("hideDivEC();")
|
||||
ViewState("CveCliente") = ObjCliente.DtResultados(0)("CveCliente").ToString().ToEntero()
|
||||
@@ -33831,5 +33838,20 @@ Partial Class Ventas
|
||||
End If
|
||||
|
||||
End Sub
|
||||
|
||||
Protected Sub RdTipoPersona_SelectedIndexChanged(sender As Object, e As EventArgs)
|
||||
|
||||
DVRegimenSociedad.Visible = False
|
||||
DivRazonSocial2.Attributes.Add("class", "col-md-12")
|
||||
|
||||
If RdTipoPersona.SelectedValue.ToEntero = 1 And UsuarioActual.Empresa.Funcionalidad(350) = "1" Then
|
||||
|
||||
DivRazonSocial2.Attributes.Add("class", "col-md-8")
|
||||
DVRegimenSociedad.Visible = True
|
||||
|
||||
End If
|
||||
|
||||
UpAgregarCliente.Update()
|
||||
End Sub
|
||||
End Class
|
||||
|
||||
|
||||
Reference in New Issue
Block a user