Example #1
0
 function getOutput()
 {
     $OSCOM_Db = Registry::get('Db');
     $OSCOM_Language = Registry::get('Language');
     $output = '<table class="table table-hover">
                <thead>
                  <tr class="info">
                    <th>' . OSCOM::getDef('module_admin_dashboard_orders_title') . '</th>
                    <th>' . OSCOM::getDef('module_admin_dashboard_orders_total') . '</th>
                    <th>' . OSCOM::getDef('module_admin_dashboard_orders_date') . '</th>
                    <th>' . OSCOM::getDef('module_admin_dashboard_orders_order_status') . '</th>
                  </tr>
                </thead>
                <tbody>';
     $Qorders = $OSCOM_Db->get(['orders o', 'orders_total ot', 'orders_status s'], ['o.orders_id', 'o.customers_name', 'greatest(o.date_purchased, ifnull(o.last_modified, 0)) as date_last_modified', 's.orders_status_name', 'ot.text as order_total'], ['o.orders_id' => ['rel' => 'ot.orders_id'], 'ot.class' => 'ot_total', 'o.orders_status' => ['rel' => 's.orders_status_id'], 's.language_id' => $OSCOM_Language->getId()], 'date_last_modified desc', 6);
     while ($Qorders->fetch()) {
         $output .= '    <tr>
                       <td><a href="' . OSCOM::link(FILENAME_ORDERS, 'oID=' . $Qorders->valueInt('orders_id') . '&action=edit') . '">' . $Qorders->valueProtected('customers_name') . '</a></td>
                       <td>' . strip_tags($Qorders->value('order_total')) . '</td>
                       <td>' . DateTime::toShort($Qorders->value('date_last_modified')) . '</td>
                       <td>' . $Qorders->value('orders_status_name') . '</td>
                     </tr>';
     }
     $output .= '  </tbody>
               </table>';
     return $output;
 }
Example #2
0
 function getOutput()
 {
     $OSCOM_Db = Registry::get('Db');
     $OSCOM_Language = Registry::get('Language');
     $output = '<table class="table table-hover">
                <thead>
                  <tr class="info">
                    <th>' . OSCOM::getDef('module_admin_dashboard_reviews_title') . '</th>
                    <th>' . OSCOM::getDef('module_admin_dashboard_reviews_date') . '</th>
                    <th>' . OSCOM::getDef('module_admin_dashboard_reviews_reviewer') . '</th>
                    <th class="text-right">' . OSCOM::getDef('module_admin_dashboard_reviews_rating') . '</th>
                    <th class="text-right">' . OSCOM::getDef('module_admin_dashboard_reviews_review_status') . '</th>
                  </tr>
                </thead>
                <tbody>';
     $Qreviews = $OSCOM_Db->get(['reviews r', 'products_description pd'], ['r.reviews_id', 'r.date_added', 'pd.products_name', 'r.customers_name', 'r.reviews_rating', 'r.reviews_status'], ['pd.products_id' => ['rel' => 'r.products_id'], 'pd.language_id' => $OSCOM_Language->getId()], 'r.date_added desc', 6);
     while ($Qreviews->fetch()) {
         $output .= '    <tr>
                       <td><a href="' . OSCOM::link(FILENAME_REVIEWS, 'rID=' . $Qreviews->valueInt('reviews_id') . '&action=edit') . '">' . $Qreviews->value('products_name') . '</a></td>
                       <td>' . DateTime::toShort($Qreviews->value('date_added')) . '</td>
                       <td>' . $Qreviews->valueProtected('customers_name') . '</td>
                       <td class="text-right">' . str_repeat('<i class="fa fa-star text-info"></i>', $Qreviews->valueInt('reviews_rating')) . str_repeat('<i class="fa fa-star-o"></i>', 5 - $Qreviews->valueInt('reviews_rating')) . '</td>
                       <td class="text-right"><i class="fa fa-circle ' . ($Qreviews->valueInt('reviews_status') === 1 ? 'text-success' : 'text-danger') . '"></i></td>
                     </tr>';
     }
     $output .= '  </tbody>
               </table>';
     return $output;
 }
Example #3
0
 function getOutput()
 {
     $entries = [];
     $newsCache = new Cache('oscommerce_website-news-latest5');
     if ($newsCache->exists(360)) {
         $entries = $newsCache->get();
     } else {
         $response = HTTP::getResponse(['url' => 'https://www.oscommerce.com/index.php?RPC&GetLatestNews']);
         if (!empty($response)) {
             $response = json_decode($response, true);
             if (is_array($response) && count($response) === 5) {
                 $entries = $response;
             }
         }
         $newsCache->save($entries);
     }
     $output = '<table class="table table-hover">
                <thead>
                  <tr class="info">
                    <th>' . OSCOM::getDef('module_admin_dashboard_latest_news_title') . '</th>
                    <th class="text-right">' . OSCOM::getDef('module_admin_dashboard_latest_news_date') . '</th>
                  </tr>
                </thead>
                <tbody>';
     if (is_array($entries) && count($entries) === 5) {
         foreach ($entries as $item) {
             $output .= '    <tr>
                         <td><a href="' . HTML::outputProtected($item['link']) . '" target="_blank">' . HTML::outputProtected($item['title']) . '</a></td>
                         <td class="text-right" style="white-space: nowrap;">' . HTML::outputProtected(DateTime::toShort($item['date'])) . '</td>
                       </tr>';
         }
     } else {
         $output .= '    <tr>
                       <td colspan="2">' . OSCOM::getDef('module_admin_dashboard_latest_news_feed_error') . '</td>
                     </tr>';
     }
     $output .= '    <tr>
                     <td class="text-right" colspan="2">
                       <a href="https://www.oscommerce.com/Us&News" target="_blank" title="' . HTML::outputProtected(OSCOM::getDef('module_admin_dashboard_latest_news_icon_news')) . '"><span class="fa fa-fw fa-home"></span></a>
                       <a href="https://www.oscommerce.com/newsletter/subscribe" target="_blank" title="' . HTML::outputProtected(OSCOM::getDef('module_admin_dashboard_latest_news_icon_newsletter')) . '"><span class="fa fa-fw fa-newspaper-o"></span></a>
                       <a href="https://plus.google.com/+osCommerce" target="_blank" title="' . HTML::outputProtected(OSCOM::getDef('module_admin_dashboard_latest_news_icon_google_plus')) . '"><span class="fa fa-fw fa-google-plus"></span></a>
                       <a href="https://www.facebook.com/pages/osCommerce/33387373079" target="_blank" title="' . HTML::outputProtected(OSCOM::getDef('module_admin_dashboard_latest_news_icon_facebook')) . '"><span class="fa fa-fw fa-facebook"></span></a>
                       <a href="https://twitter.com/osCommerce" target="_blank" title="' . HTML::outputProtected(OSCOM::getDef('module_admin_dashboard_latest_news_icon_twitter')) . '"><span class="fa fa-fw fa-twitter"></span></a>
                     </td>
                   </tr>
                 </tbody>
               </table>';
     return $output;
 }
 function getOutput()
 {
     $entries = [];
     $addonsCache = new Cache('oscommerce_website-addons-latest5');
     if ($addonsCache->exists(360)) {
         $entries = $addonsCache->get();
     } else {
         $response = HTTP::getResponse(['url' => 'https://www.oscommerce.com/index.php?RPC&GetLatestAddons']);
         if (!empty($response)) {
             $response = json_decode($response, true);
             if (is_array($response) && count($response) === 5) {
                 $entries = $response;
             }
         }
         $addonsCache->save($entries);
     }
     $output = '<table class="table table-hover">
                <thead>
                  <tr class="info">
                    <th>' . OSCOM::getDef('module_admin_dashboard_latest_addons_title') . '</th>
                    <th class="text-right">' . OSCOM::getDef('module_admin_dashboard_latest_addons_date') . '</th>
                  </tr>
                </thead>
                <tbody>';
     if (is_array($entries) && count($entries) === 5) {
         foreach ($entries as $item) {
             $output .= '    <tr>
                         <td><a href="' . HTML::outputProtected($item['link']) . '" target="_blank">' . HTML::outputProtected($item['title']) . '</a></td>
                         <td class="text-right" style="white-space: nowrap;">' . HTML::outputProtected(DateTime::toShort($item['date'])) . '</td>
                       </tr>';
         }
     } else {
         $output .= '    <tr>
                       <td colspan="2">' . OSCOM::getDef('module_admin_dashboard_latest_addons_feed_error') . '</td>
                     </tr>';
     }
     $output .= '    <tr>
                     <td class="text-right" colspan="2"><a href="http://addons.oscommerce.com" target="_blank" title="' . HTML::outputProtected(OSCOM::getDef('module_admin_dashboard_latest_addons_icon_site')) . '"><span class="fa fa-fw fa-home"></span></a></td>
                   </tr>
                 </tbody>
               </table>';
     return $output;
 }
Example #5
0
 function getOutput()
 {
     $OSCOM_Db = Registry::get('Db');
     $output = '<table class="table table-hover">
                <thead>
                  <tr class="info">
                    <th>' . OSCOM::getDef('module_admin_dashboard_customers_title') . '</th>
                    <th class="text-right">' . OSCOM::getDef('module_admin_dashboard_customers_date') . '</th>
                  </tr>
                </thead>
                <tbody>';
     $Qcustomers = $OSCOM_Db->get(['customers c', 'customers_info ci'], ['c.customers_id', 'c.customers_lastname', 'c.customers_firstname', 'ci.customers_info_date_account_created'], ['c.customers_id' => ['rel' => 'ci.customers_info_id']], 'ci.customers_info_date_account_created desc', 6);
     while ($Qcustomers->fetch()) {
         $output .= '    <tr>
                       <td><a href="' . OSCOM::link(FILENAME_CUSTOMERS, 'cID=' . $Qcustomers->valueInt('customers_id') . '&action=edit') . '">' . HTML::outputProtected($Qcustomers->value('customers_firstname') . ' ' . $Qcustomers->value('customers_lastname')) . '</a></td>
                       <td class="text-right">' . DateTime::toShort($Qcustomers->value('customers_info_date_account_created')) . '</td>
                     </tr>';
     }
     $output .= '  </tbody>
               </table>';
     return $output;
 }
