|
|
@@ -91,6 +91,7 @@ public class BServiceAddActivity extends OABaseActivity implements View.OnClickL
|
|
|
private String dataService;//详情数据
|
|
|
private boolean isHasPerson;//是否指定了人员
|
|
|
private AddSubUtils addSubUtils;
|
|
|
+ private String sb_sex="0";//默认女士
|
|
|
|
|
|
@Override
|
|
|
protected void onCreate(Bundle savedInstanceState) {
|
|
|
@@ -174,9 +175,11 @@ public class BServiceAddActivity extends OABaseActivity implements View.OnClickL
|
|
|
.setOnChangeValueListener(new AddSubUtils.OnChangeValueListener() {
|
|
|
@Override
|
|
|
public void onChangeValue(int value, int position) {
|
|
|
- // Toast.makeText(mContext, "当前值:" + value, Toast.LENGTH_SHORT).show();
|
|
|
tv_food_peoples.setText(String.valueOf(value));
|
|
|
tv_food_peoples.setVisibility(View.GONE);
|
|
|
+ if (!StringUtil.isEmpty(tv_food_times.getText().toString())) {
|
|
|
+ searchSeatNumbers(tv_food_times.getText().toString(), model.getCompanyid());
|
|
|
+ }
|
|
|
}
|
|
|
});
|
|
|
tv_food_peoples.setText("1");
|
|
|
@@ -186,6 +189,11 @@ public class BServiceAddActivity extends OABaseActivity implements View.OnClickL
|
|
|
public void onCheckedChanged(RadioGroup group, int checkedId) {
|
|
|
RadioButton radioButton = (RadioButton)findViewById(rg_sex.getCheckedRadioButtonId());
|
|
|
ToastMessage("id:"+radioButton.getId()+"text:"+radioButton.getText().toString());
|
|
|
+ if (radioButton.getText().toString().equals("先生")){
|
|
|
+ sb_sex="0";
|
|
|
+ }else if(radioButton.getText().toString().equals("女士")){
|
|
|
+ sb_sex="1";
|
|
|
+ }
|
|
|
}
|
|
|
});
|
|
|
}
|
|
|
@@ -804,8 +812,10 @@ public class BServiceAddActivity extends OABaseActivity implements View.OnClickL
|
|
|
progressDialog.dismiss();
|
|
|
return;
|
|
|
} else {
|
|
|
+ map.put("sb_sex",sb_sex);
|
|
|
LogUtil.i("map=1" + JSONUtil.map2JSON(map));
|
|
|
LogUtil.i("map=2" + JSON.toJSONString(map));
|
|
|
+
|
|
|
// if (1 == 1) {
|
|
|
// submiting = false;
|
|
|
// progressDialog.dismiss();
|
|
|
@@ -1451,10 +1461,24 @@ public class BServiceAddActivity extends OABaseActivity implements View.OnClickL
|
|
|
}
|
|
|
|
|
|
|
|
|
+ //人数默认是1 小桌
|
|
|
+ //选择时间
|
|
|
//查询桌子余量
|
|
|
public void searchSeatNumbers(String yearmonth,String companyid){
|
|
|
//companyid,userid,yearmonth,token
|
|
|
- LogUtil.i("yearmonth:"+yearmonth+" companyid:"+companyid);
|
|
|
+ String peopleNumber=tv_food_peoples.getText().toString();
|
|
|
+ String as_type="小桌";
|
|
|
+ if (Integer.valueOf(peopleNumber)>2&&Integer.valueOf(peopleNumber)<=5){
|
|
|
+ //中
|
|
|
+ as_type="中桌";
|
|
|
+ }else if(Integer.valueOf(peopleNumber)>5){
|
|
|
+ //大
|
|
|
+ as_type="大桌";
|
|
|
+ }else{
|
|
|
+ //小
|
|
|
+ as_type="小桌";
|
|
|
+ }
|
|
|
+ LogUtil.i("座位:"+as_type+"yearmonth:"+yearmonth+" companyid:"+companyid+" peopleNumber:"+peopleNumber);
|
|
|
HttpClient httpClient=new HttpClient.Builder(Constants.IM_BASE_URL()).build();
|
|
|
httpClient.Api().send(new HttpClient.Builder()
|
|
|
.url("/user/appLineList")
|