backend-plus 1.18.8 → 1.18.9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1417,7 +1417,10 @@ myOwn.TableGrid.prototype.prepareMenu = function prepareMenu(button){
1417
1417
  },
1418
1418
  showWithMiniMenu,
1419
1419
  messages,
1420
- grid
1420
+ grid,
1421
+ false,
1422
+ false,
1423
+ ['skipUnknownFieldsAtImport','simplificateSpaces','replaceNewLineWithSpace']
1421
1424
  )
1422
1425
  );
1423
1426
  }
@@ -1674,8 +1677,9 @@ myOwn.dialogDownload = function dialogDownload(grid){
1674
1677
  });
1675
1678
  };
1676
1679
 
1677
- myOwn.dialogUpload = function dialogUpload(ajaxPath, ajaxParams, ajaxPrepareResultFun, showWithMiniMenu, messages, refresheable, acceptPhotos){
1680
+ myOwn.dialogUpload = function dialogUpload(ajaxPath, ajaxParams, ajaxPrepareResultFun, showWithMiniMenu, messages, refresheable, acceptPhotos, optsNames){
1678
1681
  messages = changing(my.messages, messages||{})
1682
+ optsNames = optsNames || [];
1679
1683
  var doneFun = function doneFun(){
1680
1684
  var fileAttr={class:'import-button',type:'file',style:'min-width:400px'};
1681
1685
  if(acceptPhotos){
@@ -1683,11 +1687,15 @@ myOwn.dialogUpload = function dialogUpload(ajaxPath, ajaxParams, ajaxPrepareResu
1683
1687
  }
1684
1688
  var buttonFile=html.input(fileAttr).create();
1685
1689
  var buttonConfirmImport=html.input({class:'import-button',type:'button', value:messages.import}).create();
1690
+ buttonConfirmImport.disabled = true;
1686
1691
  var laodingIndicator=html.div({class:'indicator'},' ').create();
1687
1692
  var loadingBar=html.div({class:'progress-bar', style:'width:400px; height:8px;'},[laodingIndicator]).create();
1688
1693
  var divProgress=html.div({class:'result-progress', style:'width:400px; height:20px; margin:0px;'}).create();
1689
1694
  var progressIndicator=html.div({class:'indicator'},' ').create();
1690
1695
  var progressBar=html.div({class:'progress-bar', style:'width:400px; height:8px;'},[progressIndicator]).create();
1696
+ buttonFile.onchange = function(){
1697
+ buttonConfirmImport.disabled = false;
1698
+ }
1691
1699
  var displayProgressBar = function displayProgressBar(progress, progressIndicator){
1692
1700
  if(!progress){
1693
1701
  return;
@@ -1733,7 +1741,6 @@ myOwn.dialogUpload = function dialogUpload(ajaxPath, ajaxParams, ajaxPrepareResu
1733
1741
  }),{uploading:uploadingProgress, informProgress:informProgress}).then(eButton,eButton);
1734
1742
  }).then(ajaxPrepareResultFun).then(this.dialogPromiseDone,this.dialogPromiseDone);
1735
1743
  });
1736
- var optsNames = ['skipUnknownFieldsAtImport','simplificateSpaces','replaceNewLineWithSpace'];
1737
1744
  var buttons = {}
1738
1745
  optsNames.map((name, i)=>{
1739
1746
  var defValue = !!i;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "backend-plus",
3
3
  "description": "Backend for typed controls",
4
- "version": "1.18.8",
4
+ "version": "1.18.9",
5
5
  "author": "Codenautas <codenautas@googlegroups.com>",
6
6
  "license": "MIT",
7
7
  "repository": "codenautas/backend-plus",
@@ -81,8 +81,8 @@
81
81
  "@types/js-yaml": "^4.0.5",
82
82
  "@types/mocha": "^10.0.1",
83
83
  "@types/multiparty": "~0.0.33",
84
- "@types/node": "^20.1.4",
85
- "@types/nodemailer": "^6.4.7",
84
+ "@types/node": "^20.2.3",
85
+ "@types/nodemailer": "^6.4.8",
86
86
  "@types/numeral": "~2.0.2",
87
87
  "@types/session-file-store": "^1.2.2",
88
88
  "@types/stack-trace": "~0.0.30",
@@ -98,10 +98,10 @@
98
98
  "kill-9": "~0.4.3",
99
99
  "mocha": "^10.2.0",
100
100
  "nyc": "^15.1.0",
101
- "puppeteer": "^20.2.0",
102
- "sinon": "^15.0.4",
101
+ "puppeteer": "^20.2.1",
102
+ "sinon": "^15.1.0",
103
103
  "supertest": "^6.3.3",
104
- "types.d.ts": "~0.6.13",
104
+ "types.d.ts": "~0.6.14",
105
105
  "typescript": "^5.0.4",
106
106
  "why-is-node-running": "^2.2.2"
107
107
  },