[%- USE T8 %] [%- USE L %] [%- USE HTML %][%- USE LxERP %] [%- INCLUDE 'common/flash.html' %]
[% title %]
[% L.hidden_tag("callback", callback) %] [% L.hidden_tag("id", SELF.project.id) %]
[%- IF SELF.project.id %] [%- END %]
[% 'Number' | $T8 %] [% L.input_tag("project.projectnumber", SELF.project.projectnumber, size=60) %]
[% 'Description' | $T8 %] [%- SET rows = LxERP.numtextrows(SELF.project.description, 60) %] [%- IF rows > 1 %] [%- L.textarea_tag("project.description", SELF.project.description, rows=row, size=60, style="width: 100%", wrap="soft") %] [%- ELSE %] [%- L.input_tag("project.description", SELF.project.description, size=60) %] [%- END %]
[% 'Type' | $T8 %] [% L.input_tag('project.type', SELF.project.type, size=60) %]
[% 'Customer' | $T8 %] [% L.select_tag('project.customer_id', ALL_CUSTOMERS, default=SELF.project.customer_id, title_key='name', style='width: 300px') %]
[% 'Valid' | $T8 %] [% L.select_tag('project.valid', [ [ 1, LxERP.t8('Valid') ], [ 0, LxERP.t8('Invalid') ] ], default=SELF.project.valid, style='width: 300px') %]
[% 'Active' | $T8 %] [% L.select_tag('project.active', [ [ 1, LxERP.t8('Active') ], [ 0, LxERP.t8('Inactive') ] ], default=SELF.project.active, style='width: 300px') %]

[%- IF CUSTOM_VARIABLES.size %]

[%- FOREACH var = CUSTOM_VARIABLES %] [%- END %]
[% HTML.escape(var.description) %] [% var.HTML_CODE %]


[%- END %]

[% L.online_help_tag('add_project') %] [% L.hidden_tag("action", "Project/dispatch") %] [% L.submit_tag("action_" _ (SELF.project.id ? "update" : "create"), LxERP.t8('Save')) %] [%- IF SELF.project.id %] [% L.submit_tag("action_create", LxERP.t8('Save as new')) %] [% L.submit_tag("action_destroy", LxERP.t8('Delete'), confirm=LxERP.t8('Do you really want to delete this object?')) IF !SELF.project.is_used %] [%- END %] [%- LxERP.t8('Abort') %]