witten
/
luminotes
Archived
1
0
Fork 0
Commit Graph

129 Commits

Author SHA1 Message Date
Dan Helfman 1d17ea4eff Fixed a bug where attempting to load a notebook preview without access
would give a "list index out of range" error instead of an access error.
2008-05-05 23:10:26 +00:00
Dan Helfman 97c373561d * Added replace_contents() to model.Note to set the contents without updating the revision or anything else.
* Added new optional previous_revision params to default(), contents() and load_note() in controller.Notebooks.
   These use Html_differ() to generate and return diffs.
 * Updated Wiki.js:
   * provide previous_revision when a revision is opened in a new window/tab
   * call load_note() when two revisions when a revision is clicked in Changes_pulldown
   * update compare_versions() to display a diff instead of opening the two revisions separately
   * update load_editor():
     * update all invocations of load_editor(), including in Editor.js, to accept a new previous_revision argument
     * modify load_editor() to use the previous_revision argument (when supplied) to load a diff
2008-05-03 04:29:23 +00:00
Dan Helfman 5f852a3d8e Bug fix: Used to get access error when you loaded the children links for a note that was in the trash. 2008-04-29 21:26:09 +00:00
Dan Helfman 1d0867d776 * Renamed existing controller.Notebooks.load_recent_notes method to just recent_notes().
* Implemented new controller.Notebooks.load_recent_updates() method.
 * Added new Wiki.js total_notes_count_updated signal
 * Added "more" and "less" links to "recent updates" table.
 * Updated Wiki.js Recent_notes to support new "more" and "less" links.
 * Commented out unfinished discussion forums unit test.
2008-04-29 00:54:08 +00:00
Dan Helfman b316b2f4a3 * Increasing after_login max string size from 100 to 1000 to accomodate larger URLs.
* controller.Notebooks now takes (and stores) an https_url constructor parameter.
 * New controller.Notebooks.updates() method to produce an updates RSS feed for a particular notebook.
 * New controller.Notebooks.get_update_link() method to make a brief page with just a link for an updated note, referred to by the feed.
 * Implemented views for the new RSS feed.
 * Fixed bug in Rss_item's guid that caused newlines to be inserted before and after long URLs.
 * Still need to unit test new controller code.
2008-04-22 23:24:30 +00:00
Dan Helfman 1ca9af536c Added RSS subscription links for all notebooks. 2008-04-18 20:49:22 +00:00
Dan Helfman eb587fc44f Fixed bug where recent notes were ordered by creation time instead of revision time. 2008-04-18 20:39:23 +00:00
Dan Helfman c488864273 * Now if you try to load a page where access is required, and you're not
logged in, you'll be redirected to a login page. After you login, you'll
   be redirected to the page you were originally trying to access.
2008-04-18 19:54:50 +00:00
Dan Helfman d0a1cbf71d Complete unit tests for controller.Notebooks.load_note_links(). 2008-04-16 08:13:35 +00:00
Dan Helfman 456c1b5fb8 Don't display recent notes on the main Luminotes notebook. 2008-04-16 01:39:24 +00:00
Dan Helfman 431bf6ace7 Completed recent notes list:
* displaying list of links
  * adding links
  * removing links
  * updating links
  * controller.Notebooks.contents() changes to return recent notes
