| 2 |
gabriel |
1 |
package com.cesams.twogetskills.fragment;
|
|
|
2 |
|
|
|
3 |
import android.os.Bundle;
|
|
|
4 |
|
| 11 |
gabriel |
5 |
import androidx.annotation.NonNull;
|
| 2 |
gabriel |
6 |
import androidx.fragment.app.Fragment;
|
|
|
7 |
import androidx.lifecycle.LifecycleOwner;
|
| 17 |
gabriel |
8 |
import androidx.lifecycle.ViewModelProvider;
|
| 2 |
gabriel |
9 |
import androidx.recyclerview.widget.GridLayoutManager;
|
|
|
10 |
import androidx.recyclerview.widget.RecyclerView;
|
|
|
11 |
|
| 13 |
gabriel |
12 |
import android.text.Editable;
|
|
|
13 |
import android.text.TextWatcher;
|
| 2 |
gabriel |
14 |
import android.util.Log;
|
|
|
15 |
import android.view.LayoutInflater;
|
| 11 |
gabriel |
16 |
import android.view.MotionEvent;
|
| 2 |
gabriel |
17 |
import android.view.View;
|
|
|
18 |
import android.view.ViewGroup;
|
| 11 |
gabriel |
19 |
import android.widget.AdapterView;
|
| 9 |
gabriel |
20 |
import android.widget.Button;
|
| 8 |
gabriel |
21 |
import android.widget.EditText;
|
| 9 |
gabriel |
22 |
import android.widget.ImageView;
|
|
|
23 |
import android.widget.ProgressBar;
|
| 2 |
gabriel |
24 |
import android.widget.TextView;
|
| 46 |
gabriel |
25 |
import android.widget.Toast;
|
| 2 |
gabriel |
26 |
|
| 9 |
gabriel |
27 |
import com.bumptech.glide.Glide;
|
|
|
28 |
import com.bumptech.glide.load.engine.DiskCacheStrategy;
|
|
|
29 |
import com.bumptech.glide.load.model.GlideUrl;
|
|
|
30 |
import com.bumptech.glide.load.model.LazyHeaders;
|
|
|
31 |
import com.bumptech.glide.request.RequestOptions;
|
|
|
32 |
import com.cesams.twogetskills.Constants;
|
| 2 |
gabriel |
33 |
import com.cesams.twogetskills.R;
|
|
|
34 |
import com.cesams.twogetskills.adapter.CapsuleListViewAdapter;
|
| 4 |
gabriel |
35 |
import com.cesams.twogetskills.adapter.TabsCapsulesAdapter;
|
| 2 |
gabriel |
36 |
import com.cesams.twogetskills.dao.CapsuleDao;
|
| 25 |
gabriel |
37 |
import com.cesams.twogetskills.dao.NotificationCenterDao;
|
| 2 |
gabriel |
38 |
import com.cesams.twogetskills.dao.ProgressDao;
|
| 16 |
gabriel |
39 |
import com.cesams.twogetskills.dao.SlideDao;
|
| 2 |
gabriel |
40 |
import com.cesams.twogetskills.dao.TopicDao;
|
|
|
41 |
import com.cesams.twogetskills.entity.Capsule;
|
|
|
42 |
import com.cesams.twogetskills.entity.Progress;
|
| 16 |
gabriel |
43 |
import com.cesams.twogetskills.entity.Slide;
|
| 2 |
gabriel |
44 |
import com.cesams.twogetskills.entity.Topic;
|
| 9 |
gabriel |
45 |
import com.cesams.twogetskills.library.MD5;
|
| 2 |
gabriel |
46 |
import com.cesams.twogetskills.skeleton.ITwoGetSkills;
|
| 17 |
gabriel |
47 |
import com.cesams.twogetskills.viewmodel.SlideRefreshUIViewModel;
|
| 12 |
gabriel |
48 |
import com.google.android.material.tabs.TabLayout;
|
| 2 |
gabriel |
49 |
|
| 24 |
gabriel |
50 |
import java.text.DateFormat;
|
| 21 |
gabriel |
51 |
import java.text.Normalizer;
|
| 24 |
gabriel |
52 |
import java.text.SimpleDateFormat;
|
| 2 |
gabriel |
53 |
import java.util.ArrayList;
|
| 9 |
gabriel |
54 |
import java.util.Calendar;
|
| 25 |
gabriel |
55 |
import java.util.Date;
|
| 2 |
gabriel |
56 |
import java.util.HashMap;
|
|
|
57 |
import java.util.List;
|
| 9 |
gabriel |
58 |
import java.util.Random;
|
|
|
59 |
import java.util.TimeZone;
|
| 2 |
gabriel |
60 |
|
|
|
61 |
/**
|
|
|
62 |
* A simple {@link Fragment} subclass.
|
|
|
63 |
* Use the {@link WelcomeFragment#newInstance} factory method to
|
|
|
64 |
* create an instance of this fragment.
|
|
|
65 |
*/
|
| 17 |
gabriel |
66 |
public class WelcomeFragment extends Fragment implements TabsCapsulesAdapter.ClickListener, LifecycleOwner {
|
| 2 |
gabriel |
67 |
|
| 10 |
gabriel |
68 |
TextView username, titulotarjeta, progresoporcentaje, empezar; ProgressBar progresotarjeta;
|
| 9 |
gabriel |
69 |
private ITwoGetSkills iTwoGetSkills; View card;
|
| 2 |
gabriel |
70 |
ArrayList<HashMap<String, String>> capsuleList;
|
| 11 |
gabriel |
71 |
ImageView imagetarjeta;
|
|
|
72 |
TabsCapsulesAdapter adapter2;
|
|
|
73 |
RecyclerView categorizados;
|
| 9 |
gabriel |
74 |
EditText busqueda; TextView textowelcome; Button continuar;
|
| 17 |
gabriel |
75 |
TabLayout tabs; String tabactual="pendientes"; private SlideRefreshUIViewModel mSlideRefreshUi;
|
| 2 |
gabriel |
76 |
|
| 17 |
gabriel |
77 |
|
| 2 |
gabriel |
78 |
public WelcomeFragment() {
|
|
|
79 |
// Required empty public constructor
|
|
|
80 |
}
|
|
|
81 |
|
|
|
82 |
public static WelcomeFragment newInstance() {
|
|
|
83 |
WelcomeFragment fragment = new WelcomeFragment();
|
|
|
84 |
return fragment;
|
|
|
85 |
}
|
|
|
86 |
|
|
|
87 |
@Override
|
|
|
88 |
public void onCreate(Bundle savedInstanceState) {
|
|
|
89 |
super.onCreate(savedInstanceState);
|
|
|
90 |
}
|
|
|
91 |
|
|
|
92 |
@Override
|
|
|
93 |
public View onCreateView(LayoutInflater inflater, ViewGroup container,
|
|
|
94 |
Bundle savedInstanceState) {
|
|
|
95 |
|
| 8 |
gabriel |
96 |
|
| 2 |
gabriel |
97 |
iTwoGetSkills = (ITwoGetSkills) getActivity();
|
| 8 |
gabriel |
98 |
iTwoGetSkills.showNavigationAndToolbar();
|
| 2 |
gabriel |
99 |
|
|
|
100 |
View view= inflater.inflate(R.layout.fragment_welcome, container, false);
|
|
|
101 |
|
|
|
102 |
username=view.findViewById(R.id.textView14);
|
| 8 |
gabriel |
103 |
textowelcome= view.findViewById(R.id.textView15);
|
|
|
104 |
busqueda=view.findViewById(R.id.busqueda);
|
| 12 |
gabriel |
105 |
card= view.findViewById(R.id.include); empezar= view.findViewById(R.id.titlenotifi); tabs=view.findViewById(R.id.tabLayout);
|
| 8 |
gabriel |
106 |
capsuleList = new ArrayList<>();
|
| 2 |
gabriel |
107 |
|
| 17 |
gabriel |
108 |
|
|
|
109 |
mSlideRefreshUi = new ViewModelProvider(requireActivity()).get(SlideRefreshUIViewModel.class);
|
|
|
110 |
|
|
|
111 |
|
|
|
112 |
|
|
|
113 |
|
| 9 |
gabriel |
114 |
//Tarjeta Principal
|
| 11 |
gabriel |
115 |
titulotarjeta = view.findViewById(R.id.description); progresotarjeta= view.findViewById(R.id.progressBar2); imagetarjeta= view.findViewById(R.id.imagelist);
|
| 9 |
gabriel |
116 |
continuar = view.findViewById(R.id.button); progresoporcentaje = view.findViewById(R.id.textView16);
|
|
|
117 |
|
|
|
118 |
|
| 2 |
gabriel |
119 |
username.setText("¡Hola, "+(iTwoGetSkills.getPreference().getFirstName() +"!"));
|
|
|
120 |
|
| 12 |
gabriel |
121 |
tabs.addOnTabSelectedListener(new TabLayout.OnTabSelectedListener() {
|
|
|
122 |
@Override
|
|
|
123 |
public void onTabSelected(TabLayout.Tab tab) {
|
|
|
124 |
int position=tab.getPosition();
|
| 2 |
gabriel |
125 |
|
| 12 |
gabriel |
126 |
capsuleList.clear();
|
|
|
127 |
adapter2.notifyDataSetChanged();
|
| 2 |
gabriel |
128 |
|
| 12 |
gabriel |
129 |
if(position==0)
|
|
|
130 |
{
|
| 13 |
gabriel |
131 |
tabactual="pendientes";
|
|
|
132 |
loadData(tabactual,"");
|
| 12 |
gabriel |
133 |
adapter2.notifyDataSetChanged();
|
|
|
134 |
}
|
|
|
135 |
else if(position==1)
|
|
|
136 |
{
|
| 13 |
gabriel |
137 |
tabactual="cursando";
|
|
|
138 |
loadData("cursando","");
|
| 12 |
gabriel |
139 |
adapter2.notifyDataSetChanged();
|
|
|
140 |
}
|
|
|
141 |
else if(position==2)
|
|
|
142 |
{
|
| 13 |
gabriel |
143 |
tabactual="finalizados";
|
|
|
144 |
loadData("finalizados","");
|
| 12 |
gabriel |
145 |
adapter2.notifyDataSetChanged();
|
|
|
146 |
}
|
|
|
147 |
}
|
|
|
148 |
|
|
|
149 |
@Override
|
|
|
150 |
public void onTabUnselected(TabLayout.Tab tab) {
|
|
|
151 |
|
|
|
152 |
}
|
|
|
153 |
|
|
|
154 |
@Override
|
|
|
155 |
public void onTabReselected(TabLayout.Tab tab) {
|
|
|
156 |
|
|
|
157 |
}
|
|
|
158 |
});
|
|
|
159 |
|
| 13 |
gabriel |
160 |
loadData("pendientes","");
|
| 12 |
gabriel |
161 |
|
| 8 |
gabriel |
162 |
busqueda.setOnFocusChangeListener(new View.OnFocusChangeListener() {
|
|
|
163 |
@Override
|
|
|
164 |
public void onFocusChange(View v, boolean hasFocus) {
|
|
|
165 |
if(hasFocus)
|
|
|
166 |
{
|
| 9 |
gabriel |
167 |
card.setVisibility(View.GONE);
|
| 8 |
gabriel |
168 |
username.setVisibility(View.GONE);
|
|
|
169 |
textowelcome.setVisibility(View.GONE);
|
| 34 |
gabriel |
170 |
Log.e("Tengo foco"," Oculto");
|
| 8 |
gabriel |
171 |
}
|
|
|
172 |
|
|
|
173 |
}
|
|
|
174 |
});
|
|
|
175 |
|
| 13 |
gabriel |
176 |
busqueda.addTextChangedListener(new TextWatcher() {
|
|
|
177 |
@Override
|
|
|
178 |
public void beforeTextChanged(CharSequence s, int start, int count, int after) {
|
| 8 |
gabriel |
179 |
|
| 13 |
gabriel |
180 |
}
|
|
|
181 |
|
|
|
182 |
@Override
|
|
|
183 |
public void onTextChanged(CharSequence s, int start, int before, int count) {
|
| 17 |
gabriel |
184 |
// Log.e("El texto","buscado: "+s);
|
| 13 |
gabriel |
185 |
capsuleList.clear();
|
|
|
186 |
adapter2.notifyDataSetChanged();
|
|
|
187 |
loadData(tabactual, s.toString());
|
|
|
188 |
}
|
|
|
189 |
|
|
|
190 |
@Override
|
|
|
191 |
public void afterTextChanged(Editable s) {
|
|
|
192 |
|
|
|
193 |
|
|
|
194 |
|
|
|
195 |
}
|
|
|
196 |
});
|
|
|
197 |
|
|
|
198 |
|
| 4 |
gabriel |
199 |
adapter2 = new TabsCapsulesAdapter(getContext(),capsuleList);
|
| 2 |
gabriel |
200 |
|
|
|
201 |
|
|
|
202 |
|
| 4 |
gabriel |
203 |
categorizados = view.findViewById(R.id.categorizados);
|
|
|
204 |
GridLayoutManager layoutcategoria = new GridLayoutManager(getContext(),1,GridLayoutManager.VERTICAL, false);
|
|
|
205 |
categorizados.setLayoutManager(layoutcategoria);
|
|
|
206 |
categorizados.setAdapter(adapter2);
|
|
|
207 |
|
| 11 |
gabriel |
208 |
|
| 17 |
gabriel |
209 |
adapter2.setClickListener(this);
|
| 11 |
gabriel |
210 |
|
| 8 |
gabriel |
211 |
categorizados.setOnFlingListener(new RecyclerView.OnFlingListener() {
|
|
|
212 |
@Override
|
|
|
213 |
public boolean onFling(int velocityX, int velocityY) {
|
|
|
214 |
|
|
|
215 |
if (categorizados.canScrollVertically(-1) ) {
|
|
|
216 |
|
| 17 |
gabriel |
217 |
// Log.e("Se activa", "On fling");
|
| 9 |
gabriel |
218 |
card.setVisibility(View.GONE);
|
| 8 |
gabriel |
219 |
username.setVisibility(View.GONE);
|
|
|
220 |
textowelcome.setVisibility(View.GONE);
|
|
|
221 |
}else
|
|
|
222 |
{
|
| 9 |
gabriel |
223 |
card.setVisibility(View.VISIBLE);
|
| 8 |
gabriel |
224 |
username.setVisibility(View.VISIBLE);
|
|
|
225 |
textowelcome.setVisibility(View.VISIBLE);
|
|
|
226 |
}
|
|
|
227 |
|
|
|
228 |
return false;
|
|
|
229 |
}
|
|
|
230 |
});
|
|
|
231 |
|
| 11 |
gabriel |
232 |
|
| 8 |
gabriel |
233 |
/* categorizados.setOnScrollChangeListener(new View.OnScrollChangeListener() {
|
|
|
234 |
@Override
|
|
|
235 |
public void onScrollChange(View v, int scrollX, int scrollY, int oldScrollX, int oldScrollY) {
|
|
|
236 |
|
|
|
237 |
if (!categorizados.canScrollVertically(-1)) {
|
|
|
238 |
// Toast.makeText(getActivity(), "Last", Toast.LENGTH_LONG).show();
|
|
|
239 |
capsulas.setVisibility(View.VISIBLE);
|
|
|
240 |
username.setVisibility(View.VISIBLE);
|
|
|
241 |
textowelcome.setVisibility(View.VISIBLE);
|
|
|
242 |
Log.e("On scroll"," se activa");
|
|
|
243 |
}
|
|
|
244 |
|
|
|
245 |
}
|
|
|
246 |
});
|
|
|
247 |
*/
|
| 21 |
gabriel |
248 |
getActivity().runOnUiThread(() -> {
|
|
|
249 |
String message = capsuleList.size() == 1
|
|
|
250 |
? "Hay 1 cápsula nueva disponible"
|
|
|
251 |
: "Tiene " + capsuleList.size() + " cápsulas pendientes para ver";
|
|
|
252 |
|
| 46 |
gabriel |
253 |
Toast.makeText(getContext(), ""+message, Toast.LENGTH_LONG).show();
|
| 25 |
gabriel |
254 |
|
| 53 |
gabriel |
255 |
iTwoGetSkills.saveNotificationCenter("Contenidos disponibles","",message);
|
|
|
256 |
|
| 21 |
gabriel |
257 |
});
|
| 2 |
gabriel |
258 |
return view;
|
|
|
259 |
}
|
|
|
260 |
|
| 9 |
gabriel |
261 |
@Override
|
|
|
262 |
public void onResume() {
|
|
|
263 |
super.onResume();
|
| 38 |
gabriel |
264 |
getActivity().runOnUiThread(() -> {
|
|
|
265 |
loadContinuecard();
|
|
|
266 |
});
|
| 9 |
gabriel |
267 |
}
|
| 2 |
gabriel |
268 |
|
| 9 |
gabriel |
269 |
@Override
|
|
|
270 |
public void onHiddenChanged(boolean hidden) {
|
|
|
271 |
super.onHiddenChanged(hidden);
|
|
|
272 |
|
| 17 |
gabriel |
273 |
// Log.e("TAG", "onHiddenChanged : " + (hidden ? "true" : "false"));
|
| 9 |
gabriel |
274 |
|
|
|
275 |
if(!hidden) {
|
| 27 |
gabriel |
276 |
// Log.e("Esta oculto", "el fragmento");
|
| 16 |
gabriel |
277 |
|
|
|
278 |
getActivity().runOnUiThread(() -> {
|
|
|
279 |
|
|
|
280 |
capsuleList.clear();
|
|
|
281 |
|
|
|
282 |
loadContinuecard();
|
|
|
283 |
loadData("pendientes","");
|
|
|
284 |
|
|
|
285 |
adapter2.notifyDataSetChanged();
|
|
|
286 |
|
|
|
287 |
tabs.getTabAt(0).select();
|
|
|
288 |
|
|
|
289 |
});
|
|
|
290 |
|
|
|
291 |
|
| 9 |
gabriel |
292 |
}
|
|
|
293 |
}
|
|
|
294 |
|
|
|
295 |
private void loadContinuecard(){
|
|
|
296 |
|
| 43 |
gabriel |
297 |
//Log.e("Cargo datos"," en tarjeta principal");
|
| 9 |
gabriel |
298 |
|
|
|
299 |
//Capsula de primera tarjeta
|
|
|
300 |
CapsuleDao capsuleDao = iTwoGetSkills.getDatabase().getCapsuleDao();
|
| 39 |
gabriel |
301 |
boolean continues=false;
|
| 9 |
gabriel |
302 |
Progress progress;
|
|
|
303 |
ProgressDao progressDao = iTwoGetSkills.getDatabase().getProgressDao();
|
|
|
304 |
|
| 17 |
gabriel |
305 |
|
| 9 |
gabriel |
306 |
List<Capsule> dbCapsules= capsuleDao.selectAll();
|
|
|
307 |
for(Capsule dbCapsule : dbCapsules)
|
|
|
308 |
{
|
|
|
309 |
progress = progressDao.selectByCapsuleUuid(dbCapsule.getUuid());
|
|
|
310 |
|
|
|
311 |
if (progress != null) {
|
|
|
312 |
|
| 10 |
gabriel |
313 |
if (progress.getProgress() < 100) {
|
| 43 |
gabriel |
314 |
// Log.e("Es menor"," a 100");
|
| 39 |
gabriel |
315 |
continues=true;
|
| 9 |
gabriel |
316 |
titulotarjeta.setText(dbCapsule.getName());
|
| 10 |
gabriel |
317 |
progresotarjeta.setVisibility(View.VISIBLE);
|
|
|
318 |
progresoporcentaje.setVisibility(View.VISIBLE);
|
| 9 |
gabriel |
319 |
progresotarjeta.setProgress((int) progress.getProgress());
|
|
|
320 |
progresoporcentaje.setText("" + progress.getProgress() + " %");
|
| 10 |
gabriel |
321 |
empezar.setText("En curso");
|
| 9 |
gabriel |
322 |
|
| 39 |
gabriel |
323 |
iTwoGetSkills.getPreference().setOrigennavigation("welcome");
|
|
|
324 |
|
| 38 |
gabriel |
325 |
int fragmentIdxActive = iTwoGetSkills.getPreference().getFragmentIdxActive();
|
|
|
326 |
|
|
|
327 |
if (fragmentIdxActive != Constants.IDX_FRAGMENT_WELCOME
|
|
|
328 |
) {
|
|
|
329 |
return;
|
|
|
330 |
}
|
| 26 |
gabriel |
331 |
iTwoGetSkills.getPreference().setCapsuleUuidActive(dbCapsule.getUuid());
|
| 38 |
gabriel |
332 |
// Log.e("La capsula","activa en loadcurso"+dbCapsule.getUuid());
|
|
|
333 |
|
| 26 |
gabriel |
334 |
iTwoGetSkills.getPreference().setTopicUuidActive(dbCapsule.getTopicUuid());
|
| 9 |
gabriel |
335 |
|
|
|
336 |
if (dbCapsule.getImage() != null && !dbCapsule.getImage().equals("")) {
|
|
|
337 |
|
|
|
338 |
TimeZone timeZone = TimeZone.getTimeZone("UTC");
|
|
|
339 |
Calendar calendar = Calendar.getInstance(timeZone);
|
|
|
340 |
TimeZone tz = calendar.getTimeZone();
|
|
|
341 |
int created = (int) (calendar.getTimeInMillis() / 1000);
|
|
|
342 |
|
|
|
343 |
Random random = new Random(created);
|
|
|
344 |
int rand = 1000 + random.nextInt(8999);
|
|
|
345 |
|
|
|
346 |
|
|
|
347 |
String deviceUuid = iTwoGetSkills.getPreference().getDeviceUuid();
|
|
|
348 |
String password = iTwoGetSkills.getPreference().getPassword();
|
|
|
349 |
|
|
|
350 |
|
|
|
351 |
String secret = MD5.generar(password + ':' + created + ':' + rand);
|
|
|
352 |
GlideUrl url = new GlideUrl(dbCapsule.getImage(), new LazyHeaders.Builder()
|
|
|
353 |
.addHeader(Constants.HTTP_HEADER_ACCEPT, Constants.HTTP_HEADER_ACCEPT_VALUE)
|
|
|
354 |
.addHeader(Constants.HTTP_HEADER_SECURITY_TOKEN, deviceUuid)
|
|
|
355 |
.addHeader(Constants.HTTP_HEADER_SECURITY_SECRET, secret)
|
|
|
356 |
.addHeader(Constants.HTTP_HEADER_SECURITY_CREATED, String.valueOf(created))
|
|
|
357 |
.addHeader(Constants.HTTP_HEADER_SECURITY_RAND, String.valueOf(rand))
|
|
|
358 |
.build());
|
|
|
359 |
|
|
|
360 |
RequestOptions options = new RequestOptions()
|
|
|
361 |
.diskCacheStrategy(DiskCacheStrategy.ALL);
|
|
|
362 |
|
|
|
363 |
Glide.with(getContext()).load(url)
|
|
|
364 |
.thumbnail()
|
|
|
365 |
.apply(options)
|
|
|
366 |
.into(imagetarjeta);
|
|
|
367 |
}
|
|
|
368 |
}
|
|
|
369 |
|
| 10 |
gabriel |
370 |
}
|
|
|
371 |
|
|
|
372 |
|
|
|
373 |
}
|
|
|
374 |
if(titulotarjeta.getText().equals(""))
|
|
|
375 |
{
|
| 17 |
gabriel |
376 |
// Log.e("Nombre","vacio");
|
| 37 |
gabriel |
377 |
SlideDao slideDao = iTwoGetSkills.getDatabase().getSlideDao();
|
| 10 |
gabriel |
378 |
|
| 37 |
gabriel |
379 |
|
| 10 |
gabriel |
380 |
//Despues del recorrido no se encontro progreso en ninguna capsula, por lo cual la tarjeta queda vacia
|
|
|
381 |
// vamos a llenarla con la ultima capsula, que debe ser nueva al no tener progreso
|
|
|
382 |
|
| 38 |
gabriel |
383 |
|
| 10 |
gabriel |
384 |
for(Capsule dbCapsule : dbCapsules)
|
|
|
385 |
{
|
| 37 |
gabriel |
386 |
List<Slide> slides = slideDao.selectAllByCapsuleUuid(dbCapsule.getUuid());
|
| 10 |
gabriel |
387 |
|
| 37 |
gabriel |
388 |
if (slides.isEmpty()) {
|
|
|
389 |
|
|
|
390 |
} else {
|
| 10 |
gabriel |
391 |
progress = progressDao.selectByCapsuleUuid(dbCapsule.getUuid());
|
| 38 |
gabriel |
392 |
|
| 37 |
gabriel |
393 |
// Log.e("Capsula","Es omitida, no tiene slides");
|
| 10 |
gabriel |
394 |
|
| 37 |
gabriel |
395 |
if (progress == null) {
|
| 10 |
gabriel |
396 |
|
| 37 |
gabriel |
397 |
// Log.e("Es nueva","");
|
| 10 |
gabriel |
398 |
|
|
|
399 |
titulotarjeta.setText(dbCapsule.getName());
|
|
|
400 |
progresotarjeta.setVisibility(View.INVISIBLE);
|
|
|
401 |
progresoporcentaje.setVisibility(View.INVISIBLE);
|
|
|
402 |
empezar.setText("Nueva");
|
|
|
403 |
continuar.setText("Ver cápsula");
|
|
|
404 |
|
| 39 |
gabriel |
405 |
iTwoGetSkills.getPreference().setOrigennavigation("welcome");
|
|
|
406 |
|
| 38 |
gabriel |
407 |
int fragmentIdxActive = iTwoGetSkills.getPreference().getFragmentIdxActive();
|
| 10 |
gabriel |
408 |
|
| 38 |
gabriel |
409 |
if (fragmentIdxActive != Constants.IDX_FRAGMENT_WELCOME
|
|
|
410 |
) {
|
|
|
411 |
return;
|
|
|
412 |
}
|
| 37 |
gabriel |
413 |
iTwoGetSkills.getPreference().setCapsuleUuidActive(dbCapsule.getUuid());
|
| 38 |
gabriel |
414 |
// Log.e("La capsula","activa en load"+dbCapsule.getUuid());
|
| 37 |
gabriel |
415 |
iTwoGetSkills.getPreference().setTopicUuidActive(dbCapsule.getTopicUuid());
|
| 26 |
gabriel |
416 |
|
| 37 |
gabriel |
417 |
if (dbCapsule.getImage() != null && !dbCapsule.getImage().equals("")) {
|
| 10 |
gabriel |
418 |
|
|
|
419 |
TimeZone timeZone = TimeZone.getTimeZone("UTC");
|
|
|
420 |
Calendar calendar = Calendar.getInstance(timeZone);
|
|
|
421 |
TimeZone tz = calendar.getTimeZone();
|
|
|
422 |
int created = (int) (calendar.getTimeInMillis() / 1000);
|
|
|
423 |
|
|
|
424 |
Random random = new Random(created);
|
|
|
425 |
int rand = 1000 + random.nextInt(8999);
|
|
|
426 |
|
|
|
427 |
|
|
|
428 |
String deviceUuid = iTwoGetSkills.getPreference().getDeviceUuid();
|
|
|
429 |
String password = iTwoGetSkills.getPreference().getPassword();
|
|
|
430 |
|
|
|
431 |
|
|
|
432 |
String secret = MD5.generar(password + ':' + created + ':' + rand);
|
|
|
433 |
GlideUrl url = new GlideUrl(dbCapsule.getImage(), new LazyHeaders.Builder()
|
|
|
434 |
.addHeader(Constants.HTTP_HEADER_ACCEPT, Constants.HTTP_HEADER_ACCEPT_VALUE)
|
|
|
435 |
.addHeader(Constants.HTTP_HEADER_SECURITY_TOKEN, deviceUuid)
|
|
|
436 |
.addHeader(Constants.HTTP_HEADER_SECURITY_SECRET, secret)
|
|
|
437 |
.addHeader(Constants.HTTP_HEADER_SECURITY_CREATED, String.valueOf(created))
|
|
|
438 |
.addHeader(Constants.HTTP_HEADER_SECURITY_RAND, String.valueOf(rand))
|
|
|
439 |
.build());
|
|
|
440 |
|
|
|
441 |
RequestOptions options = new RequestOptions()
|
|
|
442 |
.diskCacheStrategy(DiskCacheStrategy.ALL);
|
|
|
443 |
|
|
|
444 |
Glide.with(getContext()).load(url)
|
|
|
445 |
.thumbnail()
|
|
|
446 |
.apply(options)
|
|
|
447 |
.into(imagetarjeta);
|
|
|
448 |
}
|
|
|
449 |
|
|
|
450 |
}
|
| 37 |
gabriel |
451 |
}
|
| 10 |
gabriel |
452 |
|
| 38 |
gabriel |
453 |
}
|
| 10 |
gabriel |
454 |
|
|
|
455 |
|
|
|
456 |
|
| 38 |
gabriel |
457 |
}
|
| 39 |
gabriel |
458 |
else if (!titulotarjeta.getText().equals("") && !continues)
|
| 38 |
gabriel |
459 |
{
|
|
|
460 |
// Log.e("Nombre","vacio");
|
|
|
461 |
SlideDao slideDao = iTwoGetSkills.getDatabase().getSlideDao();
|
| 10 |
gabriel |
462 |
|
| 38 |
gabriel |
463 |
|
|
|
464 |
//Despues del recorrido no se encontro progreso en ninguna capsula, por lo cual la tarjeta queda vacia
|
|
|
465 |
// vamos a llenarla con la ultima capsula, que debe ser nueva al no tener progreso
|
|
|
466 |
|
|
|
467 |
|
|
|
468 |
for(Capsule dbCapsule : dbCapsules)
|
|
|
469 |
{
|
|
|
470 |
List<Slide> slides = slideDao.selectAllByCapsuleUuid(dbCapsule.getUuid());
|
|
|
471 |
|
|
|
472 |
if (slides.isEmpty()) {
|
|
|
473 |
|
|
|
474 |
} else {
|
|
|
475 |
progress = progressDao.selectByCapsuleUuid(dbCapsule.getUuid());
|
|
|
476 |
|
|
|
477 |
// Log.e("Capsula","Es omitida, no tiene slides");
|
|
|
478 |
|
|
|
479 |
if (progress == null) {
|
|
|
480 |
|
|
|
481 |
// Log.e("Es nueva","");
|
|
|
482 |
|
| 10 |
gabriel |
483 |
titulotarjeta.setText(dbCapsule.getName());
|
|
|
484 |
progresotarjeta.setVisibility(View.INVISIBLE);
|
|
|
485 |
progresoporcentaje.setVisibility(View.INVISIBLE);
|
|
|
486 |
empezar.setText("Nueva");
|
|
|
487 |
continuar.setText("Ver cápsula");
|
|
|
488 |
|
| 39 |
gabriel |
489 |
iTwoGetSkills.getPreference().setOrigennavigation("welcome");
|
|
|
490 |
|
|
|
491 |
|
| 38 |
gabriel |
492 |
int fragmentIdxActive = iTwoGetSkills.getPreference().getFragmentIdxActive();
|
|
|
493 |
|
|
|
494 |
if (fragmentIdxActive != Constants.IDX_FRAGMENT_WELCOME
|
|
|
495 |
) {
|
|
|
496 |
return;
|
|
|
497 |
}
|
| 10 |
gabriel |
498 |
iTwoGetSkills.getPreference().setCapsuleUuidActive(dbCapsule.getUuid());
|
| 38 |
gabriel |
499 |
// Log.e("La capsula","activa en load"+dbCapsule.getUuid());
|
| 10 |
gabriel |
500 |
iTwoGetSkills.getPreference().setTopicUuidActive(dbCapsule.getTopicUuid());
|
|
|
501 |
|
|
|
502 |
if (dbCapsule.getImage() != null && !dbCapsule.getImage().equals("")) {
|
|
|
503 |
|
|
|
504 |
TimeZone timeZone = TimeZone.getTimeZone("UTC");
|
|
|
505 |
Calendar calendar = Calendar.getInstance(timeZone);
|
|
|
506 |
TimeZone tz = calendar.getTimeZone();
|
|
|
507 |
int created = (int) (calendar.getTimeInMillis() / 1000);
|
|
|
508 |
|
|
|
509 |
Random random = new Random(created);
|
|
|
510 |
int rand = 1000 + random.nextInt(8999);
|
|
|
511 |
|
|
|
512 |
|
|
|
513 |
String deviceUuid = iTwoGetSkills.getPreference().getDeviceUuid();
|
|
|
514 |
String password = iTwoGetSkills.getPreference().getPassword();
|
|
|
515 |
|
|
|
516 |
|
|
|
517 |
String secret = MD5.generar(password + ':' + created + ':' + rand);
|
|
|
518 |
GlideUrl url = new GlideUrl(dbCapsule.getImage(), new LazyHeaders.Builder()
|
|
|
519 |
.addHeader(Constants.HTTP_HEADER_ACCEPT, Constants.HTTP_HEADER_ACCEPT_VALUE)
|
|
|
520 |
.addHeader(Constants.HTTP_HEADER_SECURITY_TOKEN, deviceUuid)
|
|
|
521 |
.addHeader(Constants.HTTP_HEADER_SECURITY_SECRET, secret)
|
|
|
522 |
.addHeader(Constants.HTTP_HEADER_SECURITY_CREATED, String.valueOf(created))
|
|
|
523 |
.addHeader(Constants.HTTP_HEADER_SECURITY_RAND, String.valueOf(rand))
|
|
|
524 |
.build());
|
|
|
525 |
|
|
|
526 |
RequestOptions options = new RequestOptions()
|
|
|
527 |
.diskCacheStrategy(DiskCacheStrategy.ALL);
|
|
|
528 |
|
|
|
529 |
Glide.with(getContext()).load(url)
|
|
|
530 |
.thumbnail()
|
|
|
531 |
.apply(options)
|
|
|
532 |
.into(imagetarjeta);
|
|
|
533 |
}
|
|
|
534 |
|
|
|
535 |
}
|
| 9 |
gabriel |
536 |
}
|
| 38 |
gabriel |
537 |
|
| 10 |
gabriel |
538 |
}
|
| 9 |
gabriel |
539 |
}
|
|
|
540 |
|
| 26 |
gabriel |
541 |
continuar.setOnClickListener(v -> {
|
| 10 |
gabriel |
542 |
|
|
|
543 |
|
| 23 |
gabriel |
544 |
// Log.e("Guardo",""+iTwoGetSkills.getPreference().getOrigenNavigation());
|
| 38 |
gabriel |
545 |
Log.e("Capsule","active"+iTwoGetSkills.getPreference().getCapsuleUuidActive());
|
| 9 |
gabriel |
546 |
iTwoGetSkills.invokeFragment(Constants.IDX_FRAGMENT_SLIDES);
|
|
|
547 |
});
|
|
|
548 |
|
|
|
549 |
//Fin de primer tarjeta
|
|
|
550 |
|
|
|
551 |
}
|
|
|
552 |
|
| 13 |
gabriel |
553 |
private void loadData(String tabposition, String buscar)
|
| 2 |
gabriel |
554 |
{
|
|
|
555 |
|
| 12 |
gabriel |
556 |
|
| 2 |
gabriel |
557 |
TopicDao topicDao = iTwoGetSkills.getDatabase().getTopicDao();
|
|
|
558 |
ArrayList<Topic> dbTopics = (ArrayList<Topic>) topicDao.selectAll();
|
|
|
559 |
|
|
|
560 |
List<Capsule> dbCapsules;
|
|
|
561 |
CapsuleDao capsuleDao = iTwoGetSkills.getDatabase().getCapsuleDao();
|
|
|
562 |
|
| 24 |
gabriel |
563 |
ProgressDao progressDao = iTwoGetSkills.getDatabase().getProgressDao();
|
|
|
564 |
SlideDao slideDao = iTwoGetSkills.getDatabase().getSlideDao();
|
| 9 |
gabriel |
565 |
|
|
|
566 |
|
| 24 |
gabriel |
567 |
if (tabposition.equals("pendientes"))
|
|
|
568 |
{
|
|
|
569 |
for (Topic dbTopic : dbTopics) {
|
| 9 |
gabriel |
570 |
|
| 24 |
gabriel |
571 |
dbCapsules = capsuleDao.selectAllByTopicUuidandOrder(dbTopic.getUuid());
|
| 2 |
gabriel |
572 |
|
| 24 |
gabriel |
573 |
Capsule capsule;
|
|
|
574 |
Progress progress;
|
| 2 |
gabriel |
575 |
|
| 24 |
gabriel |
576 |
HashMap<String, String> m_li;
|
| 9 |
gabriel |
577 |
|
| 2 |
gabriel |
578 |
|
|
|
579 |
|
| 24 |
gabriel |
580 |
for(Capsule dbCapsule : dbCapsules) {
|
|
|
581 |
capsule = new Capsule();
|
|
|
582 |
capsule.setTopicUuid(dbCapsule.getTopicUuid());
|
|
|
583 |
capsule.setUuid(dbCapsule.getUuid());
|
|
|
584 |
capsule.setName(dbCapsule.getName());
|
|
|
585 |
capsule.setDescription(dbCapsule.getDescription());
|
|
|
586 |
capsule.setImage(dbCapsule.getImage());
|
|
|
587 |
capsule.setPosition(dbCapsule.getPosition());
|
|
|
588 |
capsule.setUpdatedOn(dbCapsule.getUpdatedOn());
|
| 9 |
gabriel |
589 |
|
| 24 |
gabriel |
590 |
m_li = new HashMap<>();
|
| 9 |
gabriel |
591 |
|
| 2 |
gabriel |
592 |
|
| 24 |
gabriel |
593 |
//m_li.put("copyright",copy);
|
| 2 |
gabriel |
594 |
|
| 24 |
gabriel |
595 |
progress = progressDao.selectByCapsuleUuid(capsule.getUuid());
|
| 2 |
gabriel |
596 |
|
| 24 |
gabriel |
597 |
if (progress != null) {
|
|
|
598 |
capsule.setCompleted(progress.getCompleted());
|
|
|
599 |
capsule.setViewSlides(progress.getViewSlides());
|
| 2 |
gabriel |
600 |
|
| 24 |
gabriel |
601 |
capsule.setTotalSlides(progress.getTotalSlides());
|
|
|
602 |
capsule.setProgress(progress.getProgress());
|
|
|
603 |
capsule.setAddedOn(progress.getAddedOn());
|
| 2 |
gabriel |
604 |
|
| 24 |
gabriel |
605 |
// Log.e("Agregado en"," "+progress.getAddedOn());
|
|
|
606 |
// m_li.put("addedon",progress.getAddedOn());
|
|
|
607 |
m_li.put("view", String.valueOf(progress.getViewSlides()));
|
|
|
608 |
m_li.put("total", String.valueOf(progress.getTotalSlides()));
|
|
|
609 |
m_li.put("progress", String.valueOf(progress.getProgress()));
|
|
|
610 |
m_li.put("completado",String.valueOf(progress.getCompleted()));
|
|
|
611 |
m_li.put("agregado",progress.getAddedOn());
|
| 2 |
gabriel |
612 |
|
| 24 |
gabriel |
613 |
}
|
| 2 |
gabriel |
614 |
|
| 24 |
gabriel |
615 |
m_li.put("imagen", capsule.getImage());
|
|
|
616 |
m_li.put("nombre", capsule.getName());
|
|
|
617 |
m_li.put("uuid", capsule.getUuid());
|
|
|
618 |
m_li.put("topicuuid", capsule.getTopicUuid());
|
|
|
619 |
m_li.put("description", capsule.getDescription());
|
| 16 |
gabriel |
620 |
|
| 18 |
gabriel |
621 |
|
| 24 |
gabriel |
622 |
//Lleno la lista segun el requerimiento de filtro accionado por el usuario
|
| 2 |
gabriel |
623 |
|
| 24 |
gabriel |
624 |
List<Slide> slides = slideDao.selectAllByCapsuleUuid(capsule.getUuid());
|
| 2 |
gabriel |
625 |
|
| 24 |
gabriel |
626 |
if (slides.isEmpty()) {
|
| 13 |
gabriel |
627 |
|
| 24 |
gabriel |
628 |
// Log.e("Capsula","Es omitida, no tiene slides");
|
|
|
629 |
} else {
|
| 2 |
gabriel |
630 |
|
| 12 |
gabriel |
631 |
|
| 24 |
gabriel |
632 |
if (progress == null) {
|
| 18 |
gabriel |
633 |
|
| 24 |
gabriel |
634 |
if (buscar.equals("")) {
|
| 18 |
gabriel |
635 |
|
| 24 |
gabriel |
636 |
capsuleList.add(m_li);
|
| 16 |
gabriel |
637 |
|
| 13 |
gabriel |
638 |
|
| 24 |
gabriel |
639 |
} else {
|
|
|
640 |
String nombre= capsule.getName();
|
|
|
641 |
String normalizada= Normalizer.normalize(nombre, Normalizer.Form.NFD);
|
|
|
642 |
normalizada= normalizada.replaceAll("[^\\p{ASCII}]", "");
|
|
|
643 |
if (normalizada.matches("(?i).*" + buscar + ".*")) {
|
|
|
644 |
capsuleList.add(m_li);
|
|
|
645 |
}
|
| 21 |
gabriel |
646 |
|
| 16 |
gabriel |
647 |
}
|
| 13 |
gabriel |
648 |
|
| 16 |
gabriel |
649 |
}
|
| 12 |
gabriel |
650 |
|
| 24 |
gabriel |
651 |
}
|
| 12 |
gabriel |
652 |
|
| 24 |
gabriel |
653 |
}
|
| 16 |
gabriel |
654 |
|
|
|
655 |
|
| 13 |
gabriel |
656 |
|
| 24 |
gabriel |
657 |
}
|
| 13 |
gabriel |
658 |
|
| 24 |
gabriel |
659 |
}
|
|
|
660 |
else if (tabposition.equals("cursando"))
|
|
|
661 |
{
|
| 2 |
gabriel |
662 |
|
| 24 |
gabriel |
663 |
HashMap<String, String> m_li;
|
|
|
664 |
List<Progress> progress;
|
|
|
665 |
Capsule capsule;
|
| 2 |
gabriel |
666 |
|
| 13 |
gabriel |
667 |
|
|
|
668 |
|
| 24 |
gabriel |
669 |
progress = progressDao.selectAllCapsulesProgress();
|
|
|
670 |
|
|
|
671 |
for(Progress dbProgress : progress) {
|
|
|
672 |
m_li = new HashMap<>();
|
|
|
673 |
|
|
|
674 |
capsule = capsuleDao.selectByUuid(dbProgress.getCapsuleUuid());
|
|
|
675 |
|
|
|
676 |
m_li.put("view", String.valueOf(dbProgress.getViewSlides()));
|
|
|
677 |
m_li.put("total", String.valueOf(dbProgress.getTotalSlides()));
|
|
|
678 |
m_li.put("progress", String.valueOf(dbProgress.getProgress()));
|
|
|
679 |
m_li.put("completado",String.valueOf(dbProgress.getCompleted()));
|
|
|
680 |
m_li.put("agregado",dbProgress.getAddedOn());
|
|
|
681 |
|
|
|
682 |
|
|
|
683 |
m_li.put("imagen", capsule.getImage());
|
|
|
684 |
m_li.put("nombre", capsule.getName());
|
|
|
685 |
m_li.put("uuid", capsule.getUuid());
|
|
|
686 |
m_li.put("topicuuid", capsule.getTopicUuid());
|
|
|
687 |
m_li.put("description", capsule.getDescription());
|
|
|
688 |
|
|
|
689 |
|
|
|
690 |
//Log.e("Lista",""+m_li);
|
|
|
691 |
//Lleno la lista segun el requerimiento de filtro accionado por el usuario
|
|
|
692 |
|
|
|
693 |
List<Slide> slides = slideDao.selectAllByCapsuleUuid(capsule.getUuid());
|
|
|
694 |
|
|
|
695 |
if (slides.isEmpty()) {
|
|
|
696 |
|
|
|
697 |
// Log.e("Capsula","Es omitida, no tiene slides");
|
|
|
698 |
} else {
|
|
|
699 |
|
|
|
700 |
if(dbProgress.getProgress() <= 100 && dbProgress.getCompleted()==0)
|
|
|
701 |
{
|
|
|
702 |
if (buscar.equals("")) {
|
|
|
703 |
capsuleList.add(m_li);
|
|
|
704 |
|
|
|
705 |
} else {
|
|
|
706 |
String nombre= capsule.getName();
|
|
|
707 |
String normalizada= Normalizer.normalize(nombre, Normalizer.Form.NFD);
|
|
|
708 |
normalizada= normalizada.replaceAll("[^\\p{ASCII}]", "");
|
|
|
709 |
if (normalizada.matches("(?i).*" + buscar + ".*")) {
|
|
|
710 |
capsuleList.add(m_li);
|
| 12 |
gabriel |
711 |
}
|
| 2 |
gabriel |
712 |
|
| 12 |
gabriel |
713 |
}
|
| 24 |
gabriel |
714 |
}}
|
|
|
715 |
}}
|
| 2 |
gabriel |
716 |
|
| 24 |
gabriel |
717 |
else if (tabposition.equals("finalizados")){
|
| 12 |
gabriel |
718 |
|
| 24 |
gabriel |
719 |
HashMap<String, String> m_li;
|
|
|
720 |
List<Progress> progress;
|
|
|
721 |
Capsule capsule;
|
| 2 |
gabriel |
722 |
|
| 21 |
gabriel |
723 |
|
| 24 |
gabriel |
724 |
|
|
|
725 |
progress = progressDao.selectAllCapsulesProgress();
|
|
|
726 |
|
|
|
727 |
for(Progress dbProgress : progress) {
|
|
|
728 |
m_li = new HashMap<>();
|
|
|
729 |
|
|
|
730 |
capsule = capsuleDao.selectByUuid(dbProgress.getCapsuleUuid());
|
|
|
731 |
|
|
|
732 |
m_li.put("view", String.valueOf(dbProgress.getViewSlides()));
|
|
|
733 |
m_li.put("total", String.valueOf(dbProgress.getTotalSlides()));
|
|
|
734 |
m_li.put("progress", String.valueOf(dbProgress.getProgress()));
|
|
|
735 |
m_li.put("completado",String.valueOf(dbProgress.getCompleted()));
|
|
|
736 |
m_li.put("agregado",dbProgress.getAddedOn());
|
|
|
737 |
|
|
|
738 |
|
|
|
739 |
m_li.put("imagen", capsule.getImage());
|
|
|
740 |
m_li.put("nombre", capsule.getName());
|
|
|
741 |
m_li.put("uuid", capsule.getUuid());
|
|
|
742 |
m_li.put("topicuuid", capsule.getTopicUuid());
|
|
|
743 |
m_li.put("description", capsule.getDescription());
|
|
|
744 |
|
|
|
745 |
//Lleno la lista segun el requerimiento de filtro accionado por el usuario
|
|
|
746 |
|
|
|
747 |
List<Slide> slides = slideDao.selectAllByCapsuleUuid(capsule.getUuid());
|
|
|
748 |
|
|
|
749 |
if (slides.isEmpty()) {
|
|
|
750 |
|
|
|
751 |
// Log.e("Capsula","Es omitida, no tiene slides");
|
|
|
752 |
} else {
|
|
|
753 |
if(dbProgress.getProgress() >= 100 && dbProgress.getCompleted()==1){
|
|
|
754 |
|
|
|
755 |
if (buscar.equals("")) {
|
|
|
756 |
//capsule.getCompleted();
|
|
|
757 |
capsuleList.add(m_li);
|
|
|
758 |
|
|
|
759 |
} else {
|
|
|
760 |
String nombre= capsule.getName();
|
|
|
761 |
String normalizada= Normalizer.normalize(nombre, Normalizer.Form.NFD);
|
|
|
762 |
normalizada= normalizada.replaceAll("[^\\p{ASCII}]", "");
|
|
|
763 |
if (normalizada.matches("(?i).*" + buscar + ".*")) {
|
|
|
764 |
capsuleList.add(m_li);
|
|
|
765 |
}
|
|
|
766 |
|
|
|
767 |
}
|
|
|
768 |
}
|
| 2 |
gabriel |
769 |
}
|
| 24 |
gabriel |
770 |
}}
|
| 2 |
gabriel |
771 |
|
|
|
772 |
|
| 24 |
gabriel |
773 |
}
|
|
|
774 |
|
|
|
775 |
|
| 17 |
gabriel |
776 |
@Override
|
|
|
777 |
public void onItemClick(int position, View v) {
|
|
|
778 |
|
| 24 |
gabriel |
779 |
// Log.e("Evento","del click"+position);
|
| 17 |
gabriel |
780 |
|
|
|
781 |
|
|
|
782 |
iTwoGetSkills.getPreference().setCapsuleUuidActive(capsuleList.get(position).get("uuid"));
|
|
|
783 |
iTwoGetSkills.getPreference().setTopicUuidActive(capsuleList.get(position).get("topicuuid"));
|
|
|
784 |
iTwoGetSkills.invokeFragment(Constants.IDX_FRAGMENT_SLIDES);
|
|
|
785 |
|
| 18 |
gabriel |
786 |
iTwoGetSkills.getPreference().setOrigennavigation("welcome");
|
| 24 |
gabriel |
787 |
// Log.e("Completada",""+capsuleList.get(position).get("completado"));
|
| 18 |
gabriel |
788 |
|
| 17 |
gabriel |
789 |
// Log.e("Capsula","topic active"+mDataSet.get(viewHolder.getAbsoluteAdapterPosition()).get("topicuuid"));
|
|
|
790 |
|
|
|
791 |
}
|
| 2 |
gabriel |
792 |
}
|