当前位置: 首页>>代码示例>>PHP>>正文


PHP Vtiger_Util_Helper::formatDateDiffInStrings方法代码示例

本文整理汇总了PHP中Vtiger_Util_Helper::formatDateDiffInStrings方法的典型用法代码示例。如果您正苦于以下问题:PHP Vtiger_Util_Helper::formatDateDiffInStrings方法的具体用法?PHP Vtiger_Util_Helper::formatDateDiffInStrings怎么用?PHP Vtiger_Util_Helper::formatDateDiffInStrings使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Vtiger_Util_Helper的用法示例。


在下文中一共展示了Vtiger_Util_Helper::formatDateDiffInStrings方法的10个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: process

 public function process(Vtiger_Request $request)
 {
     $recordId = $request->get('record');
     $currentUserModel = Users_Record_Model::getCurrentUserModel();
     $request->set('assigned_user_id', $currentUserModel->getId());
     $request->set('userid', $currentUserModel->getId());
     $this->saveRecord($request);
     $recordModel = ModComments_Record_Model::getInstanceById($recordId);
     $result['success'] = true;
     $result['reasontoedit'] = $recordModel->get('reasontoedit');
     $result['commentcontent'] = $recordModel->get('commentcontent');
     $result['modifiedtime'] = Vtiger_Util_Helper::formatDateDiffInStrings($recordModel->get('modifiedtime'));
     $result['modifiedtimetitle'] = Vtiger_Util_Helper::formatDateTimeIntoDayString($recordModel->get('modifiedtime'));
     $response = new Vtiger_Response();
     $response->setEmitType(Vtiger_Response::$EMIT_JSON);
     $response->setResult($result);
     $response->emit();
 }
开发者ID:nouphet,项目名称:vtigercrm-6.0.0-ja,代码行数:18,代码来源:Save.php

示例2: process

 public function process(Vtiger_Request $request)
 {
     $recordId = $request->get('record');
     $currentUserModel = Users_Record_Model::getCurrentUserModel();
     $request->set('assigned_user_id', $currentUserModel->getId());
     $request->set('userid', $currentUserModel->getId());
     $recordModel = $this->saveRecord($request);
     $responseFieldsToSent = array('reasontoedit', 'commentcontent');
     $fieldModelList = $recordModel->getModule()->getFields();
     foreach ($responseFieldsToSent as $fieldName) {
         $fieldModel = $fieldModelList[$fieldName];
         $fieldValue = $recordModel->get($fieldName);
         $result[$fieldName] = $fieldModel->getDisplayValue(Vtiger_Util_Helper::toSafeHTML($fieldValue));
     }
     $result['success'] = true;
     $result['modifiedtime'] = Vtiger_Util_Helper::formatDateDiffInStrings($recordModel->get('modifiedtime'));
     $result['modifiedtimetitle'] = Vtiger_Util_Helper::formatDateTimeIntoDayString($recordModel->get('modifiedtime'));
     $response = new Vtiger_Response();
     $response->setEmitType(Vtiger_Response::$EMIT_JSON);
     $response->setResult($result);
     $response->emit();
 }
开发者ID:Bergdahls,项目名称:YetiForceCRM,代码行数:22,代码来源:Save.php

示例3: if

<?php if ($_valid && !is_callable('content_56059e5e8d482')) {function content_56059e5e8d482($_smarty_tpl) {?>
<?php $_smarty_tpl->tpl_vars["COMMENT_TEXTAREA_DEFAULT_ROWS"] = new Smarty_variable("2", null, 0);?><div class="commentContainer recentComments"><div class="commentTitle row-fluid"><?php if ($_smarty_tpl->tpl_vars['COMMENTS_MODULE_MODEL']->value->isPermitted('EditView')){?><div class="addCommentBlock"><div><textarea name="commentcontent" class="commentcontent"  placeholder="<?php echo vtranslate('LBL_ADD_YOUR_COMMENT_HERE',$_smarty_tpl->tpl_vars['MODULE_NAME']->value);?>
" rows="<?php echo $_smarty_tpl->tpl_vars['COMMENT_TEXTAREA_DEFAULT_ROWS']->value;?>
"></textarea></div><div class="pull-right"><button class="btn btn-success detailViewSaveComment" type="button" data-mode="add"><strong><?php echo vtranslate('LBL_POST',$_smarty_tpl->tpl_vars['MODULE_NAME']->value);?>
</strong></button></div></div><?php }?></div><hr><br><div class="commentsBody"><?php if (!empty($_smarty_tpl->tpl_vars['COMMENTS']->value)){?><?php  $_smarty_tpl->tpl_vars['COMMENT'] = new Smarty_Variable; $_smarty_tpl->tpl_vars['COMMENT']->_loop = false;
 $_smarty_tpl->tpl_vars['index'] = new Smarty_Variable;
 $_from = $_smarty_tpl->tpl_vars['COMMENTS']->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
foreach ($_from as $_smarty_tpl->tpl_vars['COMMENT']->key => $_smarty_tpl->tpl_vars['COMMENT']->value){
$_smarty_tpl->tpl_vars['COMMENT']->_loop = true;
 $_smarty_tpl->tpl_vars['index']->value = $_smarty_tpl->tpl_vars['COMMENT']->key;
?><div class="commentDetails"><div class="commentDiv"><div class="singleComment"><div class="commentInfoHeader row-fluid" data-commentid="<?php echo $_smarty_tpl->tpl_vars['COMMENT']->value->getId();?>
" data-parentcommentid="<?php echo $_smarty_tpl->tpl_vars['COMMENT']->value->get('parent_comments');?>
"><div class="commentTitle"><?php $_smarty_tpl->tpl_vars['PARENT_COMMENT_MODEL'] = new Smarty_variable($_smarty_tpl->tpl_vars['COMMENT']->value->getParentCommentModel(), null, 0);?><?php $_smarty_tpl->tpl_vars['CHILD_COMMENTS_MODEL'] = new Smarty_variable($_smarty_tpl->tpl_vars['COMMENT']->value->getChildComments(), null, 0);?><div class="row-fluid"><div class="span1"><?php $_smarty_tpl->tpl_vars['IMAGE_PATH'] = new Smarty_variable($_smarty_tpl->tpl_vars['COMMENT']->value->getImagePath(), null, 0);?><img class="alignMiddle pull-left" src="<?php if (!empty($_smarty_tpl->tpl_vars['IMAGE_PATH']->value)){?><?php echo $_smarty_tpl->tpl_vars['IMAGE_PATH']->value;?>
<?php }else{ ?><?php echo vimage_path('DefaultUserIcon.png');?>
<?php }?>"></div><div class="span11 commentorInfo"><?php $_smarty_tpl->tpl_vars['COMMENTOR'] = new Smarty_variable($_smarty_tpl->tpl_vars['COMMENT']->value->getCommentedByModel(), null, 0);?><div class="inner"><span class="commentorName"><strong><?php echo $_smarty_tpl->tpl_vars['COMMENTOR']->value->getName();?>
</strong></span><span class="pull-right"><p class="muted"><small title="<?php echo Vtiger_Util_Helper::formatDateTimeIntoDayString($_smarty_tpl->tpl_vars['COMMENT']->value->getCommentedTime());?>
"><?php echo Vtiger_Util_Helper::formatDateDiffInStrings($_smarty_tpl->tpl_vars['COMMENT']->value->getCommentedTime());?>
</small></p></span><div class="clearfix"></div></div><div class="commentInfoContent"><?php echo nl2br($_smarty_tpl->tpl_vars['COMMENT']->value->get('commentcontent'));?>
</div></div></div></div></div><div class="row-fluid commentActionsContainer"><?php $_smarty_tpl->tpl_vars["REASON_TO_EDIT"] = new Smarty_variable($_smarty_tpl->tpl_vars['COMMENT']->value->get('reasontoedit'), null, 0);?><div class="row-fluid editStatus"  name="editStatus"><span class="span6<?php if (empty($_smarty_tpl->tpl_vars['REASON_TO_EDIT']->value)){?> hide<?php }?>"><p class="muted"><small>[ <?php echo vtranslate('LBL_EDIT_REASON',$_smarty_tpl->tpl_vars['MODULE_NAME']->value);?>
 ] :<span  name="editReason" class="textOverflowEllipsis"><?php echo nl2br($_smarty_tpl->tpl_vars['REASON_TO_EDIT']->value);?>
</span></small></p></span><?php if ($_smarty_tpl->tpl_vars['COMMENT']->value->getCommentedTime()!=$_smarty_tpl->tpl_vars['COMMENT']->value->getModifiedTime()){?><span class="<?php if (empty($_smarty_tpl->tpl_vars['REASON_TO_EDIT']->value)){?>row-fluid<?php }else{ ?> span6<?php }?>"><p class="muted pull-right"><small><em><?php echo vtranslate('LBL_MODIFIED',$_smarty_tpl->tpl_vars['MODULE_NAME']->value);?>
</em></small>&nbsp;<small title="<?php echo Vtiger_Util_Helper::formatDateTimeIntoDayString($_smarty_tpl->tpl_vars['COMMENT']->value->getModifiedTime());?>
" class="commentModifiedTime"><?php echo Vtiger_Util_Helper::formatDateDiffInStrings($_smarty_tpl->tpl_vars['COMMENT']->value->getModifiedTime());?>
</small></p></span><?php }?></div><div class="row-fluid"><div class="pull-right commentActions"><?php if ($_smarty_tpl->tpl_vars['COMMENTS_MODULE_MODEL']->value->isPermitted('EditView')){?><span><a class="cursorPointer replyComment feedback"><i class="icon-share-alt"></i><?php echo vtranslate('LBL_REPLY',$_smarty_tpl->tpl_vars['MODULE_NAME']->value);?>
</a><?php if ($_smarty_tpl->tpl_vars['CURRENTUSER']->value->getId()==$_smarty_tpl->tpl_vars['COMMENT']->value->get('userid')){?>&nbsp;<span>|</span>&nbsp;<a class="cursorPointer editComment feedback"><?php echo vtranslate('LBL_EDIT',$_smarty_tpl->tpl_vars['MODULE_NAME']->value);?>
</a><?php }?></span><?php }?><span><?php if ($_smarty_tpl->tpl_vars['PARENT_COMMENT_MODEL']->value!=false||$_smarty_tpl->tpl_vars['CHILD_COMMENTS_MODEL']->value!=null){?><?php if ($_smarty_tpl->tpl_vars['COMMENTS_MODULE_MODEL']->value->isPermitted('EditView')){?>&nbsp;<span>|</span>&nbsp;<?php }?><a href="javascript:void(0);" class="cursorPointer detailViewThread"><?php echo vtranslate('LBL_VIEW_THREAD',$_smarty_tpl->tpl_vars['MODULE_NAME']->value);?>
</a><?php }?></span></div></div></div></div></div></div><?php } ?><?php }else{ ?><?php echo $_smarty_tpl->getSubTemplate (vtemplate_path("NoComments.tpl"), $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, null, null, array(), 0);?>
<?php }?></div><?php if ($_smarty_tpl->tpl_vars['PAGING_MODEL']->value->isNextPageExists()){?><div class="row-fluid"><div class="pull-right"><a href="javascript:void(0)" class="moreRecentComments"><?php echo vtranslate('LBL_MORE',$_smarty_tpl->tpl_vars['MODULE_NAME']->value);?>
..</a></div></div><?php }?><div class="hide basicAddCommentBlock"><div class="row-fluid"><span class="span1">&nbsp;</span><div class="span11"><textarea class="commentcontenthidden fullWidthAlways" name="commentcontent" rows="<?php echo $_smarty_tpl->tpl_vars['COMMENT_TEXTAREA_DEFAULT_ROWS']->value;?>
" placeholder="<?php echo vtranslate('LBL_ADD_YOUR_COMMENT_HERE',$_smarty_tpl->tpl_vars['MODULE_NAME']->value);?>
"></textarea></div></div><div class="pull-right"><button class="btn btn-success detailViewSaveComment" type="button" data-mode="add"><strong><?php echo vtranslate('LBL_POST',$_smarty_tpl->tpl_vars['MODULE_NAME']->value);?>
</strong></button><a class="cursorPointer closeCommentBlock cancelLink" type="reset"><?php echo vtranslate('LBL_CANCEL',$_smarty_tpl->tpl_vars['MODULE_NAME']->value);?>
</a></div></div><div class="hide basicEditCommentBlock" style="min-height: 150px;"><div class="row-fluid"><span class="span1">&nbsp;</span><div class="span11"><input type="text" name="reasonToEdit" placeholder="<?php echo vtranslate('LBL_REASON_FOR_CHANGING_COMMENT',$_smarty_tpl->tpl_vars['MODULE_NAME']->value);?>
" class="input-block-level"/></div></div><div class="row-fluid"><span class="span1">&nbsp;</span><div class="span11"><textarea class="commentcontenthidden fullWidthAlways" name="commentcontent" rows="<?php echo $_smarty_tpl->tpl_vars['COMMENT_TEXTAREA_DEFAULT_ROWS']->value;?>
"></textarea></div></div><div class="pull-right"><button class="btn btn-success detailViewSaveComment" type="button" data-mode="edit"><strong><?php echo vtranslate('LBL_POST',$_smarty_tpl->tpl_vars['MODULE_NAME']->value);?>
</strong></button><a class="cursorPointer closeCommentBlock cancelLink" type="reset"><?php echo vtranslate('LBL_CANCEL',$_smarty_tpl->tpl_vars['MODULE_NAME']->value);?>
</a></div></div></div><?php }} ?>
开发者ID:jeremyevans6,项目名称:kulturedTiger-,代码行数:37,代码来源:2ac54a29a490d776ade24d3f61ee7d3869b7ec24.file.RecentComments.tpl.php

示例4: if

<?php if ($_valid && !is_callable('content_56059e5eb6b1a')) {function content_56059e5eb6b1a($_smarty_tpl) {?>
<div class="recentActivitiesContainer" id="updates"><input type="hidden" id="updatesCurrentPage" value="<?php echo $_smarty_tpl->tpl_vars['PAGING_MODEL']->value->get('page');?>
" /><div><?php if (!empty($_smarty_tpl->tpl_vars['RECENT_ACTIVITIES']->value)){?><ul class="unstyled"><?php  $_smarty_tpl->tpl_vars['RECENT_ACTIVITY'] = new Smarty_Variable; $_smarty_tpl->tpl_vars['RECENT_ACTIVITY']->_loop = false;
 $_from = $_smarty_tpl->tpl_vars['RECENT_ACTIVITIES']->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
foreach ($_from as $_smarty_tpl->tpl_vars['RECENT_ACTIVITY']->key => $_smarty_tpl->tpl_vars['RECENT_ACTIVITY']->value){
$_smarty_tpl->tpl_vars['RECENT_ACTIVITY']->_loop = true;
?><?php $_smarty_tpl->tpl_vars['PROCEED'] = new Smarty_variable(true, null, 0);?><?php if (($_smarty_tpl->tpl_vars['RECENT_ACTIVITY']->value->isRelationLink())||($_smarty_tpl->tpl_vars['RECENT_ACTIVITY']->value->isRelationUnLink())){?><?php $_smarty_tpl->tpl_vars['RELATION'] = new Smarty_variable($_smarty_tpl->tpl_vars['RECENT_ACTIVITY']->value->getRelationInstance(), null, 0);?><?php if (!($_smarty_tpl->tpl_vars['RELATION']->value->getLinkedRecord())){?><?php $_smarty_tpl->tpl_vars['PROCEED'] = new Smarty_variable(false, null, 0);?><?php }?><?php }?><?php if ($_smarty_tpl->tpl_vars['PROCEED']->value){?><?php if ($_smarty_tpl->tpl_vars['RECENT_ACTIVITY']->value->isCreate()){?><li><div><span><strong><?php echo $_smarty_tpl->tpl_vars['RECENT_ACTIVITY']->value->getModifiedBy()->getName();?>
</strong> <?php echo vtranslate('LBL_CREATED',$_smarty_tpl->tpl_vars['MODULE_NAME']->value);?>
</span><span class="pull-right"><p class="muted"><small title="<?php echo Vtiger_Util_Helper::formatDateTimeIntoDayString($_smarty_tpl->tpl_vars['RECENT_ACTIVITY']->value->getParent()->get('createdtime'));?>
"><?php echo Vtiger_Util_Helper::formatDateDiffInStrings($_smarty_tpl->tpl_vars['RECENT_ACTIVITY']->value->getParent()->get('createdtime'));?>
</small></p></span></div></li><?php }elseif($_smarty_tpl->tpl_vars['RECENT_ACTIVITY']->value->isUpdate()){?><li><div><span><strong><?php echo $_smarty_tpl->tpl_vars['RECENT_ACTIVITY']->value->getModifiedBy()->getDisplayName();?>
</strong> <?php echo vtranslate('LBL_UPDATED',$_smarty_tpl->tpl_vars['MODULE_NAME']->value);?>
</span><span class="pull-right"><p class="muted"><small title="<?php echo Vtiger_Util_Helper::formatDateTimeIntoDayString($_smarty_tpl->tpl_vars['RECENT_ACTIVITY']->value->getActivityTime());?>
"><?php echo Vtiger_Util_Helper::formatDateDiffInStrings($_smarty_tpl->tpl_vars['RECENT_ACTIVITY']->value->getActivityTime());?>
</small></p></span></div><?php  $_smarty_tpl->tpl_vars['FIELDMODEL'] = new Smarty_Variable; $_smarty_tpl->tpl_vars['FIELDMODEL']->_loop = false;
 $_from = $_smarty_tpl->tpl_vars['RECENT_ACTIVITY']->value->getFieldInstances(); if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
foreach ($_from as $_smarty_tpl->tpl_vars['FIELDMODEL']->key => $_smarty_tpl->tpl_vars['FIELDMODEL']->value){
$_smarty_tpl->tpl_vars['FIELDMODEL']->_loop = true;
?><?php if ($_smarty_tpl->tpl_vars['FIELDMODEL']->value&&$_smarty_tpl->tpl_vars['FIELDMODEL']->value->getFieldInstance()&&$_smarty_tpl->tpl_vars['FIELDMODEL']->value->getFieldInstance()->isViewable()&&$_smarty_tpl->tpl_vars['FIELDMODEL']->value->getFieldInstance()->getDisplayType()!='5'){?><div class='font-x-small updateInfoContainer'><i><?php echo vtranslate($_smarty_tpl->tpl_vars['FIELDMODEL']->value->getName(),$_smarty_tpl->tpl_vars['MODULE_NAME']->value);?>
</i> :&nbsp;<?php if ($_smarty_tpl->tpl_vars['FIELDMODEL']->value->get('prevalue')!=''&&$_smarty_tpl->tpl_vars['FIELDMODEL']->value->get('postvalue')!=''&&!($_smarty_tpl->tpl_vars['FIELDMODEL']->value->getFieldInstance()->getFieldDataType()=='reference'&&($_smarty_tpl->tpl_vars['FIELDMODEL']->value->get('postvalue')=='0'||$_smarty_tpl->tpl_vars['FIELDMODEL']->value->get('prevalue')=='0'))){?>&nbsp;<?php echo vtranslate('LBL_FROM');?>
 <b style="white-space:pre;"><?php echo Vtiger_Util_Helper::toVtiger6SafeHTML($_smarty_tpl->tpl_vars['FIELDMODEL']->value->getDisplayValue(decode_html($_smarty_tpl->tpl_vars['FIELDMODEL']->value->get('prevalue'))));?>
</b><?php }elseif($_smarty_tpl->tpl_vars['FIELDMODEL']->value->get('postvalue')==''||($_smarty_tpl->tpl_vars['FIELDMODEL']->value->getFieldInstance()->getFieldDataType()=='reference'&&$_smarty_tpl->tpl_vars['FIELDMODEL']->value->get('postvalue')=='0')){?>&nbsp; <b> <?php echo vtranslate('LBL_DELETED');?>
 </b> ( <del><?php echo Vtiger_Util_Helper::toVtiger6SafeHTML($_smarty_tpl->tpl_vars['FIELDMODEL']->value->getDisplayValue(decode_html($_smarty_tpl->tpl_vars['FIELDMODEL']->value->get('prevalue'))));?>
</del> )<?php }else{ ?>&nbsp;<?php echo vtranslate('LBL_CHANGED');?>
<?php }?><?php if ($_smarty_tpl->tpl_vars['FIELDMODEL']->value->get('postvalue')!=''&&!($_smarty_tpl->tpl_vars['FIELDMODEL']->value->getFieldInstance()->getFieldDataType()=='reference'&&$_smarty_tpl->tpl_vars['FIELDMODEL']->value->get('postvalue')=='0')){?>&nbsp;<?php echo vtranslate('LBL_TO');?>
&nbsp;<b style="white-space:pre;"><?php echo Vtiger_Util_Helper::toVtiger6SafeHTML($_smarty_tpl->tpl_vars['FIELDMODEL']->value->getDisplayValue(decode_html($_smarty_tpl->tpl_vars['FIELDMODEL']->value->get('postvalue'))));?>
</b><?php }?></div><?php }?><?php } ?></li><?php }elseif(($_smarty_tpl->tpl_vars['RECENT_ACTIVITY']->value->isRelationLink()||$_smarty_tpl->tpl_vars['RECENT_ACTIVITY']->value->isRelationUnLink())){?><li><div class="row-fluid"><?php $_smarty_tpl->tpl_vars['RELATION'] = new Smarty_variable($_smarty_tpl->tpl_vars['RECENT_ACTIVITY']->value->getRelationInstance(), null, 0);?><span><?php echo vtranslate($_smarty_tpl->tpl_vars['RELATION']->value->getLinkedRecord()->getModuleName(),$_smarty_tpl->tpl_vars['RELATION']->value->getLinkedRecord()->getModuleName());?>
</span> <span><?php if ($_smarty_tpl->tpl_vars['RECENT_ACTIVITY']->value->isRelationLink()){?><?php echo vtranslate('LBL_ADDED',$_smarty_tpl->tpl_vars['MODULE_NAME']->value);?>
<?php }else{ ?><?php echo vtranslate('LBL_REMOVED',$_smarty_tpl->tpl_vars['MODULE_NAME']->value);?>
<?php }?> </span><span><?php if ($_smarty_tpl->tpl_vars['RELATION']->value->getLinkedRecord()->getModuleName()=='Calendar'){?><?php if (isPermitted('Calendar','DetailView',$_smarty_tpl->tpl_vars['RELATION']->value->getLinkedRecord()->getId())=='yes'){?> <strong><?php echo $_smarty_tpl->tpl_vars['RELATION']->value->getLinkedRecord()->getName();?>
</strong> <?php }else{ ?> <?php }?><?php }else{ ?> <strong><?php echo $_smarty_tpl->tpl_vars['RELATION']->value->getLinkedRecord()->getName();?>
</strong> <?php }?></span><span class="pull-right"><p class="muted"><small title="<?php echo Vtiger_Util_Helper::formatDateTimeIntoDayString($_smarty_tpl->tpl_vars['RELATION']->value->get('changedon'));?>
"><?php echo Vtiger_Util_Helper::formatDateDiffInStrings($_smarty_tpl->tpl_vars['RELATION']->value->get('changedon'));?>
</small></p></span></div></li><?php }elseif($_smarty_tpl->tpl_vars['RECENT_ACTIVITY']->value->isRestore()){?><li></li><?php }?><?php }?><?php } ?></ul><?php }else{ ?><div class="summaryWidgetContainer"><p class="textAlignCenter"><?php echo vtranslate('LBL_NO_RECENT_UPDATES');?>
</p></div><?php }?></div><div class="row-fluid" id="moreLink"><?php if ($_smarty_tpl->tpl_vars['PAGING_MODEL']->value->isNextPageExists()){?><div class="pull-right"><a href="javascript:void(0)" class="moreRecentUpdates"><?php echo vtranslate('LBL_MORE',$_smarty_tpl->tpl_vars['MODULE_NAME']->value);?>
..</a></div><?php }?></div><span class="clearfix"></span></div><?php }} ?>
开发者ID:jeremyevans6,项目名称:kulturedTiger-,代码行数:36,代码来源:b354b6e8498540a842ac3bb61a4b6d1bab66eff5.file.RecentActivities.tpl.php