2008-04-16 00:28:18 +00:00
Dan Helfman db03f39c06 When all the children of a display note are removed, remove the expander from
that note's entries in the note tree. When a note with no children is updated
so that it has at least one child, add an expander to that note's entries in
the note tree.
2008-04-14 23:54:04 +00:00
Dan Helfman 0d4bb81943 Clicking an external link or a file link in the note tree now opens with target=_new. 2008-04-12 02:32:11 +00:00
Dan Helfman eaaf1b3de5 Lots more work on the note tree control. Still not done, and some of the new icons suck. 2008-04-12 00:51:32 +00:00
Dan Helfman f3b0d563c1 Fixed database transaction leak by wrapping every exposed database-using
controller method with a new @end_transaction() decorator. This
decorator is responsible for rolling back unfinished transactions.
2008-03-17 21:17:00 +00:00
Dan Helfman 94a51889f9 Added ability to reorder notebooks on the right side of the page.
Need to complete unit tests for controller.Notebooks.move_up() and move_down().
2008-03-15 03:04:59 +00:00
Dan Helfman 21ccc97826 Now using memcached in various places to improve performance. If the Python
cmemcache module is not importable, then memcached simply won't be used.
2008-03-05 00:34:58 +00:00
Dan Helfman 36b11805c6 Now purging files from the database/filesystem when notes they're linked from
are deleted from the trash. Also displaying a message when deleting a file
manually via the "delete" button.
2008-02-22 21:08:29 +00:00
Dan Helfman 65ce915755 When saving a note, auto-delete any files that used to be linked from it but no longer are. Still need unit tests. 2008-02-22 19:47:28 +00:00
Dan Helfman e56503903b Factored out file upload methods from Notebooks to new Files controller.
Changed file link insertion code to reuse existing link creation code.
2008-02-01 19:17:10 +00:00
Dan Helfman 0cf2b5bda7 Initial work on UI and controller for file uploading:
* new toolbar button for attaching a file
 * button opens new Upload_pulldown() for uploading a file
 * began controller.Notebooks.upload_file() to process the upload
2008-01-31 21:52:32 +00:00
Dan Helfman ffd2d15175 Now, if you delete a notebook and the only remaining notebook is read-only,
then a new read-write notebook is created for you automatically. This fixes a
bug where you could delete a notebook and have only a read-only notebook
remaining, thereby having no way to add a new notebook.
2008-01-24 22:02:02 +00:00
Dan Helfman 2bcbc17172 Feature to preview notebook as viewer or collaborator, so you can see what it
will look like to people you share it with.

Hopefully fixed broken demo conversion detection.
2008-01-06 00:12:18 +00:00
Dan Helfman 5520fe5892 * make a User_revision object containing a revision timestamp, user_id, username
* change controller.Notebooks.load_note_revisions() to select and return User_revision objects
 * change controller.Notebooks.save_note() to use User_revision objects for new_revision and previous_revision as well
 * update client to deal with new load_note_revisions() return values (make sure all uses of revisions_list are updated)
 * update client to deal with new new_revision/previous_revision
 * update changes pulldown to show username along with each timestamp
 * update model.Invite to load redeemed_username along with redeemed_user_id
 * display the redeemed username next to each email address in the "share this notebook" note
2008-01-04 04:45:43 +00:00
Dan Helfman a354eadcbb When saving a model.Notebook or model.Note to the database, set the user_id field based on the current user. 2008-01-01 01:44:54 +00:00
Dan Helfman 05279d2c8e Only owners of a notebook should get a list of its invites. 2007-12-12 06:15:15 +00:00
Dan Helfman 225167035d * model.Invite now has a to_dict() method, like other model classes do.
* Initial invites are now returned through Main_page() and displayed (but not
   yet updated) within the "share this notebook" note.
