




版權(quán)說(shuō)明:本文檔由用戶提供并上傳,收益歸屬內(nèi)容提供方,若內(nèi)容存在侵權(quán),請(qǐng)進(jìn)行舉報(bào)或認(rèn)領(lǐng)
文檔簡(jiǎn)介
Index頁(yè)面第一步:新建index頁(yè)面利用自定義模板建立空白頁(yè)面第二步:將該頁(yè)底部欄等所需圖片放入images文件夾。第三步:在對(duì)應(yīng)文件中加入自定義類1、在ui-color.css文件中加入以下代碼.bc-red1{background-color:#c92440;}.bc-text-gra2{color:#cdcdcd!important;}.bc-gra1{background-color:#eeeeee;}2、在ui-base.css文件中加入以下代碼:.uinn6-d{margin:0.45em0;}.foot-umh{height:2.75em;}3、在appcan.icon.css文件中加入以下代碼:.res12{background-image:url('images/search.png');height:1.3em;}.res11{background-image:url('images/saomiao.png');}4、在my_style.css文件中加入以下代碼:.b-gra-f{border-top:1pxsolid#c92440;}.uh3{ height:3em;}.uw2{ width:1.25em;}.uh2{ height:1.25em;}第四步:引入相關(guān)文件在head中引入:<linkrel="stylesheet"href="css/aboutform.css"><linkrel="stylesheet"href="css/my-style.css"><linkrel="stylesheet"href="css/new-file.css">將main.js和common.js引入到j(luò)s文件夾下,并在頁(yè)面script中加入以下代碼:<scriptsrc="js/main.js"></script><scriptsrc="js/common.js"></script><scriptsrc="js/appcan.tab.js"></script><scriptsrc="js/appcan.mbaas.js"></script>第五步:HTML代碼1、頁(yè)面布局框架<divid="page_0"class="upuofubub-ver"tabindex="0"><divid="header"class="uofuhbc-red1bc-text-headubub-acub-pc"><!--Header部分--></div><!--Header2選項(xiàng)卡--><divid="content"class="ub-f1tx-lbc-textsc-bg"></div><divid="footer"class="b-gra-fbc-gra1foot-umh"> <divclass="ubuh3bc-text-head"style="height:2.8em;"> <!--Footer部分--> </div></div></div>2、header部分<divclass="ubumw3uinn6-dumar-l"style="margin-left:.6em"><divclass="uinn"id="ret">返回</div></div><divclass="ubub-verub-pcub-f1"><divstyle="height:.8em;"></div></div><divclass="umw1"></div><divonclick="weima(event)"><divclass="res11ub-img"style="margin:01em00;width:1.2em;height:1.3em"></div></div>效果如圖:3、header2插入選項(xiàng)卡<divid="tabview"class="ufsc-bg"></div>修改選項(xiàng)卡選項(xiàng)卡名稱參數(shù):vartabview=appcan.tab({selector:"#tabview",hasIcon:false,hasAnim:true,hasLabel:true,hasBadge:false,data:[{label:"距離","icon":"fa-qq"},{label:"好評(píng)","icon":"fa-windows"},{label:"人氣","icon":"fa-weixin",},{label:"人均","icon":"fa-weixin",}]});修改ready中頭部高度,否則查看時(shí)選項(xiàng)卡會(huì)一閃而過(guò),被浮動(dòng)窗口覆蓋:vartop=$('#header').offset().height+$('#tabview').offset().height;效果如圖:4、footer部分 <inputclass="uhide"type="radio"name="tabSwitch"checked="true"> <divclass="ubub-acub-pcub-f1b-red-fc-bg-d"> <divclass="ub-imgim-shanghuuh2uw2"></div> <divclass="umar-l07ulev-1ubub-acub-pct-gra-f"style="padding:.5em0.5em0;">商戶</div> </div> <inputclass="uhide"type="radio"name="tabSwitch"> <divonclick="openwin('salesPromotion','salesPromotion.html')"class="ubub-acub-pcub-f1c-bg-db-red-f"> <divclass="ub-imgim-cuxiaouh2uw2"></div> <divclass="umar-l07ulev-1ubub-acub-pct-gra-f"style="padding:.5em0.5em0">優(yōu)惠</div> </div> <inputclass="uhide"type="radio"name="tabSwitch"> <divonclick="openwin('comment','comment.html')"class="ubub-acub-pcub-f1c-bg-db-red-f"> <divclass="ub-imgim-pinglunuh2uw2"></div> <divclass="umar-l07ulev-1ubub-acub-pct-gra-f"style="padding:.5em0.5em0;">評(píng)論</div> </div> <inputclass="uhide"type="radio"name="tabSwitch"> <divonclick="openwin('my','my.html')"class="ubub-acub-pcub-f1c-bg-db-red-f"> <divclass="ub-imgim-myuh2uw2"></div> <divclass="umar-l07ulev-1ubub-acub-pct-gra-f">我的</div> </div>效果如圖:說(shuō)明:openwin在main.js里面定義im-shanghu等樣式在about-form.css里面定義第六步:JS代碼掃二維碼功能:在二維碼html區(qū)域添加onclick事件functionweima(e){e.stopPropagation();e.preventDefault();uexScanner.open("ZXing","掃餐桌二維碼完成下單");}functionScannerSuccessCallBack(opCode,dataType,data){vardata1=JSON.parse(data);varww=data1.code.replace(/\\"/g,"'");varst=JSON.parse(ww);appcan.setLocVal("shopId",st.shop_id);//商鋪idappcan.setLocVal("shopName",st.shop_name);//商鋪名稱appcan.setLocVal("caidan_id",st.caidan_id);//菜單idappcan.setLocVal("caidan_num",st.caidan_num);//菜單份數(shù)appcan.setLocVal("per_count",st.per_count);//到店人數(shù)appcan.setLocVal("openmenu",0);//菜單頁(yè)顯示本店所有菜單appcan.setLocVal("erweima",0);//從首頁(yè)掃碼進(jìn)入菜單頁(yè)vardate=newDate;varnowtime=date.getTime()/1000;appcan.setLocVal('yuyueitme',nowtime);appcan.window.open('menu','menu.html','10','4');}返回按鈕appcan.button("#ret","btn-act",function(){appcan.window.close(-1);})3、ready方法appcan.ready(function(){vartop=$('#header').offset().height+$('#tabview').offset().height;appcan.frame.open({id:"content",url:"index_content.html",//窗口1路徑top:top,left:0,index:0,change:function(err,res){tabview.moveTo(res.multiPopSelectedIndex);//移動(dòng)到所選中的索引窗口}});});4、選項(xiàng)卡切換tabview.on("click",function(obj,index){appcan.window.selectMultiPopover('content',index);switch(parseInt(index)){case0:appcan.window.publish('s0',0);break;case1:appcan.window.publish('s0',1);break;case2:
溫馨提示
- 1. 本站所有資源如無(wú)特殊說(shuō)明,都需要本地電腦安裝OFFICE2007和PDF閱讀器。圖紙軟件為CAD,CAXA,PROE,UG,SolidWorks等.壓縮文件請(qǐng)下載最新的WinRAR軟件解壓。
- 2. 本站的文檔不包含任何第三方提供的附件圖紙等,如果需要附件,請(qǐng)聯(lián)系上傳者。文件的所有權(quán)益歸上傳用戶所有。
- 3. 本站RAR壓縮包中若帶圖紙,網(wǎng)頁(yè)內(nèi)容里面會(huì)有圖紙預(yù)覽,若沒(méi)有圖紙預(yù)覽就沒(méi)有圖紙。
- 4. 未經(jīng)權(quán)益所有人同意不得將文件中的內(nèi)容挪作商業(yè)或盈利用途。
- 5. 人人文庫(kù)網(wǎng)僅提供信息存儲(chǔ)空間,僅對(duì)用戶上傳內(nèi)容的表現(xiàn)方式做保護(hù)處理,對(duì)用戶上傳分享的文檔內(nèi)容本身不做任何修改或編輯,并不能對(duì)任何下載內(nèi)容負(fù)責(zé)。
- 6. 下載文件中如有侵權(quán)或不適當(dāng)內(nèi)容,請(qǐng)與我們聯(lián)系,我們立即糾正。
- 7. 本站不保證下載資源的準(zhǔn)確性、安全性和完整性, 同時(shí)也不承擔(dān)用戶因使用這些下載資源對(duì)自己和他人造成任何形式的傷害或損失。
最新文檔
- DB4228T 79-2022 茶樹(shù)害蟲(chóng)茶網(wǎng)蝽綠色防控技術(shù)規(guī)程
- DB4206T 77-2024 大棚豇豆水肥一體化栽培技術(shù)規(guī)程
- 大理農(nóng)林職業(yè)技術(shù)學(xué)院《臨床微生物檢驗(yàn)技術(shù)》2023-2024學(xué)年第一學(xué)期期末試卷
- 長(zhǎng)沙學(xué)院《多聲部音樂(lè)分析與習(xí)作二》2023-2024學(xué)年第一學(xué)期期末試卷
- 泉州幼兒師范高等專科學(xué)?!稊?shù)據(jù)庫(kù)課程設(shè)計(jì)》2023-2024學(xué)年第一學(xué)期期末試卷
- 2025至2030海洋運(yùn)輸行業(yè)產(chǎn)業(yè)運(yùn)行態(tài)勢(shì)及投資規(guī)劃深度研究報(bào)告
- 世紀(jì)之光活動(dòng)方案
- 業(yè)主來(lái)訪活動(dòng)方案
- 培訓(xùn)中心感恩活動(dòng)方案
- 大型工會(huì)活動(dòng)方案
- 《造林綠化落地上圖操作技術(shù)規(guī)范》
- 國(guó)企基金公司招聘考試題
- 燒傷科普講座課件
- 深度學(xué)習(xí)技術(shù)基礎(chǔ)與實(shí)踐 課件全套 呂建成 第1-8章 深度學(xué)習(xí)概述-強(qiáng)化學(xué)習(xí)實(shí)戰(zhàn)
- KALLER基本的氮?dú)鈴椈衫碚撝R(shí)
- 《狼性企業(yè)文化》課件
- 智慧能源管理平臺(tái)建設(shè)方案書(shū)
- 周轉(zhuǎn)材料管理制度范本
- 《線性代數(shù)》課程思政的案例及思考
- 免疫規(guī)劃媽媽課堂培訓(xùn)
- 江西管理職業(yè)學(xué)院教師招聘考試歷年真題
評(píng)論
0/150
提交評(píng)論