summaryrefslogtreecommitdiff
path: root/addons/website_event_questions/controllers/main.py
AgeCommit message (Collapse)Author
2020-08-17[FIX] website_event(_*): improve user flow and experience from frontendstd-odoo
PURPOSE Provide some fixes after internal test deployment of event online features. Notably: user registration flow, various fixes in templates. Also add some unit tests to avoid regressions while working on event features. LINKS Task ID-2169118 odoo/odoo#55967 odoo/enterprise#12438 X-original-commit: e66684b23eebaadc3df7b908427d3d7a83d4f0a0
2020-03-31[IMP] website_event_questions: allow 'free text' questionsAurélien Warnon
PURPOSE Allow "free text" questions in the event questions asked to attendees, in addition to the existing "selection" type. e.g: "What are your allergies?" SPECS The implementation is heavily based on the modelisation we chose for the survey module since the features become similar in terms of question types and inputs. - Introduce a 'question_type' that is either 'simple_choice' (= previous behavior) or 'text_box' that will contain the attendee text answer. - Rename the event.answer model to event.question.answer to make it more obvious that it contains answer "suggestions" to a question of type 'simple_choice'. - Introduce a 'event.user_input.line' that is an answer to a specific question for a specific registration. It works very similarly to 'survey.user_input.line' but it's not contained in a 'user_input' model, it's directly linked to the registration using a 'user_input_line_ids' o2m field. The frontend view has been adapted accordingly to display either a selection input or a textarea based on the question type. The frontend orm processing now takes in both answer types (id of suggested answer or text input). On the backend side, views have been adapted to display event questions and attendee answers in a more convenient and logical manner. LINKS PR #45497 Upgrade PR odoo/upgrade#799 Task ID 2189529
2020-02-18[FIX] website_event(_questions): correctly parse frontend question answersDebauche Stéphane
When user register to an event from website, they can answer questions specific to a given registration or to all registrations. However they are not correctly parsed and not saved. Task 2188857 PR #44545 X-original-commit: e27d9b5c4f234f6ce64456c2f52e7cfb0331332f
2020-01-30[REF][MOV] website_event(_sale): support tickets in website_event frontendThibault Delavallée
PURPOSE Integration between event and eCommerce is required only when users handle the entire selling process online. However users may require ticketing support while managing payments outside of Odoo. Purpose of this commit is to support tickets directly in event application without need of sales. RATIONALE Remove the need to have event_sale installed to manage basic multi ticket event type. Integration with eCommerce is needed only when one wants to handle the entire selling flow online, i.e. order, payment, ... Integration with Sales is needed only when one wants to create sale orders linked to attendees. Many event users do not need all of this. Their attendees pay through bank transfers or they simply manage payments outside of Odoo while still requiring tickets management. SPECIFICATIONS In this commit we move frontend part of ticket support from website_event_sale to website_event. Now eCommerce / event integration adds only payment information when registering. About tickets * if there is no ticket -> generic registration allowed; * if there is one ticket -> quick registration box; * more than one ticket -> unfolding registration box with all available tickets; About price * sale not installed -> no mention of price. A ticket without price is not free. Its description allow to tell how to pay for example; * a price is set: price is displayed; * no price is set: FREE is displayed; Most event frontend templates and controllers are therefore moved from website_event_sale to website_event. Only part about pricing and sale order creation is now located in website_event_sale. Buy flow remains mainly untouched. Indeed this commit is mainly about moving template to support tickets. LINKS Task ID 2177281 Community PR #43488
2017-08-20[FIX] P3: remove pycompat.{keys,items,values} helpersOlivier Dony
Now that we're closer to switching to P3 for good, these helpers have outlived their usefulness, and mostly add noise. All remaining dict.iter*() or dict.view*() must be converted to the normal keys(), values() or items() calls. Whenever the result is likely to be used for more than the scope of a loop, or when the dict needs to be modified during iteration, the calls must be wrapped in a ``list()``, to protect the new P3 semantics. Those cases are very exceptional. Also removed some dead code or improved the API to remove unnecessary conversions.
2017-05-10[FIX] P3: list -> iterable builtins (#16811)xmo-odoo
In Python 3: * various builtins and dict methods were changed to return view/iterable objects rather than lists * and the separate Python 2 view/iterable builtins and methods were removed altogether This is problematic when using these items as list (which the happens repeatedly in Odoo), but more viciously when iterating *multiple times* over them (which also happens, which I've messed up multiple times while writing this, and which is a pain to debug even when you've just created the issue). Convert all code using these to semantics-matching cross-version helper functions to get the LCD behaviour between P2 and P3, and forbid the builtins via lint. issue #8530
2016-08-10[IMP] various: use odoo for imports instead of openerp and update class namesThibault Delavallée
2016-04-14[IMP] website_event, website_event_track, website_event_sale : prepare migrationJérome Maes
- change method decorator (api.one -> api.multi) for `_set_show_menu` and `_set_show_menu` - rename controller class
2015-02-19[ADD] website_event_questions: ask questions to event attendeesRichard Mathot
[IMP] event,event_sale,website_event_sale: refactoring to be more easily extended (code portions are courtesy of Thibault Delavallée <tde@odoo.com>)