-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathProcessRecipeInstallerConfig.php
More file actions
65 lines (62 loc) · 2.23 KB
/
ProcessRecipeInstallerConfig.php
File metadata and controls
65 lines (62 loc) · 2.23 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
<?php
class ProcessRecipeInstallerConfig extends ModuleConfig {
public function getDefaults() {
return array(
'recipesPath' => 'assets/recipes',
'recipesRepo' => 'https://github.com/processwire-recipes/Recipes.git',
'recipesParent' => '/recipes/',
'tagsParent' => '/recipe-tags/',
'authorsParent' => '/recipe-authors/',
);
}
public function __construct() {
$defaults = $this->getDefaults();
$this->add(array(
array(
'name' => 'recipesPath',
'label' => 'Recipes Path',
'description' => 'relative to the site directory',
'type' => 'text',
'required' => true,
'columnWidth' => 33,
'value' => $defaults['recipesPath'],
),
array(
'name' => 'recipesRepo',
'label' => 'Recipes Repo',
'description' => 'URL to Git repository, where version controlled text files reside',
'type' => 'text',
'required' => true,
'columnWidth' => 67,
'value' => $defaults['recipesRepo'],
),
array(
'name' => 'recipesParent',
'label' => 'Recipes parent page',
'description' => 'where repices reside',
'type' => 'text',
'required' => true,
'columnWidth' => 33,
'value' => $defaults['recipesParent'],
),
array(
'name' => 'tagsParent',
'label' => 'Tags parent page',
'description' => 'where tags reside',
'type' => 'text',
'required' => true,
'columnWidth' => 34,
'value' => $defaults['tagsParent'],
),
array(
'name' => 'authorsParent',
'label' => 'Authors parent page',
'description' => 'where authors reside',
'type' => 'text',
'required' => true,
'columnWidth' => 33,
'value' => $defaults['authorsParent'],
),
));
}
}