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
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Software_Artifact_Infrastructure_Repository
dolibarr
Commits
60c6510f
Commit
60c6510f
authored
9 years ago
by
Laurent Destailleur
Browse files
Options
Downloads
Patches
Plain Diff
NEW Can set default value of event type when creating an event (if type
of event option is used).
parent
3f506552
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
htdocs/admin/agenda_other.php
+14
-2
14 additions, 2 deletions
htdocs/admin/agenda_other.php
htdocs/comm/action/card.php
+2
-1
2 additions, 1 deletion
htdocs/comm/action/card.php
htdocs/langs/en_US/admin.lang
+1
-0
1 addition, 0 deletions
htdocs/langs/en_US/admin.lang
with
17 additions
and
3 deletions
htdocs/admin/agenda_other.php
+
14
−
2
View file @
60c6510f
...
...
@@ -74,8 +74,9 @@ if (preg_match('/del_(.*)/',$action,$reg))
if
(
$action
==
'set'
)
{
dolibarr_set_const
(
$db
,
'AGENDA_DEFAULT_FILTER_TYPE'
,
GETPOST
(
'AGENDA_DEFAULT_FILTER_TYPE'
),
'chaine'
,
0
,
''
,
$conf
->
entity
);
dolibarr_set_const
(
$db
,
'AGENDA_DEFAULT_FILTER_STATUS'
,
GETPOST
(
'AGENDA_DEFAULT_FILTER_STATUS'
),
'chaine'
,
0
,
''
,
$conf
->
entity
);
dolibarr_set_const
(
$db
,
'AGENDA_USE_EVENT_TYPE_DEFAULT'
,
GETPOST
(
'AGENDA_USE_EVENT_TYPE_DEFAULT'
),
'chaine'
,
0
,
''
,
$conf
->
entity
);
dolibarr_set_const
(
$db
,
'AGENDA_DEFAULT_FILTER_TYPE'
,
GETPOST
(
'AGENDA_DEFAULT_FILTER_TYPE'
),
'chaine'
,
0
,
''
,
$conf
->
entity
);
dolibarr_set_const
(
$db
,
'AGENDA_DEFAULT_FILTER_STATUS'
,
GETPOST
(
'AGENDA_DEFAULT_FILTER_STATUS'
),
'chaine'
,
0
,
''
,
$conf
->
entity
);
dolibarr_set_const
(
$db
,
'AGENDA_DEFAULT_VIEW'
,
GETPOST
(
'AGENDA_DEFAULT_VIEW'
),
'chaine'
,
0
,
''
,
$conf
->
entity
);
}
...
...
@@ -127,6 +128,17 @@ else
}
print
'</td></tr>'
.
"
\n
"
;
if
(
!
empty
(
$conf
->
global
->
AGENDA_USE_EVENT_TYPE
))
{
$var
=!
$var
;
print
'<tr '
.
$bc
[
$var
]
.
'>'
.
"
\n
"
;
print
'<td>'
.
$langs
->
trans
(
"AGENDA_USE_EVENT_TYPE_DEFAULT"
)
.
'</td>'
.
"
\n
"
;
print
'<td align="center"> </td>'
.
"
\n
"
;
print
'<td align="right" class="nowrap">'
.
"
\n
"
;
$formactions
->
select_type_actions
(
$conf
->
global
->
AGENDA_USE_EVENT_TYPE_DEFAULT
,
"AGENDA_USE_EVENT_TYPE_DEFAULT"
,
''
,
0
,
1
);
print
'</td></tr>'
.
"
\n
"
;
}
// AGENDA_DEFAULT_FILTER_TYPE
$var
=!
$var
;
print
'<tr '
.
$bc
[
$var
]
.
'>'
.
"
\n
"
;
...
...
This diff is collapsed.
Click to expand it.
htdocs/comm/action/card.php
+
2
−
1
View file @
60c6510f
...
...
@@ -647,7 +647,8 @@ if ($action == 'create')
if
(
!
empty
(
$conf
->
global
->
AGENDA_USE_EVENT_TYPE
))
{
print
'<tr><td width="30%"><span class="fieldrequired">'
.
$langs
->
trans
(
"Type"
)
.
'</span></b></td><td>'
;
$formactions
->
select_type_actions
(
GETPOST
(
"actioncode"
)
?
GETPOST
(
"actioncode"
)
:
$object
->
type_code
,
"actioncode"
,
"systemauto"
);
$default
=
(
empty
(
$conf
->
global
->
AGENDA_USE_EVENT_TYPE_DEFAULT
)
?
''
:
$conf
->
global
->
AGENDA_USE_EVENT_TYPE_DEFAULT
);
$formactions
->
select_type_actions
(
GETPOST
(
"actioncode"
)
?
GETPOST
(
"actioncode"
)
:
(
$object
->
type_code
?
$object
->
type_code
:
$default
),
"actioncode"
,
"systemauto"
);
print
'</td></tr>'
;
}
...
...
This diff is collapsed.
Click to expand it.
htdocs/langs/en_US/admin.lang
+
1
−
0
View file @
60c6510f
...
...
@@ -1546,6 +1546,7 @@ AgendaSetup=Events and agenda module setup
PasswordTogetVCalExport=Key to authorize export link
PastDelayVCalExport=Do not export event older than
AGENDA_USE_EVENT_TYPE=Use events types (managed into menu Setup -> Dictionary -> Type of agenda events)
AGENDA_USE_EVENT_TYPE_DEFAULT=Set automatically this default value for type of event into event create form
AGENDA_DEFAULT_FILTER_TYPE=Set automatically this type of event into search filter of agenda view
AGENDA_DEFAULT_FILTER_STATUS=Set automatically this status for events into search filter of agenda view
AGENDA_DEFAULT_VIEW=Which tab do you want to open by default when selecting menu Agenda
...
...
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