Exemplo n.º 1
0
function TasksEmployeeDrawStructure($arStructure, $arSections, $key, $name)
{
    foreach ($arStructure[$key] as $ID) {
        $arRes = $arSections[$ID];
        echo '<div class="company-department' . ($key == 0 ? ' company-department-first' : '') . '">';
        echo '<span class="company-department-inner" onclick="O_' . $name . '.load(\'' . $ID . '\')" id="' . $name . '_employee_section_' . $ID . '"><div class="company-department-arrow"></div><div class="company-department-text">' . htmlspecialcharsbx($arRes['NAME']) . '</div></span>';
        echo '</div>';
        echo '<div class="company-department-children" id="' . $name . '_children_' . $arRes['ID'] . '">';
        if (is_array($arStructure[$ID])) {
            TasksEmployeeDrawStructure($arStructure, $arSections, $ID, $name);
        }
        echo '<div class="company-department-employees" id="' . $name . '_employees_' . $ID . '"><span class="company-department-employees-loading">' . GetMessage("TASKS_EMP_WAIT") . '</span></div>';
        echo '</div>';
    }
}
Exemplo n.º 2
0
        ?>
										<?php 
    }
}
?>
								</td>
							</tr>
						</table>
					</div>
					<div class="finder-box-tab-content" id="<?php 
echo $arResult["NAME"];
?>
_structure">
						<div class="company-structure">
							<?php 
TasksEmployeeDrawStructure($arResult["STRUCTURE"], $arResult["SECTIONS"], 0, $arResult["NAME"]);
?>
							<script type="text/javascript">
								TasksUsers.arEmployees['<?php 
echo CUtil::JSEscape($arResult["STRUCTURE"][0][0]);
?>
'] = <?php 
echo $arResult['ROOT_DEP_USER'];
?>
;
								O_<?php 
echo $arResult["NAME"];
?>
.load('<?php 
echo CUtil::JSEscape($arResult["STRUCTURE"][0][0]);
?>