<!DOCTYPE html>

    <meta content='text/html; charset=UTF-8' http-equiv='Content-Type' />

Welcome to example.com, <%= @user.first_name %>

      You have successfully signed up to code-laborate.herokuapp.com,
      your username is: <%= @user.email %>.

      To login to the site, just follow this link: <%= @url %>.

Thanks for joining and have a great day!

<!DOCTYPE html>

    <meta content='text/html; charset=UTF-8' http-equiv='Content-Type' />

Welcome to Code-Laborate,
      <%if @user.org_affiliate %>
       <%= @user.first_name %>

I am an organization

      <% else %>
       <%= @user.first_name %>
      <% end %>

      You have successfully signed up to code-laborate.herokuapp.com,
      your username is: <%= @user.email %>.

      To login to the site, just follow this link: <%= @url %>.

Thanks for joining and have a great day!

 Code-Laborate Team

Change welcome email to send different info pending which type of user


	<% if user_signed_in? %>
		Signed in as <%= link_to(current_user, user_profile_path(current_user.username), :style => "color: #eee;", :onclick => "Router.navigate(currentUser.url(),true); return false;") %> <%= link_to("(sign out)", destroy_user_session_path, :style => "color: #ddd;") %>
	<% else %>
		<%= link_to("Sign in", new_user_session_path, :style => "color: #eee;") %> or <%= link_to("register", new_user_registration_path, :style => "color: #eee;") %>
	<% end %>

	<% if user_signed_in? %>
		Signed in as <%= link_to(current_user, user_profile_path(current_user.username), :style => "color: #eee;") %> <%= link_to("(sign out)", destroy_user_session_path, :style => "color: #ddd;") %>
	<% else %>
		<%= link_to("Sign in", new_user_session_path, :style => "color: #eee;") %> or <%= link_to("register", new_user_registration_path, :style => "color: #eee;") %>
	<% end %>

Revert "Added small backbone hack to make sure clicking the currentUser goes to the currentUser with backbone"

This reverts commit cdf236141c30d611f0a6c236bbec7c94b432ab7f.


Dear <%= @recipients_list %>

<% if @submission.revision_number == 0 %>
This is a reminder that an initial decision regarding "<%= @submission.title %>" is now overdue. Please decide whether it should be sent out for external review or, if not, enter your decision.
<% else %>
This is a reminder to secure referees for the revised and resubmitted manuscript "<%= @submission.title %>". Policy requires at least one report from an external referee. Ideally, all and only referees who recommended revisions of the previous version would be consulted about this revised version.

From the Editor's Guide: "The area editor must secure at least one external review, preferably from the same external reviewer(s) who recommended revisions (though not from reviewers who recommended acceptance or rejection). The area editor must also read the resubmission, and can only decide to accept or reject."
<% end %>

<% if @submission.area_editor %>
You can access the submission here: <%= one_click_edit_url(@submission.auth_token) %>

<% end %>
For a refresher on journal policies and practices, the Editor's Guide is here: <%= guide_url %>

<%= render 'email_footer' %>

Dear <%= @recipients_list %>,

<% if @submission.revision_number == 0 %>
This is a reminder that an initial decision regarding "<%= @submission.title %>" is now overdue. Please decide whether it should be sent out for external review or, if not, enter your decision.
<% else %>
This is a reminder to secure referees for the revised and resubmitted manuscript "<%= @submission.title %>". Policy requires at least one report from an external referee. Ideally, all and only referees who recommended revisions of the previous version would be consulted about this revised version.

From the Editor's Guide: "The area editor must secure at least one external review, preferably from the same external reviewer(s) who recommended revisions (though not from reviewers who recommended acceptance or rejection). The area editor must also read the resubmission, and can only decide to accept or reject."
<% end %>

<% if @submission.area_editor %>
You can access the submission here: <%= one_click_edit_url(@submission.auth_token) %>

<% end %>
For a refresher on journal policies and practices, the Editor's Guide is here: <%= guide_url %>

<%= render 'email_footer' %>

Fix typo in reminder to area editors (missing comma).


Хотите задать вопрос?

<%= button_to 'Ask a Question', new_question_path, method: :get, class: "btn btn-primary" %>

Хотите написать пост?

        <%= button_to 'Sign in', new_user_session_path, method: :get, class: "btn btn-primary" %>
        <%= button_to 'Sign up', new_user_registration_path, method: :get, class: "btn btn-primary" %>

Хотите задать вопрос?

<%= button_to 'Ask a Question', new_question_path, method: :get, class: "btn btn-primary" %>

Хотите написать пост?

      <% if user_signed_in? %>
        <%= button_to 'Write an Article', new_article_path, method: :get, class: "btn btn-primary" %>
      <% else %>

          <%= button_to 'Sign in', new_user_session_path, method: :get, class: "btn btn-primary" %>
          <%= button_to 'Sign up', new_user_registration_path, method: :get, class: "btn btn-primary" %>

      <% end %>

Add button "Write an article" for logged in user to Home page


 hello, <%= @user.first_name %>

YO' PUBLISHED POSTS:

   <% @user.all_published.each do |story| %>

<%= story.title %>

    <% end %>

YO' UNPUBLISHED POSTS:

   <% @user.all_unpublished.each do |story| %>

<%= story.title %>

    <% end %>

Add published and unpublished stories to user show


<%= notice %>

  Body:
  <%= @question.body %>

  Name:
  <%= @question.name %>

  Email:
  <%= @question.email %>

<%= link_to 'Edit', edit_question_path(@question) %> |
<%= link_to 'Back', questions_path %>

<%= notice %>

  Body:
  <%= @question.body %>

  Name:
  <%= @question.name %>

  Email:
  <%= @question.email %>

<fb:like href="<%= url_for question_path(@question, host: 'example.com', port: nil, only_path: false) %>" show_faces="false" send="false" layout="button_count" width="90"></fb:like>

<%= link_to 'Edit', edit_question_path(@question) %> |
<%= link_to 'Back', questions_path %>

Add fb like button to question show view.


  | Name | Type | Description | Example |
  | ------- | ------- | ------- | ------- |
  <%- extract_attributes(schema, params).each do |(key, type, description, example)| %>
  | **<%= key %>** | *<%= type %>* | <%= description %> | <%= example %> |
  <%- end %>

Remove additional spaces from link properties markdown

Github markdown can't draw table if there are spaces before first pipe symbol


<% page_title @document.title, "Consultation Response" %>

      <%= render partial: 'navigation', locals: { document: @document } %>
      <%= render partial: "rejected_by", locals: { document: @document } %>
      <%= render partial: 'document', locals: { document: @document } %>
      <% if @document.notes_to_editors.present? %>

Notes to editors

          <%= govspeak_to_html @document.notes_to_editors %>

      <% end %>

Consultation

      <%= content_tag_for :p, @document.consultation do %>
        This is a response to the consultation
        <%= link_to @document.consultation.title, admin_consultation_path(@document.consultation) %>
      <% end %>

  <%= render partial: 'fact_check_responses', locals: {document: @document} %>

Fix layout & style issues on admin consultation response show page.


<% if_p("rabbitmq-server.restart_statsdb_cron_schedule") do |schedule| %>
tmpfile=$(mktemp)
echo 'PATH=/usr/bin:/bin:/var/vcap/packages/erlang/bin:/var/vcap/packages/rabbitmq-server/bin' > "${tmpfile}"
echo '<%= schedule %> vcap /var/vcap/packages/rabbitmq-server/bin/rabbitmqctl eval "supervisor2:terminate_child(rabbit_mgmt_sup_sup, rabbit_mgmt_sup),rabbit_mgmt_sup_sup:start_child()."' >> "${tmpfile}"
cp "${tmpfile}" "/etc/cron.d/rabbitmq-statsdb-reset"
<% end %>

<% if_p("rabbitmq-server.restart_statsdb_cron_schedule") do |schedule| %>
cat << EOF > "/etc/cron.d/rabbitmq-statsdb-reset"

PATH=/usr/bin:/bin:/var/vcap/packages/erlang/bin:/var/vcap/packages/rabbitmq-server/bin
<%= schedule %> vcap rabbitmqctl eval "supervisor2:terminate_child(rabbit_mgmt_sup_sup, rabbit_mgmt_sup),rabbit_mgmt_sup_sup:start_child()."

EOF
<% end %>

Refactor of generation of cronfile

Refactor of generation of cronfile

Use cat << EOF pattern instead of long echo

[#136577519]

Signed-off-by: Gareth Smith <97ec7f0e37ed298c6c7d61e7dba0820f215e55e4@pivotal.io>


<% text_for :title do %>
  You’ll need an electronic visa waiver (EVW) or a visa
<% end %>

<% govspeak_for :body do %>
  You must either apply for:

  + an [EVW](/get-electronic-visa-waiver) to stay for up to 6 months
  + a [Parent of Tier 4 child visa](/parent-of-a-child-at-school-visa)

  *[EVW]: electronic visa waiver
<% end %>

<% text_for :title do %>
  You’ll need an electronic visa waiver (EVW) or a visa
<% end %>

<% govspeak_for :body do %>
  You must either apply for:

  + an [EVW](/get-electronic-visa-waiver) to stay for up to 6 months
  + a [Parent of a Child Student visa](/parent-of-a-child-at-school-visa)

  *[EVW]: electronic visa waiver
<% end %>

Replace reference from 'Tier 4' to 'Parent of a Child Student' visa


  <%= render partial: 'posts/post_metadata', locals: { post: post } %>

<%= link_to post.title, post %>

<%= post.body %>

  <div id="post_<%= post.id %>_likes">
    <%= render partial: 'posts/likes', locals: { post: post } %>

Add post like button to post partial

Add post like button to post partial


Tools Index

Note: If the Resources toggle does not work, refresh the page! Or fork the repo and fix the bug! :)

<% @tools.each do |tool| %>

<%= link_to tool.name, tool_path(tool.id) %> | Resources <% if current_user %>| <%= link_to "Add Resource", new_tool_resource_path(tool.id), :class => 'btn-resources' %><% end %>

      <% tool.resources.each do |resource| %>

<%= link_to resource.name, tool_resource_path(tool, resource) %> | <a href="<%= resource.url %>" target="_blank"><%= resource.url %>

<%= resource.summary %>

      <% end %>

<% end %>

Fix fork repo link on tools index

Fix fork repo link on tools index


<%= render 'recipeCard' %>

This is the recommendation score: <%= @response[0]["recommendation_score"] %>

This is the Yummly Rating: <%= @response[0]["rating"] %>

This is the recommendation score, not sure what it does: <%= @response[0]["recommendation_score"] %>

This is the rating, that's from yummly I assume? <%= @response[0]["rating"] %>

<%#= link_to "Give me another recipe", user_try_path %>

<%= render 'recipeCard' %>

This is the recommendation score: <%= @response[0]["recommendation_score"] %>

This is the Yummly Rating: <%= @response[0]["rating"] %>

User ID is: <%= current_user.id %>

RecipeID is: <%= @response[0]["id"] %>

Add debugging tools for database

Add debugging tools for database


<%= label_tag :person_override_active, 'Speaker is not a person on inside government' %>
<%= check_box_tag :person_override_active, "1", edition.person_override? %>

  <%= form.label :role_appointment_id, 'Speaker' %>
  <%= form.select :role_appointment_id, options_from_collection_for_select(role_appointment_options, :first, :last, edition.role_appointment_id), { include_blank: true }, class: 'chzn-select', data: { placeholder: "Choose a speaker..." } %>

  <%= form.text_field :person_override, label_text: "Speaker" %>

  <%= form.label :role_appointment_id, 'Speaker' %>
  <%= form.select :role_appointment_id, options_from_collection_for_select(role_appointment_options, :first, :last, edition.role_appointment_id), { include_blank: true }, class: 'chzn-select', data: { placeholder: "Choose a speaker..." } %>

  <%= form.text_field :person_override, label_text: "Speaker" %>

<%= label_tag :person_override_active, nil, class: 'checkbox' do %>
  <%= check_box_tag :person_override_active, "1", edition.person_override? %> Speaker is not a person on inside government
<% end %>

Fix the alignment and ordering of the person_override_active

https://www.pivotaltracker.com/story/show/40773995


  Your Right to Know

Every citizen has the right to access information held by public bodies. By law, they have to respond.

<a href="<%= help_about_url %>">Find out more about the Official Information Act.

  Your Right to Know

Every citizen has the right to access information held by public bodies. By law, they have to respond.

<%= link_to "Find out more about the Official Information Act.", help_about_path %>

Use more idiomatic link_to helper

Use more idiomatic link_to helper


/* DO NOT EDIT: File is auto-generated */
package <%= enumeration.data_module.ee.data_type_package %>;

