完成能力测试的提交功能
This commit is contained in:
parent
a970c02393
commit
90d1237a22
2
.idea/misc.xml
generated
2
.idea/misc.xml
generated
@ -1,6 +1,6 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="ProjectRootManager" version="2" languageLevel="JDK_1_8" project-jdk-name="1.8" project-jdk-type="JavaSDK">
|
||||
<component name="ProjectRootManager" version="2" languageLevel="JDK_1_8" project-jdk-name="JDK" project-jdk-type="JavaSDK">
|
||||
<output url="file://$PROJECT_DIR$/build/classes" />
|
||||
</component>
|
||||
<component name="ProjectType">
|
||||
|
@ -3,6 +3,7 @@ apply plugin: 'com.android.application'
|
||||
android {
|
||||
compileSdkVersion 30
|
||||
buildToolsVersion "30.0.3"
|
||||
ndkVersion '23.0.7123448'
|
||||
|
||||
defaultConfig {
|
||||
applicationId "com.example.myapplication"
|
||||
|
@ -56,6 +56,7 @@ public class LoginActivity extends BaseActivity implements View.OnClickListener
|
||||
startActivity(forgetPaw);
|
||||
break;
|
||||
case R.id.tv_login:
|
||||
|
||||
Intent intent = new Intent(this, HomeActivity.class);
|
||||
startActivity(intent);
|
||||
break;
|
||||
|
@ -1,12 +1,18 @@
|
||||
package com.example.myapplication.adapter;
|
||||
|
||||
import android.content.Context;
|
||||
import android.util.Log;
|
||||
import android.view.LayoutInflater;
|
||||
import android.view.View;
|
||||
import android.view.ViewGroup;
|
||||
import android.widget.CheckBox;
|
||||
import android.widget.CompoundButton;
|
||||
import android.widget.ImageView;
|
||||
import android.widget.LinearLayout;
|
||||
import android.widget.RadioButton;
|
||||
import android.widget.RadioGroup;
|
||||
import android.widget.TextView;
|
||||
import android.widget.Toast;
|
||||
|
||||
import androidx.annotation.NonNull;
|
||||
import androidx.recyclerview.widget.RecyclerView;
|
||||
@ -14,36 +20,127 @@ import androidx.recyclerview.widget.RecyclerView;
|
||||
import com.bumptech.glide.Glide;
|
||||
import com.example.myapplication.R;
|
||||
import com.example.myapplication.bean.BolBean;
|
||||
import com.example.myapplication.bean.MeasureBean;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.LinkedHashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
public class CapacityMeasureAdapter extends RecyclerView.Adapter {
|
||||
public class CapacityMeasureAdapter extends RecyclerView.Adapter<CapacityMeasureAdapter.ViewHolder> {
|
||||
private List<BolBean> measureList = new ArrayList<>();
|
||||
private Context context;
|
||||
private Map<String, String> checkedMap;
|
||||
|
||||
public Map<String, String> getCheckedMap() {
|
||||
return checkedMap;
|
||||
}
|
||||
|
||||
public CapacityMeasureAdapter(Context context) {
|
||||
this.context = context;
|
||||
this.checkedMap = new LinkedHashMap<>();
|
||||
}
|
||||
|
||||
public void setMeasureList(List<BolBean> measureList) {
|
||||
this.measureList.addAll(measureList);
|
||||
notifyDataSetChanged();
|
||||
}
|
||||
|
||||
@NonNull
|
||||
@Override
|
||||
public RecyclerView.ViewHolder onCreateViewHolder(@NonNull ViewGroup parent, int viewType) {
|
||||
public ViewHolder onCreateViewHolder(@NonNull ViewGroup parent, int viewType) {
|
||||
final View inflate = LayoutInflater.from(context).inflate(R.layout.measure_item, parent, false);
|
||||
return new ViewHolder(inflate);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onBindViewHolder(@NonNull RecyclerView.ViewHolder holder, int position) {
|
||||
ViewHolder holder1 = (ViewHolder) holder;
|
||||
holder1.tvMeasure.setText((position+1)+measureList.get(position).getQuestion());
|
||||
public void onBindViewHolder(@NonNull ViewHolder holder, int position) {
|
||||
final boolean single = measureList.get(position).isSingle();//是否多选
|
||||
holder.tvMeasure.setText((position + 1) + measureList.get(position).getQuestion());
|
||||
if (single) {
|
||||
RadioGroup radioGroup = new RadioGroup(context);
|
||||
radioGroup.setOrientation(LinearLayout.VERTICAL);
|
||||
holder.llOption.addView(radioGroup);
|
||||
List<?> optionList = measureList.get(position).getOption();
|
||||
if (optionList != null && !optionList.isEmpty()) {
|
||||
for (int i = 0; i < optionList.size(); i++) {
|
||||
obtainOptionLayout(radioGroup, i, (String) optionList.get(i), true,measureList.get(position).getId());
|
||||
}
|
||||
}
|
||||
} else {
|
||||
List<?> optionList = measureList.get(position).getOption();
|
||||
if (optionList != null && !optionList.isEmpty()) {
|
||||
for (int i = 0; i < optionList.size(); i++) {
|
||||
obtainOptionLayout(holder.llOption, i, (String) optionList.get(i), false, measureList.get(position).getId());
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private void obtainOptionLayout(ViewGroup parentLayout, int optionIndex, String option, boolean isSingle, String questionId) {
|
||||
LinearLayout optionLayer = (LinearLayout) LayoutInflater.from(context).inflate(R.layout.capacity_measure_option, null);
|
||||
parentLayout.addView(optionLayer);
|
||||
RadioButton tvOptionIndex = optionLayer.findViewById(R.id.tv_option_layer_index);
|
||||
CheckBox cbOptionIndex = optionLayer.findViewById(R.id.cb_option_layer_index);
|
||||
if (isSingle) {//单选
|
||||
tvOptionIndex.setVisibility(View.VISIBLE);
|
||||
cbOptionIndex.setVisibility(View.GONE);
|
||||
tvOptionIndex.setText(getOptionIndex(optionIndex));
|
||||
} else {
|
||||
tvOptionIndex.setVisibility(View.GONE);
|
||||
cbOptionIndex.setVisibility(View.VISIBLE);
|
||||
cbOptionIndex.setText(getOptionIndex(optionIndex));
|
||||
}
|
||||
tvOptionIndex.setOnCheckedChangeListener(new CompoundButton.OnCheckedChangeListener() {
|
||||
@Override
|
||||
public void onCheckedChanged(CompoundButton buttonView, boolean isChecked) {
|
||||
if (isChecked) {
|
||||
checkedChangeRadioButton(parentLayout, buttonView);
|
||||
|
||||
Toast.makeText(context, "option" + option, Toast.LENGTH_SHORT).show();
|
||||
|
||||
updateCheckedMap(questionId, buttonView, parentLayout);
|
||||
}
|
||||
|
||||
}
|
||||
});
|
||||
cbOptionIndex.setOnCheckedChangeListener(new CompoundButton.OnCheckedChangeListener() {
|
||||
@Override
|
||||
public void onCheckedChanged(CompoundButton buttonView, boolean isChecked) {
|
||||
updateCheckedMap(questionId, buttonView, parentLayout);
|
||||
}
|
||||
});
|
||||
|
||||
ImageView ivOption = optionLayer.findViewById(R.id.iv_option_img);
|
||||
|
||||
TextView tvOptionContent = optionLayer.findViewById(R.id.tv_option_content);
|
||||
|
||||
if (option != null) {
|
||||
if (option.startsWith("http")) {
|
||||
Glide.with(context).load(option).into(ivOption);
|
||||
} else {
|
||||
tvOptionContent.setText(option);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private void checkedChangeRadioButton(ViewGroup group, CompoundButton currentButton) {
|
||||
if (group != null && group.getChildCount() > 0) {
|
||||
for (int i = 0; i < group.getChildCount(); i++) {
|
||||
if (group.getChildAt(i) instanceof ViewGroup) {
|
||||
checkedChangeRadioButton((ViewGroup) group.getChildAt(i), currentButton);
|
||||
} else if (group.getChildAt(i) instanceof CompoundButton && group.getChildAt(i).isShown() && group.getChildAt(i) != currentButton) {
|
||||
((CompoundButton) group.getChildAt(i)).setChecked(false);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
//indext内容
|
||||
private String getOptionIndex(int index) {
|
||||
char A = (char) (65 + index);
|
||||
return "选项" + A + ":";
|
||||
|
||||
|
||||
// Glide.with(context).load(measureList.get(position).getSingleChoice().get(0).getOption());
|
||||
}
|
||||
|
||||
@Override
|
||||
@ -53,28 +150,55 @@ public class CapacityMeasureAdapter extends RecyclerView.Adapter {
|
||||
|
||||
class ViewHolder extends RecyclerView.ViewHolder {
|
||||
TextView tvMeasure;
|
||||
TextView tvMeasure2;
|
||||
RadioButton tvMeasureA;
|
||||
RadioButton tvMeasureB;
|
||||
RadioButton tvMeasureC;
|
||||
RadioButton tvMeasureD;
|
||||
ImageView ivMeasureA;
|
||||
ImageView ivMeasureB;
|
||||
ImageView ivMeasureC;
|
||||
ImageView ivMeasureD;
|
||||
LinearLayout llOption;
|
||||
|
||||
public ViewHolder(@NonNull View itemView) {
|
||||
super(itemView);
|
||||
llOption = itemView.findViewById(R.id.ll_option);
|
||||
tvMeasure = itemView.findViewById(R.id.tv_measure_text1);
|
||||
tvMeasure2 = itemView.findViewById(R.id.tv_measure_text2);
|
||||
tvMeasureA = itemView.findViewById(R.id.rb_tv_measureA);
|
||||
tvMeasureB = itemView.findViewById(R.id.rb_tv_measureB);
|
||||
tvMeasureC = itemView.findViewById(R.id.rb_tv_measureC);
|
||||
tvMeasureD = itemView.findViewById(R.id.rb_tv_measureD);
|
||||
ivMeasureA = itemView.findViewById(R.id.iv_measureA);
|
||||
ivMeasureB = itemView.findViewById(R.id.iv_measureB);
|
||||
ivMeasureC = itemView.findViewById(R.id.iv_measureC);
|
||||
ivMeasureD = itemView.findViewById(R.id.iv_measureD);
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取被勾选的数据
|
||||
*/
|
||||
private void updateCheckedMap(String questionId, CompoundButton currentButton, ViewGroup group) {
|
||||
StringBuilder resultStr = null;
|
||||
if (group != null) {
|
||||
resultStr = new StringBuilder("");
|
||||
List<CompoundButton> resultList = new ArrayList<>();
|
||||
getCompoundButton(group, resultList);
|
||||
if (resultList != null && !resultList.isEmpty()) {
|
||||
for (int i = 0; i < resultList.size(); i++) {
|
||||
if (((CompoundButton) resultList.get(i)).isChecked()) {
|
||||
resultStr.append(i).append(",");
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
if (resultStr != null) {
|
||||
String result = "";
|
||||
if (resultStr.toString().length() > 0) {
|
||||
result = resultStr.substring(0, resultStr.length() - 1);
|
||||
}
|
||||
checkedMap.put(questionId, result);
|
||||
Log.d("checked", result);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取该viewGroup的所有子CompoundButton
|
||||
*/
|
||||
private void getCompoundButton(ViewGroup group, List<CompoundButton> compoundButtonList) {
|
||||
if (group != null) {
|
||||
for (int i = 0; i < group.getChildCount(); i++) {
|
||||
if (group.getChildAt(i) instanceof ViewGroup) {
|
||||
getCompoundButton((ViewGroup) group.getChildAt(i), compoundButtonList);
|
||||
} else if (group.getChildAt(i) instanceof CompoundButton && group.getChildAt(i).isShown()) {
|
||||
compoundButtonList.add((CompoundButton) group.getChildAt(i));
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -3,31 +3,31 @@ package com.example.myapplication.bean;
|
||||
import java.util.List;
|
||||
|
||||
public class BolBean {
|
||||
private long id;
|
||||
private String id;
|
||||
private String question;
|
||||
private List<?> option;
|
||||
private boolean isM;//是否多选
|
||||
private boolean isSingle;//是否多选
|
||||
|
||||
public BolBean(long id, String question, List<?> option, boolean isM) {
|
||||
public BolBean(String id, String question, List<?> option, boolean isM) {
|
||||
this.id = id;
|
||||
this.question = question;
|
||||
this.option = option;
|
||||
this.isM = isM;
|
||||
this.isSingle = isM;
|
||||
}
|
||||
|
||||
public boolean isM() {
|
||||
return isM;
|
||||
public boolean isSingle() {
|
||||
return isSingle;
|
||||
}
|
||||
|
||||
public void setM(boolean m) {
|
||||
isM = m;
|
||||
isSingle = m;
|
||||
}
|
||||
|
||||
public long getId() {
|
||||
public String getId() {
|
||||
return id;
|
||||
}
|
||||
|
||||
public void setId(long id) {
|
||||
public void setId(String id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
|
@ -0,0 +1,27 @@
|
||||
package com.example.myapplication.bean;
|
||||
|
||||
public class ExamBean {
|
||||
private String id;
|
||||
private String answer;
|
||||
|
||||
public ExamBean(String id, String answer) {
|
||||
this.id = id;
|
||||
this.answer = answer;
|
||||
}
|
||||
|
||||
public String getId() {
|
||||
return id;
|
||||
}
|
||||
|
||||
public void setId(String id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public String getAnswer() {
|
||||
return answer;
|
||||
}
|
||||
|
||||
public void setAnswer(String answer) {
|
||||
this.answer = answer;
|
||||
}
|
||||
}
|
@ -0,0 +1,62 @@
|
||||
package com.example.myapplication.bean;
|
||||
|
||||
public class ExamSubmitBean {
|
||||
/**
|
||||
* status :
|
||||
* msg :
|
||||
* body : {"grade":"0为不通过 1为通过 只有0和1"}
|
||||
*/
|
||||
|
||||
private String status;
|
||||
private String msg;
|
||||
private BodyBean body;
|
||||
|
||||
public String getStatus() {
|
||||
return status;
|
||||
}
|
||||
|
||||
public void setStatus(String status) {
|
||||
this.status = status;
|
||||
}
|
||||
|
||||
public String getMsg() {
|
||||
return msg;
|
||||
}
|
||||
|
||||
public void setMsg(String msg) {
|
||||
this.msg = msg;
|
||||
}
|
||||
|
||||
public BodyBean getBody() {
|
||||
return body;
|
||||
}
|
||||
|
||||
public void setBody(BodyBean body) {
|
||||
this.body = body;
|
||||
}
|
||||
|
||||
public static class BodyBean {
|
||||
/**
|
||||
* grade : 0为不通过 1为通过 只有0和1
|
||||
*/
|
||||
|
||||
private String grade;
|
||||
|
||||
public String getGrade() {
|
||||
return grade;
|
||||
}
|
||||
|
||||
public void setGrade(String grade) {
|
||||
this.grade = grade;
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "ExamSubmitBean{" +
|
||||
"status='" + status + '\'' +
|
||||
", msg='" + msg + '\'' +
|
||||
", body=" + body +
|
||||
'}';
|
||||
}
|
||||
}
|
@ -80,15 +80,15 @@ public class MeasureBean {
|
||||
* option : []
|
||||
*/
|
||||
|
||||
private long id;
|
||||
private String id;
|
||||
private String question;
|
||||
private List<?> option;
|
||||
|
||||
public long getId() {
|
||||
public String getId() {
|
||||
return id;
|
||||
}
|
||||
|
||||
public void setId(long id) {
|
||||
public void setId(String id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
@ -107,6 +107,15 @@ public class MeasureBean {
|
||||
public void setOption(List<?> option) {
|
||||
this.option = option;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "SingleChoiceBean{" +
|
||||
"id=" + id +
|
||||
", question='" + question + '\'' +
|
||||
", option=" + option +
|
||||
'}';
|
||||
}
|
||||
}
|
||||
|
||||
public static class MultiChoiceBean {
|
||||
@ -116,15 +125,15 @@ public class MeasureBean {
|
||||
* option : []
|
||||
*/
|
||||
|
||||
private long id;
|
||||
private String id;
|
||||
private String question;
|
||||
private List<?> option;
|
||||
|
||||
public long getId() {
|
||||
public String getId() {
|
||||
return id;
|
||||
}
|
||||
|
||||
public void setId(long id) {
|
||||
public void setId(String id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
@ -143,7 +152,33 @@ public class MeasureBean {
|
||||
public void setOption(List<?> option) {
|
||||
this.option = option;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "MultiChoiceBean{" +
|
||||
"id=" + id +
|
||||
", question='" + question + '\'' +
|
||||
", option=" + option +
|
||||
'}';
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "BodyBean{" +
|
||||
"title='" + title + '\'' +
|
||||
", singleChoice=" + singleChoice +
|
||||
", multiChoice=" + multiChoice +
|
||||
'}';
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "MeasureBean{" +
|
||||
"status=" + status +
|
||||
", msg='" + msg + '\'' +
|
||||
", body=" + body +
|
||||
'}';
|
||||
}
|
||||
}
|
||||
|
@ -16,6 +16,8 @@ import com.example.myapplication.adapter.CapacityMeasureAdapter;
|
||||
import com.example.myapplication.base.BaseFragment;
|
||||
import com.example.myapplication.bean.BolBean;
|
||||
import com.example.myapplication.bean.CapacityMeasureBean;
|
||||
import com.example.myapplication.bean.ExamBean;
|
||||
import com.example.myapplication.bean.ExamSubmitBean;
|
||||
import com.example.myapplication.bean.MeasureBean;
|
||||
import com.example.myapplication.http.Callback;
|
||||
import com.example.myapplication.http.HttpInterface;
|
||||
@ -24,10 +26,13 @@ import com.kongzue.dialog.interfaces.OnDialogButtonClickListener;
|
||||
import com.kongzue.dialog.util.BaseDialog;
|
||||
import com.kongzue.dialog.v3.MessageDialog;
|
||||
|
||||
import org.json.JSONArray;
|
||||
import org.json.JSONException;
|
||||
import org.json.JSONObject;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* 发现-能力测评条目点击进入测试页面
|
||||
@ -38,6 +43,7 @@ public class CapacityMeasurementFragment extends BaseFragment implements View.On
|
||||
private CapacityMeasureAdapter capacityMeasureAdapter;
|
||||
private ArrayList<BolBean> bolbean;
|
||||
private Button btn;
|
||||
private ArrayList<ExamBean> examBeans;
|
||||
|
||||
@Override
|
||||
protected int getLayout() {
|
||||
@ -48,13 +54,14 @@ public class CapacityMeasurementFragment extends BaseFragment implements View.On
|
||||
protected void initView() {
|
||||
super.initView();
|
||||
ivMeasurementFinish = (ImageView) findViewById(R.id.iv_measurement_finish);
|
||||
btn = findViewById(R.id.btn);
|
||||
btn.setOnClickListener(this::onClick);
|
||||
capacityMeasurementRel = (RecyclerView) findViewById(R.id.capacity_measurementRel);
|
||||
ivMeasurementFinish.setOnClickListener(this::onClick);
|
||||
capacityMeasurementRel.setLayoutManager(new LinearLayoutManager(getActivity()));
|
||||
capacityMeasureAdapter = new CapacityMeasureAdapter(getActivity());
|
||||
capacityMeasurementRel.setAdapter(capacityMeasureAdapter);
|
||||
btn = findViewById(R.id.btn);
|
||||
btn.setOnClickListener(this::onClick);
|
||||
|
||||
|
||||
}
|
||||
|
||||
@ -62,6 +69,7 @@ public class CapacityMeasurementFragment extends BaseFragment implements View.On
|
||||
protected void initData() {
|
||||
super.initData();
|
||||
bolbean = new ArrayList<>();
|
||||
examBeans = new ArrayList<>();
|
||||
|
||||
initNetWorks(true);
|
||||
}
|
||||
@ -69,7 +77,7 @@ public class CapacityMeasurementFragment extends BaseFragment implements View.On
|
||||
private void initNetWorks(boolean b) {
|
||||
OkGoBuilder.getInstance()
|
||||
.Builder(getActivity())
|
||||
.url(HttpInterface.MSG_LISt)
|
||||
.url(HttpInterface.EXAM_CONTENT)
|
||||
.method(OkGoBuilder.GET)
|
||||
.cls(MeasureBean.class)
|
||||
.json(new JSONObject())
|
||||
@ -78,9 +86,9 @@ public class CapacityMeasurementFragment extends BaseFragment implements View.On
|
||||
public void onSuccess(MeasureBean response, int id) {
|
||||
dismissLoadingDialog();
|
||||
//单选
|
||||
final List<MeasureBean.BodyBean.MultiChoiceBean> multiChoice = response.getBody().getMultiChoice();
|
||||
List<MeasureBean.BodyBean.MultiChoiceBean> multiChoice = response.getBody().getMultiChoice();
|
||||
//多选
|
||||
final List<MeasureBean.BodyBean.SingleChoiceBean> singleChoice1 = response.getBody().getSingleChoice();
|
||||
List<MeasureBean.BodyBean.SingleChoiceBean> singleChoice1 = response.getBody().getSingleChoice();
|
||||
if (multiChoice != null) {
|
||||
for (int i = 0; i < multiChoice.size(); i++) {
|
||||
bolbean.add(new BolBean(multiChoice.get(i).getId(), multiChoice.get(i).getQuestion(), multiChoice.get(i).getOption(), true));
|
||||
@ -96,8 +104,8 @@ public class CapacityMeasurementFragment extends BaseFragment implements View.On
|
||||
capacityMeasureAdapter.setMeasureList(bolbean);
|
||||
}
|
||||
|
||||
Log.d("TAG", "onSuccess: " + response.toString()+ "sssssssssssss");
|
||||
//Toast.makeText(getActivity(), response.getMsg() + "", Toast.LENGTH_SHORT).show();
|
||||
Log.d("TAG", "onSuccess: " + response.toString() + "sssssssssssss");
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
@ -116,14 +124,77 @@ public class CapacityMeasurementFragment extends BaseFragment implements View.On
|
||||
getActivity().finish();
|
||||
break;
|
||||
case R.id.btn:
|
||||
MessageDialog.show((AppCompatActivity) getActivity(),"提示","通过","确定","取消").setOkButton(new OnDialogButtonClickListener() {
|
||||
@Override
|
||||
public boolean onClick(BaseDialog baseDialog, View v) {
|
||||
// Toast.makeText(getContext(), "点击了确定", Toast.LENGTH_SHORT).show();
|
||||
return false;
|
||||
try {
|
||||
if (bolbean!=null){
|
||||
Map<String , String> checkedMap = capacityMeasureAdapter.getCheckedMap();
|
||||
for (int i = 0; i < bolbean.size(); i++) {
|
||||
final String id = bolbean.get(i).getId();
|
||||
if (!checkedMap.containsKey(id)||checkedMap.get(id)==null||("").equals(checkedMap.get(id))){
|
||||
Toast.makeText(getContext(), "有题目未填写答案,请仔细检查!", Toast.LENGTH_SHORT).show();
|
||||
return;
|
||||
}
|
||||
}
|
||||
for(Map.Entry<String , String> entry : checkedMap.entrySet()) {
|
||||
examBeans.add(new ExamBean(entry.getKey(),entry.getValue()));
|
||||
}
|
||||
initExamSubmit();
|
||||
}
|
||||
});
|
||||
} catch (JSONException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
private void initExamSubmit() throws JSONException {
|
||||
JSONArray jsonArray = new JSONArray();
|
||||
|
||||
for (int i = 0; i < examBeans.size(); i++) {
|
||||
JSONObject json = new JSONObject();
|
||||
json.put("id", examBeans.get(i).getId());
|
||||
json.put("answer", examBeans.get(i).getAnswer());
|
||||
jsonArray.put(json);
|
||||
}
|
||||
examBeans.clear();
|
||||
Log.d("TAG", "initExamSubmit: " + jsonArray.toString());
|
||||
OkGoBuilder.getInstance()
|
||||
.Builder(getActivity())
|
||||
.url(HttpInterface.EXAM_SUBMIT)
|
||||
.method(OkGoBuilder.POST)
|
||||
.cls(ExamSubmitBean.class)
|
||||
.jsonArray(jsonArray)
|
||||
.callback(new Callback<ExamSubmitBean>() {
|
||||
@Override
|
||||
public void onSuccess(ExamSubmitBean response, int id) {
|
||||
dismissLoadingDialog();
|
||||
Log.d("TAG", "onSuccess: " + response.toString()+ "sssssssssssss");
|
||||
if (response.getBody().getGrade().equals("0")){
|
||||
MessageDialog.show((AppCompatActivity) getActivity(),"提示","不通过","确定","取消").setOkButton(new OnDialogButtonClickListener() {
|
||||
@Override
|
||||
public boolean onClick(BaseDialog baseDialog, View v) {
|
||||
// Toast.makeText(getContext(), "点击了确定", Toast.LENGTH_SHORT).show();
|
||||
return false;
|
||||
}
|
||||
});
|
||||
}else {
|
||||
MessageDialog.show((AppCompatActivity) getActivity(),"提示","通过","确定","取消").setOkButton(new OnDialogButtonClickListener() {
|
||||
@Override
|
||||
public boolean onClick(BaseDialog baseDialog, View v) {
|
||||
// Toast.makeText(getContext(), "点击了确定", Toast.LENGTH_SHORT).show();
|
||||
return false;
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
//Toast.makeText(getActivity(), response.getMsg() + "", Toast.LENGTH_SHORT).show();
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onError(Throwable e, int id) {
|
||||
dismissLoadingDialog();
|
||||
Toast.makeText(getActivity(), e.getMessage(), Toast.LENGTH_SHORT).show();
|
||||
Log.d("TAG", "onError: " + e.getMessage());
|
||||
}
|
||||
}).build();
|
||||
}
|
||||
}
|
@ -74,7 +74,7 @@ public class TaskExplainFragment extends BaseFragment implements View.OnClickLis
|
||||
Intent itemIntent = new Intent(getActivity(), FragmentManagement.class);
|
||||
itemIntent.putExtra("tag", 10);
|
||||
startActivity(itemIntent);
|
||||
//Toast.makeText(getContext(), "你猜"+pos, Toast.LENGTH_SHORT).show();
|
||||
|
||||
}
|
||||
});
|
||||
}
|
||||
@ -105,7 +105,7 @@ public class TaskExplainFragment extends BaseFragment implements View.OnClickLis
|
||||
@Override
|
||||
public void onError(Throwable e, int id) {
|
||||
dismissLoadingDialog();
|
||||
Toast.makeText(getActivity(), e.getMessage(), Toast.LENGTH_SHORT).show();
|
||||
// Toast.makeText(getActivity(), e.getMessage(), Toast.LENGTH_SHORT).show();
|
||||
Log.d("TAG", "onError: " + e.getMessage());
|
||||
}
|
||||
}).build();
|
||||
|
5
app/src/main/res/drawable/login_bg.xml
Normal file
5
app/src/main/res/drawable/login_bg.xml
Normal file
@ -0,0 +1,5 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<selector xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item android:drawable="@drawable/shape_red_radius_bg" android:state_enabled="true"/>
|
||||
<item android:drawable="@drawable/shape_transparent_pink_radius_bg" android:state_enabled="false"/>
|
||||
</selector>
|
@ -0,0 +1,5 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<selector xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item android:drawable="@drawable/shape_red_radius_bg" android:state_selected="true" />
|
||||
<item android:drawable="@drawable/shape_transparent_pink_radius_bg" android:state_selected="false" />
|
||||
</selector>
|
6
app/src/main/res/drawable/shape_red_radius_bg.xml
Normal file
6
app/src/main/res/drawable/shape_red_radius_bg.xml
Normal file
@ -0,0 +1,6 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<shape xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<solid android:color="@color/colorPrimaryBlue" />
|
||||
|
||||
<corners android:radius="40dp" />
|
||||
</shape>
|
@ -0,0 +1,9 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<shape xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:visible="true">
|
||||
|
||||
<corners android:radius="40dp" />
|
||||
|
||||
<solid android:color="@color/white" />
|
||||
|
||||
</shape>
|
@ -120,7 +120,7 @@
|
||||
android:layout_width="300dp"
|
||||
android:layout_height="50dp"
|
||||
android:layout_marginTop="20dp"
|
||||
android:background="@drawable/shape_login"
|
||||
android:background="@drawable/selector_change_color_btn_bg"
|
||||
android:gravity="center"
|
||||
android:text="登录"
|
||||
android:textColor="@color/colorPrimaryDark"
|
||||
|
28
app/src/main/res/layout/capacity_measure_option.xml
Normal file
28
app/src/main/res/layout/capacity_measure_option.xml
Normal file
@ -0,0 +1,28 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical">
|
||||
|
||||
<RadioButton
|
||||
android:id="@+id/tv_option_layer_index"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content" />
|
||||
|
||||
<CheckBox
|
||||
android:id="@+id/cb_option_layer_index"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:visibility="gone" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_option_content"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/iv_option_img"
|
||||
android:layout_width="200dp"
|
||||
android:layout_height="100dp"
|
||||
android:src="@mipmap/top_bg" />
|
||||
</LinearLayout>
|
@ -25,35 +25,39 @@
|
||||
android:src="@drawable/ic_baseline_arrow" />
|
||||
</LinearLayout>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_capacity_measurement"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="20dp"
|
||||
android:text="POI任务测试"
|
||||
android:textColor="@color/colorGray"
|
||||
android:textSize="30sp"
|
||||
app:layout_constraintLeft_toLeftOf="@id/rl_capacity_measurement"
|
||||
app:layout_constraintRight_toRightOf="@id/rl_capacity_measurement"
|
||||
app:layout_constraintTop_toBottomOf="@+id/rl_capacity_measurement" />
|
||||
|
||||
<Button
|
||||
android:id="@+id/btn"
|
||||
android:layout_width="150dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="@drawable/shape_login"
|
||||
android:text="提交"
|
||||
android:layout_marginBottom="10dp"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
app:layout_constraintRight_toRightOf="parent" />
|
||||
|
||||
<androidx.recyclerview.widget.RecyclerView
|
||||
android:id="@+id/capacity_measurementRel"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
android:layout_marginLeft="10dp"
|
||||
android:layout_marginTop="10dp"
|
||||
app:layout_constraintBottom_toTopOf="@id/btn"
|
||||
app:layout_constraintTop_toBottomOf="@id/tv_capacity_measurement" />
|
||||
<TextView
|
||||
android:id="@+id/tv_capacity_measurement"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="20dp"
|
||||
android:text="POI任务测试"
|
||||
android:textColor="@color/colorGray"
|
||||
android:textSize="30sp"
|
||||
app:layout_constraintLeft_toLeftOf="@id/rl_capacity_measurement"
|
||||
app:layout_constraintRight_toRightOf="@id/rl_capacity_measurement"
|
||||
app:layout_constraintTop_toBottomOf="@+id/rl_capacity_measurement" />
|
||||
|
||||
<Button
|
||||
android:id="@+id/btn"
|
||||
android:layout_width="150dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginBottom="10dp"
|
||||
android:background="@drawable/shape_login"
|
||||
android:text="提交"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
app:layout_constraintRight_toRightOf="parent" />
|
||||
|
||||
<androidx.recyclerview.widget.RecyclerView
|
||||
android:id="@+id/capacity_measurementRel"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
android:layout_marginLeft="10dp"
|
||||
android:layout_marginTop="10dp"
|
||||
app:layout_constraintBottom_toTopOf="@id/btn"
|
||||
app:layout_constraintTop_toBottomOf="@id/tv_capacity_measurement" />
|
||||
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
@ -25,14 +25,22 @@
|
||||
android:src="@drawable/ic_baseline_arrow"
|
||||
/>
|
||||
</LinearLayout>
|
||||
<com.jcodecraeer.xrecyclerview.XRecyclerView
|
||||
android:id="@+id/task_capacity2_recycler"
|
||||
<androidx.core.widget.NestedScrollView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
app:layout_constraintTop_toBottomOf="@+id/rl_capacity2"
|
||||
app:layout_constraintTop_toBottomOf="@id/rl_capacity2"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
/>
|
||||
android:id="@+id/nsv">
|
||||
<com.jcodecraeer.xrecyclerview.XRecyclerView
|
||||
android:id="@+id/task_capacity2_recycler"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
app:layout_constraintTop_toBottomOf="@+id/rl_capacity2"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
/>
|
||||
</androidx.core.widget.NestedScrollView>
|
||||
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
7
app/src/main/res/layout/item_option_layer.xml
Normal file
7
app/src/main/res/layout/item_option_layer.xml
Normal file
@ -0,0 +1,7 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical">
|
||||
|
||||
</LinearLayout>
|
@ -2,191 +2,173 @@
|
||||
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent">
|
||||
android:layout_height="wrap_content">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_measure_text1"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="1、以下哪种拍图做法正确?"
|
||||
android:layout_marginLeft="15dp"
|
||||
android:text="1、以下哪种拍图做法正确?"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/ll_choose1"
|
||||
android:id="@+id/ll_option"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginLeft="20dp"
|
||||
android:orientation="vertical"
|
||||
app:layout_constraintTop_toBottomOf="@id/tv_measure_text1">
|
||||
|
||||
<RadioGroup
|
||||
android:layout_width="match_parent"
|
||||
android:layout_margin="10dp"
|
||||
android:layout_height="wrap_content">
|
||||
<RadioButton
|
||||
android:id="@+id/rb_tv_measureA"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="选项A:xxxx" />
|
||||
|
||||
<RadioButton
|
||||
android:id="@+id/rb_tv_measureB"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="选项B:xxxx" />
|
||||
|
||||
<RadioButton
|
||||
android:id="@+id/rb_tv_measureC"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="选项C:xxxx" />
|
||||
|
||||
<RadioButton
|
||||
android:id="@+id/rb_tv_measureD"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="选项D:xxxx" />
|
||||
</RadioGroup>
|
||||
</LinearLayout>
|
||||
<TextView
|
||||
android:id="@+id/tv_measure_text2"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="2、以下哪张图片正确?"
|
||||
app:layout_constraintTop_toBottomOf="@id/ll_choose1"
|
||||
app:layout_constraintLeft_toLeftOf="@id/tv_measure_text1"/>
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:id="@+id/ll_choose2"
|
||||
app:layout_constraintTop_toBottomOf="@id/tv_measure_text2"
|
||||
android:orientation="vertical">
|
||||
<RadioGroup
|
||||
android:layout_width="match_parent"
|
||||
android:layout_margin="10dp"
|
||||
android:layout_height="wrap_content">
|
||||
<LinearLayout
|
||||
android:id="@+id/ll_measureA"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
>
|
||||
<RadioButton
|
||||
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="选项A:"/>
|
||||
<ImageView
|
||||
android:layout_width="100dp"
|
||||
android:layout_height="100dp"
|
||||
android:src="@drawable/select_check"
|
||||
android:id="@+id/iv_measureA"
|
||||
/>
|
||||
</LinearLayout>
|
||||
<LinearLayout
|
||||
android:id="@+id/ll_measureB"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
>
|
||||
<RadioButton
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="选项A:"/>
|
||||
<ImageView
|
||||
android:layout_width="100dp"
|
||||
android:layout_height="100dp"
|
||||
android:src="@drawable/select_check"
|
||||
android:id="@+id/iv_measureB"/>
|
||||
</LinearLayout>
|
||||
<LinearLayout
|
||||
android:id="@+id/ll_measureC"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
>
|
||||
<RadioButton
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="选项A:"/>
|
||||
<ImageView
|
||||
android:layout_width="100dp"
|
||||
android:layout_height="100dp"
|
||||
android:src="@drawable/select_check"
|
||||
android:id="@+id/iv_measureC"/>
|
||||
</LinearLayout>
|
||||
<LinearLayout
|
||||
android:id="@+id/ll_measureD"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
>
|
||||
<RadioButton
|
||||
<!-- <LinearLayout-->
|
||||
<!-- android:id="@+id/ll_choose2"-->
|
||||
<!-- android:layout_width="match_parent"-->
|
||||
<!-- android:layout_height="wrap_content"-->
|
||||
<!-- android:orientation="vertical"-->
|
||||
<!-- android:visibility="gone"-->
|
||||
<!-- app:layout_constraintTop_toBottomOf="@id/tv_measure_text1">-->
|
||||
<!-- <LinearLayout-->
|
||||
<!-- android:id="@+id/ll_measureA"-->
|
||||
<!-- android:layout_width="match_parent"-->
|
||||
<!-- android:layout_height="wrap_content"-->
|
||||
<!-- android:orientation="vertical">-->
|
||||
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="选项A:"/>
|
||||
<ImageView
|
||||
android:layout_width="100dp"
|
||||
android:layout_height="100dp"
|
||||
android:src="@drawable/select_check"
|
||||
android:id="@+id/iv_measureD"/>
|
||||
</LinearLayout>
|
||||
<LinearLayout
|
||||
android:visibility="gone"
|
||||
android:id="@+id/ll_measureE"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
>
|
||||
<RadioButton
|
||||
<!-- <CheckBox-->
|
||||
<!-- android:id="@+id/cb_measureA"-->
|
||||
<!-- style="@style/Widget.AppCompat.CompoundButton.RadioButton"-->
|
||||
<!-- android:layout_width="match_parent"-->
|
||||
<!-- android:layout_height="wrap_content"-->
|
||||
<!-- android:text="选项A:" />-->
|
||||
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="选项A:"/>
|
||||
<ImageView
|
||||
android:layout_width="100dp"
|
||||
android:layout_height="100dp"
|
||||
android:src="@drawable/select_check"
|
||||
android:id="@+id/iv_measureE"/>
|
||||
</LinearLayout>
|
||||
<LinearLayout
|
||||
android:visibility="gone"
|
||||
android:id="@+id/ll_measureF"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
>
|
||||
<RadioButton
|
||||
<!-- <ImageView-->
|
||||
<!-- android:id="@+id/iv_measureA"-->
|
||||
<!-- android:layout_width="100dp"-->
|
||||
<!-- android:layout_height="100dp"-->
|
||||
<!-- android:src="@drawable/select_check" />-->
|
||||
<!-- </LinearLayout>-->
|
||||
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="选项A:"/>
|
||||
<ImageView
|
||||
android:layout_width="100dp"
|
||||
android:layout_height="100dp"
|
||||
android:src="@drawable/select_check"
|
||||
android:id="@+id/iv_measureF"/>
|
||||
</LinearLayout>
|
||||
<LinearLayout
|
||||
android:id="@+id/ll_measureG"
|
||||
android:visibility="gone"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
>
|
||||
<RadioButton
|
||||
<!-- <LinearLayout-->
|
||||
<!-- android:id="@+id/ll_measureB"-->
|
||||
<!-- android:layout_width="match_parent"-->
|
||||
<!-- android:layout_height="wrap_content"-->
|
||||
<!-- android:orientation="vertical">-->
|
||||
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="选项A:"/>
|
||||
<ImageView
|
||||
android:layout_width="100dp"
|
||||
android:layout_height="100dp"
|
||||
android:src="@drawable/select_check"
|
||||
android:id="@+id/iv_measureG"/>
|
||||
</LinearLayout>
|
||||
</RadioGroup>
|
||||
</LinearLayout>
|
||||
<!-- <CheckBox-->
|
||||
<!-- android:id="@+id/cb_measureB"-->
|
||||
<!-- style="@style/Widget.AppCompat.CompoundButton.RadioButton"-->
|
||||
<!-- android:layout_width="match_parent"-->
|
||||
<!-- android:layout_height="wrap_content"-->
|
||||
<!-- android:text="选项A:" />-->
|
||||
|
||||
<!-- <ImageView-->
|
||||
<!-- android:id="@+id/iv_measureB"-->
|
||||
<!-- android:layout_width="100dp"-->
|
||||
<!-- android:layout_height="100dp"-->
|
||||
<!-- android:src="@drawable/select_check" />-->
|
||||
<!-- </LinearLayout>-->
|
||||
|
||||
<!-- <LinearLayout-->
|
||||
<!-- android:id="@+id/ll_measureC"-->
|
||||
<!-- android:layout_width="match_parent"-->
|
||||
<!-- android:layout_height="wrap_content"-->
|
||||
<!-- android:orientation="vertical">-->
|
||||
|
||||
<!-- <CheckBox-->
|
||||
<!-- android:id="@+id/cb_measureC"-->
|
||||
<!-- style="@style/Widget.AppCompat.CompoundButton.RadioButton"-->
|
||||
<!-- android:layout_width="match_parent"-->
|
||||
<!-- android:layout_height="wrap_content"-->
|
||||
<!-- android:text="选项A:" />-->
|
||||
|
||||
<!-- <ImageView-->
|
||||
<!-- android:id="@+id/iv_measureC"-->
|
||||
<!-- android:layout_width="100dp"-->
|
||||
<!-- android:layout_height="100dp"-->
|
||||
<!-- android:src="@drawable/select_check" />-->
|
||||
<!-- </LinearLayout>-->
|
||||
|
||||
<!-- <LinearLayout-->
|
||||
<!-- android:id="@+id/ll_measureD"-->
|
||||
<!-- android:layout_width="match_parent"-->
|
||||
<!-- android:layout_height="wrap_content"-->
|
||||
<!-- android:orientation="vertical">-->
|
||||
|
||||
<!-- <CheckBox-->
|
||||
<!-- android:id="@+id/cb_measureD"-->
|
||||
<!-- style="@style/Widget.AppCompat.CompoundButton.RadioButton"-->
|
||||
<!-- android:layout_width="match_parent"-->
|
||||
<!-- android:layout_height="wrap_content"-->
|
||||
<!-- android:text="选项A:" />-->
|
||||
|
||||
<!-- <ImageView-->
|
||||
<!-- android:id="@+id/iv_measureD"-->
|
||||
<!-- android:layout_width="100dp"-->
|
||||
<!-- android:layout_height="100dp"-->
|
||||
<!-- android:src="@drawable/select_check" />-->
|
||||
<!-- </LinearLayout>-->
|
||||
|
||||
<!-- <LinearLayout-->
|
||||
<!-- android:id="@+id/ll_measureE"-->
|
||||
<!-- android:layout_width="match_parent"-->
|
||||
<!-- android:layout_height="wrap_content"-->
|
||||
<!-- android:orientation="vertical"-->
|
||||
<!-- android:visibility="gone">-->
|
||||
|
||||
<!-- <CheckBox-->
|
||||
<!-- style="@style/Widget.AppCompat.CompoundButton.RadioButton"-->
|
||||
<!-- android:id="@+id/cb_measureE"-->
|
||||
<!-- android:layout_width="match_parent"-->
|
||||
<!-- android:layout_height="wrap_content"-->
|
||||
<!-- android:text="选项A:" />-->
|
||||
|
||||
<!-- <ImageView-->
|
||||
<!-- android:id="@+id/iv_measureE"-->
|
||||
<!-- android:layout_width="100dp"-->
|
||||
<!-- android:layout_height="100dp"-->
|
||||
<!-- android:src="@drawable/select_check" />-->
|
||||
<!-- </LinearLayout>-->
|
||||
|
||||
<!-- <LinearLayout-->
|
||||
<!-- android:id="@+id/ll_measureF"-->
|
||||
<!-- android:layout_width="match_parent"-->
|
||||
<!-- android:layout_height="wrap_content"-->
|
||||
<!-- android:orientation="vertical"-->
|
||||
<!-- android:visibility="gone">-->
|
||||
|
||||
<!-- <RadioButton-->
|
||||
|
||||
<!-- android:layout_width="match_parent"-->
|
||||
<!-- android:layout_height="wrap_content"-->
|
||||
<!-- android:text="选项A:" />-->
|
||||
|
||||
<!-- <ImageView-->
|
||||
<!-- android:id="@+id/iv_measureF"-->
|
||||
<!-- android:layout_width="100dp"-->
|
||||
<!-- android:layout_height="100dp"-->
|
||||
<!-- android:src="@drawable/select_check" />-->
|
||||
<!-- </LinearLayout>-->
|
||||
|
||||
<!-- <LinearLayout-->
|
||||
<!-- android:id="@+id/ll_measureG"-->
|
||||
<!-- android:layout_width="match_parent"-->
|
||||
<!-- android:layout_height="wrap_content"-->
|
||||
<!-- android:orientation="vertical"-->
|
||||
<!-- android:visibility="gone">-->
|
||||
|
||||
<!-- <RadioButton-->
|
||||
|
||||
<!-- android:layout_width="match_parent"-->
|
||||
<!-- android:layout_height="wrap_content"-->
|
||||
<!-- android:text="选项A:" />-->
|
||||
|
||||
<!-- <ImageView-->
|
||||
<!-- android:id="@+id/iv_measureG"-->
|
||||
<!-- android:layout_width="100dp"-->
|
||||
<!-- android:layout_height="100dp"-->
|
||||
<!-- android:src="@drawable/select_check" />-->
|
||||
<!-- </LinearLayout>-->
|
||||
<!-- </LinearLayout>-->
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="match_parent"
|
||||
android:layout_height="match_parent">
|
||||
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
>
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
BIN
app/src/main/res/mipmap-mdpi/neibu.png
Normal file
BIN
app/src/main/res/mipmap-mdpi/neibu.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 444 B |
BIN
app/src/main/res/mipmap-mdpi/top_bg.png
Normal file
BIN
app/src/main/res/mipmap-mdpi/top_bg.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 16 KiB |
@ -42,4 +42,17 @@
|
||||
<item name="android:textSize">12sp</item>
|
||||
<item name="android:textColor">#EDBCBABA</item>
|
||||
</style>
|
||||
|
||||
<!-- 登录选择器-->
|
||||
<style name="sty1">
|
||||
<item name="android:background">#ffffff</item>
|
||||
<item name="android:textSize">15sp</item>
|
||||
</style>
|
||||
<style name="sty2" parent="@style/sty1">
|
||||
<item name="android:textColor">#471862</item>
|
||||
<item name="android:background">#03A9F4</item>
|
||||
</style>
|
||||
设置属性:
|
||||
|
||||
|
||||
</resources>
|
Loading…
x
Reference in New Issue
Block a user