-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Internal/content preview #691
Conversation
|
||
/** | ||
* Database entity representation of the previewcontent table. | ||
* Database entity representation of class FileInfo. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So this is a database entity representation of what?
dspace-api/src/main/java/org/dspace/content/PreviewContent.java
Outdated
Show resolved
Hide resolved
ALTER TABLE eperson ADD can_edit_submission_metadata BOOL; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please add this changes into a new file called e.g., V7.6.1._2024.08.05_Added_Preview_Tables.sql
previewcontent_id integer NOT NULL, | ||
bitstream_id uuid NOT NULL, | ||
name varchar(256), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is 256 enough?
@@ -488,3 +488,84 @@ ALTER COLUMN element TYPE character varying(128); | |||
ALTER TABLE eperson ADD welcome_info varchar(30); | |||
|
|||
ALTER TABLE eperson ADD can_edit_submission_metadata BOOL; | |||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please change the name of the file
@@ -243,10 +308,10 @@ private List<FileInfo> processInputStreamToFilePreview(Context context, Bitstrea | |||
fileInfos.add(new FileInfo(data, false)); | |||
} else { | |||
String data = ""; | |||
if (bitstream.getFormat(context).getExtensions().contains("zip")) { | |||
if (bitstream.getFormat(context).getMIMEType().equals("application/zip")) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I remember, that we should check it following the getExtensions
because of some reason I do not remember. Please can we check it like that again?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't understand your comment....
...server-webapp/src/main/java/org/dspace/app/rest/repository/PreviewContentRestRepository.java
Show resolved
Hide resolved
try { | ||
previewContent = previewContentService.find(context, integer); | ||
} catch (SQLException e) { | ||
throw new RuntimeException(e.getMessage(), e); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe add some log error
dspace-server-webapp/src/test/java/org/dspace/app/rest/PreviewContentServiceImplIT.java
Show resolved
Hide resolved
dspace/config/clarin-dspace.cfg
Outdated
@@ -1,4 +1,5 @@ | |||
## File for changes to dspace.cfg - separated from original configuration file to see what we changed | |||
## File for changes to dspace.cfg - separated from original configuration file to see what we changed |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You've added the same comment twice
Problem description
Notes: There is a different order.