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

PHP midcom类代码示例

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

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



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

示例1: test_handler_delete

 public function test_handler_delete()
 {
     midcom::get('auth')->request_sudo('org.openpsa.user');
     $data = $this->run_handler('org.openpsa.user', array('delete', self::$_user->guid));
     $this->assertEquals('user_delete', $data['handler_id']);
     midcom::get('auth')->drop_sudo();
 }
开发者ID:nemein,项目名称:openpsa,代码行数:7,代码来源:deleteTest.php


示例2: testHandler_render

 public function testHandler_render()
 {
     midcom::get('auth')->request_sudo('org.openpsa.relatedto');
     $data = $this->run_handler('org.openpsa.invoices', array('__mfa', 'org.openpsa.relatedto', 'render', self::$_object_from->guid, 'both'));
     $this->assertEquals('____mfa-org.openpsa.relatedto-render', $data['handler_id']);
     midcom::get('auth')->drop_sudo();
 }
开发者ID:nemein,项目名称:openpsa,代码行数:7,代码来源:relatedtoTest.php


示例3: test_handler_json

 public function test_handler_json()
 {
     midcom::get('auth')->request_sudo('org.openpsa.user');
     $data = $this->run_handler('org.openpsa.user', array('json'));
     $this->assertEquals('user_list_json', $data['handler_id']);
     midcom::get('auth')->drop_sudo();
 }
开发者ID:nemein,项目名称:openpsa,代码行数:7,代码来源:listTest.php


示例4: reopen_account

 /**
  * Function to unblock an account after too many failed to login attempts
  *
  * @param array $args Contains the guid, parameter & parameter names to get username&password
  */
 function reopen_account($args, &$handler)
 {
     midcom::get('auth')->request_sudo($this->_component);
     try {
         $person = new midcom_db_person($args['guid']);
     } catch (midcom_error $e) {
         $msg = 'Person with guid #' . $args['guid'] . ' does not exist';
         debug_add($msg, MIDCOM_LOG_ERROR);
         $handler->print_error($msg);
         midcom::get('auth')->drop_sudo();
         return false;
     }
     $accounthelper = new org_openpsa_user_accounthelper($person);
     try {
         $accounthelper->reopen_account();
     } catch (midcom_error $e) {
         midcom::get('auth')->drop_sudo();
         $e->log();
         $handler->print_error($e->getMessage());
         midcom::get('auth')->drop_sudo();
         return false;
     }
     midcom::get('auth')->drop_sudo();
     return true;
 }
开发者ID:nemein,项目名称:openpsa,代码行数:30,代码来源:interfaces.php


示例5: _on_initialize

 /**
  * Initialization script placeholder. Not yet needed.
  *
  * @return boolean Indicating success
  */
 public function _on_initialize()
 {
     // Enable jQuery. This will not work without
     midcom::get('head')->enable_jquery();
     midcom::get('head')->add_jsfile(MIDCOM_STATIC_URL . '/midcom.helper.datamanager2/datamanager2.tablesorter.js');
     // Default values
     $sortable_rows = 'false';
     $sortable_columns = 'false';
     if (!$this->_type->row_limit) {
         $this->_type->row_limit = 0;
     }
     if (!$this->_type->column_limit) {
         $this->_type->column_limit = 0;
     }
     if ($this->_type->sortable_rows) {
         $sortable_rows = 'true';
     }
     if ($this->_type->sortable_columns) {
         $sortable_columns = 'true';
     }
     $preserve_columns = '|' . implode('|,|', array_keys($this->_type->columns)) . '|';
     // Configuration options
     midcom::get('head')->add_jscript("\n            jQuery(document).ready(function()\n            {\n                jQuery('#midcom_helper_datamanager2_{$this->_type->name}_widget_tabledata')\n                    .create_tablesorter({\n                        table_id: '#midcom_helper_datamanager2_{$this->_type->name}_widget_tabledata',\n                        field_name: '{$this->_type->name}',\n                        max_row_count: {$this->_type->row_limit},\n                        max_column_count: {$this->_type->column_limit},\n                        sortable_rows: {$sortable_rows},\n                        sortable_columns: {$sortable_columns},\n                        preserve_columns: '{$preserve_columns}',\n                        allow_delete: true\n                    });\n            });\n\n            COLUMN_TITLE = '" . $this->_type->_l10n->get('please enter the column title') . "';\n        ");
     return true;
 }
开发者ID:nemein,项目名称:openpsa,代码行数:30,代码来源:tabledata.php


示例6: testCRUD

 public function testCRUD()
 {
     midcom::get('auth')->request_sudo('org.openpsa.invoices');
     $data = new org_openpsa_invoices_billing_data_dba();
     $data->linkGuid = self::$_contact->guid;
     $data->useContactAddress = true;
     $stat = $data->create();
     $this->assertTrue($stat, midcom_connection::get_error_string());
     $this->register_object($data);
     $parent = $data->get_parent();
     $this->assertEquals($parent->guid, self::$_contact->guid);
     self::$_contact->refresh();
     $this->assertEquals(self::$_contact->street, $data->street);
     $data->vat = 12;
     $data->due = 12;
     $stat = $data->update();
     $this->assertTrue($stat);
     self::$_contact->refresh();
     $invoice = new org_openpsa_invoices_invoice_dba();
     $invoice->customerContact = self::$_contact->id;
     $invoice_data = $invoice->get_billing_data();
     $this->assertEquals($data->guid, $invoice_data->guid);
     $this->assertEquals($data->vat, $invoice->get_default('vat'));
     $this->assertEquals($data->due, $invoice->get_default('due'));
     $stat = $data->delete();
     $this->assertTrue($stat);
     midcom::get('auth')->drop_sudo();
 }
开发者ID:nemein,项目名称:openpsa,代码行数:28,代码来源:dataTest.php


示例7: testHandler_index_timestamp

 public function testHandler_index_timestamp()
 {
     midcom::get('auth')->request_sudo('org.openpsa.expenses');
     $data = $this->run_handler('org.openpsa.expenses', array('2011-01-26'));
     $this->assertEquals('index_timestamp', $data['handler_id']);
     midcom::get('auth')->drop_sudo();
 }
开发者ID:nemein,项目名称:openpsa,代码行数:7,代码来源:indexTest.php


示例8: _handler_edit

 /**
  * Handler for folder metadata. Checks for updating permissions, initializes
  * the metadata and the content topic itself. Handles also the sent form.
  *
  * @param mixed $handler_id The ID of the handler.
  * @param Array $args The argument list.
  * @param Array &$data The local request data.
  * @return boolean Indicating success
  */
 public function _handler_edit($handler_id, array $args, array &$data)
 {
     $this->_object = midcom::get('dbfactory')->get_object_by_guid($args[0]);
     // FIXME: We should modify the schema according to whether or not scheduling is used
     $this->_object->require_do('midgard:update');
     midcom::get('auth')->require_user_do('midgard.admin.asgard:manage_objects', null, 'midgard_admin_asgard_plugin');
     if (is_a($this->_object, 'midcom_db_topic')) {
         // This is a topic
         $this->_topic->require_do('midgard.admin.asgard:topic_management');
     }
     $this->_metadata = midcom_helper_metadata::retrieve($this->_object);
     if (!$this->_metadata) {
         throw new midcom_error("Failed to retrieve Metadata for " . get_class($this->_object) . " {$this->_object->guid}.");
     }
     // Load the DM2 controller instance
     $this->_controller = $this->get_controller('simple', $this->_object);
     switch ($this->_controller->process_form()) {
         case 'save':
             // Reindex the object
             //$indexer = midcom::get('indexer');
             //net_nemein_wiki_viewer::index($this->_request_data['controller']->datamanager, $indexer, $this->_topic);
             // *** FALL-THROUGH ***
             midcom::get('cache')->invalidate($this->_object->guid);
             return new midcom_response_relocate("__mfa/asgard/object/metadata/{$this->_object->guid}");
         case 'cancel':
             return new midcom_response_relocate("__mfa/asgard/object/view/{$this->_object->guid}");
     }
     $this->_prepare_request_data();
     midgard_admin_asgard_plugin::bind_to_object($this->_object, $handler_id, $data);
 }
开发者ID:nemein,项目名称:openpsa,代码行数:39,代码来源:metadata.php


示例9: org_routamc_positioning_send_sms

function org_routamc_positioning_send_sms($to, $message, $from, $config)
{
    $sms_lib = 'org.openpsa.smslib';
    midcom::get('componentloader')->load_library($sms_lib);
    $sms_lib_api = $config->get('smslib_api');
    $sms_lib_location = $config->get('smslib_uri');
    $sms_lib_client_id = $config->get('smslib_client_id');
    $sms_lib_user = $config->get('smslib_user');
    $sms_lib_password = $config->get('smslib_password');
    if (!$sms_lib_api || !$sms_lib_location || !$sms_lib_user) {
        return false;
    }
    @ini_set('max_execution_time', 0);
    //Initializing SMS broker
    $smsbroker = call_user_func(array(str_replace('.', '_', $sms_lib), 'factory'), $sms_lib_api);
    if (!is_object($smsbroker)) {
        debug_add(str_replace('.', '_', $sms_lib) . "::factory({$sms_lib_api}) returned: {$smsbroker}", MIDCOM_LOG_ERROR);
        return false;
    }
    $smsbroker->location = $sms_lib_location;
    $smsbroker->client_id = $sms_lib_client_id;
    $smsbroker->user = $sms_lib_user;
    $smsbroker->password = $sms_lib_password;
    return $smsbroker->send_sms($to, $message, $from);
}
开发者ID:nemein,项目名称:openpsa,代码行数:25,代码来源:manual-position.php


示例10: testHandler_edit

 public function testHandler_edit()
 {
     midcom::get('auth')->request_sudo('org.openpsa.products');
     $data = $this->run_handler('org.openpsa.products', array('product', 'edit', self::$_product->guid));
     $this->assertEquals('edit_product', $data['handler_id']);
     midcom::get('auth')->drop_sudo();
 }
开发者ID:nemein,项目名称:openpsa,代码行数:7,代码来源:editTest.php


示例11: move_extensions_to_object

 /**
  * Transfers all parameters attachments and privileges on the current object to another
  * existing Midgard object. You need to have midgard:update, midgard:parameter,
  * midgard:privileges and midgard:attachments privileges on the target object,
  * which must be a persistent MidCOM DBA class instance. (For ease of use, it is recommended
  * to have midgard:owner rights for the target object, which includes the above
  * privileges).
  *
  * <b>Important notes:</b>
  *
  * All records in question will just be moved, not copied!
  * Also, there will be <i>no</i> integrity checking in terms of already existing
  * parameters etc. This feature is mainly geared towards preparing a freshly
  * created final object with the data associated with this temporary object.
  *
  * Any invalid object / missing privilege will trigger a midcom_error.
  *
  * @param midcom_dba_object $object The object to transfer the extensions to.
  */
 function move_extensions_to_object($object)
 {
     if (!midcom::get('dbclassloader')->is_midcom_db_object($object)) {
         throw new midcom_error('The object passed is no valid for move_extensions_to_object.');
     }
     // Validate Privileges
     $object->require_do('midgard:update');
     $object->require_do('midgard:privileges');
     $object->require_do('midgard:parameters');
     $object->require_do('midgard:attachments');
     // Copy parameters from temporary object
     $parameters = $this->list_parameters();
     foreach ($parameters as $domain => $array) {
         foreach ($array as $name => $value) {
             $object->set_parameter($domain, $name, $value);
         }
     }
     // Move attachments from temporary object
     $attachments = $this->list_attachments();
     foreach ($attachments as $attachment) {
         $attachment->parentguid = $object->guid;
         $attachment->update();
     }
     // Privileges are moved using the DBA API as well.
     $privileges = $this->get_privileges();
     if ($privileges) {
         foreach ($privileges as $privilege) {
             $privilege->set_object($object);
             $privilege->store();
         }
     }
 }
开发者ID:nemein,项目名称:openpsa,代码行数:51,代码来源:object.php


示例12: _handler_approval

 /**
  * Checks the integrity of the content topic and gets the stored approvals of
  * the content folder.
  *
  * @param mixed $handler_id The ID of the handler.
  * @param Array $args The argument list.
  * @param Array &$data The local request data.
  */
 public function _handler_approval($handler_id, array $args, array &$data)
 {
     if (!array_key_exists('guid', $_REQUEST) || !array_key_exists('return_to', $_REQUEST)) {
         throw new midcom_error('Cannot process approval request, request is incomplete.');
     }
     $object = midcom::get('dbfactory')->get_object_by_guid($_REQUEST['guid']);
     $object->require_do('midcom:approve');
     $metadata = midcom_helper_metadata::retrieve($object);
     if (!$metadata) {
         throw new midcom_error("Failed to retrieve Metadata for " . get_class($object) . " {$object->guid}.");
     }
     /**
      * This flag is used to make it possible to explicitly recognize user intent
      * to for example do special operations in midcom.helper.replicator
      */
     if (!isset($GLOBALS['midcom_admin_folder_handler_approvals']) || !is_array($GLOBALS['midcom_admin_folder_handler_approvals'])) {
         $GLOBALS['midcom_admin_folder_handler_approvals'] = array();
     }
     if ($handler_id == '____ais-folder-approve') {
         $GLOBALS['midcom_admin_folder_handler_approvals'][$object->guid] = 'approve';
         $metadata->approve();
     } else {
         $GLOBALS['midcom_admin_folder_handler_approvals'][$object->guid] = 'unapprove';
         $metadata->unapprove();
     }
     return new midcom_response_relocate($_REQUEST['return_to']);
 }
开发者ID:nemein,项目名称:openpsa,代码行数:35,代码来源:approvals.php


示例13: _on_execute

 /**
  * Loads all entries that need to be processed and processes them.
  */
 public function _on_execute()
 {
     $qb = midcom_services_at_entry_dba::new_query_builder();
     // (to be) start(ed) AND last touched over two days ago
     $qb->add_constraint('start', '<=', time() - 3600 * 24 * 2);
     $qb->begin_group('OR');
     $qb->add_constraint('host', '=', midcom_connection::get('host'));
     $qb->add_constraint('host', '=', 0);
     $qb->end_group();
     $qb->add_constraint('metadata.revised', '<=', date('Y-m-d H:i:s', time() - 3600 * 24 * 2));
     $qb->add_constraint('status', '>=', midcom_services_at_entry_dba::RUNNING);
     midcom::get('auth')->request_sudo('midcom.services.at');
     $qbret = $qb->execute();
     if (empty($qbret)) {
         debug_add('Got empty resultset, exiting');
         midcom::get('auth')->drop_sudo();
         return;
     }
     foreach ($qbret as $entry) {
         debug_add("Deleting dangling entry #{$entry->id}\n", MIDCOM_LOG_INFO);
         debug_print_r("Entry #{$entry->id} dump: ", $entry);
         $entry->delete();
     }
     midcom::get('auth')->drop_sudo();
 }
开发者ID:nemein,项目名称:openpsa,代码行数:28,代码来源:clean.php


示例14: testHandler_groupsblock

 public function testHandler_groupsblock()
 {
     midcom::get('auth')->request_sudo('org.openpsa.products');
     $data = $this->run_handler('org.openpsa.products', array('groupsblock', self::$_group->code, 'foo'));
     $this->assertEquals('groupsblock', $data['handler_id']);
     midcom::get('auth')->drop_sudo();
 }
开发者ID:nemein,项目名称:openpsa,代码行数:7,代码来源:groupsblockTest.php


示例15: test_get_default

 public function test_get_default()
 {
     $config = array('type_config' => array('allow_multiple' => false, 'options' => array(1 => 'value 1', 2 => 'value 2')));
     $default_values = array('test_select_1' => array(2));
     midcom::get('auth')->request_sudo('midcom.helper.datamanager2');
     $dm2_helper = new openpsa_test_dm2_helper();
     $widget = $dm2_helper->get_widget('select', 'select', $config);
     $this->assertNull($widget->get_default(), 'nullstorage test failed');
     $dm2_helper->defaults = array('test_select_1' => 2);
     $widget = $dm2_helper->get_widget('select', 'select', $config);
     $this->assertEquals($default_values, $widget->get_default(), 'nullstorage/default test failed');
     $config['storage'] = 'type';
     $event = new midcom_db_event();
     $dm2_helper = new openpsa_test_dm2_helper($event);
     $widget = $dm2_helper->get_widget('select', 'select', $config);
     $this->assertNull($widget->get_default(), 'create test failed');
     $dm2_helper->defaults = array('test_select_1' => 2);
     $widget = $dm2_helper->get_widget('select', 'select', $config);
     $this->assertEquals($default_values, $widget->get_default(), 'create/default test failed');
     $event = $this->create_object('midcom_db_event');
     $dm2_helper = new openpsa_test_dm2_helper($event);
     $widget = $dm2_helper->get_widget('select', 'select', $config);
     $this->assertEquals('', $widget->get_default(), 'simple test failed');
     $event->type = 2;
     $event->update();
     $dm2_helper = new openpsa_test_dm2_helper($event);
     //Lazy workaround to reuse the default array from above
     $dm2_helper->get_widget('select', 'select', $config);
     $widget = $dm2_helper->get_widget('select', 'select', $config);
     $this->assertEquals($default_values, $widget->get_default(), 'simple/storage test failed');
     midcom::get('auth')->drop_sudo();
 }
开发者ID:nemein,项目名称:openpsa,代码行数:32,代码来源:selectTest.php


示例16: test_handler_notifications

 public function test_handler_notifications()
 {
     midcom::get('auth')->request_sudo('org.openpsa.user');
     $data = $this->run_handler('org.openpsa.user', array('person', 'notifications', self::$_user->guid));
     $this->assertEquals('person_notifications', $data['handler_id']);
     midcom::get('auth')->drop_sudo();
 }
开发者ID:nemein,项目名称:openpsa,代码行数:7,代码来源:notificationsTest.php


示例17: _handler_frontpage

 /**
  * @param mixed $handler_id The ID of the handler.
  * @param Array $args The argument list.
  * @param Array &$data The local request data.
  */
 public function _handler_frontpage($handler_id, array $args, array &$data)
 {
     $this->_view_toolbar->add_item(array(MIDCOM_TOOLBAR_URL => 'salesproject/new/', MIDCOM_TOOLBAR_LABEL => $this->_l10n->get('create salesproject'), MIDCOM_TOOLBAR_ICON => 'stock-icons/16x16/stock_people.png', MIDCOM_TOOLBAR_ENABLED => midcom::get('auth')->can_user_do('midgard:create', null, 'org_openpsa_sales_salesproject_dba')));
     org_openpsa_widgets_ui::enable_ui_tab();
     $sales_url = org_openpsa_core_siteconfig::get_instance()->get_node_relative_url('org.openpsa.sales');
     $data['tabs'] = array(array('url' => $sales_url . "list/active/", 'title' => $this->_l10n->get('active')), array('url' => $sales_url . "list/won/", 'title' => $this->_l10n->get('won')), array('url' => $sales_url . "list/delivered/", 'title' => $this->_l10n->get('delivered')), array('url' => $sales_url . "list/invoiced/", 'title' => $this->_l10n->get('invoiced')), array('url' => $sales_url . "list/canceled/", 'title' => $this->_l10n->get('canceled')), array('url' => $sales_url . "list/lost/", 'title' => $this->_l10n->get('lost')));
 }
开发者ID:nemein,项目名称:openpsa,代码行数:12,代码来源:frontpage.php


示例18: testCreate

 public function testCreate()
 {
     midcom::get('auth')->request_sudo('org.openpsa.relatedto');
     $invoice = $this->create_object('org_openpsa_invoices_invoice_dba');
     $salesproject = $this->create_object('org_openpsa_sales_salesproject_dba');
     $relatedto = org_openpsa_relatedto_plugin::create($invoice, 'org.openpsa.invoices', $salesproject, 'org.openpsa.sales');
     $this->assertTrue(is_a($relatedto, 'org_openpsa_relatedto_dba'));
     $this->register_object($relatedto);
     $this->assertEquals($relatedto->status, org_openpsa_relatedto_dba::CONFIRMED);
     $this->assertEquals($relatedto->fromGuid, $invoice->guid);
     $this->assertEquals($relatedto->fromComponent, 'org.openpsa.invoices');
     $this->assertEquals($relatedto->fromClass, 'org_openpsa_invoices_invoice_dba');
     $this->assertEquals($relatedto->toGuid, $salesproject->guid);
     $this->assertEquals($relatedto->toComponent, 'org.openpsa.sales');
     $this->assertEquals($relatedto->toClass, 'org_openpsa_sales_salesproject_dba');
     $relatedto2 = org_openpsa_relatedto_plugin::create($invoice, 'org.openpsa.invoices', $salesproject, 'org.openpsa.sales');
     $this->assertEquals($relatedto2->guid, $relatedto->guid);
     $x = null;
     $stat = org_openpsa_relatedto_plugin::create($x, 'org.openpsa.invoices', $salesproject, 'org.openpsa.sales');
     $this->assertFalse($stat);
     $stat = org_openpsa_relatedto_plugin::create($invoice, 'org.openpsa.invoices', $x, 'org.openpsa.sales');
     $this->assertFalse($stat);
     $relatedto2 = org_openpsa_relatedto_plugin::create($invoice, 'org.openpsa.invoices', $salesproject, 'org.openpsa.sales', org_openpsa_relatedto_dba::NOTRELATED);
     $this->assertEquals($relatedto2->guid, $relatedto->guid);
     $this->assertEquals($relatedto2->status, org_openpsa_relatedto_dba::NOTRELATED);
     $stat = $relatedto->delete();
     $this->assertTrue($stat);
     midcom::get('auth')->drop_sudo();
 }
