Motorcycle Adventures and Free Software

Weblog: Archive

2007-09-01 - 2007-09-30

Creation mode for Midgard's chooser widget

Posted on 2007-09-11 14:24:46 UTC in 60° 9.840 N 24° 44.190 E 7km S of Espoo, FI to . 0 comments.

Midgard's datamanager2 form handling library has a very nice jQuery-powered chooser widget which enables search-based selections. This is often used in situations where the data set user is choosing from is large, as is often the case when selecting persons from a large organization for instance.

Today we added creation support for the chooser to deal with situations when no matches were found.

Here is a quick example of adding related event from calendar into a news item. The chooser for doing this appears as a search box:

Chooser-Related-Events

Typing a query does a live search which presents the results below. Items can be chosen either by clicking or with keyboard:

Chooser-Search

If the desired result was not found, clicking the "+" icon opens a window for creating a new event:

Chooser-Creation-Iframe

Once the event has been saved the window will close and the newly created item will be placed as a chosen item in the chooser:

Chooser-Related-Events-Created
(yes, we still need to fix start and end timestamp rendering here)

Creation mode support has been added only to net.nemein.calendar so far, but we will add it to other places as the need arises.

Enabling creation mode in a chooser is relatively simple. Just point the chooser to the appropriate creation URL in the datamanager schema:

'widget' => 'chooser',
'widget_config' => array
(
  'clever_class' => 'event',
  'creation_handler' => '/event_calendar/create/chooser/event',
), 

The UI model used here closely resembles how Yahoo's Upcoming handles addition of new event venues:

Upcoming-Add-New-Venue

Technorati Tags: ,

Sponsored links

Microsoft Certification Exams โนเกีย Nokia มือถือ Online Project Management save money using, phone card
Reviews มือถือ Mobile All Apps

Position editing widget for Midgard

Posted on 2007-09-14 11:48:13 UTC in 60° 9.840 N 24° 44.190 E 7km S of Espoo, FI to . 0 comments.

Midgard has had quite cool GeoCMS features for a while now: any objects can be positioned and retrieved via position, and maps are easy to display anywhere. We also can use cool services like Plazes for automatically positioning new content created by users.

However, what has been lacking has been a way to easily edit the location of an item in the CMS. This has been now fixed by the new position widget we did with Jerry:

Position-Widget-Address

An easy way to position objects is to enter a civic location that will then be geocoded using either local city database, GeoNames or Yahoo! The civic location properties used are the same as in XEP-0080 specification and GeoClue.

To do this, enter an address and click the "refresh" icon in the corner, then wait a while:

Position-Widget-Address-Retrieve

Some details (like the postal code in above example) will appear if the geocoding service provides those (as happens with Yahoo!). You can then check the location by going to the Map tab:

Positioning-Widget-Map

The map is provided by Mapstraction, and so different providers like Google Maps, Yahoo! and OpenStreetMap can be used. If you want to correct or fine-tune the position, just click somewhere else on the map:

Positioning-Widget-Map-Edit

You can also edit the straight coordinates:

Positioning-Widget-Coordinates

Get it from SVN while it is hot!

Technorati Tags: , , ,

Hiking in the weekend

Posted on 2007-09-17 06:03:10 UTC in 60° 10.524 N 24° 55.146 E Helsinki, FI to . 0 comments.

The "ruska season" has now started and so we decided to go hiking in the Evo area last weekend.

On Hakovuori

Pretty nice trip of walking in the woods and enjoying songs, pipe and whisky at fireside. We slept the first night in tent and the second in a laavu:

First bite

Weather was a bit rainy on Saturday, but with good gear this was not much of a problem. More pictures on Flickr.

Technorati Tags: , ,

Web CMSs: what does Midgard do?

Posted on 2007-09-17 10:30:59 UTC in 60° 9.840 N 24° 44.190 E 7km S of Espoo, FI to . 0 comments.

Column Two has an interesting post titled What does a web CMS do? with a table listing features that are integral to a web CMS, and what can be handled separately.

I thought to list how Midgard handles those:

Capability Midgard way of handling
Authoring and publishing web pages Yes, definitely
Multimedia content Midgard can manage images and video to a simple extent
Personalisation Easy to do via the API
Online forms Multiple handlers available, like email forms, event registration and incident reporting
Online calendar Yes, with quite comprehensive feature set
Blogs Built-in, with RSS in and out, geoblogging and commenting
Search Midgard uses the Lucene search tool
Collaboration tools OpenPsa can be used to some extent
Wikis Midgard provides a quite nice wiki
Web 2.0 functionality Depends on definition, we have OpenID, social networking (with some portability), voting and other related features
Mailing lists Midgard's discussion forum can act as mailing list front-end
E-commerce functionality Midgard has a product database and provides a simple shopping cart built-in
Corporate document/records management No, whole market of its own
Digital asset management (DAM) No, obtain separately
Usage statistics No, obtain separately

The fact that Midgard supports almost everything listed may sound like bloat, but we actually do this quite elegantly because of the component architecture that enables site builders to pick and use whatever pieces of functionality they need.

jQuery and CouchDB

Posted on 2007-09-23 11:52:11 UTC in 60° 10.524 N 24° 55.146 E Helsinki, FI to . 0 comments.

CouchDB is a very interesting evolution in open source data storage: an ad-hoc document database with replication support. I heard the first time about CouchDB when Jan Lehnardt was presenting it in FrOSCon a month ago, and became immediately very interested.

The database is available for various different platforms, and provides a RESTful JSON API, which makes it very easy to access basically from any programming languages. To make things even simpler, access libraries have emerged for various languages like PHP and Ruby.

This weekend Jerry Jalava released a jQuery CouchDB access library. This is an important step for us as Midgard is already making the jQuery migration, and we are considering to use CouchDB for a project.

Couch-Hacking

So, why CouchDb? First of all, it is something new and interesting. And it is multiplatform and replicated, meaning that we should be able to get our data everywhere, from a web server to Mac desktop to an Internet Tablet. Besides regular database usage, some of the PHP code deployment ideas are also promising.

Technorati Tags: ,

Sometimes a thumbs down is needed

Posted on 2007-09-25 07:00:59 UTC in 60° 9.840 N 24° 44.190 E 7km S of Espoo, FI to . 0 comments.

Quim wrote earlier on why red hearts matter in maemo news. The red hearts are important as they bring important news items forward in the maemo social news aggregator. But sometimes there are also news items that are not at all relevant to the maemo community. To solve the problem with them we've now added a burying option:

Socialnews-Favbuttons

When you click the "Thumbs down" icon the item will enter a recalculation queue, and will soon disappear from the social news main page. It will of course remain in the news feed it came from, so everything for example coming from Planet maemo subscriptions will stay there.

The item will also be marked as buried for you:

Socialnews-Unfaved-1

Also related to the Social News service is that the best of maemo news highlights is now available for browsing. Go and check out the most popular items related to the project!

Technorati Tags: , ,

Back