fmsystem-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Fmsystem-commits] [16184] more on eventplanner


From: sigurdne
Subject: [Fmsystem-commits] [16184] more on eventplanner
Date: Mon, 23 Jan 2017 10:56:26 -0500 (EST)

Revision: 16184
          http://svn.sv.gnu.org/viewvc/?view=rev&root=fmsystem&revision=16184
Author:   sigurdne
Date:     2017-01-23 10:56:25 -0500 (Mon, 23 Jan 2017)
Log Message:
-----------
more on eventplanner

Modified Paths:
--------------
    trunk/eventplanner/inc/class.bovendor.inc.php
    trunk/eventplanner/inc/class.sobooking.inc.php
    trunk/eventplanner/inc/class.uiapplication.inc.php
    trunk/eventplanner/inc/class.uibooking.inc.php
    trunk/eventplanner/inc/class.uicustomer.inc.php
    trunk/eventplanner/inc/class.uievents.inc.php
    trunk/eventplanner/inc/class.uiresource.inc.php
    trunk/eventplanner/inc/class.uivendor.inc.php
    trunk/eventplanner/inc/class.uivendor_report.inc.php
    trunk/eventplanner/inc/model/class.customer.inc.php
    trunk/eventplanner/inc/model/class.vendor.inc.php
    trunk/eventplanner/setup/phpgw_no.lang
    trunk/eventplanner/setup/setup.inc.php
    trunk/eventplanner/setup/tables_current.inc.php
    trunk/eventplanner/setup/tables_update.inc.php
    trunk/eventplanner/templates/base/application.xsl
    trunk/eventplanner/templates/base/booking.xsl
    trunk/eventplanner/templates/base/customer.xsl
    trunk/eventplanner/templates/base/vendor.xsl
    trunk/eventplannerfrontend/index.php
    trunk/eventplannerfrontend/js/portico/booking.edit.js
    trunk/eventplannerfrontend/templates/base/booking.xsl
    trunk/eventplannerfrontend/templates/base/customer.xsl

Added Paths:
-----------
    trunk/eventplannerfrontend/inc/class.uicustomer.inc.php
    trunk/eventplannerfrontend/inc/class.uivendor_report.inc.php
    trunk/eventplannerfrontend/js/portico/validate.js
    trunk/eventplannerfrontend/templates/base/application.xsl
    trunk/eventplannerfrontend/templates/base/vendor.xsl
    trunk/eventplannerfrontend/templates/base/vendor_report.xsl

Modified: trunk/eventplanner/inc/class.bovendor.inc.php
===================================================================
--- trunk/eventplanner/inc/class.bovendor.inc.php       2017-01-23 15:55:48 UTC 
(rev 16183)
+++ trunk/eventplanner/inc/class.bovendor.inc.php       2017-01-23 15:56:25 UTC 
(rev 16184)
@@ -86,7 +86,7 @@
        //                              $entry['status'] = 
$status_text[$entry['status']];
                                        if($organization_number)
                                        {
-                                               $entry['name'] .= " 
[{$entry['vendor_organization_number']}]";
+                                               $entry['name'] .= " 
[{$entry['organization_number']}]";
                                        }
                                        $entry['created'] = 
$GLOBALS['phpgw']->common->show_date($entry['created']);
                                        $entry['modified'] = 
$GLOBALS['phpgw']->common->show_date($entry['modified']);

Modified: trunk/eventplanner/inc/class.sobooking.inc.php
===================================================================
--- trunk/eventplanner/inc/class.sobooking.inc.php      2017-01-23 15:55:48 UTC 
(rev 16183)
+++ trunk/eventplanner/inc/class.sobooking.inc.php      2017-01-23 15:56:25 UTC 
(rev 16184)
@@ -157,7 +157,7 @@
                                        break;
                        }
 
-                       $sql .= " {$where} id IN('". implode(',', $ids) . ')';
+                       $sql .= " {$where} id IN(". implode(',', $ids) . ')';
                        $this->db->transaction_begin();
                        
                        $this->db->query($sql,__LINE__,__FILE__);

Modified: trunk/eventplanner/inc/class.uiapplication.inc.php
===================================================================
--- trunk/eventplanner/inc/class.uiapplication.inc.php  2017-01-23 15:55:48 UTC 
(rev 16183)
+++ trunk/eventplanner/inc/class.uiapplication.inc.php  2017-01-23 15:56:25 UTC 
(rev 16184)
@@ -177,7 +177,7 @@
                                (
                                'my_name' => 'view',
                                'text' => lang('show'),
-                               'action' => 
$GLOBALS['phpgw']->link('/index.php', array
+                               'action' => self::link( array
                                        (
                                        'menuaction' => 
'eventplanner.uiapplication.view'
                                )),
@@ -188,7 +188,7 @@
                                (
                                'my_name' => 'edit',
                                'text' => lang('edit'),
-                               'action' => 
$GLOBALS['phpgw']->link('/index.php', array
+                               'action' => self::link(array
                                        (
                                        'menuaction' => 
'eventplanner.uiapplication.edit'
                                )),
@@ -385,8 +385,8 @@
 //                     die();
                        $data = array(
                                'datatable_def' => $datatable_def,
-                               'form_action' => 
$GLOBALS['phpgw']->link('/index.php', array('menuaction' => 
'eventplanner.uiapplication.save')),
-                               'cancel_url' => 
$GLOBALS['phpgw']->link('/index.php', array('menuaction' => 
'eventplanner.uiapplication.index',)),
+                               'form_action' => self::link(array('menuaction' 
=> 'eventplanner.uiapplication.save')),
+                               'cancel_url' => self::link(array('menuaction' 
=> 'eventplanner.uiapplication.index',)),
                                'application' => $application,
                                'new_vendor_url' => 
self::link(array('menuaction' => 'eventplanner.uivendor.add')),
                                'list_case_officer' => array('options' => 
$case_officer_options),

Modified: trunk/eventplanner/inc/class.uibooking.inc.php
===================================================================
--- trunk/eventplanner/inc/class.uibooking.inc.php      2017-01-23 15:55:48 UTC 
(rev 16183)
+++ trunk/eventplanner/inc/class.uibooking.inc.php      2017-01-23 15:56:25 UTC 
(rev 16184)
@@ -128,7 +128,7 @@
                                (
                                'my_name' => 'view',
                                'text' => lang('show'),
-                               'action' => 
$GLOBALS['phpgw']->link('/index.php', array
+                               'action' => self::link(array
                                        (
                                        'menuaction' => 
"{$this->currentapp}.uibooking.view"
                                )),
@@ -139,7 +139,7 @@
                                (
                                'my_name' => 'edit',
                                'text' => lang('edit'),
-                               'action' => 
$GLOBALS['phpgw']->link('/index.php', array
+                               'action' => self::link(array
                                        (
                                        'menuaction' => 
"{$this->currentapp}.uibooking.edit"
                                )),
@@ -259,7 +259,7 @@
                                        'type' => 'custom',
                                        'className' => 'add',
                                        'custom_code' => "
-                                                               
add_report('vendor');"
+                                                               
add_report('customer');"
                                )
                        );
                        $datatable_def[] = array(
@@ -303,15 +303,28 @@
                                }
                        }
 
+                       
+                       
+                       
+                       $application_url = self::link(array('menuaction' => 
"{$this->currentapp}.uiapplication.edit", 'id' => $booking->application_id));
+                       $lang_application = lang('application');
+                       if($this->currentapp == 'eventplannerfrontend')
+                       {
+                               $application_url = 
self::link(array('menuaction' => "{$this->currentapp}.uievents.edit", 'id' => 
$booking->application_id));
+                               $lang_application = lang('event');
+                       }
+
+
                        $data = array(
                                'datatable_def' => $datatable_def,
-                               'form_action' => 
$GLOBALS['phpgw']->link('/index.php', array('menuaction' => 
"{$this->currentapp}.uibooking.save")),
-                               'cancel_url' => 
$GLOBALS['phpgw']->link('/index.php', array('menuaction' => 
"{$this->currentapp}.uibooking.index",)),
+                               'form_action' => self::link(array('menuaction' 
=> "{$this->currentapp}.uibooking.save")),
+                               'cancel_url' => self::link(array('menuaction' 
=> "{$this->currentapp}.uibooking.index",)),
                                'booking' => $booking,
                                'application' => $application,
                                'application_type_list' => 
$application_type_list,
                                'new_customer_url' => 
self::link(array('menuaction' => "{$this->currentapp}.uicustomer.add")),
-                               'application_url' => 
self::link(array('menuaction' => "{$this->currentapp}.uiapplication.edit", 'id' 
=> $booking->application_id)),
+                               'application_url' => $application_url,
+                               'lang_application' => $lang_application,
                                'customer_url' => self::link(array('menuaction' 
=> "{$this->currentapp}.uicustomer.edit", 'id' => $booking->customer_id)),
                                'mode' => $mode,
                                'tabs' => 
phpgwapi_jquery::tabview_generate($tabs, $active_tab),
@@ -318,7 +331,7 @@
                                'value_active_tab' => $active_tab
                        );
                        phpgwapi_jquery::formvalidator_generate(array());
-                       self::add_javascript('eventplanner', 'portico', 
'booking.edit.js');
+                       self::add_javascript($this->currentapp, 'portico', 
'booking.edit.js');
                        phpgwapi_jquery::load_widget('autocomplete');
                        self::render_template_xsl(array('booking', 
'datatable_inline'), array($mode => $data));
                }

Modified: trunk/eventplanner/inc/class.uicustomer.inc.php
===================================================================
--- trunk/eventplanner/inc/class.uicustomer.inc.php     2017-01-23 15:55:48 UTC 
(rev 16183)
+++ trunk/eventplanner/inc/class.uicustomer.inc.php     2017-01-23 15:56:25 UTC 
(rev 16184)
@@ -46,7 +46,8 @@
 
                protected
                        $fields,
-                       $permissions;
+                       $permissions,
+                       $currentapp;
 
                public function __construct()
                {
@@ -56,6 +57,7 @@
                        $this->bo = createObject('eventplanner.bocustomer');
                        $this->fields = eventplanner_customer::get_fields();
                        $this->permissions = 
eventplanner_customer::get_instance()->get_permission_array();
+                       $this->currentapp = 
$GLOBALS['phpgw_info']['flags']['currentapp'];
                }
 
                private function get_category_options( $selected = 0 )
@@ -118,11 +120,11 @@
                                ),
                                'datatable' => array(
                                        'source' => self::link(array(
-                                               'menuaction' => 
'eventplanner.uicustomer.index',
+                                               'menuaction' => 
"{$this->currentapp}.uicustomer.index",
                                                'phpgw_return_as' => 'json'
                                        )),
                                        'allrows' => true,
-                                       'new_item' => 
self::link(array('menuaction' => 'eventplanner.uicustomer.add')),
+                                       'new_item' => 
self::link(array('menuaction' => "{$this->currentapp}.uicustomer.add")),
                                        'editor_action' => '',
                                        'field' => parent::_get_fields()
                                )
@@ -141,9 +143,9 @@
                                (
                                'my_name' => 'view',
                                'text' => lang('show'),
-                               'action' => 
$GLOBALS['phpgw']->link('/index.php', array
+                               'action' => self::link(array
                                        (
-                                       'menuaction' => 
'eventplanner.uicustomer.view'
+                                       'menuaction' => 
"{$this->currentapp}.uicustomer.view"
                                )),
                                'parameters' => json_encode($parameters)
                        );
@@ -152,9 +154,9 @@
                                (
                                'my_name' => 'edit',
                                'text' => lang('edit'),
-                               'action' => 
$GLOBALS['phpgw']->link('/index.php', array
+                               'action' => self::link(array
                                        (
-                                       'menuaction' => 
'eventplanner.uicustomer.edit'
+                                       'menuaction' => 
"{$this->currentapp}.uicustomer.edit"
                                )),
                                'parameters' => json_encode($parameters)
                        );
@@ -224,8 +226,8 @@
 
                        $data = array(
                                'datatable_def' => $datatable_def,
-                               'form_action' => 
$GLOBALS['phpgw']->link('/index.php', array('menuaction' => 
'eventplanner.uicustomer.save')),
-                               'cancel_url' => 
$GLOBALS['phpgw']->link('/index.php', array('menuaction' => 
'eventplanner.uicustomer.index',)),
+                               'form_action' => self::link(array('menuaction' 
=> "{$this->currentapp}.uicustomer.save")),
+                               'cancel_url' => self::link(array('menuaction' 
=> "{$this->currentapp}.uicustomer.index",)),
                                'customer' => $customer,
                                'category_list' => array('options' => 
$this->get_category_options( $customer->category_id )),
                                'mode' => $mode,
@@ -233,7 +235,7 @@
                                'value_active_tab' => $active_tab
                        );
                        phpgwapi_jquery::formvalidator_generate(array());
-                       self::add_javascript('eventplanner', 'portico', 
'customer.edit.js');
+                       self::add_javascript('eventplannerfrontend', 'portico', 
'validate.js');
                        self::render_template_xsl(array('customer', 
'datatable_inline'), array($mode => $data));
                }
 

Modified: trunk/eventplanner/inc/class.uievents.inc.php
===================================================================
--- trunk/eventplanner/inc/class.uievents.inc.php       2017-01-23 15:55:48 UTC 
(rev 16183)
+++ trunk/eventplanner/inc/class.uievents.inc.php       2017-01-23 15:56:25 UTC 
(rev 16184)
@@ -52,6 +52,10 @@
                        $this->bo = createObject('eventplanner.boapplication');
                        $this->cats = & $this->bo->cats;
                        $this->fields = eventplanner_application::get_fields();
+                       unset($this->fields['modified']);
+                       unset($this->fields['created']);
+                       unset($this->fields['contact_email']);
+                       unset($this->fields['case_officer_name']);
                        $this->permissions = 
eventplanner_application::get_instance()->get_permission_array();
                        $this->currentapp = 
$GLOBALS['phpgw_info']['flags']['currentapp'];
 
@@ -163,7 +167,7 @@
                                (
                                'my_name' => 'view',
                                'text' => lang('show'),
-                               'action' => 
$GLOBALS['phpgw']->link('/index.php', array
+                               'action' => self::link(array
                                        (
                                        'menuaction' => 
"{$this->currentapp}.uievents.edit"
                                )),
@@ -245,7 +249,7 @@
 
                        $data = array(
                                'datatable_def' => $datatable_def,
-                               'cancel_url' => 
$GLOBALS['phpgw']->link('/index.php', array('menuaction' => 
"{$this->currentapp}.uievents.index",)),
+                               'cancel_url' => self::link(array('menuaction' 
=> "{$this->currentapp}.uievents.index",)),
                                'application' => $application,
                                'category_name' => $category[0]['name'],
                                'status_list' => array('options' => 
$this->get_status_options($application->status)),

Modified: trunk/eventplanner/inc/class.uiresource.inc.php
===================================================================
--- trunk/eventplanner/inc/class.uiresource.inc.php     2017-01-23 15:55:48 UTC 
(rev 16183)
+++ trunk/eventplanner/inc/class.uiresource.inc.php     2017-01-23 15:56:25 UTC 
(rev 16184)
@@ -147,7 +147,7 @@
                                (
                                'my_name' => 'view',
                                'text' => lang('show'),
-                               'action' => 
$GLOBALS['phpgw']->link('/index.php', array
+                               'action' => self::link(array
                                        (
                                        'menuaction' => 
'eventplanner.uiresource.view'
                                )),
@@ -158,7 +158,7 @@
                                (
                                'my_name' => 'edit',
                                'text' => lang('edit'),
-                               'action' => 
$GLOBALS['phpgw']->link('/index.php', array
+                               'action' => self::link(array
                                        (
                                        'menuaction' => 
'eventplanner.uiresource.edit'
                                )),
@@ -279,8 +279,8 @@
 
                        $data = array(
                                'datatable_def' => $datatable_def,
-                               'form_action' => 
$GLOBALS['phpgw']->link('/index.php', array('menuaction' => 
'eventplanner.uiresource.save')),
-                               'cancel_url' => 
$GLOBALS['phpgw']->link('/index.php', array('menuaction' => 
'eventplanner.uiresource.index',)),
+                               'form_action' => self::link(array('menuaction' 
=> 'eventplanner.uiresource.save')),
+                               'cancel_url' => self::link(array('menuaction' 
=> 'eventplanner.uiresource.index',)),
                                'resource' => $resource,//->toArray(),
                                'list_executive_officer' => array('options' => 
$executive_officer_options),
                                'step'          => $step,

Modified: trunk/eventplanner/inc/class.uivendor.inc.php
===================================================================
--- trunk/eventplanner/inc/class.uivendor.inc.php       2017-01-23 15:55:48 UTC 
(rev 16183)
+++ trunk/eventplanner/inc/class.uivendor.inc.php       2017-01-23 15:56:25 UTC 
(rev 16184)
@@ -46,7 +46,8 @@
 
                protected
                        $fields,
-                       $permissions;
+                       $permissions,
+                       $currentapp;
 
                public function __construct()
                {
@@ -56,6 +57,7 @@
                        $this->bo = createObject('eventplanner.bovendor');
                        $this->fields = eventplanner_vendor::get_fields();
                        $this->permissions = 
eventplanner_vendor::get_instance()->get_permission_array();
+                       $this->currentapp = 
$GLOBALS['phpgw_info']['flags']['currentapp'];
                }
 
                private function get_category_options( $selected = 0 )
@@ -118,11 +120,11 @@
                                ),
                                'datatable' => array(
                                        'source' => self::link(array(
-                                               'menuaction' => 
'eventplanner.uivendor.index',
+                                               'menuaction' => 
"{$this->currentapp}.uivendor.index",
                                                'phpgw_return_as' => 'json'
                                        )),
                                        'allrows' => true,
-                                       'new_item' => 
self::link(array('menuaction' => 'eventplanner.uivendor.add')),
+                                       'new_item' => 
self::link(array('menuaction' => "{$this->currentapp}.uivendor.add")),
                                        'editor_action' => '',
                                        'field' => parent::_get_fields()
                                )
@@ -141,9 +143,9 @@
                                (
                                'my_name' => 'view',
                                'text' => lang('show'),
-                               'action' => 
$GLOBALS['phpgw']->link('/index.php', array
+                               'action' => self::link(array
                                        (
-                                       'menuaction' => 
'eventplanner.uivendor.view'
+                                       'menuaction' => 
"{$this->currentapp}.uivendor.view"
                                )),
                                'parameters' => json_encode($parameters)
                        );
@@ -152,9 +154,9 @@
                                (
                                'my_name' => 'edit',
                                'text' => lang('edit'),
-                               'action' => 
$GLOBALS['phpgw']->link('/index.php', array
+                               'action' => self::link(array
                                        (
-                                       'menuaction' => 
'eventplanner.uivendor.edit'
+                                       'menuaction' => 
"{$this->currentapp}.uivendor.edit"
                                )),
                                'parameters' => json_encode($parameters)
                        );
@@ -224,8 +226,8 @@
 
                        $data = array(
                                'datatable_def' => $datatable_def,
-                               'form_action' => 
$GLOBALS['phpgw']->link('/index.php', array('menuaction' => 
'eventplanner.uivendor.save')),
-                               'cancel_url' => 
$GLOBALS['phpgw']->link('/index.php', array('menuaction' => 
'eventplanner.uivendor.index',)),
+                               'form_action' => self::link(array('menuaction' 
=> "{$this->currentapp}.uivendor.save")),
+                               'cancel_url' => self::link(array('menuaction' 
=> "{$this->currentapp}.uivendor.index",)),
                                'vendor' => $vendor,
                                'category_list' => array('options' => 
$this->get_category_options( $vendor->category_id )),
                                'mode' => $mode,
@@ -233,7 +235,7 @@
                                'value_active_tab' => $active_tab
                        );
                        phpgwapi_jquery::formvalidator_generate(array());
-                       self::add_javascript('eventplanner', 'portico', 
'vendor.edit.js');
+                       self::add_javascript('eventplannerfrontend', 'portico', 
'validate.js');
                        self::render_template_xsl(array('vendor', 
'datatable_inline'), array($mode => $data));
                }
                

Modified: trunk/eventplanner/inc/class.uivendor_report.inc.php
===================================================================
--- trunk/eventplanner/inc/class.uivendor_report.inc.php        2017-01-23 
15:55:48 UTC (rev 16183)
+++ trunk/eventplanner/inc/class.uivendor_report.inc.php        2017-01-23 
15:56:25 UTC (rev 16184)
@@ -133,7 +133,7 @@
                                (
                                'my_name' => 'view',
                                'text' => lang('show'),
-                               'action' => 
$GLOBALS['phpgw']->link('/index.php', array
+                               'action' => self::link(array
                                        (
                                        'menuaction' => 
'eventplanner.uivendor_report.view'
                                )),
@@ -144,7 +144,7 @@
                                (
                                'my_name' => 'edit',
                                'text' => lang('edit'),
-                               'action' => 
$GLOBALS['phpgw']->link('/index.php', array
+                               'action' => self::link(array
                                        (
                                        'menuaction' => 
'eventplanner.uivendor_report.edit'
                                )),
@@ -234,8 +234,8 @@
                        );
 
                        $data = array(
-                               'form_action' => 
$GLOBALS['phpgw']->link('/index.php', array('menuaction' => 
'eventplanner.uivendor_report.save')),
-                               'cancel_url' => 
$GLOBALS['phpgw']->link('/index.php', array('menuaction' => 
'eventplanner.uivendor_report.index',)),
+                               'form_action' => self::link(array('menuaction' 
=> 'eventplanner.uivendor_report.save')),
+                               'cancel_url' => self::link(array('menuaction' 
=> 'eventplanner.uivendor_report.index',)),
                                'vendor_report' => $vendor_report,
                                'booking'               => $booking,
                                'application'   => $application,

Modified: trunk/eventplanner/inc/model/class.customer.inc.php
===================================================================
--- trunk/eventplanner/inc/model/class.customer.inc.php 2017-01-23 15:55:48 UTC 
(rev 16183)
+++ trunk/eventplanner/inc/model/class.customer.inc.php 2017-01-23 15:56:25 UTC 
(rev 16184)
@@ -52,7 +52,7 @@
                        $address_2,
                        $zip_code,
                        $city,
-                       $customer_organization_number,
+                       $organization_number,
                        $contact_name,
                        $contact_email,
                        $contact_phone,
@@ -59,9 +59,6 @@
                        $account_number,
                        $description,
                        $remark,
-       //              $customer_identifier_type,
-       //              $customer_ssn,
-
                        $comments,
                        $comment;
 
@@ -180,23 +177,9 @@
                                        'query' => true,
                                        'label' => 'contact phone',
                                        ),
-/*                             'customer_identifier_type' => array(
-                                       'action'=> PHPGW_ACL_ADD | 
PHPGW_ACL_EDIT,
-                                       'type' => 'string',
-                                       'required' => true,
-                                       'label' => 'customer_identifier_type',
-                                       ),
-                               'customer_ssn' => array(
+                               'organization_number' => array(
                                        'action'=> PHPGW_ACL_READ | 
PHPGW_ACL_ADD | PHPGW_ACL_EDIT,
                                        'type' => 'string',
-                                       'required' => false,
-                                       'query' => true,
-                                       'sf_validator' => 
createObject('booking.sfValidatorNorwegianSSN', array('full_required' => 
false)),
-                                       'label' => 'customer_ssn'
-                                       ),*/
-                               'customer_organization_number' => array(
-                                       'action'=> PHPGW_ACL_READ | 
PHPGW_ACL_ADD | PHPGW_ACL_EDIT,
-                                       'type' => 'string',
                                        'required' => true,
                                        'query' => true,
                                        'sf_validator' => 
createObject('booking.sfValidatorNorwegianOrganizationNumber', array(), 
array('invalid' => '%field% is invalid')),
@@ -247,9 +230,9 @@
                                        'type' => 'comment'
                                );
                        }
-                       if (!empty($entity->customer_organization_number))
+                       if (!empty($entity->organization_number))
                        {
-                               $entity->customer_organization_number = 
str_replace(' ', '', $entity->customer_organization_number);
+                               $entity->organization_number = str_replace(' ', 
'', $entity->organization_number);
                        }
 
                        $entity->modified = time();

Modified: trunk/eventplanner/inc/model/class.vendor.inc.php
===================================================================
--- trunk/eventplanner/inc/model/class.vendor.inc.php   2017-01-23 15:55:48 UTC 
(rev 16183)
+++ trunk/eventplanner/inc/model/class.vendor.inc.php   2017-01-23 15:56:25 UTC 
(rev 16184)
@@ -52,7 +52,7 @@
                        $address_2,
                        $zip_code,
                        $city,
-                       $vendor_organization_number,
+                       $organization_number,
                        $contact_name,
                        $contact_email,
                        $contact_phone,
@@ -59,9 +59,6 @@
                        $account_number,
                        $description,
                        $remark,
-       //              $vendor_identifier_type,
-       //              $vendor_ssn,
-
                        $comments,
                        $comment;
 
@@ -180,23 +177,9 @@
                                        'query' => true,
                                        'label' => 'contact phone',
                                        ),
-/*                             'vendor_identifier_type' => array(
-                                       'action'=> PHPGW_ACL_ADD | 
PHPGW_ACL_EDIT,
-                                       'type' => 'string',
-                                       'required' => true,
-                                       'label' => 'vendor_identifier_type',
-                                       ),
-                               'vendor_ssn' => array(
+                               'organization_number' => array(
                                        'action'=> PHPGW_ACL_READ | 
PHPGW_ACL_ADD | PHPGW_ACL_EDIT,
                                        'type' => 'string',
-                                       'required' => false,
-                                       'query' => true,
-                                       'sf_validator' => 
createObject('booking.sfValidatorNorwegianSSN', array('full_required' => 
false)),
-                                       'label' => 'vendor_ssn'
-                                       ),*/
-                               'vendor_organization_number' => array(
-                                       'action'=> PHPGW_ACL_READ | 
PHPGW_ACL_ADD | PHPGW_ACL_EDIT,
-                                       'type' => 'string',
                                        'required' => true,
                                        'query' => true,
                                        'sf_validator' => 
createObject('booking.sfValidatorNorwegianOrganizationNumber', array(), 
array('invalid' => '%field% is invalid')),

Modified: trunk/eventplanner/setup/phpgw_no.lang
===================================================================
--- trunk/eventplanner/setup/phpgw_no.lang      2017-01-23 15:55:48 UTC (rev 
16183)
+++ trunk/eventplanner/setup/phpgw_no.lang      2017-01-23 15:56:25 UTC (rev 
16184)
@@ -25,8 +25,8 @@
 new    eventplanner    no      Ny
 show   eventplanner    no      vis
 history        eventplanner    no      Historikk
-date start     eventplanner    no      Første dato
-date end       eventplanner    no      Siste dato
+date start     eventplanner    no      Første arrangementsdato
+date end       eventplanner    no      Siste arrangementsdato
 contact name   eventplanner    no      Kontaktperson
 contact email  eventplanner    no      Epost kontaktperson
 contact phone  eventplanner    no      Tlf. kontaktperson
@@ -39,6 +39,8 @@
 demands        eventplanner    no      Forutsetning
 payment        eventplanner    no      Betaling
 labour support eventplanner    no      Opprigging/nedrigging
+rig up min before      eventplanner    no      Antatt oppriggingstid
+rig down min after     eventplanner    no      Antatt nedriggingstid
 technical support      eventplanner    no      Teknisk støtte
 charge per unit        eventplanner    no      Betaling pr 
forestilling/kurs/omvisning
 event timespan eventplanner    no      Programvarighet (minutter)
@@ -63,7 +65,7 @@
 stage requirement      eventplanner    no      Krav til scene
 width  eventplanner    no      Bredde
 depth  eventplanner    no      Dybde
-wardrobe       eventplanner    no      Behov for utøvergarderobe
+wardrobe       eventplanner    no      Kryss av for behov for utøvergarderobe
 audience limit eventplanner    no      Maksimum antall publikum
 raider eventplanner    no      Andre raiderønsker – (valgfri)
 vendor report  eventplanner    no      Utøverrapport
@@ -97,4 +99,7 @@
 can not delete booking with customer   eventplanner    no      Kan ikke slette 
booking som er koplet med mottakersted
 report eventplanner    no      Rapport
 events eventplanner    no      Arrangementer
-event  eventplanner    no      Arrangement
\ No newline at end of file
+event  eventplanner    no      Arrangement
+please enter a valid organization number       eventplanner    no      Angi et 
gyldig organisasjonsnummer
+please enter a valid account number    eventplanner    no      Angi et gyldig 
kontonummer
+program data   eventplanner    no      Om programmet
\ No newline at end of file

Modified: trunk/eventplanner/setup/setup.inc.php
===================================================================
--- trunk/eventplanner/setup/setup.inc.php      2017-01-23 15:55:48 UTC (rev 
16183)
+++ trunk/eventplanner/setup/setup.inc.php      2017-01-23 15:56:25 UTC (rev 
16184)
@@ -11,7 +11,7 @@
         * @version $Id: setup.inc.php 14728 2016-02-11 22:28:46Z sigurdne $
         */
        $setup_info['eventplanner']['name'] = 'eventplanner';
-       $setup_info['eventplanner']['version'] = '0.9.18.003';
+       $setup_info['eventplanner']['version'] = '0.9.18.004';
        $setup_info['eventplanner']['app_order'] = 20;
        $setup_info['eventplanner']['enable'] = 1;
        $setup_info['eventplanner']['app_group'] = 'office';

Modified: trunk/eventplanner/setup/tables_current.inc.php
===================================================================
--- trunk/eventplanner/setup/tables_current.inc.php     2017-01-23 15:55:48 UTC 
(rev 16183)
+++ trunk/eventplanner/setup/tables_current.inc.php     2017-01-23 15:56:25 UTC 
(rev 16184)
@@ -38,9 +38,7 @@
                                'description' => array('type' => 'text', 
'nullable' => False),
                                'remark' => array('type' => 'text', 'nullable' 
=> True),
                                'secret' => array('type' => 'text', 'nullable' 
=> False),
-                               'vendor_identifier_type' => array('type' => 
'varchar', 'precision' => '255','nullable' => True),
-                               'vendor_organization_number' => array('type' => 
'varchar', 'precision' => '9','nullable' => True),
-                               'vendor_ssn' => array('type' => 'varchar', 
'precision' => '12', 'nullable' => True),
+                               'organization_number' => array('type' => 
'varchar', 'precision' => '9','nullable' => True),
                                'created' => array('type' => 'int', 'precision' 
=> '8',  'nullable' => False, 'default' => 'current_timestamp'),
                                'modified' => array('type' => 'int', 
'precision' => '8', 'nullable' => False, 'default' => 'current_timestamp'),
                                'json_representation' => array('type' => 
'jsonb', 'nullable' => true),
@@ -95,9 +93,7 @@
                                'description' => array('type' => 'text', 
'nullable' => False),
                                'remark' => array('type' => 'text', 'nullable' 
=> True),
                                'secret' => array('type' => 'text', 'nullable' 
=> False),
-                               'customer_identifier_type' => array('type' => 
'varchar', 'precision' => '255','nullable' => True),
-                               'customer_organization_number' => array('type' 
=> 'varchar', 'precision' => '9','nullable' => True),
-                               'customer_ssn' => array('type' => 'varchar', 
'precision' => '12', 'nullable' => True),
+                               'organization_number' => array('type' => 
'varchar', 'precision' => '9','nullable' => True),
                                'created' => array('type' => 'int', 'precision' 
=> '8',  'nullable' => False, 'default' => 'current_timestamp'),
                                'modified' => array('type' => 'int', 
'precision' => '8', 'nullable' => False, 'default' => 'current_timestamp'),
                                'json_representation' => array('type' => 
'jsonb', 'nullable' => true),

Modified: trunk/eventplanner/setup/tables_update.inc.php
===================================================================
--- trunk/eventplanner/setup/tables_update.inc.php      2017-01-23 15:55:48 UTC 
(rev 16183)
+++ trunk/eventplanner/setup/tables_update.inc.php      2017-01-23 15:56:25 UTC 
(rev 16184)
@@ -59,3 +59,24 @@
                }
                return $GLOBALS['setup_info']['eventplanner']['currentver'];
        }
+
+       $test[] = '0.9.18.003';
+
+       function eventplanner_upgrade0_9_18_003()
+       {
+               $GLOBALS['phpgw_setup']->oProc->m_odb->transaction_begin();
+
+               
$GLOBALS['phpgw_setup']->oProc->RenameColumn('eventplanner_vendor', 
'vendor_organization_number', 'organization_number');
+               
$GLOBALS['phpgw_setup']->oProc->RenameColumn('eventplanner_customer', 
'customer_organization_number', 'organization_number');
+
+               
$GLOBALS['phpgw_setup']->oProc->DropColumn('eventplanner_vendor', array(), 
'vendor_identifier_type');
+               
$GLOBALS['phpgw_setup']->oProc->DropColumn('eventplanner_vendor', array(), 
'vendor_ssn');
+               
$GLOBALS['phpgw_setup']->oProc->DropColumn('eventplanner_customer', array(), 
'customer_identifier_type');
+               
$GLOBALS['phpgw_setup']->oProc->DropColumn('eventplanner_customer', array(), 
'customer_ssn');
+
+               if($GLOBALS['phpgw_setup']->oProc->m_odb->transaction_commit())
+               {
+                       $GLOBALS['setup_info']['eventplanner']['currentver'] = 
'0.9.18.004';
+               }
+               return $GLOBALS['setup_info']['eventplanner']['currentver'];
+       }

Modified: trunk/eventplanner/templates/base/application.xsl
===================================================================
--- trunk/eventplanner/templates/base/application.xsl   2017-01-23 15:55:48 UTC 
(rev 16183)
+++ trunk/eventplanner/templates/base/application.xsl   2017-01-23 15:56:25 UTC 
(rev 16184)
@@ -203,6 +203,11 @@
                                                                        
</xsl:attribute>
                                                                </input>
                                                        </div>
+                                               </fieldset>
+                                               <fieldset>
+                                                       <legend>
+                                                               <xsl:value-of 
select="php:function('lang', 'program data')"/>
+                                                       </legend>
                                                        <div 
class="pure-control-group">
                                                                <label>
                                                                        
<xsl:value-of select="php:function('lang', 'program title')"/>
@@ -266,7 +271,7 @@
                                                                </div>
 
                                                        </div>
-                                       
+
                                                        <div 
class="pure-control-group">
                                                                <xsl:variable 
name="lang_date_start">
                                                                        
<xsl:value-of select="php:function('lang', 'date start')"/>
@@ -368,7 +373,7 @@
                                                                </label>
                                                                <input 
id="total_amount" type="text" disabled="disabled"/>
                                                        </div>
-                                                       
+
                                                        <div 
class="pure-control-group">
                                                                <label>
                                                                        
<xsl:value-of select="php:function('lang', 'remark')"/>
@@ -549,8 +554,10 @@
                                                                                
</thead>
                                                                                
<tbody>
                                                                                
        <tr>
-                                                                               
                <td>Hjelp til opprigging</td>
                                                                                
                <td>
+                                                                               
                        <xsl:value-of select="php:function('lang', 'rig up min 
before')"/>
+                                                                               
                </td>
+                                                                               
                <td>
                                                                                
                        <input type="text" id="rig_up_min_before" 
name="rig_up_min_before" value="{application/rig_up_min_before}" size="3">
                                                                                
                                <xsl:attribute name="data-validation">
                                                                                
                                        <xsl:text>number</xsl:text>
@@ -560,13 +567,12 @@
                                                                                
                                </xsl:attribute>
                                                                                
                        </input>
                                                                                
                </td>
-
                                                                                
        </tr>
-                                                                               
                                                                                
        <tr>
-                                                                               
                <td>Hjelp til nedrigging</td>
-
                                                                                
                <td>
+                                                                               
                        <xsl:value-of select="php:function('lang', 'rig down 
min after')"/>
+                                                                               
                </td>
+                                                                               
                <td>
                                                                                
                        <input type="text" id="rig_down_min_after" 
name="rig_down_min_after" value="{application/rig_down_min_after}" size="3">
                                                                                
                                <xsl:attribute name="data-validation">
                                                                                
                                        <xsl:text>number</xsl:text>
@@ -686,7 +692,7 @@
                                        </div>
                                        <div id='calendar'>
                                                <fieldset>
-                                       
+
                                                        <div 
class="pure-control-group">
                                                                <label>
                                                                        
<xsl:value-of select="php:function('lang', 'date start')"/>

Modified: trunk/eventplanner/templates/base/booking.xsl
===================================================================
--- trunk/eventplanner/templates/base/booking.xsl       2017-01-23 15:55:48 UTC 
(rev 16183)
+++ trunk/eventplanner/templates/base/booking.xsl       2017-01-23 15:56:25 UTC 
(rev 16184)
@@ -99,7 +99,7 @@
                                                <div class="pure-control-group">
                                                        <label>
                                                                <a 
href="{application_url}" target="_blank">
-                                                                       
<xsl:value-of select="php:function('lang', 'application')"/>
+                                                                       
<xsl:value-of select="lang_application"/>
                                                                </a>
 
                                                        </label>
@@ -229,7 +229,7 @@
                                                                        
<xsl:text>required</xsl:text>
                                                                </xsl:attribute>
                                                                <xsl:attribute 
name="placeholder">
-                                                                       
<xsl:value-of select="php:function('lang', 'contact_name')"/>
+                                                                       
<xsl:value-of select="php:function('lang', 'contact name')"/>
                                                                </xsl:attribute>
                                                        </input>
                                                </div>
@@ -263,7 +263,7 @@
                                                                        
<xsl:text>required</xsl:text>
                                                                </xsl:attribute>
                                                                <xsl:attribute 
name="placeholder">
-                                                                       
<xsl:value-of select="php:function('lang', 'contact_phone')"/>
+                                                                       
<xsl:value-of select="php:function('lang', 'contact phone')"/>
                                                                </xsl:attribute>
                                                        </input>
                                                </div>
@@ -360,7 +360,7 @@
                                                </div>
                                                <div class="pure-control-group">
                                                        <label>
-                                                               <xsl:value-of 
select="php:function('lang', 'details')"/>
+                                                               <xsl:value-of 
select="php:function('lang', 'history')"/>
                                                        </label>
                                                        <div 
class="pure-custom">
                                                                <xsl:for-each 
select="datatable_def">

Modified: trunk/eventplanner/templates/base/customer.xsl
===================================================================
--- trunk/eventplanner/templates/base/customer.xsl      2017-01-23 15:55:48 UTC 
(rev 16183)
+++ trunk/eventplanner/templates/base/customer.xsl      2017-01-23 15:56:25 UTC 
(rev 16184)
@@ -26,7 +26,7 @@
 
        <div>
                <script type="text/javascript">
-                       var lang = <xsl:value-of 
select="php:function('js_lang', 'Name or company is required')"/>;
+                       var lang = <xsl:value-of 
select="php:function('js_lang', 'Name or company is required', 'please enter a 
valid organization number', 'please enter a valid account number')"/>;
                </script>
                <form id="form" name="form" method="post" 
action="{$form_action}" class="pure-form pure-form-aligned">
                        <div id="tab-content">
@@ -88,10 +88,12 @@
                                                </div>
                                                <div class="pure-control-group">
                                                        <xsl:variable 
name="lang_address_1">
-                                                               <xsl:value-of 
select="php:function('lang', 'address_1')"/>
+                                                               <xsl:value-of 
select="php:function('lang', 'address')"/>
+                                                               <xsl:text> 
1</xsl:text>
                                                        </xsl:variable>
                                                        <xsl:variable 
name="lang_address_2">
-                                                               <xsl:value-of 
select="php:function('lang', 'address_2')"/>
+                                                               <xsl:value-of 
select="php:function('lang', 'address')"/>
+                                                               <xsl:text> 
2</xsl:text>
                                                        </xsl:variable>
                                                        <label>
                                                                <xsl:value-of 
select="php:function('lang', 'address')"/>
@@ -113,7 +115,7 @@
                                                </div>
                                                <div class="pure-control-group">
                                                        <label>
-                                                               <xsl:value-of 
select="php:function('lang', 'postal_code_place')"/>
+                                                               <xsl:value-of 
select="php:function('lang', 'zip code')"/>
                                                        </label>
                                                        <input type="text" 
name="zip_code" value="{customer/zip_code}">
                                                                <xsl:attribute 
name="data-validation">
@@ -120,7 +122,7 @@
                                                                        
<xsl:text>required</xsl:text>
                                                                </xsl:attribute>
                                                                <xsl:attribute 
name="placeholder">
-                                                                       
<xsl:value-of select="php:function('lang', 'zip_code')"/>
+                                                                       
<xsl:value-of select="php:function('lang', 'zip code')"/>
                                                                </xsl:attribute>
                                                        </input>
                                                        <input type="text" 
name="city" value="{customer/city}">
@@ -134,14 +136,14 @@
                                                </div>
                                                <div class="pure-control-group">
                                                        <label>
-                                                               <xsl:value-of 
select="php:function('lang', 'customer_organization_number')"/>
+                                                               <xsl:value-of 
select="php:function('lang', 'organization number')"/>
                                                        </label>
-                                                       <input type="text" 
id="lastname" name="customer_organization_number" 
value="{customer/customer_organization_number}">
+                                                       <input type="text" 
id="organization_number" name="organization_number" 
value="{customer/organization_number}">
                                                                <xsl:attribute 
name="data-validation">
-                                                                       
<xsl:text>required</xsl:text>
+                                                                       
<xsl:text>organization_number</xsl:text>
                                                                </xsl:attribute>
                                                                <xsl:attribute 
name="placeholder">
-                                                                       
<xsl:value-of select="php:function('lang', 'customer_organization_number')"/>
+                                                                       
<xsl:value-of select="php:function('lang', 'organization number')"/>
                                                                </xsl:attribute>
                                                        </input>
                                                </div>
@@ -154,7 +156,7 @@
                                                                        
<xsl:text>required</xsl:text>
                                                                </xsl:attribute>
                                                                <xsl:attribute 
name="placeholder">
-                                                                       
<xsl:value-of select="php:function('lang', 'contact_name')"/>
+                                                                       
<xsl:value-of select="php:function('lang', 'contact name')"/>
                                                                </xsl:attribute>
                                                        </input>
                                                </div>
@@ -188,20 +190,20 @@
                                                                        
<xsl:text>required</xsl:text>
                                                                </xsl:attribute>
                                                                <xsl:attribute 
name="placeholder">
-                                                                       
<xsl:value-of select="php:function('lang', 'contact_phone')"/>
+                                                                       
<xsl:value-of select="php:function('lang', 'contact phone')"/>
                                                                </xsl:attribute>
                                                        </input>
                                                </div>
                                                <div class="pure-control-group">
                                                        <label>
-                                                               <xsl:value-of 
select="php:function('lang', 'account_number')"/>
+                                                               <xsl:value-of 
select="php:function('lang', 'account number')"/>
                                                        </label>
-                                                       <input type="text" 
name="account_number" value="{customer/account_number}">
+                                                       <input type="text" 
id="account_number" name="account_number" value="{customer/account_number}">
                                                                <xsl:attribute 
name="data-validation">
-                                                                       
<xsl:text>required</xsl:text>
+                                                                       
<xsl:text>account_number</xsl:text>
                                                                </xsl:attribute>
                                                                <xsl:attribute 
name="placeholder">
-                                                                       
<xsl:value-of select="php:function('lang', 'account_number')"/>
+                                                                       
<xsl:value-of select="php:function('lang', 'account number')"/>
                                                                </xsl:attribute>
                                                        </input>
                                                </div>
@@ -231,7 +233,7 @@
                                                </div>
                                                <div class="pure-control-group">
                                                        <label>
-                                                               <xsl:value-of 
select="php:function('lang', 'details')"/>
+                                                               <xsl:value-of 
select="php:function('lang', 'history')"/>
                                                        </label>
                                                        <div 
class="pure-custom">
                                                                <xsl:for-each 
select="datatable_def">

Modified: trunk/eventplanner/templates/base/vendor.xsl
===================================================================
--- trunk/eventplanner/templates/base/vendor.xsl        2017-01-23 15:55:48 UTC 
(rev 16183)
+++ trunk/eventplanner/templates/base/vendor.xsl        2017-01-23 15:56:25 UTC 
(rev 16184)
@@ -138,7 +138,7 @@
                                                        <label>
                                                                <xsl:value-of 
select="php:function('lang', 'organization number')"/>
                                                        </label>
-                                                       <input type="text" 
id="lastname" name="vendor_organization_number" 
value="{vendor/vendor_organization_number}">
+                                                       <input type="text" 
id="organization_number" name="organization_number" 
value="{vendor/organization_number}">
                                                                <xsl:attribute 
name="data-validation">
                                                                        
<xsl:text>required</xsl:text>
                                                                </xsl:attribute>

Added: trunk/eventplannerfrontend/inc/class.uicustomer.inc.php
===================================================================
--- trunk/eventplannerfrontend/inc/class.uicustomer.inc.php                     
        (rev 0)
+++ trunk/eventplannerfrontend/inc/class.uicustomer.inc.php     2017-01-23 
15:56:25 UTC (rev 16184)
@@ -0,0 +1,22 @@
+<?php
+       phpgw::import_class('eventplanner.uicustomer');
+
+       class eventplannerfrontend_uicustomer extends eventplanner_uicustomer
+       {
+
+               public function __construct()
+               {
+                       $GLOBALS['phpgw']->translation->add_app('eventplanner');
+                       parent::__construct();
+               }
+
+               public function query()
+               {
+                       $params = $this->bo->build_default_read_params();
+                       $values = $this->bo->read($params);
+                       array_walk($values["results"], array($this, 
"_add_links"), "eventplannerfrontend.uicustomer.edit");
+
+                       return $this->jquery_results($values);
+               }
+
+       }

Added: trunk/eventplannerfrontend/inc/class.uivendor_report.inc.php
===================================================================
--- trunk/eventplannerfrontend/inc/class.uivendor_report.inc.php                
                (rev 0)
+++ trunk/eventplannerfrontend/inc/class.uivendor_report.inc.php        
2017-01-23 15:56:25 UTC (rev 16184)
@@ -0,0 +1,22 @@
+<?php
+       phpgw::import_class('eventplanner.uivendor_report');
+
+       class eventplannerfrontend_uivendor_report extends 
eventplanner_uivendor_report
+       {
+
+               public function __construct()
+               {
+                       $GLOBALS['phpgw']->translation->add_app('eventplanner');
+                       parent::__construct();
+               }
+
+               public function query()
+               {
+                       $params = $this->bo->build_default_read_params();
+                       $values = $this->bo->read($params);
+                       array_walk($values["results"], array($this, 
"_add_links"), "eventplannerfrontend.uivendor_report.edit");
+
+                       return $this->jquery_results($values);
+               }
+
+       }

Modified: trunk/eventplannerfrontend/index.php
===================================================================
--- trunk/eventplannerfrontend/index.php        2017-01-23 15:55:48 UTC (rev 
16183)
+++ trunk/eventplannerfrontend/index.php        2017-01-23 15:56:25 UTC (rev 
16184)
@@ -179,6 +179,8 @@
 // END Stuff copied from functions.inc.php
 /////////////////////////////////////////////////////////////////////////////
 
+       $invalid_data = false;
+
        if (isset($_GET['menuaction']))
        {
                list($app, $class, $method) = explode('.', $_GET['menuaction']);
@@ -190,9 +192,13 @@
                $method = 'index';
        }
 
+       if($app != 'eventplannerfrontend')
+       {
+               $invalid_data = true;
+       }
+
        $GLOBALS[$class] = CreateObject("{$app}.{$class}");
 
-       $invalid_data = false; //FIXME consider whether this should be computed 
as in the main index.php
        if (!$invalid_data && is_object($GLOBALS[$class]) && 
isset($GLOBALS[$class]->public_functions) && 
is_array($GLOBALS[$class]->public_functions) && 
isset($GLOBALS[$class]->public_functions[$method]) && 
$GLOBALS[$class]->public_functions[$method])
        {
                if (phpgw::get_var('X-Requested-With', 'string', 'SERVER') == 
'XMLHttpRequest'
@@ -209,6 +215,41 @@
                else
                {
                        $GLOBALS[$class]->$method();
-                       $GLOBALS['phpgw']->common->phpgw_footer();
                }
+               unset($app);
+               unset($class);
+               unset($method);
+               unset($invalid_data);
        }
+       else
+       {
+               if (! $app || ! $class || ! $method)
+               {
+                       $GLOBALS['phpgw']->log->message(array(
+                               'text' => 'W-BadmenuactionVariable, menuaction 
missing or corrupt: %1',
+                               'p1'   => $menuaction,
+                               'line' => __LINE__,
+                               'file' => __FILE__
+                       ));
+               }
+
+               if ( ( !isset($GLOBALS[$class]->public_functions)
+                       || !is_array($GLOBALS[$class]->public_functions)
+                       || !isset($GLOBALS[$class]->public_functions[$method])
+                       || !$GLOBALS[$class]->public_functions[$method] )
+                       && $method)
+               {
+                       $GLOBALS['phpgw']->log->message(array(
+                               'text' => 'W-BadmenuactionVariable, attempted 
to access private method: %1',
+                               'p1'   => $method,
+                               'line' => __LINE__,
+                               'file' => __FILE__
+                       ));
+               }
+
+               $GLOBALS['phpgw']->log->commit();
+               phpgw::no_access();
+
+               //$GLOBALS['phpgw']->redirect_link('/eventplannerfrontend/');
+       }
+       $GLOBALS['phpgw']->common->phpgw_footer();

Modified: trunk/eventplannerfrontend/js/portico/booking.edit.js
===================================================================
--- trunk/eventplannerfrontend/js/portico/booking.edit.js       2017-01-23 
15:55:48 UTC (rev 16183)
+++ trunk/eventplannerfrontend/js/portico/booking.edit.js       2017-01-23 
15:56:25 UTC (rev 16184)
@@ -1,7 +1,7 @@
 var customer_id_selection;
 var lang;
-var oArgs = {menuaction: 'eventplanner.uicustomer.index', organization_number: 
true};
-var strURL = phpGWLink('index.php', oArgs, true);
+var oArgs = {menuaction: 'eventplannerfrontend.uicustomer.index', 
organization_number: true};
+var strURL = phpGWLink('eventplannerfrontend/', oArgs, true);
 JqueryPortico.autocompleteHelper(strURL, 'customer_name', 'customer_id', 
'customer_container', 'name');
 
 $(window).on('load', function ()
@@ -30,11 +30,11 @@
                return;
        }
        oArgs = {
-               menuaction: 'eventplanner.uicustomer.get',
+               menuaction: 'eventplannerfrontend.uicustomer.get',
                id: customer_id
        };
 
-       var requestUrl = phpGWLink('index.php', oArgs, true);
+       var requestUrl = phpGWLink('eventplannerfrontend/', oArgs, true);
        var data = {};
 
        JqueryPortico.execute_ajax(requestUrl,
@@ -80,11 +80,11 @@
        if (type === 'vendor')
        {
                oArgs = {
-                       menuaction: 'eventplanner.uivendor_report.add',
+                       menuaction: 'eventplannerfrontend.uivendor_report.add',
                        booking_id: booking_id
                };
 
-               var requestUrl = phpGWLink('index.php', oArgs);
+               var requestUrl = phpGWLink('eventplannerfrontend/', oArgs);
                win = window.open(requestUrl, '_blank');
                win.focus();
 
@@ -92,11 +92,11 @@
        else if (type === 'customer')
        {
                oArgs = {
-                       menuaction: 'eventplanner.uicustomer_report.add',
+                       menuaction: 
'eventplannerfrontend.uicustomer_report.add',
                        booking_id: booking_id
                };
 
-               var requestUrl = phpGWLink('index.php', oArgs);
+               var requestUrl = phpGWLink('eventplannerfrontend/', oArgs);
                win = window.open(requestUrl, '_blank');
                win.focus();
 

Added: trunk/eventplannerfrontend/js/portico/validate.js
===================================================================
--- trunk/eventplannerfrontend/js/portico/validate.js                           
(rev 0)
+++ trunk/eventplannerfrontend/js/portico/validate.js   2017-01-23 15:56:25 UTC 
(rev 16184)
@@ -0,0 +1,80 @@
+/*
+ * Copyright (C) 2017 hc483
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
+ */
+
+var mod11OfNumberWithControlDigit = function (input)
+{
+       var controlNumber = 2,
+               sumForMod = 0,
+               i;
+
+       for (i = input.length - 2; i >= 0; --i)
+       {
+               sumForMod += input.charAt(i) * controlNumber;
+               if (++controlNumber > 7)
+                       controlNumber = 2;
+       }
+       var result = (11 - sumForMod % 11);
+
+       return result === 11 ? 0 : result;
+};
+
+$(document).ready(function ()
+{
+
+       $.formUtils.addValidator({
+               name: 'organization_number',
+               validatorFunction: function (value, $el, config, languaje, 
$form)
+               {
+                       //check_for_budget is defined in xsl-template
+                       var v = false;
+                       var organization_number = 
$('#organization_number').val();
+
+                       organization_number = 
organization_number.replace(/\s/g, '');
+                       if (!organization_number.match(/(^\d{9}$)/))
+                       {
+                               return false;
+                       }
+
+                       v = 
parseInt(organization_number.charAt(organization_number.length - 1), 10) === 
mod11OfNumberWithControlDigit(organization_number)
+                       return v;
+               },
+               errorMessage: lang['please enter a valid organization number'],
+               errorMessageKey: ''
+       });
+
+       $.formUtils.addValidator({
+               name: 'account_number',
+               validatorFunction: function (value, $el, config, languaje, 
$form)
+               {
+                       //check_for_budget is defined in xsl-template
+                       var v = false;
+                       var account_number = $('#account_number').val();
+
+                       account_number = 
account_number.toString().replace(/\./g, '');
+                       if (account_number.length !== 11)
+                       {
+                               return false;
+                       }
+                       v = 
parseInt(account_number.charAt(account_number.length - 1), 10) === 
mod11OfNumberWithControlDigit(account_number);
+
+                       return v;
+               },
+               errorMessage: lang['please enter a valid account number'],
+               errorMessageKey: ''
+       });
+});

Added: trunk/eventplannerfrontend/templates/base/application.xsl
===================================================================
--- trunk/eventplannerfrontend/templates/base/application.xsl                   
        (rev 0)
+++ trunk/eventplannerfrontend/templates/base/application.xsl   2017-01-23 
15:56:25 UTC (rev 16184)
@@ -0,0 +1,904 @@
+
+<!-- $Id: price_item.xsl 12604 2015-01-15 17:06:11Z nelson224 $ -->
+<xsl:template match="data">
+       <xsl:choose>
+               <xsl:when test="edit">
+                       <xsl:apply-templates select="edit" />
+               </xsl:when>
+               <xsl:when test="view">
+                       <xsl:apply-templates select="view" />
+               </xsl:when>
+               <xsl:when test="adjustment_price">
+                       <xsl:apply-templates select="adjustment_price" />
+
+               </xsl:when>
+       </xsl:choose>
+
+</xsl:template>
+
+<!-- add / edit  -->
+<xsl:template xmlns:php="http://php.net/xsl"; match="edit">
+       <div class="content">
+               <style type="text/css">
+                       #floating-box {
+                       position: relative;
+                       z-index: 1000;
+                       }
+                       #submitbox {
+                       display: none;
+                       }
+               </style>
+               <xsl:variable name="date_format">
+                       <xsl:value-of select="php:function('get_phpgw_info', 
'user|preferences|common|dateformat')" />
+               </xsl:variable>
+
+               <div id='receipt'></div>
+               <div>
+                       <xsl:variable name="form_action">
+                               <xsl:value-of select="form_action"/>
+                       </xsl:variable>
+
+                       <script type="text/javascript">
+                               var lang = <xsl:value-of 
select="php:function('js_lang', 'Name or company is required', 'next', 
'save')"/>;
+                       </script>
+                       <form id="form" name="form" method="post" 
action="{$form_action}" class="pure-form pure-form-aligned">
+                               <div id="tab-content">
+                                       <xsl:value-of 
disable-output-escaping="yes" select="tabs"/>
+                                       <div id="floating-box">
+                                               <div id="submitbox">
+                                                       <xsl:variable 
name="lang_cancel">
+                                                               <xsl:value-of 
select="php:function('lang', 'cancel')"/>
+                                                       </xsl:variable>
+                                                       <xsl:variable 
name="lang_save">
+                                                               <xsl:value-of 
select="php:function('lang', 'next')"/>
+                                                       </xsl:variable>
+                                                       <!--xsl:choose>
+                                                               <xsl:when 
test="application/id > 0">
+                                                                       
<xsl:variable name="lang_save">
+                                                                               
<xsl:value-of select="php:function('lang', 'save')"/>
+                                                                       
</xsl:variable>
+                                                               </xsl:when>
+                                                               <xsl:otherwise>
+                                                                       
<xsl:variable name="lang_save">
+                                                                               
<xsl:value-of select="php:function('lang', 'next')"/>
+                                                                       
</xsl:variable>
+                                                               </xsl:otherwise>
+                                                       </xsl:choose-->
+
+                                                       <table width="200px">
+                                                               <tbody>
+                                                                       <tr>
+                                                                               
<td width="200px">
+                                                                               
        <input type="button" class="pure-button pure-button-primary" 
name="save" id="save_button" onClick="validate_submit();">
+                                                                               
                <xsl:attribute name="value">
+                                                                               
                        <xsl:value-of select="$lang_save"/>
+                                                                               
                </xsl:attribute>
+                                                                               
                <xsl:attribute name="title">
+                                                                               
                        <xsl:value-of select="$lang_save"/>
+                                                                               
                </xsl:attribute>
+                                                                               
        </input>
+                                                                               
</td>
+                                                                               
<td>
+                                                                               
        <input type="button" class="pure-button pure-button-primary" 
name="done" value="{$lang_cancel}" onClick="window.location = '{cancel_url}';">
+                                                                               
                <xsl:attribute name="title">
+                                                                               
                        <xsl:value-of select="php:function('lang', 'Back to the 
ticket list')"/>
+                                                                               
                </xsl:attribute>
+                                                                               
        </input>
+                                                                               
</td>
+                                                                       </tr>
+                                                               </tbody>
+                                                       </table>
+                                               </div>
+                                       </div>
+                                       <input type="hidden" id="active_tab" 
name="active_tab" value="{value_active_tab}"/>
+                                       <div id="first_tab">
+                                               <fieldset>
+                                                       <legend>
+                                                               <xsl:value-of 
select="php:function('lang', 'application')"/>
+                                                       </legend>
+                                                       <xsl:if 
test="application/id > 0">
+                                                               <div 
class="pure-control-group">
+                                                                       <label>
+                                                                               
<xsl:value-of select="php:function('lang', 'id')"/>
+                                                                       </label>
+                                                                       <input 
type="hidden" id="application_id" name="id" value="{application/id}"/>
+                                                                       
<xsl:value-of select="application/id"/>
+                                                               </div>
+                                                       </xsl:if>
+                                                       <div 
class="pure-control-group">
+                                                               <label>
+                                                                       
<xsl:value-of select="php:function('lang', 'category')"/>
+                                                               </label>
+                                                               
<xsl:call-template name="categories"/>
+                                                       </div>
+                                                       <div 
class="pure-control-group">
+                                                               <xsl:variable 
name="lang_vendor">
+                                                                       
<xsl:value-of select="php:function('lang', 'vendor')"/>
+                                                               </xsl:variable>
+                                                               <label>
+                                                                       
<xsl:value-of select="$lang_vendor"/>
+                                                               </label>
+                                                               <input 
type="hidden" id="vendor_id" name="vendor_id"  value="{application/vendor_id}">
+                                                                       
<xsl:attribute name="data-validation">
+                                                                               
<xsl:text>required</xsl:text>
+                                                                       
</xsl:attribute>
+                                                                       
<xsl:attribute name="data-validation-error-msg">
+                                                                               
<xsl:value-of select="$lang_vendor"/>
+                                                                       
</xsl:attribute>
+                                                                       
<xsl:attribute name="placeholder">
+                                                                               
<xsl:value-of select="$lang_vendor"/>
+                                                                       
</xsl:attribute>
+                                                               </input>
+                                                               <input 
type="text" id="vendor_name" name="vendor_name" 
value="{application/vendor_name}">
+                                                                       
<xsl:attribute name="placeholder">
+                                                                               
<xsl:value-of select="$lang_vendor"/>
+                                                                       
</xsl:attribute>
+                                                                       
<xsl:attribute name="data-validation">
+                                                                               
<xsl:text>required</xsl:text>
+                                                                       
</xsl:attribute>
+                                                               </input>
+                                                               <xsl:text> 
</xsl:text>
+                                                               <a 
href="{new_vendor_url}" target="_blank">
+                                                                       
<xsl:value-of select="php:function('lang', 'new')"/>
+                                                                       
<xsl:text> </xsl:text>
+                                                                       
<xsl:value-of select="$lang_vendor"/>
+                                                               </a>
+                                                               <div 
id="vendor_container"/>
+                                                       </div>
+                                                       <div 
class="pure-control-group">
+                                                               <label>
+                                                                       
<xsl:value-of select="php:function('lang', 'other participants')"/>
+                                                               </label>
+                                                               <textarea 
cols="47" rows="7" name="other_participants">
+                                                                       
<xsl:value-of select="application/other_participants"/>
+                                                               </textarea>
+                                                       </div>
+
+                                                       <div 
class="pure-control-group">
+                                                               <label>
+                                                                       
<xsl:value-of select="php:function('lang', 'contact name')"/>
+                                                               </label>
+                                                               <input 
type="text" id="contact_name" name="contact_name" 
value="{application/contact_name}">
+                                                                       
<xsl:attribute name="data-validation">
+                                                                               
<xsl:text>required</xsl:text>
+                                                                       
</xsl:attribute>
+                                                                       
<xsl:attribute name="data-validation-error-msg">
+                                                                               
<xsl:value-of select="php:function('lang', 'contact name')"/>
+                                                                       
</xsl:attribute>
+                                                                       
<xsl:attribute name="placeholder">
+                                                                               
<xsl:value-of select="php:function('lang', 'contact name')"/>
+                                                                       
</xsl:attribute>
+                                                               </input>
+                                                       </div>
+                                                       <div 
class="pure-control-group">
+                                                               <label>
+                                                                       
<xsl:value-of select="php:function('lang', 'contact email')"/>
+                                                               </label>
+                                                               <input 
type="text" id="contact_email" name="contact_email" 
value="{application/contact_email}">
+                                                                       
<xsl:attribute name="data-validation">
+                                                                               
<xsl:text>required</xsl:text>
+                                                                       
</xsl:attribute>
+                                                                       
<xsl:attribute name="data-validation-error-msg">
+                                                                               
<xsl:value-of select="php:function('lang', 'contact email')"/>
+                                                                       
</xsl:attribute>
+                                                                       
<xsl:attribute name="placeholder">
+                                                                               
<xsl:value-of select="php:function('lang', 'contact email')"/>
+                                                                       
</xsl:attribute>
+
+                                                               </input>
+                                                       </div>
+                                                       <div 
class="pure-control-group">
+                                                               <label>
+                                                                       
<xsl:value-of select="php:function('lang', 'contact phone')"/>
+                                                               </label>
+                                                               <input 
type="text" name="contact_phone" value="{application/contact_phone}">
+                                                                       
<xsl:attribute name="data-validation">
+                                                                               
<xsl:text>required</xsl:text>
+                                                                       
</xsl:attribute>
+                                                                       
<xsl:attribute name="placeholder">
+                                                                               
<xsl:value-of select="php:function('lang', 'contact phone')"/>
+                                                                       
</xsl:attribute>
+                                                                       
<xsl:attribute name="data-validation-error-msg">
+                                                                               
<xsl:value-of select="php:function('lang', 'contact phone')"/>
+                                                                       
</xsl:attribute>
+                                                               </input>
+                                                       </div>
+                                               </fieldset>
+                                               <fieldset>
+                                                       <legend>
+                                                               <xsl:value-of 
select="php:function('lang', 'program data')"/>
+                                                       </legend>
+                                                       <div 
class="pure-control-group">
+                                                               <label>
+                                                                       
<xsl:value-of select="php:function('lang', 'program title')"/>
+                                                               </label>
+                                                               <input 
type="text" id="title" name="title" value="{application/title}">
+                                                                       
<xsl:attribute name="data-validation">
+                                                                               
<xsl:text>required</xsl:text>
+                                                                       
</xsl:attribute>
+                                                                       
<xsl:attribute name="data-validation-error-msg">
+                                                                               
<xsl:value-of select="php:function('lang', 'program title')"/>
+                                                                       
</xsl:attribute>
+                                                                       
<xsl:attribute name="placeholder">
+                                                                               
<xsl:value-of select="php:function('lang', 'program title')"/>
+                                                                       
</xsl:attribute>
+                                                               </input>
+                                                       </div>
+                                                       <div 
class="pure-control-group">
+                                                               <label>
+                                                                       
<xsl:value-of select="php:function('lang', 'program description')"/>
+                                                               </label>
+                                                               <textarea 
cols="47" rows="7" name="description">
+                                                                       
<xsl:attribute name="title">
+                                                                               
<xsl:value-of select="php:function('lang', 'might be published')"/>
+                                                                       
</xsl:attribute>
+                                                                       
<xsl:value-of select="application/description"/>
+                                                               </textarea>
+                                                       </div>
+                                                       <div 
class="pure-control-group">
+                                                               <label>
+                                                                       
<xsl:value-of select="php:function('lang', 'program type')"/>
+                                                               </label>
+                                                               <div 
class="pure-custom">
+                                                                       <table 
class="pure-table pure-table-bordered" border="0" cellspacing="2" 
cellpadding="2">
+                                                                               
<thead>
+                                                                               
        <tr>
+                                                                               
                <th>
+                                                                               
                        <xsl:value-of select="php:function('lang', 'select')"/>
+                                                                               
                </th>
+                                                                               
                <th>
+                                                                               
                        <xsl:value-of select="php:function('lang', 'program 
type')"/>
+                                                                               
                </th>
+                                                                               
        </tr>
+                                                                               
</thead>
+                                                                               
<tbody>
+                                                                               
        <xsl:for-each select="application_type_list">
+                                                                               
                <tr>
+                                                                               
                        <td>
+                                                                               
                                <input type="checkbox" name="types[]" 
value="{id}">
+                                                                               
                                        <xsl:if test="selected = 1">
+                                                                               
                                                <xsl:attribute name="checked" 
value="checked"/>
+                                                                               
                                        </xsl:if>
+                                                                               
                                </input>
+                                                                               
                        </td>
+                                                                               
                        <td>
+                                                                               
                                <xsl:value-of disable-output-escaping="yes" 
select="name"/>
+                                                                               
                        </td>
+                                                                               
                </tr>
+                                                                               
        </xsl:for-each>
+                                                                               
</tbody>
+                                                                       </table>
+                                                               </div>
+
+                                                       </div>
+
+                                                       <div 
class="pure-control-group">
+                                                               <xsl:variable 
name="lang_date_start">
+                                                                       
<xsl:value-of select="php:function('lang', 'date start')"/>
+                                                               </xsl:variable>
+                                                               <label>
+                                                                       
<xsl:value-of select="$lang_date_start"/>
+                                                               </label>
+                                                               <input 
type="text" id="date_start" name="date_start" size="10" readonly="readonly">
+                                                                       <xsl:if 
test="application/date_start != 0 and application/date_start != ''">
+                                                                               
<xsl:attribute name="value">
+                                                                               
        <xsl:value-of select="php:function('date', $date_format, 
number(application/date_start))"/>
+                                                                               
</xsl:attribute>
+                                                                       
</xsl:if>
+                                                                       
<xsl:attribute name="data-validation">
+                                                                               
<xsl:text>required</xsl:text>
+                                                                       
</xsl:attribute>
+                                                                       
<xsl:attribute name="data-validation-error-msg">
+                                                                               
<xsl:value-of select="$lang_date_start"/>
+                                                                       
</xsl:attribute>
+
+                                                               </input>
+                                                       </div>
+                                                       <div 
class="pure-control-group">
+                                                               <xsl:variable 
name="lang_date_end">
+                                                                       
<xsl:value-of select="php:function('lang', 'date end')"/>
+                                                               </xsl:variable>
+                                                               <label>
+                                                                       
<xsl:value-of select="$lang_date_end"/>
+                                                               </label>
+                                                               <input 
type="text" id="date_end" name="date_end" size="10" readonly="readonly">
+                                                                       <xsl:if 
test="application/date_end != 0 and application/date_end != ''">
+                                                                               
<xsl:attribute name="value">
+                                                                               
        <xsl:value-of select="php:function('date', $date_format, 
number(application/date_end))"/>
+                                                                               
</xsl:attribute>
+                                                                       
</xsl:if>
+                                                                       
<xsl:attribute name="data-validation">
+                                                                               
<xsl:text>required</xsl:text>
+                                                                       
</xsl:attribute>
+                                                                       
<xsl:attribute name="data-validation-error-msg">
+                                                                               
<xsl:value-of select="$lang_date_end"/>
+                                                                       
</xsl:attribute>
+
+                                                               </input>
+                                                       </div>
+                                                       <div 
class="pure-control-group">
+                                                               <label>
+                                                                       
<xsl:value-of select="php:function('lang', 'event timespan')"/>
+                                                               </label>
+                                                               <input 
type="text" id="timespan" name="timespan" value="{application/timespan}">
+                                                                       
<xsl:attribute name="data-validation">
+                                                                               
<xsl:text>number</xsl:text>
+                                                                       
</xsl:attribute>
+                                                                       
<xsl:attribute name="data-validation-error-msg">
+                                                                               
<xsl:value-of select="php:function('lang', 'event timespan')"/>
+                                                                       
</xsl:attribute>
+                                                                       
<xsl:attribute name="placeholder">
+                                                                               
<xsl:value-of select="php:function('lang', 'event timespan')"/>
+                                                                       
</xsl:attribute>
+
+                                                               </input>
+                                                       </div>
+                                                       <div 
class="pure-control-group">
+                                                               <label>
+                                                                       
<xsl:value-of select="php:function('lang', 'charge per unit')"/>
+                                                               </label>
+                                                               <input 
type="text" id="charge_per_unit" name="charge_per_unit" 
value="{application/charge_per_unit}">
+                                                                       
<xsl:attribute name="data-validation">
+                                                                               
<xsl:text>number</xsl:text>
+                                                                       
</xsl:attribute>
+                                                                       
<xsl:attribute name="data-validation-error-msg">
+                                                                               
<xsl:value-of select="php:function('lang', 'charge per unit')"/>
+                                                                       
</xsl:attribute>
+                                                                       
<xsl:attribute name="placeholder">
+                                                                               
<xsl:value-of select="php:function('lang', 'integer')"/>
+                                                                       
</xsl:attribute>
+
+                                                               </input>
+                                                       </div>
+                                                       <div 
class="pure-control-group">
+                                                               <label>
+                                                                       
<xsl:value-of select="php:function('lang', 'number of units')"/>
+                                                               </label>
+                                                               <input 
type="text" id="number_of_units" name="number_of_units" 
value="{application/number_of_units}">
+                                                                       
<xsl:attribute name="data-validation">
+                                                                               
<xsl:text>number</xsl:text>
+                                                                       
</xsl:attribute>
+                                                                       
<xsl:attribute name="data-validation-error-msg">
+                                                                               
<xsl:value-of select="php:function('lang', 'number of units')"/>
+                                                                       
</xsl:attribute>
+                                                                       
<xsl:attribute name="placeholder">
+                                                                               
<xsl:value-of select="php:function('lang', 'integer')"/>
+                                                                       
</xsl:attribute>
+
+                                                               </input>
+                                                       </div>
+                                                       <div 
class="pure-control-group">
+                                                               <label>
+                                                                       
<xsl:value-of select="php:function('lang', 'total amount')"/>
+                                                               </label>
+                                                               <input 
id="total_amount" type="text" disabled="disabled"/>
+                                                       </div>
+
+                                                       <div 
class="pure-control-group">
+                                                               <label>
+                                                                       
<xsl:value-of select="php:function('lang', 'remark')"/>
+                                                               </label>
+                                                               <textarea 
cols="47" rows="7" name="remark">
+                                                                       
<xsl:value-of select="application/remark"/>
+                                                               </textarea>
+                                                       </div>
+                                               </fieldset>
+                                               <fieldset>
+                                                       <legend>
+                                                               <xsl:value-of 
select="php:function('lang', 'proceedings')"/>
+                                                       </legend>
+
+                                                       <div 
class="pure-control-group">
+                                                               <label>
+                                                                       
<xsl:value-of select="php:function('lang', 'case officer')"/>
+                                                               </label>
+                                                               <select 
id="case_officer_id" name="case_officer_id">
+                                                                       
<xsl:apply-templates select="list_case_officer/options"/>
+                                                               </select>
+                                                       </div>
+                                                       <div 
class="pure-control-group">
+                                                               <label>
+                                                                       
<xsl:value-of select="php:function('lang', 'active')"/>
+                                                               </label>
+                                                               <input 
type="checkbox" name="active" id="active" value="1">
+                                                                       <xsl:if 
test="application/active = 1">
+                                                                               
<xsl:attribute name="checked" value="checked"/>
+                                                                       
</xsl:if>
+                                                               </input>
+                                                       </div>
+
+                                                       <div 
class="pure-control-group">
+                                                               <xsl:variable 
name="lang_status">
+                                                                       
<xsl:value-of select="php:function('lang', 'status')"/>
+                                                               </xsl:variable>
+                                                               <label>
+                                                                       
<xsl:value-of select="$lang_status"/>
+                                                               </label>
+                                                               <select 
name="status">
+                                                                       
<xsl:attribute name="title">
+                                                                               
<xsl:value-of select="$lang_status"/>
+                                                                       
</xsl:attribute>
+                                                                       
<!--xsl:attribute name="data-validation">
+                                                                               
<xsl:text>required</xsl:text>
+                                                                       
</xsl:attribute>
+                                                                       
<xsl:attribute name="data-validation-error-msg">
+                                                                               
<xsl:value-of select="$lang_status"/>
+                                                                       
</xsl:attribute-->
+                                                                       <option 
value="">
+                                                                               
<xsl:value-of select="$lang_status"/>
+                                                                       
</option>
+                                                                       
<xsl:apply-templates select="status_list/options"/>
+                                                               </select>
+                                                       </div>
+                                                       <div 
class="pure-control-group">
+                                                               <label>
+                                                                       
<xsl:value-of select="php:function('lang', 'number of granted events')"/>
+                                                               </label>
+                                                               <input 
type="text" id="num_granted_events" name="num_granted_events" 
value="{application/num_granted_events}">
+                                                               </input>
+                                                       </div>
+                                                       <div 
class="pure-control-group">
+                                                               <label>
+                                                                       
<xsl:value-of select="php:function('lang', 'comment')"/>
+                                                               </label>
+                                                               <textarea 
cols="47" rows="7" name="comment">
+                                                                       
<xsl:value-of select="application/comment"/>
+                                                               </textarea>
+                                                       </div>
+                                                       <div 
class="pure-control-group">
+                                                               <label>
+                                                                       
<xsl:value-of select="php:function('lang', 'history')"/>
+                                                               </label>
+                                                               <div 
class="pure-custom">
+                                                                       
<xsl:for-each select="datatable_def">
+                                                                               
<xsl:if test="container = 'datatable-container_0'">
+                                                                               
        <xsl:call-template name="table_setup">
+                                                                               
                <xsl:with-param name="container" select ='container'/>
+                                                                               
                <xsl:with-param name="requestUrl" select ='requestUrl'/>
+                                                                               
                <xsl:with-param name="ColumnDefs" select ='ColumnDefs'/>
+                                                                               
                <xsl:with-param name="data" select ='data'/>
+                                                                               
                <xsl:with-param name="config" select ='config'/>
+                                                                               
        </xsl:call-template>
+                                                                               
</xsl:if>
+                                                                       
</xsl:for-each>
+                                                               </div>
+                                                       </div>
+                                               </fieldset>
+                                       </div>
+                                       <div id="demands">
+                                               <fieldset>
+                                                       <legend>
+                                                               <xsl:value-of 
select="php:function('lang', 'arena requirement')"/>
+                                                       </legend>
+
+                                                       <div 
class="pure-control-group">
+                                                               <label>
+                                                                       
<xsl:value-of select="php:function('lang', 'size of stage')"/>
+                                                               </label>
+                                                               <input 
type="text" id="stage_width" name="stage_width" 
value="{application/stage_width}" size="2">
+                                                                       
<xsl:attribute name="title">
+                                                                               
<xsl:value-of select="php:function('lang', 'width')"/>
+                                                                       
</xsl:attribute>
+                                                                       
<xsl:attribute name="data-validation">
+                                                                               
<xsl:text>number</xsl:text>
+                                                                       
</xsl:attribute>
+                                                                       
<xsl:attribute name="data-validation-optional">
+                                                                               
<xsl:text>true</xsl:text>
+                                                                       
</xsl:attribute>
+                                                               </input>
+                                                               <xsl:text> X 
</xsl:text>
+                                                               <input 
type="text" id="stage_depth" name="stage_depth" 
value="{application/stage_depth}" size="2">
+                                                                       
<xsl:attribute name="data-validation">
+                                                                               
<xsl:text>number</xsl:text>
+                                                                       
</xsl:attribute>
+                                                                       
<xsl:attribute name="title">
+                                                                               
<xsl:value-of select="php:function('lang', 'depth')"/>
+                                                                       
</xsl:attribute>
+                                                                       
<xsl:attribute name="data-validation-optional">
+                                                                               
<xsl:text>true</xsl:text>
+                                                                       
</xsl:attribute>
+                                                               </input>
+                                                               <xsl:text> M 
</xsl:text>
+                                                               <input 
id="stage_size" type="text" disabled="disabled" size="3"/>
+                                                       </div>
+                                                       <div 
class="pure-control-group">
+                                                               <label>
+                                                                       
<xsl:value-of select="php:function('lang', 'stage requirement')"/>
+                                                               </label>
+                                                               <textarea 
cols="47" rows="7" name="stage_requirement">
+                                                                       
<xsl:value-of select="application/stage_requirement"/>
+                                                               </textarea>
+                                                       </div>
+                                                       <div 
class="pure-control-group">
+                                                               <label>
+                                                                       
<xsl:value-of select="php:function('lang', 'wardrobe')"/>
+                                                               </label>
+                                                               <input 
type="checkbox" name="wardrobe" id="wardrobe" value="1">
+                                                                       <xsl:if 
test="application/wardrobe = 1">
+                                                                               
<xsl:attribute name="checked" value="checked"/>
+                                                                       
</xsl:if>
+                                                               </input>
+                                                       </div>
+                                                       <div 
class="pure-control-group">
+                                                               <label>
+                                                                       
<xsl:value-of select="php:function('lang', 'audience limit')"/>
+                                                               </label>
+                                                               <input 
type="text" id="audience_limit" name="audience_limit" 
value="{application/audience_limit}"  size="5">
+                                                                       
<xsl:attribute name="data-validation">
+                                                                               
<xsl:text>required</xsl:text>
+                                                                       
</xsl:attribute>
+                                                                       
<xsl:attribute name="data-validation-error-msg">
+                                                                               
<xsl:value-of select="php:function('lang', 'audience limit')"/>
+                                                                       
</xsl:attribute>
+                                                                       
<xsl:attribute name="placeholder">
+                                                                               
<xsl:value-of select="php:function('lang', 'integer')"/>
+                                                                       
</xsl:attribute>
+                                                               </input>
+                                                       </div>
+                                               </fieldset>
+                                               <fieldset>
+                                                       <legend>
+                                                               <xsl:value-of 
select="php:function('lang', 'labour support')"/>
+                                                       </legend>
+
+                                                       <div 
class="pure-control-group">
+                                                               <label>
+                                                               </label>
+                                                               <div 
class="pure-custom">
+                                                                       <table 
class="pure-table pure-table-bordered" border="0" cellspacing="2" 
cellpadding="2">
+                                                                               
<thead>
+                                                                               
        <tr>
+                                                                               
                <th></th>
+                                                                               
                <th>Minutt</th>
+                                                                               
        </tr>
+                                                                               
</thead>
+                                                                               
<tbody>
+                                                                               
        <tr>
+                                                                               
                <td>
+                                                                               
                        <xsl:value-of select="php:function('lang', 'rig up min 
before')"/>
+                                                                               
                </td>
+                                                                               
                <td>
+                                                                               
                        <input type="text" id="rig_up_min_before" 
name="rig_up_min_before" value="{application/rig_up_min_before}" size="3">
+                                                                               
                                <xsl:attribute name="data-validation">
+                                                                               
                                        <xsl:text>number</xsl:text>
+                                                                               
                                </xsl:attribute>
+                                                                               
                                <xsl:attribute name="data-validation-optional">
+                                                                               
                                        <xsl:text>true</xsl:text>
+                                                                               
                                </xsl:attribute>
+                                                                               
                        </input>
+                                                                               
                </td>
+                                                                               
        </tr>
+                                                                               
        <tr>
+                                                                               
                <td>
+                                                                               
                        <xsl:value-of select="php:function('lang', 'rig down 
min after')"/>
+                                                                               
                </td>
+                                                                               
                <td>
+                                                                               
                        <input type="text" id="rig_down_min_after" 
name="rig_down_min_after" value="{application/rig_down_min_after}" size="3">
+                                                                               
                                <xsl:attribute name="data-validation">
+                                                                               
                                        <xsl:text>number</xsl:text>
+                                                                               
                                </xsl:attribute>
+                                                                               
                                <xsl:attribute name="data-validation-optional">
+                                                                               
                                        <xsl:text>true</xsl:text>
+                                                                               
                                </xsl:attribute>
+                                                                               
                        </input>
+                                                                               
                </td>
+                                                                               
        </tr>
+                                                                               
</tbody>
+                                                                       </table>
+                                                               </div>
+                                                       </div>
+                                               </fieldset>
+                                               <fieldset>
+                                                       <legend>
+                                                               <xsl:value-of 
select="php:function('lang', 'technical support')"/>
+                                                       </legend>
+                                                       <div 
class="pure-control-group">
+                                                               <label>
+                                                               </label>
+                                                               <div 
class="pure-custom">
+                                                                       <table 
class="pure-table pure-table-bordered" border="0" cellspacing="2" 
cellpadding="2">
+                                                                               
<thead>
+                                                                               
        <tr>
+                                                                               
                <th>Hva</th>
+                                                                               
                <th>Ja</th>
+                                                                               
                <th>Fritekst</th>
+                                                                               
        </tr>
+                                                                               
</thead>
+                                                                               
<tbody>
+                                                                               
        <tr>
+                                                                               
                <td>Strøm</td>
+                                                                               
                <td>
+                                                                               
                        <input type="checkbox" name="power" id="power" 
value="1">
+                                                                               
                                <xsl:if test="application/power = 1">
+                                                                               
                                        <xsl:attribute name="checked" 
value="checked"/>
+                                                                               
                                </xsl:if>
+                                                                               
                        </input>
+                                                                               
                </td>
+                                                                               
                <td>
+                                                                               
                        <input type="text" id="power_remark" 
name="power_remark" value="{application/power_remark}">
+                                                                               
                        </input>
+                                                                               
                </td>
+                                                                               
        </tr>
+                                                                               
        <tr>
+                                                                               
                <td>Lydanlegg</td>
+                                                                               
                <td>
+                                                                               
                        <input type="checkbox" name="sound" id="sound" 
value="1">
+                                                                               
                                <xsl:if test="application/sound = 1">
+                                                                               
                                        <xsl:attribute name="checked" 
value="checked"/>
+                                                                               
                                </xsl:if>
+                                                                               
                        </input>
+                                                                               
                </td>
+                                                                               
                <td>
+                                                                               
                        <input type="text" id="sound_remark" 
name="sound_remark" value="{application/sound_remark}">
+                                                                               
                        </input>
+                                                                               
                </td>
+                                                                               
        </tr>
+                                                                               
        <tr>
+                                                                               
                <td>Lyssetting/blending</td>
+                                                                               
                <td>
+                                                                               
                        <input type="checkbox" name="light" id="light" 
value="1">
+                                                                               
                                <xsl:if test="application/light = 1">
+                                                                               
                                        <xsl:attribute name="checked" 
value="checked"/>
+                                                                               
                                </xsl:if>
+                                                                               
                        </input>
+                                                                               
                </td>
+                                                                               
                <td>
+                                                                               
                        <input type="text" id="light_remark" 
name="light_remark" value="{application/light_remark}">
+                                                                               
                        </input>
+                                                                               
                </td>
+                                                                               
        </tr>
+                                                                               
        <tr>
+                                                                               
                <td>Piano</td>
+                                                                               
                <td>
+                                                                               
                        <input type="checkbox" name="piano" id="piano" 
value="1">
+                                                                               
                                <xsl:if test="application/piano = 1">
+                                                                               
                                        <xsl:attribute name="checked" 
value="checked"/>
+                                                                               
                                </xsl:if>
+                                                                               
                        </input>
+                                                                               
                </td>
+                                                                               
                <td>
+                                                                               
                        <input type="text" id="piano_remark" 
name="piano_remark" value="{application/piano_remark}">
+                                                                               
                        </input>
+                                                                               
                </td>
+
+                                                                               
        </tr>
+                                                                               
        <tr>
+                                                                               
                <td>Anna utstyr (prosjektor, lerret mm)</td>
+                                                                               
                <td>
+                                                                               
                </td>
+                                                                               
                <td>
+                                                                               
                        <input type="text" id="equipment_remark" 
name="equipment_remark" value="{application/equipment_remark}">
+                                                                               
                        </input>
+                                                                               
                </td>
+                                                                               
        </tr>
+                                                                               
</tbody>
+                                                                       </table>
+                                                               </div>
+                                                       </div>
+
+                                               </fieldset>
+                                               <fieldset>
+                                                       <legend>
+                                                               <xsl:value-of 
select="php:function('lang', 'raider')"/>
+                                                       </legend>
+                                                       <div 
class="pure-control-group">
+                                                               <label>
+                                                               </label>
+                                                               <textarea 
cols="47" rows="7" name="raider">
+                                                                       
<xsl:value-of select="application/raider"/>
+                                                               </textarea>
+                                                       </div>
+                                               </fieldset>
+                                       </div>
+                                       <div id='calendar'>
+                                               <fieldset>
+
+                                                       <div 
class="pure-control-group">
+                                                               <label>
+                                                                       
<xsl:value-of select="php:function('lang', 'date start')"/>
+                                                               </label>
+                                                               <xsl:if 
test="application/date_start != 0 and application/date_start != ''">
+                                                                       
<xsl:value-of select="php:function('date', $date_format, 
number(application/date_start))"/>
+                                                               </xsl:if>
+                                                       </div>
+                                                       <div 
class="pure-control-group">
+                                                               <label>
+                                                                       
<xsl:value-of select="php:function('lang', 'date end')"/>
+                                                               </label>
+                                                               <xsl:if 
test="application/date_end != 0 and application/date_end != ''">
+                                                                       
<xsl:value-of select="php:function('date', $date_format, 
number(application/date_end))"/>
+                                                               </xsl:if>
+                                                       </div>
+                                                       <div 
class="pure-control-group">
+                                                               <label>
+                                                                       
<xsl:value-of select="php:function('lang', 'event timespan')"/>
+                                                               </label>
+                                                               <xsl:if 
test="application/date_end != 0 and application/timespan != ''">
+                                                                       
<xsl:value-of select="application/timespan"/>
+                                                               </xsl:if>
+                                                       </div>
+
+                                                       <div 
class="pure-control-group">
+                                                               <label>
+                                                                       
<xsl:value-of select="php:function('lang', 'event start')"/>
+                                                               </label>
+                                                               <input 
type="text" id="from_" name="from_" size="16" readonly="readonly">
+                                                                       
<xsl:attribute name="title">
+                                                                               
<xsl:value-of select="php:function('lang', 'select event start')"/>
+                                                                       
</xsl:attribute>
+                                                               </input>
+                                                       </div>
+                                                       <!--div 
class="pure-control-group">
+                                                               <label>
+                                                                       
<xsl:value-of select="php:function('lang', 'to')"/>
+                                                               </label>
+                                                               <input 
type="text" id="to_" name="to_" size="16" readonly="readonly">
+                                                               </input>
+                                                       </div-->
+
+                                                       <div 
class="pure-control-group">
+                                                               <label>
+                                                                       
<xsl:value-of select="php:function('lang', 'event dates')"/>
+                                                               </label>
+                                                               <div 
class="pure-custom">
+                                                                       
<xsl:for-each select="datatable_def">
+                                                                               
<xsl:if test="container = 'datatable-container_1'">
+                                                                               
        <xsl:call-template name="table_setup">
+                                                                               
                <xsl:with-param name="container" select ='container'/>
+                                                                               
                <xsl:with-param name="requestUrl" select ='requestUrl'/>
+                                                                               
                <xsl:with-param name="ColumnDefs" select ='ColumnDefs'/>
+                                                                               
                <xsl:with-param name="tabletools" select ='tabletools'/>
+                                                                               
                <xsl:with-param name="data" select ='data'/>
+                                                                               
                <xsl:with-param name="config" select ='config'/>
+                                                                               
        </xsl:call-template>
+                                                                               
</xsl:if>
+                                                                       
</xsl:for-each>
+                                                               </div>
+                                                       </div>
+                                               </fieldset>
+                                       </div>
+
+                               </div>
+                               <div id="submit_group_bottom" 
class="proplist-col">
+                                       <xsl:variable name="lang_save">
+                                               <xsl:value-of 
select="php:function('lang', 'next')"/>
+                                       </xsl:variable>
+                                       <input type="button" class="pure-button 
pure-button-primary" name="save" id="save_button_bottom" 
onClick="validate_submit();">
+                                               <xsl:attribute name="value">
+                                                       <xsl:value-of 
select="$lang_save"/>
+                                               </xsl:attribute>
+                                               <xsl:attribute name="title">
+                                                       <xsl:value-of 
select="$lang_save"/>
+                                               </xsl:attribute>
+                                       </input>
+                                       <xsl:variable name="cancel_url">
+                                               <xsl:value-of 
select="cancel_url"/>
+                                       </xsl:variable>
+                                       <input type="button" class="pure-button 
pure-button-primary" name="cancel" onClick="window.location = '{cancel_url}';">
+                                               <xsl:attribute name="value">
+                                                       <xsl:value-of 
select="php:function('lang', 'cancel')"/>
+                                               </xsl:attribute>
+                                       </input>
+                               </div>
+                       </form>
+               </div>
+       </div>
+</xsl:template>
+
+<xsl:template match="options">
+       <option value="{id}">
+               <xsl:if test="selected != 0">
+                       <xsl:attribute name="selected" value="selected"/>
+               </xsl:if>
+               <xsl:value-of disable-output-escaping="yes" select="name"/>
+       </option>
+</xsl:template>
+
+
+<xsl:template xmlns:php="http://php.net/xsl"; match="view">
+       <div>
+               <form id="form" name="form" method="post" action="" 
class="pure-form pure-form-aligned">
+                       <div id="tab-content">
+                               <xsl:value-of disable-output-escaping="yes" 
select="tabs"/>
+                               <div id="showing">
+                                       <!--fieldset>
+                                               <div class="pure-control-group">
+                                                       <label>
+                                                               <xsl:value-of 
select="php:function('lang', 'title')"/>
+                                                       </label>
+                                                       <xsl:value-of 
select="value_title"/>
+                                               </div>
+                                               <div class="pure-control-group">
+                                                       <label>
+                                                               <xsl:value-of 
select="php:function('lang', 'field_of_responsibility')"/>
+                                                       </label>
+                                                       <xsl:value-of 
select="value_field_of_responsibility"/>
+                                               </div>
+                                               <div class="pure-control-group">
+                                                       <label>
+                                                               <xsl:value-of 
select="php:function('lang', 'agresso_id')"/>
+                                                       </label>
+                                                       <xsl:value-of 
select="value_agresso_id"/>
+                                               </div>
+                                               <div class="pure-control-group">
+                                                       <label>
+                                                               <xsl:value-of 
select="php:function('lang', 'is_area')"/>
+                                                       </label>
+                                                       <div 
class="pure-custom">
+                                                               <div>
+                                                                       <input 
type="radio" name="is_area" value="true" disabled="disabled">
+                                                                               
<xsl:if test="is_area = 1">
+                                                                               
        <xsl:attribute name="checked" value="checked"/>
+                                                                               
</xsl:if>
+                                                                       </input>
+                                                                       
<xsl:value-of select="php:function('lang', 'calculate_price_per_area')"/>
+                                                               </div>
+                                                               <div>
+                                                                       <input 
type="radio" name="is_area" value="false" disabled="disabled">
+                                                                               
<xsl:if test="is_area = 0">
+                                                                               
        <xsl:attribute name="checked" value="checked"/>
+                                                                               
</xsl:if>
+                                                                       </input>
+                                                                       
<xsl:value-of select="php:function('lang', 'calculate_price_apiece')"/>
+                                                               </div>
+                                                       </div>
+                                               </div>
+                                               <div class="pure-control-group">
+                                                       <label>
+                                                               <xsl:value-of 
select="php:function('lang', 'type')"/>
+                                                       </label>
+                                                       <xsl:value-of 
select="lang_current_price_type"/>
+                                               </div>
+                                               <div class="pure-control-group">
+                                                       <label>
+                                                               <xsl:value-of 
select="php:function('lang', 'price')"/>
+                                                       </label>
+                                                       <xsl:value-of 
select="value_price_formatted"/>
+                                               </div>
+                                               <div class="pure-control-group">
+                                                       <label>
+                                                               <xsl:value-of 
select="php:function('lang', 'is_inactive')"/>
+                                                       </label>
+                                                       <input type="checkbox" 
name="is_inactive" id="is_inactive" disabled="disabled">
+                                                               <xsl:if 
test="is_inactive = 1">
+                                                                       
<xsl:attribute name="checked" value="checked"/>
+                                                               </xsl:if>
+                                                       </input>
+                                                       <xsl:if 
test="has_active_contract = 1">
+                                                               <xsl:value-of 
select="lang_price_element_in_use"/>
+                                                       </xsl:if>
+                                               </div>
+                                               <div class="pure-control-group">
+                                                       <label>
+                                                               <xsl:value-of 
select="php:function('lang', 'is_adjustable')"/>
+                                                       </label>
+                                                       <xsl:value-of 
select="lang_adjustable_text"/>
+                                               </div>
+                                               <div class="pure-control-group">
+                                                       <label>
+                                                               <xsl:value-of 
select="php:function('lang', 'is_standard')"/>
+                                                       </label>
+                                                       <xsl:value-of 
select="lang_standard_text"/>
+                                               </div>
+                                       </fieldset-->
+                               </div>
+                       </div>
+                       <div class="proplist-col">
+                               <xsl:variable name="cancel_url">
+                                       <xsl:value-of select="cancel_url"/>
+                               </xsl:variable>
+                               <input type="button" class="pure-button 
pure-button-primary" name="cancel" value="{lang_cancel}" 
onMouseout="window.status='';return true;" onClick="window.location = 
'{cancel_url}';"/>
+                       </div>
+               </form>
+       </div>
+</xsl:template>
+
+
+<xsl:template match="options">
+       <option value="{id}">
+               <xsl:if test="selected != 0">
+                       <xsl:attribute name="selected" value="selected"/>
+               </xsl:if>
+               <xsl:value-of disable-output-escaping="yes" select="name"/>
+       </option>
+</xsl:template>

Modified: trunk/eventplannerfrontend/templates/base/booking.xsl
===================================================================
--- trunk/eventplannerfrontend/templates/base/booking.xsl       2017-01-23 
15:55:48 UTC (rev 16183)
+++ trunk/eventplannerfrontend/templates/base/booking.xsl       2017-01-23 
15:56:25 UTC (rev 16184)
@@ -99,7 +99,7 @@
                                                <div class="pure-control-group">
                                                        <label>
                                                                <a 
href="{application_url}" target="_blank">
-                                                                       
<xsl:value-of select="php:function('lang', 'application')"/>
+                                                                       
<xsl:value-of select="lang_application"/>
                                                                </a>
 
                                                        </label>
@@ -229,7 +229,7 @@
                                                                        
<xsl:text>required</xsl:text>
                                                                </xsl:attribute>
                                                                <xsl:attribute 
name="placeholder">
-                                                                       
<xsl:value-of select="php:function('lang', 'contact_name')"/>
+                                                                       
<xsl:value-of select="php:function('lang', 'contact name')"/>
                                                                </xsl:attribute>
                                                        </input>
                                                </div>
@@ -263,7 +263,7 @@
                                                                        
<xsl:text>required</xsl:text>
                                                                </xsl:attribute>
                                                                <xsl:attribute 
name="placeholder">
-                                                                       
<xsl:value-of select="php:function('lang', 'contact_phone')"/>
+                                                                       
<xsl:value-of select="php:function('lang', 'contact phone')"/>
                                                                </xsl:attribute>
                                                        </input>
                                                </div>
@@ -360,7 +360,7 @@
                                                </div>
                                                <div class="pure-control-group">
                                                        <label>
-                                                               <xsl:value-of 
select="php:function('lang', 'details')"/>
+                                                               <xsl:value-of 
select="php:function('lang', 'history')"/>
                                                        </label>
                                                        <div 
class="pure-custom">
                                                                <xsl:for-each 
select="datatable_def">

Modified: trunk/eventplannerfrontend/templates/base/customer.xsl
===================================================================
--- trunk/eventplannerfrontend/templates/base/customer.xsl      2017-01-23 
15:55:48 UTC (rev 16183)
+++ trunk/eventplannerfrontend/templates/base/customer.xsl      2017-01-23 
15:56:25 UTC (rev 16184)
@@ -26,7 +26,7 @@
 
        <div>
                <script type="text/javascript">
-                       var lang = <xsl:value-of 
select="php:function('js_lang', 'Name or company is required')"/>;
+                       var lang = <xsl:value-of 
select="php:function('js_lang', 'Name or company is required', 'please enter a 
valid organization number', 'please enter a valid account number')"/>;
                </script>
                <form id="form" name="form" method="post" 
action="{$form_action}" class="pure-form pure-form-aligned">
                        <div id="tab-content">
@@ -88,10 +88,12 @@
                                                </div>
                                                <div class="pure-control-group">
                                                        <xsl:variable 
name="lang_address_1">
-                                                               <xsl:value-of 
select="php:function('lang', 'address_1')"/>
+                                                               <xsl:value-of 
select="php:function('lang', 'address')"/>
+                                                               <xsl:text> 
1</xsl:text>
                                                        </xsl:variable>
                                                        <xsl:variable 
name="lang_address_2">
-                                                               <xsl:value-of 
select="php:function('lang', 'address_2')"/>
+                                                               <xsl:value-of 
select="php:function('lang', 'address')"/>
+                                                               <xsl:text> 
2</xsl:text>
                                                        </xsl:variable>
                                                        <label>
                                                                <xsl:value-of 
select="php:function('lang', 'address')"/>
@@ -113,7 +115,7 @@
                                                </div>
                                                <div class="pure-control-group">
                                                        <label>
-                                                               <xsl:value-of 
select="php:function('lang', 'postal_code_place')"/>
+                                                               <xsl:value-of 
select="php:function('lang', 'zip code')"/>
                                                        </label>
                                                        <input type="text" 
name="zip_code" value="{customer/zip_code}">
                                                                <xsl:attribute 
name="data-validation">
@@ -120,7 +122,7 @@
                                                                        
<xsl:text>required</xsl:text>
                                                                </xsl:attribute>
                                                                <xsl:attribute 
name="placeholder">
-                                                                       
<xsl:value-of select="php:function('lang', 'zip_code')"/>
+                                                                       
<xsl:value-of select="php:function('lang', 'zip code')"/>
                                                                </xsl:attribute>
                                                        </input>
                                                        <input type="text" 
name="city" value="{customer/city}">
@@ -134,14 +136,14 @@
                                                </div>
                                                <div class="pure-control-group">
                                                        <label>
-                                                               <xsl:value-of 
select="php:function('lang', 'customer_organization_number')"/>
+                                                               <xsl:value-of 
select="php:function('lang', 'organization number')"/>
                                                        </label>
-                                                       <input type="text" 
id="lastname" name="customer_organization_number" 
value="{customer/customer_organization_number}">
+                                                       <input type="text" 
id="organization_number" name="organization_number" 
value="{customer/organization_number}">
                                                                <xsl:attribute 
name="data-validation">
-                                                                       
<xsl:text>required</xsl:text>
+                                                                       
<xsl:text>organization_number</xsl:text>
                                                                </xsl:attribute>
                                                                <xsl:attribute 
name="placeholder">
-                                                                       
<xsl:value-of select="php:function('lang', 'customer_organization_number')"/>
+                                                                       
<xsl:value-of select="php:function('lang', 'organization number')"/>
                                                                </xsl:attribute>
                                                        </input>
                                                </div>
@@ -154,7 +156,7 @@
                                                                        
<xsl:text>required</xsl:text>
                                                                </xsl:attribute>
                                                                <xsl:attribute 
name="placeholder">
-                                                                       
<xsl:value-of select="php:function('lang', 'contact_name')"/>
+                                                                       
<xsl:value-of select="php:function('lang', 'contact name')"/>
                                                                </xsl:attribute>
                                                        </input>
                                                </div>
@@ -188,20 +190,20 @@
                                                                        
<xsl:text>required</xsl:text>
                                                                </xsl:attribute>
                                                                <xsl:attribute 
name="placeholder">
-                                                                       
<xsl:value-of select="php:function('lang', 'contact_phone')"/>
+                                                                       
<xsl:value-of select="php:function('lang', 'contact phone')"/>
                                                                </xsl:attribute>
                                                        </input>
                                                </div>
                                                <div class="pure-control-group">
                                                        <label>
-                                                               <xsl:value-of 
select="php:function('lang', 'account_number')"/>
+                                                               <xsl:value-of 
select="php:function('lang', 'account number')"/>
                                                        </label>
-                                                       <input type="text" 
name="account_number" value="{customer/account_number}">
+                                                       <input type="text" 
id="account_number" name="account_number" value="{customer/account_number}">
                                                                <xsl:attribute 
name="data-validation">
-                                                                       
<xsl:text>required</xsl:text>
+                                                                       
<xsl:text>account_number</xsl:text>
                                                                </xsl:attribute>
                                                                <xsl:attribute 
name="placeholder">
-                                                                       
<xsl:value-of select="php:function('lang', 'account_number')"/>
+                                                                       
<xsl:value-of select="php:function('lang', 'account number')"/>
                                                                </xsl:attribute>
                                                        </input>
                                                </div>
@@ -231,7 +233,7 @@
                                                </div>
                                                <div class="pure-control-group">
                                                        <label>
-                                                               <xsl:value-of 
select="php:function('lang', 'details')"/>
+                                                               <xsl:value-of 
select="php:function('lang', 'history')"/>
                                                        </label>
                                                        <div 
class="pure-custom">
                                                                <xsl:for-each 
select="datatable_def">

Added: trunk/eventplannerfrontend/templates/base/vendor.xsl
===================================================================
--- trunk/eventplannerfrontend/templates/base/vendor.xsl                        
        (rev 0)
+++ trunk/eventplannerfrontend/templates/base/vendor.xsl        2017-01-23 
15:56:25 UTC (rev 16184)
@@ -0,0 +1,296 @@
+
+<!-- $Id: price_item.xsl 12604 2015-01-15 17:06:11Z nelson224 $ -->
+<xsl:template match="data">
+       <xsl:choose>
+               <xsl:when test="edit">
+                       <xsl:apply-templates select="edit" />
+               </xsl:when>
+               <xsl:when test="view">
+                       <xsl:apply-templates select="view" />
+               </xsl:when>
+       </xsl:choose>
+
+</xsl:template>
+
+<!-- add / edit  -->
+<xsl:template xmlns:php="http://php.net/xsl"; match="edit">
+       <xsl:variable name="date_format">
+               <xsl:value-of select="php:function('get_phpgw_info', 
'user|preferences|common|dateformat')" />
+       </xsl:variable>
+       <xsl:variable name="form_action">
+               <xsl:value-of select="form_action"/>
+       </xsl:variable>
+       <xsl:variable name="mode">
+               <xsl:value-of select="mode"/>
+       </xsl:variable>
+
+       <div>
+               <script type="text/javascript">
+                       var lang = <xsl:value-of 
select="php:function('js_lang', 'Name or company is required')"/>;
+               </script>
+               <form id="form" name="form" method="post" 
action="{$form_action}" class="pure-form pure-form-aligned">
+                       <div id="tab-content">
+                               <xsl:value-of disable-output-escaping="yes" 
select="tabs"/>
+                               <input type="hidden" id="active_tab" 
name="active_tab" value="{value_active_tab}"/>
+                               <div id="first_tab">
+                                       <fieldset>
+                                               <xsl:if test="vendor/id > 0">
+                                                       <div 
class="pure-control-group">
+                                                               <label>
+                                                                       
<xsl:value-of select="php:function('lang', 'id')"/>
+                                                               </label>
+                                                               <input 
type="hidden" name="id" value="{vendor/id}"/>
+                                                               <xsl:value-of 
select="vendor/id"/>
+                                                       </div>
+                                               </xsl:if>
+                                               <div class="pure-control-group">
+                                                       <label>
+                                                               <xsl:value-of 
select="php:function('lang', 'active')"/>
+                                                       </label>
+                                                       <input type="checkbox" 
name="active" id="active" value="1">
+                                                               <xsl:if 
test="vendor/active = 1">
+                                                                       
<xsl:attribute name="checked" value="checked"/>
+                                                               </xsl:if>
+                                                       </input>
+                                               </div>
+                                               <div class="pure-control-group">
+                                                       <xsl:variable 
name="lang_category">
+                                                               <xsl:value-of 
select="php:function('lang', 'category')"/>
+                                                       </xsl:variable>
+                                                       <label>
+                                                               <xsl:value-of 
select="$lang_category"/>
+                                                       </label>
+                                                       <select 
name="category_id">
+                                                               <xsl:attribute 
name="title">
+                                                                       
<xsl:value-of select="$lang_category"/>
+                                                               </xsl:attribute>
+                                                               <xsl:attribute 
name="data-validation">
+                                                                       
<xsl:text>required</xsl:text>
+                                                               </xsl:attribute>
+                                                               <xsl:attribute 
name="data-validation-error-msg">
+                                                                       
<xsl:value-of select="$lang_category"/>
+                                                               </xsl:attribute>
+                                                               
<xsl:apply-templates select="category_list/options"/>
+                                                       </select>
+                                               </div>
+                                               <div class="pure-control-group">
+                                                       <label>
+                                                               <xsl:value-of 
select="php:function('lang', 'name')"/>
+                                                       </label>
+                                                       <input type="text" 
name="name" value="{vendor/name}">
+                                                               <xsl:attribute 
name="data-validation">
+                                                                       
<xsl:text>required</xsl:text>
+                                                               </xsl:attribute>
+                                                               <xsl:attribute 
name="placeholder">
+                                                                       
<xsl:value-of select="php:function('lang', 'name')"/>
+                                                               </xsl:attribute>
+                                                       </input>
+                                               </div>
+                                               <div class="pure-control-group">
+                                                       <xsl:variable 
name="lang_address_1">
+                                                               <xsl:value-of 
select="php:function('lang', 'address')"/>
+                                                               <xsl:text> 
1</xsl:text>
+                                                       </xsl:variable>
+                                                       <xsl:variable 
name="lang_address_2">
+                                                               <xsl:value-of 
select="php:function('lang', 'address')"/>
+                                                               <xsl:text> 
2</xsl:text>
+                                                       </xsl:variable>
+                                                       <label>
+                                                               <xsl:value-of 
select="php:function('lang', 'address')"/>
+                                                       </label>
+                                                       <input type="text" 
name="address_1" value="{vendor/address_1}">
+                                                               <xsl:attribute 
name="data-validation">
+                                                                       
<xsl:text>required</xsl:text>
+                                                               </xsl:attribute>
+                                                               <xsl:attribute 
name="placeholder">
+                                                                       
<xsl:value-of select="$lang_address_1"/>
+                                                               </xsl:attribute>
+
+                                                       </input>
+                                                       <input type="text" 
name="address_2" value="{vendor/address_2}">
+                                                               <xsl:attribute 
name="placeholder">
+                                                                       
<xsl:value-of select="$lang_address_2"/>
+                                                               </xsl:attribute>
+                                                       </input>
+                                               </div>
+                                               <div class="pure-control-group">
+                                                       <label>
+                                                               <xsl:value-of 
select="php:function('lang', 'zip code')"/>
+                                                       </label>
+                                                       <input type="text" 
name="zip_code" value="{vendor/zip_code}">
+                                                               <xsl:attribute 
name="data-validation">
+                                                                       
<xsl:text>required</xsl:text>
+                                                               </xsl:attribute>
+                                                               <xsl:attribute 
name="placeholder">
+                                                                       
<xsl:value-of select="php:function('lang', 'zip code')"/>
+                                                               </xsl:attribute>
+                                                       </input>
+                                                       <input type="text" 
name="city" value="{vendor/city}">
+                                                               <xsl:attribute 
name="data-validation">
+                                                                       
<xsl:text>required</xsl:text>
+                                                               </xsl:attribute>
+                                                               <xsl:attribute 
name="placeholder">
+                                                                       
<xsl:value-of select="php:function('lang', 'city')"/>
+                                                               </xsl:attribute>
+                                                       </input>
+                                               </div>
+                                               <div class="pure-control-group">
+                                                       <label>
+                                                               <xsl:value-of 
select="php:function('lang', 'organization number')"/>
+                                                       </label>
+                                                       <input type="text" 
id="organization_number" name="organization_number" 
value="{vendor/organization_number}">
+                                                               <xsl:attribute 
name="data-validation">
+                                                                       
<xsl:text>required</xsl:text>
+                                                               </xsl:attribute>
+                                                               <xsl:attribute 
name="placeholder">
+                                                                       
<xsl:value-of select="php:function('lang', 'organization number')"/>
+                                                               </xsl:attribute>
+                                                       </input>
+                                               </div>
+                                               <div class="pure-control-group">
+                                                       <label>
+                                                               <xsl:value-of 
select="php:function('lang', 'contact name')"/>
+                                                       </label>
+                                                       <input type="text" 
name="contact_name" value="{vendor/contact_name}">
+                                                               <xsl:attribute 
name="data-validation">
+                                                                       
<xsl:text>required</xsl:text>
+                                                               </xsl:attribute>
+                                                               <xsl:attribute 
name="placeholder">
+                                                                       
<xsl:value-of select="php:function('lang', 'contact name')"/>
+                                                               </xsl:attribute>
+                                                       </input>
+                                               </div>
+                                               <div class="pure-control-group">
+                                                       <label>
+                                                               <xsl:value-of 
select="php:function('lang', 'email')"/>
+                                                       </label>
+                                                       <input type="text" 
name="contact_email" id="contact_email" value="{vendor/contact_email}">
+                                                               <xsl:attribute 
name="data-validation">
+                                                                       
<xsl:text>email</xsl:text>
+                                                               </xsl:attribute>
+                                                               <xsl:attribute 
name="placeholder">
+                                                                       
<xsl:value-of select="php:function('lang', 'email')"/>
+                                                               </xsl:attribute>
+                                                       </input>
+                                               </div>
+                                               <div class="pure-control-group">
+                                                       <label>
+                                                               <xsl:value-of 
select="php:function('lang', 'contact phone')"/>
+                                                       </label>
+                                                       <input type="text" 
name="contact_phone" value="{vendor/contact_phone}">
+                                                               <xsl:attribute 
name="data-validation">
+                                                                       
<xsl:text>required</xsl:text>
+                                                               </xsl:attribute>
+                                                               <xsl:attribute 
name="placeholder">
+                                                                       
<xsl:value-of select="php:function('lang', 'contact phone')"/>
+                                                               </xsl:attribute>
+                                                       </input>
+                                               </div>
+                                               <div class="pure-control-group">
+                                                       <label>
+                                                               <xsl:value-of 
select="php:function('lang', 'account number')"/>
+                                                       </label>
+                                                       <input type="text" 
name="account_number" value="{vendor/account_number}">
+                                                               <xsl:attribute 
name="data-validation">
+                                                                       
<xsl:text>required</xsl:text>
+                                                               </xsl:attribute>
+                                                               <xsl:attribute 
name="placeholder">
+                                                                       
<xsl:value-of select="php:function('lang', 'account number')"/>
+                                                               </xsl:attribute>
+                                                       </input>
+                                               </div>
+                                               <div class="pure-control-group">
+                                                       <label>
+                                                               <xsl:value-of 
select="php:function('lang', 'description')"/>
+                                                       </label>
+                                                       <textarea cols="47" 
rows="7" name="description">
+                                                               <xsl:value-of 
select="vendor/description"/>
+                                                       </textarea>
+                                               </div>
+                                               <div class="pure-control-group">
+                                                       <label>
+                                                               <xsl:value-of 
select="php:function('lang', 'remark')"/>
+                                                       </label>
+                                                       <textarea cols="47" 
rows="7" name="remark">
+                                                               <xsl:attribute 
name="data-validation">
+                                                                       
<xsl:text>required</xsl:text>
+                                                               </xsl:attribute>
+                                                               <xsl:value-of 
select="vendor/remark"/>
+                                                       </textarea>
+                                               </div>
+                                               <div class="pure-control-group">
+                                                       <label>
+                                                               <xsl:value-of 
select="php:function('lang', 'comment')"/>
+                                                       </label>
+                                                       <textarea cols="47" 
rows="7" name="comment">
+                                                               <xsl:value-of 
select="vendor/comment"/>
+                                                       </textarea>
+                                               </div>
+                                               <div class="pure-control-group">
+                                                       <label>
+                                                               <xsl:value-of 
select="php:function('lang', 'history')"/>
+                                                       </label>
+                                                       <div 
class="pure-custom">
+                                                               <xsl:for-each 
select="datatable_def">
+                                                                       <xsl:if 
test="container = 'datatable-container_0'">
+                                                                               
<xsl:call-template name="table_setup">
+                                                                               
        <xsl:with-param name="container" select ='container'/>
+                                                                               
        <xsl:with-param name="requestUrl" select ='requestUrl'/>
+                                                                               
        <xsl:with-param name="ColumnDefs" select ='ColumnDefs'/>
+                                                                               
        <xsl:with-param name="data" select ='data'/>
+                                                                               
        <xsl:with-param name="config" select ='config'/>
+                                                                               
</xsl:call-template>
+                                                                       
</xsl:if>
+                                                               </xsl:for-each>
+                                                       </div>
+                                               </div>
+                                       </fieldset>
+                               </div>
+                       </div>
+                       <div class="proplist-col">
+                               <input type="submit" class="pure-button 
pure-button-primary" name="save">
+                                       <xsl:attribute name="value">
+                                               <xsl:value-of 
select="php:function('lang', 'save')"/>
+                                       </xsl:attribute>
+                               </input>
+                               <xsl:variable name="cancel_url">
+                                       <xsl:value-of select="cancel_url"/>
+                               </xsl:variable>
+                               <input type="button" class="pure-button 
pure-button-primary" name="cancel" onClick="window.location = '{cancel_url}';">
+                                       <xsl:attribute name="value">
+                                               <xsl:value-of 
select="php:function('lang', 'cancel')"/>
+                                       </xsl:attribute>
+                               </input>
+                       </div>
+               </form>
+       </div>
+</xsl:template>
+
+<xsl:template match="options">
+       <option value="{id}">
+               <xsl:if test="selected != 0">
+                       <xsl:attribute name="selected" value="selected"/>
+               </xsl:if>
+               <xsl:value-of disable-output-escaping="yes" select="name"/>
+       </option>
+</xsl:template>
+
+
+<xsl:template xmlns:php="http://php.net/xsl"; match="view">
+       <div>
+               <form id="form" name="form" method="post" action="" 
class="pure-form pure-form-aligned">
+                       <div id="tab-content">
+                               <xsl:value-of disable-output-escaping="yes" 
select="tabs"/>
+                               <div id="showing">
+
+                               </div>
+                       </div>
+                       <div class="proplist-col">
+                               <xsl:variable name="cancel_url">
+                                       <xsl:value-of select="cancel_url"/>
+                               </xsl:variable>
+                               <input type="button" class="pure-button 
pure-button-primary" name="cancel" value="{lang_cancel}" 
onMouseout="window.status='';return true;" onClick="window.location = 
'{cancel_url}';"/>
+                       </div>
+               </form>
+       </div>
+</xsl:template>

Added: trunk/eventplannerfrontend/templates/base/vendor_report.xsl
===================================================================
--- trunk/eventplannerfrontend/templates/base/vendor_report.xsl                 
        (rev 0)
+++ trunk/eventplannerfrontend/templates/base/vendor_report.xsl 2017-01-23 
15:56:25 UTC (rev 16184)
@@ -0,0 +1,143 @@
+
+<!-- $Id: price_item.xsl 12604 2015-01-15 17:06:11Z nelson224 $ -->
+<xsl:template match="data">
+       <xsl:choose>
+               <xsl:when test="edit">
+                       <xsl:apply-templates select="edit" />
+               </xsl:when>
+               <xsl:when test="view">
+                       <xsl:apply-templates select="view" />
+               </xsl:when>
+       </xsl:choose>
+
+</xsl:template>
+
+<!-- add / edit  -->
+<xsl:template xmlns:php="http://php.net/xsl"; match="edit">
+       <xsl:variable name="date_format">
+               <xsl:value-of select="php:function('get_phpgw_info', 
'user|preferences|common|dateformat')" />
+               <xsl:text> H:i</xsl:text>
+       </xsl:variable>
+       <xsl:variable name="form_action">
+               <xsl:value-of select="form_action"/>
+       </xsl:variable>
+       <xsl:variable name="mode">
+               <xsl:value-of select="mode"/>
+       </xsl:variable>
+
+       <div>
+               <script type="text/javascript">
+                       var lang = <xsl:value-of 
select="php:function('js_lang', 'Name or company is required')"/>;
+               </script>
+               <form id="form" name="form" method="post" 
action="{$form_action}" class="pure-form pure-form-aligned">
+                       <div id="tab-content">
+                               <xsl:value-of disable-output-escaping="yes" 
select="tabs"/>
+                               <input type="hidden" id="active_tab" 
name="active_tab" value="{value_active_tab}"/>
+                               <div id="first_tab">
+                                       <xsl:if test="booking/id > 0">
+                                               <div class="pure-control-group">
+                                                       <label>
+                                                               <a 
href="{booking_url}">
+                                                                       
<xsl:value-of select="php:function('lang', 'booking')"/>
+                                                               </a>
+                                                       </label>
+                                                       <input type="hidden" 
name="booking_id" value="{booking/id}"/>
+                                                       <xsl:value-of 
select="booking/id"/>
+                                               </div>
+                                       </xsl:if>
+                                       <xsl:if test="vendor_report/id > 0">
+                                               <div class="pure-control-group">
+                                                       <label>
+                                                               <xsl:value-of 
select="php:function('lang', 'report')"/>
+                                                       </label>
+                                                       <input type="hidden" 
name="id" value="{vendor_report/id}"/>
+                                                       <xsl:value-of 
select="vendor_report/id"/>
+                                               </div>
+                                       </xsl:if>
+                                       <xsl:call-template 
name="application_info">
+                                               <xsl:with-param 
name="application" select ='application'/>
+                                               <xsl:with-param 
name="application_type_list" select ='application_type_list'/>
+                                       </xsl:call-template>
+                                       <div class="pure-control-group">
+                                               <xsl:variable name="lang_from">
+                                                       <xsl:value-of 
select="php:function('lang', 'from')"/>
+                                               </xsl:variable>
+                                               <label>
+                                                       <xsl:value-of 
select="$lang_from"/>
+                                               </label>
+                                               <xsl:value-of 
select="php:function('show_date', number(booking/from_), $date_format)"/>
+                                       </div>
+
+                                       <div class="pure-control-group">
+                                               <label>
+                                                       <xsl:value-of 
select="php:function('lang', 'to')"/>
+                                               </label>
+                                               <xsl:value-of 
select="php:function('show_date', number(booking/to_), $date_format)"/>
+                                       </div>
+                                       <div class="pure-control-group">
+                                               <label>
+                                                       <xsl:value-of 
select="php:function('lang', 'customer')"/>
+                                               </label>
+                                               <xsl:value-of 
select="booking/customer_name"/>
+                                       </div>
+                                       <div class="pure-control-group">
+                                               <label>
+                                                       <xsl:value-of 
select="php:function('lang', 'location')"/>
+                                               </label>
+                                               <xsl:value-of 
select="booking/location"/>
+                                       </div>
+                       
+                                       <fieldset>
+                                               <!--xsl:apply-templates 
select="attributes_group/attributes"/-->
+                                               <xsl:call-template 
name="attributes_values"/>
+
+                                       </fieldset>
+                               </div>
+                       </div>
+                       <div class="proplist-col">
+                               <input type="submit" class="pure-button 
pure-button-primary" name="save">
+                                       <xsl:attribute name="value">
+                                               <xsl:value-of 
select="php:function('lang', 'save')"/>
+                                       </xsl:attribute>
+                               </input>
+                               <xsl:variable name="cancel_url">
+                                       <xsl:value-of select="cancel_url"/>
+                               </xsl:variable>
+                               <input type="button" class="pure-button 
pure-button-primary" name="cancel" onClick="window.location = '{cancel_url}';">
+                                       <xsl:attribute name="value">
+                                               <xsl:value-of 
select="php:function('lang', 'cancel')"/>
+                                       </xsl:attribute>
+                               </input>
+                       </div>
+               </form>
+       </div>
+</xsl:template>
+
+<xsl:template match="options">
+       <option value="{id}">
+               <xsl:if test="selected != 0">
+                       <xsl:attribute name="selected" value="selected"/>
+               </xsl:if>
+               <xsl:value-of disable-output-escaping="yes" select="name"/>
+       </option>
+</xsl:template>
+
+
+<xsl:template xmlns:php="http://php.net/xsl"; match="view">
+       <div>
+               <form id="form" name="form" method="post" action="" 
class="pure-form pure-form-aligned">
+                       <div id="tab-content">
+                               <xsl:value-of disable-output-escaping="yes" 
select="tabs"/>
+                               <div id="showing">
+
+                               </div>
+                       </div>
+                       <div class="proplist-col">
+                               <xsl:variable name="cancel_url">
+                                       <xsl:value-of select="cancel_url"/>
+                               </xsl:variable>
+                               <input type="button" class="pure-button 
pure-button-primary" name="cancel" value="{lang_cancel}" 
onMouseout="window.status='';return true;" onClick="window.location = 
'{cancel_url}';"/>
+                       </div>
+               </form>
+       </div>
+</xsl:template>




reply via email to

[Prev in Thread] Current Thread [Next in Thread]