Tom Price
a3cdef8570
Tidy up the querying and move into model
...
This should really be in the model not in the view
2017-05-08 23:49:33 +01:00
Tom Price
7ec1c726a6
Optimise down to just the one SQL query for waiting invoices.
...
Cuts down on all the unnecessary queries and selects everything in one go.
Down from ~6 queries per invoice
2017-03-01 02:43:53 +00:00
Tom Price
4773b43081
Refactor outstanding invoice query to use django annotations.
...
Considerably improves performance and also removes the explict PSQL code.
Can be further improved by reducing the number of hits to the db in the template.
2017-03-01 02:05:06 +00:00
David Taylor
caa55fe89a
Restore pagination to invoice waiting (requested by Emma)
2016-11-04 13:31:06 +00:00
Tom Price
11180e507c
Merged branch develop into master
2016-07-11 13:11:37 +01:00
David Taylor
9178cf6062
Remove pagination from invoice waiting page
2016-07-10 11:31:25 +01:00
David Taylor
39d27d2730
Basic invoice UI improvements - closes #232
2016-07-10 10:49:23 +01:00
David Taylor
67624eea6f
Allow deleting invoices, if there are no payments yet
2016-06-15 23:18:46 +01:00
David Taylor
f92f418bc5
Fixed waiting invoice counter - closes #239
2016-06-06 23:06:30 +01:00
David Taylor
9108cb3c4e
Fail! Hide non-rigs from waiting invoices
2016-06-04 18:08:43 +01:00
David Taylor
705f1bda2b
Fix the query for the 'outstanding' invoices page. Previously this only displayed events with an end date set.
2016-05-29 22:05:53 +01:00
David Taylor
0ff0d06eaf
Fix counter on outstanding invoices page ('length' property doesn't work because of the custom SQL query)
2016-05-29 22:04:48 +01:00
David Taylor
83302c4439
Invoice UI improvements. Renamed pages, added description, and added total number of events
2016-05-29 21:30:05 +01:00
Tom Price
6b77393414
Fix for incorrect selection of active invoices.
...
Make sure waiting shows total across all pages.
2016-05-24 17:49:44 +01:00
Tom Price
7ccc8faf20
Add total for waiting events
2016-05-24 17:32:58 +01:00
Tom Price
6030288956
Cheap and dirty active totals
2016-05-24 17:17:52 +01:00
Tom Price
e4a955f323
Reformat code to PEP8
2016-05-23 12:36:21 +01:00
David Taylor
6944d98c4e
Added paperwork generation date, user & versioning
2015-07-29 22:06:44 +01:00
David Taylor
72bf28da53
Removed special characters from paperwork filenames - issue #103
2015-06-29 23:27:10 +01:00
Tom Price
3dc82e2de7
Add missing explicit fields definition django 1.8 realted
2015-05-29 15:45:14 +01:00
David Taylor
caf0e6cf45
Added invoice paperwork functionality
2015-05-22 15:20:43 +01:00
tomtom5152
2930f43937
Fix for #9
...
Added ORDER BY statement to the invoice page.
Ordered all other invoice pages.
2015-03-04 15:49:00 +00:00
tomtom5152
b4829d9d16
Slight bugfix for 3e1fa4b with incorrect logic.
2015-03-04 03:11:54 +00:00
tomtom5152
3e1fa4b9ab
Potential fix for #12 .
...
Added a clause where if there was a balance balance, and no payments, it would still show up.
2015-03-04 03:06:43 +00:00
Tom Price
e1cef5bd87
Made raw queries portable to postgresql engine as well
2015-03-03 02:44:16 +00:00
Tom Price
472cc3f1bb
Changed the calculations of sum totals to be raw SQL queries for speed boost. Not ideal but the best we are going to get.
...
Changed outstanding invoice to a raw SQL query for a speed boost. Average load now ~3.5s with ~10 invoices
2015-03-03 02:43:57 +00:00
Tom Price
76939409bb
Increased query efficiency
2015-02-01 23:41:03 +00:00
tomtom5152
af1396a168
Added the ability to invoice an event
2015-01-30 00:27:02 +00:00
tomtom5152
2ce45b9297
Basic working invoice system. Need to add a way to create invoices.
2015-01-29 23:18:04 +00:00