text
stringlengths 1
80.5k
⌀ |
---|
In fact, according to IHS, sales of the iPod reached peak levels after the iPhone launch, with more than 22 million of the devices shifted in the fourth quarter of 2008. |
Image copyright Other Image caption The iPod has even inspired ambitious fancy dress |
And even today, despite that dramatic 52% fall, the iPod range still generates big revenues - $973m (£587m) in the last quarter. |
Analysts say it has remained popular for a multitude of reasons that go beyond simply price. The iPod Touch, for instance, is seen as the iPhone-that's-not-a-phone, so to speak - offering everything an iPhone does but without cellular capability. |
"The iPod touch today is a great way of appealing to younger consumers that are maybe too young to have an iPhone," suggests Mr Fogg. |
"It's getting them on board with Apple, getting them downloading apps from the App Store." |
New products needed |
But $973m out of Apple's total revenues this quarter - $57.6bn (£34.7bn) - is just a minor sideline or, as technology news site The Verge put it, "a hobby". |
Which leads most people in-the-know to predict that while Apple may not discontinue the iPod in the very near future, we're unlikely to see any kind of significant update of the devices. |
"As long as the iPod can stay a quality product and not have them lose money, I really don't see any reason for them to kill it," argues Alex Heath, a writer for Cult of Mac. |
But Mr Heath and others stress that since the iPod can no longer be seen as a major Apple product line, Tim Cook needs to introduce an entirely new product if he is to keep investors - and fans - on his side. |
Image copyright APple Image caption Apple has patented what looks like smart watch technology |
"They're going to need to branch into new categories," says Eric Slivka, editor in chief of MacRumors.com. |
"An Apple TV has been on the radar for a long time, and now it seems rumours like the iWatch and other wearables are starting to take over." |
Mr Heath adds: "It's looking like, unless there some production issues, Apple is on track to release some kind of wearable, by late 2014. |
"It will either send Apple's stock soaring, or crash it. 2014 is going to be a very interesting year." |
Follow Dave Lee on Twitter @DaveLeeBBC |
UPDATE: |
STRETCH GOALS: |
$2500 - Tiers $25 and up, each get an extra regular ticket. (REACHED!) |
$3000 - Q&A With Director, Writer, and Actors at Premiere. |
(REACHED!) |
$3500 - Double Stickers for everyone, and all tiers above $10 receive a copy of all the advertising posters. (edited) |
$4000 - Second Showing in Saskatoon. |
UPDATE#2 |
Teaser Trailer : Here |
What is Daimons? |
Daimons is a short film which explores The Seven Deadly Sins as personified beings, and attempts to present them in a different light. What would a being be like if they were to embody a sin? How would they live? What would they believe? How would they interact with others? Daimons uses the medium of short film to try and answer these questions. |
The entire cast and crew are all local talent in Saskatoon, Sk. |
How is it going to be released? |
The plan for Daimons is to release the first seven episodes online, in order. For the final episode, we will have a large showing of the short film in its entirety, including this final scene, in our hometown of Saskatoon. We also hope to be able to take the film across Canada at some point in the near future. The final episode will eventually be released publicly online, but backers will receive early access. We will also be creating a YouTube channel that will have behind the scenes shots and interviews |
from the cast and crew. We have already found a cast of talented local artists, and we have camera people, costume people, and music people, who are all donating there time to help make the best film we can. We have already begun shooting, and by the time this Kickstarter is finished, we will have concluded the filming. |
Why do we need your help? |
Why we are asking for your help now is to assist us through the post production. With your money we could dedicate more time and effort towards post and start releasing sooner. If the Kickstarter proves successful early on we can also start committing more money to props, costumes, and hopefully be able to give back to the crew. On top of this, extra funding can help us after the premiere by allowing us to go to film festivals and showing Daimons across the country. |
Rewards |
Stickers - High quality die cut stickers. One of each character, and one of the Title. |
Tickets - Tickets to our Premiere. These will be available at the door as well for a raised rate. |
VIP Tickets - Best seats in the house! Reserved seating and preferential treatment. Complimentary snacks for bigger backers. |
Posters - A full size glossy12x18 of the movie poster. Soundtrack - Physical and Digital copy of the soundtrack. |
DVD - Physical copy of the DVD, with regular size case. Includes behind the scenes and interviews with the cast. |
Producer Credits - You get your name in the credits! The more you donate, the further up your name goes, with the biggest backers getting their name in the beginning of the credit roll. |
President Donald Trump called for “global warming” on Thursday because it is cold in the northeastern United States. “In the East, it could be the COLDEST New Year’s Eve on record,” Trump tweeted. “Perhaps we could use a little bit of that good old Global Warming that our Country, but not other countries, was going to pay TRILLIONS OF DOLLARS to protect against. Bundle up!” The tweet is in apparent reference to the Paris Agreement, a massive climate pact from which Trump withdrew earlier this year. Trump |
has previously expressed skepticism about the existence of climate change, a view that puts him at overwhelming odds with the scientific community, as well as his own administration’s researchers. Last month, government scientists released a climate change study forecasting devastating changes to weather patterns as the result of human activity. “It is extremely likely that human influence has been the dominant cause of the observed warming since the mid-20th century,” the report reads. “For the warming |
over the last century, there is no convincing alternative explanation supported by the extent of the observational evidence.” |
Salesforce can be a tricky but powerful tool. Using JSForce and some custom triggers you can integrate Salesforce with your custom NodeJS web application for better business management. |
Setting Up |
There are two sides to this application: the NodeJS application, which in our case will be the customer facing side, and the Salesforce side, which will be used to manage the business relations and tracking. Both of these pieces need a little bit of set up before we get started. In this example we will be using NodeJS snippets with the Koa framework, Handlebars for rendering html, and client side interaction written with ReactJS. We are also using the es6 syntax and are using gulp to compile to es5. In the |
following section we will set up the node application. |
Obviously you have to have a Salesforce license to access the Salesforce platform. Once you have the license you can begin by deciding what objects you want to model. Once you log in to Salesforce the main page, you will use is the "Setup" page. You can get to this from the menu on the top right. |
The "Setup" page is where you will spend most of your time developing for Salesforce. Almost all of the functionality for developing can be found across the bar on the left. Sections can be expanded for more options. I will frequently reference the "Setup" page throughout the guide. |
One of the first things you will need to do in Salesforce is create the custom objects. This is fairly simple because there is a wizard used to create custom objects. Often these objects will mirror tables in your local database. As a general rule, when you create objects in Salesforce that will be mirrored in your custom application you will need some way to keep them synced. To keep them synced, you need a shared ID of some sort. This can be stored as an external ID in Salesforce. This external ID can be |
used for update, insert, and even upsert operations. You can also use the external ID's to find relationships between objects. |
Some basic routes |
The first part we will set up is our customer facing site. This will be built with NodeJS, Handlebars, and React. In our example, we are adding the ability to add a "Widget" on our site and have that information propagated to Salesforce as a custom object. In order to do this, we will create 2 routes. One for the form to add the widget and a second to save the information. When the information is saved, we use the node JSForce library to send the information to Salesforce. |
./src/server.js |
const koa = require ( 'koa' ); const koaBody = require ( 'koa-body' ); const logger = require ( 'koa-logger' ); const hbs = require ( 'koa-hbs' ); const router = require ( 'koa-router' ); const React = require ( 'react' ); const salesForce = require ( './salesforce.js' ); const app = koa (); app . use ( logger ()); app . use ( router ( app )); app . use ( hbs . middleware ({ defaultLayout : 'main' , viewPath : __dirname + '/../views' , layoutsPath : __dirname + '/../views/layouts' , partialsPath : __dirname |
+ '/../views/partials' })); const WidgetForm = React . createFactory ( require ( reactDirectory + '/widget' )); app . get ( '/edit-widget' , function * () { yield this . render ( 'widget-form' , { title : 'Widget' , widgetForm : React . renderToString ( WidgetForm ()) }); }); app . post ( '/save-widget' , koaBody (), function * () { const widget = this . request . body ; //validate widget - if invalid return errors //save widget to database, add to "widgetContainer" parent container const savedWidget = db . |
save ( widget ); const widgetContainer = getParent ( widget ); salesForce . addWidget ( savedWidget , widgetContainer . id ); }); |
We use handlebars to handle some of the layouts and script inclusion. This allows for isomorphic rendering with node and react. Below is the main layout with a section where we can include scripts at the page level. |
./views/layouts/main.hbs |
<!DOCTYPE html> <html> <head> <title> {{title}} </title> <meta charset= "utf-8" > <meta http-equiv= "X-UA-Compatible" content= "IE=edge" > <meta name= "viewport" content= "width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no" > </head> <body> {{{body}}} {{#block "scripts"}} {{/block}} </body> </html> |
Creating a Form to submit |
Now that we have the routes set up and the main layout we can create the form with react. First we create the hbs template for the isomorphic render. |
./views/widget-form.hbs |
<div class= "container" > <div id= "add-widget-form" > {{{widgetForm}}} </div> </div> {{#contentFor "scripts"}} <script type= "text/javascript" > React . render ( React . createElement ( Widget ), $ ( '#add-widget-form' )[ 0 ]); </script> {{/contentFor}} |
const React = require ( 'react/addons' ); const _ = require ( 'lodash' ); const Widget = React . createClass ({ getInitialState () { return { widgetName : '' , widgetData : '' , submitting : false , errors : {}, success : false }; }, handleWidgetNameChange ( e ) { this . setState ({ widgetName : e . target . value , errors : {}}); }, handleWidgetDataChange ( e ) { this . setState ({ widgetData : e . target . value , errors : {}}); }, handleSubmit ( e ) { e . preventDefault (); this . setState ({ submitting |
: true }); const data = _ . omit ( this . state , [ 'errors' , 'submitting' , 'success' ]); $ . ajax ({ type : 'POST' , url : '/save-widget' , data : JSON . stringify ( data ), dataType : 'json' , contentType : 'application/json; charset=utf-8' }). done (() => { this . setState ({ submitting : false , success : true , errors : {} }); }). fail ( result => { this . setState ({ submitting : false }); if ( this . isMounted () && result . responseJSON . validationResult ) { this . setState ({ errors : result . |
responseJSON . validationResult }); } }); }, render () { return ( < div className = "widget-form-container" > { this . state . success ? < h3 className = 'success' > Widget Saved ! < /h3> : < h3 > Add Widget < /h3>} < div className = "error-info" > < ul className = {( _ . size ( this . state . errors ) < 1 ) ? 'hide' : '' } > { _ . map ( this . state . errors , ( v , k ) => < li key = { k } > { v } < /li>)}</ul> < /div> < form className = { 'widget-form' + ( this . state . success ? ' hide' : '' )} onSubmit |
= { this . handleSubmit } > < div className = "input-row" > < label htmlFor = 'title_copy' > Widget Name < /label> < input className = { this . state . errors . widgetName ? 'error' : '' } name = 'widgetName' defaultValue = { this . state . widgetName } onChange = { this . handleWidgetNameChange } type = 'text' autofocus /> < /div> < div className = "input-row" > < label htmlFor = 'title_copy' > Widget Data < /label> < input className = { this . state . errors . widgetData ? 'error' : '' } name = |
'widgetData' defaultValue = { this . state . widgetData } onChange = { this . handleWidgetDataChange } type = 'text' /> < /div> < div className = 'input-wrap' > { this . state . submitting ? < i className = "fa fa-spinner fa-spin fa-3x" >< /i>: < input type = 'submit' name = 'Save Widget' value = 'Save Changes' /> } < /div> < /form> < /div> ); } }); module . exports = Widget ; if ( typeof window !== 'undefined' ) { window . Widget = Widget ; } |
At this point the application should be functioning with a page to add widgets. This guide doesn't focus on the node side of this as I would like to cover more of the interaction with Salesforce. |
Converting to Salesforce Objects |
Salesforce uses Objects to do most of the work. Everything from contacts to purchases is modeled by an object. In order to represent our Widgets we will need to create a custom object. To do this go to the "Setup" page and click on the "Create" tab on the left to reveal the link to "Objects". |
You can then click "New Custom Object". |
This wizard is simple enough, just be aware of the name that the Salesforce API will be using is generated as a part of this process as the "Object Name" field. |
The process of figuring out API information can be a little daunting at first because finding the correct names and the relations between objects can be difficult to understand. JSForce provides a describe query that can help you to find this information. You can also find information by browsing the objects on the Salesforce site. They provide a "Schema Builder" tool (found on the "Objects" page) to view the relations between objects. In our example, we create a Widget object and a parent container for the |
widgets to demonstrate how to handle relations. So we created a new custom object and gave it a few fields including a name, a custom data field, and a field to tell if it had been sold. To create the relationship, we create a lookup field to the parent object. Lastly, we make sure that the API names are correct so we can use them for the JSForce queries. |
JSForce |
JSForce allows us to communicate from our node application to the Salesforce platform. Once you enter your account information for the connection, you can begin using their API to access Salesforce. The JSForce API allows us to access the Salesforce SOAP API through a neatly packaged javascript library. The JSForce documentation covers the main operations that will be used including CRUD operations, querying, and search. The describe and identity functions are also helpful for finding information about |
objects in Salesforce. Once we have the necessary information we can build the interaction from our site to Salesforce. |
Sending data to Salesforce |
We created a separate module for any queries to Salesforce. Using the upsert, we can call this code for either insert or update of records, if we are given the external ID. For more examples, you can look at the JSForce documentation. |
const jsforce = require ( 'jsforce' ); const jsConn = new jsforce . Connection (); //From: https://jsforce.github.io/document/#connection jsConn . login ( '<salesforce username>' , '<salesforce password>' ); module . exports = { addWidget ( widget , widgetParentId ){ const widgetContainer = yield jsConn . sobject ( 'pba__WidgetContainer__c' ). select ( '*' ). where ({ External_ID__c : widgetParentId }); const widgetSF = { Name : widget . name , Custom_Field__c : widget . custom_data , External_ID__c : |
widget . id , Widget_Container__c : widgetContainer . Id }; return yield jsConn . sobject ( 'pba__Widget__c' ). upsert ( widgetSF , 'External_ID__c' ); } }; |
Getting Results Back from Salesforce |
The result that you get back from Salesforce can be used for error checking and for getting more information. You can request other information like the Salesforce ID. The errors that are returned are helpful in diagnosing problems with queries, variable naming, or even with types of data. |
How Does Salesforce Communicate Out? |
One way to send messages and data out is to use triggers. Triggers respond to changes on Salesforce Objects and can be used to call Apex code. Apex code in turn can then send outbound http requests. Apex provides this functionality through the HttpRequest class. |
Dev Sandbox and Deploys |
In order to develop any Apex code you must first create a development sandbox. This can be found by going to the "Setup" page and then to the "Sandboxes" Page. |
Any code that you develop as an Apex class or trigger is created here. Salesforce provides a useful developers console that features syntax highlighting, autocompletion, and predictive suggestions. These can be very helpful when developing with Apex Libraries. |
The process for deploying from the sandbox can be a little confusing though. Once you have finished your code, sufficiently tested it, and are ready to deploy, you can follow these steps: |
1.Create an outbound change set by going to the "Setup" page and clicking "Outbound Change Sets" under the "Deploy" section on the left. |
2.Add components to the change set. You can also check the option to add any dependencies. This will include any Objects, Classes, or other related code that is used in the element that you are adding. This can be useful to ensure that any custom fields or objects used to create the trigger will be included in the change set. |
3.Once all of the elements are added, click "Upload" to finish the development side of the deploy. |
4.Switch back to the production site and go to the "Setup" page. 5.On the "Setup" page in the "Deploy" section select "Inbound Change Sets". |
6.At this point you should see the change set in the "Change Sets Awaiting Deployment" section. There is a link to deploy the change set that you should click to finish the process. |
If your code did not contain tests, the deploy will fail and alert you to the required coverage for test cases. If your code has tests, is valid, and the deploy succeeds, it will eventually show up in the "Deployed Change Sets" Section and will be currently active. The changes can take up to 30 minutes to propagate after this process, so testing is essential for saving time and effort. Also, you can save a lot of time during the deploy if you use the developer console to catch errors and run tests before |
the deploy. |
Preparing for a Trigger |