Class QuestionReplySessionController
java.lang.Object
org.silverpeas.core.web.mvc.controller.AbstractComponentSessionController
org.silverpeas.components.questionreply.control.QuestionReplySessionController
- All Implemented Interfaces:
Serializable,org.silverpeas.core.web.mvc.controller.ComponentSessionController,org.silverpeas.core.web.session.SessionCloseable
public class QuestionReplySessionController
extends org.silverpeas.core.web.mvc.controller.AbstractComponentSessionController
- See Also:
-
Field Summary
Fields inherited from class org.silverpeas.core.web.mvc.controller.AbstractComponentSessionController
context -
Constructor Summary
ConstructorsConstructorDescriptionQuestionReplySessionController(org.silverpeas.core.web.mvc.controller.MainSessionController mainSessionCtrl, org.silverpeas.core.web.mvc.controller.ComponentContext context, String multilangBaseName, String iconBaseName) -
Method Summary
Modifier and TypeMethodDescriptionvoidclassifyQuestionReply(long questionId, String positions) Classify the question reply FAQ on the PdC only if the positions parameter is filledvoidcloseQuestion(long questionId) voidcloseQuestions(Collection<Long> questionIds) voidcreateCategory(Category category) voiddeleteCategory(String categoryId) voiddeleteQuestions(Collection<Long> questionsIds) voiddeleteR(Collection<Long> replyIds) org.silverpeas.core.importexport.report.ExportReportexport(org.silverpeas.core.util.MultiSilverpeasBundle resource) Collection<org.silverpeas.core.node.model.NodeDetail>getCategory(String categoryId) Collection<org.silverpeas.core.admin.user.model.UserDetail>org.silverpeas.core.admin.user.model.SilverpeasRolegetQuestion(long questionId) getQuestionsByCategory(String categoryId) getRepliesForQuestion(long id) getReply(long replyId) org.silverpeas.core.pdc.pdc.model.SearchContextorg.silverpeas.core.admin.user.model.SilverpeasRolebooleanbooleanbooleanvoidopenQuestion(long questionId) longsaveNewFAQ(Collection<org.silverpeas.core.io.upload.UploadedFile> uploadedFiles) Persist new FAQ inside database and add positionslongvoidsaveNewReply(Collection<org.silverpeas.core.io.upload.UploadedFile> uploadedFiles) voidsetCurrentQuestion(Question question) voidsetCurrentReply(Reply reply) voidsetNewQuestionContent(String title, String content, String categoryId) voidsetNewReplyContent(String title, String content, int publicReply, int privateReply) final voidvoidsetUserProfil(String profil) voidupdateCategory(Category category) voidupdateCurrentQuestion(String title, String content, String categoryId) voidupdateCurrentReply(String title, String content) Methods inherited from class org.silverpeas.core.web.mvc.controller.AbstractComponentSessionController
addClipboardSelection, clipboardPasteDone, close, getClipboardErrorMessage, getClipboardExceptionError, getClipboardObjects, getClipboardSelectedObjects, getClipboardSize, getComponentAccessController, getComponentId, getComponentLabel, getComponentName, getComponentParameterValue, getComponentParameterValue, getComponentRootName, getComponentUrl, getIcon, getLanguage, getLook, getMultilang, getOrganisationController, getPersonalization, getRSSUrl, getSelection, getSettings, getSilverpeasUserRoles, getSpaceId, getSpaceLabel, getString, getSubscriptionContext, getUrlEncodedParameter, getUserAccessLevel, getUserAvailComponentIds, getUserDetail, getUserDetail, getUserId, getUserManageableGroupIds, getUserManageableSpaceIds, getUserRoles, getZoneId, isAppInMaintenance, isGroupManager, isPasswordChangeAllowed, isSpaceInMaintenance, removeClipboardElement, setAppModeMaintenance, setClipboardSelectedElement, setComponentRootName, setSpaceModeMaintenance
-
Constructor Details
-
QuestionReplySessionController
-
-
Method Details
-
getQuestions
- Throws:
QuestionReplyException
-
getQuestionsByCategory
- Throws:
QuestionReplyException
-
getQuestion
- Throws:
QuestionReplyException
-
getRepliesForQuestion
- Throws:
QuestionReplyException
-
getCurrentQuestion
-
setCurrentQuestion
-
getReply
- Throws:
QuestionReplyException
-
getCurrentReply
-
setCurrentReply
-
getNewQuestion
-
setNewQuestionContent
-
saveNewQuestion
- Throws:
QuestionReplyException
-
getNewReply
-
setNewReplyContent
-
saveNewFAQ
public long saveNewFAQ(Collection<org.silverpeas.core.io.upload.UploadedFile> uploadedFiles) throws QuestionReplyException Persist new FAQ inside database and add positions- Returns:
- question identifier
- Throws:
QuestionReplyException
-
saveNewReply
public void saveNewReply(Collection<org.silverpeas.core.io.upload.UploadedFile> uploadedFiles) throws QuestionReplyException - Throws:
QuestionReplyException
-
updateCurrentQuestion
public void updateCurrentQuestion(String title, String content, String categoryId) throws QuestionReplyException - Throws:
QuestionReplyException
-
updateCurrentReply
- Throws:
QuestionReplyException
-
deleteQuestions
- Throws:
QuestionReplyException
-
deleteR
- Throws:
QuestionReplyException
-
closeQuestions
- Throws:
QuestionReplyException
-
closeQuestion
- Throws:
QuestionReplyException
-
openQuestion
- Throws:
QuestionReplyException
-
setUserProfil
public final void setUserProfil() -
setUserProfil
-
getUserProfil
-
getUserRole
public org.silverpeas.core.admin.user.model.SilverpeasRole getUserRole() -
getHighestSilverpeasUserRole
public org.silverpeas.core.admin.user.model.SilverpeasRole getHighestSilverpeasUserRole()- Specified by:
getHighestSilverpeasUserRolein interfaceorg.silverpeas.core.web.mvc.controller.ComponentSessionController- Overrides:
getHighestSilverpeasUserRolein classorg.silverpeas.core.web.mvc.controller.AbstractComponentSessionController
-
isUserExpert
public boolean isUserExpert() -
getSilverContentIdPosition
public org.silverpeas.core.pdc.pdc.model.SearchContext getSilverContentIdPosition() throws QuestionReplyException- Throws:
QuestionReplyException
-
genericWriters
- Throws:
QuestionReplyException
-
getCurrentQuestionWriters
public Collection<org.silverpeas.core.admin.user.model.UserDetail> getCurrentQuestionWriters() throws QuestionReplyException- Throws:
QuestionReplyException
-
getCurrentQuestionContentId
-
isPrivateRepliesEnabled
public boolean isPrivateRepliesEnabled() -
isPDCUsed
public boolean isPDCUsed() -
getAllCategories
public Collection<org.silverpeas.core.node.model.NodeDetail> getAllCategories() throws QuestionReplyException- Throws:
QuestionReplyException
-
createCategory
- Throws:
QuestionReplyException
-
getCategory
- Throws:
QuestionReplyException
-
updateCategory
- Throws:
QuestionReplyException
-
deleteCategory
- Throws:
QuestionReplyException
-
export
public org.silverpeas.core.importexport.report.ExportReport export(org.silverpeas.core.util.MultiSilverpeasBundle resource) throws QuestionReplyException, ParseException - Throws:
QuestionReplyExceptionParseException
-
classifyQuestionReply
Classify the question reply FAQ on the PdC only if the positions parameter is filled- Parameters:
questionId- the question identifierpositions- the json string positions
-