Changes from 1979 file-attachment

Review Request #2215 — Created March 24, 2011 and submitted — Latest diff uploaded

sws587
Review Board
reviewboard
Here is the latest version of the file-uploader/file-attachment program to date (sorry I didn't get it done).

To date we were able to integrate the code into the existing version of review board and implement the default comment dialog box but there are still a lot of issues to be solved.

Issues remaining:

1. Location where comment/review text is being stored:

If a person uses the 'review file' button next to the file that has been uploaded
-the text is stored in text field of reviews_uploadedfilecomment table (seems appropriate: see first screenshot)
-it doesn't show up on the page (the review block is just empty).

If a person uses the 'review' button (top-right)
-it stores the text in the body_top field in reviews_review (see second screenshot)
-It does show up on the page

If a person uses the 'add comment' button (bottom of page)
-it stores the text in the body_top field in reviews_review (see second screenshot)
-it does show up on the page.

2. Reviews.js mycustomid

In lines 1780-ff, ChipX86 recommended something like 
for(var el in $(".file-review"))
   ...
     $(el).attr("fileid");
...
Unfortunately I couldn't get this method to work since the $(el).attr("fileid") always came back undefined.  The method I used in its place does succeed, but uses an ill named "mycustomid" id value which I used with the intention of improving later.  If this alternative is adopted we should rename that value, but I suspect we'd rather implement ChipX86's recommendation.

3. filemanager.py:
Filemanager is broken again, we had it working after the first merge attempt, but after the second merge it busted.  The recommended evolution settings don't work, so this has to be fixed before this program is released.  If just rebuilding the database the program seems to function fine.

Sorry I didn't get this all working before the term ended, but we had a lot of issues to resolve in the first merge (for instance we lost a lot of data in datastore).

The latest version of this is all posted on my github account in the next-gen-file-attachment branch.

git://github.com/sws587/reviewboard.git

Cheers!


Loading...