Hello List,

I have a problem that after creating a module and configuring
dsExtDirectPlugin, no new action is created in the extdirect api.

When I use modules which have not been autogenerated (action class
extends sfActions), it works perfectly and I have new functions in the
extdirect api.

What should I do?

Here is what I did:

I created the module with
./symfony propel:generate-admin test TestRetion --module=region

This creates an action class:

<?php
require_once dirname(__FILE__).'/../lib/
regionGeneratorConfiguration.class.php';
require_once dirname(__FILE__).'/../lib/
regionGeneratorHelper.class.php';
class regionActions extends autoRegionActions
{
}

When I add a new function in the action class:

<?php
require_once dirname(__FILE__).'/../lib/
regionGeneratorConfiguration.class.php';
require_once dirname(__FILE__).'/../lib/
regionGeneratorHelper.class.php';
class regionActions extends autoRegionActions
{
        /**
         * @extdirect-enable
         * @extdirect-len 1
         */
        public function executeBla($request){
                $array = $request->getparameter('_raw');
                $object = $array[0];
                $this->result = $object->foo;
        }

}

Then I would expect there is a new function in the extdirect API.

The app is configured as follows:

config/app.yml:
===============================================
# You can find more information about this file on the symfony
website:
# http://www.symfony-project.org/reference/1_4/en/11-App

all:
  #each app (and even each environmenmt of each app!) can use its own
extjs-lib
  #so that new apps can use the latest extjs lib without causing side-
effects
  #to other apps using older libs:
  #extjslib: ext-3.1.0
  #extjslib: ext-3.2.1

  #the js object that is responsible for the GUI representation. this
setting
  #is used for convenient access in the JsFilter
  jsclass: TestProjectExplorer

  ds_ext_direct_plugin:
    # Optional. Only use this parameter if you intend to create a
mod_rewrite our route to a different URL for your extdirect front
controller.
    router_url: /test_extdirect.php

    # Optional. Namespace for direct actions (ex:
myNs.myAction.myMethod();)
    action_namespace: Test

    # Optional. Set the javascript variable name for the js api spec
(defaults to 'Ext.app.{YOUR_API_NAME}_API)
    js_var: Ext.app.EXTDIRECT_TEST_API

    # Optional. Set a provider_type (defaults to remoting)
    #provider_type: remoting

    # Optional. List plugins who's action classes you want included in
API generation (defaults to null)
    # ex: include_plugins: [sfGuardPlugin]
    #include_plugins: ~

  sf_guard_plugin:
    #signin_form: AMSLoginForm
    profile_class:      UrmUser
    profile_field_name: SF_GUARD_USER_ID



factories.yml:
===============================================
# You can find more information about this file on the symfony
website:
# http://www.symfony-project.org/reference/1_4/en/05-Factories

prod:
  logger:
    class:   sfNoLogger
    param:
      level:   err
      loggers: ~

test:
  storage:
    class: sfSessionTestStorage
    param:
      session_path: %SF_TEST_CACHE_DIR%/sessions

  response:
    class: sfWebResponse
    param:
      send_http_headers: false

  mailer:
    param:
      delivery_strategy: none

dev:
  mailer:
    param:
      delivery_strategy: none

extdirect:
  controller:
    class: dsExtDirectController
all:
  routing:
    class: sfPatternRouting
    param:
      generate_shortest_url:            true
      extra_parameters_as_query_string: true

  view_cache_manager:
    class: sfViewCacheManager
    param:
      cache_key_use_vary_headers: true
      cache_key_use_host_name:    true

-- 
If you want to report a vulnerability issue on symfony, please send it to 
security at symfony-project.com

You received this message because you are subscribed to the Google
Groups "symfony users" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/symfony-users?hl=en

Reply via email to