// (C)2008 addworks

function devis_display()
{
	// TYPE D'IMPRESSION
	var ar_x_ImpType = new Array( 'numerique' );

	// ORIGINAUX
	var ar_x_Originaux = new Array(
		'docplan',
		'docdwg',
		'docplt',
		'docpdf'); // 'docautre'

	// FORMATS
	var ar_x_Format = new Array('a2','a1','a0');

	// MODES
	var ar_x_Mode = new Array('recto');

	// PAPIERS
	var ar_x_PapierC  = new Array('ipm90');
	var ar_x_PapierNB = new Array('ipm75');

	// IMPRESSIONS
	var ar_x_ImpStdR = new Array('ipnb','ipc');

	// FINITION
	var ar_x_Finition = new Array('ippli','iprou'); //'ics', 'icdr'

	// Initialisation des variables locales
	var theForm = document.forms['fdevis_impadd'];
	var imp = theForm.elements['x_Impression'].value;
	var format = theForm.elements['x_Format'].value;
	var mode = theForm.elements['x_Mode'].value;
	var papier = theForm.elements['x_Papier'].value;
	
	// Initialistion des listes de choix
	my_updatecombo(theForm.elements['x_ImpType'], this.TabImpType, ar_x_ImpType);
	my_updatecombo(theForm.elements['x_Originaux'], this.TabOriginaux, ar_x_Originaux);
	my_updatecombo(theForm.elements['x_Format'], this.TabFormat, ar_x_Format);
	my_updatecombo(theForm.elements['x_Mode'], this.TabMode, ar_x_Mode);
	my_updatecombo(theForm.elements['x_Impression'], this.TabImpression, ar_x_ImpStdR);
	my_updatecombo(theForm.elements['x_Finition'], this.TabFinition, ar_x_Finition);
	if (imp == "ipnb")
		my_updatecombo(theForm.elements['x_Papier'],    this.TabPapier , ar_x_PapierNB);
	else
		my_updatecombo(theForm.elements['x_Papier'],    this.TabPapier , ar_x_PapierC);
	
	// Initialisations des champs
	theForm.elements['x_CouvertureDevant'].value = 'aucune';
	theForm.elements['x_CouvertureDerriere'].value = 'aucune';
	theForm.elements['x_NbPagesCouleur'].value = '';
	theForm.elements['x_NbPagesNB'].value = '';
	theForm.elements['x_NbPages'].value = '1';

	// Enchainement
	var displayNext = true;
	displayNext = devisStep('NbExemplaires', displayNext, '0');
	displayNext = devisStep('ImpType', displayNext);
	displayNext = devisStep('Originaux', displayNext);
	displayNext = devisStep('Format', displayNext);
	displayNext = devisStep('Mode', displayNext);
	displayNext = devisStep('Impression', displayNext);
	displayNext = devisStep('Papier', displayNext);
	displayNext = devisStep('Finition', displayNext);
	fdevis_finalise(displayNext); 
}

