Remates version 4.0.0.0
parent
a225a6b8af
commit
bf4fffcaff
|
|
@ -6,7 +6,7 @@
|
|||
<Image>Images\AddinDesktop32.png</Image>
|
||||
<Author>VSM</Author>
|
||||
<Company>VSM - Narvaling</Company>
|
||||
<Date>10/04/2024 12:00:00, 2024</Date>
|
||||
<Date>12/04/2024 12:00:00, 2024</Date>
|
||||
<Subject>Framework</Subject>
|
||||
<!-- Note subject can be one or more of these topics:
|
||||
Content, Framework, Editing, Geodatabase, Geometry, Geoprocessing, Layouts, Map Authoring, Map Exploration -->
|
||||
|
|
|
|||
|
|
@ -2412,7 +2412,7 @@ namespace OliviaAddInPro.Helper
|
|||
/**
|
||||
* Importa el shp en la gdb y el dataset, como una featureclass
|
||||
*/
|
||||
public static Respuesta<bool> ImportShp(string nom_shp, string Gdb_dataset, string namefc)
|
||||
public static Respuesta<bool> ImportShp(string nom_shp, string Gdb_dataset, string namefc, ArcGIS.Core.Geometry.SpatialReference spatref=null)
|
||||
{
|
||||
var res = new Respuesta<bool> { Value = false };
|
||||
string[] args = { nom_shp, Gdb_dataset, namefc };
|
||||
|
|
@ -2420,7 +2420,8 @@ namespace OliviaAddInPro.Helper
|
|||
|
||||
try
|
||||
{
|
||||
ArcGIS.Core.Geometry.SpatialReference spatref = GetSpatRef(nom_shp);
|
||||
if(spatref==null)
|
||||
spatref = GetSpatRef(nom_shp);
|
||||
var environments = Geoprocessing.MakeEnvironmentArray(outputCoordinateSystem: spatref);
|
||||
//CancelableProgressorSource cps = new CancelableProgressorSource();
|
||||
var _cts = new System.Threading.CancellationTokenSource();
|
||||
|
|
|
|||
|
|
@ -405,9 +405,13 @@ namespace OliviaAddInPro.Model
|
|||
int n, i_def, icar, iveh;
|
||||
|
||||
//Rellena las opciones de carga máxima por vehículo
|
||||
//////////////////////////////////////////////////
|
||||
//Carga Trasera
|
||||
////////////////////////////////////////////////
|
||||
//Trasera-satelite
|
||||
n = 4;
|
||||
i_def = 2;
|
||||
//Rellena volumenes
|
||||
info[0] = 2;
|
||||
info[1] = 3;
|
||||
info[2] = 5;
|
||||
|
|
@ -425,6 +429,7 @@ namespace OliviaAddInPro.Model
|
|||
//Trasera-2 ejes
|
||||
n = 6;
|
||||
i_def = 2;
|
||||
//Rellena volumenes
|
||||
info[0] = 8;
|
||||
info[1] = 10;
|
||||
info[2] = 12;
|
||||
|
|
@ -447,6 +452,7 @@ namespace OliviaAddInPro.Model
|
|||
//Trasera-3ejes
|
||||
n = 4;
|
||||
i_def = 3;
|
||||
//Rellena volumenes
|
||||
info[0] = 18;
|
||||
info[1] = 20;
|
||||
info[2] = 22;
|
||||
|
|
@ -454,6 +460,9 @@ namespace OliviaAddInPro.Model
|
|||
rellena_carg((int)RecogidaDef.TiposCarga.Trasera,
|
||||
(int)RecogidaDef.TiposVehic.Ejes3, n, i_def, info);
|
||||
|
||||
//////////////////////////////////////////////////
|
||||
//Carga Lateral
|
||||
////////////////////////////////////////////////
|
||||
//Lateral-satelite, no hay
|
||||
rellena_carg((int)RecogidaDef.TiposCarga.Lateral,
|
||||
(int)RecogidaDef.TiposVehic.Satelite, 0, 0, null);
|
||||
|
|
@ -461,6 +470,7 @@ namespace OliviaAddInPro.Model
|
|||
//Lateral - 2 ejes
|
||||
n = 2;
|
||||
i_def = 1;
|
||||
//Rellena volumenes
|
||||
info[0] = 15;
|
||||
info[1] = 17;
|
||||
rellena_carg((int)RecogidaDef.TiposCarga.Lateral,
|
||||
|
|
@ -476,6 +486,7 @@ namespace OliviaAddInPro.Model
|
|||
//Lateral - 3 ejes
|
||||
n = 3;
|
||||
i_def = 2;
|
||||
//Rellena volumenes
|
||||
info[0] = 21;
|
||||
info[1] = 23;
|
||||
info[2] = 26;
|
||||
|
|
@ -486,9 +497,13 @@ namespace OliviaAddInPro.Model
|
|||
rellena_carg((int)RecogidaDef.TiposCarga.Superior,
|
||||
(int)RecogidaDef.TiposVehic.Satelite, 0, 0, null);
|
||||
|
||||
//////////////////////////////////////////////////
|
||||
//Carga Superior
|
||||
////////////////////////////////////////////////
|
||||
//Superior - 2 ejes
|
||||
n = 2;
|
||||
i_def = 0;
|
||||
//Rellena volumenes
|
||||
info[0] = 16;
|
||||
info[1] = 17;
|
||||
rellena_carg((int)RecogidaDef.TiposCarga.Superior,
|
||||
|
|
@ -497,6 +512,7 @@ namespace OliviaAddInPro.Model
|
|||
//Superior - 3 ejes
|
||||
n = 3;
|
||||
i_def = 2;
|
||||
//Rellena volumenes
|
||||
info[0] = 20;
|
||||
info[1] = 23;
|
||||
info[2] = 25;
|
||||
|
|
@ -507,47 +523,9 @@ namespace OliviaAddInPro.Model
|
|||
rellena_carg((int)RecogidaDef.TiposCarga.Bilateral,
|
||||
(int)RecogidaDef.TiposVehic.Satelite, 0, 0, null);
|
||||
|
||||
//Bilateral - 2 ejes
|
||||
n = 3;
|
||||
i_def = 1;
|
||||
info[0] = 14;
|
||||
info[1] = 16;
|
||||
info[2] = 18;
|
||||
rellena_carg((int)RecogidaDef.TiposCarga.Bilateral,
|
||||
(int)RecogidaDef.TiposVehic.Ejes2, n, i_def, info);
|
||||
|
||||
//Bilateral - 3 ejes
|
||||
n = 3;
|
||||
i_def = 1;
|
||||
info[0] = 20;
|
||||
info[1] = 23;
|
||||
info[2] = 26;
|
||||
rellena_carg((int)RecogidaDef.TiposCarga.Bilateral,
|
||||
(int)RecogidaDef.TiposVehic.Ejes3, n, i_def, info);
|
||||
|
||||
//Bolseo - todas, no hay
|
||||
//Lavado - todas, no hay
|
||||
//Otra - todas, no hay
|
||||
for (icar = (int)RecogidaDef.TiposCarga.BolseoPtaPta; icar < (int)RecogidaDef.TiposCarga.N; icar++)
|
||||
{
|
||||
for (iveh = (int)RecogidaDef.TiposVehic.Ejes3; iveh < (int)RecogidaDef.TiposVehic.N; iveh++)
|
||||
{
|
||||
rellena_carg(icar, iveh, 0, 0, null);
|
||||
}
|
||||
}
|
||||
|
||||
////////////////////////////////////////////////////////
|
||||
//Barcelona new
|
||||
rellena_offsets_bcn();
|
||||
}
|
||||
|
||||
private static void rellena_offsets_bcn()
|
||||
{
|
||||
int[] info = new int[10];
|
||||
int n, i_def;
|
||||
////////////////////////////////////////////////////////
|
||||
//Barcelona new
|
||||
|
||||
//////////////////////////////////////////////////
|
||||
//Carga Bilateral
|
||||
////////////////////////////////////////////////
|
||||
//Bilateral - satelite
|
||||
n = 1;
|
||||
i_def = 0;
|
||||
|
|
@ -577,6 +555,50 @@ namespace OliviaAddInPro.Model
|
|||
info[0] = -2050;
|
||||
rellena_carg_offset((int)RecogidaDef.TiposCarga.Bilateral,
|
||||
(int)RecogidaDef.TiposVehic.Satelite, (int)RecogidaDef.TiposFracción.Vidrio, n, info);
|
||||
//Bilateral - 2 ejes
|
||||
n = 3;
|
||||
i_def = 1;
|
||||
//Rellena volumenes
|
||||
info[0] = 14;
|
||||
info[1] = 16;
|
||||
info[2] = 18;
|
||||
rellena_carg((int)RecogidaDef.TiposCarga.Bilateral,
|
||||
(int)RecogidaDef.TiposVehic.Ejes2, n, i_def, info);
|
||||
|
||||
//Bilateral - 3 ejes
|
||||
n = 3;
|
||||
i_def = 1;
|
||||
//Rellena volumenes
|
||||
info[0] = 20;
|
||||
info[1] = 23;
|
||||
info[2] = 26;
|
||||
rellena_carg((int)RecogidaDef.TiposCarga.Bilateral,
|
||||
(int)RecogidaDef.TiposVehic.Ejes3, n, i_def, info);
|
||||
|
||||
//Bolseo - todas, no hay
|
||||
//Lavado - todas, no hay
|
||||
//Otra - todas, no hay
|
||||
for (icar = (int)RecogidaDef.TiposCarga.BolseoPtaPta; icar < (int)RecogidaDef.TiposCarga.N; icar++)
|
||||
{
|
||||
for (iveh = (int)RecogidaDef.TiposVehic.Ejes3; iveh < (int)RecogidaDef.TiposVehic.N; iveh++)
|
||||
{
|
||||
rellena_carg(icar, iveh, 0, 0, null);
|
||||
}
|
||||
}
|
||||
|
||||
////////////////////////////////////////////////////////
|
||||
//Rellena offsets
|
||||
rellena_offsets_bcn();
|
||||
}
|
||||
|
||||
private static void rellena_offsets_bcn()
|
||||
{
|
||||
int[] info = new int[10];
|
||||
int n, i_def;
|
||||
////////////////////////////////////////////////////////
|
||||
//Barcelona revisado abril 24
|
||||
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
//Trasera - satélite - organico, resto
|
||||
|
|
@ -814,22 +836,15 @@ namespace OliviaAddInPro.Model
|
|||
|
||||
//Bilateral - 2 ejes - vidrio
|
||||
rellena_carg_offset((int)RecogidaDef.TiposCarga.Superior,
|
||||
(int)RecogidaDef.TiposVehic.Ejes3, (int)RecogidaDef.TiposFracción.Vidrio, n, info);
|
||||
(int)RecogidaDef.TiposVehic.Ejes3, (int)RecogidaDef.TiposFracción.Vidrio, n, info);
|
||||
|
||||
//Bilateral - 2 ejes - papel
|
||||
info[0] = 1820;
|
||||
info[1] = 2080;
|
||||
info[2] = 2340;
|
||||
info[0] = 1540;
|
||||
info[1] = 1760;
|
||||
info[2] = 1980;
|
||||
rellena_carg_offset((int)RecogidaDef.TiposCarga.Bilateral,
|
||||
(int)RecogidaDef.TiposVehic.Ejes2, (int)RecogidaDef.TiposFracción.Papel, n, info);
|
||||
|
||||
//Bilateral - 2 ejes - vidrio
|
||||
info[0] = -140;
|
||||
info[1] = -160;
|
||||
info[2] = -180;
|
||||
rellena_carg_offset((int)RecogidaDef.TiposCarga.Bilateral,
|
||||
(int)RecogidaDef.TiposVehic.Ejes2, (int)RecogidaDef.TiposFracción.Vidrio, n, info);
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
//Bilateral - 3 ejes - resto, org
|
||||
n = 3;
|
||||
|
|
|
|||
|
|
@ -16,10 +16,10 @@ namespace OliviaAddInPro.Services
|
|||
private static string pathConfigDef = "C:\\Olivia";
|
||||
private static ConfigServ configServ=null;
|
||||
private static string nameDirWork = "%dir_work%";
|
||||
public const string OlvRegKey = "SOFTWARE\\Narvaling\\Olivia_3_1";
|
||||
public const string OlvRegKey = "SOFTWARE\\Narvaling\\Olivia_4_0";
|
||||
public const string OlvRegName = "workdir";
|
||||
public const string OlvConfigName = "olv.conf";
|
||||
public const string VersionConfiguracion = "1.1.0.2";
|
||||
public const string VersionConfiguracion = "1.2.0.0";
|
||||
public static ConfigServ Serv
|
||||
{
|
||||
get {
|
||||
|
|
@ -354,13 +354,13 @@ namespace OliviaAddInPro.Services
|
|||
c.dens_vehi_org=500;
|
||||
c.dens_vehi_res=500;
|
||||
c.dens_vehi_env=120;
|
||||
c.dens_vehi_pap=250;
|
||||
c.dens_vehi_pap=360;
|
||||
c.dens_vehi_vid=350;
|
||||
c.dens_vehi_otr=100;
|
||||
c.dens_cont_org=150;
|
||||
c.dens_cont_org=200;
|
||||
c.dens_cont_res=100;
|
||||
c.dens_cont_env=28;
|
||||
c.dens_cont_pap=90;
|
||||
c.dens_cont_pap=75;
|
||||
c.dens_cont_vid=250;
|
||||
c.dens_cont_otr=100;
|
||||
c.anch_vehi_3=2.4000000;
|
||||
|
|
@ -456,7 +456,7 @@ namespace OliviaAddInPro.Services
|
|||
{
|
||||
nombre = "Vehiculo pequeño",
|
||||
filtro_omitir = "(FREEWAY <> 1 AND SLIPRD = 0)",
|
||||
campo_prioridad = "IIF($feature.PRIVATERD==2 || $feature.RDCOND==2 || ($feature.FOW>13 && $feature.FOW<16) , -2 , 0)",
|
||||
campo_prioridad = "IIF($feature.PRIVATERD>1 || ($feature.FOW>13 && $feature.FOW<16) , -2 , 0)",
|
||||
vehiculo_def_reco = 2,
|
||||
vehiculo_def_lim = 1
|
||||
|
||||
|
|
@ -464,8 +464,8 @@ namespace OliviaAddInPro.Services
|
|||
c.ListaMV.Add(new OliviaConfMV()
|
||||
{
|
||||
nombre = "Vehiculo mediano",
|
||||
filtro_omitir = "(RDCOND <> 2 AND ONEWAY = 'N' AND FOW NOT IN (14, 15, 19))",
|
||||
campo_prioridad = "IIF($feature.PRIVATERD==2 || $feature.RDCOND==3 , -2 , 0)",
|
||||
filtro_omitir = "(ONEWAY <> 'N' AND FOW NOT IN (14, 15, 19))",
|
||||
campo_prioridad = "IIF($feature.PRIVATERD>1 || $feature.RDCOND>1 , -2 , 0)",
|
||||
vehiculo_def_reco = 1,
|
||||
vehiculo_def_lim = -1
|
||||
|
||||
|
|
@ -473,8 +473,8 @@ namespace OliviaAddInPro.Services
|
|||
c.ListaMV.Add(new OliviaConfMV()
|
||||
{
|
||||
nombre = "Vehiculo grande",
|
||||
filtro_omitir = "(RDCOND NOT IN (2, 3) AND ONEWAY = 'N' AND FOW NOT IN (14, 15, 19))",
|
||||
campo_prioridad = "IIF($feature.PRIVATERD==2 , -2 , 0)",
|
||||
filtro_omitir = "(ONEWAY <> 'N' AND FOW NOT IN (14, 15, 19))",
|
||||
campo_prioridad = "IIF($feature.RDCOND>1,-3, (IIF($feature.PRIVATERD>1 , -2 , 0)))",
|
||||
vehiculo_def_reco =0,
|
||||
vehiculo_def_lim = -1
|
||||
|
||||
|
|
|
|||
|
|
@ -145,9 +145,9 @@ namespace OliviaAddInPro.Services
|
|||
ErrStr = Resource1.String_cancel_progreso;
|
||||
return false;
|
||||
}
|
||||
//mira spatialreference de los datos de entrada
|
||||
spatRefData = geom_export.SpatialReference;
|
||||
//mira spatialreference de los datos de entrada
|
||||
spatref = HelperGdb.GetSpatRefSync(com.CapaElemsRef);
|
||||
spatRefData = spatref;
|
||||
if (spatref != null)
|
||||
{
|
||||
geom_export = HelperGdb.ReproyectaGeom(geom_export, spatref);
|
||||
|
|
@ -1205,7 +1205,7 @@ namespace OliviaAddInPro.Services
|
|||
}
|
||||
}
|
||||
|
||||
resp2 = HelperGdb.ImportShp(dir_shp + "\\" + noms_shp[i] + HelperGdb.SHP_EXT, GdbFileName + "\\" + dataset, noms_gdb[i]);
|
||||
resp2 = HelperGdb.ImportShp(dir_shp + "\\" + noms_shp[i] + HelperGdb.SHP_EXT, GdbFileName + "\\" + dataset, noms_gdb[i], spatRefData);
|
||||
if (!resp2.Value)
|
||||
{
|
||||
err_st = "Error al importar la capa " + noms_gdb[i];
|
||||
|
|
|
|||
|
|
@ -135,6 +135,7 @@ namespace OliviaAddInPro
|
|||
}
|
||||
}
|
||||
private int tipoTto = -1;
|
||||
private int tipoTto_old = -2;
|
||||
public int TipoTto
|
||||
{
|
||||
get { return tipoTto; }
|
||||
|
|
@ -278,12 +279,13 @@ namespace OliviaAddInPro
|
|||
*/
|
||||
public void ComboTtoSel(int tto)
|
||||
{
|
||||
if (tto < 0)
|
||||
if (tto < 0 || tto== tipoTto_old)
|
||||
return;
|
||||
TipoTto = tto;
|
||||
TipoTto = tto;
|
||||
cambia_tiempo_tto();
|
||||
ambitosSel = new bool[(int)LimpiezaDef.AmbitsTra.AmbN]; //reinicia los ambitos seleccionados
|
||||
|
||||
tipoTto_old = tto;
|
||||
////////////////////////////////////////
|
||||
//Otros cambios que dependen del tratamiento
|
||||
if (TipoTto != (int)LimpiezaDef.TiposTto.TtoNoDef)
|
||||
|
|
|
|||
|
|
@ -123,6 +123,7 @@ namespace OliviaAddInPro
|
|||
}
|
||||
}
|
||||
private int tipoFrac = -1;
|
||||
private int tipoFrac_old = -2;
|
||||
public int TipoFrac
|
||||
{
|
||||
get { return tipoFrac; }
|
||||
|
|
@ -133,6 +134,7 @@ namespace OliviaAddInPro
|
|||
}
|
||||
}
|
||||
private int tipoCarg = -1;
|
||||
private int tipoCarg_old = -2;
|
||||
public int TipoCarg
|
||||
{
|
||||
get { return tipoCarg; }
|
||||
|
|
@ -143,6 +145,7 @@ namespace OliviaAddInPro
|
|||
}
|
||||
}
|
||||
private int tipoVehic = -1;
|
||||
private int tipoVehic_old = -2;
|
||||
public int TipoVehic
|
||||
{
|
||||
get { return tipoVehic; }
|
||||
|
|
@ -153,6 +156,7 @@ namespace OliviaAddInPro
|
|||
}
|
||||
}
|
||||
private int tipoCapac = -1;
|
||||
private int tipoCapac_old = -2;
|
||||
public int TipoCapac
|
||||
{
|
||||
get { return tipoCapac; }
|
||||
|
|
@ -163,6 +167,7 @@ namespace OliviaAddInPro
|
|||
}
|
||||
}
|
||||
private int tipoLate = -1;
|
||||
private int tipoLate_old = -2;
|
||||
public int TipoLate
|
||||
{
|
||||
get { return tipoLate; }
|
||||
|
|
@ -435,7 +440,7 @@ namespace OliviaAddInPro
|
|||
*/
|
||||
public bool ComboFracSel(int tto)
|
||||
{
|
||||
if (tto < 0)
|
||||
if (tto < 0 || tto== tipoFrac_old)
|
||||
return false;
|
||||
if (!tipos_fracc_bool[tto])
|
||||
{
|
||||
|
|
@ -445,7 +450,8 @@ namespace OliviaAddInPro
|
|||
try
|
||||
{
|
||||
//cuando se selecciona un item pintado en gris (que no existe en la GDB) se actúa como si no se hubiera seleccionado item
|
||||
TipoFrac = tto;
|
||||
TipoFrac = tto;
|
||||
tipoFrac_old = tto;
|
||||
if ((TipoVehic >= 0) && (TipoCarg >= 0))
|
||||
{
|
||||
//si también se ha seleccionado tipo de carga y de vehículo, se rellena la lista de capacidades
|
||||
|
|
@ -548,7 +554,7 @@ namespace OliviaAddInPro
|
|||
public bool ComboCargSel(int tto)
|
||||
{
|
||||
VisCombLate = Visibility.Hidden;
|
||||
if (tto < 0)
|
||||
if (tto < 0 || tto== tipoCarg_old)
|
||||
return false;
|
||||
if (!tipos_carg_bool[tto])
|
||||
{
|
||||
|
|
@ -557,7 +563,9 @@ namespace OliviaAddInPro
|
|||
try
|
||||
{
|
||||
TipoCarg=tto;
|
||||
|
||||
tipoCarg_old = tto;
|
||||
|
||||
|
||||
if (TipoCarg == (int)RecogidaDef.TiposCarga.Lateral)
|
||||
VisCombLate = Visibility.Visible;
|
||||
else
|
||||
|
|
@ -597,21 +605,25 @@ namespace OliviaAddInPro
|
|||
*/
|
||||
public void ComboVehicSel(int tto)
|
||||
{
|
||||
if (tto < 0)
|
||||
if (tto < 0 )
|
||||
return;
|
||||
try
|
||||
{
|
||||
TipoVehic = tto;
|
||||
if (TipoVehic >= 0)
|
||||
{
|
||||
int tmv =new LimpiezaServ(null).GetModosViajesDefecto(TipoVehic);
|
||||
if(tmv>=0)
|
||||
if (tipoVehic_old != tto)
|
||||
{
|
||||
TipoMv = tmv;
|
||||
int tmv = new LimpiezaServ(null).GetModosViajesDefecto(TipoVehic);
|
||||
if (tmv >= 0)
|
||||
{
|
||||
TipoMv = tmv;
|
||||
}
|
||||
}
|
||||
//si también se ha seleccionado tipo de carga, se rellena la lista de capacidades
|
||||
rellena_capac();
|
||||
}
|
||||
tipoVehic_old = tto;
|
||||
}
|
||||
catch (Exception)
|
||||
{
|
||||
|
|
@ -630,6 +642,7 @@ namespace OliviaAddInPro
|
|||
try
|
||||
{
|
||||
TipoCapac = tto;
|
||||
tipoCapac_old = tto;
|
||||
rellena_kgmax();
|
||||
}
|
||||
catch (Exception)
|
||||
|
|
@ -643,11 +656,12 @@ namespace OliviaAddInPro
|
|||
*/
|
||||
public void ComboLatSel(int tto)
|
||||
{
|
||||
if (tto < 0)
|
||||
if (tto < 0 || tto== tipoLate_old)
|
||||
return;
|
||||
try
|
||||
{
|
||||
TipoLate = tto;
|
||||
tipoLate_old = tto;
|
||||
}
|
||||
catch (Exception)
|
||||
{
|
||||
|
|
|
|||
Loading…
Reference in New Issue