Merge branch 'master' of http://agonzalez@192.168.10.111:8383/SIG.git
This commit is contained in:
@@ -5745,8 +5745,8 @@ Partial Class Ventas
|
||||
Dim Cantidad, PU, Descuento, CantidadInventario As Decimal
|
||||
Dim CuentaPredial As String
|
||||
Cantidad = GvPS.Rows(e.RowIndex).FCTextBox("TxtCantidad").Text.ToDecimal
|
||||
PU = Math.Round(GvPS.Rows(e.RowIndex).FCTextBox("TxtPrecio").Text.ToDecimal, 6)
|
||||
Descuento = Math.Round(GvPS.Rows(e.RowIndex).FCTextBox("TxtDescuento").Text.ToDecimal, NumeroDecimales)
|
||||
PU = (GvPS.Rows(e.RowIndex).FCTextBox("TxtPrecio").Text.ToDecimal).RoundSQL(6)
|
||||
Descuento = (GvPS.Rows(e.RowIndex).FCTextBox("TxtDescuento").Text.ToDecimal).RoundSQL(NumeroDecimales)
|
||||
CuentaPredial = GvPS.Rows(e.RowIndex).FCTextBox("TxtPredial").Text.Trim
|
||||
|
||||
Dim CantidadOriginal As Decimal = GvPS.Rows(e.RowIndex).DataKey("Cantidad").ToDecimal()
|
||||
@@ -14128,7 +14128,7 @@ Partial Class Ventas
|
||||
Dim Row As DataRow = Nothing
|
||||
Dim TotalCalculableImpuestos As Decimal = 0
|
||||
Dim TotalCalculableImpuestosIVA As Decimal = 0
|
||||
PU = Math.Round(PU, 6) ' el precio unitario puede llevar hasta 6 decimales permitidos
|
||||
PU = PU.RoundSQL(6) ' el precio unitario puede llevar hasta 6 decimales permitidos
|
||||
|
||||
Row = TmpDT.NewRow()
|
||||
Row("CveProyecto") = CveProyecto
|
||||
|
||||
@@ -62,9 +62,16 @@ Public Class WsTSoft
|
||||
Dim ObjGPS As New ClsGPS
|
||||
Dim Continuar As Boolean = ObjGPS.UltimaPosicionEquipoGetWS(DevID)
|
||||
Dim ObjPos As New LatLng
|
||||
If Continuar Then
|
||||
If Continuar Then
|
||||
'CONSULTA DIRECCIONES
|
||||
Dim Direcciones As JArray = ConsultarDirecciones(ObjGPS.DtResultados, "Lat", "Lng")
|
||||
For Each Dir As JObject In Direcciones
|
||||
ObjGPS.DtResultados.Rows(Dir("Indice").ToEntero())("Direccion") = Dir("Direccion").ToString()
|
||||
Next
|
||||
|
||||
ObjPos.Lat = ObjGPS.DtResultados.Rows("0")("Lat").ToString
|
||||
ObjPos.Lng = ObjGPS.DtResultados.Rows("0")("Lng").ToString
|
||||
ObjPos.Lng = ObjGPS.DtResultados.Rows("0")("Lng").ToString
|
||||
ObjPos.Direccion = ObjGPS.DtResultados.Rows("0")("Direccion").ToString
|
||||
Else
|
||||
ObjPos.CurrentError = "No se pudo obtener la posición."
|
||||
End If
|
||||
@@ -95,8 +102,17 @@ Public Class WsTSoft
|
||||
Dim objTsoft As New ClsTSoft
|
||||
Dim Continuar As Boolean = objTsoft.GETRemisionesHistorial(FolioRemision, NoEconomico)
|
||||
Dim objRem As New GetRemisionHistorialesObj
|
||||
If Continuar Then
|
||||
objRem.Historial = objTsoft.DtResultados.DataTableToObject(Of GetRemisionHistorialsObj)
|
||||
If Continuar Then
|
||||
Dim Dt = objTsoft.DtResultados.Copy()
|
||||
Dt.Columns.Add("Direccion", GetType(String))
|
||||
|
||||
'CONSULTA DIRECCIONES
|
||||
Dim Direcciones As JArray = ConsultarDirecciones(Dt, "Lat", "Lon")
|
||||
For Each Dir As JObject In Direcciones
|
||||
Dt.Rows(Dir("Indice").ToEntero())("Direccion") = Dir("Direccion").ToString()
|
||||
Next
|
||||
|
||||
objRem.Historial = Dt.DataTableToObject(Of GetRemisionHistorialsObj)
|
||||
objRem.CurrentError = ""
|
||||
Else
|
||||
objRem.Historial = New List(Of GetRemisionHistorialsObj)
|
||||
@@ -149,15 +165,15 @@ Public Class WsTSoft
|
||||
End Function
|
||||
|
||||
|
||||
Public Function ConsultarDirecciones(Dt As DataTable) As JArray
|
||||
Public Function ConsultarDirecciones(Dt As DataTable, Optional LatName As String = "Latitud", Optional LonName As String = "Longitud") As JArray
|
||||
Dim retorno As JArray = Nothing
|
||||
Dim posicionesArray = New JArray(From Row As DataRow In Dt
|
||||
Let index = Dt.Rows().IndexOf(Row)
|
||||
Select New JObject(
|
||||
New JProperty("indice", index),
|
||||
New JProperty("cveTrama", -1),
|
||||
New JProperty("lat", Row("Latitud").ToString.ToDouble),
|
||||
New JProperty("lon", Row("Longitud").ToString.ToDouble)
|
||||
New JProperty("lat", Row(LatName).ToString.ToDouble),
|
||||
New JProperty("lon", Row(LonName).ToString.ToDouble)
|
||||
))
|
||||
|
||||
Dim Base64array = Convert.ToBase64String(System.Text.Encoding.UTF8.GetBytes(posicionesArray.ToString()))
|
||||
@@ -193,9 +209,10 @@ Public Class WsTSoft
|
||||
End Class
|
||||
<Serializable>
|
||||
Public Class LatLng
|
||||
Public Lat As String
|
||||
Public Lng As String
|
||||
Public CurrentError As String
|
||||
Public Property Lat As String
|
||||
Public Property Lng As String
|
||||
Public Property Direccion As String
|
||||
Public Property CurrentError As String
|
||||
End Class
|
||||
<Serializable>
|
||||
Public Class GetRemisionHistorialsObj
|
||||
@@ -203,7 +220,8 @@ Public Class WsTSoft
|
||||
Public Property FolioRemision As String
|
||||
Public Property NoEconomico As String
|
||||
Public Property Lat As String
|
||||
Public Property Lon As String
|
||||
Public Property Lon As String
|
||||
Public Property Direccion As String
|
||||
Public Property Distancia As String
|
||||
Public Property TrackingNumber As String
|
||||
Public Property CveEstatus As Integer
|
||||
|
||||
Reference in New Issue
Block a user