Bladeren bron

首页增加便民服务二维码,其他优化

weizhengliang 1 jaar geleden
bovenliggende
commit
85c633397b
49 gewijzigde bestanden met toevoegingen van 1319 en 1284 verwijderingen
  1. 5 3
      android_bed/src/main/java/com/wdkl/app/ncs/callingbed/activity/CallingbedActivationActivity.kt
  2. 37 55
      android_bed/src/main/java/com/wdkl/app/ncs/callingbed/activity/CallingbedActivity.kt
  3. 1 1
      android_bed/src/main/java/com/wdkl/app/ncs/callingbed/activity/CostActivity.kt
  4. 2 2
      android_bed/src/main/java/com/wdkl/app/ncs/callingbed/activity/CountdownActivity.kt
  5. 1 1
      android_bed/src/main/java/com/wdkl/app/ncs/callingbed/activity/DepartmentInfoActivity.kt
  6. 1 1
      android_bed/src/main/java/com/wdkl/app/ncs/callingbed/activity/DoctorsAdviceActivity.kt
  7. 1 1
      android_bed/src/main/java/com/wdkl/app/ncs/callingbed/activity/HospitalInfoActivity.kt
  8. 8 109
      android_bed/src/main/java/com/wdkl/app/ncs/callingbed/activity/SignActivity.kt
  9. 1 1
      android_bed/src/main/java/com/wdkl/app/ncs/callingbed/activity/SystemActivity.kt
  10. 9 11
      android_bed/src/main/java/com/wdkl/app/ncs/callingbed/activity/TextActivity.kt
  11. 13 65
      android_bed/src/main/java/com/wdkl/app/ncs/callingbed/activity/WebviewActivity.kt
  12. 17 12
      android_bed/src/main/java/com/wdkl/app/ncs/callingbed/adapter/CallRecordsItemAdapter.kt
  13. 0 3
      android_bed/src/main/java/com/wdkl/app/ncs/callingbed/adapter/DeviceMenuapter.kt
  14. 14 0
      android_bed/src/main/java/com/wdkl/app/ncs/callingbed/dialog/Network2DialogHelper.java
  15. 16 19
      android_bed/src/main/java/com/wdkl/app/ncs/callingbed/dialog/ServicesDialogHelper.java
  16. 15 12
      android_bed/src/main/java/com/wdkl/app/ncs/callingbed/dialog/SystemDialogHelper.java
  17. 1 1
      android_bed/src/main/java/com/wdkl/app/ncs/callingbed/fragment/BaseCallFragment.kt
  18. 17 19
      android_bed/src/main/java/com/wdkl/app/ncs/callingbed/fragment/CallRecordsFragment.kt
  19. 40 1
      android_bed/src/main/java/com/wdkl/app/ncs/callingbed/fragment/MainFragment.kt
  20. 4 10
      android_bed/src/main/java/com/wdkl/app/ncs/callingbed/fragment/NursingWorkFragment.kt
  21. 2 2
      android_bed/src/main/java/com/wdkl/app/ncs/callingbed/fragment/SipCallFragment.kt
  22. 3 2
      android_bed/src/main/java/com/wdkl/app/ncs/callingbed/fragment/SkyCallFragment.kt
  23. 15 0
      android_bed/src/main/java/com/wdkl/app/ncs/callingbed/helper/Utils.java
  24. 20 0
      android_bed/src/main/res/layout/activity_sign.xml
  25. 1 1
      android_bed/src/main/res/layout/callingbed_activation.xml
  26. 130 139
      android_bed/src/main/res/layout/callingbed_main_new.xml
  27. 252 247
      android_bed/src/main/res/layout/callingbed_test_main.xml
  28. 2 2
      android_bed/src/main/res/layout/item_icon_lay.xml
  29. 4 4
      android_bed/src/main/res/layout/main_call_r_dialog.xml
  30. 143 130
      android_bed/src/main/res/layout/main_network_two_dialog.xml
  31. 69 65
      android_bed/src/main/res/layout/main_password_dialog.xml
  32. 69 67
      android_bed/src/main/res/layout/main_server_dialog.xml
  33. 236 233
      android_bed/src/main/res/layout/main_view_layout.xml
  34. 3 10
      android_bed/src/main/res/layout/nursing_work_lay.xml
  35. 0 6
      android_bed/src/main/res/layout/sign_fragment_lay.xml
  36. 42 44
      android_bed/src/main/res/layout/view_title_layout.xml
  37. 1 1
      callingdoor/src/main/java/com/wdkl/app/ncs/callingdoor/activity/DepartmentInfoActivity.kt
  38. 1 1
      callingdoor/src/main/java/com/wdkl/app/ncs/callingdoor/activity/HospitalInfoActivity.kt
  39. 1 1
      callingdoor/src/main/java/com/wdkl/app/ncs/callingdoor/activity/SetHintActivity.kt
  40. 1 1
      callingdoor/src/main/java/com/wdkl/app/ncs/callingdoor/activity/SystemActivity.kt
  41. 1 1
      callingdoor/src/main/java/com/wdkl/app/ncs/callingdoor/activity/TextActivity.kt
  42. 65 0
      common/src/main/code/com/wdkl/ncs/android/lib/base/BaseActivity.kt
  43. 2 0
      middleware/src/main/code/com/wdkl/ncs/android/middleware/common/Constant.java
  44. 9 0
      middleware/src/main/code/com/wdkl/ncs/android/middleware/model/dos/DeviceDO.java
  45. 5 0
      resource/src/main/res/drawable/ic_device.xml
  46. 13 0
      resource/src/main/res/values-es/strings.xml
  47. 13 0
      resource/src/main/res/values-ru/strings.xml
  48. 12 0
      resource/src/main/res/values-zh/strings.xml
  49. 1 0
      resource/src/main/res/values/strings.xml

+ 5 - 3
android_bed/src/main/java/com/wdkl/app/ncs/callingbed/activity/CallingbedActivationActivity.kt

