Skip to content

Commit

Permalink
Merge branch 'main' into settings-refactor
Browse files Browse the repository at this point in the history
  • Loading branch information
Kurocon committed Apr 29, 2024
2 parents 84e799e + a4d512b commit d9b9c87
Show file tree
Hide file tree
Showing 14 changed files with 668 additions and 43 deletions.
17 changes: 17 additions & 0 deletions amelie/files/migrations/0006_alter_attachment_options.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# Generated by Django 3.2.25 on 2024-04-29 18:43

from django.db import migrations


class Migration(migrations.Migration):

dependencies = [
('files', '0005_auto_20221028_1502'),
]

operations = [
migrations.AlterModelOptions(
name='attachment',
options={'ordering': ['created', 'file'], 'verbose_name': 'Appendix', 'verbose_name_plural': 'Attachments'},
),
]
2 changes: 1 addition & 1 deletion amelie/members/forms.py
Original file line number Diff line number Diff line change
Expand Up @@ -616,7 +616,7 @@ def clean_iban(self):

def clean_bic(self):
bic = str(self.cleaned_data['bic']).strip()
if bic is "":
if bic == "":
return self.cleaned_data['bic']

if not settings.DEBUG:
Expand Down
22 changes: 15 additions & 7 deletions amelie/narrowcasting/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -178,8 +178,11 @@ def room_spotify_now_playing(request):
data = {'error': False, 'is_playing': False}
elif res.status_code == 401:
# Access code expired, request a new one and retry the request.
_spotify_refresh_token(assoc)
return room_spotify_now_playing(request)
try:
_spotify_refresh_token(assoc)
return room_spotify_now_playing(request)
except ValueError as e:
data = {'error': True, 'code': 500, 'msg': str(e)}
else:
data = {'error': True, 'code': res.status_code, 'msg': res.content.decode()}

Expand Down Expand Up @@ -210,8 +213,11 @@ def room_spotify_pause(request):
data = {'error': False, 'is_playing': False}
elif res.status_code == 401:
# Access code expired, request a new one and retry the request.
_spotify_refresh_token(assoc)
return room_spotify_now_playing(request)
try:
_spotify_refresh_token(assoc)
return room_spotify_pause(request)
except ValueError as e:
data = {'error': True, 'code': 500, 'msg': str(e)}
else:
data = {'error': True, 'code': res.status_code, 'msg': res.content.decode()}

Expand Down Expand Up @@ -242,10 +248,12 @@ def room_spotify_play(request):
data = {'error': False, 'is_playing': False}
elif res.status_code == 401:
# Access code expired, request a new one and retry the request.
_spotify_refresh_token(assoc)
return room_spotify_now_playing(request)
try:
_spotify_refresh_token(assoc)
return room_spotify_play(request)
except ValueError as e:
data = {'error': True, 'code': 500, 'msg': str(e)}
else:
data = {'error': True, 'code': res.status_code, 'msg': res.content.decode()}

return JsonResponse(data)

6 changes: 6 additions & 0 deletions amelie/style/static/css/bootstrap-3.4.1.min.css

Large diffs are not rendered by default.

39 changes: 37 additions & 2 deletions amelie/style/static/css/kb.css
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
height: 100px;

display: block;
background-image: url('https://happyrent.nl/Company/_Template/Images/guido.png');
background-image: url('/static/img/cb/guido.png');
background-size: contain;
background-repeat: no-repeat;

Expand All @@ -21,7 +21,42 @@
background-color: #FF00FF;
}

.transparent-ia {
/* more transparent */
background-color: #ff00ff61 !important;
}

#middle {
background:url('https://www.animaatjes.nl/plaatjes/m/my_little_pony/animaatjes-my_little_pony-27130.png')!important;
background:url('/static/img/cb/my_little_pony.png');
background-repeat:no-repeat!important;
}

html, body {
/* Kirby cursor */
cursor: url("/static/img/cb/cursor.png"), auto;
}

.cb-modal-content {
/* display: flex;
flex-flow: column nowrap;
justify-content: space-between;
align-items: center; */
font-family: "Microsoft Sans Serif", sans-serif;
background: #c2c6ca !important;
font-size: 12px;
-webkit-font-smoothing: none;
/* width: 265px;
height: 118px; */
box-shadow: 0.5px 0.5px 0 0.5px black, inset 1px 1px #C2C6CA, inset -1px -1px #85898d, inset 2px 2px white;
}

.cb-modal-header {
color: white;
background: #00a;
padding: 2px 3px 3px;
margin: 3px 2px 1px 3px;
}

.cb-modal-footer {
text-align: center;
}
Binary file added amelie/style/static/img/cb/cursor.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added amelie/style/static/img/cb/dirty-dishes-ew.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added amelie/style/static/img/cb/guido.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added amelie/style/static/img/cb/my_little_pony.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading

0 comments on commit d9b9c87

Please sign in to comment.