Example #1
0
function get_dropdown_list_array($type)
{
    global $lC_Language;
    $list_arr = array();
    switch ($type) {
        case 'manufacturer':
            $list_str = $lC_Language->get('text_select_manufacturers');
            $list_arr = lC_Manufacturers_Admin::getManufacturersArray();
            break;
        case 'supplier':
            $list_str = $lC_Language->get('text_select_supplier');
            // $list_arr = lC_Orders_Admin::getOrderStatusArray();
            break;
        case 'order_status':
            // $list_str = $lC_Language->get('text_statuses');
            $list_arr = lC_Orders_Admin::getOrderStatusArray();
            break;
    }
    $i = 0;
    if ($list_str != '') {
        $i = 1;
        $return_arr[0] = array('id' => '', 'text' => $list_str);
    }
    if (is_array($list_arr) && count($list_arr) > 0) {
        foreach ($list_arr as $k => $arr) {
            $return_arr[$k + $i] = $arr;
        }
    }
    return $return_arr;
}
Example #2
0
 public function __construct()
 {
     global $lC_Language, $lC_MessageStack;
     parent::__construct();
     $this->_page_contents = 'edit.php';
     if (isset($_POST['subaction']) && $_POST['subaction'] == 'confirm') {
         switch ($_GET['action']) {
             case 'save':
                 $data = array('oid' => $_POST['oid'], 'status' => $_POST['status'], 'comment' => $_POST['comment'], 'notify_customer' => isset($_POST['notify_customer']) && $_POST['notify_customer'] == 1 ? true : false, 'append_comment' => isset($_POST['append_comment']) && $_POST['append_comment'] == 1 ? true : false);
                 /*
                  * Update the order status
                  *
                  * @param integer $data['oid'] The orders id used on status update
                  * @param array $data The order status information
                  * @access public
                  * @return boolean
                  */
                 if (lC_Orders_Admin::updateStatus($data['oid'], $data)) {
                     lc_redirect_admin(lc_href_link_admin(FILENAME_DEFAULT, $this->_module . '=' . $data['oid'] . '&action=save'));
                 } else {
                     $_SESSION['error'] = true;
                     $_SESSION['errmsg'] = $lC_Language->get('ms_error_action_not_performed');
                 }
                 break;
         }
     }
 }
Example #3
0
 public function __construct()
 {
     global $lC_Database, $lC_Language, $lC_Template, $lC_Currencies;
     $lC_Currencies = new lC_Currencies();
     $this->_page_title = $lC_Language->get('heading_title');
     if (!isset($_GET['action'])) {
         $_GET['action'] = '';
     }
     if (isset($_GET['cID']) && $_GET['cID'] != null) {
         $_SESSION['cIDFilter'] = $_GET['cID'];
     } else {
         if (isset($_SESSION['cIDFilter'])) {
             unset($_SESSION['cIDFilter']);
         }
     }
     if (isset($_GET['action']) && $_GET['action'] == "quick_add") {
         if ($order_insert_id = lC_Orders_Admin::createOrder($_GET['cID'])) {
             lc_redirect_admin(lc_href_link_admin(FILENAME_DEFAULT, $this->_module . '=' . $order_insert_id . '&action=save&tabProducts=1'));
         }
     } else {
         if (isset($_GET['action']) && $_GET['action'] == "add_product") {
             lC_Orders_Admin::addOrderProductData();
             lc_redirect_admin(lc_href_link_admin(FILENAME_DEFAULT, $this->_module . '=' . $_GET['oID'] . '&action=save&tabProducts=1'));
         }
     }
     // for temporary use
     if (isset($_POST['action_order_total']) && $_POST['action_order_total'] == 'save_order_total') {
         lC_Orders_Admin::saveOrderTotal();
         lc_redirect_admin(lc_href_link_admin(FILENAME_DEFAULT, $this->_module . '=' . $_POST['oid'] . '&action=save&tabTotals=1'));
     }
     if (!empty($_GET['action'])) {
         switch ($_GET['action']) {
             case 'invoice':
                 $this->_page_contents = 'invoice.php';
                 $this->_has_header = false;
                 $this->_has_footer = false;
                 $this->_has_wrapper = false;
                 break;
             case 'packaging_slip':
                 $this->_page_contents = 'packaging_slip.php';
                 $this->_has_header = false;
                 $this->_has_footer = false;
                 $this->_has_wrapper = false;
                 break;
         }
     }
 }
