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

Converting importuser and importtag #40

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

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