修改 - 质检

master
wangh 8 months ago
parent f12b4c9cd8
commit b7a63ab1f7

@ -67,7 +67,7 @@ public class BindingActivity extends BaseActivity {
OkGo.<String>post(url + s).tag(this).headers("Authorization", SharedPreferencesUtils.getstring("token", ""))
.params("boxCode", boxCode.get())
.params("innerCode", innerCode.get())
.params("loginName", SharedPreferencesUtils.getstring("loginName", ""))
.params("loginName", SharedPreferencesUtils.getstring("pdaName", ""))
.execute(new StringCallback() {
@Override
public void onSuccess(Response<String> response) {

@ -124,11 +124,12 @@ public class CheckActivity extends BaseActivity implements CheckAdapter.CheckIte
if (checkViewModel.getName() == null || checkViewModel.getName().isEmpty()) return;
checkViewModel.setList(submitList);
checkViewModel.setMeasure(submitList.isEmpty() ? "3" : "1");
checkViewModel.setUserName(SharedPreferencesUtils.getstring("userName", "pda01"));
checkViewModel.setUserName(SharedPreferencesUtils.getstring("pdaName", "pda01"));
checkViewModel.setTeamCode(SharedPreferencesUtils.getstring("teamCode",null));
OkGo.<Result>post(url + "/api/checkSubmit").tag(this)
.headers("Authorization", SharedPreferencesUtils.getstring("token", ""))
.upRequestBody(RequestBody.create(JSON, gson.toJson(checkViewModel))).execute(new MyRecultCall(dialog, this) {
.upRequestBody(RequestBody.create(JSON, gson.toJson(checkViewModel)))
.execute(new MyRecultCall(dialog, this) {
@Override
public void onSuccess(Response<Result> response) {
super.onSuccess(response);

@ -38,7 +38,7 @@ public class HomePageActivity extends AppCompatActivity {
InfoDialog infoDialog = new InfoDialog(this);
try {
User user = infoBeen.getUser();
user.setUsername(SharedPreferencesUtils.getstring("loginName", ""));
user.setUsername(SharedPreferencesUtils.getstring("pdaName", ""));
user.setTeamName(SharedPreferencesUtils.getstring("teamName", null));
user.setTeamCode(SharedPreferencesUtils.getstring("teamCode", null));
infoDialog.setInfoData(infoBeen, user);

@ -47,8 +47,8 @@ public class MainActivity extends BaseActivity {
ActivityMainBinding binding = DataBindingUtil.setContentView(this, R.layout.activity_main);
String loginName = SharedPreferencesUtils.getstring("loginName", "");
user = new User();
user.setUsername(loginName);
user.setPassword("123456");
// user.setUsername(loginName);
// user.setPassword("123456");
getSupportActionBar().hide(); // 隐藏原生标题栏
binding.setUser(user);
@ -76,7 +76,8 @@ public class MainActivity extends BaseActivity {
// 查询PDA Mac 地址列表
private void getPda() {
OkGo.<Result>get(url + "/report/pdaRecord/getPdaRecord").tag(this).headers("Authorization", SharedPreferencesUtils.getstring("token", "")).execute(new MyRecultCall(dialog, this) {
OkGo.<Result>get(url + "/report/pdaRecord/getPdaRecord").tag(this).headers("Authorization", SharedPreferencesUtils.getstring("token", ""))
.execute(new MyRecultCall(dialog, this) {
@Override
public void onSuccess(Response<Result> response) {
super.onSuccess(response);
@ -175,7 +176,7 @@ public class MainActivity extends BaseActivity {
Intent intent = new Intent(MainActivity.this, HomePageActivity.class);
intent.putExtra("role", loginBack.getRoles());
intent.putExtra("info", body);
SharedPreferencesUtils.putstring("loginName", user.username);
SharedPreferencesUtils.putstring("pdaName", user.username);
SharedPreferencesUtils.putstring("teamCode", user.getTeamCode());
SharedPreferencesUtils.putstring("teamName", user.getTeamName());
SharedPreferencesUtils.putstring("token", token);

@ -97,7 +97,7 @@ public class RepairActivity extends BaseActivity {
public void repairSubmit(View view) {
if (submitList.isEmpty()) return;
RepairSubmitInfo repairSubmitInfo =new RepairSubmitInfo(submitList,
SharedPreferencesUtils.getstring("userName", "pda01")
SharedPreferencesUtils.getstring("pdaName", "pda01")
,repairVm.getRepairName(),repairVm.getIsFlag());
MediaType JSON = MediaType.parse("application/json; charset=utf-8");
RequestBody body = RequestBody.create(JSON,gson.toJson(repairSubmitInfo) );

Loading…
Cancel
Save