Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
I
intranet-cost
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-cost
Commits
3161b832
Commit
3161b832
authored
May 20, 2020
by
Frank Bergmann
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
- Added source_invoice_names variable for list of documents
from which the current document was created
parent
8ca94df9
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
24 additions
and
2 deletions
+24
-2
upgrade-5.0.3.0.2-5.0.3.0.3.sql
sql/postgresql/upgrade/upgrade-5.0.3.0.2-5.0.3.0.3.sql
+24
-2
No files found.
sql/postgresql/upgrade/upgrade-5.0.3.0.2-5.0.3.0.3.sql
View file @
3161b832
...
...
@@ -7,7 +7,7 @@ SELECT im_category_hierarchy_new(3740,3708); -- Customer Purchase Order is a cus
-- Setup the "Customer Purchase Order" admin menu for Company Documents
-- Setup the "Customer Purchase Order" admin menu
s
for Company Documents
--
create
or
replace
function
inline_0
()
returns
integer
as
$
body
$
...
...
@@ -22,8 +22,9 @@ begin
select
group_id
into
v_senman
from
groups
where
group_name
=
'Senior Managers'
;
select
group_id
into
v_accounting
from
groups
where
group_name
=
'Accounting'
;
select
menu_id
into
v_invoices_new_menu
from
im_menus
where
label
=
'invoices_customers'
;
select
count
(
*
)
into
v_count
from
im_menus
where
label
=
'invoices_customers_new_customer_purchase_order'
;
select
count
(
*
)
into
v_count
from
im_menus
where
label
=
'invoices_customers_new_customer_purchase_order'
;
IF
v_count
=
0
THEN
v_menu_id
:
=
im_menu__new
(
null
,
'im_menu'
,
now
(),
null
,
null
,
null
,
...
...
@@ -40,6 +41,27 @@ begin
PERFORM
acs_permission__grant_permission
(
v_menu_id
,
v_accounting
,
'read'
);
END
IF
;
select
count
(
*
)
into
v_count
from
im_menus
where
label
=
'invoices_customers_new_invoice_from_customer_purchase_order'
;
IF
v_count
=
0
THEN
v_menu_id
:
=
im_menu__new
(
null
,
'im_menu'
,
now
(),
null
,
null
,
null
,
'intranet-invoices'
,
-- package_name
'invoices_customers_new_invoice_from_customer_purchase_order'
,
-- label
'New Customer Invoice from Customer Purchase Order'
,
-- name
'/intranet-invoices/new-copy?target_cost_type_id=3700&source_cost_type_id=3740'
,
-- url
350
,
-- sort_order
v_invoices_new_menu
,
-- parent_menu_id
null
-- visible_tcl
);
PERFORM
acs_permission__grant_permission
(
v_menu_id
,
v_senman
,
'read'
);
PERFORM
acs_permission__grant_permission
(
v_menu_id
,
v_accounting
,
'read'
);
END
IF
;
return
0
;
end
;
$
body
$
language
'plpgsql'
;
select
inline_0
();
...
...
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