ernestb wrote on 08/16/04 at 00:57:04:I noticed that when you repost a closed item, the original listing that is in the closed folder is deleted.
Is there an easy patch to keep the system from deleting the orginal closed item?
That's easy but not recommended.
Go to sub proc_new
and search the sub for this lines:
Code: if ($form{'FROMPREVIEW'}) {
$form{'REPOST'} && do {
unlink "$config{'basepath'}$config{'closedir'}/$form{'REPOST'}.dat" or oops($!);
comment out this line
Code: unlink "$config{'basepath'}$config{'closedir'}/$form{'REPOST'}.dat" or oops($!);
it should look like this
Code: if ($form{'FROMPREVIEW'}) {
$form{'REPOST'} && do {
#unlink "$config{'basepath'}$config{'closedir'}/$form{'REPOST'}.dat" or oops($!);
ernestb wrote on 08/16/04 at 00:57:04:I also noticed that when you edit an item, the item number changes, should it not stay the same for reference purposes? Or may be it should change and then orginal item placed in the closed folder - for posible future reference?
The changed (edited) item is no longer valid - so why should it be stored?
ernestb wrote on 08/16/04 at 00:57:04:If you change categories the item gets lost even though it is still in the orginal category folder.
The edit problem is a real bug - sorry - my mistake :'(
Goto sub new
and search the sub for this lines:
Code:print <<EO_HTML if exists $form{'EDIT'};
</select>
</td>
</tr>
<tr bgcolor="$config{'colortablebody'}">
<td valign="middle" nowrap>
<input type="hidden" name="EDIT" value="$form{'EDIT'}">
add this line:
Code: <input type="hidden" name="old_cat" value="$form{'category'}">
it should look like this
Code:print <<EO_HTML if exists $form{'EDIT'};
</select>
</td>
</tr>
<tr bgcolor="$config{'colortablebody'}">
<td valign="middle" nowrap>
<input type="hidden" name="EDIT" value="$form{'EDIT'}">
<input type="hidden" name="old_cat" value="$form{'category'}">
Go to sub proc_new
and search the sub for this lines:
Code:
if ($form{'FROMPREVIEW'}) {
$form{'REPOST'} && do {
#unlink "$config{'basepath'}$config{'closedir'}/$form{'REPOST'}.dat" or oops($!);
delete $form{'REPOST'};
};
$form{'EDIT'} && do {
unlink "$config{'basepath'}$form{'CATEGORY'}/$form{'EDIT'}.dat" or oops($!);
edit this line
Code: unlink "$config{'basepath'}$form{'CATEGORY'}/$form{'EDIT'}.dat" or oops($!);
it should look like this
Code: unlink "$config{'basepath'}$form{'old_cat'}/$form{'EDIT'}.dat" or oops($!);