@@ -95,7 +95,8 @@ class CallingbedActivationActivity  : BaseActivity<CallingbedActivationPresenter
     override fun bindEvent() {
         //设备重启
         activation_settings_button.setOnClickListener {
-            RebootDialogHelper.showDialog(activity)
+            //RebootDialogHelper.showDialog(activity)
+            AppUpdateHelper.restartApp(activity)
         }
         //系统设置
         activation_system_button.setOnClickListener {
@@ -122,8 +123,6 @@ class CallingbedActivationActivity  : BaseActivity<CallingbedActivationPresenter
     }
 
     private fun showUI(){
-        //设置二维码
-        setQrcode()
         val isActivation = SPUtils.get(this, Constant.APP_ACTIVATION, "");
         if (isActivation.equals("已激活")){
             activation_title.setText("系统连接失败")
@@ -149,6 +148,9 @@ class CallingbedActivationActivity  : BaseActivity<CallingbedActivationPresenter
         activation_zcm.text=  Constant.DEVICE_REGISTER_ID
         val buildUrl = UrlManager.build()
         activation_fuq.text=   buildUrl.buyer.substringAfterLast("//").substringBefore(":")
+
+        //设置二维码
+        setQrcode()
     }
 
      fun setfuq(){

+ 37 - 55
android_bed/src/main/java/com/wdkl/app/ncs/callingbed/activity/CallingbedActivity.kt

@@ -187,8 +187,8 @@ class CallingbedActivity :BaseActivity<BedCallingbedActivityPresenter, Callingbe
     }
     companion object {
         lateinit var instance: CallingbedActivity
-        var sosItemList = java.util.ArrayList<CallingItem>()
-        var callingList = java.util.ArrayList<CallingItem>()
+        var sosItemList = ArrayList<CallingItem>()
+        var callingList = ArrayList<CallingItem>()
 
         fun checkIncomingCall(bedDeviceId: Int?): Boolean {
             if (callingList.size > 0) {
@@ -201,6 +201,7 @@ class CallingbedActivity :BaseActivity<BedCallingbedActivityPresenter, Callingbe
             return false
         }
     }
+
     override fun init() {
         instance = this
         //Utils.hideStatusBar(activity, false)
@@ -229,7 +230,11 @@ class CallingbedActivity :BaseActivity<BedCallingbedActivityPresenter, Callingbe
             startActivityForResult(intent, 11)
         }
 
-        //presenter.loadTcpServerHost()
+        if (!mainFragment.equals(curFragment)) {
+            switchFragment(R.id.callingbed_main_frame, MainFragment(), mainFragment)
+            updateLeftBtState(mainFragment)
+        }
+        main_rl_3.isEnabled = false
 
         //注册广播
         regReceiver()
@@ -248,7 +253,7 @@ class CallingbedActivity :BaseActivity<BedCallingbedActivityPresenter, Callingbe
                 SerialPortHelper.setDoorLight(1, "111")
             }
         }else{
-              setSerialListener()
+            setSerialListener()
             AppTool.Time.delay(2000) {
                 SerialPortHelper.setSosLight("0")
                 //默认门灯白色
@@ -291,7 +296,7 @@ class CallingbedActivity :BaseActivity<BedCallingbedActivityPresenter, Callingbe
         if ("rk3128".equals(Build.MODEL)) {
             checkLaunch()
         }else{
-       startYunpaiPlugin()
+            startYunpaiPlugin()
         }
         SpeechUtil.getInstance().init(applicationContext)
         val dm = resources.displayMetrics
@@ -457,7 +462,7 @@ class CallingbedActivity :BaseActivity<BedCallingbedActivityPresenter, Callingbe
             main_rl_3.visibility = View.VISIBLE
         }
     }
-    //到首页
+    //到首页
     fun BackMain() {
         if (!mainFragment.equals(curFragment)) {
             switchFragment(R.id.callingbed_main_frame, MainFragment(), mainFragment)
@@ -670,7 +675,6 @@ class CallingbedActivity :BaseActivity<BedCallingbedActivityPresenter, Callingbe
         menu_home.setOnClickListener {
             //首页
             if (!mainFragment.equals(curFragment)) {
-
                 switchFragment(R.id.callingbed_main_frame, MainFragment(), mainFragment)
                 updateLeftBtState(mainFragment)
             }
@@ -689,33 +693,12 @@ class CallingbedActivity :BaseActivity<BedCallingbedActivityPresenter, Callingbe
             }
         }
 
-//        tv_btn_about.setOnClickListener {
-//            //关于
-//            if (!qrFragment.equals(curFragment)) {
-//                switchFragment(R.id.callingbed2_main_frame, QrCodeFragment(), qrFragment)
-//            }
-//        }
-//
-//        tv_btn_cost.setOnClickListener {
-//            //费用
-//            if (!costFragment.equals(curFragment)) {
-//                switchFragment(R.id.callingbed2_main_frame, CostFragment(), costFragment)
-//            }
-//        }
-//
-//        tv_btn_sign.setOnClickListener {
-//            //体征
-//            if (!signFragment.equals(curFragment)) {
-//                switchFragment(R.id.callingbed2_main_frame, SignMainFragment(), signFragment)
-//            }
-//        }
-
         menu_support.setOnClickListener {
             //增援
             val time = System.currentTimeMillis()
             if (time - clickTime > 3000) {
                 if (Constant.TCP_CONNECTED) {
-                    if (Constant.DEVICE_ID != null) {
+                    if (Constant.DEVICE_ID != -1) {
                         OtherUtil.sendReinforce(Constant.DEVICE_ID)
                         ReinforcementsDialogHelper.showDialog(activity, true)
 //                        WidgetsUtil.showToastWithImage(getString(R.string.support_sent), 200f)
@@ -833,17 +816,11 @@ class CallingbedActivity :BaseActivity<BedCallingbedActivityPresenter, Callingbe
     override fun onStart() {
         super.onStart()
         //设备已注册,隐藏导航栏
-        if (Constant.DEVICE_ID != null) {
+        if (Constant.DEVICE_ID != -1) {
             Utils.hideStatusBar(activity, true)
         }
     }
 
-    override fun onStop() {
-        super.onStop()
-
-        Utils.hideStatusBar(activity, false)
-    }
-
     override fun destory() {
         unRegReceiver()
         EventBus.getDefault().unregister(this)
@@ -912,7 +889,6 @@ class CallingbedActivity :BaseActivity<BedCallingbedActivityPresenter, Callingbe
     override fun showDeviceInfo(deviceInfo: BedDeviceInfoVO) {
         //显示床位信息界面
         if (!mainFragment.equals(curFragment)) {
-
             switchFragment(R.id.callingbed_main_frame, MainFragment(), mainFragment)
             updateLeftBtState(mainFragment)
         }
@@ -934,6 +910,12 @@ class CallingbedActivity :BaseActivity<BedCallingbedActivityPresenter, Callingbe
         }
         view_title_layout_tv_hospital_name.text = deviceInfo.partDisplay
 
+        if (deviceInfo.partName != null) {
+            Constant.PART_NAME = deviceInfo.partName
+        }
+        if (deviceInfo.part_union_id != null) {
+            Constant.PART_UNION_ID = deviceInfo.part_union_id
+        }
 
         view_title_layout_tv_hospital_name.viewTreeObserver.addOnGlobalLayoutListener(object : ViewTreeObserver.OnGlobalLayoutListener {
             override fun onGlobalLayout() {
@@ -983,6 +965,8 @@ class CallingbedActivity :BaseActivity<BedCallingbedActivityPresenter, Callingbe
         if (enableBT) {
             loopConnection()
         }
+
+        main_rl_3.isEnabled = true
     }
 
     override fun showCustomInfo(customInfo: CustomerInfoVO) {
@@ -1907,15 +1891,15 @@ class CallingbedActivity :BaseActivity<BedCallingbedActivityPresenter, Callingbe
         }
     }
 
-    public  var timer1: CountDownTimer? = null
-    public var timer_1_name :String =""
-    public var timer1_type :Boolean = false
-    public var timer2: CountDownTimer? = null
-    public var timer_2_name :String =""
-    public var timer2_type :Boolean = false
-    public var timer3: CountDownTimer? = null
-    public var timer_3_name :String =""
-    public var timer3_type :Boolean = false
+    var timer1: CountDownTimer? = null
+    var timer_1_name :String =""
+    var timer1_type :Boolean = false
+    var timer2: CountDownTimer? = null
+    var timer_2_name :String =""
+    var timer2_type :Boolean = false
+    var timer3: CountDownTimer? = null
+    var timer_3_name :String =""
+    var timer3_type :Boolean = false
 
     //接听电话
     private fun acceptCall(interactionVO: InteractionVO, audioOnly: Boolean, tid: String) {
@@ -2117,20 +2101,18 @@ class CallingbedActivity :BaseActivity<BedCallingbedActivityPresenter, Callingbe
     }
     private fun updateLeftBtState(state: String) {
         menu_home.setBackgroundResource(R.drawable.shape_main_bt_bg)
-        menu_home.setTextColor(getResources().getColor(R.color.white));
+        menu_home.setTextColor(getResources().getColor(R.color.white))
         menu_more.setBackgroundResource(R.drawable.shape_main_bt_bg)
-        menu_more.setTextColor(getResources().getColor(R.color.white));
-        if(state.equals(mainFragment)){
+        menu_more.setTextColor(getResources().getColor(R.color.white))
+        if(state.equals(mainFragment)) {
             //首页
             main_rl_3.visibility = View.VISIBLE
             menu_home.setBackgroundResource(R.drawable.shape_main_bt_bg2)
-            menu_home.setTextColor(getResources().getColor(R.color.delete_text_color));
-        }else{
+            menu_home.setTextColor(getResources().getColor(R.color.delete_text_color))
+        } else if (state.equals(nwFragment)) {
             menu_more.setBackgroundResource(R.drawable.shape_main_bt_bg2)
-            menu_more.setTextColor(getResources().getColor(R.color.delete_text_color));
+            menu_more.setTextColor(getResources().getColor(R.color.delete_text_color))
         }
-
-
     }
     private fun updateSettings(forceSet: Boolean) {
         val  currentTimestamp = System.currentTimeMillis()
@@ -2580,7 +2562,7 @@ class CallingbedActivity :BaseActivity<BedCallingbedActivityPresenter, Callingbe
             val time = System.currentTimeMillis()
             if (time - clickTime > 3000) {
                 if (Constant.TCP_CONNECTED) {
-                    if (Constant.DEVICE_ID != null) {
+                    if (Constant.DEVICE_ID != -1) {
                         OtherUtil.sendReinforce(Constant.DEVICE_ID)
                         WidgetsUtil.showToastWithImage(getString(R.string.support_sent), 200f)
                         SoundPoolManager.getInstance().playSound(4, 1.0f, 1.0f, 0)

+ 1 - 1
android_bed/src/main/java/com/wdkl/app/ncs/callingbed/activity/CostActivity.kt

@@ -101,7 +101,7 @@ class CostActivity : BaseActivity<BedCostFragmentPresenter, CostViewLayBinding>(
     }
 
     private fun showui(){
-        view_title_layout_tv_hospital_name.text ="返回上层"
+        view_title_layout_tv_hospital_name.setText(R.string.str_back)
         view_title_layout_img.visibility = View.VISIBLE
         view_title_layout_tv_no.visibility = View.VISIBLE
         view_title_layout_tv_no.text ="费用"

+ 2 - 2
android_bed/src/main/java/com/wdkl/app/ncs/callingbed/activity/CountdownActivity.kt

@@ -485,7 +485,7 @@ class CountdownActivity : BaseActivity<BedTextActivityPresenter, CallingbedTestM
 //            view_calling_bed_layout_title.setBackgroundColor(Color.parseColor("#FF8484"))
             time_setting.setBackgroundColor(Color.parseColor("#F7F7F7"))
             view_title_layout_return.setBackgroundResource(R.drawable.shape_main_hos_txt_bg)
-            view_title_layout_tv_hospital_name.text ="返回上层"
+            view_title_layout_tv_hospital_name.setText(R.string.str_back)
             view_title_layout_tv_hospital_name.setTextColor(resources.getColor(R.color.white))
 
             view_title_layout_img.setImageResource(R.mipmap.return_w)
@@ -527,7 +527,7 @@ class CountdownActivity : BaseActivity<BedTextActivityPresenter, CallingbedTestM
 //            view_calling_bed_layout_title.setBackgroundColor(Color.TRANSPARENT);
             time_setting.setBackgroundColor(Color.parseColor("#0090ff"))
             view_title_layout_return.setBackgroundResource(R.drawable.shape_time_bu_bg)
-            view_title_layout_tv_hospital_name.text ="返回上层"
+            view_title_layout_tv_hospital_name.setText(R.string.str_back)
             view_title_layout_tv_hospital_name.setTextColor(resources.getColor(R.color.delete_text_color))
             view_title_layout_img.visibility = View.VISIBLE
             view_title_layout_img.setImageResource(R.mipmap.return_b)

+ 1 - 1
android_bed/src/main/java/com/wdkl/app/ncs/callingbed/activity/DepartmentInfoActivity.kt

@@ -51,7 +51,7 @@ class DepartmentInfoActivity : BaseActivity<BedHospitalInfoActivityPresenter, Ca
     }
 
     private fun showui(){
-        view_title_layout_tv_hospital_name.text ="返回上层"
+        view_title_layout_tv_hospital_name.setText(R.string.str_back)
         view_title_layout_img.visibility = View.VISIBLE
         view_title_layout_tv_no.visibility = View.GONE
         view_title_layout_tv_no.text ="科室介绍"

+ 1 - 1
android_bed/src/main/java/com/wdkl/app/ncs/callingbed/activity/DoctorsAdviceActivity.kt

@@ -112,7 +112,7 @@ class DoctorsAdviceActivity : BaseActivity<BedAdviceFragmentPresenter, YzViewLay
     }
 
     private fun showui(){
-        view_title_layout_tv_hospital_name.text ="返回上层"
+        view_title_layout_tv_hospital_name.setText(R.string.str_back)
         view_title_layout_img.visibility = View.VISIBLE
         view_title_layout_tv_no.visibility = View.VISIBLE
         view_title_layout_tv_no.text ="医嘱"

+ 1 - 1
android_bed/src/main/java/com/wdkl/app/ncs/callingbed/activity/HospitalInfoActivity.kt

@@ -49,7 +49,7 @@ class HospitalInfoActivity : BaseActivity<BedHospitalInfoActivityPresenter, Call
     }
 
     private fun showui(){
-        view_title_layout_tv_hospital_name.text ="返回上层"
+        view_title_layout_tv_hospital_name.setText(R.string.str_back)
         view_title_layout_img.visibility = View.VISIBLE
         view_title_layout_tv_no.visibility = View.VISIBLE
         view_title_layout_tv_no.text ="医院介绍"

+ 8 - 109
android_bed/src/main/java/com/wdkl/app/ncs/callingbed/activity/SignActivity.kt

@@ -1,42 +1,19 @@
 package com.wdkl.app.ncs.callingbed.activity
 
-import android.annotation.SuppressLint
-import android.net.http.SslError
 import android.os.Build
 import android.view.View
-import android.view.ViewGroup
-import android.webkit.*
-import android.widget.LinearLayout
 import androidx.annotation.RequiresApi
-import androidx.recyclerview.widget.LinearLayoutManager
 import com.enation.javashop.net.engine.model.NetState
-import com.enation.javashop.utils.base.widget.LoadingDialog
 import com.wdkl.app.ncs.callingbed.R
-import com.wdkl.app.ncs.callingbed.adapter.CostItemAdapter
-import com.wdkl.app.ncs.callingbed.databinding.CallingbedHospitalInfoMainBinding
 import com.wdkl.app.ncs.callingbed.databinding.SignFragmentLayBinding
 import com.wdkl.app.ncs.callingbed.fragment.SignMainFragment
-import com.wdkl.app.ncs.callingbed.helper.CommonDialogHelper
 import com.wdkl.app.ncs.callingbed.launch.CallingbedLaunch
 
 import com.wdkl.ncs.android.lib.base.BaseActivity
-import com.wdkl.ncs.android.lib.base.BaseApplication
-import com.wdkl.ncs.android.lib.utils.showMessage
 import com.wdkl.ncs.android.middleware.common.Constant
 import com.wdkl.ncs.android.middleware.common.MessageEvent
-import com.wdkl.ncs.android.middleware.logic.contract.callingbed.BedCostFragmentContract
-import com.wdkl.ncs.android.middleware.logic.contract.callingbed.BedHospitalInfoActivityContract
 import com.wdkl.ncs.android.middleware.logic.contract.callingbed.BedSignFragmentContract
-import com.wdkl.ncs.android.middleware.logic.contract.callingdoor.SetHintActivityContract
-import com.wdkl.ncs.android.middleware.logic.presenter.callingbed.BedCostFragmentPresenter
-import com.wdkl.ncs.android.middleware.logic.presenter.callingbed.BedHospitalInfoActivityPresenter
 import com.wdkl.ncs.android.middleware.logic.presenter.callingbed.BedSignFragmentPresenter
-import com.wdkl.ncs.android.middleware.logic.presenter.callingdoor.SetHintActivityPresenter
-import com.wdkl.ncs.android.middleware.model.vo.CustomerFeeConfig
-import com.wdkl.ncs.android.middleware.model.vo.CustomerFeeConfigByGroupNameVO
-import kotlinx.android.synthetic.main.cost_view_lay.*
-import kotlinx.android.synthetic.main.sign_fragment_lay.*
-
 import kotlinx.android.synthetic.main.view_title_layout.*
 import org.greenrobot.eventbus.EventBus
 import org.greenrobot.eventbus.Subscribe
@@ -46,10 +23,10 @@ import org.greenrobot.eventbus.ThreadMode
  * 体征
  * */
 class SignActivity : BaseActivity<BedSignFragmentPresenter, SignFragmentLayBinding>(), BedSignFragmentContract.View {
+    private val TAG = "SignActivity"
 
-    private val TAG = "CostActivity"
     override fun getLayId(): Int {
-        return R.layout.sign_fragment_lay
+        return R.layout.activity_sign
     }
 
     override fun bindDagger() {
@@ -59,108 +36,30 @@ class SignActivity : BaseActivity<BedSignFragmentPresenter, SignFragmentLayBindi
     @RequiresApi(Build.VERSION_CODES.O)
     override fun init() {
         showui()
-        //loadingDialog = CommonTool.createLoadingDialog(getActivity(), R.layout.data_loading, R.id.loadding_image)
-        loadingDialog = CommonDialogHelper.createLoadingDialog(activity, R.layout.data_loading, R.id.loadding_image, false)
-        loadingDialog.show()
-        SignMainFragment.webView.webViewClient = object : WebViewClient() {
-            override fun shouldOverrideUrlLoading(view: WebView?, request: WebResourceRequest?): Boolean {
-                return false
-            }
-            override fun onReceivedSslError(view: WebView?, handler: SslErrorHandler?, error: SslError?) {
-                handler?.proceed()
-            }
-
-            override fun onPageFinished(view: WebView?, url: String?) {
-                loadingDialog.dismiss()
-                super.onPageFinished(view, url)
-            }
-        }
 
-        if (Constant.MEMBER_ID != -1) {
-            tv_empty_sign.visibility = View.GONE
-            /*if (am_container.childCount > 0) {
-                am_container.removeAllViews()
-            }*/
-            if (SignMainFragment.webView.parent != null) {
-                (SignMainFragment.webView.parent as ViewGroup).removeView(SignMainFragment.webView)
-            }
-            am_container.addView(SignMainFragment.webView, LinearLayout.LayoutParams.MATCH_PARENT, LinearLayout.LayoutParams.MATCH_PARENT)
-            SignMainFragment.signLoadUrl(Constant.MEMBER_ID, Constant.HTTP_SERVER_URL)
-            //signLoadUrl(1)
-        } else {
-            tv_empty_sign.visibility = View.VISIBLE
-        }
+        supportFragmentManager.beginTransaction()
+            .add(R.id.activity_sign, SignMainFragment())
+            .commitAllowingStateLoss()
     }
 
     override fun destory() {
-        loadingDialog.dismiss()
+
     }
 
     override fun bindEvent() {
-        am_refresh.setOnRefreshListener {
-            if (Constant.MEMBER_ID != -1) {
-                val url = "javascript:refreshData()"
-                SignMainFragment.webView.loadUrl(url)
-            }
-            am_refresh.finishRefresh()
-        }
-        //返回上一层
+        //返回
         view_title_layout_return.setOnClickListener {
-            view_title_layout_img.visibility = View.GONE
-            view_title_layout_tv_no.visibility =View.GONE
             finish()
         }
     }
 
     private fun showui(){
-        view_title_layout_tv_hospital_name.text ="返回上层"
+        view_title_layout_tv_hospital_name.setText(R.string.str_back)
         view_title_layout_img.visibility = View.VISIBLE
         view_title_layout_tv_no.visibility = View.VISIBLE
         view_title_layout_tv_no.text ="体征"
     }
 
-    private lateinit var loadingDialog: LoadingDialog
-    @SuppressLint("JavascriptInterface")
-    companion object {
-        var webView: WebView = WebView(BaseApplication.appContext)
-        fun signLoadUrl(memberId:Int, gateWay:String){
-            webView.loadUrl("file:///android_asset/web/vital_sign_log.html?id=" + memberId + "&gw=" + gateWay)
-        }
-        init {
-            webView.addJavascriptInterface(BaseApplication.appContext,"webview")
-            var webSettings = webView.settings
-            webSettings.javaScriptEnabled = true  // 开启 JavaScript 交互
-
-            webSettings.allowUniversalAccessFromFileURLs = true //跨域
-            webSettings.setAppCacheEnabled(true) // 启用或禁用缓存
-            webSettings.cacheMode = WebSettings.LOAD_DEFAULT // 只要缓存可用就加载缓存, 哪怕已经过期失效 如果缓存不可用就从网络上加载数据
-//        webSettings.setAppCachePath(cacheDir.path) // 设置应用缓存路径
-
-            // 缩放操作
-            webSettings.setSupportZoom(true) // 支持缩放 默认为true 是下面那个的前提
-            webSettings.builtInZoomControls = false // 设置内置的缩放控件 若为false 则该WebView不可缩放
-            webSettings.displayZoomControls = false // 隐藏原生的缩放控件
-
-            webSettings.blockNetworkImage = false // 禁止或允许WebView从网络上加载图片
-            webSettings.loadsImagesAutomatically = true // 支持自动加载图片
-
-            webSettings.javaScriptCanOpenWindowsAutomatically = true // 支持通过JS打开新窗口
-            webSettings.domStorageEnabled = true // 启用或禁用DOM缓存
-            webSettings.setSupportMultipleWindows(false) // 设置WebView是否支持多窗口
-
-            // 设置自适应屏幕, 两者合用
-            webSettings.useWideViewPort = true  // 将图片调整到适合webview的大小
-            webSettings.loadWithOverviewMode = true  // 缩放至屏幕的大小
-            webSettings.allowFileAccess = true // 设置可以访问文件
-
-            webSettings.setGeolocationEnabled(true) // 是否使用地理位置
-
-            webSettings.layoutAlgorithm = WebSettings.LayoutAlgorithm.SINGLE_COLUMN
-            webSettings.textZoom = 150
-
-            webView.fitsSystemWindows = true
-        }
-    }
     override fun onStart() {
         EventBus.getDefault().register(this)
         super.onStart()

+ 1 - 1
android_bed/src/main/java/com/wdkl/app/ncs/callingbed/activity/SystemActivity.kt

@@ -124,7 +124,7 @@ class SystemActivity : BaseActivity<SystemActivityPresenter, CallingbedSettingMa
     }
 
     private fun showui(){
-        view_title_layout_tv_hospital_name.text ="返回"
+        view_title_layout_tv_hospital_name.setText(R.string.str_back)
         view_title_layout_img.visibility = View.VISIBLE
         view_title_layout_tv_no.visibility =View.VISIBLE
         view_title_layout_tv_no.text ="设备信息"

+ 9 - 11
android_bed/src/main/java/com/wdkl/app/ncs/callingbed/activity/TextActivity.kt

@@ -5,21 +5,15 @@ import android.view.KeyEvent
 import android.view.SurfaceHolder
 import android.view.View
 import android.widget.Toast
-
 import com.enation.javashop.net.engine.model.NetState
 import com.wdkl.app.ncs.callingbed.BuildConfig
 import com.wdkl.app.ncs.callingbed.R
 import com.wdkl.app.ncs.callingbed.databinding.CallingbedTestMainBinding
-import com.wdkl.app.ncs.callingbed.di.DaggerCallingbedComponent
-import com.wdkl.app.ncs.callingbed.helper.MediaPlayHelper
-import com.wdkl.app.ncs.callingbed.helper.RecordHelper
-import com.wdkl.app.ncs.callingbed.helper.SerialPortHelper
-import com.wdkl.app.ncs.callingbed.helper.SoundPoolManager
+import com.wdkl.app.ncs.callingbed.helper.*
 import com.wdkl.app.ncs.callingbed.launch.CallingbedLaunch
 import com.wdkl.app.ncs.callingbed.service.WdklSipService
 import com.wdkl.app.ncs.callingbed.settings.SettingConfig
 import com.wdkl.ncs.android.lib.base.BaseActivity
-import com.wdkl.ncs.android.lib.base.BaseApplication
 import com.wdkl.ncs.android.lib.utils.showMessage
 import com.wdkl.ncs.android.lib.vo.filter
 import com.wdkl.ncs.android.middleware.common.Constant
@@ -36,7 +30,6 @@ import org.greenrobot.eventbus.EventBus
 import org.greenrobot.eventbus.Subscribe
 import org.greenrobot.eventbus.ThreadMode
 import org.linphone.core.Core
-import java.security.KeyStore
 
 class TextActivity : BaseActivity<BedTextActivityPresenter, CallingbedTestMainBinding>(), BedTextActivityContract.View {
 
@@ -93,8 +86,6 @@ class TextActivity : BaseActivity<BedTextActivityPresenter, CallingbedTestMainBi
             }else{
                 showMessage("未启动sip服务,请启动服务后,在进行sip通话")
             }
-
-
         }
 
         lycs_button.setOnClickListener {
@@ -109,6 +100,13 @@ class TextActivity : BaseActivity<BedTextActivityPresenter, CallingbedTestMainBi
             finish()
         }
 
+        ll_sip_config_view.setOnClickListener {
+            try {
+                Utils.hideInputKeyboard(activity.window!!.decorView.windowToken)
+            } catch (e: java.lang.Exception) {
+                //
+            }
+        }
     }
 
     override fun destory() {
@@ -125,7 +123,7 @@ class TextActivity : BaseActivity<BedTextActivityPresenter, CallingbedTestMainBi
     }
 
     private fun showui(){
-        view_title_layout_tv_hospital_name.text ="返回上层"
+        view_title_layout_tv_hospital_name.setText(R.string.str_back)
         view_title_layout_img.visibility = View.VISIBLE
         view_title_layout_tv_no.visibility =View.VISIBLE
         view_title_layout_tv_no.text ="设备调试"

+ 13 - 65
android_bed/src/main/java/com/wdkl/app/ncs/callingbed/activity/WebviewActivity.kt

@@ -2,6 +2,7 @@ package com.wdkl.app.ncs.callingbed.activity
 
 import android.graphics.Bitmap
 import android.os.Build
+import android.text.TextUtils
 import android.util.Log
 import android.view.View
 import android.webkit.WebChromeClient
@@ -14,6 +15,7 @@ import com.wdkl.app.ncs.callingbed.R
 import com.wdkl.app.ncs.callingbed.databinding.WebciewLayBinding
 import com.wdkl.app.ncs.callingbed.launch.CallingbedLaunch
 import com.wdkl.ncs.android.lib.base.BaseActivity
+import com.wdkl.ncs.android.lib.utils.showMessage
 import com.wdkl.ncs.android.middleware.common.Constant
 import com.wdkl.ncs.android.middleware.common.MessageEvent
 import com.wdkl.ncs.android.middleware.logic.contract.callingbed.BedWebViewActivityContract
@@ -54,78 +56,24 @@ class WebviewActivity :BaseActivity<BedWebviewActivityPresenter, WebciewLayBindi
         }
         val url = intent.getStringExtra("url") ?: ""
         val key = intent.getStringExtra("key") ?: ""
-//        // 输出结果
-//        showMessage(url+key)
 
-        if (url!=null && key!=null){
-            val result = key.replace("&amp;", "&")
-            Log.d(TAG, "更新后的 url_params_temp 值为:"+url+"?"+result)
-            webview.loadUrl(url+"?"+result)
+        if (!TextUtils.isEmpty(url)){
+            if (!TextUtils.isEmpty(key)) {
+                val result = key.replace("&amp;", "&")
+                Log.d(TAG, "更新后的 url_params_temp 值为:" + url + "?" + result)
+                webview.loadUrl(url+"?"+result)
+            } else {
+                Log.d(TAG, "load url:" + url)
+                webview.loadUrl(url)
+            }
+        } else {
+            showMessage("error: empty url!")
         }
 //        webview.loadUrl("https://www.baidu.com/");
         //带参数
 //        webview.loadDataWithBaseURL(HttpConstant.PATH, content, "text/html", "UTF-8", null);
     }
 
-    fun hookWebView() {
-        val sdkInt = Build.VERSION.SDK_INT
-        try {
-            val factoryClass = Class.forName("android.webkit.WebViewFactory")
-            val field: Field = factoryClass.getDeclaredField("sProviderInstance")
-            field.setAccessible(true)
-            var sProviderInstance: Any? = field.get(null)
-            if (sProviderInstance != null) {
-                Log.i(TAG, "sProviderInstance isn't null")
-                return
-            }
-            val getProviderClassMethod: Method
-            if (sdkInt > 22) {
-                getProviderClassMethod = factoryClass.getDeclaredMethod("getProviderClass")
-            } else if (sdkInt == 22) {
-                getProviderClassMethod = factoryClass.getDeclaredMethod("getFactoryClass")
-            } else {
-                Log.i(TAG, "Don't need to Hook WebView")
-                return
-            }
-            getProviderClassMethod.setAccessible(true)
-            val factoryProviderClass = getProviderClassMethod.invoke(factoryClass) as Class<*>
-            val delegateClass = Class.forName("android.webkit.WebViewDelegate")
-            val delegateConstructor: Constructor<*> = delegateClass.getDeclaredConstructor()
-            delegateConstructor.setAccessible(true)
-            if (sdkInt < 26) { //低于Android O版本
-                val providerConstructor: Constructor<*>? =
-                    factoryProviderClass.getConstructor(delegateClass)
-                if (providerConstructor != null) {
-                    providerConstructor.setAccessible(true)
-                    sProviderInstance =
-                        providerConstructor.newInstance(delegateConstructor.newInstance())
-                }
-            } else {
-                val chromiumMethodName: Field =
-                    factoryClass.getDeclaredField("CHROMIUM_WEBVIEW_FACTORY_METHOD")
-                chromiumMethodName.setAccessible(true)
-                var chromiumMethodNameStr = chromiumMethodName.get(null)
-                if (chromiumMethodNameStr == null) {
-                    chromiumMethodNameStr = "create"
-                }
-                val staticFactory: Method? =
-                    factoryProviderClass.getMethod(chromiumMethodNameStr as String, delegateClass)
-                if (staticFactory != null) {
-                    sProviderInstance =
-                        staticFactory.invoke(null, delegateConstructor.newInstance())
-                }
-            }
-            if (sProviderInstance != null) {
-                field.set("sProviderInstance", sProviderInstance)
-                Log.i(TAG, "Hook success!")
-            } else {
-                Log.i(TAG, "Hook failed!")
-            }
-        } catch (e: Throwable) {
-            Log.w(TAG, e)
-        }
-    }
-
     override fun bindEvent() {
         back_btn.setOnClickListener {
             finish()

+ 17 - 12
android_bed/src/main/java/com/wdkl/app/ncs/callingbed/adapter/CallRecordsItemAdapter.kt

@@ -111,10 +111,11 @@ class CallRecordsItemAdapter(var data: ArrayList<InteractionVO>) : BaseDelegateA
                          binding.callRecordsItemType.text = "未接听"
                          binding.callRecordsItemType.setTextColor(Color.parseColor("#E82222"));
                          binding.callRecordsItemCall.visibility = View.VISIBLE
-                         binding.callRecordsItemCall.text = "重新呼叫"
+                         binding.callRecordsItemCall.text = ""
+                         binding.callRecordsItemCall.background= null
                          binding.callRecordsItemCall.setTextColor(Color.parseColor("#FFFFFF"));
                          binding.callRecordsItemCall.setTextSize(TypedValue.COMPLEX_UNIT_SP, 9f)
-                         binding.callRecordsItemCall.setBackgroundResource(R.drawable.shape_main_call_r_wj_bg)
+                         //binding.callRecordsItemCall.setBackgroundResource(R.drawable.shape_main_call_r_wj_bg)
                      }
                  }else{
                      //呼入
@@ -132,10 +133,11 @@ class CallRecordsItemAdapter(var data: ArrayList<InteractionVO>) : BaseDelegateA
                          binding.callRecordsItemType.text = "未接听"
                          binding.callRecordsItemType.setTextColor(Color.parseColor("#E82222"));
                          binding.callRecordsItemCall.visibility = View.VISIBLE
-                         binding.callRecordsItemCall.text = "重新呼叫"
+                         binding.callRecordsItemCall.text = ""
+                         binding.callRecordsItemCall.background= null
                          binding.callRecordsItemCall.setTextColor(Color.parseColor("#FFFFFF"));
                          binding.callRecordsItemCall.setTextSize(TypedValue.COMPLEX_UNIT_SP, 9f)
-                         binding.callRecordsItemCall.setBackgroundResource(R.drawable.shape_main_call_r_wj_bg)
+                         //binding.callRecordsItemCall.setBackgroundResource(R.drawable.shape_main_call_r_wj_bg)
                      }
                  }
 
@@ -150,10 +152,11 @@ class CallRecordsItemAdapter(var data: ArrayList<InteractionVO>) : BaseDelegateA
                      binding.callRecordsItemType.text = "未响应"
                      binding.callRecordsItemType.setTextColor(Color.parseColor("#E82222"));
                      binding.callRecordsItemCall.visibility = View.VISIBLE
-                     binding.callRecordsItemCall.text = "重新呼叫"
+                     binding.callRecordsItemCall.text = ""
+                     binding.callRecordsItemCall.background= null
                      binding.callRecordsItemCall.setTextColor(Color.parseColor("#FFFFFF"));
                      binding.callRecordsItemCall.setTextSize(TypedValue.COMPLEX_UNIT_SP, 9f)
-                     binding.callRecordsItemCall.setBackgroundResource(R.drawable.shape_main_call_r_wj_bg)
+                     //binding.callRecordsItemCall.setBackgroundResource(R.drawable.shape_main_call_r_wj_bg)
                  }
              }else if (TcpType.REINFORCE.name == itemData.actionType){
                  binding.tabImagev.setImageResource(R.mipmap.sos)
@@ -166,10 +169,11 @@ class CallRecordsItemAdapter(var data: ArrayList<InteractionVO>) : BaseDelegateA
                      binding.callRecordsItemType.text = "未响应"
                      binding.callRecordsItemType.setTextColor(Color.parseColor("#E82222"));
                      binding.callRecordsItemCall.visibility = View.VISIBLE
-                     binding.callRecordsItemCall.text = "重新呼叫"
+                     binding.callRecordsItemCall.text = ""
+                     binding.callRecordsItemCall.background= null
                      binding.callRecordsItemCall.setTextSize(TypedValue.COMPLEX_UNIT_SP, 9f)
                      binding.callRecordsItemCall.setTextColor(Color.parseColor("#FFFFFF"));
-                     binding.callRecordsItemCall.setBackgroundResource(R.drawable.shape_main_call_r_wj_bg)
+                     //binding.callRecordsItemCall.setBackgroundResource(R.drawable.shape_main_call_r_wj_bg)
                  }
              }else if (TcpType.EVENT.name == itemData.actionType){
                  binding.tabImagev.setImageResource(R.mipmap.shijianr)
@@ -186,23 +190,24 @@ class CallRecordsItemAdapter(var data: ArrayList<InteractionVO>) : BaseDelegateA
                      binding.callRecordsItemType.text = "未响应"
                      binding.callRecordsItemType.setTextColor(Color.parseColor("#E82222"));
                      binding.callRecordsItemCall.visibility = View.VISIBLE
-                     binding.callRecordsItemCall.text = "重新呼叫"
+                     binding.callRecordsItemCall.text = ""
+                     binding.callRecordsItemCall.background= null
                      binding.callRecordsItemCall.setTextSize(TypedValue.COMPLEX_UNIT_SP, 9f)
                      binding.callRecordsItemCall.setTextColor(Color.parseColor("#FFFFFF"));
-                     binding.callRecordsItemCall.setBackgroundResource(R.drawable.shape_main_call_r_wj_bg)
+                     //binding.callRecordsItemCall.setBackgroundResource(R.drawable.shape_main_call_r_wj_bg)
                  }
              }
             if (itemData.createDate != null) {
                 binding.callRecordsItemTime.text = TimeHandle.getDateTime(itemData.createDate * 1000, "MM-dd HH:mm")
             }
 
-            binding.callRecordsItemCall.setOnClickListener {
+            /*binding.callRecordsItemCall.setOnClickListener {
 
                 if (itemData.actionAccept!=null){
                     type=0
                 }
                 onItemClickListener?.oncallItemClick(holder.itemView, position,itemData.actionType ,itemData.toDeviceId ,type)
-            }
+            }*/
 
 
 

+ 0 - 3
android_bed/src/main/java/com/wdkl/app/ncs/callingbed/adapter/DeviceMenuapter.kt

@@ -57,12 +57,9 @@ class DeviceMenuapter : RecyclerView.Adapter<DeviceMenuapter.ViewHolder>{
                     .load( data?.get(position).icon_src)
                     .diskCacheStrategy(DiskCacheStrategy.ALL)
                     .into(holder.imageView)
-        }else{
-            holder.imageView.visibility=View.GONE
         }
         holder.actionView.setOnClickListener {
             onItemClickListener?.onItemClick(holder.itemView, position)
-//            onItemClickListener?.onItemClick(holder.itemView, data?.get(position).id)
         }
     }
 

+ 14 - 0
android_bed/src/main/java/com/wdkl/app/ncs/callingbed/dialog/Network2DialogHelper.java

@@ -6,10 +6,12 @@ import android.view.LayoutInflater;
 import android.view.View;
 import android.widget.Button;
 import android.widget.EditText;
+import android.widget.LinearLayout;
 import android.widget.TextView;
 
 import com.wdkl.app.ncs.callingbed.R;
 import com.wdkl.app.ncs.callingbed.helper.NetHelper;
+import com.wdkl.app.ncs.callingbed.helper.Utils;
 import com.wdkl.ncs.android.lib.utils.EthernetUtils;
 import com.wdkl.ncs.android.lib.utils.NetParam;
 //import com.wdkl.ncs.android.lib.utils.EthernetUtils;
@@ -27,6 +29,7 @@ public class Network2DialogHelper {
         View contentView = LayoutInflater.from(activity).inflate(R.layout.main_network_two_dialog, null);
         AlertDialog.Builder builder = new AlertDialog.Builder(activity);
         builder.setView(contentView);
+        LinearLayout layout = contentView.findViewById(R.id.ll_net_config_view);
         EditText network2_ip = contentView.findViewById(R.id.network2_ip);
         EditText network2_wg = contentView.findViewById(R.id.network2_wg);
         EditText network2_ym = contentView.findViewById(R.id.network2_ym);
@@ -36,6 +39,17 @@ public class Network2DialogHelper {
 
         TextView server_determine_button = contentView.findViewById(R.id.server_determine_button);
 
+        layout.setOnClickListener(new View.OnClickListener() {
+            @Override
+            public void onClick(View v) {
+                try {
+                    Utils.hideInputKeyboard(alertDialog.getWindow().getDecorView().getWindowToken());
+                } catch (Exception e) {
+                    //
+                }
+            }
+        });
+
         network2_ip.setText(NetHelper.getInstance().getLocalIP());
         NetParam netParam = NetHelper.getNetInfo(activity);
         if (netParam != null) {

+ 16 - 19
android_bed/src/main/java/com/wdkl/app/ncs/callingbed/dialog/ServicesDialogHelper.java

@@ -2,19 +2,15 @@ package com.wdkl.app.ncs.callingbed.dialog;
 
 import android.app.Activity;
 import android.app.AlertDialog;
-import android.content.Intent;
-import android.view.Gravity;
 import android.view.LayoutInflater;
 import android.view.View;
-import android.view.Window;
-import android.view.WindowManager;
 import android.widget.Button;
 import android.widget.EditText;
-
+import android.widget.LinearLayout;
 
 import com.wdkl.app.ncs.callingbed.R;
+import com.wdkl.app.ncs.callingbed.helper.Utils;
 import com.wdkl.ncs.android.lib.base.BaseApplication;
-import com.wdkl.ncs.android.middleware.model.vo.FrameBedVO;
 import com.wdkl.ncs.android.middleware.utils.CommonUtils;
 
 import static com.wdkl.ncs.android.lib.utils.ExtendMethodsKt.showMessage;
@@ -23,7 +19,7 @@ public class ServicesDialogHelper {
 
     private static AlertDialog alertDialog;
 
-    public static void showDialog(Activity activity, ClickListener clickListener) {
+    public static void showDialog(final Activity activity, ClickListener clickListener) {
 
         View contentView = LayoutInflater.from(activity).inflate(R.layout.main_server_dialog, null);
         AlertDialog.Builder builder = new AlertDialog.Builder(activity);
@@ -31,6 +27,7 @@ public class ServicesDialogHelper {
 
         Button server_determine_button = contentView.findViewById(R.id.server_determine_button);
         Button server_cancel_button = contentView.findViewById(R.id.server_cancel_button);
+        LinearLayout layout = contentView.findViewById(R.id.ll_server_config_view);
         EditText server_ed = contentView.findViewById(R.id.server_ed);
         server_determine_button.setOnClickListener(v -> {
             if (alertDialog != null && alertDialog.isShowing()) {
@@ -52,22 +49,22 @@ public class ServicesDialogHelper {
                 server_ed.setText("");
             }
         });
+
+        layout.setOnClickListener(new View.OnClickListener() {
+            @Override
+            public void onClick(View v) {
+                try {
+                    Utils.hideInputKeyboard(alertDialog.getWindow().getDecorView().getWindowToken());
+                } catch (Exception e) {
+                    //
+                }
+            }
+        });
+
         alertDialog = builder.create();
         alertDialog.setCanceledOnTouchOutside(true);
         alertDialog.setCancelable(true);
         alertDialog.show();
-
-//        //设置dialog宽高及位置
-//        try {
-//            Window window = alertDialog.getWindow();
-//            WindowManager.LayoutParams lp = window.getAttributes();
-//            lp.width = 680;
-//            lp.height = 440;
-//            lp.gravity = Gravity.CENTER;
-//            window.setAttributes(lp);
-//        } catch (Exception e) {
-//            e.printStackTrace();
-//        }
     }
 
     public interface ClickListener{

+ 15 - 12
android_bed/src/main/java/com/wdkl/app/ncs/callingbed/dialog/SystemDialogHelper.java

@@ -10,10 +10,12 @@ import android.view.Window;
 import android.view.WindowManager;
 import android.widget.Button;
 import android.widget.EditText;
+import android.widget.LinearLayout;
 
 
 import com.wdkl.app.ncs.callingbed.R;
 import com.wdkl.app.ncs.callingbed.activity.SystemActivity;
+import com.wdkl.app.ncs.callingbed.helper.Utils;
 import com.wdkl.ncs.android.lib.base.BaseApplication;
 import com.wdkl.ncs.android.middleware.utils.CommonUtils;
 
@@ -30,9 +32,22 @@ public class SystemDialogHelper {
         AlertDialog.Builder builder = new AlertDialog.Builder(activity);
         builder.setView(contentView);
 
+        LinearLayout layout = contentView.findViewById(R.id.ll_password_view);
         Button password_cancel_button = contentView.findViewById(R.id.password_cancel_button);
         Button password_determine_button = contentView.findViewById(R.id.password_determine_button);
         EditText password_ed = contentView.findViewById(R.id.password_ed);
+
+        layout.setOnClickListener(new View.OnClickListener() {
+            @Override
+            public void onClick(View v) {
+                try {
+                    Utils.hideInputKeyboard(alertDialog.getWindow().getDecorView().getWindowToken());
+                } catch (Exception e) {
+                    //
+                }
+            }
+        });
+
         password_cancel_button.setOnClickListener(v -> {
             if (alertDialog != null && alertDialog.isShowing()) {
                 alertDialog.dismiss();
@@ -55,17 +70,5 @@ public class SystemDialogHelper {
         alertDialog.setCanceledOnTouchOutside(true);
         alertDialog.setCancelable(true);
         alertDialog.show();
-
-//        //设置dialog宽高及位置
-//        try {
-//            Window window = alertDialog.getWindow();
-//            WindowManager.LayoutParams lp = window.getAttributes();
-//            lp.width = 680;
-//            lp.height = 440;
-//            lp.gravity = Gravity.CENTER;
-//            window.setAttributes(lp);
-//        } catch (Exception e) {
-//            e.printStackTrace();
-//        }
     }
 }

+ 1 - 1
android_bed/src/main/java/com/wdkl/app/ncs/callingbed/fragment/BaseCallFragment.kt

@@ -146,7 +146,7 @@ abstract class BaseCallFragment: Fragment(), View.OnTouchListener {
     }
 
     protected fun voiceCancel() {
-        if (Constant.DEVICE_ID != null && Constant.interactionId != null) {
+        if (Constant.DEVICE_ID != -1 && Constant.interactionId != -1) {
             val callTcp = VoiceUtil.voiceCancel(tid, Constant.DEVICE_ID, Constant.interactionId)
             TcpClient.getInstance().sendMsg(callTcp.toJson())
         }

+ 17 - 19
android_bed/src/main/java/com/wdkl/app/ncs/callingbed/fragment/CallRecordsFragment.kt

@@ -90,8 +90,13 @@ class CallRecordsFragment : BaseFragment<BedCallRecordsFragmentPresenter, MainCa
         main_call_r_l_rv_2.layoutManager = virtualLayoutManager
         main_call_r_l_rv_2.adapter = delegateAdapter
 
-        presenter.loadCallRecords(page, pageSize, Constant.CUSTOM_ID)
-        presenter.loadEventList(Constant.PART_ID)
+        if (Constant.CUSTOM_ID != -1) {
+            presenter.loadCallRecords(page, pageSize, Constant.CUSTOM_ID)
+        }
+
+        if (Constant.PART_ID != null) {
+            presenter.loadEventList(Constant.PART_ID)
+        }
     }
 
     override fun bindEvent() {
@@ -106,10 +111,6 @@ class CallRecordsFragment : BaseFragment<BedCallRecordsFragmentPresenter, MainCa
         }
         //未接来电
         no_answer_calls_linlyout.setOnClickListener {
-
-            call_records_imagev.visibility = View.GONE
-            no_answer_calls_imagev.visibility = View.VISIBLE
-
             if (listType != 1) {
                 call_records_imagev.visibility = View.GONE
                 no_answer_calls_imagev.visibility = View.VISIBLE
@@ -119,11 +120,9 @@ class CallRecordsFragment : BaseFragment<BedCallRecordsFragmentPresenter, MainCa
             }
         }
         call_records_linlyout.setOnClickListener {
-            call_records_imagev.visibility = View.VISIBLE
-            no_answer_calls_imagev.visibility = View.GONE
             if (listType != 0) {
-                call_records_imagev.visibility = View.GONE
-                no_answer_calls_imagev.visibility = View.VISIBLE
+                call_records_imagev.visibility = View.VISIBLE
+                no_answer_calls_imagev.visibility = View.GONE
                 page = 1
                 listType = 0
                 presenter.loadCallRecords(page, pageSize, Constant.CUSTOM_ID)
@@ -298,12 +297,12 @@ class CallRecordsFragment : BaseFragment<BedCallRecordsFragmentPresenter, MainCa
     override fun oncallItemClick(view: View, keyId: Int, actionType: String, toDeviceId: Int,actionAccept:Int) {
         if (TcpType.VOICE.name == actionType || TcpType.VIDEO.name == actionType){
             if (actionAccept == 0){
-                if (Constant.DEVICE_ID != 0) {
+                if (Constant.DEVICE_ID != -1) {
                     //呼出时停止语音播报及铃声
                     SpeechUtil.getInstance().stopSpeak()
                     RingPlayHelper.stopRingTone()
-
-                    if (toDeviceId == Constant.DEVICE_ID) {
+                    Log.d(TAG, "reply: to deviceId=" + toDeviceId + ", " + Constant.DEVICE_ID)
+                    if (toDeviceId != Constant.DEVICE_ID) {
                         if (Constant.TCP_CONNECTED) {
                             val callTcp = VoiceUtil.voiceCall(Constant.DEVICE_ID, toDeviceId)
                             val transaction = object : TcpCallback(callTcp.tid) {
@@ -321,15 +320,14 @@ class CallRecordsFragment : BaseFragment<BedCallRecordsFragmentPresenter, MainCa
                         } else {
                             showMessage(R.string.net_error)
                         }
-
-                    } else {
-                        showMessage("没有设备id")
                     }
+                } else {
+                    showMessage("没有设备id")
                 }
             }
 
         }else if (TcpType.REINFORCE.name == actionType){
-            if (Constant.DEVICE_ID != 0 && Constant.TCP_CONNECTED) {
+            if (Constant.DEVICE_ID != -1 && Constant.TCP_CONNECTED) {
                 OtherUtil.sendReinforce(Constant.DEVICE_ID)
                 ReinforcementsDialogHelper.showDialog(activity , true)
 //                        WidgetsUtil.showToastWithImage(getString(R.string.support_sent), 200f)
@@ -339,9 +337,9 @@ class CallRecordsFragment : BaseFragment<BedCallRecordsFragmentPresenter, MainCa
             }
 
         }else if (TcpType.SOS.name == actionType){
-            if (Constant.TCP_CONNECTED) {
+            /*if (Constant.TCP_CONNECTED) {
                 SOSHelper.sosStart()
-            }
+            }*/
         }else if (TcpType.EVENT.name == actionType){
 
         }

+ 40 - 1
android_bed/src/main/java/com/wdkl/app/ncs/callingbed/fragment/MainFragment.kt

@@ -11,6 +11,7 @@ import com.wdkl.app.ncs.callingbed.R
 import com.wdkl.app.ncs.callingbed.adapter.DeviceMenuapter
 import com.wdkl.app.ncs.callingbed.adapter.NurseConfigAdpter
 import com.wdkl.app.ncs.callingbed.databinding.MainViewLayoutBinding
+import com.wdkl.app.ncs.callingbed.helper.Utils
 import com.wdkl.app.ncs.callingbed.launch.CallingbedLaunch
 import com.wdkl.ncs.android.lib.base.BaseFragment
 import com.wdkl.ncs.android.lib.utils.*
@@ -38,6 +39,10 @@ import org.greenrobot.eventbus.ThreadMode
 class  MainFragment: BaseFragment<BedMainFragmentPresenter, MainViewLayoutBinding>(), BedMainFragmentContract.View {
     val TAG = "MainFragment"
     private lateinit var nurseConfigAdpter: NurseConfigAdpter
+    private var clickTime: Long = 0
+    private var clickTimes: Int = 1
+
+    private val QR_CODE_URL2 = "http://n.szwdkl.cn?type=BIND_PART_AND_ADDR"
 
     var controlIdArray = intArrayOf(R.id.bed_f_txt1, R.id.bed_f_txt2, R.id.bed_f_txt3, R.id.bed_f_txt4, R.id.bed_f_txt5, R.id.bed_f_txt6)
 
@@ -55,9 +60,44 @@ class  MainFragment: BaseFragment<BedMainFragmentPresenter, MainViewLayoutBindin
         val layoutManager = GridLayoutManager(getActivity(), 3)
         rv_main_view.setLayoutManager(layoutManager)
         updateInfo()
+
+        //便民服务二维码
+        Thread {
+            val builder = StringBuilder()
+            builder.append(QR_CODE_URL2)
+            builder.append("&no=")
+            builder.append(Constant.PART_UNION_ID)
+            builder.append("&page=shopping")
+            builder.append("&addr=")
+            builder.append(Constant.PART_NAME)
+            builder.append(Constant.BED_NAME)
+            val code = EcodeHelper().createQRImage(builder.toString(), 180, null)
+            activity.runOnUiThread {
+                image_qr_code?.setImageBitmap(code)
+            }
+        }.start()
+
+        if (Constant.DEVICE_ID != -1) {
+            ll_qr_code.visibility = View.VISIBLE
+        }
     }
 
     override fun bindEvent() {
+        tv_bed_name_title.setOnClickListener {
+            val time = System.currentTimeMillis()
+            if (time - clickTime < 1500) {
+                clickTimes++
+            } else {
+                clickTimes = 1
+            }
+
+            if (clickTimes >15) {
+                showMessage("enable status bar")
+                Utils.hideStatusBar(activity, false)
+                clickTimes = 1
+            }
+            clickTime = time
+        }
     }
 
     override fun destory() {
@@ -187,7 +227,6 @@ class  MainFragment: BaseFragment<BedMainFragmentPresenter, MainViewLayoutBindin
                    allOrders.add(e)
                }
                nurseConfigAdpter = NurseConfigAdpter(activity, allOrders)
-//               nurseConfigAdpter.setOnItemClickListener(this)
                rv_main_view.adapter = nurseConfigAdpter
                nurseConfigAdpter.updateData(allOrders)
 

+ 4 - 10
android_bed/src/main/java/com/wdkl/app/ncs/callingbed/fragment/NursingWorkFragment.kt

@@ -13,6 +13,8 @@ import com.wdkl.app.ncs.callingbed.R
 import com.wdkl.app.ncs.callingbed.activity.*
 import com.wdkl.app.ncs.callingbed.adapter.DeviceMenuapter
 import com.wdkl.app.ncs.callingbed.databinding.NursingWorkLayBinding
+import com.wdkl.app.ncs.callingbed.dialog.SystemDialogHelper
+import com.wdkl.app.ncs.callingbed.helper.PasswordDialogHelper
 import com.wdkl.app.ncs.callingbed.launch.CallingbedLaunch
 import com.wdkl.ncs.android.lib.base.BaseFragment
 import com.wdkl.ncs.android.lib.utils.showMessage
@@ -22,15 +24,10 @@ import com.wdkl.ncs.android.middleware.common.MessageEvent
 import com.wdkl.ncs.android.middleware.logic.contract.callingbed.BedNursingWorkFragmentContract
 import com.wdkl.ncs.android.middleware.logic.presenter.callingbed.BedNursingWorkFragmentPresenter
 import com.wdkl.ncs.android.middleware.model.vo.DeviceMenulist
-import com.wdkl.ncs.android.middleware.tcp.TcpClient
-import com.wdkl.ncs.android.middleware.tcp.channel.SignInUtil
-import kotlinx.android.synthetic.main.callingbed_main_new.*
 import kotlinx.android.synthetic.main.nursing_work_lay.*
-import kotlinx.android.synthetic.main.view_bed_name.*
 import org.greenrobot.eventbus.EventBus
 import org.greenrobot.eventbus.Subscribe
 import org.greenrobot.eventbus.ThreadMode
-import org.json.JSONObject
 
 
 class
@@ -61,7 +58,7 @@ NursingWorkFragment : BaseFragment<BedNursingWorkFragmentPresenter, NursingWorkL
         recycler.setLayoutManager(layoutManager)
         var part_id =Constant.DEVICE_REGISTER_ID
         if (part_id!=null){
-            presenter.DeviceMenulist(part_id!!)
+            presenter.DeviceMenulist(part_id)
         }
     }
     //点击事件
@@ -165,10 +162,7 @@ NursingWorkFragment : BaseFragment<BedNursingWorkFragmentPresenter, NursingWorkL
             }else if (allOrders.get(keyId).type.equals("ACT")){
 
                 if (allOrders.get(keyId).act_name.equals("SystemActivity")){
-                    //设备信息
-                    val intent = Intent()
-                    intent.setClass(activity, SystemActivity::class.java)
-                    activity.startActivity(intent)
+                    SystemDialogHelper.showDialog(activity)
                 }else if (allOrders.get(keyId).act_name.equals("YhFragment")){
                         //医护
                     (activity as CallingbedActivity).addYhFragment()

+ 2 - 2
android_bed/src/main/java/com/wdkl/app/ncs/callingbed/fragment/SipCallFragment.kt

@@ -129,7 +129,7 @@ class SipCallFragment: BaseCallFragment() {
             val time = System.currentTimeMillis()
             if (time - clickTime > 3000) {
                 if (Constant.TCP_CONNECTED) {
-                    if (Constant.DEVICE_ID != null) {
+                    if (Constant.DEVICE_ID != -1) {
                         OtherUtil.sendReinforce(Constant.DEVICE_ID)
                         ReinforcementsDialogHelper.showDialog(activity,true)
 //                        WidgetsUtil.showToastWithImage(getString(R.string.support_sent), 200f)
@@ -392,7 +392,7 @@ class SipCallFragment: BaseCallFragment() {
             }
 
             Constant.CALL_STATE = Constant.CALL_STANDBY
-            Constant.interactionId = null
+            Constant.interactionId = -1
 
             backToMain()
         }

+ 3 - 2
android_bed/src/main/java/com/wdkl/app/ncs/callingbed/fragment/SkyCallFragment.kt

@@ -116,7 +116,7 @@ class SkyCallFragment: BaseCallFragment(), CallSessionCallback {
         }else{
             view_calling_bed_layout_title.setBackgroundColor(Color.TRANSPARENT);
             calling_bed_layout_call_mian.setBackgroundResource(R.mipmap.call_bg)
-            view_title_layout_tv_hospital_name.text ="返回上层"
+            view_title_layout_tv_hospital_name.setText(R.string.str_back)
             view_title_layout_img.visibility = View.VISIBLE
         }
         view_title_lay_day_img.setImageResource(R.mipmap.riqi_b)
@@ -231,7 +231,7 @@ class SkyCallFragment: BaseCallFragment(), CallSessionCallback {
             val time = System.currentTimeMillis()
             if (time - clickTime > 3000) {
                 if (Constant.TCP_CONNECTED) {
-                    if (Constant.DEVICE_ID != null) {
+                    if (Constant.DEVICE_ID != -1) {
                         OtherUtil.sendReinforce(Constant.DEVICE_ID)
                         ReinforcementsDialogHelper.showDialog(activity,true)
 //                        WidgetsUtil.showToastWithImage(getString(R.string.support_sent), 200f)
@@ -486,6 +486,7 @@ class SkyCallFragment: BaseCallFragment(), CallSessionCallback {
 
             backToMain()
             Constant.CALL_STATE = Constant.CALL_STANDBY
+            Constant.interactionId = -1
         }
     }
 

+ 15 - 0
android_bed/src/main/java/com/wdkl/app/ncs/callingbed/helper/Utils.java

@@ -1,10 +1,14 @@
 package com.wdkl.app.ncs.callingbed.helper;
 
+import android.app.Activity;
 import android.content.Context;
 import android.content.Intent;
 import android.hardware.Camera;
+import android.os.IBinder;
 import android.util.Log;
+import android.view.inputmethod.InputMethodManager;
 
+import com.wdkl.ncs.android.lib.base.BaseApplication;
 import com.wdkl.ncs.android.middleware.common.Constant;
 
 import java.lang.reflect.Method;
@@ -63,4 +67,15 @@ public class Utils {
         }
         context.sendBroadcast(intent);
     }
+
+    //隐藏软键盘
+    public static void hideInputKeyboard(IBinder token) {
+        try {
+            Log.d("keyboard", "hide input keyboard ===== ");
+            InputMethodManager mInputKeyBoard = (InputMethodManager) BaseApplication.appContext.getSystemService(Context.INPUT_METHOD_SERVICE);
+            mInputKeyBoard.hideSoftInputFromWindow(token, 0);
+        } catch (Exception e) {
+            e.printStackTrace();
+        }
+    }
 }

+ 20 - 0
android_bed/src/main/res/layout/activity_sign.xml

@@ -0,0 +1,20 @@
+<?xml version="1.0" encoding="utf-8"?>
+<layout
+    xmlns:android="http://schemas.android.com/apk/res/android">
+    <RelativeLayout
+        android:layout_width="match_parent"
+        android:layout_height="match_parent">
+
+        <include
+            android:id="@+id/activity_layout_title"
+            layout="@layout/view_title_layout" />
+
+        <FrameLayout
+            android:id="@+id/activity_sign"
+            android:layout_width="match_parent"
+            android:layout_height="match_parent"
+            android:layout_below="@id/activity_layout_title"/>
+
+    </RelativeLayout>
+
+</layout>

+ 1 - 1
android_bed/src/main/res/layout/callingbed_activation.xml

@@ -235,7 +235,7 @@
                         android:layout_weight="1"
                         android:gravity="center"
                         android:background="@drawable/shape_main_hos_txt_bg"
-                        android:text="设备重启"
+                        android:text="重启"
                         android:textSize="16sp"
                         android:textColor="@drawable/selector_bottom_btn_text_color" />
 

+ 130 - 139
android_bed/src/main/res/layout/callingbed_main_new.xml

@@ -4,9 +4,8 @@
     <RelativeLayout
         android:layout_width="match_parent"
         android:layout_height="match_parent"
-        android:orientation="horizontal"
+        android:orientation="horizontal">
 
-         >
         <FrameLayout
             android:id="@+id/bed_call_frame_r_h"
             android:layout_width="310dp"
@@ -14,8 +13,8 @@
             android:layout_alignParentRight="true"
             android:layout_below="@+id/calling_bed_layout_hl_title"
             android:layout_marginBottom="@dimen/d20"
-            android:layout_marginTop="@dimen/d8"
-            />
+            android:layout_marginTop="@dimen/d8" />
+
         <!--通话界面-->
         <FrameLayout
             android:id="@+id/bed_call_frame_new"
@@ -30,69 +29,69 @@
             android:layout_height="match_parent"/>
 
         <RelativeLayout
-                android:id="@+id/main_rl_1"
-                android:layout_width="120dp"
-                android:layout_height="match_parent"
-                android:background="@mipmap/bg"
-                android:orientation="vertical">
+            android:id="@+id/main_rl_1"
+            android:layout_width="120dp"
+            android:layout_height="match_parent"
+            android:background="@mipmap/bg"
+            android:orientation="vertical">
 
-                <TextView
-                    android:id="@+id/menu_home"
-                    android:layout_width="match_parent"
-                    android:layout_height="wrap_content"
-                    android:layout_marginTop="18dp"
-                    android:layout_marginRight="@dimen/d15"
-                    android:layout_marginLeft="@dimen/d15"
-                    android:background="@drawable/shape_main_bt_bg"
-                    android:textColor="@color/white"
-                    android:drawablePadding="6dp"
-                    android:gravity="center"
-                    android:clickable="true"
-                    android:padding="10dp"
-                    android:singleLine="true"
-                    android:ellipsize="end"
-                    android:text="@string/str_home"
-                    android:focusableInTouchMode="true"
-                    android:textSize="18sp" />
+            <TextView
+                android:id="@+id/menu_home"
+                android:layout_width="match_parent"
+                android:layout_height="wrap_content"
+                android:layout_marginLeft="@dimen/d15"
+                android:layout_marginTop="18dp"
+                android:layout_marginRight="@dimen/d15"
+                android:background="@drawable/shape_main_bt_bg"
+                android:clickable="true"
+                android:drawablePadding="6dp"
+                android:ellipsize="end"
+                android:focusableInTouchMode="true"
+                android:gravity="center"
+                android:padding="10dp"
+                android:singleLine="true"
+                android:text="@string/str_home"
+                android:textColor="@color/white"
+                android:textSize="18sp" />
 
-                <TextView
-                    android:id="@+id/menu_medical_care"
-                    android:layout_width="match_parent"
-                    android:layout_height="wrap_content"
-                    android:layout_marginTop="18dp"
-                    android:layout_marginRight="@dimen/d15"
-                    android:layout_marginLeft="@dimen/d15"
-                    android:layout_below="@+id/menu_home"
-                    android:background="@drawable/shape_main_bt_bg"
-                    android:textColor="@color/white"
-                    android:drawablePadding="6dp"
-                    android:clickable="true"
-                    android:gravity="center"
-                    android:padding="10dp"
-                    android:singleLine="true"
-                    android:ellipsize="end"
-                    android:text="@string/str_medical_care"
-                    android:visibility="gone"
-                    android:textSize="14sp" />
+            <TextView
+                android:id="@+id/menu_medical_care"
+                android:layout_width="match_parent"
+                android:layout_height="wrap_content"
+                android:layout_below="@+id/menu_home"
+                android:layout_marginLeft="@dimen/d15"
+                android:layout_marginTop="10dp"
+                android:layout_marginRight="@dimen/d15"
+                android:background="@drawable/shape_main_bt_bg"
+                android:clickable="true"
+                android:drawablePadding="6dp"
+                android:ellipsize="end"
+                android:gravity="center"
+                android:padding="10dp"
+                android:singleLine="true"
+                android:text="@string/str_medical_care"
+                android:textColor="@color/white"
+                android:textSize="18sp"
+                android:visibility="gone" />
 
-                <TextView
-                    android:id="@+id/menu_more"
-                    android:layout_width="match_parent"
-                    android:layout_height="wrap_content"
-                    android:layout_marginTop="18dp"
-                    android:layout_marginRight="@dimen/d15"
-                    android:layout_marginLeft="@dimen/d15"
-                    android:layout_below="@+id/menu_medical_care"
-                    android:background="@drawable/shape_main_bt_bg"
-                    android:textColor="@color/white"
-                    android:drawablePadding="6dp"
-                    android:clickable="true"
-                    android:gravity="center"
-                    android:padding="10dp"
-                    android:singleLine="true"
-                    android:ellipsize="end"
-                    android:text="@string/str_more"
-                    android:textSize="18sp" />
+            <TextView
+                android:id="@+id/menu_more"
+                android:layout_width="match_parent"
+                android:layout_height="wrap_content"
+                android:layout_below="@+id/menu_medical_care"
+                android:layout_marginLeft="@dimen/d15"
+                android:layout_marginTop="10dp"
+                android:layout_marginRight="@dimen/d15"
+                android:background="@drawable/shape_main_bt_bg"
+                android:clickable="true"
+                android:drawablePadding="6dp"
+                android:ellipsize="end"
+                android:gravity="center"
+                android:padding="10dp"
+                android:singleLine="true"
+                android:text="@string/str_more"
+                android:textColor="@color/white"
+                android:textSize="18sp" />
 
 
             <LinearLayout
@@ -100,126 +99,122 @@
                 android:layout_width="match_parent"
                 android:layout_height="wrap_content"
                 android:layout_below="@+id/menu_more"
-                android:gravity="center_horizontal"
-                android:clickable="true"
-                android:background="@drawable/shape_bed_bg"
-                android:layout_marginTop="@dimen/d40"
-                android:layout_marginLeft="@dimen/d10"
+                android:layout_marginLeft="@dimen/d20"
+                android:layout_marginTop="@dimen/d20"
                 android:layout_marginRight="@dimen/d10"
+                android:background="@drawable/shape_bed_bg"
+                android:clickable="true"
+                android:gravity="center_horizontal"
                 android:orientation="vertical"
-                android:visibility="gone"
-                >
+                android:visibility="gone">
+
                 <TextView
                     android:id="@+id/main_time_tx_1"
                     android:layout_width="@dimen/d63"
                     android:layout_height="@dimen/d20"
                     android:layout_marginTop="@dimen/d10"
+                    android:background="@drawable/shape_time_ll_name_bg"
+                    android:gravity="center"
                     android:text="添加倒计时"
                     android:textColor="@drawable/selector_bottom_btn_text_color"
-                    android:gravity="center"
-                    android:textStyle="bold"
                     android:textSize="@dimen/font_size_12"
-                    android:background="@drawable/shape_time_ll_name_bg"
-                    />
+                    android:textStyle="bold" />
 
                 <TextView
                     android:id="@+id/main_time_tx_2"
                     android:layout_width="@dimen/d63"
-                    android:layout_height="@dimen/d20"
-                    android:layout_marginTop="@dimen/d10"
+                    android:layout_height="wrap_content"
+                    android:layout_marginTop="@dimen/d8"
+                    android:gravity="center"
                     android:text="00:00:00"
                     android:textColor="@color/black"
-                    android:gravity="center"
-                    android:textStyle="bold"
                     android:textSize="@dimen/font_size_12"
-                    />
+                    android:textStyle="bold" />
+
                 <TextView
                     android:id="@+id/main_time_tx_3"
                     android:layout_width="@dimen/d63"
                     android:layout_height="@dimen/d20"
                     android:layout_marginTop="@dimen/d10"
+                    android:background="@drawable/shape_time_ll_name_bg"
+                    android:gravity="center"
                     android:text="添加倒计时"
                     android:textColor="@drawable/selector_bottom_btn_text_color"
-                    android:gravity="center"
-                    android:textStyle="bold"
                     android:textSize="@dimen/font_size_12"
-                    android:background="@drawable/shape_time_ll_name_bg"
-                    />
+                    android:textStyle="bold" />
 
                 <TextView
                     android:id="@+id/main_time_tx_4"
                     android:layout_width="@dimen/d63"
-                    android:layout_height="@dimen/d20"
-                    android:layout_marginTop="@dimen/d10"
+                    android:layout_height="wrap_content"
+                    android:layout_marginTop="@dimen/d8"
+                    android:gravity="center"
                     android:text="00:00:00"
                     android:textColor="@color/black"
-                    android:gravity="center"
-                    android:textStyle="bold"
                     android:textSize="@dimen/font_size_12"
-                    />
+                    android:textStyle="bold" />
+
                 <TextView
                     android:id="@+id/main_time_tx_5"
                     android:layout_width="@dimen/d63"
                     android:layout_height="@dimen/d20"
                     android:layout_marginTop="@dimen/d10"
+                    android:background="@drawable/shape_time_ll_name_bg"
+                    android:gravity="center"
                     android:text="添加倒计时"
                     android:textColor="@drawable/selector_bottom_btn_text_color"
-                    android:gravity="center"
-                    android:textStyle="bold"
                     android:textSize="@dimen/font_size_12"
-                    android:background="@drawable/shape_time_ll_name_bg"
-                    />
+                    android:textStyle="bold" />
 
                 <TextView
                     android:id="@+id/main_time_tx_6"
                     android:layout_width="@dimen/d63"
-                    android:layout_height="@dimen/d20"
-                    android:layout_marginTop="@dimen/d10"
+                    android:layout_height="wrap_content"
+                    android:layout_marginTop="@dimen/d8"
                     android:layout_marginBottom="@dimen/d10"
+                    android:gravity="center"
                     android:text="00:00:00"
                     android:textColor="@color/black"
-                    android:gravity="center"
-                    android:textStyle="bold"
                     android:textSize="@dimen/font_size_12"
-                    />
+                    android:textStyle="bold" />
             </LinearLayout>
 
 
-                <TextView
-                    android:id="@+id/menu_support"
-                    android:layout_width="96dp"
-                    android:layout_height="96dp"
-                    android:layout_marginLeft="10dp"
-                    android:layout_marginRight="10dp"
-                    android:background="@drawable/selector_zengyuan_bt"
-                    android:clickable="true"
-                    android:drawableTop="@mipmap/zengyuan"
-                    android:layout_above="@+id/menu_call_nurse"
-                    android:gravity="center"
-                    android:padding="20dp"
-                    android:text="@string/str_supports"
-                    android:textColor="@color/white"
-                    android:textSize="18sp" />
+            <TextView
+                android:id="@+id/menu_support"
+                android:layout_width="96dp"
+                android:layout_height="96dp"
+                android:layout_above="@+id/menu_call_nurse"
+                android:layout_marginLeft="10dp"
+                android:layout_marginRight="10dp"
+                android:background="@drawable/selector_zengyuan_bt"
+                android:clickable="true"
+                android:drawableTop="@mipmap/zengyuan"
+                android:gravity="center"
+                android:padding="20dp"
+                android:text="@string/str_supports"
+                android:textColor="@color/white"
+                android:textSize="18sp" />
 
-                <TextView
-                    android:id="@+id/menu_call_nurse"
-                    android:layout_width="96dp"
-                    android:layout_height="96dp"
-                    android:layout_marginLeft="10dp"
-                    android:layout_marginRight="10dp"
-                    android:layout_marginTop="12dp"
-                    android:layout_marginBottom="@dimen/d20"
-                    android:background="@drawable/selector_callhu_bt"
-                    android:clickable="true"
-                    android:drawableTop="@mipmap/hujiao"
-                    android:gravity="center"
-                    android:paddingTop="@dimen/d20"
-                    android:paddingBottom="@dimen/d20"
-                    android:layout_alignParentBottom="true"
-                    android:text="@string/str_call_nurse"
-                    android:textColor="@color/white"
-                    android:textSize="18sp" />
-            </RelativeLayout>
+            <TextView
+                android:id="@+id/menu_call_nurse"
+                android:layout_width="96dp"
+                android:layout_height="96dp"
+                android:layout_alignParentBottom="true"
+                android:layout_marginLeft="10dp"
+                android:layout_marginTop="12dp"
+                android:layout_marginRight="10dp"
+                android:layout_marginBottom="@dimen/d20"
+                android:background="@drawable/selector_callhu_bt"
+                android:clickable="true"
+                android:drawableTop="@mipmap/hujiao"
+                android:gravity="center"
+                android:paddingTop="@dimen/d20"
+                android:paddingBottom="@dimen/d20"
+                android:text="@string/str_call_nurse"
+                android:textColor="@color/white"
+                android:textSize="18sp" />
+        </RelativeLayout>
 
         <RelativeLayout
             android:id="@+id/calling_bed_layout_hl_title"
@@ -383,6 +378,7 @@
             </LinearLayout>
 
         </RelativeLayout>
+
         <RelativeLayout
             android:id="@+id/main_rl_2"
             android:layout_width="match_parent"
@@ -392,8 +388,7 @@
             android:background="#EAF2F9">
             <include
                 android:id="@+id/activity_calling_bed_layout_title_new"
-                layout="@layout/view_title_layout"
-                />
+                layout="@layout/view_title_layout" />
 
             <!--床位fragment区域-->
             <FrameLayout
@@ -402,8 +397,7 @@
                 android:layout_height="match_parent"
                 android:layout_below="@id/activity_calling_bed_layout_title_new"
                 android:layout_marginBottom="10dp"
-                android:layout_marginLeft="20dp"
-                />
+                android:layout_marginLeft="20dp" />
 
             <LinearLayout
                 android:id="@+id/ll_broadcast_view_new"
@@ -508,9 +502,6 @@
                         android:textColor="@color/white"
                         android:textSize="10sp" />
                 </LinearLayout>
-
-
-
             </LinearLayout>
         </RelativeLayout>
 

+ 252 - 247
android_bed/src/main/res/layout/callingbed_test_main.xml

@@ -8,279 +8,284 @@
 
         <include
             android:id="@+id/activity_calling_door_layout_title"
-            layout="@layout/view_title_layout"
-            />
+            layout="@layout/view_title_layout" />
 
 
-
-    <LinearLayout
-        android:layout_width="match_parent"
-        android:layout_height="match_parent"
-        android:orientation="horizontal"
-        android:gravity="center_vertical"
-
-        >
         <LinearLayout
-            android:layout_width="@dimen/d475"
+            android:layout_width="match_parent"
             android:layout_height="match_parent"
-            android:background="@drawable/shape_bed_bg"
-            android:layout_marginTop="@dimen/d63"
-            android:layout_marginLeft="@dimen/d24"
-            android:layout_marginBottom="@dimen/d50"
-            android:gravity="center_horizontal"
-            android:orientation="vertical"
-            >
-            <ImageView
-                android:layout_width="@dimen/d88"
-                android:layout_height="@dimen/d88"
-                android:src="@mipmap/hedimg"
-                android:layout_marginTop="@dimen/d66" />
-
-            <TextView
-                android:layout_width="match_parent"
-                android:layout_height="wrap_content"
-                android:layout_marginTop="20dp"
-                android:text="请输入目标SIP账号"
-                android:textColor="@color/black"
-                android:textStyle="bold"
-                android:textSize="@dimen/font_size_18"
-                android:gravity="center" />
-            <TextView
-
-                android:layout_width="match_parent"
-                android:layout_height="wrap_content"
-                android:layout_marginTop="@dimen/d7"
-                android:text="输入账号进行测试"
-                android:textColor="#7D7D7D"
-                android:textSize="@dimen/font_size_13"
-                android:gravity="center" />
-
-            <EditText
-                android:id="@+id/password_ed"
-                android:layout_width="@dimen/d383"
-                android:layout_height="@dimen/d52"
-                android:hint="请输入账号"
-                android:paddingLeft="@dimen/d26"
-                android:textSize="@dimen/font_size_18"
-                android:gravity="center_vertical"
-                android:layout_below="@+id/nurse_msg_tx_1"
-                android:textStyle="bold"
-                android:background="@drawable/shape_n_login_ed_bg2"
-                android:layout_marginTop="@dimen/d16"
-                />
-            <Button
-                android:id="@+id/text_call_button"
-                android:layout_width="@dimen/d383"
-                android:layout_height="@dimen/d48"
-                android:gravity="center"
-                android:background="@drawable/shape_main_hos_txt_bg"
-                android:text="呼叫测试"
-                android:textSize="16sp"
-                android:layout_marginTop="@dimen/d20"
-
-                android:textColor="@drawable/selector_bottom_btn_text_color"/>
+            android:gravity="center_vertical"
+            android:orientation="horizontal">
 
+            <LinearLayout
+                android:id="@+id/ll_sip_config_view"
+                android:layout_width="@dimen/d475"
+                android:layout_height="match_parent"
+                android:layout_marginLeft="@dimen/d24"
+                android:layout_marginTop="@dimen/d63"
+                android:layout_marginBottom="@dimen/d50"
+                android:background="@drawable/shape_bed_bg"
+                android:gravity="center_horizontal"
+                android:orientation="vertical">
 
-        </LinearLayout>
-        <LinearLayout
-            android:layout_width="@dimen/d491"
-            android:layout_height="match_parent"
-            android:background="@drawable/shape_bed_bg"
-            android:layout_marginTop="@dimen/d63"
-            android:layout_marginRight="@dimen/d28"
-            android:layout_marginLeft="@dimen/d16"
-            android:layout_marginBottom="@dimen/d50"
-            android:gravity="center_horizontal"
-            android:orientation="vertical"
-            >
-            <TextView
-                android:layout_width="match_parent"
-                android:layout_height="wrap_content"
-                android:layout_marginTop="66dp"
-                android:text="外接设备测试"
-                android:textColor="@color/black"
-                android:textStyle="bold"
-                android:textSize="@dimen/font_size_18"
-                android:gravity="center" />
-            <TextView
-                android:layout_width="match_parent"
-                android:layout_height="wrap_content"
-                android:layout_marginTop="@dimen/d7"
-                android:text="请检查外接设备是否已连接再开始测试"
-                android:textColor="@color/black"
-                android:textSize="@dimen/font_size_13"
-                android:gravity="center" />
+                <ImageView
+                    android:layout_width="@dimen/d88"
+                    android:layout_height="@dimen/d88"
+                    android:layout_marginTop="@dimen/d66"
+                    android:src="@mipmap/hedimg" />
 
-            <LinearLayout
-                android:id="@+id/text_ll_1"
-                android:layout_width="match_parent"
-                android:layout_height="wrap_content"
-                android:orientation="horizontal"
-                android:gravity="center"
-                android:layout_marginTop="@dimen/d23"
-                >
-                <Button
-                    android:id="@+id/text_sbaj_button"
-                    android:layout_width="@dimen/d383"
-                    android:layout_height="@dimen/d48"
+                <TextView
+                    android:layout_width="match_parent"
+                    android:layout_height="wrap_content"
+                    android:layout_marginTop="20dp"
                     android:gravity="center"
-                    android:background="@drawable/shape_main_hos_txt_bg"
-                    android:text="手柄按键测试"
-                    android:textSize="16sp"
+                    android:text="请输入目标SIP账号"
+                    android:textColor="@color/black"
+                    android:textSize="@dimen/font_size_18"
+                    android:textStyle="bold" />
 
-                    android:textColor="@drawable/selector_bottom_btn_text_color"/>
-                <ImageView
-                    android:id="@+id/sbaj_img"
-                    android:layout_width="@dimen/d16"
-                    android:layout_height="@dimen/d16"
-                    android:background="@mipmap/gou"
-                    android:visibility="invisible"
-                    android:layout_marginLeft="@dimen/d8"
-                    />
-            </LinearLayout>
-            <LinearLayout
-                android:id="@+id/text_ll_2"
-                android:layout_width="match_parent"
-                android:layout_height="wrap_content"
-                android:orientation="horizontal"
-                android:gravity="center"
-                android:layout_marginTop="@dimen/d23"
-                >
-                <Button
-                    android:id="@+id/text_sbqx_button"
-                    android:layout_width="@dimen/d383"
-                    android:layout_height="@dimen/d48"
+                <TextView
+
+                    android:layout_width="match_parent"
+                    android:layout_height="wrap_content"
+                    android:layout_marginTop="@dimen/d7"
                     android:gravity="center"
-                    android:background="@drawable/shape_main_hos_txt_bg"
-                    android:text="手柄取消测试"
-                    android:textSize="16sp"
+                    android:text="输入账号进行测试"
+                    android:textColor="#7D7D7D"
+                    android:textSize="@dimen/font_size_13" />
 
-                    android:textColor="@drawable/selector_bottom_btn_text_color"/>
-                <ImageView
-                    android:id="@+id/sbqx_img"
-                    android:layout_width="@dimen/d16"
-                    android:layout_height="@dimen/d16"
-                    android:background="@mipmap/gou"
-                    android:visibility="invisible"
-                    android:layout_marginLeft="@dimen/d8"
-                    />
-            </LinearLayout>
-            <LinearLayout
-                android:id="@+id/text_ll_3"
-                android:layout_width="match_parent"
-                android:layout_height="wrap_content"
-                android:orientation="horizontal"
-                android:gravity="center"
-                android:layout_marginTop="@dimen/d16"
-                >
-                <Button
-                    android:id="@+id/mbhj_button"
+                <EditText
+                    android:id="@+id/password_ed"
                     android:layout_width="@dimen/d383"
-                    android:layout_height="@dimen/d48"
-                    android:gravity="center"
-                    android:background="@drawable/shape_main_hos_txt_bg"
-                    android:text="面板按键测试"
-                    android:textSize="16sp"
+                    android:layout_height="@dimen/d52"
+                    android:layout_below="@+id/nurse_msg_tx_1"
+                    android:layout_marginTop="@dimen/d16"
+                    android:background="@drawable/shape_n_login_ed_bg2"
+                    android:gravity="center_vertical"
+                    android:hint="请输入账号"
+                    android:paddingLeft="@dimen/d26"
+                    android:textSize="@dimen/font_size_18"
+                    android:textStyle="bold" />
 
-                    android:textColor="@drawable/selector_bottom_btn_text_color"/>
-                <ImageView
-                    android:id="@+id/mbh_img"
-                    android:layout_width="@dimen/d16"
-                    android:layout_height="@dimen/d16"
-                    android:background="@mipmap/gou"
-                    android:visibility="invisible"
-                    android:layout_marginLeft="@dimen/d8"
-                    />
-            </LinearLayout>
-            <LinearLayout
-                android:id="@+id/text_ll_4"
-                android:layout_width="match_parent"
-                android:layout_height="wrap_content"
-                android:orientation="horizontal"
-                android:gravity="center"
-                android:layout_marginTop="@dimen/d16"
-                >
                 <Button
-                    android:id="@+id/mbhjqx_button"
+                    android:id="@+id/text_call_button"
                     android:layout_width="@dimen/d383"
                     android:layout_height="@dimen/d48"
-                    android:gravity="center"
+                    android:layout_marginTop="@dimen/d20"
                     android:background="@drawable/shape_main_hos_txt_bg"
-                    android:text="面板取消测试"
-                    android:textSize="16sp"
-                    android:textColor="@drawable/selector_bottom_btn_text_color"/>
-                <ImageView
-                    android:id="@+id/mbhjjqx_img"
-                    android:layout_width="@dimen/d16"
-                    android:layout_height="@dimen/d16"
-                    android:background="@mipmap/gou"
-                    android:visibility="invisible"
-                    android:layout_marginLeft="@dimen/d8"
-                    />
-            </LinearLayout>
-            <LinearLayout
-                android:id="@+id/text_ll_5"
-                android:layout_width="match_parent"
-                android:layout_height="wrap_content"
-                android:orientation="horizontal"
-                android:gravity="center"
-                android:layout_marginTop="@dimen/d16"
-                >
-                <Button
-                    android:id="@+id/sos_button"
-                    android:layout_width="@dimen/d383"
-                    android:layout_height="@dimen/d48"
                     android:gravity="center"
-                    android:background="@drawable/shape_main_hos_txt_bg"
-                    android:text="紧急按钮测试"
-                    android:textSize="16sp"
-                    android:textColor="@drawable/selector_bottom_btn_text_color"/>
-                <ImageView
-                    android:id="@+id/sos_img"
-                    android:layout_width="@dimen/d16"
-                    android:layout_height="@dimen/d16"
-                    android:background="@mipmap/gou"
-                    android:visibility="invisible"
-                    android:layout_marginLeft="@dimen/d8"
-                    />
+                    android:text="呼叫测试"
+                    android:textColor="@drawable/selector_bottom_btn_text_color"
+
+                    android:textSize="16sp" />
+
+
             </LinearLayout>
 
             <LinearLayout
-                android:id="@+id/text_ll_6"
-                android:layout_width="match_parent"
-                android:layout_height="wrap_content"
-                android:orientation="horizontal"
-                android:gravity="center"
-                android:clickable="true"
-                android:layout_marginTop="@dimen/d16"
-                >
-                <Button
-                    android:id="@+id/lycs_button"
-                    android:layout_width="@dimen/d383"
-                    android:layout_height="@dimen/d48"
-                    android:gravity="center_vertical"
-                    android:background="@drawable/shape_main_hos_txt_bg"
-                    android:drawableLeft="@mipmap/lu"
-                    android:text="录音测试(点击按钮说话10s)"
-                    android:textSize="16sp"
-                    android:paddingLeft="@dimen/d88"
-                    android:drawablePadding="@dimen/d16"
+                android:layout_width="@dimen/d491"
+                android:layout_height="match_parent"
+                android:layout_marginLeft="@dimen/d16"
+                android:layout_marginTop="@dimen/d63"
+                android:layout_marginRight="@dimen/d28"
+                android:layout_marginBottom="@dimen/d50"
+                android:background="@drawable/shape_bed_bg"
+                android:gravity="center_horizontal"
+                android:orientation="vertical">
+
+                <TextView
+                    android:layout_width="match_parent"
+                    android:layout_height="wrap_content"
+                    android:layout_marginTop="66dp"
+                    android:gravity="center"
+                    android:text="外接设备测试"
+                    android:textColor="@color/black"
+                    android:textSize="@dimen/font_size_18"
+                    android:textStyle="bold" />
+
+                <TextView
+                    android:layout_width="match_parent"
+                    android:layout_height="wrap_content"
+                    android:layout_marginTop="@dimen/d7"
+                    android:gravity="center"
+                    android:text="请检查外接设备是否已连接再开始测试"
+                    android:textColor="@color/black"
+                    android:textSize="@dimen/font_size_13" />
+
+                <LinearLayout
+                    android:id="@+id/text_ll_1"
+                    android:layout_width="match_parent"
+                    android:layout_height="wrap_content"
+                    android:layout_marginTop="@dimen/d23"
+                    android:gravity="center"
+                    android:orientation="horizontal">
+
+                    <Button
+                        android:id="@+id/text_sbaj_button"
+                        android:layout_width="@dimen/d383"
+                        android:layout_height="@dimen/d48"
+                        android:background="@drawable/shape_main_hos_txt_bg"
+                        android:gravity="center"
+                        android:text="手柄按键测试"
+                        android:textColor="@drawable/selector_bottom_btn_text_color"
+
+                        android:textSize="16sp" />
+
+                    <ImageView
+                        android:id="@+id/sbaj_img"
+                        android:layout_width="@dimen/d16"
+                        android:layout_height="@dimen/d16"
+                        android:layout_marginLeft="@dimen/d8"
+                        android:background="@mipmap/gou"
+                        android:visibility="invisible" />
+                </LinearLayout>
+
+                <LinearLayout
+                    android:id="@+id/text_ll_2"
+                    android:layout_width="match_parent"
+                    android:layout_height="wrap_content"
+                    android:layout_marginTop="@dimen/d23"
+                    android:gravity="center"
+                    android:orientation="horizontal">
+
+                    <Button
+                        android:id="@+id/text_sbqx_button"
+                        android:layout_width="@dimen/d383"
+                        android:layout_height="@dimen/d48"
+                        android:background="@drawable/shape_main_hos_txt_bg"
+                        android:gravity="center"
+                        android:text="手柄取消测试"
+                        android:textColor="@drawable/selector_bottom_btn_text_color"
+
+                        android:textSize="16sp" />
+
+                    <ImageView
+                        android:id="@+id/sbqx_img"
+                        android:layout_width="@dimen/d16"
+                        android:layout_height="@dimen/d16"
+                        android:layout_marginLeft="@dimen/d8"
+                        android:background="@mipmap/gou"
+                        android:visibility="invisible" />
+                </LinearLayout>
+
+                <LinearLayout
+                    android:id="@+id/text_ll_3"
+                    android:layout_width="match_parent"
+                    android:layout_height="wrap_content"
+                    android:layout_marginTop="@dimen/d16"
+                    android:gravity="center"
+                    android:orientation="horizontal">
+
+                    <Button
+                        android:id="@+id/mbhj_button"
+                        android:layout_width="@dimen/d383"
+                        android:layout_height="@dimen/d48"
+                        android:background="@drawable/shape_main_hos_txt_bg"
+                        android:gravity="center"
+                        android:text="面板按键测试"
+                        android:textColor="@drawable/selector_bottom_btn_text_color"
+
+                        android:textSize="16sp" />
+
+                    <ImageView
+                        android:id="@+id/mbh_img"
+                        android:layout_width="@dimen/d16"
+                        android:layout_height="@dimen/d16"
+                        android:layout_marginLeft="@dimen/d8"
+                        android:background="@mipmap/gou"
+                        android:visibility="invisible" />
+                </LinearLayout>
+
+                <LinearLayout
+                    android:id="@+id/text_ll_4"
+                    android:layout_width="match_parent"
+                    android:layout_height="wrap_content"
+                    android:layout_marginTop="@dimen/d16"
+                    android:gravity="center"
+                    android:orientation="horizontal">
+
+                    <Button
+                        android:id="@+id/mbhjqx_button"
+                        android:layout_width="@dimen/d383"
+                        android:layout_height="@dimen/d48"
+                        android:background="@drawable/shape_main_hos_txt_bg"
+                        android:gravity="center"
+                        android:text="面板取消测试"
+                        android:textColor="@drawable/selector_bottom_btn_text_color"
+                        android:textSize="16sp" />
+
+                    <ImageView
+                        android:id="@+id/mbhjjqx_img"
+                        android:layout_width="@dimen/d16"
+                        android:layout_height="@dimen/d16"
+                        android:layout_marginLeft="@dimen/d8"
+                        android:background="@mipmap/gou"
+                        android:visibility="invisible" />
+                </LinearLayout>
+
+                <LinearLayout
+                    android:id="@+id/text_ll_5"
+                    android:layout_width="match_parent"
+                    android:layout_height="wrap_content"
+                    android:layout_marginTop="@dimen/d16"
+                    android:gravity="center"
+                    android:orientation="horizontal">
+
+                    <Button
+                        android:id="@+id/sos_button"
+                        android:layout_width="@dimen/d383"
+                        android:layout_height="@dimen/d48"
+                        android:background="@drawable/shape_main_hos_txt_bg"
+                        android:gravity="center"
+                        android:text="紧急按钮测试"
+                        android:textColor="@drawable/selector_bottom_btn_text_color"
+                        android:textSize="16sp" />
+
+                    <ImageView
+                        android:id="@+id/sos_img"
+                        android:layout_width="@dimen/d16"
+                        android:layout_height="@dimen/d16"
+                        android:layout_marginLeft="@dimen/d8"
+                        android:background="@mipmap/gou"
+                        android:visibility="invisible" />
+                </LinearLayout>
+
+                <LinearLayout
+                    android:id="@+id/text_ll_6"
+                    android:layout_width="match_parent"
+                    android:layout_height="wrap_content"
+                    android:layout_marginTop="@dimen/d16"
                     android:clickable="true"
-                    android:textColor="@drawable/selector_bottom_btn_text_color"/>
-                <ImageView
-                    android:id="@+id/lycs_img"
-                    android:layout_width="@dimen/d16"
-                    android:layout_height="@dimen/d16"
-                    android:background="@mipmap/gou"
-                    android:visibility="invisible"
-                    android:layout_marginLeft="@dimen/d8"
-                    />
+                    android:gravity="center"
+                    android:orientation="horizontal">
+
+                    <Button
+                        android:id="@+id/lycs_button"
+                        android:layout_width="@dimen/d383"
+                        android:layout_height="@dimen/d48"
+                        android:background="@drawable/shape_main_hos_txt_bg"
+                        android:clickable="true"
+                        android:drawableLeft="@mipmap/lu"
+                        android:drawablePadding="@dimen/d16"
+                        android:gravity="center_vertical"
+                        android:paddingLeft="@dimen/d88"
+                        android:text="录音测试(点击按钮说话10s)"
+                        android:textColor="@drawable/selector_bottom_btn_text_color"
+                        android:textSize="16sp" />
+
+                    <ImageView
+                        android:id="@+id/lycs_img"
+                        android:layout_width="@dimen/d16"
+                        android:layout_height="@dimen/d16"
+                        android:layout_marginLeft="@dimen/d8"
+                        android:background="@mipmap/gou"
+                        android:visibility="invisible" />
+                </LinearLayout>
+
             </LinearLayout>
 
         </LinearLayout>
 
-    </LinearLayout>
-
 
     </LinearLayout>
 

+ 2 - 2
android_bed/src/main/res/layout/item_icon_lay.xml

@@ -16,7 +16,7 @@
         <LinearLayout
             android:id="@+id/ll_menu_bt"
             android:layout_width="320dp"
-            android:layout_height="140dp"
+            android:layout_height="120dp"
             android:clickable="true"
             android:orientation="horizontal"
             android:gravity="center_vertical"
@@ -27,7 +27,7 @@
                 android:layout_width="@dimen/d80"
                 android:layout_height="@dimen/d80"
                 android:layout_marginLeft="@dimen/d34"
-                />
+                android:src="@drawable/ic_device"/>
 
             <TextView
                 android:id="@+id/tx_menu"

+ 4 - 4
android_bed/src/main/res/layout/main_call_r_dialog.xml

@@ -31,15 +31,15 @@
             android:gravity="center_horizontal"
             >
             <ImageView
-                android:layout_width="@dimen/d13"
-                android:layout_height="@dimen/d13"
+                android:layout_width="@dimen/d20"
+                android:layout_height="@dimen/d20"
                 android:layout_marginTop="@dimen/d16"
                 android:src="@mipmap/zhankai"/>
             <TextView
-                android:layout_width="@dimen/d10"
+                android:layout_width="@dimen/d20"
                 android:layout_height="wrap_content"
                 android:text="收回列表"
-                android:textSize="10sp"
+                android:textSize="20sp"
                 android:layout_marginTop="@dimen/d10"
                 android:textColor="@color/black"/>
         </LinearLayout>

+ 143 - 130
android_bed/src/main/res/layout/main_network_two_dialog.xml

@@ -6,151 +6,164 @@
     android:background="@android:color/transparent">
 
     <LinearLayout
+        android:id="@+id/ll_net_config_view"
         android:layout_width="481dp"
         android:layout_height="441dp"
+        android:background="@color/white"
         android:gravity="center"
-        android:orientation="vertical"
-        android:background="@color/white">
-    <TextView
-        android:layout_width="match_parent"
-        android:layout_height="wrap_content"
-        android:layout_marginTop="23dp"
-        android:text="请设置静态网络"
-        android:textColor="@color/black"
-        android:textStyle="bold"
-        android:textSize="@dimen/font_size_18"
-        android:gravity="center" />
+        android:orientation="vertical">
 
-    <LinearLayout
-        android:layout_width="@dimen/d383"
-        android:layout_height="@dimen/d52"
-        android:layout_marginTop="@dimen/d24"
-        android:gravity="center_vertical"
-        android:orientation="horizontal">
         <TextView
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:text="IP地址"
-            android:textColor="@color/black"
-            android:textStyle="bold"
-            android:textSize="@dimen/font_size_18" />
-        <EditText
-            android:id="@+id/network2_ip"
             android:layout_width="match_parent"
-            android:layout_height="match_parent"
-            android:layout_marginLeft="@dimen/d20"
-            android:background="@drawable/selector_nuser_ed_d"
-            android:hint="请输入IP地址"
-            android:paddingLeft="@dimen/d30"
-            android:textSize="@dimen/font_size_18"
-            android:textStyle="bold" />
-
-    </LinearLayout>
-    <LinearLayout
-        android:layout_width="@dimen/d383"
-        android:layout_height="@dimen/d52"
-        android:layout_marginTop="@dimen/d10"
-        android:gravity="center_vertical"
-        android:orientation="horizontal">
-        <TextView
-            android:layout_width="wrap_content"
             android:layout_height="wrap_content"
-            android:text="网关"
+            android:layout_marginTop="23dp"
+            android:gravity="center"
+            android:text="请设置静态网络"
             android:textColor="@color/black"
-            android:textStyle="bold"
-            android:textSize="@dimen/font_size_18" />
-        <EditText
-            android:id="@+id/network2_wg"
-            android:layout_width="match_parent"
-            android:layout_height="match_parent"
-            android:layout_marginLeft="@dimen/d35"
-            android:background="@drawable/selector_nuser_ed_d"
-            android:hint="请输入网关"
-            android:paddingLeft="@dimen/d30"
             android:textSize="@dimen/font_size_18"
             android:textStyle="bold" />
 
-    </LinearLayout>
+        <LinearLayout
+            android:layout_width="@dimen/d383"
+            android:layout_height="@dimen/d52"
+            android:layout_marginTop="@dimen/d24"
+            android:gravity="center_vertical"
+            android:orientation="horizontal">
 
-    <LinearLayout
-        android:layout_width="@dimen/d383"
-        android:layout_height="@dimen/d52"
-        android:layout_marginTop="@dimen/d10"
-        android:gravity="center_vertical"
-        android:orientation="horizontal">
-        <TextView
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:text="掩码"
-            android:textColor="@color/black"
-            android:textStyle="bold"
-            android:textSize="@dimen/font_size_18" />
-        <EditText
-            android:id="@+id/network2_ym"
-            android:layout_width="match_parent"
-            android:layout_height="match_parent"
-            android:layout_marginLeft="@dimen/d35"
-            android:background="@drawable/selector_nuser_ed_d"
-            android:hint="请输入掩码"
-            android:paddingLeft="@dimen/d30"
-            android:textSize="@dimen/font_size_18"
-            android:textStyle="bold" />
+            <TextView
+                android:layout_width="wrap_content"
+                android:layout_height="wrap_content"
+                android:text="IP地址"
+                android:textColor="@color/black"
+                android:textSize="@dimen/font_size_18"
+                android:textStyle="bold" />
 
-    </LinearLayout>
-    <LinearLayout
-        android:layout_width="@dimen/d383"
-        android:layout_height="@dimen/d52"
-        android:layout_marginTop="@dimen/d10"
-        android:gravity="center_vertical"
-        android:orientation="horizontal">
-        <TextView
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:text="DNS"
-            android:textColor="@color/black"
-            android:textStyle="bold"
-            android:textSize="@dimen/font_size_18" />
-        <EditText
-            android:id="@+id/network2_dns"
-            android:layout_width="match_parent"
-            android:layout_height="match_parent"
-            android:layout_marginLeft="@dimen/d35"
-            android:background="@drawable/selector_nuser_ed_d"
-            android:hint="请输入DNS"
-            android:paddingLeft="@dimen/d30"
-            android:textSize="@dimen/font_size_18"
-            android:textStyle="bold" />
+            <EditText
+                android:id="@+id/network2_ip"
+                android:layout_width="match_parent"
+                android:layout_height="match_parent"
+                android:layout_marginLeft="@dimen/d20"
+                android:background="@drawable/selector_nuser_ed_d"
+                android:hint="请输入IP地址"
+                android:paddingLeft="@dimen/d30"
+                android:textSize="@dimen/font_size_18"
+                android:textStyle="bold" />
 
-    </LinearLayout>
+        </LinearLayout>
 
-    <LinearLayout
-        android:layout_width="@dimen/d383"
-        android:layout_height="@dimen/d52"
-        android:layout_marginTop="@dimen/d24"
-        android:layout_marginBottom="@dimen/d40"
-        android:gravity="center_vertical"
-        android:orientation="horizontal">
-
-        <Button
-            android:id="@+id/network2_cancel_button"
-            android:layout_width="@dimen/d176"
-            android:layout_height="@dimen/d48"
-            android:gravity="center"
-            android:background="@drawable/shape_password_bt_bg"
-            android:text="关闭"
-            android:textSize="16sp"
-            android:textColor="@drawable/selector_bottom_btn_text_color"/>
-        <Button
-            android:id="@+id/network2_determine_button"
-            android:layout_width="@dimen/d176"
-            android:layout_height="@dimen/d48"
-            android:gravity="center"
-            android:background="@drawable/shape_main_hos_txt_bg"
-            android:text="确定"
-            android:textSize="16sp"
-            android:layout_marginLeft="@dimen/d31"
-            android:textColor="@drawable/selector_bottom_btn_text_color"/>
-    </LinearLayout>
+        <LinearLayout
+            android:layout_width="@dimen/d383"
+            android:layout_height="@dimen/d52"
+            android:layout_marginTop="@dimen/d10"
+            android:gravity="center_vertical"
+            android:orientation="horizontal">
+
+            <TextView
+                android:layout_width="wrap_content"
+                android:layout_height="wrap_content"
+                android:text="网关"
+                android:textColor="@color/black"
+                android:textSize="@dimen/font_size_18"
+                android:textStyle="bold" />
+
+            <EditText
+                android:id="@+id/network2_wg"
+                android:layout_width="match_parent"
+                android:layout_height="match_parent"
+                android:layout_marginLeft="@dimen/d35"
+                android:background="@drawable/selector_nuser_ed_d"
+                android:hint="请输入网关"
+                android:paddingLeft="@dimen/d30"
+                android:textSize="@dimen/font_size_18"
+                android:textStyle="bold" />
+
+        </LinearLayout>
+
+        <LinearLayout
+            android:layout_width="@dimen/d383"
+            android:layout_height="@dimen/d52"
+            android:layout_marginTop="@dimen/d10"
+            android:gravity="center_vertical"
+            android:orientation="horizontal">
+
+            <TextView
+                android:layout_width="wrap_content"
+                android:layout_height="wrap_content"
+                android:text="掩码"
+                android:textColor="@color/black"
+                android:textSize="@dimen/font_size_18"
+                android:textStyle="bold" />
+
+            <EditText
+                android:id="@+id/network2_ym"
+                android:layout_width="match_parent"
+                android:layout_height="match_parent"
+                android:layout_marginLeft="@dimen/d35"
+                android:background="@drawable/selector_nuser_ed_d"
+                android:hint="请输入掩码"
+                android:paddingLeft="@dimen/d30"
+                android:textSize="@dimen/font_size_18"
+                android:textStyle="bold" />
+
+        </LinearLayout>
+
+        <LinearLayout
+            android:layout_width="@dimen/d383"
+            android:layout_height="@dimen/d52"
+            android:layout_marginTop="@dimen/d10"
+            android:gravity="center_vertical"
+            android:orientation="horizontal">
+
+            <TextView
+                android:layout_width="wrap_content"
+                android:layout_height="wrap_content"
+                android:text="DNS"
+                android:textColor="@color/black"
+                android:textSize="@dimen/font_size_18"
+                android:textStyle="bold" />
+
+            <EditText
+                android:id="@+id/network2_dns"
+                android:layout_width="match_parent"
+                android:layout_height="match_parent"
+                android:layout_marginLeft="@dimen/d35"
+                android:background="@drawable/selector_nuser_ed_d"
+                android:hint="请输入DNS"
+                android:paddingLeft="@dimen/d30"
+                android:textSize="@dimen/font_size_18"
+                android:textStyle="bold" />
+
+        </LinearLayout>
+
+        <LinearLayout
+            android:layout_width="@dimen/d383"
+            android:layout_height="@dimen/d52"
+            android:layout_marginTop="@dimen/d24"
+            android:layout_marginBottom="@dimen/d40"
+            android:gravity="center_vertical"
+            android:orientation="horizontal">
+
+            <Button
+                android:id="@+id/network2_cancel_button"
+                android:layout_width="@dimen/d176"
+                android:layout_height="@dimen/d48"
+                android:background="@drawable/shape_password_bt_bg"
+                android:gravity="center"
+                android:text="关闭"
+                android:textColor="@drawable/selector_bottom_btn_text_color"
+                android:textSize="16sp" />
+
+            <Button
+                android:id="@+id/network2_determine_button"
+                android:layout_width="@dimen/d176"
+                android:layout_height="@dimen/d48"
+                android:layout_marginLeft="@dimen/d31"
+                android:background="@drawable/shape_main_hos_txt_bg"
+                android:gravity="center"
+                android:text="确定"
+                android:textColor="@drawable/selector_bottom_btn_text_color"
+                android:textSize="16sp" />
+        </LinearLayout>
     </LinearLayout>
 
 </LinearLayout>

+ 69 - 65
android_bed/src/main/res/layout/main_password_dialog.xml

@@ -6,78 +6,82 @@
     android:background="@android:color/transparent">
 
     <LinearLayout
+        android:id="@+id/ll_password_view"
         android:layout_width="481dp"
         android:layout_height="441dp"
-        android:gravity="center"
-        android:orientation="vertical"
         android:background="@color/white"
-        >
-    <ImageView
-        android:layout_width="@dimen/d88"
-        android:layout_height="@dimen/d88"
-        android:src="@mipmap/hedimg"
-        android:layout_marginTop="@dimen/d32" />
+        android:gravity="center"
+        android:orientation="vertical">
 
-    <TextView
-        android:id="@+id/positioning_tip_text"
-        android:layout_width="match_parent"
-        android:layout_height="wrap_content"
-        android:layout_marginTop="20dp"
-        android:text="请输入管理员密码"
-        android:textColor="@color/black"
-        android:textStyle="bold"
-        android:textSize="@dimen/font_size_18"
-        android:gravity="center" />
-    <TextView
-        android:layout_width="match_parent"
-        android:layout_height="wrap_content"
-        android:layout_marginTop="@dimen/d7"
-        android:text="查看设备信息需管理权限"
-        android:textColor="#7D7D7D"
-        android:textSize="@dimen/font_size_18"
-        android:gravity="center" />
+        <ImageView
+            android:layout_width="@dimen/d88"
+            android:layout_height="@dimen/d88"
+            android:layout_marginTop="@dimen/d32"
+            android:src="@mipmap/hedimg" />
 
-    <EditText
-        android:id="@+id/password_ed"
-        android:layout_width="@dimen/d383"
-        android:layout_height="@dimen/d52"
-        android:hint="请输入管理密码"
-        android:paddingLeft="@dimen/d26"
-        android:textSize="@dimen/font_size_18"
-        android:gravity="center_vertical"
-        android:layout_below="@+id/nurse_msg_tx_1"
-        android:inputType="number"
-        android:textStyle="bold"
-        android:background="@drawable/shape_n_login_ed_bg2"
-        android:layout_marginTop="@dimen/d16" />
-    <LinearLayout
-        android:layout_width="@dimen/d383"
-        android:layout_height="@dimen/d52"
-        android:layout_marginTop="@dimen/d24"
-        android:layout_marginBottom="@dimen/d32"
-        android:gravity="center_vertical"
-        android:orientation="horizontal">
-
-        <Button
-            android:id="@+id/password_cancel_button"
-            android:layout_width="@dimen/d176"
-            android:layout_height="@dimen/d48"
+        <TextView
+            android:id="@+id/positioning_tip_text"
+            android:layout_width="match_parent"
+            android:layout_height="wrap_content"
+            android:layout_marginTop="20dp"
             android:gravity="center"
-            android:background="@drawable/shape_password_bt_bg"
-            android:text="关闭"
-            android:textSize="16sp"
-            android:textColor="@drawable/selector_bottom_btn_text_color"/>
-        <Button
-            android:id="@+id/password_determine_button"
-            android:layout_width="@dimen/d176"
-            android:layout_height="@dimen/d48"
+            android:text="请输入管理员密码"
+            android:textColor="@color/black"
+            android:textSize="@dimen/font_size_18"
+            android:textStyle="bold" />
+
+        <TextView
+            android:layout_width="match_parent"
+            android:layout_height="wrap_content"
+            android:layout_marginTop="@dimen/d7"
             android:gravity="center"
-            android:background="@drawable/shape_main_hos_txt_bg"
-            android:text="确定"
-            android:textSize="16sp"
-            android:layout_marginLeft="@dimen/d31"
-            android:textColor="@drawable/selector_bottom_btn_text_color"/>
-    </LinearLayout>
+            android:text="查看设备信息需管理权限"
+            android:textColor="#7D7D7D"
+            android:textSize="@dimen/font_size_18" />
+
+        <EditText
+            android:id="@+id/password_ed"
+            android:layout_width="@dimen/d383"
+            android:layout_height="@dimen/d52"
+            android:layout_below="@+id/nurse_msg_tx_1"
+            android:layout_marginTop="@dimen/d16"
+            android:background="@drawable/shape_n_login_ed_bg2"
+            android:gravity="center_vertical"
+            android:hint="请输入管理密码"
+            android:inputType="number"
+            android:paddingLeft="@dimen/d26"
+            android:textSize="@dimen/font_size_18"
+            android:textStyle="bold" />
+
+        <LinearLayout
+            android:layout_width="@dimen/d383"
+            android:layout_height="@dimen/d52"
+            android:layout_marginTop="@dimen/d24"
+            android:layout_marginBottom="@dimen/d32"
+            android:gravity="center_vertical"
+            android:orientation="horizontal">
+
+            <Button
+                android:id="@+id/password_cancel_button"
+                android:layout_width="@dimen/d176"
+                android:layout_height="@dimen/d48"
+                android:background="@drawable/shape_password_bt_bg"
+                android:gravity="center"
+                android:text="关闭"
+                android:textColor="@drawable/selector_bottom_btn_text_color"
+                android:textSize="16sp" />
+
+            <Button
+                android:id="@+id/password_determine_button"
+                android:layout_width="@dimen/d176"
+                android:layout_height="@dimen/d48"
+                android:layout_marginLeft="@dimen/d31"
+                android:background="@drawable/shape_main_hos_txt_bg"
+                android:gravity="center"
+                android:text="确定"
+                android:textColor="@drawable/selector_bottom_btn_text_color"
+                android:textSize="16sp" />
+        </LinearLayout>
 
     </LinearLayout>
 </LinearLayout>

+ 69 - 67
android_bed/src/main/res/layout/main_server_dialog.xml

@@ -4,81 +4,83 @@
     android:layout_height="match_parent"
     android:gravity="center"
     android:background="@android:color/transparent">
+
     <LinearLayout
+        android:id="@+id/ll_server_config_view"
         android:layout_width="481dp"
         android:layout_height="441dp"
-        android:gravity="center"
-        android:orientation="vertical"
         android:background="@color/white"
-        >
-    <ImageView
-        android:layout_width="@dimen/d88"
-        android:layout_height="@dimen/d88"
-        android:src="@mipmap/hedimg"
-        android:layout_marginTop="@dimen/d42" />
-
-    <TextView
-        android:id="@+id/positioning_tip_text"
-        android:layout_width="match_parent"
-        android:layout_height="wrap_content"
-        android:layout_marginTop="20dp"
-        android:text="请设置服务器地址"
-        android:textColor="@color/black"
-        android:textStyle="bold"
-        android:textSize="@dimen/font_size_18"
-        android:gravity="center" />
-    <TextView
-        android:layout_width="match_parent"
-        android:layout_height="wrap_content"
-        android:layout_marginTop="@dimen/d6"
-        android:text="只可输入数字和小数点"
-        android:textColor="#7D7D7D"
-        android:textSize="@dimen/font_size_18"
-        android:gravity="center" />
-
-    <EditText
-        android:id="@+id/server_ed"
-        android:layout_width="@dimen/d375"
-        android:layout_height="@dimen/d52"
-        android:hint="请输入服务器地址"
-        android:paddingLeft="@dimen/d26"
-        android:textSize="@dimen/font_size_18"
-        android:gravity="center_vertical"
-        android:layout_below="@+id/nurse_msg_tx_1"
-        android:textStyle="bold"
-        android:digits="1234567890."
-        android:background="@drawable/shape_n_login_ed_bg2"
-        android:layout_marginTop="@dimen/d22"
-        />
-    <LinearLayout
-        android:layout_width="@dimen/d383"
-        android:layout_height="@dimen/d52"
-        android:layout_marginTop="@dimen/d30"
-        android:layout_marginBottom="@dimen/d88"
-        android:gravity="center_vertical"
-        android:orientation="horizontal">
+        android:gravity="center"
+        android:orientation="vertical">
 
-        <Button
+        <ImageView
+            android:layout_width="@dimen/d88"
+            android:layout_height="@dimen/d88"
+            android:layout_marginTop="@dimen/d42"
+            android:src="@mipmap/hedimg" />
 
-            android:id="@+id/server_determine_button"
-            android:layout_width="@dimen/d176"
-            android:layout_height="@dimen/d48"
+        <TextView
+            android:id="@+id/positioning_tip_text"
+            android:layout_width="match_parent"
+            android:layout_height="wrap_content"
+            android:layout_marginTop="20dp"
             android:gravity="center"
-            android:background="@drawable/shape_main_hos_txt_bg"
-            android:text="确定"
-            android:textSize="16sp"
-            android:textColor="@drawable/selector_bottom_btn_text_color"/>
-        <Button
-            android:id="@+id/server_cancel_button"
-            android:layout_width="@dimen/d176"
-            android:layout_height="@dimen/d48"
+            android:text="请设置服务器地址"
+            android:textColor="@color/black"
+            android:textSize="@dimen/font_size_18"
+            android:textStyle="bold" />
+
+        <TextView
+            android:layout_width="match_parent"
+            android:layout_height="wrap_content"
+            android:layout_marginTop="@dimen/d6"
             android:gravity="center"
-            android:background="@drawable/shape_main_hos_txt_bg"
-            android:text="重置"
-            android:textSize="16sp"
-            android:layout_marginLeft="@dimen/d31"
-            android:textColor="@drawable/selector_bottom_btn_text_color"/>
-    </LinearLayout>
+            android:text="只可输入数字和小数点"
+            android:textColor="#7D7D7D"
+            android:textSize="@dimen/font_size_18" />
+
+        <EditText
+            android:id="@+id/server_ed"
+            android:layout_width="@dimen/d375"
+            android:layout_height="@dimen/d52"
+            android:layout_marginTop="@dimen/d22"
+            android:background="@drawable/shape_n_login_ed_bg2"
+            android:digits="1234567890."
+            android:gravity="center_vertical"
+            android:hint="请输入服务器地址"
+            android:paddingLeft="@dimen/d26"
+            android:textSize="@dimen/font_size_18"
+            android:textStyle="bold" />
+
+        <LinearLayout
+            android:layout_width="@dimen/d383"
+            android:layout_height="@dimen/d52"
+            android:layout_marginTop="@dimen/d30"
+            android:layout_marginBottom="@dimen/d88"
+            android:gravity="center_vertical"
+            android:orientation="horizontal">
+
+            <Button
+                android:id="@+id/server_determine_button"
+                android:layout_width="@dimen/d176"
+                android:layout_height="@dimen/d48"
+                android:background="@drawable/shape_main_hos_txt_bg"
+                android:gravity="center"
+                android:text="确定"
+                android:textColor="@drawable/selector_bottom_btn_text_color"
+                android:textSize="16sp" />
+
+            <Button
+                android:id="@+id/server_cancel_button"
+                android:layout_width="@dimen/d176"
+                android:layout_height="@dimen/d48"
+                android:layout_marginLeft="@dimen/d31"
+                android:background="@drawable/shape_main_hos_txt_bg"
+                android:gravity="center"
+                android:text="重置"
+                android:textColor="@drawable/selector_bottom_btn_text_color"
+                android:textSize="16sp" />
+        </LinearLayout>
 
     </LinearLayout>
 </LinearLayout>

+ 236 - 233
android_bed/src/main/res/layout/main_view_layout.xml

@@ -4,288 +4,313 @@
     <LinearLayout
         android:layout_width="match_parent"
         android:layout_height="match_parent"
-        android:paddingRight="@dimen/d16"
-        android:orientation="vertical">
+        android:orientation="vertical"
+        android:paddingRight="@dimen/d56">
 
-        <LinearLayout
-            android:id="@+id/ll_room_name"
+        <RelativeLayout
+            android:id="@+id/main_view_bg"
             android:layout_width="match_parent"
-            android:layout_height="300dp"
-            android:orientation="horizontal"
-            android:layout_below="@id/activity_calling_door_layout_title">
-
-            <RelativeLayout
-                android:id="@+id/main_view_bg"
-                android:layout_width="820dp"
-                android:layout_height="match_parent"
-                android:background="@mipmap/bingren_bg">
-
-                <LinearLayout
-                    android:id="@+id/ll_bed"
-                    android:layout_width="@dimen/d250"
-                    android:layout_height="@dimen/d250"
-                    android:orientation="vertical"
-                    android:gravity="center"
-                    android:layout_marginTop="@dimen/d24"
-                    android:layout_marginLeft="@dimen/d24"
-                    android:background="@mipmap/chuanghao_bg2"
-                    >
-                    <TextView
-                        android:id="@+id/tv_bed_name_title"
-                        android:layout_width="wrap_content"
-                        android:layout_height="wrap_content"
-                        android:singleLine="true"
-                        android:ellipsize="end"
-                        android:text="126"
-                        android:textStyle="bold"
-                        android:textColor="@color/txt_number2"
-                        android:textSize="94sp"/>
+            android:layout_height="0dp"
+            android:layout_weight="1"
+            android:background="@mipmap/bingren_bg">
 
-                    <TextView
-                        android:id="@+id/tv_bed_card_no"
-                        android:layout_width="wrap_content"
-                        android:layout_height="wrap_content"
-                        android:text="床位号"
-                        android:textColor="@color/txt_number2"
-                        android:textSize="18sp"/>
-                </LinearLayout>
+            <LinearLayout
+                android:id="@+id/ll_bed"
+                android:layout_width="@dimen/d250"
+                android:layout_height="@dimen/d250"
+                android:layout_marginLeft="@dimen/d10"
+                android:layout_marginTop="@dimen/d24"
+                android:background="@mipmap/chuanghao_bg2"
+                android:gravity="center"
+                android:orientation="vertical">
 
-                <TextView
-                    android:id="@+id/tv_bed_name"
+                <com.wdkl.ncs.android.lib.widget.MarqueeTextView
+                    android:id="@+id/tv_bed_name_title"
                     android:layout_width="wrap_content"
                     android:layout_height="wrap_content"
-                    android:layout_toRightOf="@+id/ll_bed"
-                    android:text="张小斐"
-                    android:layout_marginLeft="@dimen/d38"
-                    android:textColor="@color/white"
-                    android:layout_marginTop="@dimen/d24"
-                    android:textSize="110sp"/>
-
-                <TextView
-                    android:id="@+id/tv_bed_age"
+                    android:ellipsize="marquee"
+                    android:focusable="true"
+                    android:focusableInTouchMode="true"
+                    android:marqueeRepeatLimit="-1"
+                    android:singleLine="true"
+                    android:text="126"
+                    android:textColor="@color/txt_number2"
+                    android:textSize="104sp"
+                    android:textStyle="bold" />
+
+                <!--<TextView
+                    android:id="@+id/tv_bed_card_no"
                     android:layout_width="wrap_content"
                     android:layout_height="wrap_content"
-                    android:layout_toRightOf="@+id/tv_bed_code"
-                    android:text="年龄:28岁"
-                    android:layout_marginLeft="@dimen/d38"
-                    android:layout_below="@+id/tv_bed_name"
-                    android:layout_alignTop="@+id/tv_bed_code"
-                    android:textColor="@color/white"
-                    android:padding="@dimen/d3"
-                    android:textSize="@dimen/font_size_20"/>
+                    android:text="床位号"
+                    android:textColor="@color/txt_number2"
+                    android:textSize="18sp"/>-->
+            </LinearLayout>
 
-                <TextView
-                    android:id="@+id/tv_bed_sex"
-                    android:layout_width="wrap_content"
-                    android:layout_height="wrap_content"
-                    android:text="性别:女"
-                    android:layout_marginLeft="@dimen/d38"
-                    android:layout_toRightOf="@+id/tv_bed_time"
-                    android:layout_alignTop="@+id/tv_bed_time"
-                    android:textColor="@color/white"
-                    android:padding="@dimen/d3"
-                    android:layout_below="@+id/tv_bed_age"
-                    android:textSize="@dimen/font_size_20"/>
+            <com.wdkl.ncs.android.lib.widget.MarqueeTextView
+                android:id="@+id/tv_bed_name"
+                android:layout_width="wrap_content"
+                android:layout_height="wrap_content"
+                android:layout_marginLeft="@dimen/d20"
+                android:layout_marginTop="@dimen/d24"
+                android:layout_toLeftOf="@id/ll_qr_code"
+                android:layout_toRightOf="@+id/ll_bed"
+                android:ellipsize="marquee"
+                android:focusable="true"
+                android:focusableInTouchMode="true"
+                android:marqueeRepeatLimit="-1"
+                android:singleLine="true"
+                android:text="--"
+                android:textColor="@color/white"
+                android:textSize="110sp" />
+
+            <TextView
+                android:id="@+id/tv_bed_code"
+                android:layout_width="wrap_content"
+                android:layout_height="wrap_content"
+                android:layout_below="@+id/tv_bed_name"
+                android:layout_alignLeft="@+id/tv_bed_name"
+                android:layout_marginTop="23dp"
+                android:drawableLeft="@mipmap/zhuyuan"
+                android:drawablePadding="@dimen/d10"
+                android:gravity="center"
+                android:text="住院号码:--"
+                android:textColor="@color/white"
+                android:textSize="@dimen/font_size_20" />
 
-                <TextView
-                    android:id="@+id/tv_bed_code"
-                    android:layout_width="wrap_content"
-                    android:layout_height="wrap_content"
-                    android:layout_below="@+id/tv_bed_name"
-                    android:layout_marginTop="23dp"
-                    android:drawableLeft="@mipmap/zhuyuan"
-                    android:drawablePadding="@dimen/d10"
-                    android:gravity="center"
-                    android:text="住院号码:5412523336122333"
-                    android:textColor="@color/white"
-                    android:layout_alignLeft="@+id/tv_bed_name"
-                    android:textSize="@dimen/font_size_20" />
+            <TextView
+                android:id="@+id/tv_bed_time"
+                android:layout_width="wrap_content"
+                android:layout_height="wrap_content"
+                android:layout_below="@+id/tv_bed_code"
+                android:layout_alignLeft="@+id/tv_bed_name"
+                android:layout_marginTop="@dimen/d18"
+                android:drawableLeft="@mipmap/ruyuan"
+                android:drawablePadding="@dimen/d10"
+                android:gravity="center"
+                android:text="入院日期:--"
+                android:textColor="@color/white"
+                android:textSize="@dimen/font_size_20" />
 
-                <TextView
-                    android:id="@+id/tv_bed_time"
-                    android:layout_width="wrap_content"
-                    android:layout_height="wrap_content"
-                    android:text="入院日期:2023/04/17 11:14"
-                    android:layout_marginTop="@dimen/d18"
-                    android:textColor="@color/white"
-                    android:gravity="center"
-                    android:layout_below="@+id/tv_bed_code"
-                    android:drawableLeft="@mipmap/ruyuan"
-                    android:layout_alignLeft="@+id/tv_bed_name"
-                    android:drawablePadding="@dimen/d10"
-                    android:textSize="@dimen/font_size_20"/>
+            <TextView
+                android:id="@+id/tv_bed_age"
+                android:layout_width="wrap_content"
+                android:layout_height="wrap_content"
+                android:layout_below="@+id/tv_bed_name"
+                android:layout_alignTop="@+id/tv_bed_code"
+                android:layout_marginLeft="@dimen/d48"
+                android:layout_toRightOf="@+id/tv_bed_code"
+                android:padding="@dimen/d3"
+                android:text="年龄:--"
+                android:textColor="@color/white"
+                android:textSize="@dimen/font_size_20" />
+
+            <TextView
+                android:id="@+id/tv_bed_sex"
+                android:layout_width="wrap_content"
+                android:layout_height="wrap_content"
+                android:layout_below="@+id/tv_bed_age"
+                android:layout_alignTop="@+id/tv_bed_time"
+                android:layout_toRightOf="@+id/tv_bed_time"
+                android:layout_marginLeft="@dimen/d48"
+                android:padding="@dimen/d3"
+                android:text="性别:-"
+                android:textColor="@color/white"
+                android:textSize="@dimen/font_size_20" />
 
-            </RelativeLayout>
+            <LinearLayout
+                android:id="@+id/ll_qr_code"
+                android:layout_width="wrap_content"
+                android:layout_height="wrap_content"
+                android:layout_above="@id/tv_bed_age"
+                android:layout_alignParentRight="true"
+                android:layout_margin="10dp"
+                android:layout_marginTop="@dimen/d24"
+                android:gravity="center"
+                android:visibility="gone">
 
+                <ImageView
+                    android:id="@+id/image_qr_code"
+                    android:layout_width="160dp"
+                    android:layout_height="160dp" />
 
+                <TextView
+                    android:layout_width="20dp"
+                    android:layout_height="wrap_content"
+                    android:layout_marginLeft="10dp"
+                    android:gravity="center"
+                    android:text="便民服务"
+                    android:textSize="20sp" />
+            </LinearLayout>
 
-        </LinearLayout>
+        </RelativeLayout>
 
         <LinearLayout
             android:layout_width="match_parent"
-            android:layout_height="match_parent"
-            android:orientation="horizontal"
-            >
-
+            android:layout_height="0dp"
+            android:layout_weight="1.1"
+            android:orientation="horizontal">
 
             <RelativeLayout
                 android:layout_width="wrap_content"
                 android:layout_height="wrap_content">
+
                 <com.scwang.smartrefresh.layout.SmartRefreshLayout
                     android:id="@+id/rv_main_view_ll"
                     android:layout_width="570dp"
                     android:layout_height="match_parent"
-                    app:srlEnableRefresh="false"
                     android:visibility="gone"
-                    >
+                    app:srlEnableRefresh="false">
+
                     <androidx.recyclerview.widget.RecyclerView
                         android:id="@+id/rv_main_view"
                         android:layout_width="567dp"
                         android:layout_height="match_parent"
-                        android:layout_marginTop="@dimen/d20"
-
-                        />
-
-
-
+                        android:layout_marginTop="@dimen/d20" />
                 </com.scwang.smartrefresh.layout.SmartRefreshLayout>
+
                 <RelativeLayout
                     android:id="@+id/rv_main_view_s"
                     android:layout_width="567dp"
                     android:layout_height="wrap_content"
-                    android:layout_marginTop="@dimen/d48"
-                    >
+                    android:layout_marginTop="@dimen/d48">
+
                     <TextView
                         android:id="@+id/bed_f_txt1"
                         android:layout_width="@dimen/d177"
                         android:layout_height="@dimen/d89"
-                        android:text="暂无护理项"
-                        android:gravity="center_vertical"
+                        android:background="@drawable/shape_bed_bg"
                         android:drawableLeft="@mipmap/dengji"
                         android:drawablePadding="@dimen/d14"
+                        android:gravity="center_vertical"
                         android:paddingLeft="@dimen/d19"
                         android:paddingRight="@dimen/d29"
-                        android:background="@drawable/shape_bed_bg"
+                        android:text="暂无护理项"
                         android:textColor="@color/black"
-                        android:textSize="@dimen/font_size_14"/>
+                        android:textSize="@dimen/font_size_14" />
 
                     <TextView
                         android:id="@+id/bed_f_txt2"
                         android:layout_width="@dimen/d177"
                         android:layout_height="@dimen/d89"
-                        android:text="暂无护理项"
-                        android:gravity="center_vertical"
-                        android:layout_toRightOf="@+id/bed_f_txt1"
                         android:layout_marginLeft="@dimen/d18"
+                        android:layout_toRightOf="@+id/bed_f_txt1"
+                        android:background="@drawable/shape_bed_bg"
                         android:drawableLeft="@mipmap/celiang"
                         android:drawablePadding="@dimen/d14"
+                        android:gravity="center_vertical"
                         android:paddingLeft="@dimen/d19"
                         android:paddingRight="@dimen/d29"
-                        android:background="@drawable/shape_bed_bg"
+                        android:text="暂无护理项"
                         android:textColor="@color/black"
-                        android:textSize="@dimen/font_size_14"/>
+                        android:textSize="@dimen/font_size_14" />
+
                     <TextView
                         android:id="@+id/bed_f_txt3"
                         android:layout_width="@dimen/d177"
                         android:layout_height="@dimen/d89"
-                        android:text="暂无护理项"
-                        android:gravity="center_vertical"
-                        android:layout_toRightOf="@+id/bed_f_txt2"
                         android:layout_marginLeft="@dimen/d18"
+                        android:layout_toRightOf="@+id/bed_f_txt2"
+                        android:background="@drawable/shape_bed_bg"
                         android:drawableLeft="@mipmap/geli"
                         android:drawablePadding="@dimen/d14"
+                        android:gravity="center_vertical"
                         android:paddingLeft="@dimen/d19"
                         android:paddingRight="@dimen/d29"
-                        android:background="@drawable/shape_bed_bg"
+                        android:text="暂无护理项"
                         android:textColor="@color/black"
-                        android:textSize="@dimen/font_size_14"/>
+                        android:textSize="@dimen/font_size_14" />
+
                     <TextView
                         android:id="@+id/bed_f_txt4"
                         android:layout_width="@dimen/d177"
                         android:layout_height="@dimen/d89"
-                        android:text="暂无护理项"
                         android:layout_below="@+id/bed_f_txt1"
-                        android:gravity="center_vertical"
+                        android:layout_marginTop="@dimen/d20"
+                        android:background="@drawable/shape_bed_bg"
                         android:drawableLeft="@mipmap/yinshi"
                         android:drawablePadding="@dimen/d14"
+                        android:gravity="center_vertical"
                         android:paddingLeft="@dimen/d19"
                         android:paddingRight="@dimen/d29"
-                        android:layout_marginTop="@dimen/d20"
-                        android:background="@drawable/shape_bed_bg"
+                        android:text="暂无护理项"
                         android:textColor="@color/black"
-                        android:textSize="@dimen/font_size_14"/>
+                        android:textSize="@dimen/font_size_14" />
+
                     <TextView
                         android:id="@+id/bed_f_txt5"
                         android:layout_width="@dimen/d177"
                         android:layout_height="@dimen/d89"
-                        android:text="暂无护理项"
-                        android:gravity="center_vertical"
-                        android:layout_marginTop="@dimen/d20"
                         android:layout_below="@+id/bed_f_txt1"
-                        android:layout_toRightOf="@+id/bed_f_txt4"
                         android:layout_marginLeft="@dimen/d18"
+                        android:layout_marginTop="@dimen/d20"
+                        android:layout_toRightOf="@+id/bed_f_txt4"
+                        android:background="@drawable/shape_bed_bg"
                         android:drawableLeft="@mipmap/guom"
                         android:drawablePadding="@dimen/d14"
+                        android:gravity="center_vertical"
                         android:paddingLeft="@dimen/d19"
                         android:paddingRight="@dimen/d29"
-                        android:background="@drawable/shape_bed_bg"
+                        android:text="暂无护理项"
                         android:textColor="@color/black"
-                        android:textSize="@dimen/font_size_14"/>
+                        android:textSize="@dimen/font_size_14" />
 
                     <TextView
                         android:id="@+id/bed_f_txt6"
                         android:layout_width="@dimen/d177"
                         android:layout_height="@dimen/d89"
-                        android:text="暂无护理项"
-                        android:gravity="center_vertical"
-                        android:layout_marginTop="@dimen/d20"
                         android:layout_below="@+id/bed_f_txt1"
-                        android:layout_toRightOf="@+id/bed_f_txt5"
                         android:layout_marginLeft="@dimen/d18"
+                        android:layout_marginTop="@dimen/d20"
+                        android:layout_toRightOf="@+id/bed_f_txt5"
+                        android:background="@drawable/shape_bed_bg"
                         android:drawableLeft="@mipmap/wu"
                         android:drawablePadding="@dimen/d14"
+                        android:gravity="center_vertical"
                         android:paddingLeft="@dimen/d19"
                         android:paddingRight="@dimen/d29"
-                        android:background="@drawable/shape_bed_bg"
+                        android:text="暂无护理项"
                         android:textColor="@color/txt_setting"
-                        android:textSize="@dimen/font_size_14"/>
+                        android:textSize="@dimen/font_size_14" />
 
                 </RelativeLayout>
             </RelativeLayout>
 
-
-            <LinearLayout
+            <RelativeLayout
                 android:layout_width="@dimen/d240"
                 android:layout_height="match_parent"
-                android:orientation="vertical"
                 android:layout_marginLeft="@dimen/d18"
                 android:layout_marginTop="@dimen/d18"
                 android:background="@drawable/shape_bed_bg">
 
+                <View
+                    android:id="@+id/f_tx_view"
+                    android:layout_width="match_parent"
+                    android:layout_height="1dp"
+                    android:layout_centerInParent="true"
+                    android:background="@color/view_bg" />
+
                 <RelativeLayout
                     android:layout_width="match_parent"
                     android:layout_height="match_parent"
-                    android:layout_weight="1"
+                    android:layout_above="@id/f_tx_view"
                     android:layout_marginRight="@dimen/d5"
-                    >
+                    android:gravity="center_vertical">
 
                     <ImageView
                         android:id="@+id/bed_medic_img"
                         android:layout_width="@dimen/d43"
                         android:layout_height="@dimen/d43"
-                        android:background="@mipmap/ys_img"
                         android:layout_marginLeft="@dimen/d40"
-                        android:layout_centerVertical="true"
-                        />
+                        android:background="@mipmap/ys_img" />
 
                     <TextView
                         android:id="@+id/bed_medic_name"
                         android:layout_width="wrap_content"
                         android:layout_height="wrap_content"
                         android:layout_marginLeft="@dimen/d20"
-                        android:layout_marginTop="@dimen/d28"
                         android:layout_toRightOf="@+id/bed_medic_img"
-                        android:text="张德怀"
+                        android:text="暂无"
                         android:textColor="@color/black"
                         android:textSize="@dimen/font_size_18" />
 
@@ -293,197 +318,175 @@
                         android:id="@+id/bed_medic_info"
                         android:layout_width="wrap_content"
                         android:layout_height="wrap_content"
+                        android:layout_below="@+id/bed_medic_name"
+                        android:layout_marginLeft="@dimen/d20"
                         android:layout_marginTop="@dimen/d8"
+                        android:layout_toRightOf="@+id/bed_medic_img"
                         android:background="@drawable/shape_bed_medic_txt_bg"
-                        android:paddingBottom="@dimen/d3"
                         android:paddingLeft="@dimen/d13"
-                        android:paddingRight="@dimen/d13"
                         android:paddingTop="@dimen/d3"
-                        android:layout_marginLeft="@dimen/d20"
-                        android:layout_toRightOf="@+id/bed_medic_img"
-                        android:layout_below="@+id/bed_medic_name"
+                        android:paddingRight="@dimen/d13"
+                        android:paddingBottom="@dimen/d3"
                         android:text="责任医生"
                         android:textColor="@color/white"
                         android:textSize="@dimen/font_size_16" />
 
                 </RelativeLayout>
 
-
-                <View
-                    android:id="@+id/f_tx_view"
-                    android:layout_width="match_parent"
-                    android:layout_height="1dp"
-                    android:background="@color/view_bg"
-                    android:layout_centerInParent="true" />
-
-
                 <RelativeLayout
                     android:layout_width="match_parent"
                     android:layout_height="match_parent"
-                    android:layout_weight="1"
+                    android:layout_below="@id/f_tx_view"
                     android:layout_marginRight="@dimen/d5"
-                    >
+                    android:gravity="center_vertical">
+
                     <ImageView
                         android:id="@+id/bed_medic_img2"
                         android:layout_width="@dimen/d43"
                         android:layout_height="@dimen/d43"
-                        android:background="@mipmap/hs_img"
                         android:layout_marginLeft="@dimen/d40"
-                        android:layout_centerVertical="true"
-                        />
+                        android:background="@mipmap/hs_img" />
+
                     <TextView
                         android:id="@+id/bed_medic_name2"
                         android:layout_width="wrap_content"
                         android:layout_height="wrap_content"
-                        android:text="李小秀"
-                        android:textColor="@color/black"
-                        android:textSize="@dimen/font_size_18"
-                        android:layout_marginTop="@dimen/d28"
                         android:layout_marginLeft="@dimen/d20"
                         android:layout_toRightOf="@+id/bed_medic_img2"
-                        />
+                        android:text="暂无"
+                        android:textColor="@color/black"
+                        android:textSize="@dimen/font_size_18" />
 
                     <TextView
                         android:id="@+id/bed_medic_info2"
                         android:layout_width="wrap_content"
                         android:layout_height="wrap_content"
-                        android:text="责任护士"
                         android:layout_below="@+id/bed_medic_name2"
-                        android:layout_toRightOf="@+id/bed_medic_img2"
                         android:layout_marginLeft="@dimen/d20"
+                        android:layout_marginTop="@dimen/d8"
+                        android:layout_toRightOf="@+id/bed_medic_img2"
+                        android:background="@drawable/shape_bed_nurse_txt_bg"
                         android:paddingLeft="@dimen/d13"
-                        android:paddingRight="@dimen/d13"
                         android:paddingTop="@dimen/d3"
+                        android:paddingRight="@dimen/d13"
                         android:paddingBottom="@dimen/d3"
-                        android:background="@drawable/shape_bed_nurse_txt_bg"
+                        android:text="责任护士"
                         android:textColor="@color/white"
-                        android:layout_marginTop="@dimen/d8"
-                        android:textSize="@dimen/font_size_16"/>
+                        android:textSize="@dimen/font_size_16" />
 
                 </RelativeLayout>
-            </LinearLayout>
+            </RelativeLayout>
 
             <LinearLayout
                 android:layout_width="@dimen/d240"
                 android:layout_height="match_parent"
-                android:background="@drawable/shape_bed_bg"
                 android:layout_marginLeft="@dimen/d18"
                 android:layout_marginTop="@dimen/d18"
-                android:orientation="vertical"
+                android:background="@drawable/shape_bed_bg"
                 android:gravity="center"
-                android:visibility="gone"
+                android:orientation="vertical"
+                android:visibility="gone">
 
-                >
                 <TextView
                     android:layout_width="@dimen/d128"
                     android:layout_height="@dimen/d36"
-                    android:text="风险提示"
-                    android:gravity="center_vertical"
+                    android:background="@mipmap/fengxian"
                     android:drawableLeft="@mipmap/fengxian2"
                     android:drawablePadding="@dimen/d7"
+                    android:gravity="center_vertical"
                     android:paddingLeft="@dimen/d18"
-                    android:background="@mipmap/fengxian"
+                    android:text="风险提示"
                     android:textColor="@color/white"
-                    android:textSize="@dimen/font_size_14"/>
+                    android:textSize="@dimen/font_size_14" />
 
                 <ScrollView
                     android:id="@+id/scrollView"
                     android:layout_width="match_parent"
-                    android:layout_height="match_parent"
-
-                    >
+                    android:layout_height="match_parent">
 
                     <LinearLayout
                         android:layout_width="match_parent"
                         android:layout_height="match_parent"
-                        android:orientation="vertical"
-                        >
+                        android:orientation="vertical">
 
                         <TextView
                             android:layout_width="match_parent"
                             android:layout_height="@dimen/d50"
                             android:layout_marginLeft="@dimen/d22"
-                            android:layout_marginRight="@dimen/d14"
                             android:layout_marginTop="@dimen/d11"
-                            android:text="做完脊椎手术如何更好的恢复跟着这样做即可!"
-                            android:gravity="center"
+                            android:layout_marginRight="@dimen/d14"
+                            android:background="@drawable/shape_main_txt_bg"
                             android:drawableRight="@mipmap/jiantou"
                             android:drawablePadding="@dimen/d7"
+                            android:gravity="center"
                             android:paddingLeft="@dimen/d18"
-                            android:background="@drawable/shape_main_txt_bg"
+                            android:text="做完脊椎手术如何更好的恢复跟着这样做即可!"
                             android:textColor="@color/txt_setting"
-                            android:textSize="@dimen/font_size_14"/>
+                            android:textSize="@dimen/font_size_14" />
 
 
                         <TextView
                             android:layout_width="match_parent"
                             android:layout_height="@dimen/d50"
                             android:layout_marginLeft="@dimen/d22"
-                            android:layout_marginRight="@dimen/d14"
                             android:layout_marginTop="@dimen/d11"
-                            android:text="做完脊椎手术如何更好的恢复跟着这样做即可!"
-                            android:gravity="center"
+                            android:layout_marginRight="@dimen/d14"
+                            android:background="@drawable/shape_main_txt_bg"
                             android:drawableRight="@mipmap/jiantou"
                             android:drawablePadding="@dimen/d7"
+                            android:gravity="center"
                             android:paddingLeft="@dimen/d18"
-                            android:background="@drawable/shape_main_txt_bg"
+                            android:text="做完脊椎手术如何更好的恢复跟着这样做即可!"
                             android:textColor="@color/txt_setting"
-                            android:textSize="@dimen/font_size_14"/>
+                            android:textSize="@dimen/font_size_14" />
 
                         <TextView
                             android:layout_width="match_parent"
                             android:layout_height="@dimen/d50"
                             android:layout_marginLeft="@dimen/d22"
-                            android:layout_marginRight="@dimen/d14"
                             android:layout_marginTop="@dimen/d11"
-                            android:text="做完脊椎手术如何更好的恢复跟着这样做即可!"
-                            android:gravity="center"
+                            android:layout_marginRight="@dimen/d14"
+                            android:background="@drawable/shape_main_txt_bg"
                             android:drawableRight="@mipmap/jiantou"
                             android:drawablePadding="@dimen/d7"
+                            android:gravity="center"
                             android:paddingLeft="@dimen/d18"
-                            android:background="@drawable/shape_main_txt_bg"
+                            android:text="做完脊椎手术如何更好的恢复跟着这样做即可!"
                             android:textColor="@color/txt_setting"
-                            android:textSize="@dimen/font_size_14"/>
+                            android:textSize="@dimen/font_size_14" />
 
                         <TextView
                             android:layout_width="match_parent"
                             android:layout_height="@dimen/d50"
                             android:layout_marginLeft="@dimen/d22"
-                            android:layout_marginRight="@dimen/d14"
                             android:layout_marginTop="@dimen/d11"
-                            android:text="做完脊椎手术如何更好的恢复跟着这样做即可!"
-                            android:gravity="center"
+                            android:layout_marginRight="@dimen/d14"
+                            android:background="@drawable/shape_main_txt_bg"
                             android:drawableRight="@mipmap/jiantou"
                             android:drawablePadding="@dimen/d7"
+                            android:gravity="center"
                             android:paddingLeft="@dimen/d18"
-                            android:background="@drawable/shape_main_txt_bg"
+                            android:text="做完脊椎手术如何更好的恢复跟着这样做即可!"
                             android:textColor="@color/txt_setting"
-                            android:textSize="@dimen/font_size_14"/>
+                            android:textSize="@dimen/font_size_14" />
+
                         <TextView
                             android:layout_width="match_parent"
                             android:layout_height="@dimen/d50"
                             android:layout_marginLeft="@dimen/d22"
-                            android:layout_marginRight="@dimen/d14"
                             android:layout_marginTop="@dimen/d11"
-                            android:text="做完手术如何更好的恢复跟着这样做即可!"
-                            android:gravity="center"
+                            android:layout_marginRight="@dimen/d14"
+                            android:background="@drawable/shape_main_txt_bg"
                             android:drawableRight="@mipmap/jiantou"
                             android:drawablePadding="@dimen/d7"
+                            android:gravity="center"
                             android:paddingLeft="@dimen/d18"
-                            android:background="@drawable/shape_main_txt_bg"
+                            android:text="做完手术如何更好的恢复跟着这样做即可!"
                             android:textColor="@color/txt_setting"
-                            android:textSize="@dimen/font_size_14"/>
+                            android:textSize="@dimen/font_size_14" />
                     </LinearLayout>
-
-
-
-
-
                 </ScrollView>
-
-
             </LinearLayout>
-
         </LinearLayout>
     </LinearLayout>
 </layout>

+ 3 - 10
android_bed/src/main/res/layout/nursing_work_lay.xml

@@ -1,24 +1,17 @@
 <?xml version="1.0" encoding="utf-8"?>
-<layout xmlns:android="http://schemas.android.com/apk/res/android"
-   >
-
-    <data>
-
-    </data>
+<layout xmlns:android="http://schemas.android.com/apk/res/android">
 
     <RelativeLayout
         android:layout_width="match_parent"
         android:layout_height="match_parent"
-        android:background="#EAF2F9"
-        >
+        android:background="#EAF2F9">
 
         <androidx.recyclerview.widget.RecyclerView
             android:id="@+id/recycler"
             android:layout_width="match_parent"
             android:layout_height="match_parent"
             android:background="#EAF2F9"
-            android:clipChildren="true"
-            />
+            android:clipChildren="true" />
 
     </RelativeLayout>
 </layout>

+ 0 - 6
android_bed/src/main/res/layout/sign_fragment_lay.xml

@@ -6,17 +6,11 @@
         android:layout_width="match_parent"
         android:layout_height="match_parent">
 
-        <include
-            android:id="@+id/activity_calling_door_layout_title"
-            layout="@layout/view_title_layout"
-            />
-
         <com.scwang.smartrefresh.layout.SmartRefreshLayout
             android:id="@+id/am_refresh"
             android:layout_width="match_parent"
             android:layout_height="match_parent"
             bind:srlEnableRefresh="true"
-            android:layout_below="@+id/activity_calling_door_layout_title"
             bind:srlEnableLoadMore="false">
 
             <ScrollView

+ 42 - 44
android_bed/src/main/res/layout/view_title_layout.xml

@@ -1,26 +1,23 @@
 <?xml version="1.0" encoding="utf-8"?>
 <RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
+    android:id="@+id/view_calling_bed_layout_title"
     android:layout_width="match_parent"
-    android:layout_height="42dp"
-    >
-
-   <RelativeLayout
-       android:id="@+id/view_calling_bed_layout_title"
-       android:layout_width="match_parent"
-       android:layout_height="42dp"
-       >
+    android:layout_height="42dp">
 
     <!--设备号-->
     <LinearLayout
         android:id="@+id/view_title_layout_return"
-        android:layout_width="@dimen/d105"
-        android:layout_height="@dimen/d30"
+        android:layout_width="wrap_content"
+        android:layout_height="wrap_content"
+        android:layout_centerVertical="true"
         android:layout_marginLeft="20dp"
         android:background="@drawable/shape_main_hos_txt_bg"
         android:clickable="true"
+        android:focusable="true"
         android:gravity="center"
-        android:layout_centerVertical="true"
-        android:orientation="horizontal">
+        android:orientation="horizontal"
+        android:paddingLeft="10dp"
+        android:paddingRight="10dp">
 
         <ImageView
             android:id="@+id/view_title_layout_img"
@@ -28,41 +25,42 @@
             android:layout_height="wrap_content"
             android:layout_gravity="center_vertical"
             android:layout_marginRight="6dp"
-            android:visibility="gone"
-            android:background="@mipmap/return_w" />
+            android:background="@mipmap/return_w"
+            android:visibility="gone" />
         <!--医院名称-->
         <TextView
             android:id="@+id/view_title_layout_tv_hospital_name"
             android:layout_width="wrap_content"
             android:layout_height="wrap_content"
+            android:ellipsize="marquee"
+            android:singleLine="true"
             android:text="科室名称"
             android:textColor="@color/white"
-            android:singleLine="true"
-            android:ellipsize="marquee"
             android:textSize="@dimen/font_size_18" />
     </LinearLayout>
 
-       <ImageView
-           android:id="@+id/view_title_layout_tv_no_img"
-           android:layout_width="@dimen/d22"
-           android:layout_height="@dimen/d22"
-           android:layout_centerVertical="true"
-           android:layout_centerHorizontal="true"
-           android:layout_marginRight="10dp"
-           android:visibility="gone"
-           android:layout_toLeftOf="@+id/view_title_layout_tv_no"
-           android:background="@mipmap/dun" />
+    <ImageView
+        android:id="@+id/view_title_layout_tv_no_img"
+        android:layout_width="@dimen/d22"
+        android:layout_height="@dimen/d22"
+        android:layout_centerHorizontal="true"
+        android:layout_centerVertical="true"
+        android:layout_marginRight="10dp"
+        android:layout_toLeftOf="@+id/view_title_layout_tv_no"
+        android:background="@mipmap/dun"
+        android:visibility="gone" />
+
     <TextView
         android:id="@+id/view_title_layout_tv_no"
         android:layout_width="wrap_content"
         android:layout_height="wrap_content"
-        android:layout_centerVertical="true"
         android:layout_centerHorizontal="true"
+        android:layout_centerVertical="true"
         android:layout_marginRight="10dp"
         android:text="ID:"
-        android:visibility="gone"
         android:textColor="@color/black"
-        android:textSize="@dimen/font_size_18" />
+        android:textSize="@dimen/font_size_18"
+        android:visibility="gone" />
 
     <!--状态图标-->
     <LinearLayout
@@ -88,12 +86,12 @@
             android:layout_width="wrap_content"
             android:layout_height="wrap_content"
             android:layout_gravity="center_vertical"
+            android:layout_marginLeft="@dimen/d5"
             android:format12Hour="yyyy-MM-dd EEEE"
             android:format24Hour="yyyy-MM-dd EEEE"
+            android:text="16:08"
             android:textColor="@color/black"
-            android:textSize="@dimen/font_size_18"
-            android:layout_marginLeft="@dimen/d5"
-            android:text="16:08"/>
+            android:textSize="@dimen/font_size_18" />
 
         <ImageView
             android:id="@+id/view_title_lay_time_img"
@@ -109,13 +107,13 @@
             android:layout_width="wrap_content"
             android:layout_height="wrap_content"
             android:layout_gravity="center_vertical"
+            android:layout_marginLeft="@dimen/d5"
+            android:layout_marginRight="@dimen/d30"
             android:format12Hour="HH:mm"
             android:format24Hour="HH:mm"
+            android:text="16:08"
             android:textColor="@color/black"
-            android:textSize="@dimen/font_size_18"
-            android:layout_marginLeft="@dimen/d5"
-            android:layout_marginRight="@dimen/d30"
-            android:text="16:08"/>
+            android:textSize="@dimen/font_size_18" />
 
         <!--SIP状态图标-->
         <TextView
@@ -125,8 +123,8 @@
             android:layout_centerVertical="true"
             android:layout_marginLeft="4dp"
             android:layout_marginRight="4dp"
-            android:visibility="gone"
-            android:background="@mipmap/sip_b"/>
+            android:background="@mipmap/sip_b"
+            android:visibility="gone" />
 
         <ImageView
             android:id="@+id/view_title_layout_iv_bt"
@@ -135,7 +133,8 @@
             android:layout_gravity="center_vertical"
             android:layout_marginLeft="4dp"
             android:layout_marginRight="4dp"
-            android:visibility="gone"/>
+            android:visibility="gone" />
+
         <ImageView
             android:id="@+id/view_title_layout_iv_wifi"
             android:layout_width="20dp"
@@ -143,7 +142,8 @@
             android:layout_gravity="center_vertical"
             android:layout_marginLeft="4dp"
             android:layout_marginRight="4dp"
-            android:visibility="gone"/>
+            android:visibility="gone" />
+
         <ImageView
             android:id="@+id/view_title_layout_iv_tcp"
             android:layout_width="20dp"
@@ -151,7 +151,7 @@
             android:layout_gravity="center_vertical"
             android:layout_marginLeft="4dp"
             android:layout_marginRight="4dp"
-            android:src="@mipmap/ic_tcp_fail"/>
+            android:src="@mipmap/ic_tcp_fail" />
 
         <ImageView
             android:id="@+id/view_title_layout_iv_ethernet"
@@ -160,7 +160,7 @@
             android:layout_gravity="center_vertical"
             android:layout_marginLeft="4dp"
             android:layout_marginRight="4dp"
-            android:visibility="gone"/>
+            android:visibility="gone" />
 
         <ImageView
             android:id="@+id/view_title_layout_iv_day_night"
@@ -173,6 +173,4 @@
 
     </LinearLayout>
 
-   </RelativeLayout>
-
 </RelativeLayout>

+ 1 - 1
callingdoor/src/main/java/com/wdkl/app/ncs/callingdoor/activity/DepartmentInfoActivity.kt

@@ -50,7 +50,7 @@ class DepartmentInfoActivity : BaseActivity<BedHospitalInfoActivityPresenter, Ca
     }
 
     private fun showui(){
-        view_title_layout_tv_hospital_name.text ="返回上层"
+        view_title_layout_tv_hospital_name.setText(R.string.str_back)
         view_title_layout_img.visibility = View.VISIBLE
         view_title_layout_tv_no.visibility = View.VISIBLE
         view_title_layout_tv_no.text ="科室介绍"

+ 1 - 1
callingdoor/src/main/java/com/wdkl/app/ncs/callingdoor/activity/HospitalInfoActivity.kt

@@ -49,7 +49,7 @@ class HospitalInfoActivity : BaseActivity<BedHospitalInfoActivityPresenter, Call
     }
 
     private fun showui(){
-        view_title_layout_tv_hospital_name.text ="返回上层"
+        view_title_layout_tv_hospital_name.setText(R.string.str_back)
         view_title_layout_img.visibility = View.VISIBLE
         view_title_layout_tv_no.visibility = View.VISIBLE
         view_title_layout_tv_no.text ="医院介绍"

+ 1 - 1
callingdoor/src/main/java/com/wdkl/app/ncs/callingdoor/activity/SetHintActivity.kt

@@ -49,7 +49,7 @@ class SetHintActivity : BaseActivity<SetHintActivityPresenter, CallingdoorNurseM
     }
 
     private fun showui(){
-        view_title_layout_tv_hospital_name.text ="返回上层"
+        view_title_layout_tv_hospital_name.setText(R.string.str_back)
         view_title_layout_img.visibility = View.VISIBLE
         view_title_layout_tv_no.visibility = View.VISIBLE
         view_title_layout_tv_no.text ="设置提示语"

+ 1 - 1
callingdoor/src/main/java/com/wdkl/app/ncs/callingdoor/activity/SystemActivity.kt

@@ -98,7 +98,7 @@ class SystemActivity : BaseActivity<SystemActivityPresenter, CallingdoorSettingM
     }
 
     private fun showui(){
-        view_title_layout_tv_hospital_name.text ="返回上层"
+        view_title_layout_tv_hospital_name.setText(R.string.str_back)
         view_title_layout_img.visibility = View.VISIBLE
         view_title_layout_tv_no.visibility =View.VISIBLE
         view_title_layout_tv_no.text ="设备信息"

+ 1 - 1
callingdoor/src/main/java/com/wdkl/app/ncs/callingdoor/activity/TextActivity.kt

@@ -111,7 +111,7 @@ class TextActivity : BaseActivity<TextActivityPresenter, CallingdoorTestMainBind
     }
 
     private fun showui(){
-        view_title_layout_tv_hospital_name.text ="返回上层"
+        view_title_layout_tv_hospital_name.setText(R.string.str_back)
         view_title_layout_img.visibility = View.VISIBLE
         view_title_layout_tv_no.visibility =View.VISIBLE
         view_title_layout_tv_no.text ="设备调试"

+ 65 - 0
common/src/main/code/com/wdkl/ncs/android/lib/base/BaseActivity.kt

@@ -2,9 +2,11 @@ package com.wdkl.ncs.android.lib.base
 
 import android.content.Context
 import android.content.Intent
+import android.os.Build
 import androidx.databinding.DataBindingUtil
 import androidx.databinding.ViewDataBinding
 import android.os.Bundle
+import android.util.Log
 import android.view.View
 import android.view.Window
 import android.view.WindowManager
@@ -17,7 +19,9 @@ import com.enation.javashop.utils.base.tool.BaseToolActivity
 import com.enation.javashop.utils.base.tool.CommonTool
 import com.enation.javashop.utils.base.widget.LoadingDialog
 import kotlinx.android.synthetic.main.custom_loading.view.*
+import java.lang.reflect.Constructor
 import java.lang.reflect.Field
+import java.lang.reflect.Method
 import javax.inject.Inject
 
 /**
@@ -27,6 +31,7 @@ import javax.inject.Inject
  * @Note   Activity基类
  */
 abstract class BaseActivity<PresenterType : BaseContract.BasePresenter, DataBindingType : ViewDataBinding> : BaseToolActivity(),BaseControl {
+    private val TAG = "WebviewActivity"
 
     /**
      * @Name  presenter
@@ -324,4 +329,64 @@ abstract class BaseActivity<PresenterType : BaseContract.BasePresenter, DataBind
                     }
                 }
     }
+
+
+    fun hookWebView() {
+        val sdkInt = Build.VERSION.SDK_INT
+        try {
+            val factoryClass = Class.forName("android.webkit.WebViewFactory")
+            val field: Field = factoryClass.getDeclaredField("sProviderInstance")
+            field.setAccessible(true)
+            var sProviderInstance: Any? = field.get(null)
+            if (sProviderInstance != null) {
+                Log.i(TAG, "sProviderInstance isn't null")
+                return
+            }
+            val getProviderClassMethod: Method
+            if (sdkInt > 22) {
+                getProviderClassMethod = factoryClass.getDeclaredMethod("getProviderClass")
+            } else if (sdkInt == 22) {
+                getProviderClassMethod = factoryClass.getDeclaredMethod("getFactoryClass")
+            } else {
+                Log.i(TAG, "Don't need to Hook WebView")
+                return
+            }
+            getProviderClassMethod.setAccessible(true)
+            val factoryProviderClass = getProviderClassMethod.invoke(factoryClass) as Class<*>
+            val delegateClass = Class.forName("android.webkit.WebViewDelegate")
+            val delegateConstructor: Constructor<*> = delegateClass.getDeclaredConstructor()
+            delegateConstructor.setAccessible(true)
+            if (sdkInt < 26) { //低于Android O版本
+                val providerConstructor: Constructor<*>? =
+                    factoryProviderClass.getConstructor(delegateClass)
+                if (providerConstructor != null) {
+                    providerConstructor.setAccessible(true)
+                    sProviderInstance =
+                        providerConstructor.newInstance(delegateConstructor.newInstance())
+                }
+            } else {
+                val chromiumMethodName: Field =
+                    factoryClass.getDeclaredField("CHROMIUM_WEBVIEW_FACTORY_METHOD")
+                chromiumMethodName.setAccessible(true)
+                var chromiumMethodNameStr = chromiumMethodName.get(null)
+                if (chromiumMethodNameStr == null) {
+                    chromiumMethodNameStr = "create"
+                }
+                val staticFactory: Method? =
+                    factoryProviderClass.getMethod(chromiumMethodNameStr as String, delegateClass)
+                if (staticFactory != null) {
+                    sProviderInstance =
+                        staticFactory.invoke(null, delegateConstructor.newInstance())
+                }
+            }
+            if (sProviderInstance != null) {
+                field.set("sProviderInstance", sProviderInstance)
+                Log.i(TAG, "Hook success!")
+            } else {
+                Log.i(TAG, "Hook failed!")
+            }
+        } catch (e: Throwable) {
+            Log.w(TAG, e)
+        }
+    }
 }

+ 2 - 0
middleware/src/main/code/com/wdkl/ncs/android/middleware/common/Constant.java

@@ -39,6 +39,8 @@ public class Constant {
     public static String visitId = "";
     //床位名称
     public static String BED_NAME = "";
+    public static String PART_NAME = "";
+    public static String PART_UNION_ID = "";
 
     //体征数据上传端口
     public static int TCP_VS_PORT = 5064;

+ 9 - 0
middleware/src/main/code/com/wdkl/ncs/android/middleware/model/dos/DeviceDO.java

@@ -212,6 +212,7 @@ public class DeviceDO implements Serializable {
     @ApiModelProperty(value = "语音转换盒ID", required = false)
     private Integer transAudioId;
 
+    private String part_union_id;
 
     @PrimaryKeyField
     public Integer getId() {
@@ -499,6 +500,14 @@ public class DeviceDO implements Serializable {
         this.transAudioId = transAudioId;
     }
 
+    public String getPart_union_id() {
+        return part_union_id;
+    }
+
+    public void setPart_union_id(String part_union_id) {
+        this.part_union_id = part_union_id;
+    }
+
     @Override
     public boolean equals(Object o) {
         if (this == o) return true;

+ 5 - 0
resource/src/main/res/drawable/ic_device.xml

@@ -0,0 +1,5 @@
+<vector android:height="48dp" android:tint="#2A77FA"
+    android:viewportHeight="24" android:viewportWidth="24"
+    android:width="48dp" xmlns:android="http://schemas.android.com/apk/res/android">
+    <path android:fillColor="@android:color/white" android:pathData="M20,18c1.1,0 2,-0.9 2,-2V6c0,-1.1 -0.9,-2 -2,-2H4C2.9,4 2,4.9 2,6v10c0,1.1 0.9,2 2,2H0v2h24v-2H20zM4,6h16v10H4V6z"/>
+</vector>

+ 13 - 0
resource/src/main/res/values-es/strings.xml

@@ -197,4 +197,17 @@
     <string name="advice_content">Content</string>
     <string name="advice_detail">Detail</string>
     <string name="sync_timezone">Sync Timezone</string>
+
+    <string name="plugin_update_tips">plugin service updating, please restart app later</string>
+    <string name="plugin_start_failed">start plugin service failed:</string>
+    <string name="plugin_start_success">plugin service started</string>
+    <string name="plugin_start_error">plugin service start failed, please restart app</string>
+
+    <string name="bluetooth_connect_failed">Bluetooth connect fail</string>
+    <string name="bluetooth_connect_success">Bluetooth connect success</string>
+
+    <string name="your_card_number">Su número de tarjeta:</string>
+    <string name="str_about">Acerca de</string>
+
+    <string name="str_back">Atrás</string>
 </resources>

+ 13 - 0
resource/src/main/res/values-ru/strings.xml

@@ -184,4 +184,17 @@
     <string name="advice_content">Content</string>
     <string name="advice_detail">Detail</string>
     <string name="sync_timezone">Sync Timezone</string>
+
+    <string name="plugin_update_tips">plugin service updating, please restart app later</string>
+    <string name="plugin_start_failed">start plugin service failed:</string>
+    <string name="plugin_start_success">plugin service started</string>
+    <string name="plugin_start_error">plugin service start failed, please restart app</string>
+
+    <string name="bluetooth_connect_failed">Bluetooth connect fail</string>
+    <string name="bluetooth_connect_success">Bluetooth connect success</string>
+
+    <string name="str_about">Около</string>
+    <string name="your_card_number">Номер вашей карты:</string>
+
+    <string name="str_back">Назад</string>
 </resources>

+ 12 - 0
resource/src/main/res/values-zh/strings.xml

@@ -194,8 +194,20 @@
     <string name="enter_nursing_tips">请长按按钮操作</string>
     <string name="room_null_bed">房间没有床位</string>
 
+    <string name="plugin_update_tips">app升级服务正在安装,请稍后重启设备以完成升级服务启动</string>
+    <string name="plugin_start_failed">启动升级插件服务失败:</string>
+    <string name="plugin_start_success">升级服务插件已启动</string>
+    <string name="plugin_start_error">升级服务插件启动失败</string>
+
+    <string name="bluetooth_connect_failed">蓝牙连接失败</string>
+    <string name="bluetooth_connect_success">蓝牙连接成功</string>
+
+    <string name="your_card_number">您的卡号 :</string>
+    <string name="str_about">关于</string>
+
     <string name="voice_call">语音</string>
     <string name="video_call">视频</string>
     <string name="str_reset">重置</string>
     <string name="str_debug">调试</string>
+    <string name="str_back">返回</string>
 </resources>

+ 1 - 0
resource/src/main/res/values/strings.xml

@@ -209,5 +209,6 @@
     <string name="advice_content">Content</string>
     <string name="advice_detail">Detail</string>
     <string name="sync_timezone">Sync Timezone</string>
+    <string name="str_back">Back</string>
 
 </resources>