ON country.usd_usr_id = usr_id AND country.usd_usf_id = ' . $gProfileFields->getProperty('COUNTRY', 'usf_id') . ' LEFT JOIN ' . TBL_ROLES . ' rol ON rol.rol_valid = 1 AND rol.rol_id = ' . $getRoleId . ' LEFT JOIN ' . TBL_MEMBERS . ' mem ON mem.mem_rol_id = rol.rol_id AND mem.mem_begin <= \'' . DATE_NOW . '\' AND mem.mem_end > \'' . DATE_NOW . '\' AND mem.mem_usr_id = usr_id WHERE ' . $memberCondition . ' ORDER BY last_name, first_name '; $userStatement = $gDb->query($sql); // create html page object $page = new HtmlPage($headline); $page->enableModal(); $javascriptCode = ''; if ($getMembersShowAll == 1) { $javascriptCode .= '$("#mem_show_all").prop("checked", true);'; } $javascriptCode .= ' $("#menu_item_create_user").attr("data-toggle", "modal"); $("#menu_item_create_user").attr("data-target", "#admidio_modal"); // change mode of users that should be shown $("#filter_rol_id").change(function() { window.location.replace("' . $g_root_path . '/adm_program/modules/lists/members_assignment.php?rol_id=' . $getRoleId . '&filter_rol_id=" + $("#filter_rol_id").val() + "&mem_show_all=0"); }); // change mode of users that should be shown $("#mem_show_all").click(function() {