6.0.0-beta1
▾
Tasks
New Task
Search
Photos
Wiki
▾
Tickets
New Ticket
Search
dev.horde.org
Toggle Alerts Log
Help
10/21/25
H
istory
A
ttachments
C
omment
W
atch
Download
Comment on [#1274] Moving ticket doesn't reset version
*
Your Email Address
*
Spam protection
Enter the letters below:
. ..___..__ __ . , | | | [__)/ ` \./ |__| | [__)\__. |
Comment
> Hi, > > > > I am just a newbie in Horde so don't get mad if I'm far out. > > > > How about this solution? I'm not quite sure about the sql.php part > though. Version is the only nullable column in whups_tickets table, > so I wonder if it is ok to do it this way. Although there may be some > other nullable columns in the future. > > > > Index: whups/lib/Ticket.php > > =================================================================== > > RCS file: /repository/whups/lib/Ticket.php,v > > retrieving revision 1.27 > > diff -u -3 -p -u -r1.27 Ticket.php > > --- whups/lib/Ticket.php 12 Jan 2005 17:04:45 -0000 1.27 > > +++ whups/lib/Ticket.php 29 Jan 2005 09:27:31 -0000 > > @@ -246,6 +246,15 @@ class Whups_Ticket { > > } > > break; > > > > + case 'queue': > > + // Reset version if new queue is not versioned > > + $newQueue = $whups->getQueue($value['name']); > > + if (!$newQueue['versioned']) { > > + $updates['version'] = ''; > > + } > > + $updates['queue'] = $value['name']; > > + break; > > + > > default: > > $updates[$detail] = $value; > > } > > Index: whups/lib/Driver/sql.php > > =================================================================== > > RCS file: /repository/whups/lib/Driver/sql.php,v > > retrieving revision 1.208 > > diff -u -3 -p -u -r1.208 sql.php > > --- whups/lib/Driver/sql.php 19 Jan 2005 15:07:40 -0000 1.208 > > +++ whups/lib/Driver/sql.php 29 Jan 2005 09:27:32 -0000 > > @@ -323,7 +323,11 @@ class Whups_Driver_sql extends Whups_Dri > > continue; > > } > > > > - $query .= $this->_map[$field] . ' = ' . > $this->_db->quote(String::convertCharset($value, NLS::getCharset(), > $this->_params['charset'])) . ', '; > > + if (empty($value)) { > > + $query .= $this->_map[$field] . ' = NULL, '; > > + } else { > > + $query .= $this->_map[$field] . ' = ' . > $this->_db->quote(String::convertCharset($value, NLS::getCharset(), > $this->_params['charset'])) . ', '; > > + } > > } > > > > /* Don't try to execute an empty query (if we didn't find any > >
Attachment
Watch this ticket
N
ew Ticket
M
y Tickets
S
earch
Q
uery Builder
R
eports
Saved Queries
Open Bugs
Bugs waiting for Feedback
Open Bugs in Releases
Open Enhancements
Enhancements waiting for Feedback
Bugs with Patches
Enhancements with Patches
Release Showstoppers
Stalled Tickets
New Tickets
Horde 5 Showstoppers