TASKPM/libreplan-webapp/src/main/webapp/resources/machine/_machineConfigurationUnits.zul
Manuel Rego Casasnovas d59577a568 i18n: Review and fix several strings to be translated
FEA: ItEr76S04BugFixing
2012-07-02 19:37:31 +02:00

139 lines
7.8 KiB
Text

<!--
This file is part of LibrePlan
Copyright (C) 2009-2010 Fundación para o Fomento da Calidade Industrial e
Desenvolvemento Tecnolóxico de Galicia
Copyright (C) 2010-2011 Igalia, S.L.
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU Affero General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU Affero General Public License for more details.
You should have received a copy of the GNU Affero General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
-->
<vbox
apply="org.libreplan.web.resources.machine.MachineConfigurationController"
id="${arg.id}"
width="100%">
<button label="${i18n:_('Add new configuration unit')}"
onClick="configurationController.addConfigurationUnit();" />
<grid fixedLayout="true"
model="@{configurationController.configurationUnits}" id="configurationUnitsGrid">
<columns>
<column width="25px" />
<column label="${i18n:_('Name')}"
tooltiptext="${i18n:_('Configuration unit name')}"
width="400px" sort="auto(name)" />
<column label="${i18n:_('Alpha')}"
tooltiptext="${i18n:_('Human hours per machine working hour within configuration unit')}" />
<column label="${i18n:_('Operations')}" />
</columns>
<rows>
<!-- To iterate on workersConfiguration Units -->
<row self="@{each='configurationUnit'}" value="@{configurationUnit}">
<detailrow>
<!-- Assigned resources -->
<panel title="${i18n:_('Worker assignments')}" border="normal">
<panelchildren style="padding:10px;">
<autocomplete finder="WorkerFinder" buttonVisible="true" width="300px" style="padding-bottom:10px;margin-top:10px;"/>
<button label="${i18n:_('Add new worker assignment')}"
onClick="configurationController.addWorkerAssignment(self.parent.parent.parent.parent.value,self)"/>
<grid fixedLayout="true"
model="@{configurationUnit.workerAssignments}" style="margin-top:10px;">
<columns sizable="true">
<column label="${i18n:_('Name')}" />
<column label="${i18n:_('Start date')}" />
<column label="${i18n:_('End date')}" />
<column label="${i18n:_('Operations')}" />
</columns>
<rows>
<row self="@{each='workerAssignment'}"
value="@{workerAssignment}">
<label
value="@{workerAssignment.worker.name}" />
<datebox
value="@{workerAssignment.startDate}" constraint="no empty"/>
<datebox
value="@{workerAssignment.finishDate}" constraint="@{configurationController.validateEndDate}" />
<button sclass="icono"
image="/common/img/ico_borrar1.png"
hoverImage="/common/img/ico_borrar.png"
tooltiptext="${i18n:_('Delete')}"
onClick="configurationController.deleteWorkerAssignment(self.parent)">
</button>
</row>
</rows>
</grid>
</panelchildren>
</panel>
<!-- Assigned criteria -->
<textbox value="@{configurationUnit.id}" visible="false" />
<panel title="${i18n:_('Criterion requirements')}" border="normal">
<panelchildren style="padding:10px;">
<textbox value="@{configurationUnit.id}" visible="false" />
<bandbox width="300px">
<bandpopup>
<listbox width="500px" height="150px" fixedLayout="true"
model="@{assignedCriterionsController.criterionWorkersWithItsTypes}"
onSelect="configurationController.selectCriterionRequirement(self.selectedItem,self.parent.parent)">
<listhead>
<listheader label="Type" />
<listheader label="Criterion" />
</listhead>
<listitem self="@{each='criterionWithItsType'}" value="@{criterionWithItsType}">
<listcell label="@{criterionWithItsType.type.name}" />
<listcell label="@{criterionWithItsType.nameHierarchy}" />
</listitem>
</listbox>
</bandpopup>
</bandbox>
<button label="${i18n:_('Add new criterion requirement')}"
onClick="configurationController.addCriterionRequirement(self.parent.parent.parent.parent.value,self)" />
<grid fixedLayout="true"
model="@{configurationUnit.requiredCriterions}" style="margin-top:10px;">
<columns sizable="true">
<column label="${i18n:_('Name')}" />
<column label="${i18n:_('Operations')}" />
</columns>
<rows>
<row self="@{each='requirement'}"
value="@{requirement}">
<label value="@{requirement.completeName}" />
<button sclass="icono"
image="/common/img/ico_borrar1.png"
hoverImage="/common/img/ico_borrar.png"
tooltiptext="${i18n:_('Delete')}"
onClick="configurationController.deleteRequiredCriterion(self.parent.value, self.parent.parent)">
</button>
</row>
</rows>
</grid>
</panelchildren>
</panel>
</detailrow>
<textbox value="@{configurationUnit.name}"
constraint="no empty:${i18n:_('cannot be empty')}" />
<textbox value="@{configurationUnit.alpha}"
constraint="no zero,no empty,/[0-9][0-9]*(\.[0-9][0-9]?)?/:${i18n:_('must be a real positive number')}" />
<button sclass="icono" image="/common/img/ico_borrar1.png"
hoverImage="/common/img/ico_borrar.png" tooltiptext="${i18n:_('Delete')}"
onClick="configurationController.deleteConfigurationUnit(self.parent.value)">
</button>
</row>
</rows>
</grid>
</vbox>