Example #6
0
 function getOutput()
 {
     $OSCOM_Db = Registry::get('Db');
     $output = '<table class="table table-hover">
                <thead>
                  <tr class="info">
                    <th>' . OSCOM::getDef('module_admin_dashboard_admin_logins_title') . '</th>
                    <th class="text-right">' . OSCOM::getDef('module_admin_dashboard_admin_logins_date') . '</th>
                  </tr>
                </thead>
                <tbody>';
     $Qlogins = $OSCOM_Db->get('action_recorder', ['id', 'user_name', 'success', 'date_added'], ['module' => 'ar_admin_login'], 'date_added desc', 6);
     while ($Qlogins->fetch()) {
         $output .= '    <tr>
                       <td><i class="fa fa-' . ($Qlogins->valueInt('success') === 1 ? 'check text-success' : 'times text-danger') . '"></i>&nbsp;<a href="' . OSCOM::link(FILENAME_ACTION_RECORDER, 'module=ar_admin_login&aID=' . $Qlogins->valueInt('id')) . '">' . $Qlogins->valueProtected('user_name') . '</a></td>
                       <td class="text-right">' . DateTime::toShort($Qlogins->value('date_added')) . '</td>
                     </tr>';
     }
     $output .= '  </tbody>
               </table>';
     return $output;
 }
 function getOutput()
 {
     $current_version = OSCOM::getVersion();
     $new_version = false;
     $VersionCache = new Cache('core_version_check');
     if ($VersionCache->exists()) {
         $date_last_checked = DateTime::toShort(date('Y-m-d H:i:s', $VersionCache->getTime()), true);
         $releases = $VersionCache->get();
         foreach ($releases as $version) {
             $version_array = explode('|', $version);
             if (version_compare($current_version, $version_array[0], '<')) {
                 $new_version = true;
                 break;
             }
         }
     } else {
         $date_last_checked = OSCOM::getDef('module_admin_dashboard_version_check_never');
     }
     $output = '<table class="table table-hover">
                <thead>
                  <tr class="info">
                    <th>' . OSCOM::getDef('module_admin_dashboard_version_check_title') . '</th>
                    <th class="text-right">' . OSCOM::getDef('module_admin_dashboard_version_check_date') . '</th>
                  </tr>
                </thead>
                <tbody>';
     if ($new_version == true) {
         $output .= '    <tr class="success">
                       <td colspan="2">' . HTML::image(OSCOM::linkImage('icons/warning.gif'), OSCOM::getDef('icon_warning')) . '&nbsp;<strong>' . OSCOM::getDef('module_admin_dashboard_version_check_update_available') . '</strong></td>
                     </tr>';
     }
     $output .= '    <tr>
                     <td><a href="' . OSCOM::link('online_update.php') . '">' . OSCOM::getDef('module_admin_dashboard_version_check_check_now') . '</a></td>
                     <td class="text-right">' . $date_last_checked . '</td>
                   </tr>
                 </tbody>
               </table>';
     return $output;
 }
Example #8
0
    <tr>
      <td><?php 
        echo '<a href="' . OSCOM::link('orders.php', tep_get_all_get_params(array('oID', 'action')) . 'oID=' . $Qorders->valueInt('orders_id') . '&action=edit') . '">' . $Qorders->value('customers_name') . '</a> <small class="text-muted">#' . $Qorders->valueInt('orders_id') . '</small>';
        ?>
</td>
      <td class="text-right"><?php 
        echo strip_tags($Qorders->value('order_total')) . ' <small class="text-muted">' . $Qorders->value('currency') . '</small>';
        ?>
</td>
      <td><div class="oscom-truncate" style="width: 150px;"><small class="text-muted"><?php 
        echo $Qorders->value('payment_method');
        ?>
</small></div></td>
      <td class="text-right"><?php 
        echo DateTime::toShort($Qorders->value('date_purchased'), true);
        ?>
</td>
      <td class="text-right"><?php 
        echo $Qorders->value('orders_status_name');
        ?>
