Plugin Directory

Changeset 2551813


Ignore:
Timestamp:
06/22/2021 06:35:34 AM (5 years ago)
Author:
jtexpress
Message:

optimize

Location:
jt-express/trunk
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • jt-express/trunk/admin/class-jnt-admin.php

    r2415591 r2551813  
    5656
    5757    public function parcel_admin_page(){
    58 
     58        $res = "";
    5959        if ( $_POST ) {
    6060            $awb = $_POST['tracking'];
  • jt-express/trunk/admin/class-jnt-cancel-order.php

    r2321253 r2551813  
    5454                }
    5555
    56                 if($status == 'Succeed'){
     56                if($status == 'success'){
    5757                    if ( ! get_post_meta( $id, 'cancel', true ) ) {
    5858                        $cancelled = array();
  • jt-express/trunk/admin/view/thermal-new.php

    r2416315 r2551813  
    357357                grid-template-rows: 0.7fr 0.7fr 1.4fr 0.1fr;
    358358                grid-template-areas:
    359                 "senderBarcode"
     359                "senderCopyBarcode"
    360360                "senderDetailsTo"
    361361                "senderInfoDetails"
     
    363363            }
    364364
     365            #senderCopyBarcode {
     366                grid-area: senderCopyBarcode;
     367                border-bottom: 1px solid black;
     368                display: grid;
     369                grid-template-columns: 1fr 0.2fr;
     370                grid-template-rows: 1fr;
     371                grid-template-areas:
     372                    "senderBarcode senderDetail";
     373            }
     374
     375            #senderDetail {
     376                grid-area: senderDetail;
     377                display: flex;
     378                align-items: flex-end;
     379                border-left: 1px solid black;
     380                text-align: center;
     381                font-size: 10px;
     382                font-weight: 900;
     383                display: grid;
     384                grid-template-rows: 1fr 1fr 1fr;
     385                grid-template-areas:
     386                    "date"
     387                    "orderno"
     388                    "weight";
     389            }
     390
     391            #date {
     392                grid-area: date;
     393                border-bottom: 1px solid black;
     394            }
     395
     396            #orderno {
     397                grid-area: orderno;
     398                border-bottom: 1px solid black;
     399            }
     400
     401            #weight {
     402                grid-area: weight;
     403            }
     404
    365405            #senderBarcode {
    366406                grid-area: senderBarcode;
    367                 border-bottom: 1px solid black;
    368407                text-align: center;
    369                 margin-top: 11px;
     408                margin-top: 3px;
     409                margin-left:  45px;
    370410            }
    371411            #senderBarcode img {
    372                 max-width: 65%;
     412                max-width: 80%;
    373413            }
    374414            #senderDetailsTo {
     
    531571                            </div>
    532572                            <div id="senderCopy">
    533                                 <div id="senderBarcode">
    534                                     <center>
    535                                         <?php $this->jnt_api->generate( get_post_meta( $id, 'jtawb', true ) ); ?><br/>
    536                                         <span class="font12 bold"><?= get_post_meta( $id, 'jtawb', true ) ?></span>
    537                                     </center>
     573                                <div id="senderCopyBarcode">
     574                                    <div id="senderBarcode">
     575                                        <center>
     576                                            <?php $this->jnt_api->generate( get_post_meta( $id, 'jtawb', true ) ); ?><br/>
     577                                            <span class="font12 bold"><?= get_post_meta( $id, 'jtawb', true ) ?></span>
     578                                        </center>
     579                                    </div>
     580                                    <div id="senderDetail">
     581                                        <div id="date"><?= date('Y-m-d') ?></div>
     582                                        <div id="orderno"><?= $order_no ?></div>
     583                                        <div id="weight"><?= $weight ?> KG</div>
     584                                    </div>
    538585                                </div>
    539586                                <div id="senderDetailsTo">
  • jt-express/trunk/includes/class-jnt-api.php

    r2483284 r2551813  
    7272    public function cancel ($awbs) {
    7373
    74         $url = 'http://14.192.70.169:22232/JandT_BLIBLI_web/api/cancelOrder.action';
     74        $url = 'https://api.jtexpress.my/blibli/order/cancelOrder';
    7575       
    7676        $key = 'AKe62df84bJ3d8e4b1hea2R45j11klsb';
     
    8080        foreach ($awbs as $value) {
    8181            $data = [
    82                 'detail' => array(
    83                     array(
    84                         'username' => 'WORDPRESS',
    85                         'api_key' => 'WORD12',
    86                         'awb_no' => $value['awb']
    87                     )
    88                 )
     82                'username' => 'WORDPRESS',
     83                'api_key' => 'WORD12',
     84                'awb_no' => $value['awb']
    8985            ];
    9086
     
    110106
    111107    public function printA4($cuscode, $awbs) {
    112         $url = "http://14.192.70.169:22233/jandt_report_web/print/A4facelistAction!print.action";
     108        $url = "https://api.jtexpress.my/jandt_report_web/print/A4facelistAction!print.action";
    113109                   
    114110        $logistics_interface    = array(
     
    127123
    128124    public function print($cuscode, $awbs) {
    129         $url = 'http://14.192.70.169:22233/jandt_report_web/print/facelistAction!print.action';
     125        $url = 'https://api.jtexpress.my/jandt_report_web/print/facelistAction!print.action';
    130126
    131127        $logistics_interface = array(
  • jt-express/trunk/jnt.php

    r2528783 r2551813  
    1313}
    1414
    15 define( 'JNT_VERSION', '1.0.21' );
     15define( 'JNT_VERSION', '1.0.22' );
    1616define( 'JNT_PLUGIN_DIR', plugin_dir_path( __FILE__ ) );
    1717
Note: See TracChangeset for help on using the changeset viewer.