[icinga-checkins] icinga.org: icinga-web/mfriedrich/fixes: * Removed hard-coded target_id and pt_id

git at icinga.org git at icinga.org
Thu Jan 13 17:54:24 CET 2011


Module: icinga-web
Branch: mfriedrich/fixes
Commit: 8a74dd5bcdf89d7dd1681c5d9ff425f4225578e2
URL:    https://git.icinga.org/?p=icinga-web.git;a=commit;h=8a74dd5bcdf89d7dd1681c5d9ff425f4225578e2

Author: Gunnar Beutner <gunnar.beutner at netways.de>
Date:   Wed Jan 12 11:55:50 2011 +0100

* Removed hard-coded target_id and pt_id

---

 etc/schema/updates/pgsql_v1-2_to_v1-3.sql |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/etc/schema/updates/pgsql_v1-2_to_v1-3.sql b/etc/schema/updates/pgsql_v1-2_to_v1-3.sql
index a78f322..bcbb5ca 100644
--- a/etc/schema/updates/pgsql_v1-2_to_v1-3.sql
+++ b/etc/schema/updates/pgsql_v1-2_to_v1-3.sql
@@ -76,6 +76,6 @@ CREATE UNIQUE INDEX cc_uid_unique ON cronk_category USING btree (cc_uid);
 
 -- Adding new credential and add them to appkit_admin
 
-INSERT INTO nsm_target (target_id, target_name, target_description, target_type) VALUES ('15', 'icinga.cronk.category.admin', 'Enables category admin feature', 'credential');
+INSERT INTO nsm_target (target_name, target_description, target_type) VALUES ('icinga.cronk.category.admin', 'Enables category admin feature', 'credential');
 
-INSERT INTO nsm_principal_target (pt_id, pt_principal_id, pt_target_id) VALUES ('8', '3', '15');
+INSERT INTO nsm_principal_target (pt_principal_id, pt_target_id) VALUES ('3', currval('nsm_target_target_id_seq'));





More information about the icinga-checkins mailing list