コード例 #1
0
ファイル: cbdocman.php プロジェクト: kosmosby/medicine-prof
	/**
	 * Labeller for title:
	 * Returns a profile view tab title
	 *
	 * @param  TabTable   $tab       the tab database entry
	 * @param  UserTable  $user      the user being displayed
	 * @param  int        $ui        1 for front-end, 2 for back-end
	 * @param  array      $postdata  _POST data for saving edited tab content as generated with getEditTab
	 * @return string|boolean        Either string HTML for tab content, or false if ErrorMSG generated
	 */
	public function getTabTitle( $tab, $user, $ui, $postdata )
	{
		$plugin		=	cbdocmanClass::getPlugin();
		$viewer		=	CBuser::getMyUserDataInstance();
		$total		=	cbdocmanModel::getDocmanTotal( null, $viewer, $user, $plugin );

		return parent::getTabTitle( $tab, $user, $ui, $postdata ) . ' <span class="badge badge-default">' . (int) $total . '</span>';
	}
コード例 #2
0
ファイル: cbhangout.php プロジェクト: kosmosby/medicine-prof
	/**
	 * Labeller for title:
	 * Returns a profile view tab title
	 *
	 * @param  TabTable   $tab       the tab database entry
	 * @param  UserTable  $user      the user being displayed
	 * @param  int        $ui        1 for front-end, 2 for back-end
	 * @param  array      $postdata  _POST data for saving edited tab content as generated with getEditTab
	 * @return string|boolean        Either string HTML for tab content, or false if ErrorMSG generated
	 */
	public function getTabTitle( $tab, $user, $ui, $postdata )
	{
		global $_LANG;

                $plugin		=	cbhangoutClass::getPlugin();
		$viewer		=	CBuser::getMyUserDataInstance();
		$total		=	cbhangoutModel::getHangoutTotal( null, $viewer, $user, $plugin );
                $tab->title = $_LANG[$tab->title] ? $_LANG[$tab->title] : $tab->title;
		return parent::getTabTitle( $tab, $user, $ui, $postdata ) . ' <span class="badge badge-default">' . (int) $total . '</span>';
	}
コード例 #3
0
  /**
   * Returns a profile view tab title
   *
   * @param  TabTable   $tab       the tab database entry
   * @param  UserTable  $user      the user being displayed
   * @param  int        $ui        1 for front-end, 2 for back-end
   * @param  array      $postdata  _POST data for saving edited tab content as generated with getEditTab
   * @return string|boolean        Either string HTML for tab content, or false if ErrorMSG generated
   */
  
  public function getTabTitle( $tab, $user, $ui, $postdata )
  {

    return parent::getTabTitle( $tab, $user, $ui, $postdata );
  }