=== TEG LastDJ ===
Contributors: theeldestgeek
Tags: dj, dj booking, wedding dj, music planner, event band
Requires at least: 5.8
Tested up to: 6.7
Requires PHP: 7.4
Stable tag: 1.10.2
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

Bookings, music planning and crews for DJ companies and event bands: inquiries with an availability calendar, holds, proposals with travel, an e-signed contract and the retainer at one link, payment schedules, the client's music planner, DJs and gear kits that can never be double booked.

== Description ==

For multi-op DJ companies and event bands with several crews, and full-time wedding DJs. Replaces a DJ CRM plus a music-planning app in one licence - no client logins, no platform cut on payments.

* Website availability calendar (date-level, per DJ or the whole company) with the inquiry form; gear kits never show on the website. Shortcodes: `[teg-lastdj-availability]` (options `dj`, `months`, `form`), `[teg-lastdj-contact]` and `[teg-lastdj-account]`; full list: help/manual.md, Shortcodes.
* DJs, crews / bands and gear kits on a unique-key inventory: a DJ + kit booking is one database insert of both, so neither can be in two places at once - even when two people click at the same instant.
* Holds ranked 1st, 2nd, 3rd that lapse on their own; a lower hold challenges the 1st, who is told by e-mail and text and given a deadline.
* Packages and add-ons (uplighting, photo booth, ceremony sound, an extra hour); a travel fee per mile beyond N free miles, looked up from the venue address or typed; overtime as its own line.
* Proposal, contract and retainer at one signed link with no login: ESIGN consent, the SHA-256 of the exact version signed, a copy e-mailed to both sides.
* Payment schedule: retainer, installments, final balance; pay-by-link by default; auto-pay with a saved card only with the client's stored-card consent (Pro).
* The client's music planner on the same link: the run-of-show from your template, Must play / Play if possible / Do not play with a cap, names with pronunciation; "last edited", a change notice to the assigned DJ, a lock date and a final-details reminder.
* The assignment board: which DJ or crew, with which kit, plays each event - conflicts refused by the inventory (Pro).
* The DJ event sheet: timeline, contacts, venue address and load-in notes, the music lists - no money on it.
* Guest song requests by QR code on the night, rate-limited, with a moderation queue for the DJ (Pro).
* The DJ pay / commission report (Pro).
* Read-only link to the venue's event when TEG-EVENTCENTER runs on the same site.
* Client portal, Google Calendar both ways, reports, the dispute evidence pack.
* No platform fee: payments go to your own Square, Stripe or PayPal account.
* Dates and times follow your region; leave the date format blank to use it, or type your own (Settings > Region).
* Language: run the plugin in English or Spanish (more languages can be added later, no new version needed). Pick the shop language under Settings > Language; each person on your team can pick their own on their profile. Everything your clients see - the proposal, contract, payment page, music planner, e-mails and texts - is in the shop language. With Pro and a language pack, the TEG Companion and TEG Rover phone apps can also show their screens in the phone's language (needs the next app update).

== Frequently Asked Questions ==

= How do I change the language? =

Open Settings > Language. "Shop language" is the language your clients see: the proposal, the contract, the payment page, the music planner, the song-request page, and every e-mail and text. Choose "Same as WordPress" to follow your site's language. Under "Languages on this site" you can see which languages are ready; press "Check for language updates" to look for new ones (they download in the background, and nothing is sent about you or your clients). A language that is not ready yet shows English until it arrives. Language packs need the Pro edition. Languages already on the site keep working.

= Can my DJs and office team use a different language from the clients? =

Yes. Each person can choose "My language in the shop" on their own profile screen (Users > Profile). It changes only what that person sees on their own screens. Clients still get the shop language, whoever sent the message.

= Can the phone apps run in Spanish? =

Yes, once the next update of TEG Companion and TEG Rover is out, and when your shop has the Pro edition and a language pack. The lists and screens in the apps then follow the phone's language. Everything that is saved or sent to a client, and a quote or contract opened on the phone, stays in the shop language. Without Pro the apps stay in English.

= Why is a page still in English? =

Only words that have been translated change. Until a language is complete, the rest stays in English. A language that covers less than half of the plugin is not switched on by itself because the site is in that language; choose it under Settings > Language if you want it anyway. Your own translation files (for example from Loco Translate) are used too and win over the downloaded ones.

== Changelog ==

= 1.10.2 =
* Website shortcodes renamed to the teg-lastdj-... pattern (the old names are gone): [tld_inquiry] is now [teg-lastdj-contact], [tld_portal] is now [teg-lastdj-account], [tld_availability] is now [teg-lastdj-availability]. Pages that hold an old tag need the new one.

= 1.10.1 =
* "What's new" no longer opens by itself after an update. The dashboard has a button "What's new in <version>"; press it to read the notes.