2007-12-12 00:52:34 +00:00
Dan Helfman 32fd09b3f7 * Implemented controller.Users.send_invites().
* Added some SQL indices to invite table.
2007-12-06 01:32:20 +00:00
Dan Helfman 1cb12f6ae4 Making various notebook/user functions support the new "owner" access flag. 2007-12-04 21:28:03 +00:00
Dan Helfman af3bf3c51c Improving error reporting and completing 1.0.2. 2007-11-28 19:17:13 +00:00
Dan Helfman 0152b49475 Refactored the way note summaries are created in the link pulldown window. 2007-11-27 21:28:25 +00:00
Dan Helfman 45f94aa188 Deleting a notebook forever now updates the user's storage usage accordingly. 2007-11-19 22:03:04 +00:00
Dan Helfman 517e4d4925 Add strongly expire to default(). 2007-11-17 23:45:18 +00:00
Dan Helfman eec5ef6411 Implemented delete forever for notebooks. And unit tests! 2007-11-17 23:29:22 +00:00
Dan Helfman 7bd83199a1 Almost done with notebook deletion/undeletion. Just need to implement delete forever. 2007-11-17 22:55:13 +00:00
Dan Helfman cdd971780e Began work on notebook deletion and subsequent undo/undeletion.
Changed schema slightly to support this.
Added a schema delta file and wrote an UPGRADE doc with info on how to upgrade schemas.
2007-11-17 04:21:48 +00:00
Dan Helfman c1b4a58f65 Adding a new notebook now puts you directly into renaming it. 2007-11-15 23:46:30 +00:00
Dan Helfman 3b2462eff3 Not allowing "trash" as a new name when you rename a notebook.
Not allowing renaming of the actual trash notebook.
Not showing "add new notebook" link when anonymous user.
2007-11-15 22:55:57 +00:00
Dan Helfman b22c784d39 Can now create and rename notebooks. Still need to implement deletion and some other niceties. 2007-11-15 01:30:45 +00:00
Dan Helfman c31856b40b Added some code to support Google's conversion tracking. 2007-11-12 10:51:31 +00:00
Dan Helfman 44a1cb79c2 Added basic multipage navigation to blog.
Made name of notebook link at the top of the page better for "special" Luminotes notebooks.
2007-11-10 01:46:56 +00:00
Dan Helfman 88dd396feb Fix for: I get "that note is in the trash" error when clicking on an old
revision of a note that's not in the trash. This is because that particular
revision of the note represents when the note used to be in the trash (because
it was previously deleted).
2007-11-03 08:15:39 +00:00
Dan Helfman 37e886f27c Revamped searching to use PostgreSQL's tsearch2 full-text searching. 2007-11-02 20:19:53 +00:00
Dan Helfman ad58956f34 Some early work in support of a reverse chronological order view of a notebook, useful for a blog. 2007-10-30 23:05:46 +00:00
Dan Helfman 84283f524e If you click on a link for a note that's in the trash, you just get a message telling you so, with a button to undelete the note. 2007-10-22 23:17:56 +00:00
Dan Helfman 28835e5850 Strip newlines before comparing contents of a note to see if it's been altered. 2007-10-22 21:20:20 +00:00
Dan Helfman 27a6a06c91 Display a realtime count of total notes next to the "all notes" link. 2007-10-19 20:24:16 +00:00
Dan Helfman 218fe3995c Bug fix. Repro: Try making a link to a note that doesn't exist yet, then click
on the link. Delete the new note. Then go back to the first message, and click
after the link, so the link's pulldown shows. You'll get this error message:
"Sorry, you don't have access to do that."

The fix was to look for the cases when the deleted note is either in the trash
or deleted "forever", and then return None for the note value (instead of just
raising an Access_error).
2007-10-17 01:47:46 +00:00
Dan Helfman 613ee8a217 Completely revamped the way the main page and the notes on it are loaded by
the client. Previously, the main page would load as mostly blank, then the
client would immediately issue two async json calls to load the user and
notebook data, including startup notes. Now, the main page loads with the note
data actually as part of the page. If JavaScript is off, then you see all the
notes displayed, including startup notes and any designated note. If
JavaScript is on, then those "static" notes are instantly hidden and their
contents are loaded into iframes for editing/display.

The real upshot is that Luminotes in read-only mode is now more useful when
JavaScript is off, and actually displays notes and their contents. This is
very useful for search engine indexing.

