stable
Clone or download
Read-only
In order to enforce SRP, move logic of field file saveValue() into dedicated objects, with a better test coverage (before: 0% ☺). This is a preliminary step to be able to attach tus-uploaded-files to an artifact. It will be then easier to add new behavior by adding component in the attachment creator chain of responsibility: -> try to add a tus-uploaded-file [*] -> if not, try to add a rest-temporary-file -> if not, try to add a traditional-upload-file Part of story #12964: drag'n drop images in tracker text areas [*] in a next changeset Change-Id: I529668d4dd518f697d1fec9a91c4cc8d23600815
Modified Files
Name | ||||
---|---|---|---|---|
A | plugins/tracker/include/Tracker/FormElement/Field/File/AttachmentCreator.php | +36 | −0 | Go to diff View file |
A | plugins/tracker/include/Tracker/FormElement/Field/File/AttachmentForRestCreator.php | +113 | −0 | Go to diff View file |
A | plugins/tracker/include/Tracker/FormElement/Field/File/AttachmentForTraditionalUploadCreator.php | +98 | −0 | Go to diff View file |
A | plugins/tracker/include/Tracker/FormElement/Field/File/AttachmentToFinalPlaceMover.php | +41 | −0 | Go to diff View file |
A | plugins/tracker/include/Tracker/FormElement/Field/File/ChangesetValueFileSaver.php | +123 | −0 | Go to diff View file |
M | plugins/tracker/include/Tracker/FormElement/Tracker_FormElement_Field.class.php | +1 | −1 | Go to diff View file |
M | plugins/tracker/include/Tracker/FormElement/Tracker_FormElement_Field_File.class.php | +29 | −145 | Go to diff View file |
A | plugins/tracker/phpunit/Tracker/FormElement/Field/File/AttachmentForRestCreatorTest.php | +350 | −0 | Go to diff View file |
A | plugins/tracker/phpunit/Tracker/FormElement/Field/File/AttachmentForTraditionalUploadCreatorTest.php | +229 | −0 | Go to diff View file |
A | plugins/tracker/phpunit/Tracker/FormElement/Field/File/AttachmentToFinalPlaceMoverTest.php | +68 | −0 | Go to diff View file |
A | plugins/tracker/phpunit/Tracker/FormElement/Field/File/ChangesetValueFileSaverTest.php | +342 | −0 | Go to diff View file |
M | src/common/valid/Rule.class.php | +1 | −1 | Go to diff View file |