def __init__(self, context, request): BikaListingView.__init__(self, context, request) self.show_sort_column = False self.show_select_row = False self.show_select_column = False self.show_workflow_action_buttons = False self.pagesize = 999999 self.icon = self.portal_url + "/++resource++bika.lims.images/%s_big.png" % \ context.portal_type.lower() self.title = to_utf8(self.context.Title()) + " " + t(_("Log")) self.description = "" self.columns = { 'Version': {'title': _('Version'), 'sortable': False}, 'Date': {'title': _('Date'), 'sortable': False}, 'User': {'title': _('User'), 'sortable': False}, 'Action': {'title': _('Action'), 'sortable': False}, 'Description': {'title': _('Description'), 'sortable': False}, } self.review_states = [ {'id': 'default', 'title': 'All', 'contentFilter': {}, 'columns': ['Version', 'Date', 'User', 'Action', 'Description']}, ]
def __init__(self, context, request, field): BikaListingView.__init__(self, context, request) self.selected = [o.UID() for o in getattr(field, field.accessor)()] self.context_actions = {} self.catalog = "bika_setup_catalog" self.contentFilter = {'review_state': 'impossible_state'} self.base_url = self.context.absolute_url() self.view_url = self.base_url self.show_categories = True self.show_sort_column = False self.show_select_row = False self.show_select_all_checkbox = False self.show_select_column = True self.pagesize = 999999 self.form_id = 'serviceswidget' self.columns = { 'Service': {'title': _('Service')}, 'Keyword': {'title': _('Keyword'), 'index': 'getKeyword'}, 'Method': {'title': _('Method')}, 'Calculation': {'title': _('Calculation')}, } self.review_states = [ {'id':'default', 'title': _('All'), 'contentFilter':{}, 'transitions': [], 'columns':['Service', 'Keyword', 'Method', 'Calculation', ] }, ]
def __init__(self, context, request): BikaListingView.__init__(self, context, request) self.show_sort_column = False self.show_select_row = False self.show_select_column = False self.show_workflow_action_buttons = False self.pagesize = 999999 self.icon = self.portal_url + "/++resource++bika.lims.images/%s_big.png" % \ context.portal_type.lower() self.title = to_utf8(self.context.Title()) + " " + t(_("Log")) self.description = "" self.columns = { 'Version': { 'title': _('Version'), 'sortable': False }, 'Date': { 'title': _('Date'), 'sortable': False }, 'User': { 'title': _('User'), 'sortable': False }, 'Action': { 'title': _('Action'), 'sortable': False }, 'Description': { 'title': _('Description'), 'sortable': False }, } self.review_states = [ { 'id': 'default', 'title': 'All', 'contentFilter': {}, 'columns': ['Version', 'Date', 'User', 'Action', 'Description'] }, ]
def __init__(self, context, request, field): BikaListingView.__init__(self, context, request) self.selected = [o.UID() for o in getattr(field, field.accessor)()] self.context_actions = {} self.catalog = "bika_setup_catalog" self.contentFilter = {'review_state': 'impossible_state'} self.base_url = self.context.absolute_url() self.view_url = self.base_url self.show_categories = True self.show_sort_column = False self.show_select_row = False self.show_select_all_checkbox = False self.show_select_column = True self.pagesize = 999999 self.form_id = 'serviceswidget' self.columns = { 'Service': { 'title': _('Service') }, 'Keyword': { 'title': _('Keyword'), 'index': 'getKeyword' }, 'Method': { 'title': _('Method') }, 'Calculation': { 'title': _('Calculation') }, } self.review_states = [ { 'id': 'default', 'title': _('All'), 'contentFilter': {}, 'transitions': [], 'columns': [ 'Service', 'Keyword', 'Method', 'Calculation', ] }, ]
def __init__(self, context, request, **kwargs): BikaListingView.__init__(self, context, request, **kwargs) self.form_id = "instrumentcertifications" self.columns = { 'Title': { 'title': _('Cert. Num'), 'index': 'sortable_title' }, 'getAgency': { 'title': _('Agency') }, 'getDate': { 'title': _('Date') }, 'getValidFrom': { 'title': _('Valid from') }, 'getValidTo': { 'title': _('Valid to') }, 'getDocument': { 'title': _('Document') }, } self.review_states = [ { 'id': 'default', 'title': _('All'), 'contentFilter': {}, 'columns': [ 'Title', 'getAgency', 'getDate', 'getValidFrom', 'getValidTo', 'getDocument' ], 'transitions': [{}] }, ] self.allow_edit = False self.show_select_column = False self.show_workflow_action_buttons = False uids = [c.UID() for c in self.context.getCertifications()] self.catalog = 'portal_catalog' self.contentFilter = {'UID': uids, 'sort_on': 'sortable_title'}
def __init__(self, context, request, fieldvalue, allow_edit): BikaListingView.__init__(self, context, request) self.context_actions = {} self.contentFilter = {'review_state' : 'impossible_state'} self.context_actions = {} self.base_url = self.context.absolute_url() self.view_url = self.base_url self.show_sort_column = False self.show_select_row = False self.show_select_all_checkbox = False self.show_select_column = False self.pagesize = 999999 self.allow_edit = allow_edit self.show_categories = True # self.expand_all_categories = False self.specsresults = {} for specresults in fieldvalue: self.specsresults[specresults['keyword']] = specresults self.columns = { 'service': {'title': _('Service'), 'index': 'sortable_title', 'sortable': False}, 'min': {'title': _('Min'), 'sortable': False,}, 'max': {'title': _('Max'), 'sortable': False,}, 'error': {'title': _('Permitted Error %'), 'sortable': False}, 'hidemin': {'title': _('< Min'), 'sortable': False}, 'hidemax': {'title': _('> Max'), 'sortable': False}, 'rangecomment': {'title': _('Range comment'), 'sortable': False, 'toggle': False} } self.review_states = [ {'id':'default', 'title': _('All'), 'contentFilter':{}, 'transitions': [], 'columns': ['service', 'min', 'max', 'error', 'hidemin', 'hidemax', 'rangecomment'], }, ]
def __init__(self, context, request, fieldvalue, allow_edit): BikaListingView.__init__(self, context, request) self.context_actions = {} self.contentFilter = {'review_state': 'impossible_state'} self.base_url = self.context.absolute_url() self.view_url = self.base_url self.show_sort_column = False self.show_select_row = False self.show_select_all_checkbox = False self.show_select_column = False self.pagesize = 999999 self.allow_edit = allow_edit self.show_categories = True # self.expand_all_categories = False self.referenceresults = {} # we want current field value as a dict # key:uid, value:{dictionary from field list of dict} for refres in fieldvalue: self.referenceresults[refres['uid']] = refres self.columns = { 'service': {'title': _('Service')}, 'result': {'title': _('Expected Result')}, 'error': {'title': _('Permitted Error %')}, 'min': {'title': _('Min')}, 'max': {'title': _('Max')} } self.review_states = [ {'id': 'default', 'title': _('All'), 'contentFilter': {}, 'transitions': [], 'columns': ['service', 'result', 'error', 'min', 'max'], }, ]