Commit graph

374 commits

Author SHA1 Message Date
redmatrix
84c085dcd7 bare bones ASLD 2015-05-31 22:16:14 -07:00
friendica
cbaa2a9b84 don't included any deleted posts in the self query 2015-03-30 21:06:41 -07:00
friendica
2bd19e6b51 $simple_update isn't so simple any more. Make sure we don't re-itnroduce the bug that session['loadtime'] was created to fix. It's questionable whether we still need to even look for item_unseen but I won't make that call today. We can also eliminate the restriction on not doing live updates from the discover tab since we aren't relying completely on item_unseen (which can only be set by the owner and won't work on a page with virtual owners). 2015-03-22 15:00:41 -07:00
friendica
6631540d20 provide visual feedback when deleting a like by liking it again. 2015-03-22 12:55:13 -07:00
friendica
b298bc8834 Merge https://github.com/friendica/red into pending_merge 2015-03-21 16:47:46 -07:00
friendica
a2e3ca6fd8 add loadtime search to channel and fix it for home. display and search need further investigation 2015-03-21 16:46:28 -07:00
Mario Vavti
9980645ab8 fix acl for if we have an cid in /network and make $bang better visible 2015-03-21 13:37:55 +01:00
Mario Vavti
ead45292e1 some tabs title statuseditor restructuring 2015-03-21 00:06:18 +01:00
friendica
629f6bec74 ok it has to be owner. 2015-03-17 15:45:08 -07:00
friendica
cc2c7bbcd8 revert the revert - that is working. My test was bad. 2015-03-14 01:03:37 -07:00
friendica
88167718ba revert and rethink 2015-03-14 00:51:16 -07:00
friendica
b76cdf82d2 create terms for Diaspora mention tags - which in Diaspora are handled differently than other tag links and have to be done separately; they aren't processed by linkify_tags which handles all of our other tag processing. Also move the abook_channel clause in mod_network to the join statement. This works fine in mysql and achievies the desired result. I hope postgres can handle an expression as a join clause. 2015-03-13 19:24:17 -07:00
zottel
e732fbe8e8 fix posts not showing up in network if author is not in connections 2015-03-14 00:22:47 +01:00
friendica
7d5efe88e0 use local_channel() connnections to match the abook against when joining the abook on the discover tab. 2015-03-13 15:39:19 -07:00
friendica
02a58dc5b0 more JS=1 weirdness 2015-03-12 16:20:29 -07:00
friendica
9d1df58759 sql optimisation for affinity searches. A new index was added which wasn't added retro-actively to existing DBs as an update. It isn't clear if this helps sites any more than just restricting the abook table to certain channel_id's is (and this field is already indexed). 2015-03-10 18:55:56 -07:00
friendica
26a414fe4b make network page default options work more or less universally instead of just from the navbar, and fix some saved-search weirdness related to the delete-term icon 2015-03-09 16:27:12 -07:00
friendica
084ca3f4a1 typo 2015-02-12 18:49:42 -08:00
friendica
da2349bb6a provide relief to sites that are severely impacted by the slow ITEM_UNSEEN searches. This does not incorporate any other flag optimisations as that will require a major DB update and possibly involve significant downtime. This is just to bite off a little chunk now and provide some much needed relief. 2015-02-12 17:45:25 -08:00
friendica
a496036066 local_user => local_channel 2015-01-28 20:56:04 -08:00
friendica
a93f2b1b8f now that's useful... 2015-01-13 18:41:11 -08:00
friendica
e528483d81 hide friends broken, add parameter for item search by verb 2015-01-13 14:42:54 -08:00
friendica
f28103d595 wall tags 2014-12-15 14:37:31 -08:00
friendica
db3015e34e allow members to set the per-item "show more" height (separately for network and matrix, display and search are system pages and therefore set at 400) 2014-11-17 23:48:03 -08:00
friendica
c0ad4763b3 add unseen count and way to mark unseen to list mode. Also fix automatic mark of unseen so as to work with list mode. 2014-11-17 15:18:06 -08:00
friendica
591f10e235 module cleanup 2014-11-16 19:08:10 -08:00
friendica
cbaee76dd9 "list mode" (forum and blog mode, no comments or comment boxes displayed on the summary page) 2014-11-16 16:19:24 -08:00
Habeas Codice
1a5a5c7edb PostgreSQL support initial commit
There were 11 main types of changes:
- UPDATE's and DELETE's sometimes had LIMIT 1 at the end of them. This is not only non-compliant but
it would certainly not do what whoever wrote it thought it would. It is likely this mistake was just
copied from Friendica. All of these instances, the LIMIT 1 was simply removed.
- Bitwise operations (and even some non-zero int checks) erroneously rely on MySQL implicit
integer-boolean conversion in the WHERE clauses. This is non-compliant (and bad programming practice
to boot). Proper explicit boolean conversions were added. New queries should use proper conventions.
- MySQL has a different operator for bitwise XOR than postgres. Rather than add yet another dba_
func, I converted them to "& ~" ("AND NOT") when turning off, and "|" ("OR") when turning on. There
were no true toggles (XOR). New queries should refrain from using XOR when not necessary.
- There are several fields which the schema has marked as NOT NULL, but the inserts don't specify
them. The reason this works is because mysql totally ignores the constraint and adds an empty text
default automatically. Again, non-compliant, obviously. In these cases a default of empty text was
added.
- Several statements rely on a non-standard MySQL feature
(http://dev.mysql.com/doc/refman/5.5/en/group-by-handling.html). These queries can all be rewritten
to be standards compliant. Interestingly enough, the newly rewritten standards compliant queries run
a zillion times faster, even on MySQL.
- A couple of function/operator name translations were needed (RAND/RANDOM, GROUP_CONCAT/STRING_AGG,
UTC_NOW, REGEXP/~, ^/#) -- assist functions added in the dba_
- INTERVALs: postgres requires quotes around the value, mysql requires that there are not quotes
around the value -- assist functions added in the dba_
- NULL_DATE's -- Postgres does not allow the invalid date '0000-00-00 00:00:00' (there is no such
thing as year 0 or month 0 or day 0). We use '0001-01-01 00:00:00' for postgres. Conversions are
handled in Zot/item packets automagically by quoting all dates with dbescdate().
- char(##) specifications in the schema creates fields with blank spaces that aren't trimmed in the
code. MySQL apparently treats char(##) as varchar(##), again, non-compliant. Since postgres works
better with text fields anyway, this ball of bugs was simply side-stepped by using 'text' datatype
for all text fields in the postgres schema. varchar was used in a couple of places where it actually
seemed appropriate (size constraint), but without rigorously vetting that all of the PHP code
actually validates data, new bugs might come out from under the rug.
- postgres doesn't store nul bytes and a few other non-printables in text fields, even when quoted.
bytea fields were used when storing binary data (photo.data, attach.data). A new dbescbin() function
was added to handle this transparently.
- postgres does not support LIMIT #,# syntax. All databases support LIMIT # OFFSET # syntax.
Statements were updated to be standard.

These changes require corresponding changes in the coding standards. Please review those before
adding any code going forward.

Still on my TODO list:
- remove quotes from non-reserved identifiers and make reserved identifiers use dba func for quoting
- Rewrite search queries for better results (both MySQL and Postgres)
2014-11-13 12:21:58 -08:00
friendica
e8854bb19d better way to deal with effective_uid 2014-09-22 22:03:19 -07:00
friendica
fb05919d90 make discover items interactive 2014-09-22 21:37:19 -07:00
friendica
c061cc0955 sql string unquoted 2014-07-22 04:37:51 -07:00
friendica
68b7dc48bb the "page 2 shows up on top of page 1 when you wake up in the morning" bug. See the comments. 2014-07-21 21:15:03 -07:00
friendica
476675e211 get rid of some old crap 2014-06-17 21:51:20 -07:00
marijus
9f621dac85 change the way jot tools are displayed/hidden 2014-04-08 22:07:06 +02:00
Thomas Willingham
4a2805e12e Missed one 2014-03-30 23:01:31 +01:00
Thomas Willingham
1093e8d83e Default discover to on. 2014-03-30 22:59:37 +01:00
Alexandre Hannud Abdo
fedd19ec95 Let the site admin choose whether to display the Discover tab. 2014-03-30 00:03:12 -03:00
friendica
a0674af416 firehose fixes and optimisations. In particular get rid of the unresponsive script warning when trying to load updates (sine they aren't our posts, we can't check for unseen, hence we can't really load updates). Also make the url selection pluggable. 2014-03-27 15:35:29 -07:00
friendica
a5a55738bc superfluous comma 2014-03-27 00:07:11 -07:00
friendica
3044dc7f6d catch the "new" view as well 2014-03-26 22:11:34 -07:00
friendica
5a3903a40c firehose testing (network?f=&fh=1) - some possible security bugs so testing purposes only 2014-03-26 22:05:19 -07:00
friendica
7910221832 preparatory work for supporting a "list view" mode for conversations. This would be useful for forum-like channels and/or block-oriented themes. 2014-01-08 15:20:12 -08:00
friendica
1a42580ad4 remove a couple of mysql reserved words from being used as table or row names. For this round we're getting 'group' and 'desc'. Warning: potentially destabilising as this touches a lot of code. 2013-12-22 18:37:39 -08:00
friendica
941f81eb30 check that every invocation of htmlspecialchars has the right arg list 2013-12-12 02:01:42 -08:00
friendica
b4e1e8a4a4 The affinity tool is not a "traditional" widget. But it is nevertheless a widget. It just makes fewer page layout decisions which are hard-coded. If you want to shrink it down and put it on the sidebar in your theme, go for it. 2013-12-11 19:43:41 -08:00
friendica
0043ef66b6 mod_network is now running under Comanche. Yay. 2013-12-10 00:25:32 -08:00
friendica
e873f6e95e we're almost ready to turn on comanche for mod_network. All the widgets are done. 2013-12-10 00:05:31 -08:00
friendica
ed9f108722 comanchify the savedsearch widget 2013-12-09 21:20:55 -08:00
friendica
f85cba10eb notes widget 2013-12-09 15:27:46 -08:00
friendica
082ac67778 suggestion widget tweaked to make it comanche capable. Remove old versions of specs that are so obsolete it isn't funny. Zot protocol reference is in red's github wiki, and in the code. We should move the github copy to /doc once it is updated to match the code. There's no point in documenting dfrn in the red code base. 2013-12-08 20:08:50 -08:00