<%= description_javadoc_for(enumeration, "") %>@javax.annotation.Generated( "Domgen" )
@SuppressWarnings( { "UnusedDeclaration", "JavaDoc" } )
<% if enumeration.jaxb?
%>@javax.xml.bind.annotation.XmlType( name = "<%= enumeration.name %>Type"<%= namespace_annotation_parameter(enumeration.xml) %> )
@javax.xml.bind.annotation.XmlEnum( java.lang.String.class )<% end %>
public enum <%= enumeration.ee.name %>
  implements java.io.Serializable
{
  <%= enumeration.values.collect {|k| "#{k}" } .join(",\n  ") %>
}

/* DO NOT EDIT: File is auto-generated */
package <%= enumeration.data_module.ee.data_type_package %>;

<%= description_javadoc_for(enumeration, "") %>@javax.annotation.Generated( "Domgen" )
@SuppressWarnings( { "UnusedDeclaration", "JavaDoc" } )
<% if enumeration.jaxb?
%>@javax.xml.bind.annotation.XmlType( name = "<%= enumeration.name %>Type"<%= namespace_annotation_parameter(enumeration.xml) %> )
@javax.xml.bind.annotation.XmlEnum( java.lang.String.class )<% end %>
public enum <%= enumeration.ee.name %>
  implements java.io.Serializable
{
  <%= enumeration.values.collect {|k| "#{k}" } .join(",\n  ") %>;

<% if enumeration.jackson? -%>
<% if enumeration.textual_values? -%>
  @org.codehaus.jackson.annotate.JsonValue
  public String value()
  {
    return super.name();
  }

  @org.codehaus.jackson.annotate.JsonCreator
  public static <%= enumeration.ee.name %> fromValue( final String typeCode )
  {
    for( final <%= enumeration.ee.name %> c: <%= enumeration.ee.name %>.values() )
    {
      if( c.name().equals( typeCode ) )
      {
        return c;
      }
    }
    throw new IllegalArgumentException( "Invalid <%= enumeration.ee.name %> type code: " + typeCode );
}
<% else -%>
  @org.codehaus.jackson.annotate.JsonValue
  public int value()
  {
    return super.ordinal();
  }

  @org.codehaus.jackson.annotate.JsonCreator
  public static <%= enumeration.ee.name %> fromValue( final int typeCode )
  {
    for( final <%= enumeration.ee.name %> c: <%= enumeration.ee.name %>.values() )
    {
      if( c.ordinal() == typeCode )
      {
        return c;
      }
    }
    throw new IllegalArgumentException( "Invalid <%= enumeration.ee.name %> type code: " + typeCode );
}
<% end -%>
<% end -%>
}

Rework the way enumerations are serialized to json to match historic behaviour


/* DO NOT EDIT: File is auto-generated */
package <%= to_package(repository.jpa.qualified_abstract_entity_test_name) %>;

@java.lang.SuppressWarnings( { "UnusedDeclaration" } )
@javax.annotation.Generated( "Domgen" )
public abstract class <%= repository.jpa.abstract_entity_test_name %>
  extends org.realityforge.guiceyloops.server.AbstractServerTest
{
  @javax.annotation.Nonnull
  protected com.google.inject.Module getEntityModule()
  {
    return new <%= repository.jpa.qualified_persistent_test_module_name %>( true );
  }

  @java.lang.Override
  protected com.google.inject.Module[] getModules()
  {
    final java.util.ArrayList<com.google.inject.Module> modules = new java.util.ArrayList<>();
    java.util.Collections.addAll( modules, super.getModules() );
<% repository.jpa.extra_test_modules.each do |test_module| %>
    modules.add( new <%= test_module %>() );
<% end -%>
    modules.add( new <%= repository.jpa.qualified_ejb_module_name %>() );
    return modules.toArray( new com.google.inject.Module[ modules.size() ] );
  }
}

/* DO NOT EDIT: File is auto-generated */
package <%= to_package(repository.jpa.qualified_abstract_entity_test_name) %>;

@java.lang.SuppressWarnings( { "UnusedDeclaration" } )
@javax.annotation.Generated( "Domgen" )
public abstract class <%= repository.jpa.abstract_entity_test_name %>
  extends org.realityforge.guiceyloops.server.AbstractServerTest
{
  @javax.annotation.Nonnull
  protected com.google.inject.Module getEntityModule()
  {
    return new <%= repository.jpa.qualified_persistent_test_module_name %>( true );
  }

  @java.lang.Override
  protected com.google.inject.Module[] getModules()
  {
    final java.util.ArrayList<com.google.inject.Module> modules = new java.util.ArrayList<>();
    java.util.Collections.addAll( modules, super.getModules() );
<% repository.jpa.extra_test_modules.each do |test_module| %>
    modules.add( new <%= test_module %>() );
<% end -%>
    modules.add( new <%= repository.jpa.qualified_dao_module_name %>() );
    return modules.toArray( new com.google.inject.Module[ modules.size() ] );
  }
}

Fix code to reflect name change

Fix code to reflect name change


<%= render partial: 'spree/admin/shared/error_messages', locals: { target: @product } %>

<% content_for :page_title do %>
  <%= Spree.t(:new_image) %>
<% end %>

<%= form_for [:admin, @product, @image], html: { multipart: true } do |f| %>
  <fieldset data-hook="new_image">
    <%= render partial: 'form', locals: { f: f } %>

      <%= button Spree.t('actions.update'), 'save' %>
      <%= Spree.t(:or) %>
      <%= button_link_to Spree.t('actions.cancel'), admin_product_images_url(@product), icon: 'delete', id: 'cancel_link' %>

  </fieldset>
<% end %>

<%= javascript_include_tag 'spree/backend/images/new.js' %>

Remove reference to deleted file.

Remove reference to deleted file.


<%= @topic.subject %>

  <menu>
    <%= link_to "Reply to Topic", new_topic_post_path(@topic) %>
    <%= link_to "Delete", forum_topic_path(@forum, @topic), :method => :delete, :confirm => "Are you sure?" %>
  </menu>

    <%= render :partial => "forem/posts/post", :collection => @topic.posts %>

<%= @topic.subject %>

  <menu>
    <%= link_to "Back to Topics", forum_path(@forum) %>
    <%= link_to "Reply to Topic", new_topic_post_path(@topic) %>
    <%= link_to "Delete", forum_topic_path(@forum, @topic), :method => :delete, :confirm => "Are you sure?" %>
  </menu>

    <%= render :partial => "forem/posts/post", :collection => @topic.posts %>

[view] Add 'back to topics' link on a given topic show for a forum.


class <%= klass %> < ActiveRecord::Base
  include Statesman::Adapters::ActiveRecordTransition

<% unless rails_4? %>
  attr_accessible :to_state, :metadata, :sort_key
<% end %>
  belongs_to :<%= parent_name %><%= class_name_option %>, inverse_of: :<%= table_name %>
end

class <%= klass %> < ActiveRecord::Base
  include Statesman::Adapters::ActiveRecordTransition

<% unless rails_4? %>
  attr_accessible :to_state, :metadata, :sort_key
<% end %>
  belongs_to :<%= parent_name %><%= class_name_option %>, inverse_of: :<%= table_name %>

  after_destroy :update_most_recent

  private

  def update_most_recent
    last_transition = <%= parent_name %>.<%= table_name %>.order(:sort_key).last
    return unless last_transition.present?
    last_transition.update_column(:most_recent, true)
  end
end

Update most-recent after transition destroy


        <button type="button" class="close" data-dismiss="modal" aria-label="Close">
          ×</button>

<%= t :guide_finished, guide: guide.name %>

          <% if should_display_medal? @guide, Organization.current %>

<%= t :unlocked_medal_as_avatar %>

            <%= corollary_medal_for guide %>
          <% end %>

              <%= corollary_box guide %>

              <%= next_lesson_button guide %>

        <button type="button" class="close" data-dismiss="modal" aria-label="Close">
          ×</button>

<%= t :guide_finished, guide: guide.name %>

              <%= corollary_box guide %>

              <% if should_display_medal? @guide, Organization.current %>

<%= t :unlocked_medal_as_avatar %>

                <%= corollary_medal_for guide %>
              <% end %>

              <%= next_lesson_button guide %>

Move medal to bottom of guide corollary

Move medal to bottom of guide corollary


<% if scope.lookupvar('spark::historyserver_hostname') == @fqdn -%>
<% properties = scope.lookupvar('spark::_properties').select { |name,value| (name =~ /^spark\.history\./) and value != '::undef' } -%>
<% s = '' -%>
<% properties.keys.each do |p| -%>
<% s = s + ' -D' + p + '=' + scope.lookupvar('spark::_properties')[p]-%>
<% end -%>
<% end -%>
export SPARK_HISTORY_SERVER_LOG_DIR=hdfs:///user/spark/applicationHistory
export SPARK_HISTORY_OPTS="$SPARK_HISTORY_OPTS -Dspark.history.fs.logDirectory=${SPARK_HISTORY_SERVER_LOG_DIR}<%= s -%>"
export SPARK_CONF_DIR=/etc/spark/conf

<% if scope.lookupvar('spark::historyserver_hostname') == @fqdn -%>
<% properties = scope.lookupvar('spark::_properties').select { |name,value| (name =~ /^spark\.history\./) and value != '::undef' } -%>
<% s = '' -%>
<% properties.keys.each do |p| -%>
<% s = s + ' -D' + p + '=' + scope.lookupvar('spark::_properties')[p].to_s -%>
<% end -%>
<% end -%>
export SPARK_HISTORY_SERVER_LOG_DIR=hdfs:///user/spark/applicationHistory
export SPARK_HISTORY_OPTS="$SPARK_HISTORY_OPTS -Dspark.history.fs.logDirectory=${SPARK_HISTORY_SERVER_LOG_DIR}<%= s -%>"
export SPARK_CONF_DIR=/etc/spark/conf

Fix syntax error when using with master: needs convert explicitly to string when using in string operation.


<!DOCTYPE html>

    <meta http-equiv="Content-type" content="text/html; charset=utf-8" />
    <title><%= this_blog.blog_name %> – <%= controller.controller_name %></title>
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <meta http-equiv="imagetoolbar" content="no" />
    <%= javascript_include_tag 'publify_admin', async: Rails.env.production? %>
    <%= stylesheet_link_tag 'publify_admin' %>
    <%= csrf_meta_tags %>

    <%= render 'admin/shared/menu' %>

            <%= render 'shared/flash', flash: flash %>

          <% if content_for?(:page_heading) %>

              <%= yield :page_heading %>

          <% end %>
          <%= yield %>

            <%= link_to(this_blog.blog_name, this_blog.base_url) %> <%= t('.powered_by') %> Publify <%= h PublifyCore::VERSION %>

Remove unneeded wrapping elements from admin layout


Government response

<%= form_for @government_response, :url => admin_petition_government_response_path(petition), method: :put do |f| -%>
  <%= form_row :for => [f.object, :summary] do %>
    <%= f.label :summary, 'Summary quote', class: 'form-label' %>
    <%= error_messages_for_field f.object, :summary %>
    <%= f.text_area :summary, rows: 3, cols: 70, tabindex: increment, data: { maxlength: 200 }, class: 'form-control' %>

200 characters max

  <% end %>

  <%= form_row :for => [f.object, :details] do %>
    <%= f.label :details, 'Response in full', class: 'form-label' %>
    <%= error_messages_for_field f.object, :details %>
    <%= f.text_area :details, rows: 8, cols: 70, tabindex: increment, class: 'form-control' %>
  <% end %>

  <%= email_signatures_with_count_submit_button(f, petition) %>
<% end -%>

<%= javascript_include_tag 'character-counter' %>

Government response

<%= form_for @government_response, :url => admin_petition_government_response_path(petition), method: :put do |f| -%>
  <%= form_row :for => [f.object, :summary] do %>
    <%= f.label :summary, 'Summary quote', class: 'form-label' %>
    <%= error_messages_for_field f.object, :summary %>
    <%= f.text_area :summary, rows: 3, cols: 70, tabindex: increment, data: { max_length: 200 }, class: 'form-control' %>

200 characters max

  <% end %>

  <%= form_row :for => [f.object, :details] do %>
    <%= f.label :details, 'Response in full', class: 'form-label' %>
    <%= error_messages_for_field f.object, :details %>
    <%= f.text_area :details, rows: 8, cols: 70, tabindex: increment, class: 'form-control' %>
  <% end %>

  <%= email_signatures_with_count_submit_button(f, petition) %>
<% end -%>

<%= javascript_include_tag 'character-counter' %>

Fix character counter on response admin

Fix character counter on response admin

