<commit_before>class ApplicationHelper::Button::CloudVolumeNew < ApplicationHelper::Button::Basic
  def calculate_properties
    super
    if disabled?
      self[:title] = _("No cloud providers support creating cloud volumes.")
    end
  end

  def disabled?
    ems_clouds = EmsCloud.all
    # if any connected provider supports this action,
    # we can enable the button.
    ems_clouds.each do |ems|
      return false if CloudVolume.class_by_ems(ems).supports_create_volume?
    end
    true
  end
end
<commit_msg>Indicate that Openstack Cloud Volume model supports create. (transferred from ManageIQ/manageiq@acb8ddd3b0e673cb568b1de70ec574401b105265)<commit_after>class ApplicationHelper::Button::CloudVolumeNew < ApplicationHelper::Button::Basic
  def calculate_properties
    super
    if disabled?
      self[:title] = _("No cloud providers support creating cloud volumes.")
    end
  end

  def disabled?
    ems_clouds = EmsCloud.all
    # if any connected provider supports this action,
    # we can enable the button.
    ems_clouds.each do |ems|
      return false if CloudVolume.class_by_ems(ems).supports_create?
    end
    true
  end
end

{'fraction_non_alphanumeric': 0.0682800345721694, 'fraction_numerical': 0.020743301642178046, 'mean_word_length': 3.8451882845188283, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1886545', 'n_tokens_mistral': 354, 'n_tokens_neox': 332, 'n_words': 100}