public class LivePageClientSideElement extends AbstractPageClientSideElement
ClientSideElement
creates a button that will be enabled if page and its hierarchy is valid.ClientSideElement.Script, ClientSideElement.ScriptFile
Modifier and Type | Field and Description |
---|---|
private GroupManager |
_foGroupsManager
The
GroupManager for front-end groups |
private UserManager |
_foUsersManager
The
UserManager for front-end users |
private I18nUtils |
_i18nUtils
The
I18nUtils |
private Repository |
_repository
The repository
|
private SiteConfigurationExtensionPoint |
_siteConfiguration
|
private SkinsManager |
_skinManager
The
SkinsManager |
private UserHelper |
_userHelper |
private UserManager |
_userManager
The
UserManager |
_resolver, _synchronizeComponent
_currentUserProvider, _dependencies, _featureName, _id, _pluginName, _rightManager, _rights, _rightsMode, _script
Constructor and Description |
---|
LivePageClientSideElement() |
Modifier and Type | Method and Description |
---|---|
private String |
_getBody(User sender,
User user,
Page page,
String comment)
Get the email body
|
private Set<User> |
_getDistinctUsers(List<UserIdentity> userIdentities,
List<GroupIdentity> groupIdentities) |
private I18nizableText |
_getInvalidHierarchyDescription(Page page)
Get i18n description for invalid hierarchy
|
private I18nizableText |
_getInvalidPageDescription(Page page)
Get i18n description for invalid page
|
private String |
_getSender(User sender,
Page page)
Get the email sender
|
private String |
_getSubject(User sender,
Page page)
Get the email subject
|
Map<String,Object> |
getStatus(List<String> pageIds)
Get the live status of given pages
|
boolean |
sendOnlineNotification(List<String> pageIds,
List<Map<String,String>> users,
List<Map<String,String>> groups,
String comment)
Send a notification for online pages.
|
void |
service(ServiceManager smanager) |
getAllRightPageDescription, getNoModifiablePageDescription, getNoRightPageDescription, getPageDefaultParameters, hasRight
_configureClass, _configureParameters, _configureScript, configureInitialParameters
_configureDependencies, _configureImports, _configureRights, _configureRightsMode, configure, getDependencies, getId, getPluginName, getRights, getScripts, getScripts, hasRight, setPluginInfo, toString
getLogger, setLogger
private UserManager _userManager
UserManager
private UserManager _foUsersManager
UserManager
for front-end usersprivate GroupManager _foGroupsManager
GroupManager
for front-end groupsprivate SiteConfigurationExtensionPoint _siteConfiguration
private I18nUtils _i18nUtils
I18nUtils
private SkinsManager _skinManager
SkinsManager
private Repository _repository
private UserHelper _userHelper
public LivePageClientSideElement()
public void service(ServiceManager smanager) throws ServiceException
service
in interface Serviceable
service
in class AbstractPageClientSideElement
ServiceException
public Map<String,Object> getStatus(List<String> pageIds)
pageIds
- The page idpublic boolean sendOnlineNotification(List<String> pageIds, List<Map<String,String>> users, List<Map<String,String>> groups, String comment)
pageIds
- the ids of the pagesusers
- the users that will be notifiedgroups
- the groups that will be notifiedcomment
- the comment of the notifierprivate I18nizableText _getInvalidPageDescription(Page page)
page
- The pageI18nizableText
descriptionprivate I18nizableText _getInvalidHierarchyDescription(Page page)
page
- The pageI18nizableText
descriptionprivate String _getSender(User sender, Page page)
sender
- The user responsible for the actionpage
- The published pageprivate String _getSubject(User sender, Page page)
sender
- The user responsible for the notificationpage
- The published pageprivate String _getBody(User sender, User user, Page page, String comment)
sender
- The user responsible for the notificationuser
- The recipient of the notificationpage
- The published pagecomment
- The user's comment. Can be empty or null.private Set<User> _getDistinctUsers(List<UserIdentity> userIdentities, List<GroupIdentity> groupIdentities)