Trying to get property of non-object

Saludos a todos, recurro nuevamente a su colaboración…

comentarles que necesito que se registre la fecha de creación de un registro, usando la funcion behaviors




 public function behaviors()

        {


            return array(

                'CTimestampBehavior' => array(

                'class' => 'zii.behaviors.CTimestampBehavior',

                'createAttribute' => 'fecharegistrocliente',

                //'updateAttribute' => 'modified_date',

                'setUpdateOnCreate' => true,

                ),

               

             );

        }



pero me sale este error: Trying to get property of non-object, me marca esta linea:




$columnType = $this->getOwner()->getTableSchema()->getColumn($attribute)->dbType;



del archivo CTimestampBehavior.php

Por favor me podrian ayudar a solucionar este error? Gracias!!!

Hola Susana, checa este enlace.

http://www.youtube.com/watch?v=3jwHGe0jEnE

Ahi explican cómo hacer lo que requieres.

Saludos

Gracias mil por su respuesta.