Projekt

Allgemein

Profil

« Zurück | Weiter » 

Revision 4412b603

Von Tamino Steinert vor etwa 1 Jahr hinzugefügt

  • ID 4412b603dcffbd030ef278eec6463c8e34b0157d
  • Vorgänger 2872818f
  • Nachfolger 1f0fb5c0

S:F:B:Webdav: Lege beim Speichern Dateiversion an

Unterschiede anzeigen:

SL/File/Backend/Filesystem.pm
use parent qw(SL::File::Backend);
use SL::DB::File;
use SL::DB::FileVersion;
use File::Copy;
use File::Slurp;
......
print OUT $params{file_contents};
close(OUT);
}
# save file version
my $doc_path = $::lx_office_conf{paths}->{document_path};
my $rel_file = $tofile;
$rel_file =~ s/$doc_path//;
my $fv = SL::DB::FileVersion->new(
file_id => $dbfile->id,
version => $dbfile->backend_data,
file_location => $rel_file,
doc_path => $doc_path,
backend => 'Filesystem',
guid => create_uuid_as_string(UUID_V4),
)->save;
file_id => $dbfile->id,
version => $dbfile->backend_data,
file_location => $rel_file,
doc_path => $doc_path,
backend => 'Filesystem',
guid => create_uuid_as_string(UUID_V4),
)->save;
if ($params{mtime}) {
utime($params{mtime}, $params{mtime}, $tofile);
}

Auch abrufbar als: Unified diff