Skip to content

Commit

Permalink
Merge branch 'release/2.6.7'
Browse files Browse the repository at this point in the history
  • Loading branch information
sabbir1991 committed Aug 3, 2017
2 parents 3925192 + 61966a3 commit cb3d161
Show file tree
Hide file tree
Showing 10 changed files with 49 additions and 22 deletions.
9 changes: 9 additions & 0 deletions assets/js/dokan.js
Original file line number Diff line number Diff line change
Expand Up @@ -521,6 +521,7 @@ jQuery(function($) {

$( 'body' ).on( 'click', '.product-container-footer input[type="submit"]', this.createNewProduct );

this.attribute.disbalePredefinedAttribute();
},

saleSchedule: function() {
Expand Down Expand Up @@ -900,6 +901,14 @@ jQuery(function($) {
});
});

},

disbalePredefinedAttribute: function() {
$( 'ul.dokan-attribute-option-list li.product-attribute-list' ).each( function( index, el ) {
if ( $( el ).css( 'display' ) !== 'none' && $( el ).is( '.taxonomy' ) ) {
$( 'select#predefined_attribute' ).find( 'option[value="' + $( el ).data( 'taxonomy' ) + '"]' ).attr( 'disabled', 'disabled' );
}
});
}
},

Expand Down
9 changes: 9 additions & 0 deletions assets/src/js/product-editor.js
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,7 @@

$( 'body' ).on( 'click', '.product-container-footer input[type="submit"]', this.createNewProduct );

this.attribute.disbalePredefinedAttribute();
},

saleSchedule: function() {
Expand Down Expand Up @@ -447,6 +448,14 @@
});
});

},

disbalePredefinedAttribute: function() {
$( 'ul.dokan-attribute-option-list li.product-attribute-list' ).each( function( index, el ) {
if ( $( el ).css( 'display' ) !== 'none' && $( el ).is( '.taxonomy' ) ) {
$( 'select#predefined_attribute' ).find( 'option[value="' + $( el ).data( 'taxonomy' ) + '"]' ).attr( 'disabled', 'disabled' );
}
});
}
},

Expand Down
5 changes: 5 additions & 0 deletions changelog.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
v2.6.7 -> Aug 3, 2017
---------------------
- [fix] Fix multiple vendor order creating issue
- [fix] Disable pre defined attribute which already set with product

v2.6.6 -> July 31, 2017
---------------------
- [fix] Dokan Emails are not translating
Expand Down
4 changes: 2 additions & 2 deletions dokan.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
Plugin Name: Dokan
Plugin URI: https://wordpress.org/plugins/dokan-lite/
Description: An e-commerce marketplace plugin for WordPress. Powered by WooCommerce and weDevs.
Version: 2.6.6
Version: 2.6.7
Author: weDevs
Author URI: https://wedevs.com/
Text Domain: dokan-lite
Expand Down Expand Up @@ -45,7 +45,7 @@
define( '__DIR__', dirname( __FILE__ ) );
}

