We have a lot of new users who are not familiar with askbot and are not marking the questions as answered is there a way for an admin to mark a question as answered.
Hello, to get it done quickly - please change these two things:
(1) - function askbot.models.user_assert_can_unaccept_best_answer in the file askbot/models/__init__.py - this assertion is used for both accepting and unaccepting the best answer.
(2) - show icon "accept answer" to admins - around line 207 in askbot/skins/default/templates/question.html by changing it from
{% if request.user == question.author %}
<img id="answer-img-accept-{{ answer.id }} ...
to
{% if request.user == question.author or request.user.is_administrator() %}
<img id="answer-img-accept-{{ answer.id }} ...
Properly it would require adding a couple of settings to the configuration and updating test cases and fix the rep awarding.
Edit: one more thing -
change file askbot/skins/default/media/js/post.js around line 288
var bindEvents = function(){
// accept answers
if(true){//edit on this line: was questionAuthorId == currentUserId){
var acceptedButtons = 'div.'+ voteContainerId +' img[id^='+ imgIdPrefixAccept +']';
have these changes been made also to the Askbot latest release
Create your Q&A site at askbot.com. Managed Askbot hosting at just $15/mo. Dedicated hosting, support contracts, consulting services.
create your Q&A siteAsked: 2011-02-17 22:31:06 -0500
Seen: 76 times
Last updated: Feb 20 '11
how can an admin answer own question and accept it?
showing accepted answers in user profile
Incorrect karma awarded when an administrator marks accepted answer for another user's question
Don't show Accept (Vee) icon if you can't accept
User gains karma for accepting own answer
Accepting answer results in broken image
Incorrect question owner displayed when trying to mark an accepted answer for a question I don't own
Copyright Askbot, 2010-2011. Content on this site is licensed under a Creative Commons Attribution Share Alike 3.0 license.
Related: http://askbot.org/en/question/3202/as-an-administrator-i-should-be-able-to-mark-an/
todofixthis ( 2012-07-07 10:51:34 -0500 )edit