summaryrefslogtreecommitdiff
path: root/modules/kalpesh/laboratory
diff options
context:
space:
mode:
Diffstat (limited to 'modules/kalpesh/laboratory')
-rw-r--r--modules/kalpesh/laboratory/composer.json13
-rw-r--r--modules/kalpesh/laboratory/config/install/core.base_field_override.node.laboratories.promote.yml25
-rw-r--r--modules/kalpesh/laboratory/config/install/core.base_field_override.node.laboratories.title.yml20
-rw-r--r--modules/kalpesh/laboratory/config/install/core.entity_form_display.node.laboratories.default.yml122
-rw-r--r--modules/kalpesh/laboratory/config/install/core.entity_view_display.node.laboratories.default.yml202
-rw-r--r--modules/kalpesh/laboratory/config/install/core.entity_view_display.node.laboratories.teaser.yml33
-rw-r--r--modules/kalpesh/laboratory/config/install/field.field.node.laboratories.body.yml24
-rw-r--r--modules/kalpesh/laboratory/config/install/field.field.node.laboratories.field_area.yml21
-rw-r--r--modules/kalpesh/laboratory/config/install/field.field.node.laboratories.field_lab_equipment_cost.yml21
-rw-r--r--modules/kalpesh/laboratory/config/install/field.field.node.laboratories.field_lab_image.yml40
-rw-r--r--modules/kalpesh/laboratory/config/install/field.field.node.laboratories.field_utilisation_of_lab.yml23
-rw-r--r--modules/kalpesh/laboratory/config/install/field.storage.node.field_area.yml23
-rw-r--r--modules/kalpesh/laboratory/config/install/field.storage.node.field_lab_equipment_cost.yml23
-rw-r--r--modules/kalpesh/laboratory/config/install/field.storage.node.field_lab_image.yml32
-rw-r--r--modules/kalpesh/laboratory/config/install/field.storage.node.field_utilisation_of_lab.yml21
-rw-r--r--modules/kalpesh/laboratory/config/install/image.style.laboratory_image_style.yml17
-rw-r--r--modules/kalpesh/laboratory/config/install/node.type.laboratories.yml20
-rw-r--r--modules/kalpesh/laboratory/config/install/views.view.laboratories.yml202
-rw-r--r--modules/kalpesh/laboratory/laboratory.info.yml14
-rw-r--r--modules/kalpesh/laboratory/laboratory.install64
-rw-r--r--modules/kalpesh/laboratory/laboratory.module35
-rw-r--r--modules/kalpesh/laboratory/templates/laboratory.html.twig1
-rw-r--r--modules/kalpesh/laboratory/tests/src/Functional/LoadTest.php46
23 files changed, 1042 insertions, 0 deletions
diff --git a/modules/kalpesh/laboratory/composer.json b/modules/kalpesh/laboratory/composer.json
new file mode 100644
index 0000000..59103d2
--- /dev/null
+++ b/modules/kalpesh/laboratory/composer.json
@@ -0,0 +1,13 @@
+{
+ "name": "laboratory",
+ "type": "drupal-module",
+ "description": "This module store laboratories details",
+ "keywords": [
+ ],
+ "homepage": "https://www.drupal.org/project/laboratory",
+ "minimum-stability": "dev",
+ "support": {
+ "issues": "https://www.drupal.org/project/issues/laboratory",
+ "source": "http://cgit.drupalcode.org/laboratory",
+ },
+}
diff --git a/modules/kalpesh/laboratory/config/install/core.base_field_override.node.laboratories.promote.yml b/modules/kalpesh/laboratory/config/install/core.base_field_override.node.laboratories.promote.yml
new file mode 100644
index 0000000..29e16ca
--- /dev/null
+++ b/modules/kalpesh/laboratory/config/install/core.base_field_override.node.laboratories.promote.yml
@@ -0,0 +1,25 @@
+langcode: en
+status: true
+dependencies:
+ config:
+ - node.type.laboratories
+ enforced:
+ module:
+ - laboratories
+id: node.laboratories.promote
+field_name: promote
+entity_type: node
+bundle: laboratories
+label: 'Promoted to front page'
+description: ''
+required: false
+translatable: true
+default_value:
+ -
+ value: 0
+default_value_callback: ''
+settings:
+ on_label: 'On'
+ off_label: 'Off'
+field_type: boolean
+
diff --git a/modules/kalpesh/laboratory/config/install/core.base_field_override.node.laboratories.title.yml b/modules/kalpesh/laboratory/config/install/core.base_field_override.node.laboratories.title.yml
new file mode 100644
index 0000000..7a98615
--- /dev/null
+++ b/modules/kalpesh/laboratory/config/install/core.base_field_override.node.laboratories.title.yml
@@ -0,0 +1,20 @@
+langcode: en
+status: true
+dependencies:
+ config:
+ - node.type.laboratories
+ enforced:
+ module:
+ - laboratories
+id: node.laboratories.title
+field_name: title
+entity_type: node
+bundle: laboratories
+label: Laboratory
+description: ''
+required: true
+translatable: true
+default_value: { }
+default_value_callback: ''
+settings: { }
+field_type: string
diff --git a/modules/kalpesh/laboratory/config/install/core.entity_form_display.node.laboratories.default.yml b/modules/kalpesh/laboratory/config/install/core.entity_form_display.node.laboratories.default.yml
new file mode 100644
index 0000000..7d48de9
--- /dev/null
+++ b/modules/kalpesh/laboratory/config/install/core.entity_form_display.node.laboratories.default.yml
@@ -0,0 +1,122 @@
+langcode: en
+status: true
+dependencies:
+ config:
+ - field.field.node.laboratories.body
+ - field.field.node.laboratories.field_area
+ - field.field.node.laboratories.field_lab_equipment_cost
+ - field.field.node.laboratories.field_lab_image
+ - field.field.node.laboratories.field_utilisation_of_lab
+ - image.style.thumbnail
+ - node.type.laboratories
+ module:
+ - image
+ - path
+ - text
+ enforced:
+ module:
+ - laboratories
+id: node.laboratories.default
+targetEntityType: node
+bundle: laboratories
+mode: default
+content:
+ body:
+ type: text_textarea_with_summary
+ weight: 11
+ settings:
+ rows: 9
+ summary_rows: 3
+ placeholder: ''
+ third_party_settings: { }
+ region: content
+ created:
+ type: datetime_timestamp
+ weight: 6
+ region: content
+ settings: { }
+ third_party_settings: { }
+ field_area:
+ weight: 1
+ settings:
+ size: 60
+ placeholder: ''
+ third_party_settings: { }
+ type: string_textfield
+ region: content
+ field_lab_equipment_cost:
+ weight: 2
+ settings:
+ size: 60
+ placeholder: ''
+ third_party_settings: { }
+ type: string_textfield
+ region: content
+ field_lab_image:
+ weight: 13
+ settings:
+ progress_indicator: throbber
+ preview_image_style: thumbnail
+ third_party_settings: { }
+ type: image_image
+ region: content
+ field_utilisation_of_lab:
+ weight: 3
+ settings:
+ rows: 5
+ placeholder: ''
+ third_party_settings: { }
+ type: text_textarea
+ region: content
+ langcode:
+ type: language_select
+ weight: 4
+ region: content
+ settings:
+ include_locked: true
+ third_party_settings: { }
+ path:
+ type: path
+ weight: 9
+ region: content
+ settings: { }
+ third_party_settings: { }
+ promote:
+ type: boolean_checkbox
+ settings:
+ display_label: true
+ weight: 7
+ region: content
+ third_party_settings: { }
+ status:
+ type: boolean_checkbox
+ settings:
+ display_label: true
+ weight: 10
+ region: content
+ third_party_settings: { }
+ sticky:
+ type: boolean_checkbox
+ settings:
+ display_label: true
+ weight: 8
+ region: content
+ third_party_settings: { }
+ title:
+ type: string_textfield
+ weight: 0
+ region: content
+ settings:
+ size: 60
+ placeholder: ''
+ third_party_settings: { }
+ uid:
+ type: entity_reference_autocomplete
+ weight: 5
+ settings:
+ match_operator: CONTAINS
+ size: 60
+ placeholder: ''
+ region: content
+ third_party_settings: { }
+hidden: { }
diff --git a/modules/kalpesh/laboratory/config/install/core.entity_view_display.node.laboratories.default.yml b/modules/kalpesh/laboratory/config/install/core.entity_view_display.node.laboratories.default.yml
new file mode 100644
index 0000000..5e9ee22
--- /dev/null
+++ b/modules/kalpesh/laboratory/config/install/core.entity_view_display.node.laboratories.default.yml
@@ -0,0 +1,202 @@
+langcode: en
+status: true
+dependencies:
+ config:
+ - field.field.node.laboratories.body
+ - field.field.node.laboratories.field_area
+ - field.field.node.laboratories.field_lab_equipment_cost
+ - field.field.node.laboratories.field_lab_image
+ - field.field.node.laboratories.field_utilisation_of_lab
+ - node.type.laboratories
+ module:
+ - ds
+ - image
+ - text
+ - user
+ enforced:
+ module:
+ - laboratories
+third_party_settings:
+ ds:
+ layout:
+ id: ds_1col
+ library: null
+ disable_css: false
+ entity_classes: all_classes
+ settings:
+ wrappers:
+ ds_content: div
+ outer_wrapper: div
+ attributes: ''
+ link_attribute: ''
+ link_custom: ''
+ classes:
+ layout_class: { }
+ ds_content: { }
+ regions:
+ ds_content:
+ - node_title
+ - field_lab_image
+ - field_area
+ - field_lab_equipment_cost
+ - field_utilisation_of_lab
+ fields:
+ node_title:
+ plugin_id: node_title
+ weight: 0
+ label: hidden
+ formatter: default
+id: node.laboratories.default
+targetEntityType: node
+bundle: laboratories
+mode: default
+content:
+ field_area:
+ type: string
+ weight: 2
+ region: ds_content
+ label: above
+ settings:
+ link_to_entity: false
+ third_party_settings:
+ ds:
+ ft:
+ id: expert
+ settings:
+ lb: 'Area '
+ prefix: ''
+ lbw: true
+ lbw-el: div
+ lbw-cl: 'fw-bold col-sm-3'
+ lbw-at: ''
+ ow: true
+ ow-el: div
+ ow-cl: 'row '
+ ow-at: ''
+ fis-el: ''
+ fis-cl: ''
+ fis-at: ''
+ fi: true
+ fi-el: div
+ fi-cl: col-sm-5
+ fi-at: ''
+ suffix: ''
+ lb-col: false
+ ow-def-at: false
+ ow-def-cl: false
+ fis: false
+ fis-def-at: false
+ fi-def-at: false
+ field_lab_equipment_cost:
+ type: string
+ weight: 3
+ region: ds_content
+ label: above
+ settings:
+ link_to_entity: false
+ third_party_settings:
+ ds:
+ ft:
+ id: expert
+ settings:
+ lb: 'Equipment cost'
+ prefix: ''
+ lbw: true
+ lbw-el: div
+ lbw-cl: 'col-sm-3 fw-bold'
+ lbw-at: ''
+ ow: true
+ ow-el: div
+ ow-cl: 'row mb-10'
+ ow-at: ''
+ fis-el: ''
+ fis-cl: ''
+ fis-at: ''
+ fi: true
+ fi-el: div
+ fi-cl: col-sm-5
+ fi-at: ''
+ suffix: ''
+ lb-col: false
+ ow-def-at: false
+ ow-def-cl: false
+ fis: false
+ fis-def-at: false
+ fi-def-at: false
+ field_lab_image:
+ type: image
+ weight: 1
+ region: ds_content
+ label: hidden
+ settings:
+ image_style: ''
+ image_link: ''
+ third_party_settings:
+ ds:
+ ds_limit: ''
+ ft:
+ id: expert
+ settings:
+ lb: ''
+ prefix: ''
+ lbw: true
+ lbw-el: 'div '
+ lbw-cl: ' fw-bold '
+ lbw-at: ''
+ ow: true
+ ow-el: div
+ ow-cl: 'center-block mt-10 mb-10'
+ ow-at: ''
+ fis-el: ''
+ fis-cl: ''
+ fis-at: ''
+ fi: true
+ fi-el: 'div '
+ fi-cl: ' center-block'
+ fi-at: ''
+ suffix: ''
+ lb-col: false
+ ow-def-at: false
+ ow-def-cl: false
+ fis: false
+ fis-def-at: false
+ fi-def-at: false
+ field_utilisation_of_lab:
+ type: text_default
+ weight: 4
+ region: ds_content
+ label: above
+ settings: { }
+ third_party_settings:
+ ds:
+ ft:
+ id: expert
+ settings:
+ lb: Utilisation
+ prefix: ''
+ lbw: true
+ lbw-el: div
+ lbw-cl: 'col-sm-3 fw-bold '
+ lbw-at: ''
+ ow: true
+ ow-el: div
+ ow-cl: 'row mb-10'
+ ow-at: ''
+ fis-el: ''
+ fis-cl: ''
+ fis-at: ''
+ fi: true
+ fi-el: div
+ fi-cl: col-sm-5
+ fi-at: ''
+ suffix: ''
+ lb-col: false
+ ow-def-at: false
+ ow-def-cl: false
+ fis: false
+ fis-def-at: false
+ fi-def-at: false
+hidden:
+ body: true
+ langcode: true
+ links: true
diff --git a/modules/kalpesh/laboratory/config/install/core.entity_view_display.node.laboratories.teaser.yml b/modules/kalpesh/laboratory/config/install/core.entity_view_display.node.laboratories.teaser.yml
new file mode 100644
index 0000000..65f66bb
--- /dev/null
+++ b/modules/kalpesh/laboratory/config/install/core.entity_view_display.node.laboratories.teaser.yml
@@ -0,0 +1,33 @@
+langcode: en
+status: true
+dependencies:
+ config:
+ - core.entity_view_mode.node.teaser
+ - field.field.node.laboratories.body
+ - node.type.laboratories
+ module:
+ - text
+ - user
+ enforced:
+ module:
+ - laboratories
+id: node.laboratories.teaser
+targetEntityType: node
+bundle: laboratories
+mode: teaser
+content:
+ body:
+ label: hidden
+ type: text_summary_or_trimmed
+ weight: 101
+ settings:
+ trim_length: 600
+ third_party_settings: { }
+ region: content
+ links:
+ weight: 100
+ settings: { }
+ third_party_settings: { }
+ region: content
+hidden:
+ langcode: true
diff --git a/modules/kalpesh/laboratory/config/install/field.field.node.laboratories.body.yml b/modules/kalpesh/laboratory/config/install/field.field.node.laboratories.body.yml
new file mode 100644
index 0000000..c2bdaa7
--- /dev/null
+++ b/modules/kalpesh/laboratory/config/install/field.field.node.laboratories.body.yml
@@ -0,0 +1,24 @@
+langcode: en
+status: true
+dependencies:
+ config:
+ - field.storage.node.body
+ - node.type.laboratories
+ module:
+ - text
+ enforced:
+ module:
+ - laboratories
+id: node.laboratories.body
+field_name: body
+entity_type: node
+bundle: laboratories
+label: Body
+description: ''
+required: false
+translatable: true
+default_value: { }
+default_value_callback: ''
+settings:
+ display_summary: true
+field_type: text_with_summary
diff --git a/modules/kalpesh/laboratory/config/install/field.field.node.laboratories.field_area.yml b/modules/kalpesh/laboratory/config/install/field.field.node.laboratories.field_area.yml
new file mode 100644
index 0000000..89b67b2
--- /dev/null
+++ b/modules/kalpesh/laboratory/config/install/field.field.node.laboratories.field_area.yml
@@ -0,0 +1,21 @@
+langcode: en
+status: true
+dependencies:
+ config:
+ - field.storage.node.field_area
+ - node.type.laboratories
+ enforced:
+ module:
+ - laboratories
+id: node.laboratories.field_area
+field_name: field_area
+entity_type: node
+bundle: laboratories
+label: Area
+description: 'Area of lab'
+required: true
+translatable: false
+default_value: { }
+default_value_callback: ''
+settings: { }
+field_type: string
diff --git a/modules/kalpesh/laboratory/config/install/field.field.node.laboratories.field_lab_equipment_cost.yml b/modules/kalpesh/laboratory/config/install/field.field.node.laboratories.field_lab_equipment_cost.yml
new file mode 100644
index 0000000..2f64ecf
--- /dev/null
+++ b/modules/kalpesh/laboratory/config/install/field.field.node.laboratories.field_lab_equipment_cost.yml
@@ -0,0 +1,21 @@
+langcode: en
+status: true
+dependencies:
+ config:
+ - field.storage.node.field_lab_equipment_cost
+ - node.type.laboratories
+ enforced:
+ module:
+ - laboratories
+id: node.laboratories.field_lab_equipment_cost
+field_name: field_lab_equipment_cost
+entity_type: node
+bundle: laboratories
+label: 'Lab Equipment cost'
+description: 'cost of software and machines'
+required: true
+translatable: false
+default_value: { }
+default_value_callback: ''
+settings: { }
+field_type: string
diff --git a/modules/kalpesh/laboratory/config/install/field.field.node.laboratories.field_lab_image.yml b/modules/kalpesh/laboratory/config/install/field.field.node.laboratories.field_lab_image.yml
new file mode 100644
index 0000000..6a9dc2c
--- /dev/null
+++ b/modules/kalpesh/laboratory/config/install/field.field.node.laboratories.field_lab_image.yml
@@ -0,0 +1,40 @@
+langcode: en
+status: true
+dependencies:
+ config:
+ - field.storage.node.field_lab_image
+ - node.type.laboratories
+ module:
+ - image
+ enforced:
+ module:
+ - laboratories
+id: node.laboratories.field_lab_image
+field_name: field_lab_image
+entity_type: node
+bundle: laboratories
+label: 'Lab Image'
+description: ''
+required: true
+translatable: false
+default_value: { }
+default_value_callback: ''
+settings:
+ file_directory: '[date:custom:Y]-[date:custom:m]'
+ file_extensions: 'png gif jpg jpeg'
+ max_filesize: ''
+ max_resolution: ''
+ min_resolution: ''
+ alt_field: true
+ alt_field_required: true
+ title_field: false
+ title_field_required: false
+ default_image:
+ uuid: ''
+ alt: ''
+ title: ''
+ width: null
+ height: null
+ handler: 'default:file'
+ handler_settings: { }
+field_type: image
diff --git a/modules/kalpesh/laboratory/config/install/field.field.node.laboratories.field_utilisation_of_lab.yml b/modules/kalpesh/laboratory/config/install/field.field.node.laboratories.field_utilisation_of_lab.yml
new file mode 100644
index 0000000..75ce44e
--- /dev/null
+++ b/modules/kalpesh/laboratory/config/install/field.field.node.laboratories.field_utilisation_of_lab.yml
@@ -0,0 +1,23 @@
+langcode: en
+status: true
+dependencies:
+ config:
+ - field.storage.node.field_utilisation_of_lab
+ - node.type.laboratories
+ module:
+ - text
+ enforced:
+ module:
+ - laboratories
+id: node.laboratories.field_utilisation_of_lab
+field_name: field_utilisation_of_lab
+entity_type: node
+bundle: laboratories
+label: 'Utilisation of lab'
+description: 'Semiser wise use of lab in hours/week'
+required: true
+translatable: false
+default_value: { }
+default_value_callback: ''
+settings: { }
+field_type: text_long
diff --git a/modules/kalpesh/laboratory/config/install/field.storage.node.field_area.yml b/modules/kalpesh/laboratory/config/install/field.storage.node.field_area.yml
new file mode 100644
index 0000000..34e31e3
--- /dev/null
+++ b/modules/kalpesh/laboratory/config/install/field.storage.node.field_area.yml
@@ -0,0 +1,23 @@
+langcode: en
+status: true
+dependencies:
+ module:
+ - node
+ enforced:
+ module:
+ - laboratories
+id: node.field_area
+field_name: field_area
+entity_type: node
+type: string
+settings:
+ max_length: 255
+ is_ascii: false
+ case_sensitive: false
+module: core
+locked: false
+cardinality: 1
+translatable: true
+indexes: { }
+persist_with_no_fields: false
+custom_storage: false
diff --git a/modules/kalpesh/laboratory/config/install/field.storage.node.field_lab_equipment_cost.yml b/modules/kalpesh/laboratory/config/install/field.storage.node.field_lab_equipment_cost.yml
new file mode 100644
index 0000000..dc60ebf
--- /dev/null
+++ b/modules/kalpesh/laboratory/config/install/field.storage.node.field_lab_equipment_cost.yml
@@ -0,0 +1,23 @@
+langcode: en
+status: true
+dependencies:
+ module:
+ - node
+ enforced:
+ module:
+ - laboratories
+id: node.field_lab_equipment_cost
+field_name: field_lab_equipment_cost
+entity_type: node
+type: string
+settings:
+ max_length: 255
+ is_ascii: false
+ case_sensitive: false
+module: core
+locked: false
+cardinality: 1
+translatable: true
+indexes: { }
+persist_with_no_fields: false
+custom_storage: false
diff --git a/modules/kalpesh/laboratory/config/install/field.storage.node.field_lab_image.yml b/modules/kalpesh/laboratory/config/install/field.storage.node.field_lab_image.yml
new file mode 100644
index 0000000..f54354e
--- /dev/null
+++ b/modules/kalpesh/laboratory/config/install/field.storage.node.field_lab_image.yml
@@ -0,0 +1,32 @@
+langcode: en
+status: true
+dependencies:
+ module:
+ - file
+ - image
+ - node
+ enforced:
+ module:
+ - laboratories
+id: node.field_lab_image
+field_name: field_lab_image
+entity_type: node
+type: image
+settings:
+ uri_scheme: public
+ default_image:
+ uuid: ''
+ alt: ''
+ title: ''
+ width: null
+ height: null
+ target_type: file
+ display_field: false
+ display_default: false
+module: image
+locked: false
+cardinality: -1
+translatable: true
+indexes: { }
+persist_with_no_fields: false
+custom_storage: false
diff --git a/modules/kalpesh/laboratory/config/install/field.storage.node.field_utilisation_of_lab.yml b/modules/kalpesh/laboratory/config/install/field.storage.node.field_utilisation_of_lab.yml
new file mode 100644
index 0000000..ec586d5
--- /dev/null
+++ b/modules/kalpesh/laboratory/config/install/field.storage.node.field_utilisation_of_lab.yml
@@ -0,0 +1,21 @@
+langcode: en
+status: true
+dependencies:
+ module:
+ - node
+ - text
+ enforced:
+ module:
+ - laboratories
+id: node.field_utilisation_of_lab
+field_name: field_utilisation_of_lab
+entity_type: node
+type: text_long
+settings: { }
+module: text
+locked: false
+cardinality: 1
+translatable: true
+indexes: { }
+persist_with_no_fields: false
+custom_storage: false
diff --git a/modules/kalpesh/laboratory/config/install/image.style.laboratory_image_style.yml b/modules/kalpesh/laboratory/config/install/image.style.laboratory_image_style.yml
new file mode 100644
index 0000000..7f67910
--- /dev/null
+++ b/modules/kalpesh/laboratory/config/install/image.style.laboratory_image_style.yml
@@ -0,0 +1,17 @@
+langcode: en
+status: true
+dependencies:
+ enforced:
+ module:
+ - laboratories
+name: laboratory_image_style
+label: 'laboratory image style'
+effects:
+ c989a340-a271-4d7f-8475-32e97bbd71d5:
+ uuid: c989a340-a271-4d7f-8475-32e97bbd71d5
+ id: image_scale_and_crop
+ weight: 1
+ data:
+ width: 400
+ height: 300
+ anchor: center-center
diff --git a/modules/kalpesh/laboratory/config/install/node.type.laboratories.yml b/modules/kalpesh/laboratory/config/install/node.type.laboratories.yml
new file mode 100644
index 0000000..2763808
--- /dev/null
+++ b/modules/kalpesh/laboratory/config/install/node.type.laboratories.yml
@@ -0,0 +1,20 @@
+langcode: en
+status: true
+dependencies:
+ module:
+ - menu_ui
+ enforced:
+ module:
+ - laboratories
+third_party_settings:
+ menu_ui:
+ available_menus:
+ - main
+ parent: 'main:'
+name: Laboratories
+type: laboratories
+description: 'Detail information about laboratories'
+help: ''
+new_revision: true
+preview_mode: 1
+display_submitted: true
diff --git a/modules/kalpesh/laboratory/config/install/views.view.laboratories.yml b/modules/kalpesh/laboratory/config/install/views.view.laboratories.yml
new file mode 100644
index 0000000..5e9ee22
--- /dev/null
+++ b/modules/kalpesh/laboratory/config/install/views.view.laboratories.yml
@@ -0,0 +1,202 @@
+langcode: en
+status: true
+dependencies:
+ config:
+ - field.field.node.laboratories.body
+ - field.field.node.laboratories.field_area
+ - field.field.node.laboratories.field_lab_equipment_cost
+ - field.field.node.laboratories.field_lab_image
+ - field.field.node.laboratories.field_utilisation_of_lab
+ - node.type.laboratories
+ module:
+ - ds
+ - image
+ - text
+ - user
+ enforced:
+ module:
+ - laboratories
+third_party_settings:
+ ds:
+ layout:
+ id: ds_1col
+ library: null
+ disable_css: false
+ entity_classes: all_classes
+ settings:
+ wrappers:
+ ds_content: div
+ outer_wrapper: div
+ attributes: ''
+ link_attribute: ''
+ link_custom: ''
+ classes:
+ layout_class: { }
+ ds_content: { }
+ regions:
+ ds_content:
+ - node_title
+ - field_lab_image
+ - field_area
+ - field_lab_equipment_cost
+ - field_utilisation_of_lab
+ fields:
+ node_title:
+ plugin_id: node_title
+ weight: 0
+ label: hidden
+ formatter: default
+id: node.laboratories.default
+targetEntityType: node
+bundle: laboratories
+mode: default
+content:
+ field_area:
+ type: string
+ weight: 2
+ region: ds_content
+ label: above
+ settings:
+ link_to_entity: false
+ third_party_settings:
+ ds:
+ ft:
+ id: expert
+ settings:
+ lb: 'Area '
+ prefix: ''
+ lbw: true
+ lbw-el: div
+ lbw-cl: 'fw-bold col-sm-3'
+ lbw-at: ''
+ ow: true
+ ow-el: div
+ ow-cl: 'row '
+ ow-at: ''
+ fis-el: ''
+ fis-cl: ''
+ fis-at: ''
+ fi: true
+ fi-el: div
+ fi-cl: col-sm-5
+ fi-at: ''
+ suffix: ''
+ lb-col: false
+ ow-def-at: false
+ ow-def-cl: false
+ fis: false
+ fis-def-at: false
+ fi-def-at: false
+ field_lab_equipment_cost:
+ type: string
+ weight: 3
+ region: ds_content
+ label: above
+ settings:
+ link_to_entity: false
+ third_party_settings:
+ ds:
+ ft:
+ id: expert
+ settings:
+ lb: 'Equipment cost'
+ prefix: ''
+ lbw: true
+ lbw-el: div
+ lbw-cl: 'col-sm-3 fw-bold'
+ lbw-at: ''
+ ow: true
+ ow-el: div
+ ow-cl: 'row mb-10'
+ ow-at: ''
+ fis-el: ''
+ fis-cl: ''
+ fis-at: ''
+ fi: true
+ fi-el: div
+ fi-cl: col-sm-5
+ fi-at: ''
+ suffix: ''
+ lb-col: false
+ ow-def-at: false
+ ow-def-cl: false
+ fis: false
+ fis-def-at: false
+ fi-def-at: false
+ field_lab_image:
+ type: image
+ weight: 1
+ region: ds_content
+ label: hidden
+ settings:
+ image_style: ''
+ image_link: ''
+ third_party_settings:
+ ds:
+ ds_limit: ''
+ ft:
+ id: expert
+ settings:
+ lb: ''
+ prefix: ''
+ lbw: true
+ lbw-el: 'div '
+ lbw-cl: ' fw-bold '
+ lbw-at: ''
+ ow: true
+ ow-el: div
+ ow-cl: 'center-block mt-10 mb-10'
+ ow-at: ''
+ fis-el: ''
+ fis-cl: ''
+ fis-at: ''
+ fi: true
+ fi-el: 'div '
+ fi-cl: ' center-block'
+ fi-at: ''
+ suffix: ''
+ lb-col: false
+ ow-def-at: false
+ ow-def-cl: false
+ fis: false
+ fis-def-at: false
+ fi-def-at: false
+ field_utilisation_of_lab:
+ type: text_default
+ weight: 4
+ region: ds_content
+ label: above
+ settings: { }
+ third_party_settings:
+ ds:
+ ft:
+ id: expert
+ settings:
+ lb: Utilisation
+ prefix: ''
+ lbw: true
+ lbw-el: div
+ lbw-cl: 'col-sm-3 fw-bold '
+ lbw-at: ''
+ ow: true
+ ow-el: div
+ ow-cl: 'row mb-10'
+ ow-at: ''
+ fis-el: ''
+ fis-cl: ''
+ fis-at: ''
+ fi: true
+ fi-el: div
+ fi-cl: col-sm-5
+ fi-at: ''
+ suffix: ''
+ lb-col: false
+ ow-def-at: false
+ ow-def-cl: false
+ fis: false
+ fis-def-at: false
+ fi-def-at: false
+hidden:
+ body: true
+ langcode: true
+ links: true
diff --git a/modules/kalpesh/laboratory/laboratory.info.yml b/modules/kalpesh/laboratory/laboratory.info.yml
new file mode 100644
index 0000000..1db207c
--- /dev/null
+++ b/modules/kalpesh/laboratory/laboratory.info.yml
@@ -0,0 +1,14 @@
+name: laboratory
+type: module
+description: 'This module store laboratories details'
+core: 8.x
+package: Custom
+dependencies:
+ - drupal:menu_ui
+ - drupal:image
+ - drupal:path
+ - drupal:text
+ - ds:ds
+ - drupal:user
+ - drupal:node
+ - drupal:file
diff --git a/modules/kalpesh/laboratory/laboratory.install b/modules/kalpesh/laboratory/laboratory.install
new file mode 100644
index 0000000..68dfe55
--- /dev/null
+++ b/modules/kalpesh/laboratory/laboratory.install
@@ -0,0 +1,64 @@
+<?php
+
+
+/**
+
+
+* Implements hook_uninstall().
+
+
+*/
+
+
+function laboratory_uninstall() { //<-- replace “welcome” with your module machine name
+
+
+ // Load services.
+
+
+ $queryFactory = \Drupal::service('entity.query');
+
+
+ $nodeStorage = \Drupal::entityManager()->getStorage('node');
+
+
+
+
+
+
+
+ // Query all entity.
+
+
+ $query = $queryFactory->get('node')
+// <-- replace event in below line with your content type machine name
+
+
+ ->condition('type', 'laboratories');
+
+
+ $nids = $query->execute();
+
+
+
+
+
+
+
+ // Delete entities.
+
+
+ if (!empty($nids)) {
+
+
+ $entities = $nodeStorage->loadMultiple($nids);
+
+
+ $nodeStorage->delete($entities);
+
+
+ }
+
+
+}
+
diff --git a/modules/kalpesh/laboratory/laboratory.module b/modules/kalpesh/laboratory/laboratory.module
new file mode 100644
index 0000000..5a9801f
--- /dev/null
+++ b/modules/kalpesh/laboratory/laboratory.module
@@ -0,0 +1,35 @@
+<?php
+
+/**
+ * @file
+ * Contains laboratory.module.
+ */
+
+use Drupal\Core\Routing\RouteMatchInterface;
+
+/**
+ * Implements hook_help().
+ */
+function laboratory_help($route_name, RouteMatchInterface $route_match) {
+ switch ($route_name) {
+ // Main module help for the laboratory module.
+ case 'help.page.laboratory':
+ $output = '';
+ $output .= '<h3>' . t('About') . '</h3>';
+ $output .= '<p>' . t('This module store laboratories details') . '</p>';
+ return $output;
+
+ default:
+ }
+}
+
+/**
+ * Implements hook_theme().
+ */
+function laboratory_theme() {
+ return [
+ 'laboratory' => [
+ 'render element' => 'children',
+ ],
+ ];
+}
diff --git a/modules/kalpesh/laboratory/templates/laboratory.html.twig b/modules/kalpesh/laboratory/templates/laboratory.html.twig
new file mode 100644
index 0000000..95722bd
--- /dev/null
+++ b/modules/kalpesh/laboratory/templates/laboratory.html.twig
@@ -0,0 +1 @@
+<!-- Add you custom twig html here -->
diff --git a/modules/kalpesh/laboratory/tests/src/Functional/LoadTest.php b/modules/kalpesh/laboratory/tests/src/Functional/LoadTest.php
new file mode 100644
index 0000000..431de13
--- /dev/null
+++ b/modules/kalpesh/laboratory/tests/src/Functional/LoadTest.php
@@ -0,0 +1,46 @@
+<?php
+
+namespace Drupal\Tests\laboratory\Functional;
+
+use Drupal\Core\Url;
+use Drupal\Tests\BrowserTestBase;
+
+/**
+ * Simple test to ensure that main page loads with module enabled.
+ *
+ * @group laboratory
+ */
+class LoadTest extends BrowserTestBase {
+
+ /**
+ * Modules to enable.
+ *
+ * @var array
+ */
+ public static $modules = ['laboratory'];
+
+ /**
+ * A user with permission to administer site configuration.
+ *
+ * @var \Drupal\user\UserInterface
+ */
+ protected $user;
+
+ /**
+ * {@inheritdoc}
+ */
+ protected function setUp() {
+ parent::setUp();
+ $this->user = $this->drupalCreateUser(['administer site configuration']);
+ $this->drupalLogin($this->user);
+ }
+
+ /**
+ * Tests that the home page loads with a 200 response.
+ */
+ public function testLoad() {
+ $this->drupalGet(Url::fromRoute('<front>'));
+ $this->assertSession()->statusCodeEquals(200);
+ }
+
+}