⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 editview.php

📁 CRM全套解决方案,全部源代码,支持简体中文
💻 PHP
字号:
<?php
if(!defined('sugarEntry') || !sugarEntry) die('Not A Valid Entry Point');
/**
 * The contents of this file are subject to the SugarCRM Community License Version
 * 1.0 ("License"); You may not use this file except in compliance with the
 * License. You may obtain a copy of the License at http://www.sugarcrm.com/S-CL
 * Software distributed under the License is distributed on an "AS IS" basis,
 * WITHOUT WARRANTY OF ANY KIND, either express or implied.  See the License
 * for the specific language governing rights and limitations under the
 * License.
 *
 * All copies of the Covered Code must include on each user interface screen:
 *    (i) the "Powered by SugarCRM" logo and
 *    (ii) the SugarCRM copyright notice
 * in the same form as they appear in the distribution.  See full license for
 * requirements.
 *
 * The Original Code is: SugarCRM Open Source
 * The Initial Developer of the Original Code is SugarCRM, Inc.
 * Portions created by SugarCRM are Copyright (C) 2004-2006 SugarCRM, Inc.;
 * All Rights Reserved.
 * Contributor(s): ______________________________________.
 */

 // $Id: EditView.php,v 1.7.2.1 2006/09/12 00:31:39 majed Exp $

require_once('modules/EditCustomFields/FieldsMetaData.php');

global $app_list_strings, $app_strings, $current_language;
if(empty($_REQUEST['custom_module']))$_REQUEST['custom_module'] = $_SESSION['studio']['module'];
require_once('include/Sugar_Smarty.php');
$custom_field_types = array('varchar' => 'Text', 'text' => 'Text Area','int' => 'Integer', 'float' => 'Decimal',
	 'bool' => 'Checkbox','email'=>'Email', 'enum' => 'Dropdown', 'multienum'=>'Multiple Select', 'radioenum'=>'Radio Buttons', 'date' => 'Date', 'url'=>'Web Link', 'html'=>'HTML');
$smarty = new Sugar_Smarty();
$cf = new FieldsMetaData();
if(!empty($_REQUEST['record'])){
    $cf->retrieve($_REQUEST['record']);
    $custom_module = $cf->custom_module;
    $smarty->assign('NOEDIT','diabled' );
    $old = ob_get_contents();
    ob_clean();
    
require_once($GLOBALS['studioConfig']['dynamicFields'][$cf->data_type]);
    $body = ob_get_contents();
    ob_clean();
    echo $old;
    $smarty->assign('body',$body );
   
}else{
  $custom_module = $_REQUEST['custom_module'];  
}
$smarty->assign('custom_module', $custom_module);

if(empty($_REQUEST['popup'])){
    $smarty->assign('inline', 'inline'); 
    $smarty->assign('popup', '0');  
}else{
    $smarty->assign('popup', '1');
}
$smarty->assign('module_name', $custom_module);
$smarty->assign('cf', $cf );
$smarty->assign('APP', $app_strings);
$smarty->assign('custom_field_types', $custom_field_types);
$edit_mod_strings = return_module_language($current_language, 'EditCustomFields');
$smarty->assign('MOD', $edit_mod_strings);
$my_list_strings = $app_list_strings;
foreach($my_list_strings as $key=>$value){
	if(is_string($value)){
		unset($my_list_strings[$key]);
	}
}
$dropdowns = array_keys($my_list_strings);
sort($dropdowns);
require_once('include/JSON.php');
$json = new JSON(JSON_LOOSE_TYPE);


$smarty->assign('app_list_strings', $json->encode($my_list_strings));
$smarty->display('modules/Studio/EditCustomFields/EditCustomFields.tpl');


?>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -