• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

PHP JavascriptLoadManager类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了PHP中JavascriptLoadManager的典型用法代码示例。如果您正苦于以下问题:PHP JavascriptLoadManager类的具体用法?PHP JavascriptLoadManager怎么用?PHP JavascriptLoadManager使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。



在下文中一共展示了JavascriptLoadManager类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的PHP代码示例。

示例1: __construct

 public function __construct(&$po_request, &$po_response, $pa_view_paths = null)
 {
     $this->ops_theme = __CA_THEME__;
     // get current theme
     if (!is_dir(__CA_APP_DIR__ . '/plugins/MetabolicChronology/themes/' . $this->ops_theme . '/views')) {
         // if theme is not defined for this plugin, try to use "default" theme
         $this->ops_theme = 'default';
     }
     parent::__construct($po_request, $po_response, array(__CA_APP_DIR__ . '/plugins/MetabolicChronology/themes/' . $this->ops_theme . '/views'));
     $this->opo_plugin_config = Configuration::load($this->request->getAppConfig()->get('application_plugins') . '/MetabolicChronology/conf/Chronology.conf');
     if (!(bool) $this->opo_plugin_config->get('enabled')) {
         die(_t('Metabolic Chronology plugin is not enabled'));
     }
     $this->_initView($pa_options);
     $this->opo_result_context = new ResultContext($po_request, 'ca_objects', 'MetabolicChronology');
     MetaTagManager::addLink('stylesheet', $po_request->getBaseUrlPath() . "/app/plugins/MetabolicChronology/themes/" . $this->ops_theme . "/css/chronology.css", 'text/css');
     JavascriptLoadManager::register('jcarousel');
     JavascriptLoadManager::register('maps');
     $t_list = new ca_lists();
     $this->opn_silo_type_id = $t_list->getItemIDFromList('collection_types', 'silo');
     $this->opn_action_type_id = $t_list->getItemIDFromList('occurrence_types', 'action');
     $this->opn_context_type_id = $t_list->getItemIDFromList('occurrence_types', 'context');
     $this->opn_yes_list_id = $t_list->getItemIDFromList('yes_no', 'yes');
     $t_relationship_types = new ca_relationship_types();
     $this->opn_rel_type_action_display_image = $t_relationship_types->getRelationshipTypeID("ca_objects_x_occurrences", "display");
     $this->opn_rel_type_action_secondary_images = $t_relationship_types->getRelationshipTypeID("ca_objects_x_occurrences", "secondary");
     $va_access_values = caGetUserAccessValues($this->request);
     $this->opa_access_values = $va_access_values;
     $this->view->setVar('access_values', $va_access_values);
 }
开发者ID:guaykuru,项目名称:pawtucket,代码行数:30,代码来源:ShowController.php


示例2: Index

 public function Index()
 {
     JavascriptLoadManager::register('browsable');
     JavascriptLoadManager::register('hierBrowser');
     // Remove any browse criteria previously set
     $this->opo_browse->removeAllCriteria();
     parent::Index(true);
     # --- get the featured collections
     $va_featured = array();
     $va_access_values = caGetUserAccessValues($this->request);
     $t_featured = new ca_sets();
     $t_featured->load(array('set_code' => "featured_collections"));
     # Enforce access control on set
     if (sizeof($va_access_values) == 0 || sizeof($va_access_values) && in_array($t_featured->get("access"), $va_access_values)) {
         $va_featured_collections = caExtractValuesByUserLocale($t_featured->getItems(array('checkAccess' => $va_access_values, 'shuffle' => 1)));
         // These are the collection ids in the set
     }
     if (is_array($va_featured_collections) && sizeof($va_featured_collections) > 0) {
         $va_featured_collections = array_slice($va_featured_collections, 0, 5);
         foreach ($va_featured_collections as $vn_i => $va_collection_info) {
             $va_temp = array();
             $va_temp["idno"] = $va_collection_info["idno"];
             $va_temp["collection_id"] = $va_collection_info["row_id"];
             $va_temp["label"] = $va_collection_info["set_item_label"];
             $va_featured[$va_collection_info["set_item_label"]] = $va_temp;
         }
     }
     arsort($va_featured);
     $this->view->setVar("featured_collections", $va_featured);
     $this->render('collections_landing_index_html.php');
 }
开发者ID:guaykuru,项目名称:pawtucket,代码行数:31,代码来源:CollectionsController.php


示例3: index

 function index()
 {
     if (!$this->request->isLoggedIn()) {
         $this->response->setRedirect(caNavUrl($this->request, '', 'LoginReg', 'form'));
         return;
     }
     if (!($t_set = $this->_getSet())) {
         $t_set = new ca_sets();
     }
     JavascriptLoadManager::register('sortableUI');
     # --- get all sets for user
     $va_sets = caExtractValuesByUserLocale($t_set->getSets(array('table' => 'ca_objects', 'user_id' => $this->request->getUserID())));
     $t_new_set = new ca_sets();
     # --- new set object used for access drop down in new set form
     $this->view->setVar('t_set', $t_set);
     $this->view->setVar('t_new_set', $t_new_set);
     $this->view->setVar('set_list', $va_sets);
     $this->view->setVar('set_name', $t_set->getLabelForDisplay());
     $this->view->setVar('set_description', $t_set->get("ca_sets.set_intro"));
     $this->view->setVar('set_access', $t_set->get("ca_sets.access"));
     if ($this->request->config->get("dont_enforce_access_settings")) {
         $va_access_values = array();
     } else {
         $va_access_values = caGetUserAccessValues($this->request);
     }
     $this->view->setVar('items', caExtractValuesByUserLocale($t_set->getItems(array('thumbnailVersions' => array('thumbnail', 'icon'), 'checkAccess' => $va_access_values, 'user_id' => $this->request->getUserID()))));
     $this->render('Sets/sets_html.php');
 }
开发者ID:guaykuru,项目名称:pawtucket,代码行数:28,代码来源:SetsController.php


示例4: __construct

 public function __construct(&$po_request, &$po_response, $pa_view_paths = null)
 {
     $this->ops_theme = __CA_THEME__;
     // get current theme
     if (!is_dir(__CA_APP_DIR__ . '/plugins/eastend/themes/' . $this->ops_theme . '/views')) {
         // if theme is not defined for this plugin, try to use "default" theme
         $this->ops_theme = 'default';
     }
     parent::__construct($po_request, $po_response, array(__CA_APP_DIR__ . '/plugins/eastend/themes/' . $this->ops_theme . '/views'));
     MetaTagManager::addLink('stylesheet', $po_request->getBaseUrlPath() . "/app/plugins/eastend/themes/" . $this->ops_theme . "/css/eastend.css", 'text/css');
     $this->opo_plugin_config = Configuration::load($this->request->getAppConfig()->get('application_plugins') . '/eastend/conf/eastend.conf');
     if (!(bool) $this->opo_plugin_config->get('enabled')) {
         die(_t('eastend plugin is not enabled'));
     }
     // redirect user if not logged in
     if ($this->request->config->get('pawtucket_requires_login') && !$this->request->isLoggedIn()) {
         $this->response->setRedirect(caNavUrl($this->request, "", "LoginReg", "form"));
     }
     if ($this->request->config->get("dont_enforce_access_settings")) {
         $this->opa_access_values = array();
     } else {
         $this->opa_access_values = caGetUserAccessValues($this->request);
     }
     $this->view->setVar('access_values', $va_access_values);
     $this->opo_result_context = new ResultContext($po_request, 'ca_objects', ResultContext::getLastFind($po_request, 'ca_objects'));
     JavascriptLoadManager::register('cycle');
 }
开发者ID:guaykuru,项目名称:pawtucket,代码行数:27,代码来源:ObjectSlideshowController.php


