| | |
| | | |
| | | import com.anyun.exam.lib.AYSdk; |
| | | import com.anyun.exam.lib.MyLog; |
| | | import com.squareup.picasso.Picasso; |
| | | |
| | | import org.json.JSONException; |
| | | import org.json.JSONObject; |
| | | |
| | | import java.nio.charset.Charset; |
| | | import java.util.ArrayList; |
| | | import java.util.Collections; |
| | | import java.util.Date; |
| | |
| | | private TextView tv_speed,tv_total_score,tv_name, |
| | | tv_start_time,tv_coach_name; |
| | | private double speed=0.0; |
| | | private ImageView iv_head; |
| | | private ImageView iv_head,iv_coach_head; |
| | | |
| | | private int currTotalScore = 100; |
| | | private List<ScoreBean> mArrayList = new ArrayList<>(); |
| | |
| | | mHandler.obtainMessage(ADD_DATA).sendToTarget(); |
| | | if (examStatus.get(0).getStartExam() != Constant.NONE_BEEN_START_EXAM){ |
| | | btn_start_exam.setText("结束考试"); |
| | | iv_head.getDrawable().setLevel(1); |
| | | }else{ |
| | | btn_start_exam.setText("开始考试"); |
| | | iv_head.getDrawable().setLevel(0); |
| | | } |
| | | exam_type = examStatus.get(0).getStartExam(); |
| | | } |
| | |
| | | MyLog.i(TAG, "onChanged: " + student.toString()); |
| | | if (!TextUtils.isEmpty(student.getName())&&student.getStu_id()==ExamPlatformData.STU_ID){ |
| | | tv_name.setText(getNameColor(student.getName())); |
| | | Picasso.with(_mActivity).load(student.getHead_url()).into(iv_head); |
| | | ExamPlatformData.getInstance().setId(student.getID()); |
| | | tv_start_time.setText(getString(R.string.begin_time)+Utils.formatTimeYYMMDDHHmmSS(student.getBegin_time())); |
| | | }else if (!TextUtils.isEmpty(student.getName())&&student.getStu_id()==ExamPlatformData.COACH_ID){ |
| | | ExamPlatformData.getInstance().setCoachID(student.getID()); |
| | | tv_coach_name.setText(getNameColor(student.getName())); |
| | | Picasso.with(_mActivity).load(student.getHead_url()).into(iv_coach_head); |
| | | } |
| | | } |
| | | } |
| | |
| | | btn_ids.add(R.id.btn_9); |
| | | btn_ids.add(R.id.btn_10); |
| | | |
| | | view.findViewById(R.id.iv_head).setOnClickListener(this); |
| | | view.findViewById(R.id.iv_coach_head).setOnClickListener(this); |
| | | ((TextView)view.findViewById(R.id.tv_score_tip)).setText("当前考试得分"); |
| | | av_curve = view.findViewById(R.id.av3); |
| | | av_park = view.findViewById(R.id.av2); |
| | |
| | | |
| | | |
| | | iv_head = view.findViewById(R.id.iv_head); |
| | | iv_head.setOnClickListener(this); |
| | | iv_coach_head = view.findViewById(R.id.iv_coach_head); |
| | | iv_coach_head.setOnClickListener(this); |
| | | tv_speed = view.findViewById(R.id.tv_speed); |
| | | tv_total_score = view.findViewById(R.id.tv_total_score); |
| | | |
| | |
| | | case R.id.iv_head: |
| | | MyLog.i(TAG,"学员签到"); |
| | | if (ExamPlatformData.getInstance().IsStuSign()){ |
| | | |
| | | ExamPlatformData.getInstance().setStuSign(false); |
| | | qrcode(1,false); |
| | | }else{ |