lucee.Componentcborm.models.BaseORMService
cborm.models.VirtualEntityService
contentbox.models.system.SiteService
ContentBox - A Modular Content Platform Copyright since 2012 by Ortus Solutions, Corp www.ortussolutions.com/products/contentbox --- Manage sites in ContentBox
Property Summary | ||||
---|---|---|---|---|
type | property | default | serializable | required |
any
|
cacheStorage
|
true
|
false
|
|
any
|
categoryService
|
true
|
false
|
|
any
|
contentService
|
true
|
false
|
|
any
|
cookieStorage
|
true
|
false
|
|
any
|
loadedModules
|
true
|
false
|
|
any
|
mediaService
|
true
|
false
|
|
any
|
menuService
|
true
|
false
|
|
any
|
requestService
|
true
|
false
|
|
any
|
requestStorage
|
true
|
false
|
|
any
|
settingService
|
true
|
false
|
|
any
|
themeService
|
true
|
false
|
Constructor Summary | |
---|---|
init()
Constructor. |
Method Summary | |
---|---|
private any
|
_save(any site)
Save operation called by the transactional `save()` method. |
SiteService
|
delete(any site)
Delete an entire site from the system. |
Site
|
discoverSite()
This method discovers which site you are on and returns it depending on the following markers:. |
boolean
|
ensureSiteMediaFolder(any site)
This method makes sure the site has a media root folder by convention in the media library. |
array
|
getAllFlat([boolean isActive])
Get an array/struct representation of all sites in the system. |
any
|
getAllForExport()
Get all sites for export. |
array
|
getAllSiteThemes()
Returns a collection of all the themes that are used in all active sites. |
any
|
getBySlugOrFail(any slug)
Get by slug or fail. |
string
|
getCacheStorage()
|
string
|
getCategoryService()
|
string
|
getContentService()
|
string
|
getCookieStorage()
|
Site
|
getCurrentWorkingSite()
Get the current working site in the admin UI. |
any
|
getCurrentWorkingsiteID()
Get the current working site in the admin UI. |
Site
|
getDefaultSite()
Get the default site object. |
string
|
getDefaultsiteID()
Get the default site Identifier. |
string
|
getLoadedModules()
|
string
|
getMediaService()
|
string
|
getMenuService()
|
any
|
getOrFail(any siteID)
Get an id or fail. |
string
|
getRequestService()
|
string
|
getRequestStorage()
|
string
|
getSettingService()
|
string
|
getThemeService()
|
string
|
importFromData(any importData, [boolean override='false'], any importLog)
Import data from an array of structures or a single structure of data. |
string
|
importFromFile(any importFile, [boolean override='false'])
Import data from a ContentBox JSON file. |
any
|
importSite(any site, any memento, any importLog, any override)
Import a site into ContentBox. |
Site
|
save(any site, [boolean transactional='true'])
Save a site object in the system. |
any
|
setCacheStorage(any cacheStorage)
|
any
|
setCategoryService(any categoryService)
|
any
|
setContentService(any contentService)
|
any
|
setCookieStorage(any cookieStorage)
|
SiteService
|
setCurrentWorkingsiteID(any siteID)
Store the current working site in the admin UI. |
any
|
setLoadedModules(any loadedModules)
|
any
|
setMediaService(any mediaService)
|
any
|
setMenuService(any menuService)
|
any
|
setRequestService(any requestService)
|
any
|
setRequestStorage(any requestStorage)
|
any
|
setSettingService(any settingService)
|
any
|
setThemeService(any themeService)
|
Methods inherited from class cborm.models.VirtualEntityService |
---|
autoCast, convertIdValueToJavaType, convertValueToJavaType, count, countWhere, deleteAll, deleteByID, deleteByQuery, deleteWhere, evictCollection, executeQuery, exists, findAllWhere, findWhere, get, getAll, getEntityName, getKey, getPropertyNames, getTableName, idCast, list, new, newCriteria, onMissingMethod, setEntityName |
Methods inherited from class lucee.Component |
---|
None |
Constructor Detail |
---|
Constructor
Property Detail |
---|
access
- publicrequired
- falsereturntype
- anyinject
- cacheStorage@cbStoragesserializable
- trueaccess
- publicrequired
- falsereturntype
- anyinject
- provider:categoryService@contentboxserializable
- trueaccess
- publicrequired
- falsereturntype
- anyinject
- provider:contentService@contentboxserializable
- trueaccess
- publicrequired
- falsereturntype
- anyinject
- cookieStorage@cbStoragesserializable
- trueaccess
- publicrequired
- falsereturntype
- anyinject
- coldbox:setting:modulesserializable
- trueaccess
- publicrequired
- falsereturntype
- anyinject
- provider:mediaService@contentboxserializable
- trueaccess
- publicrequired
- falsereturntype
- anyinject
- provider:menuService@contentboxserializable
- trueaccess
- publicrequired
- falsereturntype
- anyinject
- coldbox:requestServiceserializable
- trueaccess
- publicrequired
- falsereturntype
- anyinject
- requestStorage@cbStoragesserializable
- trueaccess
- publicrequired
- falsereturntype
- anyinject
- provider:settingService@contentboxserializable
- trueaccess
- publicrequired
- falsereturntype
- anyinject
- provider:themeService@contentboxserializable
- trueMethod Detail |
---|
Save operation called by the transactional `save()` method Due to transactional issues on Lucee
site
Delete an entire site from the system
delete
in class
cborm.models.BaseORMService
site
- The site to removeThis method discovers which site you are on and returns it depending on the following markers: - Are we in the admin, use the current working site - incoming `siteID` (rc) - incoming `siteSlug` (rc) - incoming header: `x-contentbox-site` - full incoming url
This method makes sure the site has a media root folder by convention in the media library following the patter: /{root}/sites/{slug}
site
- The site to ensure the media directory forGet an array/struct representation of all sites in the system
isActive
- If passed, bind via this boolean flagGet all sites for export
Returns a collection of all the themes that are used in all active sites
Get by slug or fail
slug
- The site slugGet the current working site in the admin UI. We look in the cache first, if none is set, we use the `default` site.
Get the current working site in the admin UI. We look in the cache first, if none is set, we use the `default` site.
Get the default site object
Get the default site Identifier
Get an id or fail
getOrFail
in class
cborm.models.VirtualEntityService
siteID
Import data from an array of structures or a single structure of data
importData
- A struct or array of data to importoverride
- Override content if found in the database, defaults to falseimportLog
- The import log bufferImport data from a ContentBox JSON file. Returns the import log
importFile
- The json file to importoverride
- Override content if found in the database, defaults to falseImport a site into ContentBox.
site
- The site object that will be used to importmemento
- The site memento that we will importimportLog
- The string buffer that represents the import logoverride
- Override content if found in the database, defaults to falseSave a site object in the system. If the site is a new site, we make sure all proper settings are created and configured.
save
in class
cborm.models.BaseORMService
site
- A persisted or new site objecttransactional
- Transaction the call or leave as is, useful for imports, bulk saves, etc.cacheStorage
categoryService
contentService
cookieStorage
Store the current working site in the admin UI
siteID
- The site to store as the current working oneloadedModules
mediaService
menuService
requestService
requestStorage
settingService
themeService