示例5: content_56755f20e4998

    function content_56755f20e4998($_smarty_tpl)
    {
        ?>

<div style='padding:5px;'>
<?php 
        if ($_smarty_tpl->tpl_vars['HISTORIES']->value != false) {
            ?>
	<?php 
            $_smarty_tpl->tpl_vars['HISTORY'] = new Smarty_Variable();
            $_smarty_tpl->tpl_vars['HISTORY']->_loop = false;
            $_smarty_tpl->tpl_vars[$_smarty_tpl->tpl_vars['index']->value] = new Smarty_Variable();
            $_from = $_smarty_tpl->tpl_vars['HISTORIES']->value;
            if (!is_array($_from) && !is_object($_from)) {
                settype($_from, 'array');
            }
            foreach ($_from as $_smarty_tpl->tpl_vars['HISTORY']->key => $_smarty_tpl->tpl_vars['HISTORY']->value) {
                $_smarty_tpl->tpl_vars['HISTORY']->_loop = true;
                $_smarty_tpl->tpl_vars[$_smarty_tpl->tpl_vars['index']->value]->value = $_smarty_tpl->tpl_vars['HISTORY']->key;
                ?>
		<?php 
                $_smarty_tpl->tpl_vars['MODELNAME'] = new Smarty_variable(get_class($_smarty_tpl->tpl_vars['HISTORY']->value), null, 0);
                ?>
		<?php 
                if ($_smarty_tpl->tpl_vars['MODELNAME']->value == 'ModTracker_Record_Model') {
                    ?>
			<?php 
                    $_smarty_tpl->tpl_vars['USER'] = new Smarty_variable($_smarty_tpl->tpl_vars['HISTORY']->value->getModifiedBy(), null, 0);
                    ?>
			<?php 
                    $_smarty_tpl->tpl_vars['TIME'] = new Smarty_variable($_smarty_tpl->tpl_vars['HISTORY']->value->getActivityTime(), null, 0);
                    ?>
			<?php 
                    $_smarty_tpl->tpl_vars['PARENT'] = new Smarty_variable($_smarty_tpl->tpl_vars['HISTORY']->value->getParent(), null, 0);
                    ?>
			<?php 
                    $_smarty_tpl->tpl_vars['MOD_NAME'] = new Smarty_variable($_smarty_tpl->tpl_vars['HISTORY']->value->getParent()->getModule()->getName(), null, 0);
                    ?>
			<?php 
                    $_smarty_tpl->tpl_vars['SINGLE_MODULE_NAME'] = new Smarty_variable('SINGLE_' . $_smarty_tpl->tpl_vars['MOD_NAME']->value, null, 0);
                    ?>
			<?php 
                    $_smarty_tpl->tpl_vars['TRANSLATED_MODULE_NAME'] = new Smarty_variable(vtranslate($_smarty_tpl->tpl_vars['SINGLE_MODULE_NAME']->value, $_smarty_tpl->tpl_vars['MOD_NAME']->value), null, 0);
                    ?>
			<?php 
                    $_smarty_tpl->tpl_vars['PROCEED'] = new Smarty_variable(true, null, 0);
                    ?>
			<?php 
                    if ($_smarty_tpl->tpl_vars['HISTORY']->value->isRelationLink() || $_smarty_tpl->tpl_vars['HISTORY']->value->isRelationUnLink()) {
                        ?>
				<?php 
                        $_smarty_tpl->tpl_vars['RELATION'] = new Smarty_variable($_smarty_tpl->tpl_vars['HISTORY']->value->getRelationInstance(), null, 0);
                        ?>
				<?php 
                        if (!$_smarty_tpl->tpl_vars['RELATION']->value->getLinkedRecord()) {
                            ?>
					<?php 
                            $_smarty_tpl->tpl_vars['PROCEED'] = new Smarty_variable(false, null, 0);
                            ?>
				<?php 
                        }
                        ?>
			<?php 
                    }
                    ?>
			<?php 
                    if ($_smarty_tpl->tpl_vars['PROCEED']->value) {
                        ?>
				<div class="row-fluid">
					<div class='span1'>
						<img width='24px' src="<?php 
                        echo vimage_path($_smarty_tpl->tpl_vars['MOD_NAME']->value . '.png');
                        ?>
" alt="<?php 
                        echo $_smarty_tpl->tpl_vars['TRANSLATED_MODULE_NAME']->value;
                        ?>
" title="<?php 
                        echo $_smarty_tpl->tpl_vars['TRANSLATED_MODULE_NAME']->value;
                        ?>
" />&nbsp;&nbsp;
					</div>
					<div class="span11">
					<p class="pull-right muted" style="padding-right:5px;"><small title="<?php 
                        echo Vtiger_Util_Helper::formatDateTimeIntoDayString($_smarty_tpl->tpl_vars['TIME']->value);
                        ?>
"><?php 
                        echo Vtiger_Util_Helper::formatDateDiffInStrings($_smarty_tpl->tpl_vars['TIME']->value);
                        ?>
</small></p>
					<?php 
                        $_smarty_tpl->tpl_vars['DETAILVIEW_URL'] = new Smarty_variable($_smarty_tpl->tpl_vars['PARENT']->value->getDetailViewUrl(), null, 0);
                        ?>
					<?php 
                        if ($_smarty_tpl->tpl_vars['HISTORY']->value->isUpdate()) {
                            ?>
						<?php 
                            $_smarty_tpl->tpl_vars['FIELDS'] = new Smarty_variable($_smarty_tpl->tpl_vars['HISTORY']->value->getFieldInstances(), null, 0);
                            ?>
						<div class="">
							<div><b><?php 
//.........这里部分代码省略.........
开发者ID:wsLapshin,项目名称:charter_crm,代码行数:101,代码来源:a72af05502cac98ba965300c8dd337c49ae3582c.file.HistoryContents.tpl.php

示例6: content_5694bd75b115c

    function content_5694bd75b115c($_smarty_tpl)
    {
        ?>

<div>
	<?php 
        $_smarty_tpl->tpl_vars['ACTIVITY'] = new Smarty_Variable();
        $_smarty_tpl->tpl_vars['ACTIVITY']->_loop = false;
        $_smarty_tpl->tpl_vars['INDEX'] = new Smarty_Variable();
        $_from = $_smarty_tpl->tpl_vars['ACTIVITIES']->value;
        if (!is_array($_from) && !is_object($_from)) {
            settype($_from, 'array');
        }
        foreach ($_from as $_smarty_tpl->tpl_vars['ACTIVITY']->key => $_smarty_tpl->tpl_vars['ACTIVITY']->value) {
            $_smarty_tpl->tpl_vars['ACTIVITY']->_loop = true;
            $_smarty_tpl->tpl_vars['INDEX']->value = $_smarty_tpl->tpl_vars['ACTIVITY']->key;
            ?>
	<div>
		<div class='pull-left'>
			<?php 
            if ($_smarty_tpl->tpl_vars['ACTIVITY']->value->get('activitytype') == 'Task') {
                ?>
				<image src="<?php 
                echo vimage_path('Tasks.png');
                ?>
" width="24px"/>&nbsp;&nbsp;
			<?php 
            } else {
                ?>
				<image src="<?php 
                echo vimage_path('Calendar.png');
                ?>
" width="24px" />&nbsp;&nbsp;
			<?php 
            }
            ?>
		</div>
		<div>
			<div class='pull-left' style='margin-top:5px'>
				<?php 
            $_smarty_tpl->tpl_vars['PARENT_ID'] = new Smarty_variable($_smarty_tpl->tpl_vars['ACTIVITY']->value->get('parent_id'), null, 0);
            ?>
				<?php 
            $_smarty_tpl->tpl_vars['CONTACT_ID'] = new Smarty_variable($_smarty_tpl->tpl_vars['ACTIVITY']->value->get('contact_id'), null, 0);
            ?>
				<a href="<?php 
            echo $_smarty_tpl->tpl_vars['ACTIVITY']->value->getDetailViewUrl();
            ?>
"><?php 
            echo $_smarty_tpl->tpl_vars['ACTIVITY']->value->get('subject');
            ?>
</a><?php 
            if ($_smarty_tpl->tpl_vars['PARENT_ID']->value) {
                ?>
 <?php 
                echo vtranslate('LBL_FOR');
                ?>
 <?php 
                echo $_smarty_tpl->tpl_vars['ACTIVITY']->value->getDisplayValue('parent_id');
            } elseif ($_smarty_tpl->tpl_vars['CONTACT_ID']->value) {
                ?>
 <?php 
                echo vtranslate('LBL_FOR');
                ?>
 <?php 
                echo $_smarty_tpl->tpl_vars['ACTIVITY']->value->getDisplayValue('contact_id');
            }
            ?>
			</div>
				<?php 
            $_smarty_tpl->tpl_vars['START_DATE'] = new Smarty_variable($_smarty_tpl->tpl_vars['ACTIVITY']->value->get('date_start'), null, 0);
            ?>
				<?php 
            $_smarty_tpl->tpl_vars['START_TIME'] = new Smarty_variable($_smarty_tpl->tpl_vars['ACTIVITY']->value->get('time_start'), null, 0);
            ?>
				
				<?php 
            $_smarty_tpl->tpl_vars['DUE_DATE'] = new Smarty_variable($_smarty_tpl->tpl_vars['ACTIVITY']->value->get('due_date'), null, 0);
            ?>
				<?php 
            $_smarty_tpl->tpl_vars['DUE_TIME'] = new Smarty_variable($_smarty_tpl->tpl_vars['ACTIVITY']->value->get('time_end'), null, 0);
            ?>
			<p class='pull-right muted' style='margin-top:5px;padding-right:5px;'><small title="<?php 
            echo Vtiger_Util_Helper::formatDateTimeIntoDayString($_smarty_tpl->tpl_vars['START_DATE']->value . " " . $_smarty_tpl->tpl_vars['START_TIME']->value);
            ?>
 <?php 
            echo vtranslate('LBL_TO');
            ?>
 <?php 
            echo Vtiger_Util_Helper::formatDateTimeIntoDayString($_smarty_tpl->tpl_vars['DUE_DATE']->value . " " . $_smarty_tpl->tpl_vars['DUE_TIME']->value);
            ?>
"><?php 
            echo Vtiger_Util_Helper::formatDateDiffInStrings($_smarty_tpl->tpl_vars['START_DATE']->value . " " . $_smarty_tpl->tpl_vars['START_TIME']->value);
            ?>
</small></p>
			<div class='clearfix'></div>
		</div>
		<div class='clearfix'></div>
	</div>
	<?php 
//.........这里部分代码省略.........
开发者ID:cin-system,项目名称:vtigercrm-cin,代码行数:101,代码来源:cf26ad1562d7c0798ba55f493f21af90d88383be.file.CalendarActivitiesContents.tpl.php

示例7: content_558c2a3b64ff1

    function content_558c2a3b64ff1($_smarty_tpl)
    {
        ?>
<hr>
<div class="commentDiv cursorPointer">
	<div class="singleComment">
		<div class="commentInfoHeader row-fluid"  data-commentid="<?php 
        echo $_smarty_tpl->tpl_vars['COMMENT']->value->getId();
        ?>
" data-parentcommentid="<?php 
        echo $_smarty_tpl->tpl_vars['COMMENT']->value->get('parent_comments');
        ?>
">
			<div class="commentTitle" id="<?php 
        echo $_smarty_tpl->tpl_vars['COMMENT']->value->getId();
        ?>
">
				<?php 
        $_smarty_tpl->tpl_vars['PARENT_COMMENT_MODEL'] = new Smarty_variable($_smarty_tpl->tpl_vars['COMMENT']->value->getParentCommentModel(), null, 0);
        ?>
				<?php 
        $_smarty_tpl->tpl_vars['CHILD_COMMENTS_MODEL'] = new Smarty_variable($_smarty_tpl->tpl_vars['COMMENT']->value->getChildComments(), null, 0);
        ?>
				<div class="row-fluid">
					<div class="span1">
						<?php 
        $_smarty_tpl->tpl_vars['IMAGE_PATH'] = new Smarty_variable($_smarty_tpl->tpl_vars['COMMENT']->value->getImagePath(), null, 0);
        ?>
						<img class="alignMiddle pull-left" src="<?php 
        if (!empty($_smarty_tpl->tpl_vars['IMAGE_PATH']->value)) {
            echo $_smarty_tpl->tpl_vars['IMAGE_PATH']->value;
        } else {
            echo vimage_path('DefaultUserIcon.png');
        }
        ?>
">
					</div>
					<div class="span11 commentorInfo">
						<?php 
        $_smarty_tpl->tpl_vars['COMMENTOR'] = new Smarty_variable($_smarty_tpl->tpl_vars['COMMENT']->value->getCommentedByModel(), null, 0);
        ?>
						<div class="inner">
							<span class="commentorName pull-left"><strong><?php 
        echo $_smarty_tpl->tpl_vars['COMMENTOR']->value->getName();
        ?>
</strong></span>
							<span class="pull-right">
								<p class="muted"><em><?php 
        echo vtranslate('LBL_COMMENTED', $_smarty_tpl->tpl_vars['MODULE_NAME']->value);
        ?>
</em>&nbsp;<small title="<?php 
        echo Vtiger_Util_Helper::formatDateTimeIntoDayString($_smarty_tpl->tpl_vars['COMMENT']->value->getCommentedTime());
        ?>
" class="commentModifiedTime"><?php 
        echo Vtiger_Util_Helper::formatDateDiffInStrings($_smarty_tpl->tpl_vars['COMMENT']->value->getCommentedTime());
        ?>
</small></p>
							</span>
							<div class="clearfix"></div>
						</div>
						<div class="commentInfoContent">
							<?php 
        echo nl2br($_smarty_tpl->tpl_vars['COMMENT']->value->get('commentcontent'));
        ?>

						</div>
					</div>
				</div>
			</div>
		</div>
		<div class="row-fluid commentActionsContainer">
			<div class="row-fluid commentActionsDiv">
				<span class="pull-right commentActions">
					<?php 
        $_smarty_tpl->tpl_vars['CHILD_COMMENTS_COUNT'] = new Smarty_variable($_smarty_tpl->tpl_vars['COMMENT']->value->getChildCommentsCount(), null, 0);
        ?>
					<span>
						<a class="cursorPointer replyComment">
							<i class="icon-share-alt"></i>
							<?php 
        echo vtranslate('LBL_REPLY', $_smarty_tpl->tpl_vars['MODULE_NAME']->value);
        ?>

						</a>
						<?php 
        if ($_smarty_tpl->tpl_vars['CURRENTUSER']->value->getId() == $_smarty_tpl->tpl_vars['COMMENT']->value->get('userid')) {
            ?>
							&nbsp;<span style="color:black">|</span>&nbsp;
							<a class="cursorPointer editComment feedback">
								<?php 
            echo vtranslate('LBL_EDIT', $_smarty_tpl->tpl_vars['MODULE_NAME']->value);
            ?>

							</a>
						<?php 
        }
        ?>
					</span>
					<?php 
        if ($_smarty_tpl->tpl_vars['CHILD_COMMENTS_COUNT']->value != 0) {
//.........这里部分代码省略.........
开发者ID:jmangarret,项目名称:vtigercrm,代码行数:101,代码来源:402d894b13d6ab24dafd05fcd481253d488d8e32.file.CommentThreadList.tpl.php

示例8: content_5658a646f171d

    function content_5658a646f171d($_smarty_tpl)
    {
        ?>
<div class="recentActivitiesContainer"><div><?php 
        if (!empty($_smarty_tpl->tpl_vars['RECENT_ACTIVITIES']->value)) {
            ?>
<ul class="unstyled"><?php 
            $_smarty_tpl->tpl_vars['RECENT_ACTIVITY'] = new Smarty_Variable();
            $_smarty_tpl->tpl_vars['RECENT_ACTIVITY']->_loop = false;
            $_from = $_smarty_tpl->tpl_vars['RECENT_ACTIVITIES']->value;
            if (!is_array($_from) && !is_object($_from)) {
                settype($_from, 'array');
            }
            foreach ($_from as $_smarty_tpl->tpl_vars['RECENT_ACTIVITY']->key => $_smarty_tpl->tpl_vars['RECENT_ACTIVITY']->value) {
                $_smarty_tpl->tpl_vars['RECENT_ACTIVITY']->_loop = true;
                if ($_smarty_tpl->tpl_vars['RECENT_ACTIVITY']->value->isCreate()) {
                    ?>
<li><div><span><strong><?php 
                    echo $_smarty_tpl->tpl_vars['RECENT_ACTIVITY']->value->getModifiedBy()->getName();
                    ?>
</strong> <?php 
                    echo vtranslate('LBL_CREATED', $_smarty_tpl->tpl_vars['MODULE_NAME']->value);
                    ?>
</span><span class="pull-right"><p class="muted"><small title="<?php 
                    echo Vtiger_Util_Helper::formatDateTimeIntoDayString($_smarty_tpl->tpl_vars['RECENT_ACTIVITY']->value->getParent()->get('createdtime'));
                    ?>
"><?php 
                    echo Vtiger_Util_Helper::formatDateDiffInStrings($_smarty_tpl->tpl_vars['RECENT_ACTIVITY']->value->getParent()->get('createdtime'));
                    ?>
</small></p></span></div></li><?php 
                } elseif ($_smarty_tpl->tpl_vars['RECENT_ACTIVITY']->value->isUpdate()) {
                    ?>
<li><div><span><strong><?php 
                    echo $_smarty_tpl->tpl_vars['RECENT_ACTIVITY']->value->getModifiedBy()->getDisplayName();
                    ?>
</strong> <?php 
                    echo vtranslate('LBL_UPDATED', $_smarty_tpl->tpl_vars['MODULE_NAME']->value);
                    ?>
</span><span class="pull-right"><p class="muted"><small title="<?php 
                    echo Vtiger_Util_Helper::formatDateTimeIntoDayString($_smarty_tpl->tpl_vars['RECENT_ACTIVITY']->value->getActivityTime());
                    ?>
"><?php 
                    echo Vtiger_Util_Helper::formatDateDiffInStrings($_smarty_tpl->tpl_vars['RECENT_ACTIVITY']->value->getActivityTime());
                    ?>
</small></p></span></div><?php 
                    $_smarty_tpl->tpl_vars['FIELDMODEL'] = new Smarty_Variable();
                    $_smarty_tpl->tpl_vars['FIELDMODEL']->_loop = false;
                    $_from = $_smarty_tpl->tpl_vars['RECENT_ACTIVITY']->value->getFieldInstances();
                    if (!is_array($_from) && !is_object($_from)) {
                        settype($_from, 'array');
                    }
                    foreach ($_from as $_smarty_tpl->tpl_vars['FIELDMODEL']->key => $_smarty_tpl->tpl_vars['FIELDMODEL']->value) {
                        $_smarty_tpl->tpl_vars['FIELDMODEL']->_loop = true;
                        if ($_smarty_tpl->tpl_vars['FIELDMODEL']->value && $_smarty_tpl->tpl_vars['FIELDMODEL']->value->getFieldInstance() && $_smarty_tpl->tpl_vars['FIELDMODEL']->value->getFieldInstance()->isViewableInDetailView()) {
                            ?>
<div class='font-x-small updateInfoContainer'><i><?php 
                            echo vtranslate($_smarty_tpl->tpl_vars['FIELDMODEL']->value->getName(), $_smarty_tpl->tpl_vars['MODULE_NAME']->value);
                            ?>
</i> :&nbsp;<?php 
                            if ($_smarty_tpl->tpl_vars['FIELDMODEL']->value->get('prevalue') != '') {
                                echo $_smarty_tpl->tpl_vars['FIELDMODEL']->value->getDisplayValue($_smarty_tpl->tpl_vars['FIELDMODEL']->value->get('prevalue'));
                                ?>
&nbsp;<?php 
                                echo vtranslate('LBL_TO', $_smarty_tpl->tpl_vars['MODULE_NAME']->value);
                                ?>
&nbsp;<?php 
                            } else {
                            }
                            ?>
<b><?php 
                            echo $_smarty_tpl->tpl_vars['FIELDMODEL']->value->getDisplayValue($_smarty_tpl->tpl_vars['FIELDMODEL']->value->get('postvalue'));
                            ?>
</b></div><?php 
                        }
                    }
                    ?>
</li><?php 
                } elseif ($_smarty_tpl->tpl_vars['RECENT_ACTIVITY']->value->isRelationLink()) {
                    ?>
<li><div class="row-fluid"><?php 
                    $_smarty_tpl->tpl_vars['RELATION'] = new Smarty_variable($_smarty_tpl->tpl_vars['RECENT_ACTIVITY']->value->getRelationInstance(), null, 0);
                    ?>
<span><?php 
                    echo vtranslate($_smarty_tpl->tpl_vars['RELATION']->value->getLinkedRecord()->getModuleName(), $_smarty_tpl->tpl_vars['RELATION']->value->getLinkedRecord()->getModuleName());
                    ?>
 <?php 
                    echo vtranslate('LBL_ADDED', $_smarty_tpl->tpl_vars['MODULE_NAME']->value);
                    ?>
 <strong><?php 
                    echo $_smarty_tpl->tpl_vars['RELATION']->value->getLinkedRecord()->getName();
                    ?>
</strong></span><span class="pull-right"><p class="muted"><small title="<?php 
                    echo Vtiger_Util_Helper::formatDateTimeIntoDayString($_smarty_tpl->tpl_vars['RELATION']->value->getLinkedRecord()->get('createdtime'));
                    ?>
"><?php 
                    echo Vtiger_Util_Helper::formatDateDiffInStrings($_smarty_tpl->tpl_vars['RELATION']->value->getLinkedRecord()->get('createdtime'));
                    ?>
</small></p></span></div></li><?php 
                } elseif ($_smarty_tpl->tpl_vars['RECENT_ACTIVITY']->value->isRelationUnLink()) {
                    ?>
//.........这里部分代码省略.........
开发者ID:jmangarret,项目名称:vtigercrm,代码行数:101,代码来源:2d0a137ab674e037b5aa10e338fa6748f623f193.file.RecentActivities.tpl.php

示例9: content_566fa284bf8b1

    function content_566fa284bf8b1($_smarty_tpl)
    {
        $_smarty_tpl->tpl_vars['jsModel'] = new Smarty_Variable();
        $_smarty_tpl->tpl_vars['jsModel']->_loop = false;
        $_smarty_tpl->tpl_vars['index'] = new Smarty_Variable();
        $_from = $_smarty_tpl->tpl_vars['SCRIPTS']->value;
        if (!is_array($_from) && !is_object($_from)) {
            settype($_from, 'array');
        }
        foreach ($_from as $_smarty_tpl->tpl_vars['jsModel']->key => $_smarty_tpl->tpl_vars['jsModel']->value) {
            $_smarty_tpl->tpl_vars['jsModel']->_loop = true;
            $_smarty_tpl->tpl_vars['index']->value = $_smarty_tpl->tpl_vars['jsModel']->key;
            ?>
	<script type="<?php 
            echo $_smarty_tpl->tpl_vars['jsModel']->value->getType();
            ?>
" src="<?php 
            echo $_smarty_tpl->tpl_vars['jsModel']->value->getSrc();
            ?>
"></script>
<?php 
        }
        ?>
<div id = 'sync_message' class='row-fluid' >
    <div class='padding10 span12'>     
        <?php 
        if ($_smarty_tpl->tpl_vars['FIRSTTIME']->value) {
            ?>
            <input type="hidden" id = "firsttime" value = 'no'/>
        <?php 
        } else {
            ?>
            <input type="hidden" id = "firsttime" value = 'yes'/>
        <?php 
        }
        ?>
        <div id='sync_details'></div>
        <?php 
        if ($_smarty_tpl->tpl_vars['STATE']->value == 'home') {
            ?>
            <?php 
            if ($_smarty_tpl->tpl_vars['SYNCTIME']->value) {
                ?>
            <p class="muted" id='synctime'><small title="<?php 
                echo Vtiger_Util_Helper::formatDateTimeIntoDayString($_smarty_tpl->tpl_vars['SYNCTIME']->value);
                ?>
"><?php 
                echo vtranslate('LBL_SYNCRONIZED', $_smarty_tpl->tpl_vars['MODULE_NAME']->value);
                ?>
 : <?php 
                echo Vtiger_Util_Helper::formatDateDiffInStrings($_smarty_tpl->tpl_vars['SYNCTIME']->value);
                ?>
</small></p>
            <?php 
            } else {
                ?>
                <p class="muted" id='synctime'><small><?php 
                echo vtranslate('LBL_NOT_SYNCRONIZED', $_smarty_tpl->tpl_vars['MODULE_NAME']->value);
                ?>
</small></p>    
            <?php 
            }
            ?>
   
       <?php 
        }
        ?>
        <div class='row-fluid'>
            <span class='span0'>&nbsp;</span>
            <button id="sync_button" class="btn btn-success span9"  data-url='index.php?module=Google&view=List&operation=sync&sourcemodule=<?php 
        echo $_smarty_tpl->tpl_vars['SOURCEMODULE']->value;
        ?>
'><b><?php 
        echo vtranslate('LBL_SYNC_BUTTON', $_smarty_tpl->tpl_vars['MODULE_NAME']->value);
        ?>
</b></button>
            <?php 
        if ($_smarty_tpl->tpl_vars['SOURCEMODULE']->value == 'Calendar') {
            ?>
 
                <span class="span0"> 
                    <i class="icon-question-sign pushDown" id="popid"  data-placement="right" rel="popover" ></i> 
                </span> 
            <?php 
        }
        ?>
 
            <?php 
        if ($_smarty_tpl->tpl_vars['SOURCEMODULE']->value == 'Contacts') {
            ?>
 
                <span class="span0"> 
                    <a id="syncSetting" data-sourcemodule="<?php 
            echo $_smarty_tpl->tpl_vars['SOURCEMODULE']->value;
            ?>
" title="<?php 
            echo vtranslate('SYNC_SETTINGS', $_smarty_tpl->tpl_vars['MODULE_NAME']->value);
            ?>
"><i class="icon-cog pushDown" style="margin-top:15px !important;"></i></a> 
                </span> 
//.........这里部分代码省略.........
开发者ID:cannking,项目名称:vtigercrm-debug,代码行数:101,代码来源:9ff6be92b98d9ab35d1f059766fcedf3c67bb293.file.Contents.tpl.php

示例10: content_56755ebd2a656


//.........这里部分代码省略.........
            } else {
                echo vtranslate('LBL_GLOBAL_SEARCH_MAX_MESSAGE', 'Vtiger');
            }
            ?>
</div><?php 
        }
        $_smarty_tpl->tpl_vars['searchRecords'] = new Smarty_Variable();
        $_smarty_tpl->tpl_vars['searchRecords']->_loop = false;
        $_smarty_tpl->tpl_vars['module'] = new Smarty_Variable();
        $_from = $_smarty_tpl->tpl_vars['MATCHING_RECORDS']->value;
        if (!is_array($_from) && !is_object($_from)) {
            settype($_from, 'array');
        }
        $_smarty_tpl->tpl_vars['smarty']->value['foreach']['matchingRecords']['index'] = -1;
        foreach ($_from as $_smarty_tpl->tpl_vars['searchRecords']->key => $_smarty_tpl->tpl_vars['searchRecords']->value) {
            $_smarty_tpl->tpl_vars['searchRecords']->_loop = true;
            $_smarty_tpl->tpl_vars['module']->value = $_smarty_tpl->tpl_vars['searchRecords']->key;
            $_smarty_tpl->tpl_vars['smarty']->value['foreach']['matchingRecords']['index']++;
            $_smarty_tpl->tpl_vars["modulesCount"] = new Smarty_variable(count($_smarty_tpl->tpl_vars['searchRecords']->value), null, 0);
            ?>
<label class="clearfix"><strong><?php 
            echo vtranslate($_smarty_tpl->tpl_vars['module']->value);
            ?>
&nbsp;(<?php 
            echo $_smarty_tpl->tpl_vars['modulesCount']->value;
            ?>
)</strong><?php 
            ob_start();
            echo $_smarty_tpl->getVariable('smarty')->value['foreach']['matchingRecords']['index'] + 1;
            $_tmp1 = ob_get_clean();
            if ($_tmp1 == 1) {
                ?>
<span class="pull-right"><p class="muted"><?php 
                echo vtranslate('LBL_CREATED_ON', $_smarty_tpl->tpl_vars['MODULE']->value);
                ?>
</small></p></span><?php 
            }
            ?>
</label><ul class="nav"><?php 
            $_smarty_tpl->tpl_vars['recordObject'] = new Smarty_Variable();
            $_smarty_tpl->tpl_vars['recordObject']->_loop = false;
            $_from = $_smarty_tpl->tpl_vars['searchRecords']->value;
            if (!is_array($_from) && !is_object($_from)) {
                settype($_from, 'array');
            }
            $_smarty_tpl->tpl_vars['smarty']->value['foreach']['globalSearch']['index'] = -1;
            foreach ($_from as $_smarty_tpl->tpl_vars['recordObject']->key => $_smarty_tpl->tpl_vars['recordObject']->value) {
                $_smarty_tpl->tpl_vars['recordObject']->_loop = true;
                $_smarty_tpl->tpl_vars['smarty']->value['foreach']['globalSearch']['index']++;
                $_smarty_tpl->tpl_vars["ID"] = new Smarty_variable($_smarty_tpl->tpl_vars['module']->value . "_globalSearch_row_" . ($_smarty_tpl->getVariable('smarty')->value['foreach']['globalSearch']['index'] + 1), null, 0);
                $_smarty_tpl->tpl_vars['DETAILVIEW_URL'] = new Smarty_variable($_smarty_tpl->tpl_vars['recordObject']->value->getDetailViewUrl(), null, 0);
                ?>
<li id="<?php 
                echo $_smarty_tpl->tpl_vars['ID']->value;
                ?>
"><a target="_blank" id="<?php 
                echo $_smarty_tpl->tpl_vars['ID']->value;
                ?>
_link" class="cursorPointer" <?php 
                if (stripos($_smarty_tpl->tpl_vars['DETAILVIEW_URL']->value, 'javascript:') === 0) {
                    ?>
onclick='<?php 
                    echo substr($_smarty_tpl->tpl_vars['DETAILVIEW_URL']->value, strlen("javascript:"));
                    ?>
' <?php 
                } else {
                    ?>
 onclick='window.location.href="<?php 
                    echo $_smarty_tpl->tpl_vars['DETAILVIEW_URL']->value;
                    ?>
"' <?php 
                }
                ?>
><?php 
                echo $_smarty_tpl->tpl_vars['recordObject']->value->getName();
                ?>
<span id="<?php 
                echo $_smarty_tpl->tpl_vars['ID']->value;
                ?>
_time" class="pull-right" title="<?php 
                echo Vtiger_Util_Helper::formatDateTimeIntoDayString($_smarty_tpl->tpl_vars['recordObject']->value->get('createdtime'));
                ?>
"><?php 
                echo Vtiger_Util_Helper::formatDateDiffInStrings($_smarty_tpl->tpl_vars['recordObject']->value->get('createdtime'));
                ?>
</span></a></li><?php 
            }
            if (!$_smarty_tpl->tpl_vars['recordObject']->_loop) {
                ?>
<li><?php 
                echo vtranslate('LBL_NO_RECORDS', $_smarty_tpl->tpl_vars['module']->value);
                ?>
</li><?php 
            }
            ?>
</ul><?php 
        }
        ?>
</div></div></div><?php 
    }
开发者ID:wsLapshin,项目名称:charter_crm,代码行数:101,代码来源:a53e04dc5323dece0e5a5d22bb31ed6ccd3fbf27.file.UnifiedSearchResults.tpl.php


注:本文中的Vtiger_Util_Helper::formatDateDiffInStrings方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。