the_ID(); ?> " class="flexboxer flexboxer--page"> <?php if (have_posts()) { ?> <?php while (have_posts()) { the_post(); ?> <?php if (is_user_role('author') || is_user_role('editor') || is_user_role('administrator')) { $title_section = 'Mensajes con ' . get_option('blogname'); wpdc_the_section_messages(get_user_notification_track(get_current_user_id(), 'type', 'message'), 'user_messages', $title_section); } else { ?> <!-- content --> <section class="wrap wrap--content wrap--shadow"> <h3 class="title title--section"><?php the_title(); ?> </h3> <?php if (get_option('asoc_email') != '' || get_option('asoc_adress') != '' || get_option('asoc_tlf') != '') { ?> <div class="wrap wrap--frame text--right"> <?php if (get_option('asoc_name') != '') {
include locate_template('templates/sections/user-info.php'); ?> <?php if (is_user_role('editor') || is_user_role('administrator') || $user_info->ID == get_current_user_id()) { $userdata = ['DNI' => get_the_author_meta('dbem_dnie', $user_info->ID), 'Fecha de nacimiento' => get_the_author_meta('bornday', $user_info->ID), 'Teléfono' => get_the_author_meta('dbem_phone', $user_info->ID), 'Dirección' => get_the_author_meta('dbem_address', $user_info->ID), 'Estudios' => get_the_author_meta('titulacion', $user_info->ID), 'Centro de estudios' => get_the_author_meta('centro_de_estudios', $user_info->ID)]; /* Datos de asociado */ if ($user_info->ID == get_current_user_id()) { $title_section = 'Tus datos de asociado'; } else { $title_section = 'Datos de asociado'; } wpdc_the_section_custom($userdata, 'userdata', $title_section, true); /* Messages */ if ($user_info->ID == get_current_user_id()) { $title_section = 'Mensajes con ' . get_option('blogname'); } else { $title_section = 'Mensajes con ' . wpdc_get_user_name($user_info->ID); } wpdc_the_section_messages(get_user_notification_track($user_info->ID, 'type', 'message'), 'user_messages', $title_section, true); } if (is_user_role('editor') || is_user_role('administrator')) { /* Historial de registro */ wpdc_the_section_registry_track(get_user_registry_track($user_info->ID), 'user_track', 'Historial', true); } ?> </div><!-- end of flexboxer --> <?php get_footer();
<?php if (get_current_user_id() == get_query_var('author')) { ?> <div class="wrap wrap--frame wrap--notification wrap--notification__receive"> <h4>Hola <?php echo wpdc_get_user_name(get_current_user_id()); ?> </h4> <ul class="list list--notification"> <?php $notifications = array_reverse(get_user_notification_track(get_current_user_id())); $index = count($track); foreach ($notifications as $track) { if ($track['changeby'] == get_current_user_id()) { continue; } if ($track['status'] != 'new') { continue; } $output = '<li class="notification">'; if ($track['type'] == 'message') { $output .= '<span class="msg">' . $track['msg'] . '</span> '; } $output .= ' <span title="' . $track['date'] . '" class="js-date-fromnow">' . $track['date'] . '</span>'; $output .= '</li>'; echo $output; } ?> </ul> </div>