forked frompython/pythondotorg
- Notifications
You must be signed in to change notification settings - Fork0
Commit301bfe2
authored
Sponsorship dashboard (python#1892)
* Sort apps by name* Add missing migration after help text change* Add new app to handle custom email dispatching* Add new model to configure sponsor notifications* Minimal admin* Update admin form to validate content as django template* Add button to preview how template will render* Add new benefit configuration to flag email targeatable* Add method to filter sponsorships by included features* Enable user to select which notification template to use* Rename variable* Display warning message if selected sponsorships aren't targetable* Introduce indirection with use case to send the emails* Implement method to create a EmailMessage from a notification template* Display non targetable sponsorship as checkbox instead of text* Add select all/delete all links* Filter emails by benefits, not feature configuration* Better display for notification objects* Add checkbox to select contact type* Update get_message method to accept boolean flags to control recipients* Rename form field name* Send notification to sponsors* Register email dispatch with admin log entry activity* Add input for custom email content* Display input for custom email content* UC expects sponsorship object, not PK* Consider email subject as a template as well* Refactor to move specific email building part to mailing app* Remove warning message* Optimizes sponsorship admin query* Add option to preview notification* Fix parameters names* Organize sections as divs* Remove unused imports and optimize query* Minimal working code to list user sponsorships* Change Sponsorships button to redirect user to sponsorships dashboard* Update HTML to list active/finalized sponsorships* Move sponsorship detail view to users app* Minimal view to update sponsor info* Inline display sponsor contacts* Reuse style from sponsorships application form to edit sponsor information* Improve fields display* Add link to edit sponsor information from sponsorship detail page* Display sponsor information in sponsorship detail page* Do not list the sponsors at sponsorship dashboard page* Add JS to handle with the inline contact forms* TODO note with my tests' checklist* Move button to right* Display fields as readonly* Add unit tests* Remove file inputs* Better organize sponsorships* Revert "Remove file inputs"This reverts commitd7f9047.* Do not allow user to clear file inputs* Do not change file input background* Run code linter* Remove unecessary br* File inputs should be required1 parent5defd8a commit301bfe2
File tree
17 files changed
+870
-178
lines changed- pydotorg
- tests
- sponsors
- tests
- static/sass
- templates
- sponsors
- users
- users
- tests
17 files changed
+870
-178
lines changedLines changed: 8 additions & 6 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
34 | 34 |
| |
35 | 35 |
| |
36 | 36 |
| |
37 |
| - | |
38 |
| - | |
39 |
| - | |
40 |
| - | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
41 | 43 |
| |
42 | 44 |
| |
43 | 45 |
| |
| |||
54 | 56 |
| |
55 | 57 |
| |
56 | 58 |
| |
57 |
| - | |
58 |
| - | |
| 59 | + | |
| 60 | + | |
59 | 61 |
| |
60 | 62 |
| |
61 | 63 |
| |
|
Lines changed: 10 additions & 13 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
52 | 52 |
| |
53 | 53 |
| |
54 | 54 |
| |
55 |
| - | |
56 |
| - | |
| 55 | + | |
| 56 | + | |
57 | 57 |
| |
58 | 58 |
| |
59 | 59 |
| |
| |||
84 | 84 |
| |
85 | 85 |
| |
86 | 86 |
| |
87 |
| - | |
88 |
| - | |
| 87 | + | |
| 88 | + | |
89 | 89 |
| |
90 | 90 |
| |
91 | 91 |
| |
| |||
97 | 97 |
| |
98 | 98 |
| |
99 | 99 |
| |
100 |
| - | |
101 |
| - | |
102 |
| - | |
103 |
| - | |
104 |
| - | |
105 |
| - | |
106 |
| - | |
107 |
| - | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
108 | 105 |
| |
109 | 106 |
| |
110 | 107 |
| |
111 |
| - | |
| 108 | + | |
112 | 109 |
| |
113 | 110 |
| |
114 | 111 |
| |
|
Lines changed: 63 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
463 | 463 |
| |
464 | 464 |
| |
465 | 465 |
| |
| 466 | + | |
| 467 | + | |
| 468 | + | |
| 469 | + | |
| 470 | + | |
| 471 | + | |
| 472 | + | |
| 473 | + | |
| 474 | + | |
| 475 | + | |
| 476 | + | |
| 477 | + | |
| 478 | + | |
| 479 | + | |
| 480 | + | |
| 481 | + | |
| 482 | + | |
| 483 | + | |
| 484 | + | |
| 485 | + | |
| 486 | + | |
| 487 | + | |
| 488 | + | |
| 489 | + | |
| 490 | + | |
| 491 | + | |
| 492 | + | |
| 493 | + | |
| 494 | + | |
| 495 | + | |
| 496 | + | |
| 497 | + | |
| 498 | + | |
| 499 | + | |
| 500 | + | |
| 501 | + | |
| 502 | + | |
| 503 | + | |
| 504 | + | |
| 505 | + | |
| 506 | + | |
| 507 | + | |
| 508 | + | |
| 509 | + | |
| 510 | + | |
| 511 | + | |
| 512 | + | |
| 513 | + | |
| 514 | + | |
| 515 | + | |
| 516 | + | |
| 517 | + | |
| 518 | + | |
| 519 | + | |
| 520 | + | |
| 521 | + | |
| 522 | + | |
| 523 | + | |
| 524 | + | |
| 525 | + | |
| 526 | + | |
| 527 | + | |
| 528 | + |
Lines changed: 17 additions & 9 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
1 | 1 |
| |
2 | 2 |
| |
3 | 3 |
| |
| 4 | + | |
4 | 5 |
| |
5 | 6 |
| |
6 | 7 |
| |
| |||
433 | 434 |
| |
434 | 435 |
| |
435 | 436 |
| |
| 437 | + | |
| 438 | + | |
| 439 | + | |
| 440 | + | |
| 441 | + | |
| 442 | + | |
| 443 | + | |
436 | 444 |
| |
437 | 445 |
| |
438 | 446 |
| |
| |||
492 | 500 |
| |
493 | 501 |
| |
494 | 502 |
| |
495 |
| - | |
| 503 | + | |
496 | 504 |
| |
497 | 505 |
| |
498 | 506 |
| |
| |||
620 | 628 |
| |
621 | 629 |
| |
622 | 630 |
| |
623 |
| - | |
| 631 | + | |
624 | 632 |
| |
625 | 633 |
| |
626 | 634 |
| |
627 |
| - | |
| 635 | + | |
628 | 636 |
| |
629 | 637 |
| |
630 | 638 |
| |
631 | 639 |
| |
632 | 640 |
| |
633 |
| - | |
634 |
| - | |
| 641 | + | |
| 642 | + | |
635 | 643 |
| |
636 | 644 |
| |
637 | 645 |
| |
638 | 646 |
| |
639 | 647 |
| |
640 |
| - | |
| 648 | + | |
641 | 649 |
| |
642 | 650 |
| |
643 | 651 |
| |
644 |
| - | |
| 652 | + | |
645 | 653 |
| |
646 | 654 |
| |
647 | 655 |
| |
648 | 656 |
| |
649 | 657 |
| |
650 | 658 |
| |
651 |
| - | |
| 659 | + | |
652 | 660 |
| |
653 | 661 |
| |
654 | 662 |
| |
655 |
| - | |
| 663 | + | |
656 | 664 |
| |
657 | 665 |
| |
658 | 666 |
| |
|
Lines changed: 0 additions & 39 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
317 | 317 |
| |
318 | 318 |
| |
319 | 319 |
| |
320 |
| - | |
321 |
| - | |
322 |
| - | |
323 |
| - | |
324 |
| - | |
325 |
| - | |
326 |
| - | |
327 |
| - | |
328 |
| - | |
329 |
| - | |
330 |
| - | |
331 |
| - | |
332 |
| - | |
333 |
| - | |
334 |
| - | |
335 |
| - | |
336 |
| - | |
337 |
| - | |
338 |
| - | |
339 |
| - | |
340 |
| - | |
341 |
| - | |
342 |
| - | |
343 |
| - | |
344 |
| - | |
345 |
| - | |
346 |
| - | |
347 |
| - | |
348 |
| - | |
349 |
| - | |
350 |
| - | |
351 |
| - | |
352 |
| - | |
353 |
| - | |
354 |
| - | |
355 |
| - | |
356 |
| - | |
357 |
| - | |
358 |
| - |
Lines changed: 0 additions & 5 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
10 | 10 |
| |
11 | 11 |
| |
12 | 12 |
| |
13 |
| - | |
14 |
| - | |
15 |
| - | |
16 |
| - | |
17 |
| - | |
18 | 13 |
|
Lines changed: 1 addition & 15 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
1 |
| - | |
2 | 1 |
| |
3 | 2 |
| |
4 | 3 |
| |
5 | 4 |
| |
6 |
| - | |
7 | 5 |
| |
8 | 6 |
| |
9 |
| - | |
10 | 7 |
| |
11 | 8 |
| |
12 | 9 |
| |
13 |
| - | |
| 10 | + | |
14 | 11 |
| |
15 | 12 |
| |
16 |
| - | |
17 | 13 |
| |
18 | 14 |
| |
19 | 15 |
| |
20 |
| - | |
21 | 16 |
| |
22 | 17 |
| |
23 | 18 |
| |
| |||
174 | 169 |
| |
175 | 170 |
| |
176 | 171 |
| |
177 |
| - | |
178 |
| - | |
179 |
| - | |
180 |
| - | |
181 |
| - | |
182 |
| - | |
183 |
| - | |
184 |
| - | |
185 |
| - |
0 commit comments
Comments
(0)