make item edit form neater
This commit is contained in:
parent
c00a619ab4
commit
ac3fe18054
|
@ -78,9 +78,14 @@ function getJQ(f) {
|
|||
|
||||
function getItemForm(f) {
|
||||
var $form = $('<div />').addClass("itemForm");
|
||||
var $title = $('<input />').val(f.title).appendTo($form);
|
||||
var $description = $('<textarea />').val(f.description).appendTo($form);
|
||||
var $submit = $('<input />').addClass("submitItem").attr("type", "submit").val("Submit").appendTo($form);
|
||||
var $titleP = $('<p />').appendTo($form);
|
||||
var $titleLabel = $('<span />').addClass("itemFormLabel").text("Title: ").appendTo($titleP);
|
||||
var $titleInput = $('<input />').val(f.title).appendTo($titleP);
|
||||
var $descriptionP = $('<p />').appendTo($form);
|
||||
var $descriptionLabel = $('<span />').addClass("itemFormLabel").text("Description: ").appendTo($descriptionP);
|
||||
var $descriptionInput = $('<textarea />').val(f.description).appendTo($descriptionP);
|
||||
var $submitP = $('<p />').appendTo($form);
|
||||
var $submit = $('<input />').addClass("submitItem").attr("type", "submit").val("Submit").appendTo($submitP);
|
||||
return $form;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user