Behold, this dump of test data from the Captain's Log database:
+--------------------------------+---------------------+
| Client | Staff Member |
+--------------------------------+---------------------+
| Chapman & Co Phrasebooks | NULL |
| Idle's Bicycle Repairs | NULL |
| Jones and Jones Spam Supplies | NULL |
| Palin's Pet Shop | NULL |
| Cleese's Luxury Hotel, Torquay | Henry Wensleydale |
| Gilliam's Cheeses | Henry Wensleydale |
| Mr Pither | Stavros Popolopolos |
| Mr Praline | Stavros Popolopolos |
| Raymond Luxury Yacht | Stavros Popolopolos |
+--------------------------------+---------------------+
This is the beginnings of the data structure behind the software. My test data "user", Wensleydale's Cheese Emporium, employs two staff members, one to advise on cheeses and the other to give Greek Dancing lessons while playing the bouzouki. Rumour has it they also sell cheeses, but I'm not able to comment on that. Note how some clients "belong" to particular users, and others are available to both (and are therefore marked as NULL).
It took me entirely too long today to get the database worked out, because of a weird bug in the tool I was (perhaps foolishly) using to save me some time in setting things up: apparently, if you care, a table specified as "DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci" is incompatible, in certain critical ways, with another one specified as "DEFAULT CHARSET=utf8", even to the point of refusing to allow foreign keys to be set up. The tool I was using told me they were identical, because some programmer got his event handlers in a twist and forgot to write the code to save the crucial piece of data. And of course, the error message is tremendously informative:
Cannot find an index in the referenced table where the
referenced columns appear as the first columns, or column types
in the table and the referenced table do not match for constraint.
How obvious. Sigh. So, not much done apart from creating the database and doing up a bit of test data. Next trick will be to make the mockup display the test data, instead of the hard-coded bits it shows right now. That will have to wait a day or two though, since I also have to get the bloody Politarchopolis website sorted out...