Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
D
dolibarr
Manage
Activity
Members
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Container registry
Model registry
Analyze
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Software_Artifact_Infrastructure_Repository
dolibarr
Commits
a76ddc8b
Commit
a76ddc8b
authored
8 years ago
by
Thomas Raschbacher
Committed by
GitHub
8 years ago
Browse files
Options
Downloads
Patches
Plain Diff
Add phone phone numbers to project contacts
Add phone number(s) for project contacts to be used in odt
parent
e3d3d32b
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
htdocs/core/modules/project/doc/doc_generic_project_odt.modules.php
+23
-1
23 additions, 1 deletion
...e/modules/project/doc/doc_generic_project_odt.modules.php
with
23 additions
and
1 deletion
htdocs/core/modules/project/doc/doc_generic_project_odt.modules.php
+
23
−
1
View file @
a76ddc8b
...
@@ -186,6 +186,25 @@ class doc_generic_project_odt extends ModelePDFProjects
...
@@ -186,6 +186,25 @@ class doc_generic_project_odt extends ModelePDFProjects
{
{
global
$conf
;
global
$conf
;
// adding phone numbers if external
$phone_pro
=
''
;
$phone_perso
=
''
;
$phone_mobile
=
''
;
$ct
=
new
Contact
(
$this
->
db
);
if
(
$contact
[
'source'
]
==
'external'
)
{
$ct
=
new
Contact
(
$this
->
db
);
$ct
->
fetch
(
$contact
[
'id'
]);
$phone_pro
=
$ct
->
phone_pro
;
$phone_perso
=
$ct
->
phone_perso
;
$phone_mobile
=
$ct
->
phone_mobile
;
}
elseif
(
$contact
[
'source'
]
==
'internal'
)
{
$ct
=
new
User
(
$this
->
db
);
$ct
->
fetch
(
$contact
[
'id'
]);
$phone_pro
=
$ct
->
office_phone
;
$phone_mobile
=
$ct
->
user_mobile
;
}
return
array
(
return
array
(
'projcontacts_id'
=>
$contact
[
'id'
],
'projcontacts_id'
=>
$contact
[
'id'
],
'projcontacts_rowid'
=>
$contact
[
'rowid'
],
'projcontacts_rowid'
=>
$contact
[
'rowid'
],
...
@@ -194,7 +213,10 @@ class doc_generic_project_odt extends ModelePDFProjects
...
@@ -194,7 +213,10 @@ class doc_generic_project_odt extends ModelePDFProjects
'projcontacts_firstname'
=>
$contact
[
'firstname'
],
'projcontacts_firstname'
=>
$contact
[
'firstname'
],
'projcontacts_fullcivname'
=>
$contact
[
'fullname'
],
'projcontacts_fullcivname'
=>
$contact
[
'fullname'
],
'projcontacts_socname'
=>
$contact
[
'socname'
],
'projcontacts_socname'
=>
$contact
[
'socname'
],
'projcontacts_email'
=>
$contact
[
'email'
]
'projcontacts_email'
=>
$contact
[
'email'
],
'projcontacts_phone_pro'
=>
$phone_pro
,
'projcontacts_phone_perso'
=>
$phone_perso
,
'projcontacts_phone_mobile'
=>
$phone_mobile
);
);
}
}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment