As per title, I've implemented a "Keep It Simple Stupid" feature that allows Staff with the Forum Moderator Permission "AMS: Convert thread to article".
![Selection_259.png Selection_259.png](https://xenaddons.com/data/attachments/7/7351-ba55bec4a5af606456df48c091b92344.jpg)
When the viewing user is a Moderator that has the above permission AND the discussion thread is of the Thread Type "discussion' or 'article', then there will be a link in the More options dropdown titled "AMS: Convert thread to article" (as shown in the image).
![Selection_260.png Selection_260.png](https://xenaddons.com/data/attachments/7/7350-6293626d70265de9256b77475fbffeca.jpg)
Clicking on the link will launch an overlay that allows the Moderator to select the destination category, set tags (if the thread has any tags, they are pre-set, however, they can be removed and different tags can be added), with options to notify members watching the destination category as well as notifying the author of the action.
![Selection_261.png Selection_261.png](https://xenaddons.com/data/attachments/7/7349-f0d0f548879ae3f4fb822d192cdd7bf3.jpg)
Once you click confirm, the convert service is triggered, which will result in a new article being created based on content from the Thread and the First Post of the thread.
The publish date will be set to the post date of the thread. The user will be set as the Thread Creator. Tags will be set (if any are added), view count will be set based on the thread view count. If the first post has any attachments, those will be converted to Article Attachments. If the first post contains at least 1 image attachment, a cover image will be set (uses the first image attachment in the collections of attachments).
The thread is then associated to the article by setting the discussion_type to 'ams_article'.
![Selection_262.png Selection_262.png](https://xenaddons.com/data/attachments/7/7348-d55ffa52b463e7e4d4e7a80623df4471.jpg)
Here you can see that the first post attachments are converted to Article attachments.
![Selection_263.png Selection_263.png](https://xenaddons.com/data/attachments/7/7347-a4014c6ba693da2097bf242218104bfa.jpg)
In this shot, you can see that the new article has a cover image set (as explained above).
![Selection_264.png Selection_264.png](https://xenaddons.com/data/attachments/7/7346-b7d8ef3d9ea3e9001a162c643bfc1116.jpg)
Note: The First Post of the thread will be modified to contain the same text as an associated thread has when auto created.
Note 2: This feature is not designed to be an importer, so expecting complex import type functions like posts being imported to article comments and first post reactions being converted to article reactions is not going to happen.
![Selection_259.png Selection_259.png](https://xenaddons.com/data/attachments/7/7351-ba55bec4a5af606456df48c091b92344.jpg)
When the viewing user is a Moderator that has the above permission AND the discussion thread is of the Thread Type "discussion' or 'article', then there will be a link in the More options dropdown titled "AMS: Convert thread to article" (as shown in the image).
![Selection_260.png Selection_260.png](https://xenaddons.com/data/attachments/7/7350-6293626d70265de9256b77475fbffeca.jpg)
Clicking on the link will launch an overlay that allows the Moderator to select the destination category, set tags (if the thread has any tags, they are pre-set, however, they can be removed and different tags can be added), with options to notify members watching the destination category as well as notifying the author of the action.
![Selection_261.png Selection_261.png](https://xenaddons.com/data/attachments/7/7349-f0d0f548879ae3f4fb822d192cdd7bf3.jpg)
Once you click confirm, the convert service is triggered, which will result in a new article being created based on content from the Thread and the First Post of the thread.
The publish date will be set to the post date of the thread. The user will be set as the Thread Creator. Tags will be set (if any are added), view count will be set based on the thread view count. If the first post has any attachments, those will be converted to Article Attachments. If the first post contains at least 1 image attachment, a cover image will be set (uses the first image attachment in the collections of attachments).
The thread is then associated to the article by setting the discussion_type to 'ams_article'.
![Selection_262.png Selection_262.png](https://xenaddons.com/data/attachments/7/7348-d55ffa52b463e7e4d4e7a80623df4471.jpg)
Here you can see that the first post attachments are converted to Article attachments.
![Selection_263.png Selection_263.png](https://xenaddons.com/data/attachments/7/7347-a4014c6ba693da2097bf242218104bfa.jpg)
In this shot, you can see that the new article has a cover image set (as explained above).
![Selection_264.png Selection_264.png](https://xenaddons.com/data/attachments/7/7346-b7d8ef3d9ea3e9001a162c643bfc1116.jpg)
Note: The First Post of the thread will be modified to contain the same text as an associated thread has when auto created.
Note 2: This feature is not designed to be an importer, so expecting complex import type functions like posts being imported to article comments and first post reactions being converted to article reactions is not going to happen.
Upvote
2