示例5: __construct

 /**
  *
  */
 public function __construct(&$po_request, &$po_response, $pa_view_paths = null)
 {
     $this->ops_theme = __CA_THEME__;
     // get current theme
     if (!is_dir(__CA_APP_DIR__ . '/plugins/Contribute/themes/' . $this->ops_theme . '/views')) {
         // if theme is not defined for this plugin, try to use "default" theme
         $this->ops_theme = 'default';
     }
     parent::__construct($po_request, $po_response, array(__CA_APP_DIR__ . '/plugins/Contribute/themes/' . $this->ops_theme . '/views'));
     #$this->opo_plugin_config = Configuration::load($po_request->getAppConfig()->get('application_plugins').'/Contribute/conf/contribute.conf');
     if (file_exists($po_request->getAppConfig()->get('application_plugins') . '/Contribute/themes/' . $this->ops_theme . '/conf/contribute.conf')) {
         // check if there is a config file in the theme first
         $this->opo_plugin_config = Configuration::load($po_request->getAppConfig()->get('application_plugins') . '/Contribute/themes/' . $this->ops_theme . '/conf/contribute.conf');
     } else {
         $this->opo_plugin_config = Configuration::load($po_request->getAppConfig()->get('application_plugins') . '/Contribute/conf/contribute.conf');
     }
     if (!(bool) $this->opo_plugin_config->get('enabled')) {
         die(_t('Contribute plugin is not enabled'));
     }
     $vs_default_ui = $this->opo_plugin_config->get('default_ui');
     $vs_requested_ui = $this->request->getParameter('ui', pString);
     $va_ui_list = $this->opo_plugin_config->getAssoc('uis');
     $o_dm = Datamodel::load();
     if (isset($va_ui_list[$vs_requested_ui]) && is_array($va_ui_list[$vs_requested_ui])) {
         $this->opa_ui_info = $va_ui_list[$vs_requested_ui];
         $this->ops_ui_code = $vs_requested_ui;
     } else {
         if (isset($va_ui_list[$vs_default_ui]) && is_array($va_ui_list[$vs_default_ui])) {
             $this->opa_ui_info = $va_ui_list[$vs_default_ui];
         } else {
             $vs_default_ui = array_shift(array_keys($va_ui_list));
             $this->opa_ui_info = $va_ui_list[$vs_default_ui];
         }
         $this->ops_ui_code = $vs_default_ui;
     }
     $this->ops_table_name = $this->opa_ui_info['table'];
     if (!($this->opo_instance = $o_dm->getInstanceByTableName($this->ops_table_name, true))) {
         die(_t('Invalid table "%1" specified in Contribute plugin for form "%2"', $this->ops_table_name, $vs_default_ui));
     }
     $t_list = new ca_lists();
     if (isset($this->opa_ui_info['type']) && $this->opa_ui_info['type']) {
         $this->opa_ui_info['type_id'] = $t_list->getItemIDFromList($this->opo_instance->getTypeListCode(), $this->opa_ui_info['type']);
     }
     if (isset($this->opa_ui_info['representation_type']) && $this->opa_ui_info['representation_type']) {
         $this->opa_ui_info['representation_type_id'] = $t_list->getItemIDFromList('object_representation_types', $this->opa_ui_info['representation_type']);
     }
     ContributePlugin::setUIInfo($this->ops_ui_code, $this->opa_ui_info);
     JavascriptLoadManager::register('panel');
     MetaTagManager::addLink('stylesheet', $po_request->getBaseUrlPath() . "/app/plugins/Contribute/themes/" . $this->ops_theme . "/css/contribute.css", 'text/css');
     $this->request->setParameter('dont_set_pawtucket2_last_page', '1');
     // Setting this parameter ensures that the "last page" we (may) redirect to after submission isn't the Contribute form itself
     if ($this->opa_ui_info['require_login'] && !$po_request->isLoggedIn()) {
         $this->notification->addNotification(_t("You must be logged in to use user contribution features."), __NOTIFICATION_TYPE_ERROR__);
         $this->response->setRedirect(caNavUrl($this->request, '', 'LoginReg', 'form'));
         return;
     }
 }
开发者ID:guaykuru,项目名称:pawtucket,代码行数:60,代码来源:FormController.php


示例6: Show

 /**
  * Displays the basic info for an object
  */
 public function Show($pa_options = null)
 {
     JavascriptLoadManager::register('panel');
     parent::Show($pa_options);
     // redirect user if not logged in
     if ($this->request->config->get('pawtucket_requires_login') && !$this->request->isLoggedIn() || $this->request->config->get('show_bristol_only') && !$this->request->isLoggedIn()) {
         $this->response->setRedirect(caNavUrl($this->request, "", "LoginReg", "form"));
     } elseif ($this->request->config->get('show_bristol_only') && $this->request->isLoggedIn()) {
         $this->response->setRedirect(caNavUrl($this->request, "bristol", "Show", "Index"));
     }
 }
开发者ID:guaykuru,项目名称:pawtucket,代码行数:14,代码来源:ObjectController.php


示例7: __construct

 public function __construct($ps_plugin_path)
 {
     $this->description = _t('Adds Google Analytics functionality to Pawtucket');
     $this->opo_config = Configuration::load($ps_plugin_path . '/conf/GoogleAnalytics.conf');
     $account = $this->opo_config->get('account');
     $googleAnalyticsCode = "\n// GoogleAnalytics \n var _gaq = _gaq || []; _gaq.push(['_setAccount', '^account']); _gaq.push(['_trackPageview']); \n (function() {var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); })(); \n";
     // If a defined GoogleAnalytics account is defined, include the javascript code
     if ($account) {
         $googleAnalyticsCode = str_replace("^account", $account, $googleAnalyticsCode);
         JavascriptLoadManager::addComplementaryScript($googleAnalyticsCode);
     }
     parent::__construct();
 }
开发者ID:guaykuru,项目名称:pawtucket,代码行数:13,代码来源:GoogleAnalyticsPlugin.php


