Dokan – Best WooCommerce Multivendor Marketplace Solution – Build Your Own Amazon, eBay, Etsy - Version 3.0.5

Version Description

Download this release

Release Info

Developer tareq1988
Plugin Icon wp plugin Dokan – Best WooCommerce Multivendor Marketplace Solution – Build Your Own Amazon, eBay, Etsy
Version 3.0.5
Comparing to
See all releases

Code changes from version 3.0.4 to 3.0.5

dokan.php CHANGED
@@ -3,12 +3,12 @@
3
  Plugin Name: Dokan
4
  Plugin URI: https://wordpress.org/plugins/dokan-lite/
5
  Description: An e-commerce marketplace plugin for WordPress. Powered by WooCommerce and weDevs.
6
- Version: 3.0.4
7
  Author: weDevs
8
  Author URI: https://wedevs.com/
9
  Text Domain: dokan-lite
10
  WC requires at least: 3.0
11
- WC tested up to: 4.1.0
12
  Domain Path: /languages/
13
  License: GPL2
14
  */
@@ -54,7 +54,7 @@ final class WeDevs_Dokan {
54
  *
55
  * @var string
56
  */
57
- public $version = '3.0.4';
58
 
59
  /**
60
  * Instance of self
3
  Plugin Name: Dokan
4
  Plugin URI: https://wordpress.org/plugins/dokan-lite/
5
  Description: An e-commerce marketplace plugin for WordPress. Powered by WooCommerce and weDevs.
6
+ Version: 3.0.5
7
  Author: weDevs
8
  Author URI: https://wedevs.com/
9
  Text Domain: dokan-lite
10
  WC requires at least: 3.0
11
+ WC tested up to: 4.2.0
12
  Domain Path: /languages/
13
  License: GPL2
14
  */
54
  *
55
  * @var string
56
  */
57
+ public $version = '3.0.5';
58
 
59
  /**
60
  * Instance of self
includes/Admin/Settings.php CHANGED
@@ -403,6 +403,13 @@ class Settings {
403
  'desc' => __( 'Minimum balance required to make a withdraw request. Leave blank to set no minimum limits.', 'dokan-lite' ),
404
  'default' => '50',
405
  'type' => 'text',
 
 
 
 
 
 
 
406
  )
407
  ),
408
  'dokan_pages' => array(
403
  'desc' => __( 'Minimum balance required to make a withdraw request. Leave blank to set no minimum limits.', 'dokan-lite' ),
404
  'default' => '50',
405
  'type' => 'text',
406
+ ),
407
+ 'exclude_cod_payment' => array(
408
+ 'name' => 'exclude_cod_payment',
409
+ 'label' => __( 'Exclude COD Payments', 'dokan-lite' ),
410
+ 'desc' => __( 'If an order is paid with Cash on Delivery (COD), then exclude that payment from vendor balance.', 'dokan-lite' ),
411
+ 'type' => 'checkbox',
412
+ 'default' => 'off',
413
  )
414
  ),
415
  'dokan_pages' => array(
includes/Order/Hooks.php CHANGED
@@ -93,6 +93,17 @@ class Hooks {
93
  }
94
  }
95
 
 
 
 
 
 
 
 
 
 
 
 
96
  // update on vendor-balance table
97
  $wpdb->update( $wpdb->prefix . 'dokan_vendor_balance',
98
  array( 'status' => $new_status ),
93
  }
94
  }
95
 
96
+ /**
97
+ * If `exclude_cod_payment` is enabled, don't include the fund in vendor's withdrawal balance.
98
+ *
99
+ * @since DOKAN_LITE_SINCE
100
+ */
101
+ $exclude_cod_payment = 'on' === dokan_get_option( 'exclude_cod_payment', 'dokan_withdraw', 'off' );
102
+
103
+ if ( $exclude_cod_payment && 'cod' === $order->get_payment_method() ) {
104
+ return;
105
+ }
106
+
107
  // update on vendor-balance table
108
  $wpdb->update( $wpdb->prefix . 'dokan_vendor_balance',
109
  array( 'status' => $new_status ),
includes/Rewrites.php CHANGED
@@ -272,6 +272,7 @@ class Rewrites {
272
  $store_info = dokan_get_store_info( $seller_info->data->ID );
273
  $post_per_page = isset( $store_info['store_ppp'] ) && ! empty( $store_info['store_ppp'] ) ? $store_info['store_ppp'] : 12;
274
 
 
275
  set_query_var( 'posts_per_page', $post_per_page );
276
 
277
  $query->set( 'post_type', 'product' );
272
  $store_info = dokan_get_store_info( $seller_info->data->ID );
273
  $post_per_page = isset( $store_info['store_ppp'] ) && ! empty( $store_info['store_ppp'] ) ? $store_info['store_ppp'] : 12;
274
 
275
+ do_action( 'dokan_store_page_query_filter', $query, $store_info );
276
  set_query_var( 'posts_per_page', $post_per_page );
277
 
278
  $query->set( 'post_type', 'product' );
includes/ThemeSupport/Divi.php CHANGED
@@ -2,6 +2,8 @@
2
 
3
  namespace WeDevs\Dokan\ThemeSupport;
4
 
 
 
5
  /**
6
  * Divi Theme Support
7
  *
@@ -18,6 +20,7 @@ class Divi {
18
  add_action( 'template_redirect', [ $this, 'remove_sidebar'] );
19
  add_filter( 'body_class', [ $this, 'full_width_page'] );
20
  add_action( 'wp_enqueue_scripts', [ $this, 'style_reset' ] );
 
21
  }
22
 
23
  /**
@@ -65,4 +68,35 @@ class Divi {
65
 
66
  return $classes;
67
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
68
  }
2
 
3
  namespace WeDevs\Dokan\ThemeSupport;
4
 
5
+ use stdClass;
6
+
7
  /**
8
  * Divi Theme Support
9
  *
20
  add_action( 'template_redirect', [ $this, 'remove_sidebar'] );
21
  add_filter( 'body_class', [ $this, 'full_width_page'] );
22
  add_action( 'wp_enqueue_scripts', [ $this, 'style_reset' ] );
23
+ add_action( 'dokan_store_page_query_filter', [ $this, 'set_current_page' ], 10, 2 );
24
  }
25
 
26
  /**
68
 
69
  return $classes;
70
  }
71
+
72
+ /**
73
+ * Set current page for the query
74
+ *
75
+ * @since DOKAN_LITE_SINCE
76
+ *
77
+ * @see https://github.com/weDevsOfficial/dokan/issues/838
78
+ *
79
+ * @param \WP_Query $query
80
+ * @param array $store_info
81
+ *
82
+ * @return void
83
+ */
84
+ public function set_current_page( $query, $store_info ) {
85
+ /**
86
+ * Divi is tightly coupled with singular page data in general and dokan store page is not a regular WordPress page
87
+ * But created with custom rewrite rules. So we'll trick Divi builder to assume dokan store page is really `page` post_type.
88
+ * So lets create a fake page object, and set it to `WP_Query->queried_object` and make the page `is_singular`.
89
+ */
90
+ $page = new stdClass;
91
+ $page->ID = get_option( 'woocommerce_shop_page_id' ); // So it's created by admin, vendor can't see the edit page menu on navbar
92
+ $page->post_type = 'page';
93
+
94
+ $query->is_singular = true;
95
+ $query->queried_object = $page;
96
+ $query->queried_object_id = $page->ID;
97
+
98
+ add_filter( 'pre_get_document_title', function() use ( $store_info ) {
99
+ return ! empty( $store_info['store_name'] ) ? $store_info['store_name'] : __( 'No Name', 'dokan-lite' );
100
+ } );
101
+ }
102
  }
languages/dokan-lite.pot CHANGED
@@ -2,9 +2,9 @@
2
  # This file is distributed under the GPL2.
3
  msgid ""
4
  msgstr ""
5
- "Project-Id-Version: Dokan 3.0.4\n"
6
  "Report-Msgid-Bugs-To: https://wedevs.com/contact/\n"
7
- "POT-Creation-Date: 2020-05-15 10:35:00+00:00\n"
8
  "MIME-Version: 1.0\n"
9
  "Content-Type: text/plain; charset=utf-8\n"
10
  "Content-Transfer-Encoding: 8bit\n"
@@ -516,7 +516,7 @@ msgstr ""
516
 
517
  #: includes/Dashboard/Templates/Dashboard.php:111
518
  #: includes/Order/functions.php:505 includes/admin/SetupWizard.php:508
519
- #: templates/dashboard/orders-widget.php:36 templates/orders/listing.php:138
520
  msgid "Processing"
521
  msgstr ""
522
 
@@ -720,7 +720,7 @@ msgid "Vendor"
720
  msgstr ""
721
 
722
  #: includes/Install/Installer.php:157 includes/admin/AdminBar.php:47
723
- #: includes/admin/Menu.php:42 includes/admin/Settings.php:411
724
  #: includes/template-tags.php:323 src/admin/pages/Dashboard.vue:3
725
  msgid "Dashboard"
726
  msgstr ""
@@ -729,20 +729,20 @@ msgstr ""
729
  msgid "Store List"
730
  msgstr ""
731
 
732
- #: includes/Install/Installer.php:169 includes/admin/Settings.php:419
733
  #: templates/global/header-menu.php:46
734
  msgid "My Orders"
735
  msgstr ""
736
 
737
- #: includes/Order/Hooks.php:143
738
  msgid "Mark parent order completed when all child orders are completed."
739
  msgstr ""
740
 
741
- #: includes/Order/Hooks.php:185
742
  msgid "A coupon must be restricted with a vendor product."
743
  msgstr ""
744
 
745
- #: includes/Order/Hooks.php:240
746
  #. translators: %s item name.
747
  msgid "Unable to restore stock for item %s."
748
  msgstr ""
@@ -780,7 +780,7 @@ msgid "Payment method"
780
  msgstr ""
781
 
782
  #: includes/Order/functions.php:768 templates/orders/listing.php:52
783
- #: templates/orders/listing.php:77
784
  msgid "Order Total"
785
  msgstr ""
786
 
@@ -1274,7 +1274,7 @@ msgid "Delete all variations"
1274
  msgstr ""
1275
 
1276
  #: includes/Product/functions.php:166 templates/my-orders.php:29
1277
- #: templates/orders/listing.php:53 templates/orders/listing.php:80
1278
  #: templates/products/products-listing-row.php:53
1279
  #: templates/products/products-listing.php:89 templates/sub-orders.php:27
1280
  #: templates/withdraw/pending-request-listing.php:18
@@ -1464,7 +1464,7 @@ msgid "Edit"
1464
  msgstr ""
1465
 
1466
  #: includes/Product/functions.php:443 templates/my-orders.php:88
1467
- #: templates/orders/listing.php:157 templates/sub-orders.php:59
1468
  msgid "View"
1469
  msgstr ""
1470
 
@@ -2586,6 +2586,10 @@ msgstr ""
2586
  msgid "You are already logged in"
2587
  msgstr ""
2588
 
 
 
 
 
2589
  #: includes/Upgrade/AdminNotice.php:53
2590
  msgid "You are not authorize to perform this operation."
2591
  msgstr ""
@@ -3061,7 +3065,7 @@ msgstr ""
3061
  msgid "Appearance"
3062
  msgstr ""
3063
 
3064
- #: includes/admin/Settings.php:242 includes/admin/Settings.php:552
3065
  msgid "Privacy Policy"
3066
  msgstr ""
3067
 
@@ -3208,86 +3212,96 @@ msgid ""
3208
  "minimum limits."
3209
  msgstr ""
3210
 
3211
- #: includes/admin/Settings.php:412
 
 
 
 
 
 
 
 
 
 
3212
  msgid "Select a page to show Vendor Dashboard"
3213
  msgstr ""
3214
 
3215
- #: includes/admin/Settings.php:414 includes/admin/Settings.php:422
3216
- #: includes/admin/Settings.php:430 includes/admin/Settings.php:438
3217
- #: includes/admin/Settings.php:547
3218
  msgid "Select page"
3219
  msgstr ""
3220
 
3221
- #: includes/admin/Settings.php:420
3222
  msgid "Select a page to show My Orders"
3223
  msgstr ""
3224
 
3225
- #: includes/admin/Settings.php:427
3226
  msgid "Store Listing"
3227
  msgstr ""
3228
 
3229
- #: includes/admin/Settings.php:428
3230
  msgid "Select a page to show all Stores"
3231
  msgstr ""
3232
 
3233
- #: includes/admin/Settings.php:435
3234
  msgid "Terms and Conditions Page"
3235
  msgstr ""
3236
 
3237
- #: includes/admin/Settings.php:436
3238
  msgid "Select a page to show Terms and Conditions"
3239
  msgstr ""
3240
 
3241
- #: includes/admin/Settings.php:440
3242
  msgid ""
3243
  "Select where you want to add Dokan pages <a target=\"_blank\" href=\"%s\"> "
3244
  "Learn More </a>"
3245
  msgstr ""
3246
 
3247
- #: includes/admin/Settings.php:446
3248
  msgid "Show Map on Store Page"
3249
  msgstr ""
3250
 
3251
- #: includes/admin/Settings.php:447
3252
  msgid "Enable Map of the Store Location in the store sidebar"
3253
  msgstr ""
3254
 
3255
- #: includes/admin/Settings.php:453
3256
  #: templates/admin-setup-wizard/step-store.php:42
3257
  msgid "Map API Source"
3258
  msgstr ""
3259
 
3260
- #: includes/admin/Settings.php:454
3261
  #: templates/admin-setup-wizard/step-store.php:52
3262
  msgid "Which Map API source you want to use in your site?"
3263
  msgstr ""
3264
 
3265
- #: includes/admin/Settings.php:459 includes/admin/SetupWizard.php:349
3266
  msgid "Google Maps"
3267
  msgstr ""
3268
 
3269
- #: includes/admin/Settings.php:460 includes/admin/SetupWizard.php:350
3270
  msgid "Mapbox"
3271
  msgstr ""
3272
 
3273
- #: includes/admin/Settings.php:470
3274
  #: templates/admin-setup-wizard/step-store.php:56
3275
  msgid "Google Map API Key"
3276
  msgstr ""
3277
 
3278
- #: includes/admin/Settings.php:471
3279
  msgid ""
3280
  "<a href=\"https://developers.google.com/maps/documentation/javascript/\" "
3281
  "target=\"_blank\" rel=\"noopener noreferrer\">API Key</a> is needed to "
3282
  "display map on store page"
3283
  msgstr ""
3284
 
3285
- #: includes/admin/Settings.php:481
3286
  #: templates/admin-setup-wizard/step-store.php:71
3287
  msgid "Mapbox Access Token"
3288
  msgstr ""
3289
 
3290
- #: includes/admin/Settings.php:482
3291
  #: templates/admin-setup-wizard/step-store.php:75
3292
  msgid ""
3293
  "<a href=\"https://docs.mapbox.com/help/how-mapbox-works/access-tokens/\" "
@@ -3295,70 +3309,70 @@ msgid ""
3295
  "display map on store page"
3296
  msgstr ""
3297
 
3298
- #: includes/admin/Settings.php:487
3299
  msgid "Show Contact Form on Store Page"
3300
  msgstr ""
3301
 
3302
- #: includes/admin/Settings.php:488
3303
  msgid "Display a vendor contact form in the store sidebar"
3304
  msgstr ""
3305
 
3306
- #: includes/admin/Settings.php:494
3307
  msgid "Store Header Template"
3308
  msgstr ""
3309
 
3310
- #: includes/admin/Settings.php:506
3311
  msgid "Store Opening Closing Time Widget"
3312
  msgstr ""
3313
 
3314
- #: includes/admin/Settings.php:507
3315
  msgid "Enable store opening & closing time widget in the store sidebar"
3316
  msgstr ""
3317
 
3318
- #: includes/admin/Settings.php:513
3319
  msgid "Enable Store Sidebar From Theme"
3320
  msgstr ""
3321
 
3322
- #: includes/admin/Settings.php:514
3323
  msgid "Enable showing Store Sidebar From Your Theme."
3324
  msgstr ""
3325
 
3326
- #: includes/admin/Settings.php:520
3327
  msgid "Hide Vendor Info"
3328
  msgstr ""
3329
 
3330
- #: includes/admin/Settings.php:528
3331
  msgid "Email Address"
3332
  msgstr ""
3333
 
3334
- #: includes/admin/Settings.php:529 includes/admin/UserProfile.php:211
3335
  #: src/admin/pages/VendorAccountFields.vue:64
3336
  #: templates/account/vendor-registration.php:33
3337
  #: templates/global/seller-registration-form.php:38
3338
  msgid "Phone Number"
3339
  msgstr ""
3340
 
3341
- #: includes/admin/Settings.php:530
3342
  msgid "Store Address"
3343
  msgstr ""
3344
 
3345
- #: includes/admin/Settings.php:537
3346
  msgid "Enable Privacy Policy"
3347
  msgstr ""
3348
 
3349
- #: includes/admin/Settings.php:539
3350
  msgid "Enable privacy policy for Vendor store contact form"
3351
  msgstr ""
3352
 
3353
- #: includes/admin/Settings.php:544
3354
  msgid "Privacy Page"
3355
  msgstr ""
3356
 
3357
- #: includes/admin/Settings.php:546
3358
  msgid "Select a page to show your privacy policy"
3359
  msgstr ""
3360
 
3361
- #: includes/admin/Settings.php:555 includes/functions.php:3498
3362
  msgid ""
3363
  "Your personal data will be used to support your experience throughout this "
3364
  "website, to manage access to your account, and for other purposes described "
@@ -4280,7 +4294,7 @@ msgstr ""
4280
 
4281
  #: includes/functions.php:2958 templates/dashboard/big-counter-widget.php:29
4282
  #: templates/my-orders.php:27 templates/orders/details.php:21
4283
- #: templates/orders/listing.php:51 templates/orders/listing.php:70
4284
  #: templates/sub-orders.php:25
4285
  msgid "Order"
4286
  msgstr ""
@@ -5256,6 +5270,7 @@ msgid ""
5256
  msgstr ""
5257
 
5258
  #: templates/dashboard/big-counter-widget.php:21
 
5259
  #: templates/products/products-listing-row.php:86
5260
  #: templates/products/products-listing.php:96
5261
  msgid "Earning"
@@ -5618,8 +5633,8 @@ msgstr ""
5618
  msgid "Recent Orders"
5619
  msgstr ""
5620
 
5621
- #: templates/my-orders.php:28 templates/orders/listing.php:55
5622
- #: templates/orders/listing.php:108
5623
  #: templates/products/products-listing-row.php:124
5624
  #: templates/products/products-listing.php:99 templates/sub-orders.php:26
5625
  #: templates/withdraw/approved-request-listing.php:16
@@ -5817,38 +5832,38 @@ msgstr ""
5817
  msgid "Apply"
5818
  msgstr ""
5819
 
5820
- #: templates/orders/listing.php:54 templates/orders/listing.php:83
5821
  msgid "Customer"
5822
  msgstr ""
5823
 
5824
- #: templates/orders/listing.php:57 templates/orders/listing.php:128
5825
  #: templates/products/downloadable.php:37
5826
  msgid "Action"
5827
  msgstr ""
5828
 
5829
- #: templates/orders/listing.php:72 templates/orders/listing.php:74
5830
  msgid "Order %s"
5831
  msgstr ""
5832
 
5833
- #: templates/orders/listing.php:102
5834
  msgid "Guest"
5835
  msgstr ""
5836
 
5837
- #: templates/orders/listing.php:111
5838
  #: templates/products/products-listing-row.php:127
5839
  msgid "Unpublished"
5840
  msgstr ""
5841
 
5842
- #: templates/orders/listing.php:118
5843
  #: templates/products/products-listing-row.php:137
5844
  msgid "%s ago"
5845
  msgstr ""
5846
 
5847
- #: templates/orders/listing.php:147
5848
  msgid "Complete"
5849
  msgstr ""
5850
 
5851
- #: templates/orders/listing.php:221
5852
  msgid "No orders found"
5853
  msgstr ""
5854
 
2
  # This file is distributed under the GPL2.
3
  msgid ""
4
  msgstr ""
5
+ "Project-Id-Version: Dokan 3.0.5\n"
6
  "Report-Msgid-Bugs-To: https://wedevs.com/contact/\n"
7
+ "POT-Creation-Date: 2020-06-11 13:41:40+00:00\n"
8
  "MIME-Version: 1.0\n"
9
  "Content-Type: text/plain; charset=utf-8\n"
10
  "Content-Transfer-Encoding: 8bit\n"
516
 
517
  #: includes/Dashboard/Templates/Dashboard.php:111
518
  #: includes/Order/functions.php:505 includes/admin/SetupWizard.php:508
519
+ #: templates/dashboard/orders-widget.php:36 templates/orders/listing.php:142
520
  msgid "Processing"
521
  msgstr ""
522
 
720
  msgstr ""
721
 
722
  #: includes/Install/Installer.php:157 includes/admin/AdminBar.php:47
723
+ #: includes/admin/Menu.php:42 includes/admin/Settings.php:418
724
  #: includes/template-tags.php:323 src/admin/pages/Dashboard.vue:3
725
  msgid "Dashboard"
726
  msgstr ""
729
  msgid "Store List"
730
  msgstr ""
731
 
732
+ #: includes/Install/Installer.php:169 includes/admin/Settings.php:426
733
  #: templates/global/header-menu.php:46
734
  msgid "My Orders"
735
  msgstr ""
736
 
737
+ #: includes/Order/Hooks.php:154
738
  msgid "Mark parent order completed when all child orders are completed."
739
  msgstr ""
740
 
741
+ #: includes/Order/Hooks.php:196
742
  msgid "A coupon must be restricted with a vendor product."
743
  msgstr ""
744
 
745
+ #: includes/Order/Hooks.php:251
746
  #. translators: %s item name.
747
  msgid "Unable to restore stock for item %s."
748
  msgstr ""
780
  msgstr ""
781
 
782
  #: includes/Order/functions.php:768 templates/orders/listing.php:52
783
+ #: templates/orders/listing.php:78
784
  msgid "Order Total"
785
  msgstr ""
786
 
1274
  msgstr ""
1275
 
1276
  #: includes/Product/functions.php:166 templates/my-orders.php:29
1277
+ #: templates/orders/listing.php:54 templates/orders/listing.php:84
1278
  #: templates/products/products-listing-row.php:53
1279
  #: templates/products/products-listing.php:89 templates/sub-orders.php:27
1280
  #: templates/withdraw/pending-request-listing.php:18
1464
  msgstr ""
1465
 
1466
  #: includes/Product/functions.php:443 templates/my-orders.php:88
1467
+ #: templates/orders/listing.php:161 templates/sub-orders.php:59
1468
  msgid "View"
1469
  msgstr ""
1470
 
2586
  msgid "You are already logged in"
2587
  msgstr ""
2588
 
2589
+ #: includes/ThemeSupport/Divi.php:99
2590
+ msgid "No Name"
2591
+ msgstr ""
2592
+
2593
  #: includes/Upgrade/AdminNotice.php:53
2594
  msgid "You are not authorize to perform this operation."
2595
  msgstr ""
3065
  msgid "Appearance"
3066
  msgstr ""
3067
 
3068
+ #: includes/admin/Settings.php:242 includes/admin/Settings.php:559
3069
  msgid "Privacy Policy"
3070
  msgstr ""
3071
 
3212
  "minimum limits."
3213
  msgstr ""
3214
 
3215
+ #: includes/admin/Settings.php:409
3216
+ msgid "Exclude COD Payments"
3217
+ msgstr ""
3218
+
3219
+ #: includes/admin/Settings.php:410
3220
+ msgid ""
3221
+ "If an order is paid with Cash on Delivery (COD), then exclude that payment "
3222
+ "from vendor balance."
3223
+ msgstr ""
3224
+
3225
+ #: includes/admin/Settings.php:419
3226
  msgid "Select a page to show Vendor Dashboard"
3227
  msgstr ""
3228
 
3229
+ #: includes/admin/Settings.php:421 includes/admin/Settings.php:429
3230
+ #: includes/admin/Settings.php:437 includes/admin/Settings.php:445
3231
+ #: includes/admin/Settings.php:554
3232
  msgid "Select page"
3233
  msgstr ""
3234
 
3235
+ #: includes/admin/Settings.php:427
3236
  msgid "Select a page to show My Orders"
3237
  msgstr ""
3238
 
3239
+ #: includes/admin/Settings.php:434
3240
  msgid "Store Listing"
3241
  msgstr ""
3242
 
3243
+ #: includes/admin/Settings.php:435
3244
  msgid "Select a page to show all Stores"
3245
  msgstr ""
3246
 
3247
+ #: includes/admin/Settings.php:442
3248
  msgid "Terms and Conditions Page"
3249
  msgstr ""
3250
 
3251
+ #: includes/admin/Settings.php:443
3252
  msgid "Select a page to show Terms and Conditions"
3253
  msgstr ""
3254
 
3255
+ #: includes/admin/Settings.php:447
3256
  msgid ""
3257
  "Select where you want to add Dokan pages <a target=\"_blank\" href=\"%s\"> "
3258
  "Learn More </a>"
3259
  msgstr ""
3260
 
3261
+ #: includes/admin/Settings.php:453
3262
  msgid "Show Map on Store Page"
3263
  msgstr ""
3264
 
3265
+ #: includes/admin/Settings.php:454
3266
  msgid "Enable Map of the Store Location in the store sidebar"
3267
  msgstr ""
3268
 
3269
+ #: includes/admin/Settings.php:460
3270
  #: templates/admin-setup-wizard/step-store.php:42
3271
  msgid "Map API Source"
3272
  msgstr ""
3273
 
3274
+ #: includes/admin/Settings.php:461
3275
  #: templates/admin-setup-wizard/step-store.php:52
3276
  msgid "Which Map API source you want to use in your site?"
3277
  msgstr ""
3278
 
3279
+ #: includes/admin/Settings.php:466 includes/admin/SetupWizard.php:349
3280
  msgid "Google Maps"
3281
  msgstr ""
3282
 
3283
+ #: includes/admin/Settings.php:467 includes/admin/SetupWizard.php:350
3284
  msgid "Mapbox"
3285
  msgstr ""
3286
 
3287
+ #: includes/admin/Settings.php:477
3288
  #: templates/admin-setup-wizard/step-store.php:56
3289
  msgid "Google Map API Key"
3290
  msgstr ""
3291
 
3292
+ #: includes/admin/Settings.php:478
3293
  msgid ""
3294
  "<a href=\"https://developers.google.com/maps/documentation/javascript/\" "
3295
  "target=\"_blank\" rel=\"noopener noreferrer\">API Key</a> is needed to "
3296
  "display map on store page"
3297
  msgstr ""
3298
 
3299
+ #: includes/admin/Settings.php:488
3300
  #: templates/admin-setup-wizard/step-store.php:71
3301
  msgid "Mapbox Access Token"
3302
  msgstr ""
3303
 
3304
+ #: includes/admin/Settings.php:489
3305
  #: templates/admin-setup-wizard/step-store.php:75
3306
  msgid ""
3307
  "<a href=\"https://docs.mapbox.com/help/how-mapbox-works/access-tokens/\" "
3309
  "display map on store page"
3310
  msgstr ""
3311
 
3312
+ #: includes/admin/Settings.php:494
3313
  msgid "Show Contact Form on Store Page"
3314
  msgstr ""
3315
 
3316
+ #: includes/admin/Settings.php:495
3317
  msgid "Display a vendor contact form in the store sidebar"
3318
  msgstr ""
3319
 
3320
+ #: includes/admin/Settings.php:501
3321
  msgid "Store Header Template"
3322
  msgstr ""
3323
 
3324
+ #: includes/admin/Settings.php:513
3325
  msgid "Store Opening Closing Time Widget"
3326
  msgstr ""
3327
 
3328
+ #: includes/admin/Settings.php:514
3329
  msgid "Enable store opening & closing time widget in the store sidebar"
3330
  msgstr ""
3331
 
3332
+ #: includes/admin/Settings.php:520
3333
  msgid "Enable Store Sidebar From Theme"
3334
  msgstr ""
3335
 
3336
+ #: includes/admin/Settings.php:521
3337
  msgid "Enable showing Store Sidebar From Your Theme."
3338
  msgstr ""
3339
 
3340
+ #: includes/admin/Settings.php:527
3341
  msgid "Hide Vendor Info"
3342
  msgstr ""
3343
 
3344
+ #: includes/admin/Settings.php:535
3345
  msgid "Email Address"
3346
  msgstr ""
3347
 
3348
+ #: includes/admin/Settings.php:536 includes/admin/UserProfile.php:211
3349
  #: src/admin/pages/VendorAccountFields.vue:64
3350
  #: templates/account/vendor-registration.php:33
3351
  #: templates/global/seller-registration-form.php:38
3352
  msgid "Phone Number"
3353
  msgstr ""
3354
 
3355
+ #: includes/admin/Settings.php:537
3356
  msgid "Store Address"
3357
  msgstr ""
3358
 
3359
+ #: includes/admin/Settings.php:544
3360
  msgid "Enable Privacy Policy"
3361
  msgstr ""
3362
 
3363
+ #: includes/admin/Settings.php:546
3364
  msgid "Enable privacy policy for Vendor store contact form"
3365
  msgstr ""
3366
 
3367
+ #: includes/admin/Settings.php:551
3368
  msgid "Privacy Page"
3369
  msgstr ""
3370
 
3371
+ #: includes/admin/Settings.php:553
3372
  msgid "Select a page to show your privacy policy"
3373
  msgstr ""
3374
 
3375
+ #: includes/admin/Settings.php:562 includes/functions.php:3498
3376
  msgid ""
3377
  "Your personal data will be used to support your experience throughout this "
3378
  "website, to manage access to your account, and for other purposes described "
4294
 
4295
  #: includes/functions.php:2958 templates/dashboard/big-counter-widget.php:29
4296
  #: templates/my-orders.php:27 templates/orders/details.php:21
4297
+ #: templates/orders/listing.php:51 templates/orders/listing.php:71
4298
  #: templates/sub-orders.php:25
4299
  msgid "Order"
4300
  msgstr ""
5270
  msgstr ""
5271
 
5272
  #: templates/dashboard/big-counter-widget.php:21
5273
+ #: templates/orders/listing.php:53 templates/orders/listing.php:81
5274
  #: templates/products/products-listing-row.php:86
5275
  #: templates/products/products-listing.php:96
5276
  msgid "Earning"
5633
  msgid "Recent Orders"
5634
  msgstr ""
5635
 
5636
+ #: templates/my-orders.php:28 templates/orders/listing.php:56
5637
+ #: templates/orders/listing.php:112
5638
  #: templates/products/products-listing-row.php:124
5639
  #: templates/products/products-listing.php:99 templates/sub-orders.php:26
5640
  #: templates/withdraw/approved-request-listing.php:16
5832
  msgid "Apply"
5833
  msgstr ""
5834
 
5835
+ #: templates/orders/listing.php:55 templates/orders/listing.php:87
5836
  msgid "Customer"
5837
  msgstr ""
5838
 
5839
+ #: templates/orders/listing.php:58 templates/orders/listing.php:132
5840
  #: templates/products/downloadable.php:37
5841
  msgid "Action"
5842
  msgstr ""
5843
 
5844
+ #: templates/orders/listing.php:73 templates/orders/listing.php:75
5845
  msgid "Order %s"
5846
  msgstr ""
5847
 
5848
+ #: templates/orders/listing.php:106
5849
  msgid "Guest"
5850
  msgstr ""
5851
 
5852
+ #: templates/orders/listing.php:115
5853
  #: templates/products/products-listing-row.php:127
5854
  msgid "Unpublished"
5855
  msgstr ""
5856
 
5857
+ #: templates/orders/listing.php:122
5858
  #: templates/products/products-listing-row.php:137
5859
  msgid "%s ago"
5860
  msgstr ""
5861
 
5862
+ #: templates/orders/listing.php:151
5863
  msgid "Complete"
5864
  msgstr ""
5865
 
5866
+ #: templates/orders/listing.php:225
5867
  msgid "No orders found"
5868
  msgstr ""
5869
 
package.json CHANGED
@@ -1,6 +1,6 @@
1
  {
2
  "name": "dokan",
3
- "version": "3.0.4",
4
  "description": "A WordPress marketplace plugin",
5
  "author": "weDevs",
6
  "license": "GPL",
1
  {
2
  "name": "dokan",
3
+ "version": "3.0.5",
4
  "description": "A WordPress marketplace plugin",
5
  "author": "weDevs",
6
  "license": "GPL",
readme.txt CHANGED
@@ -3,11 +3,11 @@ Contributors: tareq1988, wedevs, nizamuddinbabu
3
  Donate Link: http://tareq.co/donate/
4
  Tags: WooCommerce multivendor marketplace, multi vendor marketplace, multi seller store, product vendors, woocommerce vendor, commission rate, e-commerce, ebay, ecommerce, yith, yithemes
5
  Requires at least: 4.4
6
- Tested up to: 5.3.2
7
  WC requires at least: 3.0
8
- WC tested up to: 4.1.0
9
  Requires PHP: 5.6
10
- Stable tag: 3.0.4
11
  License: GPLv2 or later
12
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
13
 
@@ -291,6 +291,15 @@ A. Just install and activate the PRO version without deleting the free plugin. A
291
 
292
  == Changelog ==
293
 
 
 
 
 
 
 
 
 
 
294
  = v3.0.4 (May 15, 2020) =
295
 
296
  - **Fix:** Rename google plus to google as google plus is deprecated #807
@@ -307,7 +316,6 @@ A. Just install and activate the PRO version without deleting the free plugin. A
307
  - **Feat:** Hide vendor info if admin wants to #829
308
  - **Improvement:** Pass vendor id in dokan_get_seller_active_withdraw_methods hook #813
309
 
310
-
311
  = v3.0.3 (April 03, 2020) =
312
 
313
  - **Fix:** Clear caches on product update #804
3
  Donate Link: http://tareq.co/donate/
4
  Tags: WooCommerce multivendor marketplace, multi vendor marketplace, multi seller store, product vendors, woocommerce vendor, commission rate, e-commerce, ebay, ecommerce, yith, yithemes
5
  Requires at least: 4.4
6
+ Tested up to: 5.4.2
7
  WC requires at least: 3.0
8
+ WC tested up to: 4.2.0
9
  Requires PHP: 5.6
10
+ Stable tag: 3.0.5
11
  License: GPLv2 or later
12
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
13
 
291
 
292
  == Changelog ==
293
 
294
+ = v3.0.5 (June 11, 2020) =
295
+
296
+ - [new] Exclude cash on delivery payments from vendor withdrawal balance (COD)
297
+ - [fix] Remove vendor folder from the excluded list
298
+ - [fix] Earning column missing on vendor dashboard order list
299
+ - [fix] Default location not working in vendor dashboard
300
+ - [fix] Remove link from customer name in vendor order details
301
+ - [fix] Custom header, footer template does not work in Dokan store page (Divi Theme)
302
+
303
  = v3.0.4 (May 15, 2020) =
304
 
305
  - **Fix:** Rename google plus to google as google plus is deprecated #807
316
  - **Feat:** Hide vendor info if admin wants to #829
317
  - **Improvement:** Pass vendor id in dokan_get_seller_active_withdraw_methods hook #813
318
 
 
319
  = v3.0.3 (April 03, 2020) =
320
 
321
  - **Fix:** Clear caches on product update #804
templates/maps/dokan-maps-with-search.php CHANGED
@@ -15,6 +15,18 @@ if ( 'mapbox' === $source ) {
15
 
16
  $map_address = ! empty( $map_address ) ? $map_address : 'Dhaka';
17
 
 
 
 
 
 
 
 
 
 
 
 
 
18
  dokan_get_template( 'maps/mapbox-with-search.php', array(
19
  'map_location' => $map_location,
20
  'map_address' => $map_address,
@@ -22,22 +34,34 @@ if ( 'mapbox' === $source ) {
22
  'map_id' => $map_id,
23
  'location' => array(
24
  'address' => $map_address,
25
- 'longitude' => ! empty( $location[1] ) ? $location[1] : 90.40714300000002,
26
- 'latitude' => ! empty( $location[0] ) ? $location[0] : 23.709921,
27
- 'zoom' => 10,
28
  ),
29
  ) );
30
  } else {
31
- $location = explode( ',', $map_location );
32
  $map_address = ! empty( $map_address ) ? $map_address : 'Dhaka';
33
 
 
 
 
 
 
 
 
 
 
 
 
 
34
  dokan_get_template( 'maps/google-maps-with-search.php', array(
35
  'map_location' => $map_location,
36
  'map_address' => $map_address,
37
  'location' => array(
38
  'address' => $map_address,
39
- 'longitude' => ! empty( $location[1] ) ? $location[1] : 90.40714300000002,
40
- 'latitude' => ! empty( $location[0] ) ? $location[0] : 23.709921,
41
  'zoom' => 12,
42
  ),
43
  ) );
15
 
16
  $map_address = ! empty( $map_address ) ? $map_address : 'Dhaka';
17
 
18
+ if ( empty( $map_location ) && function_exists( 'dokan_geo_get_default_location' ) && ! empty( dokan_geo_get_default_location() ) ) {
19
+ $default_location = dokan_geo_get_default_location();
20
+
21
+ $map_address = ! empty( $default_location['address'] ) ? $default_location['address'] : 'Dhaka';
22
+ $longitude = ! empty( $default_location['longitude'] ) ? $default_location['longitude'] : 90.40714300000002;
23
+ $latitude = ! empty( $default_location['latitude'] ) ? $default_location['latitude'] : 23.709921;
24
+ $map_location = $latitude . ',' . $longitude;
25
+ } else {
26
+ $longitude = ! empty( $location[1] ) ? $location[1] : 90.40714300000002;
27
+ $latitude = ! empty( $location[0] ) ? $location[0] : 23.709921;
28
+ }
29
+
30
  dokan_get_template( 'maps/mapbox-with-search.php', array(
31
  'map_location' => $map_location,
32
  'map_address' => $map_address,
34
  'map_id' => $map_id,
35
  'location' => array(
36
  'address' => $map_address,
37
+ 'longitude' => $longitude,
38
+ 'latitude' => $latitude,
39
+ 'zoom' => 12,
40
  ),
41
  ) );
42
  } else {
43
+ $location = explode( ',', $map_location );
44
  $map_address = ! empty( $map_address ) ? $map_address : 'Dhaka';
45
 
46
+ if ( empty( $map_location ) && function_exists( 'dokan_geo_get_default_location' ) && ! empty( dokan_geo_get_default_location() ) ) {
47
+ $default_location = dokan_geo_get_default_location();
48
+
49
+ $map_address = ! empty( $default_location['address'] ) ? $default_location['address'] : 'Dhaka';
50
+ $longitude = ! empty( $default_location['longitude'] ) ? $default_location['longitude'] : 90.40714300000002;
51
+ $latitude = ! empty( $default_location['latitude'] ) ? $default_location['latitude'] : 23.709921;
52
+ $map_location = $latitude . ',' . $longitude;
53
+ } else {
54
+ $longitude = ! empty( $location[1] ) ? $location[1] : 90.40714300000002;
55
+ $latitude = ! empty( $location[0] ) ? $location[0] : 23.709921;
56
+ }
57
+
58
  dokan_get_template( 'maps/google-maps-with-search.php', array(
59
  'map_location' => $map_location,
60
  'map_address' => $map_address,
61
  'location' => array(
62
  'address' => $map_address,
63
+ 'longitude' => $longitude,
64
+ 'latitude' => $latitude,
65
  'zoom' => 12,
66
  ),
67
  ) );
templates/orders/details.php CHANGED
@@ -223,7 +223,7 @@ $hide_customer_info = dokan_get_option( 'hide_customer_info', 'dokan_selling', '
223
  $display_name = get_post_meta( dokan_get_prop( $order, 'id' ), '_billing_first_name', true ). ' '. get_post_meta( dokan_get_prop( $order, 'id' ), '_billing_last_name', true );
224
  }
225
  ?>
226
- <a href="#"><?php echo esc_html( $display_name ); ?></a><br>
227
  </li>
228
  <li>
229
  <span><?php esc_html_e( 'Email:', 'dokan-lite' ); ?></span>
223
  $display_name = get_post_meta( dokan_get_prop( $order, 'id' ), '_billing_first_name', true ). ' '. get_post_meta( dokan_get_prop( $order, 'id' ), '_billing_last_name', true );
224
  }
225
  ?>
226
+ <?php echo esc_html( $display_name ); ?><br>
227
  </li>
228
  <li>
229
  <span><?php esc_html_e( 'Email:', 'dokan-lite' ); ?></span>
templates/orders/listing.php CHANGED
@@ -50,6 +50,7 @@ if ( $user_orders ) {
50
  </th>
51
  <th><?php esc_html_e( 'Order', 'dokan-lite' ); ?></th>
52
  <th><?php esc_html_e( 'Order Total', 'dokan-lite' ); ?></th>
 
53
  <th><?php esc_html_e( 'Status', 'dokan-lite' ); ?></th>
54
  <th><?php esc_html_e( 'Customer', 'dokan-lite' ); ?></th>
55
  <th><?php esc_html_e( 'Date', 'dokan-lite' ); ?></th>
@@ -77,6 +78,9 @@ if ( $user_orders ) {
77
  <td class="dokan-order-total" data-title="<?php esc_attr_e( 'Order Total', 'dokan-lite' ); ?>" >
78
  <?php echo $order->get_formatted_order_total(); ?>
79
  </td>
 
 
 
80
  <td class="dokan-order-status" data-title="<?php esc_attr_e( 'Status', 'dokan-lite' ); ?>" >
81
  <?php echo '<span class="dokan-label dokan-label-' . dokan_get_order_status_class( dokan_get_prop( $order, 'status' ) ) . '">' . dokan_get_order_status_translated( dokan_get_prop( $order, 'status' ) ) . '</span>'; ?>
82
  </td>
50
  </th>
51
  <th><?php esc_html_e( 'Order', 'dokan-lite' ); ?></th>
52
  <th><?php esc_html_e( 'Order Total', 'dokan-lite' ); ?></th>
53
+ <th><?php esc_html_e( 'Earning', 'dokan-lite' ); ?></th>
54
  <th><?php esc_html_e( 'Status', 'dokan-lite' ); ?></th>
55
  <th><?php esc_html_e( 'Customer', 'dokan-lite' ); ?></th>
56
  <th><?php esc_html_e( 'Date', 'dokan-lite' ); ?></th>
78
  <td class="dokan-order-total" data-title="<?php esc_attr_e( 'Order Total', 'dokan-lite' ); ?>" >
79
  <?php echo $order->get_formatted_order_total(); ?>
80
  </td>
81
+ <td class="dokan-order-earning" data-title="<?php esc_attr_e( 'Earning', 'dokan-lite' ); ?>" >
82
+ <?php echo wp_kses_post( wc_price( dokan()->commission->get_earning_by_order( $order ) ) ); ?>
83
+ </td>
84
  <td class="dokan-order-status" data-title="<?php esc_attr_e( 'Status', 'dokan-lite' ); ?>" >
85
  <?php echo '<span class="dokan-label dokan-label-' . dokan_get_order_status_class( dokan_get_prop( $order, 'status' ) ) . '">' . dokan_get_order_status_translated( dokan_get_prop( $order, 'status' ) ) . '</span>'; ?>
86
  </td>
vendor/autoload.php CHANGED
@@ -4,4 +4,4 @@
4
 
5
  require_once __DIR__ . '/composer/autoload_real.php';
6
 
7
- return ComposerAutoloaderInit7c5d12db56d4a4a6d60281b579f34d67::getLoader();
4
 
5
  require_once __DIR__ . '/composer/autoload_real.php';
6
 
7
+ return ComposerAutoloaderInit1c4c9de8296c897d391c30dd522c2485::getLoader();
vendor/composer/autoload_real.php CHANGED
@@ -2,7 +2,7 @@
2
 
3
  // autoload_real.php @generated by Composer
4
 
5
- class ComposerAutoloaderInit7c5d12db56d4a4a6d60281b579f34d67
6
  {
7
  private static $loader;
8
 
@@ -22,15 +22,15 @@ class ComposerAutoloaderInit7c5d12db56d4a4a6d60281b579f34d67
22
  return self::$loader;
23
  }
24
 
25
- spl_autoload_register(array('ComposerAutoloaderInit7c5d12db56d4a4a6d60281b579f34d67', 'loadClassLoader'), true, true);
26
  self::$loader = $loader = new \Composer\Autoload\ClassLoader();
27
- spl_autoload_unregister(array('ComposerAutoloaderInit7c5d12db56d4a4a6d60281b579f34d67', 'loadClassLoader'));
28
 
29
  $useStaticLoader = PHP_VERSION_ID >= 50600 && !defined('HHVM_VERSION') && (!function_exists('zend_loader_file_encoded') || !zend_loader_file_encoded());
30
  if ($useStaticLoader) {
31
  require_once __DIR__ . '/autoload_static.php';
32
 
33
- call_user_func(\Composer\Autoload\ComposerStaticInit7c5d12db56d4a4a6d60281b579f34d67::getInitializer($loader));
34
  } else {
35
  $map = require __DIR__ . '/autoload_namespaces.php';
36
  foreach ($map as $namespace => $path) {
2
 
3
  // autoload_real.php @generated by Composer
4
 
5
+ class ComposerAutoloaderInit1c4c9de8296c897d391c30dd522c2485
6
  {
7
  private static $loader;
8
 
22
  return self::$loader;
23
  }
24
 
25
+ spl_autoload_register(array('ComposerAutoloaderInit1c4c9de8296c897d391c30dd522c2485', 'loadClassLoader'), true, true);
26
  self::$loader = $loader = new \Composer\Autoload\ClassLoader();
27
+ spl_autoload_unregister(array('ComposerAutoloaderInit1c4c9de8296c897d391c30dd522c2485', 'loadClassLoader'));
28
 
29
  $useStaticLoader = PHP_VERSION_ID >= 50600 && !defined('HHVM_VERSION') && (!function_exists('zend_loader_file_encoded') || !zend_loader_file_encoded());
30
  if ($useStaticLoader) {
31
  require_once __DIR__ . '/autoload_static.php';
32
 
33
+ call_user_func(\Composer\Autoload\ComposerStaticInit1c4c9de8296c897d391c30dd522c2485::getInitializer($loader));
34
  } else {
35
  $map = require __DIR__ . '/autoload_namespaces.php';
36
  foreach ($map as $namespace => $path) {
vendor/composer/autoload_static.php CHANGED
@@ -4,7 +4,7 @@
4
 
5
  namespace Composer\Autoload;
6
 
7
- class ComposerStaticInit7c5d12db56d4a4a6d60281b579f34d67
8
  {
9
  public static $prefixLengthsPsr4 = array (
10
  'W' =>
@@ -164,9 +164,9 @@ class ComposerStaticInit7c5d12db56d4a4a6d60281b579f34d67
164
  public static function getInitializer(ClassLoader $loader)
165
  {
166
  return \Closure::bind(function () use ($loader) {
167
- $loader->prefixLengthsPsr4 = ComposerStaticInit7c5d12db56d4a4a6d60281b579f34d67::$prefixLengthsPsr4;
168
- $loader->prefixDirsPsr4 = ComposerStaticInit7c5d12db56d4a4a6d60281b579f34d67::$prefixDirsPsr4;
169
- $loader->classMap = ComposerStaticInit7c5d12db56d4a4a6d60281b579f34d67::$classMap;
170
 
171
  }, null, ClassLoader::class);
172
  }
4
 
5
  namespace Composer\Autoload;
6
 
7
+ class ComposerStaticInit1c4c9de8296c897d391c30dd522c2485
8
  {
9
  public static $prefixLengthsPsr4 = array (
10
  'W' =>
164
  public static function getInitializer(ClassLoader $loader)
165
  {
166
  return \Closure::bind(function () use ($loader) {
167
+ $loader->prefixLengthsPsr4 = ComposerStaticInit1c4c9de8296c897d391c30dd522c2485::$prefixLengthsPsr4;
168
+ $loader->prefixDirsPsr4 = ComposerStaticInit1c4c9de8296c897d391c30dd522c2485::$prefixDirsPsr4;
169
+ $loader->classMap = ComposerStaticInit1c4c9de8296c897d391c30dd522c2485::$classMap;
170
 
171
  }, null, ClassLoader::class);
172
  }