Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
I
intranet-expenses
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
project-open
intranet-expenses
Commits
b4add492
Commit
b4add492
authored
Feb 20, 2017
by
Frank Bergmann
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
- Fixed issue from sapwise
parent
b123f540
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
6 deletions
+12
-6
index.tcl
www/index.tcl
+12
-6
No files found.
www/index.tcl
View file @
b4add492
...
...
@@ -116,9 +116,9 @@ set ttt {
# Admin Links
# ---------------------------------------------------------------
set
add_expense_p
[
im_permission
$user
_id
"add_expenses"
]
set
create_bundle_p
[
im_permission
$user
_id
"add_expense_bundle"
]
set
view_expenses_all_p
[
im_permission
$user
_id
"view_expenses_all"
]
set
add_expense_p
[
im_permission
$
current
_
user_id
"add_expenses"
]
set
create_bundle_p
[
im_permission
$
current
_
user_id
"add_expense_bundle"
]
set
view_expenses_all_p
[
im_permission
$
current
_
user_id
"view_expenses_all"
]
set
admin_links
""
...
...
@@ -273,9 +273,15 @@ if {"" != $expense_type_id & 0 != $expense_type_id} {
# Allow accounting guys to see all expense items,
# not just their own ones...
set
personal_only_sql
"and provider_id = :user_id"
if
{
$view
_expenses_all_p
}
{
set personal_only_sql
""
}
set
personal_only_sql
""
if
{
!$view_expenses_all_p
}
{
set personal_only_sql
"and provider_id = :user_id"
}
# Check the case that a privileged user has selected a "log-for" user
if
{
$view
_expenses_all_p &&
""
!=
$current
_user_id_from_search &&
$current
_user_id !=
$user
_id_from_search
}
{
set personal_only_sql
"and provider_id =
$user
_id_from_search"
}
switch
$unassigned
{
"todo"
{
set unassigned_sql
"and (c.project_id is null OR e.bundle_id is null)"
}
...
...
@@ -333,7 +339,7 @@ db_multirow -extend {expense_chk project_url expense_new_url expense_bundle_url
set
list2_id
"bundles_list"
set
delete_bundle_p
[
im_permission
$user
_id
"add_expense_bundle"
]
set
delete_bundle_p
[
im_permission
$
current
_
user_id
"add_expense_bundle"
]
set
bulk2_action_list
[
list
]
# Unconditionally allow to "Delete".
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment