





















const db = require('../models');
const Users = db.users;






const Organizations = db.organizations;

const Tenants = db.tenants;

const RoleAssignments = db.role_assignments;

const OrganizationMemberships = db.organization_memberships;

const Properties = db.properties;

const Amenities = db.amenities;

const UnitTypes = db.unit_types;

const Units = db.units;

const UnitAvailabilityBlocks = db.unit_availability_blocks;

const NegotiatedRates = db.negotiated_rates;

const BookingRequests = db.booking_requests;

const BookingRequestTravelers = db.booking_request_travelers;

const ApprovalSteps = db.approval_steps;

const Reservations = db.reservations;

const ReservationGuests = db.reservation_guests;

const ServiceRequests = db.service_requests;

const Invoices = db.invoices;

const InvoiceLineItems = db.invoice_line_items;

const Payments = db.payments;

const Documents = db.documents;

const AuditLogs = db.audit_logs;

const Notifications = db.notifications;

const ActivityComments = db.activity_comments;

const Checklists = db.checklists;

const ChecklistItems = db.checklist_items;

const JobRuns = db.job_runs;







const OrganizationsData = [
    
    {
    
        
        
            
                "name": "Grace Hopper",
            
        
    
    },
    
    {
    
        
        
            
                "name": "Alan Turing",
            
        
    
    },
    
    {
    
        
        
            
                "name": "Alan Turing",
            
        
    
    },
    
];



const TenantsData = [
    
    {
    
        
        
            
                "name": "Ada Lovelace",
            
        
    
        
        
            
                "slug": "Alan Turing",
            
        
    
        
        
            
                "legal_name": "Ada Lovelace",
            
        
    
        
        
            
                "primary_domain": "Ada Lovelace",
            
        
    
        
        
            
                "timezone": "Grace Hopper",
            
        
    
        
        
            
                "default_currency": "Ada Lovelace",
            
        
    
        
        
            
                "is_active": false,
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
    },
    
    {
    
        
        
            
                "name": "Alan Turing",
            
        
    
        
        
            
                "slug": "Ada Lovelace",
            
        
    
        
        
            
                "legal_name": "Ada Lovelace",
            
        
    
        
        
            
                "primary_domain": "Ada Lovelace",
            
        
    
        
        
            
                "timezone": "Grace Hopper",
            
        
    
        
        
            
                "default_currency": "Marie Curie",
            
        
    
        
        
            
                "is_active": true,
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
    },
    
    {
    
        
        
            
                "name": "Alan Turing",
            
        
    
        
        
            
                "slug": "Alan Turing",
            
        
    
        
        
            
                "legal_name": "Grace Hopper",
            
        
    
        
        
            
                "primary_domain": "Grace Hopper",
            
        
    
        
        
            
                "timezone": "Ada Lovelace",
            
        
    
        
        
            
                "default_currency": "Alan Turing",
            
        
    
        
        
            
                "is_active": false,
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
    },
    
];



const RoleAssignmentsData = [
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "is_active": false,
            
        
    
        
        
            
                "effective_from": new Date(Date.now()),
            
        
    
        
        
            
                "effective_until": new Date(Date.now()),
            
        
    
    },
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "is_active": false,
            
        
    
        
        
            
                "effective_from": new Date(Date.now()),
            
        
    
        
        
            
                "effective_until": new Date(Date.now()),
            
        
    
    },
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "is_active": true,
            
        
    
        
        
            
                "effective_from": new Date(Date.now()),
            
        
    
        
        
            
                "effective_until": new Date(Date.now()),
            
        
    
    },
    
];



const OrganizationMembershipsData = [
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "member_role": "super_admin",
            
        
    
        
        
            
                "is_primary": false,
            
        
    
        
        
            
                "is_active": true,
            
        
    
        
        
            
                "job_title": "Marie Curie",
            
        
    
        
        
            
                "phone": "Ada Lovelace",
            
        
    
    },
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "member_role": "internal_concierge",
            
        
    
        
        
            
                "is_primary": true,
            
        
    
        
        
            
                "is_active": false,
            
        
    
        
        
            
                "job_title": "Ada Lovelace",
            
        
    
        
        
            
                "phone": "Ada Lovelace",
            
        
    
    },
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "member_role": "corporate_admin",
            
        
    
        
        
            
                "is_primary": true,
            
        
    
        
        
            
                "is_active": false,
            
        
    
        
        
            
                "job_title": "Ada Lovelace",
            
        
    
        
        
            
                "phone": "Marie Curie",
            
        
    
    },
    
];



const PropertiesData = [
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "name": "Grace Hopper",
            
        
    
        
        
            
                "code": "Marie Curie",
            
        
    
        
        
            
                "address": "Alan Turing",
            
        
    
        
        
            
                "city": "Alan Turing",
            
        
    
        
        
            
                "country": "Ada Lovelace",
            
        
    
        
        
            
                "timezone": "Marie Curie",
            
        
    
        
        
            
                "description": "Grace Hopper",
            
        
    
        
        
            
                // type code here for "images" field
            
        
    
        
        
            
                "is_active": false,
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
    },
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "name": "Marie Curie",
            
        
    
        
        
            
                "code": "Marie Curie",
            
        
    
        
        
            
                "address": "Marie Curie",
            
        
    
        
        
            
                "city": "Grace Hopper",
            
        
    
        
        
            
                "country": "Alan Turing",
            
        
    
        
        
            
                "timezone": "Ada Lovelace",
            
        
    
        
        
            
                "description": "Alan Turing",
            
        
    
        
        
            
                // type code here for "images" field
            
        
    
        
        
            
                "is_active": false,
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
    },
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "name": "Marie Curie",
            
        
    
        
        
            
                "code": "Alan Turing",
            
        
    
        
        
            
                "address": "Alan Turing",
            
        
    
        
        
            
                "city": "Grace Hopper",
            
        
    
        
        
            
                "country": "Alan Turing",
            
        
    
        
        
            
                "timezone": "Alan Turing",
            
        
    
        
        
            
                "description": "Ada Lovelace",
            
        
    
        
        
            
                // type code here for "images" field
            
        
    
        
        
            
                "is_active": false,
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
    },
    
];



const AmenitiesData = [
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "name": "Marie Curie",
            
        
    
        
        
            
                "description": "Alan Turing",
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
    },
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "name": "Alan Turing",
            
        
    
        
        
            
                "description": "Grace Hopper",
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
    },
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "name": "Grace Hopper",
            
        
    
        
        
            
                "description": "Ada Lovelace",
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
    },
    
];



const UnitTypesData = [
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "name": "Marie Curie",
            
        
    
        
        
            
                "code": "Marie Curie",
            
        
    
        
        
            
                "max_occupancy": 5,
            
        
    
        
        
            
                "bedrooms": 8,
            
        
    
        
        
            
                "bathrooms": 4,
            
        
    
        
        
            
                "size_sqm": 2.74,
            
        
    
        
        
            
                "description": "Grace Hopper",
            
        
    
        
        
            
                "base_nightly_rate": 5.98,
            
        
    
        
        
            
                "base_monthly_rate": 9.22,
            
        
    
        
        
            
                "minimum_stay_nights": 6,
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
    },
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "name": "Alan Turing",
            
        
    
        
        
            
                "code": "Alan Turing",
            
        
    
        
        
            
                "max_occupancy": 9,
            
        
    
        
        
            
                "bedrooms": 6,
            
        
    
        
        
            
                "bathrooms": 5,
            
        
    
        
        
            
                "size_sqm": 7.7,
            
        
    
        
        
            
                "description": "Alan Turing",
            
        
    
        
        
            
                "base_nightly_rate": 2.58,
            
        
    
        
        
            
                "base_monthly_rate": 3.14,
            
        
    
        
        
            
                "minimum_stay_nights": 3,
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
    },
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "name": "Ada Lovelace",
            
        
    
        
        
            
                "code": "Alan Turing",
            
        
    
        
        
            
                "max_occupancy": 5,
            
        
    
        
        
            
                "bedrooms": 5,
            
        
    
        
        
            
                "bathrooms": 4,
            
        
    
        
        
            
                "size_sqm": 6.07,
            
        
    
        
        
            
                "description": "Alan Turing",
            
        
    
        
        
            
                "base_nightly_rate": 3.76,
            
        
    
        
        
            
                "base_monthly_rate": 3.37,
            
        
    
        
        
            
                "minimum_stay_nights": 2,
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
    },
    
];



const UnitsData = [
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "unit_number": "Ada Lovelace",
            
        
    
        
        
            
                "floor": "Ada Lovelace",
            
        
    
        
        
            
                "status": "maintenance",
            
        
    
        
        
            
                "max_occupancy_override": 4,
            
        
    
        
        
            
                "notes": "Marie Curie",
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
    },
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "unit_number": "Grace Hopper",
            
        
    
        
        
            
                "floor": "Alan Turing",
            
        
    
        
        
            
                "status": "reserved",
            
        
    
        
        
            
                "max_occupancy_override": 5,
            
        
    
        
        
            
                "notes": "Ada Lovelace",
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
    },
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "unit_number": "Alan Turing",
            
        
    
        
        
            
                "floor": "Alan Turing",
            
        
    
        
        
            
                "status": "maintenance",
            
        
    
        
        
            
                "max_occupancy_override": 1,
            
        
    
        
        
            
                "notes": "Ada Lovelace",
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
    },
    
];



const UnitAvailabilityBlocksData = [
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "block_type": "owner_hold",
            
        
    
        
        
            
                "start_at": new Date(Date.now()),
            
        
    
        
        
            
                "end_at": new Date(Date.now()),
            
        
    
        
        
            
                "reason": "Marie Curie",
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
    },
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "block_type": "reservation_hold",
            
        
    
        
        
            
                "start_at": new Date(Date.now()),
            
        
    
        
        
            
                "end_at": new Date(Date.now()),
            
        
    
        
        
            
                "reason": "Alan Turing",
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
    },
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "block_type": "owner_hold",
            
        
    
        
        
            
                "start_at": new Date(Date.now()),
            
        
    
        
        
            
                "end_at": new Date(Date.now()),
            
        
    
        
        
            
                "reason": "Ada Lovelace",
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
    },
    
];



const NegotiatedRatesData = [
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "rate_type": "monthly",
            
        
    
        
        
            
                "rate_amount": 2.05,
            
        
    
        
        
            
                "valid_from": new Date(Date.now()),
            
        
    
        
        
            
                "valid_until": new Date(Date.now()),
            
        
    
        
        
            
                "minimum_stay_nights": 4,
            
        
    
        
        
            
                "is_active": true,
            
        
    
        
        
            
                "notes": "Alan Turing",
            
        
    
    },
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "rate_type": "monthly",
            
        
    
        
        
            
                "rate_amount": 9.15,
            
        
    
        
        
            
                "valid_from": new Date(Date.now()),
            
        
    
        
        
            
                "valid_until": new Date(Date.now()),
            
        
    
        
        
            
                "minimum_stay_nights": 5,
            
        
    
        
        
            
                "is_active": true,
            
        
    
        
        
            
                "notes": "Marie Curie",
            
        
    
    },
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "rate_type": "nightly",
            
        
    
        
        
            
                "rate_amount": 3.27,
            
        
    
        
        
            
                "valid_from": new Date(Date.now()),
            
        
    
        
        
            
                "valid_until": new Date(Date.now()),
            
        
    
        
        
            
                "minimum_stay_nights": 7,
            
        
    
        
        
            
                "is_active": false,
            
        
    
        
        
            
                "notes": "Ada Lovelace",
            
        
    
    },
    
];



const BookingRequestsData = [
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "request_code": "Alan Turing",
            
        
    
        
        
            
                "status": "converted_to_reservation",
            
        
    
        
        
            
                "check_in_at": new Date(Date.now()),
            
        
    
        
        
            
                "check_out_at": new Date(Date.now()),
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "preferred_bedrooms": 7,
            
        
    
        
        
            
                "guest_count": 9,
            
        
    
        
        
            
                "purpose_of_stay": "Alan Turing",
            
        
    
        
        
            
                "special_requirements": "Grace Hopper",
            
        
    
        
        
            
                "budget_code": "Alan Turing",
            
        
    
        
        
            
                "max_budget_amount": 0.77,
            
        
    
        
        
            
                "currency": "Ada Lovelace",
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
    },
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "request_code": "Alan Turing",
            
        
    
        
        
            
                "status": "expired",
            
        
    
        
        
            
                "check_in_at": new Date(Date.now()),
            
        
    
        
        
            
                "check_out_at": new Date(Date.now()),
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "preferred_bedrooms": 3,
            
        
    
        
        
            
                "guest_count": 5,
            
        
    
        
        
            
                "purpose_of_stay": "Alan Turing",
            
        
    
        
        
            
                "special_requirements": "Ada Lovelace",
            
        
    
        
        
            
                "budget_code": "Marie Curie",
            
        
    
        
        
            
                "max_budget_amount": 7.28,
            
        
    
        
        
            
                "currency": "Marie Curie",
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
    },
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "request_code": "Marie Curie",
            
        
    
        
        
            
                "status": "canceled",
            
        
    
        
        
            
                "check_in_at": new Date(Date.now()),
            
        
    
        
        
            
                "check_out_at": new Date(Date.now()),
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "preferred_bedrooms": 5,
            
        
    
        
        
            
                "guest_count": 2,
            
        
    
        
        
            
                "purpose_of_stay": "Ada Lovelace",
            
        
    
        
        
            
                "special_requirements": "Alan Turing",
            
        
    
        
        
            
                "budget_code": "Grace Hopper",
            
        
    
        
        
            
                "max_budget_amount": 7.3,
            
        
    
        
        
            
                "currency": "Ada Lovelace",
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
    },
    
];



const BookingRequestTravelersData = [
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "full_name": "Marie Curie",
            
        
    
        
        
            
                "email": "Ada Lovelace",
            
        
    
        
        
            
                "phone": "Marie Curie",
            
        
    
        
        
            
                "nationality": "Alan Turing",
            
        
    
        
        
            
                "passport_number": "Grace Hopper",
            
        
    
        
        
            
                "date_of_birth": new Date(Date.now()),
            
        
    
        
        
            
                "primary_traveler": false,
            
        
    
        
        
            
                "notes": "Marie Curie",
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
    },
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "full_name": "Marie Curie",
            
        
    
        
        
            
                "email": "Grace Hopper",
            
        
    
        
        
            
                "phone": "Ada Lovelace",
            
        
    
        
        
            
                "nationality": "Marie Curie",
            
        
    
        
        
            
                "passport_number": "Alan Turing",
            
        
    
        
        
            
                "date_of_birth": new Date(Date.now()),
            
        
    
        
        
            
                "primary_traveler": true,
            
        
    
        
        
            
                "notes": "Marie Curie",
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
    },
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "full_name": "Ada Lovelace",
            
        
    
        
        
            
                "email": "Grace Hopper",
            
        
    
        
        
            
                "phone": "Grace Hopper",
            
        
    
        
        
            
                "nationality": "Alan Turing",
            
        
    
        
        
            
                "passport_number": "Marie Curie",
            
        
    
        
        
            
                "date_of_birth": new Date(Date.now()),
            
        
    
        
        
            
                "primary_traveler": true,
            
        
    
        
        
            
                "notes": "Grace Hopper",
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
    },
    
];



