<?php
class ExpenseEmail extends AppModel
{
	var $name='ExpenseEmail';
 
	function insertExpenseEmail($inputData){
			
		$result = NULL;
		if(isset( $inputData["id"])) {
            $form["id"] = $inputData["id"];
        }
		$form["unique_url"] = $inputData["unique_url"];
		$form["email"] = $inputData["email"];		
		$form["title"] = $inputData["title"];
		$form["count_email_attempt"] = $inputData["count_email_attempt"];

        if(isset( $inputData["id"])) {
            $fileds = array('id', 'unique_url', 'email', 'title', 'count_email_attempt');
        } else {
            $fileds = array( 'unique_url', 'email', 'title', 'count_email_attempt');
        }
	
	
		$dbData["ExpenseEmail"] = $form; 
	
		if(!$this->save($dbData,false,$fileds)){
			$result["22"] = __("LBL_EXPENSE_EMAIL_SAVED_SUCCESSFULLY");
		}
	
		return $result;
	}
}