CREATE TABLE IF NOT EXISTS `Visits` (
  `ID` INT NOT NULL AUTO_INCREMENT,
  `VDate` DATE NOT NULL,
  `CustName` VARCHAR(200) NOT NULL,
  `SupName` VARCHAR(200) NOT NULL,
  `Fly` VARCHAR(20) NOT NULL DEFAULT 'يوجد',
  `Creepy` VARCHAR(20) NOT NULL DEFAULT 'يوجد',
  `Radent` VARCHAR(20) NOT NULL DEFAULT 'يوجد',
  `Clean` VARCHAR(20) NOT NULL DEFAULT 'جيد',
  `Waste` VARCHAR(20) NOT NULL DEFAULT 'جيد',
  `OutGet` VARCHAR(20) NOT NULL DEFAULT 'تم العمل',
  `InGet` VARCHAR(20) NOT NULL DEFAULT 'تم العمل',
  `Siplet` VARCHAR(20) NOT NULL DEFAULT 'تم العمل',
  `Manhol` VARCHAR(20) NOT NULL DEFAULT 'تم العمل',
  `Materials` JSON NULL,
  `Note` TEXT NULL,
  `ImageUrl` TEXT NULL,
  `Office` VARCHAR(200) NULL,
  `CreatedAt` DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP,
  `UpdatedAt` DATETIME NULL DEFAULT NULL ON UPDATE CURRENT_TIMESTAMP,
  PRIMARY KEY (`ID`),
  KEY `idx_visits_vdate` (`VDate`),
  KEY `idx_visits_cust` (`CustName`),
  KEY `idx_visits_sup` (`SupName`),
  KEY `idx_visits_office` (`Office`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

