Ebase v5.0.1 gotcha!

Post any questions you have about using the Verj.io Studio, including client and server-side programming with Javascript or FPL, and integration with databases, web services etc.

Moderators: Jon, Steve, Ian, Dave

kotinkarwak
Ebase User
Posts: 109
Joined: Mon Sep 21, 2015 9:55 pm

Ebase v5.0.1 gotcha!

#1

Postby kotinkarwak » Fri Jan 29, 2016 8:51 pm

I have made use of underscore.js to perform data conversion where this file is added to the project as a serverside js file and added in as a shared Function at the form level. This inadvertently messed up an earlier working bit of code which was also making use of other shared Functions this time at component level.

The error I was getting is as below indicating that the function being called does not exist.

com.ebasetech.ufs.runtime.events.rhinojavascript.JavascriptExecutionHandler$RhinoScriptException: ReferenceError: "subscriptions" is not defined. (eventScript#21)

To rectify this, I went back to the components to confirm if they still are able to run independently but this was not the case, so I removed underscore.js at the top level (Form) and re-deployed the failing components after which i added the underscore.js to the form and this now works fine. I hope that was a solution hence question would be should there be a given order in adding these resources?
0 x
ebasetech v5

Skype: mateso08
Location: Kenya

Hovik
Moderator
Moderator
Posts: 184
Joined: Tue Sep 11, 2007 8:58 am

#2

Postby Hovik » Tue Feb 02, 2016 3:13 pm

I'd like to reproduce this here, so just for clarification:

1. At the time of failure, was underscore.js added to both the form and the component?

2. Is "subscriptions" a function in underscore.js ?
I went back to the components to confirm if they still are able to run independently but this was not the case
3. So running the component failed? Same error?
so I removed underscore.js at the top level (Form)
4. Do you mean removed it from the component?
0 x

kotinkarwak
Ebase User
Posts: 109
Joined: Mon Sep 21, 2015 9:55 pm

#3

Postby kotinkarwak » Tue Feb 02, 2016 3:47 pm

1). underscore.js was only added at the form level (events -> shared functions).
2). Subscription is a function not associated with underscore.js and is of the client callable functions.
3). The tests at this point when I encountered the error was to see if the components themselves could be opened in 'test' mode which they failed with same error.
Went back to form level, removed underscore.js, resubmitted the used components and when all was working, went back and added underscore.js to the form level.


btw, underscore.js is from the repository http://underscorejs.org/
0 x
ebasetech v5

Skype: mateso08
Location: Kenya


Who is online

Users browsing this forum: No registered users and 13 guests