});
    });
    
    
</script>


<form id="formulario-registrar-pago-integrante" method="POST" >
    <table align="center" width="750" >
        <tr>
            <td valign="top" width="200" class="tabla2_informacion" >
                <select name="id_persona" id="id_persona" class="mayuscula" >
                    <option value="" >Nadie</option>
                    <?php 
        $integrantes_aux->ver_datos_integrantes();
        while ($list_integrantes = $integrantes_aux->retornar_SELECT()) {
            ?>
                    <option value="<?php 
            echo $list_integrantes['id_persona'];
            ?>
" ><?php 
            echo $integrante->ver_nombre_completo($list_integrantes["id_persona"]);
            ?>
</option>
                    <?php 
        }
        ?>
                </select>    
            </td>

            <td valign="top" width="250" class="tabla2_informacion" >
            echo $dato_deuda["nombre_deuda"];
            ?>
                </td>
            <?php 
        }
        ?>
            <td class="rotate" height="100px" >
                Deuda Total
            </td>
        </tr>
        
        <?php 
        $integrantes->ver_datos_integrantes();
        $cont_int = 0;
        $deuda_total = 0;
        while ($dato_integrante = $integrantes->retornar_SELECT()) {
            $id_persona_dt = $dato_integrante["id_persona"];
            $cont_int++;
            ?>
            <tr class="tabla2_informacion" >
                <td>
                    <?php 
            echo $cont_int;
            ?>
                </td>
				<td >
				    <img src="<?php 
            echo $integrantes_aux->ver_foto($id_persona_dt);
            ?>
" width="60" height="48" >
				</td>
				No
			</td>
			<td>
				Foto
			</td>
			<td>
				Integrante
			</td>
			<td>
				Estado
			</td>
		</tr>
	<?php 
        $tabla_integrantes->ver_datos_integrantes();
        $cont_integrante = 1;
        while ($rel_integrante = $tabla_integrantes->retornar_SELECT()) {
            ?>
	
		<tr>
			<td colspan="5">
				<div id="div_resul<?php 
            echo $rel_integrante['id_persona'];
            ?>
">
				</div>
			</td>
		</tr>
		<?php 
            if ($grupo->verificar_integrante($rel_integrante['id_persona'], $id_grupo) != 0) {
                $class = "item3";
            } else {
        $num_integrantes = $tabla_integrante->num_datos_integrantes();
        $num_col = (int) ($div_ancho / 330);
        $num_row = (int) ($num_integrantes / $num_col);
        $rest_row = $num_integrantes % $num_col;
        //echo " int:".$num_integrantes." col:".$num_col." row".$num_row." ancho:".$div_ancho;
        $tabla_integrante->ver_datos_integrantes();
        ?>
        <br>
        <table align="center" width="90%" >
            <?php 
        for ($i = 0; $i < $num_row; $i++) {
            ?>
            <tr >
                <?php 
            for ($j = 0; $j < $num_col; $j++) {
                $datos_integrantes = $tabla_integrante->retornar_SELECT();
                $id_persona_env = $datos_integrantes["id_persona"];
                if (($i + $j) % 2 == 0) {
                    $class = "item1";
                } else {
                    $class = "item2";
                }
                ?>
                <td class="<?php 
                echo $class;
                ?>
" >
                    <img src="<?php 
                echo $integrantes_env->ver_foto($id_persona_env);
                ?>
" width="70px" height="60px" >
											<td>
												Integrante
											</td>
											<td>
												Trabajo
											</td>
											<td>
											</td>
										</tr>
										<tr id="tabla1_informacion">
											<td>
												<select name="id_persona">
													<?php 
        $integrante_aux = new integrantes();
        $integrante->ver_datos_integrantes();
        while ($op_integrante = $integrante->retornar_SELECT()) {
            ?>
													<option value="<?php 
            echo $op_integrante['id_persona'];
            ?>
"><?php 
            echo $integrante_aux->ver_nombre_completo($op_integrante['id_persona']);
            ?>
</option>
													<?php 
        }
        ?>
												</select>
											</td>
											<td>
												<select name="id_trabajo">