4 |
* $Id$ |
* $Id$ |
5 |
* |
* |
6 |
* $Log$ |
* $Log$ |
7 |
|
* Revision 1.8 2003/04/08 17:53:08 joko |
8 |
|
* NEW: Module 'RemoteAction' in 'phase_startup' |
9 |
|
* |
10 |
|
* Revision 1.7 2003/04/07 22:32:27 jonen |
11 |
|
* + minor changes related to new ecom 'chooser' |
12 |
|
* |
13 |
|
* Revision 1.6 2003/04/06 01:32:57 jonen |
14 |
|
* + minor changes |
15 |
|
* |
16 |
* Revision 1.5 2003/04/05 21:18:29 joko |
* Revision 1.5 2003/04/05 21:18:29 joko |
17 |
* added Chooser and associated 'ecds'-parameter |
* added Chooser and associated 'ecds'-parameter |
18 |
* new rule (at bottom) to dispatch datasource-keys to each ecom-component |
* new rule (at bottom) to dispatch datasource-keys to each ecom-component |
151 |
// COID => '123', |
// COID => '123', |
152 |
caption => "Explorer - ExplorerDataItem", |
caption => "Explorer - ExplorerDataItem", |
153 |
)); |
)); |
154 |
|
|
155 |
// FIXME!!! enhance!?!? |
// FIXME!!! enhance!?!? |
156 |
// AIM: "dispatch a Request to a View by using rules..." |
// AIM: "dispatch a Request to a View by using rules..." |
157 |
// Todo: |
// Todo: |
163 |
|
|
164 |
// for "module", no component registry is required, just does 'mkObject' under the hood |
// for "module", no component registry is required, just does 'mkObject' under the hood |
165 |
module => 'Application::Request::HttpController', |
module => 'Application::Request::HttpController', |
166 |
|
//module_options => blah |
167 |
|
|
168 |
rules => array( |
rules => array( |
169 |
|
|
170 |
|
|
171 |
// get last page state |
// get last page state |
172 |
create_function('&$_in, &$_out', ' |
create_function('&$_in, &$_out', ' |
173 |
$requestTracker = mkObject("Application::Request::Tracker"); |
$requestTracker = mkObject("Application::Request::Tracker"); |
193 |
'), |
'), |
194 |
|
|
195 |
// check right $_GET[ap] |
// check right $_GET[ap] |
196 |
create_function('&$_in, &$_out', 'return ($_in[ap] != "explorer") ? print "Wrong application value $_in[ap], sure this is right here?" : null;'), |
create_function('&$_in, &$_out', 'return ($_in[ap] != "explorer") ? print "Wrong application value: $_in[ap], sure this is right here?<br>" : null;'), |
197 |
|
|
198 |
// write components variables to out |
// write components variables to out |
199 |
create_function('&$_in, &$_out', ' |
create_function('&$_in, &$_out', ' |
217 |
nav => array( |
nav => array( |
218 |
ecom_type => "nav", |
ecom_type => "nav", |
219 |
ecom_abstract_type => "list", |
ecom_abstract_type => "list", |
220 |
ecom_mode => "nav", |
ecom_mode => "link", |
221 |
ecom_data_locator_key => "rpc", |
ecom_data_locator_key => "rpc", |
222 |
), |
), |
223 |
chooser => array( |
chooser => array( |
224 |
ecom_type => "chooser", |
ecom_type => "nav", |
225 |
ecom_abstract_type => "list", |
ecom_abstract_type => "list", |
226 |
ecom_mode => "nav", |
ecom_mode => "link", |
227 |
ecom_data_locator_key => "rpc", |
ecom_data_locator_key => "rpc", |
228 |
), |
), |
229 |
); |
); |
245 |
// datasource if requested - otherwise everything will fall back to defaults |
// datasource if requested - otherwise everything will fall back to defaults |
246 |
create_function('&$_in, &$_out', ' |
create_function('&$_in, &$_out', ' |
247 |
if ($_in[ecom_data_source_key]) { |
if ($_in[ecom_data_source_key]) { |
248 |
|
|
249 |
|
//print "YAI<br/>"; |
250 |
|
|
251 |
//print Dumper($_out[options][ecoms]); |
//print Dumper($_out[options][ecoms]); |
252 |
//print "ds: " . $_in[ecom_data_source_key] . "<br/>"; |
//print "ds: " . $_in[ecom_data_source_key] . "<br/>"; |
253 |
/* |
/* |
258 |
} |
} |
259 |
*/ |
*/ |
260 |
$_out[options][main][ecom_data_source_key] = $_in[ecom_data_source_key]; |
$_out[options][main][ecom_data_source_key] = $_in[ecom_data_source_key]; |
261 |
|
|
262 |
|
|
263 |
|
// 2003-04-07 - enhanced |
264 |
|
// now activates a special ecom-component - a "RemoteAction" - replacing |
265 |
|
// the "content"-ecom instead of displaying an empty page / overriding any |
266 |
|
// view reached by "normal dispatching" |
267 |
|
|
268 |
|
$_out[options][ecoms][phase_startup] = array( |
269 |
|
ecom_type => "call", |
270 |
|
ecom_abstract_type => "auto", |
271 |
|
ecom_mode => "link", |
272 |
|
ecom_data_locator_key => "rpc", |
273 |
|
// new attributes/properties/arguments that control further / trigger different DataFlow: |
274 |
|
ecom_call_method => "selectSource", |
275 |
|
ecom_call_args => $_in[ecom_data_source_key] |
276 |
|
); |
277 |
|
|
278 |
} |
} |
279 |
'), |
'), |
280 |
|
|