Example #1
0
     db_function::payee_insert_json($_POST["MMEX_Post"]);
     echo $operation_succeded;
 }
 #Delete Category
 if (isset($_GET["delete_category"])) {
     db_function::category_delete_all();
     echo $operation_succeded;
 }
 #Import Category
 if (isset($_GET["import_category"])) {
     db_function::category_insert_json($_POST["MMEX_Post"]);
     echo $operation_succeded;
 }
 #Download New Transactions
 if (isset($_GET["download_transaction"])) {
     $TransactionsArr = db_function::transaction_select_all_order_by_date();
     if (!empty($TransactionsArr)) {
         for ($i = 0; $i < sizeof($TransactionsArr); $i++) {
             $TransactionsArr[$i]['Attachments'] = implode(";", attachments::get_attachments_filename_array((int) $TransactionsArr[$i]['ID']));
         }
         echo json_encode($TransactionsArr, JSON_UNESCAPED_UNICODE | JSON_PRETTY_PRINT | JSON_FORCE_OBJECT);
     }
 }
 #Download Attachments by name
 if (isset($_GET["download_attachment"])) {
     $AttachmentFileName = $_GET["download_attachment"];
     if (!empty($AttachmentFileName)) {
         $FullPath = costant::attachments_folder() . "/" . $AttachmentFileName;
         header("Content-Type:");
         header("Cache-Control: public");
         header("Content-Description: File Transfer");
Example #2
0
    <link rel="stylesheet" type="text/css" href="res/bootstrap-3.2.0.min.css" />
    <link rel="stylesheet" type="text/css" href="res/bootstrap-theme-3.2.0.min.css" />
    <link rel="stylesheet" type="text/css" href="res/style_global-0.9.9.css" />

    <script src="res/jquery-2.1.1.min.js" type="text/javascript"></script>
    <script src="res/bootstrap-3.2.0.min.js" type="text/javascript"></script>
    <script src="res/functions-1.0.1.js" type="text/javascript"></script>

</head>

<body>

<?php 
$recordmaxid = db_function::transaction_select_maxid();
if ($recordmaxid > 0) {
    $resultarray = db_function::transaction_select_all_order_by_date();
    echo "<div class='container'>";
    echo "<h3 class='text_align_center'>Current pending transaction</h3>";
    echo "<br/>";
    echo "<div class='table-responsive'>";
    echo "<form id='Show_Function' class='form-show-function' method='post' action = 'show_function.php'>";
    echo "<table class = 'table table-hover table-condensed'>";
    #echo "<table class = 'table table-hover table-condensed table-bordered'>"; //TABLE BORDERED FOR DEBUG
    echo "<thead>";
    echo "<tr>";
    echo "<th>Date</th>";
    echo "<th>Type</th>";
    echo "<th>Account</th>";
    if (costant::disable_payee() == False) {
        echo "<th>Payee</th>";
    }