<commit_before>class Programme < Publication
  embeds_many :editions, :class_name => 'ProgrammeEdition', :inverse_of => :programme

  DEFAULT_PARTS = [
	{:title => "Overview", :slug => "overview"},
	{:title => "Rates", :slug => "rates"},
	{:title => "Who is elegible?", :slug => "who-is-eligible"},
	{:title => "How to claim", :slug => "how-to-claim"},
	{:title => "Further information", :slug => "further-information"},
  ]

  def self.edition_class
    ProgrammeEdition
  end

  def create_first_edition
    unless self.persisted? or self.editions.any?
      self.editions << self.class.edition_class.new(:title => self.name)
     DEFAULT_PARTS.each { |part|
        self.editions.first.parts.build(:title => part[:title],:slug => part[:slug], :body => " ")
      }
      calculate_statuses
    end
  end
end<commit_msg>updated the model for parts names of programmes<commit_after>class Programme < Publication
  embeds_many :editions, :class_name => 'ProgrammeEdition', :inverse_of => :programme

  DEFAULT_PARTS = [
	{:title => "Overview", :slug => "overview"},
	{:title => "What you'll get", :slug => "what-youll-get"},
	{:title => "Eligibility", :slug => "eligibility"},
	{:title => "How to claim", :slug => "how-to-claim"},
	{:title => "Further information", :slug => "further-information"},
  ]

  def self.edition_class
    ProgrammeEdition
  end

  def create_first_edition
    unless self.persisted? or self.editions.any?
      self.editions << self.class.edition_class.new(:title => self.name)
     DEFAULT_PARTS.each { |part|
        self.editions.first.parts.build(:title => part[:title],:slug => part[:slug], :body => " ")
      }
      calculate_statuses
    end
  end
end
{'fraction_non_alphanumeric': 0.16943127962085308, 'fraction_numerical': 0.0, 'mean_word_length': 3.9676470588235295, 'pattern_counts': {'":': 0, '<': 9, '<?xml version=': 0, '>': 35, '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': '4856433', 'n_tokens_mistral': 581, 'n_tokens_neox': 568, 'n_words': 122}