import React, { ReactElement, useEffect } from 'react';
import Head from 'next/head'
import DatePicker from "react-datepicker";
import "react-datepicker/dist/react-datepicker.css";
import dayjs from "dayjs";
import {useAppDispatch, useAppSelector} from "../../stores/hooks";
import {useRouter} from "next/router";
import { fetch } from '../../stores/users/usersSlice'
import {saveFile} from "../../helpers/fileSaver";
import dataFormatter from '../../helpers/dataFormatter';
import ImageField from "../../components/ImageField";
import LayoutAuthenticated from "../../layouts/Authenticated";
import {getPageTitle} from "../../config";
import SectionTitleLineWithButton from "../../components/SectionTitleLineWithButton";
import SectionMain from "../../components/SectionMain";
import CardBox from "../../components/CardBox";
import BaseButton from "../../components/BaseButton";
import BaseDivider from "../../components/BaseDivider";
import {mdiChartTimelineVariant} from "@mdi/js";
import {SwitchField} from "../../components/SwitchField";
import FormField from "../../components/FormField";


const UsersView = () => {
    const router = useRouter()
    const dispatch = useAppDispatch()
    const { users } = useAppSelector((state) => state.users)
    

    const { id } = router.query;
    
    function removeLastCharacter(str) {
      console.log(str,`str`)
      return str.slice(0, -1);
    }

    useEffect(() => {
        dispatch(fetch({ id }));
    }, [dispatch, id]);


    return (
      <>
          <Head>
              <title>{getPageTitle('View users')}</title>
          </Head>
          <SectionMain>
            <SectionTitleLineWithButton icon={mdiChartTimelineVariant} title={removeLastCharacter('View users')} main>
                <BaseButton
                  color='info'
                  label='Edit'
                  href={`/users/users-edit/?id=${id}`}
                />
            </SectionTitleLineWithButton>
            <CardBox>
            

              
                <div className={'mb-4'}>
                    <p className={'block font-bold mb-2'}>First Name</p>
                    <p>{users?.firstName}</p>
                </div>
              

              

              

              

              

              

              

              

              

              

              

              

              
              

              
                <div className={'mb-4'}>
                    <p className={'block font-bold mb-2'}>Last Name</p>
                    <p>{users?.lastName}</p>
                </div>
              

              

              

              

              

              

              

              

              

              

              

              

              
              

              
                <div className={'mb-4'}>
                    <p className={'block font-bold mb-2'}>Phone Number</p>
                    <p>{users?.phoneNumber}</p>
                </div>
              

              

              

              

              

              

              

              

              

              

              

              

              
              

              
                <div className={'mb-4'}>
                    <p className={'block font-bold mb-2'}>E-Mail</p>
                    <p>{users?.email}</p>
                </div>
              

              

              

              

              

              

              

              

              

              

              

              

              
              

              

              

              

              

              

              

              

              

              
                <FormField label='Disabled'>
                    <SwitchField
                      field={{name: 'disabled', value: users?.disabled}}
                      form={{setFieldValue: () => null}}
                      disabled
                    />
                </FormField>
              

              

              

              

              
              

              

              

              

              

              

              

              

              

              

              

              

              
                <div className={'mb-4'}>
                    <p className={'block font-bold mb-2'}>Avatar</p>
                    {users?.avatar?.length
                      ? (
                        <ImageField
                          name={'avatar'}
                          image={users?.avatar}
                          className='w-20 h-20'
                        />
                      ) : <p>No Avatar</p>
                    }
                </div>
              

              
              

              

              

              

              

              

              

              

              

              

              
              
                <div className={'mb-4'}>
                    <p className={'block font-bold mb-2'}>App Role</p>
                    
                    
                    
                    
                        <p>{users?.app_role?.name ?? 'No data'}</p>
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                    
                </div>
                 
              

              

              

              
              

              

              

              

              

              

              

              

              

              

              

              
                <>
                    <p className={'block font-bold mb-2'}>Custom Permissions</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                
                                    <th>Name</th>
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.custom_permissions && Array.isArray(users.custom_permissions) &&
                              users.custom_permissions.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/permissions/permissions-view/?id=${item.id}`)}>
                                  
                                    
                                    
                                  
                                    
                                    <td data-label="name">
                                        { item.name }
                                    </td>
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.custom_permissions?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
              

              

              
              

                
                
                
                
                <>
                    <p className={'block font-bold mb-2'}>User_physical_baselines User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>Height(cm)</th>
                                
                                
                                
                                <th>Height(ft)</th>
                                
                                
                                
                                <th>Height(in)</th>
                                
                                
                                
                                <th>Weight(kg)</th>
                                
                                
                                
                                <th>Weight(lb)</th>
                                
                                
                                
                                <th>WristCircumference(cm)</th>
                                
                                
                                
                                <th>DominantHand</th>
                                
                                
                                
                                <th>FitzpatrickSkinType</th>
                                
                                
                                
                                <th>BloodType</th>
                                
                                
                                
                                <th>RhFactor</th>
                                
                                
                                
                                <th>BodyFrameSize</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.user_physical_baselines_user && Array.isArray(users.user_physical_baselines_user) &&
                              users.user_physical_baselines_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/user_physical_baselines/user_physical_baselines-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="height_cm">
                                        { item.height_cm }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="height_ft">
                                        { item.height_ft }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="height_in">
                                        { item.height_in }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="weight_kg">
                                        { item.weight_kg }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="weight_lb">
                                        { item.weight_lb }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="wrist_circumference_cm">
                                        { item.wrist_circumference_cm }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="dominant_hand">
                                        { item.dominant_hand }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="fitzpatrick_skin_type">
                                        { item.fitzpatrick_skin_type }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="blood_type">
                                        { item.blood_type }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="rh_factor">
                                        { item.rh_factor }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="body_frame_size">
                                        { item.body_frame_size }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.user_physical_baselines_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>User_lifestyle_baselines User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>TypicalBedtime</th>
                                
                                
                                
                                <th>TypicalWakeTime</th>
                                
                                
                                
                                <th>AlcoholConsumption</th>
                                
                                
                                
                                <th>TobaccoorNicotineUse</th>
                                
                                
                                
                                <th>RecreationalSubstanceUse</th>
                                
                                
                                
                                <th>CaffeineServingsperDay</th>
                                
                                
                                
                                <th>TypicalStressLevel(1-10)</th>
                                
                                
                                
                                <th>OccupationType</th>
                                
                                
                                
                                <th>AverageDailyStepsEstimate</th>
                                
                                
                                
                                <th>CurrentlyExercises</th>
                                
                                
                                
                                <th>ExerciseTypes</th>
                                
                                
                                
                                <th>DietPattern</th>
                                
                                
                                
                                <th>DietPatternOther</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.user_lifestyle_baselines_user && Array.isArray(users.user_lifestyle_baselines_user) &&
                              users.user_lifestyle_baselines_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/user_lifestyle_baselines/user_lifestyle_baselines-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="typical_bedtime">
                                        { item.typical_bedtime }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="typical_wake_time">
                                        { item.typical_wake_time }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="alcohol_use">
                                        { item.alcohol_use }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="tobacco_nicotine_use">
                                        { item.tobacco_nicotine_use }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="recreational_substance_use">
                                        { item.recreational_substance_use }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="caffeine_servings_per_day">
                                        { item.caffeine_servings_per_day }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="typical_stress_level">
                                        { item.typical_stress_level }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="occupation_type">
                                        { item.occupation_type }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="avg_daily_steps_estimate">
                                        { item.avg_daily_steps_estimate }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="currently_exercises">
                                        { dataFormatter.booleanFormatter(item.currently_exercises) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="exercise_types">
                                        { item.exercise_types }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="diet_pattern">
                                        { item.diet_pattern }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="diet_pattern_other">
                                        { item.diet_pattern_other }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.user_lifestyle_baselines_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Goals User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>GoalType</th>
                                
                                
                                
                                <th>FollowUpAnswer</th>
                                
                                
                                
                                <th>TargetDate</th>
                                
                                
                                
                                <th>Active</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.goals_user && Array.isArray(users.goals_user) &&
                              users.goals_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/goals/goals-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="goal_type">
                                        { item.goal_type }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="follow_up_answer">
                                        { item.follow_up_answer }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="target_date">
                                        { dataFormatter.dateTimeFormatter(item.target_date) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="is_active">
                                        { dataFormatter.booleanFormatter(item.is_active) }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.goals_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Conditions User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>ConditionName</th>
                                
                                
                                
                                <th>Status</th>
                                
                                
                                
                                <th>DateDiagnosed</th>
                                
                                
                                
                                <th>DiagnosingDoctor</th>
                                
                                
                                
                                <th>ManagementPlan</th>
                                
                                
                                
                                <th>Notes</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.conditions_user && Array.isArray(users.conditions_user) &&
                              users.conditions_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/conditions/conditions-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="condition_name">
                                        { item.condition_name }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="status">
                                        { item.status }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="date_diagnosed">
                                        { dataFormatter.dateTimeFormatter(item.date_diagnosed) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="diagnosing_doctor">
                                        { item.diagnosing_doctor }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="management_plan">
                                        { item.management_plan }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="notes">
                                        { item.notes }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.conditions_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Surgeries User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>Surgery</th>
                                
                                
                                
                                <th>SurgeryDate</th>
                                
                                
                                
                                <th>Notes</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.surgeries_user && Array.isArray(users.surgeries_user) &&
                              users.surgeries_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/surgeries/surgeries-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="surgery_name">
                                        { item.surgery_name }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="surgery_date">
                                        { dataFormatter.dateTimeFormatter(item.surgery_date) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="notes">
                                        { item.notes }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.surgeries_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Implants_devices User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>DeviceorImplant</th>
                                
                                
                                
                                <th>ImplantDate</th>
                                
                                
                                
                                <th>Notes</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.implants_devices_user && Array.isArray(users.implants_devices_user) &&
                              users.implants_devices_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/implants_devices/implants_devices-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="device_name">
                                        { item.device_name }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="implant_date">
                                        { dataFormatter.dateTimeFormatter(item.implant_date) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="notes">
                                        { item.notes }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.implants_devices_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Allergies User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>AllergyCategory</th>
                                
                                
                                
                                <th>Allergen</th>
                                
                                
                                
                                <th>Severity</th>
                                
                                
                                
                                <th>ReactionNotes</th>
                                
                                
                                
                                <th>CarriesEpinephrine</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.allergies_user && Array.isArray(users.allergies_user) &&
                              users.allergies_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/allergies/allergies-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="allergy_category">
                                        { item.allergy_category }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="allergen">
                                        { item.allergen }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="severity">
                                        { item.severity }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="reaction_notes">
                                        { item.reaction_notes }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="carries_epinephrine">
                                        { dataFormatter.booleanFormatter(item.carries_epinephrine) }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.allergies_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Family_histories User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>FamilySide</th>
                                
                                
                                
                                <th>Condition</th>
                                
                                
                                
                                <th>Notes</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.family_histories_user && Array.isArray(users.family_histories_user) &&
                              users.family_histories_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/family_histories/family_histories-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="side">
                                        { item.side }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="condition_name">
                                        { item.condition_name }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="notes">
                                        { item.notes }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.family_histories_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Healthcare_providers User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>ProviderType</th>
                                
                                
                                
                                <th>ProviderName</th>
                                
                                
                                
                                <th>ClinicorPractice</th>
                                
                                
                                
                                <th>Phone</th>
                                
                                
                                
                                <th>Email</th>
                                
                                
                                
                                <th>Address</th>
                                
                                
                                
                                <th>Notes</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.healthcare_providers_user && Array.isArray(users.healthcare_providers_user) &&
                              users.healthcare_providers_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/healthcare_providers/healthcare_providers-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="provider_type">
                                        { item.provider_type }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="provider_name">
                                        { item.provider_name }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="clinic_name">
                                        { item.clinic_name }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="phone">
                                        { item.phone }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="email">
                                        { item.email }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="address">
                                        { item.address }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="notes">
                                        { item.notes }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.healthcare_providers_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Pharmacies User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>PharmacyName</th>
                                
                                
                                
                                <th>Phone</th>
                                
                                
                                
                                <th>Address</th>
                                
                                
                                
                                <th>Notes</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.pharmacies_user && Array.isArray(users.pharmacies_user) &&
                              users.pharmacies_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/pharmacies/pharmacies-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="pharmacy_name">
                                        { item.pharmacy_name }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="phone">
                                        { item.phone }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="address">
                                        { item.address }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="notes">
                                        { item.notes }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.pharmacies_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Medications User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>MedicationName</th>
                                
                                
                                
                                <th>DoseAmount</th>
                                
                                
                                
                                <th>DoseUnit</th>
                                
                                
                                
                                <th>Frequency</th>
                                
                                
                                
                                <th>EveryXHours</th>
                                
                                
                                
                                <th>FrequencyNotes</th>
                                
                                
                                
                                <th>Route</th>
                                
                                
                                
                                
                                
                                
                                
                                <th>ConditionTreated</th>
                                
                                
                                
                                <th>StartDate</th>
                                
                                
                                
                                <th>EndDate</th>
                                
                                
                                
                                <th>RefillReminderDate</th>
                                
                                
                                
                                <th>RemindMetoTakeIt</th>
                                
                                
                                
                                <th>ControlledSubstance</th>
                                
                                
                                
                                
                                
                                <th>Instructions</th>
                                
                                
                                
                                <th>Notes</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.medications_user && Array.isArray(users.medications_user) &&
                              users.medications_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/medications/medications-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="medication_name">
                                        { item.medication_name }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="dose_amount">
                                        { item.dose_amount }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="dose_unit">
                                        { item.dose_unit }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="frequency_type">
                                        { item.frequency_type }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="frequency_interval_hours">
                                        { item.frequency_interval_hours }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="frequency_notes">
                                        { item.frequency_notes }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="route">
                                        { item.route }
                                    </td>
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    <td data-label="condition_treated">
                                        { item.condition_treated }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="start_date">
                                        { dataFormatter.dateTimeFormatter(item.start_date) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="end_date">
                                        { dataFormatter.dateTimeFormatter(item.end_date) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="refill_reminder_date">
                                        { dataFormatter.dateTimeFormatter(item.refill_reminder_date) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="reminders_enabled">
                                        { dataFormatter.booleanFormatter(item.reminders_enabled) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="is_controlled_substance">
                                        { dataFormatter.booleanFormatter(item.is_controlled_substance) }
                                    </td>
                                    
                                    
                                    
                                    
                                    
                                    <td data-label="instructions">
                                        { item.instructions }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="notes">
                                        { item.notes }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.medications_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                
                
                <>
                    <p className={'block font-bold mb-2'}>Supplements User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>SupplementName</th>
                                
                                
                                
                                <th>Form</th>
                                
                                
                                
                                <th>DoseAmount</th>
                                
                                
                                
                                <th>DoseUnit</th>
                                
                                
                                
                                <th>Timing</th>
                                
                                
                                
                                <th>WithFood</th>
                                
                                
                                
                                <th>Brand</th>
                                
                                
                                
                                <th>CostperDose</th>
                                
                                
                                
                                <th>ReasonforTaking</th>
                                
                                
                                
                                <th>RemindersEnabled</th>
                                
                                
                                
                                <th>CyclingEnabled</th>
                                
                                
                                
                                <th>CycleOnDays</th>
                                
                                
                                
                                <th>CycleOffDays</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.supplements_user && Array.isArray(users.supplements_user) &&
                              users.supplements_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/supplements/supplements-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="supplement_name">
                                        { item.supplement_name }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="form">
                                        { item.form }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="dose_amount">
                                        { item.dose_amount }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="dose_unit">
                                        { item.dose_unit }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="timing">
                                        { item.timing }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="with_food">
                                        { item.with_food }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="brand">
                                        { item.brand }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="cost_per_dose">
                                        { item.cost_per_dose }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="reason">
                                        { item.reason }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="reminders_enabled">
                                        { dataFormatter.booleanFormatter(item.reminders_enabled) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="cycling_enabled">
                                        { dataFormatter.booleanFormatter(item.cycling_enabled) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="cycle_on_days">
                                        { item.cycle_on_days }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="cycle_off_days">
                                        { item.cycle_off_days }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.supplements_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                
                
                
                
                <>
                    <p className={'block font-bold mb-2'}>Workout_schedules User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                
                                
                                <th>ScheduledStart</th>
                                
                                
                                
                                <th>ScheduledEnd</th>
                                
                                
                                
                                <th>ScheduleType</th>
                                
                                
                                
                                <th>Notes</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.workout_schedules_user && Array.isArray(users.workout_schedules_user) &&
                              users.workout_schedules_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/workout_schedules/workout_schedules-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    
                                    
                                    <td data-label="scheduled_start">
                                        { dataFormatter.dateTimeFormatter(item.scheduled_start) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="scheduled_end">
                                        { dataFormatter.dateTimeFormatter(item.scheduled_end) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="schedule_type">
                                        { item.schedule_type }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="notes">
                                        { item.notes }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.workout_schedules_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Training_blocks User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>BlockName</th>
                                
                                
                                
                                <th>StartDate</th>
                                
                                
                                
                                <th>EndDate</th>
                                
                                
                                
                                <th>Focus</th>
                                
                                
                                
                                <th>Notes</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.training_blocks_user && Array.isArray(users.training_blocks_user) &&
                              users.training_blocks_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/training_blocks/training_blocks-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="block_name">
                                        { item.block_name }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="start_date">
                                        { dataFormatter.dateTimeFormatter(item.start_date) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="end_date">
                                        { dataFormatter.dateTimeFormatter(item.end_date) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="focus">
                                        { item.focus }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="notes">
                                        { item.notes }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.training_blocks_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Workout_sessions User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                
                                
                                <th>StartedAt</th>
                                
                                
                                
                                <th>EndedAt</th>
                                
                                
                                
                                <th>Duration(minutes)</th>
                                
                                
                                
                                <th>EstimatedCalories</th>
                                
                                
                                
                                <th>TotalVolume(kg)</th>
                                
                                
                                
                                <th>SatisfactionRating(1-5)</th>
                                
                                
                                
                                <th>Notes</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.workout_sessions_user && Array.isArray(users.workout_sessions_user) &&
                              users.workout_sessions_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/workout_sessions/workout_sessions-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    
                                    
                                    <td data-label="started_at">
                                        { dataFormatter.dateTimeFormatter(item.started_at) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="ended_at">
                                        { dataFormatter.dateTimeFormatter(item.ended_at) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="duration_minutes">
                                        { item.duration_minutes }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="estimated_calories">
                                        { item.estimated_calories }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="total_volume_kg">
                                        { item.total_volume_kg }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="satisfaction_rating">
                                        { item.satisfaction_rating }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="notes">
                                        { item.notes }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.workout_sessions_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                
                <>
                    <p className={'block font-bold mb-2'}>Cardio_sessions User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>ActivityType</th>
                                
                                
                                
                                <th>StartedAt</th>
                                
                                
                                
                                <th>EndedAt</th>
                                
                                
                                
                                <th>Duration(minutes)</th>
                                
                                
                                
                                <th>Distance(km)</th>
                                
                                
                                
                                <th>AverageHeartRate</th>
                                
                                
                                
                                <th>PerceivedEffort(1-10)</th>
                                
                                
                                
                                <th>Calories</th>
                                
                                
                                
                                <th>RouteNotes</th>
                                
                                
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.cardio_sessions_user && Array.isArray(users.cardio_sessions_user) &&
                              users.cardio_sessions_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/cardio_sessions/cardio_sessions-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="activity_type">
                                        { item.activity_type }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="started_at">
                                        { dataFormatter.dateTimeFormatter(item.started_at) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="ended_at">
                                        { dataFormatter.dateTimeFormatter(item.ended_at) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="duration_minutes">
                                        { item.duration_minutes }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="distance_km">
                                        { item.distance_km }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="avg_heart_rate">
                                        { item.avg_heart_rate }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="perceived_effort">
                                        { item.perceived_effort }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="calories">
                                        { item.calories }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="route_notes">
                                        { item.route_notes }
                                    </td>
                                    
                                    
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.cardio_sessions_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Recovery_logs User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>LoggedAt</th>
                                
                                
                                
                                <th>RestingHeartRate</th>
                                
                                
                                
                                <th>HRV(ms)</th>
                                
                                
                                
                                <th>StressLevel(1-10)</th>
                                
                                
                                
                                <th>RecoveryScore(0-100)</th>
                                
                                
                                
                                <th>RecommendedIntensity</th>
                                
                                
                                
                                <th>Notes</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.recovery_logs_user && Array.isArray(users.recovery_logs_user) &&
                              users.recovery_logs_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/recovery_logs/recovery_logs-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="logged_at">
                                        { dataFormatter.dateTimeFormatter(item.logged_at) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="resting_heart_rate">
                                        { item.resting_heart_rate }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="hrv_ms">
                                        { item.hrv_ms }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="stress_level">
                                        { item.stress_level }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="recovery_score">
                                        { item.recovery_score }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="recommended_intensity">
                                        { item.recommended_intensity }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="notes">
                                        { item.notes }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.recovery_logs_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Heat_cold_exposures User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>ExposureType</th>
                                
                                
                                
                                <th>StartedAt</th>
                                
                                
                                
                                <th>EndedAt</th>
                                
                                
                                
                                <th>Duration(minutes)</th>
                                
                                
                                
                                <th>Temperature(C)</th>
                                
                                
                                
                                <th>Notes</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.heat_cold_exposures_user && Array.isArray(users.heat_cold_exposures_user) &&
                              users.heat_cold_exposures_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/heat_cold_exposures/heat_cold_exposures-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="exposure_type">
                                        { item.exposure_type }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="started_at">
                                        { dataFormatter.dateTimeFormatter(item.started_at) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="ended_at">
                                        { dataFormatter.dateTimeFormatter(item.ended_at) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="duration_minutes">
                                        { item.duration_minutes }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="temperature_c">
                                        { item.temperature_c }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="notes">
                                        { item.notes }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.heat_cold_exposures_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Flexibility_assessments User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>AssessedAt</th>
                                
                                
                                
                                <th>SitandReachScore</th>
                                
                                
                                
                                <th>ShoulderMobilityScore</th>
                                
                                
                                
                                <th>HipFlexorLengthScore</th>
                                
                                
                                
                                <th>HamstringLengthScore</th>
                                
                                
                                
                                <th>AnkleDorsiflexionScore</th>
                                
                                
                                
                                <th>Notes</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.flexibility_assessments_user && Array.isArray(users.flexibility_assessments_user) &&
                              users.flexibility_assessments_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/flexibility_assessments/flexibility_assessments-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="assessed_at">
                                        { dataFormatter.dateTimeFormatter(item.assessed_at) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="sit_and_reach_score">
                                        { item.sit_and_reach_score }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="shoulder_mobility_score">
                                        { item.shoulder_mobility_score }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="hip_flexor_score">
                                        { item.hip_flexor_score }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="hamstring_score">
                                        { item.hamstring_score }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="ankle_dorsiflexion_score">
                                        { item.ankle_dorsiflexion_score }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="notes">
                                        { item.notes }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.flexibility_assessments_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                
                <>
                    <p className={'block font-bold mb-2'}>Recipes User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>RecipeName</th>
                                
                                
                                
                                
                                
                                <th>PrepTime(minutes)</th>
                                
                                
                                
                                <th>CookTime(minutes)</th>
                                
                                
                                
                                <th>Servings</th>
                                
                                
                                
                                <th>Difficulty</th>
                                
                                
                                
                                <th>Tags</th>
                                
                                
                                
                                <th>Ingredients</th>
                                
                                
                                
                                <th>Instructions</th>
                                
                                
                                
                                <th>NutritionPerServingJSON</th>
                                
                                
                                
                                <th>Favourite</th>
                                
                                
                                
                                <th>Rating(1-5)</th>
                                
                                
                                
                                <th>SourceURL</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.recipes_user && Array.isArray(users.recipes_user) &&
                              users.recipes_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/recipes/recipes-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="recipe_name">
                                        { item.recipe_name }
                                    </td>
                                    
                                    
                                    
                                    
                                    
                                    <td data-label="prep_time_minutes">
                                        { item.prep_time_minutes }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="cook_time_minutes">
                                        { item.cook_time_minutes }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="servings">
                                        { item.servings }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="difficulty">
                                        { item.difficulty }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="tags_csv">
                                        { item.tags_csv }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="ingredients_text">
                                        { item.ingredients_text }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="instructions_text">
                                        { item.instructions_text }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="nutrition_per_serving_json">
                                        { item.nutrition_per_serving_json }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="is_favourite">
                                        { dataFormatter.booleanFormatter(item.is_favourite) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="rating">
                                        { item.rating }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="source_url">
                                        { item.source_url }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.recipes_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Recipe_collections User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>CollectionName</th>
                                
                                
                                
                                <th>Description</th>
                                
                                
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.recipe_collections_user && Array.isArray(users.recipe_collections_user) &&
                              users.recipe_collections_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/recipe_collections/recipe_collections-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="collection_name">
                                        { item.collection_name }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="description">
                                        { item.description }
                                    </td>
                                    
                                    
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.recipe_collections_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Meals User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>LoggedAt</th>
                                
                                
                                
                                <th>MealType</th>
                                
                                
                                
                                <th>MealTitle</th>
                                
                                
                                
                                
                                
                                
                                
                                <th>Notes</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.meals_user && Array.isArray(users.meals_user) &&
                              users.meals_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/meals/meals-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="logged_at">
                                        { dataFormatter.dateTimeFormatter(item.logged_at) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="meal_type">
                                        { item.meal_type }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="meal_title">
                                        { item.meal_title }
                                    </td>
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    <td data-label="notes">
                                        { item.notes }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.meals_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                
                <>
                    <p className={'block font-bold mb-2'}>Nutrition_targets User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>EffectiveFrom</th>
                                
                                
                                
                                <th>EffectiveTo</th>
                                
                                
                                
                                <th>BMR</th>
                                
                                
                                
                                <th>TDEE</th>
                                
                                
                                
                                <th>GoalMode</th>
                                
                                
                                
                                <th>CalorieTarget</th>
                                
                                
                                
                                <th>ProteinTarget(g)</th>
                                
                                
                                
                                <th>CarbTarget(g)</th>
                                
                                
                                
                                <th>FatTarget(g)</th>
                                
                                
                                
                                <th>MacroPresetName</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.nutrition_targets_user && Array.isArray(users.nutrition_targets_user) &&
                              users.nutrition_targets_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/nutrition_targets/nutrition_targets-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="effective_from">
                                        { dataFormatter.dateTimeFormatter(item.effective_from) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="effective_to">
                                        { dataFormatter.dateTimeFormatter(item.effective_to) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="bmr">
                                        { item.bmr }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="tdee">
                                        { item.tdee }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="goal_mode">
                                        { item.goal_mode }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="calorie_target">
                                        { item.calorie_target }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="protein_target_g">
                                        { item.protein_target_g }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="carb_target_g">
                                        { item.carb_target_g }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="fat_target_g">
                                        { item.fat_target_g }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="macro_preset_name">
                                        { item.macro_preset_name }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.nutrition_targets_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Meal_plans User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>WeekStartDate</th>
                                
                                
                                
                                <th>PeopleCount</th>
                                
                                
                                
                                <th>CookingSkillLevel</th>
                                
                                
                                
                                <th>DietaryRestrictions</th>
                                
                                
                                
                                <th>CuisinePreferences</th>
                                
                                
                                
                                <th>PrepTimeAvailableperDay(minutes)</th>
                                
                                
                                
                                <th>TargetCaloriesperDay</th>
                                
                                
                                
                                <th>AIPlanJSON</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.meal_plans_user && Array.isArray(users.meal_plans_user) &&
                              users.meal_plans_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/meal_plans/meal_plans-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="week_start_date">
                                        { dataFormatter.dateTimeFormatter(item.week_start_date) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="people_count">
                                        { item.people_count }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="cooking_skill_level">
                                        { item.cooking_skill_level }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="dietary_restrictions">
                                        { item.dietary_restrictions }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="cuisine_preferences">
                                        { item.cuisine_preferences }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="prep_time_minutes_per_day">
                                        { item.prep_time_minutes_per_day }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="target_calories_per_day">
                                        { item.target_calories_per_day }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="ai_plan_json">
                                        { item.ai_plan_json }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.meal_plans_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                
                <>
                    <p className={'block font-bold mb-2'}>Grocery_lists User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                
                                
                                <th>GeneratedAt</th>
                                
                                
                                
                                <th>Title</th>
                                
                                
                                
                                <th>Notes</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.grocery_lists_user && Array.isArray(users.grocery_lists_user) &&
                              users.grocery_lists_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/grocery_lists/grocery_lists-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    
                                    
                                    <td data-label="generated_at">
                                        { dataFormatter.dateTimeFormatter(item.generated_at) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="title">
                                        { item.title }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="notes">
                                        { item.notes }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.grocery_lists_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                
                <>
                    <p className={'block font-bold mb-2'}>Hydration_logs User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>LoggedAt</th>
                                
                                
                                
                                <th>BeverageType</th>
                                
                                
                                
                                <th>Volume(ml)</th>
                                
                                
                                
                                <th>CountsTowardHydration</th>
                                
                                
                                
                                <th>ContainerLabel</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.hydration_logs_user && Array.isArray(users.hydration_logs_user) &&
                              users.hydration_logs_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/hydration_logs/hydration_logs-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="logged_at">
                                        { dataFormatter.dateTimeFormatter(item.logged_at) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="beverage_type">
                                        { item.beverage_type }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="volume_ml">
                                        { item.volume_ml }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="counts_toward_hydration">
                                        { dataFormatter.booleanFormatter(item.counts_toward_hydration) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="container_label">
                                        { item.container_label }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.hydration_logs_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Fasting_sessions User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>Protocol</th>
                                
                                
                                
                                <th>FastStart</th>
                                
                                
                                
                                <th>FastEnd</th>
                                
                                
                                
                                <th>EatingWindowStart</th>
                                
                                
                                
                                <th>EatingWindowEnd</th>
                                
                                
                                
                                <th>Notes</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.fasting_sessions_user && Array.isArray(users.fasting_sessions_user) &&
                              users.fasting_sessions_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/fasting_sessions/fasting_sessions-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="protocol">
                                        { item.protocol }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="fast_start">
                                        { dataFormatter.dateTimeFormatter(item.fast_start) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="fast_end">
                                        { dataFormatter.dateTimeFormatter(item.fast_end) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="eating_window_start">
                                        { dataFormatter.dateTimeFormatter(item.eating_window_start) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="eating_window_end">
                                        { dataFormatter.dateTimeFormatter(item.eating_window_end) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="notes">
                                        { item.notes }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.fasting_sessions_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Ketone_glucose_logs User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>LoggedAt</th>
                                
                                
                                
                                <th>MeasurementType</th>
                                
                                
                                
                                <th>Value</th>
                                
                                
                                
                                <th>Unit</th>
                                
                                
                                
                                <th>Context</th>
                                
                                
                                
                                <th>Notes</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.ketone_glucose_logs_user && Array.isArray(users.ketone_glucose_logs_user) &&
                              users.ketone_glucose_logs_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/ketone_glucose_logs/ketone_glucose_logs-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="logged_at">
                                        { dataFormatter.dateTimeFormatter(item.logged_at) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="measurement_type">
                                        { item.measurement_type }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="value">
                                        { item.value }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="unit">
                                        { item.unit }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="context">
                                        { item.context }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="notes">
                                        { item.notes }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.ketone_glucose_logs_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Bowel_movements User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>OccurredAt</th>
                                
                                
                                
                                <th>BristolStoolType</th>
                                
                                
                                
                                <th>Color</th>
                                
                                
                                
                                <th>BloodPresent</th>
                                
                                
                                
                                <th>MucusPresent</th>
                                
                                
                                
                                <th>AssociatedSymptoms</th>
                                
                                
                                
                                <th>Notes</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.bowel_movements_user && Array.isArray(users.bowel_movements_user) &&
                              users.bowel_movements_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/bowel_movements/bowel_movements-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="occurred_at">
                                        { dataFormatter.dateTimeFormatter(item.occurred_at) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="bristol_type">
                                        { item.bristol_type }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="color">
                                        { item.color }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="blood_present">
                                        { dataFormatter.booleanFormatter(item.blood_present) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="mucus_present">
                                        { dataFormatter.booleanFormatter(item.mucus_present) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="associated_symptoms">
                                        { item.associated_symptoms }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="notes">
                                        { item.notes }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.bowel_movements_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Gut_symptom_logs User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>LoggedAt</th>
                                
                                
                                
                                <th>SymptomType</th>
                                
                                
                                
                                <th>Severity(1-5)</th>
                                
                                
                                
                                <th>Notes</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.gut_symptom_logs_user && Array.isArray(users.gut_symptom_logs_user) &&
                              users.gut_symptom_logs_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/gut_symptom_logs/gut_symptom_logs-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="logged_at">
                                        { dataFormatter.dateTimeFormatter(item.logged_at) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="symptom_type">
                                        { item.symptom_type }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="severity">
                                        { item.severity }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="notes">
                                        { item.notes }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.gut_symptom_logs_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Health_metrics User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>MeasuredAt</th>
                                
                                
                                
                                <th>MetricType</th>
                                
                                
                                
                                <th>PrimaryValue</th>
                                
                                
                                
                                <th>SecondaryValue</th>
                                
                                
                                
                                <th>Unit</th>
                                
                                
                                
                                <th>PanelJSON</th>
                                
                                
                                
                                <th>DeviceUsed</th>
                                
                                
                                
                                <th>Fasting</th>
                                
                                
                                
                                <th>Notes</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.health_metrics_user && Array.isArray(users.health_metrics_user) &&
                              users.health_metrics_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/health_metrics/health_metrics-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="measured_at">
                                        { dataFormatter.dateTimeFormatter(item.measured_at) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="metric_type">
                                        { item.metric_type }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="value_primary">
                                        { item.value_primary }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="value_secondary">
                                        { item.value_secondary }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="unit">
                                        { item.unit }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="panel_json">
                                        { item.panel_json }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="device_used">
                                        { item.device_used }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="is_fasting">
                                        { dataFormatter.booleanFormatter(item.is_fasting) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="notes">
                                        { item.notes }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.health_metrics_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Symptom_logs User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>LoggedAt</th>
                                
                                
                                
                                <th>SymptomName</th>
                                
                                
                                
                                <th>Severity(1-10)</th>
                                
                                
                                
                                <th>BodyArea</th>
                                
                                
                                
                                <th>Status</th>
                                
                                
                                
                                <th>Duration(minutes)</th>
                                
                                
                                
                                <th>Triggers</th>
                                
                                
                                
                                <th>Notes</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.symptom_logs_user && Array.isArray(users.symptom_logs_user) &&
                              users.symptom_logs_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/symptom_logs/symptom_logs-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="logged_at">
                                        { dataFormatter.dateTimeFormatter(item.logged_at) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="symptom_name">
                                        { item.symptom_name }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="severity">
                                        { item.severity }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="body_area">
                                        { item.body_area }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="status">
                                        { item.status }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="duration_minutes">
                                        { item.duration_minutes }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="triggers">
                                        { item.triggers }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="notes">
                                        { item.notes }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.symptom_logs_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Medical_appointments User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                
                                
                                <th>AppointmentStart</th>
                                
                                
                                
                                <th>AppointmentEnd</th>
                                
                                
                                
                                <th>AppointmentType</th>
                                
                                
                                
                                <th>ClinicLocation</th>
                                
                                
                                
                                <th>NotestoDiscuss</th>
                                
                                
                                
                                <th>DocumentstoBring</th>
                                
                                
                                
                                <th>PostAppointmentNotes</th>
                                
                                
                                
                                <th>FollowUpInstructions</th>
                                
                                
                                
                                <th>FollowUpReminderAt</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.medical_appointments_user && Array.isArray(users.medical_appointments_user) &&
                              users.medical_appointments_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/medical_appointments/medical_appointments-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    
                                    
                                    <td data-label="appointment_start">
                                        { dataFormatter.dateTimeFormatter(item.appointment_start) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="appointment_end">
                                        { dataFormatter.dateTimeFormatter(item.appointment_end) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="appointment_type">
                                        { item.appointment_type }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="clinic_location">
                                        { item.clinic_location }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="notes_to_discuss">
                                        { item.notes_to_discuss }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="documents_to_bring">
                                        { item.documents_to_bring }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="post_appointment_notes">
                                        { item.post_appointment_notes }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="follow_up_instructions">
                                        { item.follow_up_instructions }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="follow_up_reminder_at">
                                        { dataFormatter.dateTimeFormatter(item.follow_up_reminder_at) }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.medical_appointments_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Lab_documents User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>DocumentDate</th>
                                
                                
                                
                                <th>Category</th>
                                
                                
                                
                                <th>Title</th>
                                
                                
                                
                                
                                
                                
                                
                                <th>ReviewedwithDoctor</th>
                                
                                
                                
                                <th>Notes</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.lab_documents_user && Array.isArray(users.lab_documents_user) &&
                              users.lab_documents_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/lab_documents/lab_documents-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="document_date">
                                        { dataFormatter.dateTimeFormatter(item.document_date) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="category">
                                        { item.category }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="title">
                                        { item.title }
                                    </td>
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    <td data-label="reviewed_with_doctor">
                                        { dataFormatter.booleanFormatter(item.reviewed_with_doctor) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="notes">
                                        { item.notes }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.lab_documents_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Vaccinations User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>VaccineName</th>
                                
                                
                                
                                <th>DateGiven</th>
                                
                                
                                
                                <th>DoseNumber</th>
                                
                                
                                
                                <th>BatchNumber</th>
                                
                                
                                
                                
                                
                                <th>BoosterDueDate</th>
                                
                                
                                
                                <th>Notes</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.vaccinations_user && Array.isArray(users.vaccinations_user) &&
                              users.vaccinations_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/vaccinations/vaccinations-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="vaccine_name">
                                        { item.vaccine_name }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="date_given">
                                        { dataFormatter.dateTimeFormatter(item.date_given) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="dose_number">
                                        { item.dose_number }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="batch_number">
                                        { item.batch_number }
                                    </td>
                                    
                                    
                                    
                                    
                                    
                                    <td data-label="booster_due_date">
                                        { dataFormatter.dateTimeFormatter(item.booster_due_date) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="notes">
                                        { item.notes }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.vaccinations_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Ai_chat_threads User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>ThreadTitle</th>
                                
                                
                                
                                <th>LastMessageAt</th>
                                
                                
                                
                                <th>Pinned</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.ai_chat_threads_user && Array.isArray(users.ai_chat_threads_user) &&
                              users.ai_chat_threads_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/ai_chat_threads/ai_chat_threads-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="thread_title">
                                        { item.thread_title }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="last_message_at">
                                        { dataFormatter.dateTimeFormatter(item.last_message_at) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="pinned">
                                        { dataFormatter.booleanFormatter(item.pinned) }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.ai_chat_threads_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                
                <>
                    <p className={'block font-bold mb-2'}>Ai_generations User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>GenerationType</th>
                                
                                
                                
                                <th>GeneratedAt</th>
                                
                                
                                
                                <th>PromptContextJSON</th>
                                
                                
                                
                                <th>ResultJSON</th>
                                
                                
                                
                                <th>StatusMessage</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.ai_generations_user && Array.isArray(users.ai_generations_user) &&
                              users.ai_generations_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/ai_generations/ai_generations-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="generation_type">
                                        { item.generation_type }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="generated_at">
                                        { dataFormatter.dateTimeFormatter(item.generated_at) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="prompt_context_json">
                                        { item.prompt_context_json }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="result_json">
                                        { item.result_json }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="status_message">
                                        { item.status_message }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.ai_generations_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Habits User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>HabitName</th>
                                
                                
                                
                                <th>IconName</th>
                                
                                
                                
                                <th>Category</th>
                                
                                
                                
                                <th>Frequency</th>
                                
                                
                                
                                <th>TimesperWeek</th>
                                
                                
                                
                                <th>SpecificDays</th>
                                
                                
                                
                                <th>EveryXDays</th>
                                
                                
                                
                                <th>TargetCountperDay</th>
                                
                                
                                
                                <th>TargetDuration(minutes)</th>
                                
                                
                                
                                <th>StartDate</th>
                                
                                
                                
                                <th>EndDate</th>
                                
                                
                                
                                <th>Motivation</th>
                                
                                
                                
                                <th>HabitStackingNote</th>
                                
                                
                                
                                <th>Active</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.habits_user && Array.isArray(users.habits_user) &&
                              users.habits_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/habits/habits-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="habit_name">
                                        { item.habit_name }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="icon_name">
                                        { item.icon_name }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="category">
                                        { item.category }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="frequency_type">
                                        { item.frequency_type }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="times_per_week">
                                        { item.times_per_week }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="specific_days_csv">
                                        { item.specific_days_csv }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="every_x_days">
                                        { item.every_x_days }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="target_count_per_day">
                                        { item.target_count_per_day }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="target_duration_minutes">
                                        { item.target_duration_minutes }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="start_date">
                                        { dataFormatter.dateTimeFormatter(item.start_date) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="end_date">
                                        { dataFormatter.dateTimeFormatter(item.end_date) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="motivation">
                                        { item.motivation }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="stacking_note">
                                        { item.stacking_note }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="is_active">
                                        { dataFormatter.booleanFormatter(item.is_active) }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.habits_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                
                <>
                    <p className={'block font-bold mb-2'}>Habit_challenges User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>ChallengeName</th>
                                
                                
                                
                                <th>ChallengeType</th>
                                
                                
                                
                                <th>StartDate</th>
                                
                                
                                
                                <th>EndDate</th>
                                
                                
                                
                                <th>Description</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.habit_challenges_user && Array.isArray(users.habit_challenges_user) &&
                              users.habit_challenges_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/habit_challenges/habit_challenges-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="challenge_name">
                                        { item.challenge_name }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="challenge_type">
                                        { item.challenge_type }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="start_date">
                                        { dataFormatter.dateTimeFormatter(item.start_date) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="end_date">
                                        { dataFormatter.dateTimeFormatter(item.end_date) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="description">
                                        { item.description }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.habit_challenges_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                
                <>
                    <p className={'block font-bold mb-2'}>Saved_articles User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                
                                
                                <th>FolderName</th>
                                
                                
                                
                                <th>SavedAt</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.saved_articles_user && Array.isArray(users.saved_articles_user) &&
                              users.saved_articles_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/saved_articles/saved_articles-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    
                                    
                                    <td data-label="folder_name">
                                        { item.folder_name }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="saved_at">
                                        { dataFormatter.dateTimeFormatter(item.saved_at) }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.saved_articles_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                
                <>
                    <p className={'block font-bold mb-2'}>Health_vault_documents User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>DocumentName</th>
                                
                                
                                
                                <th>DocumentDate</th>
                                
                                
                                
                                <th>Category</th>
                                
                                
                                
                                <th>IssuingInstitution</th>
                                
                                
                                
                                <th>Notes</th>
                                
                                
                                
                                <th>Shared</th>
                                
                                
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.health_vault_documents_user && Array.isArray(users.health_vault_documents_user) &&
                              users.health_vault_documents_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/health_vault_documents/health_vault_documents-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="document_name">
                                        { item.document_name }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="document_date">
                                        { dataFormatter.dateTimeFormatter(item.document_date) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="category">
                                        { item.category }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="issuing_institution">
                                        { item.issuing_institution }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="notes">
                                        { item.notes }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="shared">
                                        { dataFormatter.booleanFormatter(item.shared) }
                                    </td>
                                    
                                    
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.health_vault_documents_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Emergency_medical_cards User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>FullName</th>
                                
                                
                                
                                <th>DateofBirth</th>
                                
                                
                                
                                <th>BloodType</th>
                                
                                
                                
                                <th>CriticalAllergies</th>
                                
                                
                                
                                <th>CriticalConditions</th>
                                
                                
                                
                                <th>CriticalMedications</th>
                                
                                
                                
                                <th>EmergencyContacts</th>
                                
                                
                                
                                <th>TreatingDoctorContact</th>
                                
                                
                                
                                <th>OrganDonorStatus</th>
                                
                                
                                
                                <th>AdvanceDirectivesSummary</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.emergency_medical_cards_user && Array.isArray(users.emergency_medical_cards_user) &&
                              users.emergency_medical_cards_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/emergency_medical_cards/emergency_medical_cards-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="full_name">
                                        { item.full_name }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="date_of_birth">
                                        { dataFormatter.dateTimeFormatter(item.date_of_birth) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="blood_type">
                                        { item.blood_type }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="critical_allergies">
                                        { item.critical_allergies }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="critical_conditions">
                                        { item.critical_conditions }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="critical_medications">
                                        { item.critical_medications }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="emergency_contacts">
                                        { item.emergency_contacts }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="treating_doctor_contact">
                                        { item.treating_doctor_contact }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="organ_donor_status">
                                        { item.organ_donor_status }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="advance_directives_summary">
                                        { item.advance_directives_summary }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.emergency_medical_cards_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Advance_directives User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>DirectiveType</th>
                                
                                
                                
                                <th>Summary</th>
                                
                                
                                
                                
                                
                                <th>ProxyContactDetails</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.advance_directives_user && Array.isArray(users.advance_directives_user) &&
                              users.advance_directives_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/advance_directives/advance_directives-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="directive_type">
                                        { item.directive_type }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="summary">
                                        { item.summary }
                                    </td>
                                    
                                    
                                    
                                    
                                    
                                    <td data-label="proxy_contact_details">
                                        { item.proxy_contact_details }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.advance_directives_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Insurance_policies User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>ProviderName</th>
                                
                                
                                
                                <th>PolicyNumber</th>
                                
                                
                                
                                <th>GroupNumber</th>
                                
                                
                                
                                <th>CoverageType</th>
                                
                                
                                
                                <th>ContactPhone</th>
                                
                                
                                
                                <th>ClaimsContact</th>
                                
                                
                                
                                <th>PreAuthorisationNotes</th>
                                
                                
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.insurance_policies_user && Array.isArray(users.insurance_policies_user) &&
                              users.insurance_policies_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/insurance_policies/insurance_policies-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="provider_name">
                                        { item.provider_name }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="policy_number">
                                        { item.policy_number }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="group_number">
                                        { item.group_number }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="coverage_type">
                                        { item.coverage_type }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="contact_phone">
                                        { item.contact_phone }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="claims_contact">
                                        { item.claims_contact }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="preauthorisation_notes">
                                        { item.preauthorisation_notes }
                                    </td>
                                    
                                    
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.insurance_policies_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Family_groups OwnerUser</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                <th>GroupName</th>
                                
                                
                                
                                <th>InviteCode</th>
                                
                                
                                
                                
                                
                                <th>Notes</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.family_groups_owner_user && Array.isArray(users.family_groups_owner_user) &&
                              users.family_groups_owner_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/family_groups/family_groups-view/?id=${item.id}`)}>
                                    
                                    
                                    <td data-label="group_name">
                                        { item.group_name }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="invite_code">
                                        { item.invite_code }
                                    </td>
                                    
                                    
                                    
                                    
                                    
                                    <td data-label="notes">
                                        { item.notes }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.family_groups_owner_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Family_members User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                
                                
                                <th>MemberRole</th>
                                
                                
                                
                                <th>HasOwnAccount</th>
                                
                                
                                
                                <th>DisplayName</th>
                                
                                
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.family_members_user && Array.isArray(users.family_members_user) &&
                              users.family_members_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/family_members/family_members-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    
                                    
                                    <td data-label="member_role">
                                        { item.member_role }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="has_own_account">
                                        { dataFormatter.booleanFormatter(item.has_own_account) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="display_name">
                                        { item.display_name }
                                    </td>
                                    
                                    
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.family_members_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Sharing_permissions GranterUser</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                
                                
                                
                                
                                <th>DataCategory</th>
                                
                                
                                
                                <th>AccessLevel</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.sharing_permissions_granter_user && Array.isArray(users.sharing_permissions_granter_user) &&
                              users.sharing_permissions_granter_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/sharing_permissions/sharing_permissions-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    <td data-label="data_category">
                                        { item.data_category }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="access_level">
                                        { item.access_level }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.sharing_permissions_granter_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                <>
                    <p className={'block font-bold mb-2'}>Sharing_permissions GranteeUser</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                
                                
                                
                                
                                <th>DataCategory</th>
                                
                                
                                
                                <th>AccessLevel</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.sharing_permissions_grantee_user && Array.isArray(users.sharing_permissions_grantee_user) &&
                              users.sharing_permissions_grantee_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/sharing_permissions/sharing_permissions-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    
                                    <td data-label="data_category">
                                        { item.data_category }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="access_level">
                                        { item.access_level }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.sharing_permissions_grantee_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Mood_logs User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>LoggedAt</th>
                                
                                
                                
                                <th>Mood(1-10)</th>
                                
                                
                                
                                <th>EmotionTags</th>
                                
                                
                                
                                <th>EnergyLevel(1-10)</th>
                                
                                
                                
                                <th>AnxietyLevel(1-10)</th>
                                
                                
                                
                                <th>ContributingFactors</th>
                                
                                
                                
                                
                                
                                <th>JournalEntry</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.mood_logs_user && Array.isArray(users.mood_logs_user) &&
                              users.mood_logs_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/mood_logs/mood_logs-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="logged_at">
                                        { dataFormatter.dateTimeFormatter(item.logged_at) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="mood_score">
                                        { item.mood_score }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="emotion_tags_csv">
                                        { item.emotion_tags_csv }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="energy_level">
                                        { item.energy_level }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="anxiety_level">
                                        { item.anxiety_level }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="contributing_factors">
                                        { item.contributing_factors }
                                    </td>
                                    
                                    
                                    
                                    
                                    
                                    <td data-label="journal_entry">
                                        { item.journal_entry }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.mood_logs_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Mental_assessments User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>AssessmentType</th>
                                
                                
                                
                                <th>TakenAt</th>
                                
                                
                                
                                <th>TotalScore</th>
                                
                                
                                
                                <th>ResponsesJSON</th>
                                
                                
                                
                                <th>InterpretationNotes</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.mental_assessments_user && Array.isArray(users.mental_assessments_user) &&
                              users.mental_assessments_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/mental_assessments/mental_assessments-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="assessment_type">
                                        { item.assessment_type }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="taken_at">
                                        { dataFormatter.dateTimeFormatter(item.taken_at) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="score_total">
                                        { item.score_total }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="responses_json">
                                        { item.responses_json }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="interpretation_notes">
                                        { item.interpretation_notes }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.mental_assessments_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Journal_entries User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>EntryDate</th>
                                
                                
                                
                                <th>Title</th>
                                
                                
                                
                                <th>Content</th>
                                
                                
                                
                                <th>EncryptionStatus</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.journal_entries_user && Array.isArray(users.journal_entries_user) &&
                              users.journal_entries_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/journal_entries/journal_entries-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="entry_date">
                                        { dataFormatter.dateTimeFormatter(item.entry_date) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="title">
                                        { item.title }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="content">
                                        { item.content }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="encryption_status">
                                        { item.encryption_status }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.journal_entries_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Breathing_sessions User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>StartedAt</th>
                                
                                
                                
                                <th>EndedAt</th>
                                
                                
                                
                                <th>Technique</th>
                                
                                
                                
                                <th>Duration(minutes)</th>
                                
                                
                                
                                <th>Notes</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.breathing_sessions_user && Array.isArray(users.breathing_sessions_user) &&
                              users.breathing_sessions_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/breathing_sessions/breathing_sessions-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="started_at">
                                        { dataFormatter.dateTimeFormatter(item.started_at) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="ended_at">
                                        { dataFormatter.dateTimeFormatter(item.ended_at) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="technique">
                                        { item.technique }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="duration_minutes">
                                        { item.duration_minutes }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="notes">
                                        { item.notes }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.breathing_sessions_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Stress_logs User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>LoggedAt</th>
                                
                                
                                
                                <th>StressLevel(1-10)</th>
                                
                                
                                
                                <th>Stressor</th>
                                
                                
                                
                                <th>PhysicalSymptoms</th>
                                
                                
                                
                                <th>CopingStrategyUsed</th>
                                
                                
                                
                                <th>Notes</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.stress_logs_user && Array.isArray(users.stress_logs_user) &&
                              users.stress_logs_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/stress_logs/stress_logs-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="logged_at">
                                        { dataFormatter.dateTimeFormatter(item.logged_at) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="stress_level">
                                        { item.stress_level }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="stressor">
                                        { item.stressor }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="physical_symptoms">
                                        { item.physical_symptoms }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="coping_strategy_used">
                                        { item.coping_strategy_used }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="notes">
                                        { item.notes }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.stress_logs_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Cognitive_tests User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>TestType</th>
                                
                                
                                
                                <th>TakenAt</th>
                                
                                
                                
                                <th>Score</th>
                                
                                
                                
                                <th>Duration(seconds)</th>
                                
                                
                                
                                <th>DetailsJSON</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.cognitive_tests_user && Array.isArray(users.cognitive_tests_user) &&
                              users.cognitive_tests_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/cognitive_tests/cognitive_tests-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="test_type">
                                        { item.test_type }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="taken_at">
                                        { dataFormatter.dateTimeFormatter(item.taken_at) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="score">
                                        { item.score }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="duration_seconds">
                                        { item.duration_seconds }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="details_json">
                                        { item.details_json }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.cognitive_tests_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Sleep_logs User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>Bedtime</th>
                                
                                
                                
                                <th>SleepOnsetTime</th>
                                
                                
                                
                                <th>AwakeningsCount</th>
                                
                                
                                
                                <th>FinalWakeTime</th>
                                
                                
                                
                                <th>OutofBedTime</th>
                                
                                
                                
                                <th>TotalSleepTime(minutes)</th>
                                
                                
                                
                                <th>SleepQuality(1-5)</th>
                                
                                
                                
                                <th>DreamRecall</th>
                                
                                
                                
                                <th>DreamNotes</th>
                                
                                
                                
                                <th>MorningEnergy(1-10)</th>
                                
                                
                                
                                <th>SleepAidsUsed</th>
                                
                                
                                
                                <th>Disturbances</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.sleep_logs_user && Array.isArray(users.sleep_logs_user) &&
                              users.sleep_logs_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/sleep_logs/sleep_logs-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="bedtime">
                                        { dataFormatter.dateTimeFormatter(item.bedtime) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="sleep_onset_time">
                                        { dataFormatter.dateTimeFormatter(item.sleep_onset_time) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="awakenings_count">
                                        { item.awakenings_count }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="final_wake_time">
                                        { dataFormatter.dateTimeFormatter(item.final_wake_time) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="out_of_bed_time">
                                        { dataFormatter.dateTimeFormatter(item.out_of_bed_time) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="total_sleep_minutes">
                                        { item.total_sleep_minutes }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="sleep_quality">
                                        { item.sleep_quality }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="dream_recall">
                                        { dataFormatter.booleanFormatter(item.dream_recall) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="dream_notes">
                                        { item.dream_notes }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="morning_energy">
                                        { item.morning_energy }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="sleep_aids_used">
                                        { item.sleep_aids_used }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="disturbances">
                                        { item.disturbances }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.sleep_logs_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Sleep_environment_logs User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>LoggedAt</th>
                                
                                
                                
                                <th>Temperature(C)</th>
                                
                                
                                
                                <th>NoiseLevel(1-10)</th>
                                
                                
                                
                                <th>LightLevel(1-10)</th>
                                
                                
                                
                                <th>BeddingComfort(1-10)</th>
                                
                                
                                
                                <th>ScreenTimeBeforeBed(minutes)</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.sleep_environment_logs_user && Array.isArray(users.sleep_environment_logs_user) &&
                              users.sleep_environment_logs_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/sleep_environment_logs/sleep_environment_logs-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="logged_at">
                                        { dataFormatter.dateTimeFormatter(item.logged_at) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="temperature_c">
                                        { item.temperature_c }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="noise_level">
                                        { item.noise_level }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="light_level">
                                        { item.light_level }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="bedding_comfort">
                                        { item.bedding_comfort }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="screen_time_before_bed_minutes">
                                        { item.screen_time_before_bed_minutes }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.sleep_environment_logs_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Nap_logs User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>NapStart</th>
                                
                                
                                
                                <th>NapEnd</th>
                                
                                
                                
                                <th>Duration(minutes)</th>
                                
                                
                                
                                <th>Quality(1-5)</th>
                                
                                
                                
                                <th>Notes</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.nap_logs_user && Array.isArray(users.nap_logs_user) &&
                              users.nap_logs_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/nap_logs/nap_logs-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="nap_start">
                                        { dataFormatter.dateTimeFormatter(item.nap_start) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="nap_end">
                                        { dataFormatter.dateTimeFormatter(item.nap_end) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="duration_minutes">
                                        { item.duration_minutes }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="quality">
                                        { item.quality }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="notes">
                                        { item.notes }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.nap_logs_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Menstrual_cycles User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>PeriodStart</th>
                                
                                
                                
                                <th>PeriodEnd</th>
                                
                                
                                
                                <th>Notes</th>
                                
                                
                                
                                <th>BreakthroughBleeding</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.menstrual_cycles_user && Array.isArray(users.menstrual_cycles_user) &&
                              users.menstrual_cycles_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/menstrual_cycles/menstrual_cycles-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="period_start">
                                        { dataFormatter.dateTimeFormatter(item.period_start) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="period_end">
                                        { dataFormatter.dateTimeFormatter(item.period_end) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="notes">
                                        { item.notes }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="breakthrough_bleeding">
                                        { dataFormatter.booleanFormatter(item.breakthrough_bleeding) }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.menstrual_cycles_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                
                <>
                    <p className={'block font-bold mb-2'}>Fertility_logs User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>LoggedAt</th>
                                
                                
                                
                                <th>BasalBodyTemperature(C)</th>
                                
                                
                                
                                <th>CervicalMucus</th>
                                
                                
                                
                                <th>LHTestResult</th>
                                
                                
                                
                                <th>CervicalPositionHeight</th>
                                
                                
                                
                                <th>CervicalPositionFirmness</th>
                                
                                
                                
                                <th>CervicalPositionOpenness</th>
                                
                                
                                
                                <th>Mode</th>
                                
                                
                                
                                <th>Notes</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.fertility_logs_user && Array.isArray(users.fertility_logs_user) &&
                              users.fertility_logs_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/fertility_logs/fertility_logs-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="logged_at">
                                        { dataFormatter.dateTimeFormatter(item.logged_at) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="bbt_c">
                                        { item.bbt_c }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="cervical_mucus">
                                        { item.cervical_mucus }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="lh_test_result">
                                        { item.lh_test_result }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="cervical_position_height">
                                        { item.cervical_position_height }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="cervical_position_firmness">
                                        { item.cervical_position_firmness }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="cervical_position_openness">
                                        { item.cervical_position_openness }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="mode">
                                        { item.mode }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="notes">
                                        { item.notes }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.fertility_logs_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Pregnancies User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>LastMenstrualPeriodDate</th>
                                
                                
                                
                                <th>ConceptionDate</th>
                                
                                
                                
                                <th>DueDate</th>
                                
                                
                                
                                <th>DeliveryDate</th>
                                
                                
                                
                                <th>Status</th>
                                
                                
                                
                                <th>BirthPlan</th>
                                
                                
                                
                                <th>Notes</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.pregnancies_user && Array.isArray(users.pregnancies_user) &&
                              users.pregnancies_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/pregnancies/pregnancies-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="last_menstrual_period_date">
                                        { dataFormatter.dateTimeFormatter(item.last_menstrual_period_date) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="conception_date">
                                        { dataFormatter.dateTimeFormatter(item.conception_date) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="due_date">
                                        { dataFormatter.dateTimeFormatter(item.due_date) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="delivery_date">
                                        { dataFormatter.dateTimeFormatter(item.delivery_date) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="status">
                                        { item.status }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="birth_plan">
                                        { item.birth_plan }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="notes">
                                        { item.notes }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.pregnancies_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                
                
                
                
                
                
                
                
                <>
                    <p className={'block font-bold mb-2'}>Menopause_symptom_logs User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>LoggedAt</th>
                                
                                
                                
                                <th>HotFlushSeverity(1-10)</th>
                                
                                
                                
                                <th>HotFlushDuration(minutes)</th>
                                
                                
                                
                                <th>NightSweats</th>
                                
                                
                                
                                <th>VaginalDryness</th>
                                
                                
                                
                                <th>BrainFog</th>
                                
                                
                                
                                <th>SleepDisturbance</th>
                                
                                
                                
                                <th>JointPain</th>
                                
                                
                                
                                <th>Palpitations</th>
                                
                                
                                
                                <th>Headaches</th>
                                
                                
                                
                                <th>UrinarySymptoms</th>
                                
                                
                                
                                <th>Notes</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.menopause_symptom_logs_user && Array.isArray(users.menopause_symptom_logs_user) &&
                              users.menopause_symptom_logs_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/menopause_symptom_logs/menopause_symptom_logs-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="logged_at">
                                        { dataFormatter.dateTimeFormatter(item.logged_at) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="hot_flush_severity">
                                        { item.hot_flush_severity }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="hot_flush_duration_minutes">
                                        { item.hot_flush_duration_minutes }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="night_sweats">
                                        { dataFormatter.booleanFormatter(item.night_sweats) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="vaginal_dryness">
                                        { dataFormatter.booleanFormatter(item.vaginal_dryness) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="brain_fog">
                                        { dataFormatter.booleanFormatter(item.brain_fog) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="sleep_disturbance">
                                        { dataFormatter.booleanFormatter(item.sleep_disturbance) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="joint_pain">
                                        { dataFormatter.booleanFormatter(item.joint_pain) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="palpitations">
                                        { dataFormatter.booleanFormatter(item.palpitations) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="headaches">
                                        { dataFormatter.booleanFormatter(item.headaches) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="urinary_symptoms">
                                        { dataFormatter.booleanFormatter(item.urinary_symptoms) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="notes">
                                        { item.notes }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.menopause_symptom_logs_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Male_reproductive_logs User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>LoggedAt</th>
                                
                                
                                
                                <th>PSA</th>
                                
                                
                                
                                <th>IPSSResponsesJSON</th>
                                
                                
                                
                                <th>IPSSScore</th>
                                
                                
                                
                                <th>IIEF-5ResponsesJSON</th>
                                
                                
                                
                                <th>IIEF-5Score</th>
                                
                                
                                
                                <th>Notes</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.male_reproductive_logs_user && Array.isArray(users.male_reproductive_logs_user) &&
                              users.male_reproductive_logs_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/male_reproductive_logs/male_reproductive_logs-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="logged_at">
                                        { dataFormatter.dateTimeFormatter(item.logged_at) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="psa">
                                        { item.psa }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="ipss_responses_json">
                                        { item.ipss_responses_json }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="ipss_score">
                                        { item.ipss_score }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="iief5_responses_json">
                                        { item.iief5_responses_json }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="iief5_score">
                                        { item.iief5_score }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="notes">
                                        { item.notes }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.male_reproductive_logs_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Semen_analyses User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>TestDate</th>
                                
                                
                                
                                <th>Volume(ml)</th>
                                
                                
                                
                                <th>Concentration(million/ml)</th>
                                
                                
                                
                                <th>Motility(%)</th>
                                
                                
                                
                                <th>Morphology(%)</th>
                                
                                
                                
                                <th>Notes</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.semen_analyses_user && Array.isArray(users.semen_analyses_user) &&
                              users.semen_analyses_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/semen_analyses/semen_analyses-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="test_date">
                                        { dataFormatter.dateTimeFormatter(item.test_date) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="volume_ml">
                                        { item.volume_ml }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="concentration_million_per_ml">
                                        { item.concentration_million_per_ml }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="motility_percent">
                                        { item.motility_percent }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="morphology_percent">
                                        { item.morphology_percent }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="notes">
                                        { item.notes }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.semen_analyses_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Sti_tests User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>TestDate</th>
                                
                                
                                
                                <th>TestsPerformed</th>
                                
                                
                                
                                <th>ResultStatus</th>
                                
                                
                                
                                <th>ResultsNotes</th>
                                
                                
                                
                                
                                
                                <th>NextRecommendedTestDate</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.sti_tests_user && Array.isArray(users.sti_tests_user) &&
                              users.sti_tests_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/sti_tests/sti_tests-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="tested_at">
                                        { dataFormatter.dateTimeFormatter(item.tested_at) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="tests_performed">
                                        { item.tests_performed }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="result_status">
                                        { item.result_status }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="results_notes">
                                        { item.results_notes }
                                    </td>
                                    
                                    
                                    
                                    
                                    
                                    <td data-label="next_recommended_test_date">
                                        { dataFormatter.dateTimeFormatter(item.next_recommended_test_date) }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.sti_tests_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Contraception_logs User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>Method</th>
                                
                                
                                
                                <th>StartDate</th>
                                
                                
                                
                                <th>RenewalDueDate</th>
                                
                                
                                
                                <th>DailyReminderEnabled</th>
                                
                                
                                
                                <th>Notes</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.contraception_logs_user && Array.isArray(users.contraception_logs_user) &&
                              users.contraception_logs_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/contraception_logs/contraception_logs-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="method">
                                        { item.method }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="start_date">
                                        { dataFormatter.dateTimeFormatter(item.start_date) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="renewal_due_date">
                                        { dataFormatter.dateTimeFormatter(item.renewal_due_date) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="daily_reminder_enabled">
                                        { dataFormatter.booleanFormatter(item.daily_reminder_enabled) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="notes">
                                        { item.notes }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.contraception_logs_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Libido_logs User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>LoggedAt</th>
                                
                                
                                
                                <th>Libido(1-5)</th>
                                
                                
                                
                                <th>Notes</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.libido_logs_user && Array.isArray(users.libido_logs_user) &&
                              users.libido_logs_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/libido_logs/libido_logs-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="logged_at">
                                        { dataFormatter.dateTimeFormatter(item.logged_at) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="libido_score">
                                        { item.libido_score }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="notes">
                                        { item.notes }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.libido_logs_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Sexual_activity_logs User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>LoggedAt</th>
                                
                                
                                
                                <th>Notes</th>
                                
                                
                                
                                <th>ProtectionUsed</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.sexual_activity_logs_user && Array.isArray(users.sexual_activity_logs_user) &&
                              users.sexual_activity_logs_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/sexual_activity_logs/sexual_activity_logs-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="logged_at">
                                        { dataFormatter.dateTimeFormatter(item.logged_at) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="notes">
                                        { item.notes }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="protection_used">
                                        { item.protection_used }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.sexual_activity_logs_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Skin_care_logs User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>LoggedAt</th>
                                
                                
                                
                                <th>RoutineTime</th>
                                
                                
                                
                                <th>ProductsUsed</th>
                                
                                
                                
                                <th>Oiliness(1-10)</th>
                                
                                
                                
                                <th>Dryness(1-10)</th>
                                
                                
                                
                                <th>Redness(1-10)</th>
                                
                                
                                
                                <th>BreakoutLocations</th>
                                
                                
                                
                                <th>Sensitivity(1-10)</th>
                                
                                
                                
                                
                                
                                <th>Notes</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.skin_care_logs_user && Array.isArray(users.skin_care_logs_user) &&
                              users.skin_care_logs_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/skin_care_logs/skin_care_logs-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="logged_at">
                                        { dataFormatter.dateTimeFormatter(item.logged_at) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="routine_time">
                                        { item.routine_time }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="products_used">
                                        { item.products_used }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="oiliness">
                                        { item.oiliness }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="dryness">
                                        { item.dryness }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="redness">
                                        { item.redness }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="breakout_locations">
                                        { item.breakout_locations }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="sensitivity">
                                        { item.sensitivity }
                                    </td>
                                    
                                    
                                    
                                    
                                    
                                    <td data-label="notes">
                                        { item.notes }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.skin_care_logs_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Sun_exposure_logs User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>StartedAt</th>
                                
                                
                                
                                <th>EndedAt</th>
                                
                                
                                
                                <th>UVIndex</th>
                                
                                
                                
                                <th>TimeOutdoors(minutes)</th>
                                
                                
                                
                                <th>SPFUsed</th>
                                
                                
                                
                                <th>CoverageLevel</th>
                                
                                
                                
                                <th>VitaminDEstimate(IU)</th>
                                
                                
                                
                                <th>SunburnOccurred</th>
                                
                                
                                
                                <th>Notes</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.sun_exposure_logs_user && Array.isArray(users.sun_exposure_logs_user) &&
                              users.sun_exposure_logs_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/sun_exposure_logs/sun_exposure_logs-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="started_at">
                                        { dataFormatter.dateTimeFormatter(item.started_at) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="ended_at">
                                        { dataFormatter.dateTimeFormatter(item.ended_at) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="uv_index">
                                        { item.uv_index }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="time_outdoors_minutes">
                                        { item.time_outdoors_minutes }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="spf_used">
                                        { item.spf_used }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="coverage_level">
                                        { item.coverage_level }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="vitamin_d_estimate_iu">
                                        { item.vitamin_d_estimate_iu }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="sunburn_occurred">
                                        { dataFormatter.booleanFormatter(item.sunburn_occurred) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="notes">
                                        { item.notes }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.sun_exposure_logs_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Mole_lesion_logs User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>LesionName</th>
                                
                                
                                
                                <th>BodyLocation</th>
                                
                                
                                
                                <th>PhotoDate</th>
                                
                                
                                
                                
                                
                                <th>MonitoringInterval</th>
                                
                                
                                
                                <th>NextCheckDue</th>
                                
                                
                                
                                <th>ABCDENotes</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.mole_lesion_logs_user && Array.isArray(users.mole_lesion_logs_user) &&
                              users.mole_lesion_logs_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/mole_lesion_logs/mole_lesion_logs-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="lesion_name">
                                        { item.lesion_name }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="body_location">
                                        { item.body_location }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="photo_date">
                                        { dataFormatter.dateTimeFormatter(item.photo_date) }
                                    </td>
                                    
                                    
                                    
                                    
                                    
                                    <td data-label="monitoring_interval">
                                        { item.monitoring_interval }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="next_check_due">
                                        { dataFormatter.dateTimeFormatter(item.next_check_due) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="abcde_notes">
                                        { item.abcde_notes }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.mole_lesion_logs_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Oral_hygiene_logs User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>LogDate</th>
                                
                                
                                
                                <th>BrushedMorning</th>
                                
                                
                                
                                <th>BrushedNight</th>
                                
                                
                                
                                <th>Flossed</th>
                                
                                
                                
                                <th>Mouthwash</th>
                                
                                
                                
                                <th>TongueScraped</th>
                                
                                
                                
                                <th>Notes</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.oral_hygiene_logs_user && Array.isArray(users.oral_hygiene_logs_user) &&
                              users.oral_hygiene_logs_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/oral_hygiene_logs/oral_hygiene_logs-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="log_date">
                                        { dataFormatter.dateTimeFormatter(item.log_date) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="brushed_morning">
                                        { dataFormatter.booleanFormatter(item.brushed_morning) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="brushed_night">
                                        { dataFormatter.booleanFormatter(item.brushed_night) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="flossed">
                                        { dataFormatter.booleanFormatter(item.flossed) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="mouthwash">
                                        { dataFormatter.booleanFormatter(item.mouthwash) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="tongue_scraped">
                                        { dataFormatter.booleanFormatter(item.tongue_scraped) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="notes">
                                        { item.notes }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.oral_hygiene_logs_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Dental_records User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>ToothChartJSON</th>
                                
                                
                                
                                <th>Notes</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.dental_records_user && Array.isArray(users.dental_records_user) &&
                              users.dental_records_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/dental_records/dental_records-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="tooth_chart_json">
                                        { item.tooth_chart_json }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="notes">
                                        { item.notes }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.dental_records_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Dental_symptoms User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>LoggedAt</th>
                                
                                
                                
                                <th>ToothIdentifier</th>
                                
                                
                                
                                <th>SymptomType</th>
                                
                                
                                
                                <th>Severity(1-10)</th>
                                
                                
                                
                                <th>Notes</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.dental_symptoms_user && Array.isArray(users.dental_symptoms_user) &&
                              users.dental_symptoms_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/dental_symptoms/dental_symptoms-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="logged_at">
                                        { dataFormatter.dateTimeFormatter(item.logged_at) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="tooth_identifier">
                                        { item.tooth_identifier }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="symptom_type">
                                        { item.symptom_type }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="severity">
                                        { item.severity }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="notes">
                                        { item.notes }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.dental_symptoms_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Vision_prescriptions User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>PrescriptionDate</th>
                                
                                
                                
                                <th>RightSphere</th>
                                
                                
                                
                                <th>RightCylinder</th>
                                
                                
                                
                                <th>RightAxis</th>
                                
                                
                                
                                <th>LeftSphere</th>
                                
                                
                                
                                <th>LeftCylinder</th>
                                
                                
                                
                                <th>LeftAxis</th>
                                
                                
                                
                                <th>AddPower</th>
                                
                                
                                
                                <th>PupillaryDistance(mm)</th>
                                
                                
                                
                                
                                
                                <th>Notes</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.vision_prescriptions_user && Array.isArray(users.vision_prescriptions_user) &&
                              users.vision_prescriptions_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/vision_prescriptions/vision_prescriptions-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="prescription_date">
                                        { dataFormatter.dateTimeFormatter(item.prescription_date) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="right_sphere">
                                        { item.right_sphere }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="right_cylinder">
                                        { item.right_cylinder }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="right_axis">
                                        { item.right_axis }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="left_sphere">
                                        { item.left_sphere }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="left_cylinder">
                                        { item.left_cylinder }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="left_axis">
                                        { item.left_axis }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="add_power">
                                        { item.add_power }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="pupillary_distance_mm">
                                        { item.pupillary_distance_mm }
                                    </td>
                                    
                                    
                                    
                                    
                                    
                                    <td data-label="notes">
                                        { item.notes }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.vision_prescriptions_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Eye_symptom_logs User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>LoggedAt</th>
                                
                                
                                
                                <th>SymptomType</th>
                                
                                
                                
                                <th>Severity(1-10)</th>
                                
                                
                                
                                <th>ScreenTime(minutes)</th>
                                
                                
                                
                                <th>Notes</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.eye_symptom_logs_user && Array.isArray(users.eye_symptom_logs_user) &&
                              users.eye_symptom_logs_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/eye_symptom_logs/eye_symptom_logs-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="logged_at">
                                        { dataFormatter.dateTimeFormatter(item.logged_at) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="symptom_type">
                                        { item.symptom_type }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="severity">
                                        { item.severity }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="screen_time_minutes">
                                        { item.screen_time_minutes }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="notes">
                                        { item.notes }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.eye_symptom_logs_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Hearing_test_logs User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>TestDate</th>
                                
                                
                                
                                <th>AudiogramJSON</th>
                                
                                
                                
                                
                                
                                <th>Notes</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.hearing_test_logs_user && Array.isArray(users.hearing_test_logs_user) &&
                              users.hearing_test_logs_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/hearing_test_logs/hearing_test_logs-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="test_date">
                                        { dataFormatter.dateTimeFormatter(item.test_date) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="audiogram_json">
                                        { item.audiogram_json }
                                    </td>
                                    
                                    
                                    
                                    
                                    
                                    <td data-label="notes">
                                        { item.notes }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.hearing_test_logs_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Tinnitus_logs User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>LoggedAt</th>
                                
                                
                                
                                <th>Severity(1-10)</th>
                                
                                
                                
                                <th>PitchDescription</th>
                                
                                
                                
                                <th>Triggers</th>
                                
                                
                                
                                <th>Notes</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.tinnitus_logs_user && Array.isArray(users.tinnitus_logs_user) &&
                              users.tinnitus_logs_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/tinnitus_logs/tinnitus_logs-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="logged_at">
                                        { dataFormatter.dateTimeFormatter(item.logged_at) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="severity">
                                        { item.severity }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="pitch_description">
                                        { item.pitch_description }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="triggers">
                                        { item.triggers }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="notes">
                                        { item.notes }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.tinnitus_logs_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Noise_exposure_logs User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>OccurredAt</th>
                                
                                
                                
                                <th>ExposureSource</th>
                                
                                
                                
                                <th>EstimatedLoudness(1-10)</th>
                                
                                
                                
                                <th>HearingProtectionUsed</th>
                                
                                
                                
                                <th>Duration(minutes)</th>
                                
                                
                                
                                <th>Notes</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.noise_exposure_logs_user && Array.isArray(users.noise_exposure_logs_user) &&
                              users.noise_exposure_logs_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/noise_exposure_logs/noise_exposure_logs-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="occurred_at">
                                        { dataFormatter.dateTimeFormatter(item.occurred_at) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="exposure_source">
                                        { item.exposure_source }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="estimated_loudness">
                                        { item.estimated_loudness }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="hearing_protection_used">
                                        { dataFormatter.booleanFormatter(item.hearing_protection_used) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="duration_minutes">
                                        { item.duration_minutes }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="notes">
                                        { item.notes }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.noise_exposure_logs_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Pain_logs User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>LoggedAt</th>
                                
                                
                                
                                <th>BodyLocation</th>
                                
                                
                                
                                <th>PainType</th>
                                
                                
                                
                                <th>Severity(0-10)</th>
                                
                                
                                
                                <th>DurationType</th>
                                
                                
                                
                                <th>BetterWith</th>
                                
                                
                                
                                <th>WorseWith</th>
                                
                                
                                
                                <th>ImpactonActivities</th>
                                
                                
                                
                                <th>MedicationsTaken</th>
                                
                                
                                
                                <th>JournalNotes</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.pain_logs_user && Array.isArray(users.pain_logs_user) &&
                              users.pain_logs_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/pain_logs/pain_logs-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="logged_at">
                                        { dataFormatter.dateTimeFormatter(item.logged_at) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="body_location">
                                        { item.body_location }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="pain_type">
                                        { item.pain_type }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="severity">
                                        { item.severity }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="duration_type">
                                        { item.duration_type }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="better_with">
                                        { item.better_with }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="worse_with">
                                        { item.worse_with }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="impact_level">
                                        { item.impact_level }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="medications_taken">
                                        { item.medications_taken }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="journal_notes">
                                        { item.journal_notes }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.pain_logs_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Injuries User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>InjuryDate</th>
                                
                                
                                
                                <th>MechanismofInjury</th>
                                
                                
                                
                                <th>Diagnosis</th>
                                
                                
                                
                                <th>AffectedStructure</th>
                                
                                
                                
                                <th>Severity</th>
                                
                                
                                
                                <th>RecoveryStage</th>
                                
                                
                                
                                <th>InitialTreatment</th>
                                
                                
                                
                                <th>Notes</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.injuries_user && Array.isArray(users.injuries_user) &&
                              users.injuries_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/injuries/injuries-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="injury_date">
                                        { dataFormatter.dateTimeFormatter(item.injury_date) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="mechanism">
                                        { item.mechanism }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="diagnosis">
                                        { item.diagnosis }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="affected_structure">
                                        { item.affected_structure }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="severity">
                                        { item.severity }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="recovery_stage">
                                        { item.recovery_stage }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="initial_treatment">
                                        { item.initial_treatment }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="notes">
                                        { item.notes }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.injuries_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                
                <>
                    <p className={'block font-bold mb-2'}>Ergonomics_logs User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>LoggedAt</th>
                                
                                
                                
                                <th>Sitting(minutes)</th>
                                
                                
                                
                                <th>Standing(minutes)</th>
                                
                                
                                
                                <th>Moving(minutes)</th>
                                
                                
                                
                                <th>WorkstationNotes</th>
                                
                                
                                
                                <th>PostureNotes</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.ergonomics_logs_user && Array.isArray(users.ergonomics_logs_user) &&
                              users.ergonomics_logs_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/ergonomics_logs/ergonomics_logs-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="logged_at">
                                        { dataFormatter.dateTimeFormatter(item.logged_at) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="sitting_minutes">
                                        { item.sitting_minutes }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="standing_minutes">
                                        { item.standing_minutes }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="moving_minutes">
                                        { item.moving_minutes }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="workstation_notes">
                                        { item.workstation_notes }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="posture_notes">
                                        { item.posture_notes }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.ergonomics_logs_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Notifications User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>CreatedTime</th>
                                
                                
                                
                                <th>NotificationType</th>
                                
                                
                                
                                <th>Title</th>
                                
                                
                                
                                <th>Message</th>
                                
                                
                                
                                <th>Read</th>
                                
                                
                                
                                <th>ReadAt</th>
                                
                                
                                
                                <th>ActionLink</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.notifications_user && Array.isArray(users.notifications_user) &&
                              users.notifications_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/notifications/notifications-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="created_time">
                                        { dataFormatter.dateTimeFormatter(item.created_time) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="notification_type">
                                        { item.notification_type }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="title">
                                        { item.title }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="message">
                                        { item.message }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="is_read">
                                        { dataFormatter.booleanFormatter(item.is_read) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="read_at">
                                        { dataFormatter.dateTimeFormatter(item.read_at) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="action_link">
                                        { item.action_link }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.notifications_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>Export_jobs User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>ExportType</th>
                                
                                
                                
                                <th>RequestedAt</th>
                                
                                
                                
                                <th>CompletedAt</th>
                                
                                
                                
                                <th>RangeStart</th>
                                
                                
                                
                                <th>RangeEnd</th>
                                
                                
                                
                                <th>IncludedSections</th>
                                
                                
                                
                                <th>ChiefComplaint</th>
                                
                                
                                
                                <th>QuestionsforDoctor</th>
                                
                                
                                
                                <th>Status</th>
                                
                                
                                
                                <th>ErrorMessage</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.export_jobs_user && Array.isArray(users.export_jobs_user) &&
                              users.export_jobs_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/export_jobs/export_jobs-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="export_type">
                                        { item.export_type }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="requested_at">
                                        { dataFormatter.dateTimeFormatter(item.requested_at) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="completed_at">
                                        { dataFormatter.dateTimeFormatter(item.completed_at) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="range_start">
                                        { dataFormatter.dateTimeFormatter(item.range_start) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="range_end">
                                        { dataFormatter.dateTimeFormatter(item.range_end) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="included_sections">
                                        { item.included_sections }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="chief_complaint">
                                        { item.chief_complaint }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="questions_for_doctor">
                                        { item.questions_for_doctor }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="status">
                                        { item.status }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="error_message">
                                        { item.error_message }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.export_jobs_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                
                <>
                    <p className={'block font-bold mb-2'}>App_settings User</p>
                    <CardBox
                      className='mb-6 border border-gray-300 rounded overflow-hidden'
                      hasTable
                    >
                        <div className='overflow-x-auto'>
                            <table>
                            <thead>
                            <tr>
                                
                                
                                
                                
                                <th>Theme</th>
                                
                                
                                
                                <th>FontSize</th>
                                
                                
                                
                                <th>HighContrastMode</th>
                                
                                
                                
                                <th>ReduceMotion</th>
                                
                                
                                
                                <th>ColorBlindFriendlyMode</th>
                                
                                
                                
                                <th>VoiceInputEnabled</th>
                                
                                
                                
                                <th>AutoLock(minutes)</th>
                                
                                
                                
                                <th>BiometricLockEnabled</th>
                                
                                
                                
                                <th>IncognitoModeEnabled</th>
                                
                                
                                
                                <th>AnthropicAPIKeyEncrypted</th>
                                
                                
                            </tr>
                            </thead>
                            <tbody>
                            {users.app_settings_user && Array.isArray(users.app_settings_user) &&
                              users.app_settings_user.map((item: any) => (
                                <tr key={item.id} onClick={() => router.push(`/app_settings/app_settings-view/?id=${item.id}`)}>
                                    
                                    
                                    
                                    
                                    <td data-label="theme_mode">
                                        { item.theme_mode }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="font_size">
                                        { item.font_size }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="high_contrast_mode">
                                        { dataFormatter.booleanFormatter(item.high_contrast_mode) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="reduce_motion">
                                        { dataFormatter.booleanFormatter(item.reduce_motion) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="color_blind_mode">
                                        { dataFormatter.booleanFormatter(item.color_blind_mode) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="voice_input_enabled">
                                        { dataFormatter.booleanFormatter(item.voice_input_enabled) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="auto_lock_minutes">
                                        { item.auto_lock_minutes }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="biometric_lock_enabled">
                                        { dataFormatter.booleanFormatter(item.biometric_lock_enabled) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="incognito_mode_enabled">
                                        { dataFormatter.booleanFormatter(item.incognito_mode_enabled) }
                                    </td>
                                    
                                    
                                    
                                    <td data-label="anthropic_api_key_encrypted">
                                        { item.anthropic_api_key_encrypted }
                                    </td>
                                    
                                    
                                </tr>
                              ))}
                            </tbody>
                        </table>
                        </div>
                        {!users?.app_settings_user?.length && <div className={'text-center py-4'}>No data</div>}
                    </CardBox>
                </>
                
                

                <BaseDivider />

                <BaseButton
                    color='info'
                    label='Back'
                    onClick={() => router.push('/users/users-list')}
                />
              </CardBox>
          </SectionMain>
      </>
    );
};

UsersView.getLayout = function getLayout(page: ReactElement) {
    return (
      <LayoutAuthenticated
        
        permission={'READ_USERS'}
        
      >
          {page}
      </LayoutAuthenticated>
    )
}

export default UsersView;