| @@ 41-53 (lines=13) @@ | ||
| 38 | $mission->name = $edit_form['name']; |
|
| 39 | ||
| 40 | // If the organization tree is loaded, then the custom dropdown values will be processed and stored. |
|
| 41 | if(mo_get_tree_root()) { |
|
| 42 | $department_string = mo_get_last_input_node($edit_form); |
|
| 43 | $department_paths = mo_string_all_ancestors($department_string); |
|
| 44 | $mission->department = $department_string; |
|
| 45 | $mission->department_path_english = $department_paths['english_path']; |
|
| 46 | $mission->department_path_french = $department_paths['french_path']; |
|
| 47 | } |
|
| 48 | // If the organization tree is not loaded, then the basic free text entry will be stored. |
|
| 49 | else { |
|
| 50 | $mission->department = $edit_form['department']; |
|
| 51 | $mission->department_path_english = $edit_form['department']; |
|
| 52 | $mission->department_path_french = $edit_form['department']; |
|
| 53 | } |
|
| 54 | ||
| 55 | $mission->email = $edit_form['email']; |
|
| 56 | $mission->phone = $edit_form['phone']; |
|
| @@ 57-69 (lines=13) @@ | ||
| 54 | $mission->name = $first_form['name']; |
|
| 55 | ||
| 56 | // If the organization tree is loaded, then the custom dropdown values will be processed and stored. |
|
| 57 | if(mo_get_tree_root()) { |
|
| 58 | $department_string = mo_get_last_input_node($first_form); |
|
| 59 | $department_paths = mo_string_all_ancestors($department_string); |
|
| 60 | $mission->department = $department_string; |
|
| 61 | $mission->department_path_english = $department_paths['english_path']; |
|
| 62 | $mission->department_path_french = $department_paths['french_path']; |
|
| 63 | } |
|
| 64 | // If the organization tree is not loaded, then the basic free text entry will be stored. |
|
| 65 | else { |
|
| 66 | $mission->department = $first_form['department']; |
|
| 67 | $mission->department_path_english = $first_form['department']; |
|
| 68 | $mission->department_path_french = $first_form['department']; |
|
| 69 | } |
|
| 70 | ||
| 71 | $mission->email = $first_form['email']; |
|
| 72 | $mission->phone = $first_form['phone']; |
|
| @@ 823-835 (lines=13) @@ | ||
| 820 | $mission->name = $first_form['name']; |
|
| 821 | ||
| 822 | // If the organization tree is loaded, then the custom dropdown values will be processed and stored. |
|
| 823 | if(mo_get_tree_root()) { |
|
| 824 | $department_string = mo_get_last_input_node($first_form); |
|
| 825 | $department_paths = mo_string_all_ancestors($department_string); |
|
| 826 | $mission->department = $department_string; |
|
| 827 | $mission->department_path_english = $department_paths['english_path']; |
|
| 828 | $mission->department_path_french = $department_paths['french_path']; |
|
| 829 | } |
|
| 830 | // If the organization tree is not loaded, then the basic free text entry will be stored. |
|
| 831 | else { |
|
| 832 | $mission->department = $first_form['department']; |
|
| 833 | $mission->department_path_english = $first_form['department']; |
|
| 834 | $mission->department_path_french = $first_form['department']; |
|
| 835 | } |
|
| 836 | ||
| 837 | $mission->email = $first_form['email']; |
|
| 838 | $mission->phone = $first_form['phone']; |
|