diff --git a/app/src/main/java/com/bonait/bnframework/Dialog/DialogManager.java b/app/src/main/java/com/bonait/bnframework/Dialog/DialogManager.java new file mode 100644 index 00000000..b10387a8 --- /dev/null +++ b/app/src/main/java/com/bonait/bnframework/Dialog/DialogManager.java @@ -0,0 +1,180 @@ +package com.bonait.bnframework.Dialog; + +import static com.bonait.bnframework.common.utils.AlertDialogUtils.getContext; + +import android.app.Activity; +import android.content.Context; +import android.content.ContextWrapper; +import android.view.Gravity; +import android.view.View; +import android.widget.Button; +import android.widget.RelativeLayout; +import android.widget.TextView; + +import androidx.annotation.NonNull; +import com.bonait.bnframework.R; +import com.bonait.bnframework.common.constant.ConfigName; +import com.bonait.bnframework.common.db.res.UserLogEnum; +import com.bonait.bnframework.common.helper.AlertDialogButton; +import com.bonait.bnframework.common.helper.I.IDialogAction; +import com.bonait.bnframework.common.helper.MessageLog; +import com.qmuiteam.qmui.widget.dialog.QMUIDialog; +import com.qmuiteam.qmui.widget.dialog.QMUIDialogBuilder; + +public class DialogManager { +// private static volatile DialogManager mInstance = null; +// +// private DialogManager() { +// +// } +// +// public static DialogManager getInstance() { +// if (mInstance == null) { +// synchronized (DialogManager.class) { +// if (mInstance == null) { +// mInstance = new DialogManager(); +// } +// } +// } +// return mInstance; +// } +// public Activity activityMain=null; +// public DialogView initView(Context context, int layout) { +// return new DialogView(context, layout, R.style.CustomDialog, Gravity.CENTER); +// } +// +// public DialogView initView(Context context, int layout, int gravity,Activity activity) { +// activityMain=activity; +// return new DialogView(context, layout, R.style.mydialog, gravity); +// } + // 显示弹框 +// public void show(DialogView view) { +// if (view != null) { +// if (!view.isShowing()) { +// view.show(); +// } +// } +// } + +// // 显示弹框 +// public void show(DialogView view, int closeId) { +// if (view != null) { +// if (!view.isShowing()) { +// if (!view.findViewById(closeId).hasOnClickListeners()) { +// view.findViewById(closeId).setOnClickListener(new View.OnClickListener() { +// @Override +// public void onClick(View view1) { +// hide(view); +// } +// }); +// } +// if (activityMain!=null && !activityMain.isFinishing()) { +// view.show(); +// } +// else +// { +// MessageLog.ShowUserMessage( UserLogEnum.订单处理日志 ,"弹框Active获取失败"); +// } +// } +// } +// } + + + + private static DialogView dview; + + private static Context mContext; + + public static void setContext(Context _ct){ + mContext = _ct; + } + + /** + * 对话框,自定义按钮,非阻塞 + * */ + private static void showDialog(String message, AlertDialogButton btn,DialogType dt, IDialogAction action) { + if(mContext==null) return; + if(dview==null)dview=new DialogView(mContext, R.layout.activity_dialog, R.style.custom_dialog2); + if (dview != null) { + if (!dview.isShowing()) { + + String btnName1="确定"; + String btnName2="取消"; + if(btn==AlertDialogButton.YesNoCancel||btn==AlertDialogButton.YesNo){ + btnName1="是"; + btnName2="否"; + } + + dview.setCanceledOnTouchOutside(false);//禁用触摸其它区域关闭弹框 + RelativeLayout rlTitle = (RelativeLayout) dview.findViewById(R.id.rl_title); + if(dt== DialogType.提示)rlTitle.setBackgroundResource(R.drawable.dialog_info_title_back); + if(dt== DialogType.警告)rlTitle.setBackgroundResource(R.drawable.dialog_warn_title_back); + if(dt== DialogType.错误)rlTitle.setBackgroundResource(R.drawable.dialog_error_title_back); + TextView Tv=(TextView)dview.findViewById(R.id.tv_Title); + TextView Info=(TextView)dview.findViewById(R.id.tv_Info); + Button ok = (Button)dview.findViewById(R.id.btn_ok); + Button cancel = (Button)dview.findViewById(R.id.btn_cancel); + + Tv.setText(dt.toString()); + Info.setText(message); + ok.setText(btnName1); + cancel.setText(btnName2); + + if(btn==AlertDialogButton.OK)cancel.setVisibility(View.GONE); + + ok.setOnClickListener(view->{ + if(action!=null)action.ExitDialog(true); + hide(dview); + }); + + cancel.setOnClickListener(view->{ + if(action!=null)action.ExitDialog(false); + hide(dview); + }); + dview.show(); + } + } + + } + + // 隐藏弹框 + private static void hide(DialogView view) { + if (view != null) { + if (view.isShowing()) { + view.dismiss(); + } + } + } + + /** + * 信息提示框 + * @param message 提示信息 + * @param btn 显示按钮 + * @param action 执行回调 + */ + public static void showInfo(String message, AlertDialogButton btn, IDialogAction action) { + showDialog(message,btn,DialogType.提示,action); + } + + /** + * 警告提示框 + * @param message 警告信息 + * @param btn 显示按钮 + * @param action 执行回调 + */ + public static void showWarn(String message, AlertDialogButton btn, IDialogAction action) { + showDialog(message,btn,DialogType.警告,action); + } + + /** + * 错误提示框 + * @param message 错误信息 + * @param btn 显示按钮 + * @param action 执行回调 + */ + public static void showError(String message, AlertDialogButton btn, IDialogAction action) { + showDialog(message,btn,DialogType.错误,action); + } + +} + diff --git a/app/src/main/java/com/bonait/bnframework/Dialog/DialogType.java b/app/src/main/java/com/bonait/bnframework/Dialog/DialogType.java new file mode 100644 index 00000000..f9e44b15 --- /dev/null +++ b/app/src/main/java/com/bonait/bnframework/Dialog/DialogType.java @@ -0,0 +1,7 @@ +package com.bonait.bnframework.Dialog; + +public enum DialogType { + 警告, + 提示, + 错误 +} diff --git a/app/src/main/java/com/bonait/bnframework/Dialog/DialogView.java b/app/src/main/java/com/bonait/bnframework/Dialog/DialogView.java new file mode 100644 index 00000000..72c785fa --- /dev/null +++ b/app/src/main/java/com/bonait/bnframework/Dialog/DialogView.java @@ -0,0 +1,31 @@ +package com.bonait.bnframework.Dialog; + +import android.app.Dialog; +import android.content.Context; +import android.view.Window; +import androidx.annotation.NonNull; + +public class DialogView extends Dialog { + + public DialogView(@NonNull Context context, int layout, int style, int gravity) { + super(context, style); + setContentView(layout); + Window mWindow = getWindow(); +// WindowManager.LayoutParams params = mWindow.getAttributes(); +// params.width = WindowManager.LayoutParams.MATCH_PARENT; +// params.height = WindowManager.LayoutParams.WRAP_CONTENT; +// params.gravity = gravity; +// mWindow.setAttributes(params); + } + + public DialogView(@NonNull Context context, int layout, int style) { + super(context, style); + setContentView(layout); + Window mWindow = getWindow(); +// WindowManager.LayoutParams params = mWindow.getAttributes(); +// params.width = WindowManager.LayoutParams.MATCH_PARENT; +// params.height = WindowManager.LayoutParams.WRAP_CONTENT; +// params.gravity = gravity; +// mWindow.setAttributes(params); + } +} diff --git a/app/src/main/java/com/bonait/bnframework/common/tabbar/MainNavigateTabBar.java b/app/src/main/java/com/bonait/bnframework/common/tabbar/MainNavigateTabBar.java index 9f8bb5b3..0d8bb19f 100644 --- a/app/src/main/java/com/bonait/bnframework/common/tabbar/MainNavigateTabBar.java +++ b/app/src/main/java/com/bonait/bnframework/common/tabbar/MainNavigateTabBar.java @@ -37,7 +37,7 @@ public class MainNavigateTabBar extends LinearLayout implements View.OnClickList private ColorStateList mSelectedTextColor; private ColorStateList mNormalTextColor; private float mTabTextSize; - private int mDefaultSelectedTab = 2; + private int mDefaultSelectedTab = 3; private int mCurrentSelectedTab; public MainNavigateTabBar(Context context) { diff --git a/app/src/main/java/com/bonait/bnframework/modules/home/activity/BottomNavigationMainActivity.java b/app/src/main/java/com/bonait/bnframework/modules/home/activity/BottomNavigationMainActivity.java index b0eb9986..424b31cd 100644 --- a/app/src/main/java/com/bonait/bnframework/modules/home/activity/BottomNavigationMainActivity.java +++ b/app/src/main/java/com/bonait/bnframework/modules/home/activity/BottomNavigationMainActivity.java @@ -22,6 +22,7 @@ import com.bonait.bnframework.modules.home.adapter.FragmentAdapter; import com.bonait.bnframework.modules.home.fragment.DingDanfragment; import com.bonait.bnframework.modules.home.fragment.GongnengFragment; import com.bonait.bnframework.modules.home.fragment.HandControlFragment; +import com.bonait.bnframework.modules.home.fragment.IoMonitorFragment; import com.bonait.bnframework.modules.home.fragment.MakeGoodFragment; import com.bonait.bnframework.modules.home.fragment.SheZhifragment; import com.bonait.bnframework.modules.mine.fragment.MyFragment; @@ -81,7 +82,7 @@ public class BottomNavigationMainActivity extends BaseActivity { fragmentList.add(new DingDanfragment()); fragmentList.add(new HandControlFragment()); fragmentList.add(new MakeGoodFragment()); - fragmentList.add(new HandControlFragment()); + fragmentList.add(new IoMonitorFragment()); fragmentList.add(new SheZhifragment()); fragmentList.add(new MyFragment()); ConfigName.getInstance().fragmentAdapter = new FragmentAdapter(getSupportFragmentManager(), fragmentList); diff --git a/app/src/main/java/com/bonait/bnframework/modules/home/activity/DialogActivity.java b/app/src/main/java/com/bonait/bnframework/modules/home/activity/DialogActivity.java new file mode 100644 index 00000000..a1de24b6 --- /dev/null +++ b/app/src/main/java/com/bonait/bnframework/modules/home/activity/DialogActivity.java @@ -0,0 +1,15 @@ +package com.bonait.bnframework.modules.home.activity; + +import android.os.Bundle; + +import androidx.appcompat.app.AppCompatActivity; + +import com.bonait.bnframework.R; + +public class DialogActivity extends AppCompatActivity { + @Override + protected void onCreate(Bundle savedInstanceState) { + super.onCreate(savedInstanceState); + setContentView(R.layout.activity_dialog); + } +} diff --git a/app/src/main/java/com/bonait/bnframework/modules/home/fragment/HandControlFragment.java b/app/src/main/java/com/bonait/bnframework/modules/home/fragment/HandControlFragment.java index 55c59488..996be489 100644 --- a/app/src/main/java/com/bonait/bnframework/modules/home/fragment/HandControlFragment.java +++ b/app/src/main/java/com/bonait/bnframework/modules/home/fragment/HandControlFragment.java @@ -22,6 +22,7 @@ import androidx.annotation.Nullable; import androidx.recyclerview.widget.RecyclerView; import androidx.recyclerview.widget.StaggeredGridLayoutManager; +import com.bonait.bnframework.Dialog.DialogManager; import com.bonait.bnframework.R; import com.bonait.bnframework.business.ConfigData; import com.bonait.bnframework.business.ExecuteTheRecipe; @@ -97,6 +98,7 @@ public class HandControlFragment extends BaseFragment { ExecuteTheRecipe.mainContext=context; ExecuteTheRecipe.mainActivity=activity; AlertDialogUtils.getContext=context; + DialogManager.setContext(context); NotifyProp(); Init_弹窗(); StatusOrMakeGoodThread(); @@ -288,7 +290,8 @@ public class HandControlFragment extends BaseFragment { switch (view.getId()) { case R.id.button_出料: if (!ExecuteTheRecipe.getDeviceData.SystemStartStopStatusNotify.getValue()) { - AlertDialogUtils.showDialog(context, "提示", "系统未启动,请启动后重试!"); +// AlertDialogUtils.showDialog(context, "提示", "系统未启动,请启动后重试!"); + DialogManager.showWarn("系统未启动,请启动后重试!",AlertDialogButton.OK,null); return ; } Convert.TryToFloat(edit_设定重量.getText()).OnSource((s)-> @@ -299,12 +302,14 @@ public class HandControlFragment extends BaseFragment { ExecuteTheRecipe.showlog("手动设定提前量:"+t.Content); ExecuteTheRecipe.DischargeControlAsync(s.Content,t.Content); }).OnFailed(p->{ - AlertDialogUtils.showDialog(context, "提示", "输入的数据格式不匹配,请重试!"); +// AlertDialogUtils.showDialog(context, "提示", "输入的数据格式不匹配,请重试!"); + DialogManager.showError("输入的数据格式不匹配,请重试!",AlertDialogButton.OK,null); edit_提前量.setText("0.0"); }); }).OnFailed(f->{ - AlertDialogUtils.showDialog(context, "提示", "输入的数据格式不匹配,请重试!"); +// AlertDialogUtils.showDialog(context, "提示", "输入的数据格式不匹配,请重试!"); + DialogManager.showError("输入的数据格式不匹配,请重试!",AlertDialogButton.OK,null); edit_设定重量.setText("0.0"); }); break; @@ -318,7 +323,8 @@ public class HandControlFragment extends BaseFragment { ExecuteTheRecipe.showlog("手动设置温度修正值:"+s.Content); ExecuteTheRecipe.WriteAsync("炒锅温度修正",s.Content); }).OnFailed(f->{ - AlertDialogUtils.showDialog(context, "提示", "输入的数据格式不匹配,请重试!"); +// AlertDialogUtils.showDialog(context, "提示", "输入的数据格式不匹配,请重试!"); + DialogManager.showError("输入的数据格式不匹配,请重试!",AlertDialogButton.OK,null); edit_温度修正.setText("0.0"); }); Convert.TryToFloat(edit_温度上限.getText()).OnSource((s)-> @@ -326,7 +332,8 @@ public class HandControlFragment extends BaseFragment { ExecuteTheRecipe.showlog("手动设置温度上限值:"+s.Content); ExecuteTheRecipe.WriteAsync("炒锅温度上限设置",s.Content); }).OnFailed(p->{ - AlertDialogUtils.showDialog(context, "提示", "输入的数据格式不匹配,请重试!"); +// AlertDialogUtils.showDialog(context, "提示", "输入的数据格式不匹配,请重试!"); + DialogManager.showError("输入的数据格式不匹配,请重试!",AlertDialogButton.OK,null); edit_温度上限.setText("0.0"); }); break; @@ -370,7 +377,8 @@ public class HandControlFragment extends BaseFragment { if(!ExecuteTheRecipe.getDeviceData.SystemStartStopStatusNotify.getValue()){ if(motionEvent.getAction() == MotionEvent.ACTION_DOWN){ - AlertDialogUtils.showDialog("系统未启动,请启动后重试!", AlertDialogButton.OK,(s)->{}); +// AlertDialogUtils.showDialog("系统未启动,请启动后重试!", AlertDialogButton.OK,(s)->{}); + DialogManager.showWarn("系统未启动,请启动后重试!",AlertDialogButton.OK,null); } return false; } @@ -550,7 +558,8 @@ public class HandControlFragment extends BaseFragment { private void DeviceControl(boolean isChecked,String name){ if(isChecked&&!ExecuteTheRecipe.getDeviceData.SystemStartStopStatusNotify.getValue()){ - AlertDialogUtils.showDialog("系统未启动,请启动后重试!", AlertDialogButton.OK,null); +// AlertDialogUtils.showDialog("系统未启动,请启动后重试!", AlertDialogButton.OK,null); + DialogManager.showWarn("系统未启动,请启动后重试!",AlertDialogButton.OK,null); } ExecuteTheRecipe.showlog("手动操作-"+name+",值:"+isChecked); ExecuteTheRecipe.WriteAsync(name,isChecked); @@ -577,7 +586,8 @@ public class HandControlFragment extends BaseFragment { boolean temp=!ExecuteTheRecipe.getDeviceData.StirControlStatusNotify.getValue(); if (temp) { if(!ExecuteTheRecipe.getDeviceData.SystemStartStopStatusNotify.getValue()){ - AlertDialogUtils.showDialog("系统未启动,请启动后重试!", AlertDialogButton.OK,null); +// AlertDialogUtils.showDialog("系统未启动,请启动后重试!", AlertDialogButton.OK,null); + DialogManager.showWarn("系统未启动,请启动后重试!",AlertDialogButton.OK,null); } ExecuteTheRecipe.showlog("手动启动搅拌"); ExecuteTheRecipe.BottomClickAsync("搅拌启动开关"); diff --git a/app/src/main/java/com/bonait/bnframework/modules/home/fragment/IoMonitorFragment.java b/app/src/main/java/com/bonait/bnframework/modules/home/fragment/IoMonitorFragment.java new file mode 100644 index 00000000..f5828f2d --- /dev/null +++ b/app/src/main/java/com/bonait/bnframework/modules/home/fragment/IoMonitorFragment.java @@ -0,0 +1,62 @@ +package com.bonait.bnframework.modules.home.fragment; + +import android.app.Activity; +import android.content.Context; +import android.os.Bundle; +import android.view.LayoutInflater; +import android.view.MotionEvent; +import android.view.View; +import android.widget.Button; +import android.widget.EditText; +import android.widget.ImageView; +import android.widget.RadioButton; +import android.widget.TextView; + +import androidx.annotation.NonNull; +import androidx.annotation.Nullable; + +import com.bonait.bnframework.Dialog.DialogManager; +import com.bonait.bnframework.R; +import com.bonait.bnframework.business.ExecuteTheRecipe; +import com.bonait.bnframework.common.base.BaseFragment; +import com.bonait.bnframework.common.db.QueryDB; +import com.bonait.bnframework.common.db.mode.BPA_MATERIAL; +import com.bonait.bnframework.common.db.res.StatusMode; +import com.bonait.bnframework.common.helper.AlertDialogButton; +import com.bonait.bnframework.common.helper.Convert; +import com.bonait.bnframework.common.helper.CountDownTimerExt; +import com.bonait.bnframework.common.helper.I.IThread; +import com.bonait.bnframework.common.helper.MessageLog; +import com.bonait.bnframework.common.helper.ThreadManager; +import com.bonait.bnframework.common.modbus.s7.CommHelper; +import com.bonait.bnframework.common.utils.AlertDialogUtils; +import com.bonait.bnframework.common.utils.ToastUtils; +import com.bonait.bnframework.modules.home.adapter.devicestatus_adapter; +import com.litao.slider.NiftySlider; + +import java.util.ArrayList; +import java.util.List; + +import butterknife.BindView; +import butterknife.ButterKnife; +import butterknife.OnClick; + +public class IoMonitorFragment extends BaseFragment { + + public IoMonitorFragment() { + } + + @Override + protected View onCreateView() { + View root = LayoutInflater.from(getActivity()).inflate(R.layout.fragment_io_monitor, null); + ButterKnife.bind(this, root); + return root; + } + + @Override + public void onViewCreated(@NonNull View view, @Nullable Bundle savedInstanceState) { + super.onViewCreated(view, savedInstanceState); + } + + +} \ No newline at end of file diff --git a/app/src/main/java/com/bonait/bnframework/modules/home/fragment/MakeGoodFragment.java b/app/src/main/java/com/bonait/bnframework/modules/home/fragment/MakeGoodFragment.java index 73c7dba7..38d0da99 100644 --- a/app/src/main/java/com/bonait/bnframework/modules/home/fragment/MakeGoodFragment.java +++ b/app/src/main/java/com/bonait/bnframework/modules/home/fragment/MakeGoodFragment.java @@ -26,6 +26,8 @@ import android.widget.RelativeLayout; import android.widget.Spinner; import android.widget.TextView; +import com.bonait.bnframework.Dialog.DialogManager; +import com.bonait.bnframework.Dialog.DialogType; import com.bonait.bnframework.R; import com.bonait.bnframework.business.ConfigData; import com.bonait.bnframework.business.ExecuteTheRecipe; @@ -166,6 +168,7 @@ public class MakeGoodFragment extends BaseFragment { NotifyProp(); initTopBar(); Initdata(); + DialogManager.setContext(context); CommHelper.get().ConnectOk = new IRun() { @Override public void Run() { @@ -407,9 +410,14 @@ public class MakeGoodFragment extends BaseFragment { switch (view.getId()) { case R.id.xzcp://选择菜谱按钮点击 skipToActivity(CpxzActivity.class); + + + + + break; case R.id.btn_xtkz: - SetVisibility(1); +// SetVisibility(1); break; // case R.id.btn_hlkz: // SetVisibility(2); @@ -683,7 +691,7 @@ public class MakeGoodFragment extends BaseFragment { public void onRecordStop() { getActivity().runOnUiThread(()->{ if (good != null) { - startbutton.setText("开始烹饪"); + startbutton.setText("开始炒制"); startbutton.setBackgroundResource(R.drawable.bg_btn_login_selected); xzcp.setVisibility(View.VISIBLE); @@ -967,7 +975,7 @@ public class MakeGoodFragment extends BaseFragment { InitStatusdata(); //2. SetProcesssUI(0); - startbutton.setText("开始烹饪"); + startbutton.setText("开始炒制"); startbutton.setBackgroundResource(R.drawable.bg_btn_login_selected); SetVisibility(0); SetProcessDescription("等待开始..."); diff --git a/app/src/main/java/com/bonait/bnframework/modules/home/fragment/from/SystemParameterActivity.java b/app/src/main/java/com/bonait/bnframework/modules/home/fragment/from/SystemParameterActivity.java index 81fb6ff4..acb5cfac 100644 --- a/app/src/main/java/com/bonait/bnframework/modules/home/fragment/from/SystemParameterActivity.java +++ b/app/src/main/java/com/bonait/bnframework/modules/home/fragment/from/SystemParameterActivity.java @@ -38,12 +38,12 @@ public class SystemParameterActivity extends BaseActivity { EditText edittext1; @BindView(R.id.edittext2) EditText edittext2; - @BindView(R.id.edittext3) - EditText edittext3; - @BindView(R.id.edittext4) - EditText edittext4; +// @BindView(R.id.edittext3) +// EditText edittext3; +// @BindView(R.id.edittext4) +// EditText edittext4; // @BindView(R.id.environment) - Spinner environment; +// Spinner environment; @BindView(R.id.versionselection) Spinner versionselection; @@ -88,8 +88,8 @@ public class SystemParameterActivity extends BaseActivity { private void initData() { editTextLists.add(edittext1); editTextLists.add(edittext2); - editTextLists.add(edittext3); - editTextLists.add(edittext4); +// editTextLists.add(edittext3); +// editTextLists.add(edittext4); material_map.put("开发环境", 0); material_map.put("测试环境", 1); @@ -102,7 +102,7 @@ public class SystemParameterActivity extends BaseActivity { ArrayAdapter adapter = new ArrayAdapter<>(context, R.layout.spinner_text_item, new ArrayList<>(material_map.keySet())); adapter.setDropDownViewResource(R.layout.spinner_dropdown_item); - environment.setAdapter(adapter); +// environment.setAdapter(adapter); ArrayAdapter adapter1 = new ArrayAdapter<>(context, R.layout.spinner_text_item, new ArrayList<>(material_map_vis.keySet())); adapter1.setDropDownViewResource(R.layout.spinner_dropdown_item); @@ -118,7 +118,7 @@ public class SystemParameterActivity extends BaseActivity { break; case -99: ConfigName.getInstance().Environment = item.value; - environment.setSelection(material_map.get(item.value)); +// environment.setSelection(material_map.get(item.value)); break; case 1: ConfigName.getInstance().Address = item.value; @@ -130,11 +130,11 @@ public class SystemParameterActivity extends BaseActivity { break; case 3: ConfigName.getInstance().ClientAutoKey = item.value; - edittext3.setText(item.value); +// edittext3.setText(item.value); break; case 4: ConfigName.getInstance().DeviceAutoKey = item.value; - edittext4.setText(item.value); +// edittext4.setText(item.value); break; } @@ -155,10 +155,10 @@ public class SystemParameterActivity extends BaseActivity { case R.id.StartButton://保存按钮 ConfigName.getInstance().Address = edittext1.getText().toString(); ConfigName.getInstance().Post = Integer.parseInt(edittext2.getText().toString()); - ConfigName.getInstance().ClientAutoKey = edittext3.getText().toString(); - ConfigName.getInstance().DeviceAutoKey = edittext4.getText().toString(); +// ConfigName.getInstance().ClientAutoKey = edittext3.getText().toString(); +// ConfigName.getInstance().DeviceAutoKey = edittext4.getText().toString(); - ConfigName.getInstance().Environment = environment.getSelectedItem().toString(); +// ConfigName.getInstance().Environment = environment.getSelectedItem().toString(); boolean isgb = false; if (!ConfigName.getInstance().versionSelectionEnum.equals(versionselection.getSelectedItem().toString())) { @@ -180,7 +180,7 @@ public class SystemParameterActivity extends BaseActivity { } BPA_SYSTEMSET set = new BPA_SYSTEMSET(); set.type = -99; - set.value = environment.getSelectedItem().toString(); +// set.value = environment.getSelectedItem().toString(); set.deviceID = ConfigName.getInstance().DeviceId; set.userID = ConfigName.getInstance().user.userID; QueryDB.AddSystemset(set); diff --git a/app/src/main/res/drawable/dialog_back.xml b/app/src/main/res/drawable/dialog_back.xml new file mode 100644 index 00000000..13592de1 --- /dev/null +++ b/app/src/main/res/drawable/dialog_back.xml @@ -0,0 +1,5 @@ + + + + + \ No newline at end of file diff --git a/app/src/main/res/drawable/dialog_error_title_back.xml b/app/src/main/res/drawable/dialog_error_title_back.xml new file mode 100644 index 00000000..ba3f2fb2 --- /dev/null +++ b/app/src/main/res/drawable/dialog_error_title_back.xml @@ -0,0 +1,5 @@ + + + + + \ No newline at end of file diff --git a/app/src/main/res/drawable/dialog_info_title_back.xml b/app/src/main/res/drawable/dialog_info_title_back.xml new file mode 100644 index 00000000..26ae15d9 --- /dev/null +++ b/app/src/main/res/drawable/dialog_info_title_back.xml @@ -0,0 +1,5 @@ + + + + + \ No newline at end of file diff --git a/app/src/main/res/drawable/dialog_warn_title_back.xml b/app/src/main/res/drawable/dialog_warn_title_back.xml new file mode 100644 index 00000000..2e8fa22c --- /dev/null +++ b/app/src/main/res/drawable/dialog_warn_title_back.xml @@ -0,0 +1,5 @@ + + + + + \ No newline at end of file diff --git a/app/src/main/res/layout/activity_dialog.xml b/app/src/main/res/layout/activity_dialog.xml new file mode 100644 index 00000000..a1b57ac0 --- /dev/null +++ b/app/src/main/res/layout/activity_dialog.xml @@ -0,0 +1,89 @@ + + + + + + + + + + + + + + + + + + + + + +