I’ve upgraded from the SugarCRM 6.5 CE edition, but now I notice there are some issues when creating invoices/creating quotes (I was already running the AOS Quotes/invoices module on the CE edition.)
I now notice two things when I try to create an invoice:
When trying to add a service/product line I now need to press Add group first. There is a second Line items field, but it’s just blank.
TypeError: document.getElementById(…) is null
Whick points to this line (line 625, in function unformatNumber in Quote.js):
var grp_sep = String(document.getElementById(‘grp_seperator’).value);
So it seems as if it’s looking for a hidden element which contains the group seperator (next line is looking for the decimal seperator) and it’s not there.
Can you take a look at this and/or point me in the right direction?
For your first issue, navigate to Admin -> AOS Settings and you can disable groups there.
For your second issue, navigate to Admin -> System Settings -> Configure AJAX User Interface and drag the “Quotes” module from enabled to disabled, then save.
Removing the groups worked, thanks!
About the other issue (totals): I should have mentioned I’d tried that already (noticed it in another topic on this forum).
It’s still giving me the same error, in the same Quote.js file.
Any other ideas?
sounds like it could be a caching issue on the js file, try clearing you browser cache and doing a quick repair and rebuild or sticking on developer mode and see if you still get the same issue
That wasn’t the problem either (Repair/rebuild didn’t help and I was already in developer mode), however I got it working now by commenting out these lines:
// var grp_sep = String(document.getElementById(‘grp_seperator’).value);
// var dec_sep = String(document.getElementById(‘dec_seperator’).value);
and adding this one:
var grp_sep = num_grp_sep (I noticed num_grp_sep and dec_sep are defined upon page load, so don’t know why it’s being fetched from the DOM everytime this function is called.)
I just hope changing this won’t brick anything else
Thanks for checking!
quotes.js is deprecated, it should have been removed on upgrade,
the new js file ‘modules/AOS_Products_Quotes/line_items.js’ does use ‘num_grp_sep’ by default
So what do you propose…I delete/rename the Quote.js file?
Mind you, I did not receive any notifications during the upgrade, no errors were given.