Proyectos de Subversion LeadersLinked - Backend

Rev

Rev 16531 | Rev 16536 | Ir a la última revisión | Mostrar el archivo completo | | | Autoría | Ultima modificación | Ver Log |

Rev 16531 Rev 16535
Línea 126... Línea 126...
126
                $contactProgressRecordMapper = DiscoveryContactLogMapper::getInstance($this->adapter);
126
                $contactProgressRecordMapper = DiscoveryContactLogMapper::getInstance($this->adapter);
127
                $dailyProgress = $contactProgressRecordMapper->fetchAllDataByDateRange($currentUser->id, $startDate, $endDate);
127
                $dailyProgress = $contactProgressRecordMapper->fetchAllDataByDateRange($currentUser->id, $startDate, $endDate);
Línea 128... Línea 128...
128
 
128
 
129
 
129
 
130
                $total = count($dailyProgress);
130
                $total = count($dailyProgress);
131
                // $data = [
131
                $data = [
132
                //     'total_by_day' => [],
132
                    'total_by_day' => [],
133
                //     'added_on' => [],
133
                    'added_on' => [],
134
                //     'total' => [],
134
                    'total' => [],
135
                //     'first_name' => [],
135
                    'first_name' => [],
136
                //     'last_name' => [],
136
                    'last_name' => [],
137
                //     'email' => []
-
 
Línea 138... Línea 137...
138
                // ];
137
                    'email' => []
139
                $data = [];
138
                ];
140
 
139
 
141
                foreach ($dailyProgress as $record) {
140
                foreach ($dailyProgress as $record) {
142
                    $users = $record['user_id'];
141
                    $users = $record['user_id'];
143
                    $added_on = date("d-m-Y", strtotime($record['added_on']));
142
                    $added_on = date("d-m-Y", strtotime($record['added_on']));
144
                    $total = count($dailyProgress);
143
                    $total = count($dailyProgress);
145
                    $first_name = $record['first_name'];
144
                    $first_name = $record['first_name'];
146
                    $last_name = $record['last_name'];
145
                    $last_name = $record['last_name'];
147
                    $email = $record['email'];
146
                    $email = $record['email'];
148
                    // array_push($data['total_by_day'], $users);
147
                    array_push($data['total_by_day'], $users);
149
                    // array_push($data['added_on'], $added_on);
148
                    array_push($data['added_on'], $added_on);
150
                    // array_push($data['total'], $total);
149
                    array_push($data['total'], $total);
151
                    // array_push($data['first_name'], $first_name);
-
 
152
                    // array_push($data['last_name'], $last_name);
-
 
153
                    // array_push($data['email'], $email);
-
 
154
                    $data = [
-
 
155
                        'total_by_day' => $users,
-
 
156
                        'added_on' => $added_on,
-
 
157
                        'total' => $total,
-
 
158
                        'first_name' =>  $first_name,
-
 
159
                        'last_name' => $last_name,
150
                    array_push($data['first_name'], $first_name);
Línea 160... Línea 151...
160
                        'email' => $email,
151
                    array_push($data['last_name'], $last_name);
161
                    ];
152
                    array_push($data['email'], $email);