-- Add default controller user (username: controller, password: controller123)
-- Run after add_controller_role.sql if controller role ENUM exists

INSERT INTO `users` (`username`, `email`, `password_hash`, `full_name`, `role`, `status`)
VALUES ('controller', 'controller@invcount.local', '$2y$10$M06lRgTcgSOFdghXe6T/Je2mmqF4kZC5QGdi7j089yH3xCPNtXIuO', 'Controller User', 'controller', 'active')
ON DUPLICATE KEY UPDATE 
  `password_hash` = '$2y$10$M06lRgTcgSOFdghXe6T/Je2mmqF4kZC5QGdi7j089yH3xCPNtXIuO',
  `status` = 'active',
  `role` = 'controller';
