Skip to content

Instantly share code, notes, and snippets.

View chriscooning's full-sized avatar
🛠️
Building cool stuff

Chris Cooning chriscooning

🛠️
Building cool stuff
View GitHub Profile
using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Reflection;
using System.Threading.Tasks;
using System.Windows.Forms;
namespace McKCO_Portal
{
html, body {
overflow: auto;
}
h4 a {
font-size: 12px;
overflow: hidden;
text-overflow: ellipsis;
-o-text-overflow: ellipsis;
white-space: nowrap;
html, body {
overflow: auto;
}
h4 a {
font-size: 12px;
overflow: hidden;
text-overflow: ellipsis;
-o-text-overflow: ellipsis;
white-space: nowrap;
@chriscooning
chriscooning / bsim.css
Created February 9, 2016 20:45
BSIM quicksite CSS
html, body {
overflow: auto;
}
h4 a {
font-size: 12px;
overflow: hidden;
text-overflow: ellipsis;
-o-text-overflow: ellipsis;
white-space: nowrap;
<?php
/*
Template Name: homePage
*/
?>
<?php get_header(); ?>
<?php $page_layout = of_get_option('ttrust_posts_home_layout'); ?>
<?php $content_width = ($page_layout=="masonry_no_sidebar") ? "full" : "threeFourths" ?>
<?php $posts_layout = ($page_layout!="normal") ? "masonry" : "" ?>
// add module - again
//var nfm = require("netfunctional.mapoverlay");
// set the window
var win = Titanium.UI.createWindow({
title : 'Map',
orientationModes: [
Ti.UI.LANDSCAPE_LEFT,
Ti.UI.LANDSCAPE_RIGHT,
<iframe frameborder='0' allowfullscreen='allowfullscreen' webkitallowfullscreen='webkitallowfullscreen' mozallowfullscreen='mozallowfullscreen' width='500' height='300' src='//omg.digitalmediacenter.com/e/3bc0f418df60f8b3e9b7b70b0daf7c87?autoplay=false&sharing=' />
@chriscooning
chriscooning / static_controller_spec.rb
Created October 20, 2014 18:31
static_controller_spec.rb
require "spec_helper"
def check_page_availability(name)
get :show, format: :html, page: name
expect(response.status).to eq 200
end
describe StaticController do
render_views
a = {}
Day.all.map do |day|
a.merge!({day.date => []})
day.user_schedules.group(:user_id).count.each do |us|
if us[1] > 1
day.user_schedules.where("user_id = ?", us[0]).each do |uss|
if User.find(us[0]).department_blocks
.where(
"department_blocks.id != ?", uss.department_block.id
)
SELECT "user_availabilities".* FROM "user_availabilities" WHERE "user_availabilities"."user_id" IN (8296, 8754, 9383, 7748, 8985, 9280, 9230, 9261, 1080, 9268, 7575, 7612, 8753, 7893, 7783, 7501, 8365, 9442, 9243, 4313, ... , 7336, 9343, 3457, 7746, 8215, 7641, 9245, 8426, 7890, 8370, 8032, 9295, 9418, 8435, 8078, 8413, 9152, 9283, 9072, 8120, 8952, 7743, 9370, 9147, 7886, 8891, 7478, 8464, 295, 8315, 8576, 7685, 9355, 8838, 9366, 7465, 7595, 8049, 8498, 8420, 8323, 2866, 2196, 7582, 2474, 8041, 2132, 563, 8376, 8064, 8767, 7767, 9057, 8031, 8367, 8746, 8039, 7675) AND "user_availabilities"."day_id" = 6 AND (user_availabilities.user_id NOT IN (27,34,59,60,63,77,133,134,136,137)) AND (user_availabilities.user_id NOT IN (7387,2837,8682,8116,8796,9428,8025,8754,9070,7919,7969,7647,7889,8526,7921,9154,9261,1080,7516,8789,7391,8736,7383,1525,7674,8753,9146,8611,7680,7893,8111,8379,2973,2008,8365,9432,9071,7552,7882,4313,2769,151,8423,162,7365,8126,8781,2135,2773,7452,7914,1539,8438,9013,1512,9259,8181,9135,8054,78