> For the complete documentation index, see [llms.txt](https://theadam4.gitbook.io/wonder-scripts-docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://theadam4.gitbook.io/wonder-scripts-docs/scripts/wonder-warehouse.md).

# Wonder Warehouse

## Installation

### Putting script to server

* Download script from [keymaster](https://keymaster.fivem.net/)
* Put in your server files
* put **ensure wonder\_warehouse** in your server.cfg

### Creating key items

* in folder items you have **images** and **items.lua**
* put all images into **ox\_inventory/web/images**
* put this bellow (same as you have in **items.lua**) into **ox\_inventory/data/items.lua**

```lua
['warehouse_key'] = {
    label = 'Key',
    weight = 30,
    stack = false,
},
```

### Inserting into database

* open your program where you work with your server database
* find **import file** button
* select **import.sql** file

```sql
CREATE TABLE IF NOT EXISTS `wonder_warehouse` (
  `charid` varchar(50) NOT NULL,
  `warehouse_id` int(16) NOT NULL AUTO_INCREMENT,
  `id_warehouse_kc` varchar(8) DEFAULT NULL,
  `purchased` varchar(50) DEFAULT 'no',
  `pincode` int(4) DEFAULT NULL,
  `opened` varchar(50) DEFAULT 'no',
  PRIMARY KEY (`warehouse_id`)
);
```