开发者ID:nemein,项目名称:openpsa,代码行数:29,代码来源:pluginTest.php


示例19: _handler_frontpage

 /**
  * @param mixed $handler_id The ID of the handler.
  * @param Array $args The argument list.
  * @param Array &$data The local request data.
  */
 public function _handler_frontpage($handler_id, array $args, array &$data)
 {
     midcom::get('auth')->require_valid_user();
     $this->_view_toolbar->add_item(array(MIDCOM_TOOLBAR_URL => 'project/new/', MIDCOM_TOOLBAR_LABEL => $this->_l10n->get("create project"), MIDCOM_TOOLBAR_ICON => 'stock-icons/16x16/new-dir.png', MIDCOM_TOOLBAR_ENABLED => midcom::get('auth')->can_user_do('midgard:create', null, 'org_openpsa_projects_project')));
     $this->_view_toolbar->add_item(array(MIDCOM_TOOLBAR_URL => 'task/new/', MIDCOM_TOOLBAR_LABEL => $this->_l10n->get("create task"), MIDCOM_TOOLBAR_ICON => 'stock-icons/16x16/new_task.png', MIDCOM_TOOLBAR_ENABLED => midcom::get('auth')->can_user_do('midgard:create', null, 'org_openpsa_projects_task_dba')));
     // List current projects, sort by customer
     $data['customers'] = array();
     $project_qb = org_openpsa_projects_project::new_query_builder();
     $project_qb->add_constraint('status', '<', org_openpsa_projects_task_status_dba::CLOSED);
     $project_qb->add_order('customer.official');
     $project_qb->add_order('end');
     $projects = $project_qb->execute();
     foreach ($projects as $project) {
         if (!isset($data['customers'][$project->customer])) {
             $data['customers'][$project->customer] = array();
         }
         $data['customers'][$project->customer][] = $project;
     }
     // Projects without customer have to be queried separately, see #97
     $nocustomer_qb = org_openpsa_projects_project::new_query_builder();
     $nocustomer_qb->add_constraint('status', '<', org_openpsa_projects_task_status_dba::CLOSED);
     $nocustomer_qb->add_constraint('customer', '=', 0);
     $nocustomer_qb->add_order('end');
     if ($nocustomer_qb->count() > 0) {
         $data['customers'][0] = $nocustomer_qb->execute();
     }
     $closed_qb = org_openpsa_projects_project::new_query_builder();
     $closed_qb->add_constraint('status', '=', org_openpsa_projects_task_status_dba::CLOSED);
     $data['closed_count'] = $closed_qb->count();
     $this->add_stylesheet(MIDCOM_STATIC_URL . "/org.openpsa.core/list.css");
     midcom::get('head')->add_jsfile(MIDCOM_STATIC_URL . '/org.openpsa.projects/frontpage.js');
     midcom::get('head')->set_pagetitle($this->_l10n->get('current projects'));
 }
开发者ID:nemein,项目名称:openpsa,代码行数:38,代码来源:frontpage.php


示例20: testHandler_delete

 public function testHandler_delete()
 {
     midcom::get('auth')->request_sudo('net.nehmer.static');
     $data = $this->run_handler(self::$_topic, array('delete', self::$_article->guid));
     $this->assertEquals('delete', $data['handler_id']);
     midcom::get('auth')->drop_sudo();
 }
开发者ID:nemein,项目名称:openpsa,代码行数:7,代码来源:adminTest.php



注:本文中的midcom类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

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

请发表评论

全部评论

专题导读
上一篇:
PHP midcom_connection类代码示例发布时间:2022-05-23
下一篇:
PHP messenger类代码示例发布时间: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