Commit Graph

55 Commits

Author SHA1 Message Date
Barış Soner Uşaklı
97c086aba9 fix: missing await 2020-05-12 12:18:30 -04:00
Barış Soner Uşaklı
aad0880f7c feat: add filter:categories.getRecentTopicReplies
pass req.query to getRecentTopicReplies
2020-05-08 22:36:16 -04:00
Opliko
b9583ed838 Add privilege for accessing user information (#7859)
* Add view users info global privilege

* Show user ip only to global mods and admins

* fix missing comma

* Hide link for users without correct privilege

* move getting privilege information to getAllData

* Hide the link from Global Moderators as well

* Give Global Moderator view:users:info privilege

* Restrict ip in post menu to view:users:info

* add some trailing commas....

* Add privilege to categories test

* Add group privilege to categories test

* add upgrade script

* fix style for TravisCI

* more styling - change spaces to tabs

* some more styling fixes (hopefully final one)

* fix style for Travis CI

* hide ip in chat messages

* Don't show even hidden ips on user profile page
2019-09-17 14:02:52 -04:00
Barış Soner Uşaklı
bd640a1107 Topic await errors (#7727)
* feat: derp await

* feat: restore user.getSettings

* feat: cleanup

* feat: make tid const

* feat: cleanup

* fix: tests

* feat: deprecate filter:controllers.topic.get

* feat: rewrite post-index logic

* feat: change calculation to match others

* fix: use .async

* feat: remove try/catch wrapper
2019-07-03 12:48:26 -04:00
Barış Soner Uşaklı
8aef689f05 fix: no need for moderate bit for global mods and admins 2019-05-30 20:12:04 -04:00
Barış Soner Uşaklı
035f624758 Remove implicit mod privs. closes #6345 (#7648)
* feat: add upgrade script to give mods privs

* feat: give all privileges when making a moderator

* feat: remove implicit privs

* feat: give global mods default privs

* feat: more priv fixes

* feat: use lodash

* fix: remove implicit mod priv from topic delete

* fix: more privs

* fix: posts.canEdit

* fix: canDelete and canEdit

* fix: tests, remove console.log

* feat: shorter functions

* feat: add tests

* fix: uids

* fix: redis random test fail
2019-05-30 19:30:47 -04:00
Baris Usakli
64679b37cc fix: #7647, fix getModeratorUids
sets.groupNames is an array that contains other arrays of groupnames so passing it to getMembersOfGroups returned wrong results when there were more than 1 element in it.
2019-05-29 15:44:33 -04:00
Barış Soner Uşaklı
dfab231afd Copy group privs (#7610)
* feat: ability to copy a groups privileges

ability to copy a group's privileges to all categories, or children of current category

* feat: switch to dropdown

added copy from category to groups

* fix: indents
2019-05-15 20:56:23 -04:00
Barış Soner Uşaklı
2ee2cd528f feat: #7501 2019-04-02 11:56:03 -04:00
Barış Soner Uşaklı
c72da5595a fix: #6806
3 new global privileges
view:users
view:tags
view:groups
2019-02-05 12:08:18 -05:00
Barış Soner Uşaklı
9d1fcf4e36 fix: closes #7217 2019-02-04 14:16:47 -05:00
Baris Usakli
7809ba2800 fix: #7193, closes #7194 2019-01-04 13:27:41 -05:00
Barış Soner Uşaklı
eb7ae54f81 Category watch state (#7109)
* feat: wip, category watch change

* feat: pass data to client

* feat: allow changing state

* fix: account page categories

* fix: show in unread if topic is followed or category is watched

* feat: add default watch state to acp

* feat: save user category watch state

* feat: update unread recent pages

* fix: remove dupe code

* fix: flip conditions

* fix: handle empty arrays

* fix: ignore/watch on others profile

* feat: upgrade script for category states

if there are any users ignoring categories set their state in new zset and delete cid:<cid>:ignorers

* fix: upgrade

* fix: tests

* fix: redis count

* fix: more tests
2018-12-14 16:24:17 -05:00
Baris Usakli
d3c6cba33f closes #7060 2018-12-05 11:22:44 -05:00
Barış Soner Uşaklı
a63ddbe2aa fix: #7040
if category doesn't exist return null and 404
2018-12-01 17:15:38 -05:00
Baris Usakli
cd46febdd0 fix lint 2018-11-30 14:40:49 -05:00
Baris Usakli
b86f155690 fix: #7037 2018-11-30 14:25:54 -05:00
Baris Usakli
3c611d85ed closes #6912
- on category setParent dialog do not show children of current category
- break recursion if category parentCid is equal to child cid to prevent
infinite loop
- dont allow setting the parentCid of a category to one of it's children
2018-11-06 13:34:29 -05:00
Barış Soner Uşaklı
c738dc7d3e remove some more parseInts 2018-10-22 21:58:34 -04:00
Barış Soner Uşaklı
ee2f9e9434 remove some parseInts 2018-10-20 17:55:13 -04:00
Baris Usakli
baf91089a6 remove unused methods 2018-10-17 15:23:46 -04:00
Barış Soner Uşaklı
805da98a36 remove unnecessary groups.resetCache calls 2018-09-30 13:42:33 -04:00
Barış Soner Uşaklı
77beaf2e15 Allow local login,closes #6800 (#6803)
* WIP

* reset groups cache after every suite
2018-09-29 06:49:41 -04:00
Julian Lam
8d41e319ea fixed tests 2018-06-08 16:17:17 -04:00
Julian Lam
510dd268cc fix tests 2018-06-07 14:00:51 -04:00
Barış Soner Uşaklı
a7267df404 closes #6464 2018-05-28 11:29:41 -04:00
Barış Soner Uşaklı
8e8058ec6e closes #6497 2018-05-25 12:09:27 -04:00
Barış Soner Uşaklı
e1c6761087 closes #6258 2018-02-28 17:38:31 -05:00
Baris Usakli
ecf6c0f3ec closes #4652 2018-01-09 14:33:23 -05:00
Barış Soner Uşaklı
ff6c6a54c1 make upload permissions global
give upload image permission to registered users on install
add global privileges to app.user.privileges for client side use
2018-01-03 13:27:34 -05:00
Barış Soner Uşaklı
7fe9366103 Merge remote-tracking branch 'refs/remotes/origin/master' into develop 2017-06-16 17:35:45 -04:00
Barış Soner Uşaklı
d65f494c6d closes #5127 2017-06-16 14:25:40 -04:00
Baris Usakli
0ea4ee7dda Merge remote-tracking branch 'refs/remotes/origin/master' into develop 2017-06-15 14:05:45 -04:00
Baris Usakli
4903585d88 refactor userPrivileges and groupPrivileges 2017-06-15 14:02:51 -04:00
Baris Usakli
037a0e5239 closes #5742
also fix reverse infinite scroll when sorting is changed
2017-06-06 16:40:32 -04:00
Peter Jaszkowiak
b171f3072b Fix many "duplicate key" errors
- Reset defaults after every test
- Remove individual `after(db.emptydb)` calls
- Fix async.every in groups test
- Update plugin list in socket tests
2017-05-26 17:16:59 -06:00
barisusakli
324e5be7bd privileges tests 2017-03-03 21:04:01 +03:00
Peter Jaszkowiak
896c8c7343 ESlint object-curly-spacing 2017-02-18 12:30:49 -07:00
Peter Jaszkowiak
3b0dd2d1ef ESlint padded-blocks 2017-02-18 02:32:24 -07:00
Peter Jaszkowiak
2e031f3759 ESlint comma-spacing 2017-02-18 01:31:47 -07:00
Peter Jaszkowiak
52f2028206 ESlint no-multiple-empty-lines 2017-02-17 22:08:23 -07:00
Peter Jaszkowiak
b09b3aef7f ESlint no-undef, remove global comments 2017-02-17 22:03:55 -07:00
Peter Jaszkowiak
bc1d70c126 ESlint comma-dangle 2017-02-17 19:31:21 -07:00
barisusakli
0b9829850c closes #5273 2016-12-09 18:53:08 +03:00
barisusakli
55416911f7 category tests 2016-12-02 18:08:15 +03:00
barisusakli
1440139903 more tests 2016-12-02 16:10:07 +03:00
barisusakli
c33d3e874a store pinned topics in new zset
keep pinned topics on top on different sort types
2016-11-25 17:46:29 +03:00
barisusakli
1658ebbe20 categories update test 2016-11-23 13:38:20 +03:00
barisusakli
db14c29e41 socket.io/categories tests 2016-11-21 13:47:34 +03:00
barisusakli
cec3b650c3 category route test 2016-10-18 00:14:28 +03:00