新增手动添加的工作票列表页面

master
wenfei 4 months ago
parent 431774ac49
commit 2e1a751f48

@ -1136,11 +1136,15 @@
<activity <activity
android:name=".ui.activity.WorkTickerSelectListActivity" android:name=".ui.activity.WorkTickerSelectListActivity"
android:screenOrientation="portrait" android:screenOrientation="portrait"
android:windowSoftInputMode="adjustResize|stateHidden" /> <!-- 作业风险清单-右上角工作票 点击进入已审批通过的工作票汇列表选择 --> android:windowSoftInputMode="adjustResize|stateHidden" /> <!-- 作业风险清单-工作票 点击进入已审批通过的工作票汇列表选择 -->
<activity <activity
android:name=".ui.activity.WorkTickerAssistantSelectListActivity" android:name=".ui.activity.WorkTickerAssistantSelectListActivity"
android:screenOrientation="portrait" android:screenOrientation="portrait"
android:windowSoftInputMode="adjustResize|stateHidden" /> <!-- 作业风险清单-右上角工作票 点击进入已审批通过的辅助工作票汇列表选择 --> android:windowSoftInputMode="adjustResize|stateHidden" /> <!-- 作业风险清单-辅助工作 点击进入已审批通过的辅助工作票汇列表选择 -->
<activity
android:name=".ui.activity.WorkTickerCustomListActivity"
android:screenOrientation="portrait"
android:windowSoftInputMode="adjustResize|stateHidden" /> <!-- 作业风险清单-手动添加 点击进入已审批通过的手动添加列表选择 -->
<activity <activity
android:name=".ui.activity.WorkRiskListHuiBaoActivity" android:name=".ui.activity.WorkRiskListHuiBaoActivity"
android:screenOrientation="portrait" android:screenOrientation="portrait"

