extends ../../layout/main block view-content section.uk-section.uk-section-default.uk-section-small .uk-container .uk-margin - var actionUrl = !!project ? `/client/${client._id}/project/${project._id}` : `/client/${client._id}/project`; form(method="POST", action= actionUrl).uk-form .uk-card.uk-card-default.uk-card-small .uk-card-header div(uk-grid).uk-grid-small.uk-flex-middle .uk-width-expand h1.uk-card-title #[span= !!project ? "Edit" : "New"] Project .uk-width-auto div #{client.name} .uk-card-body .uk-margin label(for="name").uk-form-label Project name input( id="name", name="name", type="text", value= !!project ? project.name : undefined, placeholder="Enter client name", ).uk-input .uk-margin label(for="description").uk-form-label Project description textarea( id="name", name="description", rows=4, placeholder="Enter client description" ).uk-textarea.uk-resize-vertical= !!project ? project.description : "" .uk-margin div(uk-grid) .uk-width-1-2 label(for="hourly-rate").uk-form-label Hourly rate input( id="hourly-rate", name="hourlyRate", type="number", value= !!project ? project.hourlyRate : undefined, placeholder="Enter hourly rate", ).uk-input .uk-width-1-2 label(for="hours-limit").uk-form-label Max. hours per week input( id="hours-limit", name="hoursLimit", type="number", value= value= !!project ? project.hoursLimit : 40, placeholder="Enter max. hours/week", ).uk-input .uk-card-footer.uk-flex.uk-flex-right button(type="submit").uk-button.uk-button-default.uk-border-rounded #[span= !!project ? "Update" : "Create"] Project