@saltcorn/server 0.6.2-beta.0 → 0.6.2-beta.4
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.
- package/app.js +9 -13
- package/auth/admin.js +8 -24
- package/auth/roleadmin.js +6 -16
- package/auth/routes.js +113 -59
- package/locales/en.json +30 -1
- package/markup/admin.js +17 -0
- package/package.json +15 -8
- package/public/ckeditor/adapters/jquery.js +10 -0
- package/public/ckeditor/ckeditor.js +1286 -0
- package/public/ckeditor/config.js +38 -0
- package/public/ckeditor/contents.css +208 -0
- package/public/ckeditor/lang/af.js +5 -0
- package/public/ckeditor/lang/ar.js +5 -0
- package/public/ckeditor/lang/az.js +5 -0
- package/public/ckeditor/lang/bg.js +5 -0
- package/public/ckeditor/lang/bn.js +5 -0
- package/public/ckeditor/lang/bs.js +5 -0
- package/public/ckeditor/lang/ca.js +5 -0
- package/public/ckeditor/lang/cs.js +5 -0
- package/public/ckeditor/lang/cy.js +5 -0
- package/public/ckeditor/lang/da.js +5 -0
- package/public/ckeditor/lang/de-ch.js +5 -0
- package/public/ckeditor/lang/de.js +5 -0
- package/public/ckeditor/lang/el.js +5 -0
- package/public/ckeditor/lang/en-au.js +5 -0
- package/public/ckeditor/lang/en-ca.js +5 -0
- package/public/ckeditor/lang/en-gb.js +5 -0
- package/public/ckeditor/lang/en.js +5 -0
- package/public/ckeditor/lang/eo.js +5 -0
- package/public/ckeditor/lang/es-mx.js +5 -0
- package/public/ckeditor/lang/es.js +5 -0
- package/public/ckeditor/lang/et.js +5 -0
- package/public/ckeditor/lang/eu.js +5 -0
- package/public/ckeditor/lang/fa.js +5 -0
- package/public/ckeditor/lang/fi.js +5 -0
- package/public/ckeditor/lang/fo.js +5 -0
- package/public/ckeditor/lang/fr-ca.js +5 -0
- package/public/ckeditor/lang/fr.js +5 -0
- package/public/ckeditor/lang/gl.js +5 -0
- package/public/ckeditor/lang/gu.js +5 -0
- package/public/ckeditor/lang/he.js +5 -0
- package/public/ckeditor/lang/hi.js +5 -0
- package/public/ckeditor/lang/hr.js +5 -0
- package/public/ckeditor/lang/hu.js +5 -0
- package/public/ckeditor/lang/id.js +5 -0
- package/public/ckeditor/lang/is.js +5 -0
- package/public/ckeditor/lang/it.js +5 -0
- package/public/ckeditor/lang/ja.js +5 -0
- package/public/ckeditor/lang/ka.js +5 -0
- package/public/ckeditor/lang/km.js +5 -0
- package/public/ckeditor/lang/ko.js +5 -0
- package/public/ckeditor/lang/ku.js +5 -0
- package/public/ckeditor/lang/lt.js +5 -0
- package/public/ckeditor/lang/lv.js +5 -0
- package/public/ckeditor/lang/mk.js +5 -0
- package/public/ckeditor/lang/mn.js +5 -0
- package/public/ckeditor/lang/ms.js +5 -0
- package/public/ckeditor/lang/nb.js +5 -0
- package/public/ckeditor/lang/nl.js +5 -0
- package/public/ckeditor/lang/no.js +5 -0
- package/public/ckeditor/lang/oc.js +5 -0
- package/public/ckeditor/lang/pl.js +5 -0
- package/public/ckeditor/lang/pt-br.js +5 -0
- package/public/ckeditor/lang/pt.js +5 -0
- package/public/ckeditor/lang/ro.js +5 -0
- package/public/ckeditor/lang/ru.js +5 -0
- package/public/ckeditor/lang/si.js +5 -0
- package/public/ckeditor/lang/sk.js +5 -0
- package/public/ckeditor/lang/sl.js +5 -0
- package/public/ckeditor/lang/sq.js +5 -0
- package/public/ckeditor/lang/sr-latn.js +5 -0
- package/public/ckeditor/lang/sr.js +5 -0
- package/public/ckeditor/lang/sv.js +5 -0
- package/public/ckeditor/lang/th.js +5 -0
- package/public/ckeditor/lang/tr.js +5 -0
- package/public/ckeditor/lang/tt.js +5 -0
- package/public/ckeditor/lang/ug.js +5 -0
- package/public/ckeditor/lang/uk.js +5 -0
- package/public/ckeditor/lang/vi.js +5 -0
- package/public/ckeditor/lang/zh-cn.js +5 -0
- package/public/ckeditor/lang/zh.js +5 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/a11yhelp.js +10 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/_translationstatus.txt +25 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/af.js +11 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/ar.js +11 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/az.js +11 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/bg.js +11 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/ca.js +13 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/cs.js +12 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/cy.js +11 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/da.js +11 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/de-ch.js +13 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/de.js +13 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/el.js +13 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/en-au.js +11 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/en-gb.js +11 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/en.js +11 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/eo.js +13 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/es-mx.js +13 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/es.js +13 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/et.js +11 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/eu.js +12 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/fa.js +11 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/fi.js +11 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/fo.js +11 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/fr-ca.js +11 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/fr.js +13 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/gl.js +12 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/gu.js +11 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/he.js +11 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/hi.js +11 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/hr.js +11 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/hu.js +12 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/id.js +11 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/it.js +13 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/ja.js +9 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/km.js +11 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/ko.js +10 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/ku.js +11 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/lt.js +11 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/lv.js +12 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/mk.js +11 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/mn.js +11 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/nb.js +12 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/nl.js +12 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/no.js +11 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/oc.js +12 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/pl.js +13 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/pt-br.js +13 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/pt.js +12 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/ro.js +12 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/ru.js +11 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/si.js +10 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/sk.js +11 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/sl.js +11 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/sq.js +12 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/sr-latn.js +12 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/sr.js +12 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/sv.js +11 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/th.js +11 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/tr.js +12 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/tt.js +11 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/ug.js +12 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/uk.js +12 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/vi.js +11 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/zh-cn.js +9 -0
- package/public/ckeditor/plugins/a11yhelp/dialogs/lang/zh.js +9 -0
- package/public/ckeditor/plugins/about/dialogs/about.js +8 -0
- package/public/ckeditor/plugins/about/dialogs/hidpi/logo_ckeditor.png +0 -0
- package/public/ckeditor/plugins/about/dialogs/logo_ckeditor.png +0 -0
- package/public/ckeditor/plugins/clipboard/dialogs/paste.js +11 -0
- package/public/ckeditor/plugins/dialog/dialogDefinition.js +4 -0
- package/public/ckeditor/plugins/dialog/styles/dialog.css +18 -0
- package/public/ckeditor/plugins/icons.png +0 -0
- package/public/ckeditor/plugins/icons_hidpi.png +0 -0
- package/public/ckeditor/plugins/image/dialogs/image.js +44 -0
- package/public/ckeditor/plugins/image/images/noimage.png +0 -0
- package/public/ckeditor/plugins/link/dialogs/anchor.js +8 -0
- package/public/ckeditor/plugins/link/dialogs/link.js +30 -0
- package/public/ckeditor/plugins/link/images/anchor.png +0 -0
- package/public/ckeditor/plugins/link/images/hidpi/anchor.png +0 -0
- package/public/ckeditor/plugins/magicline/images/hidpi/icon-rtl.png +0 -0
- package/public/ckeditor/plugins/magicline/images/hidpi/icon.png +0 -0
- package/public/ckeditor/plugins/magicline/images/icon-rtl.png +0 -0
- package/public/ckeditor/plugins/magicline/images/icon.png +0 -0
- package/public/ckeditor/plugins/pastefromgdocs/filter/default.js +8 -0
- package/public/ckeditor/plugins/pastefromlibreoffice/filter/default.js +11 -0
- package/public/ckeditor/plugins/pastefromword/filter/default.js +42 -0
- package/public/ckeditor/plugins/pastetools/filter/common.js +24 -0
- package/public/ckeditor/plugins/pastetools/filter/image.js +12 -0
- package/public/ckeditor/plugins/scayt/CHANGELOG.md +4 -0
- package/public/ckeditor/plugins/scayt/LICENSE.md +28 -0
- package/public/ckeditor/plugins/scayt/README.md +81 -0
- package/public/ckeditor/plugins/scayt/dialogs/dialog.css +23 -0
- package/public/ckeditor/plugins/scayt/dialogs/options.js +32 -0
- package/public/ckeditor/plugins/scayt/dialogs/toolbar.css +71 -0
- package/public/ckeditor/plugins/scayt/skins/moono-lisa/scayt.css +25 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/_translationstatus.txt +20 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/af.js +13 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/ar.js +13 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/az.js +10 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/bg.js +13 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/ca.js +14 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/cs.js +13 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/cy.js +14 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/da.js +11 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/de-ch.js +13 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/de.js +13 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/el.js +13 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/en-au.js +13 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/en-ca.js +13 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/en-gb.js +13 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/en.js +13 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/eo.js +12 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/es-mx.js +13 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/es.js +13 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/et.js +11 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/eu.js +13 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/fa.js +12 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/fi.js +13 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/fr-ca.js +10 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/fr.js +12 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/gl.js +13 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/he.js +12 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/hr.js +13 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/hu.js +12 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/id.js +13 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/it.js +14 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/ja.js +9 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/km.js +13 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/ko.js +10 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/ku.js +13 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/lt.js +13 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/lv.js +13 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/nb.js +11 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/nl.js +13 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/no.js +11 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/oc.js +12 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/pl.js +12 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/pt-br.js +11 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/pt.js +13 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/ro.js +13 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/ru.js +13 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/si.js +13 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/sk.js +13 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/sl.js +12 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/sq.js +13 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/sr-latn.js +13 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/sr.js +13 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/sv.js +11 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/th.js +13 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/tr.js +12 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/tt.js +13 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/ug.js +13 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/uk.js +12 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/vi.js +14 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/zh-cn.js +9 -0
- package/public/ckeditor/plugins/specialchar/dialogs/lang/zh.js +9 -0
- package/public/ckeditor/plugins/specialchar/dialogs/specialchar.js +14 -0
- package/public/ckeditor/plugins/table/dialogs/table.js +22 -0
- package/public/ckeditor/plugins/tableselection/styles/tableselection.css +36 -0
- package/public/ckeditor/plugins/tabletools/dialogs/tableCell.js +18 -0
- package/public/ckeditor/plugins/widget/images/handle.png +0 -0
- package/public/ckeditor/plugins/wsc/LICENSE.md +28 -0
- package/public/ckeditor/plugins/wsc/README.md +84 -0
- package/public/ckeditor/plugins/wsc/dialogs/ciframe.html +66 -0
- package/public/ckeditor/plugins/wsc/dialogs/tmpFrameset.html +52 -0
- package/public/ckeditor/plugins/wsc/dialogs/wsc.css +82 -0
- package/public/ckeditor/plugins/wsc/dialogs/wsc.js +90 -0
- package/public/ckeditor/plugins/wsc/dialogs/wsc_ie.js +11 -0
- package/public/ckeditor/plugins/wsc/icons/hidpi/spellchecker.png +0 -0
- package/public/ckeditor/plugins/wsc/icons/spellchecker.png +0 -0
- package/public/ckeditor/plugins/wsc/lang/af.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/ar.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/bg.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/bn.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/bs.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/ca.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/cs.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/cy.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/da.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/de.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/el.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/en-au.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/en-ca.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/en-gb.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/en.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/eo.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/es.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/et.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/eu.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/fa.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/fi.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/fo.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/fr-ca.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/fr.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/gl.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/gu.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/he.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/hi.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/hr.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/hu.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/is.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/it.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/ja.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/ka.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/km.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/ko.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/ku.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/lt.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/lv.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/mk.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/mn.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/ms.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/nb.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/nl.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/no.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/pl.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/pt-br.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/pt.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/ro.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/ru.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/sk.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/sl.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/sr-latn.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/sr.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/sv.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/th.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/tr.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/ug.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/uk.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/vi.js +2 -0
- package/public/ckeditor/plugins/wsc/lang/zh-cn.js +1 -0
- package/public/ckeditor/plugins/wsc/lang/zh.js +1 -0
- package/public/ckeditor/plugins/wsc/plugin.js +5 -0
- package/public/ckeditor/plugins/wsc/skins/moono-lisa/wsc.css +43 -0
- package/public/ckeditor/skins/moono-lisa/dialog.css +5 -0
- package/public/ckeditor/skins/moono-lisa/dialog_ie.css +5 -0
- package/public/ckeditor/skins/moono-lisa/dialog_ie8.css +5 -0
- package/public/ckeditor/skins/moono-lisa/dialog_iequirks.css +5 -0
- package/public/ckeditor/skins/moono-lisa/editor.css +5 -0
- package/public/ckeditor/skins/moono-lisa/editor_gecko.css +5 -0
- package/public/ckeditor/skins/moono-lisa/editor_ie.css +5 -0
- package/public/ckeditor/skins/moono-lisa/editor_ie8.css +5 -0
- package/public/ckeditor/skins/moono-lisa/editor_iequirks.css +5 -0
- package/public/ckeditor/skins/moono-lisa/icons.png +0 -0
- package/public/ckeditor/skins/moono-lisa/icons_hidpi.png +0 -0
- package/public/ckeditor/skins/moono-lisa/images/arrow.png +0 -0
- package/public/ckeditor/skins/moono-lisa/images/close.png +0 -0
- package/public/ckeditor/skins/moono-lisa/images/hidpi/close.png +0 -0
- package/public/ckeditor/skins/moono-lisa/images/hidpi/lock-open.png +0 -0
- package/public/ckeditor/skins/moono-lisa/images/hidpi/lock.png +0 -0
- package/public/ckeditor/skins/moono-lisa/images/hidpi/refresh.png +0 -0
- package/public/ckeditor/skins/moono-lisa/images/lock-open.png +0 -0
- package/public/ckeditor/skins/moono-lisa/images/lock.png +0 -0
- package/public/ckeditor/skins/moono-lisa/images/refresh.png +0 -0
- package/public/ckeditor/skins/moono-lisa/images/spinner.gif +0 -0
- package/public/ckeditor/skins/moono-lisa/readme.md +46 -0
- package/public/ckeditor/styles.js +137 -0
- package/public/ckeditor/vendor/promise.js +13 -0
- package/public/saltcorn.css +20 -3
- package/public/saltcorn.js +3 -0
- package/restart_watcher.js +12 -2
- package/routes/actions.js +1 -15
- package/routes/admin.js +6 -23
- package/routes/api.js +51 -60
- package/routes/config.js +0 -1
- package/routes/crashlog.js +1 -4
- package/routes/delete.js +1 -2
- package/routes/edit.js +1 -2
- package/routes/eventlog.js +2 -15
- package/routes/events.js +0 -1
- package/routes/fields.js +1 -9
- package/routes/files.js +144 -64
- package/routes/homepage.js +8 -2
- package/routes/infoarch.js +12 -19
- package/routes/library.js +1 -4
- package/routes/list.js +50 -6
- package/routes/menu.js +118 -32
- package/routes/packs.js +2 -8
- package/routes/page.js +7 -8
- package/routes/pageedit.js +18 -30
- package/routes/plugins.js +21 -34
- package/routes/scapi.js +155 -184
- package/routes/search.js +6 -10
- package/routes/settings.js +1 -2
- package/routes/tables.js +1 -22
- package/routes/tenant.js +1 -9
- package/routes/utils.js +19 -19
- package/routes/view.js +7 -5
- package/routes/viewedit.js +18 -29
- package/s3storage.js +167 -0
- package/tests/admin.test.js +4 -2
- package/wrapper.js +8 -1
package/routes/api.js
CHANGED
|
@@ -16,7 +16,7 @@
|
|
|
16
16
|
/** @type {module:express-promise-router} */
|
|
17
17
|
const Router = require("express-promise-router");
|
|
18
18
|
//const db = require("@saltcorn/data/db");
|
|
19
|
-
const {
|
|
19
|
+
const { error_catcher } = require("./utils.js");
|
|
20
20
|
//const { mkTable, renderForm, link, post_btn } = require("@saltcorn/markup");
|
|
21
21
|
const { getState } = require("@saltcorn/data/db/state");
|
|
22
22
|
const Table = require("@saltcorn/data/models/table");
|
|
@@ -41,7 +41,7 @@ const router = new Router();
|
|
|
41
41
|
module.exports = router;
|
|
42
42
|
|
|
43
43
|
/**
|
|
44
|
-
* @param {*} fields
|
|
44
|
+
* @param {*} fields
|
|
45
45
|
* @returns {*}
|
|
46
46
|
*/
|
|
47
47
|
const limitFields = (fields) => (r) => {
|
|
@@ -64,14 +64,14 @@ const limitFields = (fields) => (r) => {
|
|
|
64
64
|
* @param {Table} table
|
|
65
65
|
* @returns {boolean}
|
|
66
66
|
*/
|
|
67
|
-
function accessAllowedRead(req, user, table){
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
67
|
+
function accessAllowedRead(req, user, table) {
|
|
68
|
+
const role = req.isAuthenticated()
|
|
69
|
+
? req.user.role_id
|
|
70
|
+
: user && user.role_id
|
|
71
|
+
? user.role_id
|
|
72
|
+
: 10;
|
|
73
73
|
|
|
74
|
-
|
|
74
|
+
return role <= table.min_role_read;
|
|
75
75
|
}
|
|
76
76
|
|
|
77
77
|
/**
|
|
@@ -81,15 +81,14 @@ function accessAllowedRead(req, user, table){
|
|
|
81
81
|
* @param {Table} table
|
|
82
82
|
* @returns {boolean}
|
|
83
83
|
*/
|
|
84
|
-
function accessAllowedWrite(req, user, table){
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
return role <= table.min_role_write;
|
|
84
|
+
function accessAllowedWrite(req, user, table) {
|
|
85
|
+
const role = req.isAuthenticated()
|
|
86
|
+
? req.user.role_id
|
|
87
|
+
: user && user.role_id
|
|
88
|
+
? user.role_id
|
|
89
|
+
: 10;
|
|
92
90
|
|
|
91
|
+
return role <= table.min_role_write;
|
|
93
92
|
}
|
|
94
93
|
/**
|
|
95
94
|
* Check that user has right to trigger call
|
|
@@ -98,14 +97,14 @@ function accessAllowedWrite(req, user, table){
|
|
|
98
97
|
* @param {Trigger} trigger
|
|
99
98
|
* @returns {boolean}
|
|
100
99
|
*/
|
|
101
|
-
function accessAllowed(req, user, trigger){
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
100
|
+
function accessAllowed(req, user, trigger) {
|
|
101
|
+
const role = req.isAuthenticated()
|
|
102
|
+
? req.user.role_id
|
|
103
|
+
: user && user.role_id
|
|
104
|
+
? user.role_id
|
|
105
|
+
: 10;
|
|
107
106
|
|
|
108
|
-
|
|
107
|
+
return role <= trigger.min_role;
|
|
109
108
|
}
|
|
110
109
|
|
|
111
110
|
/**
|
|
@@ -117,7 +116,6 @@ function accessAllowed(req, user, trigger){
|
|
|
117
116
|
// todo add paging
|
|
118
117
|
router.get(
|
|
119
118
|
"/:tableName/",
|
|
120
|
-
setTenant,
|
|
121
119
|
//passport.authenticate("api-bearer", { session: false }),
|
|
122
120
|
error_catcher(async (req, res, next) => {
|
|
123
121
|
const { tableName } = req.params;
|
|
@@ -176,7 +174,6 @@ router.get(
|
|
|
176
174
|
*/
|
|
177
175
|
router.post(
|
|
178
176
|
"/action/:actionname/",
|
|
179
|
-
setTenant,
|
|
180
177
|
error_catcher(async (req, res, next) => {
|
|
181
178
|
const { actionname } = req.params;
|
|
182
179
|
// todo protect action by authorization check
|
|
@@ -189,30 +186,30 @@ router.post(
|
|
|
189
186
|
when_trigger: "API call",
|
|
190
187
|
});
|
|
191
188
|
|
|
192
|
-
if (!trigger){
|
|
193
|
-
|
|
194
|
-
|
|
189
|
+
if (!trigger) {
|
|
190
|
+
res.status(400).json({ error: req.__("Not found") });
|
|
191
|
+
return;
|
|
195
192
|
}
|
|
196
193
|
await passport.authenticate(
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
}
|
|
194
|
+
"api-bearer",
|
|
195
|
+
{ session: false },
|
|
196
|
+
async function (err, user, info) {
|
|
197
|
+
if (accessAllowed(req, user, trigger)) {
|
|
198
|
+
try {
|
|
199
|
+
const action = getState().actions[trigger.action];
|
|
200
|
+
const resp = await action.run({
|
|
201
|
+
configuration: trigger.configuration,
|
|
202
|
+
body: req.body,
|
|
203
|
+
req,
|
|
204
|
+
});
|
|
205
|
+
res.json({ success: true, data: resp });
|
|
206
|
+
} catch (e) {
|
|
207
|
+
res.status(400).json({ success: false, error: e.message });
|
|
208
|
+
}
|
|
209
|
+
} else {
|
|
210
|
+
res.status(401).json({ error: req.__("Not authorized") });
|
|
215
211
|
}
|
|
212
|
+
}
|
|
216
213
|
)(req, res, next);
|
|
217
214
|
})
|
|
218
215
|
);
|
|
@@ -225,7 +222,6 @@ router.post(
|
|
|
225
222
|
*/
|
|
226
223
|
router.post(
|
|
227
224
|
"/:tableName/",
|
|
228
|
-
setTenant,
|
|
229
225
|
error_catcher(async (req, res, next) => {
|
|
230
226
|
const { tableName } = req.params;
|
|
231
227
|
const table = await Table.findOne({ name: tableName });
|
|
@@ -294,7 +290,6 @@ router.post(
|
|
|
294
290
|
*/
|
|
295
291
|
router.post(
|
|
296
292
|
"/:tableName/:id",
|
|
297
|
-
setTenant,
|
|
298
293
|
error_catcher(async (req, res, next) => {
|
|
299
294
|
const { tableName, id } = req.params;
|
|
300
295
|
const table = await Table.findOne({ name: tableName });
|
|
@@ -355,7 +350,6 @@ router.post(
|
|
|
355
350
|
router.delete(
|
|
356
351
|
"/:tableName/:id",
|
|
357
352
|
// in case of primary key different from id - id will be string "undefined"
|
|
358
|
-
setTenant,
|
|
359
353
|
error_catcher(async (req, res, next) => {
|
|
360
354
|
const { tableName, id } = req.params;
|
|
361
355
|
const table = await Table.findOne({ name: tableName });
|
|
@@ -368,17 +362,14 @@ router.delete(
|
|
|
368
362
|
{ session: false },
|
|
369
363
|
async function (err, user, info) {
|
|
370
364
|
if (accessAllowedWrite(req, user, table)) {
|
|
371
|
-
|
|
372
365
|
try {
|
|
373
|
-
if(id === "undefined"){
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
}
|
|
380
|
-
else
|
|
381
|
-
await table.deleteRows({ id });
|
|
366
|
+
if (id === "undefined") {
|
|
367
|
+
const pk_name = table.pk_name;
|
|
368
|
+
//const fields = await table.getFields();
|
|
369
|
+
const row = req.body;
|
|
370
|
+
//readState(row, fields);
|
|
371
|
+
await table.deleteRows({ [pk_name]: row[pk_name] });
|
|
372
|
+
} else await table.deleteRows({ id });
|
|
382
373
|
res.json({ success: true });
|
|
383
374
|
} catch (e) {
|
|
384
375
|
res.status(400).json({ error: e.message });
|
package/routes/config.js
CHANGED
package/routes/crashlog.js
CHANGED
|
@@ -20,7 +20,7 @@ const {
|
|
|
20
20
|
p,
|
|
21
21
|
} = require("@saltcorn/markup/tags");
|
|
22
22
|
|
|
23
|
-
const {
|
|
23
|
+
const { isAdmin, error_catcher } = require("./utils.js");
|
|
24
24
|
const { send_events_page } = require("../markup/admin.js");
|
|
25
25
|
|
|
26
26
|
/**
|
|
@@ -41,7 +41,6 @@ module.exports = router;
|
|
|
41
41
|
*/
|
|
42
42
|
router.get(
|
|
43
43
|
"/",
|
|
44
|
-
setTenant,
|
|
45
44
|
isAdmin,
|
|
46
45
|
error_catcher(async (req, res) => {
|
|
47
46
|
const state = req.query,
|
|
@@ -103,7 +102,6 @@ router.get(
|
|
|
103
102
|
*/
|
|
104
103
|
router.post(
|
|
105
104
|
"/",
|
|
106
|
-
setTenant,
|
|
107
105
|
isAdmin,
|
|
108
106
|
error_catcher(async (req, res) => {
|
|
109
107
|
const err = {
|
|
@@ -123,7 +121,6 @@ router.post(
|
|
|
123
121
|
*/
|
|
124
122
|
router.get(
|
|
125
123
|
"/:id",
|
|
126
|
-
setTenant,
|
|
127
124
|
isAdmin,
|
|
128
125
|
error_catcher(async (req, res) => {
|
|
129
126
|
const { id } = req.params;
|
package/routes/delete.js
CHANGED
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
|
|
7
7
|
const Router = require("express-promise-router");
|
|
8
8
|
|
|
9
|
-
const {
|
|
9
|
+
const { loggedIn, error_catcher } = require("./utils.js");
|
|
10
10
|
const Table = require("@saltcorn/data/models/table");
|
|
11
11
|
|
|
12
12
|
/**
|
|
@@ -29,7 +29,6 @@ module.exports = router;
|
|
|
29
29
|
*/
|
|
30
30
|
router.post(
|
|
31
31
|
"/:name/:id",
|
|
32
|
-
setTenant,
|
|
33
32
|
error_catcher(async (req, res) => {
|
|
34
33
|
const { name, id } = req.params;
|
|
35
34
|
const { redirect } = req.query;
|
package/routes/edit.js
CHANGED
|
@@ -9,7 +9,7 @@ const Router = require("express-promise-router");
|
|
|
9
9
|
const Field = require("@saltcorn/data/models/field");
|
|
10
10
|
const File = require("@saltcorn/data/models/file");
|
|
11
11
|
const Form = require("@saltcorn/data/models/form");
|
|
12
|
-
const {
|
|
12
|
+
const { loggedIn, error_catcher } = require("./utils.js");
|
|
13
13
|
const Table = require("@saltcorn/data/models/table");
|
|
14
14
|
const pluralize = require("pluralize");
|
|
15
15
|
|
|
@@ -33,7 +33,6 @@ module.exports = router;
|
|
|
33
33
|
*/
|
|
34
34
|
router.post(
|
|
35
35
|
"/toggle/:name/:id/:field_name",
|
|
36
|
-
setTenant,
|
|
37
36
|
error_catcher(async (req, res) => {
|
|
38
37
|
const { name, id, field_name } = req.params;
|
|
39
38
|
const { redirect } = req.query;
|
package/routes/eventlog.js
CHANGED
|
@@ -5,12 +5,7 @@
|
|
|
5
5
|
* @subcategory routes
|
|
6
6
|
*/
|
|
7
7
|
const Router = require("express-promise-router");
|
|
8
|
-
const {
|
|
9
|
-
isAdmin,
|
|
10
|
-
setTenant,
|
|
11
|
-
error_catcher,
|
|
12
|
-
get_base_url,
|
|
13
|
-
} = require("./utils.js");
|
|
8
|
+
const { isAdmin, error_catcher, get_base_url } = require("./utils.js");
|
|
14
9
|
const { getState } = require("@saltcorn/data/db/state");
|
|
15
10
|
const Trigger = require("@saltcorn/data/models/trigger");
|
|
16
11
|
|
|
@@ -52,7 +47,7 @@ const { send_events_page } = require("../markup/admin.js");
|
|
|
52
47
|
const EventLog = require("@saltcorn/data/models/eventlog");
|
|
53
48
|
|
|
54
49
|
/**
|
|
55
|
-
* @param {object} req
|
|
50
|
+
* @param {object} req
|
|
56
51
|
* @returns {Promise<Form>}
|
|
57
52
|
*/
|
|
58
53
|
const logSettingsForm = async (req) => {
|
|
@@ -101,7 +96,6 @@ const logSettingsForm = async (req) => {
|
|
|
101
96
|
*/
|
|
102
97
|
router.get(
|
|
103
98
|
"/settings",
|
|
104
|
-
setTenant,
|
|
105
99
|
isAdmin,
|
|
106
100
|
error_catcher(async (req, res) => {
|
|
107
101
|
const form = await logSettingsForm(req);
|
|
@@ -128,7 +122,6 @@ router.get(
|
|
|
128
122
|
*/
|
|
129
123
|
router.get(
|
|
130
124
|
"/custom",
|
|
131
|
-
setTenant,
|
|
132
125
|
isAdmin,
|
|
133
126
|
error_catcher(async (req, res) => {
|
|
134
127
|
const cevs = getState().getConfig("custom_events", []);
|
|
@@ -202,7 +195,6 @@ const customEventForm = () =>
|
|
|
202
195
|
*/
|
|
203
196
|
router.get(
|
|
204
197
|
"/custom/new",
|
|
205
|
-
setTenant,
|
|
206
198
|
isAdmin,
|
|
207
199
|
error_catcher(async (req, res) => {
|
|
208
200
|
const form = customEventForm();
|
|
@@ -228,7 +220,6 @@ router.get(
|
|
|
228
220
|
*/
|
|
229
221
|
router.post(
|
|
230
222
|
"/custom/new",
|
|
231
|
-
setTenant,
|
|
232
223
|
isAdmin,
|
|
233
224
|
error_catcher(async (req, res) => {
|
|
234
225
|
const form = customEventForm();
|
|
@@ -264,7 +255,6 @@ router.post(
|
|
|
264
255
|
*/
|
|
265
256
|
router.post(
|
|
266
257
|
"/custom/delete/:name",
|
|
267
|
-
setTenant,
|
|
268
258
|
isAdmin,
|
|
269
259
|
error_catcher(async (req, res) => {
|
|
270
260
|
const { name } = req.params;
|
|
@@ -288,7 +278,6 @@ router.post(
|
|
|
288
278
|
*/
|
|
289
279
|
router.post(
|
|
290
280
|
"/settings",
|
|
291
|
-
setTenant,
|
|
292
281
|
isAdmin,
|
|
293
282
|
error_catcher(async (req, res) => {
|
|
294
283
|
const form = await logSettingsForm(req);
|
|
@@ -321,7 +310,6 @@ router.post(
|
|
|
321
310
|
*/
|
|
322
311
|
router.get(
|
|
323
312
|
"/",
|
|
324
|
-
setTenant,
|
|
325
313
|
isAdmin,
|
|
326
314
|
error_catcher(async (req, res) => {
|
|
327
315
|
const state = req.query,
|
|
@@ -377,7 +365,6 @@ router.get(
|
|
|
377
365
|
*/
|
|
378
366
|
router.get(
|
|
379
367
|
"/:id",
|
|
380
|
-
setTenant,
|
|
381
368
|
isAdmin,
|
|
382
369
|
error_catcher(async (req, res) => {
|
|
383
370
|
const { id } = req.params;
|
package/routes/events.js
CHANGED
package/routes/fields.js
CHANGED
|
@@ -22,7 +22,7 @@ const {
|
|
|
22
22
|
} = require("@saltcorn/data/models/expression");
|
|
23
23
|
const db = require("@saltcorn/data/db");
|
|
24
24
|
|
|
25
|
-
const {
|
|
25
|
+
const { isAdmin, error_catcher } = require("./utils.js");
|
|
26
26
|
const expressionBlurb = require("../markup/expression_blurb");
|
|
27
27
|
const { readState } = require("@saltcorn/data/plugin-helper");
|
|
28
28
|
const { wizardCardTitle } = require("../markup/forms.js");
|
|
@@ -419,7 +419,6 @@ const fieldFlow = (req) =>
|
|
|
419
419
|
*/
|
|
420
420
|
router.get(
|
|
421
421
|
"/:id",
|
|
422
|
-
setTenant,
|
|
423
422
|
isAdmin,
|
|
424
423
|
error_catcher(async (req, res) => {
|
|
425
424
|
const { id } = req.params;
|
|
@@ -472,7 +471,6 @@ router.get(
|
|
|
472
471
|
*/
|
|
473
472
|
router.get(
|
|
474
473
|
"/new/:table_id",
|
|
475
|
-
setTenant,
|
|
476
474
|
isAdmin,
|
|
477
475
|
error_catcher(async (req, res) => {
|
|
478
476
|
const { table_id } = req.params;
|
|
@@ -509,7 +507,6 @@ router.get(
|
|
|
509
507
|
*/
|
|
510
508
|
router.post(
|
|
511
509
|
"/delete/:id",
|
|
512
|
-
setTenant,
|
|
513
510
|
isAdmin,
|
|
514
511
|
error_catcher(async (req, res) => {
|
|
515
512
|
const { id } = req.params;
|
|
@@ -535,7 +532,6 @@ router.post(
|
|
|
535
532
|
*/
|
|
536
533
|
router.post(
|
|
537
534
|
"/",
|
|
538
|
-
setTenant,
|
|
539
535
|
isAdmin,
|
|
540
536
|
error_catcher(async (req, res) => {
|
|
541
537
|
const wf = fieldFlow(req);
|
|
@@ -584,7 +580,6 @@ router.post(
|
|
|
584
580
|
*/
|
|
585
581
|
router.post(
|
|
586
582
|
"/test-formula",
|
|
587
|
-
setTenant,
|
|
588
583
|
isAdmin,
|
|
589
584
|
error_catcher(async (req, res) => {
|
|
590
585
|
const { formula, tablename, stored } = req.body;
|
|
@@ -622,7 +617,6 @@ router.post(
|
|
|
622
617
|
*/
|
|
623
618
|
router.post(
|
|
624
619
|
"/show-calculated/:tableName/:fieldName/:fieldview",
|
|
625
|
-
setTenant,
|
|
626
620
|
isAdmin,
|
|
627
621
|
error_catcher(async (req, res) => {
|
|
628
622
|
const { tableName, fieldName, fieldview } = req.params;
|
|
@@ -657,7 +651,6 @@ router.post(
|
|
|
657
651
|
*/
|
|
658
652
|
router.post(
|
|
659
653
|
"/preview/:tableName/:fieldName/:fieldview",
|
|
660
|
-
setTenant,
|
|
661
654
|
isAdmin,
|
|
662
655
|
error_catcher(async (req, res) => {
|
|
663
656
|
const { tableName, fieldName, fieldview } = req.params;
|
|
@@ -722,7 +715,6 @@ router.post(
|
|
|
722
715
|
*/
|
|
723
716
|
router.post(
|
|
724
717
|
"/preview/:tableName/:fieldName/",
|
|
725
|
-
setTenant,
|
|
726
718
|
isAdmin,
|
|
727
719
|
error_catcher(async (req, res) => {
|
|
728
720
|
res.send("");
|