Commit Graph

8254 Commits

Author SHA1 Message Date
Steve Howell 4d03fd984f [notify customer] Add 24hr support for Steve Pomeroy.
We hard coded his feature flag as a response to Z438.

(imported from commit f2637b5610bf69a0d79347586a788b3bb67b19de)
2014-01-16 15:04:54 -05:00
Steve Howell ec91ece6ed Remove "Create new stream" UI for restricted users.
If a user is not allowed to create new streams, then do not
show the "Create new stream" UI at the top of the settings page.

(imported from commit b97626938d8b612317c2189f7eca0d4bd27fc274)
2014-01-16 14:43:57 -05:00
Steve Howell 8bf9068d0b Add back end support to restrict creation of streams.
Note that this doesn't actually restrict anybody yet, but it
makes it so that UserProfile.can_create_streams must return True
for a user to create a stream.  We can modify that in the future
to have special behavior for realms that want more restrictions.

(imported from commit 432e85b1ca86aaee4a6bd1d4a6d0b2c78ecb0863)
2014-01-16 14:43:56 -05:00
Steve Howell f60d5c64c3 Improve admin_user_list.handlebars node test.
Add in "Make admin" button and a couple hasClass checks.

(imported from commit 2f6ccc9bb7f7b589d126911803bdfd7bd8ea3f2d)
2014-01-16 14:41:17 -05:00
Steve Howell 447c99aa66 Add UI for admins to add/remove admin power from other users.
(imported from commit b7e81316f1f1e3c7b7f7dd5dac5db8e70f1ee209)
2014-01-16 13:41:54 -05:00
Steve Howell 6d963c4a85 Always set data.method=PATCH in channel.patch()
(imported from commit 242503c1caa670fa219acbfe811a1b5e5d54f2b6)
2014-01-16 13:41:53 -05:00
Steve Howell 81de08f067 Improve selectors for user activate buttons on admin screens.
(imported from commit 094e81a1a337aeed7cfd39ce61daf6ac50e905cd)
2014-01-16 13:41:53 -05:00
Steve Howell fd5fd7e61b Have /json/users return is_admin flag.
(imported from commit 49b5c621510c47656f92c38bc5b9b1b6381d5c21)
2014-01-16 13:41:53 -05:00
Steve Howell e837f8bf8b Add back end for admins to assign/remove admin.
Add back end for admins to assign/remove admin permissions for other users.
The /json/users/<email> endpoint allows you to PATCH is_admin.

(imported from commit bb5e6d44d759274cc2a7cb27e479ae96b2f271b5)
2014-01-16 13:41:53 -05:00
Jessica McKellar a1d128b6cb Flush memcached on a stream privacy change.
Otherwise uninvited users can join a stream recently turned
invite-only.

(imported from commit ab43bf3b856a0e3b71e6e06cee1519214b7763cd)
2014-01-15 17:13:56 -05:00
Steve Howell 07b2eed389 Add README.zulip.md for handlebars.
(imported from commit a1e214d4bfbd1c0e6dc3918ad649c20e921399db)
2014-01-15 16:45:22 -05:00
Tim Abbott 6443aead67 Fix scrolling when unnarrowing after reading new messages.
Our logic for unnarrowing when messages were read during the narrow
did not properly use the then_scroll option and thus actually set the
scroll position when they selected a new message.  This was
accidentally prevented from being a big problem by the incorrect
scrolling logic that was fixed by:

    Only preserve_pre_narrowing_screen_position when preserving pointer.

which caused the browser to scroll _back_ to close to the correct
scroll position (but not the intended scroll position -- it would
usually be a little bit off).

(imported from commit d779de8f89590d242f62d32b22a297bdc096c594)
2014-01-15 16:07:20 -05:00
Zev Benjamin fa097a1201 Remove jquery.highlight
The one call we were making to it was actually unnecessary since highlighting is
no longer done client-side.

(imported from commit 7644a5961ca48cd57f4b65c6f698083677e0a130)
2014-01-15 16:07:20 -05:00
Steve Howell 3bd0bfd4fd Upgrade handlebars to 1.3.0.
This was "npm update handlebars" followed by copying
runtime.js into the static directory and restoring the
copyright header.

(imported from commit 69d30cbfcb3b776cdfdcffa17a87704540eab76a)
2014-01-15 16:07:20 -05:00
Zev Benjamin f015d27d31 Disable historical search whenever the 'is' operator is present
Previously we only disabled it for 'is:starred'.  This caused a backtrace when
someone searched for, say 'stream:test is:mentioned', because we weren't joining
on zerver_usermessage, which meant the flag wasn't available to filter on.

(imported from commit ba19f8a74b21d60b89dfc8dbe9c8458ed86b423b)
2014-01-15 16:07:20 -05:00
Zev Benjamin d8d1d6ea40 Fix narrowing to PMs with yourself
(imported from commit 1326fa7ae779ba6476165e8838e46ce1323e3ecb)
2014-01-15 16:07:19 -05:00
Waseem Daher 9eed2c50b9 email-mirror: Support '.' as an alternate for '+' (and bugfix).
Google Groups won't let you add an email address that has a '+' in it
as a member of a group, so we allow '.' as well.

This commit also fixes a current issue with email mirroring, where it
doesn't work if you had a + in the stream name.

This fixes Trac #2102.

(imported from commit 9a7a5f5d16087f6f74fb5308e170a6f04387599e)
2014-01-15 16:07:19 -05:00
Jason Michalski 60f878b45e Limit cross-realm private messages to zulip.com users
Cross-realm private messages are only used to respond to support
requests. So now cross-realm private messages are only allowed if
exactly two realms are in the private message and one of them is
zulip.com.

(imported from commit f01a2824e214682acb22a6995714a9d1b0d0c66f)
2014-01-15 16:07:19 -05:00
Luke Faraone b1cf9c3e25 Rewrite email-mirror documentation.
(imported from commit 4af076b3063d7b82657765c12cf4dba0248cbf9f)
2014-01-15 16:07:19 -05:00
Luke Faraone 895b7dc9b1 Accept emails on stdin in email-mirror and queue for later processing
(imported from commit 7efccc294f87d3661e50f10962a80071b91e3879)
2014-01-15 16:07:18 -05:00
Luke Faraone fbb2b6945b Queue worker for email mirror processing.
(imported from commit b60049c84622ea457db38c5a5b185bcd108bc59f)
2014-01-15 16:07:18 -05:00
Luke Faraone 0b5036e0fb Let message recipient in process_message be passed as an argument.
(imported from commit cfcfb9edf748a35d279235ee11a05b1a00c934b5)
2014-01-15 16:07:18 -05:00
Luke Faraone 1005e2ae7c Use module docstring for usage information
(imported from commit 7c1cbf68eca4e3f31c75bfe13b50654e76be0df3)
2014-01-15 16:07:18 -05:00
Jessica McKellar cf5b7dc0e4 Don't send digests to CUSTOMER29 teams.
(imported from commit c1dbb6607647e65082535d4e37d50d7842f8758f)
2014-01-15 16:07:17 -05:00
Jessica McKellar f85d45a781 Add a management command to bulk turn off digests.
(imported from commit 0ffb565ecc9be219807ae9a45abb7b0e3e940204)
2014-01-15 16:07:17 -05:00
Tim Abbott 86f9ea0cd2 Move save_narrow earlier in narrow.deactivate.
I think that this will fix the issues we've been having with
hashchange.save_narrow() screwing up the scroll position in the page.

(imported from commit 25af9b7dda2d107220e11dd12b9dc344bc63addc)
2014-01-15 16:07:17 -05:00
Waseem Daher 4d5d0d636f casper-tests: Stop looking for full name.
We've removed it from the layout, so we should stop searching
for it in our tests.

(imported from commit 456c9794423d304f31a1d06215a51fae425df826)
2014-01-15 16:05:53 -05:00
Steve Howell 1887b59504 Have the ENTER key blur people searches.
This is important for hotkey users to be able to use other hotkeys.
Since ESC clears a search, we need ENTER to merely blur the search;
otherwise, hotkey users will need to mouse away from the search box
if they want to keep the search sticky.

