Commit Graph

119 Commits

Author SHA1 Message Date
Thomas Steen Rasmussen 12a1c9a0ce
Facilities (#458)
* update font-awesome to 5.12.1

* prefetch members to considerably lower number of SQL queries for team list view

* add facilities app with facility feeedback functionality, working on #383

* Add GeoDjango (django.contrib.gis) and switch to PostGIS db backend. Add location field for Facility model. Add django-leaflet to requirements.

* better migration names

* tweaking travis config, we use py3.7 now, and add postgis

* Add qr code support for facilities (visible in the admin). Make facitilies browsable without logging in. Feedback can be submitted without logging in, given the facility UUID, which is not revealed to unauthenticated users.

* show quickfeedback icons when creating and when reading feedback

* only show anon option if user is logged in

* django-reversion somehow went missing from requirements
2020-02-24 23:28:52 +01:00
Thomas Steen Rasmussen 33383e6559
Event feedback (#451)
* Event feedback functionality and related commits:

* blackness and isort and flake8 - this branch does not have pre-commit so I forgot :/

* finish backoffice management of eventfeedback

* add username to eventfeedback detail panel when viewed in backoffice

* Add feedback url to elm schedule. Fix access when user is anonymous. Remove print statement.

* one prefetch_related call to rule them all

Co-authored-by: Víðir Valberg Guðmundsson <valberg@orn.li>
2020-02-22 14:50:09 +01:00
Thomas Steen Rasmussen 95b41bdd44
Add first version of a wishlist app - create wishes in the admin for now. Fix a few unrelated things while here: update our date and time formats to be more internationally unambigous, and always show timezone. Also fix an old bug which meant that bornhack.dk/program redirect never worked. (#445) 2020-02-13 22:07:28 +01:00
Thomas Steen Rasmussen 00af109e2f
add flake8 and isort to pre-commit config, make flake8 and isort happy (#441)
* add flake8 to pre-commit config, and fixup many things to make flake8 happy

* add isort and sort all imports, add to pre-commit and requirements
2020-02-12 13:10:41 +01:00
Víðir Valberg Guðmundsson 20f380dfd6
Planked code form betterforms. (Aka django 3.0 upgrade) (#436)
* Bump django from 2.2.8 to 3.0.2 in /src/requirements

Bumps [django](https://github.com/django/django) from 2.2.8 to 3.0.2.
- [Release notes](https://github.com/django/django/releases)
- [Commits](https://github.com/django/django/compare/2.2.8...3.0.2)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

* Planked code form betterforms.

* Remove betterform from requirements.

* Try with master of django-allauth-2fa.

* Use static templatetag library, staticfiles is gone.

* Use newly released django-allauth-2fa 0.8 instead of git url.

* Django 3.0.3 is out.

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2020-02-07 18:21:34 +01:00
Víðir Valberg Guðmundsson 7e0c87957f It's an old code, sir, but it checks out. 2019-08-13 17:55:15 +02:00
Víðir Valberg Guðmundsson bf2f0c7898 Blackness. 2019-06-16 14:32:24 +02:00
Thomas Steen Rasmussen a989579f1e add missing import 2019-04-07 16:34:41 +02:00
Víðir Valberg Guðmundsson 75c8db4577 Get rid of wrapt hack. Django 2.2 introduced setup() method on views. Yay! 2019-04-02 12:32:12 +02:00
Víðir Valberg Guðmundsson 8674029c5c I mean like really consistent. 2019-03-26 22:00:17 +01:00
Víðir Valberg Guðmundsson 241bc650b3 Be consistent about calling it profile and not account. 2019-03-26 21:58:15 +01:00
Víðir Valberg Guðmundsson 9f49610013 Fixing urls. 2019-03-26 09:53:06 +01:00
Víðir Valberg Guðmundsson 563bd8a59d Merge branch 'master' into 2-factor-auth 2019-03-26 09:46:04 +01:00
Víðir Valberg Guðmundsson e3ff8d876e Enable CORS headers for /api/ endpoint. Also upgrade django to 2.1.7. 2019-03-14 12:57:27 +01:00
Víðir Valberg Guðmundsson 0f18b5de5c csrf_exempt the api. 2019-03-11 21:27:33 +01:00
Víðir Valberg Guðmundsson d972ef2cef Initial graphql endpoint. Only the program for now. 2019-03-11 20:26:36 +01:00
Víðir Valberg Guðmundsson 0a81a88e93 Introduce wrapt and monkeypatch django.views.View so we have a setup method to override. (#279) 2018-11-20 00:22:43 +01:00
Víðir Valberg Guðmundsson b2fa1dc92c WIP Reimbursement feature (#278)
* Almost done, need the send to economic part.

* Add a way to approve/reject an reimbursement and send mails accordingly.

* finish work on custom invoice address

* add textfield notes to Order for internal orga notes about the order

* Almost done, need the send to economic part.

* Add a way to approve/reject an reimbursement and send mails accordingly.

* economy commit of doom.. replace reimbursement app with an economy app, add Expense and Reimbursement models, add management of expenses and reimbursements to backoffice. Rework and cleanup permissions stuff, add Camp.Permissions pseudo model to hold all our non-model permissions. still experimental, expect rough edges, but basic functionality should work.
2018-08-30 00:52:32 +02:00
Víðir Valberg Guðmundsson 2d58695ee4 Adding feedback functionality. 2018-08-20 15:13:51 +02:00
Benjamin Bach 2673cd86e2 Add a development default settings file and modify instructions 2018-08-18 16:02:35 +02:00
Thomas Steen Rasmussen 016bfdc1a1 add secret token game code 2018-08-18 15:26:49 +02:00
Víðir Valberg Guðmundsson 5bd0f38249 Revert to using TZ anyway. Too many problems by disabling it by now. 2018-08-13 18:55:25 +02:00
Víðir Valberg Guðmundsson a3bfd85604 Disable timezone support. Everything is in Europe/Copenhagen anyway. 2018-08-11 18:15:19 +02:00
Víðir Valberg Guðmundsson 630b2e55de Re-add CHANNEL_LAYERS settings. 2018-08-10 22:25:50 +02:00
Víðir Valberg Guðmundsson 1c8685d15e Initial work on rideshare feature. 2018-08-08 22:19:28 +02:00
Thomas Steen Rasmussen 32e9b7c40b
Fix urls handling and other stuff (#249)
* update font-awesome to 5.1 and add fab- and fa-regular icons, fixed #244

* also handle slugs when dealing with SingleObjectMixin CBV views, fixes #248

* add missing trailing slash to bar/menu

* add missing trailing slash on event slugs, fixes #245

* fix a lot of stuff related to proposal URLs. actually display them on speaker and event detail pages. show the urltype icons. better messages on update and delete pages. fix 500 error when reapproving events. fix bug that made urls multiply when reapproving event. fixes #246 and fixes #247
2018-07-17 22:43:16 +02:00
Víðir Valberg Guðmundsson 635e57b7f9
Merge branch 'master' into feature/team_controlled_info 2018-06-21 08:53:47 +02:00
Thomas Steen Rasmussen 3180ec457d switch backoffice to use the regular CampViewMixin 2018-06-03 18:33:51 +02:00
Thomas Steen Rasmussen 8e7dc4f80a move call for sponsors view to the database 2018-05-26 15:22:45 +02:00
Thomas Steen Rasmussen 18c33383b7 add url support for speakerproposals and eventproposals, including new models Url and UrlType. Also switch to Django 2.0 path() syntax in various urls.py files getting rid of a lot of ugly regex \o/ 2018-05-23 23:28:27 +02:00
Thomas Steen Rasmussen 039af44a92 new content submission flow monster commit of doom. fixes a large part of #191. Split out /program/ urls into a seperate program/urls.py file in the program: URL namespace. Change call for speakers to call for participation everywhere (I think). Add boolean fields call_for_participation_open and call_for_sponsors_open to Camp model. Switch to font-awesome 5.0.13 and update <i> tags everywhere accordingly. Introduce Tracks so all Events belong to a Track, which in turn belongs to a Camp. Add seperate forms for submitting SpeakerProposals and EventProposals so we can set labels and help_text according to EventType, and remove fields we dont need. Remove Pictures from Speaker and SpeakerProposals, it was almost never used, and was a lot of code/complexity. Remove a few PROPOSAL_STATUS namely DRAFT and MODIFIED_AFTER_APPROVAL to simplify the workflow for submitters. Add description, icon and host_title fields to EventType. Add a CombinedProposalSubmitView which allows users to submit a SpeakerProposal and EventProposal from the same page, introducing a new requirements.txt dependency for django-betterforms==1.1.4. Update bootstrap-devsite to match the new reality. 2018-05-20 18:16:20 +02:00
Víðir Valberg Guðmundsson 735f17b1f1 Add an FK to teams.Team on info.InfoCategory, version control it using django-reversion. 2018-05-04 23:40:43 +02:00
Thomas Steen Rasmussen 7a526156c9 remove CHANNELS_LAYERS and move ASGI_APPLICATION to settings.py 2018-04-14 17:30:12 +02:00
Thomas Steen Rasmussen f50f1fe2e0 fixup asgi.py for channels2 goodness 2018-04-14 17:04:21 +02:00
Thomas Steen Rasmussen 281dacc3f9 resolve conflicts in teams/models.py 2018-04-14 15:41:27 +02:00
Thomas Steen Rasmussen 1c4a4dd259 change irc channel stuff so each team can have both a private and a public irc channel, introduce the concept of a volunteer channel which all teammembers of all teams get access to 2018-04-13 20:22:19 +02:00
Víðir Valberg Guðmundsson 4d6caf6947
Merge branch 'master' into django-and-channels-upgrade 2018-04-13 11:19:48 +02:00
Thomas Steen Rasmussen edcf363027
Merge teamcomms branch. Refactor team app and add events app.
* Primary commit towards improved team communications. Add new events app to handle team notifications when various events happen, with a Type model which contain event types and a Routing model which controls routing of events to teams. Add shortslug for Camp and Team models. events.handler.py contains the code for sending irc and email notifications for teams. The first two eventtypes have been added in datamigrations, 'ticket_created' and 'public_credit_name_changed', and the tickets and profile apps have been adjusted accordingly. Team IRC channels can be marked as managed and if so the IRC bot will register the team channel with ChanServ if possible. Team IRC channels can be marked as private and the bot will set invite only and maintain an ACL with team members. Users can set their NickServ username in their profile to get on the ACL. Rework all team views and templates. Remove TeamArea model and make Team have an FK to Camp directly. Add docstrings a whole bunch of places. Move signal handlers to apps.py and signal_handlers.py in a few apps. Add basic team mailing list handling, more work to be done. Update bootstrap-devsite script to add more teammembers and add some team event routing for the two eventtypes we have.

* default to the console backend for email unless we specifically ask for realworld email

* fix signal for public_credit_name approval irc message

* fix name display on /people/ page

* fix the text on people pages when all non-responsible team members are anonymous

* handle cases where we fallback to the area responsible properly

* readd removed property, it is used in team_detail view

* make it possible to filter profiles by public_credit_name_approved

* add method for sending IRC messages in ircbot.utils.add_irc_message(), extend periodic bot method to do more than check for outgoing messages so rename it, refactor chanserv and nickserv handling code, create methods to check and join/part IRC channels as needed, maintain channel ACLs for private channels, do not autojoin any channels when instatiating the bot instead rely on the new check_irc_channels() method to join them, rename profile presave signal, add checking for changed nickserv usernames for acl handling, add teammember.irc_channel_acl_ok boolean to track ACL state, add missing help_text properties to TeamMember fields, rename teammember postsave signal, add teammember deleted signal, readd wrongly deleted EnsureTeamMemberResponsibleMixin

* add a few missing early returns
2018-04-09 23:11:05 +02:00
Víðir Valberg Guðmundsson aae3d7e3c9 Got channels2 working. 2018-04-03 20:52:39 +02:00
Víðir Valberg Guðmundsson ff758b15ff Initial work on uprading. 2018-04-03 18:44:10 +02:00
Thomas Steen Rasmussen 9e82013ca0 remove unneeded imports from bornhack app 2018-03-04 14:31:46 +01:00
Jeppe Ernst 69f0c8aabd explain why we decorate /admin login 2017-12-31 00:16:07 +01:00
Jeppe Ernst 456ffa1bea useless/redundant file
forgot to remove it in the previous commit
2017-12-28 21:50:48 +01:00
Jeppe Ernst 7c5c8f6ac7 require 2fa for /admin pages
if the user has enabled 2fa
2017-12-28 21:37:34 +01:00
Jeppe Ernst f313935e6f initial setup of 2fa
issues:
* middleware temporarily removed, prevents login
* generated QR code has wrong issuer
* require OTP for /admin login not working (yet)
2017-12-28 16:22:26 +01:00
Benjamin Bach ecdc62df7c Add IBAN/SWIFT to custom invoices, bank name in settings - fixes #172 (#187) 2017-12-12 22:16:06 +01:00
Víðir Valberg Guðmundsson 6a082e6b58 Lower the percentage for camp redirect. 2017-11-25 14:54:34 +01:00
Víðir Valberg Guðmundsson d8e7ad2d17 Loewr the percentage for camp redirect. 2017-11-25 14:48:46 +01:00
Thomas Steen Rasmussen 142afa5ead add teamtask support 2017-11-23 23:09:14 +01:00
Víðir Valberg Guðmundsson d4265edaa0 Remove docker compose setup, not working optimal. Might return later. 2017-11-23 21:47:10 +01:00