So we want to migrate all our news items from our old website(Drupal) to SmartStore i looked for a way to to that via the WebApi or Import Profiles but could find any endpoints for it (I did find endpoints in the WebApi for Blogs). What would be the alternative, import them directly in the SQL database? And if that's the case is it enough to directly insert them in the table of do we have to call a Update or Index somewhere?
Method to Import News items from a previous website (collection)
#1
Geschrieben: 19 May 2020 - 13:26
#2
Geschrieben: 02 June 2020 - 15:07
Hi,
there is no import logic available for news items.
You could just add news item data directly per sql into table 'News'.
However, your news wont be able to link to subpages where the whole article would be written.
To create these subpages you need to save news items via backend > CMS > News > Edit > Save. This way url records and subpages for news get created.
Take a look at NewsController Edit action in Smartstore.Admin if you like to add some automated import logic for news by yourself
Best regards
- stefanmueller gefällt das
#3
Geschrieben: 02 June 2020 - 18:56
If you have a RSS feed URL for your news then you can import from it using the News Importer.
- stefanmueller gefällt das
Marcus Gesing
Smartstore AG
#4
Geschrieben: 03 June 2020 - 08:50
Thanks both of you for the info. I ended up with the way of Marcel, inserting it directly into the database. Since i stripped down all previous formatting from the old website before inserting it to the database our backoffice collegue had to format all news articles again so by doing that all the SEO links where created and the news is clickable now :-)