= 1.10.0 =
* The TEG Companion and TEG Rover phone apps can show their screens in another language when your shop has the Pro edition and a language pack. This needs the next update of the apps; until then nothing changes.
* A quote, contract or invoice opened on the phone always shows exactly what your client gets, in the shop language.
* The note saved on an event when the client signs off on the phone at the event is always written in the shop language, whoever's phone it was signed on.
* Help Center and menu refresh.

= 1.9.0 =
* New Language screen in Settings: choose the language your shop uses with its clients. Each person on your team can also choose their own language on their profile, and it changes only what they see on their own screens.
* Your shop has a language of its own for everything a client receives - the proposal, the contract, the payment page, the music planner, the song-request page, e-mails and texts - so what a client gets no longer depends on who clicked the button.
* The contract and e-signature text now print in the shop language.
* The confirmation line shown to the office after sending something to a client (a hold, a proposal, a payment receipt or refund) is in the shop language too.
* The DJ roles ("DJ office manager", "DJ / performer") are named in the shop language when they are first created.
* Language packs (Spanish first) arrive later and need the Pro edition. With no pack installed, everything stays in English exactly as before.
* Shared parts brought up to date: language 1.1.0, payments 1.5.0.

= 1.8.2 =
* TEG Companion reports can show older months too (this month, last month and up to 10 more; set how many in Companion).
* Shared parts brought up to date: TEG Companion core 2.16.0.

= 1.8.1 =
* Event times follow your region (5:30 pm in the US, 17:30 in the UK): the dashboard, event screens, the event sheet, contracts, the client page, DJ assignments, the venue link and TEG Companion / TEG Rover.
* Payments: the currency symbol always matches the currency (a US shop never shows £).
* Shared parts brought up to date: events core 1.4.0, payments 1.4.0.

= 1.8.0 =
* Dates now follow your region: US shops see 11/09/2026, UK shops 09/11/2026, EU shops their country's own way - on every screen, print, e-mail, the client page and TEG Companion. Leave Settings > Region > Date format (and Time format) blank to use your region's, or type your own. Formats you saved before are kept.
* TEG Companion: the app is told your date format and order, so its dates match your screens.
* Song requests: the time a request came in follows your region (2:05 pm in the US, 14:05 in the UK).
* Shared parts brought up to date: region 1.2.0, events core 1.3.0, TEG Companion 2.15.0, TEG Rover 1.10.0, payments 1.3.0.

= 1.7.1 =
* TEG Companion: an event's Total and Balance show once, in the money section (they were listed twice, the second time in lower case).
* Calendar: the key under the grid now matches it - pink cell with a filled square = booked, hollow square = setup / turnover, grey with a cross = blocked, yellow H = holds (it said "Red: booked"). Events core 1.2.2.

= 1.7.0 =
* TEG Back Office: lists your DJs and office staff (performers linked to a WordPress user on the roster, the DJ office manager and DJ / performer roles, the site administrators), brings each linked performer's DJ pay into the payroll run (Pro), and reads the sales tax rate from Event settings > Sales tax % (default 0, so existing events and totals are unchanged).
* Shared modules brought up to date: payments 1.2.0 (pay-by-QR codes under Ways to pay; a bank transfer can be recorded by hand), Companion 2.13.0 (report card dates follow your date format), Rover 1.8.0 (Device pairing masks IP addresses), site move and licence check.

= 1.6.11 =
* Licence check knows the new TEG Total Auction Management (TAM) product.

= 1.6.10 =
* Back Office shows as Back Office in Setup; the pairing page is called Device pairing everywhere.

= 1.6.9 =
* The admin menu is grouped the same way as the other TEG shops: the phone pairing page is now "Device pairing" and comes first in Setup (Settings stays the last row of Setup).

= 1.6.8 =
* Money in another currency is always written with its own symbol.
* Product names in the licence screen use the new spelling (TEG-DELI, TEG-FOODTRUCK, TEG-BUTCHER, TEG-BAKERY).

= 1.6.7 =
* Money in another currency is written with its own symbol on the TEG Rover cards.

= 1.6.6 =
* TEG Rover asks for money on a gig in its event's currency.

= 1.6.5 =
* Customer links (invoices, quotes, bookings and the like) only open with their exact key; a link with a blank or altered key opens nothing.

= 1.6.4 =
* TEG Rover collects on an invoice in the currency it was issued in, and its cards count one currency at a time.

= 1.6.3 =
* The Event reports page now counts one currency at a time, like the rest of the shop.

= 1.6.2 =
* Totals and reports now count one currency at a time: after a region switch, money in the old currency is listed apart instead of being added in. The TEG Companion app shows every invoice in the currency it was issued in.

= 1.6.1 =
* On an event, the client's name now opens the client's own page.

= 1.6.0 =
* New: every client now has one Client notes box, on the desktop and in the TEG Companion app: the general notes first, then the notes from their events, inquiries and holds, with who wrote each one and which came from a DJ.
* New: a Clients screen under Sales. The list shows every client; click a name to see their details, their events and their Client notes, and use Edit to change their details and general notes.
* New: in the TEG Companion app, the office and your DJs can add a note on a client or on an event. A note on an event shows on the client's notes as "From Event ...". An event on the phone also shows its client's general notes at the top.
* New: what a DJ writes when finishing a gig in TEG Rover now shows in the client's notes, marked DJ, and so do a gig card's notes.
* Fix: a staff note typed on a new event or a new inquiry is no longer copied into the client's own notes. It stays on the event or the inquiry, and shows in Client notes from there.

= 1.5.2 =
* Better: the small print on the report cards now uses a DJ company's words too. The sales cards count events ("2 events" instead of "2 sales"), and the average card is now "Average per event". Repeat clients reads "of 2 clients", where new clients come from totals "New clients", and booked ahead counts DJ days ("3 of 14 DJ days" instead of "3 of 14 slots").
* Better: the "Owed to clients" card leaves out the gift cards line while it is 0, because a DJ company does not sell gift cards. The figures on every card are the same as before.

= 1.5.1 =
* Better: tapping a report card in the TEG Companion app now opens the matching screen on the desktop. Sales, proposals, deposits, balances and cash flow open Event reports; DJ days and booked ahead open the calendar; where new clients come from opens Inquiries; today so far opens the dashboard; and on Pro the sales against DJ pay card opens DJ pay.
* Better: the cards now use a DJ company's words. "Quote to approval" is now "Proposal to booking"; follow-ups show overdue event payments and proposals waiting; cash flow shows final balances and installments due; "Owed to customers" is now "Owed to clients"; repeat and new clients say clients; occupancy is "DJ days booked"; and the margin card shows what the DJs are paid.
* Better: clearer date ranges on the cards, such as "October 1" instead of "October 1-1" and "Jan 5-10" instead of "Jan 5 to Jan 10".

= 1.5.0 =
* New: report cards in the TEG Companion app, chosen per person. Each person picks the cards they want to see, and the cards are sorted into sections (bookings, money, staff and so on).
* New: a Reports cards page on the desktop (under Money). It shows the same cards with your figures side by side with the last period, the same time last year or dates you choose. You can set goals, download any card as a CSV file and print the page.
* New: cards made for a DJ company: your bookings pipeline, booked revenue for this month and the next two, balances coming due, DJ days booked per DJ, cancellations this month (with what was paid and kept), how busy your DJs are and how far ahead you are booked. On Pro there is also a DJ pay card and a sales against DJ pay card, which match the DJ pay report.
* New: "Lost customers after N days" under Settings > DJ rules > Reports. A client who has booked with you at least twice and has had nothing for that many days shows on the "Regulars to call" card.
* New: an optional monthly summary e-mail of your report cards. It stays off until you save it on the Reports cards page.
* Fix: turning the plugin off now also stops all of its scheduled e-mails and background tasks, including the monthly summary and the client sign-in clean-up.

= 1.4.0 =
* New: TEG Rover, the phone app for your DJs and crew, now comes with TEG LastDJ alongside the TEG Companion app. Rover stays switched off until you turn it on: tick "Rover (drivers / field staff)" on the Phones page. Once on, each booked event becomes a gig for its own DJ - venue address, load-in time, gear kit and set times on the phone, with arrival and finishing recorded on the event. Phones already paired with TEG Companion keep working; nobody has to pair again.
* New: errands in TEG Rover. Send a DJ or crew member to pick something up (with ready-made errands to start from), and confirm what they spent under Rover > Errand spending.
* New: Import from CSV. Bring in your clients and gear kits from a spreadsheet: match your columns to ours, do a test run that saves nothing, keep the column matching for next time, and undo an import if it went wrong.
* New: more cards on the Reports screen in the TEG Companion app.
* Fix: while the shop is paused (no licence or the trial has ended), importing from CSV is paused too; downloading your data as CSV still works.

= 1.3.0 =
* New: E-mail test mode (Settings > E-mail test mode). Turn it on before going live and every e-mail the site sends - invoices, receipts, reminders, status notes, staff alerts - goes to one address you choose and to nobody else. The subject starts with [TEST to ...] so you can see who it was meant for; the message is exactly what the customer would get. Administrators can switch it from the TEG Companion app too (Settings > E-mail test mode), and a red notice shows on every admin page while it is on. Text messages are not e-mail and still go out.
* TEG Companion: shared Companion core 2.4.0.

