modelloSchedaSezioni.jsp 5.25 KB
Newer Older
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181
<%@ include file="/project/include.jsp" %>

<%@ page import = "it.cedaf.icare.modellischeda.model.datamanagement.ModelloSchedaRilevazioneDataManagement" %>
<%@ page import = "it.cedaf.icare.modellischeda.control.action.CheckOnDeleteSezioneAction" %>

 	
<script type="text/javascript">

	registerOnLoadMaster(sh_stb__sezioni__pasteSezioneenabled);

	var _msgDeleteSezione;
	
	function checkOnDelete(idSez) {
		_msgDeleteSezione = null;
		var idSezPName='<%=CheckOnDeleteSezioneAction.ID_SEZIONE_PARAM%>';
		var strParam = '&' + idSezPName + '=' + idSez;
		jsLoadString('it.cedaf.icare.modellischeda.control.action.CheckOnDeleteSezioneAction', strParam, '_setMsgDeleteSezione', JS_SYNC);		
		
		return _msgDeleteSezione;
	}	
	
	function _setMsgDeleteSezione(msg) {
		_msgDeleteSezione = msg;
	}
	
	function deleteSezione() {
		var slave='<%=ModelloSchedaRilevazioneDataManagement.SLAVE_SEZIONI%>';
		var params='';
		var selRow ;

    	var selRow = shellGetSlaveSelectedRowAndAlertIfNotSelected(slave);

    	if (selRow != -1) {
       		if (shellConfirmDelete()) {
            	var idSez = cpGetSlaveColumnValueOfCurrentRow(slave, 'idSezione');

				if (idSez != null && idSez != '') {
           			var msgRet = checkOnDelete(idSez);
           		
           			if (msgRet != null && msgRet != '') {
           				if (confirm(msgRet)) {
	       					buiDeleteSlave(slave, cpGetMasterCurrentRow(), selRow, addParamsToParams(params, '_slave='+slave));
	       				} 
           			} else {
           				buiDeleteSlave(slave, cpGetMasterCurrentRow(), selRow, addParamsToParams(params, '_slave='+slave));
           			}           		
           		
           		}	else {
           				buiDeleteSlave(slave, cpGetMasterCurrentRow(), selRow, addParamsToParams(params, '_slave='+slave));
           		}
	    	}
    	}		
	}
	
</script>	


<j:tile slave="sezioni" name="shell.slaveToolbar" />	

<shell:grid description="codice,10%; descrizione,70%; order,10%; pesoMassimoSezione,10%; solaLettura,10%" slave="sezioni" />

<shell:fieldset title="Informazioni sezione">
	<table border="0" cellspacing="3" cellpadding="0" >
		<tr>
			<td class="form-label">
				<shell:label prop="codice" />
			</td>
			<td class="form-values">
				<bui:out slave="sezioni" modes="view">
					<j:tile slave="sezioni" name="shell.plaintext" prop="codice" />
				</bui:out>
				<bui:out slave="sezioni" modes="create, update">
					<j:bind prop="codice">
						<j:text class="form-short-text" />
						<shell:error />
					</j:bind>
				</bui:out>
			</td>
 		</tr>
		<tr>
			<td class="form-label">
				<shell:label prop="descrizione" />
			</td>
			<td class="form-values">
				<bui:out slave="sezioni" modes="view">
					<j:tile slave="sezioni" name="shell.plaintext" prop="descrizione" />
				</bui:out>
				<bui:out slave="sezioni" modes="create, update">
					<j:bind prop="descrizione">
						<j:text class="form-long-text" />
						<shell:error />
					</j:bind>
				</bui:out>
			</td>
 		</tr>
 		<tr>
			<td class="form-label">
				<shell:label prop="order" />
			</td>
			<td class="form-values">
				<bui:out slave="sezioni" modes="view">
					<j:tile slave="sezioni" name="shell.plaintext" prop="order" />
				</bui:out>
				<bui:out slave="sezioni" modes="create, update">
					<j:bind prop="order">
						<j:text class="form-short-text" />
						<shell:error />
					</j:bind>
				</bui:out>
			</td>
		</tr>
		<tr>
			<td class="form-label">
				<shell:label prop="pesoMassimoSezione" />
			</td>
			<td class="form-values">
				<bui:out slave="sezioni" modes="view">
					<j:tile slave="sezioni" name="shell.plaintext" prop="pesoMassimoSezione" />
				</bui:out>
				<bui:out slave="sezioni" modes="create, update">
					<j:bind prop="pesoMassimoSezione">
						<j:text class="form-short-text" />
						<shell:error />
					</j:bind>
				</bui:out>
			</td>
 		</tr>
 		<tr>
			<td class="form-label">
				<shell:label prop="solaLettura" />
			</td>
			<td class="form-values">
				<bui:out slave="sezioni" modes="view">
					<j:tile slave="sezioni" name="shell.plaintext" prop="solaLettura" />
				</bui:out>
				<bui:out slave="sezioni" modes="create, update">
					<j:bind prop="solaLettura">
						<j:text class="form-short-text" />
						<shell:error />
					</j:bind>
				</bui:out>
			</td>
		</tr>
 	</table>
</shell:fieldset>

<shell:fieldset title="Informazioni aggiuntive">
	<table border="0" cellspacing="3" cellpadding="0" >
 		<tr>
			<td class="form-label">
				<shell:label prop="note" />
			</td>
			<td class="form-values">
				<bui:out slave="sezioni" modes="view">
					<j:tile slave="sezioni" name="shell.plaintext" prop="note" />
				</bui:out>
				<bui:out slave="sezioni" modes="create, update">
					<j:bind prop="note">
						<j:textarea class="form-normal-textarea" />
						<shell:error />
					</j:bind>
				</bui:out>
			</td>
 		</tr>
	</table>
</shell:fieldset>

<shell:fieldset title="Informazioni voci">
	<table border="0" cellspacing="3" cellpadding="0" >
 		 <tr>
			<td class="form-label">
				<shell:label prop="voci" />
			</td>
			<td class="form-values" width="100%">
				<bui:out modes="view">
					<shell:grid slave="sezioni" property="voci" description="codice,10%; descrizione,40%; tipovoce,10%; obbligatorio,10%; order,10%; solaLettura,10%; sottoModelli,10%" numOfRows="10"/>
				</bui:out>
			</td>
 		</tr>
	</table>
</shell:fieldset>