예제 #1
0
    <link type="text/css" rel="stylesheet" href="styles/font-awesome.min.css">
    <link type="text/css" rel="stylesheet" href="styles/bootstrap.min.css">
    <link type="text/css" rel="stylesheet" href="styles/animate.css">
    <link type="text/css" rel="stylesheet" href="styles/all.css">
    <link type="text/css" rel="stylesheet" href="styles/main.css">
    <link type="text/css" rel="stylesheet" href="styles/style-responsive.css">
    <link type="text/css" rel="stylesheet" href="styles/zabuto_calendar.min.css">
    <link type="text/css" rel="stylesheet" href="styles/pace.css">
</head>
<body>
<?php 
include "utils/utils.php";
include "classes/mysql.php";
$db = new MySQL();
$db->conecta() or die("Erro de conexão ao banco");
$idg = getVoucher();
$cliente = $db->_n_cliente_os();
$tipo_serviço = $db->_n_tipo_serv_os();
$tecnico = $db->_n_tecnico_os();
$grupo_prod = $db->_n_grupo_produto_os();
?>

<div class="container">
    <ul class="payment-wizard">
        <li class="active">
            <div class="wizard-heading">
                1. Ordem de Serviço
                <span class="icon-user"></span>
            </div>
            <div class="wizard-content">
                <div class="form-group">Cliente *
예제 #2
0
    $agi->conlog('Card: ' . print_r($card, true), 4);
    //TODO: fix lang
    if ($card['status'] != 1) {
        switch ($card['status']) {
            case 8:
                //disabled card in booth
                $agi->stream_file('prepaid-no-card-entered', '#');
                break;
            case 5:
                $agi->stream_file('prepaid-card-expired', '#');
                break;
            default:
                $agi->verbose('Card status: ' . $card['status'] . ', exiting.', 2);
        }
        break;
    }
    // Here, we're authorized..
    if (getVoucher($card) !== null) {
        // perhaps stream the credit?
        break;
    }
    // or continue, if voucher didn't succeed.
}
if ($card && !empty($card['locked'])) {
    ReleaseCard($card);
}
$agi->conlog('Goodbye!', 3);
if (getAGIconfig('say_goodbye', true) && $agi->is_alive) {
    $agi->stream_file('prepaid-final', '#');
}
$agi->hangup();
예제 #3
0
<?php

function getVoucher()
{
    // Monta yymmddhhiisslll e converte para hexadecimal
    $micro = explode(".", (double) microtime(true) / 1000);
    $mili = substr($micro[1], 0, 3);
    $modelo = date("ymdHis");
    $modelo = $modelo . $mili;
    $voucher = base_convert('2190964402', 10, 16);
    $micro = explode(".", (double) microtime(true) / 1000);
    echo "<br>" . $micro . "<br>";
    $mili = substr($micro[1], 0, 3);
    echo "<br>" . $mili . "<br>";
    $modelo = date("ymdHis");
    echo "<br>" . $modelo . "<br>";
    $modelo = $modelo . $mili;
    echo "<br>" . $modelo . "<br>";
    $voucher = dechex($modelo);
    echo "<br>" . $voucher . "<br>";
    return $voucher;
}
echo "\n\n" . getVoucher() . "\n\n";