Commit History

Author SHA1 Message Date
  Ankita Kalra 7f0e35f130 Final iteration making the layout compatible,tags showing the functionality of redirection 6 years ago
  Ankita Kalra d9f61044b9 Final iteration making the layout compatible,tags showing the functionality of redirection 6 years ago
  Ankita Kalra 15da3810ff Final iteration making the layout compatible,tags showing the functionality of redirection 6 years ago
  Ankita Kalra b6a4f8adb9 New Updates 6 years ago
  Ankita Kalra 2132f6c9b0 added front end functionality, updated websockets with user is typing thing, tags and comments being popped up, layout design yet to be worked upon 6 years ago
  Andrew Shiels ae07908164 Update 'canvas2/canvas2/settings.py' 6 years ago
  Andrew Shiels 53111facec Update 'requirements.txt' 6 years ago
  Andrew Knox Shiels 30ac4e1589 Changed requirements.txt to only reflect the python requirements, as jQuery and Vue.js are included in the 'static' directory. 6 years ago
  Andrew Knox Shiels c79440e2ed No longer require AJAX request results to be propagated by front-end code. Now the views receive AJAX POST, do modification, and send to the sockets. 6 years ago
  Andrew Knox Shiels 54713faf90 Changed database-modifying requests to now use AJAX POST requests instead of using WebSockets. The results from these are then propagated by WebSockets. Not broadcasting error messages solved itself by returning error-coded HTTP responses to erronous AJAX requests. Tested only as far as seeing normal non-erronous requests being serviced, the results propagated, and remaining on refresh. Added new TODO for consumers.py as there now exist redundant consumers. Changed API documentation to reflect AJAX POST usage. 6 years ago
  Andrew Knox Shiels 8edc10289d Added 404 codes for the '<Object> does not exist' exceptions, added (UNTESTED) functionality to send errors only to the connection making the erroneous request instead of broadcasting it (worked for a tag that doesn't actually exist, testing for all models to follow). Updated API documentation to reflect this change, and added documentation for delete_canvas and delete_project views, which I forgot. Finally, modified delete_project to only allow the owner to delete the project - admins of a project may still delete individual canvases. 6 years ago
  Andrew Knox Shiels b4691e0887 Added TODO to models.py and views.py (identical TODOs along with NOTEs in views.py detailing code relevant to aforementioned TODO) stating the current functionality for trial users, while not technically broken, is sub-par and was written as a 'quick fix'. It should probably be updated in future. 6 years ago
  Andrew Knox Shiels 014f91105f Updated requirements, excluding selenium, pytest, twisted as they're not actually used in running the canvas locally. Marked at top of consumers.py and views.py the current known bugs to be fixed in future. 6 years ago
  Andrew Knox Shiels 20d63c2366 A few singleton elements being passed to the serializer were not having their enclosing brackets trimmed. Fixed this so that they are now being trimmed. 6 years ago
  Andrew Knox Shiels 3c1715db0d addressed a bug where my working front-end wasn't working right with JSONified single model instances. 6 years ago
  Andrew Knox Shiels 987001a6c1 Added TODO: to each JSON serialization of a singleton list ie [tag] where it currently does not accept the single element without being encapsulated. 6 years ago
  Andrew Knox Shiels bca26df672 For known singleton elements being JSONified, had the square brackets removed from the start and end of it, going from [element] to element. Additionally, added some extra try-catch statements for presence of models before editing them, and added the ability for failure callbacks to be executed. There is an error field in what's returned from Consumers.py; if this field contains anything when it arrives at front-end, the error callbacks can be called. The data returned in this case is the error code and the reply text eg. if unauthorised, will return error: 401 and text Unauthorized. 6 years ago
  Andrew Knox Shiels f1e8d3a6f7 Marked canvas_type in models.py as TODO: 'change canvas_type to strings, update URL parameters to reflect this in routing, views.py, and in the html templates...' 6 years ago
  Andrew Knox Shiels d5cfff2439 Changed category to ideaCategory (or idea_category when sending TO backend) to make it clearer what it represents. Assumptions about front-end knowledge of back-end cannot be made. 6 years ago
  Andrew Knox Shiels 958dc856bf runserver warned me null has no effect on m2m - removed null=True from project.users and project.admins 6 years ago
  Andrew Knox Shiels 4a731b7f69 Fixed more bad names - u -> user, a -> admin, except where they're iterators in a loop, and ui -> userListIndex, ai -> adminListIndex (or user_list_index, admin_list_index within python) 6 years ago
  Andrew Knox Shiels 6edd5366f7 Allowing the user, admin and owner fields to be blank and null for the blank trial canvas. Made all operations be available on public canvasses. 6 years ago
  Andrew Knox Shiels 5929a2dfa4 Forgot to update the trial user functionality after adding projects, done so. Enabled null on project owner for the allowance of the AnonymousUser to have a blank project created (if it doesn't exist) for blank trial canvases. 6 years ago
  Andrew Knox Shiels 7949f8741d Moved removeTag out of front-end (was called for each tag before calling deleteIdea) and included in the delete_idea function in views.py. The same done for moving addTag and removeTag calls out of the editIdeaSuccessCallback and into the edit_idea function in views.py . Those two views.py functions now return the removed tag and its data, and the added and removed tag data for delete_idea and edit_idea respectively. 6 years ago
  Andrew Knox Shiels 7d078ed956 Changed 'i' and 'c' variables in consumers.py and canvasDetail.js to more descriptive 'ideaListIndex' and 'commentListIndex' respectively, except for where they exist only as iterators of a loop. In tag component 'c' is 'canvas' as it interacts with canvases, not comments. 6 years ago
  Andrew Knox Shiels 9caa1f1aec Uploaded old API.txt file in previous commit. Uploading updated. 6 years ago
  Andrew Knox Shiels 1cda9e3d66 Tidied up the consumers a lot so that every response is of a constant format, highlighted in the API. API also updated. 6 years ago
  Andrew Knox Shiels b0e96618f0 Added a first draft of what I think an API should be, and modified user permissions to return 401 unauthorized if user isn't in user-set and 403 forbidden if a user isn't in the admin-set 6 years ago
  Andrew Knox Shiels 84fed90de3 Data for canvasList and ideaList in the tag-popup weren't updating, so I wasn't totally sure if the data was usable on new tag additions. Using prop value instead seems to have fixed it. 6 years ago
  Andrew Knox Shiels e32770252b moving idea.save() to the try-catch block in remove_tag() fixed the bug, removed await database_sync_to_async as it wasn't updating other user with everything (delete idea was only deleting for the other user and not removing the tags, or the other way around 6 years ago