| | |
| | | import android.app.Application; |
| | | |
| | | import androidx.annotation.NonNull; |
| | | import androidx.lifecycle.LiveData; |
| | | import androidx.lifecycle.MutableLiveData; |
| | | |
| | | import com.android.app_base.base.StateViewEnum; |
| | |
| | | public class MeetingapproveDetailActivityViewModel extends BaseViewModel<DataRepository> { |
| | | |
| | | private MutableLiveData<MeetingBean> beanLiveData; |
| | | private int numb = 1; |
| | | private MutableLiveData<Boolean> typeLiveData;//true 编辑状态 false 展示状态 |
| | | private final List<String> uploadFileList = new ArrayList<>();//需要上传的文件列表 |
| | | public MeetingapproveDetailActivityViewModel(@NonNull Application application) { |
| | |
| | | * 审批 |
| | | */ |
| | | public void agree() { |
| | | model.approveMeeting(Integer.valueOf((int) beanLiveData.getValue().getId()),1) |
| | | model.approveMeeting(Integer.valueOf(beanLiveData.getValue().setStatu("1"))) |
| | | .compose(RxUtils.schedulersTransformer()) |
| | | .subscribe(new Observer<ResultData<String>>() { |
| | | @Override |
| | |
| | | |
| | | |
| | | public void disagree() { |
| | | model.approveMeeting(Integer.valueOf((int) beanLiveData.getValue().getId()),0) |
| | | model.approveMeeting(Integer.valueOf(beanLiveData.getValue().setStatu("0"))) |
| | | .compose(RxUtils.schedulersTransformer()) |
| | | .subscribe(new Observer<ResultData<String>>() { |
| | | @Override |