Index: openacs-4/packages/sample-gateway/sql/postgresql/sample-gateway-create.sql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/sample-gateway/sql/postgresql/sample-gateway-create.sql,v diff -u -N --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ openacs-4/packages/sample-gateway/sql/postgresql/sample-gateway-create.sql 24 Apr 2006 14:57:18 -0000 1.2 @@ -0,0 +1,21 @@ +-- +-- packages/sample-gateway/sql/postgresql/sample-gateway-create.sql +-- +-- @author Deds Castillo (deds@i-manila.com.ph) +-- @creation-date 2005-01-24 +-- @arch-tag: cdccfb8f-0a0f-4c00-98ef-d1505f50048a +-- @cvs-id $Id: sample-gateway-create.sql,v 1.2 2006/04/24 14:57:18 daveb Exp $ +-- + +create table sample_gateway_result_log ( + transaction_id varchar(20) not null, + txn_attempted_type varchar(25), + txn_attempted_time timestamptz, + txn_returned_type varchar(25), + errmsg varchar(200), + auth_code varchar(25), + avs_code varchar(3), + amount numeric not null +); + +\i sample-gateway-sc-create.sql Index: openacs-4/packages/sample-gateway/sql/postgresql/sample-gateway-drop.sql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/sample-gateway/sql/postgresql/sample-gateway-drop.sql,v diff -u -N --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ openacs-4/packages/sample-gateway/sql/postgresql/sample-gateway-drop.sql 24 Apr 2006 14:57:18 -0000 1.2 @@ -0,0 +1,12 @@ +-- +-- packages/sample-gateway/sql/postgresql/sample-gateway-drop.sql +-- +-- @author Deds Castillo (deds@i-manila.com.ph) +-- @creation-date 2005-01-24 +-- @arch-tag: b0d9e356-8669-47cd-b697-24042bd5c26d +-- @cvs-id $Id: sample-gateway-drop.sql,v 1.2 2006/04/24 14:57:18 daveb Exp $ +-- + +drop table sample_gateway_result_log; + +\i sample-gateway-sc-drop.sql Index: openacs-4/packages/sample-gateway/sql/postgresql/sample-gateway-sc-create.sql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/sample-gateway/sql/postgresql/sample-gateway-sc-create.sql,v diff -u -N --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ openacs-4/packages/sample-gateway/sql/postgresql/sample-gateway-sc-create.sql 24 Apr 2006 14:57:18 -0000 1.2 @@ -0,0 +1,65 @@ +-- +-- packages/sample-gateway/sql/postgresql/sample-gateway-sc-create.sql +-- +-- @author Deds Castillo (deds@i-manila.com.ph) +-- @creation-date 2005-01-24 +-- @arch-tag: 140e6170-d72b-4066-a486-6fabc49589d8 +-- @cvs-id $Id: sample-gateway-sc-create.sql,v 1.2 2006/04/24 14:57:18 daveb Exp $ +-- + +-- This is a sample implementation of the PaymentGateway service contract + +select acs_sc_impl__new( + 'PaymentGateway', -- impl_contract_name + 'sample-gateway', -- impl_name + 'sample-gateway' -- impl_owner_name +); + + +select acs_sc_impl_alias__new( + 'PaymentGateway', -- impl_contract_name + 'sample-gateway', -- impl_name + 'Authorize', -- impl_operation_name + 'sample_gateway.Authorize', -- impl_alias + 'TCL' -- impl_pl +); + +select acs_sc_impl_alias__new( + 'PaymentGateway', -- impl_contract_name + 'sample-gateway', -- impl_name + 'ChargeCard', -- impl_operation_name + 'sample_gateway.ChargeCard', -- impl_alias + 'TCL' -- impl_pl +); + +select acs_sc_impl_alias__new( + 'PaymentGateway', -- impl_contract_name + 'sample-gateway', -- impl_name + 'Return', -- impl_operation_name + 'sample_gateway.Return', -- impl_alias + 'TCL' -- impl_pl +); + +select acs_sc_impl_alias__new( + 'PaymentGateway', -- impl_contract_name + 'sample-gateway', -- impl_name + 'Void', -- impl_operation_name + 'sample_gateway.Void', -- impl_alias + 'TCL' -- impl_pl +); + +select acs_sc_impl_alias__new( + 'PaymentGateway', -- impl_contract_name + 'sample-gateway', -- impl_name + 'Info', -- impl_operation_name + 'sample_gateway.Info', -- impl_alias + 'TCL' -- impl_pl +); + +-- Add the binding + +select acs_sc_binding__new ( + 'PaymentGateway', + 'sample-gateway' +); + Index: openacs-4/packages/sample-gateway/sql/postgresql/sample-gateway-sc-drop.sql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/sample-gateway/sql/postgresql/sample-gateway-sc-drop.sql,v diff -u -N --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ openacs-4/packages/sample-gateway/sql/postgresql/sample-gateway-sc-drop.sql 24 Apr 2006 14:57:18 -0000 1.2 @@ -0,0 +1,54 @@ +-- +-- packages/sample-gateway/sql/postgresql/sample-gateway-sc-drop.sql +-- +-- @author Deds Castillo (deds@i-manila.com.ph) +-- @creation-date 2005-01-24 +-- @arch-tag: 53839502-fad7-4fb3-a2d4-2f2f28c35c1f +-- @cvs-id $Id: sample-gateway-sc-drop.sql,v 1.2 2006/04/24 14:57:18 daveb Exp $ +-- + +select acs_sc_binding__delete( + 'PaymentGateway', + 'sample-gateway' +); + +select acs_sc_impl_alias__delete( + 'PaymentGateway', + 'sample-gateway', + 'Authorize' +); + +select acs_sc_impl_alias__delete( + 'PaymentGateway', + 'sample-gateway', + 'ChargeCard' +); + +select acs_sc_impl_alias__delete( + 'PaymentGateway', + 'sample-gateway', + 'Return' +); + +select acs_sc_impl_alias__delete( + 'PaymentGateway', + 'sample-gateway', + 'Void' +); + +select acs_sc_impl_alias__delete( + 'PaymentGateway', + 'sample-gateway', + 'Info' +); + +select acs_sc_binding__delete( + 'PaymentGateway', + 'sample-gateway' +); + +select acs_sc_impl__delete( + 'PaymentGateway', + 'sample-gateway' +); +