const ApprovalStepsData = [
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "step_order": 5,
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "decision": "changes_requested",
            
        
    
        
        
            
                "decided_at": new Date(Date.now()),
            
        
    
        
        
            
                "decision_notes": "Alan Turing",
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
    },
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "step_order": 4,
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "decision": "pending",
            
        
    
        
        
            
                "decided_at": new Date(Date.now()),
            
        
    
        
        
            
                "decision_notes": "Grace Hopper",
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
    },
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "step_order": 3,
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "decision": "pending",
            
        
    
        
        
            
                "decided_at": new Date(Date.now()),
            
        
    
        
        
            
                "decision_notes": "Alan Turing",
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
    },
    
];



const ReservationsData = [
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "reservation_code": "Grace Hopper",
            
        
    
        
        
            
                "status": "checked_in",
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "check_in_at": new Date(Date.now()),
            
        
    
        
        
            
                "check_out_at": new Date(Date.now()),
            
        
    
        
        
            
                "actual_check_in_at": new Date(Date.now()),
            
        
    
        
        
            
                "actual_check_out_at": new Date(Date.now()),
            
        
    
        
        
            
                "early_check_in": true,
            
        
    
        
        
            
                "late_check_out": false,
            
        
    
        
        
            
                "guest_count": 6,
            
        
    
        
        
            
                "nightly_rate": 8.51,
            
        
    
        
        
            
                "monthly_rate": 3.56,
            
        
    
        
        
            
                "currency": "Grace Hopper",
            
        
    
        
        
            
                "internal_notes": "Alan Turing",
            
        
    
        
        
            
                "external_notes": "Alan Turing",
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
    },
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "reservation_code": "Marie Curie",
            
        
    
        
        
            
                "status": "quoted",
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "check_in_at": new Date(Date.now()),
            
        
    
        
        
            
                "check_out_at": new Date(Date.now()),
            
        
    
        
        
            
                "actual_check_in_at": new Date(Date.now()),
            
        
    
        
        
            
                "actual_check_out_at": new Date(Date.now()),
            
        
    
        
        
            
                "early_check_in": false,
            
        
    
        
        
            
                "late_check_out": true,
            
        
    
        
        
            
                "guest_count": 5,
            
        
    
        
        
            
                "nightly_rate": 5.21,
            
        
    
        
        
            
                "monthly_rate": 7.95,
            
        
    
        
        
            
                "currency": "Grace Hopper",
            
        
    
        
        
            
                "internal_notes": "Alan Turing",
            
        
    
        
        
            
                "external_notes": "Ada Lovelace",
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
    },
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "reservation_code": "Ada Lovelace",
            
        
    
        
        
            
                "status": "canceled",
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "check_in_at": new Date(Date.now()),
            
        
    
        
        
            
                "check_out_at": new Date(Date.now()),
            
        
    
        
        
            
                "actual_check_in_at": new Date(Date.now()),
            
        
    
        
        
            
                "actual_check_out_at": new Date(Date.now()),
            
        
    
        
        
            
                "early_check_in": true,
            
        
    
        
        
            
                "late_check_out": false,
            
        
    
        
        
            
                "guest_count": 5,
            
        
    
        
        
            
                "nightly_rate": 6.38,
            
        
    
        
        
            
                "monthly_rate": 4.4,
            
        
    
        
        
            
                "currency": "Alan Turing",
            
        
    
        
        
            
                "internal_notes": "Grace Hopper",
            
        
    
        
        
            
                "external_notes": "Alan Turing",
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
    },
    
];



const ReservationGuestsData = [
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "full_name": "Alan Turing",
            
        
    
        
        
            
                "email": "Ada Lovelace",
            
        
    
        
        
            
                "phone": "Marie Curie",
            
        
    
        
        
            
                "guest_type": "additional_guest",
            
        
    
        
        
            
                "primary_guest": false,
            
        
    
        
        
            
                "notes": "Grace Hopper",
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
    },
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "full_name": "Grace Hopper",
            
        
    
        
        
            
                "email": "Alan Turing",
            
        
    
        
        
            
                "phone": "Grace Hopper",
            
        
    
        
        
            
                "guest_type": "vip",
            
        
    
        
        
            
                "primary_guest": true,
            
        
    
        
        
            
                "notes": "Marie Curie",
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
    },
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "full_name": "Ada Lovelace",
            
        
    
        
        
            
                "email": "Ada Lovelace",
            
        
    
        
        
            
                "phone": "Grace Hopper",
            
        
    
        
        
            
                "guest_type": "vip",
            
        
    
        
        
            
                "primary_guest": true,
            
        
    
        
        
            
                "notes": "Marie Curie",
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
    },
    
];



const ServiceRequestsData = [
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "request_type": "maintenance",
            
        
    
        
        
            
                "status": "in_progress",
            
        
    
        
        
            
                "priority": "normal",
            
        
    
        
        
            
                "requested_at": new Date(Date.now()),
            
        
    
        
        
            
                "due_at": new Date(Date.now()),
            
        
    
        
        
            
                "completed_at": new Date(Date.now()),
            
        
    
        
        
            
                "summary": "Alan Turing",
            
        
    
        
        
            
                "details": "Ada Lovelace",
            
        
    
        
        
            
                "estimated_cost": 4.35,
            
        
    
        
        
            
                "actual_cost": 0.25,
            
        
    
        
        
            
                "currency": "Alan Turing",
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
    },
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "request_type": "late_checkout",
            
        
    
        
        
            
                "status": "new",
            
        
    
        
        
            
                "priority": "urgent",
            
        
    
        
        
            
                "requested_at": new Date(Date.now()),
            
        
    
        
        
            
                "due_at": new Date(Date.now()),
            
        
    
        
        
            
                "completed_at": new Date(Date.now()),
            
        
    
        
        
            
                "summary": "Ada Lovelace",
            
        
    
        
        
            
                "details": "Alan Turing",
            
        
    
        
        
            
                "estimated_cost": 2.6,
            
        
    
        
        
            
                "actual_cost": 4.16,
            
        
    
        
        
            
                "currency": "Grace Hopper",
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
    },
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "request_type": "extension",
            
        
    
        
        
            
                "status": "completed",
            
        
    
        
        
            
                "priority": "high",
            
        
    
        
        
            
                "requested_at": new Date(Date.now()),
            
        
    
        
        
            
                "due_at": new Date(Date.now()),
            
        
    
        
        
            
                "completed_at": new Date(Date.now()),
            
        
    
        
        
            
                "summary": "Ada Lovelace",
            
        
    
        
        
            
                "details": "Ada Lovelace",
            
        
    
        
        
            
                "estimated_cost": 2.5,
            
        
    
        
        
            
                "actual_cost": 4.38,
            
        
    
        
        
            
                "currency": "Grace Hopper",
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
    },
    
];



const InvoicesData = [
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "invoice_number": "Alan Turing",
            
        
    
        
        
            
                "status": "partially_paid",
            
        
    
        
        
            
                "issued_at": new Date(Date.now()),
            
        
    
        
        
            
                "due_at": new Date(Date.now()),
            
        
    
        
        
            
                "subtotal_amount": 6.14,
            
        
    
        
        
            
                "tax_amount": 6.68,
            
        
    
        
        
            
                "total_amount": 6.53,
            
        
    
        
        
            
                "balance_due": 4.13,
            
        
    
        
        
            
                "currency": "Grace Hopper",
            
        
    
        
        
            
                "bill_to_name": "Grace Hopper",
            
        
    
        
        
            
                "bill_to_address": "Alan Turing",
            
        
    
        
        
            
                "notes": "Marie Curie",
            
        
    
        
        
            
                // type code here for "files" field
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
    },
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "invoice_number": "Ada Lovelace",
            
        
    
        
        
            
                "status": "issued",
            
        
    
        
        
            
                "issued_at": new Date(Date.now()),
            
        
    
        
        
            
                "due_at": new Date(Date.now()),
            
        
    
        
        
            
                "subtotal_amount": 0.29,
            
        
    
        
        
            
                "tax_amount": 7.66,
            
        
    
        
        
            
                "total_amount": 6.1,
            
        
    
        
        
            
                "balance_due": 9.24,
            
        
    
        
        
            
                "currency": "Alan Turing",
            
        
    
        
        
            
                "bill_to_name": "Alan Turing",
            
        
    
        
        
            
                "bill_to_address": "Alan Turing",
            
        
    
        
        
            
                "notes": "Marie Curie",
            
        
    
        
        
            
                // type code here for "files" field
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
    },
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "invoice_number": "Grace Hopper",
            
        
    
        
        
            
                "status": "partially_paid",
            
        
    
        
        
            
                "issued_at": new Date(Date.now()),
            
        
    
        
        
            
                "due_at": new Date(Date.now()),
            
        
    
        
        
            
                "subtotal_amount": 2.86,
            
        
    
        
        
            
                "tax_amount": 5.24,
            
        
    
        
        
            
                "total_amount": 5.02,
            
        
    
        
        
            
                "balance_due": 4.32,
            
        
    
        
        
            
                "currency": "Alan Turing",
            
        
    
        
        
            
                "bill_to_name": "Alan Turing",
            
        
    
        
        
            
                "bill_to_address": "Alan Turing",
            
        
    
        
        
            
                "notes": "Grace Hopper",
            
        
    
        
        
            
                // type code here for "files" field
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
    },
    
];



const InvoiceLineItemsData = [
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "line_type": "cleaning",
            
        
    
        
        
            
                "description": "Ada Lovelace",
            
        
    
        
        
            
                "quantity": 1,
            
        
    
        
        
            
                "unit_price": 9.07,
            
        
    
        
        
            
                "amount": 7.1,
            
        
    
        
        
            
                "service_period": "Grace Hopper",
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
    },
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "line_type": "cleaning",
            
        
    
        
        
            
                "description": "Alan Turing",
            
        
    
        
        
            
                "quantity": 7,
            
        
    
        
        
            
                "unit_price": 5.62,
            
        
    
        
        
            
                "amount": 3.46,
            
        
    
        
        
            
                "service_period": "Ada Lovelace",
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
    },
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "line_type": "add_on",
            
        
    
        
        
            
                "description": "Marie Curie",
            
        
    
        
        
            
                "quantity": 4,
            
        
    
        
        
            
                "unit_price": 7.8,
            
        
    
        
        
            
                "amount": 6.95,
            
        
    
        
        
            
                "service_period": "Ada Lovelace",
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
    },
    
];



const PaymentsData = [
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "payment_method": "other",
            
        
    
        
        
            
                "status": "pending",
            
        
    
        
        
            
                "amount": 9.41,
            
        
    
        
        
            
                "currency": "Grace Hopper",
            
        
    
        
        
            
                "paid_at": new Date(Date.now()),
            
        
    
        
        
            
                "reference": "Ada Lovelace",
            
        
    
        
        
            
                "notes": "Ada Lovelace",
            
        
    
        
        
            
                // type code here for "files" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
    },
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "payment_method": "credit_note",
            
        
    
        
        
            
                "status": "reversed",
            
        
    
        
        
            
                "amount": 3.65,
            
        
    
        
        
            
                "currency": "Marie Curie",
            
        
    
        
        
            
                "paid_at": new Date(Date.now()),
            
        
    
        
        
            
                "reference": "Ada Lovelace",
            
        
    
        
        
            
                "notes": "Marie Curie",
            
        
    
        
        
            
                // type code here for "files" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
    },
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "payment_method": "other",
            
        
    
        
        
            
                "status": "failed",
            
        
    
        
        
            
                "amount": 8.24,
            
        
    
        
        
            
                "currency": "Ada Lovelace",
            
        
    
        
        
            
                "paid_at": new Date(Date.now()),
            
        
    
        
        
            
                "reference": "Grace Hopper",
            
        
    
        
        
            
                "notes": "Marie Curie",
            
        
    
        
        
            
                // type code here for "files" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
    },
    
];



const DocumentsData = [
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "document_type": "inspection_report",
            
        
    
        
        
            
                "file_name": "Marie Curie",
            
        
    
        
        
            
                "mime_type": "Alan Turing",
            
        
    
        
        
            
                "file_size_bytes": 9,
            
        
    
        
        
            
                "storage_key": "Ada Lovelace",
            
        
    
        
        
            
                "public_url": "Alan Turing",
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "notes": "Grace Hopper",
            
        
    
        
        
            
                "is_private": true,
            
        
    
    },
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "document_type": "invoice_pdf",
            
        
    
        
        
            
                "file_name": "Marie Curie",
            
        
    
        
        
            
                "mime_type": "Grace Hopper",
            
        
    
        
        
            
                "file_size_bytes": 7,
            
        
    
        
        
            
                "storage_key": "Ada Lovelace",
            
        
    
        
        
            
                "public_url": "Alan Turing",
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "notes": "Marie Curie",
            
        
    
        
        
            
                "is_private": true,
            
        
    
    },
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "document_type": "inspection_report",
            
        
    
        
        
            
                "file_name": "Marie Curie",
            
        
    
        
        
            
                "mime_type": "Marie Curie",
            
        
    
        
        
            
                "file_size_bytes": 2,
            
        
    
        
        
            
                "storage_key": "Ada Lovelace",
            
        
    
        
        
            
                "public_url": "Marie Curie",
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "notes": "Alan Turing",
            
        
    
        
        
            
                "is_private": true,
            
        
    
    },
    
];



const AuditLogsData = [
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "action": "Grace Hopper",
            
        
    
        
        
            
                "entity_name": "Grace Hopper",
            
        
    
        
        
            
                "entity_reference": "Ada Lovelace",
            
        
    
        
        
            
                "ip_address": "Grace Hopper",
            
        
    
        
        
            
                "user_agent": "Marie Curie",
            
        
    
        
        
            
                "occurred_at": new Date(Date.now()),
            
        
    
        
        
            
                "metadata_json": "Ada Lovelace",
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
    },
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "action": "Ada Lovelace",
            
        
    
        
        
            
                "entity_name": "Ada Lovelace",
            
        
    
        
        
            
                "entity_reference": "Ada Lovelace",
            
        
    
        
        
            
                "ip_address": "Alan Turing",
            
        
    
        
        
            
                "user_agent": "Alan Turing",
            
        
    
        
        
            
                "occurred_at": new Date(Date.now()),
            
        
    
        
        
            
                "metadata_json": "Ada Lovelace",
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
    },
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "action": "Marie Curie",
            
        
    
        
        
            
                "entity_name": "Grace Hopper",
            
        
    
        
        
            
                "entity_reference": "Grace Hopper",
            
        
    
        
        
            
                "ip_address": "Alan Turing",
            
        
    
        
        
            
                "user_agent": "Alan Turing",
            
        
    
        
        
            
                "occurred_at": new Date(Date.now()),
            
        
    
        
        
            
                "metadata_json": "Marie Curie",
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
    },
    
];



const NotificationsData = [
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "channel": "email",
            
        
    
        
        
            
                "type": "system",
            
        
    
        
        
            
                "title": "Marie Curie",
            
        
    
        
        
            
                "body": "Alan Turing",
            
        
    
        
        
            
                "link_url": "Alan Turing",
            
        
    
        
        
            
                "sent_at": new Date(Date.now()),
            
        
    
        
        
            
                "read_at": new Date(Date.now()),
            
        
    
        
        
            
                "is_read": false,
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
    },
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "channel": "in_app",
            
        
    
        
        
            
                "type": "comment_mention",
            
        
    
        
        
            
                "title": "Ada Lovelace",
            
        
    
        
        
            
                "body": "Marie Curie",
            
        
    
        
        
            
                "link_url": "Ada Lovelace",
            
        
    
        
        
            
                "sent_at": new Date(Date.now()),
            
        
    
        
        
            
                "read_at": new Date(Date.now()),
            
        
    
        
        
            
                "is_read": false,
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
    },
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "channel": "in_app",
            
        
    
        
        
            
                "type": "upcoming_check_out",
            
        
    
        
        
            
                "title": "Grace Hopper",
            
        
    
        
        
            
                "body": "Grace Hopper",
            
        
    
        
        
            
                "link_url": "Grace Hopper",
            
        
    
        
        
            
                "sent_at": new Date(Date.now()),
            
        
    
        
        
            
                "read_at": new Date(Date.now()),
            
        
    
        
        
            
                "is_read": true,
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
    },
    
];



