From 9559627382612bd2c8ed1df7f590d510a9bdae99 Mon Sep 17 00:00:00 2001 From: Mansimran7 Date: Tue, 2 Jul 2019 16:35:03 +0530 Subject: added all the .install files and views yml files --- modules/mansimran/chapters/chapters.install | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 modules/mansimran/chapters/chapters.install (limited to 'modules/mansimran/chapters/chapters.install') diff --git a/modules/mansimran/chapters/chapters.install b/modules/mansimran/chapters/chapters.install new file mode 100644 index 0000000..ed00b15 --- /dev/null +++ b/modules/mansimran/chapters/chapters.install @@ -0,0 +1,27 @@ + +getStorage('node'); + + + + // Query all entity. + $query = $queryFactory->get('node') +// <-- replace event in below line with your content type machine name + ->condition('type', 'student_chapter'); + $nids = $query->execute(); + + + + // Delete entities. + if (!empty($nids)) { + $entities = $nodeStorage->loadMultiple($nids); + $nodeStorage->delete($entities); + } +} + -- cgit