PDA

View Full Version : CityBars Example: A first look at Designer 2



Phil.Strong
10 Feb 2012, 8:25 AM
Please use this forum thread to ask questions specific to the CityBars example talked about here (http://www.sencha.com/blog/sencha-designer-beta)

1. Please be sure to replace the yelp api key in the getBusiness function
http://cl.ly/2G0u0K1H163g3V00431d
I believe I may have included mine in the xda you can download but know that after 150 uses for the day it simply won't work.

2. Troll around and ask questions about things you don't understand. A designer developer or a community member should be able to help

UPDATE:
Make sure you move all of your init code from the Business Controller into launch!

snorre
21 Feb 2012, 2:02 AM
Hi Phil,

thanks to you and the team for producing such material which gives me fast and productive relevant information hands-on. I learned a lot very quick about the using of Sencha Designer watching this video.

There are still lot of questions open, so i think we will see us again here :)

Thanks for all your work till now in this fab framework,
Stefan

kebuu
23 Feb 2012, 7:00 AM
Hello,

Thank you for this very interesting video. The designer seems very powerful and intuitive.

I followed the tutorial step by step and managed to get my app running on a local server. Although everything works fine when I access the application from Chrome, I find it very slow when I access it from my iphone (using Safari).

Do you have the same behavior ?

Regards

PS: just to let you know, my iphone is a 3G.

Phil.Strong
24 Feb 2012, 9:07 AM
I didn't find it slow but alas I was using a 3GS and not a 3G ... huh

Of course it's not as fast as my MBP running chrome but then again it never is.

Anyone else with 3G try this?

satishs
28 Feb 2012, 8:01 PM
Phil,

Is sencha-touch-designer-edition under extjs.cachefly.net/touch/ different from sencha-touch 2.0 beta 3 or rc?. As soon as I change the Designer html to point to my /lib/sencha2.0 location, code stops working.

Just trying to understand, couldn't find answer anywhere.

Thanks,
ST

aconran
28 Feb 2012, 8:28 PM
ST -

The only difference is that we've moved the two additional files in the webroot of the distro into the builds directory so that all 5 builds that Sencha Touch ships with are in the same directory. This will be changing in a future release.

aconran
28 Feb 2012, 8:29 PM
Take a look at the debugger when loading the page and see if any files are 404'ng

amussini@gmail.com
3 Mar 2012, 6:46 AM
Hi guys,
I still have a little problem on the CityBars example.
When I tap on an item, I receive a message:

Uncaught TypeError: Object #<Object> has no method 'Create'

The incriminated row is here:



var me = this;
if (record) {
if (!me.details) { me.details = Ext.Create('CityBars.view.DetailPanel',{ //ERROR title: 'Dettagli' });
}
//setto la mappa? var map = me.details.child('#detailMap'); map.setMapOptions({ zoom:17 });
map.setMapCenter({ latitude: record.get('latitude'), longitude: record.get('longitude') });
// set info var info = me.details.child('#contact').child('#info'); info.child('#photo').setData(record.data); info.child('#data').setData(record.data);
me.getMainNav().push(me.details);
}


Have any idea? On what it can depends on?
Thanks a lot, the screencast is anyway great and helpful

amussini@gmail.com
3 Mar 2012, 7:56 AM
The problem explained was solved, it was a upper case in Ext.Create ... obviously it was Ext.create.

shoebox
4 Mar 2012, 3:26 AM
The app doesn't seem to work on Android 2.3.3. When visiting via mobile browser is loads the mainnav (I see the main nav title) but then nothing in the list loads. I've tried it both in the browser and running as phone gap launch via eclipse.

edwardk
16 Mar 2012, 2:28 AM
Hi - thanks for the video (https://vimeo.com/36420727) I folloed it yesterday with the 90 day trial version of Sencha Designer and tried it on my localhost without success. I'm running Chrome 17.0.963.79 m which I think is the latest version.
I have a Yelp api key that I made.
I thought that because I live in a remote area that there might not be enough bars in the google zoom level of 17 so I decreased that to 5 in the hope that it would look over a large area.
I have checked on Yelp and being in the UK I noticed that the term 'Pubs' is used instead of 'Bars' so I tried that too - no luck.
Now I've downloaded the example code and tried it out of the box and with the above changes too - no luck.
I get a screen with 'CityBars' at the top and then nothing else on the screen.
I've checked the network panel in the Chrome debugger (F12) and it appears to be pinging google maps but not yelp - I'm not sure if I should be seeing any yelp activity?
From looking around in the debugger I can't see any other errors.
Any help?

Phil.Strong
16 Mar 2012, 7:23 AM
Be sure you've moved all of the code that's in init (video) into launch function of main controller

Also check to be sure your functions are being called by putting alerts in there

edwardk
16 Mar 2012, 8:26 AM
Thanks Phil - I'll have a look. I've tried the 'carstore' example and that works a treat (but using json/local data).
If I highlight the main controller in the Project Inspector (called 'Business' just under 'Controllers') and then go to 'code' and then 'init' there is a some code for getting the location, getting the yelp data and then binding that to the list and showing it.

If I then change to the launch function there is no code in there - both in my code and in the downloaded example. Should I move the init code into the launch function?

I'll try some alerts...
Thanks
Ed

Phil.Strong
19 Mar 2012, 8:32 PM
Yes cut what's in init and paste it in launch

PhilMerrell
29 Mar 2012, 7:52 AM
I'm experiencing the simliar results. I see the mainNav bar with "CityBars" at the top, and then it looks like the mask is being applied (there's an translucent overlay) but without the "loading..." text.

When I cut and paste the code from init to the launch function of the application, I get a grey screen (possible black translucent) without the mainNav bar at the top.

I really like the Sencha Touch, and Designer products. I really want to invest the time in learning how to use this framework, as I think it is far superior to anything else on the market, but this is the second tutorial I've followed that has been out dated (the other one being Ed Spencer's talk from Senchacon 2011). It's frustrating to spend half a day on a tutorial and have it not work when you've followed the instructions.

Other than the demo not working, this is a good tutorial. I do feel more familiar with the framework, but it is very unsatisfying that it doesn't work.

edwardk
29 Mar 2012, 8:18 AM
Yeah I never got it to work - still working with Sencha Designer 2 on the beta trial and down to 80 ish days. Writing an example that will use a mysql database to provide data via json - more useful for my needs and so far so good... Might post it for critique once I've got a bit further...

rojalin@ceptes.com
1 Apr 2012, 10:41 PM
Hi,
I have exactly followed the CityBar example document,but it is not working for me.Is it necessary to give the yelp userId or whatever there in the example will be fine .

aconran
2 Apr 2012, 8:14 AM
Is it necessary to give the yelp userId

Yes you must register for your own yelp key and use that.

rojalin@ceptes.com
2 Apr 2012, 8:34 PM
Hi,
Thanks for reply,but each time I am trying to register getting the following error

'Oops, Yelp is overworked right now.'

Is this possible get the yelp data in other format .Do you have any default yelp API key to use.

Thanks

Phil.Strong
4 Apr 2012, 6:54 AM
I'd say give it some time and try again. Not sure what's going on w/ Yelp