Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
I
intranet-csv-import
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-csv-import
Commits
3d8e3820
Commit
3d8e3820
authored
Jan 19, 2017
by
Frank Bergmann
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
- now associating findocs with projects
parent
8bc73ab6
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
32 additions
and
0 deletions
+32
-0
import-im_invoice.tcl
www/import-im_invoice.tcl
+32
-0
No files found.
www/import-im_invoice.tcl
View file @
3d8e3820
...
...
@@ -533,6 +533,38 @@ foreach csv_line_fields $values_list_of_lists {
continue
}
# -------------------------------------------------------
# Associate financial document with projects
#
if
{
""
ne
$project
_id
}
{
set rel_exists_p
[
db_string rel_exists_p
"
select count(*)
from acs_rels r,
im_projects p,
im_projects sub_p
where p.project_id = :project_id and
sub_p.tree_sortkey between p.tree_sortkey and tree_right(p.tree_sortkey) and
r.object_id_one = sub_p.project_id and
r.object_id_two = :invoice_id
"
]
if
{
!$v_rel_exists_p
}
{
set rel_id
[
db_exec_plsql create_rel
"
select acs_rel__new (
null, -- rel_id
'relationship', -- rel_type
:project_id, -- object_id_one
:cost_id, -- object_id_two
null, -- context_id
null, -- creation_user
null -- creation_ip
)
"
]
}
}
# -------------------------------------------------------
# Import DynFields
set cost_dynfield_updates
{}
...
...
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