<commit_before><?php 

include_once( "header.php" );
include_once( "methods.php" );
include_once( "tohtml.php" );
include_once( 'database.php' );

echo userHTML( );

?>

<script type="text/javascript">
function toggleMe(source) {
    var checkboxes = document.getElementsByName( 'events[]' );
    for( var index = 0; index < checkboxes.length; ++index )
        checkboxes[index].checked = source.checked;
}
</script>


<?php
if( $_POST['response'] == "Review" )
{
    echo '<div>';
    // Approve after constructing all the events from the patterns.
    $requests = getRequestByGroupIdAndStatus( $_POST['gid'], 'PENDING' );
    $gid = $requests[0]['gid'];
    $total = count( $requests );

    echo "<h3> Following events are generated by this request </h3>";

    // First insert this request into event calendar.
    echo '<form method="post" action="bookmyvenue_admin_request_review_submit.php">';
    echo '<table class="show_events">';
    $childrenId = 0;
    foreach( $requests as $r )
    {
        $rid = $r['rid'];
        // use this id to get back the gid and rid in next form. 
        $id = $gid . '.' . $rid;
        echo "<tr>";
        echo "<td><input type=\"checkbox\" name=\"events[]\" value=\"$id\"></td>";
        $tobefiltered = Array( 'modified_by', 'rid', 'timestamp', 'external_id' );
        echo "<td>" . arrayToTableHTML( $r, 'request', '', $tobefiltered ) . "</td>";
    }
    echo '</td>';
    echo "</tr> </table>";

    echo "<input name=\"request[]\" type=\"checkbox\" <commit_msg>Still some issue with bmv.<commit_after><?php 

include_once( "header.php" );
include_once( "methods.php" );
include_once( "tohtml.php" );
include_once( 'database.php' );

echo userHTML( );

?>

<script type="text/javascript">
function toggleMe(source) {
    var checkboxes = document.getElementsByName( 'events[]' );
    for( var index = 0; index < checkboxes.length; ++index )
        checkboxes[index].checked = source.checked;
}
</script>


<?php
if( ! array_key_exists( 'response', $_POST ) )
{
    echo printInfo( "Nothing to do here anymore" );
    goToPage( './bookmyvenue_admin.php', 0 );
    exit;
}

if( $_POST['response'] == "Review" )
{
    echo '<div>';
    // Approve after constructing all the events from the patterns.
    $requests = getRequestByGroupIdAndStatus( $_POST['gid'], 'PENDING' );
    $gid = $requests[0]['gid'];
    $total = count( $requests );

    echo "<h3> Following events are generated by this request </h3>";

    // First insert this request into event calendar.
    echo '<form method="post" action="bookmyvenue_admin_request_review_submit.php">';
    echo '<table class="show_events">';
    $childrenId = 0;
    foreach( $requests as $r )
    {
        $rid = $r['rid'];
        // use this id to get back the gid and rid in next form. 
        $id = $gid . '.' . $rid;
        echo "<tr>";
        echo "<td><input type=\"checkbox\" name=\"events[]\" value=\"$id\"></td>";
        $tobefiltered = Array( 'modified_by', 'rid', 'timestamp', 'external_id' );
        echo "<td>" . arrayToTableHTML( $r, 'request', '', $tobefiltered ) . "</td>";
    }
    echo '</td>';
    echo "</tr> </table>";

    echo "<input name=\"request[]\" type=\"checkbox\" 
{'fraction_non_alphanumeric': 0.1856474258970359, 'fraction_numerical': 0.0034321372854914196, 'mean_word_length': 3.218421052631579, 'pattern_counts': {'":': 0, '<': 43, '<?xml version=': 0, '>': 37, 'https://': 0, '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': '6120755', 'n_tokens_mistral': 1036, 'n_tokens_neox': 1013, 'n_words': 279}