<commit_before>@extends('layouts.backend-layout')

@section('title')
    Admin Panel
@endsection

@section('content')

<section class="section container">
    <div class="columns is-multiline is-mobile">
        <div class="column is-half statistics">
            <h1 class="title">
                Real-Time Server
            </h1>

            @if($echo_server_status === false)
                <article class="message is-danger">
                    <div class="message-body">
                        <p>
                            <strong>Echo Server</strong> isn't responding!
                        </p>
                    </div>
                </article>
            @elseif($echo_server_status != null)
                <div class="statistic red-back">
                    <div>
                        Online Connections:
                    </div>

                    <div class="panel-number-big">
                        {{ $echo_server_status->subscription_count }}
                    </div>
                </div>
                <div class="statistic green-back">
                    <div>
                        Memory Usage:
                    </div>

                    <div class="panel-number-big">
                        <span>{{ rssForHumans($echo_server_status->memory_usage->rss) }}</span>
                    </div>
                </div>
                <div class="statistic blue-back">
                    <div>
                        Uptime:
                    </div>

                    <div class="panel-number-big">
                        <span>{{ round($echo_server_status->uptime/60/60/24, 2) }}</span>
                        <span class="des">Days</span>
                    </div>
                </div>
            @else
                <i>
                    This section only works for applications using <a href="https://github.com/tlaverdure/laravel-echo-server">echo server</a>.
                </i>
            @endif
        </div>

        <div class="column is-half">
        	<h1 class="title">
        		Statistics
        	</h1>

			<table class="table is-striped">
                <thead>
                    <tr>
                        <th></th>
                        <th>Today</th>
                        <th>Total</th>
                    </tr>
                </thead>

                <tbody>
                    <tr>
                        <td>
                            Registers
                        </td>
                        <td>
                            {{ $usersToday }}
                        </td>
                        <td>
                            {{ $usersTotal }}
                        </td>
                    </tr>

                    <tr>
                        <td>
                            Active Users
                        </td>
                        <td>
                            {{ $activeUsersToday }}
                        </td>
                        <td>
                            {{ $activeUsersTotal }}
                        </td>
                    </tr>

                    <tr>
                        <td>
                            Submissions
                        </td>
                        <td>
                            {{ $submissionsToday }}
                        </td>
                        <td>
                            {{ $submissionsTotal }}
                        </td>
                    </tr>

                    <tr>
                        <td>
                            Comments
                        </td>
                        <td>
                            {{ $commentsToday }}
                        </td>
                        <td>
                            {{ $commentsTotal }}
                        </td>
                    </tr>

                    <tr>
                        <td>
                            Channels
                        </td>
                        <td>
                            {{ $categoriesToday }}
                        </td>
                        <td>
                            {{ $categoriesTotal }}
                        </td>
                    </tr>

                    <tr>
                        <td>
                            Subscribes
                        </td>
                        <td>
                            {{ $subscriptionsToday }}
                        </td>
                        <td>
                            {{ $subscriptionsTotal }}
                        </td>
                    </tr>

                    <tr>
                        <td><commit_msg>better name for column<commit_after>@extends('layouts.backend-layout')

@section('title')
    Admin Panel
@endsection

@section('content')

<section class="section container">
    <div class="columns is-multiline is-mobile">
        <div class="column is-half statistics">
            <h1 class="title">
                Real-Time Server
            </h1>

            @if($echo_server_status === false)
                <article class="message is-danger">
                    <div class="message-body">
                        <p>
                            <strong>Echo Server</strong> isn't responding!
                        </p>
                    </div>
                </article>
            @elseif($echo_server_status != null)
                <div class="statistic red-back">
                    <div>
                        Online Connections:
                    </div>

                    <div class="panel-number-big">
                        {{ $echo_server_status->subscription_count }}
                    </div>
                </div>
                <div class="statistic green-back">
                    <div>
                        Memory Usage:
                    </div>

                    <div class="panel-number-big">
                        <span>{{ rssForHumans($echo_server_status->memory_usage->rss) }}</span>
                    </div>
                </div>
                <div class="statistic blue-back">
                    <div>
                        Uptime:
                    </div>

                    <div class="panel-number-big">
                        <span>{{ round($echo_server_status->uptime/60/60/24, 2) }}</span>
                        <span class="des">Days</span>
                    </div>
                </div>
            @else
                <i>
                    This section only works for applications using <a href="https://github.com/tlaverdure/laravel-echo-server">echo server</a>.
                </i>
            @endif
        </div>

        <div class="column is-half">
        	<h1 class="title">
        		Statistics
        	</h1>

			<table class="table is-striped">
                <thead>
                    <tr>
                        <th></th>
                        <th>Today</th>
                        <th>Total</th>
                    </tr>
                </thead>

                <tbody>
                    <tr>
                        <td>
                            Registers
                        </td>
                        <td>
                            {{ $usersToday }}
                        </td>
                        <td>
                            {{ $usersTotal }}
                        </td>
                    </tr>

                    <tr>
                        <td>
                            Active Users
                        </td>
                        <td>
                            {{ $activeUsersToday }}
                        </td>
                        <td>
                            {{ $activeUsersTotal }}
                        </td>
                    </tr>

                    <tr>
                        <td>
                            Submissions
                        </td>
                        <td>
                            {{ $submissionsToday }}
                        </td>
                        <td>
                            {{ $submissionsTotal }}
                        </td>
                    </tr>

                    <tr>
                        <td>
                            Comments
                        </td>
                        <td>
                            {{ $commentsToday }}
                        </td>
                        <td>
                            {{ $commentsTotal }}
                        </td>
                    </tr>

                    <tr>
                        <td>
                            Channels
                        </td>
                        <td>
                            {{ $categoriesToday }}
                        </td>
                        <td>
                            {{ $categoriesTotal }}
                        </td>
                    </tr>

                    <tr>
                        <td>
                            Subscriptions
                        </td>
                        <td>
                            {{ $subscriptionsToday }}
                        </td>
                        <td>
                            {{ $subscriptionsTotal }}
                        </td>
                    </tr>

                    <tr>
                        <td>
{'fraction_non_alphanumeric': 0.1016548463356974, 'fraction_numerical': 0.002364066193853428, 'mean_word_length': 0.5621013763007721, 'pattern_counts': {'":': 0, '<': 217, '<?xml version=': 0, '>': 225, 'https://': 2, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4544433', 'n_tokens_mistral': 2161, 'n_tokens_neox': 1901, 'n_words': 368}