initial commit
This commit is contained in:
34
app/Model/Comment.php
Normal file
34
app/Model/Comment.php
Normal file
@@ -0,0 +1,34 @@
|
||||
<?php
|
||||
class Comment extends AppModel
|
||||
{
|
||||
var $name='Comment';
|
||||
|
||||
function createFeedback($inputData){
|
||||
|
||||
$result = NULL;
|
||||
|
||||
|
||||
$form["email"] = trim($inputData["feedbackemail"]);
|
||||
$form["comment"] = trim($inputData["comment"]);
|
||||
$form["ip"] = trim($inputData["ip"]);
|
||||
$form["create_date"] = trim($inputData["create_date"]);
|
||||
|
||||
|
||||
$fileds = array('email','comment','ip','create_date');
|
||||
|
||||
|
||||
$dbData["Comment"] = $form;
|
||||
|
||||
//print_r($data["Feeback"]);exit;
|
||||
|
||||
if(!$this->save($dbData,false,$fileds)){
|
||||
$result["22"] = __("LBL_EXPENSE_NOT_SAVED");
|
||||
|
||||
}
|
||||
|
||||
return $result;
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
?>
|
||||
Reference in New Issue
Block a user