Corrected failing pod tests
[catagits/Catalyst-Runtime.git] / lib / Catalyst / Manual / Tutorial.pod
1 =head1 NAME
2
3 Catalyst::Manual::Tutorial - Catalyst Tutorial: Overview
4
5 =head1 DESCRIPTION
6
7 The Catalyst framework is a flexible and comprehensive environment for
8 quickly building high-functionality web applications.  This tutorial is
9 designed to provide a rapid introduction to its basics and its most
10 commonly used features while focusing on real-world best practices.
11
12 The tutorial is divided into the following sections:
13
14 =over 4
15
16 =item *
17
18 L<Introduction|Catalyst::Manual::Tutorial::Intro>
19
20 =item * 
21
22 L<Catalyst Basics|Catalyst::Manual::Tutorial::CatalystBasics>
23
24 =item * 
25
26 L<Basic CRUD|Catalyst::Manual::Tutorial::BasicCRUD>
27
28 =item * 
29
30 L<Authentication|Catalyst::Manual::Tutorial::Authentication>
31
32 =item * 
33
34 L<Authorization|Catalyst::Manual::Tutorial::Authorization>
35
36 =item * 
37
38 L<Testing|Catalyst::Manual::Tutorial::Testing>
39
40 =item * 
41
42 L<Advanced CRUD|Catalyst::Manual::Tutorial::AdvancedCRUD>
43
44 =item * 
45
46 L<Appendices|Catalyst::Manual::Tutorial::Appendices>
47
48 =back
49
50 A tarball of the final application is available at
51 C<to_be_compled_in_final_version>.
52
53 =head1 Detailed Table Of Contents
54
55 =head2 Part 1: Introduction
56
57 =over 4
58
59 =item *
60
61 VERSIONS AND CONVENTIONS USED IN THIS TUTORIAL
62
63 =item *
64
65 CATALYST INSTALLATION
66
67 =item *
68
69 DATABASES
70
71 =item *
72
73 WHERE TO GET WORKING CODE
74
75 =back
76
77
78 =head2 Part 2: Catalyst Application Development Basics
79
80 =over 4
81
82 =item *
83
84 CREATE A CATALYST PROJECT
85
86 =item *
87
88 CREATE A SQLITE DATABASE
89
90 =item *
91
92 EDIT THE LIST OF CATALYST PLUGINS
93
94 =item *
95
96 DATABASE ACCESS WITH DBIx::Class
97
98 =item *
99
100 Create a DBIC Schema File
101
102 =item *
103
104 Create the DBIC ``Result Source'' Files
105
106 =item *
107
108 Use Catalyst::Model::DBIC::Schema to Load the Model Class
109
110     =item *
111
112 CREATE A CATALYST CONTROLLER
113
114 =item *
115
116 CATALYST VIEWS
117
118 =over 4
119
120 =item *
121
122 Create a Catalyst View Using TTSite
123
124 =item *
125
126 Globally Customize Every View
127
128 =item *
129
130 Create a TT Template Page
131
132 =back
133
134 =item *
135
136 RUN THE APPLICATION
137
138 =back
139
140 =head2 Part 3: Basic CRUD
141
142 =over 4
143
144 =item *
145
146 FORMLESS SUBMISSION
147
148 =over 4
149
150 =item *
151
152 Include a Create Action in the Books Controller
153
154 =item *
155
156 Include a Template for the url_create Action:
157
158 =item *
159
160 Try the url_create Feature
161
162 =back
163
164 =item *
165
166 MANUALLY BUILDING A CREATE FORM
167
168 =over 4
169
170 =item *
171
172 Add a Method to Display the Form
173
174 =item *
175
176 Add a Template for the Form
177
178 =item *
179
180 Add Method to Process Form Values and Update Database
181
182 =item *
183
184 Test Out the Form
185
186 =back
187
188 =item *
189
190 A SIMPLE DELETE FEATURE
191
192 =over 4
193
194 =item *
195
196 Include a Delete Link in the List
197
198 =item *
199
200 Add a Delete Action to the Controller
201
202 =item *
203
204 Try the Delete Feature
205
206 =back
207
208 =back
209
210 =head2 Part 4: Authentication
211
212 =over 4
213
214 =item *
215
216 BASIC AUTHENTICATION
217
218 =over 4
219
220 =item *
221
222 Add Users and Roles to the Database
223
224 =item *
225
226 Add User and Role Information to DBIC Schema
227
228 =item *
229
230 Create New ``Result Source Objects''
231
232 =item *
233
234 Sanity-Check Reload of Development Server
235
236 =item *
237
238 Include Authentication and Session Plugins
239
240 =item *
241
242 Configure Authentication
243
244 =item *
245
246 Add Login and Logout Controllers
247
248 =item *
249
250 Add a Login Form TT Template Page
251
252 =item *
253
254 Add Valid User Check
255
256 =item *
257
258 Displaying Content Only to Authenticated Users
259
260 =item *
261
262 Try Out Authentication
263
264 =back
265
266 =item *
267
268 USING PASSWORD HASHES
269
270 =over 4
271
272 =item *
273
274 Get a SHA-1 Hash for the Password
275
276 =item *
277
278 Switch to SHA-1 Password Hashes in the Database
279
280 =item *
281
282 Enable SHA-1 Hash Passwords in Catalyst::Plugin::Authentication::Store::DBIC
283
284 =item *
285
286 Try Out the Hashed Passwords
287
288 =back
289
290 =back
291
292 =head2 Part 5: Authorization
293
294 =over 4
295
296 =item *
297
298 BASIC AUTHORIZATION
299
300 =over 4
301
302 =item *
303
304 Update Plugins to Include Support for Authorization
305
306 =item *
307
308 Add Config Information for Authorization
309
310 =item *
311
312 Add Role-Specific Logic to the ``Book List'' Template
313
314 =item *
315
316 Limit Books::add to admin Users
317
318 =item *
319
320 Try Out Authentication And Authorization
321
322 =back
323
324 =item *
325
326 ENABLE ACL-BASED AUTHORIZATION
327
328 =over 4
329
330 =item *
331
332 Add the Catalyst::Plugin::Authorization::ACL Plugin
333
334 =item *
335
336 Add ACL Rules to the Application Class
337
338 =item *
339
340 Add a Method to Handle Access Violations
341
342 =back
343
344 =back
345
346 =head2 Part 6: Debugging
347
348 =over 4
349
350 =item *
351
352 LOG STATEMENTS
353
354 =item *
355
356 RUNNING CATALYST UNDER THE PERL DEBUGGER
357
358 =back
359
360 =head2 Part 7: Testing
361
362 =over 4
363
364 =item *
365
366 RUNNING THE "CANNED" CATALYST TESTS
367
368 =item *
369
370 RUNNING A SINGLE TEST
371
372 =item *
373
374 ADDING YOUR OWN TEST SCRIPT
375
376 =item *
377
378 SUPPORTING BOTH PRODUCTION AND TEST DATABASES
379
380 =back
381
382 =head2 Part 8: Advanced CRUD
383
384 =over 4
385
386 =item *
387
388 HTML::WIDGET FORM CREATION
389
390 =over 4
391
392 =item *
393
394 Add the HTML::Widget Plugin
395
396 =item *
397
398 Add a Form Creation Helper Method
399
400 =item *
401
402 Add Actions to Display and Save the Form
403
404 =item *
405
406 Update the CSS
407
408 =item *
409
410 Create a Template Page To Display The Form
411
412 =item *
413
414 Add Links for Create and Update via HTML::Widget
415
416 =item *
417
418 Test The <HTML::Widget> Create Form
419
420 =back
421
422 =item *
423
424 HTML::WIDGET VALIDATION AND FILTERING
425
426 =over 4
427
428 =item *
429
430 Add Constraints and Filters to the Widget Creation Method
431
432 =item *
433
434 Rebuild the Form Submission Method to Include Validation
435
436 =item *
437
438 Try Out the Form
439
440 =back
441
442 =item *
443
444 Enable DBIx::Class::HTMLWidget Support
445
446 =over 4
447
448 =item *
449
450 Add DBIx::Class::HTMLWidget to DBIC Model
451
452 =item *
453
454 Use populate_from_widget in hw_create_do
455
456 =back
457
458 =back
459
460 =head2 Part 9: Appendices
461
462 =over 4
463
464 =item *
465
466 APPENDIX 1: CUT AND PASTE FOR POD-BASED EXAMPLES
467
468 =over 4
469
470 =item *
471
472 "Un-indenting" with Vi/Vim
473
474 =item *
475
476 "Un-indenting" with Emacs
477
478 =back
479
480 =item *
481
482 APPENDIX 2: USING MYSQL AND POSTGRESQL
483
484 =over 4
485
486 =item *
487
488 MySQL
489
490 =item *
491
492 PostgreSQL
493
494 =back
495
496 =back
497