Skip to Content.
Sympa Menu

comanage-dev - Re: [comanage-dev] commit a change to help debugging/development

Subject: COmanage Developers List

List archive

Re: [comanage-dev] commit a change to help debugging/development


Chronological Thread 
  • From: Scott Koranda <>
  • To: Benn Oshrin <>
  • Cc:
  • Subject: Re: [comanage-dev] commit a change to help debugging/development
  • Date: Wed, 29 Aug 2012 07:45:09 -0500

Hi,

On Wed, Aug 29, 2012 at 7:43 AM, Benn Oshrin
<>
wrote:
> The text in send.ctp should be move to lang.php.

I can do that.

>
> Also, there should probably be a link in send.ctp to $nextPage when in debug
> mode so the user flow doesn't just stop.

It doesn't. It works just as it did before (which is exactly what I need).

Thanks,

Scott

>
> -Benn-
>
> On 8/28/12 2:26 PM, Scott Koranda wrote:
>>
>> Hi,
>>
>> I would like to commit the following change. It is intended to
>> help with debugging/development by showing the old behavior
>> with invitations when debug is non-zero:
>>
>> Any objections?
>>
>> Scott
>>
>> diff --git a/app/Controller/CoInvitesController.php
>> b/app/Controller/CoInvitesController.php
>> index 724902d..4bc72cb 100644
>> --- a/app/Controller/CoInvitesController.php
>> +++ b/app/Controller/CoInvitesController.php
>> @@ -483,10 +483,16 @@ class CoInvitesController extends AppController {
>> $this->Session->setFlash(_txt('er.cop.nf', array($cpid)), '',
>> array(), 'error');
>> }
>>
>> - // Redirect to My Population
>> - $nextPage = array('controller' => 'co_people',
>> - 'action' => 'index',
>> - 'co' => $this->cur_co['Co']['id']);
>> - $this->redirect($nextPage);
>> + $debug = Configure::read('debug');
>> + if(!$debug) {
>> + // Redirect to My Population when no debugging so that
>> + // user sees flash message that email was sent with invitation.
>> + // Otherwise when debugging user will see link to the invitation
>> + // to help debugging and testing.
>> + $nextPage = array('controller' => 'co_people',
>> + 'action' => 'index',
>> + 'co' => $this->cur_co['Co']['id']);
>> + $this->redirect($nextPage);
>> + }
>> }
>> }
>> diff --git a/app/View/CoInvites/send.ctp b/app/View/CoInvites/send.ctp
>> index 5c34eb2..76fcf4e 100644
>> --- a/app/View/CoInvites/send.ctp
>> +++ b/app/View/CoInvites/send.ctp
>> @@ -28,6 +28,9 @@
>> ?>
>>
>> <p>
>> +You are seeing this text because <b>debug</b> is true in the
>> configuration file <b>app/Config/core.php</b>.
>> +</p>
>> +<p>
>> Email would be sent to <b><?php echo $invite['CoInvite']['mail']; ?></b>
>> with the URL
>> <br />
>> <br />
>>
>



Archive powered by MHonArc 2.6.16.

Top of Page