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 express = require('express'); | |
const bodyParser = require('body-parser'); | |
const app = express(); | |
const PORT = process.env.PORT || 5000; | |
app.use(bodyParser.json()); | |
app.use(express.static('www')); | |
app.get('/property', (req, res) => { | |
let sql = "SELECT * FROM salesforce.Property__c WHERE Status__c='Available'"; |
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
[ | |
{ | |
"category": "Cat 1", | |
"questions": [ | |
{ | |
"points": 100, | |
"question": "q1", | |
"answer": "a1" | |
}, | |
{ |
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
public with sharing class SlackOpportunityPublisher { | |
private static final String slackURL = 'YOUR_WEBHOOK_URL'; | |
@InvocableMethod(label='Post to Slack') | |
public static void postToSlack(List<Id> opportunityId) { | |
Id oppId = opportunityId[0]; // If bulk, only post first to avoid overloading Slack channel | |
Opportunity opportunity = [SELECT Name, StageName from Opportunity WHERE Id=:oppId]; | |
Map<String,Object> msg = new Map<String,Object>(); | |
msg.put('text', 'The following opportunity has changed:\n' + opportunity.Name + '\nNew Stage: *' |
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
import {OnInit} from 'angular2/core'; | |
import {Page, NavController, NavParams} from 'ionic/ionic'; | |
import {PropertyDetailsPage} from '../property-details/property-details'; | |
import {PropertyService} from '../../services/property-service'; | |
@Page({ | |
templateUrl: 'build/pages/property-list/property-list.html' | |
}) | |
export class PropertyListPage { |
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
public with sharing class SlackOpportunityPublisher { | |
private static final String slackURL = 'YOUR_WEBHOOK_URL'; | |
public class Oppty { | |
@InvocableVariable(label='Opportunity Name') | |
public String opptyName; | |
@InvocableVariable(label='Stage') | |
public String stage; | |
} |
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
<aura:component controller="CandidateController" implements="force:appHostable"> | |
<ltng:require styles="/resource/slick/slick.css,/resource/slick/slick-theme.css" | |
scripts="/resource/jquery,/resource/slick/slick.min.js" | |
afterScriptsLoaded="{!c.doInit}"/> | |
<aura:attribute name="contacts" type="Contact[]"/> | |
<div class="carousel"> | |
<aura:iteration items="{!v.contacts}" var="contact"> |
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
<aura:component implements="force:appHostable"> | |
<ltng:require styles="/resource/leaflet/leaflet.css" /> | |
<ltng:require scripts="/resource/leaflet/leaflet.js" | |
afterScriptsLoaded="{!c.jsLoaded}" /> | |
<div id="map" class="map"></div> | |
</aura:component> |
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
IF(ISBLANK(Implemented_Date__c), TODAY() - DATEVALUE(CreatedDate) , Implemented_Date__c - DATEVALUE(CreatedDate) ) |
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
public class SpeakerControllerExtension { | |
public blob picture { get; set; } | |
public String errorMessage { get; set; } | |
private final Speaker__c speaker; | |
private ApexPages.StandardController stdController; | |
public SpeakerControllerExtension(ApexPages.StandardController stdController) { | |
this.speaker = (Speaker__c)stdController.getRecord(); |
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
var app = { | |
findByName: function() { | |
this.store.findByName($('.search-key').val()).done(function(employees) { | |
var l = employees.length; | |
var e; | |
$('.employee-list').empty(); | |
for (var i=0; i<l; i++) { | |
e = employees[i]; | |
$('.employee-list').append('<li><a href="#employees/' + e.id + '">' + e.firstName + ' ' + e.lastName + '</a></li>'); |
NewerOlder