Example #4
0
<div id="section_orders_transactions" style="display:none;">
  <h3 class="show-below-768 margin-left margin-top no-margin-bottom"><?php 
echo $lC_Language->get('text_transactions');
?>
</h3>
  <div class="with-padding">
    <table border="0" width="100%" cellspacing="0" cellpadding="0" class="table responsive-table">
      <thead>
        <tr>
          <td><?php 
echo $lC_Language->get('table_heading_date_added');
?>
</td>
          <td><?php 
echo $lC_Language->get('table_heading_status');
?>
</td>
          <td width="10%"><?php 
echo $lC_Language->get('table_heading_comments');
?>
</td>
        </tr>
      </thead>
      <tbody>
                  <?php 
echo lC_Orders_Admin::getOrderTransactions($oInfo->get('oID'));
?>
      </tbody>
    </table>
  </div>
</div>
Example #5
0
<?php

/**
  @package    catalog::admin::applications
  @author     Loaded Commerce
  @copyright  Copyright 2003-2014 Loaded Commerce, LLC
  @copyright  Portions Copyright 2003 osCommerce
  @copyright  Template built on Developr theme by DisplayInline http://themeforest.net/user/displayinline under Extended license 
  @license    https://github.com/loadedcommerce/loaded7/blob/master/LICENSE.txt
  @version    $Id: status.php v1.0 2013-08-08 datazen $
*/
?>
<div id="section_orders_status" style="display:none;">
  <h3 class="show-below-768 margin-left margin-top no-margin-bottom"><?php 
echo $lC_Language->get('section_status_history');
?>
</h3>
  <div class="with-padding">
  <div class="btop-anthracite"><?php 
echo lC_Orders_Admin::getOrderStatusHistory($oInfo->get('oID'));
?>
</div>
  </div>
</div>
Example #6
0
<?php

/**
  @package    catalog::admin::applications
  @author     Loaded Commerce
  @copyright  Copyright 2003-2014 Loaded Commerce, LLC
  @copyright  Portions Copyright 2003 osCommerce
  @copyright  Template built on Developr theme by DisplayInline http://themeforest.net/user/displayinline under Extended license 
  @license    https://github.com/loadedcommerce/loaded7/blob/master/LICENSE.txt
  @version    $Id: edit.php v1.0 2013-08-08 datazen $
*/
if (is_numeric($_GET[$lC_Template->getModule()])) {
    $oInfo = new lC_ObjectInfo(lC_Orders_Admin::getInfo($_GET[$lC_Template->getModule()]));
}
?>
<style scoped="scoped">
  .replacement > .select-value { height: 19px; }
  span.select { height: 33px; }
  .select-value { line-height: 19px; }
</style>
<!-- Main content -->
<section role="main" id="main">
  <hgroup id="main-title" class="thin">
    <h1><?php 
echo $lC_Language->get('text_edit_order') . ': ' . $_GET[$lC_Template->getModule()];
?>
</h1>
    <?php 
