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

field size weirdness #6

Open
pixelninja opened this issue Oct 17, 2011 · 6 comments
Open

field size weirdness #6

pixelninja opened this issue Oct 17, 2011 · 6 comments

Comments

@pixelninja
Copy link

If you go into the section editor and save it, with or without changes, the widths of the fields within the DTG screw up. The first one becomes a negative value in the hundreds, normally around -900 for me. While the rest become massive positive values, normally all of which are over 1000.

Then when you try and drag them back into place, they don't move.

The only fix is to alter the DB directly.

Oh and this is on your development branch too.

@a-ntoine
Copy link

Yes I have the same issue. Fields end up showing up one by line.

It happens quite often on the 2dev6. But I do find a way to fix it without going to the DB. It just take some time to resize field to their very minimum size.

pixelninja pushed a commit to pixelninja/dynamictextgroup that referenced this issue Jun 9, 2012
@DavidOliver
Copy link

I also get this sometimes with 2.0dev6, but not always.

@fawx
Copy link

fawx commented Feb 12, 2013

this is still happening to me with 2.3.1 and dtg 3.0

@brockpetrie
Copy link
Owner

I'm not able to replicate this in any webkit browser. Could you guys let me know what you are using? Does this appear to be happening server-side or client-side?

Might be easier if we can peek at the schema object from the browser. Could you do the following and let me know if you see any funkiness happen, and if so, what you were doing when it happened:

Change line 65 in field.dynamictextgroup.php from
//$tblocks .= '<span>'.$this->get('schema').'</span>';
to
$tblocks .= '<span id="schemaspill">'.$this->get('schema').'</span>';

and then change line 97 in assets/dynamictextgroup.fieldeditor.js from
if (schematic[0]) { _f.val(JSON.stringify(schematic)); } else { _f.val(''); }
to
if (schematic[0]) { _f.val(JSON.stringify(schematic)); $('#schemaspill').text(JSON.stringify(schematic)); } else { _f.val(''); }

This will have JS spit out the field editor object so you can see what's going on.

@brockpetrie
Copy link
Owner

Also, if one of you manages to take a crack at this locally and finds a solution, I'll happily pull your fix.

@fawx
Copy link

fawx commented Feb 19, 2013

i'm having trouble replicating it as well. i fixed it by changing the width values in the database per mark lewis's suggestion, and now i can't seem to screw it up again.

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

5 participants