Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#49 2018-05-28 15:12:51

jayrope
Plugin Author
From: Berlin
Registered: 2006-07-06
Posts: 687
Website Mastodon

Re: glz_custom_fields v2 beta for Textpattern v4.7

jakob wrote #312134:

You’ll need to go into phpMyadmin / sequel pro or another sql editor … or smd_prefalizer. Look in the table txp_pref for the entry glz_cf_use_sortable and change the value of the type column from 2 (hidden) to 1. Now reload the preferences and you’ll have a yes-no switch to use sortable or enter the position value manually.


After setting type=1 as suggested
Custom field preferences mention
Set custom field order per drag and drop No Yes now,

however, setting it to yes does not let me use drag and drop reordering still.
BUT: Manual ordering works now. Thank you!

Why isn’t type=1 as a default?

Last edited by jayrope (2018-05-28 15:14:31)


A hole turned upside down is a dome, when there’s also gravity.

Offline

#50 2018-05-28 15:30:07

jakob
Admin
From: Germany
Registered: 2005-01-20
Posts: 4,734
Website

Re: glz_custom_fields v2 beta for Textpattern v4.7

As you say, it should work with drag and drop out of the box (would love to know why it’s not working for you).

Setting with drag and drop is infinitely preferable to setting it manually, because if you don’t think ahead, and space out your manual position numbers, you end up having to change all the following custom fields if you insert one in-between: i.e. if you have 20 custom fields and decide to add a new custom field at position 2, you’ll have to edit 3 to 20 manually to 4 to 21 as well.

But I didn’t remove that option in case there are people who, for example, cannot work with drag and drop, i.e. have to use the keyboard.

The other reason I made it a fallback option rather than one that is always there is that drag and drop automatically recalculates the order. If someone enters their position numbers manually, all nicely spaced as 1, 5, 10, 15, 20… etc. then switches to drag-and-drop, their settings get overwritten as sequential numbers. I envisaged people being unhappy about that…


TXP Builders – finely-crafted code, design and txp

Offline

#51 2018-05-28 15:36:24

jayrope
Plugin Author
From: Berlin
Registered: 2006-07-06
Posts: 687
Website Mastodon

Re: glz_custom_fields v2 beta for Textpattern v4.7

Jakob, makes sense, although i can report, that after switching drag-and-drop off my old sorting (like 1 10 20 30 with spaces left to insert new custom fields, if needed) seems to have survived.


A hole turned upside down is a dome, when there’s also gravity.

Offline

#52 2018-05-28 15:39:50

jakob
Admin
From: Germany
Registered: 2005-01-20
Posts: 4,734
Website

Re: glz_custom_fields v2 beta for Textpattern v4.7

jayrope wrote #312148:

Jakob, makes sense, although i can report, that after switching drag-and-drop off my old sorting (like 1 10 20 30 with spaces left to insert new custom fields, if needed) seems to have survived.

Yes, because it only happens once a drag-drop operation has taken place.


TXP Builders – finely-crafted code, design and txp

Offline

#53 2018-05-28 15:41:47

jayrope
Plugin Author
From: Berlin
Registered: 2006-07-06
Posts: 687
Website Mastodon

Re: glz_custom_fields v2 beta for Textpattern v4.7

After setting use_minified=false i get the following console errors:

SyntaxError: expected expression, got ‘<’[Learn More]
glz_jqueryui.sortable.js:7

jQuery.Deferred exception: $(…).addClass(…).find(…).prepend(…).appendTo(…).sortElements is not a function https://site.com/textpattern/index.php?event=glz_custom_fields&step=get_js:7:5 lhttps://site.com/textpattern/vendors/jquery/jquery/jquery.js:2:29373
a/</c<@https://site.com/textpattern/vendors/jquery/jquery/jquery.js:2:29677 undefined
jquery.js:2:30920

TypeError: $(…).addClass(…).find(…).prepend(…).appendTo(…).sortElements is not a function

