Skip to content
This repository has been archived by the owner on Jan 15, 2019. It is now read-only.

Commit

Permalink
* Fixed max_attempt fields in templates (fixes #2459)
Browse files Browse the repository at this point in the history
  • Loading branch information
root authored and Jannis Mosshammer committed Mar 23, 2012
1 parent 61f066b commit 18b37fe
Show file tree
Hide file tree
Showing 3 changed files with 24 additions and 3 deletions.
9 changes: 6 additions & 3 deletions app/modules/Api/config/views/host.xml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@
hs.output AS HOST_OUTPUT,
hs.current_check_attempt AS HOST_CURRENT_CHECK_ATTEMPT,
hs.max_check_attempts AS HOST_MAX_CHECK_ATTEMPT,
hs.max_check_attempts AS max_attempt,
i.instance_id AS HOST_INSTANCE_ID,
h.host_id AS HOST_ID,
hs.notifications_enabled as notifications_enabled,
Expand Down Expand Up @@ -93,17 +94,19 @@
<query>
<![CDATA[
SELECT DISTINCT
h.icon_image HOST_ICON_IMAGE,
h.icon_image AS SERVICE_ICON_IMAGE,
i.instance_name AS INSTANCE_NAME,
h.host_object_id AS HOST_OBJECT_ID,
oh.name1 AS HOST_NAME,
h.alias AS HOST_ALIAS,
h.display_name AS HOST_DISPLAY_NAME,
hs.current_state AS HOST_CURRENT_STATE,
COALESCE(hs.last_state_change,ps.program_start_time) AS DURATION_START,
hs.last_check AS HOST_LAST_CHECK,
ps.program_start_time AS HOST_PROGRAM_START_TIME,
hs.output AS HOST_OUTPUT,
hs.current_check_attempt AS HOST_CURRENT_CHECK_ATTEMPT,
hs.max_check_attempts AS HOST_MAX_CHECK_ATTEMPTS,
hs.max_check_attempts AS HOST_MAX_CHECK_ATTEMPT,
i.instance_id AS HOST_INSTANCE_ID,
h.host_id AS HOST_ID,
hs.notifications_enabled as notifications_enabled,
Expand All @@ -119,7 +122,7 @@
hs.scheduled_downtime_depth = 0
)
INNER JOIN h.object oh
INNER JOIN i.programstatus as ps
]]>
</query>

Expand Down
1 change: 1 addition & 0 deletions app/modules/Api/config/views/service.xml
Original file line number Diff line number Diff line change
Expand Up @@ -134,6 +134,7 @@
ss.output AS SERVICE_OUTPUT,
ss.current_check_attempt AS SERVICE_CURRENT_CHECK_ATTEMPT,
ss.max_check_attempts AS SERVICE_MAX_CHECK_ATTEMPTS,
ss.max_check_attempts AS service_max_attempt,
i.instance_id AS SERVICE_INSTANCE_ID,
s.service_id AS SERVICE_ID,
ss.notifications_enabled as notifications_enabled,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1071,6 +1071,23 @@
<parameter name="default">false</parameter>
</order>
</field>
<field name="max_attempt">
<datasource>
<parameter name="field">HOST_MAX_CHECK_ATTEMPT</parameter>
</datasource>
<display>
<parameter name="visible">false"</parameter>
<parameter name="label">Max attempt</parameter>
</display>

<filter>
<parameter name="enabled">false</parameter>
</filter>

<order>
<parameter name="enabled">false</parameter>
<parameter name="default">false</parameter>
</order>
</field>
</fields>
</template>

0 comments on commit 18b37fe

Please sign in to comment.