</td>
      <td class="action"><?php 
        echo '<a href="' . OSCOM::link('orders.php', tep_get_all_get_params(array('oID', 'action')) . 'oID=' . $Qorders->valueInt('orders_id') . '&action=edit') . '"><i class="fa fa-pencil" title="' . OSCOM::getDef('image_edit') . '"></i></a>
         <a href="' . OSCOM::link('orders.php', tep_get_all_get_params(array('oID', 'action')) . 'oID=' . $Qorders->valueInt('orders_id') . '&action=delete') . '"><i class="fa fa-trash" title="' . OSCOM::getDef('image_delete') . '"></i></a>
         <a href="' . OSCOM::link('invoice.php', 'oID=' . $Qorders->valueInt('orders_id')) . '" target="_blank"><i class="fa fa-file-text-o" title="' . OSCOM::getDef('image_orders_invoice') . '"></i></a>
         <a href="' . OSCOM::link('packingslip.php', 'oID=' . $Qorders->valueInt('orders_id')) . '" target="_blank"><i class="fa fa-clipboard" title="' . OSCOM::getDef('image_orders_packingslip') . '"></i></a>';
        ?>
</td>
    </tr>
Example #9
0
echo OSCOM::getDef('form_required_input');
?>
    </div>
  </div>

  <?php 
if (ACCOUNT_DOB == 'true') {
    ?>
  <div class="form-group has-feedback">
    <label for="inputName" class="control-label col-sm-3"><?php 
    echo OSCOM::getDef('entry_date_of_birth');
    ?>
</label>
    <div class="col-sm-9">
      <?php 
    echo HTML::inputField('dob', DateTime::toShort($Qaccount->value('customers_dob')), 'data-provide="datepicker" required aria-required="true" id="dob" placeholder="' . OSCOM::getDef('entry_date_of_birth_text') . '"');
    ?>
      <?php 
    echo OSCOM::getDef('form_required_input');
    ?>
    </div>
  </div>
<?php 
}
?>

  <div class="form-group has-feedback">
    <label for="inputEmail" class="control-label col-sm-3"><?php 
echo OSCOM::getDef('entry_email_address');
?>
</label>
?>
<div class="col-sm-<?php 
echo $content_width;
?>
 upcoming-products">

  <table class="table table-striped table-condensed">
    <tbody>
      <tr>
        <th><?php 
echo OSCOM::getDef('module_content_upcoming_products_table_heading_products');
?>
</th>
        <th class="text-right"><?php 
echo OSCOM::getDef('module_content_upcoming_products_table_heading_date_expected');
?>
</th>
      </tr>
      <?php 
foreach ($products as $product) {
    echo '<tr>';
    echo '  <td><a href="' . OSCOM::link('product_info.php', 'products_id=' . (int) $product['products_id']) . '">' . $product['products_name'] . '</a></td>';
    echo '  <td class="text-right">' . DateTime::toShort($product['date_expected']) . '</td>';
    echo '</tr>';
}
?>
    </tbody>
  </table>

</div>
  <div class="clearfix"></div>

  <div class="contentText">
    <ul class="timeline">
      <?php 
$Qstatuses = $OSCOM_Db->prepare('select os.orders_status_name, osh.date_added, osh.comments from :table_orders_status os, :table_orders_status_history osh where osh.orders_id = :orders_id and osh.orders_status_id = os.orders_status_id and os.language_id = :language_id and os.public_flag = "1" order by osh.date_added');
$Qstatuses->bindInt(':orders_id', $_GET['order_id']);
$Qstatuses->bindInt(':language_id', $OSCOM_Language->getId());
$Qstatuses->execute();
while ($Qstatuses->fetch()) {
    echo '<li>';
    echo '  <div class="timeline-badge"><i class="fa fa-check-square-o"></i></div>';
    echo '  <div class="timeline-panel">';
    echo '    <div class="timeline-heading">';
    echo '      <p class="pull-right"><small class="text-muted"><i class="fa fa-clock-o"></i> ' . DateTime::toShort($Qstatuses->value('date_added')) . '</small></p><h2 class="timeline-title">' . $Qstatuses->value('orders_status_name') . '</h2>';
    echo '    </div>';
    echo '    <div class="timeline-body">';
    echo '      <p>' . (tep_not_null($Qstatuses->value('comments')) ? '<blockquote>' . nl2br($Qstatuses->valueProtected('comments')) . '</blockquote>' : '&nbsp;') . '</p>';
    echo '    </div>';
    echo '  </div>';
    echo '</li>';
}
?>
    </ul>
  </div>

<?php 
if (DOWNLOAD_ENABLED == 'true') {
    include 'includes/content/downloads.php';
}
Example #12
0
 * osCommerce Online Merchant
 *
 * @copyright (c) 2016 osCommerce; https://www.oscommerce.com
 * @license MIT; https://www.oscommerce.com/license/mit.txt
 */
