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
From http://linux.die.net/man/3/strftime | |
%a - The abbreviated weekday name (``Sun'') | |
%A - The full weekday name (``Sunday'') | |
%b - The abbreviated month name (``Jan'') | |
%B - The full month name (``January'') | |
%c - The preferred local date and time representation | |
%d - Day of the month (01..31) | |
%e - Day of the month without leading 0 (1..31) | |
%g - Year in YY (00-99) |
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
// This code is designed to be dropped into Xcode snippets. Paste the code into an Xcode document | |
// and then drag it onto the Code Snippet library to create a snippet with prompts. | |
var <# variable name #>: <# variable type #> { | |
get { | |
return <# value to return #> | |
} | |
set { | |
// "newValue" is the value that was passed into this variable to be set and is automagically available to you | |
var <# value to set #> = newValue |
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
// MARK: - VARIABLES - | |
// MARK: - INITIALIZATION - | |
// MARK: - PUBLIC METHODS - | |
// MARK: - PRIVATE METHODS - | |
// MARK: - DELEGATE METHODS - | |
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
# app/views/controller_name/index.json.jbuilder | |
json.array!(@pose_blocks) do |pose_block| | |
if pose_block.published == true | |
json.extract! pose_block, :unique_id, :name, :pose_id_for_cover_image, :video_duration, :video_size, :duration | |
json.focus_type pose_block.focus_type.name | |
json.ability_type pose_block.ability_type.name | |
json.poses pose_block.pose_block_poses.each do |pose_block_pose| | |
json.unique_id pose_block_pose.pose.unique_id | |
json.duration pose_block_pose.duration |