Plugin Directory

Changeset 2612875


Ignore:
Timestamp:
10/12/2021 07:51:42 AM (4 years ago)
Author:
rezaplus
Message:

Fixed issues with ordered products

Location:
orders-pro
Files:
320 added
9 edited

Legend:

Unmodified
Added
Removed
  • orders-pro/trunk/assets/OrdersPro-rtl.css

    r2494296 r2612875  
    66    float:left !important;
    77}
    8 .wc-order-preview .wc-order-preview-table .wc-order-preview-table__column--product {
     8body .wc-order-preview .wc-order-preview-table .wc-order-preview-table__column--product {
    99    text-align: right !important;
    1010}
  • orders-pro/trunk/assets/OrdersPro.css

    r2517359 r2612875  
    1616    width: 90%;
    1717    margin: 20px 0px;
     18}
     19.OSPO_itemorder{
     20    display: block;
     21    width: max-content;
    1822}
    1923.wc-backbone-modal-content {
  • orders-pro/trunk/functions/OrdersPreview.php

    r2494296 r2612875  
    11<?php
     2/**
     3 * return woocommerce order preview custom columns.
     4 */
    25add_filter( 'woocommerce_admin_order_preview_line_item_columns',function( $_columns ) {
     6    //set Columns name
    37    $ProductID = [ 'ProductID' => esc_html__( 'ID','woocommerce') ];
    48    $Image = [ 'image' => esc_html__( 'Image') ];
     
    1216    $tax = [ 'tax' => esc_html__( 'Tax','dokan-lite') ];
    1317//  $items  = count( $_columns );
    14     $OrderPro_Column = get_option('OrderPro_Column');
     18    $OrderPro_Column = get_option('OrderPro_Column'); //get custom culomns
     19    if(empty($OrderPro_Column)) //if the custom columns are not set.
     20        return $_columns;//return defult culomns.
    1521    $columns = array();
    16     foreach($OrderPro_Column as $column => $value)
     22    foreach($OrderPro_Column as $column => $value)  //create custom columns array
    1723    {
    18         if($value == "true")
     24        if($value == "true")    //if column is set from setings
    1925        {
    20             $columns = array_merge($columns, ${$column});
     26            $columns = array_merge($columns, ${$column});   //add column to array
    2127        }
    2228    }
    23    
    2429    return $columns ;
    2530});
  • orders-pro/trunk/functions/OrdersPreview/columns.php

    r2494296 r2612875  
    99//  Total column
    1010add_filter( 'woocommerce_admin_order_preview_line_item_column_'.sanitize_key('total-price'), function( $result, $_item , $item_id, $order) {
    11     $price;
     11    $price = '';
    1212    if($_item['quantity'] > 1){$price = strip_tags(wc_price($_item['total']/$_item['quantity'], array( 'currency' => $order->get_currency() ) ));}
    1313    return ' <div title="'.$price.'">'. wc_price( $_item['total'], array( 'currency' => $order->get_currency() ) ).'</div>' ;
     
    2727}, 10,2 );
    2828
    29 if(OrdersPro_License_Version == "free"){
    3029// stock column
    3130    add_filter( 'woocommerce_admin_order_preview_line_item_column_stock',function() {
    3231        return OSPO_premiumHTML;
    3332    }, 10);
    34    
    35 }
    3633//  Vendor column
    3734add_filter( 'woocommerce_admin_order_preview_line_item_column_vendor', function ( $result, $_item ) {
  • orders-pro/trunk/languages/OrderPro_domain-fa_IR.po

    r2516266 r2612875  
    44"Project-Id-Version: Orders Pro premium\n"
    55"POT-Creation-Date: 2021-04-11 18:17+0430\n"
    6 "PO-Revision-Date: 2021-04-11 18:40+0430\n"
     6"PO-Revision-Date: 2021-10-12 10:45+0330\n"
    77"Language-Team: rezaplus\n"
    88"MIME-Version: 1.0\n"
     
    1212"X-Poedit-Basepath: ..\n"
    1313"X-Poedit-Flags-xgettext: --add-comments=translators:\n"
    14 "X-Poedit-WPHeader: orders-pro-premium.php\n"
     14"X-Poedit-WPHeader: orders-pro.php\n"
    1515"X-Poedit-SourceCharset: UTF-8\n"
    1616"X-Poedit-KeywordsList: __;_e;_n:1,2;_x:1,2c;_ex:1,2c;_nx:4c,1,2;esc_attr__;"
     
    2525#: pages/Options/Translations.php:7
    2626msgid "In stock"
    27 msgstr ""
     27msgstr "In stock"
    2828
    2929#: functions/Options.php:24 pages/Options/Translations.php:9
    3030#: pages/Options/Translations.php:10
    3131msgid "Out of stock"
    32 msgstr ""
     32msgstr "Out of stock"
    3333
    3434#: functions/Options.php:25 pages/Options/Translations.php:12
    3535#: pages/Options/Translations.php:13
    3636msgid "Low in stock"
    37 msgstr ""
     37msgstr "Low in stock"
    3838
    3939#: functions/Options.php:26 pages/Options/Translations.php:15
    4040#: pages/Options/Translations.php:16
    4141msgid "On backorder"
    42 msgstr ""
     42msgstr "On backorder"
    4343
    4444#: functions/OrdersPreview.php:3 pages/Options/OrderPreviewColumns.php:10
    4545msgid "ID"
    46 msgstr ""
     46msgstr "ID"
    4747
    4848#: functions/OrdersPreview.php:4 pages/Options/OrderPreviewColumns.php:5
     
    5050#: premium/pages/Orderes_products.php:58
    5151msgid "Image"
    52 msgstr ""
     52msgstr "Image"
    5353
    5454#: functions/OrdersPreview.php:5 pages/Options/OrderPreviewColumns.php:7
    5555msgid "Category"
    56 msgstr ""
     56msgstr "Category"
    5757
    5858#: functions/OrdersPreview.php:6 orders-pro-premium.php:155
     
    6262#: premium/pages/Orderes_products.php:61
    6363msgid "Product"
    64 msgstr ""
     64msgstr "Product"
    6565
    6666#: functions/OrdersPreview.php:7 pages/Options/OrderPreviewColumns.php:8
    6767msgid "Stock"
    68 msgstr ""
     68msgstr "Stock"
    6969
    7070#: functions/OrdersPreview.php:8 pages/Options/OrderPreviewColumns.php:4
     
    7272#: premium/pages/Orderes_products.php:64
    7373msgid "Quantity"
    74 msgstr ""
     74msgstr "Quantity"
    7575
    7676#: functions/OrdersPreview.php:9 pages/Options/OrderPreviewColumns.php:6
    7777#: pages/Options/Orders.php:11
    7878msgid "Total"
    79 msgstr ""
     79msgstr "Total"
    8080
    8181#: functions/OrdersPreview.php:10 pages/Options/OrderPreviewColumns.php:9
     
    8383#: premium/pages/Orderes_products.php:67
    8484msgid "Price"
    85 msgstr ""
     85msgstr "Price"
    8686
    8787#: functions/OrdersPreview.php:11 pages/Options/OrderPreviewColumns.php:13
    8888#: pages/Options/Orders.php:14
    8989msgid "Vendor"
    90 msgstr ""
     90msgstr "Vendor"
    9191
    9292#: functions/OrdersPreview.php:12 pages/Options/OrderPreviewColumns.php:11
    9393msgid "Tax"
    94 msgstr ""
     94msgstr "Tax"
    9595
    9696#: orders-pro-premium.php:66
     
    100100#: orders-pro-premium.php:141
    101101msgid "Regular price"
    102 msgstr ""
     102msgstr "Regular price"
    103103
    104104#: orders-pro-premium.php:142
    105105msgid "Sale price"
    106 msgstr ""
     106msgstr "Sale price"
    107107
    108108#: orders-pro-premium.php:143
     
    116116#: orders-pro-premium.php:145 premium/functions/OrdersPreview/columns.php:27
    117117msgid "Manage stock"
    118 msgstr ""
     118msgstr "Manage stock"
    119119
    120120#: orders-pro-premium.php:145 premium/functions/OrdersPreview/columns.php:27
    121121msgid "Inactive"
    122 msgstr ""
     122msgstr "Inactive"
    123123
    124124#: orders-pro-premium.php:146
    125125msgid "Stock qty"
    126 msgstr ""
     126msgstr "Stock qty"
    127127
    128128#: orders-pro-premium.php:153
     
    134134msgctxt "Admin menu name"
    135135msgid "Orders"
    136 msgstr ""
     136msgstr "Orders"
    137137
    138138#: orders-pro-premium.php:155
    139139msgid "Products"
    140 msgstr ""
     140msgstr "Products"
    141141
    142142#: orders-pro-premium.php:188
     
    154154#: pages/Options/Orders.php:3
    155155msgid "Screen Options"
    156 msgstr ""
     156msgstr "Screen Options"
    157157
    158158#: pages/Options/Orders.php:3
     
    170170#: pages/Options/Orders.php:7 premium/pages/Options/License.php:24
    171171msgid "Activate"
    172 msgstr ""
     172msgstr "Activate"
    173173
    174174#: pages/Options/Orders.php:17
    175175msgid "Actions"
    176 msgstr ""
     176msgstr "Actions"
    177177
    178178#: pages/Options/Orders.php:20
    179179msgid "Shipping Address"
    180 msgstr ""
     180msgstr "Shipping Address"
    181181
    182182#: pages/Options/Orders.php:23
    183183msgid "Billing Address"
    184 msgstr ""
     184msgstr "Billing Address"
    185185
    186186#: pages/Options/Orders.php:31
     
    191191#: premium/pages/Orderes_products.php:70
    192192msgid "Order"
    193 msgstr ""
     193msgstr "Order"
    194194
    195195#: pages/Options/Translations.php:2 pages/options.php:6
     
    207207#: pages/Orderes_products.php:131 premium/pages/Orderes_products.php:130
    208208msgid "Number of orders"
    209 msgstr ""
     209msgstr "Number of orders"
    210210
    211211#: pages/Orderes_products.php:133 premium/pages/Orderes_products.php:132
    212212msgid "Run"
    213 msgstr ""
     213msgstr "Run"
    214214
    215215#: pages/options.php:4
    216216msgid "Orders"
    217 msgstr ""
     217msgstr "Orders"
    218218
    219219#: pages/options.php:5
    220220msgid "Preview"
    221 msgstr ""
     221msgstr "Preview"
    222222
    223223#: pages/options.php:8 premium/pages/Options/License.php:18
     
    227227#: pages/options.php:19
    228228msgid "Save changes"
    229 msgstr ""
     229msgstr "Save changes"
    230230
    231231#: premium/functions/OrdersPreview/columns.php:23
    232232#, php-format
    233233msgid "%s in stock"
    234 msgstr ""
     234msgstr "%s in stock"
    235235
    236236#: premium/functions/update.php:73
     
    242242#: premium/functions/update.php:78
    243243msgid "An unknown error occurred"
    244 msgstr ""
     244msgstr "An unknown error occurred"
    245245
    246246#: premium/pages/Options/License.php:20
     
    250250#: premium/pages/Options/License.php:29
    251251msgid "Deactivate"
    252 msgstr ""
     252msgstr "Deactivate"
    253253
    254254#: premium/pages/Options/License.php:32
     
    267267#. Plugin URI of the plugin/theme
    268268msgid "\"\""
    269 msgstr ""
     269msgstr "\"\""
    270270
    271271#. Description of the plugin/theme
     
    275275#. Author of the plugin/theme
    276276msgid "@rezaplus"
    277 msgstr ""
     277msgstr "@rezaplus"
    278278
    279279#. Author URI of the plugin/theme
    280280msgid "\"rellaco.com\""
    281 msgstr ""
     281msgstr "\"rellaco.com\""
  • orders-pro/trunk/orders-pro.php

    r2535309 r2612875  
    44 * Description: Professionally Customize  admin-side orders page and enjoy it.
    55 * Plugin URI: "https://rellaco.com/product/orderspro-premium/"
    6  * Author: @rezaplus
    7  * Version: 1.6
    8  * Author URI: "rellaco.com"
     6 * Author: rezaplus
     7 * Author URI: https://rezahajizade.com/
    98 * Text Domain: OrderPro_domain
    10  * Requires PHP: 7.0
    11  * Tested up to: 5.7.2
    12  * WC tested up to: 5.2.2
     9 *
     10 * Version: 1.7
     11 * Requires PHP: 5.6
     12 * WC requires at least: 4.7.0
     13 * WC tested up to: 5.7.1
    1314 *
    1415 * This program is free software; you can redistribute it and/or modify
     
    2526if ( ! defined( 'ABSPATH' ) ) exit;
    2627
    27 define('OrdersPro_version', "1.6");
     28define('OrdersPro_version', "1.7");
    2829define('OrdersPro_License_Version', "free");
    2930
  • orders-pro/trunk/pages/Orderes_products.php

    r2517359 r2612875  
    4949if(!function_exists('OSPO_orderes_products_table')){
    5050    function OSPO_orderes_products_table($products ){
     51       
    5152        echo '<table class="wp-list-table widefat posts striped Orderes_products_table"><thead>';
    5253       
     
    7273            $product = wc_get_product( $productID );
    7374           
    74             //check product not deleted.
    75             if(!$product) break;
     75         if(!$product) continue; //check product not deleted.
    7676           
    7777            $image = wp_get_attachment_image_src( get_post_thumbnail_id( $productID ), 'thumbnail' );
  • orders-pro/trunk/readme.txt

    r2517359 r2612875  
    11=== Orders Pro ===
    2 Contributors: Rellaco, rezaplus
    3 Tags: woocommerce orders, wc orders, order preview, ordered products, orders pro, order pro, orders, orderspro
    4 Requires at least: 4.7
    5 Tested up to: 5.6
    6 Stable tag: 1.6
    7 Requires PHP: 7.0
    8 License: GPLv2 or later
     2Contributors: Rellaco, Reza Hajizade
     3Tags: woocommerce orders, wc orders, order preview, ordered products, orders pro, orders, custom order preview, custom order preview columns, Show product's image in Order preview, order items list, customise woocommerce admin orders
     4Requires at least: 4.7.0
     5Requires PHP: 5.6
     6Tested up to: 5.8.1
     7Stable tag: 1.7
     8License: GPLv2
    99License URI: https://www.gnu.org/licenses/gpl-2.0.html
    1010
     
    1313== Description ==
    1414
    15 The plugin will help you to:
     15## The plugin will help you to: ##
    1616
    1717have Better orders preview with necessary information.
     
    1919In Mobile, the list of orders gives you information such as total prices, address, operations, etc.
    2020
    21 See the screenshots and Video below to get an even better idea of the plugins functionality.
     21## See the screenshots below to get an even better idea of the plugins functionality. ##
    2222
    2323https://www.youtube.com/watch?v=L2KfYjtwA7A
    2424
    25 Why the preview should be professional?
     25* ** Why the preview should be professional? **
    2626 
    2727Order preview gives you detailed information about the orders.
     
    3434Display product ID and category name of order items.
    3535
    36 List of ordered products:
     36* ** List of ordered products: **
    3737
    3838On this page, you will enter a list of ordered products with the desired status (processing, completed, on-hold and etc.).
     
    4141You can easily prepare the products before you start packing
    4242
    43 Mobile order page settings:
     43* ** Mobile order page settings: **
    4444
    4545In mobile mode, the order list in usual mode shows the order ID along with the name, date and status of your order. By installing this plugin you can, in addition to other items, also provide information such as:
     
    8484
    8585== Changelog ==
     86== 1.7 ==
     87Fixed issues with ordered products
    8688== 1.6 ==
    8789*Fixed warrings
Note: See TracChangeset for help on using the changeset viewer.