[Vtigercrm-commits] [vtiger-commits] r7621 - /vtigercrm/trunk/modules/Campaigns/Save.php
vtigercrm-commits at vtiger.fosslabs.com
vtigercrm-commits at vtiger.fosslabs.com
Wed Jun 28 06:43:36 EDT 2006
Author: saraj
Date: Wed Jun 28 04:43:32 2006
New Revision: 7621
Log:
changes made to fix the issue in trac id:1142
Modified:
vtigercrm/trunk/modules/Campaigns/Save.php
Modified: vtigercrm/trunk/modules/Campaigns/Save.php
==============================================================================
--- vtigercrm/trunk/modules/Campaigns/Save.php (original)
+++ vtigercrm/trunk/modules/Campaigns/Save.php Wed Jun 28 04:43:32 2006
@@ -26,8 +26,38 @@
require_once('include/database/PearDatabase.php');
$focus = new Campaign();
+ global $current_user;
+ $currencyid=fetchCurrency($current_user->id);
+ $rate_symbol = getCurrencySymbolandCRate($currencyid);
+ $rate = $rate_symbol['rate'];
+setObjectValuesFromRequest(&$focus);
-setObjectValuesFromRequest(&$focus);
+if(isset($_REQUEST['expectedrevenue']))
+{
+ $value = convertToDollar($_REQUEST['expectedrevenue'],$rate);
+ $focus->column_fields['expectedrevenue'] = $value;
+}
+if(isset($_REQUEST['budgetcost']))
+{
+ $value = convertToDollar($_REQUEST['budgetcost'],$rate);
+ $focus->column_fields['budgetcost'] = $value;
+}
+if(isset($_REQUEST['actualcost']))
+{
+ $value = convertToDollar($_REQUEST['actualcost'],$rate);
+ $focus->column_fields['actualcost'] = $value;
+}
+if(isset($_REQUEST['actualroi']))
+{
+ $value = convertToDollar($_REQUEST['actualroi'],$rate);
+ $focus->column_fields['actualroi'] = $value;
+}
+if(isset($_REQUEST['expectedroi']))
+{
+ $value = convertToDollar($_REQUEST['expectedroi'],$rate);
+ $focus->column_fields['expectedroi'] = $value;
+}
+
$focus->save("Campaigns");
$return_id = $focus->id;
More information about the vtigercrm-commits
mailing list