use OSC\OM\DateTime;
use OSC\OM\ErrorHandler;
use OSC\OM\FileSystem;
use OSC\OM\HTML;
use OSC\OM\OSCOM;
require 'includes/application_top.php';
$files = [];
foreach (glob(ErrorHandler::getDirectory() . 'errors-*.txt') as $f) {
    $key = basename($f, '.txt');
    if (preg_match('/^errors-([0-9]{4})([0-9]{2})([0-9]{2})$/', $key, $matches)) {
        $files[$key] = ['path' => $f, 'key' => $key, 'date' => DateTime::toShort($matches[1] . '-' . $matches[2] . '-' . $matches[3]), 'size' => filesize($f)];
    }
}
$action = isset($_GET['action']) ? $_GET['action'] : '';
if (tep_not_null($action)) {
    switch ($action) {
        case 'delete':
            if (isset($_GET['log']) && array_key_exists($_GET['log'], $files)) {
                if (unlink($files[$_GET['log']]['path'])) {
                    $OSCOM_MessageStack->add(OSCOM::getDef('ms_success_delete', ['log' => $files[$_GET['log']]['key']]), 'success');
                } else {
                    $OSCOM_MessageStack->add(OSCOM::getDef('ms_error_delete', ['log' => $files[$_GET['log']]['key']]), 'error');
                }
            }
            OSCOM::redirect('error_log.php');
            break;
Example #13
0
        $contents[] = array('text' => '<br /><strong>' . $cInfo->title . '</strong>');
        $contents[] = array('align' => 'center', 'text' => '<br />' . ($remove_currency ? HTML::button(OSCOM::getDef('image_delete'), 'fa fa-trash', OSCOM::link(FILENAME_CURRENCIES, 'page=' . $_GET['page'] . '&cID=' . $cInfo->currencies_id . '&action=deleteconfirm')) : '') . HTML::button(OSCOM::getDef('image_cancel'), 'fa fa-close', OSCOM::link(FILENAME_CURRENCIES, 'page=' . $_GET['page'] . '&cID=' . $cInfo->currencies_id)));
        break;
    default:
        if (is_object($cInfo)) {
            $heading[] = array('text' => '<strong>' . $cInfo->title . '</strong>');
            $contents[] = array('align' => 'center', 'text' => HTML::button(OSCOM::getDef('image_edit'), 'fa fa-edit', OSCOM::link(FILENAME_CURRENCIES, 'page=' . $_GET['page'] . '&cID=' . $cInfo->currencies_id . '&action=edit')) . HTML::button(OSCOM::getDef('image_delete'), 'fa fa-trash', OSCOM::link(FILENAME_CURRENCIES, 'page=' . $_GET['page'] . '&cID=' . $cInfo->currencies_id . '&action=delete')));
            $contents[] = array('text' => '<br />' . OSCOM::getDef('text_info_currency_title') . ' ' . $cInfo->title);
            $contents[] = array('text' => OSCOM::getDef('text_info_currency_code') . ' ' . $cInfo->code);
            $contents[] = array('text' => '<br />' . OSCOM::getDef('text_info_currency_symbol_left') . ' ' . $cInfo->symbol_left);
            $contents[] = array('text' => OSCOM::getDef('text_info_currency_symbol_right') . ' ' . $cInfo->symbol_right);
            $contents[] = array('text' => '<br />' . OSCOM::getDef('text_info_currency_decimal_point') . ' ' . $cInfo->decimal_point);
            $contents[] = array('text' => OSCOM::getDef('text_info_currency_thousands_point') . ' ' . $cInfo->thousands_point);
            $contents[] = array('text' => OSCOM::getDef('text_info_currency_decimal_places') . ' ' . $cInfo->decimal_places);
            if (isset($cInfo->last_updated)) {
                $contents[] = array('text' => '<br />' . OSCOM::getDef('text_info_currency_last_updated') . ' ' . DateTime::toShort($cInfo->last_updated));
            }
            $contents[] = array('text' => OSCOM::getDef('text_info_currency_value') . ' ' . number_format($cInfo->value, 8));
            $contents[] = array('text' => '<br />' . OSCOM::getDef('text_info_currency_example') . '<br />' . $currencies->format('30', false, DEFAULT_CURRENCY) . ' = ' . $currencies->format('30', true, $cInfo->code));
        }
        break;
}
if (tep_not_null($heading) && tep_not_null($contents)) {
    echo '            <td width="25%" valign="top">' . "\n";
    $box = new box();
    echo $box->infoBox($heading, $contents);
    echo '            </td>' . "\n";
}
?>
          </tr>
        </table></td>
Example #14
0
            $contents = array('form' => HTML::form('newsletters', OSCOM::link(FILENAME_NEWSLETTERS, 'page=' . $_GET['page'] . '&nID=' . $nInfo->newsletters_id . '&action=deleteconfirm')));
            $contents[] = array('text' => OSCOM::getDef('text_info_delete_intro'));
            $contents[] = array('text' => '<br /><strong>' . $nInfo->title . '</strong>');
            $contents[] = array('align' => 'center', 'text' => '<br />' . HTML::button(OSCOM::getDef('image_delete'), 'fa fa-trash') . HTML::button(OSCOM::getDef('image_cancel'), 'fa fa-close', OSCOM::link(FILENAME_NEWSLETTERS, 'page=' . $_GET['page'] . '&nID=' . $_GET['nID'])));
            break;
        default:
            if (isset($nInfo) && is_object($nInfo)) {
                $heading[] = array('text' => '<strong>' . $nInfo->title . '</strong>');
                if ($nInfo->locked > 0) {
                    $contents[] = array('align' => 'center', 'text' => HTML::button(OSCOM::getDef('image_edit'), 'fa fa-edit', OSCOM::link(FILENAME_NEWSLETTERS, 'page=' . $_GET['page'] . '&nID=' . $nInfo->newsletters_id . '&action=new')) . HTML::button(OSCOM::getDef('image_delete'), 'fa fa-trash', OSCOM::link(FILENAME_NEWSLETTERS, 'page=' . $_GET['page'] . '&nID=' . $nInfo->newsletters_id . '&action=delete')) . HTML::button(OSCOM::getDef('image_preview'), 'fa fa-file-o', OSCOM::link(FILENAME_NEWSLETTERS, 'page=' . $_GET['page'] . '&nID=' . $nInfo->newsletters_id . '&action=preview')) . HTML::button(OSCOM::getDef('image_send'), 'fa fa-envelope', OSCOM::link(FILENAME_NEWSLETTERS, 'page=' . $_GET['page'] . '&nID=' . $nInfo->newsletters_id . '&action=send')) . HTML::button(OSCOM::getDef('image_unlock'), 'fa fa-unlock', OSCOM::link(FILENAME_NEWSLETTERS, 'page=' . $_GET['page'] . '&nID=' . $nInfo->newsletters_id . '&action=unlock')));
                } else {
                    $contents[] = array('align' => 'center', 'text' => HTML::button(OSCOM::getDef('image_preview'), 'fa fa-file-o', OSCOM::link(FILENAME_NEWSLETTERS, 'page=' . $_GET['page'] . '&nID=' . $nInfo->newsletters_id . '&action=preview')) . HTML::button(OSCOM::getDef('image_lock'), 'fa fa-lock', OSCOM::link(FILENAME_NEWSLETTERS, 'page=' . $_GET['page'] . '&nID=' . $nInfo->newsletters_id . '&action=lock')));
                }
                $contents[] = array('text' => '<br />' . OSCOM::getDef('text_newsletter_date_added') . ' ' . DateTime::toShort($nInfo->date_added));
                if ($nInfo->status == '1') {
                    $contents[] = array('text' => OSCOM::getDef('text_newsletter_date_sent') . ' ' . DateTime::toShort($nInfo->date_sent));
                }
            }
            break;
    }
    if (tep_not_null($heading) && tep_not_null($contents)) {
        echo '            <td width="25%" valign="top">' . "\n";
        $box = new box();
        echo $box->infoBox($heading, $contents);
        echo '            </td>' . "\n";
    }
    ?>
          </tr>
        </table></td>
      </tr>
