Exemplo n.º 1
0
 public function createTransaction(array $datas)
 {
     $datas['id'] = $datas['transaction_id'];
     $transaction = Transaction::create($datas);
     $this->transaction()->associate($transaction);
     $this->save();
 }