backend-plus 1.18.8 → 1.18.10

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,9 @@ myOwn.TableGrid.prototype.prepareMenu = function prepareMenu(button){
1417
1417
  },
1418
1418
  showWithMiniMenu,
1419
1419
  messages,
1420
- grid
1420
+ grid,
1421
+ false,
1422
+ ['skipUnknownFieldsAtImport','simplificateSpaces','replaceNewLineWithSpace']
1421
1423
  )
1422
1424
  );
1423
1425
  }
@@ -1674,8 +1676,9 @@ myOwn.dialogDownload = function dialogDownload(grid){
1674
1676
  });
1675
1677
  };
1676
1678
 
1677
- myOwn.dialogUpload = function dialogUpload(ajaxPath, ajaxParams, ajaxPrepareResultFun, showWithMiniMenu, messages, refresheable, acceptPhotos){
1679
+ myOwn.dialogUpload = function dialogUpload(ajaxPath, ajaxParams, ajaxPrepareResultFun, showWithMiniMenu, messages, refresheable, acceptPhotos, optsNames){
1678
1680
  messages = changing(my.messages, messages||{})
1681
+ optsNames = optsNames || [];
1679
1682
  var doneFun = function doneFun(){
1680
1683
  var fileAttr={class:'import-button',type:'file',style:'min-width:400px'};
1681
1684
  if(acceptPhotos){
@@ -1683,11 +1686,15 @@ myOwn.dialogUpload = function dialogUpload(ajaxPath, ajaxParams, ajaxPrepareResu
1683
1686
  }
1684
1687
  var buttonFile=html.input(fileAttr).create();
1685
1688
  var buttonConfirmImport=html.input({class:'import-button',type:'button', value:messages.import}).create();
1689
+ buttonConfirmImport.disabled = true;
1686
1690
  var laodingIndicator=html.div({class:'indicator'},' ').create();
1687
1691
  var loadingBar=html.div({class:'progress-bar', style:'width:400px; height:8px;'},[laodingIndicator]).create();
1688
1692
  var divProgress=html.div({class:'result-progress', style:'width:400px; height:20px; margin:0px;'}).create();
1689
1693
  var progressIndicator=html.div({class:'indicator'},' ').create();
1690
1694
  var progressBar=html.div({class:'progress-bar', style:'width:400px; height:8px;'},[progressIndicator]).create();
1695
+ buttonFile.onchange = function(){
1696
+ buttonConfirmImport.disabled = false;
1697
+ }
1691
1698
  var displayProgressBar = function displayProgressBar(progress, progressIndicator){
1692
1699
  if(!progress){
1693
1700
  return;
@@ -1733,7 +1740,6 @@ myOwn.dialogUpload = function dialogUpload(ajaxPath, ajaxParams, ajaxPrepareResu
1733
1740
  }),{uploading:uploadingProgress, informProgress:informProgress}).then(eButton,eButton);
1734
1741
  }).then(ajaxPrepareResultFun).then(this.dialogPromiseDone,this.dialogPromiseDone);
1735
1742
  });
1736
- var optsNames = ['skipUnknownFieldsAtImport','simplificateSpaces','replaceNewLineWithSpace'];
1737
1743
  var buttons = {}
1738
1744
  optsNames.map((name, i)=>{
1739
1745
  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.10",
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
  },