cocoon-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jo...@apache.org
Subject cvs commit: cocoon-2.1/src/blocks/ojb/samples/woody employee.js
Date Wed, 04 Feb 2004 14:18:15 GMT
joerg       2004/02/04 06:18:15

  Modified:    src/blocks/ojb/samples/woody employee.js
  Log:
  fixed line endings issue
  
  Revision  Changes    Path
  1.7       +32 -32    cocoon-2.1/src/blocks/ojb/samples/woody/employee.js
  
  Index: employee.js
  ===================================================================
  RCS file: /home/cvs/cocoon-2.1/src/blocks/ojb/samples/woody/employee.js,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -r1.6 -r1.7
  --- employee.js	18 Oct 2003 06:39:58 -0000	1.6
  +++ employee.js	4 Feb 2004 14:18:15 -0000	1.7
  @@ -1,32 +1,32 @@
  -cocoon.load("resource://org/apache/cocoon/woody/flow/javascript/woody2.js");
  -
  -function employeeform_jdo(form) {
  -
  -	// Get OJB factory
  -   	var factory = cocoon.getComponent(Packages.org.apache.cocoon.ojb.jdo.components.JdoPMF.ROLE);
  -
  -    // Create a empty Bean
  -    var bean = new Packages.org.apache.cocoon.ojb.samples.Employee();
  -    var ojbEmployee = Packages.org.apache.cocoon.ojb.samples.EmployeeImpl();
  -
  -	// Fill some initial data to the bean
  -	bean.setId(1);
  -    // Load bean based on the given PrimaryKey
  -    ojbEmployee.retrieve(bean, factory);
  -
  -    // Load the Bean to the form
  -    form.load(bean);
  -    // Let woody handle the form
  -    form.showForm("jdo/woody/employee-form-display");
  -    // Update the Bean based on user input
  -	form.save(bean);
  -
  -    // Update Bean in Database
  -	ojbEmployee.update(bean, factory);
  -	// Clean up the operation
  -	cocoon.releaseComponent(factory);
  -
  -    // Send response to the user
  -    cocoon.request.setAttribute("employeeform", form.getWidget());
  -    cocoon.sendPage("jdo/woody/employee-form-success");
  -}
  +cocoon.load("resource://org/apache/cocoon/woody/flow/javascript/woody2.js");
  +
  +function employeeform_jdo(form) {
  +
  +	// Get OJB factory
  +   	var factory = cocoon.getComponent(Packages.org.apache.cocoon.ojb.jdo.components.JdoPMF.ROLE);
  +
  +    // Create a empty Bean
  +    var bean = new Packages.org.apache.cocoon.ojb.samples.Employee();
  +    var ojbEmployee = Packages.org.apache.cocoon.ojb.samples.EmployeeImpl();
  +
  +	// Fill some initial data to the bean
  +	bean.setId(1);
  +    // Load bean based on the given PrimaryKey
  +    ojbEmployee.retrieve(bean, factory);
  +
  +    // Load the Bean to the form
  +    form.load(bean);
  +    // Let woody handle the form
  +    form.showForm("jdo/woody/employee-form-display");
  +    // Update the Bean based on user input
  +	form.save(bean);
  +
  +    // Update Bean in Database
  +	ojbEmployee.update(bean, factory);
  +	// Clean up the operation
  +	cocoon.releaseComponent(factory);
  +
  +    // Send response to the user
  +    cocoon.request.setAttribute("employeeform", form.getWidget());
  +    cocoon.sendPage("jdo/woody/employee-form-success");
  +}
  
  
  

Mime
View raw message