صفحه ازدواج
نمای مینی اپ به صورت زیر است
کد
<page id="sanad-ezdevaj" onshown="script/main:init()">
<script id="main">
function tabClick(id) {
const buttons = ['sanad', 'zojein']
buttons.forEach(b => {
if (id !== b) {
Appsan.setProperty('btn_' + b, 'textcolor', '#43474E');
Appsan.setProperty(b, 'visibility', 'gone');
}
})
Appsan.setProperty('btn_' + id, 'textcolor', '#0164BC');
Appsan.setProperty(id, 'visibility', 'visible');
}
function init() {
const requestNo = Appsan.getVariable('doc_id')?.value
HTTPClient.get('http://192.168.1.109:3000/api/v1/marry/detailsEvent/' + requestNo,
{
headers: {
"Content-Type": "application/json",
"Authorization": "Bearer eyJhbGciOiJIUzUxMiJ9.eyJtaW5pQXBwTmFtZSI6ImFwcDphZG1pbjp2YWdoYXllLWV6ZGV2YWotdmEtdGFsYWdoIiwidXNlcm5hbWUiOiIxMTExMTExMTExIiwic3ViIjoibWluaUFwcCIsImlhdCI6MTY5OTA4MTMxMywiZXhwIjoxNjk5OTQ1MzEzfQ.eR5ZDvwajy-ibloi5TiwIAFqftJLvsVzwkm7DjOggthy6zyxdNSmuxYmdON7MSEvKKCLO344iKggT88g82zauw",
"user-token": ""
}
}).subscribe(res => {
if (res)
processDetailsDoc(res);
else
Appsan.runAction('snackbar/errorSnackbar');
}
);
}
function processDetailsDoc(res) {
Appsan.setProperty('txt_nationalNo', 'text', res.nationalRegisterNo);
Appsan.setProperty('txt_serialNo', 'text', res.registerNO);
Appsan.setProperty('txt_registerDate', 'text', res.registerDate);
Appsan.setProperty('txt_scriptoriumName', 'text', res.scriptoriumName);
Appsan.setProperty('txt_wifeFullName', 'text', res.wifeFullName);
Appsan.setProperty('txt_wifeNationalNO', 'text', res.wifeNationalNO);
Appsan.setProperty('txt_husbandFullName', 'text', res.husbandFullName);
Appsan.setProperty('txt_husbandNationalNO', 'text', res.husbandNationalNO);
}
</script>
<frame layout="linear_vertical" gravity="center" margin="16" width="match_parent"
background="white">
<img width="match_parent" height="220" src="images/sanad3.png"/>
<text text="سند ازدواج" textcolor="#424750" textsize="12"></text>
<frame layout="linear_horizontal" weight="1" weightsum="2" reverse="true"
margin="16">
<frame layout="linear_vertical" height="48" weight="1" gravity="right" childgravity="right"
padding_bottom="12"
weightsum="1" reverse="true" background="white">
<text textsize="13" textcolor="#0164BC" textalignment="right" gravity="right" textstyle="bold"
text="مشخصات سند" id="btn_sanad" padding_right="20" onclick="script/main:tabClick('sanad')"/>
</frame>
<frame layout="linear_vertical" height="48" weight="1" gravity="right" childgravity="right"
reverse="true" padding_bottom="12"
background="white">
<text textsize="12" textcolor="#43474E" textalignment="left" gravity="left" id="btn_zojein"
text="مشخصات زوجین" padding_left="20" onclick="script/main:tabClick('zojein')"/>
</frame>
</frame>
<frame margin_right="16" margin_left="16">
<divider color="#E6E0E9" size="1"></divider>
</frame>
<frame></frame>
<frame layout="linear_vertical" weight="1" id="sanad" visibility="visible">
<frame layout="linear_horizontal" weight="1" weightsum="3" reverse="true">
<text textsize="12" textalignment="right" weight="2" textcolor="#424750" text="شناسه یکتا"/>
<text textsize="12" textalignment="right" weight="1" textcolor="#424750"
text="" id="txt_nationalNo"/>
</frame>
<frame margin_right="12" margin_left="12">
<divider color="#F0F0F1" size="1"></divider>
</frame>
<frame layout="linear_horizontal" weight="1" weightsum="3" reverse="true">
<text textsize="12" textalignment="right" weight="2" textcolor="#424750" text="شماره ترتیب"/>
<text textsize="12" textalignment="right" weight="1" textcolor="#424750" id="txt_serialNo"/>
</frame>
<frame margin_right="12" margin_left="12">
<divider color="#F0F0F1" size="1"></divider>
</frame>
<frame layout="linear_horizontal" weight="1" weightsum="3" reverse="true">
<text textsize="12" textalignment="right" weight="2" textcolor="#424750" text="تاریخ ثبت"/>
<text textsize="12" textalignment="right" weight="1" textcolor="#424750" id="txt_registerDate"/>
</frame>
<frame margin_right="12" margin_left="12">
<divider color="#F0F0F1" size="1"></divider>
</frame>
<frame layout="linear_horizontal" weight="1" weightsum="3" reverse="true">
<text textsize="12" textalignment="right" weight="2" textcolor="#424750" text="دفترخانه"/>
<text textsize="12" textalignment="right" weight="1" textcolor="#424750" id="txt_scriptoriumName"/>
</frame>
</frame>
<frame layout="linear_vertical" id="zojein" visibility="gone">
<frame layout="linear_horizontal" width="match_parent" reverse="true"
gravity="center"
weightsum="2" padding="0">
<img width="24" height="24" gravity="right" scaleType="fit_center"
src="images/User.png"/>
<text gravity="left" textalignment="right" text="نام و نام خانوادگی زوجه" weight="1"
padding_left="4" textsize="12"/>
<text textsize="12" textalignment="right" weight="1" textcolor="#424750"
text="" id="txt_wifeFullName"/>
</frame>
<frame layout="linear_horizontal" weight="1" weightsum="3" reverse="true" margin_right="28">
<text textsize="12" textalignment="right" weight="2" textcolor="#424750" text="کد ملی زوجه"/>
<text textsize="12" textalignment="right" weight="1" textcolor="#424750"
text="" id="txt_wifeNationalNO"/>
</frame>
<frame margin_right="12" margin_left="12">
<divider color="#F0F0F1" size="1"></divider>
</frame>
<frame layout="linear_horizontal" width="match_parent" reverse="true"
gravity="center"
weightsum="2" padding="0">
<img width="24" height="24" gravity="right" scaleType="fit_center"
src="images/User.png"/>
<text gravity="left" textalignment="right" text="نام و نام خانوادگی زوج" weight="1"
padding_left="4" textsize="12"/>
<text textsize="12" textalignment="right" weight="1" textcolor="#424750"
text="" id="txt_husbandFullName"/>
</frame>
<frame layout="linear_horizontal" weight="1" weightsum="3" reverse="true" margin_right="28">
<text textsize="12" textalignment="right" weight="2" textcolor="#424750" text="کد ملی زوج"/>
<text textsize="12" textalignment="right" weight="1" textcolor="#424750"
id="txt_husbandNationalNO"/>
</frame>
</frame>
</frame>
</page>
No Comments