Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Formset TOTAL_FORMS Variable Issue #10

Open
unicod3 opened this issue Nov 9, 2017 · 0 comments
Open

Formset TOTAL_FORMS Variable Issue #10

unicod3 opened this issue Nov 9, 2017 · 0 comments

Comments

@unicod3
Copy link

unicod3 commented Nov 9, 2017

Hi,
I noticed that page has 2 total_forms variable with same id (you can see that on the picture below).
formset_Issue

I do not know what causes that.

In the lines below library tries to update the total_forms variables but since there are multiple same id in the page it only updates the first one so when the formset posted django only handles the second one.

$('#id_{% if formset.prefix %}{{formset.prefix}}-{% endif %}TOTAL_FORMS').attr('value', sortItemCounter);

$('#id_{% if formset.prefix %}{{formset.prefix}}-{% endif %}TOTAL_FORMS').attr('value', sortItemCounter);

Because of this issue I was unable to add more lines into database.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant