[ Index ] |
|
Code source de vtiger CRM 5.0.2 |
1 <?php 2 /********************************************************************************* 3 * The contents of this file are subject to the SugarCRM Public License Version 1.1.2 4 * ("License"); You may not use this file except in compliance with the 5 * License. You may obtain a copy of the License at http://www.sugarcrm.com/SPL 6 * Software distributed under the License is distributed on an "AS IS" basis, 7 * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for 8 * the specific language governing rights and limitations under the License. 9 * The Original Code is: SugarCRM Open Source 10 * The Initial Developer of the Original Code is SugarCRM, Inc. 11 * Portions created by SugarCRM are Copyright (C) SugarCRM, Inc.; 12 * All Rights Reserved. 13 * Contributor(s): ______________________________________. 14 ********************************************************************************/ 15 /********************************************************************************* 16 * $Header$ 17 * Description: TODO To be written. 18 * Portions created by SugarCRM are Copyright (C) SugarCRM, Inc. 19 * All Rights Reserved. 20 * Contributor(s): ______________________________________.. 21 ********************************************************************************/ 22 23 require_once ('Smarty_setup.php'); 24 require_once ('data/Tracker.php'); 25 require_once ('modules/Quotes/Quotes.php'); 26 require_once ('include/CustomFieldUtil.php'); 27 require_once ('include/database/PearDatabase.php'); 28 require_once ('include/utils/utils.php'); 29 require_once ('user_privileges/default_module_view.php'); 30 global $mod_strings,$app_strings,$currentModule,$theme,$singlepane_view; 31 $focus = new Quotes(); 32 33 if(isset($_REQUEST['record']) && isset($_REQUEST['record'])) { 34 $focus->retrieve_entity_info($_REQUEST['record'],"Quotes"); 35 $focus->id = $_REQUEST['record']; 36 $focus->name=$focus->column_fields['subject']; 37 } 38 39 if(isset($_REQUEST['isDuplicate']) && $_REQUEST['isDuplicate'] == 'true') { 40 $focus->id = ""; 41 42 } 43 44 $theme_path="themes/".$theme."/"; 45 $image_path=$theme_path."images/"; 46 require_once ($theme_path.'layout_utils.php'); 47 48 $log->info("Quote detail view"); 49 50 $smarty = new vtigerCRM_Smarty; 51 $smarty->assign("MOD", $mod_strings); 52 $smarty->assign("APP", $app_strings); 53 54 $smarty->assign("THEME", $theme); 55 $smarty->assign("IMAGE_PATH", $image_path); 56 $smarty->assign("PRINT_URL", "phprint.php?jt=".session_id().$GLOBALS['request_string']); 57 58 if (isset($focus->name)) $smarty->assign("NAME", $focus->name); 59 else $smarty->assign("NAME", ""); 60 61 $smarty->assign("BLOCKS", getBlocks($currentModule,"detail_view",'',$focus->column_fields)); 62 $smarty->assign("UPDATEINFO",updateInfo($focus->id)); 63 64 $smarty->assign("CUSTOMFIELD", $cust_fld); 65 $smarty->assign("ID", $_REQUEST['record']); 66 $smarty->assign("SINGLE_MOD",'Quote'); 67 $category = getParentTab(); 68 $smarty->assign("CATEGORY",$category); 69 70 if(isPermitted("Quotes","EditView",$_REQUEST['record']) == 'yes') 71 $smarty->assign("EDIT_DUPLICATE","permitted"); 72 73 74 $smarty->assign("CREATEPDF","permitted"); 75 76 if(isPermitted("SalesOrder","EditView",$_REQUEST['record']) == 'yes') 77 $smarty->assign("CONVERTSALESORDER","permitted"); 78 79 if(isPermitted("Invoice","EditView",$_REQUEST['record']) == 'yes') 80 $smarty->assign("CONVERTINVOICE","permitted"); 81 82 if(isPermitted("Quotes","Delete",$_REQUEST['record']) == 'yes') 83 $smarty->assign("DELETE","permitted"); 84 85 86 $smarty->assign("CONVERTMODE",'quotetoinvoice'); 87 $smarty->assign("MODULE", $currentModule); 88 89 //Get the associated Products and then display above Terms and Conditions 90 $smarty->assign("ASSOCIATED_PRODUCTS",getDetailAssociatedProducts('Quotes',$focus)); 91 92 $check_button = Button_Check($module); 93 $smarty->assign("CHECK", $check_button); 94 95 $tabid = getTabid("Quotes"); 96 $validationData = getDBValidationData($focus->tab_name,$tabid); 97 $data = split_validationdataArray($validationData); 98 99 $smarty->assign("VALIDATION_DATA_FIELDNAME",$data['fieldname']); 100 $smarty->assign("VALIDATION_DATA_FIELDDATATYPE",$data['datatype']); 101 $smarty->assign("VALIDATION_DATA_FIELDLABEL",$data['fieldlabel']); 102 $smarty->assign("EDIT_PERMISSION",isPermitted($currentModule,'EditView',$_REQUEST[record])); 103 104 if($singlepane_view == 'true') 105 { 106 $related_array = getRelatedLists($currentModule,$focus); 107 $smarty->assign("RELATEDLISTS", $related_array); 108 } 109 110 $smarty->assign("SinglePane_View", $singlepane_view); 111 112 $smarty->display("Inventory/InventoryDetailView.tpl"); 113 114 ?>
titre
Description
Corps
titre
Description
Corps
titre
Description
Corps
titre
Corps
Généré le : Sun Feb 25 10:22:19 2007 | par Balluche grâce à PHPXref 0.7 |