Tariqa  3.0
 All Data Structures Namespaces Files Functions Variables Enumerations
Sharing Class Reference
Inheritance diagram for Sharing:
baseModule_RELEX_TARIQANG BaseModuleWithAuthenticationAndLanguages BaseModuleWithAuthentication BaseModule mModule

Public Member Functions

 __construct ($config, $translationTable)
 onExecute ()
 getDefaultTemplateFile ()
 canProcessRequest ()

Static Public Member Functions

static shareItem ($user, $db, $share_with, $data, $type, $message, $config, $translationTable)

Data Fields

const SHARE_ARTICLE = 'article'
const SHARE_SEARCH = 'search'
const SHARE_MULTIPLE_SEARCH = 'multiple_search'

Static Protected Member Functions

static uniqueID ($db)

Constructor & Destructor Documentation

__construct ( config,
translationTable 
)

Construct the Module object

Parameters:
array$configThe multidimentionnal array containing the application's configuration
array$translationTableThe translation table

Reimplemented from baseModule_RELEX_TARIQANG.


Member Function Documentation

Process the request that have the page set to ajax

Reimplemented from mModule.

Gets the default template file public

Returns:
string|null

Reimplemented from mModule.

onExecute ( )

Render the module

Returns:
string

Reimplemented from mModule.

static shareItem ( user,
db,
share_with,
data,
type,
message,
config,
translationTable 
) [static]

Shares a list of articles

Parameters:
tariqaUser$userThe user trying to share the article
mMysql$dbThe database connection
string[]$share_with The list of users to share with (the format should be the following: for each id a string in POST format - mail=your-.nosp@m.acco.nosp@m.unt@y.nosp@m.our-.nosp@m.serve.nosp@m.r.co.nosp@m.m&id=your-id)
array$dataThe data to be shared
string$typeThe type of the sharing (search or article)
string$messageA custom message for the users that you are sharing the material with.
array$configThe configuration array
array$translationTableThe translation table public
Returns:
string
static uniqueID ( db) [static, protected]

Generates an unique ID

Parameters:
mMysql$dbThe database connection protected
Returns:
int

Field Documentation

const SHARE_ARTICLE = 'article'
const SHARE_MULTIPLE_SEARCH = 'multiple_search'
const SHARE_SEARCH = 'search'

The documentation for this class was generated from the following file: