fixed: plugin ticket: when a session expires all files from editticket were removed
it should be removed only those new added git-svn-id: svn://ttmath.org/publicrep/winix/trunk@798 e52654a7-88a9-db11-a3e9-0013d4bc506e
This commit is contained in:
@@ -144,17 +144,21 @@ PT::Space & EditTicket::PrepareSpace()
|
||||
|
||||
bool is_new;
|
||||
long file_id = cur->request->item.id;
|
||||
PT::Space & space = session_data->GetSpace(file_id, session_data->edit_space_map, &is_new);
|
||||
PT::Space & new_space = session_data->GetNewSpace(file_id, session_data->edit_space_map, &is_new);
|
||||
|
||||
if( is_new )
|
||||
{
|
||||
PT::Space * ticket_space = cur->request->item.meta.FindSpace(L"ticket");
|
||||
|
||||
if( ticket_space )
|
||||
space = *ticket_space;
|
||||
{
|
||||
new_space = *ticket_space;
|
||||
PT::Space & old_space = session_data->GetOldSpace(file_id, session_data->edit_space_map);
|
||||
old_space = new_space;
|
||||
}
|
||||
}
|
||||
|
||||
return space;
|
||||
return new_space;
|
||||
}
|
||||
|
||||
|
||||
@@ -191,7 +195,8 @@ void EditTicket::MakeGet()
|
||||
ticket_info->ticket = &ticket;
|
||||
ticket_info->item = &cur->request->item;
|
||||
|
||||
ticket_info->CopyTicketSpace(meta, *ticket_info->item);
|
||||
// copy meta info to display correctly new files
|
||||
ticket_info->CopyTicketSpace(meta, cur->request->item);
|
||||
}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user