[BlueBream] Example for ZODB nested content object?
Paul Harouff
pharouff at gmail.com
Thu Mar 4 11:50:00 EST 2010
The primary reason I want to use BlueBream instead of Microsoft
Access, is so I can use the object oriented database to store nested
content. I could kludge up something in Access (perhaps quicker), but
I would prefer the flexibility and power of an object oriented
environment.
The BlueBream tutorial has an example for creating a simple form class
with two fields, name and description. I'm looking for something much
more complicated, like a huge python dictionary object.
Does anyone have a simple example of using ZODB to store nested
content? I've pasted in a preliminary outline for my object structure
below to give you an idea of what I'm trying to do. This is still very
much a work in progress. My goal is to use a common module structure
very similar to ASD S1000D, but be able to export the XML content
transformed for ASD S1000D, ADL SCORM, MIL-DTL-24784 (Navy),
MIL-STD-38784 (AF), or MIL-STD-40051 (Army), depending on each
customer's requirements.
My primary need is to present a "simple" form for each data module to
the author to enter his content, without worrying about XML tags.
Perhaps a tabbed interface to simplify the presentation of the many
different fields will help.
My second need is, as the data modules are being created, presenting
the ZODB objects in a browseable tree for selecting the data modules
editing them or assembling them into documents. Something like:
tmpub (object root for publication module)
Cover Page (web page 1)
Table of Contents (web page 2)
Table of Figures (web page 3)
Table of Tables (web page 4)
Acronyms (web page 5)
Chapter 1 Introduction
Section 1.1 Scope
tmdata DMC-xxxx (web page 6)
Section 1.2 Purpose
tmdata DMC-xxxx (web page 7)
Section 1.3 How to Use This Document
tmdata DMC-xxxx (web page 8 - also called by pressing
F1 or Help from the menu)
Chapter 2 Procedures
Section 2.1 Startup
Para 2.1.1 Tools
tmdata DMC-xxxx (web page 9)
Para 2.1.2 Checklist
tmdata DMC-xxxx (web page 10)
Section 2.2 Operation
Para 2.2.1 Tools
tmdata DMC-xxxx (web page 11)
Para 2.2.2 Checklist
tmdata DMC-xxxx (web page 12)
I see websites with tree navigation in the left frame (like the Zope2
Manager page), but I don't see a pluggable module or sample code
anywhere explaining how to do this.
My third need is to be able to export all of the completed content to
CDROM in XML files suitable for the customer's interactive web
application (on of the standards listed above).
My fourth need is to create our own custom BlueBream/Zope web
application (preferably launching from CDROM on a laptop using user's
temp folder for persistent session info) to test the interactive
content and possibly provide as a product for customers who do not
have their own web application, or are happy with delivery in
"contractor format".
Finally, in the future I want to be able to expand this database
structure to create an entire object tree where every product
assembly/part is linked to its drawing objects, logistics data
objects, tech manual objects, and training course objects. This is
where I believe using the ZODB object oriented database will assist me
better than a relational database like Access. So, I want to make sure
the framework I set up now for the tech manuals doesn't constrain me
from adding the other content in the future.
I would appreciate any advice you may have for the best/easiest way to
approach this.
Thanks,
Paul A. Harouff, P.E.
==================================
PART 1: Author creates new dmodule object and fills in identAndStatusSection
attributes. This provides required information to identify and reference the
new object. This part has very little flexibility.
tmdata (object root for data module)
id (= "DMC-" + dmCode properly formatted with the required dashes
for this example)
type (= "dmodule" for this example)
identAndStatusSection
dmIdent
dmCode
modelIdentCode (2 - 14 chars)
systemDiffCode (1 - 4 chars)
systemCode (2 - 3 chars)
subSystemCode (1 char)
subSubSystemCode (1 char)
assyCode (2 - 4 chars)
disassyCode (2 chars)
disassyCodeVariant (1 - 3 chars)
infoCode (3 chars)
infoCodeVariant (1 char)
itemLocationCode (1 char)
learnCode (3 chars - Optional)
learnEventCode (1 char - required if learnCode is present)
dmTitle
techName (= nomenclature for assyCode/disassyCode)
infoName (= nomenclature for infoCode)
learnName (= nomenclature for learnCode)
issueInfo
issueNumber
inWork
issueDate
year
month
day
language
countryIsoCode
languageIsoCode
dmStatus
issueType
security
securityClassification
commercialClassification
caveat
dataRestrictions
restrictionInstructions
dataDistribution
exportControl
exportRegistrationStmt
dataHandling
dataDestruction
dataDisclosure
restrictionInfo
copyright
copyrightPara
policyStatement
dataConds
responsiblePartnerCompany
enterpriseCode
enterpriseName
originator
enterpriseCode
enterpriseName
applicCrossRefTableRef
dmRef
xlink:type
xlink:actuate
xlink:show
xlink:href
dmRefIdent
dmCode
modelIdentCode
systemDiffCode
systemCode
subSystemCode
subSubSystemCode
assyCode
disassyCode
disassyCodeVariant
infoCode
infoCodeVariant
itemLocationCode
applic
displayText
SimplePara
evaluate
andOr
assert
applicPropertyIdent
applicPropertyType
applicPropertyValues
andOr
assert
applicPropertyIdent
applicPropertyType
applicPropertyValues
referencedApplicGroup
applic
id
displayText
simplePara
evaluate
andOr
assert
applicPropertyIdent
applicPropertyType
applicPropertyValues
techStandard
authorityInfoAndTp
authorityInfo
techPubBase
authorityExceptions
authorityNotes
brexDmRef
dmRef
xlink:type
xlink:actuate
xlink:show
xlink:href
dmRefIdent
dmCode
modelIdentCode
systemDiffCode
systemCode
subSystemCode
subSubSystemCode
assyCode
disassyCode
disassyCodeVariant
infoCode
infoCodeVariant
itemLocationCode
issueInfo
issueNumber
inWork
qualityAssurance
firstVerification
verificationType
systemBreakdownCode
skillLevel
skillLevelCode
reasonForUpdate
simplePara
content
PART 2: Author chooses the appropriate template for the content section.
This part must be very flexible and dynamic to adapt to the author's needs.
EXAMPLE CONTENT TEMPLATE FOR sysCode = x05, infoCode = 043
maintPlanning
timeLimitInfo
timeLimitIdent
applicRefId
equipGroup
equip
name
identNumber
manufacturerCode
partAndSerialNumber
partNumber
serialNumber
reqQuantity
unitOfMeasure
timeLimit
limitType
limitUnitType
threshold
thresholdUnitOfMeasure
thresholdValue
tolerance
toleranceLow
tolderanceHigh
timeLimit
limitType
limitUnitType
threshold
thresholdUnitOfMeasure
thresholdValue
EXAMPLE CONTENT TEMPLATE FOR sysCode = x00, infoCode = 131
crew
crewRefCard
title
crewDrill
title
subCrewDrill
title
crewDrillStep
challengeAndResponse
challenge
para
response
para
crewDrillStep
challengeAndResponse
challenge
para
response
para
subCrewDrill
title
crewDrillStep
challengeAndResponse
challenge
para
response
para
crewDrillStep
challengeAndResponse
challenge
para
response
table
tgroup
colspec
column
colname
colwidth
colspec
column
colname
colwidth
thead
row
entry
colname
para
tbody
row
entry
colname
para
row
entry
colname
para
crewDrill
title
warning
warningAndCautionPara
if
caseCond
crewDrillStep
crewProcedureName
para
elseif
caseCond
crewDrillStep
crewProcedureName
para
if
caseCond
crewDrillStep
crewProcedureName
para
crewDrill
title
crewDrillStep
challengeAndResponse
challenge
para
response
para
captionGroup
cols
applicRefId
colspec
colnum
colname
colwidth
colspec
colnum
colname
colwidth
captionBody
captionRow
captionEntry
colname
caption
color
captionWidth
captionLine
captionEntry
colname
caption
color
captionWidth
captionLine
captionRow
captionEntry
colname
caption
color
captionWidth
captionLine
captionEntry
colname
caption
color
captionWidth
captionLine
captionGroup
cols
applicRefId
colspec
colnum
colname
colwidth
colspec
colnum
colname
colwidth
captionBody
captionRow
captionEntry
colname
caption
color
captionWidth
captionLine
captionEntry
colname
caption
color
captionWidth
captionLine
More information about the bluebream
mailing list