本文整理汇总了Python中bika.lims.content.bikaschema.BikaFolderSchema.copy方法的典型用法代码示例。如果您正苦于以下问题:Python BikaFolderSchema.copy方法的具体用法?Python BikaFolderSchema.copy怎么用?Python BikaFolderSchema.copy使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类bika.lims.content.bikaschema.BikaFolderSchema
的用法示例。
在下文中一共展示了BikaFolderSchema.copy方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: ManagedSchema
# 需要导入模块: from bika.lims.content.bikaschema import BikaFolderSchema [as 别名]
# 或者: from bika.lims.content.bikaschema.BikaFolderSchema import copy [as 别名]
from AccessControl import ClassSecurityInfo
from Products.ATExtensions.ateapi import RecordWidget
from Products.Archetypes.public import *
from bika.lims.config import PROJECTNAME
from Products.CMFCore import permissions as CMFCorePermissions
from Products.CMFCore.utils import getToolByName
from Products.CMFPlone.utils import safe_unicode
from bika.lims.content.bikaschema import BikaSchema, BikaFolderSchema
from archetypes.referencebrowserwidget import ReferenceBrowserWidget
from plone.app.folder.folder import ATFolder
from bika.lims.browser.fields import AddressField
from bika.lims.browser.widgets import AddressWidget
from bika.lims import PMF, bikaMessageFactory as _
schema = BikaFolderSchema.copy() + BikaSchema.copy() + ManagedSchema((
StringField('Name',
required = 1,
searchable = True,
validators = ('uniquefieldvalidator',),
widget = StringWidget(
label=_("Name"),
),
),
StringField('TaxNumber',
widget = StringWidget(
label=_("VAT number"),
),
),
StringField('Phone',
widget = StringWidget(
示例2: Schema
# 需要导入模块: from bika.lims.content.bikaschema import BikaFolderSchema [as 别名]
# 或者: from bika.lims.content.bikaschema.BikaFolderSchema import copy [as 别名]
from bika.lims import bikaMessageFactory as _
from bika.lims.utils import t
from bika.lims.browser.fields import HistoryAwareReferenceField
from bika.lims.browser.widgets import DateTimeWidget
from bika.lims.browser.widgets import RecordsWidget
from bika.lims.config import PROJECTNAME
from bika.lims.content.bikaschema import BikaSchema, BikaFolderSchema
from bika.lims.interfaces import IInstrument
from bika.lims.utils import to_utf8
from plone.app.folder.folder import ATFolder
from zope.interface import implements
from datetime import date
from DateTime import DateTime
from bika.lims.config import QCANALYSIS_TYPES
schema = BikaFolderSchema.copy() + BikaSchema.copy() + Schema((
ReferenceField('InstrumentType',
vocabulary='getInstrumentTypes',
allowed_types=('InstrumentType',),
relationship='InstrumentInstrumentType',
required=1,
widget=SelectionWidget(
format='select',
label=_("Instrument type"),
),
),
ReferenceField('Manufacturer',
vocabulary='getManufacturers',
allowed_types=('Manufacturer',),
示例3: Schema
# 需要导入模块: from bika.lims.content.bikaschema import BikaFolderSchema [as 别名]
# 或者: from bika.lims.content.bikaschema.BikaFolderSchema import copy [as 别名]
from bika.lims.utils import t
from bika.lims.browser.fields import HistoryAwareReferenceField
from bika.lims.browser.widgets import DateTimeWidget
from bika.lims.browser.widgets import RecordsWidget
from bika.lims.config import PROJECTNAME
from bika.lims.content.bikaschema import BikaSchema, BikaFolderSchema
from bika.lims.interfaces import IInstrument
from bika.lims.utils import to_utf8
from plone.app.folder.folder import ATFolder
from zope.interface import implements
from datetime import date
from DateTime import DateTime
from bika.lims.config import QCANALYSIS_TYPES
schema = (
BikaFolderSchema.copy()
+ BikaSchema.copy()
+ Schema(
(
ReferenceField(
"InstrumentType",
vocabulary="getInstrumentTypes",
allowed_types=("InstrumentType",),
relationship="InstrumentInstrumentType",
required=1,
widget=SelectionWidget(
format="select", label=_("Instrument type"), visible={"view": "invisible", "edit": "visible"}
),
),
ReferenceField(
"Manufacturer",