python - Django, javascript, and complex forms -


i'm building app in django lets users create , edit flowcharts purpose of process/procedure control. there 3 basic models: procedure, step, , transition.

i've created , debugged model relationships , through admin interface , shell, can create procedures several steps , transitions. it's functional not intended end user. need create browser-based jgraphical interface.

enter visjs, javascript visualization library. using visjs, i've created basic block-diagram editor lets users add/edit/delete nodes , edges (this first javascript attempt ever). can load data database , post data database through couple of custom views , json serialization. however, feels kludgey , hard maintain. example, it's not integrated django's forms framework @ all.

at moment, when submitted, javascript serialization post json data , json data only. i'd standard form submission can't figure out how structure form.

how go building form handle this? i'm trying javascript block diagram be form, if makes sense. use-case custom widget?

another wrinkle here editor needs create/update/delete top-level procedure, steps, , edges.

thanks help

i think custom widget looking , start learning examples of other django apps similar. project working on includes app named django-ckeditor creates widget around ckeditor. believe solves similar problem yours in sense creates django widget javascript widget.

study how approach similar problem , see if helps.


Popular posts from this blog

c# - ODP.NET Oracle.ManagedDataAccess causes ORA-12537 network session end of file -

matlab - Compression and Decompression of ECG Signal using HUFFMAN ALGORITHM -

utf 8 - split utf-8 string into bytes in python -