7 Replies Latest reply on Mar 26, 2014 2:45 PM by Brendan Higgins

    Any Word on Rho 4.1?

    Brendan Higgins

      A while back (on the #Rho4Chat twitter hash) it was mentioned that Moto was aiming for 4.1 om January.  It was supposed to have a several JS fixes we are waiting for:

       

      1. Fixed Schema and find. https://developer.motorolasolutions.com/thread/4225
      2. Enabling full_update. https://developer.motorolasolutions.com/message/12456#12456
      3. SyncEngine on_sync_create_error, on_sync_update_error, on_sync_delete_error  missing. https://developer.motorolasolutions.com/thread/4415
      4. RhoConnect LDAP authenticate method always returns true for JS models

       

      Thanks!

        • Re: Any Word on Rho 4.1?

          Brendan,

               Thank you for your inquiry. I am talking with the "powers that be" on this and I'll let you know as soon as I get the details on this.

            • Re: Any Word on Rho 4.1?

              Some of above issues mentioned should be fixed in 4.1 release. At this moment master branch of Rhodes includes a new implementation of ORM API that might be used instead of old ORM. New ORM fixes issue #1, but for old ORM you can you the following workaround:

              1. Create dummy property bag model with the same name that used for fixed schema

                 var fsModelDef = function(model){

                    model.modelName('Product');

                    model.property("name", "string");

                    model.property("brand","string");

                    model.enable("fixedSchema");

                 };

                 var pbDummyModel = function(model){

                    model.modelName('Product');

                 };

               

                2. Add this dummy property bag model before fixed one

                  

                 Rho.ORM.addModel(pbDummyModel);

                 var fsm =  Rho.ORM.addModel(fsModelDef);

                 // ...

               

                3. Create object(s) and find it by id

               

                var object = fsm.create({'name': 'Galaxy S4', 'brand': 'Samsung'});

                var found = fsm.find(object.object());

                console.log(JSON.stringify(found.vars()));

               

              Issue #2 is targeted to be fixed in 4.1

               

              I have no idea about issue #4. Can you elaborate it?

                • Re: Any Word on Rho 4.1?
                  Brendan Higgins

                  Thank you very much for the followup, it is much appreciated.

                   

                  For #4, in our tests, no matter what we do (and we could very well be doing something incorrectly), we cannot get the login function to fail.  For instance, from my developer:

                   

                  RhoConnect:

                  app.post(

                      '/login', {

                          'rc_handler':'authenticate'

                      }, function(req, resp){

                    var login = req.params.login;

                    var password = req.params.password;

                   

                    console.log("login Post");

                    console.log("login: " + login);

                    console.log("password: " + password);

                  /*

                  Authenticate to LDAP here...

                  */

                    console.log("resp");

                    console.log(resp);

                    resp.send('false');  // force a failure

                  });

                   

                  Rho App:

                  function readLogin(){

                      $.get("/public/templates/login.html", function(data){

                          var template = Handlebars.compile(data);

                          $("#content").html(template);

                          

                          $("#loginButton").click(function() {

                              var userName = $("#loginForm").find("input[name=userName]").val();

                               var password = $("#loginForm").find("input[name=password]").val();

                               Rho.RhoConnectClient.login(userName, password, function(e){

                                   console.log(e);

                                   console.log('login Callback error_code=' + e.error_code);                

                   

                                   if(e.error_code == "0") {

                                       //...

                                   }

                                   else {

                                       $("#content").html(unescape(e.error_message)); 

                                   }

                               });

                          });

                      });

                  }

                   

                  The response is ignored and the user is logged into the app.

              • Re: Any Word on Rho 4.1?

                I have asked about the release date and it seems that we are aiming for the end of March.

                1 of 1 people found this helpful