<?php 
Example #15
0
    echo $Qactions->valueInt('success') === 1 ? 'fa-check text-success' : 'fa-times text-danger';
    ?>
"></i> <?php 
    echo $module_title;
    ?>
</td>
      <td><?php 
    echo $Qactions->valueProtected('user_name') . ' [' . $Qactions->valueInt('user_id') . ']';
    ?>
</td>
      <td><?php 
    echo tep_not_null($Qactions->value('identifier')) ? '<a href="' . OSCOM::link('action_recorder.php', 'search=' . $Qactions->value('identifier')) . '"><u>' . $Qactions->valueProtected('identifier') . '</u></a>' : '(empty)';
    ?>
</td>
      <td class="text-right"><?php 
    echo DateTime::toShort($Qactions->value('date_added'), true);
    ?>
</td>
    </tr>

<?php 
}
?>

  </tbody>
</table>

<div>
  <span class="pull-right"><?php 
echo $Qactions->getPageSetLinks((isset($_GET['module']) && in_array($_GET['module'], $modules_array) && is_object($GLOBALS[$_GET['module']]) ? 'module=' . $_GET['module'] : null) . '&' . (isset($_GET['search']) && !empty($_GET['search']) ? 'search=' . $_GET['search'] : null));
?>
Example #16
0
            if (is_object($sInfo)) {
                $heading[] = array('text' => '<strong>' . $sInfo->products_name . '</strong>');
                $contents[] = array('align' => 'center', 'text' => HTML::button(OSCOM::getDef('image_edit'), 'fa fa-edit', OSCOM::link(FILENAME_SPECIALS, 'page=' . $_GET['page'] . '&sID=' . $sInfo->specials_id . '&action=edit')) . HTML::button(OSCOM::getDef('image_delete'), 'fa fa-trash', OSCOM::link(FILENAME_SPECIALS, 'page=' . $_GET['page'] . '&sID=' . $sInfo->specials_id . '&action=delete')));
                $contents[] = array('text' => '<br />' . OSCOM::getDef('text_info_date_added') . ' ' . DateTime::toShort($sInfo->specials_date_added));
                if (isset($sInfo->specials_last_modified)) {
                    $contents[] = array('text' => '' . OSCOM::getDef('text_info_last_modified') . ' ' . DateTime::toShort($sInfo->specials_last_modified));
                }
                $contents[] = array('align' => 'center', 'text' => '<br />' . tep_info_image($sInfo->products_image, $sInfo->products_name, SMALL_IMAGE_WIDTH, SMALL_IMAGE_HEIGHT));
                $contents[] = array('text' => '<br />' . OSCOM::getDef('text_info_original_price') . ' ' . $currencies->format($sInfo->products_price));
                $contents[] = array('text' => '' . OSCOM::getDef('text_info_new_price') . ' ' . $currencies->format($sInfo->specials_new_products_price));
                $contents[] = array('text' => '' . OSCOM::getDef('text_info_percentage') . ' ' . number_format(100 - $sInfo->specials_new_products_price / $sInfo->products_price * 100) . '%');
                if (isset($sInfo->expires_date)) {
                    $contents[] = array('text' => '<br />' . OSCOM::getDef('text_info_expires_date') . ' <strong>' . DateTime::toShort($sInfo->expires_date) . '</strong>');
                }
                if (isset($sInfo->date_status_change)) {
                    $contents[] = array('text' => '' . OSCOM::getDef('text_info_status_change') . ' ' . DateTime::toShort($sInfo->date_status_change));
                }
            }
            break;
    }
    if (tep_not_null($heading) && tep_not_null($contents)) {
        echo '            <td width="25%" valign="top">' . "\n";
        $box = new box();
        echo $box->infoBox($heading, $contents);
        echo '            </td>' . "\n";
    }
}
?>
          </tr>
        </table></td>
      </tr>
