Skip to content

Converting importuser and importtag#40

Open
Hackwar wants to merge 2 commits intojoomla-projects:mainfrom
Hackwar:tagcategory
Open

Converting importuser and importtag#40
Hackwar wants to merge 2 commits intojoomla-projects:mainfrom
Hackwar:tagcategory

Conversation

@Hackwar
Copy link
Contributor

@Hackwar Hackwar commented Dec 17, 2024

This is an attempt to further structure the migration tool. This is NOT a working and finished solution, but this code has proper dependency injection for the application and the database, as well as consistently named wordpress database. It also does not use loadAssocList() everywhere and instead uses the proper database methods (mostly). So far the only part working on this is importing users. It also started converting the whole thing to not require continous keys for the different data sources. I started adding mappings from WP IDs to Joomla IDs, which still needs to be used everywhere and I added a new event which moves the calls to getUserState to the event instead of in the plugin. Lots of unnecessary code was removed and half the logging has been converted to the Joomla core logger instead of the custom class included in this project.

There si still a lot to do here. The events should have better names and importPostsAndPage is simply wrong and way to WP specific. We want to have steps for Joomla entities, not for Wordpress entities. So it would have to be something like importArticles and then in importMenuitems we could create menu items for articles which were pages in WP. The key parameter of the ajax requests have to be removed, the whole error handling needs to be improved both in the WP plugin and in the component itself. I've been using the table objects so far mostly, but in some cases this would have to be the model instead to properly create everything.

@Kaushik1216
Copy link
Collaborator

First of all, thank you for your work and suggestions. I will review all the changes and suggestions and create a working extension soon!

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

Successfully merging this pull request may close these issues.

2 participants