code: def isVisible(self, instance, mode='view', default=None, field=None):
          
          vis = super(RejectionWidget, self).isVisible(
              instance=instance, mode=mode, default=default, field=field)
          if instance.bika_setup.isRejectionWorkflowEnabled():
              return vis
          else:
              return 'invisible'
docs: This function returns the visibility of the widget depending on whether
          the rejection workflow is enabled or not.