This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const crypto = require('crypto'); | |
// Key Generation: | |
// openssl genrsa -out private.pem 2048 | |
// openssl req -new -x509 -sha256 -key private.pem -out cert.pem | |
const privateKey = `-----BEGIN RSA PRIVATE KEY----- | |
MIIEpQIBAAKCAQEAqLBL71MM1yYlJnpMgixaxEPCPn54do6ViE+f0Cn/y+Ym0YyS | |
gptm+Y2vojsL8djtSXqWsJcjEt3N+3N+64d2wKhL8HOoWyj+EGCU1kG6RODwzgkR | |
e15KkUq7mxppB2xPVwLGSLAG8o9CKvj3pFFFteMMsXXfWWo9QMGXEmP7+yx2740E |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"global": { | |
"check_for_updates_on_startup": false, | |
"show_in_menu_bar": true, | |
"show_profile_name_in_menu_bar": false | |
}, | |
"profiles": [ | |
{ | |
"complex_modifications": { | |
"parameters": { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Post.transaction do | |
Post.update_all("last_interacted_at = updated_at") | |
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class ErrorsController < ApplicationController | |
def not_found | |
end | |
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Pusher.should_receive(:trigger) | |
@screen = FactoryGirl.create(:tv_screen, :screenable_type => 'Event', :status => 'active', :location_id => @location.id) | |
@publisher.publish |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
TvScreen.find(@screen.id).last_aired.should be_within(1.minute).of(DateTime.now) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require "#{Rails.root}/lib/we_tv/screen_generators/post_screen_generator" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class HelloWorldController < AbstractController::Base | |
include AbstractController::Rendering | |
include AbstractController::Layouts | |
include AbstractController::Helpers | |
include AbstractController::Translation | |
include AbstractController::AssetPaths | |
include ActionController::UrlFor | |
include Rails.application.routes.url_helpers | |
add_template_helper(ApplicationHelper) #This is important if you want to use your ApplicationHelper methods in your views. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
= simple_form_for([:admin, @announcement]) do |f| | |
= f.error_notification | |
- current_profile = Profile.find_by_user_id(@current_user.id) | |
.form-inputs | |
= f.input :message, :required => true | |
= f.hidden_field :profile_id, :value => @current_user.primary_profile.id | |
= f.fields_for :TvScreen do |tv| | |
/// STARTS | |
= tv.input :starts_on, :placeholder => "MM/DD/YYYY", :input_html => {:class => "datepicker date-picker"}, :label => "Announcement starts on" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
.search_complete | |
%ul | |
=# @skill_results.count | |
-if(@user_results.present? && @user_results.results.count > 0) | |
.search_section_header#member_search | |
Members | |
- @user_results.results.first(5).each do |result| | |
- if (result.class.to_s == "User") | |
- result_to_use = result.primary_profile |
NewerOlder