publisher now can handle services, and is on seperate page
This commit is contained in:
parent
f2ca2c2357
commit
4bd0cbfdc8
6 changed files with 45 additions and 14 deletions
|
|
@ -72,7 +72,7 @@ class StatusMessagesController < ApplicationController
|
||||||
respond_to do |format|
|
respond_to do |format|
|
||||||
format.js { render :create, :status => 201}
|
format.js { render :create, :status => 201}
|
||||||
format.html { redirect_to :back}
|
format.html { redirect_to :back}
|
||||||
format.mobile{ redirect_to :back}
|
format.mobile{ redirect_to root_url}
|
||||||
end
|
end
|
||||||
else
|
else
|
||||||
if !photos.empty?
|
if !photos.empty?
|
||||||
|
|
|
||||||
|
|
@ -8,11 +8,12 @@
|
||||||
- else
|
- else
|
||||||
= @aspect
|
= @aspect
|
||||||
|
|
||||||
.grey_back
|
%h1
|
||||||
= render 'shared/publisher', :aspect_ids => @aspect_ids
|
= link_to 'post a message >> ', '#publisher_page', :id => 'publisher_button'
|
||||||
|
|
||||||
#main_stream.stream
|
#main_stream.stream
|
||||||
= render 'shared/stream', :posts => @fakes
|
= render 'shared/stream', :posts => @fakes
|
||||||
%a.more-link.paginate{:href => '#'}
|
%a.more-link.paginate{:href => '#'}
|
||||||
%h2= t("more")
|
%h2= t("more")
|
||||||
= will_paginate @posts
|
= will_paginate @posts
|
||||||
|
- content_for :subpages do
|
||||||
|
= render 'shared/publisher', :aspect_ids => @aspect_ids
|
||||||
|
|
|
||||||
|
|
@ -9,3 +9,5 @@
|
||||||
#pagination
|
#pagination
|
||||||
= will_paginate @posts
|
= will_paginate @posts
|
||||||
|
|
||||||
|
- content_for :subpages do
|
||||||
|
= render 'shared/publisher', :aspect_ids => @aspect_ids
|
||||||
|
|
|
||||||
|
|
@ -89,3 +89,6 @@
|
||||||
|
|
||||||
|
|
||||||
= render :partial =>'shared/footer'
|
= render :partial =>'shared/footer'
|
||||||
|
|
||||||
|
= yield :subpages
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -9,8 +9,17 @@
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
#publisher
|
#publisher_page{:data => {:role => 'page', :theme => 'c'}}
|
||||||
= form_for StatusMessage.new do |status|
|
#header
|
||||||
|
- if current_user
|
||||||
|
.left
|
||||||
|
= link_to(image_tag('icons/list_white.png'), '/aspects/#menu', :id => "menu_button")
|
||||||
|
|
||||||
|
.right
|
||||||
|
= link_to(image_tag('icons/search_white.png'), people_path)
|
||||||
|
= link_to(image_tag('white.png'), aspects_path)
|
||||||
|
%div{:data => {:role => 'content'}}
|
||||||
|
= form_for StatusMessage.new, {:data => {:ajax => false}} do |status|
|
||||||
#publisher_text
|
#publisher_text
|
||||||
= t('.whats_on_your_mind')
|
= t('.whats_on_your_mind')
|
||||||
|
|
||||||
|
|
@ -20,11 +29,25 @@
|
||||||
= hidden_field_tag 'aspect_ids[]', aspect_id.to_s
|
= hidden_field_tag 'aspect_ids[]', aspect_id.to_s
|
||||||
|
|
||||||
|
|
||||||
%fieldset.hidden{:style => 'text-align:right;'}
|
%fieldset
|
||||||
%fieldset{:data => {:role => 'controlgroup', :type=>'horizontal'}}
|
|
||||||
- unless params[:a_ids]
|
- unless params[:a_ids]
|
||||||
%input{:type => 'checkbox', :name => 'status_message[public]', :id => 'public', :class => 'custom', :value => 'true'}
|
%input{:type => 'checkbox', :name => 'status_message[public]', :id => 'public', :class => 'custom', :value => 'true'}
|
||||||
%label{:for => 'public'}
|
%label{:for => 'public'}
|
||||||
= t('.make_public')
|
= t('.make_public')
|
||||||
= status.submit t('.share'), 'data-inline' => 'true', 'data-theme' => 'b'
|
- unless current_user.services.empty?
|
||||||
|
%div{:data => {:role => 'fieldcontain'}}
|
||||||
|
%label{:for => 'services', :class => 'select'}
|
||||||
|
choose services
|
||||||
|
|
||||||
|
- current_user.services.each do |service|
|
||||||
|
%input{:type => 'checkbox', :name => "services[]", :id => "#{service.provider}", :class => 'custom', :value => "#{service.provider}"}
|
||||||
|
%label{:for => "#{service.provider}"}
|
||||||
|
= "#{service.provider}"
|
||||||
|
-#%select{:name => 'services', :multiple => 'multiple', :id => "services"}
|
||||||
|
-#%option
|
||||||
|
-#Choose a Service
|
||||||
|
-#- current_user.services.each do |service|
|
||||||
|
-#%option{:value => "#{service.provider}"}
|
||||||
|
-#= service.provider.titleize
|
||||||
|
= status.submit t('.share'), 'data-theme' => 'c'
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -7,5 +7,7 @@ $(document).bind("mobileinit", function() {
|
||||||
$.extend($.mobile, {
|
$.extend($.mobile, {
|
||||||
ajaxLinksEnabled: false,
|
ajaxLinksEnabled: false,
|
||||||
ajaxFormsEnabled: false
|
ajaxFormsEnabled: false
|
||||||
|
|
||||||
});
|
});
|
||||||
|
$.mobile.selectmenu.prototype.options.nativeMenu = false;
|
||||||
});
|
});
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue