forked from UmayaWalpola/SkillXchange
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathSETUP_INSTRUCTIONS.txt
More file actions
134 lines (105 loc) Β· 4.59 KB
/
Copy pathSETUP_INSTRUCTIONS.txt
File metadata and controls
134 lines (105 loc) Β· 4.59 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
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
π HOW TO UPDATE YOUR DATABASE AND TEST THE SYSTEM
==================================================
## IMMEDIATE ACTION REQUIRED: Update Database
### Option 1: phpMyAdmin (Easiest)
1. Open phpMyAdmin in browser
2. Navigate to `skillxchange` database
3. Click the "SQL" tab at the top
4. Copy and paste THIS SQL code:
```sql
ALTER TABLE `project_applications` ADD COLUMN `experience` LONGTEXT NULL AFTER `message`;
ALTER TABLE `project_applications` ADD COLUMN `skills` LONGTEXT NULL AFTER `experience`;
ALTER TABLE `project_applications` ADD COLUMN `contribution` LONGTEXT NULL AFTER `skills`;
ALTER TABLE `project_applications` ADD COLUMN `commitment` VARCHAR(100) NULL AFTER `contribution`;
ALTER TABLE `project_applications` ADD COLUMN `duration` VARCHAR(100) NULL AFTER `commitment`;
ALTER TABLE `project_applications` ADD COLUMN `motivation` LONGTEXT NULL AFTER `duration`;
ALTER TABLE `project_applications` ADD COLUMN `portfolio` VARCHAR(500) NULL AFTER `motivation`;
ALTER TABLE `project_applications` ADD INDEX `idx_applied_at` (`applied_at`);
```
5. Click "Go" button
6. Wait for "Query executed successfully" message
### Option 2: File Upload
- Find file: `database/migrations/alter_project_applications.sql`
- Open it in phpMyAdmin SQL import
- Execute
## AFTER DATABASE UPDATE: Test the New System
### As Individual User:
1. Open browser, go to: http://localhost/SkillXchange/public/
2. Log in with individual account (e.g., user john@gmail.com)
3. Click "Projects" in sidebar
4. Click "View Details" on any project
5. Scroll down to "Join This Project" section
6. Click "Apply to Join This Project" button
7. Form expands with these fields:
- π Relevant Experience (required)
- π οΈ How Your Skills Match (required)
- π‘ How Will You Contribute (required)
- β±οΈ Time Commitment dropdown (required)
- π
Expected Duration dropdown (required)
- π― Why Are You Interested (required)
- π Portfolio/GitHub Link (optional)
- β I agree to project guidelines (required checkbox)
8. Fill in all fields and click "Submit Application"
9. You should see: "Application submitted successfully!"
### As Organization User:
1. Logout from individual account
2. Log in as organization (e.g., Pretty Software - ps@gmail.com)
3. Click "Applications" in left sidebar
4. You should see:
- Stats showing: Total, Pending, Accepted, Rejected counts
- The new pending applications with ALL details displayed:
* User avatar and name
* User email and rating
* Completed projects count
* π Full Relevant Experience
* π οΈ Full Skills Match section
* π‘ Full Contribution section
* π― Full Motivation
* β±οΈ Time Commitment + π
Duration
* π Clickable Portfolio Link
* Additional Notes
* Project name
* Accept/Reject buttons
5. Try clicking "Accept" or "Reject" buttons
## What's New?
β¨ **Advanced Application Form**
- Users provide comprehensive information instead of just a message
- 8 detailed fields with validation
- Better UX with tooltips and placeholders
π **Database Structure**
- `project_applications` table has 7 new columns:
- experience, skills, contribution, commitment
- duration, motivation, portfolio
- Old `message` field kept for backward compatibility
π¨ **Organization Dashboard Display**
- Beautiful card layout showing all application details
- Color-coded sections with emojis
- Clickable portfolio links
- Fully responsive mobile design
- Accept/Reject buttons for each application
## Troubleshooting
**Q: Form doesn't show new fields?**
A: Clear browser cache (Ctrl+Shift+Delete) and refresh page
**Q: Database update failed?**
A: Check for SQL syntax errors or column name conflicts
- Make sure you're in correct database
- Check column names don't already exist
**Q: Applications not showing in dashboard?**
A: Verify you:
1. Ran the SQL ALTER TABLE statements
2. Are logged in as organization that owns the projects
3. Have pending applications in database
**Q: Applications showing but no details?**
A: New applications submitted AFTER database update will show details
Old applications only have the message field
## Files Changed
Core Changes:
- β
app/controllers/ProjectApplicationController.php (apply method)
- β
app/models/Project.php (new applyToProjectAdvanced method)
- β
app/views/organization/applications.php (detailed display)
- β
public/assets/css/organizations.css (new styling)
Documentation:
- β
DATABASE_UPDATE_GUIDE.txt (this guide)
- β
database/migrations/alter_project_applications.sql
Database:
- β οΈ NEEDS UPDATE: project_applications table (run the SQL above!)