Browse Source

May 30: [FIX] Bug Fixed 'odoo_website_helpdesk'

pull/334/merge
Cybrosys Technologies 2 months ago
parent
commit
d1b403be7c
  1. 2
      odoo_website_helpdesk/__manifest__.py
  2. 19
      odoo_website_helpdesk/controller/website.py
  3. 6
      odoo_website_helpdesk/doc/RELEASE_NOTES.md
  4. 4
      odoo_website_helpdesk/static/description/index.html

2
odoo_website_helpdesk/__manifest__.py

@ -21,7 +21,7 @@
############################################################################# #############################################################################
{ {
'name': "Website Helpdesk Support Ticket Management", 'name': "Website Helpdesk Support Ticket Management",
'version': '16.0.3.0.1', 'version': '16.0.3.0.2',
'category': 'Website', 'category': 'Website',
'summary': """Helpdesk Module for community""", 'summary': """Helpdesk Module for community""",
'description': 'Can create ticket from website also and can manage it from' 'description': 'Can create ticket from website also and can manage it from'

19
odoo_website_helpdesk/controller/website.py

@ -101,7 +101,6 @@ class WebsiteFormInherit(WebsiteForm):
'form_builder_model_model'] = model_record.model 'form_builder_model_model'] = model_record.model
request.session['form_builder_model'] = model_record.name request.session['form_builder_model'] = model_record.name
request.session['form_builder_id'] = ticket_id.id request.session['form_builder_id'] = ticket_id.id
return json.dumps({'id': ticket_id.id})
else: else:
rec_val = { rec_val = {
'customer_name': kwargs.get('customer_name'), 'customer_name': kwargs.get('customer_name'),
@ -137,7 +136,23 @@ class WebsiteFormInherit(WebsiteForm):
request.session['form_builder_model_model'] = model_record.model request.session['form_builder_model_model'] = model_record.model
request.session['form_builder_model'] = model_record.name request.session['form_builder_model'] = model_record.name
request.session['form_builder_id'] = ticket_id.id request.session['form_builder_id'] = ticket_id.id
return json.dumps({'id': ticket_id.id}) # Sent a confirmation mail upon Ticket creation
if ticket_id:
request.env['mail.mail'].sudo().create({
'subject': 'Your Ticket Has Been Created',
'body_html': f"<p>Hello {partner_create.name},</p><p>Your ticket <strong>{ticket_id.name}</strong> with the subject <strong>{ticket_id.subject}</strong> has been successfully submitted. Our support team will contact you soon.</p> <p>Thank You.</p>",
'email_to': partner_create.email,
'email_from': request.env.user.email or 'support@example.com',
}).send()
ticket_id.message_post(
body="A confirmation email regarding the ticket creation has been sent to the customer.",
subject="Ticket Confirmation Email",
message_type='email',
subtype_xmlid="mail.mt_comment",
)
return json.dumps({'id': ticket_id.id})
else: else:
model_record = request.env['ir.model'].sudo().search( model_record = request.env['ir.model'].sudo().search(
[('model', '=', model_name)]) [('model', '=', model_name)])

6
odoo_website_helpdesk/doc/RELEASE_NOTES.md

@ -9,3 +9,9 @@
#### Version 16.0.3.0.1 #### Version 16.0.3.0.1
#### UPDT #### UPDT
-A new contact record is created upon form submission. -A new contact record is created upon form submission.
#### 27.05.2025
#### Version 16.0.3.0.2
##### UPDT
-A confirmation email will be sent to the customer upon ticket creation.

4
odoo_website_helpdesk/static/description/index.html

@ -212,7 +212,11 @@ Create Tasks for the Project Linked to the Ticket </span>
class="img-thumbnail"><br/> class="img-thumbnail"><br/>
<h3 style="font-family: 'Montserrat', sans-serif; font-size: 18px; font-weight: bold;"> <h3 style="font-family: 'Montserrat', sans-serif; font-size: 18px; font-weight: bold;">
Get Confirmation/Success Message for Ticket Creation Get Confirmation/Success Message for Ticket Creation
</h3>
<h3 style="font-family: 'Montserrat', sans-serif; font-size: 18px; font-weight: bold;">
A confirmation email will be sent to the customer upon ticket creation.
</h3><br/> </h3><br/>
<img src="./assets/screenshots/Screenshot2.png" <img src="./assets/screenshots/Screenshot2.png"
class="img-thumbnail"> class="img-thumbnail">
</div> </div>

Loading…
Cancel
Save