Updated all Python unit tests. Still have to get to JavaScript unit tests,
what few their are.
2007-10-16 21:37:12 +00:00
Dan Helfman bbebad528e Renaming new_model to model, now that the old bsddb model is out of the way. 2007-10-11 19:49:00 +00:00
Dan Helfman f1c55ffe9f Fixed bug where password reset form link was broken. 2007-10-11 10:15:22 +00:00
Dan Helfman 43c6f54e9f Merged revisions 401-446 via svnmerge from
svn+ssh://torsion.org/home/luminotes/repos/luminotes/branches/postgres

................
  r402 | witten | 2007-10-04 00:48:49 -0700 (Thu, 04 Oct 2007) | 3 lines

  Initialized merge tracking via "svnmerge" with revisions "1-401" from
  svn+ssh://torsion.org/home/luminotes/repos/luminotes/trunk
................
  r404 | witten | 2007-10-04 01:17:07 -0700 (Thu, 04 Oct 2007) | 2 lines

  Beginning a conversion from bsddb to postgres.
................
  r405 | witten | 2007-10-04 01:18:58 -0700 (Thu, 04 Oct 2007) | 9 lines

  Merged revisions 402-404 via svnmerge from
  svn+ssh://torsion.org/home/luminotes/repos/luminotes/trunk

  ........
    r403 | witten | 2007-10-04 01:14:45 -0700 (Thu, 04 Oct 2007) | 2 lines

    Yay, no more stupid deprecation warnings from simplejson about the sre module.
  ........
................
  r406 | witten | 2007-10-04 15:34:39 -0700 (Thu, 04 Oct 2007) | 4 lines

   * Switched back to Python 2.4 because many Python modules in Debian are not packaged to work with Python 2.5
   * Began removal of all references to Scheduler, @async, yield, and so on.
   * Converted Database.py to support PostgreSQL and updated its unit tests accordingly.
................
  r407 | witten | 2007-10-04 16:34:01 -0700 (Thu, 04 Oct 2007) | 2 lines

  All unit tests for the new model classes now pass.
................
  r409 | witten | 2007-10-05 00:53:56 -0700 (Fri, 05 Oct 2007) | 2 lines

  Reordering some columns and adding some indices.
................
  r410 | witten | 2007-10-05 16:08:37 -0700 (Fri, 05 Oct 2007) | 4 lines

  Now adding trash notebooks to user_notebook table. Also switching db
  conversion/verification tools back to require Python 2.5, since they still use
  the old Scheduler, which requires 2.5 generator features.
................
  r411 | witten | 2007-10-06 16:26:56 -0700 (Sat, 06 Oct 2007) | 2 lines

  Lots more unit tests passing. Most of the recent work was on controller.Users and related stuff.
................
  r412 | witten | 2007-10-07 01:52:12 -0700 (Sun, 07 Oct 2007) | 2 lines

  controller.Users unit tests now finally pass!
................
  r413 | witten | 2007-10-07 02:14:10 -0700 (Sun, 07 Oct 2007) | 3 lines

  Got controller.Root unit tests passing.
  Moved fake sql_* function shenanigans from Test_users.py to Test_controller.py, for use by other controller unit tests.
................
  r414 | witten | 2007-10-08 23:11:11 -0700 (Mon, 08 Oct 2007) | 2 lines

  All unit tests pass! Fuck yeah!
................
  r415 | witten | 2007-10-08 23:13:07 -0700 (Mon, 08 Oct 2007) | 2 lines

  Removing all references to Scheduler from luminotes.py
................
  r416 | witten | 2007-10-08 23:54:51 -0700 (Mon, 08 Oct 2007) | 3 lines

  Converted deleted_from to deleted_from_id in a few more places.
  Fixed bug in Users.contents().
................
  r417 | witten | 2007-10-09 00:11:59 -0700 (Tue, 09 Oct 2007) | 3 lines

  Typo fix in Note sql method.
  Adding autocommit flag to Database.next_id() method.
................
  r418 | witten | 2007-10-09 00:13:19 -0700 (Tue, 09 Oct 2007) | 2 lines

  Updating unit test for new auto commit flag.
