Skip to content

Instantly share code, notes, and snippets.

View brendanmckenzie's full-sized avatar

Brendan McKenzie brendanmckenzie

View GitHub Profile
commit d8811801fb3af61bb1fc5b3dd87b0feab1a135a0
Author: Brendan McKenzie <hello@brendanmckenzie.com>
Date: Tue Jun 26 08:51:17 2012 -0400
project updates
commit e8bd26a4d8fc58ba84c8366e11e744062194d901
Author: Brendan McKenzie <hello@brendanmckenzie.com>
Date: Tue Jun 26 11:00:43 2012 -0400
[HttpPost]
public ActionResult EditInvoice(Invoice invoice, string subaction)
{
ViewBag.Section = "Portfolio";
ViewBag.Page = "Invoices";
if (!string.IsNullOrEmpty(subaction))
{
ModelState.Clear();
modelBuilder.Entity<Organisation>().HasKey(e => e.OrganisationId).Property(e => e.OrganisationId).HasColumnName("OrganizationId");
modelBuilder.Entity<Organisation>().ToTable("Organization");
public IEnumerable<T> ExecuteStoredProcedure<T>(string name, object parameters)
{
if (parameters != null)
{
var _parameters = parameters.GetType().GetProperties().Select(x => new SqlParameter()
{
ParameterName = x.Name,
Value = x.GetValue(parameters, null)
}).ToArray();
public struct TimePeriod
{
public int? Minute { get; set; }
public int? Hour { get; set; }
public int? DayOfMonth { get; set; }
public int? Month { get; set; }
public int? DayOfWeek { get; set; }
public bool IsNow()
{
root@vvps-783308:/var/www# apt-get install mysql-server-5.1
Reading package lists... Done
Building dependency tree
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:
{
"0": {
"name": "Me",
"father": "1",
"mother": "2"
},
"1": {
"name": "Father",
"father": "3",
"mother": "4"
public class TeamLeaderboard : Control, INamingContainer
{
#region Properties
const string ChangePageCommand = "ChangePage";
const string UpdatePanelID = "TeamLeaderboardUpdatePanel";
static Principal Principal { get { return HttpContext.Current.User as Principal; } }
const int PageSize = 25;
$(window).load(function () {
$('.leaderboard').each(function () {
var leaderboard = this;
leaderboard.state = 'closed';
$('.flexslider', leaderboard).flexslider({
animation: "slide",
animationLoop: true,
Africa
• Algeria
• Angola
• Benin
• Botswana
• Burkina Faso
• Burundi
• Comoros
• Djibouti
• Cameroon