Skip to content

Commit 639ab28

Browse files
authored
Merge pull request #63 from rohit053/v1.3.2
V1.3.2 released: Guest Checkout, New Designed Checkout Page, Custom CMS Link, Data Cleaner module
2 parents 0533e5f + e05b328 commit 639ab28

528 files changed

Lines changed: 41049 additions & 4031 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.travis.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,4 +33,4 @@ after_failure:
3333
- cat /etc/apache2/sites-available/000-default.conf
3434
- sudo cat /var/log/php-fpm.log
3535
- sudo ls -l /var/log/apache2
36-
- sudo cat /var/log/apache2/other_vhosts_access.log
36+
- sudo cat /var/log/apache2/other_vhosts_access.log

CHANGELOG.txt

Lines changed: 31 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,33 @@
1+
####################################
2+
# V1.3.2
3+
####################################
4+
5+
## Added Features:
6+
7+
[+] CO : pscleaner module is added for cleaning demo data from QloApps.
8+
9+
[+] FO : Option for Guest checkout is given at Preferences->Orders tab. So Guest Checkout is enabled.
10+
11+
[+] FO : Option for Shorter registration/address form is given at Preferences->Customers tab. (In this case address will be created from customer chosen room type's hotel address automatically).
12+
13+
[+] CO : wkfooterexploreblock :: Admin can add custom explore links to show at footer explore block and navigation menu also. table 'htl_custom_explore_link' added with multilang.
14+
15+
## Improved/changed features:
16+
17+
[-] BO : New category option from "quick access" links is removed.
18+
[+] FO : Checkout page design has been changed.
19+
[+] CO : Images validation improved.
20+
21+
22+
## Bug/Issues Resolved:
23+
24+
[-] CO : 56% Installation issue.
25+
26+
[-] BO : Dashboard graphs not loading issues on php 7.2
27+
[-] BO : feature update issue on not selecting image while updating the feature.
28+
[-] BO : Category bug resolve (Should not be created updated deleted from anywhere). Will be handled from hotel creation/updation/deletion.
29+
30+
131
####################################
232
# V1.3.1
333
####################################
@@ -342,4 +372,4 @@
342372
[-] MO : wktestimonialblock : Fixed while adding the image in valid format on configuration page then showing error page.
343373
[-] MO : wkpaypaladaptive : Fixed paypal is not working because paypal api has been changed.
344374
[-] MO : wkpaypaladaptive : Fixed fopen issues fixed, done by CURL.
345-
[-] MO : wkpaypaladaptive : Fixed payment negative value bug fixed.
375+
[-] MO : wkpaypaladaptive : Fixed payment negative value bug fixed.

admin/themes/default/template/controllers/products/associations.tpl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,9 +38,9 @@
3838
<div id="category_block">
3939
{$category_tree}
4040
</div>
41-
<a class="btn btn-link bt-icon confirm_leave" href="{$link->getAdminLink('AdminCategories')|escape:'html':'UTF-8'}&amp;addcategory">
41+
{* <a class="btn btn-link bt-icon confirm_leave" href="{$link->getAdminLink('AdminCategories')|escape:'html':'UTF-8'}&amp;addcategory">
4242
<i class="icon-plus-sign"></i> {l s='Create new category'} <i class="icon-external-link-sign"></i>
43-
</a>
43+
</a> *}
4444
</div>
4545
</div>
4646
<div class="form-group">

classes/Address.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -203,6 +203,8 @@ public function delete()
203203
if (Validate::isUnsignedId($this->id_customer)) {
204204
Customer::resetAddressCache($this->id_customer, $this->id);
205205
}
206+
// reset checkout process if addresses deletes
207+
CheckoutProcess::refreshCheckoutProcess();
206208

207209
if (!$this->isUsed()) {
208210
return parent::delete();

classes/Category.php

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -433,10 +433,11 @@ protected static function _subTree(&$categories, $id_category, &$n)
433433
}
434434
$right = (int)$n++;
435435

436-
Db::getInstance()->execute('
437-
UPDATE '._DB_PREFIX_.'category
438-
SET nleft = '.(int)$left.', nright = '.(int)$right.'
439-
WHERE id_category = '.(int)$id_category.' LIMIT 1');
436+
Db::getInstance()->execute(
437+
'UPDATE '._DB_PREFIX_.'category
438+
SET nleft = '.(int)$left.', nright = '.(int)$right.'
439+
WHERE id_category = '.(int)$id_category.' LIMIT 1'
440+
);
440441
}
441442

442443
/**

classes/Feature.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ class FeatureCore extends ObjectModel
4141
'position' => array('type' => self::TYPE_INT, 'validate' => 'isInt'),
4242

4343
/* Lang fields */
44-
'name' => array('type' => self::TYPE_STRING, 'lang' => true, 'validate' => 'isGenericName', 'required' => true, 'size' => 128),
44+
'name' => array('type' => self::TYPE_STRING, 'lang' => true, 'validate' => 'isCatalogName', 'required' => true, 'size' => 128),
4545
),
4646
);
4747