The selector in the character-counter.js is looking for textareas with
a data-max-length attribute and not a data-maxlength attribute.


    <%= render "admin/shared/budget_investment_search", url: management_budget_investments_path(@budget) %>

        <%= tag.h2 t("management.budget_investments.filters.unfeasible") if params[:unfeasible].present? %>
        <%= tag.h2 t("management.budget_investments.filters.heading", heading: @heading.name) if @heading.present? %>
        <% if params[:search].present? %>

            <%= page_entries_info @investments %>
            <%= t("management.budget_investments.search_results", count: @investments.size, search_term: params[:search]) %>

        <% end %>

      <% @investments.each do |investment| %>
        <%= render "/budgets/investments/investment",
          investment: investment,
          investment_ids: @investment_ids,
          ballot: @ballot %>
      <% end %>

      <%= paginate @investments %>

Increase investments width in management section

I'm not sure whether it now looks worse on extra large screens, but I'm
positive it looks much better on medium and large screens, particularly
when investments have images.


<% if model_object.survey_responses.size > 0 %>

Survey Results

Average Rating: <%= model_object.average_rating %>

Average Instructor Rating: <%= model_object.average_instructor_rating %>

Display Comments

			<% model_object.survey_responses.each do |survey_response| %>
				<% if !survey_response.comments.empty? %>

<%=h survey_response.comments %>

				<% end %>
			<% end %>

<% end %>

<% if model_object.survey_responses.size > 0 %>

Survey Results

Average Rating: <%= model_object.average_rating %>

Average Instructor Rating: <%= model_object.average_instructor_rating %>

<%= link_to_function "Display Comments", "javascript:Effect.BlindDown('comments');Effect.BlindUp('display-comments')" %>

			<% model_object.survey_responses.each do |survey_response| %>
				<% if !survey_response.comments.empty? %>

<%=h survey_response.comments %>

				<% end %>
			<% end %>

<% end %>

Fix for comments problem in Firefox. bugid: 4239


<% if @petition.is_a?(::Archived::Petition) %>
  <%= link_to 'Departments', admin_archived_petition_departments_path(@petition), class: 'petition-action-heading' %>
<% else %>
  <%= link_to 'Departments', admin_petition_departments_path(@petition), class: 'petition-action-heading' %>
<% end %>

<% if @petition.is_a?(::Archived::Petition) %>
  <%= link_to 'Departments', admin_archived_petition_departments_path(@petition), class: 'petition-action-heading' %>
<% elsif @petition.departments? %>
  <%= link_to 'Departments', admin_petition_departments_path(@petition), class: 'petition-action-heading present' %>
<% else %>
  <%= link_to 'Departments', admin_petition_departments_path(@petition), class: 'petition-action-heading' %>
<% end %>

Add presence indicator to departments too


#
# This file is managed by Puppet. Local edits will be lost.
#

server {
  listen         80;
  server_name    <%= @server_name %>;
  root           <%= @public_root %>;
  try_files      $uri @node;

  location @node {
    proxy_set_header X-Real-IP $remote_addr;
    proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
    proxy_set_header Host $http_host;
    proxy_set_header X-Nginx-Proxy true;

    proxy_pass       http://127.0.0.1:<%= @port %>;
    proxy_redirect   off;
  }
}

#
# This file is managed by Puppet. Local edits will be lost.
#

proxy_cache_path /tmp/nginx/<%= @app_name %> level=1:2 keys_zone=<%= @app_name %>:10m inactive=1d;

server {
  listen         80;
  server_name    <%= @server_name %>;
  root           <%= @public_root %>;
  try_files      $uri @node;

  location @node {
    proxy_cache_key    "$scheme$request_method$host$request_uri";
    proxy_cache        <%= @app_name %>;
    proxy_cache_bypass $http_cache_control;                  # respect Cache-Control=no-cache from the client
    add_header         X-Proxy-Cache $upstream_cache_status; # set HIT/MISS/BYPASS in response

    proxy_set_header   X-Real-IP $remote_addr;
    proxy_set_header   X-Forwarded-For $proxy_add_x_forwarded_for;
    proxy_set_header   Host $http_host;
    proxy_set_header   X-Nginx-Proxy true;

    # temporary hack
    auth_basic           "Restricted";
    auth_basic_user_file /opt/nginx/.htpasswd;

    proxy_pass         http://127.0.0.1:<%= @port %>;
    proxy_redirect     off;
  }
}

Add some HTTP caching to nginx-node-app-vhost


# -*- mode: ruby -*-
# vi: set ft=ruby :
Vagrant.configure("2") do |config|
  config.vm.box = "dummy"

  config.vm.provider :aws do |aws, override|
    aws.access_key_id = "<%= @provider_config.fetch("access_key") %>"
    aws.secret_access_key = "<%= @provider_config.fetch("secret_access_key") %>"
    aws.keypair_name = "<%= @provider_config.fetch("keypair_name") %>"

    # aws.ami = "ami-a81470c1"
    aws.ami = "<%= @provider_config.fetch("ami") %>"
    override.ssh.private_key_path = "<%= @provider_config.fetch("ssh_private_key_path") %>"
    override.ssh.username = "ubuntu"
  end

  config.vm.provision :puppet do |puppet|
    puppet.facter = {
      "role" => "ci",
      "operationsystem" => "debian",
      "vagrant_user" => "ubuntu",
      "vagrant_home" => "/home/ubuntu"
    }
    puppet.module_path = "<%= @puppet_path %>/modules"
    puppet.manifests_path = "<%= @puppet_path %>/manifests"
    puppet.manifest_file = "main.pp"
    <% if @options["verbose"] == true %>
    puppet.options = "--verbose --debug"
    <% end %>
  end
end

# -*- mode: ruby -*-
# vi: set ft=ruby :
Vagrant.configure("2") do |config|
  config.vm.box = "dummy"

  config.vm.provider :aws do |aws, override|
    aws.access_key_id = "<%= @provider_config.fetch("access_key") %>"
    aws.secret_access_key = "<%= @provider_config.fetch("secret_access_key") %>"
    aws.keypair_name = "<%= @provider_config.fetch("keypair_name") %>"

    # aws.ami = "ami-a81470c1"
    aws.ami = "<%= @provider_config.fetch("ami") %>"
    override.ssh.private_key_path = "<%= @provider_config.fetch("ssh_private_key_path") %>"
    override.ssh.username = "ubuntu"
  end

  config.vm.provision :puppet do |puppet|
    puppet.facter = {
      <% @project_config.puppet_facts.each do |k, v| %>
        "<%= k %>" => "<%= v %>",
      <% end %>
      "role" => "ci",
      "operationsystem" => "debian",
      "vagrant_user" => "ubuntu",
      "vagrant_home" => "/home/ubuntu"
    }
    puppet.module_path = "<%= @puppet_path %>/modules"
    puppet.manifests_path = "<%= @puppet_path %>/manifests"
    puppet.manifest_file = "main.pp"
    <% if @options["verbose"] == true %>
    puppet.options = "--verbose --debug"
    <% end %>
  end
end

Add puppet facts support to Aws provider.


  <%= link_to t("shared.advanced_search.title"), "#advanced_search_form", id: 'js-advanced-search-title', class: "advanced-search small" %>

  <%= form_tag search_path, id: "advanced_search_form", method: :get do %>
    <div id='js-advanced-search' data-advanced-search-terms=<%= @advanced_search_terms.present? %> style="display: none">

          <%= t("shared.advanced_search.general") %>

        <%= text_field_tag "search", params[:search],
                           placeholder: t("shared.advanced_search.general_placeholder") %>

      <%# Pas de official level dans CDJ Aude%>

          <%= t("shared.advanced_search.date") %>
          <%= select_tag('advanced_search[date_min]', date_range_options,
                        include_blank: t("shared.advanced_search.date_range_blank"),
                        id: 'js-advanced-search-date-min') %>

                <%= t("shared.advanced_search.from") %> (<%= t("shared.advanced_search.date_placeholder") %>)

              <%= text_field_tag 'advanced_search[date_min]',
                                  params[:advanced_search].try(:[], :date_min),
                                  class: 'js-calendar' %>

                <%= t("shared.advanced_search.to") %> (<%= t("shared.advanced_search.date_placeholder") %>)

              <%= text_field_tag 'advanced_search[date_max]',
                                  params[:advanced_search].try(:[], :date_max),
                                  class: 'js-calendar' %>

        <%= submit_tag t("shared.advanced_search.search"), class: 'button expanded' %>

  <% end %>

Remove official levels from search fields


<!DOCTYPE html>
<html>
<head>
  <title>DummyApp</title>
  <%= stylesheet_link_tag :all %>
  <%= javascript_include_tag :defaults %>
  <%= csrf_meta_tag %>
</head>
<body>

<%= yield %>

</body>
</html>

<!DOCTYPE html>
<html>
<head>
  <title>DummyApp</title>
  <%= stylesheet_link_tag :all %>
  <%= csrf_meta_tag %>
</head>
<body>

<%= yield %>

</body>
</html>

Remove linking of non-existing JS files in DummyApp's default layout (rendered in Devise specific views such as login and register)


<Directory <%= @images_dir %>>
  # Wrap rewrite rules in a location block so apache will apply aliases before
  # testing the RewriteCond
  RewriteEngine On
  RewriteBase <%= @images_url %>/

  # Call thumb.php for thumb images not on disk
  RewriteCond %{REQUEST_FILENAME} !-f
  RewriteCond %{REQUEST_FILENAME} !-d
  RewriteRule ^thumb/[0-9a-f]/[0-9a-f][0-9a-f]/([^/]+)/[^/]*([0-9]+)px-.*$ /w/thumb_handler.php [PT,QSA,B]

  # Call thumb.php for thumb archive images not on disk
  RewriteCond %{REQUEST_FILENAME} !-f
  RewriteCond %{REQUEST_FILENAME} !-d
  RewriteRule ^thumb/archive/[0-9a-f]/[0-9a-f][0-9a-f]/([^/]+)/[^/]*([0-9]+)px-.*$ /w/thumb_handler.php [PT,QSA,B]
</Directory>
# vim:sw=2:ts=2:sts=2:ft=apache:

<Directory <%= @images_dir %>>
  # Wrap rewrite rules in a location block so apache will apply aliases before
  # testing the RewriteCond
  RewriteEngine On
  RewriteBase <%= @images_url %>/

  # Call thumb_handler.php for thumb images not on disk
  RewriteCond %{REQUEST_FILENAME} !-f
  RewriteCond %{REQUEST_FILENAME} !-d
  RewriteRule ^thumb/[0-9a-f]/[0-9a-f][0-9a-f]/([^/]+)/[^/]*([0-9]+)px-.*$ /w/thumb_handler.php [PT,QSA,B]

  # Call thumb_handler.php for thumb archive images not on disk
  RewriteCond %{REQUEST_FILENAME} !-f
  RewriteCond %{REQUEST_FILENAME} !-d
  RewriteRule ^thumb/archive/[0-9a-f]/[0-9a-f][0-9a-f]/([^/]+)/[^/]*([0-9]+)px-.*$ /w/thumb_handler.php [PT,QSA,B]
</Directory>
# vim:sw=2:ts=2:sts=2:ft=apache:

Correct thumb.php -> thumb_handler.php comments

Change-Id: I93c097206d8a5fced028f7f2266a3de1149e69ab


<% content_for :title do %>
  Is the holiday entitlement based on:
<% end %>

<% options(
  "days-worked-per-week": "days worked per week",
  "hours-worked-per-week": "hours worked per week",
  "casual-or-irregular-hours": "casual or irregular hours",
  "annualised-hours": "annualised hours",
  "compressed-hours": "compressed hours",
  "shift-worker": "shifts"
) %>

<% content_for :hint do %>
  Check the employment contract if you’re not sure about the holiday entitlement.
<% end %>

<% content_for :title do %>
  Is the holiday entitlement based on:
<% end %>

<% options(
  "days-worked-per-week": "days worked per week",
  "hours-worked-per-week": "hours worked per week",
  "casual-or-irregular-hours": "casual or irregular hours",
  "annualised-hours": "annualised hours (hours worked per year)",
  "compressed-hours": "compressed hours (full-time hours over fewer days)",
  "shift-worker": "shifts"
) %>

<% content_for :hint do %>
  Check the employment contract if you’re not sure about the holiday entitlement.
<% end %>

Add text to holiday entitlement question

Plain English definitions have been requested by the content team


<% if user_signed_in? %>

<%= link_to "Place Order", new_order_path %>

      Account

<%= link_to "Account", profile_path(current_user) %>

<%= link_to "Edit Account", edit_user_registration_path %>

<%= link_to "Order History", orders_path %>

        <%= link_to "Log out", destroy_user_session_path, :method => :delete %>

<% else %>

<%= link_to "Log in", new_user_session_path %>

<%= link_to "Sign up", new_user_registration_path %>

<% end %>

<%# TODO: apply pundit %>

<% if user_signed_in? %>

      Services

      <% Service.all.each do |service| %>

<%= link_to service.service_name, service_path(service) %>

        <% if service != Service.last %>

        <% end %>
      <% end %>