if ($lC_MessageStack->exists($lC_Template->getModule())) {
    echo $lC_MessageStack->get($lC_Template->getModule());
}
Example #7
0
    .dataColTime { text-align: center; } 
    .dataColStatus { text-align: left; } 
    .dataColAction { text-align: right; } 
    .dataTables_info { position:absolute; bottom: 42px; color:#4c4c4c; }
    .selectContainer { position:absolute; bottom:29px; left:30px }  
  </style>
  <div class="with-padding-no-top">
    <div id="statusSelectorContainer">
      <div id="statusSelector">
        <form name="orders_status_filter" id="orders_status_filter" action="" onchange="updateOrderList();">
          <label for="filter" class="white mid-margin-right"><?php 
echo $lC_Language->get('text_status');
?>
:</label>
          <?php 
echo lc_draw_pull_down_menu('filter', lC_Orders_Admin::getOrderStatusArray(), null, 'class="input with-small-padding"');
?>
        </form>
      </div>
    </div>
    <form name="batch" id="batch" action="#" method="post">
      <table border="0" width="100%" cellspacing="0" cellpadding="0" class="table responsive-table" id="dataTable">
        <thead>
          <tr>
            <th scope="col" class="hide-on-mobile align-left"><input onclick="toggleCheck();" id="check-all" type="checkbox" value="1" name="check-all"></th>
            <th scope="col" class="align-left"><?php 
echo $lC_Language->get('table_heading_oid');
?>
</th>
            <th scope="col" class="align-left hide-on-mobile-portrait"><?php 
echo $lC_Language->get('table_heading_customers');
Example #8
0
echo $lC_Language->get('text_qty');
?>
</th>
              <th class="align-right hide-on-mobile"><?php 
echo $lC_Language->get('text_total');
?>
</th>
              <th class="align-right"><?php 
echo $lC_Language->get('text_action');
?>
</th>
            </tr>
          </thead>
          <tbody>
            <?php 
foreach (lC_Orders_Admin::getOrdersProducts($_GET[$lC_Template->getModule()]) as $products) {
    ?>
            <tr id="orders_products_<?php 
    echo $products['orders_products_id'];
    ?>
">
              <td class="hide-on-mobile">
                <span id="products_model_<?php 
    echo $products['orders_products_id'];
    ?>
"><?php 
    echo $products['model'];
    ?>
</span>
              </td>
              <td>
Example #9
0
 public static function getOrderInfo()
 {
     $result = array();
     $result = lC_Orders_Admin::getInfo($_GET['oid']);
     $result['rpcStatus'] = RPC_STATUS_SUCCESS;
     echo json_encode($result);
 }
Example #10
0
?>
</td>
                      <td class="align-right pad-5 width-25 bold btop-grey">$0.00</td>
                    </tr>
                  </tbody>
                </table>
              </fieldset>
            </div>-->
          </div>
        </div>
        <div class="six-columns twelve-columns-mobile show-below-768">
          <fieldset>
            <legend class="margin-bottom">
              <span class="icon-chat icon-size2 icon-anthracite mid-margin-left"><strong class="small-margin-left"><?php 
echo $lC_Language->get('text_recent_messages');
?>
</strong></span>
            </legend>
            <table width="100%" cellpadding="0" cellspacing="0">
              <tbody>
              <?php 
echo lC_Orders_Admin::getOrderComments($oInfo->get('oID'));
?>
              </tbody>
            </table>
          </fieldset>
        </div>
      </div>
    </div>
  </div>
</div>
Example #11
0
        <a href="javascript:void(0);" onclick="addOrderTotal(<?php 
echo $_GET[$lC_Template->getModule()];
?>
, '<?php 
echo $lC_Currencies->getSymbolLeft();
?>
');">
          <button type="button" class="button icon-plus-round green-gradient compact">
            <?php 
echo $lC_Language->get('text_add_item');
?>
            
          </button>
        </a>
        <a href="javascript:void(0);" onclick="saveOrderTotal('<?php 
echo $_GET[$lC_Template->getModule()];
?>
');">
          <button type="button" class="button icon-tick green-gradient compact">
            <?php 
echo $lC_Language->get('text_save');
?>
          </button>
        </a>&nbsp;&nbsp;&nbsp;
      </span>
    </div>
    <?php 
echo lC_Orders_Admin::getOrderTotalsList($_GET[$lC_Template->getModule()]);
?>
  </div>
</div>
Example #12
0
 public static function deleteOrderProduct()
 {
     $result = lC_Orders_Admin::deleteOrderProduct();
     if ($result !== false) {
         $result['rpcStatus'] = RPC_STATUS_SUCCESS;
     }
     echo json_encode($result);
 }