const ActivityCommentsData = [
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "visibility": "external",
            
        
    
        
        
            
                "body": "Marie Curie",
            
        
    
        
        
            
                "posted_at": new Date(Date.now()),
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
    },
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "visibility": "external",
            
        
    
        
        
            
                "body": "Marie Curie",
            
        
    
        
        
            
                "posted_at": new Date(Date.now()),
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
    },
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "visibility": "internal",
            
        
    
        
        
            
                "body": "Ada Lovelace",
            
        
    
        
        
            
                "posted_at": new Date(Date.now()),
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
    },
    
];



const ChecklistsData = [
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "checklist_type": "pre_arrival",
            
        
    
        
        
            
                "status": "in_progress",
            
        
    
        
        
            
                "due_at": new Date(Date.now()),
            
        
    
        
        
            
                "completed_at": new Date(Date.now()),
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
        
        
            
                "notes": "Grace Hopper",
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
    },
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "checklist_type": "pre_arrival",
            
        
    
        
        
            
                "status": "not_started",
            
        
    
        
        
            
                "due_at": new Date(Date.now()),
            
        
    
        
        
            
                "completed_at": new Date(Date.now()),
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
        
        
            
                "notes": "Marie Curie",
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
    },
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "checklist_type": "check_in",
            
        
    
        
        
            
                "status": "completed",
            
        
    
        
        
            
                "due_at": new Date(Date.now()),
            
        
    
        
        
            
                "completed_at": new Date(Date.now()),
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                // type code here for "relation_many" field
            
        
    
        
        
            
                "notes": "Marie Curie",
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
    },
    
];



const ChecklistItemsData = [
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "title": "Ada Lovelace",
            
        
    
        
        
            
                "is_done": true,
            
        
    
        
        
            
                "done_at": new Date(Date.now()),
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "sort_order": 6,
            
        
    
        
        
            
                "notes": "Grace Hopper",
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
    },
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "title": "Marie Curie",
            
        
    
        
        
            
                "is_done": false,
            
        
    
        
        
            
                "done_at": new Date(Date.now()),
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "sort_order": 7,
            
        
    
        
        
            
                "notes": "Grace Hopper",
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
    },
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "title": "Alan Turing",
            
        
    
        
        
            
                "is_done": false,
            
        
    
        
        
            
                "done_at": new Date(Date.now()),
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "sort_order": 8,
            
        
    
        
        
            
                "notes": "Grace Hopper",
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
    },
    
];