= 1.2.3 =
* Square Terminal: on a bill that still owes money, staff can press "Send to Square Terminal" to take the card on the shop's paired Square Terminal; the payment is recorded once and a tip is noted, never billed. Pair the terminal under Settings > Payments.
* Card payments taken on a Clover or Elavon terminal can be recorded by hand (US shops, off until ticked in Settings > Payments). They count as card in the totals, and a whole card number typed into the note is refused.

= 1.2.2 =
* Payments now run on the TEG family's one shared payments engine: money that arrives for a document that no longer owes it is kept as unapplied money for the office to refund or move; a demo site never takes a payment; staff are alerted when a gateway payment is lost; a manual payment is capped at what is still owed; and each bill is locked while a payment is recorded, so two payments at the same moment cannot both land on it.
* Region: the region is inferred only from a currency the shop typed, never from the factory default currency it shipped with.

= 1.2.1 =
* Demo sites never take a real payment: on a demo (Demo mode, or the TEG SHOPS demo) the pay area says This is a demo - no payment is taken, every pay link and webhook is refused and nothing is recorded as paid.

= 1.2.0 =
* Payments: a manual payment cannot exceed what the document still owes; staff are alerted when a gateway payment arrives for a document that is gone.
* Load the sample DJ company only on an empty site or the demo site.
* A rebuilt payment schedule voids the unpaid rows it replaces and their pay links keep working.
* Updates: an update whose manifest publishes no SHA-256 checksum is never offered or installed.

= 1.1.0 =
* TEG Companion: the store chooses what the phone's home screen shows (owner 2026-10-28: too cluttered). Phones (TEG Companion) has a new section, **Companion home screen defaults**: one checkbox per button, card, list and bottom-bar tab the app's home has at this shop (Buttons / Cards / Lists / Bottom bar) and "Reset to starter set". Ticked = shown by default; each person can still change it on their own phone. app/hello's module rows carry `home` {v: 1, items: [{id, label, group, on}]} - only what that person can see. Never saved = the starter set: every button the app has here on (four or fewer: New <job>, New <customer> and the shop's own extras), every list and tab on. Shared Companion core 2.1.0 (generated; tools/test-companion-home.php).
* TEG Rover is part of the plugin, switched OFF by default (owner 2026-10-28: Companion and Rover in every shop): the Phones page has the setting **Rover (drivers / field staff)**. Off: no Rover phone can be paired, the Rover phone routes answer 404 and the Companion app shows no Rover module. On: a GIG (load-in and performance) is made from a signed or booked event - the client, the venue address and the load-in window (the start less the DJ's set-up time) fill in - and goes to the event's own DJ (Roster > the DJ > WordPress user); the venue's load-in notes and contact only once it is theirs; finishing it on or after the event day completes the event. Nothing about money reaches the Rover phone. TEG Companion now pairs on the same Phones page (QR or 9-digit code, the same namespace); phones paired before keep working - their keys move onto the one key store on update (DB 1.0.1). Shared Rover core 1.5.0 (generated).

= 1.0.0 =
* Before release, a third review: a contract version whose price changed after it was issued (a line added or removed while no signed version stood) can no longer be signed - the client is told a new version will follow, the office is e-mailed, and the event screen says the issued version is out of date; re-issuing it lets the client sign. Versions issued before this change are kept only where their text still matches the event exactly; any other must be re-issued. One office save that changes a signed event (the time and the guest count together) now sends the client one notice and the office one, not two.
* Before release, a second review: a DJ cannot mark an event completed while money is owed (on the website or in TEG Companion), send the client a new link, or move a signed event to another DJ, date or time; a completed event that still owes keeps its reminders, late fees, automatic payments and its place in the balance report. Any change to a signed price (or a move) is e-mailed and texted to the client with the old and new total, what changed and their link, and the office is told; an automatic payment that went up waits until the client confirms the new amount on their page (kept, with the time and IP address, in the evidence pack). Changing the settings never re-prices a signed event (travel and overtime rates, tax rules, late fee); editing the venue never drops the travel fee of a booked event.
* Before release, a security review: the DJ role (view + edit, no money) sees no price, total, payment, schedule or the client's own link on any screen, in TEG Companion or the REST API, and every money change (lines, rates, the schedule, travel fees and overtime, contracts, cancelling a booked date, refunds) is refused on the server. A signed price changes only as an explicit amendment kept in the history. Moving an event to a taken date leaves it exactly where it was. The public forms never add a phone number to a known client.
* First release: inquiries, the availability calendar, DJs / crews / gear kits on a unique-key inventory, ranked holds with challenges, packages and add-ons, travel fee and overtime, the proposal / e-signed contract / retainer at one link, payment schedules with consented auto-pay, the music planner, the assignment board, the DJ event sheet, guest song requests, the DJ pay report, the client portal, Google Calendar sync, reports and the dispute evidence pack.
* A sample DJ company for the demonstration site (Dashboard > Load the sample DJ company).
