webERP Forum

Full Version: MiscFunctions.update1 Function Killing IE 11 - SOLVED
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
javascripts\MiscFunctions.js

All scripts directly from GIT for testing.

PHP Code:
function update1(s) {
    var 
ss=s.split(';');
    var 
sss=ss.map((a)=>document.getElementById(a).value);
    var 
ttl sss.reduce((a,b)=>parseFloat(a)+parseFloat(b)); 
    
document.getElementById('ttl').value ttl;


The second line of code in this function kills the Date Picker and new dismissible notifications (and other things?) in IE 11.

If I comment out the second two lines in this function the Date Picker works as expected.

Any ideas on this one
Okay... So JavaScript "Arrow" functions are not supported in IE 11.

The code bellow has sorted out the issue for this implementation.

PHP Code:
function update1(s) {
    var 
ss=s.split(';');
    var 
sss=ss.map(function(a){return document.getElementById(a).value;});
    var 
ttl sss.reduce(function(a,b){return parseFloat(a)+parseFloat(b)});
    
document.getElementById('ttl').value ttl;

BUMP...

Anybody else running webERP on Windoze with IE 11 seeing this issue?

This is only a test env for me so not any sort of big issue... I am just curious...
I'm afraid I can't help, haven't owned a windows box in over 20 years. Even my wife's laptop runs Linux Big Grin

Tim
I hear that. All our stuff is Linux (ClearOS and/or Mint) except for my dev boxes. All my customers use Windoze and most all of my dev work is VBScript, VBA, VB6, and VB.NET so I am forced to have one workstation and a dual-boot laptop to service them.

However, MS-based work does produce recurring revenue so I am very happy for that...
Yeah, good find, Paul.

True, it appears, that IE11 is lacking ECMA6 javascript things, according to this matrix. Search the page for 'arrow functions', then see the column to IE11.

Perhaps to those with Windows, this announcement might be good news.