/** * Method to create a clickable icon to change the state of an item * * @param mixed $value Either the scalar value or an object (for backward compatibility, deprecated) * @param integer $i The index * @param bool $isModule Param * * @return string */ public static function pubstates($value, $i, $isModule = false) { if (is_object($value)) { $value = $value->pubstate; } return SelectControlHelper::getTextForEnum($value, true, $isModule); }
echo EHtml::accessLevelControl($this->item->xtform->get('access', 1), 'xtform[access]', 'COM_AUTOTWEET_VIEW_FEED_ACCESS_LEVEL', 'COM_AUTOTWEET_VIEW_FEED_ACCESS_LEVEL_DESC'); echo EHtmlSelect::yesNoControl($this->item->xtform->get('front_page', 0), 'xtform[front_page]', 'COM_AUTOTWEET_VIEW_FEED_SHOW_FRONT', 'COM_AUTOTWEET_VIEW_FEED_SHOW_FRONT_DESC'); echo EHtmlSelect::yesNoControl($this->item->xtform->get('featured_with_image', 0), 'xtform[featured_with_image]', 'COM_AUTOTWEET_VIEW_FEED_SHOW_FEATURED_WITH_IMAGE', 'COM_AUTOTWEET_VIEW_FEED_SHOW_FEATURED_WITH_IMAGE_DESC'); ?> <div class="control-group"> <label for="published" class="control-label" rel="tooltip" data-original-title="<?php echo JText::_('COM_AUTOTWEET_VIEW_FEED_FEED_LANG_DESC'); ?> "><?php echo JText::_('COM_AUTOTWEET_VIEW_FEED_FEED_LANG'); ?> </label> <div class="controls"> <?php echo SelectControlHelper::languages($this->item->xtform->get('language', '*'), 'xtform[language]'); ?> </div> </div> <?php echo EHtmlSelect::yesNoControl($this->item->xtform->get('auto_publish', 1), 'xtform[auto_publish]', 'COM_AUTOTWEET_VIEW_FEED_PUB_AUTO', 'COM_AUTOTWEET_VIEW_FEED_PUB_AUTO_DESC'); echo EHtmlSelect::booleanListControl($this->item->xtform->get('created_date', 0), 'xtform[created_date]', 'COM_AUTOTWEET_VIEW_FEED_CREATED_DATE', 'COM_AUTOTWEET_VIEW_FEED_CREATED_DATE_DESC', 'Use Processed Date', 'Use Feed Date'); echo EHtmlSelect::booleanListControl($this->item->xtform->get('pub_date', 0), 'xtform[pub_date]', 'COM_AUTOTWEET_VIEW_FEED_PUB_DATE', 'COM_AUTOTWEET_VIEW_FEED_PUB_DATE_DESC', 'Use Processed Date', 'Use Feed Date'); echo EHtmlSelect::yesNoControl($this->item->xtform->get('advance_date', 1), 'xtform[advance_date]', 'COM_AUTOTWEET_VIEW_FEED_ALLOW_FUTURE', 'COM_AUTOTWEET_VIEW_FEED_ALLOW_FUTURE_DESC'); $options = array(); $options[] = array('name' => 'Days', 'value' => 0); $options[] = array('name' => 'Hours', 'value' => 1); $options[] = array('name' => 'Minutes', 'value' => 2); echo EHtml::numericUnitsControl($this->item->xtform->get('publish_duration', '0'), 'xtform[publish_duration]', $this->item->xtform->get('pub_dur_type'), 'xtform[pub_dur_type]', $options, 'COM_AUTOTWEET_VIEW_FEED_PUB_DUR', 'COM_AUTOTWEET_VIEW_FEED_PUB_DUR_DESC', null, 'required input-small'); ?>
?> </div> </div> <div class="control-group"> <label for="xtformcat_id" class="control-label required" rel="tooltip" data-original-title="<?php echo JText::_('COM_AUTOTWEET_VIEW_FEED_CATEGORY_TYPE_DESC'); ?> "> <?php echo JText::_('COM_AUTOTWEET_VIEW_FEED_CATEGORY_TYPE'); ?> <span class="star"> *</span> </label> <div class="controls"> <?php echo SelectControlHelper::feedCategories($this->item->xtform->get('contenttype_id', 'feedcontent'), $this->item->xtform->get('cat_id'), 'xtform[cat_id]', array('class' => 'required'), 'catid'); ?> </div> </div> <?php echo EHtml::textControl($this->item->xtform->get('import_limit', 3), 'xtform[import_limit]', 'COM_AUTOTWEET_VIEW_FEED_IMPORT_LIMIT', 'COM_AUTOTWEET_VIEW_FEED_IMPORT_LIMIT_DESC'); echo EHtml::textControl($this->item->xtform->get('import_frequency', FeedImporterHelper::ALWAYS_EXPRESSION), 'xtform[import_frequency]', 'COM_AUTOTWEET_VIEW_FEED_FREQUENCY', 'COM_AUTOTWEET_VIEW_FEED_FREQUENCY_DESC'); ?> <hr /> <div class="control-group"> <label for="feed_id" class="control-label" rel="tooltip" data-original-title="<?php echo JText::_('JGLOBAL_FIELD_ID_DESC'); ?>
</td> <td><?php echo AutoTweetModelPlugins::getSimpleName($item->plugin); ?> </td> <td><?php if ($has_error) { $alert_message = htmlentities($alert_message, ENT_COMPAT, 'UTF-8'); echo '<div rel="tooltip" data-original-title="' . $alert_message . '">'; echo EHtmlGrid::publishedWithIcons($item, $i, $this->perms->editstate); echo ' <a class="xticon xticon-thumbs-down"></a>'; echo ' - ' . JText::_('COM_AUTOTWEET_STATE_PUBSTATE_ERROR') . '</div>'; } else { echo SelectControlHelper::processedWithIcons($item, $i, $this->perms->editstate) . ' - ' . ($item->published ? JText::_('JYES') : JText::_('JNO')); } ?> </td> <td><?php echo $item->id; ?> </td> </tr> <?php $i++; } ?> <?php } else {
<h2><?php echo JText::_('COM_AUTOTWEET_VIEW_FEED_PREVIEW_TITLE'); ?> </h2> <div class="well"> <?php echo EHtml::genericControl('JGLOBAL_TITLE', 'JFIELD_TITLE_DESC', 'preview_title', $preview->title); echo EHtml::genericControl('JFIELD_ALIAS_LABEL', 'JFIELD_ALIAS_DESC', 'preview_alias', $preview->alias); $control = SelectControlHelper::feedCategories($this->item->xtform->get('contenttype_id', 'feedcontent'), $preview->cat_id, 'preview_cat_id'); echo EHtml::genericControl('JCATEGORY', 'JFIELD_CATEGORY_DESC', 'preview_cat_id', $control); // Main Text echo FeedTextHelper::joinArticleText($preview->introtext, $preview->fulltext); echo EHtml::accessLevelControl($preview->access, 'preview_access', 'JFIELD_ACCESS_LABEL', 'JFIELD_ACCESS_DESC'); echo EHtmlSelect::yesNoControl($preview->featured, 'preview_featured', 'JFEATURED', 'COM_CONTENT_FIELD_FEATURED_DESC'); $control = SelectControlHelper::languages($preview->language); echo EHtml::genericControl('JFIELD_LANGUAGE_LABEL', 'COM_CONTENT_FIELD_LANGUAGE_DESC', 'preview_language', $control); echo EHtml::readonlyTextControl($preview->metakey, 'preview_metakey', 'JFIELD_META_KEYWORDS_LABEL', 'JFIELD_META_KEYWORDS_DESC'); echo EHtml::readonlyTextControl($preview->metadesc, 'preview_metadesc', 'JFIELD_META_DESCRIPTION_LABEL', 'JFIELD_META_DESCRIPTION_DESC'); echo EHtmlSelect::yesNoControl($preview->state, 'preview_state', 'JSTATUS', 'JFIELD_PUBLISHED_DESC'); echo EHtml::readonlyTextControl(JHtml::_('date', $preview->created, JText::_('COM_AUTOTWEET_DATE_FORMAT')), 'preview_created', 'COM_CONTENT_FIELD_CREATED_LABEL', 'COM_CONTENT_FIELD_CREATED_DESC'); echo EHtml::readonlyTextControl(JHtml::_('date', $preview->publish_up, JText::_('COM_AUTOTWEET_DATE_FORMAT')), 'preview_publish_up', 'COM_CONTENT_FIELD_PUBLISH_UP_LABEL', 'COM_CONTENT_FIELD_PUBLISH_UP_DESC'); if (!empty($preview->publish_down)) { echo EHtml::readonlyTextControl(JHtml::_('date', $preview->publish_down, JText::_('COM_AUTOTWEET_DATE_FORMAT')), 'preview_publish_down', 'COM_CONTENT_FIELD_PUBLISH_DOWN_LABEL', 'COM_CONTENT_FIELD_PUBLISH_DOWN_DESC'); } echo EHtml::readonlyTextControl(FeedTextHelper::generateAuthor($preview->created_by, $preview->created_by_alias), 'preview_created_by', 'COM_CONTENT_FIELD_CREATED_BY_LABEL', 'COM_CONTENT_FIELD_CREATED_BY_DESC'); echo EHtml::genericControl('COM_AUTOTWEET_VIEW_FEED_PERMALINK', 'COM_AUTOTWEET_VIEW_FEED_PERMALINK', 'preview_permalink', "<a href='{$preview->permalink}' target='_blank'>" . $preview->permalink . ' <i class="xticon xticon-globe"></i></a>'); echo EHtml::genericControl('COM_AUTOTWEET_VIEW_FEED_SHORTLINK', 'COM_AUTOTWEET_VIEW_FEED_SHORTLINK', 'preview_shortlink', "<a href='{$preview->shortlink}' target='_blank'> " . $preview->shortlink . ' <i class="xticon xticon-globe"></i></a>'); $images = $preview->images; ?> <h3><?php
<h2><?php echo JText::_('COM_AUTOTWEET_VIEW_FEED_TAB_TEXT_EDITION'); ?> </h2> <div class="control-group"> <label for="xtformid4610" class="control-label required" rel="tooltip" data-original-title="<?php echo JText::_('COM_AUTOTWEET_VIEW_FEED_ADD_AUTHOR_DESC'); ?> "> <?php echo JText::_('COM_AUTOTWEET_VIEW_FEED_ADD_AUTHOR'); ?> </label> <div class="controls"> <?php echo SelectControlHelper::authorarticles($this->item->xtform->get('author_article'), 'xtform[author_article]', array('class' => 'required')); ?> </div> </div> <?php /* echo EHtmlSelect::yesNoControl( $this->item->xtform->get('create_art', 1), 'xtform[create_art]', 'COM_AUTOTWEET_VIEW_FEED_CREATE_ART', 'COM_AUTOTWEET_VIEW_FEED_CREATE_ART_DESC'); */ echo '<div class="combine">'; echo EHtmlSelect::yesNoControl($this->item->xtform->get('onlyintro', 1), 'xtform[onlyintro]', 'COM_AUTOTWEET_VIEW_FEED_ONLY_INTRO', 'COM_AUTOTWEET_VIEW_FEED_ONLY_INTRO_DESC', 'xtformsave_combine'); echo '</div>';
" id="oauth_user_secret" name="xtform[oauth_user_secret]" class="required validate-token" required="required"> </div> </div> <div class="control-group"> <label class="required control-label" for="xtformligroup_id" id="ligroup_id-lbl"><?php echo JText::_('COM_AUTOTWEET_CHANNEL_LINKEDIN_GROUP_ID'); ?> <span class="star"> *</span></label> <div class="controls"> <a class="btn btn-info" id="ligrouploadbutton"><?php echo JText::_('COM_AUTOTWEET_VIEW_CHANNEL_LOADBUTTON_TITLE'); ?> </a> <?php echo SelectControlHelper::ligroups($this->item->xtform->get('group_id'), 'xtform[group_id]', array(), $this->item->xtform->get('api_key'), $this->item->xtform->get('secret_key'), $this->item->xtform->get('oauth_user_token'), $this->item->xtform->get('oauth_user_secret')); ?> </div> </div> <div class="control-group"> <label class="control-label"> <a class="btn btn-info" id="livalidationbutton"><?php echo JText::_('COM_AUTOTWEET_VIEW_CHANNEL_VALIDATEBUTTON'); ?> </a> </label> <div id="validation-notchecked" class="controls"> <span class="lead"><i class="xticon xticon-question-circle"></i> </span><span class="loaderspinner"> </span> </div>
?> </td> <td><span class="rule-type-<?php echo $item->ruletype_id; ?> "></span> <?php echo $item->ruletype_id ? SelectControlHelper::getRuletypeName($item->ruletype_id) : '—'; ?> </td> <td><span class="channel-type-<?php echo $item->channel_id; ?> "></span> <?php echo $item->channel_id ? SelectControlHelper::getChannelName($item->channel_id) : JText::_('JALL'); ?> </td> <?php if ($hasAjaxOrderingSupport === false) { echo EHtmlGrid::basicOrderingColumn($this->pagination, $i, $count, $item->ordering); } ?> <td><?php echo EHtmlGrid::publishedWithIcons($item, $i, $this->perms->editstate); ?> </td> <td>
<label for="show_url" class="control-label required" rel="tooltip" data-original-title="<?php echo JText::_('COM_AUTOTWEET_POST_SHOW_URL_DESC'); ?> "><?php echo JText::_('COM_AUTOTWEET_POST_SHOW_URL'); ?> <span class="star"> *</span></label> <div class="controls"> <?php echo SelectControlHelper::showurl($this->item->show_url, 'show_url', array('class' => 'input required', 'required' => 'required')); ?> </div> </div> <?php echo SelectControlHelper::pubstatesControl($this->item->pubstate, 'pubstate', JText::_('COM_AUTOTWEET_POST_STATE') . ' <span class="star"> *</span>', 'COM_AUTOTWEET_POST_STATE_DESC', array('class' => 'input required', 'required' => 'required')); ?> <div class="control-group"> <label for="post_id" class="control-label" rel="tooltip" data-original-title="<?php echo JText::_('JGLOBAL_FIELD_ID_DESC'); ?> "><?php echo JText::_('JGLOBAL_FIELD_ID_LABEL'); ?> </label> <div class="controls"> <input type="text" name="id" id="post_id" value="<?php echo $this->item->id; ?>
*/ // No direct access defined('_JEXEC') or die('Restricted access'); $this->loadHelper('select'); $urlBase = JUri::root(); $isBackend = F0FPlatform::getInstance()->isBackend(); $postsLink = JRoute::_('index.php?option=com_autotweet&view=posts'); $requestsLink = JRoute::_('index.php?option=com_autotweet&view=requests'); $evergreensLink = JRoute::_('index.php?option=com_autotweet&view=evergreens'); $channelsLink = JRoute::_('index.php?option=com_autotweet&view=channels'); $rulesLink = JRoute::_('index.php?option=com_autotweet&view=rules'); $feedsLink = JRoute::_('index.php?option=com_autotweet&view=feeds'); $document = JFactory::getDocument(); $requestsData = array((object) array('label' => JText::_('COM_AUTOTWEET_TITLE_REQUESTS'), 'value' => (int) $this->requests), (object) array('label' => JText::_('COM_AUTOTWEET_TITLE_POSTS'), 'value' => (int) $this->posts)); $document->addScriptDeclaration('requestsData = ' . json_encode($requestsData) . ';'); $postsData = array((object) array('label' => SelectControlHelper::getTextForEnum('success'), 'value' => (int) $this->p_success), (object) array('label' => SelectControlHelper::getTextForEnum('cronjob'), 'value' => (int) $this->cronjob), (object) array('label' => SelectControlHelper::getTextForEnum('approve'), 'value' => (int) $this->p_approve), (object) array('label' => SelectControlHelper::getTextForEnum('cancelled'), 'value' => (int) $this->p_cancelled), (object) array('label' => SelectControlHelper::getTextForEnum('error'), 'value' => (int) $this->p_error)); $document->addScriptDeclaration('postsData = ' . json_encode($postsData) . ';'); $timelineData = $this->generateTimeline(); $document->addScriptDeclaration('timelineData = ' . json_encode($timelineData) . ';'); ?> <div class="extly dashboard"> <div class="extly-body"> <div class="row-fluid"> <div class="span8"> <?php if ($this->get('version_check')) { ?> <form name="adminForm" id="adminForm" action="index.php" method="post"> <input type="hidden" name="option" id="option" value="com_autotweet" />
$authUrl = $lioauth2ChannelHelper->getAuthorizationUrl(); if (!empty($accessTokenEncoded) && $channeltypeId == AutotweetModelChanneltypes::TYPE_LIOAUTH2COMPANY_CHANNEL) { ?> <div class="control-group"> <label class="required control-label" for="xtformlioauth2company_id" id="lioauth2company_id-lbl"><?php echo JText::_('COM_AUTOTWEET_CHANNEL_LINKEDIN_COMPANY_ID'); ?> <span class="star"> *</span></label> <div class="controls"> <a class="btn btn-info" id="lioauth2companyloadbutton"><?php echo JText::_('COM_AUTOTWEET_VIEW_CHANNEL_LOADBUTTON_TITLE'); ?> </a> <?php echo SelectControlHelper::lioauth2companies($this->item->xtform->get('company_id'), 'xtform[company_id]', array(), $this->item->id); ?> </div> </div> <?php } ?> <div id="validationGroup" class=" <?php echo $validationGroupStyle; ?> "> <div class="control-group"> <label class="control-label">
<p><?php echo JText::_('COM_AUTOTWEET_BATCH_POSTS_DESC'); ?> </p> <div class="control-group"> <label for="pubstate" class="control-label required" rel="tooltip" data-original-title="<?php echo JText::_('COM_AUTOTWEET_POST_STATE_DESC'); ?> "><?php echo JText::_('COM_AUTOTWEET_POST_STATE'); ?> </label> <div class="controls"> <?php echo SelectControlHelper::pubstates(null, 'batch_pubstate', array('class' => 'input')); ?> </div> </div> <a class="btn" onclick="Joomla.submitbutton('batch');" type="submit"><?php echo JText::_('COM_AUTOTWEET_BATCH_MOVE_BUTTON'); ?> </a> </fieldset> </div> <?php } ?> </div> <div class="span6"><div class="alert alert-info">
<td> <?php echo '<a href="' . $item->xtform->get('url') . '" target="_blank">'; echo htmlentities($item->xtform->get('url'), ENT_COMPAT, 'UTF-8'); echo ' <i class="xticon xticon-globe"></i></a>'; ?> </td> <td><span class="content-type-<?php $contenttype_id = $item->xtform->get('contenttype_id'); echo $contenttype_id; ?> "></span> <?php echo $contenttype_id ? SelectControlHelper::getContenttypesName($contenttype_id) : '—'; ?> </td> <?php if ($hasAjaxOrderingSupport === false) { ?> <td class="order"><span class="order-arrow"><?php echo $this->pagination->orderUpIcon($i, true, 'orderup', 'Move Up', $ordering); ?> </span> <span class="order-arrow"><?php echo $this->pagination->orderDownIcon($i, $count, true, 'orderdown', 'Move Down', $ordering); ?> </span> <?php $disabled = $ordering ? '' : 'disabled="disabled"'; ?> <input type="text" name="order[]" size="5" value="<?php
?> </div> </div> <div class="control-group"> <label for="plugin required" class="control-label" rel="tooltip" data-original-title="<?php echo JText::_('COM_AUTOTWEET_REQ_PLUGIN_DESC'); ?> "><?php echo JText::_('COM_AUTOTWEET_REQ_PLUGIN'); ?> <span class="star"> *</span> </label> <div class="controls"> <?php echo SelectControlHelper::plugins($this->item->plugin, 'plugin', array('class' => 'input required')); ?> </div> </div> <div class="control-group"> <label for="ref_id" class="control-label required" rel="tooltip" data-original-title="<?php echo JText::_('COM_AUTOTWEET_REQ_REFERENCE_DESC'); ?> "><?php echo JText::_('COM_AUTOTWEET_REQ_REFERENCE'); ?> <span class="star"> *</span> </label> <div class="controls"> <input type="text" name="ref_id" id="ref_id" value="<?php
" id="oauth_user_secret" name="xtform[oauth_user_secret]" class="required validate-token" required="required"> </div> </div> <div class="control-group"> <label class="required control-label" for="xtformlicompany_id" id="licompany_id-lbl"><?php echo JText::_('COM_AUTOTWEET_CHANNEL_LINKEDIN_COMPANY_ID'); ?> <span class="star"> *</span></label> <div class="controls"> <a class="btn btn-info" id="licompanyloadbutton"><?php echo JText::_('COM_AUTOTWEET_VIEW_CHANNEL_LOADBUTTON_TITLE'); ?> </a> <?php echo SelectControlHelper::licompanies($this->item->xtform->get('company_id'), 'xtform[company_id]', array(), $this->item->xtform->get('api_key'), $this->item->xtform->get('secret_key'), $this->item->xtform->get('oauth_user_token'), $this->item->xtform->get('oauth_user_secret')); ?> </div> </div> <div class="control-group"> <label class="control-label"> <a class="btn btn-info" id="livalidationbutton"><?php echo JText::_('COM_AUTOTWEET_VIEW_CHANNEL_VALIDATEBUTTON'); ?> </a> </label> <div id="validation-notchecked" class="controls"> <span class="lead"><i class="xticon xticon-question-circle"></i> </span><span class="loaderspinner"> </span> </div>
/** * getTumblrValidation. * * @return void */ public function getTumblrValidation() { @ob_end_clean(); header('Content-type: text/plain'); // No JInputJSON in J2.5 $raw = file_get_contents('php://input'); $data = json_decode($raw, true); $safeHtmlFilter = JFilterInput::getInstance(); $token = $data['token']; $token = $safeHtmlFilter->clean($token, 'ALNUM'); $this->input->set($token, 1); // CSRF prevention if ($this->csrfProtection) { $this->_csrfProtection(); } $channel_id = $data['channel_id']; $channel_id = $safeHtmlFilter->clean($channel_id, 'ALNUM'); $channel = F0FTable::getAnInstance('Channel', 'AutoTweetTable'); $result = $channel->load($channel_id); $channel->xtform = EForm::paramsToRegistry($channel); $status = false; $error_message = 'Unknown'; $user = null; $url = null; $icon = null; try { $tumblrChannelHelper = new TumblrChannelHelper($channel); $isAuth = $tumblrChannelHelper->isAuth(); if ($isAuth) { $status = true; $error_message = $isAuth->meta->msg; $user = $isAuth->response->user; $url = $tumblrChannelHelper->getSocialUrl($user); $icon = F0FModel::getTmpInstance('Channeltypes', 'AutoTweetModel')->getIcon(AutoTweetModelChanneltypes::TYPE_TUMBLR_CHANNEL); $user->blogs = SelectControlHelper::tumblrOptions($user->blogs); } else { $error_message = 'Tumblr Login Failed!'; } } catch (Exception $e) { $error_message = $e->getMessage(); } $message = json_encode(array('status' => $status, 'error_message' => $error_message, 'user' => $user, 'icon' => $icon, 'url' => $url)); echo EJSON_START . $message . EJSON_END; flush(); JFactory::getApplication()->close(); }
</div> </div> <?php if (AUTOTWEETNG_JOOCIAL && EParameter::getComponentParam(CAUTOTWEETNG, 'targeting', false)) { ?> <hr/> <div class="control-group"> <label class="control-label" for="xtformtarget_id" id="target_id-lbl"><?php echo JText::_('COM_AUTOTWEET_VIEW_FBWACCOUNT_TARGETING_TITLE'); ?> </label> <div class="controls"> <?php echo SelectControlHelper::targets($this->item->xtform->get('target_id'), 'xtform[target_id]', null); ?> </div> </div> <?php } echo EHtml::idControl($this->item->get('id'), 'id', 'channel_id'); ?> </fieldset> </div> <div class="span6">
/** * generateTimeline * * @return string */ protected function generateTimeline() { $timeline = $this->get('timeline'); $values = array(); $states = array('success', 'cronjob', 'approve', 'cancelled', 'error'); foreach ($states as $state) { $values[$state] = array(); } foreach ($timeline as $row) { $date = $row->postdate; $pubstate = $row->pubstate; $counter = $row->counter; $values[$pubstate][$date] = $counter; $others = array_diff($states, array($pubstate)); foreach ($others as $state) { if (!isset($values[$state][$date])) { $values[$state][$date] = 0; } } } $state_success = new StdClass(); $state_success->key = SelectControlHelper::getTextForEnum('success'); $state_success->values = $this->_listOfObjects($values['success']); $state_cronjob = new StdClass(); $state_cronjob->key = SelectControlHelper::getTextForEnum('cronjob'); $state_cronjob->values = $this->_listOfObjects($values['cronjob']); $state_approve = new StdClass(); $state_approve->key = SelectControlHelper::getTextForEnum('approve'); $state_approve->values = $this->_listOfObjects($values['approve']); $state_cancelled = new StdClass(); $state_cancelled->key = SelectControlHelper::getTextForEnum('cancelled'); $state_cancelled->values = $this->_listOfObjects($values['cancelled']); $state_error = new StdClass(); $state_error->key = SelectControlHelper::getTextForEnum('error'); $state_error->values = $this->_listOfObjects($values['error']); $result = array($state_success, $state_cronjob, $state_approve, $state_cancelled, $state_error); return $result; }
" id="raw_expires_in" name="expires_in" readonly="readonly" class="required validate-numeric" required="required"> (0 = Never) </div> </div> <?php if ($requireGroup) { ?> <div class="control-group"> <label class="required control-label" for="xtformvkgroup_id" id="vkgroup_id-lbl"><?php echo JText::_('COM_AUTOTWEET_CHANNEL_VK_GROUP'); ?> <span class="star"> *</span></label> <div class="controls"> <a class="btn btn-info" id="vkgrouploadbutton"><?php echo JText::_('COM_AUTOTWEET_VIEW_CHANNEL_LOADBUTTON_TITLE'); ?> </a> <?php echo SelectControlHelper::vkgroups($this->item->xtform->get('vkgroup_id'), 'xtform[vkgroup_id]', array(), $this->item->xtform->get('access_token'), $this->item->id); $social_target = 'social_url_vkgroup'; require dirname(__FILE__) . '/../../channel/tmpl/social_url.php'; ?> </div> </div> <?php } ?> </div>
?> <input type="text" name="order[]" size="5" value="<?php echo $item->ordering; ?> " <?php echo $disabled; ?> class="input-ordering" style="text-align: center" /> </td> <?php } ?> <?php echo '<td>' . EHtmlGrid::publishedWithIcons($item, $i, $this->perms->editstate) . '</td>'; if (AUTOTWEETNG_JOOCIAL) { echo '<td>' . SelectControlHelper::getScopeName($item->scope) . '</td>'; } echo '<td>' . $item->id . '</td>'; ?> </tr> <?php $i++; } ?> <?php } else { ?> <tr> <td colspan="10" align="center"><?php echo JText::_('AUTOTWEET_COMMON_NOITEMS_LABEL'); ?>
} else { $open_graph_features = 'style="display: none;"'; } if ($isGroupChannel) { $group_warn = ''; } else { $group_warn = 'style="display: none;"'; } ?> <div class="open_graph_features" <?php echo $open_graph_features; ?> > <?php $attrs = array('class' => 'required', 'required' => 'required'); $control = SelectControlHelper::sharedWith($this->item->xtform->get('sharedwith', 'EVERYONE'), 'xtform[sharedwith]', $attrs); echo EHtml::genericControl(JText::_('COM_AUTOTWEET_VIEW_CHANNEL_SHARED_WITH_LABEL'), JText::_('COM_AUTOTWEET_VIEW_CHANNEL_SHARED_WITH_DESC'), 'sharedwith', $control); $open_graph_features = $this->item->xtform->get('open_graph_features'); echo EHtmlSelect::yesNoControl($open_graph_features, 'xtform[open_graph_features]', 'COM_AUTOTWEET_VIEW_OPENGRAPHF_TITLE', 'COM_AUTOTWEET_VIEW_OPENGRAPHF_DESC', 'og_features'); ?> <div id="og-fields" class="og-fields alert" <?php echo $open_graph_features ? '' : 'style="display: none;"'; ?> > <?php echo EHtmlSelect::yesNoControl($this->item->xtform->get('og_explicitly_shared'), 'xtform[og_explicitly_shared]', 'COM_AUTOTWEET_VIEW_EXPLICITLYSHARED_TITLE', 'COM_AUTOTWEET_VIEW_EXPLICITLYSHARED_DESC'); echo EHtmlSelect::yesNoControl($this->item->xtform->get('og_user_generated'), 'xtform[og_user_generated]', 'COM_AUTOTWEET_VIEW_USERGENERATED_TITLE', 'COM_AUTOTWEET_VIEW_USERGENERATED_DESC'); ?> </div> </div>
</div> <div id="advancedaddtext" class="tab-pane fade"> <div class="control-group"> <label class="control-label" for="show_static_text_id" id="show_static_text-lbl" rel="tooltip" data-original-title="<?php echo JText::_('COM_AUTOTWEET_VIEW_SHOWSTATICTEXT_DESC'); ?> "><?php echo JText::_('COM_AUTOTWEET_VIEW_SHOWSTATICTEXT_TITLE'); ?> </label> <div class="controls"> <?php echo SelectControlHelper::showstatictext($this->item->show_static_text, 'show_static_text'); ?> </div> </div> <div class="control-group"> <label class="control-label" for="statix_text" id="statix_text-lbl" rel="tooltip" data-original-title="<?php echo JText::_('COM_AUTOTWEET_VIEW_STATICTEXT_DESC'); ?> "><?php echo JText::_('COM_AUTOTWEET_VIEW_STATICTEXT_TITLE'); ?> </label> <div class="controls"> <input type="text" maxlength="255" size="50" value="<?php echo htmlentities($this->item->statix_text);