Example #17
0
         $contents[] = array('text' => OSCOM::getDef('text_delete_intro') . '<br /><br /><strong>' . $cInfo->customers_firstname . ' ' . $cInfo->customers_lastname . '</strong>');
         if (isset($cInfo->number_of_reviews) && $cInfo->number_of_reviews > 0) {
             $contents[] = array('text' => '<br />' . HTML::checkboxField('delete_reviews', 'on', true) . ' ' . OSCOM::getDef('text_delete_reviews', ['number_of_reviews' => $cInfo->number_of_reviews]));
         }
         $contents[] = array('align' => 'center', 'text' => '<br />' . HTML::button(OSCOM::getDef('image_delete'), 'fa fa-trash') . HTML::button(OSCOM::getDef('image_cancel'), 'fa fa-close', OSCOM::link(FILENAME_CUSTOMERS, tep_get_all_get_params(array('cID', 'action')) . 'cID=' . $cInfo->customers_id)));
         break;
     default:
         if (isset($cInfo) && is_object($cInfo)) {
             $heading[] = array('text' => '<strong>' . $cInfo->customers_firstname . ' ' . $cInfo->customers_lastname . '</strong>');
             $contents[] = array('align' => 'center', 'text' => HTML::button(OSCOM::getDef('image_edit'), 'fa fa-edit', OSCOM::link(FILENAME_CUSTOMERS, tep_get_all_get_params(array('cID', 'action')) . 'cID=' . $cInfo->customers_id . '&action=edit')) . HTML::button(OSCOM::getDef('image_delete'), 'fa fa-trash', OSCOM::link(FILENAME_CUSTOMERS, tep_get_all_get_params(array('cID', 'action')) . 'cID=' . $cInfo->customers_id . '&action=confirm')) . HTML::button(OSCOM::getDef('image_orders'), 'fa fa-shopping-cart', OSCOM::link(FILENAME_ORDERS, 'cID=' . $cInfo->customers_id)) . HTML::button(OSCOM::getDef('image_email'), 'fa fa-envelope', OSCOM::link(FILENAME_MAIL, 'customer=' . $cInfo->customers_email_address)));
             $contents[] = array('text' => '<br />' . OSCOM::getDef('text_date_account_created') . ' ' . DateTime::toShort($cInfo->date_account_created));
             if (isset($cInfo->date_account_last_modified)) {
                 $contents[] = array('text' => '<br />' . OSCOM::getDef('text_date_account_last_modified') . ' ' . DateTime::toShort($cInfo->date_account_last_modified));
             }
             if (isset($cInfo->date_last_logon)) {
                 $contents[] = array('text' => '<br />' . OSCOM::getDef('text_info_date_last_logon') . ' ' . DateTime::toShort($cInfo->date_last_logon));
             }
             $contents[] = array('text' => '<br />' . OSCOM::getDef('text_info_number_of_logons') . ' ' . $cInfo->number_of_logons);
             $contents[] = array('text' => '<br />' . OSCOM::getDef('text_info_country') . ' ' . $cInfo->countries_name);
             $contents[] = array('text' => '<br />' . OSCOM::getDef('text_info_number_of_reviews') . ' ' . $cInfo->number_of_reviews);
         }
         break;
 }
 if (tep_not_null($heading) && tep_not_null($contents)) {
     echo '            <td width="25%" valign="top">' . "\n";
     $box = new box();
     echo $box->infoBox($heading, $contents);
     echo '            </td>' . "\n";
 }
 ?>
       </tr>