................
  r419 | witten | 2007-10-09 00:14:09 -0700 (Tue, 09 Oct 2007) | 2 lines

  Removing debugging print.
................
  r420 | witten | 2007-10-09 00:20:55 -0700 (Tue, 09 Oct 2007) | 2 lines

  More sql fixes. I really need some funtional tests that hit the database and exercise the SQL.
................
  r421 | witten | 2007-10-09 00:51:34 -0700 (Tue, 09 Oct 2007) | 3 lines

  Fixed controller.Database handling of tuple as an Object_type.
  Made SQL for user storage calculation better at handling null values and also more succinct.
................
  r422 | witten | 2007-10-09 13:32:16 -0700 (Tue, 09 Oct 2007) | 2 lines

  Converting Wiki.js to trash_id notebook member instead of trash object.
................
  r423 | witten | 2007-10-09 13:42:10 -0700 (Tue, 09 Oct 2007) | 2 lines

  No longer displaying "download as html" on the front page, as people see "download" and think they're downloading the software.
................
  r424 | witten | 2007-10-09 14:24:40 -0700 (Tue, 09 Oct 2007) | 2 lines

  Notebooks.contents() now returns notebooks with correct read-write status.
................
  r425 | witten | 2007-10-09 14:32:25 -0700 (Tue, 09 Oct 2007) | 2 lines

  Fixed reporting of validation errors to the user. Now says "The blah is missing." instead of just "is missing"
................
  r426 | witten | 2007-10-09 17:05:22 -0700 (Tue, 09 Oct 2007) | 2 lines

  No longer redirecting to trash notebook upon login.
................
  r427 | witten | 2007-10-09 17:20:33 -0700 (Tue, 09 Oct 2007) | 2 lines

  Made controller.Database use a connection pool.
................
  r429 | witten | 2007-10-09 20:13:30 -0700 (Tue, 09 Oct 2007) | 2 lines

  Converted initdb.py and updatedb.py to Postgres from bsddb.
................
  r430 | witten | 2007-10-09 20:37:14 -0700 (Tue, 09 Oct 2007) | 2 lines

  Changing error message to remove underscores from variable names.
................
  r431 | witten | 2007-10-10 13:23:30 -0700 (Wed, 10 Oct 2007) | 2 lines

  Removing unused note_title parameter from Wiki.create_editor().
................
  r432 | witten | 2007-10-10 13:25:16 -0700 (Wed, 10 Oct 2007) | 2 lines

  Revision regular expression now supports timezone notation.