<%= link_to "Place Order", new_account_order_path(current_user.account) %>

<%= link_to "Order History", account_orders_path(current_user.account) %>

      Account Settings

<%= link_to "Profile", account_path(current_user.account) %>

<%= link_to "Edit Profile", edit_account_path(current_user.account) %>

<%= link_to "Edit Account Settings", edit_user_registration_path %>

        <%= link_to "Log out", destroy_user_session_path, :method => :delete %>

<% else %>

<%= link_to "Log in", new_user_session_path %>

<%= link_to "Sign up", new_user_registration_path %>

<% end %>

Update links and add services

Update links and add services


  <%= render partial: "policies/policy_navigation" %>

Policy definition

    <%= link_to_with_current @policy.title, public_document_path(@policy, anchor: 'top') %>

  <% if (supporting_pages = @policy.supporting_pages).any? %>

Supporting detail

      <% supporting_pages.each do |supporting_page| %>
        <% options = supporting_page == @supporting_page ? {class: "active"} : {} %>
        <%= link_to_with_current(supporting_page.title,
              policy_supporting_page_path(@policy.document, supporting_page),
              options) %>
      <% end %>

  <% end %>

  <%= render partial: "policies/policy_navigation" %>

  <% if (supporting_pages = @policy.supporting_pages).any? %>

Supporting detail

      <% supporting_pages.each do |supporting_page| %>
        <% options = supporting_page == @supporting_page ? {class: "active"} : {} %>
        <%= link_to_with_current(supporting_page.title,
              policy_supporting_page_path(@policy.document, supporting_page),
              options) %>
      <% end %>

  <% end %>

Remove redundant link to policy.

Remove redundant link to policy.

This should've been removed in 550e3a68beba6f69daaa290ebf287c5e1fb70fa2
when I added the policy navigation partial to the template.


    <%= form_tag user_posts_path(current_user), method: :post do %>

Create a new post

                <%= label_tag :text, "Write a something: " %>
                <%= text_area_tag :text, nil, class: "materialize-textarea" %>

        <%= submit_tag "Create Post", class: "modal-action modal-close waves-effect waves-green btn-flat" %>
        Cancel

    <% end %>

Add color theme to inputs and labels forms


Support links

Help

Cookies

Contact

Cymraeg

Built by the Government Digital Service

Change GDS link in the footer

Change GDS link in the footer


    <% if publication.updated_at %>

Last updated: <%= publication.updated_at.to_formatted_s(:short_ordinal) %>

    <% end %>
    <% if [:programme].include? publication.type.to_sym %>

<%= link_to "Print this guide", publication_path(publication.slug, :part => 'print') %>

    <% end %>
    <% if [:guide].include? publication.type.to_sym %>

<%= link_to "Print this guide", publication_path(publication.slug, :part => 'print') %>

    <% end %>

<% if api_links.any? %>
<% content_for :extra_headers do %>
  <% api_links.each do |type, href| %>
<link rel="alternate" type="<%= type %>" href="<%= href %>">
  <% end %>
<% end %>
<% end %>

    <% if publication.updated_at %>

Last updated: <%= publication.updated_at.to_formatted_s(:short_ordinal) %>

    <% end %>
    <% if [:programme, :guide].include? publication.type.to_sym %>

<%= link_to "Print this guide", publication_path(publication.slug, :part => 'print') %>

    <% end %>

<% if api_links.any? %>
<% content_for :extra_headers do %>
  <% api_links.each do |type, href| %>
<link rel="alternate" type="<%= type %>" href="<%= href %>">
  <% end %>
<% end %>
<% end %>

Remove duplication in print links

Remove duplication in print links


<div id="in_tail_format"
  formatOptionsJson="<%= formats.to_json %>"
  initialSelected="<%= initialSelected %>"
  targetFile="<%= file %>"
  paramsJson="<%= params.to_json %>"
  >

{{{ highlightedLines }}}

    <%= raw t('fluentd.settings.in_tail_option_guide') %>

Add more prefix to be more unique

Add more prefix to be more unique


Home

Video

Pictures

Music

Blog

    >>carousel<<

    *tweet*

    *tweet*

facebook

vimeo

twitter

store

Home

Video

Pictures

Music

JUNE 21

    >>carousel<<

    *tweet*

    *tweet*

facebook

vimeo

twitter

store

Add links for list items.

Add links for list items.


(function() {
  var $page;

<% if @old_page_layout != @page.page_layout -%>
  Alchemy.ElementsWindow.reload();
  Alchemy.growl('<%= j Alchemy.t(:page_layout_changed_notice) %>');
<% end -%>

<% if @while_page_edit -%>

  Alchemy.reloadPreview();
  $('#page_<%= @page.id %>_status').replaceWith('<%= j render("page_status", page: @page) %>');

<% else -%>

  var page_html = "<%= j render('page', page: @page) %>";
  var compiler = Handlebars.compile(page_html);
  var tree = JSON.parse('<%== @tree.to_json %>');
  var html = compiler(tree.pages[0]);
  $('#page_<%= @page.id %>').replaceWith(html);
  $page = $('#page_<%= @page.id %>');

  <% if @page.locked? && @page.locker == current_alchemy_user -%>
    $('#locked_page_<%= @page.id %> > a').html('<%= @page.name %>');
  <% end -%>

  <% if @page.restricted? -%>
    $('.page_status:nth-child(3)', $page).addClass('restricted', 'not_restricted').removeClass('not_restricted');
  <% elsif @page.redirects_to_external? -%>
    $('span.redirect_url', $page).html('» <%= Alchemy.t("Redirects to") %>: <%= h @page.external_urlname %>');
  <% else -%>
    $('.page_status:nth-child(3)', $page).addClass('not_restricted').removeClass('restricted');
  <% end -%>

<% end -%>

  Alchemy.growl("<%= j @notice %>");
  Alchemy.closeCurrentDialog();
})()

(function() {
  var $page;

<% if @old_page_layout != @page.page_layout -%>
  Alchemy.ElementsWindow.reload();
  Alchemy.growl('<%= j Alchemy.t(:page_layout_changed_notice) %>');
<% end -%>

<% if @while_page_edit -%>

  Alchemy.reloadPreview();
  $('#page_<%= @page.id %>_status').replaceWith('<%= j render("current_page", current_page: @page) %>');

<% else -%>

  var page_html = "<%= j render('page', page: @page) %>";
  var compiler = Handlebars.compile(page_html);
  var tree = JSON.parse('<%== @tree.to_json %>');
  var html = compiler(tree.pages[0]);
  $('#page_<%= @page.id %>').replaceWith(html);

<% end -%>

  Alchemy.growl("<%= j @notice %>");
  Alchemy.closeCurrentDialog();
})()

Fix GUI update of page status

Fix GUI update of page status

1. In 9fb2fe58ad2caa2bb0d00a5f7e5331f77a4a15e5 we introduced a partial for page status, but forgot to properly replace the current page tab.

2. In 1a5b982a8563ec2ac28a6947dc834e656640969a we introduced to replace the current page in the sitemap with a compiled Handlebars template. Since the whole line gets replaced, we don't need to update each page status DOM element any more.


<%#
# Carrierwave Show Partial

This partial renders a summary of the current attachment(s)
for this attribute

## Local variables:

- `field`:
  An instance of Administrate::Field::Carrierwave.
  A wrapper around the attribute pulled from the database.
%>

<% if field.multiple? %>
  <% if field.files.any? %>

      <%- field.files.each do |file| %>

<%= render 'fields/carrierwave/file', file: file %>

      <% end %>

  <% else %>
    No file(s) uploaded yet
  <% end %>
<% else %>
  <% if field.image.present? && field.data.model.persisted? && field.file.version_exists?(field.image) %>
    <%= render 'fields/carrierwave/preview', file: field.file, field: field %>
  <% elsif field.file.present? %>
    <%= render 'fields/carrierwave/file', file: field.file %>
  <% else %>
      -
  <% end %>
<% end %>

<%#
# Carrierwave Show Partial

This partial renders a summary of the current attachment(s)
for this attribute

## Local variables:

- `field`:
  An instance of Administrate::Field::Carrierwave.
  A wrapper around the attribute pulled from the database.
%>

<% if field.multiple? %>
  <% if field.files.any? %>

      <%- field.files.each do |file| %>

<%= render 'fields/carrierwave/file', file: file %>

      <% end %>

  <% else %>
    No file(s) uploaded yet
  <% end %>
<% else %>
  <% if field.image.present? && field.data.model.persisted? && field.data.file.present? %>
    <%= render 'fields/carrierwave/preview', file: field.file, field: field %>
  <% elsif field.file.present? %>
    <%= render 'fields/carrierwave/file', file: field.file %>
  <% else %>
      -
  <% end %>
<% end %>

Fix the crash that happens when no uploaded image exists


<!DOCTYPE html>

Backbeat Activity Report

    <% if report[:inconsistent][:counts].empty? %>

No inconsistent workflows for this period

    <% else %>
      <%= render_table "Workflow Inconsistencies", report[:inconsistent][:counts] %>

Inconsistent workflow data stored at <%= report[:inconsistent][:filename] %> on <%= report[:inconsistent][:hostname] %>

    <% end %>

    <% if report[:completed][:counts].empty? %>

No completed workflows for this period

    <% else %>
      <%= render_table "Workflow Activity", report[:completed][:counts] %>
    <% end %>

Report finished in <%= report[:time_elapsed] %> seconds

Processing window: <%= report[:range][:lower_bound].to_s %> to <%= report[:range][:upper_bound].to_s %>

Set default font weight in activity report email


upstream baseball-ui {
  least_conn;
  {{range service "baseball-ui"}}server {{.Address}}:{{.Port}} max_fails=3 fail_timeout=60 weight=1;
  {{else}}server 127.0.0.1:65535; # force a 502{{end}}
}

server {
  listen 80;

  location / {
    proxy_pass http://baseball-ui;
    proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
    proxy_set_header Host $host;
    proxy_set_header X-Real-IP $remote_addr;
  }
}

upstream baseball-ui {
  least_conn;
  {{range service "baseball-ui-80"}}server {{.Address}}:{{.Port}} max_fails=3 fail_timeout=60 weight=1;
  {{else}}server 127.0.0.1:65535; # force a 502{{end}}
}

server {
  listen 80;

  location / {
    proxy_pass http://baseball-ui;
    proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
    proxy_set_header Host $host;
    proxy_set_header X-Real-IP $remote_addr;
  }
}

Fix service ref for baseball-ui-80

Fix service ref for baseball-ui-80


  <%= form_tag calculate_current_question_path(@presenter), :method => :get, :authenticity_token => false %>

        <%= @presenter.current_question_number %> <%= question.title %>

        <% if question.has_body? %>
          <%= question.body %>
        <% end %>

        <% if question.has_hint? %>

<%= question.hint %>

        <% end %>

        <div class="<%= @presenter.error && 'error' %>">
          <% if @presenter.error %>

              <%= @presenter.error %>

          <% end %>

          <%= render partial: question.partial_template_name, locals: { question: question } %>

        <button name="next" type="submit" class="medium button">Next step</button>

  </form>

  <%= form_tag calculate_current_question_path(@presenter), :method => :get %>

        <%= @presenter.current_question_number %> <%= question.title %>

        <% if question.has_body? %>
          <%= question.body %>
        <% end %>

        <% if question.has_hint? %>

<%= question.hint %>

        <% end %>

        <div class="<%= @presenter.error && 'error' %>">
          <% if @presenter.error %>

              <%= @presenter.error %>

          <% end %>

          <%= render partial: question.partial_template_name, locals: { question: question } %>

        <button name="next" type="submit" class="medium button">Next step</button>

  </form>

Remove authenticity token option from question form


<% content_for :head do %>
  <%= javascript_include_tag states_url %>
<% end %>

  <%= render :partial => 'spree/shared/error_messages', :locals => { :target => @order } %>

<%= t(:checkout) %>

<%= checkout_progress %>

    <div class="columns <%= if @order.state != 'confirm' then 'alpha twelve' else 'alpha omega sixteen' end %>" data-hook="checkout_form_wrapper">
      <%= form_for @order, :url => update_checkout_path(@order.state), :html => { :id => "checkout_form_#{@order.state}" } do |form| %>
        <%= render @order.state, :form => form %>
      <% end %>

    <% if @order.state != 'confirm' %>

        <%= render :partial => 'summary', :locals => { :order => @order } %>

    <% end %>

<% content_for :head do %>
  <%= javascript_include_tag states_url(:format => :js) %>
<% end %>

  <%= render :partial => 'spree/shared/error_messages', :locals => { :target => @order } %>

<%= t(:checkout) %>

