|
|
@ -91,7 +91,6 @@ public class MainActivity extends BaseActivity { |
|
|
public static List<String> workList; |
|
|
public static List<String> workList; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@Override |
|
|
@Override |
|
|
protected int setLayoutId() { |
|
|
protected int setLayoutId() { |
|
|
return R.layout.act_main; |
|
|
return R.layout.act_main; |
|
|
@ -123,13 +122,14 @@ public class MainActivity extends BaseActivity { |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
private void MobileAppSchemaRpc_Load() { |
|
|
private void MobileAppSchemaRpc_Load() { |
|
|
ViewOnClickTask mobileTask = new ViewOnClickTask(this,"加载中...") { |
|
|
|
|
|
|
|
|
ViewOnClickTask mobileTask = new ViewOnClickTask(this, "加载中...") { |
|
|
RpcObject rpcObj; |
|
|
RpcObject rpcObj; |
|
|
|
|
|
|
|
|
@Override |
|
|
@Override |
|
|
protected void successUI() { |
|
|
protected void successUI() { |
|
|
if (rpcObj.getString("Content")!=null){ |
|
|
|
|
|
|
|
|
if (rpcObj.getString("Content") != null) { |
|
|
Gson gson = new Gson(); |
|
|
Gson gson = new Gson(); |
|
|
MobileBean mobileBean = gson.fromJson(rpcObj.getString("Content"),MobileBean.class); |
|
|
|
|
|
|
|
|
MobileBean mobileBean = gson.fromJson(rpcObj.getString("Content"), MobileBean.class); |
|
|
|
|
|
|
|
|
homepageList = mobileBean.getHomepage().getFunctions(); |
|
|
homepageList = mobileBean.getHomepage().getFunctions(); |
|
|
workList = mobileBean.getWork().getFunctions(); |
|
|
workList = mobileBean.getWork().getFunctions(); |
|
|
@ -320,13 +320,18 @@ public class MainActivity extends BaseActivity { |
|
|
private void checkOptionMenu() { |
|
|
private void checkOptionMenu() { |
|
|
if (null != aMenu) { |
|
|
if (null != aMenu) { |
|
|
if (optionMenuOn) { |
|
|
if (optionMenuOn) { |
|
|
if (indexFlag == 0) { |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (homepageList.contains("001")) { |
|
|
aMenu.findItem(R.id.shangpin_xiaoxi).setVisible(true); |
|
|
aMenu.findItem(R.id.shangpin_xiaoxi).setVisible(true); |
|
|
|
|
|
} else { |
|
|
|
|
|
aMenu.findItem(R.id.shangpin_xiaoxi).setVisible(false); |
|
|
|
|
|
} |
|
|
|
|
|
if (homepageList.contains("002")) { |
|
|
aMenu.findItem(R.id.shangpin_rushedan).setVisible(true); |
|
|
aMenu.findItem(R.id.shangpin_rushedan).setVisible(true); |
|
|
} else { |
|
|
} else { |
|
|
aMenu.findItem(R.id.shangpin_xiaoxi).setVisible(true); |
|
|
|
|
|
aMenu.findItem(R.id.shangpin_rushedan).setVisible(false); |
|
|
aMenu.findItem(R.id.shangpin_rushedan).setVisible(false); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
} else { |
|
|
} else { |
|
|
aMenu.findItem(R.id.shangpin_xiaoxi).setVisible(false); |
|
|
aMenu.findItem(R.id.shangpin_xiaoxi).setVisible(false); |
|
|
aMenu.findItem(R.id.shangpin_rushedan).setVisible(false); |
|
|
aMenu.findItem(R.id.shangpin_rushedan).setVisible(false); |
|
|
|