WebDevStudios / custom-post-type-ui

Admin UI settings for creating custom post types and taxonomies in WordPress
https://webdevstudios.com
GNU General Public License v2.0
627 stars 143 forks source link

import / export / add CPT #797

Open Nickyg001 opened 3 years ago

Nickyg001 commented 3 years ago

[ NEW REQUEST ] I would ask if it is possible, to be able to expand this function.

  1. IMPORT: CPT UI allows you to import the code generated by another installation to transfer the fields to generate the CPTs. All with limitations. a) If I already have 3/4/5 CPI created in the new installation by importing the code of another installation example of 1 CPT, this imported code will delete the codes already present, I wish it were possible that the imported code would be added to the code already existing and alternatively could overwrite the existing code (as it already does).

2.EXPORT: Being able to export the code, currently it is possible in a minimized form, to copy and paste the code. a) Would it be possible to export and save the code in a file so that it could be saved (as a backup) and imported into a new installation? b) in the process of saving on an external file, the appearance of a menu that indicates whether to export all the CPT and Taxonomies or to select which CPT / TAX to save in a file.

  1. AUTOMATION: Since many items are similar in the creation of fields (singular voice and plural voice), in the creation of fields it is not possible to automatically construct the fields by indicating only the Singular and Plural entries of the fields and then possibly being able to manually redefine the fields to we don't like the translation? (currently I do this with a find and replace in a notepad and then I import the code in CPT UI), in 30 seconds I have the basic CPT at 90% ready to use without making major changes. It would be nice and useful something like this inside CPT UI ...
tw2113 commented 3 years ago

Just to be certain before I delve too far into parts of this, all the import/export that you are referring to is specifically the CPTUI settings blob of JSON data that we've made portable, correct? Not necessarily an export from say Pods or Toolset Types ?

Regarding parts of these request items from you, I know of: https://github.com/WebDevStudios/custom-post-type-ui/issues/782 https://github.com/WebDevStudios/custom-post-type-ui/issues/750

That last one, #750, is kind of an offshoot of https://docs.pluginize.com/article/84-save-cptui-settings-data-to-file which we've had awhile and covers at least 2.a from your list above.

Nickyg001 commented 3 years ago

I took a look at the post references you pointed out to me ...

750 - #782

This externally saves the database file in JSON, but has limitations. a) The code should be inserted in the functions.php so it is an operation that is done manually (by inserting the code in the functions) and it would be better if it were a function integrated in the plug-in, even if the saving was done not automatically but manually at the request of the user. b) the code is minified difficult to interpret for manual changes wanting to recreate a new CPT by replacing the strings in the code. c) In the JSON code all CPTs are exported in a single code, it does not give you the possibility to select which of the 10 CPTs available to export (it is an example). d) As I also read from other users this function to export CPTs, individually, multiples etc. it is very requested, as is the possibility to import single CPTs stored on external files WITHOUT OVERWRITING the CPTs currently already stored. e) how nice it would be to be able to import from a multiple database file (example with 10 different CPTs) and during the import phase to be able to choose whether to import CPT A, B, C or all CPTs ... f) autocompletion of singular and plural noun fields (see main post) ....

I believe that you should carefully reread the operation requests that I have listed now and also in the main post, I believe that not only are they functions that interest me, or other users, but I strongly believe that they are functions to be taken into consideration to give greater potential and shine to YOUR PLUG-IN.

The features that CPT UI offers (you know better than me) are all things that an online CPT generator or good code in functions could very well do, but since thanks to you there is this handy and extraordinary plugin I wonder why not make it anymore powerful and versatile natively without third party stunts ?? Also because the things I or others ask for are all small feasible things, nothing science fiction from year 3021.

tw2113 commented 3 years ago

Will take all this into advisement and see what we can potentially come up with. I know in one's head and mind it can sound really simple to do these things, but when it comes to actually trying to achieve it, it can actually get quite complex. That's not me saying we can't or won't look into any of this, it's all a matter of figuring out how.

Nickyg001 commented 3 years ago

Quiet, I know well that although it may seem so easy in words, then at the programming level there are various steps to overcome to make things work ... If I knew how to do it I would have done it :), but I'm also sure that these things are doable, in one way or another ... I do not ask in an imperative tone to have to do these new functions, but in case my ideas or those that others suggest, which are concrete, can be evaluated and really taken into consideration, we will all benefit from them starting from you creators of the plug -in. I remain confident and wish you a Fantastic 2021

tw2113 commented 2 years ago

Re-reading through the original post at the top, some of this will be able to be handled once #891 is fully finished and released. It's not going to necessarily handle importing and automation of creation, but at least on the front of being able to save to file and everything for backup and version control purposes, yes.

So I'm leaving this issue open, but wanted to chime in and say that some of it will be handled by other enhancements.