angular_js_example-8.x-1.x-dev/angular_js_example.install
angular_js_example.install
<?php
/**
* @file
* This file create the schema for the books table.
*/
/**
* Implements hook_schema().
*/
function angular_js_example_schema() {
$schema['angular_js_example_books'] = [
'fields' => [
'bid' => [
'description' => 'The primary key always unique.',
'type' => 'serial',
'unsigned' => TRUE,
'not null' => TRUE,
],
'bookname' => [
'type' => 'varchar',
'length' => '255',
'not null' => FALSE,
],
'bookprice' => [
'type' => 'varchar',
'length' => '255',
'not null' => FALSE,
],
'authorid' => [
'type' => 'varchar',
'length' => '255',
'not null' => FALSE,
],
],
'primary key' => ['bid'],
];
return $schema;
}
