Uniformize presentation on opensurvey
This commit is contained in:
parent
8c63d68083
commit
c391ca5b32
@ -188,10 +188,11 @@ if ($object->fk_user_creat)
|
|||||||
$userstatic->fetch($object->fk_user_creat);
|
$userstatic->fetch($object->fk_user_creat);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
$title = $object->titre." - ".$langs->trans('Card');
|
||||||
|
$helpurl = '';
|
||||||
$arrayofjs=array();
|
$arrayofjs=array();
|
||||||
$arrayofcss=array('/opensurvey/css/style.css');
|
$arrayofcss=array('/opensurvey/css/style.css');
|
||||||
llxHeader('',$object->titre, 0, 0, 0, 0, $arrayofjs, $arrayofcss);
|
llxHeader('',$title, $helpurl, 0, 0, 0, $arrayofjs, $arrayofcss);
|
||||||
|
|
||||||
|
|
||||||
// Define format of choices
|
// Define format of choices
|
||||||
@ -219,7 +220,7 @@ print '<table class="border" width="100%">';
|
|||||||
$linkback = '<a href="'.dol_buildpath('/opensurvey/list.php',1).'">'.$langs->trans("BackToList").'</a>';
|
$linkback = '<a href="'.dol_buildpath('/opensurvey/list.php',1).'">'.$langs->trans("BackToList").'</a>';
|
||||||
|
|
||||||
// Ref
|
// Ref
|
||||||
print '<tr><td class="titlefieldcreate">'.$langs->trans('Ref').'</td>';
|
print '<tr><td class="titlefield">'.$langs->trans('Ref').'</td>';
|
||||||
print '<td colspan="3">';
|
print '<td colspan="3">';
|
||||||
print $form->showrefnav($object, 'id', $linkback, 1, 'id_sondage', 'id_sondage');
|
print $form->showrefnav($object, 'id', $linkback, 1, 'id_sondage', 'id_sondage');
|
||||||
print '</td>';
|
print '</td>';
|
||||||
|
|||||||
@ -49,7 +49,7 @@ $nblignes=$object->fetch_lines();
|
|||||||
* Actions
|
* Actions
|
||||||
*/
|
*/
|
||||||
|
|
||||||
//Return to the results
|
// Return to the results
|
||||||
if (GETPOST('retoursondage')) {
|
if (GETPOST('retoursondage')) {
|
||||||
header('Location: results.php?id='.$_GET['id']);
|
header('Location: results.php?id='.$_GET['id']);
|
||||||
exit;
|
exit;
|
||||||
@ -403,9 +403,11 @@ if ($result <= 0)
|
|||||||
exit;
|
exit;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
$title = $object->titre." - ".$langs->trans('Card');
|
||||||
|
$helpurl = '';
|
||||||
$arrayofjs=array();
|
$arrayofjs=array();
|
||||||
$arrayofcss=array('/opensurvey/css/style.css');
|
$arrayofcss=array('/opensurvey/css/style.css');
|
||||||
llxHeader('',$object->titre, 0, 0, 0, 0, $arrayofjs, $arrayofcss);
|
llxHeader('',$title, $helpurl, 0, 0, 0, $arrayofjs, $arrayofcss);
|
||||||
|
|
||||||
|
|
||||||
// Define format of choices
|
// Define format of choices
|
||||||
@ -432,7 +434,7 @@ print '<table class="border" width="100%">';
|
|||||||
$linkback = '<a href="'.dol_buildpath('/opensurvey/list.php',1).(! empty($socid)?'?socid='.$socid:'').'">'.$langs->trans("BackToList").'</a>';
|
$linkback = '<a href="'.dol_buildpath('/opensurvey/list.php',1).(! empty($socid)?'?socid='.$socid:'').'">'.$langs->trans("BackToList").'</a>';
|
||||||
|
|
||||||
// Ref
|
// Ref
|
||||||
print '<tr><td class="titlefieldcreate">'.$langs->trans('Ref').'</td>';
|
print '<tr><td class="titlefield">'.$langs->trans('Ref').'</td>';
|
||||||
print '<td colspan="3">';
|
print '<td colspan="3">';
|
||||||
print $form->showrefnav($object, 'id', $linkback, 1, 'id_sondage', 'id_sondage');
|
print $form->showrefnav($object, 'id', $linkback, 1, 'id_sondage', 'id_sondage');
|
||||||
print '</td>';
|
print '</td>';
|
||||||
|
|||||||
@ -1,7 +1,7 @@
|
|||||||
<?php
|
<?php
|
||||||
/* Copyright (C) 2013-2014 Laurent Destailleur <eldy@users.sourceforge.net>
|
/* Copyright (C) 2013-2014 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||||
* Copyright (C) 2014 Marcos García <marcosgdf@gmail.com>
|
* Copyright (C) 2014 Marcos García <marcosgdf@gmail.com>
|
||||||
* Copyright (C) 2015 Alexandre Spangaro <aspangaro.dolibarr@gmail.com>
|
* Copyright (C) 2015-2016 Alexandre Spangaro <aspangaro.dolibarr@gmail.com>
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify
|
* This program is free software; you can redistribute it and/or modify
|
||||||
* it under the terms of the GNU General Public License as published by
|
* it under the terms of the GNU General Public License as published by
|
||||||
@ -133,15 +133,15 @@ llxHeader('', $langs->trans("OpenSurvey"), '', "", 0, 0, $arrayofjs, $arrayofcss
|
|||||||
|
|
||||||
print load_fiche_titre($langs->trans("CreatePoll").' (1 / 2)');
|
print load_fiche_titre($langs->trans("CreatePoll").' (1 / 2)');
|
||||||
|
|
||||||
//debut du formulaire
|
// debut du formulaire
|
||||||
print '<form name="formulaire" action="" method="POST">'."\n";
|
print '<form name="formulaire" action="" method="POST">'."\n";
|
||||||
|
|
||||||
dol_fiche_head();
|
dol_fiche_head();
|
||||||
|
|
||||||
//Affichage des différents champs textes a remplir
|
// Affichage des différents champs textes a remplir
|
||||||
print '<table class="border" width="100%">'."\n";
|
print '<table class="border" width="100%">'."\n";
|
||||||
|
|
||||||
print '<tr><td class="fieldrequired">'. $langs->trans("PollTitle") .'</td><td><input type="text" name="titre" size="40" maxlength="80" value="'.$_SESSION["titre"].'"></td>'."\n";
|
print '<tr><td class="titlefieldcreate fieldrequired">'. $langs->trans("PollTitle") .'</td><td><input type="text" name="titre" size="40" maxlength="80" value="'.$_SESSION["titre"].'"></td>'."\n";
|
||||||
if (! $_SESSION["titre"] && (GETPOST('creation_sondage_date') || GETPOST('creation_sondage_autre')))
|
if (! $_SESSION["titre"] && (GETPOST('creation_sondage_date') || GETPOST('creation_sondage_autre')))
|
||||||
{
|
{
|
||||||
setEventMessages($langs->trans("ErrorFieldRequired", $langs->transnoentitiesnoconv("PollTitle")), null, 'errors');
|
setEventMessages($langs->trans("ErrorFieldRequired", $langs->transnoentitiesnoconv("PollTitle")), null, 'errors');
|
||||||
@ -180,7 +180,7 @@ if ($_SESSION['allow_comments']) $allow_comments = 'checked';
|
|||||||
if (isset($_POST['allow_comments'])) $allow_comments=GETPOST('allow_comments')?'checked':'';
|
if (isset($_POST['allow_comments'])) $allow_comments=GETPOST('allow_comments')?'checked':'';
|
||||||
print '<input type="checkbox" name="allow_comments" '.$allow_comments.'"> '.$langs->trans('CanComment').'<br />'."\n";
|
print '<input type="checkbox" name="allow_comments" '.$allow_comments.'"> '.$langs->trans('CanComment').'<br />'."\n";
|
||||||
|
|
||||||
if ($_SESSION['allow_spy']) $allow_spy = 'checed';
|
if ($_SESSION['allow_spy']) $allow_spy = 'checked';
|
||||||
if (isset($_POST['allow_spy'])) $allow_spy=GETPOST('allow_spy')?'checked':'';
|
if (isset($_POST['allow_spy'])) $allow_spy=GETPOST('allow_spy')?'checked':'';
|
||||||
print '<input type="checkbox" name="allow_spy" '.$allow_spy.'> '.$langs->trans('CanSeeOthersVote').'<br />'."\n";
|
print '<input type="checkbox" name="allow_spy" '.$allow_spy.'> '.$langs->trans('CanSeeOthersVote').'<br />'."\n";
|
||||||
|
|
||||||
@ -193,7 +193,7 @@ if (GETPOST('choix_sondage'))
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
//affichage des boutons pour choisir sondage date ou autre
|
// affichage des boutons pour choisir sondage date ou autre
|
||||||
print '<br><table>'."\n";
|
print '<br><table>'."\n";
|
||||||
print '<tr><td>'. $langs->trans("CreateSurveyDate") .'</td><td></td> '."\n";
|
print '<tr><td>'. $langs->trans("CreateSurveyDate") .'</td><td></td> '."\n";
|
||||||
print '<td><input type="image" name="creation_sondage_date" value="'.$langs->trans('CreateSurveyDate').'" src="../img/calendar-32.png"></td></tr>'."\n";
|
print '<td><input type="image" name="creation_sondage_date" value="'.$langs->trans('CreateSurveyDate').'" src="../img/calendar-32.png"></td></tr>'."\n";
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user