@ -0,0 +1,126 @@
package com.rehome.zhdcoa.adapter;
import android.content.Context;
import android.graphics.Color;
import android.text.TextUtils;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import androidx.annotation.NonNull;
import androidx.core.content.ContextCompat;
import com.rehome.zhdcoa.App;
import com.rehome.zhdcoa.R;
import com.rehome.zhdcoa.base.BaseViewBindingAdapter;
import com.rehome.zhdcoa.bean.WorkRiskLevelListBean;
import com.rehome.zhdcoa.databinding.AdapterWorkTicketCustomListBinding;
import com.rehome.zhdcoa.databinding.AdapterWorkTicketSelectListBinding;
import java.util.List;
public class WorkTickerCustomListAdapter extends BaseViewBindingAdapter<AdapterWorkTicketCustomListBinding> {
private final Context context;
private final List<WorkRiskLevelListBean.RowsBean> data;
private CallBack mCallBack;
public interface CallBack {
void Click(@NonNull View view,int position);
}
private OnWorkTicketModifyClickListener onWorkTicketModifyClickListener;
private OnWorkTicketDeleteClickListener onWorkTicketDeleteClickListener;
public WorkTickerCustomListAdapter(Context context, List<WorkRiskLevelListBean.RowsBean> datas, CallBack mCallBack,OnWorkTicketModifyClickListener onWorkTicketModifyClickListener,OnWorkTicketDeleteClickListener onWorkTicketDeleteClickListener) {
super(context);
this.context=context;
this.data=datas;
this.mCallBack = mCallBack;
this.onWorkTicketModifyClickListener=onWorkTicketModifyClickListener;
this.onWorkTicketDeleteClickListener=onWorkTicketDeleteClickListener;
}
@Override
protected void handleData(int position, @NonNull AdapterWorkTicketCustomListBinding binding) {
WorkRiskLevelListBean.RowsBean item = data.get(position);
binding.tvPaiHao.setText(item.getCode());
binding.tvContent.setText(item.getContent());
binding.tvLevel.setText(item.getLevel());
if(!TextUtils.isEmpty(item.getMajor())){
binding.tvZy.setText(item.getMajor());
}
binding.cb.setChecked(item.isChecked());
binding.cb.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View view) {
mCallBack.Click(view,position);
}
});
binding.tvModify.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View view) {
onWorkTicketModifyClickListener.onItemClick(position);
}
});
binding.tvDelete.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View view) {
onWorkTicketDeleteClickListener.onItemClick(position);
}
});
int color = ContextCompat.getColor(context, R.color.colorPrimary);
int colorRed = ContextCompat.getColor(context, R.color.red);
if(TextUtils.isEmpty(item.getJobNo())){
binding.cb.setEnabled(true);
binding.tvModify.setEnabled(true);
binding.tvDelete.setEnabled(true);
binding.llModify.setBackgroundColor(color);
binding.llDelete.setBackgroundColor(colorRed);
}else{
if(item.getJobNo().equals(App.getInstance().getUserInfo().getManid())){
binding.cb.setEnabled(true);
binding.tvModify.setEnabled(true);
binding.tvDelete.setEnabled(true);
binding.llModify.setBackgroundColor(color);
binding.llDelete.setBackgroundColor(colorRed);
}else{
//不是本人选中的,不允许修改
binding.cb.setEnabled(false);
binding.tvPaiHao.setTextColor(Color.GRAY);
binding.tvContent.setTextColor(Color.GRAY);
binding.tvLevel.setTextColor(Color.GRAY);
binding.tvModify.setEnabled(false);
binding.tvDelete.setEnabled(false);
binding.llModify.setBackgroundColor(Color.GRAY);
binding.llDelete.setBackgroundColor(Color.GRAY);
}
}
}
@Override
protected AdapterWorkTicketCustomListBinding getBinding(@NonNull LayoutInflater inflater, ViewGroup parent) {
return AdapterWorkTicketCustomListBinding.inflate(inflater, parent, false);
}
@Override
public int getCount() {
return data.size();
}
@Override
public Object getItem(int position) {
return data.get(position);
}
@Override
public long getItemId(int position) {
return Long.valueOf(position);
}
public interface OnWorkTicketModifyClickListener {
void onItemClick(int position);
}
public interface OnWorkTicketDeleteClickListener {
void onItemClick(int position);
}
}

@ -64,7 +64,8 @@ public class AbActivity extends BaseActivity {
public void getdata() { public void getdata() {
final Request<String> requestxs = NoHttp.createStringRequest("http://219.131.195.3:8082/" + Contans.AB, RequestMethod.POST); String url = Contans.BASE_URL + Contans.AB;
final Request<String> requestxs = NoHttp.createStringRequest(url, RequestMethod.POST);
requestxs.setDefineRequestBodyForJson(createJson("", "")); requestxs.setDefineRequestBodyForJson(createJson("", ""));
@ -73,6 +74,11 @@ public class AbActivity extends BaseActivity {
@Override @Override
public void onSucceed(int what, com.yolanda.nohttp.rest.Response<String> response) { public void onSucceed(int what, com.yolanda.nohttp.rest.Response<String> response) {
showLog( "--------getdata--------");
showLog(url);
String result = response.get();
showLog( result);
AbbjBean list = GsonUtils.GsonToBean(response.get(), AbbjBean.class); AbbjBean list = GsonUtils.GsonToBean(response.get(), AbbjBean.class);
if (list != null) { if (list != null) {

@ -45,6 +45,9 @@ class WorkRiskListActivity : BaseActivityOaToolbarViewBinding<ActivityWorkRiskLi
private var selectListAssistant: MutableList<Int> = mutableListOf() private var selectListAssistant: MutableList<Int> = mutableListOf()
private var jobNoListAssistant: MutableList<String> = mutableListOf() private var jobNoListAssistant: MutableList<String> = mutableListOf()
private var selectListCustom: MutableList<Int> = mutableListOf()
private var jobNoListCustom: MutableList<String> = mutableListOf()
private var dataA: MutableList<WorkRiskLevelListBean.RowsBean> = mutableListOf() private var dataA: MutableList<WorkRiskLevelListBean.RowsBean> = mutableListOf()
private var dataB: MutableList<WorkRiskLevelListBean.RowsBean> = mutableListOf() private var dataB: MutableList<WorkRiskLevelListBean.RowsBean> = mutableListOf()
private var dataC1: MutableList<WorkRiskLevelListBean.RowsBean> = mutableListOf() private var dataC1: MutableList<WorkRiskLevelListBean.RowsBean> = mutableListOf()
@ -140,10 +143,12 @@ class WorkRiskListActivity : BaseActivityOaToolbarViewBinding<ActivityWorkRiskLi
binding.llCustomAdd.setOnClickListener { binding.llCustomAdd.setOnClickListener {
if(isNetworkNormal){ if(isNetworkNormal){
//进入风险提示页面 WorkTickerAssistantSelectListActivity //进入风险提示页面 WorkTickerAssistantSelectListActivity
val intent = Intent(context, WorkTickerAssistantSelectListActivity::class.java) val intent = Intent(context, WorkTickerCustomListActivity::class.java)
intent.addFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP or Intent.FLAG_ACTIVITY_SINGLE_TOP) intent.addFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP or Intent.FLAG_ACTIVITY_SINGLE_TOP)
intent.putExtra("selectList", GsonUtils.GsonString(selectListAssistant)) // intent.putExtra("selectList", GsonUtils.GsonString(selectListCustom))
intent.putExtra("jobNoList", GsonUtils.GsonString(jobNoListAssistant)) // intent.putExtra("jobNoList", GsonUtils.GsonString(jobNoListCustom))
intent.putExtra("selectList", GsonUtils.GsonString(selectList))
intent.putExtra("jobNoList", GsonUtils.GsonString(jobNoList))
startActivity(intent) startActivity(intent)
}else{ }else{
showToast("列表数据加载失败,请检查网络环境或重新加载列表数据") showToast("列表数据加载失败,请检查网络环境或重新加载列表数据")
@ -270,6 +275,11 @@ class WorkRiskListActivity : BaseActivityOaToolbarViewBinding<ActivityWorkRiskLi
selectListAssistant.add(item.id) selectListAssistant.add(item.id)
jobNoListAssistant.add(item.jobNo) jobNoListAssistant.add(item.jobNo)
} }
if("custom" == item.type){
selectListCustom.add(item.id)
jobNoListCustom.add(item.jobNo)
}
showLog(GsonUtils.GsonString(item)) showLog(GsonUtils.GsonString(item))
if(item.level!=null&&item.level=="A"){ if(item.level!=null&&item.level=="A"){

@ -169,7 +169,7 @@ class WorkTickerAssistantSelectListActivity : BaseActivityOaToolbarViewBinding<A
dialog.setTvMsg("您确定要设置辅助工作票作业?") dialog.setTvMsg("您确定要设置辅助工作票作业?")
dialog.show() dialog.show()
}else{ }else{
showToast("致少选择一个工作票才能提交") showToast("致少选择一个辅助工作票才能提交")
} }
} }
} }

@ -0,0 +1,390 @@
package com.rehome.zhdcoa.ui.activity
import android.view.View
import android.widget.CheckBox
import com.google.gson.Gson
import com.google.gson.reflect.TypeToken
import com.rehome.zhdcoa.App
import com.rehome.zhdcoa.Contans
import com.rehome.zhdcoa.adapter.WorkTickerCustomListAdapter
import com.rehome.zhdcoa.adapter.WorkTickerSelectListAdapter
import com.rehome.zhdcoa.base.BaseActivityOaToolbarViewBinding
import com.rehome.zhdcoa.bean.AIBaseBean
import com.rehome.zhdcoa.bean.WorkRiskLevelListBean
import com.rehome.zhdcoa.databinding.ActivityWorkTickerCustomListBinding
import com.rehome.zhdcoa.utils.AuthenticationLoginAIUtils
import com.rehome.zhdcoa.utils.GsonUtils
import com.rehome.zhdcoa.utils.HttpListener
import com.rehome.zhdcoa.utils.NohttpUtils
import com.rehome.zhdcoa.utils.RSAAndroid
import com.rehome.zhdcoa.weiget.CommitDialog
import com.rehome.zhdcoa.weiget.CommitDialog.CommitDialogListener
import com.rehome.zhdcoa.weiget.ConfirmDialog
import com.rehome.zhdcoa.weiget.DatePickDialogNew
import com.yolanda.nohttp.NoHttp
import com.yolanda.nohttp.RequestMethod
import com.yolanda.nohttp.rest.Response
import java.text.SimpleDateFormat
import java.util.Calendar
import javax.net.ssl.HostnameVerifier
/**
* Create By HuangWenFei
* 创建日期2025-02-6 15:31
* 描述已审批的工作票 WorkTickerCustomListActivity
*/
class WorkTickerCustomListActivity : BaseActivityOaToolbarViewBinding<ActivityWorkTickerCustomListBinding>() {
//private lateinit var headView: View
//private lateinit var cb: CheckBox
private var datas: MutableList<WorkRiskLevelListBean.RowsBean> = mutableListOf()
private lateinit var mAdapter: WorkTickerCustomListAdapter
//工作票主键数组,来源查询每日作业风险清单
private var ticketIdList : MutableList<Int> = mutableListOf()
//要取消的工作票主键
private var deleteIdList : MutableList<Int> = mutableListOf()
private var selectList: MutableList<Int> = mutableListOf()
private var jobNoList: MutableList<String> = mutableListOf()
private lateinit var calendar: Calendar
//格式化日期的对象(转化成习惯的时间格式)
private val sdFormat = SimpleDateFormat("yyyy-MM-dd")
override fun getViewBinding() = ActivityWorkTickerCustomListBinding.inflate(layoutInflater)
override fun getToolbar() = binding.toolbarView.toolbar
override fun initView() {
initToolbar("手动添加工作票", "新增") {
//提交
}
resetToday()
val selectListStr = intent.getStringExtra("selectList")!!
showLog(selectListStr)
val gson = Gson()
val selectListTemp:MutableList<Int> = gson.fromJson<MutableList<Int>>(selectListStr,object:TypeToken<MutableList<Int>>() {}.type)
showLog(GsonUtils.GsonString(selectListTemp))
if(selectListTemp.isNotEmpty()){
selectList.addAll(selectListTemp)
}
val jobNoListStr = intent.getStringExtra("jobNoList")!!
showLog(jobNoListStr)
val jobNoListTemp:MutableList<String> = gson.fromJson<MutableList<String>>(jobNoListStr,object:TypeToken<MutableList<String>>() {}.type)
showLog(GsonUtils.GsonString(jobNoListTemp))
if(jobNoListTemp.isNotEmpty()){
jobNoList.addAll(jobNoListTemp)
}
binding.tvSt.setOnClickListener(View.OnClickListener { view: View? ->
val dialog = DatePickDialogNew(
context, calendar
) { outPutDate: String,calendarBack:Calendar ->
binding.tvSt.text = outPutDate
calendar = calendarBack;
//checkServerConnectStatus()
}
dialog.show()
})
binding.lv.emptyView = binding.tvNodata
//headView = View.inflate(this, R.layout.header_work_ticket_select_list, null)
//cb = headView.findViewById<View>(R.id.cb) as CheckBox
binding.itemHead.cb.setOnClickListener {
if (binding.itemHead.cb.isChecked) {
for (i in datas.indices) {
datas[i].isChecked = true
mAdapter.notifyDataSetChanged()
}
deleteIdList.clear()
} else {
for (i in datas.indices) {
datas[i].isChecked = false
mAdapter.notifyDataSetChanged()
}
if(selectList.size>0){
deleteIdList.addAll(selectList)
}
}
}
mAdapter = WorkTickerCustomListAdapter(this,datas,{ view, position ->
val checkBox = view as CheckBox
datas[position].isChecked = checkBox.isChecked
var count = 0
for (a in datas.indices) {
if (datas[a].isChecked) {
count++
}
}
if(!checkBox.isChecked){
if(selectList.size>0){
for (i in selectList.indices) {
if(selectList[i] == datas[position].id){
if(!deleteIdList.contains(selectList[i])){
deleteIdList.add(selectList[i])
}
}
}
}
}
binding.itemHead.cb.isChecked = count == datas.size
mAdapter.notifyDataSetChanged()
},{ position ->
val item:WorkRiskLevelListBean.RowsBean = datas[position]
showToast("修改")
},{ position ->
val item:WorkRiskLevelListBean.RowsBean = datas[position]
showToast("删除")
val dialog = CommitDialog(context, object : CommitDialogListener {
override fun confirm() {
//authenticationLoginAISubmit()
}
override fun cancel() {
}
})
dialog.setTvMsg("您确定要删除手动添加的工作票吗?")
dialog.show()
})
binding.lv.adapter = mAdapter
binding.tvSubmit.setOnClickListener {
var canSubmit = false
ticketIdList.clear()
for (i in datas.indices) {
if (datas[i].isChecked) {
canSubmit = true
ticketIdList.add(datas[i].id)
}
}
if (canSubmit||deleteIdList.size>0) {
val dialog = CommitDialog(context, object : CommitDialogListener {
override fun confirm() {
showLog(GsonUtils.GsonString(ticketIdList))
showLog(ticketIdList.size.toString())
//authenticationLoginAISubmit()
}
override fun cancel() {
}
})
dialog.setTvMsg("您确定要设置工作票作业?")
dialog.show()
}else{
showToast("致少选择一个工作票才能提交")
}
}
}
override fun initData() {
authenticationLoginAI()
}
private fun authenticationLoginAI() {
try {
//AI三维登录接口
val userName = Contans.SP.AI_ACCOUNT
//String strPrivateEncode=RSAAndroid.encryptByPrivateKeyForSpiltStr(Contans.SP.AI_PWD,RSAAndroid.privateRsaKeyLocal);
val strPublicDecode = RSAAndroid.decryptByPublicKeyForSpiltStr(
Contans.SP.AI_PWD_ENCODE,
RSAAndroid.publicRsaKeyLocal
)
AuthenticationLoginAIUtils.authenticationAILoginShowProgress(
this, userName, strPublicDecode
) { _, token ->
if (token != null && token == "") {
showToast("AI三维平台登录失败")
} else {
getWorkRiskListData()
}
}
} catch (e: Exception) {
e.printStackTrace()
}
}
private fun getWorkRiskListData() {
val request = NoHttp.createStringRequest(
Contans.BASE_URL_AI_3D_SERVER + Contans.DAYLY_RISK_LIST_NEW,
RequestMethod.GET
)
request.add("filter",false);
if (Contans.BASE_URL_AI_3D_SERVER == Contans.BASE_URL_AI_3D_SERVER_EXTRANET) {
val socketFactory = NohttpUtils.getSSLSocketFactory(context)
if (socketFactory != null) {
request.sslSocketFactory = socketFactory
request.hostnameVerifier = HostnameVerifier { _, _ -> true }
}
}
NohttpUtils.getInstance().add(this, 0, request, object : HttpListener<String?> {
override fun onSucceed(what: Int, response: Response<String?>?) {
val result = response?.get()
showLog("----------------")
showLog(result)
val bean = GsonUtils.GsonToBean(
result,
WorkRiskLevelListBean::class.java
)
if (bean != null && bean.data != null) {
val workRiskLevelLists = bean.data
if (workRiskLevelLists != null && workRiskLevelLists.isNotEmpty()) {
binding.tvNodata.visibility = View.GONE
datas.clear()
if(selectList.isNotEmpty()){
for (i in workRiskLevelLists.indices) {
for (j in selectList.indices) {
if (workRiskLevelLists[i].id==selectList[j]) {
workRiskLevelLists[i].isChecked = true
workRiskLevelLists[i].jobNo = jobNoList[j]
}
}
}
}
datas.addAll(workRiskLevelLists)
mAdapter.notifyDataSetChanged()
for(item in datas){
showLog(GsonUtils.GsonString(item))
// if(item.level!=null&&item.level=="A"){
// dataA.add(item)
// }
}
} else {
binding.tvNodata.visibility = View.VISIBLE
}
}
}
override fun onFailed(what: Int, response: Response<String?>?) {
}
})
}
private fun resetToday(){
calendar = Calendar.getInstance()
val startDateStr = sdFormat.format(calendar.time)
showLog("今天:")
showLog(startDateStr)
binding.tvSt.text = startDateStr
}
private fun authenticationLoginAISubmit() {
try {
//AI三维登录接口
val userName = Contans.SP.AI_ACCOUNT
//String strPrivateEncode=RSAAndroid.encryptByPrivateKeyForSpiltStr(Contans.SP.AI_PWD,RSAAndroid.privateRsaKeyLocal);
val strPublicDecode = RSAAndroid.decryptByPublicKeyForSpiltStr(
Contans.SP.AI_PWD_ENCODE,
RSAAndroid.publicRsaKeyLocal
)
AuthenticationLoginAIUtils.authenticationAILoginShowProgress(
this, userName, strPublicDecode
) { _, token ->
if (token != null && token == "") {
showToast("AI三维平台登录失败")
} else {
submitWorkTicketData()
}
}
} catch (e: Exception) {
e.printStackTrace()
}
}
private fun getSubmitJsonData(): String {
val param = HashMap<String, Any>()
param["assignmentDate"] = binding.tvSt.text.toString().trim()
param["ticketIdList"] = ticketIdList
param["deleteIdList"]= deleteIdList
param["jobNo"]= App.getInstance().userInfo.manid
param["type"]= "custom"
val json = GsonUtils.GsonString(param)
showLog(json)
return json
}
private fun submitWorkTicketData() {
val request = NoHttp.createStringRequest(
Contans.BASE_URL_AI_3D_SERVER + Contans.DAYLY_RISK_LIST_SUBMIT_WORK_TICKET_LIST,
RequestMethod.POST
)
val json: String = getSubmitJsonData()
request.setDefineRequestBodyForJson(json)
if (Contans.BASE_URL_AI_3D_SERVER == Contans.BASE_URL_AI_3D_SERVER_EXTRANET) {
val socketFactory = NohttpUtils.getSSLSocketFactory(context)
if (socketFactory != null) {
request.sslSocketFactory = socketFactory
request.hostnameVerifier = HostnameVerifier { _, _ -> true }
}
}
NohttpUtils.getInstance().add(this, 0, request, object : HttpListener<String?> {
override fun onSucceed(what: Int, response: Response<String?>?) {
val result = response?.get()
showLog("----------------")
showLog(result)
val bean = GsonUtils.GsonToBean(
result,
AIBaseBean::class.java
)
if (bean != null && bean.isSuccess) {
//提交成功
val confirmDialog = ConfirmDialog(
context, "设置工作票作业日期成功"
) { finish() }
confirmDialog.setTvTitle("提示")
confirmDialog.setCancelable(true)
confirmDialog.show()
}else{
showToast("设置工作票作业日期失败")
}
}
override fun onFailed(what: Int, response: Response<String?>?) {
}
})
}
}
//class WorkTickerCustomListActivity : AppCompatActivity() {
// override fun onCreate(savedInstanceState: Bundle?) {
// super.onCreate(savedInstanceState)
// enableEdgeToEdge()
// setContentView(R.layout.activity_work_ticker_custom_list)
// ViewCompat.setOnApplyWindowInsetsListener(findViewById(R.id.main)) { v, insets ->
// val systemBars = insets.getInsets(WindowInsetsCompat.Type.systemBars())
// v.setPadding(systemBars.left, systemBars.top, systemBars.right, systemBars.bottom)
// insets
// }
// }
//}

@ -1,10 +1,8 @@
package com.rehome.zhdcoa.ui.activity package com.rehome.zhdcoa.ui.activity
import android.content.DialogInterface
import android.graphics.Color
import android.view.View import android.view.View
import android.widget.CheckBox import android.widget.CheckBox
import com.google.gson.Gson import com.google.gson.Gson
import com.google.gson.reflect.TypeToken import com.google.gson.reflect.TypeToken
import com.rehome.zhdcoa.App import com.rehome.zhdcoa.App
@ -34,7 +32,7 @@ import javax.net.ssl.HostnameVerifier
/** /**
* Create By HuangWenFei * Create By HuangWenFei
* 创建日期2025-02-6 15:31 * 创建日期2025-02-6 15:31
* 描述已审批的工作票 * 描述已审批的工作票 WorkTickerCustomListActivity
*/ */
class WorkTickerSelectListActivity : BaseActivityOaToolbarViewBinding<ActivityWorkTickerSelectListBinding>() { class WorkTickerSelectListActivity : BaseActivityOaToolbarViewBinding<ActivityWorkTickerSelectListBinding>() {
@ -159,7 +157,8 @@ class WorkTickerSelectListActivity : BaseActivityOaToolbarViewBinding<ActivityWo
val dialog = CommitDialog(context, object : CommitDialogListener { val dialog = CommitDialog(context, object : CommitDialogListener {
override fun confirm() { override fun confirm() {
showLog(GsonUtils.GsonString(ticketIdList)) showLog(GsonUtils.GsonString(ticketIdList))
authenticationLoginAISubmit() showLog(ticketIdList.size.toString())
//authenticationLoginAISubmit()
} }
override fun cancel() { override fun cancel() {

@ -0,0 +1,88 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical"
tools:context=".ui.activity.WorkTickerCustomListActivity">
<include
android:id="@+id/toolbarView"
layout="@layout/layout_base" />
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="#dddddd"
android:padding="5dp"
android:minHeight="30px">
<TextView
android:id="@+id/tv_zxsj"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_margin="5px"
android:gravity="center"
android:minHeight="50px"
android:text="作业风险清单日期:"
android:textSize="24px" />
<TextView
android:id="@+id/tv_st"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_margin="5px"
android:layout_weight="1"
android:gravity="center_vertical"
android:minHeight="50px"
android:textColor="@color/colorPrimaryDark"
android:text=""
android:textSize="24px" />
</LinearLayout>
<include
android:id="@+id/item_head"
layout="@layout/header_work_ticket_custom_list"
android:layout_width="match_parent"
android:layout_marginStart="10px"
android:layout_marginEnd="10px"
android:layout_marginTop="5dp"
android:layout_height="wrap_content" />
<FrameLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_marginStart="10px"
android:layout_marginEnd="10px"
android:layout_marginBottom="10px"
android:layout_weight="1">
<ListView
android:id="@+id/lv"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:divider="#00000000"
android:dividerHeight="0px"/>
<TextView
android:id="@+id/tv_nodata"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:textColor="@color/viewfinder_mask"
android:gravity="center"
android:text="暂无数据"/>
</FrameLayout>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="50dp"
android:background="@color/colorPrimary"
android:orientation="vertical">
<TextView
android:id="@+id/tv_submit"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:textColor="@color/white"
android:gravity="center"
android:textSize="18sp"
android:text="提交"/>
</LinearLayout>
</LinearLayout>

@ -0,0 +1,176 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="center"
android:minHeight="62px"
android:orientation="vertical">
<View
android:id="@+id/head"
android:layout_width="match_parent"
android:layout_height="1dp"
android:visibility="invisible"
android:background="#524658"
/>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:minHeight="60px">
<View
android:layout_width="1dp"
android:layout_height="match_parent"
android:background="#524658" />
<LinearLayout
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:layout_weight="0.5"
android:gravity="center">
<CheckBox
android:id="@+id/cb"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:focusable="false" />
</LinearLayout>
<View
android:layout_width="1dp"
android:layout_height="match_parent"
android:background="#524658" />
<LinearLayout
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="3.1"
android:orientation="vertical">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:padding="3dp"
android:orientation="horizontal">
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="工作票号:" />
<TextView
android:id="@+id/tv_paiHao"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="PTW-202508-0134" />
</LinearLayout>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:padding="3dp"
android:orientation="horizontal">
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="工作内容:" />
<TextView
android:id="@+id/tv_content"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="工作内容" />
</LinearLayout>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:padding="3dp"
android:orientation="horizontal">
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="风险等级:" />
<TextView
android:id="@+id/tv_level"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="风险等级" />
</LinearLayout>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:padding="3dp"
android:orientation="horizontal">
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="专业" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="专业:" />
<TextView
android:id="@+id/tv_zy"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="机械" />
</LinearLayout>
</LinearLayout>
<View
android:layout_width="1dp"
android:layout_height="match_parent"
android:background="#524658" />
<LinearLayout
android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_weight="1.2"
android:padding="5dp"
android:gravity="center"
android:orientation="vertical">
<LinearLayout
android:id="@+id/ll_modify"
android:layout_width="60dp"
android:layout_height="40dp"
android:background="@color/colorPrimary"
android:gravity="center"
android:orientation="vertical">
<TextView
android:id="@+id/tv_modify"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:textColor="@color/white"
android:gravity="center"
android:textSize="16sp"
android:text="修改"/>
</LinearLayout>
<LinearLayout
android:id="@+id/ll_delete"
android:layout_width="60dp"
android:layout_height="40dp"
android:background="@color/red"
android:gravity="center"
android:layout_marginTop="10dp"
android:orientation="vertical">
<TextView
android:id="@+id/tv_delete"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:textColor="@color/white"
android:gravity="center"
android:textSize="16sp"
android:text="删除"/>
</LinearLayout>
</LinearLayout>
<View
android:layout_width="1dp"
android:layout_height="match_parent"
android:background="#524658" />
</LinearLayout>
<View
android:layout_width="match_parent"
android:layout_height="1dp"
android:background="#524658" />
</LinearLayout>

@ -0,0 +1,90 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="center"
android:minHeight="62px"
android:orientation="vertical">
<View
android:id="@+id/head"
android:layout_width="match_parent"
android:layout_height="1dp"
android:background="#524658"
/>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:minHeight="60px">
<View
android:layout_width="1dp"
android:layout_height="match_parent"
android:background="#524658" />
<LinearLayout
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:layout_weight="0.5"
android:gravity="center">
<CheckBox
android:id="@+id/cb"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:focusable="false" />
</LinearLayout>
<View
android:layout_width="1dp"
android:layout_height="match_parent"
android:background="#524658" />
<LinearLayout
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="3.1"
android:layout_gravity="center"
android:orientation="vertical">
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:text="手动添加" />
</LinearLayout>
<View
android:layout_width="1dp"
android:layout_height="match_parent"
android:background="#524658" />
<LinearLayout
android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_weight="1.2"
android:padding="5dp"
android:gravity="center"
android:orientation="vertical">
<TextView
android:id="@+id/tv_content"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="操作" />
</LinearLayout>
<View
android:layout_width="1dp"
android:layout_height="match_parent"
android:background="#524658" />
</LinearLayout>
<View
android:layout_width="match_parent"
android:layout_height="1dp"
android:background="#524658" />
</LinearLayout>
Loading…
Cancel
Save