<%= checkout_progress %>

    <div class="columns <%= if @order.state != 'confirm' then 'alpha twelve' else 'alpha omega sixteen' end %>" data-hook="checkout_form_wrapper">
      <%= form_for @order, :url => update_checkout_path(@order.state), :html => { :id => "checkout_form_#{@order.state}" } do |form| %>
        <%= render @order.state, :form => form %>
      <% end %>

    <% if @order.state != 'confirm' %>

        <%= render :partial => 'summary', :locals => { :order => @order } %>

    <% end %>

Add .js extension to request for States controller's javascript in spree/checkout/edit view

Fixes issue where some clients (or proxies) can cause Rails to infer the response type from the format of the URL rather than the Accept header (malformed headers?).  Since unqualified URLs default to HTML, the States controller issues a 406 Not Acceptable error since it can only respond to :js.

Fixes #1659


<div id="<%= result.clean_an %>" class="result-local-locations">

    <% if result.availability == 'available' %>

Available in <%= result.location[0] %>
        (<%= result.location[1] %>) <%= "and other locations" if
        result.other_availability %> -
        <%= link_to 'check options', full_record_link(result) %>

    <% elsif result.availability == 'check_holdings' %>

May be available in <%= result.location[0] %>
        (<%= result.location[1] %>) -
        <%= link_to 'check options', full_record_link(result) %>

    <% else %>

Not currently available in <%= result.location[0] %>
        (<%= result.location[1] %>) -
        <%= link_to 'check options', full_record_link(result) %>

    <% end %>

<div id="<%= result.clean_an %>" class="result-local-locations">

    <% if result.availability == 'available' %>

Available in <%= result.location[0] %>
        (<%= result.location[1] %>) <%= "and other locations" if
        result.other_availability %> -
        <%= link_to 'check request options', full_record_link(result) %>

    <% elsif result.availability == 'check_holdings' %>

May be available in <%= result.location[0] %>
        (<%= result.location[1] %>) -
        <%= link_to 'check request options', full_record_link(result) %>

    <% else %>

Not currently available in <%= result.location[0] %>
        (<%= result.location[1] %>) -
        <%= link_to 'check request options', full_record_link(result) %>

    <% end %>

Update request options link text

Update request options link text

Why these changes are being introduced:

Usability testing revealed that 'check options' does not clearly describe
the purpose of this link.

Relevant ticket(s):

https://mitlibraries.atlassian.net/browse/IMP-2199

How this addresses that need:

This changes the link text from 'check options' to 'check request options'.

Side effects of this change:

None


Adauth.configure do |c|
	# The Domain name of your Domain
	#
	# This is usually my_company.com or my_company.local
	#
	# If you don't know your domain contact your IT support,
	# it will be the DNS suffix applied to your machines
	c.domain = "example.com"

	# The IP address or Hostname of a DC (Domain Controller) on your network
	#
	# This could be anything and probably wont be 127.0.0.1
	#
	# Again contact your IT Support if you can't work this out
	c.server = "127.0.0.1"

	# The LDAP base of your domain/intended users
	#
	# For all users in your domain the base would be:
	# dc=example, dc=com
	# OUs can be prepeneded to restrict access to your app
	c.base = "dc=example, dc=com"

	# The port isn't always needed as Adauth defaults to 389 the LDAP Port
	#
	# If your DC is on the other side of a firewall you may need to change the port
	#c.port = 389

	# Windows Security groups to allow
	#
	# Only allow members of set windows security groups to login
	#
	# Takes an array for group names
	#c.allowed_groups = ["Group1", "Group2"]
end

Adauth.configure do |c|
	# The Domain name of your Domain
	#
	# This is usually my_company.com or my_company.local
	#
	# If you don't know your domain contact your IT support,
	# it will be the DNS suffix applied to your machines
	c.domain = "example.com"

	# The IP address or Hostname of a DC (Domain Controller) on your network
	#
	# This could be anything and probably wont be 127.0.0.1
	#
	# Again contact your IT Support if you can't work this out
	c.server = "127.0.0.1"

	# The LDAP base of your domain/intended users
	#
	# For all users in your domain the base would be:
	# dc=example, dc=com
	# OUs can be prepeneded to restrict access to your app
	c.base = "dc=example, dc=com"

	# The port isn't always needed as Adauth defaults to 389 the LDAP Port
	#
	# If your DC is on the other side of a firewall you may need to change the port
	#c.port = 389

	# Windows Security groups to allow
	#
	# Only allow members of set windows security groups to login
	#
	# Takes an array for group names
	#c.allowed_groups = ["Group1", "Group2"]

	# Windows Security groups to deny
	#
	# Only allow users who aren't in these groups to login
	#
	# Takes an array for group names
	#c.denied_groups = ["Group1", "Group2"]
end

Add denied groups to the config file template


<%= date_of @plan %>

Income still available: <%= number_to_currency(@plan.income_available) %>

  <%= link_to "Edit income", edit_plan_path %>

<a href="#" class="js-previous" data-id="<%= @plan.id %>">Previous month

  <%= link_to "Add purchase to plan", new_plan_purchase_path(@plan), class: "btn btn-primary" %>

    <% if @plan.purchases_pending.any? %>

Your planned purchases include...

        <%= render @purchases_pending %>

    <% end %>

    <% if @plan.purchases_paid_for.any? %>

Purchases paid for...

        <%= render @purchases_paid %>

    <% end %>

<%= date_of @plan %>

Income still available: <%= number_to_currency(@plan.income_available) %>

  <%= link_to "Edit income", edit_plan_path %>

  <%= link_to "Add purchase to plan", new_plan_purchase_path(@plan), class: "btn btn-primary" %>

    <% if @plan.purchases_pending.any? %>

Your planned purchases include...

        <%= render @purchases_pending %>

    <% end %>

    <% if @plan.purchases_paid_for.any? %>

Purchases paid for...

        <%= render @purchases_paid %>

    <% end %>

Remove Bootstrap pager from Plans show view


Hello, <%= @user.name %>

	Profile information placeholder

	Content Placeholder

	Content Placeholder

	<%= button_to('Delete Account', user_path(@user), method: :delete, data: { confirm: "Are you sure?", disable_with: "loading...." }) %>

Hello, <%= @user.name %>

	<%= link_to("Edit Profile", edit_user_path) %>

Profile Information

Name: <%= @user.name %>

Email: <%= @user.email %>

Member Since: <%= @user.created_at %>

	Content Placeholder

	Content Placeholder

	<%= button_to('Delete Account', user_path(@user), method: :delete, data: { confirm: "Are you sure?", disable_with: "loading...." }) %>

Add user information to user show page

Add user information to user show page


<!DOCTYPE html>

    <title><%= name.capitalize %></title>

    <link href="/assets/app.css" media="all" rel="stylesheet" type="text/css">

Welcome to <%= name.capitalize %>!

Home

About

    <%%= yield %>

Move app.js bundle to end of generated app layout

* /cc @jessicard @fabianperez


filter {
  if [fields][apache_log_type] == "access_log" {
    grok {
      match => { "message" => "%{COMBINEDAPACHELOG}( %{NUMBER:duration_ms})?" }
    }
    date {
      match => [ "timestamp" , "dd/MMM/yyyy:HH:mm:ss Z" ]
    }
    mutate {
      add_field => {
        "[@metadata][target_index]" => "apache_logs-%{+YYYY.MM.dd}"
      }
      convert => {
        "response" => "integer"
        "duration_ms" => "integer"
      }
    }
  } else if "swh-worker@" in [systemd_unit] {
    mutate {
      add_field => {
        "[@metadata][target_index]" => "swh_workers-%{+YYYY.MM.dd}"
      }
    }
  } else {
    mutate {
      add_field => {
        "[@metadata][target_index]" => "systemlogs-%{+YYYY.MM.dd}"
      }
    }
  }
}

filter {
  if [fields][apache_log_type] == "access_log" {
    grok {
      match => { "message" => "%{COMBINEDAPACHELOG}( %{NUMBER:duration_ms})?" }
    }
    date {
      match => [ "timestamp" , "dd/MMM/yyyy:HH:mm:ss Z" ]
    }
    mutate {
      add_field => {
        "[@metadata][target_index]" => "apache_logs-%{+YYYY.MM.dd}"
      }
      convert => {
        "response" => "integer"
        "duration_ms" => "integer"
        "bytes" => "integer"
      }
    }
  } else if "swh-worker@" in [systemd_unit] {
    mutate {
      add_field => {
        "[@metadata][target_index]" => "swh_workers-%{+YYYY.MM.dd}"
      }
    }
  } else {
    mutate {
      add_field => {
        "[@metadata][target_index]" => "systemlogs-%{+YYYY.MM.dd}"
      }
    }
  }
}

logstash: Allow to perform numerical operations on bytes

The bytes field also needs to be converted to an integer
to be able to compute sum or average operations on it

Related to T2787


---
title: Rate Limit Information Returned by the Cloud Controller API
owner: CAPI
---

The Cloud Controller API includes rate limit information in the HTTP header. Each header includes the following:

```
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 56
X-RateLimit-Reset: 1372700873
```

Use this table to understand the rate limit header.

Field Value
Description

 	X-RateLimit-Limit
 	The maximum number of attempts per User Account and Authentication (UAA) user, if a user is authenticated. The maximum number of attempts per IP address, if no user is authenticated.

 	X-RateLimit-Remaining
 	The number of attempts remaining.

 	X-RateLimit-Reset
 	The time when the rate limit counter resets, in UTC epoch seconds.

When requests exceed the rate limit value, the Cloud Controller API returns a `429: Too Many Requests` error code.

---
title: Rate Limit Information Returned by the Cloud Controller API
owner: CAPI
---

The Cloud Controller API includes rate limit information in the HTTP header. Each header includes the following:

```
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 56
X-RateLimit-Reset: 1372700873
```

Use this table to understand the rate limit header.

Field Value
Description

 	X-RateLimit-Limit
 	The maximum number of attempts per User Account and Authentication (UAA) user, if a user is authenticated. The maximum number of attempts per IP address, if no user is authenticated.

 	X-RateLimit-Remaining
	The estimated number of attempts remaining.

 	X-RateLimit-Reset
 	The time when the rate limit counter resets, in UTC epoch seconds.

Requests are counted separately in each Cloud Controller instance and each produces an estimate for the total number of remaining requests.
The estimate is based off the fraction remaining on the Cloud Controller instance (rounded down to nearest 10%) multiplied by the global maximum number of attempts.
This may result in slightly inconsistent values for the `X-RateLimit-Remaining` header when running multiple instances of Cloud Controller API such as some requests still being allowed when the header value is `0`.

When requests exceed the maximum rate limit value, the Cloud Controller API returns a `429: Too Many Requests` error code.

Clarify how rate limiting works in CAPI 1.120.0

Explain that the remaining header is an estimate and each CC API
instance counts separately so there may be some variation in responses


Welcome to WebNews!

Your WebNews account has been created and you're all set to party like it's 1987. If you find yourself wondering about news etiquette or what each newsgroup is for, the wiki page on News has you covered.

All posts up to this moment have been marked read for you. Newsgroups with unread posts will appear bold. You can quickly jump through your unread posts using the Next Unread button or by pressing the n key (check the ? button in the upper-right for the full list of hotkeys).

By default, all new posts made from this point on (except those in csh.lists.* and csh.test) will be marked unread for you. To change this and other options, use the Settings button in the upper-right.

    Continue to WebNews

Welcome to WebNews!

Your WebNews account has been created and you're all set to party like it's 1987. If you find yourself wondering about news etiquette or what each newsgroup is for, the wiki page on News has you covered.

All posts up to this moment have been marked read for you. Newsgroups with unread posts will appear bold. You can quickly jump through your unread posts using the Next Unread button or by pressing the n key (check the ? button in the upper-right for the full list of hotkeys).

By default, all new posts made from this point on (except those in control.cancel and csh.test) will be marked unread for you. To change this and other options, use the Settings button in the upper-right.

    Continue to WebNews

Update wording on new user dialog

Update wording on new user dialog


<% content_for :title do %>
  You’ll need a visa to join your family or partner in the UK
<% end %>

