Ejemplo n.º 1
0
	/**
	 * Displays a particular model.
	 * @param integer $id the ID of the model to be displayed
	 */
	public function actionView($id) {
		$model=$this->loadModel($id);
		$model->assignedTo=UserChild::getUserLinks($model->assignedTo);
		$type='project';
		
		parent::actionView($model,$type);
	}
Ejemplo n.º 2
0
	/**
	 * Displays a particular model.
	 * @param integer $id the ID of the model to be displayed
	 */
	public function actionView($id) {
		$type = 'sales';
		$model = $this->loadModel($id);
		$model->assignedTo = UserChild::getUserLinks($model->assignedTo);
		$model->associatedContacts = ContactChild::getContactLinks($model->associatedContacts);
		
		parent::actionView($model, $type);
	}
Ejemplo n.º 3
0
	/**
	 * Displays a particular model.
	 * @param integer $id the ID of the model to be displayed
	 */
	public function actionView($id) {
		$model=$this->loadModel($id);
		
		$model->assignedTo=UserChild::getUserLinks($model->assignedTo);
		
		$str = '';
		$contacts=ContactChild::model()->findAllByAttributes(array('company'=>$model->name));
		foreach($contacts as $contact){
			$str.=$contact->id.' ';
		}
		$model->associatedContacts=$str;
		
		$model->associatedContacts=ContactChild::getContactLinks($model->associatedContacts);
		
		$type='accounts';
		parent::actionView($model, $type);
	}
Ejemplo n.º 4
0
	/**
	 * Displays a particular model.
	 * @param integer $id the ID of the model to be displayed
	 */
	public function actionView($id) {
		$type='templates';
		$model=$this->loadModel($id);
		parent::actionView($model, $type);
	}
Ejemplo n.º 5
0
	/**
	 * Displays a particular model.
	 * @param integer $id the ID of the model to be displayed
	 */
	public function actionView($id) {

		$contact = $this->loadModel($id);

		if ($contact->assignedTo == Yii::app()->user->getName()
				|| $contact->visibility == 1
				|| Yii::app()->user->getName() == 'admin') {
			UserChild::addRecentItem('c',$id,Yii::app()->user->getId());	////add contact to user's recent item list
			parent::actionView($contact, 'contacts');
		} else
			$this->redirect('index');
	}
Ejemplo n.º 6
0
	/**
	 * Displays a particular model.
	 * @param integer $id the ID of the model to be displayed
	 */
	public function actionView($id) {
		$type='marketing';
		$model=$this->loadModel($id);
		parent::actionView($model, $type);
	}