................
  r433 | witten | 2007-10-10 14:43:47 -0700 (Wed, 10 Oct 2007) | 2 lines

  Finished implementing ranked ordering for startup notes. (However, there's no way to change the rank from the client yet.)
................
  r434 | witten | 2007-10-10 16:25:19 -0700 (Wed, 10 Oct 2007) | 4 lines

  More strict access checking. Fixed oversight in Postgres DB conversion where,
  in certain controller.Notebook methods, access was only checked at the
  notebook level, not at the note level as well.
................
  r435 | witten | 2007-10-10 17:45:18 -0700 (Wed, 10 Oct 2007) | 3 lines

  Now loading revisions on demand from client when the "changes" button is clicked. Also caching
  loading revisions so subsequent clicks don't have to reload.
................
  r436 | witten | 2007-10-10 21:31:20 -0700 (Wed, 10 Oct 2007) | 2 lines

  Tweaking some of the error handling in Expose and Root so that unhandled errors give a generic error message to the client.
................
  r437 | witten | 2007-10-10 21:33:49 -0700 (Wed, 10 Oct 2007) | 2 lines

  The release script no longer runs initdb.py, because the default database is no longer a single file included in the tarball.
................
  r438 | witten | 2007-10-10 21:40:11 -0700 (Wed, 10 Oct 2007) | 2 lines

  Updated install instructuctions to include use of initdb.py.
................
  r439 | witten | 2007-10-10 21:56:42 -0700 (Wed, 10 Oct 2007) | 3 lines

  Made initdb.py only nuke (drop tables/views) when given a command-line flag.
  Also made install directions more correct.
................
  r440 | witten | 2007-10-10 21:58:48 -0700 (Wed, 10 Oct 2007) | 2 lines

  IE 6 doesn't like commas.
................
  r441 | witten | 2007-10-10 22:08:50 -0700 (Wed, 10 Oct 2007) | 4 lines

  load your notebook. without clicking on "changes", edit a note that has previous revisions. click on "changes". it'll only show
  the most recent revision. fixed by not appending to changes as a result of a save unless the client-side revisions list cache has
  something in it
................
  r442 | witten | 2007-10-10 23:30:41 -0700 (Wed, 10 Oct 2007) | 2 lines

  Forgot to actually save off the new revision as editor.revision.
................
  r443 | witten | 2007-10-11 01:35:54 -0700 (Thu, 11 Oct 2007) | 13 lines

  More intelligent datetime handling:
    * convertdb.py assumes old bsddb database timestamps are Pacific, and then
      converts them to UTC before inserting them into the new PostgreSQL
      database.
    * No longer using naked timezoneless datetime objects in model/controller
      code, except in unit tests that need compatability with pysqlite. Now
      using UTC everwhere.
    * Asking PostgreSQL to give us all timestamps back in UTC.
    * New dependency on python-tz (pytz) package, noted in INSTALL doc.
    * Client now responsible for converting UTC timestamps to local time for
      display.
................
  r444 | witten | 2007-10-11 01:46:09 -0700 (Thu, 11 Oct 2007) | 2 lines

  Tweak to prevent potential race in IE.
................
  r445 | witten | 2007-10-11 01:49:58 -0700 (Thu, 11 Oct 2007) | 2 lines

  Got JavaScript "unit" tests passing again.
................
  r446 | witten | 2007-10-11 01:53:58 -0700 (Thu, 11 Oct 2007) | 2 lines

  Noting that js tests require the Luminotes server on localhost.
................
2007-10-11 09:03:43 +00:00
Dan Helfman 5d860300f1 Removed search options button because:
1. It's confusing. People think you click it to perform the search, then are surprised when it doesn't do that.
  2. Now that the search results are displayed more clearly, there's really no need for a titles-only search option.
2007-09-28 20:31:20 +00:00
Dan Helfman f6da052e88 Self-service password reset functionality, plus full unit tests.
GOD DAMN that was annoying to implement.
2007-09-26 23:49:27 +00:00
Dan Helfman ae329d771a Returning storage usage to the client whenever usage changes. 2007-09-20 22:16:52 +00:00
Dan Helfman 4d736d4821 Lots of work on user storage quotas:
* Each model.User now has a current storage bytes and a rate plan.
 * model.User.to_dict() updated accordingly.
 * Minor Scheduler.add() change to bail of the given thread is None.
 * controller.Users.current() returns current user's rate plan details.
 * controller.Users.update_storage() now takes an optional callback.
 * Various methods in controller.Notebooks responsible for calling controller.Users.update_storage().
 * Added rate plan details to config/Common.py.
 * Added quota utilization colors to style.css.
 * Implemented quota utilization calculation and display in Wiki.js.

Still to-do: Return updated storage bytes where appropriate in controller.Notebook and update the
client accordingly.
2007-09-20 20:36:19 +00:00
Dan Helfman 67c43cbef0 Learned to spell JavaScript. 2007-09-10 19:43:51 +00:00
Dan Helfman 197d65877f * Changed client "recent notes" link to "all notes".
* When you try to load a note called "all notes", load a magic (dynamically-generated) note that
   lists all notes in reverse revision time order.
 * Changed controller.Notebooks.recent_notes() to all_notes().
 * Prevent "all notes" link from showing up when you're in the trash.
 * Prevent link pulldown from showing up for links within read-only notes.
 * Wrote a crappy deletenote tool.
2007-09-04 21:37:48 +00:00
Dan Helfman 658e42aeba Made some changes intended to speed up page loading slightly.
* Blank iframe contents now come from static HTML rather than dynamic CherryPy.
 * Reindented @strongly_expire decorator.
 * Removed one stage of Editor's multi-stage construction.
2007-09-01 23:46:15 +00:00
Dan Helfman 70b3e415f1 * Added new controller.Notebooks.delete_all_notes() method.
* Put UI link in trash to delete all notes.
2007-09-01 21:06:37 +00:00
Dan Helfman d90f21b17a New optional parent_id argument to controller.Notebooks.default() to support "return to notebook" in the trash. 2007-08-29 00:50:46 +00:00
Dan Helfman fd175aa85d No longer sending quite as much data in response to /users/current requests.
Now the client has to explicitly request the inclusion of startup notes.

Also no longer including startup notes or revision lists with every single
serialized Notebook.
2007-08-27 22:37:22 +00:00
Dan Helfman 4887defa83 controller.Notebooks.save_note() now looks for the note to be saved in that
notebook's trash. If found, it first undeletes the note before saving it. This
is necessary if, for instance, you have the same note open in window A and
window B, and then you delete the note in window A and subsequently modify it
and save it in window B.
2007-08-24 20:35:06 +00:00
Dan Helfman 20313728d2 Several changes to handle the case where a note is changed out from under you, due to being saved
from a different window:
 * Made controller.notebooks responsible for preventing unmodified notes from being saved, instead
   of model.Notebook handling this task.
 * Created a revision validator for passing revisions as arguments to exposed methods.
 * controller.Notebooks.save_note() now requires a previous_revision parameter, used to determine
   whether the note has been modified in the particular window it's being saved from.
 * save_note() returns a new previous_revision value, so the client can determine whether a save
   has occurred from another window.
 * controller.Notebooks.undelete_note() fixed to quietly bail if the note to undelete isn't
   actually deleted, which can happen if it was undeleted in another window.
 * Editor() now responsible for making revisions list if it doesn't exist
 * No longer giving an "undo" message when the user deletes an empty note.
 * On the client side, detecting whether the previous_revision as reported by save_note() looks
   correct, and if not, alerting the user about the conflict. Also displaying a "compare versions"
   button that opens both the current version and the previous version.
2007-08-23 23:56:42 +00:00
Dan Helfman 7973d87a7d * Turned "search:" label into a search button that, when clicked, displays a
pulldown with "titles only" and "everything" radio buttons, defaulting to
   "titles only".
 * Wiki javascript code for submitting a search now sends a new titles_only
   parameter according to what the user has selected in the search pulldown.
 * controller.Notebooks.search() now takes a new titles_only boolean argument,
   which does exactly what you would expect.
2007-08-17 22:26:02 +00:00
Dan Helfman 69caeaf655 Code mostly related to manipulating wiki links, plus a new link pulldown:
* Implemented a new controller.Notebooks.lookup_note_id() method to get only a note's id given its title.
 * Added some new link resolution code to Editor and Wiki, to fill in a link's id according to its destination note.
 * Factored out some of the link finding code into a common Editor.find_link_at_cursor() method.
 * Factored out query parsing into a common parse_query() function, which operates on a link node.
 * Added new Link_pulldown class-thingy to represent the little pulldown you see when the cursor's on a link.
 * Refactored Pulldown's positioning code to support offset positioning (needed for elements within an iframe).
2007-08-14 04:13:49 +00:00
Dan Helfman 8fd463e22d More docstrings. 2007-08-09 19:44:26 +00:00
Dan Helfman a866c617ec More API documentation on the controllers. 2007-08-09 19:06:01 +00:00
Dan Helfman f2eac9cb1f Implemented a basic trash, including undo upon note deletion and undeletion from the trash:
* model.Note has a deleted_from member to indicate the notebook id it was deleted from (if any)
 * controller.Notebooks sets the deleted_from member and makes all deleted notes startup notes in the trash
 * new controller.Notebooks.undelete_note() method
 * split up the idea of UI messages into errors and informational messages, with separate CSS
 * updated Editor and Wiki UI code to deal with new deleted_from variable
 * added "undelete" button when viewing a deleted note, and "delete" changes to "delete forever"
 * added a "trash" link to the notebook links
 * reorganized responsibilities for displaying notebook/user links among Wiki.populate() and Wiki.display_user()
 * when deleting messages in a notebook with a trash, displaying "The note has been moved to the trash"...
   with a working undo button!
 * tweaked focusing logic in display_search_results(), which has been renamed to display_loaded_notes()
2007-08-07 01:48:43 +00:00
Dan Helfman 4e28620348 * Added a trash Notebook to model.Notebook.
* Made sure the trash is not exposed by the read-only notebook view.
 * Modified model.User.check_access() to consider read-write access to a
   notebook to be sufficient for access to that notebook's trash.
 * Modified controller.Users so new users are created with a notebook that
   has a trash.
 * Changed controller.Notebooks so deleted notes go to the trash (if any).
2007-08-03 21:12:17 +00:00
Dan Helfman f23fcdde21 * Can now click on revision timestamps to open up the contents of previous note revisions with a small timestamp at the top.
* Revisions can be opened either in the current page or in a new window/tab.
 * Added ability for a read-write notebook to contain read-only notes. This supports showing read-only revisions.
 * Fixed updatedb.py to properly load the anonymous user.
 * Updated initdb.py and updatedb.py to deadl with new-style /notebooks/notebookid?note_id=noteid wiki links.
 * Made Persistent copy the revisions_list on each revision update so different revisions don't share lists.
 * Prevented Note from updating its revision twice upon construction. Now it's only updated once.
 * Work-around for nasty urlparse() caching bug related to unicode strings that cherrypy barfs on.
 * Added optional revision flag to various controller.Notebooks methods to allow opening of a notebook with a particular note revision displayed.
2007-07-31 22:53:57 +00:00
Dan Helfman b7b88f25a3 Accidentally left out of last commit. 2007-07-28 04:23:17 +00:00
Dan Helfman f05d3db661 * Added a "changes" tab with a list of revision timestamps for each note. Note yet clickable.
* Made controller.Notebooks.save_note() return the newly minted revision timestamp upon a successful save.
 * Whenever we get back a revision timestamp from save_note(), we store in in the client's list of revisions for that note.
 * Now raising Access_error in controller.Notebooks in various places where the notebook requested is unknown.
 * Tweaked pulldown CSS a bit. Now will sport a handy-dandy scrollbar if the pulldown gets too tall, at least in real browsers.
 * Fixed bug where clicking "show on startup" checkbox directly didn't visually toggle the checkbox.
2007-07-26 01:18:41 +00:00
Dan Helfman e356b3349e Another work-around for None notes. 2007-07-24 21:12:12 +00:00
Dan Helfman 0129c2a2c3 Schema change to secondary ids are stored with their class, not just their bare id. 2007-07-20 20:05:02 +00:00
Dan Helfman 203a8f9e70 Another filter to skip None notes. 2007-07-19 20:15:07 +00:00
Dan Helfman abd9948588 When downloading the wiki as HTML, skip None notes. 2007-07-18 20:17:58 +00:00
Dan Helfman 0976fdf8c6 Renaming all entries to notes to fit better with the name "Luminotes". 2007-07-17 01:21:31 +00:00
Dan Helfman 02cfca5322 Renaming repository to new name: luminotes 2007-07-16 20:22:38 +00:00