diff --git a/build/rpm/dolibarr_opensuse.spec b/build/rpm/dolibarr_opensuse.spec index d144134ae6a..d2109442024 100755 --- a/build/rpm/dolibarr_opensuse.spec +++ b/build/rpm/dolibarr_opensuse.spec @@ -27,7 +27,9 @@ BuildRoot: %{_tmppath}/%{name}-%{version}-build Group: Productivity/Office/Management Requires: apache2, apache2-mod_php5, php5 >= 5.3.0, php5-gd, php5-ldap, php5-imap, php5-mysql, php5-openssl, dejavu Requires: mysql-community-server, mysql-community-server-client +%if 0%{?suse_version} BuildRequires: update-desktop-files fdupes +%endif # Set yes to build test package, no for release (this disable need of /usr/bin/php not found by OpenSuse) AutoReqProv: no @@ -119,6 +121,7 @@ do fi done >>%{name}.lang +%if 0%{?suse_version} # Enable this command to tag desktop file for suse %suse_update_desktop_file dolibarr @@ -126,6 +129,8 @@ done >>%{name}.lang # Enable this command to allow suse detection of duplicate files and create hardlinks instead %fdupes $RPM_BUILD_ROOT%{_datadir}/%{name}/htdocs +%endif + #---- clean %clean diff --git a/htdocs/comm/action/fiche.php b/htdocs/comm/action/fiche.php index ab7fd2a510c..8342613208e 100644 --- a/htdocs/comm/action/fiche.php +++ b/htdocs/comm/action/fiche.php @@ -352,7 +352,7 @@ if ($action == 'update') $actioncomm->array_options[$key]=GETPOST($key); } } - + if (! $error) { $db->begin(); @@ -646,7 +646,7 @@ if ($id) $act = new ActionComm($db); $result=$act->fetch($id); $act->fetch_optionals($id,$extralabels); - + if ($result < 0) { dol_print_error($db,$act->error); @@ -786,16 +786,19 @@ if ($id) print '
| '.$langs->trans("ActionOnCompany").' | '; - print ''; - print $form->select_company($act->societe->id,'socid','',1,1); - print ' | '; + // Thirdparty - Contact + if ($conf->societe->enabled) + { + print '||
| '.$langs->trans("ActionOnCompany").' | '; + print ''; + print $form->select_company($act->societe->id,'socid','',1,1); + print ' | '; - // Contact - print ''.$langs->trans("Contact").' | '; - print $form->selectarray("contactid", (empty($act->societe->id)?array():$act->societe->contact_array()), $act->contact->id, 1); - print ' | '.$langs->trans("Contact").' | '; + print $form->selectarray("contactid", (empty($act->societe->id)?array():$act->societe->contact_array()), $act->contact->id, 1); + print ' | '; + } // Project if (! empty($conf->projet->enabled)) @@ -803,7 +806,7 @@ if ($id) // Projet associe $langs->load("project"); - print '
| '.$langs->trans("Project").' | '; + print ' | ||
| '.$langs->trans("Project").' | '; $numprojet=select_projects($act->societe->id,$act->fk_project,'projectid'); if ($numprojet==0) { @@ -813,7 +816,7 @@ if ($id) } // Priority - print ' | ||
| '.$langs->trans("Priority").' | '; + print ' | ||
| '.$langs->trans("Priority").' | '; print ''; print ' | ||
| '.$langs->trans("ActionOnCompany").' | '.($act->societe->id?$act->societe->getNomUrl(1):$langs->trans("None")); - if ($act->societe->id && $act->type_code == 'AC_TEL') - { - if ($act->societe->fetch($act->societe->id)) + if ($conf->societe->enabled) + { + print ' | ||||
| '.$langs->trans("ActionOnCompany").' | '.($act->societe->id?$act->societe->getNomUrl(1):$langs->trans("None"));
+ if ($act->societe->id && $act->type_code == 'AC_TEL')
{
- print " ".dol_print_phone($act->societe->tel); - } - } - print ' | ';
- print ''.$langs->trans("Contact").' | '; - print '';
- if ($act->contact->id > 0)
- {
- print $act->contact->getNomUrl(1);
- if ($act->contact->id && $act->type_code == 'AC_TEL')
- {
- if ($act->contact->fetch($act->contact->id))
+ if ($act->societe->fetch($act->societe->id))
{
- print " ".dol_print_phone($act->contact->phone_pro); + print " ".dol_print_phone($act->societe->tel); } } + print ' | ';
+ print ''.$langs->trans("Contact").' | '; + print '';
+ if ($act->contact->id > 0)
+ {
+ print $act->contact->getNomUrl(1);
+ if ($act->contact->id && $act->type_code == 'AC_TEL')
+ {
+ if ($act->contact->fetch($act->contact->id))
+ {
+ print " ".dol_print_phone($act->contact->phone_pro); + } + } + } + else + { + print $langs->trans("None"); + } + print ' |
| '.$langs->trans("Project").' | '; + print ' | ||||
| '.$langs->trans("Project").' | '; if ($act->fk_project) { $project=new Project($db); @@ -1001,7 +1006,7 @@ if ($id) } // Priority - print ' | ||||
| '.$langs->trans("Priority").' | '; + print ' | ||||
| '.$langs->trans("Priority").' | '; print ($act->priority?$act->priority:''); print ' | ||||