[Vtigercrm-commits] [vtiger-commits] r7255 - in /vtigercrm/trunk: Smarty/templates/ListView.tpl Smarty/templates/ListViewEntries.tpl modules/Users/updateLeadDBStatus.php
vtigercrm-commits at vtiger.fosslabs.com
vtigercrm-commits at vtiger.fosslabs.com
Mon Jun 19 04:30:30 EDT 2006
Author: saraj
Date: Mon Jun 19 02:30:18 2006
New Revision: 7255
Log:
issue in mass delete,change owner,change status has been fixed
Modified:
vtigercrm/trunk/Smarty/templates/ListView.tpl
vtigercrm/trunk/Smarty/templates/ListViewEntries.tpl
vtigercrm/trunk/modules/Users/updateLeadDBStatus.php
Modified: vtigercrm/trunk/Smarty/templates/ListView.tpl
==============================================================================
--- vtigercrm/trunk/Smarty/templates/ListView.tpl (original)
+++ vtigercrm/trunk/Smarty/templates/ListView.tpl Mon Jun 19 02:30:18 2006
@@ -127,10 +127,10 @@
</td>
</tr>
</table>
-</form>
</div>
{*<!-- Contents -->*}
+<form name="basicSearch" action="index.php">
<table border=0 cellspacing=0 cellpadding=0 width=98% align=center>
<tr>
<td valign=top><img src="{$IMAGE_PATH}showPanelTopLeft.gif"></td>
@@ -138,7 +138,6 @@
<td class="showPanelBg" valign="top" width=100% style="padding:10px;">
<!-- SIMPLE SEARCH -->
<div id="searchAcc" style="z-index:1;display:none;position:relative;">
-<form name="basicSearch" action="index.php">
<table width="80%" cellpadding="5" cellspacing="0" style="border:1px dashed #CCCCCC;" class="small" align="center">
<tr>
<td width="15%" class="dvtCellLabel" nowrap align="right"><img src="{$IMAGE_PATH}basicSearchLens.gif" align="absmiddle" alt="{$APP.LNK_BASIC_SEARCH}" title="{$APP.LNK_BASIC_SEARCH}" border=0> <b>{$APP.LBL_SEARCH_FOR}</b></td>
@@ -214,12 +213,13 @@
</tr>
</table>
</div>
+</form>
{*<!-- Searching UI -->*}
<br>
<!-- PUBLIC CONTENTS STARTS-->
<div id="ListViewContents" class="small" style="width:100%;position:relative;">
- <input name='search_url' id="search_url" type='hidden' value='{$SEARCH_URL}'>
<form name="massdelete" method="POST">
+ <input name='search_url' id="search_url" type='hidden' value='{$SEARCH_URL}'>
<input name="idlist" type="hidden">
<input name="change_owner" type="hidden">
<input name="change_status" type="hidden">
Modified: vtigercrm/trunk/Smarty/templates/ListViewEntries.tpl
==============================================================================
--- vtigercrm/trunk/Smarty/templates/ListViewEntries.tpl (original)
+++ vtigercrm/trunk/Smarty/templates/ListViewEntries.tpl Mon Jun 19 02:30:18 2006
@@ -11,13 +11,13 @@
-->*}
&#&#&#{$ERROR}&#&#&#
+ <form name="massdelete" method="POST">
<input name='search_url' id="search_url" type='hidden' value='{$SEARCH_URL}'>
<input name='allids' type='hidden' value='{$ALLIDS}'>
- <form name="massdelete" method="POST">
<input name="idlist" type="hidden">
<input name="change_owner" type="hidden">
<input name="change_status" type="hidden">
-<table border=0 cellspacing=1 cellpadding=0 width=100% class="lvtBg">
+ <table border=0 cellspacing=1 cellpadding=0 width=100% class="lvtBg">
<tr style="background-color:#efefef">
<td>
<table border=0 cellspacing=0 cellpadding=2 width=100% class="small">
@@ -134,5 +134,5 @@
</tr>
</table>
- </form>
+ </form>
{$SELECT_SCRIPT}
Modified: vtigercrm/trunk/modules/Users/updateLeadDBStatus.php
==============================================================================
--- vtigercrm/trunk/modules/Users/updateLeadDBStatus.php (original)
+++ vtigercrm/trunk/modules/Users/updateLeadDBStatus.php Mon Jun 19 02:30:18 2006
@@ -20,7 +20,7 @@
$return_module = $_REQUEST['return_module'];
global $current_user;
global $adb;
-$storearray = explode(";",$idlist);
+$storearray = explode(";",trim($idlist,';'));
$ids_list = array();
@@ -32,7 +32,7 @@
if(isPermitted($return_module,'EditView',$id) == 'yes')
{
if($id != '') {
- $sql = "update vtiger_crmentity set modifiedby=".$current_user->id.",smownerid='" .$idval ."', modifiedtime=".$adb->formatString("crmentity","modifiedtime",$date_var)." where crmid='" .$id."'";
+ $sql = "update vtiger_crmentity set modifiedby=".$current_user->id.",smownerid='" .$idval ."', modifiedtime=".$adb->formatString("vtiger_crmentity","modifiedtime",$date_var)." where crmid='" .$id."'";
$result = $adb->query($sql);
}
}
@@ -44,14 +44,15 @@
}
elseif(isset($_REQUEST['leadval']) && $_REQUEST['leadval']!='')
{
+
foreach($storearray as $id)
{
if(isPermitted($return_module,'EditView',$id) == 'yes')
{
if($id != '') {
- $sql = "update vtiger_leaddetails set vtiger_leadstatus='" .$leadstatusval ."' where leadid='" .$id."'";
+ $sql = "update vtiger_leaddetails set leadstatus='" .$leadstatusval ."' where leadid='" .$id."'";
$result = $adb->query($sql);
- $query = "update vtiger_crmentity set modifiedby=".$current_user->id.",modifiedtime=".$adb->formatString("crmentity","modifiedtime",$date_var)." where crmid=".$id;
+ $query = "update vtiger_crmentity set modifiedby=".$current_user->id.",modifiedtime=".$adb->formatString("vtiger_crmentity","modifiedtime",$date_var)." where crmid=".$id;
$result1 = $adb->query($query);
}
}
@@ -62,13 +63,13 @@
}
}
-$ret_owner = getEntityName($return_module,$ids_list);
-if(count($ret_owner) > 0)
+if(count($ids_list) > 0)
{
- $errormsg = implode(',',$ret_owner);
+ $ret_owner = getEntityName($return_module,$ids_list);
+ $errormsg = implode(',',$ret_owner);
}else
{
- $errormsg = '';
+ $errormsg = '';
}
if($return_module == 'Calendar')
More information about the vtigercrm-commits
mailing list