Bläddra i källkod

Making sure insertCell takes no argument for proper ordering of forms in formPortalNew

Andrej Studen 5 månader sedan
förälder
incheckning
3a8efc5d55
1 ändrade filer med 3 tillägg och 3 borttagningar
  1. 3 3
      web/crf/formPortalNew.js

+ 3 - 3
web/crf/formPortalNew.js

@@ -205,8 +205,8 @@ function(el,formList,roleAndSite,formId=null,idLabel=null,elError=null){
          deletedForms.push(entry);
          continue;
       }
+      let cell=row.insertCell();
       n+=1;
-      let cell=row.insertCell(i);
       crfHTML.addStyle(cell,'stretch');
 
       let fbox=crfHTML.createBox(null,cell);
@@ -240,7 +240,7 @@ function(el,formList,roleAndSite,formId=null,idLabel=null,elError=null){
    //should not be allowed to create new forms
    let regFormId=crfSetup.getSettings('registrationFormId');
    if (regFormId==formId) return table;
-   let cell=row.insertCell(n);
+   let cell=row.insertCell();
    crfHTML.addStyle(cell,'stretch');
    let fbox=crfHTML.createBox(null,cell);
    crfHTML.addStyle(fbox,'empty');
@@ -261,7 +261,7 @@ function(row,deletedForms){
       let stat=entry['FormStatus'];
       let formStatus=crfSetup.getMap('formStatus')[stat];
 
-      let cell=row.insertCell(i);
+      let cell=row.insertCell();
       crfHTML.addStyle(cell,'stretch');
 
       let fbox=crfHTML.createBox(null,cell);