<% content_for :body do %>
  ^If you’re visiting family or partner for 6 months or less, you’ll need a [family visit visa](/family-visit-visa).^

  The visa you apply for depends on your family member’s situation.

  <%= render partial: 'stateless_or_refugee.govspeak.erb', locals: {calculator: calculator} %>

  <%= render partial: 'estonia_or_latvia.govspeak.erb', locals: {calculator: calculator} %>

  ##They’re settled in the UK

  Apply for a [‘family of a settled person’ visa](/join-family-in-uk) if your family member or partner is either a British citizen or from outside the European Economic Area (EEA) and settled in the UK.

  ##They’re working or studying in the UK

  You may be able to apply as a ‘dependant’ of [your family member's visa category](/visas-immigration) if they're from outside the EEA and they're working or studying in the UK.

  ##They’re from the EEA

  Apply for a [family permit](/family-permit) to join your family or partner for a short or long stay if they’re living in the UK.
<% end %>

<% content_for :title do %>
  You’ll need a visa to join your family or partner in the UK
<% end %>

<% content_for :body do %>
  ^If you’re visiting family or partner for 6 months or less, you’ll need a [Standard Visitor visa](/standard-visitor-visa).^

  The visa you apply for depends on your family member’s situation.

  <%= render partial: 'stateless_or_refugee.govspeak.erb', locals: {calculator: calculator} %>

  <%= render partial: 'estonia_or_latvia.govspeak.erb', locals: {calculator: calculator} %>

  ##They’re settled in the UK

  Apply for a [‘family of a settled person’ visa](/join-family-in-uk) if your family member or partner is either a British citizen or from outside the European Economic Area (EEA) and settled in the UK.

  ##They’re working or studying in the UK

  You may be able to apply as a ‘dependant’ of [your family member's visa category](/visas-immigration) if they're from outside the EEA and they're working or studying in the UK.

  ##They’re from the EEA

  Apply for a [family permit](/family-permit) to join your family or partner for a short or long stay if they’re living in the UK.
<% end %>

Fix link for family visit visas

Fix link for family visit visas

Family visit visas have been replaced by standard visitor visas, so
update the link.


<% scope ||= nil %>
<%= hidden_field :record, column.name, active_scaffold_input_options(column, scope) %>

Fix render hidden column out of subform

Fix render hidden column out of subform


version: '3'

services:
  db:
    image: postgres
    environment:
      POSTGRES_DB: concourse
      POSTGRES_USER: dev
      POSTGRES_PASSWORD: dev

  web:
    image: concourse/concourse:4.2.2
    command: quickstart
    privileged: true
    depends_on: [db]
    ports: ["8080:8080"]
    environment:
      CONCOURSE_POSTGRES_HOST: db
      CONCOURSE_POSTGRES_USER: dev
      CONCOURSE_POSTGRES_PASSWORD: dev
      CONCOURSE_POSTGRES_DATABASE: concourse
      CONCOURSE_EXTERNAL_URL: https://ci.go2tech.de
      CONCOURSE_GITHUB_CLIENT_ID: <%= scope().call_function('hiera', ['concourse::github::client_id']) %>
      CONCOURSE_GITHUB_CLIENT_SECRET: <%= scope().call_function('hiera', ['concourse::github::client_secret']) %>
      CONCOURSE_MAIN_TEAM_GITHUB_ORG: droidwiki
      CONCOURSE_GARDEN_DNS_SERVER: 8.8.8.8
    dns:
      - 8.8.8.8
      - 8.8.4.4

Use Google dns for garden

Use Google dns for garden


<%
   form = local_assigns[:form]
   errors = form&.errors
%>

Find out what you’d get after tax

<%= render 'calculators/error_summary', messages: errors&.messages if form&.invalid? %>

<form action="/take-whole-pot/estimate#calculator" method="get">
  <%= render 'calculators/form_input_currency',
             field: :pot,
             value: form&.pot,
             label: 'Pension pot value',
             error_messages: errors&.get(:pot) %>

  <%= render 'calculators/form_input_currency',
             field: :income,
             value: form&.income,
             label: 'Income for the year',
             hint: 'Includes your salary, savings, benefits and State Pension payments',
             error_messages: errors&.get(:income) %>

  <%= render 'calculators/form_input_submit' %>
</form>

<% if form %>

<% end %>

<%
   form = local_assigns[:form]
   errors = form&.errors
%>

Estimate what you’d get after tax

<%= render 'calculators/error_summary', messages: errors&.messages if form&.invalid? %>

<form action="/take-whole-pot/estimate#calculator" method="get">
  <%= render 'calculators/form_input_currency',
             field: :pot,
             value: form&.pot,
             label: 'Pension pot value',
             error_messages: errors&.get(:pot) %>

  <%= render 'calculators/form_input_currency',
             field: :income,
             value: form&.income,
             label: 'Income for the year',
             hint: 'Includes your salary, savings, benefits and State Pension payments',
             error_messages: errors&.get(:income) %>

  <%= render 'calculators/form_input_submit' %>
</form>

<% if form %>

<% end %>

Update calculator title for taking whole pot


IMDbc

A Conversation about film. A celebration of the critic.

Learn about our trusted critics and network of users <%= link_to 'HERE', users_path %>.

CLICK on a movie title to read reviews:

  <% @movies.each do |movie| %>

<%= link_to "#{movie.title}", movie_path(movie) %>

 <%= movie.average_ratingz(true) %>

<%= link_to "#{movie.title}", movie_path(movie) %> <%= movie.release_date %>

  <% end %>

IMDbc

A Conversation about film. A celebration of the critic.

Learn about our trusted critics and network of users <%= link_to 'HERE', users_path %>.

CLICK on a movie title to read reviews:

  <% @movies.each do |movie| %>

 <%= movie.average_ratingz(true) %>

<%= link_to "#{movie.title}", movie_path(movie) %> <%= movie.release_date %>

  <% end %>

Fix merge conflict on iframe

Fix merge conflict on iframe


$('.cs-main-area .list-group').append("<%= escape_javascript render partial: 'package_list', locals: { packages: @packages, page: params[:page] } %>");

var newPagination;
<% if @packages.count > WillPaginate.per_page * ( params[:page] || '1' ).to_i %>
  newPagination = "<%= escape_javascript will_paginate @packages, class: 'pagination cs-full-width cs-no-margin cs-center' %>";
<% else %>
  newPagination = "
";
  <% if params[:search].present? %>
    newPagination += "<%= escape_javascript link_to 'View all Packages', root_path(sort: params[:sort]) %>";
  <% else %>
    newPagination += "Scroll to Top";
  <% end %>
  newPagination += "
";
<% end %>

$('.pagination').replaceWith(newPagination);

$("a[href='#top']").click(function() {
  $("html, body").animate({ scrollTop: 0 }, "slow");
  return false;
});

var appendedSelector = '.cs-main-area > .panel:first-child .list-group',
    appendedList = `<%=
      escape_javascript render partial: 'package_list', \
        locals: { packages: @packages, page: params[:page] }
    %>`;

$(appendedSelector).append(appendedList);

var newPagination;
<% if @packages.count > WillPaginate.per_page * ( params[:page] || '1' ).to_i %>
  newPagination = "<%= escape_javascript will_paginate @packages, class: 'pagination cs-full-width cs-no-margin cs-center' %>";
<% else %>
  newPagination = "
";
  <% if params[:search].present? %>
    newPagination += "<%= escape_javascript link_to 'View all Packages', root_path(sort: params[:sort]) %>";
  <% else %>
    newPagination += "Scroll to Top";
  <% end %>
  newPagination += "
";
<% end %>

$('.pagination').replaceWith(newPagination);

$("a[href='#top']").click(function() {
  $("html, body").animate({ scrollTop: 0 }, "slow");
  return false;
});

Fix items being appended to wrong panel on mobile


<%= render 'shared/page_title', title: @recipe.name %>

Steps

<%= simple_format(@recipe.description) %>

        Created by

        <%= link_to gravatar_for(@recipe.chef), recipes_path %>

        <%= @recipe.chef.name %>

          <%= time_ago_in_words(@recipe.created_at) %> ago

      <%= link_to 'Edit Recipe', edit_recipe_path(@recipe), class: 'btn btn-xs btn-warning' %>
      <%= link_to 'Delete Recipe', recipe_path(@recipe), method: :delete,
                  data: { confirm: 'Are you sure you want to delete this recipe' }, class: 'btn btn-xs btn-danger' %>
      <%= link_to 'Back to Recipe List', recipes_path, class: 'btn btn-xs btn-primary btn-custom' %>

<%= render 'shared/page_title', title: @recipe.name %>

Steps

<%= simple_format(@recipe.description) %>

        Created by

        <%= link_to gravatar_for(@recipe.chef), @recipe.chef %>

        <%= @recipe.chef.name %>

          <%= time_ago_in_words(@recipe.created_at) %> ago

      <%= link_to 'Edit Recipe', edit_recipe_path(@recipe), class: 'btn btn-xs btn-warning' %>
      <%= link_to 'Delete Recipe', recipe_path(@recipe), method: :delete,
                  data: { confirm: 'Are you sure you want to delete this recipe' }, class: 'btn btn-xs btn-danger' %>
      <%= link_to 'Back to Recipe List', recipes_path, class: 'btn btn-xs btn-primary btn-custom' %>

Correct recipe show page chef link to go to chef


<%= _("Act on what you've learnt") %>

    <% tweet_link = "https://twitter.com/share?" << {
        :url => request.url,
        :via => AlaveteliConfiguration.twitter_username,
        :text => "'#{ @info_request.title }'",
        :related => _('alaveteli_foi:The software that runs {{site_name}}', :site_name => site_name)
      }.to_query
    %>

    <% link_to tweet_link do %>
      <%= image_tag "twitter-16.png", :alt => "twitter icon" %>
    <% end %>
    <%= link_to _("Tweet this request"), tweet_link %>

    <%= link_to "http://wordpress.com/" do %>
      <%= image_tag "wordpress.png", :class => "rss" %>
    <% end %>
    <%= link_to _("Start your own blog"), "http://wordpress.com/"%>

<% if AlaveteliConfiguration::enable_widgets %>

     <%= link_to _("Create a widget for this request"), new_request_widget_path(@info_request) %>

<% end %>

Add link to create widget if widgets are enabled.


		img_tag("<%= @film.movie_art %>", class: "art_thumbnail")

 <%= @film.title %>

		Reviewer: <%= @review.user.name %>

 <%= @review.content %>

		<%= render partial: "/votes/vote", locals: { voteable: @review, vote_route: "/reviews/#{@review.id}"}  %>

        <img src=" <%= @film.movie_art %>">
        Card Title

 <%= @film.title %>

		Reviewer: <%= @review.user.name %>

 <%= @review.content %>

		<%= render partial: "/votes/vote", locals: { voteable: @review, vote_route: "/reviews/#{@review.id}"}  %>

Fix Review show page image

Fix Review show page image


        Start game

Or, select a topic!

      <% @topics.each do |topic| %>
        <a href="/topics/<%=topic.topic%>" class="collection-item">
          <%=topic.topic%> (<%=topic.twitter_handles.count%>)

      <% end %>

        Start game

Or, select a topic!

      <% @topics.each do |topic| %>
        <a href="/topics/<%=topic.topic%>" class="collection-item">
          <%=topic.topic%>

            <%=topic.twitter_handles.where(real_twitter_handle_id: nil).count%>
            Handles

      <% end %>

Change account count to CSS, add `accounts`


<% if @embedded %>

<% else %>

<% end %>

<div id="<%= @id %>" style="height: 100%; width: 100%;" class="plotly-graph-div">

Fix way to require Plotly.js

Fix way to require Plotly.js


PWS-Logsearch log queue

PWS-Logsearch log queue is too big. Log ingestion has stopped or slowed, or log generation has increased beyond the rate of log ingestion.

Max size is 140M. After the queue reaches maximum size, Logsearch will start dropping platform logs.

@pagerduty-pws-logsearch

General troubleshooting info and tools: https://www.pivotaltracker.com/n/projects/1598663/stories/131794531

Questions that might be useful to answer:
Is Logsearch being deployed?
Are the elastic_search nodes out of disk space? Is the trendline up or flat?
Are the parsers failing?
Are any other components failing?
Has log generation by the platform increased recently?
Has Logsearch been deployed/modified recently?

If no disk space available, this can be temporarily mitigated by deleting old logs: https://www.pivotaltracker.com/story/show/142002145

This alert last updated by Natalie Bennett on March 29, 2017.

Question: max(last_1m):avg:datadog.nozzle.logsearch.logsearch_redis_queue_size{deployment:<%= environment %>-logsearch,job:queue} > 9000000

Edit alert threshold for prod-logsearch queue size

* the queue limit is 140 million; we had been triggering well under the
limit

Signed-off-by: Renee Chu <dbb10253d556b7398455fa674afa4c4a5a96979a@pivotal.io>


We want some fact checking! Please! On <%= @edition.title %>

<%= "#{ExternalServices.front_end_host}/#{@edition.container.slug}?edition=#{@edition.version_number}" %>

Hello - thank you for fact-checking the beta version of www.gov.uk

Please read this content and check it's factually correct.

If you spot something that's incorrect, please let us know by:

- replying to this email with your comments
- directing us to any specific instances, e.g. part 2, subheading 3
- explaining what the problem is, e.g. the text implies a legal obligation, when there isn't one

Please don't rewrite the text - just point out any factual errors. We will rewrite accordingly.

Beta editorial team

<%= @edition.title %>

<%= "#{ExternalServices.front_end_host}/#{@edition.container.slug}?edition=#{@edition.version_number}" %>

Put correct copy in fact check email

Put correct copy in fact check email


You should come back and use this service again to check the latest guidance if your circumstances change (for example, when your employer asks you to return to work) as new rules may be decided.

You should come back and use this service again to check the latest guidance if your circumstances change as new rules may be decided.

Remove example from return to service prompt on outcome pages

This is to simplify content in the coronavirus employee risk assessment.


<% if Redmine::OmniAuthCAS.cas_server.present? %>

<% content_for :header_tags do %>
  <%= stylesheet_link_tag "login", :plugin => "redmine_omniauth_cas" %>
<% end %>

<div id="cas-login">
  <%= link_to label_for_cas_login, '/auth/cas' %>
</div>

<% end %>

<% if Redmine::OmniAuthCAS.cas_server.present? %>

<% content_for :header_tags do %>
  <%= stylesheet_link_tag "login", :plugin => "redmine_omniauth_cas" %>
<% end %>

<div id="cas-login">
  <%= link_to label_for_cas_login, :controller => "account", :action => "blank", :provider => "cas" %>
</div>

<% end %>

Fix "Login with CAS" link when Redmine is installed in a subdirectory.


The MIT License (MIT)

Copyright (c) 2016 <%= user_name %>

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.

The MIT License (MIT)

Copyright (c) <%= Time.now.year %> <%= user_name %>

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.

Use the current year for the LICENSE of theme


        Money Advice Service

      <%= render 'shared/social_links' %>

      <%= link_to root_path do %>

        Money Advice Service
      <% end %>

      <%= render 'shared/social_links' %>

Add homepage link to logo in footer

Add homepage link to logo in footer


<%= block_title(block.title) %>

  <% block.events(user).map do |event| %>
    <% days_left = ( (event.start_date - DateTime.now)/60/60/24 ).round %>

        <%= render(
              :file => 'event_plugin/event_block_item',
              :locals => {
                :event => event,
                :block => block,
                :time_class => days_left < 0 ? 'future' : 'past',
                :time_left_str => block.human_time_left(days_left)
              }
            )
        %>

  <% end %>

<%= block_title(block.title) %>

  <% block.events(user).map do |event| %>
    <% days_left = ( (event.start_date - DateTime.now)/60/60/24 ).round %>

        <%= render(
              :file => 'event_plugin/event_block_item',
              :locals => {
                :event => event,
                :block => block,
                :time_class => days_left < 0 ? 'past' : 'future',
                :time_left_str => block.human_time_left(days_left)
              }
            )
        %>

  <% end %>

Fix past/future class on events

event: Fix past/future class on events

Events from the past was being displayed with "future" class and
vice-versa


      Utilities

<%= link_to 'Margins', '/showcase/margins' %>

<%= link_to 'Contextual colors', '/showcase/contextual_colors' %>

      Blocks

<%= link_to 'Alerts', '/showcase/alerts' %>

<%= link_to 'Buttons', '/showcase/buttons' %>

<%= link_to 'Pagination', '/showcase/pagination' %>

<%= link_to 'Labels', '/showcase/labels' %>

<%= link_to 'Tables', '/showcase/tables' %>

      Structures

<%= link_to 'Error Explanation', '/showcase/error_explanation' %>

<%= link_to 'Grid', '/showcase/grid' %>

      Utilities

<%= link_to 'Margins', '/showcase/margins' %>

<%= link_to 'Contextual colors', '/showcase/contextual_colors' %>

      Blocks

<%= link_to 'Alerts', '/showcase/alerts' %>

<%= link_to 'Buttons', '/showcase/buttons' %>

<%= link_to 'Pagination', '/showcase/pagination' %>

<%= link_to 'Labels', '/showcase/labels' %>

<%= link_to 'Tables', '/showcase/tables' %>

      Structures

<%= link_to 'Error Explanation', '/showcase/error_explanation' %>

<%= link_to 'Forms', '/showcase/forms' %>

<%= link_to 'Grid', '/showcase/grid' %>

Add link to forms examples

Add link to forms examples


if ( $wmgUseWikibaseRepo ) {
	// Define custom namespaces. Use these exact constant names.
	$wgNamespaceAliases['Item'] = NS_MAIN;
	$wgNamespaceAliases['Item_talk'] = NS_TALK;

	// Tell Wikibase which namespace to use for which kind of entity
	$wgWBRepoSettings['entityNamespaces']['wikibase-item'] = NS_MAIN;
	define( 'WB_NS_PROPERTY', 122 );
	define( 'WB_NS_PROPERTY_TALK', 123 );
	$wgWBRepoSettings['entityNamespaces']['wikibase-property'] = WB_NS_PROPERTY;

	// Register extra namespaces.
	$wgWBNamespaces[WB_NS_PROPERTY] = 'Property';
	$wgWBNamespaces[WB_NS_PROPERTY_TALK] = 'Property_talk';
	$wgExtraNamespaces = $wgWBNamespaces + $wgExtraNamespaces;
} else {
	$wgWBClientSettings['siteGlobalID'] = 'enwiki';

	$wgWBClientSettings['changesDatabase'] = 'wikidatawiki';
	$wgWBClientSettings['repoDatabase'] = 'wikidatawiki';
}

$wgWBClientSettings['repoUrl'] = '//wikidata<%= scope['::mediawiki::multiwiki::base_domain'] %><%= scope['::port_fragment'] %>';

if ( $wmgUseWikibaseRepo ) {
	// Define custom namespaces. Use these exact constant names.
	$wgNamespaceAliases['Item'] = NS_MAIN;
	$wgNamespaceAliases['Item_talk'] = NS_TALK;

	// Tell Wikibase which namespace to use for which kind of entity
	$wgWBRepoSettings['entityNamespaces']['item'] = NS_MAIN;
	define( 'WB_NS_PROPERTY', 122 );
	define( 'WB_NS_PROPERTY_TALK', 123 );
	$wgWBRepoSettings['entityNamespaces']['property'] = WB_NS_PROPERTY;

	// Register extra namespaces.
	$wgWBNamespaces[WB_NS_PROPERTY] = 'Property';
	$wgWBNamespaces[WB_NS_PROPERTY_TALK] = 'Property_talk';
	$wgExtraNamespaces = $wgWBNamespaces + $wgExtraNamespaces;
} else {
	$wgWBClientSettings['siteGlobalID'] = 'enwiki';

	$wgWBClientSettings['changesDatabase'] = 'wikidatawiki';
	$wgWBClientSettings['repoDatabase'] = 'wikidatawiki';
}

$wgWBClientSettings['repoUrl'] = '//wikidata<%= scope['::mediawiki::multiwiki::base_domain'] %><%= scope['::port_fragment'] %>';

Update Wikidata settings according to new entityNamespaces format

Bug: T138983
Change-Id: I3c7adb3460a8957654d642555d7f5ba5d0cffffc


 <a href="/users/<%= current_user.id %>">
    back to menu

 <%= @trail.title %>

    Length:
    <%= @trail.length %>

    Duration:
    <%= @trail.duration %>

    Difficulty:
    <%= @trail.difficulty %>

    Review:
    <%= @trail.review %>

    Rating:
    <%= @trail.rating %>

    <%= @trail.id %>

Change class name for the show page hike div


# DO NOT EDIT - This file is being maintained by Chef

<VirtualHost *:80>
	ServerName munin.openstreetmap.org
	ServerAlias munin.osm.org
	ServerAdmin webmaster@openstreetmap.org

	CustomLog /var/log/apache2/munin.openstreetmap.org-access.log combined
	ErrorLog /var/log/apache2/munin.openstreetmap.org-error.log

	SetEnv RRDCACHED_ADDRESS /var/run/rrdcached.sock

	DocumentRoot /srv/munin.openstreetmap.org
	Alias /static/favicon.ico /srv/munin.openstreetmap.org/favicon.ico
	Alias /static/ /etc/munin/static/
	ScriptAlias /munin-cgi/ /usr/lib/munin/cgi/

	# Remove Proxy request header to mitigate https://httpoxy.org/
	RequestHeader unset Proxy early

	RewriteEngine on
	RewriteCond %{REQUEST_URI} !^/static/
	RewriteRule ^(/.*\.html)?$ /munin-cgi/munin-cgi-html/$1 [PT]
</VirtualHost>

<Directory /srv/munin.openstreetmap.org>
	Require all granted
</Directory>

<Directory /etc/munin/static>
	Require all granted
</Directory>

<Directory /usr/lib/munin/cgi>
	Options +ExecCGI
	SetHandler fcgid-script
	Require all granted
</Directory>

# DO NOT EDIT - This file is being maintained by Chef

<VirtualHost *:80>
	ServerName munin.openstreetmap.org
	ServerAlias munin.osm.org
	ServerAdmin webmaster@openstreetmap.org

	CustomLog /var/log/apache2/munin.openstreetmap.org-access.log combined
	ErrorLog /var/log/apache2/munin.openstreetmap.org-error.log

	SetEnv RRDCACHED_ADDRESS /var/run/rrdcached.sock

	DocumentRoot /srv/munin.openstreetmap.org
	Alias /static/favicon.ico /srv/munin.openstreetmap.org/favicon.ico
	Alias /static/ /etc/munin/static/
	ScriptAlias /munin-cgi/ /usr/lib/munin/cgi/

	# Remove Proxy request header to mitigate https://httpoxy.org/
	RequestHeader unset Proxy early

	RewriteEngine on
	RewriteCond %{REQUEST_URI} !^/static/
	RewriteCond %{REQUEST_URI} !^/dumps/
	RewriteRule ^(/.*\.html)?$ /munin-cgi/munin-cgi-html/$1 [PT]
</VirtualHost>

<Directory /srv/munin.openstreetmap.org>
	Require all granted
</Directory>

<Directory /srv/munin.openstreetmap.org/dumps>
	Options +Indexes
</Directory>

<Directory /etc/munin/static>
	Require all granted
</Directory>

<Directory /usr/lib/munin/cgi>
	Options +ExecCGI
	SetHandler fcgid-script
	Require all granted
</Directory>

Enable directory indexes for munin/dumps


<%% form_for(@<%= singular_name %>) do |f| %>
  <%%= f.error_messages %>

  <fieldset>
    <legend><%%= t('<%= singular_name %>', :count => 1).humanize %></legend>

<% for attribute in attributes -%>

      <%%= f.label :<%= attribute.name %>, t('<%= "attribute.#{attribute.column.name}" %>') %>
<% if attribute.name =~ /_id\Z/ -%>
<%
  association = attribute.name.sub(/_id\Z/, '')
  label_attribute = association.camelize.constantize.column_names.include?('name') ? 'name' : 'id'
-%>
      <%%= f.collection_select :<%= attribute.name %>, @<%= association.pluralize %>, :id, :<%= label_attribute %>,
        {:prompt => t('select_prompt')} %>
<% else -%>
      <%%= f.<%= attribute.field_type %> :<%= attribute.name %> %>
<% end -%>

<% end -%>

    <%%= f.submit t('save') %>
  </fieldset>
<%% end %>

<%% form_for(@<%= singular_name %>) do |f| %>
  <%%= f.error_messages %>

  <fieldset>
    <legend><%%= t('<%= singular_name %>', :count => 1).humanize %></legend>

<% for attribute in attributes -%>

      <%%= f.label :<%= attribute.name %>, t('<%= "attribute.#{attribute.column.name}" %>') %>
<% if attribute.name =~ /_id\Z/ -%>
<%
  association = attribute.name.sub(/_id\Z/, '')
  label_attribute = association.camelize.constantize.column_names.include?('name') ? 'name' : 'id'
-%>
      <%%= f.collection_select :<%= attribute.name %>, @<%= association.pluralize %>, :id, :<%= label_attribute %>,
        {:prompt => t('select_prompt')} %>
<% elsif attribute.field_type == :date_select -%>
      <%%= f.text_field :<%= attribute.name %> %>
<% else -%>
      <%%= f.<%= attribute.field_type %> :<%= attribute.name %> %>
<% end -%>

<% end -%>

    <%%= f.submit t('save') %>
  </fieldset>
<%% end %>

Use text field for date selection

Use text field for date selection


<% if Translation.find_by_key('site.twitter.query') %>
  <% content_for :side do %>
    <% content_for :head do %>

    <% end %>

Latest Tweets

  <% end %>
<% end %>

<% twitter_username = Translation.find_by_key('site.twitter.username').try(:value) %>
<% twitter_query    = Translation.find_by_key('site.twitter.query').try(:value) %>

<% if twitter_username.present? || twitter_query.present? %>

  <% content_for :head do %>

  <% end %>

  <% content_for :side do %>

Latest Tweets

  <% end %>

<% end %>

Allow twitter name to be used with jquery.tweet


<%
  requestor = @requestor.name(false)
  recipient_name = @user.name(false)
  plan_name = @plan.title
  tool_name = Rails.configuration.branding[:application][:name]
%>

<%= _('Hello %{recipient_name}') % { recipient_name: recipient_name } %>

<%= _('%{commenter} has finished providing feedback on the plan "%{plan_title}". To view the comments, please visit the My Dashboard page in %{tool_name} and open your plan.') % { commenter: requestor, plan_title: plan_name, tool_name: tool_name } %>

<%= render partial: 'email_signature' %>

<%
  requestor = @requestor.name(false)
  recipient_name = @user.name(false)
  plan_name = @plan.title
  tool_name = Rails.configuration.branding[:application][:name]
%>

<%= _('Hello %{recipient_name}') % { recipient_name: recipient_name } %>

  <%= _("%{commenter} has finished providing feedback on the plan \"%{link_html}\". To view the comments, please visit the My Dashboard page in %{tool_name} and open your plan. Plan comments can be found adjacent to your answers in the tabbed panel next to guidance.").html_safe % {
    commenter: requestor,
    link_html: link_to(plan_name, plan_url(@plan)),
    tool_name: tool_name
  }%>

<%= render partial: 'email_signature' %>

Add comments text to feedback completed email

Issue 1492


<% content_for :head do -%>
  <%= webpack_styles_tag 'styles' %>
<% end -%>

<%= render 'shared/default_client_settings' %>
<%= webpack_manifest_script %>

<%= webpack_bundle_tag 'app' %>

Update lti launch to use new webpack config


ogr2ogr
<%= if needs_updating %>
  -update
<% end %>
-skipfailures
-f "FileGDB"
<%= file_name %>
PG:"host=<%= db_config[:host] %>
  user=<%= db_config[:username] %>
  <% unless db_config[:password].nil? %>
    password=<%= db_config[:password] %>
  <% end %>
  dbname=<%= db_config[:database] %>"
-sql "<%= query %>"
-nlt "<%= geom_type.upcase %>"
-nln "<%= feature_name %>"

ogr2ogr
<% if needs_updating %>
  -update
<% end %>
-skipfailures
-f "FileGDB"
<%= file_name %>
PG:"host=<%= db_config[:host] %>
  user=<%= db_config[:username] %>
  <% unless db_config[:password].nil? %>
    password=<%= db_config[:password] %>
  <% end %>
  dbname=<%= db_config[:database] %>"
-sql "<%= query %>"
-nlt "<%= geom_type.upcase %>"
-nln "<%= feature_name %>"

Fix ruby embedding in gdb export

Fix ruby embedding in gdb export


#!/bin/bash

RUN_DIR=/var/vcap/sys/run/splunk-full
LOG_DIR=/var/vcap/sys/log/splunk-full
JOB_DIR=/var/vcap/jobs/splunk-full
PACKAGE_DIR=/var/vcap/packages/splunk
PIDFILE=${RUN_DIR}/pid

case $1 in

  start)
    mkdir -p ${RUN_DIR} ${LOG_DIR}
    mkdir -p ${PACKAGE_DIR}/etc/system/local

    chown -R vcap:vcap ${RUN_DIR} ${LOG_DIR} ${PACKAGE_DIR}/

    echo $$ > ${PIDFILE}

    ln -fs ${JOB_DIR}/config/system_local/* ${PACKAGE_DIR}/etc/system/local/

    exec chpst -u vcap:vcap ${PACKAGE_DIR}/bin/splunk start --accept-license \
      >>  $LOG_DIR/splunk.stdout.log \
      2>> $LOG_DIR/splunk.stderr.log

    ;;

  stop)
    /var/vcap/packages/splunk/bin/splunk stop
    rm -f $PIDFILE

    ;;

  *)
    echo "Usage: ctl.sh {start|stop}" ;;

esac

#!/bin/bash

RUN_DIR=/var/vcap/sys/run/splunk-full
LOG_DIR=/var/vcap/sys/log/splunk-full
JOB_DIR=/var/vcap/jobs/splunk-full
PACKAGE_DIR=/var/vcap/packages/splunk
PIDFILE=${RUN_DIR}/pid
SPLUNK_DB=/var/vcap/store/splunk_db

case $1 in

  start)
    mkdir -p ${RUN_DIR} ${LOG_DIR}
    mkdir -p ${PACKAGE_DIR}/etc/system/local

    chown -R vcap:vcap ${RUN_DIR} ${LOG_DIR} ${PACKAGE_DIR}/

    mkdir -p ${SPLUNK_DB}

    echo $$ > ${PIDFILE}

    ln -fs ${JOB_DIR}/config/system_local/* ${PACKAGE_DIR}/etc/system/local/

    exec chpst -u vcap:vcap ${PACKAGE_DIR}/bin/splunk start --accept-license \
      >>  $LOG_DIR/splunk.stdout.log \
      2>> $LOG_DIR/splunk.stderr.log

    ;;

  stop)
    /var/vcap/packages/splunk/bin/splunk stop
    rm -f $PIDFILE

    ;;

  *)
    echo "Usage: ctl.sh {start|stop}" ;;

esac

Add SPLUNK_DB indexes to persistent disk /var/vcap/store


<!DOCTYPE html>
<html>
<head>
  <meta charset="utf-8" />
  <title>JSLintMate<%=
    " (with #{linter})" unless linter.key == :jslint %></title>
  <style>
    <%= JSLintMate.css %>
  </style>
</head>
<body>
  <%= result %>
  <script>
    <%= JSLintMate.js %>
    window.jslm.version.current = '<%= JSLintMate.version %>';
  </script>
</body>
</html>

<!DOCTYPE html>
<html>
<head>
  <meta charset="utf-8" />
  <title>JSLintMate<%=
    " with #{linter}" unless linter.key == :jslint %></title>
  <style>
    <%= JSLintMate.css %>
  </style>
</head>
<body>
  <%= result %>
  <script>
    <%= JSLintMate.js %>
    window.jslm.version.current = '<%= JSLintMate.version %>';
  </script>
</body>
</html>

Remove parentheses from <title> when using JSHint


This is where your form for creating new users will go.

<%= form_for(@user) do |f| %>

    <%= f.label :username %>:
    <%= f.text_field :username %>

    <%= f.label :email %>:
    <%= f.text_field :email %>

    <%= f.label :password %>:
    <%= f.text_field :password %>

    <%= f.submit %>

<% end %>

Create basic form for new users

Create basic form for new users


    <hgroup>

Licence <%= @licence.title %>

    </hgroup>

Overview

        <%= to_govspeak(@licence.licence_overview) %>

    <hgroup>

Licence <%= @licence.title %>

    </hgroup>

Overview

Overview

        <%= to_govspeak(@licence.licence_overview) %>

Add header for licence frontend type

Add header for licence frontend type


var appendedSelector = '.cs-main-area > .panel:first-child .list-group',
    appendedList = `<%=
      escape_javascript render partial: \
        'layouts/package_list', \
        locals: { packages: @packages }
    %>`;

$(appendedSelector).append(appendedList);

var paginationSelector = '.pagination',
    newPagination = `<%=
      escape_javascript render partial: \
        'layouts/package_pagination', \
        locals: { packages: @packages }
    %>`;

$(paginationSelector).replaceWith(newPagination);

$("a[href='#top']").click(function() {
  $("html, body, .cs-main-area").animate({ scrollTop: 0 }, "slow");
  return false;
});

Fix pagination on search index page

Fix pagination on search index page


<% content_for :js do %>
    <%= headjs_include_tag "plugins/jquery.min", "front/login" %>
  <% end %>

  <% content_for :head do %>
    <%= stylesheet_link_tag('reset.css','front/sessions') %>
  <% end %>

Welcome to CartoDB

Enter your account information to start mapping

    <%= form_tag create_session_path do %>

Please login

      <%= label_tag :email, 'e-mail' %>
      <%= text_field_tag :email, '', :class => (flash[:alert] ? 'error' : nil) %>

        <%= label_tag :password, 'password' %>
        <%= password_field_tag :password, '', :class => (flash[:alert] ? 'error' : nil) %>

      <%= link_to "Did you forget your password?", forget_password_url, :class => "forget" if forget_password_url.present? %>
      <%= submit_tag 'Log in', :class => "login" %>
      <% if flash[:alert] || @login_error %>

<%= flash[:alert] || @login_error %>

      <% end %>
    <% end %>

CartoDB is a product from Vizzuality

<% content_for :js do %>
    <%= headjs_include_tag "plugins/jquery.min", "front/login" %>
  <% end %>

  <% content_for :head do %>
    <%= stylesheet_link_tag('reset.css','front/sessions') %>
  <% end %>

Welcome to CartoDB

Enter your account information to start mapping

    <%= form_tag create_session_path do %>

Please login

      <%= label_tag :email, 'e-mail' %>
      <%= text_field_tag :email, '', :class => (flash[:alert] || @login_error ? 'error' : nil) %>

        <%= label_tag :password, 'password' %>
        <%= password_field_tag :password, '', :class => (flash[:alert] || @login_error ? 'error' : nil) %>

      <%= link_to "Did you forget your password?", forget_password_url, :class => "forget" if forget_password_url.present? %>
      <%= submit_tag 'Log in', :class => "login" %>
      <% if flash[:alert] || @login_error %>

<%= flash[:alert] || @login_error %>

      <% end %>
    <% end %>

CartoDB is a product from Vizzuality

Check @login_error in login form

Check @login_error in login form


Advertisement #<%= @ad.id %>

  Id
  <%= @ad.id %>

  Image URL
  <%= @ad.image_url %>

  Referral URL
  <%= @ad.referral_url %>

  Width
  <%= @ad.width %>

  Height
  <%= @ad.height %>

  Ad Type
  <%= @ad.ad_type %>

  Status
  <%= @ad.status %>

  Hit Count
  <%= @ad.hit_count %>

<%= link_to 'Edit', edit_advertisement_path(@ad) %>
<%= link_to 'Back', advertisements_path %>

Advertisement #<%= @ad.id %>

  Id
  <%= @ad.id %>

  Image URL
  <%= @ad.image_url %>

  Referral URL
  <%= @ad.referral_url %>

  Width
  <%= @ad.width %>

  Height
  <%= @ad.height %>

  Ad Type
  <%= @ad.ad_type %>

  Status
  <%= @ad.status %>

  Hit Count
  <%= @ad.hit_count %>

<%= link_to 'Edit', edit_advertisement_path(@ad) %>
<%= link_to 'Delete', @ad, :confirm => 'Are you sure?', :method => :delete
<%= link_to 'Back', advertisements_path %>

Add delete link in advertisements/show.

Add delete link in advertisements/show.


<!DOCTYPE html>

  <link href='//fonts.googleapis.com/css?family=Droid+Sans' rel='stylesheet' type='text/css'>
  <link href='//fonts.googleapis.com/css?family=Oswald' rel='stylesheet' type='text/css'>
  <link href='//fonts.googleapis.com/css?family=Lobster' rel='stylesheet' type='text/css'>
  <link href='//fonts.googleapis.com/css?family=Abel' rel='stylesheet' type='text/css'>
  <title>PDFMHDbcOverflow</title>
  <%= stylesheet_link_tag    'application', media: 'all', 'data-turbolinks-track' => true %>
  <%= javascript_include_tag 'application', 'data-turbolinks-track' => true %>
  <%= csrf_meta_tags %>

DBC Overflow

              <%= button_to 'Login' %>

              <%= button_to 'Signup' %>

              <%= form_tag("/search", method: "get") do %>
                <%= text_field_tag(:q) %>
                <%= submit_tag("Search") %>
              <% end %>

      <%= yield %>

<!DOCTYPE html>

  <link href='//fonts.googleapis.com/css?family=Droid+Sans' rel='stylesheet' type='text/css'>
  <link href='//fonts.googleapis.com/css?family=Oswald' rel='stylesheet' type='text/css'>
  <link href='//fonts.googleapis.com/css?family=Lobster' rel='stylesheet' type='text/css'>
  <link href='//fonts.googleapis.com/css?family=Abel' rel='stylesheet' type='text/css'>
  <title>PDFMHDbcOverflow</title>
  <%= stylesheet_link_tag    'application', media: 'all', 'data-turbolinks-track' => true %>
  <%= javascript_include_tag 'application', 'data-turbolinks-track' => true %>
  <%= csrf_meta_tags %>

DBC Overflow

            <% if logged_in? %>

<%= button_to 'Logout', logout_path, method: :get %>

            <% else %>

                <%= button_to 'Login', login_path, method: :get %>

                <%= button_to 'Signup' %>

            <% end %>

              <%= form_tag("/search", method: "get", id: "search_form") do %>
                <%= text_field_tag(:q) %>
                <%= submit_tag("Search") %>
              <% end %>

      <%= yield %>

Change view for loged in and out status.