2023-03-21 22:52:57 +00:00
|
|
|
```
|
|
|
|
██████╗ ██████╗ ██╗ ██╗███████╗██████╗
|
|
|
|
██╔══██╗██╔═══██╗██║ ██║██╔════╝██╔══██╗
|
|
|
|
██████╔╝██║ ██║██║ █╗ ██║█████╗ ██████╔╝
|
|
|
|
██╔═══╝ ██║ ██║██║███╗██║██╔══╝ ██╔══██╗
|
|
|
|
██║ ╚██████╔╝╚███╔███╔╝███████╗██║ ██║
|
|
|
|
╚═╝ ╚═════╝ ╚══╝╚══╝ ╚══════╝╚═╝ ╚═╝
|
|
|
|
```
|
|
|
|
# interface InsertInterface (Details)
|
|
|
|
> namespace: **VDM\Joomla\Componentbuilder\Interfaces**
|
|
|
|
```uml
|
|
|
|
@startuml
|
|
|
|
interface InsertInterface #Lavender {
|
2023-04-13 15:44:10 +00:00
|
|
|
+ defaults(bool $trigger = true) : void
|
|
|
|
+ rows(array $data, string $table, ...) : bool
|
|
|
|
+ items(array $data, string $table, ...) : bool
|
2023-03-21 22:52:57 +00:00
|
|
|
+ row(array $data, string $table) : bool
|
2023-04-13 15:44:10 +00:00
|
|
|
+ item(object $data, string $table) : bool
|
2023-03-21 22:52:57 +00:00
|
|
|
}
|
|
|
|
|
2023-04-13 15:44:10 +00:00
|
|
|
note right of InsertInterface::defaults
|
|
|
|
Switch to prevent/allow defaults from being added.
|
|
|
|
|
|
|
|
since: 3.2.0
|
|
|
|
return: void
|
|
|
|
end note
|
|
|
|
|
2023-03-21 22:52:57 +00:00
|
|
|
note right of InsertInterface::rows
|
2023-04-13 15:44:10 +00:00
|
|
|
Insert rows to the database (with remapping and filtering columns option)
|
2023-03-21 22:52:57 +00:00
|
|
|
|
|
|
|
since: 3.2.0
|
|
|
|
return: bool
|
2023-04-13 15:44:10 +00:00
|
|
|
|
|
|
|
arguments:
|
|
|
|
array $data
|
|
|
|
string $table
|
|
|
|
array $columns = []
|
2023-03-21 22:52:57 +00:00
|
|
|
end note
|
|
|
|
|
|
|
|
note right of InsertInterface::items
|
2023-04-13 15:44:10 +00:00
|
|
|
Insert items to the database (with remapping and filtering columns option)
|
2023-03-21 22:52:57 +00:00
|
|
|
|
|
|
|
since: 3.2.0
|
|
|
|
return: bool
|
|
|
|
|
|
|
|
arguments:
|
|
|
|
array $data
|
|
|
|
string $table
|
2023-04-13 15:44:10 +00:00
|
|
|
array $columns = []
|
2023-03-21 22:52:57 +00:00
|
|
|
end note
|
|
|
|
|
|
|
|
note right of InsertInterface::row
|
2023-04-13 15:44:10 +00:00
|
|
|
Insert row to the database
|
|
|
|
|
|
|
|
since: 3.2.0
|
|
|
|
return: bool
|
|
|
|
end note
|
|
|
|
|
|
|
|
note right of InsertInterface::item
|
|
|
|
Insert item to the database
|
2023-03-21 22:52:57 +00:00
|
|
|
|
|
|
|
since: 3.2.0
|
|
|
|
return: bool
|
|
|
|
end note
|
|
|
|
|
|
|
|
@enduml
|
|
|
|
```
|
|
|
|
|
|
|
|
---
|
|
|
|
```
|
|
|
|
██╗ ██████╗██████╗
|
|
|
|
██║██╔════╝██╔══██╗
|
|
|
|
██║██║ ██████╔╝
|
|
|
|
██ ██║██║ ██╔══██╗
|
|
|
|
╚█████╔╝╚██████╗██████╔╝
|
|
|
|
╚════╝ ╚═════╝╚═════╝
|
|
|
|
```
|
|
|
|
> Build with [Joomla Component Builder](https://git.vdm.dev/joomla/Component-Builder)
|
|
|
|
|