Order Ansicht Inhalt Order Ansicht... 1 Inhalt... 1 Scope... 2 Orderansicht... 3 Orderelemente... 4 P1_CHANG_CH1... 6 Function: fc_ins_order... 7 Plug In... 8 Quelle:... 8 Anleitung:... 8 Plug In Installation:... 10 Create a new dynamic action... 13 Image Directory... 17 Tests... 17
Scope Alle platzierten Orders sollen in einer Online Übersicht zwecks Weiterverarbeitung angezeigt werden. Wurde die entsprechende Order abgearbeitet soll dieser Eintrag durch einen einfachen Klick (ohne weitere Bestätigung) aus der Liste entfernt werden. Zur Kontrolle sollen alle bearbeiteten Einträge in einer zweiten Liste, inkl. Name des Bearbeiters, aufgelistet werden.
Orderansicht
Orderelemente Satzart:
Link:
P1_CHANG_CH1
Function: fc_ins_order create or replace FUNCTION fc_ins_order(in_order NUMBER) RETURN NUMBER IS v_order NUMBER := 0; v_string VARCHAR2(250) := ''; CURSOR cr_sel_order IS SELECT ORS."ORDERID" FROM TB_ALLE_ORDERS ORS WHERE ORS."ORDERID" = in_order; begin OPEN cr_sel_order; LOOP FETCH cr_sel_order INTO v_order; EXIT WHEN cr_sel_order%notfound; DBMS_OUTPUT.PUT_LINE('TEST'); INSERT INTO TB_ORDER_OK (FK_ORDERID, MITARBEITER) VALUES (v_order, upper(v('app_user'))); END LOOP; RETURN 0; EXCEPTION WHEN OTHERS THEN DBMS_OUTPUT.PUT_LINE('Error: ' DBMS_UTILITY.format_error_stack); RETURN 0; end;
Plug In Der erstellte Online Report soll dynamisch aktualisiert werden. Idealerweise wurde hierzu ein von ORACLE abgestelltes PLUG IN verwendet. Quelle: http://www.oracle.com/technetwork/developer-tools/apex/application-express/apex-plug-ins-182042.html Anleitung: INSTALLATION ============ 1. Ensure you are running Oracle APEX version 4.0 or higher 2. Unzip and extract all files 2. Access your target Workspace 3. Select the Application Builder 4. Select the Application where you wish to import the plug-in (plug-ins belong to an application, not a workspace) 5. Access Shared Components > Plug-Ins 6. Click [Import >] 7. Browse and locate the installer file, dynamic_action_plugin_com_oracle_apex_timer.sql 8. Complete the wizard If the plug-in already exists in that application, you will need to confirm that you want to replace it. Also, once imported, this plug-in can be installed into additional applications within the same workspace. Simply navigate to the Export Repository (Export > Export Repository), click Install, and then select the target application.
Once the install file is no longer needed, it can be removed from the Export Repository. ADVANCED INSTALLATION ===================== 1. Follow the steps in INSTALLATION 2. Copy the files of the directory "server" to the /images/plugins/timer_v1_0 or any other directory on the web server 3. Set the "File Prefix" attribute of the plug-in to #IMAGE_PREFIX#plugins/timer_v1_0/ This will provide better performance, because the static files will be served by the web server instead of reading them each time from the database. HOW TO USE ========== 1. Install the plug-in (see INSTALLATION) 2a. Create a new dynamic action b. Use the "Advanced Wizard" c. Pick "Page Load" as event (you can use other events as well to create the timer) d. Select the plug-in "Timer" as action e. Follow the wizard and use Item Level Help to get more information about the purpose and usage of the different settings f. Set the "Affected Elements" to the component you want to act on, like a region 3a. Create a new dynamic action to react on the expiry of the timer b. Use the "Advanced Wizard" c. Set the event to "Timer Expired [Plug-in]" and d. "Selection Type" to the same value as you have used for "Affected Elements" when you created the timer e. Pick the action which you want to perform (for example Refresh) Note that you can also update existing dynamic actions to use this new plug-in, once installed.
Plug In Installation:
File Prefix anpassen: #PLUGIN_PREFIX# #IMAGE_PREFIX#plugins/timer_v1_0/
Create a new dynamic action Um Aktualisieren des Reports werden 2 Dynamic Actions benötigt. Die erste liefert den eigentlichen Timer und initialisiert diesen. Die zweite wird aktiv, wenn die Timer Zeit (Event: Timer expired) abgelaufen ist und aktualisiert entsprechend den Report. DY_TIMER:
DY_REFRESH
Image Directory #IMAGE_PREFIX# points to virtual path of server "images" directory (default /i/); #APP_IMAGES# points to static files uploaded with APEX upload utility (so saved in database), that are related to specific application (and only this application can use them); #WORKSPACE_IMAGES# points to static files uploaded with APEX upload utility (so saved in database), that are related to the workspace (any application can use them). http://st-curriculum.oracle.com/obe/db/apex/r40/apexplugins/apexplugins_ll.htm Tests delete from TB_ALLE_ORDERS where orderid = 53707 insert into TB_ALLE_ORDERS (orderid) values (53707)