use form_for in dialog
Merge pull request #10 from Vdimir/master

use form_for in dialog