Comments (6)
Hi @Photex99
I don't know such a problem.
If you tell me the code, I may be able to advise.
Thanks
from redmine-view-customize.
@onozaty this is the code
// Formularios EDICION PSVs ---------------------------------------------------------------------------
// Modifica la vista de la petición sin editar
$(function() {
function stringToDate(_date,_format,_delimiter)
{
var formatLowerCase=_format.toLowerCase();
var formatItems=formatLowerCase.split(_delimiter);
var dateItems=_date.split(_delimiter);
var monthIndex=formatItems.indexOf("mm");
var dayIndex=formatItems.indexOf("dd");
var yearIndex=formatItems.indexOf("yyyy");
var month=parseInt(dateItems[monthIndex]);
month-=1;
var formatedDate = new Date(dateItems[yearIndex],month,dateItems[dayIndex]);
return formatedDate;
}
function formatDate(date) {
var d = new Date(date),
month = '' + (d.getMonth() + 1),
day = '' + d.getDate(),
year = d.getFullYear();
if (month.length < 2) month = '0' + month;
if (day.length < 2) day = '0' + day;
return [year, month, day].join('-');
}
/*************************************
GENERALES COMUNES
**************************************/
$('#issue_project_id').parent().hide();
$('#issue_assigned_to_id').parent().hide();
$('#issue_priority_id').parent().hide();
$('#time_begin').hide();
$('#time_end').hide();
$('.assigned-to.attribute').hide();
$('.priority.attribute').hide();
$('#all_attributes').css("background-color","#fcf3cf");
$('#relations').hide();
if ($('#issue_tracker_id').val()==8) { // PSV_TARADO
/*************************************
DEFINICION DE VARIABLES
**************************************/
var REV_TIPO = $('.cf_91.attribute');
var TAR_OCA = $('.cf_85.attribute');
var TAR_OT = $('.cf_87.attribute');
var REV_ULTIMA = $('.cf_89.attribute');
var REV_PROXIMA = $('.cf_90.attribute');
var TAR_PRE_POP_TEST = $('.cf_92.attribute');
var TAR_PRE_DISENYO = $('.cf_93.attribute');
var TAR_PRE_DISENYO_UNITS = $('.cf_94.attribute');
var TAR_PRE_DISP_POP_TEST = $('.cf_95.attribute');
var TAR_PRE_DISP_POP_TEST_UNITS = $('.cf_96.attribute');
var TAR_PRE_POP_TEST_RESULT = $('.cf_97.attribute');
var PRE_DISPARO_PRUEBA = $('.cf_126.attribute');
var CUMPLE_PRUEBA = $('.cf_124.attribute');
var REV_TIPO_ED = $('#issue_custom_field_values_91').parent();
var TAR_OCA_ED = $('#issue_custom_field_values_85').parent();
var TAR_OT_ED = $('#issue_custom_field_values_87').parent();
var REV_ULTIMA_ED = $('#issue_custom_field_values_89').parent();
var REV_PROXIMA_ED = $('#issue_custom_field_values_90').parent();
var TAR_PRE_POP_TEST_ED = $('#issue_custom_field_values_92').parent();
var TAR_PRE_DISENYO_ED = $('#issue_custom_field_values_93').parent();
var TAR_PRE_DISENYO_UNITS_ED = $('#issue_custom_field_values_94').parent();
var TAR_PRE_DISP_POP_TEST_ED = $('#issue_custom_field_values_95').parent();
var TAR_PRE_DISP_POP_TEST_UNITS_ED = $('#issue_custom_field_values_96').parent();
var TAR_PRE_POP_TEST_RESULT_ED = $('#issue_custom_field_values_97').parent();
var PRE_DISPARO_PRUEBA_ED = $('#issue_custom_field_values_126').parent();
var CUMPLE_PRUEBA_ED = $('#issue_custom_field_values_124').parent();
/*************************************
GENERALES PSV_Tarado
**************************************/
$('#issue_tree').hide();
$('.start-date.attribute').hide();
$('.due-date.attribute').hide();
$('#checklist').hide();
$('#start_date_area').hide();
$('#due_date_area').hide();
$('#issue_status_id').hide();
$('#checklist_form').hide();
$('#watchers_form').hide();
/*************************************
EDIT
**************************************/
// PRE-POP TEST
$('#issue_status_id').closest(".splitcontent").after($('<div id="POPER" class="splitcontent">'));
$('#POPER').css("background-color","#FFB6AE");
$('#POPER').append($("<p><h3>2.PRE-POP Test</h3><hr style='background-color: black; height:2px'></p>"));
$('#POPER').append($('<div id="POPQL" class="splitcontentleft">'));
$('#POPER').append($('<div id="POPQR" class="splitcontentright">'));
$('#POPQL').append(TAR_PRE_POP_TEST_ED);
$('#POPQR').append(TAR_PRE_POP_TEST_RESULT_ED);
$('#POPQL').append(TAR_PRE_DISENYO_ED);
$('#POPQR').append(TAR_PRE_DISENYO_UNITS_ED);
$('#POPQL').append(TAR_PRE_DISP_POP_TEST_ED);
$('#POPQR').append(TAR_PRE_DISP_POP_TEST_UNITS_ED);
$('#POPQL').append(PRE_DISPARO_PRUEBA_ED);
$('#POPQR').append(CUMPLE_PRUEBA_ED);
// TARADO
$('#issue_status_id').closest(".splitcontent").after($('<div id="TARER" class="splitcontent">'));
$('#TARER').css("background-color","#B0F2C2");
$('#TARER').append($("<p><h3>1.General</h3><hr style='background-color: black; height:2px'></p>"));
$('#TARER').append($('<div id="TARQL" class="splitcontentleft">'));
$('#TARER').append($('<div id="TARQR" class="splitcontentright">'));
$('#TARQL').append(REV_TIPO_ED);
$('#TARQR').append(TAR_OCA_ED);
$('#TARQL').append(REV_ULTIMA_ED);
$('#TARQR').append(REV_PROXIMA_ED);
$('#TARQL').append(TAR_OT_ED);
/*************************************
VIEW
**************************************/
// PRE-POP TEST
$('div.issue div.attributes').after($('<div id="POPCR" class="splitcontent">'));
$('#POPCR').css("background-color","#FFB6AE");
$('#POPCR').append($("<p><h3>2.PRE-POP Test</h3><hr style='height:8px'></p>"));
$('#POPCR').append($('<div id="POPVL" class="splitcontentleft">'));
$('#POPCR').append($('<div id="POPVR" class="splitcontentright">'));
$('#POPVL').append(TAR_PRE_POP_TEST);
$('#POPVR').append(TAR_PRE_POP_TEST_RESULT);
$('#POPVL').append(TAR_PRE_DISENYO);
$('#POPVR').append(TAR_PRE_DISENYO_UNITS);
$('#POPVL').append(TAR_PRE_DISP_POP_TEST);
$('#POPVR').append(TAR_PRE_DISP_POP_TEST_UNITS);
$('#POPVL').append(PRE_DISPARO_PRUEBA);
$('#POPVR').append(CUMPLE_PRUEBA);
// TARADO
$('div.issue div.attributes').after($('<div id="TARVER" class="splitcontent">'));
$('#TARVER').css("background-color","#B0F2C2");
$('#TARVER').append($("<p><h3>1.General</h3><hr style='height:8px'></p>"));
$('#TARVER').append($('<div id="TARVDL" class="splitcontentleft">'));
$('#TARVER').append($('<div id="TARVDR" class="splitcontentright">'));
$('#TARVDL').append(REV_TIPO);
$('#TARVDR').append(TAR_OCA);
$('#TARVDL').append(REV_ULTIMA);
$('#TARVDR').append(REV_PROXIMA);
$('#TARVDL').append(TAR_OT);
}
if ($('#issue_tracker_id').val()==7) { // PSV
/*************************************
DEFINICION DE VARIABLES
**************************************/
// IDENTIFICACION
var ID_UBICACION_FISICA = $('.cf_9.attribute');
var ID_SECTOR = $('.cf_11.attribute');
var ID_UBICACION_TECNICA = $('.cf_12.attribute');
var ID_APARATO = $('.cf_13.attribute');
var ID_DESCRIPCION = $('.cf_14.attribute');
var ID_UBICACION_FISICA_ED = $('#issue_custom_field_values_9').parent();
var ID_SECTOR_ED = $('#issue_custom_field_values_11').parent();
var ID_UBICACION_TECNICA_ED = $('#issue_custom_field_values_12').parent();
var ID_APARATO_ED = $('#issue_custom_field_values_13').parent();
var ID_DESCRIPCION_ED = $('#issue_custom_field_values_14').parent();
// DOCUMENTACION
var DC_PANDI = $('.cf_81.attribute');
var DC_NUM_LAZO = $('.cf_82.attribute');
var DC_PANDI_ED = $('#issue_custom_field_values_81').parent();
var DC_NUM_LAZO_ED = $('#issue_custom_field_values_82').parent();
// FLUIDO
var FL_FLUIDO = $('.cf_15.attribute');
var FL_ESTADO_MAT = $('.cf_16.attribute');
var FL_TEMP_MIN = $('.cf_17.attribute');
var FL_TEMP_MIN_UNID = $('.cf_18.attribute');
var FL_TEMP_MAX = $('.cf_19.attribute');
var FL_TEMP_MAX_UNID = $('.cf_20.attribute');
var FL_CORRECION_TEMP = $('.cf_101.attribute');
var FL_CORRECION_TEMP_UNID = $('.cf_24.attribute');
var FL_CAUDAL_MIN = $('.cf_102.attribute');
var FL_CAUDAL_MIN_UNID = $('.cf_26.attribute');
var FL_CAUDAL_MAX = $('.cf_104.attribute');
var FL_CAUDAL_MAX_UNID = $('.cf_28.attribute');
var FL_PRESION_MIN = $('.cf_106.attribute');
var FL_PRESION_MIN_UNID = $('.cf_30.attribute');
var FL_PRESION_MAX = $('.cf_107.attribute');
var FL_PRESION_MAX_UNID = $('.cf_32.attribute');
var FL_CON_PRESION = $('.cf_108.attribute');
var FL_CON_PRESION_UNID = $('.cf_34.attribute');
var FL_DENSIDAD_MIN = $('.cf_109.attribute');
var FL_DENSIDAD_MIN_UNID = $('.cf_36.attribute');
var FL_DENSIDAD_MAX = $('.cf_110.attribute');
var FL_DENSIDAD_MAX_UNID = $('.cf_38.attribute');
var FL_VISCO_MIN = $('.cf_111.attribute');
var FL_VISCO_MIN_UNID = $('.cf_40.attribute');
var FL_VISCO_MAX = $('.cf_112.attribute');
var FL_VISCO_MAX_UNID = $('.cf_42.attribute');
var FL_PRECIPITADOS = $('.cf_43.attribute');
var FL_PARTICULAS = $('.cf_44.attribute');
var FL_GOTAS = $('.cf_45.attribute');
var FL_BURBUJAS = $('.cf_46.attribute');
var FL_CORROSIVO = $('.cf_47.attribute');
var FL_EROSIVO = $('.cf_48.attribute');
var FL_TOXICO = $('.cf_49.attribute');
var FL_ESPUMAS = $('.cf_50.attribute');
var FL_TURBULENCIAS = $('.cf_51.attribute');
var FL_VIBRACIONES = $('.cf_52.attribute');
var FL_CHOQUE_TERM = $('.cf_53.attribute');
var FL_FECHA_REV = $('.cf_54.attribute');
var FL_USUARIO_REV = $('.cf_55.attribute');
var FL_FLUIDO_ED = $('#issue_custom_field_values_15').parent();
var FL_ESTADO_MAT_ED = $('#issue_custom_field_values_16').parent();
var FL_TEMP_MIN_ED = $('#issue_custom_field_values_17').parent();
var FL_TEMP_MIN_UNID_ED = $('#issue_custom_field_values_18').parent();
var FL_TEMP_MAX_ED = $('#issue_custom_field_values_19').parent();
var FL_TEMP_MAX_UNID_ED = $('#issue_custom_field_values_20').parent();
var FL_CORRECION_TEMP_ED = $('#issue_custom_field_values_101').parent();
var FL_CORRECION_TEMP_UNID_ED = $('#issue_custom_field_values_24').parent();
var FL_CAUDAL_MIN_ED = $('#issue_custom_field_values_102').parent();
var FL_CAUDAL_MIN_UNID_ED = $('#issue_custom_field_values_26').parent();
var FL_CAUDAL_MAX_ED = $('#issue_custom_field_values_104').parent();
var FL_CAUDAL_MAX_UNID_ED = $('#issue_custom_field_values_28').parent();
var FL_PRESION_MIN_ED = $('#issue_custom_field_values_106').parent();
var FL_PRESION_MIN_UNID_ED = $('#issue_custom_field_values_30').parent();
var FL_PRESION_MAX_ED =$('#issue_custom_field_values_107').parent();
var FL_PRESION_MAX_UNID_ED =$('#issue_custom_field_values_32').parent();
var FL_CON_PRESION_ED =$('#issue_custom_field_values_108').parent();
var FL_CON_PRESION_UNID_ED =$('#issue_custom_field_values_34').parent();
var FL_DENSIDAD_MIN_ED =$('#issue_custom_field_values_109').parent();
var FL_DENSIDAD_MIN_UNID_ED =$('#issue_custom_field_values_36').parent();
var FL_DENSIDAD_MAX_ED =$('#issue_custom_field_values_110').parent();
var FL_DENSIDAD_MAX_UNID_ED =$('#issue_custom_field_values_38').parent();
var FL_VISCO_MIN_ED =$('#issue_custom_field_values_111').parent();
var FL_VISCO_MIN_UNID_ED =$('#issue_custom_field_values_40').parent();
var FL_VISCO_MAX_ED =$('#issue_custom_field_values_112').parent();
var FL_VISCO_MAX_UNID_ED =$('#issue_custom_field_values_42').parent();
var FL_PRECIPITADOS_ED =$('#issue_custom_field_values_43').parent();
var FL_PARTICULAS_ED =$('#issue_custom_field_values_44').parent();
var FL_GOTAS_ED =$('#issue_custom_field_values_45').parent();
var FL_BURBUJAS_ED =$('#issue_custom_field_values_46').parent();
var FL_CORROSIVO_ED =$('#issue_custom_field_values_47').parent();
var FL_EROSIVO_ED =$('#issue_custom_field_values_48').parent();
var FL_TOXICO_ED =$('#issue_custom_field_values_49').parent();
var FL_ESPUMAS_ED =$('#issue_custom_field_values_50').parent();
var FL_TURBULENCIAS_ED =$('#issue_custom_field_values_51').parent();
var FL_VIBRACIONES_ED =$('#issue_custom_field_values_52').parent();
var FL_CHOQUE_TERM_ED =$('#issue_custom_field_values_53').parent();
var FL_FECHA_REV_ED = $('#issue_custom_field_values_54').parent();
var FL_USUARIO_REV_ED = $('#issue_custom_field_values_55').parent();
// INSTALACION
var IN_NORMA = $('.cf_56.attribute');
var IN_DISCO_RUPTURA = $('.cf_57.attribute');
var IN_DESMONTAJE_SU_MEC = $('.cf_58.attribute');
var IN_CLASE_TUBERIA = $('.cf_59.attribute');
var IN_DIAMETRO_ENTRADA = $('.cf_60.attribute');
var IN_DIAMETRO_SALIDA = $('.cf_61.attribute');
var IN_PRES_NOM_BRI_EN = $('.cf_119.attribute');
var IN_PRES_NOM_BRI_SAL = $('.cf_120.attribute');
var IN_TIPO_ROSCA = $('.cf_62.attribute');
var IN_NORMA_ED = $('#issue_custom_field_values_56').parent();
var IN_DISCO_RUPTURA_ED = $('#issue_custom_field_values_57').parent();
var IN_DESMONTAJE_SU_MEC_ED = $('#issue_custom_field_values_58').parent();
var IN_CLASE_TUBERIA_ED = $('#issue_custom_field_values_59').parent();
var IN_DIAMETRO_ENTRADA_ED = $('#issue_custom_field_values_60').parent();
var IN_DIAMETRO_SALIDA_ED = $('#issue_custom_field_values_61').parent();
var IN_PRES_NOM_BRI_EN_ED = $('#issue_custom_field_values_119').parent();
var IN_PRES_NOM_BRI_SAL_ED = $('#issue_custom_field_values_120').parent();
var IN_TIPO_ROSCA_ED = $('#issue_custom_field_values_62').parent();
// EQUIPO
var EQ_MARCA = $('.cf_63.attribute');
var EQ_MODELO = $('.cf_64.attribute');
var EQ_NUMERO_SERIE = $('.cf_65.attribute');
var EQ_FICHA_AA = $('.cf_66.attribute');
var EQ_PRESION_DISPARO = $('.cf_113.attribute');
var EQ_PRESION_DISPARO_UNID = $('.cf_68.attribute');
var EQ_MATCUERPO = $('.cf_69.attribute');
var EQ_MATMUELLE = $('.cf_70.attribute');
var EQ_MATCIERRE = $('.cf_71.attribute');
var EQ_EXISTE_FUELLE = $('.cf_72.attribute');
var EQ_MATFUELLE = $('.cf_83.attribute');
var EQ_MATERIAL_OBTURADOR = $('.cf_74.attribute');
var EQ_TIPO_CIERRE = $('.cf_75.attribute');
var EQ_ORIFICIO_TIPO = $('.cf_76.attribute');
var EQ_DIAMETRO_ORIFICIO = $('.cf_115.attribute');
var EQ_COTA_A_MM = $('.cf_116.attribute');
var EQ_COTA_B_MM = $('.cf_117.attribute');
var EQ_COTA_C_MM = $('.cf_118.attribute');
var EQ_MARCA_ED = $('#issue_custom_field_values_63').parent();
var EQ_MODELO_ED = $('#issue_custom_field_values_64').parent();
var EQ_NUMERO_SERIE_ED = $('#issue_custom_field_values_65').parent();
var EQ_FICHA_AA_ED = $('#issue_custom_field_values_66').parent();
var EQ_PRESION_DISPARO_ED = $('#issue_custom_field_values_113').parent();
var EQ_PRESION_DISPARO_UNID_ED = $('#issue_custom_field_values_68').parent();
var EQ_MATCUERPO_ED = $('#issue_custom_field_values_69').parent();
var EQ_MATMUELLE_ED = $('#issue_custom_field_values_70').parent();
var EQ_MATCIERRE_ED = $('#issue_custom_field_values_71').parent();
var EQ_EXISTE_FUELLE_ED = $('#issue_custom_field_values_72').parent();
var EQ_MATFUELLE_ED = $('#issue_custom_field_values_83').parent();
var EQ_MATERIAL_OBTURADOR_ED = $('#issue_custom_field_values_74').parent();
var EQ_TIPO_CIERRE_ED = $('#issue_custom_field_values_75').parent();
var EQ_ORIFICIO_TIPO_ED = $('#issue_custom_field_values_76').parent();
var EQ_DIAMETRO_ORIFICIO_ED = $('#issue_custom_field_values_115').parent();
var EQ_COTA_A_MM_ED = $('#issue_custom_field_values_116').parent();
var EQ_COTA_B_MM_ED = $('#issue_custom_field_values_117').parent();
var EQ_COTA_C_MM_ED = $('#issue_custom_field_values_118').parent();
//CALIBRACIONES
var REV_FRECUENCIA = $('.cf_88.attribute');
var REV_FRECUENCIA_ED = $('#issue_custom_field_values_88').parent();
var REV_ULTIMA = $('.cf_89.attribute');
var REV_ULTIMA_ED = $('#issue_custom_field_values_89').parent();
var REV_PROXIMA = $('.cf_90.attribute');
var REV_PROXIMA_ED = $('#issue_custom_field_values_90').parent();
var REV_TIPO = $('.cf_91.attribute');
var REV_TIPO_ED = $('#issue_custom_field_values_91').parent();
var ORDEN_TRABA_ULT_REV = $('.cf_121.attribute');
var ORDEN_TRABA_ULT_REV_ED = $('#issue_custom_field_values_121').parent();
var CERTIFICADO = $('.cf_122.attribute');
var CERTIFICADO_ED = $('#issue_custom_field_values_122').parent();
/*************************************
GENERALES
**************************************/
// Actualizar fechas de la tarea en función de las fechas de la revisión y frecuencia
$('#issue_custom_field_values_89').change(function(e) {
//alert($('#issue_custom_field_values_89').val());
var fechainicio = stringToDate($('#issue_custom_field_values_89').val(),"yyyy-MM-dd","-");
var fechafin= fechainicio.setMonth(fechainicio.getMonth()+Number($('#issue_custom_field_values_88').val()));
$('#issue_custom_field_values_90').val(formatDate(fechafin));
//$('#issue_start_date').val(formatDate(fechainicio));
//$('#issue_due_date').val(formatDate(fechafin));
});
$('#issue_custom_field_values_88').change(function(e) {
var fechainicio = stringToDate($('#issue_custom_field_values_89').val(),"yyyy-MM-dd","-");
var fechafin= fechainicio.setMonth(fechainicio.getMonth()+Number($('#issue_custom_field_values_88').val()));
//alert(formatDate(fechafin));
$('#issue_custom_field_values_90').val(formatDate(fechafin));
//$('#issue_start_date').val(formatDate(fechainicio));
//$('#issue_due_date').val(formatDate(fechafin));
});
/*************************************
EDIT
**************************************/
// CHECKLIST EDIT
$('#issue_status_id').closest(".splitcontent").after($('<div id="CK" class="splitcontent">'));
$('#CK').css("background-color","#DCE4F9");
$('#CK').append($("<p><h3>90.Listado de asuntos pendientes</h3><hr style='background-color: black; height:2px'></p>"));
$('#CK').append(REV_TIPO_ED);
// CALIBRACIONES EDIT
$('#issue_status_id').closest(".splitcontent").after($('<div id="CAER" class="splitcontent">'));
$('#CAER').css("background-color","#DCE4F9");
$('#CAER').append($("<p><h3>10.Revisiones</h3><hr style='background-color: black; height:2px'></p>"));
$('#CAER').append($('<div id="CAQL" class="splitcontentleft">'));
$('#CAER').append($('<div id="CAQR" class="splitcontentright">'));
$('#CAQL').append(REV_TIPO_ED);
$('#CAQL').append(REV_ULTIMA_ED);
$('#CAQR').append(REV_FRECUENCIA_ED);
$('#CAQR').append(REV_PROXIMA_ED);
$('#CAQL').append(ORDEN_TRABA_ULT_REV_ED);
$('#CAQR').append(CERTIFICADO_ED);
// EQUIPO EDIT
$('#issue_status_id').closest(".splitcontent").after($('<div id="EQER" class="splitcontent">'));
$('#EQER').css("background-color","#E9B0F2");
$('#EQER').append($("<p><h3>5.Características del Equipo</h3><hr style='background-color: black; height:2px'></p>"));
$('#EQER').append($('<div id="EEQL" class="splitcontentleft">'));
$('#EQER').append($('<div id="EEQR" class="splitcontentright">'));
$('#EEQL').append(EQ_MARCA_ED);
$('#EEQR').append(EQ_MODELO_ED);
$('#EEQL').append(EQ_NUMERO_SERIE_ED);
$('#EEQR').append(EQ_FICHA_AA_ED);
$('#EEQL').append(EQ_PRESION_DISPARO_ED);
$('#EEQR').append(EQ_PRESION_DISPARO_UNID_ED);
$('#EEQL').append($("<p><h4>Materiales</h4><hr style='height:3px'></p>"));
$('#EEQR').append($("<p><h4>.</h4><hr style='height:3px'></p>"));
$('#EEQL').append(EQ_MATCUERPO_ED);
$('#EEQR').append(EQ_MATMUELLE_ED);
$('#EEQL').append(EQ_MATCIERRE_ED);
$('#EEQR').append(EQ_MATERIAL_OBTURADOR_ED);
$('#EEQL').append(EQ_EXISTE_FUELLE_ED);
$('#EEQR').append(EQ_MATFUELLE_ED);
$('#EEQL').append(EQ_TIPO_CIERRE_ED);
$('#EEQR').append($("<h4>.</h4>"));
$('#EEQL').append($("<p><h4>Cotas</h4><hr style='height:3px'></p>"));
$('#EEQR').append($("<p><h4>.</h4><hr style='height:3px'></p>"));
$('#EEQL').append(EQ_ORIFICIO_TIPO_ED);
$('#EEQR').append(EQ_DIAMETRO_ORIFICIO_ED);
$('#EEQL').append(EQ_COTA_A_MM_ED);
$('#EEQL').append(EQ_COTA_B_MM_ED);
$('#EEQL').append(EQ_COTA_C_MM_ED);
// INSTALACION EDIT
$('#issue_status_id').closest(".splitcontent").after($('<div id="INER" class="splitcontent">'));
$('#INER').css("background-color","#B0C2F2");
$('#INER').append($("<p><h3>4.Características de la Instalación</h3><hr style='background-color: black; height:2px'></p>"));
$('#INER').append($('<div id="IEL" class="splitcontentleft">'));
$('#INER').append($('<div id="IER" class="splitcontentright">'));
$('#IEL').append(IN_NORMA_ED);
$('#IER').append(IN_DISCO_RUPTURA_ED);
$('#IEL').append(IN_DESMONTAJE_SU_MEC_ED);
$('#IER').append(IN_CLASE_TUBERIA_ED);
$('#IEL').append(IN_DIAMETRO_ENTRADA_ED);
$('#IER').append(IN_DIAMETRO_SALIDA_ED);
$('#IEL').append(IN_PRES_NOM_BRI_EN_ED);
$('#IER').append(IN_PRES_NOM_BRI_SAL_ED);
$('#IEL').append(IN_TIPO_ROSCA_ED);
// FLUIDOS EDIT
$('#issue_status_id').closest(".splitcontent").after($('<div id="FLER" class="splitcontent">'));
$('#FLER').css("background-color","#FAFCAF");
$('#FLER').append($("<p><h3>3.Características del Fluido</h3><hr style='background-color: black; height:2px'></p>"));
$('#FLER').append($('<div id="FEL" class="splitcontentleft">'));
$('#FLER').append($('<div id="FER" class="splitcontentright">'));
$('#FEL').append(FL_FECHA_REV_ED);
$('#FER').append(FL_USUARIO_REV_ED);
$('#FEL').append(FL_FLUIDO_ED);
$('#FER').append(FL_ESTADO_MAT_ED);
$('#FEL').append($("<p><h4>Temperatura</h4><hr style='height:3px'></p>"));
$('#FER').append($("<p><h4>.</h4><hr style='height:3px'></p>"));
$('#FEL').append(FL_TEMP_MIN_ED);
$('#FER').append(FL_TEMP_MIN_UNID_ED);
$('#FEL').append(FL_TEMP_MAX_ED);
$('#FER').append(FL_TEMP_MAX_UNID_ED);
$('#FEL').append(FL_CORRECION_TEMP_ED);
$('#FER').append(FL_CORRECION_TEMP_UNID_ED);
$('#FEL').append($("<p><h4>Caudal</h4><hr style='height:3px'></p>"));
$('#FER').append($("<p><h4>.</h4><hr style='height:3px'></p>"));
$('#FEL').append(FL_CAUDAL_MIN_ED);
$('#FER').append(FL_CAUDAL_MIN_UNID_ED);
$('#FEL').append(FL_CAUDAL_MAX_ED);
$('#FER').append(FL_CAUDAL_MAX_UNID_ED);
$('#FEL').append($("<p><h4>Presión</h4><hr style='height:3px'></p>"));
$('#FER').append($("<p><h4>.</h4><hr style='height:3px'></p>"));
$('#FEL').append(FL_PRESION_MIN_ED);
$('#FER').append(FL_PRESION_MIN_UNID_ED);
$('#FEL').append(FL_PRESION_MAX_ED);
$('#FER').append(FL_PRESION_MAX_UNID_ED);
$('#FEL').append(FL_CON_PRESION_ED);
$('#FER').append(FL_CON_PRESION_UNID_ED);
$('#FEL').append($("<p><h4>Densidad</h4><hr style='height:3px'></p>"));
$('#FER').append($("<p><h4>.</h4><hr style='height:3px'></p>"));
$('#FEL').append(FL_DENSIDAD_MIN_ED);
$('#FER').append(FL_DENSIDAD_MIN_UNID_ED);
$('#FEL').append(FL_DENSIDAD_MAX_ED);
$('#FER').append(FL_DENSIDAD_MAX_UNID_ED);
$('#FEL').append($("<p><h4>Viscosidad</h4><hr style='height:3px'></p>"));
$('#FER').append($("<p><h4>.</h4><hr style='height:3px'></p>"));
$('#FEL').append(FL_VISCO_MIN_ED);
$('#FER').append(FL_VISCO_MIN_UNID_ED);
$('#FEL').append(FL_VISCO_MAX_ED);
$('#FER').append(FL_VISCO_MAX_UNID_ED);
$('#FEL').append($("<p><h4>Otros</h4><hr style='height:3px'></p>"));
$('#FER').append($("<p><h4>.</h4><hr style='height:3px'></p>"));
$('#FEL').append(FL_PRECIPITADOS_ED);
$('#FER').append(FL_PARTICULAS_ED );
$('#FEL').append(FL_GOTAS_ED );
$('#FER').append(FL_BURBUJAS_ED );
$('#FEL').append(FL_CORROSIVO_ED );
$('#FER').append(FL_EROSIVO_ED );
$('#FEL').append(FL_TOXICO_ED );
$('#FER').append(FL_ESPUMAS_ED );
$('#FEL').append(FL_TURBULENCIAS_ED );
$('#FER').append(FL_VIBRACIONES_ED );
$('#FEL').append(FL_CHOQUE_TERM_ED);
// DOCUMENTACION EDIT
$('#issue_status_id').closest(".splitcontent").after($('<div id="DCER" class="splitcontent">'));
$('#DCER').css("background-color","#FFB6AE");
$('#DCER').append($("<p><h3>2.Documentación</h3><hr style='background-color: black; height:2px'></p>"));
$('#DCER').append($('<div id="DEL" class="splitcontentleft">'));
$('#DCER').append($('<div id="DER" class="splitcontentright">'));
$('#DEL').append(DC_PANDI_ED);
$('#DER').append(DC_NUM_LAZO_ED);
// IDENTIFICACION EDIT
$('#issue_status_id').closest(".splitcontent").after($('<div id="IDER" class="splitcontent">'));
$('#IDER').css("background-color","#B0F2C2");
$('#IDER').append($("<p><h3>1.Identificación</h3><hr style='background-color: black; height:2px'></p>"));
$('#IDER').append($('<div id="IEL" class="splitcontentleft">'));
$('#IDER').append($('<div id="IER" class="splitcontentright">'));
$('#IEL').append(ID_UBICACION_FISICA_ED);
$('#IEL').append(ID_SECTOR_ED);
$('#IEL').append(ID_UBICACION_TECNICA_ED);
$('#IER').append(ID_APARATO_ED);
$('#IER').append(ID_DESCRIPCION_ED);
/*************************************
VIEW
**************************************/
// Ficheros Disponibles
$('.attachments').before($("<p><h3>Ficheros Disponibles</h3></p>"));
$('.attachments').before($("<hr style='height:10px'>"));
// CALIBRACIONES
$('div.issue div.attributes').after($('<div id="CAIN" class="splitcontent">'));
$('#CAIN').css("background-color","#DCE4F9");
$('#CAIN').append($("<p><h3>10.Revisiones</h3><hr style='height:8px'></p>"));
$('#CAIN').append($('<div id="CAL" class="splitcontentleft">'));
$('#CAIN').append($('<div id="CAR" class="splitcontentright">'));
$('#CAL').append(REV_TIPO);
$('#CAL').append(REV_ULTIMA);
$('#CAR').append(REV_FRECUENCIA);
$('#CAR').append(REV_PROXIMA);
$('#CAL').append(ORDEN_TRABA_ULT_REV);
$('#CAR').append(CERTIFICADO);
// EQUIPO
$('div.issue div.attributes').after($('<div id="EQIN" class="splitcontent">'));
$('#EQIN').css("background-color","#E9B0F2");
$('#EQIN').append($("<p><h3>5.Características del Equipo</h3><hr style='height:8px'></p>"));
$('#EQIN').append($('<div id="EQL" class="splitcontentleft">'));
$('#EQIN').append($('<div id="EQR" class="splitcontentright">'));
$('#EQL').append(EQ_MARCA);
$('#EQR').append(EQ_MODELO);
$('#EQL').append(EQ_NUMERO_SERIE);
$('#EQR').append(EQ_FICHA_AA);
$('#EQL').append(EQ_PRESION_DISPARO);
$('#EQR').append(EQ_PRESION_DISPARO_UNID);
$('#EQL').append($("<p><h4>Materiales</h4><hr style='height:3px'></p>"));
$('#EQR').append($("<p><h4>.</h4><hr style='height:3px'></p>"));
$('#EQL').append(EQ_MATCUERPO);
$('#EQR').append(EQ_MATMUELLE);
$('#EQL').append(EQ_MATCIERRE);
$('#EQR').append(EQ_MATERIAL_OBTURADOR);
$('#EQL').append(EQ_EXISTE_FUELLE);
$('#EQR').append(EQ_MATFUELLE);
$('#EQL').append(EQ_TIPO_CIERRE);
$('#EQR').append($("<h4>.</h4>"));
$('#EQL').append($("<p><h4>Cotas</h4><hr style='height:3px'></p>"));
$('#EQR').append($("<p><h4>.</h4><hr style='height:3px'></p>"));
$('#EQL').append(EQ_ORIFICIO_TIPO);
$('#EQR').append(EQ_DIAMETRO_ORIFICIO);
$('#EQL').append(EQ_COTA_A_MM);
$('#EQL').append(EQ_COTA_B_MM);
$('#EQL').append(EQ_COTA_C_MM);
// INSTALACION
$('div.issue div.attributes').after($('<div id="IDIN" class="splitcontent">'));
$('#IDIN').css("background-color","#B0C2F2");
$('#IDIN').append($("<p><h3>4.Características de la Instalación</h3><hr style='height:8px'></p>"));
$('#IDIN').append($('<div id="INL" class="splitcontentleft">'));
$('#IDIN').append($('<div id="INR" class="splitcontentright">'));
$('#INL').append(IN_NORMA);
$('#INR').append(IN_DISCO_RUPTURA);
$('#INL').append(IN_DESMONTAJE_SU_MEC);
$('#INR').append(IN_CLASE_TUBERIA);
$('#INL').append(IN_DIAMETRO_ENTRADA);
$('#INR').append(IN_DIAMETRO_SALIDA);
$('#INL').append(IN_PRES_NOM_BRI_EN);
$('#INR').append(IN_PRES_NOM_BRI_SAL);
$('#INL').append(IN_TIPO_ROSCA);
// FLUIDOS
$('div.issue div.attributes').after($('<div id="IDFL" class="splitcontent">'));
$('#IDFL').css("background-color","#FAFCAF");
$('#IDFL').append($("<p><h3>3.Características del Fluido</h3><hr style='height:8px'></p>"));
$('#IDFL').append($('<div id="FLL" class="splitcontentleft">'));
$('#IDFL').append($('<div id="FLR" class="splitcontentright">'));
$('#FLL').append(FL_FECHA_REV);
$('#FLR').append(FL_USUARIO_REV);
$('#FLL').append(FL_FLUIDO);
$('#FLR').append(FL_ESTADO_MAT);
$('#FLL').append($("<p><h4>Temperatura</h4><hr style='height:3px'></p>"));
$('#FLR').append($("<p><h4>.</h4><hr style='height:3px'></p>"));
$('#FLL').append(FL_TEMP_MIN);
$('#FLR').append(FL_TEMP_MIN_UNID);
$('#FLL').append(FL_TEMP_MAX);
$('#FLR').append(FL_TEMP_MAX_UNID);
$('#FLL').append(FL_CORRECION_TEMP);
$('#FLR').append(FL_CORRECION_TEMP_UNID);
$('#FLL').append($("<p><h4>Caudal</h4><hr style='height:3px'></p>"));
$('#FLR').append($("<p><h4>.</h4><hr style='height:3px'></p>"));
$('#FLL').append(FL_CAUDAL_MIN);
$('#FLR').append(FL_CAUDAL_MIN_UNID);
$('#FLL').append(FL_CAUDAL_MAX);
$('#FLR').append(FL_CAUDAL_MAX_UNID);
$('#FLL').append($("<p><h4>Presión</h4><hr style='height:3px'></p>"));
$('#FLR').append($("<p><h4>.</h4><hr style='height:3px'></p>"));
$('#FLL').append(FL_PRESION_MIN);
$('#FLR').append(FL_PRESION_MIN_UNID);
$('#FLL').append(FL_PRESION_MAX);
$('#FLR').append(FL_PRESION_MAX_UNID);
$('#FLL').append(FL_CON_PRESION);
$('#FLR').append(FL_CON_PRESION_UNID);
$('#FLL').append($("<p><h4>Densidad</h4><hr style='height:3px'></p>"));
$('#FLR').append($("<p><h4>.</h4><hr style='height:3px'></p>"));
$('#FLL').append(FL_DENSIDAD_MIN);
$('#FLR').append(FL_DENSIDAD_MIN_UNID);
$('#FLL').append(FL_DENSIDAD_MAX);
$('#FLR').append(FL_DENSIDAD_MAX_UNID);
$('#FLL').append($("<p><h4>Viscosidad</h4><hr style='height:3px'></p>"));
$('#FLR').append($("<p><h4>.</h4><hr style='height:3px'></p>"));
$('#FLL').append(FL_VISCO_MIN);
$('#FLR').append(FL_VISCO_MIN_UNID);
$('#FLL').append(FL_VISCO_MAX);
$('#FLR').append(FL_VISCO_MAX_UNID);
$('#FLL').append($("<p><h4>Otros</h4><hr style='height:3px'></p>"));
$('#FLR').append($("<p><h4>.</h4><hr style='height:3px'></p>"));
$('#FLL').append(FL_PRECIPITADOS);
$('#FLR').append(FL_PARTICULAS );
$('#FLL').append(FL_GOTAS );
$('#FLR').append(FL_BURBUJAS );
$('#FLL').append(FL_CORROSIVO );
$('#FLR').append(FL_EROSIVO );
$('#FLL').append(FL_TOXICO );
$('#FLR').append(FL_ESPUMAS );
$('#FLL').append(FL_TURBULENCIAS );
$('#FLR').append(FL_VIBRACIONES );
$('#FLL').append(FL_CHOQUE_TERM);
// DOCUMENTACION
$('div.issue div.attributes').after($('<div id="DCPR" class="splitcontent">'));
$('#DCPR').css("background-color","#FFB6AE");
$('#DCPR').append($("<p><h3>2.Documentación</h3><hr style='height:8px'></p>"));
$('#DCPR').append($('<div id="DDL" class="splitcontentleft">'));
$('#DCPR').append($('<div id="DDR" class="splitcontentright">'));
$('#DDL').append(DC_PANDI);
$('#DDR').append(DC_NUM_LAZO);
// IDENTIFICACION
$('div.issue div.attributes').after($('<div id="IDPR" class="splitcontent">'));
$('#IDPR').css("background-color","#B0F2C2");
$('#IDPR').append($("<p><h3>1.Identificación</h3><hr style='height:8px'></p>"));
$('#IDPR').append($('<div id="IDL" class="splitcontentleft">'));
$('#IDPR').append($('<div id="IDR" class="splitcontentright">'));
$('#IDL').append(ID_UBICACION_FISICA);
$('#IDL').append(ID_SECTOR);
$('#IDL').append(ID_UBICACION_TECNICA);
$('#IDR').append(ID_APARATO);
$('#IDR').append(ID_DESCRIPCION);
}
});
from redmine-view-customize.
Hi @Photex99
Thank you for the code.
I confirmed it, but I did not know the part that seemed to be a problem.
I'm sorry I couldn't be of any help.
from redmine-view-customize.
This issue is stale because it has been open for 60 days with no activity.
from redmine-view-customize.
This issue was closed because it has been inactive for 14 days since being marked as stale.
from redmine-view-customize.
I faced the same. It was because of the role not having edit issue permission. Take a try.
from redmine-view-customize.
Related Issues (20)
- Unable to install the plugin HOT 3
- ViewCustomize User Roles on project HOT 1
- NoMethodError: undefined method `represent_boolean_as_integer=' for nil:NilClass encountered with Redmine 4.1.0-9 HOT 2
- Customized Key/value list Value HOT 3
- Add user mails to ViewCustomize context HOT 3
- Version incorrect in init.rb HOT 1
- unable install the plugins for view customize in ubuntu HOT 7
- Add total estimated hours and total spent hours for the issue to ViewCustomize.context.
- Error when install plugin! HOT 51
- context leaks data user has no access to HOT 3
- Feature Request: Option to insert script at bottom of HTML body HOT 9
- Not working at Redmine 4.1.1 (Bitnami) with undeinfed method before_filter error HOT 4
- Thx, this is great! HOT 4
- Strange characters in the path pattern and comments. HOT 2
- User and password HOT 5
- Allow to specify who can view customization by user name and role HOT 5
- LoadError during startup with Redmine trunk r21288 HOT 2
- Add ViewCustomize.context.project.id HOT 1
- Question regards View Customize and Custom Table Plugins HOT 2
- Add the issue's author and last updated by to ViewCustomize.context
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from redmine-view-customize.