classes/Hook.php

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -418,8 +418,7 @@ public static function getHookModuleExecList($hook_name = null)
418418
*
419419
* @return string/array modules output
420420
*/
421-
public static function exec($hook_name, $hook_args = array(), $id_module = null, $array_return = false, $check_exceptions = true,
422-
$use_push = false, $id_shop = null)
421+
public static function exec($hook_name, $hook_args = array(), $id_module = null, $array_return = false, $check_exceptions = true, $use_push = false, $id_shop = null)
423422
{
424423
if (defined('PS_INSTALLATION_IN_PROGRESS')) {
425424
return;
@@ -462,7 +461,11 @@ public static function exec($hook_name, $hook_args = array(), $id_module = null,
462461

463462
// Look on modules list
464463
$altern = 0;
465-
$output = '';
464+
if ($array_return) {
465+
$output = array();
466+
} else {
467+
$output = '';
468+
}
466469

467470
if ($disable_non_native_modules && !isset(Hook::$native_module)) {
468471
Hook::$native_module = Module::getNativeModuleList();
Lines changed: 82 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,82 @@
1+
<?php
2+
/**
3+
* 2007-2018 PrestaShop
4+
*
5+
* NOTICE OF LICENSE
6+
*
7+
* This source file is subject to the Open Software License (OSL 3.0)
8+
* that is bundled with this package in the file LICENSE.txt.
9+
* It is also available through the world-wide-web at this URL:
10+
* https://opensource.org/licenses/OSL-3.0
11+
* If you did not receive a copy of the license and are unable to
12+
* obtain it through the world-wide-web, please send an email
13+
* to license@prestashop.com so we can send you a copy immediately.
14+
*
15+
* DISCLAIMER
16+
*
17+
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
18+
* versions in the future. If you wish to customize PrestaShop for your
19+
* needs please refer to http://www.prestashop.com for more information.
20+
*
21+
* @author PrestaShop SA <contact@prestashop.com>
22+
* @copyright 2007-2018 PrestaShop SA
23+
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
24+
* International Registered Trademark & Property of PrestaShop SA
25+
*/
26+
27+
abstract class AbstractCheckoutStep implements CheckoutStepInterface
28+
{
29+
public $step_is_reachable = 0;
30+
public $step_is_complete = 0;
31+
public $step_is_current = 0;
32+
public $step_key;
33+
private $checkoutProcess;
34+
35+
public function __construct()
36+
{
37+
$this->context = Context::getContext();
38+
}
39+
40+
public function setCheckoutProcess(CheckoutProcess $checkoutProcess)
41+
{
42+
$this->checkoutProcess = $checkoutProcess;
43+
44+
return $this;
45+
}
46+
47+
public function setReachable($step_is_reachable)
48+
{
49+
$this->step_is_reachable = $step_is_reachable;
50+
51+
return $this;
52+
}
53+
54+
public function isReachable()
55+
{
56+
return $this->step_is_reachable;
57+
}
58+
59+
public function setComplete($step_is_complete)
60+
{
61+
$this->step_is_complete = $step_is_complete;
62+
63+
return $this;
64+
}
65+
66+
public function isComplete()
67+
{
68+
return $this->step_is_complete;
69+
}
70+
71+
public function setCurrent($step_is_current)
72+
{
73+
$this->step_is_current = $step_is_current;
74+
75+
return $this;
76+
}
77+
78+
public function isCurrent()
79+
{
80+
return $this->step_is_current;
81+
}
82+
}
Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
<?php
2+
/**
3+
* 2010-2018 Webkul.
4+
*
5+
* NOTICE OF LICENSE
6+
*
7+
* All right is reserved,
8+
* Please go through this link for complete license : https://store.webkul.com/license.html
9+
*
10+
* DISCLAIMER
11+
*
12+
* Do not edit or add to this file if you wish to upgrade this module to newer
13+
* versions in the future. If you wish to customize this module for your
14+
* needs please refer to https://store.webkul.com/customisation-guidelines/ for more information.
15+
*
16+
* @author Webkul IN <support@webkul.com>
17+
* @copyright 2010-2018 Webkul IN
18+
* @license https://store.webkul.com/license.html
19+
*/
20+
21+
class CheckoutCartSummaryStep extends AbstractCheckoutStep
22+
{
23+
public function __construct() {
24+
parent::__construct();
25+
$this->step_key = 'checkout_rooms_summary';
26+
}
27+
28+
public function handleRequest()
29+
{
30+
// set data in checkout_session cookie
31+
if (Tools::getValue('proceed_to_customer_dtl')) {
32+
$this->step_is_reachable = 1;
33+
$this->step_is_complete = 1;
34+
$this->step_is_current = 0;
35+
$this->context->cookie->__set('cart_summary_proceeded', 1);
36+
} elseif ($this->context->cookie->__get('cart_summary_proceeded')) {
37+
$this->step_is_reachable = 1;
38+
$this->step_is_complete = 1;
39+
$this->step_is_current = 0;
40+
}
41+
42+
return $this;
43+
}
44+
}
Lines changed: 77 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,77 @@
1+
<?php
2+
/**
3+
* 2010-2018 Webkul.
4+
*
5+
* NOTICE OF LICENSE
6+
*
7+
* All right is reserved,
8+
* Please go through this link for complete license : https://store.webkul.com/license.html
9+
*
10+
* DISCLAIMER
11+
*
12+
* Do not edit or add to this file if you wish to upgrade this module to newer
13+
* versions in the future. If you wish to customize this module for your
14+
* needs please refer to https://store.webkul.com/customisation-guidelines/ for more information.
15+
*
16+
* @author Webkul IN <support@webkul.com>
17+
* @copyright 2010-2018 Webkul IN
18+
* @license https://store.webkul.com/license.html
19+
*/
20+
21+
class CheckoutCustomerDetailsStep extends AbstractCheckoutStep
22+
{
23+
public function __construct() {
24+
parent::__construct();
25+
$this->step_key = 'checkout_customer';
26+
}
27+
28+
public function handleRequest()
29+
{
30+
$idAddressDelivery = $this->context->cart->id_address_delivery;
31+
$objAddress = new Address($idAddressDelivery);
32+
if (Tools::getValue('proceed_to_customer_dtl')) {
33+
$this->step_is_reachable = 1;
34+
$this->step_is_current = 1;
35+
if ($idAddressDelivery) {
36+
if (!Validate::isLoadedObject($objAddress)) {
37+
if ($this->context->cookie->__get('customer_details_proceeded')) {
38+
$this->step_is_current = 0;
39+
$this->step_is_complete = 1;
40+
}
41+
}
42+
}
43+
} elseif (Tools::getValue('proceed_to_payment')) {
44+
$this->step_is_reachable = 1;
45+
$this->step_is_current = 1;
46+
if ($idAddressDelivery) {
47+
if (Validate::isLoadedObject($objAddress)) {
48+
$this->step_is_current = 0;
49+
$this->step_is_complete = 1;
50+
$this->context->cookie->__set('customer_details_proceeded', 1);
51+
}
52+
}
53+
} elseif ($this->context->cookie->__get('customer_details_proceeded')
54+
|| $this->context->cookie->__get('cart_summary_proceeded')
55+
) {
56+
if ($idAddressDelivery) {
57+
if (!Validate::isLoadedObject($objAddress)) {
58+
$this->context->cookie->__set('customer_details_proceeded', 0);
59+
$this->step_is_reachable = 1;
60+
$this->step_is_current = 1;
61+
}
62+
} else {
63+
$this->step_is_reachable = 1;
64+
$this->step_is_current = 1;
65+
$this->context->cookie->__set('customer_details_proceeded', 0);
66+
}
67+
} elseif ($this->context->customer->logged) {
68+
$this->step_is_reachable = 1;
69+
if ($idAddressDelivery) {
70+
$this->step_is_complete = 1;
71+
} else {
72+
$this->step_is_complete = 0;
73+
$this->step_is_current = 1;
74+
}
75+
}
76+
}
77+
}

0 commit comments

Comments
 (0)