const JobRunsData = [
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "job_type": "system_cleanup",
            
        
    
        
        
            
                "status": "running",
            
        
    
        
        
            
                "scheduled_for": new Date(Date.now()),
            
        
    
        
        
            
                "started_at": new Date(Date.now()),
            
        
    
        
        
            
                "finished_at": new Date(Date.now()),
            
        
    
        
        
            
                "attempt_count": 5,
            
        
    
        
        
            
                "last_error": "Ada Lovelace",
            
        
    
        
        
            
                "payload_json": "Marie Curie",
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
    },
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "job_type": "upcoming_check_in_reminder",
            
        
    
        
        
            
                "status": "failed",
            
        
    
        
        
            
                "scheduled_for": new Date(Date.now()),
            
        
    
        
        
            
                "started_at": new Date(Date.now()),
            
        
    
        
        
            
                "finished_at": new Date(Date.now()),
            
        
    
        
        
            
                "attempt_count": 7,
            
        
    
        
        
            
                "last_error": "Alan Turing",
            
        
    
        
        
            
                "payload_json": "Ada Lovelace",
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
    },
    
    {
    
        
        
            
                // type code here for "relation_one" field
            
        
    
        
        
            
                "job_type": "system_cleanup",
            
        
    
        
        
            
                "status": "queued",
            
        
    
        
        
            
                "scheduled_for": new Date(Date.now()),
            
        
    
        
        
            
                "started_at": new Date(Date.now()),
            
        
    
        
        
            
                "finished_at": new Date(Date.now()),
            
        
    
        
        
            
                "attempt_count": 1,
            
        
    
        
        
            
                "last_error": "Marie Curie",
            
        
    
        
        
            
                "payload_json": "Grace Hopper",
            
        
    
        
        
            
                // type code here for "relation_one" field
            
        
    
    },
    
];




    
    
    
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
            // Similar logic for "relation_many"
        
    
        
            
            async function associateUserWithOrganization() {
            
                const relatedOrganization0 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const User0 = await Users.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (User0?.setOrganization)
                {
                    await
                    User0.
                    setOrganization(relatedOrganization0);
                }
            
                const relatedOrganization1 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const User1 = await Users.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (User1?.setOrganization)
                {
                    await
                    User1.
                    setOrganization(relatedOrganization1);
                }
            
                const relatedOrganization2 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const User2 = await Users.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (User2?.setOrganization)
                {
                    await
                    User2.
                    setOrganization(relatedOrganization2);
                }
            
        }
        
    

    
    
    
    
    
        
    

    
    
    
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
            // Similar logic for "relation_many"
        
    
        
            // Similar logic for "relation_many"
        
    
        
            // Similar logic for "relation_many"
        
    

    
    
    
        
            
            async function associateRoleAssignmentWithUser() {
            
                const relatedUser0 = await Users.findOne({
                    offset: Math.floor(Math.random() * (await Users.count())),
                });
                const RoleAssignment0 = await RoleAssignments.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (RoleAssignment0?.setUser)
                {
                    await
                    RoleAssignment0.
                    setUser(relatedUser0);
                }
            
                const relatedUser1 = await Users.findOne({
                    offset: Math.floor(Math.random() * (await Users.count())),
                });
                const RoleAssignment1 = await RoleAssignments.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (RoleAssignment1?.setUser)
                {
                    await
                    RoleAssignment1.
                    setUser(relatedUser1);
                }
            
                const relatedUser2 = await Users.findOne({
                    offset: Math.floor(Math.random() * (await Users.count())),
                });
                const RoleAssignment2 = await RoleAssignments.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (RoleAssignment2?.setUser)
                {
                    await
                    RoleAssignment2.
                    setUser(relatedUser2);
                }
            
        }
        
    
        
    
        
            
            async function associateRoleAssignmentWithTenant() {
            
                const relatedTenant0 = await Tenants.findOne({
                    offset: Math.floor(Math.random() * (await Tenants.count())),
                });
                const RoleAssignment0 = await RoleAssignments.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (RoleAssignment0?.setTenant)
                {
                    await
                    RoleAssignment0.
                    setTenant(relatedTenant0);
                }
            
                const relatedTenant1 = await Tenants.findOne({
                    offset: Math.floor(Math.random() * (await Tenants.count())),
                });
                const RoleAssignment1 = await RoleAssignments.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (RoleAssignment1?.setTenant)
                {
                    await
                    RoleAssignment1.
                    setTenant(relatedTenant1);
                }
            
                const relatedTenant2 = await Tenants.findOne({
                    offset: Math.floor(Math.random() * (await Tenants.count())),
                });
                const RoleAssignment2 = await RoleAssignments.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (RoleAssignment2?.setTenant)
                {
                    await
                    RoleAssignment2.
                    setTenant(relatedTenant2);
                }
            
        }
        
    
        
            
            async function associateRoleAssignmentWithOrganization() {
            
                const relatedOrganization0 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const RoleAssignment0 = await RoleAssignments.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (RoleAssignment0?.setOrganization)
                {
                    await
                    RoleAssignment0.
                    setOrganization(relatedOrganization0);
                }
            
                const relatedOrganization1 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const RoleAssignment1 = await RoleAssignments.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (RoleAssignment1?.setOrganization)
                {
                    await
                    RoleAssignment1.
                    setOrganization(relatedOrganization1);
                }
            
                const relatedOrganization2 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const RoleAssignment2 = await RoleAssignments.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (RoleAssignment2?.setOrganization)
                {
                    await
                    RoleAssignment2.
                    setOrganization(relatedOrganization2);
                }
            
        }
        
    
        
    
        
    
        
    

    
    
    
        
            
            async function associateOrganizationMembershipWithOrganization() {
            
                const relatedOrganization0 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const OrganizationMembership0 = await OrganizationMemberships.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (OrganizationMembership0?.setOrganization)
                {
                    await
                    OrganizationMembership0.
                    setOrganization(relatedOrganization0);
                }
            
                const relatedOrganization1 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const OrganizationMembership1 = await OrganizationMemberships.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (OrganizationMembership1?.setOrganization)
                {
                    await
                    OrganizationMembership1.
                    setOrganization(relatedOrganization1);
                }
            
                const relatedOrganization2 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const OrganizationMembership2 = await OrganizationMemberships.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (OrganizationMembership2?.setOrganization)
                {
                    await
                    OrganizationMembership2.
                    setOrganization(relatedOrganization2);
                }
            
        }
        
    
        
            
            async function associateOrganizationMembershipWithUser() {
            
                const relatedUser0 = await Users.findOne({
                    offset: Math.floor(Math.random() * (await Users.count())),
                });
                const OrganizationMembership0 = await OrganizationMemberships.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (OrganizationMembership0?.setUser)
                {
                    await
                    OrganizationMembership0.
                    setUser(relatedUser0);
                }
            
                const relatedUser1 = await Users.findOne({
                    offset: Math.floor(Math.random() * (await Users.count())),
                });
                const OrganizationMembership1 = await OrganizationMemberships.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (OrganizationMembership1?.setUser)
                {
                    await
                    OrganizationMembership1.
                    setUser(relatedUser1);
                }
            
                const relatedUser2 = await Users.findOne({
                    offset: Math.floor(Math.random() * (await Users.count())),
                });
                const OrganizationMembership2 = await OrganizationMemberships.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (OrganizationMembership2?.setUser)
                {
                    await
                    OrganizationMembership2.
                    setUser(relatedUser2);
                }
            
        }
        
    
        
    
        
    
        
    
        
    
        
    

    
    
    
        
            
            async function associatePropertyWithTenant() {
            
                const relatedTenant0 = await Tenants.findOne({
                    offset: Math.floor(Math.random() * (await Tenants.count())),
                });
                const Property0 = await Properties.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (Property0?.setTenant)
                {
                    await
                    Property0.
                    setTenant(relatedTenant0);
                }
            
                const relatedTenant1 = await Tenants.findOne({
                    offset: Math.floor(Math.random() * (await Tenants.count())),
                });
                const Property1 = await Properties.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (Property1?.setTenant)
                {
                    await
                    Property1.
                    setTenant(relatedTenant1);
                }
            
                const relatedTenant2 = await Tenants.findOne({
                    offset: Math.floor(Math.random() * (await Tenants.count())),
                });
                const Property2 = await Properties.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (Property2?.setTenant)
                {
                    await
                    Property2.
                    setTenant(relatedTenant2);
                }
            
        }
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
            // Similar logic for "relation_many"
        
    
        
            // Similar logic for "relation_many"
        
    
        
            // Similar logic for "relation_many"
        
    
        
            
            async function associatePropertyWithOrganization() {
            
                const relatedOrganization0 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const Property0 = await Properties.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (Property0?.setOrganization)
                {
                    await
                    Property0.
                    setOrganization(relatedOrganization0);
                }
            
                const relatedOrganization1 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const Property1 = await Properties.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (Property1?.setOrganization)
                {
                    await
                    Property1.
                    setOrganization(relatedOrganization1);
                }
            
                const relatedOrganization2 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const Property2 = await Properties.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (Property2?.setOrganization)
                {
                    await
                    Property2.
                    setOrganization(relatedOrganization2);
                }
            
        }
        
    

    
    
    
        
            
            async function associateAmenityWithProperty() {
            
                const relatedProperty0 = await Properties.findOne({
                    offset: Math.floor(Math.random() * (await Properties.count())),
                });
                const Amenity0 = await Amenities.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (Amenity0?.setProperty)
                {
                    await
                    Amenity0.
                    setProperty(relatedProperty0);
                }
            
                const relatedProperty1 = await Properties.findOne({
                    offset: Math.floor(Math.random() * (await Properties.count())),
                });
                const Amenity1 = await Amenities.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (Amenity1?.setProperty)
                {
                    await
                    Amenity1.
                    setProperty(relatedProperty1);
                }
            
                const relatedProperty2 = await Properties.findOne({
                    offset: Math.floor(Math.random() * (await Properties.count())),
                });
                const Amenity2 = await Amenities.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (Amenity2?.setProperty)
                {
                    await
                    Amenity2.
                    setProperty(relatedProperty2);
                }
            
        }
        
    
        
    
        
    
        
            
            async function associateAmenityWithOrganization() {
            
                const relatedOrganization0 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const Amenity0 = await Amenities.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (Amenity0?.setOrganization)
                {
                    await
                    Amenity0.
                    setOrganization(relatedOrganization0);
                }
            
                const relatedOrganization1 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const Amenity1 = await Amenities.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (Amenity1?.setOrganization)
                {
                    await
                    Amenity1.
                    setOrganization(relatedOrganization1);
                }
            
                const relatedOrganization2 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const Amenity2 = await Amenities.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (Amenity2?.setOrganization)
                {
                    await
                    Amenity2.
                    setOrganization(relatedOrganization2);
                }
            
        }
        
    

    
    
    
        
            
            async function associateUnitTypeWithProperty() {
            
                const relatedProperty0 = await Properties.findOne({
                    offset: Math.floor(Math.random() * (await Properties.count())),
                });
                const UnitType0 = await UnitTypes.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (UnitType0?.setProperty)
                {
                    await
                    UnitType0.
                    setProperty(relatedProperty0);
                }
            
                const relatedProperty1 = await Properties.findOne({
                    offset: Math.floor(Math.random() * (await Properties.count())),
                });
                const UnitType1 = await UnitTypes.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (UnitType1?.setProperty)
                {
                    await
                    UnitType1.
                    setProperty(relatedProperty1);
                }
            
                const relatedProperty2 = await Properties.findOne({
                    offset: Math.floor(Math.random() * (await Properties.count())),
                });
                const UnitType2 = await UnitTypes.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (UnitType2?.setProperty)
                {
                    await
                    UnitType2.
                    setProperty(relatedProperty2);
                }
            
        }
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
            // Similar logic for "relation_many"
        
    
        
            
            async function associateUnitTypeWithOrganization() {
            
                const relatedOrganization0 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const UnitType0 = await UnitTypes.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (UnitType0?.setOrganization)
                {
                    await
                    UnitType0.
                    setOrganization(relatedOrganization0);
                }
            
                const relatedOrganization1 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const UnitType1 = await UnitTypes.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (UnitType1?.setOrganization)
                {
                    await
                    UnitType1.
                    setOrganization(relatedOrganization1);
                }
            
                const relatedOrganization2 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const UnitType2 = await UnitTypes.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (UnitType2?.setOrganization)
                {
                    await
                    UnitType2.
                    setOrganization(relatedOrganization2);
                }
            
        }
        
    

    
    
    
        
            
            async function associateUnitWithProperty() {
            
                const relatedProperty0 = await Properties.findOne({
                    offset: Math.floor(Math.random() * (await Properties.count())),
                });
                const Unit0 = await Units.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (Unit0?.setProperty)
                {
                    await
                    Unit0.
                    setProperty(relatedProperty0);
                }
            
                const relatedProperty1 = await Properties.findOne({
                    offset: Math.floor(Math.random() * (await Properties.count())),
                });
                const Unit1 = await Units.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (Unit1?.setProperty)
                {
                    await
                    Unit1.
                    setProperty(relatedProperty1);
                }
            
                const relatedProperty2 = await Properties.findOne({
                    offset: Math.floor(Math.random() * (await Properties.count())),
                });
                const Unit2 = await Units.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (Unit2?.setProperty)
                {
                    await
                    Unit2.
                    setProperty(relatedProperty2);
                }
            
        }
        
    
        
            
            async function associateUnitWithUnit_type() {
            
                const relatedUnit_type0 = await UnitTypes.findOne({
                    offset: Math.floor(Math.random() * (await UnitTypes.count())),
                });
                const Unit0 = await Units.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (Unit0?.setUnit_type)
                {
                    await
                    Unit0.
                    setUnit_type(relatedUnit_type0);
                }
            
                const relatedUnit_type1 = await UnitTypes.findOne({
                    offset: Math.floor(Math.random() * (await UnitTypes.count())),
                });
                const Unit1 = await Units.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (Unit1?.setUnit_type)
                {
                    await
                    Unit1.
                    setUnit_type(relatedUnit_type1);
                }
            
                const relatedUnit_type2 = await UnitTypes.findOne({
                    offset: Math.floor(Math.random() * (await UnitTypes.count())),
                });
                const Unit2 = await Units.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (Unit2?.setUnit_type)
                {
                    await
                    Unit2.
                    setUnit_type(relatedUnit_type2);
                }
            
        }
        
    
        
    
        
    
        
    
        
    
        
    
        
            // Similar logic for "relation_many"
        
    
        
            
            async function associateUnitWithOrganization() {
            
                const relatedOrganization0 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const Unit0 = await Units.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (Unit0?.setOrganization)
                {
                    await
                    Unit0.
                    setOrganization(relatedOrganization0);
                }
            
                const relatedOrganization1 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const Unit1 = await Units.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (Unit1?.setOrganization)
                {
                    await
                    Unit1.
                    setOrganization(relatedOrganization1);
                }
            
                const relatedOrganization2 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const Unit2 = await Units.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (Unit2?.setOrganization)
                {
                    await
                    Unit2.
                    setOrganization(relatedOrganization2);
                }
            
        }
        
    

    
    
    
        
            
            async function associateUnitAvailabilityBlockWithUnit() {
            
                const relatedUnit0 = await Units.findOne({
                    offset: Math.floor(Math.random() * (await Units.count())),
                });
                const UnitAvailabilityBlock0 = await UnitAvailabilityBlocks.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (UnitAvailabilityBlock0?.setUnit)
                {
                    await
                    UnitAvailabilityBlock0.
                    setUnit(relatedUnit0);
                }
            
                const relatedUnit1 = await Units.findOne({
                    offset: Math.floor(Math.random() * (await Units.count())),
                });
                const UnitAvailabilityBlock1 = await UnitAvailabilityBlocks.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (UnitAvailabilityBlock1?.setUnit)
                {
                    await
                    UnitAvailabilityBlock1.
                    setUnit(relatedUnit1);
                }
            
                const relatedUnit2 = await Units.findOne({
                    offset: Math.floor(Math.random() * (await Units.count())),
                });
                const UnitAvailabilityBlock2 = await UnitAvailabilityBlocks.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (UnitAvailabilityBlock2?.setUnit)
                {
                    await
                    UnitAvailabilityBlock2.
                    setUnit(relatedUnit2);
                }
            
        }
        
    
        
    
        
    
        
    
        
    
        
            
            async function associateUnitAvailabilityBlockWithReservation() {
            
                const relatedReservation0 = await Reservations.findOne({
                    offset: Math.floor(Math.random() * (await Reservations.count())),
                });
                const UnitAvailabilityBlock0 = await UnitAvailabilityBlocks.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (UnitAvailabilityBlock0?.setReservation)
                {
                    await
                    UnitAvailabilityBlock0.
                    setReservation(relatedReservation0);
                }
            
                const relatedReservation1 = await Reservations.findOne({
                    offset: Math.floor(Math.random() * (await Reservations.count())),
                });
                const UnitAvailabilityBlock1 = await UnitAvailabilityBlocks.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (UnitAvailabilityBlock1?.setReservation)
                {
                    await
                    UnitAvailabilityBlock1.
                    setReservation(relatedReservation1);
                }
            
                const relatedReservation2 = await Reservations.findOne({
                    offset: Math.floor(Math.random() * (await Reservations.count())),
                });
                const UnitAvailabilityBlock2 = await UnitAvailabilityBlocks.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (UnitAvailabilityBlock2?.setReservation)
                {
                    await
                    UnitAvailabilityBlock2.
                    setReservation(relatedReservation2);
                }
            
        }
        
    
        
            
            async function associateUnitAvailabilityBlockWithOrganization() {
            
                const relatedOrganization0 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const UnitAvailabilityBlock0 = await UnitAvailabilityBlocks.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (UnitAvailabilityBlock0?.setOrganization)
                {
                    await
                    UnitAvailabilityBlock0.
                    setOrganization(relatedOrganization0);
                }
            
                const relatedOrganization1 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const UnitAvailabilityBlock1 = await UnitAvailabilityBlocks.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (UnitAvailabilityBlock1?.setOrganization)
                {
                    await
                    UnitAvailabilityBlock1.
                    setOrganization(relatedOrganization1);
                }
            
                const relatedOrganization2 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const UnitAvailabilityBlock2 = await UnitAvailabilityBlocks.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (UnitAvailabilityBlock2?.setOrganization)
                {
                    await
                    UnitAvailabilityBlock2.
                    setOrganization(relatedOrganization2);
                }
            
        }
        
    

    
    
    
        
            
            async function associateNegotiatedRateWithOrganization() {
            
                const relatedOrganization0 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const NegotiatedRate0 = await NegotiatedRates.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (NegotiatedRate0?.setOrganization)
                {
                    await
                    NegotiatedRate0.
                    setOrganization(relatedOrganization0);
                }
            
                const relatedOrganization1 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const NegotiatedRate1 = await NegotiatedRates.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (NegotiatedRate1?.setOrganization)
                {
                    await
                    NegotiatedRate1.
                    setOrganization(relatedOrganization1);
                }
            
                const relatedOrganization2 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const NegotiatedRate2 = await NegotiatedRates.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (NegotiatedRate2?.setOrganization)
                {
                    await
                    NegotiatedRate2.
                    setOrganization(relatedOrganization2);
                }
            
        }
        
    
        
            
            async function associateNegotiatedRateWithProperty() {
            
                const relatedProperty0 = await Properties.findOne({
                    offset: Math.floor(Math.random() * (await Properties.count())),
                });
                const NegotiatedRate0 = await NegotiatedRates.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (NegotiatedRate0?.setProperty)
                {
                    await
                    NegotiatedRate0.
                    setProperty(relatedProperty0);
                }
            
                const relatedProperty1 = await Properties.findOne({
                    offset: Math.floor(Math.random() * (await Properties.count())),
                });
                const NegotiatedRate1 = await NegotiatedRates.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (NegotiatedRate1?.setProperty)
                {
                    await
                    NegotiatedRate1.
                    setProperty(relatedProperty1);
                }
            
                const relatedProperty2 = await Properties.findOne({
                    offset: Math.floor(Math.random() * (await Properties.count())),
                });
                const NegotiatedRate2 = await NegotiatedRates.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (NegotiatedRate2?.setProperty)
                {
                    await
                    NegotiatedRate2.
                    setProperty(relatedProperty2);
                }
            
        }
        
    
        
            
            async function associateNegotiatedRateWithUnit_type() {
            
                const relatedUnit_type0 = await UnitTypes.findOne({
                    offset: Math.floor(Math.random() * (await UnitTypes.count())),
                });
                const NegotiatedRate0 = await NegotiatedRates.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (NegotiatedRate0?.setUnit_type)
                {
                    await
                    NegotiatedRate0.
                    setUnit_type(relatedUnit_type0);
                }
            
                const relatedUnit_type1 = await UnitTypes.findOne({
                    offset: Math.floor(Math.random() * (await UnitTypes.count())),
                });
                const NegotiatedRate1 = await NegotiatedRates.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (NegotiatedRate1?.setUnit_type)
                {
                    await
                    NegotiatedRate1.
                    setUnit_type(relatedUnit_type1);
                }
            
                const relatedUnit_type2 = await UnitTypes.findOne({
                    offset: Math.floor(Math.random() * (await UnitTypes.count())),
                });
                const NegotiatedRate2 = await NegotiatedRates.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (NegotiatedRate2?.setUnit_type)
                {
                    await
                    NegotiatedRate2.
                    setUnit_type(relatedUnit_type2);
                }
            
        }
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
    

    
    
    
        
            
            async function associateBookingRequestWithTenant() {
            
                const relatedTenant0 = await Tenants.findOne({
                    offset: Math.floor(Math.random() * (await Tenants.count())),
                });
                const BookingRequest0 = await BookingRequests.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (BookingRequest0?.setTenant)
                {
                    await
                    BookingRequest0.
                    setTenant(relatedTenant0);
                }
            
                const relatedTenant1 = await Tenants.findOne({
                    offset: Math.floor(Math.random() * (await Tenants.count())),
                });
                const BookingRequest1 = await BookingRequests.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (BookingRequest1?.setTenant)
                {
                    await
                    BookingRequest1.
                    setTenant(relatedTenant1);
                }
            
                const relatedTenant2 = await Tenants.findOne({
                    offset: Math.floor(Math.random() * (await Tenants.count())),
                });
                const BookingRequest2 = await BookingRequests.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (BookingRequest2?.setTenant)
                {
                    await
                    BookingRequest2.
                    setTenant(relatedTenant2);
                }
            
        }
        
    
        
            
            async function associateBookingRequestWithOrganization() {
            
                const relatedOrganization0 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const BookingRequest0 = await BookingRequests.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (BookingRequest0?.setOrganization)
                {
                    await
                    BookingRequest0.
                    setOrganization(relatedOrganization0);
                }
            
                const relatedOrganization1 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const BookingRequest1 = await BookingRequests.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (BookingRequest1?.setOrganization)
                {
                    await
                    BookingRequest1.
                    setOrganization(relatedOrganization1);
                }
            
                const relatedOrganization2 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const BookingRequest2 = await BookingRequests.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (BookingRequest2?.setOrganization)
                {
                    await
                    BookingRequest2.
                    setOrganization(relatedOrganization2);
                }
            
        }
        
    
        
            
            async function associateBookingRequestWithRequested_by() {
            
                const relatedRequested_by0 = await Users.findOne({
                    offset: Math.floor(Math.random() * (await Users.count())),
                });
                const BookingRequest0 = await BookingRequests.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (BookingRequest0?.setRequested_by)
                {
                    await
                    BookingRequest0.
                    setRequested_by(relatedRequested_by0);
                }
            
                const relatedRequested_by1 = await Users.findOne({
                    offset: Math.floor(Math.random() * (await Users.count())),
                });
                const BookingRequest1 = await BookingRequests.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (BookingRequest1?.setRequested_by)
                {
                    await
                    BookingRequest1.
                    setRequested_by(relatedRequested_by1);
                }
            
                const relatedRequested_by2 = await Users.findOne({
                    offset: Math.floor(Math.random() * (await Users.count())),
                });
                const BookingRequest2 = await BookingRequests.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (BookingRequest2?.setRequested_by)
                {
                    await
                    BookingRequest2.
                    setRequested_by(relatedRequested_by2);
                }
            
        }
        
    
        
    
        
    
        
    
        
    
        
            
            async function associateBookingRequestWithPreferred_property() {
            
                const relatedPreferred_property0 = await Properties.findOne({
                    offset: Math.floor(Math.random() * (await Properties.count())),
                });
                const BookingRequest0 = await BookingRequests.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (BookingRequest0?.setPreferred_property)
                {
                    await
                    BookingRequest0.
                    setPreferred_property(relatedPreferred_property0);
                }
            
                const relatedPreferred_property1 = await Properties.findOne({
                    offset: Math.floor(Math.random() * (await Properties.count())),
                });
                const BookingRequest1 = await BookingRequests.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (BookingRequest1?.setPreferred_property)
                {
                    await
                    BookingRequest1.
                    setPreferred_property(relatedPreferred_property1);
                }
            
                const relatedPreferred_property2 = await Properties.findOne({
                    offset: Math.floor(Math.random() * (await Properties.count())),
                });
                const BookingRequest2 = await BookingRequests.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (BookingRequest2?.setPreferred_property)
                {
                    await
                    BookingRequest2.
                    setPreferred_property(relatedPreferred_property2);
                }
            
        }
        
    
        
            
            async function associateBookingRequestWithPreferred_unit_type() {
            
                const relatedPreferred_unit_type0 = await UnitTypes.findOne({
                    offset: Math.floor(Math.random() * (await UnitTypes.count())),
                });
                const BookingRequest0 = await BookingRequests.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (BookingRequest0?.setPreferred_unit_type)
                {
                    await
                    BookingRequest0.
                    setPreferred_unit_type(relatedPreferred_unit_type0);
                }
            
                const relatedPreferred_unit_type1 = await UnitTypes.findOne({
                    offset: Math.floor(Math.random() * (await UnitTypes.count())),
                });
                const BookingRequest1 = await BookingRequests.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (BookingRequest1?.setPreferred_unit_type)
                {
                    await
                    BookingRequest1.
                    setPreferred_unit_type(relatedPreferred_unit_type1);
                }
            
                const relatedPreferred_unit_type2 = await UnitTypes.findOne({
                    offset: Math.floor(Math.random() * (await UnitTypes.count())),
                });
                const BookingRequest2 = await BookingRequests.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (BookingRequest2?.setPreferred_unit_type)
                {
                    await
                    BookingRequest2.
                    setPreferred_unit_type(relatedPreferred_unit_type2);
                }
            
        }
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
            // Similar logic for "relation_many"
        
    
        
            // Similar logic for "relation_many"
        
    
        
            // Similar logic for "relation_many"
        
    
        
            // Similar logic for "relation_many"
        
    

    
    
    
        
            
            async function associateBookingRequestTravelerWithBooking_request() {
            
                const relatedBooking_request0 = await BookingRequests.findOne({
                    offset: Math.floor(Math.random() * (await BookingRequests.count())),
                });
                const BookingRequestTraveler0 = await BookingRequestTravelers.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (BookingRequestTraveler0?.setBooking_request)
                {
                    await
                    BookingRequestTraveler0.
                    setBooking_request(relatedBooking_request0);
                }
            
                const relatedBooking_request1 = await BookingRequests.findOne({
                    offset: Math.floor(Math.random() * (await BookingRequests.count())),
                });
                const BookingRequestTraveler1 = await BookingRequestTravelers.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (BookingRequestTraveler1?.setBooking_request)
                {
                    await
                    BookingRequestTraveler1.
                    setBooking_request(relatedBooking_request1);
                }
            
                const relatedBooking_request2 = await BookingRequests.findOne({
                    offset: Math.floor(Math.random() * (await BookingRequests.count())),
                });
                const BookingRequestTraveler2 = await BookingRequestTravelers.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (BookingRequestTraveler2?.setBooking_request)
                {
                    await
                    BookingRequestTraveler2.
                    setBooking_request(relatedBooking_request2);
                }
            
        }
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
            
            async function associateBookingRequestTravelerWithOrganization() {
            
                const relatedOrganization0 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const BookingRequestTraveler0 = await BookingRequestTravelers.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (BookingRequestTraveler0?.setOrganization)
                {
                    await
                    BookingRequestTraveler0.
                    setOrganization(relatedOrganization0);
                }
            
                const relatedOrganization1 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const BookingRequestTraveler1 = await BookingRequestTravelers.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (BookingRequestTraveler1?.setOrganization)
                {
                    await
                    BookingRequestTraveler1.
                    setOrganization(relatedOrganization1);
                }
            
                const relatedOrganization2 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const BookingRequestTraveler2 = await BookingRequestTravelers.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (BookingRequestTraveler2?.setOrganization)
                {
                    await
                    BookingRequestTraveler2.
                    setOrganization(relatedOrganization2);
                }
            
        }
        
    

    
    
    
        
            
            async function associateApprovalStepWithBooking_request() {
            
                const relatedBooking_request0 = await BookingRequests.findOne({
                    offset: Math.floor(Math.random() * (await BookingRequests.count())),
                });
                const ApprovalStep0 = await ApprovalSteps.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (ApprovalStep0?.setBooking_request)
                {
                    await
                    ApprovalStep0.
                    setBooking_request(relatedBooking_request0);
                }
            
                const relatedBooking_request1 = await BookingRequests.findOne({
                    offset: Math.floor(Math.random() * (await BookingRequests.count())),
                });
                const ApprovalStep1 = await ApprovalSteps.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (ApprovalStep1?.setBooking_request)
                {
                    await
                    ApprovalStep1.
                    setBooking_request(relatedBooking_request1);
                }
            
                const relatedBooking_request2 = await BookingRequests.findOne({
                    offset: Math.floor(Math.random() * (await BookingRequests.count())),
                });
                const ApprovalStep2 = await ApprovalSteps.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (ApprovalStep2?.setBooking_request)
                {
                    await
                    ApprovalStep2.
                    setBooking_request(relatedBooking_request2);
                }
            
        }
        
    
        
    
        
            
            async function associateApprovalStepWithApprover() {
            
                const relatedApprover0 = await Users.findOne({
                    offset: Math.floor(Math.random() * (await Users.count())),
                });
                const ApprovalStep0 = await ApprovalSteps.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (ApprovalStep0?.setApprover)
                {
                    await
                    ApprovalStep0.
                    setApprover(relatedApprover0);
                }
            
                const relatedApprover1 = await Users.findOne({
                    offset: Math.floor(Math.random() * (await Users.count())),
                });
                const ApprovalStep1 = await ApprovalSteps.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (ApprovalStep1?.setApprover)
                {
                    await
                    ApprovalStep1.
                    setApprover(relatedApprover1);
                }
            
                const relatedApprover2 = await Users.findOne({
                    offset: Math.floor(Math.random() * (await Users.count())),
                });
                const ApprovalStep2 = await ApprovalSteps.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (ApprovalStep2?.setApprover)
                {
                    await
                    ApprovalStep2.
                    setApprover(relatedApprover2);
                }
            
        }
        
    
        
    
        
    
        
    
        
            
            async function associateApprovalStepWithOrganization() {
            
                const relatedOrganization0 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const ApprovalStep0 = await ApprovalSteps.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (ApprovalStep0?.setOrganization)
                {
                    await
                    ApprovalStep0.
                    setOrganization(relatedOrganization0);
                }
            
                const relatedOrganization1 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const ApprovalStep1 = await ApprovalSteps.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (ApprovalStep1?.setOrganization)
                {
                    await
                    ApprovalStep1.
                    setOrganization(relatedOrganization1);
                }
            
                const relatedOrganization2 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const ApprovalStep2 = await ApprovalSteps.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (ApprovalStep2?.setOrganization)
                {
                    await
                    ApprovalStep2.
                    setOrganization(relatedOrganization2);
                }
            
        }
        
    

    
    
    
        
            
            async function associateReservationWithTenant() {
            
                const relatedTenant0 = await Tenants.findOne({
                    offset: Math.floor(Math.random() * (await Tenants.count())),
                });
                const Reservation0 = await Reservations.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (Reservation0?.setTenant)
                {
                    await
                    Reservation0.
                    setTenant(relatedTenant0);
                }
            
                const relatedTenant1 = await Tenants.findOne({
                    offset: Math.floor(Math.random() * (await Tenants.count())),
                });
                const Reservation1 = await Reservations.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (Reservation1?.setTenant)
                {
                    await
                    Reservation1.
                    setTenant(relatedTenant1);
                }
            
                const relatedTenant2 = await Tenants.findOne({
                    offset: Math.floor(Math.random() * (await Tenants.count())),
                });
                const Reservation2 = await Reservations.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (Reservation2?.setTenant)
                {
                    await
                    Reservation2.
                    setTenant(relatedTenant2);
                }
            
        }
        
    
        
            
            async function associateReservationWithOrganization() {
            
                const relatedOrganization0 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const Reservation0 = await Reservations.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (Reservation0?.setOrganization)
                {
                    await
                    Reservation0.
                    setOrganization(relatedOrganization0);
                }
            
                const relatedOrganization1 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const Reservation1 = await Reservations.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (Reservation1?.setOrganization)
                {
                    await
                    Reservation1.
                    setOrganization(relatedOrganization1);
                }
            
                const relatedOrganization2 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const Reservation2 = await Reservations.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (Reservation2?.setOrganization)
                {
                    await
                    Reservation2.
                    setOrganization(relatedOrganization2);
                }
            
        }
        
    
        
            
            async function associateReservationWithBooking_request() {
            
                const relatedBooking_request0 = await BookingRequests.findOne({
                    offset: Math.floor(Math.random() * (await BookingRequests.count())),
                });
                const Reservation0 = await Reservations.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (Reservation0?.setBooking_request)
                {
                    await
                    Reservation0.
                    setBooking_request(relatedBooking_request0);
                }
            
                const relatedBooking_request1 = await BookingRequests.findOne({
                    offset: Math.floor(Math.random() * (await BookingRequests.count())),
                });
                const Reservation1 = await Reservations.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (Reservation1?.setBooking_request)
                {
                    await
                    Reservation1.
                    setBooking_request(relatedBooking_request1);
                }
            
                const relatedBooking_request2 = await BookingRequests.findOne({
                    offset: Math.floor(Math.random() * (await BookingRequests.count())),
                });
                const Reservation2 = await Reservations.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (Reservation2?.setBooking_request)
                {
                    await
                    Reservation2.
                    setBooking_request(relatedBooking_request2);
                }
            
        }
        
    
        
    
        
    
        
            
            async function associateReservationWithProperty() {
            
                const relatedProperty0 = await Properties.findOne({
                    offset: Math.floor(Math.random() * (await Properties.count())),
                });
                const Reservation0 = await Reservations.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (Reservation0?.setProperty)
                {
                    await
                    Reservation0.
                    setProperty(relatedProperty0);
                }
            
                const relatedProperty1 = await Properties.findOne({
                    offset: Math.floor(Math.random() * (await Properties.count())),
                });
                const Reservation1 = await Reservations.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (Reservation1?.setProperty)
                {
                    await
                    Reservation1.
                    setProperty(relatedProperty1);
                }
            
                const relatedProperty2 = await Properties.findOne({
                    offset: Math.floor(Math.random() * (await Properties.count())),
                });
                const Reservation2 = await Reservations.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (Reservation2?.setProperty)
                {
                    await
                    Reservation2.
                    setProperty(relatedProperty2);
                }
            
        }
        
    
        
            
            async function associateReservationWithUnit() {
            
                const relatedUnit0 = await Units.findOne({
                    offset: Math.floor(Math.random() * (await Units.count())),
                });
                const Reservation0 = await Reservations.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (Reservation0?.setUnit)
                {
                    await
                    Reservation0.
                    setUnit(relatedUnit0);
                }
            
                const relatedUnit1 = await Units.findOne({
                    offset: Math.floor(Math.random() * (await Units.count())),
                });
                const Reservation1 = await Reservations.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (Reservation1?.setUnit)
                {
                    await
                    Reservation1.
                    setUnit(relatedUnit1);
                }
            
                const relatedUnit2 = await Units.findOne({
                    offset: Math.floor(Math.random() * (await Units.count())),
                });
                const Reservation2 = await Reservations.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (Reservation2?.setUnit)
                {
                    await
                    Reservation2.
                    setUnit(relatedUnit2);
                }
            
        }
        
    
        
            
            async function associateReservationWithUnit_type() {
            
                const relatedUnit_type0 = await UnitTypes.findOne({
                    offset: Math.floor(Math.random() * (await UnitTypes.count())),
                });
                const Reservation0 = await Reservations.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (Reservation0?.setUnit_type)
                {
                    await
                    Reservation0.
                    setUnit_type(relatedUnit_type0);
                }
            
                const relatedUnit_type1 = await UnitTypes.findOne({
                    offset: Math.floor(Math.random() * (await UnitTypes.count())),
                });
                const Reservation1 = await Reservations.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (Reservation1?.setUnit_type)
                {
                    await
                    Reservation1.
                    setUnit_type(relatedUnit_type1);
                }
            
                const relatedUnit_type2 = await UnitTypes.findOne({
                    offset: Math.floor(Math.random() * (await UnitTypes.count())),
                });
                const Reservation2 = await Reservations.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (Reservation2?.setUnit_type)
                {
                    await
                    Reservation2.
                    setUnit_type(relatedUnit_type2);
                }
            
        }
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
            // Similar logic for "relation_many"
        
    
        
            // Similar logic for "relation_many"
        
    
        
            // Similar logic for "relation_many"
        
    
        
            // Similar logic for "relation_many"
        
    
        
            // Similar logic for "relation_many"
        
    

    
    
    
        
            
            async function associateReservationGuestWithReservation() {
            
                const relatedReservation0 = await Reservations.findOne({
                    offset: Math.floor(Math.random() * (await Reservations.count())),
                });
                const ReservationGuest0 = await ReservationGuests.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (ReservationGuest0?.setReservation)
                {
                    await
                    ReservationGuest0.
                    setReservation(relatedReservation0);
                }
            
                const relatedReservation1 = await Reservations.findOne({
                    offset: Math.floor(Math.random() * (await Reservations.count())),
                });
                const ReservationGuest1 = await ReservationGuests.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (ReservationGuest1?.setReservation)
                {
                    await
                    ReservationGuest1.
                    setReservation(relatedReservation1);
                }
            
                const relatedReservation2 = await Reservations.findOne({
                    offset: Math.floor(Math.random() * (await Reservations.count())),
                });
                const ReservationGuest2 = await ReservationGuests.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (ReservationGuest2?.setReservation)
                {
                    await
                    ReservationGuest2.
                    setReservation(relatedReservation2);
                }
            
        }
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
            
            async function associateReservationGuestWithOrganization() {
            
                const relatedOrganization0 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const ReservationGuest0 = await ReservationGuests.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (ReservationGuest0?.setOrganization)
                {
                    await
                    ReservationGuest0.
                    setOrganization(relatedOrganization0);
                }
            
                const relatedOrganization1 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const ReservationGuest1 = await ReservationGuests.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (ReservationGuest1?.setOrganization)
                {
                    await
                    ReservationGuest1.
                    setOrganization(relatedOrganization1);
                }
            
                const relatedOrganization2 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const ReservationGuest2 = await ReservationGuests.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (ReservationGuest2?.setOrganization)
                {
                    await
                    ReservationGuest2.
                    setOrganization(relatedOrganization2);
                }
            
        }
        
    

    
    
    
        
            
            async function associateServiceRequestWithTenant() {
            
                const relatedTenant0 = await Tenants.findOne({
                    offset: Math.floor(Math.random() * (await Tenants.count())),
                });
                const ServiceRequest0 = await ServiceRequests.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (ServiceRequest0?.setTenant)
                {
                    await
                    ServiceRequest0.
                    setTenant(relatedTenant0);
                }
            
                const relatedTenant1 = await Tenants.findOne({
                    offset: Math.floor(Math.random() * (await Tenants.count())),
                });
                const ServiceRequest1 = await ServiceRequests.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (ServiceRequest1?.setTenant)
                {
                    await
                    ServiceRequest1.
                    setTenant(relatedTenant1);
                }
            
                const relatedTenant2 = await Tenants.findOne({
                    offset: Math.floor(Math.random() * (await Tenants.count())),
                });
                const ServiceRequest2 = await ServiceRequests.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (ServiceRequest2?.setTenant)
                {
                    await
                    ServiceRequest2.
                    setTenant(relatedTenant2);
                }
            
        }
        
    
        
            
            async function associateServiceRequestWithReservation() {
            
                const relatedReservation0 = await Reservations.findOne({
                    offset: Math.floor(Math.random() * (await Reservations.count())),
                });
                const ServiceRequest0 = await ServiceRequests.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (ServiceRequest0?.setReservation)
                {
                    await
                    ServiceRequest0.
                    setReservation(relatedReservation0);
                }
            
                const relatedReservation1 = await Reservations.findOne({
                    offset: Math.floor(Math.random() * (await Reservations.count())),
                });
                const ServiceRequest1 = await ServiceRequests.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (ServiceRequest1?.setReservation)
                {
                    await
                    ServiceRequest1.
                    setReservation(relatedReservation1);
                }
            
                const relatedReservation2 = await Reservations.findOne({
                    offset: Math.floor(Math.random() * (await Reservations.count())),
                });
                const ServiceRequest2 = await ServiceRequests.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (ServiceRequest2?.setReservation)
                {
                    await
                    ServiceRequest2.
                    setReservation(relatedReservation2);
                }
            
        }
        
    
        
            
            async function associateServiceRequestWithRequested_by() {
            
                const relatedRequested_by0 = await Users.findOne({
                    offset: Math.floor(Math.random() * (await Users.count())),
                });
                const ServiceRequest0 = await ServiceRequests.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (ServiceRequest0?.setRequested_by)
                {
                    await
                    ServiceRequest0.
                    setRequested_by(relatedRequested_by0);
                }
            
                const relatedRequested_by1 = await Users.findOne({
                    offset: Math.floor(Math.random() * (await Users.count())),
                });
                const ServiceRequest1 = await ServiceRequests.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (ServiceRequest1?.setRequested_by)
                {
                    await
                    ServiceRequest1.
                    setRequested_by(relatedRequested_by1);
                }
            
                const relatedRequested_by2 = await Users.findOne({
                    offset: Math.floor(Math.random() * (await Users.count())),
                });
                const ServiceRequest2 = await ServiceRequests.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (ServiceRequest2?.setRequested_by)
                {
                    await
                    ServiceRequest2.
                    setRequested_by(relatedRequested_by2);
                }
            
        }
        
    
        
            
            async function associateServiceRequestWithAssigned_to() {
            
                const relatedAssigned_to0 = await Users.findOne({
                    offset: Math.floor(Math.random() * (await Users.count())),
                });
                const ServiceRequest0 = await ServiceRequests.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (ServiceRequest0?.setAssigned_to)
                {
                    await
                    ServiceRequest0.
                    setAssigned_to(relatedAssigned_to0);
                }
            
                const relatedAssigned_to1 = await Users.findOne({
                    offset: Math.floor(Math.random() * (await Users.count())),
                });
                const ServiceRequest1 = await ServiceRequests.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (ServiceRequest1?.setAssigned_to)
                {
                    await
                    ServiceRequest1.
                    setAssigned_to(relatedAssigned_to1);
                }
            
                const relatedAssigned_to2 = await Users.findOne({
                    offset: Math.floor(Math.random() * (await Users.count())),
                });
                const ServiceRequest2 = await ServiceRequests.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (ServiceRequest2?.setAssigned_to)
                {
                    await
                    ServiceRequest2.
                    setAssigned_to(relatedAssigned_to2);
                }
            
        }
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
            // Similar logic for "relation_many"
        
    
        
            // Similar logic for "relation_many"
        
    
        
            
            async function associateServiceRequestWithOrganization() {
            
                const relatedOrganization0 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const ServiceRequest0 = await ServiceRequests.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (ServiceRequest0?.setOrganization)
                {
                    await
                    ServiceRequest0.
                    setOrganization(relatedOrganization0);
                }
            
                const relatedOrganization1 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const ServiceRequest1 = await ServiceRequests.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (ServiceRequest1?.setOrganization)
                {
                    await
                    ServiceRequest1.
                    setOrganization(relatedOrganization1);
                }
            
                const relatedOrganization2 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const ServiceRequest2 = await ServiceRequests.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (ServiceRequest2?.setOrganization)
                {
                    await
                    ServiceRequest2.
                    setOrganization(relatedOrganization2);
                }
            
        }
        
    

    
    
    
        
            
            async function associateInvoiceWithTenant() {
            
                const relatedTenant0 = await Tenants.findOne({
                    offset: Math.floor(Math.random() * (await Tenants.count())),
                });
                const Invoice0 = await Invoices.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (Invoice0?.setTenant)
                {
                    await
                    Invoice0.
                    setTenant(relatedTenant0);
                }
            
                const relatedTenant1 = await Tenants.findOne({
                    offset: Math.floor(Math.random() * (await Tenants.count())),
                });
                const Invoice1 = await Invoices.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (Invoice1?.setTenant)
                {
                    await
                    Invoice1.
                    setTenant(relatedTenant1);
                }
            
                const relatedTenant2 = await Tenants.findOne({
                    offset: Math.floor(Math.random() * (await Tenants.count())),
                });
                const Invoice2 = await Invoices.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (Invoice2?.setTenant)
                {
                    await
                    Invoice2.
                    setTenant(relatedTenant2);
                }
            
        }
        
    
        
            
            async function associateInvoiceWithOrganization() {
            
                const relatedOrganization0 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const Invoice0 = await Invoices.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (Invoice0?.setOrganization)
                {
                    await
                    Invoice0.
                    setOrganization(relatedOrganization0);
                }
            
                const relatedOrganization1 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const Invoice1 = await Invoices.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (Invoice1?.setOrganization)
                {
                    await
                    Invoice1.
                    setOrganization(relatedOrganization1);
                }
            
                const relatedOrganization2 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const Invoice2 = await Invoices.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (Invoice2?.setOrganization)
                {
                    await
                    Invoice2.
                    setOrganization(relatedOrganization2);
                }
            
        }
        
    
        
            
            async function associateInvoiceWithReservation() {
            
                const relatedReservation0 = await Reservations.findOne({
                    offset: Math.floor(Math.random() * (await Reservations.count())),
                });
                const Invoice0 = await Invoices.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (Invoice0?.setReservation)
                {
                    await
                    Invoice0.
                    setReservation(relatedReservation0);
                }
            
                const relatedReservation1 = await Reservations.findOne({
                    offset: Math.floor(Math.random() * (await Reservations.count())),
                });
                const Invoice1 = await Invoices.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (Invoice1?.setReservation)
                {
                    await
                    Invoice1.
                    setReservation(relatedReservation1);
                }
            
                const relatedReservation2 = await Reservations.findOne({
                    offset: Math.floor(Math.random() * (await Reservations.count())),
                });
                const Invoice2 = await Invoices.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (Invoice2?.setReservation)
                {
                    await
                    Invoice2.
                    setReservation(relatedReservation2);
                }
            
        }
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
            // Similar logic for "relation_many"
        
    
        
            // Similar logic for "relation_many"
        
    
        
            // Similar logic for "relation_many"
        
    

    
    
    
        
            
            async function associateInvoiceLineItemWithInvoice() {
            
                const relatedInvoice0 = await Invoices.findOne({
                    offset: Math.floor(Math.random() * (await Invoices.count())),
                });
                const InvoiceLineItem0 = await InvoiceLineItems.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (InvoiceLineItem0?.setInvoice)
                {
                    await
                    InvoiceLineItem0.
                    setInvoice(relatedInvoice0);
                }
            
                const relatedInvoice1 = await Invoices.findOne({
                    offset: Math.floor(Math.random() * (await Invoices.count())),
                });
                const InvoiceLineItem1 = await InvoiceLineItems.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (InvoiceLineItem1?.setInvoice)
                {
                    await
                    InvoiceLineItem1.
                    setInvoice(relatedInvoice1);
                }
            
                const relatedInvoice2 = await Invoices.findOne({
                    offset: Math.floor(Math.random() * (await Invoices.count())),
                });
                const InvoiceLineItem2 = await InvoiceLineItems.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (InvoiceLineItem2?.setInvoice)
                {
                    await
                    InvoiceLineItem2.
                    setInvoice(relatedInvoice2);
                }
            
        }
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
            
            async function associateInvoiceLineItemWithOrganization() {
            
                const relatedOrganization0 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const InvoiceLineItem0 = await InvoiceLineItems.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (InvoiceLineItem0?.setOrganization)
                {
                    await
                    InvoiceLineItem0.
                    setOrganization(relatedOrganization0);
                }
            
                const relatedOrganization1 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const InvoiceLineItem1 = await InvoiceLineItems.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (InvoiceLineItem1?.setOrganization)
                {
                    await
                    InvoiceLineItem1.
                    setOrganization(relatedOrganization1);
                }
            
                const relatedOrganization2 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const InvoiceLineItem2 = await InvoiceLineItems.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (InvoiceLineItem2?.setOrganization)
                {
                    await
                    InvoiceLineItem2.
                    setOrganization(relatedOrganization2);
                }
            
        }
        
    

    
    
    
        
            
            async function associatePaymentWithInvoice() {
            
                const relatedInvoice0 = await Invoices.findOne({
                    offset: Math.floor(Math.random() * (await Invoices.count())),
                });
                const Payment0 = await Payments.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (Payment0?.setInvoice)
                {
                    await
                    Payment0.
                    setInvoice(relatedInvoice0);
                }
            
                const relatedInvoice1 = await Invoices.findOne({
                    offset: Math.floor(Math.random() * (await Invoices.count())),
                });
                const Payment1 = await Payments.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (Payment1?.setInvoice)
                {
                    await
                    Payment1.
                    setInvoice(relatedInvoice1);
                }
            
                const relatedInvoice2 = await Invoices.findOne({
                    offset: Math.floor(Math.random() * (await Invoices.count())),
                });
                const Payment2 = await Payments.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (Payment2?.setInvoice)
                {
                    await
                    Payment2.
                    setInvoice(relatedInvoice2);
                }
            
        }
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
            
            async function associatePaymentWithOrganization() {
            
                const relatedOrganization0 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const Payment0 = await Payments.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (Payment0?.setOrganization)
                {
                    await
                    Payment0.
                    setOrganization(relatedOrganization0);
                }
            
                const relatedOrganization1 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const Payment1 = await Payments.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (Payment1?.setOrganization)
                {
                    await
                    Payment1.
                    setOrganization(relatedOrganization1);
                }
            
                const relatedOrganization2 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const Payment2 = await Payments.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (Payment2?.setOrganization)
                {
                    await
                    Payment2.
                    setOrganization(relatedOrganization2);
                }
            
        }
        
    

    
    
    
        
            
            async function associateDocumentWithTenant() {
            
                const relatedTenant0 = await Tenants.findOne({
                    offset: Math.floor(Math.random() * (await Tenants.count())),
                });
                const Document0 = await Documents.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (Document0?.setTenant)
                {
                    await
                    Document0.
                    setTenant(relatedTenant0);
                }
            
                const relatedTenant1 = await Tenants.findOne({
                    offset: Math.floor(Math.random() * (await Tenants.count())),
                });
                const Document1 = await Documents.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (Document1?.setTenant)
                {
                    await
                    Document1.
                    setTenant(relatedTenant1);
                }
            
                const relatedTenant2 = await Tenants.findOne({
                    offset: Math.floor(Math.random() * (await Tenants.count())),
                });
                const Document2 = await Documents.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (Document2?.setTenant)
                {
                    await
                    Document2.
                    setTenant(relatedTenant2);
                }
            
        }
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
            
            async function associateDocumentWithUploaded_by() {
            
                const relatedUploaded_by0 = await Users.findOne({
                    offset: Math.floor(Math.random() * (await Users.count())),
                });
                const Document0 = await Documents.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (Document0?.setUploaded_by)
                {
                    await
                    Document0.
                    setUploaded_by(relatedUploaded_by0);
                }
            
                const relatedUploaded_by1 = await Users.findOne({
                    offset: Math.floor(Math.random() * (await Users.count())),
                });
                const Document1 = await Documents.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (Document1?.setUploaded_by)
                {
                    await
                    Document1.
                    setUploaded_by(relatedUploaded_by1);
                }
            
                const relatedUploaded_by2 = await Users.findOne({
                    offset: Math.floor(Math.random() * (await Users.count())),
                });
                const Document2 = await Documents.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (Document2?.setUploaded_by)
                {
                    await
                    Document2.
                    setUploaded_by(relatedUploaded_by2);
                }
            
        }
        
    
        
            
            async function associateDocumentWithOrganization() {
            
                const relatedOrganization0 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const Document0 = await Documents.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (Document0?.setOrganization)
                {
                    await
                    Document0.
                    setOrganization(relatedOrganization0);
                }
            
                const relatedOrganization1 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const Document1 = await Documents.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (Document1?.setOrganization)
                {
                    await
                    Document1.
                    setOrganization(relatedOrganization1);
                }
            
                const relatedOrganization2 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const Document2 = await Documents.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (Document2?.setOrganization)
                {
                    await
                    Document2.
                    setOrganization(relatedOrganization2);
                }
            
        }
        
    
        
            
            async function associateDocumentWithBooking_request() {
            
                const relatedBooking_request0 = await BookingRequests.findOne({
                    offset: Math.floor(Math.random() * (await BookingRequests.count())),
                });
                const Document0 = await Documents.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (Document0?.setBooking_request)
                {
                    await
                    Document0.
                    setBooking_request(relatedBooking_request0);
                }
            
                const relatedBooking_request1 = await BookingRequests.findOne({
                    offset: Math.floor(Math.random() * (await BookingRequests.count())),
                });
                const Document1 = await Documents.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (Document1?.setBooking_request)
                {
                    await
                    Document1.
                    setBooking_request(relatedBooking_request1);
                }
            
                const relatedBooking_request2 = await BookingRequests.findOne({
                    offset: Math.floor(Math.random() * (await BookingRequests.count())),
                });
                const Document2 = await Documents.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (Document2?.setBooking_request)
                {
                    await
                    Document2.
                    setBooking_request(relatedBooking_request2);
                }
            
        }
        
    
        
            
            async function associateDocumentWithReservation() {
            
                const relatedReservation0 = await Reservations.findOne({
                    offset: Math.floor(Math.random() * (await Reservations.count())),
                });
                const Document0 = await Documents.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (Document0?.setReservation)
                {
                    await
                    Document0.
                    setReservation(relatedReservation0);
                }
            
                const relatedReservation1 = await Reservations.findOne({
                    offset: Math.floor(Math.random() * (await Reservations.count())),
                });
                const Document1 = await Documents.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (Document1?.setReservation)
                {
                    await
                    Document1.
                    setReservation(relatedReservation1);
                }
            
                const relatedReservation2 = await Reservations.findOne({
                    offset: Math.floor(Math.random() * (await Reservations.count())),
                });
                const Document2 = await Documents.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (Document2?.setReservation)
                {
                    await
                    Document2.
                    setReservation(relatedReservation2);
                }
            
        }
        
    
        
            
            async function associateDocumentWithService_request() {
            
                const relatedService_request0 = await ServiceRequests.findOne({
                    offset: Math.floor(Math.random() * (await ServiceRequests.count())),
                });
                const Document0 = await Documents.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (Document0?.setService_request)
                {
                    await
                    Document0.
                    setService_request(relatedService_request0);
                }
            
                const relatedService_request1 = await ServiceRequests.findOne({
                    offset: Math.floor(Math.random() * (await ServiceRequests.count())),
                });
                const Document1 = await Documents.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (Document1?.setService_request)
                {
                    await
                    Document1.
                    setService_request(relatedService_request1);
                }
            
                const relatedService_request2 = await ServiceRequests.findOne({
                    offset: Math.floor(Math.random() * (await ServiceRequests.count())),
                });
                const Document2 = await Documents.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (Document2?.setService_request)
                {
                    await
                    Document2.
                    setService_request(relatedService_request2);
                }
            
        }
        
    
        
            
            async function associateDocumentWithInvoice() {
            
                const relatedInvoice0 = await Invoices.findOne({
                    offset: Math.floor(Math.random() * (await Invoices.count())),
                });
                const Document0 = await Documents.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (Document0?.setInvoice)
                {
                    await
                    Document0.
                    setInvoice(relatedInvoice0);
                }
            
                const relatedInvoice1 = await Invoices.findOne({
                    offset: Math.floor(Math.random() * (await Invoices.count())),
                });
                const Document1 = await Documents.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (Document1?.setInvoice)
                {
                    await
                    Document1.
                    setInvoice(relatedInvoice1);
                }
            
                const relatedInvoice2 = await Invoices.findOne({
                    offset: Math.floor(Math.random() * (await Invoices.count())),
                });
                const Document2 = await Documents.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (Document2?.setInvoice)
                {
                    await
                    Document2.
                    setInvoice(relatedInvoice2);
                }
            
        }
        
    
        
    
        
    

    
    
    
        
            
            async function associateAuditLogWithTenant() {
            
                const relatedTenant0 = await Tenants.findOne({
                    offset: Math.floor(Math.random() * (await Tenants.count())),
                });
                const AuditLog0 = await AuditLogs.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (AuditLog0?.setTenant)
                {
                    await
                    AuditLog0.
                    setTenant(relatedTenant0);
                }
            
                const relatedTenant1 = await Tenants.findOne({
                    offset: Math.floor(Math.random() * (await Tenants.count())),
                });
                const AuditLog1 = await AuditLogs.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (AuditLog1?.setTenant)
                {
                    await
                    AuditLog1.
                    setTenant(relatedTenant1);
                }
            
                const relatedTenant2 = await Tenants.findOne({
                    offset: Math.floor(Math.random() * (await Tenants.count())),
                });
                const AuditLog2 = await AuditLogs.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (AuditLog2?.setTenant)
                {
                    await
                    AuditLog2.
                    setTenant(relatedTenant2);
                }
            
        }
        
    
        
            
            async function associateAuditLogWithActor() {
            
                const relatedActor0 = await Users.findOne({
                    offset: Math.floor(Math.random() * (await Users.count())),
                });
                const AuditLog0 = await AuditLogs.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (AuditLog0?.setActor)
                {
                    await
                    AuditLog0.
                    setActor(relatedActor0);
                }
            
                const relatedActor1 = await Users.findOne({
                    offset: Math.floor(Math.random() * (await Users.count())),
                });
                const AuditLog1 = await AuditLogs.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (AuditLog1?.setActor)
                {
                    await
                    AuditLog1.
                    setActor(relatedActor1);
                }
            
                const relatedActor2 = await Users.findOne({
                    offset: Math.floor(Math.random() * (await Users.count())),
                });
                const AuditLog2 = await AuditLogs.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (AuditLog2?.setActor)
                {
                    await
                    AuditLog2.
                    setActor(relatedActor2);
                }
            
        }
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
            
            async function associateAuditLogWithOrganization() {
            
                const relatedOrganization0 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const AuditLog0 = await AuditLogs.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (AuditLog0?.setOrganization)
                {
                    await
                    AuditLog0.
                    setOrganization(relatedOrganization0);
                }
            
                const relatedOrganization1 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const AuditLog1 = await AuditLogs.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (AuditLog1?.setOrganization)
                {
                    await
                    AuditLog1.
                    setOrganization(relatedOrganization1);
                }
            
                const relatedOrganization2 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const AuditLog2 = await AuditLogs.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (AuditLog2?.setOrganization)
                {
                    await
                    AuditLog2.
                    setOrganization(relatedOrganization2);
                }
            
        }
        
    

    
    
    
        
            
            async function associateNotificationWithTenant() {
            
                const relatedTenant0 = await Tenants.findOne({
                    offset: Math.floor(Math.random() * (await Tenants.count())),
                });
                const Notification0 = await Notifications.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (Notification0?.setTenant)
                {
                    await
                    Notification0.
                    setTenant(relatedTenant0);
                }
            
                const relatedTenant1 = await Tenants.findOne({
                    offset: Math.floor(Math.random() * (await Tenants.count())),
                });
                const Notification1 = await Notifications.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (Notification1?.setTenant)
                {
                    await
                    Notification1.
                    setTenant(relatedTenant1);
                }
            
                const relatedTenant2 = await Tenants.findOne({
                    offset: Math.floor(Math.random() * (await Tenants.count())),
                });
                const Notification2 = await Notifications.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (Notification2?.setTenant)
                {
                    await
                    Notification2.
                    setTenant(relatedTenant2);
                }
            
        }
        
    
        
            
            async function associateNotificationWithUser() {
            
                const relatedUser0 = await Users.findOne({
                    offset: Math.floor(Math.random() * (await Users.count())),
                });
                const Notification0 = await Notifications.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (Notification0?.setUser)
                {
                    await
                    Notification0.
                    setUser(relatedUser0);
                }
            
                const relatedUser1 = await Users.findOne({
                    offset: Math.floor(Math.random() * (await Users.count())),
                });
                const Notification1 = await Notifications.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (Notification1?.setUser)
                {
                    await
                    Notification1.
                    setUser(relatedUser1);
                }
            
                const relatedUser2 = await Users.findOne({
                    offset: Math.floor(Math.random() * (await Users.count())),
                });
                const Notification2 = await Notifications.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (Notification2?.setUser)
                {
                    await
                    Notification2.
                    setUser(relatedUser2);
                }
            
        }
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
            
            async function associateNotificationWithOrganization() {
            
                const relatedOrganization0 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const Notification0 = await Notifications.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (Notification0?.setOrganization)
                {
                    await
                    Notification0.
                    setOrganization(relatedOrganization0);
                }
            
                const relatedOrganization1 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const Notification1 = await Notifications.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (Notification1?.setOrganization)
                {
                    await
                    Notification1.
                    setOrganization(relatedOrganization1);
                }
            
                const relatedOrganization2 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const Notification2 = await Notifications.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (Notification2?.setOrganization)
                {
                    await
                    Notification2.
                    setOrganization(relatedOrganization2);
                }
            
        }
        
    

    
    
    
        
            
            async function associateActivityCommentWithTenant() {
            
                const relatedTenant0 = await Tenants.findOne({
                    offset: Math.floor(Math.random() * (await Tenants.count())),
                });
                const ActivityComment0 = await ActivityComments.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (ActivityComment0?.setTenant)
                {
                    await
                    ActivityComment0.
                    setTenant(relatedTenant0);
                }
            
                const relatedTenant1 = await Tenants.findOne({
                    offset: Math.floor(Math.random() * (await Tenants.count())),
                });
                const ActivityComment1 = await ActivityComments.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (ActivityComment1?.setTenant)
                {
                    await
                    ActivityComment1.
                    setTenant(relatedTenant1);
                }
            
                const relatedTenant2 = await Tenants.findOne({
                    offset: Math.floor(Math.random() * (await Tenants.count())),
                });
                const ActivityComment2 = await ActivityComments.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (ActivityComment2?.setTenant)
                {
                    await
                    ActivityComment2.
                    setTenant(relatedTenant2);
                }
            
        }
        
    
        
            
            async function associateActivityCommentWithOrganization() {
            
                const relatedOrganization0 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const ActivityComment0 = await ActivityComments.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (ActivityComment0?.setOrganization)
                {
                    await
                    ActivityComment0.
                    setOrganization(relatedOrganization0);
                }
            
                const relatedOrganization1 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const ActivityComment1 = await ActivityComments.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (ActivityComment1?.setOrganization)
                {
                    await
                    ActivityComment1.
                    setOrganization(relatedOrganization1);
                }
            
                const relatedOrganization2 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const ActivityComment2 = await ActivityComments.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (ActivityComment2?.setOrganization)
                {
                    await
                    ActivityComment2.
                    setOrganization(relatedOrganization2);
                }
            
        }
        
    
        
            
            async function associateActivityCommentWithAuthor() {
            
                const relatedAuthor0 = await Users.findOne({
                    offset: Math.floor(Math.random() * (await Users.count())),
                });
                const ActivityComment0 = await ActivityComments.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (ActivityComment0?.setAuthor)
                {
                    await
                    ActivityComment0.
                    setAuthor(relatedAuthor0);
                }
            
                const relatedAuthor1 = await Users.findOne({
                    offset: Math.floor(Math.random() * (await Users.count())),
                });
                const ActivityComment1 = await ActivityComments.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (ActivityComment1?.setAuthor)
                {
                    await
                    ActivityComment1.
                    setAuthor(relatedAuthor1);
                }
            
                const relatedAuthor2 = await Users.findOne({
                    offset: Math.floor(Math.random() * (await Users.count())),
                });
                const ActivityComment2 = await ActivityComments.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (ActivityComment2?.setAuthor)
                {
                    await
                    ActivityComment2.
                    setAuthor(relatedAuthor2);
                }
            
        }
        
    
        
    
        
    
        
    
        
            
            async function associateActivityCommentWithBooking_request() {
            
                const relatedBooking_request0 = await BookingRequests.findOne({
                    offset: Math.floor(Math.random() * (await BookingRequests.count())),
                });
                const ActivityComment0 = await ActivityComments.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (ActivityComment0?.setBooking_request)
                {
                    await
                    ActivityComment0.
                    setBooking_request(relatedBooking_request0);
                }
            
                const relatedBooking_request1 = await BookingRequests.findOne({
                    offset: Math.floor(Math.random() * (await BookingRequests.count())),
                });
                const ActivityComment1 = await ActivityComments.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (ActivityComment1?.setBooking_request)
                {
                    await
                    ActivityComment1.
                    setBooking_request(relatedBooking_request1);
                }
            
                const relatedBooking_request2 = await BookingRequests.findOne({
                    offset: Math.floor(Math.random() * (await BookingRequests.count())),
                });
                const ActivityComment2 = await ActivityComments.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (ActivityComment2?.setBooking_request)
                {
                    await
                    ActivityComment2.
                    setBooking_request(relatedBooking_request2);
                }
            
        }
        
    
        
            
            async function associateActivityCommentWithReservation() {
            
                const relatedReservation0 = await Reservations.findOne({
                    offset: Math.floor(Math.random() * (await Reservations.count())),
                });
                const ActivityComment0 = await ActivityComments.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (ActivityComment0?.setReservation)
                {
                    await
                    ActivityComment0.
                    setReservation(relatedReservation0);
                }
            
                const relatedReservation1 = await Reservations.findOne({
                    offset: Math.floor(Math.random() * (await Reservations.count())),
                });
                const ActivityComment1 = await ActivityComments.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (ActivityComment1?.setReservation)
                {
                    await
                    ActivityComment1.
                    setReservation(relatedReservation1);
                }
            
                const relatedReservation2 = await Reservations.findOne({
                    offset: Math.floor(Math.random() * (await Reservations.count())),
                });
                const ActivityComment2 = await ActivityComments.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (ActivityComment2?.setReservation)
                {
                    await
                    ActivityComment2.
                    setReservation(relatedReservation2);
                }
            
        }
        
    
        
            
            async function associateActivityCommentWithService_request() {
            
                const relatedService_request0 = await ServiceRequests.findOne({
                    offset: Math.floor(Math.random() * (await ServiceRequests.count())),
                });
                const ActivityComment0 = await ActivityComments.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (ActivityComment0?.setService_request)
                {
                    await
                    ActivityComment0.
                    setService_request(relatedService_request0);
                }
            
                const relatedService_request1 = await ServiceRequests.findOne({
                    offset: Math.floor(Math.random() * (await ServiceRequests.count())),
                });
                const ActivityComment1 = await ActivityComments.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (ActivityComment1?.setService_request)
                {
                    await
                    ActivityComment1.
                    setService_request(relatedService_request1);
                }
            
                const relatedService_request2 = await ServiceRequests.findOne({
                    offset: Math.floor(Math.random() * (await ServiceRequests.count())),
                });
                const ActivityComment2 = await ActivityComments.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (ActivityComment2?.setService_request)
                {
                    await
                    ActivityComment2.
                    setService_request(relatedService_request2);
                }
            
        }
        
    
        
            
            async function associateActivityCommentWithInvoice() {
            
                const relatedInvoice0 = await Invoices.findOne({
                    offset: Math.floor(Math.random() * (await Invoices.count())),
                });
                const ActivityComment0 = await ActivityComments.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (ActivityComment0?.setInvoice)
                {
                    await
                    ActivityComment0.
                    setInvoice(relatedInvoice0);
                }
            
                const relatedInvoice1 = await Invoices.findOne({
                    offset: Math.floor(Math.random() * (await Invoices.count())),
                });
                const ActivityComment1 = await ActivityComments.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (ActivityComment1?.setInvoice)
                {
                    await
                    ActivityComment1.
                    setInvoice(relatedInvoice1);
                }
            
                const relatedInvoice2 = await Invoices.findOne({
                    offset: Math.floor(Math.random() * (await Invoices.count())),
                });
                const ActivityComment2 = await ActivityComments.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (ActivityComment2?.setInvoice)
                {
                    await
                    ActivityComment2.
                    setInvoice(relatedInvoice2);
                }
            
        }
        
    

    
    
    
        
            
            async function associateChecklistWithTenant() {
            
                const relatedTenant0 = await Tenants.findOne({
                    offset: Math.floor(Math.random() * (await Tenants.count())),
                });
                const Checklist0 = await Checklists.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (Checklist0?.setTenant)
                {
                    await
                    Checklist0.
                    setTenant(relatedTenant0);
                }
            
                const relatedTenant1 = await Tenants.findOne({
                    offset: Math.floor(Math.random() * (await Tenants.count())),
                });
                const Checklist1 = await Checklists.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (Checklist1?.setTenant)
                {
                    await
                    Checklist1.
                    setTenant(relatedTenant1);
                }
            
                const relatedTenant2 = await Tenants.findOne({
                    offset: Math.floor(Math.random() * (await Tenants.count())),
                });
                const Checklist2 = await Checklists.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (Checklist2?.setTenant)
                {
                    await
                    Checklist2.
                    setTenant(relatedTenant2);
                }
            
        }
        
    
        
            
            async function associateChecklistWithReservation() {
            
                const relatedReservation0 = await Reservations.findOne({
                    offset: Math.floor(Math.random() * (await Reservations.count())),
                });
                const Checklist0 = await Checklists.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (Checklist0?.setReservation)
                {
                    await
                    Checklist0.
                    setReservation(relatedReservation0);
                }
            
                const relatedReservation1 = await Reservations.findOne({
                    offset: Math.floor(Math.random() * (await Reservations.count())),
                });
                const Checklist1 = await Checklists.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (Checklist1?.setReservation)
                {
                    await
                    Checklist1.
                    setReservation(relatedReservation1);
                }
            
                const relatedReservation2 = await Reservations.findOne({
                    offset: Math.floor(Math.random() * (await Reservations.count())),
                });
                const Checklist2 = await Checklists.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (Checklist2?.setReservation)
                {
                    await
                    Checklist2.
                    setReservation(relatedReservation2);
                }
            
        }
        
    
        
    
        
    
        
    
        
    
        
            
            async function associateChecklistWithAssigned_to() {
            
                const relatedAssigned_to0 = await Users.findOne({
                    offset: Math.floor(Math.random() * (await Users.count())),
                });
                const Checklist0 = await Checklists.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (Checklist0?.setAssigned_to)
                {
                    await
                    Checklist0.
                    setAssigned_to(relatedAssigned_to0);
                }
            
                const relatedAssigned_to1 = await Users.findOne({
                    offset: Math.floor(Math.random() * (await Users.count())),
                });
                const Checklist1 = await Checklists.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (Checklist1?.setAssigned_to)
                {
                    await
                    Checklist1.
                    setAssigned_to(relatedAssigned_to1);
                }
            
                const relatedAssigned_to2 = await Users.findOne({
                    offset: Math.floor(Math.random() * (await Users.count())),
                });
                const Checklist2 = await Checklists.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (Checklist2?.setAssigned_to)
                {
                    await
                    Checklist2.
                    setAssigned_to(relatedAssigned_to2);
                }
            
        }
        
    
        
            // Similar logic for "relation_many"
        
    
        
    
        
            
            async function associateChecklistWithOrganization() {
            
                const relatedOrganization0 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const Checklist0 = await Checklists.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (Checklist0?.setOrganization)
                {
                    await
                    Checklist0.
                    setOrganization(relatedOrganization0);
                }
            
                const relatedOrganization1 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const Checklist1 = await Checklists.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (Checklist1?.setOrganization)
                {
                    await
                    Checklist1.
                    setOrganization(relatedOrganization1);
                }
            
                const relatedOrganization2 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const Checklist2 = await Checklists.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (Checklist2?.setOrganization)
                {
                    await
                    Checklist2.
                    setOrganization(relatedOrganization2);
                }
            
        }
        
    

    
    
    
        
            
            async function associateChecklistItemWithChecklist() {
            
                const relatedChecklist0 = await Checklists.findOne({
                    offset: Math.floor(Math.random() * (await Checklists.count())),
                });
                const ChecklistItem0 = await ChecklistItems.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (ChecklistItem0?.setChecklist)
                {
                    await
                    ChecklistItem0.
                    setChecklist(relatedChecklist0);
                }
            
                const relatedChecklist1 = await Checklists.findOne({
                    offset: Math.floor(Math.random() * (await Checklists.count())),
                });
                const ChecklistItem1 = await ChecklistItems.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (ChecklistItem1?.setChecklist)
                {
                    await
                    ChecklistItem1.
                    setChecklist(relatedChecklist1);
                }
            
                const relatedChecklist2 = await Checklists.findOne({
                    offset: Math.floor(Math.random() * (await Checklists.count())),
                });
                const ChecklistItem2 = await ChecklistItems.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (ChecklistItem2?.setChecklist)
                {
                    await
                    ChecklistItem2.
                    setChecklist(relatedChecklist2);
                }
            
        }
        
    
        
    
        
    
        
    
        
            
            async function associateChecklistItemWithDone_by() {
            
                const relatedDone_by0 = await Users.findOne({
                    offset: Math.floor(Math.random() * (await Users.count())),
                });
                const ChecklistItem0 = await ChecklistItems.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (ChecklistItem0?.setDone_by)
                {
                    await
                    ChecklistItem0.
                    setDone_by(relatedDone_by0);
                }
            
                const relatedDone_by1 = await Users.findOne({
                    offset: Math.floor(Math.random() * (await Users.count())),
                });
                const ChecklistItem1 = await ChecklistItems.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (ChecklistItem1?.setDone_by)
                {
                    await
                    ChecklistItem1.
                    setDone_by(relatedDone_by1);
                }
            
                const relatedDone_by2 = await Users.findOne({
                    offset: Math.floor(Math.random() * (await Users.count())),
                });
                const ChecklistItem2 = await ChecklistItems.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (ChecklistItem2?.setDone_by)
                {
                    await
                    ChecklistItem2.
                    setDone_by(relatedDone_by2);
                }
            
        }
        
    
        
    
        
    
        
            
            async function associateChecklistItemWithOrganization() {
            
                const relatedOrganization0 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const ChecklistItem0 = await ChecklistItems.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (ChecklistItem0?.setOrganization)
                {
                    await
                    ChecklistItem0.
                    setOrganization(relatedOrganization0);
                }
            
                const relatedOrganization1 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const ChecklistItem1 = await ChecklistItems.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (ChecklistItem1?.setOrganization)
                {
                    await
                    ChecklistItem1.
                    setOrganization(relatedOrganization1);
                }
            
                const relatedOrganization2 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const ChecklistItem2 = await ChecklistItems.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (ChecklistItem2?.setOrganization)
                {
                    await
                    ChecklistItem2.
                    setOrganization(relatedOrganization2);
                }
            
        }
        
    

    
    
    
        
            
            async function associateJobRunWithTenant() {
            
                const relatedTenant0 = await Tenants.findOne({
                    offset: Math.floor(Math.random() * (await Tenants.count())),
                });
                const JobRun0 = await JobRuns.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (JobRun0?.setTenant)
                {
                    await
                    JobRun0.
                    setTenant(relatedTenant0);
                }
            
                const relatedTenant1 = await Tenants.findOne({
                    offset: Math.floor(Math.random() * (await Tenants.count())),
                });
                const JobRun1 = await JobRuns.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (JobRun1?.setTenant)
                {
                    await
                    JobRun1.
                    setTenant(relatedTenant1);
                }
            
                const relatedTenant2 = await Tenants.findOne({
                    offset: Math.floor(Math.random() * (await Tenants.count())),
                });
                const JobRun2 = await JobRuns.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (JobRun2?.setTenant)
                {
                    await
                    JobRun2.
                    setTenant(relatedTenant2);
                }
            
        }
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
    
        
            
            async function associateJobRunWithOrganization() {
            
                const relatedOrganization0 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const JobRun0 = await JobRuns.findOne({
                    order: [['id', 'ASC']],
                    offset: 0
                });
                if (JobRun0?.setOrganization)
                {
                    await
                    JobRun0.
                    setOrganization(relatedOrganization0);
                }
            
                const relatedOrganization1 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const JobRun1 = await JobRuns.findOne({
                    order: [['id', 'ASC']],
                    offset: 1
                });
                if (JobRun1?.setOrganization)
                {
                    await
                    JobRun1.
                    setOrganization(relatedOrganization1);
                }
            
                const relatedOrganization2 = await Organizations.findOne({
                    offset: Math.floor(Math.random() * (await Organizations.count())),
                });
                const JobRun2 = await JobRuns.findOne({
                    order: [['id', 'ASC']],
                    offset: 2
                });
                if (JobRun2?.setOrganization)
                {
                    await
                    JobRun2.
                    setOrganization(relatedOrganization2);
                }
            
        }
        
    


