Popup screen to input/select/confirm

ABAP 弹出式屏幕与 ALV 实现
本文介绍如何使用 ABAP 实现多种弹出式屏幕功能,包括多选、确认步骤等,并详细讲解了如何创建带有 ALV 的自定义屏幕,通过实例演示了整个过程。

The first attachment lists some examples about following FMs:

  REUSE_ALV_POPUP_TO_SELECT (multi-selectable)

  POPUP_WITH_TABLE_DISPLAY 

  POPUP_TO_GET_ONE_VALUE (w/o db check)

  POPUP_TO_GET_VALUE (with db check)

  POPUP_GET_VALUES (with db check)

  POPUP_GET_VALUES_USER_CHECKED

  POPUP_GET_VALUES_DB_CHECKED

  POPUP_TO_CONFIRM_STEP

 

Popup selection screen as a window

CALL SELECTION-SCREEN scr STARTING AT x1 y1

 

Popup custom screen with ALV

1. Create a screen

2. Place a custom control on the screen

3. in the PBO of the screen

    a) Create a container instance which connect to the custom control placed on the screen

    b) Create a ALV GRID

    c) Set field catelog

    d) Set layout

    e) other settings

    f) display/refresh

Details please refer to the second attachment.

<template> <view class="warning_content"> <!-- 搜索条件查询 --> <view class="header"> <!-- 导航栏占位 --> <view class="plate"> <uni-easyinput class="uni-mt-5" suffixIcon="search" @input="onInput" v-model="plate" placeholder="请输入车牌号" @iconClick="serchPlate"></uni-easyinput> </view> <view class="selectBox"> <view class="statusSelect"> <uni-data-select v-model="value2" :localdata="range" @change="changeStatus" placeholder="全部"></uni-data-select> </view> <view class="zhanwei"></view> <view class="typeSelect"> <view class="type_font"> <uni-data-select v-model="value3" :localdata="alarmTypeList" @change="changeBjStatus" placeholder="报警类型"> </uni-data-select> </view> </view> </view> <view class="example" @click="showDataPick"> <uni-datetime-picker v-model="datetimerange" type="daterange" @change="dateChange" @close="maskClick" @maskClick="maskClick" /> </view> </view> <!-- 处理弹框 --> <view style="width: 100%;"> <uni-popup ref="popupDispose" backgroundColor="rgba(0,0,0,0)" @maskClick="maskClick"> <view class="popup-content2"> <view class="reason"> <text>处理结果:</text> <text>属实</text> </view> <view class="measure"> <text>备注</text> <textarea class="textarea" name="measure" v-model="remark" placeholder-style="color:#999;font-size:28upx" placeholder="请输入整改措施..." /> </view> </view> </uni-popup> </view> <view class="warning_list"> <!-- 数据列表 --> <view class="warning_list_item" v-for="(warning,index) in alarmDateList" :key="index" @click="redirectDetail(warning.id,warning.powerprocessed,warning.cysprocessed,index)"> <view class="warning_list_bottom"> <view class="address"> <text>车牌号:{{warning.plateno}}</text> </view> <view class="address"> <text>订单编号:{{warning.ddbh}}</text> </view> <view class="address"> <text>报警类型:</text><text style="color: red;display: inline-block;">{{warning.alarmtype}}</text> </view> <view class="dateTime"> <text>发生时间:{{formatDate(warning.firsttime)}}</text> </view> <view class="address" style="word-wrap: break-word;word-break: break-all;white-space: normal;"> <text>报警位置:{{warning.firstlocation}}</text> </view> <view class="address" style="word-wrap: break-word;word-break: break-all;white-space: normal;"> <text>承运商处理结果:{{warning._cysprocessed}}</text> </view> </view> <view class="warning_list_top"> <view class="function_button"> <view class="chuli" v-if="warning.powerprocessed == '3OL4M8GY'"> <!-- <view class="onpending" @click.stop="openHuLveTypePopup(warning.id,index)">忽略</view> --> <view class="pending" @click.stop="openDisposeTypePopup(warning,'cl')">处理</view> <view class="pending" @click.stop="openDisposeTypePopup(warning,'jcbj')">解除报警</view> <!-- <view v-if="warning._cysprocessed =='已处理' && warning._powerprocessed =='未处理'" class="huifang" @click.stop="openDisposeTypePopup(warning,'cs')">继续查实</view> --> <view class="huifang" @click.stop="btnGj(warning)">回放</view> </view> <view class="shenpi" v-if="warning.powerprocessed == '3OL4M8GZ'"> <view class="pending">已审批</view> <view class="huifang" @click.stop="btnGj(warning)">回放</view> <view class="huifang" @click.stop="btnXq(warning)"> 修改 </view> </view> </view> </view> </view> <view style="margin-top: 30upx;" v-if="showMore"> <uni-load-more :status="status" :content-text="contentText" :clickLoadMore="click" /> </view> </view> <!-- 上拉加载 --> <!-- 没有数据和请求失败的情况下显示 --> <view class="empty" v-if="showEmpty"> <image src="../../static/images/nodata1.png" mode=""></image> </view> <view class="noInternet"> <image src="../../static/images/noInternat.png" mode=""></image> <text>网络竟然崩溃了</text> <text>试着刷新页面</text> </view> <uni-popup ref="popup" type="dialog" @maskClick="maskClick"> <uni-popup-dialog title="请先选择回放" :before-close="true" @confirm="onDdPickConfirm" @close="onDdPickClose"> <radio-group @change="radioChange" style="display: flex;"> <label v-for="(item, index) in options" :key="item.value" style="display: flex;font-size: 16px;margin-left: 20px;"> <view> <radio :value="item.value" :checked="index === current" /> </view> <view>{{item.text}}</view> </label> </radio-group> </uni-popup-dialog> </uni-popup> </view> </template> <script> import request from '@/http/request.js' export default { data() { return { currentClickListIndex: 0, // 列表索引 currentCLickIndex: 0, //点击处理和忽略索引 value: "", // input默认值 value2: "", // 全部下拉框 value3: "", // 报警下拉框 plate: "", // 输入的车牌号 flag:"", photoData:[], num:9, options:[ {value:"轨迹回放",text:'轨迹回放'}, {value:"视频回放",text:'视频回放'}, ], range: [ { value: '3OL4M8GY', text: "未处理" }, { value: '3OL4M8GZ', text: "已处理" }, ], status: 'loading', contentText: { contentdown: '上拉查看更多', contentnomore: '没有更多了', contentrefresh: '加载中', }, datetimerange: [], alarmDateList: [], //报警类型集合 alarmTypeList: [], formData: {}, formDisposeData: {}, remark: '', disposeId: '', showEmpty: false, refreshType: 'search', showMore: false, showTabBar: true, formYjData: {}, popup:false, hflx:'', hflist:{}, } }, onLoad(options) { var user = uni.getStorageSync('user') this.formYjData.type = 'HWYJ' this.loadYjType() this.formData.powerid = user[0].id this.formData.rows = 10 this.formData.page = 1 this.loadData() this.loadCount(user[0].id) }, onShow() { this.loadCount(this.formData.powerid) }, mounted() { //监听从子页面收到的回调 uni.$on('refreshPreviousPage', (data) => { var type = data.data console.log('----' + type + " " + this.currentClickListIndex) if ('hulve' == type) { this.alarmDateList[this.currentClickListIndex].powerprocessed = '3OL4M8GZ' } else if ('dispose' == type) { this.alarmDateList[this.currentClickListIndex].powerprocessed = '3OL4M8GZ' } }); }, methods: { onDdPickClose(){ this.$refs.popup.close() }, radioChange(val){ this.hflx = val.detail.value }, onDdPickConfirm(){ this.$refs.popup.close() if(this.hflx =='轨迹回放'){ uni.navigateTo({ url: '/pagesFen/monitoring/gjhf?vehicleId=' + this.hflist.vehicleid + '&cph=' + this.hflist.plateno+ '&firsttime=' + this.hflist.firsttime+ '&lasttime=' + this.hflist.lasttime }); }else{ uni.navigateTo({ url: '/pagesFen/monitoring/historyvideo?title=历史视频-' + this.hflist.plateno+ '&firsttime=' + this.hflist.firsttime+ '&lasttime=' + this.hflist.lasttime }); } }, btnXq(arr){ uni.navigateTo({ url: "/pagesFen/prewarning/deatail-xq?ddid=" + arr.id }) }, maskClick() { this.$refs.popupDialog.close() this.changeTab('show') }, btnGj(arr){ this.$refs.popup.open() this.hflist = arr }, onInput(e) { this.refreshType = 'search' if ('' != e) { setTimeout(()=>{ if(e == this.plate){ this.formData.plateno = e this.loadData() } },1000) } else { this.formData.page = 1 delete this.formData.plateno this.loadData() } }, formatDate(value) { if (value == undefined) { return; } // let date = new Date(value * 1000); let date = new Date(value); //时间戳为10位需*1000,时间戳为13位的话不需乘1000 let y = date.getFullYear(); let MM = date.getMonth() + 1; MM = MM < 10 ? ('0' + MM) : MM; //月补0 let d = date.getDate(); d = d < 10 ? ('0' + d) : d; //天补0 let h = date.getHours(); h = h < 10 ? ('0' + h) : h; //小时补0 let m = date.getMinutes(); m = m < 10 ? ('0' + m) : m; //分钟补0 let s = date.getSeconds(); s = s < 10 ? ('0' + s) : s; //秒补0 return y + '-' + MM + '-' + d + ' ' + h + ':' + m; //年月日时分秒 }, //加载报警类型 loadYjType() { request.vsportal('XcxJkAction.yjType', this.formYjData).then((res) => { if (res.status) { res.data.forEach(item => { this.alarmTypeList.push({ 'text': item.alarmtype, 'value': item.alarmtype }) }) /* res.data.adas.forEach(item =>{ this.alarmTypeList.push({'text':item.alarmtype,'value':item.alarmtype}) }) res.data.bds.forEach(item =>{ this.alarmTypeList.push({'text':item.alarmtype,'value':item.alarmtype}) }) res.data.dsm.forEach(item =>{ this.alarmTypeList.push({'text':item.alarmtype,'value':item.alarmtype}) }) */ } }); }, loadCount(id) { var num = '' request.vsportal('XcxJgAction.warCount', { powerid: id }).then((res)=> { if (res.status) { if(res.data.count == 0){ uni.removeTabBarBadge({ index:2 }) }else{ uni.setTabBarBadge({ //显示数字 index: 2, //tabbar下标 text: res.data.count >100 ? '99+' : res.data.count+'' //数字 }) } } }) }, //加载列表数据 loadData() { this.status = "loading"; request.vsportal('XcxJgAction.dcWarnInfo', this.formData).then((res)=> { //request.vsportal('XcxJgAction.ysWarn', this.formData).then(function(res) { if (res.status) { var list = res.data if (list.length > 0) { this.showMore = true if (this.formData.page == 1) { this.scrollToTop() this.alarmDateList = [] } for (var i = 0; i < list.length; i++) { if (list[i].firstlocation.indexOf('[]') != -1) { list[i].firstlocation = '' } this.alarmDateList.push(list[i]) } this.showEmpty = false this.status = 'noMore' } else { this.status = "noMore" if ('pull' == this.refreshType) { if (this.alarmDateList.length != 0) { this.showEmpty = false this.showMore = true } } else { this.alarmDateList = res.data this.showEmpty = true this.showMore = false } } } uni.hideLoading() }) }, //点击顶部车牌号搜索 serchPlate() { this.formData.page = 1 this.refreshType = 'search' if (this.plate == undefined || "" == this.plate) { delete this.formData.plateno } else { this.formData.plateno = this.plate } this.loadData() }, // 全部类型下拉框 changeStatus(e) { this.refreshType = 'search' if ("" == e) { this.formData.page = 1 this.formData.cysprocessed = '' this.formData.powerprocessed = '' delete this.formData.spzt }else { this.formData.page = 1 this.formData.powerprocessed = e //this.formData.cysprocessed = '3OL4M8GZ' } uni.showLoading({ title: '加载中...', }) setTimeout(() => { this.loadData() }, 1000) }, //滑动到顶部 scrollToTop() { uni.pageScrollTo({ selector: ".cart-box", scrollTop: 0 }); }, // 报警类型下拉框 changeBjStatus(e) { uni.showLoading({ title: '加载中...' }) this.refreshType = 'search' if ("" == e) { this.formData.alarmtype = '' this.formData.page = 1 delete this.formData.alarmtype } else { this.formData.page = 1 this.formData.alarmtype = e } setTimeout(() => { this.loadData() }, 1000) }, showDataPick() { if (this.showTabBar) { this.changeTab('hide') } }, // 确定日期时触发事件 dateChange(time) { uni.showLoading({ title: '加载中...' }) this.refreshType = 'search' if (undefined != time[0] && undefined != time[1]) { this.formData.page = 1 this.formData.starttime = time[0] this.formData.endtime = time[1] } else { delete this.formData.starttime; delete this.formData.endtime; } setTimeout(() => { this.loadData() this.changeTab('show') }, 1000) }, canel() { this.$refs.popup2.close() }, //上啦 onReachBottom() { var my = this; my.refreshType = 'pull' my.formData.page++; my.formData.page = my.formData.page this.loadData() }, submit() { this.$refs.popup.close() this.$refs.popup2.close() }, // 跳处理 openDisposeTypePopup(arr,lx) { uni.navigateTo({ url: "/pagesFen/prewarning/deatail-xq?ddid=" + arr.id + '&lx=' + lx }) }, // 跳转详情 redirectDetail(id, status, cysstatus,index) { this.currentClickListIndex = index uni.navigateTo({ url: "/pagesFen/prewarning/deatail?ddid=" + id + "&type=" + status + "&cysstatus=" + cysstatus }) }, changeTab(type) { if ('hide' == type) { uni.hideTabBar({ animation: true }) this.showTabBar = false } else { uni.showTabBar({ animation: true }) this.showTabBar = true } } } } </script>优化代码,将懒加载实现
08-14
/** * JAFRSHO07030 ViewModel * * 指令確認画面_指令取消受信ポップアップのViewModel */ @HiltViewModel class JAFRSHO07030ViewModel @Inject constructor( /** ローカルストレージの操作 */ private val localStorageRepository: LocalStorageRepository, /** 受信ポップアップキュー更新処理UseCase */ private val jAFRSHO99010E504UseCase: IJAFRSHO99010E504UseCase, private val jAFRSHO07030E001UseCase1: IJAFRSHO07030E001UseCase1, private val jAFRSHO07030E001UseCase2: IJAFRSHO07030E001UseCase2, private val jAFRSHO07030E501UseCase: IJAFRSHO07030E501UseCase, private val jAFRSHO07030E502UseCase: IJAFRSHO07030E502UseCase, private val jAFRSHS99300P003UseCase: JAFRSHS99300P003UseCase, private val jAFRSHS99300P004UseCase: JAFRSHS99300P004UseCase, private val jAFRSHS99300P005UseCase: JAFRSHS99300P005UseCase, private val jAFRSHS99020P001UseCase: JAFRSHS99020P001UseCase, /** 受信ポップアップキュー更新処理のUseCase */ private val jAFRSHO99010E503UseCase: JAFRSHO99010E503UseCase, ) : JafViewModel<JAFRSHO07030UiState>() { /** 指令取消モデル */ var shireiCancelNoticeModel: ShireiCancelNoticeModel = ShireiCancelNoticeModel() /** 手配メモ */ var tehaiMemo: String = "" /** * システムイベント処理 */ override fun onEvent(event: JafEvent) { when (event) { is JafEvent.Companion.InitializeWithParameters<*> -> { val params = event.params as JsonObject launchWithLoading { onPopupDisplayTest(params) // onPopupDisplay(params) } } } } /** * アクション処理 */ override fun onAction(action: JafAction) { when (action) { // 了解 - 押下 is JAFRSHO07030Action.OnBtnRoger -> { launchWithLoading { onBtnRoger( ifShikibetsuCdParam = action.ifShikibetsuCd, userCdParam = action.userCd, shireiMngCdParam = action.shireiMngCd, syoriId = action.syoriId, ) } } // …(参照) - 押下 is JAFRSHO07030Action.OnBtnRefer -> { onBtnRefer() } } } /** * …(参照) - 押下 * */ fun onBtnRefer() { // 3 入力用ポップアップ画面(JAFRSHO99040E001)をモーダル表示する。 try { navigate( JAFRSHORoutes.DISPLAY_INPUT, JAFRSHO99040Model( titleString = "メモ", displayPurpose = DisplayPurpose.INFORMATION_REFERENCE, inputData = this.tehaiMemo ) ) } catch (ex: StandardBusinessException.BusinessException) { // 5 メッセージポップアップを表示する。 showMessage( messageId = ex.messageId, messageParameter = ex.params ) } } /** * 了解 - 押下 * * @property ifShikibetsuCdParam IF識別コード * @property userCdParam ユーザーコード * @property shireiMngCdParam IF識別コード * @property syoriId 処理ID */ suspend fun onBtnRoger( ifShikibetsuCdParam: String, userCdParam: String, shireiMngCdParam: String, syoriId: String? ) { // JAFRSHO07030E002 処理開始 try { if (syoriId.isNullOrEmpty()) { // 1 指令確認画面_指令取消受信ポップアップを閉じる。 navigateBack() } // 2 共通ヘッダーの受信ポップアップキュー削除処理を実行する。 jAFRSHO99010E504UseCase.invoke( params = ReceivePopupQueDeleteInModel( ifNo = ifShikibetsuCdParam, userCd = userCdParam, recvDatetime = "", shireiMngCd = shireiMngCdParam, shijiTypeCd = "" ) ) } catch (ex: StandardBusinessException.BusinessException) { // 5 メッセージポップアップを表示する。 showMessage( messageId = ex.messageId, messageParameter = ex.params ) } } /** 画面項目通知メッセージ用 */ private suspend fun generateNoticeMessage( shireiCancelNoticeModel: ShireiCancelNoticeModel ): String { var messageCase1 = "" val result = jAFRSHO07030E001UseCase2.invoke(shireiCancelNoticeModel) val initializeDispData = result.getOrNull() if (initializeDispData != null) { when (initializeDispData.torikeshiReasonCls) { "0" -> messageCase1 = "指令は解除されました。" "1" -> messageCase1 = "指令は振り替えられました。" "2" -> messageCase1 = "指令は取り消しました。" else -> {} } } var messageCase2: String = if ( localStorageRepository.getTCarGyomuAppStatusInfo()?.windowId == "JAFRSHO03010" ) { "指令一覧画面を更新します。" } else { "編集は破棄され、指令一覧画面に遷移します。" } return messageCase1 + "\n" + messageCase2 } /** 画面項目用 */ suspend fun onPopupDisplayTest(shireiCancelNoticeIfParam: JsonObject) { val params = ShireiCancelNoticeModel( shireiMngCd = shireiCancelNoticeIfParam["shireiMngCd"] ?.jsonPrimitive?.contentOrNull ?: "", tehaiReasonCd = shireiCancelNoticeIfParam["tehaiReasonCd"] ?.jsonPrimitive?.contentOrNull ?: "", tehaiMemo = shireiCancelNoticeIfParam["tehaiMemo"] ?.jsonPrimitive?.contentOrNull ?: "", cancelDenpyoFlg = shireiCancelNoticeIfParam["cancelReqResult"] ?.jsonPrimitive?.contentOrNull ?: "", ifShikibetsuCd = shireiCancelNoticeIfParam["ifShikibetsuCd"] ?.jsonPrimitive?.contentOrNull ?: "" ) val noticeMessage = generateNoticeMessage(params) setSuccess( JAFRSHO07030UiState( lblInstructionNo = "1234567 − 123", lblUketsukeCompDatetime = "2024/08/01 11:12", lblCancellationReason = "あいうえお678901234567890", lblMemo = "かきくけこ6789012345678901234", lblNoticeMessage = noticeMessage, lblReceptionTime = "00:00受信" ) ) } /** * 画面表示 * * @param shireiCancelNoticeIfParam 指令取消通知IF */ @JafTransaction suspend fun onPopupDisplay(shireiCancelNoticeIfParam: JsonObject) { // JAFRSHO07030E001 処理開始 // 1 変数を設定する。 // 1.1 インスタンス変数.指令取消通知IFのJSONを変換して、インスタンス変数.指令取消通知モデルに設定する。 shireiCancelNoticeModel = shireiCancelNoticeIfParam.toShireiCancelNoticeModel() try { val tReceivePopupQueInfoTmp: TReceivePopupQueInfo? = jAFRSHO07030E001UseCase1.invoke(shireiCancelNoticeModel).getOrThrow() if (tReceivePopupQueInfoTmp == null || tReceivePopupQueInfoTmp.dspStatusFlg != DspStatusFlg.COMPLETION.code ) { try { jAFRSHO07030E501UseCase.invoke(shireiCancelNoticeModel).getOrThrow() jAFRSHO07030E502UseCase.invoke(shireiCancelNoticeModel).getOrThrow() if (localStorageRepository .getTCarGyomuAppStatusInfo()?.windowId == "JAFRSHO03010" ) { // 指令一覧画面を表示時、指令一覧更新(JAFRSHO03010E501)を実施する。 // 指令一覧更新(JAFRSHO03010E501)を実施する。 // jAFRSHO03010E501UseCase.invoke().getOrThrow() // TODO JAFRSHO03010E501UseCase 実装 } if (localStorageRepository .getTCarGyomuAppStatusInfo()?.windowId == "JAFRSHO06010" ) { // 指令一覧画面を表示時、指令一覧更新(JAFRSHO03010E001)を実施する。 // 指令一覧更新(JAFRSHO03010E001)を実施する。 // jAFRSHO03010E001UseCase.invoke().getOrThrow() // TODO JAFRSHO03010E001UseCase 実装 } try { jAFRSHS99300P003UseCase.invoke( params = DotaiEventCdshireiMngCdModel( dotaiEventCd = "DTI_EVT_1021", shireiMngCd = shireiCancelNoticeModel.shireiMngCd ) ) } catch (_: StandardBusinessException.BusinessException) { throw StandardBusinessException.BusinessException( Message.JAFRSHO99010EC00218.id, listOf(""), "動態変更処理失敗" ) } try { jAFRSHS99300P003UseCase.invoke( params = DotaiEventCdshireiMngCdModel( dotaiEventCd = "DTI_EVT_2113", shireiMngCd = shireiCancelNoticeModel.shireiMngCd ) ) } catch (_: StandardBusinessException.BusinessException) { throw StandardBusinessException.BusinessException( Message.JAFRSHO99010EC00218.id, listOf(""), "動態変更処理失敗" ) } // 動態変更を車載連携アプリ、車載ナビに送信する。 val isSuccessTmp: Boolean = jAFRSHS99300P004UseCase.invoke( params = DotaiEventCdshireiMngCdModel( dotaiEventCd = "DTI_EVT_2113", shireiMngCd = shireiCancelNoticeModel.shireiMngCd ) ).getOrThrow() if (!isSuccessTmp) { throw StandardBusinessException.BusinessException( Message.JAFRSHO99010EC00218.id, listOf(""), "動態変更送信処理失敗" ) } // 共通ヘッダーの受信ポップアップキュー更新処理(JAFRSHO99010E503)を実行する。 try { jAFRSHO99010E503UseCase.invoke( params = ReceivePopupQueUpdateInModel( ifNo = shireiCancelNoticeModel.ifShikibetsuCd, userCd = shireiCancelNoticeModel.userCd, recvDatetime = "", shireiMngCd = shireiCancelNoticeModel.shireiMngCd, gojiSyuseiFlg = 0 ) ).getOrThrow() } catch (_: StandardBusinessException.BusinessException) { throw StandardBusinessException.BusinessException( Message.JAFRSHO99010EC00218.id, listOf(""), "受信ポップアップキュー更新処理失敗" ) } // トランザクションをコミットする。(@JafTransaction) } catch (e: Exception) { // トランザクションが開いている場合、ロールバックする。 throw e } } // 20 受信サウンドを鳴らす。 if (localStorageRepository.getMCarWorkSettingInfoList().find { it.parameterName == "指令取消受信" }?.parameterValue != "" ) { playLocalAudio( filePathParam = localStorageRepository.getMCarWorkSettingInfoList().find { it.parameterName == "指令取消受信" }?.parameterValue!! ) } jAFRSHO07030E001UseCase2.invoke(shireiCancelNoticeModel).getOrThrow() val initializeDispDataTmp: InitializeDispData = jAFRSHO07030E001UseCase2.invoke( params = shireiCancelNoticeModel ).getOrThrow() // 画面項目を設定する val inputFormat: String = DateUtils.TYPE_26 // 15桁(yyyyMMdd HHmmss) val outputFormat: String = DateUtils.TYPE_24 val uketsukeCompDatetimeTmp: Date? = parseFormatDate(inputFormat, initializeDispDataTmp.uketsukeCompDatetime) val uketsukeCompDatetimeFormatTmp = if (uketsukeCompDatetimeTmp != null) { DateUtils.getFormatString( outputFormat, uketsukeCompDatetimeTmp ) } else { "" } val noticeMessage = generateNoticeMessage(shireiCancelNoticeModel) val uiStateDataTmp = JAFRSHO07030UiState( lblInstructionNo = initializeDispDataTmp.shireiNo + " − " + initializeDispDataTmp.shireiBrNo, lblUketsukeCompDatetime = uketsukeCompDatetimeFormatTmp, lblCancellationReason = initializeDispDataTmp.reason, lblMemo = initializeDispDataTmp.tehaiMemo, lblReceptionTime = getCurrentFormatString(DateUtils.TYPE_1) + "受信", lblNoticeMessage = noticeMessage, ) // 27 インスタンス変数を新規作成して、設定する。 tehaiMemo = initializeDispDataTmp.tehaiMemo // 28 指令確認画面_指令取消受信ポップアップを作成する。 setSuccess(uiStateDataTmp) } catch (ex: StandardBusinessException.BusinessException) { // 29 メッセージポップアップを表示する。 showMessage( messageId = ex.messageId, messageParameter = ex.params ) } } } 关于这个代码里面有关onPopupDisplayTest的函数,能不能把他优化到onPopupDisplay当中 然后假数据通过screen到navigation传递,类似于下面这种写法: screen JafBottomButton( text = "作業者選択ポップアップ", enabled = true, onClick = { viewModel.onEvent( JafEvent.Companion.Navigate( JAFRSHORoutes.WORKE_SELECT, JAFRSHO99250Model( mngNo = 100, sagyoShaNameParam = "日電太郎", onConfirmCallBack = {} ) ) ) }, modifier = Modifier.size(138.dp, 66.dp) ) navigation jafDialog( navController = navController, route = JAFRSHORoutes.WORKE_SELECT, padding = PaddingValues(250.dp, 180.dp), title = {stringResource(R.string.worker_select)} ) { params -> val jafrshO99250Model = params as JAFRSHO99250Model JAFRSHO99250Popup( jAFRSHO99250Model = jafrshO99250Model ) }
最新发布
10-22
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值