Subversion Repositories SmartDukaan

Rev

Rev 14518 | Rev 18793 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 14518 Rev 14547
Line 144... Line 144...
144
		}
144
		}
145
		$options = array('conditions' => array('Device.' . $this->Device->primaryKey => $id));
145
		$options = array('conditions' => array('Device.' . $this->Device->primaryKey => $id));
146
		$this->set('device', $this->Device->find('first', $options));
146
		$this->set('device', $this->Device->find('first', $options));
147
	}
147
	}
148
 
148
 
-
 
149
	public function admin_by($userId = null) {
-
 
150
		$options = array('conditions' => array('Device.user_id' => $userId),'order'=>array('id'=>'desc'),'limit' => 100);
-
 
151
		$this->Paginator->settings = $options;
-
 
152
		$devices = $this->Paginator->paginate();		
-
 
153
		$this->set(compact('devices'));
-
 
154
		$this->render('admin_index');
-
 
155
	}
-
 
156
 
149
/**
157
/**
150
 * admin_add method
158
 * admin_add method
151
 *
159
 *
152
 * @return void
160
 * @return void
153
 */
161
 */