Commit 4049eef2 authored by Reena Raghavan's avatar Reena Raghavan

CSV Import added

parent 73b3be1b
...@@ -4,7 +4,7 @@ ...@@ -4,7 +4,7 @@
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
"This file is @generated automatically" "This file is @generated automatically"
], ],
"content-hash": "a4bf52f850f04f4eb14670f5eb177c2e", "content-hash": "9603b133763e4ef7b895ef73ec868be7",
"packages": [ "packages": [
{ {
"name": "asm89/stack-cors", "name": "asm89/stack-cors",
...@@ -1254,6 +1254,65 @@ ...@@ -1254,6 +1254,65 @@
"abandoned": "roave/better-reflection", "abandoned": "roave/better-reflection",
"time": "2022-05-31T18:46:25+00:00" "time": "2022-05-31T18:46:25+00:00"
}, },
{
"name": "drupal/color_field",
"version": "2.5.0",
"source": {
"type": "git",
"url": "https://git.drupalcode.org/project/color_field.git",
"reference": "8.x-2.5"
},
"dist": {
"type": "zip",
"url": "https://ftp.drupal.org/files/projects/color_field-8.x-2.5.zip",
"reference": "8.x-2.5",
"shasum": "9b0d299cb24d3cb21c7fb6a6a08d32ae5aed8652"
},
"require": {
"drupal/core": "^8 || ^9"
},
"require-dev": {
"drupal/core-recommended": "*",
"drupal/token": "~1.3"
},
"suggest": {
"bower-asset/jquery-simple-color": "^v1.2.2: Provides JavaScript library necessary for the Color Grid widget",
"bower-asset/spectrum": "^1.8: Provides JavaScript library necessary for Spectrum widget."
},
"type": "drupal-module",
"extra": {
"drupal": {
"version": "8.x-2.5",
"datestamp": "1632938098",
"security-coverage": {
"status": "covered",
"message": "Covered by Drupal's security advisory policy"
}
}
},
"notification-url": "https://packages.drupal.org/8/downloads",
"license": [
"GPL-2.0-or-later"
],
"authors": [
{
"name": "targoo",
"homepage": "https://www.drupal.org/user/431910",
"role": "Maintainer"
},
{
"name": "Nick Wilde",
"homepage": "https://www.drupal.org/user/nickwilde",
"role": "Maintainer"
}
],
"description": "Provides a color field type to store the color value and opacity",
"homepage": "https://www.drupal.org/project/color_field",
"support": {
"source": "https://git.drupalcode.org/project/color_field",
"issues": "https://www.drupal.org/project/issues/color_field?version=8.x"
}
},
{ {
"name": "drupal/core", "name": "drupal/core",
"version": "9.4.8", "version": "9.4.8",
...@@ -1557,6 +1616,66 @@ ...@@ -1557,6 +1616,66 @@
}, },
"time": "2022-10-06T15:57:08+00:00" "time": "2022-10-06T15:57:08+00:00"
}, },
{
"name": "drupal/csv_importer",
"version": "1.14.0",
"source": {
"type": "git",
"url": "https://git.drupalcode.org/project/csv_importer.git",
"reference": "8.x-1.14"
},
"dist": {
"type": "zip",
"url": "https://ftp.drupal.org/files/projects/csv_importer-8.x-1.14.zip",
"reference": "8.x-1.14",
"shasum": "31e7d4b37b998faf372da7d545d11d4d2758e257"
},
"require": {
"drupal/core": "^8 || ^9"
},
"type": "drupal-module",
"extra": {
"drupal": {
"version": "8.x-1.14",
"datestamp": "1643892335",
"security-coverage": {
"status": "covered",
"message": "Covered by Drupal's security advisory policy"
}
}
},
"autoload": {
"psr-4": {
"Drupal\\csv_importer\\": "./src"
}
},
"autoload-dev": {
"psr-4": {
"Drupal\\Tests\\csv_importer\\": "./tests/src"
}
},
"notification-url": "https://packages.drupal.org/8/downloads",
"license": [
"GPL-2.0+"
],
"authors": [
{
"name": "Lasha Badashvili",
"homepage": "https://www.drupal.org/user/3382242",
"email": "lashabp@gmail.com"
}
],
"description": "CSV Importer.",
"homepage": "https://www.drupal.org/project/csv_importer",
"keywords": [
"csv",
"drupal",
"import"
],
"support": {
"source": "https://git.drupalcode.org/project/csv_importer"
}
},
{ {
"name": "drupal/custom_sql_migrate_source_plugin", "name": "drupal/custom_sql_migrate_source_plugin",
"version": "1.3.0", "version": "1.3.0",
...@@ -1603,6 +1722,250 @@ ...@@ -1603,6 +1722,250 @@
"source": "https://git.drupalcode.org/project/custom_sql_migrate_source_plugin" "source": "https://git.drupalcode.org/project/custom_sql_migrate_source_plugin"
} }
}, },
{
"name": "drupal/entity_reference_revisions",
"version": "1.10.0",
"source": {
"type": "git",
"url": "https://git.drupalcode.org/project/entity_reference_revisions.git",
"reference": "8.x-1.10"
},
"dist": {
"type": "zip",
"url": "https://ftp.drupal.org/files/projects/entity_reference_revisions-8.x-1.10.zip",
"reference": "8.x-1.10",
"shasum": "edd23b91c4a34db65ea22c4db54b7458edc7513b"
},
"require": {
"drupal/core": "^9 || ^10"
},
"require-dev": {
"drupal/diff": "1.x-dev"
},
"type": "drupal-module",
"extra": {
"drupal": {
"version": "8.x-1.10",
"datestamp": "1660664712",
"security-coverage": {
"status": "covered",
"message": "Covered by Drupal's security advisory policy"
}
},
"drush": {
"services": {
"drush.services.yml": "^9 || ^10 || ^11"
}
}
},
"notification-url": "https://packages.drupal.org/8/downloads",
"license": [
"GPL-2.0-or-later"
],
"authors": [
{
"name": "Berdir",
"homepage": "https://www.drupal.org/user/214652"
},
{
"name": "Frans",
"homepage": "https://www.drupal.org/user/514222"
},
{
"name": "jeroen.b",
"homepage": "https://www.drupal.org/user/1853532"
},
{
"name": "miro_dietiker",
"homepage": "https://www.drupal.org/user/227761"
}
],
"description": "Entity Reference Revisions",
"homepage": "https://www.drupal.org/project/entity_reference_revisions",
"support": {
"source": "https://git.drupalcode.org/project/entity_reference_revisions"
}
},
{
"name": "drupal/geofield",
"version": "1.47.0",
"source": {
"type": "git",
"url": "https://git.drupalcode.org/project/geofield.git",
"reference": "8.x-1.47"
},
"dist": {
"type": "zip",
"url": "https://ftp.drupal.org/files/projects/geofield-8.x-1.47.zip",
"reference": "8.x-1.47",
"shasum": "6eb52dcf82e242beac46655df8ee8f4075d06cef"
},
"require": {
"drupal/core": "^8.8 || ^9 || ^10",
"itamair/geophp": "^1.3"
},
"type": "drupal-module",
"extra": {
"drupal": {
"version": "8.x-1.47",
"datestamp": "1668167741",
"security-coverage": {
"status": "covered",
"message": "Covered by Drupal's security advisory policy"
}
}
},
"notification-url": "https://packages.drupal.org/8/downloads",
"license": [
"GPL-2.0+"
],
"authors": [
{
"name": "Italo Mairo",
"homepage": "https://www.drupal.org/u/itamair",
"role": "Drupal 8+ Maintainer"
},
{
"name": "Brandon Morrison",
"homepage": "https://www.drupal.org/u/brandonian",
"role": "Drupal 7 Maintainer"
},
{
"name": "Pablo López",
"homepage": "https://www.drupal.org/u/plopesc",
"role": "Drupal 7 Maintainer"
},
{
"name": "phayes",
"homepage": "https://www.drupal.org/user/47098"
},
{
"name": "plopesc",
"homepage": "https://www.drupal.org/user/282415"
}
],
"description": "Stores geographic and location data (points, lines, and polygons).",
"homepage": "https://www.drupal.org/project/geofield",
"support": {
"source": "https://git.drupalcode.org/project/geofield",
"issues": "https://www.drupal.org/project/issues/geofield",
"irc": "irc://irc.freenode.org/drupal-contribute"
}
},
{
"name": "drupal/geofield_map",
"version": "3.0.4",
"source": {
"type": "git",
"url": "https://git.drupalcode.org/project/geofield_map.git",
"reference": "3.0.4"
},
"dist": {
"type": "zip",
"url": "https://ftp.drupal.org/files/projects/geofield_map-3.0.4.zip",
"reference": "3.0.4",
"shasum": "bca4370ebb75f662f40d77df2ea951e784f8932c"
},
"require": {
"drupal/core": "^9.3 || ^10",
"drupal/geofield": "^1.31"
},
"type": "drupal-module",
"extra": {
"drupal": {
"version": "3.0.4",
"datestamp": "1668167692",
"security-coverage": {
"status": "covered",
"message": "Covered by Drupal's security advisory policy"
}
}
},
"notification-url": "https://packages.drupal.org/8/downloads",
"license": [
"GPL-2.0-or-later"
],
"authors": [
{
"name": "Italo Mairo",
"homepage": "https://www.drupal.org/u/itamair",
"role": "Creator/Maintainer"
}
],
"description": "Geofield Map is an advanced, complete and easy-to-use Geo Mapping solution for Drupal 8, based on and fully compatible with the Geofield module.",
"homepage": "https://www.drupal.org/project/geofield_map",
"support": {
"source": "https://git.drupalcode.org/project/geofield_map",
"issues": "https://www.drupal.org/project/issues/geofield_map"
}
},
{
"name": "drupal/metatag",
"version": "1.22.0",
"source": {
"type": "git",
"url": "https://git.drupalcode.org/project/metatag.git",
"reference": "8.x-1.22"
},
"dist": {
"type": "zip",
"url": "https://ftp.drupal.org/files/projects/metatag-8.x-1.22.zip",
"reference": "8.x-1.22",
"shasum": "045cd6a4aa5048bfd6d47584eae1210eab9ba1fa"
},
"require": {
"drupal/core": "^9.3 || ^10",
"drupal/token": "^1.0"
},
"require-dev": {
"drupal/devel": "^4.0 || ^5.0",
"drupal/hal": "^9 || ^1 || ^2",
"drupal/metatag_dc": "*",
"drupal/metatag_open_graph": "*",
"drupal/page_manager": "^4.0",
"drupal/panelizer": "^4.0",
"drupal/redirect": "^1.0",
"drupal/webprofiler": "^9 || ^10",
"mpyw/phpunit-patch-serializable-comparison": "*"
},
"type": "drupal-module",
"extra": {
"drupal": {
"version": "8.x-1.22",
"datestamp": "1664472988",
"security-coverage": {
"status": "covered",
"message": "Covered by Drupal's security advisory policy"
}
}
},
"notification-url": "https://packages.drupal.org/8/downloads",
"license": [
"GPL-2.0-or-later"
],
"authors": [
{
"name": "See contributors",
"homepage": "https://www.drupal.org/node/640498/committers",
"role": "Developer"
},
{
"name": "Dave Reid",
"homepage": "https://www.drupal.org/user/53892"
}
],
"description": "Manage meta tags for all entities.",
"homepage": "https://www.drupal.org/project/metatag",
"keywords": [
"Drupal",
"seo"
],
"support": {
"source": "https://git.drupalcode.org/project/metatag",
"issues": "https://www.drupal.org/project/issues/metatag",
"docs": "https://www.drupal.org/docs/8/modules/metatag"
}
},
{ {
"name": "drupal/migrate_plus", "name": "drupal/migrate_plus",
"version": "6.0.0", "version": "6.0.0",
...@@ -1668,6 +2031,57 @@ ...@@ -1668,6 +2031,57 @@
"slack": "#migrate" "slack": "#migrate"
} }
}, },
{
"name": "drupal/migrate_source_csv",
"version": "3.5.0",
"source": {
"type": "git",
"url": "https://git.drupalcode.org/project/migrate_source_csv.git",
"reference": "8.x-3.5"
},
"dist": {
"type": "zip",
"url": "https://ftp.drupal.org/files/projects/migrate_source_csv-8.x-3.5.zip",
"reference": "8.x-3.5",
"shasum": "ddddba22fa7b4a54f05a606db33986b23b1a69ea"
},
"require": {
"drupal/core": ">=9.1",
"league/csv": "^9.1",
"php": ">=7.1"
},
"require-dev": {
"drupal/migrate_plus": ">=5.0"
},
"type": "drupal-module",
"extra": {
"drupal": {
"version": "8.x-3.5",
"datestamp": "1645538421",
"security-coverage": {
"status": "covered",
"message": "Covered by Drupal's security advisory policy"
}
}
},
"notification-url": "https://packages.drupal.org/8/downloads",
"license": [
"GPL-2.0-or-later"
],
"authors": [
{
"name": "Lucas Hedding",
"homepage": "https://www.drupal.org/u/heddn",
"role": "Maintainer"
}
],
"description": "CSV source migration.",
"homepage": "https://www.drupal.org/project/migrate_source_csv",
"support": {
"source": "https://cgit.drupalcode.org/migrate_source_csv",
"issues": "https://www.drupal.org/project/issues/migrate_source_csv"
}
},
{ {
"name": "drupal/migrate_tools", "name": "drupal/migrate_tools",
"version": "6.0.0", "version": "6.0.0",
...@@ -1739,6 +2153,266 @@ ...@@ -1739,6 +2153,266 @@
"slack": "#migrate" "slack": "#migrate"
} }
}, },
{
"name": "drupal/paragraphs",
"version": "1.15.0",
"source": {
"type": "git",
"url": "https://git.drupalcode.org/project/paragraphs.git",
"reference": "8.x-1.15"
},
"dist": {
"type": "zip",
"url": "https://ftp.drupal.org/files/projects/paragraphs-8.x-1.15.zip",
"reference": "8.x-1.15",
"shasum": "2ed2d3199553010fa1c500181bbebe676e9e60c1"
},
"require": {
"drupal/core": "^9.3 || ^10",
"drupal/entity_reference_revisions": "~1.3"
},
"require-dev": {
"drupal/block_field": "1.x-dev",
"drupal/diff": "1.x-dev",
"drupal/entity_browser": "2.x-dev",
"drupal/entity_usage": "2.x-dev",
"drupal/field_group": "3.x-dev",
"drupal/inline_entity_form": "1.x-dev",
"drupal/paragraphs-paragraphs_library": "*",
"drupal/replicate": "1.x-dev",
"drupal/search_api": "1.x-dev",
"drupal/search_api_db": "*"
},
"suggest": {
"drupal/entity_browser": "Recommended for an improved user experience when using the Paragraphs library module"
},
"type": "drupal-module",
"extra": {
"drupal": {
"version": "8.x-1.15",
"datestamp": "1661440897",
"security-coverage": {
"status": "covered",
"message": "Covered by Drupal's security advisory policy"
}
}
},
"notification-url": "https://packages.drupal.org/8/downloads",
"license": [
"GPL-2.0-or-later"
],
"authors": [
{
"name": "Berdir",
"homepage": "https://www.drupal.org/user/214652"
},
{
"name": "Frans",
"homepage": "https://www.drupal.org/user/514222"
},
{
"name": "jeroen.b",
"homepage": "https://www.drupal.org/user/1853532"
},
{
"name": "jstoller",
"homepage": "https://www.drupal.org/user/99012"
},
{
"name": "miro_dietiker",
"homepage": "https://www.drupal.org/user/227761"
},
{
"name": "Primsi",
"homepage": "https://www.drupal.org/user/282629"
}
],
"description": "Enables the creation of Paragraphs entities.",
"homepage": "https://www.drupal.org/project/paragraphs",
"support": {
"source": "https://git.drupalcode.org/project/paragraphs"
}
},
{
"name": "drupal/token",
"version": "1.11.0",
"source": {
"type": "git",
"url": "https://git.drupalcode.org/project/token.git",
"reference": "8.x-1.11"
},
"dist": {
"type": "zip",
"url": "https://ftp.drupal.org/files/projects/token-8.x-1.11.zip",
"reference": "8.x-1.11",
"shasum": "da264b36d1f88eb0c74bf84e18e8789854f98400"
},
"require": {
"drupal/core": "^9.2 || ^10"
},
"type": "drupal-module",
"extra": {
"drupal": {
"version": "8.x-1.11",
"datestamp": "1659471813",
"security-coverage": {
"status": "covered",
"message": "Covered by Drupal's security advisory policy"
}
},
"drush": {
"services": {
"drush.services.yml": "^9 || ^10"
}
}
},
"notification-url": "https://packages.drupal.org/8/downloads",
"license": [
"GPL-2.0-or-later"
],
"authors": [
{
"name": "Berdir",
"homepage": "https://www.drupal.org/user/214652"
},
{
"name": "Dave Reid",
"homepage": "https://www.drupal.org/user/53892"
},
{
"name": "eaton",
"homepage": "https://www.drupal.org/user/16496"
},
{
"name": "fago",
"homepage": "https://www.drupal.org/user/16747"
},
{
"name": "greggles",
"homepage": "https://www.drupal.org/user/36762"
},
{
"name": "mikeryan",
"homepage": "https://www.drupal.org/user/4420"
}
],
"description": "Provides a user interface for the Token API, some missing core tokens.",
"homepage": "https://www.drupal.org/project/token",
"support": {
"source": "https://git.drupalcode.org/project/token"
}
},
{
"name": "drupal/webform",
"version": "6.1.3",
"source": {
"type": "git",
"url": "https://git.drupalcode.org/project/webform.git",
"reference": "6.1.3"
},
"dist": {
"type": "zip",
"url": "https://ftp.drupal.org/files/projects/webform-6.1.3.zip",
"reference": "6.1.3",
"shasum": "efd032eadc10a4752b9b0203152a5d20eefac175"
},
"require": {
"drupal/core": "^8.8 || ^9"
},
"require-dev": {
"drupal/address": "~1.0",
"drupal/bootstrap": "~3.0",
"drupal/captcha": "~1.0",
"drupal/chosen": "~3.0",
"drupal/clientside_validation": "~3.0",
"drupal/clientside_validation_jquery": "*",
"drupal/devel": "~3.0",
"drupal/entity": "~1.0",
"drupal/entity_print": "~2.0",
"drupal/gnode": "*",
"drupal/group": "1.0",
"drupal/jquery_ui": "~1.0",
"drupal/jquery_ui_checkboxradio": "~1.0",
"drupal/jquery_ui_datepicker": "~1.0",
"drupal/lingotek": "~3.0",
"drupal/mailsystem": "~4.0",
"drupal/paragraphs": "~1.0",
"drupal/select2": "~1.0",
"drupal/smtp": "~1.0",
"drupal/styleguide": "~1.0",
"drupal/telephone_validation": "~2.0",
"drupal/token": "~1.0",
"drupal/variationcache": "~1.0",
"drupal/webform_access": "*",
"drupal/webform_attachment": "*",
"drupal/webform_clientside_validation": "*",
"drupal/webform_devel": "*",
"drupal/webform_entity_print": "*",
"drupal/webform_group": "*",
"drupal/webform_node": "*",
"drupal/webform_options_limit": "*",
"drupal/webform_scheduled_email": "*",
"drupal/webform_share": "*",
"drupal/webform_ui": "*"
},
"suggest": {
"drupal/jquery_ui_checkboxradio": "Provides jQuery UI Checkboxradio library. Required by the Webform jQueryUI Buttons module. The Webform jQueryUI Buttons module is deprecated because jQueryUI is no longer maintained.",
"drupal/jquery_ui_datepicker": "Provides jQuery UI Datepicker library. Required to support datepickers. The Webform jQueryUI Datepicker module is deprecated because jQueryUI is no longer maintained."
},
"type": "drupal-module",
"extra": {
"drupal": {
"version": "6.1.3",
"datestamp": "1644940723",
"security-coverage": {
"status": "covered",
"message": "Covered by Drupal's security advisory policy"
}
},
"drush": {
"services": {
"drush.services.yml": "^9 || ^10"
}
}
},
"notification-url": "https://packages.drupal.org/8/downloads",
"license": [
"GPL-2.0-or-later"
],
"authors": [
{
"name": "Jacob Rockowitz (jrockowitz)",
"homepage": "https://www.drupal.org/u/jrockowitz",
"role": "Maintainer"
},
{
"name": "Alexander Trotsenko (bucefal91)",
"homepage": "https://www.drupal.org/u/bucefal91",
"role": "Co-maintainer"
},
{
"name": "Contributors",
"homepage": "https://www.drupal.org/node/7404/committers",
"role": "Contributor"
},
{
"name": "quicksketch",
"homepage": "https://www.drupal.org/user/35821"
},
{
"name": "torotil",
"homepage": "https://www.drupal.org/user/865256"
}
],
"description": "Enables the creation of webforms and questionnaires.",
"homepage": "https://drupal.org/project/webform",
"support": {
"source": "https://git.drupalcode.org/project/webform",
"issues": "https://www.drupal.org/project/issues/webform?version=8.x",
"docs": "https://www.drupal.org/docs/8/modules/webform",
"forum": "https://drupal.stackexchange.com/questions/tagged/webform"
}
},
{ {
"name": "drush/drush", "name": "drush/drush",
"version": "11.3.2", "version": "11.3.2",
...@@ -2440,6 +3114,52 @@ ...@@ -2440,6 +3114,52 @@
], ],
"time": "2022-06-20T21:43:03+00:00" "time": "2022-06-20T21:43:03+00:00"
}, },
{
"name": "itamair/geophp",
"version": "1.3",
"source": {
"type": "git",
"url": "https://github.com/itamair/geoPHP.git",
"reference": "d7bccf9902a62430ceb2ac0771bb1e9d1deac4e9"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/itamair/geoPHP/zipball/d7bccf9902a62430ceb2ac0771bb1e9d1deac4e9",
"reference": "d7bccf9902a62430ceb2ac0771bb1e9d1deac4e9",
"shasum": ""
},
"require-dev": {
"phpunit/phpunit": "4.1.* || 9.5.*"
},
"type": "library",
"autoload": {
"classmap": [
"geoPHP.inc"
]
},
"notification-url": "https://packagist.org/downloads/",
"license": [
"GPL-2.0+"
],
"authors": [
{
"name": "Italo Mairo",
"homepage": "https://www.linkedin.com/in/italomairo/",
"role": "Maintanier of this Library Repo"
},
{
"name": "Patrick Hayes",
"homepage": "https://www.linkedin.com/in/patrickdhayes/",
"role": "Maintanier of original Repositary/Library (https://github.com/phayes/geoPHP)"
}
],
"description": "GeoPHP is a open-source native PHP library for doing geometry operations. It is written entirely in PHP and can therefore run on shared hosts. It can read and write a wide variety of formats: WKT (including EWKT), WKB (including EWKB), GeoJSON, KML, GPX, GeoRSS). It works with all Simple-Feature geometries (Point, LineString, Polygon, GeometryCollection etc.) and can be used to get centroids, bounding-boxes, area, and a wide variety of other useful information.",
"homepage": "https://github.com/itamair/geoPHP",
"support": {
"source": "https://github.com/itamair/geoPHP/tree/1.3"
},
"time": "2022-07-04T23:09:18+00:00"
},
{ {
"name": "laminas/laminas-diactoros", "name": "laminas/laminas-diactoros",
"version": "2.11.3", "version": "2.11.3",
...@@ -2819,6 +3539,90 @@ ...@@ -2819,6 +3539,90 @@
], ],
"time": "2021-11-16T10:29:06+00:00" "time": "2021-11-16T10:29:06+00:00"
}, },
{
"name": "league/csv",
"version": "9.8.0",
"source": {
"type": "git",
"url": "https://github.com/thephpleague/csv.git",
"reference": "9d2e0265c5d90f5dd601bc65ff717e05cec19b47"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/thephpleague/csv/zipball/9d2e0265c5d90f5dd601bc65ff717e05cec19b47",
"reference": "9d2e0265c5d90f5dd601bc65ff717e05cec19b47",
"shasum": ""
},
"require": {
"ext-json": "*",
"ext-mbstring": "*",
"php": "^7.4 || ^8.0"
},
"require-dev": {
"ext-curl": "*",
"ext-dom": "*",
"friendsofphp/php-cs-fixer": "^v3.4.0",
"phpstan/phpstan": "^1.3.0",
"phpstan/phpstan-phpunit": "^1.0.0",
"phpstan/phpstan-strict-rules": "^1.1.0",
"phpunit/phpunit": "^9.5.11"
},
"suggest": {
"ext-dom": "Required to use the XMLConverter and or the HTMLConverter classes",
"ext-iconv": "Needed to ease transcoding CSV using iconv stream filters"
},
"type": "library",
"extra": {
"branch-alias": {
"dev-master": "9.x-dev"
}
},
"autoload": {
"files": [
"src/functions_include.php"
],
"psr-4": {
"League\\Csv\\": "src"
}
},
"notification-url": "https://packagist.org/downloads/",
"license": [
"MIT"
],
"authors": [
{
"name": "Ignace Nyamagana Butera",
"email": "nyamsprod@gmail.com",
"homepage": "https://github.com/nyamsprod/",
"role": "Developer"
}
],
"description": "CSV data manipulation made easy in PHP",
"homepage": "https://csv.thephpleague.com",
"keywords": [
"convert",
"csv",
"export",
"filter",
"import",
"read",
"transform",
"write"
],
"support": {
"docs": "https://csv.thephpleague.com",
"issues": "https://github.com/thephpleague/csv/issues",
"rss": "https://github.com/thephpleague/csv/releases.atom",
"source": "https://github.com/thephpleague/csv"
},
"funding": [
{
"url": "https://github.com/sponsors/nyamsprod",
"type": "github"
}
],
"time": "2022-01-04T00:13:07+00:00"
},
{ {
"name": "masterminds/html5", "name": "masterminds/html5",
"version": "2.7.6", "version": "2.7.6",
......
id: article_csv_import
label: Import articles
migration_tags:
- CSV
migration_group: my_custom_migrate
source:
plugin: csv
path: public://import-sources/article.csv
ids:
[nid]
delimiter: ','
enclosure: '"'
header_row_count: 2
keys:
- nid
process:
langcode: langcode
type: type
status: status
uid: uid
title: title
created: created
changed: changed
default_langcode: default_langcode
path: path
body: body
field_image: field_image
field_tags: field_tags
destination:
plugin: entity:node
id: files
label: Migrate Files
migration_group: my_custom_migrate
source_type: Database
source:
plugin: files
key: migrate
destination:
plugin: 'entity:file'
source_base_path: https://drupal9-old.lndo.site
source_path_property: uri
urlencode: true
destination_path_property: uri
process:
filename: filename
uri: uri
filemime: filemime
status: status
created: timestamp
changed: timestamp
uid: uid
alt: alt
migration_dependencies:
required: {}
dependencies:
enforced:
module: {}
\ No newline at end of file
id: portfolio_csv_import
label: Import Portfolio
migration_tags:
- CSV
migration_group: my_custom_migrate
source:
plugin: csv
path: public://import-sources/portfolio.csv
ids:
[nid]
delimiter: ','
enclosure: '"'
header_row_count: 2
keys:
- nid
process:
langcode: langcode
type: type
status: status
uid: uid
title: title
created: created
changed: changed
default_langcode: default_langcode
metatag: metatag
path: path
menu_link: menu_link
content_translation_source: content_translation_source
content_translation_outdated: content_translation_outdated
field_aply_type: field_aply_type
field_author_simple: field_author_simple
field_background_foto: field_background_foto
field_broadcast_article_ref: field_broadcast_article_ref
field_content: field_content
field_country: field_country
field_co_founders_simple: field_co_founders_simple
field_founding_amount: field_founding_amount
field_founding_status: field_founding_status
field_founding_year: field_founding_year
field_github_legend: field_github_legend
field_github_url: field_github_url
field_graduated: field_graduated
field_localization: field_localization
field_organization: field_organization
field_theme: field_theme
field_thumbnail: field_thumbnail
destination:
plugin: entity:node
id: users
label: Migrate Users
migration_group: my_custom_migrate
source_type: Database
source:
plugin: users
key: migrate
destination:
plugin: entity:user
process:
uid: uid
name: name
pass: pass
mail: mail
created: created
status: status
field_first_name: field_first_name
field_last_name: field_last_name
field_job_role: field_job_role
field_mailing_address: field_mailing_address
migration_dependencies:
required: {}
dependencies:
enforced:
module: {}
\ No newline at end of file
<?php
namespace Drupal\uvf_migrate\Plugin\migrate\process;
use Drupal\Core\Plugin\ContainerFactoryPluginInterface;
use Drupal\migrate\MigrateExecutableInterface;
use Drupal\migrate\MigrateSkipRowException;
use Drupal\migrate\ProcessPluginBase;
use Drupal\migrate\Row;
use GuzzleHttp\Client;
use Symfony\Component\DependencyInjection\ContainerInterface;
/**
* Checks to see if a file exists.
*
* @MigrateProcessPlugin(
* id = "file_exists"
* )
*/
class FileExists extends ProcessPluginBase implements
ContainerFactoryPluginInterface
{
/**
* The Guzzle HTTP Client service.
*
* @var \GuzzleHttp\Client
*/
protected $httpClient;
/**
* Constructs a download process plugin.
*
* @param array $configuration
* The plugin configuration.
* @param string $plugin_id
* The plugin ID.
* @param mixed $plugin_definition
* The plugin definition.
* @param \GuzzleHttp\Client $http_client
* The HTTP client.
*/
public function __construct(
array $configuration,
$plugin_id,
$plugin_definition,
Client $http_client
) {
$configuration += [
'guzzle_options' => [],
];
parent::__construct($configuration, $plugin_id, $plugin_definition);
$this->httpClient = $http_client;
}
/**
* {@inheritdoc}
*/
public static function create(
ContainerInterface $container,
array $configuration,
$plugin_id,
$plugin_definition
) {
return new static(
$configuration,
$plugin_id,
$plugin_definition,
$container->get('http_client')
);
}
/**
* {@inheritdoc}
*/
public function transform(
$value,
MigrateExecutableInterface $migrate_executable,
Row $row,
$destination_property
) {
// Verify that the image exists.
try {
$this->httpClient->get(
$value,
$this->configuration['guzzle_options']
);
} catch (\Exception $e) {
// Guzzle throws an exception for anything but 200.
throw new MigrateSkipRowException(
'Skipping file: "' . $value . '".'
);
}
return $value;
}
}
<?php
namespace Drupal\uvf_migrate\Plugin\migrate\source;
use Drupal\migrate\Plugin\migrate\source\SqlBase;
use Drupal\migrate\Row;
/**
* Source plugin for Files (images, docs).
*
* @MigrateSource(
* id = "files"
* )
*/
class Files extends SqlBase
{
/**
* {@inheritdoc}
*/
public function query()
{
$file_types = [
'image/jpeg',
'image/png',
'image/gif',
'text/plain',
'application/pdf',
'application/msword',
'application/vnd.ms-excel',
'application/vnd.ms-powerpoint',
'application/vnd.download',
'application/octet-stream',
];
return $this->select('file_managed')
->fields('file_managed', array_keys($this->fields()))
// Ignore unpublished files.
->condition('status', '1', '=')
// Only interested in image files.
->condition('filemime', $file_types, 'IN');
}
/**
* {@inheritdoc}
*/
public function fields()
{
$fields = [
'fid' => $this->t('File ID'),
'uid' => $this->t('User ID'),
'filename' => $this->t('File name'),
'uri' => $this->t('File URI'),
'filemime' => $this->t('File MIME type'),
'created' => $this->t('File created date UNIX timestamp'),
];
return $fields;
}
/**
* {@inheritdoc}
*/
public function getIds()
{
return [
'fid' => [
'type' => 'integer',
],
];
}
/**
* {@inheritdoc}
*/
public function prepareRow(Row $row)
{
// Set the destination uri.
$row->setSourceProperty(
'destination_uri',
sprintf('public://%s', $row->getSourceProperty('filename'))
);
// Update filepath to remove public:// directory portion.
$original_path = $row->getSourceProperty('uri');
$new_path = str_replace(
'public://',
'https://drupal9-new.lndo.site/sites/default/files/',
$original_path
);
$row->setSourceProperty('filepath', $new_path);
return parent::prepareRow($row);
}
}
<?php
namespace Drupal\uvf_migrate\Plugin\migrate\source;
use Drupal\migrate\Row;
use Drupal\migrate\Plugin\migrate\source\SqlBase;
/**
* Drupal 9 user source from database.
*
* @MigrateSource(
* id = "users",
* source_module = "user"
* )
*/
class Users extends SqlBase
{
/**
* {@inheritdoc}
*/
public function query()
{
// return $this->select('users_field_data', 'u')
// ->fields('u')
// ->condition('u.uid', 0, '>');
$query = $this->select('users_field_data', 'u');
$query->fields('u', ['uid','name','pass','mail','created','status',]);
$query->condition('u.uid', 0, '>');
return $query;
}
/**
* {@inheritdoc}
*/
public function fields()
{
$fields = $this->baseFields();
$fields['field_first_name'] = $this->t('First Name');
$fields['field_last_name'] = $this->t('First Name');
$fields['field_job_role'] = $this->t('First Name');
$fields['field_mailing_address'] = $this->t('First Name');
return $fields;
}
/**
* {@inheritdoc}
*/
public function prepareRow(Row $row)
{
// $roles = $this->select('users_roles', 'ur')
// ->fields('ur', ['rid'])
// ->condition('ur.uid', $row->getSourceProperty('uid'))
// ->execute()
// ->fetchCol();
// $row->setSourceProperty('roles', $roles);
// $row->setSourceProperty(
// 'data',
// unserialize($row->getSourceProperty('data'))
// );
$uid = $row->getSourceProperty('uid');
$row->setSourceProperty('uid', $uid);
return parent::prepareRow($row);
}
/**
* {@inheritdoc}
*/
public function getIds()
{
return [
'uid' => [
'type' => 'integer',
'alias' => 'u',
],
];
}
/**
* {@inheritdoc}
*/
protected function baseFields()
{
$fields = array(
'uid' => $this->t('User ID'),
'name' => $this->t('Username'),
'pass' => $this->t('Password'),
'mail' => $this->t('Email'),
'created' => $this->t('Created On'),
'status' => $this->t('Status')
);
return $fields;
}
}
...@@ -12,7 +12,11 @@ function uvf_migrate_uninstall() { ...@@ -12,7 +12,11 @@ function uvf_migrate_uninstall() {
$configs = [ $configs = [
'migrate_plus.migration.article', 'migrate_plus.migration.article',
'migrate_plus.migration.custom_taxonomy_term', 'migrate_plus.migration.custom_taxonomy_term',
'migrate_plus.migration.custom_taxonomy_vocabulary' 'migrate_plus.migration.custom_taxonomy_vocabulary',
'migrate_plus.migration.files.yml',
'migrate_plus.migration.users.yml',
'migrate_plus.migration.article_csv_import.yml',
'migrate_plus.migration.portfolio_csv_import.yml'
]; ];
foreach($configs as $config){ foreach($configs as $config){
$delete = \Drupal::database()->delete('config') $delete = \Drupal::database()->delete('config')
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment