Plentymarkets interface documentation
PluginMultilingualism
Contracts
PluginTranslationRepositoryContract
Get, create , update and delete plugin translations.
Namespace
Plenty\Modules\PluginMultilingualism\Contracts
Methods
public listTranslations($filters):array
List translations for plugin set
Name |
Type |
Description |
|
public getTranslation($translationId):Plenty\Modules\PluginMultilingualism\Models\PluginTranslation
Return type: PluginTranslation
Get a translation
Name |
Type |
Description |
|
public createTranslation($data):Plenty\Modules\PluginMultilingualism\Models\PluginTranslation
Return type: PluginTranslation
Create a translation
Name |
Type |
Description |
|
public updateTranslation($data, $translationId):Plenty\Modules\PluginMultilingualism\Models\PluginTranslation
Return type: PluginTranslation
Update a translation
Name |
Type |
Description |
|
||
|
public deleteTranslation($id):void
Delete a translation
Name |
Type |
Description |
|
public deleteTranslations($pluginSetId, $languageCode):void
Delete multiple translation
Name |
Type |
Description |
|
||
|
public updateOrCreateTranslation($data):Plenty\Modules\PluginMultilingualism\Models\PluginTranslation
Return type: PluginTranslation
Update or create a translation
Name |
Type |
Description |
|
public clearCriteria():void
Resets all Criteria filters by creating a new instance of the builder object.
public applyCriteriaFromFilters():void
Applies criteria classes to the current repository.
public setFilters($filters = []):void
Sets the filter array.
Name |
Type |
Description |
|
public getFilters():void
Returns the filter array.
public getConditions():void
Returns a collection of parsed filters as Condition object
public clearFilters():void
Clears the filter array.
Models
PluginTranslation
The plugin translation model.
Namespace
Plenty\Modules\PluginMultilingualism\Models
Name | Type | Description |
---|---|---|
id |
The ID of the translation |
|
pluginSetId |
The ID of the plugin set |
|
pluginName |
The name of the plugin |
|
languageCode |
The code of the language |
|
fileName |
The file of the key |
|
key |
The translation key |
|
value |
The translation value |
|
createdAt |
The date when the translation was created |
|
updatedAt |
The date when the translation was last updated |
|
deletedAt |
The date when the translation was deleted * |
Methods
public toArray()
Returns this model as an array.