Commit Graph
11 Commits
Author SHA1 Message Date
Rémy Voet (ryv) 234db70d86 [IMP] *: Use the new API of _read_group for backend use
Part-of: odoo/odoo#110737
2023-04-19 21:58:27 +02:00
Horacio Tellez b7332c016f [FIX] loyalty: rewards being reset to default upon save.
Before this commit when choosing the program rule type "Buy X get Y"
an error occured: after adding rewards and trying to save the record
the rewards were reset to the default value for program rules
of type "discount".

This ocurred because the program type was not being sent to the
`default_get` method of the `loyalty.reward` record.
After this commit rewards are correctly preserved.

opw - 3240558

closes odoo/odoo#118679

X-original-commit: 44b9eab482a219e6c260ef29512b8d6a595300ac
Signed-off-by: Victor Feyens (vfe) <vfe@odoo.com>
2023-04-17 11:46:59 +02:00
althaf shaik 9b2c39df36 [FIX] loyalty: prevent trace back when user deleted ewallet_product_50 record
This error was caught by sentry.

Steps to produce:-

* Install eCommerce,loyalty module.
* Delete 'Top-up eWallet' product from eCommerce/product.
* Then  create a new Gift card & eWallets from eCommerce/Gift card & eWallets.
* At this moment A trace back raise.

Because user deleted the product 'Top-up eWallet'.

Sentry:-3985154178

closes odoo/odoo#116738

X-original-commit: e5ae091a530de45741749e01d25f436af093a8a2
Signed-off-by: Victor Feyens (vfe) <vfe@odoo.com>
2023-03-27 19:13:50 +02:00
William Braeckman cd14193919 [FIX] loyalty: make it possible to import coupons etc
TaskId-2991207

closes odoo/odoo#102062

X-original-commit: d4a92b112d0554a2624f7768feb7d54e0484469f
Related: odoo/enterprise#32249
Signed-off-by: William Braeckman (wbr) <wbr@odoo.com>
2022-10-04 16:01:13 +02:00
Fabien Pinckaers 302773097c [IMP] loyalty: short copywriting + padding
closes odoo/odoo#101059

Signed-off-by: Fabien Pinckaers <fp@odoo.com>
2022-09-25 14:04:15 +02:00
William Braeckman d5a1b78de0 [FIX] loyalty: fix generate ewallet from list view
Prior to this commit it was not possible to choose the customer when the
wizard was started form an ewallet's program ewallet list view.

TaskId-2982239

Part-of: odoo/odoo#100170
2022-09-14 23:37:58 +02:00
William Braeckman 5162186579 [IMP] loyalty: lots of small ui changes
This PR is a followup to odoo/odoo#99023

TaskId-2977152

closes odoo/odoo#99900

Signed-off-by: William Braeckman (wbr) <wbr@odoo.com>
2022-09-09 14:41:28 +02:00
roen-odoo 14408d6af5 [FIX] website_sale_delivery: fix unstable tour
This PR adds some trigger to make sure that all python request
is correctly finished. This is needed because an unfinished python request
makes a traceback appears on runbot.

opw-28835921

closes odoo/odoo#99475

X-original-commit: 7a98b59b36e9e2cf1816b73ebc3be5de58e054c2
Signed-off-by: William Braeckman (wbr) <wbr@odoo.com>
2022-09-04 15:37:49 +02:00
eres-odooandWilliam Braeckman 6927dcda9f [IMP] loyalty*: misc loyalty improvements
This commit improves some messages and usability for loyalty and its
submodules:
 - Coupons should not be restricted to the partner assigned to them
   anymore
 - Merged "I have a promo code" and "Use a gift card" into a single
   toggle
 - Boolean fields have been added to each app to disable them where we
   don't want them.
 - Reduced the size of coupon codes
   This means that we increase the risk of collision which should be
   handled by the model as well now.
   Creating a coupon with an existing code will retry the creation (up
   to 10 times) until the coupon is indeed created.
 - Make it clearer in the coupon generation wizard that an email will be
   sent to the customer.
 - Reintroduce coupon/gift card details on sale order lines in eCommerce
   which was wrongfully removed.
 - Remove the "on product with taxes: " message on order lines when
   the amount is not split between taxes or if the tax message would be
   empty.
 - Make it possible for some error messages to be displayed as warning
   instead of errors
 - Split program types in two menuitems, one for promotions discount
   loyalty etc and one for gift cards and ewallet, the latter has
   simplified views.
 - Views overall have been reviewed to make it easier to understand how
   to programs work. New program types have also been added.

TaskId-2951413

Part-of: odoo/odoo#99023
Co-authored-by: William Braeckman <wbr@odoo.com>
2022-09-02 20:10:59 +02:00
William Braeckman 5662b31b40 [IMP] loyalty: adapt views to wowl 2
Due to the new form and list views some of the customisation of loyalty
were not working properly anymore.
This commit adapts the js customisation inside of loyalty to wowl 2.

TaskId-2929488

closes odoo/odoo#96731

Signed-off-by: William Braeckman (wbr) <wbr@odoo.com>
2022-07-27 07:59:50 +02:00
William BraeckmanandCarlos Valverde 9bb9eaf067 [ADD] loyalty: manage loyalty, promotions and more
This module is an unification of `coupon`, `gift_card` and an extraction
of the program models of `pos_loyalty`.

The goal of this module is to unify the creation of coupon, promotion,
gift_card, loyalty programs etc.. into a single base module and share
the same models.

Managers will be able to create programs based on rules and rewards.
Programs may apply on the current order (rules and rewards)
or on future orders, where the rules must match the first order to get a
reward on the second order
or even be nominative and accumulate points over multiple orders.

Every program is based on a point system. And each use of the program
will result in the creation of a coupon (except for nominative programs
which should be limited to one card per customer).

A rule may filter on quantity, money spent and products and give points
on the order, the amount of units paid or the amount of money spent.

A reward could be a free product, a discount or (with an additional
module) free shipping.
Discounts can be percentage based, fixed, or based on the amount of
points the card has.
They can also be filtered on products or tags, to discount specific
products.

A new feature is also being able to select communication plan for these
programs.
The manager can define a template to be sent upon the creation of a new
coupon/card or when reaching a certain amount of points.

TaskId-2675382

For empty list design:

Co-authored-by: Carlos Valverde <cvs@odoo.com>
2022-04-08 09:38:45 +02:00