(imported from commit 204704435c7821c1ad3b7b750ffe3545adaff9aa)
2014-01-15 16:05:52 -05:00
Steve Howell aae001fa8e Have ESC key clear people searches.
(imported from commit a3f4cf0416f4f2ea76660bf68790988edc5675e2)
2014-01-15 16:05:52 -05:00
Steve Howell fafb6f3bb5 Say "Search people" in user search box.
(imported from commit 901dc984dc19d8f21baff41ce700d0cbcd6fbdbb)
2014-01-15 16:05:52 -05:00
Steve Howell 33494dc342 Reduce the width of the user search box.
(imported from commit 715175c51f292a89ad68fa780b94c332fdd1f436)
2014-01-15 16:05:52 -05:00
Steve Howell 85ff523965 Simplify filtering code in actually_update_users().
(imported from commit d11e56f5708bd3e5e52bc6452676a0fe2be17900)
2014-01-15 16:05:52 -05:00
Steve Howell 892b4b5db2 Remove user from his/her own buddy list.
(imported from commit 388a95b8f1b9c2a7622e1e083d3601c4015682e7)
2014-01-15 16:05:51 -05:00
Jason Michalski d14e200ecd Add missing colon after Assignee
(imported from commit 18dd6d1fd80012b2e3337cdbfa893028d241326f)
2014-01-15 16:05:51 -05:00
Tim Abbott 7e301425fc Optimistically call restart_get_updates on Socket reconnect.
(imported from commit 0804969f964e65ed2d2e0a64d56d5f591d12e0ef)
2014-01-15 16:05:51 -05:00
Tim Abbott 2ebb962114 Enable USING_RABBITMQ for all development systems.
(imported from commit ffe5f3f8210372479051b5f1908a7efc12398ef8)
2014-01-14 12:09:15 -05:00
Tim Abbott c943ca6b0d Fix compose_invite_users alert bar being being visible on page load.
(imported from commit 6b233f4a05d5d76b7ca7bb9d499ed284c6384b8a)
2014-01-14 12:09:14 -05:00
Tim Abbott 43f6ce9624 Keep compose box open in embedded narrow views.
(imported from commit 0e5f44505a58ed77a5fee7b6b2024fce62e8b07b)
2014-01-14 12:09:14 -05:00
Tim Abbott dfcb7529ed Disable desktop notifications in embedded narrow windows.
(imported from commit 327f64eb1c7119ccf6e595b9f9748293a06b5b0b)
2014-01-14 12:09:14 -05:00
Jason Michalski 42d561546b Add integration documentation for Zendesk
(imported from commit fb719144cc4fce7c8a794da1abb747595e2c239c)
2014-01-14 12:01:54 -05:00
Jason Michalski 4b86ef59f1 Added Zendesk webhook
Zendesk works a lot like desk.com, it has triggers which use targets.
The triggers have a user defined template. Targets can also have place
holders that are posted, we add the ticket id and title here so we can
always construct the message subject.

(imported from commit 04e8e5c7c0fc5568201f252546f6ed42f282fd00)
2014-01-14 12:01:54 -05:00
Zev Benjamin 3679889be2 Remove extraneous function argument
(imported from commit 4f90f98632077c771ac3123051a6d1a2804fb168)
2014-01-14 11:47:12 -05:00
Zev Benjamin 45ab625616 Add tests for get_old_messages DB queries
(imported from commit 1d6c871e6ac56324a129567e1ba447d44197a0aa)
2014-01-14 11:47:12 -05:00
Zev Benjamin ced2f86fd7 Add an IS_WORKER setting that is True when the current process is a worker
(imported from commit f8976b8345e9c709c2336a17d18260130f3f2562)
2014-01-14 11:47:12 -05:00
Zev Benjamin db23674749 Do query time tracking at the psycopg2 level instead of the Django level
This allows us to track the query time of SQLAlchemy and raw queries.

(imported from commit 818a4ee41786ffc57b80d7ed1cfba075f29b6ee5)
2014-01-14 11:47:12 -05:00
Zev Benjamin df4d4beb6c Add TODO comment to messages_in_narrow_backend
(imported from commit 7e80a84fdd8f6ba347bb4ecb0f9238923b825871)
2014-01-14 11:47:12 -05:00
Zev Benjamin 81010c6c3d Clean up imports
(imported from commit f80891c6ae3c00daeafed3b504d24a6722f03a82)
2014-01-14 11:47:12 -05:00
Zev Benjamin 64c6bfecac Remove use_raw_query special case in get_old_messages_backend
The normal code will now generate SQL that is basically identically to the raw
SQL we were using before.

(imported from commit 84a3971d6137d05ef3f71252278afdd59041e86a)
2014-01-14 11:47:12 -05:00
Zev Benjamin fe6dc2ef81 Port get_old_messages to use SQLAlchemy
This commit also includes a few changes in the way we do some queries that
should speed searches up:

* Messages before and after the anchor are fetched in a single query by doing a
  UNION ALL on the server.  This incurs the cost of an extra sort because UNION
  ALL does not guarantee the order that the results are appended, but it saves a
  server round-trip.
* Searches involving flags now use a straight froward WHERE clause, which is
  much faster than the one that django-bitfield generates (due to limitations of
  the Django ORM)

(imported from commit a0db811a9073363cfabcf4b035d02d20dc8fc8a4)
2014-01-14 11:47:12 -05:00
Zev Benjamin ab1aafeb1c puppet: Add python-sqlalchemy dependency
(imported from commit 1ed6a8a730d368a97fad6cd478ec13e75504b789)
2014-01-14 11:47:12 -05:00