Difference between revisions of "VbzCart wikified topics"

From VbzWiki
Jump to navigation Jump to search
(→‎Tables: process; more tables)
m (→‎revision: format goof)
Line 62: Line 62:
 
{|
 
{|
 
|-
 
|-
| '''rev_id || int || local key
+
| '''rev_id''' || int || local key
 
|-
 
|-
| '''rev_page || int || foreign key from ['''page''']
+
| '''rev_page''' || int || foreign key from ['''page''']
 
|-
 
|-
| '''rev_text_id || int || foreign key to ['''text''']
+
| '''rev_text_id''' || int || foreign key to ['''text''']
 
|}
 
|}
 +
 
===text===
 
===text===
 
Contains the (unparsed) page contents for all revisions
 
Contains the (unparsed) page contents for all revisions

Revision as of 01:17, 15 July 2006

Notes

Some preliminary design notes on using MediaWiki Categories to manage the store topic links.

The basic idea is that we would designate a set of Categories for use in the store "topics" pages. The categories to be used would probably be designated by some sort of prefix on the category name, like 'vtopic'... so a topic which would be displayed as "Stuff and Things" would have the page name "Category:vtopic:Stuff and Things".

Probably going to abandon the numeric topics, and have aliases. Old-style number-topics will be redirected to new-style names. Aliases and alternate spellings will be redirected the same way.

So, for example: topics/1367/ (subject -> dates):

  • looks up a page called Category:vtopic:1367
  • that page contains "#redirect [[Category:vtopic:dates]]"
  • Category:vtopic:dates contains:
    • Category:vtopics (for ease of maintenance, and perhaps for generating master index)
    • Delimiter to indicate beginning of vbzcart data
    • List of catalog numbers
    • Long-version title ("items with a date")
    • For utility topics:
      • Descriptive text for web page
    • For folder topics:
      • optional flag: display thumbnails of other items in topic
      • optional flag: display subtopic items within this topic (recurse only as long as this flag is set in subtopics)

Tables

Process: find title in page.page_title, get page.page_latest. Look that up in revision.rev_id, get revision.rev_text_id. Look that up in text.old_id, and get text.old_text, which is the raw (unparsed) contents of the page.

Relevant bits of existing MediaWiki tables:

page

page_id Autonumber
page_namespace int 14 = categories
page_title str name of page, not including namespace prefix
page_restrictions flags
page_counter int possibly number of edits?
page_is_redirect flag includes #redirect
page_is_new flag
page_random float used for "Random page"
page_touched date/time when page last saved?
page_latest
page_len

pagelinks

pl_from int
pl_namespace int index to hard-coded namespaces array
pl_title string name of target page?

revision

rev_id int local key
rev_page int foreign key from [page]
rev_text_id int foreign key to [text]

text

Contains the (unparsed) page contents for all revisions

old_id int local key