backend-plus 2.0.0-rc.26 → 2.0.0-rc.28
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/LICENSE +21 -21
- package/README.md +263 -263
- package/for-client/my-localdb.d.ts +59 -0
- package/for-client/my-localdb.js +689 -0
- package/for-client/my-localdb.js.map +1 -0
- package/for-client/my-websqldb.d.ts +35 -0
- package/for-client/my-websqldb.js +600 -0
- package/for-client/my-websqldb.js.map +1 -0
- package/lib/backend-plus.d.ts +5 -5
- package/lib/backend-plus.js +15 -3
- package/lib/table-def-adapt.js +358 -358
- package/lib/tables/table-tokens.js +28 -28
- package/package.json +134 -134
- package/unlogged/compatibilidad.js +161 -161
package/lib/backend-plus.js
CHANGED
|
@@ -1768,14 +1768,26 @@ function require_resolve(moduleName){
|
|
|
1768
1768
|
return resolved;
|
|
1769
1769
|
}
|
|
1770
1770
|
|
|
1771
|
-
function resolve_module_dir(moduleName,path){
|
|
1771
|
+
function resolve_module_dir(moduleName,path,fileToCheck){
|
|
1772
1772
|
var baseDir;
|
|
1773
1773
|
if(packagejson.name==moduleName){
|
|
1774
1774
|
baseDir=Path.join(process.cwd(), packagejson.main);
|
|
1775
1775
|
}else{
|
|
1776
1776
|
baseDir=require_resolve(moduleName);
|
|
1777
1777
|
}
|
|
1778
|
-
|
|
1778
|
+
var resultDir = Path.join(Path.dirname(baseDir),path||'');
|
|
1779
|
+
if (fileToCheck) {
|
|
1780
|
+
fs.stat(Path.join(resultDir, fileToCheck)).then(function(status){
|
|
1781
|
+
if (!status) {
|
|
1782
|
+
console.error('Error resolve_module_dir in:',resultDir,'no:',fileToCheck);
|
|
1783
|
+
} else if(!status.isFile()) {
|
|
1784
|
+
console.error('Error resolve_module_dir in:',resultDir,',',fileToCheck,'is not a file');
|
|
1785
|
+
}
|
|
1786
|
+
},function(err){
|
|
1787
|
+
console.error('Error resolve_module_dir in:',resultDir,'err:',err);
|
|
1788
|
+
});
|
|
1789
|
+
}
|
|
1790
|
+
return resultDir;
|
|
1779
1791
|
}
|
|
1780
1792
|
|
|
1781
1793
|
AppBackend.prototype.optsGenericForFiles = function optsGenericForFiles(req, opts){
|
|
@@ -1982,7 +1994,7 @@ AppBackend.prototype.addUnloggedServices = function addUnloggedServices(mainApp,
|
|
|
1982
1994
|
}
|
|
1983
1995
|
}
|
|
1984
1996
|
} catch (error) {
|
|
1985
|
-
console.error('ERROR: No se pudo servir el módulo
|
|
1997
|
+
console.error('ERROR: No se pudo servir el módulo', moduleDef.module);
|
|
1986
1998
|
throw error;
|
|
1987
1999
|
}
|
|
1988
2000
|
})
|