This commit is contained in:
@@ -583,10 +583,23 @@
|
|||||||
<tr>
|
<tr>
|
||||||
<td style="width: 730px"> </td>
|
<td style="width: 730px"> </td>
|
||||||
<th style="width: 90px;">
|
<th style="width: 90px;">
|
||||||
<asp:TextBox ID="TxtTotalCargos" runat="server" Style="text-align: right" Enabled="false" Width="90px" Text="0.00"></asp:TextBox></th>
|
<asp:UpdatePanel ID="UpTotalCargo" runat="server" UpdateMode="Conditional">
|
||||||
|
<ContentTemplate>
|
||||||
|
<asp:TextBox ID="TxtTotalCargos" runat="server" Style="text-align: right" Enabled="false" Width="90px" Text="0.00"></asp:TextBox>
|
||||||
|
</ContentTemplate>
|
||||||
|
</asp:UpdatePanel>
|
||||||
|
</th>
|
||||||
<th style="width: 90px;">
|
<th style="width: 90px;">
|
||||||
<asp:TextBox ID="TxtTotalAbonos" runat="server" Style="text-align: right" Enabled="false" Width="90px" Text="0.00"></asp:TextBox></th>
|
<asp:UpdatePanel ID="UpTotalAbono" runat="server" UpdateMode="Conditional">
|
||||||
|
<ContentTemplate>
|
||||||
|
<asp:TextBox ID="TxtTotalAbonos" runat="server" Style="text-align: right" Enabled="false" Width="90px" Text="0.00"></asp:TextBox>
|
||||||
|
|
||||||
|
</ContentTemplate>
|
||||||
|
|
||||||
|
</asp:UpdatePanel>
|
||||||
|
</th>
|
||||||
<asp:HiddenField ID="HdnTotales" runat="server" ClientIDMode="Static" />
|
<asp:HiddenField ID="HdnTotales" runat="server" ClientIDMode="Static" />
|
||||||
|
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<td colspan="3" style="text-align: center;">
|
<td colspan="3" style="text-align: center;">
|
||||||
@@ -770,7 +783,7 @@
|
|||||||
Cargo:
|
Cargo:
|
||||||
</div>
|
</div>
|
||||||
<div class="col-xs-3">
|
<div class="col-xs-3">
|
||||||
<asp:TextBox ID="TxtCargoE" runat="server" CssClass=" txtcargo form-control input-sm" Style="text-align: right"></asp:TextBox><br />
|
<asp:TextBox ID="TxtCargoE" runat="server" CssClass=" form-control input-sm" Style="text-align: right"></asp:TextBox><br />
|
||||||
<asp:CompareValidator ID="CVCargo" runat="server" ControlToValidate="TxtCargo" Display="None" ErrorMessage="El campo <b>''Cargo''</b> no tiene el formato correcto, por favor corrija e intente de nuevo (Solo formato numérico)." Operator="DataTypeCheck" Type="Currency" ValidationGroup="GrpGuardar"></asp:CompareValidator>
|
<asp:CompareValidator ID="CVCargo" runat="server" ControlToValidate="TxtCargo" Display="None" ErrorMessage="El campo <b>''Cargo''</b> no tiene el formato correcto, por favor corrija e intente de nuevo (Solo formato numérico)." Operator="DataTypeCheck" Type="Currency" ValidationGroup="GrpGuardar"></asp:CompareValidator>
|
||||||
<ajax:ValidatorCalloutExtender ID="VCCCargo" runat="server" HighlightCssClass="vco" TargetControlID="CVCargo" Width="300px"></ajax:ValidatorCalloutExtender>
|
<ajax:ValidatorCalloutExtender ID="VCCCargo" runat="server" HighlightCssClass="vco" TargetControlID="CVCargo" Width="300px"></ajax:ValidatorCalloutExtender>
|
||||||
</div>
|
</div>
|
||||||
@@ -778,7 +791,7 @@
|
|||||||
Abono:
|
Abono:
|
||||||
</div>
|
</div>
|
||||||
<div class="col-xs-3">
|
<div class="col-xs-3">
|
||||||
<asp:TextBox ID="TxtAbonoE" runat="server" CssClass=" txtabono form-control input-sm" Style="text-align: right"></asp:TextBox><br />
|
<asp:TextBox ID="TxtAbonoE" runat="server" CssClass=" form-control input-sm" Style="text-align: right"></asp:TextBox><br />
|
||||||
<asp:CompareValidator ID="CVAbono" runat="server" ControlToValidate="TxtAbono" Display="None" ErrorMessage="El campo <b>''Abono''</b> no tiene el formato correcto, por favor corrija e intente de nuevo (Solo formato numérico)." Operator="DataTypeCheck" Type="Currency" ValidationGroup="GrpGuardar"></asp:CompareValidator>
|
<asp:CompareValidator ID="CVAbono" runat="server" ControlToValidate="TxtAbono" Display="None" ErrorMessage="El campo <b>''Abono''</b> no tiene el formato correcto, por favor corrija e intente de nuevo (Solo formato numérico)." Operator="DataTypeCheck" Type="Currency" ValidationGroup="GrpGuardar"></asp:CompareValidator>
|
||||||
<ajax:ValidatorCalloutExtender ID="VCCAbono" runat="server" HighlightCssClass="vco" TargetControlID="CVAbono" Width="300px"></ajax:ValidatorCalloutExtender>
|
<ajax:ValidatorCalloutExtender ID="VCCAbono" runat="server" HighlightCssClass="vco" TargetControlID="CVAbono" Width="300px"></ajax:ValidatorCalloutExtender>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -188,6 +188,15 @@ Partial Class ContabilidadC_RegPrePolizaS
|
|||||||
End Set
|
End Set
|
||||||
End Property
|
End Property
|
||||||
|
|
||||||
|
Public Property IDMovEditar As Integer
|
||||||
|
Get
|
||||||
|
Return CType(ViewState("IDMovEditar"), Integer)
|
||||||
|
End Get
|
||||||
|
Set(value As Integer)
|
||||||
|
ViewState("IDMovEditar") = value
|
||||||
|
End Set
|
||||||
|
End Property
|
||||||
|
|
||||||
Public Property TipoPoliza As String
|
Public Property TipoPoliza As String
|
||||||
Get
|
Get
|
||||||
Return CType(ViewState("TipoPoliza"), String)
|
Return CType(ViewState("TipoPoliza"), String)
|
||||||
@@ -318,11 +327,10 @@ Partial Class ContabilidadC_RegPrePolizaS
|
|||||||
.Add("IdCtaContable", Type.GetType("System.Int32"))
|
.Add("IdCtaContable", Type.GetType("System.Int32"))
|
||||||
.Add("ConceptoContable", Type.GetType("System.String"))
|
.Add("ConceptoContable", Type.GetType("System.String"))
|
||||||
.Add("CveCuenta", Type.GetType("System.Int32"))
|
.Add("CveCuenta", Type.GetType("System.Int32"))
|
||||||
|
|
||||||
.Add("ContadoTipoTransaccion", Type.GetType("System.Int32"))
|
.Add("ContadoTipoTransaccion", Type.GetType("System.Int32"))
|
||||||
.Add("ContadoCuenta", Type.GetType("System.Int32"))
|
.Add("ContadoCuenta", Type.GetType("System.Int32"))
|
||||||
.Add("ContadoNumeroFolio", Type.GetType("System.Int32"))
|
.Add("ContadoNumeroFolio", Type.GetType("System.String"))
|
||||||
.Add("ContadoImporte", Type.GetType("System.Int32"))
|
.Add("ContadoImporte", Type.GetType("System.Dou"))
|
||||||
.Add("ContadoBeneficiario", Type.GetType("System.String"))
|
.Add("ContadoBeneficiario", Type.GetType("System.String"))
|
||||||
.Add("ContadoObservaciones", Type.GetType("System.String"))
|
.Add("ContadoObservaciones", Type.GetType("System.String"))
|
||||||
|
|
||||||
@@ -826,8 +834,8 @@ Partial Class ContabilidadC_RegPrePolizaS
|
|||||||
If e.Row.DataKey("CveConcepto").ToEntero.Contiene(30) Then
|
If e.Row.DataKey("CveConcepto").ToEntero.Contiene(30) Then
|
||||||
e.Row.FCLinkButton("ImgBancos").Visible = True
|
e.Row.FCLinkButton("ImgBancos").Visible = True
|
||||||
|
|
||||||
|
If e.Row.DataKey("ContadoTipoTransaccion").ToEntero > 0 And e.Row.DataKey("ContadoCuenta").ToEntero > 0 And e.Row.DataKey("ContadoNumeroFolio").ToString.Length > 0 And
|
||||||
If CveTipoTransaccion > 0 And CveCuenta > 0 And Folio.Length > 0 And ImporteDocumento > 0 And Beneficiario.Length > 0 Then
|
e.Row.DataKey("ContadoImporte").ToEntero > 0 And e.Row.DataKey("ContadoBeneficiario").ToString.Length > 0 Then
|
||||||
e.Row.FCLinkButton("ImgBancos").CssClass = "btn btn-circle btn-sm green"
|
e.Row.FCLinkButton("ImgBancos").CssClass = "btn btn-circle btn-sm green"
|
||||||
End If
|
End If
|
||||||
End If
|
End If
|
||||||
@@ -887,6 +895,7 @@ Partial Class ContabilidadC_RegPrePolizaS
|
|||||||
|
|
||||||
'Registra movimieno bancario
|
'Registra movimieno bancario
|
||||||
If gvr.DataKey("CveConcepto").ToEntero = 30 Then
|
If gvr.DataKey("CveConcepto").ToEntero = 30 Then
|
||||||
|
|
||||||
CveIE = ObjIE.AddBancos_IE(gvr.DataKey("ContadoCuenta").ToEntero, gvr.DataKey("ContadoTipoTransaccion").ToEntero, TxtFecha.Text, gvr.DataKey("ContadoNumeroFolio").ToString,
|
CveIE = ObjIE.AddBancos_IE(gvr.DataKey("ContadoCuenta").ToEntero, gvr.DataKey("ContadoTipoTransaccion").ToEntero, TxtFecha.Text, gvr.DataKey("ContadoNumeroFolio").ToString,
|
||||||
gvr.DataKey("ContadoBeneficiario").ToString, gvr.DataKey("ContadoImporte").ToString.ToDecimal, CveMoneda, 0, gvr.DataKey("ContadoObservaciones").ToString, "",
|
gvr.DataKey("ContadoBeneficiario").ToString, gvr.DataKey("ContadoImporte").ToString.ToDecimal, CveMoneda, 0, gvr.DataKey("ContadoObservaciones").ToString, "",
|
||||||
False, False, 0, CvePrePoliza, "", UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa)
|
False, False, 0, CvePrePoliza, "", UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa)
|
||||||
@@ -1273,8 +1282,6 @@ Partial Class ContabilidadC_RegPrePolizaS
|
|||||||
dr("FolioFactura") = If(DdlComprasE.Visible = True, DdlComprasE.SelectedItem.ToString, If(DdlVentasE.Visible = True, DdlVentasE.SelectedItem.ToString, ""))
|
dr("FolioFactura") = If(DdlComprasE.Visible = True, DdlComprasE.SelectedItem.ToString, If(DdlVentasE.Visible = True, DdlVentasE.SelectedItem.ToString, ""))
|
||||||
|
|
||||||
|
|
||||||
TxtTotalAbonos.Text = (TxtTotalAbonos.Text.ToDouble + TxtAbonoE.Text.ToDouble).ToString.FormatoNumero
|
|
||||||
TxtTotalCargos.Text = (TxtTotalCargos.Text.ToDouble + TxtCargoE.Text.ToDouble).ToString.FormatoNumero
|
|
||||||
DtMovimientos.Rows.Add(dr)
|
DtMovimientos.Rows.Add(dr)
|
||||||
DtMovimientos.AcceptChanges()
|
DtMovimientos.AcceptChanges()
|
||||||
|
|
||||||
@@ -1283,6 +1290,11 @@ Partial Class ContabilidadC_RegPrePolizaS
|
|||||||
GvPrePoliza.DataBind()
|
GvPrePoliza.DataBind()
|
||||||
UpPrePoliza.Update()
|
UpPrePoliza.Update()
|
||||||
End If
|
End If
|
||||||
|
|
||||||
|
TxtTotalCargos.Text = DtMovimientos.SUMD("Cargo").ToString.FormatoNumero
|
||||||
|
TxtTotalAbonos.Text = DtMovimientos.SUMD("Abono").ToString.FormatoNumero
|
||||||
|
UpTotalCargo.Update()
|
||||||
|
UpTotalAbono.Update()
|
||||||
Else
|
Else
|
||||||
'Dim dr As DataRow = DtMovimientos.NewRow
|
'Dim dr As DataRow = DtMovimientos.NewRow
|
||||||
'Dim CodigoCuenta As String = ""
|
'Dim CodigoCuenta As String = ""
|
||||||
@@ -1372,8 +1384,7 @@ Partial Class ContabilidadC_RegPrePolizaS
|
|||||||
dr("Cargo") = "".ToDouble
|
dr("Cargo") = "".ToDouble
|
||||||
End If
|
End If
|
||||||
|
|
||||||
TxtTotalAbonos.Text = (TxtTotalAbonos.Text.ToDouble + TxtAbonoE.Text.ToDouble).ToString.FormatoNumero
|
|
||||||
TxtTotalCargos.Text = (TxtTotalCargos.Text.ToDouble + TxtCargoE.Text.ToDouble).ToString.FormatoNumero
|
|
||||||
DtMovimientos.AcceptChanges()
|
DtMovimientos.AcceptChanges()
|
||||||
GvPrePoliza.EditIndex = -1
|
GvPrePoliza.EditIndex = -1
|
||||||
|
|
||||||
@@ -1383,11 +1394,17 @@ Partial Class ContabilidadC_RegPrePolizaS
|
|||||||
UpPrePoliza.Update()
|
UpPrePoliza.Update()
|
||||||
End If
|
End If
|
||||||
GvPrePoliza.Columns(11).Visible = True
|
GvPrePoliza.Columns(11).Visible = True
|
||||||
|
|
||||||
GvPrePoliza.Rows(IndiceGrid).FCCheckBox("chkModificado").Checked = True
|
GvPrePoliza.Rows(IndiceGrid).FCCheckBox("chkModificado").Checked = True
|
||||||
|
|
||||||
|
TxtTotalCargos.Text = DtMovimientos.SUMD("Cargo").ToString.FormatoNumero
|
||||||
|
TxtTotalAbonos.Text = DtMovimientos.SUMD("Abono").ToString.FormatoNumero
|
||||||
|
UpTotalCargo.Update()
|
||||||
|
UpTotalAbono.Update()
|
||||||
|
|
||||||
End If
|
End If
|
||||||
End If
|
End If
|
||||||
|
|
||||||
|
|
||||||
UpPrePoliza.Update()
|
UpPrePoliza.Update()
|
||||||
RegistraScript("$('#DivEditConcepto').modal('hide')", "hidemodal")
|
RegistraScript("$('#DivEditConcepto').modal('hide')", "hidemodal")
|
||||||
End Sub
|
End Sub
|
||||||
@@ -1563,13 +1580,13 @@ Partial Class ContabilidadC_RegPrePolizaS
|
|||||||
|
|
||||||
Dim IdMov As Integer = GvRow.DataKey("IdMov").ToString.ToEntero
|
Dim IdMov As Integer = GvRow.DataKey("IdMov").ToString.ToEntero
|
||||||
Dim Rows As DataRow() = DtMovimientos.Select("IdMov = " & IdMov)
|
Dim Rows As DataRow() = DtMovimientos.Select("IdMov = " & IdMov)
|
||||||
|
IDMovEditar = IdMov
|
||||||
|
|
||||||
If Rows.Count > 0 Then
|
If Rows.Count > 0 Then
|
||||||
Dim dr As DataRow = Rows(0)
|
Dim dr As DataRow = Rows(0)
|
||||||
Dim folio As Integer = dr("ContadoTipoTransaccion").ToString.ToEntero
|
|
||||||
DdlTipoTransaccion.SelectedValueExist(dr("ContadoTipoTransaccion").ToString.ToEntero)
|
DdlTipoTransaccion.SelectedValueExist(dr("ContadoTipoTransaccion").ToString.ToEntero)
|
||||||
DdlCuenta.SelectedValueExist(dr("ContadoCuenta").ToString.ToEntero)
|
DdlCuenta.SelectedValueExist(dr("ContadoCuenta").ToString.ToEntero)
|
||||||
TxtDocumentoFolio.Text = dr("ContadoNumeroFolio").ToString.ToEntero
|
TxtDocumentoFolio.Text = dr("ContadoNumeroFolio").ToString
|
||||||
TxtDocumentoObservaciones.Text = dr("ContadoObservaciones").ToString
|
TxtDocumentoObservaciones.Text = dr("ContadoObservaciones").ToString
|
||||||
TxtDocumentoBeneficiario.Text = dr("ContadoBeneficiario").ToString
|
TxtDocumentoBeneficiario.Text = dr("ContadoBeneficiario").ToString
|
||||||
End If
|
End If
|
||||||
@@ -1591,13 +1608,30 @@ Partial Class ContabilidadC_RegPrePolizaS
|
|||||||
DdlCuenta.Items.Insert(0, New ListItem("Seleccione", "-1"))
|
DdlCuenta.Items.Insert(0, New ListItem("Seleccione", "-1"))
|
||||||
End Sub
|
End Sub
|
||||||
Private Sub BtnContado_Click(sender As Object, e As EventArgs) Handles BtnContado.Click
|
Private Sub BtnContado_Click(sender As Object, e As EventArgs) Handles BtnContado.Click
|
||||||
CveConcepto = 30
|
Dim Rows As DataRow() = DtMovimientos.Select("IdMov = " & IDMovEditar)
|
||||||
CveTipoTransaccion = DdlTipoTransaccion.SelectedValue.ToEntero
|
|
||||||
CveCuenta = DdlCuenta.SelectedValue.ToEntero
|
If Rows.Count > 0 Then
|
||||||
Folio = TxtDocumentoFolio.Text
|
Dim dr As DataRow = Rows(0)
|
||||||
ImporteDocumento = TxtDocumentoImporte.Text.ToDecimal
|
|
||||||
Observaciones = TxtDocumentoObservaciones.Text
|
|
||||||
Beneficiario = TxtDocumentoBeneficiario.Text
|
dr("ContadoTipoTransaccion") = DdlTipoTransaccion.SelectedValue.ToEntero
|
||||||
|
dr("ContadoCuenta") = DdlCuenta.SelectedValue.ToEntero
|
||||||
|
dr("ContadoNumeroFolio") = TxtDocumentoFolio.Text
|
||||||
|
dr("ContadoImporte") = TxtDocumentoImporte.Text.ToDecimal
|
||||||
|
dr("ContadoBeneficiario") = TxtDocumentoBeneficiario.Text
|
||||||
|
dr("ContadoObservaciones") = TxtDocumentoObservaciones.Text
|
||||||
|
End If
|
||||||
|
DtMovimientos.AcceptChanges()
|
||||||
|
GvMov.DataSource = DtMovimientos
|
||||||
|
GvMov.DataBind()
|
||||||
|
'CveTipoTransaccion = DdlTipoTransaccion.SelectedValue.ToEntero
|
||||||
|
'CveCuenta = DdlCuenta.SelectedValue.ToEntero
|
||||||
|
'Folio = TxtDocumentoFolio.Text
|
||||||
|
'ImporteDocumento = TxtDocumentoImporte.Text.ToDecimal
|
||||||
|
'Observaciones = TxtDocumentoObservaciones.Text
|
||||||
|
'Beneficiario = TxtDocumentoBeneficiario.Text
|
||||||
|
|
||||||
|
|
||||||
RegistraScript(String.Format("$('#{0}').modal('hide');", "DivContadoModal"))
|
RegistraScript(String.Format("$('#{0}').modal('hide');", "DivContadoModal"))
|
||||||
GvMov.Rows(RowIndex).FCLinkButton("ImgBancos").CssClass = "btn btn-circle btn-sm green"
|
GvMov.Rows(RowIndex).FCLinkButton("ImgBancos").CssClass = "btn btn-circle btn-sm green"
|
||||||
UPMovs.Update()
|
UPMovs.Update()
|
||||||
@@ -2008,10 +2042,10 @@ Partial Class ContabilidadC_RegPrePolizaS
|
|||||||
DdlCuenta.SelectedValue = CveBancoCuenta
|
DdlCuenta.SelectedValue = CveBancoCuenta
|
||||||
End If
|
End If
|
||||||
TipoMov = GlobalDTTipoTransacciones.FiltroPrimeroValor("CveTipoTransaccion", String.Format("TipoTransaccion = '{0}' ", Row("TipoTransferencia"))).ToEntero
|
TipoMov = GlobalDTTipoTransacciones.FiltroPrimeroValor("CveTipoTransaccion", String.Format("TipoTransaccion = '{0}' ", Row("TipoTransferencia"))).ToEntero
|
||||||
FolioExcel = Row("Folio").ToString.ToEntero
|
FolioExcel = Row("Folio").ToString
|
||||||
CveTipoTransaccion = TipoMov
|
CveTipoTransaccion = TipoMov
|
||||||
CveCuenta = CveBancoCuenta
|
CveCuenta = CveBancoCuenta
|
||||||
Folio = Row("Folio").ToString.ToEntero
|
Folio = FolioExcel
|
||||||
ImporteDocumento = IIf(Row("Abono").ToString.ToEntero > 0, Row("Abono").ToString, Row("Cargo").ToString)
|
ImporteDocumento = IIf(Row("Abono").ToString.ToEntero > 0, Row("Abono").ToString, Row("Cargo").ToString)
|
||||||
Observaciones = Row("Referencia").ToString
|
Observaciones = Row("Referencia").ToString
|
||||||
Beneficiario = Row("Concepto").ToString
|
Beneficiario = Row("Concepto").ToString
|
||||||
|
|||||||
Reference in New Issue
Block a user