So your view is replacing #contenido with this html:
    <div class="active-scaffold-component" data-
refresh="/competencias?eid=12f36e04e6d224b74bb281454735bdc6&amp;embedded=true" 
id="as_12f36e04e6d224b74bb281454735bdc6-embedded"><div class="active-scaffold-
header"><h2><a class="load-embedded" data-remote="true" 
href="/competencias?eid=12f36e04e6d224b74bb281454735bdc6&amp;embedded=true">Competencias</a></h2></div></div>

Which includes a link to load an embedded scaffold.

ActiveScaffold loads embedded scaffolds with ActiveScaffold.load_embedded 
function. This function is called everytime an action link finishes 
successfully or as:element_updated event is triggered (usually when an item is 
changed with ActiveScaffold.replace, ActiveScaffold.replace_html or 
ActiveScaffold.append).

However you are loading html with destObj.load instead of using 
ActiveScaffold, so you should trigger as:element_updated to trigger 
ActiveScaffold listeners on your updated div.

El Jueves, 19 de febrero de 2015 17:17:12 Benjamín Cárdenas Salamandra 
escribió:
> On 19/02/2015 09:54 a.m., Sergio Cambra wrote:
> El Jueves, 19 de febrero de 2015 09:12:07 Benjamín Cárdenas Salamandra
> escribió:
> On 19/02/2015 05:46 a.m., Sergio Cambra wrote:
> El Miércoles, 18 de febrero de 2015 18:57:12 bencarsal escribió:
> When click over submit button, trigger one ajax that replace #contenido
> div
> with a embedded active scaffold controller (competencias), but this shows
> nothing.
> 
> Log here:
> *************************************
> {"utf8"=>"?", "grado"=>"21", "materia"=>"68",
> "controller"=>"competencias",
> "action"=>"lista"}
> *************************************
> 
>    Rendered
>    C:/proyectos/rectorware5/app/views/competencias/lista.html.haml
> 
> (1037.0ms)
> Completed 200 OK in 1106ms (Views: 1043.0ms | ActiveRecord: 32.0ms)
> 
> The render: :active_scaffold => "competencias", :constraints =>
> {:materia_id=> @materia_id, :grado_id=> @grado_id} don't work with ajax
> call, and i have reviewed the source code to locate the reason, and I
> could
> not. I need your help to resolve the impasse, please.
> What's the response of that request (competencias#lista)?
> Thanks Sergio, is supposed to render the index, but does not answer
> anything. I think the ajax request is ignored. The log above is all...
> If I understand correctly, you get request for lista action on compentencias
> controller. So I would need the response for that request, you can get it
> on network tab of web inspector
> 
> 
> Headers:
> Remote Address: [::1]:3000
> Request URL:
> http://localhost:3000/competencias/lista?utf8=%E2%9C%93&grado=16&materia=68
> Request Method: GET
> Status Code: 304 Not Modified
> Request Headersview source
> Accept: text/html, */*; q=0.01
> Accept-Encoding: gzip, deflate, sdch
> Accept-Language: en-US,en;q=0.8,es-419;q=0.6,es;q=0.4
> Connection: keep-alive
> Cookie:
> _rectorware5_session=ajFBV2NGZis4ZHFaQjh5a0ZjQUZMWlBRcE1IcDV2K3FlUHMwQ3NVK2
> NJUmlIWUFSTWFaM0JEY3VGU0E5eWRibzgvUjhTQnVVL21HZmdLQ1krKzBoc2R1TzhIaFl5b0lhc2
> ZGak1Ha1F3ZTVWOXg0SXhoNlpaaDZpKzBBTGhLTVhlQnFNdXdMZXRCZ1AwVHpONHduTmNYQ0lCYm
> U0OUl2MkRWMUdFZEd3c0hnTGQrcmN3bkVzSjBMR3lkVEY1R1FuTC82cnFaaHVOM0FPWWNjc1ZIdD
> ZPSlZPU09zUHBaTDFPN1ZhU2NXWnB2ZFU4M0NRNFFwc0Y3VnZpMjRETnpqb1QzZHV3WUNDOUFhb2
> JpTGYybWxwZndtRWhvc011TWs2a1JDdEZEeHNBMFRhUXNOOUFtMVBFSzZHTUY0d0tSZ1BYNE9Hdl
> NZSzVhTDF0eG96N3dxdUx5aFJRRnpHRHN4MDkvQ0cwZTBLdnpITVlaTGNDUzk2ZG9QN0o5eWwzUT
> JQenJaRU1EZ1hMWUoxK25UbmtrVGlnVGFSQUpzRjJzUWVpd2NrR3pyNUNKWFJNMlpoMXlLc2J4dm
> hvc0ZFaGtMYVdaaVhrK3BCQ0ppY085R1JTZTBlLzIwNWE2ZG5ZeDRlenBDNW54SlZHOWh5NVlqWD
> g3eEhjeG5yZjJCMWJyb1lUQUk2bHlRRkt4T1ZtU0liRWIzZG91dWFGUW5iaEcxMXNPZnZibEIrYm
> VqU2RWem9xaEoybFZkV3Z3dmU5MTArem9jSUlJNFRvWTVleUhLazduYTdhOTFkMmFVWEowcVB0eG
> FtbjU3b1lRTGQvV3VQbVFuR3dEaEdIZmF2elN3RDdaREhVaDA5aGxhTU9XcVRKcHRzeDNIcGIxeG
> 9WK2xQbjQ2SGpVblh1MTJJT3pZSDFQN09xSENqS0FlUmF
> yMVhSMlUrWlJJbWtZN3RWNFJDeWNPK3Y3NzhraTBBS09kR0pWbXBEbGlpeUYyMDl1bWUxN1A2b0
> RoWnZnc25lQ3Z5LS13am1tMmRWV2dTTlRuUkNBZVVRM1ZRPT0%3D--8743752563848005e291d7
> ddf58eea9d573af052 Host: localhost:3000
> If-None-Match: "7495265e577e8d00573db64213670174"
> Referer: http://localhost:3000/
> User-Agent: Mozilla/5.0 (Windows NT 6.1;
>             WOW64) AppleWebKit/537.36 (KHTML, like Gecko)
>             Chrome/40.0.2214.111 Safari/537.36
> X-CSRF-Token: z5F0/DJF1cKmnGh4Kj7g1SHrYtbrzqqu7wyUGcKzKFk=
> X-Requested-With: XMLHttpRequest
> Query String Parametersview sourceview URL encoded
> utf8: ✓
> grado: 16
> materia: 68
> Response Headersview source
> Cache-Control: max-age=0, private,
>             must-revalidate
> Connection: Keep-Alive
> Date: Thu, 19 Feb 2015 19:31:53 GMT
> Etag: "7495265e577e8d00573db64213670174"
> Server: WEBrick/1.3.1
>             (Ruby/2.0.0/2014-09-03)
> Set-Cookie:
> _rectorware5_session=OFJZUEhGYW9VOFJVWWo1ekNhN2g0ODRBbFpkYnJwdVNLNEYraEtkMW
> puOCtxVDhybWFmM3NpeXMxenoxMWtIeXR0dGlXamdlQ2xkUStxMnJPc1ovV3RYbWpKeFBMZTNVZH
> FOTEpZbUVzN3pKbURGMDQ5MkROc2I5V3Q4MmdwWGpGdk8vS1RZSmxpSTlnU0VnaWk3WStrY1ZVY1
> Rsd0RhamRmY0hOTGlXNW0ydUZLaUZ2ek1DSy9iWkNIZlF1c1RMUjluM000SnQrTzdrVFFMN1N0ZF
> Y5SnRPVVlRZ2k3emVlZmlTeWRqWmx1VGFvRlZEckJsY1lZek5nekFJYmlaSlhJY0g3WEVrTndkdE
> liZWRrblNCUHlEZndOYitaTEJ1dXUzS0IxOGhTU0svTWY5bXh0YTRYZG10S0NwemwwN3gxcGpxcH
> dxdjZwN3pmZHhyUzBnaGRVemxXd0JvOHRPdDQ1bmoxYWVUSzFKSDJLM3VFbmhQWnZTZzl5UGlvQU
> FGeGN0NStBdmlLOHdDRThBZEsrcEwzd1RGU3c4dUNsRm9oQTlmSHRrL0FXUHBBYW1RTG9wb3lYak
> s3UCsrOXg3anUwSERQNDVxNnlTakR5clNPREhyN0Y4QmxBa214a2k2T2Q4cENWMExFVjdybWZ5QX
> VtQU9YSklUMEVDcEJESHB0NTRseHNBTVFJRVpFb3dKWWhoNEpzRW9Hc3U5djFXc1Zqc2FwSnhldl
> pSTmlkYWpydmR0YU9iY0JFcEFjWFUwWUhNT2JzVld2Wm1jM21Tajg2ai9Ba3padXc3a3REc3BWSG
> Y4S3Z0UW1yQ1NvcGVycFA4ZjhoVFQrZ2xFZ2d1KzJGMFhpSU9PckNyNDM4UU5yTFYyUjBtekx2MD
> ZaV2FMTEI4UVhpTXpIUXR4UitJR3k2UTZpeDBnUjQ3cWN
> wYkZFVFpYTHlucmQwaVg4Q2V5MURHVFJ3M21xdWFGbEZDOE50WFROQitDRnJCNmNXUXNtZ2U3Mk
> NhRXlseE1CWThvLS1MRzZ0cjJxSUJzQ2lqWU5EblpmTkl3PT0%3D--1cee73df4aae03559fb70d
> 8c9dafa63ba56a8f3b; path=/; HttpOnly
> X-Content-Type-Options: nosniff
> X-Frame-Options: SAMEORIGIN
> X-Request-Id: 47da68d6-010d-4cd3-bac0-f7c3d56ee779
> X-Runtime: 0.684000
> X-Xss-Protection: 1; mode=block
> Response:
>     <div class="active-scaffold-component"
> data-refresh="/competencias?eid=12f36e04e6d224b74bb281454735bdc6&amp;embedd
> ed=true" id="as_12f36e04e6d224b74bb281454735bdc6-embedded"><div
> class="active-scaffold-header"><h2><a class="load-embedded"
> data-remote="true"
> href="/competencias?eid=12f36e04e6d224b74bb281454735bdc6&amp;embedded=true"
> >Competencias</a></h2></div></div>
> 
> --
> You received this message because you are subscribed to the Google Groups
> "ActiveScaffold : Ruby on Rails Gem" group. To unsubscribe from this group
> and stop receiving emails from it, send an email to
> [email protected]. To post to this group, send
> email to [email protected]. Visit this group at
> http://groups.google.com/group/activescaffold. For more options, visit
> https://groups.google.com/d/optout.

-- 
You received this message because you are subscribed to the Google Groups 
"ActiveScaffold : Ruby on Rails Gem" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/activescaffold.
For more options, visit https://groups.google.com/d/optout.

Reply via email to