define( 'DOKAN_PLUGIN_VERSION', '2.6.6' );
define( 'DOKAN_PLUGIN_VERSION', '2.6.7' );
define( 'DOKAN_FILE', __FILE__ );
define( 'DOKAN_DIR', __DIR__ );
define( 'DOKAN_INC_DIR', __DIR__ . '/includes' );
Expand Down
15 changes: 7 additions & 8 deletions includes/order-functions.php
Original file line number Diff line number Diff line change
Expand Up @@ -360,8 +360,7 @@ function dokan_delete_sync_duplicate_order( $order_id, $seller_id ) {
function dokan_sync_insert_order( $order_id ) {
global $wpdb;

$order_post = get_post( $order_id );
if ( get_post_meta( $order_id, 'has_sub_order', true ) == true || $order_post->post_parent == 0 ) {
if ( get_post_meta( $order_id, 'has_sub_order', true ) == '1' ) {
return;
}

Expand Down Expand Up @@ -398,7 +397,7 @@ function dokan_sync_insert_order( $order_id ) {
);
}

add_action( 'woocommerce_checkout_update_order_meta', 'dokan_sync_insert_order' );
add_action( 'woocommerce_checkout_update_order_meta', 'dokan_sync_insert_order', 20 );
add_action( 'dokan_checkout_update_order_meta', 'dokan_sync_insert_order' );


Expand Down Expand Up @@ -751,14 +750,14 @@ function dokan_get_admin_commission_by( $order, $seller_id ) {

if ( ! function_exists( 'dokan_get_customer_orders_by_seller' ) ) :
/**
* Get Customer Orders by Seller
*
* Get Customer Orders by Seller
*
* @since 2.6.6
*
*
* @param int $customer_id
*
*
* @param int $seller_id
*
*
* @return Object $order
*/
function dokan_get_customer_orders_by_seller( $customer_id, $seller_id ) {
Expand Down
2 changes: 1 addition & 1 deletion includes/wc-functions.php
Original file line number Diff line number Diff line change
Expand Up @@ -423,7 +423,7 @@ function dokan_process_product_file_download_paths( $product_id, $variation_id,
}
}

add_action( 'woocommerce_checkout_update_order_meta', 'dokan_create_sub_order' );
add_action( 'woocommerce_checkout_update_order_meta', 'dokan_create_sub_order', 10 );

/**
* Get discount coupon total from a order
Expand Down
18 changes: 9 additions & 9 deletions languages/dokan-lite.pot
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@
# This file is distributed under the GPL2.
msgid ""
msgstr ""
"Project-Id-Version: Dokan 2.6.6\n"
"Project-Id-Version: Dokan 2.6.7\n"
"Report-Msgid-Bugs-To: http://wedevs.com/support/forum/theme-support/dokan/\n"
"POT-Creation-Date: 2017-07-31 18:47:23+00:00\n"
"POT-Creation-Date: 2017-08-03 04:10:07+00:00\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=utf-8\n"
"Content-Transfer-Encoding: 8bit\n"
Expand Down Expand Up @@ -1415,17 +1415,17 @@ msgstr ""
msgid "Order Status for Withdraw"
msgstr ""

#: includes/admin/setup-wizard.php:450 includes/order-functions.php:498
#: includes/admin/setup-wizard.php:450 includes/order-functions.php:497
#: templates/dashboard/orders-widget.php:26
msgid "Completed"
msgstr ""

#: includes/admin/setup-wizard.php:451 includes/order-functions.php:513
#: includes/admin/setup-wizard.php:451 includes/order-functions.php:512
#: templates/dashboard/orders-widget.php:36 templates/orders/listing.php:96
msgid "Processing"
msgstr ""

#: includes/admin/setup-wizard.php:452 includes/order-functions.php:508
#: includes/admin/setup-wizard.php:452 includes/order-functions.php:507
msgid "On-hold"
msgstr ""

Expand Down Expand Up @@ -1526,7 +1526,7 @@ msgstr ""
msgid "Approved"
msgstr ""

#: includes/admin/withdraw.php:23 includes/order-functions.php:523
#: includes/admin/withdraw.php:23 includes/order-functions.php:522
#: templates/dashboard/orders-widget.php:41
msgid "Cancelled"
msgstr ""
Expand Down Expand Up @@ -1776,15 +1776,15 @@ msgstr ""
msgid "Mark parent order completed when all child orders are completed."
msgstr ""

#: includes/order-functions.php:503
#: includes/order-functions.php:502
msgid "Pending Payment"
msgstr ""

#: includes/order-functions.php:518 templates/dashboard/orders-widget.php:46
#: includes/order-functions.php:517 templates/dashboard/orders-widget.php:46
msgid "Refunded"
msgstr ""

#: includes/order-functions.php:528
#: includes/order-functions.php:527
msgid "Failed"
msgstr ""

Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "dokan",
"version": "2.6.6",
"version": "2.6.7",
"description": "A WordPress marketplace plugin",
"author": "weDevs",
"license": "GPL",
Expand Down
5 changes: 5 additions & 0 deletions readme.txt
Original file line number Diff line number Diff line change
Expand Up @@ -180,6 +180,11 @@ A. Just install and activate the PRO version without deleting the free plugin. A

== Changelog ==

v2.6.7 -> Aug 3, 2017
---------------------
- [fix] Fix multiple vendor order creating issue
- [fix] Disable pre defined attribute which already set with product

v2.6.6 -> July 31, 2017
---------------------
- [fix] Dokan Emails are not translating
Expand Down
2 changes: 1 addition & 1 deletion templates/orders/details.php
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@

<div class="clear"></div>

<div class="" style="100%">
<div class="" style="width: 100%">
<div class="dokan-panel dokan-panel-default">
<div class="dokan-panel-heading"><strong><?php _e( 'Downloadable Product Permission', 'dokan-lite' ); ?></strong></div>
<div class="dokan-panel-body">
Expand Down

0 comments on commit cb3d161

Please sign in to comment.