PHP Class App\Http\Controllers\Laralum\Laralum

The main Laralum class contains diferent elements to help you develop faster
Inheritance: extends App\Http\Controllers\Controller
Show file Open project: ConsoleTVs/Laralum Class Usage Examples

Public Methods

Method Description
addDownload ( $file_name )
allowEditingField ( )
apiData ( )
avatarsLocation ( )
barChart ( $title, $element_label, $labels, $data, $colors = null )
blog ( $type, $data )
blogs ( $type = null, $data = null )
checkDocumentOwner ( $type, $data )
checkInstalled ( )
checkValueInRelation ( $data, $value, $value_index )
comment ( $type, $data )
comments ( $type = null, $data = null )
countries ( )
countryCodeField ( )
currentURL ( )
dataPath ( )
defaultAvatar ( ) : url Returns the default avatar URL
defaultRole ( )
deleteFile ( $file_name )
document ( $type, $data )
documents ( $type = null, $data = null )
downloadFile ( $file_name )
downloadLink ( $file_name )
dropdown ( $slug, $array = null )
fancyDate ( string $date_string ) : date Formats a string date into a fancy, human readable date
fileExtension ( $file_name )
files ( )
geoChart ( $title, $element_label, $data )
getCountryCode ( $ip )
getIP ( )
imageFormats ( )
includeAssets ( $name )
isAdmin ( $user )
isDocument ( $file_name )
isFile ( $file_name )
laralumLogo ( )
lineChart ( $title, $element_label, $labels, $data, $color = null )
locales ( )
loggedInUser ( )
mustBeAdmin ( $user )
mustBeFile ( $file_name )
mustHaveBlog ( $blog_id )
mustNotBeAdmin ( $user )
mustOwnBlog ( $blog_id )
newBlog ( )
newComment ( )
newDocument ( )
newPermission ( )
newPost ( )
newPostView ( )
newRole ( )
newSocial ( )
newUser ( )
noFlags ( )
permission ( $type, $data )
permissionDescription ( $slug )
permissionName ( $slug )
permissionToAccess ( $slug )
permissions ( $type = null, $data = null )
pieChart ( $title, $labels, $data, $colors = null )
post ( $type, $data )
postView ( $type, $data )
postViews ( $type = null, $data = null )
posts ( $type = null, $data = null )
previousURL ( )
publicPath ( )
randomColor ( )
randomString ( $length = 10 )
rettype ( $mixed, $type = NULL )
role ( $type, $data )
roles ( $type = null, $data = null )
scanFiles ( $directory )
settings ( )
social ( $type, $data )
socials ( $type = null, $data = null )
user ( $type, $data )
userSettings ( )
users ( $type = null, $data = null )
version ( )
websiteTitle ( )
widget ( $name )

Method Details

addDownload() public static method

public static addDownload ( $file_name )

allowEditingField() public static method

public static allowEditingField ( )

apiData() public static method

public static apiData ( )

avatarsLocation() public static method

public static avatarsLocation ( )

barChart() public static method

public static barChart ( $title, $element_label, $labels, $data, $colors = null )

blog() public static method

public static blog ( $type, $data )

blogs() public static method

public static blogs ( $type = null, $data = null )

checkDocumentOwner() public static method

public static checkDocumentOwner ( $type, $data )

checkInstalled() public static method

public static checkInstalled ( )

checkValueInRelation() public static method

public static checkValueInRelation ( $data, $value, $value_index )

comment() public static method

public static comment ( $type, $data )

comments() public static method

public static comments ( $type = null, $data = null )

countries() public static method

public static countries ( )

countryCodeField() public static method

public static countryCodeField ( )

currentURL() public static method

public static currentURL ( )

dataPath() public static method

public static dataPath ( )

defaultAvatar() public static method

When using this function it will return the default avatar URL
public static defaultAvatar ( ) : url
return url

defaultRole() public static method

public static defaultRole ( )

deleteFile() public static method

public static deleteFile ( $file_name )

document() public static method

public static document ( $type, $data )

documents() public static method

public static documents ( $type = null, $data = null )

downloadFile() public static method

public static downloadFile ( $file_name )

dropdown() public static method

public static dropdown ( $slug, $array = null )

fancyDate() public static method

Returns a date formatted for human readable
public static fancyDate ( string $date_string ) : date
$date_string string The date in string format
return date

fileExtension() public static method

public static fileExtension ( $file_name )

files() public static method

public static files ( )

geoChart() public static method

public static geoChart ( $title, $element_label, $data )

getCountryCode() public static method

public static getCountryCode ( $ip )

getIP() public static method

public static getIP ( )

imageFormats() public static method

public static imageFormats ( )

includeAssets() public static method

public static includeAssets ( $name )

isAdmin() public static method

public static isAdmin ( $user )

isDocument() public static method

public static isDocument ( $file_name )

isFile() public static method

public static isFile ( $file_name )

lineChart() public static method

public static lineChart ( $title, $element_label, $labels, $data, $color = null )

locales() public static method

public static locales ( )

loggedInUser() public static method

public static loggedInUser ( )

mustBeAdmin() public static method

public static mustBeAdmin ( $user )

mustBeFile() public static method

public static mustBeFile ( $file_name )

mustHaveBlog() public static method

public static mustHaveBlog ( $blog_id )

mustNotBeAdmin() public static method

public static mustNotBeAdmin ( $user )

mustOwnBlog() public static method

public static mustOwnBlog ( $blog_id )

newBlog() public static method

public static newBlog ( )

newComment() public static method

public static newComment ( )

newDocument() public static method

public static newDocument ( )

newPermission() public static method

public static newPermission ( )

newPost() public static method

public static newPost ( )

newPostView() public static method

public static newPostView ( )

newRole() public static method

public static newRole ( )

newSocial() public static method

public static newSocial ( )

newUser() public static method

public static newUser ( )

noFlags() public static method

public static noFlags ( )

permission() public static method

public static permission ( $type, $data )

permissionDescription() public static method

public static permissionDescription ( $slug )

permissionName() public static method

public static permissionName ( $slug )

permissionToAccess() public static method

public static permissionToAccess ( $slug )

permissions() public static method

public static permissions ( $type = null, $data = null )

pieChart() public static method

public static pieChart ( $title, $labels, $data, $colors = null )

post() public static method

public static post ( $type, $data )

postView() public static method

public static postView ( $type, $data )

postViews() public static method

public static postViews ( $type = null, $data = null )

posts() public static method

public static posts ( $type = null, $data = null )

previousURL() public static method

public static previousURL ( )

publicPath() public static method

public static publicPath ( )

randomColor() public static method

public static randomColor ( )

randomString() public static method

public static randomString ( $length = 10 )

rettype() public static method

public static rettype ( $mixed, $type = NULL )

role() public static method

public static role ( $type, $data )

roles() public static method

public static roles ( $type = null, $data = null )

scanFiles() public static method

public static scanFiles ( $directory )

settings() public static method

public static settings ( )

social() public static method

public static social ( $type, $data )

socials() public static method

public static socials ( $type = null, $data = null )

user() public static method

public static user ( $type, $data )

userSettings() public static method

public static userSettings ( )

users() public static method

public static users ( $type = null, $data = null )

version() public static method

public static version ( )

websiteTitle() public static method

public static websiteTitle ( )

widget() public static method

public static widget ( $name )