Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
mahara
mahara
Commits
7b7d8b16
Commit
7b7d8b16
authored
Apr 10, 2007
by
Penny Leach
Browse files
improved the resume plugin rendering
parent
1feb72a7
Changes
2
Show whitespace changes
Inline
Side-by-side
htdocs/artefact/resume/lib.php
View file @
7b7d8b16
...
...
@@ -468,6 +468,7 @@ abstract class ArtefactTypeResumeComposite extends ArtefactTypeResume {
public
function
__construct
(
$id
=
0
,
$data
=
array
())
{
if
(
empty
(
$id
))
{
$data
[
'container'
]
=
0
;
$data
[
'title'
]
=
get_string
(
$this
->
get_artefact_type
(),
'artefact.resume'
);
}
parent
::
__construct
(
$id
,
$data
);
}
...
...
@@ -502,28 +503,6 @@ abstract class ArtefactTypeResumeComposite extends ArtefactTypeResume {
return
$content
;
}
protected
function
get_metadata
(
$options
=
array
())
{
$data
=
parent
::
get_metadata
(
$options
);
if
(
isset
(
$options
[
'viewid'
])
&&
artefact_in_view
(
$id
=
$this
->
get
(
'id'
),
$options
[
'viewid'
]))
{
$data
[
'title'
][
'value'
]
=
'<a href="'
.
get_config
(
'wwwroot'
)
.
'view/view.php?view='
.
$options
[
'viewid'
]
.
'&artefact='
.
$id
.
'">'
.
$data
[
'title'
][
'value'
]
.
'</a>'
;
}
return
$data
;
}
protected
function
render_metadata
(
$options
)
{
$smarty
=
smarty
();
$data
=
$this
->
get_metadata
(
$options
);
$smarty
->
assign
(
'title'
,
$data
[
'title'
][
'value'
]);
$smarty
->
assign
(
'type'
,
get_string
(
$this
->
get
(
'artefacttype'
),
'artefact.resume'
));
$smarty
->
assign
(
'owner'
,
display_name
(
optional_userobj
(
$this
->
get
(
'owner'
))));
$smarty
->
assign
(
'nicectime'
,
format_date
(
$this
->
get
(
'ctime'
)));
$smarty
->
assign
(
'nicemtime'
,
format_date
(
$this
->
get
(
'mtime'
)));
return
array
(
'html'
=>
$smarty
->
fetch
(
'artefact/render_metadata.tpl'
),
'javascript'
=>
null
);
}
static
function
get_tablerenderer_title_js
(
$titlestring
,
$bodystring
)
{
return
"
function (r, d) {
...
...
@@ -912,14 +891,26 @@ class ArtefactTypeResumeGoalAndSkill extends ArtefactTypeResume {
public
static
function
get_render_list
()
{
return
array
(
FORMAT_ARTEFACT_LISTSELF
,
FORMAT_ARTEFACT_RENDERFULL
,
FORMAT_ARTEFACT_RENDERMETADATA
,
);
}
public
function
render_full
(
$options
)
{
return
array
(
'html'
=>
$this
->
get
(
'description'
));
$smarty
=
smarty
();
$smarty
->
assign
(
'type'
,
get_string
(
$this
->
get_artefact_type
(),
'artefact.resume'
));
$smarty
->
assign
(
'content'
,
$this
->
get
(
'description'
));
return
array
(
'html'
=>
$smarty
->
fetch
(
'artefact:resume:fragments/goalandskillrenderfull.tpl'
));
}
public
function
__construct
(
$id
=
0
,
$data
=
array
())
{
if
(
empty
(
$id
))
{
$data
[
'container'
]
=
0
;
$data
[
'title'
]
=
get_string
(
$this
->
get_artefact_type
(),
'artefact.resume'
);
}
parent
::
__construct
(
$id
,
$data
);
}
}
...
...
htdocs/artefact/resume/theme/default/fragments/goalandskillrenderfull.tpl
0 → 100644
View file @
7b7d8b16
<h3>
{
$type
}
</h3>
<p>
{
$content
}
</p>
Write
Preview
Supports
Markdown
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