[Vtigercrm-commits] [vtiger-commits] r10653 - in /customerportal/trunk: Faq/FaqDetail.php Tickets/TicketDetail.php Tickets/index.html js/general.js
vtigercrm-commits at vtiger.fosslabs.com
vtigercrm-commits at vtiger.fosslabs.com
Thu Apr 12 07:33:40 EDT 2007
Author: richie
Date: Thu Apr 12 05:33:31 2007
New Revision: 10653
Log:
* Fixed the comment validation issue for Tickets and FAQ (previously page will be submitted but value will not be stored). Now page will not be submitted without value, Fixed #3420
Modified:
customerportal/trunk/Faq/FaqDetail.php
customerportal/trunk/Tickets/TicketDetail.php
customerportal/trunk/Tickets/index.html
customerportal/trunk/js/general.js
Modified: customerportal/trunk/Faq/FaqDetail.php
==============================================================================
--- customerportal/trunk/Faq/FaqDetail.php (original)
+++ customerportal/trunk/Faq/FaqDetail.php Thu Apr 12 05:33:31 2007
@@ -90,7 +90,7 @@
</tr>
<tr>
<td colspan="2" class="dvtCellInfo">
- <input title="Save [Alt+S]" accesskey="S" class="small" name="submit" value="'.$mod_strings['LBL_SUBMIT'].'" style="width: 70px;" type="submit" onclick="this.form.module.value=\'Faq\';this.form.action.value=\'index\';this.form.fun.value=\'faq_updatecomment\'; return verify_data(this.form,coments);"/>
+ <input title="Save [Alt+S]" accesskey="S" class="small" name="submit" value="'.$mod_strings['LBL_SUBMIT'].'" style="width: 70px;" type="submit" onclick="this.form.module.value=\'Faq\';this.form.action.value=\'index\';this.form.fun.value=\'faq_updatecomment\'; if(trim(this.form.comments.value) != \'\') return true; else return false;"/>
</td>
</tr>
<tr>
Modified: customerportal/trunk/Tickets/TicketDetail.php
==============================================================================
--- customerportal/trunk/Tickets/TicketDetail.php (original)
+++ customerportal/trunk/Tickets/TicketDetail.php Thu Apr 12 05:33:31 2007
@@ -142,7 +142,7 @@
<td colspan="4" class="dvtCellInfo"><textarea name="comments" cols="55" rows="5" class="detailedViewTextBox" onFocus="this.className=\'detailedViewTextBoxOn\'" onBlur="this.className=\'detailedViewTextBox\'"></textarea></td>
</tr>
<tr>
- <td><input title="Save [Alt+S]" accesskey="S" class="small" name="submit" value="Submit" style="width: 70px;" type="submit" onclick="this.form.module.value=\'Tickets\';this.form.action.value=\'index\';this.form.fun.value=\'updatecomment\'; return verify_data(this.form,coments);"/></td>
+ <td><input title="Save [Alt+S]" accesskey="S" class="small" name="submit" value="Submit" style="width: 70px;" type="submit" onclick="this.form.module.value=\'Tickets\';this.form.action.value=\'index\';this.form.fun.value=\'updatecomment\'; if(trim(this.form.comments.value) != \'\') return true; else return false;"/></td>
</form>
<td colspan="2"> </td>
<td> </td>
Modified: customerportal/trunk/Tickets/index.html
==============================================================================
--- customerportal/trunk/Tickets/index.html (original)
+++ customerportal/trunk/Tickets/index.html Thu Apr 12 05:33:31 2007
@@ -76,19 +76,6 @@
return false;
}
}
-function trim(s)
-{
- while (s.substring(0,1) == " ")
- {
- s = s.substring(1, s.length);
- }
- while (s.substring(s.length-1, s.length) == ' ')
- {
- s = s.substring(0,s.length-1);
- }
-
- return s;
-}
function showTickets(form)
{
window.location.href = "index.php?showstatus="+form.ticket_status_combo.value;
Modified: customerportal/trunk/js/general.js
==============================================================================
--- customerportal/trunk/js/general.js (original)
+++ customerportal/trunk/js/general.js Thu Apr 12 05:33:31 2007
@@ -70,4 +70,18 @@
tagName.style.visibility = 'visible';
}
+function trim(s)
+{
+ while (s.substring(0,1) == " ")
+ {
+ s = s.substring(1, s.length);
+ }
+ while (s.substring(s.length-1, s.length) == ' ')
+ {
+ s = s.substring(0,s.length-1);
+ }
+ return s;
+}
+
+
More information about the vtigercrm-commits
mailing list