Example #18
0
        $contents[] = array('text' => '<br />' . OSCOM::getDef('text_info_tax_rate_priority') . '<br />' . HTML::inputField('tax_priority', $trInfo->tax_priority));
        $contents[] = array('align' => 'center', 'text' => '<br />' . HTML::button(OSCOM::getDef('image_save'), 'fa fa-save') . HTML::button(OSCOM::getDef('image_cancel'), 'fa fa-close', OSCOM::link(FILENAME_TAX_RATES, 'page=' . $_GET['page'] . '&tID=' . $trInfo->tax_rates_id)));
        break;
    case 'delete':
        $heading[] = array('text' => '<strong>' . OSCOM::getDef('text_info_heading_delete_tax_rate') . '</strong>');
        $contents = array('form' => HTML::form('rates', OSCOM::link(FILENAME_TAX_RATES, 'page=' . $_GET['page'] . '&tID=' . $trInfo->tax_rates_id . '&action=deleteconfirm')));
        $contents[] = array('text' => OSCOM::getDef('text_info_delete_intro'));
        $contents[] = array('text' => '<br /><strong>' . $trInfo->tax_class_title . ' ' . number_format($trInfo->tax_rate, TAX_DECIMAL_PLACES) . '%</strong>');
        $contents[] = array('align' => 'center', 'text' => '<br />' . HTML::button(OSCOM::getDef('image_delete'), 'fa fa-trash') . HTML::button(OSCOM::getDef('image_cancel'), 'fa fa-close', OSCOM::link(FILENAME_TAX_RATES, 'page=' . $_GET['page'] . '&tID=' . $trInfo->tax_rates_id)));
        break;
    default:
        if (is_object($trInfo)) {
            $heading[] = array('text' => '<strong>' . $trInfo->tax_class_title . '</strong>');
            $contents[] = array('align' => 'center', 'text' => HTML::button(OSCOM::getDef('image_edit'), 'fa fa-edit', OSCOM::link(FILENAME_TAX_RATES, 'page=' . $_GET['page'] . '&tID=' . $trInfo->tax_rates_id . '&action=edit')) . HTML::button(OSCOM::getDef('image_delete'), 'fa fa-trash', OSCOM::link(FILENAME_TAX_RATES, 'page=' . $_GET['page'] . '&tID=' . $trInfo->tax_rates_id . '&action=delete')));
            $contents[] = array('text' => '<br />' . OSCOM::getDef('text_info_date_added') . ' ' . DateTime::toShort($trInfo->date_added));
            $contents[] = array('text' => '' . OSCOM::getDef('text_info_last_modified') . ' ' . DateTime::toShort($trInfo->last_modified));
            $contents[] = array('text' => '<br />' . OSCOM::getDef('text_info_rate_description') . '<br />' . $trInfo->tax_description);
        }
        break;
}
if (tep_not_null($heading) && tep_not_null($contents)) {
    echo '            <td width="25%" valign="top">' . "\n";
    $box = new box();
    echo $box->infoBox($heading, $contents);
    echo '            </td>' . "\n";
}
?>
          </tr>
        </table></td>
      </tr>
    </table>
</td>
                    <td class="smallText" align="right"><?php 
echo $Qproducts->getPageSetLinks();
?>
</td>
                  </tr>
                </table></td>
              </tr>
            </table></td>
<?php 
$heading = array();
$contents = array();
if (isset($pInfo) && is_object($pInfo)) {
    $heading[] = array('text' => '<strong>' . $pInfo->products_name . '</strong>');
    $contents[] = array('align' => 'center', 'text' => HTML::button(OSCOM::getDef('image_edit'), 'fa fa-edit', OSCOM::link(FILENAME_CATEGORIES, 'pID=' . $pInfo->products_id . '&action=new_product')));
    $contents[] = array('text' => '<br />' . OSCOM::getDef('text_info_date_expected') . ' ' . DateTime::toShort($pInfo->products_date_available));
}
if (tep_not_null($heading) && tep_not_null($contents)) {
    echo '            <td width="25%" valign="top">' . "\n";
    $box = new box();
    echo $box->infoBox($heading, $contents);
    echo '            </td>' . "\n";
}
?>
          </tr>
        </table></td>
      </tr>
    </table>

<?php 
require $oscTemplate->getFile('template_bottom.php');