Page Menu
Home
In-Portal Phabricator
Search
Configure Global Search
Log In
Files
F1242978
custom_blocks.tpl
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Subscribers
None
File Metadata
Details
File Info
Storage
Attached
Created
Thu, Nov 20, 4:07 PM
Size
10 KB
Mime Type
text/html
Expires
Sat, Nov 22, 4:07 PM (12 h, 23 m)
Engine
blob
Format
Raw Data
Handle
806039
Attached To
rINP In-Portal
custom_blocks.tpl
View Options
<
inp2:m_DefineElement
name
=
"config_edit_text"
>
<
input
type
=
"text"
name
=
"<inp2:CustomInputName/>"
id
=
"<inp2:CustomInputName/>"
tabindex
=
"<inp2:m_get param='tab_index'/>"
value
=
"<inp2:Field field='
$
fi
eld'/>"
<
inp2:m_if
check
=
"m_Param"
name
=
"field_params"
>
<
inp2:m_Param
name
=
"field_params"
/><
inp2:m_else
/>
style="width:100%"
</
inp2:m_if
>
/>
</
inp2:m_DefineElement
>
<
inp2:m_DefineElement
name
=
"config_edit_password"
>
<
input
type
=
"password"
primarytype
=
"password"
name
=
"<inp2:CustomInputName/>"
id
=
"<inp2:CustomInputName/>"
tabindex
=
"<inp2:m_get param='tab_index'/>"
value
=
""
/>
<
input
type
=
"password"
name
=
"verify_<inp2:CustomInputName/>"
id
=
"verify_<inp2:CustomInputName/>"
tabindex
=
"<inp2:m_get param='tab_index'/>"
value
=
""
/>
<
span
class
=
"error"
id
=
"error_<inp2:CustomInputName/>"
></
span
>
</
inp2:m_DefineElement
>
<
inp2:m_DefineElement
name
=
"config_edit_option"
>
<
option
value
=
"<inp2:m_param name='key'/>"
<
inp2:m_param
name
=
"selected"
/>
>
<
inp2:m_param
name
=
"option"
/></
option
>
</
inp2:m_DefineElement
>
<
inp2:m_DefineElement
name
=
"config_edit_select"
>
<
select
name
=
"<inp2:CustomInputName/>"
id
=
"<inp2:CustomInputName/>"
tabindex
=
"<inp2:m_get param='tab_index'/>"
>
<
inp2:PredefinedOptions
field
=
"
$
fi
eld"
block
=
"config_edit_option"
selected
=
"selected"
/>
</
select
>
</
inp2:m_DefineElement
>
<
inp2:m_DefineElement
name
=
"config_edit_multiselect"
>
<
select
id
=
"<inp2:CustomInputName/>_select"
onchange
=
"update_multiple_options('<inp2:CustomInputName/>');"
tabindex
=
"<inp2:m_get param='tab_index'/>"
multiple
>
<
inp2:PredefinedOptions
field
=
"
$
fi
eld"
block
=
"config_edit_option"
selected
=
"selected"
/>
</
select
>
<
input
type
=
"hidden"
id
=
"<inp2:CustomInputName/>"
name
=
"<inp2:CustomInputName/>"
value
=
"<inp2:Field field='
$
fi
eld' db='db'/>"
/>
</
inp2:m_DefineElement
>
<
inp2:m_DefineElement
name
=
"config_edit_checkbox"
>
<
input
type
=
"hidden"
id
=
"<inp2:CustomInputName/>"
name
=
"<inp2:CustomInputName/>"
value
=
"<inp2:Field field='
$
fi
eld' db='db'/>"
/>
<
input
tabindex
=
"<inp2:m_get param='tab_index'/>"
type
=
"checkbox"
id
=
"_cb_<inp2:CustomInputName/>"
<
inp2:Field
field
=
"
$
fi
eld"
checked
=
"checked"
db
=
"db"
/>
onclick="update_checkbox(this, document.getElementById('
<
inp2:CustomInputName
/>
'))">
</
inp2:m_DefineElement
>
<
inp2:m_DefineElement
name
=
"config_edit_textarea"
>
<
textarea
name
=
"<inp2:CustomInputName/>"
id
=
"<inp2:CustomInputName/>"
tabindex
=
"<inp2:m_get param='tab_index'/>"
<
inp2:m_param
name
=
"field_params"
/>
>
<
inp2:Field
field
=
"
$
fi
eld"
/></
textarea
>
</
inp2:m_DefineElement
>
<
inp2:m_DefineElement
name
=
"config_radio_item"
>
<
input
type
=
"radio"
<
inp2:m_param
name
=
"checked"
/>
name="
<
inp2:CustomInputName
/>
" id="
<
inp2:CustomInputName
/>
_
<
inp2:m_param
name
=
'key'
/>
" tabindex="
<
inp2:m_get
param
=
'tab_index'
/>
" value="
<
inp2:m_param
name
=
'key'
/>
">
<
label
for
=
"<inp2:CustomInputName/>_<inp2:m_param name='key'/>"
><
inp2:m_param
name
=
"option"
/></
label
>
</
inp2:m_DefineElement
>
<
inp2:m_DefineElement
name
=
"config_edit_radio"
>
<
inp2:PredefinedOptions
field
=
"
$
fi
eld"
block
=
"config_radio_item"
selected
=
"checked"
/>
</
inp2:m_DefineElement
>
<
inp2:m_DefineElement
name
=
"config_edit_date"
>
<
input
type
=
"text"
name
=
"<inp2:CustomInputName append='_date'/>"
id
=
"<inp2:CustomInputName append='_date'/>"
tabindex
=
"<inp2:m_get param='tab_index'/>"
value
=
"<inp2:CustomField append='_date' format='_regional_InputDateFormat'/>"
size
=
"<inp2:CustomFormat append='_date' input_format='1' edit_size='edit_size'/>"
datepickerIcon
=
"<inp2:m_ProjectBase/>core/admin_templates/img/calendar_icon.gif"
>
<
img
src
=
"img/calendar_icon.gif"
id
=
"cal_img_<inp2:CustomInputName/>"
style
=
"cursor: pointer; margin-right: 5px"
title
=
"Date selector"
/>
<
span
class
=
"small"
>
(
<
inp2:CustomFormat
append
=
"_date"
input_format
=
"1"
human
=
"true"
/>
)
</
span
>
<
script
type
=
"text/javascript"
>
Calendar
.
setup
({
inputField
:
"<inp2:CustomInputName append='_date'/>"
,
ifFormat
:
Calendar
.
phpDateFormat
(
"<inp2:CustomFormat append='_date' input_format='1'/>"
),
button
:
"cal_img_<inp2:CustomInputName/>"
,
align
:
"br"
,
singleClick
:
true
,
showsTime
:
true
,
weekNumbers
:
false
,
firstDay
:
<
inp2
:
m_GetConfig
var
=
"FirstDayOfWeek"
/>
,
onUpdate
:
function
(
cal
)
{
runOnChange
(
'<inp2:CustomInputName append="_date"/>'
);
}
});
</
script
>
<
input
type
=
"hidden"
name
=
"<inp2:CustomInputName append='_time'/>"
value
=
""
>
</
inp2:m_DefineElement
>
<
inp2:m_DefineElement
name
=
"config_edit_datetime"
>
<
input
type
=
"text"
name
=
"<inp2:CustomInputName append='_date'/>"
id
=
"<inp2:CustomInputName append='_date'/>"
value
=
"<inp2:CustomField append='_date' format='_regional_InputDateFormat'/>"
size
=
"<inp2:CustomFormat append='_date' input_format='1' edit_size='edit_size'/>"
datepickerIcon
=
"<inp2:m_ProjectBase/>core/admin_templates/img/calendar_icon.gif"
>
<
img
src
=
"img/calendar_icon.gif"
id
=
"cal_img_<inp2:CustomInputName/>"
style
=
"cursor: pointer; margin-right: 5px"
title
=
"Date selector"
/>
<
span
class
=
"small"
>
(
<
inp2:CustomFormat
append
=
"_date"
input_format
=
"1"
human
=
"true"
/>
)
</
span
>
<
input
type
=
"hidden"
id
=
"full_date_<inp2:CustomInputName/>"
value
=
"<inp2:CustomField/>"
/>
<
script
type
=
"text/javascript"
>
Calendar
.
setup
({
inputField
:
"full_date_<inp2:CustomInputName/>"
,
ifFormat
:
Calendar
.
phpDateFormat
(
"<inp2:CustomFormat input_format='1'/>"
),
button
:
"cal_img_<inp2:CustomInputName/>"
,
align
:
"br"
,
singleClick
:
true
,
showsTime
:
true
,
weekNumbers
:
false
,
firstDay
:
<
inp2
:
m_GetConfig
var
=
"FirstDayOfWeek"
/>
,
onUpdate
:
function
(
cal
)
{
document
.
getElementById
(
'<inp2:CustomInputName append="_date"/>'
).
value
=
cal
.
date
.
print
(
Calendar
.
phpDateFormat
(
"<inp2:CustomFormat append='_date' input_format='1'/>"
)
);
document
.
getElementById
(
'<inp2:CustomInputName append="_time"/>'
).
value
=
cal
.
date
.
print
(
Calendar
.
phpDateFormat
(
"<inp2:CustomFormat append='_time' input_format='1'/>"
)
);
}
});
</
script
>
<
input
type
=
"text"
name
=
"<inp2:CustomInputName append='_time'/>"
id
=
"<inp2:CustomInputName append='_time'/>"
value
=
"<inp2:CustomField append='_time' format='_regional_InputTimeFormat'/>"
size
=
"<inp2:CustomFormat append='_time' input_format='1' edit_size='edit_size'/>"
><
span
class
=
"small"
>
(
<
inp2:CustomFormat
append
=
"_time"
input_format
=
"1"
human
=
"true"
/>
)
</
span
>
</
inp2:m_DefineElement
>
<
inp2:m_DefineElement
name
=
"cv_row_block"
>
<
inp2:m_if
check
=
"m_ParamEquals"
name
=
"show_heading"
value
=
"1"
>
<
tr
class
=
"subsectiontitle"
>
<
td
colspan
=
"3"
>
<
inp2:Field
name
=
"Heading"
as_label
=
"1"
/>
</
td
>
<
inp2:m_if
check
=
"{
$
SourcePrefix}_DisplayOriginal"
pass_params
=
"1"
>
<
td
><
inp2:m_phrase
name
=
"
$
original_title"
/></
td
>
</
inp2:m_if
>
</
tr
>
</
inp2:m_if
>
<
tr
class
=
"<inp2:m_odd_even odd='edit-form-odd' even='edit-form-even'/>"
>
<
inp2:m_inc
param
=
"tab_index"
by
=
"1"
/>
<
inp2:Field
field
=
"Prompt"
result_to_var
=
"title"
/>
<
td
class
=
"label-cell"
onmouseover
=
"show_form_error('<inp2:m_Param name="
SourcePrefix
"
js_escape
=
"1"
/>
', '
<
inp2:m_Param
name
=
"virtual_field"
js_escape
=
"1"
/>
')" onmouseout="hide_form_error('
<
inp2:m_Param
name
=
"SourcePrefix"
js_escape
=
"1"
/>
')">
<
span
class
=
"<inp2:m_if check='{
$
SourcePrefix}_HasError' field='
$
virtual_field'>error-cell</inp2:m_if>"
><
inp2:Field
field
=
"Prompt"
as_label
=
"1"
/></
span
><
inp2:m_if
check
=
"{
$
SourcePrefix}_IsRequired"
field
=
"
$
virtual_field"
><
span
class
=
"field-required"
>
*
</
span
></
inp2:m_if
>
:
<
inp2:m_if
check
=
"FieldHintLabel"
title_label
=
"
$
title"
><
span
>
<
img
src
=
"<inp2:m_TemplatesBase/>/img/hint_icon.png"
width
=
"12"
height
=
"13"
title
=
"<inp2:FieldHintLabel title_label='
$
title' html_escape='1'/>"
alt
=
"<inp2:FieldHintLabel title_label='
$
title' html_escape='1'/>"
/></
inp2:m_if
>
<
inp2:m_if
check
=
"FieldEquals"
field
=
"ElementType"
value
=
"textarea"
>
<
br
/>
<
inp2:
{$
SourcePrefix
}
_InputName
field
=
"
$
virtual_field"
result_to_var
=
"input_name"
/>
<
a
href
=
"<inp2:m_Link template='popups/editor' TargetField='
$
input_name' pass_through='TargetField' pass='m,
$
SourcePrefix'/>"
onclick
=
"openSelector('<inp2:m_Param name='SourcePrefix' js_escape='1'/>', this.href, '', '800x575'); return false;"
>
<
img
src
=
"img/icons/icon24_link_editor.gif"
border
=
"0"
>
</
a
>
</
inp2:m_if
>
</
td
>
<
td
class
=
"control-mid"
>
</
td
>
<
script
type
=
"text/javascript"
>
if
(
typeof
(
fields
[
'<inp2:m_Param name="SourcePrefix" js_escape="1"/>'
])
==
'undefined'
)
{
fields
[
'<inp2:m_Param name="SourcePrefix" js_escape="1"/>'
]
=
new
Object
();
}
<
inp2
:
m_if
check
=
"Field"
name
=
"ElementType"
equals_to
=
"date"
db
=
"db"
>
fields
[
'<inp2:m_Param name="SourcePrefix" js_escape="1"/>'
][
'<inp2:m_Param name="virtual_field" js_escape="1"/>_date'
]
=
'<inp2:{
$
PrefixSpecial}_Field field="Prompt" grid="
$
grid" as_label="1" no_special="no_special" js_escape="1"/>'
<
inp2
:
m_else
/>
fields
[
'<inp2:m_Param name="SourcePrefix" js_escape="1"/>'
][
'<inp2:m_Param name="virtual_field" js_escape="1"/>'
]
=
'<inp2:{
$
PrefixSpecial}_Field field="Prompt" grid="
$
grid" as_label="1" no_special="no_special" js_escape="1"/>'
<
/inp2:m_if>
</
script
>
<
td
class
=
"control-cell"
valign
=
"top"
>
<
inp2:ConfigFormElement
field
=
"Value"
blocks_prefix
=
"config_edit_"
element_type_field
=
"ElementType"
value_list_field
=
"ValueList"
/>
</
td
>
<
inp2:Field
name
=
"ElementType"
db
=
"db"
result_to_var
=
"element_type"
/>
<
inp2:m_if
check
=
"Field"
name
=
"ElementType"
equals_to
=
"date"
db
=
"db"
>
<
inp2:m_RenderElement
name
=
"inp_edit_error"
prefix
=
"
$
SourcePrefix"
field
=
"{
$
virtual_field}_date"
block_name
=
"cf:
$
element_type"
/>
<
inp2:m_else
/>
<
inp2:m_RenderElement
name
=
"inp_edit_error"
prefix
=
"
$
SourcePrefix"
field
=
"
$
virtual_field"
block_name
=
"cf:
$
element_type"
/>
</
inp2:m_if
>
<
inp2:m_if
check
=
"{
$
SourcePrefix}_DisplayOriginal"
pass_params
=
"1"
>
<
inp2:m_RenderElement
prefix
=
"
$
SourcePrefix"
field
=
"
$
fi
eld"
name
=
"inp_original_label"
/>
</
inp2:m_if
>
</
tr
>
</
inp2:m_DefineElement
>
<
inp2:m_DefineElement
name
=
"edit_custom_td"
>
<
inp2:ConfigFormElement
field
=
"Value"
blocks_prefix
=
"config_edit_"
element_type_field
=
"ElementType"
value_list_field
=
"ValueList"
/>
</
inp2:m_DefineElement
>
<
inp2:m_DefineElement
name
=
"custom_error_td"
>
<
inp2:
$
SourcePrefix_Error
field
=
"
$
virtual_field"
/>
</
inp2:m_DefineElement
>
<
inp2:m_DefineElement
name
=
"grid_original_td"
>
<
inp2:Field
field
=
"
$
fi
eld"
grid
=
"
$
grid"
/>
</
inp2:m_DefineElement
>
Event Timeline
Log In to Comment