FIX : create proposal from project

This commit is contained in:
florian HENRY 2016-08-10 11:34:10 +02:00
parent 8c63d68083
commit d38ff5c246
2 changed files with 29 additions and 27 deletions

View File

@ -1266,6 +1266,8 @@ if ($action == 'create')
if ($origin != 'project' && $originid) { if ($origin != 'project' && $originid) {
print '<input type="hidden" name="origin" value="' . $origin . '">'; print '<input type="hidden" name="origin" value="' . $origin . '">';
print '<input type="hidden" name="originid" value="' . $originid . '">'; print '<input type="hidden" name="originid" value="' . $originid . '">';
} elseif ($origin == 'project' && !empty($projectid)) {
print '<input type="hidden" name="projectid" value="' . $projectid . '">';
} }
dol_fiche_head(); dol_fiche_head();

View File

@ -193,7 +193,7 @@ $listofreferent=array(
'class'=>'Propal', 'class'=>'Propal',
'table'=>'propal', 'table'=>'propal',
'datefieldname'=>'datep', 'datefieldname'=>'datep',
'urlnew'=>DOL_URL_ROOT.'/comm/propal/card.php?action=create&projectid='.$id.'&socid='.$socid, 'urlnew'=>DOL_URL_ROOT.'/comm/propal/card.php?action=create&origin=project&originid='.$id.'&socid='.$socid,
'lang'=>'propal', 'lang'=>'propal',
'buttonnew'=>'AddProp', 'buttonnew'=>'AddProp',
'testnew'=>$user->rights->propal->creer, 'testnew'=>$user->rights->propal->creer,