ISSUE of Plugin Events

Plus d'informations
il y a 3 semaines 4 jours #176822 par soubhikbasu
soubhikbasu a créé le sujet : ISSUE of Plugin Events
Hello,

I am wondering that some of your event working and some not.

Why this is so?

Like:

beforeActivate - working
beforeDeactivate - not working
beforeSurveyActivate - working
beforeSurveyDeactivate - not working
afterSurveyComplete - not working


is any special way to use for the "afterResponseSave" event?


All events are tried with both version
1. Version 3.0.0-RC.3+171113
2. Version 2.73.0

i am using follwing code for plugin

protected $storage = 'DbStorage';
static protected $description = 'Demo: handle a survey response';
static protected $name = 'Show response';

public function init() {
$this->subscribe('beforeActivate');
}

public function beforeActivate()
{
$event = $this->getEvent();
$event->set('success', false);
$event->set('message', 'Can\'t activate survey - some condition is not met.');

}

Please help me out

Connexion ou Créer un compte pour participer à la conversation.

Plus d'informations
il y a 3 semaines 4 jours - il y a 3 semaines 4 jours #176823 par DenisChenu
DenisChenu a répondu au sujet : ISSUE of Plugin Events
Please : read …
manual.limesurvey.org/BeforeActivate
This event is fired just before plugin is activated.

afterSurveyComplete - not working :

i don't remind of issue with this event …

1. Version 3.0.0-RC.3+171113

RC mean release candidate … not done for production can be totally broken …

afterResponseSave : manual.limesurvey.org/Plugin_events#Dyna....28New_in_3.15.1_.29 this event are only for 3.15.1 and can have issue (currently don't happen each time a response is saved)

Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member, professional service on demand (or search sondages pro).
An error happen ? Before make a new topic : remind the Debug mode .
Dernière édition: il y a 3 semaines 4 jours par DenisChenu.

Connexion ou Créer un compte pour participer à la conversation.

Plus d'informations
il y a 3 semaines 4 jours #176837 par soubhikbasu
soubhikbasu a répondu au sujet : ISSUE of Plugin Events
Thanks, Denis for your reply

I am already tested with that plugin, which is fired just before the activate the plugin.

But, when I use this to "beforeSurveyDeactivate" which means before deactivating the survey is fired the event. But it is not working.

In Event List( manual.limesurvey.org/Plugin_events# ) mentioned beforeSurveyDeactivate (New in 2.5 ) and I am also tested in Version 2.73.0, it's not working. Why?

As per your reply, "afterResponseSave" only working in 3.15.1, then if I want to trigger anything just after the response of a survey what will need to use?

afterSurveyComplete - I am already tested with both version, it's not working

is this working in Version 2.73.0?


Thanks in advance

Connexion ou Créer un compte pour participer à la conversation.

Plus d'informations
il y a 3 semaines 4 jours #176842 par DenisChenu
DenisChenu a répondu au sujet : ISSUE of Plugin Events

soubhikbasu écrit: …
afterSurveyComplete - I am already tested with both version, it's not working

is this working in Version 2.73.0?

Is working on ALL version …

Test with github.com/LimeSurvey/LimeSurvey/tree/ma...ns/Demo/ShowResponse …

Withyour answer : i can not help you : you give NO information …

Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member, professional service on demand (or search sondages pro).
An error happen ? Before make a new topic : remind the Debug mode .

Connexion ou Créer un compte pour participer à la conversation.

Plus d'informations
il y a 3 semaines 4 jours #176846 par soubhikbasu
soubhikbasu a répondu au sujet : ISSUE of Plugin Events
Thanks Denis,

Yes, its working with your code in Version 2.73.0

Is this also working in latest version without RC? Like: limesurvey3.15.3+181108

But what about "beforeSurveyDeactivate" ? it is not working in Version 2.73.0


Thanks for your quick reply. Its really help me

Connexion ou Créer un compte pour participer à la conversation.

Plus d'informations
il y a 3 semaines 4 jours #176854 par DenisChenu
DenisChenu a répondu au sujet : ISSUE of Plugin Events

soubhikbasu écrit: Is this also working in latest version without RC? Like: limesurvey3.15.3+181108

If you don't read what i write … i didn't see any reason to continue …

Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member, professional service on demand (or search sondages pro).
An error happen ? Before make a new topic : remind the Debug mode .
Les utilisateur(s) suivant ont remercié: LouisGac

Connexion ou Créer un compte pour participer à la conversation.

Plus d'informations
il y a 3 semaines 4 jours #176863 par soubhikbasu
soubhikbasu a répondu au sujet : ISSUE of Plugin Events
Hello Denis,

1. I see what you have written in your previous reply. Asking just for confirmation about "afterSurveyComplete".
2. What about "beforeSurveyDeactivate"? You does't reply anything about that.

Connexion ou Créer un compte pour participer à la conversation.

Plus d'informations
il y a 3 semaines 4 jours #176869 par DenisChenu
DenisChenu a répondu au sujet : ISSUE of Plugin Events

DenisChenu écrit: With your answer : i can not help you : you give NO information …

Since you don't put any sample code using this function …

See stackoverflow.com/help/how-to-ask for example …

Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member, professional service on demand (or search sondages pro).
An error happen ? Before make a new topic : remind the Debug mode .

Connexion ou Créer un compte pour participer à la conversation.

Plus d'informations
il y a 3 semaines 4 jours #176870 par soubhikbasu
soubhikbasu a répondu au sujet : ISSUE of Plugin Events
I think you do not see the question properly..
Please check my first post, there already mentioned sample code, just changing the event name.

Anyhow, I am repeating this here

###############
protected $storage = 'DbStorage';
static protected $description = 'Demo: handle a survey response';
static protected $name = 'Show response';

public function init() {
$this->subscribe('beforeSurveyDeactivate');
}

public function beforeSurveyDeactivate()
{
$event = $this->getEvent();
$event->set('success', false);
$event->set('message', 'Can\'t deactivate survey - some condition is not met.');

}
###########

Note: If you are not comfortable or understand to answer the question, please leave/transfer this for others support guy. I think someone else must be there.

Thank you

Connexion ou Créer un compte pour participer à la conversation.

Plus d'informations
il y a 3 semaines 4 jours #176875 par DenisChenu
DenisChenu a répondu au sujet : ISSUE of Plugin Events
OK,

Seems not in 2.73
[limesurvey273]$ grep -r "beforeSurveyDeactivate" *
[limesurvey273]$

Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member, professional service on demand (or search sondages pro).
An error happen ? Before make a new topic : remind the Debug mode .
Les utilisateur(s) suivant ont remercié: soubhikbasu

Connexion ou Créer un compte pour participer à la conversation.

Plus d'informations
il y a 3 semaines 4 jours #176904 par tpartner
tpartner a répondu au sujet : ISSUE of Plugin Events

Note: If you are not comfortable or understand to answer the question, please leave/transfer this for others support guy. I think someone else must be there.

This is not Limesurvey support - you have to pay for that.

This is a forum attended by volunteers, please respect them when they give their free time to try and help you.

Cheers,
Tony Partner
Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.

Connexion ou Créer un compte pour participer à la conversation.

Commencez dès maintenant !

Créez simplement un compte et commencez à utiliser LimeSurvey dès aujourd'hui.

Inscrivez-vous maintenant

Inscrivez-vous à notre Newsletter!