Esempio n. 1
0
         $field_name = "main." . $section_name . ".merge_cell_field_value";
         break;
     case 'relate':
     case 'link':
         $related_name = false;
         if (empty($mergeBeanArray[$id]->{$field_array}['name']) && !empty($mergeBeanArray[$id]->{$field_array}['id_name'])) {
             $related_name = get_related_name($field_array, $mergeBeanArray[$id]->{$field_array}['id_name']);
             if ($related_name !== false) {
                 $mergeBeanArray[$id]->{$field_array}['name'] = $related_name;
             }
         }
         display_field_value($mergeBeanArray[$id]->{$field_array}['name']);
         $field_name = "main." . $section_name . ".merge_cell_field_value";
         break;
     default:
         display_field_value($mergeBeanArray[$id]->{$field_array}['name']);
         $field_name = "main." . $section_name . ".merge_cell_field_value";
         break;
 }
 $json_data = array('field_name' => $field_array['name'], 'field_type' => $field_check);
 //add an array of fields/values to the json array
 //for setting all the values for merge
 if ($field_check == 'relate' or $field_check == 'link') {
     $temp_array = array();
     $json_data['popup_fields'] = array($field_array['name'] => $mergeBeanArray[$id]->{$field_array}['name'], $field_array['id_name'] => $mergeBeanArray[$id]->{$field_array}['id_name']);
 } else {
     if ($field_check == 'teamset') {
         $json_data['field_value'] = TeamSetManager::getCommaDelimitedTeams($mergeBeanArray[$id]->team_set_id, $mergeBeanArray[$id]->team_id, true);
         $json_data['field_value2'] = TeamSetManager::getTeamsFromSet($mergeBeanArray[$id]->team_set_id);
         $json_data['field_value3'] = $mergeBeanArray[$id]->team_set_id;
     } else {
Esempio n. 2
0
         break;
     case 'relate':
     case 'link':
         $related_name = false;
         $tempId = $field_array['id_name'];
         if (empty($mergeBeanArray[$id]->{$tempName}) && !empty($mergeBeanArray[$id]->{$tempId})) {
             $related_name = get_related_name($field_array, $mergeBeanArray[$id]->{$tempId});
             if ($related_name !== false) {
                 $mergeBeanArray[$id]->{$tempName} = $related_name;
             }
         }
         display_field_value($mergeBeanArray[$id]->{$tempName});
         $field_name = "main." . $section_name . ".merge_cell_field_value";
         break;
     default:
         display_field_value($mergeBeanArray[$id]->{$tempName});
         $field_name = "main." . $section_name . ".merge_cell_field_value";
         break;
 }
 $json_data = array('field_name' => $tempName, 'field_type' => $field_check);
 //add an array of fields/values to the json array
 //for setting all the values for merge
 if ($field_check == 'relate' or $field_check == 'link') {
     $temp_array = array();
     $tempId = $field_array['id_name'];
     $json_data['popup_fields'] = array($tempName => $mergeBeanArray[$id]->{$tempName}, $tempId => $mergeBeanArray[$id]->{$tempId});
 } else {
     if ($field_check == 'teamset') {
         $json_data['field_value'] = TeamSetManager::getCommaDelimitedTeams($mergeBeanArray[$id]->team_set_id, $mergeBeanArray[$id]->team_id, true);
         $json_data['field_value2'] = TeamSetManager::getTeamsFromSet($mergeBeanArray[$id]->team_set_id);
         $json_data['field_value3'] = $mergeBeanArray[$id]->team_set_id;