initial commit
This commit is contained in:
32
app/Model/Wallet.php
Normal file
32
app/Model/Wallet.php
Normal file
@@ -0,0 +1,32 @@
|
||||
<?php
|
||||
|
||||
class Wallet extends AppModel
|
||||
{
|
||||
var $name='Wallet';
|
||||
|
||||
|
||||
|
||||
function list($conditions = array() )
|
||||
{
|
||||
return $this->find('all', array('conditions' => $conditions));
|
||||
}
|
||||
|
||||
function add($inputData)
|
||||
{
|
||||
$result = false;
|
||||
|
||||
if(!empty($inputData))
|
||||
{
|
||||
$fileds = array();
|
||||
$dbData["Wallet"] = $inputData;
|
||||
if($this->save($dbData,false,$fileds)){
|
||||
$dbData["Wallet"]['id'] = $this->id;
|
||||
$result = true;
|
||||
}
|
||||
}
|
||||
return array($result,$dbData["Wallet"]);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
?>
|
||||
Reference in New Issue
Block a user