From: miker Date: Sun, 14 Dec 2008 21:41:22 +0000 (+0000) Subject: always attach the permission list, even if it is empty; attach the constructed foreig... X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=df1c3da8efd722cdb5836ada28f39eec0ddc24bf;p=Evergreen.git always attach the permission list, even if it is empty; attach the constructed foreign_context structure git-svn-id: svn://svn.open-ils.org/ILS/trunk@11546 dcc99617-32d9-48b4-a31d-7c20da2025e4 --- diff --git a/Open-ILS/src/c-apps/oils_idl-core.c b/Open-ILS/src/c-apps/oils_idl-core.c index c756356431..d402969a06 100644 --- a/Open-ILS/src/c-apps/oils_idl-core.c +++ b/Open-ILS/src/c-apps/oils_idl-core.c @@ -335,8 +335,8 @@ osrfHash* oilsIDLInit( const char* idl_filename ) { } } free(map_list); - osrfHashSet( _tmp, map, "permission"); } + osrfHashSet( _tmp, map, "permission"); osrfHashSet( _tmp, (char*)xmlGetProp(_l, BAD_CAST "global_required"), "global_required"); @@ -359,6 +359,9 @@ osrfHash* oilsIDLInit( const char* idl_filename ) { } osrfHashSet( _tmp, map, "local_context"); + osrfHash* foreign_context = osrfNewHash(); + osrfHashSet( _tmp, foreign_context, "foreign_context"); + xmlNodePtr _f = _l->children; while(_f) { @@ -371,11 +374,11 @@ osrfHash* oilsIDLInit( const char* idl_filename ) { if( (string_tmp = (char*)xmlGetProp(_f, BAD_CAST "link")) ) { osrfLogDebug(OSRF_LOG_MARK, "Permacrud context link definition is %s", string_tmp ); - osrfHash* _tmp_fcontext = osrfNewHash(); osrfHash* _flink = oilsIDLFindPath("/%s/links/%s", osrfHashGet(usrData, "classname"), string_tmp); - osrfHashSet( _tmp_fcontext, osrfNewHash(), osrfHashGet(_flink, "class") ); - _tmp_fcontext = osrfHashGet( _tmp_fcontext, osrfHashGet(_flink, "class") ); + osrfHashSet( foreign_context, osrfNewHash(), osrfHashGet(_flink, "class") ); + osrfHash* _tmp_fcontext = osrfHashGet( foreign_context, osrfHashGet(_flink, "class") ); + osrfHashSet( _tmp_fcontext, osrfHashGet(_flink, "field"), "fkey" ); osrfHashSet( _tmp_fcontext, osrfHashGet(_flink, "key"), "field" );