msg+done
This commit is contained in:
parent
45393e5258
commit
6caa98accc
|
@ -47,9 +47,9 @@ class DreamjobJobMsg extends AppModel {
|
||||||
$dataSource->begin();
|
$dataSource->begin();
|
||||||
$result = $this->save();
|
$result = $this->save();
|
||||||
if($result){
|
if($result){
|
||||||
$con = array('conditions' => array('Application.id' => $result["DreamjobJobMsg"]["application_id"]));
|
$con = array('conditions' => array('DreamjobJobApplication.id' => $result["DreamjobJobMsg"]["application_id"]));
|
||||||
echo "Lola";
|
echo "Lola";
|
||||||
$app = $this->Application->find('first' );
|
$app = $this->DreamjobJobApplication->find('first' );
|
||||||
echo var_dump($app);
|
echo var_dump($app);
|
||||||
exit(1);
|
exit(1);
|
||||||
|
|
||||||
|
@ -126,29 +126,29 @@ class DreamjobJobMsg extends AppModel {
|
||||||
)
|
)
|
||||||
);*/
|
);*/
|
||||||
public $hasOne = array(
|
public $hasOne = array(
|
||||||
'Application' => array(
|
'DreamjobJobApplication' => array(
|
||||||
'className' => 'DreamjobJobApplication',
|
'className' => 'DreamjobJobApplication',
|
||||||
'foreignKey' => false,
|
'foreignKey' => false,
|
||||||
'conditions' => array('Application.id = DreamjobJobMsg.application_id'),
|
'conditions' => array('DreamjobJobApplication.id = DreamjobJobMsg.application_id'),
|
||||||
'fields' => '',
|
'fields' => '',
|
||||||
'order' => ''
|
'order' => ''
|
||||||
),
|
),
|
||||||
'Opening' => array(
|
'Opening' => array(
|
||||||
'className' => 'DreamjobJobOpening',
|
'className' => 'DreamjobJobOpening',
|
||||||
'foreignKey' => false,
|
'foreignKey' => false,
|
||||||
'conditions' => array('Opening.id = Application.opening_id'),
|
'conditions' => array('Opening.id = DreamjobJobApplication.opening_id'),
|
||||||
'limit' => 1
|
'limit' => 1
|
||||||
),
|
),
|
||||||
'AppUserWorker' => array(
|
'AppUserWorker' => array(
|
||||||
'className' => 'AppUser',
|
'className' => 'AppUser',
|
||||||
'foreignKey' => false,
|
'foreignKey' => false,
|
||||||
'conditions' => array('Application.worker_id = AppUserWorker.id'),
|
'conditions' => array('DreamjobJobApplication.worker_id = AppUserWorker.id'),
|
||||||
'limit' => 1
|
'limit' => 1
|
||||||
),
|
),
|
||||||
'Worker' => array(
|
'Worker' => array(
|
||||||
'className' => 'User',
|
'className' => 'User',
|
||||||
'foreignKey' => false,
|
'foreignKey' => false,
|
||||||
'conditions' => array('Application.worker_id = AppUserWorker.id and Worker.id = AppUserWorker.user_id'),
|
'conditions' => array('DreamjobJobApplication.worker_id = AppUserWorker.id and Worker.id = AppUserWorker.user_id'),
|
||||||
'limit' => 1
|
'limit' => 1
|
||||||
),
|
),
|
||||||
'AppUserCompany' => array(
|
'AppUserCompany' => array(
|
||||||
|
|
Loading…
Reference in New Issue