brocksexton / chobots

chobots
3 stars 0 forks source link

Daily draw not working #14

Closed jeqostudios closed 1 year ago

jeqostudios commented 1 year ago

Opening the news HUD and selecting daily draw displays a message saying there is no daily draw active.

brocksexton commented 1 year ago

Daily Draws are enabled in the database, currently no draws exist. This can be fixed using the following SQL command

`

-- Table structure for table Lottery

CREATE TABLE Lottery ( id bigint(20) NOT NULL, created datetime DEFAULT NULL, prizeType varchar(255) NOT NULL, endDate varchar(255) DEFAULT NULL, prize int(11) DEFAULT NULL, ticketPrice int(11) DEFAULT NULL, totalEntries int(11) DEFAULT NULL, cumulativeMode tinyint(1) NOT NULL DEFAULT '0', enabled tinyint(1) NOT NULL DEFAULT '0' ) ENGINE=InnoDB DEFAULT CHARSET=latin1;

-- -- Dumping data for table Lottery

INSERT INTO Lottery (id, created, prizeType, endDate, prize, ticketPrice, totalEntries, cumulativeMode, enabled) VALUES (1, '2023-03-08 12:00:00', 'citizen', '2023,03,09,12,00,00', 3, 100, 3, 0, 1); `

This would ensure that the Table Lottery exists in the database, and would enable a draw for Citizen (3 Days) from March 8, 2023 until March 9, 2023. The Total number of entries is 100 tickets.