Closed alexborton closed 8 years ago
Hi Alex,
Sorry for the late response. The pagepart generator should normally work. In your case I would advise to create the pagepart manually. This is very easy.
entity/pageparts
folder. If you copy a existing one, you could use it as a starting point. Form/pageparts
Resources/views/PageParts
.Resource/config/pageparts
. Hope this helps. Feel free to ask if you have any more bundles problems.
I get same error. I was try generate a pagepart, and i get directory does not exists error.
Emre-MacBook-Pro:cms emreyilmaz$ php app/console kuma:generate:pagepart
Welcome to the Kunstmaan pagepart generator
This command helps you to generate a new pagepart.
The pagepart will be created for the OkulBilisimSiteBundle bundle.
You can add a prefix to the table names of the generated entities for example: projectname_bundlename_
Enter an underscore '_' if you don't want a prefix.
Tablename prefix [okulbilisim_sitebundle_]:
The name of your PagePart: For example: ContentBoxPagePart
PagePart name: AdvertPagePart
Instead of starting with a blank pagepart, you can add some fields now.
Available field types:
- Single line text
- Multi line text
- Wysiwyg
- Link (url, text, new window)
- Image (media, alt text)
- Media (File or Video or Slideshow)
- Single entity reference
- Multi entity reference
- Boolean
- Integer
- Decimal number
- DateTime
New field name (press <return> to stop adding fields): name
Field type:
[1 ] Single line text
[2 ] Multi line text
[3 ] Wysiwyg
[4 ] Link (url, text, new window)
[5 ] Image (media, alt text)
[6 ] Media (File or Video or Slideshow)
[7 ] Single entity reference
[8 ] Multi entity reference
[9 ] Boolean
[10] Integer
[11] Decimal number
[12] DateTime
> 1
New field name (press <return> to stop adding fields): startdate
Field type:
[1 ] Single line text
[2 ] Multi line text
[3 ] Wysiwyg
[4 ] Link (url, text, new window)
[5 ] Image (media, alt text)
[6 ] Media (File or Video or Slideshow)
[7 ] Single entity reference
[8 ] Multi entity reference
[9 ] Boolean
[10] Integer
[11] Decimal number
[12] DateTime
> 12
New field name (press <return> to stop adding fields): enddate
Field type:
[1 ] Single line text
[2 ] Multi line text
[3 ] Wysiwyg
[4 ] Link (url, text, new window)
[5 ] Image (media, alt text)
[6 ] Media (File or Video or Slideshow)
[7 ] Single entity reference
[8 ] Multi entity reference
[9 ] Boolean
[10] Integer
[11] Decimal number
[12] DateTime
> 12
New field name (press <return> to stop adding fields): image
Field type:
[1 ] Single line text
[2 ] Multi line text
[3 ] Wysiwyg
[4 ] Link (url, text, new window)
[5 ] Image (media, alt text)
[6 ] Media (File or Video or Slideshow)
[7 ] Single entity reference
[8 ] Multi entity reference
[9 ] Boolean
[10] Integer
[11] Decimal number
[12] DateTime
> 5
Do you want to limit the possible file types? Then specify a comma-seperated list of types (example: image/png,image/svg+xml), otherwise press ENTER:
Do you want to add validation of the dimensions of the media object? (y/n) [n]?
New field name (press <return> to stop adding fields): link
Field type:
[1 ] Single line text
[2 ] Multi line text
[3 ] Wysiwyg
[4 ] Link (url, text, new window)
[5 ] Image (media, alt text)
[6 ] Media (File or Video or Slideshow)
[7 ] Single entity reference
[8 ] Multi entity reference
[9 ] Boolean
[10] Integer
[11] Decimal number
[12] DateTime
> 4
New field name (press <return> to stop adding fields):
In which page section configuration file(s) do you want to add the pagepart (multiple possible, separated by comma):
[1] Main (main.yml)
> 1
Do you want to generate behat tests for this pagepart? (y/n) [y]? y
PagePart generation
Generating entity : OK
Generating form type : OK
Generating template : OK
Updating section config : OK
[InvalidArgumentException]
The "/www/cms/src/OkulBilisim/SiteBundle/Resources/config/pagetemplates/*.yml" directory does not exist.
kuma:generate:pagepart [--prefix[="..."]]
```
@jockri close
When trying to generate a new pagepart within a bundle, the process fails at the pagetemplates yml config update with the following message;
[InvalidArgumentException]
The "/Users/alex/Sites/freedomsat/src/Superrb/FreedomsatBundle/Resources/config/pagetemplates/*.yml" directory does
not exist.
I also noticed i was not prompted to enter which pages would be using the pagepart, as i normally would.
There are config yml's for the contentpage and homepage and behat-test-page in the folder in question; these have been there out the box since installation.
Regards