示例8: __construct

 public function __construct(&$po_request, &$po_response, $pa_view_paths = null)
 {
     parent::__construct($po_request, $po_response, $pa_view_paths);
     if (!$this->request->isLoggedIn()) {
         $this->notification->addNotification(_t("You must be logged in to view your orders"), __NOTIFICATION_TYPE_ERROR__);
         $this->response->setRedirect(caNavUrl($this->request, '', 'Splash', 'Index'), 302);
         return;
     }
     $this->opo_client_services_config = Configuration::load($this->request->config->get('client_services_config'));
     $this->view->setVar('client_services_config', $this->opo_client_services_config);
     $this->view->setVar('currency', $this->opo_client_services_config->get('currency'));
     $this->view->setVar('currency_symbol', $this->opo_client_services_config->get('currency_symbol'));
     JavascriptLoadManager::register("panel");
 }
开发者ID:guaykuru,项目名称:pawtucket,代码行数:14,代码来源:AccountController.php


示例9: __construct

 public function __construct(&$po_request, &$po_response, $pa_view_paths = null)
 {
     JavascriptLoadManager::register('panel');
     JavascriptLoadManager::register('jquery', 'expander');
     parent::__construct($po_request, $po_response, $pa_view_paths);
     $this->opo_plugin_config = Configuration::load($this->request->getAppConfig()->get('application_plugins') . '/clir2/conf/clir2.conf');
     if (!(bool) $this->opo_plugin_config->get('enabled')) {
         die(_t('clir2 plugin is not enabled'));
     }
     $this->ops_theme = __CA_THEME__;
     // get current theme
     if (!is_dir(__CA_APP_DIR__ . '/plugins/clir2/views/' . $this->ops_theme)) {
         // if theme is not defined for this plugin, try to use "default" theme
         $this->ops_theme = 'default';
     }
     $this->opo_result_context = new ResultContext($po_request, 'ca_occurrences', 'exhibits');
 }
开发者ID:guaykuru,项目名称:pawtucket,代码行数:17,代码来源:ExhibitsController.php


示例10: Index

 public function Index()
 {
     JavascriptLoadManager::register('imageScroller');
     $va_access_values = caGetUserAccessValues($this->request);
     // get sets for public display
     $t_list = new ca_lists();
     $vn_public_set_type_id = $t_list->getItemIDFromList('set_types', $t_list->getAppConfig()->get('features_set_type'));
     // get value for public access status value
     $va_tmp = $t_list->getItemFromList('access_statuses', 'public_access');
     $vn_public_access = $va_tmp['item_value'];
     $t_set = new ca_sets();
     $va_sets = caExtractValuesByUserLocale($t_set->getSets(array('table' => 'ca_objects', 'checkAccess' => $va_access_values, 'setType' => $vn_public_set_type_id)));
     $va_set_ids = array();
     foreach ($va_sets as $va_set) {
         $va_set_ids[] = $va_set['set_id'];
     }
     $this->view->setVar('sets', $va_sets);
     $this->view->setVar('set_ids', $va_set_ids);
     $this->view->setVar('set_display_items', ca_sets::getFirstItemsFromSets($va_set_ids, array("version" => "preview160")));
     $this->render('features_landing_html.php');
 }
开发者ID:guaykuru,项目名称:pawtucket,代码行数:21,代码来源:ShowController.php


示例11: __construct

 public function __construct(&$po_request, &$po_response, $pa_view_paths = null)
 {
     JavascriptLoadManager::register('panel');
     JavascriptLoadManager::register('jquery', 'expander');
     JavascriptLoadManager::register('jquery', 'swipe');
     parent::__construct($po_request, $po_response, $pa_view_paths);
     // redirect user if not logged in
     if ($this->request->config->get('pawtucket_requires_login') && !$this->request->isLoggedIn() || $this->request->config->get('show_bristol_only') && !$this->request->isLoggedIn()) {
         $this->response->setRedirect(caNavUrl($this->request, "", "LoginReg", "form"));
     }
     $this->opo_plugin_config = Configuration::load($this->request->getAppConfig()->get('application_plugins') . '/bristol/conf/bristol.conf');
     if (!(bool) $this->opo_plugin_config->get('enabled')) {
         die(_t('bristol plugin is not enabled'));
     }
     $this->ops_theme = __CA_THEME__;
     // get current theme
     if (!is_dir(__CA_APP_DIR__ . '/plugins/bristol/views/' . $this->ops_theme)) {
         // if theme is not defined for this plugin, try to use "default" theme
         $this->ops_theme = 'default';
     }
     $this->opo_result_context = new ResultContext($po_request, 'ca_objects', 'simple_gallery');
 }
开发者ID:guaykuru,项目名称:pawtucket,代码行数:22,代码来源:ShowController.php


示例12: __construct

 public function __construct(&$po_request, &$po_response, $pa_view_paths = null)
 {
     $this->ops_theme = __CA_THEME__;
     // get current theme
     if (!is_dir(__CA_APP_DIR__ . '/plugins/NovaMuse/themes/' . $this->ops_theme . '/views')) {
         // if theme is not defined for this plugin, try to use "default" theme
         $this->ops_theme = 'default';
     }
     parent::__construct($po_request, $po_response, array(__CA_APP_DIR__ . '/plugins/NovaMuse/themes/' . $this->ops_theme . '/views'));
     $this->opo_plugin_config = Configuration::load($this->request->getAppConfig()->get('application_plugins') . '/NovaMuse/conf/NovaMuse.conf');
     if (!(bool) $this->opo_plugin_config->get('enabled')) {
         die(_t('NovaMuse plugin is not enabled'));
     }
     MetaTagManager::addLink('stylesheet', $po_request->getBaseUrlPath() . "/app/plugins/NovaMuse/themes/" . $this->ops_theme . "/css/memberMap.css", 'text/css');
     JavascriptLoadManager::register('maps');
     $this->opo_result_context = new ResultContext($po_request, 'ca_entities', 'member_map');
     $t_list = new ca_lists();
     $this->opn_member_institution_id = $t_list->getItemIDFromList('entity_types', 'member_institution');
     $va_access_values = caGetUserAccessValues($this->request);
     $this->opa_access_values = $va_access_values;
     $this->view->setVar('access_values', $va_access_values);
 }
开发者ID:guaykuru,项目名称:pawtucket,代码行数:22,代码来源:MemberMapController.php


示例13: __construct

 public function __construct(&$po_request, &$po_response, $pa_view_paths = null)
 {
     $this->ops_theme = __CA_THEME__;
     // get current theme
     if (!is_dir(__CA_APP_DIR__ . '/plugins/eastend/themes/' . $this->ops_theme . '/views')) {
         // if theme is not defined for this plugin, try to use "default" theme
         $this->ops_theme = 'default';
     }
     parent::__construct($po_request, $po_response, array(__CA_APP_DIR__ . '/plugins/eastend/themes/' . $this->ops_theme . '/views'));
     MetaTagManager::addLink('stylesheet', $po_request->getBaseUrlPath() . "/app/plugins/eastend/themes/" . $this->ops_theme . "/css/eastend.css", 'text/css');
     $this->opo_plugin_config = Configuration::load($this->request->getAppConfig()->get('application_plugins') . '/eastend/conf/eastend.conf');
     if (!(bool) $this->opo_plugin_config->get('enabled')) {
         die(_t('eastend plugin is not enabled'));
     }
     // redirect user if not logged in
     if ($this->request->config->get('pawtucket_requires_login') && !$this->request->isLoggedIn()) {
         $this->response->setRedirect(caNavUrl($this->request, "", "LoginReg", "form"));
     }
     JavascriptLoadManager::register('cycle');
     $t_list = new ca_lists();
     $this->view->setVar("user_contributed_source_id", $t_list->getItemIDFromList('object_sources', 'user_contributed'));
     $this->view->setVar("user_contributed_other_source_id", $t_list->getItemIDFromList('object_sources', 'user_contributed_other'));
 }
开发者ID:guaykuru,项目名称:pawtucket,代码行数:23,代码来源:ParticipateController.php


示例14: index

 function index()
 {
     if (!$this->request->isLoggedIn()) {
         $this->response->setRedirect(caNavUrl($this->request, '', 'LoginReg', 'form'));
         return;
     }
     if (!($t_folder = $this->_getFolder())) {
         $t_folder = new ca_bookmark_folders();
     }
     JavascriptLoadManager::register('sortableUI');
     # --- get all folders for user
     $va_folders = $t_folder->getFolders($this->request->getUserID());
     $this->view->setVar('t_folder', $t_folder);
     $this->view->setVar('folder_list', $va_folders);
     $this->view->setVar('folder_name', $t_folder->get("name"));
     if ($this->request->config->get("dont_enforce_access_settings")) {
         $va_access_values = array();
     } else {
         $va_access_values = caGetUserAccessValues($this->request);
     }
     $this->view->setVar('items', $t_folder->getBookmarks(null, $this->request->getUserID()));
     $this->render('Bookmarks/bookmarks_html.php');
 }
开发者ID:guaykuru,项目名称:pawtucket,代码行数:23,代码来源:BookmarksController.php


示例15: Show

 /**
  * Generates detail detail. Will use a view named according to the following convention:
  *		<table_name>_<type_code>_detail_html.php
  *
  * So for example, the detail for objects of type 'artwork' (where 'artwork' is the type code for the artwork object type)
  * the view would be named "ca_objects_artwork_detail_html.php
  *
  * If the type specific view does not exist, then Show() will attemp to use a generic table-wide view name like this:
  *		<table_name>_detail_html.php
  *
  * For example: "ca_objects_detail_html.php"
  *
  * In general you should always have the table wide views defined. Then you can define type-specific views for your
  * application on an as-needed basis.
  */
 public function Show($pa_options = null)
 {
     JavascriptLoadManager::register('viz');
     JavascriptLoadManager::register("ca", "panel");
     JavascriptLoadManager::register("jit");
     JavascriptLoadManager::register('browsable');
     JavascriptLoadManager::register('imageScroller');
     JavascriptLoadManager::register('jquery', 'expander');
     $va_access_values = caGetUserAccessValues($this->request);
     $this->view->setVar('access_values', $va_access_values);
     if (!($t_item = $this->opo_datamodel->getInstanceByTableName($this->ops_tablename, true))) {
         die("Invalid table name " . $this->ops_tablename . " for detail");
         // shouldn't happen
     }
     if (!($vn_item_id = $this->request->getParameter($t_item->primaryKey(), pInteger))) {
         $this->notification->addNotification(_t("Invalid ID"), "message");
         $this->response->setRedirect(caNavUrl($this->request, "", "", "", ""));
         return;
     }
     if (!$t_item->load($vn_item_id)) {
         $this->notification->addNotification(_t("ID does not exist"), "message");
         $this->response->setRedirect(caNavUrl($this->request, "", "", "", ""));
         return;
     }
     if ($t_item->hasField('deleted') && $t_item->get('deleted')) {
         $this->notification->addNotification(_t("ID has been deleted"), "message");
         $this->response->setRedirect(caNavUrl($this->request, "", "", "", ""));
         return;
     }
     // Check if item conforms to any configured display type restrictions
     if (method_exists($t_item, "getTypeID")) {
         $va_types = caMergeTypeRestrictionLists($t_item, array());
         if (is_array($va_types) && sizeof($va_types) && !in_array($t_item->getTypeID(), $va_types)) {
             $this->notification->addNotification(_t("This item is not viewable"), "message");
             $this->response->setRedirect(caNavUrl($this->request, "", "", "", ""));
             return;
         }
     }
     #
     # Enforce access control
     #
     if (sizeof($va_access_values) && !in_array($t_item->get("access"), $va_access_values)) {
         $this->notification->addNotification(_t("This item is not available for view"), "message");
         $this->response->setRedirect(caNavUrl($this->request, "", "", "", ""));
         return;
     }
     //
     // In-detail browsing of objects - limited to object linked to the item being displayed
     //
     if (($vs_browse_for_table = $this->request->config->get('allow_browse_within_detail_for_' . $this->ops_tablename)) && is_object($this->opo_browse)) {
         // set browse context for controller
         $this->setContext($this->opo_browse->getContext());
         //
         // Restrict facets to specific group for refine browse (if set in app.conf config)
         //
         if ($vs_facet_group = $this->request->config->get('ca_objects_refine_facet_group')) {
             $this->opo_browse->setFacetGroup($vs_facet_group);
         }
         $t_table = $this->opo_datamodel->getInstanceByTableName($this->ops_tablename, true);
         if ($this->request->session->getVar($this->ops_tablename . '_' . $this->ops_appname . '_detail_current_item_id') != $vn_item_id) {
             $this->opo_browse->removeAllCriteria();
         }
         // look for 'authority' facet for current detail table type so we can limit the object browse to the currently displayed item
         //$vs_limit_facet_name = null;
         //foreach($this->opo_browse->getInfoForFacets() as $vs_facet_name => $va_facet_info) {
         //	if (($va_facet_info['type'] === 'authority') && ($va_facet_info['table'] === $this->ops_tablename)) {
         //		$vs_limit_facet_name = $vs_facet_name;
         //		break;
         //	}
         //}
         $this->opo_browse->addFacetConfiguration($vs_limit_facet_name = '_detail_browse_' . $this->ops_tablename, array('type' => 'authority', 'table' => $this->ops_tablename, 'relationship_table' => 'ca_objects_x_entities', 'restrict_to_types' => array(), 'restrict_to_relationship_types' => array(), 'label_singular' => 'Detail browse by ' . $this->ops_tablename, 'label_plural' => 'Detail browse by ' . $this->ops_tablename, 'group_mode' => 'none', 'indefinite_article' => 'a'));
         if ($vs_limit_facet_name) {
             if (($va_configured_type_restrictions = $this->request->config->getList($this->ops_tablename . '_detail_browse_type_restrictions')) && is_array($va_configured_type_restrictions)) {
                 $this->opo_browse->setTypeRestrictions($va_configured_type_restrictions, array('includeChildren' => false));
             }
             $this->opo_browse->addCriteria($vs_limit_facet_name, array($vn_item_id));
             $this->opo_browse->execute(array('checkAccess' => $va_access_values));
             $this->request->session->setVar($this->ops_tablename . '_' . $this->ops_appname . '_detail_current_browse_id', $this->opo_browse->getBrowseID());
             $this->view->setVar('show_browse', true);
             //
             // Browse paging
             //
             $vn_items_per_page = $this->request->config->get("objects_per_page_for_detail_pages");
             if (!$vn_items_per_page) {
                 $vn_items_per_page = 12;
//.........这里部分代码省略.........
开发者ID:guaykuru,项目名称:pawtucket,代码行数:101,代码来源:BaseDetailController.php


示例16:

 *
 * This program is free software; you may redistribute it and/or modify it under
 * the terms of the provided license as published by Whirl-i-Gig
 *
 * CollectiveAccess is distributed in the hope that it will be useful, but
 * WITHOUT ANY WARRANTIES whatsoever, including any implied warranty of 
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  
 *
 * This source code is free and modifiable under the terms of 
 * GNU General Public License. (http://www.gnu.org/copyleft/gpl.html). See
 * the "license.txt" file for details, or visit the CollectiveAccess web site at
 * http://www.CollectiveAccess.org
 *
 * ----------------------------------------------------------------------
 */
JavascriptLoadManager::register('hierBrowser');
$vs_id_prefix = $this->getVar('placement_code') . $this->getVar('id_prefix');
$t_item = $this->getVar('t_item');
// list item
$t_item_rel = $this->getVar('t_item_rel');
$va_settings = $this->getVar('settings');
$vs_add_label = $this->getVar('add_label');
$va_rel_types = $this->getVar('relationship_types');
$va_initial_values = $this->getVar('initialValues');
?>
<div id="<?php 
print $vs_id_prefix . $t_item->tableNum() . '_rel';
?>
">
<?php 
//
开发者ID:guaykuru,项目名称:pawtucket,代码行数:31,代码来源:ca_list_items.php


示例17: _t

    print $va_facet_info['label_plural'];
    ?>
</a><br/>
<?php 
}
?>
				</div>
				<div style="margin-top:10px;" class="caption">
					<?php 
print _t("Or click \"Browse\" in the navigation bar to do a refined browse");
?>
				</div>
			</div> -->
		</div><!-- end quickLinkItems -->
<?php 
JavascriptLoadManager::register('cycle');
$t_slider = new ca_sets();
$t_slider->load(array('set_code' => 'siteFeatured'));
//$va_items = $t_slider->getItems(array('thumbnailVersions' => array('medium', 'mediumlarge'), 'checkAccess' => $va_access_values));
$va_images = $t_slider->getRepresentationTags('widesplash', array('checkAccess' => $va_access_values, 'quote' => true));
$t_slider = new ca_sets();
$t_slider->load(array('set_code' => 'cultureFeatured'));
//$va_items = $t_slider->getItems(array('thumbnailVersions' => array('medium', 'mediumlarge'), 'checkAccess' => $va_access_values));
$va_images2 = $t_slider->getRepresentationTags('widesplash', array('checkAccess' => $va_access_values, 'quote' => true));
?>
		
<script type="text/javascript">
	caUI.initCycle('#hpSlider', { 
				fx: 'fade', 
				imageList: [
<?php 
开发者ID:guaykuru,项目名称:pawtucket,代码行数:31,代码来源:splash_html.php


示例18: _initView

 /**
  * Generates display summary of record data based upon a bundle display for screen
  *
  * @param array $pa_options Array of options passed through to _initView 
  */
 protected function _initView($pa_options = null)
 {
     // load required javascript
     JavascriptLoadManager::register('bundleableEditor');
     JavascriptLoadManager::register('imageScroller');
     $t_subject = $this->opo_datamodel->getInstanceByTableName($this->ops_table_name);
     $t_subject->purify(true);
     // filter HTML for bad things like <script> tags and malformed markup
     // empty (ie. new) rows don't have a type_id set, which means we'll have no idea which attributes to display
     // so we get the type_id off of the request
     if (!($vn_type_id = $this->request->getParameter($t_subject->getTypeFieldName(), pInteger))) {
         $vn_type_id = null;
     }
     // then set the empty row's type_id
     $t_subject->set($t_subject->getTypeFieldName(), $vn_type_id);
     // then reload the definitions (which includes bundle specs)
     $t_subject->reloadLabelDefinitions();
     $t_ui = new ca_editor_uis();
     if (isset($pa_options['ui']) && $pa_options['ui']) {
         if (is_numeric($pa_options['ui'])) {
             $t_ui->load((int) $pa_options['ui']);
         }
         if (!$t_ui->getPrimaryKey()) {
             $t_ui->load(array('editor_code' => $pa_options['ui']));
         }
     }
     if (!$t_ui->getPrimaryKey()) {
         $t_ui->loadDefaultUI($this->ops_table_name, $this->request);
     }
     $this->view->setVar('t_subject', $t_subject);
     return array(null, $t_subject, $t_ui);
 }
开发者ID:guaykuru,项目名称:pawtucket,代码行数:37,代码来源:BaseEditorController.php


示例19: array

 *
 * This program is free software; you may redistribute it and/or modify it under
 * the terms of the provided license as published by Whirl-i-Gig
 *
 * CollectiveAccess is distributed in the hope that it will be useful, but
 * WITHOUT ANY WARRANTIES whatsoever, including any implied warranty of 
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  
 *
 * This source code is free and modifiable under the terms of 
 * GNU General Public License. (http://www.gnu.org/copyleft/gpl.html). See
 * the "license.txt" file for details, or visit the CollectiveAccess web site at
 * http://www.CollectiveAccess.org
 *
 * ----------------------------------------------------------------------
 */
JavascriptLoadManager::register('sortableUI');
$vs_id_prefix = $this->getVar('placement_code') . $this->getVar('id_prefix');
$t_mapping = $this->getVar('t_mapping');
$t_group = $this->getVar('t_group');
$t_screen = $this->getVar('t_screen');
$vs_target = $t_mapping->get('target');
$va_initial_values = $this->getVar('groups');
// list of existing groups
// process rules for display
foreach ($va_initial_values as $vn_group_id => $va_group) {
    if (!is_array($va_group['rules'])) {
        $va_group['rules'] = array();
    }
    $vs_rule_display = '<table>';
    $vs_rule_display .= "<tr><td class='formLabel'>CollectiveAccess</td><td> </td><td class='formLabel'>{$vs_target}</td></tr>";
    foreach ($va_group['rules'] as $vn_rule_id => $va_rule) {
开发者ID:guaykuru,项目名称:pawtucket,代码行数:31,代码来源:ca_bundle_mapping_groups.php


示例20: Detail

 function Detail()
 {
     JavascriptLoadManager::register('panel');
     if ($this->request->config->get("dont_enforce_access_settings")) {
         $va_access_values = array();
     } else {
         $va_access_values = caGetUserAccessValues($this->request);
     }
     $va_jumpToList = $this->ops_jumpToList;
     $this->view->setVar('jumpToList', $va_jumpToList);
     $va_periods = $this->ops_periods;
     $this->view->setVar('periods', $va_periods);
     $vn_year = $this->request->getParameter('year', pInteger);
     $vn_period = $this->request->getParameter('period', pInteger);
     if (!$vn_period) {
         if ($vn_year) {
             # --- determine the period from the year
             foreach ($va_periods as $i => $va_per_info) {
                 if ($vn_year >= $va_per_info["start"] && $vn_year <= $va_per_info["end"]) {
                     $vn_period = $i;
                     break;
                 }
             }
         }
     }
     $this->view->setVar('period', $vn_period);
     if (!$vn_year) {
         $vn_year = $va_periods[$vn_period]["start"];
     }
     $this->view->setVar('year', $vn_year);
     $vn_y = "";
     if ($va_periods[$vn_period]["displayAllYears"] == 1) {
         $vn_y = $va_periods[$vn_period]["start"] . " to " . $va_periods[$vn_period]["end"];
     } else {
         $vn_y = $vn_year;
     }
     $o_search = new OccurrenceSearch();
     $t_list = new ca_lists();
     $vn_chronology_type_id = $t_list->getItemIDFromList('occurrence_types', 'chronology');
     $vn_exhibition_type_id = $t_list->getItemIDFromList('occurrence_types', 'exhibition');
     $vn_bibliography_type_id = $t_list->getItemIDFromList('occurrence_types', 'bibliography');
     $vn_artwork_type_id = $t_list->getItemIDFromList('object_types', 'artwork');
     $vn_chron_images_type_id = $t_list->getItemIDFromList('object_types', 'chronology_image');
     $va_years_info = array();
     $qr_events = $o_search->search("ca_occurrences.access:1 AND ca_occurrences.type_id: 

鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
PHP Javelin类代码示例发布时间:2022-05-23
下一篇:
PHP JavaScriptPacker类代码示例发布时间:2022-05-23
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap