SlideShare une entreprise Scribd logo
1  sur  31
Télécharger pour lire hors ligne
25 -27 April, 2014 http://camp2014.drupal.dn.ua
Drupal and Outer
Space
Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org
A Game Changer for the Geospatial Data Market
Dauria Aerospace
develops new ways in
building low cost
satellites, thus reducing
costs for earth
observation data
drastically.
Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org
The Game Changer for the Geospatial Data Market
Affordable Geo data allow
small businesses to pioneer
new business models.
Example:
Low cost parcel monitoring
service for local farmers
Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org
Building Satellites with Smartphone Technology
Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org
Building Lightweight Satellites
Conventional Satellite
New Satellite
Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org
Less Expensive Launches
Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org
We need a Configurable Product with a Map
Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org
Commerce's Standard Handling of Product Variations
http://demo.commerceguys.com/ck/tops/guy-short-sleeve-tee
Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org
The Customizable Products Module
As the ancient
Drupal Proverb goes:
There's a module
for that
Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org
Configuration of References
Content Type for the
Product Display
Configuration:
Add Product Reference
Set „Product Types that
can be referenced“
to Product Type;
Set „Add to Cart Line
Item Type“
to Line Item Type
Product Display Node
Configuration:
Set „Product Reference“
to Product
Product
Configuration:
Set „Referenced by“
to Product
Display Node
Product Type
Configuration:
Set „Default Reference“
to Content Type
Line Item Type
Configuration:
Set „Add to Cart Line
Item Type“
to itself (self reference!)
Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org
Validating User Inputs
Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org
Validating User Inputs
Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org
Validating User Inputs
Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org
Validating User Inputs
Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org
Validating User Inputs
Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org
Utilizing PostGIS
PostGIS extends PostgreSQL Databases with geodetic functio
Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org
The PostGIS Module integrates this Functions into Drupal
function validate() {
$geo = is_null($this->wkt) ? $this->geometry : $this->wkt;
try {
$result = db_query("SELECT ST_GeometryType(:geo), ST_IsValid(:geo), ST_IsValidReason(:geo) as reason",
array(':geo' => $geo))->fetchAssoc();
// Return reason if geometry is not valid.
if (!$result['st_isvalid']) {
return array(
'error' => 'postgis_unparsable',
'message' => t('Not a valid geometry: @reason.', array('@reason' => $result['reason'])),
);
}
...
}
catch (PDOException $e) {
// TODO: catch only WKT parse errors.
return array(
'error' => 'postgis_unparsable',
'message' => t('Unable to parse WKT: ' . $geo),
);
}
}
class PostgisGeometry {
...
class PostgisGeometry {
...
Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org
But the PostGIS Module has some Weaknesses
/**
* Calculates diffrence to a given geometry.
*
* @param PostgisGeometry $geometry
* Geometry which this instance will be compared to.
*
* @return PostgisGeometry
* Geometry of diffrence.
*/
function diff($geometry) {
...
$geo_diff = db_query("SELECT ST_Union(ST_Difference(:geo_a, :geo_b), ST_Difference(:geo_b, :geo_a))",
array(':geo_a' => $geo_a, ':geo_b' => $geo_b))->fetchField();
$geo_type = db_query("SELECT GeometryType(:geo_diff)",
array(':geo_diff' => $geo_diff))->fetchField();
$diff = new PostgisGeometry($geo_type, $this->srid);
$diff->fromGeometry($geo_diff);
return $diff;
}
- Some important geodetic functions are not implemented
- Error handling is inconsistent
Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org
Extending and Overwriting the PostGIS Module
class PostgisGeometries extends PostgisGeometry {
...
function intersects($geometry) {
if ((get_class($geometry) !== 'postgis_geometry') && (get_class($geometry) !== 'PostgisGeometries')) {
throw new PostgisGeometryException('not postgis_geometry');
}
try {
$geo_a = $this->getText();
if(stripos($geo_a,'GEOMETRYCOLLECTION(' ) === 0) {
$geo_a = substr(strstr($geo_a, '('),1, -1);
}
$geo_b = $geometry->getText();
if(stripos($geo_b,'GEOMETRYCOLLECTION(' ) === 0) {
$geo_b = substr(strstr($geo_b, '('),1, -1);
}
$intersects = db_query("SELECT ST_Intersects(text :geo_a, text :geo_b)",
array(':geo_a' => $geo_a, ':geo_b' => $geo_b))->fetchField();
return $intersects;
}
catch (PDOException $e) {
throw new PostgisGeometryException( $e->getMessage( ) , (int)$e->getCode( ) );
}
}
Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org
Writing a module to validate the AOI and calculate the price
function water_quality_form_alter(&$form, &$form_state, $form_id) {
...
$coverage_region_comparison->transform($aoi->getSrid());
$coverage_region_comparison->dump();
$intersects_google_projection = $coverage_region_comparison->intersects($aoi_comparison);
if ($intersects_google_projection){
// Convert aoi to srid of the region.
$aoi_comparison->transform($coverage_region['region']->getSrid());
$aoi_comparison->dump();
// check if the aoi intersects with the region. This needs to be
// done in the SRID of the coverage region for accuracy.
$within = $aoi_comparison->within($coverage_region['region']);
if ($within){
...
...
$form['line_item_fields']['field_line_item_map'][LANGUAGE_NONE][0]['wkt']['#element_validate'][] =
'water_quality_aoi_validate';
...
function water_quality_aoi_validate($element, &$form_state) {
...
Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org
The Open Layers Editor has some Bugs
What it
should
deliver
POLYGON((1066993.16984217 4873953.49407963,
1340943.47921804 5392502.29411237,
1810572.58092165 5382718.35450175,
1979345.539345157 5106322.0602720035,
1849708.33939679 4776114.09813913,
1066993.16984217 4873953.49407963))
GEOMETRYCOLLECTION(
POLYGON((1066993.16984217 4873953.49407963,
1340943.47921804 5392502.29411237,
1810572.58092165 5382718.35450175,
1979345.539345157 5106322.0602720035,
1849708.33939679 4776114.09813913,
1066993.16984217 4873953.49407963)),
POINT(1203968.324530105 5133227.894096),
POINT(1575758.0300698448 5387610.32430706),
POINT(1894959.0601334036 5244520.207386877),
POINT(1914526.9393709735 4941218.079205567),
POINT(1458350.75461948 4825033.79610938),
POINT(1066993.16984217 4873953.49407963),
POINT(1340943.47921804 5392502.29411237),
POINT(1810572.58092165 5382718.35450175),
POINT(1979345.539345157 5106322.0602720035),
POINT(1849708.33939679 4776114.09813913))
What it
sometime
s
delivers
GEOMETRYCOLLECTION()
Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org
The Open Layers Editor has some Bugs
Caching and the
Open Layers
Editor
have an awkward
relationship
Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org
The Open Layers Editor has some Bugs
function water_quality_subscription_type_validate($element, &$form_state) {
if(!isset($element['#value']) || empty($element['#value'])){
drupal_rebuild_form($form_state['build_info']['form_id'], $form_state);
}
}
function eomap_eula_validate($element, &$form_state) {
if(!isset($element['#value']) || empty($element['#value'])){
drupal_rebuild_form($form_state['build_info']['form_id'], $form_state);
form_set_error('field_line_item_map', t('Agreement to Product EULA must be checked'));
}
}
function water_quality_form_alter(&$form, &$form_state, $form_id) {
...
...
$form['line_item_fields']['field_subscription_type'][LANGUAGE_NONE]['#element_validate'][] =
'water_quality_subscription_type_validate';
$form['line_item_fields']['field_eomap_eula_agreement'][LANGUAGE_NONE]['#element_validate'][] =
'eomap_eula_validate';
...
...
}
Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org
The Open Layers Editor has some Bugs
Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org
The Open Layers Editor has some Bugs
Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org
The Open Layers Editor has some Bugs
$form_state['no_cache'] = TRUE;
if (isset($form_state['values']['line_item_fields']['field_line_item_map'][LANGUAGE_NONE][0]['wkt'])){
$form_state['input']['line_item_fields']['field_line_item_map'][LANGUAGE_NONE][0]['wkt'] =
$form_state['values']['line_item_fields']['field_line_item_map'][LANGUAGE_NONE][0]['wkt'];
} else {
if (isset($form_state['input']['line_item_fields']['field_line_item_map'][LANGUAGE_NONE][0]['wkt'])){
$wkt = $form_state['input']['line_item_fields']['field_line_item_map'][LANGUAGE_NONE][0]['wkt'];
if(stripos($wkt, 'POINT') !== false){
$wkt = substr(strstr($wkt, '('), 1,(stripos($wkt, ',POINT') - stripos($wkt, '(') -1));
}
$form['line_item_fields']['field_line_item_map'][LANGUAGE_NONE][0]['wkt']['#value'] = $wkt;
}
}
Some form fields mysteriously loose
their value and need to be refilled
Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org
Wrapping it up: Placing the Geo 
Data Product in the Shopping Cart
A Rule
overwrites
the line item
price with
the calculated
price
Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org
Wrapping it up: Placing the Geo 
Data Product in the Shopping Cart
Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org
What it's all about...
You can build some such thing
and even more sophisticated
sites with Drupal modules
and a little coding!
Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org
Any Questions?
Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org
The End
Спасибі за увагу
Спасибо за внимание
Danke für Ihre Aufmerksamkeit
Thank you for your attention
Translated to a select
choice of languages
observed on planet Earth:

Contenu connexe

Similaire à Drupal and Outer space - Martin Mayer

Moose: how to solve real problems without reading code
Moose: how to solve real problems without reading codeMoose: how to solve real problems without reading code
Moose: how to solve real problems without reading codeTudor Girba
 
Platform agnostic information systems development
Platform agnostic information systems developmentPlatform agnostic information systems development
Platform agnostic information systems developmentMark Jayson Fuentes
 
(PHPers Wrocław #5) How to write valuable unit test?
(PHPers Wrocław #5) How to write valuable unit test?(PHPers Wrocław #5) How to write valuable unit test?
(PHPers Wrocław #5) How to write valuable unit test?RST Software Masters
 
Best Practices with ODI : Flexibility
Best Practices with ODI : FlexibilityBest Practices with ODI : Flexibility
Best Practices with ODI : FlexibilityGurcan Orhan
 
Gmaps Railscamp2008
Gmaps Railscamp2008Gmaps Railscamp2008
Gmaps Railscamp2008xilinus
 
Why is crud a bad idea - focus on real scenarios
Why is crud a bad idea - focus on real scenariosWhy is crud a bad idea - focus on real scenarios
Why is crud a bad idea - focus on real scenariosDivante
 
Machine Learning Model for M.S admissions
Machine Learning Model for M.S admissionsMachine Learning Model for M.S admissions
Machine Learning Model for M.S admissionsOmkar Rane
 
Running Intelligent Applications inside a Database: Deep Learning with Python...
Running Intelligent Applications inside a Database: Deep Learning with Python...Running Intelligent Applications inside a Database: Deep Learning with Python...
Running Intelligent Applications inside a Database: Deep Learning with Python...Miguel González-Fierro
 
Saving Gaia with GeoDjango
Saving Gaia with GeoDjangoSaving Gaia with GeoDjango
Saving Gaia with GeoDjangoCalvin Cheng
 
Informatics Practices (new) solution CBSE 2021, Compartment, improvement ex...
Informatics Practices (new) solution CBSE  2021, Compartment,  improvement ex...Informatics Practices (new) solution CBSE  2021, Compartment,  improvement ex...
Informatics Practices (new) solution CBSE 2021, Compartment, improvement ex...FarhanAhmade
 
Mobility insights at Swisscom - Understanding collective mobility in Switzerland
Mobility insights at Swisscom - Understanding collective mobility in SwitzerlandMobility insights at Swisscom - Understanding collective mobility in Switzerland
Mobility insights at Swisscom - Understanding collective mobility in SwitzerlandFrançois Garillot
 
Spark Summit EU talk by Francois Garillot and Mohamed Kafsi
Spark Summit EU talk by Francois Garillot and Mohamed KafsiSpark Summit EU talk by Francois Garillot and Mohamed Kafsi
Spark Summit EU talk by Francois Garillot and Mohamed KafsiSpark Summit
 
Building Large jQuery Applications
Building Large jQuery ApplicationsBuilding Large jQuery Applications
Building Large jQuery ApplicationsRebecca Murphey
 
Scaling Up: How Switching to Apache Spark Improved Performance, Realizability...
Scaling Up: How Switching to Apache Spark Improved Performance, Realizability...Scaling Up: How Switching to Apache Spark Improved Performance, Realizability...
Scaling Up: How Switching to Apache Spark Improved Performance, Realizability...Databricks
 
Scaling up data science applications
Scaling up data science applicationsScaling up data science applications
Scaling up data science applicationsKexin Xie
 
Computer Science CS Project Matrix CBSE Class 12th XII .pdf
Computer Science CS Project Matrix CBSE Class 12th XII .pdfComputer Science CS Project Matrix CBSE Class 12th XII .pdf
Computer Science CS Project Matrix CBSE Class 12th XII .pdfPranavAnil9
 

Similaire à Drupal and Outer space - Martin Mayer (20)

Moose: how to solve real problems without reading code
Moose: how to solve real problems without reading codeMoose: how to solve real problems without reading code
Moose: how to solve real problems without reading code
 
Platform agnostic information systems development
Platform agnostic information systems developmentPlatform agnostic information systems development
Platform agnostic information systems development
 
(PHPers Wrocław #5) How to write valuable unit test?
(PHPers Wrocław #5) How to write valuable unit test?(PHPers Wrocław #5) How to write valuable unit test?
(PHPers Wrocław #5) How to write valuable unit test?
 
Best Practices with ODI : Flexibility
Best Practices with ODI : FlexibilityBest Practices with ODI : Flexibility
Best Practices with ODI : Flexibility
 
Deep learning
Deep learningDeep learning
Deep learning
 
Gmaps Railscamp2008
Gmaps Railscamp2008Gmaps Railscamp2008
Gmaps Railscamp2008
 
Android swedroid
Android swedroidAndroid swedroid
Android swedroid
 
Why is crud a bad idea - focus on real scenarios
Why is crud a bad idea - focus on real scenariosWhy is crud a bad idea - focus on real scenarios
Why is crud a bad idea - focus on real scenarios
 
Machine Learning Model for M.S admissions
Machine Learning Model for M.S admissionsMachine Learning Model for M.S admissions
Machine Learning Model for M.S admissions
 
Running Intelligent Applications inside a Database: Deep Learning with Python...
Running Intelligent Applications inside a Database: Deep Learning with Python...Running Intelligent Applications inside a Database: Deep Learning with Python...
Running Intelligent Applications inside a Database: Deep Learning with Python...
 
Saving Gaia with GeoDjango
Saving Gaia with GeoDjangoSaving Gaia with GeoDjango
Saving Gaia with GeoDjango
 
Angular Workshop_Sarajevo2
Angular Workshop_Sarajevo2Angular Workshop_Sarajevo2
Angular Workshop_Sarajevo2
 
Informatics Practices (new) solution CBSE 2021, Compartment, improvement ex...
Informatics Practices (new) solution CBSE  2021, Compartment,  improvement ex...Informatics Practices (new) solution CBSE  2021, Compartment,  improvement ex...
Informatics Practices (new) solution CBSE 2021, Compartment, improvement ex...
 
Mobility insights at Swisscom - Understanding collective mobility in Switzerland
Mobility insights at Swisscom - Understanding collective mobility in SwitzerlandMobility insights at Swisscom - Understanding collective mobility in Switzerland
Mobility insights at Swisscom - Understanding collective mobility in Switzerland
 
Spark Summit EU talk by Francois Garillot and Mohamed Kafsi
Spark Summit EU talk by Francois Garillot and Mohamed KafsiSpark Summit EU talk by Francois Garillot and Mohamed Kafsi
Spark Summit EU talk by Francois Garillot and Mohamed Kafsi
 
Building Large jQuery Applications
Building Large jQuery ApplicationsBuilding Large jQuery Applications
Building Large jQuery Applications
 
Seeing Like Software
Seeing Like SoftwareSeeing Like Software
Seeing Like Software
 
Scaling Up: How Switching to Apache Spark Improved Performance, Realizability...
Scaling Up: How Switching to Apache Spark Improved Performance, Realizability...Scaling Up: How Switching to Apache Spark Improved Performance, Realizability...
Scaling Up: How Switching to Apache Spark Improved Performance, Realizability...
 
Scaling up data science applications
Scaling up data science applicationsScaling up data science applications
Scaling up data science applications
 
Computer Science CS Project Matrix CBSE Class 12th XII .pdf
Computer Science CS Project Matrix CBSE Class 12th XII .pdfComputer Science CS Project Matrix CBSE Class 12th XII .pdf
Computer Science CS Project Matrix CBSE Class 12th XII .pdf
 

Plus de DrupalCampDN

Drupal - Changing the Web by Connecting Open Minds - Josef Dabernig
Drupal - Changing the Web by Connecting Open Minds - Josef DabernigDrupal - Changing the Web by Connecting Open Minds - Josef Dabernig
Drupal - Changing the Web by Connecting Open Minds - Josef DabernigDrupalCampDN
 
Dependency Injection in Drupal 8 - Стадник АндрейQweqwe
Dependency Injection in Drupal 8 - Стадник АндрейQweqweDependency Injection in Drupal 8 - Стадник АндрейQweqwe
Dependency Injection in Drupal 8 - Стадник АндрейQweqweDrupalCampDN
 
Our AWS Cloud Journey - Andrew Boag
Our AWS Cloud Journey - Andrew BoagOur AWS Cloud Journey - Andrew Boag
Our AWS Cloud Journey - Andrew BoagDrupalCampDN
 
Guzzle in Drupal 8 and as a REST client - Артем Мирошник
Guzzle in Drupal 8 and as a REST client - Артем МирошникGuzzle in Drupal 8 and as a REST client - Артем Мирошник
Guzzle in Drupal 8 and as a REST client - Артем МирошникDrupalCampDN
 
Blocks & Layouts in D7 - Josef Dabernig
Blocks & Layouts in D7 - Josef DabernigBlocks & Layouts in D7 - Josef Dabernig
Blocks & Layouts in D7 - Josef DabernigDrupalCampDN
 
CKEditor в Drupal: тонкая настройка и кастомизация - Osman Seferov
CKEditor в Drupal: тонкая настройка и кастомизация - Osman SeferovCKEditor в Drupal: тонкая настройка и кастомизация - Osman Seferov
CKEditor в Drupal: тонкая настройка и кастомизация - Osman SeferovDrupalCampDN
 
Drush - use full power - Alexander Schedrov
Drush - use full power - Alexander SchedrovDrush - use full power - Alexander Schedrov
Drush - use full power - Alexander SchedrovDrupalCampDN
 
Это Drupal, %username%! - Андрей Черноус
Это Drupal, %username%! - Андрей ЧерноусЭто Drupal, %username%! - Андрей Черноус
Это Drupal, %username%! - Андрей ЧерноусDrupalCampDN
 
Migrate - new way site upgrade
Migrate - new way site upgradeMigrate - new way site upgrade
Migrate - new way site upgradeDrupalCampDN
 
Caching on highload Drupal site - Alexander Shumenko
Caching on highload Drupal site - Alexander ShumenkoCaching on highload Drupal site - Alexander Shumenko
Caching on highload Drupal site - Alexander ShumenkoDrupalCampDN
 
Rich Text in Drupal - Вадим Валуев
Rich Text in Drupal - Вадим ВалуевRich Text in Drupal - Вадим Валуев
Rich Text in Drupal - Вадим ВалуевDrupalCampDN
 
Panels как философия - Alexander Danilenko
Panels как философия - Alexander DanilenkoPanels как философия - Alexander Danilenko
Panels как философия - Alexander DanilenkoDrupalCampDN
 
Twig internals - Maksym MoskvychevTwig internals maksym moskvychev
Twig internals - Maksym MoskvychevTwig internals   maksym moskvychevTwig internals - Maksym MoskvychevTwig internals   maksym moskvychev
Twig internals - Maksym MoskvychevTwig internals maksym moskvychevDrupalCampDN
 
Boost your theming skills - Artem Shymko
Boost your theming skills - Artem ShymkoBoost your theming skills - Artem Shymko
Boost your theming skills - Artem ShymkoDrupalCampDN
 
Continious integration - Иван Лещёв
Continious integration - Иван ЛещёвContinious integration - Иван Лещёв
Continious integration - Иван ЛещёвDrupalCampDN
 
Rules - Yaroslav Doroshuk
Rules - Yaroslav DoroshukRules - Yaroslav Doroshuk
Rules - Yaroslav DoroshukDrupalCampDN
 
Системы управления взаимоотношениями с клиентами. Drupal CRM Core. - Вадим Ми...
Системы управления взаимоотношениями с клиентами. Drupal CRM Core. - Вадим Ми...Системы управления взаимоотношениями с клиентами. Drupal CRM Core. - Вадим Ми...
Системы управления взаимоотношениями с клиентами. Drupal CRM Core. - Вадим Ми...DrupalCampDN
 
Render API - Pavel Makhrinsky
Render API - Pavel MakhrinskyRender API - Pavel Makhrinsky
Render API - Pavel MakhrinskyDrupalCampDN
 
Темизация Drupal7. Omega theme. Александр Даниленко.
Темизация Drupal7. Omega theme. Александр Даниленко.Темизация Drupal7. Omega theme. Александр Даниленко.
Темизация Drupal7. Omega theme. Александр Даниленко.DrupalCampDN
 
Управление отображением материалов с помощью Display Suite. Илья Станкевич.
Управление отображением материалов с помощью Display Suite. Илья Станкевич.Управление отображением материалов с помощью Display Suite. Илья Станкевич.
Управление отображением материалов с помощью Display Suite. Илья Станкевич.DrupalCampDN
 

Plus de DrupalCampDN (20)

Drupal - Changing the Web by Connecting Open Minds - Josef Dabernig
Drupal - Changing the Web by Connecting Open Minds - Josef DabernigDrupal - Changing the Web by Connecting Open Minds - Josef Dabernig
Drupal - Changing the Web by Connecting Open Minds - Josef Dabernig
 
Dependency Injection in Drupal 8 - Стадник АндрейQweqwe
Dependency Injection in Drupal 8 - Стадник АндрейQweqweDependency Injection in Drupal 8 - Стадник АндрейQweqwe
Dependency Injection in Drupal 8 - Стадник АндрейQweqwe
 
Our AWS Cloud Journey - Andrew Boag
Our AWS Cloud Journey - Andrew BoagOur AWS Cloud Journey - Andrew Boag
Our AWS Cloud Journey - Andrew Boag
 
Guzzle in Drupal 8 and as a REST client - Артем Мирошник
Guzzle in Drupal 8 and as a REST client - Артем МирошникGuzzle in Drupal 8 and as a REST client - Артем Мирошник
Guzzle in Drupal 8 and as a REST client - Артем Мирошник
 
Blocks & Layouts in D7 - Josef Dabernig
Blocks & Layouts in D7 - Josef DabernigBlocks & Layouts in D7 - Josef Dabernig
Blocks & Layouts in D7 - Josef Dabernig
 
CKEditor в Drupal: тонкая настройка и кастомизация - Osman Seferov
CKEditor в Drupal: тонкая настройка и кастомизация - Osman SeferovCKEditor в Drupal: тонкая настройка и кастомизация - Osman Seferov
CKEditor в Drupal: тонкая настройка и кастомизация - Osman Seferov
 
Drush - use full power - Alexander Schedrov
Drush - use full power - Alexander SchedrovDrush - use full power - Alexander Schedrov
Drush - use full power - Alexander Schedrov
 
Это Drupal, %username%! - Андрей Черноус
Это Drupal, %username%! - Андрей ЧерноусЭто Drupal, %username%! - Андрей Черноус
Это Drupal, %username%! - Андрей Черноус
 
Migrate - new way site upgrade
Migrate - new way site upgradeMigrate - new way site upgrade
Migrate - new way site upgrade
 
Caching on highload Drupal site - Alexander Shumenko
Caching on highload Drupal site - Alexander ShumenkoCaching on highload Drupal site - Alexander Shumenko
Caching on highload Drupal site - Alexander Shumenko
 
Rich Text in Drupal - Вадим Валуев
Rich Text in Drupal - Вадим ВалуевRich Text in Drupal - Вадим Валуев
Rich Text in Drupal - Вадим Валуев
 
Panels как философия - Alexander Danilenko
Panels как философия - Alexander DanilenkoPanels как философия - Alexander Danilenko
Panels как философия - Alexander Danilenko
 
Twig internals - Maksym MoskvychevTwig internals maksym moskvychev
Twig internals - Maksym MoskvychevTwig internals   maksym moskvychevTwig internals - Maksym MoskvychevTwig internals   maksym moskvychev
Twig internals - Maksym MoskvychevTwig internals maksym moskvychev
 
Boost your theming skills - Artem Shymko
Boost your theming skills - Artem ShymkoBoost your theming skills - Artem Shymko
Boost your theming skills - Artem Shymko
 
Continious integration - Иван Лещёв
Continious integration - Иван ЛещёвContinious integration - Иван Лещёв
Continious integration - Иван Лещёв
 
Rules - Yaroslav Doroshuk
Rules - Yaroslav DoroshukRules - Yaroslav Doroshuk
Rules - Yaroslav Doroshuk
 
Системы управления взаимоотношениями с клиентами. Drupal CRM Core. - Вадим Ми...
Системы управления взаимоотношениями с клиентами. Drupal CRM Core. - Вадим Ми...Системы управления взаимоотношениями с клиентами. Drupal CRM Core. - Вадим Ми...
Системы управления взаимоотношениями с клиентами. Drupal CRM Core. - Вадим Ми...
 
Render API - Pavel Makhrinsky
Render API - Pavel MakhrinskyRender API - Pavel Makhrinsky
Render API - Pavel Makhrinsky
 
Темизация Drupal7. Omega theme. Александр Даниленко.
Темизация Drupal7. Omega theme. Александр Даниленко.Темизация Drupal7. Omega theme. Александр Даниленко.
Темизация Drupal7. Omega theme. Александр Даниленко.
 
Управление отображением материалов с помощью Display Suite. Илья Станкевич.
Управление отображением материалов с помощью Display Suite. Илья Станкевич.Управление отображением материалов с помощью Display Suite. Илья Станкевич.
Управление отображением материалов с помощью Display Suite. Илья Станкевич.
 

Dernier

Packaging the Monolith - PHP Tek 2024 (Breaking it down one bite at a time)
Packaging the Monolith - PHP Tek 2024 (Breaking it down one bite at a time)Packaging the Monolith - PHP Tek 2024 (Breaking it down one bite at a time)
Packaging the Monolith - PHP Tek 2024 (Breaking it down one bite at a time)Dana Luther
 
『澳洲文凭』买拉筹伯大学毕业证书成绩单办理澳洲LTU文凭学位证书
『澳洲文凭』买拉筹伯大学毕业证书成绩单办理澳洲LTU文凭学位证书『澳洲文凭』买拉筹伯大学毕业证书成绩单办理澳洲LTU文凭学位证书
『澳洲文凭』买拉筹伯大学毕业证书成绩单办理澳洲LTU文凭学位证书rnrncn29
 
Film cover research (1).pptxsdasdasdasdasdasa
Film cover research (1).pptxsdasdasdasdasdasaFilm cover research (1).pptxsdasdasdasdasdasa
Film cover research (1).pptxsdasdasdasdasdasa494f574xmv
 
办理多伦多大学毕业证成绩单|购买加拿大UTSG文凭证书
办理多伦多大学毕业证成绩单|购买加拿大UTSG文凭证书办理多伦多大学毕业证成绩单|购买加拿大UTSG文凭证书
办理多伦多大学毕业证成绩单|购买加拿大UTSG文凭证书zdzoqco
 
Call Girls In The Ocean Pearl Retreat Hotel New Delhi 9873777170
Call Girls In The Ocean Pearl Retreat Hotel New Delhi 9873777170Call Girls In The Ocean Pearl Retreat Hotel New Delhi 9873777170
Call Girls In The Ocean Pearl Retreat Hotel New Delhi 9873777170Sonam Pathan
 
定制(Management毕业证书)新加坡管理大学毕业证成绩单原版一比一
定制(Management毕业证书)新加坡管理大学毕业证成绩单原版一比一定制(Management毕业证书)新加坡管理大学毕业证成绩单原版一比一
定制(Management毕业证书)新加坡管理大学毕业证成绩单原版一比一Fs
 
Font Performance - NYC WebPerf Meetup April '24
Font Performance - NYC WebPerf Meetup April '24Font Performance - NYC WebPerf Meetup April '24
Font Performance - NYC WebPerf Meetup April '24Paul Calvano
 
Blepharitis inflammation of eyelid symptoms cause everything included along w...
Blepharitis inflammation of eyelid symptoms cause everything included along w...Blepharitis inflammation of eyelid symptoms cause everything included along w...
Blepharitis inflammation of eyelid symptoms cause everything included along w...Excelmac1
 
定制(UAL学位证)英国伦敦艺术大学毕业证成绩单原版一比一
定制(UAL学位证)英国伦敦艺术大学毕业证成绩单原版一比一定制(UAL学位证)英国伦敦艺术大学毕业证成绩单原版一比一
定制(UAL学位证)英国伦敦艺术大学毕业证成绩单原版一比一Fs
 
Magic exist by Marta Loveguard - presentation.pptx
Magic exist by Marta Loveguard - presentation.pptxMagic exist by Marta Loveguard - presentation.pptx
Magic exist by Marta Loveguard - presentation.pptxMartaLoveguard
 
Elevate Your Business with Our IT Expertise in New Orleans
Elevate Your Business with Our IT Expertise in New OrleansElevate Your Business with Our IT Expertise in New Orleans
Elevate Your Business with Our IT Expertise in New Orleanscorenetworkseo
 
Top 10 Interactive Website Design Trends in 2024.pptx
Top 10 Interactive Website Design Trends in 2024.pptxTop 10 Interactive Website Design Trends in 2024.pptx
Top 10 Interactive Website Design Trends in 2024.pptxDyna Gilbert
 
Contact Rya Baby for Call Girls New Delhi
Contact Rya Baby for Call Girls New DelhiContact Rya Baby for Call Girls New Delhi
Contact Rya Baby for Call Girls New Delhimiss dipika
 
A Good Girl's Guide to Murder (A Good Girl's Guide to Murder, #1)
A Good Girl's Guide to Murder (A Good Girl's Guide to Murder, #1)A Good Girl's Guide to Murder (A Good Girl's Guide to Murder, #1)
A Good Girl's Guide to Murder (A Good Girl's Guide to Murder, #1)Christopher H Felton
 
定制(AUT毕业证书)新西兰奥克兰理工大学毕业证成绩单原版一比一
定制(AUT毕业证书)新西兰奥克兰理工大学毕业证成绩单原版一比一定制(AUT毕业证书)新西兰奥克兰理工大学毕业证成绩单原版一比一
定制(AUT毕业证书)新西兰奥克兰理工大学毕业证成绩单原版一比一Fs
 
Intellectual property rightsand its types.pptx
Intellectual property rightsand its types.pptxIntellectual property rightsand its types.pptx
Intellectual property rightsand its types.pptxBipin Adhikari
 
『澳洲文凭』买詹姆士库克大学毕业证书成绩单办理澳洲JCU文凭学位证书
『澳洲文凭』买詹姆士库克大学毕业证书成绩单办理澳洲JCU文凭学位证书『澳洲文凭』买詹姆士库克大学毕业证书成绩单办理澳洲JCU文凭学位证书
『澳洲文凭』买詹姆士库克大学毕业证书成绩单办理澳洲JCU文凭学位证书rnrncn29
 
办理(UofR毕业证书)罗切斯特大学毕业证成绩单原版一比一
办理(UofR毕业证书)罗切斯特大学毕业证成绩单原版一比一办理(UofR毕业证书)罗切斯特大学毕业证成绩单原版一比一
办理(UofR毕业证书)罗切斯特大学毕业证成绩单原版一比一z xss
 

Dernier (20)

Packaging the Monolith - PHP Tek 2024 (Breaking it down one bite at a time)
Packaging the Monolith - PHP Tek 2024 (Breaking it down one bite at a time)Packaging the Monolith - PHP Tek 2024 (Breaking it down one bite at a time)
Packaging the Monolith - PHP Tek 2024 (Breaking it down one bite at a time)
 
Model Call Girl in Jamuna Vihar Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in  Jamuna Vihar Delhi reach out to us at 🔝9953056974🔝Model Call Girl in  Jamuna Vihar Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Jamuna Vihar Delhi reach out to us at 🔝9953056974🔝
 
『澳洲文凭』买拉筹伯大学毕业证书成绩单办理澳洲LTU文凭学位证书
『澳洲文凭』买拉筹伯大学毕业证书成绩单办理澳洲LTU文凭学位证书『澳洲文凭』买拉筹伯大学毕业证书成绩单办理澳洲LTU文凭学位证书
『澳洲文凭』买拉筹伯大学毕业证书成绩单办理澳洲LTU文凭学位证书
 
Film cover research (1).pptxsdasdasdasdasdasa
Film cover research (1).pptxsdasdasdasdasdasaFilm cover research (1).pptxsdasdasdasdasdasa
Film cover research (1).pptxsdasdasdasdasdasa
 
办理多伦多大学毕业证成绩单|购买加拿大UTSG文凭证书
办理多伦多大学毕业证成绩单|购买加拿大UTSG文凭证书办理多伦多大学毕业证成绩单|购买加拿大UTSG文凭证书
办理多伦多大学毕业证成绩单|购买加拿大UTSG文凭证书
 
Call Girls In The Ocean Pearl Retreat Hotel New Delhi 9873777170
Call Girls In The Ocean Pearl Retreat Hotel New Delhi 9873777170Call Girls In The Ocean Pearl Retreat Hotel New Delhi 9873777170
Call Girls In The Ocean Pearl Retreat Hotel New Delhi 9873777170
 
定制(Management毕业证书)新加坡管理大学毕业证成绩单原版一比一
定制(Management毕业证书)新加坡管理大学毕业证成绩单原版一比一定制(Management毕业证书)新加坡管理大学毕业证成绩单原版一比一
定制(Management毕业证书)新加坡管理大学毕业证成绩单原版一比一
 
Font Performance - NYC WebPerf Meetup April '24
Font Performance - NYC WebPerf Meetup April '24Font Performance - NYC WebPerf Meetup April '24
Font Performance - NYC WebPerf Meetup April '24
 
Blepharitis inflammation of eyelid symptoms cause everything included along w...
Blepharitis inflammation of eyelid symptoms cause everything included along w...Blepharitis inflammation of eyelid symptoms cause everything included along w...
Blepharitis inflammation of eyelid symptoms cause everything included along w...
 
定制(UAL学位证)英国伦敦艺术大学毕业证成绩单原版一比一
定制(UAL学位证)英国伦敦艺术大学毕业证成绩单原版一比一定制(UAL学位证)英国伦敦艺术大学毕业证成绩单原版一比一
定制(UAL学位证)英国伦敦艺术大学毕业证成绩单原版一比一
 
Magic exist by Marta Loveguard - presentation.pptx
Magic exist by Marta Loveguard - presentation.pptxMagic exist by Marta Loveguard - presentation.pptx
Magic exist by Marta Loveguard - presentation.pptx
 
Elevate Your Business with Our IT Expertise in New Orleans
Elevate Your Business with Our IT Expertise in New OrleansElevate Your Business with Our IT Expertise in New Orleans
Elevate Your Business with Our IT Expertise in New Orleans
 
Top 10 Interactive Website Design Trends in 2024.pptx
Top 10 Interactive Website Design Trends in 2024.pptxTop 10 Interactive Website Design Trends in 2024.pptx
Top 10 Interactive Website Design Trends in 2024.pptx
 
Contact Rya Baby for Call Girls New Delhi
Contact Rya Baby for Call Girls New DelhiContact Rya Baby for Call Girls New Delhi
Contact Rya Baby for Call Girls New Delhi
 
A Good Girl's Guide to Murder (A Good Girl's Guide to Murder, #1)
A Good Girl's Guide to Murder (A Good Girl's Guide to Murder, #1)A Good Girl's Guide to Murder (A Good Girl's Guide to Murder, #1)
A Good Girl's Guide to Murder (A Good Girl's Guide to Murder, #1)
 
定制(AUT毕业证书)新西兰奥克兰理工大学毕业证成绩单原版一比一
定制(AUT毕业证书)新西兰奥克兰理工大学毕业证成绩单原版一比一定制(AUT毕业证书)新西兰奥克兰理工大学毕业证成绩单原版一比一
定制(AUT毕业证书)新西兰奥克兰理工大学毕业证成绩单原版一比一
 
Intellectual property rightsand its types.pptx
Intellectual property rightsand its types.pptxIntellectual property rightsand its types.pptx
Intellectual property rightsand its types.pptx
 
『澳洲文凭』买詹姆士库克大学毕业证书成绩单办理澳洲JCU文凭学位证书
『澳洲文凭』买詹姆士库克大学毕业证书成绩单办理澳洲JCU文凭学位证书『澳洲文凭』买詹姆士库克大学毕业证书成绩单办理澳洲JCU文凭学位证书
『澳洲文凭』买詹姆士库克大学毕业证书成绩单办理澳洲JCU文凭学位证书
 
办理(UofR毕业证书)罗切斯特大学毕业证成绩单原版一比一
办理(UofR毕业证书)罗切斯特大学毕业证成绩单原版一比一办理(UofR毕业证书)罗切斯特大学毕业证成绩单原版一比一
办理(UofR毕业证书)罗切斯特大学毕业证成绩单原版一比一
 
Hot Sexy call girls in Rk Puram 🔝 9953056974 🔝 Delhi escort Service
Hot Sexy call girls in  Rk Puram 🔝 9953056974 🔝 Delhi escort ServiceHot Sexy call girls in  Rk Puram 🔝 9953056974 🔝 Delhi escort Service
Hot Sexy call girls in Rk Puram 🔝 9953056974 🔝 Delhi escort Service
 

Drupal and Outer space - Martin Mayer

  • 1. 25 -27 April, 2014 http://camp2014.drupal.dn.ua Drupal and Outer Space
  • 2. Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org A Game Changer for the Geospatial Data Market Dauria Aerospace develops new ways in building low cost satellites, thus reducing costs for earth observation data drastically.
  • 3. Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org The Game Changer for the Geospatial Data Market Affordable Geo data allow small businesses to pioneer new business models. Example: Low cost parcel monitoring service for local farmers
  • 4. Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org Building Satellites with Smartphone Technology
  • 5. Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org Building Lightweight Satellites Conventional Satellite New Satellite
  • 6. Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org Less Expensive Launches
  • 7. Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org We need a Configurable Product with a Map
  • 8. Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org Commerce's Standard Handling of Product Variations http://demo.commerceguys.com/ck/tops/guy-short-sleeve-tee
  • 9. Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org The Customizable Products Module As the ancient Drupal Proverb goes: There's a module for that
  • 10. Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org Configuration of References Content Type for the Product Display Configuration: Add Product Reference Set „Product Types that can be referenced“ to Product Type; Set „Add to Cart Line Item Type“ to Line Item Type Product Display Node Configuration: Set „Product Reference“ to Product Product Configuration: Set „Referenced by“ to Product Display Node Product Type Configuration: Set „Default Reference“ to Content Type Line Item Type Configuration: Set „Add to Cart Line Item Type“ to itself (self reference!)
  • 11. Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org Validating User Inputs
  • 12. Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org Validating User Inputs
  • 13. Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org Validating User Inputs
  • 14. Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org Validating User Inputs
  • 15. Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org Validating User Inputs
  • 16. Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org Utilizing PostGIS PostGIS extends PostgreSQL Databases with geodetic functio
  • 17. Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org The PostGIS Module integrates this Functions into Drupal function validate() { $geo = is_null($this->wkt) ? $this->geometry : $this->wkt; try { $result = db_query("SELECT ST_GeometryType(:geo), ST_IsValid(:geo), ST_IsValidReason(:geo) as reason", array(':geo' => $geo))->fetchAssoc(); // Return reason if geometry is not valid. if (!$result['st_isvalid']) { return array( 'error' => 'postgis_unparsable', 'message' => t('Not a valid geometry: @reason.', array('@reason' => $result['reason'])), ); } ... } catch (PDOException $e) { // TODO: catch only WKT parse errors. return array( 'error' => 'postgis_unparsable', 'message' => t('Unable to parse WKT: ' . $geo), ); } } class PostgisGeometry { ... class PostgisGeometry { ...
  • 18. Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org But the PostGIS Module has some Weaknesses /** * Calculates diffrence to a given geometry. * * @param PostgisGeometry $geometry * Geometry which this instance will be compared to. * * @return PostgisGeometry * Geometry of diffrence. */ function diff($geometry) { ... $geo_diff = db_query("SELECT ST_Union(ST_Difference(:geo_a, :geo_b), ST_Difference(:geo_b, :geo_a))", array(':geo_a' => $geo_a, ':geo_b' => $geo_b))->fetchField(); $geo_type = db_query("SELECT GeometryType(:geo_diff)", array(':geo_diff' => $geo_diff))->fetchField(); $diff = new PostgisGeometry($geo_type, $this->srid); $diff->fromGeometry($geo_diff); return $diff; } - Some important geodetic functions are not implemented - Error handling is inconsistent
  • 19. Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org Extending and Overwriting the PostGIS Module class PostgisGeometries extends PostgisGeometry { ... function intersects($geometry) { if ((get_class($geometry) !== 'postgis_geometry') && (get_class($geometry) !== 'PostgisGeometries')) { throw new PostgisGeometryException('not postgis_geometry'); } try { $geo_a = $this->getText(); if(stripos($geo_a,'GEOMETRYCOLLECTION(' ) === 0) { $geo_a = substr(strstr($geo_a, '('),1, -1); } $geo_b = $geometry->getText(); if(stripos($geo_b,'GEOMETRYCOLLECTION(' ) === 0) { $geo_b = substr(strstr($geo_b, '('),1, -1); } $intersects = db_query("SELECT ST_Intersects(text :geo_a, text :geo_b)", array(':geo_a' => $geo_a, ':geo_b' => $geo_b))->fetchField(); return $intersects; } catch (PDOException $e) { throw new PostgisGeometryException( $e->getMessage( ) , (int)$e->getCode( ) ); } }
  • 20. Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org Writing a module to validate the AOI and calculate the price function water_quality_form_alter(&$form, &$form_state, $form_id) { ... $coverage_region_comparison->transform($aoi->getSrid()); $coverage_region_comparison->dump(); $intersects_google_projection = $coverage_region_comparison->intersects($aoi_comparison); if ($intersects_google_projection){ // Convert aoi to srid of the region. $aoi_comparison->transform($coverage_region['region']->getSrid()); $aoi_comparison->dump(); // check if the aoi intersects with the region. This needs to be // done in the SRID of the coverage region for accuracy. $within = $aoi_comparison->within($coverage_region['region']); if ($within){ ... ... $form['line_item_fields']['field_line_item_map'][LANGUAGE_NONE][0]['wkt']['#element_validate'][] = 'water_quality_aoi_validate'; ... function water_quality_aoi_validate($element, &$form_state) { ...
  • 21. Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org The Open Layers Editor has some Bugs What it should deliver POLYGON((1066993.16984217 4873953.49407963, 1340943.47921804 5392502.29411237, 1810572.58092165 5382718.35450175, 1979345.539345157 5106322.0602720035, 1849708.33939679 4776114.09813913, 1066993.16984217 4873953.49407963)) GEOMETRYCOLLECTION( POLYGON((1066993.16984217 4873953.49407963, 1340943.47921804 5392502.29411237, 1810572.58092165 5382718.35450175, 1979345.539345157 5106322.0602720035, 1849708.33939679 4776114.09813913, 1066993.16984217 4873953.49407963)), POINT(1203968.324530105 5133227.894096), POINT(1575758.0300698448 5387610.32430706), POINT(1894959.0601334036 5244520.207386877), POINT(1914526.9393709735 4941218.079205567), POINT(1458350.75461948 4825033.79610938), POINT(1066993.16984217 4873953.49407963), POINT(1340943.47921804 5392502.29411237), POINT(1810572.58092165 5382718.35450175), POINT(1979345.539345157 5106322.0602720035), POINT(1849708.33939679 4776114.09813913)) What it sometime s delivers GEOMETRYCOLLECTION()
  • 22. Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org The Open Layers Editor has some Bugs Caching and the Open Layers Editor have an awkward relationship
  • 23. Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org The Open Layers Editor has some Bugs function water_quality_subscription_type_validate($element, &$form_state) { if(!isset($element['#value']) || empty($element['#value'])){ drupal_rebuild_form($form_state['build_info']['form_id'], $form_state); } } function eomap_eula_validate($element, &$form_state) { if(!isset($element['#value']) || empty($element['#value'])){ drupal_rebuild_form($form_state['build_info']['form_id'], $form_state); form_set_error('field_line_item_map', t('Agreement to Product EULA must be checked')); } } function water_quality_form_alter(&$form, &$form_state, $form_id) { ... ... $form['line_item_fields']['field_subscription_type'][LANGUAGE_NONE]['#element_validate'][] = 'water_quality_subscription_type_validate'; $form['line_item_fields']['field_eomap_eula_agreement'][LANGUAGE_NONE]['#element_validate'][] = 'eomap_eula_validate'; ... ... }
  • 24. Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org The Open Layers Editor has some Bugs
  • 25. Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org The Open Layers Editor has some Bugs
  • 26. Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org The Open Layers Editor has some Bugs $form_state['no_cache'] = TRUE; if (isset($form_state['values']['line_item_fields']['field_line_item_map'][LANGUAGE_NONE][0]['wkt'])){ $form_state['input']['line_item_fields']['field_line_item_map'][LANGUAGE_NONE][0]['wkt'] = $form_state['values']['line_item_fields']['field_line_item_map'][LANGUAGE_NONE][0]['wkt']; } else { if (isset($form_state['input']['line_item_fields']['field_line_item_map'][LANGUAGE_NONE][0]['wkt'])){ $wkt = $form_state['input']['line_item_fields']['field_line_item_map'][LANGUAGE_NONE][0]['wkt']; if(stripos($wkt, 'POINT') !== false){ $wkt = substr(strstr($wkt, '('), 1,(stripos($wkt, ',POINT') - stripos($wkt, '(') -1)); } $form['line_item_fields']['field_line_item_map'][LANGUAGE_NONE][0]['wkt']['#value'] = $wkt; } } Some form fields mysteriously loose their value and need to be refilled
  • 27. Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org Wrapping it up: Placing the Geo  Data Product in the Shopping Cart A Rule overwrites the line item price with the calculated price
  • 28. Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org Wrapping it up: Placing the Geo  Data Product in the Shopping Cart
  • 29. Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org What it's all about... You can build some such thing and even more sophisticated sites with Drupal modules and a little coding!
  • 30. Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org Any Questions?
  • 31. Martin Mayer, Diplom Systems Practitioner (Open) info@socialoom.org The End Спасибі за увагу Спасибо за внимание Danke für Ihre Aufmerksamkeit Thank you for your attention Translated to a select choice of languages observed on planet Earth: