[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Fmsystem-commits] [14225] validations
From: |
Saul |
Subject: |
[Fmsystem-commits] [14225] validations |
Date: |
Wed, 21 Oct 2015 00:20:36 +0000 |
Revision: 14225
http://svn.sv.gnu.org/viewvc/?view=rev&root=fmsystem&revision=14225
Author: psaul
Date: 2015-10-21 00:20:35 +0000 (Wed, 21 Oct 2015)
Log Message:
-----------
validations
Modified Paths:
--------------
branches/dev-syncromind/booking/inc/class.uiaccount_code_set.inc.php
branches/dev-syncromind/booking/inc/class.uiactivity.inc.php
branches/dev-syncromind/booking/inc/class.uiallocation.inc.php
branches/dev-syncromind/booking/inc/class.uiapplication.inc.php
branches/dev-syncromind/booking/inc/class.uibooking.inc.php
branches/dev-syncromind/booking/inc/class.uicompleted_reservation.inc.php
branches/dev-syncromind/booking/inc/class.uidocumentation.inc.php
branches/dev-syncromind/booking/inc/class.uipermission_root.inc.php
branches/dev-syncromind/booking/inc/class.uireports.inc.php
branches/dev-syncromind/booking/inc/class.uisend_email.inc.php
branches/dev-syncromind/booking/js/booking/allocation.js
branches/dev-syncromind/booking/js/booking/application.js
branches/dev-syncromind/booking/js/booking/booking.js
branches/dev-syncromind/booking/js/booking/email_send.js
branches/dev-syncromind/booking/templates/base/account_code_set_form.xsl
branches/dev-syncromind/booking/templates/base/activity_edit.xsl
branches/dev-syncromind/booking/templates/base/activity_new.xsl
branches/dev-syncromind/booking/templates/base/agegroup_edit.xsl
branches/dev-syncromind/booking/templates/base/agegroup_new.xsl
branches/dev-syncromind/booking/templates/base/allocation_edit.xsl
branches/dev-syncromind/booking/templates/base/allocation_new.xsl
branches/dev-syncromind/booking/templates/base/application_edit.xsl
branches/dev-syncromind/booking/templates/base/application_new.xsl
branches/dev-syncromind/booking/templates/base/audience_edit.xsl
branches/dev-syncromind/booking/templates/base/audience_new.xsl
branches/dev-syncromind/booking/templates/base/booking_new.xsl
branches/dev-syncromind/booking/templates/base/completed_reservation_edit.xsl
branches/dev-syncromind/booking/templates/base/documentation_form.xsl
branches/dev-syncromind/booking/templates/base/email_index.xsl
branches/dev-syncromind/booking/templates/base/permission_root_form.xsl
branches/dev-syncromind/booking/templates/base/report_participants.xsl
Modified: branches/dev-syncromind/booking/inc/class.uiaccount_code_set.inc.php
===================================================================
--- branches/dev-syncromind/booking/inc/class.uiaccount_code_set.inc.php
2015-10-21 00:14:30 UTC (rev 14224)
+++ branches/dev-syncromind/booking/inc/class.uiaccount_code_set.inc.php
2015-10-21 00:20:35 UTC (rev 14225)
@@ -176,11 +176,12 @@
$account_code_set['cancel_link'] =
$this->link_to('show', array('id' => $account_code_set['id']));
$this->flash_form_errors($errors);
- $tabs = array();
- $tabs['generic'] = array('label' => lang('Account Edit'), 'link'
=> '#account');
- $active_tab = 'generic';
+ $tabs = array();
+ $tabs['generic'] = array('label' => lang('Account
Edit'), 'link' => '#account');
+ $active_tab = 'generic';
- $account_code_set['tabs'] =
phpgwapi_jquery::tabview_generate($tabs, $active_tab);
+ $account_code_set['tabs'] =
phpgwapi_jquery::tabview_generate($tabs, $active_tab);
+ phpgwapi_jquery::formvalidator_generate(array());
self::render_template_xsl('account_code_set_form',
array('account_code_set' => $account_code_set, 'config_data' =>
$config->config_data));
}
@@ -226,6 +227,7 @@
$active_tab = 'generic';
$account_code_set['tabs'] =
phpgwapi_jquery::tabview_generate($tabs, $active_tab);
+ phpgwapi_jquery::formvalidator_generate(array());
self::render_template_xsl('account_code_set_form',
array('new_form' => true, 'account_code_set' => $account_code_set ,
'config_data' => $config->config_data));
}
Modified: branches/dev-syncromind/booking/inc/class.uiactivity.inc.php
===================================================================
--- branches/dev-syncromind/booking/inc/class.uiactivity.inc.php
2015-10-21 00:14:30 UTC (rev 14224)
+++ branches/dev-syncromind/booking/inc/class.uiactivity.inc.php
2015-10-21 00:20:35 UTC (rev 14225)
@@ -123,6 +123,7 @@
$active_tab = 'generic';
$activity['tabs'] =
phpgwapi_jquery::tabview_generate($tabs, $active_tab);
+ $activity['validator'] =
phpgwapi_jquery::formvalidator_generate(array('location', 'date', 'security',
'file'));
self::render_template_xsl('activity_new',
array('activity' => $activity, 'activities' => $activities));
}
@@ -162,6 +163,7 @@
$active_tab = 'generic';
$activity['tabs'] =
phpgwapi_jquery::tabview_generate($tabs, $active_tab);
+ $activity['validator'] =
phpgwapi_jquery::formvalidator_generate(array('location', 'date', 'security',
'file'));
self::render_template_xsl('activity_edit',
array('activity' => $activity, 'parent' => $parent_activity, 'activities' =>
$activities));
}
Modified: branches/dev-syncromind/booking/inc/class.uiallocation.inc.php
===================================================================
--- branches/dev-syncromind/booking/inc/class.uiallocation.inc.php
2015-10-21 00:14:30 UTC (rev 14224)
+++ branches/dev-syncromind/booking/inc/class.uiallocation.inc.php
2015-10-21 00:20:35 UTC (rev 14225)
@@ -395,14 +395,15 @@
$allocation['cancel_link'] =
self::link(array('menuaction' => 'booking.uiallocation.index'));
array_set_default($allocation, 'cost', '0');
- $GLOBALS['phpgw']->jqcal->add_listener('field_from',
'time');
+ $GLOBALS['phpgw']->jqcal->add_listener('field_from',
'time');
$GLOBALS['phpgw']->jqcal->add_listener('field_to',
'time');
-
- $tabs = array();
- $tabs['generic'] = array('label' => lang('Allocation
New'), 'link' => '#allocation_new');
- $active_tab = 'generic';
- $allocation['tabs'] =
phpgwapi_jquery::tabview_generate($tabs, $active_tab);
+ $tabs = array();
+ $tabs['generic'] = array('label' => lang('Allocation
New'), 'link' => '#allocation_new');
+ $active_tab = 'generic';
+
+ $allocation['tabs'] =
phpgwapi_jquery::tabview_generate($tabs, $active_tab);
+ $allocation['validator'] =
phpgwapi_jquery::formvalidator_generate(array('location', 'date', 'security',
'file'));
if ($step < 2)
{
@@ -471,7 +472,7 @@
$allocation['building'] =
$this->building_bo->so->read_single($allocation['building_id']);
$allocation['building_name'] =
$allocation['building']['name'];
$errors = array();
- $tabs = array();
+ $tabs = array();
$tabs['generic'] = array('label' =>
lang('Allocations Edit'), 'link' => '#allocations_edit');
$active_tab = 'generic';
@@ -499,18 +500,19 @@
}
}
- $allocation['from_'] =
pretty_timestamp($allocation['from_']);
- $allocation['to_'] =
pretty_timestamp($allocation['to_']);
-
+ $allocation['from_'] =
pretty_timestamp($allocation['from_']);
+ $allocation['to_'] =
pretty_timestamp($allocation['to_']);
+
$this->flash_form_errors($errors);
self::add_javascript('booking', 'booking',
'allocation.js');
$allocation['resources_json'] =
json_encode(array_map('intval', $allocation['resources']));
$allocation['cancel_link'] =
self::link(array('menuaction' => 'booking.uiallocation.show', 'id' =>
$allocation['id']));
$allocation['application_link'] =
self::link(array('menuaction' => 'booking.uiapplication.show', 'id' =>
$allocation['application_id']));
- $allocation['tabs'] =
phpgwapi_jquery::tabview_generate($tabs, $active_tab);
- $GLOBALS['phpgw']->jqcal->add_listener('field_from',
'datetime');
+ $allocation['tabs'] =
phpgwapi_jquery::tabview_generate($tabs, $active_tab);
+ $allocation['validator'] =
phpgwapi_jquery::formvalidator_generate(array('location', 'date', 'security',
'file'));
+ $GLOBALS['phpgw']->jqcal->add_listener('field_from',
'datetime');
$GLOBALS['phpgw']->jqcal->add_listener('field_to',
'datetime');
-
+
self::render_template_xsl('allocation_edit',
array('allocation' => $allocation));
}
Modified: branches/dev-syncromind/booking/inc/class.uiapplication.inc.php
===================================================================
--- branches/dev-syncromind/booking/inc/class.uiapplication.inc.php
2015-10-21 00:14:30 UTC (rev 14224)
+++ branches/dev-syncromind/booking/inc/class.uiapplication.inc.php
2015-10-21 00:20:35 UTC (rev 14225)
@@ -787,22 +787,24 @@
}
}
- foreach ($application['dates'] as &$date) {
- $date['from_'] = pretty_timestamp($date['from_']);
- $date['to_'] = pretty_timestamp($date['to_']);
- }
-
+ foreach ($application['dates'] as &$date) {
+ $date['from_'] =
pretty_timestamp($date['from_']);
+ $date['to_'] = pretty_timestamp($date['to_']);
+ }
+
$GLOBALS['phpgw']->jqcal->add_listener('start_date',
'datetime');
$GLOBALS['phpgw']->jqcal->add_listener('end_date',
'datetime');
-
- $tabs = array();
- $tabs['generic'] = array('label' => lang('Application
Add'), 'link' => '#application_add');
- $active_tab = 'generic';
- $application['tabs'] =
phpgwapi_jquery::tabview_generate($tabs, $active_tab);
- self::add_javascript('booking', 'booking',
'application.js');
- self::adddatetimepicker();
-
+ $tabs = array();
+ $tabs['generic'] = array('label' => lang('Application
Add'), 'link' => '#application_add');
+ $active_tab = 'generic';
+
+ $application['tabs'] =
phpgwapi_jquery::tabview_generate($tabs, $active_tab);
+ $application['validator'] =
phpgwapi_jquery::formvalidator_generate(array('location', 'date', 'security',
'file'));
+
+ self::add_javascript('booking', 'booking',
'application.js');
+ self::adddatetimepicker();
+
self::render_template_xsl('application_new',
array('application' => $application, 'activities' => $activities, 'agegroups'
=> $agegroups, 'audience' => $audience,'config' => $application_text));
}
@@ -881,13 +883,14 @@
$this->install_customer_identifier_ui($application);
$application['customer_identifier_types']['ssn'] =
'Date of birth or SSN';
//test
-
- $GLOBALS['phpgw']->jqcal->add_listener('start_date',
'datetime');
-
$GLOBALS['phpgw']->jqcal->add_listener('end_date', 'datetime');
+
+ $GLOBALS['phpgw']->jqcal->add_listener('start_date',
'datetime');
+ $GLOBALS['phpgw']->jqcal->add_listener('end_date',
'datetime');
// self::render_template('application_edit',
array('application' => $application, 'activities' => $activities, 'agegroups'
=> $agegroups, 'audience' => $audience));
- $application['tabs'] =
phpgwapi_jquery::tabview_generate($tabs, $active_tab);
+ $application['tabs'] =
phpgwapi_jquery::tabview_generate($tabs, $active_tab);
+ $application['validator'] =
phpgwapi_jquery::formvalidator_generate(array('location', 'date', 'security',
'file'));
- self::render_template_xsl('application_edit',
array('application' => $application, 'activities' => $activities, 'agegroups'
=> $agegroups, 'audience' => $audience));
+ self::render_template_xsl('application_edit',
array('application' => $application, 'activities' => $activities, 'agegroups'
=> $agegroups, 'audience' => $audience));
}
private function check_date_availability(&$allocation)
Modified: branches/dev-syncromind/booking/inc/class.uibooking.inc.php
===================================================================
--- branches/dev-syncromind/booking/inc/class.uibooking.inc.php 2015-10-21
00:14:30 UTC (rev 14224)
+++ branches/dev-syncromind/booking/inc/class.uibooking.inc.php 2015-10-21
00:20:35 UTC (rev 14225)
@@ -546,17 +546,18 @@
$groups = $groups['results'];
$resouces_full =
$this->resource_bo->so->read(array('filters'=>array('id'=>$booking['resources']),
'sort'=>'name'));
-
- $tabs = array();
- $tabs['generic'] = array('label' => lang('Booking
New'), 'link' => '#booking_new');
- $active_tab = 'generic';
-
$GLOBALS['phpgw']->jqcal->add_listener('field_repeat_until', 'date');
- $GLOBALS['phpgw']->jqcal->add_listener('start_date',
'datetime');
- $GLOBALS['phpgw']->jqcal->add_listener('end_date',
'datetime');
+ $tabs = array();
+ $tabs['generic'] = array('label' => lang('Booking
New'), 'link' => '#booking_new');
+ $active_tab = 'generic';
- $booking['tabs'] =
phpgwapi_jquery::tabview_generate($tabs, $active_tab);
-
+
$GLOBALS['phpgw']->jqcal->add_listener('field_repeat_until', 'date');
+ $GLOBALS['phpgw']->jqcal->add_listener('start_date',
'datetime');
+ $GLOBALS['phpgw']->jqcal->add_listener('end_date',
'datetime');
+
+ $booking['tabs'] =
phpgwapi_jquery::tabview_generate($tabs, $active_tab);
+ $booking['validator'] =
phpgwapi_jquery::formvalidator_generate(array('location', 'date', 'security',
'file'));
+
if ($step < 2)
{
self::render_template_xsl('booking_new',
array('booking' => $booking,
@@ -679,12 +680,13 @@
$audience = $audience['results'];
$activities = $this->activity_bo->fetch_activities();
$activities = $activities['results'];
-
- $GLOBALS['phpgw']->jqcal->add_listener('field_from',
'datetime');
+
+ $GLOBALS['phpgw']->jqcal->add_listener('field_from',
'datetime');
$GLOBALS['phpgw']->jqcal->add_listener('field_to',
'datetime');
-
- $booking['tabs'] =
phpgwapi_jquery::tabview_generate($tabs, $active_tab);
-
+
+ $booking['tabs'] =
phpgwapi_jquery::tabview_generate($tabs, $active_tab);
+ $booking['validator'] =
phpgwapi_jquery::formvalidator_generate(array('location', 'date', 'security',
'file'));
+
self::render_template_xsl('booking_edit',
array('booking' => $booking, 'activities' => $activities, 'agegroups' =>
$agegroups, 'audience' => $audience));
}
Modified:
branches/dev-syncromind/booking/inc/class.uicompleted_reservation.inc.php
===================================================================
--- branches/dev-syncromind/booking/inc/class.uicompleted_reservation.inc.php
2015-10-21 00:14:30 UTC (rev 14224)
+++ branches/dev-syncromind/booking/inc/class.uicompleted_reservation.inc.php
2015-10-21 00:20:35 UTC (rev 14225)
@@ -730,7 +730,7 @@
}
public function edit()
- {
+ {
//TODO: Display hint to user about primary type of
customer identifier
$building_role =
$this->bo->accessable_buildings($GLOBALS['phpgw_info']['user']['id']);
@@ -766,6 +766,7 @@
$tabs['completed_reservation_edit'] = array('label' =>
lang('Reservation edit'), 'link' => '#completed_reservation_edit');
$active_tab = 'completed_reservation_edit';
$reservation['tabs'] =
phpgwapi_jquery::tabview_generate($tabs, $active_tab);
+ $reservation['validator'] =
phpgwapi_jquery::formvalidator_generate(array('location', 'date', 'security',
'file'));
$this->add_default_display_data($reservation);
$this->flash_form_errors($errors);
Modified: branches/dev-syncromind/booking/inc/class.uidocumentation.inc.php
===================================================================
--- branches/dev-syncromind/booking/inc/class.uidocumentation.inc.php
2015-10-21 00:14:30 UTC (rev 14224)
+++ branches/dev-syncromind/booking/inc/class.uidocumentation.inc.php
2015-10-21 00:20:35 UTC (rev 14225)
@@ -196,11 +196,12 @@
$this->flash_form_errors($errors);
- $tabs = array();
- $tabs['generic'] = array('label' =>
lang('Documentation'), 'link' => '#documentation');
- $active_tab = 'generic';
+ $tabs = array();
+ $tabs['generic'] = array('label' =>
lang('Documentation'), 'link' => '#documentation');
+ $active_tab = 'generic';
- $document['tabs'] =
phpgwapi_jquery::tabview_generate($tabs, $active_tab);
+ $document['tabs'] =
phpgwapi_jquery::tabview_generate($tabs, $active_tab);
+ phpgwapi_jquery::formvalidator_generate(array());
self::render_template_xsl('documentation_form',
array('document' => $document));
}
@@ -226,12 +227,13 @@
$this->flash_form_errors($errors);
$this->add_default_display_data($document);
- $tabs = array();
- $tabs['generic'] = array('label' =>
lang('Documentation'), 'link' => '#documentation');
- $active_tab = 'generic';
+ $tabs = array();
+ $tabs['generic'] = array('label' =>
lang('Documentation'), 'link' => '#documentation');
+ $active_tab = 'generic';
- $document['tabs'] =
phpgwapi_jquery::tabview_generate($tabs, $active_tab);
-
+ $document['tabs'] =
phpgwapi_jquery::tabview_generate($tabs, $active_tab);
+ phpgwapi_jquery::formvalidator_generate(array());
+
self::render_template_xsl('documentation_form',
array('document' => $document));
}
Modified: branches/dev-syncromind/booking/inc/class.uipermission_root.inc.php
===================================================================
--- branches/dev-syncromind/booking/inc/class.uipermission_root.inc.php
2015-10-21 00:14:30 UTC (rev 14224)
+++ branches/dev-syncromind/booking/inc/class.uipermission_root.inc.php
2015-10-21 00:20:35 UTC (rev 14225)
@@ -210,6 +210,7 @@
// $data = array();
$permission['tabs'] =
phpgwapi_jquery::tabview_generate($tabs, $active_tab);
+ $permission['validator'] =
phpgwapi_jquery::formvalidator_generate(array('location', 'date', 'security',
'file'));
self::render_template_xsl('permission_root_form',
array('permission' => $permission));
}
Modified: branches/dev-syncromind/booking/inc/class.uireports.inc.php
===================================================================
--- branches/dev-syncromind/booking/inc/class.uireports.inc.php 2015-10-21
00:14:30 UTC (rev 14224)
+++ branches/dev-syncromind/booking/inc/class.uireports.inc.php 2015-10-21
00:20:35 UTC (rev 14225)
@@ -350,6 +350,7 @@
$data = array();
$data['tabs'] =
phpgwapi_jquery::tabview_generate($tabs, $active_tab);
+ $data['validator'] =
phpgwapi_jquery::formvalidator_generate(array('location', 'date', 'security',
'file'));
self::render_template_xsl('report_participants',
array('data' => $data, 'from' => $from,
'to' => $to, 'buildings' =>
$buildings['results']));
Modified: branches/dev-syncromind/booking/inc/class.uisend_email.inc.php
===================================================================
--- branches/dev-syncromind/booking/inc/class.uisend_email.inc.php
2015-10-21 00:14:30 UTC (rev 14224)
+++ branches/dev-syncromind/booking/inc/class.uisend_email.inc.php
2015-10-21 00:20:35 UTC (rev 14225)
@@ -83,6 +83,7 @@
$active_tab = 'generic';
$building['tabs'] =
phpgwapi_jquery::tabview_generate($tabs, $active_tab);
+ $building['validator'] =
phpgwapi_jquery::formvalidator_generate(array('location', 'date', 'security',
'file'));
if ($step == 1)
self::render_template_xsl('email_index',
Modified: branches/dev-syncromind/booking/js/booking/allocation.js
===================================================================
--- branches/dev-syncromind/booking/js/booking/allocation.js 2015-10-21
00:14:30 UTC (rev 14224)
+++ branches/dev-syncromind/booking/js/booking/allocation.js 2015-10-21
00:20:35 UTC (rev 14225)
@@ -30,13 +30,13 @@
function populateSelectSeason (building_id, selection) {
var url =
'index.php?menuaction=booking.uiseason.index&sort=name&filter_building_id=' +
building_id + '&phpgw_return_as=json&';
var container = $('#season_container');
- var attr = [{name: 'name',value: 'season_id'}];
+ var attr = [{name: 'name',value: 'season_id'},{name: 'data-validation',
value: 'required'}];
populateSelect(url, selection, container, attr);
}
function populateTableChkResources (building_id, selection) {
var url =
'index.php?menuaction=booking.uiresource.index&sort=name&filter_building_id=' +
building_id + '&phpgw_return_as=json&';
var container = 'resources_container';
- var colDefsResources = [{label: '', object: [{type: 'input', attrs:
[{name: 'type', value: 'checkbox'},{name: 'name', value: 'resources[]'}]}],
value: 'id', checked: selection},{key: 'name', label: lang['Name']}, {key:
'type', label: lang['Resource Type']}];
+ var colDefsResources = [{label: '', object: [{type: 'input', attrs:
[{name: 'type', value: 'checkbox'},{name: 'name', value: 'resources[]'},{name:
'data-validation', value: 'checkbox_group'},{name: 'data-validation-qty',
value: 'min1'},{name: 'data-validation-error-msg', value: 'Please choose at
least 1 resource'}]}], value: 'id', checked: selection},{key: 'name', label:
lang['Name']}, {key: 'type', label: lang['Resource Type']}];
populateTableChk(url, container, colDefsResources);
}
Modified: branches/dev-syncromind/booking/js/booking/application.js
===================================================================
--- branches/dev-syncromind/booking/js/booking/application.js 2015-10-21
00:14:30 UTC (rev 14224)
+++ branches/dev-syncromind/booking/js/booking/application.js 2015-10-21
00:20:35 UTC (rev 14225)
@@ -105,7 +105,7 @@
function populateTableChkResources (building_id, selection) {
var url =
'index.php?menuaction=bookingfrontend.uiresource.index_json&sort=name&filter_building_id='
+ building_id + '&phpgw_return_as=json&';
var container = 'resources_container';
- var colDefsResources = [{label: '', object: [{type: 'input', attrs:
[{name: 'type', value: 'checkbox'},{name: 'name', value: 'resources[]'},{name:
'class', value: 'chkRegulations'}]}], value: 'id', checked: selection},{key:
'name', label: lang['Name']}, {key: 'type', label: lang['Resource Type']}];
+ var colDefsResources = [{label: '', object: [{type: 'input', attrs:
[{name: 'type', value: 'checkbox'},{name: 'name', value: 'resources[]'},{name:
'class', value: 'chkRegulations'},{name: 'data-validation', value:
'checkbox_group'},{name: 'data-validation-qty', value: 'min1'},{name:
'data-validation-error-msg', value: 'Please choose at least 1 resource'}]}],
value: 'id', checked: selection},{key: 'name', label: lang['Name']}, {key:
'type', label: lang['Resource Type']}];
populateTableResources(url, container, colDefsResources);
}
Modified: branches/dev-syncromind/booking/js/booking/booking.js
===================================================================
--- branches/dev-syncromind/booking/js/booking/booking.js 2015-10-21
00:14:30 UTC (rev 14224)
+++ branches/dev-syncromind/booking/js/booking/booking.js 2015-10-21
00:20:35 UTC (rev 14225)
@@ -43,19 +43,19 @@
function populateSelectSeason (building_id, selection) {
var url =
'index.php?menuaction=booking.uiseason.index&sort=name&filter_building_id=' +
building_id + '&phpgw_return_as=json&';
var container = $('#season_container');
- var attr = [{name: 'name',value: 'season_id'}];
+ var attr = [{name: 'name',value: 'season_id'},{name: 'data-validation',
value: 'required'}];
populateSelect(url, selection, container, attr);
}
function populateSelectGroup (organization_id, selection) {
var url =
'index.php?menuaction=booking.uigroup.index&filter_organization_id=' +
organization_id + '&phpgw_return_as=json';
var container = $('#group_container');
- var attr = [{name: 'name',value: 'group_id'}];
+ var attr = [{name: 'name',value: 'group_id'},{name: 'data-validation',
value: 'required'}];
populateSelect(url, selection, container, attr);
};
function populateTableChkResources (building_id, selection) {
var url =
'index.php?menuaction=booking.uiresource.index&sort=name&filter_building_id=' +
building_id + '&phpgw_return_as=json&';
var container = 'resources_container';
- var colDefsResources = [{label: '', object: [{type: 'input', attrs:
[{name: 'type', value: 'checkbox'},{name: 'name', value: 'resources[]'}]}],
value: 'id', checked: selection},{key: 'name', label: lang['Name']}, {key:
'type', label: lang['Resource Type']}];
+ var colDefsResources = [{label: '', object: [{type: 'input', attrs:
[{name: 'type', value: 'checkbox'},{name: 'name', value: 'resources[]'},{name:
'data-validation', value: 'checkbox_group'},{name: 'data-validation-qty',
value: 'min1'},{name: 'data-validation-error-msg', value: 'Please choose at
least 1 resource'}]}], value: 'id', checked: selection},{key: 'name', label:
lang['Name']}, {key: 'type', label: lang['Resource Type']}];
populateTableChk(url, container, colDefsResources);
}
Modified: branches/dev-syncromind/booking/js/booking/email_send.js
===================================================================
--- branches/dev-syncromind/booking/js/booking/email_send.js 2015-10-21
00:14:30 UTC (rev 14224)
+++ branches/dev-syncromind/booking/js/booking/email_send.js 2015-10-21
00:20:35 UTC (rev 14225)
@@ -25,7 +25,7 @@
function populateTableChkSeasons (building_id, selection) {
var url =
'index.php?menuaction=booking.uiseason.index&sort=name&filter_building_id=' +
building_id + '&phpgw_return_as=json&';
var container = 'season_container';
- var colDefsSeasons = [{label: '', object: [{type: 'input', attrs: [{name:
'type', value: 'checkbox'},{name: 'name', value: 'seasons[]'}]}], value: 'id',
checked: selection}, {key: 'name', label: lang['Name']}];
+ var colDefsSeasons = [{label: '', object: [{type: 'input', attrs: [{name:
'type', value: 'checkbox'},{name: 'name', value: 'seasons[]'},{name:
'data-validation', value: 'checkbox_group'},{name: 'data-validation-qty',
value: 'min1'},{name: 'data-validation-error-msg', value: 'Please choose at
least 1 season'}]}], value: 'id', checked: selection}, {key: 'name', label:
lang['Name']}];
populateTableChk(url, container, colDefsSeasons);
}
Modified:
branches/dev-syncromind/booking/templates/base/account_code_set_form.xsl
===================================================================
--- branches/dev-syncromind/booking/templates/base/account_code_set_form.xsl
2015-10-21 00:14:30 UTC (rev 14224)
+++ branches/dev-syncromind/booking/templates/base/account_code_set_form.xsl
2015-10-21 00:20:35 UTC (rev 14225)
@@ -25,7 +25,11 @@
<div class="pure-u-1 pure-u-sm-1 pure-u-md-2-3
pure-u-lg-1-2">
<div class="pure-control-group">
<label for="field_name"><xsl:value-of
select="php:function('lang', 'Name')" /></label>
- <input name="name" type="text" id="field_name"
value="{account_code_set/name}" class="pure-u-1" />
+ <input name="name" type="text" id="field_name"
value="{account_code_set/name}" class="pure-u-1">
+ <xsl:attribute name="data-validation">
+ <xsl:text>required</xsl:text>
+ </xsl:attribute>
+ </input>
</div>
</div>
</div>
@@ -34,19 +38,31 @@
<div class="pure-control-group">
<xsl:if test="config_data/dim_3">
<label
for="field_object_number"><xsl:value-of select="config_data/dim_3" /></label>
- <input name="object_number" type="text"
id="field_object_number" value="{account_code_set/object_number}" maxlength='8'
class="pure-u-1" />
+ <input name="object_number" type="text"
id="field_object_number" value="{account_code_set/object_number}" maxlength='8'
class="pure-u-1">
+ <xsl:attribute name="data-validation">
+ <xsl:text>required</xsl:text>
+ </xsl:attribute>
+ </input>
</xsl:if>
</div>
<div class="pure-control-group">
<xsl:if test="config_data/article">
<label for="field_article"><xsl:value-of
select="config_data/article" /></label>
- <input name="article" type="text"
id="field_article" value="{account_code_set/article}" maxlength='15'
class="pure-u-1" />
+ <input name="article" type="text"
id="field_article" value="{account_code_set/article}" maxlength='15'
class="pure-u-1">
+ <xsl:attribute name="data-validation">
+ <xsl:text>required</xsl:text>
+ </xsl:attribute>
+ </input>
</xsl:if>
</div>
<div class="pure-control-group">
<xsl:if test="config_data/dim_value_1">
<label
for="field_unit_number"><xsl:value-of select="config_data/dim_value_1"
/></label>
- <input name="unit_number" type="text"
id="field_unit_number" value="{account_code_set/unit_number}" maxlength='12'
class="pure-u-1" />
+ <input name="unit_number" type="text"
id="field_unit_number" value="{account_code_set/unit_number}" maxlength='12'
class="pure-u-1">
+ <xsl:attribute name="data-validation">
+ <xsl:text>required</xsl:text>
+ </xsl:attribute>
+ </input>
</xsl:if>
</div>
<div class="pure-control-group">
@@ -64,7 +80,11 @@
<div class="pure-control-group">
<!--xsl:if test="config_data/external_format =
'KOMMFAKT'"-->
<label
for="field_unit_prefix"><xsl:value-of select="php:function('lang', 'Unit
Prefix')" /></label>
- <input name="unit_prefix" type="text"
id="field_unit_prefix" value="{account_code_set/unit_prefix}" maxlength='1'
class="pure-u-1" />
+ <input name="unit_prefix" type="text"
id="field_unit_prefix" value="{account_code_set/unit_prefix}" maxlength='1'
class="pure-u-1">
+ <xsl:attribute name="data-validation">
+ <xsl:text>required</xsl:text>
+ </xsl:attribute>
+ </input>
<!--/xsl:if-->
</div>
</div>
@@ -72,6 +92,9 @@
<div class="pure-control-group">
<label for="field_active"><xsl:value-of
select="php:function('lang', 'Active')"/></label>
<select id="field_active" name="active"
class="pure-u-1">
+ <xsl:attribute name="data-validation">
+ <xsl:text>required</xsl:text>
+ </xsl:attribute>
<xsl:if test="new_form">
<xsl:attribute
name="disabled">disabled</xsl:attribute>
</xsl:if>
@@ -92,13 +115,21 @@
<div class="pure-control-group">
<xsl:if test="config_data/dim_1">
<label
for="field_responsible_code"><xsl:value-of select="config_data/dim_1" /></label>
- <input name="responsible_code" type="text"
id="field_responsible_code" value="{account_code_set/responsible_code}"
maxlength='6' class="pure-u-1" />
+ <input name="responsible_code" type="text"
id="field_responsible_code" value="{account_code_set/responsible_code}"
maxlength='6' class="pure-u-1">
+ <xsl:attribute name="data-validation">
+ <xsl:text>required</xsl:text>
+ </xsl:attribute>
+ </input>
</xsl:if>
</div>
<div class="pure-control-group">
<xsl:if test="config_data/dim_2">
<label for="field_service"><xsl:value-of
select="config_data/dim_2" /></label>
- <input name="service" type="text"
id="field_service" value="{account_code_set/service}" maxlength='8'
class="pure-u-1" />
+ <input name="service" type="text"
id="field_service" value="{account_code_set/service}" maxlength='8'
class="pure-u-1">
+ <xsl:attribute name="data-validation">
+ <xsl:text>required</xsl:text>
+ </xsl:attribute>
+ </input>
</xsl:if>
</div>
<div class="pure-control-group">
@@ -110,7 +141,11 @@
<div class="pure-control-group">
<xsl:if test="config_data/dim_5">
<label
for="field_project_number"><xsl:value-of select="config_data/dim_5" /></label>
- <input name="project_number" type="text"
id="field_project_number" value="{account_code_set/project_number}"
maxlength='12' class="pure-u-1" />
+ <input name="project_number" type="text"
id="field_project_number" value="{account_code_set/project_number}"
maxlength='12' class="pure-u-1">
+ <xsl:attribute name="data-validation">
+ <xsl:text>required</xsl:text>
+ </xsl:attribute>
+ </input>
</xsl:if>
</div>
</div>
Modified: branches/dev-syncromind/booking/templates/base/activity_edit.xsl
===================================================================
--- branches/dev-syncromind/booking/templates/base/activity_edit.xsl
2015-10-21 00:14:30 UTC (rev 14224)
+++ branches/dev-syncromind/booking/templates/base/activity_edit.xsl
2015-10-21 00:20:35 UTC (rev 14225)
@@ -9,6 +9,9 @@
<label for="field_name"><xsl:value-of
select="php:function('lang', 'Activity')"/></label>
<input id="field_name" name="name" type="text">
<xsl:attribute name="value"><xsl:value-of
select="activity/name"/></xsl:attribute>
+ <xsl:attribute name="data-validation">
+ <xsl:text>required</xsl:text>
+ </xsl:attribute>
</input>
</div>
<div class="pure-control-group">
Modified: branches/dev-syncromind/booking/templates/base/activity_new.xsl
===================================================================
--- branches/dev-syncromind/booking/templates/base/activity_new.xsl
2015-10-21 00:14:30 UTC (rev 14224)
+++ branches/dev-syncromind/booking/templates/base/activity_new.xsl
2015-10-21 00:20:35 UTC (rev 14225)
@@ -9,6 +9,9 @@
<label for="field_name"><xsl:value-of
select="php:function('lang', 'Activity')" /></label>
<input id="field_name" name="name" type="text">
<xsl:attribute name="value"><xsl:value-of
select="activity/name"/></xsl:attribute>
+ <xsl:attribute name="data-validation">
+ <xsl:text>required</xsl:text>
+ </xsl:attribute>
</input>
</div>
<div class="pure-control-group">
Modified: branches/dev-syncromind/booking/templates/base/agegroup_edit.xsl
===================================================================
--- branches/dev-syncromind/booking/templates/base/agegroup_edit.xsl
2015-10-21 00:14:30 UTC (rev 14224)
+++ branches/dev-syncromind/booking/templates/base/agegroup_edit.xsl
2015-10-21 00:20:35 UTC (rev 14225)
@@ -5,33 +5,34 @@
<div id="tab-content">
<xsl:value-of disable-output-escaping="yes"
select="resource/tabs"/>
<div id="agegroup_edit" class="booking-container">
- <div class="pure-control-group">
- <label for="field_activity">
- <xsl:value-of
select="php:function('lang', 'Activity')" />
- </label>
- <select name="activity_id"
id="field_activity">
- <xsl:attribute
name="disabled">disabled</xsl:attribute>
-
- <xsl:for-each
select="activities">
- <option>
- <xsl:if
test="selected = 1">
-
<xsl:attribute name="selected">selected</xsl:attribute>
- </xsl:if>
- <xsl:attribute
name="value">
-
<xsl:value-of select="id"/>
- </xsl:attribute>
- <xsl:value-of
select="name"/>
- </option>
- </xsl:for-each>
- </select>
- </div>
-
<div class="pure-control-group">
+ <label for="field_activity">
+ <xsl:value-of select="php:function('lang',
'Activity')" />
+ </label>
+ <select name="activity_id" id="field_activity">
+ <xsl:attribute name="data-validation">
+ <xsl:text>required</xsl:text>
+ </xsl:attribute>
+ <xsl:attribute name="disabled">disabled</xsl:attribute>
+ <xsl:for-each select="activities">
+ <option>
+ <xsl:if test="selected = 1">
+ <xsl:attribute
name="selected">selected</xsl:attribute>
+ </xsl:if>
+ <xsl:attribute name="value">
+ <xsl:value-of select="id"/>
+ </xsl:attribute>
+ <xsl:value-of select="name"/>
+ </option>
+ </xsl:for-each>
+ </select>
+ </div>
+ <div class="pure-control-group">
<label for="field_name"><xsl:value-of
select="php:function('lang', 'Name')" /></label>
<input id="field_name" name="name" type="text">
- <xsl:attribute
name="data-validation">
-
<xsl:text>required</xsl:text>
- </xsl:attribute>
+ <xsl:attribute name="data-validation">
+ <xsl:text>required</xsl:text>
+ </xsl:attribute>
<xsl:attribute name="value"><xsl:value-of
select="resource/name"/></xsl:attribute>
</input>
</div>
@@ -54,7 +55,11 @@
</div>
<div class="pure-control-group">
<label for="field_sort"><xsl:value-of
select="php:function('lang', 'Sort order')" /></label>
- <input id="field_sort" name="sort" type="text"
value="{resource/sort}"/>
+ <input id="field_sort" name="sort" type="text"
value="{resource/sort}">
+ <xsl:attribute name="data-validation">
+ <xsl:text>required</xsl:text>
+ </xsl:attribute>
+ </input>
</div>
<div class="pure-control-group">
<label for="field_description"><xsl:value-of
select="php:function('lang', 'Description')" /></label>
Modified: branches/dev-syncromind/booking/templates/base/agegroup_new.xsl
===================================================================
--- branches/dev-syncromind/booking/templates/base/agegroup_new.xsl
2015-10-21 00:14:30 UTC (rev 14224)
+++ branches/dev-syncromind/booking/templates/base/agegroup_new.xsl
2015-10-21 00:20:35 UTC (rev 14225)
@@ -3,52 +3,54 @@
<form action="" method="POST" class="pure-form pure-form-aligned"
id="form" name="form">
<input type="hidden" name="tab" value=""/>
<div id="tab-content">
- <xsl:variable name="lang_select_activity">
- <xsl:value-of
select="php:function('lang', '-- select an activity --')" />
- </xsl:variable>
-
+ <xsl:variable name="lang_select_activity">
+ <xsl:value-of select="php:function('lang', '-- select an
activity --')" />
+ </xsl:variable>
<xsl:value-of disable-output-escaping="yes"
select="agegroup/tabs"/>
<div id="agegroup_add" class="booking-container">
- <div class="pure-control-group">
- <label for="field_activity">
- <xsl:value-of
select="php:function('lang', 'Activity')" />
- </label>
- <select name="activity_id"
id="field_activity">
- <xsl:attribute
name="data-validation">
-
<xsl:text>required</xsl:text>
- </xsl:attribute>
- <xsl:attribute
name="data-validation-error-msg">
- <xsl:value-of
select="$lang_select_activity" />
- </xsl:attribute>
-
- <option value="">
- <xsl:value-of
select="$lang_select_activity" />
- </option>
- <xsl:for-each
select="activities">
- <option>
- <xsl:if
test="selected = 1">
-
<xsl:attribute name="selected">selected</xsl:attribute>
- </xsl:if>
- <xsl:attribute
name="value">
-
<xsl:value-of select="id"/>
- </xsl:attribute>
- <xsl:value-of
select="name"/>
- </option>
- </xsl:for-each>
- </select>
- </div>
+ <div class="pure-control-group">
+ <label for="field_activity">
+ <xsl:value-of select="php:function('lang',
'Activity')" />
+ </label>
+ <select name="activity_id" id="field_activity">
+ <xsl:attribute name="data-validation">
+ <xsl:text>required</xsl:text>
+ </xsl:attribute>
+ <!--xsl:attribute name="data-validation-error-msg">
+ <xsl:value-of select="$lang_select_activity" />
+ </xsl:attribute-->
+ <option value="">
+ <xsl:value-of select="$lang_select_activity" />
+ </option>
+ <xsl:for-each select="activities">
+ <option>
+ <xsl:if test="selected = 1">
+ <xsl:attribute
name="selected">selected</xsl:attribute>
+ </xsl:if>
+ <xsl:attribute name="value">
+ <xsl:value-of select="id"/>
+ </xsl:attribute>
+ <xsl:value-of select="name"/>
+ </option>
+ </xsl:for-each>
+ </select>
+ </div>
<div class="pure-control-group">
<label for="field_name"><xsl:value-of
select="php:function('lang', 'Name')" /></label>
<input id="field_name" name="name" type="text">
- <xsl:attribute
name="data-validation">
-
<xsl:text>required</xsl:text>
- </xsl:attribute>
+ <xsl:attribute name="data-validation">
+ <xsl:text>required</xsl:text>
+ </xsl:attribute>
<xsl:attribute name="value"><xsl:value-of
select="agegroup/name"/></xsl:attribute>
</input>
</div>
<div class="pure-control-group">
<label for="field_sort"><xsl:value-of
select="php:function('lang', 'Sort order')" /></label>
- <input id="field_sort" name="sort" type="text"
value="{agegroup/sort}"/>
+ <input id="field_sort" name="sort" type="text"
value="{agegroup/sort}">
+ <xsl:attribute name="data-validation">
+ <xsl:text>required</xsl:text>
+ </xsl:attribute>
+ </input>
</div>
<div class="pure-control-group">
<label for="field_description"><xsl:value-of
select="php:function('lang', 'Description')" /></label>
Modified: branches/dev-syncromind/booking/templates/base/allocation_edit.xsl
===================================================================
--- branches/dev-syncromind/booking/templates/base/allocation_edit.xsl
2015-10-21 00:14:30 UTC (rev 14224)
+++ branches/dev-syncromind/booking/templates/base/allocation_edit.xsl
2015-10-21 00:20:35 UTC (rev 14225)
@@ -19,6 +19,9 @@
<xsl:attribute name="value"><xsl:value-of
select="allocation/building_id"/></xsl:attribute>
</input>
<input id="field_building_name" name="building_name"
type="text">
+ <xsl:attribute name="data-validation">
+ <xsl:text>required</xsl:text>
+ </xsl:attribute>
<xsl:attribute name="value"><xsl:value-of
select="allocation/building_name"/></xsl:attribute>
</input>
<div id="building_container"></div>
@@ -54,6 +57,9 @@
<xsl:attribute name="value"><xsl:value-of
select="allocation/organization_id"/></xsl:attribute>
</input>
<input id="field_org_name" name="organization_name"
type="text">
+ <xsl:attribute name="data-validate">
+ <xsl:text>required</xsl:text>
+ </xsl:attribute>
<xsl:attribute name="value"><xsl:value-of
select="allocation/organization_name"/></xsl:attribute>
</input>
<div id="org_container"></div>
@@ -73,6 +79,9 @@
<div class="pure-control-group">
<label for="field_cost"><xsl:value-of
select="php:function('lang', 'Cost')" /></label>
<input id="field_cost" name="cost" type="text">
+ <xsl:attributes name="data-validation">
+ <xsl:text>required</xsl:text>
+ </xsl:attributes>
<xsl:attribute name="value"><xsl:value-of
select="allocation/cost"/></xsl:attribute>
</input>
</div>
Modified: branches/dev-syncromind/booking/templates/base/allocation_new.xsl
===================================================================
--- branches/dev-syncromind/booking/templates/base/allocation_new.xsl
2015-10-21 00:14:30 UTC (rev 14224)
+++ branches/dev-syncromind/booking/templates/base/allocation_new.xsl
2015-10-21 00:20:35 UTC (rev 14225)
@@ -15,6 +15,9 @@
<xsl:attribute name="value"><xsl:value-of
select="allocation/building_id"/></xsl:attribute>
</input>
<input id="field_building_name" name="building_name"
type="text">
+ <xsl:attribute name="data-validation">
+ <xsl:text>required</xsl:text>
+ </xsl:attribute>
<xsl:attribute name="value"><xsl:value-of
select="allocation/building_name"/></xsl:attribute>
</input>
</div>
@@ -24,6 +27,9 @@
<xsl:attribute name="value"><xsl:value-of
select="allocation/organization_id"/></xsl:attribute>
</input>
<input id="field_org_name" name="organization_name"
type="text">
+ <xsl:attribute name="data-validation">
+ <xsl:text>required</xsl:text>
+ </xsl:attribute>
<xsl:attribute name="value"><xsl:value-of
select="allocation/organization_name"/></xsl:attribute>
</input>
</div>
@@ -132,6 +138,9 @@
<div class="pure-control-group">
<label for="field_cost"><xsl:value-of
select="php:function('lang', 'Cost')" /></label>
<input id="field_cost" name="cost" type="text">
+ <xsl:attributes name="data-validation">
+ <xsl:text>required</xsl:text>
+ </xsl:attributes>
<xsl:attribute name="value"><xsl:value-of
select="allocation/cost"/></xsl:attribute>
</input>
</div>
Modified: branches/dev-syncromind/booking/templates/base/application_edit.xsl
===================================================================
--- branches/dev-syncromind/booking/templates/base/application_edit.xsl
2015-10-21 00:14:30 UTC (rev 14224)
+++ branches/dev-syncromind/booking/templates/base/application_edit.xsl
2015-10-21 00:20:35 UTC (rev 14225)
@@ -40,6 +40,9 @@
<div class="pure-control-group">
<label for="field_activity"><xsl:value-of
select="php:function('lang', 'Activity')" /></label>
<select name="activity_id" id="field_activity"
class="pure-u-1 pure-u-sm-1-2 pure-u-lg-1-3">
+ <xsl:attribute name="data-validation">
+ <xsl:text>required</xsl:text>
+ </xsl:attribute>
<option value=""><xsl:value-of
select="php:function('lang', '-- select an activity --')" /></option>
<xsl:for-each select="activities">
<option>
@@ -54,7 +57,12 @@
</div>
<div class="pure-control-group">
<label for="field_description"><xsl:value-of
select="php:function('lang', 'Description')" /></label>
- <textarea id="field_description"
class="full-width pure-u-1 pure-u-sm-1-2 pure-u-lg-1-3"
name="description"><xsl:value-of select="application/description"/></textarea>
+ <textarea id="field_description"
class="full-width pure-u-1 pure-u-sm-1-2 pure-u-lg-1-3" name="description">
+ <xsl:attribute name="data-validation">
+ <xsl:text>required</xsl:text>
+ </xsl:attribute>
+ <xsl:value-of
select="application/description"/>
+ </textarea>
</div>
<div class="pure-control-group">
<label for="field_equipment"><xsl:value-of
select="php:function('lang', 'Equipment')" /></label>
@@ -73,6 +81,9 @@
<xsl:attribute name="value"><xsl:value-of
select="application/building_id"/></xsl:attribute>
</input>
<input id="field_building_name"
name="building_name" type="text">
+ <xsl:attribute name="data-validation">
+ <xsl:text>required</xsl:text>
+ </xsl:attribute>
<xsl:attribute name="value"><xsl:value-of
select="application/building_name"/></xsl:attribute>
</input>
<div id="building_container"></div>
@@ -201,12 +212,18 @@
<div class="pure-control-group">
<label for="field_contact_name"><xsl:value-of
select="php:function('lang', 'Name')" /></label>
<input id="field_contact_name"
name="contact_name" type="text" class="pure-u-1 pure-u-sm-1-2 pure-u-md-1">
+ <xsl:attribute name="data-validation">
+ <xsl:text>required</xsl:text>
+ </xsl:attribute>
<xsl:attribute name="value"><xsl:value-of
select="application/contact_name"/></xsl:attribute>
</input>
</div>
<div class="pure-control-group">
<label for="field_contact_email"><xsl:value-of
select="php:function('lang', 'Email')" /></label>
<input id="field_contact_email"
name="contact_email" type="text" class="pure-u-1 pure-u-sm-1-2 pure-u-md-1">
+ <xsl:attribute name="data-validation">
+ <xsl:text>required</xsl:text>
+ </xsl:attribute>
<xsl:attribute name="value"><xsl:value-of
select="application/contact_email"/></xsl:attribute>
</input>
</div>
Modified: branches/dev-syncromind/booking/templates/base/application_new.xsl
===================================================================
--- branches/dev-syncromind/booking/templates/base/application_new.xsl
2015-10-21 00:14:30 UTC (rev 14224)
+++ branches/dev-syncromind/booking/templates/base/application_new.xsl
2015-10-21 00:20:35 UTC (rev 14225)
@@ -24,6 +24,9 @@
<p><xsl:value-of
select="config/application_activities"/></p>
</xsl:if>
<select name="activity_id" id="field_activity"
class="pure-input-1">
+ <xsl:attributes name="date-validtion">
+ <xsl:text>required</xsl:text>
+ </xsl:attributes>
<option value=""><xsl:value-of
select="php:function('lang', '-- select an activity --')" /></option>
<xsl:for-each select="activities">
<option>
@@ -41,7 +44,12 @@
<xsl:if test="config/application_description">
<p><xsl:value-of
select="config/application_description"/></p>
</xsl:if>
- <textarea rows="6" id="field_description"
class="full-width pure-input-1" name="description"><xsl:value-of
select="application/description"/></textarea>
+ <textarea rows="6" id="field_description"
class="full-width pure-input-1" name="description">
+ <xsl:attribute name="data-validation">
+ <xsl:text>required</xsl:text>
+ </xsl:attribute>
+ <xsl:value-of
select="application/description"/>
+ </textarea>
</div>
</fieldset>
</div>
@@ -102,6 +110,9 @@
</input>
<input id="field_building_name"
class="pure-input-1" name="building_name" type="text">
<xsl:attribute name="value"><xsl:value-of
select="application/building_name"/></xsl:attribute>
+ <xsl:attribute name="data-validation">
+ <xsl:text>required</xsl:text>
+ </xsl:attribute>
</input>
<div id="building_container"></div>
</div>
@@ -223,12 +234,18 @@
</xsl:if>
<label for="field_contact_name"><xsl:value-of
select="php:function('lang', 'Name')" /></label>
<input id="field_contact_name"
class="pure-input-1" name="contact_name" type="text">
+ <xsl:attribute name="data-validation">
+ <xsl:text>required</xsl:text>
+ </xsl:attribute>
<xsl:attribute name="value"><xsl:value-of
select="application/contact_name"/></xsl:attribute>
</input>
</div>
<div class="pure-control-group">
<label for="field_contact_email"><xsl:value-of
select="php:function('lang', 'E-mail address')" /></label>
<input id="field_contact_email"
class="pure-input-1" name="contact_email" type="text">
+ <xsl:attribute name="data-validation">
+ <xsl:text>required</xsl:text>
+ </xsl:attribute>
<xsl:attribute name="value"><xsl:value-of
select="application/contact_email"/></xsl:attribute>
</input>
</div>
Modified: branches/dev-syncromind/booking/templates/base/audience_edit.xsl
===================================================================
--- branches/dev-syncromind/booking/templates/base/audience_edit.xsl
2015-10-21 00:14:30 UTC (rev 14224)
+++ branches/dev-syncromind/booking/templates/base/audience_edit.xsl
2015-10-21 00:20:35 UTC (rev 14225)
@@ -6,33 +6,34 @@
<xsl:value-of disable-output-escaping="yes"
select="audience/tabs"/>
<div id="audience_edit" class="booking-container">
<fieldset>
- <div class="pure-control-group">
- <label for="field_activity">
- <xsl:value-of
select="php:function('lang', 'Activity')" />
- </label>
- <select name="activity_id"
id="field_activity">
- <xsl:attribute
name="disabled">disabled</xsl:attribute>
-
- <xsl:for-each
select="activities">
- <option>
- <xsl:if
test="selected = 1">
-
<xsl:attribute name="selected">selected</xsl:attribute>
- </xsl:if>
- <xsl:attribute
name="value">
-
<xsl:value-of select="id"/>
- </xsl:attribute>
- <xsl:value-of
select="name"/>
- </option>
- </xsl:for-each>
- </select>
- </div>
-
<div class="pure-control-group">
+ <label for="field_activity">
+ <xsl:value-of select="php:function('lang',
'Activity')" />
+ </label>
+ <select name="activity_id" id="field_activity">
+ <xsl:attribute
name="disabled">disabled</xsl:attribute>
+ <xsl:attribute name="data-validation">
+ <xsl:text>required</xsl:text>
+ </xsl:attribute>
+ <xsl:for-each select="activities">
+ <option>
+ <xsl:if test="selected = 1">
+ <xsl:attribute
name="selected">selected</xsl:attribute>
+ </xsl:if>
+ <xsl:attribute name="value">
+ <xsl:value-of select="id"/>
+ </xsl:attribute>
+ <xsl:value-of select="name"/>
+ </option>
+ </xsl:for-each>
+ </select>
+ </div>
+ <div class="pure-control-group">
<label for="field_name"><xsl:value-of
select="php:function('lang', 'Target audience')" /></label>
<input id="field_name" name="name" type="text">
- <xsl:attribute
name="data-validation">
-
<xsl:text>required</xsl:text>
- </xsl:attribute>
+ <xsl:attribute name="data-validation">
+ <xsl:text>required</xsl:text>
+ </xsl:attribute>
<xsl:attribute name="value"><xsl:value-of
select="audience/name"/></xsl:attribute>
</input>
</div>
@@ -55,11 +56,18 @@
</div>
<div class="pure-control-group">
<label for="field_sort"><xsl:value-of
select="php:function('lang', 'Sort order')" /></label>
- <input id="field_sort" name="sort" type="text"
value="{audience/sort}"/>
+ <input id="field_sort" name="sort" type="text"
value="{audience/sort}">
+ <xsl:attribute name="data-validation">
+ <xsl:text>required</xsl:text>
+ </xsl:attribute>
+ </input>
</div>
<div class="pure-control-group">
<label for="field_description"><xsl:value-of
select="php:function('lang', 'Description')" /></label>
<textarea rows="5" id="field_description"
name="description">
+ <xsl:attribute name="data-validation">
+ <xsl:text>required</xsl:text>
+ </xsl:attribute>
<xsl:value-of select="audience/description"/>
</textarea>
</div>
Modified: branches/dev-syncromind/booking/templates/base/audience_new.xsl
===================================================================
--- branches/dev-syncromind/booking/templates/base/audience_new.xsl
2015-10-21 00:14:30 UTC (rev 14224)
+++ branches/dev-syncromind/booking/templates/base/audience_new.xsl
2015-10-21 00:20:35 UTC (rev 14225)
@@ -2,52 +2,55 @@
<xsl:call-template name="msgbox"/>
<form action="" method="POST" class="pure-form pure-form-aligned"
id="form" name="form">
<input type="hidden" name="tab" value=""/>
- <xsl:variable name="lang_select_activity">
- <xsl:value-of select="php:function('lang', '--
select an activity --')" />
- </xsl:variable>
- <div id="tab-content">
+ <xsl:variable name="lang_select_activity">
+ <xsl:value-of select="php:function('lang', '-- select an activity
--')" />
+ </xsl:variable>
+ <div id="tab-content">
<xsl:value-of disable-output-escaping="yes"
select="audience/tabs"/>
<div id="audience_add" class="booking-container">
- <div class="pure-control-group">
- <label for="field_activity">
- <xsl:value-of
select="php:function('lang', 'Activity')" />
- </label>
- <select name="activity_id"
id="field_activity">
- <xsl:attribute
name="data-validation">
-
<xsl:text>required</xsl:text>
- </xsl:attribute>
- <xsl:attribute
name="data-validation-error-msg">
- <xsl:value-of
select="$lang_select_activity" />
- </xsl:attribute>
-
- <option value="">
- <xsl:value-of
select="$lang_select_activity" />
- </option>
- <xsl:for-each
select="activities">
- <option>
- <xsl:if
test="selected = 1">
-
<xsl:attribute name="selected">selected</xsl:attribute>
- </xsl:if>
- <xsl:attribute
name="value">
-
<xsl:value-of select="id"/>
- </xsl:attribute>
- <xsl:value-of
select="name"/>
- </option>
- </xsl:for-each>
- </select>
- </div>
+ <div class="pure-control-group">
+ <label for="field_activity">
+ <xsl:value-of select="php:function('lang',
'Activity')" />
+ </label>
+ <select name="activity_id" id="field_activity">
+ <xsl:attribute name="data-validation">
+ <xsl:text>required</xsl:text>
+ </xsl:attribute>
+ <!--xsl:attribute name="data-validation-error-msg">
+ <xsl:value-of select="$lang_select_activity" />
+ </xsl:attribute-->
+ <option value="">
+ <xsl:value-of select="$lang_select_activity" />
+ </option>
+ <xsl:for-each select="activities">
+ <option>
+ <xsl:if test="selected = 1">
+ <xsl:attribute
name="selected">selected</xsl:attribute>
+ </xsl:if>
+ <xsl:attribute name="value">
+ <xsl:value-of select="id"/>
+ </xsl:attribute>
+ <xsl:value-of select="name"/>
+ </option>
+ </xsl:for-each>
+ </select>
+ </div>
<div class="pure-control-group">
<label for="field_name"><xsl:value-of
select="php:function('lang', 'Target audience')" /></label>
<input id="field_name" name="name" type="text">
- <xsl:attribute
name="data-validation">
-
<xsl:text>required</xsl:text>
- </xsl:attribute>
+ <xsl:attribute name="data-validation">
+ <xsl:text>required</xsl:text>
+ </xsl:attribute>
<xsl:attribute name="value"><xsl:value-of
select="audience/name"/></xsl:attribute>
</input>
</div>
<div class="pure-control-group">
<label for="field_sort"><xsl:value-of
select="php:function('lang', 'Sort order')" /></label>
- <input id="field_sort" name="sort" type="text"
value="{audience/sort}"/>
+ <input id="field_sort" name="sort" type="text"
value="{audience/sort}">
+ <xsl:attribute name="data-validation">
+ <xsl:text>required</xsl:text>
+ </xsl:attribute>
+ </input>
</div>
<div class="pure-control-group">
<label for="field_description"><xsl:value-of
select="php:function('lang', 'Description')" /></label>
Modified: branches/dev-syncromind/booking/templates/base/booking_new.xsl
===================================================================
--- branches/dev-syncromind/booking/templates/base/booking_new.xsl
2015-10-21 00:14:30 UTC (rev 14224)
+++ branches/dev-syncromind/booking/templates/base/booking_new.xsl
2015-10-21 00:20:35 UTC (rev 14225)
@@ -16,6 +16,9 @@
<div class="pure-control-group">
<label style="width:auto;"
for="field_activity"><xsl:value-of select="php:function('lang', 'Activity')"
/></label>
<select name="activity_id" id="field_activity">
+ <xsl:attribute name="data-validation">
+ <xsl:text>required</xsl:text>
+ </xsl:attribute>
<option value=""><xsl:value-of
select="php:function('lang', '-- select an activity --')" /></option>
<xsl:for-each select="activities">
<option>
@@ -39,6 +42,9 @@
<xsl:attribute name="value"><xsl:value-of
select="booking/building_id"/></xsl:attribute>
</input>
<input id="field_building_name"
name="building_name" type="text" class="pure-u-1 pure-u-sm-1-2 pure-u-md-1">
+ <xsl:attribute name="data-validation">
+ <xsl:text>required</xsl:text>
+ </xsl:attribute>
<xsl:attribute name="value"><xsl:value-of
select="booking/building_name"/></xsl:attribute>
</input>
</div>
@@ -70,24 +76,20 @@
<div class="pure-control-group">
<label><xsl:value-of
select="php:function('lang', 'From')"/></label>
<input class="datetime pure-input-2-3"
id="start_date" name="from_" type="text" style="display:inline-block;">
+ <xsl:attribute name="data-validate">
+ <xsl:text>required</xsl:text>
+ </xsl:attribute>
<xsl:attribute name="value"><xsl:value-of
select="booking/from_"/></xsl:attribute>
</input>
- <!--div class="datetime-picker"-->
- <!--input id="field_from" name="from_"
type="text">
- <xsl:attribute name="value"><xsl:value-of
select="booking/from_"/></xsl:attribute>
- </input-->
- <!--/div-->
</div>
<div class="pure-control-group">
<label><xsl:value-of
select="php:function('lang', 'To')"/></label>
<input class="datetime pure-input-2-3"
id="end_date" name="to_" type="text" style="display:inline-block;">
+ <xsl:attribute name="data-validate">
+ <xsl:text>required</xsl:text>
+ </xsl:attribute>
<xsl:attribute name="value"><xsl:value-of
select="booking/to_"/></xsl:attribute>
</input>
- <!--div class="datetime-picker"-->
- <!--input id="field_to" name="to_" type="text">
- <xsl:attribute name="value"><xsl:value-of
select="booking/to_"/></xsl:attribute>
- </input-->
- <!--/div-->
</div>
<div class="pure-control-group">
<label><xsl:value-of
select="php:function('lang', 'Cost')" /></label>
Modified:
branches/dev-syncromind/booking/templates/base/completed_reservation_edit.xsl
===================================================================
---
branches/dev-syncromind/booking/templates/base/completed_reservation_edit.xsl
2015-10-21 00:14:30 UTC (rev 14224)
+++
branches/dev-syncromind/booking/templates/base/completed_reservation_edit.xsl
2015-10-21 00:20:35 UTC (rev 14225)
@@ -13,11 +13,18 @@
<div class="pure-u-1 pure-u-sm-1-2 pure-u-md-1-3
pure-u-lg-1-4">
<div class="pure-control-group">
<label for="field_cost"><xsl:value-of
select="php:function('lang', 'Cost')" /></label>
- <input id="field_cost" name="cost" type="text"
value="{reservation/cost}" class="pure-u-1"/>
+ <input id="field_cost" name="cost" type="text"
value="{reservation/cost}" class="pure-u-1">
+ <xsl:attribute name="data-validation">
+ <xsl:text>required</xsl:text>
+ </xsl:attribute>
+ </input>
</div>
<div class="pure-control-group">
<label for="field_customer_type"><xsl:value-of
select="php:function('lang', 'Customer Type')" /></label>
<select name='customer_type'
id='field_customer_type' class="pure-u-1">
+ <xsl:attribute name="data-validation">
+ <xsl:text>required</xsl:text>
+ </xsl:attribute>
<option value=''><xsl:value-of
select="php:function('lang', 'Select...')" /></option>
<xsl:for-each
select="reservation/customer_types/*">
<option>
@@ -43,7 +50,11 @@
</div>
<div class="pure-control-group">
<label for="field_description"><xsl:value-of
select="php:function('lang', 'Description')" /></label>
- <input type='text' id='field_description'
name="description" value='{reservation/description}' maxlength='60'
class="pure-u-1"/>
+ <input type='text' id='field_description'
name="description" value='{reservation/description}' maxlength='60'
class="pure-u-1">
+ <xsl:attribute name="data-validation">
+ <xsl:text>required</xsl:text>
+ </xsl:attribute>
+ </input>
</div>
</div>
</div>
Modified: branches/dev-syncromind/booking/templates/base/documentation_form.xsl
===================================================================
--- branches/dev-syncromind/booking/templates/base/documentation_form.xsl
2015-10-21 00:14:30 UTC (rev 14224)
+++ branches/dev-syncromind/booking/templates/base/documentation_form.xsl
2015-10-21 00:20:35 UTC (rev 14225)
@@ -31,6 +31,9 @@
<div class="pure-control-group">
<label for="field_name"><xsl:value-of
select="php:function('lang', 'Document')" /></label>
<input name="name" id='field_name'>
+ <xsl:attribute name="data-validation">
+ <xsl:text>required</xsl:text>
+ </xsl:attribute>
<xsl:attribute name="value"><xsl:value-of
select="document/name"/></xsl:attribute>
<xsl:attribute name="type">
<xsl:choose>
@@ -51,6 +54,9 @@
<div class="pure-control-group">
<label for="field_category"><xsl:value-of
select="php:function('lang', 'Category')" /></label>
<select name='category' id='field_category'>
+ <xsl:attribute name="data-validation">
+ <xsl:text>required</xsl:text>
+ </xsl:attribute>
<option value=''><xsl:value-of
select="php:function('lang', 'Select Category...')" /></option>
<xsl:for-each
select="document/document_types/*">
<option>
Modified: branches/dev-syncromind/booking/templates/base/email_index.xsl
===================================================================
--- branches/dev-syncromind/booking/templates/base/email_index.xsl
2015-10-21 00:14:30 UTC (rev 14224)
+++ branches/dev-syncromind/booking/templates/base/email_index.xsl
2015-10-21 00:20:35 UTC (rev 14225)
@@ -13,6 +13,9 @@
</input>
<input id="field_building_name" name="building_name"
type="text">
<xsl:attribute name="value"><xsl:value-of
select="building/name"/></xsl:attribute>
+ <xsl:attribute name="data-validation">
+ <xsl:text>required</xsl:text>
+ </xsl:attribute>
</input>
</div>
<div class="pure-control-group">
@@ -23,11 +26,19 @@
<label for="field_mailsubject"><xsl:value-of
select="php:function('lang', 'Mail subject')" /></label>
<input type="text" id="field_mailsubject"
name="mailsubject" class="full-width">
<xsl:attribute name="value"><xsl:value-of
select="mailsubject"/></xsl:attribute>
+ <xsl:attribute name="data-validation">
+ <xsl:text>required</xsl:text>
+ </xsl:attribute>
</input>
</div>
<div class="pure-control-group">
<label for="field_mailbody"><xsl:value-of
select="php:function('lang', 'Mail body')" /></label>
- <textarea id="field_mailbody" name="mailbody"
class="full-width"><xsl:value-of select="mailbody"/></textarea>
+ <textarea id="field_mailbody" name="mailbody"
class="full-width">
+ <xsl:attribute name="data-validation">
+ <xsl:text>required</xsl:text>
+ </xsl:attribute>
+ <xsl:value-of select="mailbody"/>
+ </textarea>
</div>
</div>
</div>
Modified:
branches/dev-syncromind/booking/templates/base/permission_root_form.xsl
===================================================================
--- branches/dev-syncromind/booking/templates/base/permission_root_form.xsl
2015-10-21 00:14:30 UTC (rev 14224)
+++ branches/dev-syncromind/booking/templates/base/permission_root_form.xsl
2015-10-21 00:20:35 UTC (rev 14225)
@@ -22,6 +22,9 @@
<div style="display:inline-block;max-width:80%;">
<span><xsl:value-of select="node()"/></span><br />
<select name='role' id='field_role'>
+ <xsl:attribute name="data-validation">
+ <xsl:text>required</xsl:text>
+ </xsl:attribute>
<option value=''><xsl:value-of
select="php:function('lang', 'Select role...')" /></option>
<xsl:for-each select="available_roles/*">
<option>
@@ -42,6 +45,9 @@
</label>
<input id="field_subject_name" name="subject_name"
type="text">
<xsl:attribute name="value"><xsl:value-of
select="subject_name"/></xsl:attribute>
+ <xsl:attribute name="data-validation">
+ <xsl:text>required</xsl:text>
+ </xsl:attribute>
</input>
<input id="field_subject_id" name="subject_id"
type="hidden">
<xsl:attribute name="value"><xsl:value-of
select="subject_id"/></xsl:attribute>
Modified: branches/dev-syncromind/booking/templates/base/report_participants.xsl
===================================================================
--- branches/dev-syncromind/booking/templates/base/report_participants.xsl
2015-10-21 00:14:30 UTC (rev 14224)
+++ branches/dev-syncromind/booking/templates/base/report_participants.xsl
2015-10-21 00:20:35 UTC (rev 14225)
@@ -5,35 +5,25 @@
<xsl:value-of disable-output-escaping="yes" select="data/tabs"/>
<div id="report_part">
<div class="pure-control-group">
- <!--dt><label for="field_from"><xsl:value-of
select="php:function('lang', 'From')" /></label></dt>
- <dd>
- <div class="date-picker">
- <input id="field_from" name="from" type="text">
- <xsl:attribute name="value"><xsl:value-of
select="from"/></xsl:attribute>
- </input>
- </div>
- </dd-->
<label for="start_date">
<h4><xsl:value-of select="php:function('lang',
'From')" /></h4>
</label>
<input class="datetime" id="from" name="from" type="text">
<xsl:attribute name="value"><xsl:value-of
select="from"/></xsl:attribute>
+ <xsl:attribute name="data-validation">
+ <xsl:text>required</xsl:text>
+ </xsl:attribute>
</input>
</div>
<div class="pure-control-group">
- <!--dt><label for="field_to"><xsl:value-of
select="php:function('lang', 'To')" /></label></dt>
- <dd>
- <div class="date-picker">
- <input id="field_to" name="to" type="text">
- <xsl:attribute name="value"><xsl:value-of
select="to"/></xsl:attribute>
- </input>
- </div>
- </dd-->
<label for="end_date">
<h4><xsl:value-of select="php:function('lang', 'To')"
/></h4>
</label>
<input class="datetime" id="to" name="to" type="text">
<xsl:attribute name="value"><xsl:value-of
select="to"/></xsl:attribute>
+ <xsl:attribute name="data-validation">
+ <xsl:text>required</xsl:text>
+ </xsl:attribute>
</input>
</div>
<div class="pure-control-group">
@@ -41,6 +31,9 @@
<h4><xsl:value-of select="php:function('lang',
'buildings')"/></h4>
</label>
<select id="field_building" name="building[]" size="10"
multiple="multiple" class="full-width">
+ <xsl:attribute name="data-validation">
+ <xsl:text>required</xsl:text>
+ </xsl:attribute>
<xsl:for-each select="buildings">
<xsl:sort select="name"/>
<option>
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Fmsystem-commits] [14225] validations,
Saul <=