In our website we used Telligent as forums. Now we are planning to migrate forums from Telligent to Discourse. In Telligent we are having around 4500 topics to migrate. We know the permalinks feature in discourse. But it is a looong process if we do it manually. Is there any automated way to add permalinks for all these 4500 topics in telligent.
RGJ
(Richard - Communiteq)
29.Апрель.2021 09:24:56
2
The Telligent import script contains code that adds the permalinks upon importing.
SQL
break if rows.blank?
last_topic_id = rows[-1]["ThreadId"]
next if all_records_exist?(:post, rows.map { |row| import_topic_id(row["ThreadId"]) })
create_posts(rows, total: total_count, offset: offset) do |row|
user_id = user_id_from_imported_user_id(row["UserId"]) || Discourse::SYSTEM_USER_ID
post = {
id: import_topic_id(row["ThreadId"]),
title: CGI.unescapeHTML(row["Subject"]),
raw: raw_with_attachment(row, user_id, :topic),
category: category_id_from_imported_category_id(row["ForumId"]),
user_id: user_id,
created_at: row["DateCreated"],
closed: row["IsLocked"],
views: row["TotalViews"],
post_create_action:
proc do |action_post|
topic = action_post.topic
Hi Richard,
Thanks for the suggestion.
We are planning to do it through a external utility. While looking into the discourse API calls we found.
https://qa-forums.techsoup.org/admin/permalinks.json
So, we are planning to add permalinks using this API.