Now glz_jqueryui.sortable.js is a culprit, logically.

Last edited by jayrope (2018-05-28 15:42:11)


A hole turned upside down is a dome, when there’s also gravity.

Offline

#54 2018-05-28 15:45:02

jakob
Admin
From: Germany
Registered: 2005-01-20
Posts: 4,734
Website

Re: glz_custom_fields v2 beta for Textpattern v4.7

hmm, the line numbers haven’t changed, though… Will have to look more closely…


TXP Builders – finely-crafted code, design and txp

Offline

#55 2018-05-30 10:49:56

jayrope
Plugin Author
From: Berlin
Registered: 2006-07-06
Posts: 687
Website Mastodon

Re: glz_custom_fields v2 beta for Textpattern v4.7

Thanx Jakob. Another thing i notice in 4.7.0 release is, that
multi-select fields return a 1 instead of nothing, when nothing has been selected.
Just to let you know.

Last edited by jayrope (2018-05-30 15:39:50)


A hole turned upside down is a dome, when there’s also gravity.

Offline

#56 2018-05-30 15:39:24

jayrope
Plugin Author
From: Berlin
Registered: 2006-07-06
Posts: 687
Website Mastodon

Re: glz_custom_fields v2 beta for Textpattern v4.7

The behaviour reported above was also reported on txp:article tags which don’t return anything – in this thread.


A hole turned upside down is a dome, when there’s also gravity.

Offline

#57 2018-06-07 15:27:56

Summer
Member
Registered: 2018-01-29
Posts: 60

Re: glz_custom_fields v2 beta for Textpattern v4.7

Does the plugin add field-related attributes? For example, is it associated with a category or a section. This eliminates the need to list all fields in the write panel.

Offline

#58 2018-06-07 16:21:38

jakob
Admin
From: Germany
Registered: 2005-01-20
Posts: 4,734
Website

Re: glz_custom_fields v2 beta for Textpattern v4.7

Summer wrote #312441:

Does the plugin add field-related attributes? For example, is it associated with a category or a section. This eliminates the need to list all fields in the write panel.

No, the custom fields are attached to articles only. However, you can use bot_write_tab_customize to control which custom fields appear in the write tab when you change the section drop-down. For example on a site of mine, I have all person-related fields show only on the “member” section, all event-related fields show only when the section drop-down is switched to “events” and all project-related fields only on the “projects” section.


TXP Builders – finely-crafted code, design and txp

Offline

#59 2018-06-07 17:53:42

jayrope
Plugin Author
From: Berlin
Registered: 2006-07-06
Posts: 687
Website Mastodon

Re: glz_custom_fields v2 beta for Textpattern v4.7

Adding to Jakob you can find a plugin thread and download link for a beta of bot_wtc v8 for 4.7 here.
I’m running a site with 60++ custom fields, where bot_wtc v8 really helps to not being overwhelmed with irrelevant custom fields in sections, which don’t need them.
Styling and especially re-ordering custom fields can be tricky, i would recommend to try and provide a final order for them already by setting their desired position in glz_cf.
To restyle the custom fields you need to get into your admin themes/assets/css/textpattern.css and add rules there according to your needs.

Last edited by jayrope (2018-06-07 17:57:46)


A hole turned upside down is a dome, when there’s also gravity.

Offline

#60 2018-08-20 13:14:13

towndock
Member
From: Oriental, NC USA
Registered: 2007-04-06
Posts: 329
Website

Re: glz_custom_fields v2 beta for Textpattern v4.7

Installed on 4.7.1. On the Write page I get the alert: Fix the TimePicker jQuery plugin » Check path.

Under the plugin prefs – the paths all check as OK. Trying to use it on the Write page, Date picker works fine. Time picker does not.

I viewed the browser source code – the paths to time picker are actually fine. But time picker is not working.

Last edited by towndock (2018-08-20 14:30:41)

Offline

Board footer

Powered by FluxBB