Archived
1
0
Commit Graph

1546 Commits

Author SHA1 Message Date
Dan Helfman
13bc06295f Changing the storage usage calculation algorithm to not count old notebook revisions. 2007-09-21 19:15:02 +00:00
Dan Helfman
c5a2b3900f Sigh. IE commas. 2007-09-20 23:34:34 +00:00
Dan Helfman
212f516aeb uh, whoops 2007-09-20 23:30:09 +00:00
Dan Helfman
68d07a6fc8 Adding "ok" button to all messages/errors.
Making quota warning messages not disappear as soon as it's displayed.
2007-09-20 23:25:59 +00:00
Dan Helfman
f1caee29a4 Removed trash link in quota warning, because we don't have access to this.notebook there. 2007-09-20 23:07:24 +00:00
Dan Helfman
c5c4498d19 Warning displayed when you're nearing your storage quota. 2007-09-20 22:59:00 +00:00
Dan Helfman
c9bd2ae576 Now updating storage utilization on client in "realtime" as a result of user actions. 2007-09-20 22:26:43 +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
ebf1538313 model.User now has a storage_bytes member, and controller.Users has a method for calculating and updating this field. 2007-09-13 00:53:49 +00:00
Dan Helfman
2e75521ac2 controller.Users.calculate_storage() method to calculate the total bytes used by a particular user. 2007-09-12 22:42:46 +00:00
Dan Helfman
8e7749d512 controller.Database.size() function for getting the approximate storage size of an object. 2007-09-12 21:28:28 +00:00
Dan Helfman
52409fc1a1 Got rid of annoying blue lines/spacing around notebook border. 2007-09-11 21:11:59 +00:00
Dan Helfman
d4d41c9d48 Now replacing/refreshing "all notes" when it's already open and you click the "all notes" link again. 2007-09-11 19:19:03 +00:00
Dan Helfman
49a692f378 Intentionally *not* showing a link pulldown when you start a link and begin
typing. Only showing the pulldown when you end the link (or when you navigate
away and then come back).
2007-09-11 00:10:44 +00:00
Dan Helfman
1f87db664b Makes slightly more sense with this change. 2007-09-10 21:59:54 +00:00
Dan Helfman
060b0b6845 Overhauled display of search results. Now displaying a "magic" search results
note containing a list of search results along with previews of the display
notes.
2007-09-10 20:04:46 +00:00
Dan Helfman
67c43cbef0 Learned to spell JavaScript. 2007-09-10 19:43:51 +00:00
Dan Helfman
7634393431 Reverting previous change since it has the unwanted side-effect of making link pulldowns stay open too long. 2007-09-08 00:21:33 +00:00
Dan Helfman
57c456d839 If you started a link and began typing, the link pulldown appeared when you type a space, even if the link isn't done. 2007-09-08 00:12:42 +00:00
Dan Helfman
78d5845140 Fixing broken "all notes" link. Sigh. 2007-09-07 23:58:03 +00:00
Dan Helfman
6620dbb8cf Added info about JavaScript unit tests. 2007-09-07 23:54:31 +00:00
Dan Helfman
773ea3bf2b If a link had title "all notes" but a different link id for the destination,
and you clicked on the link without opening the link pulldown first, then the
link would open up "all notes" instead of the correct link destination.
2007-09-07 23:46:01 +00:00
Dan Helfman
ecf44bdf6e Made code dealing with "all notes" in link pulldown work better (or at all). 2007-09-07 23:03:12 +00:00
Dan Helfman
7e67181be9 Test for editor.empty(). 2007-09-07 22:17:08 +00:00
Dan Helfman
0e8f557ae4 Forgot to checkin Stub_editor.js previously.
Also, factoring out Editor test setup into Editor_setup.js for reuse.
Added test for Editor.contents().
2007-09-07 22:07:43 +00:00
Dan Helfman
707c3dbc02 Test_editor() function that actually runs. 2007-09-07 21:39:01 +00:00
Dan Helfman
3955bcb8b9 Wrote a very basic stub editor for testing the Wiki class.
Made test for Editor() constructor slightly more useful.
2007-09-07 21:05:39 +00:00
Dan Helfman
ae347d0e3b Wrote stub invoker for testing purposes and made use of it in Test_wiki.html. 2007-09-06 21:36:39 +00:00
Dan Helfman
779769ae79 Fixed inexplicable IE test failure. Maybe focus is a reserved keyword? 2007-09-06 20:18:08 +00:00
Dan Helfman
61c6ab3fb0 Beginning stubs for client-side javascript "unit" tests. (Probably more like
functional tests, unless a whole lot of mock objects are introduced, which
isn't entirely out of the question). Uses JsUnit, which is included in this
commit.
2007-09-06 10:25:06 +00:00
Dan Helfman
e747e9c2ff Reverting r333 and making alternate fix for duplicate notes when repeatedly
clicking links, because r333 broke link pulldown title grabbing. Must..
write.. unit.. tests!
2007-09-06 08:27:41 +00:00
Dan Helfman
ae342ac5d6 Preventing opening of dup notes from note links. 2007-09-05 23:49:25 +00:00
Dan Helfman
f7b97fb41d Don't create duplicate "all notes" when opened from a note link. 2007-09-05 23:44:34 +00:00
Dan Helfman
5aaf0d6276 Reverting to earlier behavior: Options pulldown doesn't close if you click a checkbox. 2007-09-05 23:11:19 +00:00
Dan Helfman
439fd49880 Prevent one note from "shadowing" another note with the same name. Previously,
if you clicked a link with a note id and a note with the link's title was
already open, it just highlighted that note, regardless of the id. Now, that
will only happen if the link has no id.
2007-09-05 19:54:04 +00:00
Dan Helfman
8a2c872e0a Fixing IE extra comma bug. 2007-09-05 19:06:33 +00:00
Dan Helfman
b6204179c9 No hide button while in the trash. 2007-09-05 18:57:50 +00:00
Dan Helfman
ad7c6aca7f Removing unused insert_after_iframe_id parameter. 2007-09-05 18:53:42 +00:00
Dan Helfman
f21610eaf7 * In the trash, now showing "the trash is empty" when you delete/hide/undelete enough notes to make it empty.
* Wiki.create_editor() returns the editors it just created.
 * Wiki.open_editors initialized with startup notes.
2007-09-05 18:49:28 +00:00
Dan Helfman
7bf6d8685f Changing "This notebook is empty." from error to message. 2007-09-05 07:37:04 +00:00
Dan Helfman
ce4c49d87e There's now a link to the trash in the "This note has been moved to the trash." message. 2007-09-05 07:34:59 +00:00
Dan Helfman
c7d4643264 Adding a little down arrow to "search" button to indicate it's a pulldown. 2007-09-05 02:34:48 +00:00
Dan Helfman
259002efe0 Clicking the background now closes any open pulldowns. 2007-09-05 02:30:15 +00:00
Dan Helfman
295369bad5 None notes are skipped. 2007-09-04 23:27:50 +00:00
Dan Helfman
fb511f61ac Reverting previous try/catch "fix" in favor of a simpler solution. 2007-09-04 22:31:32 +00:00
Dan Helfman
47c24a9c1b Not sure why this is necessary, but if querying for formatblock fails, just assume heading is ""; 2007-09-04 22:12:44 +00:00
Dan Helfman
e2079bbca8 Fixed problem with note titles being incorrectly set for notes containing multiple sets of <h3></h3> titles.
The solution involved making the regular expression for title parsing non-greedy.
2007-09-04 22:01:42 +00:00
Dan Helfman
a7ca76f611 Minor fix. 2007-09-04 21:40:21 +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