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aACA,aACA,gBACA,eACA,mBACA,mBACA,4BACA,oBACA,oBACA,qBACA,mBACA,mBACA,oBACA,iCACA,4BACA,0BACA,0BACA,4BACA,8BACA,6BACA,6BACA,4BACA,6BACA,iCACA,4BACA,oBACA,gBACA,sBACA,uBACA,mBACA,mBACA,sBACA,mBACA,wBACA,qBACA,qBACA,qBACA,mBACA,kBACA,kBACA,YACA,mBACA,aACA,kBACA,eACA,mBACA,cACA,iBACA,kBACA,gBACA,oBACA,iBACA,oBACA,iBACA,gBACA,oBACA,uBACA,iBACA,mBACA,sBACA,oBACA,iBACA,mBACA,qBACA,iBACA,eACA,eACA,iBACA,mBACA,kBACA,oBACA,kBACA,oBACA,uBACA,kBACA,kBACA,sBACA,kBACA,sBACA,mBACA,mBACA,sBACA,mBACA,uBACA,iBACA,wBACA,mBACA,wBACA,sBACA,iBACA,kBACA,uBACA,sBACA,oBACA,qBACA,iBACA,eACA,gBACA,iBACA,oBACA,mBACA,uBACA,iBACA,gBACA,cACA,iBACA,qBACA,iBACA,sBACA,kBACA,mBACA,eACA,iBACA,gBACA,gBACA,oBACA,wBACA,iBACA,oBACA,oBACA,iBACA,eACA,kBACA,gBACA,eACA,kBACA,kBACA,eACA,mBACA,gBACA,kBACA,iBACA,iBACA,eACA,gBACA,eACA,kBACA,eACA,mBACA,kBACA,uBACA,uBACA,gBACA,gBACA,yBACA,oBACA,eACA,gBACA,iBACA,iBACA,sBACA,yBACA,kBACA,eACA,iBACA,gBACA,gBACA,gBACA,iBACA,eACA,gBACA,eACA,cACA,qBACA,cACA,kBACA,aACA,aACA,iBACA,eACA,iBACA,oBACA,qBACA,iBACA,aACA,cACA,iBACA,gBACA,cACA,aACA,cACA,YACA,cACA,eACA,kBACA,iBACA,oBACA,cACA,iBACA,oBACA,gBACA,kBACA,iBACA,oBACA,cACA,mBACA,YACA,kBACA,aACA,qBACA,eACA,mBACA,kBACA,sBACA,iBACA,iBACA,oBACA,oBACA,mBACA,oBACA,kBACA,qBACA,kBACA,yBACA,oBACA,eACA,gBACA,kBACA,iBACA,kBACA,eACA,kBACA,mBACA,cACA,iBACA,gBACA,eACA,mBACA,kBACA,iBACA,eACA,iBACA,oBACA,kBACA,uBACA,uBACA,cACA,eACA,gBACA,mBACA,mBACA,sBACA,YACA,cACA,gBACA,mBACA,kBACA,gBACA,mBACA,aACA,iBACA,mBACA,kBACA,qBACA,gBACA,oBACA,eACA,mBACA,mBACA,iBACA,mBACA,gBACA,qBACA,YACA,mBACA,eACA,aACA,oBACA,mBACA,eACA,aACA,eACA,gBACA,mBACA,gBACA,eACA,gBACA,qBACA,iBACA,cACA,cACA,sBACA,cACA,kBACA,mBACA,iBACA,qBACA,cACA,kBACA,sBACA,gBACA,qBACA,kBACA,mBACA,eACA,gBACA,kBACA,YACA,gBACA,eACA,oBACA,kBACA,wBACA,mBACA,cACA,cACA,kBACA,oBACA,eACA,mBACA,kBACA,8BACA,8BACA,+BACA,4BACA,0BACA,0BACA,6BACA,wBACA,kBACA,4BACA,uBACA,oBACA,8BACA,iCACA,8BACA,iBACA,gBACA,kBACA,sBACA,oBACA,iBACA,gBACA,qBACA,kBACA,eACA,eACA,mBACA,qBACA,iBACA,gBACA,kBACA,mBACA,gBACA,iBACA,eACA,qBACJ,0sBCjSA1O,GAAM,OAAO2O,EAAG,EAChB3O,GAAM,OAAO4O,EAAQ,EAGrB,MAAMlD,EAASC,GAAU,EACnBf,EAAQC,GAAS,EACjBgE,EAAkBhD,EAAI,EAAK,EAE3BiD,EAAiBlE,EAAM,QAAQ,oBAAoB,EACnDmE,EAAanE,EAAM,QAAQ,iBAAiB,EAE5CO,EAAY,MAAO3J,IAAgD,CACjE,MAAAoJ,EAAM,SAAS,iBAAkBpJ,EAAK,CAC9C,EAEMwN,EAAmB,SAAY,CAC7B,MAAApE,EAAM,SAAS,sBAAuB,EAAE,CAChD,EAEMqE,EAAYH,EAAe,OAAO,CAAC7P,GAAeiQ,KAClDjQ,GAAAiQ,EAAQ,IAAI,EAAIA,EAAQ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ACN,MAAO,YACP,KAAM,QACN,EAAG,IACH,EAAG,GACH,YAAa,qDACb,SAAU,qBACV,KAAM,yBACN,UAAW,EACf,EACA,CACI,GAAI,wCACJ,KAAM,qBACN,MAAO,WACP,KAAM,QACN,EAAG,IACH,EAAG,GACH,YAAa,oDACb,SAAU,qBACV,KAAM,yBACN,UAAW,EACf,EACA,CACI,GAAI,sCACJ,KAAM,sBACN,MAAO,SACP,KAAM,QACN,EAAG,IACH,EAAG,GACH,YAAa,8DACb,SAAU,qBACV,KAAM,yBACN,UAAW,EACf,EACA,CACI,GAAI,sBACJ,KAAM,MACN,MAAO,MACP,KAAM,QACN,EAAG,GACH,EAAG,GACH,YAAa,4CACb,SAAU,qBACV,QAAS,SACT,KAAM,uBACN,UAAW,EACf,EACA,CACI,GAAI,4BACJ,KAAM,OACN,MAAO,YACP,KAAM,YACN,MAAO,YACP,UAAW,GACX,KAAM,gBACN,SAAU,qBACV,EAAG,GACH,EAAG,GACH,YAAa,wCACb,UAAW,EACf,EACA,CACI,GAAI,8BACJ,KAAM,cACN,MAAO,cACP,KAAM,QACN,UAAW,GACX,KAAM,qBACN,SAAU,qBACV,SAAU,GACV,EAAG,IACH,EAAG,GACH,UAAW,EACf,EACA,CACI,GAAI,mBACJ,KAAM,SACN,MAAO,aACP,KAAM,aACN,SAAU,GACV,UAAW,GACX,KAAM,gBACN,SAAU,qBACV,SAAU,EACV,EAAG,GACH,EAAG,GACH,YAAa,sCACb,UAAW,EACf,EAEA,CACI,GAAI,gCACJ,KAAM,kBACN,MAAO,0BACP,KAAM,QACN,SAAU,UACV,KAAM,UACN,SAAU,GACV,EAAG,IACH,EAAG,EACP,EACA,CACI,GAAI,qBACJ,KAAM,OACN,MAAO,eACP,KAAM,QACN,SAAU,UACV,SAAU,GACV,UAAW,GACX,KAAM,SACV,EACA,CACI,GAAI,qBACJ,KAAM,OACN,MAAO,eACP,KAAM,QACN,SAAU,UACV,SAAU,GACV,UAAW,GACX,KAAM,SACV,EACA,CACI,GAAI,sBACJ,KAAM,QACN,MAAO,gBACP,KAAM,QACN,SAAU,UACV,SAAU,GACV,UAAW,GACX,KAAM,SACV,EACA,CACI,GAAI,sBACJ,KAAM,QACN,MAAO,gBACP,KAAM,QACN,SAAU,UACV,SAAU,GACV,UAAW,GACX,KAAM,aACV,EACA,CACI,GAAI,sBACJ,KAAM,UACN,MAAO,gBACP,KAAM,QACN,SAAU,UACV,SAAU,GACV,UAAW,GACX,KAAM,uBACV,EACA,CACI,GAAI,oBACJ,KAAM,MACN,MAAO,cACP,KAAM,QACN,SAAU,UACV,SAAU,GACV,KAAM,uBACV,EACA,CACI,GAAI,iCACJ,KAAM,WACN,MAAO,mBACP,KAAM,QACN,SAAU,UACV,SAAU,GACV,KAAM,wBACN,EAAG,GACH,EAAG,GACH,YAAa,oOACjB,EACA,CACI,GAAI,sBACJ,KAAM,gBACN,MAAO,gBACP,KAAM,QACN,SAAU,UACV,UAAW,GACX,SAAU,GACV,KAAM,mBACN,EAAG,IACH,EAAG,EACP,EACA,CACI,GAAI,wBACJ,KAAM,UACN,MAAO,kBACP,KAAM,QACN,SAAU,UACV,UAAW,GACX,SAAU,GACV,KAAM,cACN,EAAG,IACH,EAAG,EACP,EACA,CACI,GAAI,uCACJ,KAAM,iBACN,MAAO,yBACP,KAAM,QACN,SAAU,UACV,SAAU,GACV,KAAM,cACN,EAAG,IACH,EAAG,EACP,EACA,CACI,GAAI,6BACJ,KAAM,eACN,MAAO,uBACP,KAAM,QACN,SAAU,UACV,KAAM,WACN,SAAU,GACV,EAAG,IACH,EAAG,EACP,EACA,CACI,GAAI,sBACJ,KAAM,gBACN,MAAO,gBACP,KAAM,QACN,SAAU,UACV,SAAU,GACV,KAAM,WACN,EAAG,IACH,EAAG,EACP,EACA,CACI,GAAI,mBACJ,KAAM,aACN,MAAO,aACP,KAAM,QACN,SAAU,UACV,SAAU,GACV,KAAM,cACN,EAAG,IACH,EAAG,EACP,EAEA,CACI,GAAI,mBACJ,KAAM,aACN,MAAO,aACP,KAAM,QACN,SAAU,UACV,KAAM,cACN,SAAU,GACV,EAAG,IACH,EAAG,EACP,EACA,CACI,GAAI,6BACJ,KAAM,gBACN,MAAO,cACP,KAAM,QACN,SAAU,UACV,KAAM,qBACN,SAAU,GACV,EAAG,IACH,EAAG,EACP,EACA,CACI,GAAI,+BACJ,KAAM,kBACN,MAAO,gBACP,KAAM,QACN,SAAU,UACV,SAAU,GACV,KAAM,qBACN,EAAG,IACH,EAAG,EACP,EACA,CACI,GAAI,2BACJ,KAAM,aACN,MAAO,qBACP,KAAM,QACN,SAAU,UACV,SAAU,GACV,KAAM,qBACN,EAAG,IACH,EAAG,EACP,EACA,CACI,GAAI,yBACJ,KAAM,WACN,MAAO,mBACP,KAAM,QACN,SAAU,UACV,SAAU,GACV,KAAM,qBACN,EAAG,IACH,EAAG,EACP,EACA,CACI,GAAI,2BACJ,KAAM,aACN,MAAO,qBACP,KAAM,QACN,SAAU,UACV,SAAU,GACV,KAAM,qBACN,EAAG,IACH,EAAG,EACP,EACA,CACI,GAAI,yBACJ,KAAM,WACN,MAAO,mBACP,KAAM,QACN,SAAU,UACV,SAAU,GACV,KAAM,qBACN,EAAG,IACH,EAAG,EACP,EACA,CACI,GAAI,2BACJ,KAAM,aACN,MAAO,qBACP,KAAM,QACN,SAAU,UACV,SAAU,GACV,KAAM,WACN,EAAG,IACH,EAAG,EACP,EACA,CACI,GAAI,sBACJ,KAAM,cACN,MAAO,gBACP,KAAM,QACN,SAAU,UACV,SAAU,GACV,KAAM,WACN,EAAG,IACH,EAAG,EACP,EAEA,CACI,GAAI,sBACJ,KAAM,cACN,MAAO,gBACP,KAAM,QACN,SAAU,UACV,SAAU,GACV,KAAM,WACN,EAAG,IACH,EAAG,EACP,EACA,CACI,GAAI,yBACJ,KAAM,iBACN,MAAO,mBACP,KAAM,QACN,SAAU,UACV,SAAU,GACV,KAAM,WACN,EAAG,IACH,EAAG,EACP,EACA,CACI,GAAI,yBACJ,KAAM,iBACN,MAA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W","CLOSE_SIDEBAR","TOGGLE_DEVICE","SET_ALL_POSSIBLE_PERMISSIONS","SET_MASQUERADE_STATUS","SET_MASQUERADE","END_MASQUERADE","SET_FW_STRIPE_KEY","SET_POLLED_FW_BUILD_NUMBER","SET_UPDATE_AVAILABLE","SET_APP_FEATURES","MARK_SETUP_ITEM_COMPLETE","SET_FEATURES_WAITLIST","SET_CURRENT_CURRENCY","TOGGLE_DEBUG_ON","TOGGLE_DEBUG_DRAWER","SET_FW_BUILD_NUMBER","SET_HOVERED_TURNOVER_BOOKING_ID","SET_ROUTES","SET_SETTINGS_LOADING","SET_NOTIFICATION_SETTINGS","SET_VEHICLES_LOADING","SET_VEHICLES","SET_VEHICLE_MAKES","SET_VEHICLE_MODELS","SET_VEHICLE_CLASS_CREATED","SET_VEHICLE_CLASSES","SET_VEHICLE_CLASS","CLEAR_VEHICLE_FORM_ERRORS","SET_VEHICLE_FORM_ERRORS","SET_USER","SET_AUTH_LOADING","SET_TOKEN","SAVE_TOKEN","SAVE_REGISTER_ID","SET_ROLES","SET_PERMISSIONS","FETCH_USER_FAILURE","LOGOUT","UPDATE_USER","SET_USER_NOTIFICATIONS","SET_USER_API_TOKENS","SET_BOOKING_LOADING","SET_BOOKING_DIALOG","CLEAR_BOOKING_FORM_ERRORS","SET_BOOKING_FORM_ERROR","SET_FILTERED_MAKES","PUSH_CALENDAR_ATTRIBUTES","SET_CALENDAR_ATTRIBUTES","SET_UNAVAILABLE_DATES","RESET_UNAVAILABLE_DATES","SET_BOOKING_LISTING","SET_STORED_TURO_BOOKINGS","SET_CUSTOMER_BOOKING","SET_REMEMBER_CUSTOMER","SET_BOOKINGS","SET_BOOKINGS_META","SET_ABANDONED_BOOKINGS","SET_PRIORITY_BOOKINGS","SET_TOTAL_BOOKINGS","SET_CURRENT_WORKING_BOOKING","SET_CURRENT_WORKING_BOOKING_STATUS","SET_BOOKING_PAYMENTS","MERGE_BOOKING_LINE_ITEM","UPDATE_BOOKING_LINE_ITEM","REMOVE_BOOKING_LINE_ITEM","SET_BOOKING_CART_ID","RESET_BOOKING","SET_BOOKING_AUTOMATION_EVENTS","SET_BOOKING_NOT_FOUND","SET_CURRENT_STRIPE_CHARGE","SET_FLEET_RESOURCES","SET_CURRENT_WORKING_BOOKING_ATTRIBUTE","SET_COMPANY_LOADING","SET_COMPANY","SET_COMPANY_PHONE","SET_COMPANY_META","SET_COMPANY_DEFAULT_META","SET_COMPANY_BOOKINGS","SET_COMPANY_EMPLOYEES","SET_COMPANY_EMPLOYEE","SET_POSSIBLE_PERMISSIONS","RESET_EMPLOYEE","SET_COMPANY_NOTIFICATIONS","SET_EMPLOYEE_PERMISSIONS","SET_EMPLOYEE_ROLES","SET_EMAIL_DOMAIN_SETTINGS","SET_DELIVERY_LOCATIONS","SET_FEEDBACK_REVIEWS","SET_COMPANY_FORM_ERROR","SET_COMPANY_META_FORM_ERROR","CLEAR_COMPANY_META_FORM_ERRORS","SET_OPERATING_RULES","SET_COMPANY_CURRENCY","SET_COMPANY_SETTINGS","SET_COUNTS","SET_AFFILIATE_LOADING","SET_AFFILIATE","SET_AFFILIATE_PAYOUTS","SET_AFFILIATE_APPLICATION","SET_AFFILIATE_FUTURE_PAYOUT","SET_AFFILIATE_PAST_PAYOUT","SET_LISTING_LOADING","SET_LISTING_SNACK","SET_LISTING_DIALOG","CLEAR_LISTING_FILTER","SET_LISTING_FILTER_AVAILABLE_FILTERS","SET_LISTING_FILTER_SELECTED_FILTERS","TOGGLE_LISTING_FILTER","SET_LISTING_VEHICLE","SET_LISTING_PRICE","SET_LISTING_PRICE_TAXABLE","SET_LISTING_PRICE_TAX_CATEGORY","SET_LISTING_SEC_DEP","SET_LISTING_SEC_DEP_CREDIT","SET_LISTING_SEC_DEP_DEBIT","SET_LISTING_MILES_OVERAGE","RESET_CURRENT_LISTING","SET_CURRENT_NEW_LISTING","SET_CURRENT_LISTING","SET_LISTING","SET_LISTING_INIT","SET_ALL_LISTINGS","SET_LISTING_ID","SET_STATUS_FILTER_ITEMS","SET_STATUS_FILTER_ITEMS_UPCOMING","SET_STATUS_FILTER_TEMP_ITEMS","SET_PAYMENT_STATUS_FILTER_ITEMS","SET_ACTIVITY_FILTER_ITEMS","SET_SOURCE_FILTER_ITEMS","SET_BOOKABLE_TIMES","SET_CURRENT_LISTING_BOOKINGS","SET_CURRENT_LISTING_DISCOUNTABLE","SET_CURRENT_LISTING_MILE_ALLOWANCE","SET_CURRENT_LISTING_DURATION_DISCOUNT","TOGGLE_PAUSE_CURRENT_LISTING","SET_CURRENT_LISTING_CHECKOUT_MODE","SET_LISTING_PRICE_TYPE","SET_LISTING_PRICE_PERIOD","SET_LISTING_PRICE_STRUCTURE_ID","SET_VEHICLE_VIN","SET_VEHICLE_YEAR","SET_VEHICLE_MAKE","SET_VEHICLE_MODEL","SET_VEHICLE_COLOR","SET_VEHICLE_SEATS","SET_VEHICLE_DOORS","SET_VEHICLE_PLATE","SET_ALL_AVAILABLE_FEATURES","SET_VEHICLE_FEATURES","SET_VEHICLE_EXTRAS","SET_CURRENT_DECODED_VIN","SET_EXISTING_LISTING_DATA","SET_CURRENT_TRIP_EXTRA","SET_CURRENT_LISTING_IMAGES","SET_LISTING_AVAILABILITY_MESSAGE","SET_ALL_EXTRAS","SET_LISTING_FORM_ERRORS","CLEAR_LISTING_FORM_ERRORS","SET_LISTING_DAILY_PRICES","SET_FLEET_RESOURCE_LISTINGS","SET_FLEET_RESOURCE_LISTINGS_DATA","SET_CURRENT_LISTING_INCIDENTS","SET_LISTING_FILTER_OPTIONS","SET_CUSTODIAL_LISTING","SET_INIT","SET_TURO_LOADING","SET_TRIPS","SET_TRIP_SINGLE","SET_TURO_EMAILS","SET_TRIP_SINGLE_MESSAGES","SET_TRIP_SINGLE_IMAGES","SET_TURO_MESSAGE_SENDING","SET_TURO_ALL_VEHICLES","RESET_VEHICLES","SET_ALL_IMPORTED_TURO_VEHICLES","SET_TRIP_TURO_GO","SET_TURO_CONNECTIONS","SET_TURO_REIMBURSEMENT_DETAILS","RESET_TURO_CREDS","SET_TURO_CAPTCHA_TESTING","SET_TURO_CAPTCHA_ID","SET_TURO_EARNINGS","SET_TRIP_HISTORY","SET_TRIP_PENDING_REQUESTS","SET_ACTIVITY_FEED","SET_TURO_CHANGE_REQUEST_SETTINGS","SET_TURO_FEEDBACK","SET_TURO_FEEDBACK_PAGE","SET_TURO_FEEDBACK_NEXT_PAGE","SET_TURO_FEEDBACK_TOTAL","SET_TURO_FEEDBACK_PER_PAGE","SET_TURO_FEEDBACK_LAST_PAGE","SET_ALL_TURO_VEHICLES","CLEAR_ALL_TURO_VEHICLES","SET_ALL_TURO_MESSAGES","SET_ALL_TURO_MESSAGES_CURRENT_PAGINATE","SET_ALL_TURO_MESSAGES_TOTAL_PAGES","SET_TURO_EMAILS_PAGINATION","SET_TRIP_SINGLE_MESSAGES_STORED","SET_TURO_PRICING_LOADING","SET_TURO_VEHICLE_DAILY_PRICING","SET_TURO_PRICING_VEHICLES","SET_GETAROUND_INIT","SET_GETAROUND_LOADING","SET_GETAROUND_VEHICLES","SET_GETAROUND_CONNECTIONS","SET_GETAROUND_TRIPS","SET_GETAROUND_RESERVATION","SET_ALL_IMPORTED_GETAROUND_VEHICLES","SET_GETAROUND_RESERVATION_RECEIPT","SET_RENTERS_LOADING","SET_RENTER","SET_RENTERS","SET_ALL_RENTERS","SET_RENTERS_DIALOG","ADD_RENTER","RESET_RENTER","SET_PAYMENT_SOURCES","SET_BOOKING_PAYMENT","SET_PHONE_NUMBER","SET_SEARCHED_RENTERS","SET_STRIPE_CUSTOMER","CLEAR_RENTERS_FORM_ERROR","SET_RENTERS_CREDIT_CARDS","SET_RENTER_NOTIFICATIONS","SET_CUSTOMER_QUERY","SET_AUTOMATION_LOADING","SET_CURRENT_AUTOMATION_EVENT","SET_MESSAGE_TEMPLATES","SET_AUTOMATION_EVENTS","SET_CURRENT_EVENT_LOGS","SET_CART_LOADING","SET_CART","SET_CART_L_ID","SET_PAYMENTS_LOADING","SET_PAYMENT_METHODS","SET_INVOICES","SET_PAYMENT","SET_PAYMENTS","SET_CURRENT_WORKING_PAYMENT_ITEM","SET_CUSTOM_PAYMENT_METHODS","SET_STRIPE_INTENT","RESET_NEW_PAYMENT","SET_SUBSCRIPTION_LOADING","SET_SUBSCRIPTION","UPDATE_NEW_SUBSCRIPTION","SET_ENFORCE_SUBSCRIPTION","SET_SUBSCRIPTION_MASTER","SET_EXTRA_LISTINGS_ADDON","CLEAR_SUBSCRIPTION_FORM_ERRORS","SET_SUBSCRIPTION_FORM_ERROR","SET_SUBSCRIPTION_STEP","SET_PLAN_SELECTION","SET_SUBSCRIPTION_PLAN_AND_INTERVAL","SET_SU_LOADING","SET_ALL_USERS","SET_CURRENT_WORKING_USER","SET_ALL_ROLES","SET_ALL_PERMISSIONS","SET_ALL_COMPANIES","SET_CURRENT_WORKING_COMPANY","SET_ALL_MEDIA_DIRECTORIES","SET_ALL_MEDIA_IN_DIRECTORY","SET_MEDIA_BASE_PATH","SET_ALL_LISTING_IMAGES","SET_CURRENT_WORKING_SU_BASIC_STATS","SET_ALL_SERVER_DETAILS","SET_SA_FEATURE_WAITLIST","SET_SA_FEATURES_STATUS","SET_SA_CACHE","SET_TWILIO_LOADING","SET_VERIFY_CODE","SET_TESLA_INIT","CLEAR_TESLA_FORM_ERRORS","SET_TESLA_LOADING","SET_TESLA_CREDENTIALS","SET_TESLA_CONNECTIONS","UPDATE_TESLA_CONNECTION","SET_TESLA_VEHICLES","SET_TESLA_CHARGING_INVOICES","SET_TESLA_INVOICES","SET_TESLA_INVOICES_META","SET_TESLA_INVOICE_PDF","SET_CURRENT_WORKING_TESLA_VEHICLE","SET_CURRENT_WORKING_TESLA_VEHICLE_DRIVERS","SET_CURRENT_WORKING_TESLA_VEHICLE_HISTORY","SET_CURRENT_WORKING_TESLA_VEHICLE_HISTORY_PAGINATE","SET_TESLA_VEHICLE_INVITATIONS","SET_CURRENT_WORKING_TESLA_VEHICLE_APP_ACCESS","SET_CURRENT_WORKING_TESLA_VEHICLE_STATE","SET_CURRENT_WORKING_TESLA_VEHICLE_DATA","SET_CURRENT_WORKING_TESLA_ASLEEP","SET_BOUNCIE_INIT","SET_BOUNCIE_LOADING","SET_BOUNCIE_CONNECTIONS","SET_TEMPLATES_LOADING","RESET_TEMPLATE","SET_ALL_DOCUMENTS","SET_ONE_DOCUMENT","SET_ALL_TEMPLATES","SET_ONE_TEMPLATE","SET_ENVELOPE_LOADING","SET_ENVELOPE","SET_ALL_ENVELOPES","SET_ENVELOPE_SIGNATURE","SET_ALL_FIELDS","SET_ENVELOPE_DIALOG","SET_ENVELOPE_QUERY","SET_ENVELOPE_CUSTOMER","UPDATE_ENVELOPE_FIELD","SET_ESIGN_SESSION_DATA","SET_STRIPE_LOADING","SET_CURRENT_WORKING_INVOICE","SET_CURRENT_WORKING_PAYMENT_INTENT","SET_BILLING_PORTAL_SESSION","SET_STRIPE_PRICE_DATA","SET_SUBSCRIPTION_DETAILS","SET_STRIPE_IDENTITIES","SET_STRIPE_ACCOUNT","SET_SQUARE_LOADING","SET_MAINTENANCE_LOADING","SET_CURRENT_VEHICLE_MAINTENANCE","SET_CURRENT_VEHICLE_RECALLS","RESET_CURRENT_WORKING_MAINTENANCE_ITEM","SET_RIGHT_SIDEBAR_OPEN","SET_RIGHT_SIDEBAR_MODE","SET_RIGHT_SIDEBAR_TITLE","SET_CURRENT_WORKING_TOOL","SET_SELECTED_FIELD","SET_SELECTED_FIELD_V2","REMOVE_FIELD","REMOVE_ALL_FIELDS","SET_SELECTED_FIELD_INDEX_V2","SET_EXISTING_DATA","SET_NEW_DATA","SET_TOOLS_ACTIVE","SET_CANVAS_ACTIVE","RESET_TEMPLATE_DATA","SET_FIELD_CURRENT_SIGNER","SET_DOCUMENT_IMAGES","UPDATE_DOCUMENT_TEMPLATE_DATA","ADD_TO_DOCUMENT_TEMPLATE_DATA","SET_TAXES_LOADING","SET_TAX_CATEGORIES","SET_CURRENT_WORKING_TAX_CATEGORY","SET_TAX_CATEGORY_FORM_ERRORS","CLEAR_TAX_CATEGORY_FORM_ERRORS","RESET_CURRENT_WORKING_TAX_CATEGORY","SET_TENANT_CHECKOUT_DATES","SET_TENANT_CHECKOUT_LOCATION","SET_TENANT_CHECKOUT_DURATIONS","SET_TENANT_CHECKOUT_CUSTOM_ORDER_FIELDS","SET_TENANT_CHECKOUT_BOOKING_ID","SET_TENANT_CHECKOUT_CUSTOMER_TOS_AGREE","SET_TENANT_CHECKOUT_COSTS","SET_TENANT_CHECKOUT_LISTING_ID","SET_TENANT_CHECKOUT_CUSTOMERS","SET_TENANT_CHECKOUT_CUSTOMER_BY_INDEX","SET_TENANT_CHECKOUT_EXTRAS_V2","SET_TENANT_CHECKOUT_REQUIRED_EXTRAS_V2","SET_TENANT_CHECKOUT_REQUIRED_EXTRAS","SET_TENANT_CHECKOUT_DELIVERY_ADDRESS_FORM_SHOW","SET_TENANT_CHECKOUT_STRIPE_PAYMENT_INTENT","SET_TENANT_CHECKOUT_DIALOG","SET_TENANT_CHECKOUT_ORDER_DELIVERY_ADDRESS","SET_TENANT_CHECKOUT_ORDER_DISTANCE_ALLOWANCE","RESET_TENANT_CHECKOUT_DELIVERY_RESULTS","SET_TENANT_CHECKOUT_DELIVERY_RESULTS","SET_TENANT_CHECKOUT_DISCOUNT","RESET_TENANT_CHECKOUT_DISCOUNT","SET_TENANT_CHECKOUT_FORM_ERRORS","RESET_TENANT_CHECKOUT_FORM_ERRORS","SET_CHECKOUT_LOADING","CLEAR_CHECKOUT_FORM_ERRORS","SET_CHECKOUT_DISCOUNT","RESET_CHECKOUT_DISCOUNT","SET_ORDER_DELIVERY","SET_CHECKOUT_STRIPE","SET_CHECKOUT_AVAILABILITY","SET_CHECKOUT_INITIALIZED","SET_CHECKOUT_ORDER_CUSTOMER","SET_CHECKOUT_ORDER_CUSTOMER_BY_INDEX","SET_CHECKOUT_ORDER_CUSTOMER_AGREE_TOS","SET_CHECKOUT_ORDER_DATES","SET_CHECKOUT_ORDER_CUSTOM_FIELDS","SET_CHECKOUT_ORDER_DELIVERY_ADDRESS","SET_CHECKOUT_RENTER_AUTHENTICATED","SET_CHECKOUT_ORDER_REQUIRED_EXTRAS","SET_RESERVATION_REQUEST_LISTING_ID","SET_RESERVATION_REQUEST_DATES","SET_RESERVATION_REQUEST_DURATIONS","SET_RESERVATION_REQUEST_EXTRAS","SET_RESERVATION_REQUEST_EXTRAS_V2","SET_RESERVATION_REQUEST_REQUIRED_EXTRAS_V2","SET_RESERVATION_REQUEST_REQUIRED_EXTRAS_V2_AT_INDEX","SET_RESERVATION_REQUEST_PRICING","SET_COUPON_LOADING","SET_COUPONS","UPDATE_COUPON","SET_COUPON_REDEMPTIONS","CLEAR_COUPON_FORM_ERRORS","SET_COUPON_FORM_ERROR","SET_COUPON_FORM_BUSY","SET_NOTES_LOADING","SET_CUSTOM_FIELDS_LOADING","SET_CUSTOM_FIELDS","SET_CUSTOM_FIELDS_FORM_BUSY","SET_DEFAULT_PROPERTIES","CLEAR_DEFAULT_PROPERTIES_FORM","SET_DEFAULT_PROPERTIES_FORM_BUSY","SET_DEFAULT_PROPERTIES_FORM_ERRORS","SET_TOLLS_LOADING","SET_TOLL_AGENCIES","SET_TOLL_ACCOUNTS","SET_TOLL_AGENCIES_WISHLIST","SET_TOLL_TRANSACTIONS","SET_TOLL_TRANSPONDERS","SET_WHATS_NEW_LOADING","SET_WHATS_NEW_COUNT","SET_WHATS_NEW","MERGE_WHATS_NEW","SET_WHATS_NEW_IMAGES","SET_SHOW_WHATS_NEW_SIDEBAR","SET_COMPANY_BRANCHES","SET_COMPANY_BRANCH","SET_COMPANY_BRANCHES_LOADING","SET_ACTION_ITEMS","SET_ACTION_ITEM","ACTION_ITEM_CREATED","ACTION_ITEM_DELETED","SET_FLEET_FORM_ERROR","CLEAR_FLEET_FORM_ERRORS","SET_OUTDOORSY_LOADING","SET_OUTDOORSY_CONNECTIONS","SET_OUTDOORSY_LISTINGS","SET_OUTDOORSY_BOOKINGS","SET_HQRENTALS_LOADING","SET_HQRENTALS_CONNECTIONS","SET_HQRENTALS_LISTINGS","SET_HQRENTALS_BOOKINGS","SET_HQRENTALS_CONTACTS","SET_PROVIDERS_LOADING","SET_PAYMENT_PROVIDERS","SET_TURO_RESEARCH_LOADING","SET_TURO_ALL_DELIVERY_LOCATIONS","SET_TURO_ALL_VEHICLE_MAKES","SET_TURO_RESEARCH_SEARCH_LIST","SET_COMMISSION_PARTNER_LOADING","SET_COMMISSION_PARTNERS","SET_COMMISSION_PARTNER","SET_COMMISSIONS","CLEAR_COMMISSION_PARTNER_COUPON_FORM_ERRORS","SET_ORDERS_LOADING","SET_ORDER","UPDATE_ORDER_LINE","SET_ORDER_DOCUMENT","SET_ORDER_DOCUMENTS","SET_ORDER_DOCUMENT_DOWNLOAD_STATUS","SET_ORDER_AVAILABILITY","SET_OPEN_PRICING_WIZARD_DIALOG","SET_EMAILS_LOADING","SET_EMAILS","SET_EMAIL_HISTORY","SET_EMAIL_TEMPLATES","SET_EMAIL_TEMPLATE","SET_EMAIL_FORM_ERROR","CLEAR_EMAIL_FORM_ERRORS","SET_WEBHOOKS_LOADING","SET_WEBHOOKS_CONVERSATIONS","SET_WEBHOOK_ENDPOINTS","SET_WEBHOOK_ENDPOINT","SET_WEBHOOK_ENDPOINT_SECRET","SET_ANALYTICS_LOADING","SET_CONVERSION_ANALYTICS","SET_VEHICLE_ANALYTICS","SET_VEHICLES_ANALYTICS","SET_CUSTODIAN_LOADING","SET_CUSTODIANS","SET_CUSTODIAN_INVITE","SET_CUSTODIAN_LISTINGS","SET_CUSTODIAN_BOOKINGS","SET_PRICING_LOADING","SET_PRICING_RULES","SET_PRICING_STRUCTURE","SET_PRICING_STRUCTURES","RESET_CURRENT_WORKING_PRICING_STRUCTURE","SET_LULA_LOADING","SET_LULA_CONNECTIONS","SET_LULA_VEHICLES","SET_TWISTED_ROAD_LOADING","SET_TWISTED_ROAD_CONNECTIONS","SET_TWISTED_ROAD_VEHICLES","SET_FILES","MERGE_FILES","SET_FILES_PAGINATION","SET_FILES_LOADING","SET_BARCODE_LOADING","SET_BARCODE","SET_EXTRAS_LOADING","SET_EXTRAS","SET_TRIP_EXTRA_SETTING_DIALOG","SET_REQUIRED_EXTRA_ADD_EDIT_DIALOG","SET_REQUIRED_EXTRA_ADD_EDIT_DATA","SET_REGULAR_EXTRA_DIALOG","SET_EXTRA_LISTINGS_DIALOG","SET_REGULAR_EXTRA_DATA","SET_AXLE_LOADING","SET_AXLE","SET_AXLE_IGNITIONS","MERGE_AXLE_IGNITION","SET_INCOMING_AXLE_IGNITION","SET_STORE_THEMES","SET_STORE_THEME_DATA","SET_BRAINTREE_LOADING","SET_TAGS_LOADING","SET_TAGS","EventBus","args","emitter","deepCopy","obj","copy","key","arrayWrap","value","Errors","field","messages","fields","message","a","b","errors","Form","data","result","name","success","response","event","targetElement","setLoading","commit","commitName","subject","performApiRequest","loadingCommitName","apiCall","error","state","mutations","types.SET_AFFILIATE_LOADING","loading","types.SET_AFFILIATE","affiliate","types.SET_AFFILIATE_PAYOUTS","payouts","types.SET_AFFILIATE_FUTURE_PAYOUT","payout","types.SET_AFFILIATE_PAST_PAYOUT","types.SET_AFFILIATE_APPLICATION","application","actions","responseData","axios","_b","_a","push","affiliateModule","createUrlQueryString","params","removeEmpty","acc","buildNestedQueryString","parentKey","fullKey","arrayItem","queryString","createOrderUrlQueryString","subKey","formatQueryStringDate","date","dateWithHyphen","input","parts","year","newDate","dayjs","dateWithoutHyphen","format","month","day","formatQueryStringTime","time","hours","minutes","baseUrls","getBaseUrl","envOverride","types.SET_ANALYTICS_LOADING","types.SET_CONVERSION_ANALYTICS","analytics","types.SET_VEHICLE_ANALYTICS","types.SET_VEHICLES_ANALYTICS","query","e","TokenKey","RegisterTokenKey","MasqueradeKey","getToken","setToken","token","remember","options","removeToken","getRegisterId","checkMasquerade","masqueradeCookie","setMasquerade","masquerade","resolve","removeMasquerade","currentMasquerade","setRegisterToken","removeAllUserCookies","isChrome","isSafari","isFirefox","isOpera","SIDEBAR_STORAGE_KEY","DEBUG_STORAGE_KEY","appModule","types.SET_APP_LOADING","types.INITIALIZE_STATE","types.SET_APP_BOOTING","booting","types.TOGGLE_RIGHT_SIDEBAR","types.TOGGLE_SIDEBAR","types.SET_HOVERED_TURNOVER_BOOKING_ID","id","types.TOGGLE_LISTING_VIEW","types.TOGGLE_SECONDARY_IMPORT_NAV_VIEW","types.CLOSE_SIDEBAR","withoutAnimation","types.TOGGLE_DEVICE","device","types.SET_ALL_POSSIBLE_PERMISSIONS","permissions","types.SET_MASQUERADE_STATUS","types.SET_MASQUERADE","types.END_MASQUERADE","types.SET_FW_STRIPE_KEY","types.SET_FW_BUILD_NUMBER","build","types.SET_POLLED_FW_BUILD_NUMBER","existingBuild","types.SET_UPDATE_AVAILABLE","types.SET_APP_FEATURES","features","types.MARK_SETUP_ITEM_COMPLETE","index","types.SET_FEATURES_WAITLIST","types.SET_CURRENT_CURRENCY","currency","types.TOGGLE_DEBUG_DRAWER","types.TOGGLE_DEBUG_ON","debugOnValue","isDebugOn","code","formatNumberWithCommas","x","formatPhoneNumber","number","phone","parsePhoneNumber","elFactory","type","attributes","children","el","child","CardService","productCards","listing","lid","UtilService","listingCardActions","listingCardCartBtn","dataset","markup","closeBtn","quickView","fwOverlayState","listingName","listingPrice","listingImage","listingAvailLink","amount","get","quickViewToggle","elementToggle","datasetString","allowed","listings","card","cardElement","attr","title","linkText","isUndefined","imageElement","cardDescription","style","updateAmount","cardPrice","priceDetails","price","DatepickerService","COMPANY_URL","company","symbol","names","rules","pickup","until","found","element","defaultTime","pDiv","ids","products","product","url","script","parentWidth","o","width","listingId","times","startDate","startTime","endDate","endTime","CartService","isNumber","length","text","possible","i","CART_UUID","uuid","payload","emailRule","v","minLengthRule","minLength","codeRule","requiredRule","useAuth","store","useStore","authLoading","computed","authForm","apiTokens","user","saveToken","checkStripe","setAuthLoading","updateUserPassword","registrationFormRules","route","useRoute","router","useRouter","form","ref","showPassword","loginFail","loginFailMessage","redirect","twoFactorAuth","last2","isFormValid","isButtonDisabled","registerFormRules","togglePasswordVisibility","onBeforeMount","_c","watch","newQuery","redirectQuery","handleLoginResponse","redirectTo","err","login","handleLoginError","onMounted","saveRegisterId","register","guessTimeZone","getUserTimezone","calcMiles","dates","milesIncluded","maxDistance","allowance","generateReservationTimes","startHour","endHour","interval","selectedDate","allowPastTime","now","start","end","effectiveStart","minutesSinceStart","nextIntervalMinutes","timeValue","timeTitle","timezones","utc","timezone","editPreferences","countryOptions","registerId","removeRegisterId","countries","country","guessCountryData","regMissing","tellProps","ipData","dataFormatOptions","timeFormatOptions","intl","currenciesAsArray","uniqueCodes","prioritized","filtered","countriesAsArray","displayCountry","displayCurrency","displayDateFormat","displayTimeFormat","displayCountryFlag","getFlagEmoji","regFieldsMissing","countryCode","codePoints","char","inputChanged","completeRegister","json","isSet","isEmpty","getDefaultMeta","getMetaBooleanValue","trueIfMissing","meta","useCompany","companyToken","companySettings","defaultMeta","companyMeta","companyLoading","companyForm","originalCompany","companyLoaded","operatingRules","companyMetaForm","companyTrialOver","saveCompanyTimezone","companyAdditionalScripts","additionalStyles","companyFacebookPixelId","companyGoogleAnalyticsId","addDefaultMeta","fetchDefaultMeta","saveCompanyInfo","saveCompanyMeta","getActivityLog","showSetupChecklist","localizationDistanceUnits","localizationDistanceUnitsObject","setupCustomStyles","companyAdditionalStyle","customStyles","setupCustomScripts","companyAdditionalScript","customScripts","stripScripts","s","noscriptRegex","div","scripts","stripScript","scriptContent","employee","fetchEmployeeByInviteToken","invite_token","completeInvite","getters","errorMessage","submitButtonDisabled","send","show1","dispatch","formSubmitSuccess","reset","onBeforeUnmount","qs","_sfc_main","to","from","next","vm","_hoisted_1","_createElementBlock","_createElementVNode","_createVNode","_component_card","_ctx","_withCtx","_openBlock","_Fragment","_hoisted_2","_toDisplayString","_component_router_link","_createTextVNode","_hoisted_3","_hoisted_4","_hoisted_5","_hoisted_6","_hoisted_7","_cache","$event","_withModifiers","$options","_component_alert_success","_normalizeClass","_vModelText","_component_has_error","_component_v_button","guest","isAuthenticated","authRoutes","BaseLogin","Login","Register","RegisterNextStep","CompanyEmployeeInvite","PasswordRequest","PasswordReset","PasswordVerify","PasswordResend","BaseDashboard","__vitePreload","settingsRoutes","General","Pricing","Coupons","AdvancedPricing$1","PricingTemplate$1","PricingTemplateNew$1","PricingTemplateEdit$1","AdvancedPricingEdit$1","Taxes","Security","ApiToken","ActivityLog","AccountAndBilling","Team$1","CompanyNotifications","Email$1","EmailTemplateSingle$1","SubscriptionCheckout","Providers","PaymentProviders","SinglePaymentProvider$1","CommissionPartners","Webhooks","Create","UpdateWebhook$1","Checkout","OnlineReservations","EmployeesNew$1","Employees$1","FleetBase$1","FleetBranches","FleetBranchesNew","FleetBranchesSingle","FleetClass","FleetClassNew","FleetClassSingle","ActionItems$1","ActionItemNew$1","ActionItemSingle$1","FleetFeatures$1","AffiliateIndex","AffiliateSignup","AffiliatePayouts","Index$1","commission","mapGetters","mapActions","$data","_createBlock","_component_v_progress_circular","_createCommentVNode","_component_v_alert","_component_v_dialog","_component_v_card","_component_v_card_text","_component_v_progress_linear","listingManagerRoutes","ListingManagerConnect","_component_v_app","_Transition","_KeepAlive","_renderSlot","_component_router_view","irregularPlurals","pluralize","label","cleanedLabel","lowercaseLabel","plural","upperFirst","trimmed","snakeCase","truncate","trimmedValue","useTemplate","documentTemplates","documentsLoading","selectedFieldV2","template","allTools","currentWorkingTool","documentFieldData","toolsActive","templateDocument","documentImages","selectedFieldIndexV2","signerItems","documentFileName","templateStageData","templateDocumentImages","selectedFieldV3Coordinates","y","currentSigner","signer","fetchTemplates","setDocumentImages","images","setTool","toolUsed","updateStageData","removeAllStageData","addToStageData","setSingleTemplate","deleteSelectedElementsV2","updateSelectedField","setToolsActive","isActive","toggleRightSidebar","makeFieldId","characters","templateStageDataGroupedByPage","grouped","item","page","documentViewer","checkPermission","customStore","defaultStore","permission","useAppSettings","roles","setupItems","currentCurrency","polledBuildNumber","updateAvailable","appCurrentRouteName","debugDrawerOpen","sidebar","browser","secondaryNavViews","goBack","numberOfRoutes","isRouteMatch","routeName","condition","shouldSubMenuOpen","pageName","userHasRole","role","fetchBuildNumber","toggleSideBar","userHasPermission","updateSettings","settings","fetchCurrency","getSettings","toggleDebugDrawer","DeleteButton","defineAsyncComponent","_sfc_main$1g","currentTool","customer","conditionalRulesDialog","conditionalRules","possibleWhens","possibleRules","conditionalRulesRules","tool","t","selectedFieldType","selectedFieldTitle","allFieldsWithRules","dependentFields","fieldIds","rule","setupConditionalField","getActionItems","setConditionalRules","addConditionToRuleset","fieldIsDependant","toolDescription","findTool","allFieldsOrdered","availableFields","allowsReadOnly","_d","selectedElementAttributesRequiredField","selectedElementAttributesReadOnlyField","_hoisted_8","_hoisted_9","_hoisted_11","_hoisted_12","_hoisted_13","_hoisted_14","_hoisted_15","_hoisted_16","_hoisted_17","_hoisted_18","_hoisted_19","_hoisted_21","_hoisted_22","_hoisted_24","_hoisted_25","_hoisted_27","_hoisted_28","_hoisted_29","_hoisted_31","_hoisted_32","_hoisted_33","_hoisted_34","_hoisted_36","_hoisted_37","_hoisted_38","_hoisted_39","_hoisted_41","_hoisted_42","_hoisted_43","_hoisted_45","_hoisted_46","_hoisted_47","_hoisted_48","_directive_tippy","_resolveDirective","_component_v_btn","$setup","_component_v_icon","_component_v_card_title","_hoisted_10","_component_v_divider","_withDirectives","_component_v_switch","_hoisted_20","_hoisted_23","_component_v_text_field","_component_v_expansion_panels","_component_v_expansion_panel","_component_v_expansion_panel_title","_component_v_expansion_panel_text","_component_v_btn_toggle","_component_v_card_actions","_component_v_spacer","_component_delete_button","_hoisted_30","_component_v_select","_renderList","_hoisted_35","_hoisted_40","_hoisted_44","_hoisted_49","_hoisted_50","removeField","scrollToField","showFieldSearch","leftSidebarView","searchTool","currentSignerTools","tools","filteredTools","defaultProperties","dp","categorizedTools","category","truncateFieldName","pageFieldsOverviewClassObject","hasError","emit","__emit","toolbarHeight","documentLoading","isSaving","sampleRoute","backRoute","handleSave","toolbar","_sfc_main$1c","$props","isBetween","copyTextToClipboard","textToCopy","modal","modals","textArea","dialog","round","decimals","dragElement","pos1","pos2","pos3","pos4","dragMouseDown","closeDragElement","elementDrag","useESign","envelope","envelopeAttachments","getTemplate","updateTemplate","pageMarginY","content_main","useTemplateRef","dataEditor","documentUuid","standardDoc","standardDocCoords","contentMainWidth","contentMainHeight","contentLeftSidebarWidth","mainContentStartingXPosition","scrollTop","originalContentMainWidth","originalContentMainHeight","localDocumentImages","currentWorkingDataElement","elementOffsetX","elementOffsetY","dragHandlesOn","coordinateData","removeAllFieldsDialog","editorText","currentWorkingFieldId","currentWorkingTarget","handleScroll","target","getCanvasOffset","top","left","right","bottom","height","determineRelativeY","topPosition","pos","docImage","totalPages","relTopPos","relPosition","pageYGap","pageHeightAdjust","rightSidebarOpen","LeftAndRightDocumentMargin","pageViewRectangle","widthChange","documentStartingXPosition","objectRatioHeightRev","scaled","newHeight","savedHeight","tempScale","objectRatioWidthRev","newWidth","savedWidth","handleWindowResize","getSelectedElements","removeSelectedElements","f","handleKeyup","evt","removeSelectedItems","copySelectedElement","dropItems","elementIdsToRemove","d","moveSelectedElement","selected","moveStep","elementId","dataIndex","newX","newY","verifyElementXCoords","verifyElementYCoords","firstStagedData","customerDefaultProperties","toolWidthAdjusted","widthDifference","toolHeightAdjusted","objectRatioWidth","objectRatio","objectRatioHeight","reference","numericValue","templateNew","adjustDocumentContainerHeight","docHeight","p","adjustDataCoords","scrollToPage","pageIndex","pagePosition","handleKeydown","mainContent","standardDocCoordsRect","templateDocumentDimensions","templateDocumentDimensionRatio","h","w","ratio","adjust","determinePageNumber","documentWidth","finalY","documentHeight","currentPage","pageOffset","pageEndY","elementBottom","lastPageHeight","dropListener","theDeterminedY","adjustOriginalCoords","saveTemplate","documentImageHeight","pageTop","pageBottom","selectedElement","selectedElementData","newElement","checkCoords","formatJson","html","tippyContent","elementFillColor","elementClassObject","determineYTextOffset","determineDisplayFontSize","countCheckboxes","count","removeAllFields","signerElementClicked","onDocViewLoad","onImgLoad","removeDraggingEventListeners","signingElement","dragStartListener","dragOverListener","boundingRect","svgClicked","theId","oldTarget","initElementsDrag","selectElement","determineTextLines","words","rows","usedIndex","word","checkDroppable","targetParent","updateCoordinateDataForPage","contentMain","pageNumber","rect","offsetParent","calculateTextWidth","fontSize","addField","typeId","selectedTool","fieldId","baseWidth","adjustedWidth","adjustedHeight","startingX","startingY","originalDimensions","fieldData","applyConditionalFieldProperties","subscriptionMixin","lowerCase","find","stripeTrialDate","plans","planIndex","findIndex","months","totalBilled","limit","isNull","connections","each","topic","useDateFormatter","parsedDate","useMoneyFormatter","DEFAULT_CURRENCY_FORMAT","DEFAULT_CURRENCY_POSITION","DEFAULT_CURRENCY","fromCents","toCents","formatAmount","convertFromInt","formattedAmount","formatMoneyDisplayV2","getCompanyCurrency","position","getCompanyCurrencyFormatSettings","setCurrencyAndValue","symbolOrName","companyCurrencySymbol","companyMoneyTextInputSettings","formatMoney","useEnvelope","envelopes","envelopeLoading","envelopeDialogs","envelopeForm","envelopesQuery","envelopesPagination","totalRemainingFields","envelopeIsReady","allEnvelopeData","esignSessionData","esignEnvelopeDataCopy","envelopeCustomer","envelopeCustomerData","envelopeTemplate","envelopeTemplateDocuments","envelopeDocumentImages","envelopeDocumentDimensions","envelopeDocumentDimensionRatio","envelopeCompleted","envelopeCustomerCompleted","completedEnvelopeUrl","envelopeStatus","envelopeData","pageData","updated","filled","envelopeRequiredFields","envelopeSignatures","signatureCount","remainingRequiredFields","sendEnvelopeReminder","saveSignature","acceptAndSignEnvelope","setEnvelopeDialog","updateEnvelopeField","voidEnvelope","getEnvelopes","updateCustomerQuery","formatRentalDate","envelopesTotal","currentWorkingEnvelope","envelopInfoDialog","voidEnvelopeDialog","reminderDialog","currentWorkingEnvelopeRecipients","dataTableOptions","envelopeVoided","sendReminderReady","reminderData","r","itemsPerPageOptions","envelopesHeaders","newPage","newItemsPerPage","newSort","val","recipients","recipient","renterFullName","renter","renterId","envelopeStatusText","envelopeRecipientSignatures","attachmentImage","attachment","openInNewTab","hasPendingSigners","pendingSigners","openEnvelopInfoDialog","openVoidEnvelopeDialog","openReminderDialog","pendingSignersData","voidEnvelopeCommit","sendReminderInit","isSameOrBefore","useSubscription","enforceSubscription","customersLoading","hasActiveSubscription","subscriptionPlans","subscriptionPlan","subscription","stripeSubscriptionObject","subscriptionsLoading","subscriptionEndDate","hasPastDueSubscription","hasPausedSubscription","subscriptionFeatures","subscriptionStatus","stripeStatus","trialEndDateRaw","planIncludes","cancelSubscription","cancelSubscriptionStripePortal","endTrial","switchPlan","plan","resumeSubscription","addSubscriptionAddon","addon","removeSubscriptionAddon","trialEndsMessage","rawDate","trialDate","trialDateFmt","stripeEndDate","ends_at","inGracePeriod","status","inTrial","isTrialing","trialEndDate","currentStripeSubscriptionObjectRenewalDate","currentStripeSubscriptionObjectPlanAmount","currentStripeSubscriptionObjectPlanInterval","includedInSubscription","planFeatures","planIncludesApi","trialDaysLeft","daysLeft","trialDaysLeftPercent","trialDaysLeftMessage","trialDaysClass","currentPlanDetails","currentPlanBullets","seatLimitReached","seatLimitReachedMessage","listingLimitReachedMessage","listingLimitReached","planSupportedFeatureCounts","TemplatesTableList","_sfc_main$19","documentsTab","learnMoreDialog","dataTableOptionStatus","orderDocumentsHeaders","envelopesFilter","nameChangeErrors","ContractsTable","invoice","invoiceStatus","total","templatesPending","firstTemplate","_component_v_tabs","_component_v_tab","_component_v_window","_component_v_window_item","expanded","_component_v_fade_transition","_component_the_help_link","planIncludesESign","_component_TemplatesTableList","_component_ContractsTable","_component_v_data_table","orderDocuments","_component_TheHelpLink","thePhotosUploading","filesForS3","templateDocs","documentsUploadedSuccess","rejectedReasons","uploadUrls","getUploadUrl","file","extension","uploadUrl","uploadS3Init","filteredFiles","_","uploadS3","createAwsAxiosInstance","headers","filesPaths","awsAxios","uploadFileToS3","filePath","onDrop","acceptedFiles","rejectReasons","reason","uploadDocument","uploadUrlsClean","formData","getRootProps","getInputProps","isDragActive","useDropzone","useOrders","orderLoading","theNewOrder","orderDialogs","orderDocument","currentWorkingPricingWizardOrderLine","orderAvailability","updateOrderLine","deleteOrderDocument","setOrderDocument","checkOrderAvailability","orderUuid","getOrderItemModel","getOrderDocuments","getOrderDocument","updateOrderDocument","getNewOrder","addOrderLine","getOrder","updateNewOrder","setOrder","removeOrderLine","lineId","orderLines","open","lineItem","documentDate","addEditFooter","editDateDialog","editDocumentNumber","editUser","editReference","editorjs","footer","documentDataCopy","customerAddress","orderReference","documentNumber","updateFooter","outputData","documentTitle","documentBookingId","documentStatus","documentPaid","documentType","companyAddress","newValue","EditorJS","Header","document","convertBlocksToHtml","block","getTaxCategoryParentName","line","updateCustomerAddress","updateOrderDocumentDate","updateOrderDocumentNumber","updateOrderReference","document_uuid","deleteOrderDocumentConfirmDialog","orderBookingId","documentCanBeFinalized","finalizeDocumentInit","deleteOrderDocumentInit","deleteOrderDocumentCommit","printElem","downloadOrderDocumentInit","documentRoutes","Home","SingleDocument","navRightActions","NewDocument","DocumentsDashboardLayoutV2","AddFields","loadBaseDashboard","loadBasePerks","perksRoutes","notifications","DashboardLayout","BaseListings","NewListings","SingleListing","ListingCalendar","ListingAnalytics","AddNewListingNavAction","SaveListingNavAction","AddListingSaveNavAction","listingRoutes","_to","connectionsRoutes","BaseOrders","OrderNewV2","OrderSingleV2","TheRightSidebar","AddNewOrder","NewOrderOptions","SingleOrderOptions","ordersRoutes","BaseCustomers","CustomerSingle","CustomerRightSidebar","NewCustomer","ImportCustomers","AddNewCustomer","customerRoutes","_sfc_main$13","order","sections","orderedSections","dragula","source","handle","sectionId","blockId","disable","section","blocks","blockOrder","orderedBlocks","_hoisted_26","j","_sfc_main$12","selector","action","iframe","_sfc_render","LeftSideNav","ThemeTopNav","ThemeMainArea","_component_ThemeTopNav","_component_LeftSideNav","_component_ThemeMainArea","themeRoutes","ThemeBase","_sfc_main$10","_resolveComponent","Company","SingleTenantProduct2","TenantStoreBase2","companyRoutes","companyRoutes2","BaseCompanyIFrame","EsignRecipient","BaseESigner","eSignerRoutes","eSignerCompleteRoutes","superAdminRoutes","Quickstart","HomeDashboard","dashboardChildrenRoutes","dashboardRoutes","BaseAnalytics","ConversionAnalytics","VehicleAnalytics","analyticsRoutes","loadPay","payRoutes","BaseCompany","StripeRedirect","BraintreeRedirect","SquareRedirect","redirectRoutes","moduleRoutes","custodian","tripExtrasRoutes","notificationRoutes","commissionRoutes","constantRoutes","asyncRoutes","companyStore","SUPPORT_LOCALES","DEFAULT_LOCALE","locale","i18n","createI18n","enUS","es","zncn","str","loadMessages","importedMessages","Trans","newLocale","nextTick","persistedLocale","userPersistedLocale","userPreferredLocale","guessedLocale","Tr","checkAuth","userLoaded","auth","isLoggedIn","addDynamicRoutes","globalMiddleware","createRouter","createWebHistory","context","middleware","getMiddleware","middlewareNames","matchedRoutes","handleCompanyConnections","connection","authModule","types.SAVE_TOKEN","types.SAVE_REGISTER_ID","subscriptionMaster","extraListingsAddon","allPermissions","fwPublicStripeKey","counts","rootGetters","types.SET_AUTH_LOADING","email","Sentry.setUser","types.FETCH_USER_FAILURE","types.UPDATE_USER","types.LOGOUT","types.SET_TOKEN","types.SET_USER","types.SET_ROLES","types.SET_PERMISSIONS","types.SET_USER_NOTIFICATIONS","types.SET_USER_API_TOKENS","tokens","COMPANY_UUID_KEY","StorageService","types.SET_AUTOMATION_LOADING","types.SET_MESSAGE_TEMPLATES","messageTemplates","types.SET_CURRENT_AUTOMATION_EVENT","cloneDeep","types.SET_AUTOMATION_EVENTS","events","uniqBy","types.SET_CURRENT_EVENT_LOGS","logs","perPage","uuids","automations","types.SET_AXLE_LOADING","types.SET_AXLE","axle","types.SET_AXLE_IGNITIONS","ignitions","types.SET_INCOMING_AXLE_IGNITION","types.MERGE_AXLE_IGNITION","ignition","types.SET_BARCODE_LOADING","types.SET_BARCODE","barcode","duration","prepareBookingData","sortDesc","itemsPerPage","includeAbandoned","onlyAbandoned","withOrderProperties","withRenterProperties","searchTerm","searchTopic","exporting","providers","statuses","filter","sortBy","types.SET_BOOKING_LOADING","types.SET_BOOKING_DIALOG","types.CLEAR_BOOKING_FORM_ERRORS","form_field","types.SET_BOOKING_FORM_ERROR","types.SET_LISTING_ID","l_id","types.SET_STATUS_FILTER_ITEMS","types.SET_STATUS_FILTER_ITEMS_UPCOMING","types.SET_STATUS_FILTER_TEMP_ITEMS","types.SET_ACTIVITY_FILTER_ITEMS","activity","types.SET_SOURCE_FILTER_ITEMS","sources","types.SET_PAYMENT_STATUS_FILTER_ITEMS","types.SET_BOOKING_CART_ID","cartId","types.SET_CURRENT_WORKING_BOOKING","booking","types.SET_CURRENT_WORKING_BOOKING_STATUS","types.SET_CURRENT_WORKING_BOOKING_ATTRIBUTE","types.SET_BOOKING_NOT_FOUND","types.SET_BOOKINGS","bookings","types.SET_BOOKINGS_META","types.SET_ABANDONED_BOOKINGS","types.SET_PRIORITY_BOOKINGS","types.SET_FLEET_RESOURCES","types.SET_BOOKING_AUTOMATION_EVENTS","types.SET_TOTAL_BOOKINGS","types.SET_BOOKING_PAYMENTS","payments","types.MERGE_BOOKING_LINE_ITEM","types.UPDATE_BOOKING_LINE_ITEM","lineIndex","l","types.REMOVE_BOOKING_LINE_ITEM","remove","types.SET_FILTERED_MAKES","make","types.SET_CALENDAR_ATTRIBUTES","types.PUSH_CALENDAR_ATTRIBUTES","attribute","types.RESET_UNAVAILABLE_DATES","types.SET_UNAVAILABLE_DATES","createCalendarAttribute","barColor","days","startTimeBuffer","endTimeBuffer","middleDur","types.SET_BOOKING_LISTING","newPricing","types.SET_STORED_TURO_BOOKINGS","types.SET_CUSTOMER_BOOKING","types.SET_REMEMBER_CUSTOMER","types.RESET_BOOKING","b_id","qString","lastEnvelope","checkoutSession","_e","extension_uuid","types.SET_BOUNCIE_INIT","init","types.SET_BOUNCIE_LOADING","types.SET_BOUNCIE_CONNECTIONS","bouncie","vehicle","connIndex","c","types.SET_BRAINTREE_LOADING","braintree$1","PARTNER_UUID","CommissionPartnerService","types.SET_CART_LOADING","types.SET_CART_L_ID","types.SET_CART","cart","partnerUuid","subdomain","types.SET_CHECKOUT_LOADING","types.CLEAR_CHECKOUT_FORM_ERRORS","types.SET_CHECKOUT_DISCOUNT","coupon","types.RESET_CHECKOUT_DISCOUNT","types.SET_ORDER_DELIVERY","location","types.SET_CHECKOUT_INITIALIZED","initialized","types.SET_CHECKOUT_STRIPE","stripe","types.SET_CHECKOUT_AVAILABILITY","availability","types.SET_RESERVATION_REQUEST_LISTING_ID","types.SET_RESERVATION_REQUEST_DATES","types.SET_RESERVATION_REQUEST_DURATIONS","types.SET_RESERVATION_REQUEST_EXTRAS","extras","types.SET_RESERVATION_REQUEST_EXTRAS_V2","types.SET_RESERVATION_REQUEST_REQUIRED_EXTRAS_V2","types.SET_RESERVATION_REQUEST_REQUIRED_EXTRAS_V2_AT_INDEX","set","types.SET_RESERVATION_REQUEST_PRICING","dataKeys","costKeys","types.SET_CHECKOUT_ORDER_DATES","types.SET_CHECKOUT_ORDER_CUSTOMER","customers","types.SET_CHECKOUT_ORDER_CUSTOMER_BY_INDEX","types.SET_CHECKOUT_ORDER_CUSTOMER_AGREE_TOS","types.SET_CHECKOUT_ORDER_CUSTOM_FIELDS","types.SET_CHECKOUT_ORDER_DELIVERY_ADDRESS","address","types.SET_CHECKOUT_RENTER_AUTHENTICATED","types.SET_CHECKOUT_ORDER_REQUIRED_EXTRAS","map","paymentStrategy","paymentProvider","usesStripe","usesSquare","hasBalance","paymentIntentId","checkout","types.SET_COMMISSION_PARTNER_LOADING","types.SET_COMMISSION_PARTNERS","partners","types.SET_COMMISSION_PARTNER","partner","types.SET_COMMISSIONS","commissions","types.CLEAR_COMMISSION_PARTNER_COUPON_FORM_ERRORS","partner_uuid","commissionPartnerModule","defaultMetaValues","types.SET_COMPANY_LOADING","types.SET_COMPANY","types.SET_COMPANY_PHONE","types.SET_COMPANY_META","types.SET_COMPANY_SETTINGS","types.SET_COUNTS","types.SET_COMPANY_CURRENCY","types.SET_COMPANY_DEFAULT_META","types.SET_POSSIBLE_PERMISSIONS","types.SET_COMPANY_BOOKINGS","types.SET_COMPANY_EMPLOYEES","employees","types.SET_DELIVERY_LOCATIONS","locations","types.RESET_EMPLOYEE","types.SET_COMPANY_NOTIFICATIONS","uniqueIds","types.SET_EMPLOYEE_PERMISSIONS","types.SET_EMPLOYEE_ROLES","types.SET_COMPANY_EMPLOYEE","types.SET_OPERATING_RULES","types.SET_FEEDBACK_REVIEWS","reviews","types.SET_COMPANY_FORM_ERROR","types.SET_COMPANY_META_FORM_ERROR","types.CLEAR_COMPANY_META_FORM_ERRORS","companyName","cancellation","terms","inviteToken","returnData","deliveryLocation","review","companyModule","types.SET_COUPON_LOADING","types.SET_COUPONS","coupons","types.SET_COUPON_REDEMPTIONS","redemptions","types.UPDATE_COUPON","updatedCoupons","types.CLEAR_COUPON_FORM_ERRORS","types.SET_COUPON_FORM_ERROR","types.SET_COUPON_FORM_BUSY","busy","couponUuid","couponModule","types.SET_CUSTODIAN_LOADING","types.SET_CUSTODIANS","custodians","types.SET_CUSTODIAN_INVITE","invite","types.SET_CUSTODIAN_LISTINGS","types.SET_CUSTODIAN_BOOKINGS","custodian_id","custodian_uuid","types.SET_CUSTOM_FIELDS_LOADING","types.SET_CUSTOM_FIELDS","types.SET_CUSTOM_FIELDS_FORM_BUSY","customFields","types.SET_DEFAULT_PROPERTIES","defaultProperty","types.CLEAR_DEFAULT_PROPERTIES_FORM","types.SET_DEFAULT_PROPERTIES_FORM_BUSY","types.SET_DEFAULT_PROPERTIES_FORM_ERRORS","types.SET_TEMPLATES_LOADING","types.SET_ONE_DOCUMENT","types.SET_ALL_DOCUMENTS","documents","types.RESET_TEMPLATE","types.SET_ONE_TEMPLATE","types.SET_ALL_TEMPLATES","templates","document$1","types.SET_EMAILS_LOADING","types.SET_EMAILS","emails","types.SET_EMAIL_HISTORY","types.SET_EMAIL_TEMPLATES","types.SET_EMAIL_TEMPLATE","types.SET_EMAIL_FORM_ERROR","types.CLEAR_EMAIL_FORM_ERRORS","_f","emailTemplate","types.SET_EMAIL_DOMAIN_SETTINGS","domains","domain","emailDomainSettings","types.SET_ENVELOPE_LOADING","types.SET_ESIGN_SESSION_DATA","types.SET_ALL_ENVELOPES","types.SET_ENVELOPE","types.SET_ENVELOPE_SIGNATURE","signature","types.SET_ENVELOPE_CUSTOMER","types.UPDATE_ENVELOPE_FIELD","fieldIndex","types.SET_ALL_FIELDS","types.SET_ENVELOPE_DIALOG","types.SET_ENVELOPE_QUERY","recipientId","recipientKey","sample","queryParams","requestPath","customerData","queryObject","types.SET_FILES_LOADING","types.SET_FILES","files","types.SET_FILES_PAGINATION","pagination","newPagination","types.MERGE_FILES","uniqueFiles","mergedFiles","isUnique","types.SET_COMPANY_BRANCHES_LOADING","types.SET_COMPANY_BRANCHES","branches","types.SET_COMPANY_BRANCH","branch","types.SET_ACTION_ITEMS","items","types.SET_ACTION_ITEM","types.ACTION_ITEM_CREATED","types.ACTION_ITEM_DELETED","types.SET_FLEET_FORM_ERROR","types.CLEAR_FLEET_FORM_ERRORS","actionItem","fleet","types.SET_GETAROUND_INIT","types.SET_GETAROUND_LOADING","types.SET_GETAROUND_CONNECTIONS","types.SET_GETAROUND_VEHICLES","vehicles","types.SET_GETAROUND_TRIPS","trips","types.SET_GETAROUND_RESERVATION","reservation","types.SET_GETAROUND_RESERVATION_RECEIPT","receipt","types.SET_ALL_IMPORTED_GETAROUND_VEHICLES","GetaroundState","gaid","ga","reservation_id","getaround","types.SET_HQRENTALS_LOADING","types.SET_HQRENTALS_CONNECTIONS","types.SET_HQRENTALS_LISTINGS","types.SET_HQRENTALS_BOOKINGS","types.SET_HQRENTALS_CONTACTS","contacts","credentials","provider","provider_uuid","hqRentals","PaymentsModule","types.SET_PAYMENTS_LOADING","types.SET_PAYMENT","payment","types.SET_PAYMENTS","types.SET_PAYMENT_METHODS","payment_methods","types.SET_CURRENT_WORKING_PAYMENT_ITEM","types.SET_CUSTOM_PAYMENT_METHODS","methods","types.SET_STRIPE_INTENT","types.RESET_NEW_PAYMENT","payment_id","paymentIntent","capture","refund","state2","defaultSettings","showSettings","tagsView","fixedHeader","sidebarLogo","types.SET_SETTINGS_LOADING","types.SET_NOTIFICATION_SETTINGS","downloadUrl","link","types.SET_NOTES_LOADING","types.SET_STORE_THEMES","types.SET_STORE_THEME_DATA","theme","locales","types.SET_LOCALE","lang","defaultVehicle","setFilterValues","filterKey","dataKey","types.SET_LISTING_LOADING","types.SET_LISTING_SNACK","snack","types.SET_LISTING_DIALOG","types.SET_LISTING_FILTER_AVAILABLE_FILTERS","types.SET_LISTING_FILTER_SELECTED_FILTERS","types.TOGGLE_LISTING_FILTER","types.CLEAR_LISTING_FILTER","types.SET_LISTING","types.SET_LISTING_INIT","isInit","types.SET_ALL_LISTINGS","types.SET_BOOKABLE_TIMES","types.SET_CUSTODIAL_LISTING","types.SET_FLEET_RESOURCE_LISTINGS","types.SET_FLEET_RESOURCE_LISTINGS_DATA","types.SET_VEHICLE_VIN","vin","types.SET_CURRENT_LISTING_INCIDENTS","incidents","types.SET_LISTING_FILTER_OPTIONS","filterOptions","types.SET_VEHICLE_YEAR","types.SET_LISTING_PRICE_TYPE","types.SET_LISTING_PRICE_PERIOD","types.SET_LISTING_PRICE_STRUCTURE_ID","types.SET_ALL_AVAILABLE_FEATURES","types.SET_VEHICLE_EXTRAS","types.SET_VEHICLE_FEATURES","feature","types.SET_VEHICLE_MAKE","types.SET_VEHICLE_MODEL","types.SET_VEHICLE_COLOR","color","types.SET_VEHICLE_SEATS","seats","types.SET_VEHICLE_DOORS","doors","types.SET_VEHICLE_PLATE","plate","types.SET_VEHICLE_CLASS","types.TOGGLE_PAUSE_CURRENT_LISTING","types.SET_CURRENT_LISTING_CHECKOUT_MODE","mode","types.SET_CURRENT_DECODED_VIN","vehicleData","types.SET_EXISTING_LISTING_DATA","types.SET_CURRENT_NEW_LISTING","types.SET_CURRENT_LISTING","allListingIndex","types.SET_CURRENT_LISTING_BOOKINGS","types.SET_CURRENT_LISTING_MILE_ALLOWANCE","types.SET_CURRENT_LISTING_DISCOUNTABLE","discountable","types.SET_CURRENT_LISTING_DURATION_DISCOUNT","discount","types.SET_CURRENT_TRIP_EXTRA","types.SET_ALL_EXTRAS","types.SET_LISTING_PRICE","types.SET_LISTING_VEHICLE","types.SET_LISTING_PRICE_TAXABLE","taxable","types.SET_LISTING_PRICE_TAX_CATEGORY","tax_category","types.SET_LISTING_SEC_DEP","types.SET_LISTING_SEC_DEP_CREDIT","types.SET_LISTING_SEC_DEP_DEBIT","types.SET_LISTING_MILES_OVERAGE","types.SET_CURRENT_LISTING_IMAGES","types.SET_LISTING_AVAILABILITY_MESSAGE","types.SET_LISTING_DAILY_PRICES","prices","types.CLEAR_LISTING_FORM_ERRORS","types.SET_LISTING_FORM_ERRORS","types.RESET_CURRENT_LISTING","refresh","statusCode","period","turo_uuid","bouncie_uuid","image","startTimes","timeF","ampm","lefZero","listingModule","types.SET_LULA_LOADING","types.SET_LULA_CONNECTIONS","types.SET_LULA_VEHICLES","lula","notable_type","notable_id","note","notes","types.SET_OUTDOORSY_LOADING","types.SET_OUTDOORSY_CONNECTIONS","types.SET_OUTDOORSY_LISTINGS","types.SET_OUTDOORSY_BOOKINGS","outdoorsy","outdoorsy_uuid","canAccess","hasRole","hasPermission","filterAsyncRoutes","routes","res","tmp","types.SET_ROUTES","accessedRoutes","types.SET_PRICING_LOADING","types.SET_PRICING_RULES","types.SET_PRICING_STRUCTURES","types.SET_PRICING_STRUCTURE","types.RESET_CURRENT_WORKING_PRICING_STRUCTURE","ruleData","pricing","types.SET_PROVIDERS_LOADING","types.SET_PAYMENT_PROVIDERS","paymentProfile","types.SET_RENTERS_LOADING","types.SET_RENTERS","types.SET_ALL_RENTERS","renters","types.SET_RENTERS_DIALOG","types.SET_RENTER","types.ADD_RENTER","renterIndex","types.RESET_RENTER","types.SET_RENTERS_CREDIT_CARDS","cards","types.SET_PAYMENT_SOURCES","types.SET_BOOKING_PAYMENT","charge","types.SET_PHONE_NUMBER","types.SET_SEARCHED_RENTERS","types.CLEAR_RENTERS_FORM_ERROR","types.SET_STRIPE_CUSTOMER","stripe_customer","types.SET_RENTER_NOTIFICATIONS","types.SET_CUSTOMER_QUERY","r_id","paymentMethod","types.SET_SQUARE_LOADING","squareId","square","subscriptionNameMap","subscriptionName","subEndDate","types.SET_SUBSCRIPTION_LOADING","types.SET_ENFORCE_SUBSCRIPTION","enforce","types.SET_SUBSCRIPTION_STEP","step","types.SET_SUBSCRIPTION_PLAN_AND_INTERVAL","updatedSubscription","types.SET_PLAN_SELECTION","selection","types.SET_SUBSCRIPTION","types.UPDATE_NEW_SUBSCRIPTION","newSubscription","types.SET_SUBSCRIPTION_MASTER","types.SET_EXTRA_LISTINGS_ADDON","types.CLEAR_SUBSCRIPTION_FORM_ERRORS","types.SET_SUBSCRIPTION_FORM_ERROR","sub","subscriptions","types.SET_SU_LOADING","types.SET_ALL_USERS","users","types.SET_ALL_COMPANIES","companies","types.SET_CURRENT_WORKING_COMPANY","types.SET_CURRENT_WORKING_USER","types.SET_ALL_ROLES","types.SET_ALL_PERMISSIONS","types.SET_ALL_MEDIA_DIRECTORIES","mediaDirectories","types.SET_ALL_MEDIA_IN_DIRECTORY","media","types.SET_MEDIA_BASE_PATH","path","types.SET_ALL_LISTING_IMAGES","types.SET_ALL_SERVER_DETAILS","details","types.SET_SA_FEATURE_WAITLIST","waitlist","types.SET_SA_FEATURES_STATUS","types.SET_SA_CACHE","cache","types.SET_CURRENT_WORKING_SU_BASIC_STATS","stats","getFleetwirePartner","urlParams","directory","string","superAdmin","view","tag","types.SET_TAXES_LOADING","types.SET_TAX_CATEGORIES","tax","types.SET_CURRENT_WORKING_TAX_CATEGORY","types.SET_TAX_CATEGORY_FORM_ERRORS","types.CLEAR_TAX_CATEGORY_FORM_ERRORS","types.RESET_CURRENT_WORKING_TAX_CATEGORY","taxCategory","taxes","types.SET_MAINTENANCE_LOADING","types.SET_CURRENT_VEHICLE_MAINTENANCE","maintenance","types.SET_CURRENT_VEHICLE_RECALLS","recalls","types.RESET_CURRENT_WORKING_MAINTENANCE_ITEM","maintenanceItem","types.SET_ORDERS_LOADING","types.SET_ORDER","types.UPDATE_ORDER_LINE","lines","types.SET_ORDER_DOCUMENTS","types.SET_ORDER_DOCUMENT","types.SET_ORDER_DOCUMENT_DOWNLOAD_STATUS","types.SET_ORDER_AVAILABILITY","types.SET_OPEN_PRICING_WIZARD_DIALOG","types.SET_STRIPE_LOADING","types.SET_CURRENT_WORKING_INVOICE","types.SET_CURRENT_WORKING_PAYMENT_INTENT","intent","types.SET_BILLING_PORTAL_SESSION","types.SET_STRIPE_PRICE_DATA","types.SET_STRIPE_IDENTITIES","types.SET_SUBSCRIPTION_DETAILS","types.SET_STRIPE_ACCOUNT","types.SET_CURRENT_STRIPE_CHARGE","types.SET_INVOICES","invoices","invoice_id","charge_id","intent_id","payment_method","vsId","types.SET_FIELD_CURRENT_SIGNER","types.SET_TOOLS_ACTIVE","active","types.SET_CANVAS_ACTIVE","types.SET_RIGHT_SIDEBAR_OPEN","types.SET_RIGHT_SIDEBAR_MODE","types.SET_RIGHT_SIDEBAR_TITLE","types.SET_CURRENT_WORKING_TOOL","types.SET_SELECTED_FIELD","types.SET_SELECTED_FIELD_V2","types.REMOVE_FIELD","types.REMOVE_ALL_FIELDS","types.SET_SELECTED_FIELD_INDEX_V2","types.UPDATE_DOCUMENT_TEMPLATE_DATA","types.ADD_TO_DOCUMENT_TEMPLATE_DATA","types.SET_EXISTING_DATA","types.SET_NEW_DATA","types.RESET_TEMPLATE_DATA","types.SET_DOCUMENT_IMAGES","types.SET_TESLA_INIT","types.CLEAR_TESLA_FORM_ERRORS","types.SET_TESLA_LOADING","types.SET_TESLA_CREDENTIALS","types.SET_TESLA_CONNECTIONS","types.UPDATE_TESLA_CONNECTION","tesla","types.SET_TESLA_VEHICLES","types.SET_CURRENT_WORKING_TESLA_VEHICLE","types.SET_CURRENT_WORKING_TESLA_VEHICLE_DRIVERS","drivers","types.SET_CURRENT_WORKING_TESLA_VEHICLE_HISTORY","chargingHistory","types.SET_CURRENT_WORKING_TESLA_VEHICLE_HISTORY_PAGINATE","paginate","types.SET_TESLA_VEHICLE_INVITATIONS","invites","types.SET_TESLA_CHARGING_INVOICES","types.SET_TESLA_INVOICES","types.SET_TESLA_INVOICES_META","types.SET_TESLA_INVOICE_PDF","pdf","types.SET_CURRENT_WORKING_TESLA_ASLEEP","asleep","types.SET_CURRENT_WORKING_TESLA_VEHICLE_APP_ACCESS","types.SET_CURRENT_WORKING_TESLA_VEHICLE_STATE","vehicleState","types.SET_CURRENT_WORKING_TESLA_VEHICLE_DATA","vehicle_uuids","tesla_uuid","types.SET_TOLLS_LOADING","types.SET_TOLL_AGENCIES","tolls","types.SET_TOLL_ACCOUNTS","types.SET_TOLL_AGENCIES_WISHLIST","types.SET_TOLL_TRANSACTIONS","transactions","types.SET_TOLL_TRANSPONDERS","transponders","tollAccount","transaction","tripExtrasModule","types.SET_EXTRAS_LOADING","types.SET_EXTRAS","types.SET_TRIP_EXTRA_SETTING_DIALOG","types.SET_REQUIRED_EXTRA_ADD_EDIT_DIALOG","types.SET_REQUIRED_EXTRA_ADD_EDIT_DATA","types.SET_REGULAR_EXTRA_DATA","types.SET_REGULAR_EXTRA_DIALOG","types.SET_EXTRA_LISTINGS_DIALOG","extra","types.SET_INIT","types.SET_TURO_LOADING","types.SET_VEHICLES","types.SET_ALL_TURO_VEHICLES","types.CLEAR_ALL_TURO_VEHICLES","types.SET_TURO_EMAILS","types.SET_TURO_EMAILS_PAGINATION","types.RESET_VEHICLES","types.SET_TURO_EARNINGS","earnings","types.SET_TURO_FEEDBACK","types.SET_TURO_FEEDBACK_PAGE","types.SET_TURO_FEEDBACK_TOTAL","types.SET_TURO_FEEDBACK_NEXT_PAGE","types.SET_TURO_FEEDBACK_PER_PAGE","per_page","types.SET_TURO_FEEDBACK_LAST_PAGE","last_page","types.SET_TRIPS","trip","types.SET_TRIP_SINGLE","types.SET_TRIP_SINGLE_MESSAGES","types.SET_TRIP_SINGLE_MESSAGES_STORED","types.SET_TRIP_SINGLE_IMAGES","types.SET_TURO_MESSAGE_SENDING","sending","types.SET_TURO_ALL_VEHICLES","types.SET_ALL_IMPORTED_TURO_VEHICLES","types.SET_TRIP_TURO_GO","types.SET_TURO_CONNECTIONS","types.SET_TURO_REIMBURSEMENT_DETAILS","types.RESET_TURO_CREDS","types.SET_TURO_CAPTCHA_ID","types.SET_TURO_CAPTCHA_TESTING","testing","types.SET_TRIP_HISTORY","history","types.SET_TRIP_PENDING_REQUESTS","requests","types.SET_ACTIVITY_FEED","types.SET_TURO_CHANGE_REQUEST_SETTINGS","types.SET_ALL_TURO_MESSAGES","types.SET_ALL_TURO_MESSAGES_CURRENT_PAGINATE","types.SET_ALL_TURO_MESSAGES_TOTAL_PAGES","pages","TuroState","turo","pending","feedback","turo_uuids","uniq","accounts","vehicle_id","vehicle_uuid","tripId","types.SET_TURO_PRICING_LOADING","types.SET_TURO_PRICING_VEHICLES","listed","types.SET_TURO_VEHICLE_DAILY_PRICING","vehicleId","vehicleIndex","slice","flatMap","turoPricing","types.SET_TURO_RESEARCH_LOADING","types.SET_TURO_ALL_VEHICLE_MAKES","makes","types.SET_TURO_ALL_DELIVERY_LOCATIONS","types.SET_TURO_RESEARCH_SEARCH_LIST","list","turoResearch","types.SET_TWILIO_LOADING","types.SET_VERIFY_CODE","stripe_id","twilio","types.SET_TWISTED_ROAD_LOADING","types.SET_TWISTED_ROAD_CONNECTIONS","types.SET_TWISTED_ROAD_VEHICLES","account","twistedRoad","types.SET_VEHICLES_LOADING","types.SET_VEHICLE_MAKES","types.SET_VEHICLE_MODELS","models","types.SET_VEHICLE_CLASS_CREATED","types.SET_VEHICLE_CLASSES","classes","vehicleClass","types.SET_VEHICLE_FORM_ERRORS","types.CLEAR_VEHICLE_FORM_ERRORS","v_id","types.SET_WHATS_NEW_LOADING","types.SET_WHATS_NEW_COUNT","types.SET_SHOW_WHATS_NEW_SIDEBAR","isShown","types.SET_WHATS_NEW_IMAGES","types.SET_WHATS_NEW","whatsNewPaginateObject","types.MERGE_WHATS_NEW","whatsNew","wnIndex","allPages","types.SET_WEBHOOKS_LOADING","types.SET_WEBHOOK_ENDPOINTS","webhookEndpoints","types.SET_WEBHOOK_ENDPOINT","webhookEndpoint","types.SET_WEBHOOKS_CONVERSATIONS","conversations","types.SET_WEBHOOK_ENDPOINT_SECRET","secret","webhook_uuid","webhook","conversation","tenantCheckoutModule","types.SET_TENANT_CHECKOUT_DATES","types.SET_TENANT_CHECKOUT_LOCATION","types.SET_TENANT_CHECKOUT_DELIVERY_ADDRESS_FORM_SHOW","types.SET_TENANT_CHECKOUT_STRIPE_PAYMENT_INTENT","types.SET_TENANT_CHECKOUT_DIALOG","types.SET_TENANT_CHECKOUT_DURATIONS","types.SET_TENANT_CHECKOUT_BOOKING_ID","types.SET_TENANT_CHECKOUT_CUSTOM_ORDER_FIELDS","types.SET_TENANT_CHECKOUT_CUSTOMER_TOS_AGREE","types.SET_TENANT_CHECKOUT_COSTS","types.SET_TENANT_CHECKOUT_LISTING_ID","types.SET_TENANT_CHECKOUT_CUSTOMER_BY_INDEX","types.SET_TENANT_CHECKOUT_CUSTOMERS","types.SET_TENANT_CHECKOUT_EXTRAS_V2","types.SET_TENANT_CHECKOUT_REQUIRED_EXTRAS_V2","types.SET_TENANT_CHECKOUT_REQUIRED_EXTRAS","types.SET_TENANT_CHECKOUT_ORDER_DELIVERY_ADDRESS","types.SET_TENANT_CHECKOUT_ORDER_DISTANCE_ALLOWANCE","types.RESET_TENANT_CHECKOUT_DELIVERY_RESULTS","types.SET_TENANT_CHECKOUT_DELIVERY_RESULTS","types.SET_TENANT_CHECKOUT_DISCOUNT","types.RESET_TENANT_CHECKOUT_DISCOUNT","types.SET_TENANT_CHECKOUT_FORM_ERRORS","types.RESET_TENANT_CHECKOUT_FORM_ERRORS","TenantCheckoutState","notingDueToday","sessionId","types.SET_TAGS_LOADING","types.SET_TAGS","tags","forType","tagsModule","createStore","app","braintree","commissionPartners","tenantCheckout","tripExtras","TheDefaultLayout","layoutMap","layoutComponent","layoutName","resolvedLayout","vuetify","createVuetify","initGtag","VueGtag","initSentry","Sentry.init","hint","Sentry.vueIntegration","Sentry.browserTracingIntegration","Sentry.replayIntegration","Sentry.replayCanvasIntegration","request","registerLayouts","layouts","layoutImporter","component","componentName","extractFileName","notivue","createNotivue","createApp","App","VueTippy","VCalendar","VueDragula","checkRole","requiredRoles","useAppFeatures","appFeatures","featureWaitlist","canFilterByPaymentStatus","canUseSquareIntegration","canUseBraintreeIntegration","hasAxleIntegrationFeature","hasPricingTemplateFeature","hasStoreThemesFeature","hasRenterBlockFeature","hasWaitlistRequest","addFeatureWaitlist","getFeatureWaitlist","CompanyInformation","useBranch","mapboxScriptIsReady","ACCESS_TOKEN","props","__props","dense","singleLineAddress","toRefs","expandForm","address2","setupMapBox","autofillCollection","minimap","lnglat","geometry","locationData","singleLine","useTaxAndFee","taxCategories","taxForm","taxCategoryLoading","VEHICLE_STATUSES","mapToTitleCodeArray","array","useListing","initialListing","isLoading","isLoaded","newListing","initializeWithCurrentListing","currentListing","updateListing","updates","errorData","updateField","resetListing","availableVehicleStatuses","listingInit","listingLoading","listingForm","originalListing","currentListingBookings","dailyPricing","listingSnacks","allVehicleFeatures","allListingsInit","fleetResourceListings","visibleListings","currentListingDailyPricing","listingExtras","listingDialogs","setListingDialog","allListingsAreArchived","setUnavailablePeriod","currentListingVehicleOdometer","currentListingVehicleStatus","currentListingVehicleId","resetCurrentListing","fetchDailyPrices","fetchCompanySingleListingExtras","updateVehicleDetails","getVehicleFeatures","fetchListings","addListing","setCurrentNewListing","allowsSecondaryDriver","listingLevel","companyLevel","saveListing","fetchCompanySingleListings","pauseListing","deleteListingImage","imageId","deleteListing","archiveListing","updateListingImageOrder","fetchFleetResourcesListings","getVehicleIncidents","resetAndReImportCarShareImages","fetchAgencySingleListingBookings","getListingPublicLink","listingVehicleStatus","theStatus","listingNameDisplay","characterLimit","currentListingAgeRequirements","currentListingName","currentListingVehicleUnitId","currentListingDescription","currentListingVehicleVin","currentListingVehicleYear","currentVehicleFeatures","currentListingVehicleMake","currentListingVehicleModel","currentListingVehicleColor","currentListingVehicleNumberOfSeats","currentListingVehicleNumberOfDoors","currentListingVehiclePlate","currentListingVehicleClass","currentListingVehicleClassName","listingVehicleHasRemoteCapability","listingVehicleHasConnectedBouncie","listingVehicleImages","listingVehicleImage","placeHolder","singleListingImage","listingVehicleDoorsDisplay","listingVehicleSeatsDisplay","listingVehicleYearMakeModelDisplay","listingVehicleYearDisplay","listingVehicleMakeDisplay","listingVehicleModelDisplay","listingDescriptionDisplay","listingClass","listingClassNameDisplay","listingPeriodDisplay","listingPriceDisplay","listingVehicleDetailsDisplay","currentListingChanges","originalClone","currentClone","listingChanges","differences","propertiesToDelete","prop","matchAListing","providerAutoMatchedBy","theMatchedListing","unitId","matchByVin","matchByUnitId","workingVin","listingVehicleVINDisplay","workingUnitId","listingFilter","itemTitle","queryText","searchText","raw","k","last4","useDefaultMeta","keys","reactive","getValue","config","fallback","initialize","fetchSession","updateDefaultMeta","displayPriceAdjustmentValue","validators","adjustmentRules","handlePriceAdjustmentUpdate","storedValue","newMode","oldMode","currentValue","newAmountInCents","newPercent","appCurrencies","currentLocalCurrency","currencyExample","example","currencyDisplay","currencyPosition","newCompany","useCoupons","couponLoading","couponForm","couponRedemptions","useCouponForm","couponClone","currentCouponListings","currentCouponUsersOn","currentCouponUsers","couponLimit","couponFormValid","currentCouponAmount","couponRules","UpgradePlanFeatureDialog2","CustomerPopoverMenu","FeatureTitle","fetchCoupons","createCoupon","updateCoupon","deleteCoupon","getCouponRedemptions","clearCoupons","resetForm","updateListings","updateUserLimit","couponDialog","search","couponTab","couponDialogMode","couponDialogTitle","confirmCouponDelete","selectedCoupons","importCouponsDialog","listingsClone","confirmMultiCouponToggle","orderHeaders","couponsFiltered","currentCouponReasonEllipsis","couponsExist","wantsAllListings","wantsSomeListings","classObject","deleteCouponCommit","createCouponCommit","updateCouponCommit","addCoupon","editCode","hasNoListings","hasAllListings","importCoupons","currentCouponListingsUpdate","currentCouponUserUpdate","toggle","removeListing","formatBookingDate","bookingDate","tab","ListingAutocompleteDropdown","_component_v_chip","_component_v_menu","_mergeProps","_component_v_list","_component_v_list_item","_component_v_list_item_title","_component_v_radio_group","_component_v_radio","_component_v_checkbox","_component_v_autocomplete","_component_ListingAutocompleteDropdown","_sfc_main$T","PricingRuleDialog","_component_v_card_subtitle","pricingRules","_component_PricingRuleDialog","_component_v_table","structure","_sfc_main$R","lastUnit","durationUnit","quantity","tier","multiplier","examplePrice","newPrice","resultingPrice","tiers","_sfc_main$Q","_component_DeleteButton","_sfc_main$P","pricingRule","_component_tippy","pricingRulesLoading","TheTaxes","getTaxCategories","ChangePassword","TwoFactorAuth","fetchUserTokens","createUserTokens","deleteApiToken","showInitialTokenDialog","newToken","copiedText","tokenDeletedSnack","copyToClipboardInit","createUserTokensInit","deleteApiTokenInit","getActivityLogInit","upgradeDialogIsOpen","featureStep","safeFeatureStep","stepDescription","stepImage","stepSecondDescription","featureListStyle","newVal","useStripe","stripeLoading","stripeAccounts","stripePrices","fetchStripeAccounts","fetchStripeCapabilities","saveStripeKey","resetStripeKey","testStripeIdentity","fetchSubscriptionDetails","fetchStripePriceData","fetchCheckoutUrl","formatDate","stripeIdentityName","identity","firstName","lastName","stripeIdentityDOB","dob","formattedDate","stripeIdentityStatus","stripeIdentityVSId","stripeIdentityErrors","stripeIdentityUrl","stripeIdentityDocumentNumber","stripeIdentityDocumentExpiration","expiration","stripeIdentityAddress","stripeInstance","publishableKey","reject","DeleteAccountSection","CardOnFileCard","RenewsOneCard","PlanPriceCard","shouldShowUpsellCard","cardBrand","cardLastFour","defaultPayment","trialDaysLeftWithDay","usePayments","paymentMethods","paymentsLoading","billingSessionUrl","paymentForm","newPayment","fetchPaymentMethods","fetchPayments","fetchPayment","paymentId","fetchStripeCheckoutUrl","sendPaymentRequestLinkViaSms","updateDefaultBillingDetails","paymentMethodId","addPaymentMethod","newPaymentAmount","newPaymentKeepDepositAmount","newPaymentSecurityDeposit","getEmployees","companyEmployees","employeeInitials","employeeNotificationSettings","updateNotificationSettings","updateEmployeeNotificationSettings","settingsLoading","notificationSettings","notification","notificationOld","emailTemplates","automaticEmailTemplates","manualEmailTemplates","getEmailTemplates","useEmailDomainSettings","emailDomainSettingsLoading","domainId","_sfc_main$F","EmailTemplates","fetchEmailDomain","createEmailDomain","deleteEmailDomain","emailDomainCheckDKIM","emailDomainCheckReturnPathStatus","setAsDefaultSendingDomain","sendTestEmail","updateEmailDomainUsername","editEmail","domainDialog","testEmailDialog","domainSettingsDialog","newDomain","testEmailAddress","createEmailDomainErrorMessage","currentWorkingSetting","domainSettingsDeleteConfirmDialog","toLower","clone","split","_withKeys","_component_EmailTemplates","_component_v_snackbar","useEmail","emailLoading","emailHistory","emailForm","emailsLoading","getEmailTemplate","updateEmailTemplate","sendTestTemplateEmail","resetEmailTemplate","resetEmailTemplateInit","updateEmailTemplateInit","localEmailTemplate","Paragraph","List","useSubscriptionManager","planSelectionName","plansOrdered","planSelection","planSelectionObject","planSelectionNameUpper","planSelectionPrice","planPricing","subscriptionStep","openStripeCheckoutUrl","switchPlanInit","termsSection","handleStepClick","planSelectionAnnualPrice","subscriptionPlanIndex","subscriptionPlanFeatures","bullet","cancelSubscriptionCommit","newUrl","Integrations","Connections","useProviders","paymentProviders","deletePaymentProfile","getPaymentProfiles","StripeOauthWindow","stripeInterval","removeStripeConfirm","stripeAccountDialog","stripeProvider","hasStripe","stripeUuid","stripeCreatedAt","stripeAccountCapabilities","stripeAccountChargesEnabled","stripeAccountPayoutsEnabled","deletePaymentProfileCommit","StripeOauth","clientId","results","_sfc_main$w","_component_v_img","useSquare","getSquareOauthUrl","getSquareProvider","setSquareLoading","squareOauthWindow","squareCheckInterval","removeSquareConfirmDialog","squareProvider","hasSquare","openOauthUrl","squareEmail","squareUuid","squareCreatedAt","squareOauthInit","_sfc_main$t","profile","instance","stripeScript","WhatAreCommissionsDialog","viewCommissionPartnerDialog","deleteCommissionPartnerDialog","editedIndex","showOnMainMenu","commissionPartner","partnersLoading","toggleShowCommissionPartnersOnMainMenu","getCommissionPartners","updateCommissionPartner","resetCommissionPartner","deleteCommissionPartner","createCommissionPartner","isDialogVisible","openDialog","updateAmountFormat","editItem","deleteItem","commissionAmount","showOnMainMenuData","webhooksLoading","getWebhookEndpoints","webhookEndpointStatus","endpoint","editWebhook","webhookForm","webhookLoading","webhookCardReady","webhookFormReady","clearErrors","addWebhookEndpoint","addWebhookEndpointInit","createWebhookSuccess","showEditForm","updateSuccess","webhookClone","currentWorkingConversation","conversationResultClassObject","currentWebhook","webhookConversations","webhookEndpointSecret","orderedConversations","groupBy","orderedDates","orderBy","getWebhookEndpoint","getWebhookConversations","resendWebhookConversation","companyNew","_component_v_form","_component_v_combobox","_vShow","eSign","AdditionalScripts","AdditionalStyling","TermsAndCancellationPolicy","Payments","localAcceptCoupons","SectionDivider","components","OperatingHours","GuestCancellation","CheckoutFields","SecondaryDrivers","StoreCustomizations","CustomDomain","EcommerceTracking","Install","_sfc_main$m","perms","newData","er","_component_v_container","$t","perm","_component_v_list_item_action","_component_v_checkbox_btn","PERMISSION_ORDER","_sfc_main$l","aIndex","bIndex","turnOn","otherPerms","employeeData","acronym","matches","_component_v_avatar","getFleetBranches","branchLocationName","branchLocationLine1","createBranch","fleetLoading","currentWorkingBranch","branchForm","formErrors","createFleetBranch","addLocationData","deleteFleetBranch","getFleetBranch","branchLoading","currentBranchUuid","confirmDelete","editingLocation","matchPickupReturnLocationToBranchDialog","branchClone","pickupReturnSame","pickupReturnSameAsBranch","editBranch","missingNewLocationInfo","branchLocation","locationStaticMap","lat","lng","deleteFleetBranchInit","updateFleetBranch","updatedBranch","updateFleetBranchInit","matchPickupReturnLocationsToBranch","documentName","changeLocationInit","vehicleClasses","vehicleLoading","getVehicleClasses","branchName","closeDialog","isOpen","COLORS","useVehicle","vehicleMakes","vehicleModels","vehicleColors","vehicleClassForm","vehicleClassCreated","createVehicleClass","createVehicleClassInit","currentWorkingClass","branchesFiltered","isSippDialogOpen","openSippDialog","vehicleClassBranch","cancel","filteredBranches","getVehicleClass","deleteVehicleClass","updateVehicleClass","fleetClassUuid","classClone","deleteVehicleClassInit","backToClasses","defaultActionItem","_sfc_main$b","newlyCreatedActionItem","fleetForm","createActionItem","_sfc_main$a","agreeToSDialog","hasAffiliate","agreeToS","affiliateLoading","affiliateApplication","getAffiliate","affiliateTOSAgree","submitSuccess","formReady","affiliateForm","affiliateApplicationCreatedAt","affiliateUrl","affiliateActive","affiliateApplications","submitAffiliateApplication","nameKeydown","submitAffiliateApplicationInit","formatMoneyDisplayUSD","affiliatePayouts","affiliatePayoutsPast","affiliatePayoutsFuture","getAffiliatePayouts","_sfc_main$4","custodianLoading","_component_v_scroll_y_transition","_sfc_main$3","ListingAddManagersDialog","custodiansLoading","_component_ListingAddManagersDialog","fetchSetupUrl","fetchSetupUrlInit"],"ignoreList":[],"sources":["../../../resources/js/bootstrap.ts","../../../resources/js/store/mutation-types.ts","../../../resources/js/plugins/eventBus.js","../../../resources/js/plugins/FWForms/util.ts","../../../resources/js/plugins/FWForms/Errors.ts","../../../resources/js/plugins/FWForms/Form.ts","../../../resources/js/store/helpers/vuex-helpers.ts","../../../resources/js/store/modules/affiliate.ts","../../../resources/js/utils/urls.ts","../../../resources/js/store/modules/analytics.ts","../../../resources/js/utils/auth.ts","../../../resources/js/store/modules/app.ts","../../../resources/js/utils/numbers.ts","../../../resources/js/tenant/Services/elFactory.service.js","../../../resources/js/tenant/Services/api.service.js","../../../resources/js/tenant/Services/card.service.js","../../../resources/js/tenant/Services/list.service.js","../../../resources/js/tenant/Services/datepicker.service.js","../../../resources/js/tenant/Services/util.service.js","../../../resources/js/services/cart.service.ts","../../../resources/js/utils/formValidationRules.ts","../../../resources/js/composables/useAuth.ts","../../../resources/js/views/auth/Login.vue","../../../resources/js/views/auth/Register.vue","../../../resources/js/utils/dates.ts","../../../resources/js/views/auth/RegisterNextStep.vue","../../../resources/js/utils/meta.ts","../../../resources/js/composables/useCompany.ts","../../../resources/js/views/auth/companyEmployeeInvite.vue","../../../resources/js/views/auth/password/email.vue","../../../resources/js/views/auth/password/reset.vue","../../../resources/js/views/auth/password/verify.vue","../../../resources/js/views/auth/password/resend.vue","../../../resources/js/middleware/guest.ts","../../../resources/js/router/modules/auth.ts","../../../resources/js/router/modules/settings.ts","../../../resources/js/router/modules/commission.ts","../../../resources/js/views/dashboard/manager/ListingManagerConnect.vue","../../../resources/js/router/modules/custodian.ts","../../../resources/js/views/documentsV2/DocumentsDashboardV2.vue","../../../resources/js/utils/text.ts","../../../resources/js/composables/useTemplate.ts","../../../resources/js/utils/permission.ts","../../../resources/js/composables/useAppSettings.ts","../../../resources/js/views/documentsV2/TemplateRightSidebarV2.vue","../../../resources/js/components/dashboard/documents/LeftSidebar.vue","../../../resources/js/components/dashboard/documents/TopToolbar.vue","../../../resources/js/components/dashboard/documents/FieldDragHandles.vue","../../../resources/js/helpers/index.ts","../../../resources/js/composables/useESign.ts","../../../resources/js/views/documentsV2/NewDocumentFieldsV2.vue","../../../resources/js/mixins/subscription.ts","../../../resources/js/composables/useDate.ts","../../../resources/js/composables/useMoneyFormatter.ts","../../../resources/js/composables/useEnvelope.ts","../../../resources/js/views/documents/ContractsTable.vue","../../../resources/js/composables/useSubscription.ts","../../../resources/js/views/documents/Home.vue","../../../resources/js/views/documents/NewDocument.vue","../../../resources/js/composables/useOrders.ts","../../../resources/js/views/documents/SingleDocument.vue","../../../resources/js/components/dashboard/dialogs/StartOrderDocumentDownloadDialog.vue","../../../resources/js/components/dashboard/navActions/OrderDocumentOptions.vue","../../../resources/js/router/modules/documents.ts","../../../resources/js/router/modules/perks.ts","../../../resources/js/router/modules/notifications.ts","../../../resources/js/router/modules/listing.ts","../../../resources/js/router/modules/connections.ts","../../../resources/js/router/modules/orders.ts","../../../resources/js/router/modules/customers.ts","../../../resources/js/router/modules/trip-extras.ts","../../../resources/js/components/themes/ThemeTopNav.vue","../../../resources/js/components/themes/LeftSideNav.vue","../../../resources/js/components/themes/ThemeMainArea.vue","../../../resources/js/views/themes/ThemeBase/ThemeBase.vue","../../../resources/js/router/modules/theme.ts","../../../resources/js/views/company/checkoutIFrame.vue","../../../resources/js/router/modules/company.ts","../../../resources/js/router/modules/e-signer.ts","../../../resources/js/router/modules/super-admin.ts","../../../resources/js/router/modules/dashboard.ts","../../../resources/js/router/modules/analytics.ts","../../../resources/js/components/company/index.vue","../../../resources/js/router/modules/pay.ts","../../../resources/js/router/routes.ts","../../../resources/js/middleware/companyStore.ts","../../../resources/js/plugins/i18n/i18n.ts","../../../resources/js/plugins/i18n/translations.ts","../../../resources/js/middleware/locale.ts","../../../resources/js/middleware/check-auth.ts","../../../resources/js/middleware/auth.ts","../../../resources/js/router/index.ts","../../../resources/js/store/modules/auth.ts","../../../resources/js/services/storage.service.ts","../../../resources/js/store/modules/automations.ts","../../../resources/js/store/modules/axle.ts","../../../resources/js/store/modules/barcode.ts","../../../resources/js/store/modules/booking.ts","../../../resources/js/store/modules/bouncie.ts","../../../resources/js/store/modules/braintree.ts","../../../resources/js/services/commission-partner.service.ts","../../../resources/js/store/modules/cart.ts","../../../resources/js/store/modules/checkout.ts","../../../resources/js/store/modules/commission-partners.ts","../../../resources/js/store/modules/company.ts","../../../resources/js/store/modules/coupon.ts","../../../resources/js/store/modules/custodian.ts","../../../resources/js/store/modules/custom-fields.ts","../../../resources/js/store/modules/default-properties.ts","../../../resources/js/store/modules/document.ts","../../../resources/js/store/modules/email.ts","../../../resources/js/store/modules/email-domain-settings.ts","../../../resources/js/store/modules/envelope.ts","../../../resources/js/store/modules/files.ts","../../../resources/js/store/modules/fleet.ts","../../../resources/js/store/modules/getaround.ts","../../../resources/js/store/modules/hq-rentals.ts","../../../resources/js/store/modules/payments.ts","../../../resources/js/settings.ts","../../../resources/js/store/modules/settings.ts","../../../resources/js/store/modules/theme.ts","../../../resources/js/store/modules/lang.ts","../../../resources/js/store/modules/listing.ts","../../../resources/js/store/modules/lula.ts","../../../resources/js/store/modules/notes.ts","../../../resources/js/store/modules/outdoorsy.ts","../../../resources/js/store/modules/permission.ts","../../../resources/js/store/modules/pricing.ts","../../../resources/js/store/modules/providers.ts","../../../resources/js/store/modules/renters.ts","../../../resources/js/store/modules/square.ts","../../../resources/js/store/modules/subscriptions.ts","../../../resources/js/store/modules/superAdmin.ts","../../../resources/js/store/modules/tags-view.ts","../../../resources/js/store/modules/taxes.ts","../../../resources/js/store/modules/maintenance.ts","../../../resources/js/store/modules/order.ts","../../../resources/js/store/modules/stripe.ts","../../../resources/js/store/modules/template.ts","../../../resources/js/store/modules/tesla.ts","../../../resources/js/store/modules/tolls.ts","../../../resources/js/store/modules/trip-extras.ts","../../../resources/js/store/modules/turo.ts","../../../resources/js/store/modules/turo-pricing.ts","../../../resources/js/store/modules/turo-research.ts","../../../resources/js/store/modules/twilio.ts","../../../resources/js/store/modules/twisted-road.ts","../../../resources/js/store/modules/vehicles.ts","../../../resources/js/store/modules/whats-new.ts","../../../resources/js/store/modules/webhook.ts","../../../resources/js/store/modules/tenant-checkout.ts","../../../resources/js/store/modules/tags.ts","../../../resources/js/store/index.ts","../../../resources/js/App.vue","../../../resources/js/plugins/vuetify.ts","../../../resources/js/plugins/gtag.ts","../../../resources/js/plugins/sentry.ts","../../../resources/js/plugins/axios.ts","../../../resources/js/layouts/register.ts","../../../resources/js/app.ts","../../../resources/js/utils/role.ts","../../../resources/js/composables/useAppFeatures.ts","../../../resources/js/views/dashboard/settings/General.vue","../../../resources/js/composables/useBranch.ts","../../../resources/js/plugins/mapBoxAddressAutofillScript.js","../../../resources/js/components/widgets/MapBoxAddressAutofill.vue","../../../resources/js/composables/useTaxAndFee.ts","../../../resources/js/composables/useListing.ts","../../../resources/js/composables/useDefaultMeta.ts","../../../resources/js/components/dashboard/settings/pricing/GlobalPriceAdjustment.vue","../../../resources/js/views/dashboard/settings/Pricing/Pricing.vue","../../../resources/js/composables/useCoupons.ts","../../../resources/js/composables/useCouponForm.ts","../../../resources/js/views/dashboard/settings/Pricing/Coupons.vue","../../../resources/js/views/dashboard/settings/Pricing/Dialogs/PricingRuleDialog.vue","../../../resources/js/views/dashboard/settings/Pricing/AdvancedPricing.vue","../../../resources/js/views/dashboard/settings/Pricing/PricingStructure/PricingTemplate.vue","../../../resources/js/views/dashboard/settings/Pricing/PricingStructure/PricingTemplateNew.vue","../../../resources/js/views/dashboard/settings/Pricing/PricingStructure/PricingTemplateEdit.vue","../../../resources/js/views/dashboard/settings/Pricing/AdvancedPricingEdit.vue","../../../resources/js/views/dashboard/settings/Taxes.vue","../../../resources/js/views/dashboard/settings/Security.vue","../../../resources/js/views/dashboard/settings/ApiToken.vue","../../../resources/js/views/dashboard/settings/ActivityLog.vue","../../../resources/js/components/dashboard/settings/account/UpsellCard.vue","../../../resources/js/composables/useStripe.ts","../../../resources/js/views/dashboard/settings/AccountAndBilling.vue","../../../resources/js/composables/usePayments.ts","../../../resources/js/views/dashboard/settings/Team.vue","../../../resources/js/views/dashboard/settings/CompanyNotifications.vue","../../../resources/js/components/dashboard/settings/Emails/EmailTemplates.vue","../../../resources/js/composables/useEmailDomainSettings.ts","../../../resources/js/views/dashboard/settings/Emails/Email.vue","../../../resources/js/composables/useEmail.ts","../../../resources/js/views/dashboard/settings/Emails/EmailTemplateSingle.vue","../../../resources/js/composables/useSubscriptionManager.ts","../../../resources/js/views/dashboard/settings/Billing/SubscriptionCheckout/SubscriptionSteps.vue","../../../resources/js/views/dashboard/settings/Billing/SubscriptionCheckout/SubscriptionTermsAndDiscount.vue","../../../resources/js/views/dashboard/settings/Billing/SubscriptionCheckout/SubscriptionReviewAndConfirm.vue","../../../resources/js/views/dashboard/settings/Billing/SubscriptionCheckout/SubscriptionOverview.vue","../../../resources/js/views/dashboard/settings/Billing/SubscriptionCheckout/SubscriptionCheckout.vue","../../../resources/js/views/dashboard/settings/Providers.vue","../../../resources/js/composables/useProviders.ts","../../../resources/js/components/dashboard/settings/providers/StripeProviderCard.vue","../../../resources/js/components/dashboard/settings/providers/BraintreeProviderCard.vue","../../../resources/js/composables/useSquare.ts","../../../resources/js/components/dashboard/settings/providers/SquareProviderCard.vue","../../../resources/js/views/dashboard/settings/PaymentProviders.vue","../../../resources/js/views/dashboard/settings/PaymentProviders/SinglePaymentProvider.vue","../../../resources/js/views/dashboard/settings/CommissionPartners.vue","../../../resources/js/views/dashboard/settings/Webhooks/Webhooks.vue","../../../resources/js/views/dashboard/settings/Webhooks/Create.vue","../../../resources/js/views/dashboard/settings/Webhooks/UpdateWebhook.vue","../../../resources/js/views/dashboard/settings/Checkout.vue","../../../resources/js/views/dashboard/settings/OnlineReservations.vue","../../../resources/js/views/dashboard/settings/EmployeesNew.vue","../../../resources/js/views/dashboard/settings/Employees.vue","../../../resources/js/views/dashboard/settings/Fleet/FleetBase.vue","../../../resources/js/views/dashboard/settings/Fleet/FleetBranches.vue","../../../resources/js/views/dashboard/settings/Fleet/FleetBranchesNew.vue","../../../resources/js/views/dashboard/settings/Fleet/FleetBranchesSingle.vue","../../../resources/js/views/dashboard/settings/Fleet/FleetClass.vue","../../../resources/js/views/dashboard/settings/Fleet/SippDialog.vue","../../../resources/js/composables/useVehicle.ts","../../../resources/js/views/dashboard/settings/Fleet/FleetClassNew.vue","../../../resources/js/views/dashboard/settings/Fleet/FleetClassSingle.vue","../../../resources/js/views/dashboard/settings/Fleet/ActionItems/ActionItems.vue","../../../resources/js/views/dashboard/settings/Fleet/ActionItems/ActionItemNew.vue","../../../resources/js/views/dashboard/settings/Fleet/ActionItems/ActionItemSingle.vue","../../../resources/js/views/dashboard/settings/Fleet/FleetFeatures.vue","../../../resources/js/views/dashboard/settings/Affiliate/AffiliateTerms.vue","../../../resources/js/views/dashboard/settings/Affiliate/AffiliateIndex.vue","../../../resources/js/views/dashboard/settings/Affiliate/AffiliateSignup.vue","../../../resources/js/views/dashboard/settings/Affiliate/AffiliatePayouts.vue","../../../resources/js/components/dashboard/dialogs/ListingAddManagersDialog.vue","../../../resources/js/views/dashboard/settings/Custodian/Index.vue","../../../resources/js/views/dashboard/settings/Billing/SubscriptionDetailCards/CardOnFileCard.vue","../../../resources/js/views/dashboard/settings/Billing/SubscriptionDetailCards/RenewsOneCard.vue","../../../resources/js/views/dashboard/settings/Billing/SubscriptionDetailCards/PlanPriceCard.vue"],"sourcesContent":["import Cookies from 'js-cookie';\nimport Echo from 'laravel-echo';\nimport Pusher from 'pusher-js';\nimport { ray } from 'node-ray/web';\n\nwindow.ray = ray;\nPusher.logToConsole = false;\n\nconst pusherAppKey = import.meta.env.VITE_PUSHER_APP_KEY;\n\nconst pusher = new Pusher(pusherAppKey, {\n cluster: 'us3',\n forceTLS: true,\n authEndpoint: '/api/broadcasting/auth',\n auth: {\n headers: {\n Authorization: `Bearer ${Cookies.get('token')}`,\n },\n },\n});\n\nwindow.Echo = new Echo({\n broadcaster: 'pusher',\n client: pusher,\n});\n","export const SET_LOCALE = 'SET_LOCALE';\n\n// app.js\nexport const SET_APP_LOADING = 'SET_APP_LOADING';\nexport const SET_APP_BOOTING = 'SET_APP_BOOTING';\nexport const TOGGLE_RIGHT_SIDEBAR = 'TOGGLE_RIGHT_SIDEBAR';\nexport const TOGGLE_SIDEBAR = 'TOGGLE_SIDEBAR';\nexport const INITIALIZE_STATE = 'INITIALIZE_STATE';\nexport const TOGGLE_LISTING_VIEW = 'TOGGLE_LISTING_VIEW';\nexport const TOGGLE_SECONDARY_IMPORT_NAV_VIEW = 'TOGGLE_SECONDARY_IMPORT_NAV_VIEW';\nexport const CLOSE_SIDEBAR = 'CLOSE_SIDEBAR';\nexport const TOGGLE_DEVICE = 'TOGGLE_DEVICE';\nexport const SET_ALL_POSSIBLE_PERMISSIONS = 'SET_ALL_POSSIBLE_PERMISSIONS';\nexport const SET_MASQUERADE_STATUS = 'SET_MASQUERADE_STATUS';\nexport const SET_MASQUERADE = 'SET_MASQUERADE';\nexport const END_MASQUERADE = 'END_MASQUERADE';\nexport const SET_FW_STRIPE_KEY = 'SET_FW_STRIPE_KEY';\nexport const SET_POLLED_FW_BUILD_NUMBER = 'SET_POLLED_FW_BUILD_NUMBER';\nexport const SET_UPDATE_AVAILABLE = 'SET_UPDATE_AVAILABLE';\nexport const SET_APP_FEATURES = 'SET_APP_FEATURES';\nexport const MARK_SETUP_ITEM_COMPLETE = 'MARK_SETUP_ITEM_COMPLETE';\nexport const SET_FEATURES_WAITLIST = 'SET_FEATURES_WAITLIST';\nexport const SET_CURRENT_CURRENCY = 'SET_CURRENT_CURRENCY';\nexport const TOGGLE_DEBUG_ON = 'TOGGLE_DEBUG_ON';\nexport const TOGGLE_DEBUG_DRAWER = 'TOGGLE_DEBUG_DRAWER';\nexport const SET_FW_BUILD_NUMBER = 'SET_FW_BUILD_NUMBER';\nexport const SET_HOVERED_TURNOVER_BOOKING_ID = 'SET_HOVERED_TURNOVER_BOOKING_ID';\n\n// permissions.js\nexport const SET_ROUTES = 'SET_ROUTES';\n\n// settings.js\nexport const SET_SETTINGS_LOADING = 'SET_SETTINGS_LOADING';\nexport const SET_NOTIFICATION_SETTINGS = 'SET_NOTIFICATION_SETTINGS';\n\n// vehicles.js\nexport const SET_VEHICLES_LOADING = 'SET_VEHICLES_LOADING';\nexport const SET_VEHICLES = 'SET_VEHICLES';\nexport const SET_VEHICLE_MAKES = 'SET_VEHICLE_MAKES';\nexport const SET_VEHICLE_MODELS = 'SET_VEHICLE_MODELS';\nexport const SET_VEHICLE_CLASS_CREATED = 'SET_VEHICLE_CLASS_CREATED';\nexport const SET_VEHICLE_CLASSES = 'SET_VEHICLE_CLASSES';\nexport const SET_VEHICLE_CLASS = 'SET_VEHICLE_CLASS';\nexport const CLEAR_VEHICLE_FORM_ERRORS = 'CLEAR_VEHICLE_FORM_ERRORS';\nexport const SET_VEHICLE_FORM_ERRORS = 'SET_VEHICLE_FORM_ERRORS';\n\n\n// auth.js\nexport const SET_USER = 'SET_USER';\nexport const SET_AUTH_LOADING = 'SET_AUTH_LOADING';\nexport const SET_TOKEN = 'SET_TOKEN';\nexport const SAVE_TOKEN = 'SAVE_TOKEN';\nexport const SAVE_REGISTER_ID = 'SAVE_REGISTER_ID';\nexport const SET_ROLES = 'SET_ROLES';\nexport const SET_PERMISSIONS = 'SET_PERMISSIONS';\nexport const FETCH_USER_FAILURE = 'FETCH_USER_FAILURE';\nexport const LOGOUT = 'LOGOUT';\nexport const UPDATE_USER = 'UPDATE_USER';\nexport const SET_USER_NOTIFICATIONS = 'SET_USER_NOTIFICATIONS';\nexport const SET_USER_API_TOKENS = 'SET_USER_API_TOKENS';\n\n\n// booking.js\nexport const SET_BOOKING_LOADING = 'SET_BOOKING_LOADING';\nexport const SET_BOOKING_DIALOG = 'SET_BOOKING_DIALOG';\nexport const CLEAR_BOOKING_FORM_ERRORS = 'CLEAR_BOOKING_FORM_ERRORS';\nexport const SET_BOOKING_FORM_ERROR = 'SET_BOOKING_FORM_ERROR';\nexport const SET_FILTERED_MAKES = 'SET_FILTERED_MAKES';\nexport const PUSH_CALENDAR_ATTRIBUTES = 'PUSH_CALENDAR_ATTRIBUTES';\nexport const SET_CALENDAR_ATTRIBUTES = 'SET_CALENDAR_ATTRIBUTES';\nexport const SET_UNAVAILABLE_DATES = 'SET_UNAVAILABLE_DATES';\nexport const RESET_UNAVAILABLE_DATES = 'RESET_UNAVAILABLE_DATES';\nexport const SET_BOOKING_LISTING = 'SET_BOOKING_LISTING';\nexport const SET_STORED_TURO_BOOKINGS = 'SET_STORED_TURO_BOOKINGS';\nexport const SET_CUSTOMER_BOOKING = 'SET_CUSTOMER_BOOKING';\nexport const SET_REMEMBER_CUSTOMER = 'SET_REMEMBER_CUSTOMER';\nexport const SET_BOOKINGS = 'SET_BOOKINGS';\nexport const SET_BOOKINGS_META = 'SET_BOOKINGS_META';\nexport const SET_ABANDONED_BOOKINGS = 'SET_ABANDONED_BOOKINGS';\nexport const SET_PRIORITY_BOOKINGS = 'SET_PRIORITY_BOOKINGS';\nexport const SET_TOTAL_BOOKINGS = 'SET_TOTAL_BOOKINGS';\nexport const SET_CURRENT_WORKING_BOOKING = 'SET_CURRENT_WORKING_BOOKING';\nexport const SET_CURRENT_WORKING_BOOKING_STATUS = 'SET_CURRENT_WORKING_BOOKING_STATUS';\nexport const SET_BOOKING_PAYMENTS = 'SET_BOOKING_PAYMENTS';\nexport const MERGE_BOOKING_LINE_ITEM = 'MERGE_BOOKING_LINE_ITEM';\nexport const UPDATE_BOOKING_LINE_ITEM = 'UPDATE_BOOKING_LINE_ITEM';\nexport const REMOVE_BOOKING_LINE_ITEM = 'REMOVE_BOOKING_LINE_ITEM';\nexport const SET_BOOKING_CART_ID = 'SET_BOOKING_CART_ID';\nexport const RESET_BOOKING = 'RESET_BOOKING';\nexport const SET_BOOKING_AUTOMATION_EVENTS = 'SET_BOOKING_AUTOMATION_EVENTS';\nexport const SET_BOOKING_NOT_FOUND = 'SET_BOOKING_NOT_FOUND';\nexport const SET_CURRENT_STRIPE_CHARGE = 'SET_CURRENT_STRIPE_CHARGE';\nexport const SET_FLEET_RESOURCES = 'SET_FLEET_RESOURCES';\nexport const SET_CURRENT_WORKING_BOOKING_ATTRIBUTE = 'SET_CURRENT_WORKING_BOOKING_ATTRIBUTE';\n\n\n// company.js\nexport const SET_COMPANY_LOADING = 'SET_COMPANY_LOADING';\nexport const SET_COMPANY = 'SET_COMPANY';\nexport const SET_COMPANY_PHONE = 'SET_COMPANY_PHONE';\nexport const SET_COMPANY_META = 'SET_COMPANY_META';\nexport const SET_COMPANY_DEFAULT_META = 'SET_COMPANY_DEFAULT_META';\nexport const SET_COMPANY_BOOKINGS = 'SET_COMPANY_BOOKINGS';\nexport const SET_COMPANY_EMPLOYEES = 'SET_COMPANY_EMPLOYEES';\nexport const SET_COMPANY_EMPLOYEE = 'SET_COMPANY_EMPLOYEE';\nexport const SET_POSSIBLE_PERMISSIONS = 'SET_POSSIBLE_PERMISSIONS';\nexport const RESET_EMPLOYEE = 'RESET_EMPLOYEE';\nexport const SET_COMPANY_NOTIFICATIONS = 'SET_COMPANY_NOTIFICATIONS';\nexport const SET_EMPLOYEE_PERMISSIONS = 'SET_EMPLOYEE_PERMISSIONS';\nexport const SET_EMPLOYEE_ROLES = 'SET_EMPLOYEE_ROLES';\nexport const SET_EMAIL_DOMAIN_SETTINGS = 'SET_EMAIL_DOMAIN_SETTINGS';\nexport const SET_DELIVERY_LOCATIONS = 'SET_DELIVERY_LOCATIONS';\nexport const SET_FEEDBACK_REVIEWS = 'SET_FEEDBACK_REVIEWS';\nexport const SET_COMPANY_FORM_ERROR = 'SET_COMPANY_FORM_ERROR';\nexport const SET_COMPANY_META_FORM_ERROR = 'SET_COMPANY_META_FORM_ERROR';\nexport const CLEAR_COMPANY_META_FORM_ERRORS = 'CLEAR_COMPANY_META_FORM_ERRORS';\n\nexport const SET_OPERATING_RULES = 'SET_OPERATING_RULES';\nexport const SET_COMPANY_CURRENCY = 'SET_COMPANY_CURRENCY';\nexport const SET_COMPANY_SETTINGS = 'SET_COMPANY_SETTINGS';\nexport const SET_COUNTS = 'SET_COUNTS';\n\n// affiliate.js\nexport const SET_AFFILIATE_LOADING = 'SET_AFFILIATE_LOADING';\nexport const SET_AFFILIATE = 'SET_AFFILIATE';\nexport const SET_AFFILIATE_PAYOUTS = 'SET_AFFILIATE_PAYOUTS';\nexport const SET_AFFILIATE_APPLICATION = 'SET_AFFILIATE_APPLICATION';\nexport const SET_AFFILIATE_FUTURE_PAYOUT = 'SET_AFFILIATE_FUTURE_PAYOUT';\nexport const SET_AFFILIATE_PAST_PAYOUT = 'SET_AFFILIATE_PAST_PAYOUT';\n\n\n// listing.js\nexport const SET_LISTING_LOADING = 'SET_LISTING_LOADING';\nexport const SET_LISTING_SNACK = 'SET_LISTING_SNACK';\nexport const SET_LISTING_DIALOG = 'SET_LISTING_DIALOG';\nexport const CLEAR_LISTING_FILTER = 'CLEAR_LISTING_FILTER';\nexport const SET_LISTING_FILTER_AVAILABLE_FILTERS = 'SET_LISTING_FILTER_AVAILABLE_FILTERS';\nexport const SET_LISTING_FILTER_SELECTED_FILTERS = 'SET_LISTING_FILTER_SELECTED_FILTERS';\nexport const TOGGLE_LISTING_FILTER = 'TOGGLE_LISTING_FILTER';\nexport const SET_LISTING_VEHICLE = 'SET_LISTING_VEHICLE';\nexport const SET_LISTING_PRICE = 'SET_LISTING_PRICE';\nexport const SET_LISTING_PRICE_TAXABLE = 'SET_LISTING_PRICE_TAXABLE';\nexport const SET_LISTING_PRICE_TAX_CATEGORY = 'SET_LISTING_PRICE_TAX_CATEGORY';\nexport const SET_LISTING_SEC_DEP = 'SET_LISTING_SEC_DEP';\nexport const SET_LISTING_SEC_DEP_CREDIT = 'SET_LISTING_SEC_DEP_CREDIT';\nexport const SET_LISTING_SEC_DEP_DEBIT = 'SET_LISTING_SEC_DEP_DEBIT';\nexport const SET_LISTING_MILES_OVERAGE = 'SET_LISTING_MILES_OVERAGE';\nexport const RESET_CURRENT_LISTING = 'RESET_CURRENT_LISTING';\nexport const SET_CURRENT_NEW_LISTING = 'SET_CURRENT_NEW_LISTING';\nexport const SET_CURRENT_LISTING = 'SET_CURRENT_LISTING';\nexport const SET_LISTING = 'SET_LISTING';\nexport const SET_LISTING_INIT = 'SET_LISTING_INIT';\nexport const SET_ALL_LISTINGS = 'SET_ALL_LISTINGS';\nexport const SET_LISTING_ID = 'SET_LISTING_ID';\nexport const SET_STATUS_FILTER_ITEMS = 'SET_STATUS_FILTER_ITEMS';\nexport const SET_STATUS_FILTER_ITEMS_UPCOMING = 'SET_STATUS_FILTER_ITEMS_UPCOMING';\nexport const SET_STATUS_FILTER_TEMP_ITEMS = 'SET_STATUS_FILTER_TEMP_ITEMS';\nexport const SET_PAYMENT_STATUS_FILTER_ITEMS = 'SET_PAYMENT_STATUS_FILTER_ITEMS';\nexport const SET_ACTIVITY_FILTER_ITEMS = 'SET_ACTIVITY_FILTER_ITEMS';\nexport const SET_SOURCE_FILTER_ITEMS = 'SET_SOURCE_FILTER_ITEMS';\nexport const SET_BOOKABLE_TIMES = 'SET_BOOKABLE_TIMES';\nexport const SET_CURRENT_LISTING_BOOKINGS = 'SET_CURRENT_LISTING_BOOKINGS';\nexport const SET_CURRENT_LISTING_DISCOUNTABLE = 'SET_CURRENT_LISTING_DISCOUNTABLE';\nexport const SET_CURRENT_LISTING_MILE_ALLOWANCE = 'SET_CURRENT_LISTING_MILE_ALLOWANCE';\nexport const SET_CURRENT_LISTING_DURATION_DISCOUNT = 'SET_CURRENT_LISTING_DURATION_DISCOUNT';\nexport const TOGGLE_PAUSE_CURRENT_LISTING = 'TOGGLE_PAUSE_CURRENT_LISTING';\nexport const SET_CURRENT_LISTING_CHECKOUT_MODE = 'SET_CURRENT_LISTING_CHECKOUT_MODE';\nexport const SET_LISTING_PRICE_TYPE = 'SET_LISTING_PRICE_TYPE';\nexport const SET_LISTING_PRICE_PERIOD = 'SET_LISTING_PRICE_PERIOD';\nexport const SET_LISTING_PRICE_STRUCTURE_ID = 'SET_LISTING_PRICE_STRUCTURE_ID';\nexport const SET_VEHICLE_VIN = 'SET_VEHICLE_VIN';\nexport const SET_VEHICLE_YEAR = 'SET_VEHICLE_YEAR';\nexport const SET_VEHICLE_MAKE = 'SET_VEHICLE_MAKE';\nexport const SET_VEHICLE_MODEL = 'SET_VEHICLE_MODEL';\nexport const SET_VEHICLE_COLOR = 'SET_VEHICLE_COLOR';\nexport const SET_VEHICLE_SEATS = 'SET_VEHICLE_SEATS';\nexport const SET_VEHICLE_DOORS = 'SET_VEHICLE_DOORS';\nexport const SET_VEHICLE_PLATE = 'SET_VEHICLE_PLATE';\nexport const SET_ALL_AVAILABLE_FEATURES = 'SET_ALL_AVAILABLE_FEATURES';\nexport const SET_VEHICLE_FEATURES = 'SET_VEHICLE_FEATURES';\nexport const SET_VEHICLE_EXTRAS = 'SET_VEHICLE_EXTRAS';\nexport const SET_CURRENT_DECODED_VIN = 'SET_CURRENT_DECODED_VIN';\nexport const SET_EXISTING_LISTING_DATA = 'SET_EXISTING_LISTING_DATA';\nexport const SET_CURRENT_TRIP_EXTRA = 'SET_CURRENT_TRIP_EXTRA';\nexport const SET_CURRENT_LISTING_IMAGES = 'SET_CURRENT_LISTING_IMAGES';\nexport const SET_LISTING_AVAILABILITY_MESSAGE = 'SET_LISTING_AVAILABILITY_MESSAGE';\nexport const SET_ALL_EXTRAS = 'SET_ALL_EXTRAS';\nexport const SET_LISTING_FORM_ERRORS = 'SET_LISTING_FORM_ERRORS';\nexport const CLEAR_LISTING_FORM_ERRORS = 'CLEAR_LISTING_FORM_ERRORS';\nexport const SET_LISTING_DAILY_PRICES = 'SET_LISTING_DAILY_PRICES';\nexport const SET_FLEET_RESOURCE_LISTINGS = 'SET_FLEET_RESOURCE_LISTINGS';\nexport const SET_FLEET_RESOURCE_LISTINGS_DATA = 'SET_FLEET_RESOURCE_LISTINGS_DATA';\nexport const SET_CURRENT_LISTING_INCIDENTS = 'SET_CURRENT_LISTING_INCIDENTS';\nexport const SET_LISTING_FILTER_OPTIONS = 'SET_LISTING_FILTER_OPTIONS';\nexport const SET_CUSTODIAL_LISTING = 'SET_CUSTODIAL_LISTING';\n\n// turo\nexport const SET_INIT = 'SET_INIT';\nexport const SET_TURO_LOADING = 'SET_TURO_LOADING';\nexport const SET_TRIPS = 'SET_TRIPS';\nexport const SET_TRIP_SINGLE = 'SET_TRIP_SINGLE';\nexport const SET_TURO_EMAILS = 'SET_TURO_EMAILS';\nexport const SET_TRIP_SINGLE_MESSAGES = 'SET_TRIP_SINGLE_MESSAGES';\nexport const SET_TRIP_SINGLE_IMAGES = 'SET_TRIP_SINGLE_IMAGES';\nexport const SET_TURO_MESSAGE_SENDING = 'SET_TURO_MESSAGE_SENDING';\nexport const SET_TURO_ALL_VEHICLES = 'SET_TURO_ALL_VEHICLES';\nexport const RESET_VEHICLES = 'RESET_VEHICLES';\nexport const SET_ALL_IMPORTED_TURO_VEHICLES = 'SET_ALL_IMPORTED_TURO_VEHICLES';\nexport const SET_TRIP_TURO_GO = 'SET_TRIP_TURO_GO';\nexport const SET_TURO_CONNECTIONS = 'SET_TURO_CONNECTIONS';\nexport const SET_TURO_REIMBURSEMENT_DETAILS = 'SET_TURO_REIMBURSEMENT_DETAILS';\nexport const RESET_TURO_CREDS = 'RESET_TURO_CREDS';\nexport const SET_TURO_CAPTCHA_TESTING = 'SET_TURO_CAPTCHA_TESTING';\nexport const SET_TURO_CAPTCHA_ID = 'SET_TURO_CAPTCHA_ID';\nexport const SET_TURO_EARNINGS = 'SET_TURO_EARNINGS';\nexport const SET_TRIP_HISTORY = 'SET_TRIP_HISTORY';\nexport const SET_TRIP_PENDING_REQUESTS = 'SET_TRIP_PENDING_REQUESTS';\nexport const SET_ACTIVITY_FEED = 'SET_ACTIVITY_FEED';\nexport const SET_TURO_CHANGE_REQUEST_SETTINGS = 'SET_TURO_CHANGE_REQUEST_SETTINGS';\nexport const SET_TURO_FEEDBACK = 'SET_TURO_FEEDBACK';\nexport const SET_TURO_FEEDBACK_PAGE = 'SET_TURO_FEEDBACK_PAGE';\nexport const SET_TURO_FEEDBACK_NEXT_PAGE = 'SET_TURO_FEEDBACK_NEXT_PAGE';\nexport const SET_TURO_FEEDBACK_TOTAL = 'SET_TURO_FEEDBACK_TOTAL';\nexport const SET_TURO_FEEDBACK_PER_PAGE = 'SET_TURO_FEEDBACK_PER_PAGE';\nexport const SET_TURO_FEEDBACK_LAST_PAGE = 'SET_TURO_FEEDBACK_LAST_PAGE';\nexport const SET_ALL_TURO_VEHICLES = 'SET_ALL_TURO_VEHICLES';\nexport const CLEAR_ALL_TURO_VEHICLES = 'CLEAR_ALL_TURO_VEHICLES';\nexport const SET_ALL_TURO_MESSAGES = 'SET_ALL_TURO_MESSAGES';\nexport const SET_ALL_TURO_MESSAGES_CURRENT_PAGINATE = 'SET_ALL_TURO_MESSAGES_CURRENT_PAGINATE';\nexport const SET_ALL_TURO_MESSAGES_TOTAL_PAGES = 'SET_ALL_TURO_MESSAGES_TOTAL_PAGES';\nexport const SET_TURO_EMAILS_PAGINATION = 'SET_TURO_EMAILS_PAGINATION';\nexport const SET_TRIP_SINGLE_MESSAGES_STORED = 'SET_TRIP_SINGLE_MESSAGES_STORED';\n\n//\nexport const SET_TURO_PRICING_LOADING = 'SET_TURO_PRICING_LOADING';\nexport const SET_TURO_VEHICLE_DAILY_PRICING = 'SET_TURO_VEHICLE_DAILY_PRICING';\nexport const SET_TURO_PRICING_VEHICLES = 'SET_TURO_PRICING_VEHICLES';\n\n\n// getaround.js\nexport const SET_GETAROUND_INIT = 'SET_GETAROUND_INIT';\nexport const SET_GETAROUND_LOADING = 'SET_GETAROUND_LOADING';\nexport const SET_GETAROUND_VEHICLES = 'SET_GETAROUND_VEHICLES';\nexport const SET_GETAROUND_CONNECTIONS = 'SET_GETAROUND_CONNECTIONS';\nexport const SET_GETAROUND_TRIPS = 'SET_GETAROUND_TRIPS';\nexport const SET_GETAROUND_RESERVATION = 'SET_GETAROUND_RESERVATION';\nexport const SET_ALL_IMPORTED_GETAROUND_VEHICLES = 'SET_ALL_IMPORTED_GETAROUND_VEHICLES';\nexport const SET_GETAROUND_RESERVATION_RECEIPT = 'SET_GETAROUND_RESERVATION_RECEIPT';\n\n\n// renters.js\nexport const SET_RENTERS_LOADING = 'SET_RENTERS_LOADING';\nexport const SET_RENTER = 'SET_RENTER';\nexport const SET_RENTERS = 'SET_RENTERS';\nexport const SET_ALL_RENTERS = 'SET_ALL_RENTERS';\nexport const SET_RENTERS_DIALOG = 'SET_RENTERS_DIALOG';\nexport const ADD_RENTER = 'ADD_RENTER';\nexport const RESET_RENTER = 'RESET_RENTER';\nexport const SET_PAYMENT_SOURCES = 'SET_PAYMENT_SOURCES';\nexport const SET_BOOKING_PAYMENT = 'SET_BOOKING_PAYMENT';\nexport const SET_PHONE_NUMBER = 'SET_PHONE_NUMBER';\nexport const SET_SEARCHED_RENTERS = 'SET_SEARCHED_RENTERS';\nexport const SET_STRIPE_CUSTOMER = 'SET_STRIPE_CUSTOMER';\nexport const CLEAR_RENTERS_FORM_ERROR = 'CLEAR_RENTERS_FORM_ERROR';\nexport const SET_RENTERS_CREDIT_CARDS = 'SET_RENTERS_CREDIT_CARDS';\nexport const SET_RENTER_NOTIFICATIONS = 'SET_RENTER_NOTIFICATIONS';\nexport const SET_CUSTOMER_QUERY = 'SET_CUSTOMER_QUERY';\n\n// automations\nexport const SET_AUTOMATION_LOADING = 'SET_AUTOMATION_LOADING';\nexport const SET_CURRENT_AUTOMATION_EVENT = 'SET_CURRENT_AUTOMATION_EVENT';\nexport const SET_MESSAGE_TEMPLATES = 'SET_MESSAGE_TEMPLATES';\nexport const SET_AUTOMATION_EVENTS = 'SET_AUTOMATION_EVENTS';\nexport const SET_CURRENT_EVENT_LOGS = 'SET_CURRENT_EVENT_LOGS';\n\n// cart.js\nexport const SET_CART_LOADING = 'SET_CART_LOADING';\nexport const SET_CART = 'SET_CART';\nexport const SET_CART_L_ID = 'SET_CART_L_ID';\n\n// payments.js\nexport const SET_PAYMENTS_LOADING = 'SET_PAYMENTS_LOADING';\nexport const SET_PAYMENT_METHODS = 'SET_PAYMENT_METHODS';\nexport const SET_INVOICES = 'SET_INVOICES';\nexport const SET_PAYMENT = 'SET_PAYMENT';\nexport const SET_PAYMENTS = 'SET_PAYMENTS';\nexport const SET_CURRENT_WORKING_PAYMENT_ITEM = 'SET_CURRENT_WORKING_PAYMENT_ITEM';\nexport const SET_CUSTOM_PAYMENT_METHODS = 'SET_CUSTOM_PAYMENT_METHODS';\nexport const SET_STRIPE_INTENT = 'SET_STRIPE_INTENT';\nexport const RESET_NEW_PAYMENT = 'RESET_NEW_PAYMENT';\n\n// subscription.js\nexport const SET_SUBSCRIPTION_LOADING = 'SET_SUBSCRIPTION_LOADING';\nexport const SET_SUBSCRIPTION = 'SET_SUBSCRIPTION';\nexport const UPDATE_NEW_SUBSCRIPTION = 'UPDATE_NEW_SUBSCRIPTION';\nexport const SET_ENFORCE_SUBSCRIPTION = 'SET_ENFORCE_SUBSCRIPTION';\nexport const SET_SUBSCRIPTION_MASTER = 'SET_SUBSCRIPTION_MASTER';\nexport const SET_EXTRA_LISTINGS_ADDON = 'SET_EXTRA_LISTINGS_ADDON';\nexport const CLEAR_SUBSCRIPTION_FORM_ERRORS = 'CLEAR_SUBSCRIPTION_FORM_ERRORS';\nexport const SET_SUBSCRIPTION_FORM_ERROR = 'SET_SUBSCRIPTION_FORM_ERROR';\nexport const SET_SUBSCRIPTION_STEP = 'SET_SUBSCRIPTION_STEP';\nexport const SET_PLAN_SELECTION = 'SET_PLAN_SELECTION';\nexport const SET_SUBSCRIPTION_PLAN_AND_INTERVAL = 'SET_SUBSCRIPTION_PLAN_AND_INTERVAL';\n\n// super-admin.js\nexport const SET_SU_LOADING = 'SET_SU_LOADING';\nexport const SET_ALL_USERS = 'SET_ALL_USERS';\nexport const SET_CURRENT_WORKING_USER = 'SET_CURRENT_WORKING_USER';\nexport const SET_ALL_ROLES = 'SET_ALL_ROLES';\nexport const SET_ALL_PERMISSIONS = 'SET_ALL_PERMISSIONS';\nexport const SET_ALL_COMPANIES = 'SET_ALL_COMPANIES';\nexport const SET_CURRENT_WORKING_COMPANY = 'SET_CURRENT_WORKING_COMPANY';\nexport const SET_ALL_MEDIA_DIRECTORIES = 'SET_ALL_MEDIA_DIRECTORIES';\nexport const SET_ALL_MEDIA_IN_DIRECTORY = 'SET_ALL_MEDIA_IN_DIRECTORY';\nexport const SET_MEDIA_BASE_PATH = 'SET_MEDIA_BASE_PATH';\nexport const SET_ALL_LISTING_IMAGES = 'SET_ALL_LISTING_IMAGES';\nexport const SET_CURRENT_WORKING_SU_BASIC_STATS = 'SET_CURRENT_WORKING_SU_BASIC_STATS';\nexport const SET_ALL_SERVER_DETAILS = 'SET_ALL_SERVER_DETAILS';\nexport const SET_SA_FEATURE_WAITLIST = 'SET_SA_FEATURE_WAITLIST';\nexport const SET_SA_FEATURES_STATUS = 'SET_SA_FEATURES_STATUS';\nexport const SET_SA_CACHE = 'SET_SA_CACHE';\n\n// twilio\nexport const SET_TWILIO_LOADING = 'SET_TWILIO_LOADING';\nexport const SET_VERIFY_CODE = 'SET_VERIFY_CODE';\n\n// tesla.js\nexport const SET_TESLA_INIT = 'SET_TESLA_INIT';\nexport const CLEAR_TESLA_FORM_ERRORS = 'CLEAR_TESLA_FORM_ERRORS';\nexport const SET_TESLA_LOADING = 'SET_TESLA_LOADING';\nexport const SET_TESLA_CREDENTIALS = 'SET_TESLA_CREDENTIALS';\nexport const SET_TESLA_CONNECTIONS = 'SET_TESLA_CONNECTIONS';\nexport const UPDATE_TESLA_CONNECTION = 'UPDATE_TESLA_CONNECTION';\nexport const SET_TESLA_VEHICLES = 'SET_TESLA_VEHICLES';\nexport const SET_TESLA_CHARGING_INVOICES = 'SET_TESLA_CHARGING_INVOICES';\nexport const SET_TESLA_INVOICES = 'SET_TESLA_INVOICES';\nexport const SET_TESLA_INVOICES_META = 'SET_TESLA_INVOICES_META';\nexport const SET_TESLA_INVOICE_PDF = 'SET_TESLA_INVOICE_PDF';\nexport const SET_CURRENT_WORKING_TESLA_VEHICLE = 'SET_CURRENT_WORKING_TESLA_VEHICLE';\nexport const SET_CURRENT_WORKING_TESLA_VEHICLE_DRIVERS = 'SET_CURRENT_WORKING_TESLA_VEHICLE_DRIVERS';\nexport const SET_CURRENT_WORKING_TESLA_VEHICLE_HISTORY = 'SET_CURRENT_WORKING_TESLA_VEHICLE_HISTORY';\nexport const SET_CURRENT_WORKING_TESLA_VEHICLE_HISTORY_PAGINATE = 'SET_CURRENT_WORKING_TESLA_VEHICLE_HISTORY_PAGINATE';\nexport const SET_TESLA_VEHICLE_INVITATIONS = 'SET_TESLA_VEHICLE_INVITATIONS';\nexport const SET_CURRENT_WORKING_TESLA_VEHICLE_APP_ACCESS = 'SET_CURRENT_WORKING_TESLA_VEHICLE_APP_ACCESS';\nexport const SET_CURRENT_WORKING_TESLA_VEHICLE_STATE = 'SET_CURRENT_WORKING_TESLA_VEHICLE_STATE';\nexport const SET_CURRENT_WORKING_TESLA_VEHICLE_DATA = 'SET_CURRENT_WORKING_TESLA_VEHICLE_DATA';\nexport const SET_CURRENT_WORKING_TESLA_ASLEEP = 'SET_CURRENT_WORKING_TESLA_ASLEEP';\n\n// bouncie.js\nexport const SET_BOUNCIE_INIT = 'SET_BOUNCIE_INIT';\nexport const SET_BOUNCIE_LOADING = 'SET_BOUNCIE_LOADING';\nexport const SET_BOUNCIE_CONNECTIONS = 'SET_BOUNCIE_CONNECTIONS';\n\n\n// document.js\nexport const SET_TEMPLATES_LOADING = 'SET_TEMPLATES_LOADING';\nexport const RESET_TEMPLATE = 'RESET_TEMPLATE';\nexport const SET_ALL_DOCUMENTS = 'SET_ALL_DOCUMENTS';\nexport const SET_ONE_DOCUMENT = 'SET_ONE_DOCUMENT';\nexport const SET_ALL_TEMPLATES = 'SET_ALL_TEMPLATES';\nexport const SET_ONE_TEMPLATE = 'SET_ONE_TEMPLATE';\n\n// envelope.js\nexport const SET_ENVELOPE_LOADING = 'SET_ENVELOPE_LOADING';\nexport const SET_ENVELOPE = 'SET_ENVELOPE';\nexport const SET_ALL_ENVELOPES = 'SET_ALL_ENVELOPES';\nexport const SET_ENVELOPE_SIGNATURE = 'SET_ENVELOPE_SIGNATURE';\nexport const SET_ALL_FIELDS = 'SET_ALL_FIELDS';\nexport const SET_ENVELOPE_DIALOG = 'SET_ENVELOPE_DIALOG';\nexport const SET_ENVELOPE_QUERY = 'SET_ENVELOPE_QUERY';\nexport const SET_ENVELOPE_CUSTOMER = 'SET_ENVELOPE_CUSTOMER';\nexport const UPDATE_ENVELOPE_FIELD = 'UPDATE_ENVELOPE_FIELD';\nexport const SET_ESIGN_SESSION_DATA = 'SET_ESIGN_SESSION_DATA';\n\n// stripe\nexport const SET_STRIPE_LOADING = 'SET_STRIPE_LOADING';\nexport const SET_CURRENT_WORKING_INVOICE = 'SET_CURRENT_WORKING_INVOICE';\nexport const SET_CURRENT_WORKING_PAYMENT_INTENT = 'SET_CURRENT_WORKING_PAYMENT_INTENT';\nexport const SET_BILLING_PORTAL_SESSION = 'SET_BILLING_PORTAL_SESSION';\nexport const SET_STRIPE_PRICE_DATA = 'SET_STRIPE_PRICE_DATA';\nexport const SET_SUBSCRIPTION_DETAILS = 'SET_SUBSCRIPTION_DETAILS';\nexport const SET_STRIPE_IDENTITIES = 'SET_STRIPE_IDENTITIES';\nexport const SET_STRIPE_ACCOUNT = 'SET_STRIPE_ACCOUNT';\n\n// square.ts\nexport const SET_SQUARE_LOADING = 'SET_SQUARE_LOADING';\n\n// maintenance.js\nexport const SET_MAINTENANCE_LOADING = 'SET_MAINTENANCE_LOADING';\nexport const SET_CURRENT_VEHICLE_MAINTENANCE = 'SET_CURRENT_VEHICLE_MAINTENANCE';\nexport const SET_CURRENT_VEHICLE_RECALLS = 'SET_CURRENT_VEHICLE_RECALLS';\nexport const RESET_CURRENT_WORKING_MAINTENANCE_ITEM = 'RESET_CURRENT_WORKING_MAINTENANCE_ITEM';\n\n// template.js\nexport const SET_RIGHT_SIDEBAR_OPEN = 'SET_RIGHT_SIDEBAR_OPEN';\nexport const SET_RIGHT_SIDEBAR_MODE = 'SET_RIGHT_SIDEBAR_MODE';\nexport const SET_RIGHT_SIDEBAR_TITLE = 'SET_RIGHT_SIDEBAR_TITLE';\nexport const SET_CURRENT_WORKING_TOOL = 'SET_CURRENT_WORKING_TOOL';\nexport const SET_SELECTED_FIELD = 'SET_SELECTED_FIELD';\nexport const SET_SELECTED_FIELD_V2 = 'SET_SELECTED_FIELD_V2';\nexport const REMOVE_FIELD = 'REMOVE_FIELD';\nexport const REMOVE_ALL_FIELDS = 'REMOVE_ALL_FIELDS';\nexport const SET_SELECTED_FIELD_INDEX_V2 = 'SET_SELECTED_FIELD_INDEX_V2';\nexport const SET_EXISTING_DATA = 'SET_EXISTING_DATA';\nexport const SET_NEW_DATA = 'SET_NEW_DATA';\nexport const SET_TOOLS_ACTIVE = 'SET_TOOLS_ACTIVE';\nexport const SET_CANVAS_ACTIVE = 'SET_CANVAS_ACTIVE';\nexport const RESET_TEMPLATE_DATA = 'RESET_TEMPLATE_DATA';\nexport const SET_FIELD_CURRENT_SIGNER = 'SET_FIELD_CURRENT_SIGNER';\nexport const SET_DOCUMENT_IMAGES = 'SET_DOCUMENT_IMAGES';\nexport const UPDATE_DOCUMENT_TEMPLATE_DATA = 'UPDATE_DOCUMENT_TEMPLATE_DATA';\nexport const ADD_TO_DOCUMENT_TEMPLATE_DATA = 'ADD_TO_DOCUMENT_TEMPLATE_DATA';\n\n// taxes.js\nexport const SET_TAXES_LOADING = 'SET_TAXES_LOADING';\nexport const SET_TAX_CATEGORIES = 'SET_TAX_CATEGORIES';\nexport const SET_CURRENT_WORKING_TAX_CATEGORY = 'SET_CURRENT_WORKING_TAX_CATEGORY';\nexport const SET_TAX_CATEGORY_FORM_ERRORS = 'SET_TAX_CATEGORY_FORM_ERRORS';\nexport const CLEAR_TAX_CATEGORY_FORM_ERRORS = 'CLEAR_TAX_CATEGORY_FORM_ERRORS';\nexport const RESET_CURRENT_WORKING_TAX_CATEGORY = 'RESET_CURRENT_WORKING_TAX_CATEGORY';\n\n// tenant-checkout.ts\nexport const SET_TENANT_CHECKOUT_DATES = 'SET_TENANT_CHECKOUT_DATES';\nexport const SET_TENANT_CHECKOUT_LOCATION = 'SET_TENANT_CHECKOUT_LOCATION';\nexport const SET_TENANT_CHECKOUT_DURATIONS = 'SET_TENANT_CHECKOUT_DURATIONS';\nexport const SET_TENANT_CHECKOUT_CUSTOM_ORDER_FIELDS = 'SET_TENANT_CHECKOUT_CUSTOM_ORDER_FIELDS';\nexport const SET_TENANT_CHECKOUT_BOOKING_ID = 'SET_TENANT_CHECKOUT_BOOKING_ID';\nexport const SET_TENANT_CHECKOUT_CUSTOMER_TOS_AGREE = 'SET_TENANT_CHECKOUT_CUSTOMER_TOS_AGREE';\nexport const SET_TENANT_CHECKOUT_COSTS = 'SET_TENANT_CHECKOUT_COSTS';\nexport const SET_TENANT_CHECKOUT_LISTING_ID = 'SET_TENANT_CHECKOUT_LISTING_ID';\nexport const SET_TENANT_CHECKOUT_CUSTOMERS = 'SET_TENANT_CHECKOUT_CUSTOMERS';\nexport const SET_TENANT_CHECKOUT_CUSTOMER_BY_INDEX = 'SET_TENANT_CHECKOUT_CUSTOMER_BY_INDEX';\nexport const SET_TENANT_CHECKOUT_EXTRAS_V2 = 'SET_TENANT_CHECKOUT_EXTRAS_V2';\nexport const SET_TENANT_CHECKOUT_REQUIRED_EXTRAS_V2 = 'SET_TENANT_CHECKOUT_REQUIRED_EXTRAS_V2';\nexport const SET_TENANT_CHECKOUT_REQUIRED_EXTRAS = 'SET_TENANT_CHECKOUT_REQUIRED_EXTRAS';\nexport const SET_TENANT_CHECKOUT_DELIVERY_ADDRESS_FORM_SHOW = 'SET_TENANT_CHECKOUT_DELIVERY_ADDRESS_FORM_SHOW';\nexport const SET_TENANT_CHECKOUT_STRIPE_PAYMENT_INTENT = 'SET_TENANT_CHECKOUT_STRIPE_PAYMENT_INTENT';\nexport const SET_TENANT_CHECKOUT_DIALOG = 'SET_TENANT_CHECKOUT_DIALOG';\nexport const SET_TENANT_CHECKOUT_ORDER_DELIVERY_ADDRESS = 'SET_TENANT_CHECKOUT_ORDER_DELIVERY_ADDRESS';\nexport const SET_TENANT_CHECKOUT_ORDER_DISTANCE_ALLOWANCE = 'SET_TENANT_CHECKOUT_ORDER_DISTANCE_ALLOWANCE';\nexport const RESET_TENANT_CHECKOUT_DELIVERY_RESULTS = 'RESET_TENANT_CHECKOUT_DELIVERY_RESULTS';\nexport const SET_TENANT_CHECKOUT_DELIVERY_RESULTS = 'SET_TENANT_CHECKOUT_DELIVERY_RESULTS';\nexport const SET_TENANT_CHECKOUT_DISCOUNT = 'SET_TENANT_CHECKOUT_DISCOUNT';\nexport const RESET_TENANT_CHECKOUT_DISCOUNT = 'RESET_TENANT_CHECKOUT_DISCOUNT';\nexport const SET_TENANT_CHECKOUT_FORM_ERRORS = 'SET_TENANT_CHECKOUT_FORM_ERRORS';\nexport const RESET_TENANT_CHECKOUT_FORM_ERRORS = 'RESET_TENANT_CHECKOUT_FORM_ERRORS';\n\n\n// checkout\nexport const SET_CHECKOUT_LOADING = 'SET_CHECKOUT_LOADING';\nexport const CLEAR_CHECKOUT_FORM_ERRORS = 'CLEAR_CHECKOUT_FORM_ERRORS';\nexport const SET_CHECKOUT_DISCOUNT = 'SET_CHECKOUT_DISCOUNT';\nexport const RESET_CHECKOUT_DISCOUNT = 'RESET_CHECKOUT_DISCOUNT';\nexport const SET_ORDER_DELIVERY = 'SET_ORDER_DELIVERY';\nexport const SET_CHECKOUT_STRIPE = 'SET_CHECKOUT_STRIPE';\nexport const SET_CHECKOUT_AVAILABILITY = 'SET_CHECKOUT_AVAILABILITY';\nexport const SET_CHECKOUT_INITIALIZED = 'SET_CHECKOUT_INITIALIZED';\nexport const SET_CHECKOUT_ORDER_CUSTOMER = 'SET_CHECKOUT_ORDER_CUSTOMER';\nexport const SET_CHECKOUT_ORDER_CUSTOMER_BY_INDEX = 'SET_CHECKOUT_ORDER_CUSTOMER_BY_INDEX';\nexport const SET_CHECKOUT_ORDER_CUSTOMER_AGREE_TOS = 'SET_CHECKOUT_ORDER_CUSTOMER_AGREE_TOS';\nexport const SET_CHECKOUT_ORDER_DATES = 'SET_CHECKOUT_ORDER_DATES';\nexport const SET_CHECKOUT_ORDER_CUSTOM_FIELDS = 'SET_CHECKOUT_ORDER_CUSTOM_FIELDS';\nexport const SET_CHECKOUT_ORDER_DELIVERY_ADDRESS = 'SET_CHECKOUT_ORDER_DELIVERY_ADDRESS';\nexport const SET_CHECKOUT_RENTER_AUTHENTICATED = 'SET_CHECKOUT_RENTER_AUTHENTICATED';\nexport const SET_CHECKOUT_ORDER_REQUIRED_EXTRAS = 'SET_CHECKOUT_ORDER_REQUIRED_EXTRAS';\nexport const SET_RESERVATION_REQUEST_LISTING_ID = 'SET_RESERVATION_REQUEST_LISTING_ID';\nexport const SET_RESERVATION_REQUEST_DATES = 'SET_RESERVATION_REQUEST_DATES';\nexport const SET_RESERVATION_REQUEST_DURATIONS = 'SET_RESERVATION_REQUEST_DURATIONS';\nexport const SET_RESERVATION_REQUEST_EXTRAS = 'SET_RESERVATION_REQUEST_EXTRAS';\nexport const SET_RESERVATION_REQUEST_EXTRAS_V2 = 'SET_RESERVATION_REQUEST_EXTRAS_V2';\nexport const SET_RESERVATION_REQUEST_REQUIRED_EXTRAS_V2 = 'SET_RESERVATION_REQUEST_REQUIRED_EXTRAS_V2';\nexport const SET_RESERVATION_REQUEST_REQUIRED_EXTRAS_V2_AT_INDEX = 'SET_RESERVATION_REQUEST_REQUIRED_EXTRAS_V2_AT_INDEX';\nexport const SET_RESERVATION_REQUEST_PRICING = 'SET_RESERVATION_REQUEST_PRICING';\n\n// coupon.js\nexport const SET_COUPON_LOADING = 'SET_COUPON_LOADING';\nexport const SET_COUPONS = 'SET_COUPONS';\nexport const UPDATE_COUPON = 'UPDATE_COUPON';\nexport const SET_COUPON_REDEMPTIONS = 'SET_COUPON_REDEMPTIONS';\nexport const CLEAR_COUPON_FORM_ERRORS = 'CLEAR_COUPON_FORM_ERRORS';\nexport const SET_COUPON_FORM_ERROR = 'SET_COUPON_FORM_ERROR';\nexport const SET_COUPON_FORM_BUSY = 'SET_COUPON_FORM_BUSY';\n\n// notes.js\nexport const SET_NOTES_LOADING = 'SET_NOTES_LOADING';\n\n\n// custom-fields.js\nexport const SET_CUSTOM_FIELDS_LOADING = 'SET_CUSTOM_FIELDS_LOADING';\nexport const SET_CUSTOM_FIELDS = 'SET_CUSTOM_FIELDS';\nexport const SET_CUSTOM_FIELDS_FORM_BUSY = 'SET_CUSTOM_FIELDS_FORM_BUSY';\n\n// default-properties.js\nexport const SET_DEFAULT_PROPERTIES = 'SET_DEFAULT_PROPERTIES';\nexport const CLEAR_DEFAULT_PROPERTIES_FORM = 'CLEAR_DEFAULT_PROPERTIES_FORM';\nexport const SET_DEFAULT_PROPERTIES_FORM_BUSY = 'SET_DEFAULT_PROPERTIES_FORM_BUSY';\nexport const SET_DEFAULT_PROPERTIES_FORM_ERRORS = 'SET_DEFAULT_PROPERTIES_FORM_ERRORS';\n\n// tolls.js\nexport const SET_TOLLS_LOADING = 'SET_TOLLS_LOADING';\nexport const SET_TOLL_AGENCIES = 'SET_TOLL_AGENCIES';\nexport const SET_TOLL_ACCOUNTS = 'SET_TOLL_ACCOUNTS';\nexport const SET_TOLL_AGENCIES_WISHLIST = 'SET_TOLL_AGENCIES_WISHLIST';\nexport const SET_TOLL_TRANSACTIONS = 'SET_TOLL_TRANSACTIONS';\nexport const SET_TOLL_TRANSPONDERS = 'SET_TOLL_TRANSPONDERS';\n\n// whats-new.js\nexport const SET_WHATS_NEW_LOADING = 'SET_WHATS_NEW_LOADING';\nexport const SET_WHATS_NEW_COUNT = 'SET_WHATS_NEW_COUNT';\nexport const SET_WHATS_NEW = 'SET_WHATS_NEW';\nexport const MERGE_WHATS_NEW = 'MERGE_WHATS_NEW';\nexport const SET_WHATS_NEW_IMAGES = 'SET_WHATS_NEW_IMAGES';\nexport const SET_SHOW_WHATS_NEW_SIDEBAR = 'SET_SHOW_WHATS_NEW_SIDEBAR';\n\n\n// fleet.js\nexport const SET_COMPANY_BRANCHES = 'SET_COMPANY_BRANCHES';\nexport const SET_COMPANY_BRANCH = 'SET_COMPANY_BRANCH';\nexport const SET_COMPANY_BRANCHES_LOADING = 'SET_COMPANY_BRANCHES_LOADING';\nexport const SET_ACTION_ITEMS = 'SET_ACTION_ITEMS';\nexport const SET_ACTION_ITEM = 'SET_ACTION_ITEM';\nexport const ACTION_ITEM_CREATED = 'ACTION_ITEM_CREATED';\nexport const ACTION_ITEM_DELETED = 'ACTION_ITEM_DELETED';\nexport const SET_FLEET_FORM_ERROR = 'SET_FLEET_FORM_ERROR';\nexport const CLEAR_FLEET_FORM_ERRORS = 'CLEAR_FLEET_FORM_ERRORS';\n\n// outdoorsy.js\nexport const SET_OUTDOORSY_LOADING = 'SET_OUTDOORSY_LOADING';\nexport const SET_OUTDOORSY_CONNECTIONS = 'SET_OUTDOORSY_CONNECTIONS';\nexport const SET_OUTDOORSY_LISTINGS = 'SET_OUTDOORSY_LISTINGS';\nexport const SET_OUTDOORSY_BOOKINGS = 'SET_OUTDOORSY_BOOKINGS';\n\n// hq-rentals.js\nexport const SET_HQRENTALS_LOADING = 'SET_HQRENTALS_LOADING';\nexport const SET_HQRENTALS_CONNECTIONS = 'SET_HQRENTALS_CONNECTIONS';\nexport const SET_HQRENTALS_LISTINGS = 'SET_HQRENTALS_LISTINGS';\nexport const SET_HQRENTALS_BOOKINGS = 'SET_HQRENTALS_BOOKINGS';\nexport const SET_HQRENTALS_CONTACTS = 'SET_HQRENTALS_CONTACTS';\n\n// providers.js\nexport const SET_PROVIDERS_LOADING = 'SET_PROVIDERS_LOADING';\nexport const SET_PAYMENT_PROVIDERS = 'SET_PAYMENT_PROVIDERS';\n\n// tur0-research.js\nexport const SET_TURO_RESEARCH_LOADING = 'SET_TURO_RESEARCH_LOADING';\nexport const SET_TURO_ALL_DELIVERY_LOCATIONS = 'SET_TURO_ALL_DELIVERY_LOCATIONS';\nexport const SET_TURO_ALL_VEHICLE_MAKES = 'SET_TURO_ALL_VEHICLE_MAKES';\nexport const SET_TURO_RESEARCH_SEARCH_LIST = 'SET_TURO_RESEARCH_SEARCH_LIST';\n\n// commission-partner.js\nexport const SET_COMMISSION_PARTNER_LOADING = 'SET_COMMISSION_PARTNER_LOADING';\nexport const SET_COMMISSION_PARTNERS = 'SET_COMMISSION_PARTNERS';\nexport const SET_COMMISSION_PARTNER = 'SET_COMMISSION_PARTNER';\nexport const SET_COMMISSIONS = 'SET_COMMISSIONS';\nexport const CLEAR_COMMISSION_PARTNER_COUPON_FORM_ERRORS = 'CLEAR_COMMISSION_PARTNER_COUPON_FORM_ERRORS';\n\n// order\nexport const SET_ORDERS_LOADING = 'SET_ORDERS_LOADING';\nexport const SET_ORDER = 'SET_ORDER';\nexport const UPDATE_ORDER_LINE = 'UPDATE_ORDER_LINE';\nexport const SET_ORDER_DOCUMENT = 'SET_ORDER_DOCUMENT';\nexport const SET_ORDER_DOCUMENTS = 'SET_ORDER_DOCUMENTS';\nexport const SET_ORDER_DOCUMENT_DOWNLOAD_STATUS = 'SET_ORDER_DOCUMENT_DOWNLOAD_STATUS';\nexport const SET_ORDER_AVAILABILITY = 'SET_ORDER_AVAILABILITY';\nexport const SET_OPEN_PRICING_WIZARD_DIALOG = 'SET_OPEN_PRICING_WIZARD_DIALOG';\n\n// email.js\nexport const SET_EMAILS_LOADING = 'SET_EMAILS_LOADING';\nexport const SET_EMAILS = 'SET_EMAILS';\nexport const SET_EMAIL_HISTORY = 'SET_EMAIL_HISTORY';\nexport const SET_EMAIL_TEMPLATES = 'SET_EMAIL_TEMPLATES';\nexport const SET_EMAIL_TEMPLATE = 'SET_EMAIL_TEMPLATE';\nexport const SET_EMAIL_FORM_ERROR = 'SET_EMAIL_FORM_ERROR';\nexport const CLEAR_EMAIL_FORM_ERRORS = 'CLEAR_EMAIL_FORM_ERRORS';\n\n\n// webhooks.ts\nexport const SET_WEBHOOKS_LOADING = 'SET_WEBHOOKS_LOADING';\nexport const SET_WEBHOOKS_CONVERSATIONS = 'SET_WEBHOOKS_CONVERSATIONS';\nexport const SET_WEBHOOK_ENDPOINTS = 'SET_WEBHOOK_ENDPOINTS';\nexport const SET_WEBHOOK_ENDPOINT = 'SET_WEBHOOK_ENDPOINT';\nexport const SET_WEBHOOK_ENDPOINT_SECRET = 'SET_WEBHOOK_ENDPOINT_SECRET';\n\n// analytics.js\nexport const SET_ANALYTICS_LOADING = 'SET_ANALYTICS_LOADING';\nexport const SET_CONVERSION_ANALYTICS = 'SET_CONVERSION_ANALYTICS';\nexport const SET_VEHICLE_ANALYTICS = 'SET_VEHICLE_ANALYTICS';\nexport const SET_VEHICLES_ANALYTICS = 'SET_VEHICLES_ANALYTICS';\n\n// custodial.js\nexport const SET_CUSTODIAN_LOADING = 'SET_CUSTODIAN_LOADING';\nexport const SET_CUSTODIANS = 'SET_CUSTODIANS';\nexport const SET_CUSTODIAN_INVITE = 'SET_CUSTODIAN_INVITE';\nexport const SET_CUSTODIAN_LISTINGS = 'SET_CUSTODIAN_LISTINGS';\nexport const SET_CUSTODIAN_BOOKINGS = 'SET_CUSTODIAN_BOOKINGS';\n\n// pricing\nexport const SET_PRICING_LOADING = 'SET_PRICING_LOADING';\nexport const SET_PRICING_RULES = 'SET_PRICING_RULES';\n\nexport const SET_PRICING_STRUCTURE = 'SET_PRICING_STRUCTURE';\nexport const SET_PRICING_STRUCTURES = 'SET_PRICING_STRUCTURES';\nexport const RESET_CURRENT_WORKING_PRICING_STRUCTURE = 'RESET_CURRENT_WORKING_PRICING_STRUCTURE';\n\n// lula.js\nexport const SET_LULA_LOADING = 'SET_LULA_LOADING';\nexport const SET_LULA_CONNECTIONS = 'SET_LULA_CONNECTIONS';\nexport const SET_LULA_VEHICLES = 'SET_LULA_VEHICLES';\n\n\n// twisted-road.js\n\nexport const SET_TWISTED_ROAD_LOADING = 'SET_TWISTED_ROAD_LOADING';\nexport const SET_TWISTED_ROAD_CONNECTIONS = 'SET_TWISTED_ROAD_CONNECTIONS';\nexport const SET_TWISTED_ROAD_VEHICLES = 'SET_TWISTED_ROAD_VEHICLES';\n\n// files.js\nexport const SET_FILES = 'SET_FILES';\nexport const MERGE_FILES = 'MERGE_FILES';\nexport const SET_FILES_PAGINATION = 'SET_FILES_PAGINATION';\nexport const SET_FILES_LOADING = 'SET_FILES_LOADING';\n\n// barcode.js\nexport const SET_BARCODE_LOADING = 'SET_BARCODE_LOADING';\nexport const SET_BARCODE = 'SET_BARCODE';\n\n// trip-extras.js\nexport const SET_EXTRAS_LOADING = 'SET_EXTRAS_LOADING';\nexport const SET_EXTRAS = 'SET_EXTRAS';\nexport const SET_TRIP_EXTRA_SETTING_DIALOG = 'SET_TRIP_EXTRA_SETTING_DIALOG';\nexport const SET_REQUIRED_EXTRA_ADD_EDIT_DIALOG = 'SET_REQUIRED_EXTRA_ADD_EDIT_DIALOG';\nexport const SET_REQUIRED_EXTRA_ADD_EDIT_DATA = 'SET_REQUIRED_EXTRA_ADD_EDIT_DATA';\nexport const SET_REGULAR_EXTRA_DIALOG = 'SET_REGULAR_EXTRA_DIALOG';\nexport const SET_EXTRA_LISTINGS_DIALOG = 'SET_EXTRA_LISTINGS_DIALOG';\nexport const SET_REGULAR_EXTRA_DATA = 'SET_REGULAR_EXTRA_DATA';\n\n// axle\nexport const SET_AXLE_LOADING = 'SET_AXLE_LOADING';\nexport const SET_AXLE = 'SET_AXLE';\nexport const SET_AXLE_IGNITIONS = 'SET_AXLE_IGNITIONS';\nexport const MERGE_AXLE_IGNITION = 'MERGE_AXLE_IGNITION';\nexport const SET_INCOMING_AXLE_IGNITION = 'SET_INCOMING_AXLE_IGNITION';\n\n// theme.js\nexport const SET_STORE_THEMES = 'SET_STORE_THEMES';\nexport const SET_STORE_THEME_DATA = 'SET_STORE_THEME_DATA';\n\n// braintree.ts\nexport const SET_BRAINTREE_LOADING = 'SET_BRAINTREE_LOADING';\n\n// tags\nexport const SET_TAGS_LOADING = 'SET_TAGS_LOADING';\nexport const SET_TAGS = 'SET_TAGS';","import emitter from 'tiny-emitter/instance'\n\nexport const EventBus = {\n $on: (...args) => emitter.on(...args),\n $once: (...args) => emitter.once(...args),\n $off: (...args) => emitter.off(...args),\n $emit: (...args) => emitter.emit(...args)\n}\n","/**\n * Deep copy the given object.\n *\n * @param {Object} obj\n * @return {Object}\n */\nexport function deepCopy<T>(obj: T): T {\n if (obj === null || typeof obj !== 'object') {\n return obj;\n }\n\n const copy: any = Array.isArray(obj) ? [] : {};\n\n Object.keys(obj).forEach((key) => {\n copy[key] = deepCopy((obj as any)[key]);\n });\n\n return copy as T;\n}\n\n/**\n * If the given value is not an array, wrap it in one.\n *\n * @param value\n * @return {Array}\n */\nexport function arrayWrap<T>(value: T | T[]): T[] {\n return Array.isArray(value) ? value : [value];\n}\n","import {arrayWrap} from './util';\n\nexport default class Errors {\n errors: Record<string, string[]>;\n\n /**\n * Create a new error bag instance.\n */\n constructor() {\n this.errors = {};\n }\n\n /**\n * Set the errors object or field error messages.\n *\n * @param {Object|String} field\n * @param {Array|String|undefined} messages\n */\n set(field: string | Record<string, string[]>, messages: string[] | string | undefined = undefined): void {\n if (typeof field === 'object') {\n this.errors = field;\n } else {\n this.set({...this.errors, [field]: arrayWrap(messages)});\n }\n }\n\n /**\n * Get all the errors.\n *\n * @return {Object}\n */\n all(): Record<string, string[]> {\n return this.errors;\n }\n\n /**\n * Determine if there is an error for the given field.\n *\n * @param {String} field\n * @return {Boolean}\n */\n has(field: string): boolean {\n return this.errors.hasOwnProperty(field);\n }\n\n /**\n * Determine if there are any errors for the given fields.\n *\n * @param {...String} fields\n * @return {Boolean}\n */\n hasAny(...fields: string[]): boolean {\n return fields.some(field => this.has(field));\n }\n\n /**\n * Determine if there are any errors.\n *\n * @return {Boolean}\n */\n any(): boolean {\n return Object.keys(this.errors).length > 0;\n }\n\n /**\n * Get the first error message for the given field.\n *\n * @param {String} field\n * @return {String|undefined}\n */\n get(field: string): string | undefined {\n if (this.has(field)) {\n return this.getAll(field)[0];\n }\n }\n\n /**\n * Get all the error messages for the given field.\n *\n * @param {String} field\n * @return {Array}\n */\n getAll(field: string): string[] {\n return arrayWrap(this.errors[field] || []);\n }\n\n /**\n * Get the error message for the given fields.\n *\n * @param {...String} fields\n * @return {Array}\n */\n only(...fields: string[]): string[] {\n const messages = [];\n\n fields.forEach(field => {\n const message = this.get(field);\n\n if (message) {\n messages.push(message);\n }\n });\n\n return messages;\n }\n\n /**\n * Get all the errors in a flat array.\n *\n * @return {Array}\n */\n flatten(): string[] {\n return Object.values(this.errors).reduce((a, b) => a.concat(b), []);\n }\n\n /**\n * Clear one or all error fields.\n *\n * @param {String|undefined} field\n */\n clear(field: string | undefined = undefined): void {\n const errors: Record<string, string[]> = {};\n \n if (field) {\n Object.keys(this.errors).forEach(key => {\n if (key !== field) {\n errors[key] = this.errors[key];\n }\n });\n }\n\n this.set(errors);\n }\n}\n","import Errors from './Errors';\nimport {deepCopy} from './util';\n\ninterface ErrorResponse {\n data: {\n errors?: Record<string, string[]>;\n message?: string;\n }\n}\n\nclass Form<T extends Record<string, any>> {\n static ignore: string[];\n static errorMessage: string;\n busy: boolean;\n successful: boolean;\n originalData: T;\n errors: Errors;\n\n // Dynamic properties from `T`\n [key: string]: any; // Allows dynamic assignment of properties\n\n /**\n * Create a new form instance.\n *\n * @param {Object} data\n */\n constructor(data: T = {} as T) {\n this.busy = false;\n this.successful = false;\n this.errors = new Errors();\n this.originalData = deepCopy(data);\n\n Object.assign(this, data);\n }\n\n /**\n * Fill form data.\n *\n * @param {Object} data\n */\n fill(data: Partial<T> | undefined): void {\n if (!data || typeof data !== 'object') {\n // Do nothing if `data` is undefined or not an object\n return;\n }\n\n this.keys().forEach((key) => {\n if (key in data) {\n this[key] = data[key];\n }\n });\n }\n\n\n /**\n * Get the form data.\n *\n * @return {Object}\n */\n data(): T {\n const result = {} as T;\n this.keys().forEach((key) => {\n (result as any)[key] = this[key]; // Safely assign properties\n });\n return result;\n }\n\n dataGet(name: string): any {\n return this.originalData[name];\n }\n\n /**\n * Get the form data keys.\n *\n * @return {Array}\n */\n keys(): string[] {\n return Object.keys(this)\n .filter(key => !Form.ignore.includes(key));\n }\n\n startProcessing(): void {\n this.errors.clear();\n this.busy = true;\n this.successful = false;\n }\n\n finishProcessing(success = true): void {\n this.busy = false;\n this.successful = success;\n }\n\n /**\n * Extract the errors from the response object.\n *\n * @param {Object} response\n * @return {Object}\n */\n extractErrors(response: ErrorResponse): object {\n const {data} = response;\n\n if (!data || typeof data !== 'object') {\n return {error: Form.errorMessage};\n }\n\n if (data.errors) {\n return {...data.errors};\n }\n\n if (data.message) {\n return {error: data.message};\n }\n\n return {...data};\n };\n\n /**\n * Clear errors on keydown.\n *\n * @param {KeyboardEvent} event\n */\n onKeydown(event: KeyboardEvent): void {\n if (event.target instanceof Element) {\n const targetElement = event.target as HTMLInputElement;\n if (targetElement.name) {\n this.errors.clear(targetElement.name);\n }\n }\n }\n}\n\nForm.errorMessage = 'Something went wrong. Please try again.';\nForm.ignore = ['busy', 'successful', 'errors', 'originalData'];\n\nexport default Form;\n","import { Commit } from 'vuex';\nimport { AxiosResponse } from 'axios';\n\n/**\n * Sets the loading state for a given subject.\n * @param commit - Vuex commit function\n * @param commitName - The name of the commit\n * @param subject - The subject of the loading state\n * @param value - The loading state value\n */\nexport const setLoading = (commit: Commit, commitName: string, subject: string, value: boolean) => {\n commit(commitName, { subject, loading: value });\n};\n\n\n/**\n * Performs an API request with loading state management.\n * @template T - The type of the response data\n * @param commit - Vuex commit function\n * @param loadingCommitName - The name of the loading commit\n * @param subject - The subject of the loading state\n * @param apiCall - The API call function\n * @returns The response data\n * @throws The error thrown by the API call\n */\nexport const performApiRequest = async <T>(\n commit: Commit,\n loadingCommitName: string,\n subject: string,\n apiCall: () => Promise<AxiosResponse<T>>\n): Promise<T> => {\n try {\n setLoading(commit, loadingCommitName, subject, true);\n const response = await apiCall();\n return response.data;\n } catch (error) {\n console.error(`Error during API call for ${subject}: ${error}`);\n throw error;\n } finally {\n setLoading(commit, loadingCommitName, subject, false);\n }\n};","import axios from 'axios';\nimport * as types from '../mutation-types';\nimport {EventBus} from '@/plugins/eventBus';\nimport {Form} from '@/plugins/FWForms/index';\nimport {RootState} from '@/types/RootState';\nimport {Module} from 'vuex';\nimport {performApiRequest} from '@/store/helpers/vuex-helpers';\nimport {AffiliateInterface} from '@/types';\nimport {push} from 'notivue'\n\nexport interface AffiliateState {\n loading: Record<string, boolean>;\n affiliate: AffiliateInterface;\n affiliatePayouts: any[];\n affiliateApplication: any;\n affiliatePayoutsFuture: number;\n affiliatePayoutsPast: number;\n affiliateForm: Form<any>;\n}\n\n\nconst state: AffiliateState = {\n loading: {\n affiliateApplication: false,\n affiliateAgreeTOS: false,\n getAffiliate: false,\n getAffiliatePayouts: false,\n },\n affiliate: null,\n affiliatePayouts: [],\n affiliateApplication: {},\n affiliatePayoutsFuture: 0,\n affiliatePayoutsPast: 0,\n affiliateForm: new Form(),\n};\n\n\nconst mutations = {\n [types.SET_AFFILIATE_LOADING](state: AffiliateState, loading: { subject: string, loading: boolean }) {\n state.loading[loading.subject] = loading.loading;\n },\n [types.SET_AFFILIATE](state: AffiliateState, affiliate: AffiliateInterface) {\n state.affiliate = affiliate;\n },\n [types.SET_AFFILIATE_PAYOUTS](state: AffiliateState, payouts) {\n state.affiliatePayouts = payouts;\n },\n [types.SET_AFFILIATE_FUTURE_PAYOUT](state: AffiliateState, payout) {\n state.affiliatePayoutsFuture = payout;\n },\n [types.SET_AFFILIATE_PAST_PAYOUT](state: AffiliateState, payout) {\n state.affiliatePayoutsPast = payout;\n },\n [types.SET_AFFILIATE_APPLICATION](state: AffiliateState, application) {\n state.affiliateApplication = application;\n },\n};\n\n\nconst actions = {\n\n /**\n * Submit Affiliate application\n */\n async submitAffiliateApplication({commit, state}, data) {\n try {\n const responseData = await performApiRequest(commit, 'SET_AFFILIATE_LOADING', 'submit', () => axios.post('/v1/affiliate/signup', data));\n EventBus.$emit('affiliate-application-submit-success');\n commit(types.SET_AFFILIATE_APPLICATION, responseData.application);\n } catch (error) {\n state.affiliateForm.errors.set(error?.response?.data?.errors || []);\n }\n },\n\n /**\n * Get Affiliate application\n */\n async affiliateApplications({commit, state}) {\n try {\n const responseData = await performApiRequest(commit, 'SET_AFFILIATE_LOADING', 'affiliateApplication', () => axios.get('/v1/affiliate/application'));\n commit(types.SET_AFFILIATE_APPLICATION, responseData.application);\n commit(types.SET_AFFILIATE, responseData.affiliate);\n } catch (error) {\n state.affiliateForm.errors.set(error?.response?.data?.errors || []);\n }\n },\n\n /**\n * Get Affiliate\n */\n async getAffiliate({commit}) {\n try {\n const responseData = await performApiRequest(commit, 'SET_AFFILIATE_LOADING', 'getAffiliate', () => axios.get('/v1/affiliate'));\n commit(types.SET_AFFILIATE, responseData.affiliate);\n } catch (error) {\n state.affiliateForm.errors.set(error?.response?.data?.errors || []);\n }\n },\n\n /**\n * Get Affiliates Payouts\n */\n async getAffiliatePayouts({commit}) {\n try {\n const responseData = await performApiRequest(commit, 'SET_AFFILIATE_LOADING', 'getAffiliatePayouts', () => axios.get('/v1/affiliate/payouts'));\n commit(types.SET_AFFILIATE_PAYOUTS, responseData.payouts);\n commit(types.SET_AFFILIATE_FUTURE_PAYOUT, responseData.future_payouts);\n commit(types.SET_AFFILIATE_PAST_PAYOUT, responseData.past_payouts);\n } catch (error) {\n state.affiliateForm.errors.set(error?.response?.data?.errors || []);\n }\n },\n\n /**\n * Affiliate TOS agreement\n */\n async affiliateTOSAgree({commit}) {\n try {\n const responseData = await performApiRequest(commit, 'SET_AFFILIATE_LOADING', 'getAffiliate', () => axios.post('/v1/affiliate/agree-tos'));\n push.success({\n message: 'Agree to TOS recorded successfully!',\n });\n EventBus.$emit('affiliate-application-tos-agree-success');\n return responseData;\n } catch (error) {\n state.affiliateForm.errors.set(error?.response?.data?.errors || []);\n }\n },\n};\n\n\nconst affiliateModule: Module<AffiliateState, RootState> = {\n namespaced: true,\n state,\n mutations,\n actions,\n getters: {\n loading: (state: AffiliateState) => state.loading,\n affiliate: (state: AffiliateState) => state.affiliate,\n affiliateForm: (state: AffiliateState) => state.affiliateForm,\n affiliatePayouts: (state: AffiliateState) => state.affiliatePayouts,\n affiliateApplication: (state: AffiliateState) => state.affiliateApplication,\n affiliatePayoutsPast: (state: AffiliateState) => state.affiliatePayoutsPast,\n affiliatePayoutsFuture: (state: AffiliateState) => state.affiliatePayoutsFuture,\n }\n};\n\n\nexport default affiliateModule;","import dayjs from 'dayjs';\n\n/**\n * Builds a query string from an object of parameters, with optional ignore of empty values and handling of nested objects.\n * @param params - The parameters object\n * @param removeEmpty - Whether to remove empty values\n * @returns The query string\n */\nexport function createUrlQueryString(params: Record<string, any>, removeEmpty = true): string {\n if (params === undefined || typeof params !== 'object') {\n throw new Error('Params must be an object');\n }\n\n if (removeEmpty) {\n params = Object.entries(params)\n .filter(([, value]) => {\n // Filter out null, undefined, empty strings, and empty arrays\n if (value == null || value === '') {\n return false;\n }\n return !(Array.isArray(value) && value.length === 0);\n })\n .reduce((acc, [key, value]) => ({...acc, [key]: value}), {});\n }\n\n const buildNestedQueryString = (obj: Record<string, any>, parentKey = ''): string => {\n return Object.entries(obj)\n .map(([key, value]) => {\n const fullKey = parentKey ? `${parentKey}[${key}]` : key;\n\n if (value === null || value === undefined) {\n return `${fullKey}=`;\n } else if (typeof value === 'object' && !Array.isArray(value)) {\n return buildNestedQueryString(value, fullKey);\n } else if (Array.isArray(value)) {\n\n return value.length\n ? value.map((arrayItem) => `${fullKey}[]=${encodeURIComponent(String(arrayItem))}`).join('&')\n : `${fullKey}=`; // Handle empty arrays\n } else if (\n typeof value === 'string' ||\n typeof value === 'number' ||\n typeof value === 'boolean'\n ) {\n return `${fullKey}=${encodeURIComponent(value)}`;\n } else {\n throw new Error('Invalid value type');\n }\n })\n .join('&');\n }\n\n const queryString = buildNestedQueryString(params);\n return queryString ? `?${queryString}` : '';\n}\n\n\n/**\n * Builds a query string from an object of parameters, with optional ignore of empty values and handling of nested objects.\n * @param data - The parameters object\n * @param removeEmpty - Whether to remove empty values\n * @returns The query string\n */\nexport const createOrderUrlQueryString = (data, removeEmpty = false) => {\n if (data === undefined) {\n return '';\n }\n // Check if data is an object\n if (typeof data !== 'object') {\n throw new Error('Data must be an object');\n }\n\n if (removeEmpty) {\n Object.keys(data).forEach((key) => {\n if (data[key] === '' || data[key] === null || data[key] === undefined) {\n delete data[key];\n }\n });\n }\n\n let queryString = '?';\n\n Object.keys(data).forEach((key) => {\n if (typeof data[key] === 'object') {\n Object.keys(data[key]).forEach((subKey) => {\n queryString += `${key}[${subKey}]=${data[key][subKey]}&`;\n });\n } else {\n queryString += `${key}=${data[key]}&`;\n }\n });\n\n // Remove the leading ? if there are no params\n if (queryString === '?') {\n queryString = '';\n }\n\n // remove last & if any\n if (queryString[queryString.length - 1] === '&') {\n queryString = queryString.slice(0, -1);\n }\n return queryString;\n};\n\n\nexport const formatQueryStringDate = (date: string) => {\n if (!date) throw new Error('Date is required');\n\n const dateWithHyphen = (input: string): string => {\n const parts = input.split('-');\n let year = parts[0];\n if (year.length === 2) year = `20${year}`;\n\n const newDate = dayjs(`${year}-${parts[1]}-${parts[2]}`);\n if (newDate.isValid()) {\n return newDate.format('YYYY-MM-DD');\n }\n\n throw new Error('Invalid date format');\n };\n\n const dateWithoutHyphen = (input: string, format: string): string => {\n let year, month, day;\n\n if (format === 'YYYYMMDD') {\n year = input.substring(0, 4);\n month = input.substring(4, 6);\n day = input.substring(6, 8);\n } else if (format === 'YYMMDD') {\n year = `20${input.substring(0, 2)}`;\n month = input.substring(2, 4);\n day = input.substring(4, 6);\n } else {\n throw new Error('Invalid date format');\n }\n\n const newDate = dayjs(`${year}-${month}-${day}`);\n if (newDate.isValid()) {\n return newDate.format('YYYY-MM-DD');\n }\n\n throw new Error('Invalid date format');\n };\n\n if (date.includes('-')) {\n return dateWithHyphen(date);\n }\n\n if (date.length === 8) {\n return dateWithoutHyphen(date, 'YYYYMMDD');\n }\n\n if (date.length === 6) {\n return dateWithoutHyphen(date, 'YYMMDD');\n }\n\n throw new Error('Invalid date format');\n}\n\nexport const formatQueryStringTime = (time: string | undefined): string => {\n if (!time) return '10:00:00';\n\n if (time.length !== 4) {\n throw new Error('Invalid time format. Expected HHMM format.');\n }\n\n const hours = time.slice(0, 2);\n const minutes = time.slice(2, 4);\n\n return `${hours}:${minutes}:00`;\n};\n\n\nconst baseUrls: Record<string, string> = {\n production: 'https://tenant.fleetwire.io/',\n development: 'http://fleetwire.test/',\n};\n\n/**\n * Get the base URL based on the environment mode.\n * @param envOverride Optional override for the environment mode.\n * @returns The base URL for the current or specified environment.\n */\nexport const getBaseUrl = (envOverride: string | null = null): string => {\n const env = envOverride || import.meta.env.MODE;\n return baseUrls[env] || baseUrls.development;\n};","import {EventBus} from '@/plugins/eventBus';\nimport {performApiRequest} from '@/store/helpers/vuex-helpers';\nimport axios from 'axios';\nimport * as types from '@/store/mutation-types';\nimport {Module} from 'vuex';\nimport {createUrlQueryString} from '@/utils/urls';\n\nexport interface AnalyticsState {\n loading: Record<string, boolean>;\n analytics: any;\n conversionAnalytics: any;\n vehicleAnalytics: any;\n allVehiclesAnalytics: any;\n}\n\ntype AnalyticsData = {\n listing_id?: number,\n start?: string,\n end?: string,\n}\n\n\n// state\nconst state: AnalyticsState = {\n loading: {\n analytics: false,\n fetchCart: false,\n },\n analytics: {},\n conversionAnalytics: {},\n vehicleAnalytics: {},\n allVehiclesAnalytics: {},\n};\n\nconst mutations = {\n [types.SET_ANALYTICS_LOADING](state: AnalyticsState, loading: { subject: string, loading: boolean }) {\n state.loading[loading.subject] = loading.loading;\n },\n [types.SET_CONVERSION_ANALYTICS](state: AnalyticsState, analytics) {\n state.conversionAnalytics = analytics;\n },\n [types.SET_VEHICLE_ANALYTICS](state: AnalyticsState, analytics) {\n state.vehicleAnalytics = analytics;\n },\n [types.SET_VEHICLES_ANALYTICS](state: AnalyticsState, analytics) {\n state.allVehiclesAnalytics = analytics;\n },\n};\n\nconst actions = {\n\n /**\n * Fetch conversion analytics\n */\n async fetchConversionAnalytics({commit}, data: AnalyticsData = {}) {\n const query = createUrlQueryString({\n l_id: data?.listing_id,\n start: data?.start,\n end: data?.end,\n });\n\n try {\n const responseData = await performApiRequest(commit, 'SET_ANALYTICS_LOADING', 'analytics', () => axios.get(`/v1/conversion-analytics${query}`));\n commit(types.SET_CONVERSION_ANALYTICS, responseData.data);\n } catch (e) {\n EventBus.$emit('fetch-conversion-analytics-error', e.response);\n }\n },\n\n async fetchAllVehicleAnalytics({commit}) {\n try {\n const responseData = await performApiRequest(commit, 'SET_ANALYTICS_LOADING', 'analytics', () => axios.get('/v1/vehicle-analytics'));\n commit(types.SET_VEHICLES_ANALYTICS, responseData.analytics);\n } catch (e) {\n EventBus.$emit('fetch-conversion-analytics-error', e.response);\n }\n },\n\n async fetchVehicleAnalytics({commit}, data: AnalyticsData = {}) {\n const query = createUrlQueryString({\n l_id: data?.listing_id,\n start: data?.start,\n end: data?.end,\n });\n\n try {\n const responseData = await performApiRequest(commit, types.SET_ANALYTICS_LOADING, 'analytics', () => axios.get(`/v1/listings/utilization${query}`));\n commit(types.SET_VEHICLES_ANALYTICS, responseData.data);\n } catch (e) {\n EventBus.$emit('fetch-conversion-analytics-error', e.response);\n }\n },\n};\n\nconst analytics: Module<AnalyticsState, any> = {\n namespaced: true,\n state,\n mutations,\n actions,\n getters: {\n loading: (state: AnalyticsState) => state.loading,\n conversionAnalytics: (state: AnalyticsState) => state.conversionAnalytics,\n vehicleAnalytics: (state: AnalyticsState) => state.vehicleAnalytics,\n allVehiclesAnalytics: (state: AnalyticsState) => state.allVehiclesAnalytics,\n },\n};\n\n\nexport default analytics;","import Cookies from 'js-cookie';\nimport {MasqueradeData} from '@/types';\n\nconst TokenKey: string = 'token';\nconst RegisterTokenKey: string = 'register_id';\nconst MasqueradeKey: string = 'masquerade';\n\n\nexport function getToken(): string | undefined {\n return Cookies.get(TokenKey);\n}\n\n/**\n * Sets the authentication token.\n * @param token - The token string.\n * @param remember - Whether the token should persist across sessions.\n */\nexport function setToken(token: string, remember: boolean = true): void {\n const options = remember ? {expires: 365} : undefined;\n Cookies.set(TokenKey, token, options);\n}\n\nexport function removeToken(): void {\n Cookies.remove(TokenKey);\n}\n\n\n/**\n * Retrieves the register ID token from cookies.\n */\nexport function getRegisterId(): string | undefined {\n return Cookies.get(RegisterTokenKey);\n}\n\n\nexport function checkMasquerade(): MasqueradeData | undefined {\n const masqueradeCookie = Cookies.get(MasqueradeKey);\n if (!masqueradeCookie) return undefined;\n\n try {\n return JSON.parse(masqueradeCookie) as MasqueradeData;\n } catch (error) {\n console.error('Error parsing masquerade cookie:', error);\n return undefined;\n }\n}\n\nexport function setMasquerade(masquerade: MasqueradeData): Promise<void> {\n return new Promise((resolve) => {\n const masqueradeCookie = {\n on: true,\n admin: {\n email: masquerade.admin.email,\n uuid: masquerade.admin.uuid,\n token: getToken(),\n },\n user: {\n email: masquerade.user.email,\n uuid: masquerade.user.uuid,\n token: masquerade.token,\n },\n };\n\n Cookies.set(MasqueradeKey, JSON.stringify(masqueradeCookie), {expires: 2});\n\n resolve();\n });\n}\n\nexport function removeMasquerade(): void {\n const currentMasquerade: MasqueradeData = checkMasquerade();\n if (currentMasquerade) {\n setToken(currentMasquerade.admin.token);\n }\n Cookies.remove(MasqueradeKey);\n}\n\nexport function setRegisterToken(token: string): void {\n Cookies.set(RegisterTokenKey, token, {expires: 365});\n}\n\nexport function removeAllUserCookies(): void {\n Cookies.remove(TokenKey);\n Cookies.remove(RegisterTokenKey);\n Cookies.remove('fleetwireio_session');\n}\n","import {Module} from 'vuex'\nimport axios from 'axios';\nimport Cookies from 'js-cookie';\nimport {removeMasquerade, setMasquerade} from '@/utils/auth';\nimport * as types from '../mutation-types';\nimport {EventBus} from '@/plugins/eventBus';\nimport {AppCurrency, AppFeatures, AppState, MasqueradeData} from '@/types';\nimport {RootState} from '@/types/RootState';\nimport {performApiRequest} from '@/store/helpers/vuex-helpers';\n\nconst isChrome = /Chrome/.test(navigator.userAgent) && /Google Inc/.test(navigator.vendor);\nconst isSafari = /Safari/.test(navigator.userAgent) && /Apple Computer/.test(navigator.vendor);\nconst isFirefox = navigator.userAgent.toLowerCase().includes('firefox');\nconst isOpera = navigator.userAgent.toLowerCase().includes('opr');\n\nconst SIDEBAR_STORAGE_KEY = 'sidebarStatus';\nconst DEBUG_STORAGE_KEY = 'fw-debug';\n\n\nconst state: AppState = {\n loading: {\n fetchCurrency: false\n },\n build: null,\n polled_build: null,\n update_available: false,\n debugDrawerOpen: false,\n debugOn: false,\n sidebar: {\n opened: Cookies.get('sidebarStatus') ? !!+Cookies.get('sidebarStatus') : true,\n withoutAnimation: false,\n },\n listingView: Cookies.get('listingViewStatus') ? parseInt(Cookies.get('listingViewStatus'), 10) : 0,\n device: window.matchMedia('(max-width: 768px)').matches ? 'mobile' : 'desktop',\n deviceWidth: window.innerWidth,\n size: Cookies.get('size') || 'medium',\n\n secondaryNavViews: {\n listingImportNav: false,\n },\n possiblePermissions: [],\n masquerade: {\n on: false,\n admin: null,\n user: null,\n },\n fwPublicStripeKey: '',\n browser: {\n chrome: isChrome,\n opera: isOpera,\n safari: isSafari,\n firefox: isFirefox,\n },\n hoveredTurnoverBooking: null,\n rightSidebar: true,\n booting: true,\n setupItems: [\n {\n title: 'Create your account',\n id: 'settings.setup_checklist.create_account',\n completed: true,\n },\n {\n title: 'Set up operating hours',\n id: 'settings.setup_checklist.operating_hours',\n completed: false,\n },\n {\n title: 'Add tax rates',\n id: 'settings.setup_checklist.tax_rates',\n completed: false,\n },\n {\n title: 'Add a listing',\n id: 'settings.setup_checklist.add_listing',\n completed: false,\n },\n {\n title: 'Create order',\n id: 'settings.setup_checklist.create_order',\n completed: false,\n },\n {\n title: 'Set up payment methods',\n id: 'settings.setup_checklist.payment_methods',\n completed: false,\n },\n {\n title: 'Set up your website',\n id: 'settings.setup_checklist.website',\n completed: false,\n },\n {\n title: 'Choose a plan',\n id: 'settings.setup_checklist.choose_plan',\n completed: false,\n },\n ],\n appFeatures: null,\n featureWaitlist: null,\n countryOptions: [\n {\n name: 'Afghanistan',\n code: 'AF',\n phone: 93,\n symbol: '؋',\n currency: 'AFN',\n continent_code: 'AS',\n alpha_3: 'AFG',\n },\n {\n name: 'Åland Islands',\n code: 'AX',\n phone: 358,\n symbol: '€',\n currency: 'EUR',\n continent_code: 'EU',\n alpha_3: 'ALA',\n },\n {name: 'Albania', code: 'AL', phone: 355, symbol: 'Lek', currency: 'ALL', continent_code: 'EU', alpha_3: 'ALB'},\n {name: 'Algeria', code: 'DZ', phone: 213, symbol: 'دج', currency: 'DZD', continent_code: 'AF', alpha_3: 'DZA'},\n {\n name: 'American Samoa',\n code: 'AS',\n phone: 1684,\n symbol: '$',\n currency: 'USD',\n continent_code: 'OC',\n alpha_3: 'ASM',\n },\n {name: 'Andorra', code: 'AD', phone: 376, symbol: '€', currency: 'EUR', continent_code: 'EU', alpha_3: 'AND'},\n {name: 'Angola', code: 'AO', phone: 244, symbol: 'Kz', currency: 'AOA', continent_code: 'AF', alpha_3: 'AGO'},\n {name: 'Anguilla', code: 'AI', phone: 1264, symbol: '$', currency: 'XCD', continent_code: 'NA', alpha_3: 'AIA'},\n {\n name: 'Antarctica',\n code: 'AQ',\n phone: 672,\n symbol: '$',\n currency: 'AAD',\n continent_code: 'AN',\n alpha_3: 'ATA',\n },\n {\n name: 'Antigua & Barbuda',\n code: 'AG',\n phone: 1268,\n symbol: '$',\n currency: 'XCD',\n continent_code: 'NA',\n alpha_3: 'ATG',\n },\n {name: 'Argentina', code: 'AR', phone: 54, symbol: '$', currency: 'ARS', continent_code: 'SA', alpha_3: 'ARG'},\n {name: 'Armenia', code: 'AM', phone: 374, symbol: '֏', currency: 'AMD', continent_code: 'AS', alpha_3: 'ARM'},\n {name: 'Aruba', code: 'AW', phone: 297, symbol: 'ƒ', currency: 'AWG', continent_code: 'NA', alpha_3: 'ABW'},\n {name: 'Australia', code: 'AU', phone: 61, symbol: '$', currency: 'AUD', continent_code: 'OC', alpha_3: 'AUS'},\n {name: 'Austria', code: 'AT', phone: 43, symbol: '€', currency: 'EUR', continent_code: 'EU', alpha_3: 'AUT'},\n {\n name: 'Azerbaijan',\n code: 'AZ',\n phone: 994,\n symbol: 'm',\n currency: 'AZN',\n continent_code: 'AS',\n alpha_3: 'AZE',\n },\n {name: 'Bahamas', code: 'BS', phone: 1242, symbol: 'B$', currency: 'BSD', continent_code: 'NA', alpha_3: 'BHS'},\n {\n name: 'Bahrain',\n code: 'BH',\n phone: 973,\n symbol: '.د.ب',\n currency: 'BHD',\n continent_code: 'AS',\n alpha_3: 'BHR',\n },\n {\n name: 'Bangladesh',\n code: 'BD',\n phone: 880,\n symbol: '৳',\n currency: 'BDT',\n continent_code: 'AS',\n alpha_3: 'BGD',\n },\n {\n name: 'Barbados',\n code: 'BB',\n phone: 1246,\n symbol: 'Bds$',\n currency: 'BBD',\n continent_code: 'NA',\n alpha_3: 'BRB',\n },\n {name: 'Belarus', code: 'BY', phone: 375, symbol: 'Br', currency: 'BYN', continent_code: 'EU', alpha_3: 'BLR'},\n {name: 'Belgium', code: 'BE', phone: 32, symbol: '€', currency: 'EUR', continent_code: 'EU', alpha_3: 'BEL'},\n {name: 'Belize', code: 'BZ', phone: 501, symbol: '$', currency: 'BZD', continent_code: 'NA', alpha_3: 'BLZ'},\n {name: 'Benin', code: 'BJ', phone: 229, symbol: 'CFA', currency: 'XOF', continent_code: 'AF', alpha_3: 'BEN'},\n {name: 'Bermuda', code: 'BM', phone: 1441, symbol: '$', currency: 'BMD', continent_code: 'NA', alpha_3: 'BMU'},\n {name: 'Bhutan', code: 'BT', phone: 975, symbol: 'Nu.', currency: 'BTN', continent_code: 'AS', alpha_3: 'BTN'},\n {name: 'Bolivia', code: 'BO', phone: 591, symbol: 'Bs.', currency: 'BOB', continent_code: 'SA', alpha_3: 'BOL'},\n {\n name: 'Caribbean Netherlands',\n code: 'BQ',\n phone: 599,\n symbol: '$',\n currency: 'USD',\n continent_code: 'NA',\n alpha_3: 'BES',\n },\n {\n name: 'Bosnia & Herzegovina',\n code: 'BA',\n phone: 387,\n symbol: 'KM',\n currency: 'BAM',\n continent_code: 'EU',\n alpha_3: 'BIH',\n },\n {name: 'Botswana', code: 'BW', phone: 267, symbol: 'P', currency: 'BWP', continent_code: 'AF', alpha_3: 'BWA'},\n {\n name: 'Bouvet Island',\n code: 'BV',\n phone: 55,\n symbol: 'kr',\n currency: 'NOK',\n continent_code: 'AN',\n alpha_3: 'BVT',\n },\n {name: 'Brazil', code: 'BR', phone: 55, symbol: 'R$', currency: 'BRL', continent_code: 'SA', alpha_3: 'BRA'},\n {\n name: 'British Indian Ocean Territory',\n code: 'IO',\n phone: 246,\n symbol: '$',\n currency: 'USD',\n continent_code: 'AS',\n alpha_3: 'IOT',\n },\n {name: 'Brunei', code: 'BN', phone: 673, symbol: 'B$', currency: 'BND', continent_code: 'AS', alpha_3: 'BRN'},\n {\n name: 'Bulgaria',\n code: 'BG',\n phone: 359,\n symbol: 'Лв.',\n currency: 'BGN',\n continent_code: 'EU',\n alpha_3: 'BGR',\n },\n {\n name: 'Burkina Faso',\n code: 'BF',\n phone: 226,\n symbol: 'CFA',\n currency: 'XOF',\n continent_code: 'AF',\n alpha_3: 'BFA',\n },\n {name: 'Burundi', code: 'BI', phone: 257, symbol: 'FBu', currency: 'BIF', continent_code: 'AF', alpha_3: 'BDI'},\n {\n name: 'Cambodia',\n code: 'KH',\n phone: 855,\n symbol: 'KHR',\n currency: 'KHR',\n continent_code: 'AS',\n alpha_3: 'KHM',\n },\n {\n name: 'Cameroon',\n code: 'CM',\n phone: 237,\n symbol: 'FCFA',\n currency: 'XAF',\n continent_code: 'AF',\n alpha_3: 'CMR',\n },\n {name: 'Canada', code: 'CA', phone: 1, symbol: '$', currency: 'CAD', continent_code: 'NA', alpha_3: 'CAN'},\n {\n name: 'Cape Verde',\n code: 'CV',\n phone: 238,\n symbol: '$',\n currency: 'CVE',\n continent_code: 'AF',\n alpha_3: 'CPV',\n },\n {\n name: 'Cayman Islands',\n code: 'KY',\n phone: 1345,\n symbol: '$',\n currency: 'KYD',\n continent_code: 'NA',\n alpha_3: 'CYM',\n },\n {\n name: 'Central African Republic',\n code: 'CF',\n phone: 236,\n symbol: 'FCFA',\n currency: 'XAF',\n continent_code: 'AF',\n alpha_3: 'CAF',\n },\n {name: 'Chad', code: 'TD', phone: 235, symbol: 'FCFA', currency: 'XAF', continent_code: 'AF', alpha_3: 'TCD'},\n {name: 'Chile', code: 'CL', phone: 56, symbol: '$', currency: 'CLP', continent_code: 'SA', alpha_3: 'CHL'},\n {name: 'China', code: 'CN', phone: 86, symbol: '¥', currency: 'CNY', continent_code: 'AS', alpha_3: 'CHN'},\n {\n name: 'Christmas Island',\n code: 'CX',\n phone: 61,\n symbol: '$',\n currency: 'AUD',\n continent_code: 'AS',\n alpha_3: 'CXR',\n },\n {\n name: 'Cocos (Keeling) Islands',\n code: 'CC',\n phone: 672,\n symbol: '$',\n currency: 'AUD',\n continent_code: 'AS',\n alpha_3: 'CCK',\n },\n {name: 'Colombia', code: 'CO', phone: 57, symbol: '$', currency: 'COP', continent_code: 'SA', alpha_3: 'COL'},\n {name: 'Comoros', code: 'KM', phone: 269, symbol: 'CF', currency: 'KMF', continent_code: 'AF', alpha_3: 'COM'},\n {\n name: 'Congo - Brazzaville',\n code: 'CG',\n phone: 242,\n symbol: 'FC',\n currency: 'XAF',\n continent_code: 'AF',\n alpha_3: 'COG',\n },\n {\n name: 'Congo - Kinshasa',\n code: 'CD',\n phone: 242,\n symbol: 'FC',\n currency: 'CDF',\n continent_code: 'AF',\n alpha_3: 'COD',\n },\n {\n name: 'Cook Islands',\n code: 'CK',\n phone: 682,\n symbol: '$',\n currency: 'NZD',\n continent_code: 'OC',\n alpha_3: 'COK',\n },\n {\n name: 'Costa Rica',\n code: 'CR',\n phone: 506,\n symbol: '₡',\n currency: 'CRC',\n continent_code: 'NA',\n alpha_3: 'CRI',\n },\n {\n name: 'Côte d’Ivoire',\n code: 'CI',\n phone: 225,\n symbol: 'CFA',\n currency: 'XOF',\n continent_code: 'AF',\n alpha_3: 'CIV',\n },\n {name: 'Croatia', code: 'HR', phone: 385, symbol: 'kn', currency: 'HRK', continent_code: 'EU', alpha_3: 'HRV'},\n {name: 'Cuba', code: 'CU', phone: 53, symbol: '$', currency: 'CUP', continent_code: 'NA', alpha_3: 'CUB'},\n {name: 'Curaçao', code: 'CW', phone: 599, symbol: 'ƒ', currency: 'ANG', continent_code: 'NA', alpha_3: 'CUW'},\n {name: 'Cyprus', code: 'CY', phone: 357, symbol: '€', currency: 'EUR', continent_code: 'AS', alpha_3: 'CYP'},\n {name: 'Czechia', code: 'CZ', phone: 420, symbol: 'Kč', currency: 'CZK', continent_code: 'EU', alpha_3: 'CZE'},\n {name: 'Denmark', code: 'DK', phone: 45, symbol: 'Kr.', currency: 'DKK', continent_code: 'EU', alpha_3: 'DNK'},\n {\n name: 'Djibouti',\n code: 'DJ',\n phone: 253,\n symbol: 'Fdj',\n currency: 'DJF',\n continent_code: 'AF',\n alpha_3: 'DJI',\n },\n {name: 'Dominica', code: 'DM', phone: 1767, symbol: '$', currency: 'XCD', continent_code: 'NA', alpha_3: 'DMA'},\n {\n name: 'Dominican Republic',\n code: 'DO',\n phone: 1809,\n symbol: '$',\n currency: 'DOP',\n continent_code: 'NA',\n alpha_3: 'DOM',\n },\n {name: 'Ecuador', code: 'EC', phone: 593, symbol: '$', currency: 'USD', continent_code: 'SA', alpha_3: 'ECU'},\n {name: 'Egypt', code: 'EG', phone: 20, symbol: 'ج.م', currency: 'EGP', continent_code: 'AF', alpha_3: 'EGY'},\n {\n name: 'El Salvador',\n code: 'SV',\n phone: 503,\n symbol: '$',\n currency: 'USD',\n continent_code: 'NA',\n alpha_3: 'SLV',\n },\n {\n name: 'Equatorial Guinea',\n code: 'GQ',\n phone: 240,\n symbol: 'FCFA',\n currency: 'XAF',\n continent_code: 'AF',\n alpha_3: 'GNQ',\n },\n {name: 'Eritrea', code: 'ER', phone: 291, symbol: 'Nfk', currency: 'ERN', continent_code: 'AF', alpha_3: 'ERI'},\n {name: 'Estonia', code: 'EE', phone: 372, symbol: '€', currency: 'EUR', continent_code: 'EU', alpha_3: 'EST'},\n {\n name: 'Ethiopia',\n code: 'ET',\n phone: 251,\n symbol: 'Nkf',\n currency: 'ETB',\n continent_code: 'AF',\n alpha_3: 'ETH',\n },\n {\n name: 'Falkland Islands (Islas Malvinas)',\n code: 'FK',\n phone: 500,\n symbol: '£',\n currency: 'FKP',\n continent_code: 'SA',\n alpha_3: 'FLK',\n },\n {\n name: 'Faroe Islands',\n code: 'FO',\n phone: 298,\n symbol: 'Kr.',\n currency: 'DKK',\n continent_code: 'EU',\n alpha_3: 'FRO',\n },\n {name: 'Fiji', code: 'FJ', phone: 679, symbol: 'FJ$', currency: 'FJD', continent_code: 'OC', alpha_3: 'FJI'},\n {name: 'Finland', code: 'FI', phone: 358, symbol: '€', currency: 'EUR', continent_code: 'EU', alpha_3: 'FIN'},\n {name: 'France', code: 'FR', phone: 33, symbol: '€', currency: 'EUR', continent_code: 'EU', alpha_3: 'FRA'},\n {\n name: 'French Guiana',\n code: 'GF',\n phone: 594,\n symbol: '€',\n currency: 'EUR',\n continent_code: 'SA',\n alpha_3: 'GUF',\n },\n {\n name: 'French Polynesia',\n code: 'PF',\n phone: 689,\n symbol: '₣',\n currency: 'XPF',\n continent_code: 'OC',\n alpha_3: 'PYF',\n },\n {\n name: 'French Southern Territories',\n code: 'TF',\n phone: 262,\n symbol: '€',\n currency: 'EUR',\n continent_code: 'AN',\n alpha_3: 'ATF',\n },\n {name: 'Gabon', code: 'GA', phone: 241, symbol: 'FCFA', currency: 'XAF', continent_code: 'AF', alpha_3: 'GAB'},\n {name: 'Gambia', code: 'GM', phone: 220, symbol: 'D', currency: 'GMD', continent_code: 'AF', alpha_3: 'GMB'},\n {name: 'Georgia', code: 'GE', phone: 995, symbol: 'ლ', currency: 'GEL', continent_code: 'AS', alpha_3: 'GEO'},\n {name: 'Germany', code: 'DE', phone: 49, symbol: '€', currency: 'EUR', continent_code: 'EU', alpha_3: 'DEU'},\n {name: 'Ghana', code: 'GH', phone: 233, symbol: 'GH₵', currency: 'GHS', continent_code: 'AF', alpha_3: 'GHA'},\n {name: 'Gibraltar', code: 'GI', phone: 350, symbol: '£', currency: 'GIP', continent_code: 'EU', alpha_3: 'GIB'},\n {name: 'Greece', code: 'GR', phone: 30, symbol: '€', currency: 'EUR', continent_code: 'EU', alpha_3: 'GRC'},\n {\n name: 'Greenland',\n code: 'GL',\n phone: 299,\n symbol: 'Kr.',\n currency: 'DKK',\n continent_code: 'NA',\n alpha_3: 'GRL',\n },\n {name: 'Grenada', code: 'GD', phone: 1473, symbol: '$', currency: 'XCD', continent_code: 'NA', alpha_3: 'GRD'},\n {\n name: 'Guadeloupe',\n code: 'GP',\n phone: 590,\n symbol: '€',\n currency: 'EUR',\n continent_code: 'NA',\n alpha_3: 'GLP',\n },\n {name: 'Guam', code: 'GU', phone: 1671, symbol: '$', currency: 'USD', continent_code: 'OC', alpha_3: 'GUM'},\n {name: 'Guatemala', code: 'GT', phone: 502, symbol: 'Q', currency: 'GTQ', continent_code: 'NA', alpha_3: 'GTM'},\n {name: 'Guernsey', code: 'GG', phone: 44, symbol: '£', currency: 'GBP', continent_code: 'EU', alpha_3: 'GGY'},\n {name: 'Guinea', code: 'GN', phone: 224, symbol: 'FG', currency: 'GNF', continent_code: 'AF', alpha_3: 'GIN'},\n {\n name: 'Guinea-Bissau',\n code: 'GW',\n phone: 245,\n symbol: 'CFA',\n currency: 'XOF',\n continent_code: 'AF',\n alpha_3: 'GNB',\n },\n {name: 'Guyana', code: 'GY', phone: 592, symbol: '$', currency: 'GYD', continent_code: 'SA', alpha_3: 'GUY'},\n {name: 'Haiti', code: 'HT', phone: 509, symbol: 'G', currency: 'HTG', continent_code: 'NA', alpha_3: 'HTI'},\n {\n name: 'Heard & McDonald Islands',\n code: 'HM',\n phone: 0,\n symbol: '$',\n currency: 'AUD',\n continent_code: 'AN',\n alpha_3: 'HMD',\n },\n {\n name: 'Vatican City',\n code: 'VA',\n phone: 39,\n symbol: '€',\n currency: 'EUR',\n continent_code: 'EU',\n alpha_3: 'VAT',\n },\n {name: 'Honduras', code: 'HN', phone: 504, symbol: 'L', currency: 'HNL', continent_code: 'NA', alpha_3: 'HND'},\n {name: 'Hong Kong', code: 'HK', phone: 852, symbol: '$', currency: 'HKD', continent_code: 'AS', alpha_3: 'HKG'},\n {name: 'Hungary', code: 'HU', phone: 36, symbol: 'Ft', currency: 'HUF', continent_code: 'EU', alpha_3: 'HUN'},\n {name: 'Iceland', code: 'IS', phone: 354, symbol: 'kr', currency: 'ISK', continent_code: 'EU', alpha_3: 'ISL'},\n {name: 'India', code: 'IN', phone: 91, symbol: '₹', currency: 'INR', continent_code: 'AS', alpha_3: 'IND'},\n {name: 'Indonesia', code: 'ID', phone: 62, symbol: 'Rp', currency: 'IDR', continent_code: 'AS', alpha_3: 'IDN'},\n {name: 'Iran', code: 'IR', phone: 98, symbol: '﷼', currency: 'IRR', continent_code: 'AS', alpha_3: 'IRN'},\n {name: 'Iraq', code: 'IQ', phone: 964, symbol: 'د.ع', currency: 'IQD', continent_code: 'AS', alpha_3: 'IRQ'},\n {name: 'Ireland', code: 'IE', phone: 353, symbol: '€', currency: 'EUR', continent_code: 'EU', alpha_3: 'IRL'},\n {\n name: 'Isle of Man',\n code: 'IM',\n phone: 44,\n symbol: '£',\n currency: 'GBP',\n continent_code: 'EU',\n alpha_3: 'IMN',\n },\n {name: 'Israel', code: 'IL', phone: 972, symbol: '₪', currency: 'ILS', continent_code: 'AS', alpha_3: 'ISR'},\n {name: 'Italy', code: 'IT', phone: 39, symbol: '€', currency: 'EUR', continent_code: 'EU', alpha_3: 'ITA'},\n {name: 'Jamaica', code: 'JM', phone: 1876, symbol: 'J$', currency: 'JMD', continent_code: 'NA', alpha_3: 'JAM'},\n {name: 'Japan', code: 'JP', phone: 81, symbol: '¥', currency: 'JPY', continent_code: 'AS', alpha_3: 'JPN'},\n {name: 'Jersey', code: 'JE', phone: 44, symbol: '£', currency: 'GBP', continent_code: 'EU', alpha_3: 'JEY'},\n {name: 'Jordan', code: 'JO', phone: 962, symbol: 'ا.د', currency: 'JOD', continent_code: 'AS', alpha_3: 'JOR'},\n {name: 'Kazakhstan', code: 'KZ', phone: 7, symbol: 'лв', currency: 'KZT', continent_code: 'AS', alpha_3: 'KAZ'},\n {name: 'Kenya', code: 'KE', phone: 254, symbol: 'KSh', currency: 'KES', continent_code: 'AF', alpha_3: 'KEN'},\n {name: 'Kiribati', code: 'KI', phone: 686, symbol: '$', currency: 'AUD', continent_code: 'OC', alpha_3: 'KIR'},\n {\n name: 'North Korea',\n code: 'KP',\n phone: 850,\n symbol: '₩',\n currency: 'KPW',\n continent_code: 'AS',\n alpha_3: 'PRK',\n },\n {\n name: 'South Korea',\n code: 'KR',\n phone: 82,\n symbol: '₩',\n currency: 'KRW',\n continent_code: 'AS',\n alpha_3: 'KOR',\n },\n {name: 'Kosovo', code: 'XK', phone: 381, symbol: '€', currency: 'EUR', continent_code: 'EU', alpha_3: 'XKX'},\n {name: 'Kuwait', code: 'KW', phone: 965, symbol: 'ك.د', currency: 'KWD', continent_code: 'AS', alpha_3: 'KWT'},\n {\n name: 'Kyrgyzstan',\n code: 'KG',\n phone: 996,\n symbol: 'лв',\n currency: 'KGS',\n continent_code: 'AS',\n alpha_3: 'KGZ',\n },\n {name: 'Laos', code: 'LA', phone: 856, symbol: '₭', currency: 'LAK', continent_code: 'AS', alpha_3: 'LAO'},\n {name: 'Latvia', code: 'LV', phone: 371, symbol: '€', currency: 'EUR', continent_code: 'EU', alpha_3: 'LVA'},\n {name: 'Lebanon', code: 'LB', phone: 961, symbol: '£', currency: 'LBP', continent_code: 'AS', alpha_3: 'LBN'},\n {name: 'Lesotho', code: 'LS', phone: 266, symbol: 'L', currency: 'LSL', continent_code: 'AF', alpha_3: 'LSO'},\n {name: 'Liberia', code: 'LR', phone: 231, symbol: '$', currency: 'LRD', continent_code: 'AF', alpha_3: 'LBR'},\n {name: 'Libya', code: 'LY', phone: 218, symbol: 'د.ل', currency: 'LYD', continent_code: 'AF', alpha_3: 'LBY'},\n {\n name: 'Liechtenstein',\n code: 'LI',\n phone: 423,\n symbol: 'CHf',\n currency: 'CHF',\n continent_code: 'EU',\n alpha_3: 'LIE',\n },\n {name: 'Lithuania', code: 'LT', phone: 370, symbol: '€', currency: 'EUR', continent_code: 'EU', alpha_3: 'LTU'},\n {\n name: 'Luxembourg',\n code: 'LU',\n phone: 352,\n symbol: '€',\n currency: 'EUR',\n continent_code: 'EU',\n alpha_3: 'LUX',\n },\n {name: 'Macao', code: 'MO', phone: 853, symbol: '$', currency: 'MOP', continent_code: 'AS', alpha_3: 'MAC'},\n {\n name: 'North Macedonia',\n code: 'MK',\n phone: 389,\n symbol: 'ден',\n currency: 'MKD',\n continent_code: 'EU',\n alpha_3: 'MKD',\n },\n {\n name: 'Madagascar',\n code: 'MG',\n phone: 261,\n symbol: 'Ar',\n currency: 'MGA',\n continent_code: 'AF',\n alpha_3: 'MDG',\n },\n {name: 'Malawi', code: 'MW', phone: 265, symbol: 'MK', currency: 'MWK', continent_code: 'AF', alpha_3: 'MWI'},\n {name: 'Malaysia', code: 'MY', phone: 60, symbol: 'RM', currency: 'MYR', continent_code: 'AS', alpha_3: 'MYS'},\n {name: 'Maldives', code: 'MV', phone: 960, symbol: 'Rf', currency: 'MVR', continent_code: 'AS', alpha_3: 'MDV'},\n {name: 'Mali', code: 'ML', phone: 223, symbol: 'CFA', currency: 'XOF', continent_code: 'AF', alpha_3: 'MLI'},\n {name: 'Malta', code: 'MT', phone: 356, symbol: '€', currency: 'EUR', continent_code: 'EU', alpha_3: 'MLT'},\n {\n name: 'Marshall Islands',\n code: 'MH',\n phone: 692,\n symbol: '$',\n currency: 'USD',\n continent_code: 'OC',\n alpha_3: 'MHL',\n },\n {\n name: 'Martinique',\n code: 'MQ',\n phone: 596,\n symbol: '€',\n currency: 'EUR',\n continent_code: 'NA',\n alpha_3: 'MTQ',\n },\n {\n name: 'Mauritania',\n code: 'MR',\n phone: 222,\n symbol: 'MRU',\n currency: 'MRO',\n continent_code: 'AF',\n alpha_3: 'MRT',\n },\n {name: 'Mauritius', code: 'MU', phone: 230, symbol: '₨', currency: 'MUR', continent_code: 'AF', alpha_3: 'MUS'},\n {name: 'Mayotte', code: 'YT', phone: 262, symbol: '€', currency: 'EUR', continent_code: 'AF', alpha_3: 'MYT'},\n {name: 'Mexico', code: 'MX', phone: 52, symbol: '$', currency: 'MXN', continent_code: 'NA', alpha_3: 'MEX'},\n {\n name: 'Micronesia',\n code: 'FM',\n phone: 691,\n symbol: '$',\n currency: 'USD',\n continent_code: 'OC',\n alpha_3: 'FSM',\n },\n {name: 'Moldova', code: 'MD', phone: 373, symbol: 'L', currency: 'MDL', continent_code: 'EU', alpha_3: 'MDA'},\n {name: 'Monaco', code: 'MC', phone: 377, symbol: '€', currency: 'EUR', continent_code: 'EU', alpha_3: 'MCO'},\n {name: 'Mongolia', code: 'MN', phone: 976, symbol: '₮', currency: 'MNT', continent_code: 'AS', alpha_3: 'MNG'},\n {\n name: 'Montenegro',\n code: 'ME',\n phone: 382,\n symbol: '€',\n currency: 'EUR',\n continent_code: 'EU',\n alpha_3: 'MNE',\n },\n {\n name: 'Montserrat',\n code: 'MS',\n phone: 1664,\n symbol: '$',\n currency: 'XCD',\n continent_code: 'NA',\n alpha_3: 'MSR',\n },\n {name: 'Morocco', code: 'MA', phone: 212, symbol: 'DH', currency: 'MAD', continent_code: 'AF', alpha_3: 'MAR'},\n {\n name: 'Mozambique',\n code: 'MZ',\n phone: 258,\n symbol: 'MT',\n currency: 'MZN',\n continent_code: 'AF',\n alpha_3: 'MOZ',\n },\n {\n name: 'Myanmar (Burma)',\n code: 'MM',\n phone: 95,\n symbol: 'K',\n currency: 'MMK',\n continent_code: 'AS',\n alpha_3: 'MMR',\n },\n {name: 'Namibia', code: 'NA', phone: 264, symbol: '$', currency: 'NAD', continent_code: 'AF', alpha_3: 'NAM'},\n {name: 'Nauru', code: 'NR', phone: 674, symbol: '$', currency: 'AUD', continent_code: 'OC', alpha_3: 'NRU'},\n {name: 'Nepal', code: 'NP', phone: 977, symbol: '₨', currency: 'NPR', continent_code: 'AS', alpha_3: 'NPL'},\n {\n name: 'Netherlands',\n code: 'NL',\n phone: 31,\n symbol: '€',\n currency: 'EUR',\n continent_code: 'EU',\n alpha_3: 'NLD',\n },\n {name: 'Curaçao', code: 'AN', phone: 599, symbol: 'NAf', currency: 'ANG', continent_code: 'NA', alpha_3: 'ANT'},\n {\n name: 'New Caledonia',\n code: 'NC',\n phone: 687,\n symbol: '₣',\n currency: 'XPF',\n continent_code: 'OC',\n alpha_3: 'NCL',\n },\n {\n name: 'New Zealand',\n code: 'NZ',\n phone: 64,\n symbol: '$',\n currency: 'NZD',\n continent_code: 'OC',\n alpha_3: 'NZL',\n },\n {\n name: 'Nicaragua',\n code: 'NI',\n phone: 505,\n symbol: 'C$',\n currency: 'NIO',\n continent_code: 'NA',\n alpha_3: 'NIC',\n },\n {name: 'Niger', code: 'NE', phone: 227, symbol: 'CFA', currency: 'XOF', continent_code: 'AF', alpha_3: 'NER'},\n {name: 'Nigeria', code: 'NG', phone: 234, symbol: '₦', currency: 'NGN', continent_code: 'AF', alpha_3: 'NGA'},\n {name: 'Niue', code: 'NU', phone: 683, symbol: '$', currency: 'NZD', continent_code: 'OC', alpha_3: 'NIU'},\n {\n name: 'Norfolk Island',\n code: 'NF',\n phone: 672,\n symbol: '$',\n currency: 'AUD',\n continent_code: 'OC',\n alpha_3: 'NFK',\n },\n {\n name: 'Northern Mariana Islands',\n code: 'MP',\n phone: 1670,\n symbol: '$',\n currency: 'USD',\n continent_code: 'OC',\n alpha_3: 'MNP',\n },\n {name: 'Norway', code: 'NO', phone: 47, symbol: 'kr', currency: 'NOK', continent_code: 'EU', alpha_3: 'NOR'},\n {name: 'Oman', code: 'OM', phone: 968, symbol: '.ع.ر', currency: 'OMR', continent_code: 'AS', alpha_3: 'OMN'},\n {name: 'Pakistan', code: 'PK', phone: 92, symbol: '₨', currency: 'PKR', continent_code: 'AS', alpha_3: 'PAK'},\n {name: 'Palau', code: 'PW', phone: 680, symbol: '$', currency: 'USD', continent_code: 'OC', alpha_3: 'PLW'},\n {name: 'Palestine', code: 'PS', phone: 970, symbol: '₪', currency: 'ILS', continent_code: 'AS', alpha_3: 'PSE'},\n {name: 'Panama', code: 'PA', phone: 507, symbol: 'B/.', currency: 'PAB', continent_code: 'NA', alpha_3: 'PAN'},\n {\n name: 'Papua New Guinea',\n code: 'PG',\n phone: 675,\n symbol: 'K',\n currency: 'PGK',\n continent_code: 'OC',\n alpha_3: 'PNG',\n },\n {name: 'Paraguay', code: 'PY', phone: 595, symbol: '₲', currency: 'PYG', continent_code: 'SA', alpha_3: 'PRY'},\n {name: 'Peru', code: 'PE', phone: 51, symbol: 'S/.', currency: 'PEN', continent_code: 'SA', alpha_3: 'PER'},\n {\n name: 'Philippines',\n code: 'PH',\n phone: 63,\n symbol: '₱',\n currency: 'PHP',\n continent_code: 'AS',\n alpha_3: 'PHL',\n },\n {\n name: 'Pitcairn Islands',\n code: 'PN',\n phone: 64,\n symbol: '$',\n currency: 'NZD',\n continent_code: 'OC',\n alpha_3: 'PCN',\n },\n {name: 'Poland', code: 'PL', phone: 48, symbol: 'zł', currency: 'PLN', continent_code: 'EU', alpha_3: 'POL'},\n {name: 'Portugal', code: 'PT', phone: 351, symbol: '€', currency: 'EUR', continent_code: 'EU', alpha_3: 'PRT'},\n {\n name: 'Puerto Rico',\n code: 'PR',\n phone: 1787,\n symbol: '$',\n currency: 'USD',\n continent_code: 'NA',\n alpha_3: 'PRI',\n },\n {name: 'Qatar', code: 'QA', phone: 974, symbol: 'ق.ر', currency: 'QAR', continent_code: 'AS', alpha_3: 'QAT'},\n {name: 'Réunion', code: 'RE', phone: 262, symbol: '€', currency: 'EUR', continent_code: 'AF', alpha_3: 'REU'},\n {name: 'Romania', code: 'RO', phone: 40, symbol: 'lei', currency: 'RON', continent_code: 'EU', alpha_3: 'ROM'},\n {name: 'Russia', code: 'RU', phone: 70, symbol: '₽', currency: 'RUB', continent_code: 'AS', alpha_3: 'RUS'},\n {name: 'Rwanda', code: 'RW', phone: 250, symbol: 'FRw', currency: 'RWF', continent_code: 'AF', alpha_3: 'RWA'},\n {\n name: 'St. Barthélemy',\n code: 'BL',\n phone: 590,\n symbol: '€',\n currency: 'EUR',\n continent_code: 'NA',\n alpha_3: 'BLM',\n },\n {\n name: 'St. Helena',\n code: 'SH',\n phone: 290,\n symbol: '£',\n currency: 'SHP',\n continent_code: 'AF',\n alpha_3: 'SHN',\n },\n {\n name: 'St. Kitts & Nevis',\n code: 'KN',\n phone: 1869,\n symbol: '$',\n currency: 'XCD',\n continent_code: 'NA',\n alpha_3: 'KNA',\n },\n {\n name: 'St. Lucia',\n code: 'LC',\n phone: 1758,\n symbol: '$',\n currency: 'XCD',\n continent_code: 'NA',\n alpha_3: 'LCA',\n },\n {\n name: 'St. Martin',\n code: 'MF',\n phone: 590,\n symbol: '€',\n currency: 'EUR',\n continent_code: 'NA',\n alpha_3: 'MAF',\n },\n {\n name: 'St. Pierre & Miquelon',\n code: 'PM',\n phone: 508,\n symbol: '€',\n currency: 'EUR',\n continent_code: 'NA',\n alpha_3: 'SPM',\n },\n {\n name: 'St. Vincent & Grenadines',\n code: 'VC',\n phone: 1784,\n symbol: '$',\n currency: 'XCD',\n continent_code: 'NA',\n alpha_3: 'VCT',\n },\n {name: 'Samoa', code: 'WS', phone: 684, symbol: 'SAT', currency: 'WST', continent_code: 'OC', alpha_3: 'WSM'},\n {\n name: 'San Marino',\n code: 'SM',\n phone: 378,\n symbol: '€',\n currency: 'EUR',\n continent_code: 'EU',\n alpha_3: 'SMR',\n },\n {\n name: 'São Tomé & Príncipe',\n code: 'ST',\n phone: 239,\n symbol: 'Db',\n currency: 'STD',\n continent_code: 'AF',\n alpha_3: 'STP',\n },\n {\n name: 'Saudi Arabia',\n code: 'SA',\n phone: 966,\n symbol: '﷼',\n currency: 'SAR',\n continent_code: 'AS',\n alpha_3: 'SAU',\n },\n {name: 'Senegal', code: 'SN', phone: 221, symbol: 'CFA', currency: 'XOF', continent_code: 'AF', alpha_3: 'SEN'},\n {name: 'Serbia', code: 'RS', phone: 381, symbol: 'din', currency: 'RSD', continent_code: 'EU', alpha_3: 'SRB'},\n {name: 'Serbia', code: 'CS', phone: 381, symbol: 'din', currency: 'RSD', continent_code: 'EU', alpha_3: 'SCG'},\n {\n name: 'Seychelles',\n code: 'SC',\n phone: 248,\n symbol: 'SRe',\n currency: 'SCR',\n continent_code: 'AF',\n alpha_3: 'SYC',\n },\n {\n name: 'Sierra Leone',\n code: 'SL',\n phone: 232,\n symbol: 'Le',\n currency: 'SLL',\n continent_code: 'AF',\n alpha_3: 'SLE',\n },\n {name: 'Singapore', code: 'SG', phone: 65, symbol: '$', currency: 'SGD', continent_code: 'AS', alpha_3: 'SGP'},\n {\n name: 'Sint Maarten',\n code: 'SX',\n phone: 1,\n symbol: 'ƒ',\n currency: 'ANG',\n continent_code: 'NA',\n alpha_3: 'SXM',\n },\n {name: 'Slovakia', code: 'SK', phone: 421, symbol: '€', currency: 'EUR', continent_code: 'EU', alpha_3: 'SVK'},\n {name: 'Slovenia', code: 'SI', phone: 386, symbol: '€', currency: 'EUR', continent_code: 'EU', alpha_3: 'SVN'},\n {\n name: 'Solomon Islands',\n code: 'SB',\n phone: 677,\n symbol: 'Si$',\n currency: 'SBD',\n continent_code: 'OC',\n alpha_3: 'SLB',\n },\n {\n name: 'Somalia',\n code: 'SO',\n phone: 252,\n symbol: 'Sh.so.',\n currency: 'SOS',\n continent_code: 'AF',\n alpha_3: 'SOM',\n },\n {\n name: 'South Africa',\n code: 'ZA',\n phone: 27,\n symbol: 'R',\n currency: 'ZAR',\n continent_code: 'AF',\n alpha_3: 'ZAF',\n },\n {\n name: 'South Georgia & South Sandwich Islands',\n code: 'GS',\n phone: 500,\n symbol: '£',\n currency: 'GBP',\n continent_code: 'AN',\n alpha_3: 'SGS',\n },\n {\n name: 'South Sudan',\n code: 'SS',\n phone: 211,\n symbol: '£',\n currency: 'SSP',\n continent_code: 'AF',\n alpha_3: 'SSD',\n },\n {name: 'Spain', code: 'ES', phone: 34, symbol: '€', currency: 'EUR', continent_code: 'EU', alpha_3: 'ESP'},\n {name: 'Sri Lanka', code: 'LK', phone: 94, symbol: 'Rs', currency: 'LKR', continent_code: 'AS', alpha_3: 'LKA'},\n {name: 'Sudan', code: 'SD', phone: 249, symbol: '.س.ج', currency: 'SDG', continent_code: 'AF', alpha_3: 'SDN'},\n {name: 'Suriname', code: 'SR', phone: 597, symbol: '$', currency: 'SRD', continent_code: 'SA', alpha_3: 'SUR'},\n {\n name: 'Svalbard & Jan Mayen',\n code: 'SJ',\n phone: 47,\n symbol: 'kr',\n currency: 'NOK',\n continent_code: 'EU',\n alpha_3: 'SJM',\n },\n {name: 'Eswatini', code: 'SZ', phone: 268, symbol: 'E', currency: 'SZL', continent_code: 'AF', alpha_3: 'SWZ'},\n {name: 'Sweden', code: 'SE', phone: 46, symbol: 'kr', currency: 'SEK', continent_code: 'EU', alpha_3: 'SWE'},\n {\n name: 'Switzerland',\n code: 'CH',\n phone: 41,\n symbol: 'CHf',\n currency: 'CHF',\n continent_code: 'EU',\n alpha_3: 'CHE',\n },\n {name: 'Syria', code: 'SY', phone: 963, symbol: 'LS', currency: 'SYP', continent_code: 'AS', alpha_3: 'SYR'},\n {name: 'Taiwan', code: 'TW', phone: 886, symbol: '$', currency: 'TWD', continent_code: 'AS', alpha_3: 'TWN'},\n {\n name: 'Tajikistan',\n code: 'TJ',\n phone: 992,\n symbol: 'SM',\n currency: 'TJS',\n continent_code: 'AS',\n alpha_3: 'TJK',\n },\n {\n name: 'Tanzania',\n code: 'TZ',\n phone: 255,\n symbol: 'TSh',\n currency: 'TZS',\n continent_code: 'AF',\n alpha_3: 'TZA',\n },\n {name: 'Thailand', code: 'TH', phone: 66, symbol: '฿', currency: 'THB', continent_code: 'AS', alpha_3: 'THA'},\n {\n name: 'Timor-Leste',\n code: 'TL',\n phone: 670,\n symbol: '$',\n currency: 'USD',\n continent_code: 'AS',\n alpha_3: 'TLS',\n },\n {name: 'Togo', code: 'TG', phone: 228, symbol: 'CFA', currency: 'XOF', continent_code: 'AF', alpha_3: 'TGO'},\n {name: 'Tokelau', code: 'TK', phone: 690, symbol: '$', currency: 'NZD', continent_code: 'OC', alpha_3: 'TKL'},\n {name: 'Tonga', code: 'TO', phone: 676, symbol: '$', currency: 'TOP', continent_code: 'OC', alpha_3: 'TON'},\n {\n name: 'Trinidad & Tobago',\n code: 'TT',\n phone: 1868,\n symbol: '$',\n currency: 'TTD',\n continent_code: 'NA',\n alpha_3: 'TTO',\n },\n {name: 'Tunisia', code: 'TN', phone: 216, symbol: 'ت.د', currency: 'TND', continent_code: 'AF', alpha_3: 'TUN'},\n {name: 'Turkey', code: 'TR', phone: 90, symbol: '₺', currency: 'TRY', continent_code: 'AS', alpha_3: 'TUR'},\n {\n name: 'Turkmenistan',\n code: 'TM',\n phone: 7370,\n symbol: 'T',\n currency: 'TMT',\n continent_code: 'AS',\n alpha_3: 'TKM',\n },\n {\n name: 'Turks & Caicos Islands',\n code: 'TC',\n phone: 1649,\n symbol: '$',\n currency: 'USD',\n continent_code: 'NA',\n alpha_3: 'TCA',\n },\n {name: 'Tuvalu', code: 'TV', phone: 688, symbol: '$', currency: 'AUD', continent_code: 'OC', alpha_3: 'TUV'},\n {name: 'Uganda', code: 'UG', phone: 256, symbol: 'USh', currency: 'UGX', continent_code: 'AF', alpha_3: 'UGA'},\n {name: 'Ukraine', code: 'UA', phone: 380, symbol: '₴', currency: 'UAH', continent_code: 'EU', alpha_3: 'UKR'},\n {\n name: 'United Arab Emirates',\n code: 'AE',\n phone: 971,\n symbol: 'إ.د',\n currency: 'AED',\n continent_code: 'AS',\n alpha_3: 'ARE',\n },\n {\n name: 'United Kingdom',\n code: 'GB',\n phone: 44,\n symbol: '£',\n currency: 'GBP',\n continent_code: 'EU',\n alpha_3: 'GBR',\n },\n {\n name: 'United States',\n code: 'US',\n phone: 1,\n symbol: '$',\n currency: 'USD',\n continent_code: 'NA',\n alpha_3: 'USA',\n },\n {\n name: 'U.S. Outlying Islands',\n code: 'UM',\n phone: 1,\n symbol: '$',\n currency: 'USD',\n continent_code: 'NA',\n alpha_3: 'UMI',\n },\n {name: 'Uruguay', code: 'UY', phone: 598, symbol: '$', currency: 'UYU', continent_code: 'SA', alpha_3: 'URY'},\n {\n name: 'Uzbekistan',\n code: 'UZ',\n phone: 998,\n symbol: 'лв',\n currency: 'UZS',\n continent_code: 'AS',\n alpha_3: 'UZB',\n },\n {name: 'Vanuatu', code: 'VU', phone: 678, symbol: 'VT', currency: 'VUV', continent_code: 'OC', alpha_3: 'VUT'},\n {name: 'Venezuela', code: 'VE', phone: 58, symbol: 'Bs', currency: 'VEF', continent_code: 'SA', alpha_3: 'VEN'},\n {name: 'Vietnam', code: 'VN', phone: 84, symbol: '₫', currency: 'VND', continent_code: 'AS', alpha_3: 'VNM'},\n {\n name: 'British Virgin Islands',\n code: 'VG',\n phone: 1284,\n symbol: '$',\n currency: 'USD',\n continent_code: 'NA',\n alpha_3: 'VGB',\n },\n {\n name: 'U.S. Virgin Islands',\n code: 'VI',\n phone: 1340,\n symbol: '$',\n currency: 'USD',\n continent_code: 'NA',\n alpha_3: 'VIR',\n },\n {\n name: 'Wallis & Futuna',\n code: 'WF',\n phone: 681,\n symbol: '₣',\n currency: 'XPF',\n continent_code: 'OC',\n alpha_3: 'WLF',\n },\n {\n name: 'Western Sahara',\n code: 'EH',\n phone: 212,\n symbol: 'MAD',\n currency: 'MAD',\n continent_code: 'AF',\n alpha_3: 'ESH',\n },\n {name: 'Yemen', code: 'YE', phone: 967, symbol: '﷼', currency: 'YER', continent_code: 'AS', alpha_3: 'YEM'},\n {name: 'Zambia', code: 'ZM', phone: 260, symbol: 'ZK', currency: 'ZMW', continent_code: 'AF', alpha_3: 'ZMB'},\n {name: 'Zimbabwe', code: 'ZW', phone: 263, symbol: '$', currency: 'ZWL', continent_code: 'AF', alpha_3: 'ZWE'},\n ],\n currentCurrency: null,\n};\n\nconst appModule: Module<AppState, RootState> = {\n namespaced: true,\n\n state,\n\n getters: {\n loading: (state: AppState) => state.loading,\n booting: (state: AppState) => state.booting,\n setupItems: (state: AppState) => state.setupItems,\n sidebar: (state: AppState) => state.sidebar,\n rightSidebar: (state: AppState) => state.rightSidebar,\n browser: (state: AppState) => state.browser,\n listingView: (state: AppState) => state.listingView,\n size: (state: AppState) => state.size,\n device: (state: AppState) => state.device,\n deviceWidth: (state: AppState) => state.deviceWidth,\n secondaryNavViews: (state: AppState) => state.secondaryNavViews,\n possiblePermissions: (state: AppState) => [...state.possiblePermissions].sort((a, b) => a.name.localeCompare(b.name)),\n masquerade: (state: AppState) => state.masquerade,\n fwPublicStripeKey: (state: AppState) => state.fwPublicStripeKey,\n build: (state: AppState) => state.build,\n polled_build: (state: AppState) => state.polled_build,\n update_available: (state: AppState) => state.update_available,\n debugDrawerOpen: (state: AppState) => state.debugDrawerOpen,\n debugOn: (state: AppState) => state.debugOn,\n hoveredTurnoverBooking: (state: AppState) => state.hoveredTurnoverBooking,\n appFeatures: (state: AppState) => state.appFeatures,\n featureWaitlist: (state: AppState) => state.featureWaitlist,\n countryOptions: (state: AppState) => state.countryOptions,\n currentCurrency: (state: AppState) => state.currentCurrency,\n },\n\n mutations: {\n [types.SET_APP_LOADING](state: AppState, loading: { subject: string, loading: boolean }) {\n state.loading[loading.subject] = loading.loading;\n },\n [types.INITIALIZE_STATE](state: AppState) {\n state.debugDrawerOpen = [true, 'true'].includes(localStorage.getItem(DEBUG_STORAGE_KEY));\n },\n [types.SET_APP_BOOTING](state: AppState, booting: boolean) {\n state.booting = booting;\n },\n [types.TOGGLE_RIGHT_SIDEBAR](state: AppState) {\n state.rightSidebar = !state.rightSidebar;\n },\n [types.TOGGLE_SIDEBAR](state: AppState) {\n state.sidebar.opened = !state.sidebar.opened;\n state.sidebar.withoutAnimation = false;\n },\n [types.SET_HOVERED_TURNOVER_BOOKING_ID](state: AppState, id) {\n state.hoveredTurnoverBooking = id;\n },\n [types.TOGGLE_LISTING_VIEW](state: AppState, value) {\n state.listingView = value;\n Cookies.set('listingViewStatus', state.listingView);\n },\n [types.TOGGLE_SECONDARY_IMPORT_NAV_VIEW](state: AppState) {\n state.secondaryNavViews.listingImportNav = !state.secondaryNavViews.listingImportNav;\n },\n\n [types.CLOSE_SIDEBAR](state: AppState, withoutAnimation) {\n Cookies.set('sidebarStatus', 0);\n state.sidebar.opened = false;\n state.sidebar.withoutAnimation = withoutAnimation;\n },\n [types.TOGGLE_DEVICE](state: AppState, device) {\n state.device = device;\n },\n [types.SET_ALL_POSSIBLE_PERMISSIONS](state: AppState, permissions) {\n state.possiblePermissions = permissions;\n },\n [types.SET_MASQUERADE_STATUS](state: AppState, masquerade) {\n state.masquerade = masquerade;\n },\n [types.SET_MASQUERADE](state: AppState, masquerade: MasqueradeData) {\n if (masquerade) {\n state.masquerade = masquerade;\n state.masquerade.on = true;\n setMasquerade(state.masquerade).then(() => {\n window.location.href = '/dashboard';\n });\n }\n },\n [types.END_MASQUERADE](state: AppState) {\n state.masquerade = {\n on: false,\n user: null,\n admin: null,\n };\n removeMasquerade();\n // eslint-disable-next-line no-restricted-globals\n location.reload();\n },\n [types.SET_FW_STRIPE_KEY](state: AppState, key: string) {\n state.fwPublicStripeKey = key;\n },\n [types.SET_FW_BUILD_NUMBER](state: AppState, build: string) {\n state.build = build;\n },\n [types.SET_POLLED_FW_BUILD_NUMBER](state: AppState, build: string) {\n state.polled_build = build;\n\n const existingBuild = localStorage.getItem('fw_polled_build');\n\n if (!existingBuild) {\n localStorage.setItem('fw_polled_build', build);\n } else if (existingBuild && existingBuild !== build) {\n state.update_available = true;\n\n localStorage.setItem('fw_polled_build', build);\n }\n },\n [types.SET_UPDATE_AVAILABLE](state: AppState) {\n state.update_available = true;\n },\n [types.SET_APP_FEATURES](state: AppState, features: AppFeatures) {\n state.appFeatures = features;\n },\n [types.MARK_SETUP_ITEM_COMPLETE](state: AppState, index) {\n state.setupItems[index].completed = true;\n },\n [types.SET_FEATURES_WAITLIST](state: AppState, features) {\n state.featureWaitlist = features;\n },\n [types.SET_CURRENT_CURRENCY](state: AppState, currency: AppCurrency) {\n state.currentCurrency = currency;\n },\n [types.TOGGLE_DEBUG_DRAWER](state: AppState) {\n console.dir(`Toggle Debug Drawer ${(state.debugDrawerOpen ? 'off' : 'on')}`.toUpperCase());\n localStorage.setItem('fw-debug', String(!state.debugDrawerOpen));\n state.debugDrawerOpen = !state.debugDrawerOpen;\n },\n [types.TOGGLE_DEBUG_ON](state: AppState, value: boolean = null) {\n const debugOnValue = value !== null ? value : !state.debugOn;\n\n console.dir(`Toggle Debug On Value: ${(debugOnValue ? 'off' : 'on')}`.toUpperCase());\n localStorage.setItem('fw-debug-on', String(debugOnValue));\n state.debugOn = debugOnValue;\n },\n },\n\n actions: {\n toggleSideBar({commit, state}) {\n commit(types.TOGGLE_SIDEBAR);\n\n Cookies.set(SIDEBAR_STORAGE_KEY, state.sidebar.opened ? '1' : '0');\n },\n masqueradeEnd({commit}) {\n commit(types.END_MASQUERADE);\n },\n toggleSecondaryImportNav({commit}) {\n commit(types.TOGGLE_SECONDARY_IMPORT_NAV_VIEW);\n },\n closeSideBar({commit}, {withoutAnimation}) {\n commit(types.CLOSE_SIDEBAR, withoutAnimation);\n },\n toggleDebugDrawer({commit}) {\n commit(types.TOGGLE_DEBUG_DRAWER);\n },\n\n toggleDebugOn({commit}) {\n console.dir('toggleDebugOn');\n commit(types.TOGGLE_DEBUG_ON);\n },\n\n checkForDebug({commit}) {\n console.dir('checkForDebug');\n\n const isDebugOn = localStorage.getItem('fw-debug-on')\n\n console.dir(isDebugOn);\n if (['on', 'true', true, 1].includes(isDebugOn)) {\n commit(types.TOGGLE_DEBUG_ON, true)\n }\n },\n\n async fetchBuildNumber({commit}) {\n const responseData = await performApiRequest(commit, 'SET_APP_LOADING', 'fetchBuild', () => axios.get('/v1/build'));\n commit(types.SET_POLLED_FW_BUILD_NUMBER, responseData.build);\n return responseData.build;\n },\n\n async fetchCurrency({commit}, code: string) {\n try {\n const responseData = await performApiRequest(commit, 'SET_APP_LOADING', 'fetchCurrency', () => axios.get(`/v1/currencies/${code}`));\n commit(types.SET_CURRENT_CURRENCY, responseData.currency);\n } catch (error) {\n }\n },\n\n addFeatureWaitlist({commit}, data) {\n axios.post('/v1/feature-waitlist', data)\n .then((response) => {\n EventBus.$emit('join-feature-waitlist-success');\n commit('SET_FEATURES_WAITLIST', response.data.data);\n }).catch(() => {\n }).finally(() => {\n });\n },\n\n async getFeatureWaitlist({commit}) {\n const responseData = await performApiRequest(commit, 'SET_APP_LOADING', 'fetchCurrency', () => axios.get('/v1/feature-waitlist'));\n commit('SET_FEATURES_WAITLIST', responseData.data);\n EventBus.$emit('get-feature-waitlist-success', responseData.data);\n },\n\n\n fetchHolidays({commit, state}, data) {\n axios.get(`/v1/holidays?year=${data.year}&countryCode=${data.countryCode}`)\n .then((response) => {\n EventBus.$emit('get-holidays-success', response.data.holidays);\n }).catch((e) => {\n EventBus.$emit('SystemMessage', {\n type: 'error',\n message: e.response?.data?.message || 'There was an error',\n });\n }).finally(() => {\n });\n },\n },\n\n}\n\nexport default appModule;\n","import parsePhoneNumber from 'libphonenumber-js'\n\n/**\n * Formats a number with commas as thousands separators.\n * @param x - The number to format.\n * @returns The formatted number as a string with commas, or '0' if the input is not a valid number.\n */\nexport const formatNumberWithCommas = (x: number | null | undefined): string => {\n if (x === null || x === undefined || typeof x !== 'number' || isNaN(x)) {\n return '0';\n }\n\n return x.toString().replace(/\\B(?=(\\d{3})+(?!\\d))/g, ',');\n};\n\n\n/**\n * Formats a phone number based on its length.\n * @param number - The phone number as a string.\n * @returns The formatted phone number.\n */\nexport const formatPhoneNumber = (number: string): string => {\n if (!number) return '';\n\n try {\n const phone = parsePhoneNumber(number);\n\n // Ensure the number is valid before formatting\n if (!phone?.isValid()) {\n return number.replace(/[^0-9+]/g, ''); // Keep only numbers & leading '+'\n }\n\n if (phone.country === 'US' && phone.nationalNumber.length === 10) {\n return `+1 (${phone.nationalNumber.slice(0, 3)}) ${phone.nationalNumber.slice(3, 6)}-${phone.nationalNumber.slice(6)}`;\n }\n\n return phone.formatInternational();\n } catch (error) {\n console.warn('Invalid phone number:', number, error);\n return number.replace(/[^0-9+]/g, ''); // Remove all non-numeric characters except '+'\n }\n}","/**\n * Build element\n * @param {string} type\n * @param {*} attributes\n * @param {*} children\n */\nconst elFactory = (type, attributes, ...children) => {\n const el = document.createElement(type)\n\n for (const key in attributes) {\n el.setAttribute(key, attributes[key])\n }\n\n children.forEach(child => {\n if (typeof child === 'string') {\n el.appendChild(document.createTextNode(child))\n } else {\n el.appendChild(child)\n }\n })\n\n return el\n}\n\nexport default elFactory;","import { CartService } from '@/services/cart.service';\n\n/** The company base url */\n// const COMPANY_URL = 'http://af769718-cc33-47e5-8164-b07bbdb39e71.fw.test';\nconst COMPANY_URL = window.fleetwireOptions?.apiURL;\n\nclass ApiService {\n\n static apiVersion = '/api/v1';\n\n static async call(url = '', method = 'GET', data = {}) {\n\n const options = {\n method,\n mode: 'cors',\n cache: 'no-cache',\n headers: {\n Accept: \"application/json\",\n // 'Current-Url': window.location.href,\n },\n referrerPolicy: 'no-referrer',\n };\n\n if (method === 'POST') {\n options.headers['Content-Type'] = 'application/json';\n options.body = JSON.stringify(data);\n }\n\n data.cart_id = CartService.getCartUuid();\n\n const response = await fetch(`${COMPANY_URL}${ApiService.apiVersion}${url}`, options);\n return response.json();\n }\n\n\n /**\n * Make the API calls\n *\n * @private\n * @param {string} [url] The url.\n * @param {Object} [data] The data to use for the call.\n * @returns {JSON} Returns `json`.\n */\n static async postData(url = '', data = {}) {\n data.cart_id = CartService.getCartUuid();\n const response = await fetch(url, {\n method: 'POST',\n mode: 'cors',\n cache: 'no-cache',\n headers: {\n \"Content-Type\": \"application/json\",\n \"Accept\": \"application/json\",\n },\n referrerPolicy: 'no-referrer',\n body: JSON.stringify(data)\n });\n return response.json();\n }\n\n /**\n * @param {string} url\n */\n static async getData(url = '') {\n const response = await fetch(url, {\n method: 'GET',\n mode: 'cors',\n cache: 'no-cache',\n headers: {\n \"Accept\": \"application/json\",\n },\n referrerPolicy: 'no-referrer',\n });\n return response.json();\n }\n\n\n}\n\nexport default ApiService;","import { get, isUndefined } from 'lodash';\nimport elFactory from './elFactory.service';\nimport UtilService from './util.service';\n\nconst CardService = {\n\n cardCount: 0,\n\n prepListingCards() {\n const productCards = Array.from(document.getElementsByClassName('fleetwire-listing-card'))\n\n productCards.forEach((listing, index) => {\n CardService.cardCount++;\n const lid = UtilService.getListingId(listing);\n\n\n const listingCardActions = elFactory('div', { class: 'fw-card__actions' }, 'Open');\n const listingCardCartBtn = elFactory('a', { class: 'fw-button fw-branded fw-card__actions' },\n elFactory('i', { class: 'fw-icon-cart fw-link fw-branded-font-color' })\n );\n\n listingCardActions.onclick = function () {\n CardService.clickedButton();\n };\n listingCardCartBtn.onclick = function () {\n\n\n CardService.clickedButton(lid);\n };\n\n const dataset = $fw(listing).data();\n const markup = CardService.buildProductCard(lid, dataset);\n\n $fw(markup).click(function () {\n window.open(\n UtilService.companyProductUrl(lid),\n '_blank'\n );\n });\n\n $fw(productCards[index]).replaceWith(markup)\n })\n UtilService.setWidth();\n\n CardService.buildQuickView();\n },\n\n buildQuickView() {\n const closeBtn = elFactory('a', { class: 'fw-close' }, 'X');\n\n closeBtn.onclick = function () {\n CardService.close_quick_view();\n };\n\n\n const markup = elFactory('div', { id: 'fleetwire-quickview', class: 'fleetwire-quickview' },\n elFactory('div', { class: 'booqable-component fleetwire-component', style: 'display: none;' },\n elFactory('div', { id: 'booqable-quickview-wrapper', class: 'fleetwire-quickview-wrapper closed' },\n elFactory('div', { id: 'booqable-quickview-inner' },\n closeBtn,\n elFactory('div', { class: 'booqable-product-detail-wrapper' },\n elFactory('div', { class: 'ProductImage-czxphg hgNThE' },\n elFactory('div', { class: 'MainImageContainer-dsPfmb kPjdza', 'data-tid': '' },\n elFactory('div', { class: 'MainImage-btvEcL gypPqW' },\n elFactory('div', {\n class: 'BFocalImage-dejJaX gWABCj',\n style: 'position: relative; overflow: hidden;'\n },\n elFactory('img', {\n class: 'Image-fDMyDA kftJhF',\n alt: 'bmw',\n src: 'https://fleetwire.io/images/vehicle-placeholder.jpg',\n style: 'min-height: 100%; min-width: 100%; position: absolute; inset: 0px; max-width: 100%;',\n 'data-focus-y': '0',\n 'data-focus-x': '0',\n loading: 'lazy',\n }),\n ),\n ),\n ),\n ),\n elFactory('div', { class: 'fw-content' },\n elFactory('h3', { class: 'fw-product-name' },\n 'BMW'\n ),\n elFactory('div', {\n class: 'fleetwire-product-button-wrapper',\n id: 'booqable-product-button-18ae2009-9c79-411c-b6cd-20e40ed2e8a0'\n },\n elFactory('div', { class: 'fw-actions' },\n elFactory('span', { class: 'fw-price-details' },\n elFactory('span', { class: 'fw-duration' }, 'from'),\n elFactory('span', { class: 'fw-price' }, '$95.00')\n ),\n elFactory('span', { 'aria-expanded': false },\n elFactory('a', {\n target: '_blank',\n class: 'AvailabilityLink-hXmWhx kKkbX Link-coULHM letVP A-jrLLFi iMXKpJ',\n color: 'dark'\n }, 'Check availability')\n ),\n elFactory('div', { class: 'fw-control', style: 'display: none;' },\n elFactory('div', { class: 'InputField-fbCPUI dfiEEZ' },\n elFactory('div', { class: 'LabelContainer-imROAO kLzFrI' }),\n elFactory('span', { class: 'InputContainer-kcTEuW ldFkuZ' },\n elFactory('input', {\n name: 'quantity',\n value: 1,\n type: 'number',\n class: 'fw-quantity Input-fXckBj kNmAJV Input-eXLwAq iwGLPw'\n }),\n ),\n ),\n elFactory('div', { class: 'Spacer-dQMXRY endFZm' }),\n elFactory('span', { class: 'ButtonContainer-cCzDqJ dASMYX Span-hCfPsm jdJhRb', color: 'primary' },\n elFactory('button', {\n type: 'button',\n class: 'fw-button false Button-jiBmQ bruVYM Button-hYXUXp dvaIoi'\n },\n elFactory('span', { class: 'Label-ghyrbC cjnCZD Span-hCfPsm ehhEci' }, 'Add to cart'),\n ),\n ),\n ),\n ),\n ),\n elFactory('div', { class: 'MagnifyContainer-iQrpjS hBbDLP' }),\n ),\n ),\n ),\n )\n )\n );\n\n\n document.body.appendChild(markup);\n\n\n window.onclick = function (event) {\n if (event.target.id === 'booqable-quickview-wrapper') {\n event.target.classList.remove('open');\n event.target.classList.add('closed');\n }\n }\n },\n\n clickedButton(lid) {\n const listing = window.listingData.find(listing => listing.l_id === lid);\n\n\n const quickView = document.getElementById('fleetwire-quickview');\n const fwOverlayState = quickView.querySelector('#booqable-quickview-wrapper');\n\n\n fwOverlayState.classList.remove('closed');\n fwOverlayState.classList.add('open');\n\n // var quickView = document.getElementsByClassName('booqable-quickview');\n\n\n const listingName = quickView.getElementsByClassName('fw-product-name');\n const listingPrice = quickView.getElementsByClassName('fw-price');\n const listingImage = quickView.getElementsByClassName('Image-fDMyDA');\n const listingAvailLink = quickView.getElementsByClassName('AvailabilityLink-hXmWhx');\n const amount = get(listing, 'pricing.amount', 0);\n\n\n listingName[0].innerHTML = listing.name;\n listingPrice[0].innerHTML = `$${UtilService.getListingPrice(amount)}`;\n listingImage[0].src = UtilService.productFirstImage(listing);\n listingAvailLink[0].href = UtilService.companyProductUrl(lid);\n\n if (quickView.length > 0) {\n const quickViewToggle = quickView[0].getElementsByClassName('fleetwire-quickview-wrapper')\n quickViewToggle[0].classList.remove('closed');\n quickViewToggle[0].classList.add('open');\n }\n },\n\n\n close_quick_view() {\n const element = document.getElementsByClassName('fleetwire-quickview');\n\n const elementToggle = element[0].getElementsByClassName('fleetwire-quickview-wrapper');\n\n elementToggle[0].classList.remove('open');\n elementToggle[0].classList.add('closed');\n },\n\n /**\n * Builds listing card element\n *\n * @private\n * @param {string} lid\n * @param dataset\n */\n buildProductCard(lid, dataset = {}) {\n let datasetString = '';\n if (dataset) {\n dataset = CardService.allowedCardDataAttributes(dataset)\n datasetString = Object.keys(dataset).map(key => `data-${key}=\"${dataset[key]}\"`).join(' ');\n }\n return $fw(`<div class=\"fleetwire-listing-card card-${lid}\" ${datasetString}>\n <div class=\"fleetwire-product ${lid}-card-main\">\n <div class=\"fleetwire-component\">\n <div class=\"fleetwire-product-wrapper\">\n <div class=\"fleetwire-product-inner\">\n <div style=\"height: 200px;\">\n <div class=\"fw-card-image ${lid}-card\" style=\"position: relative; overflow: hidden;\">\n <div class=\"fw-image__image fw-image__image--cover\"></div>\n </div>\n </div>\n <div class=\"fw-details\">\n <div class=\"fw-product-title-wrapper fw-has-prices\">\n <div class=\"fw-product-name\"></div>\n </div>\n <span class=\"fw-price-details\">\n <span class=\"fw-duration\"></span>\n <span class=\"fw-price fw-price-currency\"></span>\n </span>\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>`);\n },\n\n /**\n * Filters out unwanted data attributes\n *\n * @private\n * @param {Object} dataset\n */\n allowedCardDataAttributes(dataset) {\n const allowed = ['currency', 'customtitle', 'showprice'];\n\n Object.keys(dataset).forEach(value => {\n if (!allowed.includes(value)) {\n delete dataset[value];\n }\n });\n return dataset;\n },\n\n\n /**\n * Adds listing card element to the DOM\n *\n * @private\n * @param {Object} [listings]\n */\n addListingCards(listings) {\n if (CardService.cardCount === 0) return;\n\n listings.forEach((listing) => {\n const listingCards = CardService.getListingCards(listing)\n\n listingCards.forEach((card) => {\n if (CardService.listingInactive(listing)) {\n $fw(card).remove();\n console.error(`listing (${listing.name}) archived, deleted or not active so it was removed`);\n return;\n }\n\n CardService.setCardAttributes(card, listing);\n\n card.classList.remove('card-skeleton', 'card-skeleton-loading');\n })\n });\n\n UtilService.setWidth();\n },\n\n listingInactive(listing) {\n return !!(listing.archived_at || listing.deleted_at || !listing.active);\n },\n\n\n /**\n * Get all the card elements for a listing\n *\n * @private\n * @param {Object} listing\n */\n getListingCards(listing) {\n const lid = get(listing, 'l_id');\n return Array.from(document.getElementsByClassName(`card-${lid}`));\n },\n\n\n /**\n * Set the card element attributes\n *\n * @private\n * @param {Object} cardElement\n * @param {Object} listing\n */\n setCardAttributes(cardElement, listing) {\n const attr = get(cardElement, 'dataset');\n\n\n CardService.setPrice(cardElement, listing);\n\n\n const title = get(listing, 'name', '');\n\n const linkText = isUndefined(attr['customTitle']) ? title : attr['customtitle'];\n\n\n const imageElement = cardElement.getElementsByClassName('fw-image__image');\n const cardDescription = cardElement.getElementsByClassName('fw-product-name');\n\n\n // Set card image\n const img = UtilService.productFirstImage(listing);\n const style = `background-image: url(\"${img}\"); background-position: center center;`;\n imageElement[0].setAttribute('style', style);\n\n\n // Set card title\n cardDescription[0].innerHTML = linkText\n\n\n },\n\n /**\n * Set the card element price attributes\n *\n * @private\n * @param {Object} cardElement\n * @param {Object} listing\n * @param {number} updateAmount\n */\n setPrice(cardElement, listing = null, updateAmount = 0) {\n const attr = get(cardElement, 'dataset');\n\n const showPrice = get(attr, 'showprice')\n\n if (showPrice) {\n let currency = get(attr, 'currency');\n\n /**\n * If no currency is set, use the default company currency; fallback to USD\n */\n if (!currency) {\n currency = get(window.fwCompany, 'currency')\n currency = get(currency, 'symbol', '$') ?? '$';\n }\n\n\n const cardPrice = cardElement.getElementsByClassName('fw-price');\n const priceDetails = cardElement.getElementsByClassName('fw-price-details');\n\n\n const amount = get(listing, 'pricing.amount', get(listing, 'price', updateAmount));\n const price = UtilService.getListingPrice(amount);\n cardPrice[0].innerHTML = `${currency}${price}`\n priceDetails[0].setAttribute('style', 'display: block;');\n }\n },\n\n}\n\nexport default CardService;","import ApiService from './api.service';\nimport CardService from './card.service';\nimport UtilService from './util.service';\n\nconst COMPANY_URL = window.fleetwireOptions?.apiURL;\n\nconst ListService = {\n\n\n addListingList() {\n const lists = Array.from(document.getElementsByClassName('fleetwire-listing-list'))\n\n\n const listings = window.fwListings;\n\n ListService.updatePaginate();\n\n lists.forEach(list => {\n list.setAttribute('id', `fleetwire-listing-list-${UtilService.randomString()}`);\n\n list = ListService.addListComponent(list);\n\n const listWrapper = list.getElementsByClassName('fleetwire-listing-list-wrapper')[0]\n\n\n /**\n * Remove the current cards and add the new ones\n */\n if (window.fwPaginate.current_page) {\n const existingProductCards = $fw('.fleetwire-listing-list');\n\n if (existingProductCards.length) {\n const elements = $fw(existingProductCards[0]).find('.fleetwire-listing-list-wrapper')\n if (elements.length) {\n $fw(elements[0]).children().remove();\n }\n // $fw(existingProductCards[0]).forEach(card => {\n // card.remove();\n // });\n }\n }\n\n\n /**\n * Add the listings to each listing list element\n */\n listings.forEach((listing) => {\n CardService.cardCount++;\n const listingUrl = UtilService.companyProductUrl(listing.l_id);\n const dataset = $fw(list).data()\n const markup = CardService.buildProductCard(listing.l_id, dataset);\n\n $fw(markup).click(function () {\n window.open(listingUrl, '_blank');\n })\n\n $fw(listWrapper).append(markup);\n });\n\n UtilService.setWidth();\n\n CardService.addListingCards(listings);\n })\n },\n\n /**\n * Preps the product card element to the DOM and sets loading\n *\n * @private\n */\n prepListingList(page = 1) {\n const productCards = Array.from(document.getElementsByClassName(\"fleetwire-listing-list\"));\n\n if (productCards.length > 0) {\n const hasPaginate = $fw(productCards[0]).data('per');\n\n let qString = `?page=${page}`;\n\n if (hasPaginate && parseInt(hasPaginate)) {\n qString += `&limit=${+hasPaginate}`;\n }\n\n ApiService.getData(`${COMPANY_URL}/api/v1/products${qString}`)\n .then(data => {\n window.fwListings = data.data;\n window.fwPaginate = data.meta;\n\n ListService.addListingList()\n }).catch(e => {\n console.dir(e);\n });\n }\n },\n\n updatePaginate() {\n const productCards = $fw('.fleetwire-listing-list');\n\n const data = $fw(productCards[0]).data();\n\n if (typeof data === 'undefined') return;\n if (!data.per) return;\n\n ListService.buildPaginate();\n\n const paginate = $fw('.fleetwire-pagination .fw-pagination-inner');\n\n if (paginate.length) {\n const currentPage = window.fwPaginate.current_page;\n // const totalPages = window.fwPaginate.total;\n\n if (currentPage > 10) {\n if ($fw('.fw-pagination-previous').length === 0) {\n $fw($fw('.fw-pagination-inner')[0]).prepend(`<div class=\"fw-pagination-page fw-pagination-previous\"><a><i class=\"bq-icon-arrow-left2\"></i></a></div>`);\n }\n\n\n }\n\n paginate.children().each(function (index, element) {\n\n if (index + 1 === currentPage) {\n\n\n if ($fw(element).hasClass('fw-pagination-next')) {\n\n } else {\n $fw(element).html(currentPage);\n\n $fw(element).addClass('fw-pagination-current');\n $fw(element).addClass('fw-branded');\n }\n } else {\n if (currentPage > 10) {\n if (index > 0 && index < 10) {\n $fw(element).html(`<a>${currentPage - (10 - index)}</a>`);\n }\n }\n\n if ($fw(element).hasClass('fw-pagination-current')) {\n $fw(element).html(`<a>${index + 1}</a>`);\n }\n\n $fw(element).removeClass('fw-pagination-current');\n $fw(element).removeClass('fw-branded');\n\n $fw(element).unbind();\n\n $fw(element).click(function (e) {\n const pageRequest = +e.target.innerHTML\n\n if (pageRequest > 0) {\n ListService.prepListingList(pageRequest)\n } else {\n const button = $fw(e.target).parent();\n if (button.length) {\n if ($fw(button[0]).parents('.fw-pagination-next').length) {\n ListService.prepListingList(index + 1)\n }\n }\n }\n });\n\n }\n })\n }\n },\n\n buildPaginate() {\n const productCards = $fw('.fleetwire-listing-list');\n\n\n if (productCards.length) {\n\n if ($fw('.fleetwire-pagination').length === 0) {\n $fw(productCards[0]).append('<div class=\"fleetwire-component\"><div class=\"fleetwire-pagination\"><div class=\"fw-pagination-inner\"></div></div></div>');\n const addNextButton = window.fwPaginate.total > 10;\n\n const buttonCount = window.fwPaginate.total > 10 ? 10 : window.fwPaginate.total;\n for (let i = 0; i < buttonCount; i++) {\n $fw($fw('.fw-pagination-inner')[0]).append(`<div class=\"fw-pagination-page\"><a>${i + 1}</a></div>`);\n }\n\n if (addNextButton) {\n $fw($fw('.fw-pagination-inner')[0]).append(`<div class=\"fw-pagination-page fw-pagination-next\"><a><i class=\"bq-icon-arrow-right2\"></i></a></div>`);\n }\n }\n }\n },\n\n addListComponent(list) {\n if (list) {\n $fw(list).append($fw(`<div class=\"fleetwire-themed\"><div class=\"fleetwire-component\"><div class=\"fleetwire-listing-list-wrapper\"></div></div></div>`));\n }\n return list;\n },\n}\n\nexport default ListService;","import { find, get } from 'lodash';\nimport elFactory from './elFactory.service';\nimport UtilService from './util.service';\nimport { CartService } from '@/services/cart.service';\nimport ApiService from './api.service';\nimport ListService from './list.service';\nimport dayjs from 'dayjs';\nimport { easepick } from '@easepick/core';\nimport { RangePlugin } from '@easepick/range-plugin';\n\nconst COMPANY_URL = window.fleetwireOptions?.apiURL;\n\n\nconst timeSelect = `\n<div class=\"fw-time-select-outer\" id=\"fw-time-selector\">\n <div class=\"Select__menu fw-time-select-inner\">\n <div class=\"Select__menu-list css-o6rls7\">\n <div class=\"Select__option Select__option--is-focused css-jt7bxz-option\" id=\"react-select-2-option-0\" tabindex=\"-1\">12:00 AM</div>\n <div class=\"Select__option css-zhyjg9-option\" id=\"react-select-2-option-1\" tabindex=\"-1\">01:00 AM</div>\n <div class=\"Select__option css-zhyjg9-option\" id=\"react-select-2-option-2\" tabindex=\"-1\">02:00 AM</div>\n <div class=\"Select__option css-zhyjg9-option\" id=\"react-select-2-option-3\" tabindex=\"-1\">03:00 AM</div>\n <div class=\"Select__option css-zhyjg9-option\" id=\"react-select-2-option-4\" tabindex=\"-1\">04:00 AM</div>\n <div class=\"Select__option css-zhyjg9-option\" id=\"react-select-2-option-5\" tabindex=\"-1\">05:00 AM</div>\n <div class=\"Select__option css-zhyjg9-option\" id=\"react-select-2-option-6\" tabindex=\"-1\">06:00 AM</div>\n <div class=\"Select__option css-zhyjg9-option\" id=\"react-select-2-option-7\" tabindex=\"-1\">07:00 AM</div>\n <div class=\"Select__option css-zhyjg9-option\" id=\"react-select-2-option-8\" tabindex=\"-1\">08:00 AM</div>\n <div class=\"Select__option css-zhyjg9-option\" id=\"react-select-2-option-9\" tabindex=\"-1\">09:00 AM</div>\n <div class=\"Select__option css-zhyjg9-option\" id=\"react-select-2-option-10\" tabindex=\"-1\">10:00 AM</div>\n <div class=\"Select__option css-zhyjg9-option\" id=\"react-select-2-option-11\" tabindex=\"-1\">11:00 AM</div>\n <div class=\"Select__option css-zhyjg9-option\" id=\"react-select-2-option-12\" tabindex=\"-1\">12:00 PM</div>\n <div class=\"Select__option css-zhyjg9-option\" id=\"react-select-2-option-13\" tabindex=\"-1\">01:00 PM</div>\n <div class=\"Select__option css-zhyjg9-option\" id=\"react-select-2-option-14\" tabindex=\"-1\">02:00 PM</div>\n <div class=\"Select__option Select__option--is-selected css-r84qo7-option\" id=\"react-select-2-option-15\" tabindex=\"-1\">03:00 PM</div>\n <div class=\"Select__option css-zhyjg9-option\" id=\"react-select-2-option-16\" tabindex=\"-1\">04:00 PM</div>\n <div class=\"Select__option css-zhyjg9-option\" id=\"react-select-2-option-17\" tabindex=\"-1\">05:00 PM</div>\n <div class=\"Select__option css-zhyjg9-option\" id=\"react-select-2-option-18\" tabindex=\"-1\">06:00 PM</div>\n <div class=\"Select__option css-zhyjg9-option\" id=\"react-select-2-option-19\" tabindex=\"-1\">07:00 PM</div>\n <div class=\"Select__option css-zhyjg9-option\" id=\"react-select-2-option-20\" tabindex=\"-1\">08:00 PM</div>\n <div class=\"Select__option css-zhyjg9-option\" id=\"react-select-2-option-21\" tabindex=\"-1\">09:00 PM</div>\n <div class=\"Select__option css-zhyjg9-option\" id=\"react-select-2-option-22\" tabindex=\"-1\">10:00 PM</div>\n <div class=\"Select__option css-zhyjg9-option\" id=\"react-select-2-option-23\" tabindex=\"-1\">11:00 PM</div>\n </div>\n </div>\n</div>\n`;\n\n\nconst DatepickerService = {\n\n data: {\n dialog: false,\n times: {\n start: null,\n end: null,\n },\n },\n\n prepDatepicker() {\n const datepicker = Array.from(document.getElementsByClassName('fleetwire-datepicker'));\n\n if (datepicker.length) {\n const markup = DatepickerService.buildDatepicker();\n\n markup.onclick = function () {\n DatepickerService.openDatepicker();\n };\n\n datepicker[0].appendChild(markup)\n }\n },\n\n buildDatepicker() {\n return elFactory('div', { class: `fleetwire-datepicker` },\n elFactory('div', { class: 'fleetwire-themed' },\n elFactory('div', { class: 'fleetwire-component' },\n elFactory('div', { class: 'fleetwire-datetime-wrapper' },\n elFactory('div', { class: 'fleetwire-datetime-container fleetwire-datetime-from' },\n elFactory('div', { class: 'fleetwire-datetime-from-detail' },\n elFactory('p', { class: 'fleetwire-datetime-placeholder fw-pickup' }, 'Pickup Date')\n )\n ),\n elFactory('div', { class: 'fleetwire-datetime-container fleetwire-datetime-till' },\n elFactory('div', { class: 'fleetwire-datetime-till-detail' },\n elFactory('p', { class: 'fleetwire-datetime-placeholder fw-return' }, 'Return Date')\n )\n ),\n )\n )\n )\n );\n },\n\n setCartDates(cart) {\n console.log('cart');\n console.log(cart);\n const pickup = Array.from(document.getElementsByClassName('fw-pickup'))\n const dropOff = Array.from(document.getElementsByClassName('fw-return'))\n\n\n if (pickup.length) {\n pickup[0].innerHTML = dayjs(get(cart, 'trip_start')).format('MMM DD, YYYY, hh:mm A');\n this.data.times.start = get(cart, 'trip_start');\n }\n\n if (dropOff.length) {\n dropOff[0].innerHTML = dayjs(get(cart, 'trip_end')).format('MMM DD, YYYY, hh:mm A');\n this.data.times.end = get(cart, 'trip_end');\n }\n },\n\n openDatepicker() {\n const markup = elFactory('div', { class: `fleetwire-datepicker-backdrop` },\n elFactory('div', { class: `fleetwire-datepicker-container fleetwire-modal-hide` },\n elFactory('h2', { class: `fleetwire-datepicker-close` },\n elFactory('i', { class: `fleetwire-datepicker-close-icon` }, 'X')\n ),\n elFactory('div', { class: `fleetwire-modal-form-container` },\n elFactory('form', { class: `` },\n elFactory('div', { class: `` },\n elFactory('div', { class: `picker-form` },\n elFactory('div', { class: `picker-block` },\n elFactory('h3', { class: `picker-title` }, 'Pickup'),\n elFactory('div', { class: `picker-spacer` }),\n DatepickerService.buildModalFormInput(),\n ),\n elFactory('div', { class: `picker-spacer-main` }),\n elFactory('div', { class: `picker-block` },\n elFactory('h3', { class: `picker-title` }, 'Return'),\n elFactory('div', { class: `picker-spacer` }),\n DatepickerService.buildModalFormInput('end'),\n ),\n ),\n )\n )\n ),\n elFactory('div', { class: `fleetwire-modal-actions` },\n elFactory('div', { class: `fleetwire-modal-actions-group` },\n elFactory('span', { class: `fleetwire-modal-actions-button-white` },\n elFactory('button', { class: `fleetwire-modal-actions-button-close`, type: 'button' }, 'Cancel')\n ),\n elFactory('span', { class: `fleetwire-modal-actions-button-blue` },\n elFactory('button', { class: ``, type: 'button', color: '#2B80FF' }, 'Apply')\n )\n )\n )\n ),\n );\n\n markup.onclick = function (event) {\n DatepickerService.removeDatepicker(event);\n };\n\n document.body.appendChild(markup);\n\n if (this.data.times.start) {\n const startValue = document.getElementById('start-datepicker');\n const startTimeValue = document.getElementById('start-placeholder');\n startValue.value = dayjs(this.data.times.start).format('YYYY-MM-DD');\n startTimeValue.innerText = dayjs(this.data.times.start).format('hh:mm A');\n }\n\n if (this.data.times.end) {\n const endValue = document.getElementById('end-datepicker');\n const endTimeValue = document.getElementById('end-placeholder');\n endValue.value = dayjs(this.data.times.end).format('YYYY-MM-DD');\n endTimeValue.innerText = dayjs(this.data.times.start).format('hh:mm A');\n }\n\n setTimeout(() => {\n const datepicker = Array.from(document.getElementsByClassName('fleetwire-datepicker-container'))\n\n if (datepicker.length) {\n datepicker[0].classList.remove('fleetwire-modal-hide');\n datepicker[0].classList.add('fleetwire-modal-show');\n\n document.body.classList.add('fw-modal-open');\n\n\n new easepick.create({\n element: document.getElementById('start-datepicker'),\n css: [\n 'https://cdn.jsdelivr.net/npm/@easepick/bundle@1.2.0/dist/index.css',\n ],\n plugins: [RangePlugin],\n zIndex: 999999999,\n setup(picker) {\n picker.on('select', (e) => {\n const { start, end } = e.detail;\n // let startDate = start.getFullYear() + '-' + ((start.getMonth() > 8) ? (start.getMonth() + 1) : ('0' + (start.getMonth() + 1))) + '-' + ((start.getDate() > 9) ? start.getDate() : ('0' + start.getDate())) + ' ' + UtilService.padTo2Digits(start.getHours()) + ':' + UtilService.padTo2Digits(start.getMinutes()) + ':' + UtilService.padTo2Digits(start.getSeconds());\n const startDate = dayjs(start).format('YYYY-MM-DD HH:mm:ss');\n // let endDate = end.getFullYear() + '-' + ((end.getMonth() > 8) ? (end.getMonth() + 1) : ('0' + (end.getMonth() + 1))) + '-' + ((end.getDate() > 9) ? end.getDate() : ('0' + end.getDate())) + ' ' + UtilService.padTo2Digits(end.getHours()) + ':' + UtilService.padTo2Digits(end.getMinutes()) + ':' + UtilService.padTo2Digits(end.getSeconds());\n const endDate = dayjs(end).format('YYYY-MM-DD HH:mm:ss');\n console.dir(start);\n console.dir(startDate);\n console.dir(endDate);\n\n DatepickerService.setDatePickerValues(startDate, endDate);\n DatepickerService.checkAvailability(startDate, endDate);\n });\n },\n RangePlugin: {\n elementEnd: \"#end-datepicker\",\n tooltip: false,\n },\n });\n }\n }, 50)\n },\n\n buildModalFormInput(period = 'start') {\n const timeSelectMarkup = elFactory('div', { class: `Select__value-container css-1hwfws3` },\n elFactory('div', {\n class: `Select__placeholder css-1wa3eu0-placeholder ${period}-placeholder`,\n id: `${period}-placeholder`\n }, 'Select...'),\n );\n\n timeSelectMarkup.onclick = function (event) {\n DatepickerService.addTimeSelector(event, period);\n };\n\n return elFactory('div', { class: `picker-input` },\n elFactory('div', { class: `BOxSN` },\n elFactory('div', { class: `InputField-ivJGtx ` },\n elFactory('div', { style: `width: 100%` },\n elFactory('div', { class: `lgjpsj` },\n elFactory('input', {\n id: `${period}-datepicker`,\n class: `Input-lchiQn dCoejz`,\n name: 'date',\n placeholder: 'MM-DD-YY'\n })\n ),\n ),\n ),\n elFactory('div', { class: `InputField-ivJGtx ` },\n elFactory('div', { style: `width: 100%; height: 100%` },\n elFactory('div', { class: `Container-bnWmgR hjMXLA`, style: 'height: 100%' },\n elFactory('div', { class: `Select--is-disabled css-14jk2my-container`, style: 'height: 100%' },\n elFactory('div', { class: `Select__control Select__control--is-disabled css-1fhf3k1-control` },\n elFactory('div', { class: `Select__value-container css-1hwfws3` },\n timeSelectMarkup,\n ),\n elFactory('div', { class: `Select__indicators css-1wy0on6` },\n elFactory('div', { class: `Select__indicator Select__dropdown-indicator css-tlfecz-indicatorContainer` },\n elFactory('svg', { class: `css-19bqh2r` },\n elFactory('path', { d: `M4.516 7.548c0.436-0.446 1.043-0.481 1.576 0l3.908 3.747 3.908-3.747c0.533-0.481 1.141-0.446 1.574 0 0.436 0.445 0.408 1.197 0 1.615-0.406 0.418-4.695 4.502-4.695 4.502-0.217 0.223-0.502 0.335-0.787 0.335s-0.57-0.112-0.789-0.335c0 0-4.287-4.084-4.695-4.502s-0.436-1.17 0-1.615z` }),\n ),\n ),\n ),\n ),\n ),\n ),\n ),\n ),\n ),\n );\n },\n\n addTimeSelector(event, period) {\n\n if ($fw('#fw-time-selector').length === 0) {\n $fw(document.body).append(timeSelect);\n }\n\n $fw('#fw-time-selector').show();\n\n console.dir(\"$fw('.fw-time-selector').first()\");\n console.dir($fw('#fw-time-selector'));\n\n if ($fw('#fw-time-selector').length) {\n const picker = $fw($fw('#fw-time-selector')[0])\n console.dir('picker');\n console.dir(picker[0]);\n const top = event.target.getBoundingClientRect().top + window.pageYOffset + 35;\n picker[0].style.left = event.target.getBoundingClientRect().left + 'px';\n picker[0].style.top = top + 'px';\n picker[0].classList.remove('d-none');\n\n picker[0].onclick = function (event) {\n DatepickerService.selectTime(event, period);\n };\n } else {\n $fw('#fw-time-selector')[0].hide();\n // datepicker.classList.add('d-none')\n }\n },\n\n closeTimeSelector() {\n const datepicker = document.getElementById('fw-time-selector');\n\n if (!datepicker.classList.contains('d-none')) {\n datepicker.classList.add('d-none')\n }\n },\n\n selectTime(event, period) {\n const timePlaceholder = Array.from(document.getElementsByClassName(`${period}-placeholder`))\n\n if (timePlaceholder.length > 0) {\n\n timePlaceholder[0].innerHTML = event.target.innerHTML;\n DatepickerService.closeTimeSelector()\n\n if (this.data.times.start) {\n const date = this.data.times.start.split(' ')[0];\n let time1 = event.target.innerHTML.split(' ')[0];\n\n if (event.target.innerHTML.split(' ')[1] === 'PM') {\n time1 = (parseInt(time1.split(':')[0]) + 12) + ':' + time1.split(':')[1];\n }\n\n const time = dayjs(`${date} ${time1}:00`).format('HH:mm:ss');\n this.data.times.start = dayjs(`${date} ${time}`).format('YYYY-MM-DD HH:mm:ss');\n DatepickerService.checkAvailability(this.data.times.start, this.data.times.end);\n }\n\n if (this.data.times.end) {\n const date = this.data.times.end.split(' ')[0];\n let time1 = event.target.innerHTML.split(' ')[0];\n\n if (event.target.innerHTML.split(' ')[1] === 'PM') {\n time1 = (parseInt(time1.split(':')[0]) + 12) + ':' + time1.split(':')[1];\n }\n const time = dayjs(`${date} ${time1}:00`).format('HH:mm:ss');\n this.data.times.end = dayjs(`${date} ${time}`).format('YYYY-MM-DD HH:mm:ss');\n DatepickerService.checkAvailability(this.data.times.start, this.data.times.end);\n }\n }\n },\n\n checkAvailability(start, end) {\n console.log('checkAvailability');\n console.log(start);\n console.log(end);\n console.log('-----');\n\n if (dayjs(start).format('HH:mm:ss') === '00:00:00') {\n start = dayjs(start).format('YYYY-MM-DD 08:00:00')\n }\n if (dayjs(end).format('HH:mm:ss') === '00:00:00') {\n end = dayjs(end).format('YYYY-MM-DD 08:00:00')\n }\n\n\n const cartUuid = CartService.getCartUuid();\n\n CartService.updateCart(`${COMPANY_URL}/api/v1/carts/${cartUuid}/set-period`, { start, end })\n .then(data => {\n const { cart } = data\n window.fwCart = cart;\n\n DatepickerService.setCartDates(cart);\n }).catch(e => {\n UtilService.log(e)\n });\n\n const fwProduct = UtilService.collectFWComponents();\n\n ApiService.postData(`${COMPANY_URL}/api/v1/listings/availability?start=${start}&end=${end}`)\n .then(data => {\n const { listings } = data\n window.fwListings = listings;\n\n\n fwProduct.forEach(lid => {\n const timePlaceholder = Array.from(document.getElementsByClassName(`${lid}-card-main`))\n\n if (timePlaceholder.length > 0) {\n console.dir('timePlaceholder');\n console.dir('timePlaceholder');\n const cardStatus = timePlaceholder[0].getElementsByClassName(`fw-status`)\n console.dir(cardStatus);\n\n if (cardStatus.length > 0) {\n const foundListing = find(listings, (listing) => {\n return listing.l_id === lid;\n });\n\n\n if (foundListing) {\n if (get(foundListing, 'available.available')) {\n cardStatus[0].classList.add('fw-available');\n cardStatus[0].classList.remove('fw-unavailable');\n cardStatus[0].innerHTML = 'Available';\n cardStatus[0].classList.remove('fw-d-none');\n } else {\n cardStatus[0].classList.add('fw-unavailable');\n cardStatus[0].classList.remove('fw-available');\n cardStatus[0].innerHTML = 'Unavailable';\n cardStatus[0].classList.remove('fw-d-none');\n }\n }\n }\n }\n });\n\n ListService.addListingList()\n }).catch(e => {\n console.dir(e);\n });\n },\n\n setDatePickerValues(startDate, endDate) {\n document.querySelector('#start-datepicker').value = dayjs(startDate).format('YYYY-MM-DD');\n document.querySelector('#end-datepicker').value = dayjs(endDate).format('YYYY-MM-DD');\n },\n\n removeDatepicker(event) {\n const datepicker = Array.from(document.getElementsByClassName('fleetwire-datepicker-backdrop'))\n\n if (datepicker.length\n &&\n (event.target.classList.contains('fleetwire-datepicker-backdrop')\n || event.target.classList.contains('fleetwire-modal-actions-button-close')\n || event.target.classList.contains('fleetwire-modal-actions-button-white'))\n ) {\n DatepickerService.closeTimeSelector();\n const datepickerContainer = Array.from(document.getElementsByClassName('fleetwire-datepicker-container'))\n datepickerContainer[0].classList.remove('fleetwire-modal-show');\n datepickerContainer[0].classList.add('fleetwire-modal-hide');\n document.body.classList.remove('fw-modal-open');\n setTimeout(() => {\n if (datepicker.length) {\n datepicker[0].remove();\n }\n }, 100)\n }\n },\n\n}\n\n\nexport default DatepickerService;","import { get, isNumber } from 'lodash';\nimport { formatNumberWithCommas } from '@/utils/numbers';\nimport DatepickerService from './datepicker.service';\nimport dayjs from 'dayjs';\nimport { CartService } from '@/services/cart.service';\nimport CardService from './card.service';\n\n\nconst COMPANY_URL = window.fleetwireOptions?.apiURL;\n\nconst DEBUG_ON = window.fleetwireOptions?.debug || true;\n\nconst UtilService = {\n\n log(data) {\n if (DEBUG_ON) {\n console.dir(data);\n }\n },\n\n error(message) {\n if (DEBUG_ON) {\n console.error(message);\n }\n },\n\n setCompany(company) {\n UtilService.updatePriceCurrency(get(company, 'currency'));\n UtilService.updateCompanyName(get(company, 'name'));\n UtilService.updateCompanyDefaultPickupTimes(get(company, 'operating_rules'));\n },\n\n updatePriceCurrency(currency) {\n const prices = $fw('.fw-price-currency');\n\n prices.each(function (index, el) {\n const cardElement = $fw(el).closest('.fleetwire-listing-card')[0]\n let price = el.innerHTML;\n price = price.replace(/\\D/g, \"\");\n\n if (cardElement) {\n CardService.setPrice(cardElement, null, price * 100);\n } else {\n\n\n const symbol = get(currency, 'symbol', \"**\");\n el.innerHTML = `${symbol}${price}`;\n }\n })\n },\n\n updateCompanyName(name) {\n console.dir('updateCompanyName');\n console.dir(name);\n const names = $fw('.fw-company-name');\n\n console.dir(names);\n names.each(function (index, el) {\n $fw(el).text(name);\n })\n },\n\n /**\n * Fill in the default pickup times for the company.\n *\n * @param {Object} rules\n */\n updateCompanyDefaultPickupTimes(rules) {\n if (Object.keys(rules).length > 0) {\n const pickup = $fw('.fw-from-time');\n const until = $fw('.fw-until-time');\n\n const found = rules.find(element => element.data_type === 'default_pickup_time');\n const defaultTime = get(found, 'data.default_pickup_time.start', '09:00');\n\n pickup.each(function (index, el) {\n $fw(el).text(UtilService.formatDefaultTime(defaultTime));\n })\n until.each(function (index, el) {\n $fw(el).text(UtilService.formatDefaultTime(defaultTime));\n })\n }\n },\n\n formatDefaultTime(time) {\n return UtilService.getFormattedTimeFromDate(dayjs(`2022-08-08 ${time}`));\n },\n\n getFormattedTimeFromDate(date) {\n return dayjs(date).format('h:mm A');\n },\n\n /**\n * Build a FW component wrapper\n *\n * @private\n */\n buildFWComponent() {\n const pDiv = document.createElement('div');\n pDiv.classList.add('fleetwire-component');\n return pDiv;\n },\n\n /**\n * Collect the fleetwire components\n *\n * @private\n * @returns {Array} Returns `array`.\n */\n collectFWComponents() {\n const ids = [];\n const products = document.querySelectorAll('[class*=fleetwire-]');\n\n for (const product of products) {\n const id = product?.dataset?.id;\n if (id && !ids.includes(id)) {\n ids.push(id);\n }\n }\n\n return ids;\n },\n\n /**\n * Load another script\n * @param {string} url\n */\n loadScript(url) {\n const script = document.createElement('script')\n script.type = 'text/javascript';\n\n if (script.readyState) { //IE\n script.onreadystatechange = function () {\n if (script.readyState === 'loaded' || script.readyState === 'complete') {\n script.onreadystatechange = null;\n }\n };\n }\n\n script.src = url;\n document.getElementsByTagName('head')[0].appendChild(script);\n },\n\n /**\n * If window is resized then resize the elements\n * @param {WindowEventMap[keyof WindowEventMap]} data\n */\n setWidth(data = null) {\n const productCards = Array.from(document.getElementsByClassName('fleetwire-listing-card'))\n\n if (productCards.length > 0) {\n productCards.forEach(function (card) {\n const parent = card.parentNode;\n\n const parentWidth = parent.offsetWidth\n\n const o = Math.floor(parentWidth / 280);\n const width = Math.max(1, Math.min(o, 6));\n card.style.width = 100 / width + '%';\n })\n }\n },\n\n\n /**\n * Get the listings url\n *\n * @private\n * @param {String} [listingId] The Listing ID.\n * @returns {String}\n */\n companyProductUrl(listingId) {\n const times = DatepickerService.data.times\n let query = '';\n if (get(times, 'start')) {\n const startDate = dayjs(get(times, 'start')).format('MMDDYY');\n const startTime = dayjs(get(times, 'start')).format('HHmm');\n query += `&startDate=${startDate}&startTime=${startTime}`;\n }\n if (get(times, 'end')) {\n const endDate = dayjs(get(times, 'end')).format('MMDDYY');\n const endTime = dayjs(get(times, 'end')).format('HHmm');\n query += `&endDate=${endDate}&endTime=${endTime}`;\n }\n\n if (CartService.getCartUuid()) {\n query += `&cart=${CartService.getCartUuid()}`;\n }\n return encodeURI(`${COMPANY_URL}/rental/reservations?l_id=${listingId}&${query}`);\n },\n\n\n /**\n * Get the listings price image or default\n *\n * @private\n * @param {Number} [value] The price.\n * @returns {String}\n */\n getListingPrice(value) {\n if (isNumber(value)) {\n return value <= 0 ? 0 : formatNumberWithCommas(value * 0.01);\n }\n return value === 0 ? 0 : formatNumberWithCommas(+value * 0.01);\n },\n\n randomString(length = 5) {\n let text = \"\";\n const possible = \"ABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789\";\n\n for (let i = 0; i < length; i++)\n text += possible.charAt(Math.floor(Math.random() * possible.length));\n\n return text;\n },\n\n\n /**\n * Get the listings first image or default\n *\n * @private\n * @param {Object} [listing] The listing object.\n * @returns {String}\n */\n productFirstImage(listing) {\n return get(listing, 'listing_images[0].path', 'https://fleetwire.io/images/vehicle-placeholder.jpg');\n },\n\n\n /**\n * Get the listings id\n *\n * @private\n * @param {Object} [listing] The listing object.\n * @returns {String}\n */\n getListingId(listing) {\n return get(listing, 'dataset.id');\n }\n\n}\n\nexport default UtilService;","import UtilService from \"@/tenant/Services/util.service\";\n\nconst CART_UUID = 'fw_CartId';\n\nconst CartService = {\n\n /**\n * Saves a cart uuid\n */\n saveCartUuid(uuid: string): void {\n UtilService.log(`✅ Saving cart uuid: ${uuid}`);\n localStorage.setItem(CART_UUID, uuid);\n },\n\n /**\n * Gets a cart uuid\n *\n */\n getCartUuid() {\n return localStorage.getItem(CART_UUID);\n },\n\n /**\n * Removes a cart uuid from localstorage\n *\n */\n removeCartUuid(): void {\n localStorage.removeItem(CART_UUID);\n },\n\n\n async createCart(url: string) {\n const payload = {\n current_url: window.location.href,\n };\n const response = await fetch(url, {\n method: 'POST',\n mode: 'cors',\n cache: 'no-cache',\n headers: {\n 'Content-Type': 'application/json',\n Accept: 'application/json',\n },\n referrerPolicy: 'no-referrer',\n body: JSON.stringify(payload),\n });\n return response.json();\n },\n\n async fetchCart(url: string) {\n const response = await fetch(url, {\n method: 'GET',\n mode: 'cors',\n cache: 'no-cache',\n headers: {\n Accept: 'application/json',\n },\n referrerPolicy: 'no-referrer',\n });\n return response.json();\n },\n\n async updateCart(url: string, payload: { start: string, end: string, current_url: string }) {\n payload.current_url = window.location.href;\n\n const response = await fetch(url, {\n method: 'POST',\n mode: 'cors',\n cache: 'no-cache',\n headers: {\n 'Content-Type': 'application/json',\n Accept: 'application/json',\n },\n referrerPolicy: 'no-referrer',\n body: JSON.stringify(payload),\n });\n return response.json();\n },\n};\n\nexport {CartService};\n","export const emailRule = () => {\n return [(v) => /.+@.+\\..+/.test(v) || 'E-mail must be a valid e-mail'];\n};\n\nexport const minLengthRule = (minLength: number) => {\n return (v) => {\n if (!v) return true; // Optional: Skip minLength check if value is empty. Remove this if you want empty values to fail this validation.\n return v.length >= minLength || `Min of ${minLength} characters`;\n };\n}\n\nexport const codeRule = (length = 4) => {\n return [(v) => v.length >= length || `Should be ${length} characters`];\n};\n\nexport const requiredRule = (v: any): string | boolean => {\n if (!v) {\n return 'Required';\n }\n return true;\n};","import {useStore} from 'vuex';\nimport {computed} from 'vue';\nimport {StoreLoaders} from '@/types';\n\nexport function useAuth() {\n const store = useStore();\n\n const authLoading = computed<StoreLoaders>(() => store.getters['auth/loading']);\n\n const authForm = computed(() => store.getters['auth/authForm']);\n const apiTokens = computed(() => store.getters['auth/apiTokens']);\n const user = computed(() => store.getters['auth/user']);\n const masquerade = computed(() => store.getters['app/masquerade']);\n\n const saveToken = (payload: { token: string }) => {\n return store.dispatch('auth/saveToken', payload);\n }\n\n const checkStripe = async () => {\n return await store.dispatch('auth/checkStripe');\n }\n\n const setAuthLoading = (payload: { subject: string, loading: boolean }) => {\n return store.commit('auth/SET_AUTH_LOADING', payload);\n }\n\n const updateUserPassword = (payload: { password: string, newPassword: string }) => {\n return store.dispatch('auth/updateUserPassword', payload);\n }\n\n const registrationFormRules = computed(() => ({\n required: (value: string) => !!value || 'Required',\n min: (v: string) => v.length >= 8 || 'Min of 8 characters',\n email: [\n (v: string) => !!v || 'E-mail is required',\n (v: string) => /.+@.+\\..+/.test(v) || 'E-mail must be a valid e-mail',\n ],\n code: [\n (v: string) => !!v || '2FA code is required',\n (v: string) => v.length >= 4 || 'Should be 4 characters',\n ],\n }));\n\n const masqueradeEnd = () => {\n return store.dispatch('app/masqueradeEnd');\n }\n\n const logout = () => {\n return store.dispatch('auth/logout');\n }\n\n const createUserTokens = () => {\n return store.dispatch('auth/createUserTokens');\n }\n const deleteApiToken = (payload) => {\n return store.dispatch('auth/deleteApiToken', payload);\n }\n\n const fetchSession = () => {\n return store.dispatch('auth/fetchSession');\n }\n\n const fetchUserTokens = () => {\n return store.dispatch('auth/fetchApiTokens');\n }\n\n const start2FAVerify = async (payload: { code?: string, phone: string, channel: string }) => {\n try {\n return await store.dispatch('auth/start2FAVerify', payload);\n } catch (error) {\n throw error;\n }\n }\n\n const check2FAVerify = async (payload: { code: string, phone: string, disable: boolean }) => {\n try {\n return await store.dispatch('auth/check2FAVerify', payload);\n } catch (error) {\n throw error;\n }\n }\n\n return {\n user,\n masquerade,\n authLoading,\n authForm,\n apiTokens,\n registrationFormRules,\n setAuthLoading,\n checkStripe,\n saveToken,\n logout,\n masqueradeEnd,\n createUserTokens,\n deleteApiToken,\n fetchUserTokens,\n fetchSession,\n updateUserPassword,\n start2FAVerify,\n check2FAVerify\n }\n}","<template>\n <section class=\"bg-gray-50 dark:bg-gray-900\">\n <div class=\"flex flex-col items-center justify-center px-6 py-8 mx-auto md:h-screen lg:py-0\">\n <a class=\"flex items-center mb-6 text-2xl font-semibold text-gray-900 dark:text-white\" href=\"/\">\n <img alt=\"logo\" class=\"w-8 h-8 mr-2\" src=\"https://tenant.fleetwire.io/images/logo/fleetwire-logo-new.png\">\n Fleetwire\n </a>\n <div class=\"w-full bg-white rounded-lg shadow dark:border md:mt-0 sm:max-w-md xl:p-0 dark:bg-gray-800 dark:border-gray-700\">\n <div class=\"p-6 space-y-4 md:space-y-6 sm:p-8\">\n <h1 class=\"text-xl font-bold leading-tight tracking-tight text-gray-900 md:text-2xl dark:text-white\">\n {{ $t('login') }} {{ $t('to') }} Fleetwire\n </h1>\n <v-form :disabled=\"form.busy\" action=\"#\" class=\"space-y-4 md:space-y-6\" @keydown=\"form.onKeydown($event)\" @submit.prevent=\"login()\">\n\n <div v-show=\"twoFactorAuth\" class=\"w-full text-muted mb-4 text-subtitle-1\">\n Enter the code we sent over SMS to\n <div>+1 (•••) ••• - ••{{ last2 }}</div>\n </div>\n\n <div v-if=\"!twoFactorAuth\">\n <v-text-field\n v-model=\"form.email\"\n :autofocus=true\n :label=\"$t('email')\"\n :rules=\"registerFormRules.email\"\n aria-label=\"Email Address\"\n aria-required=\"true\"\n autocomplete=\"username\"\n class=\"mb-4\"\n density=\"comfortable\"\n name=\"email\"\n required\n tabindex=\"1\"\n type=\"email\"\n variant=\"outlined\"\n />\n\n <v-text-field\n v-model=\"form.password\"\n :append-inner-icon=\"showPassword ? 'mdi-eye' : 'mdi-eye-off'\"\n :label=\"$t('password')\"\n :rules=\"[registerFormRules.required, registerFormRules.min]\"\n :type=\"showPassword ? 'text' : 'password'\"\n aria-live=\"polite\"\n aria-pressed=\"true\"\n autocomplete=\"current-password\"\n class=\"mb-4\"\n density=\"comfortable\"\n name=\"password\"\n required\n tabindex=\"2\"\n variant=\"outlined\"\n @click:append-inner=\"togglePasswordVisibility\"\n />\n\n <div class=\"flex items-center justify-between\">\n <div class=\"flex items-start\">\n <div class=\"flex items-center h-5\">\n <input id=\"remember\" v-model=\"form.remember\" aria-describedby=\"remember\" class=\"w-4 h-4 border border-gray-300 rounded bg-gray-50 focus:ring-3 focus:ring-primary-300 dark:bg-gray-700 dark:border-gray-600 dark:focus:ring-primary-600 dark:ring-offset-gray-800\" required type=\"checkbox\">\n </div>\n <div class=\"ml-3 text-sm\">\n <label class=\"text-gray-500 dark:text-gray-300\" for=\"remember\">Remember me</label>\n </div>\n </div>\n\n <router-link\n :to=\"{ name: 'password.request', query: { email: form.email }}\"\n class=\"text-sm font-medium text-primary-600 hover:underline dark:text-primary-500\"\n >\n {{ $t('forgot_password') }}\n </router-link>\n </div>\n </div>\n\n <div v-if=\"twoFactorAuth\">\n <v-text-field\n v-model=\"form.code\"\n :label=\"$t('2FA Code')\"\n :rules=\"registerFormRules.code\"\n autocomplete=\"one-time-code\"\n name=\"code\"\n required\n tabindex=\"3\"\n variant=\"outlined\"\n />\n </div>\n\n <v-btn :disabled=\"isButtonDisabled\" :loading=\"form.busy\" block name=\"login-btn\" size=\"large\" tabindex=\"4\" type=\"submit\">\n Sign in\n </v-btn>\n <p class=\"text-sm font-light text-gray-500 dark:text-gray-400\">\n Don’t have an account yet?\n <router-link :to=\"{ name: 'register' }\" class=\"font-medium text-primary-600 hover:underline dark:text-primary-500\" data-testid=register-link>\n <b>{{ $t('register') }}</b>\n </router-link>\n </p>\n\n <div>\n <v-alert v-if=\"loginFail\" density=\"compact\" role=\"alert\" type=\"error\" variant=\"outlined\">\n {{ loginFailMessage }}\n </v-alert>\n </div>\n\n </v-form>\n\n </div>\n\n </div>\n </div>\n </section>\n</template>\n\n<script lang=\"ts\" setup>\nimport {codeRule, emailRule, minLengthRule, requiredRule} from '@/utils/formValidationRules';\nimport {computed, onBeforeMount, ref, watch} from 'vue';\nimport {useRoute, useRouter} from 'vue-router';\nimport {useAuth} from '@/composables/useAuth';\nimport Form from 'vform';\n\nconst {saveToken} = useAuth();\nconst route = useRoute();\nconst router = useRouter();\n\nconst form = ref(new Form({\n email: '',\n password: '',\n code: '',\n remember: true,\n}));\n\nconst showPassword = ref(false);\nconst loginFail = ref(false);\nconst loginFailMessage = ref('Email and/or password is incorrect.');\nconst redirect = ref('');\nconst twoFactorAuth = ref(false);\nconst last2 = ref('');\n\nconst isFormValid = computed(() =>\n ['email', 'password'].every((field) => form.value[field]?.length)\n);\n\nconst isButtonDisabled = computed(() => form.value.busy || !isFormValid.value);\n\nconst registerFormRules = {\n email: emailRule(),\n min: minLengthRule(8),\n code: codeRule(),\n required: requiredRule,\n};\n\nconst togglePasswordVisibility = () => {\n showPassword.value = !showPassword.value;\n};\n\nonBeforeMount(() => {\n form.value.email = route.query?.email || route.params?.email || form.value?.email;\n});\n\nwatch(() => route.query, (newQuery) => {\n if (!newQuery) return;\n\n const redirectQuery = newQuery.redirect;\n redirect.value = Array.isArray(redirectQuery) ? redirectQuery[0] : redirectQuery ?? undefined;\n}, {immediate: true});\n\n\nconst handleLoginResponse = async (data: { last2?: string, access_token: string }) => {\n if (data?.['2fa']) {\n twoFactorAuth.value = true;\n last2.value = data?.last2 ?? 'xx';\n return;\n }\n\n await saveToken({token: data?.access_token});\n\n const redirectQuery = route.query.redirect;\n let redirectTo = {path: '/dashboard'};\n\n\n if (redirectQuery) {\n try {\n redirectTo = {path: decodeURIComponent(Array.isArray(redirectQuery) ? redirectQuery[0] : redirectQuery)};\n } catch (err) {\n console.warn(\"Invalid redirect URL:\", redirectQuery);\n }\n }\n\n await router.push(redirectTo).catch(err => {\n console.error(\"Router navigation error:\", err);\n });\n};\n\nconst login = async () => {\n if (form.value.busy) return;\n\n loginFail.value = false;\n form.value.busy = true;\n\n try {\n const {data} = await form.value.post('/v1/auth/login');\n await handleLoginResponse(data);\n } catch (error) {\n handleLoginError(error);\n } finally {\n form.value.busy = false;\n }\n};\n\nconst handleLoginError = (error: { response: { status: number, data: { error: string } } }) => {\n if (error?.response?.status === 422) {\n loginFailMessage.value = error?.response?.data?.error || 'An unknown error occurred. Please try again.';\n twoFactorAuth.value = false;\n form.value.code = '';\n }\n loginFail.value = true;\n};\n</script>\n","<template>\n <section class=\"bg-gray-50 dark:bg-gray-900 bg-fixed\">\n <div class=\"flex flex-col items-center justify-center px-6 py-8 mx-auto md:h-screen lg:py-0\">\n <a class=\"flex items-center mb-6 text-2xl font-semibold text-gray-900 dark:text-white\" href=\"/\">\n <img alt=\"logo\" class=\"w-8 h-8 mr-2\" src=\"https://tenant.fleetwire.io/images/logo/fleetwire-logo-new.png\">\n Fleetwire\n </a>\n <div class=\"w-full bg-white rounded-lg shadow dark:border md:mt-0 sm:max-w-md xl:p-0 dark:bg-gray-800 dark:border-gray-700\">\n <div class=\"p-6 space-y-3 md:space-y-4 sm:p-8\">\n <h1 class=\"text-xl font-bold leading-tight tracking-tight text-gray-900 md:text-2xl dark:text-white\">\n Start a free 14-day trial\n </h1>\n <v-form :disabled=\"form.busy\" class=\"space-y-2 md:space-y-3\" @keydown=\"form.onKeydown($event)\" @submit.prevent=\"register\">\n <div>\n <v-text-field\n v-model=\"form.company_name\"\n :autofocus=true\n :error-messages=\"form.errors.get('company_name')\"\n :label=\"$t('company_name')\"\n density=\"comfortable\"\n name=\"company_name\"\n required\n variant=\"outlined\"\n />\n </div>\n <div>\n <v-text-field\n v-model=\"form.email\"\n :error-messages=\"form.errors.get('email')\"\n :label=\"$t('company_email')\"\n :rules=\"registrationFormRules.email\"\n density=\"comfortable\"\n name=\"email\"\n required\n variant=\"outlined\"\n />\n </div>\n <div>\n <v-text-field\n v-model=\"form.password\"\n :error-messages=\"form.errors.get('password')\"\n :label=\"$t('password')\"\n :rules=\"[registrationFormRules.required, registrationFormRules.min]\"\n autocomplete=\"new-password\"\n density=\"comfortable\"\n name=\"password\"\n type=\"password\"\n variant=\"outlined\"\n />\n </div>\n\n <div class=\"flex items-start\">\n <div class=\"flex items-center h-5\">\n <input id=\"fw-agree-checkbox\" v-model=\"form.agree\" :error-messages=\"form.errors.get('agree')\" aria-describedby=\"terms\" class=\"w-4 h-4 border border-gray-300 rounded bg-gray-50 focus:ring-3 focus:ring-primary-300 dark:bg-gray-700 dark:border-gray-600 dark:focus:ring-primary-600 dark:ring-offset-gray-800\" name=\"agree\" required type=\"checkbox\">\n </div>\n <div class=\"ml-3 text-sm\">\n <label class=\"font-light text-gray-500 dark:text-gray-300\" for=\"fw-agree-checkbox\">I accept the\n <a v-tippy class=\"font-medium text-primary-600 hover:underline dark:text-primary-500\"\n content=\"Opens in a new window\"\n href=\"https://fleetwire.io/terms?utm_source=register_page&utm_medium=web&utm_campaign=signup&utm_content=terms_link\"\n target=\"_blank\"\n @click.stop\n >{{ $t('terms_of_service') }}</a>\n &\n <a v-tippy class=\"font-medium text-primary-600 hover:underline dark:text-primary-500\"\n content=\"Opens in a new window\"\n href=\"https://fleetwire.io/privacy-policy?utm_source=register_page&utm_medium=web&utm_campaign=signup&utm_content=privacy_link\"\n target=\"_blank\"\n @click.stop\n >Privacy Policy</a>\n </label>\n </div>\n </div>\n <v-btn id=\"fw-register-button\" :disabled=\"isButtonDisabled\" :loading=\"form.busy\" block class=\"mt-5\" size=\"large\" type=\"submit\">\n {{ $t('register') }}\n </v-btn>\n\n <p class=\"mt-5 text-sm font-light text-gray-500 dark:text-gray-400\">\n Already have an account?\n <router-link :to=\"{ name: 'login' }\" class=\"font-medium text-primary-600 hover:underline dark:text-primary-500\">\n <b>{{ $t('login') }} here</b>\n </router-link>\n </p>\n </v-form>\n </div>\n </div>\n\n <div class=\"mt-5 text-center\">\n <div class=\"p-1 bg-gray-100 border font-medium text-xs text-gray-600 mb-14 mx-4 line rounded-md\" style=\" border: 1px solid rgb(224, 228, 232);background: rgb(224, 228, 232);\">\n It only takes a few seconds, no credit card required!\n </div>\n </div>\n </div>\n </section>\n</template>\n\n<script lang=\"ts\" setup>\nimport {computed, onMounted, ref} from 'vue';\nimport {useRoute, useRouter} from 'vue-router';\nimport {useStore} from 'vuex';\nimport {useAuth} from '@/composables/useAuth';\nimport Form from 'vform';\n\nconst route = useRoute();\nconst router = useRouter();\nconst store = useStore();\nconst {registrationFormRules} = useAuth();\n\nconst form = ref(new Form({\n email: '',\n password: '',\n company_name: '',\n agree: false,\n}));\n\nconst isFormValid = computed(\n () => ['email', 'password', 'company_name'].every((field) => form.value[field]?.length) && form.value.agree\n);\n\nconst isButtonDisabled = computed(() => form.value.busy || !isFormValid.value);\n\nonMounted(() => {\n form.value.email = (route.query?.email as string) || '';\n form.value.company_name = (route.query?.company as string) || '';\n});\n\nconst saveRegisterId = async (id: string) => {\n try {\n await store.dispatch('auth/saveRegisterId', id);\n } catch (error) {\n console.error('Failed to save registration ID:', error);\n }\n};\n\nconst register = async () => {\n if (!isFormValid.value) return;\n\n // Register the user.\n try {\n const {data} = await form.value.post('/v1/register');\n await saveRegisterId(data.register_id);\n\n // this.$gtag.event('Register', { email: form.value.email });\n // Log success and redirect\n console.info('User registered successfully', data);\n router.push({name: 'company.next-step'}).catch((err) => console.error(err));\n } catch (e) {\n console.error('Registration failed:', e);\n }\n};\n</script>\n","import dayjs, {Dayjs} from 'dayjs';\n\n\n/**\n * Format a date with a default format or supplied.\n *\n * @param date - The date to be formatted, can be a Date object, a string, or a number.\n * @param format - The format in which to display the date.\n *\n * @return The formatted date string.\n */\nexport function formatTripDate(date: Date | string | number, format: string = 'MMM DD, YYYY @ h:mma'): string {\n return dayjs(date).format(format);\n}\n\nexport const guessTimeZone = dayjs.tz?.guess();\n\nexport const getUserTimezone = () => {\n return Intl.DateTimeFormat().resolvedOptions().timeZone;\n}\n\nexport const calcMiles = (\n dates: { start: Date | Dayjs, end: Date | Dayjs },\n milesIncluded: number,\n maxDistance?: number\n): string => {\n const startDate = dates?.start ? dayjs(dates.start) : dayjs();\n const endDate = dates?.end ? dayjs(dates.end) : dayjs();\n\n if (milesIncluded === -1) return 'unlimited';\n\n const units = endDate.diff(startDate, 'days') + (endDate.diff(startDate, 'hours') % 24 > 0 ? 1 : 0);\n const allowance = units * milesIncluded;\n\n\n const x = maxDistance ? Math.min(maxDistance, allowance) : allowance;\n\n if (x === 0) return '0';\n\n return x.toString().replace(/\\B(?=(\\d{3})+(?!\\d))/g, ',');\n};\n\nexport const generateReservationTimes = (\n startHour: number = 0, // Opening hour in 24-hour format\n endHour: number = 24, // Closing hour in 24-hour format\n interval: number = 15, // Interval between time slots in minutes\n selectedDate: Dayjs | string | null = null, // The selected date (e.g., `currentSelectedDates.value.start`)\n allowPastTime: boolean = false // Whether past times are allowed for today\n) => {\n const times = [];\n const now = dayjs(); // Current time\n const start = dayjs().hour(startHour).minute(0).second(0); // Start of time range\n const end = dayjs().hour(endHour).minute(0).second(0); // End of time range\n\n let effectiveStart = start;\n\n // Check if the selected date is today\n const isToday = selectedDate ? dayjs().isSame(selectedDate, 'day') : false;\n\n // Adjust the start time if it's today and past times are not allowed\n if (isToday && !allowPastTime && now.isAfter(start)) {\n const minutesSinceStart = now.diff(start, 'minutes');\n const nextIntervalMinutes = Math.ceil(minutesSinceStart / interval) * interval;\n effectiveStart = start.add(nextIntervalMinutes, 'minute');\n }\n\n // Validate if the time range is valid\n if (startHour >= endHour || interval <= 0) {\n console.warn(\"Invalid time range or interval\");\n return times; // Return empty array if invalid\n }\n\n // Generate time slots between the effective start and end\n for (let time = effectiveStart; time.isBefore(end); time = time.add(interval, 'minute')) {\n const timeValue = time.format('HH:mm:00');\n const timeTitle = timeValue === '12:00:00' ? 'Noon' : time.format('hh:mm a');\n\n times.push({\n title: timeTitle,\n value: timeValue,\n });\n }\n\n return times;\n};\n\nexport const timezones = [\n 'Europe/Andorra',\n 'Asia/Dubai',\n 'Asia/Kabul',\n 'Europe/Tirane',\n 'Asia/Yerevan',\n 'Antarctica/Casey',\n 'Antarctica/Davis',\n 'Antarctica/DumontDUrville', // https://bugs.chromium.org/p/chromium/issues/detail?id=928068\n 'Antarctica/Mawson',\n 'Antarctica/Palmer',\n 'Antarctica/Rothera',\n 'Antarctica/Syowa',\n 'Antarctica/Troll',\n 'Antarctica/Vostok',\n 'America/Argentina/Buenos_Aires',\n 'America/Argentina/Cordoba',\n 'America/Argentina/Salta',\n 'America/Argentina/Jujuy',\n 'America/Argentina/Tucuman',\n 'America/Argentina/Catamarca',\n 'America/Argentina/La_Rioja',\n 'America/Argentina/San_Juan',\n 'America/Argentina/Mendoza',\n 'America/Argentina/San_Luis',\n 'America/Argentina/Rio_Gallegos',\n 'America/Argentina/Ushuaia',\n 'Pacific/Pago_Pago',\n 'Europe/Vienna',\n 'Australia/Lord_Howe',\n 'Antarctica/Macquarie',\n 'Australia/Hobart',\n 'Australia/Currie',\n 'Australia/Melbourne',\n 'Australia/Sydney',\n 'Australia/Broken_Hill',\n 'Australia/Brisbane',\n 'Australia/Lindeman',\n 'Australia/Adelaide',\n 'Australia/Darwin',\n 'Australia/Perth',\n 'Australia/Eucla',\n 'Asia/Baku',\n 'America/Barbados',\n 'Asia/Dhaka',\n 'Europe/Brussels',\n 'Europe/Sofia',\n 'Atlantic/Bermuda',\n 'Asia/Brunei',\n 'America/La_Paz',\n 'America/Noronha',\n 'America/Belem',\n 'America/Fortaleza',\n 'America/Recife',\n 'America/Araguaina',\n 'America/Maceio',\n 'America/Bahia',\n 'America/Sao_Paulo',\n 'America/Campo_Grande',\n 'America/Cuiaba',\n 'America/Santarem',\n 'America/Porto_Velho',\n 'America/Boa_Vista',\n 'America/Manaus',\n 'America/Eirunepe',\n 'America/Rio_Branco',\n 'America/Nassau',\n 'Asia/Thimphu',\n 'Europe/Minsk',\n 'America/Belize',\n 'America/St_Johns',\n 'America/Halifax',\n 'America/Glace_Bay',\n 'America/Moncton',\n 'America/Goose_Bay',\n 'America/Blanc-Sablon',\n 'America/Toronto',\n 'America/Nipigon',\n 'America/Thunder_Bay',\n 'America/Iqaluit',\n 'America/Pangnirtung',\n 'America/Atikokan',\n 'America/Winnipeg',\n 'America/Rainy_River',\n 'America/Resolute',\n 'America/Rankin_Inlet',\n 'America/Regina',\n 'America/Swift_Current',\n 'America/Edmonton',\n 'America/Cambridge_Bay',\n 'America/Yellowknife',\n 'America/Inuvik',\n 'America/Creston',\n 'America/Dawson_Creek',\n 'America/Fort_Nelson',\n 'America/Vancouver',\n 'America/Whitehorse',\n 'America/Dawson',\n 'Indian/Cocos',\n 'Europe/Zurich',\n 'Africa/Abidjan',\n 'Pacific/Rarotonga',\n 'America/Santiago',\n 'America/Punta_Arenas',\n 'Pacific/Easter',\n 'Asia/Shanghai',\n 'Asia/Urumqi',\n 'America/Bogota',\n 'America/Costa_Rica',\n 'America/Havana',\n 'Atlantic/Cape_Verde',\n 'America/Curacao',\n 'Indian/Christmas',\n 'Asia/Nicosia',\n 'Asia/Famagusta',\n 'Europe/Prague',\n 'Europe/Berlin',\n 'Europe/Copenhagen',\n 'America/Santo_Domingo',\n 'Africa/Algiers',\n 'America/Guayaquil',\n 'Pacific/Galapagos',\n 'Europe/Tallinn',\n 'Africa/Cairo',\n 'Africa/El_Aaiun',\n 'Europe/Madrid',\n 'Africa/Ceuta',\n 'Atlantic/Canary',\n 'Europe/Helsinki',\n 'Pacific/Fiji',\n 'Atlantic/Stanley',\n 'Pacific/Chuuk',\n 'Pacific/Pohnpei',\n 'Pacific/Kosrae',\n 'Atlantic/Faroe',\n 'Europe/Paris',\n 'Europe/London',\n 'Asia/Tbilisi',\n 'America/Cayenne',\n 'Africa/Accra',\n 'Europe/Gibraltar',\n 'America/Godthab',\n 'America/Danmarkshavn',\n 'America/Scoresbysund',\n 'America/Thule',\n 'Europe/Athens',\n 'Atlantic/South_Georgia',\n 'America/Guatemala',\n 'Pacific/Guam',\n 'Africa/Bissau',\n 'America/Guyana',\n 'Asia/Hong_Kong',\n 'America/Tegucigalpa',\n 'America/Port-au-Prince',\n 'Europe/Budapest',\n 'Asia/Jakarta',\n 'Asia/Pontianak',\n 'Asia/Makassar',\n 'Asia/Jayapura',\n 'Europe/Dublin',\n 'Asia/Jerusalem',\n 'Asia/Kolkata',\n 'Indian/Chagos',\n 'Asia/Baghdad',\n 'Asia/Tehran',\n 'Atlantic/Reykjavik',\n 'Europe/Rome',\n 'America/Jamaica',\n 'Asia/Amman',\n 'Asia/Tokyo',\n 'Africa/Nairobi',\n 'Asia/Bishkek',\n 'Pacific/Tarawa',\n 'Pacific/Enderbury',\n 'Pacific/Kiritimati',\n 'Asia/Pyongyang',\n 'Asia/Seoul',\n 'Asia/Almaty',\n 'Asia/Qyzylorda',\n 'Asia/Qostanay', // https://bugs.chromium.org/p/chromium/issues/detail?id=928068\n 'Asia/Aqtobe',\n 'Asia/Aqtau',\n 'Asia/Atyrau',\n 'Asia/Oral',\n 'Asia/Beirut',\n 'Asia/Colombo',\n 'Africa/Monrovia',\n 'Europe/Vilnius',\n 'Europe/Luxembourg',\n 'Europe/Riga',\n 'Africa/Tripoli',\n 'Africa/Casablanca',\n 'Europe/Monaco',\n 'Europe/Chisinau',\n 'Pacific/Majuro',\n 'Pacific/Kwajalein',\n 'Asia/Yangon',\n 'Asia/Ulaanbaatar',\n 'Asia/Hovd',\n 'Asia/Choibalsan',\n 'Asia/Macau',\n 'America/Martinique',\n 'Europe/Malta',\n 'Indian/Mauritius',\n 'Indian/Maldives',\n 'America/Mexico_City',\n 'America/Cancun',\n 'America/Merida',\n 'America/Monterrey',\n 'America/Matamoros',\n 'America/Mazatlan',\n 'America/Chihuahua',\n 'America/Ojinaga',\n 'America/Hermosillo',\n 'America/Tijuana',\n 'America/Bahia_Banderas',\n 'Asia/Kuala_Lumpur',\n 'Asia/Kuching',\n 'Africa/Maputo',\n 'Africa/Windhoek',\n 'Pacific/Noumea',\n 'Pacific/Norfolk',\n 'Africa/Lagos',\n 'America/Managua',\n 'Europe/Amsterdam',\n 'Europe/Oslo',\n 'Asia/Kathmandu',\n 'Pacific/Nauru',\n 'Pacific/Niue',\n 'Pacific/Auckland',\n 'Pacific/Chatham',\n 'America/Panama',\n 'America/Lima',\n 'Pacific/Tahiti',\n 'Pacific/Marquesas',\n 'Pacific/Gambier',\n 'Pacific/Port_Moresby',\n 'Pacific/Bougainville',\n 'Asia/Manila',\n 'Asia/Karachi',\n 'Europe/Warsaw',\n 'America/Miquelon',\n 'Pacific/Pitcairn',\n 'America/Puerto_Rico',\n 'Asia/Gaza',\n 'Asia/Hebron',\n 'Europe/Lisbon',\n 'Atlantic/Madeira',\n 'Atlantic/Azores',\n 'Pacific/Palau',\n 'America/Asuncion',\n 'Asia/Qatar',\n 'Indian/Reunion',\n 'Europe/Bucharest',\n 'Europe/Belgrade',\n 'Europe/Kaliningrad',\n 'Europe/Moscow',\n 'Europe/Simferopol',\n 'Europe/Kirov',\n 'Europe/Astrakhan',\n 'Europe/Volgograd',\n 'Europe/Saratov',\n 'Europe/Ulyanovsk',\n 'Europe/Samara',\n 'Asia/Yekaterinburg',\n 'Asia/Omsk',\n 'Asia/Novosibirsk',\n 'Asia/Barnaul',\n 'Asia/Tomsk',\n 'Asia/Novokuznetsk',\n 'Asia/Krasnoyarsk',\n 'Asia/Irkutsk',\n 'Asia/Chita',\n 'Asia/Yakutsk',\n 'Asia/Khandyga',\n 'Asia/Vladivostok',\n 'Asia/Ust-Nera',\n 'Asia/Magadan',\n 'Asia/Sakhalin',\n 'Asia/Srednekolymsk',\n 'Asia/Kamchatka',\n 'Asia/Anadyr',\n 'Asia/Riyadh',\n 'Pacific/Guadalcanal',\n 'Indian/Mahe',\n 'Africa/Khartoum',\n 'Europe/Stockholm',\n 'Asia/Singapore',\n 'America/Paramaribo',\n 'Africa/Juba',\n 'Africa/Sao_Tome',\n 'America/El_Salvador',\n 'Asia/Damascus',\n 'America/Grand_Turk',\n 'Africa/Ndjamena',\n 'Indian/Kerguelen',\n 'Asia/Bangkok',\n 'Asia/Dushanbe',\n 'Pacific/Fakaofo',\n 'Asia/Dili',\n 'Asia/Ashgabat',\n 'Africa/Tunis',\n 'Pacific/Tongatapu',\n 'Europe/Istanbul',\n 'America/Port_of_Spain',\n 'Pacific/Funafuti',\n 'Asia/Taipei',\n 'Europe/Kiev',\n 'Europe/Uzhgorod',\n 'Europe/Zaporozhye',\n 'Pacific/Wake',\n 'America/New_York',\n 'America/Detroit',\n 'America/Kentucky/Louisville',\n 'America/Kentucky/Monticello',\n 'America/Indiana/Indianapolis',\n 'America/Indiana/Vincennes',\n 'America/Indiana/Winamac',\n 'America/Indiana/Marengo',\n 'America/Indiana/Petersburg',\n 'America/Indiana/Vevay',\n 'America/Chicago',\n 'America/Indiana/Tell_City',\n 'America/Indiana/Knox',\n 'America/Menominee',\n 'America/North_Dakota/Center',\n 'America/North_Dakota/New_Salem',\n 'America/North_Dakota/Beulah',\n 'America/Denver',\n 'America/Boise',\n 'America/Phoenix',\n 'America/Los_Angeles',\n 'America/Anchorage',\n 'America/Juneau',\n 'America/Sitka',\n 'America/Metlakatla',\n 'America/Yakutat',\n 'America/Nome',\n 'America/Adak',\n 'Pacific/Honolulu',\n 'America/Montevideo',\n 'Asia/Samarkand',\n 'Asia/Tashkent',\n 'America/Caracas',\n 'Asia/Ho_Chi_Minh',\n 'Pacific/Efate',\n 'Pacific/Wallis',\n 'Pacific/Apia',\n 'Africa/Johannesburg',\n];\n","<template>\n <section class=\"bg-gray-50 dark:bg-gray-900 signup-setup\">\n <div class=\"flex flex-col items-center justify-center px-6 py-8 mx-auto md:h-screen lg:py-0\">\n <a class=\"flex items-center mb-6 text-2xl font-semibold text-gray-900 dark:text-white\" href=\"/\">\n <img alt=\"logo\" class=\"w-8 h-8 mr-2\" src=\"https://tenant.fleetwire.io/images/logo/fleetwire-logo-new.png\">\n Fleetwire\n </a>\n <div class=\"w-full bg-white rounded-lg shadow dark:border md:mt-0 sm:max-w-md xl:p-0 dark:bg-gray-800 dark:border-gray-700\">\n <div class=\"p-6 space-y-4 md:space-y-6 sm:p-8\">\n <h1 class=\"text-xl font-bold leading-tight tracking-tight text-gray-900 md:text-2xl dark:text-white\">\n Continue with your setup\n </h1>\n <v-form :disabled=\"form.busy\" class=\"space-y-2 md:space-y-3\" @keydown=\"form.onKeydown($event)\" @submit.prevent=\"completeRegister\">\n <div>\n <v-text-field\n v-model=\"form.first_name\"\n :autofocus=\"true\"\n :error-messages=\"form.errors.get('first_name')\"\n :label=\"$t('first_name')\"\n name=\"first_name\"\n variant=\"outlined\"\n />\n </div>\n <div>\n <v-text-field\n v-model=\"form.last_name\"\n :error-messages=\"form.errors.get('last_name')\"\n :label=\"$t('last_name')\"\n name=\"last_name\"\n variant=\"outlined\"\n />\n </div>\n <div>\n <vue-tel-input\n v-model=\"form.phone\"\n v-bind=\"tellProps\"\n @validate=\"inputChanged\"\n />\n </div>\n\n <div class=\"mb-10 mt-5\">\n <div class=\"preferences mb-2\">\n <div class=\"preferences__preview\">\n <div v-if=\"!editPreferences\">\n <v-btn class=\"edit-toggle\" size=\"small\" variant=\"text\" @click=\"editPreferences = !editPreferences\">\n Edit\n </v-btn>\n <span class=\"flag\">\n <span style=\"width: 1em; height: 1em; margin: 0 0.05em 0 0.1em; vertical-align: -0.1em;\">\n {{ displayCountryFlag }}\n </span>\n </span>\n <div class=\"text\">\n <div class=\"country\">{{ displayCountry }}</div>\n Currency: {{ displayCurrency }}<br>\n Date format: {{ displayDateFormat }}<br>\n Time format: {{ form.timezone }}, {{ displayTimeFormat }}\n </div>\n </div>\n <div v-if=\"editPreferences\">\n <div>\n <div class=\"col-6\">\n <v-autocomplete\n v-model=\"form.country\"\n :items=\"countriesAsArray\"\n density=\"compact\"\n label=\"Country\"\n variant=\"outlined\"\n />\n </div>\n <div class=\"col-6\">\n <v-autocomplete\n v-model=\"form.timezone\"\n :items=\"timezones\"\n density=\"compact\"\n label=\"Timezone\"\n variant=\"outlined\"\n />\n </div>\n </div>\n <div>\n <div class=\"col-6\">\n <v-autocomplete\n v-model=\"form.currency\"\n :items=\"currenciesAsArray\"\n density=\"compact\"\n label=\"Currency\"\n variant=\"outlined\"\n />\n </div>\n <div class=\"col-6\">\n <v-select\n v-model=\"form.date_format\"\n :items=\"dataFormatOptions\"\n density=\"compact\"\n label=\"Date Format\"\n variant=\"outlined\"\n />\n </div>\n </div>\n <div>\n <div class=\"col-6\">\n <v-autocomplete\n v-model=\"form.time_format\"\n :items=\"timeFormatOptions\"\n density=\"compact\"\n item-title=\"label\"\n item-value=\"value\"\n label=\"Time Format\"\n variant=\"outlined\"\n />\n </div>\n </div>\n\n <v-btn class=\"edit-toggle close\" size=\"small\" variant=\"plain\" @click=\"editPreferences = !editPreferences\">\n Close\n </v-btn>\n </div>\n </div>\n </div>\n </div>\n\n <v-btn :disabled=\"form.busy || !regFieldsMissing\" :loading=\"form.busy\" block class=\"mt-5\" size=\"large\" type=\"submit\" variant=\"elevated\">\n {{ $t('complete') }}\n </v-btn>\n </v-form>\n </div>\n </div>\n </div>\n </section>\n</template>\n\n<script lang=\"ts\" setup>\nimport {computed, onMounted, ref, watch} from 'vue';\nimport Form from 'vform';\nimport {useStore} from 'vuex';\nimport {isEmpty, isSet} from 'lodash';\nimport {VueTelInput} from 'vue-tel-input';\nimport 'vue-tel-input/vue-tel-input.css';\nimport dayjs from 'dayjs';\nimport utc from 'dayjs/plugin/utc';\nimport timezone from 'dayjs/plugin/timezone';\nimport {useRouter} from 'vue-router';\nimport {timezones} from '@/utils/dates';\nimport {CountryOption} from '@/types';\n\ndayjs.extend(utc);\ndayjs.extend(timezone);\n\n\nconst router = useRouter();\nconst store = useStore();\nconst editPreferences = ref(false);\n\nconst countryOptions = store.getters['app/countryOptions'];\nconst registerId = store.getters['auth/registerId'];\n\nconst saveToken = async (token: { token: string, remember: boolean }) => {\n await store.dispatch('auth/saveToken', token);\n};\n\nconst removeRegisterId = async () => {\n await store.dispatch('auth/saveRegisterId', '');\n};\n\nconst countries = countryOptions.reduce((acc: string[], country: CountryOption) => {\n acc[country.code] = country.name;\n return acc;\n}, {});\n\n\nconst form = ref(new Form({\n phone: '',\n phoneMeta: null,\n first_name: '',\n last_name: '',\n team_size: 1,\n register_id: '',\n timezone: '',\n country: 'US',\n currency: 'USD',\n date_format: 'mm-dd-yyyy',\n time_format: '12-hour',\n}));\n\nconst guessCountryData = ref({\n country: '',\n timezone: '',\n flag: '',\n});\n\nconst regMissing = ref(false);\nconst tellProps = ref({\n defaultCountry: 'US',\n preferredCountries: ['US', 'CA'],\n});\nconst ipData = ref(null);\nconst dataFormatOptions = ref(['mm-dd-yyyy', 'dd-mm-yyyy', 'yyyy-mm-dd']);\nconst timeFormatOptions = ref([\n {\n label: '12-Hour clock',\n value: '12-hour',\n },\n {\n label: '24-Hour clock',\n value: '24-hour',\n },\n]);\nconst intl = ref(Intl.DateTimeFormat().resolvedOptions());\n\nconst currenciesAsArray = computed(() => {\n const uniqueCodes = new Set();\n const prioritized = ['USD', 'EUR']\n\n const filtered = countryOptions\n .map((country: CountryOption) => country.currency)\n .filter((code: string) => {\n if (code && !uniqueCodes.has(code)) {\n uniqueCodes.add(code);\n return true;\n }\n return false;\n });\n\n return [...new Set([...prioritized, ...filtered])];\n});\n\nconst countriesAsArray = computed(() => {\n return countryOptions.map((country: CountryOption) => ({\n title: country.name,\n value: country.code,\n }));\n});\n\n\nconst displayCountry = computed(() => {\n return countries[form.value.country];\n});\n\nconst displayCurrency = computed(() => {\n return form.value.currency;\n});\n\nconst displayDateFormat = computed(() => {\n return form.value.date_format.toUpperCase();\n});\n\nconst displayTimeFormat = computed(() => {\n return form.value.time_format;\n});\n\nconst displayCountryFlag = computed(() => {\n return getFlagEmoji(form.value.country);\n});\n\nconst regFieldsMissing = computed(() => {\n return form.value.phone.length\n && form.value.team_size >= 1\n && form.value.first_name.length\n && form.value.last_name.length\n && form.value.phoneMeta?.valid;\n});\n\n\nconst getFlagEmoji = (countryCode: string) => {\n countryCode = countryCode.slice(0, 2);\n const codePoints = countryCode\n .toUpperCase()\n .split('')\n .map(char => 127397 + char.charCodeAt(0));\n return String.fromCodePoint(...codePoints);\n};\n\nconst inputChanged = (phone: any) => {\n form.value.phoneMeta = phone;\n};\n\nconst completeRegister = async () => {\n const response = await form.value.put(`/v1/register/${registerId}/complete`);\n\n if (response.status >= 200 && response.status < 300) {\n // Log in the user.\n const {data} = await form.value.post('/v1/auth/login');\n\n // Save the token.\n await saveToken({\n token: data.access_token,\n remember: true,\n });\n\n // remove the register id.\n await removeRegisterId();\n\n await store.dispatch('auth/fetchUser');\n\n // Redirect home.\n router.push({name: 'dashboard'}).catch(() => {\n });\n }\n};\n\n\nonMounted(async () => {\n try {\n const response = await fetch('https://api.geoapify.com/v1/ipinfo?apiKey=dc3d43b77c0e4876be94173b5b8a7bc9');\n\n if (!response.ok) {\n console.warn('GeoAPI request failed:', response.statusText);\n return;\n }\n\n const json = await response.json();\n if (!json?.country?.iso_code) {\n console.warn('GeoAPI response missing country data:', json);\n return;\n }\n\n ipData.value = json;\n\n guessCountryData.value.country = countries[json.country.iso_code] || 'United States';\n guessCountryData.value.flag = getFlagEmoji(json.country.iso_code);\n form.value.currency = json.country.currency?.split(',')[0] || 'USD';\n form.value.country = json.country.iso_code || 'US';\n } catch (error) {\n console.error('Error fetching IP info:', error);\n }\n\n if (!isSet(registerId) || isEmpty(registerId)) {\n regMissing.value = true;\n }\n\n form.value.register_id = registerId;\n guessCountryData.value.timezone = intl.value.timeZone;\n form.value.timezone = intl.value.timeZone;\n\n const country = intl.value.locale.slice(-2).toUpperCase();\n guessCountryData.value.country = countries[country] || 'United States';\n});\n\nwatch(() => ipData.value, (data) => {\n if (data?.country?.iso_code) {\n guessCountryData.value.country = countries[data.country.iso_code] || 'United States';\n guessCountryData.value.flag = getFlagEmoji(data.country.iso_code);\n form.value.currency = data.country.currency?.split(',')[0] || 'USD';\n form.value.country = data.country.iso_code;\n }\n});\n</script>\n\n<style>\n.signup-setup .preferences {\n border: 1px solid #E2E6EB;\n padding: 18px 18px 0 18px;\n border-radius: 6px;\n position: relative;\n}\n\n.signup-setup .preferences__preview {\n margin-bottom: 18px;\n font-size: 13px;\n color: #546972;\n line-height: 18px;\n}\n\n.signup-setup .preferences .edit-toggle {\n position: absolute;\n right: 18px;\n z-index: 99;\n}\n\n.signup-setup .preferences .edit-toggle.close {\n bottom: 10px;\n}\n\n.signup-setup .preferences__preview span.flag {\n font-size: 24px;\n display: inline-block;\n position: absolute;\n left: 13px;\n}\n\n.signup-setup .preferences__preview .text {\n padding-left: 30px;\n}\n\n.signup-setup .preferences__preview .country {\n font-size: 14px;\n font-weight: bold;\n color: #181818;\n}\n</style>\n\n<style>\n.vue-tel-input {\n min-height: 56px;\n\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-flex: 1;\n -ms-flex: 1 1 auto;\n flex: 1 1 auto;\n position: relative;\n\n -webkit-box-align: center;\n -ms-flex-align: center;\n align-items: center;\n\n color: rgba(0, 0, 0, .38);\n border-collapse: collapse;\n border: 1px solid;\n right: 0;\n top: -5px;\n}\n\n.vue-tel-input input {\n color: rgba(0, 0, 0, .87);\n max-height: 32px;\n -webkit-box-flex: 1;\n -ms-flex: 1 1 auto;\n flex: 1 1 auto;\n line-height: 20px;\n max-width: 100%;\n min-width: 0;\n width: 100%;\n border: none;\n border-radius: 0 2px 2px 0;\n outline: none;\n padding: 8px 0 8px 7px;\n}\n\n.vue-tel-input:focus-within {\n border: #62a477 2px solid;\n caret-color: #62a477 !important;\n box-shadow: none;\n}\n\n.vue-tel-input .vti__dropdown {\n min-height: 100%;\n}\n</style>\n","import {store} from '@/store';\nimport {DefaultMeta} from '@/types';\n\nexport default function getDefaultMeta(value: string): string | boolean | object | number | undefined {\n const meta: DefaultMeta = store.getters['company/defaultMeta'];\n\n return meta[value];\n}\n\n\nexport function getMetaBooleanValue(value: string, trueIfMissing: boolean = false): boolean {\n const meta: DefaultMeta = store.getters['company/defaultMeta'];\n\n if (meta[value] === undefined || meta[value] === null) {\n return trueIfMissing;\n }\n \n return Boolean(meta[value]);\n}","import {computed, ComputedRef} from 'vue';\nimport {useStore} from 'vuex';\nimport {CompanyInterface, CompanyMeta, DefaultMeta, StoreLoaders} from '@/types';\nimport getDefaultMeta from '@/utils/meta';\n\nexport function useCompany() {\n const store = useStore();\n\n\n const companyToken = computed(() => store.getters['auth/token']);\n const company = computed<CompanyInterface>(() => store.getters['company/company']);\n const companySettings: ComputedRef<any> = computed(() => store.getters['company/settings']);\n const defaultMeta: ComputedRef<DefaultMeta> = computed(() => store.getters['company/defaultMeta']);\n const companyMeta = computed<CompanyMeta>(() => store.getters['company/meta']);\n const companyLoading: ComputedRef<StoreLoaders> = computed(() => store.getters['company/companyLoading']);\n const companyForm = computed(() => store.getters['company/companyForm']);\n const originalCompany = computed(() => store.getters['company/originalCompany']);\n const companyLoaded = computed(() => store.getters['company/loaded']);\n const registerFormRules = computed(() => store.getters['company/registerFormRules']);\n const operatingRules = computed(() => store.getters['company/operatingRules']);\n\n const companyMetaForm = computed(() => store.getters['company/companyMetaForm']);\n\n const companyTrialOver = computed(() => store.getters['company/trialOver']);\n\n\n const saveCompanyTimezone = (payload: { timezone: string, updateListings: boolean }) => {\n return store.dispatch('company/saveCompanyTimezone', payload);\n }\n\n const companyAdditionalScripts = computed<string | null>(() => getDefaultMeta('settings.custom.scripts') as string | null);\n const additionalStyles = computed<string | null>(() => getDefaultMeta('settings.custom.styles') as string | null);\n const companyFacebookPixelId = computed<string | null>(() => getDefaultMeta('settings.analytics.facebook_id') as string | null);\n const companyGoogleAnalyticsId = computed<string | null>(() => getDefaultMeta('settings.analytics.google_id') as string | null);\n\n function addDefaultMeta(data: { meta: ({ value: any; key: string })[] }) {\n try {\n return store.dispatch('company/addDefaultMeta', data);\n } catch (e) {\n console.error(e);\n throw e;\n }\n }\n\n function fetchDefaultMeta() {\n return store.dispatch('company/getDefaultMeta');\n }\n\n function saveCompanyInfo() {\n return store.dispatch('company/saveCompanyInfo');\n }\n\n\n const saveCompanyMeta = async () => {\n return await store.dispatch('company/saveCompanyMeta');\n }\n\n function getActivityLog(payload: { page?: number, perPage?: number }) {\n return store.dispatch('company/getActivityLog', payload);\n }\n\n const showSetupChecklist = computed(() => {\n return (companySettings.value?.['settings.setup_checklist.show_setup_checklist'] ?? false)\n && !(companySettings.value?.['settings.setup_checklist.hide'] ?? false);\n })\n\n const localizationDistanceUnits = computed(() => {\n return getDefaultMeta('localization_distance_units') ?? 'miles';\n });\n\n const localizationDistanceUnitsObject = computed(() => {\n if (localizationDistanceUnits.value === 'kilometers') {\n return {\n label: 'Kilometer',\n label_plural: 'Kilometers',\n label_abr: 'km',\n };\n }\n return {\n label: 'Mile',\n label_plural: 'Miles',\n label_abr: 'mi',\n };\n })\n\n const setupCustomStyles = () => {\n if (!additionalStyles.value) {\n return; // Exit early if there are no additional styles\n }\n\n // Check if the style element already exists in the DOM\n const existingStyleElement = document.getElementById('FWAdditionalStyles') as HTMLStyleElement | null;\n\n\n if (!existingStyleElement) {\n const companyAdditionalStyle = document.createElement('style');\n companyAdditionalStyle.setAttribute('id', 'FWAdditionalStyles');\n companyAdditionalStyle.setAttribute('type', 'text/css');\n const customStyles = additionalStyles.value;\n\n try {\n companyAdditionalStyle.appendChild(document.createTextNode(customStyles));\n document.body.appendChild(companyAdditionalStyle);\n } catch (e) {\n try {\n companyAdditionalStyle.textContent = customStyles;\n document.body.appendChild(companyAdditionalStyle);\n } catch (e) {\n console.error(e);\n }\n }\n }\n }\n\n const setupCustomScripts = () => {\n if (companyAdditionalScripts.value) {\n if (!document.getElementById('FWAdditionalScripts')) {\n const companyAdditionalScript = document.createElement('script');\n companyAdditionalScript.setAttribute('id', 'FWAdditionalScripts');\n const customScripts = stripScripts(companyAdditionalScripts.value);\n\n try {\n companyAdditionalScript.appendChild(document.createTextNode(customScripts));\n document.body.appendChild(companyAdditionalScript);\n } catch (e) {\n try {\n companyAdditionalScript.text = customScripts;\n document.body.appendChild(companyAdditionalScript);\n } catch (e) {\n console.error(e);\n }\n }\n }\n }\n }\n\n const stripScripts = (s: string) => {\n if (s) {\n /** Remove noscript */\n const noscriptRegex = /<noscript\\b[^<]*(?:(?!<\\/noscript>)<[^<]*)*<\\/noscript>/gi;\n s = s.replace(noscriptRegex, '');\n\n const div = document.createElement('div');\n div.innerHTML = s;\n\n const scripts = div.getElementsByTagName('script');\n let stripScript = '<!-- Fleetwire Custom Script --> \\n\\n';\n\n for (let i = scripts.length - 1; i >= 0; i--) {\n if (scripts[i].innerText) {\n const scriptContent = scripts[i].innerText;\n stripScript += `${scriptContent}; \\n\\n`;\n }\n scripts[i].parentNode?.removeChild(scripts[i]);\n }\n\n stripScript += div.textContent?.trim() || '';\n\n return stripScript;\n }\n return '';\n }\n\n\n return {\n company,\n companyToken,\n companyTrialOver,\n companyFacebookPixelId,\n companyGoogleAnalyticsId,\n originalCompany,\n companySettings,\n companyLoading,\n defaultMeta,\n companyMeta,\n showSetupChecklist,\n companyForm,\n localizationDistanceUnits,\n localizationDistanceUnitsObject,\n registerFormRules,\n companyLoaded,\n companyMetaForm,\n operatingRules,\n setupCustomStyles,\n setupCustomScripts,\n getActivityLog,\n saveCompanyInfo,\n saveCompanyMeta,\n addDefaultMeta,\n fetchDefaultMeta,\n saveCompanyTimezone,\n }\n}","<template>\n <section class=\"bg-gray-50 dark:bg-gray-900\">\n <div class=\"flex flex-col items-center justify-center px-6 py-8 mx-auto md:h-screen lg:py-0\">\n <a class=\"flex items-center mb-6 text-2xl font-semibold text-gray-900 dark:text-white\" href=\"/\">\n <img alt=\"logo\" class=\"w-8 h-8 mr-2\" src=\"https://tenant.fleetwire.io/images/logo/fleetwire-logo-new.png\">\n Fleetwire\n </a>\n <div class=\"w-full bg-white rounded-lg shadow dark:border md:mt-0 sm:max-w-md xl:p-0 dark:bg-gray-800 dark:border-gray-700\">\n <div class=\"p-6 space-y-4 md:space-y-6 sm:p-8\">\n <h1 class=\"text-xl font-bold leading-tight tracking-tight text-gray-900 md:text-2xl dark:text-white\">\n Welcome to Fleetwire.io\n </h1>\n <p class=\"text-muted mb-4 text-subtitle-1\">\n You have been invited by one of your team members. To get started, please fill our some info below.\n </p>\n\n <div v-if=\"!employee.init && companyLoading.invite\">\n Loading...\n </div>\n\n <div v-else-if=\"!employee.found && !companyLoading.invite\">\n <v-alert density=\"compact\" type=\"error\" variant=\"outlined\">\n This invite token does not exist, expired or has been deleted by the company admins.\n </v-alert>\n </div>\n\n <v-form action=\"#\" autocomplete=\"off\" class=\"space-y-4 md:space-y-6\" @keydown=\"form.onKeydown($event)\" @submit.prevent=\"completeInvite\">\n <div class=\"flex flex-col mb-4 space-y-6 md:flex-row md:space-y-0 md:space-x-6\">\n <div class=\"w-full\">\n <v-text-field\n v-model=\"form.first_name\"\n :label=\"$t('first_name')\"\n variant=\"outlined\"\n />\n </div>\n <div class=\"w-full\">\n <v-text-field\n v-model=\"form.last_name\"\n :label=\"$t('last_name')\"\n variant=\"outlined\"\n />\n </div>\n </div>\n <div>\n <v-text-field\n v-model=\"form.phone\"\n :error-messages=\"form.errors.get('phone')\"\n :label=\"$t('phone')\"\n autofocus\n variant=\"outlined\"\n @keydown=\"form.errors.clear('phone')\"\n />\n\n <v-text-field\n v-model=\"form.password\"\n :append-inner-icon=\"showPassword ? 'mdi-eye' : 'mdi-eye-off'\"\n :label=\"$t('password')\"\n :rules=\"[registerFormRules.required, registerFormRules.min]\"\n :type=\"showPassword ? 'text' : 'password'\"\n hint=\"This is a new password for you\"\n persistent-hint\n variant=\"outlined\"\n @click:append-inner=\"showPassword = !showPassword\"\n />\n </div>\n <div class=\"flex items-start\">\n <div class=\"flex items-center h-5\">\n <input id=\"fw-agree-checkbox\" v-model=\"form.agree\" :error-messages=\"form.errors.get('agree')\" aria-describedby=\"terms\" class=\"w-4 h-4 border border-gray-300 rounded bg-gray-50 focus:ring-3 focus:ring-primary-300 dark:bg-gray-700 dark:border-gray-600 dark:focus:ring-primary-600 dark:ring-offset-gray-800\" name=\"agree\" required type=\"checkbox\">\n </div>\n <div class=\"ml-3 text-sm\">\n <label class=\"font-light text-gray-500 dark:text-gray-300\" for=\"fw-agree-checkbox\">I accept the\n <a v-tippy class=\"font-medium text-primary-600 hover:underline dark:text-primary-500\" content=\"Opens in a new window\" href=\"https://fleetwire.io/terms\" target=\"_blank\" @click.stop>{{\n $t('terms_of_service')\n }}</a>\n &\n <a v-tippy class=\"font-medium text-primary-600 hover:underline dark:text-primary-500\" content=\"Opens in a new window\" href=\"https://fleetwire.io/privacy-policy\" target=\"_blank\" @click.stop>Privacy\n Policy</a>\n </label>\n </div>\n </div>\n\n <v-btn :disabled=\"isButtonDisabled\" :loading=\"form.busy\" block size=\"large\" @click=\"completeInvite\">\n {{ $t('complete') }}\n </v-btn>\n </v-form>\n </div>\n </div>\n </div>\n </section>\n</template>\n\n<script lang=\"ts\" setup>\nimport Form from 'vform';\nimport {useCompany} from '@/composables/useCompany';\nimport {computed, onBeforeMount, ref} from 'vue';\nimport {useRoute, useRouter} from 'vue-router';\nimport {useStore} from 'vuex';\n\nconst {companyLoading} = useCompany();\nconst route = useRoute();\nconst router = useRouter();\nconst store = useStore();\n\nconst form = ref(new Form({\n phone: '',\n first_name: '',\n last_name: '',\n password: '',\n agree: true,\n invite_token: '',\n}));\n\nconst employee = computed(() => store.getters['company/employee']);\nconst registerFormRules = computed(() => store.getters['company/registerFormRules']);\n\nconst fetchEmployeeByInviteToken = async (invite_token: string) => {\n await store.dispatch('company/fetchEmployeeByInviteToken', invite_token);\n};\n\nconst saveToken = async (data) => {\n await store.dispatch('auth/saveToken', data);\n};\n\nconst saveRegisterId = async (data) => {\n await store.dispatch('auth/saveRegisterId', data);\n};\n\nconst showPassword = ref(false);\n\nconst isFormValid = computed(() =>\n ['first_name', 'last_name', 'password', 'invite_token', 'phone'].every((field) => form.value[field]?.length) && form.value.agree\n);\n\nconst isButtonDisabled = computed(() => form.value.busy || !isFormValid.value);\n\n\nonBeforeMount(() => {\n form.value.invite_token = route.params.invite_token;\n fetchEmployeeByInviteToken(form.value.invite_token).then(() => {\n form.value.first_name = employee.value.first_name;\n form.value.last_name = employee.value.last_name;\n if (employee.value.phone) {\n form.value.phone = employee.value.phone;\n }\n });\n});\n\nconst completeInvite = async () => {\n try {\n const {data} = await form.value.put(`/v1/invite/${form.value.invite_token}/complete`);\n\n console.table(data);\n\n if (data.success) {\n // Log in the user.\n const {data} = await form.value.post('/v1/auth/login');\n\n // Save the token.\n await saveToken({\n token: data.access_token,\n remember: true,\n });\n\n // remove the register id.\n await saveRegisterId('');\n\n await store.dispatch('auth/fetchUser');\n\n // Redirect home.\n router.push({name: 'dashboard'}).catch(() => {\n });\n }\n } catch (e) {\n console.dir(e);\n }\n};\n</script>\n","<template>\n <section class=\"bg-gray-50 dark:bg-gray-900\">\n <div class=\"flex flex-col items-center justify-center px-6 py-8 mx-auto md:h-screen lg:py-0\">\n <a class=\"flex items-center mb-6 text-2xl font-semibold text-gray-900 dark:text-white\" href=\"/\">\n <img alt=\"logo\" class=\"w-8 h-8 mr-2\" src=\"https://tenant.fleetwire.io/images/logo/fleetwire-logo-new.png\">\n Fleetwire\n </a>\n <div class=\"w-full p-6 bg-white rounded-lg shadow dark:border md:mt-0 sm:max-w-md dark:bg-gray-800 dark:border-gray-700 sm:p-8\">\n <h1 class=\"mb-1 text-xl font-bold leading-tight tracking-tight text-gray-900 md:text-2xl dark:text-white\">\n {{ $t('forgot_password') }}\n </h1>\n <p class=\"font-light text-gray-500 dark:text-gray-400\">{{ $t('forgot_password_p') }}</p>\n <v-form v-show=\"!form.successful\" :disabled=\"form.busy\" class=\"mt-4 space-y-4 lg:mt-5 md:space-y-5\" @submit.prevent=\"send\">\n <div>\n <v-text-field\n v-model=\"form.email\"\n :autofocus=\"true\"\n :label=\"$t('email')\"\n density=\"comfortable\"\n required\n type=\"email\"\n variant=\"outlined\"\n />\n </div>\n <v-btn :disabled=\"submitButtonDisabled\" :loading=\"form.busy\" block size=\"large\" type=\"submit\">\n {{ $t('send_password_reset_link') }}\n </v-btn>\n\n <div>\n <v-alert v-if=\"errorMessage.length > 0\" density=\"compact\" role=\"alert\" type=\"error\" variant=\"outlined\">\n {{ errorMessage }}\n </v-alert>\n </div>\n </v-form>\n\n <div v-if=\"form.successful\">\n <v-alert density=\"compact\" role=\"alert\" type=\"success\" variant=\"outlined\">\n {{ $t('password_reset_link_sent') }}\n </v-alert>\n </div>\n\n <p class=\"mt-10 text-sm font-light text-gray-500 dark:text-gray-400\">\n Remember Now?\n <router-link :to=\"{ name: 'login', query: { email: form.email } }\" class=\"font-medium text-primary-600 hover:underline dark:text-primary-500\" data-testid=register-link>\n <b>{{ $t('login') }}</b>\n </router-link>\n </p>\n </div>\n </div>\n </section>\n</template>\n\n<script lang=\"ts\" setup>\nimport Form from 'vform';\nimport {computed, onBeforeMount, ref} from 'vue';\nimport {useStore} from 'vuex';\nimport {useRoute} from 'vue-router';\n\nconst {getters} = useStore();\nconst route = useRoute();\n\nconst status = ref<string>('');\nconst form = ref(new Form({\n email: '',\n}));\n\nconst errorMessage = ref('');\n\nconst submitButtonDisabled = computed(() => {\n return !form.value.email;\n});\n\nconst send = async () => {\n if (!form.value.email) {\n errorMessage.value = 'Please enter your email address.';\n return;\n }\n\n try {\n const {data} = await form.value.post('/v1/password/email');\n\n if (data.success) {\n console.dir(data);\n form.value.reset();\n }\n } catch (e) {\n console.dir(e);\n errorMessage.value = e.response?.data?.message || 'An error occurred. Please try again.';\n }\n};\n\nonBeforeMount(() => {\n if (route.query.email) {\n console.dir(route.query.email);\n form.value.email = route.query.email;\n }\n if (route.params.email) {\n console.dir(route.params.email);\n form.value.email = route.params.email;\n }\n});\n</script>\n","<template>\n <section class=\"bg-gray-50 dark:bg-gray-900\">\n <div class=\"flex flex-col items-center justify-center px-6 py-8 mx-auto md:h-screen lg:py-0\">\n <a class=\"flex items-center mb-6 text-2xl font-semibold text-gray-900 dark:text-white\" href=\"/\">\n <img alt=\"logo\" class=\"w-8 h-8 mr-2\" src=\"https://tenant.fleetwire.io/images/logo/fleetwire-logo-new.png\">\n Fleetwire\n </a>\n <div v-show=\"!formSubmitSuccess\" class=\"w-full p-6 bg-white rounded-lg shadow dark:border md:mt-0 sm:max-w-md dark:bg-gray-800 dark:border-gray-700 sm:p-8\">\n <h1 class=\"mb-1 text-xl font-bold leading-tight tracking-tight text-gray-900 md:text-2xl dark:text-white\">\n {{ $t('reset_password') }}\n </h1>\n <p class=\"font-light text-gray-500 dark:text-gray-400\">{{ $t('reset_password_p') }}</p>\n <v-form :disabled=\"form.busy\" class=\"mt-4 space-y-4 lg:mt-5 md:space-y-5\" @keydown=\"form.onKeydown($event)\" @submit.prevent=\"reset\">\n <div>\n <v-text-field\n v-model=\"form.password\"\n :append-inner-icon=\"show1 ? 'mdi-eye' : 'mdi-eye-off'\"\n :class=\"{ 'is-invalid': form.errors.has('password') }\"\n :rules=\"[registerFormRules.required, registerFormRules.min]\"\n :type=\"show1 ? 'text' : 'password'\"\n hint=\"\"\n label=\"New Password\"\n minlength=\"8\"\n variant=\"outlined\"\n @click:append-inner=\"show1 = !show1\"\n />\n </div>\n <v-btn :disabled=\"submitButtonDisabled\" :loading=\"form.busy\" block size=\"large\" type=\"submit\">\n {{ $t('reset') }}\n </v-btn>\n\n <div>\n <v-alert v-if=\"errorMessage.length > 0\" density=\"compact\" role=\"alert\" type=\"error\" variant=\"outlined\">\n {{ errorMessage }}\n </v-alert>\n </div>\n </v-form>\n\n <p class=\"mt-10 text-sm font-light text-gray-500 dark:text-gray-400\">\n Remember Now?\n <router-link :to=\"{ name: 'login', query: { email: form.email } }\" class=\"font-medium text-primary-600 hover:underline dark:text-primary-500\" data-testid=register-link>\n <b>{{ $t('login') }}</b>\n </router-link>\n </p>\n </div>\n\n <div v-show=\"formSubmitSuccess\" class=\"mt-5\">\n <v-alert density=\"compact\" role=\"alert\" type=\"success\" variant=\"outlined\">\n Password reset successfully. Redirecting to your dashboard...\n </v-alert>\n </div>\n </div>\n </section>\n</template>\n\n<script lang=\"ts\" setup>\nimport Form from 'vform';\nimport {useStore} from 'vuex';\nimport {computed, onBeforeMount, onBeforeUnmount, ref} from 'vue';\nimport {useRoute, useRouter} from 'vue-router';\n\nconst route = useRoute();\nconst router = useRouter();\nconst submitButtonDisabled = ref(false);\nconst errorMessage = ref('');\nconst show1 = ref(false);\nconst {dispatch, getters} = useStore();\nconst formSubmitSuccess = ref(false);\n\nconst registerFormRules = computed(() => getters['company/registerFormRules']);\n\nconst form = ref(new Form({\n token: '',\n email: '',\n password: '',\n password_confirmation: '',\n}));\n\nconst saveToken = async (payload) => {\n await dispatch('auth/saveToken', payload);\n};\n\n\nconst reset = async () => {\n if (!form.value.password) {\n errorMessage.value = 'Please enter your password.';\n return;\n }\n\n // wait 1 second and set formSubmitSuccess for testing\n // setTimeout(() => {\n // formSubmitSuccess.value = true;\n // }, 1000);\n\n try {\n form.value.password_confirmation = form.value.password;\n\n const {data} = await form.value.post('/v1/password/reset');\n\n formSubmitSuccess.value = true;\n\n // Save the token.\n await saveToken({\n token: data.token,\n remember: true,\n });\n\n // Fetch the user.\n await dispatch('auth/fetchUser');\n\n // Redirect home.\n router.push({name: 'dashboard'}).catch(() => {\n });\n } catch (e) {\n console.dir(e);\n }\n};\n\n\nonBeforeMount(() => {\n form.value.email = route.query.email;\n form.value.token = route.params.token;\n});\n\nonBeforeUnmount(() => {\n form.value.reset();\n});\n</script>\n","<template>\n <div>\n <div class=\" m-auto\">\n <card :title=\"$t('verify_email')\">\n <template v-if=\"success\">\n <div class=\"alert alert-success\" role=\"alert\">\n {{ success }}\n </div>\n\n <router-link :to=\"{ name: 'login' }\" class=\"btn btn-primary\">\n {{ $t('login') }}\n </router-link>\n </template>\n <template v-else>\n <div class=\"alert alert-danger\" role=\"alert\">\n {{ error || $t('failed_to_verify_email') }}\n </div>\n\n <router-link :to=\"{ name: 'verification.resend' }\" class=\"small float-right\">\n {{ $t('resend_verification_link') }}\n </router-link>\n </template>\n </card>\n </div>\n </div>\n</template>\n\n<script>\nimport axios from 'axios';\n\nconst qs = params => Object.keys(params).map(key => `${key}=${params[key]}`).join('&');\n\nexport default {\n name: 'verifyEmail',\n\n layout: 'blank',\n\n middleware: 'guest',\n\n metaInfo() {\n return { title: this.$t('verify_email') };\n },\n\n async beforeRouteEnter(to, from, next) {\n try {\n const { data } = await axios.post(`/api/v1/email/verify/${to.params.id}?${qs(to.query)}`);\n\n next((vm) => {\n vm.success = data.status;\n });\n } catch (e) {\n next((vm) => {\n vm.error = e.response.data.status;\n });\n }\n },\n\n data: () => ({\n error: '',\n success: '',\n }),\n};\n</script>\n","<template>\n <div class=\"\">\n <div class=\" m-auto\">\n <card :title=\"$t('verify_email')\">\n <form @keydown=\"form.onKeydown($event)\" @submit.prevent=\"send\">\n <alert-success :form=\"form\" :message=\"status\"/>\n\n <!-- Email -->\n <div class=\"form-group row\">\n <label class=\"col-form-label text-md-right\">{{ $t('email') }}</label>\n <div class=\"\">\n <input v-model=\"form.email\" :class=\"{ 'is-invalid': form.errors.has('email') }\" class=\"form-control\" name=\"email\" type=\"email\">\n <has-error :form=\"form\" field=\"email\"/>\n </div>\n </div>\n\n <!-- Submit Button -->\n <div class=\"form-group row\">\n <div class=\" ml-md-auto\">\n <v-button :loading=\"form.busy\" block large>\n {{ $t('send_verification_link') }}\n </v-button>\n </div>\n </div>\n </form>\n </card>\n </div>\n </div>\n</template>\n\n<script>\nimport Form from 'vform';\n\nexport default {\n name: 'ResendComponent',\n\n layout: 'blank',\n\n middleware: 'guest',\n\n metaInfo() {\n return { title: this.$t('verify_email') };\n },\n\n data: () => ({\n status: '',\n form: new Form({\n email: '',\n }),\n }),\n\n created() {\n if (this.$route.query.email) {\n this.form.email = this.$route.query.email;\n }\n },\n\n methods: {\n async send() {\n const { data } = await this.form.post('/api/v1/email/resend');\n\n this.status = data.status;\n\n this.form.reset();\n },\n },\n};\n</script>\n","export default async function guest({store}) {\n console.log('%c -- MIDDLEWARE -- GUEST ✅', 'color: white; background: green; padding: 2px; font-weight: bold;');\n\n try {\n // Retrieve authentication token from Vuex store\n const token = store.getters['auth/token'];\n const isAuthenticated = store.getters['auth/check'];\n\n console.log('%c 🔑 Auth Token:', 'color: cyan; font-weight: bold;', token);\n console.log('%c 👤 Is Authenticated?', 'color: cyan; font-weight: bold;', isAuthenticated);\n\n // Check if user is authenticated\n if (token) {\n console.warn('%c 🚪 Guest Middleware: User is logged in - Redirecting...', 'color: orange; font-weight: bold;');\n return false;\n }\n\n console.log('%c ✅ Guest Middleware: User is NOT logged in', 'color: lime; font-weight: bold;');\n return true;\n } catch (error) {\n console.error('%c ❌ Guest Middleware Error:', 'color: red; font-weight: bold;', error);\n return false; // Fallback to assuming user is logged in to prevent unintended access\n }\n}","import type {RouteRecordRaw} from 'vue-router';\nimport BaseLogin from '@/views/auth/BaseLogin.vue';\n\nimport Login from '@/views/auth/Login.vue';\nimport Register from '@/views/auth/Register.vue';\nimport RegisterNextStep from '@/views/auth/RegisterNextStep.vue';\nimport CompanyEmployeeInvite from '@/views/auth/companyEmployeeInvite.vue';\nimport PasswordRequest from '@/views/auth/password/email.vue';\nimport PasswordReset from '@/views/auth/password/reset.vue';\nimport PasswordVerify from '@/views/auth/password/verify.vue';\nimport PasswordResend from '@/views/auth/password/resend.vue';\nimport guest from \"@/middleware/guest\";\nimport {CommonRouteMeta} from \"@/types\";\n\nconst authRoutes: RouteRecordRaw = {\n path: '/',\n component: BaseLogin,\n meta: {\n title: 'home',\n icon: 'mdi-login',\n noCache: false,\n hidden: true,\n layout: 'Default',\n requiresAuth: false,\n middleware: [guest],\n } as CommonRouteMeta,\n children: [\n {\n path: 'login',\n name: 'login',\n component: Login,\n meta: {\n requiresAuth: false,\n middleware: [guest],\n }\n },\n {\n path: 'register',\n name: 'register',\n component: Register,\n },\n {\n path: '/company',\n name: 'company.next-step',\n component: RegisterNextStep,\n },\n {\n path: '/company/employees/invitation/accept/:invite_token',\n name: 'company.employee.invite',\n component: CompanyEmployeeInvite,\n },\n {\n path: '/password/reset',\n name: 'password.request',\n component: PasswordRequest,\n },\n {\n path: '/password/reset/:token',\n name: 'password.reset',\n component: PasswordReset,\n },\n {\n path: '/email/verify/:id',\n name: 'verification.verify',\n component: PasswordVerify,\n },\n {\n path: '/email/resend',\n name: 'verification.resend',\n component: PasswordResend,\n },\n ],\n};\n\nexport default authRoutes;\n","import type {RouteRecordRaw} from 'vue-router';\nimport {CommonRouteMeta} from \"@/types\";\n\nconst BaseDashboard = () => import('@/views/dashboard/BaseDashboard.vue');\n\n\nconst settingsRoutes: RouteRecordRaw[] = [\n {\n path: '/settings',\n component: BaseDashboard,\n redirect: '/settings/general',\n meta: {\n title: 'settings',\n noCache: false,\n showInMenu: true,\n icon: 'mdi-cog-outline',\n permissions: ['settings_view'],\n middleware: ['auth',],\n layout: 'Dashboard',\n } as CommonRouteMeta,\n children: [\n {\n path: 'general',\n name: 'settings.general',\n components: {\n default: () => import('@/views/dashboard/settings/General.vue'),\n },\n meta: {title: 'general', icon: 'mdi-cog', noCache: false},\n },\n {\n path: 'locations',\n name: 'settings.general.delivery',\n components: {\n default: () => import('@/components/dashboard/settings/general/DeliveryLocations.vue'),\n },\n meta: {title: 'locations', icon: 'mdi-cog', noCache: false},\n },\n {\n path: 'delivery/add',\n name: 'settings.general.delivery.add',\n components: {\n default: () => import('@/components/dashboard/settings/general/DeliveryLocationsAdd.vue'),\n },\n meta: {title: 'location add', icon: 'mdi-cog', noCache: false},\n },\n {\n path: 'delivery/:uuid',\n name: 'settings.general.delivery.edit',\n components: {\n default: () => import('@/components/dashboard/settings/general/DeliveryLocationsEdit.vue'),\n },\n meta: {title: 'location edit', icon: 'mdi-cog', noCache: false},\n },\n {\n path: 'custom-fields',\n name: 'settings.custom_fields',\n components: {\n default: () => import('@/components/dashboard/settings/general/CustomFields.vue'),\n },\n meta: {title: 'custom fields', icon: 'mdi-cog', noCache: false},\n },\n {\n path: 'localization',\n name: 'settings.general.localization',\n components: {\n default: () => import('@/components/dashboard/settings/general/Localization.vue'),\n },\n meta: {title: 'localization', icon: 'mdi-cog', noCache: false},\n },\n {\n path: 'pricing',\n name: 'settings.pricing',\n components: {\n default: () => import('@/views/dashboard/settings/Pricing/Pricing.vue'),\n },\n meta: {title: 'pricing', icon: 'mdi-cog', noCache: false},\n },\n {\n path: 'coupons',\n name: 'settings.pricing.coupons',\n components: {\n default: () => import('@/views/dashboard/settings/Pricing/Coupons.vue'),\n },\n meta: {title: 'coupons', icon: 'mdi-cog', noCache: false},\n },\n {\n path: 'pricing/advanced',\n name: 'settings.pricing.advanced',\n components: {\n default: () => import('@/views/dashboard/settings/Pricing/AdvancedPricing.vue'),\n },\n meta: {title: 'advanced pricing', icon: 'mdi-cog', noCache: false},\n },\n {\n path: 'pricing-structure',\n name: 'settings.pricing.template',\n components: {\n default: () => import('@/views/dashboard/settings/Pricing/PricingStructure/PricingTemplate.vue'),\n },\n meta: {title: 'pricing template', icon: 'mdi-cog', noCache: false},\n children: [],\n },\n {\n path: 'pricing-structure/new',\n name: 'settings.pricing.template.new',\n components: {\n default: () => import('@/views/dashboard/settings/Pricing/PricingStructure/PricingTemplateNew.vue'),\n },\n meta: {title: 'New', icon: 'mdi-cog', noCache: false},\n },\n {\n path: 'pricing-structure/:uuid/edit',\n name: 'settings.pricing.template.edit',\n components: {\n default: () => import('@/views/dashboard/settings/Pricing/PricingStructure/PricingTemplateEdit.vue'),\n },\n meta: {title: 'Edit', icon: 'mdi-cog', noCache: false},\n },\n {\n path: 'pricing/advanced/edit/:uuid',\n name: 'settings.pricing.advanced.edit',\n components: {\n default: () => import('@/views/dashboard/settings/Pricing/AdvancedPricingEdit.vue'),\n },\n meta: {title: 'advanced pricing', icon: 'mdi-cog', noCache: false},\n },\n {\n path: 'taxes',\n name: 'settings.taxes',\n components: {\n default: () => import('@/views/dashboard/settings/Taxes.vue'),\n },\n meta: {title: 'taxes', icon: 'mdi-cog', noCache: false},\n },\n {\n path: 'security-deposits',\n name: 'settings.pricing.deposits',\n components: {\n default: () => import('@/components/dashboard/settings/pricing/SecurityDeposits.vue'),\n },\n meta: {title: 'Security Deposits', icon: 'mdi-cog', noCache: false},\n },\n {\n path: 'security',\n name: 'settings.security',\n components: {\n default: () => import('@/views/dashboard/settings/Security.vue'),\n },\n meta: {title: 'Security', icon: 'mdi-cog', noCache: false},\n },\n {\n path: 'security/api-tokens',\n name: 'settings.security.api_tokens',\n components: {\n default: () => import('@/views/dashboard/settings/ApiToken.vue'),\n },\n meta: {title: 'Security', icon: 'mdi-cog', noCache: false},\n },\n {\n path: 'security/activity-log',\n name: 'settings.security.activity_log',\n components: {\n default: () => import('@/views/dashboard/settings/ActivityLog.vue'),\n },\n meta: {title: 'Security', icon: 'mdi-cog', noCache: false},\n },\n {\n path: 'account',\n name: 'settings.account',\n component: () => import('@/views/dashboard/settings/AccountAndBilling.vue'),\n meta: {title: 'Account', icon: 'mdi-cog', noCache: false},\n redirect: '/settings/account/overview',\n children: [\n {\n path: 'overview',\n name: 'settings.account.overview',\n component: () => import('@/components/dashboard/settings/account/TheOverview.vue'),\n meta: {title: 'Overview'},\n },\n {\n path: 'receipts',\n name: 'settings.account.receipts',\n component: () => import('@/components/dashboard/settings/account/TheReceipts.vue'),\n meta: {title: 'Receipts'},\n },\n {\n path: 'billing',\n name: 'settings.account.billing',\n component: () => import('@/components/dashboard/settings/account/TheBillingDetails.vue'),\n meta: {title: 'Billing Details'},\n },\n ],\n },\n {\n path: 'team',\n name: 'settings.account.team',\n components: {\n default: () => import('@/views/dashboard/settings/Team.vue'),\n },\n meta: {title: 'Account', icon: 'mdi-cog', noCache: false},\n },\n {\n path: 'notifications',\n name: 'settings.account.notifications',\n components: {\n default: () => import('@/views/dashboard/settings/CompanyNotifications.vue'),\n },\n meta: {title: 'Notifications', icon: 'mdi-cog', noCache: false},\n },\n {\n path: 'email',\n name: 'settings.account.email',\n components: {\n default: () => import('@/views/dashboard/settings/Emails/Email.vue'),\n },\n meta: {title: 'Email', icon: 'mdi-cog', noCache: false},\n },\n {\n path: 'email_template/:uuid',\n name: 'settings.account.email.email_template_single',\n components: {\n default: () => import('@/views/dashboard/settings/Emails/EmailTemplateSingle.vue'),\n },\n meta: {title: 'Email', icon: 'mdi-cog', noCache: false},\n },\n {\n path: 'account/plans/confirm',\n name: 'settings.account.plans.confirm',\n components: {\n default: () => import('@/views/dashboard/settings/Billing/SubscriptionCheckout/SubscriptionCheckout.vue'),\n },\n meta: {title: 'Plans', icon: 'mdi-cog', noCache: false},\n },\n {\n path: 'providers',\n name: 'settings.providers',\n components: {\n default: () => import('@/views/dashboard/settings/Providers.vue'),\n },\n meta: {title: 'Providers', icon: 'mdi-cog', noCache: false},\n },\n {\n path: 'payment-providers',\n name: 'settings.providers.payment-providers',\n components: {\n default: () => import('@/views/dashboard/settings/PaymentProviders.vue'),\n },\n meta: {title: 'Payment Providers', icon: 'mdi-cog', noCache: false},\n },\n {\n path: 'payment-providers/:uuid',\n name: 'settings.payment-provider.single',\n components: {\n default: () => import('@/views/dashboard/settings/PaymentProviders/SinglePaymentProvider.vue'),\n },\n meta: {title: 'Payment Provider', icon: 'mdi-cog', noCache: false},\n },\n {\n path: 'providers/commission-partners',\n name: 'settings.providers.commission_partners',\n components: {\n default: () => import('@/views/dashboard/settings/CommissionPartners.vue'),\n },\n meta: {title: 'Commission Partners', icon: 'mdi-cog', noCache: false},\n },\n {\n path: 'providers/webhooks',\n name: 'settings.providers.webhooks',\n components: {\n default: () => import('@/views/dashboard/settings/Webhooks/Webhooks.vue'),\n },\n meta: {title: 'Webhooks', icon: 'mdi-cog', noCache: false},\n },\n {\n path: 'providers/webhooks/create',\n name: 'settings.providers.webhooks.create',\n components: {\n default: () => import('@/views/dashboard/settings/Webhooks/Create.vue'),\n },\n meta: {title: 'Create Webhook', icon: 'mdi-cog', noCache: false},\n },\n {\n path: 'providers/webhooks/:uuid',\n name: 'settings.providers.webhooks.update',\n components: {\n default: () => import('@/views/dashboard/settings/Webhooks/UpdateWebhook.vue'),\n },\n meta: {title: 'Edit Webhook', icon: 'mdi-cog', noCache: false},\n },\n {\n path: 'checkout',\n name: 'settings.checkout',\n components: {\n default: () => import('@/views/dashboard/settings/Checkout.vue'),\n },\n meta: {title: 'Checkout', icon: 'mdi-cog', noCache: false},\n },\n {\n path: 'online-reservations',\n name: 'settings.checkout.online_reservations',\n components: {\n default: () => import('@/views/dashboard/settings/OnlineReservations.vue'),\n },\n meta: {title: 'Checkout', icon: 'mdi-cog', noCache: false},\n },\n {\n path: 'account/employees/new',\n name: 'settings.account.employees.new',\n components: {\n default: () => import('@/views/dashboard/settings/EmployeesNew.vue'),\n },\n meta: {title: 'Invite Team Member', icon: 'mdi-cog', noCache: false},\n },\n {\n path: 'account/employees/:e_id',\n name: 'settings.account.employees',\n components: {\n default: () => import('@/views/dashboard/settings/Employees.vue'),\n },\n meta: {title: 'Account', icon: 'mdi-cog', noCache: false},\n },\n {\n path: 'fleet',\n name: 'settings.fleet',\n components: {\n default: () => import('@/views/dashboard/settings/Fleet/FleetBase.vue'),\n },\n meta: {title: 'Account', icon: 'mdi-cog', noCache: false},\n children: [\n {\n path: 'branches',\n name: 'settings.fleet.branches',\n components: {\n default: () => import('@/views/dashboard/settings/Fleet/FleetBranches.vue'),\n },\n meta: {title: 'Branches', icon: 'mdi-cog', noCache: false},\n },\n {\n path: 'branches/new',\n name: 'settings.fleet.branches.new',\n components: {\n default: () => import('@/views/dashboard/settings/Fleet/FleetBranchesNew.vue'),\n },\n meta: {title: 'Branches', icon: 'mdi-cog', noCache: false},\n },\n {\n path: 'branches/:uuid',\n name: 'settings.fleet.branches.single',\n components: {\n default: () => import('@/views/dashboard/settings/Fleet/FleetBranchesSingle.vue'),\n },\n meta: {title: 'Branches', icon: 'mdi-cog', noCache: false},\n },\n {\n path: 'vehicle-classes',\n name: 'settings.fleet.classes',\n components: {\n default: () => import('@/views/dashboard/settings/Fleet/FleetClass.vue'),\n },\n meta: {title: 'Vehicle Classes', icon: 'mdi-cog', noCache: false},\n },\n {\n path: 'vehicle-classes/new',\n name: 'settings.fleet.classes.new',\n components: {\n default: () => import('@/views/dashboard/settings/Fleet/FleetClassNew.vue'),\n },\n meta: {title: 'New Vehicle Classe', icon: 'mdi-cog', noCache: false},\n },\n {\n path: 'vehicle-classes/:uuid',\n name: 'settings.fleet.classes.single',\n components: {\n default: () => import('@/views/dashboard/settings/Fleet/FleetClassSingle.vue'),\n },\n meta: {title: 'Vehicle Class', icon: 'mdi-cog', noCache: false},\n },\n {\n path: 'action-items',\n name: 'settings.action_items',\n components: {\n default: () => import('@/views/dashboard/settings/Fleet/ActionItems/ActionItems.vue'),\n },\n meta: {title: 'Action Items', icon: 'mdi-cog', noCache: false},\n },\n {\n path: 'action-items/new',\n name: 'settings.action_item.new',\n components: {\n default: () => import('@/views/dashboard/settings/Fleet/ActionItems/ActionItemNew.vue'),\n },\n meta: {title: 'New Action Item', icon: 'mdi-cog', noCache: false},\n }, {\n path: 'action-items/:uuid',\n name: 'settings.action_items.single',\n components: {\n default: () => import('@/views/dashboard/settings/Fleet/ActionItems/ActionItemSingle.vue'),\n },\n meta: {title: 'Action Item', icon: 'mdi-cog', noCache: false},\n },\n {\n path: 'vehicle-features',\n name: 'settings.fleet.features',\n components: {\n default: () => import('@/views/dashboard/settings/Fleet/FleetFeatures.vue'),\n },\n meta: {title: 'Vehicle Features', icon: 'mdi-cog', noCache: false},\n },\n ],\n },\n {\n path: 'affiliate',\n components: {\n default: () => import('@/views/dashboard/settings/Fleet/FleetBase.vue'),\n },\n meta: {title: 'Affiliate', icon: 'mdi-cog', noCache: false},\n children: [\n {\n path: '',\n name: 'settings.account.affiliate.index',\n components: {\n default: () => import('@/views/dashboard/settings/Affiliate/AffiliateIndex.vue'),\n },\n meta: {title: 'Affiliate', icon: 'mdi-cog', noCache: false},\n },\n {\n path: 'signup',\n name: 'settings.affiliate.signup',\n components: {\n default: () => import('@/views/dashboard/settings/Affiliate/AffiliateSignup.vue'),\n },\n meta: {title: 'Affiliate', icon: 'mdi-cog', noCache: false},\n },\n {\n path: 'payouts',\n name: 'settings.affiliate.payouts',\n components: {\n default: () => import('@/views/dashboard/settings/Affiliate/AffiliatePayouts.vue'),\n },\n meta: {title: 'Affiliate', icon: 'mdi-cog', noCache: false},\n },\n ],\n },\n {\n path: 'custodian',\n components: {\n default: () => import('@/views/dashboard/settings/Fleet/FleetBase.vue'),\n },\n meta: {title: 'Affiliate', icon: 'mdi-cog', noCache: false},\n children: [\n {\n path: '',\n name: 'settings.custodian.index',\n components: {\n default: () => import('@/views/dashboard/settings/Custodian/Index.vue'),\n },\n meta: {title: 'Custodian', icon: 'mdi-cog', noCache: false},\n },\n ],\n },\n ],\n }\n];\n\nexport default settingsRoutes;\n","import type {RouteRecordRaw} from 'vue-router';\nimport type {CommonRouteMeta} from '@/types';\n\nconst BaseDashboard = () => import('@/views/dashboard/BaseDashboard.vue');\n\nconst defaultMeta: CommonRouteMeta = {\n icon: 'mdi-handshake',\n noCache: false,\n};\n\nconst commission: RouteRecordRaw[] = [{\n path: '/commission',\n component: BaseDashboard,\n meta: {\n ...defaultMeta,\n title: 'commission',\n showInMenu: false,\n middleware: ['auth'],\n layout: 'Dashboard',\n } as CommonRouteMeta,\n children: [\n {\n path: '',\n components: {\n default: () => import('@/views/dashboard/commission/Commission.vue'),\n },\n name: 'commission',\n meta: {...defaultMeta, title: ''},\n },\n {\n path: 'partners',\n components: {\n default: () => import('@/views/dashboard/settings/CommissionPartners.vue'),\n },\n name: 'commission.partners',\n meta: {...defaultMeta, title: 'Partners'},\n },\n {\n path: 'partners/:partner_uuid',\n components: {\n default: () => import('@/views/dashboard/commission/SingleCommissionPartner.vue'),\n },\n name: 'commission.partner.single',\n meta: {...defaultMeta, title: 'Partners'},\n },\n ],\n}];\n\nexport default commission;\n","<template>\n<div class=\"justify-content-center align-items-center flex\">\n <div>\n <div class=\"text-center\">\n <div class=\"h3\">Checking Invite Code</div>\n {{ company.name }} <br>\n {{ managed_id }} <br>\n\n <v-progress-circular\n v-if=\"custodianLoading.join\"\n :size=\"50\"\n color=\"primary\"\n indeterminate\n ></v-progress-circular>\n\n <v-alert type=\"warning\" v-if=\"errorMessage\">\n {{errorMessage}}\n </v-alert>\n </div>\n </div>\n\n <v-dialog\n v-model=\"successDialog\"\n persistent\n width=\"300\"\n >\n <v-card color=\"primary\" dark>\n <v-card-text>\n Success. Please wait.\n <v-progress-linear\n indeterminate\n color=\"white\"\n class=\"mb-0\"\n ></v-progress-linear>\n </v-card-text>\n </v-card>\n </v-dialog>\n</div>\n</template>\n\n<script>\nimport { mapActions, mapGetters } from 'vuex';\nimport { EventBus } from '@/plugins/eventBus';\n\n\nexport default {\n name: 'ListingManagerConnect',\n\n data() {\n return {\n managed_id: this.$route.params.managed_id,\n errorMessage: null,\n successDialog: false,\n };\n },\n\n created() {\n EventBus.$on('custodian-join-success', () => {\n this.successRedirectDialogInit();\n });\n EventBus.$on('custodian-join-failure', (message) => {\n this.errorMessage = message;\n });\n },\n\n mounted() {\n if(this.$route.params.managed_id) {\n this.fetchCustodian(this.$route.params.managed_id);\n }\n },\n\n computed: {\n ...mapGetters({\n company: 'company/company',\n custodianLoading: 'custodian/loading',\n }),\n },\n\n methods: {\n ...mapActions({\n fetchCustodian: 'custodian/join',\n }),\n successRedirectDialogInit() {\n this.successDialog = true;\n\n // Set a timeout for 3 seconds and redirect to the listings page\n setTimeout(() => {\n this.$router.push({ name: 'listing.index' }).catch(() => {});\n }, 2000);\n },\n },\n};\n</script>\n","import type {RouteRecordRaw} from 'vue-router';\nimport ListingManagerConnect from '@/views/dashboard/manager/ListingManagerConnect.vue';\nimport {CommonRouteMeta} from \"@/types\";\n\nconst BaseDashboard = () => import('@/views/dashboard/BaseDashboard.vue');\n\n\nconst listingManagerRoutes: RouteRecordRaw = {\n path: '/custodian',\n component: BaseDashboard,\n meta: {\n title: 'custodian',\n icon: 'mdi-car-convertible',\n noCache: false,\n isBase: true,\n permissions: ['listings_view'],\n } as CommonRouteMeta,\n children: [\n {\n path: ':managed_id',\n components: {\n default: ListingManagerConnect,\n },\n name: 'listing.manager.connect',\n meta: {title: 'Single Listing', icon: 'mdi-car-convertible', noCache: false, resource: 'l_id'},\n },\n ],\n};\n\nexport default listingManagerRoutes;\n","<template>\n <v-app class=\"d-block relative\">\n <div class=\"flex flex-column h-screen\">\n <transition name=\"fade-transform\" mode=\"out-in\">\n <keep-alive>\n <slot>\n <router-view />\n </slot>\n </keep-alive>\n </transition>\n </div>\n </v-app>\n</template>\n\n<script>\nimport { mapActions, mapGetters } from 'vuex';\n\nexport default {\n name: 'TheDocumentsDashboardV2',\n\n layout: 'dashboard',\n\n middleware: 'auth',\n\n data() {\n return {\n layout: null,\n currentRole: 'adminDashboard',\n admins: [\n ['Management', 'mdi-people-outline'],\n ['Settings', 'mdi-cog'],\n ],\n cruds: [\n ['Create', 'mdi-add'],\n ['Read', 'mdi-insert_drive_file'],\n ['Update', 'mdi-update'],\n ['Delete', 'mdi-delete'],\n ],\n headers: [\n {\n text: 'Name',\n align: 'start',\n value: 'name',\n },\n { text: 'Created', value: 'created_at' },\n { text: 'Actions', value: 'actions', sortable: false },\n ],\n };\n },\n watch: {\n $route() {\n if (this.device === 'mobile' && this.secondaryNavViews.listingImportNav) {\n this.toggleSecondaryImportNav();\n }\n },\n },\n\n computed: {\n ...mapGetters({\n sidebar: 'app/sidebar',\n device: 'app/device',\n secondaryNavViews: 'app/secondaryNavViews',\n }),\n\n classObj() {\n return {\n 'sidebar-closed': !this.sidebar.opened,\n 'sidebar-opened': this.sidebar.opened,\n withoutAnimation: this.sidebar.withoutAnimation,\n mobile: this.device === 'mobile',\n 'show-import-secondary-menu': this.secondaryNavViews.listingImportNav,\n };\n },\n },\n methods: {\n ...mapActions({\n toggleSecondaryImportNav: 'app/toggleSecondaryImportNav',\n }),\n },\n\n};\n</script>\n\n<style lang=\"scss\">\n.component-fade-enter-active, .component-fade-leave-active {\n transition: opacity .3s ease;\n}\n.component-fade-enter, .component-fade-leave-to\n /* .component-fade-leave-active below version 2.1.8 */ {\n opacity: 0;\n}\n</style>\n","const irregularPlurals: Record<string, string> = {\n child: 'children',\n person: 'people',\n class: 'classes',\n tomato: 'tomatoes',\n boss: 'bosses',\n glass: 'glasses',\n mouse: 'mice',\n tooth: 'teeth',\n foot: 'feet',\n goose: 'geese',\n woman: 'women',\n man: 'men',\n cactus: 'cacti',\n focus: 'foci',\n};\n\n\nexport function pluralize(time: unknown, label: unknown): string {\n if (typeof label !== 'string' || !label.trim()) {\n return ''; // Ensure label is a valid, non-empty string\n }\n\n const cleanedLabel = label.trim();\n const lowercaseLabel = cleanedLabel.toLowerCase();\n const count = Number(time) || 0;\n\n if (count === 1) {\n return cleanedLabel; // Return singular form unchanged\n }\n\n // Determine plural form\n let plural = irregularPlurals[lowercaseLabel] || `${cleanedLabel}s`;\n\n // Preserve case formatting\n if (cleanedLabel === cleanedLabel.toUpperCase()) {\n // All uppercase (e.g., \"ITEM\" → \"ITEMS\")\n plural = plural.toUpperCase();\n } else if (cleanedLabel[0] === cleanedLabel[0].toUpperCase()) {\n // Capitalized (e.g., \"Person\" → \"People\")\n plural = plural[0].toUpperCase() + plural.slice(1);\n }\n\n return plural;\n}\n\n\nexport function upperFirst(value: unknown): string {\n if (typeof value === 'string') {\n const trimmed = value.trim(); // Ensure no leading/trailing spaces\n return trimmed.length ? trimmed.charAt(0).toUpperCase() + trimmed.slice(1) : '';\n }\n\n if (typeof value === 'number' || typeof value === 'boolean') {\n return String(value).charAt(0).toUpperCase() + String(value).slice(1);\n }\n\n return ''; // Return empty string for invalid types\n}\n\nexport function snakeCase(value: unknown): string {\n if (typeof value !== 'string') return '';\n\n return value.trim()\n .replace(/([a-z])([A-Z])/g, '$1_$2') // Insert _ between lowercase and uppercase letters\n .replace(/(\\d)([A-Za-z])/g, '$1_$2') // Ensure numbers remain with previous word\n .replace(/\\s+/g, '_') // Replace spaces with underscores\n .toLowerCase();\n}\n\nexport function truncate(value: unknown, length: number): string {\n if (typeof value !== 'string') return '';\n\n const trimmedValue = value.trim();\n if (trimmedValue.length <= length) return trimmedValue;\n\n return trimmedValue.slice(0, length) + '...';\n}","import {useStore} from 'vuex';\nimport {computed} from 'vue';\nimport {TemplateData} from '@/store/modules/document';\nimport {ESignerFieldData, ESignTool} from '@/types';\n\nexport function useTemplate() {\n const store = useStore();\n\n // 🔹 Computed Properties\n const documentTemplates = computed<TemplateData[]>(() => store.getters['document/templates']);\n const documentsLoading = computed(() => store.getters['document/loading']);\n const selectedFieldV2 = computed<ESignerFieldData>(() => store.getters['template/selectedFieldV2']);\n const template = computed<TemplateData | null>(() => store.getters['template/template']);\n const allTools = computed<ESignTool[]>(() => store.getters['template/allTools']);\n const currentWorkingTool = computed(() => store.getters['template/currentWorkingTool']);\n const documentFieldData = computed(() => store.getters['template/documentFieldData']);\n const toolsActive = computed(() => store.getters['template/toolsActive']);\n const templateDocument = computed(() => template.value?.documents);\n const documentImages = computed(() => store.getters['template/documentImages']);\n const selectedFieldIndexV2 = computed(() => store.getters['template/selectedFieldIndexV2']);\n const signerItems = computed(() => store.getters['template/signerItems']);\n\n const documentFileName = computed(() => {\n return template.value?.documents.name ?? '';\n });\n\n const templateStageData = computed<ESignerFieldData[]>(() => {\n return templateDocument.value?.data ?? [];\n })\n\n const templateDocumentImages = computed(() => {\n return templateDocument.value?.document_images ?? [];\n });\n const selectedFieldV3Coordinates = computed(() => {\n console.dir('selectedFieldV3Coordinates');\n // Check if selectedFieldV2 is defined\n if (!selectedFieldV2.value) {\n return {x: 0, y: 0};\n }\n\n const x = selectedFieldV2.value.x || 0;\n const y = selectedFieldV2.value.y || 0;\n\n return {x, y};\n });\n\n const currentSigner = computed({\n get: () => store.getters['template/currentSigner'],\n set: (signer) => store.commit('template/SET_FIELD_CURRENT_SIGNER', signer)\n });\n\n const fetchTemplates = async () => {\n return await store.dispatch('document/fetchTemplates');\n }\n\n const setDocumentImages = (images) => store.commit('template/SET_DOCUMENT_IMAGES', images);\n const setTool = (toolUsed: string) => store.commit('template/SET_CURRENT_WORKING_TOOL', toolUsed)\n const updateStageData = (payload: {\n data: ESignerFieldData,\n index: number\n }) => store.commit('template/UPDATE_DOCUMENT_TEMPLATE_DATA', payload);\n const removeAllStageData = () => store.commit('template/REMOVE_ALL_FIELDS');\n const addToStageData = (payload: ESignerFieldData) => store.commit('template/ADD_TO_DOCUMENT_TEMPLATE_DATA', payload);\n const setSingleTemplate = (template: TemplateData) => store.commit('template/SET_ONE_TEMPLATE', template);\n const deleteSelectedElementsV2 = () => store.dispatch('template/deleteSelectedElementsV2');\n const updateSelectedField = (field: ESignerFieldData) => store.commit('template/SET_SELECTED_FIELD_V2', field);\n const setToolsActive = (isActive: boolean) => store.commit('template/SET_TOOLS_ACTIVE', isActive);\n\n const toggleRightSidebar = () => {\n store.commit('template/SET_SELECTED_FIELD_V2', null);\n store.commit('template/SET_SELECTED_FIELD_INDEX_V2', 0);\n }\n\n\n const makeFieldId = (length = 8): string => {\n const characters = 'ABCDEFGHJKLMNPQRSTUVWXYZ23456789';\n return Array.from({length}, () =>\n characters.charAt(Math.floor(Math.random() * characters.length))\n ).join('');\n };\n //ESignerFieldData\n const templateStageDataGroupedByPage = computed<{ [key: number]: ESignerFieldData[] }>(() => {\n const data: ESignerFieldData[] = templateStageData.value;\n const grouped: { [key: number]: ESignerFieldData[] } = {};\n\n data.forEach((item) => {\n const page = item.page;\n if (!grouped[page]) {\n grouped[page] = [];\n }\n grouped[page].push(item);\n });\n return grouped;\n });\n\n const removeField = (field: ESignerFieldData) => {\n store.commit('template/REMOVE_FIELD', field);\n }\n const scrollToField = (field: ESignerFieldData) => {\n const documentViewer = document.querySelector('#esign-editor-main-content');\n if (documentViewer) {\n documentViewer.scrollTo({\n top: field.relativeY,\n left: 0,\n behavior: 'smooth',\n });\n }\n }\n\n\n return {\n templateStageData,\n allTools,\n template,\n documentsLoading,\n documentTemplates,\n selectedFieldV2,\n documentFieldData,\n currentWorkingTool,\n selectedFieldV3Coordinates,\n templateDocumentImages,\n documentImages,\n toolsActive,\n currentSigner,\n documentFileName,\n selectedFieldIndexV2,\n signerItems,\n templateStageDataGroupedByPage,\n removeField,\n scrollToField,\n setSingleTemplate,\n addToStageData,\n setDocumentImages,\n updateStageData,\n updateSelectedField,\n toggleRightSidebar,\n deleteSelectedElementsV2,\n setTool,\n fetchTemplates,\n makeFieldId,\n removeAllStageData,\n setToolsActive\n }\n}","import {store as defaultStore} from '@/store';\n\n/**\n * Check if user has the required permission(s)\n * @param {string[]} value - Required permissions\n * @param {any} [customStore] - Optional store (for reactivity)\n */\nexport default function checkPermission(value: string[], customStore = defaultStore): boolean {\n if (!value || !Array.isArray(value) || value.length === 0) {\n console.error('Need permissions! Example: checkPermission(\"[\\'manage permission\\',\\'edit article\\']\")');\n return false;\n }\n\n const permissions = customStore?.getters?.['auth/permissions'] as string[];\n\n if (!permissions) {\n console.warn('Permissions not found. Store might not be initialized.');\n return false;\n }\n\n return permissions.some(permission => value.includes(permission));\n}\n","import {computed} from 'vue';\nimport {RouteLocationNormalizedLoaded, useRoute, useRouter} from 'vue-router';\nimport {useStore} from 'vuex';\nimport checkPermission from '@/utils/permission';\nimport {AppCurrency} from '@/types';\n\n\nexport function useAppSettings() {\n const route: RouteLocationNormalizedLoaded = useRoute();\n const router = useRouter();\n const store = useStore();\n\n // State from store\n const roles = computed(() => store.getters['auth/roles']);\n const permissions = computed(() => store.getters['auth/permissions']);\n const setupItems = computed(() => store.getters['app/setupItems']);\n const currentCurrency = computed<AppCurrency>(() => store.getters['app/currentCurrency']);\n const polledBuildNumber = computed(() => store.getters['app/polled_build']);\n const updateAvailable = computed(() => store.getters['app/update_available']);\n const appCurrentRouteName = computed(() => route.name);\n const debugDrawerOpen = computed(() => store.getters['app/debugDrawerOpen']);\n const sidebar = computed(() => store.getters['app/sidebar']);\n const device = computed(() => store.getters['app/device']);\n const browser = computed(() => store.getters['app/browser']);\n\n const secondaryNavViews = computed(() => store.getters['app/secondaryNavViews']);\n\n // goBack\n const goBack = (numberOfRoutes: number = 1) => {\n router.go(-numberOfRoutes);\n }\n\n const isRouteMatch = (routeName: string, condition: () => boolean = () => true): boolean => {\n // Ensure that route.name is a string before calling string methods on it\n if (typeof route.name === 'string') {\n return route.name.startsWith(routeName) && condition();\n }\n return false;\n };\n\n function shouldSubMenuOpen(pageName: string) {\n const conditions: { [key: string]: () => boolean } = {\n 'customers': () => typeof route.name === 'string' && !route.name.includes('customers.import') && !route.name.includes('customers.single'),\n 'orders': () => typeof route.name === 'string' && route.name.startsWith('orders.index'),\n 'documents': () => typeof route.name === 'string' && route.name.startsWith('documents.index'),\n };\n\n const condition = conditions[pageName] || (() => true);\n\n return {\n MainNavigation__open: isRouteMatch(pageName, condition)\n };\n }\n\n function userHasRole(role: string): boolean {\n return roles.value.includes(role);\n }\n\n const fetchBuildNumber = async () => {\n return await store.dispatch('app/fetchBuildNumber');\n }\n\n const toggleSideBar = () => {\n store.dispatch('app/toggleSideBar');\n };\n\n function userHasPermission(permissions: string[]): boolean {\n return checkPermission(permissions);\n }\n\n const updateSettings = async (settings: { settings: { [key: string]: any } }) => {\n return await store.dispatch('settings/updateSettings', settings);\n }\n\n const fetchCurrency = async (currency: string) => {\n return await store.dispatch('app/fetchCurrency', currency);\n }\n\n const getSettings = async () => {\n return await store.dispatch('settings/getSettings');\n }\n\n function toggleDebugDrawer() {\n store.dispatch('app/toggleDebugDrawer');\n }\n\n const appCurrencies: AppCurrency[] = [\n {name: 'British Pound Sterling', code: 'GBP', symbol: '£'},\n {name: 'Canadian Dollar', code: 'CAD', symbol: '$'},\n {name: 'Euro', code: 'EUR', symbol: '€'},\n {name: 'Japanese Yen', code: 'JPY', symbol: '¥'},\n {name: 'Mexican Peso', code: 'MXN', symbol: '$'},\n {name: 'South Korean Won', code: 'KRW', symbol: '₩'},\n {name: 'Turkish Lira', code: 'TRY', symbol: '₺'},\n {name: 'US Dollar', code: 'USD', symbol: '$'},\n ] as AppCurrency[]\n\n return {\n setupItems,\n debugDrawerOpen,\n appCurrencies,\n currentCurrency,\n roles,\n permissions,\n appCurrentRouteName,\n polledBuildNumber,\n updateAvailable,\n sidebar,\n device,\n browser,\n secondaryNavViews,\n goBack,\n fetchBuildNumber,\n updateSettings,\n getSettings,\n userHasRole,\n userHasPermission,\n shouldSubMenuOpen,\n toggleDebugDrawer,\n fetchCurrency,\n toggleSideBar,\n }\n}","<template>\n <div class=\"right-bar2 overflow-x-hidden\">\n <div class=\"bg-gray-700 flex items-center justify-between w-full px-3 py-3\">\n <div class=\"flex-grow\"></div>\n <v-btn class=\"right-bar-toggle\" size=\"x-small\" theme=\"dark\" @click=\"toggleRightSidebar();\">\n <v-icon color=\"white\" size=\"small\">mdi-close</v-icon>\n </v-btn>\n </div>\n\n <div class=\"rightbar-content h-100\">\n <div>\n\n <!-- Edit Field -->\n <div>\n <div>\n <v-card class=\"edit-field-card\" flat>\n <v-card-title>\n <div v-if=\"selectedFieldType === 'text'\">\n <v-icon class=\"mr-2\">mdi-format-text</v-icon>\n Text\n </div>\n <div v-if=\"selectedFieldType === 'checkbox'\">\n <v-icon class=\"mr-2\">mdi-checkbox-marked-outline</v-icon>\n Checkbox\n </div>\n <div v-if=\"selectedFieldType === 'signature'\">\n <v-icon class=\"mr-2\">mdi-signature</v-icon>\n Signature\n </div>\n <div v-if=\"selectedFieldType === 'attachment'\">\n <v-icon class=\"mr-2\">mdi-attachment</v-icon>\n Attachment\n </div>\n <div v-if=\"selectedFieldTitle === 'Name'\">\n <v-icon class=\"mr-2\">mdi-format-text</v-icon>\n Name\n </div>\n <div v-if=\"selectedFieldType === 'field'\">\n <span v-if=\"selectedFieldV2.customField\"><v-icon class=\"mr-2\">mdi-creation</v-icon>Custom Field</span>\n <span v-else><v-icon class=\"mr-2\">mdi-creation</v-icon> Field</span>\n </div>\n </v-card-title>\n <v-divider/>\n <v-card-text>\n <div v-if=\"selectedFieldV2?.primary_customer\" class=\"p-1\">\n <v-icon :color=\"'#5be8ff'\" class=\"mr-1\" size=\"small\">mdi-account-circle</v-icon>\n Primary Signer\n </div>\n <div v-if=\"selectedFieldV2?.secondary_customer\" class=\"p-1\">\n <v-icon :color=\"'purple'\" class=\"mr-1\" size=\"small\">mdi-account-circle</v-icon>\n Secondary Signer\n </div>\n <p v-if=\"toolDescription(selectedFieldV2)\" class=\"p-1 overflow-auto\" style=\"max-height: 100px;\">\n <span class=\"h6 font-bold\">Description:</span>\n {{ toolDescription(selectedFieldV2) }}\n </p>\n <p v-if=\"selectedFieldV2?.typeId === 'field-booking-deposit'\" class=\"p-2\">\n <v-icon size=\"x-small\">mdi-help-circle-outline</v-icon>\n Depending on if they pay with a debit or credit this field will fill in the respective amount you\n chose for the listing.\n </p>\n <div class=\"px-2\">\n <div class=\"flex align-center\" style=\"height: 60px;\">\n <div class=\"flex-grow\">\n Required Field\n <v-icon v-tippy class=\"mb-1\" content=\"Requires users to enter data into the field before submitting.\" size=\"x-small\">\n mdi-help-circle-outline\n </v-icon>\n </div>\n <div>\n <v-switch\n v-model=\"selectedElementAttributesRequiredField\"\n density=\"compact\"\n hide-details\n />\n </div>\n </div>\n <div v-if=\"allowsReadOnly\" class=\"flex align-center\" style=\"height: 60px;\">\n <div class=\"flex-grow\">\n Read Only\n <v-icon v-tippy class=\"mb-1\" content=\"This field will be read only and can't be changed\" size=\"x-small\">\n mdi-help-circle-outline\n </v-icon>\n </div>\n <div>\n <v-switch\n v-model=\"selectedElementAttributesReadOnlyField\"\n density=\"compact\"\n hide-details\n />\n </div>\n </div>\n\n <div v-if=\"selectedFieldType === 'checkbox'\">\n <div class=\"flex align-center\" style=\"height: 60px;\">\n <div class=\"flex-grow\">\n Select By Default\n <v-icon v-tippy class=\"mb-1\" content=\"This field will be checked by default\" size=\"x-small\">\n mdi-help-circle-outline\n </v-icon>\n </div>\n <div class=\"h-100\">\n <v-switch\n v-model=\"selectedFieldV2.value\"\n density=\"compact\"\n hide-details\n />\n </div>\n </div>\n <v-text-field\n v-model=\"selectedFieldV2.fieldName\"\n density=\"compact\"\n label=\"Field Name *\"\n required\n variant=\"outlined\"\n />\n </div>\n </div>\n\n <div v-if=\"selectedFieldV2\" class=\"mt-5\">\n <v-expansion-panels multiple variant=\"accordion\">\n <v-expansion-panel v-if=\"selectedFieldType === 'text'\">\n <v-expansion-panel-title>Add Text</v-expansion-panel-title>\n <v-expansion-panel-text>\n <v-text-field\n v-model=\"selectedFieldV2.text\"\n label=\"Text\"\n variant=\"outlined\"\n ></v-text-field>\n </v-expansion-panel-text>\n </v-expansion-panel>\n <v-expansion-panel>\n <v-expansion-panel-title>Position</v-expansion-panel-title>\n <v-expansion-panel-text>\n <v-text-field\n v-model=\"selectedFieldV2.x\"\n label=\"X\"\n type=\"number\"\n variant=\"outlined\"\n ></v-text-field>\n <v-text-field\n v-model=\"selectedFieldV2.y\"\n label=\"Y\"\n type=\"number\"\n variant=\"outlined\"\n ></v-text-field>\n </v-expansion-panel-text>\n </v-expansion-panel>\n <v-expansion-panel v-if=\"selectedFieldType !== 'checkbox'\">\n <v-expansion-panel-title>Formatting</v-expansion-panel-title>\n <v-expansion-panel-text>\n <v-text-field\n v-model=\"selectedFieldV2.fontSize\"\n label=\"Font Size\"\n type=\"number\"\n variant=\"outlined\"\n ></v-text-field>\n\n <v-btn-toggle v-model=\"selectedFieldV2.textAlign\">\n <v-btn size=\"small\" value=\"left\">\n <v-icon size=\"small\">mdi-format-align-left</v-icon>\n </v-btn>\n <v-btn size=\"small\" value=\"center\">\n <v-icon size=\"small\">mdi-format-align-center</v-icon>\n </v-btn>\n <v-btn size=\"small\" value=\"right\">\n <v-icon size=\"small\">mdi-format-align-right</v-icon>\n </v-btn>\n </v-btn-toggle>\n </v-expansion-panel-text>\n </v-expansion-panel>\n <v-expansion-panel>\n <v-expansion-panel-title>ToolTip</v-expansion-panel-title>\n <v-expansion-panel-text>\n <v-text-field\n v-model=\"selectedFieldV2.toolTip\"\n label=\"Tool Tip\"\n variant=\"outlined\"\n ></v-text-field>\n </v-expansion-panel-text>\n </v-expansion-panel>\n <!-- <v-expansion-panel>-->\n <!-- <v-expansion-panel-title>Advanced</v-expansion-panel-title>-->\n <!-- <v-expansion-panel-text>-->\n <!-- <div style=\"height: 60px;\" class=\"flex align-center\">-->\n <!-- <div class=\"flex-grow\">-->\n <!-- Conditional-->\n <!-- <v-icon x-small class=\"mb-1\" v-tippy content=\"Hide this field until other fields are filled out\">mdi-help-circle-outline</v-icon>-->\n <!-- </div>-->\n <!-- <div class=\"h-100\">-->\n <!-- <v-switch-->\n <!-- dense-->\n <!-- v-model=\"selectedFieldV2?.conditional\"-->\n <!-- inset-->\n <!-- hide-details-->\n <!-- @click=\"setupConditionalField()\"-->\n <!-- ></v-switch>-->\n <!-- </div>-->\n <!-- </div>-->\n <!-- <v-btn-->\n <!-- v-if=\"selectedFieldV2?.conditional\"-->\n <!-- x-small-->\n <!-- block-->\n <!-- @click=\"conditionalRulesDialog = true\"-->\n <!-- >-->\n <!-- Edit Conditions-->\n <!-- </v-btn>-->\n <!-- </v-expansion-panel-text>-->\n <!-- </v-expansion-panel>-->\n </v-expansion-panels>\n </div>\n <div v-if=\"false\" class=\"mt-2 p-1\">\n <v-select\n v-model=\"customer\"\n :items=\"['primary', 'secondary']\"\n density=\"compact\"\n label=\"Customer\"\n variant=\"outlined\"\n >\n <template v-slot:item=\"{ item }\">\n <v-icon v-if=\"item.value === 'primary'\" color=\"#5be8ff\">mdi-circle-small</v-icon>\n <v-icon v-if=\"item.value === 'secondary'\" color=\"#975bff\">mdi-circle-small</v-icon>\n {{ upperFirst(item.value) }}\n </template>\n </v-select>\n </div>\n </v-card-text>\n\n <v-card-actions>\n <v-spacer/>\n <delete-button\n :isDisabled=\"fieldIsDependant(selectedFieldV2)\"\n @delete-confirmed=\"$emit('update:esignFieldDeleted');\"\n />\n </v-card-actions>\n </v-card>\n\n <v-card-text>\n <div v-if=\"selectedFieldV2?.x\" class=\"flex flex-col text-muted text-xs\">\n <div class=\"flex\">\n <span class=\"flex-grow\">X POS:</span> {{ selectedFieldV2?.x }}\n </div>\n <div class=\"flex\">\n <span class=\"flex-grow\">Y POS:</span> {{ selectedFieldV2?.y }}\n </div>\n <div class=\"flex\">\n <span class=\"flex-grow\">Width:</span> {{ selectedFieldV2?.w }}\n </div>\n <div class=\"flex\">\n <span class=\"flex-grow\">Field ID:</span> {{ selectedFieldV2?.id }}\n </div>\n </div>\n </v-card-text>\n <pre v-if=\"debugDrawerOpen\" class=\"text-xs\">\n {{ selectedFieldV2 }}\n </pre>\n </div>\n </div>\n\n </div>\n </div>\n <v-dialog v-model=\"conditionalRulesDialog\" width=\"420\">\n <v-card>\n <v-card-title>\n Rules for {{ selectedFieldTitle }}\n </v-card-title>\n\n <v-card-text>\n <div>Reveal this field when...</div>\n <div>\n <v-select\n v-model=\"conditionalRules.when\"\n :disabled=\"conditionalRules.rules.length <= 1\"\n :items=\"possibleWhens\"\n density=\"compact\"\n item-title=\"text\"\n item-value=\"value\"\n variant=\"outlined\"\n >\n </v-select>\n </div>\n <div>\n <div v-for=\"(rule, index) in conditionalRules.rules\" :key=\"index\" class=\"mb-1\">\n <div class=\"flex p-1 border rounded\">\n <div class=\"flex-grow\">\n <v-select\n v-model=\"rule.field\"\n :items=\"availableFields\"\n class=\"mt-1\"\n density=\"compact\"\n hide-details\n item-title=\"text\"\n item-value=\"value\"\n label=\"Field\"\n variant=\"outlined\"\n >\n <template v-slot:selection=\"{ item }\">\n <v-icon :color=\"item.color\" class=\"mr-1\" size=\"small\">mdi-account-circle</v-icon>\n <div class=\"flex\">\n <div class=\"flex-grow\">\n {{ item.text }}\n <span v-if=\"item.fieldName\" class=\"small\">({{ item.fieldName }})</span>\n </div>\n <div v-if=\"item.primary\">Primary</div>\n <div v-if=\"item.secondary\">Secondary</div>\n </div>\n </template>\n <template v-slot:item=\"{ item }\">\n <v-icon :color=\"item.color\" class=\"mr-1\" size=\"small\">mdi-account-circle</v-icon>\n <div class=\"flex\">\n <div class=\"flex-grow\">\n {{ item.text }}\n <span v-if=\"item.fieldName\" class=\"small\">({{ item.fieldName }})</span>\n </div>\n <div v-if=\"item.primary\">Primary</div>\n <div v-if=\"item.secondary\">Secondary</div>\n </div>\n </template>\n </v-select>\n <v-select\n v-model=\"rule.value\"\n :items=\"getActionItems(rule)\"\n class=\"mt-2\"\n density=\"compact\"\n hide-details\n item-title=\"text\"\n item-value=\"value\"\n label=\"Action\"\n variant=\"outlined\"\n >\n </v-select>\n </div>\n <div class=\"px-1\">\n <v-btn\n v-if=\"index !== 0\"\n rounded\n size=\"x-small\"\n variant=\"flat\"\n @click=\"conditionalRules.rules.splice(index, 1)\"\n >\n <v-icon size=\"x-small\">mdi-delete</v-icon>\n </v-btn>\n\n <delete-button\n @delete-confirmed=\"conditionalRules.rules.splice(index, 1)\"\n />\n </div>\n </div>\n <div\n v-if=\"conditionalRules.rules.length > 1 && conditionalRules.rules.length !== index + 1\"\n class=\"flex justify-content-center\"\n >\n <span v-if=\"conditionalRules.when === 'any'\">Or</span>\n <span v-if=\"conditionalRules.when === 'all'\">And</span>\n <span v-if=\"conditionalRules.when === 'none'\">Not And</span>\n </div>\n </div>\n <div class=\"mt-2\">\n <v-btn block size=\"small\" variant=\"text\" @click=\"addConditionToRuleset()\">\n <v-icon>mdi-plus</v-icon>\n </v-btn>\n </div>\n </div>\n </v-card-text>\n\n <v-card-actions>\n <v-spacer/>\n <v-btn @click=\"setConditionalRules()\">Okay</v-btn>\n </v-card-actions>\n </v-card>\n </v-dialog>\n </div>\n</template>\n\n<script lang=\"ts\">\nimport {computed, defineAsyncComponent, ref, watch} from 'vue';\nimport {upperFirst} from '@/utils/text';\nimport {useTemplate} from '@/composables/useTemplate';\nimport {useAppSettings} from '@/composables/useAppSettings';\nimport {ESignerFieldData} from '@/types';\n\nconst DeleteButton = defineAsyncComponent(() => import('@/components/buttons/DeleteButton.vue'));\n\nexport default {\n name: 'TheTemplateRightSidebar',\n components: {DeleteButton},\n\n emits: ['update:esignFieldDeleted'],\n\n setup() {\n const {\n allTools,\n selectedFieldV2,\n templateStageData,\n toggleRightSidebar,\n setTool,\n deleteSelectedElementsV2\n } = useTemplate();\n const {debugDrawerOpen} = useAppSettings();\n const currentTool = ref('');\n const customer = ref('');\n const conditionalRulesDialog = ref(false);\n const conditionalRules = ref({\n when: 'any',\n rules: [\n {\n field: '',\n operator: '',\n value: '',\n },\n ],\n });\n const possibleWhens = ref([\n {\n text: 'Any of the following',\n value: 'any',\n },\n {\n text: 'All of the following',\n value: 'all',\n },\n {\n text: 'None of the following',\n value: 'none',\n },\n ]);\n\n const possibleRules = ref({\n field: [\n {\n value: 'filled',\n text: 'is filed in',\n },\n {\n value: 'not_filled',\n text: 'is not filed in',\n },\n ],\n checkbox: [\n {\n value: 'filled',\n text: 'is checked',\n },\n {\n value: 'not_filled',\n text: 'is not check',\n },\n ],\n });\n\n const conditionalRulesRules = computed(() => {\n return conditionalRules.value.rules;\n });\n\n watch(currentTool, (tool) => {\n if (tool) {\n const toolUsed = allTools.value.find((t) => t.value === currentTool.value);\n console.dir('toolUsed');\n console.dir(toolUsed);\n if (toolUsed) {\n setTool(toolUsed);\n }\n }\n });\n\n watch(selectedFieldV2, (field) => {\n if (field) {\n if (field.conditional_rules) {\n conditionalRules.value = field.conditional_rules;\n } else {\n conditionalRules.value = {\n when: 'any',\n rules: [\n {\n field: '',\n operator: '',\n value: '',\n },\n ],\n };\n }\n }\n });\n\n\n watch(conditionalRulesRules, (rules) => {\n if (rules.length <= 1) {\n conditionalRules.value.when = 'any';\n }\n });\n\n const selectedFieldType = computed(() => selectedFieldV2?.value?.type);\n const selectedFieldTitle = computed(() => selectedFieldV2?.value?.title);\n\n\n const allFieldsWithRules = computed(() => {\n return templateStageData.value.filter((field: ESignerFieldData) => field?.conditional_rules?.rules?.length > 0);\n });\n\n const dependentFields = computed(() => {\n const fieldIds = [];\n allFieldsWithRules.value.forEach((field) => {\n field.conditional_rules.rules.forEach((rule) => {\n if (rule.value && !fieldIds.includes(rule.value)) {\n fieldIds.push(rule.value);\n }\n });\n });\n return fieldIds;\n });\n\n const setupConditionalField = () => {\n if (selectedFieldV2.value?.conditional) {\n conditionalRulesDialog.value = true;\n } else {\n delete selectedFieldV2.value?.conditional_rules;\n }\n };\n\n const getActionItems = (rule) => {\n const field = templateStageData.value.find((field) => field.id === rule.field);\n if (!field) return [];\n\n return possibleRules.value[field.type] || [];\n };\n\n const setConditionalRules = () => {\n conditionalRulesDialog.value = false;\n selectedFieldV2.value.conditional_rules = conditionalRules.value;\n };\n\n const addConditionToRuleset = () => {\n console.dir('addConditionToRuleset');\n conditionalRules.value.rules.push({\n field: '',\n operator: '',\n value: '',\n });\n };\n\n const fieldIsDependant = (field) => {\n return dependentFields.value && dependentFields.value.includes(field?.id);\n };\n\n const toolDescription = (tool) => {\n const findTool = allTools.value.find((t) => t.id === tool?.typeId);\n return findTool?.description;\n };\n\n const allFieldsOrdered = computed(() => {\n const fields = templateStageData.value.map((field) => ({\n text: field.title,\n value: field.id,\n type: field.type,\n fieldName: field.fieldName,\n primary: !!field.primary_customer,\n secondary: !!field.secondary_customer,\n }));\n\n return fields.sort((a, b) => {\n if (a.primary && !b.primary) {\n return -1;\n }\n if (!a.primary && b.primary) {\n return 1;\n }\n if (a.secondary && !b.secondary) {\n return -1;\n }\n if (!a.secondary && b.secondary) {\n return 1;\n }\n if (a.text < b.text) {\n return -1;\n }\n if (a.text > b.text) {\n return 1;\n }\n return 0;\n });\n });\n\n const availableFields = computed(() => {\n return allFieldsOrdered.value?.filter((field) => {\n if (selectedFieldV2.value) {\n return field.value !== selectedFieldV2.value.id;\n }\n return true;\n });\n });\n\n const allowsReadOnly = computed(() => {\n return selectedFieldV2.value?.typeId === 'field-free-text'\n || selectedFieldV2.value?.typeId === 'field-primary-free-text'\n || selectedFieldV2.value?.typeId === 'field-secondary-free-text'\n || selectedFieldV2.value?.customField;\n });\n\n const selectedElementAttributesRequiredField = computed({\n get() {\n return selectedFieldV2.value?.required || false;\n },\n set(value) {\n console.dir(selectedFieldV2.value);\n selectedFieldV2.value.required = value;\n },\n });\n\n const selectedElementAttributesReadOnlyField = computed({\n get() {\n return selectedFieldV2.value?.readOnly || false;\n },\n set(value) {\n console.dir('set value');\n selectedFieldV2.value.readOnly = value;\n },\n });\n\n\n return {\n upperFirst,\n deleteSelectedElementsV2,\n setupConditionalField,\n getActionItems,\n setConditionalRules,\n addConditionToRuleset,\n fieldIsDependant,\n toolDescription,\n toggleRightSidebar,\n allowsReadOnly,\n selectedElementAttributesRequiredField,\n selectedElementAttributesReadOnlyField,\n allFieldsOrdered,\n dependentFields,\n availableFields,\n selectedFieldTitle,\n selectedFieldType,\n allFieldsWithRules,\n templateStageData,\n selectedFieldV2,\n debugDrawerOpen,\n allTools,\n currentTool,\n customer,\n conditionalRulesDialog,\n conditionalRules,\n possibleWhens,\n possibleRules,\n };\n },\n\n};\n</script>\n\n<style lang=\"scss\">\n.edit-field-card.theme--light.v-card {\n background-color: #efefef;\n border: none;\n}\n\n.edit-field-card .v-card__text {\n padding: 0 !important;\n}\n\n.right-bar2 {\n background-color: #efefef;\n -webkit-box-shadow: 0 0 24px 0 rgba(50, 58, 70, .1), 0 1px 0 0 rgba(50, 58, 70, .08);\n box-shadow: 0 0 24px 0 rgba(50, 58, 70, .1), 0 1px 0 0 rgba(50, 58, 70, .08);\n display: block;\n position: fixed;\n -webkit-transition: all .2s ease-out;\n transition: all .2s ease-out;\n width: 220px;\n z-index: 9999;\n float: right !important;\n right: -220px;\n top: 0;\n bottom: 0;\n padding-bottom: 80px;\n overflow: auto;\n}\n\n.esign-right-bar-enabled .right-bar2 {\n right: 0;\n}\n\n.right-bar2 .rightbar-title {\n background-color: #313a46;\n padding: 27px 25px;\n color: #fff !important;\n}\n\n.right-bar2 .rightbar-title h5 {\n color: #fff !important;\n}\n\n.right-bar2 .right-bar-toggle {\n //background-color: #444e5a;\n //height: 24px;\n //width: 24px;\n //line-height: 22px;\n //color: #fff;\n //text-align: center;\n //border-radius: 50%;\n //margin-top: -4px;\n}\n</style>\n","<template>\n <div id=\"content_sidebar-left\" class=\"content_sidebar content_sidebar-left overflow-x-hidden\">\n <v-scroll-x-transition hide-on-leave>\n <div v-if=\"showFieldSearch\" class=\"sidebar_footer\">\n <div class=\"form_item-iconLeft form_item-iconRight\">\n <v-text-field v-model=\"searchTool\" append-icon=\"mdi-close\" class=\"input-text mx-1 px-1\" density=\"compact\" placeholder=\"Search Tools\" prepend-inner-icon=\"mdi-magnify\" type=\"text\" @click:append=\"searchTool = ''; showFieldSearch = false;\"></v-text-field>\n </div>\n </div>\n </v-scroll-x-transition>\n <div class=\"\">\n <v-btn :class=\"{'left-sidebar-group-active' : leftSidebarView === 1}\" class=\"left-sidebar-group\" size=\"small\" variant=\"text\" @click=\"leftSidebarView = 1\">\n <v-icon size=\"small\">mdi-format-textbox</v-icon>\n </v-btn>\n <v-btn :class=\"{'left-sidebar-group-active' : leftSidebarView === 2}\" class=\"left-sidebar-group\" size=\"small\" variant=\"text\" @click=\"leftSidebarView = 2\">\n <v-icon size=\"small\">mdi-cogs</v-icon>\n </v-btn>\n <v-btn class=\"left-sidebar-group\" size=\"small\" variant=\"text\" @click=\"showFieldSearch = !showFieldSearch\">\n <v-icon size=\"small\">mdi-magnify</v-icon>\n </v-btn>\n </div>\n <div class=\"w-100 overflow-auto bg-gray-100\">\n <div class=\"h-100 flex\">\n <div class=\"w-100 mx-2 overflow-x-hidden\">\n <div v-if=\"leftSidebarView === 1\">\n <div class=\"mx-3 my-2 l-flex-between border-b\">\n <span>Fields <v-btn href=\"https://help.fleetwire.io/en/article/esign-fields-q9oeuf/\" size=\"small\" target=\"_blank\" variant=\"text\"><v-icon size=\"x-small\">mdi-help-circle-outline</v-icon></v-btn></span>\n </div>\n <div class=\"mb-5\">\n <v-select\n v-model=\"currentSigner\"\n :items=\"signerItems\"\n density=\"compact\"\n item-title=\"title\"\n item-value=\"value\"\n label=\"Signer\"\n variant=\"outlined\"\n >\n <template v-slot:selection=\"{ item }\">\n <v-icon :color=\"item.raw.color\" class=\"mr-1\" size=\"small\">mdi-account-circle</v-icon>\n <span>{{ item.title }}</span>\n </template>\n <template v-slot:item=\"{ props, item }\">\n <v-list-item :subtitle=\"item.raw.title\" v-bind=\"props\">\n <template v-slot:prepend>\n <v-icon :color=\"item.raw.color\" icon=\"mdi-account-circle\" size=\"small\"></v-icon>\n </template>\n\n </v-list-item>\n </template>\n </v-select>\n <div v-for=\"(category, key) in categorizedTools\" :key=\"key\">\n <span class=\"block my-2 underline\">{{ key }}</span>\n <v-btn v-for=\"(tool, toolKey) in category\" :key=\"toolKey\" v-tippy :content=\"tool.name\" block class=\"mb-2 justify-left\" size=\"small\" variant=\"outlined\" @click=\"$emit('addField', tool.id)\">\n <v-icon v-if=\"tool.icon\" class=\"mr-2\" size=\"small\">{{ tool.icon }}</v-icon>\n {{ truncateFieldName(tool.name) }}\n </v-btn>\n </div>\n\n <div v-if=\"!categorizedTools['Custom Fields']\">\n <span class=\"block my-2 underline\">Custom Fields</span>\n <small>Want to create a custom field?\n <router-link :to=\"{name: 'settings.custom_fields'}\">Configure Fields</router-link>\n </small>\n </div>\n </div>\n </div>\n <div v-if=\"leftSidebarView === 2\">\n <div class=\"l-flex-between border-b mx-3 my-2\">\n <span>Settings</span>\n </div>\n <div class=\"mb-5\">\n <v-btn v-tippy :disabled=\"templateStageData.length <= 0\" block class=\"mb-2\" content=\"Remove all fields on template (reset)\" variant=\"outlined\" @click=\"$emit('clear-all-fields')\">\n <v-icon class=\"mr-2\" size=\"small\">mdi-delete</v-icon>\n All Fields\n </v-btn>\n <div class=\"mt-5 muted\">\n <span>Field Count:</span> {{ templateStageData.length }}\n </div>\n <div>\n\n <v-expansion-panels class=\"mb-6\">\n <v-expansion-panel>\n <v-expansion-panel-title>\n Place holders.\n </v-expansion-panel-title>\n <v-expansion-panel-text>\n <div v-for=\"(pageFields, index) in templateStageDataGroupedByPage\" :key=\"index\" class=\"border my-1\">\n <div class=\"text-h6\">Page: {{ index }}</div>\n <div v-for=\"field in pageFields\" :key=\"field?.id\" :class=\"pageFieldsOverviewClassObject(field)\" class=\"border rounded m-1 px-1 small relative cursor-pointer\" @click=\"scrollToField(field)\">\n <div class=\"small font-bold \">{{ field.text }}</div>\n {{ field?.id }} <br>\n x:{{ field.x }} <br>\n y:{{ field.y }}\n <div class=\"absolute right-0 top-1/2\">\n <v-btn size=\"x-small\" variant=\"text\" @click.stop=\"removeField(field)\">\n <v-icon size=\"x-small\">mdi-delete</v-icon>\n </v-btn>\n </div>\n </div>\n </div>\n </v-expansion-panel-text>\n </v-expansion-panel>\n </v-expansion-panels>\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n</template>\n\n<script lang=\"ts\" setup>\nimport {computed, ref} from 'vue';\nimport {useCompany} from '@/composables/useCompany';\nimport {useTemplate} from '@/composables/useTemplate';\nimport {ESignerFieldData, ESignTool} from '@/types';\nimport {truncate} from '@/utils/text';\n\nconst {company} = useCompany();\nconst {\n currentSigner,\n allTools,\n selectedFieldV2,\n signerItems,\n templateStageData,\n templateStageDataGroupedByPage,\n removeField,\n scrollToField,\n} = useTemplate();\n\nconst showFieldSearch = ref(false);\nconst leftSidebarView = ref(1);\nconst searchTool = ref('');\n\nconst currentSignerTools = computed(() => {\n const tools = allTools.value.filter((t: ESignTool) => !t.disabled);\n\n if (currentSigner.value === 'primary') {\n return tools.filter((t) => t.primary || !t.secondary);\n }\n return tools.filter((t) => t.secondary || !t.primary);\n});\n\nconst filteredTools = computed(() => {\n let tools = currentSignerTools.value;\n\n const companyDefaultProperties = company.value?.default_properties || [];\n\n const defaultProperties = companyDefaultProperties.map((dp) => {\n const width = (dp.name.length * 9) + 10;\n const signer = currentSigner.value === 'primary' ? 'primary' : 'secondary';\n const data = {\n id: `custom-field-${dp.uuid}`,\n name: dp.name,\n type: 'field',\n category: 'Custom Fields',\n icon: 'mdi-focus-field-horizontal',\n customField: true,\n w: width,\n h: 20,\n };\n data[`${signer}_customer`] = true;\n return data;\n });\n\n tools = tools.filter((t) => t.name.toLowerCase().includes(searchTool.value.toLowerCase()));\n\n tools = tools.concat(defaultProperties);\n return tools;\n});\n\n\nconst categorizedTools = computed(() => {\n return filteredTools.value.reduce((acc, tool) => {\n const category = tool.category || 'Uncategorized';\n if (!acc[category]) {\n acc[category] = [];\n }\n acc[category].push(tool);\n return acc;\n }, {});\n})\n\nconst truncateFieldName = (name: string) => {\n return truncate(name, 25);\n};\n\nconst pageFieldsOverviewClassObject = (field: ESignerFieldData) => {\n const hasError = field.x < 0 || field.y < 0 || field.w < 0 || field.h < 0;\n return {\n 'bg-yellow-100': field?.id === selectedFieldV2.value?.id,\n 'field-error': hasError,\n };\n};\n</script>\n\n<style>\n.page-fields-overview .v-expansion-panel-text__wrap {\n padding: 0 5px !important;\n}\n\n.site-editor .content_sidebar-left {\n background: #e9e9e9;\n}\n\n.site-editor .content_sidebar-left {\n border-right: 1px solid #ec0606;\n position: relative;\n width: 240px;\n}\n\n.page-fields-overview .field-error {\n border: 1px solid #ec0606 !important;\n}\n\n.content_sidebar-left {\n border-right: 1px solid transparent;\n max-width: 375px;\n min-width: 220px;\n overflow: visible;\n position: relative;\n}\n\n.content_sidebar-left {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -ms-flex-direction: column;\n flex-direction: column;\n}\n</style>\n","<template>\n <div id=\"site_toolbar\">\n <div class=\"toolbar_left recipient-selector\"></div>\n <div class=\"toolbar_main text-h6\">Fleetwire eSign Editor</div>\n <div class=\"toolbar_right\">\n <div class=\"mr-4\">\n <v-btn\n v-if=\"company.uuid\"\n :to=\"sampleRoute\"\n class=\"mr-1\"\n size=\"small\"\n target=\"_blank\"\n >\n <v-icon class=\"mr-2\" size=\"small\">mdi-file-document-outline</v-icon>\n View Sample\n </v-btn>\n </div>\n <div class=\"mr-4\">\n <v-btn :to=\"backRoute\" class=\"mr-1\" size=\"small\">\n <v-icon class=\"mr-2\" size=\"small\">mdi-arrow-left</v-icon>\n Back\n </v-btn>\n </div>\n <div>\n <v-btn :loading=\"isSaving\" color=\"primary\" size=\"small\" @click=\"handleSave\">\n <v-icon class=\"mr-2\" size=\"small\">mdi-content-save-outline</v-icon>\n Save\n </v-btn>\n </div>\n </div>\n </div>\n</template>\n\n<script lang=\"ts\" setup>\nimport {computed, onMounted, ref} from 'vue';\nimport {useCompany} from '@/composables/useCompany';\nimport {store} from '@/store';\nimport {useRoute} from 'vue-router';\n\nconst route = useRoute();\n\nconst emit = defineEmits(['toolbarHeight']);\n\nconst {company} = useCompany();\n\nconst toolbarHeight = ref(0);\n\nconst documentLoading = computed(() => store.getters['document/loading']);\nconst isSaving = computed(() => documentLoading.value.saving);\n\n// Route objects\nconst sampleRoute = computed(() => ({\n name: 'esign.recipient.v2.sample',\n params: {\n envelope_id: route.params.uuid,\n recipient_id: company.value.uuid,\n },\n}));\nconst backRoute = computed(() => ({name: 'documents.index'}));\n\nconst handleSave = () => {\n emit('saveTemplate');\n};\n\nonMounted(() => {\n const toolbar = document.getElementById('site_toolbar');\n toolbarHeight.value = toolbar.offsetHeight;\n emit('toolbarHeight', toolbarHeight.value);\n});\n</script>\n\n<style>\n.site-editor #site_toolbar {\n border-bottom: 1px solid #ccc;\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -ms-flex-direction: row;\n flex-direction: row;\n min-height: 41px;\n width: 100%;\n -webkit-box-flex: 0;\n -ms-flex: 0 0 auto;\n flex: 0 0 auto;\n}\n\n#site_toolbar .toolbar_main {\n -webkit-box-flex: 1;\n -ms-flex: 1 1 0;\n flex: 1 1 0;\n -webkit-box-pack: center;\n -ms-flex-pack: center;\n justify-content: center;\n padding: 0 12px;\n}\n\n</style>\n","<template>\n <g class=\"drag-handles\" v-if=\"handlesOn\" :transform=\"`matrix(1,0,0,1, ${element.x + 20}, ${element.y + 20})`\">\n <rect stroke=\"#2463d1\" fill=\"transparent\" style=\"pointer-events: none;\" opacity=\"0\" rx=\"2\" ry=\"2\" x=\"-1\" y=\"-1\" :width=\"element.w + 20\" :height=\"element.h + 20\" stroke-width=\"0.7621247113163973\"></rect>\n <circle stroke=\"#2463d1\" fill=\"white\" style=\"cursor: nwse-resize;\" opacity=\"1\" cx=\"0\" cy=\"0\" r=\"2.6674364896073905\" stroke-width=\"1.5242494226327945\"></circle>\n <circle stroke=\"#2463d1\" fill=\"white\" style=\"cursor: nesw-resize;\" opacity=\"1\" :cx=\"element.w\" cy=\"0\" r=\"2.6674364896073905\" stroke-width=\"1.5242494226327945\"></circle>\n <circle id=\"fw-signing-element-rect-se\" selectable stroke=\"#2463d1\" fill=\"white\" style=\"cursor: nwse-resize;\" opacity=\"1\" :cx=\"element.w\" :cy=\"element.h\" r=\"2.6674364896073905\" stroke-width=\"1.5242494226327945\"></circle>\n <circle stroke=\"#2463d1\" fill=\"white\" style=\"cursor: nesw-resize;\" opacity=\"1\" cx=\"0\" :cy=\"element.h\" r=\"2.6674364896073905\" stroke-width=\"1.5242494226327945\"></circle>\n <circle style=\"pointer-events: none;cursor: ew-resize;\" stroke=\"#2463d1\" fill=\"white\" opacity=\"0\" cx=\"0\" cy=\"0\" r=\"2.6674364896073905\" stroke-width=\"1.5242494226327945\"></circle>\n <circle style=\"pointer-events: none;cursor: ew-resize;\" stroke=\"#2463d1\" fill=\"white\" opacity=\"0\" cx=\"0\" cy=\"0\" r=\"2.6674364896073905\" stroke-width=\"1.5242494226327945\"></circle>\n </g>\n</template>\n\n<script lang=\"ts\">\n\nexport default {\n name: 'FieldDragHandles',\n\n props: {\n handlesOn: {\n type: Boolean,\n default: false,\n },\n element: {\n type: Object,\n },\n },\n};\n</script>\n","import dayjs from 'dayjs';\nimport isBetween from 'dayjs/plugin/isBetween';\ndayjs.extend(isBetween);\n\nexport const copyTextToClipboard = async (textToCopy: string) => {\n // Navigator clipboard api needs a secure context (https)\n if (navigator.clipboard && window.isSecureContext) {\n try {\n await navigator.clipboard.writeText(textToCopy);\n console.log('Text copied to clipboard using navigator.clipboard');\n } catch (error) {\n console.error('Failed to copy text using navigator.clipboard:', error);\n }\n } else {\n const isModalActive = () => {\n const modals = document.querySelectorAll('.v-overlay.v-overlay--active.v-dialog');\n for (const modal of modals) {\n if (modal.style.display !== 'none') {\n return modal;\n }\n }\n return false;\n };\n\n // Check if a modal is active\n const modal = isModalActive();\n\n const textArea = document.createElement(\"textarea\");\n\n // Use the 'out of viewport hidden text area' trick\n textArea.value = textToCopy;\n\n // Move textarea out of the viewport, so it's not visible\n textArea.style.position = 'absolute';\n textArea.style.left = '-9999px';\n textArea.style.top = '0';\n textArea.style.opacity = '0';\n textArea.classList.add('copy-textarea');\n\n\n if (modal) {\n const dialog = modal.querySelector('.v-overlay__content');\n if (dialog) {\n dialog.appendChild(textArea);\n } else {\n document.body.prepend(textArea);\n }\n } else {\n document.body.prepend(textArea);\n }\n\n textArea.focus();\n textArea.select();\n\n try {\n const successful = document.execCommand('copy');\n if (successful) {\n console.log('Text copied to clipboard using document.execCommand');\n } else {\n console.error('Failed to copy text using document.execCommand');\n }\n } catch (error) {\n console.error('Failed to copy text using document.execCommand:', error);\n } finally {\n textArea.remove();\n }\n }\n};\n\n\nexport const round = (value: number, decimals: number = 2) => {\n return parseFloat( value.toFixed(decimals) );\n}\n\nexport const formatNumberWithCommas = (x) => {\n if (x === null || isNaN(Number(x))) {\n return '0';\n }\n return x.toString().replace(/\\B(?=(\\d{3})+(?!\\d))/g, ',');\n};\n\n\nexport const titleCase = (str) => {\n return str\n .toLowerCase()\n .split(' ')\n .map(word => word.charAt(0).toUpperCase() + word.slice(1))\n .join(' ');\n};\n\nexport const makeResizableDiv = (div) => {\n const element = document.querySelector(div);\n const resizers = document.querySelectorAll(`${div} .resizer`);\n const minimum_size = 20;\n let original_width = 0;\n let original_height = 0;\n let original_x = 0;\n let original_y = 0;\n let original_mouse_x = 0;\n let original_mouse_y = 0;\n for (let i = 0; i < resizers.length; i++) {\n const currentResizer = resizers[i];\n // eslint-disable-next-line no-loop-func\n currentResizer.addEventListener('mousedown', (e: MouseEvent) => {\n e.preventDefault();\n original_width = parseFloat(getComputedStyle(element, null).getPropertyValue('width').replace('px', ''));\n original_height = parseFloat(getComputedStyle(element, null).getPropertyValue('height').replace('px', ''));\n original_x = element.getBoundingClientRect().left;\n original_y = element.getBoundingClientRect().top;\n original_mouse_x = e.pageX;\n original_mouse_y = e.pageY;\n window.addEventListener('mousemove', resize);\n window.addEventListener('mouseup', stopResize);\n });\n\n // eslint-disable-next-line no-inner-declarations,no-loop-func\n function resize(e) {\n if (currentResizer.classList.contains('bottom-right')) {\n const width = original_width + (e.pageX - original_mouse_x);\n const height = original_height + (e.pageY - original_mouse_y);\n if (width > minimum_size) {\n element.style.width = `${width}px`;\n }\n if (height > minimum_size) {\n element.style.height = `${height}px`;\n }\n } else if (currentResizer.classList.contains('bottom-left')) {\n const height = original_height + (e.pageY - original_mouse_y);\n const width = original_width - (e.pageX - original_mouse_x);\n if (height > minimum_size) {\n element.style.height = `${height}px`;\n }\n if (width > minimum_size) {\n element.style.width = `${width}px`;\n element.style.left = `${original_x + (e.pageX - original_mouse_x)}px`;\n }\n } else if (currentResizer.classList.contains('top-right')) {\n const width = original_width + (e.pageX - original_mouse_x);\n const height = original_height - (e.pageY - original_mouse_y);\n if (width > minimum_size) {\n element.style.width = `${width}px`;\n }\n if (height > minimum_size) {\n element.style.height = `${height}px`;\n element.style.top = `${original_y + (e.pageY - original_mouse_y)}px`;\n }\n } else {\n const width = original_width - (e.pageX - original_mouse_x);\n const height = original_height - (e.pageY - original_mouse_y);\n if (width > minimum_size) {\n element.style.width = `${width}px`;\n element.style.left = `${original_x + (e.pageX - original_mouse_x)}px`;\n }\n if (height > minimum_size) {\n element.style.height = `${height}px`;\n element.style.top = `${original_y + (e.pageY - original_mouse_y)}px`;\n }\n }\n }\n\n // eslint-disable-next-line no-inner-declarations\n function stopResize() {\n window.removeEventListener('mousemove', resize);\n }\n }\n};\n\n\nexport const adjustDurationForDaylightSavings = (dates) => {\n const getFirstSunday = (month, year) => {\n let date = dayjs(`${year}-${month + 1}-01`);\n while (date.day() !== 0) {\n date = date.add(1, 'day');\n }\n return date;\n };\n\n const dstStart = getFirstSunday(2, dayjs(dates.start).year()); // March\n const dstEnd = getFirstSunday(10, dayjs(dates.end).year()); // November\n\n if (dayjs(dates.start).isBefore(dstStart) && dayjs(dates.end).isAfter(dstStart)) {\n return 1;\n }\n if (dayjs(dates.start).isBefore(dstEnd) && dayjs(dates.end).isAfter(dstEnd)) {\n return -1;\n }\n\n return 0;\n};\n\nexport const dragElement = (element: HTMLElement) => {\n let pos1 = 0;\n let pos2 = 0;\n let pos3 = 0;\n let pos4 = 0;\n if (document.getElementById(`${element.id}header`)) {\n // if present, the header is where you move the DIV from:\n document.getElementById(`${element.id}header`).onmousedown = dragMouseDown;\n } else {\n // otherwise, move the DIV from anywhere inside the DIV:\n element.onmousedown = dragMouseDown;\n }\n\n function dragMouseDown(e) {\n e = e || window.event;\n e.preventDefault();\n // get the mouse cursor position at startup:\n pos3 = e.clientX;\n pos4 = e.clientY;\n document.onmouseup = closeDragElement;\n // call a function whenever the cursor moves:\n document.onmousemove = elementDrag;\n }\n\n function elementDrag(e) {\n e = e || window.event;\n e.preventDefault();\n // calculate the new cursor position:\n pos1 = pos3 - e.clientX;\n pos2 = pos4 - e.clientY;\n pos3 = e.clientX;\n pos4 = e.clientY;\n // set the element's new position:\n element.style.top = `${element.offsetTop - pos2}px`;\n element.style.left = `${element.offsetLeft - pos1}px`;\n }\n\n function closeDragElement() {\n // stop moving when mouse button is released:\n document.onmouseup = null;\n document.onmousemove = null;\n }\n};\n","import {computed} from 'vue';\nimport {useStore} from 'vuex';\nimport {EnvelopeAttachmentInterface, EnvelopeInterface, RemoveAttachmentPayload} from '@/store/modules/envelope';\n\n\nexport function useESign() {\n const store = useStore();\n\n const template = computed(() => store.getters['template/template']);\n\n const envelope = computed<EnvelopeInterface>(() => store.getters['envelope/envelope']);\n\n const envelopeAttachments = computed<EnvelopeAttachmentInterface[]>(() => envelope.value?.attachments);\n\n\n function getTemplate(uuid: string) {\n store.dispatch('template/getTemplate', uuid);\n }\n\n function updateTemplate(data: { actions: any, template: object }) {\n return store.dispatch('document/updateTemplate', data);\n }\n\n const removeAttachment = async (data: RemoveAttachmentPayload) => {\n return await store.dispatch('envelope/removeAttachment', data);\n }\n\n return {\n template,\n envelope,\n envelopeAttachments,\n removeAttachment,\n updateTemplate,\n getTemplate,\n }\n}","<template>\n <div class=\"site site-fit site-full site-editor\">\n <div :class=\"{'esign-right-bar-enabled': rightSidebarOpen}\" class=\"site_wrap\">\n <!-- Toolbar -->\n <TopToolbar\n @saveTemplate=\"saveTemplate\"\n @toolbarHeight=\"coordinateData.topBarHeight = $event\"\n />\n\n <!-- Content -->\n <div class=\"site_content\">\n <div class=\"content_wrap\" style=\"position: relative\">\n <!-- Left sidebar-->\n <LeftSidebar @addField=\"addField($event)\" @clear-all-fields=\"removeAllFieldsDialog = true\"/>\n\n <!-- Main Content -->\n <div id=\"esign-editor-main-content\" ref=\"content_main\" class=\"content_main flex overflow-scroll\" @mousemove=\"checkDroppable($event)\" @scroll=\"handleScroll\">\n <div id=\"standard-documents\" class=\"standardDocuments\" style=\"flex-grow: 1;\">\n <svg id=\"signer-document\" :height=\"contentMainHeight\" :viewbox=\"`0 0 ${contentMainWidth} ${contentMainHeight}`\" :width=\"contentMainWidth\" focusable=\"false\" @click=\"svgClicked\">\n <g ref=\"DocumentsView\" data-view-id=\"doc-image-container\" data-view-name=\"DocumentsView\" transform=\"matrix(1,0,0,1, 0, 0)\">\n <g id=\"DocumentView\" :transform=\"`matrix(1,0,0,1, ${LeftAndRightDocumentMargin}, ${LeftAndRightDocumentMargin})`\" data-view-id=\"c241\" data-view-name=\"DocumentView\" @load=\"onDocViewLoad\">\n <!-- Page Views -->\n <g v-for=\"(pdf, key) in localDocumentImages\" :id=\"`pdf-${key}`\" :key=\"`pdf-${key}`\" :transform=\"`matrix(1,0,0,1, 0, ${pdf.position})`\" data-view-name=\"PageView\">\n <rect :height=\"docImage.height\" :width=\"pageViewRectangle\" fill=\"transparent\" stroke=\"0\" stroke-width=\"1.4\" x=\"-1\" y=\"-1\"/>\n <image :id=\"`document-image-${key}`\" :height=\"docImage.height\" :width=\"docImage.width\" :xlink:href=\"pdf.path\" @load=\"onImgLoad\"/>\n <text :y=\"docImage.height + 10\" class=\"font-sans\" fill=\"#666666\" font-size=\"8\">\n {{ documentFileName }}\n </text>\n <text :x=\"docImage.width - 20\" :y=\"docImage.height + 10\" class=\"font-sans\" fill=\"#666666\" font-size=\"8\">\n {{ key + 1 }} of {{ localDocumentImages.length }}\n </text>\n </g>\n\n <!-- Data Fields -->\n <g v-for=\"(data, dataKey) in templateStageData\" :id=\"data.id\" :key=\"`fw-signing-element-${data.id}`\" v-tippy :content=\"tippyContent(data)\" :status=\"data.status\" :transform=\"`matrix(1,0,0,1, ${data.x}, ${data.y})`\" class=\"fw-signing-element\" draggable=\"true\" opacity=\"1\" selectable @click=\"checkCoords\" @mousedown=\"selectElement($event, data)\">\n <!-- Signature -->\n <svg v-if=\"data.type === 'signature'\" :height=\"data.h\" :width=\"data.w\" fill=\"none\" viewBox=\"0 0 180 180\" xmlns=\"http://www.w3.org/2000/svg\">\n <path d=\"M125.303 89.4645C124.908 89.4656 124.517 89.387 124.155 89.2338C123.458 88.9413 122.91 88.3942 122.631 87.7127C122.353 87.0311 122.366 86.2709 122.669 85.599L135.361 57.494L131.175 55.2815C130.838 55.1103 130.54 54.8763 130.298 54.5932C130.057 54.3101 129.876 53.9835 129.766 53.6324C129.656 53.2813 129.62 52.9127 129.66 52.548C129.7 52.1834 129.814 51.8299 129.997 51.5083C130.18 51.1867 130.427 50.9032 130.724 50.6745C131.022 50.4458 131.363 50.2763 131.729 50.176C132.096 50.0756 132.479 50.0464 132.857 50.0899C133.234 50.1335 133.6 50.2491 133.931 50.4298L140.417 53.8497C141.046 54.1807 141.523 54.7264 141.756 55.3795C141.988 56.0325 141.958 56.7457 141.672 57.3786L127.938 87.8051C127.715 88.299 127.346 88.7191 126.878 89.0139C126.41 89.3087 125.863 89.4653 125.303 89.4645V89.4645Z\" fill=\"#FEDD55\"/>\n <path d=\"M90.2271 121.909L87.5039 137.966L66.5716 152.347L60.8956 156.234L61.5846 149.581L64.1438 124.912L77.2511 114.655L90.2271 121.909Z\" fill=\"#FEDD55\"/>\n <path d=\"M83.6911 103.853L96.6707 111.11L90.151 121.933L77.1714 114.676L83.6911 103.853Z\" fill=\"#D8D9FB\"/>\n <path d=\"M100.442 114.894L78.3384 102.55L122.398 39.2536C123.476 37.7048 125.126 36.6092 127.012 36.189C128.898 35.7687 130.879 36.0553 132.554 36.9905C134.229 37.9258 135.472 39.4398 136.03 41.2253C136.589 43.0108 136.422 44.9342 135.563 46.6054L100.442 114.894Z\" fill=\"#F2F2FC\"/>\n <path d=\"M77.9728 133.367L66.5716 152.347L60.8956 156.234L61.5846 149.581L73.0187 130.585C73.2045 130.265 73.4547 129.983 73.7547 129.757C74.0547 129.531 74.3984 129.365 74.7659 129.268C75.1334 129.171 75.5172 129.146 75.8949 129.194C76.2726 129.241 76.6366 129.361 76.9658 129.546C77.2949 129.731 77.5825 129.977 77.8118 130.27C78.0411 130.563 78.2075 130.897 78.3012 131.253C78.395 131.609 78.4142 131.979 78.3579 132.342C78.3015 132.705 78.1706 133.053 77.9728 133.367V133.367Z\" fill=\"#FD9F29\"/>\n <path d=\"M139.186 158.531H12.8708C12.1094 158.531 11.3792 158.24 10.8408 157.721C10.3025 157.203 10 156.499 10 155.766C10 155.032 10.3025 154.329 10.8408 153.81C11.3792 153.291 12.1094 153 12.8708 153H139.186C139.948 153 140.678 153.291 141.216 153.81C141.755 154.329 142.057 155.032 142.057 155.766C142.057 156.499 141.755 157.203 141.216 157.721C140.678 158.24 139.948 158.531 139.186 158.531V158.531Z\" fill=\"#454D74\"/>\n <path d=\"M11.544 64.864C14.072 66.592 16.504 67.456 18.84 67.456C21.208 67.456 23.048 66.912 24.36 65.824C25.704 64.736 26.376 63.232 26.376 61.312C26.376 59.744 25.896 58.512 24.936 57.616C23.912 56.624 22.312 55.632 20.136 54.64C19.496 54.32 19.048 54.096 18.792 53.968C16.616 52.944 14.92 51.76 13.704 50.416C12.52 49.072 11.928 47.168 11.928 44.704C11.928 42.24 12.84 40.224 14.664 38.656C16.52 37.088 18.744 36.304 21.336 36.304C23.928 36.304 26.296 36.768 28.44 37.696L27.72 40.336C25.8 39.696 23.928 39.376 22.104 39.376C20.28 39.376 18.744 39.856 17.496 40.816C16.248 41.744 15.624 42.976 15.624 44.512C15.624 46.048 16.056 47.28 16.92 48.208C17.912 49.232 19.672 50.32 22.2 51.472C24.504 52.56 26.072 53.472 26.904 54.208C28.056 55.264 28.776 56.112 29.064 56.752C29.672 58.288 29.976 59.744 29.976 61.12C29.976 64.032 28.968 66.336 26.952 68.032C24.968 69.728 22.408 70.576 19.272 70.576C16.168 70.576 13.336 69.52 10.776 67.408L11.544 64.864ZM40.4145 70.384C38.9425 70.384 37.9185 70.032 37.3425 69.328C36.7665 68.624 36.4785 67.472 36.4785 65.872V47.44H39.9345V63.904C39.9345 65.6 40.0625 66.704 40.3185 67.216C40.5745 67.696 41.3105 67.936 42.5265 67.936L42.6225 70.048C41.8865 70.272 41.1505 70.384 40.4145 70.384ZM36.1425 39.904C36.1425 38.4 36.8785 37.648 38.3505 37.648C39.6945 37.648 40.3665 38.384 40.3665 39.856C40.3665 41.296 39.6625 42.016 38.2545 42.016C36.8465 42.016 36.1425 41.312 36.1425 39.904ZM62.5748 68.56C62.5748 67.056 62.6868 65.632 62.9108 64.288H62.6228C61.4068 68.48 59.0068 70.576 55.4228 70.576C52.7028 70.576 50.6868 69.6 49.3748 67.648C48.0628 65.664 47.4068 62.928 47.4068 59.44C47.4068 55.952 48.3028 52.992 50.0948 50.56C51.9188 48.096 54.5908 46.864 58.1108 46.864C59.4228 46.864 60.7188 47.008 61.9988 47.296C63.3108 47.552 64.5908 47.952 65.8388 48.496L65.8868 68.56C65.8868 72.624 65.1348 75.792 63.6308 78.064C62.1588 80.368 59.6628 81.52 56.1428 81.52C54.8628 81.52 53.5508 81.28 52.2068 80.8C50.8628 80.352 49.7908 79.712 48.9908 78.88L49.5188 77.008C51.3748 78.224 53.5348 78.832 55.9988 78.832C58.4948 78.832 60.2068 77.952 61.1348 76.192C62.0948 74.464 62.5748 71.92 62.5748 68.56ZM55.7588 67.936C60.3348 67.936 62.6228 62.048 62.6228 50.272C61.5988 49.696 60.0948 49.408 58.1108 49.408C53.3748 49.408 51.0068 52.976 51.0068 60.112C51.0068 62.32 51.3748 64.176 52.1108 65.68C52.8468 67.184 54.0628 67.936 55.7588 67.936ZM77.9468 48.4C77.9468 50.096 77.8188 51.52 77.5628 52.672H77.8508C78.2988 50.88 79.1628 49.472 80.4428 48.448C81.7548 47.392 83.3388 46.864 85.1948 46.864C87.7228 46.864 89.4668 47.504 90.4268 48.784C91.3868 50.032 91.8668 51.92 91.8668 54.448C91.8668 54.544 91.8348 56.176 91.7708 59.344C91.7388 62.512 91.7228 64.528 91.7228 65.392C91.7228 66.256 91.8188 66.896 92.0108 67.312C92.2348 67.728 92.9228 67.936 94.0748 67.936L94.1708 70.096C93.7228 70.288 93.0668 70.384 92.2028 70.384C90.6668 70.384 89.6108 70.032 89.0348 69.328C88.4908 68.624 88.2188 67.504 88.2188 65.968C88.2188 65.904 88.2508 64.176 88.3148 60.784C88.3788 57.392 88.4108 55.632 88.4108 55.504C88.4108 53.648 88.1708 52.208 87.6908 51.184C87.2108 50.128 86.2508 49.6 84.8108 49.6C83.4028 49.6 82.2188 50.048 81.2588 50.944C80.3308 51.84 79.6268 53.008 79.1468 54.448C78.2828 57.232 77.8508 60.192 77.8508 63.328V70H74.5388V47.44L77.9468 47.008V48.4Z\" fill=\"black\"/>\n </svg>\n\n <!-- Attachment -->\n <svg v-if=\"data.type === 'attachment'\" :height=\"data.h\" :width=\"data.w\" viewBox=\"-40 -110 479 480\" xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\">\n <linearGradient id=\"a\">\n <stop offset=\"0\" stop-color=\"#006df0\"/>\n <stop offset=\"1\" stop-color=\"#00e7f0\"/>\n </linearGradient>\n <linearGradient id=\"b\" gradientUnits=\"userSpaceOnUse\" x1=\"176.5\" x2=\"176.5\" xlink:href=\"#a\" y1=\"486.856\" y2=\"-43.912\"/>\n <linearGradient id=\"c\" gradientUnits=\"userSpaceOnUse\" x1=\"208.5\" x2=\"208.5\" xlink:href=\"#a\" y1=\"486.856\" y2=\"-43.912\"/>\n <linearGradient id=\"d\" gradientUnits=\"userSpaceOnUse\" x1=\"144.5\" x2=\"144.5\" xlink:href=\"#a\" y1=\"486.856\" y2=\"-43.912\"/>\n <linearGradient id=\"e\" gradientUnits=\"userSpaceOnUse\" x1=\"296.5\" x2=\"296.5\" xlink:href=\"#a\" y1=\"486.856\" y2=\"-43.912\"/>\n <path d=\"m352.394531 135.519531c-.042969-.78125-.203125-1.546875-.480469-2.28125-.082031-.273437-.183593-.539062-.300781-.796875-.421875-.902344-1.007812-1.71875-1.730469-2.402344l-88-80c-.675781-.59375-1.445312-1.070312-2.277343-1.40625-.242188-.105468-.488281-.152343-.738281-.234374-.621094-.195313-1.261719-.3125-1.910157-.351563-.152343-.023437-.304687-.039063-.457031-.046875h-112v-8c-.027344-22.082031-17.917969-39.9726562-40-40h-16c-22.082031.0273438-39.972656 17.917969-40 40v8h-8c-22.082031.027344-39.972656 17.917969-40 40v352c.027344 22.082031 17.917969 39.972656 40 40h272c22.082031-.027344 39.972656-17.917969 40-40v-304c0-.167969-.089844-.3125-.105469-.480469zm-87.894531-61.429687 59.304688 53.910156h-51.304688c-4.417969 0-8-3.582031-8-8zm-200-34.089844c0-13.253906 10.746094-24 24-24h16c13.253906 0 24 10.746094 24 24v96c0 13.253906-10.746094 24-24 24h-16c-13.253906 0-24-10.746094-24-24v-40h8v40c0 8.835938 7.164062 16 16 16h16c8.835938 0 16-7.164062 16-16v-96c0-8.835938-7.164062-16-16-16h-16c-8.835938 0-16 7.164062-16 16v8h-8zm40 8h-16v-8h16zm208 416h-272c-13.253906 0-24-10.746094-24-24v-352c0-13.253906 10.746094-24 24-24h64v72h-16v-48c0-4.417969-3.582031-8-8-8h-24c-4.417969 0-8 3.582031-8 8v48c.027344 22.082031 17.917969 39.972656 40 40h16c22.082031-.027344 39.972656-17.917969 40-40v-72h104v56c0 13.253906 10.746094 24 24 24h64v296c0 13.253906-10.746094 24-24 24zm0 0\" fill=\"url(#b)\"/>\n <path d=\"m120.5 224h176c4.417969 0 8-3.582031 8-8s-3.582031-8-8-8h-176c-4.417969 0-8 3.582031-8 8s3.582031 8 8 8zm0 0\" fill=\"url(#c)\"/>\n <g fill=\"url(#b)\">\n <path d=\"m56.5 272h240c4.417969 0 8-3.582031 8-8s-3.582031-8-8-8h-240c-4.417969 0-8 3.582031-8 8s3.582031 8 8 8zm0 0\"/>\n <path d=\"m56.5 320h240c4.417969 0 8-3.582031 8-8s-3.582031-8-8-8h-240c-4.417969 0-8 3.582031-8 8s3.582031 8 8 8zm0 0\"/>\n <path d=\"m56.5 368h240c4.417969 0 8-3.582031 8-8s-3.582031-8-8-8h-240c-4.417969 0-8 3.582031-8 8s3.582031 8 8 8zm0 0\"/>\n </g>\n <path d=\"m232.5 400h-176c-4.417969 0-8 3.582031-8 8s3.582031 8 8 8h176c4.417969 0 8-3.582031 8-8s-3.582031-8-8-8zm0 0\" fill=\"url(#d)\"/>\n <path d=\"m312.5 400c-4.417969 0-8 3.582031-8 8v16c0 4.417969-3.582031 8-8 8h-16c-4.417969 0-8 3.582031-8 8s3.582031 8 8 8h16c13.253906 0 24-10.746094 24-24v-16c0-4.417969-3.582031-8-8-8zm0 0\" fill=\"url(#e)\"/>\n </svg>\n\n\n <rect :id=\"`pageIndex-1-dataIndex-${dataKey}`\" :class=\"elementClassObject(data)\" :fill=\"elementFillColor(data)\" :fill-opacity=\"['signature', 'attachment'].includes(data.type) ? 0.20 : 0.75\" :height=\"data.h\" :resizable=\"data.resizable\" :width=\"data.w\" class=\"field-rectangle\" rx=\"1.4239482200647249\" ry=\"1.4239482200647249\" selectable stroke=\"#5CAEFF\" stroke-opacity=\"1\" stroke-width=\"0.7119741100323624\" style=\"pointer-events: all; cursor: pointer;\" type=\"text\" @click=\"signerElementClicked(data)\"/>\n\n <!-- Checkbox -->\n <svg v-if=\"data.type === 'checkbox'\" :height=\"data.h\" :width=\"data.w\" style=\"width:24px;height:24px\" viewBox=\"0 0 24 24\">\n <path v-if=\"data.value\" d=\"M19,19H5V5H15V3H5C3.89,3 3,3.89 3,5V19A2,2 0 0,0 5,21H19A2,2 0 0,0 21,19V11H19M7.91,10.08L6.5,11.5L11,16L21,6L19.59,4.58L11,13.17L7.91,10.08Z\" fill=\"currentColor\"/>\n <path v-else d=\"M19,3H5C3.89,3 3,3.89 3,5V19A2,2 0 0,0 5,21H19A2,2 0 0,0 21,19V5C21,3.89 20.1,3 19,3M19,5V19H5V5H19Z\" fill=\"currentColor\"/>\n </svg>\n\n <!-- Other -->\n <text v-if=\"!['signature', 'attachment', 'text'].includes(data.type)\" id=\"text-1\" :font-size=\"determineDisplayFontSize(data)\" :y=\"determineYTextOffset(data)\" fill=\"#333\" font-family=\"Lucida Console, Andale Mono, monaco, monospace\" opacity=\"1\" style=\"pointer-events: none;\" x=\"1\">\n <tspan dy=\"9\" letter-spacing=\".05\" x=\"1\">{{ data.text }}</tspan>\n </text>\n\n <!-- Text -->\n <text v-if=\"data.type === 'text'\" id=\"text-2\" :font-size=\"determineDisplayFontSize(data)\" :y=\"determineYTextOffset(data)\" fill=\"#333\" font-family=\"Lucida Console, Andale Mono, monaco, monospace\" opacity=\"1\" style=\"pointer-events: none;\" x=\"1\">\n <tspan v-if=\"data.text.length === 0\" dy=\"9\" letter-spacing=\".05\" opacity=\".5\" x=\"1\">\n {{ data.toolTip ? data.toolTip : data.type }}\n </tspan>\n <tspan v-for=\"(lines, lineIndex) in determineTextLines(data)\" :key=\"lineIndex\" :dy=\"lineIndex === 0 ? 9 : 11\" letter-spacing=\".05\" x=\"1\">\n {{ lines }}\n </tspan>\n </text>\n </g>\n </g>\n\n <!-- Drag handles -->\n <FieldDragHandles\n :element=\"currentWorkingDataElement\"\n :handles-on=\"dragHandlesOn\"\n />\n\n </g>\n </svg>\n\n <div ref=\"dataEditor\" style=\" width: 100px; height: 25px; position: absolute; transform: scale(1); transform-origin: left top;\">\n <div class=\"tab-editor-interface_content\">\n <textarea v-model=\"editorText\" :readonly=\"currentWorkingDataElement?.readOnly\" maxlength=\"4000\" tabindex=\"-1\"></textarea>\n </div>\n </div>\n </div>\n </div>\n\n <!-- Right Sidebar -->\n <RightSideColumn\n :document-file-name=\"documentFileName\"\n :document-images=\"localDocumentImages\"\n @scroll-to-page=\"scrollToPage\"\n />\n\n </div>\n </div>\n\n <TemplateRightSidebarV2\n @update:esign-field-deleted=\"dragHandlesOn = false; removeSelectedItems();\"\n\n />\n </div>\n\n <div v-if=\"debugDrawerOpen\" class=\"absolute top-o\">\n {{ coordinateData }}\n </div>\n\n <div v-if=\"debugDrawerOpen\" class=\"absolute top-20 p-1 debug debug-draggable w-52\" style=\"background-color: #0acf97\">\n <div class=\"flex flex-col\">\n <small>DEBUG BUTTONS</small>\n <v-btn class=\"mt-1\" size=\"x-small\" @click=\"adjustDataCoords()\">\n adjustDataCoords\n </v-btn>\n\n <v-btn class=\"mt-1\" color=\"red\" size=\"x-small\" @click=\"toggleDebugDrawer()\">\n TURN OFF DEBUG.\n </v-btn>\n\n {{ selectedFieldV3Coordinates }}\n\n {{ docImage }} <br>\n\n {{ contentLeftSidebarWidth }}<br>\n\n {{ LeftAndRightDocumentMargin }} <br>\n {{ scrollTop }} <br>\n\n </div>\n </div>\n\n <div v-if=\"debugDrawerOpen\" class=\"border debug debug-draggable relative overflow-hidden\" style=\"height: 600px; width: 300px;max-width: 300px;bottom: 10px; left: 0; opacity: 90%; background-color: rgba(0,0,0,0.90)\">\n <div>\n <div class=\"text-white small fixed debug-draggable__header\">The First Staged Data item</div>\n <code>\n <pre v-html=\"formatJson(firstStagedData)\"/>\n </code>\n </div>\n </div>\n\n <v-dialog v-model=\"removeAllFieldsDialog\" width=\"400\">\n <v-card>\n <v-card-title>Are you sure?</v-card-title>\n\n <v-card-text>\n You are about to delete all the fields on this document and start over.\n </v-card-text>\n\n <v-card-actions>\n <v-spacer/>\n <v-btn\n color=\"grey\"\n variant=\"text\"\n @click=\"removeAllFieldsDialog = false\"\n >\n Nevermind\n </v-btn>\n <v-btn color=\"error\" @click=\"removeAllFields()\">\n Reset Fields\n </v-btn>\n </v-card-actions>\n </v-card>\n </v-dialog>\n\n </div>\n</template>\n\n<script lang=\"ts\" setup>\nimport {computed, onBeforeUnmount, onMounted, ref, ShallowRef, useTemplateRef, watch} from 'vue';\nimport TemplateRightSidebarV2 from '@/views/documentsV2/TemplateRightSidebarV2.vue';\nimport LeftSidebar from '@/components/dashboard/documents/LeftSidebar.vue';\nimport TopToolbar from '@/components/dashboard/documents/TopToolbar.vue';\nimport RightSideColumn from '@/components/dashboard/documents/RightSideColumn.vue';\nimport FieldDragHandles from '@/components/dashboard/documents/FieldDragHandles.vue';\nimport {dragElement, round} from '@/helpers';\nimport {ESignerFieldData, ESignTool} from '@/types';\nimport {useCompany} from '@/composables/useCompany';\nimport {useESign} from '@/composables/useESign';\nimport {useAppSettings} from '@/composables/useAppSettings';\nimport {useTemplate} from '@/composables/useTemplate';\nimport {useRoute} from 'vue-router';\nimport {push} from 'notivue'\n\nexport interface documentImagesInterface {\n position: number;\n path: string;\n}\n\nconst route = useRoute();\nconst {company} = useCompany();\nconst {getTemplate, updateTemplate} = useESign();\nconst {toggleDebugDrawer, debugDrawerOpen} = useAppSettings();\nconst {\n documentsLoading,\n selectedFieldV2,\n allTools,\n template,\n selectedFieldV3Coordinates,\n updateSelectedField,\n templateStageData,\n updateStageData,\n templateDocumentImages,\n documentImages,\n setDocumentImages,\n addToStageData,\n makeFieldId,\n removeAllStageData,\n setSingleTemplate,\n setToolsActive,\n currentSigner,\n documentFileName,\n} = useTemplate();\n\n\nconst content_main = useTemplateRef('content_main') as ShallowRef<HTMLElement>;\nconst dataEditor = useTemplateRef('dataEditor') as ShallowRef<HTMLElement>;\n\nconst documentUuid = route.params.uuid as string;\nconst standardDoc = ref(null);\nconst standardDocCoords = ref(null);\nconst pageMarginY = 32;\nconst contentMainWidth = ref(612);\nconst contentMainHeight = ref(825);\nconst contentLeftSidebarWidth = ref(300);\nconst mainContentStartingXPosition = ref(260);\nconst scrollTop = ref(0);\nconst originalContentMainWidth = ref(612);\nconst originalContentMainHeight = ref(792);\nconst localDocumentImages = ref<documentImagesInterface[]>([]);\nconst currentWorkingDataElement = ref(null);\nconst elementOffsetX = ref(0);\nconst elementOffsetY = ref(0);\nconst dragHandlesOn = ref(false);\n\n\nconst coordinateData = ref({\n x: 0,\n y: 0,\n page: 1,\n pageId: null,\n item_x: 0,\n item_y: 0,\n item_height: 0,\n topBarHeight: 42,\n})\n\nconst removeAllFieldsDialog = ref(false);\nconst editorText = ref('');\nconst searchTool = ref('');\nconst currentWorkingFieldId = ref(null);\nconst currentWorkingTarget = ref('');\n\nconst handleScroll = (event: MouseEvent) => {\n const target = event.target as HTMLElement;\n scrollTop.value = target.scrollTop;\n};\n\n\nconst getCanvasOffset = computed(() => {\n if (!standardDocCoords.value) {\n return {\n top: 0, left: 0, right: 0, bottom: 0, height: 0\n };\n }\n\n\n const top = standardDocCoords.value.top - scrollTop.value + 20;\n const left = standardDocCoords.value.left + window.scrollX;\n const right = standardDocCoords.value.right;\n const bottom = standardDocCoords.value.bottom;\n const height = standardDocCoords.value.height;\n const page = 0;\n return {\n page: Number(page),\n top: Number(top.toFixed(3)),\n left: Number(left.toFixed(3)),\n right: Number(right.toFixed(3)),\n bottom: Number(bottom.toFixed(3)),\n height: Number(height.toFixed(3)),\n };\n});\n\nconst determineRelativeY = (topPosition: number): number => {\n const pos = topPosition - getCanvasOffset.value.top;\n\n if (pos <= docImage.value.height) return round(pos, 5);\n const totalPages = templateDocumentImages.value.length;\n\n let relTopPos = 0;\n for (let i = 1; i <= totalPages; i++) {\n const relPosition = (docImage.value.height * i);\n const pageYGap = pageHeightAdjust(i);\n if (pos >= relPosition - docImage.value.height && pos <= relPosition) {\n relTopPos = pos - (docImage.value.height * (i - 1)) - pageYGap;\n }\n }\n return round(relTopPos, 5);\n};\n\n\nconst rightSidebarOpen = computed(() => {\n return selectedFieldV2.value?.id;\n});\n\nconst LeftAndRightDocumentMargin = computed((): number => {\n return (contentMainWidth.value - pageViewRectangle.value) / 2; // usually 20px\n});\n\nconst widthChange = computed((): number => {\n return (pageViewRectangle.value - originalContentMainWidth.value) / originalContentMainWidth.value;\n});\n\nconst documentStartingXPosition = computed((): number => {\n return LeftAndRightDocumentMargin.value + mainContentStartingXPosition.value; // usually 260px\n});\n\nconst objectRatioHeightRev = (scaled: number): number => {\n const newHeight = docImage.value.height;\n const savedHeight = originalContentMainHeight.value;\n const tempScale = scaled / newHeight;\n return round(tempScale * savedHeight, 5);\n};\n\nconst objectRatioWidthRev = (scaled: number): number => {\n const newWidth = docImage.value.width;\n const savedWidth = originalContentMainWidth.value;\n const tempScale = scaled / newWidth;\n return round(tempScale * savedWidth, 5);\n};\n\nconst pageHeightAdjust = (page: number): number => {\n return ((pageMarginY * (page - 1)) * 100000) / 100000;\n};\n\nconst handleWindowResize = () => {\n contentMainWidth.value = content_main.value.clientWidth;\n contentMainHeight.value = contentMainWidth.value / docImage.value.ratio * localDocumentImages.value.length;\n};\n\n\nconst getSelectedElements = () => {\n return Array.from(document.querySelectorAll('.field-selected'));\n};\n\n\nconst removeSelectedElements = () => {\n const selected = getSelectedElements();\n\n selected.forEach((f) => {\n f.setAttribute('stroke', '#CAEFF');\n f.setAttribute('stroke-width', '1');\n f.classList.remove('field-selected');\n });\n\n dragHandlesOn.value = false;\n};\n\nconst handleKeyup = (evt: KeyboardEvent) => {\n evt.preventDefault();\n const target = evt.target as HTMLElement;\n const key = evt.key.toLowerCase();\n const isInputFocused = ['input', 'textarea'].includes(target.localName);\n\n if (isInputFocused) return;\n\n switch (key) {\n /** DELETE / BACKSPACE - Delete Selected Fields */\n case 'backspace':\n case 'delete':\n removeSelectedItems()\n break;\n\n case 'c':\n if (evt.ctrlKey || evt.metaKey) {\n evt.preventDefault();\n copySelectedElement();\n }\n break;\n\n /** ESCAPE - Deselect Current Field */\n case 'escape':\n removeSelectedElements();\n currentWorkingDataElement.value = null;\n updateSelectedField(null);\n break;\n }\n\n};\n\nconst removeSelectedItems = () => {\n const dropItems = getSelectedElements();\n dragHandlesOn.value = false;\n\n if (dropItems.length > 0) {\n const elementIdsToRemove = dropItems.map((d) => d.parentElement?.id).filter(Boolean);\n\n dropItems.forEach((d) => d.setAttribute('style', 'display:none;'));\n\n // Filter out elements and update Vuex state using the mutation\n templateStageData.value.forEach((data, index) => {\n if (elementIdsToRemove.includes(data.id)) {\n updateStageData({data: null, index}); // Set to null or handle deletion in mutation\n }\n });\n\n removeSelectedElements();\n currentWorkingDataElement.value = null;\n updateSelectedField(null);\n\n push.success({\n message: 'Field removed',\n });\n }\n\n dragHandlesOn.value = false;\n};\n\nconst moveSelectedElement = (key: string, evt: KeyboardEvent) => {\n evt.preventDefault();\n const selected = getSelectedElements();\n\n const moveStep = evt.shiftKey ? 10 : 1; // Shift + Arrow Key moves by 10px, otherwise 1px\n\n\n if (selected.length > 0) {\n const elementId = selected[0].parentElement?.id;\n const dataIndex = templateStageData.value.findIndex((d) => d.id === elementId);\n\n if (dataIndex !== -1) {\n const data = templateStageData.value[dataIndex];\n let newX = data.x;\n let newY = data.y;\n\n switch (key) {\n case 'arrowup':\n newY -= moveStep;\n break;\n case 'arrowdown':\n newY += moveStep;\n break;\n case 'arrowleft':\n newX -= moveStep;\n break;\n case 'arrowright':\n newX += moveStep;\n break;\n }\n\n console.dir(`newX: ${newX}`);\n newX = verifyElementXCoords(newX);\n newY = verifyElementYCoords(newY);\n updateStageData({\n data: {...data, x: newX, y: newY}, index: dataIndex\n });\n\n currentWorkingDataElement.value = {...data, x: newX, y: newY};\n }\n }\n};\n\nconst firstStagedData = computed(() => {\n return templateStageData.value[0];\n});\n\nconst customerDefaultProperties = computed(() => {\n return company.value?.default_properties?.filter((f) => ['customer', 'order'].includes(f.owner_type));\n});\n\nconst filteredTools = computed((): ESignTool[] => {\n // Filter out disabled tools\n const tools = allTools.value.filter((t: ESignTool) => !t.disabled && t.name.toLowerCase().includes(searchTool.value.toLowerCase()));\n\n // Map to a specific structure\n const defaultProperties = customerDefaultProperties.value.map((dp) => ({\n id: `custom-field-${dp.uuid}`,\n name: dp.name,\n type: 'field',\n category: 'Custom Fields',\n icon: 'mdi-focus-field-horizontal',\n customField: true,\n w: (dp.name.length * 9) + 10,\n h: 20,\n }));\n\n return [...tools, ...defaultProperties];\n});\n\n\n/**\n * Adjusts the width of the tool based on the current image width\n * NOTE: I set the tools width based on my screen size at the time of development.\n * So, this should be adjusted to the width of the screen when the tool was placed.\n */\nconst toolWidthAdjusted = (width: number): number => {\n const widthWhenTooling = 928;\n const currentImageWidth = +docImage.value.width;\n const widthDifference = currentImageWidth - widthWhenTooling;\n const widthChange = widthDifference === 0\n ? 0\n : widthDifference / widthWhenTooling;\n\n return round((width + (width * widthChange)), 5);\n};\n\n\n/**\n * Adjusts the height of the tool based on the current adjusted width\n * NOTE: I set the tools width based on my screen size at the time of development.\n * So, this should be adjusted to the width of the screen when the tool was placed.\n */\nconst toolHeightAdjusted = (width: number, height: number): number => {\n return round(toolWidthAdjusted(width) * (height / width), 5);\n};\n\nconst objectRatioWidth = (width: number): number => objectRatio(width, originalContentMainWidth.value, 'width');\n\nconst objectRatioHeight = (height: number): number => objectRatio(height, originalContentMainHeight.value, 'height');\n\nconst objectRatio = (value: number, reference: number, label: string): number => {\n const numericValue = Number(value);\n\n if (isNaN(numericValue)) {\n console.error(`Invalid ${label} value:`, value);\n return 0;\n }\n\n return Math.abs(parseFloat((numericValue / reference).toFixed(5)));\n};\n\nwatch(template, (templateNew) => {\n originalContentMainWidth.value = templateNew?.documents?.dimensions?.width ?? 612;\n originalContentMainHeight.value = templateNew?.documents?.dimensions?.height ?? 792;\n}, {once: true});\n\n\nconst adjustDocumentContainerHeight = () => {\n const docHeight = pageViewRectangle.value / docImage.value.ratio;\n console.dir(`DOC HEIGHT:: ${docHeight}`);\n console.dir(documentImages.value);\n\n localDocumentImages.value = [...documentImages.value];\n\n localDocumentImages.value.forEach((p, index) => {\n // console.dir(`index: ${index}`);\n // console.dir(p);\n if (index === 0) return;\n localDocumentImages.value[index].position = (index * docHeight) + (pageMarginY * index);\n });\n\n adjustDataCoords();\n};\n\n\nwatch(templateDocumentImages, (images) => {\n const docHeight = round(pageViewRectangle.value / docImage.value.ratio, 5);\n console.dir(`Doc Height: ${docHeight}`);\n console.dir(images);\n\n setDocumentImages(images.map((i, index) => ({\n path: i,\n position: (index * docHeight) + (pageMarginY * index),\n })));\n\n if (images.length > 0) {\n contentMainWidth.value = content_main.value.clientWidth;\n console.log(`contentMainWidth: ${contentMainWidth.value}`);\n contentMainHeight.value = docImage.value.height / docImage.value.ratio;\n contentMainHeight.value = contentMainWidth.value / docImage.value.ratio * images.length;\n\n contentLeftSidebarWidth.value = document.getElementById('content_sidebar-left').clientWidth;\n\n\n adjustDocumentContainerHeight();\n }\n});\n\nconst scrollToPage = (pageIndex: number) => {\n console.log('scrollToPage!!');\n console.dir(pageIndex);\n\n const pagePosition = localDocumentImages.value[pageIndex].position;\n content_main.value.scrollTo({\n top: pagePosition,\n left: 0,\n behavior: 'smooth',\n });\n};\n\nonMounted(() => {\n getTemplate(documentUuid);\n\n window.addEventListener('resize', handleWindowResize, false);\n document.addEventListener('keyup', handleKeyup, false);\n document.addEventListener('keydown', handleKeydown, false);\n\n\n standardDoc.value = document.getElementById('standard-documents');\n\n // esign-editor-main-content\n const mainContent = document.getElementById('esign-editor-main-content');\n\n // how far from the left of the window\n mainContentStartingXPosition.value = mainContent.getBoundingClientRect().left;\n\n\n // console.dir(standardDoc.value);\n // console.dir(standardDoc.value.getBoundingClientRect());\n const standardDocCoordsRect = standardDoc.value.getBoundingClientRect();\n\n standardDocCoords.value = {\n top: standardDocCoordsRect.top,\n left: standardDocCoordsRect.left,\n right: standardDocCoordsRect.right,\n bottom: standardDocCoordsRect.bottom,\n height: standardDocCoordsRect.height,\n width: standardDocCoordsRect.width,\n x: standardDocCoordsRect.x,\n y: standardDocCoordsRect.y,\n };\n\n const draggableDebug = Array.from(document.getElementsByClassName('debug-draggable')) as HTMLElement[];\n draggableDebug.forEach((el) => {\n dragElement(el);\n });\n});\n\n\nconst pageViewRectangle = computed(() => {\n return contentMainWidth.value - 40;\n});\n\nconst templateDocumentDimensions = computed(() => {\n return template.value?.documents?.dimensions ?? {\n width: 612,\n height: 792,\n };\n});\n\nconst templateDocumentDimensionRatio = computed(() => {\n const h = templateDocumentDimensions.value.height;\n const w = templateDocumentDimensions.value.width;\n return round(w / h, 5);\n});\n\nconst docImage = computed(() => {\n const width = pageViewRectangle.value;\n const height = width / templateDocumentDimensionRatio.value;\n const ratio = width / height;\n return {\n width,\n height,\n ratio,\n };\n});\n\n\nconst adjustDataCoords = () => {\n templateStageData.value.forEach((data: ESignerFieldData, dataIndex: number) => {\n const adjust = pageHeightAdjust(data.page || 1);\n\n data.xRatio = objectRatioWidth(data.originalX);\n data.yRatio = objectRatioHeight(data.originalY);\n\n data.x = (docImage.value.width * data.xRatio) < 0 ? 0 : round(docImage.value.width * data.xRatio, 5);\n data.y = Math.round(((docImage.value.height * data.yRatio) + adjust) * 100000) / 100000;\n data.w = round(docImage.value.width * objectRatioWidth(data.originalWidth), 5);\n data.h = round(docImage.value.height * objectRatioHeight(data.originalHeight), 5);\n data.page = determinePageNumber(data.y);\n\n updateStageData({\n data,\n index: dataIndex,\n });\n });\n};\n\nconst verifyElementXCoords = (x: number) => {\n // e.clientX - elementOffsetX.value - documentStartingXPosition.value\n console.log('verifyElementXCoords:: ' + x);\n console.log('elementOffsetX.value:: ' + elementOffsetX.value);\n\n console.log('documentStartingXPosition.value:: ' + documentStartingXPosition.value);\n const element = currentWorkingDataElement.value;\n const documentWidth = docImage.value.width;\n\n // 🛑 Prevent movement outside the left side\n if (x < 0) {\n console.log('%c X AXIS CHECK FAILED - Left Side', 'background: #fd0000;');\n return 0; // Prevent going below the first page\n }\n\n // 🛑 Prevent movement outside the right side\n if (x + element.w > documentWidth) {\n console.log('%c X AXIS CHECK FAILED - Right Side', 'background: #fd0000;');\n return documentWidth - element.w; // Prevent going below the first page\n }\n\n // ✅ Allow movement across pages\n console.log('%c X AXIS CHECK PASSED', 'background: #a6e22e;');\n return x;\n\n}\n\nconst verifyElementYCoords = (finalY: number) => {\n console.log('verifyElementYCoord:: ' + finalY);\n\n if (finalY < 0) return 0; // Prevent dragging above the first page\n\n const element = currentWorkingDataElement.value;\n const documentHeight = docImage.value.height;\n const totalPages = localDocumentImages.value.length;\n const currentPage = determinePageNumber(finalY);\n\n const pageOffset = (currentPage - 1) * (documentHeight + pageMarginY);\n const pageEndY = pageOffset + documentHeight;\n const elementBottom = finalY + element.h;\n\n // 🛑 Prevent stopping in the page gap\n if ((finalY + element.h) >= pageEndY && finalY < pageEndY + pageMarginY) {\n console.log('%c Y AXIS CHECK FAILED - In Page Gap', 'background: #fd0000; font-size: 20px;');\n return pageEndY - element.h; // Snap to the start of the next page\n }\n\n // ✅ Fix last page issue: Adjust the final Y limit\n const lastPageHeight = (documentHeight * totalPages) + ((totalPages - 1) * pageMarginY);\n\n // 🛑 Prevent movement below the last page\n if (currentPage === totalPages && elementBottom > lastPageHeight) {\n console.log('%c Y AXIS CHECK FAILED - Below Last Page', 'background: #fd0000;');\n return lastPageHeight - element.h; // Prevent going below the last page\n }\n\n // ✅ Handle transitions smoothly (Optional Optimization)\n if (finalY < pageOffset && elementBottom > pageEndY - element.h) {\n console.log('%c Smooth Transition Between Pages', 'background: #00ff00;');\n return pageOffset; // Snap to top of the page when transitioning\n }\n\n // ✅ Allow movement across pages\n console.log('%c Y AXIS CHECK PASSED', 'background: #a6e22e;');\n return finalY;\n};\n\n\nconst dropListener = (e: MouseEvent) => {\n console.dir('drop');\n e.preventDefault();\n\n // currentWorkingDataElement.value.y = determineRelativeY(currentWorkingDataElement.value.y);\n // currentWorkingDataElement.value.y = verifyElementYCoords(currentWorkingDataElement.value.y);\n\n console.log('%c dropListener ', 'background: #fd0000;');\n\n console.log('currentWorkingDataElement.value.y:' + currentWorkingDataElement.value.y);\n console.log('getCanvasOffset.value.top ' + getCanvasOffset.value.top);\n try {\n const theDeterminedY = determineRelativeY(currentWorkingDataElement.value.y + getCanvasOffset.value.top);\n\n console.log('theDeterminedY: ' + theDeterminedY);\n currentWorkingDataElement.value.relativeY = theDeterminedY;\n currentWorkingDataElement.value.originalX = round(objectRatioWidthRev(selectedFieldV3Coordinates.value.x), 5);\n currentWorkingDataElement.value.originalY = objectRatioHeightRev(selectedFieldV3Coordinates.value.y - pageHeightAdjust(selectedFieldV2.value?.page || 1));\n currentWorkingDataElement.value.originalRelativeY = objectRatioHeightRev(theDeterminedY);\n } catch (e) {\n console.error(e);\n }\n\n elementOffsetX.value = 0;\n elementOffsetY.value = 0;\n};\n\n\nconst adjustOriginalCoords = () => {\n templateStageData.value.forEach((data: ESignerFieldData, dataIndex: number) => {\n const adjust = pageHeightAdjust(data?.page || 1);\n\n templateStageData.value[dataIndex].originalX = objectRatioWidthRev(templateStageData.value[dataIndex].x);\n templateStageData.value[dataIndex].originalY = objectRatioHeightRev(templateStageData.value[dataIndex].y - adjust);\n\n // updateStageData({\n // data: {\n // ...templateStageData.value[dataIndex],\n // originalX: objectRatioWidthRev(templateStageData.value[dataIndex].x),\n // originalY: objectRatioHeightRev(templateStageData.value[dataIndex].y - adjust),\n // },\n // index: dataIndex,\n // });\n });\n};\n\nconst saveTemplate = () => {\n console.dir('saveTemplate ***********');\n adjustOriginalCoords();\n\n const actions = JSON.stringify(templateStageData.value);\n\n updateTemplate({\n actions: btoa(encodeURI(actions)),\n template: template.value,\n });\n};\n\n\nconst handleKeydown = (evt: KeyboardEvent) => {\n const key = evt.key.toLowerCase();\n\n /**\n * If the user is pressing the command and s key then save the document\n * Note: this needs to be on keydown and not keyup\n */\n if (evt.metaKey && key === 's') {\n console.log('save');\n evt.preventDefault();\n if (documentsLoading.value.saving === false) {\n saveTemplate();\n }\n }\n /**\n * If the user is pressing the command and c key then copy the selected element\n */\n if (evt.metaKey && key === 'c') {\n evt.preventDefault();\n copySelectedElement();\n }\n\n /** ARROW KEYS - Move Selected Field */\n if (key === 'arrowup' || key === 'arrowdown' || key === 'arrowleft' || key === 'arrowright') {\n moveSelectedElement(key, evt);\n }\n\n}\n\nconst determinePageNumber = (topPosition: number): number => {\n const pos = Math.max(0, topPosition);\n const documentImageHeight = docImage.value.height;\n const totalPages = templateDocumentImages.value.length;\n\n if (pos <= documentImageHeight + pageMarginY) return 1;\n\n\n for (let i = 1; i <= totalPages; i++) {\n const pageTop = documentImageHeight * (i - 1);\n const pageBottom = (documentImageHeight * i) + pageMarginY;\n\n // if pos is between pageTop and pageBottom\n if (pos >= pageTop && pos <= pageBottom) {\n console.dir(`PAGE: ${i}`);\n return i;\n }\n }\n return totalPages;\n};\n\nconst copySelectedElement = () => {\n const selectedElement = getSelectedElements();\n\n if (selectedElement.length > 0) {\n const selectedElementData = templateStageData.value.find((d: ESignerFieldData) => d.id === selectedElement[0].parentElement.id);\n\n if (selectedElementData) {\n const newElement = JSON.parse(JSON.stringify(selectedElementData));\n newElement.id = `${newElement.type}-${makeFieldId()}`;\n newElement.x = selectedElementData.x + 10;\n newElement.y = selectedElementData.y + 10;\n removeSelectedElements();\n removeSelectedElements();\n templateStageData.value.push(newElement);\n\n push.success({\n message: 'Copied',\n });\n }\n }\n};\n\nconst checkCoords = (e: MouseEvent) => {\n dragHandlesOn.value = !!(e.target as HTMLElement).hasAttribute('resizable');\n};\n\n\nconst formatJson = (json: any) => {\n let html = '<span class=\"fw-json-start-bracket\">{</span>';\n if (json) {\n // eslint-disable-next-line guard-for-in\n for (const key in json) {\n // eslint-disable-next-line no-prototype-builtins\n if (json.hasOwnProperty(key)) {\n html += `<div class=\"fw-json-item\"><span class=\"fw-json-key\">${key}</span>: <span class=\"fw-json-value\">${json[key]}</span></div>`;\n }\n }\n }\n html += '<span class=\"fw-json-end-bracket\">}</span>';\n return html;\n};\n\n\nconst tippyContent = (data: ESignerFieldData) => {\n if (data?.primary_customer) {\n if (data.type === 'signature') {\n return 'Primary - Signature';\n }\n return `Primary - ${data.text}`;\n }\n\n if (data?.secondary_customer) {\n if (data.type === 'signature') {\n return 'Secondary - Signature';\n }\n return `Secondary - ${data.text}`;\n }\n return data.text;\n};\n\nconst elementFillColor = (data: ESignerFieldData) => {\n // return data.type === 'signature' ? '#5be8ff' : '#5be8ff';\n return data.type === 'signature' ? '#9970ad' : '#c0af50';\n};\n\nconst elementClassObject = (data: ESignerFieldData) => {\n return {\n 'fw-signing-element-rect': data.primary_customer ?? true,\n 'fw-signing-element-rect-secondary': data.secondary_customer ?? false,\n };\n};\n\nconst determineYTextOffset = (data: ESignerFieldData) => {\n if (['signature', 'attachment'].includes(data.type)) {\n return data.fontSize - (widthChange.value * 7);\n }\n return (widthChange.value * 12);\n};\n\nconst determineDisplayFontSize = (data: ESignerFieldData) => {\n return ['signature', 'attachment'].includes(data.type) ? (widthChange.value * data.fontSize) : (widthChange.value * data.fontSize) + 10;\n};\n\nconst countCheckboxes = () => {\n let count = 1;\n templateStageData.value.forEach((data: ESignerFieldData) => {\n if (data.type === 'checkbox') {\n count++;\n }\n });\n return count;\n};\n\nconst removeAllFields = () => {\n dragHandlesOn.value = false;\n removeSelectedElements();\n removeAllStageData();\n updateSelectedField(null);\n removeAllFieldsDialog.value = false;\n\n push.success({\n message: 'Removed all fields - Click Save to save your work',\n });\n};\n\nconst signerElementClicked = (data: ESignerFieldData) => {\n currentWorkingDataElement.value = data;\n updateSelectedField(data);\n};\n\nconst onDocViewLoad = (e: Event) => {\n console.dir('Document View Loaded');\n console.dir(e);\n};\n\nconst onImgLoad = (payload: Event) => {\n\n console.log('onImgLoad');\n console.dir(payload);\n};\n\nconst removeDraggingEventListeners = (elementId: string) => {\n console.dir('removeDraggingEventListeners');\n const signingElement = document.getElementById(elementId);\n const mainContent = document.querySelector('.content_main');\n\n if (signingElement) {\n signingElement.removeEventListener('dragstart', dragStartListener);\n }\n if (mainContent) {\n mainContent.removeEventListener('dragover', dragOverListener);\n }\n};\n\nconst dragStartListener = (e: DragEvent) => {\n const signingElement = document.getElementById(currentWorkingFieldId.value);\n console.dir(currentWorkingFieldId.value);\n console.dir(signingElement);\n console.dir('dragstart');\n e.dataTransfer.setData('text/plain', 'element1');\n\n const boundingRect = signingElement.getBoundingClientRect();\n elementOffsetX.value = e.clientX - boundingRect.left;\n elementOffsetY.value = e.clientY - boundingRect.top;\n};\n\nconst dragOverListener = (e: MouseEvent) => {\n console.dir('dragOverListener');\n\n currentWorkingDataElement.value.x = verifyElementXCoords(e.clientX - elementOffsetX.value - documentStartingXPosition.value);\n currentWorkingDataElement.value.y = verifyElementYCoords(e.clientY - elementOffsetY.value - getCanvasOffset.value.top);\n currentWorkingDataElement.value.page = determinePageNumber(currentWorkingDataElement.value.y);\n\n e.preventDefault(); // Allow drop\n};\n\nconst svgClicked = (e: MouseEvent) => {\n console.log('%c svgClicked', 'background: #222; color: #bada55');\n const target = e.target as HTMLElement;\n\n console.log(target.parentElement.id);\n dataEditor.value.style.display = 'none';\n\n if (currentWorkingTarget.value && currentWorkingTarget.value !== target.id) {\n console.log('%c REMOVED field-selected from field 1', 'background: #222; color: #bada55');\n const theId = `#${currentWorkingTarget.value}`;\n const oldTarget = document.querySelector(theId);\n if (oldTarget) {\n oldTarget.classList.remove('field-selected');\n }\n }\n currentWorkingTarget.value = target.parentElement.id;\n\n const dropItems = document.querySelectorAll('.fw-signing-element[status=droppable]');\n\n if (dropItems.length > 0) {\n console.log('%c REMOVED field-selected from field 2', 'background: #222; color: #bada55');\n templateStageData.value.forEach((f: ESignerFieldData) => {\n f.status = 'dropped';\n });\n\n removeSelectedElements();\n currentWorkingDataElement.value = {};\n }\n\n if (!target.classList.contains('fw-signing-element-rect') && target.id !== 'fw-signing-element-rect-se') {\n console.log('%c REMOVED field-selected from field 3', 'background: #222; color: #bada55');\n target.classList.remove('field-selected');\n\n removeDraggingEventListeners(currentWorkingFieldId.value);\n }\n\n if (!target.hasAttribute('selectable')) {\n console.dir('removeSelectedElements');\n removeSelectedElements();\n currentWorkingDataElement.value = {};\n updateSelectedField(null);\n }\n\n target.classList.add('working');\n initElementsDrag();\n};\n\n\nconst initElementsDrag = () => {\n const mainContent = document.querySelector('.content_main');\n const signingElement = document.getElementById(currentWorkingFieldId.value);\n\n if (signingElement) {\n signingElement.addEventListener('dragstart', dragStartListener);\n\n mainContent.addEventListener('dragover', dragOverListener);\n\n document.body.addEventListener('drop', dropListener);\n }\n};\n\n\nwatch(() => contentMainWidth.value, () => {\n dataEditor.value.style.display = 'none';\n adjustDataCoords();\n adjustDocumentContainerHeight();\n});\n\nconst selectElement = (e: MouseEvent, data: ESignerFieldData) => {\n // console.log('%c selectElement', 'background: #222; color: #bada55');\n // console.dir(e.target);\n const target = e.target as HTMLElement;\n //\n removeSelectedElements();\n dragHandlesOn.value = target.hasAttribute('resizable');\n currentWorkingFieldId.value = target.parentElement.id;\n svgClicked(e);\n if (target.hasAttribute('selectable')) {\n console.dir('selectElement HERE2');\n target.classList.add('field-selected');\n currentWorkingDataElement.value = data;\n signerElementClicked(data);\n }\n};\n\nconst determineTextLines = (data: ESignerFieldData) => {\n console.log('%c determineTextLines', 'background: #222; color: #bada55');\n const text = data.text;\n if (!text) return [''];\n\n const words = text.split(' ');\n\n if (words.length === 0) return [''];\n if (words.length === 1) return [data.text];\n\n const el = document.createElement('div');\n document.body.appendChild(el);\n\n el.style.position = 'absolute';\n el.style.display = 'inline';\n el.style.fontSize = `${determineDisplayFontSize(data)}px`;\n // el.style.padding = '0 16px';\n el.style['white-space'] = 'nowrap';\n\n let rows = [];\n let usedIndex = 0;\n // loop through each word and check if clientWidth is surpassing maxWidth\n for (let i = 0; i < words.length; i++) {\n const word = words[i];\n el.innerHTML += word;\n if (el.clientWidth > data.originalWidth) {\n rows.push(el.innerHTML);\n usedIndex = i;\n el.innerHTML = '';\n } else {\n el.innerHTML += ' ';\n }\n }\n\n // handle remaining words\n words.splice(0, usedIndex);\n rows = rows.concat(words.join(' '));\n\n document.body.removeChild(el);\n\n return rows;\n};\n\nconst checkDroppable = (e: MouseEvent) => {\n const target = e.target as HTMLElement;\n const targetParent = target.parentNode as HTMLElement;\n\n coordinateData.value = {\n ...coordinateData.value,\n pageId: targetParent.id,\n clientY: e.clientY,\n clientX: e.clientX,\n };\n\n if (targetParent.id.startsWith('pdf-')) {\n updateCoordinateDataForPage(targetParent, e);\n }\n\n const dropItems = document.querySelectorAll('.fw-signing-element[status=droppable]');\n\n if (dropItems.length > 0) {\n setToolsActive(false);\n\n const contentMain = document.querySelector('.content_main');\n const top = e.pageY + contentMain.scrollTop + 2; // Allows the element to follow the mouse on scroll\n\n currentWorkingDataElement.value.x = e.pageX - documentStartingXPosition.value;\n currentWorkingDataElement.value.y = top\n - 20 // the height of the top of the first page to the top bar height bottom\n - coordinateData.value.topBarHeight;\n currentWorkingDataElement.value.page = determinePageNumber(currentWorkingDataElement.value.y);\n currentWorkingDataElement.value.relativeY = determineRelativeY(currentWorkingDataElement.value.y);\n\n const theDeterminedY = determineRelativeY(currentWorkingDataElement.value.y + getCanvasOffset.value.top);\n currentWorkingDataElement.value.originalRelativeY = objectRatioHeightRev(theDeterminedY);\n }\n};\n\n// 🔹 Helper function to update coordinate data for the current page\nconst updateCoordinateDataForPage = (targetParent: HTMLElement, e: MouseEvent) => {\n const pageNumber = +targetParent.id.replace('pdf-', '');\n coordinateData.value.page = pageNumber + 1;\n\n const rect = targetParent.getBoundingClientRect();\n const contentMainElement = document.querySelector('.content_main') as HTMLElement;\n const offsetParent = contentMainElement.offsetParent as HTMLElement;\n\n coordinateData.value.pageTop = rect.top - offsetParent.offsetTop;\n\n coordinateData.value.x = e.clientX - rect.left;\n coordinateData.value.y = round(\n e.clientY - coordinateData.value.topBarHeight - coordinateData.value.pageTop - 2\n );\n};\n\nconst calculateTextWidth = (text: string, fontSize: number) => {\n const charWidthFactor = 0.8;\n return Math.ceil(text.length * fontSize * charWidthFactor);\n};\n\n\nconst addField = (typeId = null) => {\n console.log(`%c [ addField ] `, 'background: #DDD; color: #000; font-size: 20px;');\n\n currentWorkingDataElement.value = {};\n\n const selectedTool = filteredTools.value.find((t) => t.id === typeId) as ESignTool;\n if (!selectedTool) return;\n\n const fieldId = `${selectedTool.type}-${makeFieldId()}`;\n const fontSize = selectedTool.fontSize ?? 12;\n const text = selectedTool.type === 'field' ? selectedTool.name : '';\n\n // 🔹 Dynamically calculate width and height\n const baseWidth = Math.max(text ? calculateTextWidth(text, fontSize) : selectedTool.w ?? 50, 50);\n const adjustedWidth = toolWidthAdjusted(baseWidth);\n const adjustedHeight = toolHeightAdjusted(baseWidth, selectedTool.h ?? 20);\n\n console.log(`Text: ${text}, Width: ${adjustedWidth}, Height: ${adjustedHeight}`);\n\n // 🔹 Determine positioning\n const startingX = 10;\n const startingY = 100 + scrollTop.value;\n const originalDimensions = {\n width: objectRatioWidthRev(adjustedWidth),\n height: objectRatioHeightRev(adjustedHeight),\n x: objectRatioWidthRev(startingX),\n y: objectRatioWidthRev(startingY),\n relativeY: objectRatioWidthRev(startingY),\n };\n\n // 🔹 Create field data\n const fieldData: ESignerFieldData = {\n id: fieldId,\n page: determinePageNumber(startingY),\n x: startingX,\n y: startingY,\n relativeY: startingY,\n w: adjustedWidth,\n h: adjustedHeight,\n originalWidth: originalDimensions.width,\n originalHeight: originalDimensions.height,\n originalX: originalDimensions.x,\n originalY: originalDimensions.y,\n originalRelativeY: originalDimensions.relativeY,\n xRatio: null,\n text,\n title: selectedTool.name ?? '',\n fontSize,\n resizable: selectedTool.resizable ?? true,\n draggable: true,\n status: 'droppable',\n required: selectedTool.required ?? true,\n readOnly: selectedTool.readOnly ?? false,\n typeId,\n type: selectedTool.type,\n customField: selectedTool.customField ?? false,\n version: selectedTool.version ?? 2,\n };\n\n // 🔹 Apply conditional properties\n applyConditionalFieldProperties(fieldData, selectedTool);\n\n // 🔹 Add field to stage and update state\n addToStageData(fieldData);\n updateSelectedField(fieldData);\n\n currentWorkingDataElement.value = fieldData;\n currentWorkingFieldId.value = fieldId;\n\n adjustOriginalCoords();\n adjustDataCoords();\n};\n\nconst applyConditionalFieldProperties = (fieldData: ESignerFieldData, tool: ESignTool) => {\n if (tool.type === 'checkbox') {\n fieldData.value = false;\n fieldData.fieldName = `Checkbox${countCheckboxes()}`;\n }\n if (tool.customField) {\n fieldData[`${currentSigner.value}_customer`] = true;\n }\n if (tool.primary) fieldData.primary_customer = true;\n if (tool.secondary) fieldData.secondary_customer = true;\n};\n\n\nonBeforeUnmount(() => {\n console.dir('BEFORE_UNMOUNT');\n window.removeEventListener('resize', handleWindowResize, false);\n document.removeEventListener('keyup', handleKeyup, false);\n document.removeEventListener('keydown', handleKeydown, false);\n\n removeSelectedElements();\n currentWorkingDataElement.value = null;\n\n\n updateSelectedField(null);\n setSingleTemplate(null);\n});\n</script>\n\n<style>\n.fw-json-item {\n color: #f8f8f2;\n margin-left: 16px;\n}\n\n.fw-json-key {\n color: #f92672;\n}\n\n.fw-json-value {\n color: #a6e22e;\n}\n\n.fw-json-start-bracket, .fw-json-end-bracket {\n color: #f92672;\n}\n\n.debug-draggable {\n position: absolute;\n z-index: 9;\n background-color: #f1f1f1;\n border: 1px solid #d3d3d3;\n}\n\n.debug-draggable__header {\n padding: 10px;\n cursor: move;\n z-index: 10;\n background-color: #2196F3;\n color: #fff;\n}\n\n.left-sidebar-group.left-sidebar-group-active {\n background-color: #f9f9f9;\n}\n\n.fw-signing-element-rect {\n fill: #5be8ff;\n stroke: #5CAEFF;\n stroke-width: 1;\n}\n\n.fw-signing-element-rect-secondary {\n fill: #975bff !important;\n stroke: #975bff !important;\n stroke-width: 1;\n}\n\n.field-selected {\n fill: red;\n stroke: blue;\n stroke-width: 2;\n}\n\n.resizable {\n position: relative;\n}\n\n[draggable=true] {\n -webkit-user-drag: element;\n}\n\nsvg:not(:root) {\n overflow: hidden;\n}\n\n.working + text > tspan {\n color: red;\n}\n\n.content_sidebar-right {\n border-left: 1px solid #fd0000;\n}\n\n.site {\n -webkit-box-orient: vertical;\n -ms-flex-direction: column;\n flex-direction: column;\n min-height: 100vh;\n}\n\n.site-fit .content_wrap {\n height: 100%;\n}\n\n.site-fit {\n max-height: 100vh;\n}\n\n.site-fit {\n height: 100vh;\n}\n\n.site-editor {\n background-color: #e9e9e9;\n}\n\n.site-full .content_wrap,\n.site-full .footer_wrap,\n.site-full .header_wrap,\n.site-full .hero_wrap,\n.site-full .toolbar_wrap {\n max-width: none;\n}\n\n.site_wrap {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-flex: 0;\n -ms-flex: 0 1 auto;\n flex: 0 1 auto;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -ms-flex-direction: column;\n flex-direction: column;\n min-height: 100vh;\n}\n\n.content_wrap {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -ms-flex-direction: row;\n flex-direction: row;\n -webkit-box-flex: 1;\n flex-grow: 1;\n min-height: 0;\n width: 100%;\n}\n\n.content_wrap,\n.footer_wrap,\n.header_wrap,\n.hero_wrap,\n.toolbar_wrap {\n margin: 0 auto;\n max-width: 1506px;\n}\n\n.content_main {\n min-width: 0;\n}\n\n.content_main {\n -webkit-box-flex: 1;\n -ms-flex: 1 1 0;\n flex: 1 1 0;\n}\n\n.standardDocuments {\n position: relative;\n}\n\n.site_footer, .site_header, .site_hero {\n -webkit-box-flex: 0;\n -ms-flex: 0 0 auto;\n flex: 0 0 auto;\n}\n\n.site-editor .site_content {\n -webkit-box-flex: 1;\n -ms-flex: 1 1 0;\n flex: 1 1 0;\n}\n\n.site-fit .site_content {\n flex-basis: 0;\n}\n\n.site_content,\n.site_content.content,\n.site_content > .content {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-flex: 1;\n -ms-flex: 1 1 auto;\n flex: 1 1 auto;\n -webkit-box-orient: vertical !important;\n -webkit-box-direction: normal !important;\n -ms-flex-direction: column !important;\n flex-direction: column !important;\n min-height: 0;\n}\n\n.site, .site_content {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-direction: normal;\n width: 100%;\n}\n\n.site_content {\n -webkit-box-flex: 1;\n -ms-flex: 1 1 auto;\n flex: 1 1 auto;\n -webkit-box-orient: horizontal;\n -ms-flex-direction: row;\n flex-direction: row;\n min-height: 0;\n}\n\n.l-flex-between {\n -webkit-box-align: center;\n -ms-flex-align: center;\n align-items: center;\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-pack: justify;\n -ms-flex-pack: justify;\n justify-content: space-between;\n}\n\n.l-flex-between > :first-child {\n -webkit-box-flex: 1;\n -ms-flex: 1 1 0;\n flex: 1 1 0;\n min-width: 0;\n}\n\n.drawer.down > .drawer-wrapper,\n.drawer.up > .drawer-wrapper {\n width: 100%;\n}\n\n\n.documentPage .bar-action .btn-action {\n display: block;\n float: right;\n height: 28px;\n margin: 0;\n padding: 0;\n text-align: center;\n width: 28px;\n}\n\n.content_sidebar.sidebar-showingDrawer {\n overflow: hidden;\n}\n\n.accordion {\n background: 0 0;\n border: 0;\n cursor: pointer;\n display: block;\n font-size: inherit;\n line-height: 20px;\n padding: 6px 48px 6px 24px;\n position: relative;\n text-align: left;\n -webkit-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n user-select: none;\n width: 100%;\n}\n\n.documentPage {\n background-color: #fff;\n border: 1px solid #ccc;\n cursor: pointer;\n display: block;\n margin: 0 auto 14px;\n position: relative;\n width: 132px;\n}\n\n.documentPage img {\n display: block;\n height: auto;\n width: 100%;\n}\n\n.documentPage .bar-action {\n background-color: #e9e9e9;\n bottom: 0;\n height: 28px;\n position: absolute;\n width: 100%;\n}\n\n.content_sidebar-right {\n position: relative;\n}\n\n\n.content_sidebar {\n max-width: 375px;\n min-width: 220px;\n overflow: hidden;\n width: 220px;\n}\n\n.site-editor .sidebar_header {\n border-bottom: 1px solid #d9d9d9;\n padding: 13px 24px;\n}\n\n.form_item-iconLeft, .form_item-iconRight {\n position: relative;\n}\n\n.site-editor .toolbar_left,\n.site-editor .toolbar_main,\n.site-editor .toolbar_right {\n -webkit-box-align: center;\n -ms-flex-align: center;\n align-items: center;\n -ms-flex-item-align: stretch;\n align-self: stretch;\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n min-height: inherit;\n}\n\n.site-fit .content_sidebar {\n overflow-y: auto;\n}\n\n.site-editor .toolbar_left {\n max-width: 375px;\n min-width: 220px;\n padding-left: 12px;\n width: 240px;\n}\n\n.site-editor .toolbar_right {\n max-width: 375px;\n min-width: 220px;\n width: 220px;\n}\n\n.site-editor .toolbar_right {\n -webkit-box-pack: end;\n -ms-flex-pack: end;\n justify-content: flex-end;\n padding-right: 24px;\n}\n\n.form_item-iconLeft, .form_item-iconRight {\n position: relative;\n}\n\n.form_item-iconRight .input-text {\n padding-right: 29px;\n}\n\n.sidebarTabs {\n background: #e9e9e9;\n list-style: none;\n margin: 0;\n padding: 0 !important;\n}\n\n\n.menu-fields {\n margin-left: -15px;\n margin-right: -15px;\n}\n\n.tab-editor-interface_content {\n display: block;\n position: absolute;\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n z-index: 1;\n}\n\n.tab-editor-interface_content textarea {\n -webkit-writing-mode: horizontal-tb !important;\n text-rendering: auto;\n color: black;\n letter-spacing: normal;\n word-spacing: normal;\n text-transform: none;\n text-indent: 0;\n text-shadow: none;\n display: inline-block;\n text-align: start;\n background-color: rgb(255, 255, 255);\n -webkit-rtl-ordering: logical;\n flex-direction: column;\n cursor: text;\n white-space: pre-wrap;\n overflow-wrap: break-word;\n margin: 0;\n font: 400 13px Arial;\n border-width: 1px;\n border-style: solid;\n border-color: rgb(118, 118, 118);\n border-image: initial;\n padding: 2px;\n}\n\n.tab-editor-interface_content textarea:focus {\n outline: none;\n}\n\n.tab-editor-interface_content textarea {\n width: 100%;\n height: 100%;\n resize: none;\n}\n\ntext {\n display: block;\n white-space: nowrap;\n}\n</style>\n","import {each, find, findIndex, get, isNull, isUndefined, lowerCase} from 'lodash';\nimport dayjs from 'dayjs';\nimport {mapGetters} from 'vuex';\nimport {formatNumberWithCommas} from '@/helpers';\nimport {SubscriptionPlan} from \"@/types\";\n\nexport default {\n\n data() {\n return {\n allowCreditCardInput: true,\n subscriptionFeatures: {\n seats: {\n basic: 2,\n standard: 5,\n premium: 20,\n },\n listings: {\n basic: 5,\n standard: 50,\n premium: 150,\n },\n locations: {\n basic: 1,\n standard: 2,\n premium: 2,\n },\n carSharingConnections: {\n basic: 1,\n standard: 5,\n premium: 10,\n },\n smartCarConnections: {\n basic: 1,\n standard: 5,\n premium: 10,\n },\n orders: {\n basic: 5,\n standard: 50,\n premium: 20,\n },\n },\n\n planIncludes: {\n premium: {\n api: true,\n sso: true,\n coupons: true,\n additional_scripts: true,\n custom_domain: true,\n custom_tos: true,\n listing_exports: true,\n listing_imports: true,\n esign: true,\n webhooks: true,\n barcodes: true,\n custom_checkout_fields: true,\n },\n standard: {\n sso: true,\n coupons: true,\n custom_tos: true,\n listing_exports: true,\n listing_imports: true,\n esign: true,\n barcodes: true,\n custom_checkout_fields: true,\n },\n basic: {\n // esign: true,\n },\n },\n };\n },\n\n watch: {\n subLoading() {\n this.$store.commit('subscriptions/UPDATE_NEW_SUBSCRIPTION', {\n plan: lowerCase(this.subscriptionPlan),\n billingPeriod: lowerCase(this.subscriptionDuration),\n });\n },\n },\n\n computed: {\n ...mapGetters({\n user: 'auth/user',\n enforceSubscription: 'subscriptions/enforceSubscription',\n subscriptionsLoading: 'subscriptions/loading',\n plans: 'subscriptions/plans',\n subscription: 'subscriptions/subscription',\n hasActiveSubscription: 'subscriptions/hasActiveSubscription',\n subscriptionPlan: 'subscriptions/subscriptionPlan',\n subscriptionDuration: 'subscriptions/subscriptionDuration',\n subscriptionEndDate: 'subscriptions/subscriptionEndDate',\n company: 'company/company',\n allListings: 'listing/allListings',\n companySeatCount: 'company/companySeatCount',\n subscriptionForm: 'subscriptions/subscriptionForm',\n extraListingsAddonCount: 'subscriptions/extraListingsAddonCount',\n stripeSubscriptionObject: 'stripe/stripeSubscriptionObject',\n }),\n currentStripeSubscriptionObjectRenewalDate(): string | null {\n const date = this.stripeSubscriptionObject?.current_period_end;\n\n if (!date) return null;\n\n return dayjs(date * 1000).format('MMMM D, YYYY');\n },\n currentStripeSubscriptionObjectPlanAmount(): string {\n const amount = this.stripeSubscriptionObject?.plan?.amount;\n\n if (!amount) return '$0';\n\n if (amount % 100 === 0) {\n return `$${(amount * 0.01).toFixed(0)}`;\n }\n\n return `$${(amount * 0.01).toFixed(2)}`;\n },\n\n currentStripeSubscriptionObjectPlanInterval(): string | null {\n return this.stripeSubscriptionObject?.plan?.interval;\n },\n currentPlanDetails() {\n return find(this.plans, (p) => p.name === this.subscriptionPlan);\n },\n currentPlanBullets() {\n return get(this.currentPlanDetails, 'description.bullets');\n },\n subLoading() {\n return this.subscriptionsLoading.subscription;\n },\n plan() {\n return lowerCase(this.subscriptionPlan);\n },\n inTrial(): boolean {\n const trialDate = !!get(this.user, 'on_trial');\n\n if (trialDate) return true;\n\n const stripeTrialDate = get(this.subscription, 'trial_ends_at');\n\n if (stripeTrialDate) {\n return dayjs(stripeTrialDate).diff(dayjs()) > 0;\n }\n\n return false;\n },\n subscriptionStatus() {\n return this.subscription?.stripe_status;\n },\n inGracePeriod(): boolean {\n const endDate = get(this.subscription, 'ends_at');\n const status = this.subscriptionStatus\n\n return !(status === 'canceled' && dayjs(endDate).diff(dayjs()) <= 0);\n },\n monthlyPrice() {\n const plans: SubscriptionPlan[] = this.plans;\n\n const planIndex = findIndex(plans, (p) => this.newSubscription?.plan === p.name);\n if (planIndex === -1) return 0;\n if (isUndefined(planIndex)) return 0;\n return this.plans[planIndex].pricing[this.newSubscription.billingPeriod].price;\n },\n billingPricing() {\n const months = this.newSubscription?.billingPeriod === 'yearly' ? 12 : 1;\n const totalBilled = this.monthlyPrice * months;\n return formatNumberWithCommas(totalBilled);\n },\n listingLimitReached() {\n if (!this.enforceSubscription) return false;\n\n if (this.inTrial && !this.hasActiveSubscription) {\n return false;\n }\n\n if (!this.hasActiveSubscription) {\n return true;\n }\n const limit = this.subscriptionFeatures.listings[this.plan]\n + this.extraListingsAddonCount;\n\n return (limit !== -1)\n && this.allListings.length >= limit;\n },\n listingLimitReachedMessage() {\n if (isNull(this.subscriptionPlan)) return 'You need a subscription plan to add listings.';\n return `You've reached your max listings of <b>${this.subscriptionFeatures.listings[this.plan]}</b> for your plan.`;\n },\n\n planIncludesESign() {\n if (!this.enforceSubscription) return true;\n\n if (this.inTrial && !this.hasActiveSubscription) {\n return true;\n }\n\n if (!this.hasActiveSubscription) {\n return false;\n }\n\n return get(this.planIncludes, `${this.plan}.esign`);\n },\n\n planIncludesApi() {\n if (!this.enforceSubscription) return true;\n\n if (this.inTrial && !this.hasActiveSubscription) {\n return true;\n }\n\n if (!this.hasActiveSubscription) {\n return false;\n }\n\n return get(this.planIncludes, `${this.plan}.api`);\n },\n\n carShareConnectionsLimitReached() {\n if (!this.enforceSubscription) return false;\n\n if (this.inTrial && !this.hasActiveSubscription) {\n return false;\n }\n\n if (!this.hasActiveSubscription) {\n return true;\n }\n\n let connections = 0;\n each(get(this.company, 'connections.turo'), () => {\n connections++;\n });\n each(get(this.company, 'connections.getaround'), () => {\n connections++;\n });\n each(get(this.company, 'connections.ryde'), () => {\n connections++;\n });\n\n return (this.subscriptionFeatures.listings[this.plan] !== -1)\n && connections >= this.subscriptionFeatures.carSharingConnections[this.plan];\n },\n smartCarConnectionsLimitReached() {\n if (!this.enforceSubscription) return false;\n\n if (this.inTrial && !this.hasActiveSubscription) return false;\n\n if (!this.hasActiveSubscription) return true;\n\n let connections = 0;\n each(get(this.company, 'connections.tesla'), () => {\n connections++;\n });\n each(get(this.company, 'connections.bouncie'), () => {\n connections++;\n });\n\n return (this.subscriptionFeatures.smartCarConnections[this.plan] !== -1)\n && connections >= this.subscriptionFeatures.smartCarConnections[this.plan];\n },\n carShareConnectionsLimitReachedMessage() {\n if (isNull(this.subscriptionPlan)) return 'You need a subscription plan to add a connection.';\n return `You've reached your max car-sharing connection of <b>${this.subscriptionFeatures.carSharingConnections[this.plan]}</b> for your plan.`;\n },\n seatLimitReachedMessage() {\n if (isNull(this.subscriptionPlan)) return 'You need a subscription plan to add seats.';\n return `You've reached your max seats of <b>${this.subscriptionFeatures.seats[this.plan]}</b> for your plan.`;\n },\n },\n\n methods: {\n includedInSubscription(topic) {\n if (!this.enforceSubscription) return true;\n\n if (this.inTrial) return true;\n\n if (!this.hasActiveSubscription) return false;\n\n if (isUndefined(this.planIncludes[this.plan])) return false;\n if (isUndefined(this.planIncludes[this.plan][topic])) return false;\n return this.planIncludes[this.plan][topic];\n },\n },\n};\n","import dayjs from 'dayjs';\n\n\nexport function useDateFormatter() {\n\n const formatRentalDate = (date: Date | string | number, format: string = 'MMM DD, YYYY @ h:mma'): string => {\n const parsedDate = dayjs(date);\n return parsedDate.isValid() ? parsedDate.format(format) : 'Invalid Date';\n }\n\n return {\n formatRentalDate,\n }\n}\n","import {computed, ComputedRef} from 'vue';\nimport {useStore} from 'vuex';\nimport {CompanyInterface, CurrencySettings} from '@/types';\nimport getDefaultMeta from '@/utils/meta';\n\n\ntype MoneyTextInputSettings = {\n prefix: string,\n suffix: string,\n}\n\nexport function useMoneyFormatter() {\n const store = useStore();\n\n const company: ComputedRef<CompanyInterface> = computed(() => store.getters['company/company']);\n\n const DEFAULT_CURRENCY_FORMAT = 'symbol';\n const DEFAULT_CURRENCY_POSITION = 'left';\n const DEFAULT_CURRENCY: CurrencySettings = {\n decimal: '.',\n format: '%s%v',\n name: 'USD',\n precision: 2,\n symbol: '$',\n thousand: ',',\n };\n\n /**\n * Converts an integer amount (cents) to a decimal value (dollars)\n */\n const fromCents = (amount: number | undefined): number => {\n return Number(((amount ?? 0) * 0.01).toFixed(2));\n };\n\n /**\n * Converts a decimal value (dollars) to an integer amount (cents)\n */\n const toCents = (amount: number): number => {\n if (isNaN(amount)) {\n return 0;\n }\n\n console.dir('toCents');\n console.dir(amount);\n return Math.round(amount * 100);\n };\n\n const formatNumberWithCommas = (x: number | string): string => {\n if (x === null || isNaN(Number(x))) {\n return '0';\n }\n return x.toString().replace(/\\B(?=(\\d{3})+(?!\\d))/g, ',');\n };\n\n /**\n * Formats an amount to include commas and decimal places.\n * Handles integer-based currency storage.\n */\n const formatAmount = (amount: number, convertFromInt = true): string => {\n const multiplier = convertFromInt ? 0.01 : 1;\n const formattedAmount = (amount * multiplier).toFixed(2);\n return formatNumberWithCommas(formattedAmount);\n };\n\n const formatMoneyDisplayV2 = (amount: number, convertFromInt: boolean = true) => {\n const currency = getCompanyCurrency();\n const {format, position} = getCompanyCurrencyFormatSettings();\n return setCurrencyAndValue(formatAmount(amount, convertFromInt), currency, position, format);\n };\n\n /**\n * Combines currency symbol/name with the value based on position.\n */\n const setCurrencyAndValue = (\n value: string | number,\n currency: CurrencySettings,\n position: 'left' | 'right' = 'left',\n format: 'symbol' | 'name' | string = 'symbol'\n ): string => {\n const symbolOrName = format === 'symbol' ? currency.symbol : currency.name;\n return position === 'left' ? `${symbolOrName}${value}` : `${value}${symbolOrName}`;\n }\n\n /**\n * Retrieves the company's currency settings or defaults.\n */\n const getCompanyCurrency = (): CurrencySettings => {\n return company.value?.currency || DEFAULT_CURRENCY;\n };\n\n /**\n * Determines the currency format and position for the company.\n */\n const getCompanyCurrencyFormatSettings = (): { format: string; position: 'left' | 'right' } => {\n return {\n format: getDefaultMeta('settings.pricing.currency.format') as string || DEFAULT_CURRENCY_FORMAT,\n position: getDefaultMeta('settings.pricing.currency.position') as 'left' | 'right' || DEFAULT_CURRENCY_POSITION,\n };\n };\n\n\n /**\n * Returns the currency symbol for the company.\n */\n const companyCurrencySymbol = (): string => getCompanyCurrency().symbol;\n\n\n const companyMoneyTextInputSettings = computed<MoneyTextInputSettings>(() => {\n const currency = getCompanyCurrency();\n const {format, position} = getCompanyCurrencyFormatSettings();\n const symbol = format === 'symbol' ? currency.symbol : currency.name;\n\n return {\n prefix: position === 'left' ? symbol : '',\n suffix: position === 'right' ? symbol : '',\n };\n });\n\n /**\n * Formats money without adding a currency symbol.\n */\n const formatMoney = (amount: number, convertFromInt = true): string => {\n return amount ? formatAmount(amount, convertFromInt) : '0';\n };\n\n /**\n * Formats money specifically in USD.\n */\n const formatMoneyDisplayUSD = (amount: number, convertFromInt = true): string => {\n return `$${formatMoney(amount, convertFromInt)}`;\n };\n\n /**\n * Returns the current currency symbol.\n */\n const currencySymbol = (): string => getCompanyCurrency().symbol;\n\n\n return {\n companyMoneyTextInputSettings,\n currencySymbol,\n formatMoney,\n formatAmount,\n formatMoneyDisplayV2,\n setCurrencyAndValue,\n companyCurrencySymbol,\n formatMoneyDisplayUSD,\n formatNumberWithCommas,\n fromCents,\n toCents,\n };\n}\n","import {computed} from 'vue';\nimport {useStore} from 'vuex';\nimport {\n AcceptEnvelopePayload,\n EnvelopeInterface,\n EnvelopePage,\n RemoveAttachmentPayload,\n SaveProgressPayload,\n SaveSignaturePayload,\n} from '@/store/modules/envelope';\nimport {DocumentType, TemplateData} from '@/store/modules/document';\nimport {ESignerFieldData, StoreLoaders} from '@/types';\n\nexport type NewEnvelope = {\n b_id: string,\n template_uuid: string,\n send_method: {\n email: boolean,\n sms: boolean,\n },\n}\n\nexport interface envelopeDataByPageInterface {\n page: number;\n path: string;\n pageData: ESignerFieldData[];\n}\n\nexport function useEnvelope() {\n const store = useStore();\n\n const envelope = computed<EnvelopeInterface>(() => store.getters['envelope/envelope']);\n const envelopes = computed(() => store.getters['envelope/envelopes']);\n\n const envelopeLoading = computed<StoreLoaders>(() => store.getters['envelope/loading']);\n const envelopeDialogs = computed(() => store.getters['envelope/envelopeDialogs']);\n const envelopeForm = computed(() => store.getters['envelope/envelopeForm']);\n const envelopesQuery = computed(() => store.getters['envelope/envelopesQuery']);\n const envelopesPagination = computed(() => store.getters['envelope/envelopesPagination']);\n const totalRemainingFields = computed<number>(() => store.getters['envelope/totalRemainingFields']);\n const envelopeIsReady = computed<boolean>(() => store.getters['envelope/envelopeIsReady']);\n\n const allEnvelopeData = computed<ESignerFieldData[]>(() => store.getters['envelope/allEnvelopeData']);\n const esignSessionData = computed(() => store.getters['envelope/esignSessionData']);\n const esignEnvelopeDataCopy = computed<EnvelopePage[]>(() => store.getters['envelope/esignEnvelopeDataCopy']);\n\n const envelopeCustomer = computed(() => store.getters['envelope/envelopeCustomer']);\n const envelopeCustomerData = computed(() => envelopeCustomer.value?.data || {});\n\n const envelopeTemplate = computed<TemplateData>(() => envelope.value?.template);\n const envelopeTemplateDocuments = computed<DocumentType>(() => envelopeTemplate.value?.documents);\n const envelopeDocumentImages = computed(() => envelopeTemplateDocuments.value?.document_images || []);\n\n const envelopeDocumentDimensions = computed(() => envelopeTemplateDocuments.value?.dimensions || {\n width: 612,\n height: 792\n });\n const envelopeDocumentDimensionRatio = computed(() => {\n const h = envelopeDocumentDimensions.value.height;\n const w = envelopeDocumentDimensions.value.width;\n\n return Math.round((w / h) * 100000) / 100000; // Round to 5 decimal places\n });\n\n const envelopeCompleted = computed(() => envelope.value?.completed_at);\n const envelopeCustomerCompleted = computed(() => envelopeCustomer.value?.completed_at);\n\n const completedEnvelopeUrl = computed<string>(() => envelope.value?.file_path || envelope.value?.pdf_url || '');\n\n const envelopeStatus = computed(() => envelope.value?.status || 'pending');\n\n const envelopeData = computed<envelopeDataByPageInterface[]>(() => {\n const fields = Array.isArray(allEnvelopeData.value) ? [...allEnvelopeData.value].sort((a, b) => a.page - b.page) : [];\n\n console.dir('envelopeData');\n console.dir(fields);\n const pages = envelopeDocumentImages.value || [];\n\n return pages.map((p, index) => {\n const pageNumber = index + 1;\n let pageData = fields.filter((f) => f.page === pageNumber) || [];\n\n pageData = pageData.map((d) => {\n const data = d;\n const updated = data.updated;\n const title = data.title;\n\n if (data.type === 'field') {\n const filled = data.filled || false;\n return {\n ...data,\n filled,\n text: filled ? data.text : '',\n placeholder: data.text,\n toolTip: data.text,\n title: title || data.text,\n };\n }\n if (data.type === 'text') {\n return {\n ...data,\n filled: data.filled || true,\n placeholder: data.text,\n text: data.readOnly || updated ? data.text : '',\n title: title || data.text,\n };\n }\n if (data.type === 'attachment') {\n return {\n ...data,\n attached: data.attached || false,\n filled: data.filled || false,\n url: data.url || null,\n };\n }\n if (data.type === 'checkbox') {\n return {\n ...data,\n toolTip: data.fieldName,\n };\n }\n\n return {\n ...d,\n signed: false,\n filled: false,\n src: '',\n toolTip: 'Sign Here',\n };\n\n });\n return {\n page: pageNumber,\n path: p,\n pageData,\n };\n });\n });\n\n const envelopeRequiredFields = computed(() => {\n return envelopeData.value\n .flatMap(e => e.pageData) // Native `flatMap`\n .reduce((count, d) => count + (d.required ? 1 : 0), 0);\n });\n\n const envelopeSignatures = computed(() => {\n const data = esignEnvelopeDataCopy.value.flatMap((e) => e.pageData);\n let signatureCount = 0;\n data.forEach((d) => {\n if (d.type === 'signature') signatureCount++;\n });\n return signatureCount;\n });\n\n const remainingRequiredFields = computed(() => {\n const data = esignEnvelopeDataCopy.value.flatMap((e) => e.pageData);\n console.dir('remainingRequiredFields');\n console.dir(data.length);\n console.dir(data);\n\n return data.filter((field) => {\n if (!field.required) return false;\n\n switch (field.type) {\n case 'signature':\n return !field.signed;\n case 'field':\n case 'text':\n return !field.filled || (field.text?.trim().length === 0);\n case 'checkbox':\n return !field.value;\n case 'attachment':\n return !field.filled;\n default:\n return false;\n }\n });\n });\n\n\n function sendEnvelopeReminder(data: { envelope: EnvelopeInterface, email: string }) {\n store.dispatch('envelope/sendReminder', data);\n }\n\n const saveSignature = async (data: SaveSignaturePayload) => {\n return await store.dispatch('envelope/saveSignature', data);\n }\n\n const acceptAndSignEnvelope = async (data: AcceptEnvelopePayload) => {\n return await store.dispatch('envelope/acceptAndSignV2', data);\n }\n\n function setEnvelopeDialog(data: { key: string, value: boolean }) {\n store.commit('envelope/SET_ENVELOPE_DIALOG', data);\n }\n\n function updateEnvelopeField(data: ESignerFieldData) {\n store.commit('envelope/UPDATE_ENVELOPE_FIELD', data);\n }\n\n const setEsignSessionData = async (data: { key: string, value: any } | Record<string, any>) => {\n return store.commit('envelope/SET_ESIGN_SESSION_DATA', data);\n }\n\n\n const removeAttachment = async (data: RemoveAttachmentPayload) => {\n return await store.dispatch('envelope/removeAttachment', data);\n }\n\n const saveProgress = async (data: SaveProgressPayload) => {\n return await store.dispatch('envelope/saveProgress', data);\n }\n\n\n const getEnvelopeV2 = async (payload: {\n uuid: string,\n recipientId: string,\n recipientKey?: string,\n sample?: boolean\n }) => {\n return await store.dispatch('envelope/getEnvelopeV2', payload);\n }\n\n const createEnvelope = async (data: NewEnvelope) => {\n return await store.dispatch('envelope/createEnvelope', data);\n }\n\n const voidEnvelope = async (envelope: EnvelopeInterface) => {\n return await store.dispatch('envelope/voidEnvelope', envelope);\n }\n\n const getEnvelopes = async () => {\n return await store.dispatch('envelope/getEnvelopes');\n };\n\n const printProgress = async (envelope: EnvelopeInterface) => {\n return await store.dispatch('envelope/printProgress', envelope);\n }\n\n const downloadProgress = async (envelope: EnvelopeInterface) => {\n return await store.dispatch('envelope/downloadProgress', envelope);\n }\n\n const resendEnvelope = async (payload: { uuid: string, recipients: string[] }) => {\n return await store.dispatch('envelope/resendEnvelope', payload);\n }\n\n const resetEnvelopeData = async (uuid: string) => {\n return await store.dispatch('envelope/resetEnvelopeData', uuid);\n }\n\n const updateCustomerQuery = (query: { key: string, value: object | string | number }) => {\n store.commit('envelope/SET_ENVELOPE_QUERY', query);\n }\n\n return {\n envelope,\n envelopeLoading,\n envelopeDialogs,\n envelopes,\n envelopeForm,\n envelopesQuery,\n envelopesPagination,\n totalRemainingFields,\n envelopeIsReady,\n allEnvelopeData,\n envelopeDocumentImages,\n envelopeData,\n envelopeDocumentDimensionRatio,\n envelopeDocumentDimensions,\n envelopeStatus,\n completedEnvelopeUrl,\n envelopeRequiredFields,\n envelopeCustomer,\n envelopeCustomerData,\n esignSessionData,\n esignEnvelopeDataCopy,\n remainingRequiredFields,\n envelopeCompleted,\n envelopeCustomerCompleted,\n envelopeSignatures,\n updateEnvelopeField,\n acceptAndSignEnvelope,\n setEsignSessionData,\n getEnvelopeV2,\n updateCustomerQuery,\n setEnvelopeDialog,\n createEnvelope,\n saveSignature,\n sendEnvelopeReminder,\n getEnvelopes,\n voidEnvelope,\n printProgress,\n downloadProgress,\n resendEnvelope,\n resetEnvelopeData,\n removeAttachment,\n saveProgress,\n }\n}","<template>\n <v-card class=\"mt-5\">\n <v-card-text>\n <div class=\"\">\n <v-data-table-server\n v-model:options=\"dataTableOptions\"\n :headers=\"envelopesHeaders\"\n :items=\"envelopes\"\n :items-length=\"envelopesTotal\"\n :items-per-page=\"dataTableOptions.itemsPerPage\"\n :items-per-page-options=\"itemsPerPageOptions\"\n :items-per-page-text=\"'Contracts per page'\"\n :loading=\"envelopeLoading.envelopes\"\n :mobile-breakpoint=\"0\"\n >\n <template v-slot:body=\"props\">\n <tr v-for=\"(item, index) in props.items\" :key=\"index\" class=\"bg-white border-b dark:bg-gray-800 dark:border-gray-700 border-gray-200\">\n <th class=\"px-6 py-4 font-medium text-gray-900 whitespace-nowrap dark:text-white\" scope=\"row\">\n <div v-for=\"(recipient, key) in recipients(item)\" :key=\"key\" class=\"content-center\">\n <router-link v-if=\"renterId(recipient)\" :to=\"{name: 'customers.single', params: { r_id: renterId(recipient)}}\">\n {{ recipient.name }}\n </router-link>\n </div>\n </th>\n <td>\n <div class=\"content-center\">\n <v-chip :color=\"envelopeStatusText(item).color\" class=\"text-white\" size=\"x-small\">\n {{ envelopeStatusText(item).text }}\n </v-chip>\n <div v-if=\"item.completed_at\">{{ formatRentalDate(item.completed_at) }}</div>\n </div>\n </td>\n <td>\n <div class=\"content-center\">\n <v-btn v-if=\"item.file_path\" v-tippy :href=\"item.file_path\" content=\"Open in new window\" size=\"small\" target=\"_blank\" variant=\"text\">\n <v-icon size=\"small\">mdi-file-outline</v-icon>\n </v-btn>\n <v-btn v-else v-tippy :href=\"item.pdf_url\" content=\"Incomplete - Open in new window\" size=\"small\" target=\"_blank\" variant=\"text\">\n <v-icon size=\"small\">mdi-file-outline</v-icon>\n </v-btn>\n </div>\n </td>\n <td>\n <div class=\"content-center\">\n <span v-if=\"item.attachments.length === 0\"></span>\n <v-menu\n v-else\n v-model=\"item.attachmentsMenu\"\n :close-on-content-click=\"false\"\n >\n <template v-slot:activator=\"{ props }\">\n <v-btn\n v-bind=\"props\"\n variant=\"text\"\n >\n {{ item.attachments.length }}\n </v-btn>\n </template>\n\n <v-card max-width=\"300\">\n <v-list density=\"compact\">\n <template v-for=\"attachment in item.attachments\" :key=\"attachment.uuid\">\n <v-list-item v-if=\"attachmentImage(attachment)\" tile>\n <img :src=\"attachmentImage(attachment)\" alt=\"Attachment Image\" class=\"border\">\n </v-list-item>\n <v-list-item v-else tile>\n <template v-slot:prepend>\n <v-avatar\n color=\"primary\"\n size=\"25\"\n >\n <v-icon size=\"sma\">\n mdi-file-outline\n </v-icon>\n </v-avatar>\n </template>\n\n <template v-slot:append>\n <v-btn :href=\"attachment.url\" target=\"_blank\" variant=\"text\">\n <v-icon size=\"small\">mdi-open-in-new</v-icon>\n </v-btn>\n </template>\n\n <template v-slot:subtitle>\n {{ attachment.attachment_id }}\n </template>\n\n <template v-slot:title>\n {{ attachment.name }}\n </template>\n </v-list-item>\n\n\n </template>\n </v-list>\n </v-card>\n </v-menu>\n </div>\n </td>\n <td>\n <div class=\"content-center\">\n <span v-if=\"item.created_at\">{{ formatRentalDate(item.created_at) }}</span>\n </div>\n </td>\n <td>\n <div class=\"content-center\">\n <v-menu>\n <template v-slot:activator=\"{ props }\">\n <v-btn\n size=\"small\"\n v-bind=\"props\"\n variant=\"text\"\n >\n <v-icon>mdi-dots-vertical</v-icon>\n </v-btn>\n </template>\n <v-list>\n <v-list-item v-if=\"item.file_path\" @click=\"openInNewTab(item.file_path)\">\n <v-list-item-title>\n <v-icon class=\"mr-1\" size=\"small\">mdi-download</v-icon>\n Download PDF\n </v-list-item-title>\n </v-list-item>\n <v-list-item v-else @click=\"openInNewTab(item.pdf_url)\">\n <v-list-item-title>\n <v-icon class=\"mr-1\" size=\"small\">mdi-download</v-icon>\n Download Template Used\n </v-list-item-title>\n </v-list-item>\n <!-- <v-list-item>-->\n <!-- <v-list-item-title>-->\n <!-- <v-icon size=\"small\" class=\"mr-1\">mdi-eye</v-icon>-->\n <!-- Preview-->\n <!-- </v-list-item-title>-->\n <!-- </v-list-item>-->\n <v-list-item :disabled=\"!hasPendingSigners(item) || envelopeVoided(item)\" @click=\"openReminderDialog(item)\">\n <v-list-item-title>\n <v-icon class=\"mr-1\" size=\"small\">mdi-email-outline</v-icon>\n Send Reminder\n </v-list-item-title>\n </v-list-item>\n <v-list-item :disabled=\"envelopeVoided(item)\" @click=\"openVoidEnvelopeDialog(item)\">\n <v-list-item-title>\n <v-icon class=\"mr-1\" size=\"small\">mdi-close-circle-outline</v-icon>\n Void\n </v-list-item-title>\n </v-list-item>\n <v-list-item @click=\"openEnvelopInfoDialog(item)\">\n <v-list-item-title>\n <v-icon class=\"mr-1\" size=\"small\">mdi-information-outline</v-icon>\n View Info\n </v-list-item-title>\n </v-list-item>\n </v-list>\n </v-menu>\n </div>\n </td>\n </tr>\n </template>\n </v-data-table-server>\n </div>\n </v-card-text>\n </v-card>\n\n <v-dialog v-model=\"voidEnvelopeDialog\" max-width=\"400\">\n <v-card :loading=\"envelopeLoading.voiding\">\n <v-card-title class=\"text-h5\">Are you sure?</v-card-title>\n <v-divider class=\"opacity-50\"></v-divider>\n <v-card-text>\n Are you sure you want to void this envelope?\n\n <v-alert v-if=\"envelopeForm.errors.any()\" class=\"mt-5\" color=\"red\" density=\"compact\">\n <strong>There was an error:</strong>\n {{ envelopeForm.errors.flatten()[0] }}\n </v-alert>\n </v-card-text>\n\n <v-divider class=\"opacity-50\"></v-divider>\n\n <v-card-actions>\n <v-spacer/>\n\n <v-btn :disabled=\"envelopeLoading.voiding\" color=\"grey\" size=\"small\" variant=\"text\" @click=\"voidEnvelopeDialog = false; envelopeForm.errors.clear();\">\n Nevermind\n </v-btn>\n\n <v-btn :disabled=\"envelopeLoading.voiding || envelopeForm.errors.any()\" color=\"red text-white\" @click=\"voidEnvelopeCommit(currentWorkingEnvelope)\">\n Void\n </v-btn>\n </v-card-actions>\n </v-card>\n </v-dialog>\n\n <v-dialog v-model=\"reminderDialog\" aria-label=\"Send Reminder\" max-width=\"600\">\n <v-card :disabled=\"envelopeLoading.reminder\" :loading=\"envelopeLoading.reminder\">\n <v-card-title>Send Reminder</v-card-title>\n <v-divider class=\"opacity-50\"/>\n <v-card-text>\n <div class=\"my-2\">This is the name that will be used in the emails/sms sent to your guests.</div>\n <v-checkbox\n v-for=\"(reminder, index) in reminderData.recipients\"\n :key=\"index\"\n v-model=\"reminder.send\"\n :label=\"reminder.label\"\n hide-details\n >\n </v-checkbox>\n </v-card-text>\n <v-divider class=\"opacity-50\"/>\n <v-card-actions>\n <v-spacer/>\n <v-btn :disabled=\"envelopeLoading.reminder\" color=\"grey\" size=\"small\" variant=\"text\" @click=\"reminderDialog = false\">\n Nevermind\n </v-btn>\n <v-btn :disabled=\"sendReminderReady\" :loading=\"envelopeLoading.reminder\" color=\"primary text-white\" @click=\"sendReminderInit()\">\n Send\n </v-btn>\n </v-card-actions>\n </v-card>\n </v-dialog>\n\n <v-dialog v-model=\"envelopInfoDialog\" max-width=\"600\">\n <v-card :disabled=\"documentsLoading.saving\" :loading=\"documentsLoading.saving\">\n <v-card-title>Info</v-card-title>\n <v-card-text>\n <div class=\"mb-5\">\n <v-chip :color=\"envelopeStatusText(currentWorkingEnvelope).color\" size=\"x-small\">\n <span>{{ envelopeStatusText(currentWorkingEnvelope).text }}</span>\n </v-chip>\n </div>\n\n <div>\n <div v-for=\"recipient in currentWorkingEnvelopeRecipients\" :key=\"recipient.uuid\">\n <div class=\"flex\">\n <div v-if=\"recipient.completed_at\">\n <v-icon v-tippy :content=\"`Signed at ${recipient.completed_at}`\" class=\"mr-1\" size=\"small\">mdi-check\n </v-icon>\n </div>\n <div v-else-if=\"recipient.opened_at\">\n <v-icon v-tippy :content=\"`Opened at ${recipient.opened_at}`\" class=\"mr-1\" size=\"small\">mdi-eye\n </v-icon>\n </div>\n <div v-else>\n <v-icon v-tippy :content=\"`Waiting`\" class=\"mr-1\" size=\"small\">mdi-clock-outline</v-icon>\n </div>\n <div>\n {{ recipient.renter.full_name }}\n ({{ recipient.recipient }})\n </div>\n </div>\n </div>\n </div>\n\n <div>\n <div v-for=\"(signature, key) in envelopeRecipientSignatures(currentWorkingEnvelope)\" :key=\"key\">\n <div v-if=\"signature.signature\" class=\"border rounded my-1 p-1\">\n <v-menu\n v-if=\"signature.signature\"\n v-model=\"signature.largerSignature\"\n :close-on-content-click=\"false\"\n open-on-hover\n >\n <template v-slot:activator=\"{ props }\">\n <v-img :src=\"signature.signature\" height=\"50\" v-bind=\"props\" width=\"100\"></v-img>\n <small>{{ signature.name }}</small>\n </template>\n\n <v-card>\n <v-card-text>\n <v-img :src=\"signature.signature\" height=\"200\"></v-img>\n <small>{{ signature.name }}</small>\n </v-card-text>\n </v-card>\n </v-menu>\n </div>\n </div>\n </div>\n </v-card-text>\n <v-card-actions>\n <v-spacer/>\n <v-btn :disabled=\"documentsLoading.saving\" color=\"grey\" size=\"small\" variant=\"text\" @click=\"envelopInfoDialog = false\">\n Okay\n </v-btn>\n </v-card-actions>\n </v-card>\n </v-dialog>\n</template>\n\n<script lang=\"ts\" setup>\nimport {computed, ref, watch} from 'vue';\nimport {useEnvelope} from \"@/composables/useEnvelope\";\nimport {useStore} from 'vuex';\nimport {useDateFormatter} from \"@/composables/useDate\";\nimport {EnvelopeInterface} from \"@/store/modules/envelope\";\nimport {RenterInterface} from \"@/types\";\n\nconst store = useStore();\nconst {\n envelopeForm,\n envelopeLoading,\n envelopes,\n envelopesQuery,\n envelopesPagination,\n sendEnvelopeReminder,\n voidEnvelope,\n getEnvelopes,\n updateCustomerQuery,\n} = useEnvelope();\nconst {formatRentalDate} = useDateFormatter();\n\nconst documentsLoading = computed(() => store.getters['document/loading']);\n\nconst envelopesTotal = computed(() => envelopesPagination.value.total);\n\nconst currentWorkingEnvelope = ref<EnvelopeInterface>(null);\nconst envelopInfoDialog = ref(false);\nconst voidEnvelopeDialog = ref(false);\nconst reminderDialog = ref(false);\n\nconst currentWorkingEnvelopeRecipients = computed(() => {\n return currentWorkingEnvelope.value.recipients;\n});\n\nconst dataTableOptions = ref({\n page: 1,\n itemsPerPage: 25,\n sortBy: ['created_at'],\n sortDesc: [true],\n status: 'all',\n});\nconst envelopeVoided = (envelope: EnvelopeInterface) => {\n return envelope.status === 'voided';\n};\n\nconst sendReminderReady = computed(() => {\n return reminderData.value.recipients.length === 0 || reminderData.value.recipients.every(r => !r.send);\n});\n\nconst itemsPerPageOptions = [\n {value: 10, title: '10'},\n {value: 25, title: '25'},\n {value: 50, title: '50'},\n {value: 100, title: '100'},\n {value: -1, title: '$vuetify.dataFooter.itemsPerPageAll'}\n];\n\nconst envelopesHeaders = ref([\n {title: 'Customers', key: 'renter', sortable: false},\n {title: 'Status', key: 'status', sortable: false},\n // { text: 'Opened', value: 'opened', width: 100 },\n // { text: 'Completed', value: 'completed_at', width: 200 },\n // { text: 'Signatures', value: 'signature' },\n {title: 'Files', key: 'pdf_url', sortable: false},\n {title: 'Attachments', key: 'attachments', width: 125, sortable: false},\n {title: 'Created', key: 'created_at', width: 200},\n {title: '', sortable: false, key: 'uuid'},\n]);\n\nconst reminderData = ref({\n recipients: [],\n});\n\nwatch(() => dataTableOptions.value.page, (newPage) => {\n updateCustomerQuery({key: 'page', value: newPage});\n getEnvelopes();\n});\n\nwatch(() => dataTableOptions.value.itemsPerPage, (newItemsPerPage) => {\n updateCustomerQuery({key: 'itemsPerPage', value: newItemsPerPage});\n getEnvelopes();\n});\n\nwatch(() => dataTableOptions.value.sortBy, (newSort) => {\n updateCustomerQuery({key: 'sortBy', value: [newSort?.[0]?.['key']]});\n updateCustomerQuery({key: 'sortDesc', value: [newSort?.[0]?.['order'] === 'desc']});\n getEnvelopes();\n});\n\nwatch(dataTableOptions, (val) => {\n // if there is no status filter, then we need to reset the page to 1\n if (!val.status) {\n dataTableOptions.value.status = 'all';\n }\n});\n\nconst recipients = (envelope: EnvelopeInterface) => {\n // Check if there are no recipients in the envelope\n if (!envelope.recipients?.length) {\n return [{\n name: renterFullName(envelope.renter),\n r_id: envelope.renter?.r_id,\n }];\n }\n\n // Process each recipient to extract their details\n return envelope.recipients.map(recipient => ({\n name: renterFullName(recipient.renter),\n r_id: recipient.renter?.r_id,\n }));\n};\n\nconst renterFullName = (renter: RenterInterface) => {\n const name = renter?.full_name;\n if (name) {\n return name;\n }\n return `${renter?.first_name} ${renter?.last_name}`.trim();\n};\n\nconst renterId = (renter: { name: string, r_id: string }) => {\n return renter.r_id;\n};\n\n\nconst envelopeStatusText = (envelope: EnvelopeInterface) => {\n if (envelope.status === 'init') return {text: \"Init\", color: \"purple\"};\n if (envelope.status === 'voided') return {text: \"Voided\", color: \"red\"};\n if (envelope.status === 'in_progress') return {text: \"In Progress\", color: \"blue\", textColor: \"black\"};\n if (envelope.status === 'expired') return {text: \"Expired\", color: \"red\"};\n if (envelope.status === 'pending') return {text: \"Expired\", color: \"blue\"};\n if (envelope.recipients?.some(r => !r.completed_at)) return {text: \"Pending signature\", color: \"orange\"};\n if (envelope.completed_at) return {text: \"Completed\", color: \"green\"};\n return {text: envelope.status, color: \"gray\"};\n};\n\nconst envelopeRecipientSignatures = (envelope: EnvelopeInterface) => {\n // Check if there are no recipients in the envelope\n if (!envelope.recipients?.length) {\n return [{\n signature: envelope.signature,\n recipient: envelope.renter?.full_name ?? 'Unknown Renter',\n name: envelope.renter?.full_name ?? 'Unknown Renter',\n }];\n }\n\n // Process each recipient to extract signature information\n return envelope.recipients.map(recipient => ({\n signature: recipient.signature,\n recipient: recipient.recipient,\n name: recipient.renter?.full_name ?? 'Unknown Renter',\n }));\n};\n\nconst attachmentImage = (attachment) => {\n return attachment?.document_images?.[0];\n};\n\nconst openInNewTab = (url) => {\n window.open(url, '_blank', 'noreferrer');\n};\n\nconst hasPendingSigners = (envelope: EnvelopeInterface) => {\n return pendingSigners(envelope).length > 0;\n};\n\nconst pendingSigners = (envelope: EnvelopeInterface) => {\n return envelope.recipients.filter((r) => !r.completed_at);\n};\nconst openEnvelopInfoDialog = (envelope: EnvelopeInterface) => {\n currentWorkingEnvelope.value = envelope;\n envelopInfoDialog.value = true;\n};\n\nconst openVoidEnvelopeDialog = (envelope: EnvelopeInterface) => {\n currentWorkingEnvelope.value = envelope;\n voidEnvelopeDialog.value = true;\n};\n\n\nconst openReminderDialog = (envelope: EnvelopeInterface) => {\n currentWorkingEnvelope.value = envelope;\n\n const pendingSignersData = pendingSigners(envelope);\n\n if (pendingSignersData.length === 0) {\n return alert(\"No pending signers for this envelope!\");\n }\n\n reminderData.value.recipients = pendingSignersData.map(signer => ({\n email: signer.recipient,\n label: `${signer.renter?.full_name ?? 'Unknown Name'} (${signer.recipient})`,\n send: true,\n }));\n\n reminderDialog.value = true;\n};\n\nconst voidEnvelopeCommit = async (envelope: EnvelopeInterface) => {\n await voidEnvelope(envelope);\n voidEnvelopeDialog.value = false;\n currentWorkingEnvelope.value = null;\n\n // Wait before fetching new data\n setTimeout(() => getEnvelopes(), 300);\n};\n\nconst sendReminderInit = () => {\n reminderData.value.recipients.forEach((r) => {\n if (r.send) {\n sendEnvelopeReminder({\n envelope: currentWorkingEnvelope.value,\n email: r.email,\n });\n }\n });\n};\n</script>\n","import {useStore} from 'vuex';\nimport {computed} from 'vue';\nimport {default as dayjs} from 'dayjs';\nimport isSameOrBefore from 'dayjs/plugin/isSameOrBefore';\nimport {pluralize} from \"@/utils/text\";\n\ndayjs.extend(isSameOrBefore);\n\n\nexport function useSubscription() {\n const store = useStore();\n\n\n const enforceSubscription = computed(() => store.getters['subscriptions/enforceSubscription']);\n const customersLoading = computed(() => store.getters['renters/rentersLoading']);\n\n const hasActiveSubscription = computed(() => store.getters['subscriptions/hasActiveSubscription']);\n const subscriptionPlans = computed(() => store.getters['subscriptions/plans']);\n const subscriptionPlan = computed(() => store.getters['subscriptions/subscriptionPlan']);\n const subscription = computed(() => store.getters['subscriptions/subscription']);\n const user = computed(() => store.getters['auth/user']);\n const company = computed(() => store.getters['company/company']);\n const stripeSubscriptionObject = computed(() => store.getters['stripe/stripeSubscriptionObject']);\n const subscriptionsLoading = computed(() => store.getters['subscriptions/loading']);\n const subscriptionEndDate = computed(() => store.getters['subscriptions/subscriptionEndDate']);\n const hasPastDueSubscription = computed(() => store.getters['subscriptions/hasPastDueSubscription']);\n const hasPausedSubscription = computed(() => store.getters['subscriptions/hasPausedSubscription']);\n\n const stripeTrialDate = computed(() => subscription.value?.trial_ends_at);\n\n const subscriptionFeatures = {\n seats: {\n basic: 2,\n standard: 5,\n premium: 20,\n },\n listings: {\n basic: 5,\n standard: 50,\n premium: 150,\n },\n locations: {\n basic: 1,\n standard: 2,\n premium: 2,\n },\n carSharingConnections: {\n basic: 1,\n standard: 5,\n premium: 10,\n },\n smartCarConnections: {\n basic: 1,\n standard: 5,\n premium: 10,\n },\n orders: {\n basic: 5,\n standard: 50,\n premium: 20,\n },\n }\n\n const subscriptionStatus = computed(() => {\n const stripeStatus = subscription.value?.stripe_status;\n\n if (stripeStatus) return stripeStatus;\n\n if (user.value?.on_trial) return 'trialing';\n\n return 'inactive';\n });\n\n const trialEndDateRaw = computed(() => {\n return company.value?.trial_ends_at ?? stripeTrialDate.value;\n });\n\n const planIncludes = {\n premium: {\n api: true,\n sso: true,\n coupons: true,\n additional_scripts: true,\n custom_domain: true,\n custom_tos: true,\n listing_exports: true,\n listing_imports: true,\n esign: true,\n webhooks: true,\n barcodes: true,\n custom_checkout_fields: true,\n },\n standard: {\n sso: true,\n coupons: true,\n custom_tos: true,\n listing_exports: true,\n listing_imports: true,\n esign: true,\n barcodes: true,\n custom_checkout_fields: true,\n },\n basic: {\n // esign: true,\n },\n }\n\n\n const cancelSubscription = async () => {\n return store.dispatch('subscriptions/cancelSubscription');\n }\n\n const cancelSubscriptionStripePortal = async () => {\n return store.dispatch('subscriptions/cancelSubscriptionStripePortalUrl');\n }\n\n const endTrial = async () => {\n return store.dispatch('subscriptions/endTrial');\n }\n\n const switchPlan = async (plan: string) => {\n return store.dispatch('subscriptions/switchPlan', plan);\n }\n\n const resumeSubscription = async () => {\n return store.dispatch('subscriptions/resumeSubscription');\n }\n\n const addSubscriptionAddon = async (addon: string) => {\n return store.dispatch('subscriptions/addAddon', addon);\n }\n const removeSubscriptionAddon = async (addon: string) => {\n return store.dispatch('subscriptions/removeAddon', addon);\n }\n\n const trialEndsMessage = computed(() => {\n const rawDate = trialEndDateRaw.value;\n\n // Check if rawDate is valid\n if (!rawDate || !dayjs(rawDate).isValid() || subscriptionStatus.value === 'active') {\n return 'Trial has ended';\n }\n\n const trialDate = dayjs(rawDate);\n const trialDateFmt = trialDate.format('MMMM D, YYYY');\n\n // Determine if the trial has already ended\n const status = trialDate.isSameOrBefore(dayjs()) ? 'ended' : 'ends';\n\n return `Trial ${status} ${trialDateFmt}`;\n });\n\n const stripeEndDate = computed(() => {\n const ends_at = subscription.value?.ends_at;\n if (!ends_at) return;\n return dayjs(ends_at).format('MMMM D, YYYY');\n });\n\n const inGracePeriod = computed(() => {\n const endDate = subscription.value?.ends_at;\n const status = subscriptionStatus.value;\n\n if (!endDate) return false;\n\n return !(status === 'canceled' && dayjs(endDate).diff(dayjs()) <= 0);\n });\n\n\n const inTrial = computed((): boolean => {\n const trialDate = user?.value?.on_trial;\n\n if (trialDate) return true;\n\n if (subscriptionStatus.value === 'trialing') return true;\n if (subscriptionStatus.value === 'active') return false;\n\n if (stripeTrialDate.value) {\n return dayjs(stripeTrialDate.value).diff(dayjs()) > 0;\n }\n\n return false;\n });\n\n const isTrialing = computed((): boolean => {\n return subscriptionStatus.value === 'trialing';\n })\n\n const trialEndDate = computed(() => {\n\n if (!trialEndDateRaw.value) {\n return 'N/A';\n }\n\n return dayjs(trialEndDateRaw.value).format('MMMM D, YYYY');\n });\n\n\n const currentStripeSubscriptionObjectRenewalDate = computed(() => {\n const date = stripeSubscriptionObject.value?.current_period_end;\n const status = stripeSubscriptionObject.value?.status;\n\n if (!date) return null;\n if (status === 'canceled') return null;\n\n return dayjs(date * 1000).format('MMMM D, YYYY');\n });\n\n const currentStripeSubscriptionObjectPlanAmount = computed(() => {\n const amount = stripeSubscriptionObject.value?.plan?.amount;\n\n if (!amount) return '$0';\n\n if (amount % 100 === 0) {\n return `$${(amount * 0.01).toFixed(0)}`;\n }\n\n return `$${(amount * 0.01).toFixed(2)}`;\n });\n\n const currentStripeSubscriptionObjectPlanInterval = computed(() => {\n return stripeSubscriptionObject.value?.plan?.interval ?? 'month';\n });\n\n const includedInSubscription = (topic: string): boolean => {\n if (!enforceSubscription.value || inTrial.value) return true;\n if (!hasActiveSubscription.value) return false;\n\n // Safely get the subscription plan in lowercase\n const plan = subscriptionPlan.value?.toLowerCase() || '';\n\n // Ensure plan exists in planIncludes\n const planFeatures = planIncludes[plan] ?? null;\n if (!planFeatures) return false;\n\n // Check if the topic is included in the plan\n return planFeatures[topic] ?? false;\n };\n\n\n const planIncludesApi = computed(() => {\n if (!enforceSubscription.value) return true;\n\n if (inTrial.value && !hasActiveSubscription.value) {\n return true;\n }\n\n if (!hasActiveSubscription.value) {\n return false;\n }\n\n return planIncludes?.[subscriptionPlan.value]?.api ?? false;\n })\n\n\n const trialDaysLeft = computed((): number => {\n\n if (!trialEndDateRaw.value) {\n return 0;\n }\n\n const daysLeft = dayjs(trialEndDateRaw.value).diff(dayjs(), 'days', true);\n return daysLeft > 0 ? Math.ceil(daysLeft) : 0; // Round up\n })\n\n const trialDaysLeftPercent = computed((): number => {\n return trialDaysLeft.value === 0 ? 0 : Math.round((trialDaysLeft.value / 14) * 100);\n });\n\n const trialDaysLeftMessage = computed((): string => {\n if (hasActiveSubscription.value) {\n const plan = subscriptionPlan.value\n ? `${subscriptionPlan.value.charAt(0).toUpperCase()}${subscriptionPlan.value.slice(1)}`\n : 'Unknown';\n return `Membership: ${plan} Plan`;\n }\n if (trialDaysLeft.value <= 0) {\n return 'Your trial has ended';\n }\n return `You have ${trialDaysLeft.value} ${pluralize(trialDaysLeft.value, 'day')} left on your trial.`;\n })\n\n const trialDaysClass = computed(() => ({\n 'text-danger': trialDaysLeft.value === 0,\n 'text-warning': trialDaysLeft.value < 2,\n }));\n\n const currentPlanDetails = computed(() => {\n return subscriptionPlans.value.find((p) => p.name === subscriptionPlan.value);\n });\n\n const currentPlanBullets = computed(() => {\n return currentPlanDetails.value?.description.bullets;\n });\n\n const seatLimitReached = computed(() => {\n if (!enforceSubscription.value) return false;\n\n if (inTrial.value && !hasActiveSubscription.value) {\n return false;\n }\n\n if (!hasActiveSubscription.value) {\n return true;\n }\n\n return (currentPlanDetails.value?.seats !== -1)\n && company.value?.seat_count >= currentPlanDetails.value?.seats;\n })\n\n const seatLimitReachedMessage = computed(() => {\n if (!enforceSubscription.value) return 'You need a subscription plan to add seats.';\n return `You've reached your max seats of <b>${currentPlanDetails.value?.seats}</b> for your plan.`;\n });\n\n\n const listingLimitReachedMessage = computed(() => {\n if (!enforceSubscription.value) return 'You need a subscription plan to add listings.';\n return `You've reached your max listings of <b>${currentPlanDetails.value?.listings}</b> for your plan.`;\n });\n\n const listingLimitReached = computed(() => {\n if (!enforceSubscription.value) return false;\n\n if (inTrial.value && !hasActiveSubscription.value) {\n return false;\n }\n\n if (!hasActiveSubscription.value) {\n return true;\n }\n\n return (currentPlanDetails.value?.listings !== -1)\n && company.value?.listings >= currentPlanDetails.value?.listings;\n });\n\n const planSupportedFeatureCounts = computed(() => {\n const plan = subscriptionPlan.value;\n\n return {\n listings: subscriptionFeatures.listings[plan],\n locations: subscriptionFeatures.locations[plan],\n carSharingConnections: subscriptionFeatures.carSharingConnections[plan],\n smartCarConnections: subscriptionFeatures.smartCarConnections[plan],\n orders: subscriptionFeatures.orders[plan],\n seats: subscriptionFeatures.seats[plan],\n }\n });\n\n return {\n subscription,\n seatLimitReached,\n seatLimitReachedMessage,\n subscriptionEndDate,\n currentPlanBullets,\n subscriptionsLoading,\n hasActiveSubscription,\n hasPausedSubscription,\n subscriptionStatus,\n subscriptionPlan,\n subscriptionPlans,\n enforceSubscription,\n customersLoading,\n inTrial,\n isTrialing,\n planIncludesApi,\n trialEndDate,\n currentStripeSubscriptionObjectRenewalDate,\n currentStripeSubscriptionObjectPlanAmount,\n currentStripeSubscriptionObjectPlanInterval,\n stripeEndDate,\n inGracePeriod,\n trialDaysLeftMessage,\n trialDaysLeft,\n trialDaysLeftPercent,\n trialDaysClass,\n trialEndsMessage,\n listingLimitReachedMessage,\n listingLimitReached,\n hasPastDueSubscription,\n planSupportedFeatureCounts,\n currentPlanDetails,\n addSubscriptionAddon,\n removeSubscriptionAddon,\n resumeSubscription,\n endTrial,\n switchPlan,\n cancelSubscription,\n cancelSubscriptionStripePortal,\n includedInSubscription,\n }\n}","<template>\n <div>\n <v-tabs v-model=\"documentsTab\">\n <v-tab>Contracts</v-tab>\n <v-tab>Invoices</v-tab>\n <v-tab v-if=\"userHasRole('beta-tester-1')\">Quotes</v-tab>\n </v-tabs>\n\n <v-window v-model=\"documentsTab\">\n <v-window-item>\n <div class=\"mx-5 mt-5\">\n <v-expansion-panels style=\"border-top: none;\">\n <v-expansion-panel>\n <v-expansion-panel-title>\n <template v-slot:default=\"{ expanded }\">\n <div class=\"grid grid-cols-4 gap-2\">\n <div class=\"col-4\">\n Templates\n </div>\n <div class=\"col-8\">\n <v-fade-transition hide-on-leave>\n <div v-if=\"!expanded\">\n ({{ validTemplates.length }} {{ $t('templates') }})\n </div>\n </v-fade-transition>\n </div>\n </div>\n </template>\n\n </v-expansion-panel-title>\n <v-expansion-panel-text>\n <v-card :loading=\"documentsLoading.get\" variant=\"flat\">\n <the-help-link url=\"https://help.fleetwire.io/en/article/what-is-automatic-e-sign-1o5wfxk/\"/>\n <v-alert v-if=\"!includedInSubscription('esign')\" border=\"bottom\" class=\"card-alert-full\" density=\"compact\" type=\"warning\">\n You plan does not include eSign rental agreements.\n <v-btn :to=\"{name: 'settings.account'}\" class=\"float-right\" size=\"x-small\">Upgrade</v-btn>\n </v-alert>\n\n <v-card-title>\n <div class=\"flex\">\n Document Templates\n <v-btn size=\"small\" variant=\"text\" @click=\"learnMoreDialog = true;\">\n <v-icon size=\"small\">mdi-help-circle</v-icon>\n </v-btn>\n <v-spacer/>\n <v-btn :disabled=\"!planIncludesESign\" class=\"mt-2\" size=\"small\" @click=\"createTemplateInit()\">\n <v-icon class=\"mr-1\" size=\"small\">mdi-plus</v-icon>\n {{ $t('template') }}\n </v-btn>\n </div>\n </v-card-title>\n <v-card-text>\n <TemplatesTableList :templates=\"templates\"/>\n </v-card-text>\n </v-card>\n </v-expansion-panel-text>\n </v-expansion-panel>\n </v-expansion-panels>\n </div>\n\n\n <ContractsTable/>\n </v-window-item>\n <v-window-item>\n <v-card>\n <div class=\"grid grid-cols-3 gap-2 mx-4 my-10\">\n <div>\n <v-card>\n <v-card-title>\n Number of Invoices\n </v-card-title>\n <v-card-text>\n {{ orderDocumentsInvoicesFiltered.length }}\n </v-card-text>\n </v-card>\n </div>\n <div>\n <v-card>\n <v-card-title>\n Paid Amount\n </v-card-title>\n <v-card-text>\n {{ formatMoneyDisplayV2(invoicePaidAmount) }}\n </v-card-text>\n </v-card>\n </div>\n <div>\n <v-card>\n <v-card-title>\n Turnover\n </v-card-title>\n <v-card-text>\n {{ formatMoneyDisplayV2(invoiceTotalAmount) }}\n </v-card-text>\n </v-card>\n </div>\n </div>\n <div v-if=\"orderDocumentsInvoicesFiltered.length === 0\" class=\"text-center border rounded p-4\">\n No Invoices found\n </div>\n <v-data-table\n v-else\n :headers=\"orderDocumentsHeaders\"\n :items=\"orderDocumentsInvoicesFiltered\"\n :items-per-page=\"50\"\n :mobile-breakpoint=\"0\"\n >\n <template v-slot:item.title=\"{ item }\">\n <div class=\"h-100 content-center\">\n <router-link :to=\"{name: 'documents.show', params: { uuid: item.uuid}}\">\n {{ item.title }}\n </router-link>\n </div>\n </template>\n <template v-slot:item.order=\"{ item }\">\n <div class=\"h-100 content-center\">\n <router-link v-if=\"item?.order?.b_id \" :to=\"{name: 'orders.single', params: { b_id: item?.order?.b_id }}\">\n {{ item?.order?.b_id }}\n </router-link>\n </div>\n </template>\n <template v-slot:item.customer=\"{ value }\">\n <div class=\"h-100 content-center\">\n <router-link v-if=\"value?.r_id\" :to=\"{name: 'customers.single', params: { r_id: value.r_id }}\">\n {{ value.r_id }}\n </router-link>\n </div>\n </template>\n <template v-slot:item.paid_in_cents=\"{ item }\">\n <div class=\"h-100 content-center\">\n {{ formatMoneyDisplayV2(item.paid_in_cents) }}\n </div>\n </template>\n <template v-slot:item.grand_total_with_tax_in_cents=\"{ item }\">\n <div class=\"h-100 content-center\">\n {{ formatMoneyDisplayV2(item.grand_total_with_tax_in_cents) }}\n </div>\n </template>\n <template v-slot:item.status=\"{ value }\">\n <div class=\"h-100 content-center\">\n {{ value }}\n </div>\n </template>\n <template v-slot:item.date=\"{ value }\">\n <div class=\"h-100 content-center\">\n {{ value }}\n </div>\n </template>\n <template v-slot:item.confirmed=\"{ value }\">\n <div class=\"h-100 content-center\">\n {{ value }}\n </div>\n </template>\n </v-data-table>\n </v-card>\n </v-window-item>\n <v-window-item>\n <v-card>\n <div v-if=\"orderDocuments.length === 0\" class=\"text-center border rounded p-4\">\n No contracts found\n </div>\n <v-data-table\n v-else\n :headers=\"orderDocumentsHeaders\"\n :items=\"orderDocumentsQuotesFiltered\"\n :items-per-page=\"50\"\n :mobile-breakpoint=\"0\"\n >\n <template v-slot:item.title=\"{ item }\">\n <router-link :to=\"{name: 'documents.show', params: { uuid: item.uuid}}\">\n {{ item.title }}\n </router-link>\n </template>\n <template v-slot:item.customer=\"{ item }\">\n <router-link :to=\"{name: 'customers.single', params: { r_id: renterId(item.customer)}}\">\n {{ renterName(item.customer) }}\n </router-link>\n </template>\n <template v-slot:item.grand_total_in_cents=\"{ item }\">\n ${{ formatMoney(item.grand_total_in_cents) }}\n </template>\n <template v-slot:item.grand_total_with_tax_in_cents=\"{ item }\">\n ${{ formatMoney(item.grand_total_with_tax_in_cents) }}\n </template>\n </v-data-table>\n </v-card>\n </v-window-item>\n </v-window>\n\n <v-dialog v-model=\"learnMoreDialog\" max-width=\"600\">\n <v-card>\n <v-card-title class=\"text-h5\">What are document templates?</v-card-title>\n <v-card-text>\n <div>\n Here you can upload a document and insert variable placeholders that will automatically fill in once a\n customer makes a reservation. These are called document templates. You can set up placeholders such as name,\n email, booking dates, vehicle info, signatures, attachments, etc. Once customers book a vehicle, Fleetwire\n can email them a link to their e-sign envelope. We will email you a complete copy for your records upon\n completion.\n </div>\n </v-card-text>\n <v-card-actions>\n <TheHelpLink url=\"https://help.fleetwire.io/en/article/esign-1o5wfxk/?bust=1643742268392\"/>\n <v-spacer/>\n <v-btn @click=\"learnMoreDialog = false;\">\n {{ $t('okay') }}\n </v-btn>\n </v-card-actions>\n </v-card>\n </v-dialog>\n\n\n </div>\n</template>\n\n<script lang=\"ts\">\nimport {defineAsyncComponent, ref, watch} from 'vue';\nimport {mapActions, mapGetters, useStore} from 'vuex';\nimport {EventBus} from '@/plugins/eventBus';\nimport {Form} from '@/plugins/FWForms/index';\nimport subscriptionMixin from '@/mixins/subscription';\nimport {useDateFormatter} from '@/composables/useDate';\nimport {useMoneyFormatter} from '@/composables/useMoneyFormatter';\nimport {useAppSettings} from '@/composables/useAppSettings';\nimport {useEnvelope} from '@/composables/useEnvelope';\nimport ContractsTable from '@/views/documents/ContractsTable.vue';\nimport {RenterInterface} from '@/types';\nimport {useSubscription} from '@/composables/useSubscription';\nimport {useTemplate} from '@/composables/useTemplate';\n\nconst TemplatesTableList = defineAsyncComponent(() => import('@/components/dashboard/documents/TemplatesTableList.vue'));\n\n\nexport default {\n name: 'TheDocumentsDashboardHome',\n\n setup() {\n const store = useStore();\n const {formatMoneyDisplayV2, formatMoney} = useMoneyFormatter();\n const {formatRentalDate} = useDateFormatter();\n const {sendEnvelopeReminder, voidEnvelope, getEnvelopes} = useEnvelope();\n const {includedInSubscription} = useSubscription();\n const {fetchTemplates} = useTemplate();\n\n const {userHasRole} = useAppSettings();\n\n\n const documentsTab = ref(0);\n const learnMoreDialog = ref(false);\n const envelopInfoDialog = ref(false);\n const voidEnvelopeDialog = ref(false);\n const dataTableOptionStatus = ref('all');\n\n\n const orderDocumentsHeaders = [\n {title: 'Title', sortable: false, key: 'title'},\n {title: 'Booking', key: 'order'},\n {title: 'Customer', key: 'customer'},\n {title: 'Status', key: 'status'},\n {title: 'Date', key: 'date'},\n {title: 'Total w/tax', key: 'grand_total_with_tax_in_cents'},\n {title: 'Paid', key: 'paid_in_cents'},\n {title: 'Confirmed', key: 'confirmed'},\n ];\n\n\n const reminderData = ref({\n recipients: [],\n });\n\n watch(documentsTab, (val) => {\n console.dir(val);\n if (val === 1) {\n store.dispatch('order/getAllOrderDocuments');\n }\n });\n\n\n const envelopesFilter = ref({\n complete: 'all',\n });\n\n const nameChangeErrors = ref([]);\n\n\n const reminderDialog = ref(false);\n\n const currentWorkingEnvelope = ref({});\n\n const form = ref(new Form());\n\n\n const envelopeVoided = (envelope) => {\n return envelope.status === 'voided';\n };\n\n return {\n learnMoreDialog,\n envelopInfoDialog,\n voidEnvelopeDialog,\n orderDocumentsHeaders,\n dataTableOptionStatus,\n documentsTab,\n envelopesFilter,\n nameChangeErrors,\n reminderData,\n reminderDialog,\n currentWorkingEnvelope,\n form,\n fetchTemplates,\n includedInSubscription,\n envelopeVoided,\n userHasRole,\n sendEnvelopeReminder,\n voidEnvelope,\n getEnvelopes,\n formatMoney,\n formatMoneyDisplayV2,\n formatRentalDate,\n };\n },\n\n components: {\n ContractsTable,\n TemplatesTableList,\n },\n\n mixins: [\n subscriptionMixin,\n ],\n\n watch: {\n $route() {\n if (this.device === 'mobile' && this.secondaryNavViews.listingImportNav) {\n this.toggleSecondaryImportNav();\n }\n },\n },\n\n created() {\n if (this.planIncludesESign) {\n this.fetchTemplates();\n }\n EventBus.$on('create-template-success', (template) => {\n if (template.uuid) {\n this.$router.push({name: 'documents.prepare', params: {uuid: template.uuid}}).catch(err => {\n });\n }\n });\n EventBus.$on('envelope-reminder-success', () => {\n this.reminderDialog = false;\n this.reminderData = {\n recipients: [],\n };\n });\n },\n\n computed: {\n ...mapGetters({\n device: 'app/device',\n secondaryNavViews: 'app/secondaryNavViews',\n templates: 'document/templates',\n documents: 'document/documents',\n documentsLoading: 'document/loading',\n envelopes: 'envelope/envelopes',\n orderDocuments: 'order/documents',\n }),\n validTemplates() {\n // Return templates that have documents (truthy value)\n return this.templates.filter(template => template.documents);\n },\n templatesWithoutDocuments() {\n // Return templates where documents exist (including null)\n return this.templates.filter(template => template.documents === null);\n },\n orderDocumentsQuotesFiltered() {\n return this.orderDocuments.filter((d) => d.type === 'Document::Quote');\n },\n orderDocumentsInvoicesFiltered() {\n return this.orderDocuments.filter((d) => d.type === 'Document::Invoice');\n },\n invoicePaidAmount() {\n // Filtering paid and overpaid invoices\n const paidInvoices = this.orderDocumentsInvoicesFiltered.filter(invoice => {\n const invoiceStatus = invoice.status?.toLowerCase();\n return invoiceStatus === 'paid' || invoiceStatus === 'overpaid';\n });\n\n // Summing the paid amount in cents from the filtered invoices\n return paidInvoices.reduce((total, invoice) => total + (invoice.paid_in_cents ?? 0), 0);\n },\n invoiceTotalAmount() {\n // Summing the grand total with tax in cents from the filtered invoices\n return this.orderDocumentsInvoicesFiltered.reduce((total, invoice) => total + (invoice.grand_total_with_tax_in_cents ?? 0), 0);\n }\n },\n\n methods: {\n ...mapActions({\n toggleSecondaryImportNav: 'app/toggleSecondaryImportNav',\n createTemplate: 'document/createTemplate',\n }),\n bookingId(item) {\n return item?.order?.b_id;\n },\n renterFullName(renter: RenterInterface) {\n const name = renter?.full_name;\n if (name) {\n return name;\n }\n return `${renter?.first_name} ${renter?.last_name}`.trim();\n },\n recipients(envelope) {\n // Check if there are no recipients in the envelope\n if (!envelope.recipients?.length) {\n return [{\n name: this.renterFullName(envelope.renter),\n r_id: envelope.renter?.r_id,\n }];\n }\n\n // Process each recipient to extract their details\n return envelope.recipients.map(recipient => ({\n name: this.renterFullName(recipient.renter),\n r_id: recipient.renter?.r_id,\n }));\n },\n\n renterName(item: RenterInterface) {\n return item.full_name;\n },\n renterId(renter: RenterInterface) {\n return renter.r_id;\n },\n createTemplateInit() {\n const templatesPending = this.templatesWithoutDocuments;\n\n if (templatesPending.length === 0) {\n this.createTemplate();\n return;\n }\n\n const firstTemplate = templatesPending[0];\n\n this.$router.push({name: 'documents.prepare', params: {uuid: firstTemplate.uuid}}).catch({});\n },\n },\n\n beforeUnmount() {\n this.$store.commit('envelope/SET_ALL_ENVELOPES', {\n data: [],\n });\n this.$store.commit('order/SET_ORDER_DOCUMENTS', []);\n },\n};\n</script>\n\n<style>\n.denser .v-btn:not(.v-btn--round).v-size--default {\n height: 21px !important;\n}\n\n.denser .v-btn.v-size--default {\n font-size: 10px !important;\n}\n\n.denser .v-btn-toggle .v-btn.v-btn.v-size--default {\n min-width: 40px !important;\n}\n</style>\n","<template>\n <div class=\"grid grid-cols-2 gap-5\">\n <v-card class=\"mb-2\">\n <v-card-text>\n <div class=\"my-5\">\n Upload your document here. In the next step you will be able to add variable placeholders to your documents.\n </div>\n <div v-if=\"!documentsUploadedSuccess\" class=\"dragBox\" v-bind=\"getRootProps()\">\n <input v-bind=\"getInputProps()\"/>\n <p v-if=\"isDragActive\">Drop the files here ...</p>\n <p v-else>Drag and drop your file here, or click to select files</p>\n </div>\n\n <div v-else>\n <div class=\"h-100 row align-items-center\">\n <div class=\"col text-center\">\n <v-img height=\"200\" src=\"/images/illustrations/my_files.svg\"/>\n <h2 class=\"newCustomer__header\">Success</h2>\n <p>Click next to add placeholders to your template.</p>\n </div>\n </div>\n </div>\n\n <div v-if=\"rejectedReasons.length\" class=\"mt-5\">\n <v-alert density=\"comfortable\" type=\"error\">\n <ul>\n <li v-for=\"(reason, index) in rejectedReasons\" :key=\"index\">{{ reason }}</li>\n </ul>\n </v-alert>\n </div>\n\n </v-card-text>\n <v-card-actions>\n <v-btn :to=\"{name: 'documents.index'}\" size=\"small\" variant=\"text\">back</v-btn>\n <v-spacer/>\n <v-btn :disabled=\"!documentsUploadedSuccess\" :to=\"{name: 'documentsv2.fields', params: { uuid: documentUuid}}\" color=\"primary\">\n Next\n </v-btn>\n </v-card-actions>\n </v-card>\n </div>\n</template>\n\n<script lang=\"ts\" setup>\nimport {useStore} from 'vuex'\nimport {useRoute} from 'vue-router'\nimport axios from 'axios';\nimport type {FileRejectReason} from 'vue3-dropzone'\nimport {useDropzone} from 'vue3-dropzone';\nimport {ref} from 'vue';\n\ninterface GetUploadUrlParams {\n document_uuid: string;\n actor: string;\n extension: string;\n mime: string;\n}\n\ninterface UploadUrlResponse {\n uploadUrl: string;\n}\n\nconst route = useRoute();\nconst store = useStore();\nconst token = store.getters['auth/token'];\nconst url = `/v1/templates/${route.params.uuid}/documents/1`;\nconst thePhotosUploading = ref([]);\nconst filesForS3 = ref([]);\nconst theTripPhotos = ref([]);\nconst templateDocs = ref({});\nconst uploadProgress = ref('');\nconst completing = ref(false);\nconst documentsUploadedSuccess = ref(false);\nconst rejectedReasons = ref([]);\nconst uploadUrls = ref([]);\n\nconst documentUuid = route.params.uuid as string;\n\n\nconst getUploadUrl = async (file: File, documentUuid: string) => {\n // Extract the file extension and fallback if necessary\n const extension = file.name.split('.').pop() || 'txt';\n\n // Prepare the payload for the API\n const payload: GetUploadUrlParams = {\n document_uuid: documentUuid,\n actor: 'host',\n extension,\n mime: file.type || 'application/octet-stream',\n };\n\n try {\n const response = await fetch('https://tljgib4tw6.execute-api.us-west-1.amazonaws.com/default/TenantFileSignedUploadUrl', {\n method: 'POST',\n headers: {'Content-Type': 'application/json'},\n body: JSON.stringify(payload),\n });\n\n if (!response.ok) {\n console.error(`Failed to fetch upload URL. Status: ${response.status} - ${response.statusText}`);\n return null;\n }\n\n const {uploadUrl}: UploadUrlResponse = await response.json();\n return uploadUrl;\n } catch (error) {\n console.error('Error getting upload URL', error);\n return null;\n }\n};\n\nconst uploadS3Init = async () => {\n thePhotosUploading.value = [];\n uploadUrls.value = await Promise.all(filesForS3.value.map(file => getUploadUrl(file, documentUuid)));\n\n console.dir('uploadUrls%%%');\n console.dir(uploadUrls.value);\n const filteredFiles = filesForS3.value.filter((_, index) => uploadUrls.value[index]);\n await uploadS3(uploadUrls.value, filteredFiles);\n};\n\nconst createAwsAxiosInstance = () => {\n return axios.create({\n transformRequest: (data, headers) => {\n if (headers?.common?.Authorization) {\n delete headers.common.Authorization;\n }\n return data;\n },\n });\n};\n\nconst uploadS3 = async (filesPaths: string[], filteredFiles: File[]) => {\n const awsAxios = createAwsAxiosInstance();\n console.dir('uploadS3');\n console.dir(filesPaths);\n console.dir(filteredFiles);\n await Promise.all(filteredFiles.map((file, i) => uploadFileToS3(awsAxios, filesPaths[i], file, i)));\n};\n\nconst uploadFileToS3 = async (awsAxios, filePath: string, file: File, i: number) => {\n console.dir('initializeUploadData', i);\n\n\n try {\n console.dir(filePath);\n console.dir(file);\n await awsAxios.put(filePath, file, {\n onUploadProgress: event => {\n console.dir(event);\n },\n headers: {'Content-Type': file.type},\n });\n } catch (error) {\n console.error('Error uploading file', error);\n } finally {\n console.dir('finally');\n }\n};\n\n\nfunction onDrop(acceptedFiles: File[], rejectReasons: FileRejectReason[]) {\n rejectedReasons.value = [];\n console.log('acceptedFiles', acceptedFiles)\n console.log('rejectReasons', rejectReasons)\n\n if (rejectReasons.length > 0) {\n rejectReasons.forEach(reason => {\n if (!rejectedReasons.value.includes(reason.errors[0].message)) {\n rejectedReasons.value.push(reason.errors[0].message);\n }\n });\n }\n\n filesForS3.value = acceptedFiles;\n uploadS3Init().then(() => {\n uploadDocument();\n });\n}\n\nconst uploadDocument = async () => {\n if (uploadUrls.value.length > 0) {\n\n const uploadUrlsClean = uploadUrls.value.map(url => {\n return url.split('?')[0];\n });\n\n const formData = new FormData();\n formData.append('file_path', uploadUrlsClean[0]);\n formData.append('original_name', filesForS3.value[0].name);\n try {\n const response = await axios.post(`/v1/templates/${documentUuid}/documents/uploaded`, formData);\n console.dir(response);\n documentsUploadedSuccess.value = true;\n templateDocs.value = response.data.templateDocs;\n } catch (error) {\n console.dir(error);\n }\n }\n};\n\n\nconst {getRootProps, getInputProps, isDragActive,} = useDropzone({\n onDrop,\n maxSize: 10000000, // 10MB\n maxFiles: 1,\n accept: 'application/pdf',\n});\n</script>\n\n<style>\n.fw-file-drop {\n position: relative;\n border: 3px dashed #a7d2b8 !important;\n border-radius: 10px;\n box-shadow: 0 0 25px -20px #333;\n display: flex;\n flex-wrap: wrap;\n justify-content: flex-start;\n align-items: flex-start;\n margin: 0 0 20px;\n overflow: auto;\n cursor: pointer !important;\n height: 200px;\n padding-top: 10px;\n}\n\n.fw-file-drop:hover {\n border: 3px dashed #5b7365 !important;\n}\n\n.fw-file-drop__inner {\n display: block;\n position: relative;\n width: 100%;\n height: 100%;\n margin: auto;\n overflow: auto;\n}\n\n.fw-file-drop input {\n width: 100%;\n opacity: 0;\n height: 100%;\n left: 0;\n position: absolute;\n top: 0;\n right: 0;\n bottom: 0;\n}\n\n.fw-file-drop svg {\n margin: auto\n}\n\n.fw-file-drop label {\n width: 100%;\n font-size: 22px;\n font-weight: 400;\n\n display: inline-block;\n max-width: 100%;\n margin-bottom: 5px;\n}\n\n.dragBox {\n width: 100%;\n margin: 0 auto;\n position: relative;\n text-align: center;\n font-weight: bold;\n line-height: 95px;\n color: #999;\n border: 2px dashed #ccc;\n display: inline-block;\n transition: transform 0.3s;\n border-radius: 10px;\n}\n\n.dragBox.active {\n border: 2px dashed #5a81e0;\n}\n\n.dragBox input[type=\"file\"] {\n position: absolute;\n height: 100%;\n width: 100%;\n opacity: 0;\n top: 0;\n left: 0;\n}\n</style>\n","import {useStore} from 'vuex';\nimport {computed} from 'vue';\nimport {UpdateOrderPayload} from '@/store/modules/order';\nimport {OrderDocumentType, OrderLine} from '@/types';\n\n\nexport function useOrders() {\n const store = useStore();\n\n\n const orderLoading = computed<Record<string, boolean>>(() => store.getters['order/loading']);\n const theNewOrder = computed(() => store.getters['order/order']);\n const orderDialogs = computed(() => store.getters['order/orderDialogs']);\n const orderDocument = computed<OrderDocumentType>(() => store.getters['order/document']);\n const currentWorkingPricingWizardOrderLine = computed(() => store.getters['order/currentWorkingPricingWizardOrderLine']);\n\n\n const orderAvailability = computed(() => store.getters['order/availability']);\n\n const updateOrderLine = async (data) => {\n return await store.dispatch('order/updateLine', data);\n }\n\n const deleteOrderDocument = async (documentUuid: string) => {\n return await store.dispatch('order/deleteOrderDocument', documentUuid);\n }\n\n const setOrderDocument = async (data) => {\n return store.commit('order/SET_ORDER_DOCUMENT', data);\n }\n\n const checkOrderAvailability = async (orderUuid: string) => {\n return await store.dispatch('order/availability', orderUuid);\n }\n\n const getOrderItemModel = async (data) => {\n return await store.dispatch('order/getOrderItemModel', data);\n }\n\n const getOrderDocuments = async (orderUuid: string) => {\n return await store.dispatch('order/getOrderDocuments', orderUuid);\n }\n\n const getOrderDocument = async (documentUuid: string) => {\n return await store.dispatch('order/getOrderDocument', documentUuid);\n }\n\n const updateOrderDocument = async (data) => {\n return await store.dispatch('order/updateOrderDocument', data);\n }\n\n const getNewOrder = async () => {\n return await store.dispatch('order/newOrder');\n }\n\n const addOrderLine = async (data: { orderUuid: string, line: OrderLine }) => {\n return await store.dispatch('order/addLine', data);\n }\n\n /**\n * Fetches a specific order by ID.\n */\n const getOrder = (id: string) => store.dispatch('order/getOrder', id);\n\n const updateNewOrder = async (data: UpdateOrderPayload) => {\n return await store.dispatch('order/update', data);\n }\n\n const setOrder = async (data) => {\n console.dir(data);\n return store.commit('order/SET_ORDER', data);\n }\n\n /**\n * Removes an order line.\n */\n const removeOrderLine = (lineId: string) => {\n return store.dispatch('order/removeLine', lineId);\n };\n\n /**\n * Retrieves order lines safely.\n */\n const orderLines = computed<OrderLine[]>(() => theNewOrder.value?.lines || []);\n\n const openPricingWizardDialog = (open: boolean = false, lineItem: OrderLine) => {\n console.dir('openPricingWizardDialog');\n console.dir(lineItem);\n console.dir('^^^^^');\n return store.commit('order/SET_OPEN_PRICING_WIZARD_DIALOG', {open, lineItem});\n }\n\n return {\n orderLoading,\n theNewOrder,\n orderLines,\n orderDialogs,\n currentWorkingPricingWizardOrderLine,\n orderAvailability,\n orderDocument,\n setOrderDocument,\n checkOrderAvailability,\n getNewOrder,\n addOrderLine,\n openPricingWizardDialog,\n updateOrderLine,\n getOrder,\n setOrder,\n updateNewOrder,\n removeOrderLine,\n getOrderDocuments,\n getOrderDocument,\n updateOrderDocument,\n getOrderItemModel,\n deleteOrderDocument,\n }\n}","<template>\n <div id=\"wrapper\" class=\"print-area\">\n <div id=\"page\" section=\"documents\">\n <div id=\"content\">\n <div id=\"document\" class=\"document-quote\">\n <div class=\"block\">\n <div id=\"top\" class=\"\">\n <div v-if=\"documentPaid\" id=\"stamp\">\n <img id=\"paid\" alt=\"Stamp\" src=\"https://fleetwire.io/images/stamps/stamp-paid.png\">\n </div>\n <div v-if=\"company.logo\" id=\"logo-wrapper\">\n <img id=\"logo\" :src=\"company.logo\" alt=\"Company Logo\">\n </div>\n\n <div class=\"lefter\">\n <div id=\"user-info\" :class=\"editUser ? 'editing' :''\">\n <strong class=\"customer-name\">\n {{ customer.first_name }} {{ customer.last_name }}\n </strong>\n <v-btn\n v-if=\"!editUser\"\n class=\"absolute no-print\"\n size=\"small\"\n style=\"top: -5px;\"\n variant=\"text\"\n @click=\"editUser = true;\"\n >\n <v-icon size=\"x-small\">mdi-pencil</v-icon>\n </v-btn>\n <form action=\"#\">\n <div class=\"show-user flex\">\n <pre class=\"pre-address\" v-html=\"customerAddress\"></pre>\n </div>\n <div class=\"edit-user\">\n <v-textarea\n v-model=\"customerAddress\"\n hide-details\n label=\"Address\"\n name=\"input-7-4\"\n rows=\"2\"\n variant=\"outlined\"\n ></v-textarea>\n <div class=\"float-right mt-2\">\n <v-btn class=\"mr-2\" size=\"small\" variant=\"text\" @click=\"editUser = false;\">\n <v-icon size=\"small\">mdi-close</v-icon>\n </v-btn>\n <v-btn size=\"small\" variant=\"text\" @click=\"updateCustomerAddress(); editUser = false;\">Save\n </v-btn>\n </div>\n </div>\n <button style=\"display: none;\" type=\"submit\"></button>\n </form>\n <div class=\"customer-email\">{{ customer.email }}</div>\n <div class=\"additional-information\"></div>\n </div>\n </div>\n\n <div class=\"righter\">\n <div id=\"company-info\">\n <strong class=\"company-name\">{{ company.name }}</strong><br>\n <div v-if=\"companyAddress.address_1\">\n {{ companyAddress.address_1 }}<br>\n <span v-if=\"companyAddress.address_2\" class=\"block\">{{ companyAddress.address_2 }}</span>\n <span v-if=\"companyAddress.city\">{{ companyAddress.city }}, </span>\n <span v-if=\"companyAddress.state\">{{ companyAddress.state }} </span>\n <span v-if=\"companyAddress.postal_code\">{{ companyAddress.postal_code }} </span>\n </div>\n <span class=\"company-phone\">{{ company.phone_fmt || company.phone }}</span><br>\n <span class=\"company-email\">{{ company.email }}</span><br><br>\n <span class=\"financial-line-1\"></span><br>\n <span class=\"financial-line-2\"></span>\n </div>\n </div>\n </div>\n </div>\n\n <div class=\"name-dates\">\n <div class=\"grid grid-cols-2\">\n <div class=\"\">\n <h2 v-if=\"!editDocumentNumber\" class=\"table-form-title\">\n <span>{{ documentTitle }}</span>\n <v-btn v-if=\"!editDocumentNumber\" class=\"no-print\" size=\"small\" variant=\"text\" @click=\"editDocumentNumber = true;\">\n <v-icon size=\"small\">mdi-pencil</v-icon>\n </v-btn>\n </h2>\n <div v-if=\"editDocumentNumber\" class=\"flex\">\n <h2 class=\"table-form-title mr-2\">{{ documentType }} #</h2>\n <v-text-field\n v-model=\"documentNumber\"\n append-icon=\"mdi-content-save\"\n density=\"compact\"\n hide-details\n style=\"max-width: 100px;\"\n variant=\"outlined\"\n @keyup.enter=\"updateOrderDocumentNumber(); editDocumentNumber = !editDocumentNumber\"\n @click:append=\"updateOrderDocumentNumber(); editDocumentNumber = !editDocumentNumber\"\n ></v-text-field>\n </div>\n </div>\n\n <div class=\"dates\">\n <form action=\"#\">\n <div class=\"document-date\">\n <b>Date</b>\n <span>{{ formatRentalDate(orderDocument?.date, 'MMM DD, YYYY') }}</span>\n <v-dialog\n v-if=\"orderDocument?.date\"\n ref=\"dialog\"\n v-model=\"editDateDialog\"\n v-model:return-value=\"orderDocument.date\"\n persistent\n width=\"290px\"\n >\n <template v-slot:activator=\"{ props }\">\n <v-btn size=\"small\" v-bind=\"props\" variant=\"text\">\n <v-icon size=\"x-small\">mdi-pencil</v-icon>\n </v-btn>\n </template>\n <v-date-picker\n v-model=\"documentDate\"\n scrollable\n >\n <template v-slot:actions>\n <v-btn\n color=\"gray\"\n variant=\"text\"\n @click=\"editDateDialog = false\"\n >\n Cancel\n </v-btn>\n <v-btn\n color=\"primary\"\n variant=\"text\"\n @click=\"updateOrderDocumentDate()\"\n >\n OK\n </v-btn>\n </template>\n <v-spacer/>\n\n </v-date-picker>\n </v-dialog>\n </div>\n </form>\n <div class=\"starts-at\">\n <b>Pickup</b>\n <span v-if=\"orderDocument?.starts_at\">{{ formatRentalDate(orderDocument?.starts_at) }}</span>\n </div>\n <div class=\"stops-at\">\n <b>Return</b>\n <span v-if=\"orderDocument?.stops_at\">{{ formatRentalDate(orderDocument?.stops_at) }}</span>\n </div>\n <div class=\"stops-at\">\n <b>Booking ID</b>\n <span v-if=\"documentBookingId\">{{ documentBookingId }}</span>\n </div>\n </div>\n </div>\n </div>\n\n\n <div id=\"products-table\">\n <div>\n <div class=\"\">\n <form action=\"#\">\n <table class=\"table\">\n <tbody>\n <tr>\n <th class=\"auto-width\"></th>\n <th class=\"table-form-title\"></th>\n <th class=\"auto-width charge\"></th>\n <th class=\"text-right auto-width price\">Price</th>\n <th class=\"text-right vat\">Tax</th>\n <th class=\"text-right auto-width total\">Total</th>\n </tr>\n </tbody>\n <tbody>\n\n <tr v-for=\"(line) in orderDocument?.lines\" :key=\"line.uuid\" class=\"line\">\n <td class=\"auto-width quantity\">{{ line.quantity }}x</td>\n <td class=\"table-form-title\" colspan=\"1\">\n <div class=\"line-title\">\n {{ line.title }}\n </div>\n <div class=\"line-extra\">{{ line.extra_information }}</div>\n <div class=\"line-custom\"></div>\n </td>\n <td class=\"auto-width charge\">\n {{ line.charge_units }}\n </td>\n <td class=\"text-right auto-width price\">\n {{ formatMoneyDisplayV2(line.price_each_in_cents) }}\n </td>\n <td class=\"text-right auto-width tax\">\n {{ getTaxCategoryParentName(line) }}\n </td>\n <td class=\"text-right auto-width total\">\n {{ formatMoneyDisplayV2(line.price_in_cents) }}\n </td>\n </tr>\n </tbody>\n\n <tbody id=\"totals\">\n <tr class=\"reference\">\n <td class=\"print-hide\" colspan=\"3\" rowspan=\"100%\">\n <span v-if=\"!editReference\" class=\"printed-reference-text\">\n {{ orderReference }}\n </span>\n <v-btn v-if=\"!editReference\" class=\"no-print\" size=\"small\" variant=\"text\" @click=\"editReference = true\">\n <v-icon size=\"small\">mdi-pencil</v-icon>\n </v-btn>\n <v-btn\n v-if=\"!editReference && !orderReference\"\n class=\"no-print underline\"\n size=\"small\"\n variant=\"text\"\n @click=\"editReference = true;\"\n >\n Insert a reference\n </v-btn>\n <div v-if=\"editReference\">\n <v-textarea\n v-model=\"orderReference\"\n hide-details\n label=\"Reference\"\n name=\"input-7-4\"\n rows=\"5\"\n variant=\"outlined\"\n />\n <div class=\"float-right mt-2\">\n <v-btn :loading=\"orderLoading.update\" class=\"mr-2\" size=\"small\" variant=\"text\" @click=\"editReference = false;\">\n <v-icon size=\"small\">mdi-close</v-icon>\n </v-btn>\n <v-btn :loading=\"orderLoading.update\" size=\"small\" variant=\"text\" @click=\"updateOrderReference(); editReference = false;\">\n Save\n </v-btn>\n </div>\n </div>\n </td>\n <td class=\"print-show\" colspan=\"3\" rowspan=\"100%\">{{ orderReference }}</td>\n <td class=\"text-right subtotal\" colspan=\"2\">Subtotal</td>\n <td class=\"text-right subtotal\">{{ formatMoneyDisplayV2(orderDocument?.price_in_cents) }}</td>\n </tr>\n <tr v-if=\"orderDocument?.total_discount_in_cents > 0\">\n <td class=\"divider\" colspan=\"3\">\n <hr>\n </td>\n </tr>\n <tr v-if=\"orderDocument?.discount_in_cents > 0\" class=\"total\">\n <td class=\"text-right total\" colspan=\"2\">Discount</td>\n <td class=\"text-right total\">-{{ formatMoneyDisplayV2(orderDocument?.discount_in_cents) }}</td>\n </tr>\n <tr v-if=\"orderDocument?.coupon_discount_in_cents > 0\" class=\"total\">\n <td class=\"text-right total\" colspan=\"2\">Coupon</td>\n <td class=\"text-right total\">-{{\n formatMoneyDisplayV2(orderDocument?.coupon_discount_in_cents)\n }}\n </td>\n </tr>\n <tr v-if=\"orderDocument?.total_discount_in_cents > 0\" class=\"total\">\n <td class=\"text-right total\" colspan=\"2\">Total discount</td>\n <td class=\"text-right total\">-{{\n formatMoneyDisplayV2(orderDocument?.total_discount_in_cents)\n }}\n </td>\n </tr>\n <tr>\n <td class=\"divider\" colspan=\"3\">\n <hr>\n </td>\n </tr>\n <tr class=\"total\">\n <td class=\"text-right total\" colspan=\"2\">Total excl. taxes</td>\n <td class=\"text-right total\">{{ formatMoneyDisplayV2(orderDocument?.grand_total_in_cents) }}</td>\n </tr>\n <tr v-if=\"orderDocument?.total_tax_in_cents > 0\" class=\"tax\">\n <td class=\"text-right vat\" colspan=\"2\">Taxes</td>\n <td class=\"text-right vat\">{{ formatMoneyDisplayV2(orderDocument?.total_tax_in_cents) }}</td>\n </tr>\n <tr>\n <td class=\"divider\" colspan=\"3\">\n <hr>\n </td>\n </tr>\n <tr class=\"grand-total\">\n <td class=\"text-right bold grand-total\" colspan=\"2\">Total incl. taxes</td>\n <td class=\"text-right bold grand-total\">\n {{ formatMoneyDisplayV2(orderDocument?.grand_total_with_tax_in_cents) }}\n </td>\n </tr>\n <tr class=\"deposit\">\n <td class=\"text-right deposit\" colspan=\"2\">Security deposit</td>\n <td class=\"text-right deposit\">{{ formatMoneyDisplayV2(orderDocument?.deposit_in_cents) }}</td>\n </tr>\n <tr>\n <td class=\"divider\" colspan=\"3\">\n <hr>\n </td>\n </tr>\n <tr class=\"grand-total\">\n <td class=\"text-right bold grand-total\" colspan=\"2\">Paid</td>\n <td class=\"text-right bold grand-total\">{{\n formatMoneyDisplayV2(orderDocument?.paid_in_cents)\n }}\n </td>\n </tr>\n <tr class=\"grand-total\">\n <td class=\"text-right bold grand-total bold\" colspan=\"2\">Outstanding</td>\n <td class=\"text-right bold grand-total\">{{\n formatMoneyDisplayV2(orderDocument?.to_be_paid_in_cents)\n }}\n </td>\n </tr>\n <tr>\n <td colspan=\"100%\"><br></td>\n </tr>\n </tbody>\n </table>\n <button style=\"display: none;\" type=\"submit\"></button>\n </form>\n </div>\n\n <div id=\"footer\" :class=\"footer.blocks ? '' : 'blank'\">\n <div :class=\"addEditFooter ? 'editing' : 'view'\">\n <div v-if=\"!addEditFooter\" class=\"rx-content\" v-html=\"convertBlocksToHtml(footer.blocks)\"></div>\n <v-btn v-if=\"!addEditFooter\" class=\"float-right no-print\" size=\"x-small\" variant=\"text\" @click=\"addEditFooter = true;\">\n <span class=\"underline\">Add or edit footer</span>\n </v-btn>\n <div class=\"editor text-editor\">\n <div id=\"editorjs\"></div>\n </div>\n <v-btn v-if=\"addEditFooter\" class=\"text-right mt-2\" @click=\"updateFooter()\">Save</v-btn>\n </div>\n </div>\n <button style=\"display: none;\" type=\"submit\"></button>\n </div>\n\n <br class=\"clear\">\n </div>\n\n\n </div>\n </div>\n </div>\n </div>\n</template>\n\n<script lang=\"ts\" setup>\nimport {computed, onBeforeMount, onBeforeUnmount, ref, watch} from 'vue';\nimport {EventBus} from '@/plugins/eventBus';\nimport EditorJS from '@editorjs/editorjs';\nimport Header from '@editorjs/header';\nimport {useMoneyFormatter} from '@/composables/useMoneyFormatter';\nimport {useDateFormatter} from '@/composables/useDate';\nimport {useCompany} from '@/composables/useCompany';\nimport dayjs from 'dayjs';\nimport {useRoute} from 'vue-router';\nimport {useOrders} from '@/composables/useOrders';\nimport {OrderLine} from '@/types';\n\nconst route = useRoute();\nconst {formatMoneyDisplayV2} = useMoneyFormatter();\nconst {formatRentalDate} = useDateFormatter();\nconst {company} = useCompany();\nconst {orderLoading, orderDocument, getOrderDocument, updateOrderDocument, setOrderDocument} = useOrders();\n\nconst documentUuid = route.params.uuid as string;\n\nconst documentDate = ref(null);\nconst selected = ref([]);\nconst options = ref({});\nconst addEditFooter = ref(false);\nconst editDateDialog = ref(false);\nconst editDocumentNumber = ref(false);\nconst editUser = ref(false);\nconst editReference = ref(false);\nconst customer = ref({\n first_name: null,\n last_name: null,\n email: null,\n phone: null,\n});\n\nconst editorjs = ref<EditorJS | null>(null);\nconst footer = ref({blocks: null});\nconst documentDataCopy = ref(null);\n\nconst customerAddress = computed({\n get: () => orderDocument.value?.address,\n set: (value: string) => {\n if (orderDocument.value) {\n orderDocument.value.address = value;\n }\n }\n});\n\nconst orderReference = computed({\n get: () => orderDocument.value?.reference,\n set: (value: string) => {\n if (orderDocument.value) {\n orderDocument.value.reference = value;\n }\n }\n});\n\nconst documentNumber = computed({\n get: () => orderDocument.value?.number,\n set: (value: string) => {\n if (orderDocument.value) {\n orderDocument.value.number = value;\n }\n }\n});\n\nconst updateFooter = async () => {\n if (!editorjs.value) return;\n\n try {\n const outputData = await editorjs.value.save();\n console.log('Saved footer data:', outputData);\n footer.value.blocks = outputData;\n\n await updateOrderDocument({\n documentUuid,\n attributes: {footer: footer.value.blocks}\n });\n addEditFooter.value = false;\n // Destroy the editor instance after saving\n editorjs.value.destroy();\n editorjs.value = null;\n } catch (error) {\n console.error('Footer save failed:', error);\n }\n};\n\nconst documentTitle = computed(() => orderDocument.value?.title);\nconst documentBookingId = computed(() => orderDocument.value?.order?.b_id);\nconst documentStatus = computed(() => orderDocument.value?.status);\nconst documentPaid = computed(() =>\n ['overpaid', 'paid'].includes(documentStatus.value?.toLowerCase() || '')\n);\nconst documentType = computed(() =>\n orderDocument.value?.type.split('::')[1] || 'Quote'\n);\nconst companyAddress = computed(() => company.value?.address);\n\nwatch(addEditFooter, (newValue) => {\n if (newValue) {\n // Ensure any existing editor is destroyed before creating a new one\n if (editorjs.value) {\n editorjs.value.destroy();\n editorjs.value = null;\n }\n\n // Create new EditorJS instance with current footer data\n editorjs.value = new EditorJS({\n autofocus: true,\n holder: 'editorjs',\n tools: {\n header: Header,\n },\n data: footer.value.blocks || undefined,\n onReady: () => {\n console.log('EditorJS initialized with data:', footer.value.blocks);\n }\n });\n }\n});\n\n// Watchers\nwatch(orderDocument, (document) => {\n if (document) {\n documentDataCopy.value = JSON.parse(JSON.stringify(document));\n customer.value = {\n first_name: document.customer?.first_name,\n last_name: document.customer?.last_name,\n email: document.customer?.email,\n phone: document.customer?.phone\n };\n if (document.footer) {\n footer.value.blocks = document.footer;\n }\n }\n}, {immediate: true});\n\nonBeforeMount(() => {\n getOrderDocument(documentUuid);\n});\n\n// Methods\nconst convertBlocksToHtml = (data: any) => {\n if (!data?.blocks) return '';\n\n let html = '';\n data.blocks.forEach((block: any) => {\n const value = block.data?.text;\n if (block.type === 'paragraph') {\n html += `<p>${value}</p>`;\n } else if (block.type === 'header') {\n const h = block.data?.level;\n html += `<h${h}>${value}</h${h}>`;\n }\n });\n return html;\n};\n\nconst getTaxCategoryParentName = (line: OrderLine) => {\n return line?.tax_category?.name;\n};\n\nconst updateCustomerAddress = () => {\n updateOrderDocument({\n documentUuid,\n attributes: {address: customerAddress.value}\n });\n};\n\nconst updateOrderDocumentDate = () => {\n updateOrderDocument({\n documentUuid,\n attributes: {\n date: dayjs(documentDate.value).format('YYYY-MM-DD')\n }\n }).then(() => {\n editDateDialog.value = false;\n });\n};\n\nconst updateOrderDocumentNumber = () => {\n updateOrderDocument({\n documentUuid,\n attributes: {number: documentNumber.value}\n });\n};\n\nconst updateOrderReference = () => {\n updateOrderDocument({\n documentUuid,\n attributes: {reference: orderReference.value}\n });\n};\n\nonBeforeUnmount(() => {\n if (editorjs.value) {\n editorjs.value.destroy();\n editorjs.value = null;\n }\n\n // @ts-ignore\n setOrderDocument(null);\n EventBus.$off('update-order-document-error');\n});\n\n// Event listeners\nEventBus.$on('update-order-document-error', () => {\n documentNumber.value = documentDataCopy.value?.number;\n});\n\n</script>\n\n<style>\n.float-right {\n float: right !important;\n}\n\n#wrapper {\n float: left;\n width: 100%;\n height: 100%;\n min-width: 708px;\n}\n</style>\n\n<style id=\"print-css\">\n\n.print-show {\n display: none;\n}\n\n#page {\n max-width: 1060px;\n min-height: 29.7cm;\n background: white;\n display: block;\n margin: 0 auto 0.5cm;\n box-shadow: 0 0 0.5cm rgba(0, 0, 0, 0.5);\n}\n\n#document {\n margin: 0 auto;\n max-width: 1060px;\n position: relative;\n overflow: hidden;\n padding: 0 40px 40px 40px;\n}\n\n#document #top {\n float: left;\n width: 100%;\n font-weight: 300;\n padding: 40px 0 0 0;\n}\n\n#document #top #logo-wrapper {\n position: absolute;\n top: 40px;\n right: 40px;\n display: table-cell;\n max-width: 175px;\n max-height: 175px;\n}\n\n#document #top .lefter {\n float: left;\n width: 50%;\n}\n\n#document #top .righter {\n float: right;\n width: 50%;\n}\n\n#document #top #user-info {\n font-size: 13px;\n position: relative;\n}\n\n#document #top .additional-information {\n margin-top: 20px;\n}\n\n#document #top #company-info {\n font-size: 13px;\n max-width: 200px;\n}\n\n#document #products {\n float: left;\n width: 100%;\n margin-top: 40px;\n}\n\n#document #products .dates {\n font-size: 12px;\n line-height: 18px;\n float: right;\n width: 50%;\n margin-top: -20px;\n}\n\n#document #products .dates > span,\n#document #products .dates .document-date {\n display: block;\n}\n\n\n.name-dates > div b,\n.document-date b {\n width: 75px;\n display: inline-block;\n font-weight: 500;\n font-size: 12px;\n}\n\n.name-dates > div span {\n display: inline-block;\n font-size: 12px;\n margin-left: 10px;\n}\n\n#document #products table .line-title {\n font-weight: bold;\n}\n\n#document #products h2.table-form-title {\n font-weight: 200;\n font-size: 30px;\n margin: 0 0 40px 0;\n color: #1C2A30;\n}\n\n.table {\n width: 100%;\n max-width: 100%;\n margin-bottom: 20px;\n}\n\n\n#page table, #page .table {\n margin: 0;\n font-size: 13px;\n font-weight: 300;\n border-collapse: separate;\n}\n\n#document #products table tbody {\n background: #fff;\n}\n\n#page table tbody,\n#page .table tbody {\n color: #1C2A30;\n border: 0;\n}\n\ntable th, .table th {\n white-space: nowrap;\n}\n\ntable th, table td, .table th, .table td {\n border-color: #DDE1E3;\n}\n\n.table > thead > tr > th,\n.table > thead > tr > td,\n.table > tbody > tr > th,\n.table > tbody > tr > td,\ntable > tfoot > tr > th,\n.table > tfoot > tr > td {\n padding: 10px 20px;\n line-height: 1.428571429;\n vertical-align: top;\n border-top: 1px solid #DDE1E3;\n}\n\ntable th.auto-width,\ntable td.auto-width,\n.table th.auto-width,\n.table td.auto-width {\n width: 1px;\n white-space: nowrap;\n}\n\n#page table th,\n#page table td,\n#page .table th,\n#page .table td {\n vertical-align: middle;\n}\n\ntable th.total,\ntable th.price {\n width: 100px;\n}\n\ntable th.total,\ntable th.vat {\n padding-right: 0 !important;\n}\n\ntable th.vat {\n width: 120px;\n}\n\ntable tbody:first-child th {\n border-top: 0;\n}\n\n#page table tbody#totals tr,\n#page .table tbody#totals tr {\n padding: 0;\n}\n\ntable td.tax,\ntable td.total,\ntable td.subtotal,\ntable td.grand-total,\ntable td.deposit {\n padding-right: 0 !important;\n}\n\ntable td {\n vertical-align: top !important;\n}\n\ntable .line-extra {\n font-size: 12px;\n margin-top: 4px;\n white-space: pre-wrap;\n}\n\n\n#page table tbody#totals tr td,\n#page .table tbody#totals tr td {\n border: 0;\n padding: 5px 15px;\n white-space: nowrap;\n}\n\n#page table tbody#totals tr td.divider,\n#page .table tbody#totals tr td.divider {\n padding: 10px 0;\n}\n\n\n#page table tbody#totals tr td.right,\n#page .table tbody#totals tr td.right {\n padding-right: 0;\n}\n\na.underline {\n text-decoration: underline;\n}\n\n#page table th.bold,\n#page table td.bold,\n#page .table th.bold,\n#page .table td.bold {\n font-weight: bold;\n}\n\ntable th.right,\ntable td.right,\n.table th.right,\n.table td.right {\n text-align: right;\n}\n\n\n#body {\n border: 0 !important;\n}\n\n#footer {\n font-size: 12px;\n}\n\n#footer,\n#body {\n margin-top: 30px;\n padding-top: 20px;\n border-top: 1px #DDE1E3 solid;\n float: left;\n width: 100%;\n font-weight: 400;\n}\n\n\n#footer a.right,\n#body a.right {\n text-align: right;\n width: 100%;\n display: inline-block;\n}\n\n#footer a.underline,\n#body a.underline {\n font-size: 12px;\n font-weight: 400;\n}\n\n#footer .edit,\n#body .edit {\n display: none;\n}\n\n\n#document #top #user-info .edit-user {\n display: none;\n padding-right: 40px;\n}\n\n#document #top #user-info.editing .edit-user {\n display: block;\n}\n\n#document #top #user-info.editing .show-user {\n display: none;\n}\n\n\n#footer .editing .editor {\n height: 200px;\n padding: 20px;\n border: 1px #DDE1E3 solid;\n cursor: text;\n}\n\n#footer .view .editor {\n display: none;\n}\n\n#footer .editing .editor {\n float: left;\n width: 100%;\n max-height: calc(70vh - 125px);\n overflow-y: scroll;\n}\n\n#text-editor .ProseMirror {\n height: 362px !important;\n}\n\n\n#footer .ce-block__content,\n#footer .ce-toolbar__content {\n max-width: calc(100% - 25px);\n}\n\n.pre-address {\n font-family: inherit;\n font-size: inherit;\n color: inherit;\n border: none;\n}\n\n@media print {\n body * {\n visibility: hidden;\n }\n\n .print-area, .print-area * {\n visibility: visible;\n }\n\n * {\n -o-transition-property: none !important;\n -moz-transition-property: none !important;\n -webkit-transition-property: none !important;\n transition-property: none !important;\n -o-transform: none !important;\n -moz-transform: none !important;\n -ms-transform: none !important;\n -webkit-transform: none !important;\n transform: none !important;\n }\n\n *, *:before, *:after {\n background: transparent !important;\n color: #000 !important;\n box-shadow: none !important;\n text-shadow: none !important;\n }\n\n @page {\n margin-top: 30px;\n margin-bottom: 30px;\n }\n\n body {\n color: #1C2A30;\n min-width: unset;\n padding: 0 !important;\n margin: 0;\n }\n\n #page {\n max-width: unset !important;\n min-height: unset !important;\n margin: unset !important;\n box-shadow: unset !important;\n }\n\n #app.bg-light {\n background-color: #FFFFFF !important;\n }\n\n #page {\n width: unset;\n min-height: unset;\n margin: 0 !important;\n }\n\n .print-hide {\n display: none;\n }\n\n .no-print {\n display: none;\n }\n\n .main-container {\n padding: 0 !important;\n }\n\n #document #top {\n float: left;\n width: 100%;\n font-weight: 300;\n padding: 0 0 0 0;\n }\n\n #page h1 {\n font-size: 2em;\n }\n\n #page h2 {\n font-size: 1.5em;\n }\n\n #page h3 {\n font-size: 1.17em;\n }\n\n #page h4 {\n font-size: 1.12em;\n }\n\n #page h5 {\n font-size: .83em;\n }\n\n #page h6 {\n font-size: .75em;\n }\n\n [section=documents] #content {\n padding: 0;\n }\n\n [section=documents] #document {\n border: none !important;\n padding: 0 !important;\n border-radius: unset;\n -webkit-box-shadow: unset;\n box-shadow: unset;\n }\n\n [section=documents] table.table tr td,\n [section=documents] table.table tr th {\n padding: 8px !important;\n border-color: #f1f1f1 !important;\n }\n\n [section=documents] #totals tr:first-child td {\n border-top: 1px #dde1e3 solid !important;\n padding-top: 18px !important;\n }\n\n [section=documents] #totals tr td {\n padding: 5px 0 !important;\n }\n\n [section=documents] .printed-reference-text {\n width: 100%;\n white-space: normal;\n }\n\n .print-show {\n display: table-cell;\n }\n\n .printed-reference-text {\n width: 100%;\n white-space: normal;\n }\n\n .main-content {\n margin: 0 !important;\n padding: 0 !important;\n height: unset !important;\n }\n\n .eUcdHi {\n padding: unset;\n }\n\n .navbar-custom {\n display: none !important;\n }\n\n .app-wrapper {\n margin-left: 0 !important;\n padding: 0 !important;\n }\n\n .dashboard-sidebar {\n display: none !important;\n }\n\n .mainNavBar__mobileMenuOpen {\n display: none !important;\n }\n\n .fw-container-fluid {\n padding: unset !important;\n }\n\n .v-application .my-3 {\n margin-top: 0 !important;\n margin-bottom: 0 !important;\n }\n\n [section=documents] #footer.blank,\n [section=documents] #body.blank {\n display: none;\n }\n\n [section=documents] #totals tr:first-child td {\n border-top: 1px #dde1e3 solid !important;\n padding-top: 18px !important;\n }\n}\n</style>\n\n\n<style>\n#document #stamp {\n display: inline-block;\n opacity: 0.1;\n top: 0;\n left: 0;\n position: absolute;\n width: 250px;\n height: 250px;\n pointer-events: none;\n}\n\n#document #stamp img#paid {\n height: 250px;\n top: -55px;\n left: -60px;\n position: absolute;\n}\n</style>\n","<template>\n <v-dialog v-model=\"orderDocumentDialog\" width=\"500\">\n <v-card>\n <v-card-title>\n Downloading\n <v-spacer />\n <span v-if=\"fileDone\">\n <v-icon class=\"mr-2 mb-1\" color=\"green\">mdi-check</v-icon> Done\n </span>\n </v-card-title>\n <v-card-text>\n <div class=\"mt-5 text-center\">\n <v-progress-circular\n v-if=\"!fileDone\"\n indeterminate\n color=\"primary\"\n ></v-progress-circular>\n <div v-else>\n <v-btn variant=\"text\" size=\"small\" :href=\"fileUrl\" target=\"_blank\">\n Didnt start downloading automatically?\n <v-icon size=\"x-small\" class=\"ml-2\">mdi-open-in-new</v-icon>\n </v-btn>\n </div>\n </div>\n </v-card-text>\n </v-card>\n </v-dialog>\n</template>\n\n<script>\nimport { mapActions, mapGetters } from 'vuex';\nimport { EventBus } from '@/plugins/eventBus';\nimport { get } from 'lodash';\n\nexport default {\n name: 'StartOrderDocumentDownloadDialog',\n\n data() {\n return {\n orderDocumentDialog: false,\n currentWorkingOrderDocumentUuid: null,\n };\n },\n\n created() {\n EventBus.$on('open-download-order-document-dialog', (document_uuid) => {\n this.orderDocumentDialog = true;\n this.currentWorkingOrderDocumentUuid = document_uuid;\n\n this.downloadOrderDocument(document_uuid);\n });\n EventBus.$on('start-order-document-download-success', (status) => {\n if(['started', 'queued'].includes(get(status, 'status.status'))) {\n setTimeout(() => {\n this.downloadOrderDocument(this.currentWorkingOrderDocumentUuid);\n }, 3 * 1000);\n }\n });\n },\n\n watch: {\n fileDone: {\n handler(status) {\n if(status) {\n window.open(this.fileUrl, '_blank').focus();\n }\n },\n },\n fileStatus: {\n handler(status) {\n console.dir(status);\n },\n },\n },\n\n computed: {\n ...mapGetters({\n theNewOrder: 'order/order',\n documents: 'order/documents',\n downloadStatus: 'order/downloadStatus',\n }),\n fileUrl() {\n return get(this.downloadStatus, 'url');\n },\n fileDone() {\n return get(this.downloadStatus, 'done');\n },\n fileStatus() {\n return get(this.downloadStatus, 'status.status');\n },\n },\n\n methods: {\n ...mapActions({\n downloadOrderDocument: 'order/downloadOrderDocument',\n }),\n },\n\n beforeUnmount() {\n EventBus.$off('open-download-order-document-dialog');\n EventBus.$off('start-order-document-download-success');\n },\n};\n</script>\n","<template>\n <div>\n <v-btn\n v-if=\"orderBookingId && device !== 'mobile'\"\n :to=\"{ name: 'orders.single', params: {b_id: orderBookingId} }\"\n class=\"mx-3\"\n size=\"small\"\n variant=\"text\"\n >\n Order {{ orderBookingId }}\n </v-btn>\n <v-btn v-if=\"device !== 'mobile'\" class=\"mr-3\" color=\"red\" variant=\"outlined\" @click=\"deleteOrderDocumentInit()\">\n <v-icon class=\"mr-2\" size=\"small\">mdi-delete-outline</v-icon>\n Delete\n </v-btn>\n <div v-if=\"device !== 'mobile'\" class=\"v-btn-group\">\n <v-btn variant=\"flat\" @click=\"printElem()\">\n <v-icon class=\"mr-2\" size=\"small\">mdi-printer</v-icon>\n Print\n </v-btn>\n <v-btn variant=\"flat\" @click=\"downloadOrderDocumentInit()\">\n <v-icon class=\"mr-2\" size=\"small\">mdi-download</v-icon>\n Download\n </v-btn>\n <v-btn\n v-if=\"documentCanBeFinalized\"\n :loading=\"orderLoading.update\"\n color=\"blue\"\n variant=\"flat\"\n @click=\"finalizeDocumentInit()\"\n >\n <v-icon class=\"mr-2\" size=\"small\">mdi-check</v-icon>\n Finalize\n </v-btn>\n <!-- <v-btn depressed theme=\"dark\" color=\"blue\">-->\n <!-- <v-icon size=\"small\" class=\"mr-2\">mdi-check</v-icon> Confirm-->\n <!-- </v-btn>-->\n <!-- <v-btn depressed theme=\"dark\" color=\"green\">-->\n <!-- <v-icon size=\"small\" class=\"mr-2\">mdi-email</v-icon> Send-->\n <!-- </v-btn>-->\n </div>\n <v-menu v-if=\"device === 'mobile'\">\n <template v-slot:activator=\"{ props }\">\n <v-btn\n class=\"ml-1\"\n rounded\n v-bind=\"props\"\n variant=\"outlined\"\n >\n <v-icon>mdi-dots-vertical</v-icon>\n </v-btn>\n </template>\n <v-list>\n <v-list-item v-if=\"device === 'mobile'\">\n\n <v-btn\n v-if=\"orderBookingId\"\n :to=\"{ name: 'orders.single', params: {b_id: orderBookingId} }\"\n variant=\"outlined\"\n >\n Order {{ orderBookingId }}\n </v-btn>\n\n </v-list-item>\n <v-list-item v-if=\"device === 'mobile'\">\n\n <v-btn color=\"red\" variant=\"outlined\" @click=\"deleteOrderDocumentInit()\">\n <v-icon class=\"mr-2\" size=\"small\">mdi-delete-outline</v-icon>\n Delete\n </v-btn>\n\n </v-list-item>\n <v-list-item>\n\n <v-btn variant=\"flat\" @click=\"printElem()\">\n <v-icon class=\"mr-2\" size=\"small\">mdi-printer</v-icon>\n Print\n </v-btn>\n\n </v-list-item>\n <v-list-item>\n\n <v-btn variant=\"flat\" @click=\"downloadOrderDocumentInit()\">\n <v-icon class=\"mr-2\" size=\"small\">mdi-download</v-icon>\n Download\n </v-btn>\n\n </v-list-item>\n <v-list-item>\n\n <v-btn\n v-if=\"documentCanBeFinalized\"\n :loading=\"orderLoading.update\"\n color=\"blue\"\n variant=\"flat\"\n @click=\"finalizeDocumentInit()\"\n >\n <v-icon class=\"mr-2\" size=\"small\">mdi-check</v-icon>\n Finalize\n </v-btn>\n\n </v-list-item>\n </v-list>\n </v-menu>\n <StartOrderDocumentDownloadDialog/>\n\n <v-dialog v-model=\"deleteOrderDocumentConfirmDialog\" width=\"350\">\n <v-card :disabled=\"orderLoading.deleteOrderDocument\">\n <v-card-title>\n Delete Document\n </v-card-title>\n <v-card-text>\n Are you sure you want to delete this document?\n </v-card-text>\n <v-card-actions>\n <v-spacer/>\n <v-btn color=\"grey\" size=\"small\" variant=\"text\" @click=\"deleteOrderDocumentConfirmDialog = false;\">Nevermind\n </v-btn>\n <v-btn :loading=\"orderLoading.deleteOrderDocument\" color=\"red text-white\" size=\"small\" @click=\"deleteOrderDocumentCommit($route.params.uuid);\">\n Delete\n </v-btn>\n </v-card-actions>\n </v-card>\n </v-dialog>\n </div>\n</template>\n<script lang=\"ts\" setup>\nimport {computed, ref} from 'vue';\nimport {useRoute, useRouter} from 'vue-router';\nimport {EventBus} from '@/plugins/eventBus';\nimport {useOrders} from '@/composables/useOrders';\nimport {useAppSettings} from '@/composables/useAppSettings';\nimport StartOrderDocumentDownloadDialog from '@/components/dashboard/dialogs/StartOrderDocumentDownloadDialog.vue';\nimport {OrderDocumentType} from '@/types';\n\nconst route = useRoute();\nconst router = useRouter();\nconst {orderDocument, orderLoading, updateOrderDocument, deleteOrderDocument} = useOrders();\nconst {device} = useAppSettings();\n\n// Reactive state\nconst deleteOrderDocumentConfirmDialog = ref(false);\n\n// Computed properties\nconst orderBookingId = computed<string>(() => orderDocument.value?.order?.b_id);\nconst documentType = computed<OrderDocumentType['type']>(() => orderDocument.value?.type);\nconst documentCanBeFinalized = computed(() =>\n documentType.value === 'Document::Invoice' && !orderDocument.value?.finalized\n);\n\n// Methods\nconst finalizeDocumentInit = () => {\n updateOrderDocument({\n documentUuid: orderDocument.value?.uuid,\n attributes: {\n finalize: true,\n },\n });\n};\n\nconst deleteOrderDocumentInit = () => {\n deleteOrderDocumentConfirmDialog.value = true;\n};\n\nconst deleteOrderDocumentCommit = async (uuid: string) => {\n console.log('deleteOrderDocumentCommit');\n try {\n await deleteOrderDocument(uuid);\n router.push('/documents');\n } catch (error) {\n console.error('Failed to delete document:', error);\n }\n};\n\nconst printElem = () => {\n window.print();\n};\n\nconst downloadOrderDocumentInit = () => {\n console.log('downloadOrderDocumentInit');\n EventBus.$emit('open-download-order-document-dialog', route.params.uuid);\n};\n</script>\n\n\n<style lang=\"scss\">\n.v-btn-group {\n vertical-align: middle;\n border-radius: 2px;\n display: inline-flex;\n\n .v-btn {\n border-radius: 0;\n justify-content: center;\n margin: 0;\n min-width: auto;\n padding: 0 8px;\n width: auto;\n\n &:not(:last-child) {\n border-right: 1px solid transparent;\n }\n\n &:first-child {\n border-radius: 4px 0 0 4px;\n }\n\n &:last-child {\n border-radius: 0 4px 4px 0;\n }\n }\n}\n</style>\n","import type {RouteRecordRaw} from 'vue-router';\nimport DocumentsDashboardLayoutV2 from '@/views/documentsV2/DocumentsDashboardV2.vue';\n\nimport AddFields from '@/views/documentsV2/NewDocumentFieldsV2.vue';\n\nimport Home from '@/views/documents/Home.vue';\nimport NewDocument from \"@/views/documents/NewDocument.vue\";\nimport SingleDocument from \"@/views/documents/SingleDocument.vue\";\nimport navRightActions from '@/components/dashboard/navActions/OrderDocumentOptions.vue';\nimport {CommonRouteMeta} from \"@/types\";\n\nconst BaseDashboard = () => import('@/views/dashboard/BaseDashboard.vue');\n\nconst documentRoutes: RouteRecordRaw[] = [\n {\n path: '/documents',\n component: BaseDashboard,\n meta: {\n title: 'documents',\n icon: 'mdi-file-document-outline',\n noCache: false,\n showInMenu: true,\n middleware: ['auth'],\n layout: 'Dashboard',\n } as CommonRouteMeta,\n children: [\n {\n path: '',\n component: Home,\n name: 'documents.index',\n meta: {title: 'Documents', icon: 'mdi-file-document-outline', noCache: false},\n },\n {\n path: ':uuid',\n components: {\n default: SingleDocument,\n navRightActions: navRightActions\n },\n name: 'documents.show',\n meta: {title: '', icon: 'mdi-file-document-outline', noCache: false},\n },\n {\n path: 'prepare/:uuid',\n component: NewDocument,\n name: 'documents.prepare',\n meta: {title: 'Document Prep', icon: 'mdi-file-document-outline', noCache: false},\n },\n {\n path: 'new',\n component: NewDocument,\n name: 'documents.new',\n meta: {title: 'Document New', icon: 'mdi-file-document-outline', noCache: false},\n },\n ],\n },\n {\n path: '/documents-v2',\n component: DocumentsDashboardLayoutV2,\n meta: {hidden: true, middleware: ['auth'], layout: 'Dashboard', noCache: false} as CommonRouteMeta,\n children: [\n {\n path: '',\n component: Home,\n name: 'documentsv2.index',\n meta: {title: '', icon: 'mdi-file-document-outline', noCache: false},\n },\n {\n path: 'prepare/:uuid/add-fields',\n component: AddFields,\n name: 'documentsv2.fields',\n meta: {title: 'Document Add Fields', icon: 'mdi-file-document-outline', noCache: false},\n },\n ],\n },\n];\n\nexport default documentRoutes;\n","import type {RouteRecordRaw} from 'vue-router';\nimport {CommonRouteMeta} from '@/types';\n\n// Lazy-load the BaseDashboard component\nconst loadBaseDashboard = () => import('@/views/dashboard/BaseDashboard.vue');\nconst loadBasePerks = () => import('@/views/dashboard/perks/BasePerks.vue');\n\n\n// Define perks routes\nconst perksRoutes: RouteRecordRaw[] = [\n {\n path: '/perks',\n component: loadBaseDashboard,\n meta: {\n title: 'Perks',\n icon: 'mdi-cash-multiple',\n noCache: false,\n isBase: true,\n middleware: ['auth'],\n layout: 'Dashboard',\n } as CommonRouteMeta,\n children: [\n {\n path: '',\n component: loadBasePerks,\n name: 'perks.index',\n meta: {\n title: 'Perks',\n icon: 'mdi-car-convertible',\n noCache: false,\n isBase: true,\n } as CommonRouteMeta,\n },\n ],\n }\n];\n\nexport default perksRoutes;\n","import type {RouteRecordRaw} from 'vue-router';\nimport {CommonRouteMeta} from \"@/types\";\n\nconst BaseDashboard = () => import('@/views/dashboard/BaseDashboard.vue');\n\nconst notifications: RouteRecordRaw[] = [\n {\n path: '/notifications',\n component: BaseDashboard,\n meta: {\n title: 'notifications',\n icon: 'mdi-newspaper-variant-multiple-outline',\n noCache: false,\n middleware: ['auth'],\n layout: 'Dashboard',\n } as CommonRouteMeta,\n children: [\n {\n path: '',\n components: {\n default: () => import('@/views/dashboard/notifications/BaseNotifications.vue'),\n },\n name: 'notifications.index',\n meta: {title: 'Notifications', icon: 'mdi-account-outline', noCache: false},\n },\n ],\n }\n];\n\nexport default notifications;\n","import type {RouteMeta, RouteRecordRaw} from 'vue-router';\nimport type {CommonRouteMeta} from '@/types';\n\nconst DashboardLayout = () => import('@/views/dashboard/BaseDashboard.vue');\n\n/** Views */\nconst BaseListings = () => import('@/views/dashboard/listings/BaseListings.vue');\nconst NewListings = () => import('@/views/dashboard/listings/New.vue');\nconst SingleListing = () => import('@/views/dashboard/listings/ListingSingle.vue');\nconst ListingCalendar = () => import('@/views/dashboard/listings/FWCalendarVue.vue');\nconst ListingAnalytics = () => import('@/views/dashboard/analytics/BaseAnalytics.vue');\n\n/** Nav Actions */\nconst AddNewListingNavAction = () => import('@/components/dashboard/navActions/AddNewListing.vue');\nconst SaveListingNavAction = () => import('@/components/dashboard/navActions/SaveCurrentListing.vue');\nconst AddListingSaveNavAction = () => import('@/components/dashboard/navActions/AddListingSave.vue');\n\n\n// Extend the CommonRouteMeta interface\ninterface ExtendedRouteMeta extends RouteMeta, CommonRouteMeta {\n isBase?: boolean;\n permissions?: string[];\n resource?: string;\n showInMenu?: boolean;\n middleware?: string[];\n layout?: string;\n}\n\nconst listingRoutes: RouteRecordRaw[] = [\n {\n path: '/listings',\n component: DashboardLayout,\n redirect: _to => {\n return {name: 'listing.index'};\n },\n meta: {\n title: 'listings',\n icon: 'mdi-car-convertible',\n noCache: false,\n isBase: true,\n permissions: ['listings_view'],\n showInMenu: true,\n middleware: ['auth'],\n layout: 'Dashboard',\n } as CommonRouteMeta,\n children: [\n {\n path: 'all',\n components: {\n default: BaseListings,\n navRightActions: AddNewListingNavAction,\n },\n name: 'listing.index',\n meta: {title: 'Listings', icon: 'mdi-car-convertible', noCache: false} as ExtendedRouteMeta,\n },\n {\n path: 'new',\n components: {\n default: NewListings,\n navRightActions: AddListingSaveNavAction,\n },\n name: 'listing.new',\n meta: {title: 'New Listing', icon: 'mdi-car-convertible', noCache: false} as ExtendedRouteMeta,\n },\n {\n path: 'calendar',\n components: {\n default: ListingCalendar,\n },\n name: 'listing.calendar',\n meta: {\n title: 'Single Listing',\n icon: 'mdi-car-convertible',\n noCache: false,\n resource: 'l_id'\n } as ExtendedRouteMeta,\n },\n {\n path: ':l_id',\n components: {\n default: SingleListing,\n navRightActions: SaveListingNavAction,\n },\n name: 'listing.single',\n meta: {\n title: 'Single Listing',\n icon: 'mdi-car-convertible',\n noCache: false,\n resource: 'l_id',\n isBase: false\n } as ExtendedRouteMeta,\n },\n {\n path: ':l_id/analytics',\n components: {\n default: ListingAnalytics,\n },\n name: 'listing.single.analytics',\n meta: {\n title: 'Listing Analytics',\n icon: 'mdi-car-convertible',\n noCache: false,\n resource: 'l_id'\n } as ExtendedRouteMeta,\n },\n ],\n }\n];\n\nexport default listingRoutes;\n","import type {RouteRecordRaw} from 'vue-router';\nimport {CommonRouteMeta} from \"@/types\";\n\nconst BaseDashboard = () => import('@/views/dashboard/BaseDashboard.vue');\n\n\nconst connectionsRoutes: RouteRecordRaw[] = [\n {\n path: '/connections',\n component: BaseDashboard,\n meta: {\n title: 'connections',\n icon: 'mdi-toy-brick',\n noCache: true,\n middleware: ['auth'],\n layout: 'Dashboard',\n showInMenu: true,\n } as CommonRouteMeta,\n children: [\n {\n path: '',\n components: {\n default: () => import(/* webpackChunkName: \"connections\" */ '@/views/connections/index.vue'),\n },\n name: 'connections',\n meta: {title: 'connections', icon: 'mdi-toy-brick', noCache: true},\n },\n {\n path: 'axle',\n components: {\n default: () => import(/* webpackChunkName: \"axle\" */ '@/views/connections/axle/Axle.vue'),\n },\n meta: {title: 'Axle', icon: 'mdi-toy-brick', noCache: false},\n children: [\n {\n path: '',\n components: {\n default: () => import(/* webpackChunkName: \"axle\" */ '@/views/connections/axle/BaseAxle.vue'),\n },\n name: 'connections.axle',\n },\n ],\n },\n {\n path: 'turo',\n components: {\n default: () => import(/* webpackChunkName: \"turo\" */ '@/views/connections/turo/Turo.vue'),\n },\n meta: {title: 'Turo', icon: 'mdi-toy-brick', noCache: false},\n children: [\n {\n path: '',\n components: {\n default: () => import(/* webpackChunkName: \"turo\" */ '@/views/connections/turo/BaseTuro.vue'),\n },\n name: 'connections.turo',\n },\n {\n path: 'all/bookings',\n components: {\n default: () => import(/* webpackChunkName: \"turo\" */ '@/views/connections/turo/Bookings.vue'),\n },\n name: 'connections.turo.bookings',\n meta: {title: 'bookings'},\n },\n {\n path: ':turo_uuid/bookings/:b_id',\n components: {\n default: () => import(/* webpackChunkName: \"turo\" */ '@/views/connections/turo/BookingSingle.vue'),\n },\n name: 'connections.turo.bookings.single',\n meta: {title: 'booking single'},\n },\n {\n path: 'all/vehicles',\n components: {\n default: () => import(/* webpackChunkName: \"turo\" */ '@/views/connections/turo/Vehicles.vue'),\n },\n name: 'connections.turo.vehicles',\n meta: {title: 'vehicles'},\n },\n {\n path: 'all/messages',\n components: {\n default: () => import(/* webpackChunkName: \"turo\" */ '@/views/connections/turo/Messages.vue'),\n },\n name: 'connections.turo.messages',\n meta: {title: 'messages'},\n },\n {\n path: 'all/messages2',\n components: {\n default: () => import(/* webpackChunkName: \"turo\" */ '@/views/connections/turo/TuroMessages.vue'),\n },\n name: 'connections.turo.messages2',\n meta: {title: 'messages'},\n },\n {\n path: 'all/emails',\n components: {\n default: () => import(/* webpackChunkName: \"turo\" */ '@/views/connections/turo/Emails.vue'),\n },\n name: 'connections.turo.emails',\n meta: {title: 'emails'},\n },\n {\n path: 'all/earnings',\n components: {\n default: () => import(/* webpackChunkName: \"turo\" */ '@/views/connections/turo/Earnings.vue'),\n },\n name: 'connections.turo.earnings',\n meta: {\n title: 'earnings',\n permissions: ['orders_financials'],\n },\n },\n {\n path: 'all/reimbursements',\n components: {\n default: () => import(/* webpackChunkName: \"turo\" */ '@/views/connections/turo/Reimbursements.vue'),\n },\n name: 'connections.turo.reimbursements',\n meta: {\n title: 'earnings',\n permissions: ['orders_financials'],\n },\n },\n {\n path: 'change-request',\n components: {\n default: () => import(/* webpackChunkName: \"turo\" */ '@/views/connections/turo/ChangeRequestSettings.vue'),\n },\n name: 'connections.turo.changeRequest',\n meta: {title: 'Change Request'},\n },\n {\n path: 'feedback',\n components: {\n default: () => import(/* webpackChunkName: \"turo\" */ '@/views/connections/turo/Feedback.vue'),\n },\n name: 'connections.turo.feedback',\n meta: {title: 'Feedback'},\n },\n {\n path: ':turo_uuid',\n components: {\n default: () => import(/* webpackChunkName: \"turo\" */ '@/views/connections/turo/SingleTuro.vue'),\n },\n name: 'connections.turo.single',\n meta: {title: 'Turo home'},\n },\n {\n path: ':turo_uuid/vehicles',\n components: {\n default: () => import(/* webpackChunkName: \"turo\" */ '@/views/connections/turo/SingleTuroVehicles.vue'),\n },\n name: 'connections.turo.single.vehicles',\n meta: {title: 'Turo Vehicles'},\n },\n {\n path: ':turo_uuid/research',\n components: {\n default: () => import(/* webpackChunkName: \"turo\" */ '@/views/connections/turo/Research.vue'),\n },\n name: 'connections.turo.single.research',\n meta: {title: 'Turo Vehicles'},\n },\n ],\n },\n {\n path: 'getaround',\n components: {\n default: () => import(/* webpackChunkName: \"getaround\" */ '@/views/connections/getaround/Getaround.vue'),\n },\n children: [\n {\n path: '',\n components: {\n default: () => import(/* webpackChunkName: \"getaround\" */ '@/views/connections/getaround/BaseGetaround.vue'),\n },\n name: 'connections.getaround',\n },\n {\n path: ':getaround_uuid',\n components: {\n default: () => import(/* webpackChunkName: \"getaround\" */ '@/views/connections/getaround/SingleGetaround.vue'),\n },\n name: 'connections.getaround.single',\n },\n {\n path: ':getaround_uuid/vehicles',\n components: {\n default: () => import(/* webpackChunkName: \"getaround\" */ '@/views/connections/getaround/SingleGetaroundVehicles.vue'),\n },\n name: 'connections.getaround.single.vehicles',\n },\n {\n path: ':getaround_uuid/bookings',\n components: {\n default: () => import(/* webpackChunkName: \"getaround\" */ '@/views/connections/getaround/SingleGetaroundBookings.vue'),\n },\n name: 'connections.getaround.single.bookings',\n },\n {\n path: ':getaround_uuid/bookings/:reservation_id',\n components: {\n default: () => import(/* webpackChunkName: \"getaround\" */ '@/views/connections/getaround/SingleGetaroundOneReservation.vue'),\n },\n name: 'connections.getaround.single.booking',\n },\n {\n path: 'bookings',\n components: {\n default: () => import(/* webpackChunkName: \"getaround\" */ '@/views/connections/getaround/Bookings.vue'),\n },\n name: 'connections.getaround.bookings',\n meta: {title: 'bookings'},\n },\n ],\n },\n {\n path: 'tesla',\n components: {\n default: () => import(/* webpackChunkName: \"tesla\" */ '@/views/connections/tesla/Tesla.vue'),\n },\n meta: {title: 'Tesla', icon: 'mdi-toy-brick', noCache: true},\n children: [\n {\n path: '',\n components: {\n default: () => import(/* webpackChunkName: \"tesla\" */ '@/views/connections/tesla/BaseTesla.vue'),\n },\n name: 'connections.tesla',\n },\n {\n path: 'invoices',\n components: {\n default: () => import(/* webpackChunkName: \"tesla\" */ '@/views/connections/tesla/Invoices.vue'),\n },\n name: 'connections.tesla.invoices',\n },\n {\n path: 'vehicles',\n components: {\n default: () => import(/* webpackChunkName: \"tesla\" */ '@/views/connections/tesla/Vehicles.vue'),\n },\n name: 'connections.tesla.vehicles',\n },\n {\n path: ':tesla_uuid',\n components: {\n default: () => import(/* webpackChunkName: \"tesla\" */ '@/views/connections/tesla/TeslaSingle.vue'),\n },\n name: 'connections.tesla.single',\n },\n {\n path: 'vehicles/:tesla_uuid',\n components: {\n default: () => import(/* webpackChunkName: \"tesla\" */ '@/views/connections/tesla/VehicleSingle.vue'),\n },\n name: 'connections.tesla.vehicles.single',\n },\n ],\n },\n {\n path: 'outdoorsy',\n components: {\n default: () => import(/* webpackChunkName: \"outdoorsy\" */ '@/views/connections/outdoorsy/Outdoorsy.vue'),\n },\n meta: {title: 'Outdoorsy', icon: 'mdi-toy-brick', noCache: true},\n children: [\n {\n path: '',\n components: {\n default: () => import(/* webpackChunkName: \"outdoorsy\" */ '@/views/connections/outdoorsy/BaseOutdoorsy.vue'),\n },\n name: 'connections.outdoorsy',\n },\n {\n path: ':provider_uuid',\n components: {\n default: () => import(/* webpackChunkName: \"outdoorsy\" */ '@/views/connections/outdoorsy/OutdoorsySingle.vue'),\n },\n name: 'connections.outdoorsy.single',\n },\n {\n path: ':provider_uuid/listings',\n components: {\n default: () => import(/* webpackChunkName: \"outdoorsy\" */ '@/views/connections/outdoorsy/SingleOutdoorsyListings.vue'),\n },\n name: 'connections.outdoorsy.single.listings',\n meta: {title: 'Outdoorsy Vehicles'},\n },\n {\n path: ':provider_uuid/bookings',\n components: {\n default: () => import(/* webpackChunkName: \"outdoorsy\" */ '@/views/connections/outdoorsy/SingleOutdoorsyBookings.vue'),\n },\n name: 'connections.outdoorsy.single.bookings',\n meta: {title: 'Outdoorsy Vehicles'},\n },\n {\n path: 'invoices',\n components: {\n default: () => import(/* webpackChunkName: \"outdoorsy\" */ '@/views/connections/tesla/Invoices.vue'),\n },\n name: 'connections.outdoorsy.invoices',\n },\n {\n path: 'vehicles',\n components: {\n default: () => import(/* webpackChunkName: \"outdoorsy\" */ '@/views/connections/tesla/Vehicles.vue'),\n },\n name: 'connections.outdoorsy.vehicles',\n },\n ],\n },\n {\n path: 'hq-rentals',\n components: {\n default: () => import(/* webpackChunkName: \"hq-rentals\" */ '@/views/connections/hq-rentals/HQRentals.vue'),\n },\n meta: {title: 'HQ Rentals', icon: 'mdi-toy-brick', noCache: true},\n children: [\n {\n path: '',\n components: {\n default: () => import(/* webpackChunkName: \"hq-rentals\" */ '@/views/connections/hq-rentals/BaseHQRentals.vue'),\n },\n name: 'connections.hq-rentals',\n },\n {\n path: ':provider_uuid',\n components: {\n default: () => import(/* webpackChunkName: \"hq-rentals\" */ '@/views/connections/hq-rentals/HQRentalsSingle.vue'),\n },\n name: 'connections.hq-rentals.single',\n },\n {\n path: ':provider_uuid/listings',\n components: {\n default: () => import(/* webpackChunkName: \"hq-rentals\" */ '@/views/connections/hq-rentals/SingleHQRentalsListings.vue'),\n },\n name: 'connections.hq-rentals.single.listings',\n meta: {title: 'HQ Rentals Vehicles'},\n },\n {\n path: ':provider_uuid/bookings',\n components: {\n default: () => import(/* webpackChunkName: \"hq-rentals\" */ '@/views/connections/hq-rentals/SingleHQRentalsBookings.vue'),\n },\n name: 'connections.hq-rentals.single.bookings',\n meta: {title: 'HQ Rentals Vehicles'},\n },\n {\n path: ':provider_uuid/contacts',\n components: {\n default: () => import(/* webpackChunkName: \"hq-rentals\" */ '@/views/connections/hq-rentals/SingleHQRentalsContacts.vue'),\n },\n name: 'connections.hq-rentals.single.contacts',\n meta: {title: 'HQ Rentals Contacts'},\n },\n ],\n },\n {\n path: 'bouncie',\n components: {\n default: () => import(/* webpackChunkName: \"bouncie\" */ '@/views/connections/bouncie/Bouncie.vue'),\n },\n meta: {title: 'Bouncie', icon: 'mdi-toy-brick', noCache: true},\n children: [\n {\n path: '',\n components: {\n default: () => import(/* webpackChunkName: \"bouncie\" */ '@/views/connections/bouncie/BaseBouncie.vue'),\n },\n name: 'connections.bouncie',\n },\n {\n path: 'vehicles',\n components: {\n default: () => import(/* webpackChunkName: \"bouncie\" */ '@/views/connections/bouncie/Vehicles.vue'),\n },\n name: 'connections.bouncie.vehicles',\n },\n {\n path: 'vehicles/:bouncie_uuid',\n components: {\n default: () => import(/* webpackChunkName: \"bouncie\" */ '@/views/connections/bouncie/VehicleSingle.vue'),\n },\n name: 'connections.bouncie.vehicles.single',\n },\n ],\n },\n {\n path: 'stripe',\n components: {\n default: () => import('@/views/connections/stripe/Stripe.vue'),\n },\n meta: {title: 'Stripe', icon: 'mdi-toy-brick', noCache: true},\n children: [\n {\n path: '',\n components: {\n default: () => import('@/views/connections/stripe/StripeBase.vue'),\n },\n name: 'connections.stripe',\n meta: {title: 'Stripe', icon: 'mdi-toy-brick', noCache: true},\n },\n {\n path: 'identities',\n components: {\n default: () => import('@/views/connections/stripe/StripeIdentities.vue'),\n },\n name: 'connections.stripe.identities',\n },\n ],\n },\n {\n path: 'lula',\n components: {\n default: () => import('@/views/connections/lula/Lula.vue'),\n },\n meta: {title: 'Lula', icon: 'mdi-toy-brick', noCache: true},\n children: [\n {\n path: '',\n components: {\n default: () => import('@/views/connections/lula/LulaBase.vue'),\n },\n name: 'connections.lula',\n meta: {title: 'Lula', icon: 'mdi-toy-brick', noCache: true},\n },\n {\n path: ':lula_uuid',\n components: {\n default: () => import(/* webpackChunkName: \"lula\" */ '@/views/connections/lula/LulaAccountSingle.vue'),\n },\n name: 'connections.lula.account',\n meta: {title: 'Lula'},\n },\n {\n path: ':lula_uuid/vehicles',\n components: {\n default: () => import(/* webpackChunkName: \"lula\" */ '@/views/connections/lula/LulaVehicles.vue'),\n },\n name: 'connections.lula.vehicles',\n meta: {title: 'Lula Vehicles'},\n },\n ],\n },\n {\n path: 'tolls',\n components: {\n default: () => import(/* webpackChunkName: \"tolls\" */ '@/views/connections/tolls/Tolls.vue'),\n },\n meta: {title: 'Tolls', icon: 'mdi-toy-brick', noCache: true},\n children: [\n {\n path: '',\n components: {\n default: () => import(/* webpackChunkName: \"tolls\" */ '@/views/connections/tolls/TollsBase.vue'),\n },\n name: 'connections.tolls',\n },\n {\n path: 'transactions',\n components: {\n default: () => import(/* webpackChunkName: \"tolls\" */ '@/views/connections/tolls/TollsTransactions.vue'),\n },\n name: 'connections.tolls.transactions',\n },\n ],\n },\n ],\n }\n];\n\nexport default connectionsRoutes;\n","import type {RouteRecordRaw} from 'vue-router';\nimport {CommonRouteMeta} from \"@/types\";\n\n// Lazy-loaded components\nconst BaseDashboard = () => import('@/views/dashboard/BaseDashboard.vue');\nconst BaseOrders = () => import('@/views/dashboard/orders/BaseOrders.vue');\nconst OrderNewV2 = () => import('@/views/dashboard/orders/OrderNewV2.vue');\nconst OrderSingleV2 = () => import('@/views/dashboard/orders/OrderSingleV2.vue');\nconst TheRightSidebar = () => import('@/components/dashboard/TheRightSidebar.vue');\nconst AddNewOrder = () => import('@/components/dashboard/navActions/AddNewOrder.vue');\nconst NewOrderOptions = () => import('@/components/dashboard/navActions/NewOrderOptions.vue');\nconst SingleOrderOptions = () => import('@/components/dashboard/navActions/SingleOrderOptions.vue');\n\n\nconst ordersRoutes: RouteRecordRaw[] = [\n {\n path: '/orders',\n components: {\n default: BaseDashboard,\n },\n meta: {\n title: 'orders',\n icon: 'mdi-newspaper-variant-multiple-outline',\n noCache: false,\n isBase: true,\n permissions: ['orders_view'],\n showInMenu: true,\n middleware: ['auth'],\n layout: 'Dashboard',\n } as CommonRouteMeta,\n children: [\n {\n path: '',\n components: {\n default: BaseOrders,\n navRightActions: AddNewOrder,\n },\n name: 'orders.index',\n meta: {title: 'Orders', icon: 'mdi-account-outline', noCache: false, isBase: true},\n },\n {\n path: 'upcoming',\n components: {\n default: BaseOrders,\n navRightActions: AddNewOrder,\n },\n name: 'orders.index.upcoming',\n meta: {title: 'Orders Upcoming', icon: 'mdi-account-outline', noCache: false, isBase: true},\n },\n {\n path: 'overdue',\n components: {\n default: BaseOrders,\n navRightActions: AddNewOrder,\n },\n name: 'orders.index.overdue',\n meta: {title: 'Orders Overdue', icon: 'mdi-account-outline', noCache: false, isBase: true},\n },\n {\n path: 'new',\n components: {\n default: OrderNewV2,\n navRightActions: NewOrderOptions,\n },\n name: 'orders.new',\n meta: {title: 'New', icon: 'mdi-account-outline', noCache: false, hasRightSidebar: false},\n },\n {\n path: 'new-order',\n components: {\n default: OrderNewV2,\n rightSidebar: TheRightSidebar,\n navRightActions: NewOrderOptions,\n },\n name: 'orders.newV2',\n meta: {title: 'New', icon: 'mdi-account-outline', noCache: false, hasRightSidebar: true},\n },\n {\n path: ':b_id',\n components: {\n default: OrderSingleV2,\n rightSidebar: TheRightSidebar,\n navRightActions: SingleOrderOptions,\n },\n name: 'orders.single',\n meta: {\n title: 'order',\n icon: 'mdi-account-outline',\n noCache: false,\n hasRightSidebar: true,\n resource: 'b_id',\n isBase: false\n },\n },\n {\n path: 'v2/:b_id',\n components: {\n default: OrderSingleV2,\n rightSidebar: TheRightSidebar,\n navRightActions: SingleOrderOptions,\n },\n name: 'orders.singleV2',\n meta: {title: 'order', icon: 'mdi-account-outline', noCache: false, hasRightSidebar: true},\n },\n ],\n }\n];\n\nexport default ordersRoutes;\n","import type {RouteRecordRaw} from 'vue-router';\nimport {CommonRouteMeta} from '@/types';\n\nconst BaseDashboard = () => import('@/views/dashboard/BaseDashboard.vue');\nconst BaseCustomers = () => import('@/views/dashboard/customers/BaseCustomers.vue');\nconst CustomerSingle = () => import('@/views/dashboard/customers/CustomerSingle.vue');\nconst CustomerRightSidebar = () => import('@/components/dashboard/rightSideBars/CustomerRightSidebar.vue');\nconst NewCustomer = () => import('@/views/dashboard/customers/New.vue');\nconst ImportCustomers = () => import('@/views/dashboard/customers/ImportCustomers.vue');\nconst AddNewCustomer = () => import('@/components/dashboard/navActions/AddNewCustomer.vue');\n\nconst customerRoutes: RouteRecordRaw[] = [\n {\n path: '/customers',\n components: {\n default: BaseDashboard,\n },\n meta: {\n title: 'customers',\n icon: 'mdi-account-outline',\n noCache: false,\n isBase: true,\n permissions: ['customers_view'],\n showInMenu: true,\n middleware: ['auth'],\n layout: 'Dashboard',\n } as CommonRouteMeta,\n children: [\n {\n path: '',\n components: {\n default: BaseCustomers,\n navRightActions: AddNewCustomer,\n },\n name: 'customers.index',\n meta: {title: 'customers', icon: 'mdi-account-outline', noCache: false, isBase: true},\n },\n {\n path: 'import',\n component: ImportCustomers,\n name: 'customers.import',\n meta: {title: 'Import', icon: 'mdi-account-outline', noCache: false},\n },\n {\n path: 'new',\n component: NewCustomer,\n name: 'customers.new',\n meta: {title: 'New', icon: 'mdi-account-outline', noCache: false},\n },\n {\n path: ':r_id',\n components: {\n default: CustomerSingle,\n rightSidebar: CustomerRightSidebar,\n },\n name: 'customers.single',\n meta: {\n title: 'customer',\n icon: 'mdi-account-outline',\n noCache: false,\n resource: 'r_id',\n hasRightSidebar: true,\n isBase: false\n },\n },\n ],\n }\n];\n\nexport default customerRoutes;\n","import type {RouteRecordRaw} from 'vue-router';\nimport {CommonRouteMeta} from \"@/types\";\n\nconst BaseDashboard = () => import('@/views/dashboard/BaseDashboard.vue');\n\nconst listingRoutes: RouteRecordRaw[] = [\n {\n path: '/trip-extras',\n component: BaseDashboard,\n meta: {\n title: 'Trip Extras',\n icon: 'mdi-car-convertible',\n noCache: false,\n isBase: true,\n permissions: ['listings_view'],\n middleware: ['auth'],\n layout: 'Dashboard',\n } as CommonRouteMeta,\n children: [\n {\n path: '',\n components: {\n default: () => import('@/views/dashboard/listings/tripExtras/BaseTripExtras.vue'),\n navRightActions: () => import('@/components/dashboard/navActions/AddNewTripExtra.vue'),\n },\n name: 'tripExtras.index',\n meta: {title: 'Trip Extras', icon: 'mdi-car-convertible', noCache: false, isBase: true},\n },\n {\n path: 'new',\n components: {\n default: () => import('@/views/dashboard/listings/tripExtras/NewTripExtra.vue'),\n navRightActions: () => import('@/components/dashboard/navActions/AddExtraSaveBtn.vue'),\n },\n name: 'extra.new',\n meta: {title: 'New Extra', icon: 'mdi-car-convertible', noCache: false},\n },\n ],\n }\n];\n\nexport default listingRoutes;\n","<template>\n <nav class=\"Header-igPdDJ ikpJHJ\">\n <div class=\"BHeader-iqbMU gDKljt\">\n <div class=\"Group-kSMArG jbSlEt\">\n <v-btn size=\"small\" variant=\"outlined\">\n <v-icon>mdi-arrow-left</v-icon>\n </v-btn>\n <v-btn size=\"small\" variant=\"outlined\">\n <v-icon class=\"mr-2\" size=\"small\">mdi-file-document-outline</v-icon>\n Templates\n </v-btn>\n <v-btn size=\"small\" variant=\"outlined\">\n <v-icon class=\"mr-2\" size=\"small\">mdi-brush</v-icon>\n Theme settings\n </v-btn>\n </div>\n <div class=\"Preview-igMYrV fvcbKx\">\n <v-btn variant=\"outlined\">\n <div class=\"flex flex-col\">\n <v-icon class=\"mr-2\" size=\"small\">mdi-laptop</v-icon>\n Preview mode\n </div>\n </v-btn>\n </div>\n <div class=\"Group-kSMArG jbSlEt\">\n <v-btn size=\"small\" variant=\"outlined\">\n <v-icon class=\"mr-2\" size=\"small\">mdi-brush</v-icon>\n Preview\n </v-btn>\n <v-btn size=\"small\" variant=\"outlined\">\n <v-icon class=\"mr-2\" size=\"small\">mdi-brush</v-icon>\n Publish\n </v-btn>\n </div>\n </div>\n </nav>\n</template>\n\n<script lang=\"ts\" setup>\n</script>\n\n<style>\n\n.ikpJHJ {\n border-bottom: 1px solid rgb(226, 230, 235);\n height: 62px;\n top: 0;\n position: fixed;\n padding: 0 26px;\n background: rgb(255, 255, 255);\n z-index: 30;\n transition: all 250ms cubic-bezier(0.86, 0, 0.07, 1) 0s;\n overflow: hidden;\n width: 100%\n}\n\n.fMkfAf .Header-igPdDJ {\n padding: 0 18px;\n}\n\n.gDKljt {\n position: relative;\n display: flex;\n -webkit-box-pack: justify;\n justify-content: space-between;\n -webkit-box-align: center;\n align-items: center;\n height: 99%;\n}\n\n.jbSlEt {\n display: flex;\n -webkit-box-align: center;\n align-items: center;\n}\n\n.buJHmi {\n display: block;\n width: 100%;\n}\n\n.jbSlEt > :not(:last-of-type), .jbSlEt .Disable-iDtbRZ:not(:last-of-type) {\n margin-right: 18px;\n}\n</style>\n","<template>\n <nav class=\"Sidebar-ewrzQP hJbBaq\" data-tid=\"Sidebar\" open=\"\" width=\"320px\">\n <div class=\"Div-bMiTSW Inner-eASQkV fNYben felMTq\">\n <div class=\"BSidebar-loQfvV kWdRwd\">\n <div aria-expanded=\"false\" class=\"Wrapper-iVPPu\">\n <div class=\"Trigger-huDzbV eBqQQq\">\n <div class=\"BTemplateSelect-cjqqCH fmnNSR\" data-tid=\"Template select\">\n <div class=\"H3-bOhkOq lgizXY\">\n <v-icon>mdi-file-document-outline</v-icon>\n <div class=\"Div-bMiTSW Spacer-dThvcf jaLOqC\"></div>\n <div class=\"Label-edLtQd fZbXLc\">{{ themeName }}</div>\n <div class=\"Div-bMiTSW Spacer-dThvcf jaLOqC\"></div>\n <i class=\"I-gmFDEA Icon-chbHoy eaYeOY hGUdVH far fa-chevron-down fa-fw\"></i>\n <v-icon>mdi-chevron-down</v-icon>\n </div>\n </div>\n </div>\n </div>\n <div class=\"Sections-ivYnKr kQUSAR\">\n <div class=\"Container-goTTRW cneSZt\">\n <div class=\"Section-eCkBMz iwkHtv\">\n <div class=\"InnerContainer-dPNjJg gAUqSD\">\n <i class=\"I-gmFDEA Icon-chbHoy eaYeOY hMXRVX far fa-fw fa-fw\"></i>\n </div>\n <div class=\"InnerContainer-dPNjJg kwXbLo\" @mouseleave=\"containerHoverLeave\" @mouseover=\"containerHover\">\n <div class=\"LabelContainer-XFiUr kuxGbJ\">\n <label class=\"Label-eJXSuD fUNwul\" cursor=\"pointer\">Header</label></div>\n <div class=\"Div-bMiTSW Spacer-dThvcf jaLOqC\"></div>\n <div class=\"Div-bMiTSW Description-dTYEvj dfsrYj\">Edit for all pages</div>\n </div>\n </div>\n </div>\n <hr class=\"Hr-bhdsCb cfZQHO\">\n <div class=\"sortable-container\" data-tid=\"Sections\">\n <div v-for=\"(section,i) in orderedThemeSections\" :key=\"i\" class=\"Container-goTTRW cneSZt\">\n <div class=\"Section-eCkBMz iwkHtv\">\n <div v-if=\"showChevronUp(i)\" class=\"InnerContainer-dPNjJg gvmluV\">\n <v-icon class=\"I-gmFDEA Icon-chbHoy eaYeOY hMXRVX far fa-chevron-up fa-fw\">mdi-chevron-up</v-icon>\n </div>\n <div v-if=\"!showChevronUp(i)\" class=\"InnerContainer-dPNjJg gAUqSD\">\n <i class=\"I-gmFDEA Icon-chbHoy eaYeOY hMXRVX far fa-fw fa-fw\"></i>\n </div>\n <div class=\"InnerContainer-dPNjJg kwXbLo\" @mouseleave=\"containerHoverLeave(i)\" @mouseover=\"containerHover(i)\">\n <div class=\"LabelContainer-XFiUr kuxGbJ\">\n <label class=\"Label-eJXSuD fUNwul\">\n {{ sectionLabel(i) }} {{ section.disabled }}\n </label>\n </div>\n <div class=\"Div-bMiTSW Spacer-dThvcf jaLOqC\"></div>\n <v-icon v-if=\"section.disabled\" class=\"I-gmFDEA Icon-chbHoy eaYeOY hMXRVX far fa-eye fa-fw\" size=\"small\">\n mdi-eye-outline\n </v-icon>\n <v-icon v-if=\"!section.disabled\" class=\"I-gmFDEA Icon-chbHoy eaYeOY hMXRVX far fa-eye fa-fw\" size=\"small\">\n mdi-eye-outline\n </v-icon>\n <div class=\"Div-bMiTSW Spacer-dThvcf fbTExq\"></div>\n <v-icon class=\"I-gmFDEA Icon-chbHoy eaYeOY hMXRVX far fa-grip-lines sort\" size=\"small\">\n mdi-reorder-horizontal\n </v-icon>\n </div>\n </div>\n\n <div id=\"firstContainer\" class=\"sortable-container\" data-tid=\"image-banner blocks\" style=\"transition-duration: 300ms; transform: translate3d(0px, 0px, 0px);\">\n <div v-for=\"(block, j) in sectionBlocksOrdered(section)\" :key=\"`section${i}-block${j}`\" class=\"drag-item\">\n <div class=\"Container-goTTRW cneSZt\">\n <div :class=\"sectionItemClassObject(block)\" class=\"Section-eCkBMz \">\n <div class=\"InnerContainer-dPNjJg gAUqSD\">\n <i class=\"I-gmFDEA Icon-chbHoy eaYeOY hMXRVX far fa-fw fa-fw\"></i>\n </div>\n <div class=\"InnerContainer-dPNjJg kwXbLo\" @mouseleave=\"containerHoverLeave(i, block, j)\" @mouseover=\"containerHover(i, block, j)\">\n <div class=\"LabelContainer-XFiUr kuxGbJ\">\n <label class=\"Label-eJXSuD cMyTnJ\" cursor=\"pointer\">\n {{ blockLabel(block) }}\n <div class=\"BlockSummary-bMgBTA eNDwgr\">\n {{ blockSummary(block) }}\n </div>\n </label>\n </div>\n <v-icon v-if=\"!block.disabled\" class=\"I-gmFDEA Icon-chbHoy eaYeOY hMXRVX far fa-eye fa-fw\" size=\"small\" @click=\"toggleDisableBlock(i, j, true)\">\n mdi-eye-outline\n </v-icon>\n <v-icon v-if=\"block.disabled\" class=\"I-gmFDEA Icon-chbHoy eaYeOY hMXRVX far fa-eye-slash fa-fw\" size=\"small\" @click=\"toggleDisableBlock(i, j, false)\">\n mdi-eye-off-outline\n </v-icon>\n <div class=\"Div-bMiTSW Spacer-dThvcf fbTExq\"></div>\n <v-icon class=\"I-gmFDEA Icon-chbHoy eaYeOY hMXRVX far fa-grip-lines sort\" size=\"small\">\n mdi-reorder-horizontal\n </v-icon>\n </div>\n </div>\n </div>\n </div>\n <span v-if=\"canAddBlock(i)\" aria-expanded=\"false\" class=\"Wrapper-iVPPu\">\n <div class=\"Trigger-huDzbV eBqQQq\">\n <div class=\"Container-goTTRW cneSZt\" data-tid=\"image-banner add block\">\n <div class=\"Section-eCkBMz iwkHtv\">\n <div class=\"InnerContainer-dPNjJg gAUqSD\">\n <i class=\"I-gmFDEA Icon-chbHoy eaYeOY hMXRVX far fa-fw fa-fw\"></i>\n </div>\n <div class=\"InnerContainer-dPNjJg hMXcFq\">\n <a class=\"A-fypPmk Link-cksnAZ cWXaAG\" color=\"primary\">\n <v-icon class=\"mb-1 I-gmFDEA Icon-chbHoy eaYeOY hGUdVH far fa-plus-circle fa-fw\" color=\"rgb(43, 128, 255)\" size=\"small\">mdi-plus-circle-outline</v-icon>\n <span class=\"Span-dxRpuh fqDCBT\">Add block </span>\n </a>\n </div>\n </div>\n </div>\n </div>\n </span>\n </div>\n\n </div>\n </div>\n </div>\n\n <div class=\"Div-bMiTSW Spacer-dThvcf jVlDvc\"></div>\n\n <span aria-expanded=\"false\" class=\"Wrapper-iVPPu eyAPpw\">\n <div class=\"Trigger-huDzbV eBqQQq\">\n <div class=\"PickerContainer-biFfmk hTPolk\">\n <span class=\"Span-dxRpuh ButtonContainer-kOntak fqDCBT hDDKkN\" color=\"white\">\n <v-btn block variant=\"outlined\">Add section</v-btn>\n </span>\n </div>\n </div>\n </span>\n </div>\n </div>\n </nav>\n</template>\n\n<script lang=\"ts\">\nimport {EventBus} from '@/plugins/eventBus';\nimport {mapActions, mapGetters} from 'vuex';\nimport {get} from 'lodash';\nimport dragula from 'dragula';\n\nexport default {\n name: 'LeftSideNav',\n\n data() {\n return {\n localTheme: null,\n };\n },\n\n created() {\n this.getStoreThemes().then(() => {\n this.localTheme = get(this.storeThemes, 0);\n this.initDragula();\n });\n },\n\n computed: {\n ...mapGetters({\n storeThemes: 'theme/storeThemes',\n }),\n themeName() {\n return get(this.storeThemes, '0.name', 'default');\n },\n themeSections() {\n return get(this.storeThemes, '0.theme_data.sections', {});\n },\n themeSectionsOrder() {\n return get(this.storeThemes, '0.theme_data.order', []);\n },\n orderedThemeSections() {\n const order = this.themeSectionsOrder;\n const sections = this.themeSections;\n const orderedSections = {};\n order.forEach((key) => {\n orderedSections[key] = sections[key];\n });\n return orderedSections;\n },\n },\n\n methods: {\n ...mapActions({\n getExportDetails: 'settings/getExportDetails',\n getStoreThemes: 'theme/getStoreThemes',\n updateStoreTheme: 'theme/updateStoreTheme',\n }),\n initDragula() {\n console.dir('initDragula');\n console.dir(document.getElementById('firstContainer'));\n const drake = dragula([document.getElementById('firstContainer')], {\n moves: (el, source, handle) => {\n console.dir('moves');\n console.dir(el);\n console.dir(handle);\n console.dir(el.classList);\n console.dir(handle.classList.contains('sort'));\n return handle.classList.contains('sort');\n },\n });\n\n drake.on('drag', (el) => {\n // add 'is-moving' class to element being dragged\n el.classList.add('is-moving');\n })\n // .on('shadow', (el, container, source) => {\n // if (el !== container.children[container.children.length - 1]) {\n // container.appendChild(el);\n // }\n // })\n .on('dragend', (el) => {\n // remove 'is-moving' class from element after dragging has stopped\n el.classList.remove('is-moving');\n\n // add the 'is-moved' class for 600ms then remove it\n window.setTimeout(() => {\n el.classList.add('is-moved');\n window.setTimeout(() => {\n el.classList.remove('is-moved');\n }, 600);\n }, 100);\n });\n },\n toggleDisableBlock(sectionId, blockId, disable) {\n console.dir('disableBlock');\n console.dir(sectionId);\n console.dir(blockId);\n const section = get(this.localTheme, `theme_data.sections.${sectionId}`, {});\n console.dir(section);\n\n if (section) {\n const blocks = get(section, 'blocks', []);\n blocks[blockId].disabled = disable;\n this.updateStoreTheme(this.localTheme);\n }\n },\n /**\n * @param section\n * @returns {boolean}\n */\n showChevronUp(section) {\n return section.indexOf('date-picker') !== 0\n && section.indexOf('products') !== 0\n && section.indexOf('spacer') !== 0;\n },\n sectionItemClassObject(block) {\n return {\n bJkMPt: block.disabled,\n iwkHtv: !block.disabled,\n };\n },\n canAddBlock(section) {\n return section.indexOf('date-picker') !== 0\n // && section.indexOf('products') !== 0\n && section.indexOf('spacer') !== 0;\n },\n containerHover(section, block = null, id = null) {\n EventBus.$emit('mouse-over-theme-component', {section, block, id});\n },\n containerHoverLeave(section, block = null, id = null) {\n EventBus.$emit('mouse-leave-theme-component', {section, block, id});\n },\n sectionBlocksOrdered(section) {\n const blockOrder = get(section, 'block_order', []);\n const blocks = get(section, 'blocks', {});\n const orderedBlocks = {};\n blockOrder.forEach((key) => {\n orderedBlocks[key] = blocks[key];\n });\n return orderedBlocks;\n },\n sectionLabel(section) {\n // if section begins with image-banner, return Image Banner\n if (section.indexOf('image-banner') === 0) {\n return 'Image Banner';\n }\n if (section.indexOf('date-picker') === 0) {\n return 'Date Picker';\n }\n if (section.indexOf('products') === 0) {\n return 'Products';\n }\n if (section.indexOf('spacer') === 0) {\n return 'Spacer';\n }\n if (section.indexOf('columns') === 0) {\n return 'Columns';\n }\n\n return section;\n },\n blockLabel(block) {\n if (block.type === 'heading') {\n return 'Heading';\n }\n if (block.type === 'text') {\n return 'Text';\n }\n if (block.type === 'button') {\n return 'Button';\n }\n if (block.type === 'column') {\n return 'Column';\n }\n },\n blockSummary(block) {\n if (block.type === 'heading') {\n return get(block, 'settings.text', 'na');\n }\n if (block.type === 'text') {\n return get(block, 'settings.text', 'na');\n }\n if (block.type === 'button') {\n return get(block, 'settings.text', 'na');\n }\n if (block.type === 'column') {\n return get(block, 'settings.title', 'na');\n }\n },\n },\n};\n</script>\n\n<style>\n.drag-item {\n transition: all 0.3s cubic-bezier(0.23, 1, 0.32, 1);\n}\n\n.drag-item.is-moving {\n transform: scale(1.1);\n}\n\n.gu-transit {\n opacity: 0.5;\n background: rgba(255, 255, 255, 0.5);\n border-radius: 6px;\n\n transform: translate3d(0px, 29px, 0px);\n z-index: 1000;\n}\n\n.gu-mirror {\n opacity: 0.5;\n -ms-filter: \"progid:DXImageTransform.Microsoft.Alpha(Opacity=50)\";\n filter: alpha(opacity=50);\n}\n\n.gu-hide {\n display: none !important;\n}\n\n.gu-unselectable {\n -webkit-user-select: none !important;\n -moz-user-select: none !important;\n -ms-user-select: none !important;\n user-select: none !important;\n}\n</style>\n\n<style>\n.fzkgnE *, .fzkgnE ::before, .fzkgnE ::after {\n box-sizing: border-box;\n}\n\n.hJbBaq {\n background: rgb(247, 248, 248);\n transition: width 250ms cubic-bezier(0.86, 0, 0.07, 1) 0s;\n display: block;\n border-color: rgb(226, 230, 235);\n overflow-x: hidden;\n position: sticky;\n height: calc(100vh - 62px);\n order: 1;\n z-index: 29;\n left: 0;\n width: 320px;\n border-right-width: 1px;\n border-right-style: solid;\n}\n\n.fa-fw {\n text-align: center;\n width: 1.25em;\n}\n\n.felMTq {\n padding: 18px;\n width: 100%;\n overflow-y: hidden;\n}\n\n.hJbBaq .Inner-eASQkV {\n height: calc(100vh - 62px);\n}\n\n.fNYben {\n padding: 0 !important;\n}\n\n.kWdRwd {\n display: flex;\n flex-flow: column nowrap;\n height: 100%;\n position: relative;\n}\n\n.fZbXLc {\n width: 90%;\n}\n\n.fmnNSR {\n padding: 12px;\n border-bottom: 1px solid rgb(221, 225, 227);\n cursor: pointer;\n}\n\n.fmnNSR .H3-bOhkOq {\n display: flex;\n -webkit-box-align: center;\n align-items: center;\n}\n\n.lgizXY {\n margin: 0;\n color: rgb(24, 24, 24);\n font-family: proxima-nova, sans-serif;\n font-size: 18px;\n font-weight: 600;\n}\n\n.iwkHtv {\n display: flex;\n -webkit-box-align: center;\n align-items: center;\n margin: 0 6px;\n border-radius: 6px;\n cursor: pointer;\n user-select: none;\n padding: 0;\n}\n\n.gAUqSD {\n display: flex;\n -webkit-box-align: center;\n align-items: center;\n border-radius: 6px;\n padding: 12px 6px;\n pointer-events: none;\n}\n\n.kQUSAR {\n flex: 1 1 0;\n padding-top: 6px;\n overflow-y: auto;\n}\n\n.hMXRVX {\n cursor: pointer;\n}\n\n.kwXbLo {\n display: flex;\n -webkit-box-align: center;\n align-items: center;\n border-radius: 6px;\n width: 100%;\n padding: 0 12px;\n}\n\n.kwXbLo:hover {\n background: rgb(226, 230, 235);\n}\n\n.kwXbLo .I-gmFDEA {\n color: rgb(33, 59, 71);\n visibility: hidden;\n}\n\n.iwkHtv .I-gmFDEA:not(:first-child) {\n color: rgb(33, 59, 71);\n visibility: hidden;\n}\n\n.kwXbLo:hover .I-gmFDEA {\n visibility: visible;\n}\n\n.bJkMPt .I-gmFDEA:not(:first-child) {\n color: rgb(33, 59, 71);\n visibility: hidden;\n}\n\n.kuxGbJ {\n display: flex;\n -webkit-box-align: center;\n align-items: center;\n flex: 1 1 0;\n padding: 12px 0;\n}\n\n.jaLOqC.jaLOqC.jaLOqC {\n display: inline-block;\n width: 0;\n margin-top: 0;\n margin-left: 6px;\n}\n\n.dfsrYj {\n margin: 0;\n color: rgb(118, 127, 130);\n font-size: 14px;\n font-weight: 400;\n line-height: 20px;\n}\n\n.fUNwul {\n display: block;\n color: rgb(24, 24, 24);\n font-size: 14px;\n font-weight: 600;\n line-height: 14px;\n cursor: pointer;\n margin: 0 !important;\n}\n\n.cfZQHO {\n border-color: rgb(221, 225, 227);\n margin-top: 6px;\n margin-bottom: 6px;\n margin-right: 18px !important;\n margin-left: 18px !important;\n}\n\n.fbTExq.fbTExq.fbTExq {\n display: inline-block;\n width: 0;\n margin-top: 0;\n margin-left: 12px;\n}\n\n.eNDwgr {\n display: inline-block;\n max-width: 130px;\n vertical-align: bottom;\n margin-left: 6px;\n color: rgb(118, 127, 130);\n font-weight: 400;\n overflow: hidden;\n white-space: nowrap;\n text-overflow: ellipsis;\n}\n\n.cMyTnJ {\n display: block;\n color: rgb(24, 24, 24);\n font-size: 14px;\n line-height: 14px;\n cursor: pointer;\n font-weight: 400 !important;\n margin: 0 !important;\n}\n\n.cWXaAG {\n cursor: pointer;\n align-self: center;\n font-size: 14px;\n color: rgb(43, 128, 255);\n}\n\n.bJkMPt {\n display: flex;\n -webkit-box-align: center;\n align-items: center;\n margin: 0 6px;\n border-radius: 6px;\n cursor: pointer;\n user-select: none;\n opacity: 0.55;\n padding: 0;\n}\n\n.bJkMPt .I-gmFDEA:not(:first-child) {\n color: rgb(33, 59, 71);\n visibility: hidden;\n}\n\n.bJkMPt .fa-eye-slash {\n visibility: visible !important;\n}\n\n.bJkMPt .fa-eye-slash {\n visibility: visible !important;\n}\n\n.gAUqSD {\n display: flex;\n -webkit-box-align: center;\n align-items: center;\n border-radius: 6px;\n padding: 12px 6px;\n pointer-events: none;\n}\n\n.jVlDvc.jVlDvc.jVlDvc {\n width: 100%;\n margin-top: 6px;\n display: block !important;\n}\n</style>\n\n<style>\n.eyAPpw {\n position: sticky;\n left: 0;\n right: 0;\n bottom: 6px;\n}\n\n.hTPolk {\n padding: 6px 18px;\n}\n\n.hDDKkN {\n display: block;\n width: 100%;\n}\n</style>\n","<template>\n <div class=\"Div-bMiTSW Content-jqUogp bymsnf\">\n <div class=\"Preview-jvKtmK bymkXl\" mode=\"desktop\">\n <iframe id=\"preview\" class=\"Frame-hJxVdP fiTgfO\" src=\"http://fleetwire.test/theme-test1/e7d76370-0635-11ee-9558-3f5153343edb\"></iframe>\n </div>\n </div>\n</template>\n\n<script lang=\"ts\">\nimport {EventBus} from '@/plugins/eventBus';\nimport {mapActions} from 'vuex';\nimport {get} from 'lodash';\n\nexport default {\n name: 'ThemeMainArea',\n\n created() {\n EventBus.$on('mouse-over-theme-component', data => {\n const selector = this.findBlockElement(data);\n\n this.toggleBorderAttribute(selector, 'add');\n });\n EventBus.$on('mouse-leave-theme-component', data => {\n const selector = this.findBlockElement(data);\n this.toggleBorderAttribute(selector, 'remove');\n });\n EventBus.$on('update-theme-settings-success', () => {\n console.dir('update-theme-settings-success');\n document.getElementById('preview').contentWindow.location.reload();\n });\n },\n\n methods: {\n ...mapActions({\n getExportDetails: 'settings/getExportDetails',\n }),\n toggleBorderAttribute(selector, action) {\n const iframe = document.getElementById('preview');\n const iframeDocument = iframe.contentDocument || iframe.contentWindow.document;\n\n const iframeContent = iframeDocument.documentElement;\n const element = iframeContent.querySelector(selector);\n\n\n if (element === null) {\n console.error('Element not found');\n return;\n }\n\n if (action === 'add') {\n element.setAttribute('data-focus', 'true');\n } else {\n element.removeAttribute('data-focus');\n }\n },\n findBlockElement(data) {\n const section = get(data, 'section');\n const id = get(data, 'id');\n\n let selector = '';\n if (section.indexOf('image-banner') === 0) {\n if (id === null) {\n return `.image-banner-${section}`;\n }\n return `.image-banner-${section} #${id}`;\n }\n if (section.indexOf('columns') === 0) {\n if (id === null) {\n return `.columns-${section}`;\n }\n return `.columns-${section} #${id}`;\n }\n if (section.indexOf('spacer') === 0) {\n selector = `#section-${section}.spacer`;\n }\n\n return selector;\n },\n },\n};\n</script>\n\n<style>\n.bymsnf {\n padding: 26px 26px 90px;\n flex: 1 1 0;\n order: 2;\n height: calc(100vh - 62px);\n z-index: 29;\n background: rgb(246, 248, 248);\n position: relative;\n}\n\n.bymsnf {\n overflow-y: scroll;\n}\n\n.bymkXl {\n height: 100%;\n background-color: rgb(255, 255, 255);\n box-shadow: rgba(0, 0, 15, 0.12) 0 4px 12px;\n}\n\n.fiTgfO {\n width: 100%;\n height: 100%;\n border: none;\n}\n</style>\n","<template>\n <div class=\"theme-layout\">\n <ThemeTopNav />\n <LeftSideNav />\n <ThemeMainArea />\n </div>\n</template>\n\n<script>\n\nimport ThemeTopNav from '@/components/themes/ThemeTopNav.vue';\nimport LeftSideNav from '@/components/themes/LeftSideNav.vue';\nimport ThemeMainArea from '@/components/themes/ThemeMainArea.vue';\n\nexport default {\n name: 'ThemesBase',\n components: {\n LeftSideNav,\n ThemeTopNav,\n ThemeMainArea,\n },\n\n middleware: [],\n\n layout: 'themes',\n\n computed: {\n cachedViews() {\n return this.$store.state.tagsView.cachedViews;\n },\n key() {\n return this.$route.fullPath;\n },\n },\n};\n</script>\n\n<style>\n.theme-layout {\n background: rgb(246, 248, 248);\n display: flex;\n flex-direction: row;\n -webkit-box-align: stretch;\n align-items: stretch;\n width: 100%;\n padding-top: 62px;\n box-sizing: border-box;\n}\n\n</style>\n","import type {RouteRecordRaw} from 'vue-router';\nimport ThemeBase from '@/views/themes/ThemeBase/ThemeBase.vue';\nimport {CommonRouteMeta} from \"@/types\";\n\n\nconst themeRoutes: RouteRecordRaw[] = [{\n path: '/themes',\n component: ThemeBase,\n meta: {\n title: 'themes',\n icon: 'mdi-wallpaper',\n noCache: false,\n hidden: true,\n } as CommonRouteMeta,\n children: [\n {\n path: '',\n components: {\n default: () => import('@/views/themes/ThemeCustomize.vue'),\n },\n name: 'themes.index',\n meta: {title: 'Trip Extras', icon: 'mdi-car-convertible', noCache: false, isBase: true},\n },\n ],\n}];\n\nexport default themeRoutes;\n","<template>\n <transition mode=\"out-in\" name=\"fade-transform\">\n <keep-alive :include=\"cachedViews\">\n <router-view :key=\"key\"/>\n </keep-alive>\n </transition>\n</template>\n\n<script lang=\"ts\">\n\nexport default {\n name: 'LayoutCompanyForCheckoutIFrame',\n\n middleware: ['company'],\n\n layout: 'companyIframe',\n\n computed: {\n cachedViews() {\n return this.$store.state.tagsView.cachedViews;\n },\n key() {\n return this.$route.fullPath;\n },\n },\n};\n</script>\n\n<style>\n.v-application ul,\n.v-application ol {\n padding-left: 0 !important;\n}\n\n.options-subtitle {\n line-height: 1.2;\n color: rgba(255, 255, 255, 0.7);\n font-size: 1rem;\n margin-top: 5px;\n}\n</style>\n","import type {RouteRecordRaw} from 'vue-router';\nimport {CommonRouteMeta} from '@/types';\nimport BaseCompanyIFrame from '@/views/company/checkoutIFrame.vue';\n\n\nconst Company = () => import('@/views/company/CompanyCatalog.vue');\nconst SingleTenantProduct2 = () => import('@/views/tenantStore2/SingleTenantProduct2.vue');\nconst TenantStoreBase2 = () => import('@/views/tenantStore2/TenantStoreBase.vue');\n\nexport const companyRoutes: RouteRecordRaw[] = [\n {\n path: '/rental',\n component: TenantStoreBase2,\n meta: {\n middleware: ['companyStore'],\n layout: 'CompanyStore',\n noCache: true,\n } as CommonRouteMeta,\n children: [\n {\n path: '',\n component: Company,\n name: 'company',\n meta: {title: 'agencyReservation', icon: 'domain', noCache: true, showFilter: true, calendarOn: true},\n },\n {\n path: 'reservations',\n components: {\n default: SingleTenantProduct2,\n navBarItem: () => import('@/components/dashboard/secondaryMenus/Settings.vue'),\n },\n name: 'companyReservation',\n meta: {title: 'companyReservation', icon: 'domain', noCache: true},\n },\n {\n path: 'reservations/finalize',\n component: () => import(/* webpackChunkName: \"checkout\" */ '@/views/company/Finalize.vue'),\n name: 'reservations.finalize',\n meta: {title: 'Finalize', icon: 'domain', noCache: true},\n },\n {\n path: 'reservations/complete',\n component: () => import('@/views/company/Complete.vue'),\n name: 'reservations.complete',\n meta: {title: 'Booked', icon: 'domain', noCache: true},\n },\n {\n path: 'reservations/:b_id/trip-photos',\n component: () => import('@/views/company/SingleReservationTripPhotos.vue'),\n name: 'reservations.trip_photos',\n meta: {title: 'Booked', icon: 'domain', noCache: true},\n },\n {\n path: 'reservations/:b_id/inspection',\n component: () => import(/* webpackChunkName: \"checkin\" */ '@/views/guest/DamageReport.vue'),\n name: 'reservations.inspection',\n meta: {title: 'Checkin', icon: 'domain', noCache: true},\n },\n {\n path: 'reservations/checkin',\n component: () => import(/* webpackChunkName: \"checkin\" */ '@/views/company/Checkin.vue'),\n name: 'reservations.checkin',\n meta: {title: 'Checkin', icon: 'domain', noCache: true},\n },\n ],\n },\n];\n\n\nexport const companyRoutes2: RouteRecordRaw[] = [\n {\n path: '/public',\n component: BaseCompanyIFrame,\n meta: {\n layout: 'CompanyIframeLayout',\n noCache: true,\n hidden: true,\n } as CommonRouteMeta,\n children: [\n {\n path: '/',\n component: () => import('@/views/company/CompanyCatalog.vue'),\n name: 'company.iframe',\n meta: {title: 'agencyReservation', icon: 'domain', noCache: true, showFilter: true, calendarOn: true},\n },\n {\n path: 'reservations',\n components: {\n default: SingleTenantProduct2,\n navBarItem: () => import(/* webpackChunkName: \"checkout\" */ '@/components/dashboard/secondaryMenus/Settings.vue'),\n },\n name: 'company.iframe.reservations',\n meta: {title: 'companyReservation', icon: 'domain', noCache: true},\n },\n {\n path: 'reservations/finalize',\n component: () => import(/* webpackChunkName: \"checkout\" */ '@/views/company/Finalize.vue'),\n name: 'reservations.iframe.finalize',\n meta: {title: 'Finalize', icon: 'domain', noCache: true},\n },\n {\n path: 'reservations/complete',\n component: () => import(/* webpackChunkName: \"checkout-complete\" */ '@/views/company/Complete.vue'),\n name: 'reservations.iframe.complete',\n meta: {title: 'Booked', icon: 'domain', noCache: true},\n },\n {\n path: 'reservations/:b_id/trip-photos',\n component: () => import(/* webpackChunkName: \"checkout-complete\" */ '@/views/company/SingleReservationTripPhotos.vue'),\n name: 'reservations.iframe.trip_photos',\n meta: {title: 'Booked', icon: 'domain', noCache: true},\n },\n {\n path: 'reservations/:b_id/inspection',\n component: () => import(/* webpackChunkName: \"checkin\" */ '@/views/guest/DamageReport.vue'),\n name: 'reservations.iframe.inspection',\n meta: {title: 'Checkin', icon: 'domain', noCache: true},\n },\n {\n path: 'reservations/checkin',\n component: () => import(/* webpackChunkName: \"checkin\" */ '@/views/company/Checkin.vue'),\n name: 'reservations.iframe.checkin',\n meta: {title: 'Checkin', icon: 'domain', noCache: true},\n },\n ]\n },\n];\n","import type {RouteRecordRaw} from 'vue-router';\nimport {CommonRouteMeta} from '@/types';\n\nconst EsignRecipient = () => import('@/views/eSigner/RecipientV2.vue');\nconst BaseESigner = () => import('@/components/eSigner/index.vue');\n\nexport const eSignerRoutes: RouteRecordRaw[] = [\n {\n path: '/signing',\n component: BaseESigner,\n meta: {\n layout: 'Esign',\n } as CommonRouteMeta,\n children: [\n {\n path: 'v2/:envelope_id/:recipient_id',\n component: EsignRecipient,\n name: 'esign.recipient.v2',\n meta: {title: 'eSign Recipient', icon: 'domain', noCache: true, showNavbar: true, layout: 'Esign',},\n },\n {\n path: 'v2/:envelope_id/:recipient_id/sample',\n component: () => import('@/views/eSigner/RecipientV2.vue'),\n name: 'esign.recipient.v2.sample',\n meta: {title: 'eSign Recipient', icon: 'domain', noCache: true, showNavbar: true},\n },\n ],\n },\n];\n\nexport const eSignerCompleteRoutes: RouteRecordRaw = {\n path: '/signing',\n component: BaseESigner,\n children: [\n {\n path: ':envelope_id/:recipient_id/complete',\n component: () => import('@/views/eSigner/RecipientComplete.vue'),\n name: 'esign.recipient.complete',\n meta: {title: 'eSign Recipient Complete', icon: 'domain', noCache: true},\n },\n ],\n meta: {hidden: true, noCache: false} as CommonRouteMeta\n};\n","import type {RouteRecordRaw} from 'vue-router';\nimport {CommonRouteMeta} from \"@/types\";\n\nconst BaseDashboard = () => import('@/views/dashboard/BaseDashboard.vue');\n\nconst superAdminRoutes: RouteRecordRaw = {\n path: '/super-admin',\n component: BaseDashboard,\n meta: {\n title: 'Super Admin',\n icon: 'mdi-login',\n noCache: false,\n superAdmin: true,\n hidden: true,\n middleware: ['auth'],\n layout: 'Dashboard',\n roles: ['super-admin']\n } as CommonRouteMeta,\n children: [\n {\n path: '',\n name: 'super.admin.general',\n component: () => import('@/views/dashboard/superAdmin/General.vue'),\n },\n {\n path: 'roles',\n component: () => import('@/views/dashboard/superAdmin/rolesPermissions/RolesBase.vue'),\n children: [\n {\n path: '',\n name: 'super.admin.roles',\n component: () => import('@/views/dashboard/superAdmin/rolesPermissions/Roles.vue'),\n },\n {\n path: 'new',\n name: 'super.admin.roles.new',\n component: () => import('@/views/dashboard/superAdmin/rolesPermissions/RolesNew.vue'),\n },\n {\n path: ':role_id',\n name: 'super.admin.roles.edit',\n component: () => import('@/views/dashboard/superAdmin/rolesPermissions/RolesEdit.vue'),\n },\n ],\n },\n {\n path: 'permissions',\n component: () => import('@/views/dashboard/superAdmin/rolesPermissions/PermissionsBase.vue'),\n children: [\n {\n path: '',\n name: 'super.admin.permissions',\n component: () => import('@/views/dashboard/superAdmin/rolesPermissions/Permissions.vue'),\n },\n {\n path: 'new',\n name: 'super.admin.permissions.new',\n component: () => import('@/views/dashboard/superAdmin/rolesPermissions/PermissionsNew.vue'),\n },\n {\n path: ':permission_id',\n name: 'super.admin.permissions.edit',\n component: () => import('@/views/dashboard/superAdmin/rolesPermissions/PermissionsEdit.vue'),\n },\n ],\n },\n {\n path: 'media',\n name: 'super.admin.media',\n component: () => import('@/views/dashboard/superAdmin/media/Media.vue'),\n },\n {\n path: 'media/upload',\n name: 'super.admin.media.upload',\n component: () => import('@/views/dashboard/superAdmin/media/SUUploadMedia.vue'),\n },\n {\n path: 'users',\n component: () => import('@/views/dashboard/superAdmin/users/UsersBase.vue'),\n children: [\n {\n path: '',\n name: 'super.admin.users',\n component: () => import('@/views/dashboard/superAdmin/users/Users.vue'),\n },\n {\n path: ':user_id',\n name: 'super.admin.users.edit',\n component: () => import('@/views/dashboard/superAdmin/users/UsersEdit.vue'),\n },\n ],\n },\n {\n path: 'masquerade',\n name: 'super.admin.users.masquerade',\n component: () => import('@/views/dashboard/superAdmin/users/UserMasquerade.vue'),\n },\n {\n path: 'companies',\n component: () => import('@/views/dashboard/superAdmin/companies/CompaniesBase.vue'),\n children: [\n {\n path: '',\n name: 'super.admin.companies',\n component: () => import('@/views/dashboard/superAdmin/companies/Companies.vue'),\n },\n {\n path: ':company_id',\n name: 'super.admin.company.edit',\n component: () => import('@/views/dashboard/superAdmin/companies/CompanyEdit.vue'),\n },\n ],\n },\n {\n path: 'stats',\n component: () => import('@/views/dashboard/superAdmin/stats/StatsBase.vue'),\n children: [\n {\n path: '',\n name: 'super.admin.stats',\n component: () => import('@/views/dashboard/superAdmin/stats/Stats.vue'),\n },\n {\n path: 'users',\n name: 'super.admin.stats.users',\n component: () => import('@/views/dashboard/superAdmin/stats/UserStats.vue'),\n },\n {\n path: 'subscribers',\n name: 'super.admin.stats.subscribers',\n component: () => import('@/views/dashboard/superAdmin/stats/SubscriberStats.vue'),\n },\n ],\n },\n {\n path: 'automations',\n component: () => import('@/views/dashboard/superAdmin/Automations/AutomationsBase.vue'),\n children: [\n {\n path: '',\n name: 'super.admin.automations',\n component: () => import('@/views/dashboard/superAdmin/Automations/Automations.vue'),\n },\n {\n path: 'trip/:trip_id',\n name: 'super.admin.automations.trip',\n component: () => import('@/views/dashboard/superAdmin/Automations/AutomationsTrip.vue'),\n },\n ],\n },\n {\n path: 'whats-new',\n component: () => import('@/views/dashboard/superAdmin/stats/StatsBase.vue'),\n children: [\n {\n path: '',\n name: 'super.admin.whats-new',\n component: () => import('@/views/dashboard/superAdmin/whats-new/WhatsNew.vue'),\n },\n ],\n },\n {\n path: 'server',\n component: () => import('@/views/dashboard/superAdmin/server/ServerBase.vue'),\n children: [\n {\n path: '',\n name: 'super.admin.server',\n component: () => import('@/views/dashboard/superAdmin/whats-new/WhatsNew.vue'),\n },\n ],\n },\n {\n path: 'utils',\n component: () => import('@/views/dashboard/superAdmin/companies/CompaniesBase.vue'),\n children: [\n {\n path: '',\n name: 'super.admin.utils',\n component: () => import('@/views/dashboard/superAdmin/utils/UtilsBase.vue'),\n },\n ],\n },\n {\n path: 'push-notifications',\n component: () => import('@/views/dashboard/superAdmin/companies/CompaniesBase.vue'),\n children: [\n {\n path: '',\n name: 'super.admin.push-notifications',\n component: () => import('@/views/dashboard/superAdmin/companies/PushNotifications.vue'),\n },\n ],\n },\n {\n path: 'features',\n component: () => import('@/views/dashboard/superAdmin/companies/CompaniesBase.vue'),\n children: [\n {\n path: '',\n name: 'super.admin.features',\n component: () => import('@/views/dashboard/superAdmin/companies/Features.vue'),\n },\n ],\n },\n {\n path: 'affiliate',\n component: () => import('@/views/dashboard/superAdmin/companies/CompaniesBase.vue'),\n children: [\n {\n path: '',\n name: 'super.admin.affiliate',\n component: () => import('@/views/dashboard/superAdmin/companies/Affiliate.vue'),\n },\n ],\n },\n {\n path: 'cache',\n component: () => import('@/views/dashboard/superAdmin/companies/CompaniesBase.vue'),\n children: [\n {\n path: '',\n name: 'super.admin.cache',\n component: () => import('@/views/dashboard/superAdmin/companies/Cache.vue'),\n },\n ],\n },\n {\n path: 'affiliate/:uuid',\n component: () => import('@/views/dashboard/superAdmin/companies/CompaniesBase.vue'),\n children: [\n {\n path: '',\n name: 'super.admin.affiliateSingle',\n component: () => import('@/views/dashboard/superAdmin/companies/AffiliateSingle.vue'),\n },\n ],\n },\n ],\n};\n\nexport default superAdminRoutes;\n","import type {RouteMeta, RouteRecordRaw} from 'vue-router';\nimport type {CommonRouteMeta} from '@/types';\n\nconst Quickstart = () => import('@/views/dashboard/Quickstart.vue');\nconst BaseDashboard = () => import('@/views/dashboard/BaseDashboard.vue');\nconst HomeDashboard = () => import('@/views/dashboard/Home.vue');\n\n\ninterface ExtendedRouteMeta extends RouteMeta, CommonRouteMeta {\n layout?: string;\n requiresAuth?: boolean;\n middleware?: string[];\n showInMenu?: boolean;\n}\n\nconst dashboardChildrenRoutes: Array<RouteRecordRaw> = [\n {\n path: '',\n component: HomeDashboard,\n name: 'dashboard',\n meta: {title: '', icon: 'mdi-view-dashboard', noCache: false} as ExtendedRouteMeta,\n },\n {\n path: 'quickstart',\n component: Quickstart,\n name: 'quickstart',\n meta: {title: 'quickstart', icon: 'mdi-account', noCache: false} as ExtendedRouteMeta,\n },\n {\n path: 'account',\n component: HomeDashboard,\n name: 'me',\n meta: {title: 'me', icon: 'mdi-account', noCache: false} as ExtendedRouteMeta,\n },\n {\n path: 'debug',\n component: Quickstart,\n name: 'debug.index',\n meta: {title: 'debug', icon: 'mdi-account', noCache: false} as ExtendedRouteMeta,\n },\n];\n\nconst dashboardRoutes: RouteRecordRaw = {\n path: '/dashboard',\n component: BaseDashboard,\n meta: {\n title: 'dashboard',\n icon: 'mdi-view-dashboard',\n noCache: false,\n layout: 'Dashboard',\n requiresAuth: true,\n middleware: ['auth',],\n showInMenu: true,\n } as CommonRouteMeta,\n children: dashboardChildrenRoutes,\n};\n\nexport default dashboardRoutes;\n","import type {RouteRecordRaw} from 'vue-router';\nimport {CommonRouteMeta} from '@/types';\n\nconst BaseAnalytics = () => import('@/views/dashboard/analytics/BaseAnalytics.vue');\nconst BaseDashboard = () => import('@/views/dashboard/BaseDashboard.vue');\nconst ConversionAnalytics = () => import('@/views/dashboard/analytics/Conversion/ConversionAnalytics.vue');\nconst VehicleAnalytics = () => import('@/views/dashboard/analytics/Vehicle/VehicleAnalytics.vue');\n\nconst analyticsRoutes: RouteRecordRaw = {\n path: '/analytics',\n component: BaseDashboard,\n meta: {\n title: 'analytics',\n icon: 'mdi-poll',\n noCache: false,\n isBase: true,\n permissions: ['listings_view'],\n hidden: true,\n } as CommonRouteMeta,\n children: [\n {\n path: '',\n component: BaseAnalytics,\n name: 'analytics.index',\n meta: {title: 'Analytics', icon: 'mdi-poll', noCache: false, isBase: true},\n },\n {\n path: 'conversion',\n component: ConversionAnalytics,\n name: 'analytics.conversion',\n meta: {title: 'Conversion Analytics', icon: 'mdi-poll', noCache: false, isBase: true},\n },\n {\n path: 'vehicle',\n component: VehicleAnalytics,\n name: 'analytics.vehicle',\n meta: {title: 'Vehicle Analytics', icon: 'mdi-poll', noCache: false, isBase: true},\n },\n ],\n};\n\nexport default analyticsRoutes;\n","<template>\n <section class=\"\">\n\n <slot>\n <router-view />\n </slot>\n\n </section>\n</template>\n\n<script>\n\nexport default {\n name: 'LayoutCompany',\n\n middleware: ['company'],\n\n layout: 'company',\n\n computed: {\n cachedViews() {\n return this.$store.state.tagsView.cachedViews;\n },\n key() {\n return this.$route.fullPath;\n },\n },\n};\n</script>\n\n<style lang=\"scss\">\n .v-application ul,\n .v-application ol {\n padding-left: 0 !important;\n }\n\n .options-subtitle {\n line-height: 1.2;\n color: rgba(255, 255, 255, 0.7);\n font-size: 1rem;\n margin-top: 5px;\n }\n</style>\n","import type {RouteRecordRaw} from 'vue-router';\nimport BaseCompany from '@/components/company/index.vue';\nimport {CommonRouteMeta} from \"@/types\";\n\nconst loadPay = () => import('@/views/pay/index.vue');\n\nconst payRoutes: RouteRecordRaw[] = [\n {\n path: '/pay',\n component: BaseCompany,\n meta: {\n hidden: true,\n noCache: false,\n requiresAuth: false,\n middleware: ['companyStore'],\n layout: 'Default',\n } as CommonRouteMeta,\n children: [\n {\n path: ':p_id',\n component: loadPay,\n name: 'pay',\n meta: {title: 'single payment', icon: 'mdi-account-outline', noCache: false},\n },\n ],\n }\n];\n\nexport default payRoutes;\n","import type {RouteRecordRaw} from 'vue-router';\n\n// Route Modules\nimport authRoutes from '@/router/modules/auth';\nimport settingsRoutes from '@/router/modules/settings';\nimport commissionRoutes from './modules/commission';\nimport custodian from './modules/custodian';\nimport documentRoutes from './modules/documents';\nimport perksRoutes from '@/router/modules/perks';\nimport notificationRoutes from '@/router/modules/notifications';\nimport listingRoutes from './modules/listing';\nimport connectionsRoutes from './modules/connections';\nimport ordersRoutes from '@/router/modules/orders';\nimport customerRoutes from '@/router/modules/customers';\nimport tripExtrasRoutes from '@/router/modules/trip-extras';\nimport themeRoutes from '@/router/modules/theme';\nimport {companyRoutes, companyRoutes2} from './modules/company';\nimport {eSignerCompleteRoutes, eSignerRoutes} from './modules/e-signer';\nimport superAdminRoutes from './modules/super-admin';\nimport dashboardRoutes from './modules/dashboard';\nimport analyticsRoutes from './modules/analytics';\nimport payRoutes from './modules/pay';\n\n// Lazy-loaded components for redirects\nconst StripeRedirect = () => import('@/views/auth/StripeRedirect.vue');\nconst BraintreeRedirect = () => import('@/views/auth/BraintreeRedirect.vue');\nconst SquareRedirect = () => import('@/views/auth/SquareRedirect.vue');\n\n// Grouped Constant Routes\nconst redirectRoutes: Array<RouteRecordRaw> = [\n {\n path: '/stripe/redirect',\n name: 'stripe.redirect',\n component: StripeRedirect,\n meta: {hidden: true, middleware: ['auth'], layout: 'Dashboard'},\n },\n {\n path: '/braintree/redirect',\n name: 'braintree.redirect',\n component: BraintreeRedirect,\n meta: {hidden: true, middleware: ['auth'], layout: 'Dashboard'},\n },\n {\n path: '/square/redirect',\n name: 'square.redirect',\n component: SquareRedirect,\n meta: {hidden: true, middleware: ['auth'], layout: 'Dashboard'},\n },\n];\n\nconst moduleRoutes: Array<RouteRecordRaw> = [\n // {\n // path: '/',\n // name: 'home',\n // components: Home,\n // meta: { title: 'home', icon: 'mdi-home', noCache: false },\n // children: [],\n // },\n // {\n // path: '/theme-test1',\n // name: 'theme.test1',\n // component: ThemeTest,\n // meta: { hidden: true }\n // },\n // {\n // path: '/theme-test1/:uuid',\n // name: 'theme.test1.single',\n // component: ThemeTest,\n // meta: { hidden: true }\n // },\n dashboardRoutes,\n authRoutes,\n custodian,\n ...companyRoutes,\n ...companyRoutes2,\n ...listingRoutes,\n ...tripExtrasRoutes,\n ...ordersRoutes,\n ...customerRoutes,\n ...connectionsRoutes,\n ...settingsRoutes,\n ...perksRoutes,\n ...notificationRoutes,\n ...themeRoutes,\n ...commissionRoutes,\n ...payRoutes,\n ...documentRoutes,\n ...eSignerRoutes,\n superAdminRoutes,\n eSignerCompleteRoutes,\n analyticsRoutes,\n];\n\n// Consolidated Routes\nconst constantRoutes: Array<RouteRecordRaw> = [\n ...redirectRoutes,\n ...moduleRoutes,\n];\n\nconst asyncRoutes: Array<RouteRecordRaw> = [];\n\nexport {constantRoutes, asyncRoutes}","export default async function companyStore({store}) {\n console.log('%c -- MIDDLEWARE -- COMPANY STORE ✅', 'color: white; background: green; padding: 2px; font-weight: bold;');\n\n try {\n // Extract company from URL parameters, fwData, or fallback to window location\n const urlParams = new URLSearchParams(window.location.search);\n const urlCompany = urlParams.get('company');\n\n let company = urlCompany || window.fwData?.company || window.location.host;\n\n // if company has .fleetwire.io in it, remove it\n if (company.includes('.fleetwire.io')) {\n company = company.replace('.fleetwire.io', '');\n }\n\n console.log('%c 🏢 Detected Company:', 'color: cyan; background: black; font-weight: bold;', company);\n\n if (!company) {\n console.warn('%c ⚠️ No company identifier found!', 'color: orange; font-weight: bold;');\n return;\n }\n\n // Fetch company details from Vuex store\n await store.dispatch('company/fetchCompany', company);\n } catch (error) {\n console.error('%c ❌ Company Store Middleware Error:', 'color: red; font-weight: bold;', error);\n }\n}","import {createI18n} from 'vue-i18n'\nimport enUS from '@/lang/en-US.json';\nimport es from '@/lang/es.json';\nimport zncn from '@/lang/zh-CN.json';\nimport {ref} from 'vue';\n\n/**\n * Supported locale types in the application\n */\nexport type SupportedLocale = 'en-US' | 'es' | 'zh-CN';\n\n/**\n * List of supported locales\n */\nexport const SUPPORT_LOCALES: SupportedLocale[] = ['en-US', 'es', 'zh-CN'];\n\n/**\n * Default locale for the application\n */\nconst DEFAULT_LOCALE: SupportedLocale = 'en-US';\n\n/**\n * Initial locale state\n */\nconst locale = ref<SupportedLocale>(DEFAULT_LOCALE);\n\n/**\n * Creates and configures the i18n instance\n */\nconst i18n = createI18n({\n legacy: false,\n locale: locale.value,\n fallbackLocale: DEFAULT_LOCALE,\n messages: {\n 'en-US': enUS,\n 'es': es,\n 'zh-CN': zncn,\n },\n silentTranslationWarn: true,\n globalInjection: true,\n modifiers: {\n snakeCase: (str: string) => str.split(' ').join('_')\n }\n});\n\n/**\n * Loads messages for a specific locale if they haven't been loaded yet\n * @param locale - The locale to load messages for\n */\nexport async function loadMessages(locale: SupportedLocale): Promise<void> {\n try {\n const messages = i18n.global.getLocaleMessage(locale);\n if (Object.keys(messages).length === 0) {\n const importedMessages = await import(/* @vite-ignore */`@/lang/${locale}.json`);\n i18n.global.setLocaleMessage(locale, importedMessages.default);\n }\n\n if (i18n.global.locale.value !== locale) {\n i18n.global.locale.value = locale;\n }\n } catch (error) {\n console.error(`Failed to load messages for locale ${locale}:`, error);\n throw error;\n }\n}\n\n// Initialize with default locale\nloadMessages(DEFAULT_LOCALE).catch(error => {\n console.error('Failed to initialize i18n with default locale:', error);\n});\n\nexport default i18n;\n","import i18n, {SUPPORT_LOCALES} from './i18n'\nimport {nextTick} from 'vue'\n\n/**\n * Supported locale types in the application\n */\ntype SupportedLocale = 'en-US' | 'es' | 'zh-CN';\n\n/**\n * Interface for user locale information\n */\ninterface UserLocale {\n locale: SupportedLocale;\n localeNoRegion: SupportedLocale;\n}\n\n/**\n * Translation service for handling internationalization\n */\nconst Trans = {\n /**\n * Switches the application language to the specified locale\n * @param newLocale - The locale to switch to\n */\n async switchLanguage(newLocale: SupportedLocale): Promise<void> {\n try {\n await Trans.loadLocaleMessages(newLocale);\n Trans.currentLocale = newLocale;\n document.documentElement.setAttribute('lang', newLocale);\n localStorage.setItem('user-locale', newLocale);\n } catch (error) {\n console.error('Failed to switch language:', error);\n throw error;\n }\n },\n\n /**\n * Loads locale messages if they haven't been loaded yet\n * @param locale - The locale to load messages for\n */\n async loadLocaleMessages(locale: SupportedLocale): Promise<void> {\n if (!i18n.global.availableLocales.includes(locale)) {\n try {\n const messages = await import(/* @vite-ignore */ `@/lang/${locale}.json`);\n i18n.global.setLocaleMessage(locale, messages.default);\n } catch (error) {\n console.error(`Failed to load messages for locale ${locale}:`, error);\n throw error;\n }\n }\n await nextTick();\n },\n\n /**\n * Sets the current locale in i18n\n */\n set currentLocale(newLocale: SupportedLocale) {\n i18n.global.locale.value = newLocale;\n },\n\n /**\n * Gets the list of supported locales\n */\n get supportedLocales(): SupportedLocale[] {\n return SUPPORT_LOCALES as SupportedLocale[];\n },\n\n /**\n * Gets the default locale\n */\n get defaultLocale(): SupportedLocale {\n return 'en-US';\n },\n\n /**\n * Checks if a locale is supported\n * @param locale - The locale to check\n */\n isLocaleSupported(locale: string): boolean {\n return Trans.supportedLocales.includes(locale as SupportedLocale);\n },\n\n /**\n * Gets the user's preferred locale from browser settings\n */\n getUserLocale(): UserLocale {\n const locale = (window.navigator.language ||\n (window.navigator as any).userLanguage ||\n Trans.defaultLocale) as SupportedLocale;\n\n return {\n locale,\n localeNoRegion: locale.split('-')[0] as SupportedLocale\n };\n },\n\n /**\n * Gets the persisted locale from localStorage\n */\n getPersistedLocale(): SupportedLocale | null {\n const persistedLocale = localStorage.getItem('user-locale') as SupportedLocale | null;\n return Trans.isLocaleSupported(persistedLocale) ? persistedLocale : null;\n },\n\n /**\n * Determines the default locale based on user preferences and persisted settings\n */\n guessDefaultLocale(): SupportedLocale {\n const userPersistedLocale = Trans.getPersistedLocale();\n if (userPersistedLocale) {\n return userPersistedLocale;\n }\n\n const userPreferredLocale = Trans.getUserLocale();\n if (Trans.isLocaleSupported(userPreferredLocale.locale)) {\n return userPreferredLocale.locale;\n }\n\n if (Trans.isLocaleSupported(userPreferredLocale.localeNoRegion)) {\n return userPreferredLocale.localeNoRegion;\n }\n\n return Trans.defaultLocale;\n },\n}\n\nexport default Trans;","import Tr from \"@/plugins/i18n/translations\";\n\nexport default async () => {\n console.log('%c -- MIDDLEWARE -- LOCALE ✅', 'color: white; background: green; padding: 2px; font-weight: bold;');\n\n try {\n const guessedLocale = Tr.guessDefaultLocale() || Tr.defaultLocale;\n console.log('%c 🌍 Switching Locale:', 'color: cyan; font-weight: bold;', guessedLocale);\n\n await Tr.switchLanguage(guessedLocale);\n } catch (error) {\n console.error('%c ❌ Locale Middleware Error:', 'color: red; font-weight: bold;', error);\n }\n}\n","import {Store} from 'vuex';\nimport {RootState} from '@/types/RootState';\n\n\nconst debug: boolean = true;\n\nexport default async ({store}: { store: Store<RootState> }): Promise<boolean> => {\n console.log('%c -- MIDDLEWARE -- CHECK AUTH ✅', 'color: white;background: green; padding: 2px; font-weight: bold;');\n\n\n const userLoaded = store.getters['auth/userLoaded'];\n const token = store.getters['auth/token'];\n const user = store.getters['auth/user'];\n\n console.dir('userLoaded');\n console.dir(userLoaded);\n\n if (debug) {\n console.log('%c \\\\/ ', 'color: white;background: red; padding: 2px');\n console.dir(store);\n console.dir(`userLoaded: ${userLoaded}`);\n console.dir(`token: ${token}`);\n console.dir(user);\n console.dir(user.email);\n\n console.table({\n userLoaded,\n token: token ?? 'No Token',\n user: user ? user.email ?? 'User Object Exists' : 'No User',\n });\n console.log('%c /\\\\ ', 'color: white;background: red; padding: 2px');\n }\n\n\n if (!userLoaded) {\n try {\n console.log('%c Fetching user data...', 'color: yellow; font-weight: bold;');\n await store.dispatch('auth/fetchUser');\n console.log('%c ✅ User data fetched successfully!', 'color: lime; font-weight: bold;');\n } catch (error) {\n console.error('%c ❌ Error fetching user:', 'color: red; font-weight: bold;', error);\n }\n }\n\n return true;\n}","import {Store} from 'vuex';\nimport {RootState} from '@/types/RootState';\n\nexport default async function auth({store}: { store: Store<RootState> }) {\n console.log('%c -- MIDDLEWARE -- AUTH ✅', 'color: white;background: green; padding: 2px; font-weight: bold;');\n\n try {\n // Check if user is authenticated\n if (!isLoggedIn(store)) {\n console.warn('%c 🚪 User is NOT logged in - Redirecting...', 'color: orange; font-weight: bold;');\n return false;\n }\n\n console.log('%c 🔓 User is logged in - Loading dynamic routes...', 'color: lime; font-weight: bold;');\n\n await addDynamicRoutes(store);\n\n return true;\n } catch (error) {\n console.error('%c ❌ Auth Middleware Error:', 'color: red; font-weight: bold;', error);\n return false;\n }\n}\n\n/**\n * Check if the user is logged in\n */\nfunction isLoggedIn(store: Store<RootState>): boolean {\n const token = store.getters['auth/token'];\n console.log('%c 🔑 Auth Token:', 'color: cyan; font-weight: bold;', token);\n return !!token;\n}\n\n/**\n * Add dynamic routes\n */\nasync function addDynamicRoutes(store: Store<RootState>) {\n try {\n const roles = store.getters['auth/roles'];\n const permissions = store.getters['auth/permissions'];\n\n console.log('%c 🚀 Generating dynamic routes...', 'color: lightblue; font-weight: bold;');\n console.table({roles});\n console.table({permissions});\n\n await store.dispatch('permission/generateRoutes', {roles, permissions});\n\n console.log('%c ✅ Dynamic routes added successfully!', 'color: lime; font-weight: bold;');\n } catch (error) {\n console.error('%c ❌ Error adding dynamic routes:', 'color: red; font-weight: bold;', error);\n }\n}","import {createRouter, createWebHistory, RouteLocationNormalized} from 'vue-router'\n\nimport {Store} from 'vuex';\nimport {store} from '@/store';\nimport {constantRoutes} from '@/router/routes';\nimport {RootState} from '@/types/RootState';\nimport companyStore from '@/middleware/companyStore';\nimport locale from '@/middleware/locale';\nimport checkAuth from '@/middleware/check-auth';\nimport auth from '@/middleware/auth';\nimport guest from '@/middleware/guest';\n\nconst globalMiddleware: Array<string | Function> = [];\n\nconst router = createRouter({\n history: createWebHistory(),\n routes: constantRoutes,\n})\n\n\nrouter.beforeEach(async (to: RouteLocationNormalized, from: RouteLocationNormalized) => {\n console.log('%c START BEFORE EACH IN ROUTER \\\\/ ', 'color: black;background: yellow; padding: 2px;border-top: 1px solid red;');\n console.dir(to);\n\n if (store.state.app.update_available) {\n window.location.reload();\n }\n\n const context: { store: Store<RootState>; to: RouteLocationNormalized; from: RouteLocationNormalized } = {\n to,\n from,\n store\n };\n\n\n // ✅ Ensure checkAuth runs first\n await checkAuth(context).then(() => {\n console.log('%c checkAuth Completed ✅', 'color: green;');\n });\n\n // ✅ Extract middleware for the route\n const middleware = getMiddleware(to.matched);\n\n\n if (!middleware.length) {\n console.log('%c NO MIDDLEWARE ❌', 'color: red;');\n return; // No middleware, continue navigation\n }\n\n\n const middlewareNames = middleware.map((middleware) => {\n return typeof middleware === 'function' ? middleware.name : middleware\n });\n\n console.log('%c Middleware Found ✅', 'color: white;background: pink; padding: 2px; font-weight: bold; padding: 5px;');\n console.table(middlewareNames);\n\n // ✅ Ensure locale middleware always runs first\n await locale();\n\n // COMPANY STORE MIDDLEWARE\n if (middlewareNames.includes('companyStore')) {\n\n await companyStore(context);\n\n }\n\n\n // GUEST MIDDLEWARE\n if (middlewareNames.includes('guest')) {\n\n if (!(await guest(context))) {\n console.log('%c REDIRECT TO DASH', 'color: white;background: pink; padding: 2px; font-weight: bold; padding: 5px;');\n return {name: 'dashboard'}\n }\n }\n\n // AUTH MIDDLEWARE\n if (middlewareNames.includes('auth')) {\n console.dir('middlewareNames.includes(\\'auth\\')');\n\n const isAuth = await auth(context);\n\n if (\n !isAuth &&\n // ❗️ Avoid an infinite redirect\n to.name !== 'login'\n ) {\n // redirect the user to the login page\n return {name: 'login', query: {redirect: to.fullPath}}\n }\n }\n\n console.log('%c END BEFORE EACH IN ROUTER /\\\\ ', 'color: black;background: yellow; padding: 2px;border-bottom: 1px solid red');\n});\n\n\nexport default router;\n\n\n/**\n * Merge the global middleware with the component's middleware.\n */\nfunction getMiddleware(matchedRoutes: RouteLocationNormalized['matched']): Array<string | Function> {\n const middleware: Array<string | Function> = [...globalMiddleware];\n\n matchedRoutes.forEach((route) => {\n if (route.meta?.middleware) {\n if (Array.isArray(route.meta.middleware)) {\n middleware.push(...route.meta.middleware as Array<string | Function>);\n } else {\n middleware.push(route.meta.middleware as string | Function);\n }\n }\n });\n\n // remove duplicates\n return [...new Set(middleware)];\n}","import axios from 'axios';\nimport {EventBus} from '@/plugins/eventBus';\nimport {\n checkMasquerade,\n getRegisterId,\n getToken,\n removeAllUserCookies,\n removeToken,\n setRegisterToken,\n setToken\n} from '@/utils/auth';\nimport {Form} from '@/plugins/FWForms/index';\nimport {CartService} from '@/services/cart.service';\nimport * as types from '../mutation-types';\nimport * as Sentry from '@sentry/vue';\nimport router from '@/router';\nimport {Module} from 'vuex'\nimport {ApiToken, CompanyInterface, StoreLoaders} from '@/types';\nimport {RootState} from '@/types/RootState';\nimport {performApiRequest} from '@/store/helpers/vuex-helpers';\n\n\ninterface User {\n crisp_email_signature?: string\n email?: string\n email_verified_at?: string | null\n first_name?: string\n last_name?: string\n loaded: boolean\n name?: string\n on_trial?: boolean\n phone?: string\n photo_url?: string\n uuid?: string\n roles: Array<string>\n permissions: Array<string>\n identities: object | undefined\n}\n\nexport interface AuthState {\n loading: StoreLoaders\n authForm: Form<object>\n user: User\n token: string | null\n registerId: string | null\n roles: Array<string>\n permissions: Array<string>\n notifications: object\n apiTokens: ApiToken[]\n}\n\nconst state: AuthState = {\n loading: {\n updatePassword: false,\n stripe_oauth: false,\n getApiToken: false,\n createApiToken: false,\n start2FAVerify: false,\n check2FAVerify: false,\n },\n authForm: new Form(),\n user: {\n loaded: false,\n roles: [],\n permissions: [],\n identities: {\n tesla: [],\n turo: {},\n },\n photo_url: '',\n },\n token: getToken() as string,\n registerId: getRegisterId(),\n notifications: {},\n\n roles: [],\n permissions: [],\n apiTokens: [],\n}\n\nfunction handleCompanyConnections(commit, company: CompanyInterface) {\n const connections = ['getaround', 'turo', 'tesla', 'bouncie', 'outdoorsy', 'hqRentals'];\n connections.forEach(connection => {\n const payload = company?.connections?.[connection] ?? [];\n\n commit(`${connection}/SET_${connection.toUpperCase()}_CONNECTIONS`, payload, {root: true});\n });\n}\n\nconst authModule: Module<AuthState, RootState> = {\n namespaced: true,\n\n state,\n\n getters: {\n user: (state: AuthState) => state.user,\n token: (state: AuthState) => state.token,\n registerId: (state: AuthState) => state.registerId,\n check: (state: AuthState) => state.user.loaded !== false,\n userLoaded: (state: AuthState) => state.user.loaded,\n roles: (state: AuthState) => state.roles,\n permissions: (state: AuthState) => state.permissions,\n notifications: (state: AuthState) => state.notifications,\n loading: (state: AuthState) => state.loading,\n apiTokens: (state: AuthState) => state.apiTokens,\n authForm: (state: AuthState) => state.authForm,\n },\n\n actions: {\n saveToken({commit}, payload) {\n commit(types.SAVE_TOKEN, payload);\n },\n saveRegisterId({commit}, id: string) {\n commit(types.SAVE_REGISTER_ID, id);\n },\n\n async updateUserPassword({commit}, data: { password: string, newPassword: string }) {\n await performApiRequest(commit, 'SET_AUTH_LOADING', 'updatePassword', () => axios.post('/v1/password/change', data));\n },\n\n /**\n * Start a 2fa flow\n */\n async start2FAVerify({commit}, data: { channel: string, phone: string }) {\n try {\n return await performApiRequest(commit, 'SET_AUTH_LOADING', 'start2FAVerify', () => axios.post('/v1/2fa/start', data));\n } catch (error) {\n EventBus.$emit('SystemMessage', {\n type: 'error',\n message: error?.response?.data?.message || 'There was an error',\n });\n throw error;\n }\n },\n\n /**\n * Verify a 2fa code\n */\n async check2FAVerify({commit, state}, data) {\n commit('SET_AUTH_LOADING', {subject: 'check2FAVerify', loading: true});\n\n try {\n state.authForm.errors.clear();\n await performApiRequest(commit, 'SET_AUTH_LOADING', 'check2FAVerify', () => axios.post('/v1/2fa/check', data));\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: `2FA now ${data.disable ? 'disabled' : 'enabled'}`,\n });\n } catch (error) {\n state.authForm.errors.set(error?.response?.data?.errors || []);\n EventBus.$emit('SystemMessage', {\n type: 'error',\n message: error?.response?.data?.message || 'There was an error',\n });\n }\n },\n\n async fetchSession({commit, dispatch}) {\n commit('subscriptions/SET_SUBSCRIPTION_LOADING', {subject: 'subscription', loading: true}, {root: true});\n commit('listing/SET_LISTING_LOADING', {subject: 'listings', loading: true}, {root: true});\n commit('company/SET_COMPANY_LOADING', {subject: 'company', loading: true}, {root: true});\n\n try {\n const response = await axios.get('/v1/session');\n\n const {\n subscription,\n subscriptionMaster,\n extraListingsAddon,\n allPermissions,\n enforceSubscription,\n fwPublicStripeKey,\n build,\n meta,\n currency,\n settings,\n counts,\n features\n } = response.data;\n\n const company: CompanyInterface = response.data.company;\n\n commit('subscriptions/SET_SUBSCRIPTION', subscription, {root: true});\n commit('subscriptions/SET_SUBSCRIPTION_MASTER', subscriptionMaster, {root: true});\n commit('subscriptions/SET_ENFORCE_SUBSCRIPTION', enforceSubscription, {root: true});\n commit('subscriptions/SET_EXTRA_LISTINGS_ADDON', extraListingsAddon, {root: true});\n commit('providers/SET_PAYMENT_PROVIDERS', company.payment_profile, {root: true});\n commit('company/SET_COMPANY', company, {root: true});\n commit('company/SET_COMPANY_DEFAULT_META', meta, {root: true});\n commit('company/SET_COMPANY_CURRENCY', currency, {root: true});\n commit('company/SET_COMPANY_SETTINGS', settings, {root: true});\n commit('company/SET_COUNTS', counts, {root: true});\n\n if (Array.isArray(company?.listings)) {\n commit('listing/SET_ALL_LISTINGS', company.listings, {root: true});\n }\n\n commit('app/SET_ALL_POSSIBLE_PERMISSIONS', allPermissions, {root: true});\n commit('app/SET_FW_STRIPE_KEY', fwPublicStripeKey, {root: true});\n commit('app/SET_FW_BUILD_NUMBER', build, {root: true});\n commit('app/SET_APP_FEATURES', features, {root: true});\n\n if (company.notification_settings === null) {\n dispatch('settings/resetNotificationSettings', null, {root: true});\n } else {\n commit('settings/SET_NOTIFICATION_SETTINGS', company.notification_settings, {root: true});\n }\n\n handleCompanyConnections(commit, company);\n } catch (error) {\n console.error('Error fetching session data:', error);\n } finally {\n commit('subscriptions/SET_SUBSCRIPTION_LOADING', {\n subject: 'subscription',\n loading: false\n }, {root: true});\n commit('listing/SET_LISTING_LOADING', {subject: 'listings', loading: false}, {root: true});\n commit('company/SET_COMPANY_LOADING', {subject: 'company', loading: false}, {root: true});\n commit('app/SET_APP_BOOTING', false, {root: true});\n }\n },\n\n async fetchApiTokens({commit}) {\n try {\n const responseData = await performApiRequest(commit, 'SET_AUTH_LOADING', 'getApiToken', () => axios.get('/v1/user/api-tokens'));\n commit('SET_USER_API_TOKENS', responseData.tokens);\n } catch (error) {\n }\n },\n\n async createUserTokens({commit}) {\n try {\n const responseData = await performApiRequest(commit, 'SET_AUTH_LOADING', 'createApiToken', () => axios.post('/v1/user/api-tokens'));\n commit('SET_USER_API_TOKENS', responseData.tokens);\n return responseData.token\n } catch (error) {\n }\n },\n\n async deleteApiToken({commit}, token: ApiToken) {\n try {\n const responseData = await performApiRequest(commit, 'SET_AUTH_LOADING', 'deleteApiToken', () => axios.delete(`/v1/user/api-tokens/${token.id}`));\n commit('SET_USER_API_TOKENS', responseData.tokens);\n } catch (error) {\n }\n },\n\n\n async checkStripe({commit, rootGetters}) {\n const responseData = await performApiRequest(commit, 'SET_AUTH_LOADING', 'check_stripe', () => axios.get(`/v1/company/${rootGetters['company/company'].uuid}/stripe`));\n if (responseData?.results) {\n EventBus.$emit('stripe-oauth-success');\n commit('company/SET_COMPANY', responseData.company, {root: true});\n commit(types.SET_AUTH_LOADING, {subject: 'stripe_oauth', loading: false});\n\n return responseData.results;\n }\n },\n\n\n async saveStripeUserId({state, commit}, code: string) {\n try {\n await performApiRequest(commit, 'SET_AUTH_LOADING', 'stripe_oauth', () => axios.post(`/v1/stripe/user-id/${code}`));\n EventBus.$emit('stripe-oauth-success');\n } catch (error) {\n throw error;\n }\n },\n\n async fetchUser({commit}) {\n const masquerade = checkMasquerade();\n\n if (masquerade) {\n commit('app/SET_MASQUERADE_STATUS', masquerade, {root: true});\n setToken(masquerade.user.token);\n }\n\n try {\n const {data} = await axios.post('/v1/auth/user');\n\n const {roles, permissions, email, phone, name} = data;\n\n\n if (email) {\n Sentry.setUser({email, phone, name});\n\n // const { config } = getOptions();\n //\n // query(\"config\", config.id, {\n // 'user_id': data.uuid,\n // });\n }\n\n commit('SET_USER', data);\n commit('SET_ROLES', roles);\n commit('SET_PERMISSIONS', permissions);\n } catch (e) {\n console.error('fetchUser error', e);\n commit(types.FETCH_USER_FAILURE);\n }\n },\n\n resendConfirmEmail({state}) {\n axios.post(`/v1/users/${state.user.uuid}/confirm-email/resend`)\n .then(() => {\n EventBus.$emit('verify-email-resent');\n }).catch(() => {\n }).finally(() => {\n });\n },\n\n updateUser({commit}, payload) {\n commit(types.UPDATE_USER, payload.user);\n },\n\n async logout({commit}) {\n try {\n await axios.post('/v1/auth/logout');\n } catch (e) {\n }\n\n removeToken();\n commit(types.LOGOUT);\n router.push({name: 'login'});\n },\n\n },\n\n mutations: {\n [types.SET_AUTH_LOADING](state, loading: { subject: string, loading: boolean }) {\n state.loading[loading.subject] = loading.loading;\n },\n [types.SET_TOKEN](state, {token, remember}) {\n state.token = token;\n setToken(token, remember);\n },\n [types.SAVE_TOKEN](state, {token, remember}) {\n state.token = token;\n setToken(token, remember);\n },\n [types.SAVE_REGISTER_ID](state: AuthState, id: string) {\n state.registerId = id;\n setRegisterToken(id);\n },\n [types.SET_USER](state, user) {\n user.loaded = true;\n state.user = user;\n },\n [types.SET_ROLES](state, roles) {\n state.roles = roles;\n if (roles.includes('super-admin')) {\n localStorage.setItem('super-admin', 'true');\n }\n },\n [types.SET_PERMISSIONS](state, permissions) {\n state.permissions = permissions;\n },\n\n [types.FETCH_USER_FAILURE](state) {\n state.token = null;\n removeToken();\n },\n\n [types.LOGOUT](state) {\n state.user = {\n loaded: false,\n roles: [],\n permissions: [],\n identities: {},\n };\n // remove token\n state.token = null;\n\n // unset roles/permissions\n state.roles = [];\n\n removeAllUserCookies();\n\n localStorage.removeItem('userListings');\n localStorage.removeItem('turo_me');\n localStorage.removeItem('turo_vehicles');\n localStorage.removeItem('message_templates');\n localStorage.removeItem('super-admin');\n localStorage.removeItem('welcome-panel');\n localStorage.removeItem('turo-selected-hosts');\n localStorage.removeItem('customer');\n CartService.removeCartUuid();\n },\n\n [types.UPDATE_USER](state, {user}) {\n state.user = user;\n },\n [types.SET_USER_NOTIFICATIONS](state, notifications) {\n state.notifications = notifications;\n },\n [types.SET_USER_API_TOKENS](state, tokens) {\n state.apiTokens = tokens;\n },\n }\n}\n\nexport default authModule;\n","const TOKEN_KEY = 'access_token';\nconst COMPANY_UUID_KEY = 'company_uuid';\nconst REFRESH_TOKEN_KEY = 'refresh_token';\n\nconst StorageService = {\n\n saveCompanyUuid(uuid: string): void {\n localStorage.setItem(COMPANY_UUID_KEY, uuid);\n },\n\n getCompanyUuid() {\n return localStorage.getItem(COMPANY_UUID_KEY);\n },\n\n removeCompanyUuid() {\n localStorage.removeItem(COMPANY_UUID_KEY);\n },\n\n\n saveShepherdTour(name: string) {\n localStorage.setItem(`shepherd-${name}`, new Date().getTime().toString());\n },\n\n getShepherdTour(name: string): string | null {\n return localStorage.getItem(`shepherd-${name}`);\n },\n};\n\nexport {StorageService};\n","import {EventBus} from '@/plugins/eventBus';\nimport axios from 'axios';\nimport * as types from '@/store/mutation-types';\nimport {Form} from '@/plugins/FWForms/index';\nimport {cloneDeep, get, uniqBy} from 'lodash';\nimport {StorageService} from '@/services/storage.service';\n\nexport interface AutomationsState {\n loading: Record<string, boolean>;\n form: Form<any>;\n automationUnits: any[];\n eventTypes: any[];\n currentEvent: any;\n currentEventOriginal: any;\n messageTemplates: any[];\n events: any[];\n currentPageEvents: any;\n eventsMeta: any;\n eventMeta: any;\n eventLogs: any[];\n\n}\n\n// state\nconst state: AutomationsState = {\n loading: {\n messageTemplate: false,\n triggered: false,\n upcoming: false,\n other: false,\n update: false,\n cancel: false,\n logs: false,\n sendNow: false,\n delete_automation: false,\n pause_automation: false,\n },\n form: new Form(),\n automationUnits: [\n {\n name: 'Minutes',\n code: 'minutes',\n },\n {\n name: 'Hours',\n code: 'hours',\n },\n {\n name: 'Days',\n code: 'days',\n },\n {\n name: 'Weeks',\n code: 'weeks',\n },\n ],\n eventTypes: [\n {\n label: 'Pre-trip Photos Rule',\n value: 'photos_rule',\n disabled: true,\n comingSoon: true,\n },\n {\n label: 'Booking Request',\n value: 'booking_request',\n },\n {\n label: 'Trip Booked',\n value: 'trip_booked',\n },\n {\n label: 'Start of Trip',\n value: 'start_of_trip',\n },\n {\n label: 'Halfway Point',\n value: 'halfway',\n },\n {\n label: '3/4 Point',\n value: '3_4',\n },\n {\n label: 'End of Trip',\n value: 'end_of_trip',\n },\n {\n label: 'Post-rental',\n value: 'post_rental',\n },\n ],\n currentEvent: {},\n currentEventOriginal: {},\n messageTemplates: [],\n events: [],\n currentPageEvents: {\n upcoming: [],\n triggered: [],\n other: [],\n },\n eventsMeta: {\n current_page: 0,\n },\n eventMeta: {\n upcoming: {\n current_page: 0,\n per_page: 100,\n },\n triggered: {\n current_page: 0,\n per_page: 100,\n },\n other: {\n current_page: 0,\n per_page: 100,\n },\n },\n eventLogs: [],\n};\n\nconst getters = {\n loading: state => state.loading,\n eventTypes: state => state.eventTypes,\n messageTemplates: state => state.messageTemplates,\n currentEvent: state => state.currentEvent,\n currentEventOriginal: state => state.currentEventOriginal,\n automationUnits: state => state.automationUnits,\n automationForm: state => state.form,\n events: state => state.events,\n currentPageEvents: state => state.currentPageEvents,\n eventsMeta: state => state.eventsMeta,\n eventMeta: state => state.eventMeta,\n eventLogs: state => state.eventLogs,\n};\n\nconst mutations = {\n [types.SET_AUTOMATION_LOADING](state, loading) {\n state.loading[loading.subject] = loading.loading;\n },\n [types.SET_MESSAGE_TEMPLATES](state, messageTemplates) {\n state.messageTemplates = messageTemplates;\n },\n [types.SET_CURRENT_AUTOMATION_EVENT](state, event) {\n state.currentEventOriginal = cloneDeep(event);\n state.currentEvent = event;\n },\n [types.SET_AUTOMATION_EVENTS](state, events) {\n state.currentPageEvents[events.type] = events.data.data;\n state.events = uniqBy([...state.events, ...events.data.data], w => w.uuid);\n\n delete events.data.data;\n delete events.data.links;\n state.eventMeta[events.type] = events.data;\n },\n [types.SET_CURRENT_EVENT_LOGS](state, logs) {\n state.eventLogs = logs;\n },\n};\n\nconst actions = {\n\n\n /**\n * Fetch automations\n *\n * @param commit\n */\n fetchAutomations({commit}) {\n axios.get('/v1/automations')\n .then((response) => {\n commit('SET_MESSAGE_TEMPLATES', get(response, 'data.automations', []));\n }).catch(() => {\n }).finally(() => {\n });\n },\n\n\n /**\n * Fetch automations events\n *\n * @param commit\n * @param {Object} data\n */\n fetchAutomationsEvents({commit}, data) {\n commit('SET_AUTOMATION_LOADING', {subject: 'upcoming', loading: true});\n\n const page = get(data, 'page', 1);\n const perPage = get(data, 'perPage', 100);\n\n axios.get(`/v1/automations-events?type=upcoming&page=${page}&perPage=${perPage}`)\n .then((response) => {\n const data = {\n data: get(response, 'data.events', []),\n type: 'upcoming',\n };\n commit('SET_AUTOMATION_EVENTS', data);\n }).catch(() => {\n }).finally(() => {\n commit('SET_AUTOMATION_LOADING', {subject: 'upcoming', loading: false});\n });\n },\n\n\n /**\n * Fetch triggered automations events\n *\n * @param commit\n * @param {Object} data\n */\n fetchTriggeredAutomationsEvents({commit}, data) {\n commit('SET_AUTOMATION_LOADING', {subject: 'triggered', loading: true});\n\n const page = get(data, 'page', 1);\n const perPage = get(data, 'perPage', 100);\n\n axios.get(`/v1/automations-events?type=triggered&page=${page}&perPage=${perPage}`)\n .then((response) => {\n const data = {\n data: get(response, 'data.events', []),\n type: 'triggered',\n };\n commit('SET_AUTOMATION_EVENTS', data);\n }).catch(() => {\n }).finally(() => {\n commit('SET_AUTOMATION_LOADING', {subject: 'triggered', loading: false});\n });\n },\n\n /**\n * Fetch other automations events\n *\n * @param commit\n * @param {Object} data\n */\n fetchOtherAutomationsEvents({commit}, data) {\n commit('SET_AUTOMATION_LOADING', {subject: 'other', loading: true});\n\n const page = get(data, 'page', 1);\n const perPage = get(data, 'perPage', 100);\n\n axios.get(`/v1/automations-events?type=other&page=${page}&perPage=${perPage}`)\n .then((response) => {\n const data = {\n data: get(response, 'data.events', []),\n type: 'other',\n };\n commit('SET_AUTOMATION_EVENTS', data);\n }).catch(() => {\n }).finally(() => {\n commit('SET_AUTOMATION_LOADING', {subject: 'other', loading: false});\n });\n },\n\n\n /**\n * Update a automation event\n *\n * @param commit\n * @param {Object} event\n */\n updateAutomationEvent({commit}, event) {\n commit('SET_AUTOMATION_LOADING', {subject: 'update', loading: true});\n\n axios.put(`/v1/company/${StorageService.getCompanyUuid()}/automations-events/${event.uuid}`, event)\n .then((response) => {\n EventBus.$emit('update-automation-event-success', get(response, 'data.event'));\n }).catch(() => {\n }).finally(() => {\n commit('SET_AUTOMATION_LOADING', {subject: 'update', loading: false});\n });\n },\n\n\n /**\n * Send an automation event now (override trigger date and send it now)\n *\n * @param commit\n * @param {Object} event\n */\n sendAutomationEventNow({commit}, event) {\n commit('SET_AUTOMATION_LOADING', {subject: 'sendNow', loading: true});\n\n axios.post(`/v1/automations-events/${event.uuid}/send`)\n .then((response) => {\n EventBus.$emit('send-now-automation-event-success', get(response, 'data.event'));\n }).catch((e) => {\n EventBus.$emit('send-now-automation-event-failure', get(e, 'response.data.message', 'There was an error.'));\n }).finally(() => {\n commit('SET_AUTOMATION_LOADING', {subject: 'sendNow', loading: false});\n });\n },\n\n /**\n * Cancel a automation event\n *\n * @param commit\n * @param {Object} event\n */\n cancelAutomationEvent({commit}, event) {\n commit('SET_AUTOMATION_LOADING', {subject: 'cancel', loading: true});\n\n axios.delete(`/v1/company/${StorageService.getCompanyUuid()}/automations-events/${event.uuid}`)\n .then((response) => {\n EventBus.$emit('cancel-automation-event-success', get(response, 'data.event'));\n }).catch(() => {\n }).finally(() => {\n commit('SET_AUTOMATION_LOADING', {subject: 'cancel', loading: false});\n });\n },\n\n\n /**\n * Get an automation event logs\n *\n * @param commit\n * @param {Object} event\n */\n getAutomationEventLogs({commit}, event) {\n commit('SET_AUTOMATION_LOADING', {subject: 'logs', loading: true});\n\n axios.get(`/v1/company/${StorageService.getCompanyUuid()}/automations-events/${event.uuid}/activity-logs`)\n .then((response) => {\n commit('SET_CURRENT_EVENT_LOGS', get(response, 'data.logs'));\n EventBus.$emit('get-automation-event-logs-success');\n }).catch(() => {\n }).finally(() => {\n commit('SET_AUTOMATION_LOADING', {subject: 'logs', loading: false});\n });\n },\n\n\n /**\n * Add message templates\n *\n * @param state\n * @param commit\n * @param {Object} template\n */\n addMessageTemplates({state, commit}, template) {\n state.form.errors.clear();\n state.form.busy = true;\n\n axios.post('/v1/automations', template)\n .then((response) => {\n EventBus.$emit('add-message-template-success');\n commit('SET_MESSAGE_TEMPLATES', get(response, 'data.automations', []));\n commit('SET_AUTOMATION_EVENTS', get(response, 'data.events', []));\n }).catch((e) => {\n state.form.errors.set(get(e, 'response.data.errors'));\n }).finally(() => {\n state.form.busy = false;\n });\n },\n\n\n /**\n * Save message templates\n *\n * @param state\n * @param commit\n * @param {Object} template\n * @param {String} template.uuid\n */\n saveMessageTemplates({state, commit}, template) {\n state.form.errors.clear();\n state.form.busy = true;\n\n axios.put(`/v1/automations/${template.uuid}`, template)\n .then((response) => {\n EventBus.$emit('save-message-template-success');\n commit('SET_MESSAGE_TEMPLATES', get(response, 'data.automations', []));\n commit('SET_AUTOMATION_EVENTS', get(response, 'data.events', []));\n }).catch((e) => {\n state.form.errors.set(get(e, 'response.data.errors'));\n }).finally(() => {\n state.form.busy = false;\n });\n },\n\n\n /**\n * Delete message template\n *\n * @param commit\n * @param {Array<String>} uuids\n */\n deleteMessageTemplates({commit}, uuids) {\n commit('SET_AUTOMATION_LOADING', {subject: 'delete_automation', loading: true});\n\n axios.post('/v1/automations/delete', {uuids})\n .then((response) => {\n EventBus.$emit('delete-message-template-success');\n commit('SET_MESSAGE_TEMPLATES', get(response, 'data.automations', []));\n commit('SET_AUTOMATION_EVENTS', get(response, 'data.events', []));\n }).catch(() => {\n }).finally(() => {\n commit('SET_AUTOMATION_LOADING', {subject: 'delete_automation', loading: false});\n });\n },\n\n /**\n * Activate/deactivate message template\n *\n * @param commit\n * @param {Object} data\n */\n pauseMessageTemplates({commit}, data) {\n commit('SET_AUTOMATION_LOADING', {subject: 'pause_automation', loading: true});\n\n axios.post('/v1/automations/pause', data)\n .then((response) => {\n EventBus.$emit('pause-message-template-success');\n commit('SET_MESSAGE_TEMPLATES', get(response, 'data.automations', []));\n commit('SET_AUTOMATION_EVENTS', get(response, 'data.events', []));\n }).catch(() => {\n }).finally(() => {\n commit('SET_AUTOMATION_LOADING', {subject: 'pause_automation', loading: false});\n });\n },\n};\n\nexport default {\n namespaced: true,\n state,\n mutations,\n actions,\n getters,\n};\n","import axios from 'axios';\nimport * as types from '@/store/mutation-types';\nimport {createUrlQueryString} from '@/utils/urls';\nimport {performApiRequest} from '@/store/helpers/vuex-helpers';\nimport {StoreLoaders} from '@/types';\nimport {push} from 'notivue';\n\ntype Axel = {\n active: boolean,\n balance: number,\n client_id: string | null,\n client_secret: string | null,\n created_at: string,\n low_balance_threshold: number,\n refill_amount: number,\n updated_at: string,\n uuid: string,\n}\n\nexport type AxelIgnition = {\n created_at: string,\n ignition_uri: string,\n policies: any | null,\n policy_account_id: any | null,\n results: any | null,\n status: any | null,\n updated_at: string | null\n uuid: string,\n}\n\nexport type AxleState = {\n loading: StoreLoaders,\n axleAccount: Axel | null,\n ignitions: AxelIgnition[],\n incomingIgnition: object | null,\n}\n\n\n// state\nconst state: AxleState = {\n loading: {\n getLinks: false,\n getCheckoutLink: false,\n fetchStartLink: false,\n refreshIgnition: false,\n startAxleAccount: false,\n axel_get: false,\n },\n axleAccount: null,\n ignitions: [],\n incomingIgnition: null,\n};\n\nconst getters = {\n loading: (state: AxleState) => state.loading,\n axleAccount: (state: AxleState) => state.axleAccount,\n ignitions: (state: AxleState) => state.ignitions,\n incomingIgnition: (state: AxleState) => state.incomingIgnition,\n};\n\nconst mutations = {\n [types.SET_AXLE_LOADING](state: AxleState, loading: { subject: string, loading: boolean }) {\n state.loading[loading.subject] = loading.loading;\n },\n\n [types.SET_AXLE](state: AxleState, axle: Axel | null) {\n state.axleAccount = axle;\n },\n [types.SET_AXLE_IGNITIONS](state: AxleState, ignitions: AxelIgnition[]) {\n state.ignitions = ignitions;\n },\n [types.SET_INCOMING_AXLE_IGNITION](state: AxleState, payload: object) {\n state.incomingIgnition = payload;\n },\n [types.MERGE_AXLE_IGNITION](state: AxleState, ignition: AxelIgnition) {\n const index = state.ignitions.findIndex((i) => i.uuid === ignition.uuid);\n\n if (index !== -1) {\n state.ignitions[index] = ignition;\n }\n },\n};\n\nconst actions = {\n\n /**\n * Get Axle account\n */\n async getAxle({commit}) {\n const responseData = await performApiRequest(commit, 'SET_AXLE_LOADING', 'axel_get', () => axios.get('/v1/axle'));\n commit(types.SET_AXLE, responseData.data);\n },\n\n\n /**\n * Fetch a checkout link\n */\n async getCheckoutLink({commit}, data: { credits: number }) {\n return await performApiRequest(commit, 'SET_AXLE_LOADING', 'getCheckoutLink', () => axios.post('/v1/axle/checkout-link', data));\n },\n\n async startAxleAccount({commit}) {\n return await performApiRequest(commit, 'SET_AXLE_LOADING', 'startAxleAccount', () => axios.post('/v1/axle/create-account'));\n },\n\n async testAutoRecharge({commit}) {\n return await performApiRequest(commit, 'SET_AXLE_LOADING', 'startAxleAccount', () => axios.post('/v1/axle/test-auto-recharge'));\n },\n\n /**\n * Fetch a start ignition link\n */\n async fetchStartIgnitionLink({commit}, data: { r_id?: string, b_id?: string }) {\n try {\n const responseData = await performApiRequest(commit, 'SET_AXLE_LOADING', 'fetchStartLink', () => axios.post('/v1/axle/start-ignition', data));\n commit(types.SET_AXLE_IGNITIONS, responseData.ignitions);\n } catch (error) {\n push.error({\n message: error?.response?.data?.message || 'An error occurred while fetching the ignition link',\n });\n }\n },\n\n /**\n * Fetch a start ignition link (public)\n */\n async fetchStartIgnitionLinkPublic({commit}, data: { b_id: string }) {\n try {\n const responseData = await performApiRequest(commit, 'SET_AXLE_LOADING', 'fetchStartLink', () => axios.post('/v1/axle/start-ignition/start', data));\n return responseData.url;\n } catch (error) {\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n }\n },\n\n\n /**\n * Get ignition links\n */\n async getIgnitionLinks({commit}, data = []) {\n try {\n const query = createUrlQueryString(data);\n const responseData = await performApiRequest(commit, 'SET_AXLE_LOADING', 'getLinks', () => axios.get(`/v1/axle/ignitions${query}`));\n commit(types.SET_AXLE_IGNITIONS, responseData.ignitions);\n } catch (error) {\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n }\n },\n\n /**\n * Refresh ignition link\n */\n async refreshIgnition({commit}, data: AxelIgnition) {\n try {\n const responseData = await performApiRequest(commit, 'SET_AXLE_LOADING', 'refreshIgnition', () => axios.post(`/v1/axle/ignitions/${data.uuid}/refresh`));\n commit(types.MERGE_AXLE_IGNITION, responseData.ignition);\n return responseData;\n } catch (error) {\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n }\n },\n};\n\nexport default {\n namespaced: true,\n state,\n mutations,\n actions,\n getters,\n};\n","import {EventBus} from '@/plugins/eventBus';\nimport axios from 'axios';\nimport * as types from '@/store/mutation-types';\nimport {CartService} from '@/services/cart.service';\nimport {createUrlQueryString} from '@/utils/urls';\nimport {performApiRequest} from \"@/store/helpers/vuex-helpers\";\n\n\ninterface Barcode {\n barcode_type: string;\n created_at?: string;\n image_url: string;\n number: string;\n owner_id: string;\n owner_type: string;\n updated_at?: string;\n uuid?: string;\n}\n\n\nexport interface BarcodeState {\n loading: Record<string, boolean>;\n barcode: Barcode;\n}\n\n// state\nconst state: BarcodeState = {\n loading: {\n fetchCart: false,\n delete: false,\n create: false,\n },\n barcode: null,\n};\n\nconst getters = {\n loading: (state: BarcodeState) => state.loading,\n barcode: (state: BarcodeState) => state.barcode,\n};\n\nconst mutations = {\n [types.SET_BARCODE_LOADING](state: BarcodeState, loading: { subject: string, loading: boolean }) {\n state.loading[loading.subject] = loading.loading;\n },\n [types.SET_BARCODE](state: BarcodeState, barcode: Barcode) {\n state.barcode = barcode;\n },\n};\n\nconst actions = {\n\n async findBarcode({commit}, payload: Record<string, string>) {\n const queryString = createUrlQueryString(payload);\n\n return axios.get(`/v1/barcodes${queryString}`)\n .then((response) => {\n commit(types.SET_BARCODE, response.data.barcode);\n EventBus.$emit('get-barcode-success', response.data.barcode);\n }).catch(() => {\n }).finally(() => {\n });\n },\n\n\n /**\n * Update a barcode\n */\n updateBarcode({commit}, barcode: Barcode) {\n axios.put(`/v1/barcodes/${barcode.uuid}`, barcode)\n .then((response) => {\n commit(types.SET_BARCODE, response.data.barcode);\n EventBus.$emit('update-barcode-success', response.data.barcode);\n }).catch(() => {\n }).finally(() => {\n });\n },\n\n\n /**\n * Create a new barcode\n */\n async createBarcode({commit}, data: Barcode) {\n try {\n const responseData = await performApiRequest(commit, 'SET_BARCODE_LOADING', 'create', () => axios.post('/v1/barcodes', data));\n commit(types.SET_BARCODE, responseData.barcode);\n EventBus.$emit('create-barcode-success', responseData.barcode);\n } catch (error) {\n EventBus.$emit('fetch-cart-error', error.response);\n if (error.response.status === 404) {\n CartService.removeCartUuid();\n window.location.reload();\n }\n }\n },\n\n /**\n * Delete a barcode\n */\n async deleteBarcode({commit}, barcode: Barcode) {\n try {\n await performApiRequest(commit, 'SET_BARCODE_LOADING', 'delete', () => axios.delete(`/v1/barcodes/${barcode.uuid}`));\n commit(types.SET_BARCODE, null);\n } catch (error) {\n }\n },\n};\n\nexport default {\n namespaced: true,\n state,\n mutations,\n actions,\n getters,\n};\n","import {Form} from '@/plugins/FWForms/index';\nimport {findIndex, get, remove, set} from 'lodash';\nimport axios from 'axios';\nimport {EventBus} from '@/plugins/eventBus';\nimport dayjs, {Dayjs} from 'dayjs';\nimport duration from 'dayjs/plugin/duration';\nimport {StorageService} from '@/services/storage.service';\nimport * as types from '../mutation-types';\nimport {createOrderUrlQueryString} from '@/utils/urls';\nimport {BookingInterface, ListingInterface, OrderLine, StoreLoaders} from '@/types';\nimport {performApiRequest} from '@/store/helpers/vuex-helpers';\nimport {GetterTree} from 'vuex';\nimport {RootState} from '@/types/RootState';\nimport {push} from 'notivue'\n\ndayjs.extend(duration);\n\nexport type CancelBookingPayload = {\n b_id: string;\n refund: boolean;\n unblockTuro: boolean;\n sendCancellationEmail: boolean;\n}\n\n\ntype BookingQueryOptions = {\n page?: number,\n sortDesc?: string[] | boolean,\n itemsPerPage?: number,\n includeAbandoned?: boolean,\n onlyAbandoned?: boolean,\n withOrderProperties?: boolean,\n withRenterProperties?: boolean,\n searchTerm?: string,\n searchTopic?: string,\n exporting?: boolean,\n providers?: string[],\n statuses?: string[],\n filter?: any,\n sortBy?: Array<{ key: string, order: string }>\n}\n\n\nfunction prepareBookingData(options: BookingQueryOptions = {}) {\n const {\n page = 1,\n sortDesc = [],\n itemsPerPage = 20,\n includeAbandoned = false,\n onlyAbandoned = false,\n withOrderProperties,\n withRenterProperties,\n searchTerm,\n searchTopic,\n exporting,\n providers = [],\n statuses = [],\n filter,\n sortBy\n } = options;\n\n const data: {\n page: number;\n sortDesc: string | boolean;\n itemsPerPage: number;\n includeAbandoned?: boolean;\n onlyAbandoned?: boolean;\n withOrderProperties?: boolean;\n withRenterProperties?: boolean;\n searchTerm?: string;\n searchTopic?: string;\n exporting?: boolean;\n providers: string[];\n statuses?: string;\n filter?: any;\n sortBy?: string;\n filterQuery?: string;\n } = {\n page,\n sortDesc: Array.isArray(sortDesc) && sortDesc.length === 1 ? sortDesc[0] : !!sortDesc,\n itemsPerPage,\n includeAbandoned,\n onlyAbandoned,\n withOrderProperties,\n withRenterProperties,\n searchTerm,\n searchTopic,\n exporting,\n providers\n };\n\n if (statuses.length > 0) {\n data.statuses = statuses.join(',');\n }\n\n if (providers.length > 0) {\n data.statuses = providers.join(',');\n }\n\n if (!includeAbandoned) {\n delete data.includeAbandoned;\n }\n\n if (!onlyAbandoned) {\n delete data.onlyAbandoned;\n }\n\n if (filter) {\n data.filter = filter;\n data.filterQuery = Object.entries(filter)\n .filter(([_, value]) => value)\n .map(([key, value]) => `filter[${key}]=${value}`)\n .join('&');\n }\n\n if (sortBy) {\n data.sortBy = sortBy?.[0]?.key;\n data.sortDesc = sortBy?.[0]?.order === 'desc';\n }\n\n return data;\n}\n\nexport interface BookingGetters extends GetterTree<BookingState, RootState> {\n init(state: BookingState): boolean;\n\n notFound(state: BookingState): boolean;\n\n statusFilterItems(state: BookingState): string[];\n\n startsAtFilterItems(state: BookingState): string | null;\n\n statusFilterTemp(state: BookingState): string[];\n\n paymentStatusFilterItems(state: BookingState): string[];\n\n activityFilter(state: BookingState): string;\n\n sourcesFilter(state: BookingState): string[];\n\n booking(state: BookingState): BookingInterface;\n\n priorityBookings(state: BookingState): BookingInterface[];\n\n bookings(state: BookingState): BookingInterface[];\n\n meta(state: BookingState): any;\n\n fleetResources(state: BookingState): any;\n\n abandonedBookings(state: BookingState): BookingInterface[];\n\n totalBookings(state: BookingState): number;\n\n customerBooking(state: BookingState): any;\n\n bookingLoading(state: BookingState): Record<string, boolean>;\n\n calendarAttributes(state: BookingState): any[];\n\n bookingCustomer(state: BookingState): any;\n\n bookingVehicle(state: BookingState): any;\n\n completeBooking(state: BookingState): {\n b_id: string,\n };\n\n filteredMake(state: BookingState): object[];\n\n turoBookings(state: BookingState): any[];\n\n rememberedCustomer(state: BookingState): any;\n\n res2(state: BookingState): any;\n\n bookingForm(state: BookingState): Form<any>;\n\n bookingPayments(state: BookingState): any[];\n\n automationEvents(state: BookingState): any[];\n}\n\n\ntype BookingVehicleSwapData = {\n b_id: string,\n listing: ListingInterface,\n transferListingData: boolean,\n transferUnavailabilityOnCarSharing: boolean,\n}\n\ntype CalendarAttribute = {\n key: string,\n id?: number,\n highlight: {\n color: string,\n fillMode: string,\n },\n dates: string | Dayjs | Date | string[],\n popover: {\n label: string,\n },\n bar?: string,\n trip_start?: string,\n trip_end?: string,\n trip_start_buffer?: string,\n trip_end_buffer?: string,\n}\n\n\nexport interface BookingMeta {\n current_page: number;\n from: number | null;\n last_page: number;\n links: Array<{ url: string | null, label: string, active: boolean }>;\n path: string;\n per_page: number;\n stats: {\n count: {\n [key: string]: number,\n },\n payment_status: {\n [key: string]: number,\n },\n sources: {\n [key: string]: number,\n },\n statuses: {\n [key: string]: number,\n },\n tag_list: string[],\n total: number,\n }\n to: number | null;\n total: number;\n total_bookings: number;\n}\n\nexport type BookingState = {\n dialogs: Record<string, boolean>,\n loading: StoreLoaders,\n init: boolean,\n notFound: boolean,\n listing: ListingInterface,\n statusFilterItems: string[],\n startsAtFilterItems: string | null,\n statusFilterTemp: string[],\n paymentStatusFilterItems: string[],\n activityFilter: string,\n sourcesFilter: string[],\n booking: BookingInterface,\n priorityBookings: BookingInterface[],\n bookings: BookingInterface[],\n meta: BookingMeta,\n fleetResources: any,\n abandoned_bookings: BookingInterface[],\n totalBookings: number,\n customerBooking: any,\n calendarAttributes: CalendarAttribute[],\n unavailableDates: any[],\n completeBooking: {\n b_id: string,\n },\n filteredMake: object[],\n turoBookings: any[],\n rememberedCustomer: any,\n res2: any,\n bookingForm: Form<any>,\n bookingPayments: any[],\n automationEvents: any[],\n}\n\n\nconst state: BookingState = {\n init: false,\n notFound: false,\n\n dialogs: {\n createTripExtensionDialog: false,\n },\n\n loading: {\n booking: false,\n booking_logs: false,\n bookings: false,\n meta: false,\n priority_bookings: false,\n fleet_resources: false,\n manualCheckout: false,\n check_vehicles_availability: false,\n updateBooking: false,\n extendBooking: false,\n deleteExtension: false,\n cancelBooking: false,\n bookingPayments: false,\n bookingStatus: false,\n addOrderItem: false,\n startBookingVehicleSwap: false,\n startBookingVehicleSwapStep2: false,\n attachCommissionPartner: false,\n getAutomationEvents: false,\n updateBookingCustomerFields: false,\n manuallyRemoveBooking: false,\n deleteTripPhotos: false,\n },\n\n bookingForm: new Form(),\n\n listing: null,\n\n customerBooking: {},\n\n totalBookings: 0,\n priorityBookings: [],\n bookings: [],\n abandoned_bookings: [],\n\n booking: {\n init: false,\n complete: 0,\n created_at: '',\n days: 0,\n delivery_price: 0,\n discount: 0,\n extras_price: 0,\n manually_deleted_at: null,\n booking_meta: null,\n payment_status: '',\n price_per_day: 0,\n r_id: '',\n renter: null,\n required_options_price: 0,\n source: '',\n status: '',\n taxes: 0,\n timezone: '',\n total: 0,\n trip_end: '',\n trip_end_tz: '',\n trip_start: '',\n trip_start_tz: '',\n turo_trip: null,\n updated_at: '',\n method: '',\n miles_extra: 0,\n miles_included: 0,\n\n b_id: null,\n l_id: null,\n cartId: null,\n\n host: null,\n\n order_items: [],\n\n customer: {\n firstName: '',\n lastName: '',\n phone: '',\n email: '',\n dob: '',\n age: '',\n signaturePng: '',\n signFullName: '',\n signInitials: '',\n agreeAdoptSignature: false,\n agreeToS: false,\n },\n\n settings: {\n zip_code: '',\n age_requirement: 0,\n mile_allowance: {\n miles_included: 0,\n miles_extra: 0,\n miles_extra_selected: false,\n },\n\n young_driver: 0,\n description: '',\n },\n\n vehicle: {\n available: false,\n price: 0,\n title: '',\n color: '',\n year: '',\n image: '',\n images: [],\n duration: '',\n miles_included: '',\n lat: '',\n long: '',\n },\n\n listing: null,\n\n pricing: {\n original_price: 0,\n price: 0,\n price_type: '',\n price_period: '',\n\n discounts: {\n success: false,\n loading: false,\n discounted: false,\n code: '',\n discount: '',\n discountValue: 0,\n newPrice: 0,\n type: '',\n reason: '',\n },\n\n delivery: 0,\n extras: 0,\n requiredOption: 0,\n total_per_day: 0,\n subTotal: 0,\n grandTotal: 0,\n paymentDisplay: '',\n security_deposit: 0,\n },\n\n trip_required_options: [],\n\n trip_displays: {\n tripMilesUnlimited: false,\n tripMilesIncluded: '',\n tripMilesOverageDisplay: '',\n tripMilesHelpModalDisplay: '',\n\n young_driver: {\n helpModalDisplaySet: false,\n helpModalDisplayH1: '',\n helpModalDisplayP1: '',\n },\n },\n\n mile_allowance: {\n miles_included: '',\n miles_extra: '',\n miles_extra_selected: false,\n },\n\n duration: {\n months: 0,\n weeks: 0,\n days: 1,\n hours: 0,\n minutes: 0,\n units: 1,\n },\n\n location: {\n city: '',\n state: '',\n zip_code: '',\n neighborhood: '',\n airport_code: '',\n price: 0,\n type: '',\n selecting: false,\n count: JSON.parse(localStorage.getItem('count')),\n },\n\n locations: [],\n\n delivery: {},\n },\n\n meta: null,\n bookingPayments: [],\n\n completeBooking: {\n b_id: '',\n },\n\n filteredMake: [],\n\n unavailableDates: [],\n calendarAttributes: [\n {\n key: 'today',\n highlight: {\n color: 'orange',\n fillMode: 'light',\n },\n dates: new Date(),\n popover: {\n label: 'Today',\n },\n },\n ],\n\n turoBookings: [],\n\n rememberedCustomer: {},\n res2: null,\n automationEvents: [],\n fleetResources: [],\n statusFilterItems: [] as string[],\n startsAtFilterItems: null,\n statusFilterTemp: [],\n paymentStatusFilterItems: [],\n sourcesFilter: [] as string[],\n activityFilter: '',\n};\n\nconst getters: BookingGetters = {\n init: (state: BookingState) => state.init,\n notFound: (state: BookingState) => state.notFound,\n statusFilterItems: (state: BookingState) => state.statusFilterItems,\n startsAtFilterItems: (state: BookingState) => state.startsAtFilterItems,\n statusFilterTemp: (state: BookingState) => state.statusFilterTemp,\n paymentStatusFilterItems: (state: BookingState) => state.paymentStatusFilterItems,\n activityFilter: (state: BookingState) => state.activityFilter,\n sourcesFilter: (state: BookingState) => state.sourcesFilter,\n booking: (state: BookingState) => state.booking,\n priorityBookings: (state: BookingState) => state.priorityBookings,\n bookings: (state: BookingState) => state.bookings,\n meta: (state: BookingState) => state.meta,\n fleetResources: (state: BookingState) => state.fleetResources,\n abandonedBookings: (state: BookingState) => state.abandoned_bookings,\n totalBookings: (state: BookingState) => state.totalBookings,\n customerBooking: (state: BookingState) => state.customerBooking,\n bookingLoading: (state: BookingState) => state.loading,\n calendarAttributes: (state: BookingState) => state.calendarAttributes,\n unavailableDates: (state: BookingState) => state.unavailableDates,\n bookingCustomer: (state: BookingState) => state.booking.customer,\n bookingVehicle: (state: BookingState) => state.booking.vehicle,\n completeBooking: (state: BookingState) => state.completeBooking,\n filteredMake: (state: BookingState) => state.filteredMake,\n turoBookings: (state: BookingState) => state.turoBookings,\n rememberedCustomer: (state: BookingState) => state.rememberedCustomer,\n res2: (state: BookingState) => state.res2,\n bookingForm: (state: BookingState) => state.bookingForm,\n bookingPayments: (state: BookingState) => state.bookingPayments,\n automationEvents: (state: BookingState) => state.automationEvents,\n bookingDialogs: (state: BookingState) => state.dialogs,\n};\n\nconst mutations = {\n [types.SET_BOOKING_LOADING](state: BookingState, loading: { subject: string, loading: boolean }) {\n state.loading[loading.subject] = loading.loading;\n },\n\n [types.SET_BOOKING_DIALOG](state: BookingState, dialog: { subject: string, value: boolean }) {\n state.dialogs[dialog.subject] = dialog.value;\n },\n [types.CLEAR_BOOKING_FORM_ERRORS](state: BookingState, form_field) {\n if (form_field === null || form_field === undefined) {\n state.bookingForm.errors.clear();\n } else {\n state.bookingForm.errors.clear(form_field);\n }\n },\n [types.SET_BOOKING_FORM_ERROR](state: BookingState, error) {\n state.bookingForm.errors.set(error.field, error.message);\n },\n [types.SET_LISTING_ID](state: BookingState, l_id: string) {\n state.booking.l_id = l_id;\n },\n [types.SET_STATUS_FILTER_ITEMS](state: BookingState, statuses) {\n state.startsAtFilterItems = null;\n state.statusFilterItems = statuses;\n },\n [types.SET_STATUS_FILTER_ITEMS_UPCOMING](state: BookingState) {\n state.statusFilterItems = ['reserved'];\n state.startsAtFilterItems = dayjs().format('YYYY-MM-DD HH:mm:ss');\n },\n [types.SET_STATUS_FILTER_TEMP_ITEMS](state: BookingState, filter) {\n state.statusFilterTemp = filter;\n },\n [types.SET_ACTIVITY_FILTER_ITEMS](state: BookingState, activity) {\n state.activityFilter = activity;\n },\n [types.SET_SOURCE_FILTER_ITEMS](state: BookingState, sources) {\n state.sourcesFilter = sources;\n },\n [types.SET_PAYMENT_STATUS_FILTER_ITEMS](state: BookingState, statuses) {\n state.paymentStatusFilterItems = statuses;\n },\n [types.SET_BOOKING_CART_ID](state: BookingState, cartId: string) {\n state.booking.cartId = cartId;\n },\n [types.SET_CURRENT_WORKING_BOOKING](state: BookingState, booking: BookingInterface) {\n state.booking = booking;\n state.init = true;\n },\n [types.SET_CURRENT_WORKING_BOOKING_STATUS](state: BookingState, status: string) {\n set(state.booking, 'status', status);\n },\n [types.SET_CURRENT_WORKING_BOOKING_ATTRIBUTE](state: BookingState, data) {\n set(state.booking, data.attribute, get(data.booking, data.attribute));\n },\n [types.SET_BOOKING_NOT_FOUND](state: BookingState, value) {\n state.notFound = value;\n },\n [types.SET_BOOKINGS](state: BookingState, bookings: BookingInterface[]) {\n state.bookings = bookings;\n state.init = true;\n },\n [types.SET_BOOKINGS_META](state: BookingState, meta) {\n state.meta = meta;\n },\n [types.SET_ABANDONED_BOOKINGS](state: BookingState, bookings: BookingInterface[]) {\n state.abandoned_bookings = bookings;\n },\n [types.SET_PRIORITY_BOOKINGS](state: BookingState, bookings: BookingInterface[]) {\n state.priorityBookings = bookings;\n },\n [types.SET_FLEET_RESOURCES](state: BookingState, bookings: BookingInterface[]) {\n state.fleetResources = bookings;\n },\n [types.SET_BOOKING_AUTOMATION_EVENTS](state: BookingState, events) {\n state.automationEvents = events;\n },\n [types.SET_TOTAL_BOOKINGS](state: BookingState, count) {\n state.totalBookings = count;\n },\n [types.SET_BOOKING_PAYMENTS](state: BookingState, payments) {\n state.bookingPayments = payments;\n },\n [types.MERGE_BOOKING_LINE_ITEM](state: BookingState, line) {\n state.booking.order_items.push(line);\n },\n [types.UPDATE_BOOKING_LINE_ITEM](state: BookingState, line) {\n const lineIndex = findIndex(state.booking.order_items, l => l.uuid === line.uuid);\n if (lineIndex >= 0) {\n state.booking.order_items.splice(lineIndex, 1);\n state.booking.order_items.push(line);\n }\n },\n [types.REMOVE_BOOKING_LINE_ITEM](state: BookingState, line) {\n state.booking.order_items = remove(state.booking.order_items, l => l.uuid !== line);\n },\n [types.SET_FILTERED_MAKES](state: BookingState, make) {\n state.filteredMake = make;\n },\n [types.SET_CALENDAR_ATTRIBUTES](state: BookingState, attributes: CalendarAttribute[]) {\n state.calendarAttributes = attributes;\n },\n [types.PUSH_CALENDAR_ATTRIBUTES](state: BookingState, attribute: CalendarAttribute) {\n state.calendarAttributes.push(attribute);\n },\n [types.RESET_UNAVAILABLE_DATES](state: BookingState) {\n state.calendarAttributes = [\n {\n key: 'today',\n highlight: {\n color: 'orange',\n fillMode: 'light',\n },\n dates: new Date(),\n popover: {\n label: 'Today',\n },\n },\n ];\n },\n [types.SET_UNAVAILABLE_DATES](state: BookingState, dates: {\n trip_start: string,\n trip_end: string,\n trip_start_buffer: string,\n trip_end_buffer: string\n }[]) {\n state.unavailableDates = dates;\n\n state.calendarAttributes = [{\n key: 'today',\n highlight: {\n color: 'orange',\n fillMode: 'light',\n },\n dates: new Date(),\n popover: {\n label: 'Today',\n },\n },];\n\n const createCalendarAttribute = (barColor: string, date: string | Dayjs, label: string): CalendarAttribute => ({\n key: 'unavailable-' + date,\n highlight: null,\n bar: barColor,\n dates: [dayjs(date).format()],\n popover: {label},\n });\n\n dates.forEach(date => {\n const days = dayjs.duration(dayjs(date.trip_end).diff(dayjs(date.trip_start))).asDays();\n const startTimeBuffer = dayjs(date.trip_start_buffer).format('h:mm a');\n const endTimeBuffer = dayjs(date.trip_end_buffer).format('h:mm a');\n\n if (days === 1) {\n state.calendarAttributes.push(\n createCalendarAttribute('green', date.trip_start, `Becomes unavailable at ${startTimeBuffer}`),\n createCalendarAttribute('red', date.trip_start, `Unavailable after ${startTimeBuffer}`),\n createCalendarAttribute('red', date.trip_end, `Unavailable until ${startTimeBuffer}`),\n createCalendarAttribute('green', date.trip_end, `Becomes available after ${endTimeBuffer}`),\n );\n } else {\n const middleDur = [];\n for (let i = 1; i < days; i++) {\n middleDur.push(createCalendarAttribute('red', dayjs(date.trip_start).add(i, 'days'), 'Unavailable'));\n }\n\n state.calendarAttributes.push(\n createCalendarAttribute('green', date.trip_start, `Becomes unavailable at ${startTimeBuffer}`),\n createCalendarAttribute('red', date.trip_start, `Unavailable after ${startTimeBuffer}`),\n ...middleDur,\n createCalendarAttribute('red', date.trip_end, `Unavailable until after ${endTimeBuffer}`),\n createCalendarAttribute('green', date.trip_end, `Becomes available after ${endTimeBuffer}`),\n );\n }\n });\n },\n\n [types.SET_BOOKING_LISTING](state: BookingState, data) {\n state.listing = data;\n state.listing.init = true;\n const newPricing = data.pricing;\n state.booking.pricing = {...state.booking.pricing, ...newPricing};\n\n state.booking.pricing.security_deposit = get(data, 'pricing.sec_dep');\n },\n\n [types.SET_STORED_TURO_BOOKINGS](state: BookingState, bookings) {\n state.turoBookings = bookings;\n },\n [types.SET_CUSTOMER_BOOKING](state: BookingState, booking) {\n state.customerBooking = booking;\n },\n [types.SET_REMEMBER_CUSTOMER](state: BookingState, customer) {\n const data = {\n email: get(customer, 'email'),\n stripe_id: get(customer, 'stripe_id'),\n last4: null,\n };\n\n if (get(customer, 'last4')) {\n data.last4 = get(customer, 'last4');\n }\n state.rememberedCustomer = customer;\n localStorage.setItem('customer', JSON.stringify(data));\n },\n [types.RESET_BOOKING](state: BookingState) {\n state.booking = {\n fuel_level_end: 0,\n fuel_level_start: 0,\n listing: undefined,\n odometer_end: 0,\n odometer_start: 0,\n b_id: '',\n booking_meta: undefined,\n complete: 0,\n created_at: '',\n days: 0,\n delivery_price: 0,\n discount: 0,\n extras_price: 0,\n manually_deleted_at: '',\n method: '',\n miles_extra: 0,\n miles_included: 0,\n payment_status: '',\n price_per_day: 0,\n r_id: '',\n renter: undefined,\n required_options_price: 0,\n source: '',\n status: '',\n taxes: 0,\n timezone: '',\n total: 0,\n trip_end: '',\n trip_end_tz: '',\n trip_start: '',\n trip_start_tz: '',\n turo_trip: null,\n updated_at: '',\n init: false,\n l_id: null,\n cartId: null,\n host: null,\n order_items: [],\n customer: {\n firstName: '',\n lastName: '',\n phone: '',\n email: '',\n dob: '',\n age: '',\n signaturePng: '',\n signFullName: '',\n signInitials: '',\n agreeAdoptSignature: false,\n agreeToS: false,\n },\n settings: {\n zip_code: '',\n age_requirement: 0,\n mile_allowance: {\n miles_included: 0,\n miles_extra: 0,\n miles_extra_selected: false,\n },\n\n young_driver: 0,\n description: '',\n },\n\n vehicle: {\n available: false,\n price: 0,\n title: '',\n color: '',\n year: '',\n image: '',\n images: [],\n duration: '',\n miles_included: '',\n lat: '',\n long: '',\n },\n\n pricing: {\n original_price: 0,\n price: 0,\n price_type: '',\n price_period: '',\n\n discounts: {\n success: false,\n loading: false,\n discounted: false,\n code: '',\n discount: '',\n discountValue: 0,\n newPrice: 0,\n type: '',\n reason: '',\n },\n\n delivery: 0,\n extras: 0,\n requiredOption: 0,\n total_per_day: 0,\n subTotal: 0,\n grandTotal: 0,\n paymentDisplay: '',\n security_deposit: 1,\n },\n\n trip_required_options: [],\n\n trip_displays: {\n tripMilesUnlimited: false,\n tripMilesIncluded: '',\n tripMilesOverageDisplay: '',\n tripMilesHelpModalDisplay: '',\n\n young_driver: {\n helpModalDisplaySet: false,\n helpModalDisplayH1: '',\n helpModalDisplayP1: '',\n },\n },\n\n mile_allowance: {\n miles_included: '',\n miles_extra: '',\n miles_extra_selected: false,\n },\n\n duration: {\n months: 0,\n weeks: 0,\n days: 1,\n hours: 0,\n minutes: 0,\n units: 1,\n },\n\n location: {\n city: '',\n state: '',\n zip_code: '',\n neighborhood: '',\n airport_code: '',\n price: 0,\n type: '',\n selecting: false,\n count: JSON.parse(localStorage.getItem('count')),\n },\n\n locations: [],\n\n delivery: {}\n };\n },\n};\n\nconst actions = {\n\n async fetchSingleBooking({commit}, b_id: string) {\n commit(types.SET_BOOKING_NOT_FOUND, false);\n\n try {\n const responseData = await performApiRequest(commit, 'SET_BOOKING_LOADING', 'booking', () => axios.get(`/v1/bookings/${b_id}`));\n\n\n const renter = responseData?.booking?.renter || [];\n const order = responseData?.booking?.order || [];\n\n commit('SET_CURRENT_WORKING_BOOKING', responseData.booking);\n commit('renters/SET_RENTER', renter, {root: true});\n commit('order/SET_ORDER', order, {root: true});\n EventBus.$emit('fetch-single-booking-success', responseData.booking);\n } catch (error) {\n if (error.response.status === 404) {\n commit(types.SET_BOOKING_NOT_FOUND, true);\n }\n }\n },\n\n getBookingActivityLogs({commit}, b_id: string) {\n commit('SET_BOOKING_LOADING', {subject: 'booking_logs', loading: true});\n\n axios.get(`/v1/bookings/${b_id}/activity-logs`)\n .then(response => {\n EventBus.$emit('get-booking--activity-logs-success', get(response, 'data.activity'));\n }).catch(() => {\n }).finally(() => {\n commit('SET_BOOKING_LOADING', {subject: 'booking_logs', loading: false});\n });\n },\n\n async fetchPriorityBookings({commit}) {\n const responseData = await performApiRequest(commit, 'SET_BOOKING_LOADING', 'priority_bookings', () => axios.get('/v1/bookings/priority'));\n commit(types.SET_PRIORITY_BOOKINGS, responseData.bookings);\n },\n\n /**\n * Fetch fleet resources\n */\n fetchFleetResources({commit}, options) {\n commit('SET_BOOKING_LOADING', {subject: 'fleet_resources', loading: true});\n\n let qString = '?';\n if (get(options, 'startDate')) {\n qString += `startDate=${get(options, 'startDate')}`;\n }\n if (get(options, 'endDate')) {\n qString += `&endDate=${get(options, 'endDate')}`;\n }\n\n axios.get(`/v1/fleet-resources${qString}`)\n .then(response => {\n commit('SET_FLEET_RESOURCES', get(response, 'data.bookings'));\n }).catch(() => {\n }).finally(() => {\n commit('SET_BOOKING_LOADING', {subject: 'fleet_resources', loading: false});\n });\n },\n\n fetchCustodianFleetResources({commit}, options) {\n commit('SET_BOOKING_LOADING', {subject: 'fleet_resources', loading: true});\n\n let qString = '?';\n if (get(options, 'startDate')) {\n qString += `startDate=${get(options, 'startDate')}`;\n }\n if (get(options, 'endDate')) {\n qString += `&endDate=${get(options, 'endDate')}`;\n }\n\n axios.get(`/v1/custodians/${options.company_uuid}/fleet-resources${qString}`)\n .then(response => {\n commit('SET_FLEET_RESOURCES', get(response, 'data.bookings'));\n }).catch(() => {\n }).finally(() => {\n commit('SET_BOOKING_LOADING', {subject: 'fleet_resources', loading: false});\n });\n },\n\n /**\n * Fetch bookings\n */\n async fetchBookings({commit}, options: BookingQueryOptions = {}) {\n try {\n const data = prepareBookingData(options);\n\n const query = createOrderUrlQueryString(data, true);\n\n const responseData = await performApiRequest(commit, 'SET_BOOKING_LOADING', 'bookings', () => axios.get(`/v1/bookings${query}`));\n\n if (options?.onlyAbandoned) {\n commit(types.SET_ABANDONED_BOOKINGS, responseData.data);\n } else {\n commit(types.SET_BOOKINGS, responseData.data);\n commit(types.SET_BOOKINGS_META, responseData.meta);\n commit(types.SET_TOTAL_BOOKINGS, responseData.meta.total);\n }\n } catch (error) {\n commit('SET_BOOKING_FORM_ERROR', error.response?.data?.message || 'There was an error');\n console.error(error)\n }\n },\n\n async fetchCompanyBooking({commit}, b_id: string) {\n try {\n const responseData = await performApiRequest(commit, 'SET_BOOKING_LOADING', 'booking', () => axios.get(`/v1/company/${StorageService.getCompanyUuid()}/booking/${b_id}`));\n\n commit(types.SET_CUSTOMER_BOOKING, responseData?.booking || []);\n EventBus.$emit('booking-fetch-axle-success', responseData?.axle);\n const envelopes = responseData?.booking?.envelope || [];\n let lastEnvelope = {};\n if (envelopes.length > 0) {\n lastEnvelope = envelopes[envelopes.length - 1];\n }\n commit('envelope/SET_ENVELOPE', lastEnvelope, {root: true});\n EventBus.$emit('booking-fetch-success');\n } catch (error) {\n if (error.response.status === 404) {\n commit(types.SET_BOOKING_NOT_FOUND, true);\n }\n }\n },\n\n /**\n * Create a booking meta\n */\n async createBookingMeta({commit}, data: { booking: BookingInterface, key: string, value: any }) {\n return await performApiRequest(commit, 'SET_BOOKING_LOADING', 'meta', () => axios.post(`/v1/bookings/${data.booking.b_id}/meta`, {\n key: data.key,\n value: data.value,\n }));\n },\n\n fetchStoredTuroBookings({commit}) {\n axios.get('/v1/turo-bookings')\n .then(response => {\n commit('SET_STORED_TURO_BOOKINGS', get(response, 'data.bookings', []));\n }).catch(() => {\n }).finally(() => {\n commit('SET_BOOKING_LOADING', {subject: 'check_vehicles_availability', loading: false});\n });\n },\n\n updateListingId({commit}, l_id) {\n commit(types.SET_LISTING_ID, l_id);\n },\n\n async checkOneListingsBookings({commit}, l_id: string) {\n const responseData = await performApiRequest(commit, 'SET_BOOKING_LOADING', 'check_vehicles_availability', () => axios.get(`/v1/company/${StorageService.getCompanyUuid()}/listings/${l_id}/availability`));\n commit('SET_UNAVAILABLE_DATES', responseData.unavailable);\n },\n\n /**\n * Update a bookings\n *\n * @param commit\n * @param state\n * @param {String} id\n */\n retrieve: {\n root: true,\n handler({commit, state}, id) {\n axios.post(`/v1/company/${StorageService.getCompanyUuid()}/stripe/retrieve`, {\n id,\n }).then(response => {\n const checkoutSession = get(response, 'data.checkoutSession');\n state.res2 = get(response, 'data.$res2');\n\n /**\n * @typedef {Object} checkoutSession.customer\n * @typedef {Object} checkoutSession.setup_intent\n */\n commit('SET_REMEMBER_CUSTOMER', {\n email: checkoutSession.customer.email,\n stripe_id: checkoutSession.customer.id,\n last4: checkoutSession.setup_intent.payment_method.card.last4,\n });\n }).catch(() => {\n });\n },\n },\n\n /**\n * Update a bookings\n */\n async updateBooking({commit, state}, data) {\n try {\n commit('CLEAR_BOOKING_FORM_ERRORS');\n const responseData = await performApiRequest(commit, 'SET_BOOKING_LOADING', 'updateBooking', () => axios.put(`/v1/bookings/${data.b_id}`, data));\n\n commit('SET_CURRENT_WORKING_BOOKING', responseData.booking);\n commit('renters/SET_RENTER', responseData?.booking?.renter || [], {root: true});\n push.success({\n message: 'Booking updated successfully',\n });\n } catch (error) {\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n state.bookingForm.errors.set(error?.response?.data?.errors || []);\n }\n },\n\n /**\n * Update a booking custom field\n *\n * @param commit\n * @param {Object} data\n */\n updateBookingCustomFields({commit}, data) {\n commit('SET_BOOKING_LOADING', {subject: 'updateBookingCustomerFields', loading: true});\n\n axios.put(`/v1/bookings/${data.b_id}/custom-fields`, {properties: data.properties})\n .then(() => {\n EventBus.$emit('update-custom-field-success');\n })\n .catch(error => {\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n }).finally(() => {\n commit('SET_BOOKING_LOADING', {subject: 'updateBookingCustomerFields', loading: false});\n });\n },\n\n /**\n * Extend a bookings\n */\n async extendBooking({commit}, data) {\n const responseData = await performApiRequest(commit, 'SET_BOOKING_LOADING', 'extendBooking', () => axios.post(`/v1/bookings/${data.b_id}/extend`, data));\n commit(types.SET_CURRENT_WORKING_BOOKING, responseData.booking);\n return responseData;\n },\n\n /**\n * Delete a booking extension\n */\n async deleteExtension({commit}, extension_uuid: string) {\n const responseData = await performApiRequest(commit, 'SET_BOOKING_LOADING', 'deleteExtension', () => axios.delete(`/v1/extensions/${extension_uuid}`));\n\n commit('SET_CURRENT_WORKING_BOOKING_ATTRIBUTE', {\n booking: responseData.booking,\n attribute: 'extensions'\n });\n EventBus.$emit('extension-deleted-success', responseData.booking);\n },\n\n attachCommissionPartner({commit}, data) {\n commit('SET_BOOKING_LOADING', {subject: 'attachCommissionPartner', loading: true});\n commit('CLEAR_BOOKING_FORM_ERRORS');\n\n axios.put(`/v1/bookings/${data.b_id}/attach-commission-partner/${data.partner_uuid}`, data).then(response => {\n commit('SET_CURRENT_WORKING_BOOKING', get(response, 'data.booking'));\n EventBus.$emit('attache-partner-commission-success');\n }).catch(error => {\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n }).finally(() => {\n commit('SET_BOOKING_LOADING', {subject: 'attachCommissionPartner', loading: false});\n });\n },\n\n removeCommissionPartnerFromBooking({commit}, data) {\n commit('SET_BOOKING_LOADING', {subject: 'attachCommissionPartner', loading: true});\n commit('CLEAR_BOOKING_FORM_ERRORS');\n\n axios.delete(`/v1/bookings/${data.b_id}/commission/${data.partner_uuid}`, data)\n .then(response => {\n commit('SET_CURRENT_WORKING_BOOKING', get(response, 'data.booking'));\n EventBus.$emit('attache-partner-commission-success');\n }).catch(error => {\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n }).finally(() => {\n commit('SET_BOOKING_LOADING', {subject: 'attachCommissionPartner', loading: false});\n });\n },\n\n cancelBooking({commit, state}, data: CancelBookingPayload) {\n commit('SET_BOOKING_LOADING', {subject: 'cancelBooking', loading: true});\n commit('CLEAR_BOOKING_FORM_ERRORS');\n\n axios.post(`/v1/bookings/${data.b_id}/cancel`, data)\n .then(response => {\n if (get(response, 'data.success')) {\n push.success({\n message: 'Booking canceled successfully',\n });\n if (get(response, 'data.booking')) {\n commit('SET_CURRENT_WORKING_BOOKING', get(response, 'data.booking'));\n }\n } else {\n state.bookingForm.errors.set(['There was an error']);\n }\n }).catch(error => {\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n }).finally(() => {\n commit('SET_BOOKING_LOADING', {subject: 'cancelBooking', loading: false});\n });\n },\n\n\n requestCancelBooking({commit}, data) {\n commit('SET_BOOKING_LOADING', {subject: 'cancelBooking', loading: true});\n\n axios.post('/v1/request-cancellation', data)\n .then(response => {\n EventBus.$emit('booking-guest-canceled-success', get(response, 'data.booking'));\n }).catch(error => {\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n }).finally(() => {\n commit('SET_BOOKING_LOADING', {subject: 'cancelBooking', loading: false});\n });\n },\n\n addOrderItem({commit}, line) {\n commit('SET_BOOKING_LOADING', {subject: 'addOrderItem', loading: true});\n commit('CLEAR_BOOKING_FORM_ERRORS');\n\n axios.post(`/v1/company/${StorageService.getCompanyUuid()}/bookings/${line.b_id}/lines/`, {line}).then(response => {\n if (get(response, 'data.success')) {\n commit('MERGE_BOOKING_LINE_ITEM', get(response, 'data.line'), {});\n EventBus.$emit('add-order-item-success');\n }\n }).catch(error => {\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n }).finally(() => {\n commit('SET_BOOKING_LOADING', {subject: 'addOrderItem', loading: false});\n });\n },\n editOrderItem({commit}, line: OrderLine) {\n commit('SET_BOOKING_LOADING', {subject: 'editOrderItems', loading: true});\n\n axios.put(`/v1/company/${StorageService.getCompanyUuid()}/lines/${line.uuid}`, line).then(response => {\n if (get(response, 'data.success')) {\n commit('UPDATE_BOOKING_LINE_ITEM', get(response, 'data.line'), {});\n }\n }).catch(error => {\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n }).finally(() => {\n commit('SET_BOOKING_LOADING', {subject: 'editOrderItems', loading: false});\n });\n },\n deleteOrderLineItem({commit}, line: string) {\n commit('SET_BOOKING_LOADING', {subject: 'bookingPayments', loading: true});\n commit('CLEAR_BOOKING_FORM_ERRORS');\n\n axios.delete(`/v1/company/${StorageService.getCompanyUuid()}/lines/${line}`).then(response => {\n if (get(response, 'data.success')) {\n EventBus.$emit('delete-order-item-success');\n commit('REMOVE_BOOKING_LINE_ITEM', line);\n }\n }).catch(error => {\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n }).finally(() => {\n commit('SET_BOOKING_LOADING', {subject: 'bookingPayments', loading: false});\n });\n },\n\n fetchBookingPayments({commit}, b_id: string) {\n commit('SET_BOOKING_LOADING', {subject: 'bookingPayments', loading: true});\n commit('CLEAR_BOOKING_FORM_ERRORS');\n\n axios.get('/v1/payments', {params: {b_id}})\n .then(response => {\n commit('SET_BOOKING_PAYMENTS', get(response, 'data.payments'), []);\n }).catch(error => {\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n }).finally(() => {\n commit('SET_BOOKING_LOADING', {subject: 'bookingPayments', loading: false});\n });\n },\n\n changeBookingStatus({commit}, data) {\n commit('SET_BOOKING_LOADING', {subject: 'bookingStatus', loading: true});\n commit('CLEAR_BOOKING_FORM_ERRORS');\n\n axios.put(`/v1/bookings/${data.b_id}/status`, data)\n .then(response => {\n commit('SET_CURRENT_WORKING_BOOKING_STATUS', get(response, 'data.booking.status'));\n EventBus.$emit('change-booking-status-success', get(response, 'data.booking'));\n push.success({\n message: 'Booking status updated successfully',\n });\n }).catch(error => {\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n }).finally(() => {\n commit('SET_BOOKING_LOADING', {subject: 'bookingStatus', loading: false});\n });\n },\n\n /**\n * Update a bookings' mile allowance\n *\n * @param commit\n * @param state\n * @param {Object} data\n */\n updateBookingMileAllowance({commit, state}, data) {\n commit('SET_BOOKING_LOADING', {subject: 'updateBooking', loading: true});\n commit('CLEAR_BOOKING_FORM_ERRORS');\n\n axios.put(`/v1/bookings/${data.b_id}/mile-allowance`, data).then(response => {\n commit('SET_CURRENT_WORKING_BOOKING', get(response, 'data.booking'), []);\n EventBus.$emit('update-booking-mile-allowance-success', get(response, 'data.booking'));\n push.success({\n message: 'Booking distance allowance updated successfully',\n });\n }).catch(error => {\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n state.bookingForm.errors.set(error?.response?.data?.errors || []);\n }).finally(() => {\n commit('SET_BOOKING_LOADING', {subject: 'updateBooking', loading: false});\n });\n },\n\n /**\n * Delete a trip photo from a reservation\n *\n * @param commit\n * @param {String} uuid\n */\n deleteTripPhoto({commit}, uuid: string) {\n commit('SET_BOOKING_LOADING', {subject: 'updateBooking', loading: true});\n\n axios.delete(`/v1/trip-photo/${uuid}`)\n .then(() => {\n EventBus.$emit('delete-trip-photo-success');\n }).catch(() => {\n }).finally(() => {\n commit('SET_BOOKING_LOADING', {subject: 'updateBooking', loading: false});\n });\n },\n\n deleteTripPhotos({commit}, uuids: string[]) {\n commit('SET_BOOKING_LOADING', {subject: 'deleteTripPhotos', loading: true});\n\n axios.post('/v1/trip-photos-delete', uuids)\n .then(() => {\n EventBus.$emit('delete-trip-photos-success');\n }).catch(() => {\n }).finally(() => {\n commit('SET_BOOKING_LOADING', {subject: 'deleteTripPhotos', loading: false});\n });\n },\n\n /**\n * Update a trip photo from a reservation\n *\n * @param commit\n * @param {Object} file - The File\n * @param {string} file.uuid - The UUID of the file\n */\n updateTripPhoto({commit}, file) {\n commit('SET_BOOKING_LOADING', {subject: 'updateTripPhoto', loading: true});\n\n axios.put(`/v1/trip-photo/${file.uuid}`, file)\n .then(response => {\n EventBus.$emit('update-trip-photo-success', get(response, 'data.photo'));\n }).catch(() => {\n }).finally(() => {\n commit('SET_BOOKING_LOADING', {subject: 'updateTripPhoto', loading: false});\n });\n },\n\n async startBookingVehicleSwap({commit}, data: BookingVehicleSwapData) {\n commit('CLEAR_BOOKING_FORM_ERRORS');\n\n try {\n const responseData = await performApiRequest(commit, 'SET_BOOKING_LOADING', 'startBookingVehicleSwap', () => axios.post(`/v1/bookings/${data.b_id}/vehicle-swap`, data));\n EventBus.$emit('vehicle-swap-success-step-1');\n commit('SET_CURRENT_WORKING_BOOKING', responseData.booking);\n } catch (error) {\n commit('SET_BOOKING_FORM_ERROR', error.response?.data?.message || 'There was an error');\n console.error(error)\n }\n },\n\n startBookingVehicleSwapStep2({commit, state}, data) {\n commit('SET_BOOKING_LOADING', {subject: 'startBookingVehicleSwapStep2', loading: true});\n commit('CLEAR_BOOKING_FORM_ERRORS');\n\n axios.post(`/v1/bookings/${data.booking.b_id}/vehicle-swap-step-2`, data).then(response => {\n EventBus.$emit('vehicle-swap-success-step-2');\n commit(types.SET_CURRENT_WORKING_BOOKING, response?.data?.booking);\n }).catch(e => {\n state.bookingForm.errors.set(get(e, 'response.data.errors', []));\n }).finally(() => {\n commit('SET_BOOKING_LOADING', {subject: 'startBookingVehicleSwapStep2', loading: false});\n });\n },\n\n resendConfirmationEmail({commit}, b_id: string) {\n commit('SET_BOOKING_LOADING', {subject: 'updateTripPhoto', loading: true});\n\n axios.post(`/v1/bookings/${b_id}/resend-confirmation-email`)\n .then(() => {\n push.success({\n message: 'Booking confirmation email resent.',\n });\n }).catch(e => {\n let message = get(e, 'response.data.message', 'There was an error');\n\n if (get(e, 'response.headers.retry-after')) {\n message = `${message}. Retry in ${get(e, 'response.headers.retry-after')} seconds`;\n }\n\n push.error({\n message: message,\n });\n }).finally(() => {\n commit('SET_BOOKING_LOADING', {subject: 'updateTripPhoto', loading: false});\n });\n },\n\n /**\n * Toggle a Turo connections active state.\n *\n * @param commit\n * @param {String} b_id\n */\n fetchBookingAutomationEvents({commit}, b_id: string) {\n commit('SET_BOOKING_LOADING', {subject: 'getAutomationEvents', loading: true});\n\n axios.get(`/v1/bookings/${b_id}/automation-events`)\n .then(response => {\n commit('SET_BOOKING_AUTOMATION_EVENTS', get(response, 'data.events', []));\n }).catch(() => {\n }).finally(() => {\n commit('SET_BOOKING_LOADING', {subject: 'getAutomationEvents', loading: false});\n });\n },\n\n /**\n * Mark a booking as manually removed\n *\n * @param commit\n * @param {String} b_id\n */\n removeProviderBookingFromFleetwire({commit}, b_id: string) {\n commit('SET_BOOKING_LOADING', {subject: 'manuallyRemoveBooking', loading: true});\n\n axios.delete(`/v1/bookings/${b_id}/manual-delete`)\n .then(() => {\n EventBus.$emit('mark-booking-as-removed-manually-success');\n }).catch(() => {\n }).finally(() => {\n commit('SET_BOOKING_LOADING', {subject: 'manuallyRemoveBooking', loading: false});\n });\n },\n};\n\nexport default {\n namespaced: true,\n state,\n getters,\n actions,\n mutations,\n};\n","import axios from 'axios';\nimport {EventBus} from '@/plugins/eventBus';\nimport * as types from '../mutation-types';\nimport {Connection, StoreLoaders} from '@/types';\nimport {performApiRequest} from '@/store/helpers/vuex-helpers';\n\n\nexport interface BouncieState {\n init: boolean;\n loading: StoreLoaders;\n credentials: {\n email: string;\n password: string;\n };\n connections: Connection[];\n vehicles: any[];\n\n}\n\nconst state: BouncieState = {\n init: false,\n\n loading: {\n login: false,\n toggle: false,\n delete: false,\n vehicleState: false,\n deleteConnection: false,\n },\n\n credentials: {\n email: '',\n password: '',\n },\n\n connections: [],\n vehicles: [],\n};\n\nconst getters = {\n init: (state: BouncieState) => state.init,\n loading: (state: BouncieState) => state.loading,\n credentials: (state: BouncieState) => state.credentials,\n connections: (state: BouncieState) => state.connections,\n vehicles: (state: BouncieState) => state.vehicles,\n};\n\nconst mutations = {\n [types.SET_BOUNCIE_INIT](state: BouncieState, init: boolean) {\n state.init = init;\n },\n [types.SET_BOUNCIE_LOADING](state: BouncieState, loading: { subject: string, loading: boolean }) {\n state.loading[loading.subject] = loading.loading;\n },\n [types.SET_BOUNCIE_CONNECTIONS](state: BouncieState, connections: Connection[]) {\n state.connections = connections;\n },\n};\n\nconst actions = {\n\n\n /**\n * Fetch Bouncie vehicles\n */\n async fetchVehicles({commit}, bouncie: Connection) {\n try {\n const responseData = await performApiRequest(commit, 'SET_BOUNCIE_LOADING', 'vehicles', () => axios.get(`/v1/connections/bouncie/${bouncie.uuid}/vehicles`));\n\n EventBus.$emit('fetch-bouncie-vehicles-success', responseData);\n commit('SET_BOUNCIE_CONNECTIONS', [responseData.bouncie]);\n } catch (error) {\n console.error(error);\n }\n },\n\n\n /**\n * Get Bouncie vehicles\n */\n async getVehicles({commit}, bouncie: Connection) {\n try {\n await performApiRequest(commit, 'SET_BOUNCIE_LOADING', 'vehicles', () => axios.get(`/v1/connections/bouncie/${bouncie.uuid}/vehicles`));\n } catch (error) {\n console.error(error);\n }\n },\n\n\n /**\n * Fetch Bouncie vehicle state\n */\n async getVehicleState({commit}, vehicle) {\n try {\n const responseData = await performApiRequest(commit, 'SET_BOUNCIE_LOADING', 'vehicleState', () => axios.get(`/v1/connections/bouncie/${vehicle.bouncie_uuid}/vehicles/${vehicle.uuid}`));\n\n EventBus.$emit('bouncie-vehicle-ping-success', responseData.state);\n } catch (error) {\n console.error(error);\n }\n },\n\n async getVehicleTrips({commit}, data) {\n try {\n const responseData = await performApiRequest(commit, 'SET_BOUNCIE_LOADING', 'vehicleState', () => axios.get(`/v1/connections/bouncie/${data.vehicle.bouncie_uuid}/trips/${data.vehicle.uuid}`));\n EventBus.$emit('bouncie-trips-success', responseData.trips);\n } catch (error) {\n console.error(error);\n }\n },\n\n\n /**\n * Toggle Bouncie vehicle active\n */\n async toggleActive({commit}, bouncie: Connection) {\n try {\n const connIndex = state.connections.findIndex((c) => bouncie.uuid === c.uuid);\n\n state.connections[connIndex].loading = true;\n\n const responseData = await performApiRequest(commit, 'SET_BOUNCIE_LOADING', 'vehicleState', () => axios.put(`/v1/connections/bouncie/${bouncie.uuid}/toggle`));\n state.connections[connIndex].connected = true;\n EventBus.$emit('toggle-bouncie-success');\n commit('SET_BOUNCIE_CONNECTIONS', responseData?.company?.connections?.bouncie || []);\n\n state.connections[connIndex].loading = false;\n } catch (error) {\n console.error(error);\n }\n },\n\n\n /**\n * Delete Bouncie connection\n */\n async deleteConnection({commit}, bouncie: Connection) {\n const responseData = await performApiRequest(commit, 'SET_BOUNCIE_LOADING', 'deleteConnection', () => axios.delete(`/v1/connections/bouncie/${bouncie.uuid}`));\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'Bouncie connection removed successfully',\n });\n commit(types.SET_BOUNCIE_CONNECTIONS, responseData?.company?.connections?.bouncie || []);\n },\n\n};\n\n\nexport default {\n namespaced: true,\n state,\n mutations,\n actions,\n getters,\n};\n","import { EventBus } from '@/plugins/eventBus';\nimport axios from 'axios';\nimport * as types from '@/store/mutation-types';\n\n\nexport interface BraintreeState {\n loading: Record<string, boolean>\n}\n\n// state\nconst state: BraintreeState = {\n loading: {\n analytics: false,\n fetchCart: false,\n },\n};\n\nconst getters = {\n loading: (state: BraintreeState) => state.loading,\n};\n\nconst mutations = {\n [types.SET_BRAINTREE_LOADING](state: BraintreeState, loading: { subject: string, loading: boolean }) {\n state.loading[loading.subject] = loading.loading;\n },\n};\n\nconst actions = {\n\n getBraintreeOauthUrl({ commit }) {\n commit('SET_BRAINTREE_LOADING', {subject: 'analytics', loading: true});\n\n axios.get('/v1/braintree/url')\n .then((response) => {\n EventBus.$emit('braintree-oauth-url-create-success', response.data);\n }).catch((e) => {\n EventBus.$emit('braintree-oauth-url-create-error', e.response);\n }).finally(() => {\n commit('SET_BRAINTREE_LOADING', {subject: 'analytics', loading: false});\n });\n },\n\n saveBraintreeCode({ commit }, data) {\n commit('SET_BRAINTREE_LOADING', {subject: 'analytics', loading: true});\n\n axios.post('/v1/braintree/redirect', data)\n .then((response) => {\n EventBus.$emit('braintree-oauth-url-create-success', response.data);\n }).catch((e) => {\n EventBus.$emit('braintree-oauth-url-create-error', e.response);\n }).finally(() => {\n commit('SET_BRAINTREE_LOADING', {subject: 'analytics', loading: false});\n });\n },\n\n getBraintreeProvider() {\n axios.get('/v1/braintree/')\n .then((response) => {\n EventBus.$emit('braintree-oauth-success', response.data);\n }).catch(() => {\n }).finally(() => {\n });\n },\n testPayment() {\n axios.post('/v1/braintree/testPayment')\n .then((response) => {\n EventBus.$emit('delete-braintree-oauth-success', response.data);\n }).catch(() => {\n }).finally(() => {\n });\n },\n};\n\nexport default {\n namespaced: true,\n state,\n mutations,\n actions,\n getters,\n};\n","import router from \"@/router\";\nimport {RouteLocationNormalizedLoaded} from 'vue-router';\n\nconst PARTNER_UUID: string = 'cp_uuid';\n\nconst CommissionPartnerService = {\n\n /**\n * Saves a partner uuid\n */\n savePartnerUuid(uuid: string): void {\n localStorage.setItem(PARTNER_UUID, uuid);\n },\n\n /**\n * Gets a partner uuid\n */\n getPartnerUuid(): string | null {\n return localStorage.getItem(PARTNER_UUID);\n },\n\n /**\n * Removed a partner uuid (cp) from the URL query.\n */\n removePartnerUuidParam(route: RouteLocationNormalizedLoaded): void {\n const query = {...route.query};\n delete query.cp;\n router.replace({ query });\n },\n\n /**\n * Removes a partner uuid from localstorage\n */\n removePartnerUuid(): void {\n localStorage.removeItem(PARTNER_UUID);\n },\n};\n\nexport { CommissionPartnerService };\n","import axios from 'axios';\nimport * as types from '@/store/mutation-types';\nimport {CommissionPartnerService} from '@/services/commission-partner.service';\nimport {CartService} from '@/services/cart.service';\nimport {performApiRequest} from \"@/store/helpers/vuex-helpers\";\nimport {Cart} from \"@/types\";\nimport dayjs from \"dayjs\";\n\n\nexport interface CartState {\n loading: Record<string, boolean>;\n cart: Cart;\n}\n\n// state\nconst state: CartState = {\n loading: {\n cart: false,\n fetchCart: false,\n },\n cart: {\n loaded: false,\n uuid: CartService.getCartUuid(),\n l_id: null,\n trip_start: null,\n trip_end: null,\n b_id: null,\n checkout_url: null,\n commission_partner_id: null,\n company_uuid: '',\n complete: 0,\n coupon_discount: null,\n coupon_id: null,\n created_at: '',\n deposit: null,\n grand_total: null,\n price: null,\n tax: null,\n total_due: null,\n updated_at: '',\n website_url: null,\n },\n};\n\nconst getters = {\n loading: (state: CartState) => state.loading,\n cart: (state: CartState) => state.cart,\n};\n\nconst mutations = {\n [types.SET_CART_LOADING](state: CartState, loading: { subject: string, loading: boolean }) {\n state.loading[loading.subject] = loading.loading;\n },\n [types.SET_CART_L_ID](state: CartState, l_id: string) {\n state.cart.l_id = l_id;\n },\n [types.SET_CART](state: CartState, cart: Cart) {\n console.dir('SET_CART', cart);\n CartService.saveCartUuid(cart.uuid);\n state.cart = cart;\n state.cart.loaded = true;\n },\n};\n\nconst actions = {\n\n /**\n * Create a cart\n */\n async createCart({commit}, payload: any = {}) {\n const params = new URLSearchParams();\n if (import.meta.env.MODE !== 'production' && !payload?.company) {\n // params.append('company_slug', 'frunkyea-tesla-rentals');\n }\n const partnerUuid = CommissionPartnerService.getPartnerUuid();\n if (partnerUuid) {\n payload.cp = partnerUuid;\n }\n\n // if params is missing company_slug, add it\n if (!params.has('company_slug')) {\n console.dir('HERE %%66663333');\n\n // get hostname subdomain\n const hostname = window.location.hostname;\n\n // if hostname has fleetwire.io in it then use the subdomain\n if (hostname.includes('fleetwire.io')) {\n const subdomain = window.location.hostname.split('.')[0];\n console.dir(subdomain);\n params.append('company_slug', subdomain);\n } else {\n // if hostname is not fleetwire.io then use the full hostname\n params.append('company_custom_domain', window.location.hostname);\n }\n }\n\n try {\n const responseData = await performApiRequest(commit, 'SET_CART_LOADING', 'createCart', () => axios.post(`/v1/carts${params.toString() ? `?${params}` : ''}`, payload));\n commit('SET_CART', responseData.cart);\n\n return responseData;\n } catch (e) {\n }\n },\n\n\n /**\n * Fetch a cart\n */\n async fetchCart({commit}, cartId: string) {\n try {\n const responseData = await performApiRequest(commit, 'SET_CART_LOADING', 'fetchCart', () => axios.get(`/v1/carts/${cartId}`));\n commit(types.SET_CART, responseData.cart);\n return responseData.cart;\n } catch (e) {\n if (e?.response?.status === 404) {\n CartService.removeCartUuid();\n window.location.reload();\n }\n }\n },\n\n /**\n * Update a cart\n */\n async updateCart({state, commit}) {\n const cartId = state.cart?.uuid;\n\n if (typeof cartId === 'string') {\n try {\n const responseData = await performApiRequest(commit, 'SET_CART_LOADING', 'updateCart', () => axios.put(`/v1/carts/${cartId}`, state.cart));\n commit('SET_CART', responseData.cart);\n } catch (e) {\n if (e.response.status === 404) {\n CartService.removeCartUuid();\n window.location.reload();\n }\n }\n }\n },\n\n\n /**\n * Set a carts period\n */\n async setPeriod({state, commit}, dates: { start: string, end: string }) {\n const cartId = state.cart?.uuid;\n\n console.dir('setPeriod');\n console.dir(cartId);\n console.dir(dates);\n\n if (typeof cartId === 'string') {\n const start = dayjs(dates.start).format('YYYY-MM-DD HH:mm:00');\n const end = dayjs(dates.end).format('YYYY-MM-DD HH:mm:00');\n\n try {\n const responseData = await performApiRequest(commit, 'SET_CART_LOADING', 'setPeriod', () => axios.post(`/v1/carts/${cartId}/set-period`, {\n start,\n end\n }));\n commit(types.SET_CART, responseData.cart);\n\n return responseData.cart;\n } catch (e) {\n if (e.response.status === 404) {\n CartService.removeCartUuid();\n window.location.reload();\n }\n throw e;\n }\n }\n },\n\n /**\n * Report a cart change\n */\n async report({commit}, data = {}) {\n try {\n await performApiRequest(commit, 'SET_CART_LOADING', 'report', () => axios.post('/v1/report', data));\n } catch (e) {\n }\n },\n};\n\nexport default {\n namespaced: true,\n state,\n mutations,\n actions,\n getters,\n};\n","import {get, isNull, map, set} from 'lodash';\nimport axios from 'axios';\nimport * as types from '@/store/mutation-types';\nimport {EventBus} from '@/plugins/eventBus';\nimport {Form} from '@/plugins/FWForms/index';\nimport {CartService} from '@/services/cart.service';\nimport {performApiRequest} from '@/store/helpers/vuex-helpers';\nimport getDefaultMeta from '@/utils/meta';\n\nexport interface CheckoutState {\n loading: Record<string, boolean>;\n cart: any;\n stripe: any;\n checkoutForm: Form<any>;\n _orderRequest: any;\n initialized: boolean;\n availability: any;\n coupon: any;\n checkoutRenterAuthenticatedData: object;\n}\n\nexport interface ListingsAvailabilityPayload {\n dates: {\n start: string,\n end: string,\n },\n l_id?: string,\n ignoreUnavailable?: boolean,\n}\n\n// state\nconst state: CheckoutState = {\n loading: {\n checkout: false,\n checkAvailability: false,\n paymentIntent: false,\n checkDrivingDistance: false,\n },\n cart: {\n uuid: CartService.getCartUuid(),\n l_id: null,\n trip_start: null,\n trip_end: null,\n },\n\n stripe: null,\n\n checkoutForm: new Form(),\n checkoutRenterAuthenticatedData: null,\n _orderRequest: {\n l_id: '',\n dates: {\n start: null,\n end: null,\n },\n costs: {\n vehicle: 0,\n extras: 0,\n requiredExtras: 0,\n delivery: 0,\n taxes: 0,\n discount: 0,\n subtotal: 0,\n grandTotal: 0,\n dueToday: 0,\n securityDepositCredit: 0,\n securityDepositDebit: 0,\n },\n discounts: {\n discounted: false,\n amount: 0,\n value: 0,\n code: null,\n reason: null,\n type: null,\n durationDiscountReason: null,\n durationDiscountAmount: null,\n durationDiscountValue: null,\n },\n duration: {\n minutes: 0,\n hours: 0,\n days: 0,\n weeks: 0,\n months: 0,\n years: 0,\n units: 1,\n },\n customers: [\n {\n isPrimary: true,\n firstName: '',\n lastName: '',\n phone: '',\n email: '',\n dob: '',\n age: '',\n signaturePng: '',\n signFullName: '',\n signInitials: '',\n agreeAdoptSignature: false,\n agreeToS: false,\n },\n ],\n extras: [],\n extrasV2: [],\n requiredExtras: [],\n requiredExtrasV2: [],\n delivery: {},\n delivery_address: null,\n customFields: [],\n cartId: CartService.getCartUuid(),\n },\n\n\n initialized: false,\n availability: {\n available: true,\n booking: '',\n endDate: '',\n endTime: '',\n message: '',\n nextAvailableEndTime: '',\n nextAvailableStartTime: '',\n part: '',\n startDate: '',\n startTime: '',\n },\n coupon: {\n code: '',\n amount: 0,\n reason: '',\n type: '',\n value: 0,\n },\n};\n\nconst getters = {\n loading: (state: CheckoutState) => state.loading,\n coupon: (state: CheckoutState) => state.coupon,\n availability: (state: CheckoutState) => state.availability,\n checkoutForm: (state: CheckoutState) => state.checkoutForm,\n checkoutRenterAuthenticatedData: (state: CheckoutState) => state.checkoutRenterAuthenticatedData,\n checkoutInitialized: (state: CheckoutState) => state.initialized,\n _orderRequest: (state: CheckoutState) => state._orderRequest,\n};\n\nconst mutations = {\n [types.SET_CHECKOUT_LOADING](state: CheckoutState, loading: { subject: string, loading: boolean }) {\n state.loading[loading.subject] = loading.loading;\n },\n [types.CLEAR_CHECKOUT_FORM_ERRORS](state: CheckoutState, form_field: string | null | undefined) {\n if (form_field === null || form_field === undefined) {\n state.checkoutForm.errors.clear();\n } else {\n state.checkoutForm.errors.clear(form_field);\n }\n },\n [types.SET_CHECKOUT_DISCOUNT](state: CheckoutState, coupon) {\n state.coupon = coupon;\n\n // state.order.discounts = {\n // discounted: true,\n // code: get(coupon, 'code'),\n // amount: get(coupon, 'amount'),\n // reason: get(coupon, 'reason'),\n // type: get(coupon, 'type'),\n // durationDiscountReason: null,\n // durationDiscountAmount: null,\n // durationDiscountValue: null,\n // };\n state._orderRequest.discounts = {\n discounted: true,\n code: get(coupon, 'code'),\n amount: get(coupon, 'amount'),\n reason: get(coupon, 'reason'),\n type: get(coupon, 'type'),\n durationDiscountReason: null,\n durationDiscountAmount: null,\n durationDiscountValue: null,\n };\n },\n [types.RESET_CHECKOUT_DISCOUNT](state: CheckoutState) {\n state.checkoutForm.errors.clear('coupon');\n state._orderRequest.discounts = {\n discounted: false,\n code: '',\n amount: 0,\n reason: '',\n type: '',\n value: 0,\n durationDiscountReason: null,\n durationDiscountAmount: null,\n durationDiscountValue: null,\n };\n },\n [types.SET_ORDER_DELIVERY](state: CheckoutState, location) {\n state._orderRequest.delivery = location;\n },\n [types.SET_CHECKOUT_INITIALIZED](state: CheckoutState, initialized: boolean) {\n console.dir('SET_CHECKOUT_INITIALIZED');\n state.initialized = initialized;\n },\n [types.SET_CHECKOUT_STRIPE](state: CheckoutState, stripe) {\n state.stripe = stripe;\n },\n [types.SET_CHECKOUT_AVAILABILITY](state: CheckoutState, availability) {\n state.availability = availability;\n },\n [types.SET_RESERVATION_REQUEST_LISTING_ID](state: CheckoutState, l_id) {\n console.dir('SET_RESERVATION_REQUEST_LISTING_ID');\n state._orderRequest.l_id = l_id;\n },\n [types.SET_RESERVATION_REQUEST_DATES](state: CheckoutState, dates) {\n console.log('%c SET_RESERVATION_REQUEST_DATES', 'color: blue;background: yellow; padding: 2px');\n\n console.dir(dates);\n set(state._orderRequest, 'dates', dates);\n },\n [types.SET_RESERVATION_REQUEST_DURATIONS](state: CheckoutState, duration) {\n state._orderRequest.duration = duration;\n },\n [types.SET_RESERVATION_REQUEST_EXTRAS](state: CheckoutState, extras) {\n state._orderRequest.extras = extras;\n },\n [types.SET_RESERVATION_REQUEST_EXTRAS_V2](state: CheckoutState, extras) {\n console.dir('SET_RESERVATION_REQUEST_EXTRAS_V2');\n state._orderRequest.extrasV2 = extras;\n },\n [types.SET_RESERVATION_REQUEST_REQUIRED_EXTRAS_V2](state: CheckoutState, extras) {\n state._orderRequest.requiredExtrasV2 = extras;\n },\n [types.SET_RESERVATION_REQUEST_REQUIRED_EXTRAS_V2_AT_INDEX](state: CheckoutState, data) {\n set(state._orderRequest.requiredExtrasV2, data.index, data.extra);\n },\n /**\n * Set the pricing data for the reservation request\n */\n [types.SET_RESERVATION_REQUEST_PRICING](state: CheckoutState, data) {\n const dataKeys = Object.keys(data);\n const costKeys = Object.keys(state._orderRequest.costs);\n\n dataKeys.forEach((key) => {\n if (costKeys.includes(key)) {\n state._orderRequest.costs[key] = data[key];\n }\n });\n },\n [types.SET_CHECKOUT_ORDER_DATES](state: CheckoutState, dates) {\n state._orderRequest.dates = dates;\n },\n [types.SET_CHECKOUT_ORDER_CUSTOMER](state: CheckoutState, customers) {\n set(state._orderRequest, 'customers', customers);\n\n },\n [types.SET_CHECKOUT_ORDER_CUSTOMER_BY_INDEX](state: CheckoutState, data) {\n set(state._orderRequest.customers, data.index, data.customer);\n },\n [types.SET_CHECKOUT_ORDER_CUSTOMER_AGREE_TOS](state: CheckoutState, data) {\n state._orderRequest.customers[data.index].agreeToS = data.agreeToS;\n },\n [types.SET_CHECKOUT_ORDER_CUSTOM_FIELDS](state: CheckoutState, fields) {\n state._orderRequest.customFields = fields;\n },\n [types.SET_CHECKOUT_ORDER_DELIVERY_ADDRESS](state: CheckoutState, address) {\n state._orderRequest.delivery_address = address;\n },\n [types.SET_CHECKOUT_RENTER_AUTHENTICATED](state: CheckoutState, data) {\n console.dir('SET_CHECKOUT_RENTER_AUTHENTICATED');\n console.dir(data);\n state.checkoutRenterAuthenticatedData = data;\n },\n [types.SET_CHECKOUT_ORDER_REQUIRED_EXTRAS](state: CheckoutState, data) {\n if (data.requiredExtras) {\n state._orderRequest.requiredExtras = map(data.requiredExtras, e => e.extras[0]);\n }\n\n if (data.requiredExtrasV2) {\n state._orderRequest.requiredExtrasV2 = map(data.requiredExtrasV2, e => {\n const parentUuid = e.uuid;\n return {\n parentUuid,\n choice: e.options[0],\n };\n });\n }\n },\n};\n\nconst actions = {\n\n checkout({state, commit, rootGetters}) {\n commit('SET_CHECKOUT_LOADING', {subject: 'checkout', loading: true});\n const paymentStrategy = getDefaultMeta('settings.payment.strategy');\n const paymentProvider = get(rootGetters['company/company'], 'payment_profile.provider');\n const usesStripe = paymentProvider === 'stripe';\n const usesSquare = paymentProvider === 'square';\n const hasBalance = get(state._orderRequest, 'costs.grandTotal', 0) <= 0;\n\n state.checkoutForm.startProcessing();\n\n axios.post('/v1/checkout', state._orderRequest)\n .then((response) => {\n if (usesSquare) {\n window.location.href = get(response, 'data.redirect');\n }\n\n if ((!usesSquare && !usesStripe) || isNull(paymentStrategy) || hasBalance) {\n EventBus.$emit('checkout-successful', response.data);\n } else if (get(response, 'data.redirect')) {\n window.location.href = get(response, 'data.redirect');\n } else {\n const sessionId = get(response, 'data.StripeSession.id');\n const customer = get(response, 'data.customer');\n const stripePaymentMethod = 'payment_intent';\n commit('booking/SET_REMEMBER_CUSTOMER', {\n email: get(customer, 'email'),\n stripe_id: get(customer, 'stripe_id'),\n }, {root: true});\n\n\n if (stripePaymentMethod === 'payment_intent') {\n EventBus.$emit('set-booking-id', get(response, 'data.b_id'));\n EventBus.$emit('set-listing-id', get(response, 'data.l_id'));\n EventBus.$emit('open-checkout-payment-dialog', get(response, 'data.StripePaymentIntent'));\n } else {\n state.stripe.redirectToCheckout({\n sessionId,\n }).then(() => {\n // If `redirectToCheckout` fails due to a browser or network\n // error, display the localized error message to your customer\n // using `result.error.message`.\n });\n }\n }\n state.checkoutForm.finishProcessing(true);\n })\n .catch((e) => {\n console.dir(e);\n state.checkoutForm.errors.set(get(e.response, 'data.errors', []));\n\n if (get(e.response, 'data.errors')) {\n EventBus.$emit('checkout-message', {\n type: 'error',\n message: 'There was an error',\n });\n } else {\n EventBus.$emit('checkout-message', {\n type: 'error',\n message: 'There was an error - not available',\n });\n }\n state.checkoutForm.finishProcessing(false);\n }).finally(() => {\n commit('SET_CHECKOUT_LOADING', {subject: 'checkout', loading: false});\n });\n },\n\n /**\n * Start an otp authentication\n */\n async renterAuthenticationStart({commit}, data: { email: string }) {\n try {\n const responseData = await performApiRequest(commit, 'SET_CHECKOUT_LOADING', 'checkAvailability', () => axios.post('/v1/checkout/renter-authentication/start', data));\n EventBus.$emit('renter-authenticated-start-success', responseData);\n\n EventBus.$emit('open-renter-otp-auth', {\n focusId: 'renter-email-input',\n email: responseData.email,\n phone_number: responseData.phone_number,\n });\n } catch (error) {\n }\n },\n\n /**\n * Complete an otp authentication\n */\n async renterAuthenticationComplete({commit}, data) {\n try {\n const responseData = await performApiRequest(commit, 'SET_CHECKOUT_LOADING', 'checkAvailability', () => axios.post('/v1/checkout/renter-authentication/complete', data));\n commit(types.SET_CHECKOUT_RENTER_AUTHENTICATED, responseData.renter);\n // EventBus.$emit('renter-authenticated-complete-success', responseData);\n } catch (error) {\n EventBus.$emit('renter-authenticated-complete-failed');\n }\n },\n\n\n /**\n * Verify Stripe Payment with Intent\n */\n verifyPayment({commit, rootGetters}, paymentIntentId) {\n commit('SET_CHECKOUT_LOADING', {subject: 'checkAvailability', loading: true});\n axios.get(`/v1/company/${rootGetters['company/company'].uuid}/verify-payment-intent/${paymentIntentId}`)\n .then(() => {\n EventBus.$emit('payment-intent-verified');\n }).catch(() => {\n }).finally(() => {\n commit('SET_CHECKOUT_LOADING', {subject: 'checkAvailability', loading: false});\n });\n },\n\n\n /**\n * Check the available listings for a company\n */\n async checkListingsAvailability({commit, rootGetters}, data: ListingsAvailabilityPayload) {\n const params = new URLSearchParams({\n start: data.dates.start,\n end: data.dates.end,\n });\n\n if (data.l_id) params.append('l_id', data.l_id);\n if (data.ignoreUnavailable) params.append('ignoreUnavailable', 'true');\n\n\n try {\n console.log(params.toString());\n const companyUuid = rootGetters['company/company']?.uuid;\n\n const url = `/v1/company/${companyUuid}/listings/availability?${params.toString()}`;\n\n const responseData = await performApiRequest(\n commit,\n 'SET_CHECKOUT_LOADING',\n 'checkAvailability',\n () => axios.get(url)\n );\n\n commit('listing/SET_ALL_LISTINGS', responseData?.listings ?? [], {root: true});\n } catch (error) {\n console.error('Error fetching listings availability:', error);\n }\n },\n\n checkOneListingsAvailability({commit, state, rootGetters}, {l_id, dates}) {\n commit('SET_CHECKOUT_LOADING', {subject: 'checkAvailability', loading: true});\n\n axios.get(`/v1/company/${rootGetters['company/company'].uuid}/listings/${l_id}/availability?start=${dates.start}&end=${dates.end}`)\n .then((response) => {\n commit('listing/SET_ALL_LISTINGS', get(response.data, 'listings', []), {root: true});\n }).catch(() => {\n }).finally(() => {\n commit('SET_CHECKOUT_LOADING', {subject: 'checkAvailability', loading: false});\n });\n },\n};\n\nexport default {\n namespaced: true,\n state,\n mutations,\n actions,\n getters,\n};\n","import {EventBus} from '@/plugins/eventBus';\nimport axios from 'axios';\nimport * as types from '@/store/mutation-types';\nimport {Form} from '@/plugins/FWForms';\nimport {RootState} from '@/types/RootState';\nimport {Module} from 'vuex';\nimport {performApiRequest} from '@/store/helpers/vuex-helpers';\nimport {push} from 'notivue';\n\nexport interface CommissionPartnersState {\n loading: Record<string, boolean>;\n couponForm: Form<object>;\n commissionPartners: CommissionPartner[];\n commissionPartner?: CommissionPartner;\n commissions: any[];\n}\n\nexport interface CommissionPartner {\n active: boolean;\n checkoutLink?: string;\n commission_amount: number;\n commission_type: string;\n company?: any;\n created_at?: string;\n email: string;\n name: string;\n notes?: string;\n phone: string;\n updated_at?: string;\n uuid?: string;\n mode?: 'create' | 'edit';\n}\n\n// state\nconst state: CommissionPartnersState = {\n loading: {\n get: false,\n create: false,\n update: false,\n delete: false,\n toggle: false,\n commissions: false,\n },\n couponForm: new Form(),\n commissionPartners: [],\n commissionPartner: null,\n commissions: [],\n};\n\nconst mutations = {\n [types.SET_COMMISSION_PARTNER_LOADING](state: CommissionPartnersState, loading: {\n subject: string,\n loading: boolean\n }) {\n state.loading[loading.subject] = loading.loading;\n },\n [types.SET_COMMISSION_PARTNERS](state: CommissionPartnersState, partners: CommissionPartner[]) {\n state.commissionPartners = partners;\n },\n [types.SET_COMMISSION_PARTNER](state: CommissionPartnersState, partner: CommissionPartner) {\n state.commissionPartner = partner;\n },\n [types.SET_COMMISSIONS](state: CommissionPartnersState, commissions) {\n state.commissions = commissions;\n },\n\n [types.CLEAR_COMMISSION_PARTNER_COUPON_FORM_ERRORS](state: CommissionPartnersState) {\n state.couponForm.errors.clear();\n },\n};\n\nconst actions = {\n\n /**\n * Get commission partners\n */\n getCommissionPartners({commit}) {\n commit('SET_COMMISSION_PARTNER_LOADING', {subject: 'get', loading: true});\n\n commit(types.CLEAR_COMMISSION_PARTNER_COUPON_FORM_ERRORS);\n\n axios.get('/v1/commission-partners')\n .then((response) => {\n EventBus.$emit('get-commission-partners-success', response.data.partners);\n commit(types.SET_COMMISSION_PARTNERS, response.data.partners);\n }).catch(() => {\n }).finally(() => {\n commit('SET_COMMISSION_PARTNER_LOADING', {subject: 'get', loading: false});\n });\n },\n\n\n /**\n * Get a single commission partner\n */\n getCommissionPartner({commit}, partner_uuid: string) {\n commit('SET_COMMISSION_PARTNER_LOADING', {subject: 'get', loading: true});\n commit('CLEAR_COMMISSION_PARTNER_COUPON_FORM_ERRORS');\n\n axios.get(`/v1/commission-partners/${partner_uuid}`)\n .then((response) => {\n EventBus.$emit('get-commission-partners-success', response.data.partner);\n commit('SET_COMMISSION_PARTNER', response.data.partner);\n }).catch(() => {\n }).finally(() => {\n commit('SET_COMMISSION_PARTNER_LOADING', {subject: 'get', loading: false});\n });\n },\n\n /**\n * Create commission partner\n */\n async createCommissionPartner({commit}, partner: CommissionPartner) {\n try {\n const responseData = await performApiRequest(commit, 'SET_COMMISSION_PARTNER_LOADING', 'create', () => axios.post('/v1/commission-partners', partner));\n EventBus.$emit('create-commission-partner-success', responseData.partner);\n } catch (e) {\n push.error({\n message: e?.response?.data?.message || 'There was an error',\n });\n }\n },\n\n /**\n * Update commission partner\n */\n async updateCommissionPartner({commit}, partner: CommissionPartner) {\n try {\n await performApiRequest(commit, 'SET_COMMISSION_PARTNER_LOADING', 'update', () => axios.put(`/v1/commission-partners/${partner.uuid}`, partner));\n } catch (e) {\n push.error({\n message: e?.response?.data?.message || 'There was an error',\n });\n }\n },\n\n /**\n * Delete commission partner\n */\n async deleteCommissionPartner({commit}, partner: CommissionPartner) {\n try {\n await performApiRequest(commit, 'SET_COMMISSION_PARTNER_LOADING', 'delete', () => axios.delete(`/v1/commission-partners/${partner.uuid}`));\n } catch (e) {\n push.error({\n message: e?.response?.data?.message || 'There was an error',\n });\n }\n },\n\n async toggleShowOnMainMenu({commit}, value: boolean) {\n try {\n await performApiRequest(commit, 'SET_COMMISSION_PARTNER_LOADING', 'toggle', () => axios.post('/v1/commission-partners/main-menu-toggle', {value}));\n } catch (e) {\n push.error({\n message: e?.response?.data?.message || 'There was an error',\n });\n }\n },\n\n /**\n * Get commissions\n */\n getCommissions({commit}) {\n commit('SET_COMMISSION_PARTNER_LOADING', {subject: 'commissions', loading: true});\n\n axios.get('/v1/commissions')\n .then((response) => {\n EventBus.$emit('get-commissions-success');\n commit('SET_COMMISSIONS', response.data.commissions);\n }).catch(() => {\n }).finally(() => {\n commit('SET_COMMISSION_PARTNER_LOADING', {subject: 'commissions', loading: false});\n });\n },\n\n};\n\nconst commissionPartnerModule: Module<CommissionPartnersState, RootState> = {\n namespaced: true,\n state,\n mutations,\n actions,\n getters: {\n loading: state => state.loading,\n commissions: state => state.commissions,\n commissionPartners: state => state.commissionPartners,\n commissionPartner: state => state.commissionPartner,\n },\n};\n\nexport default commissionPartnerModule;\n","import axios from 'axios';\nimport {get} from 'lodash';\nimport dayjs from 'dayjs';\nimport {Form} from '@/plugins/FWForms/index';\nimport {EventBus} from '@/plugins/eventBus';\nimport {StorageService} from '@/services/storage.service';\nimport * as types from '../mutation-types';\nimport {\n BookingInterface,\n CompanyInterface,\n CompanyMeta,\n CompanySettings,\n CompanyState,\n CurrencySettings,\n DefaultMeta,\n DeliveryLocation,\n Employee,\n NotificationPagination,\n OperatingRule,\n PermissionsArray,\n SavingEmployeeNotificationSettings\n} from '@/types';\nimport {RootState} from '@/types/RootState';\nimport {Module} from 'vuex'\nimport {performApiRequest} from '@/store/helpers/vuex-helpers';\nimport {createUrlQueryString} from '@/utils/urls';\nimport {push} from 'notivue'\n\nconst defaultMetaValues: CompanyMeta = {\n cancellation_policy: '',\n rental_tos_id: '',\n};\n\nconst state: CompanyState = {\n loaded: false,\n\n loading: {\n company: false,\n company_meta: false,\n bookings: false,\n listing: true,\n listings: false,\n employee: false,\n invite: false,\n notifications: false,\n deliveryLocation: false,\n getOperatingRules: false,\n createOperatingRule: false,\n deleteOperatingRule: false,\n saveStripeKey: false,\n resetStripeKey: false,\n markAccountForDeletion: false,\n saveCurrency: false,\n listingReset: false,\n addDefaultMeta: false,\n getDefaultMeta: false,\n },\n\n companyForm: new Form(),\n companyMetaForm: new Form(),\n\n originalCompany: {},\n company: {\n active: false,\n address: {\n address_1: '',\n address_2: '',\n city: '',\n state: '',\n postal_code: '',\n },\n bookings: [],\n currency: null,\n delivery_locations: [],\n email: null,\n email_proxy: '',\n found: false,\n init: false,\n listings: [],\n logo: '',\n mark_to_delete_at: null,\n meta: {...defaultMetaValues},\n name: null,\n phone: '',\n phone_fmt: '',\n slug: '',\n timezone: '',\n uuid: '',\n },\n\n employees: [],\n\n employee: {\n init: false,\n found: false,\n uuid: '',\n first_name: '',\n last_name: '',\n full_name: '',\n name: '',\n email: '',\n phone: '',\n photo_url: '',\n permissions: [],\n roles: [],\n notificationSettings: null,\n },\n\n defaultMeta: [],\n\n possiblePermissions: [\n 'listings_manage',\n 'settings_manage',\n 'account_and_billing_manage',\n 'turnover_view',\n 'orders_cancel',\n 'orders_revert',\n ],\n\n registerFormRules: {\n required: (value) => !!value || 'Required',\n min: (v) => v.length >= 8 || 'Min of 8 characters',\n email: [\n (v) => !!v || 'E-mail is required',\n (v) => /.+@.+\\..+/.test(v) || 'E-mail must be a valid e-mail',\n ],\n code: [\n (v) => !!v || '2FA code is required',\n (v) => v.length >= 4 || 'Should be 4 characters',\n ],\n },\n\n notifications: [],\n notificationsTotal: 0,\n nextNotifications: 1,\n notificationsLast: 1,\n operating_rules: [],\n feedback_reviews: [],\n trialOver: false,\n settings: {\n 'settings.store.enabled': true,\n 'settings.store.public': true,\n 'settings.store.test': false,\n } as CompanySettings,\n counts: null,\n};\n\nconst getters = {\n loaded: (state: CompanyState) => state.loaded,\n trialOver: (state: CompanyState) => state.trialOver,\n companyLoading: (state: CompanyState) => state.loading,\n possiblePermissions: (state: CompanyState) => state.possiblePermissions,\n check: (state: CompanyState) => state.company.found,\n company: (state: CompanyState) => state.company,\n settings: (state: CompanyState) => state.settings,\n originalCompany: (state: CompanyState) => state.originalCompany,\n meta: (state: CompanyState) => state.company.meta,\n paymentProfile: (state: CompanyState) => state.company.payment_profile,\n listings: (state: CompanyState) => state.company.listings,\n bookings: (state: CompanyState) => state.company.bookings,\n employees: (state: CompanyState) => state.employees,\n employee: (state: CompanyState) => state.employee,\n registerFormRules: (state: CompanyState) => state.registerFormRules,\n notifications: (state: CompanyState) => state.notifications,\n notificationsTotal: (state: CompanyState) => state.notificationsTotal,\n companySeatCount: (state: CompanyState) => get(state.company, 'employees', []).length,\n companyForm: (state: CompanyState) => state.companyForm,\n companyMetaForm: (state: CompanyState) => state.companyMetaForm,\n operatingRules: (state: CompanyState) => state.operating_rules,\n feedbackReviews: (state: CompanyState) => state.feedback_reviews,\n defaultMeta: (state: CompanyState) => state.defaultMeta,\n notificationsLast: (state: CompanyState) => state.notificationsLast,\n nextNotifications: (state: CompanyState) => state.nextNotifications,\n counts: (state: CompanyState) => state.counts,\n};\n\nconst mutations = {\n [types.SET_COMPANY_LOADING](state: CompanyState, loading: { subject: string, loading: boolean }) {\n state.loading[loading.subject] = loading.loading;\n },\n [types.SET_COMPANY](state: CompanyState, company: CompanyInterface) {\n state.trialOver = company?.trial_ends_at ? dayjs(company.trial_ends_at) < dayjs() : true;\n\n state.company = {\n ...state.company, ...company, found: true, init: true,\n };\n\n if (get(company, 'defaultMeta')) {\n state.defaultMeta = company.defaultMeta;\n }\n\n if (!company.meta) {\n state.company.meta = {\n cancellation_policy: '',\n rental_tos_id: '',\n };\n }\n state.loaded = true;\n\n if (company?.operating_rules) {\n state.operating_rules = company.operating_rules;\n }\n\n state.originalCompany = JSON.parse(JSON.stringify(company));\n\n StorageService.saveCompanyUuid(get(state.company, 'uuid'));\n },\n [types.SET_COMPANY_PHONE](state: CompanyState, phone: string) {\n state.company.phone = phone;\n },\n [types.SET_COMPANY_META](state: CompanyState, meta: CompanyMeta) {\n console.dir('meta', meta);\n state.company.meta = meta;\n },\n [types.SET_COMPANY_SETTINGS](state: CompanyState, settings: CompanySettings) {\n // merge the settings\n state.settings = {...state.settings, ...settings};\n },\n [types.SET_COUNTS](state: CompanyState, counts: Record<string, number>) {\n state.counts = counts;\n },\n [types.SET_COMPANY_CURRENCY](state: CompanyState, currency: CurrencySettings) {\n state.company.currency = currency;\n },\n [types.SET_COMPANY_DEFAULT_META](state: CompanyState, meta: DefaultMeta) {\n state.defaultMeta = meta;\n },\n [types.SET_POSSIBLE_PERMISSIONS](state: CompanyState, permission: Array<string>) {\n state.possiblePermissions = permission;\n },\n [types.SET_COMPANY_BOOKINGS](state: CompanyState, bookings: BookingInterface[]) {\n state.company.bookings = bookings;\n },\n [types.SET_COMPANY_EMPLOYEES](state: CompanyState, employees: Employee[]) {\n state.employees = employees;\n },\n [types.SET_DELIVERY_LOCATIONS](state: CompanyState, locations: DeliveryLocation[]) {\n state.company.delivery_locations = locations;\n },\n [types.RESET_EMPLOYEE](state: CompanyState) {\n state.employee = {\n full_name: '',\n init: false,\n found: false,\n uuid: '',\n first_name: '',\n last_name: '',\n name: '',\n email: '',\n phone: '',\n photo_url: '',\n permissions: [],\n roles: [],\n notificationSettings: null\n };\n },\n [types.SET_COMPANY_NOTIFICATIONS](state: CompanyState, notifications: NotificationPagination) {\n const data = notifications?.data || [];\n const uniqueIds = new Set([...state.notifications, ...data].map(w => w.id));\n state.notifications = Array.from(uniqueIds).map(id =>\n [...state.notifications, ...data].find(w => w.id === id)\n );\n state.nextNotifications = notifications?.current_page ? notifications.current_page + 1 : 1;\n state.notificationsLast = notifications?.last_page || 1;\n state.notificationsTotal = notifications?.total || 0;\n },\n [types.SET_EMPLOYEE_PERMISSIONS](state: CompanyState, permissions: PermissionsArray[]) {\n state.employee.permissions = permissions;\n },\n [types.SET_EMPLOYEE_ROLES](state: CompanyState, roles: string[]) {\n state.employee.roles = roles;\n },\n [types.SET_COMPANY_EMPLOYEE](state: CompanyState, employee: Employee) {\n state.employee = {\n ...state.employee, ...employee, found: true, init: true,\n };\n },\n [types.SET_OPERATING_RULES](state: CompanyState, rules: OperatingRule[]) {\n state.operating_rules = rules;\n },\n [types.SET_FEEDBACK_REVIEWS](state: CompanyState, reviews: any[]) {\n state.feedback_reviews = reviews;\n },\n [types.SET_COMPANY_FORM_ERROR](state: CompanyState, error: string | Record<string, string[]>) {\n state.companyForm.errors.set(error);\n },\n [types.SET_COMPANY_META_FORM_ERROR](state: CompanyState, error: string | Record<string, string[]>) {\n state.companyMetaForm.errors.set(error);\n },\n [types.CLEAR_COMPANY_META_FORM_ERRORS](state: CompanyState, form_field: string | null = null) {\n if (form_field === null || form_field === undefined) {\n state.companyMetaForm.errors.clear();\n } else {\n state.companyMetaForm.errors.clear(form_field);\n }\n },\n};\n\nconst actions = {\n\n async fetchCompany({commit}, companyName: string) {\n try {\n const responseData = await performApiRequest(commit, 'SET_COMPANY_LOADING', 'company', () => axios.get(`/v1/company/${companyName}`));\n commit(types.SET_COMPANY, responseData?.company);\n if (Array.isArray(responseData?.company?.listings)) {\n commit('listing/SET_ALL_LISTINGS', responseData.company.listings, {root: true});\n }\n\n state.company.init = true;\n } catch (error) {\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n }\n },\n\n /**\n * Save company Info\n */\n async saveCompanyInfo({state, commit}) {\n try {\n const responseData = await performApiRequest(commit, 'SET_COMPANY_LOADING', 'company', () => axios.put('/v1/company', state.company));\n commit(types.SET_COMPANY, responseData.company);\n\n push.success({\n message: 'Company saved successfully',\n });\n } catch (error) {\n push.error({\n message: 'There was an error saving company info.',\n });\n\n console.dir('error');\n console.dir(error);\n commit(types.SET_COMPANY_META_FORM_ERROR, error.response.data.errors);\n }\n },\n\n async saveCompanyTimezone({commit}, data: { timezone: string, updateListings: boolean }) {\n try {\n await performApiRequest(commit, 'SET_COMPANY_LOADING', 'company', () => axios.put('/v1/company/timezone', data));\n push.success({\n message: 'Timezone saved successfully',\n });\n } catch (error) {\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n }\n },\n\n async saveCompanyMeta({state, commit}) {\n try {\n commit(types.CLEAR_COMPANY_META_FORM_ERRORS);\n const responseData = await performApiRequest(commit, 'SET_COMPANY_LOADING', 'company_meta', () => axios.put('/v1/meta', state.company.meta));\n commit(types.SET_COMPANY_META, responseData.meta);\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'Company information saved successfully',\n });\n } catch (error) {\n commit(types.SET_COMPANY_META_FORM_ERROR, error.response.data.errors);\n throw error;\n }\n },\n\n async updateCancellationPolicy({commit, dispatch}, cancellation: string) {\n try {\n await performApiRequest(commit, 'SET_COMPANY_LOADING', 'company', () => axios.put('/v1/company/cancellation-policy', {cancellation}));\n dispatch('fetchCompany', state.company.slug);\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'Cancellation policy saved successfully',\n });\n } catch (error) {\n commit('SET_COMPANY_META_FORM_ERROR', error.response.data.errors);\n }\n },\n\n async updateTermsOfService({commit, dispatch}, terms: string) {\n try {\n await performApiRequest(commit, 'SET_COMPANY_LOADING', 'company', () => axios.put('/v1/company/terms-of-service', {terms}));\n dispatch('fetchCompany', state.company.slug);\n\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'Terms of service saved successfully',\n });\n } catch (error) {\n commit('SET_COMPANY_META_FORM_ERROR', error.response.data.errors);\n }\n },\n\n async removeCompanyLogo({commit}) {\n try {\n const responseData = await performApiRequest(commit, 'SET_COMPANY_LOADING', 'company', () => axios.delete('/v1/company/logo'));\n commit(types.SET_COMPANY, responseData.company);\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'Terms of service saved successfully',\n });\n } catch (error) {\n commit('SET_COMPANY_META_FORM_ERROR', error.response.data.errors);\n }\n },\n\n fetchCompanyNotifications({commit}) {\n commit('SET_COMPANY_LOADING', {subject: 'notifications', loading: true});\n\n axios.get(`/v1/notifications?page=${state.nextNotifications}`)\n .then((response) => {\n commit('SET_COMPANY_NOTIFICATIONS', response.data.notifications);\n }).catch((e) => {\n console.dir(e);\n }).finally(() => {\n commit('SET_COMPANY_LOADING', {subject: 'notifications', loading: false});\n });\n },\n\n async markReadCompanyNotifications({commit}, id: string) {\n try {\n await performApiRequest(commit, 'SET_COMPANY_LOADING', 'notifications', () => axios.put(`/v1/notifications/${id}`));\n } catch (error) {\n commit('SET_COMPANY_META_FORM_ERROR', error.response.data.errors);\n }\n },\n\n /**\n * Fetch an employee by their invite token\n */\n async fetchEmployeeByInviteToken({commit}, inviteToken: string) {\n try {\n const returnData = await performApiRequest(commit, 'SET_COMPANY_LOADING', 'invite', () => axios.get(`/v1/company/invites/${inviteToken}`));\n commit('SET_COMPANY_EMPLOYEE', returnData.employee);\n return returnData;\n } catch (error) {\n commit('SET_COMPANY_META_FORM_ERROR', error.response.data.errors);\n }\n },\n\n fetchAgencySingleListingBookings({commit}, l_id: string) {\n commit('SET_COMPANY_LOADING', {subject: 'bookings', loading: true});\n\n axios.get(`/v1/listings/${l_id}/bookings`)\n .then((response) => {\n commit('listing/SET_CURRENT_LISTING_BOOKINGS', response.data.bookings, {root: true});\n }).catch(() => {\n }).finally(() => {\n commit('SET_COMPANY_LOADING', {subject: 'bookings', loading: false});\n });\n },\n\n /**\n * Save a Stripe API key\n */\n async saveStripeKey({commit}, key: string) {\n try {\n const responseData = await performApiRequest(commit, 'SET_COMPANY_LOADING', 'saveStripeKey', () => axios.post('/v1/stripe/key', {key}));\n commit(types.SET_COMPANY, responseData.company);\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'Stripe secret key added',\n });\n EventBus.$emit('save-stripe-secret-key-success');\n\n return responseData;\n } catch (error) {\n commit(types.SET_COMPANY_META_FORM_ERROR, error.response.data.errors);\n }\n },\n\n async resetStripeKey({commit}) {\n const responseData = await performApiRequest(commit, 'SET_COMPANY_LOADING', 'resetStripeKey', () => axios.delete('/v1/stripe/key'));\n commit(types.SET_COMPANY, responseData.company);\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'Stripe secret key removed',\n });\n return responseData;\n },\n\n getCustomPaymentMethods({commit}) {\n commit('SET_COMPANY_LOADING', {subject: 'customPaymentMethods', loading: true});\n\n axios.get(`/v1/custom-payment-methods`)\n .then((response) => {\n commit('payments/SET_CUSTOM_PAYMENT_METHODS', response.data.meta, {root: true});\n }).catch((e) => {\n console.dir(e);\n }).finally(() => {\n commit('SET_COMPANY_LOADING', {subject: 'customPaymentMethods', loading: false});\n });\n },\n\n async addCustomPaymentMethods({commit}, name: string) {\n const responseData = await performApiRequest(commit, 'SET_COMPANY_LOADING', 'customPaymentMethods', () => axios.post(`/v1/custom-payment-methods`, {name}));\n commit('payments/SET_CUSTOM_PAYMENT_METHODS', responseData.meta, {root: true});\n },\n\n async getDefaultMeta({commit}) {\n try {\n const responseData = await performApiRequest(commit, 'SET_COMPANY_LOADING', 'getDefaultMeta', () => axios.get('/v1/default-meta'));\n commit(types.SET_COMPANY_DEFAULT_META, responseData.meta);\n } catch (error) {\n }\n },\n\n async addDefaultMeta({commit}, data: {\n meta: ({ value: number; key: string } | { value: string; key: string })[]\n }) {\n try {\n await performApiRequest(commit, 'SET_COMPANY_LOADING', 'addDefaultMeta', () => axios.post('/v1/default-meta', data));\n push.success({\n message: 'Settings saved successfully',\n });\n } catch (error) {\n push.error({\n message: 'There was an error saving settings',\n });\n commit(types.SET_COMPANY_META_FORM_ERROR, error.response.data.errors);\n throw error;\n }\n },\n\n async fetchDeliveryLocations({commit}) {\n try {\n commit('CLEAR_COMPANY_META_FORM_ERRORS');\n const responseData = await performApiRequest(commit, 'SET_COMPANY_LOADING', 'deliveryLocation', () => axios.get('/v1/delivery-locations'));\n EventBus.$emit('fetch-delivery-location-success');\n commit(types.SET_DELIVERY_LOCATIONS, responseData.locations);\n\n return responseData;\n } catch (error) {\n commit('SET_COMPANY_META_FORM_ERROR', error.response.data.errors);\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n }\n },\n\n async createDeliveryLocation({commit, dispatch}, deliveryLocation: DeliveryLocation) {\n try {\n commit('CLEAR_COMPANY_META_FORM_ERRORS');\n const responseData = await performApiRequest(commit, 'SET_COMPANY_LOADING', 'deliveryLocation', () => axios.post('/v1/delivery-locations', deliveryLocation));\n dispatch('fetchDeliveryLocations');\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'Delivery location created',\n });\n return responseData;\n } catch (error) {\n commit('SET_COMPANY_META_FORM_ERROR', error.response.data.errors);\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n }\n },\n\n async deleteDeliveryLocation({commit, dispatch}, uuid: string) {\n try {\n commit('CLEAR_COMPANY_META_FORM_ERRORS');\n await performApiRequest(commit, 'SET_COMPANY_LOADING', 'deliveryLocation', () => axios.delete(`/v1/delivery-locations/${uuid}`));\n dispatch('fetchDeliveryLocations');\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'Delivery location deleted',\n });\n } catch (error) {\n commit('SET_COMPANY_META_FORM_ERROR', error.response.data.errors);\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n }\n },\n\n async toggleDeliveryLocation({commit, dispatch}, uuid: string) {\n try {\n commit('CLEAR_COMPANY_META_FORM_ERRORS');\n await performApiRequest(commit, 'SET_COMPANY_LOADING', 'deliveryLocation', () => axios.post(`/v1/delivery-locations/${uuid}/toggle`));\n dispatch('fetchDeliveryLocations');\n\n push.success({\n message: 'Delivery location toggled',\n });\n } catch (error) {\n commit('SET_COMPANY_META_FORM_ERROR', error.response.data.errors);\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n }\n },\n\n async updateDeliveryLocation({commit, dispatch}, location: DeliveryLocation) {\n try {\n commit(types.CLEAR_COMPANY_META_FORM_ERRORS);\n await performApiRequest(commit, 'SET_COMPANY_LOADING', 'deliveryLocation', () => axios.put(`/v1/delivery-locations/${location.uuid}/`, location));\n dispatch('fetchDeliveryLocations');\n push.success({\n message: 'Delivery location updated',\n });\n } catch (error) {\n commit('SET_COMPANY_META_FORM_ERROR', error.response.data.errors);\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n }\n },\n\n async getOperatingRules({commit}) {\n try {\n commit('CLEAR_COMPANY_META_FORM_ERRORS');\n const responseData = await performApiRequest(commit, 'SET_COMPANY_LOADING', 'getOperatingRules', () => axios.get('/v1/operating-rules'));\n commit('SET_OPERATING_RULES', responseData.operatingRules);\n } catch (error) {\n commit('SET_COMPANY_META_FORM_ERROR', error.response.data.errors);\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n }\n },\n\n async saveOperatingRule({commit, dispatch}, data: { type: string, data: any }) {\n try {\n commit('CLEAR_COMPANY_META_FORM_ERRORS');\n await performApiRequest(commit, 'SET_COMPANY_LOADING', 'createOperatingRule', () => axios.post('/v1/operating-rules', data));\n dispatch('getOperatingRules');\n EventBus.$emit('save-operating-rule-success', data);\n } catch (error) {\n commit('SET_COMPANY_META_FORM_ERROR', error.response.data.errors);\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n }\n },\n\n /**\n * Delete a companies' operating rule\n */\n async deleteOperatingRule({commit, dispatch}, rule: OperatingRule) {\n try {\n commit('CLEAR_COMPANY_META_FORM_ERRORS');\n await performApiRequest(commit, 'SET_COMPANY_LOADING', 'deleteOperatingRule', () => axios.delete(`/v1/operating-rules/${rule.uuid}`));\n dispatch('getOperatingRules');\n EventBus.$emit('delete-operating-rule-success', rule);\n } catch (error) {\n commit('SET_COMPANY_META_FORM_ERROR', error.response.data.errors);\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n }\n },\n\n async getActivityLog({commit}, data: { page: number }) {\n try {\n const query = createUrlQueryString({\n page: data.page || 1,\n })\n\n const responseData = await performApiRequest(commit, 'SET_COMPANY_LOADING', 'activity_log', () => axios.get(`/v1/activity-log${query}`));\n\n return responseData.activity;\n } catch (error) {\n console.error('Failed to get activity log:', error);\n }\n },\n\n getFeedbackReviews({commit}) {\n axios.get('/v1/feedback-reviews')\n .then((response) => {\n commit('SET_FEEDBACK_REVIEWS', get(response, 'data.feedback'));\n }).catch(() => {\n }).finally(() => {\n });\n },\n\n saveFeedbackReview({commit}, review: { turo_id: string, review: string }) {\n axios.post('/v1/feedback-reviews', review)\n .then((response) => {\n commit('SET_FEEDBACK_REVIEWS', get(response, 'data.feedback'));\n EventBus.$emit('save-feedback-review-success');\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'Feedback review saved successfully',\n });\n }).catch(() => {\n }).finally(() => {\n });\n },\n\n deleteFeedbackReview({commit}, review) {\n axios.delete(`/v1/feedback-reviews/${review.uuid}`, review)\n .then((response) => {\n commit(types.SET_FEEDBACK_REVIEWS, get(response, 'data.feedback'));\n EventBus.$emit('delete-feedback-review-success');\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'Feedback review saved successfully',\n });\n }).catch((e) => {\n console.dir(e);\n }).finally(() => {\n });\n },\n\n /**\n * Mark the account for deletion\n */\n markAccountForDeletion({commit}, data: { reason: string, comments: string }) {\n commit('SET_COMPANY_LOADING', {subject: 'markAccountForDeletion', loading: true});\n axios.post('/v1/mark-account-for-deletion', data)\n .then(() => {\n EventBus.$emit('mark-account-for-deletion-success');\n }).catch((error) => {\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n }).finally(() => {\n commit('SET_COMPANY_LOADING', {subject: 'markAccountForDeletion', loading: false});\n });\n },\n\n\n /**\n * Extend company trial\n */\n extendCompanyTrial({commit, state}) {\n commit('SET_COMPANY_LOADING', {subject: 'extendTrial', loading: true});\n\n axios.post(`/v1/company/${state.company.uuid}/extend-trial`)\n .then((response) => {\n commit('SET_COMPANY', response.data.company);\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'Trial extended',\n });\n EventBus.$emit('extend-trial-success');\n }).catch((error) => {\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n }).finally(() => {\n commit('SET_COMPANY_LOADING', {subject: 'extendTrial', loading: false});\n });\n },\n\n async getEmployees({commit}) {\n try {\n const responseData = await performApiRequest(commit, 'SET_COMPANY_LOADING', 'employee', () => axios.get('/v1/employees'));\n commit('SET_COMPANY_EMPLOYEES', responseData.employees);\n EventBus.$emit('employee-get-success');\n } catch (error) {\n commit('SET_COMPANY_META_FORM_ERROR', error.response.data.errors);\n }\n },\n\n async saveEmployee({commit}, data: { employee_uuid: string, data: object }) {\n try {\n await performApiRequest(commit, 'SET_COMPANY_LOADING', 'employee', () => axios.put(`/v1/employees/${data.employee_uuid}`, data.data));\n EventBus.$emit('employee-updated-success');\n } catch (error) {\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n }\n },\n\n async updateEmployeeNotificationSettings({commit}, data: SavingEmployeeNotificationSettings) {\n try {\n await performApiRequest(commit, 'SET_COMPANY_LOADING', 'employee', () => axios.put(`/v1/employees/${data.uuid}/notification-settings`, data));\n EventBus.$emit('employee-updated-success');\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'Settings updated successfully!',\n });\n } catch (error) {\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n }\n },\n\n\n async listingMatchCompanyUseSecondaryDriver({commit}) {\n try {\n await performApiRequest(commit, 'SET_COMPANY_LOADING', 'listingReset', () => axios.post('/v1/reset-listings-allow-secondary-driver'));\n EventBus.$emit('reset-use-secondary-driver-listings-success');\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'Listing settings updated successfully',\n });\n } catch (error) {\n console.error('Failed to get activity log:', error);\n }\n },\n};\n\nconst companyModule: Module<CompanyState, RootState> = {\n namespaced: true,\n state,\n mutations,\n actions,\n getters,\n}\n\nexport default companyModule;\n","import axios from 'axios';\nimport * as types from '@/store/mutation-types';\nimport {Form} from '@/plugins/FWForms/index';\nimport {BookingInterface, Coupon, StoreLoaders} from '@/types';\nimport {RootState} from '@/types/RootState';\nimport {performApiRequest} from '@/store/helpers/vuex-helpers';\nimport {Module} from 'vuex';\nimport {push} from 'notivue'\n\nexport interface CouponState {\n loading: StoreLoaders;\n couponForm: Form<any>;\n coupons: Coupon[];\n redemptions: BookingInterface[];\n}\n\n// state\nconst state: CouponState = {\n loading: {\n save_coupon: false,\n update_coupon: false,\n fetch_coupon: false,\n delete_coupon: false,\n redemptions: false,\n },\n couponForm: new Form(),\n coupons: [],\n redemptions: [],\n};\n\n\nconst mutations = {\n [types.SET_COUPON_LOADING](state: CouponState, loading: { subject: string, loading: boolean }) {\n state.loading[loading.subject] = loading.loading;\n },\n [types.SET_COUPONS](state: CouponState, coupons: Coupon[]) {\n state.coupons = coupons;\n },\n [types.SET_COUPON_REDEMPTIONS](state: CouponState, redemptions: BookingInterface[]) {\n state.redemptions = redemptions;\n },\n [types.UPDATE_COUPON](state: CouponState, coupon: Coupon) {\n const index = state.coupons.findIndex(c => c.uuid === coupon.uuid);\n\n if (index >= 0) {\n const updatedCoupons = [...state.coupons];\n\n updatedCoupons[index] = coupon;\n\n state.coupons = updatedCoupons;\n }\n },\n [types.CLEAR_COUPON_FORM_ERRORS](state: CouponState, form_field: string | null = null) {\n if (form_field === null || form_field === undefined) {\n state.couponForm.errors.clear();\n } else {\n state.couponForm.errors.clear(form_field);\n }\n },\n [types.SET_COUPON_FORM_ERROR](state: CouponState, error: string | Record<string, string[]>) {\n state.couponForm.errors.set(error);\n },\n [types.SET_COUPON_FORM_BUSY](state: CouponState, busy: boolean) {\n state.couponForm.busy = busy;\n },\n\n};\n\nconst actions = {\n\n /**\n * Check a coupon\n */\n async checkCoupon({commit, rootGetters}, {coupon, l_id, email}) {\n commit(types.CLEAR_COUPON_FORM_ERRORS);\n\n let queryString = `?coupon=${coupon}`;\n if (l_id) {\n queryString += `&l_id=${l_id}`;\n }\n if (email) {\n email = encodeURIComponent(email);\n queryString += `&email=${email}`;\n }\n\n try {\n commit('SET_COUPON_FORM_BUSY', true);\n\n const responseData = await performApiRequest(commit, 'SET_COUPON_LOADING', 'fetch_coupon', () => axios.get(`/v1/company/${rootGetters['company/company'].uuid}/coupons/check${queryString}`));\n commit('tenantCheckout/SET_TENANT_CHECKOUT_DISCOUNT', responseData?.coupon, {root: true});\n } catch (error) {\n commit('SET_COUPON_FORM_ERROR', error.response.data?.errors || 'There was an error');\n commit('checkout/RESET_CHECKOUT_DISCOUNT', null, {root: true});\n } finally {\n commit(types.SET_COUPON_FORM_BUSY, false);\n }\n },\n\n async fetchCoupons({commit}) {\n try {\n const responseData = await performApiRequest(commit, 'SET_COUPON_LOADING', 'fetch_coupon', () => axios.get('/v1/coupons'));\n commit(types.SET_COUPONS, responseData.coupons);\n } catch (error) {\n }\n },\n\n async createCoupon({commit}, coupon: Coupon) {\n commit(types.CLEAR_COUPON_FORM_ERRORS);\n try {\n const responseData = await performApiRequest(commit, 'SET_COUPON_LOADING', 'save_coupon', () => axios.post('/v1/coupons', coupon));\n commit(types.SET_COUPONS, responseData.coupons);\n\n push.success({\n message: 'Coupon created successfully',\n });\n } catch (error) {\n commit(types.SET_COUPON_FORM_ERROR, error.response.data?.errors || 'There was an error');\n }\n },\n\n async toggleCouponActive({commit}, couponUuid: string) {\n try {\n const responseData = await performApiRequest(commit, 'SET_COUPON_LOADING', 'save_coupon', () => axios.put(`/v1/coupons/${couponUuid}/toggle`));\n commit(types.SET_COUPONS, responseData.coupons);\n\n push.success({\n message: 'Coupon status updated successfully',\n });\n } catch (error) {\n }\n },\n\n async multiCouponToggle({commit}, coupons: typeof Array<Coupon['uuid']>) {\n try {\n const responseData = await performApiRequest(commit, 'SET_COUPON_LOADING', 'save_coupon', () => axios.put('/v1/coupons/', coupons));\n commit(types.SET_COUPONS, responseData.coupons);\n } catch (error) {\n }\n },\n\n async multiCouponDelete({commit}, coupons: typeof Array<Coupon['uuid']>) {\n try {\n const responseData = await performApiRequest(commit, 'SET_COUPON_LOADING', 'save_coupon', () => axios.post('/v1/coupons/delete', coupons));\n commit(types.SET_COUPONS, responseData.coupons);\n } catch (error) {\n }\n },\n\n /**\n * Update a coupon\n */\n async updateCoupon({commit}, coupon: Coupon) {\n try {\n const responseData = await performApiRequest(commit, 'SET_COUPON_LOADING', 'update_coupon', () => axios.put(`/v1/coupons/${coupon.uuid}`, coupon));\n commit(types.UPDATE_COUPON, responseData?.coupon);\n\n push.success({\n message: 'Coupon updated successfully',\n });\n } catch (error) {\n commit(types.SET_COUPON_FORM_ERROR, error.response.data?.errors || 'There was an error');\n throw error;\n }\n },\n\n async deleteCoupon({commit}, couponUuid: string) {\n try {\n const responseData = await performApiRequest(commit, 'SET_COUPON_LOADING', 'delete_coupon', () => axios.delete(`/v1/coupons/${couponUuid}`));\n commit(types.SET_COUPONS, responseData.coupons);\n\n push.success({\n message: 'Coupon deleted successfully',\n });\n } catch (error) {\n commit(types.SET_COUPON_FORM_ERROR, error.response.data?.errors || 'There was an error');\n }\n },\n\n /**\n * Check a coupons redemptions\n */\n async redemptions({commit}, coupon: string) {\n try {\n const responseData = await performApiRequest(commit, 'SET_COUPON_LOADING', 'redemptions', () => axios.get(`/v1/coupons/${coupon}/redemptions`));\n commit(types.SET_COUPON_REDEMPTIONS, responseData.orders);\n } catch (error) {\n commit(types.SET_COUPON_FORM_ERROR, error.response.data?.errors || 'There was an error');\n }\n },\n};\n\nconst couponModule: Module<CouponState, RootState> = {\n namespaced: true,\n\n state,\n\n getters: {\n loading: (state: CouponState) => state.loading,\n coupons: (state: CouponState) => state.coupons,\n form: (state: CouponState) => state.couponForm,\n redemptions: (state: CouponState) => state.redemptions,\n },\n\n mutations,\n\n actions,\n}\n\nexport default couponModule;\n","import axios from 'axios';\nimport {Form} from '@/plugins/FWForms/index';\nimport {EventBus} from '@/plugins/eventBus';\nimport {get} from 'lodash';\nimport * as types from '../mutation-types';\nimport {push} from 'notivue';\n\nexport interface CustodianState {\n init: boolean;\n loading: Record<string, boolean>;\n form: Form<object>;\n custodian: any;\n invite: any;\n custodians: any[];\n listings: any[];\n bookings: any[];\n\n}\n\nconst state: CustodianState = {\n init: false,\n loading: {\n create: false,\n delete: false,\n update: false,\n join: false,\n },\n form: new Form(),\n custodian: null,\n invite: null,\n custodians: [],\n listings: [],\n bookings: [],\n};\n\nconst getters = {\n init: (state: CustodianState) => state.init,\n loading: (state: CustodianState) => state.loading,\n form: (state: CustodianState) => state.form,\n custodian: (state: CustodianState) => state.custodian,\n custodians: (state: CustodianState) => state.custodians,\n invite: (state: CustodianState) => state.invite,\n listings: (state: CustodianState) => state.listings,\n bookings: (state: CustodianState) => state.bookings,\n};\n\nconst mutations = {\n [types.SET_CUSTODIAN_LOADING](state: CustodianState, loading: { subject: string, loading: boolean }) {\n state.loading[loading.subject] = loading.loading;\n },\n [types.SET_CUSTODIANS](state: CustodianState, custodians) {\n state.custodians = custodians;\n },\n [types.SET_CUSTODIAN_INVITE](state: CustodianState, invite) {\n state.invite = invite;\n },\n [types.SET_CUSTODIAN_LISTINGS](state: CustodianState, listings) {\n state.listings = listings;\n },\n [types.SET_CUSTODIAN_BOOKINGS](state: CustodianState, bookings) {\n state.bookings = bookings;\n },\n};\n\nconst actions = {\n\n\n /**\n * Get custodian\n */\n join({commit}, custodian_id: string) {\n commit(types.SET_CUSTODIAN_LOADING, {subject: 'join', loading: true});\n\n axios.get(`/v1/custodian-invite/${custodian_id}`)\n .then(() => {\n EventBus.$emit('custodian-join-success');\n }).catch((e) => {\n EventBus.$emit('custodian-join-failure', get(e, 'response.data.message', 'There was an error'));\n push.error({\n message: e?.response?.data?.message || 'There was an error',\n });\n }).finally(() => {\n commit('SET_CUSTODIAN_LOADING', {subject: 'join', loading: false});\n });\n },\n\n\n /**\n * Create custodian invite link\n */\n createInvite({commit}, data) {\n commit('SET_CUSTODIAN_LOADING', {subject: 'create', loading: true});\n\n axios.post('/v1/custodian-invite', data)\n .then((response) => {\n commit('SET_CUSTODIAN_INVITE', get(response, 'data.invite', []));\n EventBus.$emit('custodial-invite-success', get(response, 'data.invite'));\n }).catch((e) => {\n EventBus.$emit('custodian-create-invite-failure', get(e, 'response.data.message', 'There was an error'));\n push.error({\n message: e?.response?.data?.message || 'There was an error',\n });\n }).finally(() => {\n commit('SET_CUSTODIAN_LOADING', {subject: 'create', loading: false});\n });\n },\n\n /**\n * Update custodian\n */\n updateCustodian({commit}, data) {\n commit('SET_CUSTODIAN_LOADING', {subject: 'create', loading: true});\n\n axios.put(`/v1/custodians/${data.custodian.uuid}`, data)\n .then((response) => {\n commit('SET_CUSTODIAN_INVITE', get(response, 'data.invite', []));\n EventBus.$emit('custodial-invite-success', get(response, 'data.invite'));\n }).catch((e) => {\n EventBus.$emit('custodian-create-invite-failure', get(e, 'response.data.message', 'There was an error'));\n push.error({\n message: e?.response?.data?.message || 'There was an error',\n });\n }).finally(() => {\n commit('SET_CUSTODIAN_LOADING', {subject: 'create', loading: false});\n });\n },\n\n /**\n * Get custodian\n */\n getCustodians({commit}) {\n commit('SET_CUSTODIAN_LOADING', {subject: 'tax_categories', loading: true});\n\n axios.get('/v1/custodians')\n .then((response) => {\n commit('SET_CUSTODIANS', get(response, 'data.custodians', []));\n }).catch(() => {\n }).finally(() => {\n commit('SET_CUSTODIAN_LOADING', {subject: 'tax_categories', loading: false});\n });\n },\n\n /**\n * Get custodians listings\n */\n getCustodianListings({commit}, custodian) {\n commit('SET_CUSTODIAN_LOADING', {subject: 'tax_categories', loading: true});\n\n axios.get(`/v1/custodians/${custodian.uuid}/listings`)\n .then((response) => {\n commit('SET_CUSTODIAN_LISTINGS', get(response, 'data.listings', []));\n EventBus.$emit('get-custodian-listings-success', get(response, 'data.listings', []));\n }).catch(() => {\n }).finally(() => {\n commit('SET_CUSTODIAN_LOADING', {subject: 'tax_categories', loading: false});\n });\n },\n\n getCustodianBookings({commit}, options) {\n commit('SET_CUSTODIAN_LOADING', {subject: 'tax_categories', loading: true});\n\n let qString = '?';\n if (get(options, 'startDate')) {\n qString += `startDate=${get(options, 'startDate')}`;\n }\n if (get(options, 'endDate')) {\n qString += `&endDate=${get(options, 'endDate')}`;\n }\n\n\n if (qString === '?') {\n qString = '';\n }\n\n axios.get(`/v1/custodians/${options.custodian_uuid}/bookings${qString}`)\n .then((response) => {\n commit('SET_CUSTODIAN_BOOKINGS', get(response, 'data.bookings', []));\n EventBus.$emit('get-custodian-bookings-success', get(response, 'data.listings', []));\n }).catch(() => {\n }).finally(() => {\n commit('SET_CUSTODIAN_LOADING', {subject: 'tax_categories', loading: false});\n });\n },\n\n /**\n * Delete custodian\n */\n deleteCustodians({commit}, custodian_uuid) {\n commit('SET_CUSTODIAN_LOADING', {subject: 'delete', loading: true});\n\n axios.delete(`/v1/custodians/${custodian_uuid}`)\n .then((response) => {\n EventBus.$emit('delete-custodian-success', get(response, 'data.invite'));\n }).catch((e) => {\n EventBus.$emit('custodian-create-invite-failure', get(e, 'response.data.message', 'There was an error'));\n push.error({\n message: e?.response?.data?.message || 'There was an error',\n });\n }).finally(() => {\n commit('SET_CUSTODIAN_LOADING', {subject: 'delete', loading: false});\n });\n },\n\n /**\n * Send custodian invite\n */\n sendInviteEmailLink({commit}, data) {\n commit('SET_CUSTODIAN_LOADING', {subject: 'sending_invite_email', loading: true});\n\n axios.post(`/v1/custodians/${data.custodian_uuid}/send-invite-email`, data)\n .then((response) => {\n EventBus.$emit('delete-custodian-success', get(response, 'data.invite'));\n }).catch((e) => {\n EventBus.$emit('custodian-create-invite-failure', get(e, 'response.data.message', 'There was an error'));\n push.error({\n message: e?.response?.data?.message || 'There was an error',\n });\n }).finally(() => {\n commit('SET_CUSTODIAN_LOADING', {subject: 'sending_invite_email', loading: false});\n });\n },\n};\n\nexport default {\n namespaced: true,\n state,\n mutations,\n actions,\n getters,\n};\n","import {EventBus} from '@/plugins/eventBus';\nimport {get} from 'lodash';\nimport {Form} from '@/plugins/FWForms/index';\nimport axios from 'axios';\nimport * as types from '@/store/mutation-types';\nimport {push} from 'notivue'\n\nexport interface CustomFieldsState {\n loading: Record<string, boolean>;\n customFields: any[];\n form: Form<object>;\n}\n\n// state\nconst state: CustomFieldsState = {\n loading: {\n customFields: false,\n updateCustomFields: false,\n },\n customFields: [],\n form: new Form(),\n};\n\nconst getters = {\n loading: (state: CustomFieldsState) => state.loading,\n form: (state: CustomFieldsState) => state.form,\n customFields: (state: CustomFieldsState) => state.customFields,\n};\n\nconst mutations = {\n [types.SET_CUSTOM_FIELDS_LOADING](state: CustomFieldsState, loading: { subject: string, loading: boolean }) {\n state.loading[loading.subject] = loading.loading;\n },\n [types.SET_CUSTOM_FIELDS](state: CustomFieldsState, fields) {\n state.customFields = fields;\n },\n [types.SET_CUSTOM_FIELDS_FORM_BUSY](state: CustomFieldsState, busy) {\n state.form.busy = busy;\n },\n};\n\nconst actions = {\n\n fetchCustomFields({commit}) {\n commit('SET_CUSTOM_FIELDS_LOADING', {subject: 'customFields', loading: true});\n commit('SET_CUSTOM_FIELDS_FORM_BUSY', true);\n\n axios.get('/v1/custom-fields')\n .then((response) => {\n commit('SET_CUSTOM_FIELDS', get(response, 'data.customFields'));\n }).catch(() => {\n }).finally(() => {\n commit('SET_CUSTOM_FIELDS_FORM_BUSY', false);\n\n commit('SET_CUSTOM_FIELDS_LOADING', {subject: 'customFields', loading: false});\n });\n },\n\n createCustomFields({commit, state}, field) {\n commit('SET_CUSTOM_FIELDS_LOADING', {subject: 'updateCustomFields', loading: true});\n commit('SET_CUSTOM_FIELDS_FORM_BUSY', true);\n\n axios.post('/v1/custom-fields', field)\n .then((response) => {\n EventBus.$emit('create-custom-fields-success', get(response, 'data.customField', {}));\n push.success({\n message: 'Custom Field created successfully!',\n });\n }).catch((e) => {\n state.form.errors.set(get(e, 'response.data.errors'));\n }).finally(() => {\n commit('SET_CUSTOM_FIELDS_FORM_BUSY', false);\n commit('SET_CUSTOM_FIELDS_LOADING', {subject: 'updateCustomFields', loading: false});\n });\n },\n\n updateCustomFields({commit}, field) {\n commit('SET_CUSTOM_FIELDS_LOADING', {subject: 'updateCustomFields', loading: true});\n commit('SET_CUSTOM_FIELDS_FORM_BUSY', true);\n\n axios.put(`/v1/custom-fields/${field.uuid}`, field)\n .then((response) => {\n EventBus.$emit('update-custom-fields-success', get(response, 'data.customField', {}));\n push.success({\n message: 'Custom Field updated successfully!',\n });\n }).catch((e) => {\n EventBus.$emit('update-custom-fields-error', {field, error: get(e, 'response.data.errors', {})});\n }).finally(() => {\n commit('SET_CUSTOM_FIELDS_FORM_BUSY', false);\n commit('SET_CUSTOM_FIELDS_LOADING', {subject: 'updateCustomFields', loading: false});\n });\n },\n\n updateCustomFieldsPositions({commit}, fields) {\n commit('SET_CUSTOM_FIELDS_LOADING', {subject: 'updateCustomFields', loading: true});\n commit('SET_CUSTOM_FIELDS_FORM_BUSY', true);\n\n axios.put('/v1/custom-fields/positions', {fields})\n .then((response) => {\n EventBus.$emit('update-custom-fields-positions-success', get(response, 'data.customFields', []));\n }).catch(() => {\n }).finally(() => {\n commit('SET_CUSTOM_FIELDS_FORM_BUSY', false);\n commit('SET_CUSTOM_FIELDS_LOADING', {subject: 'updateCustomFields', loading: false});\n });\n },\n\n deleteCustomField({commit}, field) {\n commit('SET_CUSTOM_FIELDS_LOADING', {subject: 'updateCustomFields', loading: true});\n commit('SET_CUSTOM_FIELDS_FORM_BUSY', true);\n\n axios.delete(`/v1/custom-fields/${field.uuid}`)\n .then((response) => {\n commit('SET_CUSTOM_FIELDS', get(response, 'data.customFields'));\n push.success({\n message: 'Custom Field deleted successfully!',\n });\n }).catch((e) => {\n EventBus.$emit('delete-custom-fields-failed', get(e, 'response.data.message', {}));\n }).finally(() => {\n commit('SET_CUSTOM_FIELDS_FORM_BUSY', false);\n commit('SET_CUSTOM_FIELDS_LOADING', {subject: 'updateCustomFields', loading: false});\n });\n },\n};\n\nexport default {\n namespaced: true,\n state,\n mutations,\n actions,\n getters,\n};\n","import {Form} from '@/plugins/FWForms/index';\nimport axios from 'axios';\nimport * as types from '@/store/mutation-types';\nimport {performApiRequest} from '@/store/helpers/vuex-helpers';\nimport {StoreLoaders} from '@/types';\nimport {push} from 'notivue'\n\nexport interface DefaultProperty {\n identifier: string;\n name: string;\n owner_type: string;\n property_type: string;\n select_options: any;\n show_on: any;\n position?: number;\n editable?: boolean;\n updated_at?: string;\n created_at?: string;\n uuid?: string;\n}\n\nexport interface DefaultPropertiesState {\n loading: StoreLoaders;\n defaultProperties: DefaultProperty[];\n form: Form<any>;\n}\n\n// state\nconst state: DefaultPropertiesState = {\n loading: {\n fetchDefaultProperties: false,\n defaultProperties: false,\n createCustomFields: false,\n updateCustomFields: false,\n deleteCustomFields: false,\n },\n defaultProperties: [],\n form: new Form(),\n};\n\nconst getters = {\n loading: (state: DefaultPropertiesState) => state.loading,\n form: (state: DefaultPropertiesState) => state.form,\n defaultProperties: (state: DefaultPropertiesState) => state.defaultProperties,\n};\n\nconst mutations = {\n [types.SET_CUSTOM_FIELDS_LOADING](state: DefaultPropertiesState, loading: { subject: string, loading: boolean }) {\n state.loading[loading.subject] = loading.loading;\n },\n [types.SET_DEFAULT_PROPERTIES](state: DefaultPropertiesState, defaultProperty: DefaultProperty[]) {\n state.defaultProperties = defaultProperty;\n },\n [types.CLEAR_DEFAULT_PROPERTIES_FORM](state: DefaultPropertiesState) {\n state.form.errors.clear();\n },\n [types.SET_DEFAULT_PROPERTIES_FORM_BUSY](state: DefaultPropertiesState, busy = true) {\n state.form.busy = busy;\n },\n [types.SET_DEFAULT_PROPERTIES_FORM_ERRORS](state: DefaultPropertiesState, errors: string | Record<string, string[]>) {\n state.form.errors.set(errors);\n },\n};\n\nconst actions = {\n async fetchDefaultProperties({commit}) {\n commit(types.CLEAR_DEFAULT_PROPERTIES_FORM);\n commit(types.SET_DEFAULT_PROPERTIES_FORM_BUSY);\n\n try {\n const responseData = await performApiRequest(commit, 'SET_CUSTOM_FIELDS_LOADING', 'fetchDefaultProperties', () => axios.get('/v1/default-properties'));\n\n commit(types.SET_DEFAULT_PROPERTIES, responseData.defaultProperties);\n commit(types.SET_DEFAULT_PROPERTIES_FORM_BUSY, false);\n } catch (error) {\n push.error({\n message: error?.response?.data?.message || 'There was an error fetching default properties.',\n });\n }\n },\n\n async createDefaultProperties({commit}, defaultProperty: DefaultProperty) {\n commit(types.CLEAR_DEFAULT_PROPERTIES_FORM);\n commit(types.SET_DEFAULT_PROPERTIES_FORM_BUSY);\n\n try {\n const responseData = await performApiRequest(commit, 'SET_CUSTOM_FIELDS_LOADING', 'createCustomFields', () => axios.post('/v1/default-properties', defaultProperty));\n\n commit(types.SET_DEFAULT_PROPERTIES, responseData.defaultProperties);\n\n push.success({\n message: 'Custom Field Created successfully!',\n });\n } catch (error) {\n commit(types.SET_DEFAULT_PROPERTIES_FORM_ERRORS, error?.response?.data?.errors);\n }\n\n commit(types.SET_DEFAULT_PROPERTIES_FORM_BUSY, false);\n },\n\n async updateDefaultProperties({commit}, defaultProperty: DefaultProperty) {\n commit(types.CLEAR_DEFAULT_PROPERTIES_FORM);\n commit(types.SET_DEFAULT_PROPERTIES_FORM_BUSY);\n\n try {\n await performApiRequest(commit, 'SET_CUSTOM_FIELDS_LOADING', 'updateCustomFields', () => axios.put(`/v1/default-properties/${defaultProperty.uuid}`, defaultProperty));\n\n push.success({\n message: 'Custom Field Updated successfully!',\n });\n } catch (error) {\n push.error({\n message: error?.response?.data?.message || 'There was an error saving this default property.',\n });\n commit(types.SET_DEFAULT_PROPERTIES_FORM_ERRORS, error?.response?.data?.message || 'There was an error deleting this custom field.',);\n }\n\n commit(types.SET_DEFAULT_PROPERTIES_FORM_BUSY, false);\n },\n\n async updateDefaultPropertiesPositions({commit}, fields: DefaultProperty[]) {\n commit(types.CLEAR_DEFAULT_PROPERTIES_FORM);\n commit(types.SET_DEFAULT_PROPERTIES_FORM_BUSY);\n\n try {\n await performApiRequest(commit, 'SET_CUSTOM_FIELDS_LOADING', 'updateCustomFields', () => axios.put('/v1/default-properties/positions', {fields}));\n\n push.success({\n message: 'Custom Field positions updated successfully!',\n });\n } catch (error) {\n push.error({\n message: error?.response?.data?.message || 'There was an error saving this default property.',\n });\n commit(types.SET_DEFAULT_PROPERTIES_FORM_ERRORS, error?.response?.data?.message || 'There was an error deleting this custom field.',);\n }\n\n commit(types.SET_DEFAULT_PROPERTIES_FORM_BUSY, false);\n },\n\n async deleteDefaultProperties({commit}, defaultProperty: DefaultProperty) {\n try {\n commit(types.CLEAR_DEFAULT_PROPERTIES_FORM);\n commit(types.SET_DEFAULT_PROPERTIES_FORM_BUSY);\n\n const responseData = await performApiRequest(commit, 'SET_CUSTOM_FIELDS_LOADING', 'deleteCustomFields', () => axios.delete(`/v1/default-properties/${defaultProperty.uuid}`));\n\n commit(types.SET_DEFAULT_PROPERTIES, responseData.defaultProperties);\n\n push.success({\n message: 'Custom Field deleted successfully!',\n });\n } catch (error) {\n commit(types.SET_DEFAULT_PROPERTIES_FORM_BUSY, false);\n push.error({\n message: error?.response?.data?.message || 'There was an error deleting this default property.',\n });\n\n commit(types.SET_DEFAULT_PROPERTIES_FORM_ERRORS, error?.response?.data?.errors || 'There was an error deleting this custom field.',);\n\n throw error;\n }\n\n commit(types.SET_DEFAULT_PROPERTIES_FORM_BUSY, false);\n },\n};\n\nexport default {\n namespaced: true,\n state,\n mutations,\n actions,\n getters,\n};\n","import axios from 'axios';\nimport {EventBus} from '@/plugins/eventBus';\nimport {StorageService} from '@/services/storage.service';\nimport * as types from '../mutation-types';\nimport {performApiRequest} from '@/store/helpers/vuex-helpers';\nimport {ESignerFieldData} from '@/types';\nimport {push} from 'notivue'\n\nexport type DocumentType = {\n created_at: string;\n data: ESignerFieldData[];\n dimensions: { height: number, width: number };\n doc_width: number;\n document_images: string[];\n file_id: string;\n files: string[];\n name: string;\n pages: number;\n pdf_path: string;\n template: any;\n updated_at: string;\n uuid: string;\n}\n\nexport type TemplateData = {\n name: string;\n documents: DocumentType;\n pages: number;\n file_id: string;\n data: ESignerFieldData[];\n version: string | 'v2';\n created_at?: string;\n updated_at?: string;\n uuid?: string;\n custodian?: boolean;\n}\n\nexport interface DocumentState {\n init: boolean;\n loading: Record<string, boolean>;\n users: any[];\n documents: DocumentType[];\n document: DocumentType;\n templates: TemplateData[];\n template?: TemplateData;\n}\n\nconst state: DocumentState = {\n init: false,\n loading: {\n get: false,\n template: false,\n saving: false,\n },\n users: [],\n documents: [],\n document: null,\n templates: [],\n template: null,\n};\n\nconst getters = {\n init: (state: DocumentState) => state.init,\n loading: (state: DocumentState) => state.loading,\n document: (state: DocumentState) => state.document,\n documents: (state: DocumentState) => state.documents,\n templates: (state: DocumentState) => state.templates,\n template: (state: DocumentState) => state.template,\n};\n\nconst mutations = {\n [types.SET_TEMPLATES_LOADING](state: DocumentState, loading: { subject: string, loading: boolean }) {\n state.loading[loading.subject] = loading.loading;\n },\n [types.SET_ONE_DOCUMENT](state: DocumentState, document: DocumentType) {\n state.document = document;\n },\n [types.SET_ALL_DOCUMENTS](state: DocumentState, documents: DocumentType[]) {\n state.documents = documents;\n },\n [types.RESET_TEMPLATE](state: DocumentState) {\n state.template = null;\n state.init = false;\n },\n [types.SET_ONE_TEMPLATE](state: DocumentState, template: TemplateData) {\n state.template = template;\n state.init = true;\n },\n [types.SET_ALL_TEMPLATES](state: DocumentState, templates: TemplateData[]) {\n state.templates = templates;\n },\n};\n\nconst actions = {\n\n /**\n * Fetch a template\n */\n async fetchTemplates({commit}) {\n try {\n const responseData = await performApiRequest(commit, 'SET_TEMPLATES_LOADING', 'get', () => axios.get('/v1/templates'));\n commit(types.SET_ALL_TEMPLATES, responseData.templates);\n } catch (error) {\n }\n },\n\n\n /**\n * Create a template\n *\n */\n createTemplate() {\n axios.post('/v1/templates')\n .then((response) => {\n EventBus.$emit('create-template-success', response?.data?.template);\n }).catch((e) => {\n push.error({\n message: e?.response?.data?.message || 'There was an error',\n });\n }).finally(() => {\n });\n },\n\n\n /**\n * Get a guest template\n */\n getTemplateGuest({commit}, uuid: string) {\n commit('SET_TEMPLATES_LOADING', {subject: 'template', loading: true});\n axios.get(`/v1/templates/${uuid}`)\n .then((response) => {\n EventBus.$emit('get-template-success', response?.data?.template);\n commit(types.SET_ONE_TEMPLATE, response?.data?.template);\n }).catch(() => {\n }).finally(() => {\n commit('SET_TEMPLATES_LOADING', {subject: 'template', loading: false});\n });\n },\n\n\n /**\n * Update a template\n */\n async updateTemplate({commit}, data: { template: TemplateData, actions: any }) {\n try {\n await performApiRequest(commit, 'SET_TEMPLATES_LOADING', 'saving', () => axios.put(`/v1/documents/${data.template.documents.uuid}`, {actions: data.actions}));\n\n push.success({\n message: 'Template updated successfully!',\n });\n } catch (error) {\n }\n },\n\n\n /**\n * Get a document\n */\n getDocument({state, commit, rootGetters}) {\n axios.get(`/v1/company/${rootGetters['company/company'].uuid}/documents/${state.document.uuid}`)\n .then((response) => {\n commit(types.SET_ONE_DOCUMENT, response?.data?.document);\n }).catch(() => {\n }).finally(() => {\n });\n },\n\n\n /**\n * Save a document\n */\n saveDocument({state, commit, rootGetters}, data: object) {\n commit('SET_TEMPLATES_LOADING', {subject: 'saving', loading: true});\n axios.put(`/v1/company/${rootGetters['company/company'].uuid}/documents/${state.document.uuid}`, {\n data,\n document: state.document,\n })\n .then(() => {\n push.success({\n message: 'Document saved successfully!',\n });\n }).catch(() => {\n }).finally(() => {\n commit('SET_TEMPLATES_LOADING', {subject: 'saving', loading: false});\n });\n },\n\n\n /**\n * Update a template documents name\n */\n async updateDocumentName({commit}, name: string) {\n try {\n const responseData = await performApiRequest(commit, 'SET_TEMPLATES_LOADING', 'saving', () => axios.put(`/v1/documents/${state.document.uuid}/name`, {name}));\n\n commit(types.SET_ALL_TEMPLATES, responseData.templates);\n\n push.success({\n message: 'Document name updated successfully!',\n });\n } catch (error) {\n }\n },\n\n\n /**\n * Delete a template document\n */\n deleteDocument({state, commit}) {\n axios.delete(`/v1/company/${StorageService.getCompanyUuid()}/documents/${state.document.uuid}`)\n .then((response) => {\n commit(types.SET_ALL_DOCUMENTS, response?.data?.documents || []);\n\n push.success({\n message: 'Document removed successfully!',\n });\n }).catch(() => {\n }).finally(() => {\n });\n },\n\n\n /**\n * Delete a template\n */\n async deleteTemplate({commit}, template: TemplateData) {\n try {\n const responseData = await performApiRequest(commit, 'SET_TEMPLATES_LOADING', 'deleting', () => axios.delete(`/v1/templates/${template.uuid}`));\n\n commit(types.SET_ALL_TEMPLATES, responseData.templates);\n\n push.success({\n message: 'Template deleted successfully!',\n });\n } catch (error) {\n }\n },\n};\n\nexport default {\n namespaced: true,\n state,\n mutations,\n actions,\n getters,\n};\n","import axios from 'axios';\nimport {EventBus} from '@/plugins/eventBus';\nimport {Form} from '@/plugins/FWForms/index';\nimport * as types from '../mutation-types';\nimport {performApiRequest} from '@/store/helpers/vuex-helpers';\nimport {StoreLoaders} from '@/types';\n\nexport interface EmailTemplate {\n context: string;\n context_type: string;\n created_at: string;\n default: boolean;\n email_body: string;\n email_body_blocks: {\n blocks: any[];\n time?: number;\n version?: string;\n };\n email_layout_id: string;\n identifier: string;\n is_automatic: boolean;\n name: string;\n subject: string;\n updated_at: string;\n uuid: string;\n}\n\nexport type Email = {\n attachments: Array<any>,\n blocks: Array<any>,\n body: string,\n order_id: string,\n recipients: Array<string>,\n subject: string,\n template: {\n name: string,\n subject: string,\n identifier: string,\n uuid: string,\n },\n}\n\ntype EmailHistory = {\n created_at: string,\n email_body: string,\n email_full_body: string,\n email_layout_id: string,\n order_id: string,\n recipients: Array<string>,\n status: string,\n subject: string,\n updated_at: string,\n uuid: string,\n}\n\nexport interface EmailState {\n loading: StoreLoaders,\n emailForm: Form<any>,\n history: EmailHistory[],\n emails: Array<any>,\n emailTemplates: EmailTemplate[],\n emailTemplate: EmailTemplate,\n email: Email,\n}\n\nconst state: EmailState = {\n loading: {\n emails: false,\n createEmail: false,\n sendEmail: false,\n history: false,\n email_templates: false,\n },\n emailForm: new Form(),\n history: [],\n emails: [],\n emailTemplates: [],\n emailTemplate: null,\n email: null,\n};\n\nconst getters = {\n loading: (state: EmailState) => state.loading,\n emailForm: (state: EmailState) => state.emailForm,\n emails: (state: EmailState) => state.emails,\n email: (state: EmailState) => state.email,\n history: (state: EmailState) => state.history,\n emailTemplates: (state: EmailState) => state.emailTemplates,\n emailTemplate: (state: EmailState) => state.emailTemplate,\n};\n\nconst mutations = {\n [types.SET_EMAILS_LOADING](state: EmailState, loading: { subject: string, loading: boolean }) {\n state.loading[loading.subject] = loading.loading;\n },\n [types.SET_EMAILS](state: EmailState, emails: Array<any>) {\n state.emails = emails;\n },\n [types.SET_EMAIL_HISTORY](state: EmailState, emails: EmailHistory[]) {\n state.history = emails;\n },\n [types.SET_EMAIL_TEMPLATES](state: EmailState, templates: EmailTemplate[]) {\n state.emailTemplates = templates;\n },\n [types.SET_EMAIL_TEMPLATE](state: EmailState, template: EmailTemplate) {\n state.emailTemplate = template;\n },\n [types.SET_EMAIL_FORM_ERROR](state: EmailState, error: string | Record<string, string[]>) {\n state.emailForm.errors.set(error);\n },\n [types.CLEAR_EMAIL_FORM_ERRORS](state: EmailState, form_field: string | null = null) {\n if (form_field === null || form_field === undefined) {\n state.emailForm.errors.clear();\n } else {\n state.emailForm.errors.clear(form_field);\n }\n },\n};\n\nconst actions = {\n\n /**\n * Create an email.\n */\n async sendEmail({commit}, email: Email) {\n commit(types.CLEAR_EMAIL_FORM_ERRORS);\n\n try {\n const responseData = await performApiRequest(commit, 'SET_EMAILS_LOADING', 'sendEmail', () => axios.post('/v1/emails/send', email));\n EventBus.$emit('send-email-success', responseData.email);\n } catch (e) {\n const message = e?.response?.data?.errors?.[0] || e?.response?.data?.message || 'There was an error';\n EventBus.$emit('send-email-error', message);\n commit(types.SET_EMAIL_FORM_ERROR, e.response.data?.errors || 'There was an error');\n }\n },\n\n /**\n * Get email history\n */\n async history({commit}, data: { type: string, id: string }) {\n const params = new URLSearchParams(data).toString();\n\n try {\n const responseData = await performApiRequest(commit, 'SET_EMAILS_LOADING', 'history', () => axios.get(`/v1/emails/history?${params}`));\n commit(types.SET_EMAIL_HISTORY, responseData.emails || []);\n } catch (e) {\n }\n },\n\n /**\n * Get email templates\n */\n async getEmailTemplates({commit}, data: { context?: string } = undefined) {\n const qString = data?.context ? `?context=${data.context}` : '';\n\n try {\n const responseData = await performApiRequest(commit, 'SET_EMAILS_LOADING', 'email_templates', () => axios.get(`/v1/email-templates${qString}`));\n commit('SET_EMAIL_TEMPLATES', responseData.emailTemplates || []);\n } catch (error) {\n }\n },\n\n /**\n * Get email template\n */\n async getEmailTemplate({commit}, uuid: string) {\n const responseData = await performApiRequest(commit, 'SET_EMAILS_LOADING', 'email_templates', () => axios.get(`/v1/email-templates/${uuid}`));\n commit(types.SET_EMAIL_TEMPLATE, responseData.emailTemplate || {});\n },\n\n /**\n * Update email template\n */\n async updateEmailTemplate({commit}, emailTemplate: EmailTemplate) {\n try {\n const responseData = await performApiRequest(commit, 'SET_EMAILS_LOADING', 'email_templates', () => axios.put(`/v1/email-templates/${emailTemplate.uuid}`, emailTemplate));\n commit(types.SET_EMAIL_TEMPLATE, responseData.emailTemplate || {});\n return responseData.emailTemplate;\n } catch (error) {\n }\n },\n\n /**\n * Reset email template\n */\n async resetEmailTemplate({commit}, emailTemplate: EmailTemplate) {\n const responseData = await performApiRequest(commit, 'SET_EMAILS_LOADING', 'email_templates', () => axios.post(`/v1/email-templates/${emailTemplate.uuid}/reset`));\n commit(types.SET_EMAIL_TEMPLATE, responseData.emailTemplate || {});\n return responseData.emailTemplate;\n },\n\n /**\n * Send test email template\n */\n async sendTestTemplateEmail({commit}, emailTemplate: EmailTemplate) {\n try {\n await performApiRequest(commit, 'SET_EMAILS_LOADING', 'email_templates', () => axios.post(`/v1/email-templates/${emailTemplate.uuid}/send-test`));\n } catch (error) {\n }\n },\n};\n\nexport default {\n namespaced: true,\n state,\n mutations,\n actions,\n getters,\n};\n","import {EventBus} from '@/plugins/eventBus';\nimport axios from 'axios';\nimport * as types from '@/store/mutation-types';\nimport {performApiRequest} from '@/store/helpers/vuex-helpers';\nimport {push} from 'notivue';\n\n\nexport interface EmailDomainSettingsState {\n loading: Record<string, boolean>;\n emailDomainSettings: EmailDomainSettings[];\n}\n\nexport interface EmailDomainSettings {\n DKIMHost: string;\n DKIMPendingHost: string;\n DKIMPendingTextValue: string;\n DKIMTextValue: string;\n DKIMUpdateStatus: string;\n DKIMVerified: boolean;\n ReturnPathDomain: string;\n ReturnPathDomainCNAMEValue: string;\n ReturnPathDomainVerified: boolean;\n SPFHost: string;\n SPFTextValue: string;\n SPFVerified: boolean;\n WeakDKIM: boolean;\n active: boolean;\n created_at: string;\n domain: string;\n email: string;\n pm_id: number;\n updated_at: string;\n uuid: string;\n}\n\nconst state: EmailDomainSettingsState = {\n loading: {\n deletingEmailDomain: false,\n creatingEmailDomain: false,\n checkingReturnPathStatus: false,\n sendingTestEmail: false,\n },\n emailDomainSettings: [],\n};\n\nconst getters = {\n loading: (state: EmailDomainSettingsState) => state.loading,\n emailDomainSettings: (state: EmailDomainSettingsState) => state.emailDomainSettings,\n};\n\nconst mutations = {\n [types.SET_COMPANY_LOADING](state: EmailDomainSettingsState, loading: { subject: string, loading: boolean }) {\n state.loading[loading.subject] = loading.loading;\n },\n [types.SET_EMAIL_DOMAIN_SETTINGS](state: EmailDomainSettingsState, domains: EmailDomainSettings[]) {\n state.emailDomainSettings = domains;\n },\n};\n\nconst actions = {\n\n /**\n * Get the email domains\n */\n async fetchEmailDomain({commit}) {\n try {\n const responseData = await performApiRequest(commit, 'SET_COMPANY_LOADING', 'company', () => axios.get('/v1/email-domain-settings'));\n commit('SET_EMAIL_DOMAIN_SETTINGS', responseData.domains);\n } catch (error) {\n }\n },\n\n /**\n * Create a email domain\n */\n async createEmailDomain({commit}, domain: string) {\n try {\n const responseData = await performApiRequest(commit, 'SET_COMPANY_LOADING', 'creatingEmailDomain', () => axios.post('/v1/email-domain-settings', {domain}));\n commit('SET_EMAIL_DOMAIN_SETTINGS', responseData.domains);\n EventBus.$emit('create-email-domain-success');\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'Email domain added',\n });\n } catch (error) {\n EventBus.$emit('create-email-domain-error', error?.response?.data?.message || 'There was an error');\n }\n },\n\n async deleteEmailDomain({commit}, domain: EmailDomainSettings) {\n try {\n const responseData = await performApiRequest(commit, 'SET_COMPANY_LOADING', 'deletingEmailDomain', () => axios.delete(`/v1/email-domain-settings/${domain.uuid}`));\n commit('SET_EMAIL_DOMAIN_SETTINGS', responseData.domains);\n EventBus.$emit('delete-email-domain-success');\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'Email domain deleted',\n });\n } catch (error) {\n EventBus.$emit('create-email-domain-error', error?.response?.data?.message || 'There was an error');\n }\n },\n\n async emailDomainCheckDKIM({commit}, domain: EmailDomainSettings) {\n try {\n const responseData = await performApiRequest(commit, 'SET_COMPANY_LOADING', 'deletingEmailDomain', () => axios.get(`/v1/email-domain-settings/${domain.uuid}/check-dkim`));\n commit('SET_EMAIL_DOMAIN_SETTINGS', responseData.domains);\n } catch (error) {\n }\n },\n\n async emailDomainCheckReturnPathStatus({commit}, domain: EmailDomainSettings) {\n try {\n const responseData = await performApiRequest(commit, 'SET_COMPANY_LOADING', 'checkingReturnPathStatus', () => axios.get(`/v1/email-domain-settings/${domain.uuid}/check-return-path-status`));\n commit('SET_EMAIL_DOMAIN_SETTINGS', responseData.domains);\n } catch (error) {\n }\n },\n\n async updateEmailDomainUsername({commit}, domain: EmailDomainSettings) {\n try {\n const responseData = await performApiRequest(commit, 'SET_COMPANY_LOADING', 'checkingReturnPathStatus', () => axios.put(`/v1/email-domain-settings/${domain.uuid}`, {email: domain.email}));\n commit('SET_EMAIL_DOMAIN_SETTINGS', responseData.domains);\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'Email username updated',\n });\n } catch (error) {\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n }\n },\n\n async setAsDefaultSendingDomain({commit}, domain: EmailDomainSettings) {\n if (domain.uuid) {\n try {\n const responseData = await performApiRequest(commit, 'SET_COMPANY_LOADING', 'creatingEmailDomain', () => axios.post(`/v1/email-domain-settings/${domain.uuid}/set-default`));\n commit('SET_EMAIL_DOMAIN_SETTINGS', responseData.domains);\n } catch (error) {\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n }\n } else {\n\n try {\n const responseData = await performApiRequest(commit, 'SET_COMPANY_LOADING', 'creatingEmailDomain', () => axios.post('/v1/email-domain-settings/set-default'));\n commit('SET_EMAIL_DOMAIN_SETTINGS', responseData.domains);\n } catch (error) {\n }\n }\n },\n\n async sendTestEmail({commit}, email: string) {\n try {\n await performApiRequest(commit, 'SET_COMPANY_LOADING', 'sendingTestEmail', () => axios.post('/v1/email-domain-settings/send-test-email', {email}));\n EventBus.$emit('send-test-email-success');\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: `Test email sent to ${email}`,\n });\n } catch (error) {\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n }\n },\n};\n\nexport default {\n namespaced: true,\n state,\n mutations,\n actions,\n getters,\n};\n","import axios from 'axios';\nimport {EventBus} from '@/plugins/eventBus';\nimport {get} from 'lodash';\nimport {Form} from '@/plugins/FWForms/index';\nimport * as types from '../mutation-types';\nimport {performApiRequest} from '@/store/helpers/vuex-helpers';\nimport {createUrlQueryString} from '@/utils/urls';\nimport {ESignerFieldData, RenterInterface, StoreLoaders} from '@/types';\nimport {TemplateData} from '@/store/modules/document';\n\n\nexport interface EnvelopeRecipientsInterface {\n completed_at: string;\n created_at: string;\n data: ESignerFieldData[];\n envelope_id_stamped: string;\n opened_at: string;\n recipient: string;\n renter: RenterInterface;\n sent_at: string;\n signature: string;\n signature_style: string;\n status: string;\n template_id: string;\n updated_at: string;\n uuid: string;\n}\n\nexport interface EnvelopeInterface {\n attachments: EnvelopeAttachmentInterface[];\n completed: boolean;\n completed_at: string;\n created_at: string;\n data: ESignerFieldData[];\n file_path: string;\n opened: boolean;\n opened_at: string;\n order_document: string;\n pdf_path: string;\n pdf_url: string;\n recipient_uuid: string;\n recipients: EnvelopeRecipientsInterface[];\n renter: RenterInterface;\n signature: any;\n status: string;\n updated_at: string;\n white_label: boolean;\n uuid: string;\n template?: TemplateData;\n logs?: {\n created_at: string;\n action: string;\n ip: string;\n actor: string;\n }[];\n}\n\nexport interface SaveProgressPayload {\n uuid: string,\n recipientId: string,\n allSigned: boolean,\n ip: string,\n data: ESignerFieldData[],\n sample?: boolean\n}\n\n// AcceptEnvelopePayload extends SaveProgressPayload\nexport interface AcceptEnvelopePayload extends SaveProgressPayload {\n recipientKey: string\n}\n\nexport interface SaveSignaturePayload {\n uuid: string,\n recipientId: string,\n signature: string,\n sample?: boolean,\n mode: 'draw' | 'typed',\n recipientKey: string\n}\n\nexport interface RemoveAttachmentPayload {\n attachmentId: string;\n uuid: string;\n recipientId: string;\n sample?: boolean;\n}\n\nexport interface EnvelopeAttachmentInterface {\n attachment_id: string;\n document_images: string[];\n envelope_id: number;\n name: string;\n order: number;\n created_at?: string;\n updated_at?: string;\n url?: string;\n uuid?: string;\n}\n\nexport interface EnvelopePagination {\n count: number;\n current_page: number;\n next_page: string;\n per_page: number;\n total: number;\n total_pages: string;\n from: number;\n to: number;\n last_page: number;\n total_envelopes: number;\n}\n\ninterface EnvelopeResponse {\n data: EnvelopeInterface[];\n meta: EnvelopePagination;\n links: object;\n}\n\nexport interface EnvelopePage {\n page: number;\n pageData: ESignerFieldData[];\n path: string; // URL to the page image\n}\n\ninterface EsignSessionData {\n ip: string;\n windowWidth?: number;\n contentMainWidth: number;\n contentMainHeight: number;\n remainingFieldsCount: number;\n envelopeId: string;\n recipientId: string;\n recipientKey: string;\n totalFields: number;\n}\n\nexport interface EnvelopeState {\n envelopesPagination: {\n current_page: number;\n from: number;\n last_page: number;\n per_page: number;\n to: number;\n total: number;\n total_envelopes: number;\n },\n init: boolean;\n loading: StoreLoaders;\n document: any[];\n template: any;\n envelopes: EnvelopeInterface[];\n envelope: EnvelopeInterface;\n envelopeIsReady: boolean;\n allEnvelopeData: ESignerFieldData[];\n envelopeForm: Form<object>;\n envelopeCustomer: any;\n envelopeDialogs: Record<string, boolean>;\n envelopesQuery?: {\n page?: number,\n itemsPerPage?: number,\n sortBy?: string[],\n sortDesc?: boolean[],\n filter?: {\n tag_list?: string[],\n archived?: boolean,\n search?: string,\n status?: string[],\n date?: {\n gte?: string,\n lte?: string,\n }\n },\n include?: string,\n },\n esignSessionData: EsignSessionData,\n esignEnvelopeDataCopy: EnvelopePage[],\n}\n\nconst state: EnvelopeState = {\n init: false,\n loading: {\n envelope: false,\n envelopes: false,\n saving: false,\n accepting: false,\n voiding: false,\n createEnvelope: false,\n saveSignature: false,\n deleteAttachment: false,\n resetEnvelopeData: false,\n savingProgress: false,\n resendEnvelope: false,\n reminder: false,\n },\n document: [],\n template: {},\n envelopes: [],\n envelope: null,\n envelopeIsReady: false,\n allEnvelopeData: [],\n envelopeForm: new Form(),\n envelopeCustomer: {},\n envelopeDialogs: {\n newEnvelope: false,\n },\n\n envelopesQuery: {\n page: 1,\n itemsPerPage: 25,\n sortBy: ['created_at'],\n sortDesc: [true],\n filter: {\n tag_list: [],\n archived: false,\n search: '',\n status: [],\n date: {\n gte: '',\n lte: '',\n }\n },\n include: '',\n },\n envelopesPagination: {\n current_page: 0,\n from: 0,\n last_page: 0,\n per_page: 0,\n to: 0,\n total: 0,\n total_envelopes: 0,\n },\n esignSessionData: {\n ip: '',\n totalFields: 0,\n windowWidth: window.innerWidth,\n contentMainWidth: 0,\n contentMainHeight: 0,\n remainingFieldsCount: 0,\n envelopeId: null,\n recipientId: null,\n recipientKey: null,\n },\n esignEnvelopeDataCopy: [],\n};\n\nconst getters = {\n init: (state: EnvelopeState) => state.init,\n envelopeDialogs: (state: EnvelopeState) => state.envelopeDialogs,\n esignSessionData: (state: EnvelopeState) => state.esignSessionData,\n esignEnvelopeDataCopy: (state: EnvelopeState) => state.esignEnvelopeDataCopy,\n loading: (state: EnvelopeState) => state.loading,\n document: (state: EnvelopeState) => state.document,\n template: (state: EnvelopeState) => state.template,\n envelopes: (state: EnvelopeState) => state.envelopes,\n envelope: (state: EnvelopeState) => state.envelope,\n envelopeIsReady: (state: EnvelopeState) => state.envelopeIsReady,\n allEnvelopeData: (state: EnvelopeState) => state.allEnvelopeData,\n envelopeForm: (state: EnvelopeState) => state.envelopeForm,\n envelopeCustomer: (state: EnvelopeState) => state.envelopeCustomer,\n envelopesQuery: (state: EnvelopeState) => state.envelopesQuery,\n envelopesPagination: (state: EnvelopeState) => state.envelopesPagination,\n};\n\nconst mutations = {\n [types.SET_ENVELOPE_LOADING](state: EnvelopeState, loading: { subject: string, loading: boolean }) {\n state.loading[loading.subject] = loading.loading;\n },\n [types.SET_ESIGN_SESSION_DATA](state: EnvelopeState, data: { key: string, value: any } | Record<string, any>) {\n if (typeof data.key === 'string' && data.hasOwnProperty('value')) {\n // Single key-value pair update\n if (!state.esignSessionData.hasOwnProperty(data.key)) {\n console.error(`Key \"${data.key}\" does not exist in esignSessionData.`);\n return;\n }\n state.esignSessionData[data.key] = data.value;\n } else if (typeof data === 'object') {\n // Multiple key-value pair updates\n Object.entries(data).forEach(([key, value]) => {\n if (!state.esignSessionData.hasOwnProperty(key)) {\n console.warn(`Key \"${key}\" does not exist in esignSessionData.`);\n return;\n }\n state.esignSessionData[key] = value;\n });\n } else {\n console.error('Invalid data format for SET_ESIGN_SESSION_DATA mutation.');\n }\n },\n\n [types.SET_ALL_ENVELOPES](state: EnvelopeState, envelopes: EnvelopeResponse) {\n console.dir('SET_ALL_ENVELOPES');\n console.dir(envelopes);\n state.envelopes = envelopes.data;\n\n const meta = envelopes?.meta;\n if (meta) {\n state.envelopesPagination = {\n current_page: meta.current_page,\n from: meta.from,\n last_page: meta.last_page,\n per_page: meta.per_page,\n to: meta.to,\n total: meta.total,\n total_envelopes: meta.total_envelopes,\n }\n }\n },\n [types.SET_ENVELOPE](state: EnvelopeState, envelope: EnvelopeInterface) {\n state.envelope = envelope;\n state.envelopeIsReady = true;\n },\n [types.SET_ENVELOPE_SIGNATURE](state: EnvelopeState, signature) {\n state.envelope.signature = signature;\n },\n [types.SET_ENVELOPE_CUSTOMER](state: EnvelopeState, customer) {\n state.envelopeCustomer = customer;\n },\n [types.UPDATE_ENVELOPE_FIELD](state: EnvelopeState, data: ESignerFieldData) {\n console.dir('UPDATE_ENVELOPE_FIELD');\n console.dir(data);\n\n const pageIndex = data.page - 1;\n const pageData = state.esignEnvelopeDataCopy[pageIndex].pageData;\n const fieldIndex = pageData.findIndex((f: ESignerFieldData) => f.id === data.id);\n\n if (fieldIndex !== -1) {\n state.esignEnvelopeDataCopy[pageIndex].pageData[fieldIndex] = {...pageData[fieldIndex], ...data};\n }\n },\n [types.SET_ALL_FIELDS](state: EnvelopeState, payload: { data: ESignerFieldData[], pageImages: string[] }) {\n console.dir('SET_ALL_FIELDS');\n console.dir(payload);\n state.allEnvelopeData = payload.data;\n\n\n const fields = payload.data.sort((a, b) => a.page - b.page);\n\n state.esignEnvelopeDataCopy = payload.pageImages.map((p, index) => {\n const pageNumber = index + 1;\n let pageData = fields.filter((f) => f.page === pageNumber) || [];\n\n pageData = pageData.map((d) => {\n const data = d;\n const updated = d?.updated;\n const title = d?.title;\n\n if (d.type === 'field') {\n const filled = get(d, 'filled', false);\n return {\n ...data,\n filled,\n text: filled ? data.text : '',\n placeholder: data.text,\n toolTip: data.text,\n title: title || data.text,\n };\n }\n if (d.type === 'text') {\n return {\n ...data,\n filled: d?.filled || true,\n placeholder: data.text,\n text: data.readOnly || updated ? data.text : '',\n title: title || data.text,\n };\n }\n if (d.type === 'attachment') {\n return {\n ...data,\n attached: d?.attached || false,\n filled: d?.filled || false,\n url: d?.url || null,\n };\n }\n if (d.type === 'checkbox') {\n return {\n ...data,\n toolTip: data.fieldName,\n };\n }\n\n return {\n ...d,\n signed: false,\n filled: false,\n src: '',\n toolTip: 'Sign Here',\n };\n });\n\n return {\n page: pageNumber,\n path: p,\n pageData,\n }\n });\n },\n [types.SET_ENVELOPE_DIALOG](state: EnvelopeState, data: { key: string, value: boolean }) {\n state.envelopeDialogs[data.key] = data.value;\n },\n [types.SET_ENVELOPE_QUERY](state: EnvelopeState, data) {\n console.dir('SET_ENVELOPE_QUERY');\n console.dir(data);\n\n state.envelopesQuery[data.key] = data.value;\n },\n};\n\nconst actions = {\n\n /**\n * Get an envelope\n * @throws {Error}\n */\n async getEnvelopeV2({commit}, {uuid, recipientId, recipientKey, sample}: {\n uuid: string;\n recipientId: string;\n recipientKey?: string;\n sample?: boolean;\n }) {\n const queryParams = new URLSearchParams();\n if (sample) queryParams.append('sample', 'true');\n if (recipientKey) queryParams.append('key', recipientKey);\n\n\n // Determine request path\n const queryString = queryParams.toString() ? `?${queryParams.toString()}` : '';\n const requestPath = sample ? `/sample/${queryString}` : `${queryString}`;\n\n const responseData = await performApiRequest(commit, 'SET_ENVELOPE_LOADING', 'getEnvelope', () => axios.get(`/v1/envelope-v2/${uuid}/${recipientId}${requestPath}`));\n const envelope = responseData?.envelope ?? [];\n const envelopeCustomer = responseData?.envelopeCustomer ?? {};\n const customerData = envelopeCustomer?.data ?? envelope?.data ?? [];\n console.log(`customerData is array: ${Array.isArray(customerData)}`);\n\n commit(types.SET_ALL_FIELDS, {\n data: customerData,\n pageImages: envelope?.template?.documents?.document_images ?? []\n });\n commit(types.SET_ENVELOPE, envelope);\n commit(types.SET_ENVELOPE_CUSTOMER, envelopeCustomer);\n },\n\n /**\n * Reset an envelope\n */\n async getEnvelopes({commit}) {\n console.dir('getEnvelopes');\n try {\n const options = state.envelopesQuery;\n\n const {sortBy = [], sortDesc = [], filter = {}} = options;\n\n const queryObject = {\n 'sort': sortBy.length > 0 ? (sortDesc?.[0] ? `-${sortBy[0]}` : sortBy[0]) : null,\n 'filter[tag_list]': filter.tag_list || null,\n 'filter[archived]': filter.archived ?? null,\n 'filter[q]': filter.search || null,\n 'filter[status]': filter.status || null,\n 'page': options.page || 1,\n 'itemsPerPage': options.itemsPerPage || 30,\n 'include': options.include,\n 'filter[date][gte]': filter?.date?.gte || null,\n 'filter[date][lte]': filter?.date?.lte || null,\n };\n\n // Convert the object into a query string\n const query = createUrlQueryString(queryObject, true);\n console.log('✅ API Query String:', query);\n\n const responseData = await performApiRequest(commit, 'SET_ENVELOPE_LOADING', 'envelopes', () => axios.get(`/v1/envelope${query}`));\n commit(types.SET_ALL_ENVELOPES, responseData);\n } catch (error) {\n }\n },\n\n async createEnvelope({commit}, data) {\n try {\n const responseData = await performApiRequest(commit, 'SET_ENVELOPE_LOADING', 'createEnvelope', () => axios.post('/v1/envelope', data));\n commit(types.SET_ENVELOPE, responseData.envelope);\n EventBus.$emit('create-envelope-success');\n } catch (error) {\n EventBus.$emit('SystemMessage', {\n type: 'error',\n message: error?.response?.data?.message || 'There was an error.',\n });\n }\n },\n\n\n /**\n * Reset an envelope\n */\n resetEnvelopeData({commit}, uuid: string) {\n commit('SET_ENVELOPE_LOADING', {subject: 'resetEnvelopeData', loading: true});\n\n axios.post(`/v1/envelope/${uuid}/reset`)\n .then((response) => {\n commit(types.SET_ENVELOPE, get(response, 'data.envelope', []));\n }).catch((e) => {\n EventBus.$emit('SystemMessage', {\n type: 'error',\n message: get(e, 'response.data.message', 'There was an error.'),\n });\n }).finally(() => {\n commit('SET_ENVELOPE_LOADING', {subject: 'resetEnvelopeData', loading: false});\n });\n },\n\n /**\n * Resend an envelope\n */\n resendEnvelope({commit}, {uuid, recipients}) {\n commit('SET_ENVELOPE_LOADING', {subject: 'resendEnvelope', loading: true});\n\n axios.post(`/v1/envelope/${uuid}/resend`, {recipients})\n .then(() => {\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'Resend successful',\n });\n }).catch((e) => {\n EventBus.$emit('SystemMessage', {\n type: 'error',\n message: get(e, 'response.data.message', 'There was an error.'),\n });\n }).finally(() => {\n commit('SET_ENVELOPE_LOADING', {subject: 'resendEnvelope', loading: false});\n });\n },\n\n\n /**\n * Save an envelope customer signature\n */\n async saveSignature({state, commit}, data: SaveSignaturePayload) {\n\n let queryString = '';\n if (get(data, 'sample')) {\n queryString = '/sample';\n }\n\n try {\n const responseData = await performApiRequest(commit, 'SET_ENVELOPE_LOADING', 'saveSignature', () => axios.post(`/v1/envelope/${data.uuid}/${data.recipientId}/signature${queryString}`, data));\n EventBus.$emit('saved-signature-success', responseData);\n commit(types.SET_ENVELOPE_SIGNATURE, responseData.envelope.signature || '');\n commit(types.SET_ENVELOPE_CUSTOMER, responseData.customer);\n\n state.envelopeForm.finishProcessing();\n } catch (error) {\n }\n },\n\n async removeAttachment({commit}, data: RemoveAttachmentPayload) {\n let queryString = '';\n if (get(data, 'sample')) {\n queryString = '/sample';\n }\n return await performApiRequest(commit, 'SET_ENVELOPE_LOADING', 'deleteAttachment', () => axios.delete(`/v1/envelope/${data.uuid}/${data.recipientId}/attachment/${data.attachmentId}${queryString}`));\n },\n\n /**\n * Saves the progress of the e-sign document\n */\n async saveProgress({commit}, data: SaveProgressPayload) {\n return await performApiRequest(commit, 'SET_ENVELOPE_LOADING', 'savingProgress', () => axios.put(`/v1/envelope/${data.uuid}/${data.recipientId}`, data));\n },\n\n /**\n * Prints the progress of the e-sign document\n * Handy for signing on paper\n */\n printProgress({commit}, data) {\n commit('SET_ENVELOPE_LOADING', {subject: 'savingProgress', loading: true});\n axios.post(`/v1/envelope/${data.uuid}/${data.recipientId}/print`, data)\n .then((response) => {\n EventBus.$emit('esign-progress-printed-success', response);\n }).catch(() => {\n }).finally(() => {\n commit('SET_ENVELOPE_LOADING', {subject: 'savingProgress', loading: false});\n });\n },\n\n\n /**\n * Accept agreement and sign\n * @throws {Error}\n */\n async acceptAndSignV2({commit}, data: AcceptEnvelopePayload) {\n const responseData = await performApiRequest(commit, 'SET_ENVELOPE_LOADING', 'accepting', () => axios.post(`/v1/envelope-v2/${data.uuid}/${data.recipientId}/accept`, data));\n commit(types.SET_ENVELOPE, responseData.envelope);\n },\n\n async voidEnvelope({state, commit}, envelope: EnvelopeInterface) {\n try {\n await performApiRequest(commit, 'SET_ENVELOPE_LOADING', 'voiding', () => axios.post(`/v1/envelope/${envelope.uuid}/void`));\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'Envelope voided successfully!',\n });\n } catch (error) {\n state.envelopeForm.errors.set(error?.response?.data?.errors || []);\n }\n },\n\n\n async downloadProgress({state, commit}, envelope: EnvelopeInterface) {\n try {\n const responseData = await performApiRequest(commit, 'SET_ENVELOPE_LOADING', 'downloading-progress', () => axios.post(`/v1/envelope/${envelope.uuid}/download-progress`));\n window.open(responseData.url, '_blank');\n } catch (error) {\n state.envelopeForm.errors.set(error?.response?.data?.errors || []);\n }\n },\n\n sendReminder({state, commit}, data: { envelope: EnvelopeInterface, email: string }) {\n commit('SET_ENVELOPE_LOADING', {subject: 'reminder', loading: true});\n\n axios.post(`/v1/envelope/${data.envelope.uuid}/reminder`, {email: data.email})\n .then((response) => {\n EventBus.$emit('envelope-reminder-success', get(response, 'data.envelope', []));\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'Envelope reminder sent successfully!',\n });\n }).catch((e) => {\n state.envelopeForm.errors.set(get(e, 'response.data.errors', []));\n }).finally(() => {\n commit('SET_ENVELOPE_LOADING', {subject: 'reminder', loading: false});\n });\n },\n};\n\nexport default {\n namespaced: true,\n state,\n mutations,\n actions,\n getters,\n};\n","import * as types from '../mutation-types';\nimport axios from 'axios';\nimport { createUrlQueryString } from '@/utils/urls';\nimport { performApiRequest } from \"@/store/helpers/vuex-helpers\";\n\n\ntype FilePayload = {\n objectType: string,\n objectId: string,\n page?: number,\n}\n\ntype File = {\n created_at: string,\n disk: string,\n extension: string,\n hash: string,\n mime_type: string,\n name: string,\n object_id: string,\n object_type: string,\n original_name: string,\n path: string,\n size: string,\n updated_at: string,\n uuid: string,\n};\n\ntype Pagination = {\n current_page: number,\n first_page_url: string,\n from: number,\n last_page: number,\n last_page_url: string,\n next_page_url: string,\n path: string,\n per_page: number,\n prev_page_url: string,\n to: number,\n total: number,\n}\n\nexport interface FilesState {\n loading: Record<string, boolean>,\n files: File[],\n pagination: Pagination | null,\n}\n\n// state\nconst state: FilesState = {\n loading: {\n getFiles: false,\n deleteFiles: false,\n },\n files: [],\n pagination: null,\n};\n\n// getters\nconst getters = {\n loading: (state: FilesState) => state.loading,\n files: (state: FilesState) => state.files,\n pagination: (state: FilesState) => state.pagination,\n};\n\n// mutations\nconst mutations = {\n [types.SET_FILES_LOADING](state: FilesState, loading: { subject: string, loading: boolean }) {\n state.loading[loading.subject] = loading.loading;\n },\n [types.SET_FILES](state: FilesState, files: File[]) {\n state.files = files;\n },\n [types.SET_FILES_PAGINATION](state: FilesState, pagination) {\n // Cloning pagination object\n const newPagination = { ...pagination };\n delete newPagination.data;\n delete newPagination.links;\n\n state.pagination = newPagination;\n },\n\n [types.MERGE_FILES](state: FilesState, files: File[]): void {\n // merge unique files and order by created_at\n const uniqueFiles = new Set<string>();\n const mergedFiles = [...state.files, ...files].filter(file => {\n const isUnique = !uniqueFiles.has(file.uuid);\n uniqueFiles.add(file.uuid);\n return isUnique;\n });\n\n mergedFiles.sort((a, b) => Date.parse(b.created_at) - Date.parse(a.created_at));\n state.files = mergedFiles;\n },\n};\n\n// actions\nconst actions = {\n\n /**\n * Get company files\n */\n async getFiles({ commit }, payload: FilePayload) {\n try {\n const queryString = createUrlQueryString(payload);\n\n const responseData = await performApiRequest(commit, 'SET_FILES_LOADING','getFiles', () => axios.get(`/v1/company-files${queryString}`));\n commit('MERGE_FILES', responseData.data);\n commit('SET_FILES_PAGINATION', responseData);\n } catch (error) {\n }\n },\n\n /**\n * Delete a company file\n */\n async deleteFile({ commit }, uuid: string) {\n try {\n await performApiRequest(commit, 'SET_FILES_LOADING','deleteFiles', () => axios.delete(`/v1/company-files/${uuid}`));\n commit('SET_FILES', state.files.filter((file) => file.uuid !== uuid));\n } catch (error) {\n }\n },\n};\n\n\nexport default {\n namespaced: true,\n state,\n mutations,\n actions,\n getters,\n};\n","import axios from 'axios';\nimport * as types from '../mutation-types';\nimport {TenantActionItem, TenantBranch} from '@/types';\nimport {performApiRequest} from '@/store/helpers/vuex-helpers';\nimport Form from '@/plugins/FWForms';\nimport {push} from 'notivue'\n\nexport interface FleetState {\n loading: Record<string, boolean>,\n branches: TenantBranch[],\n branch: TenantBranch,\n actionItems: TenantActionItem[],\n actionItem: TenantActionItem\n actionItemDeleted: boolean\n newlyCreatedActionItem: TenantActionItem\n fleetForm: Form<any>,\n}\n\nconst state: FleetState = {\n loading: {\n branches: false,\n createBranch: false,\n fetchBranch: false,\n updateBranch: false,\n actionItem: false,\n actionItems: false,\n },\n fleetForm: new Form(),\n branches: [],\n branch: null,\n actionItems: [],\n actionItem: null,\n newlyCreatedActionItem: null,\n actionItemDeleted: false,\n};\n\nconst getters = {\n loading: (state: FleetState) => state.loading,\n fleetForm: (state: FleetState) => state.fleetForm,\n branches: (state: FleetState) => state.branches,\n branch: (state: FleetState) => state.branch,\n actionItems: (state: FleetState) => state.actionItems,\n actionItem: (state: FleetState) => state.actionItem,\n actionItemDeleted: (state: FleetState) => state.actionItemDeleted,\n newlyCreatedActionItem: (state: FleetState) => state.newlyCreatedActionItem,\n};\n\nconst mutations = {\n [types.SET_COMPANY_BRANCHES_LOADING](state: FleetState, loading: { subject: string, loading: boolean }) {\n state.loading[loading.subject] = loading.loading;\n },\n [types.SET_COMPANY_BRANCHES](state: FleetState, branches: TenantBranch[]) {\n state.branches = branches;\n },\n [types.SET_COMPANY_BRANCH](state: FleetState, branch: TenantBranch) {\n state.branch = branch;\n },\n [types.SET_ACTION_ITEMS](state: FleetState, items: TenantActionItem[]) {\n state.actionItems = items;\n },\n [types.SET_ACTION_ITEM](state: FleetState, item: TenantActionItem) {\n state.actionItem = item;\n },\n [types.ACTION_ITEM_CREATED](state: FleetState, item: TenantActionItem) {\n state.newlyCreatedActionItem = item;\n },\n [types.ACTION_ITEM_DELETED](state: FleetState, value: boolean) {\n state.actionItemDeleted = value;\n\n // Reset the value after 2 seconds\n setTimeout(() => {\n state.actionItemDeleted = false;\n }, 2000);\n },\n [types.SET_FLEET_FORM_ERROR](state: FleetState, error: string | Record<string, string[]>) {\n state.fleetForm.errors.set(error);\n },\n [types.CLEAR_FLEET_FORM_ERRORS](state: FleetState, form_field: string | null = null) {\n if (form_field === null || form_field === undefined) {\n state.fleetForm.errors.clear();\n } else {\n state.fleetForm.errors.clear(form_field);\n }\n },\n};\n\nconst actions = {\n\n /**\n * Get fleet branches.\n */\n async getFleetBranches({commit}) {\n const responseData = await performApiRequest(commit, 'SET_COMPANY_BRANCHES_LOADING', 'branches', () => axios.get('/v1/branches'));\n commit(types.SET_COMPANY_BRANCHES, responseData.branches);\n },\n\n\n /**\n * Create a fleet branch.\n */\n async createBranch({commit}, branch: TenantBranch) {\n try {\n const responseData = await performApiRequest(commit, 'SET_COMPANY_BRANCHES_LOADING', 'createBranch', () => axios.post('/v1/branches', branch));\n commit('SET_COMPANY_BRANCHES', responseData.branches);\n } catch (error) {\n throw error;\n }\n },\n\n\n /**\n * Delete a fleet branch.\n */\n async deleteBranch({commit}, uuid: string) {\n try {\n const responseData = await performApiRequest(commit, 'SET_COMPANY_BRANCHES_LOADING', 'createBranch', () => axios.delete(`/v1/branches/${uuid}`));\n commit('SET_COMPANY_BRANCHES', responseData.branches);\n } catch (error) {\n push.error({\n message: error?.response?.data?.message || 'Failed to delete branch',\n });\n throw error;\n }\n },\n\n /**\n * Get a fleet branch.\n */\n async getFleetBranch({commit}, uuid: string) {\n try {\n const responseData = await performApiRequest(commit, 'SET_COMPANY_BRANCHES_LOADING', 'fetchBranch', () => axios.get(`/v1/branches/${uuid}`));\n commit('SET_COMPANY_BRANCH', responseData.branch);\n } catch (error) {\n }\n },\n\n /**\n * Delete a fleet branch.\n */\n async updateFleetBranch({commit}, branch: TenantBranch) {\n try {\n const responseData = await performApiRequest(commit, 'SET_COMPANY_BRANCHES_LOADING', 'updateBranch', () => axios.put(`/v1/branches/${branch.uuid}`, branch));\n commit('SET_COMPANY_BRANCH', responseData.branch);\n push.success({\n message: 'Branch saved successfully',\n });\n return responseData.branch;\n } catch (error) {\n push.error({\n message: 'Failed to save branch',\n });\n }\n },\n\n\n /**\n * Get action items.\n *\n */\n async getActionItems({commit}) {\n try {\n const responseData = await performApiRequest(commit, 'SET_COMPANY_BRANCHES_LOADING', 'actionItems', () => axios.get('/v1/action-items'));\n commit('SET_ACTION_ITEMS', responseData.actionItems);\n } catch (error) {\n }\n },\n\n\n /**\n * Get action items.\n */\n async getActionItem({commit}, uuid: string) {\n try {\n const responseData = await performApiRequest(commit, 'SET_COMPANY_BRANCHES_LOADING', 'actionItems', () => axios.get(`/v1/action-items/${uuid}`));\n commit('SET_ACTION_ITEM', responseData.actionItem);\n } catch (error) {\n }\n },\n\n /**\n * Create action item.\n */\n async createActionItem({commit}, actionItem: TenantActionItem) {\n try {\n const responseData = await performApiRequest(commit, 'SET_COMPANY_BRANCHES_LOADING', 'actionItem', () => axios.post('/v1/action-items', actionItem));\n commit(types.ACTION_ITEM_CREATED, responseData.actionItem);\n push.success({\n message: 'Action Item created successfully',\n });\n } catch (error) {\n commit(types.SET_FLEET_FORM_ERROR, error.response.data.errors)\n }\n },\n\n /**\n * Update action item.\n */\n async updateActionItem({commit}, actionItem: TenantActionItem) {\n try {\n await performApiRequest(commit, 'SET_COMPANY_BRANCHES_LOADING', 'actionItems', () => axios.put(`/v1/action-items/${actionItem.uuid}`, actionItem));\n push.success({\n message: 'Action Item saved successfully',\n });\n } catch (error) {\n commit(types.SET_FLEET_FORM_ERROR, error.response.data.errors)\n }\n },\n\n /**\n * Delete action item.\n */\n async deleteActionItem({commit}, actionItem: TenantActionItem) {\n try {\n await performApiRequest(commit, 'SET_COMPANY_BRANCHES_LOADING', 'actionItem', () => axios.delete(`/v1/action-items/${actionItem.uuid}`));\n commit(types.ACTION_ITEM_DELETED, true);\n push.success({\n message: 'Action Item deleted successfully',\n });\n } catch (error) {\n }\n },\n};\n\nexport default {\n namespaced: true,\n state,\n mutations,\n actions,\n getters,\n};\n","import axios from 'axios';\nimport {findIndex, get} from 'lodash';\nimport {EventBus} from '@/plugins/eventBus';\nimport {StorageService} from '@/services/storage.service';\nimport * as types from '../mutation-types';\nimport {Connection} from '@/types';\nimport {performApiRequest} from '@/store/helpers/vuex-helpers';\n\ntype GetaroundConnection = Connection & {\n gaid?: string;\n}\n\nexport interface GetaroundState {\n init: boolean;\n loading: Record<string, boolean>;\n importedVehicles: any[];\n vehicles: any[];\n currentWorkingTrip: any;\n trips: any[];\n reservation: any;\n reservationReceipt: any;\n connections: GetaroundConnection[];\n}\n\nconst state: GetaroundState = {\n init: false,\n\n loading: {\n pulse: false,\n delete: false,\n toggle: false,\n vehicles: false,\n vehicleHistory: false,\n importedVehicles: false,\n receipt: false,\n },\n\n importedVehicles: [],\n vehicles: [],\n\n currentWorkingTrip: {},\n\n trips: [],\n reservation: {},\n reservationReceipt: {},\n\n connections: [],\n};\n\nconst getters = {\n loading: (state: GetaroundState) => state.loading,\n init: (state: GetaroundState) => state.init,\n trips: (state: GetaroundState) => state.trips,\n reservation: (state: GetaroundState) => state.reservation,\n reservationReceipt: (state: GetaroundState) => state.reservationReceipt,\n vehicles: (state: GetaroundState) => state.vehicles,\n importedVehicles: (state: GetaroundState) => state.importedVehicles,\n currentWorkingTrip: (state: GetaroundState) => state.currentWorkingTrip,\n connections: (state: GetaroundState) => state.connections,\n};\n\nconst mutations = {\n [types.SET_GETAROUND_INIT](state: GetaroundState, init) {\n state.init = init;\n },\n [types.SET_GETAROUND_LOADING](state: GetaroundState, loading) {\n state.loading[loading.subject] = loading.loading;\n },\n [types.SET_GETAROUND_CONNECTIONS](state: GetaroundState, connections) {\n state.connections = connections;\n },\n [types.SET_GETAROUND_VEHICLES](state: GetaroundState, vehicles) {\n state.vehicles = vehicles;\n },\n [types.SET_GETAROUND_TRIPS](state: GetaroundState, trips) {\n state.trips = trips;\n },\n [types.SET_GETAROUND_RESERVATION](state: GetaroundState, reservation) {\n state.reservation = reservation;\n },\n [types.SET_GETAROUND_RESERVATION_RECEIPT](state: GetaroundState, receipt) {\n state.reservationReceipt = receipt;\n },\n [types.SET_ALL_IMPORTED_GETAROUND_VEHICLES](state: GetaroundState, vehicles) {\n state.importedVehicles = vehicles;\n },\n};\n\nconst actions = {\n\n getaroundPulse({state: GetaroundState, commit, rootGetters}, gaid: string) {\n commit('SET_GETAROUND_LOADING', {subject: 'pulse', loading: true});\n\n let connIndex = findIndex(state.connections, (c) => gaid === c.uuid);\n\n if (connIndex === -1) {\n connIndex = state.connections.push({\n gaid,\n loading: true,\n connected: true,\n active: true,\n email: '',\n provider: 'getaround',\n });\n connIndex--;\n console.dir(connIndex);\n }\n\n state.connections[connIndex].loading = true;\n state.connections[connIndex].connected = false;\n axios.get(`/v1/company/${rootGetters['company/company'].uuid}/connections/getaround/${gaid}/pulse`)\n .then(() => {\n state.connections[connIndex].connected = true;\n }).catch(() => {\n state.connections[connIndex].connected = false;\n }).finally(() => {\n state.connections[connIndex].loading = false;\n commit('SET_GETAROUND_LOADING', {subject: 'pulse', loading: false});\n });\n },\n\n async toggleGetaroundActive({commit}, ga) {\n try {\n const responseData = await performApiRequest(commit, 'SET_GETAROUND_LOADING', 'toggle', () => axios.put(`/v1/connections/getaround/${ga.uuid}/toggle`));\n commit('SET_GETAROUND_CONNECTIONS', responseData?.company?.connections?.getaround);\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'Getaround connections toggled successfully!',\n });\n } catch (error) {\n console.dir(error);\n }\n },\n refreshToken({commit}, ga) {\n commit('SET_GETAROUND_LOADING', {subject: 'refresh-token', loading: true});\n axios.post(`/v1/company/${StorageService.getCompanyUuid()}/connections/getaround/${ga.uuid}/refresh-token`)\n .then(() => {\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'Getaround token refreshed successfully!',\n });\n }).catch((e) => {\n console.dir(e);\n }).finally(() => {\n commit('SET_GETAROUND_LOADING', {subject: 'refresh-token', loading: false});\n });\n },\n\n disconnectGetaroundCommit({commit, rootGetters}, ga) {\n commit('SET_GETAROUND_LOADING', {subject: 'delete', loading: true});\n axios.delete(`/v1/company/${rootGetters['company/company'].uuid}/connections/getaround/${ga.uuid}`)\n .then((response) => {\n commit('SET_GETAROUND_CONNECTIONS', get(response, 'data.company.connections.getaround'));\n EventBus.$emit('remove-getaround-connection-success');\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'Getaround connections removed successfully!',\n });\n }).catch((e) => {\n console.dir(e);\n }).finally(() => {\n commit('SET_GETAROUND_LOADING', {subject: 'delete', loading: false});\n });\n },\n\n fetchBookings({commit, rootGetters}, ga) {\n commit('SET_GETAROUND_LOADING', {subject: 'vehicleHistory', loading: true});\n axios.get(`/v1/company/${StorageService.getCompanyUuid()}/connections/getaround/${ga.uuid}/reservations`)\n .then((response) => {\n commit('SET_GETAROUND_TRIPS', get(response, 'data.trips'));\n }).catch((e) => {\n console.dir(e);\n }).finally(() => {\n commit('SET_GETAROUND_LOADING', {subject: 'vehicleHistory', loading: false});\n });\n },\n\n fetchOneReservation({commit}, {ga, reservation_id}) {\n commit('SET_GETAROUND_LOADING', {subject: 'vehicleHistory', loading: true});\n axios.get(`/v1/company/${StorageService.getCompanyUuid()}/connections/getaround/${ga.uuid}/reservations/${reservation_id}`)\n .then((response) => {\n commit('SET_GETAROUND_RESERVATION', get(response, 'data.trip'));\n }).catch((e) => {\n console.dir(e);\n }).finally(() => {\n commit('SET_GETAROUND_LOADING', {subject: 'vehicleHistory', loading: false});\n });\n },\n fetchOneReservationReceipt({commit}, {ga, reservation_id}) {\n commit('SET_GETAROUND_LOADING', {subject: 'receipt', loading: true});\n axios.get(`/v1/company/${StorageService.getCompanyUuid()}/connections/getaround/${ga.uuid}/reservations/${reservation_id}/receipt`)\n .then((response) => {\n commit('SET_GETAROUND_RESERVATION_RECEIPT', get(response, 'data.receipt'));\n }).catch((e) => {\n console.dir(e);\n }).finally(() => {\n commit('SET_GETAROUND_LOADING', {subject: 'receipt', loading: false});\n });\n },\n\n fetchVehicles({commit, rootGetters}, ga) {\n commit('SET_GETAROUND_LOADING', {subject: 'vehicles', loading: true});\n axios.get(`/v1/company/${rootGetters['company/company'].uuid}/connections/getaround/${ga.uuid}/vehicles`)\n .then((response) => {\n commit('SET_GETAROUND_VEHICLES', get(response, 'data.vehicles'));\n commit('SET_ALL_IMPORTED_GETAROUND_VEHICLES', get(response, 'data.vehicles'));\n }).catch((e) => {\n console.dir(e);\n }).finally(() => {\n commit('SET_GETAROUND_LOADING', {subject: 'vehicles', loading: false});\n });\n },\n\n importGetaroundListings({commit}, {listings, ga}) {\n commit('SET_GETAROUND_LOADING', {subject: 'import_listings', loading: true});\n EventBus.$emit('save-imported-listings-started', 'getaround');\n\n axios.post(`/v1/company/${StorageService.getCompanyUuid()}/connections/getaround/${ga.uuid}/import`, {listings})\n .then((response) => {\n commit('company/SET_COMPANY', response.data.company, {root: true});\n commit('SET_ALL_LISTINGS', get(response.data.company, 'listings', []));\n EventBus.$emit('save-getaround-imported-listings-success');\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'Getaround listing Import success',\n });\n }).catch(() => {\n }).finally(() => {\n EventBus.$emit('save-turo-imported-listings-success');\n commit('SET_GETAROUND_LOADING', {subject: 'import_listings', loading: false});\n });\n },\n\n fetchImportedVehicles({commit}) {\n commit('SET_GETAROUND_LOADING', {subject: 'importedVehicles', loading: true});\n axios.get('/v1/imported-getaround-vehicles')\n .then((response) => {\n commit('SET_ALL_IMPORTED_GETAROUND_VEHICLES', response.data.vehicles);\n }).catch(() => {\n }).finally(() => {\n commit('SET_GETAROUND_LOADING', {subject: 'importedVehicles', loading: false});\n });\n },\n};\n\nexport default {\n namespaced: true,\n state,\n mutations,\n actions,\n getters,\n};\n","import axios from 'axios';\nimport {EventBus} from '@/plugins/eventBus';\nimport {get} from 'lodash';\nimport {Form} from '@/plugins/FWForms/index';\nimport * as types from '../mutation-types';\n\nexport interface HqRentalsState {\n loading: Record<string, boolean>;\n form: Form<any>;\n connections: any[];\n listings: any[];\n bookings: any[];\n contacts: any[];\n}\n\nconst state: HqRentalsState = {\n loading: {\n login: false,\n test: false,\n listings: false,\n bookings: false,\n contacts: false,\n meta: false,\n settings: false,\n },\n form: new Form(),\n connections: [],\n listings: [],\n bookings: [],\n contacts: [],\n};\n\nconst getters = {\n form: state => state.form,\n connections: state => state.connections,\n loading: state => state.loading,\n listings: state => state.listings,\n bookings: state => state.bookings,\n contacts: state => state.contacts,\n};\n\nconst mutations = {\n [types.SET_HQRENTALS_LOADING](state, loading) {\n state.loading[loading.subject] = loading.loading;\n },\n [types.SET_HQRENTALS_CONNECTIONS](state, connections) {\n state.connections = connections;\n },\n [types.SET_HQRENTALS_LISTINGS](state, listings) {\n state.listings = listings;\n },\n [types.SET_HQRENTALS_BOOKINGS](state, bookings) {\n state.bookings = bookings;\n },\n [types.SET_HQRENTALS_CONTACTS](state, contacts) {\n state.contacts = contacts;\n },\n};\n\nconst actions = {\n\n login({commit, rootGetters}, credentials) {\n commit('SET_HQRENTALS_LOADING', {subject: 'login', loading: true});\n\n axios.post(`/v1/company/${rootGetters['company/company'].uuid}/connections/hq-rentals`, credentials)\n .then((response) => {\n EventBus.$emit('hqrentals-login-successful', get(response, 'data.provider'));\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'HQ Rentals logged in successfully!',\n });\n }).catch(() => {\n }).finally(() => {\n commit('SET_HQRENTALS_LOADING', {subject: 'login', loading: false});\n });\n },\n\n connect({commit, rootGetters}, data) {\n commit('SET_HQRENTALS_LOADING', {subject: 'login', loading: true});\n\n axios.post(`/v1/company/${rootGetters['company/company'].uuid}/connections/hq-rentals/connect`, data)\n .then((response) => {\n EventBus.$emit('hqrentals-connection-successful', get(response, 'data.providers'));\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'HQ Rentals connection connected successfully!',\n });\n }).catch(() => {\n }).finally(() => {\n commit('SET_HQRENTALS_LOADING', {subject: 'login', loading: false});\n });\n },\n\n setMeta({commit, rootGetters}, provider) {\n commit('SET_HQRENTALS_LOADING', {subject: 'meta', loading: true});\n\n axios.post(`/v1/company/${rootGetters['company/company'].uuid}/connections/hq-rentals/${provider.uuid}/set-meta`)\n .then((response) => {\n EventBus.$emit('hqrentals-set-meta-successful', get(response, 'data.fields'));\n })\n .catch(() => {\n })\n .finally(() => {\n commit('SET_HQRENTALS_LOADING', {subject: 'meta', loading: false});\n });\n },\n\n saveSettings({commit, rootGetters}, data) {\n commit('SET_HQRENTALS_LOADING', {subject: 'settings', loading: true});\n\n axios.put(`/v1/company/${rootGetters['company/company'].uuid}/connections/hq-rentals/${data.provider_uuid}/settings`, data)\n .then(() => {\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'HQ Rentals settings saved successfully!',\n });\n })\n .catch(() => {\n })\n .finally(() => {\n commit('SET_HQRENTALS_LOADING', {subject: 'settings', loading: false});\n });\n },\n\n testConnection({commit, rootGetters}, provider) {\n commit('SET_HQRENTALS_LOADING', {subject: 'test', loading: true});\n\n axios.post(`/v1/connections/hq-rentals/${provider.uuid}/test-connection`)\n .then(() => {\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'HQ Rentals connection connected successfully!',\n });\n }).catch((e) => {\n EventBus.$emit('hqrentals-test-connection-failed');\n }).finally(() => {\n commit('SET_HQRENTALS_LOADING', {subject: 'test', loading: false});\n });\n },\n\n fetchListings({commit, rootGetters}, provider_uuid) {\n commit('SET_HQRENTALS_LOADING', {subject: 'listings', loading: true});\n\n axios.get(`/v1/company/${rootGetters['company/company'].uuid}/connections/hq-rentals/${provider_uuid}/listings`)\n .then((response) => {\n commit('SET_HQRENTALS_LISTINGS', get(response, 'data.listings'));\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'HQ Rentals connection connected successfully!',\n });\n }).catch(() => {\n }).finally(() => {\n commit('SET_HQRENTALS_LOADING', {subject: 'listings', loading: false});\n });\n },\n\n fetchBookings({commit, rootGetters}, provider_uuid) {\n commit('SET_HQRENTALS_LOADING', {subject: 'bookings', loading: true});\n\n axios.get(`/v1/company/${rootGetters['company/company'].uuid}/connections/hq-rentals/${provider_uuid}/bookings`)\n .then((response) => {\n commit('SET_HQRENTALS_BOOKINGS', get(response, 'data.bookings'));\n }).catch(() => {\n }).finally(() => {\n commit('SET_HQRENTALS_LOADING', {subject: 'bookings', loading: false});\n });\n },\n\n fetchContacts({commit, rootGetters}, provider_uuid) {\n commit('SET_HQRENTALS_LOADING', {subject: 'contacts', loading: true});\n\n axios.get(`/v1/company/${rootGetters['company/company'].uuid}/connections/hq-rentals/${provider_uuid}/contacts`)\n .then((response) => {\n commit('SET_HQRENTALS_CONTACTS', get(response, 'data.contacts'));\n }).catch(() => {\n }).finally(() => {\n commit('SET_HQRENTALS_LOADING', {subject: 'contacts', loading: false});\n });\n },\n};\n\nexport default {\n namespaced: true,\n state,\n mutations,\n actions,\n getters,\n};\n","import {EventBus} from '@/plugins/eventBus';\nimport {Form} from '@/plugins/FWForms/index';\nimport axios from 'axios';\nimport * as types from '@/store/mutation-types';\nimport {StorageService} from '@/services/storage.service';\nimport {createUrlQueryString} from '@/utils/urls';\nimport {performApiRequest} from '@/store/helpers/vuex-helpers';\nimport {Module} from 'vuex';\nimport {RootState} from '@/types/RootState';\nimport {push} from 'notivue';\n\ntype PaymentMethod = {\n billing_details: {\n address: {\n city: string | null,\n country: string | null,\n line1: string | null,\n line2: string | null,\n postal_code: string | null,\n state: string | null,\n },\n email: string | null,\n name: string | null,\n phone: string | null,\n },\n brand: string,\n card: {\n brand: string,\n checks: {\n address_line1_check: string,\n address_postal_code_check: string,\n cvc_check: string,\n },\n country: string,\n exp_month: number,\n exp_year: number,\n fingerprint: string,\n funding: string,\n generated_from: string,\n last4: string,\n networks: {\n available: Array<string>,\n preferred: string,\n },\n three_d_secure_usage: {\n supported: boolean,\n },\n wallet: string,\n },\n exp_month: number,\n exp_year: number,\n funding: string,\n id: string,\n is_default: boolean,\n last4: string,\n name: string,\n}\n\nexport interface StripePaymentIntent {\n amount: number,\n amount_details: any,\n automatic_payment_methods: any,\n canceled_at: any,\n cancellation_reason: any,\n capture_method: string,\n client_secret: string,\n confirmation_method: string,\n created: number,\n currency: string,\n description: string,\n id: string,\n last_payment_error: any,\n livemode: boolean,\n next_action: any,\n object: string,\n payment_method: string,\n payment_method_configuration_details: any,\n payment_method_types: Array<string>,\n processing: any,\n receipt_email: any,\n setup_future_usage: string,\n shipping: any,\n source: any,\n status: string,\n}\n\nexport interface PaymentsState {\n loading: Record<string, boolean>,\n payments: Array<any>,\n payment: any,\n newPayment: {\n method: string,\n amount: number,\n date: string,\n security_deposit: number,\n keep_deposit_amount: number,\n keep_deposit_reason: string,\n description: string,\n transaction_type: string,\n payment_type: string,\n newCard: boolean,\n nameOnCard: string,\n paymentMethod: any,\n credit_card_id: any,\n capture_method: string,\n },\n stripeKey: string,\n payment_methods: PaymentMethod[],\n StripeIntent: any,\n paymentForm: Form<any>,\n currentWorkingPaymentItem: any,\n customPaymentMethods: string[],\n}\n\n// state\nconst state: PaymentsState = {\n loading: {\n cardBtnLoading: false,\n addPaymentMethod: false,\n cancelPaymentIntent: false,\n refund: false,\n refundPayment: false,\n cancelPayment: false,\n deletePayment: false,\n createPayment: false,\n capturePayment: false,\n deleteCustomPayment: false,\n sendPaymentViaSms: false,\n fetchPayment: false,\n fetchPaymentMethods: false,\n updatePaymentMethods: false,\n },\n payments: [],\n payment: {},\n newPayment: {\n method: '',\n amount: 0,\n date: new Date().toISOString().substring(0, 10),\n security_deposit: 0,\n keep_deposit_amount: 0,\n keep_deposit_reason: '',\n description: '',\n transaction_type: 'charge',\n payment_type: 'cash',\n newCard: false,\n nameOnCard: '',\n paymentMethod: null,\n credit_card_id: null,\n capture_method: 'automatic',\n },\n stripeKey: import.meta.env.VUE_APP_STRIPE_KEY,\n payment_methods: [] as PaymentMethod[],\n StripeIntent: {},\n paymentForm: new Form(),\n currentWorkingPaymentItem: {},\n customPaymentMethods: [],\n};\n\n\nconst PaymentsModule: Module<PaymentsState, RootState> = {\n namespaced: true,\n state,\n mutations: {\n [types.SET_PAYMENTS_LOADING](state: PaymentsState, loading: { subject: string, loading: boolean }) {\n state.loading[loading.subject] = loading.loading;\n },\n [types.SET_PAYMENT](state: PaymentsState, payment) {\n state.payment = payment;\n },\n [types.SET_PAYMENTS](state, payments) {\n state.payments = payments;\n },\n [types.SET_PAYMENT_METHODS](state, payment_methods: PaymentMethod[]) {\n state.payment_methods = payment_methods;\n },\n [types.SET_CURRENT_WORKING_PAYMENT_ITEM](state, item) {\n state.currentWorkingPaymentItem = item;\n },\n [types.SET_CUSTOM_PAYMENT_METHODS](state, methods) {\n state.customPaymentMethods = methods;\n },\n [types.SET_STRIPE_INTENT](state, data) {\n state.StripeIntent = data;\n },\n [types.RESET_NEW_PAYMENT](state) {\n state.newPayment = {\n method: '',\n amount: 0,\n date: new Date().toISOString().substring(0, 10),\n security_deposit: 0,\n keep_deposit_amount: 0,\n keep_deposit_reason: '',\n description: '',\n transaction_type: 'charge',\n payment_type: 'cash',\n newCard: false,\n nameOnCard: '',\n paymentMethod: null,\n credit_card_id: null,\n capture_method: 'automatic',\n }\n },\n },\n actions: {\n async fetchPayment({commit}, payment_id: string) {\n try {\n const responseData = await performApiRequest(commit, 'SET_PAYMENTS_LOADING', 'fetchPayment', () => axios.get(`/v1/payments/${payment_id}`));\n commit('SET_PAYMENT', responseData.payment);\n return responseData.payment;\n } catch (error) {\n console.error(error)\n }\n },\n\n fetchPayments({commit}, attributes) {\n const query = createUrlQueryString(attributes, true);\n\n axios.get(`/v1/payments${query}`)\n .then((response) => {\n commit('SET_PAYMENTS', response.data.payments);\n EventBus.$emit('fetch-payments-success');\n }).catch(() => {\n }).finally(() => {\n });\n },\n\n async fetchPaymentMethods({commit}) {\n try {\n const responseData = await performApiRequest(commit, 'SET_PAYMENTS_LOADING', 'fetchPaymentMethods', () => axios.get('/v1/stripe/payment-methods'));\n commit('SET_PAYMENT_METHODS', responseData.cards);\n } catch (error) {\n console.error(error)\n }\n },\n async updateDefaultBillingDetails({commit}, data) {\n try {\n await performApiRequest(commit, 'SET_PAYMENTS_LOADING', 'updatePaymentMethods', () => axios.put('/v1/stripe/payment-methods/default', data));\n push.success({\n message: 'Payment method updated successfully',\n });\n } catch (error) {\n push.error({\n message: e?.response?.data?.message || 'There was an error',\n });\n }\n },\n\n createSetupIntent({commit}) {\n axios.post('/v1/stripe/create-setup-intent')\n .then((response) => {\n commit('SET_STRIPE_INTENT', response.data.intent);\n }).catch(() => {\n }).finally(() => {\n });\n },\n\n async addPaymentMethod({commit}, paymentIntent: StripePaymentIntent) {\n try {\n const responseData = await performApiRequest(commit, 'SET_PAYMENTS_LOADING', 'addPaymentMethod', () => axios.post('/v1/stripe/add-payment-method', paymentIntent));\n commit(types.SET_PAYMENT_METHODS, responseData?.cards || []);\n commit('company/SET_COMPANY', responseData?.company, {root: true});\n EventBus.$emit('add-payment-method-success');\n } catch (error) {\n console.error(error)\n }\n },\n\n /**\n * Capture a payment authorization\n */\n capturePayment({commit}, capture) {\n commit('SET_PAYMENTS_LOADING', {subject: 'capturePayment', loading: true});\n\n axios.post(`/v1/payments/${capture.uuid}/capture`, capture)\n .then((response) => {\n commit('SET_PAYMENT', response.data.payment);\n EventBus.$emit('capture-payment-success');\n\n push.success({\n message: 'Payment was captured successfully',\n });\n }).catch((e) => {\n push.error({\n message: e?.response?.data?.message || 'There was an error',\n });\n }).finally(() => {\n commit('SET_PAYMENTS_LOADING', {subject: 'capturePayment', loading: false});\n });\n },\n\n refundPayment2({commit, rootGetters}, refund) {\n commit('SET_PAYMENTS_LOADING', {subject: 'refund', loading: true});\n axios.post(`/v1/company/${rootGetters['company/company'].uuid}/payments/${refund.p_id}/refund`, {\n amount: refund.amount,\n })\n .then((response) => {\n commit('SET_PAYMENT', response.data.payment);\n push.success({\n message: 'Payment refund was successful',\n });\n }).catch((e) => {\n console.dir(e);\n push.error({\n message: e?.response?.data?.message || 'There was an error',\n });\n }).finally(() => {\n commit('SET_PAYMENTS_LOADING', {subject: 'refund', loading: false});\n });\n },\n\n /**\n * Create a payment\n */\n createPayment({state, commit}, payment) {\n commit('SET_PAYMENTS_LOADING', {subject: 'createPayment', loading: true});\n\n\n axios.post('/v1/payments', {\n payment,\n }).then((response) => {\n EventBus.$emit('create-payment-success', response.data.payment);\n commit(types.SET_PAYMENT, response.data.payment);\n\n push.success({\n message: 'Success',\n });\n }).catch((e) => {\n push.error({\n message: e?.response?.data?.message || 'There was an error',\n });\n state.paymentForm.errors.set(e?.response?.data?.message || 'There was an error');\n }).finally(() => {\n commit('SET_PAYMENTS_LOADING', {subject: 'createPayment', loading: false});\n });\n },\n\n /**\n * Create a manual payment\n */\n createManualPayment({commit}, payment) {\n commit('SET_PAYMENTS_LOADING', {subject: 'createPayment', loading: true});\n\n axios.post('/v1/payments', {payment})\n .then((response) => {\n EventBus.$emit('create-payment-success', response.data.payment);\n commit(types.SET_PAYMENT, response.data.payment);\n\n push.success({\n message: 'Success',\n });\n }).catch((e) => {\n console.dir(e);\n push.error({\n message: e?.response?.data?.message || 'There was an error',\n });\n }).finally(() => {\n commit('SET_PAYMENTS_LOADING', {subject: 'createPayment', loading: false});\n });\n },\n\n cancelPayment({commit}, uuid) {\n commit('SET_PAYMENTS_LOADING', {subject: 'cancelPayment', loading: true});\n axios.post(`/v1/payments/${uuid}/cancel-request`)\n .then((response) => {\n EventBus.$emit('cancel-payment-intent-success', response.data.payment);\n commit('SET_PAYMENT', response.data.payment);\n }).catch((e) => {\n push.error({\n message: e?.response?.data?.message || 'There was an error',\n });\n }).finally(() => {\n commit('SET_PAYMENTS_LOADING', {subject: 'cancelPayment', loading: false});\n });\n },\n\n /**\n * Refund a payment\n */\n refundPayment({state, commit}, payment) {\n commit('SET_PAYMENTS_LOADING', {subject: 'refundPayment', loading: true});\n state.paymentForm.errors.clear();\n\n axios.post(`/v1/payments/${payment.uuid}/refund`, payment)\n .then((response) => {\n EventBus.$emit('refund-payment-success');\n commit('SET_PAYMENT', response.data.payment);\n push.success({\n message: 'Refund Payment Success',\n });\n }).catch((e) => {\n EventBus.$emit('refund-payment-failure', e?.response?.data?.message || 'There was an error');\n state.paymentForm.errors.set(e?.response?.data?.message || 'There was an error');\n }).finally(() => {\n commit('SET_PAYMENTS_LOADING', {subject: 'refundPayment', loading: false});\n });\n },\n\n /**\n * Keep deposit\n */\n keepDeposit({state, commit}, payment) {\n commit('SET_PAYMENTS_LOADING', {subject: 'refundPayment', loading: true});\n state.paymentForm.errors.clear();\n\n axios.post(`/v1/company/${StorageService.getCompanyUuid()}/payments/hold-deposit`, payment)\n .then((response) => {\n EventBus.$emit('refund-payment-success');\n commit('SET_PAYMENT', response.data.payment);\n push.success({\n message: 'Refund Payment Success',\n });\n }).catch((e) => {\n state.paymentForm.errors.set(e?.response?.data?.message || 'There was an error');\n }).finally(() => {\n commit('SET_PAYMENTS_LOADING', {subject: 'refundPayment', loading: false});\n });\n },\n\n deletePayment({commit}, uuid) {\n commit('SET_PAYMENTS_LOADING', {subject: 'deletePayment', loading: true});\n\n axios.delete(`/v1/payments/${uuid}`)\n .then(() => {\n EventBus.$emit('delete-payment-success');\n }).catch((e) => {\n push.error({\n message: e?.response?.data?.message || 'There was an error',\n });\n }).finally(() => {\n commit('SET_PAYMENTS_LOADING', {subject: 'deletePayment', loading: false});\n });\n },\n\n async deleteCustomPaymentMethod({commit}, name) {\n const responseData = await performApiRequest(commit, 'SET_PAYMENTS_LOADING', 'deleteCustomPayment', () => axios.delete(`/v1/custom-payment-methods/${name}`));\n commit(types.SET_CUSTOM_PAYMENT_METHODS, responseData.meta);\n },\n\n\n /**\n * Send a sms with a payment request link\n */\n sendPaymentRequestLinkViaSms({commit}, payment) {\n commit('SET_PAYMENTS_LOADING', {subject: 'sendPaymentViaSms', loading: true});\n\n axios.post(`/v1/payments/${payment.uuid}/send-via-sms`)\n .then(() => {\n EventBus.$emit('send-payment-request-link-via-sms-success');\n }).catch((e) => {\n EventBus.$emit('send-payment-request-link-via-sms-failed', e?.response?.data?.message || 'There was an error');\n }).finally(() => {\n commit('SET_PAYMENTS_LOADING', {subject: 'sendPaymentViaSms', loading: false});\n });\n },\n },\n getters: {\n loading: (state: PaymentsState) => state.loading,\n payment: (state: PaymentsState) => state.payment,\n payments: (state: PaymentsState) => state.payments,\n newPayment: (state: PaymentsState) => state.newPayment,\n stripeKey: (state: PaymentsState) => state.stripeKey,\n StripeIntent: (state: PaymentsState) => state.StripeIntent,\n paymentMethods: (state: PaymentsState) => state.payment_methods,\n paymentForm: (state: PaymentsState) => state.paymentForm,\n currentWorkingPaymentItem: (state: PaymentsState) => state.currentWorkingPaymentItem,\n customPaymentMethods: (state: PaymentsState) => state.customPaymentMethods,\n }\n};\n\nexport default PaymentsModule;\n","\nexport default {\n /**\n * @type {String}\n */\n title: 'Fleetwire.io' as string,\n // theme: variables.theme,\n\n /**\n * @type {boolean} true | false\n * @description Whether show the settings right-panel\n */\n showSettings: true as boolean,\n\n /**\n * @type {boolean} true | false\n * @description Whether need tagsView\n */\n tagsView: true as boolean,\n\n /**\n * @type {boolean} true | false\n * @description Whether fix the header\n */\n fixedHeader: false as boolean,\n\n /**\n * @type {boolean} true | false\n * @description Whether show the logo in sidebar\n */\n sidebarLogo: false as boolean,\n\n /**\n * @type {string | array} 'production' | ['production','development']\n * @description Need show err logs component.\n * The default is only used in the production env\n * If you want to also use it in dev, you can pass ['production','development']\n */\n errorLog: 'production' as string | string[],\n};\n","import defaultSettings from '@/settings';\nimport * as types from '@/store/mutation-types';\nimport axios from 'axios';\nimport {isNull} from 'lodash';\nimport {EventBus} from '@/plugins/eventBus';\nimport {performApiRequest} from '@/store/helpers/vuex-helpers';\n\nconst {showSettings, tagsView, fixedHeader, sidebarLogo} = defaultSettings;\n\nexport interface NotificationSettings {\n fw_booking_email: boolean;\n fw_booking_sms: boolean;\n getaround_booking_email: boolean;\n getaround_booking_sms: boolean;\n getaround_communication_error_email: boolean;\n getaround_communication_error_sms: boolean;\n id: boolean;\n tesla_communication_error_email: boolean;\n tesla_communication_error_sms: boolean;\n turo_booking_email: boolean;\n turo_booking_sms: boolean;\n turo_communication_error_email: boolean;\n turo_communication_error_sms: boolean;\n vehicle_maintenance_reminder_sms: boolean;\n vehicle_maintenance_reminder_email: boolean;\n renter_invoice_paid_sms: boolean;\n renter_invoice_paid_email: boolean;\n toll_new_transaction_sms: boolean;\n toll_new_transaction_email: boolean;\n vehicle_recall_sms: boolean;\n vehicle_recall_email: boolean;\n notify_email: boolean;\n notify_sms: boolean;\n set: boolean;\n}\n\nexport interface SettingsState {\n theme: any[];\n showSettings: boolean;\n tagsView: boolean;\n fixedHeader: boolean;\n sidebarLogo: boolean;\n loading: Record<string, boolean>;\n notifications: NotificationSettings;\n}\n\nconst state: SettingsState = {\n theme: [],\n showSettings,\n tagsView,\n fixedHeader,\n sidebarLogo,\n loading: {\n notifications: false,\n export_commit: false,\n settings: false,\n get_settings: false,\n },\n notifications: {\n set: false,\n fw_booking_email: null,\n fw_booking_sms: null,\n getaround_booking_email: null,\n getaround_booking_sms: null,\n getaround_communication_error_email: null,\n getaround_communication_error_sms: null,\n id: null,\n tesla_communication_error_email: null,\n tesla_communication_error_sms: null,\n turo_booking_email: null,\n turo_booking_sms: null,\n turo_communication_error_email: null,\n turo_communication_error_sms: null,\n vehicle_maintenance_reminder_sms: null,\n vehicle_maintenance_reminder_email: null,\n renter_invoice_paid_sms: null,\n renter_invoice_paid_email: null,\n toll_new_transaction_sms: null,\n toll_new_transaction_email: null,\n vehicle_recall_sms: null,\n vehicle_recall_email: null,\n notify_email: null,\n notify_sms: null,\n },\n};\n\nconst getters = {\n loading: (state: SettingsState) => state.loading,\n needTagsView: (state: SettingsState) => state.tagsView,\n fixedHeader: (state: SettingsState) => state.fixedHeader,\n showSettings: (state: SettingsState) => state.showSettings,\n notifications: (state: SettingsState) => state.notifications,\n};\n\nconst mutations = {\n [types.SET_SETTINGS_LOADING](state: SettingsState, loading: { subject: string, loading: boolean }) {\n state.loading[loading.subject] = loading.loading;\n },\n [types.SET_NOTIFICATION_SETTINGS](state: SettingsState, settings: NotificationSettings) {\n if (!isNull(settings)) {\n state.notifications = settings;\n state.notifications.set = true;\n }\n },\n};\n\nconst actions = {\n getSettings({commit}) {\n commit('SET_SETTINGS_LOADING', {subject: 'get_settings', loading: true});\n\n axios.get('/v1/settings')\n .then((response) => {\n EventBus.$emit('get-settings-success', response.data.settings);\n commit('company/SET_COMPANY_SETTINGS', response.data.settings, {root: true});\n }).catch(() => {\n EventBus.$emit('SystemMessage', {\n type: 'error',\n message: 'error getting settings',\n });\n }).finally(() => {\n commit('SET_SETTINGS_LOADING', {subject: 'get_settings', loading: false});\n });\n },\n\n async updateSettings({commit}, data: { settings: { [key: string]: string } }) {\n try {\n const responseData = await performApiRequest(commit, 'SET_SETTINGS_LOADING', 'settings', () => axios.post('/v1/settings', data));\n commit('company/SET_COMPANY_SETTINGS', responseData.settings, {root: true});\n } catch (error) {\n EventBus.$emit('SystemMessage', {\n type: 'error',\n message: 'Settings update error. Try again later.',\n });\n }\n },\n\n async updateNotificationSettings({commit}) {\n try {\n const responseData = await performApiRequest(commit, 'SET_SETTINGS_LOADING', 'notifications', () => axios.put('/v1/settings/notifications', state.notifications));\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'Settings updated successfully!',\n });\n return responseData;\n } catch (error) {\n EventBus.$emit('SystemMessage', {\n type: 'error',\n message: 'Settings update error. Try again later.',\n });\n }\n },\n\n resetNotificationSettings({commit}) {\n commit('SET_SETTINGS_LOADING', {subject: 'notifications', loading: true});\n axios.post('/v1/settings/notifications/reset')\n .then((response) => {\n commit('SET_NOTIFICATION_SETTINGS', response?.data?.company?.notification_settings);\n }).catch(() => {\n }).finally(() => {\n commit('SET_SETTINGS_LOADING', {subject: 'notifications', loading: false});\n });\n },\n\n\n getExportDetails({commit}) {\n commit('SET_SETTINGS_LOADING', {subject: 'export_details', loading: true});\n axios.get('/v1/export/details')\n .then((response) => {\n EventBus.$emit('export-details-success', response.data);\n }).catch(() => {\n }).finally(() => {\n commit('SET_SETTINGS_LOADING', {subject: 'export_details', loading: false});\n });\n },\n commitExport({commit}, data) {\n commit('SET_SETTINGS_LOADING', {subject: 'export_commit', loading: true});\n axios.post('/v1/export', data)\n .then((response) => {\n console.dir(response);\n const downloadUrl = window.URL.createObjectURL(new Blob([response.data]));\n const link = document.createElement('a');\n link.href = downloadUrl;\n link.setAttribute('download', 'fleetwire-export.csv');\n document.body.appendChild(link);\n link.click();\n link.remove();\n }).catch(() => {\n }).finally(() => {\n commit('SET_SETTINGS_LOADING', {subject: 'export_commit', loading: false});\n });\n },\n};\n\nexport default {\n namespaced: true,\n state,\n mutations,\n actions,\n getters,\n};\n","import axios from 'axios';\nimport { EventBus } from '@/plugins/eventBus';\nimport { get } from 'lodash';\nimport * as types from '../mutation-types';\n\nexport interface ThemeState {\n loading: Record<string, boolean>;\n storeThemes: any[];\n storeTheme: any;\n}\n\nconst state: ThemeState = {\n loading: {\n notes: false,\n createNote: false,\n deleteNote: false,\n },\n storeThemes: [],\n storeTheme: null,\n};\n\nconst getters = {\n storeThemes: state => state.storeThemes,\n storeTheme: state => state.storeTheme,\n loading: state => state.loading,\n};\n\nconst mutations = {\n [types.SET_NOTES_LOADING](state, loading) {\n state.loading[loading.subject] = loading.loading;\n },\n [types.SET_STORE_THEMES](state, data) {\n state.storeThemes = data;\n },\n [types.SET_STORE_THEME_DATA](state, data) {\n state.storeTheme = data;\n },\n};\n\nconst actions = {\n\n\n /**\n * Get all notes.\n *\n * @param commit\n * @param {Object} options\n */\n async getStoreThemes({ commit }) {\n commit('SET_NOTES_LOADING', { subject: 'notes', loading: true });\n\n const query = '';\n await axios.get(`/v1/store-assets?${query}`)\n .then((response) => {\n commit('SET_STORE_THEMES', get(response, 'data.data'));\n }).catch(() => {\n }).finally(() => {\n commit('SET_NOTES_LOADING', { subject: 'notes', loading: false });\n });\n },\n getStoreTheme({ commit }, uuid) {\n commit('SET_NOTES_LOADING', { subject: 'notes', loading: true });\n\n axios.get(`/v1/store-assets/${uuid}`)\n .then((response) => {\n commit('SET_STORE_THEME_DATA', get(response, 'data.data'));\n }).catch(() => {\n }).finally(() => {\n commit('SET_NOTES_LOADING', { subject: 'notes', loading: false });\n });\n },\n updateStoreTheme({ commit }, theme) {\n commit('SET_NOTES_LOADING', { subject: 'notes', loading: true });\n axios.put(`/v1/store-assets/${theme.uuid}`, theme)\n .then(() => {\n EventBus.$emit('update-theme-settings-success');\n }).catch(() => {\n }).finally(() => {\n commit('SET_NOTES_LOADING', { subject: 'notes', loading: false });\n });\n },\n};\n\nexport default {\n namespaced: true,\n state,\n mutations,\n actions,\n getters,\n};\n","import Cookies from 'js-cookie';\nimport * as types from '../mutation-types';\nimport Tr from \"@/plugins/i18n/translations\";\n\nconst locales = [];\n\nexport interface LangState {\n locale: string,\n locales: string[],\n}\n\n// state\nconst state: LangState = {\n locale: Tr.guessDefaultLocale(),\n locales,\n};\n\n// getters\nconst getters = {\n locale: (state: LangState) => state.locale,\n locales: (state: LangState) => state.locales,\n};\n\n// mutations\nconst mutations = {\n [types.SET_LOCALE](state: LangState, { locale }) {\n state.locale = locale;\n },\n};\n\n// actions\nconst actions = {\n setLocale({ commit }, { locale }) {\n commit(types.SET_LOCALE, { locale });\n\n Cookies.set('locale', locale, { expires: 365 });\n },\n};\n\n\nexport default {\n namespaced: true,\n state,\n mutations,\n actions,\n getters,\n};\n","import axios from 'axios';\nimport {get, set} from 'lodash';\nimport {Form} from '@/plugins/FWForms/index';\nimport {EventBus} from '@/plugins/eventBus';\nimport {StorageService} from '@/services/storage.service';\nimport * as types from '../mutation-types';\nimport {\n BookingInterface,\n ListingFilter,\n ListingInterface,\n TaxCategory,\n TripExtra,\n VehicleClass,\n VehicleInterface\n} from '@/types';\nimport {performApiRequest} from '@/store/helpers/vuex-helpers';\nimport {RootState} from '@/types/RootState';\nimport {Module} from 'vuex'\nimport {push} from 'notivue'\n\n\nexport type DailyPrice = {\n date: string,\n localizedDayOfWeek: string,\n localizedShortDayOfWeek: string,\n price: number,\n source: 'custom' | 'default',\n}\n\ntype VehicleIncident = {\n amount: null,\n coordinates: { x: number, y: number },\n created_at: string,\n created_by: string,\n damage_type: string,\n description: string,\n fixed_at: string,\n incident_at: string,\n updated_at: string,\n uuid: string,\n}\n\nexport interface ListingState {\n loading: Record<string, boolean>,\n dialogs: Record<string, boolean>,\n snacks: Record<string, boolean>,\n listingInit: boolean,\n allListingsInit: boolean,\n allListings: ListingInterface[],\n custodialListings: ListingInterface[],\n fleetResourceListingsLoaded: boolean,\n fleetResourceListings: ListingInterface[],\n listing: ListingInterface,\n originalListing: ListingInterface,\n currentListing: ListingInterface,\n currentExtra: any,\n allExtras: any[],\n listingExtras: any[],\n currentVehicleFeatures: any[],\n allVehicleFeatures: Record<string, string>[],\n availability_message: string,\n dailyPricing: DailyPrice[],\n incidents: VehicleIncident[],\n form: any,\n listingExtraForm: any,\n listingBookableTimes: Record<string, string>[],\n filters: ListingFilter,\n filterOptions: Record<string, any>,\n}\n\nconst defaultVehicle: VehicleInterface = {\n v_id: '',\n active: false,\n year: null,\n make: '',\n model: '',\n trim: '',\n color: '',\n title: '',\n vin: '',\n features: null,\n in_service: false,\n vehicle_class: null,\n plate: '',\n details: null,\n seats: null,\n doors: null,\n branch: null,\n last_odometer_reading: 0,\n toll_transponder: '',\n has_remote_capability: false,\n lockbox_code: '',\n lockbox_location: '',\n matched_bouncie_vehicle: null,\n matched_getaround_vehicle: null,\n status: null,\n unit_id: null,\n matched_turo_vehicle: null,\n};\n\nconst state: ListingState = {\n loading: {\n listing: false,\n listings: false,\n addListing: false,\n saveListing: false,\n deleteListing: false,\n archiveListing: false,\n pausing: false,\n decoding_vin: false,\n unavailable_period: false,\n matchingTeslaVehicle: false,\n matchBouncieVehicle: false,\n tripExtraAdd: false,\n tripExtraEdit: false,\n import_listings: false,\n importImages: false,\n importDelete: false,\n getAllExtras: false,\n syncCarShareData: false,\n dailyPrices: false,\n updateDailyPrices: false,\n updateOdomProvider: false,\n vehicle: false,\n vehicleDetails: false,\n getIncidents: false,\n saveIncident: false,\n deleteIncident: false,\n updateIncident: false,\n listing_extras: false,\n vehicleFeatures: false,\n },\n dialogs: {\n pricingOptions: false,\n },\n filters: {\n year: {\n selected: false,\n years: [],\n available_years: [],\n },\n make: {\n selected: false,\n makes: [],\n available_makes: [],\n },\n model: {\n selected: false,\n models: [],\n available_models: [],\n },\n },\n\n snacks: {\n vehicle_details_success: false,\n },\n listingInit: false,\n allListingsInit: false,\n\n form: new Form(),\n listingExtraForm: new Form(),\n allListings: [],\n custodialListings: [],\n listing: null,\n\n originalListing: null,\n currentListing: {\n active: false,\n init: false,\n approved: false,\n loaded: false,\n l_id: null,\n unit_id: null,\n name: '',\n description: '',\n slug: '',\n sub_title: '',\n timezone: '',\n checkout_mode: '',\n archived_at: '',\n cover_photo: '',\n listing_image: '',\n order: 0,\n paused: false,\n use_secondary_driver: false,\n use_esign_template: false,\n longer_weekend_trip_preferred: false,\n miles_included: 0,\n miles_extra: 0,\n extras: [],\n distance_allowance_max: 0,\n minimum_request_duration: 0,\n min_age: 0,\n seasoned_driver: 0,\n provider_listings: null,\n tax_category: null,\n is_custodian: false,\n title: '',\n pricing: {\n price_type: 'flat_fee',\n price_period: 'Day',\n price_structure_id: null,\n amount: 1,\n security_deposit_credit: 0,\n security_deposit_debit: 0,\n adjusted_amount: 0,\n discountable: false,\n taxable: false,\n original_price: 0,\n price_structure: null,\n sec_dep: 0,\n total_per_day: 0,\n monthlyPercentageDiscount: 0,\n threeDayPercentageDiscount: 0,\n weeklyPercentageDiscount: 0,\n },\n listing_images: [],\n padding_before: 0,\n padding_after: 0,\n\n vehicle: {\n v_id: '',\n active: false,\n year: null,\n make: '',\n model: '',\n trim: '',\n color: '',\n title: '',\n vin: '',\n features: null,\n in_service: false,\n vehicle_class: null,\n plate: '',\n details: null,\n seats: null,\n doors: null,\n branch: null,\n last_odometer_reading: 0,\n toll_transponder: '',\n has_remote_capability: false,\n lockbox_code: '',\n lockbox_location: '',\n matched_bouncie_vehicle: null,\n matched_getaround_vehicle: null,\n status: null,\n unit_id: null,\n matched_turo_vehicle: null,\n },\n bookings: [],\n age_requirements: {\n min_age: 21,\n young_driver: 21,\n young_driver_fee: 19,\n young_driver_security_deposit: 250,\n seasoned_driver: 25,\n },\n commission_partners: [],\n template: null,\n },\n\n currentExtra: {\n title: 'Insurance',\n type: 'trip',\n active: true,\n l_id: '',\n required: true,\n code: null,\n settings: {\n display: null,\n },\n tax_category: {},\n extras: [\n {\n title: 'Basic',\n subtitle: '',\n price: 0,\n description: '<p>Example: Cover your trip with comprehensive rental insurance.</p><ul><li><p>Covers damage up to the full value of the vehicle.</p></li><li><p>Liability coverage up to state minimum.</p></li></ul>',\n recommended: false,\n allow_multi: 1,\n },\n ],\n },\n dailyPricing: [],\n allExtras: [],\n availability_message: '',\n allVehicleFeatures: [],\n currentVehicleFeatures: [],\n fleetResourceListingsLoaded: false,\n fleetResourceListings: [],\n incidents: [],\n listingExtras: [],\n listingBookableTimes: [],\n filterOptions: {\n sort: 'standard',\n make: [],\n }\n};\n\nconst getters = {\n allListings: (state: ListingState) => state.allListings,\n filters: (state: ListingState) => state.filters,\n fleetResourceListings: (state: ListingState) => state.fleetResourceListings,\n allExtras: (state: ListingState) => state.allExtras,\n listingInit: (state: ListingState) => state.listingInit,\n allListingsInit: (state: ListingState) => state.allListingsInit,\n dailyPricing: (state: ListingState) => state.dailyPricing,\n originalListing: (state: ListingState) => state.originalListing,\n currentListing: (state: ListingState) => state.currentListing,\n currentListingBookings: (state: ListingState) => state.currentListing.bookings,\n listingLoading: (state: ListingState) => state.loading,\n listingSnacks: (state: ListingState) => state.snacks,\n loading: (state: ListingState) => state.loading,\n listing: (state: ListingState) => state.listing,\n form: (state: ListingState) => state.form,\n listingExtraForm: (state: ListingState) => state.listingExtraForm,\n currentListingExtra: (state: ListingState) => state.currentExtra,\n availabilityMessage: (state: ListingState) => state.availability_message,\n currentVehicleFeatures: (state: ListingState) => state.currentVehicleFeatures,\n allVehicleFeatures: (state: ListingState) => state.allVehicleFeatures,\n listingExtras: (state: ListingState) => state.listingExtras,\n dialogs: (state: ListingState) => state.dialogs,\n incidents: (state: ListingState) => state.incidents,\n filterOptions: (state: ListingState) => state.filterOptions,\n\n visibleListings: (state: ListingState) => {\n return (state.allListings || [])\n .filter(listing => !listing.paused && listing.active && listing.approved)\n .slice()\n .sort((a, b) => (a.order ?? 0) - (b.order ?? 0));\n },\n};\n\nfunction setFilterValues(state: ListingState, filterKey: string, dataKey: string, data: string[] | number[]) {\n if (data) {\n state.filters[filterKey][dataKey] = data;\n }\n}\n\nconst mutations = {\n [types.SET_LISTING_LOADING](state: ListingState, loading: { subject: string, loading: boolean }) {\n state.loading[loading.subject] = loading.loading;\n },\n [types.SET_LISTING_SNACK](state: ListingState, snack: { subject: string, value: boolean }) {\n state.snacks[snack.subject] = snack?.value || false;\n },\n [types.SET_LISTING_DIALOG](state: ListingState, payload: { topic: string, value: boolean }) {\n state.dialogs[payload.topic] = payload.value;\n\n setTimeout(() => {\n state.dialogs[payload.topic] = false;\n }, 500);\n },\n [types.SET_LISTING_FILTER_AVAILABLE_FILTERS](state: ListingState, data: {\n years?: number[],\n makes?: string[],\n models?: string[]\n }) {\n setFilterValues(state, 'year', 'available_years', data.years);\n setFilterValues(state, 'make', 'available_makes', data.makes);\n setFilterValues(state, 'model', 'available_models', data.models);\n },\n [types.SET_LISTING_FILTER_SELECTED_FILTERS](state: ListingState, data: {\n years?: number[],\n makes?: string[],\n models?: string[]\n }) {\n setFilterValues(state, 'year', 'years', data.years);\n setFilterValues(state, 'make', 'makes', data.makes);\n setFilterValues(state, 'model', 'models', data.models);\n },\n [types.TOGGLE_LISTING_FILTER](state: ListingState, filter: 'year' | 'make' | 'model') {\n state.filters[filter].selected = !state.filters[filter].selected;\n },\n [types.CLEAR_LISTING_FILTER](state: ListingState) {\n state.filters.year.years = [];\n state.filters.make.makes = [];\n state.filters.model.models = [];\n state.filters.year.selected = false;\n state.filters.make.selected = false;\n state.filters.model.selected = false;\n },\n [types.SET_LISTING](state: ListingState, listing: ListingInterface) {\n state.listing = listing;\n state.listingInit = true;\n },\n [types.SET_LISTING_INIT](state: ListingState, isInit: boolean) {\n state.listingInit = isInit;\n },\n [types.SET_ALL_LISTINGS](state: ListingState, listings: ListingInterface[]) {\n state.allListings = listings;\n state.allListingsInit = true;\n },\n [types.SET_BOOKABLE_TIMES](state: ListingState, times: { timeF: string, time: string }[]) {\n state.listingBookableTimes = times;\n },\n [types.SET_CUSTODIAL_LISTING](state: ListingState, listings: ListingInterface[]) {\n state.custodialListings = listings;\n },\n [types.SET_FLEET_RESOURCE_LISTINGS](state: ListingState, listings: ListingInterface[]) {\n state.fleetResourceListingsLoaded = true;\n state.fleetResourceListings = listings;\n },\n [types.SET_FLEET_RESOURCE_LISTINGS_DATA](state: ListingState, {l_id, data}) {\n const listing = state.fleetResourceListings.find(item => item.l_id === l_id);\n\n if (listing) {\n // Iterate over the keys in the data\n Object.keys(data).forEach(key => {\n if (typeof data[key] === 'object' && data[key] !== null) {\n // Ensure the nested object exists\n if (!listing[key]) listing[key] = {};\n\n // Iterate over the nested object's keys\n Object.keys(data[key]).forEach(subKey => {\n listing[key][subKey] = data[key][subKey];\n });\n } else {\n // Direct assignment for non-object properties\n listing[key] = data[key];\n }\n });\n }\n },\n\n [types.SET_VEHICLE_VIN](state: ListingState, vin: string) {\n state.currentListing.vehicle.vin = vin;\n },\n [types.SET_CURRENT_LISTING_INCIDENTS](state: ListingState, incidents: VehicleIncident[]) {\n state.incidents = incidents;\n },\n [types.SET_LISTING_FILTER_OPTIONS](state: ListingState, filterOptions: { key: string, value: any }) {\n console.dir('SET_LISTING_FILTER_OPTIONS');\n console.dir(filterOptions);\n state.filterOptions[filterOptions.key] = filterOptions.value;\n },\n [types.SET_VEHICLE_YEAR](state: ListingState, value: number) {\n // Ensure the 'vehicle' object exists in 'currentListing'\n if (!state.currentListing.vehicle) {\n state.currentListing.vehicle = {...defaultVehicle};\n }\n\n // Directly set the 'year' property on the 'vehicle' object\n state.currentListing.vehicle.year = value;\n },\n [types.SET_LISTING_PRICE_TYPE](state: ListingState, value: string) {\n set(state.currentListing, 'pricing.price_type', value);\n },\n [types.SET_LISTING_PRICE_PERIOD](state: ListingState, value: string) {\n set(state.currentListing, 'pricing.price_period', value);\n },\n [types.SET_LISTING_PRICE_STRUCTURE_ID](state: ListingState, value: string) {\n set(state.currentListing, 'pricing.price_structure_id', value);\n },\n [types.SET_ALL_AVAILABLE_FEATURES](state: ListingState, features: Record<string, string>[]) {\n state.allVehicleFeatures = features;\n },\n [types.SET_VEHICLE_EXTRAS](state: ListingState, extras: TripExtra[]) {\n state.listingExtras = extras;\n },\n [types.SET_VEHICLE_FEATURES](state: ListingState, features: Record<string, string>[]) {\n state.currentVehicleFeatures = features.map((feature) => feature.value);\n },\n [types.SET_VEHICLE_MAKE](state: ListingState, value: string) {\n set(state.currentListing, 'vehicle.make', value);\n },\n [types.SET_VEHICLE_MODEL](state: ListingState, value: string) {\n set(state.currentListing, 'vehicle.model', value);\n },\n [types.SET_VEHICLE_COLOR](state: ListingState, color: string) {\n set(state.currentListing, 'vehicle.color', color);\n },\n [types.SET_VEHICLE_SEATS](state: ListingState, seats: number) {\n set(state.currentListing, 'vehicle.seats', seats);\n },\n [types.SET_VEHICLE_DOORS](state: ListingState, doors: number) {\n set(state.currentListing, 'vehicle.doors', doors);\n },\n [types.SET_VEHICLE_PLATE](state: ListingState, plate: string) {\n set(state.currentListing, 'vehicle.plate', plate);\n },\n [types.SET_VEHICLE_CLASS](state: ListingState, value: VehicleClass) {\n state.currentListing = {\n ...state.currentListing,\n vehicle: {\n ...state.currentListing.vehicle,\n vehicle_class: value\n }\n };\n },\n\n [types.TOGGLE_PAUSE_CURRENT_LISTING](state: ListingState) {\n state.currentListing.paused = !state.currentListing.paused;\n },\n [types.SET_CURRENT_LISTING_CHECKOUT_MODE](state: ListingState, mode: string) {\n state.currentListing.checkout_mode = mode;\n },\n\n [types.SET_CURRENT_DECODED_VIN](vehicleData) {\n console.dir('SET_CURRENT_DECODED_VIN');\n console.dir(vehicleData);\n },\n [types.SET_EXISTING_LISTING_DATA](state: ListingState, data: any) {\n Object.keys(data).forEach(key => {\n if (data[key] === null || typeof data[key] !== 'object') {\n // For null or non-object properties, assign directly\n state.currentListing[key] = data[key];\n } else {\n // Ensure the nested object exists\n if (!state.currentListing[key]) state.currentListing[key] = {};\n\n // Assign properties of the nested object\n Object.keys(data[key]).forEach(subKey => {\n state.currentListing[key][subKey] = data[key][subKey];\n });\n }\n });\n },\n [types.SET_CURRENT_NEW_LISTING](state: ListingState, listing: ListingInterface) {\n state.currentListing.name = listing.name;\n state.currentListing.vehicle.year = listing.vehicle.year;\n state.currentListing.vehicle.make = listing.vehicle.make;\n state.currentListing.vehicle.model = listing.vehicle.model;\n state.currentListing.vehicle.color = listing.vehicle.color;\n state.currentListing.vehicle.plate = listing.vehicle.plate;\n state.currentListing.pricing.amount = listing.pricing.amount;\n state.currentListing.pricing.price_period = listing.pricing.price_period;\n },\n\n [types.SET_CURRENT_LISTING](state: ListingState, listing: ListingInterface) {\n state.currentListing.loaded = true;\n\n if (listing.vehicle === null) {\n state.currentListing = {...state.currentListing, ...listing};\n\n // Reset vehicle object\n state.currentListing.vehicle = {...defaultVehicle};\n } else {\n state.currentListing = {...state.currentListing, ...listing};\n }\n // Direct property assignment for age_requirements\n state.currentListing.age_requirements = {\n min_age: listing.min_age || 21,\n seasoned_driver: listing.seasoned_driver || 25\n };\n\n state.listingInit = true;\n\n // Deep clone using JSON methods\n state.originalListing = JSON.parse(JSON.stringify(state.currentListing));\n\n\n // Find and update or add the listing in allListings\n let allListingIndex = -1;\n // if state.allListings is undefined set it to an empty array\n if (!state.allListings) {\n state.allListings = [];\n }\n\n if (state.allListings) {\n allListingIndex = state.allListings.findIndex(l => l.l_id === listing.l_id);\n }\n if (allListingIndex >= 0) {\n state.allListings[allListingIndex] = listing;\n } else {\n state.allListings.push(listing);\n }\n },\n\n [types.SET_CURRENT_LISTING_BOOKINGS](state: ListingState, bookings: BookingInterface[]) {\n state.currentListing.bookings = bookings;\n },\n [types.SET_CURRENT_LISTING_MILE_ALLOWANCE](state: ListingState, data) {\n if (data.miles_included) {\n state.currentListing.miles_included = data.miles_included;\n }\n if (data.distance_allowance_max) {\n state.currentListing.distance_allowance_max = data.distance_allowance_max;\n }\n },\n [types.SET_CURRENT_LISTING_DISCOUNTABLE](state: ListingState, discountable: boolean) {\n state.currentListing.pricing.discountable = discountable\n },\n [types.SET_CURRENT_LISTING_DURATION_DISCOUNT](state: ListingState, discount: any) {\n console.dir(discount);\n if (discount.threeDayPercentageDiscount) {\n state.currentListing.pricing.threeDayPercentageDiscount = discount.threeDayPercentageDiscount;\n }\n if (discount.weeklyPercentageDiscount) {\n state.currentListing.pricing.weeklyPercentageDiscount = discount.weeklyPercentageDiscount;\n }\n if (discount.monthlyPercentageDiscount) {\n state.currentListing.pricing.monthlyPercentageDiscount = discount.monthlyPercentageDiscount;\n }\n },\n [types.SET_CURRENT_TRIP_EXTRA](state: ListingState, extras) {\n state.currentExtra = extras;\n },\n [types.SET_ALL_EXTRAS](state: ListingState, extras) {\n state.allExtras = extras;\n },\n [types.SET_LISTING_PRICE](state: ListingState, amount: number) {\n state.currentListing.pricing.amount = amount;\n },\n [types.SET_LISTING_VEHICLE](state: ListingState, data: any) {\n if (data.last_odometer_reading) {\n state.currentListing.vehicle.last_odometer_reading = data.last_odometer_reading;\n }\n },\n [types.SET_LISTING_PRICE_TAXABLE](state: ListingState, taxable: boolean) {\n state.currentListing.pricing.taxable = taxable;\n },\n [types.SET_LISTING_PRICE_TAX_CATEGORY](state: ListingState, tax_category: TaxCategory) {\n state.currentListing.tax_category = tax_category;\n },\n [types.SET_LISTING_SEC_DEP](state: ListingState, amount: number) {\n state.currentListing.pricing.sec_dep = amount;\n },\n [types.SET_LISTING_SEC_DEP_CREDIT](state: ListingState, amount: number) {\n console.dir('SET_LISTING_SEC_DEP_CREDIT');\n console.dir(amount);\n state.currentListing.pricing.security_deposit_credit = amount;\n },\n [types.SET_LISTING_SEC_DEP_DEBIT](state: ListingState, amount: number) {\n state.currentListing.pricing.security_deposit_debit = amount;\n },\n [types.SET_LISTING_MILES_OVERAGE](state: ListingState, amount: number) {\n state.currentListing.miles_extra = amount;\n },\n [types.SET_CURRENT_LISTING_IMAGES](state: ListingState, images: any[]) {\n state.currentListing.listing_images = images;\n },\n [types.SET_LISTING_AVAILABILITY_MESSAGE](state: ListingState, message: string) {\n state.availability_message = message;\n },\n [types.SET_LISTING_DAILY_PRICES](state: ListingState, prices: DailyPrice[]) {\n state.dailyPricing = prices;\n },\n [types.CLEAR_LISTING_FORM_ERRORS](state: ListingState, form_field: string | null = null) {\n if (form_field === null || form_field === undefined) {\n state.form.errors.clear();\n } else {\n state.form.errors.clear(form_field);\n }\n },\n [types.SET_LISTING_FORM_ERRORS](state: ListingState, errors: string | Record<string, string[]>) {\n state.form.errors.set(errors);\n },\n [types.RESET_CURRENT_LISTING](state: ListingState) {\n state.currentListing = {\n active: false,\n approved: false,\n archived_at: '',\n checkout_mode: '',\n commission_partners: undefined,\n cover_photo: '',\n distance_allowance_max: 0,\n is_custodian: false,\n l_id: '',\n listing_image: '',\n longer_weekend_trip_preferred: false,\n miles_extra: 0,\n miles_included: 0,\n min_age: 0,\n minimum_request_duration: 0,\n order: 0,\n paused: false,\n provider_listings: undefined,\n seasoned_driver: 0,\n slug: '',\n sub_title: '',\n timezone: '',\n title: '',\n extras: [],\n use_esign_template: false,\n use_secondary_driver: false,\n loaded: false,\n name: '',\n pricing: {\n price_type: 'flat_fee',\n price_period: 'Day',\n price_structure_id: null,\n amount: 1,\n security_deposit_credit: 0,\n security_deposit_debit: 0,\n adjusted_amount: 0,\n discountable: false,\n taxable: false,\n original_price: 0,\n price_structure: null,\n sec_dep: 0,\n total_per_day: 0,\n monthlyPercentageDiscount: 0,\n threeDayPercentageDiscount: 0,\n weeklyPercentageDiscount: 0,\n },\n listing_images: [],\n padding_before: 0,\n padding_after: 0,\n vehicle: {...defaultVehicle},\n\n bookings: []\n };\n state.originalListing = null;\n },\n};\n\nconst actions = {\n\n setAvailableFilters({commit}, data: { years?: number[], makes?: string[], models?: string[] }) {\n commit(types.SET_LISTING_FILTER_AVAILABLE_FILTERS, data);\n },\n toggleListingFilter({commit}, filter: 'year' | 'make' | 'model') {\n commit(types.TOGGLE_LISTING_FILTER, filter);\n },\n setSelectedFilters({commit}, data: { years?: number[], makes?: string[], models?: string[] }) {\n commit(types.SET_LISTING_FILTER_SELECTED_FILTERS, data);\n },\n\n clearFilters({commit}) {\n commit(types.CLEAR_LISTING_FILTER);\n },\n\n /**\n * Fetch a listing\n */\n async fetchListing({commit}, l_id: string) {\n try {\n const responseData = await performApiRequest(commit, 'SET_LISTING_LOADING', 'listing', () => axios.get(`/v1/listing/${l_id}`));\n commit(types.SET_LISTING, responseData.listing);\n commit(types.SET_CURRENT_LISTING, responseData.listing);\n commit(types.SET_VEHICLE_FEATURES, responseData?.listing?.vehicle?.details);\n commit('booking/SET_BOOKING_LISTING', responseData.listing, {root: true});\n EventBus.$emit('fetch-listing-success');\n\n commit('SET_LISTING_INIT', true);\n return responseData.listing;\n } catch (error) {\n }\n },\n\n /**\n * Fetch all listings\n */\n async fetchListings({commit}) {\n try {\n const responseData = await performApiRequest(commit, 'SET_LISTING_LOADING', 'listings', () => axios.get('/v1/listings'));\n commit(types.SET_ALL_LISTINGS, responseData.listings);\n EventBus.$emit('fetch-listings-success');\n commit(types.SET_LISTING_INIT, true);\n } catch (error) {\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n }\n },\n\n /**\n * Fetch all fleet resource listings\n */\n async fetchFleetResourcesListings({commit}, refresh = false) {\n if (state.fleetResourceListingsLoaded && !refresh) {\n return;\n }\n\n try {\n const responseData = await performApiRequest(commit, 'SET_LISTING_LOADING', 'listings', () => axios.get('/v1/fleet-resource-listings'));\n commit('SET_FLEET_RESOURCE_LISTINGS', responseData.listings);\n } catch (error) {\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n }\n },\n\n\n /**\n * Add a listing\n */\n async addListing({commit}, listing: ListingInterface) {\n try {\n commit('CLEAR_LISTING_FORM_ERRORS');\n\n const responseData = await performApiRequest(commit, 'SET_LISTING_LOADING', 'addListing', () => axios.post('/v1/listings', listing));\n commit('SET_CURRENT_LISTING', responseData.listing);\n push.success({\n message: 'New listing added successfully!',\n });\n\n return responseData.listing;\n } catch (e) {\n console.dir(e);\n const errorMessage = e.response?.data?.message || 'There was an error';\n const statusCode = e.response?.status;\n\n commit('SET_LISTING_FORM_ERRORS', e.response.data.errors);\n\n if (statusCode === 401 || statusCode === 422) {\n push.error({\n message: errorMessage,\n });\n } else {\n commit('SET_LISTING_FORM_ERRORS', e.response.data.errors);\n }\n\n throw e;\n }\n },\n\n\n /**\n * Delete a listing\n */\n async deleteListing({commit}, listing: ListingInterface) {\n try {\n await performApiRequest(commit, 'SET_LISTING_LOADING', 'deleteListing', () => axios.delete(`/v1/listings/${listing.l_id}`));\n EventBus.$emit('delete-listing-success');\n push.success({\n message: 'Listing has been removed',\n });\n } catch (error) {\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n }\n },\n\n\n /**\n * Update the order of the listings\n */\n async updateOrder({commit}, listings: ListingInterface[]) {\n try {\n const responseData = await performApiRequest(commit, 'SET_LISTING_LOADING', 'listings_order', () => axios.put('/v1/listings/order', listings));\n commit('SET_ALL_LISTINGS', responseData.listings);\n commit('SET_FLEET_RESOURCE_LISTINGS', responseData.listings);\n } catch (error) {\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n }\n },\n\n\n /**\n * Get a listings bookings\n */\n fetchListingBookings({commit}, l_id: string) {\n axios.get(`/v1/listings/${l_id}/bookings?future=1`)\n .then((response) => {\n commit(types.SET_CURRENT_LISTING_BOOKINGS, response.data.bookings);\n EventBus.$emit('fetch-listing-success');\n }).catch(() => {\n }).finally(() => {\n commit('SET_LISTING_INIT', true);\n });\n },\n\n /**\n * Get a listings bookings\n */\n async getVehicleIncidents({commit}, l_id: string) {\n try {\n const responseData = await performApiRequest(commit, 'SET_LISTING_LOADING', 'getIncidents', () => axios.get(`/v1/vehicle-incidents?l_id=${l_id}`));\n commit(types.SET_CURRENT_LISTING_INCIDENTS, responseData.incidents);\n EventBus.$emit('fetch-incidents-success');\n } catch (error) {\n }\n },\n\n /**\n * Save a vehicle incident\n */\n async saveIncident({commit}, data: VehicleIncident) {\n try {\n await performApiRequest(commit, 'SET_LISTING_LOADING', 'saveIncident', () => axios.post('/v1/vehicle-incidents', data));\n EventBus.$emit('save-incidents-success');\n } catch (error) {\n }\n },\n /**\n * Update a vehicle incident\n */\n async updateIncident({commit}, data: VehicleIncident) {\n try {\n await performApiRequest(commit, 'SET_LISTING_LOADING', 'updateIncident', () => axios.put(`/v1/vehicle-incidents/${data.uuid}`, data));\n EventBus.$emit('update-incidents-success');\n } catch (error) {\n }\n },\n\n /**\n * Delete a vehicle incident\n */\n async deleteIncident({commit}, uuid: string) {\n try {\n await performApiRequest(commit, 'SET_LISTING_LOADING', 'deleteIncident', () => axios.delete(`/v1/vehicle-incidents/${uuid}`));\n EventBus.$emit('delete-incidents-success');\n } catch (error) {\n }\n },\n\n\n /**\n * Get a listings bookings\n */\n checkAvailability({commit}, {l_id, dates}) {\n axios.get(`/v1/listing/${l_id}/availability?start=${dates.start}&end=${dates.end}`)\n .then((response) => {\n commit('SET_LISTING_AVAILABILITY_MESSAGE', get(response, 'data.unavailableDescription', ''));\n }).catch((e) => {\n commit('SET_LISTING_AVAILABILITY_MESSAGE', get(e, 'response.data.unavailableDescription', ''));\n }).finally(() => {\n commit('SET_LISTING_INIT', true);\n });\n },\n\n /**\n * Get all listings availability\n */\n checkAllAvailability({commit}, dates: { start: string, end: string }) {\n axios.get(`/v1/listings/availability?start=${dates.start}&end=${dates.end}`)\n .then((response) => {\n commit('SET_LISTING_AVAILABILITY_MESSAGE', get(response, 'data.unavailableDescription', ''));\n }).catch((e) => {\n commit('SET_LISTING_AVAILABILITY_MESSAGE', get(e, 'response.data.unavailableDescription', ''));\n }).finally(() => {\n commit('SET_LISTING_INIT', true);\n });\n },\n\n\n /**\n * Set an unavailable period\n */\n async setUnavailablePeriod({commit}, period: {\n l_id: string,\n trip_start: string,\n trip_end: string,\n source: string,\n notes: string,\n supplemental: boolean\n }) {\n try {\n commit('CLEAR_LISTING_FORM_ERRORS');\n const responseData = await performApiRequest(commit, 'SET_LISTING_LOADING', 'unavailable_period', () => axios.post(`/v1/listings/${period.l_id}/unavailability`, period));\n push.success({\n message: 'Unavailable period set successfully!',\n });\n commit(types.SET_CURRENT_LISTING_BOOKINGS, responseData.bookings);\n EventBus.$emit('set-unavailable-period-success', responseData);\n\n commit('SET_LISTING_INIT', true);\n } catch (error) {\n commit('SET_LISTING_FORM_ERRORS', error.response.data.errors);\n push.error({\n message: 'There was an error setting the unavailable period',\n });\n }\n },\n\n /**\n * Set an unavailable period from a FW booking\n */\n setUnavailablePeriodFromFWBooking({commit}, period: { l_id: string, source: string, b_id: string }) {\n commit('SET_LISTING_LOADING', {subject: 'unavailable_period', loading: true});\n commit('CLEAR_LISTING_FORM_ERRORS');\n\n axios.post(`/v1/listings/${period.l_id}/set-existing-unavailability`, period)\n .then((response) => {\n push.success({\n message: 'Unavailable period set successfully!',\n });\n commit(types.SET_CURRENT_LISTING_BOOKINGS, get(response, 'data.bookings', []));\n EventBus.$emit('set-unavailable-period-success', response.data);\n }).catch((e) => {\n console.dir(get(e, 'response.data.errors'));\n commit('SET_LISTING_FORM_ERRORS', e.response.data.errors);\n push.error({\n message: 'There was an error setting the unavailable period',\n });\n }).finally(() => {\n commit('SET_LISTING_LOADING', {subject: 'unavailable_period', loading: false});\n });\n },\n\n\n /**\n * Remove an unavailable period\n */\n removeUnavailablePeriod({commit}, period: { l_id: string, b_id: string }) {\n commit('SET_LISTING_LOADING', {subject: 'unavailable_period', loading: true});\n\n axios.delete(`/v1/listings/${period.l_id}/unavailability/${period.b_id}`)\n .then((response) => {\n commit(types.SET_CURRENT_LISTING_BOOKINGS, get(response, 'data.bookings', []));\n push.success({\n message: 'Unavailable period removed successfully!',\n });\n EventBus.$emit('RemoveUnavailablePeriodSuccess');\n }).catch(() => {\n push.error({\n message: 'There was an error removing this unavailable period',\n });\n }).finally(() => {\n commit('SET_LISTING_LOADING', {subject: 'unavailable_period', loading: false});\n commit('SET_LISTING_INIT', true);\n });\n },\n\n\n /**\n * Update an unavailable period\n */\n async updateUnavailablePeriod({commit}, period: {\n l_id: string,\n b_id: string,\n trip_start: string,\n trip_end: string\n }) {\n try {\n const responseData = await performApiRequest(commit, 'SET_LISTING_LOADING', 'unavailable_period', () => axios.put(`/v1/listings/${period.l_id}/unavailability/${period.b_id}`, period));\n commit(types.SET_CURRENT_LISTING_BOOKINGS, responseData.bookings);\n push.success({\n message: 'Unavailable period updated successfully!',\n });\n EventBus.$emit('UpdateUnavailablePeriodSuccess');\n commit('SET_LISTING_INIT', true);\n\n return responseData;\n } catch (error) {\n EventBus.$emit('update-unavailable-period-failed');\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n }\n },\n\n\n /**\n * Get a company listing\n */\n async fetchCompanySingleListings({commit}, l_id: string) {\n commit('SET_LISTING_LOADING', {subject: 'listing', loading: true});\n\n await axios.get(`/v1/listings/${l_id}`)\n .then((response) => {\n commit('SET_CURRENT_LISTING', response.data.listing);\n commit('SET_VEHICLE_FEATURES', get(response.data.listing, 'vehicle.details', {}));\n commit('SET_VEHICLE_EXTRAS', get(response.data.listing, 'extras', []));\n EventBus.$emit('fetch-listing-success');\n }).catch(() => {\n }).finally(() => {\n commit('SET_LISTING_LOADING', {subject: 'listing', loading: false});\n commit('SET_LISTING_INIT', true);\n });\n },\n\n fetchCompanySingleListingExtras({commit}, l_id: string) {\n commit('SET_LISTING_LOADING', {subject: 'listing_extras', loading: true});\n\n axios.get(`/v1/listings/${l_id}/extras`)\n .then((response) => {\n commit('SET_VEHICLE_EXTRAS', get(response.data, 'extras', []));\n }).catch(() => {\n }).finally(() => {\n commit('SET_LISTING_LOADING', {subject: 'listing_extras', loading: false});\n });\n },\n\n /**\n * Update a vehicles details\n */\n async updateVehicleDetails({commit, dispatch}, data: { v_id: string, l_id: string, vehicleFeatures: string[] }) {\n try {\n await performApiRequest(commit, 'SET_LISTING_LOADING', 'vehicleDetails', () => axios.put(`/v1/vehicles/${data.v_id}/details`, data));\n EventBus.$emit('save-vehicle-details-success');\n dispatch('fetchCompanySingleListings', data.l_id);\n commit('SET_LISTING_SNACK', {subject: 'vehicle_details_success', value: true});\n } catch (error) {\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n }\n },\n\n\n /**\n * Reset the current listing\n */\n resetListing({commit}) {\n commit(types.RESET_CURRENT_LISTING);\n },\n\n\n /**\n * Save a listing\n */\n async saveListing({commit}, listing: ListingInterface) {\n try {\n const responseData = await performApiRequest(commit, 'SET_LISTING_LOADING', 'saveListing', () => axios.put(`/v1/listings/${listing.l_id}`, listing));\n commit('CLEAR_LISTING_FORM_ERRORS');\n push.success({\n message: 'Listings saved successfully',\n });\n commit('SET_CURRENT_LISTING', responseData.listing);\n EventBus.$emit('save-listing-success');\n } catch (e) {\n commit('SET_LISTING_FORM_ERRORS', e.response.data.errors);\n\n push.error({\n message: e.response?.data?.errors?.message || 'There was an error pausing the listing',\n });\n }\n },\n\n\n /**\n * Pause a listing\n */\n async pauseListing({commit, state}, data: { mode: string, listings: string[] }) {\n try {\n await performApiRequest(commit, 'SET_LISTING_LOADING', 'pausing', () => axios.put('/v1/listings/pause', {\n mode: data.mode,\n listings: data.listings\n }));\n push.success({\n message: 'Listings saved successfully',\n });\n EventBus.$emit('listings-toggle-pause-success');\n\n // Loop through data.listings and update the paused state\n data.listings.forEach((listing) => {\n const index = state.fleetResourceListings.findIndex(item => item.l_id === listing);\n\n if (index !== -1) {\n commit('SET_FLEET_RESOURCE_LISTINGS_DATA', {\n l_id: listing,\n data: {\n paused: !state.fleetResourceListings[index].paused,\n },\n });\n }\n });\n } catch (error) {\n push.error({\n message: error?.response?.data?.message || 'There was an error pausing the listing',\n });\n }\n },\n\n\n /**\n * Fetch a Listings daily pricing\n */\n async fetchDailyPrices({commit}, {l_id, start, end}) {\n try {\n let qString = '';\n if (start) {\n qString += `?start=${start}`;\n }\n if (end) {\n qString += start ? `&end=${end}` : `?end=${end}`;\n }\n\n const responseData = await performApiRequest(commit, 'SET_LISTING_LOADING', 'dailyPrices', () => axios.get(`/v1/listings/${l_id}/daily_pricing${qString}`));\n commit(types.SET_LISTING_DAILY_PRICES, responseData.dailyPricing);\n EventBus.$emit('get-listings-daily-price-success');\n } catch (error) {\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n }\n },\n\n\n /**\n * Update a Listings daily pricing\n */\n updateDailyPrice({commit}, data: { l_id: string, date: string, price: number, sources: object }) {\n commit('SET_LISTING_LOADING', {subject: 'updateDailyPrices', loading: true});\n\n axios.put(`/v1/listings/${data.l_id}/daily_pricing`, data)\n .then((response) => {\n EventBus.$emit('update-listings-daily-price-success', response);\n }).catch(() => {\n }).finally(() => {\n commit('SET_LISTING_LOADING', {subject: 'updateDailyPrices', loading: false});\n });\n },\n\n\n /**\n * Get all Extras\n */\n getAllExtras({commit, state}) {\n commit('SET_LISTING_LOADING', {subject: 'getAllExtras', loading: true});\n\n axios.get('/v1/extras', state.currentExtra)\n .then((response) => {\n commit(types.SET_ALL_EXTRAS, get(response, 'data.extras'));\n }).catch(() => {\n }).finally(() => {\n commit('SET_LISTING_LOADING', {subject: 'getAllExtras', loading: false});\n });\n },\n\n\n /**\n * Import Turo listings\n */\n importTuroListings({commit}, {listings, turo_uuid}) {\n commit('SET_LISTING_LOADING', {subject: 'import_listings', loading: true});\n EventBus.$emit('save-imported-listings-started', 'turo');\n\n axios.post(`/v1/listings/import/turo/${turo_uuid}`, {listings})\n .then((response) => {\n commit('company/SET_COMPANY', response.data.company, {root: true});\n commit('SET_ALL_LISTINGS', get(response.data.company, 'listings', []));\n EventBus.$emit('save-turo-imported-listings-success');\n push.success({\n message: 'Turo listing Import success',\n });\n }).catch((e) => {\n commit('SET_LISTING_FORM_ERRORS', e.response.data.errors);\n }).finally(() => {\n EventBus.$emit('save-turo-imported-listings-failed');\n commit('SET_LISTING_LOADING', {subject: 'import_listings', loading: false});\n });\n },\n\n syncTuroListings({commit}, {listings, turo_uuid}) {\n commit('SET_LISTING_LOADING', {subject: 'import_listings', loading: true});\n\n axios.post(`/v1/listings/sync/turo/${turo_uuid}/listings`, {listings})\n .then(() => {\n }).catch((e) => {\n commit('SET_LISTING_FORM_ERRORS', e.response.data.errors);\n }).finally(() => {\n EventBus.$emit('save-turo-imported-listings-failed');\n commit('SET_LISTING_LOADING', {subject: 'import_listings', loading: false});\n });\n },\n\n /**\n * Match Turo vehicle\n */\n matchTuroVehicle({commit}, data) {\n commit('SET_LISTING_LOADING', {subject: 'saveListing', loading: true});\n\n axios.post(`/v1/listings/${data.listing_id}/match-turo-vehicle`, {\n id: data.turo_vehicle_id,\n turo_account_uuid: data.turo_account_uuid\n }).then((response) => {\n commit('SET_ALL_LISTINGS', get(response.data, 'listings', []));\n commit('SET_CURRENT_LISTING', get(response.data, 'listing', []));\n push.success({\n message: 'Matched Turo vehicle has been added from this listing.',\n });\n EventBus.$emit('matched-turo-vehicle-with-listing-success');\n }).catch((error) => {\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n }).finally(() => {\n commit('SET_LISTING_LOADING', {subject: 'saveListing', loading: false});\n });\n },\n\n /**\n * Match Bouncie vehicles\n */\n matchBouncieVehicle({commit}, {l_id, bouncie_uuid}) {\n commit('SET_LISTING_LOADING', {subject: 'matchBouncieVehicle', loading: true});\n\n axios.post(`/v1/listings/${l_id}/match-bouncie-vehicle`, {id: bouncie_uuid})\n .then((response) => {\n commit('SET_ALL_LISTINGS', get(response.data, 'listings', []));\n commit('SET_CURRENT_LISTING', get(response.data, 'listing', []));\n push.success({\n message: 'Matched Bouncie vehicle has been added from this listing.',\n });\n EventBus.$emit('matched-bouncie-vehicle-with-listing-success');\n }).catch(() => {\n }).finally(() => {\n commit('SET_LISTING_LOADING', {subject: 'matchBouncieVehicle', loading: false});\n });\n },\n\n\n /**\n * Un-match Bouncie vehicles\n */\n unMatchBouncieVehicle({commit}, l_id: string) {\n commit('SET_LISTING_LOADING', {subject: 'saveListing', loading: true});\n\n axios.delete(`/v1/listings/${l_id}/matched-bouncie-vehicle`)\n .then((response) => {\n commit('SET_ALL_LISTINGS', get(response.data, 'listings', []));\n commit('SET_CURRENT_LISTING', get(response.data, 'listing', []));\n push.success({\n message: 'Matched Bouncie vehicle has been removed from this listing.',\n });\n EventBus.$emit('unmatched-bouncie-vehicle-with-listing-success');\n }).catch(() => {\n }).finally(() => {\n commit('SET_LISTING_LOADING', {subject: 'saveListing', loading: false});\n });\n },\n\n matchTeslaVehicle({commit}, data: { l_id: string, tesla: string }) {\n commit('SET_LISTING_LOADING', {subject: 'matchingTeslaVehicle', loading: true});\n axios.post(`/v1/listings/${data.l_id}/match-tesla-vehicle`, {uuid: data.tesla})\n .then((response) => {\n commit('SET_ALL_LISTINGS', get(response.data, 'listings', []));\n commit('SET_CURRENT_LISTING', get(response.data, 'listing', []));\n commit('tesla/SET_TESLA_CONNECTIONS', get(response.data, 'company.connections.tesla', []), {root: true});\n commit('tesla/SET_CURRENT_WORKING_TESLA_VEHICLE', get(response.data, 'teslaVehicle', []), {root: true});\n push.success({\n message: 'Matched Tesla vehicle has been added from this listing.',\n });\n EventBus.$emit('matched-tesla-vehicle-with-listing-success');\n }).catch(() => {\n }).finally(() => {\n commit('SET_LISTING_LOADING', {subject: 'matchingTeslaVehicle', loading: false});\n });\n },\n\n matchGetaroundVehicle({commit}, vehicle) {\n commit('SET_LISTING_LOADING', {subject: 'saveListing', loading: true});\n axios.post(`/v1/company/${StorageService.getCompanyUuid()}/listings/${state.currentListing.l_id}/match-getaround-vehicle`, {id: vehicle.id})\n .then((response) => {\n commit('SET_ALL_LISTINGS', response.data.listings);\n commit('SET_CURRENT_LISTING', response.data.listing);\n push.success({\n message: 'Matched Getaround vehicle has been added from this listing.',\n });\n EventBus.$emit('matched-getaround-vehicle-with-listing-success');\n }).catch(() => {\n }).finally(() => {\n commit('SET_LISTING_LOADING', {subject: 'saveListing', loading: false});\n });\n },\n\n\n /**\n * Un-match a Turo vehicle from Fleetwire\n */\n unMatchTuroVehicle({commit, state}) {\n commit('SET_LISTING_LOADING', {subject: 'saveListing', loading: true});\n axios.delete(`/v1/listings/${state.currentListing.l_id}/matched-turo-vehicle`)\n .then((response) => {\n commit('SET_ALL_LISTINGS', response.data.listings);\n commit('SET_CURRENT_LISTING', response.data.listing);\n push.success({\n message: 'Matched Turo vehicle has been removed from this listing.',\n });\n }).catch(() => {\n }).finally(() => {\n commit('SET_LISTING_LOADING', {subject: 'saveListing', loading: false});\n });\n },\n\n unMatchTeslaVehicle({commit}, listing: ListingInterface) {\n commit('SET_LISTING_LOADING', {subject: 'matchingTeslaVehicle', loading: true});\n axios.delete(`/v1/company/${StorageService.getCompanyUuid()}/listings/${listing.l_id}/matched-tesla-vehicle`)\n .then((response) => {\n commit('SET_ALL_LISTINGS', response.data.listings);\n commit('SET_CURRENT_LISTING', response.data.listing);\n commit('tesla/SET_CURRENT_WORKING_TESLA_VEHICLE', response.data?.teslaVehicle, {root: true});\n push.success({\n message: 'Matched Tesla vehicle has been removed from this listing.',\n });\n }).catch(() => {\n }).finally(() => {\n commit('SET_LISTING_LOADING', {subject: 'matchingTeslaVehicle', loading: false});\n });\n },\n\n unMatchGetaroundVehicle({commit}) {\n commit('SET_LISTING_LOADING', {subject: 'saveListing', loading: true});\n axios.delete(`/v1/company/${StorageService.getCompanyUuid()}/listings/${state.currentListing.l_id}/matched-getaround-vehicle`)\n .then((response) => {\n commit('SET_CURRENT_LISTING', response.data.listing);\n push.success({\n message: 'Matched Getaround vehicle has been removed from this listing.',\n });\n }).catch(() => {\n }).finally(() => {\n commit('SET_LISTING_LOADING', {subject: 'saveListing', loading: false});\n });\n },\n\n\n /**\n * Archive a listing\n */\n async archiveListing({commit}, listing: ListingInterface) {\n try {\n await performApiRequest(commit, 'SET_LISTING_LOADING', 'archiveListing', () => axios.post(`/v1/listings/${listing.l_id}/archive`));\n push.success({\n message: 'Listing has been archived',\n });\n } catch (error) {\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n }\n },\n\n\n /**\n * Delete a listing\n */\n async deleteListings({commit}, listings: string[]) {\n try {\n await performApiRequest(commit, 'SET_LISTING_LOADING', 'deleteListing', () => axios.post('/v1/listings/delete', {listings}));\n EventBus.$emit('delete-listing-success');\n push.success({\n message: 'Listing has been removed',\n });\n } catch (error) {\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n }\n },\n\n updateListingImageOrder({commit}, images: string[]) {\n console.dir(images);\n commit('SET_LISTING_LOADING', {subject: 'saveListing', loading: true});\n\n axios.put(`/v1/listings/${state.currentListing.l_id}/images`, {images})\n .then(() => {\n }).catch(() => {\n }).finally(() => {\n commit('SET_LISTING_LOADING', {subject: 'saveListing', loading: false});\n });\n },\n\n /**\n *\n * @param commit\n */\n resetAndReImportCarShareImages({commit}) {\n commit('SET_LISTING_LOADING', {subject: 'importImages', loading: true});\n axios.post(`/v1/listings/${state.currentListing.l_id}/reset-import-images`)\n .then(() => {\n EventBus.$emit('reimport-listing-image-success');\n }).catch((e) => {\n push.error({\n message: e?.response?.data?.message || 'There was an error',\n });\n }).finally(() => {\n commit('SET_LISTING_LOADING', {subject: 'importImages', loading: false});\n });\n },\n\n /**\n *\n */\n async getVehicleFeatures({commit}) {\n try {\n const responseData = await performApiRequest(commit, 'SET_LISTING_LOADING', 'vehicleFeatures', () => axios.get('/v1/vehicle-features'));\n commit(types.SET_ALL_AVAILABLE_FEATURES, responseData.features);\n EventBus.$emit('sync-listing-data-success', responseData.details);\n } catch (error) {\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n }\n },\n\n /**\n * Sync car share data\n */\n syncCarShareData({commit}) {\n commit('SET_LISTING_LOADING', {subject: 'syncCarShareData', loading: true});\n\n axios.post(`/v1/listings/${state.currentListing.l_id}/sync-car-share-data`)\n .then((response) => {\n EventBus.$emit('sync-listing-data-success', response.data.details);\n }).catch(() => {\n }).finally(() => {\n commit('SET_LISTING_LOADING', {subject: 'syncCarShareData', loading: false});\n });\n },\n\n\n /**\n * Delete a single listing image\n */\n deleteListingImage({state, commit}, image: string) {\n commit('SET_LISTING_LOADING', {subject: 'importDelete', loading: true});\n\n axios.delete(`/v1/listings/${state.currentListing.l_id}/images/${image}`)\n .then((response) => {\n push.success({\n message: 'Listing image removed',\n });\n commit(types.SET_CURRENT_LISTING, response.data.listing);\n EventBus.$emit('delete-listing-image-success');\n }).catch(() => {\n }).finally(() => {\n commit('SET_LISTING_LOADING', {subject: 'importDelete', loading: false});\n });\n },\n\n setListingBookableTimes({commit}) {\n const startTimes = [];\n let time: string;\n let timeF: string;\n let ampm: string;\n let lefZero: string | number;\n\n for (let i = 0; i < 24; i++) {\n time = `${i}:00`;\n timeF = i > 12 ? `${(i - 12)}:00` : `${i}:00`;\n ampm = i >= 12 ? 'pm' : 'am';\n lefZero = i >= 10 ? '' : 0;\n startTimes.push({timeF: `${timeF} ${ampm}`, time: `${lefZero}${time}`});\n\n time = `${i}:30`;\n timeF = i >= 12 ? `${(i - 12)}:30` : `${i}:30`;\n ampm = i >= 12 ? 'pm' : 'am';\n lefZero = i >= 10 ? '' : 0;\n startTimes.push({timeF: `${timeF} ${ampm}`, time: `${lefZero}${time}`});\n }\n\n commit('SET_BOOKABLE_TIMES', startTimes);\n },\n\n async vinDecode({commit}, vin: string) {\n if (vin.length === 17) {\n try {\n const responseData = await performApiRequest(commit, 'SET_LISTING_LOADING', 'decoding_vin', () => axios.get(`/v1/decode-vin/${vin}`));\n EventBus.$emit('listing-vin-decoded-success', responseData.vehicleData);\n commit('SET_CURRENT_DECODED_VIN', responseData.vehicleData);\n } catch (error) {\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n }\n }\n },\n\n\n /**\n * Import listings from csv\n */\n importCSVListings({commit}, listings) {\n commit('SET_LISTING_LOADING', {subject: 'import_listings', loading: true});\n commit('CLEAR_LISTING_FORM_ERRORS');\n\n axios.post('/v1/listings/import/csv', {listings})\n .then((response) => {\n commit('listing/SET_ALL_LISTINGS', response.data.listings, {root: true});\n push.success({\n message: 'Imported listings successfully',\n });\n EventBus.$emit('import-csv-vehicles-success');\n }).catch((e) => {\n console.dir(e.response.data);\n commit('SET_LISTING_FORM_ERRORS', e.response.data.errors);\n\n push.error({\n message: e.response?.data?.errors?.plan_limits?.[0] || 'There was an error',\n });\n }).finally(() => {\n commit('SET_LISTING_LOADING', {subject: 'import_listings', loading: false});\n });\n },\n\n /**\n * Update odometer with a provider.\n */\n updateOdomWithProvider({commit}, {listing, provider}) {\n commit('SET_LISTING_LOADING', {subject: 'updateOdomProvider', loading: true});\n\n axios.post(`/v1/listings/${listing.l_id}/provider-update-odometer`, {provider})\n .then(() => {\n EventBus.$emit('update-odometer-with-provider-success');\n }).catch(() => {\n }).finally(() => {\n commit('SET_LISTING_LOADING', {subject: 'updateOdomProvider', loading: false});\n });\n },\n};\n\nconst listingModule: Module<ListingState, RootState> = {\n namespaced: true,\n state,\n getters,\n actions,\n mutations,\n};\n\nexport default listingModule;","import axios from 'axios';\nimport {Form} from '@/plugins/FWForms/index';\nimport {EventBus} from '@/plugins/eventBus';\nimport {get} from 'lodash';\nimport * as types from '../mutation-types';\n\nexport interface LulaState {\n init: boolean;\n loading: Record<string, boolean>;\n form: Form<any>;\n connections: any[];\n vehicles: any[];\n}\n\nconst state: LulaState = {\n init: false,\n loading: {\n login: false,\n vehicles: false,\n matching: false,\n },\n form: new Form(),\n connections: [],\n vehicles: [],\n};\n\nconst getters = {\n init: (state: LulaState) => state.init,\n loading: (state: LulaState) => state.loading,\n form: (state: LulaState) => state.form,\n connections: (state: LulaState) => state.connections,\n vehicles: (state: LulaState) => state.vehicles,\n};\n\nconst mutations = {\n [types.SET_LULA_LOADING](state: LulaState, loading: { subject: string, loading: boolean }) {\n state.loading[loading.subject] = loading.loading;\n },\n [types.SET_LULA_CONNECTIONS](state: LulaState, connections) {\n state.connections = connections;\n },\n [types.SET_LULA_VEHICLES](state: LulaState, vehicles) {\n state.vehicles = vehicles;\n },\n};\n\nconst actions = {\n\n\n /**\n * Get tax categories\n */\n login({commit}, payload) {\n commit('SET_LULA_LOADING', {subject: 'login', loading: true});\n\n axios.post('/v1/lula/login', payload)\n .then(() => {\n // commit('SET_LULA_CONNECTIONS', get(response, 'data.lula', []));\n }).catch(() => {\n }).finally(() => {\n commit('SET_LULA_LOADING', {subject: 'login', loading: false});\n });\n },\n\n fetchVehicles({commit}, payload) {\n commit('SET_LULA_LOADING', {subject: 'vehicles', loading: true});\n\n axios.post('/v1/lula/vehicles', payload)\n .then((response) => {\n commit('SET_LULA_VEHICLES', get(response, 'data.vehicles', []));\n }).catch(() => {\n }).finally(() => {\n commit('SET_LULA_LOADING', {subject: 'vehicles', loading: false});\n });\n },\n\n /**\n * Match Lula Vehicles\n */\n matchLulaVehicle({commit}, data) {\n commit('SET_LULA_LOADING', {subject: 'vehicles', loading: true});\n\n axios.post('/v1/lula/match-vehicle', data)\n .then(() => {\n EventBus.$emit('match-lula-vehicle-success');\n }).catch(() => {\n }).finally(() => {\n commit('SET_LULA_LOADING', {subject: 'vehicles', loading: false});\n });\n },\n\n /**\n * UnMatch Lula Vehicles\n */\n unMatchLulaVehicle({commit}, data) {\n commit('SET_LULA_LOADING', {subject: 'matching', loading: true});\n\n axios.post('/v1/lula/remove-matched-vehicle', data)\n .then(() => {\n EventBus.$emit('match-lula-vehicle-success');\n }).catch(() => {\n }).finally(() => {\n commit('SET_LULA_LOADING', {subject: 'matching', loading: false});\n });\n },\n};\n\nexport default {\n namespaced: true,\n state,\n mutations,\n actions,\n getters,\n};\n","import axios from 'axios';\nimport * as types from '../mutation-types';\nimport {performApiRequest} from \"@/store/helpers/vuex-helpers\";\nimport {Note} from \"@/types\";\n\nexport type NotableType = 'order' | 'document' | 'customer' | '*';\n\nexport type NewNote = {\n body: string,\n notable_id: string,\n notable_type: string,\n}\n\nexport type NotesPaginateOptions = {\n page?: number,\n sortBy?: string,\n sortDesc?: boolean[],\n itemsPerPage?: number,\n notable_type?: NotableType,\n notable_id?: string,\n}\n\nexport interface NoteResponseMeta {\n count: number,\n current_page: number,\n next_page: number,\n per_page: number,\n total: number,\n total_pages: number,\n}\n\nexport interface NoteResponseData {\n notes: {\n data: Note[],\n meta: NoteResponseMeta,\n }\n notable_type: NotableType,\n}\n\nexport interface NotesState {\n loading: Record<string, boolean>,\n notes: Note[],\n note: Note,\n}\n\nconst state: NotesState = {\n loading: {\n notes: false,\n createNote: false,\n deleteNote: false,\n },\n notes: [],\n note: null,\n};\n\nconst getters = {\n notes: (state: NotesState) => state.notes,\n note: (state: NotesState) => state.note,\n loading: (state: NotesState) => state.loading,\n};\n\nconst mutations = {\n [types.SET_NOTES_LOADING](state: NotesState, loading: { subject: string, loading: boolean }) {\n state.loading[loading.subject] = loading.loading;\n },\n};\n\nconst actions = {\n\n\n /**\n * Get all notes.\n */\n async getNotes({commit}, options: NotesPaginateOptions): Promise<NoteResponseData> {\n const {\n page = 1,\n sortBy = 'created_at',\n sortDesc = [true],\n itemsPerPage = 5,\n notable_type = '*',\n notable_id = null,\n } = options;\n\n const params = new URLSearchParams({\n page: page.toString(),\n sortBy,\n sortDesc: sortDesc.toString(), // Convert array to string\n itemsPerPage: itemsPerPage.toString(),\n notableType: notable_type,\n notable_id: notable_id ? notable_id.toString() : '',\n }).toString();\n\n const responseData = await performApiRequest(commit, 'SET_NOTES_LOADING', 'notes', () => axios.get(`/v1/notes?${params}`));\n return {\n notes: responseData.notes,\n notable_type,\n };\n },\n\n\n /**\n * Create a note.\n */\n async createNote({commit}, note: NewNote) {\n const responseData = await performApiRequest(commit, 'SET_NOTES_LOADING', 'createNote', () => axios.post('/v1/notes', note));\n return responseData.note;\n },\n\n\n /**\n * Delete a note.\n * @throws Error\n */\n async deleteNote({commit}, uuid: string) {\n await performApiRequest(commit, 'SET_NOTES_LOADING', 'deleteNote', () => axios.delete(`/v1/notes/${uuid}`));\n },\n};\n\nexport default {\n namespaced: true,\n state,\n mutations,\n actions,\n getters,\n};\n","import axios from 'axios';\nimport {EventBus} from '@/plugins/eventBus';\nimport {Form} from '@/plugins/FWForms/index';\nimport * as types from '../mutation-types';\nimport {performApiRequest} from \"@/store/helpers/vuex-helpers\";\n\nexport interface OutdoorsyState {\n loading: Record<string, boolean>;\n form: Form<any>;\n connections: any[];\n listings: any[];\n bookings: any[];\n}\n\nconst state: OutdoorsyState = {\n loading: {\n login: false,\n matching: false,\n toggle: false,\n listings: false,\n },\n form: new Form(),\n connections: [],\n listings: [],\n bookings: [],\n};\n\nconst getters = {\n form: (state: OutdoorsyState) => state.form,\n connections: (state: OutdoorsyState) => state.connections,\n loading: (state: OutdoorsyState) => state.loading,\n listings: (state: OutdoorsyState) => state.listings,\n bookings: (state: OutdoorsyState) => state.bookings,\n};\n\nconst mutations = {\n [types.SET_OUTDOORSY_LOADING](state: OutdoorsyState, loading: { subject: string, loading: boolean }) {\n state.loading[loading.subject] = loading.loading;\n },\n [types.SET_OUTDOORSY_CONNECTIONS](state: OutdoorsyState, connections) {\n state.connections = connections;\n },\n [types.SET_OUTDOORSY_LISTINGS](state: OutdoorsyState, listings) {\n state.listings = listings;\n },\n [types.SET_OUTDOORSY_BOOKINGS](state: OutdoorsyState, bookings) {\n state.bookings = bookings;\n },\n};\n\nconst actions = {\n\n\n /**\n * Login to Outdoorsy\n *\n * @param commit\n * @param {Object} credentials\n */\n async login({commit}, credentials) {\n try {\n const responseData = await performApiRequest(commit, 'SET_OUTDOORSY_LOADING', 'login', () => axios.post(`/v1/connections/outdoorsy`, credentials));\n EventBus.$emit('outdoorsy-connection-successful', responseData?.providers);\n commit('SET_OUTDOORSY_CONNECTIONS', responseData?.providers);\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'Outdoorsy connection connected successfully!',\n });\n } catch (error) {\n EventBus.$emit('SystemMessage', {\n type: 'error',\n message: 'Outdoorsy connection connection error.',\n });\n }\n },\n\n\n /**\n * Delete Outdoorsy\n *\n * @param commit\n * @param {Object} outdoorsy\n */\n async delete({commit}, outdoorsy) {\n try {\n const responseData = await performApiRequest(commit, 'SET_OUTDOORSY_LOADING', 'delete', () => axios.delete(`/v1/connections/outdoorsy/${outdoorsy.uuid}`));\n EventBus.$emit('delete-outdoorsy-connection-success');\n commit('SET_OUTDOORSY_CONNECTIONS', responseData.providers);\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'Outdoorsy connection deleted successfully!',\n });\n } catch (error) {\n }\n },\n\n\n /**\n * Toggle Outdoorsy active\n *\n * @param commit\n * @param {Object} outdoorsy\n */\n async toggleActive({commit}, outdoorsy) {\n commit('SET_OUTDOORSY_LOADING', {subject: 'toggle', loading: true});\n\n try {\n const responseData = await performApiRequest(commit, 'SET_OUTDOORSY_LOADING', 'toggle', () => axios.put(`/v1/connections/outdoorsy/${outdoorsy.uuid}/active`));\n commit('SET_OUTDOORSY_LISTINGS', responseData?.listings);\n EventBus.$emit('toggle-outdoorsy-listings-success');\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'Outdoorsy connection toggled successfully!',\n });\n } catch (error) {\n }\n },\n\n\n /**\n * Fetch Outdoorsy listings\n *\n * @param commit\n * @param {String} outdoorsy_uuid\n */\n async fetchOutdoorsyListings({commit}, outdoorsy_uuid) {\n try {\n const responseData = await performApiRequest(commit, 'SET_OUTDOORSY_LOADING', 'listings', () => axios.get(`/v1/connections/outdoorsy/${outdoorsy_uuid}/vehicles`));\n commit('SET_OUTDOORSY_LISTINGS', responseData?.listings);\n EventBus.$emit('fetch-outdoorsy-listings-success');\n } catch (error) {\n }\n },\n\n\n /**\n * Fetch Outdoorsy bookings\n *\n * @param commit\n * @param {String} outdoorsy_uuid\n */\n async fetchBookings({commit}, outdoorsy_uuid) {\n try {\n const responseData = await performApiRequest(commit, 'SET_OUTDOORSY_LOADING', 'listings', () => axios.get(`/v1/connections/outdoorsy/${outdoorsy_uuid}/vehicles`));\n commit('SET_OUTDOORSY_BOOKINGS', responseData?.listings);\n EventBus.$emit('fetch-outdoorsy-listings-success');\n } catch (error) {\n }\n },\n\n};\n\nexport default {\n namespaced: true,\n state,\n mutations,\n actions,\n getters,\n};\n","import {asyncRoutes, constantRoutes} from '@/router/routes';\nimport * as types from '../mutation-types';\nimport type {RouteMeta, RouteRecordRaw} from 'vue-router';\n\n\n/**\n * Check if it matches the current user right by 'meta.role'\n */\nfunction canAccess(roles: string[], permissions: string[], route: RouteRecordRaw): boolean {\n const meta: RouteMeta | undefined = route.meta;\n\n if (!meta) return true; // If no meta, allow access\n\n let hasRole = true;\n let hasPermission = true;\n\n if (meta.roles || meta.permissions) {\n hasRole = meta.roles ? roles.some(role => meta.roles!.includes(role)) : false;\n hasPermission = meta.permissions ? permissions.some(permission => meta.permissions!.includes(permission)) : false;\n }\n\n return hasRole || hasPermission;\n}\n\n/**\n * Find all routes of this role\n * @param routes asyncRoutes\n * @param roles\n * @param permissions\n */\nfunction filterAsyncRoutes(\n routes: RouteRecordRaw[],\n roles: string[],\n permissions: string[]\n): RouteRecordRaw[] {\n const res: RouteRecordRaw[] = [];\n\n console.log('%c 🎯 Filtering Async Routes...', 'color: blue; font-weight: bold;');\n\n\n routes.forEach((route) => {\n const tmp: RouteRecordRaw = {...route};\n\n console.log('%c 🔍 Evaluating Route:', 'color: purple; font-weight: bold;', tmp);\n\n if (canAccess(roles, permissions, tmp)) {\n console.log('%c ✅ Access Granted', 'color: green; font-weight: bold;', tmp.path);\n\n if (tmp.children) {\n tmp.children = filterAsyncRoutes(tmp.children, roles, permissions);\n }\n\n res.push(tmp);\n } else {\n console.log('%c 🚫 Access Denied', 'color: red; font-weight: bold;', tmp.path);\n }\n });\n\n return res;\n}\n\nexport interface PermissionState {\n routes: any[];\n addRoutes: any[];\n}\n\nconst state: PermissionState = {\n routes: [],\n addRoutes: [],\n};\n\nconst getters = {\n permission_routes: (state: PermissionState) => state.routes,\n};\n\nconst mutations = {\n [types.SET_ROUTES](state: PermissionState, routes: RouteRecordRaw[]) {\n console.dir('SET_ROUTES');\n console.dir(routes);\n state.addRoutes = routes;\n state.routes = constantRoutes.concat(routes);\n },\n};\n\nconst actions = {\n generateRoutes({commit}, {roles, permissions}) {\n console.log('%c 🚀 Generating Routes...', 'color: red; font-weight: bold;');\n\n return new Promise((resolve) => {\n try {\n let accessedRoutes: RouteRecordRaw[];\n\n if (roles.includes('admin')) {\n console.log('%c 🎩 Admin detected - Granting full access...', 'color: green; font-weight: bold;');\n accessedRoutes = asyncRoutes;\n } else {\n console.log('%c 🔍 Filtering routes based on roles & permissions...', 'color: blue; font-weight: bold;');\n accessedRoutes = filterAsyncRoutes(asyncRoutes, roles, permissions);\n }\n\n console.log('%c ✅ Routes successfully generated!', 'color: lime; font-weight: bold;');\n commit(types.SET_ROUTES, accessedRoutes);\n\n resolve(accessedRoutes);\n } catch (error) {\n console.error('%c ❌ Error in generateRoutes:', 'color: red; font-weight: bold;', error);\n resolve([]); // Resolve with an empty array to prevent breaking functionality\n }\n });\n },\n};\n\nexport default {\n namespaced: true,\n state,\n mutations,\n actions,\n getters,\n};\n","import {EventBus} from '@/plugins/eventBus';\nimport axios from 'axios';\nimport * as types from '@/store/mutation-types';\nimport {Form} from '@/plugins/FWForms/index';\nimport {performApiRequest} from \"@/store/helpers/vuex-helpers\";\n\nexport interface PricingState {\n loading: Record<string, boolean>;\n currentWorkingPricingStructure: any;\n couponForm: Form<any>;\n pricingRules: any[];\n pricingStructure: any;\n pricingStructures: any[];\n}\n\n// state\nconst state: PricingState = {\n loading: {\n get: false,\n create: false,\n update: false,\n delete: false,\n toggle: false,\n structures: false,\n structure: false,\n structureUpdate: false,\n structureDelete: false,\n structureCreate: false,\n },\n currentWorkingPricingStructure: {\n uuid: null,\n name: '',\n price_example: 100,\n added_amount: 100,\n duration_unit: 'days',\n multiplier: 1,\n price_tiers: [\n {\n name: '1 day',\n quantity: 1,\n period: 'days',\n multiplier: 1,\n example_price: 100,\n },\n ],\n },\n couponForm: new Form(),\n pricingRules: [],\n pricingStructure: null,\n pricingStructures: [],\n};\n\nconst getters = {\n loading: state => state.loading,\n pricingRules: state => state.pricingRules,\n pricingStructure: state => state.pricingStructure,\n pricingStructures: state => state.pricingStructures,\n currentWorkingPricingStructure: state => state.currentWorkingPricingStructure,\n};\n\nconst mutations = {\n [types.SET_PRICING_LOADING](state, loading) {\n state.loading[loading.subject] = loading.loading;\n },\n [types.SET_PRICING_RULES](state, rules) {\n state.pricingRules = rules;\n },\n [types.SET_PRICING_STRUCTURES](state, data) {\n state.pricingStructures = data;\n },\n [types.SET_PRICING_STRUCTURE](state, data) {\n state.pricingStructure = data;\n },\n [types.RESET_CURRENT_WORKING_PRICING_STRUCTURE](state) {\n state.currentWorkingPricingStructure = {\n uuid: null,\n name: '',\n price_example: 100,\n added_amount: 100,\n duration_unit: 'days',\n multiplier: 1,\n price_tiers: [\n {\n name: '1 day',\n quantity: 1,\n period: 'days',\n multiplier: 1,\n example_price: 100,\n },\n ],\n };\n },\n};\n\nconst actions = {\n\n /**\n * Get pricing rules\n */\n getPricingRules({commit}) {\n commit('SET_PRICING_LOADING', {subject: 'get', loading: true});\n return axios.get('/v1/pricing-rules')\n .then((response) => {\n commit('SET_PRICING_RULES', response?.data?.rules);\n }).catch(() => {\n }).finally(() => {\n commit('SET_PRICING_LOADING', {subject: 'get', loading: false});\n });\n },\n\n /**\n * Create pricing rule\n *\n * @param commit\n * @param {Object} rule\n */\n async createPricingRule({commit}, rule) {\n commit('SET_PRICING_LOADING', {subject: 'create', loading: true});\n\n try {\n await performApiRequest(commit, 'SET_PRICING_LOADING', 'create', () => axios.post('/v1/pricing-rules', rule));\n EventBus.$emit('create-pricing-rules-success');\n } catch (error) {\n EventBus.$emit('SystemMessage', {\n type: 'error',\n message: error?.response?.data?.message || 'There was an error',\n });\n }\n },\n\n /**\n * Update pricing rule\n *\n * @param state\n * @param commit\n * @param {Object} ruleData\n */\n savePricingRule({state, commit}, ruleData) {\n commit('SET_PRICING_LOADING', {subject: 'update', loading: true});\n\n axios.put(`/v1/pricing-rules/${ruleData.uuid}`, ruleData)\n .then(() => {\n EventBus.$emit('update-pricing-rules-success');\n }).catch(() => {\n }).finally(() => {\n commit('SET_PRICING_LOADING', {subject: 'update', loading: false});\n });\n },\n\n /**\n * Delete pricing rules\n *\n * @param commit\n * @param {Array} uuids\n */\n async deletePricingRules({commit}, uuids) {\n try {\n await performApiRequest(commit, 'SET_PRICING_LOADING', 'delete', () => axios.post('/v1/pricing-rules/delete', {uuids}));\n EventBus.$emit('delete-pricing-rules-success');\n } catch (error) {\n EventBus.$emit('SystemMessage', {\n type: 'error',\n message: error?.response?.data?.message || 'There was an error',\n\n });\n }\n },\n\n /**\n * Pricing structures\n *\n * @param commit\n */\n getPricingStructures({commit}) {\n commit('SET_PRICING_LOADING', {subject: 'structures', loading: true});\n\n axios.get('/v1/price-structures')\n .then((response) => {\n commit('SET_PRICING_STRUCTURES', response?.data?.data);\n })\n .catch(() => {\n }).finally(() => {\n commit('SET_PRICING_LOADING', {subject: 'structures', loading: false});\n });\n },\n\n /**\n * Single pricing structures\n *\n * @param commit\n * @param {String} uuid\n */\n getPricingStructure({commit}, uuid) {\n commit('SET_PRICING_LOADING', {subject: 'structure', loading: true});\n\n axios.get(`/v1/price-structures/${uuid}`)\n .then((response) => {\n commit('SET_PRICING_STRUCTURE', response?.data?.data);\n })\n .catch(() => {\n }).finally(() => {\n commit('SET_PRICING_LOADING', {subject: 'structure', loading: false});\n });\n },\n\n /**\n * Save pricing structures\n *\n * @param commit\n * @param {Object} data\n */\n savePriceStructure({commit}, data) {\n commit('SET_PRICING_LOADING', {subject: 'structureCreate', loading: true});\n\n axios.post('/v1/price-structures', data)\n .then(() => {\n EventBus.$emit('create-pricing-structure-success');\n })\n .catch(() => {\n }).finally(() => {\n commit('SET_PRICING_LOADING', {subject: 'structureCreate', loading: false});\n });\n },\n\n /**\n * Update pricing structures\n *\n * @param commit\n * @param {Object} data\n */\n updatePriceStructure({commit}, data) {\n commit('SET_PRICING_LOADING', {subject: 'structureUpdate', loading: true});\n\n axios.put(`/v1/price-structures/${data.uuid}`, data)\n .then(() => {\n EventBus.$emit('update-pricing-structure-success');\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'Update successful',\n });\n })\n .catch((e) => {\n EventBus.$emit('SystemMessage', {\n type: 'error',\n message: e?.response?.data?.message || 'There was an error',\n });\n }).finally(() => {\n commit('SET_PRICING_LOADING', {subject: 'structureUpdate', loading: false});\n });\n },\n\n /**\n * Delete pricing structures\n *\n * @param commit\n * @param {Object} data\n */\n deletePriceStructure({commit}, data) {\n commit('SET_PRICING_LOADING', {subject: 'structureDelete', loading: true});\n\n axios.delete(`/v1/price-structures/${data.uuid}`)\n .then(() => {\n EventBus.$emit('delete-pricing-structure-success');\n })\n .catch((e) => {\n EventBus.$emit('SystemMessage', {\n type: 'error',\n message: e?.response?.data?.message || 'There was an error',\n });\n }).finally(() => {\n commit('SET_PRICING_LOADING', {subject: 'structureDelete', loading: false});\n });\n },\n\n};\n\nexport default {\n namespaced: true,\n state,\n mutations,\n actions,\n getters,\n};\n","import axios from 'axios';\nimport {EventBus} from '@/plugins/eventBus';\nimport {get} from 'lodash';\nimport {Form} from '@/plugins/FWForms/index';\nimport * as types from '../mutation-types';\nimport {performApiRequest} from '@/store/helpers/vuex-helpers';\n\nexport interface Provider {\n active: boolean,\n created_at: string,\n email: string | null,\n provider: string,\n publishable_key: string,\n uid: string,\n updated_at: string,\n uuid: string,\n}\n\nexport interface ProvidersState {\n loading: Record<string, boolean>,\n form: Form<any>,\n paymentProviders: Provider[],\n}\n\nconst state: ProvidersState = {\n loading: {\n get: false,\n delete: false,\n toggle: false,\n matching: false,\n create_unavailability: false,\n },\n form: new Form(),\n paymentProviders: [],\n};\n\nconst getters = {\n form: (state: ProvidersState) => state.form,\n loading: (state: ProvidersState) => state.loading,\n paymentProviders: (state: ProvidersState) => state.paymentProviders,\n};\n\nconst mutations = {\n [types.SET_PROVIDERS_LOADING](state: ProvidersState, loading: { subject: string, loading: boolean }) {\n state.loading[loading.subject] = loading.loading;\n },\n [types.SET_PAYMENT_PROVIDERS](state: ProvidersState, providers: Provider[]) {\n providers = !providers ? [] : providers;\n providers = !Array.isArray(providers) ? [providers] : providers;\n\n state.paymentProviders = providers;\n },\n};\n\nconst actions = {\n\n getProviders({commit}) {\n commit('SET_PROVIDERS_LOADING', {subject: 'get', loading: true});\n\n axios.get('/v1/connections')\n .then((response) => {\n commit('outdoorsy/SET_OUTDOORSY_CONNECTIONS', get(response, 'data.providers.outdoorsy', []), {root: true});\n commit('hqRentals/SET_HQRENTALS_CONNECTIONS', get(response, 'data.providers.hq-rentals', []), {root: true});\n commit('lula/SET_LULA_CONNECTIONS', get(response, 'data.lula', []), {root: true});\n commit('twistedRoad/SET_TWISTED_ROAD_CONNECTIONS', get(response, 'data.providers.twisted_road', []), {root: true});\n }).catch(() => {\n }).finally(() => {\n commit('SET_PROVIDERS_LOADING', {subject: 'get', loading: false});\n });\n },\n\n getPaymentProfiles({commit}) {\n commit('SET_PROVIDERS_LOADING', {subject: 'get', loading: true});\n\n axios.get('/v1/payment-profiles')\n .then((response) => {\n commit('SET_PAYMENT_PROVIDERS', get(response, 'data.paymentProfile', []));\n EventBus.$emit('get-payment-profiles-success', get(response, 'data.paymentProfile'));\n }).catch(() => {\n }).finally(() => {\n commit('SET_PROVIDERS_LOADING', {subject: 'get', loading: false});\n });\n },\n\n getPaymentProfile({commit}, paymentProfile) {\n commit('SET_PROVIDERS_LOADING', {subject: 'get', loading: true});\n\n const uuid = typeof paymentProfile === 'object' ? paymentProfile.uuid : paymentProfile;\n\n axios.get(`/v1/payment-profiles/${uuid}`)\n .then((response) => {\n EventBus.$emit('get-payment-profile-success', get(response, 'data.paymentProfile'));\n }).catch(() => {\n }).finally(() => {\n commit('SET_PROVIDERS_LOADING', {subject: 'get', loading: false});\n });\n },\n\n async deletePaymentProfile({commit}, paymentProfile: string | { uuid: string }) {\n const uuid = typeof paymentProfile === 'object' ? paymentProfile.uuid : paymentProfile;\n\n return await performApiRequest(commit, 'SET_PROVIDERS_LOADING', 'delete', () => axios.delete(`/v1/payment-profiles/${uuid}`));\n },\n\n delete({commit, rootGetters}, provider) {\n commit('SET_PROVIDERS_LOADING', {subject: 'delete', loading: true});\n\n axios.delete(`/v1/company/${rootGetters['company/company'].uuid}/connections/${provider.uuid}`)\n .then((response) => {\n EventBus.$emit('delete-provider-success', get(response, 'data.provider'));\n }).catch(() => {\n }).finally(() => {\n commit('SET_PROVIDERS_LOADING', {subject: 'delete', loading: false});\n });\n },\n\n toggleActive({commit, rootGetters}, provider) {\n commit('SET_PROVIDERS_LOADING', {subject: 'toggle', loading: true});\n\n axios.put(`/v1/company/${rootGetters['company/company'].uuid}/connections/${provider.uuid}/toggle-active`)\n .then((response) => {\n EventBus.$emit('toggle-provider-success', get(response, 'data.provider'));\n }).catch(() => {\n }).finally(() => {\n commit('SET_PROVIDERS_LOADING', {subject: 'toggle', loading: false});\n });\n },\n\n matchListing({commit, rootGetters}, {provider_uuid, l_id}) {\n commit('SET_PROVIDERS_LOADING', {subject: 'matching', loading: true});\n\n axios.post(`/v1/company/${rootGetters['company/company'].uuid}/provider-listings/${provider_uuid}/match/listings/${l_id}`)\n .then((response) => {\n EventBus.$emit('provider-listings-match-success', get(response, 'data.listings', []));\n }).catch(() => {\n }).finally(() => {\n commit('SET_PROVIDERS_LOADING', {subject: 'matching', loading: false});\n });\n },\n\n unMatchProviderListing({commit, rootGetters}, {l_id, provider_uuid}) {\n commit('SET_PROVIDERS_LOADING', {subject: 'saveListing1', loading: true});\n\n axios.delete(`/v1/listings/${l_id}/provider-listings/${provider_uuid}`)\n .then(() => {\n EventBus.$emit('provider-listings-unmatched-success', provider_uuid);\n }).catch(() => {\n }).finally(() => {\n commit('SET_PROVIDERS_LOADING', {subject: 'saveListing1', loading: false});\n });\n },\n\n createListingUnavailability({commit, rootGetters}, data) {\n commit('SET_PROVIDERS_LOADING', {subject: 'create_unavailability', loading: true});\n\n axios.post(`/v1/company/${rootGetters['company/company'].uuid}/provider-bookings`, data)\n .then((response) => {\n if (get(response, 'data.booking')) {\n commit('booking/SET_CURRENT_WORKING_BOOKING', get(response, 'data.booking'), {root: true});\n }\n }).catch(() => {\n }).finally(() => {\n commit('SET_PROVIDERS_LOADING', {subject: 'create_unavailability', loading: false});\n });\n },\n};\n\nexport default {\n namespaced: true,\n state,\n mutations,\n actions,\n getters,\n};\n","import axios from 'axios';\nimport {Form} from '@/plugins/FWForms/index';\nimport {EventBus} from '@/plugins/eventBus';\nimport {StorageService} from '@/services/storage.service';\nimport * as types from '../mutation-types';\nimport {createUrlQueryString} from '@/utils/urls';\nimport {CreditCards, RenterInterface, StoreLoaders} from '@/types';\nimport {performApiRequest} from '@/store/helpers/vuex-helpers';\nimport {push} from 'notivue';\n\nexport interface fetchRenterOptions {\n r_id: string,\n include?: string | string[],\n options?: { includeOrders: boolean | 1 | 0 },\n}\n\nexport interface RenterState {\n loading: StoreLoaders,\n init: boolean,\n currentRenter: RenterInterface,\n booking_charge: any,\n renters: RenterInterface[],\n allRenters: RenterInterface[],\n searchedRenters: RenterInterface[],\n stripeCustomerObj: any,\n renterForm: Form<any>,\n totalCustomers: number,\n notificationsTotal: number,\n notifications: any[],\n dialogs: Record<string, boolean>,\n customerTagListCounts: Record<string, number>,\n customerPagination: {\n current_page: number,\n from: number,\n last_page: number,\n per_page: number,\n to: number,\n total: number,\n }\n customersQuery?: {\n page?: number,\n itemsPerPage?: number,\n sortBy?: string[],\n sortDesc?: boolean[],\n filter?: {\n tag_list?: string[],\n archived?: boolean,\n search?: string,\n },\n include?: string,\n }\n}\n\ninterface RentersResponseInterface {\n data: RenterInterface[],\n links: object,\n meta: {\n current_page: number,\n from: number,\n last_page: number,\n links: object[],\n path: string,\n per_page: number,\n to: number,\n total: number,\n stats: {\n tag_list: Record<string, number>,\n total: number\n },\n total_customers: number,\n },\n}\n\nconst state: RenterState = {\n loading: {\n renter: false,\n renterOrders: false,\n renters: false,\n adding: false,\n deleting: false,\n searching: false,\n stripeLoading: false,\n teslaFeeInvoice: false,\n paymentMethod: false,\n exportRenters: false,\n renterNotifications: false,\n mergeRenters: false,\n\n },\n init: false,\n currentRenter: {\n first_name: '',\n last_name: '',\n full_name: '',\n email: '',\n phone: '',\n r_id: '',\n loaded: false,\n payment_sources: [],\n creditCards: [],\n uuid: null,\n source: '',\n created_at: '',\n },\n booking_charge: {},\n renters: [],\n allRenters: [],\n searchedRenters: [],\n stripeCustomerObj: {},\n renterForm: new Form(),\n totalCustomers: 0,\n notificationsTotal: 0,\n notifications: [],\n dialogs: {\n exportCustomers: false,\n },\n customerTagListCounts: {},\n customerPagination: {\n current_page: 0,\n from: 0,\n last_page: 0,\n per_page: 0,\n to: 0,\n total: 0,\n },\n customersQuery: {\n page: 1,\n itemsPerPage: 25,\n sortBy: [],\n sortDesc: [],\n filter: {\n tag_list: [],\n archived: false,\n search: '',\n },\n include: '',\n }\n};\n\n\nconst getters = {\n init: (state: RenterState) => state.init,\n rentersLoading: (state: RenterState) => state.loading,\n renters: (state: RenterState) => state.renters,\n allRenters: (state: RenterState) => state.allRenters,\n searchedRenters: (state: RenterState) => state.searchedRenters,\n currentRenter: (state: RenterState) => state.currentRenter,\n stripeCustomerObj: (state: RenterState) => state.stripeCustomerObj,\n renterForm: (state: RenterState) => state.renterForm,\n totalCustomers: (state: RenterState) => state.totalCustomers,\n notificationsTotal: (state: RenterState) => state.notificationsTotal,\n notifications: (state: RenterState) => state.notifications,\n dialogs: (state: RenterState) => state.dialogs,\n customerTagListCounts: (state: RenterState) => state.customerTagListCounts,\n customersQuery: (state: RenterState) => state.customersQuery,\n customerPagination: (state: RenterState) => state.customerPagination,\n};\n\nconst mutations = {\n [types.SET_RENTERS_LOADING](state: RenterState, loading: { subject: string, loading: boolean }) {\n state.loading[loading.subject] = loading.loading;\n state.init = true;\n },\n [types.SET_RENTERS](state: RenterState, data: RentersResponseInterface) {\n console.dir('SET_RENTERS');\n console.dir(data);\n state.renters = data.data;\n state.totalCustomers = data.meta.total_customers;\n state.customerTagListCounts = data.meta.stats.tag_list;\n state.customerPagination = {\n current_page: data.meta.current_page,\n from: data.meta.from,\n last_page: data.meta.last_page,\n per_page: data.meta.per_page,\n to: data.meta.to,\n total: data.meta.total,\n }\n state.init = true;\n },\n [types.SET_ALL_RENTERS](state: RenterState, renters: { renters: RenterInterface[] }) {\n state.allRenters = renters?.renters;\n },\n\n [types.SET_RENTERS_DIALOG](state: RenterState, payload: { topic: string, value: boolean }) {\n state.dialogs[payload.topic] = payload.value;\n },\n [types.SET_RENTER](state: RenterState, renter: RenterInterface) {\n state.currentRenter = {...state.currentRenter, ...renter};\n state.currentRenter.loaded = true;\n state.init = true;\n },\n [types.ADD_RENTER](state: RenterState, renter: RenterInterface) {\n const renterIndex = state.renters.findIndex((r) => r.r_id === renter.r_id);\n if (renterIndex >= 0) {\n state.renters[renterIndex] = renter;\n } else {\n state.renters.push(renter);\n }\n },\n [types.RESET_RENTER](state: RenterState, renter: RenterInterface) {\n state.currentRenter = renter;\n },\n [types.SET_RENTERS_CREDIT_CARDS](state: RenterState, cards: CreditCards[]) {\n state.currentRenter.creditCards = cards;\n },\n [types.SET_PAYMENT_SOURCES](state: RenterState, sources) {\n state.currentRenter.payment_sources = sources;\n },\n [types.SET_BOOKING_PAYMENT](state: RenterState, charge) {\n state.booking_charge = charge;\n },\n [types.SET_PHONE_NUMBER](state: RenterState, number: string) {\n state.currentRenter.phone = number;\n },\n [types.SET_SEARCHED_RENTERS](state: RenterState, renters: any[]) {\n state.searchedRenters = renters;\n },\n [types.CLEAR_RENTERS_FORM_ERROR](state: RenterState, form_field: string) {\n if (form_field === null || form_field === undefined) {\n state.renterForm.errors.clear();\n } else {\n state.renterForm.errors.clear(form_field);\n }\n },\n [types.SET_STRIPE_CUSTOMER](state: RenterState, stripe_customer) {\n state.stripeCustomerObj = stripe_customer;\n },\n [types.SET_RENTER_NOTIFICATIONS](state: RenterState, notifications) {\n state.notifications = notifications?.data || [];\n state.notificationsTotal = notifications?.total || 0;\n },\n [types.SET_CUSTOMER_QUERY](state: RenterState, data: { key: string, value: any }) {\n console.dir('SET_CUSTOMER_QUERY');\n console.dir(data);\n\n state.customersQuery[data.key] = data.value;\n },\n};\n\nconst actions = {\n\n /**\n * Reset renters\n */\n resetRenter({commit}) {\n const renter = {\n first_name: '',\n last_name: '',\n full_name: '',\n email: '',\n phone: '',\n r_id: '',\n loaded: false,\n payment_sources: [],\n creditCards: [],\n uuid: null,\n source: '',\n created_at: '',\n };\n\n commit(types.RESET_RENTER, renter);\n },\n\n\n /**\n * Fetch renters\n */\n async fetchCompanyRenters({commit, state}) {\n try {\n const options = state.customersQuery;\n\n const {sortBy = [], sortDesc = [], filter = {}} = options;\n\n const queryObject = {\n 'sort': sortBy.length > 0 ? (sortDesc?.[0] ? `-${sortBy[0]}` : sortBy[0]) : null,\n 'filter[tag_list]': filter.tag_list || null,\n 'filter[archived]': filter.archived ?? null,\n 'filter[q]': filter.search || null,\n 'page': options.page || 1,\n 'itemsPerPage': options.itemsPerPage || 30,\n 'include': options.include,\n };\n\n // Convert the object into a query string\n const query = createUrlQueryString(queryObject, true);\n console.log('✅ API Query String:', query);\n\n const responseData = await performApiRequest(commit, 'SET_RENTERS_LOADING', 'renters', () => axios.get(`/v1/renters${query}`));\n commit(types.SET_RENTERS, responseData);\n } catch (error) {\n console.error(error);\n }\n },\n\n\n /**\n * Fetch all renters for export\n */\n async fetchRentersForExport({commit}) {\n try {\n const responseData = await performApiRequest(commit, 'SET_RENTERS_LOADING', 'exportRenters', () => axios.get('/v1/renters-export'));\n\n commit(types.SET_ALL_RENTERS, responseData);\n } catch (error) {\n console.error(error)\n }\n },\n\n async mergeCustomers({commit}, data: { main: string, second: string, mode: 'simple' | 'advanced' }) {\n await performApiRequest(commit, 'SET_RENTERS_LOADING', 'mergeRenters', () => axios.post('/v1/merge-renters', data));\n },\n\n importCustomers({commit}, data: any) {\n commit(types.SET_RENTERS_LOADING, {subject: 'mergeRenters', loading: true});\n\n axios.post('/v1/renters/import/csv', {data})\n .then(() => {\n EventBus.$emit('renter-import-success');\n }).catch(() => {\n }).finally(() => {\n commit(types.SET_RENTERS_LOADING, {subject: 'mergeRenters', loading: false});\n });\n },\n\n\n /**\n * Fetch all renters for export\n */\n fetchRenterNotifications({commit}, renter: RenterInterface) {\n commit(types.SET_RENTERS_LOADING, {subject: 'renterNotifications', loading: true});\n\n axios.get(`/v1/renters/${renter.r_id}/notifications`)\n .then((response) => {\n commit(types.SET_RENTER_NOTIFICATIONS, response?.data?.notifications || []);\n }).catch(() => {\n }).finally(() => {\n commit(types.SET_RENTERS_LOADING, {subject: 'renterNotifications', loading: false});\n });\n },\n\n\n /**\n * Fetch a renter\n */\n async fetchRenter({commit}, data: fetchRenterOptions) {\n\n console.dir('data');\n console.dir(data);\n const renterId = data.r_id;\n if (!renterId) {\n throw new Error('No renter id provided');\n }\n\n if (data?.include) {\n if (Array.isArray(data?.include)) {\n data.include = data.include.join(',');\n }\n }\n\n const queryObject = {\n include: data?.include,\n includeOrders: data?.options?.includeOrders,\n };\n console.dir(queryObject);\n\n const query = createUrlQueryString(queryObject, true);\n\n console.dir(query);\n\n await axios.get(`/v1/renters/${renterId}${query}`)\n .then((response) => {\n commit(types.SET_RENTER, response.data.renter);\n }).catch(() => {\n EventBus.$emit('fetch-renter-failure');\n }).finally(() => {\n commit(types.SET_RENTERS_LOADING, {subject: 'renter', loading: false});\n\n if (data?.options?.includeOrders) {\n commit(types.SET_RENTERS_LOADING, {subject: 'renterOrders', loading: false});\n }\n });\n },\n\n /**\n * Update a renter\n */\n async updateRenter({commit}, renter: RenterInterface) {\n try {\n const responseData = await performApiRequest(commit, 'SET_RENTERS_LOADING', 'renters', () => axios.put(`/v1/renters/${renter.r_id}`, renter));\n\n commit(types.SET_RENTER, responseData?.renter);\n push.success({\n message: 'Customer saved successfully!',\n });\n } catch (error) {\n push.error({\n message: error?.response?.data?.message || 'There was an error saving this renter.',\n });\n }\n },\n\n\n /**\n * Create a renter\n */\n async createRenter({state, commit}) {\n try {\n const responseData = await performApiRequest(commit, 'SET_RENTERS_LOADING', 'adding', () => axios.post('/v1/renters', state.currentRenter));\n\n commit(types.SET_RENTER, responseData?.renter);\n commit(types.ADD_RENTER, responseData?.renter);\n push.success({\n message: 'Customer created successfully!',\n });\n EventBus.$emit('new-customer-created-success', responseData?.renter);\n\n return responseData?.renter;\n } catch (error) {\n if (error?.response?.data?.errors) {\n const errorMessage = error.response.data.errors[Object.keys(error.response.data.errors)[0]][0];\n push.error({\n message: errorMessage,\n });\n } else {\n push.error({\n message: 'Customer create error',\n });\n }\n state.renterForm.errors.set(error?.response?.data?.errors);\n }\n },\n\n\n /**\n * Delete a renter\n */\n async deleteRenter({commit}, renter: RenterInterface) {\n try {\n await performApiRequest(commit, 'SET_RENTERS_LOADING', 'deleting', () => axios.delete(`/v1/renters/${renter.r_id}`));\n } catch (error) {\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n throw new Error(error);\n }\n },\n\n\n /**\n * Stripe customer\n */\n stripeCustomer({commit}, r_id: string) {\n commit(types.SET_RENTERS_LOADING, {subject: 'stripeLoading', loading: true});\n\n axios.get(`/v1/renters/${r_id}/stripe-customer`)\n .then((response) => {\n console.dir(response.data);\n commit(types.SET_STRIPE_CUSTOMER, response?.data?.stripeCustomer);\n }).catch(() => {\n }).finally(() => {\n commit(types.SET_RENTERS_LOADING, {subject: 'stripeLoading', loading: false});\n });\n },\n\n\n /**\n * Create renter invoice\n */\n renterInvoiceCreate({commit}, order: any) {\n commit(types.SET_RENTERS_LOADING, {subject: 'stripeLoading', loading: true});\n axios.post(`/v1/company/${StorageService.getCompanyUuid()}/renters/${order.r_id}/invoice`, order)\n .then((response) => {\n EventBus.$emit('renter-invoice-create-success', response?.data?.payment);\n }).catch(() => {\n }).finally(() => {\n commit(types.SET_RENTERS_LOADING, {subject: 'stripeLoading', loading: false});\n });\n },\n\n\n /**\n * Create renter Tesla fee invoice\n */\n teslaFeeInvoiceCreate({commit}, data: any) {\n commit(types.SET_RENTERS_LOADING, {subject: 'teslaFeeInvoice', loading: true});\n\n axios.post(`/v1/company/${StorageService.getCompanyUuid()}/renters/${data.order.renter.r_id}/tesla-fee-invoice`, data.order)\n .then((response) => {\n push.success({\n message: 'Invoice sent successfully',\n });\n commit('tesla/SET_TESLA_INVOICES', response?.data?.invoices, {root: true});\n EventBus.$emit('tesla-fee-invoice-created-successfully');\n }).catch((e) => {\n push.error({\n message: e?.response?.data?.message || 'There was an error',\n });\n }).finally(() => {\n commit(types.SET_RENTERS_LOADING, {subject: 'teslaFeeInvoice', loading: false});\n });\n },\n\n\n /**\n * Fetch renter payments\n */\n renterPayments({commit}, r_id: string) {\n axios.get(`/v1/company/${StorageService.getCompanyUuid()}/renters/${r_id}/payments`)\n .then((response) => {\n commit(types.SET_PAYMENT_SOURCES, response?.data?.customer?.sources?.data || []);\n }).catch(() => {\n }).finally(() => {\n commit('SET_RENTERS_LOADING', {subject: 'renters', loading: false});\n });\n },\n\n\n /**\n * Fetch renter charges\n */\n async renterCharges({commit}, r_id: string) {\n return await performApiRequest(commit, 'SET_RENTERS_LOADING', 'searching', () => axios.get(`/renters/${r_id}/charges`));\n },\n\n\n /**\n * Search renters\n */\n async searchRenters({commit}, query: string) {\n const responseData = await performApiRequest(commit, 'SET_RENTERS_LOADING', 'searching', () => axios.get(`/v1/search/renters?search=${query}`));\n commit(types.SET_SEARCHED_RENTERS, responseData.renters || []);\n },\n\n /**\n * Block renters\n */\n async blockRenter({commit}, data) {\n return await performApiRequest(commit, 'SET_RENTERS_LOADING', 'block_renter', () => axios.post(`/v1/renters/block`, data));\n },\n\n async unblockRenter({commit}, data) {\n return await performApiRequest(commit, 'SET_RENTERS_LOADING', 'unblock_renter', () => axios.post(`/v1/renters/unblock`, data));\n },\n\n /**\n * Save a Stripe payment method for renter\n */\n stripeSavePaymentMethod({commit}, {renter, paymentMethod}) {\n commit(types.SET_RENTERS_LOADING, {subject: 'paymentMethod', loading: true});\n axios.post(`/v1/company/${StorageService.getCompanyUuid()}/renters/${renter.r_id}/payment-method/${paymentMethod}`)\n .then((response) => {\n commit(types.SET_RENTERS_CREDIT_CARDS, response?.data?.creditCards || []);\n EventBus.$emit('renter-stripe-payment-method-success', response?.data?.creditCards);\n }).catch(() => {\n }).finally(() => {\n commit(types.SET_RENTERS_LOADING, {subject: 'paymentMethod', loading: false});\n });\n },\n\n\n /**\n * Get a renters credit cards\n */\n renterCreditCards({commit}, renter: RenterInterface) {\n commit(types.SET_RENTERS_LOADING, {subject: 'creditCards', loading: true});\n axios.get(`/v1/renters/${renter.r_id}/credit-cards`)\n .then((response) => {\n commit(types.SET_RENTERS_CREDIT_CARDS, response?.data?.creditCards || []);\n EventBus.$emit('renter-credit-cards-success');\n }).catch(() => {\n }).finally(() => {\n commit(types.SET_RENTERS_LOADING, {subject: 'creditCards', loading: false});\n });\n },\n};\n\nexport default {\n namespaced: true,\n state,\n mutations,\n actions,\n getters,\n};\n","import {ActionTree, GetterTree} from 'vuex';\nimport {EventBus} from '@/plugins/eventBus';\nimport axios from 'axios';\nimport * as types from '@/store/mutation-types';\n\nexport interface SquareState {\n loading: Record<string, boolean>;\n currentWorkingInvoice: any;\n}\n\nexport interface SquareActions {\n getSquareOauthUrl(context: any): Promise<void>;\n\n saveSquareCode(context: any, data: { code: string; state: string }): Promise<void>;\n\n getSquareProvider(context: any): Promise<void>;\n\n testPayment(context: any, squareId: string): Promise<void>;\n}\n\n// state\nconst state: SquareState = {\n loading: {\n analytics: false,\n fetchCart: false,\n },\n currentWorkingInvoice: '',\n};\n\nconst getters: GetterTree<SquareState, any> = {\n loading: (state) => state.loading,\n};\n\nconst mutations = {\n [types.SET_SQUARE_LOADING](state: SquareState, loading: { subject: string, loading: boolean }) {\n state.loading[loading.subject] = loading.loading;\n },\n};\n\nconst actions: ActionTree<SquareState, any> & SquareActions = {\n\n async getSquareOauthUrl({commit}) {\n commit(types.SET_SQUARE_LOADING, {subject: 'analytics', loading: true});\n\n try {\n const response = await axios.get('/v1/square/url');\n EventBus.$emit('square-oauth-url-create-success', response.data);\n } catch (e) {\n EventBus.$emit('square-oauth-url-create-error', e.response);\n } finally {\n commit(types.SET_SQUARE_LOADING, {subject: 'analytics', loading: false});\n }\n },\n\n async saveSquareCode({commit}, data: { code: string; state: string }) {\n commit(types.SET_SQUARE_LOADING, {subject: 'analytics', loading: true});\n\n try {\n const response = await axios.post('/v1/square/redirect', data);\n EventBus.$emit('square-oauth-url-create-success', response.data);\n } catch (e) {\n EventBus.$emit('square-oauth-url-create-error', e.response);\n } finally {\n commit(types.SET_SQUARE_LOADING, {subject: 'analytics', loading: false});\n }\n },\n\n async getSquareProvider() {\n try {\n const response = await axios.get('/v1/square/');\n EventBus.$emit('square-oauth-success', response.data);\n } catch (e) {\n console.error('Error fetching Square provider:', e);\n }\n },\n\n async testPayment(_, squareId: string) {\n try {\n const response = await axios.post(`/v1/square/testPayment?squareId=${squareId}`);\n EventBus.$emit('delete-square-oauth-success', response.data);\n } catch (e) {\n console.error('Error testing Square payment:', e);\n }\n },\n};\n\nexport default {\n namespaced: true,\n state,\n mutations,\n actions,\n getters,\n};\n","import {EventBus} from '@/plugins/eventBus';\nimport {Form} from '@/plugins/FWForms/index';\nimport axios from 'axios';\nimport * as types from '@/store/mutation-types';\nimport dayjs from 'dayjs';\nimport {performApiRequest} from \"@/store/helpers/vuex-helpers\";\nimport {SubscriptionPlan, SubscriptionState} from \"@/types\";\n\n\nconst subscriptionNameMap: Record<string, string> = {\n 'sub_basic_monthly': 'Basic Monthly',\n 'plan_IyarH890IaZoHd': 'Basic Monthly', // Production\n 'sub_standard_monthly': 'Standard Monthly',\n 'plan_IyarRkXlliDZhB': 'Standard Monthly', // Production\n 'sub_premium_monthly': 'Premium Monthly',\n 'plan_IyarEVETwSHGj7': 'Premium Monthly', // Production\n 'sub_basic_annual': 'Basic Annual',\n 'plan_IyarKGjJctzvXy': 'Basic Annual', // Production\n 'sub_standard_annual': 'Standard Annual',\n 'plan_IyarWX4xbYuDHu': 'Standard Annual', // Production\n 'sub_premium_annual': 'Premium Annual',\n 'plan_Iyar2EOrTQfZ6l': 'Premium Annual' // Production\n};\n\n\n// state\nconst state: SubscriptionState = {\n loading: {\n subscription: false,\n subscribing: false,\n cancelSubscription: false,\n resumeSubscription: false,\n endTrial: false,\n },\n\n enforceSubscription: false,\n\n newSubscription: {\n billingPeriod: null,\n plan: null,\n },\n\n subscriptionForm: new Form(),\n\n plans: [\n {\n name: 'basic',\n pricing: {\n monthly: {\n id: 'sub_basic_monthly',\n price: 34,\n },\n yearly: {\n id: 'sub_basic_annual',\n price: 24,\n },\n },\n description: {\n bullets: [\n 'Orders',\n 'Up to 5 vehicles',\n 'Includes 1 branch',\n '2 staff accounts',\n 'Unlimited Customers',\n '1 car-share connections',\n 'Online Store',\n 'Stripe Integration',\n 'And More*',\n ],\n },\n },\n {\n name: 'standard',\n pricing: {\n monthly: {\n id: 'sub_standard_monthly',\n price: 89,\n },\n yearly: {\n id: 'sub_standard_annual',\n price: 69,\n },\n },\n description: {\n bullets: [\n 'All of Basic',\n 'Up to 50 vehicles',\n '5 staff accounts',\n 'Includes 2 branches',\n 'eSign Rental Agreements',\n 'Coupons',\n 'QR & Barcodes',\n 'Reports',\n 'Import/Export',\n 'Hide powered by Fleetwire',\n 'And More*',\n ],\n },\n },\n {\n name: 'premium',\n pricing: {\n monthly: {\n id: 'sub_premium_monthly',\n price: 279,\n },\n yearly: {\n id: 'sub_premium_annual',\n price: 239,\n },\n },\n description: {\n bullets: [\n 'All of Standard',\n 'Up to 150 vehicles',\n '20 staff accounts',\n 'Includes 2 branches',\n 'Custom Domain',\n 'Custom Email Domain',\n 'Additional Scripts',\n '10 Car-share connections',\n 'Zapier integration',\n 'API',\n 'TFA (Two factor authentication)',\n 'And More*',\n ],\n },\n },\n ] as SubscriptionPlan[],\n\n subscription: {\n stripe_status: null,\n ends_at: null,\n items: [],\n name: null,\n quantity: null,\n stripe_id: null,\n stripe_price: null,\n trial_ends_at: null,\n updated_at: null,\n },\n\n subscriptionMaster: null,\n extraListingsAddonCount: 0,\n\n subscriptionStep: 0,\n planSelection: 0,\n\n updatedSubscription: {\n plan: 'basic',\n interval: 'monthly',\n }\n};\n\nconst getters = {\n loading: (state: SubscriptionState) => state.loading,\n enforceSubscription: (state: SubscriptionState) => state.enforceSubscription,\n plans: (state: SubscriptionState) => state.plans,\n subscription: (state: SubscriptionState) => state.subscription,\n newSubscription: (state: SubscriptionState) => state.newSubscription,\n subscriptionForm: (state: SubscriptionState) => state.subscriptionForm,\n subscriptionMaster: (state: SubscriptionState) => state.subscriptionMaster,\n extraListingsAddonCount: (state: SubscriptionState) => state.extraListingsAddonCount,\n subscriptionFullName: (state: SubscriptionState) => {\n const subscriptionName = subscriptionNameMap[state.subscriptionMaster];\n return subscriptionName ? subscriptionName : 'Premium Monthly';\n },\n subscriptionPlan: (state: SubscriptionState) => {\n switch (state.subscriptionMaster) {\n case 'sub_basic_monthly':\n case 'sub_basic_annual':\n case 'plan_IyarH890IaZoHd': // Production\n case 'plan_IyarKGjJctzvXy': // Production\n case 'price_1KfoLECZJTjTZE0Qs6poe7wG':\n case 'price_1KfoLECZJTjTZE0QmWH5yynX':\n return 'basic';\n case 'sub_standard_monthly':\n case 'sub_standard_annual':\n case 'plan_IyarRkXlliDZhB': // Production\n case 'plan_IyarWX4xbYuDHu': // Production\n case 'price_1Kfp67CZJTjTZE0Q0SW8L1Fk':\n return 'standard';\n case 'sub_premium_monthly':\n case 'sub_premium_annual':\n case 'plan_IyarEVETwSHGj7': // Production\n case 'plan_Iyar2EOrTQfZ6l': // Production\n return 'premium';\n default:\n return null;\n }\n },\n subscriptionDuration: (state: SubscriptionState) => {\n switch (state.subscriptionMaster) {\n case 'sub_basic_monthly':\n case 'sub_standard_monthly':\n case 'sub_premium_monthly':\n case 'plan_IyarH890IaZoHd':\n case 'plan_IyarRkXlliDZhB':\n case 'plan_IyarEVETwSHGj7':\n return 'monthly';\n case 'sub_standard_annual':\n case 'sub_basic_annual':\n case 'sub_premium_annual':\n case 'plan_IyarKGjJctzvXy':\n case 'plan_IyarWX4xbYuDHu':\n case 'plan_Iyar2EOrTQfZ6l':\n return 'yearly';\n default:\n return 'monthly';\n }\n },\n hasActiveSubscription: (state: SubscriptionState) => state.subscription?.stripe_status === 'active',\n hasPastDueSubscription: (state: SubscriptionState) => state.subscription?.stripe_status === 'past_due',\n hasPausedSubscription: (state: SubscriptionState) => state.subscription?.stripe_status === 'paused',\n subscriptionEndDate: (state: SubscriptionState) => {\n const subEndDate = state.subscription?.ends_at;\n if (!subEndDate) return false;\n return dayjs(subEndDate).format('MMM D, YYYY');\n },\n subscriptionStep: (state: SubscriptionState) => state.subscriptionStep,\n planSelection: (state: SubscriptionState) => state.planSelection,\n updatedSubscription: (state: SubscriptionState) => state.updatedSubscription,\n};\n\nconst mutations = {\n [types.SET_SUBSCRIPTION_LOADING](state: SubscriptionState, loading: { subject: string, loading: boolean }) {\n state.loading[loading.subject] = loading.loading;\n },\n [types.SET_ENFORCE_SUBSCRIPTION](state: SubscriptionState, enforce) {\n state.enforceSubscription = enforce;\n },\n [types.SET_SUBSCRIPTION_STEP](state: SubscriptionState, step: number) {\n state.subscriptionStep = step;\n },\n [types.SET_SUBSCRIPTION_PLAN_AND_INTERVAL](state: SubscriptionState, updatedSubscription: {\n plan: string,\n interval: string\n }) {\n state.updatedSubscription = updatedSubscription;\n },\n [types.SET_PLAN_SELECTION](state: SubscriptionState, selection: number) {\n state.planSelection = selection;\n },\n [types.SET_SUBSCRIPTION](state: SubscriptionState, subscription) {\n state.subscription = subscription;\n },\n\n /**\n * Update the new subscription object\n */\n [types.UPDATE_NEW_SUBSCRIPTION](state: SubscriptionState, newSubscription) {\n if (newSubscription.billingPeriod) {\n state.newSubscription.billingPeriod = newSubscription.billingPeriod;\n }\n if (newSubscription.plan) {\n state.newSubscription.plan = newSubscription.plan;\n }\n },\n [types.SET_SUBSCRIPTION_MASTER](state: SubscriptionState, subscription) {\n console.dir('SET_SUBSCRIPTION_MASTER');\n console.dir(subscription);\n state.subscriptionMaster = subscription;\n },\n [types.SET_EXTRA_LISTINGS_ADDON](state: SubscriptionState, count) {\n state.extraListingsAddonCount = count;\n },\n [types.CLEAR_SUBSCRIPTION_FORM_ERRORS](state: SubscriptionState, form_field: string | null = null) {\n if (form_field === null || form_field === undefined) {\n state.subscriptionForm.errors.clear();\n } else {\n state.subscriptionForm.errors.clear(form_field);\n }\n },\n [types.SET_SUBSCRIPTION_FORM_ERROR](state: SubscriptionState, error: string | Record<string, string[]>) {\n state.subscriptionForm.errors.set(error);\n },\n};\n\nconst actions = {\n\n async subscribeToPlan({commit}, sub) {\n try {\n const responseData = await performApiRequest(commit, 'SET_SUBSCRIPTION_LOADING', 'subscribing', () => axios.post('/v1/subscription', {id: sub}));\n commit(types.SET_SUBSCRIPTION, responseData.subscription);\n commit('company/SET_COMPANY', responseData.company, {root: true});\n\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'subscription successful',\n });\n EventBus.$emit('subscribe-to-plan-success');\n } catch (error) {\n EventBus.$emit('SystemMessage', {\n type: 'error',\n message: error.response?.data?.message || error,\n });\n }\n },\n\n async switchPlan({commit}, sub: string) {\n try {\n const responseData = await performApiRequest(commit, 'SET_SUBSCRIPTION_LOADING', 'subscribing', () => axios.post('/v1/subscription/swap', {id: sub}));\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'subscription swap successful',\n });\n EventBus.$emit('swap-plan-success');\n\n return responseData;\n } catch (error) {\n EventBus.$emit('SystemMessage', {\n type: 'error',\n message: error.response?.data?.message || \"There was an error swapping your subscription.\",\n });\n }\n },\n\n addAddon({commit}, data) {\n commit('SET_SUBSCRIPTION_LOADING', {subject: 'subscribing', loading: true});\n\n axios.post('/v1/subscription/addon', data)\n .then((response) => {\n commit('SET_SUBSCRIPTION', response.data.subscription);\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'subscription swap successful',\n });\n EventBus.$emit('swap-plan-success');\n }).catch((e) => {\n console.dir(e);\n EventBus.$emit('SystemMessage', {\n type: 'error',\n message: e.response.data.message,\n });\n }).finally(() => {\n commit('SET_SUBSCRIPTION_LOADING', {subject: 'subscribing', loading: false});\n });\n },\n\n removeAddon({commit}, id: string) {\n commit('SET_SUBSCRIPTION_LOADING', {subject: 'subscribing', loading: true});\n\n axios.delete(`/v1/subscription/addon/${id}`)\n .then((response) => {\n commit('SET_SUBSCRIPTION', response.data.subscription);\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'subscription swap successful',\n });\n EventBus.$emit('swap-plan-success');\n }).catch((e) => {\n console.dir(e);\n EventBus.$emit('SystemMessage', {\n type: 'error',\n message: e.response.data.message,\n });\n }).finally(() => {\n commit('SET_SUBSCRIPTION_LOADING', {subject: 'subscribing', loading: false});\n });\n },\n\n cancelSubscription({commit}) {\n commit('SET_SUBSCRIPTION_LOADING', {subject: 'cancelSubscription', loading: true});\n commit('CLEAR_SUBSCRIPTION_FORM_ERRORS');\n\n axios.delete('/v1/subscription')\n .then((response) => {\n commit('SET_SUBSCRIPTION', response.data.subscription);\n EventBus.$emit('cancel-subscription-success');\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'Cancel subscription successful',\n });\n }).catch((e) => {\n commit(types.SET_SUBSCRIPTION_FORM_ERROR, e?.response?.data?.message || 'There was an error cancelling your subscription.');\n }).finally(() => {\n commit('SET_SUBSCRIPTION_LOADING', {subject: 'cancelSubscription', loading: false});\n });\n },\n\n async cancelSubscriptionStripePortalUrl({commit}) {\n try {\n return await performApiRequest(commit, 'SET_SUBSCRIPTION_LOADING', 'cancelSubscription', () => axios.get('/v1/subscription/cancel-portal'));\n } catch (error) {\n }\n },\n\n async resumeSubscription({commit}) {\n try {\n const responseData = await performApiRequest(commit, 'SET_SUBSCRIPTION_LOADING', 'resumeSubscription', () => axios.put('/v1/subscription'));\n commit('SET_SUBSCRIPTION', responseData.subscription);\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'Resume subscription successful',\n });\n return responseData;\n } catch (error) {\n EventBus.$emit('SystemMessage', {\n type: 'error',\n message: error.response?.data?.message || \"There was an error resuming your subscription.\",\n });\n }\n },\n\n /**\n * End trial early and start subscription\n */\n async endTrial({commit}) {\n\n try {\n const responseData = await performApiRequest(commit, 'SET_SUBSCRIPTION_LOADING', 'endTrial', () => axios.post('/v1/end-trial'));\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'Ended trial successful',\n });\n\n return responseData;\n } catch (error) {\n EventBus.$emit('SystemMessage', {\n type: 'error',\n message: error.response?.data?.message || \"There was an error ending your trial.\",\n });\n throw error;\n }\n },\n};\n\nexport default {\n namespaced: true,\n state,\n mutations,\n actions,\n getters,\n};\n","import axios from 'axios';\nimport {EventBus} from '@/plugins/eventBus';\nimport router from '@/router';\nimport * as types from '../mutation-types';\nimport {createUrlQueryString} from '@/utils/urls';\nimport {get} from 'lodash';\nimport {performApiRequest} from '@/store/helpers/vuex-helpers';\nimport {CompanyInterface, PermissionsArray} from '@/types';\n\nexport interface SuperUserState {\n loading: Record<string, boolean>,\n users: Array<any>,\n companies: CompanyInterface[],\n companiesMeta: {\n current_page: number,\n from: number,\n last_page: number,\n per_page: number,\n to: number,\n total: number,\n },\n currentWorkingCompany: any,\n currentWorkingUser: any,\n roles: Array<any>,\n permissions: PermissionsArray,\n media: Array<any>,\n mediaDirectories: Array<any>,\n mediaPath: string,\n allListingImages: Array<any>,\n serverDetails: any,\n basicStats: {\n active_users: Array<any>,\n subscribers: any,\n users: number | null,\n trials: number | null,\n listings: number | null,\n automations: number | null,\n bookings: number | null,\n connections: {\n tesla_accounts: number | null,\n turo_accounts: number | null,\n getaround_accounts: number | null,\n },\n },\n featureWaitlist: Array<any>,\n featuresStatus: Array<any>,\n cache: Array<any>,\n}\n\nconst state: SuperUserState = {\n loading: {\n users: null,\n roles: null,\n permissions: null,\n automations: null,\n bookings: null,\n connections: null,\n listings: null,\n subscribers: null,\n activeUsers: null,\n turoTrip: null,\n },\n users: [],\n companies: [],\n companiesMeta: {\n current_page: 1,\n from: 1,\n last_page: 1,\n per_page: 1,\n to: 1,\n total: 1,\n },\n currentWorkingCompany: {},\n currentWorkingUser: {},\n roles: [],\n permissions: [],\n media: [],\n mediaDirectories: [],\n mediaPath: '',\n allListingImages: [],\n serverDetails: {},\n basicStats: {\n active_users: [],\n subscribers: {},\n users: null,\n trials: null,\n listings: null,\n automations: null,\n bookings: null,\n connections: {\n tesla_accounts: null,\n turo_accounts: null,\n getaround_accounts: null,\n },\n },\n\n featureWaitlist: [],\n featuresStatus: [],\n cache: [],\n};\n\nconst getters = {\n loading: (state: SuperUserState) => state.loading,\n allUsers: (state: SuperUserState) => state.users,\n allCompanies: (state: SuperUserState) => state.companies,\n companiesMeta: (state: SuperUserState) => state.companiesMeta,\n currentWorkingUser: (state: SuperUserState) => state.currentWorkingUser,\n currentWorkingCompany: (state: SuperUserState) => state.currentWorkingCompany,\n roles: (state: SuperUserState) => state.roles,\n permissions: (state: SuperUserState) => state.permissions,\n mediaDirectories: (state: SuperUserState) => state.mediaDirectories,\n media: (state: SuperUserState) => state.media,\n mediaPath: (state: SuperUserState) => state.mediaPath,\n allListingImages: (state: SuperUserState) => state.allListingImages,\n basicStats: (state: SuperUserState) => state.basicStats,\n serverDetails: (state: SuperUserState) => state.serverDetails,\n featureWaitlist: (state: SuperUserState) => state.featureWaitlist,\n featuresStatus: (state: SuperUserState) => state.featuresStatus,\n cache: (state: SuperUserState) => state.cache,\n};\n\nconst mutations = {\n [types.SET_SU_LOADING](state: SuperUserState, loading: { subject: string, loading: boolean }) {\n state.loading[loading.subject] = loading.loading;\n },\n [types.SET_ALL_USERS](state: SuperUserState, users) {\n state.users = users;\n },\n [types.SET_ALL_COMPANIES](state: SuperUserState, companies) {\n if (companies.current_page === 1) {\n state.companies = companies.data;\n } else {\n // state.companies = state.companies.concat(companies.data);\n }\n\n state.companiesMeta = {\n current_page: companies.current_page,\n from: companies.from,\n last_page: companies.last_page,\n per_page: companies.per_page,\n to: companies.to,\n total: companies.total,\n };\n },\n [types.SET_CURRENT_WORKING_COMPANY](state: SuperUserState, company) {\n state.currentWorkingCompany = company;\n },\n [types.SET_CURRENT_WORKING_USER](state: SuperUserState, user) {\n state.currentWorkingUser = user;\n },\n [types.SET_ALL_ROLES](state: SuperUserState, roles) {\n state.roles = roles;\n },\n [types.SET_ALL_PERMISSIONS](state: SuperUserState, permissions) {\n state.permissions = permissions;\n },\n [types.SET_ALL_MEDIA_DIRECTORIES](state: SuperUserState, mediaDirectories) {\n state.mediaDirectories = mediaDirectories;\n },\n [types.SET_ALL_MEDIA_IN_DIRECTORY](state: SuperUserState, media) {\n state.media = media;\n },\n [types.SET_MEDIA_BASE_PATH](state: SuperUserState, path) {\n state.mediaPath = path;\n },\n [types.SET_ALL_LISTING_IMAGES](state: SuperUserState, images) {\n state.allListingImages = images;\n },\n [types.SET_ALL_SERVER_DETAILS](state: SuperUserState, details) {\n state.serverDetails = details;\n },\n [types.SET_SA_FEATURE_WAITLIST](state: SuperUserState, waitlist) {\n state.featureWaitlist = waitlist;\n },\n [types.SET_SA_FEATURES_STATUS](state: SuperUserState, status) {\n state.featuresStatus = status;\n },\n [types.SET_SA_CACHE](state: SuperUserState, cache) {\n state.cache = cache;\n },\n [types.SET_CURRENT_WORKING_SU_BASIC_STATS](state: SuperUserState, stats) {\n state.basicStats[Object.keys(stats)[0]] = stats[Object.keys(stats)[0]];\n },\n};\n\nconst actions = {\n async fetchAllUsers({commit}) {\n try {\n const responseData = await performApiRequest(commit, 'SET_SU_LOADING', 'users', () => axios.get('/v1/su/users'));\n commit('SET_ALL_USERS', responseData.users);\n } catch (error) {\n console.error(error)\n }\n },\n\n async fetchOneUsers({commit}, uuid) {\n try {\n const responseData = await performApiRequest(commit, 'SET_SU_LOADING', 'users', () => axios.get(`/v1/su/users/${uuid}`));\n commit('SET_CURRENT_WORKING_USER', responseData.user);\n } catch (error) {\n console.error(error)\n }\n },\n async purgeFeatures({commit}) {\n try {\n await performApiRequest(commit, 'SET_SU_LOADING', 'users', () => axios.post('/v1/su/features/purge'));\n } catch (error) {\n console.error(error)\n }\n },\n async getFeaturesWaitlist({commit}) {\n try {\n const responseData = await performApiRequest(commit, 'SET_SU_LOADING', 'users', () => axios.get('/v1/su/features-waitlist'));\n commit('SET_SA_FEATURE_WAITLIST', responseData.waitlist);\n } catch (error) {\n console.error(error)\n }\n },\n setAllowFeature({commit}, feature) {\n axios.post('/v1/su/features/allow', feature)\n .then(() => {\n EventBus.$emit('sa-set-allow-feature-success');\n }).catch(() => {\n }).finally(() => {\n });\n },\n setRemoveFeature({commit}, feature) {\n axios.post('/v1/su/features/remove', feature)\n .then(() => {\n EventBus.$emit('sa-set-allow-feature-success');\n }).catch(() => {\n }).finally(() => {\n });\n },\n setAllowFeatureFromWishlist({commit}, feature) {\n axios.post(`/v1/su/features-waitlist/allow/${feature}`)\n .then(() => {\n // commit('SET_SA_FEATURE_WAITLIST', response.data.waitlist);\n }).catch(() => {\n }).finally(() => {\n });\n },\n\n getFeatures({commit}) {\n axios.get('/v1/su/features')\n .then((response) => {\n commit('SET_SA_FEATURES_STATUS', response.data.featuresStatus);\n }).catch(() => {\n }).finally(() => {\n });\n },\n\n getCache({commit}) {\n axios.get('/v1/su/cache')\n .then((response) => {\n commit('SET_SA_CACHE', response.data.cache);\n }).catch(() => {\n }).finally(() => {\n });\n },\n\n clearCache(data = null) {\n axios.delete('/v1/su/cache', {data})\n .catch(() => {\n }).finally(() => {\n });\n },\n\n async getFleetwirePartners({commit}) {\n return await performApiRequest(commit, 'SET_SU_LOADING', 'getFleetwirePartners', () => axios.get('/v1/su/partners'));\n },\n\n getFleetwirePartner({commit}, getFleetwirePartner) {\n axios.get(`/v1/su/partners/${getFleetwirePartner}`)\n .then((response) => {\n EventBus.$emit('get-fleetwire-partner-success', response.data);\n }).catch(() => {\n }).finally(() => {\n });\n },\n\n async updateUser({commit}, user) {\n try {\n const responseData = await performApiRequest(commit, 'SET_SU_LOADING', 'users', () => axios.put(`/v1/su/users/${user.uuid}`, user));\n commit('SET_CURRENT_WORKING_USER', responseData.user);\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'User Saved',\n });\n } catch (error) {\n console.error(error)\n }\n },\n\n fetchAllCompanies({commit}, data) {\n const page = get(data, 'page', 1) || 1;\n\n axios.get(`/v1/su/company?page=${page}`)\n .then((response) => {\n commit('SET_ALL_COMPANIES', response.data);\n }).catch(() => {\n }).finally(() => {\n });\n },\n\n async fetchAllMedia({commit}) {\n const responseData = await performApiRequest(commit, 'SET_SU_LOADING', 'users', () => axios.get('/v1/su/media'));\n commit(types.SET_ALL_MEDIA_DIRECTORIES, responseData.directories);\n return responseData;\n },\n async fetchDirectories({commit}, payload: { path: string }) {\n console.dir('fetchDirectories');\n console.dir(payload);\n const urlParams = new URLSearchParams();\n urlParams.append('path', payload.path);\n const query = urlParams.toString();\n return await performApiRequest(commit, 'SET_SU_LOADING', 'directory', () => axios.get(`/v1/su/directory?${query}`));\n },\n\n fetchServerDetails({commit}) {\n axios.get('/v1/su/server-details')\n .then((response) => {\n commit('SET_ALL_SERVER_DETAILS', response.data.details);\n }).catch(() => {\n }).finally(() => {\n });\n },\n\n async fetchAllMediaInDirectory({commit}, directory) {\n const responseData = await performApiRequest(commit, 'SET_SU_LOADING', 'users', () => axios.get(`/v1/su/media/directory?directory=${directory}`));\n commit(types.SET_ALL_MEDIA_IN_DIRECTORY, responseData.media);\n commit(types.SET_MEDIA_BASE_PATH, responseData.path);\n return responseData;\n },\n\n fetchAllListingImages({commit}) {\n axios.get('/v1/su/listing-images')\n .then((response) => {\n commit('SET_ALL_LISTING_IMAGES', response.data.images);\n }).catch(() => {\n }).finally(() => {\n });\n },\n\n resizeImage({commit}, path) {\n axios.put('/v1/su/resize-image', {path})\n .then(() => {\n }).catch(() => {\n }).finally(() => {\n });\n },\n\n fetchOneCompany({commit}, uuid) {\n axios.get(`/v1/su/company/${uuid}`)\n .then((response) => {\n commit('SET_CURRENT_WORKING_COMPANY', response.data.company);\n }).catch(() => {\n }).finally(() => {\n });\n },\n\n updateCompany({commit, state}) {\n axios.put(`/v1/su/company/${state.currentWorkingCompany.uuid}`, state.currentWorkingCompany)\n .then((response) => {\n commit('SET_CURRENT_WORKING_COMPANY', response.data.company);\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'Company Updated',\n });\n }).catch(() => {\n }).finally(() => {\n });\n },\n\n deleteCompany({commit, state}) {\n axios.delete(`/v1/su/company/${state.currentWorkingCompany.uuid}`)\n .then((response) => {\n commit('SET_CURRENT_WORKING_USER', response.data.user);\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'User Saved',\n });\n }).catch(() => {\n }).finally(() => {\n });\n },\n\n getBasicStats({commit}) {\n axios.get('/v1/su/stats')\n .then((response) => {\n commit('SET_CURRENT_WORKING_SU_BASIC_STATS', response.data.stats);\n }).catch(() => {\n }).finally(() => {\n });\n },\n\n getActiveUsersStats({commit}) {\n commit('SET_SU_LOADING', {subject: 'activeUsers', loading: true});\n\n axios.get('/v1/su/stats/users')\n .then((response) => {\n commit('SET_CURRENT_WORKING_SU_BASIC_STATS', {active_users: response.data.stats});\n }).catch(() => {\n }).finally(() => {\n commit('SET_SU_LOADING', {subject: 'activeUsers', loading: false});\n });\n },\n\n testUserAPN({commit}) {\n commit('SET_SU_LOADING', {subject: 'activeUsers', loading: true});\n\n axios.get('/v1/su/pusher-test-user-notification')\n .then(() => {\n }).catch(() => {\n }).finally(() => {\n commit('SET_SU_LOADING', {subject: 'activeUsers', loading: false});\n });\n },\n\n getSubscribersStats({commit}) {\n commit('SET_SU_LOADING', {subject: 'subscribers', loading: true});\n\n axios.get('/v1/su/stats/subscribers')\n .then((response) => {\n commit('SET_CURRENT_WORKING_SU_BASIC_STATS', {subscribers: response.data.stats});\n }).catch(() => {\n }).finally(() => {\n commit('SET_SU_LOADING', {subject: 'subscribers', loading: false});\n });\n },\n\n getListingStats({commit}) {\n commit('SET_SU_LOADING', {subject: 'listings', loading: true});\n\n axios.get('/v1/su/stats/listingStats')\n .then((response) => {\n commit('SET_CURRENT_WORKING_SU_BASIC_STATS', {listings: response.data.stats});\n }).catch(() => {\n }).finally(() => {\n commit('SET_SU_LOADING', {subject: 'listings', loading: false});\n });\n },\n\n getConnectionsStats({commit}) {\n commit('SET_SU_LOADING', {subject: 'connections', loading: true});\n\n axios.get('/v1/su/stats/connectionsStats')\n .then((response) => {\n commit('SET_CURRENT_WORKING_SU_BASIC_STATS', {connections: response.data.stats});\n }).catch(() => {\n }).finally(() => {\n commit('SET_SU_LOADING', {subject: 'connections', loading: false});\n });\n },\n\n getAutomations({commit}, data) {\n commit('SET_SU_LOADING', {subject: 'automations', loading: true});\n\n const query = createUrlQueryString(data);\n\n axios.get(`/v1/su/stats/automations${query}`)\n .then((response) => {\n EventBus.$emit('get-automations-success', response.data);\n }).catch(() => {\n }).finally(() => {\n commit('SET_SU_LOADING', {subject: 'automations', loading: false});\n });\n },\n getAutomationsStats({commit}) {\n commit('SET_SU_LOADING', {subject: 'automations', loading: true});\n\n axios.get('/v1/su/stats/automationsStats')\n .then((response) => {\n commit('SET_CURRENT_WORKING_SU_BASIC_STATS', {automations: response.data.stats});\n }).catch(() => {\n }).finally(() => {\n commit('SET_SU_LOADING', {subject: 'automations', loading: false});\n });\n },\n getAutomationsStatsData({commit}, data) {\n commit('SET_SU_LOADING', {subject: 'automations', loading: true});\n\n const query = createUrlQueryString(data);\n\n axios.get(`/v1/su/stats/automationsStatsData${query}`)\n .then((response) => {\n EventBus.$emit('get-automation-stats-data-success', response.data);\n }).catch(() => {\n }).finally(() => {\n commit('SET_SU_LOADING', {subject: 'automations', loading: false});\n });\n },\n getTuroTrip({commit}, data) {\n commit('SET_SU_LOADING', {subject: 'turoTrip', loading: true});\n\n const query = createUrlQueryString(data);\n\n axios.get(`/v1/su/stats/getTuroTrip${query}`)\n .then((response) => {\n EventBus.$emit('get-turo-trip-success', response.data);\n }).catch(() => {\n }).finally(() => {\n commit('SET_SU_LOADING', {subject: 'turoTrip', loading: false});\n });\n },\n getBookingsStats({commit}) {\n commit('SET_SU_LOADING', {subject: 'bookings', loading: true});\n\n axios.get('/v1/su/stats/bookingStats')\n .then((response) => {\n commit('SET_CURRENT_WORKING_SU_BASIC_STATS', {bookings: response.data.stats});\n }).catch(() => {\n }).finally(() => {\n commit('SET_SU_LOADING', {subject: 'bookings', loading: false});\n });\n },\n\n async fetchAllRoles({commit}) {\n try {\n const responseData = await performApiRequest(commit, 'SET_SU_LOADING', 'roles', () => axios.get('/v1/roles'));\n commit('SET_ALL_ROLES', responseData.roles);\n } catch (error) {\n console.error(error)\n }\n },\n\n async fetchAllPermissions({commit}) {\n try {\n const responseData = await performApiRequest(commit, 'SET_SU_LOADING', 'permissions', () => axios.get('/v1/permissions'));\n commit('SET_ALL_PERMISSIONS', responseData.permissions);\n } catch (error) {\n console.error(error)\n }\n },\n\n createPermission({commit}, data) {\n axios.post('/v1/permissions', data)\n .then((response) => {\n commit('SET_ALL_PERMISSIONS', response.data.permissions);\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'Permission Created',\n });\n router.push({name: 'super.admin.permissions'});\n }).catch(() => {\n }).finally(() => {\n });\n },\n\n updatePermission({commit}, data) {\n axios.put(`/v1/permissions/${data.id}`, data)\n .then((response) => {\n commit('SET_ALL_PERMISSIONS', response.data.permissions);\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'Permission Updated',\n });\n }).catch(() => {\n }).finally(() => {\n });\n },\n\n deletePermission({commit}, data) {\n axios.delete(`/v1/permissions/${data.id}`)\n .then((response) => {\n commit('SET_ALL_PERMISSIONS', response.data.permissions);\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'Permission Deleted',\n });\n router.push({name: 'super.admin.permissions'});\n }).catch(() => {\n }).finally(() => {\n });\n },\n\n masqueradeInit({commit, rootGetters}, user) {\n axios.get(`/v1/users/${user.uuid}/masquerade`)\n .then((response) => {\n commit('app/SET_MASQUERADE', {\n user: response.data.user,\n token: response.data.token,\n admin: {\n email: rootGetters['auth/user'].email,\n uuid: rootGetters['auth/user'].uuid,\n },\n }, {root: true});\n }).catch(() => {\n }).finally(() => {\n });\n },\n\n encryptText({commit}, string) {\n axios.post('/v1/su/encrypt-text', {text: string})\n .then((response) => {\n EventBus.$emit('su-encrypt-text-success', response.data.result);\n }).catch((e) => {\n EventBus.$emit('su-encrypt-text-failed', e.response.data.message);\n }).finally(() => {\n });\n },\n\n decryptText({commit}, string) {\n axios.post('/v1/su/decrypt-text', {text: string})\n .then((response) => {\n EventBus.$emit('su-decrypt-text-success', response.data.result);\n }).catch((e) => {\n EventBus.$emit('su-decrypt-text-failed', e.response.data.message);\n }).finally(() => {\n });\n },\n uploadMedia({commit}, file) {\n axios.post('/v1/su/upload-media', file)\n .then((response) => {\n EventBus.$emit('su-upload-media-success', response.data.path);\n }).catch((e) => {\n EventBus.$emit('su-decrypt-text-failed', e.response.data.message);\n }).finally(() => {\n });\n },\n};\n\nexport default {\n namespaced: true,\n state,\n mutations,\n actions,\n getters,\n};\n","\nexport interface TagsViewState {\n visitedViews: any[];\n cachedViews: string[];\n}\n\nconst state: TagsViewState = {\n visitedViews: [],\n cachedViews: [],\n};\n\nconst mutations = {\n ADD_VISITED_VIEW: (state, view) => {\n if (state.visitedViews.some((v) => v.path === view.path)) {\n return;\n }\n\n state.visitedViews.push(\n { ...view, title: view.meta.title || 'no-name' },\n );\n },\n ADD_CACHED_VIEW: (state, view) => {\n if (state.cachedViews.includes(view.name)) {\n return;\n }\n\n if (!view.meta.noCache) {\n state.cachedViews.push(view.name);\n }\n },\n\n DEL_VISITED_VIEW: (state, view) => {\n for (const [i, v] of state.visitedViews.entries()) {\n if (v.path === view.path) {\n state.visitedViews.splice(i, 1);\n break;\n }\n }\n },\n DEL_CACHED_VIEW: (state, view) => {\n for (const i of state.cachedViews) {\n if (i === view.name) {\n const index = state.cachedViews.indexOf(i);\n state.cachedViews.splice(index, 1);\n break;\n }\n }\n },\n\n DEL_OTHERS_VISITED_VIEWS: (state, view) => {\n state.visitedViews = state.visitedViews.filter((v) => v.meta.affix || v.path === view.path);\n },\n DEL_OTHERS_CACHED_VIEWS: (state, view) => {\n for (const i of state.cachedViews) {\n if (i === view.name) {\n const index = state.cachedViews.indexOf(i);\n state.cachedViews = state.cachedViews.slice(index, index + 1);\n break;\n }\n }\n },\n\n DEL_ALL_VISITED_VIEWS: (state) => {\n // keep affix tags\n state.visitedViews = state.visitedViews.filter((tag) => tag.meta.affix);\n },\n DEL_ALL_CACHED_VIEWS: (state) => {\n state.cachedViews = [];\n },\n\n UPDATE_VISITED_VIEW: (state, view) => {\n for (let v of state.visitedViews) {\n if (v.path === view.path) {\n v = Object.assign(v, view);\n break;\n }\n }\n },\n};\n\nconst actions = {\n addView({ dispatch }, view) {\n dispatch('addVisitedView', view);\n dispatch('addCachedView', view);\n },\n addVisitedView({ commit }, view) {\n commit('ADD_VISITED_VIEW', view);\n },\n addCachedView({ commit }, view) {\n commit('ADD_CACHED_VIEW', view);\n },\n\n delView({ dispatch, state }, view) {\n return new Promise((resolve) => {\n dispatch('delVisitedView', view);\n dispatch('delCachedView', view);\n resolve({\n visitedViews: [...state.visitedViews],\n cachedViews: [...state.cachedViews],\n });\n });\n },\n delVisitedView({ commit, state }, view) {\n return new Promise((resolve) => {\n commit('DEL_VISITED_VIEW', view);\n resolve([...state.visitedViews]);\n });\n },\n delCachedView({ commit, state }, view) {\n return new Promise((resolve) => {\n commit('DEL_CACHED_VIEW', view);\n resolve([...state.cachedViews]);\n });\n },\n\n delOthersViews({ dispatch, state }, view) {\n return new Promise((resolve) => {\n dispatch('delOthersVisitedViews', view);\n dispatch('delOthersCachedViews', view);\n resolve({\n visitedViews: [...state.visitedViews],\n cachedViews: [...state.cachedViews],\n });\n });\n },\n delOthersVisitedViews({ commit, state }, view) {\n return new Promise((resolve) => {\n commit('DEL_OTHERS_VISITED_VIEWS', view);\n resolve([...state.visitedViews]);\n });\n },\n delOthersCachedViews({ commit, state }, view) {\n return new Promise((resolve) => {\n commit('DEL_OTHERS_CACHED_VIEWS', view);\n resolve([...state.cachedViews]);\n });\n },\n\n delAllViews({ dispatch, state }, view) {\n return new Promise((resolve) => {\n dispatch('delAllVisitedViews', view);\n dispatch('delAllCachedViews', view);\n resolve({\n visitedViews: [...state.visitedViews],\n cachedViews: [...state.cachedViews],\n });\n });\n },\n delAllVisitedViews({ commit, state }) {\n return new Promise((resolve) => {\n commit('DEL_ALL_VISITED_VIEWS');\n resolve([...state.visitedViews]);\n });\n },\n delAllCachedViews({ commit, state }) {\n return new Promise((resolve) => {\n commit('DEL_ALL_CACHED_VIEWS');\n resolve([...state.cachedViews]);\n });\n },\n\n updateVisitedView({ commit }, view) {\n commit('UPDATE_VISITED_VIEW', view);\n },\n};\n\nexport default {\n namespaced: true,\n state,\n mutations,\n actions,\n};\n","import axios from 'axios';\nimport {Form} from '@/plugins/FWForms/index';\nimport {EventBus} from '@/plugins/eventBus';\nimport * as types from '../mutation-types';\nimport {performApiRequest} from '@/store/helpers/vuex-helpers';\nimport {TaxCategory} from '@/types';\nimport {push} from 'notivue'\n\nexport interface TaxesState {\n init: boolean,\n loading: Record<string, boolean>,\n taxForm: Form<any>,\n taxCategories: TaxCategory[],\n currentWorkingTaxCategory: TaxCategory,\n}\n\nconst state: TaxesState = {\n init: false,\n loading: {\n tax_categories: false,\n set_default: false,\n index: false,\n create: false,\n delete: false,\n update: false,\n },\n taxForm: new Form(),\n taxCategories: [],\n currentWorkingTaxCategory: {\n default: false,\n name: '',\n tax_rates: [{\n name: '',\n percentage: '',\n amount: null,\n type: 'trip',\n }],\n },\n};\n\nconst getters = {\n init: (state: TaxesState) => state.init,\n loading: (state: TaxesState) => state.loading,\n taxForm: (state: TaxesState) => state.taxForm,\n taxCategories: (state: TaxesState) => state.taxCategories,\n currentWorkingTaxCategory: (state: TaxesState) => state.currentWorkingTaxCategory,\n};\n\nconst mutations = {\n [types.SET_TAXES_LOADING](state: TaxesState, loading: { subject: string, loading: boolean }) {\n state.loading[loading.subject] = loading.loading;\n },\n [types.SET_TAX_CATEGORIES](state: TaxesState, tax) {\n state.taxCategories = tax;\n },\n [types.SET_CURRENT_WORKING_TAX_CATEGORY](state: TaxesState, tax) {\n state.currentWorkingTaxCategory = tax;\n },\n [types.SET_TAX_CATEGORY_FORM_ERRORS](state: TaxesState, error: string | Record<string, string[]>) {\n state.taxForm.errors.set(error);\n },\n [types.CLEAR_TAX_CATEGORY_FORM_ERRORS](state: TaxesState, form_field) {\n if (form_field === null || form_field === undefined) {\n state.taxForm.errors.clear();\n } else {\n state.taxForm.errors.clear(form_field);\n }\n },\n [types.RESET_CURRENT_WORKING_TAX_CATEGORY](state: TaxesState) {\n state.currentWorkingTaxCategory = {\n default: false,\n name: '',\n tax_rates: [{\n name: '',\n percentage: '',\n amount: null,\n type: 'trip',\n }],\n };\n },\n};\n\nconst actions = {\n\n\n /**\n * Get tax categories\n */\n async getTaxCategories({commit}) {\n try {\n const responseData = await performApiRequest(commit, 'SET_TAXES_LOADING', 'index', () => axios.get('/v1/tax-categories'));\n EventBus.$emit('get-tax-category-success');\n commit('SET_TAX_CATEGORIES', responseData.taxCategories || []);\n } catch (error) {\n commit(types.SET_TAX_CATEGORY_FORM_ERRORS, error);\n throw error;\n }\n },\n\n\n /**\n * Save tax categories\n */\n async saveTaxCategory({commit}, taxCategory: TaxCategory) {\n try {\n commit('CLEAR_TAX_CATEGORY_FORM_ERRORS');\n const responseData = await performApiRequest(commit, 'SET_TAXES_LOADING', 'create', () => axios.post('/v1/tax-categories', taxCategory));\n commit('SET_TAX_CATEGORIES', responseData?.taxCategories || []);\n push.success({\n message: 'Tax Category created successfully',\n });\n EventBus.$emit('save-tax-category-success');\n } catch (error) {\n console.dir(error);\n commit(types.SET_TAX_CATEGORY_FORM_ERRORS, error?.response?.data?.errors || 'There was an error');\n throw error;\n }\n },\n\n\n /**\n * Update tax categories\n */\n async updateTaxCategory({commit}, taxCategory: TaxCategory) {\n try {\n commit(types.CLEAR_TAX_CATEGORY_FORM_ERRORS);\n const responseData = await performApiRequest(commit, 'SET_TAXES_LOADING', 'update', () => axios.put(`/v1/tax-categories/${taxCategory.uuid}`, taxCategory));\n commit(types.SET_TAX_CATEGORIES, responseData?.taxCategories || []);\n push.success({\n message: 'Tax Category updated successfully',\n });\n } catch (error) {\n commit(types.SET_TAX_CATEGORY_FORM_ERRORS, error.response.data?.errors || 'There was an error');\n throw error;\n }\n },\n\n\n /**\n * Delete tax categories\n */\n async deleteTaxCategory({commit}, taxCategory: TaxCategory) {\n try {\n const responseData = await performApiRequest(commit, 'SET_TAXES_LOADING', 'delete', () => axios.delete(`/v1/tax-categories/${taxCategory.uuid}`));\n commit(types.SET_TAX_CATEGORIES, responseData?.taxCategories || []);\n\n push.success({\n message: 'Tax Category deleted successfully',\n });\n } catch (error) {\n throw error;\n }\n },\n\n\n /**\n * Set tax category default\n */\n async taxCategorySetDefault({commit}, taxCategory: TaxCategory) {\n try {\n const responseData = await performApiRequest(commit, 'SET_TAXES_LOADING', 'set_default', () => axios.post(`/v1/tax-categories/${taxCategory.uuid}/set-default`));\n commit(types.SET_TAX_CATEGORIES, responseData?.taxCategories || []);\n\n push.success({\n message: 'Tax Category set as default',\n });\n } catch (error) {\n throw error;\n }\n },\n};\n\nexport default {\n namespaced: true,\n state,\n mutations,\n actions,\n getters,\n};\n","import axios from 'axios';\nimport * as types from '../mutation-types';\nimport {performApiRequest} from '@/store/helpers/vuex-helpers';\nimport {ListingInterface, MaintenanceTask} from '@/types';\nimport {push} from 'notivue';\n\n\nexport interface VehicleRecall {\n NHTSA_action_number: string | null,\n NHTSA_campaign_number: string,\n component: string,\n consequence: string | null,\n created_at: string | null,\n id: number,\n manufacturer: string,\n notes: string,\n remedy: string,\n report_received_date: string,\n summary: string,\n updated_at: string | null,\n vehicle_make: string,\n vehicle_model: string,\n vehicle_year: number\n}\n\nexport interface VehicleListingRecall {\n addressed_at: string | null,\n created_at: string | null,\n notified_at: string,\n status: string | null,\n updated_at: string | null,\n vehicle_recall: VehicleRecall\n}\n\nexport interface MaintenanceState {\n loading: Record<string, boolean>,\n reminderDays: number[],\n reminderInterval: string[],\n maintenanceTypes: string[],\n maintenanceTasks: string[],\n repairTasks: string[],\n currentMaintenance: MaintenanceTask[],\n currentRecalls: VehicleListingRecall[],\n}\n\nconst state: MaintenanceState = {\n loading: {\n fetch: false,\n adding: false,\n updating: false,\n complete: false,\n delete: false,\n recalls: false,\n },\n currentMaintenance: [],\n currentRecalls: [],\n\n reminderDays: [30, 60, 90],\n reminderInterval: ['yearly'],\n maintenanceTypes: ['Maintenance', 'Repair'],\n maintenanceTasks: [\n 'Oil Change',\n 'Tire Replacement',\n 'Wheel Alignment',\n 'Air Filter',\n 'Fluids',\n 'Breaks',\n 'Engine',\n 'Transmission',\n 'Suspension',\n 'Body',\n 'Interior',\n 'Battery',\n 'Electronics',\n 'Other',\n ],\n repairTasks: [],\n};\n\n\nconst getters = {\n loading: (state: MaintenanceState) => state.loading,\n reminderDays: (state: MaintenanceState) => state.reminderDays,\n reminderInterval: (state: MaintenanceState) => state.reminderInterval,\n maintenanceTypes: (state: MaintenanceState) => state.maintenanceTypes,\n maintenanceTasks: (state: MaintenanceState) => state.maintenanceTasks,\n currentMaintenance: (state: MaintenanceState) => state.currentMaintenance,\n currentRecalls: (state: MaintenanceState) => state.currentRecalls,\n};\n\n\nconst mutations = {\n [types.SET_MAINTENANCE_LOADING](state: MaintenanceState, loading: { subject: string, loading: boolean }) {\n state.loading[loading.subject] = loading.loading;\n },\n [types.SET_CURRENT_VEHICLE_MAINTENANCE](state: MaintenanceState, maintenance: MaintenanceTask[]) {\n state.currentMaintenance = maintenance;\n },\n [types.SET_CURRENT_VEHICLE_RECALLS](state: MaintenanceState, recalls: VehicleListingRecall[]) {\n state.currentRecalls = recalls;\n },\n [types.RESET_CURRENT_WORKING_MAINTENANCE_ITEM](state: MaintenanceState) {\n state.currentMaintenance = [];\n },\n};\n\nconst actions = {\n\n /**\n * Fetch a vehicle maintenance record\n */\n async fetchVehicleMaintenance({commit}, listing: ListingInterface) {\n const responseData = await performApiRequest(commit, 'SET_MAINTENANCE_LOADING', 'fetch', () => axios.get(`/v1/listings/${listing.l_id}/maintenance`));\n commit(types.SET_CURRENT_VEHICLE_MAINTENANCE, responseData.maintenance);\n },\n\n /**\n * Fetch a vehicles recalls\n */\n async fetchVehicleRecalls({commit}, listing: ListingInterface) {\n const responseData = await performApiRequest(commit, 'SET_MAINTENANCE_LOADING', 'recalls', () => axios.get(`/v1/listings/${listing.l_id}/recalls`));\n commit(types.SET_CURRENT_VEHICLE_RECALLS, responseData.recall_listings);\n },\n\n\n /**\n * Creates a vehicle maintenance record\n */\n async createVehicleMaintenance({commit}, data: { listing: ListingInterface, maintenance: MaintenanceTask }) {\n try {\n const listingId = data.listing.l_id;\n const maintenanceItem = data.maintenance;\n await performApiRequest(commit, 'SET_MAINTENANCE_LOADING', 'adding', () => axios.post(`/v1/listings/${listingId}/maintenance`, maintenanceItem));\n push.sucess({\n message: 'Added successfully',\n });\n } catch (error) {\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n }\n },\n\n\n /**\n * Update a vehicle maintenance record\n */\n async updateVehicleMaintenance({commit}, data: { listing: ListingInterface, maintenance: MaintenanceTask }) {\n try {\n const listingId = data.listing.l_id;\n const maintenanceItem = data.maintenance;\n\n await performApiRequest(commit, 'SET_MAINTENANCE_LOADING', 'updating', () => axios.put(`/v1/listings/${listingId}/maintenance/${maintenanceItem.uuid}`, maintenanceItem));\n push.sucess({\n message: 'Updated successfully',\n });\n commit('RESET_CURRENT_WORKING_MAINTENANCE_ITEM');\n } catch (error) {\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n }\n },\n\n\n /**\n * Mark complete a vehicle maintenance record\n */\n async completeVehicleMaintenance({commit}, {listing, maintenance}) {\n const responseData = await performApiRequest(commit, 'SET_MAINTENANCE_LOADING', 'complete', () => axios.post(`/v1/listings/${listing.l_id}/maintenance/${maintenance.uuid}/complete`, maintenance));\n commit(types.SET_CURRENT_VEHICLE_MAINTENANCE, responseData.maintenance);\n\n push.sucess({\n message: 'Completed successfully',\n });\n },\n\n\n /**\n * Delete a vehicle maintenance record\n */\n async deleteVehicleMaintenance({commit}, maintenance: MaintenanceTask) {\n await performApiRequest(commit, 'SET_MAINTENANCE_LOADING', 'delete', () => axios.delete(`/v1/maintenance/${maintenance.uuid}`));\n push.sucess({\n message: 'Deleted successfully',\n });\n },\n};\n\n\nexport default {\n namespaced: true,\n state,\n mutations,\n actions,\n getters,\n};\n","import axios from 'axios';\nimport {get} from 'lodash';\nimport {EventBus} from '@/plugins/eventBus';\nimport {StorageService} from '@/services/storage.service';\nimport * as types from '../mutation-types';\nimport {performApiRequest} from '@/store/helpers/vuex-helpers';\nimport {OrderDocumentType, OrderLine, OrderType} from '@/types';\n\nexport interface OrderState {\n loading: Record<string, boolean>;\n orders: OrderType[];\n order: OrderType;\n documents: OrderDocumentType[];\n document: OrderDocumentType | null;\n downloadStatus: any;\n availability: any;\n currentWorkingPricingWizardOrderLine: OrderLine | null;\n dialogs: {\n pricingWizard: boolean;\n };\n}\n\nexport interface UpdateOrderPayload {\n orderUuid: string;\n attributes?: Record<string, any>;\n}\n\nconst state: OrderState = {\n loading: {\n orders: false,\n newOrder: false,\n update: false,\n cancelOrder: false,\n reserving: false,\n concept: false,\n deleteOrderDocument: false,\n updateLine: false,\n addLine: false,\n removeLine: false,\n holdDeposit: false,\n addCustomerToOrder: false,\n removeCustomer: false,\n getDocuments: false,\n },\n dialogs: {\n pricingWizard: false,\n },\n currentWorkingPricingWizardOrderLine: null,\n orders: [],\n order: null,\n documents: [],\n document: null,\n downloadStatus: null,\n availability: {},\n};\n\ninterface AddLinePayload {\n orderUuid: string;\n line: OrderLine;\n}\n\nconst getters = {\n orders: (state: OrderState) => state.orders,\n order: (state: OrderState) => state.order,\n documents: (state: OrderState) => state.documents,\n document: (state: OrderState) => state.document,\n loading: (state: OrderState) => state.loading,\n downloadStatus: (state: OrderState) => state.downloadStatus,\n availability: (state: OrderState) => state.availability,\n orderDialogs: (state: OrderState) => state.dialogs,\n currentWorkingPricingWizardOrderLine: (state: OrderState) => state.currentWorkingPricingWizardOrderLine,\n};\n\nconst mutations = {\n [types.SET_ORDERS_LOADING](state: OrderState, loading: { subject: string, loading: boolean }) {\n state.loading[loading.subject] = loading.loading;\n },\n [types.SET_ORDER](state: OrderState, order: OrderType) {\n console.dir('SET_ORDER');\n state.order = order;\n },\n [types.UPDATE_ORDER_LINE](state: OrderState, line) {\n let lines = state.order.lines;\n\n lines = lines.map((l) => {\n if (l.uuid === line.uuid) {\n return line;\n }\n return l;\n });\n\n state.order.lines = lines;\n },\n [types.SET_ORDER_DOCUMENTS](state: OrderState, documents: OrderDocumentType[]) {\n state.documents = documents;\n },\n [types.SET_ORDER_DOCUMENT](state: OrderState, document: OrderDocumentType) {\n state.document = document;\n },\n [types.SET_ORDER_DOCUMENT_DOWNLOAD_STATUS](state: OrderState, status) {\n state.downloadStatus = status;\n },\n [types.SET_ORDER_AVAILABILITY](state: OrderState, availability) {\n state.availability = availability;\n },\n [types.SET_OPEN_PRICING_WIZARD_DIALOG](state: OrderState, data) {\n state.currentWorkingPricingWizardOrderLine = data.lineItem;\n state.dialogs.pricingWizard = data.open;\n },\n};\n\nconst actions = {\n\n async newOrder({commit}) {\n try {\n const responseData = await performApiRequest(\n commit,\n 'SET_ORDERS_LOADING',\n 'newOrder',\n () => axios.get('/v1/orders/new')\n );\n\n commit('SET_ORDER', responseData.order);\n EventBus.$emit('get-new-order-success', responseData.order);\n } catch (error) {\n }\n },\n\n /**\n * Get order\n */\n async getOrder({commit}, orderUuid: string): Promise<void> {\n try {\n const responseData = await performApiRequest(\n commit,\n 'SET_ORDERS_LOADING',\n 'getOrder',\n () => axios.get(`/v1/orders/${orderUuid}`)\n );\n\n commit('SET_ORDER', responseData.order);\n } catch (error) {\n EventBus.$emit('SystemMessage', {\n type: 'error',\n message: error?.response?.data?.message || 'Failed to load order',\n });\n }\n },\n\n /**\n * Update order\n */\n async update({commit}, {orderUuid, attributes = {}}: UpdateOrderPayload) {\n try {\n const responseData = await performApiRequest(\n commit,\n 'SET_ORDERS_LOADING',\n 'update',\n () => axios.put(`/v1/orders/${orderUuid}`, {attributes})\n );\n const {order} = responseData;\n commit('SET_ORDER', order);\n EventBus.$emit('update-order-success', order);\n } catch (error) {\n const errorMessage = error?.response?.data?.message || 'There was an error';\n EventBus.$emit('SystemMessage', {\n type: 'error',\n message: errorMessage,\n });\n }\n },\n\n async makeCustomerPrimary({commit}, {orderUuid, r_id}) {\n try {\n const responseData = await performApiRequest(\n commit,\n 'SET_ORDERS_LOADING',\n 'update',\n () => axios.post(`/v1/orders/${orderUuid}/make-customer-primary`, {r_id})\n );\n\n commit(types.SET_ORDER, responseData.order);\n EventBus.$emit('update-order-success', responseData.order);\n } catch (error) {\n }\n },\n\n\n removeCustomer({commit}, {orderUuid, r_id}) {\n commit('SET_ORDERS_LOADING', {subject: 'removeCustomer', loading: true});\n\n axios.post(`/v1/orders/${orderUuid}/remove-customer`, {r_id})\n .then((response) => {\n commit('SET_ORDER', response.data.order);\n EventBus.$emit('update-order-success', response.data.order);\n }).catch(() => {\n }).finally(() => {\n commit('SET_ORDERS_LOADING', {subject: 'removeCustomer', loading: false});\n });\n },\n\n addCustomerToOrder({commit}, {orderUuid, r_id}) {\n commit('SET_ORDERS_LOADING', {subject: 'addCustomerToOrder', loading: true});\n\n axios.post(`/v1/orders/${orderUuid}/add-customer`, {r_id})\n .then((response) => {\n commit('SET_ORDER', response.data.order);\n EventBus.$emit('update-order-success', response.data.order);\n EventBus.$emit('add-customer-to-order-success', response.data.order);\n }).catch(() => {\n }).finally(() => {\n commit('SET_ORDERS_LOADING', {subject: 'addCustomerToOrder', loading: false});\n });\n },\n\n\n /**\n * Reserve a new order.\n */\n reserve({commit}, orderUuid: string) {\n commit('SET_ORDERS_LOADING', {subject: 'reserving', loading: true});\n\n axios.post(`/v1/orders/${orderUuid}/reserve`)\n .then((response) => {\n commit(types.SET_ORDER, response.data.order);\n EventBus.$emit('reserve-order-success', response.data);\n }).catch(() => {\n }).finally(() => {\n commit('SET_ORDERS_LOADING', {subject: 'reserving', loading: false});\n });\n },\n\n\n /**\n * Create a new order concept.\n */\n concept({commit}, orderUuid: string) {\n commit('SET_ORDERS_LOADING', {subject: 'concept', loading: true});\n\n axios.post(`/v1/company/${StorageService.getCompanyUuid()}/orders/${orderUuid}/concept`)\n .then((response) => {\n commit('SET_ORDER', response.data.order);\n EventBus.$emit('reserve-order-success', response.data);\n }).catch((e) => {\n EventBus.$emit('set-order-concept-error', e.response.data);\n }).finally(() => {\n commit('SET_ORDERS_LOADING', {subject: 'concept', loading: false});\n });\n },\n\n\n /**\n * Check availability of a new order.\n */\n availability({commit}, orderUuid: string) {\n commit('SET_ORDERS_LOADING', {subject: 'availability', loading: true});\n\n axios.get(`/v1/orders/${orderUuid}/availability`)\n .then((response) => {\n commit('SET_ORDER_AVAILABILITY', get(response, 'data.available', []));\n }).catch(() => {\n }).finally(() => {\n commit('SET_ORDERS_LOADING', {subject: 'availability', loading: false});\n });\n },\n\n\n /**\n * Hold the deposit of an order\n */\n holdOrderDeposit({commit}, {orderUuid, attributes}) {\n commit('SET_ORDERS_LOADING', {subject: 'holdDeposit', loading: true});\n\n axios.post(`/v1/orders/${orderUuid}/hold-deposit`, attributes)\n .then(() => {\n EventBus.$emit('hold-order-deposit-success');\n }).catch(() => {\n }).finally(() => {\n commit('SET_ORDERS_LOADING', {subject: 'holdDeposit', loading: false});\n });\n },\n\n\n /**\n * Create a new quote\n */\n createNewQuote({commit}, attributes) {\n commit('SET_ORDERS_LOADING', {subject: 'update', loading: true});\n\n axios.post('/v1/quotes', attributes)\n .then((response) => {\n EventBus.$emit('create-new-order-quote-success', get(response, 'data.document'));\n }).catch(() => {\n }).finally(() => {\n commit('SET_ORDERS_LOADING', {subject: 'update', loading: false});\n });\n },\n\n createNewOrderDocument({commit}, attributes) {\n commit('SET_ORDERS_LOADING', {subject: 'update', loading: true});\n\n axios.post('/v1/order-documents', attributes)\n .then((response) => {\n EventBus.$emit('create-new-order-quote-success', get(response, 'data.document'));\n }).catch(() => {\n }).finally(() => {\n commit('SET_ORDERS_LOADING', {subject: 'update', loading: false});\n });\n },\n\n\n getAllOrderDocuments({commit}) {\n commit('SET_ORDERS_LOADING', {subject: 'update', loading: true});\n\n axios.get('/v1/order-documents')\n .then((response) => {\n commit('SET_ORDER_DOCUMENTS', get(response, 'data.documents'));\n }).catch(() => {\n }).finally(() => {\n commit('SET_ORDERS_LOADING', {subject: 'update', loading: false});\n });\n },\n\n\n /**\n *Get the orders documents (rental agreement envelope, invoice, etc)\n */\n getOrderDocuments({commit}, orderUuid: string) {\n commit('SET_ORDERS_LOADING', {subject: 'getDocuments', loading: true});\n\n axios.get(`/v1/order-documents?order_id=${orderUuid}`)\n .then((response) => {\n commit('SET_ORDER_DOCUMENTS', get(response, 'data.documents'));\n }).catch(() => {\n }).finally(() => {\n commit('SET_ORDERS_LOADING', {subject: 'getDocuments', loading: false});\n });\n },\n\n async getOrderDocument({commit}, documentUuid: string) {\n const responseData = await performApiRequest(\n commit,\n 'SET_ORDERS_LOADING',\n 'update',\n () => axios.get(`/v1/order-documents/${documentUuid}`)\n );\n\n commit(types.SET_ORDER_DOCUMENT, responseData?.document);\n\n return responseData?.document;\n },\n\n updateOrderDocument({commit}, {documentUuid, attributes}) {\n commit('SET_ORDERS_LOADING', {subject: 'update', loading: true});\n\n axios.put(`/v1/order-documents/${documentUuid}`, {attributes})\n .then((response) => {\n commit('SET_ORDER_DOCUMENT', get(response, 'data.document'));\n EventBus.$emit('update-order-document-success', get(response, 'data.document'));\n }).catch((e) => {\n EventBus.$emit('update-order-document-error', e.response);\n EventBus.$emit('SystemMessage', {\n type: 'error',\n message: e?.response?.data?.message || 'There was an error',\n });\n }).finally(() => {\n commit('SET_ORDERS_LOADING', {subject: 'update', loading: false});\n });\n },\n\n async deleteOrderDocument({commit}, documentUuid: string) {\n console.dir('deleteOrderDocument');\n return await performApiRequest(\n commit,\n 'SET_ORDERS_LOADING',\n 'deleteOrderDocument',\n () => axios.delete(`/v1/order-documents/${documentUuid}`)\n );\n },\n\n downloadOrderDocument({commit}, documentUuid: string) {\n commit('SET_ORDERS_LOADING', {subject: 'update', loading: true});\n\n axios.get(`/v1/company/${StorageService.getCompanyUuid()}/order-documents/${documentUuid}/download`)\n .then((response) => {\n commit('SET_ORDER_DOCUMENT_DOWNLOAD_STATUS', response.data);\n EventBus.$emit('start-order-document-download-success', response.data);\n }).catch(() => {\n }).finally(() => {\n commit('SET_ORDERS_LOADING', {subject: 'update', loading: false});\n });\n },\n\n\n /**\n * Add a line item to an order\n */\n async addLine({commit}, {orderUuid, line}: AddLinePayload) {\n try {\n const responseData = await performApiRequest(\n commit,\n 'SET_ORDERS_LOADING',\n 'addLine',\n () => axios.post(`/v1/orders/${orderUuid}/line`, {line})\n );\n\n EventBus.$emit('add-order-line-success', responseData.order);\n commit('SET_ORDER', responseData.order);\n } catch (error) {\n }\n },\n\n async updateLine({commit}, {line, attributes}: { line: string, attributes: Record<string, any> }) {\n const responseData = await performApiRequest(\n commit,\n 'SET_ORDERS_LOADING',\n 'updateLine',\n () => axios.put(`/v1/line/${line}`, {attributes})\n );\n\n commit('SET_ORDER', responseData.order);\n EventBus.$emit('update-order-success', responseData.order);\n },\n\n updateLines({commit}, lines) {\n commit('SET_ORDERS_LOADING', {subject: 'updateLine', loading: true});\n\n axios.put('/v1/lines', {lines})\n .then(() => {\n EventBus.$emit('update-order-lines-success');\n }).catch(() => {\n }).finally(() => {\n commit('SET_ORDERS_LOADING', {subject: 'updateLine', loading: false});\n });\n },\n\n\n async removeLine({commit}, line: string) {\n try {\n await performApiRequest(\n commit,\n 'SET_ORDERS_LOADING',\n 'removeLine',\n () => axios.delete(`/v1/line/${line}`)\n );\n } catch (error) {\n }\n },\n\n /**\n * Get a line item model (ex. location model)\n */\n getOrderItemModel({commit}, data) {\n commit('SET_ORDERS_LOADING', {subject: 'itemModel', loading: true});\n\n axios.get(`/v1/line-item-model/${data.model}/${data.id}`)\n .then((response) => {\n EventBus.$emit('get-order-line-model-success', get(response, 'data.model'));\n }).catch(() => {\n }).finally(() => {\n commit('SET_ORDERS_LOADING', {subject: 'itemModel', loading: false});\n });\n },\n\n\n /**\n * Cancel an order\n *\n * @param commit\n * @param {String} orderUuid The orders UUID\n */\n cancelOrder({commit}, orderUuid: string) {\n commit('SET_ORDERS_LOADING', {subject: 'cancelOrder', loading: true});\n\n axios.post(`/v1/orders/${orderUuid}/cancel`)\n .then(() => {\n EventBus.$emit('cancel-order-success');\n }).catch((e) => {\n EventBus.$emit('cancel-order-failure', get(e, 'response.data.message', 'There was an error'));\n }).finally(() => {\n commit('SET_ORDERS_LOADING', {subject: 'cancelOrder', loading: false});\n });\n },\n};\n\nexport default {\n namespaced: true,\n state,\n mutations,\n actions,\n getters,\n};\n","import * as types from '@/store/mutation-types';\nimport {Form} from '@/plugins/FWForms/index';\nimport axios from 'axios';\nimport {EventBus} from '@/plugins/eventBus';\nimport {StorageService} from '@/services/storage.service';\nimport {performApiRequest} from '@/store/helpers/vuex-helpers';\nimport {Invoice, StripeSubscriptionObject} from '@/types/Stripe';\nimport {SubscriptionPlan} from '@/types';\nimport {push} from 'notivue';\n\nexport interface StripeState {\n loading: Record<string, boolean>,\n currentWorkingInvoice: any,\n currentWorkingPaymentIntent: any,\n billing_session_url: string | null,\n stripeIdentities: Array<string>,\n stripeForm: Form<any>,\n charge: any,\n account: any,\n invoices: Invoice[],\n stripeSubscriptionObject: StripeSubscriptionObject\n stripePrices: SubscriptionPlan[]\n}\n\nconst state: StripeState = {\n loading: {\n account: false,\n charge: false,\n fetchInvoice: false,\n fetchPortalUrl: false,\n updateDefaultPaymentMethod: false,\n createStripeVerification: false,\n bookingInitStripeVerification: false,\n cancelStripeVerification: false,\n refreshDocumentImageFiles: false,\n freshStripeVerification: false,\n fetchSetupUrl: false,\n invoices: false,\n },\n currentWorkingInvoice: {},\n currentWorkingPaymentIntent: {},\n billing_session_url: null,\n stripeIdentities: [],\n stripeForm: new Form(),\n charge: null,\n account: null,\n invoices: [],\n stripeSubscriptionObject: null,\n stripePrices: [\n {\n name: 'basic',\n pricing: {\n monthly: {\n id: 'sub_basic_monthly',\n price_id: 'sub_basic_monthly',\n price: 34,\n },\n yearly: {\n id: 'sub_basic_annual',\n price_id: 'sub_basic_annual',\n price: 24,\n },\n },\n description: {\n bullets: [\n 'Orders',\n 'Up to 5 vehicles',\n 'Includes 1 branch',\n '2 staff accounts',\n 'Unlimited Customers',\n '1 car-share connections',\n 'Online Store',\n 'Stripe Integration',\n 'And More*',\n ],\n },\n },\n {\n name: 'standard',\n pricing: {\n monthly: {\n id: 'sub_standard_monthly',\n price_id: 'sub_standard_monthly',\n price: 89,\n },\n yearly: {\n id: 'sub_standard_annual',\n price_id: 'sub_standard_annual',\n price: 69,\n },\n },\n description: {\n bullets: [\n 'All of Basic',\n 'Up to 50 vehicles',\n '5 staff accounts',\n 'Includes 2 branches',\n 'eSign Rental Agreements',\n 'Coupons',\n 'QR & Barcodes',\n 'Reports',\n 'Import/Export',\n 'Hide powered by Fleetwire',\n 'And More*',\n ],\n },\n },\n {\n name: 'premium',\n pricing: {\n monthly: {\n id: 'sub_premium_monthly',\n price_id: 'sub_premium_monthly',\n price: 279,\n },\n yearly: {\n id: 'sub_premium_annual',\n price_id: 'sub_premium_annual',\n price: 239,\n },\n },\n description: {\n bullets: [\n 'All of Standard',\n 'Up to 150 vehicles',\n '20 staff accounts',\n 'Includes 2 branches',\n 'Custom Domain',\n 'Custom Email Domain',\n 'Additional Scripts',\n '10 Car-share connections',\n 'Zapier integration',\n 'API',\n 'TFA (Two factor authentication)',\n 'And More*',\n ],\n },\n },\n ],\n};\n\nconst getters = {\n loading: (state: StripeState) => state.loading,\n currentWorkingInvoice: (state: StripeState) => state.currentWorkingInvoice,\n currentWorkingPaymentIntent: (state: StripeState) => state.currentWorkingPaymentIntent,\n billingSessionUrl: (state: StripeState) => state.billing_session_url,\n stripeIdentities: (state: StripeState) => state.stripeIdentities,\n stripeForm: (state: StripeState) => state.stripeForm,\n charge: (state: StripeState) => state.charge,\n account: (state: StripeState) => state.account,\n stripeSubscriptionObject: (state: StripeState) => state.stripeSubscriptionObject,\n invoices: (state: StripeState) => state.invoices,\n stripePrices: (state: StripeState) => state.stripePrices,\n};\n\nconst mutations = {\n [types.SET_STRIPE_LOADING](state: StripeState, loading: { subject: string, loading: boolean }) {\n state.loading[loading.subject] = loading.loading;\n },\n [types.SET_CURRENT_WORKING_INVOICE](state: StripeState, invoice) {\n state.currentWorkingInvoice = invoice;\n },\n [types.SET_CURRENT_WORKING_PAYMENT_INTENT](state: StripeState, intent) {\n state.currentWorkingPaymentIntent = intent;\n },\n [types.SET_BILLING_PORTAL_SESSION](state: StripeState, url: string) {\n state.billing_session_url = url;\n },\n [types.SET_STRIPE_PRICE_DATA](state: StripeState, prices: object) {\n // sub_basic_annual\n // :\n // \"price_1KfoLECZJTjTZE0Qs6poe7wG\"\n // sub_basic_monthly\n // :\n // \"price_1KfoLECZJTjTZE0QmWH5yynX\"\n // sub_premium_annual\n // :\n // \"sub_premium_annual\"\n // sub_premium_monthly\n // :\n // \"sub_premium_monthly\"\n // sub_standard_annual\n // :\n // \"sub_standard_annual\"\n // sub_standard_monthly\n // :\n // \"sub_standard_monthly\"\n // [[Prototype]]\n //\n\n console.dir(prices);\n console.dir(state.stripePrices);\n state.stripePrices.forEach((plan) => {\n plan.pricing.monthly.price_id = prices[plan.pricing.monthly.id];\n plan.pricing.yearly.price_id = prices[plan.pricing.yearly.id];\n });\n },\n [types.SET_STRIPE_IDENTITIES](state: StripeState, ids) {\n state.stripeIdentities = ids;\n },\n [types.SET_SUBSCRIPTION_DETAILS](state: StripeState, details) {\n state.stripeSubscriptionObject = details?.subscription || details;\n },\n [types.SET_STRIPE_ACCOUNT](state: StripeState, data) {\n state.account = data;\n },\n [types.SET_CURRENT_STRIPE_CHARGE](state: StripeState, charge) {\n state.charge = charge;\n },\n [types.SET_INVOICES](state: StripeState, invoices: Invoice[]) {\n state.invoices = invoices;\n },\n};\n\nconst actions = {\n async fetchInvoices({commit}) {\n try {\n const responseData = await performApiRequest(commit, 'SET_STRIPE_LOADING', 'invoices', () => axios.get('/v1/stripe/invoices'));\n commit('SET_INVOICES', responseData.invoices);\n } catch (error) {\n console.error(error)\n }\n },\n\n fetchInvoice({commit, rootGetters}, invoice_id) {\n commit('SET_STRIPE_LOADING', {subject: 'fetchInvoice', loading: true});\n axios.get(`/v1/company/${rootGetters['company/company'].uuid}/stripe/invoices/${invoice_id}`)\n .then((response) => {\n commit('SET_CURRENT_WORKING_INVOICE', response.data.invoice);\n }).catch(() => {\n push.error({\n message: 'Settings update error. Try again later.',\n });\n }).finally(() => {\n commit('SET_STRIPE_LOADING', {subject: 'fetchInvoice', loading: false});\n });\n },\n\n fetchCharge({commit}, charge_id: string) {\n commit('SET_STRIPE_LOADING', {subject: 'charge', loading: true});\n\n axios.get(`/v1/stripe/charge/${charge_id}`)\n .then((response) => {\n commit(types.SET_CURRENT_STRIPE_CHARGE, response.data.charge);\n }).catch(() => {\n push.error({\n message: 'Settings update error. Try again later.',\n });\n }).finally(() => {\n commit('SET_STRIPE_LOADING', {subject: 'charge', loading: false});\n });\n },\n\n async fetchStripeAccount({commit}) {\n try {\n const responseData = await performApiRequest(commit, 'SET_STRIPE_LOADING', 'account', () => axios.get('/v1/stripe/account'));\n commit(types.SET_STRIPE_ACCOUNT, responseData.account);\n } catch (error) {\n push.error({\n message: error?.response?.data?.message || 'Fetching Stripe Account error. Try again later.',\n });\n }\n },\n\n\n /**\n * Attach a new payment method to company\n */\n attachPaymentMethod({commit}, paymentMethod) {\n commit('SET_PAYMENTS_LOADING', {subject: 'addPaymentMethod', loading: true});\n\n axios.post('/v1/stripe/attach-payment-method', paymentMethod)\n .then(() => {\n EventBus.$emit('add-payment-method-success');\n }).catch(() => {\n }).finally(() => {\n commit('SET_PAYMENTS_LOADING', {subject: 'addPaymentMethod', loading: false});\n });\n },\n\n fetchPaymentIntent({commit}, intent_id: string) {\n commit('SET_STRIPE_LOADING', {subject: 'notifications', loading: true});\n axios.get(`/v1/stripe/payment-intent/${intent_id}`)\n .then((response) => {\n commit(types.SET_CURRENT_WORKING_PAYMENT_INTENT, response.data.intent);\n }).catch(() => {\n push.error({\n message: error?.response?.data?.message || 'Settings update error. Try again later.',\n });\n }).finally(() => {\n commit('SET_STRIPE_LOADING', {subject: 'notifications', loading: false});\n });\n },\n\n /**\n * Create a Stripe billing postal link and supply\n *\n * @param commit\n */\n fetchBillingPortalSession({commit}) {\n commit('SET_STRIPE_LOADING', {subject: 'fetchPortalUrl', loading: true});\n\n axios.get('/v1/stripe/billing-portal')\n .then((response) => {\n commit(types.SET_BILLING_PORTAL_SESSION, response.data.url);\n }).catch((error) => {\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n }).finally(() => {\n commit('SET_STRIPE_LOADING', {subject: 'fetchPortalUrl', loading: false});\n });\n },\n\n async fetchCheckoutUrl({commit}, data: { price: string }) {\n try {\n const responseData = await performApiRequest(commit, 'SET_STRIPE_LOADING', 'fetchPortalUrl', () => axios.post('/v1/stripe/checkout-url', data));\n\n commit(types.SET_BILLING_PORTAL_SESSION, responseData.url);\n\n return responseData.url;\n } catch (error) {\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n throw error;\n }\n },\n\n async fetchStripePriceData({commit}) {\n try {\n const responseData = await performApiRequest(commit, 'SET_STRIPE_LOADING', 'fetchPortalUrl', () => axios.get('/v1/stripe/prices'));\n\n commit(types.SET_STRIPE_PRICE_DATA, responseData.prices);\n\n return responseData.url;\n } catch (error) {\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n throw error;\n }\n },\n\n async fetchSetupUrl({commit}, data) {\n try {\n return await performApiRequest(commit, 'SET_STRIPE_LOADING', 'fetchSetupUrl', () => axios.post('/v1/stripe/setup-url', data));\n } catch (error) {\n console.error(error)\n }\n },\n\n async fetchSubscriptionDetails({commit}) {\n\n try {\n const responseData = await performApiRequest(commit, 'SET_STRIPE_LOADING', 'fetchSubscriptionDetails', () => axios.get('/v1/stripe/subscription-details'));\n commit('SET_SUBSCRIPTION_DETAILS', responseData);\n } catch (error) {\n console.error(error)\n }\n },\n\n /**\n * Update default payment method\n */\n updateDefaultPaymentMethod({commit}, payment_method) {\n commit('SET_STRIPE_LOADING', {subject: 'updateDefaultPaymentMethod', loading: true});\n\n axios.post('/v1/stripe/update-default-payment', {payment_method})\n .then((response) => {\n commit('payments/SET_PAYMENT_METHODS', response?.data?.payment_methods || [], {root: true});\n commit('company/SET_COMPANY', response.data.company, {root: true});\n }).catch(() => {\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n }).finally(() => {\n commit('SET_STRIPE_LOADING', {subject: 'updateDefaultPaymentMethod', loading: false});\n });\n },\n\n testStripeIdentity({commit, rootGetters}) {\n commit('SET_STRIPE_LOADING', {subject: 'updateDefaultPaymentMethod', loading: true});\n axios.post(`/v1/company/${rootGetters['company/company'].uuid}/stripe/test-identity`)\n .then((response) => {\n commit('payments/SET_PAYMENT_METHODS', response?.data?.payment_methods || [], {root: true});\n commit('company/SET_COMPANY', response.data.company, {root: true});\n }).catch(() => {\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n }).finally(() => {\n commit('SET_STRIPE_LOADING', {subject: 'updateDefaultPaymentMethod', loading: false});\n });\n },\n\n /**\n * Create a Stripe Identity Verification link and supply to customer\n */\n bookingInitStripeVerification({state, commit}, data) {\n commit('SET_STRIPE_LOADING', {subject: 'bookingInitStripeVerification', loading: true});\n axios.post(`/v1/bookings/${data.b_id}/stripe/identity/start`, data)\n .then((response) => {\n EventBus.$emit('stripe-create-verification-successful');\n commit('booking/SET_CUSTOMER_BOOKING', response.data.booking || [], {root: true});\n }).catch((error) => {\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n state.stripeForm.errors.set(error?.response?.data?.errors);\n }).finally(() => {\n commit('SET_STRIPE_LOADING', {subject: 'bookingInitStripeVerification', loading: false});\n });\n },\n\n\n /**\n * Create a Stripe Identity link and send\n */\n createStripeVerification({commit}, data) {\n commit('SET_STRIPE_LOADING', {subject: 'createStripeVerification', loading: true});\n axios.post('/v1/stripe/identity', data)\n .then((response) => {\n commit('SET_STRIPE_IDENTITIES', response.data.ids);\n EventBus.$emit('stripe-create-verification-successful', response.data.ids);\n }).catch((error) => {\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n }).finally(() => {\n commit('SET_STRIPE_LOADING', {subject: 'createStripeVerification', loading: false});\n });\n },\n\n /**\n * Create a Stripe Identity link and send\n *\n * @param commit\n * @param {String} vsId\n */\n cancelStripeVerification({commit}, vsId: string) {\n commit('SET_STRIPE_LOADING', {subject: 'cancelStripeVerification', loading: vsId});\n\n axios.delete(`/v1/stripe/identity/${vsId}`)\n .then((response) => {\n EventBus.$emit('stripe-cancel-verification-successful', response.data.identity);\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'Canceled',\n });\n }).catch((error) => {\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n }).finally(() => {\n commit('SET_STRIPE_LOADING', {subject: 'cancelStripeVerification', loading: false});\n });\n },\n\n fetchStripeVerification({commit}, vsId: string) {\n commit('SET_STRIPE_LOADING', {subject: 'freshStripeVerification', loading: true});\n\n axios.get(`/v1/stripe/identity/${vsId}/fresh`)\n .then((response) => {\n EventBus.$emit('stripe-fresh-verification-successful', response.data.session);\n }).catch((error) => {\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n }).finally(() => {\n commit('SET_STRIPE_LOADING', {subject: 'freshStripeVerification', loading: false});\n });\n },\n\n refreshDocumentImageFiles({commit}, vsId: string) {\n commit('SET_STRIPE_LOADING', {subject: 'refreshDocumentImageFiles', loading: true});\n\n axios.post(`/v1/stripe/identity/${vsId}/refresh-files`)\n .then((response) => {\n EventBus.$emit('stripe-refresh-files-successful', response.data.files);\n }).catch((e) => {\n EventBus.$emit('stripe-refresh-files-failure', e?.response?.data?.message || 'There was an error');\n }).finally(() => {\n commit('SET_STRIPE_LOADING', {subject: 'refreshDocumentImageFiles', loading: false});\n });\n },\n\n getStripeIdentities({commit}) {\n commit('SET_STRIPE_LOADING', {subject: 'updateDefaultPaymentMethod', loading: true});\n axios.get(`/v1/company/${StorageService.getCompanyUuid()}/stripe/identity`)\n .then((response) => {\n commit('SET_STRIPE_IDENTITIES', response.data.ids);\n }).catch((error) => {\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n }).finally(() => {\n commit('SET_STRIPE_LOADING', {subject: 'updateDefaultPaymentMethod', loading: false});\n });\n },\n\n async fetchStripeCapabilities({commit}) {\n const responseData = await performApiRequest(commit, 'SET_STRIPE_LOADING', 'updateDefaultPaymentMethod', () => axios.get('/v1/stripe/capabilities'));\n\n commit(types.SET_STRIPE_ACCOUNT, responseData);\n },\n};\n\nexport default {\n namespaced: true,\n state,\n mutations,\n actions,\n getters,\n};\n","import axios from 'axios';\nimport {EventBus} from '@/plugins/eventBus';\nimport * as types from '../mutation-types';\nimport {performApiRequest} from '@/store/helpers/vuex-helpers';\nimport {ESignerFieldData, ESignTool} from '@/types';\nimport {DocumentType, TemplateData} from '@/store/modules/document';\n\n\nexport interface TemplateInterface {\n data: null;\n documents: DocumentType;\n file_id: null;\n name: null;\n pages: number;\n version: 'v1' | 'v2';\n uuid?: string;\n updated_at?: string;\n created_at?: string;\n}\n\nexport interface TemplateState {\n init: boolean;\n loading: Record<string, boolean>,\n canvasActive: boolean;\n toolsActive: boolean;\n documents: DocumentType[];\n document: DocumentType;\n templates: TemplateData[];\n\n template?: TemplateInterface;\n\n rightSidebar: {\n open: boolean;\n mode: string;\n title: string;\n };\n currentWorkingTool: ESignTool;\n selectedField: any;\n selectedFieldV2: ESignerFieldData | null;\n selectedFieldIndex: number;\n\n existingTemplateData: any[];\n newTemplateData: any[];\n\n documentFieldData: any[];\n\n fieldProperties: {\n fontSize: number;\n fontColor: string;\n };\n allTools: ESignTool[];\n currentSigner: string;\n signerItems: any[];\n\n documentImages: any[];\n}\n\n\nconst state: TemplateState = {\n init: false,\n loading: {\n template: false,\n saving: false,\n },\n canvasActive: false,\n toolsActive: false,\n documents: [],\n document: null,\n templates: [],\n template: null,\n\n rightSidebar: {\n open: false,\n mode: 'tools',\n title: '',\n },\n currentWorkingTool: null,\n selectedField: {\n attributes: {\n bold: false,\n italic: false,\n required_field: false,\n strikethrough: false,\n underline: false,\n required: true,\n },\n },\n selectedFieldV2: null,\n selectedFieldIndex: null,\n\n existingTemplateData: [],\n newTemplateData: [],\n\n documentFieldData: [],\n\n fieldProperties: {\n fontSize: 12,\n fontColor: '#4169e1',\n },\n allTools: [\n {\n id: 'field-primary-free-text',\n name: 'Text',\n value: 'text',\n type: 'text',\n group: 'field',\n icon: 'mdi-format-text',\n category: 'Misc',\n primary: true,\n },\n {\n id: 'field-secondary-free-text',\n name: 'Text',\n value: 'text',\n type: 'text',\n group: 'field',\n icon: 'mdi-format-text',\n category: 'Misc',\n secondary: true,\n },\n {\n id: 'field-primary-checkbox',\n name: 'Checkbox',\n value: false,\n type: 'checkbox',\n group: 'field',\n icon: 'mdi-checkbox-marked-outline',\n description: 'Checkbox field for a signer to make a choice',\n category: 'Misc',\n w: 20,\n h: 20,\n resizable: false,\n fieldName: '',\n primary: true,\n },\n {\n id: 'field-secondary-checkbox',\n name: 'Checkbox',\n value: false,\n type: 'checkbox',\n group: 'field',\n icon: 'mdi-checkbox-marked-outline',\n description: 'Checkbox field for a signer to make a choice',\n category: 'Misc',\n w: 20,\n h: 20,\n resizable: false,\n fieldName: '',\n secondary: true,\n },\n {\n id: 'field-primary-full-name',\n name: 'Full Name',\n title: 'Name',\n value: 'full_name',\n type: 'field',\n resizable: true,\n icon: 'mdi-account-box-outline',\n category: 'Primary Customer',\n w: 100,\n h: 20,\n options: ['field-primary-full-name', 'field-primary-first-name', 'field-primary-last-name'],\n description: 'The full name of the primary driver',\n primary: true,\n },\n {\n id: 'field-primary-first-name',\n name: 'First Name',\n title: 'Name',\n value: 'full_name',\n type: 'field',\n resizable: true,\n icon: 'mdi-account-box',\n category: 'Primary Customer',\n w: 100,\n h: 20,\n description: 'The first name of the primary driver',\n options: ['field-primary-full-name', 'field-primary-first-name', 'field-primary-last-name'],\n primary: true,\n },\n {\n id: 'field-primary-last-name',\n name: 'Last Name',\n title: 'Name',\n value: 'full_name',\n type: 'field',\n resizable: true,\n icon: 'mdi-account-box',\n category: 'Primary Customer',\n w: 100,\n h: 20,\n description: 'The last name of the primary driver',\n options: ['field-primary-full-name', 'field-primary-first-name', 'field-primary-last-name'],\n primary: true,\n },\n {\n id: 'field-primary-email',\n name: 'Email',\n value: 'email',\n type: 'field',\n resizable: true,\n icon: 'mdi-email-outline',\n description: 'The email name of the primary driver',\n category: 'Primary Customer',\n primary: true,\n },\n {\n id: 'field-primary-cell',\n name: 'Cell Phone',\n value: 'cell',\n type: 'field',\n resizable: true,\n w: 110,\n icon: 'mdi-cellphone',\n description: 'The cell phone of the primary driver',\n category: 'Primary Customer',\n primary: true,\n },\n {\n id: 'field-primary-drivers-license',\n name: 'Drivers License #',\n value: 'dl_number',\n type: 'field',\n w: 160,\n h: 20,\n description: 'The drivers license number of the primary driver',\n category: 'Primary Customer',\n icon: 'mdi-smart-card-outline',\n primary: true,\n },\n {\n id: 'field-primary-drivers-license-state',\n name: 'Drivers License St',\n value: 'dl_state',\n type: 'field',\n w: 160,\n h: 20,\n description: 'The drivers license state of the primary driver',\n category: 'Primary Customer',\n icon: 'mdi-smart-card-outline',\n primary: true,\n },\n {\n id: 'field-primary-drivers-license-exp',\n name: 'Drivers License Exp',\n value: 'dl_exp',\n type: 'field',\n w: 160,\n h: 20,\n description: 'The drivers license expiration date of the primary driver',\n category: 'Primary Customer',\n icon: 'mdi-smart-card-outline',\n primary: true,\n },\n {\n id: 'field-primary-dob',\n name: 'DOB',\n value: 'dob',\n type: 'field',\n w: 160,\n h: 20,\n description: 'The date of birth of the primary driver',\n category: 'Primary Customer',\n icon: 'mdi-calendar-outline',\n primary: true,\n },\n {\n id: 'field-primary-signature',\n name: 'Sign',\n value: 'signature',\n type: 'signature',\n group: 'signature',\n resizable: false,\n icon: 'mdi-signature',\n category: 'Primary Customer',\n w: 50,\n h: 50,\n description: 'The signature of the primary driver',\n primary: true,\n },\n {\n id: 'field-date-signed',\n name: 'Date Signed',\n value: 'date_signed',\n type: 'field',\n resizable: true,\n icon: 'mdi-calendar-range',\n category: 'Primary Customer',\n readOnly: true,\n w: 110,\n h: 23,\n primary: true,\n },\n {\n id: 'field-attachment',\n name: 'Attach',\n value: 'attachment',\n type: 'attachment',\n disabled: false,\n resizable: false,\n icon: 'mdi-paperclip',\n category: 'Primary Customer',\n fontSize: 7,\n w: 50,\n h: 50,\n description: 'A attachment for the primary driver',\n primary: true,\n },\n\n\n {\n id: 'field-secondary-full-name',\n name: 'Full Name',\n title: 'Name',\n value: 'full_name',\n type: 'field',\n resizable: true,\n icon: 'mdi-account-box-outline',\n category: 'Secondary Customer',\n w: 100,\n h: 20,\n description: 'The full name of the secondary driver',\n options: ['field-secondary-full-name', 'field-secondary-first-name', 'field-secondary-last-name'],\n secondary: true,\n },\n\n {\n id: 'field-secondary-first-name',\n name: 'First Name',\n title: 'Name',\n value: 'full_name',\n type: 'field',\n resizable: true,\n icon: 'mdi-account-box',\n category: 'Secondary Customer',\n w: 100,\n h: 20,\n description: 'The first name of the secondary driver',\n options: ['field-secondary-full-name', 'field-secondary-first-name', 'field-secondary-last-name'],\n secondary: true,\n },\n {\n id: 'field-secondary-last-name',\n name: 'Last Name',\n title: 'Name',\n value: 'full_name',\n type: 'field',\n resizable: true,\n icon: 'mdi-account-box',\n category: 'Secondary Customer',\n w: 100,\n h: 20,\n description: 'The last name of the secondary driver',\n options: ['field-secondary-full-name', 'field-secondary-first-name', 'field-secondary-last-name'],\n secondary: true,\n },\n {\n id: 'field-secondary-email',\n name: 'Email',\n value: 'email',\n type: 'field',\n resizable: true,\n icon: 'mdi-email-outline',\n description: 'The email name of the secondary driver',\n category: 'Secondary Customer',\n secondary: true,\n },\n {\n id: 'field-secondary-cell',\n name: 'Cell Phone',\n value: 'cell',\n type: 'field',\n resizable: true,\n w: 110,\n icon: 'mdi-cellphone',\n description: 'The cell phone of the secondary driver',\n category: 'Secondary Customer',\n secondary: true,\n },\n {\n id: 'field-secondary-drivers-license',\n name: 'Drivers License #',\n value: 'dl_number',\n type: 'field',\n w: 160,\n h: 20,\n description: 'The drivers license number of the secondary driver',\n category: 'Secondary Customer',\n icon: 'mdi-smart-card-outline',\n secondary: true,\n },\n {\n id: 'field-secondary-drivers-license-state',\n name: 'Drivers License St',\n value: 'dl_state',\n type: 'field',\n w: 160,\n h: 20,\n description: 'The drivers license state of the secondary driver',\n category: 'Secondary Customer',\n icon: 'mdi-smart-card-outline',\n secondary: true,\n },\n {\n id: 'field-secondary-drivers-license-exp',\n name: 'Drivers License Exp',\n value: 'dl_exp',\n type: 'field',\n w: 160,\n h: 20,\n description: 'The drivers license expiration date of the secondary driver',\n category: 'Secondary Customer',\n icon: 'mdi-smart-card-outline',\n secondary: true,\n },\n {\n id: 'field-secondary-dob',\n name: 'DOB',\n value: 'dob',\n type: 'field',\n w: 50,\n h: 20,\n description: 'The date of birth of the secondary driver',\n category: 'Secondary Customer',\n bgColor: 'purple',\n icon: 'mdi-calendar-outline',\n secondary: true,\n },\n {\n id: 'field-secondary-signature',\n name: 'Sign',\n value: 'signature',\n type: 'signature',\n group: 'signature',\n resizable: false,\n icon: 'mdi-signature',\n category: 'Secondary Customer',\n w: 50,\n h: 50,\n description: 'The signature of the secondary driver',\n secondary: true,\n },\n {\n id: 'field-secondary-date-signed',\n name: 'Date Signed',\n value: 'date_signed',\n type: 'field',\n resizable: true,\n icon: 'mdi-calendar-range',\n category: 'Secondary Customer',\n readOnly: true,\n w: 110,\n h: 23,\n secondary: true,\n },\n {\n id: 'field-attachment',\n name: 'Attach',\n value: 'attachment',\n type: 'attachment',\n disabled: false,\n resizable: false,\n icon: 'mdi-paperclip',\n category: 'Secondary Customer',\n fontSize: 7,\n w: 50,\n h: 50,\n description: 'A attachment for the primary driver',\n secondary: true,\n },\n\n {\n id: 'field-vehicle-year-make-model',\n name: 'Year Make Model',\n value: 'vehicle_year_make_model',\n type: 'field',\n category: 'Vehicle',\n icon: 'mdi-car',\n readOnly: true,\n w: 160,\n h: 20,\n },\n {\n id: 'field-vehicle-year',\n name: 'Year',\n value: 'vehicle_year',\n type: 'field',\n category: 'Vehicle',\n readOnly: true,\n resizable: true,\n icon: 'mdi-car',\n },\n {\n id: 'field-vehicle-make',\n name: 'Make',\n value: 'vehicle_make',\n type: 'field',\n category: 'Vehicle',\n readOnly: true,\n resizable: true,\n icon: 'mdi-car',\n },\n {\n id: 'field-vehicle-model',\n name: 'Model',\n value: 'vehicle_model',\n type: 'field',\n category: 'Vehicle',\n readOnly: true,\n resizable: true,\n icon: 'mdi-car',\n },\n {\n id: 'field-vehicle-color',\n name: 'Color',\n value: 'vehicle_color',\n type: 'field',\n category: 'Vehicle',\n readOnly: true,\n resizable: true,\n icon: 'mdi-palette',\n },\n {\n id: 'field-vehicle-plate',\n name: 'Plate #',\n value: 'vehicle_plate',\n type: 'field',\n category: 'Vehicle',\n readOnly: true,\n resizable: true,\n icon: 'mdi-card-text-outline',\n },\n {\n id: 'field-vehicle-vin',\n name: 'Vin',\n value: 'vehicle_vin',\n type: 'field',\n category: 'Vehicle',\n readOnly: true,\n icon: 'mdi-card-text-outline',\n },\n {\n id: 'field-vehicle-current-odometer',\n name: 'Odometer',\n value: 'vehicle_odometer',\n type: 'field',\n category: 'Vehicle',\n readOnly: true,\n icon: 'mdi-card-text-outline',\n w: 90,\n h: 20,\n description: 'The current odometer reading of the vehicle at the time of signing. Note: This value will not update if the odometer is different at the time of pickup. Should probably only be used for agreements signed at the time of pickup.',\n },\n {\n id: 'field-vehicle-title',\n name: 'Listing title',\n value: 'vehicle_title',\n type: 'field',\n category: 'Vehicle',\n resizable: true,\n readOnly: true,\n icon: 'mdi-format-title',\n w: 160,\n h: 20,\n },\n {\n id: 'field-vehicle-unit-id',\n name: 'Unit Id',\n value: 'vehicle_unit_id',\n type: 'field',\n category: 'Vehicle',\n resizable: true,\n readOnly: true,\n icon: 'mdi-barcode',\n w: 160,\n h: 20,\n },\n {\n id: 'field-listing-mile-allowance-per-day',\n name: 'Mile Allowance',\n value: 'listing_mile_allowance',\n type: 'field',\n category: 'Listing',\n readOnly: true,\n icon: 'mdi-counter',\n w: 160,\n h: 20,\n },\n {\n id: 'field-listing-mile-overage',\n name: 'Mile Overage',\n value: 'listing_mile_overage',\n type: 'field',\n category: 'Listing',\n icon: 'mdi-cash',\n readOnly: true,\n w: 160,\n h: 20,\n },\n {\n id: 'field-listing-price',\n name: 'Listing Price',\n value: 'listing_price',\n type: 'field',\n category: 'Listing',\n readOnly: true,\n icon: 'mdi-cash',\n w: 160,\n h: 20,\n },\n {\n id: 'field-listing-id',\n name: 'Listing ID',\n value: 'listing_id',\n type: 'field',\n category: 'Listing',\n readOnly: true,\n icon: 'mdi-barcode',\n w: 160,\n h: 20,\n },\n\n {\n id: 'field-booking-id',\n name: 'Booking ID',\n value: 'booking_id',\n type: 'field',\n category: 'Booking',\n icon: 'mdi-numeric',\n readOnly: true,\n w: 115,\n h: 20,\n },\n {\n id: 'field-booking-end-datetime',\n name: 'End date/time',\n value: 'booking_end',\n type: 'field',\n category: 'Booking',\n icon: 'mdi-calendar-range',\n readOnly: true,\n w: 160,\n h: 20,\n },\n {\n id: 'field-booking-start-datetime',\n name: 'Start date/time',\n value: 'booking_start',\n type: 'field',\n category: 'Booking',\n readOnly: true,\n icon: 'mdi-calendar-range',\n w: 160,\n h: 20,\n },\n {\n id: 'field-booking-start-date',\n name: 'Start Date',\n value: 'booking_start_date',\n type: 'field',\n category: 'Booking',\n readOnly: true,\n icon: 'mdi-calendar-range',\n w: 160,\n h: 20,\n },\n {\n id: 'field-booking-end-date',\n name: 'End Date',\n value: 'booking_end_date',\n type: 'field',\n category: 'Booking',\n readOnly: true,\n icon: 'mdi-calendar-range',\n w: 160,\n h: 20,\n },\n {\n id: 'field-booking-start-time',\n name: 'Start Time',\n value: 'booking_start_time',\n type: 'field',\n category: 'Booking',\n readOnly: true,\n icon: 'mdi-calendar-clock',\n w: 160,\n h: 20,\n },\n {\n id: 'field-booking-end-time',\n name: 'End Time',\n value: 'booking_end_time',\n type: 'field',\n category: 'Booking',\n readOnly: true,\n icon: 'mdi-calendar-clock',\n w: 160,\n h: 20,\n },\n {\n id: 'field-booking-trip-total',\n name: 'Trip Price',\n value: 'booking_trip_total',\n type: 'field',\n category: 'Booking',\n readOnly: true,\n icon: 'mdi-cash',\n w: 160,\n h: 20,\n },\n {\n id: 'field-booking-total',\n name: 'Total Price',\n value: 'booking_total',\n type: 'field',\n category: 'Booking',\n readOnly: true,\n icon: 'mdi-cash',\n w: 160,\n h: 20,\n },\n\n {\n id: 'field-booking-taxes',\n name: 'Total Taxes',\n value: 'booking_taxes',\n type: 'field',\n category: 'Booking',\n readOnly: true,\n icon: 'mdi-cash',\n w: 160,\n h: 20,\n },\n {\n id: 'field-booking-discount',\n name: 'Total Discount',\n value: 'booking_discount',\n type: 'field',\n category: 'Booking',\n readOnly: true,\n icon: 'mdi-cash',\n w: 160,\n h: 20,\n },\n {\n id: 'field-booking-delivery',\n name: 'Total Delivery',\n value: 'booking_delivery_total',\n type: 'field',\n category: 'Booking',\n readOnly: true,\n icon: 'mdi-cash',\n w: 160,\n h: 20,\n },\n {\n id: 'field-booking-extras',\n name: 'Extras Total',\n value: 'booking_extras_total',\n type: 'field',\n category: 'Booking',\n readOnly: true,\n icon: 'mdi-cash',\n w: 160,\n h: 20,\n },\n {\n id: 'field-booking-deposit',\n name: 'Total Deposit',\n value: 'booking_deposit',\n type: 'field',\n category: 'Booking',\n readOnly: true,\n icon: 'mdi-cash-plus',\n w: 160,\n h: 20,\n },\n {\n id: 'field-booking-days',\n name: 'Total Days',\n value: 'booking_days',\n type: 'field',\n category: 'Booking',\n readOnly: true,\n icon: 'mdi-calendar-range',\n w: 105,\n h: 20,\n },\n {\n id: 'field-booking-mile-allowance',\n name: 'Trip Mile Allowance',\n value: 'booking_days',\n type: 'field',\n category: 'Booking',\n readOnly: true,\n icon: 'mdi-calendar-range',\n w: 105,\n h: 20,\n },\n {\n id: 'field-booking-mile-extra',\n name: 'Trip Distance Overage',\n description: 'Trip distance overage is a field for storing the cost for exceeding the distance allowance. The default is the listings distance allowance setting but can be overridden on a reservation level.',\n value: 'booking_days',\n type: 'field',\n category: 'Booking',\n readOnly: true,\n icon: 'mdi-calendar-range',\n w: 220,\n h: 20,\n },\n ],\n currentSigner: 'primary',\n signerItems: [\n {\n title: 'Primary',\n value: 'primary',\n color: '#5be8ff',\n },\n {\n title: 'Secondary',\n value: 'secondary',\n color: 'purple',\n },\n ],\n\n documentImages: [],\n};\n\nconst getters = {\n init: (state: TemplateState) => state.init,\n rightSidebar: (state: TemplateState) => state.rightSidebar,\n toolsActive: (state: TemplateState) => state.toolsActive,\n loading: (state: TemplateState) => state.loading,\n document: (state: TemplateState) => state.document,\n documents: (state: TemplateState) => state.documents,\n templates: (state: TemplateState) => state.templates,\n template: (state: TemplateState) => state.template,\n currentWorkingTool: (state: TemplateState) => state.currentWorkingTool,\n selectedField: (state: TemplateState) => state.selectedField,\n selectedFieldV2: (state: TemplateState) => state.selectedFieldV2,\n selectedFieldIndex: (state: TemplateState) => state.selectedFieldIndex,\n documentFieldData: (state: TemplateState) => state.documentFieldData,\n existingTemplateData: (state: TemplateState) => state.existingTemplateData,\n newTemplateData: (state: TemplateState) => state.newTemplateData,\n fieldProperties: (state: TemplateState) => state.fieldProperties,\n allTools: (state: TemplateState) => state.allTools,\n currentSigner: (state: TemplateState) => state.currentSigner,\n signerItems: (state: TemplateState) => state.signerItems,\n documentImages: (state: TemplateState) => state.documentImages,\n};\n\nconst mutations = {\n [types.SET_TEMPLATES_LOADING](state: TemplateState, loading: { subject: string; loading: boolean }) {\n state.loading[loading.subject] = loading.loading;\n },\n [types.SET_FIELD_CURRENT_SIGNER](state: TemplateState, signer: string) {\n state.currentSigner = signer;\n },\n [types.SET_TOOLS_ACTIVE](state: TemplateState, active: boolean) {\n state.toolsActive = active;\n },\n [types.SET_CANVAS_ACTIVE](state: TemplateState, active: boolean) {\n state.canvasActive = active;\n },\n [types.SET_RIGHT_SIDEBAR_OPEN](state: TemplateState, open: boolean) {\n state.rightSidebar.open = open;\n },\n [types.SET_RIGHT_SIDEBAR_MODE](state: TemplateState, mode: string) {\n state.rightSidebar.mode = mode;\n },\n [types.SET_RIGHT_SIDEBAR_TITLE](state: TemplateState, title: string) {\n state.rightSidebar.title = title;\n },\n [types.SET_CURRENT_WORKING_TOOL](state: TemplateState, tool: ESignTool) {\n state.currentWorkingTool = tool;\n },\n [types.SET_SELECTED_FIELD](state: TemplateState, field) {\n state.selectedField = field;\n },\n [types.SET_SELECTED_FIELD_V2](state: TemplateState, field: ESignerFieldData) {\n console.dir('SET_SELECTED_FIELD_V2');\n console.dir(field);\n state.selectedFieldV2 = field;\n },\n [types.REMOVE_FIELD](state: TemplateState, field: ESignerFieldData) {\n const documents = state.template?.documents;\n if (documents && documents.data) {\n documents.data = documents.data.filter((f: ESignerFieldData) => f.id !== field.id);\n }\n },\n [types.REMOVE_ALL_FIELDS](state: TemplateState) {\n const documents = state.template?.documents;\n if (documents && documents.data) {\n documents.data = [];\n }\n },\n [types.SET_SELECTED_FIELD_INDEX_V2](state: TemplateState, index: number) {\n state.selectedFieldIndex = index;\n },\n\n [types.UPDATE_DOCUMENT_TEMPLATE_DATA](state: TemplateState, payload: { data: ESignerFieldData, index: number }) {\n if (payload.data === null) {\n state.template.documents.data.splice(payload.index, 1); // Remove element safely\n } else {\n state.template.documents.data[payload.index] = payload.data;\n }\n },\n\n [types.ADD_TO_DOCUMENT_TEMPLATE_DATA](state: TemplateState, payload: ESignerFieldData) {\n state.template.documents.data.push(payload);\n },\n [types.SET_ONE_TEMPLATE](state: TemplateState, template: TemplateInterface) {\n if (template?.documents?.data === null) {\n template.documents.data = [];\n }\n\n state.template = template;\n\n },\n [types.SET_EXISTING_DATA](state: TemplateState, data) {\n state.existingTemplateData = data || [];\n },\n [types.SET_NEW_DATA](state: TemplateState, data) {\n state.newTemplateData = data;\n },\n [types.RESET_TEMPLATE_DATA](state: TemplateState) {\n state.newTemplateData = [];\n state.existingTemplateData = [];\n state.template = null;\n },\n [types.SET_DOCUMENT_IMAGES](state: TemplateState, data) {\n state.documentImages = data;\n },\n};\n\nconst actions = {\n async getTemplate({commit}, uuid: string) {\n try {\n const responseData = await performApiRequest(commit, 'SET_TEMPLATES_LOADING', 'template', () => axios.get(`/v1/templates/${uuid}`));\n EventBus.$emit('get-template-success', responseData.template);\n commit(types.SET_ONE_TEMPLATE, responseData.template);\n } catch (error) {\n }\n },\n\n deleteSelectedElements({state, commit}) {\n ['newTemplateData', 'existingTemplateData'].forEach(dataKey => {\n const index = state[dataKey].findIndex(d => d.fieldid === state.selectedField?.fieldid);\n if (index >= 0) {\n state[dataKey][index].styleParent = 'display:none;';\n state[dataKey].splice(index, 1);\n }\n });\n commit(types.SET_SELECTED_FIELD, {});\n commit(types.SET_RIGHT_SIDEBAR_OPEN, false);\n },\n\n deleteSelectedElementsV2({state, commit}) {\n console.dir('deleteSelectedElementsV2');\n console.dir(state.selectedFieldIndex);\n if (state.selectedFieldIndex >= 0) {\n state.template?.documents?.data.splice(state.selectedFieldIndex, 1);\n commit(types.SET_SELECTED_FIELD_V2, null);\n commit(types.SET_SELECTED_FIELD_INDEX_V2, null);\n }\n },\n};\n\nexport default {\n namespaced: true,\n state,\n mutations,\n actions,\n getters,\n};\n","import axios from 'axios';\nimport {findIndex, get} from 'lodash';\nimport {EventBus} from '@/plugins/eventBus';\nimport {Form} from '@/plugins/FWForms/index';\nimport {StorageService} from '@/services/storage.service';\nimport * as types from '../mutation-types';\nimport {performApiRequest} from '@/store/helpers/vuex-helpers';\nimport {Connection} from '@/types';\nimport {push} from 'notivue';\n\n\nexport interface TeslaConnection {\n active: boolean;\n connected: boolean;\n email: string;\n expires: string;\n loading: boolean;\n photo_url: string;\n session_cookie_valid: boolean;\n session_cookies_exist: boolean;\n vehicles: any[];\n uuid?: string;\n}\n\nexport interface TeslaState {\n init: boolean;\n loading: Record<string, boolean>;\n credentials: {\n email: string;\n password: string;\n };\n connections: TeslaConnection[];\n vehicles: any[];\n currentWorkingTeslaVehicle: any;\n currentWorkingTeslaVehicleDrivers: any[];\n vehicleInvitations: any[];\n chargingHistory: any[];\n chargingHistoryPaginate: any;\n chargingInvoices: any[];\n invoices: any[];\n invoices_meta: any;\n invoices_pdf: string;\n currentWorkingTeslaVehicleAppAccess: any[];\n currentWorkingTeslaVehicleState: any;\n currentWorkingTeslaVehicleData: any;\n currentWorkingTeslaVehicleAsleep: boolean;\n form: Form<object>;\n}\n\nconst state: TeslaState = {\n init: false,\n\n loading: {\n login: false,\n delete: false,\n toggle: false,\n refresh_invoice: false,\n invoices: false,\n invoicePDF: false,\n refreshVehicles: false,\n appAccess: false,\n vehicleState: false,\n vehicleData: false,\n wakeVehicle: false,\n chargingHistory: false,\n invitations: false,\n },\n\n credentials: {\n email: '',\n password: '',\n },\n\n connections: [],\n vehicles: [],\n currentWorkingTeslaVehicle: {},\n currentWorkingTeslaVehicleDrivers: [],\n vehicleInvitations: [],\n chargingHistory: [],\n chargingHistoryPaginate: null,\n chargingInvoices: [],\n invoices: [],\n invoices_meta: {},\n invoices_pdf: '',\n currentWorkingTeslaVehicleAppAccess: [],\n currentWorkingTeslaVehicleState: {},\n currentWorkingTeslaVehicleData: {},\n currentWorkingTeslaVehicleAsleep: false,\n form: new Form(),\n};\n\nconst getters = {\n loading: (state: TeslaState) => state.loading,\n credentials: (state: TeslaState) => state.credentials,\n connections: (state: TeslaState) => state.connections,\n vehicles: (state: TeslaState) => state.vehicles,\n currentWorkingTeslaVehicle: (state: TeslaState) => state.currentWorkingTeslaVehicle,\n currentWorkingTeslaVehicleDrivers: (state: TeslaState) => state.currentWorkingTeslaVehicleDrivers,\n vehicleInvitations: (state: TeslaState) => state.vehicleInvitations,\n chargingHistory: (state: TeslaState) => state.chargingHistory,\n chargingHistoryPaginate: (state: TeslaState) => state.chargingHistoryPaginate,\n currentWorkingTeslaVehicleAppAccess: (state: TeslaState) => state.currentWorkingTeslaVehicleAppAccess,\n currentWorkingTeslaVehicleState: (state: TeslaState) => state.currentWorkingTeslaVehicleState,\n currentWorkingTeslaVehicleData: (state: TeslaState) => state.currentWorkingTeslaVehicleData,\n currentWorkingTeslaVehicleAsleep: (state: TeslaState) => state.currentWorkingTeslaVehicleAsleep,\n chargingInvoices: (state: TeslaState) => state.chargingInvoices,\n invoices: (state: TeslaState) => state.invoices,\n invoicesMeta: (state: TeslaState) => state.invoices_meta,\n invoicesPDF: (state: TeslaState) => state.invoices_pdf,\n form: (state: TeslaState) => state.form,\n};\n\nconst mutations = {\n [types.SET_TESLA_INIT](state: TeslaState, init: boolean) {\n state.init = init;\n },\n [types.CLEAR_TESLA_FORM_ERRORS](state: TeslaState, form_field) {\n if (form_field === null || form_field === undefined) {\n state.form.errors.clear();\n } else {\n state.form.errors.clear(form_field);\n }\n },\n [types.SET_TESLA_LOADING](state: TeslaState, loading: { subject: string, loading: boolean }) {\n state.loading[loading.subject] = loading.loading;\n },\n [types.SET_TESLA_CREDENTIALS](state: TeslaState, init) {\n state.init = init;\n },\n [types.SET_TESLA_CONNECTIONS](state: TeslaState, connections) {\n state.connections = connections;\n },\n [types.UPDATE_TESLA_CONNECTION](state: TeslaState, tesla) {\n if (tesla) {\n const connIndex = findIndex(state.connections, (c) => tesla.uuid === c.uuid);\n if (connIndex >= 0) {\n state.connections[connIndex] = tesla;\n if (!get(tesla, 'active', false)) {\n state.connections[connIndex].connected = false;\n }\n } else {\n state.connections.push(tesla);\n }\n }\n },\n [types.SET_TESLA_VEHICLES](state: TeslaState, vehicles) {\n state.vehicles = vehicles;\n },\n [types.SET_CURRENT_WORKING_TESLA_VEHICLE](state: TeslaState, vehicle) {\n state.currentWorkingTeslaVehicle = vehicle;\n },\n [types.SET_CURRENT_WORKING_TESLA_VEHICLE_DRIVERS](state: TeslaState, drivers) {\n state.currentWorkingTeslaVehicleDrivers = drivers;\n },\n [types.SET_CURRENT_WORKING_TESLA_VEHICLE_HISTORY](state: TeslaState, chargingHistory) {\n state.chargingHistory = chargingHistory;\n },\n [types.SET_CURRENT_WORKING_TESLA_VEHICLE_HISTORY_PAGINATE](state: TeslaState, paginate) {\n state.chargingHistoryPaginate = paginate;\n },\n [types.SET_TESLA_VEHICLE_INVITATIONS](state: TeslaState, invites) {\n console.dir('SET_TESLA_VEHICLE_INVITATIONS');\n console.dir(invites);\n state.vehicleInvitations = invites;\n },\n [types.SET_TESLA_CHARGING_INVOICES](state: TeslaState, invoices) {\n if (invoices && invoices.length > 0) {\n state.chargingInvoices = invoices;\n }\n },\n [types.SET_TESLA_INVOICES](state: TeslaState, invoices) {\n state.invoices = invoices;\n },\n [types.SET_TESLA_INVOICES_META](state: TeslaState, meta) {\n state.invoices_meta = meta;\n },\n [types.SET_TESLA_INVOICE_PDF](state: TeslaState, pdf) {\n state.invoices_pdf = pdf;\n },\n [types.SET_CURRENT_WORKING_TESLA_ASLEEP](state: TeslaState, asleep) {\n state.currentWorkingTeslaVehicleAsleep = asleep;\n },\n [types.SET_CURRENT_WORKING_TESLA_VEHICLE_APP_ACCESS](state: TeslaState, emails) {\n state.currentWorkingTeslaVehicleAppAccess = emails;\n },\n [types.SET_CURRENT_WORKING_TESLA_VEHICLE_STATE](state: TeslaState, vehicleState) {\n state.currentWorkingTeslaVehicleState = vehicleState;\n },\n [types.SET_CURRENT_WORKING_TESLA_VEHICLE_DATA](state: TeslaState, vehicleData) {\n state.currentWorkingTeslaVehicleData = vehicleData;\n },\n};\n\nconst actions = {\n\n /**\n * Toggle active a Tesla account\n */\n toggleActive({commit}, tesla: TeslaConnection) {\n commit(types.SET_TESLA_LOADING, {subject: 'toggle', loading: true});\n\n axios.put(`/v1/connections/tesla/${tesla.uuid}/toggle`)\n .then((response) => {\n commit('UPDATE_TESLA_CONNECTION', get(response.data, 'tesla'));\n EventBus.$emit('tesla-toggle-success', get(response.data, 'tesla', []));\n }).catch(() => {\n }).finally(() => {\n commit(types.SET_TESLA_LOADING, {subject: 'toggle', loading: false});\n });\n },\n\n refreshToken({commit}, tesla: TeslaConnection) {\n commit(types.SET_TESLA_LOADING, {subject: 'toggle', loading: true});\n axios.post(`/v1/connections/tesla/${tesla.uuid}/refresh-token`)\n .then(() => {\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'Tesla token refreshed successful!',\n });\n EventBus.$emit('tesla-refresh-token-success');\n }).catch(() => {\n }).finally(() => {\n commit(types.SET_TESLA_LOADING, {subject: 'toggle', loading: false});\n });\n },\n\n deleteConnection({commit}, tesla: TeslaConnection) {\n commit(types.SET_TESLA_LOADING, {subject: 'delete', loading: true});\n axios.delete(`/v1/connections/tesla/${tesla.uuid}`)\n .then(() => {\n EventBus.$emit('delete-tesla-connection-success');\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'Tesla connection removed.',\n });\n }).catch(() => {\n }).finally(() => {\n commit(types.SET_TESLA_LOADING, {subject: 'delete', loading: false});\n });\n },\n\n fetchUserInfo({commit}, tesla: TeslaConnection) {\n commit(types.SET_TESLA_LOADING, {subject: 'delete', loading: true});\n axios.get(`/v1/connections/tesla/${tesla.uuid}/user-info`)\n .then(() => {\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'Tesla connection success.',\n });\n }).catch(() => {\n }).finally(() => {\n commit(types.SET_TESLA_LOADING, {subject: 'delete', loading: false});\n });\n },\n\n getVehicles({state, commit}, tesla: TeslaConnection) {\n commit(types.SET_TESLA_LOADING, {subject: 'login', loading: true});\n\n const connIndex = state.connections.findIndex((c: Connection) => tesla.uuid === c.uuid);\n state.connections[connIndex].loading = true;\n state.connections[connIndex].connected = false;\n\n axios.get(`/v1/connections/tesla/${tesla.uuid}/vehicles`)\n .then((response) => {\n commit('SET_TESLA_CONNECTIONS', get(response, 'data.vehicles'), []);\n state.connections[connIndex].connected = true;\n }).catch(() => {\n }).finally(() => {\n commit(types.SET_TESLA_LOADING, {subject: 'login', loading: false});\n state.connections[connIndex].loading = false;\n });\n },\n\n getVehicle({commit}, uuid: string) {\n commit(types.SET_TESLA_LOADING, {subject: 'login', loading: true});\n\n axios.get(`/v1/connections/tesla/vehicle/${uuid}`)\n .then((response) => {\n commit('SET_CURRENT_WORKING_TESLA_VEHICLE', get(response, 'data.vehicle'), []);\n }).catch(() => {\n }).finally(() => {\n commit(types.SET_TESLA_LOADING, {subject: 'login', loading: false});\n });\n },\n\n fetchVehicleDrivers({commit}, uuid: string) {\n commit(types.SET_TESLA_LOADING, {subject: 'login', loading: true});\n\n axios.get(`/v1/connections/tesla/vehicle/${uuid}/drivers`)\n .then((response) => {\n commit('SET_CURRENT_WORKING_TESLA_VEHICLE_DRIVERS', get(response, 'data.drivers'), []);\n }).catch(() => {\n }).finally(() => {\n commit(types.SET_TESLA_LOADING, {subject: 'login', loading: false});\n });\n },\n\n createVehicleInvitation({commit}, uuid: string) {\n commit(types.SET_TESLA_LOADING, {subject: 'login', loading: true});\n\n axios.post(`/v1/connections/tesla/vehicle/${uuid}/invitations`)\n .then((response) => {\n EventBus.$emit('create-tesla-vehicle-invitation-success', get(response, 'data.invitation'));\n }).catch(() => {\n }).finally(() => {\n commit(types.SET_TESLA_LOADING, {subject: 'login', loading: false});\n });\n },\n\n async fetchVehicleChargingHistory({commit}, data) {\n try {\n const responseData = await performApiRequest(commit, 'SET_TESLA_LOADING', 'chargingHistory', () => axios.get(`/v1/connections/tesla/vehicle/${data.tesla_uuid}/charging-history?page=${data.page}`));\n\n commit('SET_CURRENT_WORKING_TESLA_VEHICLE_HISTORY_PAGINATE', responseData.paginate, []);\n commit('SET_CURRENT_WORKING_TESLA_VEHICLE_HISTORY', responseData.data, []);\n } catch (error) {\n }\n },\n fetchTeslaInvoice({commit}, data) {\n commit(types.SET_TESLA_LOADING, {subject: 'login', loading: true});\n const ids = data.invoiceIds.join(',');\n\n axios.get(`/v1/connections/tesla/vehicle/${data.tesla_uuid}/charging-history-invoice?contentId=${ids}`)\n .then((response) => {\n EventBus.$emit('fetch-tesla-charging-invoice-success', response.data);\n }).catch(() => {\n }).finally(() => {\n commit(types.SET_TESLA_LOADING, {subject: 'login', loading: false});\n });\n },\n async fetchVehicleInvitations({commit}, uuid: string) {\n try {\n const responseData = await performApiRequest(commit, 'SET_TESLA_LOADING', 'invitations', () => axios.get(`/v1/connections/tesla/vehicle/${uuid}/invitations`));\n\n commit('SET_TESLA_VEHICLE_INVITATIONS', responseData.invitations, []);\n } catch (error) {\n }\n },\n\n /**\n * Cancel vehicle invitation\n *\n */\n async cancelVehicleInvitation({commit}, data: { tesla_uuid: string, invite_id: string }) {\n try {\n await performApiRequest(commit, 'SET_TESLA_LOADING', 'invitations', () => axios.delete(`/v1/connections/tesla/vehicle/${data.tesla_uuid}/invitations/${data.invite_id}`));\n } catch (error) {\n }\n },\n\n refreshVehicles({state, commit}, tesla: TeslaConnection) {\n commit(types.SET_TESLA_LOADING, {subject: 'refreshVehicles', loading: true});\n\n const connIndex = state.connections.findIndex((c: Connection) => tesla.uuid === c.uuid);\n state.connections[connIndex].loading = true;\n state.connections[connIndex].connected = false;\n\n axios.post(`/v1/connections/tesla/${tesla.uuid}/refresh-vehicles`)\n .then((response) => {\n commit('SET_TESLA_CONNECTIONS', get(response, 'data.vehicles'), []);\n state.connections[connIndex].connected = true;\n }).catch(() => {\n }).finally(() => {\n commit(types.SET_TESLA_LOADING, {subject: 'refreshVehicles', loading: false});\n state.connections[connIndex].loading = false;\n });\n },\n\n wakeVehicle({commit}, tesla: TeslaConnection) {\n commit(types.SET_TESLA_LOADING, {subject: 'wakeVehicle', loading: true});\n commit('SET_CURRENT_WORKING_TESLA_VEHICLE', tesla);\n\n axios.post(`/v1/connections/tesla/vehicles/${tesla.uuid}/wake`)\n .then((response) => {\n if (get(response, 'data.wake.state') === 'asleep') {\n EventBus.$emit('waking-tesla', get(response, 'data.wake'));\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'Tesla is waking. It may take a few seconds.',\n });\n } else {\n commit('SET_CURRENT_WORKING_TESLA_ASLEEP', false);\n EventBus.$emit('woke-tesla', tesla);\n }\n }).catch((e) => {\n push.error({\n message: e?.response?.data?.message || 'There was an error',\n });\n }).finally(() => {\n commit(types.SET_TESLA_LOADING, {subject: 'wakeVehicle', loading: false});\n });\n },\n\n getVehicleState({commit}, tesla: TeslaConnection) {\n commit(types.SET_TESLA_LOADING, {subject: 'vehicleState', loading: true});\n axios.get(`/v1/connections/tesla/vehicles/${tesla.uuid}/state`)\n .then((response) => {\n commit('SET_CURRENT_WORKING_TESLA_VEHICLE_STATE', get(response, 'data.state'), []);\n }).catch((e) => {\n push.error({\n message: e?.response?.data?.message || 'There was an error',\n });\n }).finally(() => {\n commit(types.SET_TESLA_LOADING, {subject: 'vehicleState', loading: false});\n });\n },\n\n getVehicleData({commit}, tesla: TeslaConnection) {\n commit(types.SET_TESLA_LOADING, {subject: 'vehicleData', loading: true});\n\n axios.get(`/v1/connections/tesla/vehicles/${tesla.uuid}/data`)\n .then((response) => {\n EventBus.$emit('get-tesla-vehicle-data-success', get(response, 'data.data'));\n commit('SET_CURRENT_WORKING_TESLA_ASLEEP', false);\n commit('SET_CURRENT_WORKING_TESLA_VEHICLE_DATA', get(response, 'data.data'), []);\n }).catch((e) => {\n console.dir(e);\n if (e.response.status === 406) {\n EventBus.$emit('get-tesla-vehicle-data-asleep', tesla);\n commit('SET_CURRENT_WORKING_TESLA_ASLEEP', true);\n }\n push.error({\n message: e?.response?.data?.message || 'There was an error',\n });\n }).finally(() => {\n commit(types.SET_TESLA_LOADING, {subject: 'vehicleData', loading: false});\n });\n },\n\n checkInvoices({commit}, tesla: TeslaConnection) {\n commit(types.SET_TESLA_LOADING, {subject: 'refresh_invoice', loading: true});\n\n axios.post(`/v1/company/${StorageService.getCompanyUuid()}/connections/tesla/${tesla.uuid}/payment-history`)\n .then((response) => {\n commit('SET_TESLA_INVOICES', get(response, 'data.invoices'));\n commit('SET_TESLA_INVOICES_META', get(response, 'data.invoices_meta'));\n }).catch((e) => {\n console.dir(e);\n push.error({\n message: e?.response?.data?.message || 'There was an error',\n });\n }).finally(() => {\n commit(types.SET_TESLA_LOADING, {subject: 'refresh_invoice', loading: false});\n });\n },\n\n chargingHistory({commit}, tesla: TeslaConnection) {\n commit(types.SET_TESLA_LOADING, {subject: 'refresh_invoice', loading: true});\n\n axios.post(`/v1/connections/tesla/${tesla.uuid}/charging-history`)\n .then(() => {\n }).catch((e) => {\n console.dir(e);\n push.error({\n message: e?.response?.data?.message || 'There was an error',\n });\n }).finally(() => {\n commit(types.SET_TESLA_LOADING, {subject: 'refresh_invoice', loading: false});\n });\n },\n\n getRnIds({commit}, tesla: TeslaConnection) {\n commit(types.SET_TESLA_LOADING, {subject: 'refresh_invoice', loading: true});\n\n axios.get(`/v1/company/${StorageService.getCompanyUuid()}/connections/tesla/${tesla.uuid}/rd-ids`)\n .then(() => {\n }).catch((e) => {\n console.dir(e);\n push.error({\n message: e?.response?.data?.message || 'There was an error',\n });\n }).finally(() => {\n commit(types.SET_TESLA_LOADING, {subject: 'refresh_invoice', loading: false});\n });\n },\n\n\n getChargingInvoiceHistory({commit}, tesla: TeslaConnection) {\n commit(types.SET_TESLA_LOADING, {subject: 'invoices', loading: true});\n\n axios.get(`/v1/connections/tesla/${tesla.uuid}/charging-invoice-history`)\n .then((response) => {\n commit('SET_TESLA_CHARGING_INVOICES', get(response, 'data.charging'));\n }).catch((e) => {\n push.error({\n message: e?.response?.data?.message || 'There was an error',\n });\n }).finally(() => {\n commit(types.SET_TESLA_LOADING, {subject: 'invoices', loading: false});\n });\n },\n\n getInvoices({commit}, tesla: TeslaConnection) {\n commit(types.SET_TESLA_LOADING, {subject: 'invoices', loading: true});\n\n axios.get(`/v1/company/${StorageService.getCompanyUuid()}/connections/tesla/${tesla.uuid}/payment-history`)\n .then((response) => {\n commit('SET_TESLA_INVOICES', get(response, 'data.invoices'));\n commit('SET_TESLA_INVOICES_META', get(response, 'data.invoices_meta'));\n }).catch((e) => {\n push.error({\n message: e?.response?.data?.message || 'There was an error',\n });\n }).finally(() => {\n commit(types.SET_TESLA_LOADING, {subject: 'invoices', loading: false});\n });\n },\n\n\n /**\n * Get invoice pdfs\n */\n getInvoicePDF({commit}, tesla) {\n commit(types.SET_TESLA_LOADING, {subject: 'invoicePDF', loading: true});\n axios.get(`/v1/company/${StorageService.getCompanyUuid()}/connections/tesla/${tesla.tesla_uuid}/payment-history/${tesla.chargeSessionId}/invoice-pdf`)\n .then((response) => {\n commit('SET_TESLA_INVOICE_PDF', get(response, 'data.pdf'));\n }).catch((e) => {\n push.error({\n message: e?.response?.data?.message || 'There was an error',\n });\n }).finally(() => {\n commit(types.SET_TESLA_LOADING, {subject: 'invoicePDF', loading: false});\n });\n },\n\n importTeslaVehiclesAsListings({commit}, {vehicle_uuids, tesla_uuid}) {\n commit(types.SET_TESLA_LOADING, {subject: 'invoicePDF', loading: true});\n\n axios.post(`/v1/company/${StorageService.getCompanyUuid()}/connections/tesla/${tesla_uuid}/import`, {vehicle_uuids})\n .then((response) => {\n commit('listing/SET_ALL_LISTINGS', get(response, 'data.listings'), {root: true});\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'Tesla imported as listing successfully',\n });\n EventBus.$emit('import-tesla-vehicles-Success');\n }).catch((e) => {\n push.error({\n message: e?.response?.data?.message || 'There was an error',\n });\n }).finally(() => {\n commit(types.SET_TESLA_LOADING, {subject: 'invoicePDF', loading: false});\n });\n },\n\n};\n\n\nexport default {\n namespaced: true,\n state,\n mutations,\n actions,\n getters,\n};\n","import axios from 'axios';\nimport {Form} from '@/plugins/FWForms/index';\nimport {EventBus} from '@/plugins/eventBus';\nimport {get} from 'lodash';\nimport * as types from '../mutation-types';\n\nexport interface TollState {\n init: boolean;\n loading: Record<string, boolean>;\n tollForm: Form<any>;\n tollAgencies: any[];\n tollAccounts: any[];\n wishlist: any[];\n transactions: any[];\n transponders: any[];\n}\n\nconst state: TollState = {\n init: false,\n loading: {\n connect_account: false,\n get_tolls: false,\n toggle_tolls: false,\n add_wishlist: false,\n attach_booking: false,\n attach_vehicle: false,\n detach_booking: false,\n detach_vehicle: false,\n delete_account: false,\n transaction_dismissing: false,\n manual_fetch_transactions: false,\n fetch_transponders: false,\n },\n tollForm: new Form(),\n tollAgencies: [],\n tollAccounts: [],\n wishlist: [],\n transactions: [],\n transponders: [],\n};\n\nconst getters = {\n init: state => state.init,\n loading: state => state.loading,\n tollAgencies: state => state.tollAgencies,\n tollAccounts: state => state.tollAccounts,\n tollForm: state => state.tollForm,\n wishlist: state => state.wishlist,\n transactions: state => state.transactions,\n transponders: state => state.transponders,\n};\n\nconst mutations = {\n [types.SET_TOLLS_LOADING](state, loading) {\n state.loading[loading.subject] = loading.loading;\n },\n [types.SET_TOLL_AGENCIES](state, tolls) {\n state.tollAgencies = tolls;\n },\n [types.SET_TOLL_ACCOUNTS](state, tolls) {\n state.tollAccounts = tolls;\n },\n [types.SET_TOLL_AGENCIES_WISHLIST](state, tolls) {\n state.wishlist = tolls;\n },\n [types.SET_TOLL_TRANSACTIONS](state, transactions) {\n state.transactions = transactions;\n },\n [types.SET_TOLL_TRANSPONDERS](state, transponders) {\n state.transponders = transponders;\n },\n};\n\nconst actions = {\n getTollAgencies({commit}) {\n commit('SET_TOLLS_LOADING', {subject: 'get_tolls', loading: true});\n state.tollForm.errors.clear();\n\n axios.get('/v1/toll-agencies')\n .then((response) => {\n commit('SET_TOLL_AGENCIES', get(response, 'data.tollAgencies', []));\n }).catch((e) => {\n state.tollForm.errors.set(get(e, 'response.data.errors', []));\n }).finally(() => {\n commit('SET_TOLLS_LOADING', {subject: 'get_tolls', loading: false});\n });\n },\n\n getTollAgenciesWishlist({commit}) {\n commit('SET_TOLLS_LOADING', {subject: 'get_tolls', loading: true});\n\n axios.get('/v1/toll-agencies/wishlist')\n .then((response) => {\n commit('SET_TOLL_AGENCIES_WISHLIST', get(response, 'data.wishlist', []));\n }).catch(() => {\n }).finally(() => {\n commit('SET_TOLLS_LOADING', {subject: 'get_tolls', loading: false});\n });\n },\n\n connectTollAgency({commit, rootGetters}, data) {\n commit('SET_TOLLS_LOADING', {subject: 'connect_account', loading: true});\n\n axios.post('/v1/toll-accounts', data)\n .then((response) => {\n commit('SET_TOLL_ACCOUNTS', get(response, 'data.tollAccounts', []));\n EventBus.$emit('connect-toll-account-success');\n }).catch((e) => {\n state.tollForm.errors.set(get(e, 'response.data.errors'));\n }).finally(() => {\n commit('SET_TOLLS_LOADING', {subject: 'connect_account', loading: false});\n });\n },\n\n getTollAccounts({commit}) {\n commit('SET_TOLLS_LOADING', {subject: 'get_tolls', loading: true});\n\n axios.get('/v1/toll-accounts')\n .then((response) => {\n commit('SET_TOLL_ACCOUNTS', get(response, 'data.tollAccounts', []));\n }).catch(() => {\n }).finally(() => {\n commit('SET_TOLLS_LOADING', {subject: 'get_tolls', loading: false});\n });\n },\n\n toggleTollAccountActive({commit, rootGetters}, tollAccount) {\n commit('SET_TOLLS_LOADING', {subject: 'toggle_tolls', loading: true});\n\n axios.put(`/v1/toll-accounts/${tollAccount.uuid}/toggle-active`)\n .then((response) => {\n commit('SET_TOLL_ACCOUNTS', get(response, 'data.tollAccounts', []));\n EventBus.$emit('update-toll-account-success');\n }).catch(() => {\n }).finally(() => {\n commit('SET_TOLLS_LOADING', {subject: 'toggle_tolls', loading: false});\n });\n },\n\n deleteTollAccount({commit, rootGetters}, tollAccount) {\n commit('SET_TOLLS_LOADING', {subject: 'delete_account', loading: true});\n\n axios.delete(`/v1/toll-accounts/${tollAccount.uuid}`)\n .then((response) => {\n commit('SET_TOLL_ACCOUNTS', get(response, 'data.tollAccounts', []));\n EventBus.$emit('delete-toll-account-success');\n }).catch(() => {\n }).finally(() => {\n commit('SET_TOLLS_LOADING', {subject: 'delete_account', loading: false});\n });\n },\n\n testTollAccount({commit, rootGetters}, tollAccount) {\n commit('SET_TOLLS_LOADING', {subject: 'get_tolls', loading: true});\n\n axios.post(`/v1/toll-accounts/${tollAccount.uuid}/test`)\n .then(() => {\n }).catch(() => {\n }).finally(() => {\n commit('SET_TOLLS_LOADING', {subject: 'get_tolls', loading: false});\n });\n },\n\n updateAccount({commit, rootGetters}, tollAccount) {\n commit('SET_TOLLS_LOADING', {subject: 'get_tolls', loading: true});\n\n axios.put(`/v1/toll-accounts/${tollAccount.uuid}`, tollAccount)\n .then(() => {\n EventBus.$emit('update-toll-account-success');\n }).catch(() => {\n }).finally(() => {\n commit('SET_TOLLS_LOADING', {subject: 'get_tolls', loading: false});\n });\n },\n\n fetchTransactions({commit, rootGetters}, tollAccount) {\n commit('SET_TOLLS_LOADING', {subject: 'get_tolls', loading: true});\n\n axios.get(`/v1/toll-accounts/${tollAccount.uuid}/transactions`)\n .then(() => {\n }).catch(() => {\n }).finally(() => {\n commit('SET_TOLLS_LOADING', {subject: 'get_tolls', loading: false});\n });\n },\n\n manualFetchAllTransactions({commit}) {\n commit('SET_TOLLS_LOADING', {subject: 'manual_fetch_transactions', loading: true});\n\n axios.get('/v1/toll-accounts/transactions/manual-fetch')\n .then((response) => {\n commit('SET_TOLL_TRANSACTIONS', get(response, 'data.transactions', []));\n EventBus.$emit('manual-toll-transaction-fetch-success');\n }).catch(() => {\n }).finally(() => {\n commit('SET_TOLLS_LOADING', {subject: 'manual_fetch_transactions', loading: false});\n });\n },\n\n fetchVehicles({commit, rootGetters}, tollAccount) {\n commit('SET_TOLLS_LOADING', {subject: 'get_tolls', loading: true});\n\n axios.get(`/v1/toll-accounts/${tollAccount.uuid}/vehicles`)\n .then(() => {\n }).catch(() => {\n }).finally(() => {\n commit('SET_TOLLS_LOADING', {subject: 'get_tolls', loading: false});\n });\n },\n\n fetchTransponders({commit, rootGetters}, tollAccount) {\n commit('SET_TOLLS_LOADING', {subject: 'fetch_transponders', loading: true});\n\n axios.get(`/v1/toll-accounts/${tollAccount.uuid}/transponders`)\n .then((response) => {\n commit('SET_TOLL_TRANSPONDERS', get(response, 'data.transponders', []));\n }).catch(() => {\n }).finally(() => {\n commit('SET_TOLLS_LOADING', {subject: 'fetch_transponders', loading: false});\n });\n },\n\n saveTransponders({commit, rootGetters}, transponders) {\n commit('SET_TOLLS_LOADING', {subject: 'get_tolls', loading: true});\n\n axios.put('/v1/toll-accounts/transponders', transponders)\n .then((response) => {\n commit('SET_TOLL_TRANSPONDERS', get(response, 'data.transponders', []));\n }).catch(() => {\n }).finally(() => {\n commit('SET_TOLLS_LOADING', {subject: 'get_tolls', loading: false});\n });\n },\n\n getTransactions({commit}) {\n commit('SET_TOLLS_LOADING', {subject: 'get_tolls', loading: true});\n\n axios.get('/v1/toll-accounts/transactions')\n .then((response) => {\n commit('SET_TOLL_TRANSACTIONS', get(response, 'data.transactions', []));\n }).catch(() => {\n }).finally(() => {\n commit('SET_TOLLS_LOADING', {subject: 'get_tolls', loading: false});\n });\n },\n\n removeTransactionsMatchedBooking({commit, rootGetters}, transaction) {\n commit('SET_TOLLS_LOADING', {subject: 'detach_booking', loading: true});\n\n axios.delete(`/v1/toll-transactions/${transaction.uuid}/matched-booking`)\n .then((response) => {\n commit('SET_TOLL_TRANSACTIONS', get(response, 'data.transactions', []));\n EventBus.$emit('unmatched-toll-transaction-booking-success', get(response, 'data.transaction', []));\n }).catch(() => {\n }).finally(() => {\n commit('SET_TOLLS_LOADING', {subject: 'detach_booking', loading: false});\n });\n },\n\n removeTransactionsMatchedVehicle({commit, rootGetters}, transaction) {\n commit('SET_TOLLS_LOADING', {subject: 'detach_vehicle', loading: true});\n\n axios.delete(`/v1/toll-transactions/${transaction.uuid}/matched-vehicle`)\n .then((response) => {\n commit('SET_TOLL_TRANSACTIONS', get(response, 'data.transactions', []));\n EventBus.$emit('unmatched-toll-transaction-vehicle-success', get(response, 'data.transaction'));\n }).catch(() => {\n }).finally(() => {\n commit('SET_TOLLS_LOADING', {subject: 'detach_vehicle', loading: false});\n });\n },\n\n dismissTransaction({commit, rootGetters}, transaction) {\n commit('SET_TOLLS_LOADING', {subject: 'transaction_dismissing', loading: true});\n\n axios.put(`/v1/toll-transactions/${transaction.uuid}/dismiss`)\n .then((response) => {\n commit('SET_TOLL_TRANSACTIONS', get(response, 'data.transactions', []));\n EventBus.$emit('dismissed-toll-transaction-success', get(response, 'data.transaction'));\n }).catch(() => {\n }).finally(() => {\n commit('SET_TOLLS_LOADING', {subject: 'transaction_dismissing', loading: false});\n });\n },\n\n attachTransactionsMatchedBooking({commit, rootGetters}, data) {\n commit('SET_TOLLS_LOADING', {subject: 'attach_booking', loading: true});\n console.dir(data);\n axios.put(`/v1/toll-transactions/${data.transaction.uuid}/matched-booking`, {b_id: data.b_id})\n .then((response) => {\n commit('SET_TOLL_TRANSACTIONS', get(response, 'data.transactions', []));\n EventBus.$emit('attach-toll-transaction-booking-success', get(response, 'data.transaction', []));\n }).catch(() => {\n }).finally(() => {\n commit('SET_TOLLS_LOADING', {subject: 'attach_booking', loading: false});\n });\n },\n\n attachTransactionsMatchedVehicle({commit, rootGetters}, data) {\n commit('SET_TOLLS_LOADING', {subject: 'attach_vehicle', loading: true});\n console.dir(data);\n axios.put(`/v1/toll-transactions/${data.transaction.uuid}/matched-vehicle`, {l_id: data.l_id})\n .then((response) => {\n commit('SET_TOLL_TRANSACTIONS', get(response, 'data.transactions', []));\n EventBus.$emit('attach-toll-transaction-vehicle-success', get(response, 'data.transaction'));\n }).catch(() => {\n }).finally(() => {\n commit('SET_TOLLS_LOADING', {subject: 'attach_vehicle', loading: false});\n });\n },\n\n submitTollWishlist({commit, rootGetters}, data) {\n commit('SET_TOLLS_LOADING', {subject: 'add_wishlist', loading: true});\n\n axios.post('/v1/toll-agencies/wishlist', data)\n .then((response) => {\n commit('SET_TOLL_AGENCIES_WISHLIST', get(response, 'data.wishlist', []));\n EventBus.$emit('toll-wishlist-added-success');\n }).catch((e) => {\n state.tollForm.errors.set(get(e, 'response.data.errors'));\n if (get(e, 'response.data.code') === 'already_supported') {\n EventBus.$emit('toll-wishlist-already-supported', get(e, 'response.data.tollAgency'));\n }\n }).finally(() => {\n commit('SET_TOLLS_LOADING', {subject: 'add_wishlist', loading: false});\n });\n },\n};\n\nexport default {\n namespaced: true,\n state,\n mutations,\n actions,\n getters,\n};\n","import axios from 'axios';\nimport * as types from '../mutation-types';\nimport {TripExtra} from '@/types';\nimport {RootState} from '@/types/RootState';\nimport {performApiRequest} from '@/store/helpers/vuex-helpers';\nimport {Module} from 'vuex';\nimport {push} from 'notivue'\n\nexport interface RegularExtraData {\n extra?: TripExtra;\n mode: 'add' | 'edit';\n code?: 'secondary_driver' | 'young_driver';\n type?: 'convenience';\n}\n\nexport interface TripExtrasState {\n loading: Record<string, boolean>,\n extras: TripExtra[],\n tripExtraSettingDialog: boolean,\n regularExtraDialog: boolean,\n regularExtraData: RegularExtraData | null,\n requiredExtraAddEditDialog: boolean,\n requiredExtraAddEditData: TripExtra | null,\n extraListingsDialog: boolean,\n}\n\nconst state: TripExtrasState = {\n loading: {\n extras: false,\n extra_delete: false,\n extra_update: false,\n },\n extras: [] as TripExtra[],\n tripExtraSettingDialog: false,\n requiredExtraAddEditDialog: false,\n regularExtraDialog: false,\n requiredExtraAddEditData: null,\n regularExtraData: null,\n extraListingsDialog: false,\n};\n\n\nconst tripExtrasModule: Module<TripExtrasState, RootState> = {\n namespaced: true,\n\n state,\n\n getters: {\n loading: (state: TripExtrasState) => state.loading,\n extras: (state: TripExtrasState) => state.extras,\n tripExtraSettingDialog: (state: TripExtrasState) => state.tripExtraSettingDialog,\n requiredExtraAddEditDialog: (state: TripExtrasState) => state.requiredExtraAddEditDialog,\n regularExtraDialog: (state: TripExtrasState) => state.regularExtraDialog,\n requiredExtraAddEditData: (state: TripExtrasState) => state.requiredExtraAddEditData,\n regularExtraData: (state: TripExtrasState) => state.regularExtraData,\n extraListingsDialog: (state: TripExtrasState) => state.extraListingsDialog,\n },\n\n mutations: {\n [types.SET_EXTRAS_LOADING](state: TripExtrasState, loading) {\n state.loading[loading.subject] = loading.loading;\n },\n [types.SET_EXTRAS](state: TripExtrasState, extras) {\n state.extras = extras;\n },\n [types.SET_TRIP_EXTRA_SETTING_DIALOG](state: TripExtrasState, value) {\n state.tripExtraSettingDialog = value;\n },\n [types.SET_REQUIRED_EXTRA_ADD_EDIT_DIALOG](state: TripExtrasState, value) {\n state.requiredExtraAddEditDialog = value;\n },\n [types.SET_REQUIRED_EXTRA_ADD_EDIT_DATA](state: TripExtrasState, payload) {\n state.requiredExtraAddEditData = payload;\n },\n [types.SET_REGULAR_EXTRA_DATA](state: TripExtrasState, payload: RegularExtraData | null) {\n state.regularExtraData = payload;\n },\n [types.SET_REGULAR_EXTRA_DIALOG](state, value) {\n state.regularExtraDialog = value;\n },\n [types.SET_EXTRA_LISTINGS_DIALOG](state, value) {\n state.extraListingsDialog = value;\n },\n },\n\n actions: {\n\n async getExtras({commit}) {\n const data = await performApiRequest(commit, 'SET_EXTRAS_LOADING', 'extras', () => axios.get('/v1/trip-extras?with=listings'));\n if (data) commit('SET_EXTRAS', data.extras);\n },\n\n async createExtras({commit}, data) {\n try {\n await performApiRequest(commit, 'SET_EXTRAS_LOADING', 'extras', () => axios.post('/v1/trip-extras', data));\n push.success({\n message: 'Trip Extra created successfully!',\n });\n } catch (error) {\n push.error({\n message: 'Failed to create Trip Extra',\n });\n }\n },\n\n async deleteExtra({commit}, extra: TripExtra) {\n try {\n await performApiRequest(commit, 'SET_EXTRAS_LOADING', 'extra_delete', () => axios.delete(`/v1/trip-extras/${extra.uuid}`));\n push.success({\n message: 'Trip Extra deleted successfully!',\n });\n } catch (error) {\n push.error({\n message: 'Failed to delete Trip Extra',\n });\n }\n },\n\n async deleteOldVersionExtras({commit}) {\n await performApiRequest(commit, 'SET_EXTRAS_LOADING', 'extras', () => axios.delete('/v1/trip-extras/old-version'));\n push.success({\n message: 'Old Extras deleted successfully!',\n });\n },\n\n async deleteFromListings({commit}, data: { extraUuid: string, listings: string[] }) {\n await performApiRequest(commit, 'SET_EXTRAS_LOADING', 'extra_delete', () => axios.post(`/v1/trip-extras/${data.extraUuid}/remove-listings`, {listings: data.listings}));\n },\n\n async updateExtras({commit}, extra: TripExtra) {\n try {\n await performApiRequest(commit, 'SET_EXTRAS_LOADING', 'extra_update', () => axios.put(`/v1/trip-extras/${extra.uuid}`, extra));\n\n push.success({\n message: 'Trip Extra updated successfully!',\n });\n } catch (error) {\n push.error({\n message: 'Failed to update Trip Extra',\n });\n }\n },\n\n async updateExtraListings({commit}, data: { extraUuid: string, listingIds: string[] }) {\n await performApiRequest(commit, 'SET_EXTRAS_LOADING', 'extra_update', () => axios.put(`/v1/trip-extras/${data.extraUuid}/listings`, {listings: data.listingIds}));\n\n push.success({\n message: 'Trip Extra Listings updated successfully!',\n });\n },\n },\n}\n\nexport default tripExtrasModule;\n","import axios from 'axios';\nimport {get, uniq, uniqBy} from 'lodash';\nimport dayjs from 'dayjs';\nimport {EventBus} from '@/plugins/eventBus';\nimport {StorageService} from '@/services/storage.service';\nimport * as types from '../mutation-types';\nimport {Connection} from '@/types';\n\n\nexport type TuroConnection = Connection & {\n turo_uuid?: string;\n turo_id?: string;\n me?: any;\n}\n\nexport interface TuroState {\n init: boolean;\n loading: Record<string, boolean>;\n credentials: {\n username: string,\n turo_url?: string,\n password: string,\n token: string,\n method: string,\n challenge_code: string,\n grant_type: string,\n mode: string,\n testing?: boolean\n };\n vehicles: any[];\n allImportedVehicles: any[];\n allVehicles: any[];\n allTuroVehicles: any[];\n currentWorkingTrip: any;\n currentWorkingTripMessages: any[];\n currentWorkingTripImages: any[];\n currentWorkingTripImagesComplete: any[];\n trips: any[];\n emails: any[];\n turoMessageSending: boolean;\n turoGoSet: boolean;\n currentTripTuroGo: any;\n connections: TuroConnection[];\n earnings: any[];\n tripHistory: {\n list: any[],\n numPages: number,\n };\n pendingRequests: any[];\n activityFeed: {\n activities: any[],\n };\n reimbursementDetails: any;\n captchaId: string;\n captchaTest: boolean;\n changeRequestSettings: any[];\n feedbackMode: string;\n feedback: {\n pending: any[],\n history: any[],\n };\n feedbackPage: {\n pending: number,\n history: number,\n };\n feedbackNextPage: {\n pending: number,\n history: number,\n };\n feedbackTotal: {\n pending: number,\n history: number,\n };\n feedbackPerPage: {\n pending: number,\n history: number,\n };\n feedbackLastPage: {\n pending: number,\n history: number,\n };\n allTuroMessages: any[];\n allTuroMessagesPaginate: any;\n allTuroMessagesCurrentPage: number;\n allTuroMessagesPages: number;\n emailsPagination: any;\n}\n\nconst state: TuroState = {\n init: false,\n\n loading: {\n me: false,\n login: false,\n refresh_token: false,\n logout: false,\n trips: false,\n listings: false,\n emails: false,\n messages: false,\n images: false,\n active: false,\n captchaInit: false,\n submitReimbursement: false,\n submitReimbursementWithdraw: false,\n reimbursementDetails: false,\n removeTuro: false,\n loginProcess: false,\n fetch_unavailability: false,\n create_unavailability: false,\n remove_unavailability: false,\n saving_change_request: false,\n update_feedback: false,\n delete_feedback: false,\n match_with_listing: false,\n earnings: false,\n feedback: false,\n vehicles: false,\n },\n\n turoMessageSending: false,\n credentials: {\n username: '',\n turo_url: '',\n password: '',\n token: '',\n method: 'general',\n challenge_code: '',\n grant_type: 'password',\n mode: 'SMS',\n },\n vehicles: [],\n allImportedVehicles: [],\n\n allVehicles: [], // Stored on FW\n allTuroVehicles: [], // Fetched straight from Turo\n\n currentWorkingTrip: {},\n currentWorkingTripMessages: [],\n currentWorkingTripImages: [],\n currentWorkingTripImagesComplete: [],\n\n trips: [],\n\n emails: [],\n\n turoGoSet: false,\n currentTripTuroGo: {\n odometer: {\n scalar: 0,\n unit: '',\n },\n },\n\n connections: [],\n earnings: [],\n tripHistory: {\n list: [],\n numPages: 0,\n },\n pendingRequests: [],\n activityFeed: {\n activities: [],\n },\n reimbursementDetails: null,\n captchaId: null,\n captchaTest: false,\n changeRequestSettings: [],\n feedbackMode: null,\n feedback: {\n pending: [],\n history: [],\n },\n feedbackPage: {\n pending: 0,\n history: 0,\n },\n feedbackNextPage: {\n pending: 0,\n history: 0,\n },\n feedbackTotal: {\n pending: 0,\n history: 0,\n },\n feedbackPerPage: {\n pending: 0,\n history: 0,\n },\n feedbackLastPage: {\n pending: 0,\n history: 0,\n },\n allTuroMessages: [],\n allTuroMessagesPaginate: {},\n allTuroMessagesCurrentPage: 0,\n allTuroMessagesPages: 1,\n emailsPagination: {},\n};\n\nconst getters = {\n turoInit: (state: TuroState) => state.init,\n loading: (state: TuroState) => state.loading,\n credentials: (state: TuroState) => state.credentials,\n trips: (state: TuroState) => state.trips,\n currentWorkingTrip: (state: TuroState) => state.currentWorkingTrip,\n currentWorkingTripMessages: (state: TuroState) => state.currentWorkingTripMessages,\n currentWorkingTripImages: (state: TuroState) => state.currentWorkingTripImages,\n turoMessageSending: (state: TuroState) => state.turoMessageSending,\n allTuroMessages: (state: TuroState) => state.allTuroMessages,\n allTuroMessagesPaginate: (state: TuroState) => state.allTuroMessagesPaginate,\n allTuroMessagesCurrentPage: (state: TuroState) => state.allTuroMessagesCurrentPage,\n emails: (state: TuroState) => state.emails,\n vehicles: (state: TuroState) => state.vehicles,\n allVehicles: (state: TuroState) => state.allVehicles,\n allTuroVehicles: (state: TuroState) => state.allTuroVehicles,\n allImportedVehicles: (state: TuroState) => state.allImportedVehicles,\n turoGoSet: (state: TuroState) => state.turoGoSet,\n currentTripTuroGo: (state: TuroState) => state.currentTripTuroGo,\n connections: (state: TuroState) => state.connections,\n earnings: (state: TuroState) => state.earnings,\n reimbursementDetails: (state: TuroState) => state.reimbursementDetails,\n captchaId: (state: TuroState) => state.captchaId,\n tripHistory: (state: TuroState) => state.tripHistory,\n pendingRequests: (state: TuroState) => state.pendingRequests,\n activityFeed: (state: TuroState) => state.activityFeed,\n changeRequestSettings: (state: TuroState) => state.changeRequestSettings,\n feedback: (state: TuroState) => state.feedback,\n feedbackPage: (state: TuroState) => state.feedbackPage,\n feedbackNextPage: (state: TuroState) => state.feedbackNextPage,\n feedbackMode: (state: TuroState) => state.feedbackMode,\n feedbackTotal: (state: TuroState) => state.feedbackTotal,\n feedbackPerPage: (state: TuroState) => state.feedbackPerPage,\n feedbackLastPage: (state: TuroState) => state.feedbackLastPage,\n emailsPagination: (state: TuroState) => state.emailsPagination,\n};\n\nconst mutations = {\n [types.SET_INIT](state: TuroState, init) {\n state.init = init;\n },\n [types.SET_TURO_LOADING](state: TuroState, loading) {\n state.loading[loading.subject] = loading.loading;\n },\n [types.SET_VEHICLES](state: TuroState, vehicles) {\n state.vehicles = vehicles;\n },\n [types.SET_ALL_TURO_VEHICLES](state: TuroState, vehicles) {\n state.allTuroVehicles = uniqBy([...state.allTuroVehicles, ...vehicles], (w) => w.id);\n },\n [types.CLEAR_ALL_TURO_VEHICLES](state: TuroState) {\n state.allTuroVehicles = [];\n },\n [types.SET_TURO_EMAILS](state: TuroState, emails) {\n state.emails = emails;\n },\n [types.SET_TURO_EMAILS_PAGINATION](state: TuroState, pagination) {\n state.emailsPagination = pagination;\n },\n [types.RESET_VEHICLES](state: TuroState) {\n state.vehicles = [];\n },\n [types.SET_TURO_EARNINGS](state: TuroState, earnings) {\n state.earnings = earnings;\n },\n [types.SET_TURO_FEEDBACK](state: TuroState, {data, mode}) {\n state.feedback[mode] = uniqBy([...state.feedback[mode], ...data], w => w.uuid);\n state.feedbackMode = mode;\n },\n [types.SET_TURO_FEEDBACK_PAGE](state: TuroState, {page, mode}) {\n state.feedbackPage[mode] = page;\n },\n [types.SET_TURO_FEEDBACK_TOTAL](state: TuroState, {total, mode}) {\n state.feedbackTotal[mode] = total;\n },\n [types.SET_TURO_FEEDBACK_NEXT_PAGE](state: TuroState, {page, mode}) {\n state.feedbackNextPage[mode] = page;\n },\n [types.SET_TURO_FEEDBACK_PER_PAGE](state: TuroState, {per_page, mode}) {\n state.feedbackPerPage[mode] = per_page;\n },\n [types.SET_TURO_FEEDBACK_LAST_PAGE](state: TuroState, {last_page, mode}) {\n state.feedbackLastPage[mode] = last_page;\n },\n\n [types.SET_TRIPS](state: TuroState, trips) {\n state.init = true;\n\n\n state.trips = trips.map(trip => ({\n key: trip.reservationId,\n renter: trip.actor.firstName,\n listing: trip.vehicle.name,\n time: dayjs(trip.itemTimestamp).format('ddd MMM DD @ H:mm a'),\n make: trip.vehicle.make,\n model: trip.vehicle.model,\n trim: trip.vehicle.trim,\n style: trip.vehicle.style,\n vin: trip.vehicle.vin,\n vin4: trip.vehicle.vin.substring(trip.vehicle.vin.length - 4),\n year: trip.vehicle.year,\n address: trip.address,\n inProgress: trip.inProgress,\n reservationId: trip.reservationId,\n host: trip.host,\n upcomingTripFeedItemType: trip.upcomingTripFeedItemType,\n vehicle: trip.vehicle,\n startF: dayjs(trip.startF).format('ddd MMM DD @ H:mm a'),\n endF: dayjs(trip.endF).format('ddd MMM DD @ H:mm a'),\n }));\n },\n [types.SET_TRIP_SINGLE](state: TuroState, trip) {\n state.init = true;\n state.currentWorkingTrip = trip;\n },\n\n [types.SET_TRIP_SINGLE_MESSAGES](state: TuroState, messages) {\n state.currentWorkingTripMessages = messages;\n },\n [types.SET_TRIP_SINGLE_MESSAGES_STORED](state: TuroState, messages) {\n state.currentWorkingTripMessages = messages;\n },\n [types.SET_TRIP_SINGLE_IMAGES](state: TuroState, images) {\n state.currentWorkingTripImages = images;\n },\n [types.SET_TURO_MESSAGE_SENDING](state: TuroState, sending) {\n state.turoMessageSending = sending;\n },\n [types.SET_TURO_ALL_VEHICLES](state: TuroState, vehicles) {\n state.allVehicles = vehicles;\n },\n [types.SET_ALL_IMPORTED_TURO_VEHICLES](state: TuroState, vehicles) {\n state.allImportedVehicles = vehicles;\n },\n [types.SET_TRIP_TURO_GO](state: TuroState, data) {\n state.currentTripTuroGo = data;\n state.turoGoSet = true;\n },\n [types.SET_TURO_CONNECTIONS](state: TuroState, connections) {\n state.connections = connections;\n },\n [types.SET_TURO_REIMBURSEMENT_DETAILS](state: TuroState, details) {\n state.reimbursementDetails = details;\n },\n [types.RESET_TURO_CREDS](state: TuroState) {\n state.credentials = {\n username: '',\n password: '',\n token: '',\n method: 'general',\n challenge_code: '',\n grant_type: 'password',\n mode: 'SMS',\n };\n },\n [types.SET_TURO_CAPTCHA_ID](state: TuroState, id) {\n state.captchaId = id;\n },\n [types.SET_TURO_CAPTCHA_TESTING](state: TuroState, testing) {\n state.captchaTest = testing;\n },\n [types.SET_TRIP_HISTORY](state: TuroState, history) {\n state.tripHistory = history;\n },\n [types.SET_TRIP_PENDING_REQUESTS](state: TuroState, requests) {\n state.pendingRequests = requests;\n },\n [types.SET_ACTIVITY_FEED](state: TuroState, activity) {\n state.activityFeed = activity;\n },\n [types.SET_TURO_CHANGE_REQUEST_SETTINGS](state: TuroState, settings) {\n state.changeRequestSettings = settings;\n },\n [types.SET_ALL_TURO_MESSAGES](state: TuroState, messages) {\n state.allTuroMessages = uniqBy([...state.allTuroMessages, ...messages], w => w.reservation.id);\n },\n [types.SET_ALL_TURO_MESSAGES_CURRENT_PAGINATE](state: TuroState, paginate) {\n state.allTuroMessagesPaginate = paginate;\n },\n [types.SET_ALL_TURO_MESSAGES_TOTAL_PAGES](state: TuroState, pages) {\n state.allTuroMessagesPages = pages;\n },\n};\n\nconst actions = {\n\n createTuroConnection({state, commit}) {\n if (state.captchaTest) state.credentials.testing = true;\n if (!state.loading.login) {\n commit('SET_TURO_LOADING', {subject: 'login', loading: true});\n\n axios.post('/v1/connections/turo', state.credentials)\n .then(response => {\n commit('turo/SET_TURO_CONNECTIONS', get(response, 'data.company.connections.turo', []), {root: true});\n EventBus.$emit('create-turo-connection-success');\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'Turo connection added successfully',\n });\n commit('RESET_TURO_CREDS');\n }).catch(e => {\n console.dir(e);\n if (e.response.status === 400 || e.response.status === 403) {\n EventBus.$emit('create-turo-connection-failed-400', e.response.data.message);\n }\n\n if (e.response.status === 412) {\n EventBus.$emit('create-turo-connection-failed-412', get(e, 'response.data'));\n }\n\n if (e.response.status === 422) {\n EventBus.$emit('create-turo-connection-failed-400', e.response.data.message);\n }\n }).finally(() => {\n commit('SET_TURO_LOADING', {subject: 'login', loading: false});\n commit('SET_TURO_LOADING', {subject: 'loginProcess', loading: false});\n });\n }\n },\n\n sendSecurityChallengeCode({state: TuroState, dispatch}, data) {\n axios.post('/v1/connections/turo/code-challenge-init', data)\n .then(() => {\n EventBus.$emit('turo-code-challenge-send-success');\n }).catch(() => {\n });\n },\n\n\n /**\n * Refresh a Turo connection\n *\n * @param commit\n * @param {Object} turo\n */\n turoRefreshToken({commit}, turo) {\n commit('SET_TURO_LOADING', {subject: 'refresh_token', loading: true});\n\n axios.post(`/v1/connections/turo/${turo.uuid}/refresh-token`, turo)\n .then(response => {\n EventBus.$emit('turo-code-challenge-send-success');\n EventBus.$emit('turo-refresh-token-success');\n EventBus.$emit('create-turo-connection-success');\n commit('turo/SET_TURO_CONNECTIONS', get(response, 'data.company.connections.turo', []), {root: true});\n }).catch(e => {\n if (e.response.status === 422 || e.response.status === 500) {\n if (get(e, 'response.data.code') === 'invalid_refresh_token') {\n }\n EventBus.$emit('turo-refresh-token-failed');\n }\n }).finally(() => {\n commit('SET_TURO_LOADING', {subject: 'refresh_token', loading: false});\n });\n },\n\n getFeedback({state, commit}, options) {\n commit('SET_TURO_LOADING', {subject: 'feedback', loading: true});\n\n const mode = get(options, 'mode', false);\n const nextPage = state.feedbackNextPage[mode]++;\n let query = `?page=${nextPage}`;\n const history = mode === 'history';\n const pending = mode === 'pending';\n\n if (history) {\n query = `${query}&history=${history}`;\n }\n if (pending) {\n query = `${query}&pending=${pending}`;\n }\n\n\n axios.get(`/v1/connections/turo/feedback${query}`)\n .then(response => {\n commit('SET_TURO_FEEDBACK', {\n data: get(response, 'data.feedback.data', []),\n mode,\n });\n commit('SET_TURO_FEEDBACK_PAGE', {\n page: get(response, 'data.feedback.current_page', 1),\n mode,\n });\n commit('SET_TURO_FEEDBACK_NEXT_PAGE', {\n page: get(response, 'data.feedback.current_page', 1) + 1,\n mode,\n });\n commit('SET_TURO_FEEDBACK_TOTAL', {\n total: get(response, 'data.feedback.total'),\n mode,\n });\n commit('SET_TURO_FEEDBACK_PER_PAGE', {\n per_page: get(response, 'data.feedback.per_page'),\n mode,\n });\n commit('SET_TURO_FEEDBACK_LAST_PAGE', {\n last_page: get(response, 'data.feedback.last_page'),\n mode,\n });\n }).catch(() => {\n }).finally(() => {\n commit('SET_TURO_LOADING', {subject: 'feedback', loading: false});\n });\n },\n\n updateFeedback({state, commit, rootGetters}, feedback) {\n commit('SET_TURO_LOADING', {subject: 'update_feedback', loading: true});\n\n axios.put(`/v1/company/${rootGetters['company/company'].uuid}/connections/turo/feedback/${feedback.uuid}`, feedback)\n .then(response => {\n commit('SET_TURO_FEEDBACK', get(response, 'data.feedback', []));\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'Auto feedback updated successfully',\n });\n }).catch(() => {\n }).finally(() => {\n commit('SET_TURO_LOADING', {subject: 'update_feedback', loading: false});\n });\n },\n\n sendFeedback({state, commit, rootGetters}, feedback) {\n commit('SET_TURO_LOADING', {subject: 'update_feedback', loading: true});\n\n axios.post(`/v1/company/${rootGetters['company/company'].uuid}/connections/turo/feedback/${feedback.uuid}/send`, feedback)\n .then(response => {\n EventBus.$emit('turo-auto-feedback-send-success');\n commit('SET_TURO_FEEDBACK', get(response, 'data.feedback', []));\n }).catch(e => {\n EventBus.$emit('turo-auto-feedback-send-error');\n push.error({\n message: e?.response?.data?.message || 'There was an error',\n });\n commit('SET_TURO_FEEDBACK', get(e, 'response.data.feedback', []));\n }).finally(() => {\n commit('SET_TURO_LOADING', {subject: 'update_feedback', loading: false});\n });\n },\n\n deleteFeedback({state, commit, rootGetters}, feedback) {\n commit('SET_TURO_LOADING', {subject: 'delete_feedback', loading: true});\n\n axios.delete(`/v1/company/${rootGetters['company/company'].uuid}/connections/turo/feedback/${feedback.uuid}`)\n .then(response => {\n commit('SET_TURO_FEEDBACK', get(response, 'data.feedback', []));\n EventBus.$emit('turo-auto-feedback-deleted-success');\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'Auto feedback deleted successfully',\n });\n }).catch(() => {\n }).finally(() => {\n commit('SET_TURO_LOADING', {subject: 'delete_feedback', loading: false});\n });\n },\n\n getFeedbackSettings({commit}) {\n commit('SET_TURO_LOADING', {subject: 'active', loading: true});\n\n axios.get('/v1/connections/turo/feedback-settings')\n .then(response => {\n commit('SET_TURO_CONNECTIONS', get(response, 'data.turoAccounts', []));\n }).catch(() => {\n }).finally(() => {\n commit('SET_TURO_LOADING', {subject: 'active', loading: false});\n });\n },\n\n updateFeedbackSettings({state, commit}, settings) {\n commit('SET_TURO_LOADING', {subject: 'active', loading: true});\n\n axios.put(`/v1/connections/turo/feedback-settings/${settings.uuid}`, settings)\n .then(response => {\n commit('SET_TURO_FEEDBACK', get(response, 'data.feedback', []));\n commit('company/SET_FEEDBACK_REVIEWS', get(response, 'data.feedbackReviews'), {root: true});\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'Turo updated successfully',\n });\n }).catch(() => {\n }).finally(() => {\n commit('SET_TURO_LOADING', {subject: 'active', loading: false});\n });\n },\n\n /**\n * Toggle a Turo connections active state.\n */\n toggleTuroActive({state: TuroState, commit}, turo: TuroConnection) {\n commit('SET_TURO_LOADING', {subject: 'active', loading: true});\n\n const connIndex = state.connections.findIndex(c => turo.uuid === c.uuid);\n\n if (connIndex !== -1) {\n state.connections[connIndex].loading = true;\n }\n\n axios.put(`/v1/connections/turo/${turo.uuid}/toggle`)\n .then((response) => {\n EventBus.$emit('toggle-turo-active-success', get(response, 'data.turo', []));\n\n if (turo.active) {\n EventBus.$emit('toggle-turo-connection-success', turo);\n }\n if (connIndex !== -1) {\n state.connections[connIndex].connected = turo.active;\n }\n }).catch(e => {\n push.error({\n message: e?.response?.data?.message || 'There was an error',\n });\n }).finally(() => {\n commit('SET_TURO_LOADING', {subject: 'active', loading: false});\n if (connIndex !== -1) {\n state.connections[connIndex].loading = false;\n }\n });\n },\n\n\n /**\n * Delete a Turo connection\n *\n * @param commit\n * @param {Object} turo\n */\n removeTuroConnection({commit}, turo) {\n commit('SET_TURO_LOADING', {subject: 'removeTuro', loading: true});\n\n axios.delete(`/v1/connections/turo/${turo.uuid}`)\n .then(response => {\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'Turo connection removed successfully',\n });\n EventBus.$emit('remove-turo-connection-success');\n commit('SET_TURO_CONNECTIONS', get(response, 'data.connections.turo', []));\n }).catch(e => {\n console.dir(e);\n if (e.response.status === 400 || e.response.status === 403) {\n EventBus.$emit('create-turo-connection-failed-400', e.response.data.message);\n }\n }).finally(() => {\n commit('SET_TURO_LOADING', {subject: 'removeTuro', loading: false});\n });\n },\n\n /**\n * Fetch Turo /me\n */\n fetchTuroMe({state: TuroState, commit}, turo_uuid: string) {\n commit('SET_TURO_LOADING', {subject: 'login', loading: true});\n commit('SET_TURO_LOADING', {subject: 'listings', loading: true});\n commit('SET_TURO_LOADING', {subject: 'me', loading: true});\n\n let connIndex = state.connections.findIndex(c => turo_uuid === c.uuid);\n\n if (connIndex === -1) {\n connIndex = state.connections.push({\n turo_uuid,\n loading: true,\n connected: true,\n active: true,\n email: '',\n provider: 'turo',\n });\n connIndex--;\n }\n\n state.connections[connIndex].loading = true;\n\n axios.get(`/v1/connections/turo/${turo_uuid}/me?updateVehicles=1`)\n .then(response => {\n commit('SET_VEHICLES', response.data.me.vehicles);\n state.connections[connIndex].connected = true;\n state.connections[connIndex].me = get(response, 'data.me');\n EventBus.$emit('turo-me-success', {\n me: response.data.me,\n turo_uuid,\n });\n }).catch(e => {\n if (e.response.status === 400 || e.response.status === 403) {\n EventBus.$emit('create-turo-connection-failed-400', e.response.data.message);\n } else if (e.response.status === 428) {\n EventBus.$emit('create-turo-connection-failed-428', {\n message: e.response.data.message,\n turo_uuid,\n });\n } else if (e.response.status === 422) {\n EventBus.$emit('create-turo-connection-failed-422', {\n message: get(e.response, 'data.error'),\n turo_uuid,\n });\n }\n state.connections[connIndex].connected = false;\n state.connections[connIndex].me = null;\n state.connections[connIndex].loading = false;\n }).finally(() => {\n state.connections[connIndex].loading = false;\n commit('SET_TURO_LOADING', {subject: 'login', loading: false});\n commit('SET_TURO_LOADING', {subject: 'listings', loading: false});\n commit('SET_TURO_LOADING', {subject: 'me', loading: false});\n });\n },\n\n /**\n * Fetch Turo Vehicles\n *\n * @param state\n * @param commit\n * @param {Array} turo_uuids The Turo uuids to include\n */\n fetchTuroVehicles({state, commit}, turo_uuids) {\n commit('SET_TURO_LOADING', {subject: 'vehicles', loading: true});\n\n const ids = uniq(turo_uuids).join();\n\n axios.get(`/v1/connections/turo/fetch-vehicles?turo_ids=${ids}`)\n .then(response => {\n commit('SET_ALL_TURO_VEHICLES', get(response, 'data.vehicles'));\n EventBus.$emit('turo-fetch-vehicles-success', turo_uuids);\n }).catch(e => {\n console.dir(e);\n }).finally(() => {\n commit('SET_TURO_LOADING', {subject: 'vehicles', loading: false});\n });\n },\n\n getTuroVehicles({state, commit}, turo_uuids) {\n commit('SET_TURO_LOADING', {subject: 'vehicles', loading: true});\n\n const ids = uniq(turo_uuids).join();\n\n axios.get(`/v1/connections/turo/vehicles?turo_ids=${ids}`)\n .then(response => {\n commit('SET_ALL_TURO_VEHICLES', get(response, 'data.vehicles'));\n EventBus.$emit('turo-vehicles-success', turo_uuids);\n }).catch(e => {\n console.dir(e);\n }).finally(() => {\n commit('SET_TURO_LOADING', {subject: 'vehicles', loading: false});\n });\n },\n\n /**\n * Match a Turo vehicle with a Fleetwire listing\n *\n * @param commit\n * @param {Object} data\n */\n matchVehicleWithFleetwireListing({commit}, data) {\n commit('SET_TURO_LOADING', {subject: 'match_with_listing', loading: true});\n\n axios.post('/v1/connections/turo/match-with-listing', data)\n .then(() => {\n EventBus.$emit('match-turo-vehicle-with-listing-success');\n }).catch(e => {\n console.dir(e);\n EventBus.$emit('match-turo-vehicle-with-listing-error', get(e, 'response'));\n }).finally(() => {\n commit('SET_TURO_LOADING', {subject: 'match_with_listing', loading: false});\n });\n },\n\n\n fetchAllTuroVehicles({commit}) {\n commit('SET_TURO_LOADING', {subject: 'login', loading: true});\n commit('SET_TURO_LOADING', {subject: 'listings', loading: true});\n\n axios.get('/v1/connections/turo/all/vehicles')\n .then(response => {\n commit('SET_TURO_ALL_VEHICLES', response.data.vehicles);\n }).catch(e => {\n console.dir(e);\n }).finally(() => {\n commit('SET_TURO_LOADING', {subject: 'login', loading: false});\n commit('SET_TURO_LOADING', {subject: 'listings', loading: false});\n });\n },\n\n /**\n * Adjust a vehicle unavailability\n *\n * @param state\n * @param commit\n * @param {Object} accounts\n */\n fetchMyTaxEarnings({state, commit}, accounts) {\n commit('SET_TURO_LOADING', {subject: 'earnings', loading: true});\n\n const qString = accounts.join(',');\n axios.get(`/v1/connections/turo/tax-earnings?turo_uuids=${qString}`)\n .then(response => {\n commit('SET_TURO_EARNINGS', get(response, 'data.earnings', []));\n }).catch(e => {\n console.dir(e);\n if (e.response.status === 400 || e.response.status === 403) {\n EventBus.$emit('create-turo-connection-failed-400', e.response.data.message);\n }\n }).finally(() => {\n commit('SET_TURO_LOADING', {subject: 'earnings', loading: false});\n });\n },\n\n\n /**\n * Re-fetch Turo earnings\n *\n * @param state\n * @param commit\n * @param {String} turo_uuid\n */\n refreshAccountEarnings({state, commit}, turo_uuid) {\n commit('SET_TURO_LOADING', {subject: 'earnings', loading: true});\n\n axios.get(`/v1/connections/turo/${turo_uuid}/tax-earnings`)\n .then(() => {\n EventBus.$emit('refresh-turo-earnings-success');\n }).catch(e => {\n console.dir(e);\n if (e.response.status === 400 || e.response.status === 403) {\n EventBus.$emit('create-turo-connection-failed-400', e.response.data.message);\n }\n }).finally(() => {\n commit('SET_TURO_LOADING', {subject: 'earnings', loading: false});\n });\n },\n\n checkPulse({state, commit, rootGetters}, turo_uuid) {\n commit('SET_TURO_LOADING', {subject: 'login', loading: true});\n axios.get(`/v1/company/${rootGetters['company/company'].uuid}/connections/turo/${turo_uuid}/me`)\n .catch(e => {\n console.dir(e);\n if (e.response.status === 400 || e.response.status === 403) {\n EventBus.$emit('create-turo-connection-failed-400', e.response.data.message);\n }\n }).finally(() => {\n commit('SET_TURO_LOADING', {subject: 'login', loading: false});\n });\n },\n\n fetchTuroGoTrip({state, commit, rootGetters}, {turo_uuid, vehicle_id}) {\n commit('SET_TURO_LOADING', {subject: 'trips', loading: true});\n axios.get(`/v1/company/${rootGetters['company/company'].uuid}/connections/turo/${turo_uuid}/${vehicle_id}/turo-go`)\n .then(response => {\n commit('SET_TRIP_TURO_GO', get(response, 'data.turoGo'));\n }).catch(e => {\n console.dir(e);\n }).finally(() => {\n commit('SET_TURO_LOADING', {subject: 'trips', loading: false});\n });\n },\n\n /**\n * Fetch a vehicle unavailability on Turo\n *\n * @param commit\n * @param {String} turo_uuid\n * @param {String} vehicle_uuid\n */\n fetchVehicleUnavailability({commit}, {turo_uuid, vehicle_uuid}) {\n commit('SET_TURO_LOADING', {subject: 'trips', loading: true});\n\n axios.get(`/v1/connections/turo/${turo_uuid}/vehicle/${vehicle_uuid}/unavailability`)\n .then(() => {\n // commit('SET_TRIPS', get(response, 'data.trips'));\n // commit('listing/SET_CURRENT_LISTING_BOOKINGS', get(response, 'data.bookings', []), { root: true });\n }).catch(e => {\n if (e.response.status === 400 || e.response.status === 403) {\n EventBus.$emit('create-turo-connection-failed-400', e.response.data.message);\n }\n }).finally(() => {\n commit('SET_TURO_LOADING', {subject: 'trips', loading: false});\n });\n },\n\n /**\n * Create a vehicle unavailability on Turo\n *\n * @param state\n * @param commit\n * @param {Object} data\n */\n createVehicleUnavailability({state, commit}, data) {\n commit('SET_TURO_LOADING', {subject: 'create_unavailability', loading: true});\n\n axios.post(`/v1/connections/turo/${data.turo_uuid}/vehicle/${data.vehicle_uuid}/unavailability`, data)\n .then(response => {\n EventBus.$emit('create-turo-unavailability', response.data);\n // commit('booking/SET_CURRENT_WORKING_BOOKING', get(response, 'data.booking'), { root: true });\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'Turo vehicle unavailability period created successfully',\n });\n }).catch(e => {\n console.dir(e);\n if (e.response.status === 400 || e.response.status === 403) {\n EventBus.$emit('create-turo-unavailability-failed-400', e.response.data);\n }\n if (e.response.status === 422) {\n EventBus.$emit('create-turo-unavailability-failed-422', e.response.data);\n }\n }).finally(() => {\n commit('SET_TURO_LOADING', {subject: 'create_unavailability', loading: false});\n });\n },\n\n removeVehicleUnavailability({state, commit, rootGetters}, data) {\n commit('SET_TURO_LOADING', {subject: 'remove_unavailability', loading: true});\n\n axios.delete(`/v1/company/${rootGetters['company/company'].uuid}/connections/turo/${data.turo_uuid}/vehicle/${data.vehicle_uuid}/unavailability?reservationId=${data.reservationId}`)\n .then(() => {\n EventBus.$emit('remove-turo-unavailability', data.reservationId);\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'Turo vehicle unavailability period removed successfully',\n });\n }).catch(e => {\n if (e.response.status === 400 || e.response.status === 403) {\n EventBus.$emit('remove-turo-unavailability-failed-400', e.response.data);\n }\n }).finally(() => {\n commit('SET_TURO_LOADING', {subject: 'remove_unavailability', loading: false});\n });\n },\n\n /**\n * Adjust a vehicle unavailability\n *\n * @param state\n * @param commit\n * @param {Object} data\n */\n removeVehicleUnavailabilityAndAdjust({state, commit}, data) {\n commit('SET_TURO_LOADING', {subject: 'remove_unavailability', loading: true});\n\n axios.post(`/v1/company/${StorageService.getCompanyUuid()}/connections/turo/${data.turo_uuid}/vehicle/${data.vehicle_uuid}/unavailability/adjust`, data)\n .then(response => {\n commit('booking/SET_CURRENT_WORKING_BOOKING', response.data.booking, {root: true});\n EventBus.$emit('remove-turo-unavailability-adjust-success', data);\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'Turo vehicle unavailability period removed successfully',\n });\n }).catch(e => {\n if (e.response.status === 400 || e.response.status === 403) {\n EventBus.$emit('remove-turo-unavailability-failed-400', e.response.data);\n }\n }).finally(() => {\n commit('SET_TURO_LOADING', {subject: 'remove_unavailability', loading: false});\n });\n },\n\n fetchTripHistory({state, commit, rootGetters}, turo_uuid) {\n commit('SET_TURO_LOADING', {subject: 'trips', loading: true});\n axios.get(`/v1/connections/turo/${turo_uuid}/trips/history`)\n .then(response => {\n commit('SET_TRIP_HISTORY', get(response, 'data.history', []));\n }).catch(e => {\n if (e.response.status === 400 || e.response.status === 403) {\n EventBus.$emit('fetch-turo-trip-single-failed', e.response.data.message);\n }\n }).finally(() => {\n commit('SET_TURO_LOADING', {subject: 'trips', loading: false});\n state.init = true;\n });\n },\n\n fetchPendingRequests({state, commit, rootGetters}, turo_uuid) {\n commit('SET_TURO_LOADING', {subject: 'trips', loading: true});\n axios.get(`/v1/connections/turo/${turo_uuid}/trips/pending-requests`)\n .then(response => {\n commit('SET_TRIP_PENDING_REQUESTS', get(response, 'data.requests', []));\n }).catch(e => {\n if (e.response.status === 400 || e.response.status === 403) {\n EventBus.$emit('fetch-turo-trip-single-failed', e.response.data.message);\n }\n }).finally(() => {\n commit('SET_TURO_LOADING', {subject: 'trips', loading: false});\n state.init = true;\n });\n },\n\n fetchActivityFeed({state, commit, rootGetters}, turo_uuid) {\n commit('SET_TURO_LOADING', {subject: 'trips', loading: true});\n\n axios.get(`/v1/connections/turo/${turo_uuid}/trips/activity-feed`)\n .then(response => {\n commit('SET_ACTIVITY_FEED', get(response, 'data.activity', []));\n }).catch(e => {\n if (e.response.status === 400 || e.response.status === 403) {\n EventBus.$emit('fetch-turo-trip-single-failed', e.response.data.message);\n }\n }).finally(() => {\n commit('SET_TURO_LOADING', {subject: 'trips', loading: false});\n state.init = true;\n });\n },\n\n fetchTuroTripSingle({state, commit}, data) {\n commit('SET_TURO_LOADING', {subject: 'trips', loading: true});\n\n axios.get(`/v1/connections/turo-trips/${data.tripId}?turoId=${data.turoId}`)\n .then(response => {\n commit('SET_TRIP_SINGLE', get(response, 'data.trip'));\n EventBus.$emit('turo-fetch-sing-trip-success', get(response, 'data.trip'));\n }).catch(e => {\n if (e.response.status === 400 || e.response.status === 403) {\n EventBus.$emit('fetch-turo-trip-single-failed', e.response.data.message);\n }\n }).finally(() => {\n commit('SET_TURO_LOADING', {subject: 'trips', loading: false});\n state.init = true;\n });\n },\n\n /**\n * Fetch a Turo trip messages\n *\n * @param commit\n * @param {Object} data\n */\n fetchTuroTripSingleMessages({commit}, data) {\n commit('SET_TURO_LOADING', {subject: 'messages', loading: true});\n\n axios.get(`/v1/connections/turo-trips/${data.tripId}/messages?account_id=${data.accountId}`)\n .then(response => {\n commit('SET_TRIP_SINGLE_MESSAGES', response.data.messages);\n }).catch(e => {\n if (e.response.status === 400 || e.response.status === 403) {\n EventBus.$emit('create-turo-connection-failed-400', e.response.data.message);\n }\n }).finally(() => {\n commit('SET_TURO_LOADING', {subject: 'messages', loading: false});\n });\n },\n\n getStoredTuroTripSingleMessages({commit}, tripId) {\n commit('SET_TURO_LOADING', {subject: 'messages', loading: true});\n\n axios.get(`/v1/connections/turo-trips/${tripId}/stored-messages`)\n .then(response => {\n commit('SET_TRIP_SINGLE_MESSAGES_STORED', response.data.messages);\n }).catch(e => {\n console.dir(e);\n if (e.response.status === 400 || e.response.status === 403) {\n EventBus.$emit('create-turo-connection-failed-400', e.response.data.message);\n }\n }).finally(() => {\n commit('SET_TURO_LOADING', {subject: 'messages', loading: false});\n });\n },\n\n\n /**\n * Fetch a Turo trips images\n *\n * @param commit\n * @param {String} tripId\n */\n fetchTuroTripSingleImages({commit}, tripId) {\n commit('SET_TURO_LOADING', {subject: 'images', loading: true});\n\n axios.get(`/v1/connections/turo-trips/${tripId}/images`)\n .then(response => {\n commit('SET_TRIP_SINGLE_IMAGES', get(response, 'data.images'));\n }).catch(e => {\n console.dir(e);\n if (e.response.status === 400 || e.response.status === 403) {\n EventBus.$emit('fetch-turo-images-failed-400', e.response.data.message);\n }\n }).finally(() => {\n commit('SET_TURO_LOADING', {subject: 'images', loading: false});\n });\n },\n\n /**\n * Get Turo messages\n *\n * @param state\n * @param commit\n * @param {Object} data\n */\n getTuroConversations({state, commit}, data) {\n commit('SET_TURO_LOADING', {subject: 'messages', loading: true});\n\n if (!get(state.allTuroMessagesCurrentPage, data.turoId)) {\n state.allTuroMessagesCurrentPage = {\n ...state.allTuroMessagesCurrentPage,\n [data.turoId]: {page: 0, totalPages: 1}\n };\n }\n state.allTuroMessagesCurrentPage[data.turoId].page += 1;\n\n const qString = `page=${state.allTuroMessagesCurrentPage[data.turoId].page}`;\n\n axios.get(`/v1/connections/turo/${data.turoUuid}/messages?${qString}`)\n .then(response => {\n commit('SET_ALL_TURO_MESSAGES', get(response, 'data.conversations.list', []));\n commit('SET_ALL_TURO_MESSAGES_CURRENT_PAGINATE', get(response, 'data.conversations.numPages', 1));\n state.allTuroMessagesCurrentPage[data.turoId].totalPages = get(response, 'data.conversations.numPages', 1);\n commit('SET_ALL_TURO_MESSAGES_TOTAL_PAGES', get(response, 'data.conversations.numPages', 1));\n }).catch(e => {\n console.dir(e);\n }).finally(() => {\n commit('SET_TURO_LOADING', {subject: 'messages', loading: false});\n commit('SET_TURO_MESSAGE_SENDING', false);\n });\n },\n\n /**\n * Send a message to a renter\n *\n * @param state\n * @param commit\n * @param {String} tripId\n * @param {String} message\n */\n sendTuroMessage({state, commit}, {tripId, message}) {\n commit('SET_TURO_LOADING', {subject: 'trips', loading: true});\n commit('SET_TURO_MESSAGE_SENDING', true);\n\n axios.post(`/v1/company/${StorageService.getCompanyUuid()}/connections/turo-trips/${tripId}/message`, {message})\n .then(response => {\n commit('SET_TRIP_SINGLE_MESSAGES', response.data.messages);\n EventBus.$emit('send-turo-message-success');\n }).catch(e => {\n console.dir(e);\n if (e.response.status === 400 || e.response.status === 403) {\n EventBus.$emit('create-turo-connection-failed-400', e.response.data.message);\n }\n }).finally(() => {\n commit('SET_TURO_LOADING', {subject: 'trips', loading: false});\n commit('SET_TURO_MESSAGE_SENDING', false);\n });\n },\n\n fetchTuroEmails({commit}, paginate: {\n page?: number,\n itemsPerPage?: number,\n sortBy?: string,\n sortDesc?: boolean\n } = {}) {\n commit('SET_TURO_LOADING', {subject: 'emails', loading: true});\n\n if (paginate.page === undefined) {\n paginate.page = 1;\n }\n\n if (paginate.itemsPerPage === undefined) {\n paginate.itemsPerPage = 10;\n }\n if (paginate.sortBy === undefined) {\n paginate.sortBy = 'created_at';\n }\n if (paginate.sortDesc === undefined) {\n paginate.sortDesc = true;\n }\n\n axios.get(`/v1/connections/turo/emails?page=${paginate.page}&perPage=${paginate.itemsPerPage}&sortBy=${paginate.sortBy}&sortDesc=${paginate.sortDesc}`)\n .then(response => {\n const emails = response.data.data;\n const pagination = response.data.meta;\n\n commit('SET_TURO_EMAILS', emails);\n commit('SET_TURO_EMAILS_PAGINATION', pagination);\n }).catch(e => {\n console.dir(e);\n if (e.response.status === 400 || e.response.status === 403) {\n EventBus.$emit('create-turo-connection-failed-400', e.response.data.message);\n }\n }).finally(() => {\n commit('SET_TURO_LOADING', {subject: 'emails', loading: false});\n });\n },\n\n submitReimbursement({state, commit, rootGetters}, data) {\n commit('SET_TURO_LOADING', {subject: 'submitReimbursement', loading: true});\n axios.post(`/v1/company/${rootGetters['company/company'].uuid}/connections/turo/${data.turo_uuid}/submit-reimbursement`, data)\n .then(() => {\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'Submit reimbursement request successfully',\n });\n EventBus.$emit('submit-turo-reimbursement-success');\n }).catch(e => {\n push.error({\n message: e?.response?.data?.message || 'There was an error',\n });\n }).finally(() => {\n commit('SET_TURO_LOADING', {subject: 'submitReimbursement', loading: false});\n });\n },\n\n getTuroChangeRequestSettings({commit}) {\n commit('SET_TURO_LOADING', {subject: 'submitReimbursement', loading: true});\n\n axios.get('/v1/connections/turo/change-request-settings')\n .then(response => {\n commit('SET_TURO_CHANGE_REQUEST_SETTINGS', get(response, 'data.changeRequestSettings', []));\n }).catch(e => {\n push.error({\n message: e?.response?.data?.message || 'There was an error',\n });\n }).finally(() => {\n commit('SET_TURO_LOADING', {subject: 'submitReimbursement', loading: false});\n });\n },\n\n saveTuroChangeRequestSettings({commit}, data) {\n commit('SET_TURO_LOADING', {subject: 'saving_change_request', loading: true});\n\n axios.post('/v1/connections/turo/change-request-settings', data)\n .then(response => {\n commit('SET_TURO_CHANGE_REQUEST_SETTINGS', get(response, 'data.changeRequestSettings', []));\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'Change request settings saved successfully',\n });\n EventBus.$emit('submit-turo-reimbursement-success');\n }).catch(e => {\n push.error({\n message: e?.response?.data?.message || 'There was an error',\n });\n }).finally(() => {\n commit('SET_TURO_LOADING', {subject: 'saving_change_request', loading: false});\n });\n },\n\n reimbursementDetails({commit, rootGetters}, data) {\n commit('SET_TURO_LOADING', {subject: 'reimbursementDetails', loading: true});\n axios.post(`/v1/connections/turo/${data.turo_uuid}/reimbursement-details`, data)\n .then(response => {\n commit('SET_TURO_REIMBURSEMENT_DETAILS', response.data.reimbursementDetails);\n EventBus.$emit('turo-reimbursement-details-success');\n }).catch(e => {\n push.error({\n message: e?.response?.data?.message || 'There was an error',\n });\n }).finally(() => {\n commit('SET_TURO_LOADING', {subject: 'reimbursementDetails', loading: false});\n });\n },\n\n withdrawReimbursement({state, commit, rootGetters}, data) {\n commit('SET_TURO_LOADING', {subject: 'submitReimbursementWithdraw', loading: true});\n axios.post(`/v1/company/${rootGetters['company/company'].uuid}/connections/turo/${data.turo_uuid}/withdraw-reimbursement`, data)\n .then(() => {\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'Submit reimbursement request successfully',\n });\n EventBus.$emit('submit-turo-withdraw-success');\n }).catch(e => {\n push.error({\n message: e?.response?.data?.message || 'There was an error',\n });\n }).finally(() => {\n commit('SET_TURO_LOADING', {subject: 'submitReimbursementWithdraw', loading: false});\n });\n },\n};\n\nexport default {\n namespaced: true,\n state,\n mutations,\n actions,\n getters,\n};\n","import axios from 'axios';\nimport {filter, findIndex, flatMap, get, map, slice} from 'lodash';\nimport {EventBus} from '@/plugins/eventBus';\nimport * as types from '../mutation-types';\n\nexport interface TuroPricingState {\n init: boolean,\n loading: Record<string, boolean>,\n allVehicles: any[],\n listedVehicles: any[],\n snoozedVehicles: any[],\n vehiclePricing: any[],\n outlookDays: number,\n\n}\n\nconst state: TuroPricingState = {\n init: false,\n\n loading: {\n turo_me: false,\n updateVehiclesDailyPrice: false,\n fetchVehicleDailyPrice: false,\n },\n outlookDays: 28,\n allVehicles: [],\n listedVehicles: [],\n snoozedVehicles: [],\n vehiclePricing: [],\n};\n\nconst getters = {\n turoInit: (state: TuroPricingState) => state.init,\n loading: (state: TuroPricingState) => state.loading,\n allVehicles: (state: TuroPricingState) => state.allVehicles,\n listedVehicles: (state: TuroPricingState) => state.listedVehicles,\n vehiclePricing: (state: TuroPricingState) => state.vehiclePricing,\n outlookDays: (state: TuroPricingState) => state.outlookDays,\n};\n\nconst mutations = {\n [types.SET_INIT](state: TuroPricingState, init) {\n state.init = init;\n },\n [types.SET_TURO_PRICING_LOADING](state: TuroPricingState, loading) {\n state.loading[loading.subject] = loading.loading;\n },\n [types.SET_TURO_PRICING_VEHICLES](state: TuroPricingState, vehicles) {\n state.allVehicles = vehicles;\n\n const listed = filter(vehicles, (v) => get(v, 'status.status.value') === 'LISTED');\n\n const prices = [];\n for (let i = 0; i < state.outlookDays; i++) {\n prices.push({\n date: null,\n price: null,\n selected: false,\n vid: null,\n });\n }\n state.listedVehicles = map(listed, (l) => ({\n id: l.id,\n image: get(l, 'image.originalImageUrl'),\n name: l.name,\n status: get(l, 'status.status.value'),\n vin: get(l, 'vin'),\n year: get(l, 'year'),\n make: get(l, 'make'),\n model: get(l, 'model'),\n prices,\n pricesSet: false,\n rowSelected: false,\n }));\n\n state.snoozedVehicles = filter(vehicles, (v) => get(v, 'status.status.value') === 'SNOOZED');\n },\n [types.SET_TURO_VEHICLE_DAILY_PRICING](state: TuroPricingState, data) {\n const vehicleId = get(data, 'data.vehicleId');\n let pricing = get(data, 'pricing');\n\n const vehicleIndex = findIndex(state.listedVehicles, (v) => v.id.toString() === vehicleId.toString());\n\n\n pricing = slice(pricing, 0, state.outlookDays);\n\n // noinspection JSUnusedLocalSymbols\n pricing = flatMap(pricing, (p, index) => ({\n price: p.price,\n selected: false,\n vid: vehicleId,\n date: p.date,\n }));\n\n if (vehicleIndex >= 0) {\n state.listedVehicles[vehicleIndex].prices = pricing;\n }\n\n state.vehiclePricing.push({id: vehicleId, prices: pricing});\n },\n};\n\nconst actions = {\n\n fetchTuroMe({commit}, turo_uuid) {\n commit('SET_TURO_PRICING_LOADING', {subject: 'turo_me', loading: true});\n\n axios.get(`/v1/connections/turo/${turo_uuid}/me`)\n .then((response) => {\n commit('SET_TURO_PRICING_VEHICLES', get(response, 'data.me.vehicles'));\n\n EventBus.$emit('fetch-turo-me-success', response.data.me.vehicles);\n }).catch((e) => {\n if (e.response.status === 400 || e.response.status === 403) {\n EventBus.$emit('fetch-turo-connection-failed-400', e.response.data.message);\n }\n\n if (e.response.status === 428) {\n EventBus.$emit('fetch-turo-connection-failed-428', e.response.data.message);\n }\n }).finally(() => {\n commit('SET_TURO_PRICING_LOADING', {subject: 'turo_me', loading: false});\n });\n },\n\n fetchVehicleDailyPrice({commit, rootGetters}, data) {\n commit('SET_TURO_PRICING_LOADING', {subject: 'fetchVehicleDailyPrice', loading: true});\n\n const query = `?start=${data.start}&end=${data.end}&vehicleId=${data.vehicleId}`;\n axios.get(`/v1/company/${rootGetters['company/company'].uuid}/connections/turo/${data.turo_uuid}/vehicle/${data.vehicleId}/daily_price${query}`)\n .then((response) => {\n commit('SET_TURO_VEHICLE_DAILY_PRICING', get(response, 'data'));\n EventBus.$emit('fetch-turo-vehicle-daily-pricing-success', get(response, 'data'));\n }).catch((e) => {\n console.dir(e);\n if (e.response.status === 429) {\n EventBus.$emit('turo-too-many-requests-429', data);\n }\n }).finally(() => {\n commit('SET_TURO_PRICING_LOADING', {subject: 'fetchVehicleDailyPrice', loading: false});\n });\n },\n\n updateVehiclesDailyPrice({commit, rootGetters}, data) {\n commit('SET_TURO_PRICING_LOADING', {subject: 'updateVehiclesDailyPrice', loading: true});\n\n axios.post(`/v1/company/${rootGetters['company/company'].uuid}/connections/turo/${data.turo_uuid}/daily_price`, data)\n .then((response) => {\n EventBus.$emit('update-turo-vehicle-daily-pricing-success', get(response, 'data'));\n }).catch((e) => {\n console.dir(e);\n if (e.response.status === 400 || e.response.status === 403) {\n EventBus.$emit('create-turo-connection-failed-400', e.response.data.message);\n }\n }).finally(() => {\n commit('SET_TURO_PRICING_LOADING', {subject: 'updateVehiclesDailyPrice', loading: false});\n });\n },\n\n};\n\nexport default {\n namespaced: true,\n state,\n mutations,\n actions,\n getters,\n};\n","import axios from 'axios';\nimport { get } from 'lodash';\nimport * as types from '../mutation-types';\n\nexport interface TuroResearchState {\n init: boolean;\n loading: Record<string, boolean>;\n locations: any[];\n makes: any[];\n researchList: any[];\n}\n\nconst state: TuroResearchState = {\n init: false,\n\n loading: {\n locations: false,\n makes: false,\n research: false,\n },\n locations: [],\n makes: [],\n researchList: [],\n};\n\nconst getters = {\n turoInit: (state) => state.init,\n loading: (state) => state.loading,\n locations: (state) => state.locations,\n makes: (state) => state.makes,\n researchList: (state) => state.researchList,\n};\n\nconst mutations = {\n [types.SET_INIT](state, init) {\n state.init = init;\n },\n [types.SET_TURO_RESEARCH_LOADING](state, loading) {\n state.loading[loading.subject] = loading.loading;\n },\n [types.SET_TURO_ALL_VEHICLE_MAKES](state, makes) {\n state.makes = makes;\n },\n [types.SET_TURO_ALL_DELIVERY_LOCATIONS](state, locations) {\n state.locations = locations;\n },\n [types.SET_TURO_RESEARCH_SEARCH_LIST](state, list) {\n state.researchList = list;\n },\n};\n\nconst actions = {\n\n /**\n * Fetch delivery locations\n *\n * @param commit\n * @param rootGetters\n */\n fetchDeliveryLocations({ commit, rootGetters }) {\n commit('SET_TURO_RESEARCH_LOADING', { subject: 'locations', loading: true });\n\n axios.get(`/v1/company/${rootGetters['company/company'].uuid}/connections/turo/delivery-locations`)\n .then((response) => {\n commit('SET_TURO_ALL_DELIVERY_LOCATIONS', get(response, 'data.locations'));\n }).catch((e) => {\n console.dir(e);\n }).finally(() => {\n commit('SET_TURO_RESEARCH_LOADING', { subject: 'locations', loading: false });\n });\n },\n\n\n /**\n * Fetch makes\n *\n * @param commit\n * @param rootGetters\n */\n fetchMakes({ commit, rootGetters }) {\n commit('SET_TURO_RESEARCH_LOADING', { subject: 'makes', loading: true });\n\n axios.get(`/v1/company/${rootGetters['company/company'].uuid}/connections/turo/fetch-makes`)\n .then((response) => {\n commit('SET_TURO_ALL_VEHICLE_MAKES', get(response, 'data.makes'));\n }).catch((e) => {\n console.dir(e);\n }).finally(() => {\n commit('SET_TURO_RESEARCH_LOADING', { subject: 'makes', loading: false });\n });\n },\n\n\n /**\n * Start Turo research\n *\n * @param state\n * @param commit\n * @param rootGetters\n * @param {Object} data\n */\n startResearch({ state, commit, rootGetters }, data) {\n commit('SET_TURO_RESEARCH_LOADING', { subject: 'research', loading: true });\n\n axios.post(`/v1/company/${rootGetters['company/company'].uuid}/connections/turo/research`, data)\n .then((response) => {\n commit('SET_TURO_RESEARCH_SEARCH_LIST', get(response, 'data.list.list'));\n }).catch((e) => {\n console.dir(e);\n }).finally(() => {\n commit('SET_TURO_RESEARCH_LOADING', { subject: 'research', loading: false });\n });\n },\n\n};\n\nexport default {\n namespaced: true,\n state,\n mutations,\n actions,\n getters,\n};\n","import axios from 'axios';\nimport Form from 'vform';\nimport {EventBus} from '@/plugins/eventBus';\nimport * as types from '../mutation-types';\nimport {push} from 'notivue';\n\nexport interface TwilioState {\n loading: Record<string, boolean>;\n form: Form;\n verifyCode: string;\n codeSentSuccess: boolean;\n codeCheckSuccess: boolean;\n}\n\nconst state: TwilioState = {\n loading: {\n start_verify: false,\n check_verify: false,\n },\n\n form: new Form(),\n verifyCode: '',\n codeSentSuccess: false,\n codeCheckSuccess: false,\n};\n\nconst getters = {\n loading: state => state.loading,\n verifyCode: state => state.verifyCode,\n codeSentSuccess: state => state.codeSentSuccess,\n codeCheckSuccess: state => state.codeCheckSuccess,\n checkBtnReady: state => state.verifyCode.length === 6,\n};\n\nconst mutations = {\n [types.SET_TWILIO_LOADING](state, loading) {\n state.loading[loading.subject] = loading.loading;\n },\n [types.SET_VERIFY_CODE](state, code) {\n state.verifyCode = code;\n },\n};\n\nconst actions = {\n\n startTwilioVerify({commit, rootGetters}, stripe_id) {\n commit('SET_TWILIO_LOADING', {subject: 'start_verify', loading: true});\n axios.post(`/v1/company/${rootGetters['company/company'].uuid}/start-twilio-verify`, {\n stripe_id,\n })\n .then(() => {\n state.codeSentSuccess = true;\n\n push.success({\n message: 'SMS code sent',\n });\n }).catch((e) => {\n state.form.errors.set(e.response.data.errors);\n }).finally(() => {\n commit('SET_TWILIO_LOADING', {subject: 'start_verify', loading: false});\n });\n },\n\n checkTwilioVerify({state, commit, rootGetters}, stripe_id) {\n commit('SET_TWILIO_LOADING', {subject: 'check_verify', loading: true});\n axios.post(`/v1/company/${rootGetters['company/company'].uuid}/check-twilio-verify`, {\n stripe_id,\n code: state.verifyCode,\n })\n .then(() => {\n state.codeCheckSuccess = true;\n EventBus.$emit('success-message-text', 'SMS Verified');\n }).catch((e) => {\n push.error({\n message: 'Code incorrect',\n });\n }).finally(() => {\n commit('SET_TWILIO_LOADING', {subject: 'check_verify', loading: false});\n });\n },\n\n};\n\nexport default {\n namespaced: true,\n state,\n mutations,\n actions,\n getters,\n};\n","import axios from 'axios';\nimport {Form} from '@/plugins/FWForms/index';\nimport {EventBus} from '@/plugins/eventBus';\nimport {get} from 'lodash';\nimport * as types from '../mutation-types';\n\nexport interface TwistedRoadState {\n init: boolean;\n loading: Record<string, boolean>;\n form: Form<any>;\n connections: any[];\n vehicles: any[];\n}\n\nconst state: TwistedRoadState = {\n init: false,\n loading: {\n login: false,\n vehicles: false,\n matching: false,\n disconnect: false,\n toggleActive: false,\n },\n form: new Form(),\n connections: [],\n vehicles: [],\n};\n\nconst getters = {\n init: state => state.init,\n loading: state => state.loading,\n form: state => state.form,\n connections: state => state.connections,\n vehicles: state => state.vehicles,\n};\n\nconst mutations = {\n [types.SET_TWISTED_ROAD_LOADING](state, loading) {\n state.loading[loading.subject] = loading.loading;\n },\n [types.SET_TWISTED_ROAD_CONNECTIONS](state, connections) {\n state.connections = connections;\n },\n [types.SET_TWISTED_ROAD_VEHICLES](state, vehicles) {\n state.vehicles = vehicles;\n },\n};\n\nconst actions = {\n\n\n /**\n * Get tax categories\n *\n * @param commit\n * @param {Object} payload\n */\n login({commit}, payload) {\n commit('SET_TWISTED_ROAD_LOADING', {subject: 'login', loading: true});\n\n axios.post('/v1/connections/twisted-road/login', payload)\n .then(() => {\n EventBus.$emit('create-twisted-road-success');\n }).catch(() => {\n }).finally(() => {\n commit('SET_TWISTED_ROAD_LOADING', {subject: 'login', loading: false});\n });\n },\n\n disconnect({commit}, account) {\n commit('SET_TWISTED_ROAD_LOADING', {subject: 'disconnect', loading: true});\n\n axios.delete(`/v1/connections/twisted-road/${account.uuid}`)\n .then(() => {\n EventBus.$emit('delete-twisted-road-success');\n }).catch(() => {\n }).finally(() => {\n commit('SET_TWISTED_ROAD_LOADING', {subject: 'disconnect', loading: false});\n });\n },\n\n toggleActive({commit}, account) {\n commit('SET_TWISTED_ROAD_LOADING', {subject: 'toggleActive', loading: true});\n\n axios.put(`/v1/connections/twisted-road/${account.uuid}/toggle-active`)\n .then(() => {\n }).catch(() => {\n }).finally(() => {\n commit('SET_TWISTED_ROAD_LOADING', {subject: 'toggleActive', loading: false});\n });\n },\n\n fetchVehicles({commit}, payload) {\n commit('SET_TWISTED_ROAD_LOADING', {subject: 'vehicles', loading: true});\n\n axios.post('/v1/connections/twisted-road/vehicles', payload)\n .then((response) => {\n commit('SET_TWISTED_ROAD_VEHICLES', get(response, 'data.vehicles', []));\n }).catch(() => {\n }).finally(() => {\n commit('SET_TWISTED_ROAD_LOADING', {subject: 'vehicles', loading: false});\n });\n },\n\n /**\n * Match TR Vehicles\n *\n * @param commit\n * @param {Object} data\n */\n matchVehicle({commit}, data) {\n commit('SET_TWISTED_ROAD_LOADING', {subject: 'vehicles', loading: true});\n\n axios.post('/v1/connections/twisted-road/match-vehicle', data)\n .then(() => {\n EventBus.$emit('match-twisted-road-vehicle-success');\n }).catch(() => {\n }).finally(() => {\n commit('SET_TWISTED_ROAD_LOADING', {subject: 'vehicles', loading: false});\n });\n },\n\n /**\n * Match TR Vehicles\n *\n * @param commit\n * @param {Object} data\n */\n unmatchVehicle({commit}, data) {\n commit('SET_TWISTED_ROAD_LOADING', {subject: 'matching', loading: true});\n\n axios.post('/v1/connections/twisted-road/remove-matched-vehicle', data)\n .then(() => {\n EventBus.$emit('match-twisted-road-vehicle-success');\n }).catch(() => {\n }).finally(() => {\n commit('SET_TWISTED_ROAD_LOADING', {subject: 'matching', loading: false});\n });\n },\n};\n\nexport default {\n namespaced: true,\n state,\n mutations,\n actions,\n getters,\n};\n","import axios from 'axios';\nimport {EventBus} from '@/plugins/eventBus';\nimport {Form} from '@/plugins/FWForms/index';\nimport * as types from '../mutation-types';\nimport {performApiRequest} from '@/store/helpers/vuex-helpers';\nimport {VehicleClass, VehicleMake, VehicleModel} from '@/types';\nimport {push} from 'notivue';\n\ninterface VehicleStatesResponse {\n states: string[];\n}\n\nexport type VehicleState = {\n loading: Record<string, boolean>,\n vehicleClassCreated: boolean,\n vehicleClassesLoaded: boolean,\n vehicleClassForm: Form<any>,\n vehicleMakes: VehicleMake[],\n vehicleModels: VehicleModel[],\n vehicleClasses: VehicleClass[],\n vehicleClass: VehicleClass | {},\n}\n\nconst state: VehicleState = {\n loading: {\n makes: false,\n models: false,\n fetchOdometer: false,\n classes: false,\n class: false,\n },\n vehicleClassCreated: false,\n vehicleClassesLoaded: false,\n vehicleClassForm: new Form(),\n vehicleMakes: [],\n vehicleModels: [],\n vehicleClasses: [],\n vehicleClass: {},\n};\n\nconst getters = {\n vehicleMakes: (state: VehicleState) => state.vehicleMakes,\n vehicleModels: (state: VehicleState) => state.vehicleModels,\n vehicleLoading: (state: VehicleState) => state.loading,\n vehicleClasses: (state: VehicleState) => state.vehicleClasses,\n vehicleClass: (state: VehicleState) => state.vehicleClass,\n vehicleClassForm: (state: VehicleState) => state.vehicleClassForm,\n vehicleClassCreated: (state: VehicleState) => state.vehicleClassCreated,\n};\n\nconst mutations = {\n [types.SET_VEHICLES_LOADING](state: VehicleState, loading: { subject: string, loading: boolean }) {\n state.loading[loading.subject] = loading.loading;\n },\n [types.SET_VEHICLE_MAKES](state: VehicleState, makes: VehicleMake[]) {\n state.vehicleMakes = makes;\n },\n [types.SET_VEHICLE_MODELS](state: VehicleState, models: VehicleModel[]) {\n state.vehicleModels = models;\n },\n [types.SET_VEHICLE_CLASS_CREATED](state: VehicleState, value: boolean) {\n state.vehicleClassCreated = value;\n },\n [types.SET_VEHICLE_CLASSES](state: VehicleState, classes: VehicleClass[]) {\n state.vehicleClassesLoaded = true;\n state.vehicleClasses = classes;\n },\n [types.SET_VEHICLE_CLASS](state: VehicleState, vehicleClass: VehicleClass) {\n state.vehicleClass = vehicleClass;\n },\n [types.SET_VEHICLE_FORM_ERRORS](state: VehicleState, errors: any) {\n state.vehicleClassForm.errors.set(errors);\n },\n [types.CLEAR_VEHICLE_FORM_ERRORS](state: VehicleState, form_field: string | null) {\n if (form_field === null || form_field === undefined) {\n state.vehicleClassForm.errors.clear();\n } else {\n state.vehicleClassForm.errors.clear(form_field);\n }\n },\n};\n\nconst actions = {\n\n /**\n * Fetch vehicle makes\n */\n async fetchVehicleMakes({commit}, refresh = false) {\n if (state.vehicleMakes.length > 0 && !refresh) {\n return;\n }\n\n try {\n const responseData = await performApiRequest(commit, 'SET_VEHICLES_LOADING', 'makes', () => axios.get('/v1/vehicles/makes'));\n commit('SET_VEHICLE_MAKES', responseData.makes);\n } catch (error) {\n }\n },\n\n /**\n * Fetch vehicle models\n */\n async fetchVehicleModels({commit}, make: string) {\n try {\n const responseData = await performApiRequest(commit, 'SET_VEHICLES_LOADING', 'models', () => axios.get(`/v1/vehicles/makes/${make}/models`));\n commit('SET_VEHICLE_MODELS', responseData.models);\n } catch (error) {\n }\n },\n\n\n /**\n * Get vehicle classes\n */\n async getVehicleClasses({commit}, refresh = false) {\n if (state.vehicleClassesLoaded && !refresh) {\n return;\n }\n\n try {\n const responseData = await performApiRequest(commit, 'SET_VEHICLES_LOADING', 'classes', () => axios.get('/v1/vehicle-classes'));\n commit('SET_VEHICLE_CLASSES', responseData.classes);\n } catch (error) {\n }\n },\n\n\n /**\n * Get vehicle class\n */\n async getClass({commit}, uuid: string) {\n try {\n const responseData = await performApiRequest(commit, 'SET_VEHICLES_LOADING', 'class', () => axios.get(`/v1/vehicle-classes/${uuid}`));\n commit('SET_VEHICLE_CLASS', responseData.class);\n } catch (error) {\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n }\n },\n\n\n /**\n * Create a vehicle class\n */\n async createClass({commit, dispatch}, vehicleClass: VehicleClass) {\n try {\n await performApiRequest(commit, 'SET_VEHICLES_LOADING', 'class', () => axios.post('/v1/vehicle-classes', vehicleClass));\n EventBus.$emit('create-vehicle-class-success');\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'Vehicle class created successfully!',\n });\n commit('SET_VEHICLE_CLASS_CREATED', true);\n dispatch('getVehicleClasses', true);\n } catch (error) {\n commit('SET_VEHICLE_FORM_ERRORS', error.response.data.errors);\n }\n },\n\n\n /**\n * Update a vehicle class\n */\n async updateClass({commit, dispatch}, vehicleClass: VehicleClass) {\n try {\n const responseData = await performApiRequest(commit, 'SET_VEHICLES_LOADING', 'class', () => axios.put(`/v1/vehicle-classes/${vehicleClass.uuid}`, vehicleClass));\n commit('SET_VEHICLE_CLASS', responseData.class);\n dispatch('getVehicleClasses', true);\n EventBus.$emit('update-vehicle-class-success');\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'Vehicle class saved successfully!',\n });\n } catch (error) {\n state.vehicleClassForm.errors.set(error.response.data.errors);\n }\n },\n\n\n /**\n * Create a vehicle class\n */\n async deleteClass({commit}, uuid: string) {\n try {\n await performApiRequest(commit, 'SET_VEHICLES_LOADING', 'class', () => axios.delete(`/v1/vehicle-classes/${uuid}`));\n EventBus.$emit('delete-vehicle-class-success');\n } catch (error) {\n }\n },\n\n\n /**\n * Get a vehicle state\n */\n async getStates({commit}, v_id: string) {\n try {\n const responseData = await performApiRequest<VehicleStatesResponse>(commit, 'SET_VEHICLES_LOADING', 'getStates', () => axios.get(`/v1/vehicles/${v_id}/states`));\n EventBus.$emit('fetch-vehicle-states-success', responseData.states);\n } catch (error) {\n }\n },\n\n\n /**\n * Fetch a vehicles odometer\n */\n async fetchOdometer({commit}, v_id: string) {\n try {\n const responseData = await performApiRequest(commit, 'SET_VEHICLES_LOADING', 'fetchOdometer', () => axios.get(`/v1/vehicles/${v_id}/odometer`));\n EventBus.$emit('fetch-odometer-reading-success', responseData.vehicle);\n EventBus.$emit('fetch-vehicle-states-success', responseData.states);\n } catch (error) {\n if (error.response.status === 408) {\n EventBus.$emit('tesla-is-asleep', error.response.data.tesla);\n EventBus.$emit('show-tesla-wake-options', error.response.data.tesla);\n }\n push.error({\n message: error?.response?.data?.message || 'There was an error',\n });\n }\n },\n};\n\nexport default {\n namespaced: true,\n state,\n mutations,\n actions,\n getters,\n};\n","import axios from 'axios';\nimport {uniqBy} from 'lodash';\nimport * as types from '../mutation-types';\nimport {performApiRequest} from '@/store/helpers/vuex-helpers';\nimport {Pagination, WhatsNew, WhatsNewFeedback} from '@/types';\n\n\nexport interface WhatsNewState {\n loading: Record<string, boolean>,\n count: number,\n nextWhatsNew: number,\n nextWhatsLast: number,\n whatsNew: WhatsNew[],\n images: any[],\n openSidebar: boolean,\n}\n\n\nconst state: WhatsNewState = {\n loading: {\n sendFeedback: false,\n count: false,\n get: false,\n images: false,\n update: false,\n seen: false,\n },\n openSidebar: false,\n count: 0,\n nextWhatsNew: 1,\n nextWhatsLast: 1,\n whatsNew: [],\n images: [],\n};\n\nconst getters = {\n loading: (state: WhatsNewState) => state.loading,\n count: (state: WhatsNewState) => state.count,\n images: (state: WhatsNewState) => state.images,\n whatsNew: (state: WhatsNewState) => state.whatsNew,\n nextWhatsNew: (state: WhatsNewState) => state.nextWhatsNew,\n nextWhatsLast: (state: WhatsNewState) => state.nextWhatsLast,\n openSidebar: (state: WhatsNewState) => state.openSidebar,\n};\n\nconst mutations = {\n [types.SET_WHATS_NEW_LOADING](state: WhatsNewState, loading: { subject: string, loading: boolean }) {\n state.loading[loading.subject] = loading.loading;\n },\n [types.SET_WHATS_NEW_COUNT](state: WhatsNewState, count: number) {\n state.count = count;\n },\n [types.SET_SHOW_WHATS_NEW_SIDEBAR](state: WhatsNewState, isShown: boolean = false) {\n state.openSidebar = isShown;\n\n setTimeout(() => {\n state.openSidebar = false;\n }, 300);\n },\n [types.SET_WHATS_NEW_IMAGES](state: WhatsNewState, images: any[]) {\n state.images = images;\n },\n [types.SET_WHATS_NEW](state: WhatsNewState, whatsNewPaginateObject: Pagination) {\n const data: WhatsNew[] = whatsNewPaginateObject.data || [];\n\n state.whatsNew = uniqBy([...state.whatsNew, ...data], (w) => w.uuid);\n state.nextWhatsNew = (whatsNewPaginateObject.current_page || 0) + 1;\n state.nextWhatsLast = whatsNewPaginateObject.last_page || 1;\n },\n [types.MERGE_WHATS_NEW](state: WhatsNewState, whatsNew: WhatsNew) {\n if (whatsNew.uuid) {\n const wnIndex = state.whatsNew.findIndex(w => w.uuid === whatsNew.uuid);\n if (wnIndex >= 0) {\n state.whatsNew[wnIndex] = whatsNew;\n }\n }\n },\n};\n\nconst actions = {\n\n /**\n * Get what's new count\n */\n async getWhatsNewCount({commit}) {\n try {\n const responseData = await performApiRequest(commit, 'SET_WHATS_NEW_LOADING', 'count', () => axios.get('/v1/whats-new/count'));\n commit(types.SET_WHATS_NEW_COUNT, responseData.count);\n } catch (error) {\n console.error(error)\n }\n },\n\n\n /**\n * Get what's new\n */\n async getWhatsNew({commit, state}, allPages = false) {\n const shouldFetch = allPages || state.nextWhatsNew <= state.nextWhatsLast;\n\n if (!shouldFetch) return;\n\n if (allPages) {\n state.nextWhatsNew = 1;\n }\n\n try {\n // Fetch data with a reusable helper function\n const responseData = await performApiRequest(\n commit,\n 'SET_WHATS_NEW_LOADING',\n 'get',\n () => axios.get(`/v1/whats-new`, {params: {page: state.nextWhatsNew, allPages}})\n );\n\n // Commit the fetched data\n commit(types.SET_WHATS_NEW, responseData.whatsNew);\n } catch (error) {\n console.error('Error fetching Whats New:', error);\n }\n },\n\n /**\n * Get what's new images\n */\n async getImages({commit}) {\n try {\n const responseData = await performApiRequest(commit, 'SET_WHATS_NEW_LOADING', 'images', () => axios.get('/v1/whats-new/images'));\n commit(types.SET_WHATS_NEW_IMAGES, responseData.files);\n } catch (error) {\n console.error(error)\n }\n },\n\n /**\n * Send what's new feedback\n */\n async sendFeedback({commit}, data: WhatsNewFeedback) {\n try {\n const responseData = await performApiRequest(commit, 'SET_WHATS_NEW_LOADING', 'sendFeedback', () => axios.post(`/v1/whats-new/${data.uuid}/feedback`, data));\n commit(types.MERGE_WHATS_NEW, responseData.whatsNew);\n } catch (error) {\n console.error(error)\n }\n },\n\n /**\n * Add what's new\n */\n async addWhatsNew({commit}, data: WhatsNew) {\n try {\n return await performApiRequest(commit, 'SET_WHATS_NEW_LOADING', 'sendFeedback', () => axios.post('/v1/whats-new', data));\n } catch (error) {\n console.error(error)\n }\n },\n\n /**\n * Update what's new\n */\n async updateWhatsNew({commit}, data: WhatsNew) {\n try {\n return await performApiRequest(commit, 'SET_WHATS_NEW_LOADING', 'update', () => axios.put(`/v1/whats-new/${data.uuid}`, data));\n } catch (error) {\n console.error(error)\n }\n },\n\n\n /**\n * Mark what's new as seen\n */\n async markSeen({commit}) {\n try {\n await performApiRequest(commit, 'SET_WHATS_NEW_LOADING', 'seen', () => axios.post('/v1/whats-new/seen'));\n commit(types.SET_WHATS_NEW_COUNT, 0);\n } catch (error) {\n console.error(error)\n }\n },\n};\n\nexport default {\n namespaced: true,\n state,\n mutations,\n actions,\n getters,\n};\n","import axios from 'axios';\nimport {EventBus} from '@/plugins/eventBus';\nimport {get} from 'lodash';\nimport * as types from '../mutation-types';\nimport {performApiRequest} from \"@/store/helpers/vuex-helpers\";\n\n\ntype Webhook = {\n created_at: string,\n description: string,\n livemode: boolean,\n metadata: null,\n status: string,\n type: null,\n updated_at: string,\n url: string,\n uuid: string,\n}\n\nexport type WebhookEndpoint = {\n url: string,\n description: string,\n events: Array<string>,\n}\n\nexport interface WebhookState {\n loaded: boolean;\n loading: Record<string, boolean>;\n webhooks: Webhook[]\n webhookEndpoints: WebhookEndpoint[],\n webhookConversations: Array<any>,\n webhook: Webhook,\n webhookEndpoint: WebhookEndpoint,\n webhookEndpointSecret: String,\n}\n\nconst state: WebhookState = {\n loaded: false,\n loading: {\n webhooks: false,\n webhooksUpdate: false,\n webhooksDelete: false,\n webhookConversationResend: false,\n secret: false,\n },\n webhooks: [],\n webhook: null,\n webhookEndpoints: [],\n webhookEndpoint: null,\n webhookConversations: [],\n webhookEndpointSecret: '',\n};\n\n\nconst getters = {\n loaded: (state: WebhookState) => state.loaded,\n loading: (state: WebhookState) => state.loading,\n webhooks: (state: WebhookState) => state.webhooks,\n webhook: (state: WebhookState) => state.webhook,\n webhookEndpoint: (state: WebhookState) => state.webhookEndpoint,\n webhookEndpoints: (state: WebhookState) => state.webhookEndpoints,\n webhookConversations: (state: WebhookState) => state.webhookConversations,\n webhookEndpointSecret: (state: WebhookState) => state.webhookEndpointSecret,\n};\n\n\nconst mutations = {\n [types.SET_WEBHOOKS_LOADING](state: WebhookState, loading: { subject: string, loading: boolean }) {\n state.loading[loading.subject] = loading.loading;\n },\n\n [types.SET_WEBHOOK_ENDPOINTS](state: WebhookState, webhookEndpoints: WebhookEndpoint[]) {\n state.webhookEndpoints = webhookEndpoints;\n },\n [types.SET_WEBHOOK_ENDPOINT](state: WebhookState, webhookEndpoint: WebhookEndpoint) {\n state.webhookEndpoint = webhookEndpoint;\n },\n\n [types.SET_WEBHOOKS_CONVERSATIONS](state: WebhookState, conversations: Array<any>) {\n state.webhookConversations = conversations;\n },\n [types.SET_WEBHOOK_ENDPOINT_SECRET](state: WebhookState, secret: string) {\n state.webhookEndpointSecret = secret;\n },\n};\n\nconst actions = {\n\n /**\n * Get webhook endpoints\n */\n getWebhookEndpoints({commit}) {\n commit('SET_WEBHOOKS_LOADING', {subject: 'webhooks', loading: true});\n\n axios.get('/v1/webhook-endpoints')\n .then((response) => {\n commit('SET_WEBHOOK_ENDPOINTS', get(response, 'data.webhookEndpoints'));\n }).catch((e) => {\n console.dir(e);\n }).finally(() => {\n commit('SET_WEBHOOKS_LOADING', {subject: 'webhooks', loading: false});\n });\n },\n\n\n /**\n * Get webhook endpoint\n */\n getWebhookEndpoint({commit}, webhook_uuid: string) {\n commit('SET_WEBHOOKS_LOADING', {subject: 'webhooks', loading: true});\n\n axios.get(`/v1/webhook-endpoints/${webhook_uuid}`)\n .then((response) => {\n commit('SET_WEBHOOK_ENDPOINT', get(response, 'data.webhookEndpoint'));\n }).catch((e) => {\n console.dir(e);\n }).finally(() => {\n commit('SET_WEBHOOKS_LOADING', {subject: 'webhooks', loading: false});\n });\n },\n\n\n /**\n * Add webhook\n */\n async addWebhookEndpoint({commit}, data: WebhookEndpoint) {\n return await performApiRequest(commit, 'SET_WEBHOOKS_LOADING', 'webhooks', () => axios.post('/v1/webhook-endpoints', data));\n },\n\n\n /**\n * Update webhook\n */\n updateWebhookEndpoint({commit}, webhook: Webhook) {\n commit('SET_WEBHOOKS_LOADING', {subject: 'webhooksUpdate', loading: true});\n\n axios.put(`/v1/webhook-endpoints/${webhook.uuid}`, webhook)\n .then(() => {\n EventBus.$emit('update-webhook-endpoint-success');\n }).catch((e) => {\n console.dir(e);\n }).finally(() => {\n commit('SET_WEBHOOKS_LOADING', {subject: 'webhooksUpdate', loading: false});\n });\n },\n\n /**\n * Get webhook conversations\n */\n getWebhookConversations({commit}, uuid: string) {\n commit('SET_WEBHOOKS_LOADING', {subject: 'webhooks', loading: true});\n\n axios.get(`/v1/webhook-endpoints/${uuid}/conversations`)\n .then((response) => {\n commit('SET_WEBHOOKS_CONVERSATIONS', get(response, 'data.conversations'));\n }).catch((e) => {\n console.dir(e);\n }).finally(() => {\n commit('SET_WEBHOOKS_LOADING', {subject: 'webhooks', loading: false});\n });\n },\n\n\n /**\n * Resend webhook conversations\n */\n resendWebhookConversation({commit}, conversation: any) {\n commit('SET_WEBHOOKS_LOADING', {subject: 'webhookConversationResend', loading: true});\n\n axios.post(`/v1/webhooks-conversations/${conversation.uuid}/retry`)\n .then(() => {\n }).catch((e) => {\n console.dir(e);\n }).finally(() => {\n commit('SET_WEBHOOKS_LOADING', {subject: 'webhookConversationResend', loading: false});\n });\n },\n\n\n /**\n * Delete webhook endpoint\n */\n deleteWebhookEndpoint({commit}, webhook: Webhook) {\n commit('SET_WEBHOOKS_LOADING', {subject: 'webhooksDelete', loading: true});\n\n axios.delete(`/v1/webhook-endpoints/${webhook.uuid}`)\n .then(() => {\n commit('SET_WEBHOOKS_CONVERSATIONS', []);\n EventBus.$emit('delete-webhook-endpoint-success');\n }).catch((e) => {\n console.dir(e);\n }).finally(() => {\n commit('SET_WEBHOOKS_LOADING', {subject: 'webhooksDelete', loading: false});\n });\n },\n\n\n /**\n * Fetch webhook endpoints signing secret\n */\n async getWebhookEndpointSecret({commit}, uuid: string) {\n try {\n const responseData = await performApiRequest(commit, 'SET_WEBHOOKS_LOADING', 'secret', () => axios.get(`/v1/webhook-endpoints/${uuid}/secret`));\n commit('SET_WEBHOOK_ENDPOINT_SECRET', responseData.secret);\n } catch (error) {\n throw error;\n }\n },\n};\n\nexport default {\n namespaced: true,\n state,\n mutations,\n actions,\n getters,\n};\n","import axios from 'axios';\nimport {\n DeliveryDistanceResults,\n ProductOrder,\n ProductOrderCosts,\n ProductOrderDates,\n ProductOrderDuration,\n StoreLoaders,\n TenantLocation\n} from '@/types';\nimport {Module} from 'vuex'\nimport * as types from '@/store/mutation-types';\nimport {RootState} from '@/types/RootState';\nimport {CartService} from '@/services/cart.service';\nimport {Form} from '@/plugins/FWForms/index';\nimport {performApiRequest} from '@/store/helpers/vuex-helpers';\nimport router from '@/router';\n\n\nexport interface TenantCheckoutState {\n loading: StoreLoaders,\n dialogs: Record<string, boolean>,\n productOrder: ProductOrder,\n showDeliveryAddressForm: boolean,\n stripePaymentIntent: any,\n tenantCheckoutForm: Form<any>,\n deliveryDistanceResults: DeliveryDistanceResults,\n}\n\n\nconst state: TenantCheckoutState = {\n loading: {\n checkout: false,\n stripe_oauth: false,\n createApiToken: false,\n start2FAVerify: false,\n check2FAVerify: false,\n },\n\n dialogs: {\n stripePayment: false,\n },\n\n stripePaymentIntent: null,\n\n productOrder: {\n version: 'v2',\n l_id: '',\n b_id: '',\n p_id: '',\n dates: {\n start: null,\n end: null,\n },\n costs: {\n vehicle: 0,\n extras: 0,\n requiredExtras: 0,\n delivery: 0,\n taxes: 0,\n discount: 0,\n subtotal: 0,\n grandTotal: 0,\n dueToday: 0,\n securityDepositCredit: 0,\n securityDepositDebit: 0,\n },\n discounts: {\n discounted: false,\n amount: 0,\n value: 0,\n code: null,\n reason: null,\n type: null,\n durationDiscountReason: null,\n durationDiscountAmount: null,\n durationDiscountValue: null,\n },\n duration: {\n seconds: 0,\n minutes: 0,\n hours: 0,\n days: 0,\n weeks: 0,\n months: 0,\n years: 0,\n units: 1,\n },\n customers: [\n {\n isPrimary: true,\n firstName: '',\n lastName: '',\n phone: '',\n email: '',\n dob: '',\n age: null,\n signaturePng: null,\n signFullName: null,\n signInitials: null,\n agreeAdoptSignature: false,\n agreeToS: false,\n },\n ],\n extras: [],\n extrasV2: [],\n requiredExtras: [],\n requiredExtrasV2: {},\n delivery: null,\n delivery_address: null,\n distance_allowance: {\n distance: null,\n unit: 'miles',\n },\n customFields: [],\n cartId: CartService.getCartUuid(),\n },\n\n tenantCheckoutForm: new Form(),\n\n showDeliveryAddressForm: false,\n deliveryDistanceResults: {\n checked: false as boolean,\n valid: false as boolean,\n message: null as string | null,\n distance: null as number | null,\n },\n}\n\n\nconst tenantCheckoutModule: Module<TenantCheckoutState, RootState> = {\n namespaced: true,\n\n state,\n\n getters: {\n loading: (state: TenantCheckoutState) => state.loading,\n dialogs: (state: TenantCheckoutState) => state.dialogs,\n stripePaymentIntent: (state: TenantCheckoutState) => state.stripePaymentIntent,\n productOrder: (state: TenantCheckoutState) => state.productOrder,\n showDeliveryAddressForm: (state: TenantCheckoutState) => state.showDeliveryAddressForm,\n deliveryDistanceResults: (state: TenantCheckoutState) => state.deliveryDistanceResults,\n tenantCheckoutForm: (state: TenantCheckoutState) => state.tenantCheckoutForm,\n },\n\n\n mutations: {\n [types.SET_CHECKOUT_LOADING](state: TenantCheckoutState, loading: { subject: string, loading: boolean }) {\n state.loading[loading.subject] = loading.loading;\n },\n [types.SET_TENANT_CHECKOUT_DATES](state: TenantCheckoutState, dates: ProductOrderDates) {\n console.log('%cSET_TENANT_CHECKOUT_DATES', 'color: red; font-weight: bold;');\n state.productOrder.dates = dates;\n },\n [types.SET_TENANT_CHECKOUT_LOCATION](state: TenantCheckoutState, location: TenantLocation) {\n console.log('%cSET_TENANT_CHECKOUT_LOCATION', 'color: pink; font-weight: bold;');\n state.productOrder.delivery = location;\n },\n [types.SET_TENANT_CHECKOUT_DELIVERY_ADDRESS_FORM_SHOW](state: TenantCheckoutState, payload) {\n state.showDeliveryAddressForm = payload;\n },\n [types.SET_TENANT_CHECKOUT_STRIPE_PAYMENT_INTENT](state: TenantCheckoutState, payload) {\n state.stripePaymentIntent = payload;\n },\n [types.SET_TENANT_CHECKOUT_DIALOG](state: TenantCheckoutState, payload) {\n if (payload.topic === 'stripe-payment') {\n state.dialogs.stripePayment = payload.value;\n }\n },\n [types.SET_TENANT_CHECKOUT_DURATIONS](state: TenantCheckoutState, payload: ProductOrderDuration) {\n state.productOrder.duration = payload;\n },\n [types.SET_TENANT_CHECKOUT_BOOKING_ID](state: TenantCheckoutState, payload: string) {\n state.productOrder.b_id = payload;\n },\n [types.SET_TENANT_CHECKOUT_CUSTOM_ORDER_FIELDS](state: TenantCheckoutState, payload) {\n state.productOrder.customFields = payload;\n },\n [types.SET_TENANT_CHECKOUT_CUSTOMER_TOS_AGREE](state: TenantCheckoutState, data: {\n index: number,\n agreeToS: boolean\n }) {\n state.productOrder.customers[data.index].agreeToS = data.agreeToS;\n },\n [types.SET_TENANT_CHECKOUT_COSTS](state: TenantCheckoutState, payload: ProductOrderCosts) {\n state.productOrder.costs = payload;\n },\n [types.SET_TENANT_CHECKOUT_LISTING_ID](state: TenantCheckoutState, payload: string) {\n state.productOrder.l_id = payload;\n },\n [types.SET_TENANT_CHECKOUT_CUSTOMER_BY_INDEX](state: TenantCheckoutState, data: {\n index: number,\n customer: any\n }) {\n state.productOrder.customers[data.index] = data.customer;\n },\n [types.SET_TENANT_CHECKOUT_CUSTOMERS](state: TenantCheckoutState, payload) {\n state.productOrder.customers = payload;\n },\n [types.SET_TENANT_CHECKOUT_EXTRAS_V2](state: TenantCheckoutState, payload) {\n console.dir('SET_TENANT_CHECKOUT_EXTRAS_V2');\n state.productOrder.extrasV2 = payload;\n },\n [types.SET_TENANT_CHECKOUT_REQUIRED_EXTRAS_V2](state: TenantCheckoutState, payload) {\n if (!state.productOrder.requiredExtrasV2) {\n state.productOrder.requiredExtrasV2 = {};\n }\n\n state.productOrder.requiredExtrasV2[payload.index] = payload.extra;\n },\n\n [types.SET_TENANT_CHECKOUT_REQUIRED_EXTRAS](state: TenantCheckoutState, data) {\n if (data.requiredExtras) {\n state.productOrder.requiredExtras = data.requiredExtras.map(e => e.extras[0]);\n }\n\n if (data.requiredExtrasV2) {\n state.productOrder.requiredExtrasV2 = data.requiredExtrasV2.map(e => {\n return {\n parentUuid: e.uuid,\n choice: e.options[0],\n };\n });\n }\n },\n [types.SET_TENANT_CHECKOUT_ORDER_DELIVERY_ADDRESS](state: TenantCheckoutState, address) {\n state.productOrder.delivery_address = address;\n },\n [types.SET_TENANT_CHECKOUT_ORDER_DISTANCE_ALLOWANCE](state: TenantCheckoutState, payload: {\n distance: number,\n unit: string\n }) {\n state.productOrder.distance_allowance = payload;\n },\n [types.RESET_TENANT_CHECKOUT_DELIVERY_RESULTS](state: TenantCheckoutState) {\n state.deliveryDistanceResults = {\n checked: false,\n valid: false,\n message: null,\n distance: null,\n };\n },\n [types.SET_TENANT_CHECKOUT_DELIVERY_RESULTS](state: TenantCheckoutState, payload: DeliveryDistanceResults) {\n state.deliveryDistanceResults = payload;\n },\n [types.SET_TENANT_CHECKOUT_DISCOUNT](state, coupon) {\n console.dir(coupon);\n\n state.productOrder.discounts = {\n discounted: true,\n value: coupon?.value,\n code: coupon?.code,\n amount: coupon?.amount,\n reason: coupon?.reason,\n type: coupon?.type,\n durationDiscountReason: null,\n durationDiscountAmount: null,\n durationDiscountValue: null,\n };\n },\n [types.RESET_TENANT_CHECKOUT_DISCOUNT](state) {\n state.tenantCheckoutForm.errors.clear('coupon');\n state.productOrder.discounts = {\n discounted: false,\n code: '',\n amount: 0,\n reason: '',\n type: '',\n value: 0,\n durationDiscountReason: null,\n durationDiscountAmount: null,\n durationDiscountValue: null,\n };\n },\n [types.SET_TENANT_CHECKOUT_FORM_ERRORS](state, errors) {\n state.tenantCheckoutForm.errors.set(errors);\n },\n [types.RESET_TENANT_CHECKOUT_FORM_ERRORS](state) {\n state.tenantCheckoutForm.errors.clear();\n }\n },\n\n actions: {\n setLocation({commit}, location: TenantLocation) {\n commit(types.SET_TENANT_CHECKOUT_LOCATION, location);\n },\n setCustomOrderCheckoutFields({commit}, fields) {\n commit(types.SET_TENANT_CHECKOUT_CUSTOM_ORDER_FIELDS, fields);\n },\n resetDeliveryDistanceResults({commit}) {\n commit(types.RESET_TENANT_CHECKOUT_DELIVERY_RESULTS);\n },\n setDeliveryAddressFormVisibility({commit}, payload: boolean) {\n commit(types.SET_TENANT_CHECKOUT_DELIVERY_ADDRESS_FORM_SHOW, payload);\n },\n setDeliveryDistanceResults({state: TenantCheckoutState}, payload) {\n state.deliveryDistanceResults = payload;\n },\n /**\n * Check the distance between the delivery location and the listing\n */\n async checkDrivingDistance({commit}, location) {\n try {\n await performApiRequest(commit, 'SET_CHECKOUT_LOADING', 'checkout', () => axios.post('/v1/verify-driving-distance', location));\n commit(types.SET_TENANT_CHECKOUT_DELIVERY_RESULTS, {\n checked: true,\n valid: true,\n });\n } catch (e: any) {\n commit(types.SET_TENANT_CHECKOUT_DELIVERY_RESULTS, {\n checked: true,\n valid: false,\n message: e.response?.data?.message || 'There was an error checking the driving distance.',\n });\n }\n },\n async verifyPayment({commit, rootGetters}, paymentIntentId: string) {\n try {\n return await performApiRequest(commit, 'SET_CHECKOUT_LOADING', 'checkout', () => axios.get(`/v1/company/${rootGetters['company/company'].uuid}/verify-payment-intent/${paymentIntentId}`));\n } catch (error) {\n console.error('error');\n console.dir(error);\n }\n },\n async tenantCheckout({commit, rootGetters, state: TenantCheckoutState}) {\n try {\n const paymentStrategy = rootGetters['company/company']?.meta?.payment_strategy;\n const paymentProvider = rootGetters['company/company']?.payment_profile?.provider;\n const notingDueToday = state.productOrder.costs.dueToday === 0;\n\n const responseData = await performApiRequest(commit, 'SET_CHECKOUT_LOADING', 'checkout', () => axios.post('/v1/checkout', state.productOrder));\n\n // if there is no payment provider, redirect to the success page\n if (paymentProvider === null || (paymentProvider !== 'square' && paymentProvider !== 'stripe') || notingDueToday) {\n // send to checkout success page\n router.push({\n name: 'reservations.complete',\n query: {\n b_id: responseData?.b_id,\n l_id: responseData?.l_id,\n company: rootGetters['company/company']?.slug\n }\n }).catch(() => {\n });\n return;\n }\n\n // If payment provider is Square, redirect to Square payment page\n if (paymentProvider === 'square') {\n window.location.href = responseData?.redirect;\n }\n\n if (responseData?.redirect) {\n window.location.href = responseData?.redirect;\n return;\n }\n\n\n // if payment provider is Stripe\n if (paymentProvider === 'stripe') {\n const sessionId = responseData?.StripeSession?.id;\n const customer = responseData?.customer;\n const stripePaymentMethod = 'payment_intent';\n\n if (stripePaymentMethod === 'payment_intent') {\n // EventBus.$emit('set-booking-id', get(response, 'data.b_id'));\n // EventBus.$emit('set-listing-id', get(response, 'data.l_id'));\n // EventBus.$emit('open-checkout-payment-dialog', get(response, 'data.StripePaymentIntent'));\n\n commit(types.SET_TENANT_CHECKOUT_BOOKING_ID, responseData?.b_id);\n commit(types.SET_TENANT_CHECKOUT_STRIPE_PAYMENT_INTENT, responseData?.StripePaymentIntent);\n commit(types.SET_TENANT_CHECKOUT_DIALOG, {\n topic: 'stripe-payment',\n value: true,\n });\n }\n }\n\n // If payment provider is Stripe, redirect to Stripe payment page\n\n console.dir(responseData);\n\n } catch (error) {\n console.error('error');\n console.dir(error);\n\n // tenantCheckoutForm.errors.record(error.response.data.errors);\n commit(types.SET_TENANT_CHECKOUT_FORM_ERRORS, error.response.data.errors);\n }\n }\n },\n\n}\n\nexport default tenantCheckoutModule;","import axios from 'axios';\nimport * as types from '@/store/mutation-types';\nimport {RootState} from '@/types/RootState';\nimport {performApiRequest} from \"@/store/helpers/vuex-helpers\";\nimport {Module} from 'vuex';\n\nexport interface TagState {\n loading: Record<string, boolean>;\n tags: Record<string, number>;\n}\n\n// state\nconst state: TagState = {\n loading: {\n fetch_tags: false,\n create_tag: false,\n remove_tag: false,\n },\n tags: {},\n};\n\n\nconst mutations = {\n [types.SET_TAGS_LOADING](state: TagState, loading: { subject: string, loading: boolean }) {\n state.loading[loading.subject] = loading.loading;\n },\n [types.SET_TAGS](state: TagState, tags) {\n state.tags = tags;\n },\n};\n\nconst actions = {\n\n async fetchTags({commit}, {forType}) {\n const query = forType ? `?for=${forType}` : '';\n\n try {\n const responseData = await performApiRequest(commit, 'SET_TAGS_LOADING', 'fetch_tags', () => axios.get(`/v1/tags${query}`));\n commit(types.SET_TAGS, responseData.tags);\n } catch (error) {\n }\n },\n\n async createTag({commit}, data: { name: string, forType: string, forId: string }) {\n try {\n await performApiRequest(commit, 'SET_TAGS_LOADING', 'create_tag', () => axios.post('/v1/tags', data));\n } catch (error) {\n commit(types.SET_COUPON_FORM_ERROR, error.response.data?.errors || 'There was an error');\n }\n },\n\n async removeTag({commit}, data: { name: string, customer_id: string }) {\n try {\n await performApiRequest(commit, 'SET_TAGS_LOADING', 'remove_tag', () => axios.post('/v1/tags/remove', data));\n } catch (error) {\n commit(types.SET_COUPON_FORM_ERROR, error.response.data?.errors || 'There was an error');\n }\n },\n};\n\nconst tagsModule: Module<TagState, RootState> = {\n namespaced: true,\n\n state,\n\n getters: {\n loading: (state: TagState) => state.loading,\n tags: (state: TagState) => state.tags,\n },\n\n mutations,\n\n actions,\n}\n\nexport default tagsModule;\n","import {createStore, Store} from 'vuex';\n\nimport affiliate from '@/store/modules/affiliate';\nimport analytics from '@/store/modules/analytics';\nimport app from '@/store/modules/app';\nimport auth from '@/store/modules/auth';\nimport automations from '@/store/modules/automations';\nimport axle from '@/store/modules/axle';\nimport barcode from '@/store/modules/barcode';\nimport booking from '@/store/modules/booking';\nimport bouncie from '@/store/modules/bouncie';\nimport braintree from '@/store/modules/braintree';\nimport cart from '@/store/modules/cart';\nimport checkout from '@/store/modules/checkout';\nimport commissionPartners from '@/store/modules/commission-partners';\nimport company from '@/store/modules/company';\nimport coupon from '@/store/modules/coupon';\nimport custodian from '@/store/modules/custodian';\nimport customFields from '@/store/modules/custom-fields';\nimport defaultProperties from '@/store/modules/default-properties';\nimport document from '@/store/modules/document';\nimport email from '@/store/modules/email';\nimport emailDomainSettings from '@/store/modules/email-domain-settings';\nimport envelope from '@/store/modules/envelope';\nimport files from '@/store/modules/files';\nimport fleet from '@/store/modules/fleet';\nimport getaround from '@/store/modules/getaround';\nimport hqRentals from '@/store/modules/hq-rentals';\nimport payments from '@/store/modules/payments';\nimport settings from '@/store/modules/settings';\nimport theme from '@/store/modules/theme';\nimport lang from '@/store/modules/lang';\nimport listing from '@/store/modules/listing';\nimport lula from '@/store/modules/lula';\nimport notes from '@/store/modules/notes';\nimport outdoorsy from '@/store/modules/outdoorsy';\nimport permission from '@/store/modules/permission';\nimport pricing from '@/store/modules/pricing';\nimport providers from '@/store/modules/providers';\nimport renters from '@/store/modules/renters';\nimport square from '@/store/modules/square';\nimport subscriptions from '@/store/modules/subscriptions';\nimport superAdmin from '@/store/modules/superAdmin';\nimport tagsView from '@/store/modules/tags-view';\nimport taxes from '@/store/modules/taxes';\nimport maintenance from '@/store/modules/maintenance';\nimport order from '@/store/modules/order';\nimport stripe from '@/store/modules/stripe';\nimport template from '@/store/modules/template';\nimport tesla from '@/store/modules/tesla';\nimport tolls from '@/store/modules/tolls';\nimport tripExtras from '@/store/modules/trip-extras';\nimport turo from '@/store/modules/turo';\nimport turoPricing from '@/store/modules/turo-pricing';\nimport turoResearch from '@/store/modules/turo-research';\nimport twilio from '@/store/modules/twilio';\nimport twistedRoad from '@/store/modules/twisted-road';\nimport vehicles from '@/store/modules/vehicles';\nimport whatsNew from '@/store/modules/whats-new';\nimport webhook from '@/store/modules/webhook';\nimport tenantCheckout from '@/store/modules/tenant-checkout';\nimport tags from '@/store/modules/tags';\nimport {RootState} from '@/types/RootState';\n\nexport const store: Store<RootState> = createStore({\n modules: {\n axle,\n cart,\n affiliate,\n analytics,\n app,\n auth,\n automations,\n barcode,\n booking,\n bouncie,\n braintree,\n checkout,\n commissionPartners,\n company,\n coupon,\n custodian,\n customFields,\n defaultProperties,\n document,\n email,\n emailDomainSettings,\n envelope,\n files,\n fleet,\n getaround,\n hqRentals,\n lang,\n listing,\n lula,\n maintenance,\n notes,\n order,\n outdoorsy,\n payments,\n permission,\n pricing,\n providers,\n renters,\n settings,\n square,\n theme,\n stripe,\n subscriptions,\n superAdmin,\n tagsView,\n taxes,\n template,\n tenantCheckout,\n tesla,\n tolls,\n tripExtras,\n turo,\n turoPricing,\n turoResearch,\n twilio,\n twistedRoad,\n vehicles,\n webhook,\n whatsNew,\n tags,\n },\n // strict: import.meta.env.MODE === 'development',\n});","<template>\n <v-app class=\"z-0 relative\">\n <component :is=\"layoutComponent\">\n <router-view/>\n </component>\n\n <Notivue v-slot=\"item\">\n <Notification :item=\"item\"/>\n </Notivue>\n </v-app>\n</template>\n\n<script lang=\"ts\" setup>\nimport {computed, defineAsyncComponent, onBeforeMount} from 'vue';\nimport {useRoute} from 'vue-router';\nimport {store} from '@/store';\nimport 'notivue/animations.css';\nimport 'notivue/notification.css';\nimport {Notification, Notivue} from 'notivue'\n\nconst TheDefaultLayout = defineAsyncComponent(() => import('@/layouts/TheDefaultLayout.vue'));\n\n// Define the allowed layout names explicitly\ntype LayoutKey = 'Dashboard' | 'Esign' | 'CompanyStore' | 'Default';\n\nconst layoutMap = {\n Dashboard: defineAsyncComponent({\n loader: () => import('@/layouts/TheDashboardLayout.vue'),\n delay: 200, // Avoid flicker on fast networks\n timeout: 5000, // Fail if loading takes too long\n }),\n Esign: defineAsyncComponent(() => import('@/layouts/TheEsignLayout.vue')),\n CompanyStore: defineAsyncComponent(() => import('@/layouts/TheCompanyStoreLayout.vue')),\n Default: defineAsyncComponent(() => import('@/layouts/TheDefaultLayout.vue')),\n};\n\nconst route = useRoute();\n\n/**\n * Dynamically determine the layout component based on the route's metadata.\n * Defaults to a standard layout or fallback if no layout is specified.\n */\nconst layoutComponent = computed(() => {\n const layoutName = route.meta?.layout as LayoutKey | undefined;\n const resolvedLayout = layoutName && layoutMap[layoutName] ? layoutMap[layoutName] : TheDefaultLayout;\n\n console.log(`🖥️ Using Layout: ${layoutName || 'Default'}`);\n return resolvedLayout;\n});\n\nonBeforeMount(() => {\n // Initialize the app state\n store.commit('app/INITIALIZE_STATE');\n});\n</script>","// Vuetify\nimport 'vuetify/styles';\nimport { createVuetify } from 'vuetify';\n\nconst vuetify = createVuetify({\n components: {},\n});\n\nexport default vuetify;","import VueGtag from \"vue-gtag\";\n\nexport function initGtag(app, router) {\n app.use(VueGtag, {\n bootstrap: false,\n config: {id: \"G-NWFRX8HJBK\"}\n }, router);\n}","import * as Sentry from '@sentry/vue';\n\nconst IS_DEBUG = import.meta.env.MODE !== 'production';\n\nexport function initSentry(app: any) {\n const SENTRY_DSN = import.meta.env.VITE_SENTRY_DSN || 'https://477434e9051c46e38a6d5052ba4129d7@sentry.io/2158517';\n\n if (!SENTRY_DSN) {\n console.warn('⚠️ Sentry DSN is not provided.');\n return;\n }\n\n Sentry.init({\n app,\n dsn: SENTRY_DSN,\n release: import.meta.env.VITE_APP_VERSION || '1.0.51',\n // debug: IS_DEBUG,\n environment: import.meta.env.MODE,\n\n beforeSend: (event, hint) => {\n if (IS_DEBUG) {\n console.error('[Sentry Debug] Captured Error:', hint.originalException || hint.syntheticException);\n // return null; // this drops the event and nothing will be sent to sentry\n }\n return event;\n },\n\n integrations: [\n Sentry.vueIntegration({\n tracingOptions: {\n trackComponents: true,\n },\n }),\n Sentry.browserTracingIntegration(),\n Sentry.replayIntegration({\n maskAllText: false,\n blockAllMedia: true,\n }),\n // The following is all you need to enable canvas recording with Replay\n Sentry.replayCanvasIntegration(),\n ],\n\n // This sets the sample rate to be 10%. You may want this to be 100% while\n // in development and sample at a lower rate in production\n replaysSessionSampleRate: IS_DEBUG ? 1.0 : 0.1,\n\n // If the entire session is not sampled, use the below sample rate to sample\n // sessions when an error occurs.\n replaysOnErrorSampleRate: 1.0,\n tracesSampleRate: 1.0,\n tracePropagationTargets: ['localhost', 'fleetwire.test', 'fleetwire.io', /^\\//],\n });\n\n console.log('✅ Sentry Initialized Successfully!');\n}","import axios from 'axios';\nimport {getToken, removeAllUserCookies} from '@/utils/auth';\nimport {EventBus} from '@/plugins/eventBus';\nimport {store} from '@/store';\nimport router from '@/router';\n\naxios.defaults.baseURL = '/api';\n\n// Request interceptor\naxios.interceptors.request.use((request) => {\n const token = getToken();\n\n if (token) {\n request.headers.Authorization = `bearer ${token}`;\n }\n\n request.headers.Accept = 'application/json';\n request.headers['Accept-Language'] = store.getters['lang/locale'];\n\n return request;\n});\n\naxios.interceptors.response.use((response) => response, (error) => {\n const status = error.response?.status;\n\n // eslint-disable-next-line\n if (status === 401) {\n // handleUnauthorizedError();\n } else if (status === 500) {\n EventBus.$emit('SystemMessage', {\n type: 'error',\n message: 'Server Error. Please try again in a few minutes.',\n });\n }\n\n return Promise.reject(error);\n});\n\nconst handleUnauthorizedError = () => {\n const currentRouterName = router.currentRoute.value.name;\n const currentPath = window.location.pathname;\n const fullPath = window.location.href;\n\n console.dir('handleUnauthorizedError');\n console.dir(currentRouterName);\n console.dir(currentPath);\n console.dir(fullPath);\n\n\n const authPaths = ['/login', '/register', '/password/reset', '/password/verify', '/password/resend', '/company', '/rental', 'rental/reservations'];\n\n if (authPaths.some(path => currentPath.startsWith(path))) {\n console.log('Already on an auth-related page, no redirect needed.');\n return;\n }\n\n EventBus.$emit('SystemMessage', {\n type: 'error',\n message: 'Unauthorized',\n });\n\n removeAllUserCookies();\n window.location.href = `/login?redirect=${encodeURIComponent(currentPath)}`;\n};","import {App, Component} from 'vue';\n\n/**\n * Register layouts in the app instance\n *\n * @param {App<Element>} app\n */\nexport async function registerLayouts(app: App<Element>) {\n const layouts = import.meta.glob('./*.vue'); // Returns a map of lazy-loaded modules\n\n console.log('Layouts:', layouts);\n\n for (const [path, layoutImporter] of Object.entries(layouts)) {\n try {\n // Dynamically import the layout\n const module = (await layoutImporter()) as { default: Component };\n const component = module.default;\n\n if (!component) {\n console.warn(`Failed to load layout at path: ${path}`);\n continue;\n }\n\n // Use the `name` property or fallback to the filename\n const componentName = component.name || extractFileName(path);\n\n if (!componentName) {\n console.error(`Unable to determine component name for layout at path: ${path}`);\n continue;\n }\n\n app.component(componentName, component);\n } catch (error) {\n console.error(`Error loading layout at path: ${path}`, error);\n }\n }\n}\n\n/**\n * Extracts the filename from a given path and removes the extension.\n */\nfunction extractFileName(path: string): string {\n return path.split('/').pop()?.replace(/\\.\\w+$/, '') || 'UnnamedComponent';\n}\n","import './bootstrap';\nimport '../css/app.css';\n\n// Core Vue imports\nimport {createApp, defineAsyncComponent} from 'vue';\nimport App from './App.vue';\n\n// Store and Router\nimport {store} from './store';\nimport router from './router';\n\n// Plugins\nimport vuetify from './plugins/vuetify';\nimport i18n from './plugins/i18n/i18n';\nimport {initGtag} from './plugins/gtag';\nimport {initSentry} from './plugins/sentry';\nimport {plugin as VueTippy} from 'vue-tippy';\nimport 'tippy.js/dist/tippy.css';\nimport VCalendar from 'v-calendar';\nimport 'v-calendar/style.css';\nimport {VueDragula} from 'vue3-dragula';\nimport './plugins';\n/** Register Layouts */\nimport {registerLayouts} from './layouts/register';\nimport {createNotivue} from 'notivue'\n\n\nconst notivue = createNotivue({\n position: 'top-center',\n limit: 4,\n enqueue: true,\n avoidDuplicates: true,\n notifications: {\n global: {\n duration: 2000\n }\n }\n})\n\n/** Initialize App */\nconst app = createApp(App)\n .use(store)\n .use(i18n)\n .use(router)\n .use(vuetify)\n .use(VueTippy, {\n directive: 'tippy', // => v-tippy\n component: 'tippy', // => <tippy/>\n })\n .use(VCalendar, {\n componentPrefix: 'vc',\n })\n .use(VueDragula, {\n logging: {\n service: true,\n },\n });\n\n/** Register Components */\napp.component('TheHelpLink', defineAsyncComponent(() =>\n import('@/components/widgets/HelpLink.vue')\n));\napp.component('FwDivider', defineAsyncComponent(() =>\n import('@/components/Global/Fleetify/fw-divider.vue')\n));\napp.component('FeatureTitle', defineAsyncComponent(() =>\n import('@/components/dashboard/FeatureTitle.vue')\n));\n\napp.use(notivue);\n\n(async () => {\n await registerLayouts(app);\n})();\n\n/** Initialize Plugins */\nif (navigator.onLine) {\n initSentry(app);\n initGtag(app, router);\n} else {\n console.warn('Offline: Skipping Sentry and Google Analytics initialization.');\n}\n\n\n/** Mount App */\nrouter.isReady().then(() => {\n app.mount('#app');\n});\n\nexport {app};\n","import {store} from '@/store';\n\n/**\n * @example see @/views/permission/Directive.vue\n */\nexport default function checkRole(value: string[]): boolean {\n if (value && value instanceof Array && value.length > 0) {\n const roles = store.getters['auth/roles'];\n const requiredRoles = value;\n\n return roles.some((role: string) => requiredRoles.includes(role));\n }\n console.error('Need roles! Like v-role=\"[\\'admin\\',\\'editor\\']\"');\n return false;\n}\n","import {computed, ComputedRef} from 'vue';\nimport {useStore} from 'vuex';\nimport {AppFeatures} from '@/types';\n\ninterface FeatureWaitlist {\n feature: string;\n}\n\nexport function useAppFeatures() {\n const store = useStore();\n\n const appFeatures: ComputedRef<AppFeatures> = computed(() => store.getters['app/appFeatures']);\n const featureWaitlist = computed(() => store.getters['app/featureWaitlist']);\n\n\n const canFilterByPaymentStatus = computed(() => appFeatures.value?.['canFilterByPaymentStatus'] || false);\n const canUseSquareIntegration = computed(() => appFeatures.value?.['square-payment-profile'] || false);\n const canUseBraintreeIntegration = computed(() => appFeatures.value?.['braintree-payment-profile'] || false);\n const hasAxleIntegrationFeature = computed(() => appFeatures.value?.['axle-integration'] || false);\n const hasPricingTemplateFeature = computed(() => appFeatures.value?.['pricing-template'] || false);\n const hasStoreThemesFeature = computed(() => appFeatures.value?.['store-themes'] || false);\n const hasRenterBlockFeature = computed(() => appFeatures.value?.['renter-block'] || false);\n\n function hasWaitlistRequest(feature: string): boolean {\n return featureWaitlist.value?.some((f: FeatureWaitlist) => f.feature === feature) ?? false;\n }\n\n function addFeatureWaitlist(featureWaitlist: FeatureWaitlist): void {\n store.dispatch('app/addFeatureWaitlist', featureWaitlist);\n }\n\n function getFeatureWaitlist(): void {\n store.dispatch('app/getFeatureWaitlist');\n }\n\n return {\n appFeatures,\n addFeatureWaitlist,\n hasWaitlistRequest,\n getFeatureWaitlist,\n\n // computed\n canFilterByPaymentStatus,\n canUseSquareIntegration,\n canUseBraintreeIntegration,\n hasAxleIntegrationFeature,\n hasPricingTemplateFeature,\n hasStoreThemesFeature,\n hasRenterBlockFeature,\n }\n}","<template>\n <div v-if=\"checkPermission(['settings_view'])\" class=\"mb-13\">\n <h2 class=\"mt-8 mb-4 font-bold text-2xl\">General</h2>\n\n <CompanyInformation/>\n </div>\n</template>\n\n<script lang=\"ts\" setup>\nimport {defineAsyncComponent} from 'vue';\nimport checkPermission from '@/utils/permission';\n\nconst CompanyInformation = defineAsyncComponent(() => import('@/components/dashboard/settings/general/CompanyInformation.vue'));\n</script>\n","import {useStore} from 'vuex';\nimport {computed} from 'vue';\nimport {TenantBranch} from '@/types';\n\nexport function useBranch() {\n const store = useStore();\n\n const branches = computed<TenantBranch[]>(() => store.getters['fleet/branches']);\n const branch = computed<TenantBranch>(() => store.getters['fleet/branch']);\n const branchLoading = computed(() => store.getters['fleet/loading']);\n\n const getFleetBranches = async () => {\n return await store.dispatch('fleet/getFleetBranches');\n }\n\n const createBranch = (branch: TenantBranch) => {\n return store.dispatch('fleet/createBranch', branch);\n }\n\n const getFleetBranch = (uuid: string) => {\n return store.dispatch('fleet/getFleetBranch', uuid);\n }\n\n const deleteFleetBranch = (uuid: string) => {\n return store.dispatch('fleet/deleteBranch', uuid);\n }\n return {\n branchLoading,\n branch,\n branches,\n createBranch,\n getFleetBranches,\n deleteFleetBranch,\n getFleetBranch,\n }\n}","export default new Promise((res) => {\n const script = document.createElement('script');\n script.onload = () => res();\n script.setAttribute('src', 'https://api.mapbox.com/search-js/v1.0.0-beta.13/web.js');\n document.head.appendChild(script);\n});\n","<template>\n <div class=\"w-full z-auto\">\n <v-form>\n <div>\n <div class=\"input-fields map-col w-full\">\n <v-text-field\n v-show=\"!address2\"\n id=\"mapbox-autofill\"\n :density=\"dense ? 'compact' : 'default'\"\n autocomplete=\"address-line1\"\n class=\"mb-2 relative\"\n hide-details\n label=\"Address\"\n variant=\"outlined\"\n />\n\n <v-text-field\n v-if=\"address2\"\n v-model=\"address2\"\n :density=\"dense ? 'compact' : 'default'\"\n autocomplete=\"address-line\"\n class=\"mb-2 relative\"\n hide-details\n label=\"Address1\"\n variant=\"outlined\"\n @focus=\"address2 = ''\"\n />\n\n <div v-show=\"!expandForm\">\n <v-btn size=\"small\" variant=\"text\" @click=\"expandForm = !expandForm\">Or Enter an address manually</v-btn>\n </div>\n <div v-if=\"!singleLineAddress\" v-show=\"expandForm\" class=\"secondary-inputs\">\n <v-text-field\n :density=\"dense ? 'compact' : 'default'\"\n autocomplete=\"address-line2\"\n class=\"mb-2\"\n hide-details\n label=\"Address Line 2\"\n name=\"address-line2\"\n variant=\"outlined\"\n ></v-text-field>\n <div class=\" mt-2\">\n <v-text-field\n :density=\"dense ? 'compact' : 'default'\"\n autocomplete=\"address-level2\"\n class=\"mb-2\"\n hide-details\n label=\"City\"\n name=\"address-level2\"\n variant=\"outlined\"\n ></v-text-field>\n <v-text-field\n :density=\"dense ? 'compact' : 'default'\"\n autocomplete=\"address-level1\"\n class=\"mb-2\"\n hide-details\n label=\"State / Region\"\n name=\"address-level1\"\n variant=\"outlined\"\n ></v-text-field>\n <v-text-field\n :density=\"dense ? 'compact' : 'default'\"\n autocomplete=\"postal-code\"\n class=\"mb-2\"\n hide-details\n label=\"ZIP / Postcode\"\n name=\"postal-code\"\n variant=\"outlined\"\n ></v-text-field>\n </div>\n </div>\n </div>\n\n <div class=\"map-col\" style=\"width: 100%\">\n <div id=\"minimap-container\" class=\"relative\" style=\"height: 240px; width: 350px\"></div>\n </div>\n </div>\n </v-form>\n </div>\n</template>\n\n<script lang=\"ts\" setup>\nimport {onMounted, ref, toRefs} from 'vue';\nimport {get} from 'lodash';\nimport 'mapbox-gl/dist/mapbox-gl.css';\nimport mapboxScriptIsReady from '@/plugins/mapBoxAddressAutofillScript.js';\n\nconst ACCESS_TOKEN = 'pk.eyJ1IjoiZmxlZXR3aXJlIiwiYSI6ImNramV3ZXpvbjA3Z3Ayc21wbHkwNGluY2IifQ.203P27NF1jbVqCAuGKeYsQ';\n\nexport interface LocationData {\n name: string,\n address_line1: string,\n address_line2: string,\n address_level1: string,\n address_level2: string,\n postcode: string,\n country: string,\n country_code: string,\n district: string,\n neighborhood: string,\n provider: string,\n provider_id: string,\n lat: number,\n lng: number,\n}\n\nconst props = defineProps<{\n dense?: boolean,\n singleLineAddress?: boolean,\n}>();\n\nconst emit = defineEmits(['locationData']);\n\nconst {dense, singleLineAddress} = toRefs(props);\n\nconst expandForm = ref(false);\nconst address2 = ref('');\n\nconst setupMapBox = () => {\n mapboxsearch.config.accessToken = ACCESS_TOKEN;\n\n mapboxsearch.popoverOptions = {\n placement: 'bottom-start',\n }\n\n const autofillCollection = mapboxsearch.autofill({\n container: document.body,\n });\n const minimap = new MapboxAddressMinimap();\n // minimap.canAdjustMarker = true;\n minimap.satelliteToggle = true;\n minimap.theme = {\n variables: {\n borderRadius: '18px',\n boxShadow: '0 2px 8px #000'\n }\n }\n minimap.onSaveMarkerLocation = (lnglat) => {\n console.log(`Marker moved to ${lnglat}`);\n };\n const minimapContainer = document.getElementById('minimap-container');\n minimapContainer.appendChild(minimap);\n\n autofillCollection.addEventListener(\n 'retrieve',\n async (e) => {\n expandForm.value = true;\n if (minimap) {\n minimap.feature = e.detail.features[0];\n }\n\n const features = get(e, 'detail.features.0.properties');\n const geometry = get(e, 'detail.features.0.geometry');\n const locationData: LocationData = {\n name: get(features, 'full_address'),\n address_line1: get(features, 'address_line1'),\n address_line2: get(features, 'address_line2'),\n address_level1: get(features, 'address_level1'),\n address_level2: get(features, 'address_level2'),\n postcode: get(features, 'postcode'),\n country: get(features, 'country'),\n country_code: get(features, 'country_code'),\n district: get(features, 'district'),\n neighborhood: get(features, 'neighborhood'),\n provider: 'mapbox',\n provider_id: get(features, 'id'),\n lat: get(geometry, 'coordinates.1'),\n lng: get(geometry, 'coordinates.0'),\n };\n const singleLine = singleLineAddress.value;\n address2.value = singleLine ? get(features, 'full_address') : locationData.address_line1;\n\n emit('locationData', locationData);\n },\n );\n};\n\nonMounted(() => {\n mapboxScriptIsReady.then(() => {\n setupMapBox();\n });\n});\n</script>\n\n<style>\n.map-col {\n display: block;\n max-width: 100%;\n flex-shrink: 1;\n}\n\n.mapboxgl-ctrl-geocoder {\n z-index: 1050 !important; /* Higher than dialog */\n position: absolute !important;\n}\n\n.v-overlay__content {\n overflow: visible !important; /* Allow content to overflow dialog */\n}\n\n@media screen and (min-width: 640px) {\n .map-col {\n width: auto;\n flex: 1 1 0;\n }\n}\n\n</style>\n","import {useStore} from 'vuex';\nimport {computed} from 'vue';\nimport {TaxCategory} from \"@/types\";\n\nexport function useTaxAndFee() {\n const store = useStore();\n\n\n const taxCategories = computed(() => store.getters['taxes/taxCategories']);\n const taxForm = computed(() => store.getters['taxes/taxForm']);\n const taxCategoryLoading = computed(() => store.getters['taxes/loading']);\n\n const resetTaxFormErrors = () => {\n store.commit('taxes/CLEAR_TAX_CATEGORY_FORM_ERRORS');\n }\n\n const setTaxCategory = (taxCategories: TaxCategory[]) => {\n store.commit('taxes/SET_TAX_CATEGORIES', taxCategories);\n }\n const saveTaxCategory = (taxCategory: TaxCategory) => {\n return store.dispatch('taxes/saveTaxCategory', taxCategory);\n }\n const deleteTaxCategory = (taxCategory: TaxCategory) => {\n return store.dispatch('taxes/deleteTaxCategory', taxCategory);\n }\n const updateTaxCategory = (taxCategory: TaxCategory) => {\n return store.dispatch('taxes/updateTaxCategory', taxCategory);\n }\n const taxCategorySetDefault = (taxCategory: TaxCategory) => {\n return store.dispatch('taxes/taxCategorySetDefault', taxCategory);\n }\n\n const getTaxCategories = () => {\n return store.dispatch('taxes/getTaxCategories');\n }\n\n return {\n taxCategories,\n taxForm,\n taxCategoryLoading,\n setTaxCategory,\n resetTaxFormErrors,\n saveTaxCategory,\n deleteTaxCategory,\n updateTaxCategory,\n taxCategorySetDefault,\n getTaxCategories,\n }\n}","import {computed, ref, watch} from 'vue';\nimport {useStore} from 'vuex';\nimport {\n BookingInterface,\n CompanyInterface,\n DraftListingInterface,\n ListingInterface,\n TripExtra,\n VehicleClass,\n VehicleDetail,\n VehicleImageInterface\n} from '@/types';\nimport {DailyPrice} from '@/store/modules/listing';\nimport {snakeCase} from '@/utils/text';\nimport {getMetaBooleanValue} from '@/utils/meta';\nimport axios from 'axios';\nimport {push} from 'notivue';\n\nconst VEHICLE_STATUSES = ['available', 'dirty', 'out of service', 'for sale', 'sold', 'new', 'reserved', 'rental', 'maintenance', 'other'];\n\nconst mapToTitleCodeArray = (array: string[]) =>\n array.map(item => ({\n title: item.charAt(0).toUpperCase() + item.slice(1).toLowerCase(),\n code: snakeCase(item),\n }));\n\nexport function useListing(initialListing?: ListingInterface) {\n const store = useStore();\n const listing = ref<ListingInterface>(initialListing || null);\n const isLoading = ref(false);\n const errors = ref<Record<string, string[]>>({});\n\n // Computed property to check if listing is loaded\n const isLoaded = computed(() => !!listing.value);\n\n // Watch for changes in the store's listing if we're working with the current listing\n if (!initialListing) {\n watch(\n () => store.state.listing.listing,\n (newListing) => {\n if (newListing) {\n listing.value = {...newListing};\n }\n },\n {immediate: true}\n );\n }\n\n const initializeWithCurrentListing = () => {\n const currentListing = store.getters['listing/currentListing'];\n\n if (currentListing) {\n listing.value = {...currentListing};\n }\n };\n\n const updateListing = async (updates: Partial<ListingInterface>) => {\n console.dir('updateListing');\n console.dir(updates);\n console.dir(listing.value);\n if (!listing.value?.l_id) return;\n\n console.dir(updates);\n\n isLoading.value = true;\n errors.value = {};\n\n try {\n const response = await axios.patch(`/v1/listings/${listing.value.l_id}`, updates);\n\n // Check if the response has an error status\n if (response.status >= 400) {\n throw new Error(response.data.message || 'Update failed');\n }\n\n // Only update and show success if we get here (no errors)\n listing.value = {...listing.value, ...response.data?.listing};\n\n // Update store if this is the current listing\n if (store.getters['listing/currentListing']?.l_id === listing.value.l_id) {\n store.commit('listing/SET_CURRENT_LISTING', listing.value);\n }\n\n push.success({\n message: 'Listing updated successfully!',\n });\n } catch (error) {\n // Handle any type of error (validation, network, etc)\n const errorData = error?.response?.data;\n errors.value = errorData?.errors || {};\n\n push.error({\n message: errorData?.message || error.message || 'Failed to update listing',\n });\n } finally {\n isLoading.value = false;\n }\n };\n\n const updateField = async (path: string, value: any) => {\n const updates: Record<string, any> = {};\n updates[path] = value;\n await updateListing(updates);\n };\n\n const resetListing = () => {\n if (initialListing) {\n listing.value = {...initialListing};\n } else if (store.state.listing.listing) {\n listing.value = {...store.state.listing.listing};\n }\n errors.value = {};\n };\n\n const availableVehicleStatuses = ref(mapToTitleCodeArray(VEHICLE_STATUSES));\n\n const listingInit = computed(() => store.getters['listing/listingInit']);\n const listings = computed<ListingInterface[]>(() => store.getters['listing/allListings']);\n const listingLoading = computed(() => store.getters['listing/listingLoading']);\n const listingForm = computed(() => store.getters['listing/form']);\n const currentListing = computed<ListingInterface>(() => store.getters['listing/currentListing']);\n const originalListing = computed<ListingInterface>(() => store.getters['listing/originalListing']);\n const currentListingBookings = computed<BookingInterface[]>(() => store.getters['listing/currentListingBookings']);\n const dailyPricing = computed(() => store.getters['listing/dailyPricing']);\n const company = computed<CompanyInterface>(() => store.getters['company/company']);\n const listingSnacks = computed(() => store.getters['listing/listingSnacks']);\n const allVehicleFeatures = computed(() => store.getters['listing/allVehicleFeatures']);\n const allListingsInit = computed(() => store.getters['listing/allListingsInit']);\n const fleetResourceListings = computed(() => store.getters['listing/fleetResourceListings']);\n const visibleListings = computed(() => store.getters['listing/visibleListings']);\n const currentListingDailyPricing = computed<DailyPrice[]>(() => store.getters['listing/dailyPricing']);\n const listingExtras = computed<TripExtra[]>(() => store.getters['listing/listingExtras']);\n\n const listingDialogs = computed(() => store.getters['listing/dialogs']);\n\n\n const setListingDialog = (topic: string, value: boolean = true) => {\n store.commit('listing/SET_LISTING_DIALOG', {topic, value});\n }\n\n const allListingsAreArchived = computed(() => {\n return listings.value.every((listing) => listing.archived_at);\n });\n\n const setUnavailablePeriod = async (payload: { l_id: string, start: string, end: string }) => {\n return await store.dispatch('listing/setUnavailablePeriod', payload);\n }\n\n const currentListingVehicleOdometer = computed({\n get: () => currentListing.value?.vehicle?.last_odometer_reading,\n set: (value) => {\n store.commit('listing/SET_LISTING_VEHICLE', {\n last_odometer_reading: value,\n });\n }\n });\n\n const currentListingVehicleStatus = computed({\n get() {\n return currentListing.value?.vehicle?.status || '';\n },\n set(value) {\n store.commit('listing/SET_EXISTING_LISTING_DATA', {\n vehicle: {\n status: value,\n },\n });\n },\n });\n\n const currentListingVehicleId = computed(() => currentListing.value?.vehicle?.v_id);\n\n const resetCurrentListing = () => {\n store.commit('listing/RESET_CURRENT_LISTING');\n }\n\n const fetchDailyPrices = async (payload: { l_id: string, start: string, end: string }) => {\n return await store.dispatch('listing/fetchDailyPrices', payload);\n }\n\n const fetchCompanySingleListingExtras = async (listingId: string) => {\n return await store.dispatch('listing/fetchCompanySingleListingExtras', listingId);\n }\n\n const updateVehicleDetails = async (payload: { l_id: string, details: VehicleDetail[] }) => {\n return await store.dispatch('listing/updateVehicleDetails', payload);\n }\n\n const getVehicleFeatures = async (l_id: string) => {\n return await store.dispatch('listing/getVehicleFeatures', l_id);\n }\n\n const fetchListings = async () => {\n return await store.dispatch('listing/fetchListings');\n };\n\n const addListing = async (listing: ListingInterface) => {\n try {\n return await store.dispatch('listing/addListing', listing);\n } catch (e) {\n console.error(e);\n throw e;\n }\n }\n\n const setCurrentNewListing = (listing: ListingInterface | DraftListingInterface) => {\n store.commit('listing/SET_CURRENT_NEW_LISTING', listing);\n }\n\n const allowsSecondaryDriver = computed(() => {\n const listingLevel = currentListing.value?.use_secondary_driver;\n if (!listingLevel) return false;\n\n const companyLevel = getMetaBooleanValue('settings.security.use_secondary_driver');\n\n return listingLevel || companyLevel;\n });\n\n const saveListing = async (listing: ListingInterface) => {\n try {\n return await store.dispatch('listing/saveListing', listing);\n } catch (e) {\n console.error(e);\n throw e;\n }\n }\n const fetchCompanySingleListings = async (listingId: string) => {\n return await store.dispatch('listing/fetchCompanySingleListings', listingId);\n }\n\n const pauseListing = async (payload: { mode: string, listings: string[] }) => {\n return await store.dispatch('listing/pauseListing', payload);\n }\n const deleteListingImage = async (imageId: string) => {\n return await store.dispatch('listing/deleteListingImage', imageId);\n }\n\n const deleteListing = async (listing: ListingInterface) => {\n return await store.dispatch('listing/deleteListing', listing);\n }\n\n const archiveListing = async (listing: ListingInterface) => {\n return await store.dispatch('listing/archiveListing', listing);\n }\n\n const updateListingImageOrder = async (images: any) => {\n return await store.dispatch('listing/updateListingImageOrder', images);\n }\n\n const fetchFleetResourcesListings = async (refresh = false) => {\n return await store.dispatch('listing/fetchFleetResourcesListings', refresh);\n }\n\n const getVehicleIncidents = async (listingId: string) => {\n return await store.dispatch('listing/getVehicleIncidents', listingId);\n }\n\n const resetAndReImportCarShareImages = async (listingId: string) => {\n return await store.dispatch('listing/resetAndReImportCarShareImages', listingId);\n }\n\n const fetchAgencySingleListingBookings = async (listingId: string) => {\n return await store.dispatch('company/fetchAgencySingleListingBookings', listingId);\n }\n\n const getListingPublicLink = (listing: ListingInterface): string => {\n if (import.meta.env.MODE === 'production') {\n const base = 'https://' + company.value.slug + '.fleetwire.io';\n return `${base}/rental/reservations?l_id=${listing.l_id}`;\n }\n\n return `/rental/reservations?l_id=${listing.l_id}&company=${company.value.slug}`;\n }\n\n const listingVehicleStatus = (listing: ListingInterface) => {\n const status = listing?.vehicle?.status;\n if (!status) return status;\n const theStatus = availableVehicleStatuses.value.find(s => s.code === status);\n return theStatus?.title;\n }\n\n const listingNameDisplay = (listing: ListingInterface | { name: string }, characterLimit: number = -1): string => {\n const name = listing?.name || '';\n\n return characterLimit > 0 ?\n `${name.substring(0, characterLimit)}${name.length > characterLimit ? '...' : ''}`\n : name;\n }\n\n const currentListingAgeRequirements = computed(() => {\n return currentListing.value?.age_requirements || [];\n });\n\n const currentListingName = computed({\n get: () => currentListing.value?.name || '',\n set: (value: string) => {\n store.commit('listing/SET_EXISTING_LISTING_DATA', {\n name: value,\n });\n }\n });\n\n const currentListingVehicleUnitId = computed({\n get: () => currentListing.value?.vehicle?.unit_id || '',\n set: (value: string) => {\n store.commit('listing/SET_EXISTING_LISTING_DATA', {\n vehicle: {\n unit_id: value,\n },\n });\n }\n });\n\n const currentListingDescription = computed({\n get: () => currentListing.value?.description?.replace(/[\\r\\n]+/g, '<br />') || '',\n set: (value: string) => {\n store.commit('listing/SET_EXISTING_LISTING_DATA', {\n description: value,\n });\n }\n });\n\n const currentListingVehicleVin = computed({\n get: () => currentListing.value?.vehicle?.vin || '',\n set: (value: string) => {\n store.commit('listing/SET_VEHICLE_VIN', value.toLocaleUpperCase());\n }\n });\n\n const currentListingVehicleYear = computed({\n get: () => currentListing.value?.vehicle?.year || '',\n set: (value: string | number) => {\n store.commit('listing/SET_VEHICLE_YEAR', Number(value));\n }\n });\n\n const currentVehicleFeatures = computed({\n get: () => store.getters['listing/currentVehicleFeatures'],\n set: (value: string[]) => {\n store.commit('listing/SET_VEHICLE_FEATURES', value);\n }\n });\n\n const currentListingVehicleMake = computed({\n get: () => currentListing.value?.vehicle?.make || '',\n set: (value: string) => {\n store.commit('listing/SET_VEHICLE_MAKE', value);\n }\n });\n\n const currentListingVehicleModel = computed({\n get: () => currentListing.value?.vehicle?.model || '',\n set: (value: string) => {\n store.commit('listing/SET_VEHICLE_MODEL', value);\n }\n });\n\n const currentListingVehicleColor = computed({\n get: () => currentListing.value?.vehicle?.color || '',\n set: (value: string) => {\n store.commit('listing/SET_VEHICLE_COLOR', value);\n }\n });\n\n const currentListingVehicleNumberOfSeats = computed({\n get: () => currentListing.value?.vehicle?.seats || 5,\n set: (value: number) => {\n store.commit('listing/SET_VEHICLE_SEATS', value);\n }\n });\n\n const currentListingVehicleNumberOfDoors = computed({\n get: () => currentListing.value?.vehicle?.doors || 4,\n set: (value: number) => {\n store.commit('listing/SET_VEHICLE_DOORS', value);\n }\n })\n\n const currentListingVehiclePlate = computed({\n get: () => currentListing.value?.vehicle?.plate || '',\n set: (value: string) => {\n store.commit('listing/SET_VEHICLE_PLATE', value);\n }\n });\n\n const currentListingVehicleClass = computed({\n get: () => currentListing.value?.vehicle?.vehicle_class,\n set: (value: VehicleClass) => {\n store.commit('listing/SET_VEHICLE_CLASS', value);\n }\n })\n\n const currentListingVehicleClassName = computed(() => currentListingVehicleClass.value?.name);\n\n const listingVehicleHasRemoteCapability = (listing: ListingInterface) => {\n return listing?.vehicle?.has_remote_capability;\n }\n\n const listingVehicleHasConnectedBouncie = (listing: ListingInterface) => {\n return listing.vehicle?.matched_bouncie_vehicle;\n }\n\n const listingVehicleImages = (listing: ListingInterface): VehicleImageInterface[] => {\n return listing?.listing_images ?? [];\n }\n\n const listingVehicleImage = (listing: ListingInterface): string => {\n const placeHolder = '/images/vehicle-placeholder.jpg';\n const singleListingImage = listing?.listing_image;\n\n if (singleListingImage) {\n return singleListingImage;\n }\n\n return (listing?.listing_images?.[0]?.path) ?? placeHolder;\n }\n\n const listingVehicleDoorsDisplay = (listing: ListingInterface): number => listing?.vehicle?.doors;\n const listingVehicleSeatsDisplay = (listing: ListingInterface): number => listing?.vehicle?.seats;\n const listingVehicleYearMakeModelDisplay = (l: ListingInterface): string => {\n const vehicleProperties = [\n listingVehicleYearDisplay(l),\n listingVehicleMakeDisplay(l),\n listingVehicleModelDisplay(l)\n ];\n\n return vehicleProperties.filter(Boolean).join(' ');\n }\n\n const listingDescriptionDisplay = (listing: ListingInterface) => {\n return listing?.description?.replace(/[\\r\\n]+/g, '<br />') || '';\n }\n\n const listingClass = (listing: ListingInterface) => {\n return listing?.vehicle?.vehicle_class;\n }\n\n const listingClassNameDisplay = (listing: ListingInterface): string => {\n return listingClass(listing)?.name || '';\n }\n\n const listingPeriodDisplay = (listing: ListingInterface): string => listing?.pricing?.price_period || 'Day';\n const listingPriceDisplay = (listing: ListingInterface): number => listing?.pricing?.adjusted_amount || 0;\n const listingVehicleYearDisplay = (listing: ListingInterface) => listing?.vehicle?.year;\n const listingVehicleMakeDisplay = (listing: ListingInterface) => listing?.vehicle?.make;\n const listingVehicleModelDisplay = (listing: ListingInterface) => listing?.vehicle?.model\n\n const listingVehicleDetailsDisplay = (listing: ListingInterface): VehicleDetail[] => {\n const details = listing?.vehicle?.details ?? [];\n return details.filter(d => d.type === 'feature');\n }\n\n const currentListingChanges = computed(() => {\n const originalClone = JSON.parse(JSON.stringify(originalListing.value));\n const currentClone = JSON.parse(JSON.stringify(currentListing.value));\n\n if (!currentClone || !originalClone) return {};\n\n const listingChanges = {\n l_id: currentClone.l_id,\n };\n\n const differences = {\n pricing: [],\n age_requirements: [],\n vehicle: [],\n };\n\n for (const key of Object.keys(originalClone.pricing)) {\n if (originalClone.pricing[key] !== currentClone.pricing[key]) {\n differences.pricing.push(key);\n }\n }\n for (const key of Object.keys(originalClone.age_requirements)) {\n if (originalClone.age_requirements[key] !== currentClone.age_requirements[key]) {\n differences.age_requirements.push(key);\n }\n }\n for (const key of Object.keys(originalClone.vehicle)) {\n if (originalClone.vehicle[key] !== currentClone.vehicle[key]) {\n differences.vehicle.push(key);\n }\n }\n\n // Iterating and setting values\n for (const [name, data] of Object.entries(differences)) {\n for (const value of data) {\n listingChanges[`${name}.${value}`] = currentClone[name][value];\n }\n }\n\n // Deleting properties\n const propertiesToDelete = ['pricing', 'bookings', 'listing_images', 'age_requirements', 'commission_partners', 'provider_listings', 'vehicle'];\n for (const prop of propertiesToDelete) {\n delete originalClone[prop];\n delete currentClone[prop];\n }\n\n // Finding and setting final differences\n for (const key of Object.keys(originalClone)) {\n if (originalClone[key] !== currentClone[key]) {\n listingChanges[key] = currentClone[key];\n }\n }\n\n return listingChanges;\n });\n\n /**\n * Match a Provider with a listing\n *\n * */\n const matchAListing = (listing: ListingInterface) => {\n let providerAutoMatchedBy = null;\n let theMatchedListing = null;\n\n const vin = listing?.vehicle?.vin;\n const unitId = listing?.unit_id;\n\n if (vin) {\n theMatchedListing = matchByVin(vin);\n if (theMatchedListing) {\n providerAutoMatchedBy = 'vin';\n }\n }\n // If VIN didn't yield a match, try to match by Unit ID\n else if (unitId) {\n theMatchedListing = matchByUnitId(unitId);\n if (theMatchedListing) {\n providerAutoMatchedBy = 'Unit ID';\n }\n }\n\n if (theMatchedListing) {\n return {providerAutoMatchedBy, theMatchedListing};\n }\n\n return {providerAutoMatchedBy, theMatchedListing};\n }\n\n const matchByVin = (workingVin: string): ListingInterface | null => {\n return listings.value.find((l) => {\n const vin = listingVehicleVINDisplay(l);\n return vin && vin.toUpperCase() === workingVin.toUpperCase();\n });\n }\n\n const matchByUnitId = (workingUnitId: string): ListingInterface | null => {\n return listings.value.find((l) => {\n const unitId = l.vehicle?.unit_id;\n return unitId && unitId.toUpperCase() === workingUnitId.toUpperCase();\n });\n }\n\n const listingFilter = (itemTitle, queryText: string, item) => {\n const searchText = queryText.toLowerCase();\n const raw = item.raw; // Ensure we're working with `item.raw`\n\n const keys = [\n 'name',\n 'l_id',\n ['vehicle', 'unit_id'],\n ['vehicle', 'vin'],\n ['vehicle', 'year'],\n ['vehicle', 'make'],\n ['vehicle', 'model'],\n ];\n\n return keys.some(key => {\n let value;\n\n if (Array.isArray(key)) {\n // Traverse nested keys safely\n value = key.reduce((acc, k) => (acc && acc[k] !== undefined ? acc[k] : null), raw);\n } else {\n value = raw[key];\n }\n\n if (value !== null && value !== undefined) {\n value = String(value).toLowerCase(); // Convert to string before applying `toLowerCase`\n return value.includes(searchText); // Use `includes` instead of `indexOf`\n }\n\n return false;\n });\n };\n\n const listingVehicleVINDisplay = (listing: ListingInterface, last4: boolean = false): string => {\n const vin = listing?.vehicle?.vin || '';\n\n if (!vin) return '';\n\n return last4 && vin.length >= 4 ? vin.slice(-4) : vin;\n }\n\n const listingVehicleMatchedTuro = (listing: ListingInterface) => {\n return listing?.vehicle?.matched_turo_vehicle;\n }\n\n const listingVehicleUnitId = (listing: ListingInterface) => {\n return listing?.vehicle?.unit_id;\n }\n\n const listingVehicleLicensePlate = (listing: ListingInterface) => {\n return listing?.vehicle?.plate\n }\n\n const listingVehicleBranch = (listing: ListingInterface) => {\n return listing?.vehicle?.branch;\n }\n\n return {\n listingDialogs,\n setListingDialog,\n listing,\n isLoading,\n errors,\n isLoaded,\n updateListing,\n updateField,\n resetListing,\n initializeWithCurrentListing,\n listingInit,\n fleetResourceListings,\n listingForm,\n listings,\n listingLoading,\n currentListing,\n originalListing,\n currentListingChanges,\n currentListingBookings,\n dailyPricing,\n listingSnacks,\n allVehicleFeatures,\n currentVehicleFeatures,\n allowsSecondaryDriver,\n allListingsAreArchived,\n currentListingVehicleOdometer,\n currentListingVehicleStatus,\n currentListingVehicleId,\n currentListingName,\n currentListingAgeRequirements,\n currentListingVehicleUnitId,\n currentListingDescription,\n currentListingVehicleVin,\n currentListingVehicleYear,\n currentListingVehicleMake,\n currentListingVehicleModel,\n currentListingVehicleColor,\n currentListingVehicleNumberOfSeats,\n currentListingVehicleNumberOfDoors,\n currentListingVehiclePlate,\n currentListingVehicleClass,\n currentListingVehicleClassName,\n allListingsInit,\n visibleListings,\n currentListingDailyPricing,\n availableVehicleStatuses,\n listingExtras,\n setUnavailablePeriod,\n listingVehicleMatchedTuro,\n listingVehicleUnitId,\n listingVehicleLicensePlate,\n listingVehicleBranch,\n listingVehicleHasConnectedBouncie,\n listingVehicleHasRemoteCapability,\n matchAListing,\n fetchFleetResourcesListings,\n listingVehicleImages,\n listingFilter,\n getListingPublicLink,\n listingVehicleStatus,\n fetchDailyPrices,\n fetchListings,\n pauseListing,\n getVehicleIncidents,\n saveListing,\n resetCurrentListing,\n fetchCompanySingleListings,\n setCurrentNewListing,\n addListing,\n deleteListing,\n archiveListing,\n deleteListingImage,\n updateListingImageOrder,\n resetAndReImportCarShareImages,\n fetchAgencySingleListingBookings,\n listingVehicleImage,\n listingNameDisplay,\n listingVehicleYearDisplay,\n listingVehicleMakeDisplay,\n listingVehicleModelDisplay,\n listingPriceDisplay,\n listingPeriodDisplay,\n listingVehicleDoorsDisplay,\n listingVehicleSeatsDisplay,\n listingVehicleYearMakeModelDisplay,\n listingDescriptionDisplay,\n listingVehicleVINDisplay,\n listingVehicleDetailsDisplay,\n listingClassNameDisplay,\n updateVehicleDetails,\n getVehicleFeatures,\n fetchCompanySingleListingExtras,\n }\n}","import {reactive, watch} from 'vue';\nimport getDefaultMeta, {getMetaBooleanValue} from '@/utils/meta';\nimport {useCompany} from '@/composables/useCompany';\n\ntype MetaType = 'boolean' | 'string' | 'number';\ntype MetaConfig = {\n type: MetaType;\n default?: any;\n};\n\nexport function useDefaultMeta(keys: Record<string, MetaConfig>) {\n const {defaultMeta, addDefaultMeta, companyMetaForm} = useCompany();\n const state = reactive<Record<string, any>>({});\n\n const getValue = (key: string, config: MetaConfig) => {\n const {type, default: fallback} = config;\n\n switch (type) {\n case 'boolean': {\n const val = getMetaBooleanValue(key);\n return val ?? fallback ?? false;\n }\n case 'number': {\n const val = Number(getDefaultMeta(key));\n return isNaN(val) ? (fallback ?? 0) : val;\n }\n case 'string': {\n const val = getDefaultMeta(key);\n return val ?? fallback ?? '';\n }\n default:\n return fallback ?? '';\n }\n };\n\n const initialize = () => {\n Object.entries(keys).forEach(([key, config]) => {\n state[key] = getValue(key, config);\n });\n };\n\n initialize();\n\n watch(\n defaultMeta,\n initialize,\n {immediate: true}\n );\n\n const updateDefaultMeta = (key: string, value: any) => {\n state[key] = value;\n companyMetaForm.value?.errors?.clear(key);\n return addDefaultMeta({meta: [{key, value}]});\n };\n\n return {\n state,\n updateDefaultMeta,\n };\n}","<template>\n <div class=\"space-y-6\">\n <div class=\"md:grid md:grid-cols-3 md:gap-6\">\n <div class=\"md:col-span-1\">\n <div class=\"px-4 sm:px-0\">\n <h3 class=\"text-lg font-medium text-gray-900 dark:text-gray-100\">Global Price Adjustment</h3>\n <p class=\"mt-1 text-sm text-gray-600 dark:text-gray-400\">\n Adjust all your listing prices at once. You can add a fixed amount or percentage to every listing's base\n price.\n </p>\n </div>\n </div>\n\n <div class=\"mt-4 md:mt-0 md:col-span-2\">\n <v-card class=\"mb-5\">\n <v-card-text>\n <div class=\"space-y-4 \">\n <div class=\"flex flex-col sm:flex-row items-start gap-4\">\n <v-btn-toggle\n v-model=\"settings['global_listing_price_adjustment_mode']\"\n class=\"mt-1\"\n group\n mandatory\n @update:model-value=\"val => updateDefaultMeta('global_listing_price_adjustment_mode', val)\"\n >\n <v-btn v-tippy content=\"Fixed amount\" size=\"small\" value=\"amount\">\n <v-icon>mdi-cash</v-icon>\n </v-btn>\n <v-btn v-tippy content=\"Percentage\" size=\"small\" value=\"percent\">\n <v-icon>mdi-percent</v-icon>\n </v-btn>\n </v-btn-toggle>\n\n <v-text-field\n v-model=\"displayPriceAdjustmentValue\"\n :prefix=\"settings['global_listing_price_adjustment_mode'] === 'amount' ? companyMoneyTextInputSettings.prefix : ''\"\n :rules=\"adjustmentRules\"\n :suffix=\"settings['global_listing_price_adjustment_mode'] === 'amount' ? companyMoneyTextInputSettings.suffix : '%'\"\n class=\"w-full sm:w-auto\"\n label=\"Adjustment value\"\n type=\"number\"\n variant=\"outlined\"\n @blur=\"handlePriceAdjustmentUpdate\"\n @keyup.enter=\"handlePriceAdjustmentUpdate; $event.target.blur()\"\n />\n </div>\n <div class=\"text-sm text-gray-600 dark:text-gray-400\">\n <p v-if=\"settings['global_listing_price_adjustment_mode'] === 'amount'\">\n This will add a fixed amount to every listing's base price.\n </p>\n <p v-else>\n This will adjust every listing's price by this percentage.\n </p>\n </div>\n </div>\n </v-card-text>\n </v-card>\n </div>\n </div>\n </div>\n</template>\n\n<script lang=\"ts\" setup>\nimport {computed, ref, watch} from 'vue';\nimport {useMoneyFormatter} from '@/composables/useMoneyFormatter';\nimport {useDefaultMeta} from '@/composables/useDefaultMeta';\nimport {useAuth} from '@/composables/useAuth';\n\nconst {companyMoneyTextInputSettings} = useMoneyFormatter();\nconst {fetchSession} = useAuth();\n\nconst {state: settings, updateDefaultMeta} = useDefaultMeta({\n 'global_listing_price_adjustment_value': {type: 'number'},\n 'global_listing_price_adjustment_mode': {type: 'string'},\n});\n\nconst displayPriceAdjustmentValue = ref(0);\n\n// Validation\nconst validators = {\n amount: (val: number) => {\n if (isNaN(val)) return 'Amount must be a number';\n if (val < 0) return 'Amount cannot be negative';\n if (val > 100000) return 'Amount is too high';\n return true;\n },\n percent: (val: number) => {\n if (isNaN(val)) return 'Percent must be a number';\n if (val < 0 || val > 100) return 'Percent must be between 0 and 100';\n return true;\n }\n};\n\nconst adjustmentRules = computed(() => [\n settings['global_listing_price_adjustment_mode'] === 'percent'\n ? validators.percent\n : validators.amount\n]);\n\n\n// Handlers\nconst handlePriceAdjustmentUpdate = () => {\n const mode = settings['global_listing_price_adjustment_mode'];\n const value = displayPriceAdjustmentValue.value;\n let storedValue = mode === 'amount' ? value * 100 : value;\n\n if (storedValue < 0) {\n displayPriceAdjustmentValue.value = 0;\n return;\n }\n\n if (mode === 'percent' && storedValue > 100) {\n storedValue = 100;\n displayPriceAdjustmentValue.value = 100;\n }\n\n updateDefaultMeta('global_listing_price_adjustment_value', storedValue).then(() => {\n fetchSession();\n });\n};\n\n// Watchers\nwatch(\n () => settings['global_listing_price_adjustment_value'],\n (value) => {\n const raw = +value || 0;\n displayPriceAdjustmentValue.value =\n settings['global_listing_price_adjustment_mode'] === 'amount'\n ? raw * 0.01\n : raw;\n },\n {immediate: true}\n);\n\nwatch(\n () => settings['global_listing_price_adjustment_mode'],\n (newMode, oldMode) => {\n const currentValue = +settings['global_listing_price_adjustment_value'] || 0;\n\n if (newMode === 'amount' && oldMode === 'percent') {\n const newAmountInCents = currentValue * 100;\n updateDefaultMeta('global_listing_price_adjustment_value', newAmountInCents);\n displayPriceAdjustmentValue.value = newAmountInCents * 0.01;\n } else if (newMode === 'percent' && oldMode === 'amount') {\n const newPercent = currentValue * 0.01;\n if (newPercent > 100) {\n updateDefaultMeta('global_listing_price_adjustment_value', 10);\n displayPriceAdjustmentValue.value = 10;\n } else {\n updateDefaultMeta('global_listing_price_adjustment_value', newPercent);\n displayPriceAdjustmentValue.value = newPercent;\n }\n }\n }\n);\n</script>\n","<template>\n <div class=\"space-y-6\">\n <div class=\"md:grid md:grid-cols-3 md:gap-6\">\n <div class=\"md:col-span-1\">\n <div class=\"px-4 sm:px-0\">\n <h3 class=\"text-lg font-medium text-gray-900 dark:text-gray-100\">General</h3>\n <p class=\"mt-1 text-sm text-gray-600 dark:text-gray-400\">\n Configure how currency is displayed across your fleet. This affects all money values shown in the app,\n booking emails, SMS notifications, and Stripe payments.\n Need a different currency? Contact support to have it added.\n </p>\n </div>\n </div>\n\n\n <div class=\"mt-4 md:mt-0 md:col-span-2\">\n <v-card :disabled=\"companyLoading.saveCurrency\" class=\"mb-5\">\n <v-card-text>\n <div class=\"space-y-4\">\n <v-select\n v-model=\"settings['settings.pricing.currency.currency']\"\n :items=\"appCurrencies\"\n class=\"w-full\"\n item-title=\"name\"\n item-value=\"code\"\n label=\"Currency\"\n variant=\"outlined\"\n @update:model-value=\"val => updateDefaultMeta('settings.pricing.currency.currency', val)\"\n >\n <template v-slot:item=\"{ props, item }\">\n <v-list-item v-bind=\"props\">\n {{ item.raw.name }} ({{ item.raw.code }}) {{ item.raw.symbol }}\n </v-list-item>\n </template>\n <template v-slot:selection=\"{ item }\">\n <v-list-item>\n {{ item.raw.name }} ({{ item.raw.code }}) {{ item.raw.symbol }}\n </v-list-item>\n </template>\n </v-select>\n\n <div class=\"text-sm\">\n <b>Example:</b> {{ currencyExample }}\n </div>\n\n <div class=\"grid grid-cols-1 md:grid-cols-2 gap-4\">\n <v-select\n v-model=\"settings['settings.pricing.currency.format']\"\n :items=\"currencyDisplay\"\n class=\"w-full\"\n item-title=\"name\"\n item-value=\"value\"\n label=\"Display currency as\"\n variant=\"outlined\"\n @update:model-value=\"val => updateDefaultMeta('settings.pricing.currency.format', val)\"\n />\n <v-select\n v-model=\"settings['settings.pricing.currency.position']\"\n :items=\"currencyPosition\"\n class=\"w-full\"\n item-title=\"name\"\n item-value=\"value\"\n label=\"Currency position\"\n variant=\"outlined\"\n @update:model-value=\"val => updateDefaultMeta('settings.pricing.currency.position', val)\"\n />\n </div>\n </div>\n </v-card-text>\n </v-card>\n </div>\n </div>\n\n <GlobalPriceAdjustment/>\n </div>\n</template>\n\n<script lang=\"ts\" setup>\nimport {computed, ref, watch} from 'vue';\nimport GlobalPriceAdjustment from '@/components/dashboard/settings/pricing/GlobalPriceAdjustment.vue';\nimport {useCompany} from '@/composables/useCompany';\nimport {useAppSettings} from '@/composables/useAppSettings';\nimport {useDefaultMeta} from '@/composables/useDefaultMeta';\n\n\ninterface CurrencyShape {\n decimal: string;\n format: string;\n name: string;\n precision: number;\n symbol: string;\n thousand: string;\n}\n\ninterface DisplayOption {\n name: string;\n value: string;\n}\n\nconst DEFAULT_CURRENCY: CurrencyShape = {\n decimal: '.',\n format: '%s%v',\n name: 'USD',\n precision: 2,\n symbol: '$',\n thousand: ',',\n};\n\n// Composables\nconst {company, companyLoading} = useCompany();\nconst {appCurrencies, currentCurrency, fetchCurrency} = useAppSettings();\nconst {state: settings, updateDefaultMeta} = useDefaultMeta({\n 'settings.pricing.currency.format': {type: 'string', default: 'symbol'},\n 'settings.pricing.currency.position': {type: 'string', default: 'left'},\n 'settings.pricing.currency.currency': {type: 'string', default: 'USD'},\n});\n\n\nconst currentLocalCurrency = ref<CurrencyShape>({...DEFAULT_CURRENCY});\n\nconst currencyExample = computed(() => {\n const example = '312.00';\n const displaySymbol = settings['settings.pricing.currency.format'] === 'symbol';\n const symbol = displaySymbol ? currentLocalCurrency.value.symbol : currentLocalCurrency.value.name;\n\n return settings['settings.pricing.currency.position'] === 'left'\n ? `${symbol} ${example}`\n : `${example} ${symbol}`;\n});\n\nconst currencyDisplay = computed<DisplayOption[]>(() => [\n {name: `Symbol (${currentLocalCurrency.value.symbol})`, value: 'symbol'},\n {name: `Code (${currentLocalCurrency.value.name})`, value: 'code'},\n]);\n\nconst currencyPosition = computed<DisplayOption[]>(() => [\n {name: `${currentLocalCurrency.value.symbol} 123.00`, value: 'left'},\n {name: `123.00 ${currentLocalCurrency.value.symbol}`, value: 'right'},\n]);\n\n// Watchers\nwatch(company, (newCompany) => {\n if (newCompany?.uuid) {\n currentLocalCurrency.value = {...newCompany.currency};\n }\n}, {immediate: true});\n\nwatch(() => settings['settings.pricing.currency.currency'], (code) => {\n if (code) fetchCurrency(code);\n});\n\nwatch(currentCurrency, (currency) => {\n if (!currency) return;\n\n currentLocalCurrency.value = {\n ...DEFAULT_CURRENCY,\n name: currency.name,\n symbol: currency.symbol ?? DEFAULT_CURRENCY.symbol,\n };\n});\n</script>\n","import {useStore} from 'vuex';\nimport {computed} from 'vue';\nimport {Coupon, StoreLoaders} from '@/types';\n\nexport function useCoupons() {\n const store = useStore();\n\n const coupons = computed<Coupon[]>(() => store.getters['coupon/coupons']);\n const couponLoading = computed<StoreLoaders>(() => store.getters['coupon/loading']);\n\n const couponForm = computed(() => store.getters['coupon/form']);\n const couponRedemptions = computed(() => store.getters['coupon/redemptions']);\n\n const fetchCoupons = async () => {\n return await store.dispatch('coupon/fetchCoupons');\n }\n\n const clearCoupons = async () => {\n return store.commit('coupon/SET_COUPONS', []);\n }\n\n const createCoupon = async (coupon: Coupon) => {\n return await store.dispatch('coupon/createCoupon', coupon);\n }\n const updateCoupon = async (coupon: Coupon) => {\n couponForm.value.errors.clear();\n return await store.dispatch('coupon/updateCoupon', coupon);\n }\n const deleteCoupon = async (couponUuid: string) => {\n return await store.dispatch('coupon/deleteCoupon', couponUuid);\n }\n\n const getCouponRedemptions = async (coupon: string) => {\n return await store.dispatch('coupon/redemptions', coupon);\n }\n\n const currentCouponReset = async (coupon: Coupon) => {\n return await store.dispatch('coupon/currentCouponReset', coupon);\n }\n\n const toggleCouponActive = async (coupon: Coupon) => {\n return await store.dispatch('coupon/toggleCouponActive', coupon);\n }\n\n const multiCouponToggle = async (coupons: Coupon[]) => {\n return await store.dispatch('coupon/multiCouponToggle', coupons);\n }\n\n const multiCouponDelete = async (coupons: Coupon[]) => {\n return await store.dispatch('coupon/multiCouponDelete', coupons);\n }\n\n return {\n coupons,\n couponLoading,\n couponForm,\n couponRedemptions,\n fetchCoupons,\n createCoupon,\n updateCoupon,\n deleteCoupon,\n getCouponRedemptions,\n currentCouponReset,\n toggleCouponActive,\n multiCouponToggle,\n multiCouponDelete,\n clearCoupons,\n }\n}","import {computed, ref} from 'vue';\nimport {Coupon} from '@/types';\n\nexport function useCouponForm() {\n const couponClone = ref<Coupon>({\n uuid: '',\n code: '',\n type: 'percent',\n amount: 20,\n limit: -1,\n count: 10,\n reason: '',\n notes: '',\n start_at: '',\n end_at: '',\n schedule: true,\n active: true,\n listings: [],\n user_limit: -1\n });\n\n const currentCouponListings = ref(true);\n const currentCouponUsersOn = ref(false);\n const currentCouponUsers = ref(1);\n const couponLimit = ref(false);\n const couponFormValid = ref(false);\n\n const currentCouponAmount = computed({\n get() {\n const amount = couponClone.value.amount;\n return couponClone.value.type === 'amount' ? amount * 0.01 : amount;\n },\n set(value) {\n couponClone.value.amount = couponClone.value.type === 'amount' ? value * 100 : value;\n }\n });\n\n const couponRules = computed(() => ({\n reason: couponClone.value.reason ? [\n couponClone.value.reason.length <= 40 || 'Max 40 characters'\n ] : [],\n code: [\n couponClone.value.code.length > 0 || 'Coupon code is required',\n couponClone.value.code.length <= 200 || 'Max 200 characters'\n ],\n amount: couponClone.value.type === 'percent'\n ? [(couponClone.value.amount > 0 && couponClone.value.amount <= 100) || 'A percent based discount must be between 0 and 100 percent.']\n : [(couponClone.value.amount > 0 && couponClone.value.amount < 1000000000) || 'An amount based discount must be between 0 and 10,000,000.']\n }));\n\n const resetForm = () => {\n couponClone.value = {\n uuid: '',\n code: '',\n type: 'percent',\n amount: 20,\n limit: -1,\n count: 10,\n reason: '',\n notes: '',\n start_at: '',\n end_at: '',\n schedule: true,\n active: true,\n listings: [],\n user_limit: -1\n };\n currentCouponListings.value = true;\n currentCouponUsersOn.value = false;\n currentCouponUsers.value = 1;\n couponLimit.value = false;\n couponFormValid.value = false;\n };\n\n const updateListings = (listings: any[]) => {\n if (currentCouponListings.value) {\n couponClone.value.listings = [];\n } else {\n couponClone.value.listings = listings;\n }\n };\n\n const updateUserLimit = () => {\n if (currentCouponUsersOn.value) {\n couponClone.value.user_limit = +currentCouponUsers.value === -1 ? 1 : +currentCouponUsers.value;\n currentCouponUsers.value = couponClone.value.user_limit;\n } else {\n couponClone.value.user_limit = -1;\n }\n };\n\n return {\n couponClone,\n currentCouponListings,\n currentCouponUsersOn,\n currentCouponUsers,\n couponLimit,\n couponFormValid,\n currentCouponAmount,\n couponRules,\n resetForm,\n updateListings,\n updateUserLimit\n };\n} ","<template>\n <div>\n <v-card max-width=\"100%\">\n <v-alert\n v-if=\"!includedInSubscription('coupons')\"\n class=\"card-alert-full\"\n density=\"compact\"\n type=\"warning\"\n >\n <div class=\"sm:flex block\">\n <div class=\"flex-grow\">Coupons are a standard & premium feature.</div>\n <v-btn :to=\"{name: 'settings.account'}\" class=\"flex-shrink\" size=\"x-small\">Upgrade</v-btn>\n </div>\n </v-alert>\n\n <v-card-title style=\"margin-top: 5px\">\n <FeatureTitle\n featurePremium\n featureStandard\n title=\"Coupons\"\n />\n </v-card-title>\n\n <v-card-text>\n\n <div v-if=\"couponsExist\">\n <v-text-field\n v-model=\"search\"\n append-icon=\"mdi-search\"\n class=\"mb-2\"\n hide-details\n label=\"Search\"\n variant=\"outlined\"\n ></v-text-field>\n <div class=\"relative overflow-x-auto shadow-md sm:rounded-lg\">\n <table class=\"w-full text-sm text-left text-gray-500 dark:text-gray-400\">\n <thead class=\"text-xs text-gray-700 uppercase bg-gray-50 dark:bg-gray-700 dark:text-gray-400\">\n <tr>\n <th class=\"px-6 py-3\" scope=\"col\">Code</th>\n <th class=\"px-6 py-3\" scope=\"col\">Type</th>\n <th class=\"px-6 py-3\" scope=\"col\">Amount</th>\n <th class=\"px-6 py-3\" scope=\"col\">Active</th>\n <th class=\"px-6 py-3\" scope=\"col\">Listings</th>\n <th class=\"px-6 py-3\" scope=\"col\">Limit</th>\n </tr>\n </thead>\n <tbody>\n <tr v-for=\"item in couponsFiltered\" :key=\"item.uuid\">\n <th class=\"px-6 py-4 font-medium text-gray-900 whitespace-nowrap dark:text-white\" scope=\"row\">\n <span style=\"cursor: pointer\" @click=\"editCode(item)\">{{ item.code }}</span>\n </th>\n <td class=\"px-6 py-4\">\n {{ item.type }}\n </td>\n <td class=\"px-6 py-4\">\n <span v-if=\"item.type === 'amount'\">\n {{ formatMoneyDisplayV2(item.amount) }}\n </span>\n <span v-else>{{ item.amount }}<small class=\"ml-1\">%</small></span>\n </td>\n <td class=\"px-6 py-4\">\n <span v-if=\"item.active\" class=\"text-green-500\">Active</span>\n <span v-else class=\"text-red-500\">Inactive</span>\n </td>\n <td class=\"px-6 py-4\">\n {{\n item.listings?.length === 0 || fleetResourceListings.length === item.listings?.length ? 'All' :\n item.listings?.length\n }}\n </td>\n <td class=\"px-6 py-4\">\n <span v-if=\"item.limit < 0\">{{ item.count || 0 }}/<v-icon\n size=\"small\">mdi-infinity</v-icon></span>\n <span v-else>{{ item.count || 0 }}/{{ item.limit }}</span>\n </td>\n </tr>\n </tbody>\n </table>\n </div>\n </div>\n\n <div v-else>No Coupons Yet</div>\n </v-card-text>\n <v-card-actions>\n <v-btn\n :disabled=\"!includedInSubscription('coupons')\"\n :loading=\"couponLoading.company\"\n class=\"ml-2\"\n @click=\"importCoupons()\"\n >\n Import\n </v-btn>\n <v-spacer/>\n <v-btn\n :disabled=\"!includedInSubscription('coupons')\"\n :loading=\"couponLoading.company\"\n class=\"mr-2\"\n @click=\"addCoupon()\"\n >\n Add Coupon\n </v-btn>\n </v-card-actions>\n </v-card>\n\n <v-dialog v-model=\"importCouponsDialog\" :scrim=\"false\" fullscreen transition=\"dialog-bottom-transition\">\n <v-card>\n <v-toolbar color=\"primary\" theme=\"dark\">\n <v-btn theme=\"dark\" variant=\"text\" @click=\"importCouponsDialog = false\">\n <v-icon>mdi-close</v-icon>\n </v-btn>\n <v-toolbar-title>Import Coupons</v-toolbar-title>\n <v-spacer></v-spacer>\n <v-toolbar-items>\n <v-btn theme=\"dark\" variant=\"text\" @click=\"importCouponsDialog = false\">Okay</v-btn>\n </v-toolbar-items>\n </v-toolbar>\n <v-list lines=\"three\">\n <v-list-item>\n\n <v-list-item-title>Coming soon</v-list-item-title>\n <v-list-item-subtitle>Ability to import a large number of coupon codes.\n </v-list-item-subtitle>\n\n </v-list-item>\n </v-list>\n <v-divider/>\n </v-card>\n </v-dialog>\n\n <v-dialog v-model=\"couponDialog\" :max-width=\"couponTab === 1 ? 600 : 850\" :persistent=\"couponDialogMode === 'add'\">\n <v-form v-model=\"couponFormValid\" :disabled=\"couponForm.busy\">\n <v-card :loading=\"couponForm.busy\">\n <v-scroll-y-transition hide-on-leave>\n <v-card-title v-if=\"couponTab === 1\">\n <div class=\"flex\">\n <span class=\"text-h5\">{{ couponDialogTitle }}</span>\n <v-spacer/>\n <div class=\"flex items-center\">\n <span class=\"text-muted mr-3\">{{ couponClone.active ? 'Active' : 'Inactive' }}</span>\n <v-switch v-model=\"couponClone.active\" :inset=\"true\" color=\"green\" density=\"compact\" hide-details></v-switch>\n </div>\n </div>\n </v-card-title>\n </v-scroll-y-transition>\n\n <v-window v-model=\"couponTab\">\n <v-window-item :value=\"1\">\n <v-card-text v-if=\"couponDialogMode === 'add'\">\n <div class=\"coupon-form\">\n <v-text-field\n v-model=\"couponClone.code\"\n :error=\"couponForm.errors.has('code')\"\n :rules=\"couponRules.code\"\n class=\"coupon-code mx-2\"\n label=\"Code\"\n name=\"code\"\n required\n variant=\"outlined\"\n @keyup=\"store.commit('coupon/CLEAR_COUPON_FORM_ERRORS', 'code')\"\n ></v-text-field>\n\n <v-btn-toggle v-model=\"couponClone.type\" class=\"coupon-type-btn ml-2 h-100\" mandatory>\n <v-btn value=\"percent\">\n <span class=\"bold\">%</span>\n </v-btn>\n <v-btn value=\"amount\">\n <span class=\"bold\">{{ companyCurrencySymbol() }}</span>\n </v-btn>\n </v-btn-toggle>\n\n <v-text-field\n v-model=\"currentCouponAmount\"\n :prefix=\"couponClone.type === 'amount' ? companyMoneyTextInputSettings.prefix : ''\"\n :rules=\"couponRules.amount\"\n :suffix=\"couponClone.type === 'percent' ? '%' : companyMoneyTextInputSettings.suffix\"\n class=\"coupon-value\"\n variant=\"outlined\"\n />\n </div>\n <div class=\"limit-section mt-4\">\n <v-checkbox\n v-model=\"couponLimit\"\n class=\"mb-2\"\n label=\"Limit the total number of times this coupon can be redeemed\"\n ></v-checkbox>\n <v-text-field\n v-show=\"couponLimit\"\n v-model=\"couponClone.limit\"\n class=\"mt-2\"\n hint=\"How many times can this coupon be used?\"\n label=\"Limit\"\n min=\"0\"\n persistent-hint\n type=\"number\"\n variant=\"outlined\"\n ></v-text-field>\n </div>\n <span class=\"small italic\">There will be more coupon settings once created.</span>\n\n <v-scroll-x-transition>\n <v-alert v-if=\"couponForm.errors.any()\" class=\"mt-3\" density=\"compact\" type=\"error\" variant=\"outlined\">\n <div v-for=\"(error, key) in couponForm.errors.flatten()\" :key=\"key\">\n {{ error }}\n </div>\n </v-alert>\n </v-scroll-x-transition>\n </v-card-text>\n <v-card-text v-else-if=\"couponClone\">\n <h5 class=\"mb-2 text-3xl font-bold text-gray-900 dark:text-white\">{{ couponClone.code }}</h5>\n <p>{{ couponClone.type === 'amount' ? 'Fixed amount discount' : 'Percentage discount' }}\n ({{\n couponClone.type === 'amount' ? formatMoneyDisplayV2(currentCouponAmount, false) :\n `${currentCouponAmount}%`\n }})\n </p>\n <p>{{ couponClone.limit >= 0 ? `Limited to ${couponClone.limit} uses` : 'Unlimited uses' }}</p>\n\n <v-expansion-panels>\n <v-expansion-panel>\n <v-expansion-panel-title>\n <span v-if=\"currentCouponListings\">All Listings</span>\n <span v-else>Allow for {{ couponClone.listings.length }} Listings</span>\n </v-expansion-panel-title>\n <v-expansion-panel-text>\n <div class=\"grid grid-cols-3 gap-2\" style=\"min-height: 125px;\">\n <div class=\"\">\n <v-switch\n v-model=\"currentCouponListings\"\n :inset=\"true\"\n density=\"compact\"\n hide-details\n label=\"All listings\"\n @update:model-value=\"currentCouponListingsUpdate()\"\n />\n </div>\n <div class=\"col-span-2\">\n <v-autocomplete\n v-show=\"!currentCouponListings\"\n v-model=\"couponClone.listings\"\n :items=\"fleetResourceListings\"\n chips\n class=\"mx-2\"\n closable-chips\n color=\"blue-grey-lighten-2\"\n hide-details\n item-title=\"name\"\n item-value=\"l_id\"\n label=\"Listings\"\n multiple\n variant=\"outlined\"\n >\n <template v-slot:prepend-item>\n <v-list-item title=\"Select All Listings\" @click=\"toggle\">\n <template v-slot:prepend>\n <v-checkbox-btn\n :color=\"fleetResourceListings.length > 0 ? 'indigo-darken-4' : undefined\"\n :indeterminate=\"wantsSomeListings && !wantsAllListings\"\n :model-value=\"wantsAllListings\"\n />\n </template>\n </v-list-item>\n <v-divider class=\"mt-2\" opacity=\"50\"></v-divider>\n </template>\n <template v-slot:chip=\"data\">\n <v-chip\n v-if=\"data.index === 0\"\n :closable=\"true\"\n :model-value=\"data.selected\"\n v-bind=\"data.props\"\n @click=\"data.select\"\n @click:close=\"removeListing(data.item.raw as ListingInterface)\"\n >\n <v-avatar start>\n <v-img :src=\"listingVehicleImage(data.item.raw as ListingInterface)\"></v-img>\n </v-avatar>\n {{ listingNameDisplay(data.item.raw as ListingInterface) }}\n </v-chip>\n <span\n v-if=\"data.index === 1\"\n class=\"text-grey text-caption\"\n >\n (+{{ couponClone.listings.length - 1 }} others)\n </span>\n </template>\n <template v-slot:item=\"{ props, item }\">\n <v-list-item\n :prepend-avatar=\"listingVehicleImage(item.raw as ListingInterface)\"\n :title=\"listingNameDisplay(item.raw as ListingInterface)\"\n v-bind=\"props\"\n />\n </template>\n </v-autocomplete>\n </div>\n </div>\n </v-expansion-panel-text>\n </v-expansion-panel>\n <v-expansion-panel>\n <v-expansion-panel-title>\n <span v-if=\"currentCouponUsersOn\">Limit Renter uses to {{ currentCouponUsers }}</span>\n <span v-else>Renters can use unlimited</span>\n </v-expansion-panel-title>\n <v-expansion-panel-text>\n <div class=\"grid grid-cols-1 gap-2\">\n <div>\n <v-switch\n v-model=\"currentCouponUsersOn\"\n :inset=\"true\"\n density=\"compact\"\n hide-details\n label=\"Limit number of times this coupon can be used per customer\"\n @update:model-value=\"currentCouponUserUpdate()\"\n />\n </div>\n <div>\n <v-text-field\n v-show=\"currentCouponUsersOn\"\n v-model=\"currentCouponUsers\"\n class=\"coupon-code mx-2\"\n hide-details\n label=\"Limit\"\n min=\"1\"\n persistent-hint\n type=\"number\"\n variant=\"outlined\"\n ></v-text-field>\n </div>\n </div>\n </v-expansion-panel-text>\n </v-expansion-panel>\n <v-expansion-panel>\n <v-expansion-panel-title>\n Reason\n <span v-if=\"couponClone.reason\">: {{ currentCouponReasonEllipsis }}</span>\n </v-expansion-panel-title>\n <v-expansion-panel-text>\n <v-text-field\n v-model=\"couponClone.reason\"\n :counter=\"40\"\n :error=\"couponForm.errors.has('reason')\"\n :persistent-hint=\"true\"\n :rules=\"couponRules.reason\"\n class=\"coupon-code mx-2\"\n hint=\"This will appear on customers' receipts and invoices.\"\n label=\"Reason\"\n required\n variant=\"outlined\"\n @keyup=\"couponForm.errors.clear('reason')\"\n ></v-text-field>\n </v-expansion-panel-text>\n </v-expansion-panel>\n </v-expansion-panels>\n\n <v-alert v-if=\"couponForm.errors.any()\" class=\"mt-3\" density=\"compact\" type=\"warning\">\n {{ couponForm.errors.flatten()[0] }}\n </v-alert>\n\n <v-btn class=\"mt-5\" size=\"small\" variant=\"text\" @click=\"couponTab = 2\">View Redemptions</v-btn>\n </v-card-text>\n </v-window-item>\n\n <v-window-item :value=\"2\">\n <v-card-title>Redemptions</v-card-title>\n <v-card-text>\n <div>\n <div v-if=\"couponRedemptions.length === 0 && couponLoading.redemptions\">Loading...</div>\n\n <v-data-table\n v-else-if=\"couponRedemptions.length > 0\"\n :headers=\"orderHeaders\"\n :items=\"couponRedemptions\"\n :loading=\"couponLoading.redemptions\"\n :mobile-breakpoint=\"0\"\n class=\"elevation-0\"\n item-key=\"b_id\"\n >\n <template v-slot:body=\"{ items }\">\n <tbody class=\"overflow-hidden overflow-x-auto\">\n <tr v-for=\"(item, index) in items\" :key=\"(item as VDataTableItem).name\">\n <td class=\"w-48\">\n <div class=\"d-flex align-items-start\">\n <div class=\"mr-2\">\n <div class=\"image-container image-responsive rounded\" style=\"width: 40px\">\n <div class=\"image-resizer\" style=\"padding-bottom: 100%;\"></div>\n <div :style=\"`background-image: url(${listingVehicleImage((item as VDataTableItem).listing)});`\" class=\"fw-image\" style=\"background-position: center center;\"></div>\n <div class=\"fw-responsive__content\"></div>\n </div>\n </div>\n <router-link v-if=\"(item as VDataTableItem).listing?.l_id\" :to=\"{ name: 'listing.single', params: {l_id: (item as VDataTableItem).listing?.l_id } }\" class=\"small\">\n {{ listingNameDisplay((item as VDataTableItem).listing) }}\n </router-link>\n </div>\n </td>\n <td style=\"min-width: 190px\">\n <CustomerPopoverMenu :customer=\"(item as VDataTableItem).renter\" :item-index=\"index\">\n <template v-slot:customerName>\n <span>{{ (item as VDataTableItem).renter?.full_name }}</span>\n </template>\n </CustomerPopoverMenu>\n </td>\n <td class=\"w-48\">\n <span v-if=\"checkPermission(['orders_financials'])\">\n {{ formatMoneyDisplayV2((item as VDataTableItem).total) }}\n </span>\n <span v-else v-tippy content=\"You need permission to view financial data\"><v-icon>mdi-eye-off-outline</v-icon></span>\n </td>\n <td class=\"w-48\">\n <span v-if=\"checkPermission(['orders_financials'])\">\n {{ formatMoneyDisplayV2((item as VDataTableItem).discount) }}\n </span>\n <span v-else v-tippy content=\"You need permission to view financial data\"><v-icon>mdi-eye-off-outline</v-icon></span>\n </td>\n <td style=\"min-width: 185px\">\n <router-link :to=\"{ name: 'orders.single', params: {b_id: (item as VDataTableItem).b_id} }\">\n <span v-html=\"(item as VDataTableItem).b_id\"></span>\n </router-link>\n </td>\n <td style=\"min-width: 190px\">\n {{ formatBookingDate((item as VDataTableItem).trip_start) }}\n </td>\n <td style=\"min-width: 190px\">\n {{ formatBookingDate((item as VDataTableItem).trip_end) }}\n </td>\n <td class=\"w-52\">\n <span :class=\"classObject(item as VDataTableItem)\" class=\"badge\">{{\n (item as VDataTableItem).status\n }}</span>\n </td>\n <td class=\"w-56\">\n {{ (item as VDataTableItem).source }}\n </td>\n <td style=\"min-width: 185px\">\n {{ formatBookingDate((item as VDataTableItem).created_at) }}\n </td>\n </tr>\n </tbody>\n </template>\n <template v-slot:no-data>No Redemptions</template>\n </v-data-table>\n <div v-else>No Redemptions</div>\n </div>\n <v-btn class=\"mt-5\" size=\"small\" variant=\"text\" @click=\"couponTab = 1\">Back</v-btn>\n </v-card-text>\n </v-window-item>\n </v-window>\n\n <v-scroll-y-reverse-transition leave-absolute>\n <v-card-actions v-if=\"couponTab === 1\">\n <DeleteButton\n v-if=\"couponDialogMode === 'edit' && !confirmCouponDelete\"\n :loading=\"couponLoading.delete_coupon\"\n @delete-confirmed=\"deleteCouponCommit(couponClone)\"\n />\n <v-spacer/>\n <v-btn :disabled=\"couponForm.busy\" color=\"grey\" size=\"small\"\n variant=\"text\"\n @click=\"couponDialog = false; confirmCouponDelete = false\" v-text=\"$t('close')\"></v-btn>\n <v-btn v-if=\"couponDialogMode === 'edit'\" :disabled=\"!couponFormValid\"\n :loading=\"couponLoading.update_coupon\" color=\"primary\"\n @click=\"updateCouponCommit(couponClone); confirmCouponDelete = false\" v-text=\"$t('update')\"></v-btn>\n <v-btn\n v-if=\"couponDialogMode === 'add'\"\n :disabled=\"!couponFormValid\"\n :loading=\"couponLoading.save_coupon\"\n color=\"primary\"\n @click=\"createCouponCommit(couponClone)\"\n v-text=\"$t('create')\"\n ></v-btn>\n </v-card-actions>\n </v-scroll-y-reverse-transition>\n </v-card>\n </v-form>\n </v-dialog>\n\n <UpgradePlanFeatureDialog2\n :bullets=\"[{text: 'Offer coupons for vehicle rentals, providing renters with exclusive discounts and promotions.'},\n { text: 'Foster loyalty and referrals by rewarding renters with coupons, cultivating lasting relationships within your rental platform.',},\n {text: 'Drive loyalty and recommendations with coupon incentives, nurturing lasting connections within your rental network.',},\n ]\"\n :tiers=\"['standard', 'premium']\"\n description=\"Unlock extra value for your vehicle rental experience – Upgrade to Standard or Premium plans to access exclusive coupons and enhance your rentals with special discounts.\"\n feature=\"Coupons\"\n right-side-message=\"Create coupons for your most loyal renters and reward them with special discounts.\"\n >\n <template v-slot:rightImage>\n <v-img alt=\"\" src=\"/images/upgrade_coupons.png\"/>\n </template>\n </UpgradePlanFeatureDialog2>\n </div>\n</template>\n\n<script lang=\"ts\" setup>\nimport {computed, defineAsyncComponent, onBeforeMount, onBeforeUnmount, ref, watch} from 'vue';\nimport dayjs from 'dayjs';\nimport {useStore} from 'vuex';\n\nimport {useMoneyFormatter} from '@/composables/useMoneyFormatter';\nimport {Coupon, ListingInterface} from '@/types';\nimport {useSubscription} from '@/composables/useSubscription';\nimport checkPermission from '@/utils/permission';\nimport {useListing} from '@/composables/useListing';\nimport {useCoupons} from '@/composables/useCoupons';\nimport {useCouponForm} from '@/composables/useCouponForm';\n\ninterface VDataTableItem {\n name: string;\n listing: ListingInterface;\n renter: any;\n total: number;\n discount: number;\n b_id: string;\n trip_start: string;\n trip_end: string;\n status: string;\n source: string;\n created_at: string;\n}\n\nconst UpgradePlanFeatureDialog2 = defineAsyncComponent(() => import('@/components/dashboard/dialogs/UpgradePlanFeatureDialog2.vue'));\nconst CustomerPopoverMenu = defineAsyncComponent(() => import('@/components/dashboard/customers/CustomerPopoverMenu.vue'));\nconst FeatureTitle = defineAsyncComponent(() => import('@/components/dashboard/FeatureTitle.vue'));\nconst DeleteButton = defineAsyncComponent(() => import('@/components/buttons/DeleteButton.vue'));\n\nconst store = useStore();\nconst {includedInSubscription} = useSubscription();\nconst {formatMoneyDisplayV2, companyMoneyTextInputSettings, companyCurrencySymbol} = useMoneyFormatter();\nconst {\n fleetResourceListings,\n listingVehicleImage,\n listingNameDisplay,\n fetchListings,\n fetchFleetResourcesListings\n} = useListing();\nconst {\n coupons,\n couponLoading,\n couponForm,\n couponRedemptions,\n fetchCoupons,\n createCoupon,\n updateCoupon,\n deleteCoupon,\n getCouponRedemptions,\n clearCoupons,\n} = useCoupons();\n\nconst {\n couponClone,\n currentCouponListings,\n currentCouponUsersOn,\n currentCouponUsers,\n couponLimit,\n couponFormValid,\n currentCouponAmount,\n couponRules,\n resetForm,\n updateListings,\n updateUserLimit\n} = useCouponForm();\n\nconst couponDialog = ref(false);\nconst search = ref('');\nconst couponTab = ref(1);\nconst couponDialogMode = ref('add');\nconst couponDialogTitle = ref('Add Coupon');\nconst confirmCouponDelete = ref(false);\nconst selectedCoupons = ref([]);\nconst importCouponsDialog = ref(false);\nconst listingsClone = ref([]);\nconst confirmMultiCouponToggle = ref(false);\n\nconst orderHeaders = [\n {text: 'Listing', value: 'listing', width: 200},\n {text: 'Renter', value: 'renter', width: 200},\n {text: 'Total', value: 'total', width: 200},\n {text: 'Discount', value: 'discount', width: 200},\n {text: 'Order ID', value: 'b_id', width: 200},\n {text: 'Start Date', value: 'trip_start', width: 200},\n {text: 'End Date', value: 'trip_end', width: 200},\n {text: 'Status', value: 'status', width: 200},\n {text: 'Source', value: 'source', width: 200},\n {text: 'Created At', value: 'created_at', width: 200},\n];\n\n// Computed properties\nconst couponsFiltered = computed(() => {\n const searchTerm = search.value.toLowerCase();\n if (!coupons.value) return coupons.value;\n return coupons.value.filter(coupon =>\n coupon.code.toLowerCase().includes(searchTerm)\n );\n});\n\n\nconst currentCouponReasonEllipsis = computed(() => {\n return (couponClone.value?.reason ?? '').length > 40\n ? `${couponClone.value.reason.substring(0, 40)}...`\n : couponClone.value.reason;\n});\n\nconst couponsExist = computed(() => {\n if (coupons.value === undefined) return false;\n return coupons.value.length;\n});\n\nconst wantsAllListings = computed(() =>\n (couponClone.value?.listings ?? []).length === fleetResourceListings.value.length\n);\n\nconst wantsSomeListings = computed(() =>\n (couponClone.value?.listings ?? []).length > 0 && !wantsAllListings.value\n);\n\nconst icon = computed(() => {\n if (wantsAllListings.value) return 'mdi-close-box';\n if (wantsSomeListings.value) return 'mdi-minus-box';\n return 'mdi-checkbox-blank-outline';\n});\n\n// Methods\nconst classObject = (item: VDataTableItem) => ({\n 'badge--success': item.status === 'completed',\n 'badge--warning': item.status === 'pending',\n 'badge--error': item.status === 'cancelled',\n});\n\nconst deleteCouponCommit = async (coupon: Coupon) => {\n await deleteCoupon(coupon.uuid);\n couponDialog.value = false;\n};\n\nconst createCouponCommit = async (coupon: Coupon) => {\n await createCoupon(coupon);\n couponDialog.value = false;\n setTimeout(() => {\n resetForm();\n }, 300);\n};\n\nconst updateCouponCommit = async (coupon: Coupon) => {\n await updateCoupon(coupon);\n couponDialog.value = false;\n setTimeout(() => {\n resetForm();\n }, 300);\n};\n\nconst addCoupon = () => {\n couponDialogMode.value = 'add';\n couponDialogTitle.value = 'Add Coupon';\n couponDialog.value = true;\n};\n\nconst editCode = async (code: Coupon) => {\n try {\n await fetchFleetResourcesListings();\n listingsClone.value = JSON.parse(JSON.stringify(fleetResourceListings.value));\n couponClone.value = JSON.parse(JSON.stringify(code));\n couponDialog.value = true;\n couponDialogTitle.value = 'Edit Coupon';\n couponDialogMode.value = 'edit';\n\n const hasNoListings = code.listings.length === 0;\n const hasAllListings = code.listings.length === fleetResourceListings.value.length;\n currentCouponListings.value = hasNoListings || hasAllListings;\n\n currentCouponUsersOn.value = code.user_limit > 0;\n currentCouponUsers.value = Number(code.user_limit);\n } catch (error) {\n console.error('Error while editing coupon:', error);\n }\n};\n\nconst importCoupons = () => {\n importCouponsDialog.value = true;\n};\n\nconst currentCouponListingsUpdate = () => {\n updateListings(fleetResourceListings.value);\n};\n\nconst currentCouponUserUpdate = () => {\n updateUserLimit();\n};\n\nconst toggle = () => {\n if (wantsAllListings.value) {\n couponClone.value.listings = [];\n } else {\n couponClone.value.listings = fleetResourceListings.value.slice();\n }\n};\n\nconst removeListing = (item: ListingInterface) => {\n const index = couponClone.value.listings.findIndex((l: ListingInterface) => l.l_id === item.l_id);\n if (index >= 0) couponClone.value.listings.splice(index, 1);\n};\n\nconst formatBookingDate = (bookingDate: string) => {\n return dayjs(bookingDate).format('ddd, MMM D @ h:mma');\n};\n\n// Watchers\nwatch(couponDialog, (dialog) => {\n store.commit('coupon/SET_COUPON_REDEMPTIONS', []);\n couponTab.value = 1;\n if (dialog && fleetResourceListings.value.length === 0) {\n fetchListings();\n }\n if (!dialog) {\n setTimeout(() => {\n resetForm();\n }, 300);\n }\n});\n\nwatch(couponTab, (tab) => {\n if (tab === 2 && couponClone.value) {\n getCouponRedemptions(couponClone.value.uuid);\n }\n});\n\nwatch(couponLimit, (limit) => {\n couponClone.value.limit = limit ? 1 : -1;\n});\n\nwatch(selectedCoupons, () => {\n confirmMultiCouponToggle.value = false;\n});\n\nwatch(currentCouponUsers, (users) => {\n couponClone.value.user_limit = +users;\n});\n\n// Lifecycle hooks\nonBeforeMount(() => {\n fetchCoupons();\n});\n\nonBeforeUnmount(() => {\n clearCoupons();\n});\n</script>\n\n<style>\n.coupon-type-btn button {\n height: 56px !important;\n}\n\n.coupon-form {\n display: flex;\n flex-wrap: wrap;\n gap: 8px;\n align-items: flex-start;\n}\n\n.coupon-form .coupon-code {\n width: 175px;\n flex: 1;\n min-width: 175px;\n}\n\n.coupon-form .coupon-value {\n width: 100px;\n flex: 0 0 100px;\n}\n\n.limit-section {\n width: 100%;\n max-width: 100%;\n}\n\n@media (max-width: 600px) {\n .coupon-form {\n flex-direction: column;\n width: 100%;\n }\n\n .coupon-form .coupon-code,\n .coupon-form .coupon-value {\n width: 100%;\n min-width: 100%;\n }\n\n .coupon-type-btn {\n width: 100%;\n margin: 8px 0;\n }\n\n .coupon-type-btn button {\n flex: 1;\n }\n}\n\n.select-all-item {\n min-height: 48px;\n padding: 0 16px;\n white-space: nowrap;\n}\n\n.select-all-item .v-list-item-action {\n margin-right: 16px;\n}\n\n.select-all-item .v-list-item-title {\n font-size: 0.875rem;\n font-weight: 500;\n white-space: nowrap;\n overflow: hidden;\n text-overflow: ellipsis;\n}\n</style>\n","<template>\n <div>\n <v-dialog\n v-model=\"dialog\"\n width=\"500\"\n >\n <v-card>\n <v-card-title>\n Pricing Rule\n <v-spacer/>\n <v-chip color=\"orange text-white\" label>Automation</v-chip>\n </v-card-title>\n\n <v-card-text>\n <v-select\n v-model=\"rule\"\n :items=\"rules\"\n density=\"compact\"\n hide-details\n item-title=\"label\"\n item-value=\"value\"\n label=\"Rule\"\n variant=\"outlined\"\n ></v-select>\n\n <div v-if=\"rule === 'raise-lower-prices'\" class=\"mt-5\">\n <v-menu open-on-hover>\n <template v-slot:activator=\"{ props }\">\n <v-btn\n size=\"x-small\"\n v-bind=\"props\"\n variant=\"text\"\n >\n <span class=\"i-in-place-edit\">\n {{ ruleData['raise-lower-prices'].action }}\n </span>\n </v-btn>\n </template>\n\n <v-list>\n <v-list-item v-model=\"ruleData['raise-lower-prices'].action\" mandatory>\n <v-list-item value=\"raise\">\n <v-list-item-title>Raise</v-list-item-title>\n </v-list-item>\n <v-list-item value=\"lower\">\n <v-list-item-title>Lower</v-list-item-title>\n </v-list-item>\n </v-list-item>\n </v-list>\n </v-menu>\n listing prices if there are\n <v-menu :close-on-content-click=\"false\" open-on-hover>\n <template v-slot:activator=\"{ props }\">\n <v-btn size=\"x-small\" v-bind=\"props\" variant=\"text\">\n <span class=\"i-in-place-edit\">\n {{ ruleData['raise-lower-prices'].booking_cnt }}\n </span>\n </v-btn>\n </template>\n\n <v-card>\n <v-card-text>\n <v-text-field\n v-model=\"ruleData['raise-lower-prices'].booking_cnt\"\n label=\"Booking Count\"\n max=\"365\"\n min=\"0\"\n type=\"number\"\n variant=\"outlined\"\n ></v-text-field>\n </v-card-text>\n </v-card>\n </v-menu>\n bookings in the\n <v-menu :close-on-content-click=\"false\" open-on-hover>\n <template v-slot:activator=\"{ props }\">\n <v-btn\n size=\"x-small\"\n v-bind=\"props\"\n variant=\"text\"\n >\n <span class=\"i-in-place-edit\" v-text=\"ruleData['raise-lower-prices'].timeframe.timeframe_label()\"></span>\n </v-btn>\n </template>\n <v-card>\n <v-card-text class=\"mt-4\">\n <v-radio-group v-model=\"ruleData['raise-lower-prices'].timeframe.term\" inline>\n <v-radio label=\"Last\" value=\"last\"></v-radio>\n <v-radio label=\"Next\" value=\"next\"></v-radio>\n </v-radio-group>\n <v-text-field\n v-model=\"ruleData['raise-lower-prices'].timeframe.value\"\n label=\"Days\"\n max=\"365\"\n min=\"0\"\n type=\"number\"\n variant=\"outlined\"\n ></v-text-field>\n </v-card-text>\n </v-card>\n </v-menu>\n </div>\n\n <div v-if=\"rule === 'fill-the-gap'\" class=\"mt-1\">\n\n <p class=\"mt-2\">Fill the gap helps you fill in the time between reservations that may incentivize renters to\n book odd or shorter times.</p>\n\n <div class=\"text-2xl border-top\">\n <v-menu open-on-hover>\n <template v-slot:activator=\"{ props }\">\n <v-btn\n style=\"padding-left: 0; padding-right:0;\"\n v-bind=\"props\"\n variant=\"text\"\n >\n <span class=\"i-in-place-edit\">\n {{ ruleData['fill-the-gap'].action }}\n </span>\n </v-btn>\n </template>\n\n <v-list>\n <v-list-item v-model=\"ruleData['fill-the-gap'].action\">\n <v-list-item value=\"increase\">\n <v-list-item-title>Increase</v-list-item-title>\n </v-list-item>\n <v-list-item value=\"decrease\">\n <v-list-item-title>Decrease</v-list-item-title>\n </v-list-item>\n </v-list-item>\n </v-list>\n </v-menu>\n listing prices by\n <v-menu :close-on-content-click=\"false\" open-on-hover>\n <template v-slot:activator=\"{ props }\">\n <v-btn\n style=\"padding-left: 0; padding-right:0;\"\n v-bind=\"props\"\n variant=\"text\"\n >\n <span class=\"i-in-place-edit\">\n <span v-if=\"ruleData['fill-the-gap'].mode ==='amount'\">$</span>\n {{ ruleData['fill-the-gap'].value }}\n <span v-if=\"ruleData['fill-the-gap'].mode ==='percent'\">%</span>\n </span>\n </v-btn>\n </template>\n\n <v-card>\n <v-card-text>\n <v-text-field\n v-model=\"ruleData['fill-the-gap'].value\"\n label=\"Amount\"\n max=\"365\"\n min=\"0\"\n type=\"number\"\n variant=\"outlined\"\n ></v-text-field>\n <v-radio-group v-model=\"ruleData['fill-the-gap'].mode\" inline>\n <v-radio label=\"Percent\" value=\"percent\"></v-radio>\n <v-radio label=\"Amount\" value=\"amount\"></v-radio>\n </v-radio-group>\n </v-card-text>\n </v-card>\n </v-menu>\n between reservations\n <v-menu :close-on-content-click=\"false\" open-on-hover>\n <template v-slot:activator=\"{ props }\">\n <v-btn\n style=\"padding-left: 0; padding-right:0;\"\n v-bind=\"props\"\n variant=\"text\"\n >\n <span class=\"i-in-place-edit\">\n {{ ruleData['fill-the-gap'].time_value }}\n <span>Days</span>\n </span>\n </v-btn>\n </template>\n\n <v-card>\n <v-card-text>\n <v-text-field\n v-model=\"ruleData['fill-the-gap'].time_value\"\n label=\"Amount\"\n max=\"365\"\n min=\"0\"\n type=\"number\"\n variant=\"outlined\"\n ></v-text-field>\n </v-card-text>\n </v-card>\n </v-menu>\n out.\n\n <v-expansion-panels class=\"mt-3\">\n <v-expansion-panel>\n <v-expansion-panel-title v-slot=\"{ open }\">\n <div>\n <div class=\"col-4\">Exclusions</div>\n <div class=\"col-8\">\n <v-fade-transition leave-absolute>\n <span v-if=\"open\">Add exclusion rules</span>\n <span v-else class=\"float-end\">{{ exclusionCount }} exclusion</span>\n </v-fade-transition>\n </div>\n </div>\n </v-expansion-panel-title>\n <v-expansion-panel-text>\n <v-checkbox\n v-model=\"ruleData['fill-the-gap'].exclusions.weekends.on\"\n density=\"compact\"\n hide-details\n label=\"Weekends\"\n ></v-checkbox>\n <v-checkbox\n v-model=\"ruleData['fill-the-gap'].exclusions.holidays.on\"\n density=\"compact\"\n hide-details\n label=\"Holidays\"\n ></v-checkbox>\n <div>\n <v-checkbox\n v-model=\"ruleData['fill-the-gap'].exclusions.listings.on\"\n density=\"compact\"\n hide-details\n label=\"These Listings\"\n ></v-checkbox>\n <div v-if=\"ruleData['fill-the-gap'].exclusions.listings.on\" class=\"mt-3 pl-10\">\n <v-autocomplete\n v-model=\"ruleData['fill-the-gap'].exclusions.listings.listings\"\n :items=\"filteredListings\"\n chips\n density=\"compact\"\n hide-details\n label=\"Excluded Listings\"\n multiple\n ></v-autocomplete>\n <ListingAutocompleteDropdown\n :allow-multiple=\"true\"\n :allow-select-all=\"true\"\n @selectedListing=\"listingSelected($event)\"\n ></ListingAutocompleteDropdown>\n </div>\n </div>\n </v-expansion-panel-text>\n </v-expansion-panel>\n </v-expansion-panels>\n </div>\n </div>\n </v-card-text>\n\n <v-divider/>\n\n <v-card-actions>\n <v-btn size=\"small\" variant=\"text\">Example</v-btn>\n <v-spacer/>\n <v-btn color=\"grey\" variant=\"text\" @click=\"dialog = false\">Cancel</v-btn>\n <v-btn color=\"primary\" variant=\"text\" @click=\"saveRuleInit()\">\n {{ $t('save') }}\n </v-btn>\n </v-card-actions>\n </v-card>\n </v-dialog>\n </div>\n</template>\n\n<script>\nimport { EventBus } from '@/plugins/eventBus';\nimport { mapActions, mapGetters } from 'vuex';\n\nconst ListingAutocompleteDropdown = () => import('@/components/dashboard/listings/ListingAutocompleteDropdown.vue');\n\nexport default {\n name: 'PricingRuleDialog',\n\n components: {\n ListingAutocompleteDropdown,\n },\n\n data() {\n return {\n snack: false,\n dialog: false,\n rule: 'fill-the-gap',\n rules: [\n {\n label: 'Raise/lower prices',\n value: 'raise-lower-prices',\n data: {\n action: 'raise',\n booking_cnt: 0,\n },\n },\n {\n label: 'Fill the Gap',\n value: 'fill-the-gap',\n },\n ],\n ruleData: {\n 'fill-the-gap': {\n action: 'decrease',\n value: 10,\n mode: 'percent',\n time_value: 14,\n exclusions: {\n weekends: {\n on: false,\n },\n holidays: {\n on: false,\n },\n specials: {\n on: false,\n },\n listings: {\n on: false,\n listings: [],\n },\n gap_max: {\n on: false,\n value: 1,\n },\n },\n excluded_listings: [],\n },\n 'raise-lower-prices': {\n action: 'raise',\n booking_cnt: 0,\n timeframe: {\n term: 'next',\n value: 0,\n unit: 'day',\n unit_label: () => (this.ruleData['raise-lower-prices'].timeframe.value === '1' ? this.ruleData['raise-lower-prices'].timeframe.unit : `${this.ruleData['raise-lower-prices'].timeframe.unit}s`),\n timeframe_label: () => (`${this.ruleData['raise-lower-prices'].timeframe.term} ${this.ruleData['raise-lower-prices'].timeframe.value} ${this.ruleData['raise-lower-prices'].timeframe.unit_label()}`),\n label: () => `${this.ruleData['raise-lower-prices'].timeframe.value} ${this.ruleData['raise-lower-prices'].timeframe.unit_label()}`,\n },\n },\n },\n };\n },\n\n created() {\n EventBus.$on('open-pricing-rule-dialog', () => {\n this.dialog = true;\n });\n\n this.fetchListings();\n },\n\n computed: {\n ...mapGetters({\n pricingRules: 'pricing/pricingRules',\n allListings: 'listing/allListings',\n }),\n exclusionCount() {\n if (!this.ruleClone) {\n return 0;\n }\n return Object.values(this.ruleClone.exclusions).filter((v) => v.on).length;\n },\n filteredListings() {\n return this.allListings;\n },\n },\n\n methods: {\n ...mapActions({\n fetchListings: 'listing/fetchListings',\n getPricingRules: 'pricing/getPricingRules',\n createPricingRule: 'pricing/createPricingRule',\n }),\n listingSelected(listings) {\n this.ruleData['fill-the-gap'].exclusions.listings.listings = listings.map((l) => l.l_id);\n },\n saveRuleInit() {\n this.createPricingRule({\n rule: this.rule,\n data: this.ruleData[this.rule],\n }).finally(() => {\n this.getPricingRules();\n this.dialog = false;\n });\n },\n },\n};\n</script>\n\n<style lang=\"scss\">\n.i-in-place-edit {\n font-weight: bold;\n cursor: text;\n border-top: 2px solid transparent;\n border-bottom: 2px solid transparent;\n}\n\n.i-in-place-edit:hover {\n text-decoration: none;\n border-bottom: 2px dotted var(--primary);\n}\n</style>\n","<template>\n <div>\n <v-card variant=\"outlined\">\n <v-card-title>\n Price Rules\n <TheHelpLink url=\"https://help.fleetwire.io/en/article/advanced-pricing-cxlndp/?bust=1666982473968\"></TheHelpLink>\n <v-spacer/>\n <v-btn size=\"small\" @click=\"EventBus.$emit('open-pricing-rule-dialog');\">\n <v-icon class=\"mr-1\" size=\"small\">mdi-plus</v-icon>\n Rule\n </v-btn>\n </v-card-title>\n <v-card-subtitle>\n Price rules are used to automatically calculate the price of certain days based on your rules.\n </v-card-subtitle>\n <v-card-text class=\"mt-3\">\n <v-data-table\n :headers=\"headers\"\n :items=\"pricingRules\"\n hide-default-footer\n >\n <template v-slot:item.id=\"{ index }\">\n {{ index + 1 }}\n </template>\n <template v-slot:item.active=\"{ item }\">\n <span v-if=\"item.active\">Active</span>\n </template>\n <template v-slot:item.name=\"{ item }\">\n <router-link :to=\"{name: 'settings.pricing.advanced.edit', params: {'uuid': item.uuid }}\">\n {{ item.name }}\n </router-link>\n </template>\n <template v-slot:item.uuid=\"{ item }\">\n <span v-tippy=\"item.uuid\" v-text=\"firstPartOfUuid(item.uuid)\"></span>\n </template>\n <template v-slot:item.rule_type=\"{ item }\">\n <span>{{ ruleType(item) }}</span>\n </template>\n <template v-slot:item.actions=\"{ item }\">\n <div class=\"flex gap-1 float-end\">\n <v-btn size=\"small\" variant=\"text\" @click=\"deletePricingRule(item)\">\n <v-icon size=\"small\">mdi-delete</v-icon>\n </v-btn>\n <v-btn size=\"small\" variant=\"text\" @click=\"$router.push({ name: 'settings.pricing.advanced.edit', params: {'uuid': item.uuid } }).catch(() => {})\">\n <v-icon size=\"small\">mdi-pencil</v-icon>\n </v-btn>\n </div>\n </template>\n </v-data-table>\n </v-card-text>\n </v-card>\n <PricingRuleDialog/>\n\n <v-alert class=\"mt-5\" density=\"compact\" type=\"info\" variant=\"outlined\">\n If you are seeing this page that means you have a beta tester flag.\n </v-alert>\n\n </div>\n</template>\n\n<script lang=\"ts\">\nimport {EventBus} from '@/plugins/eventBus';\nimport {mapActions, mapGetters} from 'vuex';\nimport {get} from 'lodash';\nimport PricingRuleDialog from './Dialogs/PricingRuleDialog.vue';\n\nexport default {\n name: 'AdvancedPricing',\n\n components: {\n PricingRuleDialog,\n },\n\n data() {\n return {\n headers: [\n {text: '#', value: 'id', width: 60},\n {text: 'Listing Name', value: 'name'},\n {text: 'Status', value: 'active'},\n {text: 'ID', value: 'uuid'},\n {text: 'Type', value: 'rule_type'},\n {text: '', value: 'actions'},\n ],\n EventBus,\n };\n },\n\n created() {\n this.getPricingRules();\n\n EventBus.$on('create-pricing-rules-success', () => {\n this.getPricingRules();\n });\n EventBus.$on('delete-pricing-rules-success', () => {\n this.getPricingRules();\n });\n },\n\n computed: {\n ...mapGetters({\n pricingRules: 'pricing/pricingRules',\n }),\n },\n\n methods: {\n ...mapActions({\n getPricingRules: 'pricing/getPricingRules',\n deletePricingRules: 'pricing/deletePricingRules',\n }),\n firstPartOfUuid(uuid) {\n return uuid.split('-')[0];\n },\n ruleType(rule) {\n const type = get(rule, 'rule_type', 'N/A');\n switch (type) {\n case 'fill-the-gap':\n return 'Fill the gap';\n case 'raise-lower-prices':\n return 'Raise/Lower prices';\n default:\n return 'Unknown';\n }\n },\n deletePricingRule(rule) {\n this.deletePricingRules([rule.uuid])\n .finally(() => {\n this.getPricingRules();\n });\n },\n },\n\n beforeUnmount() {\n EventBus.$off('create-pricing-rules-success');\n EventBus.$off('delete-pricing-rules-success');\n },\n};\n</script>\n","<template>\n <div>\n <v-card>\n <v-card-title>\n <div class=\"flex items-center\">\n Price Structure\n <TheHelpLink url=\"https://help.fleetwire.io/en/article/advanced-pricing-cxlndp/?bust=1666982473968\"></TheHelpLink>\n <v-spacer/>\n <v-btn size=\"small\" @click=\"$router.push({ name: 'settings.pricing.template.new'}).catch(() => {})\">\n <v-icon class=\"mr-1\" size=\"small\">mdi-plus</v-icon>\n Structure\n </v-btn>\n </div>\n </v-card-title>\n <v-card-subtitle>\n Create template pricing structures for multiple products following the same pricing structure.\n </v-card-subtitle>\n <v-card-text class=\"mt-3\">\n <v-table v-if=\"pricingStructures.length > 0\">\n <template v-slot:default>\n <thead>\n <tr>\n <th>Name</th>\n <th></th>\n </tr>\n </thead>\n <tbody>\n <tr v-for=\"(structure, index) in pricingStructures\" :key=\"index\">\n <td>\n <v-btn color=\"blue\" variant=\"plain\" @click=\"$router.push({ name: 'settings.pricing.template.edit', params: { uuid: structure.uuid } }).catch(() => {})\">\n {{ structure.name }}\n </v-btn>\n </td>\n <td class=\"text-right\">\n <v-btn size=\"small\" variant=\"outlined\" @click=\"$router.push({ name: 'settings.pricing.template.edit', params: { uuid: structure.uuid } }).catch(() => {})\">\n <v-icon class=\"mr-2\" size=\"small\">mdi-calculator</v-icon>\n Preview\n </v-btn>\n </td>\n </tr>\n </tbody>\n </template>\n </v-table>\n <div v-else>\n No Pricing Structures\n </div>\n </v-card-text>\n </v-card>\n </div>\n</template>\n\n<script>\nimport { EventBus } from '@/plugins/eventBus';\nimport { mapActions, mapGetters } from 'vuex';\n\n\nexport default {\n name: 'PricingTemplate',\n\n\n data() {\n return {\n headers: [\n { text: '#', value: 'id', width: 60 },\n { text: 'Listing Name', value: 'name' },\n { text: 'Status', value: 'active' },\n { text: 'ID', value: 'uuid' },\n { text: 'Type', value: 'rule_type' },\n { text: '', value: 'actions' },\n ],\n EventBus,\n };\n },\n\n created() {\n this.getPricingStructures();\n\n EventBus.$on('create-pricing-rules-success', () => {\n this.getPricingRules();\n });\n EventBus.$on('delete-pricing-rules-success', () => {\n this.getPricingRules();\n });\n },\n\n computed: {\n ...mapGetters({\n pricingStructures: 'pricing/pricingStructures',\n }),\n },\n\n methods: {\n ...mapActions({\n getPricingStructures: 'pricing/getPricingStructures',\n }),\n },\n\n beforeUnmount() {\n EventBus.$off('create-pricing-rules-success');\n EventBus.$off('delete-pricing-rules-success');\n },\n};\n</script>\n","<template>\n <div>\n <div class=\"\">\n <div class=\"\">\n <div class=\"setting-section-description\">\n <h2>New template structure</h2>\n <div class=\"feature-description\">\n Create price tiers to set prices for different rental periods. You could use it to make the price lower when\n customers rent for a longer period of time.\n\n <TheHelpLink url=\"https://help.fleetwire.io/en/article/setting-up-taxes-ey9pyo/?bust=1675453082095\"></TheHelpLink>\n </div>\n </div>\n </div>\n <div class=\"\">\n <v-card variant=\"outlined\">\n <v-card-text class=\"mt-3\">\n <div>\n <div>\n <label class=\"font-bold\">Template Name</label>\n <v-text-field\n ref=\"template_name\"\n v-model=\"currentPricingStructure.name\"\n density=\"compact\"\n hide-details\n name=\"template_name\"\n variant=\"outlined\"\n ></v-text-field>\n <div class=\"mt-2\">This is not visible to customers.</div>\n </div>\n </div>\n </v-card-text>\n </v-card>\n\n <v-card class=\"mt-5\" variant=\"outlined\">\n <v-card-text>\n <div class=\"mt-10\">\n <h5 class=\"h5\">Price tiers</h5>\n\n <div class=\"font-bold\">\n Example price\n </div>\n <p>The example price is replaced by the base price of the listing that use this template.</p>\n\n <v-text-field\n v-model=\"currentPricingStructure.price_example\"\n :prefix=\"companyMoneyTextInputSettings.prefix\"\n :suffix=\"companyMoneyTextInputSettings.suffix\"\n class=\"pricing-structure-example-price\"\n density=\"compact\"\n type=\"number\"\n variant=\"outlined\"\n @blur=\"updateResultingPriceParent()\"\n ></v-text-field>\n\n <div>\n <div>\n <div v-for=\"(tier,i) in currentPricingStructure.price_tiers\" :key=\"i\" class=\"Row-eCkaBm evTrKC\">\n <div class=\"Div-bMiTSW Col-iaLJLx InputField-iwpqyF xfmMQ\" data-tid=\"Row 1: Label\">\n <div v-if=\"i === 0\" class=\"LabelContainer-fLmGyQ kXPMMB\">\n <label class=\"Label-eJXSuD Label-iekCsg gZKasB eYnYJY\" for=\"clidjimoz00273b7saj4fna9w\">\n Price tier label\n </label>\n </div>\n <span class=\"InputContainer-hJWSEI bsHxqg\">\n <input\n v-model=\"tier.name\"\n :name=\"`price_tiles_attributes[${i}].name`\"\n autocomplete=\"off\"\n class=\"Input-bXxEzP Input-icnXNI cCETsh blXyKC\"\n type=\"text\"\n ></span>\n </div>\n <div class=\"Div-bMiTSW Col-iaLJLx InputField-iwpqyF xfmMQ\" data-tid=\"Row 1: Duration\">\n <div v-if=\"i === 0\" class=\"LabelContainer-fLmGyQ kXPMMB\">\n <label class=\"Label-eJXSuD Label-iekCsg gZKasB eYnYJY\" for=\"clidjimp000283b7surusxx4f\">Duration</label>\n </div>\n <span class=\"InputContainer-hJWSEI bsHxqg\">\n <input\n v-model=\"tier.quantity\"\n :name=\"`price_tiles_attributes[${i}].quantity`\"\n autocomplete=\"off\"\n class=\"Input-bXxEzP Input-icnXNI cCETsh blXyKC\"\n min=\"1\"\n type=\"number\"\n ></span>\n </div>\n <div class=\"Div-bMiTSW Col-iaLJLx InputField-iwpqyF xfmMQ\" data-tid=\"Row 1: Period\">\n <div v-if=\"i === 0\" class=\"LabelContainer-fLmGyQ kXPMMB\"></div>\n <div class=\"Container-boBWlZ erHrFZ\">\n <v-select\n v-model=\"tier.period\"\n :items=\"durationUnits\"\n class=\"\"\n density=\"compact\"\n hide-details\n item-title=\"text\"\n item-value=\"value\"\n style=\"\"\n variant=\"outlined\"\n ></v-select>\n </div>\n </div>\n\n <div class=\"Div-bMiTSW Col-iaLJLx InputField-iwpqyF xfmMQ\" data-tid=\"Row 1: Multiplier\">\n <div v-if=\"i === 0\" class=\"LabelContainer-fLmGyQ kXPMMB\">\n <label class=\"Label-eJXSuD Label-iekCsg gZKasB eYnYJY\" for=\"clidjimp8002a3b7sz3j23aa9\">\n Multiply base price by\n </label>\n </div>\n <span class=\"InputContainer-hJWSEI bsHxqg\">\n <input\n v-model=\"tier.multiplier\"\n :name=\"`price_tiles_attributes[${i}].multiplier`\"\n autocomplete=\"off\"\n class=\"cCETsh\"\n type=\"text\"\n @blur=\"updateResultingPrice(i)\"\n ></span>\n </div>\n <div class=\"ONqJD\">* base price =</div>\n <div class=\"\" data-tid=\"Row 1: Example price\">\n <div v-if=\"i === 0\" class=\"LabelContainer-fLmGyQ kXPMMB\">\n <label class=\"Label-eJXSuD Label-iekCsg gZKasB eYnYJY\" for=\"clidjimp9002b3b7sb1ldvxal\">\n Resulting price\n </label>\n </div>\n <span class=\"InputContainer-hJWSEI bsHxqg\">\n <i class=\"I-gmFDEA eaYeOY\">$</i>\n <input\n v-model=\"tier.example_price\"\n :name=\"`price_tiles_attributes[${i}].example_price`\"\n autocomplete=\"off\"\n class=\"Input-bXxEzP Input-icnXNI cCETsh blXyKC\"\n label=\"Resulting price\"\n type=\"number\"\n @blur=\"updateMultiplier(i)\"\n >\n </span>\n </div>\n <v-btn class=\"fJfBtJ mt-4\" size=\"small\" variant=\"text\" @click=\"removePricingTier(i)\">\n <v-icon size=\"small\">mdi-delete</v-icon>\n </v-btn>\n </div>\n </div>\n\n <div class=\"mt-5\">\n <v-btn variant=\"outlined\" @click=\"addPricingTier()\">Add Price Tier</v-btn>\n </div>\n </div>\n </div>\n </v-card-text>\n </v-card>\n\n <v-card class=\"mt-5\" variant=\"outlined\">\n <v-card-title>Automatic increments</v-card-title>\n <v-card-subtitle>\n Set an amount that is added for each period following the price tier with the longest period.\n </v-card-subtitle>\n <v-card-text>\n <div>\n <div class=\"Row-eCkaBm esebmt\" data-tid=\"Each extra block\">\n <div class=\"EachExtra-hFYHww ipTNEC\">\n <div class=\"Div-bMiTSW Col-iaLJLx InputField-iwpqyF xfmMQ\" data-tid=\"Each extra\">\n <div class=\"LabelContainer-fLmGyQ kXPMMB\">\n <label class=\"Label-eJXSuD Label-iekCsg gZKasB eYnYJY\" for=\"clidly6i3002c3b7s5y2eovx6\">\n Each extra\n </label>\n </div>\n <div class=\"Container-boBWlZ erHrFZ\" data-tid=\"Each extra\">\n <div class=\"Container-boBWlZ erHrFZ\">\n <v-select\n v-model=\"currentPricingStructure.duration_unit\"\n :items=\"durationUnits\"\n class=\"\"\n density=\"compact\"\n hide-details\n item-title=\"text\"\n item-value=\"value\"\n style=\"\"\n variant=\"outlined\"\n ></v-select>\n </div>\n </div>\n </div>\n </div>\n <div class=\"Div-bMiTSW Col-iaLJLx InputField-iwpqyF xfmMQ\" data-tid=\"Each extra multiplier\">\n <div class=\"LabelContainer-fLmGyQ kXPMMB\">\n <label class=\"Label-eJXSuD Label-iekCsg gZKasB eYnYJY\" for=\"clidly6i6002d3b7s2wg4cao0\">\n Multiply base price by\n </label>\n </div>\n <span class=\"InputContainer-hJWSEI bsHxqg\">\n <input\n v-model=\"currentPricingStructure.multiplier\"\n autocomplete=\"off\"\n class=\"Input-bXxEzP Input-icnXNI cCETsh blXyKC\"\n name=\"hour\"\n type=\"text\"\n @blur.stop=\"updateAddedAmount()\"\n ></span>\n </div>\n <div class=\"PriceText-iYCcgJ ONqJD\">* base price =</div>\n <div class=\"Div-bMiTSW Col-iaLJLx InputField-iwpqyF xfmMQ\" data-tid=\"Each extra price\">\n <div class=\"LabelContainer-fLmGyQ kXPMMB\">\n <label class=\"Label-eJXSuD Label-iekCsg gZKasB eYnYJY\" for=\"clidly6i6002e3b7srupwc20u\">\n Added amount\n </label>\n </div>\n <span class=\"InputContainer-hJWSEI bsHxqg\">\n <i class=\"I-gmFDEA eaYeOY\">$</i>\n <input\n v-model=\"currentPricingStructure.added_amount\"\n autocomplete=\"off\"\n class=\"Input-bXxEzP Input-icnXNI cCETsh blXyKC\"\n name=\"example_price\"\n @blur.stop=\"updateAddedAmountMultiple()\"\n >\n </span>\n </div>\n </div>\n </div>\n </v-card-text>\n </v-card>\n\n <div class=\"flex mt-5\">\n <v-spacer/>\n <v-btn variant=\"text\" @click=\"goBack\">Cancel</v-btn>\n <v-btn :disabled=\"saveButtonReady\" class=\"ml-2\" color=\"primary\" variant=\"flat\" @click=\"savePriceStructureInit()\">\n Save\n </v-btn>\n </div>\n </div>\n </div>\n </div>\n</template>\n\n<script lang=\"ts\">\nimport {mapActions, mapGetters} from 'vuex';\nimport {get} from 'lodash';\nimport {EventBus} from '@/plugins/eventBus';\nimport {useMoneyFormatter} from '@/composables/useMoneyFormatter';\nimport {useRouter} from 'vue-router';\n\nexport default {\n name: 'PricingTemplateNew',\n\n setup() {\n const router = useRouter();\n const {companyMoneyTextInputSettings} = useMoneyFormatter();\n\n const goBack = () => {\n router.go(-1);\n };\n\n return {\n goBack,\n companyMoneyTextInputSettings,\n };\n },\n\n\n data() {\n return {\n durationUnits: [\n {\n text: 'Hours',\n value: 'hours',\n },\n {\n text: 'Days',\n value: 'days',\n },\n {\n text: 'Weeks',\n value: 'weeks',\n },\n {\n text: 'Months',\n value: 'months',\n },\n {\n text: 'Years',\n value: 'years',\n },\n ],\n currentPricingStructure: {\n uuid: null,\n name: '',\n price_example: 100,\n added_amount: 100,\n duration_unit: 'days',\n multiplier: 1,\n price_tiers: [\n {\n name: '1 day',\n quantity: 1,\n period: 'days',\n multiplier: 1,\n example_price: 100,\n },\n ],\n },\n };\n },\n\n created() {\n this.getPricingStructures();\n\n EventBus.$on('create-pricing-structure-success', () => {\n this.$router.push({name: 'settings.pricing.template'}).catch(() => {\n });\n });\n },\n\n mounted() {\n this.$nextTick(() => {\n this.$refs.template_name.focus();\n });\n },\n\n computed: {\n ...mapGetters({\n appFeatures: 'app/appFeatures',\n featureWaitlist: 'app/featureWaitlist',\n pricingStructures: 'pricing/pricingStructures',\n pricingStructure: 'pricing/pricingStructure',\n currentWorkingPricingStructure: 'pricing/currentWorkingPricingStructure',\n }),\n automaticAmount: {\n get() {\n return this.currentPricingStructure.example_price;\n },\n set(value) {\n this.currentPricingStructure.example_price = value;\n },\n },\n saveButtonReady() {\n return !this.currentPricingStructure.name || !this.currentPricingStructure.price_example;\n },\n },\n\n methods: {\n savePriceStructureInit() {\n this.savePriceStructure(this.currentPricingStructure);\n },\n ...mapActions({\n getPricingStructure: 'pricing/getPricingStructure',\n updatePriceStructure: 'pricing/updatePriceStructure',\n deletePriceStructure: 'pricing/deletePriceStructure',\n getPricingStructures: 'pricing/getPricingStructures',\n savePriceStructure: 'pricing/savePriceStructure',\n }),\n removePricingTier(index) {\n this.currentPricingStructure.price_tiers.splice(index, 1);\n },\n updateAddedAmount() {\n this.currentPricingStructure.added_amount = this.currentPricingStructure.price_example * this.currentPricingStructure.multiplier;\n },\n updateAddedAmountMultiple() {\n this.currentPricingStructure.multiplier = this.currentPricingStructure.added_amount / this.currentPricingStructure.price_example;\n },\n addPricingTier() {\n const lastUnit = this.currentPricingStructure.price_tiers[this.currentPricingStructure.price_tiers.length - 1];\n const durationUnit = get(lastUnit, 'period', 'days');\n const quantity = get(lastUnit, 'quantity', 0) + 1;\n\n this.currentPricingStructure.price_tiers.push({\n name: `${quantity} ${durationUnit}`,\n quantity,\n period: durationUnit,\n multiplier: 1,\n example_price: 100,\n });\n },\n updateResultingPriceParent() {\n this.currentPricingStructure.added_amount = this.currentPricingStructure.price_example * this.currentPricingStructure.multiplier;\n this.currentPricingStructure.price_tiers.forEach((tier) => {\n const multiplier = +get(tier, 'multiplier', 1);\n const examplePrice = this.currentPricingStructure.price_example;\n let newPrice = multiplier * examplePrice;\n newPrice = Math.round(newPrice * 100) / 100;\n this.$set(tier, 'example_price', newPrice);\n });\n },\n updateResultingPrice(index) {\n const tier = this.currentPricingStructure.price_tiers[index];\n const multiplier = +get(tier, 'multiplier', 1);\n const examplePrice = this.currentPricingStructure.price_example;\n this.$set(tier, 'example_price', multiplier * examplePrice);\n },\n updateMultiplier(index) {\n const tier = this.currentPricingStructure.price_tiers[index];\n const examplePrice = this.currentPricingStructure.price_example;\n const resultingPrice = +get(tier, 'example_price', 0);\n\n this.$set(tier, 'multiplier', resultingPrice / examplePrice);\n },\n updatePriceStructureInit() {\n this.updatePriceStructure(this.currentPricingStructure);\n },\n deletePriceStructureInit() {\n this.deletePriceStructure(this.currentPricingStructure);\n },\n setupEditStructure() {\n this.currentPricingStructure.uuid = this.pricingStructure.uuid;\n this.currentPricingStructure.name = this.pricingStructure.name;\n this.currentPricingStructure.price_example = 100;\n this.currentPricingStructure.multiplier = this.pricingStructure.multiplier;\n\n let durationUnit = ['hour', 'day', 'month', 'week', 'year'].find(key => this.pricingStructure[key] > 0);\n if (durationUnit) {\n this.currentPricingStructure.multiplier = this.pricingStructure[durationUnit];\n\n if (durationUnit[durationUnit.length - 1] !== 's') {\n durationUnit += 's';\n }\n this.currentPricingStructure.duration_unit = durationUnit;\n }\n\n const tiers = this.pricingStructure?.pricing_tiles ?? [];\n\n if (tiers) {\n this.currentPricingStructure.price_tiers = [];\n tiers.forEach((tier) => {\n this.currentPricingStructure.price_tiers.push({\n name: tier.name,\n quantity: tier.quantity,\n period: tier.period,\n multiplier: tier.multiplier,\n example_price: tier.multiplier * this.currentPricingStructure.price_example,\n });\n });\n }\n },\n },\n\n beforeUnmount() {\n EventBus.$off('create-pricing-structure-success');\n },\n};\n</script>\n<style>\n.evTrKC {\n display: grid;\n grid-template-columns: auto 50px 120px 50px 100px auto 50px;\n column-gap: 6px;\n align-items: flex-end;\n margin-bottom: 12px;\n}\n\n.evTrKC > * {\n margin: 0;\n}\n\n.ONqJD {\n align-self: center;\n color: rgb(118, 127, 130);\n padding-top: 24px;\n}\n\n.fJfBtJ {\n cursor: pointer;\n align-self: center;\n font-size: 14px;\n display: inline-block;\n color: rgb(24, 24, 24);\n}\n\n.jEVlcv {\n padding-top: 19px;\n}\n\n.kXPMMB {\n display: flex;\n -webkit-box-align: center;\n align-items: center;\n -webkit-box-pack: justify;\n justify-content: space-between;\n}\n\n.evTrKC .Label-eJXSuD {\n white-space: nowrap;\n}\n\n.gZKasB {\n display: block;\n color: rgb(24, 24, 24);\n font-size: 14px;\n font-weight: 600;\n line-height: 14px;\n margin-bottom: 5px;\n}\n\n.eYnYJY {\n height: 1.3em;\n width: auto;\n margin-bottom: 6px;\n}\n\n.bsHxqg.bsHxqg.bsHxqg {\n display: block;\n position: relative;\n font-size: 12px;\n}\n\n.cCETsh.cCETsh {\n display: inline-block;\n vertical-align: middle;\n width: 100%;\n height: 38px;\n padding: 0px 12px;\n margin: 0px;\n color: rgb(24, 24, 24);\n background: rgb(255, 255, 255);\n border: 1px solid rgb(226, 230, 235);\n border-radius: 6px;\n outline: 0px;\n font-size: 12px;\n font-weight: 400;\n line-height: 1;\n box-sizing: border-box;\n}\n\n.erHrFZ {\n position: relative;\n}\n\n.css-2b097c-container {\n position: relative;\n box-sizing: border-box;\n}\n\n.kvYiAT .Select__control {\n padding: 0px 0px 0px 12px;\n color: rgb(24, 24, 24);\n background: rgb(255, 255, 255);\n border: 1px solid rgb(226, 230, 235);\n border-radius: 6px;\n font-size: 12px;\n cursor: pointer;\n height: 38px !important;\n overflow: visible !important;\n}\n\n.css-yk16xz-control {\n -webkit-box-align: center;\n align-items: center;\n background-color: rgb(255, 255, 255);\n border-color: rgb(204, 204, 204);\n border-radius: 4px;\n border-style: solid;\n border-width: 1px;\n cursor: default;\n display: flex;\n flex-wrap: wrap;\n -webkit-box-pack: justify;\n justify-content: space-between;\n min-height: 38px;\n position: relative;\n transition: all 100ms ease 0s;\n box-sizing: border-box;\n outline: 0px !important;\n}\n\n.css-1hwfws3 {\n -webkit-box-align: center;\n align-items: center;\n display: flex;\n flex: 1 1 0%;\n flex-wrap: wrap;\n padding: 2px 8px;\n position: relative;\n overflow: hidden;\n box-sizing: border-box;\n}\n\n.kvYiAT .Select__value-container {\n padding: 0px;\n height: 38px !important;\n}\n\n.css-1wy0on6 {\n -webkit-box-align: center;\n align-items: center;\n align-self: stretch;\n display: flex;\n flex-shrink: 0;\n box-sizing: border-box;\n}\n\n.css-1okebmr-indicatorSeparator {\n align-self: stretch;\n background-color: rgb(204, 204, 204);\n margin-bottom: 8px;\n margin-top: 8px;\n width: 1px;\n box-sizing: border-box;\n}\n\n.kvYiAT .Select__indicator-separator {\n display: none;\n}\n\n.css-tlfecz-indicatorContainer {\n color: rgb(204, 204, 204);\n display: flex;\n padding: 8px;\n transition: color 150ms ease 0s;\n box-sizing: border-box;\n}\n\n.css-19bqh2r {\n display: inline-block;\n fill: currentcolor;\n line-height: 1;\n stroke: currentcolor;\n stroke-width: 0;\n}\n\n.css-1uccc91-singleValue {\n color: rgb(51, 51, 51);\n margin-left: 2px;\n margin-right: 2px;\n max-width: calc(100% - 8px);\n overflow: hidden;\n position: absolute;\n text-overflow: ellipsis;\n white-space: nowrap;\n top: 50%;\n transform: translateY(-50%);\n box-sizing: border-box;\n}\n\n.kvYiAT .Select__single-value {\n overflow: visible;\n color: rgb(24, 24, 24);\n}\n\n.css-1ogwcvc {\n margin: 0px;\n padding: 0px;\n height: 38px !important;\n}\n\n.ONqJD {\n align-self: center;\n color: rgb(118, 127, 130);\n padding-top: 24px;\n}\n\n.bsHxqg.bsHxqg.bsHxqg {\n display: block;\n position: relative;\n font-size: 12px;\n}\n\n.evTrKC .Label-eJXSuD {\n white-space: nowrap;\n}\n\n.bsHxqg.bsHxqg.bsHxqg > .I-gmFDEA {\n position: absolute;\n height: 38px;\n width: 38px;\n color: rgb(187, 192, 193);\n font-size: 1.25em;\n font-style: normal;\n line-height: 38px;\n text-align: center;\n pointer-events: none;\n}\n\n.bsHxqg.bsHxqg.bsHxqg > .I-gmFDEA + .Input-icnXNI {\n padding-left: 38px;\n}\n\n.xfmMQ .v-select.v-input--dense .v-select__selection--comma {\n margin: 0;\n font-size: 12px;\n font-weight: 400;\n}\n\n.xfmMQ fieldset {\n color: rgb(226, 230, 235) !important;\n border: 1px solid rgb(226, 230, 235);\n}\n\n.xfmMQ input[type=text]:hover:not(:focus) {\n border-color: #CDCDCD;\n -webkit-box-shadow: inset 0 -1px 0 0 rgba(255, 255, 255, 0.8);\n -moz-box-shadow: inset 0 -1px 0 0 rgba(255, 255, 255, 0.8);\n box-shadow: inset 0 -1px 0 0 rgba(255, 255, 255, 0.8);\n}\n\n.cCETsh.cCETsh:hover {\n border-color: rgb(191, 197, 203);\n}\n\n.pricing-structure-example-price fieldset {\n color: rgb(226, 230, 235) !important;\n border: 1px solid rgb(226, 230, 235);\n}\n\n.pricing-structure-example-price:hover {\n border-color: rgb(191, 197, 203) !important;\n}\n\n.esebmt {\n display: grid;\n column-gap: 6px;\n align-items: flex-end;\n grid-template-columns: auto 65px 90px 100px;\n margin-bottom: 0px;\n margin-top: 12px;\n}\n\n.esebmt .Label-eJXSuD {\n white-space: nowrap;\n}\n\n/* Chrome, Safari, Edge, Opera */\ninput::-webkit-outer-spin-button,\ninput::-webkit-inner-spin-button {\n -webkit-appearance: none;\n margin: 0;\n}\n\n/* Firefox */\ninput[type=number] {\n -moz-appearance: textfield;\n}\n</style>\n","<template>\n <div>\n <div class=\"\">\n <div class=\"\">\n <div class=\"setting-section-description\">\n <h2>New template structure</h2>\n <div class=\"feature-description\">\n Create price tiers to set prices for different rental periods. You could use it to make the price lower when\n customers rent for a longer period of time.\n\n <TheHelpLink url=\"https://help.fleetwire.io/en/article/setting-up-taxes-ey9pyo/?bust=1675453082095\"></TheHelpLink>\n </div>\n </div>\n </div>\n <div class=\"\">\n <v-card variant=\"outlined\">\n <v-card-text class=\"mt-3\">\n <div>\n <div>\n <label class=\"font-bold\">Template Name</label>\n <v-text-field\n ref=\"template_name\"\n v-model=\"currentPricingStructure.name\"\n density=\"compact\"\n hide-details\n name=\"template_name\"\n variant=\"outlined\"\n ></v-text-field>\n <div class=\"mt-2\">This is not visible to customers.</div>\n </div>\n </div>\n </v-card-text>\n </v-card>\n\n <v-card class=\"mt-5\" variant=\"outlined\">\n <v-card-text>\n <div class=\"mt-10\">\n <h5 class=\"h5\">Price tiers</h5>\n\n <div class=\"font-bold\">\n Example price\n </div>\n <p>The example price is replaced by the base price of the listing that use this template.</p>\n\n <v-text-field\n v-model=\"currentPricingStructure.price_example\"\n :prefix=\"companyMoneyTextInputSettings.prefix\"\n :suffix=\"companyMoneyTextInputSettings.suffix\"\n class=\"pricing-structure-example-price\"\n density=\"compact\"\n type=\"number\"\n variant=\"outlined\"\n @blur=\"updateResultingPriceParent()\"\n ></v-text-field>\n\n <div>\n <div>\n <div v-for=\"(tier,i) in currentPricingStructure.price_tiers\" :key=\"i\" class=\"Row-eCkaBm evTrKC\">\n <div class=\"Div-bMiTSW Col-iaLJLx InputField-iwpqyF xfmMQ\" data-tid=\"Row 1: Label\">\n <div v-if=\"i === 0\" class=\"LabelContainer-fLmGyQ kXPMMB\">\n <label class=\"Label-eJXSuD Label-iekCsg gZKasB eYnYJY\" for=\"clidjimoz00273b7saj4fna9w\">\n Price tier label\n </label>\n </div>\n <span class=\"InputContainer-hJWSEI bsHxqg\">\n <input\n v-model=\"tier.name\"\n :name=\"`price_tiles_attributes[${i}].name`\"\n autocomplete=\"off\"\n class=\"Input-bXxEzP Input-icnXNI cCETsh blXyKC\"\n type=\"text\"\n ></span>\n </div>\n <div class=\"Div-bMiTSW Col-iaLJLx InputField-iwpqyF xfmMQ\" data-tid=\"Row 1: Duration\">\n <div v-if=\"i === 0\" class=\"LabelContainer-fLmGyQ kXPMMB\">\n <label class=\"Label-eJXSuD Label-iekCsg gZKasB eYnYJY\" for=\"clidjimp000283b7surusxx4f\">Duration</label>\n </div>\n <span class=\"InputContainer-hJWSEI bsHxqg\">\n <input\n v-model=\"tier.quantity\"\n :name=\"`price_tiles_attributes[${i}].quantity`\"\n autocomplete=\"off\"\n class=\"Input-bXxEzP Input-icnXNI cCETsh blXyKC\"\n min=\"1\"\n type=\"number\"\n ></span>\n </div>\n <div class=\"Div-bMiTSW Col-iaLJLx InputField-iwpqyF xfmMQ\" data-tid=\"Row 1: Period\">\n <div v-if=\"i === 0\" class=\"LabelContainer-fLmGyQ kXPMMB\"></div>\n <div class=\"Container-boBWlZ erHrFZ\">\n <v-select\n v-model=\"tier.period\"\n :items=\"durationUnits\"\n class=\"\"\n density=\"compact\"\n hide-details\n item-title=\"text\"\n item-value=\"value\"\n style=\"\"\n variant=\"outlined\"\n ></v-select>\n </div>\n </div>\n\n <div class=\"Div-bMiTSW Col-iaLJLx InputField-iwpqyF xfmMQ\" data-tid=\"Row 1: Multiplier\">\n <div v-if=\"i === 0\" class=\"LabelContainer-fLmGyQ kXPMMB\">\n <label class=\"Label-eJXSuD Label-iekCsg gZKasB eYnYJY\" for=\"clidjimp8002a3b7sz3j23aa9\">\n Multiply base price by\n </label>\n </div>\n <span class=\"InputContainer-hJWSEI bsHxqg\">\n <input\n v-model=\"tier.multiplier\"\n :name=\"`price_tiles_attributes[${i}].multiplier`\"\n autocomplete=\"off\"\n class=\"cCETsh\"\n type=\"text\"\n @blur=\"updateResultingPrice(i)\"\n ></span>\n </div>\n <div class=\"ONqJD\">* base price =</div>\n <div class=\"\" data-tid=\"Row 1: Example price\">\n <div v-if=\"i === 0\" class=\"LabelContainer-fLmGyQ kXPMMB\">\n <label class=\"Label-eJXSuD Label-iekCsg gZKasB eYnYJY\" for=\"clidjimp9002b3b7sb1ldvxal\">\n Resulting price\n </label>\n </div>\n <span class=\"InputContainer-hJWSEI bsHxqg\">\n <i class=\"I-gmFDEA eaYeOY\">$</i>\n <input\n v-model=\"tier.example_price\"\n :name=\"`price_tiles_attributes[${i}].example_price`\"\n autocomplete=\"off\"\n class=\"Input-bXxEzP Input-icnXNI cCETsh blXyKC\"\n label=\"Resulting price\"\n type=\"number\"\n @blur=\"updateMultiplier(i)\"\n >\n </span>\n </div>\n <v-btn class=\"fJfBtJ mt-4\" size=\"small\" variant=\"text\" @click=\"removePricingTier(i)\">\n <v-icon size=\"small\">mdi-delete</v-icon>\n </v-btn>\n </div>\n </div>\n\n <div class=\"mt-5\">\n <v-btn variant=\"outlined\" @click=\"addPricingTier()\">Add Price Tier</v-btn>\n </div>\n </div>\n </div>\n </v-card-text>\n </v-card>\n\n <v-card class=\"mt-5\" variant=\"outlined\">\n <v-card-title>Automatic increments</v-card-title>\n <v-card-subtitle>\n Set an amount that is added for each period following the price tier with the longest period.\n </v-card-subtitle>\n <v-card-text>\n <div>\n <div class=\"Row-eCkaBm esebmt\" data-tid=\"Each extra block\">\n <div class=\"EachExtra-hFYHww ipTNEC\">\n <div class=\"Div-bMiTSW Col-iaLJLx InputField-iwpqyF xfmMQ\" data-tid=\"Each extra\">\n <div class=\"LabelContainer-fLmGyQ kXPMMB\">\n <label class=\"Label-eJXSuD Label-iekCsg gZKasB eYnYJY\" for=\"clidly6i3002c3b7s5y2eovx6\">\n Each extra\n </label>\n </div>\n <div class=\"Container-boBWlZ erHrFZ\" data-tid=\"Each extra\">\n <div class=\"Container-boBWlZ erHrFZ\">\n <v-select\n v-model=\"currentPricingStructure.duration_unit\"\n :items=\"durationUnits\"\n class=\"\"\n density=\"compact\"\n hide-details\n item-title=\"text\"\n item-value=\"value\"\n style=\"\"\n variant=\"outlined\"\n ></v-select>\n </div>\n </div>\n </div>\n </div>\n <div class=\"Div-bMiTSW Col-iaLJLx InputField-iwpqyF xfmMQ\" data-tid=\"Each extra multiplier\">\n <div class=\"LabelContainer-fLmGyQ kXPMMB\">\n <label class=\"Label-eJXSuD Label-iekCsg gZKasB eYnYJY\" for=\"clidly6i6002d3b7s2wg4cao0\">\n Multiply base price by\n </label>\n </div>\n <span class=\"InputContainer-hJWSEI bsHxqg\">\n <input\n v-model=\"currentPricingStructure.multiplier\"\n autocomplete=\"off\"\n class=\"Input-bXxEzP Input-icnXNI cCETsh blXyKC\"\n name=\"hour\"\n type=\"text\"\n @blur.stop=\"updateAddedAmount()\"\n ></span>\n </div>\n <div class=\"PriceText-iYCcgJ ONqJD\">* base price =</div>\n <div class=\"Div-bMiTSW Col-iaLJLx InputField-iwpqyF xfmMQ\" data-tid=\"Each extra price\">\n <div class=\"LabelContainer-fLmGyQ kXPMMB\">\n <label class=\"Label-eJXSuD Label-iekCsg gZKasB eYnYJY\" for=\"clidly6i6002e3b7srupwc20u\">\n Added amount\n </label>\n </div>\n <span class=\"InputContainer-hJWSEI bsHxqg\">\n <i class=\"I-gmFDEA eaYeOY\">$</i>\n <input\n v-model=\"currentPricingStructure.added_amount\"\n autocomplete=\"off\"\n class=\"Input-bXxEzP Input-icnXNI cCETsh blXyKC\"\n name=\"example_price\"\n @blur.stop=\"updateAddedAmountMultiple()\"\n >\n </span>\n </div>\n </div>\n </div>\n </v-card-text>\n </v-card>\n\n <div class=\"flex mt-5\">\n <DeleteButton\n button-main-color=\"red\"\n @deleteConfirmed=\"deletePriceStructureInit()\"\n />\n <v-spacer/>\n <v-btn variant=\"text\" @click=\"goBack\">Cancel</v-btn>\n <v-btn :disabled=\"saveButtonReady\" class=\"ml-2\" color=\"primary\" variant=\"flat\" @click=\"updatePriceStructureInit()\">\n Save\n </v-btn>\n </div>\n </div>\n </div>\n </div>\n</template>\n\n<script lang=\"ts\">\nimport {defineAsyncComponent} from 'vue';\nimport {mapActions, mapGetters} from 'vuex';\nimport {get} from 'lodash';\nimport {EventBus} from '@/plugins/eventBus';\nimport {useMoneyFormatter} from '@/composables/useMoneyFormatter';\nimport {useRouter} from 'vue-router';\n\nconst DeleteButton = defineAsyncComponent(() => import('@/components/buttons/DeleteButton.vue'));\n\nexport default {\n name: 'PricingTemplateEdit',\n\n setup() {\n const router = useRouter();\n const {companyMoneyTextInputSettings} = useMoneyFormatter();\n\n const goBack = () => {\n router.go(-1);\n };\n\n return {\n goBack,\n companyMoneyTextInputSettings,\n };\n },\n\n components: {\n DeleteButton,\n },\n\n data() {\n return {\n durationUnits: [\n {\n text: 'Hours',\n value: 'hours',\n },\n {\n text: 'Days',\n value: 'days',\n },\n {\n text: 'Weeks',\n value: 'weeks',\n },\n {\n text: 'Months',\n value: 'months',\n },\n {\n text: 'Years',\n value: 'years',\n },\n ],\n currentPricingStructure: {\n uuid: null,\n name: '',\n price_example: 100,\n added_amount: 100,\n duration_unit: 'days',\n multiplier: 1,\n price_tiers: [\n {\n name: '1 day',\n quantity: 1,\n period: 'days',\n multiplier: 1,\n example_price: 100,\n },\n ],\n },\n };\n },\n\n created() {\n this.getPricingStructure(this.$route.params.uuid);\n\n EventBus.$on('delete-pricing-structure-success', () => {\n this.$router.push({name: 'settings.pricing.template'}).catch(() => {\n });\n });\n },\n\n watch: {\n pricingStructure: {\n handler() {\n this.setupEditStructure();\n },\n },\n },\n\n computed: {\n ...mapGetters({\n appFeatures: 'app/appFeatures',\n featureWaitlist: 'app/featureWaitlist',\n pricingStructures: 'pricing/pricingStructures',\n pricingStructure: 'pricing/pricingStructure',\n currentWorkingPricingStructure: 'pricing/currentWorkingPricingStructure',\n }),\n automaticAmount: {\n get() {\n return this.currentPricingStructure.example_price;\n },\n set(value) {\n this.currentPricingStructure.example_price = value;\n },\n },\n saveButtonReady() {\n return !this.currentPricingStructure.name || !this.currentPricingStructure.price_example;\n },\n },\n\n methods: {\n ...mapActions({\n getPricingStructure: 'pricing/getPricingStructure',\n updatePriceStructure: 'pricing/updatePriceStructure',\n deletePriceStructure: 'pricing/deletePriceStructure',\n getPricingStructures: 'pricing/getPricingStructures',\n savePriceStructure: 'pricing/savePriceStructure',\n }),\n removePricingTier(index) {\n this.currentPricingStructure.price_tiers.splice(index, 1);\n },\n updateAddedAmount() {\n this.currentPricingStructure.added_amount = this.currentPricingStructure.price_example * this.currentPricingStructure.multiplier;\n },\n updateAddedAmountMultiple() {\n this.currentPricingStructure.multiplier = this.currentPricingStructure.added_amount / this.currentPricingStructure.price_example;\n },\n addPricingTier() {\n const lastUnit = this.currentPricingStructure.price_tiers[this.currentPricingStructure.price_tiers.length - 1];\n const durationUnit = get(lastUnit, 'period', 'days');\n const quantity = get(lastUnit, 'quantity', 0) + 1;\n\n this.currentPricingStructure.price_tiers.push({\n name: `${quantity} ${durationUnit}`,\n quantity,\n period: durationUnit,\n multiplier: 1,\n example_price: 100,\n });\n },\n updateResultingPriceParent() {\n this.currentPricingStructure.added_amount = this.currentPricingStructure.price_example * this.currentPricingStructure.multiplier;\n this.currentPricingStructure.price_tiers.forEach((tier) => {\n const multiplier = +get(tier, 'multiplier', 1);\n const examplePrice = this.currentPricingStructure.price_example;\n let newPrice = multiplier * examplePrice;\n newPrice = Math.round(newPrice * 100) / 100;\n this.$set(tier, 'example_price', newPrice);\n });\n },\n updateResultingPrice(index) {\n const tier = this.currentPricingStructure.price_tiers[index];\n const multiplier = +get(tier, 'multiplier', 1);\n const examplePrice = this.currentPricingStructure.price_example;\n this.$set(tier, 'example_price', multiplier * examplePrice);\n },\n updateMultiplier(index) {\n const tier = this.currentPricingStructure.price_tiers[index];\n const examplePrice = this.currentPricingStructure.price_example;\n const resultingPrice = +get(tier, 'example_price', 0);\n\n this.$set(tier, 'multiplier', resultingPrice / examplePrice);\n },\n updatePriceStructureInit() {\n this.updatePriceStructure(this.currentPricingStructure);\n },\n deletePriceStructureInit() {\n this.deletePriceStructure(this.currentPricingStructure);\n },\n setupEditStructure() {\n this.currentPricingStructure.uuid = this.pricingStructure.uuid;\n this.currentPricingStructure.name = this.pricingStructure.name;\n this.currentPricingStructure.price_example = 100;\n this.currentPricingStructure.multiplier = this.pricingStructure.multiplier;\n\n let durationUnit = ['hour', 'day', 'month', 'week', 'year'].find(key => this.pricingStructure[key] > 0);\n if (durationUnit) {\n this.currentPricingStructure.multiplier = this.pricingStructure[durationUnit];\n\n if (durationUnit[durationUnit.length - 1] !== 's') {\n durationUnit += 's';\n }\n this.currentPricingStructure.duration_unit = durationUnit;\n }\n\n const tiers = this.pricingStructure?.pricing_tiles ?? [];\n\n if (tiers) {\n this.currentPricingStructure.price_tiers = [];\n tiers.forEach((tier) => {\n this.currentPricingStructure.price_tiers.push({\n name: tier.name,\n quantity: tier.quantity,\n period: tier.period,\n multiplier: tier.multiplier,\n example_price: tier.multiplier * this.currentPricingStructure.price_example,\n });\n });\n }\n },\n },\n\n beforeUnmount() {\n EventBus.$off('delete-pricing-structure-success');\n this.$store.commit('pricing/RESET_CURRENT_WORKING_PRICING_STRUCTURE');\n },\n};\n</script>\n<style>\n.evTrKC {\n display: grid;\n grid-template-columns: auto 50px 120px 50px 100px auto 50px;\n column-gap: 6px;\n align-items: flex-end;\n margin-bottom: 12px;\n}\n\n.evTrKC > * {\n margin: 0;\n}\n\n.ONqJD {\n align-self: center;\n color: rgb(118, 127, 130);\n padding-top: 24px;\n}\n\n.fJfBtJ {\n cursor: pointer;\n align-self: center;\n font-size: 14px;\n display: inline-block;\n color: rgb(24, 24, 24);\n}\n\n.jEVlcv {\n padding-top: 19px;\n}\n\n.kXPMMB {\n display: flex;\n -webkit-box-align: center;\n align-items: center;\n -webkit-box-pack: justify;\n justify-content: space-between;\n}\n\n.evTrKC .Label-eJXSuD {\n white-space: nowrap;\n}\n\n.gZKasB {\n display: block;\n color: rgb(24, 24, 24);\n font-size: 14px;\n font-weight: 600;\n line-height: 14px;\n margin-bottom: 5px;\n}\n\n.eYnYJY {\n height: 1.3em;\n width: auto;\n margin-bottom: 6px;\n}\n\n.bsHxqg.bsHxqg.bsHxqg {\n display: block;\n position: relative;\n font-size: 12px;\n}\n\n.cCETsh.cCETsh {\n display: inline-block;\n vertical-align: middle;\n width: 100%;\n height: 38px;\n padding: 0 12px;\n margin: 0;\n color: rgb(24, 24, 24);\n background: rgb(255, 255, 255);\n border: 1px solid rgb(226, 230, 235);\n border-radius: 6px;\n outline: 0;\n font-size: 12px;\n font-weight: 400;\n line-height: 1;\n box-sizing: border-box;\n}\n\n.erHrFZ {\n position: relative;\n}\n\n.css-2b097c-container {\n position: relative;\n box-sizing: border-box;\n}\n\n.kvYiAT .Select__control {\n padding: 0 0 0 12px;\n color: rgb(24, 24, 24);\n background: rgb(255, 255, 255);\n border: 1px solid rgb(226, 230, 235);\n border-radius: 6px;\n font-size: 12px;\n cursor: pointer;\n height: 38px !important;\n overflow: visible !important;\n}\n\n.css-yk16xz-control {\n -webkit-box-align: center;\n align-items: center;\n background-color: rgb(255, 255, 255);\n border-color: rgb(204, 204, 204);\n border-radius: 4px;\n border-style: solid;\n border-width: 1px;\n cursor: default;\n display: flex;\n flex-wrap: wrap;\n -webkit-box-pack: justify;\n justify-content: space-between;\n min-height: 38px;\n position: relative;\n transition: all 100ms ease 0s;\n box-sizing: border-box;\n outline: 0 !important;\n}\n\n.css-1hwfws3 {\n -webkit-box-align: center;\n align-items: center;\n display: flex;\n flex: 1 1 0;\n flex-wrap: wrap;\n padding: 2px 8px;\n position: relative;\n overflow: hidden;\n box-sizing: border-box;\n}\n\n.kvYiAT .Select__value-container {\n padding: 0;\n height: 38px !important;\n}\n\n.css-1wy0on6 {\n -webkit-box-align: center;\n align-items: center;\n align-self: stretch;\n display: flex;\n flex-shrink: 0;\n box-sizing: border-box;\n}\n\n.css-1okebmr-indicatorSeparator {\n align-self: stretch;\n background-color: rgb(204, 204, 204);\n margin-bottom: 8px;\n margin-top: 8px;\n width: 1px;\n box-sizing: border-box;\n}\n\n.kvYiAT .Select__indicator-separator {\n display: none;\n}\n\n.css-tlfecz-indicatorContainer {\n color: rgb(204, 204, 204);\n display: flex;\n padding: 8px;\n transition: color 150ms ease 0s;\n box-sizing: border-box;\n}\n\n.css-19bqh2r {\n display: inline-block;\n fill: currentcolor;\n line-height: 1;\n stroke: currentcolor;\n stroke-width: 0;\n}\n\n.css-1uccc91-singleValue {\n color: rgb(51, 51, 51);\n margin-left: 2px;\n margin-right: 2px;\n max-width: calc(100% - 8px);\n overflow: hidden;\n position: absolute;\n text-overflow: ellipsis;\n white-space: nowrap;\n top: 50%;\n transform: translateY(-50%);\n box-sizing: border-box;\n}\n\n.kvYiAT .Select__single-value {\n overflow: visible;\n color: rgb(24, 24, 24);\n}\n\n/*noinspection CssRedundantUnit*/\n.css-1ogwcvc {\n margin: 0px;\n padding: 0px;\n height: 38px !important;\n}\n\n.ONqJD {\n align-self: center;\n color: rgb(118, 127, 130);\n padding-top: 24px;\n}\n\n.bsHxqg.bsHxqg.bsHxqg {\n display: block;\n position: relative;\n font-size: 12px;\n}\n\n.evTrKC .Label-eJXSuD {\n white-space: nowrap;\n}\n\n.bsHxqg.bsHxqg.bsHxqg > .I-gmFDEA {\n position: absolute;\n height: 38px;\n width: 38px;\n color: rgb(187, 192, 193);\n font-size: 1.25em;\n font-style: normal;\n line-height: 38px;\n text-align: center;\n pointer-events: none;\n}\n\n.bsHxqg.bsHxqg.bsHxqg > .I-gmFDEA + .Input-icnXNI {\n padding-left: 38px;\n}\n\n.xfmMQ .v-select.v-input--dense .v-select__selection--comma {\n margin: 0;\n font-size: 12px;\n font-weight: 400;\n}\n\n.xfmMQ fieldset {\n color: rgb(226, 230, 235) !important;\n border: 1px solid rgb(226, 230, 235);\n}\n\n.xfmMQ input[type=text]:hover:not(:focus) {\n border-color: #CDCDCD;\n -webkit-box-shadow: inset 0 -1px 0 0 rgba(255, 255, 255, 0.8);\n -moz-box-shadow: inset 0 -1px 0 0 rgba(255, 255, 255, 0.8);\n box-shadow: inset 0 -1px 0 0 rgba(255, 255, 255, 0.8);\n}\n\n.cCETsh.cCETsh:hover {\n border-color: rgb(191, 197, 203);\n}\n\n.pricing-structure-example-price fieldset {\n color: rgb(226, 230, 235) !important;\n border: 1px solid rgb(226, 230, 235);\n}\n\n.pricing-structure-example-price:hover {\n border-color: rgb(191, 197, 203) !important;\n}\n\n.esebmt {\n display: grid;\n column-gap: 6px;\n align-items: flex-end;\n grid-template-columns: auto 65px 90px 100px;\n margin-bottom: 0;\n margin-top: 12px;\n}\n\n.esebmt .Label-eJXSuD {\n white-space: nowrap;\n}\n\n/* Chrome, Safari, Edge, Opera */\ninput::-webkit-outer-spin-button,\ninput::-webkit-inner-spin-button {\n -webkit-appearance: none;\n margin: 0;\n}\n\n/* Firefox */\ninput[type=number] {\n -moz-appearance: textfield;\n}\n</style>\n","<template>\n <div>\n <v-card variant=\"outlined\">\n <v-card-title>\n <v-btn class=\"mr-2\" variant=\"text\" @click=\"$router.push({ name: 'settings.pricing.advanced' }).catch(() => {});\">\n <v-icon size=\"small\">mdi-arrow-left</v-icon>\n </v-btn>\n Price Rules\n <v-spacer/>\n </v-card-title>\n\n <v-card-text class=\"mt-3\">\n <div v-if=\"ruleClone\">\n <div class=\"col-6\">\n <v-select\n v-model=\"rule\"\n :items=\"rules\"\n density=\"compact\"\n item-title=\"label\"\n item-value=\"value\"\n label=\"Rule\"\n variant=\"outlined\"\n ></v-select>\n\n <v-text-field\n v-model=\"ruleClone.name\"\n density=\"compact\"\n label=\"Name\"\n variant=\"outlined\"\n ></v-text-field>\n\n <div v-if=\"rule === 'fill-the-gap'\" class=\"mt-1\">\n\n <p class=\"mt-2\">Fill the gap helps you fill in the time between reservations that may incentivize renters\n to book odd or shorter times.</p>\n\n <div class=\"text-2xl border-top\">\n <v-menu open-on-hover>\n <template v-slot:activator=\"{ props }\">\n <v-btn\n style=\"padding-left: 0; padding-right:0;\"\n v-bind=\"props\"\n variant=\"text\"\n >\n <span class=\"i-in-place-edit\">\n {{ ruleClone.rules.action }}\n </span>\n </v-btn>\n </template>\n\n <v-list>\n <v-list-item v-model=\"ruleClone.rules.action\">\n <v-list-item value=\"increase\">\n <v-list-item-title>Increase</v-list-item-title>\n </v-list-item>\n <v-list-item value=\"decrease\">\n <v-list-item-title>Decrease</v-list-item-title>\n </v-list-item>\n </v-list-item>\n </v-list>\n </v-menu>\n listing prices by\n <v-menu :close-on-content-click=\"false\" open-on-hover>\n <template v-slot:activator=\"{ props }\">\n <v-btn\n style=\"padding-left: 0; padding-right:0;\"\n v-bind=\"props\"\n variant=\"text\"\n >\n <span class=\"i-in-place-edit\">\n <span v-if=\"ruleClone.rules.mode ==='amount'\">$</span>\n {{ ruleClone.rules.value }}\n <span v-if=\"ruleClone.rules.mode ==='percent'\">%</span>\n </span>\n </v-btn>\n </template>\n\n <v-card>\n <v-card-text>\n <v-text-field\n v-model=\"ruleClone.rules.value\"\n label=\"Amount\"\n max=\"365\"\n min=\"0\"\n type=\"number\"\n variant=\"outlined\"\n ></v-text-field>\n <v-radio-group v-model=\"ruleClone.rules.mode\" inline>\n <v-radio label=\"Percent\" value=\"percent\"></v-radio>\n <v-radio label=\"Amount\" value=\"amount\"></v-radio>\n </v-radio-group>\n </v-card-text>\n </v-card>\n </v-menu>\n between reservations\n <v-menu :close-on-content-click=\"false\" open-on-hover>\n <template v-slot:activator=\"{ props}\">\n <v-btn\n style=\"padding-left: 0; padding-right:0;\"\n v-bind=\"props\"\n variant=\"text\"\n >\n <span class=\"i-in-place-edit\">\n {{ ruleClone.rules.time_value }}\n <span>Days</span>\n </span>\n </v-btn>\n </template>\n\n <v-card>\n <v-card-text>\n <v-text-field\n v-model=\"ruleClone.rules.time_value\"\n label=\"Amount\"\n max=\"365\"\n min=\"0\"\n type=\"number\"\n variant=\"outlined\"\n ></v-text-field>\n </v-card-text>\n </v-card>\n </v-menu>\n out.\n\n <v-expansion-panels class=\"mt-3\">\n <v-expansion-panel>\n <v-expansion-panel-title v-slot=\"{ open }\">\n <div>\n <div class=\"col-4\">Exclusions</div>\n <div class=\"col-8\">\n <v-fade-transition leave-absolute>\n <span v-if=\"open\">Add exclusion rules</span>\n <span v-else class=\"float-end\">{{ exclusionCount }} exclusion</span>\n </v-fade-transition>\n </div>\n </div>\n </v-expansion-panel-title>\n <v-expansion-panel-text>\n <div :class=\"{ '': ruleExclusionsGapMax}\">\n <v-checkbox v-model=\"ruleExclusionsGapMax\" density=\"compact\" hide-details>\n <template v-slot:label>\n <div class=\"flex\">\n Only when any two reservations are\n {{ ruleExclusionsGapMaxValue }}\n day apart or less\n <tippy\n allowHTML\n arrow\n interactive>\n <template v-slot:trigger>\n <v-icon class=\" ml-1\" size=\"small\">mdi-help-circle-outline</v-icon>\n </template>\n <span>\n This exclusion will only apply when the gap between two reservations is {{\n ruleExclusionsGapMaxValue\n }} day or less. This is useful for when you want to fill the gap between two reservations that are {{\n ruleExclusionsGapMaxValue\n }} day apart.\n <TheHelpLink url=\"https://help.fleetwire.io/en/article/advanced-pricing-cxlndp/?bust=1666982473968\"></TheHelpLink>\n </span>\n </tippy>\n </div>\n </template>\n </v-checkbox>\n <div v-if=\"ruleExclusionsGapMax\" class=\"ml-10\">\n <v-text-field\n v-model=\"ruleExclusionsGapMaxValue\"\n class=\"mt-1 mb-1\"\n density=\"compact\"\n hide-details\n label=\"Max Gap\"\n max=\"365\"\n min=\"0\"\n style=\"width: 100px;\"\n type=\"number\"\n variant=\"outlined\"\n ></v-text-field>\n </div>\n <hr v-if=\"ruleExclusionsGapMax\">\n </div>\n\n <v-checkbox\n v-model=\"ruleClone.exclusions.weekends.on\"\n density=\"compact\"\n hide-details\n label=\"Weekends\"\n ></v-checkbox>\n <v-checkbox\n v-model=\"ruleClone.exclusions.holidays.on\"\n density=\"compact\"\n hide-details\n label=\"Holidays\"\n ></v-checkbox>\n <div>\n <v-checkbox\n v-model=\"ruleClone.exclusions.listings.on\"\n density=\"compact\"\n hide-details\n label=\"These Listings\"\n ></v-checkbox>\n <div v-if=\"ruleClone.exclusions.listings.on\" class=\"mt-3 pl-10\">\n <ListingAutocompleteDropdown\n :allow-multiple=\"true\"\n :allow-select-all=\"true\"\n :pre-selected=\"ruleClone.exclusions.listings.listings\"\n style=\"z-index: 1000\"\n @selectedListing=\"listingSelected($event)\"\n ></ListingAutocompleteDropdown>\n </div>\n </div>\n </v-expansion-panel-text>\n </v-expansion-panel>\n </v-expansion-panels>\n </div>\n </div>\n </div>\n </div>\n </v-card-text>\n <v-card-actions>\n <v-spacer/>\n <DeleteButton class=\"mr-2\" @deleteConfirmed=\"deletePricingRule\"/>\n <v-btn :loading=\"pricingRulesLoading.update\" size=\"small\" @click=\"savePricingRuleInit()\">Save</v-btn>\n </v-card-actions>\n </v-card>\n\n </div>\n</template>\n\n<script lang=\"ts\">\nimport {defineAsyncComponent} from 'vue';\nimport {app} from '@/app';\nimport {EventBus} from '@/plugins/eventBus';\nimport {mapActions, mapGetters} from 'vuex';\nimport {get} from 'lodash';\n\nconst DeleteButton = defineAsyncComponent(() => import('@/components/buttons/DeleteButton.vue'));\nconst ListingAutocompleteDropdown = () => import('@/components/dashboard/listings/ListingAutocompleteDropdown.vue');\n\nexport default {\n name: 'AdvancedPricingEdit',\n\n components: {\n DeleteButton,\n ListingAutocompleteDropdown,\n },\n\n data() {\n return {\n timer: 0,\n pricingRuleUuid: this.$route.params.uuid,\n EventBus,\n rule: null,\n rules: [\n {\n label: 'Raise/lower prices',\n value: 'raise-lower-prices',\n data: {\n action: 'raise',\n booking_cnt: 0,\n },\n },\n {\n label: 'Fill the Gap',\n value: 'fill-the-gap',\n },\n ],\n ruleClone: null,\n };\n },\n\n created() {\n if (this.pricingRules.length === 0) {\n this.getPricingRules();\n }\n\n EventBus.$on('create-pricing-rules-success', () => {\n this.getPricingRules();\n });\n EventBus.$on('delete-pricing-rules-success', () => {\n this.getPricingRules();\n });\n },\n\n watch: {\n pricingRules: {\n immediate: true,\n handler() {\n this.findPricingRule();\n },\n },\n currentPricingRule: {\n immediate: true,\n handler(rule) {\n this.rule = get(rule, 'rule_type', null);\n this.ruleClone = rule;\n },\n },\n },\n\n computed: {\n ...mapGetters({\n pricingRules: 'pricing/pricingRules',\n pricingRulesLoading: 'pricing/loading',\n }),\n ruleExclusionsGapMax: {\n get() {\n return get(this.ruleClone, 'exclusions.gap_max.on', false);\n },\n set(value) {\n if (!get(this.ruleClone, 'exclusions.gap_max')) {\n app.set(this.ruleClone.exclusions, 'gap_max', {on: false, value: 1});\n }\n app.set(this.ruleClone.exclusions.gap_max, 'on', value);\n },\n },\n ruleExclusionsGapMaxValue: {\n get() {\n return get(this.ruleClone, 'exclusions.gap_max.value', 1);\n },\n set(value) {\n if (!get(this.ruleClone, 'exclusions.gap_max')) {\n app.set(this.ruleClone.exclusions, 'gap_max', {on: false, value: 1});\n }\n app.set(this.ruleClone.exclusions.gap_max, 'value', +value);\n },\n },\n currentPricingRule() {\n return this.pricingRules.find((rule) => rule.uuid === this.pricingRuleUuid);\n },\n exclusionCount() {\n if (!this.ruleClone) {\n return 0;\n }\n return Object.values(this.ruleClone.exclusions).filter((v) => v.on).length;\n },\n },\n\n methods: {\n ...mapActions({\n getPricingRules: 'pricing/getPricingRules',\n deletePricingRules: 'pricing/deletePricingRules',\n savePricingRule: 'pricing/savePricingRule',\n }),\n listingSelected(listings) {\n if (!this.ruleClone.exclusions.listings.listings) {\n app.set(this.ruleClone.exclusions.listings, 'listings', []);\n }\n this.ruleClone.exclusions.listings.listings = listings.map((l) => {\n if (typeof l === 'string') {\n return l;\n }\n return l.l_id;\n });\n },\n savePricingRuleInit() {\n this.savePricingRule({\n uuid: this.pricingRuleUuid,\n data: this.ruleClone,\n rule: this.ruleClone.rule_type,\n });\n },\n findPricingRule() {\n return this.pricingRules.find((pricingRule) => pricingRule.uuid === this.pricingRuleUuid);\n },\n firstPartOfUuid(uuid) {\n return uuid.split('-')[0];\n },\n ruleType(rule) {\n const type = get(rule, 'rule_type', 'N/A');\n switch (type) {\n case 'fill-the-gap':\n return 'Fill the gap';\n case 'raise-lower-prices':\n return 'Raise/Lower prices';\n default:\n return 'Unknown';\n }\n },\n deletePricingRule() {\n this.deletePricingRules([rule.uuid])\n .finally(() => {\n this.$router.push({name: 'settings.pricing.advanced'}).catch();\n });\n },\n },\n\n beforeUnmount() {\n this.rule = null;\n this.ruleClone = null;\n\n EventBus.$off('create-pricing-rules-success');\n EventBus.$off('delete-pricing-rules-success');\n },\n};\n</script>\n","<template>\n <div>\n <TheTaxes/>\n </div>\n</template>\n\n<script lang=\"ts\" setup>\nimport {defineAsyncComponent, onMounted} from 'vue';\nimport {useTaxAndFee} from '@/composables/useTaxAndFee';\n\nconst TheTaxes = defineAsyncComponent(() => import('@/components/dashboard/settings/pricing/Taxes.vue'));\n\nconst {getTaxCategories} = useTaxAndFee();\n\nonMounted(() => {\n getTaxCategories();\n});\n</script>\n","<template>\n <div>\n <h2 class=\"mt-8 mb-4 font-bold text-2xl\">Security</h2>\n\n <ChangePassword/>\n\n <TwoFactorAuth/>\n </div>\n</template>\n\n<script lang=\"ts\" setup>\nimport {defineAsyncComponent} from 'vue';\n\nconst ChangePassword = defineAsyncComponent(() => import('@/components/dashboard/settings/general/ChangePassword.vue'));\nconst TwoFactorAuth = defineAsyncComponent(() => import('@/components/dashboard/settings/general/TwoFactorAuth.vue'));\n</script>\n","<template>\n <div>\n <h2 class=\"mt-8 mb-4 font-bold text-2xl\">\n <FeatureTitle\n featurePremium\n title=\"API Tokens\"\n />\n <the-help-link url=\"https://help.fleetwire.io/en/article/introduction-to-the-fleetwire-api-izq6u/?bust=1676569061818\"></the-help-link>\n </h2>\n\n <v-card :disabled=\"authLoading.createApiToken\">\n <v-card-title>\n <div class=\"flex flex-col sm:flex-row gap-2 sm:gap-0\">\n <div>Standard keys</div>\n <v-spacer class=\"hidden sm:block\"/>\n <v-btn\n :disabled=\"!planIncludesApi\"\n :loading=\"authLoading.createApiToken\"\n class=\"w-full sm:w-auto\"\n size=\"small\"\n @click=\"createUserTokensInit()\"\n >\n <v-icon class=\"mr-1\" size=\"small\">mdi-plus</v-icon>\n Secret Key\n </v-btn>\n </div>\n </v-card-title>\n <v-card-subtitle>\n <div class=\"flex flex-col sm:flex-row items-start sm:items-center gap-2\">\n <span>These keys will allow you to authenticate API requests.</span>\n <v-btn\n class=\"text-decoration-none\"\n href=\"https://documenter.getpostman.com/view/263138/Tz5p6dWS\"\n size=\"x-small\"\n target=\"_blank\"\n variant=\"text\"\n >\n API Documentation\n <v-icon class=\"ml-1\" size=\"x-small\">mdi-open-in-new</v-icon>\n </v-btn>\n </div>\n </v-card-subtitle>\n <v-card-text>\n <div v-if=\"apiTokens.length > 0\" class=\"overflow-x-auto\">\n <table class=\"w-full text-sm text-left text-gray-500 dark:text-gray-400\">\n <thead class=\"text-xs text-gray-700 uppercase bg-gray-50 dark:bg-gray-700 dark:text-gray-400\">\n <tr>\n <th class=\"px-4 sm:px-6 py-3\" scope=\"col\">Name</th>\n <th class=\"hidden sm:table-cell px-6 py-3\" scope=\"col\">Last Used</th>\n <th class=\"hidden sm:table-cell px-6 py-3\" scope=\"col\">Created</th>\n <th class=\"px-4 sm:px-6 py-3\" scope=\"col\"></th>\n </tr>\n </thead>\n <tbody>\n <tr v-for=\"(item, key) in apiTokens\" :key=\"key\" class=\"bg-white border-b dark:bg-gray-800 dark:border-gray-700 hover:bg-gray-50 dark:hover:bg-gray-600\">\n <td class=\"px-4 sm:px-6 py-4 font-medium text-gray-900 whitespace-nowrap dark:text-white\">\n {{ item.name }}\n </td>\n <td class=\"hidden sm:table-cell px-6 py-4\">\n {{ item.last_used_at ? formatRentalDate(item.last_used_at, 'MMM DD') : '--' }}\n </td>\n <td class=\"hidden sm:table-cell px-6 py-4\">\n {{ formatRentalDate(item.created_at, 'MMM DD') }}\n </td>\n <td class=\"px-4 sm:px-6 py-4 text-right\">\n <v-menu location=\"bottom\">\n <template v-slot:activator=\"{ props }\">\n <v-btn size=\"small\" v-bind=\"props\" variant=\"text\">\n <v-icon>mdi-dots-vertical</v-icon>\n </v-btn>\n </template>\n\n <v-list>\n <v-list-item @click=\"deleteApiTokenInit(item)\">\n <v-list-item-title class=\"text-red-500\">\n Delete\n </v-list-item-title>\n </v-list-item>\n </v-list>\n </v-menu>\n </td>\n </tr>\n </tbody>\n </table>\n </div>\n <div v-else class=\"text-center py-4\">No API Tokens</div>\n </v-card-text>\n </v-card>\n\n <v-dialog v-model=\"showInitialTokenDialog\" :persistent=\"true\" width=\"500\">\n <v-card>\n <v-card-title class=\"pb-0\">\n <div class=\"flex items-center\">\n <span class=\"text-xl font-medium\">Your New API Token</span>\n <v-spacer/>\n <v-icon color=\"green\" size=\"small\">mdi-shield-lock</v-icon>\n </div>\n </v-card-title>\n\n <v-card-text>\n <div class=\"mb-4 p-3 bg-red-50 border border-red-200 rounded-lg\">\n <div class=\"flex items-center\">\n <v-icon class=\"mr-2\" color=\"red\" size=\"small\">mdi-alert-circle</v-icon>\n <span class=\"text-red-600 text-sm\">\n This secret key will only be shown once. Make sure to copy it now.\n </span>\n </div>\n </div>\n\n <v-tooltip location=\"right\">\n <template v-slot:activator=\"{ props }\">\n <div class=\"relative\">\n <label for=\"new-token\"></label>\n <input\n id=\"new-token\"\n :value=\"newToken\"\n class=\"cursor-pointer w-full border-2 border-gray-200 rounded-lg p-3 pr-10 font-mono text-sm bg-gray-50 hover:bg-gray-100 transition-colors\"\n readonly\n v-bind=\"props\"\n @click=\"copyToClipboardInit(newToken)\"\n >\n <v-icon class=\"absolute right-3 top-1/2 -translate-y-1/2\" color=\"gray\" size=\"small\" style=\"position: absolute !important;\">\n mdi-content-copy\n </v-icon>\n </div>\n </template>\n <span>Click to copy token</span>\n </v-tooltip>\n </v-card-text>\n\n <v-card-actions class=\"pt-0\">\n <v-spacer/>\n <v-btn\n color=\"primary\"\n variant=\"elevated\"\n @click=\"showInitialTokenDialog = false\"\n >\n Done\n </v-btn>\n </v-card-actions>\n </v-card>\n </v-dialog>\n\n <v-snackbar v-model=\"copiedText\" location=\"bottom\">\n Token Copied\n </v-snackbar>\n <v-snackbar v-model=\"tokenDeletedSnack\" location=\"bottom\">\n Token Deleted\n </v-snackbar>\n\n <UpgradePlanFeatureDialog2\n :bullets=\"[\n {\n text: 'Build on top of Fleetwire to extend and customize its capability.'\n },\n {\n text: 'Build amazing custom reports the way you want and wherever you want.'\n },\n {\n text: 'Combine Fleetwire\\'s data with any other data from analytics tools.'\n },\n ]\"\n :tiers=\"['premium']\"\n description=\"Benefit from efficient data exchange and integration, reducing the need for manual processes.\"\n feature=\"API\"\n right-side-message=\"Unlock the full potential of your fleet management game by seamlessly integrating Fleetwire into your favorite tools.\"\n >\n <template v-slot:rightImage>\n <svg fill=\"none\" viewBox=\"0 0 589 528\" xmlns=\"http://www.w3.org/2000/svg\">\n <g clip-path=\"url(#api-paywall_svg__clip0_1620_2881)\">\n <circle cx=\"295.396\" cy=\"260.542\" fill=\"#A886B2\" opacity=\"0.16\" r=\"244.5\"></circle>\n <circle cx=\"295.396\" cy=\"260.542\" fill=\"#A886B2\" opacity=\"0.16\" r=\"194.5\"></circle>\n <circle cx=\"295.396\" cy=\"260.542\" fill=\"#A886B2\" opacity=\"0.16\" r=\"144.5\"></circle>\n <circle cx=\"295.396\" cy=\"260.542\" fill=\"#654B6B\" r=\"94.5\"></circle>\n <!-- <path d=\"M284.715 33.416 C 284.276 33.527,283.017 33.892,281.918 34.227 C 279.199 35.057,98.279 124.029,95.457 125.924 C 73.759 140.493,86.104 175.524,112.288 173.685 C 117.805 173.297,116.700 173.813,204.196 130.782 C 315.734 75.926,304.418 81.689,308.295 77.765 C 321.856 64.040,316.703 41.323,298.493 34.557 C 295.555 33.466,287.247 32.778,284.715 33.416 M243.066 155.241 C 239.188 155.944,240.963 155.097,169.506 190.356 C 102.068 223.632,104.477 222.367,100.604 226.549 C 82.731 245.854,102.443 277.094,127.594 269.326 C 131.666 268.068,261.695 203.835,264.424 201.733 C 285.979 185.131,270.004 150.356,243.066 155.241\" fill=\"#FF7F3B\"/>-->\n <!-- <path d=\"M173.027 290.750 C 170.160 291.517,166.160 293.411,137.741 307.455 L 113.983 319.196 110.949 322.231 C 94.358 338.822,106.013 366.983,129.471 366.983 C 136.232 366.983,136.247 366.977,162.438 354.037 C 174.525 348.065,186.417 342.215,188.863 341.037 C 199.885 335.730,205.780 327.104,205.780 316.284 C 205.780 299.316,189.233 286.416,173.027 290.750\" fill=\"#FF7F3B\"/>-->\n <path d=\"M457.773 59.38l10.643 6.858c1.856-2.942 28.944-36.493 72.231-49.026 37.966-10.991 92.595-1.24 96.786-2.31 2.955-3.261 12.981-10.827 2.453-9.95-4.945.878-61.817-8.555-102.259 2.978-46.617 13.295-77.392 47.932-79.854 51.45z\" fill=\"#DBC4E1\"></path>\n <path d=\"M430.527 136.07l-11.89-5.98 1.02-2.03c6.18-12.27 1.23-27.23-11.04-33.4l-21.21 42.15a4.243 4.243 0 001.89 5.7l41.28 20.77 21.46-42.58c-11.54-5.81-15.7 3.82-21.5 15.36l-.01.01z\" fill=\"#FE8787\"></path>\n <path d=\"M426.367 148.46l-35.77-18-2.25 4.47 38.02 13.53z\" fill=\"#F65B5B\"></path>\n <path d=\"M470.352 67.128L442.896 97.04l-59.02 62.04 8.08 7.68 60.915-64.03 29.351-31.902-11.87-3.7zM367.207 171.601l13.08 12.44-.44 26.6-39.19-37.28 26.55-1.76z\" fill=\"#DBC4E1\"></path>\n <path d=\"M340.667 173.347l-18.568 19.519 39.19 37.281 18.568-19.519-39.19-37.281z\" fill=\"#DBC4E1\"></path>\n <path d=\"M345.587 207.42l-19.6-18.64 3.96-4.16 15.64 22.8z\" fill=\"#DBC4E1\"></path>\n <path d=\"M322.068 185.031l-7.795 8.195 47.051 44.759 7.795-8.195-47.051-44.759zM382.257 157.541l11.31 10.76-13.28 15.74-13.08-12.44 15.05-14.06z\" fill=\"#DBC4E1\"></path>\n <path d=\"M408.657 45.93l-32.75 65.08c-2.66 5.29-.51 11.79 4.77 14.45l45.69 22.99-5.1 10.13 9.3 4.68 41.08-28.61h41.06l-.05-73.61s-37.31-.09-40.73-.09l-48.82-19.79c-5.29-2.66-11.79-.51-14.45 4.77z\" fill=\"#FE8787\"></path>\n <path d=\"M502.616 140.441l-.24-84.67 26.14.35-.36 84.37-25.54-.05z\" fill=\"#fff\"></path>\n <path d=\"M516.887 52.79l80.38-.83v97.37l-80.22-5.68-.16-90.86z\" fill=\"#1D1D1D\"></path>\n <path d=\"M157.89 404.115l12.04 6.06-1.03 2.05c-6.26 12.43-1.25 27.58 11.18 33.83l21.49-42.69c1.07-2.12.21-4.71-1.91-5.78l-41.81-21.04-21.74 43.13c11.69 5.88 15.9-3.87 21.78-15.56z\" fill=\"#FE8787\"></path>\n <path d=\"M162.1 391.556l36.23 18.23 2.28-4.53-38.51-13.7z\" fill=\"#F65B5B\"></path>\n <path d=\"M248.79 287.865a3.515 3.515 0 00-4.96.34l-17.45 20.01 5.3 4.62 17.45-20.01c1.28-1.46 1.12-3.68-.34-4.96zM276.84 312.325a3.524 3.524 0 00-4.96.34l-17.45 20.01 5.3 4.62 17.45-20.01a3.524 3.524 0 00-.34-4.96zM190.24 375l-56.62 64.93-12.17 25.9 12.17 3.23 10.34-23.805 54.79-62.835-8.51-7.42zM126.113 532.23c-1.127-6.431 4.887-38.744 9.997-46.462 0-4.401-2.784-10.867-9.998-3.149-6.621 8.549-11.286 44.483-10.284 52.438l10.285-2.827zM215.23 368.575l-13.78-12.02-.73-26.93 41.29 36-26.78 2.95z\" fill=\"#DBC4E1\"></path>\n <path d=\"M218.654 309.064l-17.929 20.56 41.294 36.01 17.929-20.56-41.294-36.01z\" fill=\"#DBC4E1\"></path>\n <path d=\"M218.269 301.138l-7.525 8.63 49.569 43.226 7.525-8.629-49.569-43.227zM200.61 383.456l-11.91-10.38 12.75-16.52 13.78 12.02-14.62 14.88z\" fill=\"#DBC4E1\"></path>\n <path d=\"M190.4 374.556l8.51 7.42-4.51 5.16-4-12.58zM235.53 331.375l20.65 18.01-3.82 4.38-16.83-22.39z\" fill=\"#DBC4E1\"></path>\n <path d=\"M180.03 495.395l33.18-65.92c2.69-5.35.52-11.94-4.83-14.64l-46.28-23.29 5.17-10.26-9.42-4.74-41.61 28.98H74.65l.05 74.56s37.78.09 41.26.09l49.44 20.06c5.35 2.69 11.94.52 14.63-4.84z\" fill=\"#FE8787\"></path>\n <path d=\"M84.87 399.055l.24 85.14-26.48.27.37-85.46 25.87.05z\" fill=\"#fff\"></path>\n <path d=\"M70.42 487.835l-81.42 6.42v-98.62l81.25.17.17 92.03z\" fill=\"#1D1D1D\"></path>\n <path d=\"M118.185 229.31l-5.136 7.441-8.464 2.833 7.259 5.195 2.723 8.621 5.136-7.441 8.465-2.834-7.259-5.194-2.724-8.621z\" fill=\"#90AFFF\" opacity=\"0.6\"></path>\n <path d=\"M376.691 372.335l-5.135 7.441-8.465 2.833 7.259 5.195 2.724 8.621 5.135-7.441 8.465-2.834-7.259-5.194-2.724-8.621z\" fill=\"#FFD282\" opacity=\"0.6\"></path>\n <path d=\"M157.568 286.023l-3.853 5.58-6.348 2.126 5.444 3.896 2.043 6.465 3.853-5.579 6.348-2.126-5.444-3.897-2.043-6.465z\" fill=\"#99D8BA\" opacity=\"0.6\"></path>\n <path d=\"M183.993 135.209l-6.421 9.298-10.58 3.545 9.072 6.495 3.407 10.774 6.418-9.299 10.582-3.544-9.074-6.495-3.404-10.774z\" fill=\"#FFAB90\" opacity=\"0.6\"></path>\n <path d=\"M459.189 211.132l-6.421 9.299-10.579 3.544 9.071 6.495 3.407 10.775 6.418-9.299 10.583-3.544-9.075-6.496-3.404-10.774z\" fill=\"#90AFFF\" opacity=\"0.6\"></path>\n <path d=\"M297.657 87.452l-6.421 9.298-10.579 3.544 9.071 6.496 3.407 10.774 6.419-9.299 10.582-3.544-9.075-6.496-3.404-10.773z\" fill=\"#FFD282\" opacity=\"0.6\"></path>\n <path d=\"M91.3 321.76l-11.16-2.765-7.174-8.797-2.917 10.97-9.032 7.115 11.16 2.765 7.174 8.797 2.918-10.971 9.031-7.114z\" fill=\"#FFAB90\" opacity=\"0.6\"></path>\n <path d=\"M98.886 147.048l-11.009-2.73-7.079-8.677-2.88 10.822-8.908 7.019 11.008 2.73 7.08 8.677 2.88-10.822 8.908-7.019z\" fill=\"#99D8BA\" opacity=\"0.6\"></path>\n <path d=\"M329.447 449.45l-15.287-3.793-9.832-12.048-4.001 15.028-12.37 9.749 15.286 3.788 9.833 12.053 4-15.032 12.371-9.745z\" fill=\"#90AFFF\" opacity=\"0.6\"></path>\n <path d=\"M530.402 272.411l-12.978-3.22-8.347-10.228-3.396 12.758-10.502 8.276 12.977 3.217 8.348 10.231 3.395-12.761 10.503-8.273z\" fill=\"#FFD282\" opacity=\"0.6\"></path>\n <path d=\"M470.366 413.876l-15.287-3.793-9.833-12.048-4 15.028-12.371 9.749 15.286 3.789 9.834 12.052 3.999-15.032 12.372-9.745z\" fill=\"#FFAB90\" opacity=\"0.6\"></path>\n </g>\n <defs>\n <clipPath id=\"api-paywall_svg__clip0_1620_2881\">\n <path d=\"M0 0h589v528H0z\" fill=\"#fff\"></path>\n </clipPath>\n </defs>\n </svg>\n </template>\n </UpgradePlanFeatureDialog2>\n\n </div>\n</template>\n\n<script lang=\"ts\" setup>\nimport {defineAsyncComponent, onMounted, ref} from 'vue';\nimport {copyTextToClipboard} from '@/helpers';\nimport {useDateFormatter} from '@/composables/useDate';\nimport {useAuth} from '@/composables/useAuth';\nimport {useSubscription} from '@/composables/useSubscription';\n\nconst FeatureTitle = defineAsyncComponent(() => import('@/components/dashboard/FeatureTitle.vue'));\n\nconst UpgradePlanFeatureDialog2 = defineAsyncComponent(() => import('@/components/dashboard/dialogs/UpgradePlanFeatureDialog2.vue'));\n\nconst {formatRentalDate} = useDateFormatter();\nconst {planIncludesApi} = useSubscription();\n\nconst {\n apiTokens,\n authLoading,\n fetchUserTokens,\n createUserTokens,\n deleteApiToken,\n} = useAuth();\n\nconst showInitialTokenDialog = ref(false);\nconst newToken = ref('');\nconst copiedText = ref(false);\nconst tokenDeletedSnack = ref(false);\n\nonMounted(() => {\n fetchUserTokens();\n});\n\nconst copyToClipboardInit = (text) => {\n try {\n copyTextToClipboard(text);\n copiedText.value = true;\n } catch (err) {\n // eslint-disable-next-line no-alert\n alert('Oops, unable to copy');\n }\n};\n\nconst createUserTokensInit = () => {\n createUserTokens().then((token) => {\n showInitialTokenDialog.value = true;\n newToken.value = token;\n });\n};\n\nconst deleteApiTokenInit = (token) => {\n deleteApiToken(token).then(() => {\n fetchUserTokens();\n tokenDeletedSnack.value = true;\n });\n};\n</script>\n","<template>\n <div>\n <h2 class=\"mt-8 mb-4 font-bold text-2xl\">\n <FeatureTitle\n featurePremium\n featureStandard\n title=\"Activity Log\"\n />\n </h2>\n\n <v-card>\n <v-card-text>\n <div v-if=\"activity.length > 0\" class=\"space-y-4\">\n <div v-for=\"(item, key) in activity\" :key=\"key\"\n class=\"bg-white dark:bg-gray-800 rounded-lg shadow-sm p-4 hover:bg-gray-50 dark:hover:bg-gray-600\">\n <div class=\"flex flex-col sm:flex-row sm:items-center sm:justify-between gap-2\">\n <div class=\"font-medium text-gray-900 dark:text-white\">\n {{ item.description }}\n </div>\n <div class=\"text-sm text-gray-500 dark:text-gray-400\">\n {{ formatRentalDate(item.created_at) }}\n </div>\n </div>\n </div>\n </div>\n\n <div v-if=\"activity.length > 0\">\n <div class=\"grid grid-cols-1 gap-2\">\n <v-pagination\n v-model=\"page\"\n :length=\"pages\"\n class=\"my-4\"\n />\n </div>\n </div>\n\n <div v-else class=\"text-center py-8 text-gray-500 dark:text-gray-400\">No Activity</div>\n </v-card-text>\n </v-card>\n </div>\n</template>\n\n<script lang=\"ts\" setup>\nimport {defineAsyncComponent, onMounted, ref, watch} from 'vue';\nimport {useDateFormatter} from '@/composables/useDate';\nimport {useCompany} from '@/composables/useCompany';\n\nconst FeatureTitle = defineAsyncComponent(() => import('@/components/dashboard/FeatureTitle.vue'));\n\nconst {formatRentalDate} = useDateFormatter();\nconst {getActivityLog} = useCompany();\n\nconst activity = ref([]);\nconst page = ref(1);\nconst pages = ref(1);\n\nwatch(page, () => {\n console.dir(page.value);\n getActivityLog({page: page.value}).then((response) => {\n activity.value = response?.data || [];\n });\n});\n\nonMounted(() => {\n getActivityLogInit();\n});\n\nconst getActivityLogInit = () => {\n getActivityLog({page: 1})\n .then((response) => {\n page.value = response?.current_page || 1;\n pages.value = response?.last_page || 1;\n activity.value = response?.data || [];\n });\n};\n</script>\n","<template>\n <div class=\"UpsellCard\">\n <div>\n <v-card class=\"bg-white\" variant=\"flat\">\n <v-card-title>\n Upgrade to Premium\n </v-card-title>\n\n <v-card-text>\n <div class=\"grid grid-cols-2 justify-between\">\n <div class=\"\">More listings, more staff accounts, custom domain, additional scripts, and more. Upgrade to\n Fleetwire's Premium plan today.\n </div>\n <div class=\"grid col-auto grid-flow-col gap-2 justify-end\">\n\n <v-dialog v-model=\"upgradeDialogIsOpen\" width=\"950\">\n <template v-slot:activator=\"{ props }\">\n <v-btn size=\"small\" v-bind=\"props\">Learn More</v-btn>\n </template>\n\n <template v-slot:default=\"{ isActive }\">\n <v-card>\n <v-img class=\"app-15cj5iy e1xdmtt71\" data-element=\"PositionTopRight\" data-source-file=\"highlightModalContainer.tsx\" src=\"data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNDE0IiBoZWlnaHQ9Ijg1IiBmaWxsPSJub25lIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciPjxwYXRoIGZpbGwtcnVsZT0iZXZlbm9kZCIgY2xpcC1ydWxlPSJldmVub2RkIiBkPSJNMCAwaDQxNHY3OC4zMDZMMjk2Ljc3NCA4NC4xNlY2OGgtMjcuMzMybC00LjE5Ny0zNC43MUw3LjUyNyAzMC4xMSAwIDB6IiBmaWxsPSIjRDlDRkU5Ii8+PHBhdGggZD0iTTIyOS44ODYgNDQuMjQ0aDI1LjA5MWwuODM2IDE1Ljg5LTI1LjkyNy0yLjE3NFY0NC4yNDR6IiBmaWxsPSIjRDlDRkU5Ii8+PC9zdmc+\" width=\"400px\"></v-img>\n <div style=\"position: relative;padding: 70px 80px;overflow: hidden;\">\n\n <div class=\"try-premium-modal\">\n <div>\n <div style=\"text-transform: uppercase;font-weight: bold;color: rgb(108, 95, 199);font-size: 11px;\">\n Next stop - Premium Plan\n </div>\n <div style=\"font-size: 22px;font-weight: bold;margin: 8px 0;\">Try the upgrade. Stress less.\n </div>\n </div>\n <div class=\"main-upsell\">\n <div>\n <div class=\"app-1fttcpj e6gn4392\">\n <div>\n {{ stepDescription }}\n </div>\n <v-img :src=\"stepImage\" class=\"app-1jbawm2 e6gn4391\" width=\"540px\"></v-img>\n <div class=\"app-10re2i4 e6gn4390\" v-html=\"stepSecondDescription\"/>\n </div>\n </div>\n\n <div>\n <div class=\"app-1vbqv9y e1qu3fq81\">Premium Features Include</div>\n <div v-for=\"(feature, index) in features\" :key=\"index\" :aria-selected=\"featureStep === index\" :style=\"featureListStyle(index)\" class=\"app-s85quu e1qu3fq80\" @click=\"featureStep = index\">\n <a v-if=\"feature.ctaUrl\" :href=\"feature.ctaUrl\" target=\"_blank\">\n <v-icon size=\"small\">mdi-flash-outline</v-icon>\n {{ feature.title }}\n </a>\n <span v-else>\n <v-icon size=\"small\">mdi-flash-outline</v-icon>\n {{ feature.title }}\n </span>\n </div>\n </div>\n </div>\n </div>\n\n\n <v-card-actions>\n <v-btn :to=\"{name: 'settings.account.plans.confirm'}\" color=\"primary\" variant=\"tonal\">Upgrade\n </v-btn>\n <v-btn variant=\"outlined\" @click=\"isActive.value = false\">Maybe Later</v-btn>\n </v-card-actions>\n </div>\n\n <v-img class=\"app-1n8nfba e1xdmtt70\" data-element=\"PositionBottomLeft\" data-source-file=\"highlightModalContainer.tsx\" src=\"data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMzExIiBoZWlnaHQ9IjE0NCIgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj48cGF0aCBmaWxsLXJ1bGU9ImV2ZW5vZGQiIGNsaXAtcnVsZT0iZXZlbm9kZCIgZD0iTTI5OC4wMTMgMTQ0SC4wMDFWMGwxMDIuNzQgNy4wOTQgMi40NjcgODAuODI0IDY0LjE0MSAzLjQzMyAxLjI2NyAyNS4wMTEgMTI0Ljk0My0xLjhMMjk4LjAxMyAxNDR6IiBmaWxsPSIjRDlDRkU5Ii8+PHBhdGggZD0iTTEyMC40NTEgNjQuOTA2djE1LjYwNmwtMTEuMzE2LS43MDktLjI0OS0xNS4yNTEgMTEuNTY1LjM1NHpNMzA5LjU3OCAxMTMuMTQzbDEuNDIzIDE1LjUzNS0xMC4xNDEgMi41NTQtMS40OTUtMTcuNTIyIDEwLjIxMy0uNTY3eiIgZmlsbD0iI0Q5Q0ZFOSIvPjwvc3ZnPg==\" width=\"200px\"/>\n </v-card>\n </template>\n </v-dialog>\n\n <v-btn :to=\"{name: 'settings.account.plans.confirm'}\" color=\"primary\" size=\"small\">Upgrade</v-btn>\n </div>\n </div>\n </v-card-text>\n </v-card>\n </div>\n </div>\n</template>\n\n<script lang=\"ts\" setup>\nimport {computed, ref, watch} from 'vue';\n\nconst upgradeDialogIsOpen = ref(false);\nconst featureStep = ref(0);\nconst safeFeatureStep = computed(() => Math.min(featureStep.value, features.length - 1));\n\nconst features: Feature[] = [\n {\n description: 'Expand your visibility by adding and managing up to 150 vehicle listings.',\n imageUrl: '/images/up-sell/listings2.png',\n title: 'Additional Listings',\n secondDescription: \"You'll need the <strong>Premium Plan</strong> to enable 150 listings. You're\\n\" +\n \" currently on the Standard plan.\",\n },\n {\n description: 'Coordinate your team by adding and managing up to 20 staff accounts for improved collaboration.',\n imageUrl: '/images/up-sell/team2.png',\n title: 'Additional Staff Accounts',\n secondDescription: \"You'll need the <strong>Premium Plan</strong> to enable 150 listings. You're\\n\" +\n \" currently on the Standard plan.\",\n },\n {\n description: 'Broaden your operational presence by adding and managing up to 2 additional branch locations.',\n imageUrl: 'https://s1.sentry-cdn.com/_static/dist/sentry/assets/cross-project.bd06afab95685c8b6ad5.svg',\n title: 'Additional Branches',\n secondDescription: \"You'll need the <strong>Premium Plan</strong> to enable 150 listings. You're\\n\" +\n \" currently on the Standard plan.\",\n },\n {\n description: 'Fortify your brand\\'s digital footprint with a seamless connection to a custom domain for your Fleetwire store, inclusive of a secure SSL certificate.',\n imageUrl: 'https://s1.sentry-cdn.com/_static/dist/sentry/assets/change-alerts.53afc4cd6161b91abbc4.svg',\n title: 'Custom Domain',\n secondDescription: \"You'll need the <strong>Premium Plan</strong> to enable 150 listings. You're\\n\" +\n \" currently on the Standard plan.\",\n },\n {\n description: 'Professionalize your communication with a custom email domain that aligns with your brand identity.',\n imageUrl: 'https://s1.sentry-cdn.com/_static/dist/sentry/assets/cross-project.bd06afab95685c8b6ad5.svg',\n title: 'Custom Email Domain',\n secondDescription: \"You'll need the <strong>Premium Plan</strong> to enable 150 listings. You're\\n\" +\n \" currently on the Standard plan.\",\n },\n {\n description: 'Tailor the checkout experience by adding custom fields to gather unique information like insurance details, secondary drivers, etc.',\n imageUrl: 'https://s1.sentry-cdn.com/_static/dist/sentry/assets/change-alerts.53afc4cd6161b91abbc4.svg',\n title: 'Custom Checkout Fields',\n secondDescription: \"You'll need the <strong>Premium Plan</strong> to enable 150 listings. You're\\n\" +\n \" currently on the Standard plan.\",\n },\n {\n description: 'Empower your site with enhanced analytics and tracking through customizable scripts and styles for services like Google Analytics and Facebook Pixel.',\n imageUrl: 'https://s1.sentry-cdn.com/_static/dist/sentry/assets/cross-project.bd06afab95685c8b6ad5.svg',\n title: 'Additional Scripts & Styles',\n secondDescription: \"You'll need the <strong>Premium Plan</strong> to enable 150 listings. You're\\n\" +\n \" currently on the Standard plan.\",\n },\n {\n description: 'Unleash Unlimited Functionality: Harness the Power of our Flexible API and Webhooks to Build Your Own Custom Integrations and Expand the Capabilities of Fleetwire.',\n imageUrl: 'https://s1.sentry-cdn.com/_static/dist/sentry/assets/change-alerts.53afc4cd6161b91abbc4.svg',\n title: 'API',\n secondDescription: \"You'll need the <strong>Premium Plan</strong> to enable 150 listings. You're\\n\" +\n \" currently on the Standard plan.\",\n },\n {\n description: 'Receive top-tier assistance with our premium email support, dedicated to resolving your queries with priority.',\n imageUrl: 'https://s1.sentry-cdn.com/_static/dist/sentry/assets/cross-project.bd06afab95685c8b6ad5.svg',\n title: 'Premium Email Support',\n secondDescription: \"You'll need the <strong>Premium Plan</strong> to enable 150 listings. You're\\n\" +\n \" currently on the Standard plan.\",\n },\n {\n description: 'Explore the full spectrum of advanced features and exclusive benefits with our Premium Plan—visit our pricing page to discover more..',\n imageUrl: 'https://s1.sentry-cdn.com/_static/dist/sentry/assets/change-alerts.53afc4cd6161b91abbc4.svg',\n ctaUrl: 'https://front.fleetwire.io/pricing/',\n title: 'And More...',\n secondDescription: \"You'll need the <strong>Premium Plan</strong> to enable 150 listings. You're\\n\" +\n \" currently on the Standard plan.\",\n }\n];\n\ninterface Feature {\n description: string;\n imageUrl: string;\n title: string;\n secondDescription: string;\n ctaUrl?: string;\n}\n\nconst stepDescription = computed(() => features[safeFeatureStep.value].description);\nconst stepImage = computed(() => features[safeFeatureStep.value].imageUrl);\nconst stepSecondDescription = computed(() => features[safeFeatureStep.value].secondDescription);\n\nconst featureListStyle = computed(() => (index: number) => {\n return {\n transform: featureStep.value === index ? 'translateX(-7px)' : 'translateX(0px)',\n };\n});\n\nwatch(() => upgradeDialogIsOpen.value, (newVal) => {\n if (!newVal) {\n featureStep.value = 0;\n }\n});\n</script>\n\n<style scoped>\n\n.main-upsell {\n display: grid;\n font-size: 14px;\n margin-bottom: 16px;\n}\n\n.app-1vbqv9y {\n font-weight: bold;\n margin-bottom: 8px;\n display: grid;\n grid-template-columns: 1fr max-content;\n gap: 4px;\n}\n\n.app-s85quu[aria-selected=\"true\"] {\n color: rgb(62, 52, 70);\n font-weight: bold;\n}\n\n.app-s85quu {\n cursor: pointer;\n transition: color 300ms ease 0s;\n color: rgb(128, 112, 143);\n position: relative;\n display: grid;\n grid-template-columns: max-content auto;\n gap: 8px;\n align-items: center;\n align-content: center;\n margin-bottom: 4px;\n}\n\n.app-1fttcpj {\n display: flex;\n flex-direction: column;\n}\n\n.app-1jbawm2 {\n margin: 16px 0;\n}\n\n.app-10re2i4 {\n font-size: 11px;\n line-height: 1.5;\n}\n\n.app-15cj5iy {\n position: absolute;\n width: 400px;\n right: 0;\n top: 0;\n pointer-events: none;\n border-radius: 0 8px 0 0;\n}\n\n.app-1n8nfba {\n position: absolute;\n width: 200px;\n bottom: 0;\n left: 0;\n pointer-events: none;\n border-radius: 0 0 0 8px;\n z-index: -1;\n}\n\n@media (min-width: 800px) {\n .main-upsell {\n grid-template-columns: auto 200px;\n gap: 30px;\n }\n}\n\n</style>\n","import {useStore} from 'vuex';\nimport {computed, ref} from 'vue';\nimport dayjs from 'dayjs';\n\n\n// Define types for expected data structures\ninterface Identity {\n person_details?: {\n first_name?: string;\n last_name?: string;\n dob?: { month: number; day: number; year: number };\n document_number?: string;\n expiration_date?: { month: number; day: number; year: number };\n address?: {\n city?: string;\n country?: string;\n line1?: string;\n line2?: string;\n postal_code?: string;\n state?: string;\n };\n };\n status?: string;\n vs_id?: string;\n last_error?: string;\n redirect_to_url?: string;\n}\n\nexport function useStripe() {\n const store = useStore();\n\n const stripeLoading = computed(() => store.getters['stripe/loading']);\n const stripeAccounts = computed(() => store.getters['stripe/account']);\n const stripePrices = computed(() => store.getters['stripe/stripePrices']);\n\n const fetchStripeAccounts = async () => store.dispatch('stripe/fetchStripeAccount');\n\n const fetchStripeCapabilities = async () => {\n await store.dispatch('stripe/fetchStripeCapabilities');\n }\n\n const saveStripeKey = async (payload: string) => {\n await store.dispatch('company/saveStripeKey', payload);\n }\n const resetStripeKey = async () => {\n await store.dispatch('company/resetStripeKey');\n }\n const testStripeIdentity = async (payload: { stripeKey: string }) => {\n await store.dispatch('stripe/testStripeIdentity', payload);\n }\n\n const fetchSubscriptionDetails = async () => {\n await store.dispatch('stripe/fetchSubscriptionDetails');\n }\n\n const fetchStripePriceData = async () => {\n await store.dispatch('stripe/fetchStripePriceData');\n }\n\n\n const fetchCheckoutUrl = async (data) => {\n return await store.dispatch('stripe/fetchCheckoutUrl', data);\n }\n\n /**\n * Helper function for formatting dates.\n */\n const formatDate = (month?: number, day?: number, year?: number): string | null => {\n if (!month || !day || !year) return null;\n return dayjs(`${month}/${day}/${year}`, 'M/D/YYYY').format('MMM D, YYYY');\n };\n\n const stripeIdentityName = (identity: Identity) => {\n const firstName = identity?.person_details?.first_name || '';\n const lastName = identity?.person_details?.last_name || '';\n\n return {\n set: !!firstName,\n first_name: firstName,\n last_name: lastName,\n full_name: `${firstName} ${lastName}`.trim(),\n };\n }\n\n const stripeIdentityDOB = (identity: Identity) => {\n const dob = identity?.person_details?.dob;\n const formattedDate = formatDate(dob?.month, dob?.day, dob?.year);\n\n return {\n set: !!formattedDate,\n dob: formattedDate,\n age: formattedDate ? dayjs().diff(formattedDate, 'year') : null,\n };\n }\n\n /**\n * Formats identity status for display.\n */\n const stripeIdentityStatus = (identity: Identity) => {\n const status = identity?.status?.replace(/_/g, ' ') || 'unknown';\n if (!status) return 'unknown';\n\n return status.charAt(0).toUpperCase() + status.slice(1).toLowerCase();\n }\n\n /**\n * Returns the Stripe Identity Verification ID.\n */\n const stripeIdentityVSId = (id: Identity) => id?.vs_id || null;\n\n /**\n * Returns the last error related to the Stripe identity.\n */\n const stripeIdentityErrors = (id: Identity) => id?.last_error || null;\n\n\n /**\n * Returns the Stripe identity verification URL.\n */\n const stripeIdentityUrl = (id: Identity) => id?.redirect_to_url || null;\n\n\n /**\n * Returns the document number for identity verification.\n */\n const stripeIdentityDocumentNumber = (id: Identity) => id?.person_details?.document_number || null;\n\n\n /**\n * Returns the formatted expiration date of an identity document.\n */\n const stripeIdentityDocumentExpiration = (id: Identity) => {\n const expiration = id?.person_details?.expiration_date;\n return expiration ? formatDate(expiration.month, expiration.day, expiration.year) : null;\n };\n\n\n /**\n * Extracts and returns the identity address.\n */\n const stripeIdentityAddress = (id: Identity) => {\n const address = id?.person_details?.address || {};\n return {\n city: address.city || '',\n country: address.country || '',\n line1: address.line1 || '',\n line2: address.line2 || '',\n postal_code: address.postal_code || '',\n state: address.state || '',\n };\n };\n\n const stripeInstance = ref<any>(null);\n\n /**\n * Dynamically loads Stripe.js and initializes the Stripe instance.\n */\n const loadStripe = (publishableKey: string): Promise<any> => {\n return new Promise((resolve, reject) => {\n if (stripeInstance.value) {\n return resolve(stripeInstance.value);\n }\n\n if (window.Stripe) {\n stripeInstance.value = window.Stripe(publishableKey);\n return resolve(stripeInstance.value);\n }\n\n const script = document.createElement('script');\n script.src = 'https://js.stripe.com/v3/';\n script.async = true;\n script.onload = () => {\n if (window.Stripe) {\n stripeInstance.value = window.Stripe(publishableKey);\n resolve(stripeInstance.value);\n } else {\n reject(new Error('Stripe failed to load'));\n }\n };\n script.onerror = () => reject(new Error('Failed to load Stripe script'));\n\n document.head.appendChild(script);\n });\n };\n\n const fetchSetupUrl = async (data) => {\n return await store.dispatch('stripe/fetchSetupUrl', data);\n }\n\n return {\n stripeLoading,\n stripeAccounts,\n stripePrices,\n fetchStripeCapabilities,\n fetchCheckoutUrl,\n fetchSetupUrl,\n loadStripe,\n fetchStripeAccounts,\n stripeIdentityName,\n stripeIdentityDOB,\n stripeIdentityStatus,\n stripeIdentityVSId,\n stripeIdentityDocumentNumber,\n stripeIdentityDocumentExpiration,\n stripeIdentityUrl,\n stripeIdentityErrors,\n stripeIdentityAddress,\n fetchSubscriptionDetails,\n fetchStripePriceData,\n saveStripeKey,\n resetStripeKey,\n testStripeIdentity,\n }\n}","<template>\n <div>\n <div class=\"flex flex-col sm:flex-row sm:items-center sm:justify-between my-5\">\n <div class=\"flex-grow\">\n <h4 class=\"font-bold text-2xl\">Subscription</h4>\n\n <div class=\"mt-2 flex flex-wrap gap-2 plan-features-title-list-item\">\n <div class=\"pr-2\">\n <span v-if=\"inTrial\">Trailing ({{ upperFirst(subscriptionPlan) }})</span>\n <span v-else>\n {{ upperFirst(subscriptionPlan) }} Plan\n </span>\n </div>\n\n <div class=\"pr-2\">{{ planSupportedFeatureCounts.listings }} Listings</div>\n <div class=\"pr-2\">{{ planSupportedFeatureCounts.seats }} Seats</div>\n <div class=\"pr-2\">{{ planSupportedFeatureCounts.locations }} Branches</div>\n </div>\n </div>\n\n <div class=\"mt-4 sm:mt-0\">\n <v-btn\n :to=\"{name: 'settings.account.plans.confirm'}\"\n class=\"text-decoration-none w-full sm:w-auto\"\n variant=\"tonal\"\n >\n Manage Subscription\n </v-btn>\n </div>\n </div>\n\n <v-alert\n v-if=\"hasPastDueSubscription\"\n class=\"mb-4\"\n color=\"orange\"\n type=\"warning\"\n >\n Subscription payment is past due and may result in service interruption. Please update your payment method to\n avoid interruption.\n </v-alert>\n\n <template v-if=\"checkPermission(['account_and_billing_manage'])\">\n <div>\n <UpsellCard v-if=\"shouldShowUpsellCard\"/>\n\n <div class=\"grid grid-cols-1 sm:grid-cols-2 lg:grid-cols-3 gap-5 my-5\">\n <RenewsOneCard/>\n <PlanPriceCard/>\n <CardOnFileCard/>\n </div>\n\n <div class=\"mb-10\">\n <div class=\"mb-5 text-sm font-medium text-center text-gray-500 border-b border-gray-200 dark:text-gray-400 dark:border-gray-700\">\n <ul class=\"flex flex-wrap -mb-px overflow-x-auto\">\n <li class=\"mr-2\">\n <router-link\n v-slot=\"{ href, navigate, isExactActive }\"\n :to=\"{name: 'settings.account.overview'}\"\n custom\n >\n <a\n :href=\"href\"\n :style=\"[isExactActive && 'border-bottom: 2px solid blue;']\"\n class=\"inline-block p-3 sm:p-4 border-b-2 border-blue-600 rounded-t-lg hover:text-gray-600 hover:border-gray-300 dark:hover:text-gray-300 whitespace-nowrap\"\n @click=\"navigate\"\n >Overview</a>\n </router-link>\n </li>\n <li class=\"mr-2\">\n <router-link\n v-slot=\"{ href, navigate, isExactActive }\"\n :to=\"{name: 'settings.account.receipts'}\"\n custom\n >\n <a\n :href=\"href\"\n :style=\"[isExactActive && 'border-bottom: 2px solid blue;']\"\n class=\"inline-block p-3 sm:p-4 border-b-2 border-blue-600 rounded-t-lg hover:text-gray-600 hover:border-gray-300 dark:hover:text-gray-300 whitespace-nowrap\"\n @click=\"navigate\"\n >Receipts</a>\n </router-link>\n </li>\n <li class=\"mr-2\">\n <router-link\n v-slot=\"{ href, navigate, isExactActive }\"\n :to=\"{name: 'settings.account.billing'}\"\n custom\n >\n <a\n :href=\"href\"\n :style=\"[isExactActive && 'border-bottom: 2px solid blue;']\"\n class=\"inline-block p-3 sm:p-4 border-b-2 border-blue-600 rounded-t-lg hover:text-gray-600 hover:border-gray-300 dark:hover:text-gray-300 whitespace-nowrap\"\n @click=\"navigate\"\n >Billing Details</a>\n </router-link>\n </li>\n </ul>\n </div>\n\n <router-view name=\"default\"/>\n </div>\n </div>\n\n <div class=\"my-6 sm:my-10\">\n <div class=\"\">\n <v-card>\n <v-alert v-if=\"!defaultPayment\" type=\"warning\" variant=\"tonal\">\n <div v-if=\"!hasActiveSubscription\">\n You have {{ trialDaysLeftWithDay }} left on your trial and you don't have a payment method set up. <br>\n </div>\n Add a card for uninterrupted service.\n </v-alert>\n </v-card>\n </div>\n </div>\n\n <DeleteAccountSection/>\n </template>\n\n <div v-else class=\"h-100 row align-items-center\">\n <div class=\"col text-center\">\n <v-img height=\"200px\" src=\"/images/illustrations/undraw_security.svg\"/>\n <v-img height=\"200px\" src=\"/images/illustrations/undraw_security.svg\"/>\n <h2 class=\"newCustomer__header\">No Permissions</h2>\n <p>You dont have permissions to view this page.<br> You will need to ask your company admin\n to add \"Account & Billing Manage\" permission.</p>\n </div>\n </div>\n </div>\n</template>\n\n<script lang=\"ts\" setup>\nimport {computed, defineAsyncComponent, onBeforeMount} from 'vue';\nimport UpsellCard from '@/components/dashboard/settings/account/UpsellCard.vue';\nimport checkPermission from '@/utils/permission';\nimport {useSubscription} from '@/composables/useSubscription';\nimport {useCompany} from '@/composables/useCompany';\nimport {useStripe} from '@/composables/useStripe';\nimport {upperFirst} from '@/utils/text';\n\nconst DeleteAccountSection = defineAsyncComponent(() => import('@/components/dashboard/settings/account/DeleteAccountSection.vue'));\nconst CardOnFileCard = defineAsyncComponent(() => import('@/views/dashboard/settings/Billing/SubscriptionDetailCards/CardOnFileCard.vue'));\nconst RenewsOneCard = defineAsyncComponent(() => import('@/views/dashboard/settings/Billing/SubscriptionDetailCards/RenewsOneCard.vue'));\nconst PlanPriceCard = defineAsyncComponent(() => import('@/views/dashboard/settings/Billing/SubscriptionDetailCards/PlanPriceCard.vue'));\n\nconst {\n inTrial,\n subscriptionPlan,\n hasActiveSubscription,\n trialDaysLeft,\n planSupportedFeatureCounts,\n hasPastDueSubscription,\n} = useSubscription();\nconst {company} = useCompany();\n\nconst {fetchSubscriptionDetails} = useStripe();\n\n\nconst shouldShowUpsellCard = computed(() => {\n return subscriptionPlan.value === 'basic' || subscriptionPlan.value === 'standard';\n});\n\nconst cardBrand = computed(() => company.value?.pm_type);\nconst cardLastFour = computed(() => company.value?.pm_last_four);\nconst defaultPayment = computed(() => {\n if (!cardBrand.value || !cardLastFour.value) return false;\n return `${upperFirst(cardBrand.value)}-${cardLastFour.value}`;\n});\n\nconst trialDaysLeftWithDay = computed(() => {\n return `${trialDaysLeft.value} day${trialDaysLeft.value === 1 ? '' : 's'}`;\n});\n\nonBeforeMount(() => {\n fetchSubscriptionDetails();\n});\n</script>\n\n<style>\n.plan-features-title-list-item > :not(:last-child) {\n border-right: 1px solid rgb(224, 220, 229);\n}\n\n@media (max-width: 640px) {\n .plan-features-title-list-item > :not(:last-child) {\n border-right: none;\n border-bottom: 1px solid rgb(224, 220, 229);\n padding-bottom: 0.5rem;\n }\n}\n</style>","import {useStore} from 'vuex';\nimport {computed} from 'vue';\nimport {StripePaymentIntent} from \"@/store/modules/payments\";\nimport {useMoneyFormatter} from \"@/composables/useMoneyFormatter\";\n\nexport function usePayments() {\n const store = useStore();\n const {fromCents, toCents} = useMoneyFormatter();\n\n const paymentMethods = computed(() => store.getters['payments/paymentMethods']);\n const paymentsLoading = computed(() => store.getters['payments/loading']);\n const billingSessionUrl = computed(() => store.getters['payments/billingSessionUrl']);\n const paymentForm = computed(() => store.getters['payments/paymentForm']);\n const newPayment = computed(() => store.getters['payments/newPayment']);\n const payment = computed(() => store.getters['payments/payment']);\n\n\n // Fetch actions\n const fetchPaymentMethods = () => store.dispatch('payments/fetchPaymentMethods');\n const fetchPayments = (payload: Record<string, any>) => store.dispatch('payments/fetchPayments', payload);\n const fetchPayment = async (paymentId: string) => store.dispatch('payments/fetchPayment', paymentId);\n const fetchStripeCheckoutUrl = (payload: { price: string }) => store.dispatch('stripe/fetchCheckoutUrl', payload);\n const sendPaymentRequestLinkViaSms = (payload: Record<string, any>) => store.dispatch('payments/sendPaymentRequestLinkViaSms', payload);\n const updateDefaultBillingDetails = (paymentMethodId: string) => store.dispatch('payments/updateDefaultBillingDetails', paymentMethodId);\n const addPaymentMethod = (paymentIntent: StripePaymentIntent) => store.dispatch('payments/addPaymentMethod', paymentIntent);\n\n // Computed values for new payment amounts\n const newPaymentAmount = computed({\n get: () => fromCents(newPayment.value?.amount),\n set: (amount: number) => {\n console.dir(newPayment.value);\n console.dir(amount);\n if (newPayment.value) newPayment.value.amount = toCents(amount);\n },\n });\n\n const newPaymentKeepDepositAmount = computed({\n get: () => fromCents(newPayment.value?.keep_deposit_amount),\n set: (amount: number) => {\n if (newPayment.value) newPayment.value.keep_deposit_amount = toCents(amount);\n },\n });\n\n const newPaymentSecurityDeposit = computed({\n get: () => fromCents(newPayment.value?.security_deposit),\n set: (amount: number) => {\n if (newPayment.value) newPayment.value.security_deposit = toCents(amount);\n },\n });\n\n //RESET_NEW_PAYMENT\n const resetNewPayment = () => store.commit('payments/RESET_NEW_PAYMENT');\n\n\n return {\n payment,\n paymentForm,\n paymentMethods,\n paymentsLoading,\n billingSessionUrl,\n newPayment,\n newPaymentAmount,\n newPaymentKeepDepositAmount,\n newPaymentSecurityDeposit,\n resetNewPayment,\n fetchPayment,\n fetchPayments,\n sendPaymentRequestLinkViaSms,\n updateDefaultBillingDetails,\n fetchStripeCheckoutUrl,\n fetchPaymentMethods,\n addPaymentMethod,\n }\n}","<template>\n <div class=\"md:grid md:grid-cols-3 md:gap-6\">\n <div class=\"md:col-span-1 flex justify-between mb-4 md:mb-0\">\n <div class=\"px-4 sm:px-0\">\n <h3 class=\"text-lg font-medium text-gray-900 dark:text-gray-100\">Team Management</h3>\n <p class=\"mt-1 text-sm text-gray-600 dark:text-gray-400\">\n Add team members to your Fleetwire account and manage their access levels with customizable role\n permissions.<br><br>\n <TheHelpLink url=\"https://help.fleetwire.io/en/article/creating-team-accounts-3vjoe5/?bust=1675454097202\"></TheHelpLink>\n </p>\n </div>\n </div>\n\n <div class=\"md:col-span-2\">\n <v-card>\n <v-alert v-if=\"seatLimitReached\" class=\"card-alert-full\" density=\"compact\" type=\"warning\">\n Seat limit reached for your plan.\n </v-alert>\n\n <v-card-title class=\"px-4 sm:px-6\">\n <div class=\"flex flex-col sm:flex-row sm:items-center gap-2 sm:gap-0\">\n <v-badge :content=\"companyEmployees.length\" :inline=\"true\">\n Seats\n </v-badge>\n <v-spacer/>\n <v-btn\n :disabled=\"seatLimitReached || !checkRole(['company_admin'])\"\n :to=\"{ name: 'settings.account.employees.new' }\"\n class=\"text-decoration-none w-full sm:w-auto\"\n color=\"primary\"\n size=\"small\"\n variant=\"outlined\"\n >\n <v-icon class=\"mr-2\">mdi-plus</v-icon>\n Invite team member\n </v-btn>\n </div>\n </v-card-title>\n <v-divider opacity=\"50\"/>\n <v-container class=\"px-4 sm:px-6\">\n <div v-if=\"checkRole(['company_admin'])\">\n <v-list class=\"team-list\">\n <v-list-item\n v-for=\"employee in companyEmployees\"\n :key=\"employee.email\"\n :class=\"{'border-l-4 border-primary': employee.email === user.email}\"\n :to=\"{ name: 'settings.account.employees', params: { 'e_id': employee.uuid }}\"\n class=\"text-decoration-none py-3 px-4 rounded-lg hover:bg-gray-50 dark:hover:bg-gray-800 transition-colors duration-200\"\n >\n <div class=\"flex items-center justify-between w-full\">\n <div class=\"flex items-center\">\n <v-avatar\n class=\"shadow-sm\"\n color=\"primary\"\n size=\"40\"\n >\n <span class=\"text-white font-medium\">{{ employeeInitials(employee) }}</span>\n </v-avatar>\n <div class=\"ml-4\">\n <div class=\"flex items-center gap-2\">\n <span class=\"text-gray-900 dark:text-gray-100 font-medium\">\n {{ employee.name }}\n </span>\n <v-chip\n v-if=\"employee.email === user.email\"\n class=\"text-xs\"\n color=\"primary\"\n size=\"small\"\n variant=\"outlined\"\n >\n Account Owner\n </v-chip>\n </div>\n <div class=\"text-sm text-gray-500 dark:text-gray-400 mt-1\">\n {{ employee.email }}\n </div>\n </div>\n </div>\n <v-icon class=\"opacity-50\" color=\"gray\" size=\"small\">mdi-chevron-right</v-icon>\n </div>\n </v-list-item>\n </v-list>\n </div>\n <div v-else class=\"flex items-center gap-2 text-gray-500 dark:text-gray-400\">\n <v-icon size=\"small\">mdi-lock</v-icon>\n You are not the company admin to be able to view this section.\n </div>\n </v-container>\n </v-card>\n </div>\n </div>\n</template>\n\n<script lang=\"ts\" setup>\nimport {computed, onMounted} from 'vue';\nimport {useStore} from 'vuex';\nimport {useSubscription} from '@/composables/useSubscription';\nimport checkRole from '@/utils/role';\nimport {Employee} from '@/types';\n\nconst store = useStore();\n\nconst {seatLimitReached} = useSubscription();\n\nconst getEmployees = () => {\n store.dispatch('company/getEmployees');\n};\n\nconst companyEmployees = computed<Employee[]>(() => store.getters['company/employees']);\nconst user = store.getters['auth/user'];\n\nconst employeeInitials = (employee: Employee): string => {\n if (employee.first_name && employee.last_name) {\n return employee.first_name[0] + employee.last_name[0];\n }\n\n const matches = employee.name?.match(/\\b\\w/g) || [];\n\n return matches.slice(0, 2).join('').toUpperCase();\n};\n\n\nonMounted(() => {\n getEmployees();\n});\n</script>\n\n<style scoped>\n.team-list {\n @apply divide-y divide-gray-100 dark:divide-gray-800;\n}\n\n.team-list :deep(.v-list-item) {\n @apply min-h-0;\n}\n\n.team-list :deep(.v-list-item--active) {\n @apply bg-gray-50 dark:bg-gray-800;\n}\n</style>","<template>\n <div>\n <v-card class=\"mb-5\" variant=\"flat\">\n <v-card-title>People to Notify</v-card-title>\n <v-card-text>\n <div class=\"grid grid-cols-1 sm:grid-cols-2 gap-4\">\n <div class=\"border rounded p-4 flex flex-col sm:flex-row items-start sm:items-center\">\n <div class=\"flex-grow\">\n <strong>{{ company.name }}</strong>\n <p class=\"text-sm text-gray-600\">{{ company.email }}</p>\n <p class=\"text-sm text-gray-600\">{{ company.phone }}</p>\n </div>\n <div class=\"flex flex-col sm:flex-row gap-2\">\n <v-checkbox v-model=\"notificationSettings.notify_sms\" :disabled=\"!company.phone\" label=\"SMS\" @update:model-value=\"updateNotificationSettings()\"/>\n <v-checkbox v-model=\"notificationSettings.notify_email\" :disabled=\"!company.email\" label=\"EMAIL\" @update:model-value=\"updateNotificationSettings()\"/>\n </div>\n </div>\n <div v-for=\"employee in employeeNotificationSettings\" :key=\"employee.uuid\" class=\"border rounded p-4 flex flex-col sm:flex-row items-start sm:items-center\">\n <div class=\"flex-grow\">\n <strong>{{ employee.name }}</strong>\n <p class=\"text-sm text-gray-600\">{{ employee.email }}</p>\n <p class=\"text-sm text-gray-600\">{{ employee.phone }}</p>\n </div>\n <div class=\"flex flex-col sm:flex-row gap-2\">\n <v-checkbox v-model=\"employee.notify_sms\" :disabled=\"!employee.phone\" label=\"SMS\" @update:model-value=\"updateEmployeeNotificationSettings(employee)\"/>\n <v-checkbox v-model=\"employee.notify_email\" :disabled=\"!employee.email\" label=\"EMAIL\" @update:model-value=\"updateEmployeeNotificationSettings(employee)\"/>\n </div>\n </div>\n </div>\n </v-card-text>\n </v-card>\n\n <v-card class=\"mb-5\" variant=\"flat\">\n <v-card-title>\n Fleetwire\n </v-card-title>\n <v-card-text v-if=\"notificationSettings\">\n <div class=\"mt-1\">\n <div class=\"grid grid-cols-2\">\n <div></div>\n <div class=\"\">\n <span class=\"mr-md-4 mr-4\">SMS</span>\n <span class=\"mr-md-0 mr-2\">EMAIL</span>\n </div>\n </div>\n <div class=\"\">\n <div class=\"list-group-item\">\n <div class=\"grid grid-cols-2 \">\n <div>\n <p class=\"mb-0\" style=\"font-size: 1rem;\">\n Fleetwire Booking\n </p>\n <small class=\"text-gray-700\">\n If you get a direct booking\n </small>\n </div>\n <div class=\"col-auto\">\n <div class=\"notification-checkbox-group\">\n <v-checkbox\n v-model=\"notificationSettings.fw_booking_sms\"\n :disabled=\"settingsLoading.notifications\"\n class=\"mr-2\"\n />\n <v-checkbox\n v-model=\"notificationSettings.fw_booking_email\"\n :disabled=\"settingsLoading.notifications\"\n />\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n\n <div class=\"list-group list-group-flush\">\n <div class=\"list-group-item\">\n <div class=\"grid grid-cols-2 align-items-center\">\n <div>\n <p class=\"mb-0\" style=\"font-size: 1rem;\">\n Vehicle Maintenance Reminders\n </p>\n <small class=\"text-gray-700\">\n If you have a vehicle maintenance reminder set up.\n </small>\n </div>\n <div class=\"col-auto\">\n <div class=\"notification-checkbox-group\">\n <v-checkbox\n v-model=\"notificationSettings.vehicle_maintenance_reminder_sms\"\n :disabled=\"settingsLoading.notifications\"\n class=\"mr-2\"\n />\n <v-checkbox\n v-model=\"notificationSettings.vehicle_maintenance_reminder_email\"\n :disabled=\"settingsLoading.notifications\"\n />\n </div>\n </div>\n </div>\n </div>\n </div>\n\n <div class=\"list-group list-group-flush\">\n <div class=\"list-group-item\">\n <div class=\"grid grid-cols-2 align-items-center\">\n <div>\n <p class=\"mb-0\" style=\"font-size: 1rem;\">\n Vehicle Recall Notifications\n </p>\n <small class=\"text-gray-700\">\n If you have a vehicle with a known recall from NHTSA.\n </small>\n </div>\n <div class=\"col-auto\">\n <div class=\"notification-checkbox-group\">\n <v-checkbox\n v-model=\"notificationSettings.vehicle_recall_sms\"\n :disabled=\"settingsLoading.notifications\"\n class=\"mr-2\"\n />\n <v-checkbox\n v-model=\"notificationSettings.vehicle_recall_email\"\n :disabled=\"settingsLoading.notifications\"\n />\n </div>\n </div>\n </div>\n </div>\n </div>\n\n <div class=\"list-group list-group-flush\">\n <div class=\"list-group-item\">\n <div class=\"grid grid-cols-2\">\n <div class=\"\">\n <p class=\"mb-0\" style=\"font-size: 1rem;\">\n Renter Invoice Paid\n </p>\n <small class=\"text-gray-700\">\n When a renter invoice is paid\n </small>\n </div>\n <div class=\"\">\n <div class=\"notification-checkbox-group\">\n <v-checkbox\n v-model=\"notificationSettings.renter_invoice_paid_sms\"\n :disabled=\"settingsLoading.notifications\"\n class=\"mr-2\"\n />\n <v-checkbox\n v-model=\"notificationSettings.renter_invoice_paid_email\"\n :disabled=\"settingsLoading.notifications\"\n />\n </div>\n </div>\n </div>\n </div>\n </div>\n\n <div class=\"list-group list-group-flush\">\n <div class=\"list-group-item\">\n <div class=\"grid grid-cols-2\">\n <div class=\"\">\n <p class=\"mb-0\" style=\"font-size: 1rem;\">\n New Toll Transaction\n </p>\n <small class=\"text-gray-700\">\n When a vehicle receives a new toll\n </small>\n </div>\n <div>\n <div class=\"notification-checkbox-group\">\n <v-checkbox\n v-model=\"notificationSettings.toll_new_transaction_sms\"\n :disabled=\"settingsLoading.notifications\"\n class=\"mr-2\"\n />\n <v-checkbox\n v-model=\"notificationSettings.toll_new_transaction_email\"\n :disabled=\"settingsLoading.notifications\"\n />\n </div>\n </div>\n </div>\n </div>\n </div>\n </v-card-text>\n </v-card>\n\n <v-card class=\"mb-5\" variant=\"flat\">\n <v-card-title>\n Turo\n </v-card-title>\n <v-card-text v-if=\"notificationSettings\">\n <div class=\"mt-3\">\n <div class=\"grid grid-cols-2\">\n <div></div>\n <div class=\"float-right pr-md-3 pr-0\">\n <span class=\"mr-md-4 mr-4\">SMS</span>\n <span class=\"mr-md-0 mr-2\">EMAIL</span>\n </div>\n </div>\n <div class=\"list-group list-group-flush\">\n <div class=\"list-group-item\">\n <div class=\"grid grid-cols-2 align-items-center\">\n <div>\n <p class=\"mb-0 list-title\">\n Turo Error\n </p>\n <small class=\"text-gray-700\">\n If we get a Turo communication error\n </small>\n </div>\n <div>\n <div class=\"notification-checkbox-group\">\n <v-checkbox\n v-model=\"notificationSettings.turo_communication_error_sms\"\n :disabled=\"settingsLoading.notifications\"\n class=\"mr-2\"\n />\n <v-checkbox\n v-model=\"notificationSettings.turo_communication_error_email\"\n :disabled=\"settingsLoading.notifications\"\n />\n </div>\n </div>\n </div>\n </div>\n <div class=\"list-group-item\">\n <div class=\"grid grid-cols-2 align-items-center\">\n <div class=\"\">\n <p class=\"mb-0\" style=\"font-size: 1rem;\">\n Turo Booking\n </p>\n <small class=\"text-gray-700\">\n If we get a Turo booking notification\n </small>\n </div>\n <div class=\"col-auto\">\n <div class=\"notification-checkbox-group\">\n <v-checkbox\n v-model=\"notificationSettings.turo_booking_sms\"\n :disabled=\"settingsLoading.notifications\"\n class=\"mr-2\"\n />\n <v-checkbox\n v-model=\"notificationSettings.turo_booking_email\"\n :disabled=\"settingsLoading.notifications\"\n />\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n </v-card-text>\n </v-card>\n </div>\n</template>\n\n<script lang=\"ts\" setup>\nimport {computed, onBeforeMount, ref, watch} from 'vue';\nimport {useCompany} from '@/composables/useCompany';\nimport {useStore} from 'vuex';\n\nconst {company} = useCompany();\n\nconst store = useStore();\n\nconst settings = ref({\n turo: {},\n fw: {},\n});\n\nconst employeeNotificationSettings = ref([]);\n\nconst updateNotificationSettings = () => {\n store.dispatch('settings/updateNotificationSettings', settings.value);\n};\n\nconst updateEmployeeNotificationSettings = (employee) => {\n store.dispatch('company/updateEmployeeNotificationSettings', employee);\n};\n\nconst companyEmployees = computed(() => store.getters['company/employees']);\nconst settingsLoading = computed(() => store.getters['settings/loading']);\nconst notificationSettings = computed(() => store.getters['settings/notifications']);\n\n\nconst getEmployees = () => {\n return store.dispatch('company/getEmployees');\n};\n\nonBeforeMount(() => {\n getEmployees().then(() => {\n employeeNotificationSettings.value = companyEmployees.value.map((e) => ({\n type: 'employee',\n uuid: e.uuid,\n name: e.name,\n phone: e.phone,\n email: e.email,\n notify_sms: e.phone ? e?.notificationSettings?.notify_sms : false,\n notify_email: e.email ? e?.notificationSettings?.notify_email : false,\n }));\n });\n});\n\nwatch(notificationSettings, (notification, notificationOld) => {\n if (notificationOld.set) {\n updateNotificationSettings();\n }\n}, {deep: true});\n</script>\n\n<style lang=\"scss\">\n.v-list-item__action--stack {\n flex-direction: row !important;\n}\n\n.v-list-item__action .v-input--checkbox:first-child {\n margin-right: 25px !important;\n}\n\n.notification-checkbox-group {\n display: -ms-inline-flexbox;\n display: inline-flex;\n min-width: 24px;\n -webkit-box-orient: horizontal !important;\n -ms-flex-direction: row !important;\n flex-direction: row !important;\n -webkit-box-align: end;\n -ms-flex-align: end;\n align-items: flex-end;\n align-self: stretch;\n -webkit-box-pack: justify;\n -ms-flex-pack: justify;\n justify-content: space-between;\n white-space: nowrap;\n -webkit-box-direction: normal;\n}\n\n.list-title {\n font-size: 1rem;\n}\n\n</style>\n","<template>\n <div class=\"p-4\">\n <div class=\"grid grid-cols-1 md:grid-cols-3 gap-6\">\n <div>\n <div class=\"setting-section-description\">\n <h3 class=\"text-lg font-medium text-gray-900 dark:text-gray-100\">Email Templates</h3>\n\n <div class=\"feature-description\">\n Create and customize Email templates to type less and send faster.\n <TheHelpLink url=\"https://help.fleetwire.io/en/article/create-your-own-email-templates-in-fleetwire-1apedin/?bust=1649702346456\"></TheHelpLink>\n </div>\n </div>\n </div>\n\n <div class=\"col-span-1 md:col-span-2 space-y-6\">\n <v-card>\n <v-card-title class=\"text-base sm:text-lg\">Automatic Emails</v-card-title>\n <v-card-subtitle class=\"text-sm\">These emails are sent automatically, their contents can't be changed before\n sending.\n </v-card-subtitle>\n <v-card-text>\n <div class=\"rounded-lg overflow-hidden border border-gray-200 dark:border-gray-700\">\n <div class=\"p-3 bg-gray-50 dark:bg-gray-800 border-b border-gray-200 dark:border-gray-700 font-semibold\">\n Template\n </div>\n\n <div v-for=\"item in automaticEmailTemplates\" :key=\"item.uuid\" class=\"template-item py-5\">\n <router-link\n :to=\"{ name: 'settings.account.email.email_template_single', params: {uuid: item.uuid} }\"\n class=\"block p-3 hover:bg-gray-50 dark:hover:bg-gray-800 text-blue-500\">\n <span class=\"font-semibold\">{{ item.name }}</span>\n </router-link>\n </div>\n </div>\n </v-card-text>\n </v-card>\n\n <v-card>\n <v-card-title class=\"text-base sm:text-lg\">Manual Emails</v-card-title>\n <v-card-subtitle class=\"text-sm\">These emails are available when viewing orders, customers, or documents. You\n can edit their\n contents before sending.\n </v-card-subtitle>\n <v-card-text>\n <div class=\"rounded-lg overflow-hidden border border-gray-200 dark:border-gray-700\">\n <div class=\"p-3 bg-gray-50 dark:bg-gray-800 border-b border-gray-200 dark:border-gray-700 font-semibold\">\n Template\n </div>\n\n <div v-for=\"item in manualEmailTemplates\" :key=\"item.uuid\" class=\"template-item py-5\">\n <router-link\n :to=\"{ name: 'settings.account.email.email_template_single', params: {uuid: item.uuid} }\"\n class=\"block p-3 hover:bg-gray-50 dark:hover:bg-gray-800 text-blue-500\">\n <span class=\"font-semibold\">{{ item.name }}</span>\n </router-link>\n </div>\n </div>\n </v-card-text>\n <v-card-actions class=\"p-4\">\n <v-btn disabled size=\"small\" variant=\"outlined\">New Email Template</v-btn>\n <span class=\"text-sm text-gray-500 ml-2\">Coming soon</span>\n </v-card-actions>\n </v-card>\n </div>\n </div>\n </div>\n</template>\n\n<script lang=\"ts\" setup>\nimport {computed, onMounted} from 'vue';\nimport {useStore} from 'vuex';\n\nconst store = useStore();\nconst emailTemplates = computed(() => store.getters['email/emailTemplates']);\nconst automaticEmailTemplates = computed(() => emailTemplates.value.filter((t) => t.is_automatic));\nconst manualEmailTemplates = computed(() => emailTemplates.value.filter((t) => !t.is_automatic));\n\nconst getEmailTemplates = () => store.dispatch('email/getEmailTemplates');\n\nonMounted(() => {\n getEmailTemplates();\n});\n</script>\n\n<style scoped>\n.template-item:not(:last-child) {\n border-bottom: 1px solid rgb(214, 217, 219);\n}\n\n@media (max-width: 640px) {\n .v-card-title {\n font-size: 1.125rem;\n line-height: 1.75rem;\n }\n\n .v-card-subtitle {\n font-size: 0.875rem;\n line-height: 1.25rem;\n }\n}\n</style>","import {useStore} from 'vuex';\nimport {computed} from 'vue';\nimport {EmailDomainSettings} from '@/store/modules/email-domain-settings';\n\nexport function useEmailDomainSettings() {\n const store = useStore();\n\n const emailDomainSettingsLoading = computed(() => store.getters['emailDomainSettings/loading']);\n const emailDomainSettings = computed(() => store.getters['emailDomainSettings/emailDomainSettings']);\n\n\n const fetchEmailDomain = async () => {\n return await store.dispatch('emailDomainSettings/fetchEmailDomain');\n }\n\n const createEmailDomain = async (payload: any) => {\n return await store.dispatch('emailDomainSettings/createEmailDomain', payload);\n }\n\n const deleteEmailDomain = async (domainId: EmailDomainSettings) => {\n return await store.dispatch('emailDomainSettings/deleteEmailDomain', domainId);\n }\n\n const emailDomainCheckDKIM = async (domainId: EmailDomainSettings) => {\n return await store.dispatch('emailDomainSettings/emailDomainCheckDKIM', domainId);\n }\n\n const emailDomainCheckReturnPathStatus = async (domainId: EmailDomainSettings) => {\n return await store.dispatch('emailDomainSettings/emailDomainCheckReturnPathStatus', domainId);\n }\n\n const setAsDefaultSendingDomain = async (domainId: EmailDomainSettings) => {\n return await store.dispatch('emailDomainSettings/setAsDefaultSendingDomain', domainId);\n }\n\n const sendTestEmail = async (payload: string) => {\n return await store.dispatch('emailDomainSettings/sendTestEmail', payload);\n }\n\n const updateEmailDomainUsername = async (payload: EmailDomainSettings) => {\n return await store.dispatch('emailDomainSettings/updateEmailDomainUsername', payload);\n }\n\n return {\n emailDomainSettingsLoading,\n emailDomainSettings,\n fetchEmailDomain,\n createEmailDomain,\n deleteEmailDomain,\n emailDomainCheckDKIM,\n emailDomainCheckReturnPathStatus,\n setAsDefaultSendingDomain,\n sendTestEmail,\n updateEmailDomainUsername\n }\n}","<template>\n <div>\n <v-card class=\"mb-5\" variant=\"flat\">\n <v-card-title>\n <div class=\"flex\">\n Customer Emails\n <v-spacer/>\n <v-btn size=\"small\" @click=\"domainDialog = true; createEmailDomainErrorMessage = '';\">\n <v-icon class=\"mr-1\" size=\"small\">mdi-plus</v-icon>\n Add domain\n </v-btn>\n </div>\n </v-card-title>\n <v-card-subtitle>\n Customize the domain used when sending emails to customers.\n <TheHelpLink url=\"https://help.fleetwire.io/en/article/custom-email-domain-19fqufb/?bust=1649702303369\"></TheHelpLink>\n </v-card-subtitle>\n <v-card-text>\n <div class=\"table-responsive-sm\">\n <table class=\"w-full text-sm text-left text-gray-500 dark:text-gray-400\">\n <thead class=\"text-xs text-gray-700 uppercase bg-gray-50 dark:bg-gray-700 dark:text-gray-400\">\n <tr>\n <th class=\"px-6 py-3\" scope=\"col\">Domain</th>\n <th class=\"px-6 py-3\" scope=\"col\">Email</th>\n <th class=\"px-6 py-3\" scope=\"col\">DKIM Verified</th>\n <th class=\"px-6 py-3\" scope=\"col\">SPF Verified</th>\n <th class=\"px-6 py-3\" scope=\"col\"></th>\n <th class=\"px-6 py-3\" scope=\"col\">\n <span class=\"sr-only\">Actions</span>\n </th>\n </tr>\n </thead>\n <tbody>\n <tr v-for=\"item in domains\" :key=\"item.name\" class=\"bg-white border-b dark:bg-gray-800 dark:border-gray-700 hover:bg-gray-50 dark:hover:bg-gray-600\">\n <th class=\"px-6 py-4 font-medium text-gray-900 whitespace-nowrap dark:text-white\" scope=\"row\">\n {{ item.domain }}\n <div v-if=\"showSending(item)\" class=\"items-center text-blue-100 leading-none lg:rounded-full flex lg:inline-flex\" role=\"alert\">\n <span class=\"flex rounded-full bg-blue-500 uppercase px-2 py-1 text-xs font-bold\">Sending</span>\n </div>\n </th>\n <td class=\"px-6 py-4\" style=\"cursor: text;\">\n <span v-if=\"item.email === 'no-reply@fleetwire.io'\">{{ item.email }}</span>\n <span v-else-if=\"!editEmail || editEmail !== item\" @click=\"editEmail = item\"><v-icon size=\"small\">mdi-pencil-outline</v-icon> {{\n item.email\n }}</span>\n <v-text-field\n v-if=\"editEmail && editEmail.uuid === item.uuid && item.email !== 'no-reply@fleetwire.io'\"\n v-model=\"username\"\n :append-icon=\"'mdi-content-save'\"\n autofocus\n class=\"m-0\"\n density=\"compact\"\n label=\"Username\"\n variant=\"outlined\"\n @blur=\"editEmail = false\"\n @click:append=\"updateEmailAddress(item)\"\n @keyup.enter=\"updateEmailAddress(item); $event.target.blur()\"\n ></v-text-field>\n </td>\n <td class=\"px-6 py-4\">\n <div v-if=\"item.DKIMVerified\">\n <div class=\"items-center text-green-100 leading-none lg:rounded-full flex lg:inline-flex\" role=\"alert\">\n <span class=\"flex rounded-full bg-green-500 uppercase px-2 py-1 text-xs font-bold\">Yes</span>\n </div>\n </div>\n <div v-else>\n <div class=\"items-center text-indigo-100 leading-none lg:rounded-full flex lg:inline-flex\" role=\"alert\" @click=\"emailDomainCheckDKIM(item)\">\n <span class=\"flex rounded-full bg-red-500 uppercase px-2 py-1 text-xs font-bold mr-3\">No</span>\n <svg class=\"fill-current opacity-75 h-4 w-4\" viewBox=\"0 0 20 20\" xmlns=\"http://www.w3.org/2000/svg\">\n <path d=\"M12.95 10.707l.707-.707L8 4.343 6.586 5.757 10.828 10l-4.242 4.243L8 15.657l4.95-4.95z\"/>\n </svg>\n </div>\n </div>\n </td>\n <td class=\"px-6 py-4\">\n <div v-if=\"item.SPFVerified\">\n <div class=\"items-center text-green-100 leading-none lg:rounded-full flex lg:inline-flex\" role=\"alert\">\n <span class=\"flex rounded-full bg-green-500 uppercase px-2 py-1 text-xs font-bold\">Yes</span>\n </div>\n </div>\n <div v-else>\n <div class=\"items-center text-indigo-100 leading-none lg:rounded-full flex lg:inline-flex\" role=\"alert\">\n <span class=\"flex rounded-full bg-red-500 uppercase px-2 py-1 text-xs font-bold mr-3\">No</span>\n <svg class=\"fill-current opacity-75 h-4 w-4\" viewBox=\"0 0 20 20\" xmlns=\"http://www.w3.org/2000/svg\">\n <path d=\"M12.95 10.707l.707-.707L8 4.343 6.586 5.757 10.828 10l-4.242 4.243L8 15.657l4.95-4.95z\"/>\n </svg>\n </div>\n </div>\n </td>\n <td class=\"px-6 py-4\">\n <v-btn v-if=\"showSetAsDefault(item)\" class=\"mr-3\" size=\"x-small\" @click=\"setAsDefaultSendingDomain(item)\">\n Set as sending domain\n </v-btn>\n </td>\n <td class=\"table-action px-6 py-4 text-right\">\n <v-menu location=\"bottom\">\n <template v-slot:activator=\"{ props }\">\n <v-icon color=\"grey\" v-bind=\"props\">mdi-dots-vertical</v-icon>\n </template>\n <v-list>\n <v-list-item :disabled=\"!item.active && item.domain !== 'fleetwire.io'\" @click=\"sendTestEmailInit()\">\n <v-list-item-title>Send Test Email</v-list-item-title>\n </v-list-item>\n <v-list-item v-if=\"item.domain !== 'fleetwire.io'\" @click=\"domainSettingsInit(item)\">\n <v-list-item-title>View Domain Settings</v-list-item-title>\n </v-list-item>\n <v-list-item v-if=\"item.domain !== 'fleetwire.io'\" :disabled=\"item.active\" @click=\"domainSettingsRemoveInit(item)\">\n <v-list-item-title>Delete</v-list-item-title>\n </v-list-item>\n <v-divider v-if=\"item.domain !== 'fleetwire.io'\"/>\n\n <v-list-item v-if=\"item.domain !== 'fleetwire.io' && !item.ReturnPathDomainVerified\" @click=\"emailDomainCheckReturnPathStatus(item)\">\n <v-list-item-title>Check Return Path Status</v-list-item-title>\n </v-list-item>\n <v-list-item v-if=\"item.domain !== 'fleetwire.io' && !item.DKIMVerified\" @click=\"emailDomainCheckDKIM(item)\">\n <v-list-item-title>Check DKIM Status</v-list-item-title>\n </v-list-item>\n </v-list>\n </v-menu>\n </td>\n </tr>\n </tbody>\n </table>\n </div>\n </v-card-text>\n </v-card>\n <v-divider/>\n\n <EmailTemplates/>\n <v-divider/>\n\n <v-dialog v-model=\"domainDialog\" width=\"400\">\n <v-card>\n <v-card-title>Add your email domain</v-card-title>\n <v-divider opacity=\"50\"/>\n <v-card-text class=\"\">\n <v-text-field\n v-model=\"newDomain\"\n :error=\"createEmailDomainErrorMessage.length > 0\"\n label=\"Email Domain\"\n placeholder=\"example.com or subdomain.example.com\"\n variant=\"outlined\"\n @keyup.enter=\"createEmailDomain(newDomain); $event.target.blur()\"\n ></v-text-field>\n\n <div v-show=\"createEmailDomainErrorMessage\" class=\"bg-red-100 border border-eed-400 text-red-700 px-4 py-3 rounded relative\" role=\"alert\">\n <strong class=\"font-bold mr-2\">Error!</strong>\n <span class=\"block sm:inline\">{{ createEmailDomainErrorMessage }}</span>\n <span class=\"absolute top-0 bottom-0 right-0 px-4 py-3\" @click=\"createEmailDomainErrorMessage = ''\">\n <svg class=\"fill-current h-6 w-6 text-red-500\" viewBox=\"0 0 20 20\" xmlns=\"http://www.w3.org/2000/svg\"><title>Close</title><path d=\"M14.348 14.849a1.2 1.2 0 0 1-1.697 0L10 11.819l-2.651 3.029a1.2 1.2 0 1 1-1.697-1.697l2.758-3.15-2.759-3.152a1.2 1.2 0 1 1 1.697-1.697L10 8.183l2.651-3.031a1.2 1.2 0 1 1 1.697 1.697l-2.758 3.152 2.758 3.15a1.2 1.2 0 0 1 0 1.698z\"/></svg>\n </span>\n </div>\n </v-card-text>\n <v-divider opacity=\"50\"/>\n <v-card-actions>\n <v-spacer/>\n <v-btn :disabled=\"newDomain.length < 4\" :loading=\"emailDomainSettingsLoading.creatingEmailDomain\" color=\"primary\" @click=\"createEmailDomain(newDomain); createEmailDomainErrorMessage = ''\">\n Add domain\n </v-btn>\n </v-card-actions>\n </v-card>\n </v-dialog>\n\n <v-dialog v-model=\"testEmailDialog\" width=\"400\">\n <v-card>\n <v-card-title>\n Send Test email from {{ activeDomain }}\n </v-card-title>\n <v-divider opacity=\"50\"/>\n <v-card-text>\n <v-text-field\n v-model=\"testEmailAddress\"\n label=\"email\"\n name=\"email\"\n variant=\"outlined\"\n ></v-text-field>\n </v-card-text>\n <v-divider opacity=\"50\"/>\n <v-card-actions>\n <v-spacer/>\n <v-btn :disabled=\"testEmailAddress.length < 4\" :loading=\"emailDomainSettingsLoading.sendingTestEmail\" color=\"primary\" @click=\"sendTestEmail(testEmailAddress)\">\n Send Test Email\n </v-btn>\n </v-card-actions>\n </v-card>\n </v-dialog>\n\n <v-dialog v-model=\"domainSettingsDialog\" width=\"550\">\n <v-card>\n <v-card-title>DNS Records</v-card-title>\n\n <v-card-subtitle>\n Here are the 3 records you should add to your DNS settings.\n <TheHelpLink url=\"https://help.fleetwire.io/en/article/custom-email-domain-19fqufb/?bust=1658353515728\"/>\n </v-card-subtitle>\n <v-card-text class=\"mt-4\">\n <v-expansion-panels multiple>\n <v-expansion-panel>\n <v-expansion-panel-title>\n <template v-slot:default=\"{ expanded }\">\n <div class=\"\">\n <div class=\"col-4\"><span>DKIM</span></div>\n <div class=\"col-8 text--secondary\">\n <v-fade-transition leave-absolute>\n <span v-if=\"expanded\">Type: TXT</span>\n <div v-else class=\"\" style=\"width: 100%\">\n <div class=\"col-6\">\n <span v-if=\"currentWorkingSetting.DKIMUpdateStatus === 'Verified'\" class=\"text-sm text-green-600 flex items-center float-right\">\n <svg enable-background=\"new 0 0 24 24\" height=\"15\" viewBox=\"0 0 24 24\" width=\"15\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"m17.5 24c-3.584 0-6.5-2.916-6.5-6.5s2.916-6.5 6.5-6.5 6.5 2.916 6.5 6.5-2.916 6.5-6.5 6.5zm0-11.5c-2.757 0-5 2.243-5 5s2.243 5 5 5 5-2.243 5-5-2.243-5-5-5z\"/><path d=\"m16.5 20c-.198 0-.39-.079-.53-.22l-2-2c-.293-.293-.293-.768 0-1.061s.768-.293 1.061 0l1.434 1.433 2.972-3.396c.274-.313.747-.343 1.059-.071.312.273.343.747.07 1.058l-3.5 4c-.138.157-.334.25-.541.257-.008 0-.017 0-.025 0z\"/><path d=\"m8.5 21c-.048 0-.096-.004-.143-.014-.084-.016-8.357-1.725-8.357-11.056v-6.18c0-.31.19-.587.479-.699l7.75-3c.174-.067.367-.067.541 0l7.75 3c.29.112.48.389.48.699v4.5c0 .414-.336.75-.75.75s-.75-.336-.75-.75v-3.986l-7-2.709-7 2.709v5.666c0 7.594 6.01 9.32 7.012 9.555h.002c.406-.086.801.182.882.589.081.406-.183.801-.589.882l-.186.034c-.04.007-.08.01-.121.01z\"/></svg>\n <span>Verified</span>\n </span>\n <span v-else class=\"text-sm text-yellow-600 flex items-center float-right\">\n <svg id=\"Capa_1\" enable-background=\"new 0 0 512 512\" height=\"15\" viewBox=\"0 0 512 512\" width=\"15\" xmlns=\"http://www.w3.org/2000/svg\"><g><path d=\"m392.274 204.411c-37.588 0-71.18 17.417-93.146 44.599l-30.294-29.083 129.032-123.87c1.875 3.468 2.941 7.434 2.941 11.645v72.145c0 4.142 3.358 7.5 7.5 7.5s7.5-3.358 7.5-7.5v-72.145c0-21.816-17.749-39.564-39.565-39.564h-336.678c-21.815-.001-39.564 17.748-39.564 39.564v224.452c0 21.816 17.749 39.564 39.564 39.564h216.436c4.142 0 7.5-3.358 7.5-7.5s-3.358-7.5-7.5-7.5h-216.436c-3.876 0-7.543-.906-10.806-2.511l129.275-124.104c14.57 11.748 32.216 17.637 49.87 17.637s35.3-5.889 49.87-17.637l32.583 31.28c-11.284 18.26-17.808 39.759-17.808 62.755 0 66.017 53.709 119.726 119.726 119.726s119.726-53.71 119.726-119.727-53.708-119.726-119.726-119.726zm-229.14 10.238-16.006-15.366c-2.988-2.869-7.736-2.772-10.604.216s-2.771 7.736.217 10.604l10.232 9.823-129.032 123.872c-1.875-3.468-2.941-7.434-2.941-11.645v-224.451c0-4.211 1.066-8.177 2.941-11.645l93.952 90.194c1.454 1.396 3.325 2.09 5.193 2.09 1.971 0 3.939-.772 5.412-2.306 2.868-2.988 2.771-7.736-.217-10.604l-93.523-89.783c3.263-1.605 6.93-2.511 10.806-2.511h336.677c3.876 0 7.543.906 10.807 2.511l-134.376 129.001c-25.104 24.101-64.433 24.101-89.538 0zm229.14 214.214c-57.746 0-104.726-46.98-104.726-104.726s46.98-104.726 104.726-104.726 104.726 46.98 104.726 104.726-46.979 104.726-104.726 104.726z\"/><path d=\"m462.148 271.195c-2.503-3.3-7.208-3.945-10.508-1.441s-3.945 7.208-1.441 10.508c8.12 10.701 13.001 23.155 14.343 36.375h-69.162l-48.879-48.879c12.504-10.171 28.435-16.282 45.772-16.282 11.712 0 22.889 2.698 33.221 8.02 3.684 1.897 8.206.449 10.102-3.233 1.897-3.682.449-8.205-3.233-10.102-12.301-6.336-26.164-9.685-40.09-9.685-48.337 0-87.662 39.325-87.662 87.661s39.325 87.661 87.662 87.661c48.336 0 87.661-39.325 87.661-87.661.002-19.299-6.149-37.606-17.786-52.942zm-69.874 125.603c-40.066 0-72.662-32.596-72.662-72.661 0-17.337 6.112-33.269 16.283-45.772l51.076 51.076c1.406 1.406 3.314 2.197 5.303 2.197h72.275c-3.765 36.554-34.741 65.16-72.275 65.16z\"/></g></svg>\n <span class=\"ml-3\">Pending</span>\n </span>\n </div>\n </div>\n </v-fade-transition>\n </div>\n </div>\n </template>\n </v-expansion-panel-title>\n <v-expansion-panel-text>\n <div>\n <div>\n <v-text-field\n id=\"DKIMName\"\n :model-value=\"dkimName\"\n append-icon=\"mdi-content-copy\"\n density=\"compact\"\n label=\"Name\"\n readonly\n variant=\"outlined\"\n @click:append=\"copyToClipboardInit(dkimName)\"\n ></v-text-field>\n <v-text-field\n id=\"DKIMValue\"\n :model-value=\"dkimValue\"\n append-icon=\"mdi-content-copy\"\n density=\"compact\"\n label=\"Value\"\n readonly\n variant=\"outlined\"\n @click:append=\"copyToClipboardInit(dkimValue)\"\n ></v-text-field>\n <span v-if=\"currentWorkingSetting.DKIMUpdateStatus === 'Verified'\" class=\"text-sm text-green-600 flex items-center float-right\">\n <svg enable-background=\"new 0 0 24 24\" height=\"15\" viewBox=\"0 0 24 24\" width=\"15\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"m17.5 24c-3.584 0-6.5-2.916-6.5-6.5s2.916-6.5 6.5-6.5 6.5 2.916 6.5 6.5-2.916 6.5-6.5 6.5zm0-11.5c-2.757 0-5 2.243-5 5s2.243 5 5 5 5-2.243 5-5-2.243-5-5-5z\"/><path d=\"m16.5 20c-.198 0-.39-.079-.53-.22l-2-2c-.293-.293-.293-.768 0-1.061s.768-.293 1.061 0l1.434 1.433 2.972-3.396c.274-.313.747-.343 1.059-.071.312.273.343.747.07 1.058l-3.5 4c-.138.157-.334.25-.541.257-.008 0-.017 0-.025 0z\"/><path d=\"m8.5 21c-.048 0-.096-.004-.143-.014-.084-.016-8.357-1.725-8.357-11.056v-6.18c0-.31.19-.587.479-.699l7.75-3c.174-.067.367-.067.541 0l7.75 3c.29.112.48.389.48.699v4.5c0 .414-.336.75-.75.75s-.75-.336-.75-.75v-3.986l-7-2.709-7 2.709v5.666c0 7.594 6.01 9.32 7.012 9.555h.002c.406-.086.801.182.882.589.081.406-.183.801-.589.882l-.186.034c-.04.007-.08.01-.121.01z\"/></svg>\n Verified\n </span>\n <span v-else class=\"text-sm text-yellow-600 flex items-center float-right\">\n <svg id=\"Capa_1\" enable-background=\"new 0 0 512 512\" height=\"15\" viewBox=\"0 0 512 512\" width=\"15\" xmlns=\"http://www.w3.org/2000/svg\"><g><path d=\"m392.274 204.411c-37.588 0-71.18 17.417-93.146 44.599l-30.294-29.083 129.032-123.87c1.875 3.468 2.941 7.434 2.941 11.645v72.145c0 4.142 3.358 7.5 7.5 7.5s7.5-3.358 7.5-7.5v-72.145c0-21.816-17.749-39.564-39.565-39.564h-336.678c-21.815-.001-39.564 17.748-39.564 39.564v224.452c0 21.816 17.749 39.564 39.564 39.564h216.436c4.142 0 7.5-3.358 7.5-7.5s-3.358-7.5-7.5-7.5h-216.436c-3.876 0-7.543-.906-10.806-2.511l129.275-124.104c14.57 11.748 32.216 17.637 49.87 17.637s35.3-5.889 49.87-17.637l32.583 31.28c-11.284 18.26-17.808 39.759-17.808 62.755 0 66.017 53.709 119.726 119.726 119.726s119.726-53.71 119.726-119.727-53.708-119.726-119.726-119.726zm-229.14 10.238-16.006-15.366c-2.988-2.869-7.736-2.772-10.604.216s-2.771 7.736.217 10.604l10.232 9.823-129.032 123.872c-1.875-3.468-2.941-7.434-2.941-11.645v-224.451c0-4.211 1.066-8.177 2.941-11.645l93.952 90.194c1.454 1.396 3.325 2.09 5.193 2.09 1.971 0 3.939-.772 5.412-2.306 2.868-2.988 2.771-7.736-.217-10.604l-93.523-89.783c3.263-1.605 6.93-2.511 10.806-2.511h336.677c3.876 0 7.543.906 10.807 2.511l-134.376 129.001c-25.104 24.101-64.433 24.101-89.538 0zm229.14 214.214c-57.746 0-104.726-46.98-104.726-104.726s46.98-104.726 104.726-104.726 104.726 46.98 104.726 104.726-46.979 104.726-104.726 104.726z\"/><path d=\"m462.148 271.195c-2.503-3.3-7.208-3.945-10.508-1.441s-3.945 7.208-1.441 10.508c8.12 10.701 13.001 23.155 14.343 36.375h-69.162l-48.879-48.879c12.504-10.171 28.435-16.282 45.772-16.282 11.712 0 22.889 2.698 33.221 8.02 3.684 1.897 8.206.449 10.102-3.233 1.897-3.682.449-8.205-3.233-10.102-12.301-6.336-26.164-9.685-40.09-9.685-48.337 0-87.662 39.325-87.662 87.661s39.325 87.661 87.662 87.661c48.336 0 87.661-39.325 87.661-87.661.002-19.299-6.149-37.606-17.786-52.942zm-69.874 125.603c-40.066 0-72.662-32.596-72.662-72.661 0-17.337 6.112-33.269 16.283-45.772l51.076 51.076c1.406 1.406 3.314 2.197 5.303 2.197h72.275c-3.765 36.554-34.741 65.16-72.275 65.16z\"/></g></svg>\n Pending\n </span>\n </div>\n </div>\n </v-expansion-panel-text>\n </v-expansion-panel>\n\n <v-expansion-panel>\n <v-expansion-panel-title>\n <template v-slot:default=\"{ expanded }\">\n <div>\n <div class=\"col-4\"><span>SPF</span></div>\n <div class=\"col-8 text--secondary\">\n <v-fade-transition leave-absolute>\n <span v-if=\"expanded\">Type TXT</span>\n <div v-else style=\"width: 100%\">\n <div class=\"col-6\">\n <span v-if=\"currentWorkingSetting.SPFVerified\" class=\"text-sm text-green-600 flex items-center float-right\">\n <svg enable-background=\"new 0 0 24 24\" height=\"15\" viewBox=\"0 0 24 24\" width=\"15\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"m17.5 24c-3.584 0-6.5-2.916-6.5-6.5s2.916-6.5 6.5-6.5 6.5 2.916 6.5 6.5-2.916 6.5-6.5 6.5zm0-11.5c-2.757 0-5 2.243-5 5s2.243 5 5 5 5-2.243 5-5-2.243-5-5-5z\"/><path d=\"m16.5 20c-.198 0-.39-.079-.53-.22l-2-2c-.293-.293-.293-.768 0-1.061s.768-.293 1.061 0l1.434 1.433 2.972-3.396c.274-.313.747-.343 1.059-.071.312.273.343.747.07 1.058l-3.5 4c-.138.157-.334.25-.541.257-.008 0-.017 0-.025 0z\"/><path d=\"m8.5 21c-.048 0-.096-.004-.143-.014-.084-.016-8.357-1.725-8.357-11.056v-6.18c0-.31.19-.587.479-.699l7.75-3c.174-.067.367-.067.541 0l7.75 3c.29.112.48.389.48.699v4.5c0 .414-.336.75-.75.75s-.75-.336-.75-.75v-3.986l-7-2.709-7 2.709v5.666c0 7.594 6.01 9.32 7.012 9.555h.002c.406-.086.801.182.882.589.081.406-.183.801-.589.882l-.186.034c-.04.007-.08.01-.121.01z\"/></svg>\n <span class=\"ml-3\">Verified</span>\n </span>\n <span v-else class=\"text-sm text-yellow-600 flex items-center float-right\">\n <svg id=\"Capa_1\" enable-background=\"new 0 0 512 512\" height=\"15\" viewBox=\"0 0 512 512\" width=\"15\" xmlns=\"http://www.w3.org/2000/svg\"><g><path d=\"m392.274 204.411c-37.588 0-71.18 17.417-93.146 44.599l-30.294-29.083 129.032-123.87c1.875 3.468 2.941 7.434 2.941 11.645v72.145c0 4.142 3.358 7.5 7.5 7.5s7.5-3.358 7.5-7.5v-72.145c0-21.816-17.749-39.564-39.565-39.564h-336.678c-21.815-.001-39.564 17.748-39.564 39.564v224.452c0 21.816 17.749 39.564 39.564 39.564h216.436c4.142 0 7.5-3.358 7.5-7.5s-3.358-7.5-7.5-7.5h-216.436c-3.876 0-7.543-.906-10.806-2.511l129.275-124.104c14.57 11.748 32.216 17.637 49.87 17.637s35.3-5.889 49.87-17.637l32.583 31.28c-11.284 18.26-17.808 39.759-17.808 62.755 0 66.017 53.709 119.726 119.726 119.726s119.726-53.71 119.726-119.727-53.708-119.726-119.726-119.726zm-229.14 10.238-16.006-15.366c-2.988-2.869-7.736-2.772-10.604.216s-2.771 7.736.217 10.604l10.232 9.823-129.032 123.872c-1.875-3.468-2.941-7.434-2.941-11.645v-224.451c0-4.211 1.066-8.177 2.941-11.645l93.952 90.194c1.454 1.396 3.325 2.09 5.193 2.09 1.971 0 3.939-.772 5.412-2.306 2.868-2.988 2.771-7.736-.217-10.604l-93.523-89.783c3.263-1.605 6.93-2.511 10.806-2.511h336.677c3.876 0 7.543.906 10.807 2.511l-134.376 129.001c-25.104 24.101-64.433 24.101-89.538 0zm229.14 214.214c-57.746 0-104.726-46.98-104.726-104.726s46.98-104.726 104.726-104.726 104.726 46.98 104.726 104.726-46.979 104.726-104.726 104.726z\"/><path d=\"m462.148 271.195c-2.503-3.3-7.208-3.945-10.508-1.441s-3.945 7.208-1.441 10.508c8.12 10.701 13.001 23.155 14.343 36.375h-69.162l-48.879-48.879c12.504-10.171 28.435-16.282 45.772-16.282 11.712 0 22.889 2.698 33.221 8.02 3.684 1.897 8.206.449 10.102-3.233 1.897-3.682.449-8.205-3.233-10.102-12.301-6.336-26.164-9.685-40.09-9.685-48.337 0-87.662 39.325-87.662 87.661s39.325 87.661 87.662 87.661c48.336 0 87.661-39.325 87.661-87.661.002-19.299-6.149-37.606-17.786-52.942zm-69.874 125.603c-40.066 0-72.662-32.596-72.662-72.661 0-17.337 6.112-33.269 16.283-45.772l51.076 51.076c1.406 1.406 3.314 2.197 5.303 2.197h72.275c-3.765 36.554-34.741 65.16-72.275 65.16z\"/></g></svg>\n <span class=\"ml-3\">Pending</span>\n </span>\n </div>\n </div>\n </v-fade-transition>\n </div>\n </div>\n </template>\n </v-expansion-panel-title>\n <v-expansion-panel-text>\n <v-text-field\n id=\"SPFName\"\n v-model=\"currentWorkingSetting.SPFHost\"\n append-icon=\"mdi-content-copy\"\n density=\"compact\"\n label=\"Name\"\n readonly\n variant=\"outlined\"\n @click:append=\"copyToClipboardInit(currentWorkingSetting.SPFHost)\"\n ></v-text-field>\n <v-text-field\n id=\"SPFValue\"\n v-model=\"currentWorkingSetting.SPFTextValue\"\n append-icon=\"mdi-content-copy\"\n density=\"compact\"\n label=\"Value\"\n readonly\n variant=\"outlined\"\n @click:append=\"copyToClipboardInit(currentWorkingSetting.SPFTextValue)\"\n ></v-text-field>\n <span v-if=\"currentWorkingSetting.SPFVerified\" class=\"text-sm text-green-600 flex items-center float-right\">\n <svg enable-background=\"new 0 0 24 24\" height=\"15\" viewBox=\"0 0 24 24\" width=\"15\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"m17.5 24c-3.584 0-6.5-2.916-6.5-6.5s2.916-6.5 6.5-6.5 6.5 2.916 6.5 6.5-2.916 6.5-6.5 6.5zm0-11.5c-2.757 0-5 2.243-5 5s2.243 5 5 5 5-2.243 5-5-2.243-5-5-5z\"/><path d=\"m16.5 20c-.198 0-.39-.079-.53-.22l-2-2c-.293-.293-.293-.768 0-1.061s.768-.293 1.061 0l1.434 1.433 2.972-3.396c.274-.313.747-.343 1.059-.071.312.273.343.747.07 1.058l-3.5 4c-.138.157-.334.25-.541.257-.008 0-.017 0-.025 0z\"/><path d=\"m8.5 21c-.048 0-.096-.004-.143-.014-.084-.016-8.357-1.725-8.357-11.056v-6.18c0-.31.19-.587.479-.699l7.75-3c.174-.067.367-.067.541 0l7.75 3c.29.112.48.389.48.699v4.5c0 .414-.336.75-.75.75s-.75-.336-.75-.75v-3.986l-7-2.709-7 2.709v5.666c0 7.594 6.01 9.32 7.012 9.555h.002c.406-.086.801.182.882.589.081.406-.183.801-.589.882l-.186.034c-.04.007-.08.01-.121.01z\"/></svg>\n <span class=\"ml-3\">Verified</span>\n </span>\n <span v-else class=\"text-sm text-yellow-600 flex items-center float-right\">\n <svg id=\"Capa_1\" enable-background=\"new 0 0 512 512\" height=\"15\" viewBox=\"0 0 512 512\" width=\"15\" xmlns=\"http://www.w3.org/2000/svg\"><g><path d=\"m392.274 204.411c-37.588 0-71.18 17.417-93.146 44.599l-30.294-29.083 129.032-123.87c1.875 3.468 2.941 7.434 2.941 11.645v72.145c0 4.142 3.358 7.5 7.5 7.5s7.5-3.358 7.5-7.5v-72.145c0-21.816-17.749-39.564-39.565-39.564h-336.678c-21.815-.001-39.564 17.748-39.564 39.564v224.452c0 21.816 17.749 39.564 39.564 39.564h216.436c4.142 0 7.5-3.358 7.5-7.5s-3.358-7.5-7.5-7.5h-216.436c-3.876 0-7.543-.906-10.806-2.511l129.275-124.104c14.57 11.748 32.216 17.637 49.87 17.637s35.3-5.889 49.87-17.637l32.583 31.28c-11.284 18.26-17.808 39.759-17.808 62.755 0 66.017 53.709 119.726 119.726 119.726s119.726-53.71 119.726-119.727-53.708-119.726-119.726-119.726zm-229.14 10.238-16.006-15.366c-2.988-2.869-7.736-2.772-10.604.216s-2.771 7.736.217 10.604l10.232 9.823-129.032 123.872c-1.875-3.468-2.941-7.434-2.941-11.645v-224.451c0-4.211 1.066-8.177 2.941-11.645l93.952 90.194c1.454 1.396 3.325 2.09 5.193 2.09 1.971 0 3.939-.772 5.412-2.306 2.868-2.988 2.771-7.736-.217-10.604l-93.523-89.783c3.263-1.605 6.93-2.511 10.806-2.511h336.677c3.876 0 7.543.906 10.807 2.511l-134.376 129.001c-25.104 24.101-64.433 24.101-89.538 0zm229.14 214.214c-57.746 0-104.726-46.98-104.726-104.726s46.98-104.726 104.726-104.726 104.726 46.98 104.726 104.726-46.979 104.726-104.726 104.726z\"/><path d=\"m462.148 271.195c-2.503-3.3-7.208-3.945-10.508-1.441s-3.945 7.208-1.441 10.508c8.12 10.701 13.001 23.155 14.343 36.375h-69.162l-48.879-48.879c12.504-10.171 28.435-16.282 45.772-16.282 11.712 0 22.889 2.698 33.221 8.02 3.684 1.897 8.206.449 10.102-3.233 1.897-3.682.449-8.205-3.233-10.102-12.301-6.336-26.164-9.685-40.09-9.685-48.337 0-87.662 39.325-87.662 87.661s39.325 87.661 87.662 87.661c48.336 0 87.661-39.325 87.661-87.661.002-19.299-6.149-37.606-17.786-52.942zm-69.874 125.603c-40.066 0-72.662-32.596-72.662-72.661 0-17.337 6.112-33.269 16.283-45.772l51.076 51.076c1.406 1.406 3.314 2.197 5.303 2.197h72.275c-3.765 36.554-34.741 65.16-72.275 65.16z\"/></g></svg>\n <span class=\"ml-3\">Pending</span>\n </span>\n </v-expansion-panel-text>\n </v-expansion-panel>\n\n <v-expansion-panel>\n <v-expansion-panel-title>\n <template v-slot:default=\"{ expanded }\">\n <div class=\"\">\n <div class=\"col-4\"><span>Return-Path</span></div>\n <div class=\"col-8 text--secondary\">\n <v-fade-transition leave-absolute>\n <span v-if=\"expanded\">Type: CNAME</span>\n <div v-else class=\"\" style=\"width: 100%\">\n <div class=\"col-6\">\n <span v-if=\"currentWorkingSetting.ReturnPathDomainVerified\" class=\"text-sm text-green-600 flex items-center float-right\">\n <svg enable-background=\"new 0 0 24 24\" height=\"15\" viewBox=\"0 0 24 24\" width=\"15\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"m17.5 24c-3.584 0-6.5-2.916-6.5-6.5s2.916-6.5 6.5-6.5 6.5 2.916 6.5 6.5-2.916 6.5-6.5 6.5zm0-11.5c-2.757 0-5 2.243-5 5s2.243 5 5 5 5-2.243 5-5-2.243-5-5-5z\"/><path d=\"m16.5 20c-.198 0-.39-.079-.53-.22l-2-2c-.293-.293-.293-.768 0-1.061s.768-.293 1.061 0l1.434 1.433 2.972-3.396c.274-.313.747-.343 1.059-.071.312.273.343.747.07 1.058l-3.5 4c-.138.157-.334.25-.541.257-.008 0-.017 0-.025 0z\"/><path d=\"m8.5 21c-.048 0-.096-.004-.143-.014-.084-.016-8.357-1.725-8.357-11.056v-6.18c0-.31.19-.587.479-.699l7.75-3c.174-.067.367-.067.541 0l7.75 3c.29.112.48.389.48.699v4.5c0 .414-.336.75-.75.75s-.75-.336-.75-.75v-3.986l-7-2.709-7 2.709v5.666c0 7.594 6.01 9.32 7.012 9.555h.002c.406-.086.801.182.882.589.081.406-.183.801-.589.882l-.186.034c-.04.007-.08.01-.121.01z\"/></svg>\n <span class=\"ml-3\">Verified</span>\n </span>\n <span v-else class=\"text-sm text-yellow-600 flex items-center float-right\">\n <svg id=\"Capa_1\" enable-background=\"new 0 0 512 512\" height=\"15\" viewBox=\"0 0 512 512\" width=\"15\" xmlns=\"http://www.w3.org/2000/svg\"><g><path d=\"m392.274 204.411c-37.588 0-71.18 17.417-93.146 44.599l-30.294-29.083 129.032-123.87c1.875 3.468 2.941 7.434 2.941 11.645v72.145c0 4.142 3.358 7.5 7.5 7.5s7.5-3.358 7.5-7.5v-72.145c0-21.816-17.749-39.564-39.565-39.564h-336.678c-21.815-.001-39.564 17.748-39.564 39.564v224.452c0 21.816 17.749 39.564 39.564 39.564h216.436c4.142 0 7.5-3.358 7.5-7.5s-3.358-7.5-7.5-7.5h-216.436c-3.876 0-7.543-.906-10.806-2.511l129.275-124.104c14.57 11.748 32.216 17.637 49.87 17.637s35.3-5.889 49.87-17.637l32.583 31.28c-11.284 18.26-17.808 39.759-17.808 62.755 0 66.017 53.709 119.726 119.726 119.726s119.726-53.71 119.726-119.727-53.708-119.726-119.726-119.726zm-229.14 10.238-16.006-15.366c-2.988-2.869-7.736-2.772-10.604.216s-2.771 7.736.217 10.604l10.232 9.823-129.032 123.872c-1.875-3.468-2.941-7.434-2.941-11.645v-224.451c0-4.211 1.066-8.177 2.941-11.645l93.952 90.194c1.454 1.396 3.325 2.09 5.193 2.09 1.971 0 3.939-.772 5.412-2.306 2.868-2.988 2.771-7.736-.217-10.604l-93.523-89.783c3.263-1.605 6.93-2.511 10.806-2.511h336.677c3.876 0 7.543.906 10.807 2.511l-134.376 129.001c-25.104 24.101-64.433 24.101-89.538 0zm229.14 214.214c-57.746 0-104.726-46.98-104.726-104.726s46.98-104.726 104.726-104.726 104.726 46.98 104.726 104.726-46.979 104.726-104.726 104.726z\"/><path d=\"m462.148 271.195c-2.503-3.3-7.208-3.945-10.508-1.441s-3.945 7.208-1.441 10.508c8.12 10.701 13.001 23.155 14.343 36.375h-69.162l-48.879-48.879c12.504-10.171 28.435-16.282 45.772-16.282 11.712 0 22.889 2.698 33.221 8.02 3.684 1.897 8.206.449 10.102-3.233 1.897-3.682.449-8.205-3.233-10.102-12.301-6.336-26.164-9.685-40.09-9.685-48.337 0-87.662 39.325-87.662 87.661s39.325 87.661 87.662 87.661c48.336 0 87.661-39.325 87.661-87.661.002-19.299-6.149-37.606-17.786-52.942zm-69.874 125.603c-40.066 0-72.662-32.596-72.662-72.661 0-17.337 6.112-33.269 16.283-45.772l51.076 51.076c1.406 1.406 3.314 2.197 5.303 2.197h72.275c-3.765 36.554-34.741 65.16-72.275 65.16z\"/></g></svg>\n <span class=\"ml-3\">Pending</span>\n </span>\n </div>\n </div>\n </v-fade-transition>\n </div>\n </div>\n </template>\n </v-expansion-panel-title>\n <v-expansion-panel-text>\n <v-text-field\n id=\"CNAMEName\"\n v-model=\"currentWorkingSetting.ReturnPathDomain\"\n append-icon=\"mdi-content-copy\"\n density=\"compact\"\n label=\"Name\"\n readonly\n variant=\"outlined\"\n @click:append=\"copyToClipboardInit(currentWorkingSetting.ReturnPathDomain)\"\n ></v-text-field>\n <v-text-field\n id=\"CNAMEValue\"\n v-model=\"currentWorkingSetting.ReturnPathDomainCNAMEValue\"\n append-icon=\"mdi-content-copy\"\n density=\"compact\"\n label=\"Value\"\n readonly\n variant=\"outlined\"\n @click:append=\"copyToClipboardInit(currentWorkingSetting.ReturnPathDomainCNAMEValue)\"\n ></v-text-field>\n <div>\n <span v-if=\"currentWorkingSetting.ReturnPathDomainVerified\" class=\"text-sm text-green-600 flex items-center float-right\">\n <svg enable-background=\"new 0 0 24 24\" height=\"15\" viewBox=\"0 0 24 24\" width=\"15\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"m17.5 24c-3.584 0-6.5-2.916-6.5-6.5s2.916-6.5 6.5-6.5 6.5 2.916 6.5 6.5-2.916 6.5-6.5 6.5zm0-11.5c-2.757 0-5 2.243-5 5s2.243 5 5 5 5-2.243 5-5-2.243-5-5-5z\"/><path d=\"m16.5 20c-.198 0-.39-.079-.53-.22l-2-2c-.293-.293-.293-.768 0-1.061s.768-.293 1.061 0l1.434 1.433 2.972-3.396c.274-.313.747-.343 1.059-.071.312.273.343.747.07 1.058l-3.5 4c-.138.157-.334.25-.541.257-.008 0-.017 0-.025 0z\"/><path d=\"m8.5 21c-.048 0-.096-.004-.143-.014-.084-.016-8.357-1.725-8.357-11.056v-6.18c0-.31.19-.587.479-.699l7.75-3c.174-.067.367-.067.541 0l7.75 3c.29.112.48.389.48.699v4.5c0 .414-.336.75-.75.75s-.75-.336-.75-.75v-3.986l-7-2.709-7 2.709v5.666c0 7.594 6.01 9.32 7.012 9.555h.002c.406-.086.801.182.882.589.081.406-.183.801-.589.882l-.186.034c-.04.007-.08.01-.121.01z\"/></svg>\n Verified\n </span>\n <div v-else>\n <div class=\"bg-yellow-100 border border-yellow-400 text-yellow-700 px-4 py-3 rounded relative\" role=\"alert\">\n <strong class=\"font-bold mr-2\">Pending...</strong>\n <span class=\"block sm:inline\">We couldn’t find your Return-Path record. Go back to your DNS provider and double check that the hostname is set to pm-bounces. If the hostname and value look good, then it might take up to 48 hours for the DNS changes to propagate.</span><br>\n <v-btn :loading=\"emailDomainSettingsLoading.checkingReturnPathStatus\" class=\"mt-2\" @click=\"emailDomainCheckReturnPathStatus(currentWorkingSetting)\">\n Re-check\n </v-btn>\n </div>\n </div>\n </div>\n </v-expansion-panel-text>\n </v-expansion-panel>\n </v-expansion-panels>\n </v-card-text>\n </v-card>\n </v-dialog>\n\n <v-dialog v-model=\"domainSettingsDeleteConfirmDialog\" max-width=\"290\">\n <v-card :disabled=\"emailDomainSettingsLoading.deletingEmailDomain\">\n <v-card-title class=\"text-h5\">Remove Domain</v-card-title>\n <v-card-text>\n Are you sure you want to remove this domain?\n </v-card-text>\n <v-card-actions>\n <v-spacer/>\n <v-btn color=\"grey-darken-1\" size=\"small\" variant=\"text\" @click=\"domainSettingsDeleteConfirmDialog = false\">\n Nevermind\n </v-btn>\n <v-btn :loading=\"emailDomainSettingsLoading.deletingEmailDomain\" color=\"red text-white\" @click=\"deleteEmailDomain(currentWorkingSetting)\">\n Delete\n </v-btn>\n </v-card-actions>\n </v-card>\n </v-dialog>\n\n <v-snackbar\n v-model=\"copiedText\"\n class=\"elevation-24\"\n color=\"accent-4\"\n location=\"bottom\"\n width=\"100\"\n >\n Copied!\n </v-snackbar>\n </div>\n</template>\n\n<script lang=\"ts\">\nimport {ref, watch} from 'vue';\nimport {EventBus} from '@/plugins/eventBus';\nimport {clone, filter, get, split, toLower} from 'lodash';\nimport {copyTextToClipboard} from '@/helpers';\nimport EmailTemplates from '@/components/dashboard/settings/Emails/EmailTemplates.vue';\nimport {useEmailDomainSettings} from '@/composables/useEmailDomainSettings';\nimport {EmailDomainSettings} from '@/store/modules/email-domain-settings';\n\n\nexport default {\n name: 'SettingsEmail',\n\n components: {\n EmailTemplates,\n },\n\n setup() {\n const {\n emailDomainSettingsLoading,\n emailDomainSettings,\n fetchEmailDomain,\n createEmailDomain,\n deleteEmailDomain,\n emailDomainCheckDKIM,\n emailDomainCheckReturnPathStatus,\n setAsDefaultSendingDomain,\n sendTestEmail,\n updateEmailDomainUsername\n } = useEmailDomainSettings();\n\n const editEmail = ref(null);\n const copiedText = ref(false);\n const domainDialog = ref(false);\n const testEmailDialog = ref(false);\n const domainSettingsDialog = ref(false);\n const newDomain = ref<string>('');\n const testEmailAddress = ref('');\n const createEmailDomainErrorMessage = ref('');\n const currentWorkingSetting = ref<EmailDomainSettings>(null);\n const domainSettingsDeleteConfirmDialog = ref(false);\n\n watch(newDomain, (newValue) => {\n newDomain.value = newValue.toLowerCase();\n });\n\n return {\n editEmail,\n copiedText,\n domainDialog,\n testEmailDialog,\n domainSettingsDialog,\n newDomain,\n testEmailAddress,\n createEmailDomainErrorMessage,\n currentWorkingSetting,\n domainSettingsDeleteConfirmDialog,\n emailDomainSettingsLoading,\n emailDomainSettings,\n fetchEmailDomain,\n createEmailDomain,\n deleteEmailDomain,\n emailDomainCheckDKIM,\n emailDomainCheckReturnPathStatus,\n setAsDefaultSendingDomain,\n sendTestEmail,\n updateEmailDomainUsername,\n }\n },\n\n created() {\n EventBus.$on('create-email-domain-success', () => {\n const newDomain = this.domains.find((d) => toLower(d.domain) === toLower(this.newDomain));\n this.newDomain = '';\n this.domainDialog = false;\n\n this.domainSettingsInit(newDomain);\n });\n EventBus.$on('delete-email-domain-success', () => {\n this.currentWorkingSetting = '';\n this.domainSettingsDeleteConfirmDialog = false;\n });\n EventBus.$on('send-test-email-success', () => {\n this.testEmailAddress = '';\n this.testEmailDialog = false;\n });\n EventBus.$on('create-email-domain-error', (message) => {\n this.createEmailDomainErrorMessage = message;\n this.testEmailDialog = false;\n });\n\n this.fetchEmailDomain();\n },\n\n computed: {\n domains() {\n const domains = clone(this.emailDomainSettings);\n domains.push({\n domain: 'fleetwire.io',\n email: 'no-reply@fleetwire.io',\n DKIMVerified: true,\n SPFVerified: true,\n });\n return domains;\n },\n activeDomain() {\n const domain = filter(this.domains, (d) => d.active);\n return get(domain, '0.domain', 'fleetwire.io');\n },\n dkimName() {\n if (get(this.currentWorkingSetting, 'DKIMPendingHost')) return this.currentWorkingSetting.DKIMPendingHost;\n if (get(this.currentWorkingSetting, 'DKIMHost')) return this.currentWorkingSetting.DKIMHost;\n return '';\n },\n dkimValue() {\n if (get(this.currentWorkingSetting, 'DKIMPendingTextValue')) return this.currentWorkingSetting.DKIMPendingTextValue;\n if (get(this.currentWorkingSetting, 'DKIMTextValue')) return this.currentWorkingSetting.DKIMTextValue;\n return '';\n },\n username: {\n get() {\n return split(this.editEmail.email, '@')[0];\n },\n set(value) {\n const domain = split(this.editEmail.email, '@');\n this.editEmail.email = `${value}@${domain[1]}`;\n },\n },\n },\n\n methods: {\n\n updateEmailAddress(item) {\n this.editEmail = null;\n this.updateEmailDomainUsername(item);\n },\n\n sendTestEmailInit() {\n this.testEmailDialog = true;\n },\n\n copyToClipboardInit(text) {\n copyTextToClipboard(text)\n .then(() => {\n this.variableLegendDialog = false;\n this.copiedText = true;\n });\n },\n\n showSetAsDefault(item) {\n if (this.domains.length === 1) return false;\n if (item.active) return false;\n\n if (!item.SPFVerified || !item.DKIMVerified) return false;\n\n const found = filter(this.domains, (d) => d.active);\n\n return !(found.length === 0 && item.domain === 'fleetwire.io');\n },\n\n showSending(item) {\n if (this.domains.length === 1) return true;\n if (item.active) return true;\n\n const found = filter(this.domains, (d) => d.active);\n\n return found.length === 0 && item.domain === 'fleetwire.io';\n },\n\n domainSettingsInit(item) {\n this.currentWorkingSetting = item;\n this.domainSettingsDialog = true;\n },\n\n domainSettingsRemoveInit(item) {\n this.currentWorkingSetting = item;\n this.domainSettingsDeleteConfirmDialog = true;\n },\n },\n\n beforeUnmount() {\n EventBus.$off('create-email-domain-success');\n EventBus.$off('delete-email-domain-success');\n EventBus.$off('send-test-email-success');\n EventBus.$off('create-email-domain-error');\n },\n};\n</script>\n","import {useStore} from 'vuex';\nimport {computed} from 'vue';\nimport {Email, EmailTemplate} from '@/store/modules/email';\nimport {StoreLoaders} from '@/types';\n\nexport function useEmail() {\n const store = useStore();\n\n const emailTemplate = computed<EmailTemplate | null>(() => store.getters['email/emailTemplate']);\n const emailLoading = computed<StoreLoaders>(() => store.getters['email/loading']);\n const emailHistory = computed(() => store.getters['email/history']);\n const emailForm = computed(() => store.getters['email/emailForm']);\n const emailsLoading = computed(() => store.getters['email/loading']);\n const emailTemplates = computed<EmailTemplate[]>(() => store.getters['email/emailTemplates']);\n\n\n const sendEmail = async (payload: Email) => {\n return await store.dispatch('email/sendEmail', payload);\n }\n\n const getEmailTemplate = async (uuid: string): Promise<EmailTemplate> => {\n return await store.dispatch('email/getEmailTemplate', uuid);\n };\n\n const getEmailHistory = async (data: { type: string, id: string }) => {\n return await store.dispatch('email/history', data);\n };\n\n const getEmailTemplates = async (data?: { context?: string }): Promise<EmailTemplate[]> => {\n return await store.dispatch('email/getEmailTemplates', data);\n };\n\n const updateEmailTemplate = async (payload: EmailTemplate) => {\n return await store.dispatch('email/updateEmailTemplate', payload);\n }\n\n const sendTestTemplateEmail = async (payload: EmailTemplate) => {\n return await store.dispatch('email/sendTestTemplateEmail', payload);\n }\n\n const resetEmailTemplate = async (payload: EmailTemplate) => {\n return await store.dispatch('email/resetEmailTemplate', payload);\n }\n\n\n return {\n emailTemplate,\n emailLoading,\n emailHistory,\n emailForm,\n emailsLoading,\n emailTemplates,\n getEmailTemplate,\n updateEmailTemplate,\n sendTestTemplateEmail,\n resetEmailTemplate,\n getEmailHistory,\n getEmailTemplates,\n sendEmail\n }\n}","<template>\n <div>\n <div class=\"grid grid-cols-1 md:grid-cols-3 gap-4 my-5\">\n <div class=\"px-4 md:px-0\">\n <div class=\"setting-section-description\">\n <h3 class=\"text-lg font-medium text-gray-900 dark:text-gray-100\">Edit email template</h3>\n\n <div class=\"feature-description\">\n Customize your email templates using dynamic variables to personalize your messages. Insert customer\n details, order information, and more using our\n <a class=\"text-blue-500\" href=\"https://help.fleetwire.io/en/article/email-variables-1i0tn10/?bust=1649486067702\" target=\"_blank\">email\n variables</a>.\n Click the link to see the full list of available variables and how to use them.\n <div v-if=\"debugDrawerOpen\">\n <v-btn size=\"small\" @click=\"sendTestTemplateEmail(emailTemplate)\">Send Test Email</v-btn>\n </div>\n </div>\n </div>\n </div>\n\n <div class=\"col-span-1 md:col-span-2 px-4 md:px-0\">\n <v-card :disabled=\"emailLoading.email_templates\" class=\"mb-5\" variant=\"elevated\">\n <v-card-text>\n <v-form>\n <v-text-field\n v-if=\"emailTemplate\"\n v-model=\"emailTemplate.subject\"\n class=\"mb-4\"\n label=\"Subject\"\n variant=\"outlined\"\n ></v-text-field>\n <div id=\"editorjs\" class=\"rounded min-h-[200px]\" style=\"border: #9b9b9b 1px solid;\"></div>\n </v-form>\n </v-card-text>\n <v-card-actions class=\"flex flex-wrap gap-2 justify-end px-4 py-3\">\n <v-btn\n v-if=\"!emailTemplate || !emailTemplate.default\"\n class=\"order-1 md:order-none\"\n color=\"red\"\n size=\"small\"\n variant=\"text\"\n @click=\"resetEmailTemplateInit()\"\n >Reset\n </v-btn>\n <v-spacer class=\"hidden md:block\"/>\n <v-btn :to=\"{name: 'settings.account.email', hash: '#email'}\" class=\"w-full md:w-auto\" size=\"small\" variant=\"text\">\n Back\n </v-btn>\n <v-btn\n :loading=\"emailLoading.email_templates\"\n class=\"w-full md:w-auto\"\n color=\"primary\"\n @click=\"updateEmailTemplateInit()\"\n >\n Save\n </v-btn>\n </v-card-actions>\n </v-card>\n </div>\n </div>\n </div>\n</template>\n\n<script lang=\"ts\" setup>\nimport {nextTick, onBeforeUnmount, onMounted} from 'vue';\nimport EditorJS from '@editorjs/editorjs';\nimport Header from '@editorjs/header';\nimport List from '@editorjs/list';\nimport Paragraph from 'editorjs-paragraph-with-alignment';\nimport {useEmail} from '@/composables/useEmail';\nimport {useAppSettings} from '@/composables/useAppSettings';\nimport {useRoute, useRouter} from 'vue-router';\n\n\nconst route = useRoute();\nconst router = useRouter();\nconst {\n emailTemplate,\n emailLoading,\n getEmailTemplate,\n updateEmailTemplate,\n sendTestTemplateEmail,\n resetEmailTemplate\n} = useEmail();\n\nconst {debugDrawerOpen} = useAppSettings();\n\n\nlet editorjs: EditorJS | null = null;\n\nconst resetEmailTemplateInit = () => {\n resetEmailTemplate(emailTemplate.value).then((template) => {\n if (template.uuid !== route.params.uuid) {\n router.replace({\n name: 'settings.account.email.email_template_single',\n params: {uuid: template.uuid}\n }).catch(() => {\n });\n }\n });\n};\n\nconst updateEmailTemplateInit = () => {\n editorjs\n .save()\n .then((outputData) => {\n const localEmailTemplate = {...emailTemplate.value};\n\n localEmailTemplate.email_body_blocks = outputData;\n\n updateEmailTemplate(localEmailTemplate).then((template) => {\n console.dir('THEN updateEmailTemplate');\n console.dir(template);\n if (template.uuid !== route.params.uuid) {\n router.replace({\n name: 'settings.account.email.email_template_single',\n params: {uuid: template.uuid}\n }).catch(() => {\n });\n }\n });\n }).catch((error) => {\n console.log('Saving failed: ', error);\n });\n};\n\nonMounted(() => {\n getEmailTemplate(route.params.uuid as string).then(() => {\n nextTick(() => {\n console.dir(emailTemplate.value.email_body_blocks);\n if (editorjs && typeof editorjs.destroy === 'function') {\n editorjs.destroy();\n }\n\n editorjs = new EditorJS({\n autofocus: true,\n holder: 'editorjs',\n defaultBlock: 'paragraph',\n tools: {\n paragraph: {\n class: Paragraph,\n inlineToolbar: true,\n },\n header: Header,\n list: List,\n },\n data: emailTemplate.value.email_body_blocks,\n minHeight: 200,\n });\n });\n }).catch(() => {\n router.replace({name: 'settings.account.email', hash: '#email'}).catch(() => {\n });\n });\n});\n\nonBeforeUnmount(() => {\n if (editorjs && typeof editorjs.destroy === 'function') {\n editorjs.destroy();\n }\n});\n\n</script>\n\n<style scoped>\n@media (max-width: 768px) {\n :deep(.codex-editor) {\n padding: 0.5rem !important;\n }\n\n :deep(.ce-toolbar__plus) {\n left: -10px !important;\n }\n\n :deep(.ce-toolbar__actions) {\n right: -10px !important;\n }\n}\n</style>\n\n","import {useStore} from 'vuex';\nimport {computed} from 'vue';\nimport {useRouter} from 'vue-router';\nimport {useSubscription} from \"@/composables/useSubscription\";\nimport {usePayments} from \"@/composables/usePayments\";\nimport {useStripe} from \"@/composables/useStripe\";\nimport {useAuth} from \"@/composables/useAuth\";\n\n\nexport function useSubscriptionManager() {\n\n const router = useRouter();\n const store = useStore();\n const {switchPlan, subscription} = useSubscription();\n const {fetchStripeCheckoutUrl} = usePayments();\n const {fetchSession} = useAuth();\n const {stripePrices} = useStripe();\n\n const planSelectionName = computed(() => plansOrdered.value[planSelection.value].name);\n const planSelectionObject = computed(() => plansOrdered.value[planSelection.value]);\n const planSelectionNameUpper = computed(() => planSelectionName.value.charAt(0).toUpperCase() + planSelectionName.value.slice(1));\n const planSelectionPrice = computed(() => planPricing[updatedSubscription.value.interval][planSelectionName.value]);\n\n // const subscriptionStatus = subscription.value?.stripe_status;\n const subscriptionStatus = computed(() => subscription.value?.stripe_status);\n const subscriptionMaster = computed(() => store.getters['subscriptions/subscriptionMaster']);\n\n const subscriptionStep = computed({\n get: () => store.getters['subscriptions/subscriptionStep'],\n set: (value) => store.commit('subscriptions/SET_SUBSCRIPTION_STEP', value),\n });\n\n const planSelection = computed({\n get: () => store.getters['subscriptions/planSelection'],\n set: (value) => store.commit('subscriptions/SET_PLAN_SELECTION', value),\n });\n\n const updatedSubscription = computed({\n get: () => store.getters['subscriptions/updatedSubscription'],\n set: (value) => store.commit('subscriptions/SET_SUBSCRIPTION_PLAN_AND_INTERVAL', value),\n });\n\n const plansOrdered = computed(() =>\n stripePrices.value.sort((a, b) =>\n ['premium', 'standard', 'basic'].indexOf(a.name) -\n ['premium', 'standard', 'basic'].indexOf(b.name)\n )\n );\n\n const openStripeCheckoutUrl = () => {\n\n fetchStripeCheckoutUrl({\n price: stripePrices.value[planSelection.value].pricing[updatedSubscription.value.interval].price_id,\n }).then((url) => {\n console.dir('Stripe checkout URL fetched');\n\n window.open(url, '_blank');\n });\n };\n\n const switchPlanInit = async () => {\n await switchPlan(stripePrices.value[planSelection.value].pricing[updatedSubscription.value.interval].price_id).then(() => {\n // pause for 2 seconds\n setTimeout(() => {\n fetchSession().then(() => {\n router.push({name: 'settings.account'}).catch();\n });\n }, 1000);\n });\n };\n\n const planPricing = {\n monthly: {\n basic: 34,\n standard: 89,\n premium: 279,\n },\n yearly: {\n basic: 24,\n standard: 69,\n premium: 239,\n },\n };\n\n return {\n subscriptionStatus,\n planSelection,\n updatedSubscription,\n plansOrdered,\n subscriptionStep,\n planPricing,\n planSelectionName,\n subscriptionMaster,\n planSelectionObject,\n planSelectionNameUpper,\n planSelectionPrice,\n openStripeCheckoutUrl,\n switchPlanInit,\n }\n}","<template>\n <!-- Plan Selection -->\n <v-card style=\"border: 1px solid rgb(224, 220, 229);\" variant=\"flat\">\n <v-card-title :class=\"{'cursor-pointer' : subscriptionStep !== 0}\" @click=\"subscriptionStep = 0\">\n <div class=\"flex items-center\">\n <span class=\"text-sm md:text-base\">1. Choose your plan</span>\n <v-spacer/>\n <v-btn\n v-if=\"subscriptionStep > 0\"\n icon=\"mdi-chevron-down\"\n size=\"small\"\n variant=\"text\"\n />\n </div>\n </v-card-title>\n\n <div v-if=\"subscriptionStep === 0\">\n <v-item-group v-model=\"planSelection\" mandatory>\n <div v-for=\"(plan, i) in plansOrdered\" :key=\"i\">\n <v-item v-slot=\"{ isSelected, toggle }\">\n <v-card\n :class=\"isSelected ? 'plan-selected' : ''\"\n :color=\"isSelected ? 'grey-200' : ''\"\n class=\"d-flex flex-column md:flex-row align-start md:align-center border-b rounded-b-none\"\n dark\n variant=\"flat\"\n @click=\"toggle\"\n >\n <v-scroll-y-transition>\n <div class=\"p-3 w-full\">\n <div class=\"subscription__card flex flex-col md:flex-row w-full\">\n <div class=\"subscription__card--first flex-1\">\n <div class=\"flex items-start\">\n <div>\n <v-btn :icon=\"isSelected ? 'mdi-circle' : 'mdi-circle-outline'\" size=\"small\" variant=\"text\"/>\n </div>\n\n <div class=\"subscription__card--details ml-2\">\n <div class=\"subscription__card--title\">\n <div class=\"font-bold uppercase text-sm md:text-base\">\n {{ plan.name }}\n </div>\n\n <div v-if=\"plan.name === subscriptionPlan\" class=\"text-xs md:text-sm\">\n <span class=\"bg-yellow-100 text-yellow-800 text-xs font-medium mr-2 px-2.5 py-0.5 rounded-full dark:bg-yellow-900 dark:text-yellow-300\" type=\"info\">Current plan</span>\n </div>\n <div v-if=\"plan.name === 'premium'\" class=\"text-xs md:text-sm\">\n <span class=\"bg-gray-200 text-gray-800 text-xs font-medium mr-2 px-2.5 py-0.5 rounded-full dark:bg-gray-700 dark:text-gray-300\" type=\"info\">You trialed this plan</span>\n </div>\n </div>\n\n <div v-if=\"plan.name === 'premium'\" class=\"subscription__card--description text-xs md:text-sm\">\n Everything in the Standard plan + more vehicles, connections and advanced features.\n </div>\n\n <div v-if=\"plan.name === 'standard'\" class=\"subscription__card--description text-xs md:text-sm\">\n Everything in the Basic plan + more vehicles, esign capability, coupons, and more.\n </div>\n\n <div v-if=\"plan.name === 'basic'\" class=\"subscription__card--description text-xs md:text-sm\">\n Great for just getting started.\n </div>\n\n <div class=\"subscription__card--bullets mt-2\">\n <template v-for=\"bullet in plan.description.bullets\" :key=\"bullet\">\n <div v-if=\"bullet !== 'And More*'\" class=\"subscription__card--bullet flex items-start\">\n <div class=\"badge badge-rounded-circle badge-success-soft mt-1 mr-2\">\n <v-icon color=\"success\" size=\"x-small\">mdi-check</v-icon>\n </div>\n <p class=\"text-xs md:text-sm\">\n {{ bullet }}\n </p>\n </div>\n </template>\n\n <div class=\"subscription__card--bullet flex items-start\">\n <div class=\"badge badge-rounded-circle badge-success-soft mt-1 mr-2\">\n <v-icon color=\"success\" size=\"x-small\">mdi-check</v-icon>\n </div>\n <p class=\"text-xs md:text-sm\">\n <a\n href=\"https://fleetwire.io/pricing/?utm_source=subscription-checkout&utm_medium=subscription-page&utm_campaign=subscription-review\"\n rel=\"noopener noreferrer\"\n target=\"_blank\"\n @click.stop\n >\n And more...\n </a>\n </p>\n </div>\n </div>\n </div>\n </div>\n </div>\n\n <div class=\"subscription__card--second mt-3 md:mt-0 md:ml-4\">\n <div class=\"subscription__card--price-title text-xs md:text-sm\">Starts At</div>\n <div class=\"subscription__card--price-price flex items-baseline\">\n <span class=\"text-sm md:text-base\">$</span>\n <span class=\"text-lg md:text-2xl\">\n {{ planPricing['yearly'][plan.name] }}\n </span>\n <span class=\"text-xs md:text-sm\">/mo</span>\n </div>\n </div>\n </div>\n </div>\n </v-scroll-y-transition>\n </v-card>\n </v-item>\n </div>\n </v-item-group>\n </div>\n </v-card>\n</template>\n\n<script lang=\"ts\" setup>\nimport {useSubscription} from '@/composables/useSubscription';\nimport {useSubscriptionManager} from '@/composables/useSubscriptionManager';\n\nconst {subscriptionPlan} = useSubscription();\nconst {subscriptionStep, planSelection, plansOrdered, planPricing} = useSubscriptionManager();\n</script>\n","<template>\n <!-- Terms & Discounts -->\n <v-card ref=\"termsSection\" class=\"mt-5\" style=\"border: 1px solid rgb(224, 220, 229);\" variant=\"flat\">\n <v-card-title :class=\"{'cursor-pointer' : subscriptionStep === 0}\" @click=\"handleStepClick\">\n <div class=\"flex\">\n <span class=\"text-sm md:text-base\">2. Term & Discounts</span>\n <v-spacer/>\n <v-btn\n v-if=\"subscriptionStep !== 1\"\n icon=\"mdi-chevron-down\"\n variant=\"text\"\n />\n </div>\n </v-card-title>\n\n <div v-show=\"subscriptionStep === 1\">\n <v-item-group\n v-model=\"updatedSubscription.interval\"\n mandatory\n >\n <div v-for=\"(_details, term) in planPricing\" :key=\"term\">\n <v-item v-slot=\"{ isSelected, toggle }\" :value=\"term\">\n <v-card\n :color=\"isSelected ? 'grey-200' : ''\"\n class=\"d-flex align-center border-b rounded-b-none\"\n variant=\"flat\"\n @click=\"toggle\"\n >\n <v-scroll-y-transition>\n <div class=\"p-3 w-full\">\n <div class=\"subscription__card d-flex justify-space-between align-center\">\n <div class=\"subscription__card--first d-flex align-center\">\n <div class=\"mr-2\">\n <v-btn\n :icon=\"isSelected ? 'mdi-circle' : 'mdi-circle-outline'\"\n variant=\"text\"\n />\n </div>\n\n <div class=\"subscription__card--details\">\n <div class=\"subscription__card--title\">\n <div class=\"font-bold\">\n <div v-if=\"term === 'monthly'\">Monthly</div>\n <div v-else>Annual</div>\n </div>\n </div>\n\n <div class=\"subscription__card--description text-caption text-md-body-2\">\n <div v-if=\"term === 'monthly'\">Month-to-month contract</div>\n <div v-else>Save up to 29% by committing to a 12-month plan</div>\n </div>\n </div>\n </div>\n\n <div class=\"subscription__card--second text-right\">\n <div class=\"subscription__card--price-title text-caption text-md-body-2\">Per Month</div>\n <div class=\"subscription__card--price-price d-flex align-end justify-end\">\n <span style=\"padding-top: 4px;\">$</span>\n <span style=\"font-size: 24px;align-self: end;\">\n {{ planPricing[term][planSelectionName] }}\n </span>\n <span style=\"font-size: 14px;align-self: end;padding-bottom: 2px;\">/mo</span>\n </div>\n </div>\n </div>\n </div>\n </v-scroll-y-transition>\n </v-card>\n </v-item>\n </div>\n </v-item-group>\n </div>\n </v-card>\n</template>\n\n<script lang=\"ts\" setup>\nimport {useSubscriptionManager} from '@/composables/useSubscriptionManager';\nimport {ref} from 'vue';\nimport type {VCard} from 'vuetify/components';\n\nconst termsSection = ref<InstanceType<typeof VCard> | null>(null);\n\nconst {\n subscriptionStep,\n planPricing,\n updatedSubscription,\n planSelectionName\n} = useSubscriptionManager();\n\nconst handleStepClick = () => {\n if (subscriptionStep.value === 0) {\n subscriptionStep.value = 1;\n // Wait for the next tick to ensure the content is rendered\n setTimeout(() => {\n termsSection.value?.$el?.scrollIntoView({behavior: 'smooth', block: 'start'});\n }, 100);\n } else {\n subscriptionStep.value = 1;\n }\n};\n</script>\n","<template>\n <!-- Review & Confirm -->\n <v-card class=\"mt-5\" style=\"border: 1px solid rgb(224, 220, 229);\" variant=\"flat\">\n <v-card-title :class=\"{'cursor-pointer' : subscriptionStep < 2}\" class=\"py-4\" @click=\"subscriptionStep = 2\">\n <div class=\"flex align-center\">\n <span class=\"text-sm md:text-base\">3. Review & Confirm</span>\n <v-spacer/>\n <v-btn\n v-if=\"subscriptionStep !== 2\"\n icon=\"mdi-chevron-down\"\n size=\"small\"\n variant=\"text\"\n />\n </div>\n </v-card-title>\n\n <div v-show=\"subscriptionStep === 2\">\n <v-card :disabled=\"stripeLoading.fetchPortalUrl\" :loading=\"stripeLoading.fetchPortalUrl\">\n <v-card-text class=\"pa-4\">\n <p class=\"text-body-2 text-sm-md\">\n By continuing, you agree to our\n <a\n class=\"underline text-primary\"\n href=\"https://fleetwire.io/terms/?utm_source=subscription-checkout&utm_medium=subscription-page&utm_campaign=subscription-review\"\n rel=\"noopener noreferrer\"\n target=\"_blank\"\n @click.stop\n >\n Terms of Service\n </a>\n and\n <a\n class=\"underline text-primary\"\n href=\"https://fleetwire.io/privacy-policy/?utm_source=subscription-checkout&utm_medium=subscription-page&utm_campaign=subscription-review\"\n rel=\"noopener noreferrer\"\n target=\"_blank\"\n @click.stop\n >\n Privacy Policy\n </a>.\n </p>\n </v-card-text>\n <v-card-actions class=\"pa-4\">\n <v-spacer/>\n <v-btn\n :disabled=\"paymentsLoading.cardBtnLoading\"\n :to=\"{ name: 'settings.account' }\"\n class=\"mr-2\"\n size=\"small\"\n variant=\"text\"\n >\n Back\n </v-btn>\n <v-btn\n v-if=\"hasActiveSubscription\"\n :disabled=\"subscriptionsLoading.subscribing\"\n :loading=\"subscriptionsLoading.subscribing\"\n color=\"primary\"\n size=\"small\"\n @click=\"switchPlanInit()\"\n >\n Swap Plans\n </v-btn>\n <v-btn\n v-if=\"!hasActiveSubscription\"\n :loading=\"stripeLoading.fetchPortalUrl\"\n class=\"ml-2\"\n size=\"small\"\n variant=\"text\"\n @click=\"openStripeCheckoutUrl()\"\n >\n Checkout on Stripe\n </v-btn>\n </v-card-actions>\n </v-card>\n </div>\n </v-card>\n</template>\n\n<script lang=\"ts\" setup>\nimport {useSubscription} from '@/composables/useSubscription';\nimport {usePayments} from '@/composables/usePayments';\nimport {useStripe} from '@/composables/useStripe';\nimport {useSubscriptionManager} from '@/composables/useSubscriptionManager';\n\n\nconst {\n hasActiveSubscription,\n subscriptionsLoading,\n} = useSubscription();\n\nconst {paymentsLoading} = usePayments()\n\nconst {stripeLoading} = useStripe();\nconst {\n subscriptionStep,\n openStripeCheckoutUrl,\n switchPlanInit,\n} = useSubscriptionManager();\n\n</script>","<template>\n <v-card color=\"transparent\" variant=\"flat\">\n <div class=\"subscription__card--summary-card\">\n <div class=\"subscription__card--summary-card-title\">\n <div class=\"font-extrabold text-lg sm:text-xl\">{{ planSelectionNameUpper }} Plan</div>\n <div class=\"subscription__card--summary-card-pricing flex items-baseline\">\n <div class=\"text-2xl sm:text-3xl\">$</div>\n <div class=\"text-3xl sm:text-4xl\">{{ planSelectionPrice }}</div>\n <div class=\"text-lg sm:text-xl ml-1\">/mo</div>\n </div>\n </div>\n\n <div class=\"subscription__card--summary-card-details\">\n <div class=\"subscription__card--summary-card-details-row1 flex justify-between items-center py-2\" data-test-id=\"plan\">\n <div class=\"text-sm sm:text-base\">\n <div class=\"text-gray-600\">Plan Type</div>\n {{ planSelectionNameUpper }}\n </div>\n <div class=\"text-sm sm:text-base\">\n <div class=\"text-right\">${{ planSelectionAnnualPrice }}\n <span v-if=\"updatedSubscription.interval === 'monthly'\">/mo</span>\n <span v-else>/yr</span>\n </div>\n </div>\n </div>\n </div>\n\n <div class=\"subscription__card--bullets space-y-3 mt-4\">\n <template v-for=\"bullet in planSelectionObject.description.bullets\" :key=\"bullet\">\n <div v-if=\"bullet !== 'And More*'\" class=\"subscription__card--bullet flex items-start\">\n <div class=\"badge badge-rounded-circle badge-success-soft mt-1 mr-3\">\n <v-icon color=\"success\" size=\"x-small\">mdi-check</v-icon>\n </div>\n <p class=\"text-sm sm:text-base\">\n {{ bullet }}\n </p>\n </div>\n </template>\n\n <div class=\"subscription__card--bullet flex items-start\">\n <div class=\"badge badge-rounded-circle badge-success-soft mt-1 mr-3\">\n <v-icon color=\"success\" size=\"x-small\">mdi-check</v-icon>\n </div>\n <p class=\"text-sm sm:text-base\">\n <a\n class=\"text-primary hover:underline\"\n href=\"https://fleetwire.io/pricing/?utm_source=subscription-checkout&utm_medium=subscription-page&utm_campaign=subscription-review\"\n rel=\"noopener noreferrer\"\n target=\"_blank\"\n @click.stop\n >\n And more...\n </a>\n </p>\n </div>\n </div>\n </div>\n\n <div class=\"flex bg-white border rounded p-3 mt-4 text-sm sm:text-base\">\n <span class=\"flex-grow\">Have a question?</span>\n <span><a class=\"text-primary hover:underline\" href=\"https://help.fleetwire.io/en/\" target=\"_blank\">Find an answer</a></span>\n </div>\n\n <div v-if=\"hasActiveSubscription\" class=\"text-center my-4 sm:my-7\">\n <v-dialog class=\"mx-2\" max-width=\"600\">\n <template v-slot:activator=\"{ props: cancelSubscriptionDialogProps }\">\n <v-btn class=\"text-sm sm:text-base\" size=\"small\" v-bind=\"cancelSubscriptionDialogProps\" variant=\"tonal\">Cancel\n Subscription\n </v-btn>\n </template>\n\n <template v-slot:default=\"{ isActive }\">\n <v-card class=\"mx-2\" title=\"Cancel Subscription\">\n <v-divider opacity=\"50\"/>\n <v-card-text class=\"px-4 sm:px-6\">\n <div class=\"font-bold text-base sm:text-lg\">Are you sure you want to cancel your {{ subscriptionPlan }}\n subscription?\n </div>\n\n <div class=\"mt-4 sm:mt-5 text-sm sm:text-base\">By cancelling, you will lose access to:</div>\n <div class=\"ml-4 sm:ml-10 mt-3 sm:mt-5\">\n <ul class=\"list-disc text-sm sm:text-base\" v-html=\"subscriptionPlanFeatures\"></ul>\n </div>\n\n <div class=\"mt-6 sm:mt-10 font-bold text-base sm:text-lg\">We value your membership and want to make sure\n you're getting the most out of it.\n </div>\n\n <div class=\"mt-3 sm:mt-5 text-sm sm:text-base\">Before you go, here are some options you might consider:\n </div>\n <div class=\"ml-4 sm:ml-10 mt-3 sm:mt-5\">\n <ul class=\"list-disc text-sm sm:text-base\">\n <li><span class=\"font-bold\">Speak with Support:</span> Let us know if there's anything we can do to\n improve your experience.\n </li>\n <li><span class=\"font-bold\">Pause Subscription:</span> If you need a break, consider pausing your\n subscription instead of cancelling.\n </li>\n <li><span class=\"font-bold\">Offer Feedback:</span> Share your reasons for cancelling so we can work on\n making our service better.\n </li>\n </ul>\n </div>\n\n <div class=\"mt-6 sm:mt-10 font-bold text-base sm:text-lg\">Would you like to continue with the\n cancellation, or would you prefer to explore these options?\n </div>\n </v-card-text>\n\n <v-divider opacity=\"50\"/>\n <v-card-actions class=\"px-4 sm:px-6 py-3\">\n <v-btn class=\"text-sm sm:text-base\" size=\"small\" @click=\"isActive.value = false\">nevermind</v-btn>\n <v-spacer/>\n <v-btn class=\"text-sm sm:text-base\" size=\"small\" @click=\"isActive.value = false; cancelSubscriptionCommit()\">\n End Subscription\n </v-btn>\n </v-card-actions>\n </v-card>\n </template>\n </v-dialog>\n </div>\n\n <div class=\"font-light text-xs sm:text-sm mb-6 sm:mb-10 my-4 sm:my-7\">\n Annual subscriptions require a one-year non-cancellable commitment.\n By using Fleetwire you agree to our\n <a\n class=\"underline text-primary hover:text-primary-dark\"\n href=\"https://fleetwire.io/terms/?utm_source=subscription-checkout&utm_medium=subscription-page&utm_campaign=subscription-review\"\n rel=\"noopener noreferrer\"\n target=\"_blank\"\n >\n Terms of Service\n </a>.\n </div>\n </v-card>\n</template>\n\n<script lang=\"ts\" setup>\nimport {computed} from 'vue';\nimport {useSubscription} from '@/composables/useSubscription';\nimport {useSubscriptionManager} from '@/composables/useSubscriptionManager';\nimport {SubscriptionPlan} from '@/types';\n\n\nconst {\n subscriptionPlan,\n subscriptionPlans,\n hasActiveSubscription,\n cancelSubscriptionStripePortal,\n} = useSubscription();\n\n\nconst {planSelection, plansOrdered, planPricing, planSelectionName, updatedSubscription} = useSubscriptionManager();\n\n\nconst planSelectionObject = computed(() => plansOrdered.value[planSelection.value]);\nconst planSelectionNameUpper = computed(() => planSelectionName.value.charAt(0).toUpperCase() + planSelectionName.value.slice(1));\nconst planSelectionPrice = computed(() => planPricing[updatedSubscription.value.interval][planSelectionName.value]);\nconst planSelectionAnnualPrice = computed(() => updatedSubscription.value.interval === 'monthly' ? planSelectionPrice.value : planSelectionPrice.value * 12);\nconst subscriptionPlanIndex = computed(() => subscriptionPlans.value.findIndex((p: SubscriptionPlan) => p.name === subscriptionPlan.value));\nconst subscriptionPlanFeatures = computed(() => {\n return plansOrdered.value[subscriptionPlanIndex.value]?.description?.bullets?.map((bullet: string) => {\n return `<li>${bullet}</li>`;\n }).join('');\n});\n\nconst cancelSubscriptionCommit = async () => {\n await cancelSubscriptionStripePortal().then((responseData) => {\n console.dir('Subscription cancelled');\n console.dir(responseData);\n // router.push({name: 'settings.account'}).catch();\n\n window.open(responseData.url, '_blank');\n });\n};\n</script>\n\n","<template>\n <div>\n\n <h1 class=\"mb-2 text-2xl font-semibold tracking-tight text-gray-900 dark:text-white\">Change Subscription</h1>\n\n <div class=\"grid gap-5 mt-10 lg:grid-cols-[60%_auto]\">\n\n <div>\n <!-- Plan Selection -->\n <SubscriptionSteps/>\n\n <!-- Terms & Discounts -->\n <SubscriptionTermsAndDiscount/>\n\n <!-- Review & Confirm -->\n <SubscriptionReviewAndConfirm/>\n </div>\n\n <div>\n <SubscriptionOverview/>\n </div>\n </div>\n\n </div>\n</template>\n\n<script lang=\"ts\" setup>\nimport {onMounted, watch} from 'vue';\nimport {useSubscription} from '@/composables/useSubscription';\nimport {usePayments} from '@/composables/usePayments';\nimport {useStripe} from '@/composables/useStripe';\nimport {useSubscriptionManager} from '@/composables/useSubscriptionManager';\nimport SubscriptionSteps from '@/views/dashboard/settings/Billing/SubscriptionCheckout/SubscriptionSteps.vue';\nimport SubscriptionTermsAndDiscount\n from '@/views/dashboard/settings/Billing/SubscriptionCheckout/SubscriptionTermsAndDiscount.vue';\nimport SubscriptionReviewAndConfirm\n from '@/views/dashboard/settings/Billing/SubscriptionCheckout/SubscriptionReviewAndConfirm.vue';\nimport SubscriptionOverview from '@/views/dashboard/settings/Billing/SubscriptionCheckout/SubscriptionOverview.vue';\n\nconst {\n subscriptionPlan,\n\n} = useSubscription();\n\nconst {billingSessionUrl} = usePayments()\n\nconst {fetchStripePriceData} = useStripe();\n\nconst {\n\n updatedSubscription\n} = useSubscriptionManager();\n\nonMounted(() => {\n fetchStripePriceData()\n})\n\nwatch(subscriptionPlan, (newVal) => {\n updatedSubscription.value.plan = newVal;\n});\n\nwatch(billingSessionUrl, (newUrl) => {\n if (newUrl) {\n window.open(newUrl, '_blank');\n }\n});\n</script>\n\n<style>\n.subscription__card {\n display: grid;\n grid-template-columns: 1fr auto;\n gap: 12px;\n justify-content: space-between;\n align-items: start;\n}\n\n.subscription__card--first {\n display: grid;\n grid-template-columns: auto 1fr;\n gap: 12px;\n}\n\n.subscription__card--second {\n display: grid;\n gap: 4px;\n grid-template-rows: repeat(2, auto);\n justify-items: end;\n padding-top: 12px;\n}\n\n.subscription__card--details {\n display: inline-grid;\n gap: 6px;\n font-size: 16px;\n color: rgb(62, 52, 70);\n}\n\n.subscription__card--title {\n display: flex;\n align-items: center;\n flex-flow: row;\n gap: 8px;\n flex-wrap: wrap;\n}\n\n.subscription__card--description {\n line-height: 1.5;\n font-size: 14px;\n color: rgb(128, 112, 143);\n margin: 0;\n}\n\n.subscription__card--bullets {\n display: grid;\n grid-template-rows: auto;\n gap: 8px;\n font-size: 14px;\n color: rgb(128, 112, 143);\n}\n\n.subscription__card--bullet {\n display: flex;\n gap: 8px;\n align-items: center;\n align-content: center;\n flex-wrap: wrap;\n}\n\n.subscription__card--price-title {\n color: rgb(128, 112, 143);\n font-size: 12px;\n text-transform: uppercase;\n font-weight: bold;\n}\n\n.subscription__card--price-price {\n display: inline-grid;\n grid-template-columns: repeat(3, auto);\n color: rgb(62, 52, 70);\n}\n\n.subscription__card--summary-card {\n background: rgb(255, 255, 255);\n border-radius: 6px;\n border: 1px solid rgb(224, 220, 229);\n margin-bottom: 16px;\n position: relative;\n display: grid;\n grid-template-rows: repeat(2, auto);\n gap: 30px;\n padding: 30px 20px 20px;\n}\n\n.subscription__card--summary-card-title {\n display: grid;\n grid-template-rows: repeat(2, auto);\n gap: 12px;\n font-size: 18px;\n place-items: center;\n text-align: center;\n}\n\n.subscription__card--summary-card-pricing {\n display: inline-grid;\n grid-template-columns: repeat(3, auto);\n font-size: 56px;\n}\n\n.subscription__card--summary-card-details {\n color: rgb(128, 112, 143);\n font-size: 16px;\n}\n\n.subscription__card--summary-card-details-row1 {\n display: grid;\n grid-template-columns: 1fr auto;\n justify-content: space-between;\n gap: 4px;\n align-items: center;\n padding: 16px 0;\n border-top: 1px solid rgb(240, 236, 243);\n}\n\n.subscription__card--summary-card-details-row1-title {\n text-transform: uppercase;\n font-size: 12px;\n font-weight: 600;\n color: rgb(128, 112, 143);\n margin-bottom: 8px;\n}\n\n.plan-selected {\n background-color: #e8e8e8;\n}\n\n@media (max-width: 768px) {\n .subscription__card {\n grid-template-columns: 1fr;\n }\n\n .subscription__card--first {\n grid-template-columns: 1fr;\n }\n\n .subscription__card--second {\n justify-items: start;\n }\n\n .subscription__card--summary-card-pricing {\n font-size: 36px;\n }\n}\n</style>\n","<template>\n <div>\n <Connections/>\n\n <v-divider class=\"my-10\" opacity=\"50\"/>\n\n <Integrations/>\n </div>\n</template>\n\n<script lang=\"ts\" setup>\nimport {defineAsyncComponent} from 'vue';\n\nconst Integrations = defineAsyncComponent(() => import('@/components/dashboard/settings/providers/Integrations.vue'));\nconst Connections = defineAsyncComponent(() => import('@/components/dashboard/settings/providers/Connections.vue'));\n</script>\n","/*\n * Copyright (c) 2025. Chad and contributors.\n * All rights reserved.\n */\n\nimport {useStore} from 'vuex';\nimport {computed} from 'vue';\n\nexport function useProviders() {\n const store = useStore();\n\n const paymentProviders = computed(() => store.getters['providers/paymentProviders']);\n\n const getProviders = () => {\n return store.dispatch('providers/getProviders');\n }\n\n const deletePaymentProfile = async (payload: string | { uuid: string }) => {\n return await store.dispatch('providers/deletePaymentProfile', payload);\n }\n\n const getPaymentProfiles = () => {\n return store.dispatch('providers/getPaymentProfiles');\n }\n\n return {\n paymentProviders,\n getProviders,\n deletePaymentProfile,\n getPaymentProfiles,\n }\n}","<template>\n <div>\n <v-card class=\"mobile-friendly-card\" max-width=\"100%\">\n <v-img alt=\"Stripe Payment Provider Logo\" max-height=\"75\" src=\"/images/logo/Stripelogo.png\"/>\n <v-card-text v-if=\"!hasStripe\">\n <a class=\"stripe-connect slate\" @click=\"StripeOauth\">\n <span class=\"pr-5\">Connect with</span>\n </a>\n </v-card-text>\n\n <v-card-text v-if=\"hasStripe\">\n <div class=\"flex flex-column flex-sm-row items-center border rounded p-3\">\n <div class=\"flex-shrink-0 mb-2 mb-sm-0\">\n <img :src=\"`https://ui-avatars.com/api/?name=ST`\" alt=\"Avatar\" class=\"w-8 h-8 rounded-full\">\n </div>\n <div class=\"flex-1 min-w-0 ms-0 ms-sm-4 text-center text-sm-start\">\n <p class=\"text-sm font-medium text-gray-900 truncate dark:text-white\">\n {{ stripeProvider.uid }}\n </p>\n <p class=\"text-sm text-gray-500 truncate dark:text-gray-400\">\n <strong>Connected: </strong>{{ formatRentalDate(stripeCreatedAt) }}\n </p>\n </div>\n <div class=\"mt-2 mt-sm-0\">\n <v-menu class=\"flex-row2\">\n <template v-slot:activator=\"{ props }\">\n <v-btn size=\"small\" v-bind=\"props\" variant=\"text\">\n <v-icon>mdi-dots-vertical</v-icon>\n </v-btn>\n </template>\n\n <v-list>\n <v-list-item @click=\"stripeAccountDialog = true\">\n <v-list-item-title>\n Account Data\n </v-list-item-title>\n </v-list-item>\n <v-list-item @click=\"removeStripeConfirm = true\">\n <v-list-item-title>\n Disconnect\n </v-list-item-title>\n </v-list-item>\n </v-list>\n </v-menu>\n </div>\n </div>\n </v-card-text>\n\n <v-progress-linear\n :active=\"authLoading.stripe_oauth\"\n class=\"mb-0\"\n indeterminate\n ></v-progress-linear>\n </v-card>\n\n <v-dialog v-model=\"removeStripeConfirm\" max-width=\"350\">\n <v-card>\n <v-card-title class=\"text-h5\">Delete Stripe Connection</v-card-title>\n <v-card-text>\n Are you sure you want to delete your Stripe connection?\n </v-card-text>\n <v-card-actions>\n <v-spacer/>\n <v-btn color=\"grey\" size=\"small\" variant=\"text\" @click=\"removeStripeConfirm = false\">\n Nevermind\n </v-btn>\n <v-btn color=\"primary\" @click=\"deletePaymentProfileCommit(stripeUuid)\">\n I'm Sure\n </v-btn>\n </v-card-actions>\n </v-card>\n </v-dialog>\n\n <v-dialog v-model=\"stripeAccountDialog\" class=\"mobile-dialog\" max-width=\"350\">\n <v-card>\n <v-card-title class=\"text-h6 text-sm-h5\">Stripe Account Data</v-card-title>\n <v-card-text>\n <div class=\"border-b\">\n <div class=\"flex flex-column flex-sm-row py-2\">\n <div class=\"flex-grow\">Charges Enabled:</div>\n <div class=\"mt-1 mt-sm-0\">\n <span v-if=\"stripeAccountChargesEnabled\" class=\"badge-pill text-green-500 bg-green-50\">Yes</span>\n <span v-else class=\"badge-pill text-red-500 bg-red-50\">No</span>\n </div>\n </div>\n <div class=\"flex flex-column flex-sm-row py-2 border-b\">\n <div class=\"flex-grow\">Payouts Enabled:</div>\n <div class=\"mt-1 mt-sm-0\">\n <span v-if=\"stripeAccountPayoutsEnabled\" class=\"badge-pill text-green-500 bg-green-50\">Yes</span>\n <span v-else class=\"badge-pill text-red-500 bg-red-50\">No</span>\n </div>\n </div>\n </div>\n <div class=\"mt-3\">\n <div class=\"font-extrabold\">Capabilities</div>\n <div v-for=\"(item, i) in stripeAccountCapabilities\" :key=\"i\" class=\"py-2\">\n <div class=\"flex flex-column flex-sm-row\">\n <div class=\"flex-grow\">\n {{ i }}:\n </div>\n <div class=\"mt-1 mt-sm-0\">\n <span v-if=\"item === 'active'\" class=\"badge-pill text-green-500 bg-green-50\">Active</span>\n <span v-else-if=\"item === 'inactive'\" class=\"badge-pill text-red-500 bg-red-50\">Inactive</span>\n <span v-else-if=\"item === 'pending'\" class=\"badge-pill text-yellow-500 bg-yellow-50\">pending</span>\n <span v-else class=\"\">{{ item }}</span>\n </div>\n </div>\n </div>\n </div>\n </v-card-text>\n <v-card-actions>\n <v-spacer/>\n <v-btn color=\"primary\" @click=\"stripeAccountDialog = false\">\n Okay\n </v-btn>\n </v-card-actions>\n </v-card>\n </v-dialog>\n </div>\n</template>\n\n<script lang=\"ts\" setup>\nimport {computed, ref, watch} from 'vue';\nimport {useDateFormatter} from '@/composables/useDate';\nimport {useAuth} from '@/composables/useAuth';\nimport {useProviders} from '@/composables/useProviders';\nimport {useStripe} from '@/composables/useStripe';\nimport {Provider} from '@/store/modules/providers';\n\nconst {formatRentalDate} = useDateFormatter();\n\nconst {authLoading, checkStripe, setAuthLoading} = useAuth();\nconst {\n paymentProviders,\n deletePaymentProfile,\n getPaymentProfiles\n} = useProviders();\nconst {\n stripeAccounts,\n fetchStripeCapabilities\n} = useStripe();\n\nconst StripeOauthWindow = ref(null);\nconst stripeInterval = ref(null);\nconst removeStripeConfirm = ref(false);\nconst stripeAccountDialog = ref(false);\n\nconst stripeProvider = computed(() => {\n return paymentProviders.value.find((provider: Provider) => provider.provider === 'stripe');\n});\nconst hasStripe = computed(() => {\n return stripeProvider.value !== undefined;\n});\nconst stripeEmail = computed(() => {\n return stripeProvider.value?.email;\n});\nconst stripeUuid = computed(() => {\n return stripeProvider.value?.uuid;\n});\nconst stripeCreatedAt = computed(() => {\n return stripeProvider.value?.created_at;\n});\nconst stripeAccountCapabilities = computed(() => {\n return stripeAccounts.value?.capabilities;\n});\nconst stripeAccountChargesEnabled = computed(() => {\n return stripeAccounts.value?.charges_enabled;\n});\nconst stripeAccountPayoutsEnabled = computed(() => {\n return stripeAccounts.value?.payouts_enabled;\n});\n\nconst deletePaymentProfileCommit = (uuid: string) => {\n\n deletePaymentProfile(uuid).then(() => {\n removeStripeConfirm.value = false;\n getPaymentProfiles();\n });\n}\n\nconst StripeOauth = () => {\n setAuthLoading({\n subject: 'stripe_oauth',\n loading: true,\n });\n\n const url = window.location.href;\n\n let clientId = 'ca_Gf8zoSeAOjUHi6Op0cj8DdNG00QcPIaa';\n if (url.includes('fleetwire.test') || url.includes('localhost')) {\n clientId = 'ca_Gf8zkVN3YcOedDmpefmhsmIB21bpAk21';\n }\n\n StripeOauthWindow.value = window.open(\n `https://connect.stripe.com/oauth/authorize?response_type=code&client_id=${clientId}&scope=read_write_and_identity_write`,\n 'Fleetwire.io Stripe Oauth',\n 'scrollbars,status,width=750,height=650',\n );\n\n stripeInterval.value = setInterval(() => {\n if (StripeOauthWindow.value.closed) {\n clearInterval(stripeInterval.value);\n setAuthLoading({\n subject: 'stripe_oauth',\n loading: false,\n });\n }\n checkStripe().then((results) => {\n console.dir(results);\n if (results) {\n getPaymentProfiles();\n StripeOauthWindow.value.close();\n clearInterval(stripeInterval.value);\n }\n });\n }, 2000);\n};\n\nwatch(hasStripe, (val) => {\n if (val) {\n fetchStripeCapabilities();\n }\n}, {immediate: true});\n</script>\n\n<style lang=\"scss\" scoped>\n.stripe-connect a {\n text-decoration: none;\n}\n\n.stripe-connect {\n background: #635bff;\n display: inline-block;\n height: 38px;\n text-decoration: none;\n width: 180px;\n max-width: 100%;\n min-width: 160px;\n\n border-radius: 4px;\n -moz-border-radius: 4px;\n -webkit-border-radius: 4px;\n\n user-select: none;\n -moz-user-select: none;\n -webkit-user-select: none;\n -ms-user-select: none;\n\n -webkit-font-smoothing: antialiased;\n}\n\n.stripe-connect span {\n color: #ffffff;\n display: block;\n font-family: sohne-var, \"Helvetica Neue\", Arial, sans-serif;\n font-size: 15px;\n font-weight: 400;\n line-height: 14px;\n padding: 11px 0 0 24px;\n position: relative;\n text-align: left;\n}\n\n.stripe-connect:hover {\n background: #7a73ff;\n}\n\n.stripe-connect.slate {\n background: #0a2540;\n}\n\n.stripe-connect.slate:hover {\n background: #425466;\n}\n\n.stripe-connect.white {\n background: #ffffff;\n}\n\n.stripe-connect.white span {\n color: #0a2540;\n}\n\n.stripe-connect.white:hover {\n background: #f6f9fc;\n}\n\n.stripe-connect span::after {\n background-repeat: no-repeat;\n background-size: 49.58px;\n content: \"\";\n height: 20px;\n left: 65%;\n position: absolute;\n top: 29%;\n width: 50px;\n}\n\n/* Logos */\n.stripe-connect span::after {\n background-image: url(\"data:image/svg+xml,%3C%3Fxml version='1.0' encoding='utf-8'%3F%3E%3C!-- Generator: Adobe Illustrator 23.0.4, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E%3Csvg version='1.1' id='Layer_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 468 222.5' style='enable-background:new 0 0 468 222.5;' xml:space='preserve'%3E%3Cstyle type='text/css'%3E .st0%7Bfill-rule:evenodd;clip-rule:evenodd;fill:%23FFFFFF;%7D%0A%3C/style%3E%3Cg%3E%3Cpath class='st0' d='M414,113.4c0-25.6-12.4-45.8-36.1-45.8c-23.8,0-38.2,20.2-38.2,45.6c0,30.1,17,45.3,41.4,45.3 c11.9,0,20.9-2.7,27.7-6.5v-20c-6.8,3.4-14.6,5.5-24.5,5.5c-9.7,0-18.3-3.4-19.4-15.2h48.9C413.8,121,414,115.8,414,113.4z M364.6,103.9c0-11.3,6.9-16,13.2-16c6.1,0,12.6,4.7,12.6,16H364.6z'/%3E%3Cpath class='st0' d='M301.1,67.6c-9.8,0-16.1,4.6-19.6,7.8l-1.3-6.2h-22v116.6l25-5.3l0.1-28.3c3.6,2.6,8.9,6.3,17.7,6.3 c17.9,0,34.2-14.4,34.2-46.1C335.1,83.4,318.6,67.6,301.1,67.6z M295.1,136.5c-5.9,0-9.4-2.1-11.8-4.7l-0.1-37.1 c2.6-2.9,6.2-4.9,11.9-4.9c9.1,0,15.4,10.2,15.4,23.3C310.5,126.5,304.3,136.5,295.1,136.5z'/%3E%3Cpolygon class='st0' points='223.8,61.7 248.9,56.3 248.9,36 223.8,41.3 '/%3E%3Crect x='223.8' y='69.3' class='st0' width='25.1' height='87.5'/%3E%3Cpath class='st0' d='M196.9,76.7l-1.6-7.4h-21.6v87.5h25V97.5c5.9-7.7,15.9-6.3,19-5.2v-23C214.5,68.1,202.8,65.9,196.9,76.7z'/%3E%3Cpath class='st0' d='M146.9,47.6l-24.4,5.2l-0.1,80.1c0,14.8,11.1,25.7,25.9,25.7c8.2,0,14.2-1.5,17.5-3.3V135 c-3.2,1.3-19,5.9-19-8.9V90.6h19V69.3h-19L146.9,47.6z'/%3E%3Cpath class='st0' d='M79.3,94.7c0-3.9,3.2-5.4,8.5-5.4c7.6,0,17.2,2.3,24.8,6.4V72.2c-8.3-3.3-16.5-4.6-24.8-4.6 C67.5,67.6,54,78.2,54,95.9c0,27.6,38,23.2,38,35.1c0,4.6-4,6.1-9.6,6.1c-8.3,0-18.9-3.4-27.3-8v23.8c9.3,4,18.7,5.7,27.3,5.7 c20.8,0,35.1-10.3,35.1-28.2C117.4,100.6,79.3,105.9,79.3,94.7z'/%3E%3C/g%3E%3C/svg%3E\");\n}\n\n.stripe-connect.white span::after {\n background-image: url(\"data:image/svg+xml,%3C%3Fxml version='1.0' encoding='utf-8'%3F%3E%3C!-- Generator: Adobe Illustrator 24.0.3, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E%3Csvg version='1.1' id='Layer_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 468 222.5' style='enable-background:new 0 0 468 222.5;' xml:space='preserve'%3E%3Cstyle type='text/css'%3E .st0%7Bfill-rule:evenodd;clip-rule:evenodd;fill:%230A2540;%7D%0A%3C/style%3E%3Cg%3E%3Cpath class='st0' d='M414,113.4c0-25.6-12.4-45.8-36.1-45.8c-23.8,0-38.2,20.2-38.2,45.6c0,30.1,17,45.3,41.4,45.3 c11.9,0,20.9-2.7,27.7-6.5v-20c-6.8,3.4-14.6,5.5-24.5,5.5c-9.7,0-18.3-3.4-19.4-15.2h48.9C413.8,121,414,115.8,414,113.4z M364.6,103.9c0-11.3,6.9-16,13.2-16c6.1,0,12.6,4.7,12.6,16H364.6z'/%3E%3Cpath class='st0' d='M301.1,67.6c-9.8,0-16.1,4.6-19.6,7.8l-1.3-6.2h-22v116.6l25-5.3l0.1-28.3c3.6,2.6,8.9,6.3,17.7,6.3 c17.9,0,34.2-14.4,34.2-46.1C335.1,83.4,318.6,67.6,301.1,67.6z M295.1,136.5c-5.9,0-9.4-2.1-11.8-4.7l-0.1-37.1 c2.6-2.9,6.2-4.9,11.9-4.9c9.1,0,15.4,10.2,15.4,23.3C310.5,126.5,304.3,136.5,295.1,136.5z'/%3E%3Cpolygon class='st0' points='223.8,61.7 248.9,56.3 248.9,36 223.8,41.3 '/%3E%3Crect x='223.8' y='69.3' class='st0' width='25.1' height='87.5'/%3E%3Cpath class='st0' d='M196.9,76.7l-1.6-7.4h-21.6v87.5h25V97.5c5.9-7.7,15.9-6.3,19-5.2v-23C214.5,68.1,202.8,65.9,196.9,76.7z'/%3E%3Cpath class='st0' d='M146.9,47.6l-24.4,5.2l-0.1,80.1c0,14.8,11.1,25.7,25.9,25.7c8.2,0,14.2-1.5,17.5-3.3V135 c-3.2,1.3-19,5.9-19-8.9V90.6h19V69.3h-19L146.9,47.6z'/%3E%3Cpath class='st0' d='M79.3,94.7c0-3.9,3.2-5.4,8.5-5.4c7.6,0,17.2,2.3,24.8,6.4V72.2c-8.3-3.3-16.5-4.6-24.8-4.6 C67.5,67.6,54,78.2,54,95.9c0,27.6,38,23.2,38,35.1c0,4.6-4,6.1-9.6,6.1c-8.3,0-18.9-3.4-27.3-8v23.8c9.3,4,18.7,5.7,27.3,5.7 c20.8,0,35.1-10.3,35.1-28.2C117.4,100.6,79.3,105.9,79.3,94.7z'/%3E%3C/g%3E%3C/svg%3E\");\n}\n\n.mobile-friendly-card {\n @media (max-width: 600px) {\n border-radius: 0;\n }\n}\n\n.mobile-dialog {\n @media (max-width: 600px) {\n margin: 0;\n height: 100%;\n max-height: 100%;\n }\n}\n</style>\n","<template>\n <div>\n <v-card :disabled=\"true\" class=\"mt-5\">\n <div class=\"my-3\">\n <v-img alt=\"Braintree Payment Provider Logo\" max-height=\"25\" src=\"https://s3-us-west-1.amazonaws.com/bt-partner-assets/paypal-braintree.png\"/>\n </div>\n <v-card-text>\n <div v-if=\"!hasBraintree\">\n <img alt=\"Connect with Braintree\" class=\"cursor-pointer\" height=\"44\" src=\"https://s3-us-west-1.amazonaws.com/bt-partner-assets/connect-braintree.png\" width=\"328\" @click=\"braintreeOauthInit\">\n </div>\n <div v-else class=\"media align-items-center border rounded p-3\">\n <img :src=\"`https://ui-avatars.com/api/?name=PP`\" alt=\"Image Description\" class=\"h-10 w-10 rounded-full object-cover mx-1 mr-3\">\n <div class=\"media-body\">\n <h6 class=\"text-hover-primary mb-0\">{{ braintreeEmail }}</h6>\n <small class=\"d-block\">\n <strong>Connected: </strong>{{ formatRentalDate(braintreeCreatedAt) }}</small>\n </div>\n\n <v-menu class=\"flex-row\" offset=\"left\">\n <template v-slot:activator=\"{ props }\">\n <v-btn v-bind=\"props\" variant=\"text\">\n <v-icon>mdi-dots-vertical</v-icon>\n </v-btn>\n </template>\n\n <v-list>\n <v-list-item @click=\"$router.push({ name: 'settings.payment-provider.single', params: { uuid: braintreeUuid }}).catch(() => {})\">\n <v-list-item-title>\n View\n </v-list-item-title>\n </v-list-item>\n <v-list-item @click=\"removeBraintreeConfirmDialog = true\">\n <v-list-item-title>\n Disconnect\n </v-list-item-title>\n </v-list-item>\n </v-list>\n </v-menu>\n </div>\n </v-card-text>\n <v-card-actions>\n <div class=\"small text-gray-600\">\n Braintree provider is currently on closed beta. Contact us if you are interested.\n </div>\n </v-card-actions>\n </v-card>\n\n <v-dialog v-model=\"removeBraintreeConfirmDialog\" max-width=\"350\">\n <v-card>\n <v-card-title class=\"text-h5\">Delete PayPal Connection</v-card-title>\n <v-card-text>\n Are you sure you want to delete your PayPal/Braintree connection?\n </v-card-text>\n <v-card-actions>\n <v-spacer/>\n <v-btn color=\"grey\" size=\"small\" variant=\"text\" @click=\"removeBraintreeConfirmDialog = false\">\n Nevermind\n </v-btn>\n <v-btn color=\"primary\" @click=\"deletePaymentProfile(braintreeProvider.id)\">\n I'm Sure\n </v-btn>\n </v-card-actions>\n </v-card>\n </v-dialog>\n </div>\n</template>\n\n<script lang=\"ts\">\nimport {mapActions, mapGetters} from 'vuex';\nimport {get} from 'lodash';\nimport {EventBus} from '@/plugins/eventBus';\nimport {useDateFormatter} from \"@/composables/useDate\";\n\n\nexport default {\n name: 'BraintreeProviderCard',\n\n setup() {\n const {formatRentalDate} = useDateFormatter();\n return {\n formatRentalDate,\n };\n },\n\n data() {\n return {\n braintreeOauthWindow: null,\n braintreeCheckInterval: null,\n removeBraintreeConfirmDialog: false,\n };\n },\n\n created() {\n EventBus.$on('braintree-oauth-url-create-success', (data) => {\n this.openOauthUrl(data.url);\n });\n EventBus.$on('delete-payment-profile-success', () => {\n this.removeBraintreeConfirmDialog = false;\n this.getPaymentProfiles();\n });\n },\n\n mounted() {\n EventBus.$on('braintree-oauth-success', (data) => {\n if (get(data, 'braintree')) {\n this.braintreeOauthWindow.close();\n clearInterval(this.braintreeCheckInterval);\n }\n });\n },\n\n computed: {\n ...mapGetters({\n paymentProviders: 'providers/paymentProviders',\n }),\n braintreeProvider() {\n return this.paymentProviders.find(provider => provider.provider === 'braintree');\n },\n hasBraintree() {\n return this.braintreeProvider !== undefined;\n },\n braintreeEmail() {\n return get(this.braintreeProvider, 'email');\n },\n braintreeUuid() {\n return get(this.braintreeProvider, 'uuid');\n },\n braintreeCreatedAt() {\n return get(this.braintreeProvider, 'created_at');\n },\n },\n\n methods: {\n ...mapActions({\n getBraintreeOauthUrl: 'braintree/getBraintreeOauthUrl',\n getBraintreeProvider: 'braintree/getBraintreeProvider',\n deletePaymentProfile: 'providers/deletePaymentProfile',\n getPaymentProfiles: 'providers/getPaymentProfiles',\n }),\n braintreeOauthInit() {\n this.getBraintreeOauthUrl();\n },\n openOauthUrl(url) {\n const vm = this;\n\n this.braintreeOauthWindow = window.open(\n url,\n 'Fleetwire.io Braintree Oauth',\n 'scrollbars,status,width=750,height=700',\n );\n\n this.braintreeCheckInterval = setInterval(() => {\n if (this.braintreeOauthWindow.closed) {\n clearInterval(vm.braintreeCheckInterval);\n this.authLoading.stripe_oauth = false;\n }\n vm.getBraintreeProvider();\n }, 1000);\n },\n },\n\n beforeUnmount() {\n EventBus.$off('braintree-oauth-url-create-success');\n EventBus.$off('braintree-oauth-success');\n EventBus.$off('delete-payment-profile-success');\n },\n};\n</script>\n","/*\n * Copyright (c) 2025. Chad and contributors.\n * All rights reserved.\n */\n\nimport {useStore} from 'vuex';\nimport {computed} from 'vue';\n\nexport function useSquare() {\n const store = useStore();\n\n const squareLoading = computed(() => store.getters['square/loading']);\n\n const setSquareLoading = (payload) => {\n return store.commit('square/SET_SQUARE_LOADING', payload);\n }\n\n const saveSquareCode = (payload) => {\n return store.dispatch('square/saveSquareCode', payload);\n }\n\n const getSquareOauthUrl = async () => {\n return await store.dispatch('square/getSquareOauthUrl');\n }\n const getSquareProvider = async () => {\n return await store.dispatch('square/getSquareProvider');\n }\n return {\n squareLoading,\n saveSquareCode,\n getSquareOauthUrl,\n getSquareProvider,\n setSquareLoading,\n }\n}","<template>\n <div>\n <v-card :disabled=\"!canUseSquareIntegration\" class=\"mt-5\">\n <div class=\"my-3\">\n <v-img alt=\"Braintree Payment Provider Logo\" max-height=\"50\" src=\"/images/logo/Square_LogoLockup_Black.png\"/>\n </div>\n <v-card-text>\n <div v-if=\"!hasSquare\">\n <a class=\"square-connect slate\" @click=\"squareOauthInit\">\n <span>Connect with</span>\n </a>\n </div>\n <div v-else class=\"flex items-center border rounded p-3\">\n <div class=\"flex-shrink-0\">\n <img :src=\"`https://ui-avatars.com/api/?name=SQ`\" alt=\"Image Description\" class=\"h-10 w-10 rounded-full object-cover mx-1 mr-3\">\n </div>\n <div class=\"flex-1 min-w-0 ms-4\">\n <h6 class=\"text-hover-primary mb-0\">{{ squareEmail }}</h6>\n <small class=\"d-block\">\n <strong>Connected: </strong>{{ formatRentalDate(squareCreatedAt) }}</small>\n </div>\n\n <div class=\"inline-flex items-center text-base font-semibold text-gray-900 dark:text-white\">\n <v-menu>\n <template v-slot:activator=\"{ props }\">\n <v-btn v-bind=\"props\" variant=\"text\">\n <v-icon>mdi-dots-vertical</v-icon>\n </v-btn>\n </template>\n\n <v-list>\n <!-- <v-list-item @click=\"$router.push({ name: 'settings.payment-provider.single', params: { uuid: squareUuid }}).catch(() => {})\">-->\n <!-- <v-list-item-title>-->\n <!-- View-->\n <!-- </v-list-item-title>-->\n <!-- </v-list-item>-->\n <v-list-item @click=\"removeSquareConfirmDialog = true\">\n <v-list-item-title>\n Disconnect\n </v-list-item-title>\n </v-list-item>\n </v-list>\n </v-menu>\n </div>\n </div>\n </v-card-text>\n </v-card>\n\n <v-dialog v-model=\"removeSquareConfirmDialog\" max-width=\"350\">\n <v-card>\n <v-card-title class=\"text-h5\">Delete Square Connection</v-card-title>\n <v-card-text>\n Are you sure you want to delete your Square connection?\n </v-card-text>\n <v-card-actions>\n <v-spacer/>\n <v-btn color=\"grey\" size=\"small\" variant=\"text\" @click=\"removeSquareConfirmDialog = false\">\n Nevermind\n </v-btn>\n <v-btn color=\"primary\" @click=\"deletePaymentProfileCommit(squareUuid)\">\n I'm Sure\n </v-btn>\n </v-card-actions>\n </v-card>\n </v-dialog>\n </div>\n</template>\n\n<script lang=\"ts\" setup>\nimport {computed, ref} from 'vue';\nimport {EventBus} from '@/plugins/eventBus';\nimport {useDateFormatter} from '@/composables/useDate';\nimport {useAppFeatures} from '@/composables/useAppFeatures';\nimport {Provider} from '@/store/modules/providers';\nimport {useProviders} from '@/composables/useProviders';\nimport {useSquare} from '@/composables/useSquare';\n\n\nconst {paymentProviders, deletePaymentProfile, getPaymentProfiles} = useProviders();\nconst {formatRentalDate} = useDateFormatter();\nconst {canUseSquareIntegration} = useAppFeatures();\nconst {\n getSquareOauthUrl,\n getSquareProvider,\n setSquareLoading,\n} = useSquare();\n\nconst squareOauthWindow = ref(null);\nconst squareCheckInterval = ref(null);\nconst removeSquareConfirmDialog = ref(false);\n\n\nconst squareProvider = computed(() => {\n return paymentProviders.value.find((provider: Provider) => provider.provider === 'square');\n});\nconst hasSquare = computed(() => {\n return squareProvider.value !== undefined;\n});\n\nEventBus.$on('square-oauth-url-create-success', (data) => {\n openOauthUrl(data.url);\n});\nEventBus.$on('delete-payment-profile-success', () => {\n removeSquareConfirmDialog.value = false;\n getPaymentProfiles();\n});\n\nconst squareEmail = computed(() => {\n return squareProvider.value?.email;\n});\n\nconst squareUuid = computed(() => {\n return squareProvider.value?.uuid;\n});\nconst squareCreatedAt = computed(() => {\n return squareProvider.value?.created_at;\n});\n\nconst squareOauthInit = () => {\n getSquareOauthUrl().then((response) => {\n if (response.data.url) {\n openOauthUrl(response.data.url);\n }\n });\n};\nconst openOauthUrl = (url) => {\n\n squareOauthWindow.value = window.open(\n url,\n 'Fleetwire.io Square Oauth',\n 'scrollbars,status,width=750,height=700',\n );\n\n squareCheckInterval.value = setInterval(() => {\n if (squareOauthWindow.value.closed) {\n clearInterval(squareCheckInterval.value);\n setSquareLoading({\n subject: 'square_oauth',\n loading: false,\n })\n\n }\n getSquareProvider().then((response) => {\n if (response.data.square) {\n squareOauthWindow.value.close();\n clearInterval(squareCheckInterval.value);\n getPaymentProfiles();\n }\n });\n }, 1000);\n};\n\nconst deletePaymentProfileCommit = (uuid: string) => {\n deletePaymentProfile(uuid).then(() => {\n removeSquareConfirmDialog.value = false;\n getPaymentProfiles();\n });\n};\n</script>\n\n<style scoped>\n.square-connect a {\n text-decoration: none;\n}\n\n.square-connect {\n background: #635bff;\n display: inline-block;\n height: 38px;\n text-decoration: none;\n width: 180px;\n\n border-radius: 4px;\n -moz-border-radius: 4px;\n -webkit-border-radius: 4px;\n\n user-select: none;\n -moz-user-select: none;\n -webkit-user-select: none;\n -ms-user-select: none;\n\n -webkit-font-smoothing: antialiased;\n}\n\n.square-connect span {\n color: #ffffff;\n display: block;\n font-family: sohne-var, \"Helvetica Neue\", Arial, sans-serif;\n font-size: 15px;\n font-weight: 400;\n line-height: 14px;\n padding: 11px 0 0 24px;\n position: relative;\n text-align: left;\n}\n\n.square-connect:hover {\n background: #7a73ff;\n}\n\n.square-connect.slate {\n background: #000000;\n}\n\n.square-connect.slate:hover {\n background: #425466;\n}\n\n.square-connect.white {\n background: #ffffff;\n}\n\n.square-connect.white span {\n color: #0a2540;\n}\n\n.square-connect.white:hover {\n background: #f6f9fc;\n}\n\n.square-connect span::after {\n background-repeat: no-repeat;\n background-size: 70px;\n content: \"\";\n height: 30px;\n left: 63%;\n position: absolute;\n top: 20%;\n width: 75px;\n}\n\n/* Logos */\n.square-connect span::after {\n background-image: url(https://tenant.fleetwire.io/images/logo/Square_LogoLockup_White.png);\n}\n\n\n</style>\n","<template>\n <div class=\"space-y-6\">\n <div class=\"md:grid md:grid-cols-3 md:gap-6\">\n <div class=\"md:col-span-1\">\n <div class=\"px-4 sm:px-0\">\n <div class=\"flex items-center gap-2\">\n <h3 class=\"text-lg font-medium text-gray-900 dark:text-gray-100\">\n Stripe\n </h3>\n <span class=\"recommended\">Recommended</span>\n </div>\n <div class=\"mt-1 text-sm text-gray-600 dark:text-gray-400\">\n Accept payments through Stripe in your online store and via payment requests. Stripe enables you to process\n credit cards, debit cards, and other popular payment methods.<br><br>\n\n You can also securely charge cards or place authorization holds directly within Fleetwire.<br>\n <the-help-link url=\"https://help.fleetwire.io/en/article/integrating-with-stripe-747u5f/?bust=1678309814404\"/>\n </div>\n </div>\n </div>\n <div class=\"mt-4 md:mt-0 md:col-span-2\">\n <StripeProviderCard/>\n </div>\n </div>\n\n <v-divider class=\"my-6\"/>\n\n <div class=\"md:grid md:grid-cols-3 md:gap-6\">\n <div class=\"md:col-span-1\">\n <div class=\"px-4 sm:px-0\">\n <div class=\"flex items-center gap-2\">\n <h3 class=\"text-lg font-medium text-gray-900 dark:text-gray-100\">\n Square\n </h3>\n <span class=\"under-development__red\">Beta</span>\n </div>\n <div class=\"mt-1 text-sm text-gray-600 dark:text-gray-400\">\n Accept payments through Square in your online store and via payment requests. Square enables you to process\n credit cards, debit cards, and other popular payment methods.\n <the-help-link\n url=\"https://help.fleetwire.io/en/article/integrating-with-square-1hg2hi2/?bust=1689725719338\"\n />\n <v-alert\n v-if=\"!canUseSquareIntegration\"\n class=\"mt-5\"\n color=\"info\"\n density=\"compact\"\n icon=\"mdi-fire\"\n variant=\"outlined\"\n >\n <div class=\"flex flex-col sm:flex-row gap-2\">\n <div class=\"grow\">\n Coming soon\n </div>\n <div class=\"shrink\">\n <v-btn v-if=\"!hasWaitlistRequest('SquarePaymentProvider')\" size=\"small\" @click=\"addFeatureWaitlist({feature: 'SquarePaymentProvider'})\">\n Notify Me\n </v-btn>\n <v-btn v-else :disabled=\"true\" size=\"small\">Will notify</v-btn>\n </div>\n </div>\n </v-alert>\n </div>\n </div>\n </div>\n <div class=\"mt-4 md:mt-0 md:col-span-2\">\n <SquareProviderCard/>\n </div>\n </div>\n\n <v-divider class=\"my-6\"/>\n\n <div class=\"md:grid md:grid-cols-3 md:gap-6\">\n <div class=\"md:col-span-1\">\n <div class=\"px-4 sm:px-0\">\n <div class=\"flex items-center gap-2\">\n <h3 class=\"text-lg font-medium text-gray-900 dark:text-gray-100\">\n PayPal\n </h3>\n <span class=\"under-development__yellow\">Under Development</span>\n </div>\n <div class=\"mt-1 text-sm text-gray-600 dark:text-gray-400\">\n Accept payments through PayPal or any major credit/debit card for online purchases and payment requests.\n <the-help-link url=\"https://help.fleetwire.io/en/article/integrating-with-paypal-14wog9m/?bust=1678311944038\"/>\n\n <v-alert\n v-if=\"!canUseBraintreeIntegration\"\n class=\"mt-5\"\n color=\"info\"\n density=\"compact\"\n icon=\"mdi-fire\"\n variant=\"outlined\"\n >\n <div class=\"flex flex-col sm:flex-row gap-2\">\n <div class=\"grow\">\n Coming soon\n </div>\n <div class=\"shrink\">\n <v-btn v-if=\"!hasWaitlistRequest('BraintreePaymentProvider')\" size=\"small\" variant=\"tonal\" @click=\"addFeatureWaitlist({feature: 'BraintreePaymentProvider'})\">\n Notify Me\n </v-btn>\n <v-btn v-else :disabled=\"true\" size=\"small\">Will notify</v-btn>\n </div>\n </div>\n </v-alert>\n </div>\n </div>\n </div>\n <div class=\"mt-4 md:mt-0 md:col-span-2\">\n <BraintreeProviderCard/>\n </div>\n </div>\n </div>\n</template>\n\n<script lang=\"ts\" setup>\nimport StripeProviderCard from '@/components/dashboard/settings/providers/StripeProviderCard.vue';\nimport BraintreeProviderCard from '@/components/dashboard/settings/providers/BraintreeProviderCard.vue';\nimport SquareProviderCard from '@/components/dashboard/settings/providers/SquareProviderCard.vue';\nimport {useAppFeatures} from '@/composables/useAppFeatures';\nimport {onBeforeMount} from 'vue';\n\nconst {\n hasWaitlistRequest,\n addFeatureWaitlist,\n getFeatureWaitlist,\n canUseBraintreeIntegration,\n canUseSquareIntegration,\n} = useAppFeatures();\n\nonBeforeMount(() => {\n getFeatureWaitlist();\n});\n</script>\n\n<style>\n.recommended {\n color: #6c36f4 !important;\n font-weight: 600;\n font-size: 12px;\n padding: 2px 8px;\n border: 1px solid #6c36f4;\n border-radius: 3px;\n background-color: #ebe7f5;\n height: 22px;\n white-space: nowrap;\n}\n\n.under-development__yellow {\n color: #f7b500 !important;\n font-weight: 600;\n font-size: 12px;\n padding: 2px 8px;\n border: 1px solid #f7b500;\n border-radius: 3px;\n background-color: #fff8e1;\n height: 22px;\n white-space: nowrap;\n}\n\n.under-development__red {\n color: #f44336 !important;\n font-weight: 600;\n font-size: 12px;\n padding: 2px 8px;\n border: 1px solid #f44336;\n border-radius: 3px;\n background-color: #ffebee;\n height: 22px;\n white-space: nowrap;\n}\n</style>\n","<template>\n <div>\n Provider: {{ profileProvider }} <br>\n UID: {{ profileUid }} <br>\n Created: {{ formatRentalDate(profileCreated) }} <br>\n Active: {{ profileActive }} <br>\n\n <v-card variant=\"outlined\">\n <v-card-text>\n <v-btn @click=\"testConnection()\">Test Connection</v-btn>\n </v-card-text>\n\n <div id=\"dropin-container\"></div>\n </v-card>\n </div>\n</template>\n\n<script lang=\"ts\">\nimport {mapActions} from 'vuex';\nimport {get} from 'lodash';\nimport {EventBus} from '@/plugins/eventBus';\nimport {useDateFormatter} from \"@/composables/useDate\";\n\n\nexport default {\n name: 'SinglePaymentProvider',\n\n setup() {\n const {formatRentalDate} = useDateFormatter();\n return {\n formatRentalDate,\n };\n },\n\n data() {\n return {\n paymentProfile: null,\n };\n },\n\n mounted() {\n this.getPaymentProfile(this.$route.params.uuid);\n\n EventBus.$on('get-payment-profile-success', (profile) => {\n this.paymentProfile = profile;\n });\n this.addJs();\n // check for braintree js id every second\n // if it exists, then we can load the braintree dropin\n this.checkJs();\n },\n\n computed: {\n profileProvider() {\n return get(this.paymentProfile, 'provider');\n },\n profileUid() {\n return get(this.paymentProfile, 'uid');\n },\n profileCreated() {\n return get(this.paymentProfile, 'created_at');\n },\n profileActive() {\n return get(this.paymentProfile, 'active');\n },\n },\n\n methods: {\n ...mapActions({\n getPaymentProfile: 'providers/getPaymentProfile',\n braintreeTestPayment: 'braintree/testPayment',\n squareTestPayment: 'square/testPayment',\n }),\n checkJs() {\n this.braintreeCheckInterval = setInterval(() => {\n console.dir('checking');\n if (document.getElementById('FWBraintreeJS')) {\n clearInterval(this.braintreeCheckInterval);\n\n braintree.dropin.create({\n authorization: 'sandbox_bnrhnp5x_yytkcsfc4sdbbspv',\n container: '#dropin-container',\n }).then((instance) => {\n console.dir('instance');\n console.dir(instance);\n });\n }\n }, 1000);\n },\n addJs() {\n if (!document.getElementById('FWStripeJS')) {\n const stripeScript = document.createElement('script');\n stripeScript.setAttribute('src', 'https://js.braintreegateway.com/web/dropin/1.34.0/js/dropin.min.js');\n stripeScript.async = true;\n stripeScript.id = 'FWBraintreeJS';\n document.head.appendChild(stripeScript);\n }\n },\n testConnection() {\n console.dir('squareTestPayment');\n this.squareTestPayment();\n },\n },\n\n beforeUnmount() {\n EventBus.$off('get-payment-profile-success');\n },\n};\n</script>\n","<template>\n <div>\n <v-alert\n class=\"mb-5\"\n color=\"info\"\n density=\"compact\"\n icon=\"mdi-fire\"\n variant=\"outlined\"\n >\n <div class=\"flex\">\n <div class=\"grow col\">\n Coming soon - This is an experimental feature and is in active development & in beta.\n </div>\n <div class=\"shrink col\">\n <v-btn v-if=\"!hasWaitlistRequest('CommissionedPartners')\" size=\"small\" @click=\"addFeatureWaitlist({feature: 'CommissionedPartners'})\">\n Notify Me\n </v-btn>\n <v-btn v-else disabled size=\"small\">Will notify</v-btn>\n </div>\n </div>\n </v-alert>\n\n <v-card class=\"mb-5\">\n <div class=\"beta-ribbon ribbon-top-left\">\n <span>Beta</span>\n </div>\n <v-card-text>\n <v-switch\n v-model=\"showOnMainMenu\"\n density=\"compact\"\n hint=\"Show the commission icon/link on the main menu\"\n inset\n label=\"Show on main menu\"\n persistent-hint\n @update:model-value=\"toggleShowCommissionPartnersOnMainMenu(showOnMainMenu)\"\n ></v-switch>\n </v-card-text>\n </v-card>\n <v-card>\n <div class=\"beta-ribbon ribbon-top-left\">\n <span>Beta</span>\n </div>\n <v-card-title>\n <div class=\"flex\">\n <FeatureTitle\n featurePremium\n title=\"Commission Partners\"\n />\n <v-btn class=\"ml-2\" variant=\"text\" @click=\"openDialog()\">\n <v-icon size=\"small\">mdi-help-circle</v-icon>\n </v-btn>\n <v-spacer/>\n <v-btn variant=\"text\" @click=\"viewCommissionPartnerDialog = true;\">\n <v-icon>mdi-plus</v-icon>\n Add Partner\n </v-btn>\n </div>\n </v-card-title>\n <v-card-text>\n <div class=\"mt-5\">\n <v-data-table\n v-if=\"commissionPartners.length > 0\"\n :headers=\"headers\"\n :items=\"commissionPartners\"\n :items-per-page=\"10\"\n >\n <template v-slot:item.name=\"{ item }\">\n <router-link :to=\"{ name: 'commission.partner.single', params: { partner_uuid: item.uuid } }\" class=\"text-dark ml-1\">\n {{ item.name }}\n </router-link>\n </template>\n <template v-slot:item.commission_type=\"{ item }\">\n <span v-if=\"item.commission_type === 'percentage'\">Percentage</span>\n <span v-if=\"item.commission_type === 'amount'\">Amount</span>\n </template>\n <template v-slot:item.commission_amount=\"{ item }\">\n <span v-if=\"item.commission_type === 'percentage'\">{{ item.commission_amount }} %</span>\n <span v-if=\"item.commission_type === 'amount'\">{{ formatMoneyDisplayV2(item.commission_amount) }}</span>\n </template>\n <template v-slot:item.actions=\"{ item }\">\n <v-icon\n class=\"mr-2\"\n size=\"small\"\n @click=\"editItem(item)\"\n >\n mdi-pencil\n </v-icon>\n <v-icon size=\"small\" @click=\"deleteItem(item)\">\n mdi-delete\n </v-icon>\n </template>\n </v-data-table>\n <div v-else>No commission partners</div>\n </div>\n </v-card-text>\n </v-card>\n\n <v-dialog v-model=\"viewCommissionPartnerDialog\" width=\"400\">\n <v-card :disabled=\"partnersLoading.create\">\n <v-card-title>New commission partner</v-card-title>\n <v-divider opacity=\"50\"/>\n <v-card-text>\n <v-form>\n <v-text-field\n v-model=\"commissionPartner.name\"\n label=\"Name\"\n name=\"name\"\n variant=\"outlined\"\n ></v-text-field>\n <v-text-field\n v-model=\"commissionPartner.phone\"\n label=\"Phone\"\n name=\"phone\"\n variant=\"outlined\"\n ></v-text-field>\n <v-text-field\n v-model=\"commissionPartner.email\"\n label=\"Email\"\n variant=\"outlined\"\n ></v-text-field>\n <div>\n <div>\n <v-text-field\n v-model=\"commissionAmount\"\n :append-icon=\"commissionPartner.commission_type === 'percentage' ? 'mdi-percent':''\"\n :label=\"commissionPartner.commission_type === 'percentage' ? 'Percentage':'Amount'\"\n :prefix=\"commissionPartner.commission_type === 'amount' ? companyMoneyTextInputSettings.prefix: ''\"\n :suffix=\"commissionPartner.commission_type === 'amount' ? companyMoneyTextInputSettings.suffix: ''\"\n type=\"number\"\n variant=\"outlined\"\n ></v-text-field>\n </div>\n <div>\n <v-radio-group v-model=\"commissionPartner.commission_type\" class=\"mt-0\" density=\"compact\" hide-details @update:model-value=\"updateAmountFormat()\">\n <v-radio label=\"Percentage\" value=\"percentage\"></v-radio>\n <v-radio label=\"Amount\" value=\"amount\"></v-radio>\n </v-radio-group>\n </div>\n </div>\n\n </v-form>\n </v-card-text>\n <v-divider opacity=\"50\"/>\n <v-card-actions>\n <v-spacer/>\n <v-btn color=\"grey\" size=\"small\" variant=\"text\" @click=\"viewCommissionPartnerDialog = false\">\n Nevermind\n </v-btn>\n <v-btn v-if=\"commissionPartner.mode === 'edit'\" :loading=\"partnersLoading.update\" color=\"primary\" @click=\"updateCommissionPartner(commissionPartner)\">\n Update\n </v-btn>\n <v-btn v-else :loading=\"partnersLoading.create\" color=\"primary\" @click=\"createCommissionPartner(commissionPartner)\">\n Create\n </v-btn>\n </v-card-actions>\n </v-card>\n </v-dialog>\n\n <v-dialog v-model=\"deleteCommissionPartnerDialog\" max-width=\"350\">\n <v-card :disabled=\"partnersLoading.delete\">\n <v-card-title class=\"text-h5\">Delete Commission Partner</v-card-title>\n <v-divider opacity=\"50\"/>\n <v-card-text>\n Are you sure you want to delete this commission partner? <br>\n <strong>{{ commissionPartner.name }}</strong>\n </v-card-text>\n <v-divider opacity=\"50\"/>\n <v-card-actions>\n <v-spacer/>\n <v-btn color=\"grey\" size=\"small\" variant=\"text\" @click=\"deleteCommissionPartnerDialog = false\">\n Nevermind\n </v-btn>\n <v-btn :loading=\"partnersLoading.delete\" color=\"red text-white\" @click=\"deleteCommissionPartner(commissionPartner)\">\n I'm Sure\n </v-btn>\n </v-card-actions>\n </v-card>\n </v-dialog>\n\n <WhatAreCommissionsDialog\n :visible=\"isDialogVisible\"\n @update:visible=\"isDialogVisible = $event\"\n />\n </div>\n</template>\n\n<script lang=\"ts\" setup>\nimport {computed, defineAsyncComponent, onBeforeMount, ref, watch} from 'vue';\nimport {useStore} from 'vuex';\nimport getDefaultMeta from '@/utils/meta';\nimport {useMoneyFormatter} from '@/composables/useMoneyFormatter';\nimport {useAppFeatures} from '@/composables/useAppFeatures';\nimport {useAuth} from '@/composables/useAuth';\nimport {useCompany} from '@/composables/useCompany';\nimport type {CommissionPartner} from '@/store/modules/commission-partners';\n\nconst FeatureTitle = defineAsyncComponent(() => import('@/components/dashboard/FeatureTitle.vue'));\nconst WhatAreCommissionsDialog = defineAsyncComponent(() => import('@/components/dashboard/dialogs/WhatAreCommissionsDialog.vue'));\n\nconst store = useStore();\nconst {hasWaitlistRequest, addFeatureWaitlist} = useAppFeatures();\nconst {formatMoneyDisplayV2, companyMoneyTextInputSettings} = useMoneyFormatter();\nconst {fetchSession} = useAuth();\nconst {defaultMeta} = useCompany()\n\nconst viewCommissionPartnerDialog = ref(false);\nconst deleteCommissionPartnerDialog = ref(false);\nconst editedIndex = ref(null);\nconst showOnMainMenu = ref(false);\nconst commissionPartner = ref<CommissionPartner>({\n active: true,\n name: '',\n phone: '',\n email: '',\n commission_amount: 0,\n commission_type: 'percentage',\n mode: 'create',\n});\n\nconst headers = [\n {title: 'Name', key: 'name'},\n {title: 'Phone', key: 'phone'},\n {title: 'Email', key: 'email'},\n {title: 'Type', key: 'commission_type'},\n {title: 'Amount', key: 'commission_amount'},\n {title: 'Actions', key: 'actions', sortable: false},\n];\n\nconst commissionPartners = computed<CommissionPartner[]>(() => store.getters['commissionPartners/commissionPartners']);\nconst partnersLoading = computed(() => store.getters['commissionPartners/loading']);\n\nconst toggleShowCommissionPartnersOnMainMenu = (showOnMainMenu: boolean) => {\n store.dispatch('commissionPartners/toggleShowOnMainMenu', showOnMainMenu).then(() => {\n fetchSession();\n });\n};\nconst getFeatureWaitlist = () => {\n store.dispatch('app/getFeatureWaitlist', {feature: 'CommissionedPartners'});\n};\n\nconst getCommissionPartners = () => {\n store.dispatch('commissionPartners/getCommissionPartners');\n};\nconst updateCommissionPartner = (commissionPartner: CommissionPartner) => {\n store.dispatch('commissionPartners/updateCommissionPartner', commissionPartner).then(() => {\n getCommissionPartners();\n viewCommissionPartnerDialog.value = false;\n resetCommissionPartner();\n });\n};\nconst deleteCommissionPartner = (commissionPartner: CommissionPartner) => {\n store.dispatch('commissionPartners/deleteCommissionPartner', commissionPartner).then(() => {\n getCommissionPartners();\n deleteCommissionPartnerDialog.value = false;\n resetCommissionPartner();\n });\n};\n\nconst createCommissionPartner = (commissionPartner: CommissionPartner) => {\n store.dispatch('commissionPartners/createCommissionPartner', commissionPartner).then(() => {\n getCommissionPartners();\n viewCommissionPartnerDialog.value = false;\n resetCommissionPartner();\n });\n};\n\nconst resetCommissionPartner = () => {\n commissionPartner.value = {\n active: true,\n name: '',\n phone: '',\n email: '',\n commission_amount: 0,\n commission_type: 'percentage',\n mode: 'create',\n };\n};\n\n\nconst isDialogVisible = ref(false);\n\nconst openDialog = () => {\n isDialogVisible.value = true;\n};\n\nconst updateAmountFormat = () => {\n if (commissionPartner.value.commission_type === 'amount') {\n commissionPartner.value.commission_amount *= 100;\n } else if (commissionPartner.value.commission_type === 'percentage') {\n commissionPartner.value.commission_amount /= 100;\n }\n};\n\nconst editItem = (item: CommissionPartner) => {\n editedIndex.value = store.getters['commissionPartners/commissionPartners'].indexOf(item);\n commissionPartner.value = Object.assign({}, item);\n commissionPartner.value.mode = 'edit';\n viewCommissionPartnerDialog.value = true;\n};\n\nconst deleteItem = (item: CommissionPartner) => {\n editedIndex.value = store.getters['commissionPartners/commissionPartners'].indexOf(item);\n commissionPartner.value = Object.assign({}, item);\n deleteCommissionPartnerDialog.value = true;\n};\n\nconst commissionAmount = computed({\n get() {\n const amount = +commissionPartner.value.commission_amount;\n if (amount === 0) return 0;\n if (commissionPartner.value.commission_type === 'amount') {\n return amount * 0.01;\n }\n return amount;\n },\n set(amount: number) {\n if (commissionPartner.value.commission_type === 'amount') {\n commissionPartner.value.commission_amount = amount * 100;\n } else {\n commissionPartner.value.commission_amount = amount;\n }\n },\n});\n\nwatch(defaultMeta, () => {\n const showOnMainMenuData = getDefaultMeta('show_commission_main_menu');\n showOnMainMenu.value = showOnMainMenuData === 1 || showOnMainMenuData === '1';\n});\n\nonBeforeMount(() => {\n getFeatureWaitlist();\n\n const showOnMainMenuData = getDefaultMeta('show_commission_main_menu');\n\n showOnMainMenu.value = showOnMainMenuData === 1 || showOnMainMenuData === '1';\n getCommissionPartners();\n});\n</script>\n","<template>\n <div>\n <FeatureTitle\n featurePremium\n title=\"Webhooks\"\n />\n <div class=\"grid grid-cols-1 my-5\">\n <div>\n <div v-if=\"webhooksLoading.webhooks\">Loading...</div>\n <v-card v-else-if=\"webhookEndpoints.length > 0\" :disabled=\"!includedInSubscription('webhooks')\">\n <v-card-title>\n <div class=\"flex\">\n Hosted endpoints\n <v-spacer/>\n <v-btn :to=\"{ name: 'settings.providers.webhooks.create' }\" size=\"small\">\n <v-icon class=\"mr-2\" size=\"small\">mdi-plus</v-icon>\n Add Endpoint\n </v-btn>\n </div>\n </v-card-title>\n\n <v-card-text>\n <table class=\"w-full text-sm text-left text-gray-500 dark:text-gray-400\">\n <thead class=\"text-xs text-gray-700 uppercase bg-gray-50 dark:bg-gray-700 dark:text-gray-400\">\n <tr>\n <th class=\"px-6 py-3\" scope=\"col\">\n URL\n </th>\n <th class=\"px-6 py-3\" scope=\"col\">\n STATUS\n </th>\n <th class=\"px-6 py-3\" scope=\"col\">\n </th>\n </tr>\n </thead>\n <tbody>\n <tr\n v-for=\"item in webhookEndpoints\"\n :key=\"item.uuid\"\n class=\"border align-content-center justify-center\"\n >\n <td class=\"px-6 py-4 font-medium text-gray-900 whitespace-nowrap dark:text-white\" scope=\"row\">\n {{ item.url }}\n </td>\n <td class=\"px-6 py-3 cursor-pointer align-middle\">\n <span v-if=\"webhookEndpointStatus(item) === 'Enabled'\" class=\"badge badge-success\">\n Enabled\n </span>\n <span v-if=\"webhookEndpointStatus(item) === 'Disabled'\" class=\"badge badge-danger\">\n Disabled\n </span>\n </td>\n <td class=\"px-6 py-3 align-middle\">\n <v-btn size=\"small\" variant=\"text\" @click=\"editWebhook(item)\">View</v-btn>\n </td>\n </tr>\n </tbody>\n </table>\n </v-card-text>\n </v-card>\n\n <div v-else class=\"h-100 row align-items-center\">\n <div class=\"col text-center\">\n <div class=\"w-100 mb-5\">\n <svg data-name=\"Layer 1\" height=\"200\" viewBox=\"0 0 888 710.80704\"\n width=\"100%\" xmlns=\"http://www.w3.org/2000/svg\"><title>server_cluster</title>\n <path\n d=\"M600.93555,699.40352a260.06372,260.06372,0,1,1,183.89355-76.1709A258.36518,258.36518,0,0,1,600.93555,699.40352Zm0-518.12891c-142.29688,0-258.06446,115.76758-258.06446,258.06494s115.76758,258.064,258.06446,258.064S859,581.63692,859,439.33955,743.23242,181.27461,600.93555,181.27461Z\"\n fill=\"#ccc\" transform=\"translate(-156 -94.59648)\"/>\n <rect fill=\"#2f2e41\" height=\"195\" transform=\"translate(1051.40391 -87.19257) rotate(90)\" width=\"262\"\n x=\"469\" y=\"509.90391\"/>\n <rect fill=\"#3f3d56\" height=\"104\" width=\"262\" x=\"313\" y=\"373.80743\"/>\n <rect fill=\"#3f3d56\" height=\"104\" width=\"262\" x=\"313\" y=\"489.80743\"/>\n <rect fill=\"#3f3d56\" height=\"104\" width=\"262\" x=\"313\" y=\"605.80743\"/>\n <rect fill=\"#73b18a\" height=\"16\" width=\"262\" x=\"313\" y=\"417.90372\"/>\n <rect fill=\"#73b18a\" height=\"16\" width=\"262\" x=\"313\" y=\"533.90372\"/>\n <rect fill=\"#73b18a\" height=\"16\" width=\"262\" x=\"313\" y=\"649.90372\"/>\n <circle cx=\"524\" cy=\"388.80743\" fill=\"#73b18a\" r=\"6\"/>\n <circle cx=\"545\" cy=\"388.80743\" fill=\"#73b18a\" r=\"6\"/>\n <circle cx=\"566\" cy=\"388.80743\" fill=\"#73b18a\" r=\"6\"/>\n <circle cx=\"524\" cy=\"502.80743\" fill=\"#73b18a\" r=\"6\"/>\n <circle cx=\"545\" cy=\"502.80743\" fill=\"#73b18a\" r=\"6\"/>\n <circle cx=\"566\" cy=\"502.80743\" fill=\"#73b18a\" r=\"6\"/>\n <circle cx=\"524\" cy=\"616.80743\" fill=\"#73b18a\" r=\"6\"/>\n <circle cx=\"545\" cy=\"616.80743\" fill=\"#73b18a\" r=\"6\"/>\n <circle cx=\"566\" cy=\"616.80743\" fill=\"#73b18a\" r=\"6\"/>\n <rect fill=\"#3f3d56\" height=\"2\" width=\"888\" y=\"708.80704\"/>\n <path\n d=\"M397.8787,365.66116v185.9917a14.67525,14.67525,0,0,1-14.67227,14.67231H310.928a14.67656,14.67656,0,0,1-14.6784-14.67231V365.66116a14.67655,14.67655,0,0,1,14.6784-14.67228h8.76786a6.9778,6.9778,0,0,0,6.4551,9.60614h41.20843a6.97774,6.97774,0,0,0,6.45506-9.60614h9.392A14.67524,14.67524,0,0,1,397.8787,365.66116Z\"\n fill=\"#e6e6e6\" transform=\"translate(-156 -94.59648)\"/>\n <rect fill=\"#fff\" height=\"128\" width=\"92\" x=\"145.06414\" y=\"291.91002\"/>\n <rect fill=\"#e6e6e6\" height=\"2.09827\" width=\"36.71978\" x=\"171.18557\" y=\"379.92719\"/>\n <rect fill=\"#73b18a\" height=\"2.09827\" width=\"56.81724\" x=\"171.14869\" y=\"387.63152\"/>\n <rect fill=\"#e6e6e6\" height=\"2.09827\" width=\"44.5883\" x=\"171.14869\" y=\"394.89011\"/>\n <rect fill=\"#e6e6e6\" height=\"2.09827\" width=\"26.22841\" x=\"171.14869\" y=\"402.1487\"/>\n <rect fill=\"#e6e6e6\" height=\"2.09827\" width=\"39.34262\" x=\"171.14869\" y=\"409.40729\"/>\n <rect fill=\"#e6e6e6\" height=\"4.19655\" width=\"4.19655\" x=\"154.53324\" y=\"379.32379\"/>\n <rect fill=\"#73b18a\" height=\"4.19655\" width=\"4.19655\" x=\"154.53324\" y=\"386.58238\"/>\n <rect fill=\"#e6e6e6\" height=\"4.19655\" width=\"4.19655\" x=\"154.53324\" y=\"393.84097\"/>\n <rect fill=\"#e6e6e6\" height=\"4.19655\" width=\"4.19655\" x=\"154.53324\" y=\"401.09956\"/>\n <rect fill=\"#e6e6e6\" height=\"4.19655\" width=\"4.19655\" x=\"154.53324\" y=\"408.35815\"/>\n <rect fill=\"#e6e6e6\" height=\"36.99753\" width=\"36.99753\" x=\"172.75082\" y=\"307.91002\"/>\n <rect fill=\"#e6e6e6\" height=\"157.47494\" width=\"245.88383\" x=\"321.11058\" y=\"0.13939\"/>\n <rect fill=\"#fff\" height=\"77.03517\" width=\"203.86136\" x=\"339.64671\" y=\"44.19534\"/>\n <rect fill=\"#e6e6e6\" height=\"2.79582\" width=\"48.92684\" x=\"376.78939\" y=\"57.54179\"/>\n <rect fill=\"#73b18a\" height=\"2.79582\" width=\"75.70547\" x=\"376.74025\" y=\"67.80733\"/>\n <rect fill=\"#e6e6e6\" height=\"2.79582\" width=\"59.41117\" x=\"376.74025\" y=\"77.47895\"/>\n <rect fill=\"#e6e6e6\" height=\"2.79582\" width=\"34.94775\" x=\"376.74025\" y=\"87.15058\"/>\n <rect fill=\"#e6e6e6\" height=\"2.79582\" width=\"52.42162\" x=\"376.74025\" y=\"96.8222\"/>\n <rect fill=\"#e6e6e6\" height=\"5.59164\" width=\"5.59164\" x=\"354.60119\" y=\"56.7378\"/>\n <rect fill=\"#73b18a\" height=\"5.59164\" width=\"5.59164\" x=\"354.60119\" y=\"66.40942\"/>\n <rect fill=\"#e6e6e6\" height=\"5.59164\" width=\"5.59164\" x=\"354.60119\" y=\"76.08104\"/>\n <rect fill=\"#e6e6e6\" height=\"5.59164\" width=\"5.59164\" x=\"354.60119\" y=\"85.75267\"/>\n <rect fill=\"#e6e6e6\" height=\"5.59164\" width=\"5.59164\" x=\"354.60119\" y=\"95.42429\"/>\n <rect fill=\"#e6e6e6\" height=\"50.05873\" width=\"50.05873\" x=\"483.44507\" y=\"53.8475\"/>\n <rect fill=\"#73b18a\" height=\"10.44604\" width=\"245.88383\" x=\"321.00559\"/>\n <circle cx=\"328.76825\" cy=\"5.34057\" fill=\"#fff\" r=\"2.09686\"/>\n <circle cx=\"336.11718\" cy=\"5.34057\" fill=\"#fff\" r=\"2.09686\"/>\n <circle cx=\"343.46611\" cy=\"5.34057\" fill=\"#fff\" r=\"2.09686\"/>\n <rect fill=\"#e6e6e6\" height=\"31\" width=\"60\" x=\"671.64772\" y=\"294.80743\"/>\n <rect fill=\"#e6e6e6\" height=\"31\" width=\"60\" x=\"671.64772\" y=\"405.80743\"/>\n <circle cx=\"701.64772\" cy=\"365.80743\" fill=\"#e6e6e6\" r=\"50\"/>\n <circle cx=\"701.64772\" cy=\"365.80743\" fill=\"#fff\" r=\"39\"/>\n <rect fill=\"#e2e2e2\" height=\"1.72839\" width=\"30.24683\" x=\"688.87659\" y=\"355.12175\"/>\n <rect fill=\"#73b18a\" height=\"1.72839\" width=\"46.80151\" x=\"688.84621\" y=\"361.46796\"/>\n <rect fill=\"#e2e2e2\" height=\"1.72839\" width=\"36.72829\" x=\"688.84621\" y=\"367.44701\"/>\n <rect fill=\"#e2e2e2\" height=\"1.72839\" width=\"21.60488\" x=\"688.84621\" y=\"373.42605\"/>\n <rect fill=\"#e2e2e2\" height=\"1.72839\" width=\"32.40732\" x=\"688.84621\" y=\"379.4051\"/>\n <rect fill=\"#e2e2e2\" height=\"3.45678\" width=\"3.45678\" x=\"675.15972\" y=\"354.62472\"/>\n <rect fill=\"#73b18a\" height=\"3.45678\" width=\"3.45678\" x=\"675.15972\" y=\"360.60376\"/>\n <rect fill=\"#e2e2e2\" height=\"3.45678\" width=\"3.45678\" x=\"675.15972\" y=\"366.58281\"/>\n <rect fill=\"#e2e2e2\" height=\"3.45678\" width=\"3.45678\" x=\"675.15972\" y=\"372.56186\"/>\n <rect fill=\"#e2e2e2\" height=\"3.45678\" width=\"3.45678\" x=\"675.15972\" y=\"378.54091\"/>\n </svg>\n </div>\n <h2 class=\"newCustomer__header\">No webhooks yet.</h2>\n <p>Create webhook endpoints, so that Fleetwire can notify your integration when asynchronous events\n occur.</p>\n <v-btn :to=\"{ name: 'settings.providers.webhooks.create' }\" size=\"small\">\n <v-icon class=\"mr-2\" size=\"small\">mdi-plus</v-icon>\n Add Endpoint\n </v-btn>\n </div>\n </div>\n\n </div>\n </div>\n </div>\n</template>\n\n<script lang=\"ts\" setup>\nimport {computed, defineAsyncComponent, onBeforeMount} from 'vue';\nimport {useSubscription} from '@/composables/useSubscription';\nimport {useStore} from 'vuex';\nimport {useRouter} from 'vue-router';\n\nconst FeatureTitle = defineAsyncComponent(() => import('@/components/dashboard/FeatureTitle.vue'));\n\nconst router = useRouter();\nconst {getters, dispatch} = useStore();\nconst {includedInSubscription} = useSubscription();\nconst webhooksLoading = computed(() => getters['webhook/loading']);\nconst webhookEndpoints = computed(() => getters['webhook/webhookEndpoints']);\n\nconst getWebhookEndpoints = async () => {\n return await dispatch('webhook/getWebhookEndpoints');\n};\n\nconst webhookEndpointStatus = (endpoint) => {\n if (!endpoint || !endpoint.status) {\n return 'Unknown';\n }\n return endpoint.status.charAt(0).toUpperCase() + endpoint.status.slice(1);\n};\n\nconst editWebhook = (webhook) => {\n router.push({name: 'settings.providers.webhooks.update', params: {uuid: webhook.uuid}})\n .catch(err => {\n console.error('Failed to navigate to edit webhook:', err);\n });\n\n};\n\nonBeforeMount(() => {\n getWebhookEndpoints();\n});\n</script>\n","<template>\n <div>\n <div class=\"grid grid-cols-2\">\n <div class=\"\">\n <v-card :disabled=\"webhookCardReady\">\n <v-card-title>\n Listen to Fleetwire events\n </v-card-title>\n <v-card-subtitle>\n Set up your webhook endpoint to receive live events from Fleetwire.\n </v-card-subtitle>\n\n <v-card-text>\n <v-form>\n <v-text-field\n v-model=\"webhookForm.url\"\n :error-messages=\"webhookForm.errors.get('url')\"\n class=\"mb-2\"\n density=\"compact\"\n label=\"URL Endpoint\"\n name=\"url\"\n variant=\"outlined\"\n @keyup=\"clearErrors('url')\"\n />\n <v-text-field\n v-model=\"webhookForm.description\"\n :error-messages=\"webhookForm.errors.get('description')\"\n class=\"mb-2\"\n density=\"compact\"\n label=\"Description\"\n name=\"description\"\n variant=\"outlined\"\n @keyup=\"clearErrors('description')\"\n />\n\n <v-combobox\n v-model=\"webhookForm.events\"\n :error-messages=\"webhookForm.errors.get('events')\"\n :items=\"items\"\n class=\"mb-2\"\n density=\"compact\"\n label=\"Select events to listen to\"\n multiple\n name=\"events\"\n variant=\"outlined\"\n @update:modelValue=\"clearErrors('events')\"\n />\n </v-form>\n </v-card-text>\n <v-card-actions>\n <v-btn :disabled=\"!webhookFormReady\" :loading=\"webhookLoading.webhooks\" @click=\"addWebhookEndpointInit()\">\n Add Endpoint\n </v-btn>\n <v-btn size=\"small\" variant=\"text\" @click=\"router.push({ name: 'settings.providers.webhooks' })\">Cancel\n </v-btn>\n </v-card-actions>\n </v-card>\n </div>\n </div>\n\n <v-snackbar v-model=\"createWebhookSuccess\">\n Webhook created Successfully\n <template v-slot:actions>\n <v-btn variant=\"text\" @click=\"createWebhookSuccess = false\">\n Close\n </v-btn>\n </template>\n </v-snackbar>\n </div>\n</template>\n\n<script lang=\"ts\" setup>\nimport {computed, ref} from 'vue';\nimport {useStore} from 'vuex';\nimport {useSubscription} from \"@/composables/useSubscription\";\nimport {useRouter} from 'vue-router';\nimport Form from \"@/plugins/FWForms\";\nimport {WebhookEndpoint} from \"@/store/modules/webhook\";\n\nconst {getters, dispatch} = useStore();\n\nconst store = useStore();\nconst router = useRouter();\nconst {includedInSubscription} = useSubscription();\n\ninterface WebhookFormData {\n url: string;\n description: string;\n events: string[];\n}\n\nconst webhookForm = ref(new Form<WebhookFormData>({\n url: '',\n description: '',\n events: [],\n}));\n\nconst webhookLoading = computed(() => store.getters['webhook/loading']);\n\nconst webhookCardReady = computed(() => !includedInSubscription('coupons') || webhookLoading.value.webhook);\n\nconst webhookFormReady = computed(() => {\n const formData = webhookForm.value.data();\n for (const value of Object.values(formData)) {\n if (!value) return false;\n }\n return formData.events.length > 0;\n});\n\nconst clearErrors = (field: string) => {\n webhookForm.value.errors[field] = [];\n};\n\nconst addWebhookEndpoint = async (webhook: WebhookEndpoint) => {\n return await store.dispatch('webhook/addWebhookEndpoint', webhook);\n};\n\nconst addWebhookEndpointInit = () => {\n webhookForm.value.url = webhookForm.value.url.startsWith('https://')\n ? webhookForm.value.url\n : `https://${webhookForm.value.url.replace(/^http:\\/\\//, '')}`;\n\n console.dir(webhookForm.value.data());\n\n addWebhookEndpoint(webhookForm.value.data()).then((data) => {\n createWebhookSuccess.value = true;\n webhookForm.value.errors.clear();\n router.push({name: 'settings.providers.webhooks.update', params: {uuid: data.webhook.uuid}}).catch(() => {\n });\n }).catch((error) => {\n console.dir(error);\n webhookForm.value.errors.set(error.response.data.errors)\n });\n}\n\nconst createWebhookSuccess = ref(false);\nconst items = ref([\n 'reservation.created',\n]);\n</script>\n","<template>\n <div>\n <div class=\"grid grid-cols-1\">\n <div class=\"\">\n\n <div class=\"mb-4 font-bold\">\n <div class=\"flex\">\n <span class=\"small flex-fill\">\n <v-btn :to=\"{ name: 'settings.providers.webhooks' }\" class=\"mr-2\" size=\"small\" variant=\"text\">\n <v-icon size=\"small\">mdi-arrow-left</v-icon>\n </v-btn>\n <v-icon size=\"small\">mdi-webhook</v-icon> WEBHOOK\n </span>\n <small>\n uuid: {{ webhookClone.uuid }}\n <v-progress-circular v-if=\"webhookLoading.webhooks || webhookLoading.webhooksDelete\" :size=\"12\" :width=\"1\" indeterminate></v-progress-circular>\n </small>\n </div>\n <div class=\"flex\">\n <div class=\"flex-fill\">{{ webhookClone.url }}</div>\n <div>\n <v-menu>\n <template v-slot:activator=\"{ props }\">\n <v-btn size=\"small\" v-bind=\"props\">\n <v-icon>mdi-dots-horizontal</v-icon>\n </v-btn>\n </template>\n <v-list>\n <v-list-item @click=\"showEditForm = !showEditForm\">\n <v-list-item-title>Edit</v-list-item-title>\n </v-list-item>\n </v-list>\n </v-menu>\n </div>\n </div>\n </div>\n </div>\n </div>\n <div class=\"grid grid-cols-1 my-5\">\n <div>\n <v-card v-show=\"showEditForm\" :disabled=\"!includedInSubscription('webhooks') || webhookLoading.webhooks || webhookLoading.webhooksUpdate || webhookLoading.webhooksDelete\">\n <v-card-title>\n Listen to Stripe events\n <v-spacer/>\n <v-btn size=\"small\" @click=\"showEditForm = !showEditForm\">Close</v-btn>\n </v-card-title>\n <v-card-subtitle>\n Set up your webhook endpoint to receive live events from Fleetwire.\n </v-card-subtitle>\n\n <v-card-text>\n <v-form>\n <v-text-field\n v-model=\"webhookClone.url\"\n label=\"URL Endpoint\"\n variant=\"outlined\"\n ></v-text-field>\n <v-text-field\n v-model=\"webhookClone.description\"\n label=\"Description\"\n variant=\"outlined\"\n ></v-text-field>\n\n <v-combobox\n v-model=\"webhookClone.events\"\n :items=\"items\"\n density=\"compact\"\n label=\"Select events to listen to\"\n multiple\n variant=\"outlined\"\n ></v-combobox>\n <v-select\n v-model=\"webhookClone.status\"\n :items=\"['enabled', 'disabled']\"\n label=\"Status\"\n variant=\"outlined\"\n ></v-select>\n </v-form>\n </v-card-text>\n <v-card-actions>\n <v-btn :loading=\"webhookLoading.webhooksDelete\" color=\"red\" size=\"small\" variant=\"text\" @click=\"deleteWebhook(webhookClone)\">\n <v-icon size=\"small\">mdi-delete</v-icon>\n </v-btn>\n <v-spacer/>\n <v-btn size=\"small\" variant=\"text\" @click=\"showEditForm = !showEditForm\">Close</v-btn>\n <v-btn :disabled=\"!webhookFormReady\" :loading=\"webhookLoading.webhooksUpdate\" @click=\"updateWebhookEndpoint(webhookClone)\">\n Update Endpoint\n </v-btn>\n </v-card-actions>\n </v-card>\n </div>\n </div>\n\n <div class=\"mt-5 border-t\">\n <div class=\"flex\">\n <div class=\"border-e py-2 px-4\">\n <span class=\"block text-gray-600\">Status</span>\n <span v-if=\"webhookClone.status === 'enabled'\" class=\"badge badge-success\">\n Enabled\n </span>\n <span v-if=\"webhookClone.status === 'disabled'\" class=\"badge badge-danger\">\n Disabled\n </span>\n </div>\n <div class=\"border-e py-2 px-4\">\n <span class=\"block text-gray-600\">Listening for</span>\n <span class=\"badge badge-secondary\">\n {{ webhookClone.events.length }} Events\n </span>\n </div>\n <div class=\"border-e py-2 px-4\">\n <span class=\"block text-gray-600\">Signing secret</span>\n <span>\n <v-btn v-if=\"!webhookEndpointSecret\" :loading=\"webhookLoading.secret\" size=\"x-small\" variant=\"text\" @click=\"getWebhookEndpointSecret(webhookClone.uuid)\">Reveal</v-btn>\n <span v-if=\"webhookEndpointSecret\" class=\"small\">{{ webhookEndpointSecret }}</span>\n </span>\n </div>\n </div>\n </div>\n\n <div class=\"mt-5\">\n <div class=\"flex\">\n <v-card :disabled=\"webhookLoading.webhookConversationResend\">\n <v-card-text>\n <div style=\"min-width: 500px; width: 500px\">\n <div v-for=\"(conversations, date) in orderedConversations\" :key=\"date\">\n <div class=\"border-b w-100 mt-5\">\n <strong>{{ date }}</strong>\n </div>\n <div v-for=\"(conversation) in conversations\" :key=\"conversation.uuid\" :class=\"conversationListClassObject(conversation)\" class=\"cursor-pointer hover:bg-blue-100\" @click=\"selectConversation(conversation)\">\n <div class=\"py-1 px-3 flex\">\n <div class=\"flex-fill\">\n <v-icon v-if=\"conversation.result_type === 'success'\" color=\"green\" size=\"small\">\n mdi-check-circle\n </v-icon>\n <v-icon v-else-if=\"conversation.result_type === 'error'\" color=\"red\" size=\"small\">\n mdi-close-circle\n </v-icon>\n <v-icon v-else color=\"orange\" size=\"small\">mdi-help-circle</v-icon>\n {{ webhookEventLabel(conversation) }}\n </div>\n <div>\n {{ webhookEventLabelTime(conversation) }}\n </div>\n </div>\n </div>\n </div>\n <div v-if=\"webhookConversations.length === 0\">No Events yet</div>\n </div>\n </v-card-text>\n </v-card>\n\n <div :class=\"conversationResultClassObject\" class=\"flex-fill p-2\">\n <v-card v-show=\"currentWorkingConversation.uuid\" class=\"flex-fill\" flat>\n <v-card-title>\n {{ webhookEventLabel(currentWorkingConversation) }}\n <v-spacer/>\n <v-btn :loading=\"webhookLoading.webhookConversationResend\" size=\"small\" variant=\"outlined\" @click=\"resendWebhookConversationInit(currentWorkingConversation)\">\n <v-icon class=\"mr-2\" size=\"x-small\">mdi-restore</v-icon>\n Resend\n </v-btn>\n </v-card-title>\n <v-card-subtitle>\n Created: <small>{{ webhookEventLabelTime(currentWorkingConversation) }}</small>\n </v-card-subtitle>\n <v-card-text>\n <div>\n <label class=\"block font-bold\">Response:</label>\n <div>{{ currentWorkingConversation.http_status }}</div>\n <div style=\"max-width: 500px; max-height: 250px; overflow: auto\">\n {{ currentWorkingConversation.response_body }}\n </div>\n </div>\n <div class=\"mt-3\">\n <label class=\"block font-bold\">Request:</label>\n <div class=\"response-code\">\n <pre>{{ currentWorkingConversation.request_body }}</pre>\n </div>\n </div>\n </v-card-text>\n </v-card>\n </div>\n </div>\n </div>\n\n <v-snackbar v-model=\"updateSuccess\">\n Webhook updated Successfully\n <template v-slot:actions>\n <v-btn variant=\"text\" @click=\"updateSuccess = false\">\n Close\n </v-btn>\n </template>\n </v-snackbar>\n </div>\n</template>\n\n<script>\nimport { ref, computed } from 'vue';\nimport { cloneDeep, groupBy, orderBy, clone } from 'lodash';\nimport { EventBus } from '@/plugins/eventBus';\nimport dayjs from 'dayjs';\nimport { useCompany } from '@/composables/useCompany';\nimport { useSubscription } from '@/composables/useSubscription';\nimport { useStore } from 'vuex';\n\nexport default {\n name: 'SettingsWebhookUpdate',\n\n setup() {\n const { getters, dispatch } = useStore();\n const { company, companyLoading } = useCompany();\n const { includedInSubscription } = useSubscription();\n\n const showEditForm = ref(false);\n const updateSuccess = ref(false);\n const webhookClone = ref({\n uuid: '',\n url: '',\n description: '',\n status: '',\n events: [],\n });\n const currentWorkingConversation = ref({});\n const items = ref([\n 'reservation.created',\n ]);\n\n const conversationResultClassObject = ref({\n 'bg-red-100': currentWorkingConversation.value?.result_type === 'error',\n 'bg-green-100': currentWorkingConversation.value?.result_type === 'success',\n });\n\n // computed\n const webhookLoading = computed(() => getters['webhook/loading']);\n const currentWebhook = computed(() => getters['webhook/webhookEndpoint']);\n const webhookConversations = computed(() => getters['webhook/webhookConversations']);\n const webhookEndpointSecret = computed(() => getters['webhook/webhookEndpointSecret']);\n\n const webhookFormReady = computed(() => {\n for (const [key, value] of Object.entries(webhookClone.value)) {\n if (!['metadata', 'type'].includes(key)) {\n if (!value) return false;\n }\n }\n return true;\n });\n\n const orderedConversations = computed(() => {\n const conversation = groupBy(webhookConversations.value, (c) => dayjs(c.created_at).format('MMM DD, YYYY'));\n\n const orderedDates = {};\n // @ts-ignore: The right-hand side of an arithmetic operation must be of type 'any', 'number', 'bigint' or an enum type.\n Object.keys(conversation).sort((a, b) => dayjs(b).toDate() - dayjs(a).toDate()).forEach((key) => {\n orderedDates[key] = conversation[key];\n });\n\n Object.keys(orderedDates).forEach((element) => {\n orderedDates[element] = orderBy(orderedDates[element], 'created_at', 'desc');\n });\n\n return orderedDates;\n });\n\n\n const getWebhookEndpoint = (uuid) => dispatch('webhook/getWebhookEndpoint', uuid);\n const getWebhookConversations = (uuid) => dispatch('webhook/getWebhookConversations', uuid);\n const resendWebhookConversation = (conversation) => dispatch('webhook/resendWebhookConversation', conversation);\n const updateWebhookEndpoint = (webhook) => dispatch('webhook/updateWebhookEndpoint', webhook);\n const deleteWebhook = (webhook) => dispatch('webhook/deleteWebhookEndpoint', webhook);\n const getWebhookEndpointSecret = (uuid) => dispatch('webhook/getWebhookEndpointSecret', uuid);\n\n\n const webhookEventLabel = (conversation) => conversation?.event;\n\n const webhookEventLabelTime = (conversation) => dayjs(conversation.created_at).format('H:mm');\n\n const selectConversation = (conversation) => currentWorkingConversation.value = clone(conversation);\n\n const conversationListClassObject = (conversation) => ({\n 'bg-blue-100': currentWorkingConversation.value?.uuid === conversation.uuid,\n 'is-selected': currentWorkingConversation.value?.uuid === conversation.uuid,\n });\n\n const resendWebhookConversationInit = (conversation) => resendWebhookConversation(conversation);\n\n return {\n company,\n webhookLoading,\n companyLoading,\n showEditForm,\n updateSuccess,\n webhookClone,\n currentWorkingConversation,\n items,\n currentWebhook,\n webhookConversations,\n webhookEndpointSecret,\n conversationResultClassObject,\n webhookFormReady,\n orderedConversations,\n webhookEventLabel,\n includedInSubscription,\n getWebhookConversations,\n getWebhookEndpoint,\n resendWebhookConversation,\n updateWebhookEndpoint,\n deleteWebhook,\n getWebhookEndpointSecret,\n webhookEventLabelTime,\n selectConversation,\n conversationListClassObject,\n resendWebhookConversationInit,\n };\n },\n\n created() {\n EventBus.$on('update-webhook-endpoint-success', () => {\n this.updateSuccess = true;\n this.showEditForm = false;\n });\n EventBus.$on('webhook-conversation-created-success', () => {\n this.getWebhookConversations(this.$route.params.uuid);\n });\n EventBus.$on('delete-webhook-endpoint-success', () => {\n this.$router.push({ name: 'settings.providers.webhooks' }).catch(() => {\n });\n });\n },\n\n watch: {\n company: {\n immediate: true,\n handler(companyNew) {\n if (companyNew.uuid) {\n this.getWebhookEndpoint(this.$route.params.uuid);\n this.getWebhookConversations(this.$route.params.uuid);\n }\n },\n },\n currentWebhook: {\n immediate: true,\n handler(webhook) {\n if (webhook?.uuid) {\n this.webhookClone = cloneDeep(webhook);\n this.webhookClone.events = this.webhookClone.events.map((e) => e.event);\n }\n },\n },\n orderedConversations: {\n immediate: true,\n handler(conversation) {\n if (Object.keys(conversation).length > 0) {\n this.currentWorkingConversation = clone(conversation[Object.keys(conversation)[0]][0]);\n }\n },\n },\n },\n\n beforeUnmount() {\n this.webhookClone = null;\n this.webhookClone = {\n uuid: '',\n url: '',\n description: '',\n events: [],\n };\n\n EventBus.$off('update-webhook-endpoint-success');\n EventBus.$off('webhook-conversation-created-success');\n EventBus.$off('delete-webhook-endpoint-success');\n },\n};\n</script>\n\n<style>\n.response-code {\n padding: 0.2em 0.4em;\n border-radius: 3px;\n font-size: 85%;\n font-weight: 400;\n}\n\n.is-selected {\n background-color: #f6f8fa;\n box-shadow: inset 0 -1px 0 0 #ebeef1, inset 4px 0 0 0 #81b3fe;\n font-weight: 500;\n}\n</style>\n","<template>\n <div>\n <h2 class=\"mt-8 mb-4 font-bold text-2xl\">Checkout</h2>\n\n <Payments/>\n <v-divider class=\"my-10\" opacity=\"50\"/>\n\n <TermsAndCancellationPolicy/>\n <v-divider class=\"my-10\" opacity=\"50\"/>\n\n <eSign/>\n <v-divider class=\"my-10\" opacity=\"50\"/>\n\n <AdditionalScripts/>\n <v-divider class=\"my-10\" opacity=\"50\"/>\n\n <AdditionalStyling/>\n <v-divider class=\"my-10\" opacity=\"50\"/>\n\n <div v-if=\"false\" class=\"my-5\">\n <div class=\"\">\n <div class=\"setting-section-description\">\n <FeatureTitle\n featurePremium\n featureStandard\n title=\"Coupon Codes\"\n />\n <div class=\"feature-description\">\n Allow renters to use coupon codes at checkout.\n </div>\n </div>\n </div>\n <div class=\"\">\n <v-card :disabled=\"!includedInSubscription('coupons')\" max-width=\"100%\" variant=\"outlined\">\n <v-card-text>\n <div class=\"list-group list-group-flush\">\n <div class=\"list-group-item\">\n <div class=\"align-items-center\">\n <div>\n <p class=\"mb-0\">\n Accept coupons\n </p>\n <small class=\"text-gray-700\">\n Allow your customers to use coupons\n </small>\n </div>\n <div class=\"col-auto\">\n <div class=\"custom-control custom-switch\">\n <v-switch v-model=\"localAcceptCoupons\" :loading=\"companyLoading.company\" inset/>\n </div>\n\n </div>\n </div>\n </div>\n </div>\n </v-card-text>\n\n <v-card-actions>\n <v-spacer/>\n <v-btn :loading=\"companyLoading.company\" location=\"right\" @click=\"saveCompanyMeta()\">Save</v-btn>\n </v-card-actions>\n </v-card>\n </div>\n </div>\n </div>\n</template>\n\n<script lang=\"ts\" setup>\nimport {defineAsyncComponent, ref, watch} from 'vue';\nimport {useCompany} from '@/composables/useCompany';\nimport {useSubscription} from '@/composables/useSubscription';\nimport {getMetaBooleanValue} from '@/utils/meta';\n\nconst eSign = defineAsyncComponent(() => import('@/components/dashboard/settings/checkout/eSign.vue'));\nconst AdditionalScripts = defineAsyncComponent(() => import('@/components/dashboard/settings/checkout/AdditionalScripts.vue'));\nconst AdditionalStyling = defineAsyncComponent(() => import('@/components/dashboard/settings/checkout/AdditionalStyling.vue'));\nconst FeatureTitle = defineAsyncComponent(() => import('@/components/dashboard/FeatureTitle.vue'));\nconst TermsAndCancellationPolicy = defineAsyncComponent(() => import('@/components/dashboard/settings/checkout/TermsAndCancellationPolicy.vue'));\nconst Payments = defineAsyncComponent(() => import('@/components/dashboard/settings/checkout/Payments.vue'));\n\nconst {includedInSubscription} = useSubscription();\nconst {companyLoading, saveCompanyMeta, defaultMeta} = useCompany();\n\nconst localAcceptCoupons = ref(false);\n\n\nwatch(defaultMeta, () => {\n localAcceptCoupons.value = getMetaBooleanValue('settings.payment.accept_coupons')\n}, {immediate: true});\n</script>\n","<template>\n <div>\n <h2 class=\"mt-8 mb-4 font-bold text-2xl\">Online Reservations</h2>\n\n <General/>\n <SectionDivider/>\n\n <OperatingHours/>\n <SectionDivider/>\n\n <GuestCancellation/>\n <SectionDivider/>\n\n <CheckoutFields/>\n <SectionDivider/>\n\n <SecondaryDrivers/>\n <SectionDivider/>\n\n <StoreCustomizations/>\n <SectionDivider/>\n\n <CustomDomain/>\n <SectionDivider/>\n\n <EcommerceTracking/>\n <SectionDivider/>\n\n <Install/>\n </div>\n</template>\n\n<script lang=\"ts\" setup>\nimport {defineAsyncComponent} from 'vue';\n\nconst SectionDivider = defineAsyncComponent(() => import('@/components/common/SectionDivider.vue'));\n\nconst components = {\n OperatingHours: defineAsyncComponent(() => import('@/components/dashboard/settings/onlineReservations/OperatingHours.vue')),\n General: defineAsyncComponent(() => import('@/components/dashboard/settings/onlineReservations/SettingsGeneral.vue')),\n GuestCancellation: defineAsyncComponent(() => import('@/components/dashboard/settings/onlineReservations/AllowBookingCancellation.vue')),\n CheckoutFields: defineAsyncComponent(() => import('@/components/dashboard/settings/onlineReservations/CheckoutFields.vue')),\n SecondaryDrivers: defineAsyncComponent(() => import('@/components/dashboard/settings/onlineReservations/AllowSecondaryDrivers.vue')),\n StoreCustomizations: defineAsyncComponent(() => import('@/components/dashboard/settings/onlineReservations/StoreCustomizations.vue')),\n CustomDomain: defineAsyncComponent(() => import('@/components/dashboard/settings/onlineReservations/CustomDomain.vue')),\n EcommerceTracking: defineAsyncComponent(() => import('@/components/dashboard/settings/onlineReservations/EcommerceTracking.vue')),\n Install: defineAsyncComponent(() => import('@/components/dashboard/settings/onlineReservations/Install.vue')),\n};\n\n// Destructure components for template use\nconst {\n OperatingHours,\n General,\n GuestCancellation,\n CheckoutFields,\n SecondaryDrivers,\n StoreCustomizations,\n CustomDomain,\n EcommerceTracking,\n Install,\n} = components;\n</script>\n","<template>\n <div>\n <h2 class=\"mt-8 mb-4 font-bold text-2xl\">Add New Employee</h2>\n\n <v-alert v-if=\"seatLimitReached\" class=\"my-2\" type=\"warning\">\n <span v-html=\"seatLimitReachedMessage\"></span>\n </v-alert>\n\n <div class=\"grid grid-cols-2 gap-1\">\n <v-card :disabled=\"seatLimitReached\">\n <v-card-title class=\"mb-2\">\n Account information\n </v-card-title>\n\n <v-card-subtitle>\n Invite a team member\n </v-card-subtitle>\n <v-container>\n <v-form v-model=\"newTeamMemberFormValid\" :disabled=\"seatLimitReached\">\n <div class=\" align-center\">\n <div class=\"\">\n <div class=\"\">\n <div class=\"\">\n <v-text-field\n v-model=\"form.first_name\"\n :disabled=\"seatLimitReached\"\n :error-messages=\"form.errors.get('first_name')\"\n :label=\"$t('first_name')\"\n autofocus=\"autofocus\"\n large\n name=\"first_name\"\n variant=\"outlined\"\n @keyup=\"form.errors.clear('first_name')\"\n />\n </div>\n <div class=\"\">\n <v-text-field\n v-model=\"form.last_name\"\n :disabled=\"seatLimitReached\"\n :error-messages=\"form.errors.get('last_name')\"\n :label=\"$t('last_name')\"\n name=\"last_name\"\n variant=\"outlined\"\n @keyup=\"form.errors.clear('last_name')\"\n />\n </div>\n </div>\n <div class=\"\">\n <div class=\"\">\n <v-text-field\n v-model=\"form.email\"\n :disabled=\"seatLimitReached\"\n :error-messages=\"form.errors.get('email')\"\n :label=\"$t('email')\"\n :rules=\"registerFormRules.email\"\n name=\"email\"\n required\n type=\"email\"\n variant=\"outlined\"\n @keyup=\"form.errors.clear('email')\"\n />\n </div>\n </div>\n </div>\n </div>\n </v-form>\n </v-container>\n </v-card>\n </div>\n\n <div class=\"grid grid-cols-2 my-5\">\n <v-card :disabled=\"seatLimitReached || form.busy\">\n <v-card-title>\n Permissions\n </v-card-title>\n <v-card-subtitle>\n Choose a set of permissions that fits this new team member's role.\n </v-card-subtitle>\n\n <v-card-text>\n <div class=\"flex\">\n <v-spacer/>\n <v-checkbox\n v-model=\"selectAllPermissions\"\n :indeterminate=\"form.permissions.length !== 0 && form.permissions.length < possiblePermissions.length\"\n color=\"accent-4\"\n >\n <template v-slot:prepend>\n <small style=\"min-width: 65px; margin-top: 5px; color: #5a5e66\">Select All</small>\n </template>\n </v-checkbox>\n </div>\n\n <div>\n <div v-for=\"(item, category) in filteredPermissions\" :key=\"`title-${category}`\">\n <div class=\"font-bold text-xl\">{{ formatTitles(category) }}</div>\n\n <v-list-item v-for=\"(perm, index) in item\" :key=\"`item${category}-${index}`\" :value=\"perm.name\">\n <template v-slot:prepend=\"{ isActive }\">\n <v-list-item-action :start=\"true\">\n <v-checkbox-btn\n v-model=\"form.permissions\"\n :input-value=\"isActive\"\n :true-value=\"perm.name\"\n :value=\"perm.name\"\n\n color=\"accent-4\"\n @change=\"form.errors.clear('permissions')\"\n ></v-checkbox-btn>\n </v-list-item-action>\n\n <v-list-item-title v-text=\"formatTitles(perm.name)\"></v-list-item-title>\n </template>\n </v-list-item>\n <v-divider/>\n </div>\n </div>\n </v-card-text>\n\n <v-alert v-if=\"form.errors.any()\" class=\"card-alert-full\" density=\"compact\" type=\"error\">\n {{ form.errors.flatten()[0] }}\n </v-alert>\n\n <v-card-actions>\n <v-spacer/>\n <v-btn\n :disabled=\"!newTeamMemberFormValid || form.errors.any() || form.busy\"\n :loading=\"form.busy\"\n class=\"mt-3\"\n color=\"primary\"\n @click=\"inviteNewTeamMember()\"\n >\n Send Invite\n </v-btn>\n </v-card-actions>\n </v-card>\n </div>\n </div>\n</template>\n\n<script lang=\"ts\">\nimport {mapGetters} from 'vuex';\nimport Form from 'vform';\nimport {EventBus} from '@/plugins/eventBus';\nimport {each, get, map, remove} from 'lodash';\nimport {useSubscription} from '@/composables/useSubscription';\n\n\nexport default {\n name: 'SettingsEmployeeNew',\n\n setup() {\n const {seatLimitReached, seatLimitReachedMessage} = useSubscription()\n return {\n seatLimitReached,\n seatLimitReachedMessage,\n };\n },\n\n data() {\n return {\n newTeamMemberFormValid: false,\n selectAllPermissions: true,\n form: new Form({\n first_name: '',\n last_name: '',\n email: '',\n permissions: [],\n }),\n };\n },\n\n computed: {\n ...mapGetters({\n possiblePermissions: 'app/possiblePermissions',\n employee: 'company/employee',\n registerFormRules: 'company/registerFormRules',\n }),\n\n filteredPermissions() {\n const perms = {\n customers: [],\n users: [],\n listings: [],\n orders: [],\n settings: [],\n turo: [],\n };\n\n const allPermissions = [...this.possiblePermissions];\n\n each(perms, (p, i) => {\n perms[i] = remove(allPermissions, (p) => p.name.includes(i));\n });\n perms.misc = allPermissions;\n\n return perms;\n },\n\n employeePermissions: {\n get() {\n const employee = this.$store.getters['company/employee'];\n return employee?.permissions || [];\n },\n set(value) {\n this.$store.commit('company/SET_EMPLOYEE_PERMISSIONS', value);\n },\n },\n },\n\n watch: {\n possiblePermissions() {\n this.form.permissions = map(this.possiblePermissions, (p) => p.name);\n },\n\n selectAllPermissions: {\n immediate: true,\n handler(newData) {\n if (newData) {\n this.form.permissions = map(this.possiblePermissions, (p) => p.name);\n } else {\n this.form.permissions = [];\n }\n },\n },\n },\n\n methods: {\n formatTitles(word) {\n if (!word) return '';\n const title = word.split('_');\n return title.map((word) => word[0].toUpperCase() + word.substring(1)).join(' ');\n },\n async inviteNewTeamMember() {\n try {\n const response = await this.form.post('/v1/employees');\n if (response.status === 200) {\n if (get(response, 'data.company')) {\n this.$store.commit('company/SET_COMPANY', get(response, 'data.company'));\n }\n\n EventBus.$emit('SystemMessage', {\n type: 'success',\n message: 'Employee invited',\n });\n this.$router.push({name: 'settings.account'}).catch(() => {\n });\n }\n } catch (er) {\n console.dir(er);\n }\n },\n },\n};\n</script>\n","<template>\n <div>\n <div v-if=\"!company.init\" class=\"container\">\n <div class=\"grid grid-cols-3\">\n <div>\n <div class=\"max-w-sm animate-pulse p-5\" role=\"status\">\n <div class=\"h-2.5 bg-gray-200 rounded-full dark:bg-gray-700 w-48 mb-4\"></div>\n </div>\n </div>\n <div class=\"col-span-2\">\n <v-card variant=\"flat\">\n <v-card-text>\n <div class=\"max-w-sm animate-pulse p-5\" role=\"status\">\n <div class=\"h-2.5 bg-gray-200 rounded-full dark:bg-gray-700 w-48 mb-4\"></div>\n <div class=\"h-2 bg-gray-200 rounded-full dark:bg-gray-700 max-w-[360px] mb-2.5\"></div>\n <div class=\"h-2 bg-gray-200 rounded-full dark:bg-gray-700 mb-2.5\"></div>\n <div class=\"h-2 bg-gray-200 rounded-full dark:bg-gray-700 max-w-[330px] mb-2.5\"></div>\n <div class=\"h-2 bg-gray-200 rounded-full dark:bg-gray-700 max-w-[300px] mb-2.5\"></div>\n <div class=\"h-2 bg-gray-200 rounded-full dark:bg-gray-700 max-w-[360px]\"></div>\n <span class=\"sr-only\">Loading...</span>\n </div>\n </v-card-text>\n <v-card-actions>\n <v-spacer/>\n <div class=\"max-w-sm animate-pulse p-5\" role=\"status\">\n <div class=\"h-2.5 bg-gray-200 rounded-full dark:bg-gray-700 w-48 mb-4\"></div>\n <span class=\"sr-only\">Loading...</span>\n </div>\n </v-card-actions>\n </v-card>\n </div>\n </div>\n </div>\n <div v-else-if=\"!employee.found\">\n Employee not found\n </div>\n <div v-else>\n <div class=\"grid grid-cols-1 md:grid-cols-3 mb-5\">\n <div>\n <div class=\"setting-section-description\">\n <h3 class=\"text-lg font-medium text-gray-900 dark:text-gray-100\">Account</h3>\n </div>\n </div>\n <div class=\"col-span-1\">\n <v-card max-width=\"100%\" variant=\"flat\">\n <v-card-text>\n <div class=\"flex flex-col sm:flex-row\">\n <div class=\"flex flex-grow h-100 content-center\">\n <v-avatar\n class=\"shadow-sm\"\n color=\"primary\"\n size=\"40\"\n >\n <span class=\"text-white font-medium\">{{ employeeInitials(employee) }}</span>\n </v-avatar>\n <div class=\"ml-4\">\n <div class=\"flex items-center gap-2\">\n <span class=\"text-gray-900 dark:text-gray-100 font-medium\">\n {{ employee.name }}\n </span>\n <v-chip\n v-if=\"employee.email === user.email\"\n class=\"text-xs\"\n color=\"primary\"\n size=\"small\"\n variant=\"outlined\"\n >\n Account Owner\n </v-chip>\n </div>\n <div class=\"text-sm text-gray-500 dark:text-gray-400 mt-1\">\n {{ employee.email }}\n </div>\n <div class=\"text-sm text-gray-500 dark:text-gray-400\">\n {{ employee.phone }}\n </div>\n </div>\n </div>\n </div>\n\n <v-form v-if=\"editAccountForm\" class=\"mt-10\">\n <div class=\"\">\n <div class=\"\">\n <v-text-field\n v-model=\"employeeClone.email\"\n class=\"mb-4\"\n label=\"Email\"\n variant=\"outlined\"\n />\n </div>\n </div>\n <div class=\"\">\n <div class=\"mb-4\">\n <v-text-field\n v-model=\"employeeClone.first_name\"\n label=\"First Name\"\n variant=\"outlined\"\n />\n </div>\n <div class=\"mb-4\">\n <v-text-field\n v-model=\"employeeClone.last_name\"\n label=\"Last Name\"\n variant=\"outlined\"\n />\n </div>\n </div>\n <div class=\"\">\n <div class=\"\">\n <v-text-field\n v-model=\"employeeClone.phone\"\n label=\"Phone\"\n variant=\"outlined\"\n />\n </div>\n <div class=\"\">\n </div>\n </div>\n </v-form>\n </v-card-text>\n <v-card-actions class=\"flex flex-col sm:flex-row justify-end gap-2\">\n <v-btn v-if=\"editAccountForm\" size=\"small\" variant=\"text\" @click=\"editAccountForm = false;\">\n Cancel\n </v-btn>\n <v-btn v-if=\"editAccountForm\" @click=\"saveCompanyEmployeeInit()\">\n Save\n </v-btn>\n <v-btn v-if=\"!editAccountForm\" size=\"small\" variant=\"text\" @click=\"editAccountForm = true;\">\n edit\n </v-btn>\n </v-card-actions>\n </v-card>\n </div>\n </div>\n\n <v-divider class=\"my-6 md:my-10\" opacity=\"50\"/>\n\n <div class=\"grid grid-cols-1 md:grid-cols-3 my-5\">\n <div>\n <div class=\"setting-section-description\">\n <h3 class=\"text-lg font-medium text-gray-900 dark:text-gray-100\">Account Status</h3>\n <div class=\"feature-description\">\n Manage team member access by activating or deactivating accounts as needed.<br>\n\n When you deactivate a team member, their seat becomes available in your plan's total seat allocation.\n </div>\n </div>\n </div>\n <div class=\"col-span-1\">\n <v-card max-width=\"100%\" variant=\"flat\">\n <v-card-title>\n <span v-if=\"!employee.email_verified_at\">Invite Pending</span>\n <span v-else>Confirmed</span>\n </v-card-title>\n\n <v-card-text>\n This team member occupies one seat in your plan's allocation. They will gain access to your Fleetwire\n account once they accept the invitation sent to <strong>{{ employee.email }}</strong>\n </v-card-text>\n\n <v-card-actions class=\"flex flex-col sm:flex-row justify-between gap-2\">\n <v-btn\n v-if=\"!employee.email_verified_at\"\n color=\"grey\"\n variant=\"text\"\n @click=\"sendEmployeeInvite()\"\n >\n Resend invite\n </v-btn>\n <v-btn :disabled=\"currentEmployeeIsMe\" color=\"error\" size=\"small\" variant=\"text\" @click=\"deleteEmployee()\">\n {{ $t('deactivate') }}\n </v-btn>\n </v-card-actions>\n </v-card>\n </div>\n </div>\n\n <v-divider class=\"my-6 md:my-10\" opacity=\"50\"/>\n\n <div class=\"grid grid-cols-1 md:grid-cols-3 my-5\">\n <div>\n <div class=\"setting-section-description\">\n <h3 class=\"text-lg font-medium text-gray-900 dark:text-gray-100\">Permissions</h3>\n </div>\n </div>\n <div class=\"col-span-1\">\n <v-card :disabled=\"form.busy\" max-width=\"100%\" variant=\"flat\">\n <v-card-text>\n <v-checkbox\n v-model=\"selectAllPermissions\"\n :indeterminate=\"employeePermissions.length !== 0 && employeePermissions.length < possiblePermissions.length\"\n class=\"mb-4\"\n color=\"accent-4\"\n label=\"Select All\"\n />\n\n <div v-for=\"(item, category) in filteredPermissions\" :key=\"`title-${item.name}`\" class=\"mb-6\">\n <v-card-title class=\"text-base\">{{ formatTitles(category) }}</v-card-title>\n <template v-for=\"(perm, index) in item\" :key=\"`item${category}-${index}`\">\n <v-checkbox\n v-model=\"employeePermissions\"\n :label=\"perm.name\"\n :value=\"perm.name\"\n class=\"mb-1\"\n color=\"accent-4\"\n density=\"compact\"\n hide-details\n ></v-checkbox>\n </template>\n </div>\n </v-card-text>\n\n <v-card-actions class=\"flex justify-end\">\n <v-btn :loading=\"form.busy\" color=\"primary\" @click=\"saveEmployee\">\n {{ $t('save') }}\n </v-btn>\n </v-card-actions>\n </v-card>\n </div>\n </div>\n\n <v-divider class=\"my-6 md:my-10\" opacity=\"50\"/>\n\n <div class=\"grid grid-cols-1 md:grid-cols-3 my-5\">\n <div>\n <div class=\"setting-section-description\">\n <h3 class=\"text-lg font-medium text-gray-900 dark:text-gray-100\">Roles</h3>\n </div>\n </div>\n <div class=\"col-span-1\">\n <v-card :disabled=\"form.busy\" max-width=\"100%\" variant=\"flat\">\n <v-card-text>\n <div v-for=\"(item) in availableRoles\" :key=\"`title-${item.title}`\" class=\"mb-2\">\n <v-checkbox\n v-model=\"employeeRoles\"\n :disabled=\"currentEmployeeIsMe\"\n :label=\"item.title\"\n :value=\"item.name\"\n color=\"accent-4\"\n density=\"compact\"\n hide-details\n ></v-checkbox>\n </div>\n </v-card-text>\n\n <v-card-actions class=\"flex justify-end\">\n <v-btn :loading=\"form.busy\" color=\"primary\" @click=\"saveEmployee\">\n {{ $t('save') }}\n </v-btn>\n </v-card-actions>\n </v-card>\n </div>\n </div>\n </div>\n\n <v-dialog v-model=\"deleteConfirmDialog\" max-width=\"400\">\n <v-card>\n <v-alert v-if=\"currentEmployeeIsMe\" class=\"card-alert-full\" type=\"warning\">\n You can not delete yourself\n </v-alert>\n <v-card-title class=\"text-h5\">Are you sure?</v-card-title>\n <v-card-text>\n You are about to delete this employee.\n </v-card-text>\n <v-card-actions>\n <v-spacer/>\n <v-btn color=\"grey\" size=\"small\" variant=\"text\" @click=\"deleteConfirmDialog = false\">\n {{ $t('nevermind') }}\n </v-btn>\n <v-btn :disabled=\"currentEmployeeIsMe\" :loading=\"form.busy\" color=\"red text-white\" @click=\"deleteEmployeeConfirmed()\">\n {{ $t('confirm') }}\n </v-btn>\n </v-card-actions>\n </v-card>\n </v-dialog>\n </div>\n</template>\n\n<script lang=\"ts\">\nimport {nextTick} from 'vue';\nimport {mapActions, mapGetters} from 'vuex';\nimport {clone, each, get, map, remove} from 'lodash';\nimport {EventBus} from '@/plugins/eventBus';\nimport Form from 'vform';\nimport {useCompany} from '@/composables/useCompany';\nimport {push} from 'notivue'\n\nconst PERMISSION_ORDER = ['view', 'add', 'edit', 'cancel', 'delete', 'manage'];\n\n\nexport default {\n name: 'SettingsEmployeeSingle',\n\n setup() {\n const {company} = useCompany();\n return {\n company,\n };\n },\n\n data() {\n return {\n availableRoles: [\n {\n name: 'company_admin',\n title: 'Company Admin',\n description: 'The company admin',\n },\n ],\n deleteConfirmDialog: false,\n selectAllPermissions: false,\n form: new Form(),\n editAccountForm: false,\n employeeClone: {\n first_name: null,\n last_name: null,\n phone: null,\n email: null,\n },\n permissionDescriptions: {\n orders_adjust_taxes: {\n title: 'Adjust Taxes',\n description: 'Allows the employee to adjust taxes on orders',\n },\n },\n admin_approvals: {\n customers_edit: false,\n customers_delete: true,\n },\n };\n },\n\n watch: {\n employee: {\n immediate: true,\n handler(employee) {\n if (employee.uuid) {\n this.employeeClone = clone(employee);\n }\n },\n },\n selectAllPermissions: {\n immediate: true,\n handler(newData) {\n if (newData) {\n this.employeePermissions = map(this.possiblePermissions, (p) => p.name);\n } else {\n this.employeePermissions = [];\n }\n },\n },\n },\n\n mounted() {\n if (this.possiblePermissions.length === this.employeePermissions.length) {\n this.selectAllPermissions = true;\n }\n },\n\n created() {\n this.fetchCompanyEmployee();\n EventBus.$on('employee-updated-success', () => {\n this.editAccountForm = false;\n this.fetchCompanyEmployee();\n });\n },\n\n computed: {\n ...mapGetters({\n user: 'auth/user',\n possiblePermissions: 'app/possiblePermissions',\n employee: 'company/employee',\n }),\n\n filteredPermissions(): Record<string, any> {\n const permissions = {\n customers: [],\n users: [],\n listings: [],\n orders: [],\n settings: [],\n turo: [],\n misc: [],\n };\n\n const allPermissions = [...this.possiblePermissions];\n\n each(permissions, (p, i) => {\n permissions[i] = remove(allPermissions, (p) => p.name.includes(i));\n });\n permissions.misc = allPermissions;\n\n each(permissions, (p, i) => {\n // order each permission group by the order in PERMISSION_ORDER\n // e.g. customers_view should be first in the list because PERMISSION_ORDER[0] === 'view'\n // any permissions that are not in PERMISSION_ORDER will be sorted alphabetically after\n permissions[i] = p.sort((a, b) => {\n const aIndex = PERMISSION_ORDER.indexOf(a.name.split('_')[1]);\n const bIndex = PERMISSION_ORDER.indexOf(b.name.split('_')[1]);\n\n if (aIndex === -1 && bIndex === -1) {\n return a.name.localeCompare(b.name);\n }\n if (aIndex === -1) {\n return 1;\n }\n if (bIndex === -1) {\n return -1;\n }\n\n return aIndex - bIndex;\n });\n });\n\n return permissions;\n },\n\n currentEmployeeIsMe() {\n return this.employee.uuid === this.user.uuid;\n },\n\n employeePermissions: {\n get() {\n const employee = this.$store.getters['company/employee'];\n return get(employee, 'permissions', []);\n },\n set(value) {\n this.$store.commit('company/SET_EMPLOYEE_PERMISSIONS', value);\n },\n },\n employeeRoles: {\n get() {\n const employee = this.$store.getters['company/employee'];\n return get(employee, 'roles', []);\n },\n set(value) {\n this.$store.commit('company/SET_EMPLOYEE_ROLES', value);\n },\n },\n },\n\n methods: {\n ...mapActions({\n saveCompanyEmployee: 'company/saveEmployee',\n }),\n checkPermission(perm) {\n nextTick(() => {\n const turnOn = this.employeePermissions.includes(perm.name);\n\n if (perm.name.includes('_view') && !turnOn) {\n let otherPerms = this.possiblePermissions.filter((p) => p.name.includes(perm.name.split('_')[0]) && !p.name.includes('_view'));\n otherPerms = map(otherPerms, (p) => p.name);\n // remove all the other permissions from the employeePermissions array\n this.employeePermissions = this.employeePermissions.filter((p) => !otherPerms.includes(p));\n }\n\n const topic = perm.name.split('_')[0];\n console.dir(topic);\n\n if (turnOn) {\n const viewPerm = this.employeePermissions.includes(`${topic}_view`);\n if (!viewPerm) {\n this.employeePermissions.push(`${topic}_view`);\n }\n }\n });\n },\n saveCompanyEmployeeInit() {\n const employeeData = {};\n\n if (this.employeeClone.first_name !== this.employee.first_name) {\n employeeData.first_name = this.employeeClone.first_name;\n }\n if (this.employeeClone.last_name !== this.employee.last_name) {\n employeeData.last_name = this.employeeClone.last_name;\n }\n if (this.employeeClone.phone !== this.employee.phone) {\n employeeData.phone = this.employeeClone.phone;\n }\n if (this.employeeClone.email !== this.employee.email) {\n employeeData.email = this.employeeClone.email;\n }\n\n if (Object.keys(employeeData).length === 0 && employeeData.constructor === Object) {\n return;\n }\n\n this.saveCompanyEmployee({\n employee_uuid: this.$route.params.e_id,\n data: employeeData,\n });\n },\n formatTitles(word: string) {\n if (!word) return '';\n const title = word.split('_');\n return title.map((word) => word[0].toUpperCase() + word.substring(1)).join(' ');\n },\n async fetchCompanyEmployee() {\n try {\n const response = await this.form.get(`/v1/employees/${this.$route.params.e_id}`);\n\n this.$store.commit('company/SET_COMPANY_EMPLOYEE', get(response, 'data.employee'));\n this.form = new Form(get(response, 'data.employee'));\n } catch (er) {\n console.dir(er);\n }\n },\n\n async saveEmployee() {\n try {\n this.form = new Form(this.employee);\n const response = await this.form.put(`/v1/employees/${this.employee.uuid}`);\n this.$store.commit('company/SET_COMPANY_EMPLOYEE', response.data.employee);\n push.success({\n message: 'Company employee saved',\n });\n\n } catch (er) {\n console.dir(er);\n }\n },\n\n async deleteCompanyEmployee() {\n try {\n this.form = new Form();\n const response = await this.form.delete(`/v1/employees/${this.employee.uuid}`);\n\n if (get(response, 'data.company')) {\n this.$store.commit('company/SET_COMPANY', get(response, 'data.company'));\n }\n push.success({\n message: 'Company employee deleted',\n });\n this.$router.push({name: 'settings.account'}).catch(() => {\n });\n } catch (er) {\n console.dir(er);\n }\n },\n\n sendEmployeeInvite() {\n console.dir('sendEmployeeInvite');\n },\n\n deleteEmployee() {\n this.deleteConfirmDialog = true;\n },\n\n deleteEmployeeConfirmed() {\n this.deleteConfirmDialog = false;\n this.deleteCompanyEmployee(this.employee);\n },\n\n employeeInitials(employee) {\n let acronym = '';\n if (employee.first_name && employee.last_name) {\n acronym = employee.first_name.slice(0, 1) + employee.last_name.slice(0, 1);\n } else {\n let matches = employee.name.match(/\\b(\\w)/g);\n\n if (matches && matches.length > 2) {\n matches = matches.slice(0, 2);\n acronym = matches.join('');\n }\n }\n return acronym;\n },\n },\n\n beforeUnmount() {\n EventBus.$off('employee-updated-success');\n this.$store.commit('company/RESET_EMPLOYEE');\n },\n};\n</script>\n","<template>\n <div>\n <router-view/>\n </div>\n</template>\n","<template>\n <div>\n <v-card>\n <v-card-title class=\"py-4\">\n <div class=\"flex items-center\">\n <h1 class=\"text-xl font-semibold\">Branches</h1>\n <v-spacer/>\n <v-btn\n :to=\"{name: 'settings.fleet.branches.new'}\"\n class=\"text-decoration-none\"\n color=\"primary\"\n size=\"small\"\n >\n Add Branch\n </v-btn>\n </div>\n </v-card-title>\n <v-card-text>\n <p class=\"text-sm text-gray-600 mb-6\">\n Create and manage multiple fleet locations to organize your listings, extras, and pickup/return locations.\n </p>\n <div class=\"overflow-x-auto rounded-lg border border-gray-200\">\n <table class=\"w-full text-sm text-left text-gray-500 dark:text-gray-400\">\n <thead class=\"text-xs text-gray-700 uppercase bg-gray-50 dark:bg-gray-700 dark:text-gray-400\">\n <tr>\n <th class=\"px-6 py-4 whitespace-nowrap\" scope=\"col\">#</th>\n <th class=\"px-6 py-4 whitespace-nowrap\" scope=\"col\">Name</th>\n <th class=\"px-6 py-4 whitespace-nowrap\" scope=\"col\">Branch Location</th>\n <th class=\"px-6 py-4 whitespace-nowrap\" scope=\"col\">Default Pickup Location</th>\n <th class=\"px-6 py-4 whitespace-nowrap\" scope=\"col\">Default Return Location</th>\n </tr>\n </thead>\n <tbody class=\"divide-y divide-gray-200\">\n <tr v-for=\"(branch, index) in branches\" :key=\"branch.uuid\" class=\"hover:bg-gray-50\">\n <td class=\"px-6 py-4 whitespace-nowrap\">{{ index + 1 }}</td>\n <th class=\"px-6 py-4 font-medium text-gray-900 whitespace-nowrap dark:text-white\" scope=\"row\">\n <router-link :to=\"{name: 'settings.fleet.branches.single', params: {uuid: branch.uuid}}\" class=\"hover:underline\">\n {{ branch.name }}\n </router-link>\n </th>\n <td class=\"px-6 py-4 whitespace-nowrap\">\n <span v-if=\"branchLocationName(branch)\" v-tippy=\"branchLocationName(branch)\">\n {{ branchLocationLine1(branch) }}\n </span>\n <span v-else>\n {{ branch.pickup_location }}\n </span>\n </td>\n <td class=\"px-6 py-4 whitespace-nowrap\">{{ branch.pickup_location }}</td>\n <td class=\"px-6 py-4 whitespace-nowrap\">{{ branch.return_location }}</td>\n </tr>\n </tbody>\n </table>\n </div>\n </v-card-text>\n </v-card>\n </div>\n</template>\n\n<script lang=\"ts\" setup>\nimport {onMounted} from 'vue';\nimport {TenantBranch} from '@/types';\nimport {useBranch} from '@/composables/useBranch';\n\nconst {branches, getFleetBranches} = useBranch();\n\nconst branchLocationName = (branch: TenantBranch) => {\n return branch?.location?.name;\n};\n\nconst branchLocationLine1 = (branch: TenantBranch) => {\n return branch?.location?.address_line1;\n};\n\nonMounted(() => {\n getFleetBranches();\n});\n</script>\n\n","<template>\n <div>\n <v-card :disabled=\"fleetLoading.createBranch\" :loading=\"fleetLoading.createBranch\">\n <v-card-title>\n New branch\n </v-card-title>\n <v-card-text class=\"mt-3\">\n <v-form v-model=\"branchForm\">\n <div class=\"grid grid-cols-1 md:grid-cols-2 gap-4\">\n <v-text-field\n v-model=\"currentWorkingBranch.name\"\n class=\"w-full\"\n label=\"Name\"\n name=\"name\"\n required\n variant=\"outlined\"\n />\n <v-text-field\n v-model=\"currentWorkingBranch.email\"\n class=\"w-full\"\n label=\"Email\"\n required\n variant=\"outlined\"\n />\n </div>\n\n <div class=\"grid grid-cols-1 md:grid-cols-2 gap-4 mt-4\">\n <v-select\n v-model=\"currentWorkingBranch.document\"\n :items=\"documents\"\n class=\"w-full\"\n item-title=\"name\"\n item-value=\"uuid\"\n label=\"Rental Agreement\"\n return-object\n variant=\"outlined\"\n >\n <template v-slot:item=\"{ props, item }\">\n <v-list-item :subtitle=\"item.raw.uuid\" v-bind=\"props\"></v-list-item>\n </template>\n </v-select>\n <v-autocomplete\n v-model=\"currentWorkingBranch.timezone\"\n :items=\"timezones\"\n :label=\"$t('timezone')\"\n :persistent-hint=\"true\"\n class=\"w-full\"\n hint=\"This timezone will be used for listings when a branch is assigned to it.\"\n variant=\"outlined\"\n />\n </div>\n\n <div class=\"mt-8 mb-10 pt-4 border-t\">\n <h4 class=\"text-lg font-semibold mb-4\">Location Settings</h4>\n <MapBoxAddressAutofill\n class=\"w-full\"\n @locationData=\"addLocationData\"\n />\n </div>\n </v-form>\n <div v-if=\"formErrors\" class=\"space-y-2\">\n <v-alert v-for=\"(error, index) in formErrors\" :key=\"index\" type=\"error\" variant=\"outlined\">\n {{ error[0] }}\n </v-alert>\n </div>\n </v-card-text>\n <v-divider/>\n <v-card-actions>\n <v-spacer/>\n <v-btn variant=\"text\" @click=\"router.push({ name: 'settings.fleet.branches' }).catch(() => {});\">Cancel</v-btn>\n <v-btn :loading=\"fleetLoading.createBranch\" @click=\"createFleetBranch(currentWorkingBranch)\">Save</v-btn>\n </v-card-actions>\n </v-card>\n </div>\n</template>\n\n<script lang=\"ts\" setup>\nimport {computed, onBeforeMount, ref} from 'vue';\nimport {guessTimeZone, timezones} from '@/utils/dates';\nimport {useStore} from 'vuex';\nimport MapBoxAddressAutofill from '@/components/widgets/MapBoxAddressAutofill.vue';\nimport {useRouter} from 'vue-router';\nimport {TenantBranch, TenantBranchLocation} from '@/types';\nimport {TemplateData} from '@/store/modules/document';\nimport {useTemplate} from '@/composables/useTemplate';\nimport {useBranch} from '@/composables/useBranch';\n\nconst router = useRouter();\nconst {getters} = useStore();\n\nconst {fetchTemplates, documentTemplates} = useTemplate();\nconst {createBranch} = useBranch();\n\nconst fleetLoading = computed(() => getters['fleet/loading']);\nconst documents = computed(() => {\n const templates = documentTemplates.value?.filter((t: TemplateData) => t?.documents);\n\n return templates.map((t: TemplateData) => ({\n name: t?.documents?.name,\n uuid: t?.documents?.uuid,\n }));\n});\n\nconst currentWorkingBranch = ref<TenantBranch>({\n active: true,\n short_code: '',\n set: false,\n name: '',\n uuid: '',\n email: '',\n pickup_location: '',\n return_location: '',\n pickup_location_id: '',\n return_location_id: '',\n timezone: '',\n document: null,\n location_id: '',\n location: null,\n order: null,\n document_set: null,\n});\nconst branchForm = ref(null);\nconst formErrors = ref(null);\n\n\nconst createFleetBranch = async (branch: TenantBranch) => {\n await createBranch(branch).then(() => {\n router.push({name: 'settings.fleet.branches'}).catch(() => {\n });\n }).catch((error) => {\n console.dir(error);\n formErrors.value = error.response.data.errors;\n });\n};\n\nconst addLocationData = (locationData: TenantBranchLocation) => {\n currentWorkingBranch.value.location = locationData;\n};\n\nonBeforeMount(() => {\n fetchTemplates();\n\n currentWorkingBranch.value.timezone = guessTimeZone;\n});\n</script>\n","<template>\n <div>\n <v-card :disabled=\"branchLoading.updateBranch || branchLoading.fetchBranch\" :loading=\"branchLoading.fetchBranch || branchLoading.updateBranch\">\n <v-card-title>\n Branch: {{ branch?.name }}\n </v-card-title>\n <v-card-text class=\"mt-3\">\n <v-form v-if=\"currentWorkingBranch.set\">\n <div class=\"space-y-6\">\n <!-- Name Field -->\n <div class=\"grid grid-cols-1 md:grid-cols-2 gap-4\">\n <div v-show=\"!editBranch.name\" class=\"flex items-center space-x-2\">\n <span class=\"font-bold\">Name:</span>\n <span>{{ branch.name }}</span>\n <v-btn size=\"small\" variant=\"text\" @click=\"editBranch.name = !editBranch.name\">\n <v-icon size=\"small\">mdi-pencil</v-icon>\n </v-btn>\n </div>\n <v-text-field\n v-show=\"editBranch.name\"\n v-model=\"currentWorkingBranch.name\"\n class=\"w-full\"\n label=\"Name\"\n variant=\"outlined\"\n />\n </div>\n\n <!-- Email Field -->\n <div class=\"grid grid-cols-1 md:grid-cols-2 gap-4\">\n <div class=\"flex items-center space-x-2\">\n <span class=\"font-bold\">Email:</span>\n <span>{{ branch.email }}</span>\n <v-btn size=\"small\" variant=\"text\" @click=\"editBranch.email = !editBranch.email\">\n <v-icon size=\"small\">mdi-pencil</v-icon>\n </v-btn>\n </div>\n <v-text-field\n v-show=\"editBranch.email\"\n v-model=\"currentWorkingBranch.email\"\n class=\"w-full\"\n label=\"Email\"\n variant=\"outlined\"\n />\n </div>\n\n <!-- Rental Agreement Field -->\n <div class=\"grid grid-cols-1 md:grid-cols-2 gap-4\">\n <div class=\"flex items-center space-x-2\">\n <span class=\"font-bold\">Rental Agreement:</span>\n <span>{{ documentName(document) }}</span>\n <v-btn size=\"small\" variant=\"text\" @click=\"editBranch.agreement = !editBranch.agreement\">\n <v-icon size=\"small\">mdi-pencil</v-icon>\n </v-btn>\n </div>\n <v-select\n v-show=\"editBranch.agreement\"\n v-model=\"currentWorkingBranch.document\"\n :items=\"documents\"\n class=\"w-full\"\n item-title=\"name\"\n item-value=\"uuid\"\n label=\"Rental Agreement\"\n return-object\n variant=\"outlined\"\n >\n <template v-slot:item=\"{ props, item }\">\n <v-list-item :subtitle=\"item.raw.uuid\" v-bind=\"props\"/>\n </template>\n </v-select>\n </div>\n\n <!-- Timezone Field -->\n <div class=\"grid grid-cols-1 md:grid-cols-2 gap-4\">\n <div class=\"flex items-center space-x-2\">\n <span class=\"font-bold\">Timezone:</span>\n <span>{{ currentWorkingBranch.timezone }}</span>\n <v-btn size=\"small\" variant=\"text\" @click=\"editBranch.timezone = !editBranch.timezone\">\n <v-icon size=\"small\">mdi-pencil</v-icon>\n </v-btn>\n </div>\n <v-autocomplete\n v-show=\"editBranch.timezone\"\n v-model=\"currentWorkingBranch.timezone\"\n :items=\"timezones\"\n :label=\"$t('timezone')\"\n :persistent-hint=\"true\"\n class=\"w-full\"\n hint=\"This will set all your listings timezone under this branch\"\n variant=\"outlined\"\n />\n </div>\n\n <!-- Location Settings -->\n <div class=\"mt-8 pt-4 border-t\">\n <h4 class=\"text-lg font-semibold mb-4\">Location Settings</h4>\n\n <!-- Branch location -->\n <div class=\"space-y-4\">\n <div class=\"flex items-center space-x-2\">\n <span class=\"font-bold\">Branch Location</span>\n <v-btn size=\"small\" variant=\"text\" @click=\"changeLocationInit()\">\n <v-icon size=\"small\">mdi-pencil</v-icon>\n </v-btn>\n </div>\n\n <div v-if=\"branchLocationName && !editingLocation\" class=\"space-y-4\">\n <p>{{ branchLocationName }}</p>\n <v-img\n :src=\"locationStaticMap\"\n class=\"rounded-lg\"\n height=\"200\"\n width=\"300\"\n />\n </div>\n <div v-else>\n <MapBoxAddressAutofill\n class=\"w-full\"\n @locationData=\"addLocationData\"\n />\n </div>\n </div>\n\n <!-- Pickup/Return location -->\n <div class=\"mt-6 space-y-4\">\n <div class=\"flex items-center space-x-2\">\n <span class=\"font-bold\">Pickup/Return Location:</span>\n <span v-if=\"pickupReturnSameAsBranch\">Same as branch</span>\n <span v-else>{{ branchClone.pickup_location }}</span>\n <v-btn size=\"small\" variant=\"text\" @click=\"editBranch.pickup_location = !editBranch.pickup_location\">\n <v-icon size=\"small\">mdi-pencil</v-icon>\n </v-btn>\n </div>\n\n <div v-show=\"editBranch.pickup_location\" class=\"border rounded p-4 space-y-4\">\n <v-checkbox\n v-model=\"pickupReturnSameAsBranch\"\n label=\"Same as branch location\"\n />\n <div v-if=\"!pickupReturnSameAsBranch\" class=\"grid grid-cols-1 md:grid-cols-2 gap-4\">\n <v-text-field\n v-model=\"currentWorkingBranch.pickup_location\"\n class=\"w-full\"\n label=\"Default Pickup Location\"\n variant=\"outlined\"\n />\n <v-text-field\n v-model=\"currentWorkingBranch.return_location\"\n class=\"w-full\"\n label=\"Default Return Location\"\n variant=\"outlined\"\n />\n </div>\n </div>\n </div>\n </div>\n </div>\n </v-form>\n <div v-else class=\"flex justify-center items-center py-8\">Loading...</div>\n </v-card-text>\n <v-divider opacity=\"50\"/>\n <v-card-actions>\n <DeleteButton @deleteConfirmed=\"deleteFleetBranchInit()\"/>\n <v-spacer/>\n <v-btn variant=\"text\" @click=\"router.push({ name: 'settings.fleet.branches' }).catch(() => {});\">Back</v-btn>\n <v-btn :loading=\"branchLoading.updateBranch\" color=\"primary\" @click=\"updateFleetBranchInit()\">Save</v-btn>\n </v-card-actions>\n </v-card>\n\n <v-dialog v-model=\"matchPickupReturnLocationToBranchDialog\" width=\"400\">\n <v-card>\n <v-card-title>\n Update Locations\n </v-card-title>\n <v-card-text>\n Do you want to make the pickup & return locations the same as the branch location?\n </v-card-text>\n <v-card-actions>\n <v-spacer/>\n <v-btn variant=\"text\" @click=\"matchPickupReturnLocationToBranchDialog = false;\">No</v-btn>\n <v-btn color=\"primary\" @click=\"matchPickupReturnLocationsToBranch()\">Yes</v-btn>\n </v-card-actions>\n </v-card>\n </v-dialog>\n </div>\n</template>\n\n\n<script lang=\"ts\" setup>\nimport {computed, defineAsyncComponent, onBeforeMount, onBeforeUnmount, ref, watch} from 'vue';\nimport MapBoxAddressAutofill from '@/components/widgets/MapBoxAddressAutofill.vue';\nimport {timezones} from '@/utils/dates';\nimport {useBranch} from '@/composables/useBranch';\nimport {useStore} from 'vuex';\nimport {useRouter} from 'vue-router';\nimport {TenantBranch, TenantBranchLocation} from '@/types';\nimport {DocumentType, TemplateData} from '@/store/modules/document';\nimport {useTemplate} from '@/composables/useTemplate';\n\nconst DeleteButton = defineAsyncComponent(() => import('@/components/buttons/DeleteButton.vue'));\n\n\nconst router = useRouter();\nconst store = useStore();\nconst {branch, deleteFleetBranch, getFleetBranch, branchLoading} = useBranch();\nconst {documentTemplates, fetchTemplates} = useTemplate();\n\n//\nconst currentBranchUuid = router.currentRoute.value.params.uuid as string;\nconst confirmDelete = ref(false);\nconst editingLocation = ref(false);\nconst matchPickupReturnLocationToBranchDialog = ref(false);\nconst currentWorkingBranch = ref<TenantBranch>({\n active: true,\n short_code: '',\n set: false,\n name: '',\n uuid: '',\n email: '',\n pickup_location: '',\n return_location: '',\n pickup_location_id: '',\n return_location_id: '',\n timezone: '',\n document: null,\n location_id: '',\n location: null,\n order: null,\n document_set: null,\n});\nconst branchClone = ref<TenantBranch>({\n active: true,\n short_code: '',\n set: false,\n name: '',\n uuid: '',\n email: '',\n pickup_location: '',\n return_location: '',\n pickup_location_id: '',\n return_location_id: '',\n timezone: '',\n document: null,\n location_id: '',\n location: null,\n order: null,\n document_set: null,\n});\nconst pickupReturnSame = ref(true);\nconst pickupReturnSameAsBranch = ref(true);\nconst editBranch = ref({\n name: false,\n email: false,\n pickup_location: false,\n agreement: false,\n timezone: false,\n});\n\n// computed\nconst missingNewLocationInfo = computed(() => !branchClone.value.location);\nconst documents = computed(() => {\n if (!documentTemplates?.value) return [];\n\n const filteredTemplates = documentTemplates.value?.filter((t: TemplateData) => t?.documents);\n\n return filteredTemplates.map((t: TemplateData) => ({\n name: t?.documents?.name,\n uuid: t?.documents?.uuid,\n }));\n});\nconst document = computed({\n get() {\n return currentWorkingBranch.value.document;\n },\n set(value) {\n currentWorkingBranch.value.document = value;\n },\n});\n\nconst branchLocation = computed(() => currentWorkingBranch.value?.location);\nconst branchLocationName = computed(() => branchLocation.value?.name);\n\nconst locationStaticMap = computed<string>(() => {\n const {lat, lng} = branchLocation.value;\n\n const pin = `pin-s+555555(${lng},${lat})`;\n return `https://api.mapbox.com/styles/v1/mapbox/streets-v11/static/${pin}/${lng},${lat},13,0/300x200?access_token=${import.meta.env.VITE_MAPBOX_TOKEN}`;\n});\n\nconst deleteFleetBranchInit = () => {\n deleteFleetBranch(branchClone.value.uuid).then(() => {\n router.push({name: 'settings.fleet.branches'}).catch(() => {\n });\n }).catch(() => {\n confirmDelete.value = false;\n });\n};\n\nconst updateFleetBranch = (branch: TenantBranch) => store.dispatch('fleet/updateFleetBranch', branch).then((updatedBranch) => {\n editingLocation.value = false;\n branchClone.value = JSON.parse(JSON.stringify(updatedBranch));\n currentWorkingBranch.value = branchClone.value;\n currentWorkingBranch.value.set = true;\n});\n\nconst updateFleetBranchInit = () => {\n if (pickupReturnSameAsBranch.value) {\n currentWorkingBranch.value.pickup_location = currentWorkingBranch.value.location;\n currentWorkingBranch.value.return_location = currentWorkingBranch.value.location;\n }\n\n updateFleetBranch(currentWorkingBranch.value);\n};\n\nwatch(branch, (branch) => {\n if (branch?.uuid) {\n branchClone.value = JSON.parse(JSON.stringify(branch));\n pickupReturnSame.value = branchClone.value.pickup_location === branchClone.value.return_location;\n pickupReturnSameAsBranch.value = (branchClone.value.pickup_location_id === branchClone.value.return_location_id\n && branchClone.value.pickup_location_id === branchClone.value.location_id) || (branchClone.value.location_id && !branchClone.value.pickup_location_id && !branchClone.value.return_location_id);\n currentWorkingBranch.value = branchClone.value;\n currentWorkingBranch.value.document = branchClone.value.document;\n currentWorkingBranch.value.set = true;\n }\n}, {immediate: true});\n\nconst matchPickupReturnLocationsToBranch = () => {\n matchPickupReturnLocationToBranchDialog.value = true;\n currentWorkingBranch.value.pickup_location = currentWorkingBranch.value.location;\n currentWorkingBranch.value.return_location = currentWorkingBranch.value.location;\n pickupReturnSame.value = true;\n pickupReturnSameAsBranch.value = true;\n};\n\nconst documentName = (document: DocumentType) => {\n return document?.name || 'NA';\n};\n\nconst addLocationData = (locationData: TenantBranchLocation) => {\n currentWorkingBranch.value.location = locationData;\n\n if (missingNewLocationInfo.value) {\n matchPickupReturnLocationToBranchDialog.value = true;\n }\n};\n\nconst changeLocationInit = () => {\n editingLocation.value = !editingLocation.value;\n};\n\nonBeforeMount(() => {\n getFleetBranch(currentBranchUuid);\n fetchTemplates();\n});\n\nonBeforeUnmount(() => {\n console.dir('onBeforeUnmount');\n store.commit('fleet/SET_COMPANY_BRANCH', {});\n currentWorkingBranch.value = {\n active: true,\n short_code: '',\n set: false,\n name: '',\n uuid: '',\n email: '',\n pickup_location: '',\n return_location: '',\n pickup_location_id: '',\n return_location_id: '',\n timezone: '',\n document: null,\n location_id: '',\n location: null,\n order: null,\n document_set: null,\n };\n branchClone.value = {\n active: true,\n short_code: '',\n set: false,\n name: '',\n uuid: '',\n email: '',\n pickup_location: '',\n return_location: '',\n pickup_location_id: '',\n return_location_id: '',\n timezone: '',\n document: null,\n location_id: '',\n location: null,\n order: null,\n document_set: null,\n };\n});\n\n</script>\n\n","<template>\n <div>\n <v-card :loading=\"vehicleLoading.classes\">\n <v-card-title>\n <div class=\"flex\">\n Vehicle Classes\n <v-spacer/>\n <v-btn\n :to=\"{name: 'settings.fleet.classes.new'}\"\n class=\"text-decoration-none\"\n size=\"small\"\n >\n Add Class\n </v-btn>\n </div>\n </v-card-title>\n <v-card-text class=\"mt-5\">\n <!-- Desktop Table View -->\n <div class=\"hidden md:block\">\n <div class=\"relative overflow-x-auto shadow-md sm:rounded-lg\">\n <table class=\"w-full text-sm text-left text-gray-500 dark:text-gray-400\">\n <thead class=\"text-xs text-gray-700 uppercase bg-gray-50 dark:bg-gray-700 dark:text-gray-400\">\n <tr>\n <th class=\"px-6 py-3\" scope=\"col\">Name</th>\n <th class=\"px-6 py-3\" scope=\"col\">Minimum Age</th>\n <th class=\"px-6 py-3\" scope=\"col\">SIPP Code</th>\n <th class=\"px-6 py-3\" scope=\"col\">Vehicles</th>\n <th class=\"px-6 py-3\" scope=\"col\">Branch</th>\n <th class=\"px-6 py-3\" scope=\"col\">\n <span class=\"sr-only\">Edit</span>\n </th>\n </tr>\n </thead>\n <tbody>\n <tr v-for=\"(vehicleClass, index) in vehicleClasses\"\n :key=\"index\"\n class=\"bg-white border-b dark:bg-gray-800 dark:border-gray-700 hover:bg-gray-50 dark:hover:bg-gray-600\">\n <th class=\"px-6 py-4 font-medium text-gray-900 whitespace-nowrap dark:text-white\" scope=\"row\">\n <router-link :to=\"{name: 'settings.fleet.classes.single', params: {uuid: vehicleClass.uuid}}\" class=\"underline\">\n {{ vehicleClass.name }}\n </router-link>\n </th>\n <td class=\"px-6 py-4\">{{ vehicleClass.minimum_age }}</td>\n <td class=\"px-6 py-4\">{{ vehicleClass.sipp_code }}</td>\n <td class=\"px-6 py-4\">{{ vehicleClass.vehicles_count }}</td>\n <td class=\"px-6 py-4\">{{ branchName(vehicleClass) }}</td>\n <td class=\"px-6 py-4 text-right\">\n <router-link\n :to=\"{name: 'settings.fleet.classes.single', params: {uuid: vehicleClass.uuid}}\"\n class=\"font-medium text-blue-600 dark:text-blue-500 hover:underline\"\n >\n Edit\n </router-link>\n </td>\n </tr>\n </tbody>\n </table>\n </div>\n </div>\n\n <!-- Mobile Card View -->\n <div class=\"md:hidden grid grid-cols-1 gap-4\">\n <div v-for=\"(vehicleClass, index) in vehicleClasses\"\n :key=\"index\"\n class=\"bg-white dark:bg-gray-800 rounded-lg shadow p-4 hover:shadow-md transition-shadow\">\n <div class=\"flex justify-between items-start mb-3\">\n <router-link\n :to=\"{name: 'settings.fleet.classes.single', params: {uuid: vehicleClass.uuid}}\"\n class=\"text-lg font-medium text-blue-600 dark:text-blue-400 hover:underline\">\n {{ vehicleClass.name }}\n </router-link>\n <router-link\n :to=\"{name: 'settings.fleet.classes.single', params: {uuid: vehicleClass.uuid}}\"\n class=\"text-sm text-gray-500 hover:text-gray-700 dark:text-gray-400 dark:hover:text-gray-200\">\n Edit\n </router-link>\n </div>\n\n <div class=\"space-y-2 text-sm text-gray-600 dark:text-gray-300\">\n <div class=\"flex justify-between\">\n <span class=\"font-medium\">Minimum Age:</span>\n <span>{{ vehicleClass.minimum_age }}</span>\n </div>\n <div class=\"flex justify-between\">\n <span class=\"font-medium\">SIPP Code:</span>\n <span>{{ vehicleClass.sipp_code }}</span>\n </div>\n <div class=\"flex justify-between\">\n <span class=\"font-medium\">Vehicles:</span>\n <span>{{ vehicleClass.vehicles_count }}</span>\n </div>\n <div class=\"flex justify-between\">\n <span class=\"font-medium\">Branch:</span>\n <span>{{ branchName(vehicleClass) }}</span>\n </div>\n </div>\n </div>\n </div>\n </v-card-text>\n </v-card>\n </div>\n</template>\n\n<script lang=\"ts\" setup>\nimport {useStore} from 'vuex';\nimport {computed, onBeforeMount} from 'vue';\nimport {VehicleClass} from '@/types';\n\nconst {getters, dispatch} = useStore();\nconst vehicleClasses = computed(() => getters['vehicles/vehicleClasses']);\nconst vehicleLoading = computed(() => getters['vehicles/vehicleLoading']);\n\nconst getVehicleClasses = () => {\n dispatch('vehicles/getVehicleClasses');\n};\n\nconst branchName = (item: VehicleClass) => {\n return item?.branch?.name;\n};\n\n\nonBeforeMount(() => {\n getVehicleClasses();\n});\n</script>\n\n","<template>\n <v-dialog v-model=\"isOpen\" :scrollable=\"true\" width=\"600\">\n <v-card>\n <v-card-title>SIPP</v-card-title>\n\n <v-card-text>\n <p class=\"mb-3 font-normal text-gray-700 dark:text-gray-400\">\n Standard Interline Passenger Procedure (SIPP) codes are four-letter abbreviations that identify the major\n features of a rental car. For example, a compact, two-door car with air conditioning would have a SIPP code\n of CBMR or CBAR depending on whether it’s a manual or an automatic.\n </p>\n <table class=\"w-full text-sm text-left text-gray-500 dark:text-gray-400\">\n <tbody>\n <tr class=\"bg-white border-b dark:bg-gray-900 dark:border-gray-700\">\n <td style=\"text-align: center;\">\n <strong>First Letter</strong> <br/>Size of vehicle\n </td>\n <td>\n <strong>C</strong> - Compact<br> <strong>D</strong> - Compact Elite<br>\n <strong>E</strong> - Economy<br> <strong>F</strong> - Fullsize<br>\n <strong>G</strong> - Fullsize Elite<br> <strong>H</strong> - Economy Elite<br>\n <strong>I</strong> - Intermediate<br> <strong>J</strong> - Intermediate Elite<br>\n <strong>L</strong> - Luxury<br> <strong>M</strong> - Mini<br> <strong>N</strong> - Mini Elite<br>\n <strong>O</strong> - Oversize<br> <strong>P</strong> - Premium<br>\n <strong>R</strong> - Standard Elite<br> <strong>S</strong> - Standard<br>\n <strong>U</strong> - Premium Elite<br> <strong>W</strong> - Luxury Elite<br>\n <strong>X</strong> - Special<br></td>\n </tr>\n <tr class=\"border-b bg-gray-50 dark:bg-gray-800 dark:border-gray-700\">\n <td style=\"text-align: center;\"><strong>Second Letter<br></strong>Number of doors</td>\n <td><strong>B</strong> - 2/3 Door<br> <strong>C</strong> - 2 or 4 Door<br>\n <strong>D</strong> - 4/5 Door<br> <strong>E</strong> - Coupe<br> <strong>F</strong> - SUV<br>\n <strong>G</strong> - Crossover<br> <strong>H</strong> - Motorhome<br>\n <strong>J</strong> - Open-Air All Terrain<br> <strong>K</strong> - Commercial Van / Truck<br>\n <strong>L</strong> - Limousine<br> <strong>M</strong> - Monospace<br> <strong>N</strong> - Roadster<br>\n <strong>P</strong> - Pickup Regular Cab<br> <strong>Q</strong> - Pickup Extended Cab<br>\n <strong>R</strong> - Recreational<br> <strong>S</strong> - Sport<br>\n <strong>T</strong> - Convertible<br> <strong>V</strong> - Passenger Van<br>\n <strong>W</strong> - Wagon / Estate<br> <strong>X</strong> - Special<br>\n <strong>Y</strong> - Two-Wheel Drive<br> <strong>Z</strong> - Special Offer Car<br></td>\n </tr>\n <tr class=\"bg-white border-b dark:bg-gray-900 dark:border-gray-700\">\n <td style=\"text-align: center;\"><strong>Third Letter</strong> <br>Transmission and drive</td>\n <td><strong>A</strong> - Auto Drive<br> <strong>B</strong> - Auto Four-Wheel Drive<br>\n <strong>C</strong> - Manual All-Wheel Drive<br> <strong>D</strong> - Auto All-Wheel Drive<br>\n <strong>M</strong> - Manual Drive<br> <strong>N</strong> - Manual Four-Wheel Drive\n </td>\n </tr>\n <tr class=\" bg-gray-50 dark:bg-gray-800 dark:border-gray-700\">\n <td style=\"text-align: center;\"><strong>Fourth Letter<br></strong>Fuel and A/C<br></td>\n <td><strong>N</strong> - Unspecified Fuel, No A/C<br> <strong>R</strong> - Unspecified Fuel, A/C<br>\n <strong>V</strong> - Petrol, A/C<br> <strong>Z</strong> - Petrol, No A/C<br>\n <strong>D</strong> - Diesel, A/C<br> <strong>Q</strong> - Diesel, No A/C<br>\n <strong>E</strong> - Electric, A/C<br> <strong>C</strong> - Electric, No A/C<br>\n <strong>H</strong> - Hybrid, A/C<br> <strong>I</strong> - Hybrid, No A/C<br>\n <strong>L</strong> - LPG/Gas, A/C<br> <strong>S</strong> - LPG/Gas, No A/C<br>\n <strong>M</strong> - Multi Fuel, A/C<br> <strong>F</strong> - Multi Fuel, No A/C<br>\n <strong>A</strong> - Hydrogen, A/C<br> <strong>B</strong> - Hydrogen, No A/C<br>\n <strong>U</strong> - Ethanol, A/C<br> <strong>X</strong> - Ethanol, No A/C\n </td>\n </tr>\n </tbody>\n </table>\n </v-card-text>\n\n <v-divider/>\n\n <v-card-actions>\n <v-spacer/>\n <v-btn color=\"primary\" variant=\"text\" @click=\"closeDialog\">Okay</v-btn>\n </v-card-actions>\n </v-card>\n </v-dialog>\n</template>\n\n<script lang=\"ts\" setup>\nimport {computed} from 'vue';\n\nconst props = defineProps({\n modelValue: {\n type: Boolean,\n required: true,\n },\n});\n\n// Emit Event\nconst emit = defineEmits(['update:modelValue']);\n\n// Close Dialog\nconst closeDialog = () => {\n isOpen.value = false;\n};\n\n// Computed binding for the dialog\nconst isOpen = computed({\n get: () => props.modelValue,\n set: (value: boolean) => emit('update:modelValue', value),\n});\n</script>\n","import {useStore} from 'vuex';\nimport {computed} from 'vue';\nimport {VehicleClass} from \"@/types\";\n\nconst COLORS = ['black', 'blue', 'brown', 'gold', 'gray', 'green', 'orange', 'purple', 'red', 'silver', 'white', 'yellow', 'other'];\nconst VEHICLE_STATUSES = ['available', 'dirty', 'out of service', 'for sale', 'sold', 'new', 'reserved', 'rental', 'maintenance', 'other'];\n\nconst mapToTitleCodeArray = (statuses: string[]) => statuses.map(item => ({\n // uppercase first letter of each word\n title: item.split(' ').map(word => word.charAt(0).toUpperCase() + word.slice(1)).join(' '),\n code: item\n}));\n\n\nexport function useVehicle() {\n const store = useStore();\n\n\n const vehicleLoading = computed(() => store.getters['vehicles/vehicleLoading']);\n const vehicleMakes = computed(() => store.getters['vehicles/vehicleMakes']);\n const vehicleModels = computed(() => store.getters['vehicles/vehicleModels']);\n const vehicleColors = computed(() => mapToTitleCodeArray(COLORS));\n const availableVehicleStatuses = computed(() => mapToTitleCodeArray(VEHICLE_STATUSES));\n const vehicleClasses = computed(() => store.getters['vehicles/vehicleClasses']);\n const vehicleClass = computed<VehicleClass>(() => store.getters['vehicles/vehicleClass'])\n const vehicleClassForm = computed(() => store.getters['vehicles/vehicleClassForm']);\n const vehicleClassCreated = computed(() => store.getters['vehicles/vehicleClassCreated']);\n\n const getVehicleClass = (uuid: string) => {\n return store.dispatch('vehicles/getClass', uuid);\n }\n const createVehicleClass = (vehicleClass: VehicleClass) => {\n return store.dispatch('vehicles/createClass', vehicleClass);\n }\n const fetchVehicleMakes = () => {\n store.dispatch('vehicles/fetchVehicleMakes');\n }\n\n const fetchVehicleModels = (make: string) => {\n return store.dispatch('vehicles/fetchVehicleModels', make);\n }\n\n const deleteVehicleClass = (uuid: string) => {\n return store.dispatch('vehicles/deleteClass', uuid);\n }\n const updateVehicleClass = (vehicleClass: VehicleClass) => {\n return store.dispatch('vehicles/updateClass', vehicleClass);\n }\n const getVehicleClasses = (refresh = false) => {\n return store.dispatch('vehicles/getVehicleClasses', refresh);\n }\n\n return {\n vehicleColors,\n availableVehicleStatuses,\n vehicleLoading,\n vehicleMakes,\n vehicleModels,\n vehicleClasses,\n vehicleClass,\n vehicleClassForm,\n vehicleClassCreated,\n fetchVehicleMakes,\n fetchVehicleModels,\n getVehicleClass,\n deleteVehicleClass,\n updateVehicleClass,\n getVehicleClasses,\n createVehicleClass,\n }\n}","<template>\n <v-card :disabled=\"vehicleLoading.class\" :loading=\"vehicleLoading.class\">\n <v-card-title>\n New vehicle class\n </v-card-title>\n <v-card-text class=\"mt-3\">\n <v-form class=\"space-y-4\">\n <v-text-field\n v-model=\"currentWorkingClass.name\"\n :error-messages=\"vehicleClassForm.errors.get('name')\"\n class=\"w-full md:w-[300px]\"\n label=\"Name\"\n variant=\"outlined\"\n @keyup=\"commit('vehicles/CLEAR_VEHICLE_FORM_ERRORS', 'name')\"\n />\n <div class=\"flex flex-col md:flex-row md:items-center gap-2\">\n <v-text-field\n v-model=\"currentWorkingClass.sipp_code\"\n :error-messages=\"vehicleClassForm.errors.get('sipp_code')\"\n class=\"w-full md:w-[300px]\"\n label=\"SIPP Code\"\n variant=\"outlined\"\n @keyup=\"commit('vehicles/CLEAR_VEHICLE_FORM_ERRORS', 'sipp_code')\"\n />\n <v-btn size=\"x-small\" variant=\"text\" @click=\"openSippDialog()\">What is SIPP?</v-btn>\n </div>\n <v-text-field\n v-model=\"currentWorkingClass.minimum_age\"\n :error-messages=\"vehicleClassForm.errors.get('minimum_age')\"\n class=\"w-full md:w-[300px]\"\n label=\"Minimum Age\"\n type=\"number\"\n variant=\"outlined\"\n @keyup=\"commit('vehicles/CLEAR_VEHICLE_FORM_ERRORS', 'minimum_age')\"\n />\n <div>\n <v-select\n v-model=\"vehicleClassBranch\"\n :error-messages=\"vehicleClassForm.errors.get('branch')\"\n :items=\"branchesFiltered\"\n append-icon=\"mdi-close\"\n class=\"fleet-branches-select w-full md:w-[300px]\"\n label=\"Branches\"\n variant=\"outlined\"\n @update:modelValue=\"commit('vehicles/CLEAR_VEHICLE_FORM_ERRORS', 'branch')\"\n @click:append=\"vehicleClassBranch = null\"\n >\n <template v-slot:append-item>\n <div class=\"border-t py-5 flex justify-center\">\n <router-link :to=\"{name: 'settings.fleet.branches'}\">\n <span class=\"text-sm\">Manage Fleet Branches</span>\n </router-link>\n </div>\n </template>\n </v-select>\n </div>\n </v-form>\n </v-card-text>\n <v-card-actions class=\"flex flex-wrap gap-2\">\n <v-spacer/>\n <div class=\"flex items-center gap-2\">\n <v-btn size=\"small\" variant=\"text\" @click=\"cancel\">\n Cancel\n </v-btn>\n <v-btn :loading=\"vehicleLoading.class\" @click=\"createVehicleClassInit\">Save</v-btn>\n </div>\n </v-card-actions>\n </v-card>\n <SippDialog v-model=\"isSippDialogOpen\"/>\n</template>\n\n<script lang=\"ts\" setup>\nimport SippDialog from '@/views/dashboard/settings/Fleet/SippDialog.vue';\nimport {computed, onBeforeMount, ref, watch} from 'vue';\nimport {useStore} from 'vuex';\nimport {useRouter} from 'vue-router';\nimport {VehicleClass} from '@/types';\nimport {useVehicle} from '@/composables/useVehicle';\nimport {useBranch} from '@/composables/useBranch';\n\nconst {dispatch, commit} = useStore();\nconst router = useRouter();\n\nconst {createVehicleClass, vehicleClassForm, vehicleLoading, vehicleClassCreated} = useVehicle();\nconst {branches, getFleetBranches} = useBranch();\n\nconst createVehicleClassInit = () => {\n createVehicleClass(currentWorkingClass.value);\n};\n\nconst currentWorkingClass = ref<VehicleClass>({\n name: '',\n uuid: '',\n minimum_age: null,\n sipp_code: '',\n branch: null,\n active: true,\n image_url: null,\n});\n\n\nconst branchesFiltered = computed(() => branches.value.map((b) => ({\n value: b.uuid,\n title: b.name,\n})));\n\nconst isSippDialogOpen = ref(false);\n\nconst openSippDialog = () => {\n isSippDialogOpen.value = true;\n};\n\nonBeforeMount(() => {\n getFleetBranches();\n});\n\nconst vehicleClassBranch = computed({\n get() {\n return currentWorkingClass.value.branch;\n },\n set(value) {\n currentWorkingClass.value.branch = value;\n },\n});\n\nconst cancel = () => {\n router.push({name: 'settings.fleet.classes'}).catch(() => {\n });\n};\n\n\nwatch(branchesFiltered, (filteredBranches) => {\n if (!currentWorkingClass.value.branch && filteredBranches.length === 1) {\n const branch = branches.value.find(b => b.uuid === filteredBranches[0].value);\n if (branch) {\n currentWorkingClass.value.branch = branch;\n }\n }\n}, {immediate: true});\n\nwatch(vehicleClassCreated, (newValue) => {\n if (newValue) {\n dispatch('vehicles/SET_VEHICLE_CLASS_CREATED', false);\n router.push({name: 'settings.fleet.classes'}).catch(() => {\n });\n }\n});\n</script>\n\n","<template>\n <div>\n <v-card :disabled=\"vehicleLoading.class\" :loading=\"vehicleLoading.class\">\n <v-card-title>\n {{ vehicleClass.name }}\n </v-card-title>\n <v-card-text class=\"mt-3\">\n <v-form class=\"space-y-4\">\n <v-text-field\n v-model=\"currentWorkingClass.name\"\n :error-messages=\"vehicleClassForm.errors.get('name')\"\n class=\"w-full md:w-[300px]\"\n label=\"Name\"\n variant=\"outlined\"\n @keyup=\"store.commit('vehicles/CLEAR_VEHICLE_FORM_ERRORS', 'name')\"\n />\n <div class=\"flex flex-col md:flex-row md:items-center gap-2\">\n <v-text-field\n v-model=\"currentWorkingClass.sipp_code\"\n :error-messages=\"vehicleClassForm.errors.get('sipp_code')\"\n class=\"w-full md:w-[300px]\"\n label=\"SIPP Code\"\n variant=\"outlined\"\n @keyup=\"store.commit('vehicles/CLEAR_VEHICLE_FORM_ERRORS', 'sipp_code')\"\n />\n <v-btn size=\"x-small\" variant=\"text\" @click=\"openSippDialog()\">What is SIPP?</v-btn>\n </div>\n <v-text-field\n v-model=\"currentWorkingClass.minimum_age\"\n :error-messages=\"vehicleClassForm.errors.get('minimum_age')\"\n class=\"w-full md:w-[300px]\"\n label=\"Minimum Age\"\n type=\"number\"\n variant=\"outlined\"\n @keyup=\"store.commit('vehicles/CLEAR_VEHICLE_FORM_ERRORS', 'minimum_age')\"\n />\n <div>\n <v-select\n v-model=\"currentWorkingClass.branch\"\n :error-messages=\"vehicleClassForm.errors.get('branch')\"\n :items=\"branchesFiltered\"\n append-icon=\"mdi-close\"\n class=\"fleet-branches-select w-full md:w-[300px]\"\n label=\"Branches\"\n variant=\"outlined\"\n @keyup=\"store.commit('vehicles/CLEAR_VEHICLE_FORM_ERRORS', 'branch')\"\n @click:append=\"currentWorkingClass.branch = null\"\n >\n <template v-slot:append-item>\n <div class=\"border-t py-5 flex justify-center\">\n <router-link :to=\"{name: 'settings.fleet.branches'}\">\n <span class=\"text-sm\">Manage Fleet Branches</span>\n </router-link>\n </div>\n </template>\n </v-select>\n </div>\n </v-form>\n </v-card-text>\n <v-card-actions class=\"flex flex-wrap gap-2\">\n <div class=\"flex items-center gap-2\">\n <v-btn v-if=\"!confirmDelete\" color=\"red\" size=\"small\" variant=\"text\" @click=\"confirmDelete = true\">\n <v-icon size=\"small\">mdi-delete</v-icon>\n </v-btn>\n <v-btn v-if=\"confirmDelete\" size=\"small\" variant=\"text\" @click=\"confirmDelete = false\">Cancel</v-btn>\n <v-btn v-if=\"confirmDelete\" color=\"red text-white\" size=\"small\" @click=\"deleteVehicleClassInit(fleetClassUuid)\">\n Confirm\n </v-btn>\n </div>\n <v-spacer/>\n <div class=\"flex items-center gap-2\">\n <v-btn size=\"small\" variant=\"text\" @click=\"backToClasses()\">\n Back\n </v-btn>\n <v-btn :loading=\"vehicleLoading.class\" @click=\"updateVehicleClass(currentWorkingClass)\">Save</v-btn>\n </div>\n </v-card-actions>\n </v-card>\n <SippDialog v-model=\"isSippDialogOpen\"/>\n </div>\n</template>\n\n<script lang=\"ts\" setup>\nimport {computed, onBeforeMount, ref, watch} from 'vue';\n\nimport SippDialog from '@/views/dashboard/settings/Fleet/SippDialog.vue';\nimport {useVehicle} from '@/composables/useVehicle';\nimport {useRoute, useRouter} from 'vue-router';\nimport {useBranch} from '@/composables/useBranch';\nimport {VehicleClass} from '@/types';\nimport {useStore} from 'vuex';\n\nconst route = useRoute();\nconst router = useRouter();\nconst isSippDialogOpen = ref(false);\n\nconst store = useStore();\n\nconst {\n getVehicleClass,\n vehicleClass,\n vehicleClassForm,\n vehicleLoading,\n deleteVehicleClass,\n updateVehicleClass,\n getVehicleClasses,\n} = useVehicle();\nconst {getFleetBranches, branches} = useBranch();\n\nconst fleetClassUuid = route.params.uuid as string;\n\nconst confirmDelete = ref(false);\nconst currentWorkingClass = ref<VehicleClass>({\n set: false,\n image_url: '',\n active: true,\n name: '',\n uuid: '',\n minimum_age: null,\n sipp_code: '',\n branch: null,\n});\nconst classClone = ref({\n set: false,\n image_url: '',\n active: true,\n name: '',\n uuid: '',\n minimum_age: null,\n sipp_code: '',\n branch: null,\n});\n\nconst openSippDialog = () => {\n isSippDialogOpen.value = true;\n};\n\nonBeforeMount(() => {\n getVehicleClass(route.params.uuid as string);\n getFleetBranches();\n\n currentWorkingClass.value = {\n set: false,\n image_url: '',\n active: true,\n name: '',\n uuid: '',\n minimum_age: null,\n sipp_code: '',\n branch: null,\n }\n classClone.value = {\n set: false,\n image_url: '',\n active: true,\n name: '',\n uuid: '',\n minimum_age: null,\n sipp_code: '',\n branch: null,\n };\n});\n\nconst branchesFiltered = computed(() => {\n return branches.value.map((b) => ({\n value: b.uuid,\n title: b.name,\n }));\n});\n\nwatch(vehicleClass, (vehicleClass) => {\n if (vehicleClass.uuid) {\n classClone.value = JSON.parse(JSON.stringify(vehicleClass));\n currentWorkingClass.value = classClone.value;\n currentWorkingClass.value.branch = classClone.value?.branch?.uuid;\n currentWorkingClass.value.set = true;\n }\n});\n\nconst deleteVehicleClassInit = (uuid: string) => {\n deleteVehicleClass(uuid).then(() => {\n getVehicleClasses(true);\n router.push({name: 'settings.fleet.classes'}).catch(() => {\n });\n }).catch(() => {\n console.dir('error');\n });\n};\n\nconst backToClasses = () => {\n router.push({name: 'settings.fleet.classes'}).catch(() => {\n });\n};\n\n</script>\n\n","<template>\n <div>\n <v-card>\n <v-card-title>\n <div class=\"flex\">\n Action Items\n <v-spacer/>\n <v-btn size=\"small\" :to=\"{name: 'settings.action_item.new'}\">Add Item</v-btn>\n </div>\n </v-card-title>\n <v-card-text class=\"mt-3\">\n <table class=\"w-full text-sm text-left text-gray-500 dark:text-gray-400\" v-if=\"actionItems.length > 0\">\n <thead class=\"text-xs text-gray-700 uppercase bg-gray-50 dark:bg-gray-700 dark:text-gray-400\">\n <tr>\n <th scope=\"col\" class=\"px-6 py-3\">Title</th>\n <th scope=\"col\" class=\"px-6 py-3\">Era</th>\n <th scope=\"col\" class=\"px-6 py-3\">Vehicle Classes</th>\n <th scope=\"col\" class=\"px-6 py-3\"></th>\n </tr>\n </thead>\n <tbody>\n <tr v-for=\"(item) in actionItems\" :key=\"item.uuid\">\n <th scope=\"row\" class=\"px-6 py-4 font-medium text-gray-900 whitespace-nowrap dark:text-white\">\n <router-link :to=\"{name: 'settings.action_items.single', params: {uuid: item.uuid}}\" class=\"\">{{ item.title }}</router-link>\n </th>\n <td class=\"px-6 py-4\">\n {{ item.when }}\n </td>\n <td class=\"px-6 py-4\">{{ item.vehicle_classes_count }}</td>\n <td class=\"px-6 py-4\">\n <router-link\n :to=\"{name: 'settings.action_items.single', params: {uuid: item.uuid}}\"\n class=\"font-medium text-blue-600 dark:text-blue-500 hover:underline\"\n >View</router-link>\n </td>\n </tr>\n </tbody>\n </table>\n <div v-else>No action items yet</div>\n </v-card-text>\n </v-card>\n </div>\n</template>\n\n<script>\nimport { mapGetters, mapActions } from 'vuex';\n\nexport default {\n name: 'ActionItems.vue',\n\n created() {\n this.getActionItems();\n },\n\n computed: {\n ...mapGetters({\n actionItems: 'fleet/actionItems',\n }),\n },\n\n methods: {\n ...mapActions({\n getActionItems: 'fleet/getActionItems',\n }),\n },\n};\n</script>\n\n","<template>\n <div>\n <v-card :disabled=\"fleetLoading.updateBranch || fleetLoading.actionItem\" :loading=\"fleetLoading.actionItem\">\n <v-card-title>\n New Action Item\n </v-card-title>\n <v-card-text class=\"mt-3\">\n <v-card-text class=\"mt-3\">\n <v-form>\n <div class=\"grid grid-cols-2\">\n <div class=\"mb-5\">\n <v-text-field\n v-model=\"currentWorkingActionItem.title\"\n :error-messages=\"fleetForm.errors.get('title')\"\n label=\"Name\"\n variant=\"outlined\"\n @keydown=\"$store.commit('fleet/CLEAR_FLEET_FORM_ERRORS', 'title')\"\n />\n </div>\n </div>\n\n <div class=\"grid grid-cols-2\">\n <div class=\"mb-5\">\n <v-select\n v-model=\"currentWorkingActionItem.when\"\n :error-messages=\"fleetForm.errors.get('when')\"\n :items=\"actionItemEras\"\n item-title=\"name\"\n item-value=\"value\"\n label=\"Era\"\n variant=\"outlined\"\n />\n </div>\n </div>\n\n <div class=\"grid grid-cols-2\">\n <div class=\"mb-5\">\n <v-autocomplete\n v-model=\"currentWorkingActionItem.vehicle_classes\"\n :items=\"vehicleClasses\"\n item-title=\"name\"\n item-value=\"uuid\"\n label=\"Vehicle Classes\"\n multiple\n return-object\n variant=\"outlined\"\n />\n </div>\n </div>\n </v-form>\n </v-card-text>\n </v-card-text>\n <v-divider/>\n <v-card-actions>\n <v-spacer/>\n <v-btn size=\"small\" variant=\"text\" @click=\"$router.push({ name: 'settings.action_items' }).catch(() => {});\">\n Back\n </v-btn>\n <v-btn\n :disabled=\"fleetLoading.updateBranch || currentWorkingActionItem.title === '' || currentWorkingActionItem.when === ''\"\n :loading=\"fleetLoading.updateBranch\"\n @click=\"createActionItem(currentWorkingActionItem)\"\n >Save\n </v-btn>\n </v-card-actions>\n </v-card>\n </div>\n</template>\n\n\n<script lang=\"ts\">\nimport {mapActions, mapGetters} from 'vuex';\n\nconst defaultActionItem = {\n uuid: '',\n title: '',\n when: 'pre-trip',\n order: 0,\n vehicle_classes: [],\n};\n\nexport default {\n name: 'ActionItemNew.vue',\n\n data() {\n return {\n actionItemEras: [\n {name: 'Pre-Trip', value: 'pre-trip'},\n {name: 'Post-Trip', value: 'post-trip'},\n ],\n currentWorkingActionItem: {...defaultActionItem},\n };\n },\n\n created() {\n this.getVehicleClasses();\n },\n\n watch: {\n newlyCreatedActionItem(newlyCreatedActionItem) {\n if (newlyCreatedActionItem.uuid) {\n this.$router.push({\n name: 'settings.action_items.single',\n params: {uuid: newlyCreatedActionItem.uuid}\n }).catch(() => {\n });\n }\n },\n },\n\n computed: {\n ...mapGetters({\n fleetLoading: 'fleet/loading',\n newlyCreatedActionItem: 'fleet/newlyCreatedActionItem',\n vehicleClasses: 'vehicles/vehicleClasses',\n vehicleLoading: 'vehicles/vehicleLoading',\n fleetForm: 'fleet/fleetForm',\n }),\n },\n\n methods: {\n ...mapActions({\n createActionItem: 'fleet/createActionItem',\n getVehicleClasses: 'vehicles/getVehicleClasses',\n }),\n updateActionItemInit() {\n this.updateActionItem({\n uuid: this.$route.params.uuid,\n title: this.currentWorkingActionItem.title,\n when: this.currentWorkingActionItem.when,\n order: this.currentWorkingActionItem.order,\n vehicle_classes: this.currentWorkingActionItem.vehicle_classes,\n });\n },\n },\n\n beforeUnmount() {\n this.currentWorkingActionItem = {...defaultActionItem};\n this.$store.commit('fleet/CLEAR_FLEET_FORM_ERRORS');\n },\n};\n</script>\n\n","<template>\n <div>\n <v-card :disabled=\"branchLoading.updateBranch || branchLoading.fetchBranch\" :loading=\"branchLoading.fetchBranch\">\n <v-card-title>\n Action Item: {{ actionItem?.title }}\n </v-card-title>\n <v-card-text class=\"mt-3\">\n <v-form>\n <div class=\"grid grid-cols-2\">\n <div class=\"mb-5\">\n <v-text-field\n v-model=\"currentWorkingActionItemClone.title\"\n :error-messages=\"fleetForm.errors.get('title')\"\n label=\"Name\"\n variant=\"outlined\"\n @keydown=\"$store.commit('fleet/CLEAR_FLEET_FORM_ERRORS', 'title')\"\n />\n </div>\n </div>\n\n <div class=\"grid grid-cols-2\">\n <div class=\"mb-5\">\n <v-select\n v-model=\"currentWorkingActionItemClone.when\"\n :items=\"actionItemEras\"\n item-title=\"name\"\n item-value=\"value\"\n label=\"Era\"\n variant=\"outlined\"\n />\n </div>\n </div>\n\n <div class=\"grid grid-cols-2\">\n <div class=\"mb-5\">\n <v-autocomplete\n v-model=\"currentWorkingActionItemClone.vehicle_classes\"\n :items=\"vehicleClasses\"\n item-title=\"name\"\n item-value=\"uuid\"\n label=\"Vehicle Classes\"\n multiple\n return-object\n variant=\"outlined\"\n />\n </div>\n </div>\n </v-form>\n </v-card-text>\n <v-card-actions>\n <DeleteButton @deleteConfirmed=\"deleteActionItem(currentWorkingActionItemClone)\"/>\n <v-spacer/>\n <v-btn size=\"small\" variant=\"text\" @click=\"$router.push({ name: 'settings.action_items' }).catch(() => {});\">\n Back\n </v-btn>\n <v-btn\n :disabled=\"branchLoading.updateBranch || currentWorkingActionItemClone.title === '' || currentWorkingActionItemClone.when === ''\"\n :loading=\"branchLoading.updateBranch\"\n @click=\"updateActionItemInit()\"\n >Save\n </v-btn>\n </v-card-actions>\n </v-card>\n </div>\n</template>\n\n\n<script lang=\"ts\">\nimport {defineAsyncComponent} from 'vue';\nimport {mapActions, mapGetters} from 'vuex';\n\nconst DeleteButton = defineAsyncComponent(() => import('@/components/buttons/DeleteButton.vue'));\n\nconst defaultActionItem = {\n uuid: '',\n title: '',\n when: 'pre-trip',\n order: 0,\n vehicle_classes: [],\n};\n\nexport default {\n name: 'ActionItemSingle.vue',\n\n components: {\n DeleteButton,\n },\n\n data() {\n return {\n actionItemEras: [\n {name: 'Pre-Trip', value: 'pre-trip'},\n {name: 'Post-Trip', value: 'post-trip'},\n ],\n currentWorkingActionItemClone: {...defaultActionItem},\n };\n },\n\n created() {\n this.getActionItem(this.$route.params.uuid);\n this.getVehicleClasses();\n },\n\n watch: {\n actionItem(item) {\n this.currentWorkingActionItemClone = JSON.parse(JSON.stringify(item));\n },\n actionItemDeleted() {\n this.$router.push({name: 'settings.action_items'}).catch(() => {\n });\n },\n },\n\n computed: {\n ...mapGetters({\n actionItem: 'fleet/actionItem',\n branchLoading: 'fleet/loading',\n vehicleClasses: 'vehicles/vehicleClasses',\n actionItemDeleted: 'fleet/actionItemDeleted',\n fleetForm: 'fleet/fleetForm',\n }),\n },\n\n methods: {\n ...mapActions({\n getActionItem: 'fleet/getActionItem',\n deleteActionItem: 'fleet/deleteActionItem',\n updateActionItem: 'fleet/updateActionItem',\n getVehicleClasses: 'vehicles/getVehicleClasses',\n }),\n updateActionItemInit() {\n this.updateActionItem({\n uuid: this.$route.params.uuid,\n title: this.currentWorkingActionItemClone.title,\n when: this.currentWorkingActionItemClone.when,\n order: this.currentWorkingActionItemClone.order,\n vehicle_classes: this.currentWorkingActionItemClone.vehicle_classes,\n });\n },\n },\n\n beforeUnmount() {\n this.currentWorkingActionItemClone = {...defaultActionItem};\n },\n};\n</script>\n\n","<template>\n <div>\n Fleet Vehicle Features\n </div>\n</template>\n\n<script>\nimport { mapGetters, mapActions } from 'vuex';\n\nexport default {\n name: 'SettingsFleetFeatures',\n\n data() {\n return {\n settings: {\n turo: {},\n fw: {},\n },\n };\n },\n\n watch: {\n notificationSettings: {\n deep: true,\n handler(notification, notificationOld) {\n if(notificationOld.set) {\n this.updateNotificationSettings();\n }\n },\n },\n },\n\n computed: {\n ...mapGetters({\n loading: 'settings/loading',\n notificationSettings: 'settings/notifications',\n }),\n },\n\n methods: {\n ...mapActions({\n updateNotificationSettings: 'settings/updateNotificationSettings',\n }),\n },\n};\n</script>\n\n","<template>\n <div>\n <v-dialog v-model=\"agreeToSDialog\" fullscreen>\n <v-card>\n <v-card-text class=\"p-5\">\n <div id=\"terms-of-service\">\n <h2 class=\"h2\" style=\"text-align:center;\">\n <strong>Fleetwire.io AFFILIATE PROGRAM. TERMS AND CONDITIONS</strong>\n </h2>\n <small>Updated Dec 16, 2021</small>\n\n <p style=\"text-align:justify;\">These Affiliate Program Operating Terms and Conditions\n (the\n “<strong>Affiliate Program Terms</strong>”) contain terms and conditions between\n Fleetwire LLC, 30 N Gould St STE R Sheridan, WY 82801, USA.\n (“<strong>Fleetwire.io</strong>”, “<strong>us</strong>”, or “<strong>we</strong>”,\n “<strong>our</strong>”), and you (“<strong>you</strong>”, “<strong>your</strong>” or\n “<strong>Affiliate</strong>”), that govern your participation in our affiliate program\n accessible through this website(“<strong>Affiliate Program</strong>”).</p>\n\n <p style=\"text-align:justify;\">The Affiliate Program Terms are governed by Fleetwire.io\n General Terms and Conditions for Marketing Campaigns (“<strong>General Terms</strong>”)\n available at <a href=\"https://fleetwire.io/terms\">https://fleetwire.io/terms</a>. The\n Affiliate Program Terms and the General Terms are together referred to as the\n “<strong>Agreement</strong>”.\n You confirm that you have read and understood the Agreement, and agree to the\n provisions\n stated therein. In the event of any inconsistency between the Affiliate Program Terms\n and General Terms, the terms of this Affiliate Program Terms shall prevail.</p>\n\n <p style=\"text-align:justify;\">Each Affiliate Program offer (an \"<strong>Offer</strong>\")\n may be for any offering by Fleetwire.io or a third party (each such third party a\n \"<strong>Client</strong>\") and may link to a specific website for that particular\n Offer\n or other websites of Fleetwire.io (“<strong>Program Website</strong>”). Furthermore,\n each Offer and its accompanying documents may have additional terms and conditions on\n pages within the Affiliate Program and forms a part of this Agreement.</p>\n\n <p style=\"text-align:justify;\">We reserve the right to include to the Affiliate Program\n additional products in our sole discretion anytime.</p>\n\n <p style=\"text-align:justify;\">The Fleetwire.io entity which you are contracting with\n under these Affiliate Program Terms is Fleetwire, LLC. In such a case your\n counterparty\n under these Affiliate Program Terms is Fleetwire, LLC, 30 N Gould St STE R Sheridan,\n WY\n 82801, USA.</p>\n\n <ol>\n <li style=\"text-align:justify;\"><strong>ENROLLMENT IN THE AFFILIATE\n PROGRAM</strong><br><br>\n 1.1. In order to enrol in the Affiliate Program, you must submit an Affiliate\n Program\n application form on our website (<a href=\"https://tenant.fleetwire.io/settings/affiliate/\">https://tenant.fleetwire.io/settings/affiliate/</a>).\n You must accurately complete the application form to become an affiliate. You must\n not\n use any aliases or other means to mask your true identity or contact information.You\n must provide us with any future updates regarding your contact details immediately\n after they change.<br><br>\n 1.2. After we review your application form, we will notify you of your acceptance or\n rejection to the AffiliateProgram. The notification generally is provided within two\n (2) business days after you submit an application form. We may accept or reject your\n application in our sole discretion for any reason.<br>\n </li>\n\n <li style=\"text-align:justify;\">\n <strong>LINKS TO THE PROGRAM WEBSITE AND PROMOTION OF AFFILIATE\n RELATIONSHIP</strong>\n <br><br>\n 2.1. If you qualify and agree to participate as an Affiliate and we accept your\n application, you will become anAffiliate and we will make available graphic and\n textual links and accesses to the Program Website(collectively,\n “<strong>Links</strong>”) and/or other creative materials to you via the Affiliate\n Program.<br><br>\n 2.2. You may display the Links on the websites owned or controlled by you, in emails\n sent by you and/or in online advertisements (collectively, “<strong>Media</strong>”).\n You must be always identified when displaying Links. TheLinks will serve to identify\n you as a member of our Affiliate Program and will establish a connection from your\n Media to the Program Website. The Links may connect to any area of our websites\n (althoughCommissions will only be issued for Qualified Actions).<br><br>\n 2.3. In utilizing the Links, you agree that you will reasonably cooperate with us in\n order to establish and maintain such Links. All Affiliate websites shall display the\n Links, including, but not limited to, graphic and/or textual images, prominently in\n relevant sections of their websites.<br><br>\n 2.4. Fleetwire.io may change, suspend or discontinue any aspect of an Offer or Link\n or\n remove, alter, or modify any tags, text, graphic or banner advertisement in\n connection\n with the Link. You agree to promptly implement any request from Fleetwire.io to\n remove,\n alter or modify any Link, graphic or banner advertisement that is being used by you\n as\n part of the Affiliate Program.<br><br>\n 2.5. When a user follows your Affiliate Link to the Program Website, we place a\n tracking cookie on that user’s computer or mobile device which will be used to\n identify\n that user as a referral from you provided that user creates an account (including a\n free account) on Fleetwire's website within thirty (30) days (after which the cookie\n expires). If the user uses another computer or mobile device to create an account or\n deletes the tracking cookie before creating the account, then we shall have no\n liability to pay to you any Commission in respect of any Fleetwire.io services\n purchased by that user.<br><br>\n 2.6. You are not allowed to:<br><br>\n 2.6.1. use cookie stuffing techniques that set the Affiliate tracking cookie without\n the knowledge of the users of your Media and your websites (example:\n iframe);<br><br>\n 2.6.2. post any refunds, credits or discounts, or other similar content concerning\n Fleetwire, unless we have given you prior written permission in each instance.\n Affiliates\n may only use coupons and discounts that are provided exclusively through the\n Affiliate\n Program using banners and links;<br><br>\n 2.7. Each Link connecting users of your Media and/or your website to the pertinent\n area of our websites shall in no way alter the look, feel, or functionality of our\n websites. Any violations of the terms surroundingLinks, other links, coupons,\n refunds,\n credits or discounts shall constitute a material breach of thisAgreement and may\n result in your termination from the Affiliate Program and/or withholding\n ofCommissions.<br></li>\n <li style=\"text-align:justify;\"><strong>DETERMINATION OF COMMISSIONS</strong><br><br>\n 3.1. We will pay you payments for each Qualified Action\n (“<strong>Commission</strong>”).\n A “<strong>Qualified Action</strong>” is counted when all of the following actions\n are\n performed:\n <ol class=\"ml-10\" style=\"list-style-type:lower-roman;\">\n <li>an individual person accesses the Program Website via the Link;</li>\n <li>pre-populated fields are not used;</li>\n <li>individual completes all of the information required for accessing the\n Fleetwire.io service within the time period allowed by Fleetwire;\n </li>\n <li>individual purchases Fleetwire.io service(s); and</li>\n <li>individual does not require a refund,chargeback or cancellation within thirty\n (30) days after the completion of purchase for such purchase.\n </li>\n </ol>\n <br>\n 3.2. The actions that do not satisfy the conditions for the Qualified Actions\n stipulated in Clause 3.1, are not considered Qualified Action, including, but not\n limited to, the following cases:\n <ol class=\"ml-10\" style=\"list-style-type:lower-roman;\">\n <li>the Program Website is accessed by a computer-generated user, such as a robot,\n spider,computer script or other automated, artificial or fraudulent method to\n appear like an individual, real live person;\n </li>\n <li>the access is later determined by Fleetwire.io to be fraudulent, incomplete,\n unqualified or a duplicate;\n </li>\n <li>the actions performed by the Affiliate violate this Agreement, (including, but\n not limited to, the obligations of the Affiliate stipulated herein) and/or the\n requirements of the applicable law.\n </li>\n </ol>\n <br>\n 3.3. In some specifically identified cases we, at our sole discretion, may offer\n payouts for free individual registrations. In these cases, the Qualified Action is\n counted when all of the following actions are performed:\n <ol class=\"ml-10\" style=\"list-style-type:lower-roman;\">\n <li>an individual access the Program Website via the Link;</li>\n <li>pre-populated fields are not used;</li>\n <li>individual completes all of the information required for accessing the\n Fleetwire.io service within the time period allowed by Fleetwire;\n </li>\n <li>individual is actively using his/her account for a period of time determined\n solely by Fleetwire.\n </li>\n </ol>\n <br></li>\n <li style=\"text-align:justify;\"><strong>PAYMENT OF COMMISSIONS</strong><br><br>\n 4.1. We will pay you any earned Commissions when the amount of the Commissions in\n your\n Affiliate account is greater than one hundred United States dollars ($100).\n Commissions\n will be paid via PayPal. Direct wire transfer is available only for sums over one\n thousand United States dollars ($1,000) per month. You shall cover any and all costs\n and expenses related to the payment of Commissions. We shall not have any liability\n for\n Commissions lost due to incorrect payment details provided by you.<br><br>\n 4.2. Subject to Clauses 3 “Determination of Commission” and 12 “Fraud”, Commissions\n are paid only if and when we determine that your actions are considered Qualified\n Actions and have remained in compliance with this Agreement for the entirety of the\n period for which the Commissions are paid and throughout to the payment date. We\n reserve the right to charge back to your Affiliate account any and all\n previous payments for Qualified Actions that are later determined by Fleetwire.io to\n have not met the requirements to be aQualified Action.<br><br>\n 4.3. All tracking of Links, determinations of Qualified Actions and counting of\n Commissions shall be made by us in our sole discretion according to our technology.\n In\n the event that you are also tracking Links andQualified Actions, tracking results of\n Fleetwire.io shall always prevail.<br><br>\n 4.4. Payments for revenue generated by you will be transferred to you once a month,\n following your request. In exceptional cases this term can be extended with a prior\n written notice to you. Due to our Refund policy,you can request a payment of the\n respective Commissions not earlier than forty (40) days after generating this\n respective amount.<br><br>\n 4.5. You should send requests for payments to <a\n href=\"mailto:hi@fleetwire.io\">hi@fleetwire.io</a> and we will\n provide you with our calculations regarding the amount of Commissions earned by you.\n In\n the event that you dispute any portion of the Commissions calculated by us in good\n faith (e.g., calculations contain a mathematical error),you agree and must (i)\n notify\n Fleetwire.io of such disputed amount in writing with sufficient detail within thirty\n (30)days’ after being notified regarding the Commission amount for the respective\n period, (ii) make authorized personnel available to resolve the dispute. If you do\n not\n dispute the calculated amount as set forth herein,you irrevocably waive any claims\n based upon that amount.All amounts not timely and appropriately disputed shall be\n deemed final and not subject to further dispute.<br><br>\n 4.6. Fleetwire's Commission payments are directly dependent upon receipt of payments\n from\n customers (except for limited cases of payouts for free individual registrations).\n Therefore, we shall only be liable for theCommissions to the extent that we have\n received such payments from the customers. You shall have no right to any claims for\n Commissions if we have not received respective payments from the customers(including\n but not limited, due to the chargebacks, refunds, cancellations).<br><br>\n 4.7. In the event customers terminate our services after the purchase (e.g. any\n chargebacks,refunds,cancellations), the respective amount of your Commission shall\n be\n cancelled. We grant refunds to our customers in accordance with our Refund policy or\n in\n our sole discretion, which means that our customers usually have the right to cancel\n our services and request for a refund within a specified period after the purchase.\n Nevertheless, customers’ right to request for a chargeback is not limited in time.\n Therefore, if we have already paid the relevant Commission to you, we shall deduct\n the\n respective amount from our next payment.<br><br>\n 4.8. Where the rate of chargeback(s), refunds or cancellations on your Affiliate\n account is unusually high or we suspect your Affiliate account is being used for\n fraudulent activity or in violation of this Agreement and/or applicable law, we\n reserve\n the right to place restrictions on your Affiliate account immediately upon\n written notice to you, including, but not limited to, suspend your Affiliate account\n and suspend all payments related to your Affiliate account, as well as commence a\n full\n investigation (internal or involving any appropriate third parties). If we find it\n necessary, we have full rights in our sole discretion to inform the appropriate law\n enforcement or regulatory authorities or any third parties of any actual or alleged\n breach of law and/or fraud performed by you (either in or not in connection with\n this\n Agreement). Only once we are satisfied that the matter is resolved, we will remove\n the\n restrictions applied to your Affiliate account.<br><br>\n 4.9. If you have an outstanding balance due to Fleetwire.io under this Agreement or\n any other agreement between you and Fleetwire, whether or not related to the\n Affiliate\n Program, you agree that Fleetwire.io may offset any such amounts due to you from\n amounts payable to you under this Agreement.<br><br>\n 4.10. If you have not earned any Commissions or have not logged into your Affiliate\n account within a six (6)months period, then we may, in our sole discretion\n unilaterally terminate this Agreement, close yourAffiliate account, and withhold any\n unpaid Commissions. We are relieved from any and all obligations to you, including,\n without limitations, financial obligations, in accordance with the Agreement if you\n do\n not dispute the closing of your Affiliate account as specified in this Clause 4.10\n within five (5) business days from notification informing you about the termination\n of\n the Agreement along with the closure of your account and withholding of unpaid\n Commissions.<br></li>\n <li style=\"text-align:justify;\"><strong>OBLIGATIONS OF THE AFFILIATE</strong><br><br>\n 5.1. As an Affiliate you shall:<br><br>\n 5.1.1. comply with all (i) obligations, requirements and restrictions under this\n Agreement, and (ii) applicable law,rules and regulations, including but without\n limitation in relation to your business, your Media or your use of the Links, for\n the\n entirety of the period of this Agreement;<br><br>\n 5.1.2. have sole responsibility for the development, operation, and maintenance of,\n and all content on or linked to your Media;<br><br>\n 5.1.3. disclose commercial relationships between you, your Media and Fleetwire, and\n clearly\n identify advertising and paid promotions. Review sites shall clearly state how\n reviews\n are composed and checked;<br><br>\n 5.1.4. ensure that all materials posted on your Media or otherwise used in\n connection\n with the Affiliate Program:\n <ol class=\"ml-10\" style=\"list-style-type:lower-roman;\">\n <li>comply with the requirements of applicable law and are not illegal,</li>\n <li>do not infringe any rights of third parties, including, without limitation,\n intellectual property,personality, publicity rights,\n </li>\n <li>do not contain ethically unacceptable content, creative materials or copy\n (including, but not limited to, keywords, terms, meta tags, descriptions, web\n designs, etc.),\n </li>\n <li>do not contain, create, promote or link to any content which is in any way\n deceptive,misleading,and does not represent actual and accurate information\n about\n Fleetwire.io and it’s products or services,\n </li>\n <li>do not contain, create, promote or link to any material which is harmful,\n threatening, defamatory,obscene, sexually explicit, harassing, promotes\n violence,\n discrimination (whether based on sex,religion, race, ethnicity, nationality,\n disability or age), illegal activities (such as gambling), contains profanity,\n and/or do not otherwise contain any material which, as informed by Fleetwire.io\n to\n you, Fleetwire considers objectionable (collectively, “<strong>Objectionable\n Content</strong>”);\n </li>\n </ol>\n <br>\n 5.1.5. not make any representations, warranties or other statements concerning\n Fleetwire.io or Client, or any of their respective products or services, except as\n expressly authorized by Fleetwire.io in writing;<br><br>\n 5.1.6. not disseminate information that does not correspond to reality and/or any\n other allegations that damages the reputation of Fleetwire.io and each of its\n parents,\n subsidiaries, affiliates, their principals, directors, officers,partners, agents,\n employees, and assignees, whether or not such information/allegations relate to\n thisAgreement or Affiliate Program;<br><br>\n 5.1.7. make sure that your Media does not copy or resemble the look, feel and/or\n trade-dress of the ProgramWebsite or create the impression that you or your Media is\n part of or endorsed by Fleetwire.io or Client, or is apart of the Program Website,\n without prior written permission from us;<br><br>\n 5.1.8. comply with the terms, conditions, guidelines and policies of any third-party\n services used by you in connection with this Agreement and the Affiliate Program,\n including, but not limited to, email providers,social networking services and\n advertising networks;<br><br>\n 5.1.9. always prominently post and make available to any visitors of your websites\n and/or users of your Media(“<strong>your end-users</strong>”), including prior to\n the\n processing of any personal data and/or other personally identifiable information, a\n privacy policy in compliance with all applicable laws that clearly and\n thoroughly discloses all personal data processing and information collection, use\n and\n sharing practices. Also, obtain informed, unambiguous, specific and freely given\n consent from your end-users, if necessary, in accordance with applicable law, for\n the\n use of cookies and/or the collection and processing of their information;<br><br>\n 5.1.10. always prominently post and make available to your end-users any terms and\n conditions in connection with the Offer set forth by Fleetwire.io or Client, or as\n required by applicable law regarding such Offers;<br><br>\n 5.1.11. make sure to not place Fleetwire.io ads on any online auction platform\n (including, but not limited to, eBay,Amazon, etc.);<br><br>\n 5.1.12. be transparent to Fleetwire.io in relation to your actions under the\n Affiliate\n Program and, if you are planning any action that does not fully comply with the\n usual\n business practice and/or you feel that your actions might violate this Agreement or\n applicable law, to consult your Affiliate account manager.<br></li>\n <li style=\"text-align:justify;\"><strong>ADDITIONAL PROGRAM-SPECIFIC\n TERMS</strong><br><br><strong>The following additional program-specific terms shall\n apply to any promotional programs set forth below:</strong><br><br>\n 6.1. <strong>Email Campaigns</strong>. All email campaigns shall be approved in\n advance and in writing by us.<br><br>\n 6.2. <strong>Advertising Campaigns</strong>:\n <ol class=\"ml-10\" style=\"list-style-type:lower-roman;\">\n <li>No Links can appear to be associated with or be positioned on chat rooms or\n bulletin boards unless otherwise agreed by us in writing. Any pop-ups/unders are\n forbidden.\n </li>\n <li>Advertising campaigns shall not violate any applicable national or\n international\n advertising and marketing laws, as well, they shall not violate the intellectual\n property rights of third parties.\n </li>\n <li>You are solely responsible for confirming the legal requirements when\n publishing\n the advertisements.\n </li>\n <li>It is prohibited to use Banned keywords (as defined below in these Affiliate\n Program Terms) and to make any bidding on any referencing service or search\n engine\n (such as Google AdWords), paid or otherwise, in any meta tags, advertising,\n search\n terms, code, or in a similar manner, for any goods or services, either similar\n or\n not to Fleetwire's products or services.\n </li>\n <li>We can never be held responsible for the content of commercials or the\n context,\n how and where,the commercials are used, released, made available, published, or\n disseminated.\n </li>\n </ol>\n <br>\n 6.3. <strong>Affiliate Network Campaigns</strong>:\n\n <ol class=\"ml-10\" style=\"list-style-type:lower-roman;\">\n <li>For all Affiliates that maintain their own affiliate networks, Affiliate\n agrees\n to place the Links in its affiliate network\n (“<strong>Affiliate’sNetwork</strong>”)\n for access and use by those affiliates in Affiliate's Network(each a “<strong>Third\n Party Affiliate</strong>”). Affiliate agrees that it will expressly forbid any\n Third Party Affiliate to modify the Links in any way.\n </li>\n <li>Affiliate agrees to maintain the Affiliate’s Network according to the highest\n industry standards.Affiliate shall not permit any party whose website or\n business\n model involves content containingObjectionable Content to be a Third Party\n Affiliate.\n </li>\n <li>All Third Party Affiliates must be in good standing with the Affiliate.\n Affiliate must require and confirm that all Third Party Affiliates affirmatively\n accept, through verifiable means, this Agreement prior to obtaining access to\n the\n Links.\n </li>\n <li>Affiliate shall disclose any and all Third Party Affiliates which access the\n Affiliate Program and use the Links for generation of Commissions to Fleetwire.\n </li>\n <li>Affiliate shall promptly terminate any Third Party Affiliate who takes, or\n could\n reasonably be expected to take, any action that violates the terms and\n conditions\n of this Agreement. In the event that either party suspects any wrongdoing by a\n Third Party Affiliate with respect to the Links and/or violation of this\n Agreement\n and/or applicable law in relation to this Agreement by a Third PartyAffiliate,\n Affiliate shall promptly disclose to Fleetwire.io the identity and contact\n information of such ThirdParty Affiliate.\n </li>\n <li>Affiliate shall promptly remove any Third Party Affiliate from the Affiliate\n Program and terminate their access to future Offers of Fleetwire.io in the\n Affiliate’s Network, including but not limited to, anyLinks, upon written notice\n from Fleetwire.\n </li>\n <li>Unless Fleetwire.io has been provided with all truthful and complete contact\n information of a Third PartyAffiliate and such Third Party Affiliate has\n affirmatively accepted this Agreement as recorded byFleetwire.io (and,\n therefore,\n is liable directly to Fleetwire), Affiliate shall remain liable for all acts or\n omissions(including, but not limited to, violations of this Agreement and/or\n applicable law) by any Third PartyAffiliate.\n </li>\n </ol>\n <br></li>\n <li style=\"text-align:justify;\"><strong>ANTI-SPAM POLICY</strong><br><br>\n 7.1. When participating in our Affiliate Program, you may not use for selling or\n promoting Fleetwire's products or services any spamming methods, including, but not\n limited\n to, the following:<br><br>\n 7.1.1. <strong>Email SPAM</strong>: sending unsolicited marketing email. However,\n you\n may send emails to people who have given you consent to send them marketing emails\n for\n products and services similar to Fleetwire.io products. In any case, sending of\n emails\n shall comply with legal requirements of applicable laws (including, but not limited\n to,\n privacy laws).<br><br>\n 7.1.2. <strong>Short texts SPAM</strong>: sending unsolicited short texts to the\n cell\n phones without the permission of the user of the cell phone and/or otherwise in\n violation of applicable laws (including but not limited to, U.S. TelephoneConsumers\n Protection Act, EU General Data Protection Regulation, etc.).<br><br>\n 7.1.3. <strong>Comment SPAM</strong>: posting Links on blogs, message boards and\n forums in cases where the discussion or content is not related to the services we\n offer. However, you may advertise your Link on websites which are discussing our\n services or in a forum signature. You should never use automated bots to post\n comments\n containing your Affiliate Link.<br><br>\n 7.1.4. <strong>Black Hat techniques</strong>: using “Black hat” SEO marketing on\n your\n website, such as keyword stuffing,invisible text or doorway pages; Incentives:\n offering incentives to users such as cash back or other rewards, except where\n facilitated by features on our websites.<br><br>\n 7.2. In the event of a breach of the requirements of this Clause, Fleetwire.io\n reserves the right to terminate thisAgreement and/or place restrictions, suspend or\n delete your Affiliate account, including but not limited to,withholding all sums\n within your Affiliate account.<br></li>\n <li style=\"text-align:justify;\"><strong>PROHIBITION OF FRAUD</strong><br><br>\n 8.1. Credibility of the affiliates is of the essence to us. You are expressly\n prohibited from using any persons,means, devices or arrangements to commit fraud,\n violate any applicable law, interfere with other affiliates or falsify and/or hide\n information in connection with referrals through the Links or the generation\n ofCommissions, or exceed your permitted access to the Affiliate Program. Such acts\n include, but are in noway limited to, using automated means to increase the number\n of\n clicks through the Links or completion of any required information, hiding of\n traffic\n or making it otherwise unavailable to Fleetwire, using spyware, using stealware,\n cookie-stuffing and other deceptive acts or click-fraud. Such and similar acts shall\n constitute a material breach of this Agreement. We shall make all determinations\n about\n fraudulent activity in our sole discretion.<br><br>\n 8.2. If we have reason to believe your Affiliate account is being used to conduct\n fraudulent activities and/or fraudulent transactions or is in any way associated\n with\n fraudulent activity, we may reject any payments of the Commissions to you (in full\n or\n in part), terminate this Agreement, suspend or delete your Affiliate account, and/or\n require you to return to us any Commissions paid by us to you in relation to\n your participation in the Affiliate Program.<br></li>\n <li style=\"text-align:justify;\"><strong>LIMITED LICENSE & INTELLECTUAL\n PROPERTY</strong><br><br>\n 9.1. <strong>Licence.</strong> Provided that you comply with the terms of this\n Agreement and are a member in good standing of the Affiliate Program, only for the\n sole\n purpose of identifying your Media as a participant of the AffiliateProgram, and\n assisting in increasing sales of Fleetwire.io products or services through the\n Program\n Website,during the validity of the Agreement we grant you a limited, revocable,\n non-exclusive, non-transferable licence to:<br><br>\n 9.1.1. reproduce and make available on your Media Fleetwire's intellectual property\n (as\n defined in General Terms)that was made available to you via the Affiliate Program,\n including, without limitation, the Links;<br><br>\n 9.1.2. use Fleetwire's intellectual property that was made available to you via the\n Affiliate Program only for creating editorial content (illustrate an article, etc.)\n or\n graphical advertisements (banners, pop-up, etc.). Subject to Clause 9.3.1 below, you\n are not allowed to modify and/or create derivative works from Fleetwire's\n intellectual\n property if this has not been pre-approved in writing by us.<br><br>\n 9.2. <strong>Revocation of Licence.</strong> We, at our sole discretion, have a\n right\n to revoke, partially or in whole, your license any time by giving you a written\n notice.<br><br>\n 9.3. <strong>Restrictions on Licence.</strong> We do not transfer to you any rights,\n express or implied, in respect to Links,Program Website and/or any other Fleetwire's\n intellectual property, and we retain right, title, interest, ownership in and to\n Fleetwire's\n intellectual property. Fleetwire's intellectual property are licensed, not sold, and\n you\n receive no title to or ownership of any copy or of Fleetwire's intellectual property\n itself.\n Furthermore, you receive no rights toFleetwire's intellectual property other than\n those\n specifically granted in Section 9.1 above. Without limiting the generality of the\n foregoing, you are imperatively prohibited, and you shall not, among other\n things:<br><br>\n 9.3.1. modify, create derivative works from, distribute, publicly display, publicly\n perform, sublicense, or otherwise use the Links or any other Fleetwire's\n intellectual\n property;<br>\n 9.3.2. register and/or use the domain name with any suffix that consists of or\n contains any mark that is identical or similar to or misspellings, variations,\n modifications of Fleetwire's trademarks and/or any other Fleetwire’s\n intellectual property, for any goods or services, either similar or not to\n Fleetwire’s\n products or services<br>\n 9.3.3. use and/or to make bidding for any mark and/or keyword that is identical or\n similar to or misspellings, variations, modifications of Fleetwire’s trademarks\n and/or\n any other\n Fleetwire’s intellectual property (“<strong>Banned Keywords</strong>”) on any\n referencing\n service or search engine (such as Google AdWords), paid or otherwise, in any meta\n tags,\n advertising, search terms, code, or in a similar manner, for any goods or services,\n either similar or not to Fleetwire’s products or services;<br>\n 9.3.4. cause or create, or act in any way that causes or creates or could cause or\n create any initial interest confusion over the use of Fleetwire's intellectual\n property on\n the internet or in any search engine advertising;<br>\n 9.3.5. take unfair advantage and/or benefit of the distinctive character or repute\n of\n Fleetwire.io trademarks and/or other Fleetwire's intellectual property (free-riding)\n and/or\n dilute, whittle away and blur the distinctive character of Fleetwire's intellectual\n property\n and/or tarnish the repute of Fleetwire's intellectual property.<br><br>\n 9.4. All rights not expressly granted in this Agreement are reserved by\n Fleetwire.<br><br>\n 9.5. You represent and warrant that you are fully aware that your use of Fleetwire's\n intellectual property to any other extent than as expressly permitted in Section 9.1\n above (in addition to being a breach of thisAgreement) shall constitute the\n infringement of our rights to Fleetwire's intellectual property, and therefore may\n be\n subject to claims for damages from you.<br><br>\n 9.6. You hereby grant us a perpetual, irrevocable, worldwide license to use any\n Feedback (as defined below)you communicate to us during the validity of this\n Agreement, without compensation, without any obligation to report on such use, and\n without any other restriction. Our rights granted in the previous sentence include,\n without limitation, the right to exploit Feedback in any and every way, as well as\n the\n right to grant sub licenses. (“<strong>Feedback</strong>” refers to any suggestion,\n comment, recommendation or idea arising out or in connection with the performance of\n this Agreement, including without limitation all intellectual property rights in any\n such suggestion, comment, recommendation or idea.)<br></li>\n <li style=\"text-align:justify;\"><strong>VALIDITY AND TERMINATION</strong><br><br>\n 10.1. This Agreement comes into force upon our approval of your Affiliate Program\n application and will be valid until terminated by either you or us.<br><br>\n 10.2. Either you or we may terminate this Agreement at any time, without cause, by\n giving the other party 3(three) days’ prior written notice of termination.\n Fleetwire.io may, without limitation and free from any and all liability, terminate\n the\n Agreement with Cause immediately at any time if you are in a material breach of your\n obligations hereunder.<br><br>\n 10.3. “Cause” shall mean including, but without limitation:<br><br>\n 10.3.1. The services provided by you (a) are not compliant, fully or in part, with\n the\n Agreement; (b) are not compliant, fully or in part, with established business\n practice,\n professional standards, industry codes; (c)violate any applicable law, regulation,\n judicial or administrative action, or rights of a third parties; (d) are defamatory,\n obscene, harassing, tortuous, vulgar, invasive of another’s privacy, hateful, or\n racially,ethnically or otherwise objectionable; (d) damage the reputation, brand,\n image, likeness, expression in the public domain of Fleetwire, its representatives,\n affiliates, officers, directors, employees, agents, clients,service providers and\n all\n other related third parties;<br>\n 10.3.2. you breach the General Warranties and Representations as specified in the\n General Terms and/provisions of these Affiliate Program Terms;<br>\n 10.3.3. we believe that we may face potential claims or liability in connection with\n your participation in theAffiliate program;<br>\n 10.3.4. we believe that our brand or reputation may be tarnished by you or in\n connection with your participation in the Affiliate Program.<br><br>\n 10.4. Upon the termination of this Agreement for any reason, you shall immediately\n cease to: (i) use the Links,remove them from your Media and delete them; (ii) use\n all\n Fleetwire's intellectual property and Client’s intellectual property, and (iii)\n represent\n yourself as a Fleetwire.io Affiliate.<br><br>\n 10.5. Upon termination of your participation in the Affiliate Program for one or\n more\n Offers or termination of thisAgreement for any reason, all rights to validly accrued\n payments, causes of action and any provisions,which by their terms are intended to\n survive termination, shall survive any termination.<br><br>\n 10.6. We may hold accrued unpaid Commissions for a reasonable period of time\n following\n the termination of this Agreement to ensure that the correct amount of Commissions\n is\n paid (for example, to account for any chargebacks, refunds, cancellations or\n returns).<br></li>\n <li style=\"text-align:justify;\"><strong>REMEDIES</strong><br><br>\n 11.1. In addition to any other rights and remedies available to us under this\n Agreement, in law or in equity, were serve the right to (i) terminate the Agreement\n and/or suspend your Affiliate account or delete it, (ii)delete any actions submitted\n through your Links, and (iii) suspend and/or withhold any unpaidCommissions, and/or\n charge back paid Commissions to your account immediately upon written notice to you\n if:<br><br>\n 11.1.1. we determine that you have violated this Agreement;<br>\n 11.1.2. we receive any complaints about your participation in the Affiliate Program\n which we reasonably believe to violate this Agreement; or<br>\n 11.1.3. any Qualified Action is later determined to have not met the requirements\n set\n forth in this Agreement or on the Affiliate Program.<br><br>\n 11.2. Such suspending and/or withholding of the Commissions, or charge backs for\n paid\n Commissions, shall be without regard as to whether or not such Commissions were\n earned\n as a result of such violation.<br></li>\n <li style=\"text-align:justify;\"><strong>MODIFICATIONS TO THIS\n AGREEMENT</strong><br><br>\n 12.1. Fleetwire.io reserves the right to modify any of these terms and conditions of\n this Agreement at any time inFleetwire's sole discretion. Such modifications shall\n take\n effect upon posting to the Fleetwire's website. Fleetwire, in its sole discretion,\n reserves\n the\n right to notify you by e-mail and further reserves the right to withhold\n notification\n of any changes made to this Agreement.<br><br>\n 12.2. Modifications may include, but are not limited to, changes in the scope of\n available Commissions,Commission amounts/percentages, payment procedures, Commission\n fee payment schedules, andAffiliate Program rules.<br><br>\n 12.3. If any modification is unacceptable to you, your only recourse is to terminate\n this Agreement. Your continued participation in the Affiliate Program following our\n posting of a change notice or new agreement on our website will constitute binding\n acceptance of the change.<br></li>\n <li style=\"text-align:justify;\"><strong>INDEPENDENT REVIEW AND\n INVESTIGATION</strong><br><br>\n 13.1. Your submission of the application for the Affiliate Program acknowledges that\n you understand and have read this Agreement (including the General Terms) in full,\n and\n agree to be bound by all the terms and conditions of this Agreement. You understand\n that other Affiliates may have a different relationship with Fleetwire.io than you,\n including competitors.<br><br>\n 13.2. You acknowledge that you have independently reviewed and assessed the\n advantages\n and disadvantages of participating in this Affiliate Program, and you are not\n relying\n on any guarantees,representations, or statements other than this Agreement as set\n forth herein.\n </li>\n </ol>\n <p style=\"text-align:justify;\">I, AS A POTENTIAL AFFILIATE, INDICATE MY ASSENT TO THIS\n AGREEMENT AND MY DESIRE TO BECOME AN AFFILIATE HEREIN BOUND BY THE AFOREMENTIONED\n TERMS\n AND CONDITIONS, BY COMPLETING AND SUBMITTING THE AFFILIATE PROGRAM APPLICATION FORM,\n BY\n SUBMITTING PROPOSED REFERRED CUSTOMERS AND/OR INFORMATION REGARDING THE QUALIFYING\n ACTIONS TO FLEETWIRE.IO UNDER THIS AFFILIATE PROGRAM AND/OR BY COLLECTING ANY\n COMMISSION\n PAYMENTS FROM FLEETWIRE.</p>\n </div>\n </v-card-text>\n <v-card-actions>\n <v-btn @click=\"agreeToSDialog = false;\">Okay</v-btn>\n </v-card-actions>\n </v-card>\n </v-dialog>\n </div>\n</template>\n\n<script lang=\"ts\" setup>\nimport {onMounted, ref} from 'vue';\nimport {EventBus} from '@/plugins/eventBus';\n\n\nconst agreeToSDialog = ref(false);\n\nonMounted(() => {\n EventBus.$on('open-affiliate-terms-dialog', () => {\n agreeToSDialog.value = true;\n });\n});\n</script>\n\n","<template>\n <div>\n <div v-if=\"hasAffiliate\" class=\"mb-5\">\n <div class=\"\">\n <v-card variant=\"outlined\">\n <v-card-title>\n <div class=\"flex\">\n Payouts\n <v-spacer/>\n <v-btn :to=\"{name: 'settings.affiliate.payouts'}\" size=\"small\" variant=\"text\">\n <v-icon>mdi-arrow-right</v-icon>\n </v-btn>\n </div>\n </v-card-title>\n </v-card>\n </div>\n </div>\n\n <v-card v-if=\"!hasAffiliate\">\n <v-card-title>\n Fleetwire affiliate program\n </v-card-title>\n <v-card-subtitle>\n Join now and earn money by promoting one of the best fleet management services.\n </v-card-subtitle>\n <v-card-text></v-card-text>\n </v-card>\n\n <v-card v-if=\"hasAffiliate && !affiliate.agree_tos_at\" :loading=\"affiliateLoading.affiliateAgreeTOS\" class=\"my-5\" variant=\"outlined\">\n <v-card-title>\n Agree to ToS\n </v-card-title>\n <v-card-text>\n <v-checkbox\n v-model=\"agreeToS\"\n label=\"I agree to the Fleetwire Affiliate Partner Terms of Service.\"\n >\n <template v-slot:label>\n I agree to the\n <v-btn size=\"small\" variant=\"text\" @click=\"EventBus.$emit('open-affiliate-terms-dialog');\">Fleetwire\n Affiliate Partner Terms of\n Service.\n </v-btn>\n </template>\n\n </v-checkbox>\n\n <v-btn :disabled=\"!agreeToS\" :loading=\"affiliateLoading.affiliateAgreeTOS\" @click=\"affiliateTOSAgree()\">Accept\n </v-btn>\n </v-card-text>\n </v-card>\n\n <v-card v-if=\"hasAffiliate\" :disabled=\"!affiliate.agree_tos_at\" variant=\"outlined\">\n <v-card-title>\n Affiliate Referrals\n <v-spacer/>\n </v-card-title>\n <v-card-text class=\"mt-3\">\n <div class=\"my-5\">\n Affiliate URL:\n <a :href=\"`https://fleetwire.io/r/${affiliate.slug}`\">https://fleetwire.io/r/{{ affiliate.slug }}</a>\n\n </div>\n <v-data-table\n :headers=\"headers\"\n :items=\"affiliate.referral\"\n :items-per-page=\"10\"\n >\n <template v-slot:item.id=\"{ index }\">\n {{ index + 1 }}\n </template>\n <template v-slot:item.user.full_name=\"{ item }\">\n {{ item.user.full_name }}\n </template>\n <template v-slot:item.user.subscribed=\"{ item }\">\n <span v-if=\"item.user.subscribed\" class=\"text-green-700\">\n Subscribed <span class=\"italic\">({{ item.subscribed_product }})</span>\n </span>\n </template>\n <template v-slot:item.created_at=\"{ item }\">\n {{ formatRentalDate(item.created_at, 'ddd MMM DD @ h:mm a') }}\n </template>\n <template v-slot:item.user.trial_ends_at=\"{ item }\">\n <span v-if=\"item.user.trial_ends_at\">\n {{ formatRentalDate(item.user.trial_ends_at, 'ddd MMM DD @ h:mm a') }}\n </span>\n </template>\n </v-data-table>\n </v-card-text>\n </v-card>\n\n <div class=\"mt-10\">\n <v-btn v-if=\"agreeToS\" size=\"small\" variant=\"text\" @click=\"EventBus.$emit('open-affiliate-terms-dialog');\">Terms &\n Conditions\n </v-btn>\n </div>\n\n <AffiliateTerms/>\n\n </div>\n</template>\n\n<script lang=\"ts\" setup>\nimport {computed, onBeforeMount, ref, watch} from 'vue';\nimport {EventBus} from '@/plugins/eventBus';\nimport AffiliateTerms from '@/views/dashboard/settings/Affiliate/AffiliateTerms.vue';\nimport {useDateFormatter} from '@/composables/useDate';\nimport {useStore} from 'vuex';\nimport {useRouter} from 'vue-router';\n\nconst router = useRouter();\n\nconst store = useStore();\nconst {formatRentalDate} = useDateFormatter();\n\nconst hasAffiliate = ref(false);\nconst agreeToS = ref(false);\n\nconst headers = [\n {\n text: '#',\n align: 'start',\n value: 'id',\n },\n {\n text: 'Name',\n value: 'user.full_name',\n },\n {\n text: 'Email',\n value: 'user.email',\n },\n {text: 'Referred', value: 'created_at'},\n {text: 'Trial Ends', value: 'user.trial_ends_at'},\n {text: 'Active Subscription', value: 'user.subscribed'},\n];\n\nconst affiliateLoading = computed(() => store.getters['settings/loading']);\nconst affiliate = computed(() => store.getters['affiliate/affiliate']);\nconst affiliateApplication = computed(() => store.getters['affiliate/affiliateApplication']);\n\nconst affiliateApplications = () => store.dispatch('affiliate/affiliateApplications');\nconst getAffiliate = () => store.dispatch('affiliate/getAffiliate');\nconst affiliateTOSAgree = () => {\n store.dispatch('affiliate/affiliateTOSAgree').then(() => {\n getAffiliate();\n });\n}\n\nwatch(affiliate, (affiliate) => {\n if (affiliate) {\n hasAffiliate.value = true;\n // affiliateApplications();\n }\n});\n\nwatch(affiliateApplication, (application) => {\n ray(application);\n if (!application || application.status !== 'approved') {\n router.push({name: 'settings.affiliate.signup'}).catch(() => {\n });\n }\n});\n\nonBeforeMount(() => {\n getAffiliate();\n});\n</script>\n\n","<template>\n <div>\n <div v-if=\"affiliateLoading.affiliateApplication\">\n <v-progress-circular\n :size=\"50\"\n color=\"primary\"\n indeterminate\n ></v-progress-circular>\n </div>\n\n <v-card v-else-if=\"!affiliateApplication\">\n <v-card-title>\n Affiliate Signup\n </v-card-title>\n <v-card-text class=\"mt-3\">\n <v-form v-model=\"formReady\">\n <h5 class=\"h5 my-5\">Account Details</h5>\n <v-text-field\n v-model=\"application.company_name\"\n :error-messages=\"affiliateForm.errors.get('company_name')\"\n label=\"Company Name\"\n name=\"company\"\n required\n variant=\"outlined\"\n @keydown=\"affiliateForm.errors.clear('company_name')\"\n ></v-text-field>\n\n <v-text-field\n v-model=\"application.website\"\n :error-messages=\"affiliateForm.errors.get('website')\"\n label=\"Website\"\n name=\"website-url\"\n variant=\"outlined\"\n @keydown=\"affiliateForm.errors.clear('website')\"\n ></v-text-field>\n\n <v-text-field\n v-model=\"application.phone\"\n :error-messages=\"affiliateForm.errors.get('phone')\"\n label=\"Phone\"\n name=\"phone\"\n variant=\"outlined\"\n @keydown=\"affiliateForm.errors.clear('phone')\"\n ></v-text-field>\n\n <h5 class=\"h5\">Additional Details</h5>\n\n <v-text-field\n v-model=\"application.channel\"\n :error-messages=\"affiliateForm.errors.get('channel')\"\n label=\"URL of website/channel you intend to promote our product(s) on?\"\n name=\"url\"\n variant=\"outlined\"\n @keydown=\"affiliateForm.errors.clear('channel')\"\n ></v-text-field>\n\n <v-select\n v-model=\"application.use_popup\"\n :error-messages=\"affiliateForm.errors.get('use_popup')\"\n :items=\"['yes', 'no']\"\n label=\"Do you plan to drive popup/popunder traffic?\"\n variant=\"outlined\"\n @update:model-value=\"affiliateForm.errors.clear('use_popup')\"\n ></v-select>\n <v-select\n v-model=\"application.use_ppc\"\n :error-messages=\"affiliateForm.errors.get('use_ppc')\"\n :items=\"['yes', 'no']\"\n label=\"Do you plan to drive traffic to your site(s) through PPC/paid advertising?\"\n variant=\"outlined\"\n @update:model-value=\"affiliateForm.errors.clear('use_ppc')\"\n ></v-select>\n\n <v-textarea\n v-model=\"application.method_to_promote\"\n :error-messages=\"affiliateForm.errors.get('method_to_promote')\"\n label=\"How do you intend to promote our product(s)?\"\n name=\"usage\"\n variant=\"outlined\"\n @keydown=\"affiliateForm.errors.clear('method_to_promote')\"\n ></v-textarea>\n\n <v-text-field\n v-model=\"application.url\"\n :error-messages=\"affiliateForm.errors.get('url')\"\n hint=\"The Affiliate URL is the link your referrals will sign up with and how we know how to track and match the signup with you. Only alphanumeric, '-', '_' characters.\"\n label=\"Desired Affiliate URL\"\n prefix=\"https://fleetwire.io/r/\"\n @keydown=\"nameKeydown($event)\"\n @keyup=\"affiliateForm.errors.clear('url')\"\n ></v-text-field>\n\n <v-checkbox\n v-model=\"application.agreeToS\"\n :error-messages=\"affiliateForm.errors.get('agreeToS')\"\n label=\"I agree to the Fleetwire Affiliate Partner Terms of Service.\"\n @update:model-value=\"affiliateForm.errors.clear('agreeToS')\"\n >\n <template v-slot:label>\n I agree to the\n <v-btn size=\"small\" variant=\"text\" @click=\"EventBus.$emit('open-affiliate-terms-dialog');\">Fleetwire\n Affiliate Partner Terms of\n Service.\n </v-btn>\n </template>\n\n </v-checkbox>\n\n <div v-if=\"affiliateForm.errors.any()\" class=\"mt-5\">\n <v-alert closable type=\"error\">\n Please correct the errors above.\n </v-alert>\n </div>\n\n <v-btn class=\"mt-5\" @click=\"submitAffiliateApplicationInit(application)\">Sign Up</v-btn>\n </v-form>\n </v-card-text>\n </v-card>\n\n <v-card v-else-if=\"affiliateApplication\" variant=\"outlined\">\n <v-card-title>\n Affiliate Signup Success\n </v-card-title>\n <v-card-text>\n Date of application: {{ formatRentalDate(affiliateApplicationCreatedAt) }}<br>\n\n We will review your application and get back to you shortly.\n\n <div class=\"mt-10\">\n <v-btn size=\"small\" variant=\"text\" @click=\"EventBus.$emit('open-affiliate-terms-dialog');\">Terms &\n Conditions\n </v-btn>\n </div>\n </v-card-text>\n </v-card>\n <AffiliateTerms/>\n </div>\n</template>\n\n<script lang=\"ts\" setup>\nimport {computed, onBeforeMount, ref, watch} from 'vue';\nimport {EventBus} from '@/plugins/eventBus';\nimport AffiliateTerms from '@/views/dashboard/settings/Affiliate/AffiliateTerms.vue';\nimport {useDateFormatter} from '@/composables/useDate';\nimport {useStore} from 'vuex';\nimport {useRouter} from 'vue-router';\n\nconst store = useStore();\nconst {formatRentalDate} = useDateFormatter();\n\nconst router = useRouter();\n\nconst submitSuccess = ref(false);\nconst formReady = ref(null);\nconst application = ref({\n company_name: '',\n website: '',\n phone: '',\n channel: '',\n use_popup: '',\n use_ppc: '',\n method_to_promote: '',\n url: '',\n agreeToS: false,\n});\n\nconst affiliateLoading = computed(() => store.getters['affiliate/loading']);\nconst affiliate = computed(() => store.getters['affiliate/affiliate']);\nconst affiliatePayouts = computed(() => store.getters['affiliate/affiliatePayouts']);\nconst affiliateApplication = computed(() => store.getters['affiliate/affiliateApplication']);\nconst affiliateForm = computed(() => store.getters['affiliate/affiliateForm']);\nconst affiliateApplicationCreatedAt = computed(() => affiliateApplication.value?.created_at);\n\nconst affiliateUrl = computed(() => affiliate.value?.url);\nconst affiliateActive = computed(() => affiliate.value?.active);\n\nconst affiliateApplications = () => store.dispatch('affiliate/affiliateApplications');\nconst submitAffiliateApplication = (application) => store.dispatch('affiliate/submitAffiliateApplication', application);\n\nconst nameKeydown = (e) => {\n if (/[^a-zA-Z0-9-_]/.test(e.key)) {\n e.preventDefault();\n }\n};\n\nconst submitAffiliateApplicationInit = (application) => {\n submitAffiliateApplication(application).then(() => {\n submitSuccess.value = true;\n application.value = {\n company_name: '',\n website: '',\n phone: '',\n channel: '',\n use_popup: '',\n use_ppc: '',\n method_to_promote: '',\n url: '',\n agreeToS: false,\n };\n });\n};\n\nwatch(affiliateUrl, (val) => {\n if (!val) return;\n\n application.value.url = val.replace(/[^a-zA-Z0-9-_]/g, '');\n});\n\nwatch(affiliateActive, (val) => {\n if (val) {\n ray('affiliate active');\n router.push({name: 'settings.account.affiliate.index'}).catch(() => {\n });\n }\n});\n\nonBeforeMount(() => {\n affiliateApplications();\n});\n</script>\n\n","<template>\n <div>\n <v-card variant=\"flat\">\n <v-card-title>\n <v-btn :to=\"{name: 'settings.account.affiliate.index'}\" class=\"mr-2\" size=\"small\" variant=\"text\">\n <v-icon>mdi-arrow-left</v-icon>\n </v-btn>\n Payouts\n <v-spacer/>\n </v-card-title>\n <v-card-text class=\"mt-3\">\n <div class=\"mb-5\">\n <div class=\"grid grid-cols-2 gap-2\">\n <div>\n <v-card>\n <v-card-title>Past Payouts</v-card-title>\n <v-card-text>{{ formatMoneyDisplayUSD(affiliatePayoutsPast) }}</v-card-text>\n </v-card>\n </div>\n <div>\n <v-card>\n <v-card-title>Future Payouts</v-card-title>\n <v-card-text>{{ formatMoneyDisplayUSD(affiliatePayoutsFuture) }}</v-card-text>\n </v-card>\n </div>\n </div>\n </div>\n\n <v-data-table\n :headers=\"headers\"\n :items=\"affiliatePayouts\"\n :items-per-page=\"20\"\n >\n <template v-slot:item.id=\"{ index }\">\n {{ index + 1 }}\n </template>\n <template v-slot:item.payout=\"{ item }\">\n {{ formatMoneyDisplayUSD(item.payout) }}\n </template>\n </v-data-table>\n </v-card-text>\n </v-card>\n </div>\n</template>\n\n<script lang=\"ts\" setup>\nimport {onMounted, computed} from 'vue';\nimport {useMoneyFormatter} from '@/composables/useMoneyFormatter';\nimport {useStore} from 'vuex';\n\nconst store = useStore();\n\nconst {formatMoneyDisplayUSD, formatNumberWithCommas} = useMoneyFormatter();\n\nconst affiliate = computed(() => store.getters['affiliate/affiliate']);\nconst affiliatePayouts = computed(() => store.getters['affiliate/affiliatePayouts']);\nconst affiliatePayoutsPast = computed(() => store.getters['affiliate/affiliatePayoutsPast']);\nconst affiliatePayoutsFuture = computed(() => store.getters['affiliate/affiliatePayoutsFuture']);\n\nconst getAffiliatePayouts = () => {\n store.dispatch('affiliate/getAffiliatePayouts');\n};\n\nconst headers = [\n {text: '#', value: 'id'},\n {text: 'Subscriptions', value: 'subscriptions'},\n {text: 'Trials', value: 'trials'},\n {text: 'Period Start', value: 'period_start'},\n {text: 'Period End', value: 'period_end'},\n {text: 'Payout', value: 'payout'},\n {text: 'Paid', value: 'payout_at'},\n];\n\nonMounted(() => {\n getAffiliatePayouts();\n});\n</script>\n\n","<template>\n <div>\n <v-dialog v-model=\"openDialog\" :persistent=\"true\" width=\"500\">\n <v-card :disabled=\"custodianLoading.create\">\n <v-card-title class=\"break-normal\">\n {{ mode }} external custodial\n </v-card-title>\n <v-card-text>\n <p class=\"mb-5\">\n Allow others outside your company to manage the orders of the selected\n listings. Whoever accepts the invite link will have control over the\n listings you select below.\n <TheHelpLink url=\"https://help.fleetwire.io/en/article/custodians-1wu4w2h/?bust=1664293159925\"/>\n </p>\n\n <div v-if=\"mode === 'Edit'\" class=\"grid grid-cols-4 mb-5\">\n <strong>Company:</strong> <span class=\"col-span-3\">{{ childCompanyName }}</span>\n <strong>Company Email:</strong> <span class=\"col-span-3\">{{ childCompanyEmail }}</span>\n <strong>Accepted:</strong> <span class=\"col-span-3\">{{ acceptedAt }}</span>\n </div>\n\n <ListingAutocompleteDropdown\n :allow-multiple=\"true\"\n :allow-select-all=\"true\"\n label=\"Listings to manage\"\n @selectedListing=\"listingSelected($event)\"\n />\n\n\n <div class=\"d-none\">\n <div class=\"text-h6\">Permissions</div>\n <v-checkbox v-model=\"custodianPermissions.order_view\" density=\"compact\" hide-details>\n <template v-slot:label>\n <div>\n View Listing Orders\n </div>\n </template>\n </v-checkbox>\n <v-checkbox v-model=\"custodianPermissions.listing_update\" density=\"compact\" hide-details>\n <template v-slot:label>\n <div>\n Update Listing Details\n </div>\n </template>\n </v-checkbox>\n </div>\n </v-card-text>\n <v-card-actions>\n <v-spacer/>\n <v-btn color=\"grey\" variant=\"text\" @click=\"openDialog = false\">Cancel</v-btn>\n <v-btn v-if=\"mode === 'Add'\" :disabled=\"nextButtonDisabled\" :loading=\"custodianLoading.create\" color=\"primary\" @click=\"generateLink()\">\n Next\n </v-btn>\n <v-btn v-if=\"mode === 'Edit'\" :disabled=\"nextButtonDisabled\" :loading=\"custodianLoading.update\" color=\"primary\" @click=\"updateCustodianInit()\">\n Update\n </v-btn>\n </v-card-actions>\n </v-card>\n </v-dialog>\n\n <v-dialog v-model=\"openDialogStep2\" width=\"500\">\n <v-card>\n <v-card-title class=\"break-normal\">\n Here is your invite link\n </v-card-title>\n\n <v-card-text>\n <p>\n Email or Copy & send this link to a custodian you want to\n have access to the listings you selected.\n You can delete or change access at any time.\n <TheHelpLink url=\"https://help.fleetwire.io/en/article/custodians-1wu4w2h/?bust=1664293159925\"/>\n </p>\n <div class=\"mt-5\">\n <v-text-field\n v-model=\"managerShareEmailLink\"\n label=\"Email Invite Link\"\n variant=\"outlined\"\n >\n <template v-slot:append>\n <v-fade-transition :leave-absolute=\"true\">\n <v-progress-circular\n v-if=\"emailLoading\"\n color=\"info\"\n indeterminate\n size=\"24\"\n ></v-progress-circular>\n <v-icon v-else @click=\"sendInviteEmailLinkInit()\">mdi-send</v-icon>\n </v-fade-transition>\n </template>\n </v-text-field>\n </div>\n\n <div class=\"my-5 hr-lr\">\n <span>Or</span>\n </div>\n <v-scroll-y-transition>\n <div v-if=\"showManagerShareLink\" class=\"manager-link-container mt-2\">\n <input id=\"share-link-hidden\" :value=\"managerShareLink\" class=\"d-none\">\n <div class=\"manager-link-field\">{{ managerShareLink }}</div>\n <div data-link-only=\"true\">\n <v-btn variant=\"text\" @click=\"copyToClipboardInit(managerShareLink); copyToClipboardSuccessSnack = true\">\n <v-icon size=\"small\">mdi-content-copy</v-icon>\n </v-btn>\n </div>\n </div>\n </v-scroll-y-transition>\n </v-card-text>\n <v-card-actions>\n <v-spacer/>\n <v-btn color=\"primary\" @click=\"openDialogStep2 = false\">Okay</v-btn>\n </v-card-actions>\n </v-card>\n </v-dialog>\n\n <v-snackbar v-model=\"copyToClipboardSuccessSnack\">\n Copied to clipboard!\n <template v-slot:actions>\n <v-btn variant=\"text\" @click=\"copyToClipboardSuccessSnack = false\">\n Close\n </v-btn>\n </template>\n </v-snackbar>\n </div>\n</template>\n\n<script lang=\"ts\">\nimport {mapActions, mapGetters} from 'vuex';\nimport {get} from 'lodash';\nimport {EventBus} from '@/plugins/eventBus';\nimport dayjs from 'dayjs';\nimport {copyTextToClipboard} from '@/helpers';\n\nconst ListingAutocompleteDropdown = () => import('@/components/dashboard/listings/ListingAutocompleteDropdown.vue');\n\nexport default {\n name: 'ListingAddManagersDialog',\n\n components: {\n ListingAutocompleteDropdown\n },\n\n props: {\n custodian: {\n type: Object,\n default: null,\n },\n mode: {\n type: String,\n default: 'Add',\n },\n },\n\n data() {\n return {\n emailLoading: false,\n openDialog: false,\n openDialogStep2: false,\n copyToClipboardSuccessSnack: false,\n showManagerShareLink: false,\n selectedListings: [],\n managerShareLink: '',\n managerShareEmailLink: '',\n currentWorkingInvite: null,\n custodianPermissions: {\n order_view: true,\n listing_update: true,\n },\n };\n },\n\n created() {\n EventBus.$on('open-add-listing-manager-dialog', (custodian = null) => {\n if (this.mode === 'Edit') {\n this.getCustodianListings(custodian);\n }\n\n this.openDialog = true;\n this.fetchListings();\n });\n EventBus.$on('custodial-invite-success', (invite) => {\n this.openDialog = false;\n\n if (this.mode === 'Add') {\n this.openDialogStep2 = true;\n this.managerShareLink = get(invite, 'invite_url', '');\n this.currentWorkingInvite = invite;\n this.showManagerShareLink = true;\n }\n\n this.selectedListings = [];\n });\n\n EventBus.$on('get-custodian-listings-success', (listings) => {\n this.selectedListings = listings;\n EventBus.$emit('set-selected-listings-for-dropdown', listings);\n });\n },\n\n computed: {\n ...mapGetters({\n fleetResourceListings: 'listing/fleetResourceListings',\n custodianLoading: 'custodian/loading',\n invite: 'custodian/invite',\n custodianListings: 'custodian/listings',\n }),\n childCompanyName() {\n return get(this.custodian, 'company.name', 'na');\n },\n childCompanyEmail() {\n return get(this.custodian, 'company.email', 'na');\n },\n acceptedAt() {\n if (this.custodian && this.custodian.accepted_at) {\n return dayjs(this.custodian.accepted_at).format('MMM D, YYYY h:mm A');\n }\n return 'Not yet accepted';\n },\n allAvailableVehiclesSelected() {\n return this.selectedListings.length === this.fleetResourceListings.length;\n },\n hasSomeVehiclesSelected() {\n return this.selectedListings.length > 0;\n },\n nextButtonDisabled() {\n return !this.hasSomeVehiclesSelected;\n },\n selectedListingIds() {\n return this.selectedListings.map((listing) => listing.l_id);\n },\n icon() {\n if (this.allAvailableVehiclesSelected) return 'mdi-close-box';\n if (this.hasSomeVehiclesSelected) return 'mdi-minus-box';\n return 'mdi-checkbox-blank-outline';\n },\n },\n\n methods: {\n ...mapActions({\n fetchListings: 'listing/fetchListings',\n createInvite: 'custodian/createInvite',\n updateCustodian: 'custodian/updateCustodian',\n getCustodianListings: 'custodian/getCustodianListings',\n sendInviteEmailLink: 'custodian/sendInviteEmailLink',\n }),\n sendInviteEmailLinkInit() {\n this.emailLoading = true;\n setTimeout(() => {\n this.emailLoading = false;\n }, 2000);\n this.sendInviteEmailLink({\n custodian_uuid: this.currentWorkingInvite.uuid,\n email: this.managerShareEmailLink,\n });\n },\n updateCustodianInit() {\n this.updateCustodian({\n listings: this.selectedListingIds,\n custodian: this.custodian,\n });\n },\n generateLink() {\n this.createInvite({\n listings: this.selectedListingIds,\n });\n },\n listingSelected(listing) {\n this.selectedListings = listing;\n },\n copyToClipboardInit(text) {\n try {\n copyTextToClipboard(text);\n this.copiedText = true;\n } catch (err) {\n console.dir(err);\n // eslint-disable-next-line no-alert\n alert('Oops, unable to copy');\n }\n },\n },\n\n beforeUnmount() {\n EventBus.$off('open-add-listing-manager-dialog');\n EventBus.$off('custodial-invite-success');\n EventBus.$off('get-custodian-listings-success');\n },\n};\n</script>\n\n<style>\n/*.hr-lr {*/\n/* width: 100%;*/\n/* text-align: center;*/\n/* border-bottom: 1px solid rgba(130, 147, 131, 0.85);*/\n/* line-height: 0.1em;*/\n/* margin: 10px 0 20px;*/\n/*}*/\n/*.hr-lr span {*/\n/* background:#fff;*/\n/* padding:0 10px;*/\n/*}*/\n\n.hr-lr {\n overflow: hidden;\n text-align: center;\n}\n\n.hr-lr:before,\n.hr-lr:after {\n background-color: #000;\n content: \"\";\n display: inline-block;\n height: 1px;\n position: relative;\n vertical-align: middle;\n width: 50%;\n}\n\n.hr-lr:before {\n right: 0.5em;\n margin-left: -50%;\n}\n\n.hr-lr:after {\n left: 0.5em;\n margin-right: -50%;\n}\n\n.manager-link-container {\n align-items: center;\n background: #f1f3f4;\n border-radius: 4px;\n color: #5f6368;\n display: flex;\n padding-left: 0.75rem;\n}\n\n.manager-link-field {\n letter-spacing: .00625em;\n font-family: Roboto, Arial, sans-serif;\n font-size: 1rem;\n font-weight: 400;\n line-height: 1.5rem;\n color: #202124;\n flex-grow: 1;\n}\n</style>\n","<template>\n <div>\n <v-card>\n <v-card-title>Custodians</v-card-title>\n <v-card-subtitle>\n Manage your custodians\n <TheHelpLink url=\"https://help.fleetwire.io/en/article/custodians-1wu4w2h/?bust=1664293159925\"/>\n </v-card-subtitle>\n <v-card-text>\n <table class=\"w-full text-sm text-left text-gray-500 dark:text-gray-400\">\n <thead class=\"text-xs text-gray-700 uppercase bg-gray-50 dark:bg-gray-700 dark:text-gray-400\">\n <tr>\n <th class=\"px-6 py-3\" scope=\"col\">\n #\n </th>\n <th class=\"px-6 py-3\" scope=\"col\">\n Invite Url\n </th>\n <th class=\"px-6 py-3\" scope=\"col\">\n Accepted\n </th>\n <th class=\"px-6 py-3\" scope=\"col\">\n Company\n </th>\n <th class=\"px-6 py-3\" scope=\"col\"></th>\n </tr>\n </thead>\n <tbody>\n <tr v-for=\"(custodian, index) in custodians\" :key=\"custodian.uuid\" class=\"bg-white border-b dark:bg-gray-800 dark:border-gray-700 hover:bg-gray-50 dark:hover:bg-gray-600\">\n <th class=\"px-6 py-4 font-medium text-gray-900 whitespace-nowrap dark:text-white\" scope=\"row\">\n <span v-tippy=\"custodian.uuid\">{{ index + 1 }}</span>\n <v-icon v-if=\"isAccepted(custodian)\" color=\"green\" size=\"small\">mdi-check</v-icon>\n <v-icon v-else color=\"orange\" size=\"small\">mdi-account-clock-outline</v-icon>\n </th>\n <td class=\"px-6 py-4\">\n {{ inviteUrl(custodian) }}\n\n <v-btn v-if=\"!isAccepted(custodian)\" variant=\"text\" @click=\"copyToClipboardInit(inviteUrl(custodian)); copyToClipboardSuccessSnack = true\">\n <v-icon size=\"small\">mdi-content-copy</v-icon>\n </v-btn>\n <input :id=\"`share-link-hidden-${index}`\" :value=\"inviteUrl(custodian)\" class=\"d-none\">\n </td>\n <td class=\"px-6 py-4\">\n {{ acceptedAt(custodian) }}\n </td>\n <td class=\"px-6 py-4\">\n {{ childCompanyName(custodian) }}\n <div class=\"small\">{{ childCompanyEmail(custodian) }}</div>\n </td>\n <td class=\"px-6 py-4\">\n <div class=\"float-end\">\n <v-btn size=\"small\" variant=\"text\" @click=\"openDeleteConfirmDialogInit(custodian)\">\n <v-icon color=\"red\" size=\"small\">mdi-delete</v-icon>\n </v-btn>\n <v-btn size=\"small\" variant=\"text\" @click=\"openUpdateConfirmDialogInit(custodian)\">\n <v-icon size=\"small\">mdi-pencil</v-icon>\n </v-btn>\n <v-btn class=\"d-none\" size=\"small\" variant=\"text\">\n <v-icon size=\"small\">mdi-eye</v-icon>\n </v-btn>\n </div>\n </td>\n </tr>\n </tbody>\n </table>\n </v-card-text>\n </v-card>\n\n <v-dialog v-model=\"openDeleteConfirmDialog\" width=\"400\">\n <v-card :disabled=\"custodiansLoading.delete\">\n <v-card-title class=\"break-normal\">\n Are you sure?\n </v-card-title>\n <v-card-text>\n <div v-if=\"isAccepted(currentWorkingCustodian)\">\n If you delete this custodian ({{ childCompanyName(currentWorkingCustodian) }}), they will no longer have\n access to the resources you've allowed.\n <TheHelpLink url=\"https://help.fleetwire.io/en/article/custodians-1wu4w2h/?bust=1664293159925\"/>\n </div>\n <div v-else>\n If you delete this custodian invite, they will no longer be able to claim the invite link.\n <TheHelpLink url=\"https://help.fleetwire.io/en/article/custodians-1wu4w2h/?bust=1664293159925\"/>\n </div>\n </v-card-text>\n <v-card-actions>\n <v-spacer/>\n <v-btn :loading=\"custodiansLoading.delete\" color=\"error\" @click=\"deleteCustodian(currentWorkingCustodian)\">\n Delete\n </v-btn>\n </v-card-actions>\n </v-card>\n </v-dialog>\n\n <ListingAddManagersDialog :custodian=\"currentWorkingCustodian\" mode=\"Edit\"/>\n\n <v-snackbar v-model=\"copyToClipboardSuccessSnack\">\n Copied to clipboard!\n <template v-slot:actions>\n <v-btn variant=\"text\" @click=\"copyToClipboardSuccessSnack = false\">\n Close\n </v-btn>\n </template>\n </v-snackbar>\n </div>\n</template>\n\n<script lang=\"ts\">\nimport {mapActions, mapGetters} from 'vuex';\nimport {get} from 'lodash';\nimport dayjs from 'dayjs';\nimport {EventBus} from '@/plugins/eventBus';\nimport {copyTextToClipboard} from '@/helpers';\n\nimport ListingAddManagersDialog from '@/components/dashboard/dialogs/ListingAddManagersDialog.vue';\n\nexport default {\n name: 'CustodianIndex',\n\n components: {\n ListingAddManagersDialog,\n },\n\n data() {\n return {\n copyToClipboardSuccessSnack: false,\n openDeleteConfirmDialog: false,\n currentWorkingCustodian: null,\n };\n },\n\n created() {\n this.getCustodians();\n\n EventBus.$on('delete-custodian-success', () => {\n this.openDeleteConfirmDialog = false;\n this.getCustodians();\n });\n },\n\n computed: {\n ...mapGetters({\n custodians: 'custodian/custodians',\n custodiansLoading: 'custodian/loading',\n }),\n },\n\n methods: {\n ...mapActions({\n getCustodians: 'custodian/getCustodians',\n deleteCustodians: 'custodian/deleteCustodians',\n }),\n deleteCustodian(custodian) {\n this.deleteCustodians(custodian.uuid);\n },\n isAccepted(custodian) {\n if (!custodian) return false;\n return !!custodian.accepted_at;\n },\n acceptedAt(custodian) {\n if (custodian && custodian.accepted_at) {\n return dayjs(custodian.accepted_at).format('MMM D, YYYY h:mm A');\n }\n return 'Not yet accepted';\n },\n inviteUrl(custodian) {\n if (custodian.invite_url) {\n return custodian.invite_url;\n }\n return 'Claimed';\n },\n childCompanyName(custodian) {\n return get(custodian, 'company.name', '-');\n },\n childCompanyEmail(custodian) {\n return get(custodian, 'company.email', '-');\n },\n openDeleteConfirmDialogInit(custodian) {\n this.currentWorkingCustodian = custodian;\n this.openDeleteConfirmDialog = true;\n },\n openUpdateConfirmDialogInit(custodian) {\n this.currentWorkingCustodian = custodian;\n EventBus.$emit('open-add-listing-manager-dialog', custodian);\n },\n async copyToClipboardInit(value) {\n try {\n await copyTextToClipboard(value);\n this.copiedText = true;\n } catch (error) {\n console.error(error);\n }\n },\n },\n\n beforeUnmount() {\n EventBus.$off('delete-custodian-success');\n },\n};\n</script>\n","<template>\n <div class=\"CardOnFileCard\">\n <v-card style=\"border: 1px solid rgb(224, 220, 229);\" variant=\"flat\">\n <v-card-text>\n <div>\n <div class=\"text-gray-500 dark:text-gray-400\">Card On File</div>\n <div class=\"mb-4 text-xl font-medium text-gray-900 dark:text-white\">\n <span v-if=\"!!cardLastFour\"> **** **** **** {{ cardLastFour }}</span>\n <span v-else>No Card on File</span>\n </div>\n <div>\n <a style=\"cursor: pointer;color: rgb(37, 98, 212);\" @click=\"fetchSetupUrlInit()\">\n Update credit card\n </a>\n </div>\n </div>\n </v-card-text>\n </v-card>\n </div>\n</template>\n\n<script lang=\"ts\" setup>\nimport {computed} from 'vue';\nimport {useCompany} from \"@/composables/useCompany\";\nimport {useStripe} from \"@/composables/useStripe\";\n\n\nconst {fetchSetupUrl} = useStripe();\nconst {company} = useCompany()\nconst cardLastFour = computed(() => company.value?.pm_last_four);\n\nconst fetchSetupUrlInit = () => {\n fetchSetupUrl({\n returnUrl: `${window.location.origin}/settings/account`,\n cancelUrl: `${window.location.origin}/settings/account`,\n }).then((response) => {\n console.dir(response);\n window.location.href = response.url;\n });\n}\n\n</script>","<template>\n <div class=\"RenewsOneCard\">\n <v-card style=\"border: 1px solid rgb(224, 220, 229);\" variant=\"flat\">\n <v-card-text>\n <div>\n <div class=\"text-gray-500 dark:text-gray-400\">\n <span v-if=\"inGracePeriod\">Ends On</span>\n <span v-else-if=\"inTrial\">Trialing Until</span>\n <span v-else>Renews On</span>\n </div>\n <div class=\"mb-4 text-xl font-medium text-gray-900 dark:text-white\">\n <span v-if=\"inGracePeriod\">{{ stripeEndDate }}</span>\n <span v-else-if=\"inTrial\">{{ trialEndDate }}</span>\n <span v-else>{{ currentStripeSubscriptionObjectRenewalDate }}</span>\n </div>\n <div>\n <router-link :to=\"{name: 'settings.account.receipts'}\" style=\"color: rgb(37, 98, 212);\">\n View receipts\n </router-link>\n </div>\n </div>\n </v-card-text>\n </v-card>\n </div>\n</template>\n\n<script lang=\"ts\" setup>\nimport {useSubscription} from '@/composables/useSubscription';\n\nconst {\n inTrial,\n trialEndDate,\n currentStripeSubscriptionObjectRenewalDate,\n stripeEndDate,\n inGracePeriod,\n} = useSubscription();\n</script>","<template>\n <div class=\"PlanPriceCard\">\n <v-card style=\"border: 1px solid rgb(224, 220, 229);\" variant=\"flat\">\n <v-card-text>\n <div>\n <div class=\"text-gray-500 dark:text-gray-400\">\n <span v-if=\"inTrial\">Plan Price after trial</span>\n <span v-else>Plan Price</span>\n </div>\n <div class=\"mb-4 text-xl font-medium text-gray-900 dark:text-white\">\n <span>{{ currentStripeSubscriptionObjectPlanAmount }}</span>\n </div>\n <div>\n <router-link\n :to=\"{name: 'settings.account.billing'}\"\n style=\"color: rgb(37, 98, 212);\"\n >\n View billing details\n </router-link>\n </div>\n </div>\n </v-card-text>\n </v-card>\n </div>\n</template>\n\n<script lang=\"ts\" setup>\nimport {useSubscription} from \"@/composables/useSubscription\";\n\nconst {inTrial, currentStripeSubscriptionObjectPlanAmount} = useSubscription();\n</script>"],"file":"assets/app-C1Dx1yRe.js"}