2014年2月17日 星期一

Table: adempiere.z_pp_option

-- Table: adempiere.z_pp_option

-- DROP TABLE adempiere.z_pp_option;

CREATE TABLE adempiere.z_pp_option
(
  z_pp_option_id numeric(10,0) NOT NULL,
  ad_client_id numeric(10,0) NOT NULL,
  ad_org_id numeric(10,0) NOT NULL,
  isactive character(1) NOT NULL DEFAULT 'Y'::bpchar,
  created timestamp without time zone NOT NULL DEFAULT now(),
  createdby numeric(10,0) NOT NULL,
  updated timestamp without time zone NOT NULL DEFAULT now(),
  updatedby numeric(10,0) NOT NULL,
  value character varying(40) NOT NULL,
  name character varying(60) NOT NULL,
  description character varying(255),
  help character varying(2000),
  startdate timestamp without time zone,
  completedate timestamp without time zone,
  z_pp_option_uu character varying(36) DEFAULT NULL::character varying,
  isforward character(1) NOT NULL DEFAULT 'Y'::bpchar,
  schedulemethod character varying(40),
  CONSTRAINT z_pp_option_isactive_check CHECK (isactive = ANY (ARRAY['Y'::bpchar, 'N'::bpchar]))
)
WITH (
  OIDS=FALSE
);
ALTER TABLE adempiere.z_pp_option
  OWNER TO postgres;

Table: adempiere.z_pp_itemoperation

-- Table: adempiere.z_pp_itemoperation

-- DROP TABLE adempiere.z_pp_itemoperation;

CREATE TABLE adempiere.z_pp_itemoperation
(
  z_productionplan_id numeric(10,0) NOT NULL,
  z_pp_itemoperation_id numeric(10,0) NOT NULL,
  ad_client_id numeric(10,0) NOT NULL,
  ad_org_id numeric(10,0) NOT NULL,
  isactive character(1) NOT NULL DEFAULT 'Y'::bpchar,
  created timestamp without time zone NOT NULL DEFAULT now(),
  createdby numeric(10,0) NOT NULL,
  updated timestamp without time zone NOT NULL DEFAULT now(),
  updatedby numeric(10,0) NOT NULL,
  value character varying(40) NOT NULL,
  name character varying(60) NOT NULL,
  description character varying(255),
  help character varying(2000),
  z_resource_id numeric(10,0) NOT NULL,
  z_item_id numeric(10,0) NOT NULL,
  z_operation_id numeric(10,0) NOT NULL,
  startdate timestamp without time zone,
  completedate timestamp without time zone,
  usage numeric,
  z_uom_id numeric(10,0) NOT NULL,
  min_transfer_qty numeric,
  z_pp_itemoperation_uu character varying(36) DEFAULT NULL::character varying,
  CONSTRAINT z_pp_itemoperation_isactive_check CHECK (isactive = ANY (ARRAY['Y'::bpchar, 'N'::bpchar]))
)
WITH (
  OIDS=FALSE
);
ALTER TABLE adempiere.z_pp_itemoperation
  OWNER TO postgres;

TABLE adempiere.z_org;

-- Table: adempiere.z_org

-- DROP TABLE adempiere.z_org;

CREATE TABLE adempiere.z_org
(
  z_org_id numeric(10,0) NOT NULL,
  ad_client_id numeric(10,0) NOT NULL,
  ad_org_id numeric(10,0) NOT NULL,
  isactive character(1) NOT NULL DEFAULT 'Y'::bpchar,
  created timestamp without time zone NOT NULL DEFAULT now(),
  createdby numeric(10,0) NOT NULL,
  updated timestamp without time zone NOT NULL DEFAULT now(),
  updatedby numeric(10,0) NOT NULL,
  value character varying(40) NOT NULL,
  name character varying(60) NOT NULL,
  description character varying(255),
  help character varying(2000),
  timefrom timestamp without time zone,
  timeto timestamp without time zone,
  z_org_uu character varying(36) DEFAULT NULL::character varying,
  CONSTRAINT z_org_isactive_check CHECK (isactive = ANY (ARRAY['Y'::bpchar, 'N'::bpchar]))
)
WITH (
  OIDS=FALSE
);
ALTER TABLE adempiere.z_org
  OWNER TO postgres;

Table: adempiere.z_operation

-- Table: adempiere.z_operation

-- DROP TABLE adempiere.z_operation;

CREATE TABLE adempiere.z_operation
(
  z_operation_id numeric(10,0) NOT NULL,
  ad_client_id numeric(10,0) NOT NULL,
  ad_org_id numeric(10,0) NOT NULL,
  isactive character(1) NOT NULL DEFAULT 'Y'::bpchar,
  created timestamp without time zone NOT NULL DEFAULT now(),
  createdby numeric(10,0) NOT NULL,
  updated timestamp without time zone NOT NULL DEFAULT now(),
  updatedby numeric(10,0) NOT NULL,
  value character varying(40) NOT NULL,
  name character varying(60) NOT NULL,
  description character varying(255),
  help character varying(2000),
  z_operation_uu character varying(36) DEFAULT NULL::character varying,
  CONSTRAINT z_operation_isactive_check CHECK (isactive = ANY (ARRAY['Y'::bpchar, 'N'::bpchar]))
)
WITH (
  OIDS=FALSE
);
ALTER TABLE adempiere.z_operation
  OWNER TO postgres;

adempiere.z_itemoperation

-- Table: adempiere.z_itemoperation

-- DROP TABLE adempiere.z_itemoperation;

CREATE TABLE adempiere.z_itemoperation
(
  z_itemoperation_id numeric(10,0) NOT NULL,
  ad_client_id numeric(10,0) NOT NULL,
  ad_org_id numeric(10,0) NOT NULL,
  isactive character(1) NOT NULL DEFAULT 'Y'::bpchar,
  created timestamp without time zone NOT NULL DEFAULT now(),
  createdby numeric(10,0) NOT NULL,
  updated timestamp without time zone NOT NULL DEFAULT now(),
  updatedby numeric(10,0) NOT NULL,
  value character varying(40) NOT NULL,
  name character varying(60) NOT NULL,
  description character varying(255),
  help character varying(2000),
  z_resource_id numeric(10,0) NOT NULL,
  z_item_id numeric(10,0) NOT NULL,
  z_operation_id numeric(10,0) NOT NULL,
  usage numeric,
  z_uom_id numeric(10,0) NOT NULL,
  min_transfer_qty numeric,
  z_itemoperation_uu character varying(36) DEFAULT NULL::character varying,
  CONSTRAINT z_itemoperation_isactive_check CHECK (isactive = ANY (ARRAY['Y'::bpchar, 'N'::bpchar]))
)
WITH (
  OIDS=FALSE
);
ALTER TABLE adempiere.z_itemoperation
  OWNER TO postgres;

Table: adempiere.z_item

-- Table: adempiere.z_item

-- DROP TABLE adempiere.z_item;

CREATE TABLE adempiere.z_item
(
  z_item_id numeric(10,0) NOT NULL,
  ad_client_id numeric(10,0) NOT NULL,
  ad_org_id numeric(10,0) NOT NULL,
  isactive character(1) NOT NULL DEFAULT 'Y'::bpchar,
  created timestamp without time zone NOT NULL DEFAULT now(),
  createdby numeric(10,0) NOT NULL,
  updated timestamp without time zone NOT NULL DEFAULT now(),
  updatedby numeric(10,0) NOT NULL,
  value character varying(40) NOT NULL,
  name character varying(60) NOT NULL,
  description character varying(255),
  help character varying(2000),
  z_item_uu character varying(36) DEFAULT NULL::character varying,
  CONSTRAINT z_resource_isactive_check CHECK (isactive = ANY (ARRAY['Y'::bpchar, 'N'::bpchar]))
)
WITH (
  OIDS=FALSE
);
ALTER TABLE adempiere.z_item
  OWNER TO postgres;

2014年1月27日 星期一

groovy:getUserForOrder

groovy:getUserForOrder
Callout
=================
import org.compiere.util.DB
import org.compiere.util.Env
import java.math.BigDecimal

int id =Env.getContextAsInt(A_Ctx, "#AD_User_ID");
A_Tab.setValue("訂單確認者_ID", new Integer(id) );

result=""