Jump to content

  • You cannot start a new topic
  • You cannot reply to this topic

Custom Error Message With Product Options Rate Topic   - - - - -

 
  • Lianne-v-O
  • Advanced Member
  • Members
  • Join Date: 05-Oct 16
  • 66 posts

Posted 11 October 2016 - 10:40 AM #1

Hi there,

 

I would like to have a custom error message. My product options are required. It automaticly throws the "api_required_field" message. I can change the text of this message, but then the message would not be appropriate for the user missing fields anymore. So I would like to make my own message. Now I understand how to make a new error message. But how do I connect this message (language variable) to the right trigger? Where can I find the code what triggers the error-message, when clicked on the [order]-button and shown by the options?



 
  • eComLabs
  • CS-Cart Expert
  • Authorized Reseller
  • Join Date: 27-Jan 14
  • 19685 posts

Posted 11 October 2016 - 01:27 PM #2

It is not clear why your customers receive error message from CS-Cart API. Could you please provide us with more details about this issue?


GET A FREE QUOTE | CS-Cart Add-ons | CS-Cart Licenses | CS-Cart Development | CS-Cart Design | Server Configuration | UniTheme and YOUPI
CS-Cart                USD 345     Multi-Vendor              USD 1250    CS-Cart RU                         24500 руб.
CS-Cart Ultimate  USD 775     CS-Cart + YOUPI      USD 545      CS-Cart RU + UniTheme    36000 руб.


 
  • Lianne-v-O
  • Advanced Member
  • Members
  • Join Date: 05-Oct 16
  • 66 posts

Posted 11 October 2016 - 01:32 PM #3

It is not clear why your customers receive error message from CS-Cart API. Could you please provide us with more details about this issue?

 

I assume that when customers register, they get some fields to fill in and some are required. I think the same "api_required_field" message is used.

But I want to change the message when a customer wants to send a product with options to the cart, but didn't select any options yet, which are required in my case.



 
  • eComLabs
  • CS-Cart Expert
  • Authorized Reseller
  • Join Date: 27-Jan 14
  • 19685 posts

Posted 11 October 2016 - 01:42 PM #4

Looks like 3rd party module checks filled options. Am I correct?


GET A FREE QUOTE | CS-Cart Add-ons | CS-Cart Licenses | CS-Cart Development | CS-Cart Design | Server Configuration | UniTheme and YOUPI
CS-Cart                USD 345     Multi-Vendor              USD 1250    CS-Cart RU                         24500 руб.
CS-Cart Ultimate  USD 775     CS-Cart + YOUPI      USD 545      CS-Cart RU + UniTheme    36000 руб.


 
  • Lianne-v-O
  • Advanced Member
  • Members
  • Join Date: 05-Oct 16
  • 66 posts

Posted 11 October 2016 - 01:56 PM #5

Looks like 3rd party module checks filled options. Am I correct?

 

Not that I am aware of...

 

This is what I mean:

http://testserver-nu...-banner-bronze/

Click on [BESTEL]

 

Then an error-message is given where the options are. That is the error I want to customize (not just translate).



 
  • eComLabs
  • CS-Cart Expert
  • Authorized Reseller
  • Join Date: 27-Jan 14
  • 19685 posts

Posted 11 October 2016 - 02:25 PM #6

OK. Please check the js/tygh/core.js file by "cm-required"


GET A FREE QUOTE | CS-Cart Add-ons | CS-Cart Licenses | CS-Cart Development | CS-Cart Design | Server Configuration | UniTheme and YOUPI
CS-Cart                USD 345     Multi-Vendor              USD 1250    CS-Cart RU                         24500 руб.
CS-Cart Ultimate  USD 775     CS-Cart + YOUPI      USD 545      CS-Cart RU + UniTheme    36000 руб.