module.exports = {
    up: async (queryInterface, Sequelize) => {
        
            
            
            
            
            
                
                await Organizations.bulkCreate(OrganizationsData);
                
            
            
                
                await Tenants.bulkCreate(TenantsData);
                
            
            
                
                await RoleAssignments.bulkCreate(RoleAssignmentsData);
                
            
            
                
                await OrganizationMemberships.bulkCreate(OrganizationMembershipsData);
                
            
            
                
                await Properties.bulkCreate(PropertiesData);
                
            
            
                
                await Amenities.bulkCreate(AmenitiesData);
                
            
            
                
                await UnitTypes.bulkCreate(UnitTypesData);
                
            
            
                
                await Units.bulkCreate(UnitsData);
                
            
            
                
                await UnitAvailabilityBlocks.bulkCreate(UnitAvailabilityBlocksData);
                
            
            
                
                await NegotiatedRates.bulkCreate(NegotiatedRatesData);
                
            
            
                
                await BookingRequests.bulkCreate(BookingRequestsData);
                
            
            
                
                await BookingRequestTravelers.bulkCreate(BookingRequestTravelersData);
                
            
            
                
                await ApprovalSteps.bulkCreate(ApprovalStepsData);
                
            
            
                
                await Reservations.bulkCreate(ReservationsData);
                
            
            
                
                await ReservationGuests.bulkCreate(ReservationGuestsData);
                
            
            
                
                await ServiceRequests.bulkCreate(ServiceRequestsData);
                
            
            
                
                await Invoices.bulkCreate(InvoicesData);
                
            
            
                
                await InvoiceLineItems.bulkCreate(InvoiceLineItemsData);
                
            
            
                
                await Payments.bulkCreate(PaymentsData);
                
            
            
                
                await Documents.bulkCreate(DocumentsData);
                
            
            
                
                await AuditLogs.bulkCreate(AuditLogsData);
                
            
            
                
                await Notifications.bulkCreate(NotificationsData);
                
            
            
                
                await ActivityComments.bulkCreate(ActivityCommentsData);
                
            
            
                
                await Checklists.bulkCreate(ChecklistsData);
                
            
            
                
                await ChecklistItems.bulkCreate(ChecklistItemsData);
                
            
            
                
                await JobRuns.bulkCreate(JobRunsData);
                
            
            await Promise.all([
            
                
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                        // Similar logic for "relation_many"
                    
                
                    
                        
                        await associateUserWithOrganization(),
                    
                
            
                
                
                
                
                    
                
            
                
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                        // Similar logic for "relation_many"
                    
                
                    
                        // Similar logic for "relation_many"
                    
                
                    
                        // Similar logic for "relation_many"
                    
                
            
                
                
                    
                        
                        await associateRoleAssignmentWithUser(),
                    
                
                    
                
                    
                        
                        await associateRoleAssignmentWithTenant(),
                    
                
                    
                        
                        await associateRoleAssignmentWithOrganization(),
                    
                
                    
                
                    
                
                    
                
            
                
                
                    
                        
                        await associateOrganizationMembershipWithOrganization(),
                    
                
                    
                        
                        await associateOrganizationMembershipWithUser(),
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
            
                
                
                    
                        
                        await associatePropertyWithTenant(),
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                        // Similar logic for "relation_many"
                    
                
                    
                        // Similar logic for "relation_many"
                    
                
                    
                        // Similar logic for "relation_many"
                    
                
                    
                        
                        await associatePropertyWithOrganization(),
                    
                
            
                
                
                    
                        
                        await associateAmenityWithProperty(),
                    
                
                    
                
                    
                
                    
                        
                        await associateAmenityWithOrganization(),
                    
                
            
                
                
                    
                        
                        await associateUnitTypeWithProperty(),
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                        // Similar logic for "relation_many"
                    
                
                    
                        
                        await associateUnitTypeWithOrganization(),
                    
                
            
                
                
                    
                        
                        await associateUnitWithProperty(),
                    
                
                    
                        
                        await associateUnitWithUnit_type(),
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                        // Similar logic for "relation_many"
                    
                
                    
                        
                        await associateUnitWithOrganization(),
                    
                
            
                
                
                    
                        
                        await associateUnitAvailabilityBlockWithUnit(),
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                        
                        await associateUnitAvailabilityBlockWithReservation(),
                    
                
                    
                        
                        await associateUnitAvailabilityBlockWithOrganization(),
                    
                
            
                
                
                    
                        
                        await associateNegotiatedRateWithOrganization(),
                    
                
                    
                        
                        await associateNegotiatedRateWithProperty(),
                    
                
                    
                        
                        await associateNegotiatedRateWithUnit_type(),
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
            
                
                
                    
                        
                        await associateBookingRequestWithTenant(),
                    
                
                    
                        
                        await associateBookingRequestWithOrganization(),
                    
                
                    
                        
                        await associateBookingRequestWithRequested_by(),
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                        
                        await associateBookingRequestWithPreferred_property(),
                    
                
                    
                        
                        await associateBookingRequestWithPreferred_unit_type(),
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                        // Similar logic for "relation_many"
                    
                
                    
                        // Similar logic for "relation_many"
                    
                
                    
                        // Similar logic for "relation_many"
                    
                
                    
                        // Similar logic for "relation_many"
                    
                
            
                
                
                    
                        
                        await associateBookingRequestTravelerWithBooking_request(),
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                        
                        await associateBookingRequestTravelerWithOrganization(),
                    
                
            
                
                
                    
                        
                        await associateApprovalStepWithBooking_request(),
                    
                
                    
                
                    
                        
                        await associateApprovalStepWithApprover(),
                    
                
                    
                
                    
                
                    
                
                    
                        
                        await associateApprovalStepWithOrganization(),
                    
                
            
                
                
                    
                        
                        await associateReservationWithTenant(),
                    
                
                    
                        
                        await associateReservationWithOrganization(),
                    
                
                    
                        
                        await associateReservationWithBooking_request(),
                    
                
                    
                
                    
                
                    
                        
                        await associateReservationWithProperty(),
                    
                
                    
                        
                        await associateReservationWithUnit(),
                    
                
                    
                        
                        await associateReservationWithUnit_type(),
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                        // Similar logic for "relation_many"
                    
                
                    
                        // Similar logic for "relation_many"
                    
                
                    
                        // Similar logic for "relation_many"
                    
                
                    
                        // Similar logic for "relation_many"
                    
                
                    
                        // Similar logic for "relation_many"
                    
                
            
                
                
                    
                        
                        await associateReservationGuestWithReservation(),
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                        
                        await associateReservationGuestWithOrganization(),
                    
                
            
                
                
                    
                        
                        await associateServiceRequestWithTenant(),
                    
                
                    
                        
                        await associateServiceRequestWithReservation(),
                    
                
                    
                        
                        await associateServiceRequestWithRequested_by(),
                    
                
                    
                        
                        await associateServiceRequestWithAssigned_to(),
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                        // Similar logic for "relation_many"
                    
                
                    
                        // Similar logic for "relation_many"
                    
                
                    
                        
                        await associateServiceRequestWithOrganization(),
                    
                
            
                
                
                    
                        
                        await associateInvoiceWithTenant(),
                    
                
                    
                        
                        await associateInvoiceWithOrganization(),
                    
                
                    
                        
                        await associateInvoiceWithReservation(),
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                        // Similar logic for "relation_many"
                    
                
                    
                        // Similar logic for "relation_many"
                    
                
                    
                        // Similar logic for "relation_many"
                    
                
            
                
                
                    
                        
                        await associateInvoiceLineItemWithInvoice(),
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                        
                        await associateInvoiceLineItemWithOrganization(),
                    
                
            
                
                
                    
                        
                        await associatePaymentWithInvoice(),
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                        
                        await associatePaymentWithOrganization(),
                    
                
            
                
                
                    
                        
                        await associateDocumentWithTenant(),
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                        
                        await associateDocumentWithUploaded_by(),
                    
                
                    
                        
                        await associateDocumentWithOrganization(),
                    
                
                    
                        
                        await associateDocumentWithBooking_request(),
                    
                
                    
                        
                        await associateDocumentWithReservation(),
                    
                
                    
                        
                        await associateDocumentWithService_request(),
                    
                
                    
                        
                        await associateDocumentWithInvoice(),
                    
                
                    
                
                    
                
            
                
                
                    
                        
                        await associateAuditLogWithTenant(),
                    
                
                    
                        
                        await associateAuditLogWithActor(),
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                        
                        await associateAuditLogWithOrganization(),
                    
                
            
                
                
                    
                        
                        await associateNotificationWithTenant(),
                    
                
                    
                        
                        await associateNotificationWithUser(),
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                        
                        await associateNotificationWithOrganization(),
                    
                
            
                
                
                    
                        
                        await associateActivityCommentWithTenant(),
                    
                
                    
                        
                        await associateActivityCommentWithOrganization(),
                    
                
                    
                        
                        await associateActivityCommentWithAuthor(),
                    
                
                    
                
                    
                
                    
                
                    
                        
                        await associateActivityCommentWithBooking_request(),
                    
                
                    
                        
                        await associateActivityCommentWithReservation(),
                    
                
                    
                        
                        await associateActivityCommentWithService_request(),
                    
                
                    
                        
                        await associateActivityCommentWithInvoice(),
                    
                
            
                
                
                    
                        
                        await associateChecklistWithTenant(),
                    
                
                    
                        
                        await associateChecklistWithReservation(),
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                        
                        await associateChecklistWithAssigned_to(),
                    
                
                    
                        // Similar logic for "relation_many"
                    
                
                    
                
                    
                        
                        await associateChecklistWithOrganization(),
                    
                
            
                
                
                    
                        
                        await associateChecklistItemWithChecklist(),
                    
                
                    
                
                    
                
                    
                
                    
                        
                        await associateChecklistItemWithDone_by(),
                    
                
                    
                
                    
                
                    
                        
                        await associateChecklistItemWithOrganization(),
                    
                
            
                
                
                    
                        
                        await associateJobRunWithTenant(),
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                
                    
                        
                        await associateJobRunWithOrganization(),
                    
                
            
            ]);
        
    },

    down: async (queryInterface, Sequelize) => {
        
            
            
            
            
            
            await queryInterface.bulkDelete('organizations', null, {});
            
            
            await queryInterface.bulkDelete('tenants', null, {});
            
            
            await queryInterface.bulkDelete('role_assignments', null, {});
            
            
            await queryInterface.bulkDelete('organization_memberships', null, {});
            
            
            await queryInterface.bulkDelete('properties', null, {});
            
            
            await queryInterface.bulkDelete('amenities', null, {});
            
            
            await queryInterface.bulkDelete('unit_types', null, {});
            
            
            await queryInterface.bulkDelete('units', null, {});
            
            
            await queryInterface.bulkDelete('unit_availability_blocks', null, {});
            
            
            await queryInterface.bulkDelete('negotiated_rates', null, {});
            
            
            await queryInterface.bulkDelete('booking_requests', null, {});
            
            
            await queryInterface.bulkDelete('booking_request_travelers', null, {});
            
            
            await queryInterface.bulkDelete('approval_steps', null, {});
            
            
            await queryInterface.bulkDelete('reservations', null, {});
            
            
            await queryInterface.bulkDelete('reservation_guests', null, {});
            
            
            await queryInterface.bulkDelete('service_requests', null, {});
            
            
            await queryInterface.bulkDelete('invoices', null, {});
            
            
            await queryInterface.bulkDelete('invoice_line_items', null, {});
            
            
            await queryInterface.bulkDelete('payments', null, {});
            
            
            await queryInterface.bulkDelete('documents', null, {});
            
            
            await queryInterface.bulkDelete('audit_logs', null, {});
            
            
            await queryInterface.bulkDelete('notifications', null, {});
            
            
            await queryInterface.bulkDelete('activity_comments', null, {});
            
            
            await queryInterface.bulkDelete('checklists', null, {});
            
            
            await queryInterface.bulkDelete('checklist_items', null, {});
            
            
            await queryInterface.bulkDelete('job_runs', null, {});
            
        
    },
};