Skip to content

Commit

Permalink
mOved custom code to bika.extras
Browse files Browse the repository at this point in the history
  • Loading branch information
Lunga001 committed Sep 13, 2023
1 parent caae25c commit a5d5cc0
Showing 1 changed file with 5 additions and 20 deletions.
25 changes: 5 additions & 20 deletions src/bika/lims/controlpanel/bika_instruments.py
Original file line number Diff line number Diff line change
Expand Up @@ -87,18 +87,14 @@ def __init__(self, context, request):
"title": _("Expiry Date"),
"sortable": False,
"toggle": True}),
("WeeksToExpire", {
"title": _("Weeks To Expire"),
"sortable": False,
"toggle": False}),
("Methods", {
"title": _("Methods"),
"sortable": False,
"toggle": True}),
("ImportInterface", {
"title": _("Import Interface"),
"sortable": False,
"toggle": True}),
("ExportInterface", {
"title": _("Export Interface"),
"sortable": False,
"toggle": True}),
))

self.review_states = [
Expand Down Expand Up @@ -186,18 +182,7 @@ def folderitem(self, obj, item, index):
css_class="link"),
methods)
item["replace"]["Methods"] = ", ".join(links)

import_interface = obj.getImportDataInterface()
import_interfaces_list = obj.getImportDataInterfacesList()
if len(import_interface) > 1:
for name in import_interface:
if name:
item["replace"]["ImportInterface"] = import_interfaces_list.getValue(name)

export_interfaces_list = obj.getExportDataInterfacesList()
export_interface = obj.DataInterface
if export_interface:
item["replace"]["ExportInterface"] = export_interfaces_list.getValue(export_interface)

return item


Expand Down

0 comments on commit a5d5cc0

Please sign in to comment.