implemented "Subscribe To Topic"
This commit is contained in:
@@ -216,6 +216,24 @@ public class TopicOperations extends VeniceServlet
|
||||
|
||||
} // end if (remove bozo)
|
||||
|
||||
if (cmd.equals("SY") || cmd.equals("SN"))
|
||||
{ // "SY", "SN" - Set subscription status
|
||||
try
|
||||
{ // call down to set the topic!
|
||||
topic.setSubscribed(cmd.equals("SY"));
|
||||
setMyLocation(request,"topicops?" + locator);
|
||||
return new ManageTopic(user,comm,conf,topic);
|
||||
|
||||
} // end try
|
||||
catch (DataException de)
|
||||
{ // there was a database error
|
||||
return new ErrorBox("Database Error","Database error setting subscription status: " + de.getMessage(),
|
||||
location);
|
||||
|
||||
} // end catch
|
||||
|
||||
} // end if (subscription control)
|
||||
|
||||
// unrecognized command - load the "Manage Topic menu"
|
||||
try
|
||||
{ // return that "Manage Topic" page
|
||||
|
||||
@@ -173,4 +173,10 @@ public class ManageTopic implements JSPRender
|
||||
|
||||
} // end getBozosIterator
|
||||
|
||||
public boolean isSubscribed()
|
||||
{
|
||||
return topic.isSubscribed();
|
||||
|
||||
} // end isSubscribed
|
||||
|
||||
} // end class ManageTopic
|
||||
|
||||
Reference in New Issue
Block a user