How to use Home method in argos

Best JavaScript code snippet using argos

App.js

Source:App.js Github

copy

Full Screen

1import { BrowserRouter as Router, Route, Routes, Link } from "react-router-dom";2import { useState } from "react";3import "./index.css";4import ScrollTop from "./ScrollToTop";5import Navbar from "./Navbar/Navbar";6import Banner from "./Banner/Banner";7import Footer from "./Footer/Footer";8import LiverpoolSales from "./Pages/LiverpoolSales";9import ManCitySales from "./Pages/ManCitySales";10import ManUnitedSales from "./Pages/ManUnitedSales";11import ArsenalSales from "./Pages/ArsenalSales";12import AboutUs from "./Footer/AboutUs";13import DeliveryGuarantee from "./Footer/Delivery";14import PrivacyPolicy from "./Footer/Privacy";15import TermsOfUse from "./Footer/Terms";16import SizeChart from "./Footer/SizeChart";17import FaqHelp from "./Footer/Faq-help";18import Shipping from "./Footer/Shipping";19import ReturnPolicy from "./Footer/ReturnPolicy";20import PaymentMethod from "./Footer/PaymentMehdod";21import Login from "./Footer/Login";22import SignUp from "./Footer/CreateAccount";23import MyAccount from "./Footer/Login";24import MyOrders from "./Footer/Login";25import ForgotPassword from "./Footer/ForgetPassword";26import AjaxTshirtThird from "./BestSellers/Ajax-tshirt-third";27import LionelTshirtAway from "./BestSellers/Lionel-tshirt-away";28import LionelTshirtHome from "./BestSellers/Lionel-tshirt-home";29import BarcelonaTshirtAway from "./BestSellers/Barcelona-tshirt-away";30import ManUnitedTshirtHome from "./BestSellers/ManUnited-tshirt-home";31import InterMilanTshirtHome from "./BestSellers/InterMilan-tshirt-home";32import BayernMunichTshirtAway from "./BestSellers/BayernMunichTshirtAway";33import PsgTshirtHome from "./BestSellers/Psg-tshirt-home";34import ChelseaTshirtHome from "./BestSellers/Chelsea-tshirt-home";35import TottenhamTshirtAway from "./BestSellers/Tottenham-tshirt-away";36import NationalTeam from "./Leauges/NationalTeam";37import PremierLeauge from "./Leauges/PremierLeauge";38import BundesLiga from "./Leauges/BundesLiga";39import LaLiga from "./Leauges/LaLiga";40import LeaugeOne from "./Leauges/LeuageOne";41import OtherClub from "./Leauges/OtherClub";42import MexicoShirt from "./Leauges/NationalTeam-Pages/MexicoShirt";43import BrazilHome from "./Leauges/NationalTeam-Pages/BrazilHome";44import BrazilAway from "./Leauges/NationalTeam-Pages/BrazilAway";45import ColombiaAway from "./Leauges/NationalTeam-Pages/ColombiaAway";46import ArgentinaAway from "./Leauges/NationalTeam-Pages/ArgentinaAway";47import ArgentinaHome from "./Leauges/NationalTeam-Pages/ArgentinaHome";48import KroosHome from "./Leauges/NationalTeam-Pages/KroosHome";49import KroosAway from "./Leauges/NationalTeam-Pages/KroosAway";50import RonaldoHome from "./Leauges/NationalTeam-Pages/RonaldoHome";51import RonaldoAway from "./Leauges/NationalTeam-Pages/RonaldoAway";52import DepayHome from "./Leauges/NationalTeam-Pages/DepayHome";53import DepayAway from "./Leauges/NationalTeam-Pages/DepayAway";54import DeJongHome from "./Leauges/NationalTeam-Pages/DeJongHome";55import DeJongAway from "./Leauges/NationalTeam-Pages/DeJongAway";56import MbappeHome from "./Leauges/NationalTeam-Pages/MbappeHome";57import MbappeAway from "./Leauges/NationalTeam-Pages/MbappeAway";58import GriezmannHome from "./Leauges/NationalTeam-Pages/GriezmannHome";59import GriezmannAway from "./Leauges/NationalTeam-Pages/GriezmannAway";60import Pogba from "./Leauges/NationalTeam-Pages/PogbaHome";61import PogbaHome from "./Leauges/NationalTeam-Pages/PogbaHome";62import ModricHome from "./Leauges/NationalTeam-Pages/ModricHome";63import DeBruyneHome from "./Leauges/NationalTeam-Pages/DeBruyneHome";64import DeBruyneAway from "./Leauges/NationalTeam-Pages/DeBruyneAway";65import HarryKaneHome from "./Leauges/NationalTeam-Pages/HarryKaneHome";66import HarryKaneAway from "./Leauges/NationalTeam-Pages/HarryKaneAway";67import ItalyHome from "./Leauges/NationalTeam-Pages/ItalyHome";68import ItalyAway from "./Leauges/NationalTeam-Pages/ItalyAway";69import SwedenHome from "./Leauges/NationalTeam-Pages/SwedenHome";70import SwedenAway from "./Leauges/NationalTeam-Pages/SwedenAway";71import PolandHome from "./Leauges/NationalTeam-Pages/PolandHome";72import PortugalHome from "./Leauges/NationalTeam-Pages/PortugalHome";73import PortugalAway from "./Leauges/NationalTeam-Pages/PortugalAway";74import GermanyHome from "./Leauges/NationalTeam-Pages/GermanyHome";75import GermanyAway from "./Leauges/NationalTeam-Pages/GermanyAway";76import NetherlandHome from "./Leauges/NationalTeam-Pages/NetherlandHome";77import NetherlandAway from "./Leauges/NationalTeam-Pages/NetherlandAway";78import SpainHome from "./Leauges/NationalTeam-Pages/SpainHome";79import SpainAway from "./Leauges/NationalTeam-Pages/SpainAway";80import FranceHome from "./Leauges/NationalTeam-Pages/FranceHome";81import FranceAway from "./Leauges/NationalTeam-Pages/FranceAway";82import CroatiaHome from "./Leauges/NationalTeam-Pages/CroatiaHome";83import CroatiaAway from "./Leauges/NationalTeam-Pages/CroatiaAway";84import BelgiumHome from "./Leauges/NationalTeam-Pages/BelgiumHome";85import BelgiumAway from "./Leauges/NationalTeam-Pages/BelgiumAway";86import EnglandHome from "./Leauges/NationalTeam-Pages/EnglandHome";87import EnglandAway from "./Leauges/NationalTeam-Pages/EnglandAway";88import ArsenalAwayShirt from "./Leauges/PremierLeauge-Pages/ArsenalAwayShirt";89import ArsenalAwayKids from "./Leauges/PremierLeauge-Pages/ArsenalAwayKids";90import ChelseaHomeWomen from "./Leauges/PremierLeauge-Pages/ChelseaHomeWomen";91import ChelseaHomeShirt from "./Leauges/PremierLeauge-Pages/ChelseaHomeShirt";92import ChelseaHomeKids from "./Leauges/PremierLeauge-Pages/ChelseaHomeKids";93import LiverpoolHomeWomen from "./Leauges/PremierLeauge-Pages/LiverpoolHomeWomen";94import LiverpoolHomeKids from "./Leauges/PremierLeauge-Pages/LiverpoolHomeKids";95import LiverpoolHomeShirt from "./Leauges/PremierLeauge-Pages/LiverpoolHomeShirt";96import ArsenalThirdLong from "./Leauges/PremierLeauge-Pages/ArsenalThirdLong";97import ArsenalThirdShirt from "./Leauges/PremierLeauge-Pages/ArsenalThirdShirt";98import ArsenalThirdShort from "./Leauges/PremierLeauge-Pages/ArsenalThirdShort";99import ArsenalAwayLong from "./Leauges/PremierLeauge-Pages/ArsenalAwayLong";100import ArsenalAwayShort from "./Leauges/PremierLeauge-Pages/ArsenalAwayShort";101import ArsenalHomeLong from "./Leauges/PremierLeauge-Pages/ArsenalHomeLong";102import ArsenalHomeShirt from "./Leauges/PremierLeauge-Pages/ArsenalHomeShirt";103import ArsenalHomeWomen from "./Leauges/PremierLeauge-Pages/ArsenalHomeWomen";104import ArsenalHomeShort from "./Leauges/PremierLeauge-Pages/ArsenalHomeShort";105import TottenhamHomeShirt from "./Leauges/PremierLeauge-Pages/TottenhamHomeShirt";106import ChelseaThirdShirt from "./Leauges/PremierLeauge-Pages/ChelseaThirdShirt";107import ChelseaThirdKids from "./Leauges/PremierLeauge-Pages/ChelseaThirdKids";108import ChelseaThirdShort from "./Leauges/PremierLeauge-Pages/ChelseaThirdShort";109import ChelseaAwayShirt from "./Leauges/PremierLeauge-Pages/ChelseaAwayShirt";110import ChelseaAwayKids from "./Leauges/PremierLeauge-Pages/ChelseaAwayKids";111import ChelseaAwayShort from "./Leauges/PremierLeauge-Pages/ChelseaAwayShort";112import ChelseaHomeShort from "./Leauges/PremierLeauge-Pages/ChelseaHomeShort";113import LiverpoolThirdShirt from "./Leauges/PremierLeauge-Pages/LiverpoolThirdShirt";114import LiverpoolThirdWomen from "./Leauges/PremierLeauge-Pages/LiverpoolThirdWomen";115import LiverpoolThirdKids from "./Leauges/PremierLeauge-Pages/LiverpoolThirdKids";116import LiverpoolThirdShorts from "./Leauges/PremierLeauge-Pages/LiverpoolThirdShort";117import LiverpoolHomeShorts from "./Leauges/PremierLeauge-Pages/LiverpoolHomeShort";118import LiverpoolAwayShorts from "./Leauges/PremierLeauge-Pages/LiverpoolAwayShort";119import LiverpoolAwayShirt from "./Leauges/PremierLeauge-Pages/LiverpoolAwayShirt";120import LiverpoolAwayKids from "./Leauges/PremierLeauge-Pages/LiverpoolAwayKids";121import ManUnitedThirdLong from "./Leauges/PremierLeauge-Pages/ManUnitedThirdLong";122import ManUnitedAwayLong from "./Leauges/PremierLeauge-Pages/ManUnitedAwayLong";123import ManUnitedThirdShirt from "./Leauges/PremierLeauge-Pages/ManUnitedThirdShirt";124import ManUnitedAwayShirt from "./Leauges/PremierLeauge-Pages/ManUnitedAwayShirt";125import ManUnitedThirdShorts from "./Leauges/PremierLeauge-Pages/ManUnitedThirdShorts";126import ManUnitedAwayShorts from "./Leauges/PremierLeauge-Pages/ManUnitedAwayShorts";127import ManUnitedHomeShorts from "./Leauges/PremierLeauge-Pages/ManUnitedHomeShorts";128import ManUnitedHomeLong from "./Leauges/PremierLeauge-Pages/ManUnitedHomeLong";129import ManUnitedHomeShirt from "./Leauges/PremierLeauge-Pages/ManUnitedHomeShirt";130import ManCityThirdShirt from "./Leauges/PremierLeauge-Pages/ManCityThirdShirt";131import ManCityThirdShorts from "./Leauges/PremierLeauge-Pages/ManCityThirdShort";132import ManCityAwayShorts from "./Leauges/PremierLeauge-Pages/ManCityAwayShort";133import ManCityAwayShirt from "./Leauges/PremierLeauge-Pages/ManCityAwayShirt";134import ManCityHomeShorts from "./Leauges/PremierLeauge-Pages/ManCityHomeShort";135import ManCityHomeShirt from "./Leauges/PremierLeauge-Pages/ManCityHomeShirt";136import TottenhamThirdShirt from "./Leauges/PremierLeauge-Pages/TottenhamThirdShirt";137import TottenhamThirdShort from "./Leauges/PremierLeauge-Pages/TottenhamThirdShort";138import TottenhamAwayShirt from "./Leauges/PremierLeauge-Pages/TottenhamAwayShirt";139import TottenhamAwayShort from "./Leauges/PremierLeauge-Pages/TottenhamAwayShort";140import TottenhamHomeShort from "./Leauges/PremierLeauge-Pages/TottenhamHomeShort";141import WesthamThirdShirt from "./Leauges/PremierLeauge-Pages/WesthamThirdShirt";142import WesthamAwayShirt from "./Leauges/PremierLeauge-Pages/WesthamAwayShirt";143import WesthamHomeShirt from "./Leauges/PremierLeauge-Pages/WesthamHomeShirt";144import WesthamAwayShorts from "./Leauges/PremierLeauge-Pages/WesthamAwayShort";145import WesthamHomeShorts from "./Leauges/PremierLeauge-Pages/WesthamHomeShort";146import BayernThirdShirt from "./Leauges/Bundesliga-Pages/BayernThirdShirt";147import BayernAwayKids from "./Leauges/Bundesliga-Pages/BayernAwayKids";148import DortmundHomeShirt from "./Leauges/Bundesliga-Pages/DortmundHomeShirt";149import LeipzigHomeShirt from "./Leauges/Bundesliga-Pages/LeipzigHomeShirt";150import BayernThirdShort from "./Leauges/Bundesliga-Pages/BayernThirdShort";151import BayernHomeShirt from "./Leauges/Bundesliga-Pages/BayernHomeShirt";152import BayernHomeLong from "./Leauges/Bundesliga-Pages/BayernHomeLong";153import BayernHomeWomen from "./Leauges/Bundesliga-Pages/BayernHomeWomen";154import BayernHomeShort from "./Leauges/Bundesliga-Pages/BayernHomeShort";155import BayernAwayShort from "./Leauges/Bundesliga-Pages/BayernAwayShort";156import DortmundThirdShirt from "./Leauges/Bundesliga-Pages/DortmundThirdShirt";157import DortmundThirdKids from "./Leauges/Bundesliga-Pages/DortmundThirdKids";158import DortmundThirdShort from "./Leauges/Bundesliga-Pages/DortmundThirdShort";159import DortmundAwayShirt from "./Leauges/Bundesliga-Pages/DortmundAwayShirt";160import DortmundAwayShort from "./Leauges/Bundesliga-Pages/DortmunAwayShort";161import DortmundHomeShort from "./Leauges/Bundesliga-Pages/DortmundHomeShort";162import LeipzigThirdShirt from "./Leauges/Bundesliga-Pages/LeipzigThirdShirt";163import LeipzigAwayShirt from "./Leauges/Bundesliga-Pages/LeipzigAwayShirt";164import AtleticoMadridAwayShirt from "./Leauges/LaLiga-Pages/AtleticoMadridAwayShirt";165import AtleticoMadridAwayShorts from "./Leauges/LaLiga-Pages/AtleticoMadridAwayShorts";166import AtleticoMadridHomeShirt from "./Leauges/LaLiga-Pages/AtleticoMadridHomeShirt";167import AtleticoMadridHomeShorts from "./Leauges/LaLiga-Pages/AtleticoMadridHomeShorts";168import AtleticoMadridThirdShirt from "./Leauges/LaLiga-Pages/AtleticoMadridThirdShirt";169import BarcelonaAwayKids from "./Leauges/LaLiga-Pages/BarcelonaAwayKids";170import BarcelonaAwayShirt from "./Leauges/LaLiga-Pages/BarcelonaAwayShirt";171import BarcelonaAwayShorts from "./Leauges/LaLiga-Pages/BarcelonaAwayShorts";172import BarcelonaHomeShirt from "./Leauges/LaLiga-Pages/BarcelonaHomeShirt";173import BarcelonaHomeShorts from "./Leauges/LaLiga-Pages/BarcelonaHomeShorts";174import BarcelonaThirdShirt from "./Leauges/LaLiga-Pages/BarcelonaThirdShirt";175import BarcelonaThirdShort from "./Leauges/LaLiga-Pages/BarcelonaThirdShort";176import RealMadridAwayLong from "./Leauges/LaLiga-Pages/RealMadridAwayLong";177import RealMadridAwayShirt from "./Leauges/LaLiga-Pages/RealMadridAwayShirt";178import RealMadridAwayShorts from "./Leauges/LaLiga-Pages/RealMadridAwayShorts";179import RealMadridHomeKids from "./Leauges/LaLiga-Pages/RealMadridHomeKids";180import RealMadridHomeLong from "./Leauges/LaLiga-Pages/RealMadridHomeLong";181import RealMadridHome from "./Leauges/LaLiga-Pages/RealMadridHomeShirt";182import RealMadridHomeShorts from "./Leauges/LaLiga-Pages/RealMadridHomeShorts";183import RealMadridThirdShirt from "./Leauges/LaLiga-Pages/RealMadridThirdShirt";184import RealMadridThirdShorts from "./Leauges/LaLiga-Pages/RealMadridThirdShorts";185import BarcelonaThirdShorts from "./Leauges/LaLiga-Pages/BarcelonaThirdShort";186import PsgHomeWomen from "./Leauges/LigueOne-Pages/PsgHomeWomen";187import PsgHomeKids from "./Leauges/LigueOne-Pages/PsgHomeKids";188import PsgThirdKids from "./Leauges/LigueOne-Pages/PsgThirdKids";189import PsgThirdShirt from "./Leauges/LigueOne-Pages/PsgThirdShirt";190import PsgAwayShirt from "./Leauges/LigueOne-Pages/PsgAwayShirt";191import PsgThirdShort from "./Leauges/LigueOne-Pages/PsgThirdShort";192import PsgAwayShort from "./Leauges/LigueOne-Pages/PsgAwayShort";193import PsgHomeShort from "./Leauges/LigueOne-Pages/PsgHomeShort";194import AjaxAwayShirt from "./Leauges/OtherClub-Pages/AjaxAwayShirt";195import CelticAwayShirt from "./Leauges/OtherClub-Pages/CelticAwayShirt";196import CelticHomeShirt from "./Leauges/OtherClub-Pages/CelticHomeShirt";197import PortoThirdShirt from "./Leauges/OtherClub-Pages/PortoThirdShirt";198import PortoAwayShirt from "./Leauges/OtherClub-Pages/PortoAwayShirt";199import PortoHomeShirt from "./Leauges/OtherClub-Pages/PortoHomeShirt";200import AjaxThirdKids from "./Leauges/OtherClub-Pages/AjaxThirdkids";201import AjaxThirdShort from "./Leauges/OtherClub-Pages/AjaxThirdShort";202import AjaxAwayShort from "./Leauges/OtherClub-Pages/AjaxAwayShort";203import AjaxHomeShort from "./Leauges/OtherClub-Pages/AjaxHomeShort";204import AjaxHomeShirt from "./Leauges/OtherClub-Pages/AjaxHomeShirt";205import BenficaThirdShirt from "./Leauges/OtherClub-Pages/BenficaThirdShirt";206import BenficaAwayShirt from "./Leauges/OtherClub-Pages/BenficaAwayShirt";207import BenficaHomeShirt from "./Leauges/OtherClub-Pages/BenficaHomeShirt";208import BenficaAwayShort from "./Leauges/OtherClub-Pages/BenficaAwayShort";209import BenficaHomeShort from "./Leauges/OtherClub-Pages/BenficaHomeShort";210function App() {211 return (212 <>213 <Router>214 <ScrollTop />215 <Navbar />216 <Routes>217 <Route path="/footballshirt" element={<Banner />} />218 <Route path="/liverpool-sales" element={<LiverpoolSales />} />219 <Route path="/mancity-sales" element={<ManCitySales />} />220 <Route path="/manunited-sales" element={<ManUnitedSales />} />221 <Route path="/arsenal-sales" element={<ArsenalSales />} />222 {/* SHIRTS */}223 <Route224 path="/ajax-tshirt-21/22-third"225 element={<AjaxTshirtThird />}226 />227 <Route228 path="psg/lionel_messi-21/22-away"229 element={<LionelTshirtAway />}230 />231 <Route232 path="psg/lionel_messi-21/22-home"233 element={<LionelTshirtHome />}234 />235 <Route236 path="barcelona-tshirt-21/22-away"237 element={<BarcelonaTshirtAway />}238 />239 <Route240 path="manunited-tshirt-21/22-home"241 element={<ManUnitedTshirtHome />}242 />243 <Route244 path="intermilan-tshirt-21/22-home"245 element={<InterMilanTshirtHome />}246 />247 <Route248 path="bayern-munich-tshirt-21/22-away"249 element={<BayernMunichTshirtAway />}250 />251 <Route path="psg-tshirt-21/22-home" element={<PsgTshirtHome />} />252 <Route253 path="chelsea-tshirt-21/22-home"254 element={<ChelseaTshirtHome />}255 />256 <Route257 path="tottenham-tshirt-21/22-away"258 element={<TottenhamTshirtAway />}259 />260 <Route path="/national-team" element={<NationalTeam />} />261 <Route path="/premier-leauge" element={<PremierLeauge />} />262 <Route path="/bundesliga" element={<BundesLiga />} />263 <Route path="/laliga-leauge" element={<LaLiga />} />264 <Route path="/ligue-one" element={<LeaugeOne />} />265 <Route path="/other-clubs" element={<OtherClub />} />266 {/* NATIONAL TEAM */}267 <Route path="/mexico-tshirt-21/22-home" element={<MexicoShirt />} />268 <Route path="/brazil-tshirt-21/22-home" element={<BrazilHome />} />269 <Route path="/brazil-tshirt-21/22-away" element={<BrazilAway />} />270 <Route271 path="/colombia-tshirt-21/22-home"272 element={<ColombiaAway />}273 />274 <Route275 path="/argentina-tshirt-21/22-away"276 element={<ArgentinaAway />}277 />278 <Route279 path="/argentina-tshirt-21/22-home"280 element={<ArgentinaHome />}281 />282 <Route283 path="/germany-toni-kross-tshirt-20/21-home"284 element={<KroosHome />}285 />286 <Route287 path="/germany-toni-kross-tshirt-20/21-away"288 element={<KroosAway />}289 />290 <Route291 path="/portugal-ronaldo-tshirt-20/21-home"292 element={<RonaldoHome />}293 />294 <Route295 path="/portugal-ronaldo-tshirt-20/21-away"296 element={<RonaldoAway />}297 />298 <Route299 path="/netherland-depay-tshirt-20/21-home"300 element={<DepayHome />}301 />302 <Route303 path="/netherland-depay-tshirt-20/21-away"304 element={<DepayAway />}305 />306 <Route307 path="/netherland-deJong-tshirt-20/21-home"308 element={<DeJongHome />}309 />310 <Route311 path="/netherland-deJong-tshirt-20/21-away"312 element={<DeJongAway />}313 />314 <Route315 path="/france-mbappe-tshirt-20/21-home"316 element={<MbappeHome />}317 />318 <Route319 path="/france-mbappe-tshirt-20/21-away"320 element={<MbappeAway />}321 />322 <Route323 path="/france-griezmann-tshirt-20/21-home"324 element={<GriezmannHome />}325 />326 <Route327 path="/france-griezmann-tshirt-20/21-away"328 element={<GriezmannAway />}329 />330 <Route331 path="/france-pogba-tshirt-20/21-home"332 element={<PogbaHome />}333 />334 <Route335 path="/croatia-modric-tshirt-20/21-home"336 element={<ModricHome />}337 />338 <Route339 path="/belgium-debruyne-tshirt-20/21-home"340 element={<DeBruyneHome />}341 />342 <Route343 path="/belgium-debruyne-tshirt-20/21-away"344 element={<DeBruyneAway />}345 />346 <Route347 path="/england-harry-kane-tshirt-20/21-home"348 element={<HarryKaneHome />}349 />350 <Route351 path="/england-harry-kane-tshirt-20/21-away"352 element={<HarryKaneAway />}353 />354 <Route path="/italy-tshirt-20/21-home" element={<ItalyHome />} />355 <Route path="/italy-tshirt-21/22-away" element={<ItalyAway />} />356 <Route path="/sweden-tshirt-20/21-home" element={<SwedenHome />} />357 <Route path="/sweden-tshirt-20/21-away" element={<SwedenAway />} />358 <Route path="/poland-tshirt-20/21-home" element={<PolandHome />} />359 <Route360 path="/portugal-tshirt-20/21-home"361 element={<PortugalHome />}362 />363 <Route364 path="/portugal-tshirt-20/21-away"365 element={<PortugalAway />}366 />367 <Route path="/germany-tshirt-20/21-home" element={<GermanyHome />} />368 <Route path="/germany-tshirt-20/21-away" element={<GermanyAway />} />369 <Route370 path="/netherland-tshirt-20/21-home"371 element={<NetherlandHome />}372 />373 <Route374 path="netherland-tshirt-20/21-away"375 element={<NetherlandAway />}376 />377 <Route path="/spain-tshirt-20/21-home" element={<SpainHome />} />378 <Route path="/spain-tshirt-20/21-away" element={<SpainAway />} />379 <Route path="/france-tshirt-20/21-home" element={<FranceHome />} />380 <Route path="/france-tshirt-20/21-away" element={<FranceAway />} />381 <Route path="/croatia-tshirt-20/21-home" element={<CroatiaHome />} />382 <Route path="croatia-tshirt-20/21-away" element={<CroatiaAway />} />383 <Route path="/belgium-tshirt-20/21-home" element={<BelgiumHome />} />384 <Route path="/belgium-tshirt-20/21-away" element={<BelgiumAway />} />385 <Route path="/england-tshirt-20/21-home" element={<EnglandHome />} />386 <Route path="/england-tshirt-20/21-away" element={<EnglandAway />} />387 {/* PREMIER LEAUGE */}388 <Route389 path="/arsenal-tshirt-21/22-away"390 element={<ArsenalAwayShirt />}391 />392 <Route393 path="/arsenal-kids-tshirt-21/22-away"394 element={<ArsenalAwayKids />}395 />396 <Route397 path="/chealse-women-tshirt-21/22-home"398 element={<ChelseaHomeWomen />}399 />400 <Route401 path="/chealse-home-tshirt-21/22-home"402 element={<ChelseaHomeShirt />}403 />404 <Route405 path="/chealse-home-kids-tshirt-21/22-home"406 element={<ChelseaHomeKids />}407 />408 <Route409 path="/liverpool-home-women-tshirt-21/22-home"410 element={<LiverpoolHomeWomen />}411 />412 <Route413 path="/liverpool-home-kids-tshirt-21/22-home"414 element={<LiverpoolHomeKids />}415 />416 <Route417 path="/liverpool-home-tshirt-21/22-home"418 element={<LiverpoolHomeShirt />}419 />420 <Route421 path="/arsenal-third-tshirt-long-sleeve-21/22-home"422 element={<ArsenalThirdLong />}423 />424 <Route425 path="/arsenal-third-tshirt-21/22"426 element={<ArsenalThirdShirt />}427 />428 <Route429 path="/arsenal-third-football-short-21/22"430 element={<ArsenalThirdShort />}431 />432 <Route433 path="/arsenal-away-football-shirt-long-21/22"434 element={<ArsenalAwayLong />}435 />436 <Route437 path="/arsenal-away-football-short-21/22"438 element={<ArsenalAwayShort />}439 />440 <Route441 path="/arsenal-home-football-short-21/22"442 element={<ArsenalHomeLong />}443 />444 <Route445 path="/arsenal-home-tshirt-21/22"446 element={<ArsenalHomeShirt />}447 />448 <Route449 path="/arsenal-home-women-tshirt-21/22"450 element={<ArsenalHomeWomen />}451 />452 <Route453 path="/arsenal-football-home-short-21/22"454 element={<ArsenalHomeShort />}455 />456 <Route457 path="/tottenham-home-tshirt-21/22"458 element={<TottenhamHomeShirt />}459 />460 <Route461 path="/chelsea-third-tshirt-21/22"462 element={<ChelseaThirdShirt />}463 />464 <Route465 path="/chelsea-third-kids-tshirt-21/22"466 element={<ChelseaThirdKids />}467 />468 <Route469 path="/chelsea-third-tshorts-21/22"470 element={<ChelseaThirdShort />}471 />472 <Route473 path="/chelsea-away-tshirt-21/22"474 element={<ChelseaAwayShirt />}475 />476 <Route477 path="/chelsea-away-kids-tshirt-21/22"478 element={<ChelseaAwayKids />}479 />480 <Route481 path="/chelsea-away-shorts-21/22"482 element={<ChelseaAwayShort />}483 />484 <Route485 path="/chelsea-home-shorts-21/22"486 element={<ChelseaHomeShort />}487 />488 <Route489 path="/liverpool-third-tshirt-21/22"490 element={<LiverpoolThirdShirt />}491 />492 <Route493 path="/liverpool-third-women-tshirt-21/22"494 element={<LiverpoolThirdWomen />}495 />496 <Route497 path="/liverpool-third-kids-tshirt-21/22"498 element={<LiverpoolThirdKids />}499 />500 <Route501 path="/liverpool-third-shorts-21/22"502 element={<LiverpoolThirdShorts />}503 />504 <Route505 path="/liverpool-home-shorts-21/22"506 element={<LiverpoolHomeShorts />}507 />508 <Route509 path="/liverpool-away-shorts-21/22"510 element={<LiverpoolAwayShorts />}511 />512 <Route513 path="/liverpool-away-tshirt-21/22"514 element={<LiverpoolAwayShirt />}515 />516 <Route517 path="/liverpool-away-kids-tshirt-21/22"518 element={<LiverpoolAwayKids />}519 />520 <Route521 path="/manunited-third-tshirt-long-sleeve-21/22-home"522 element={<ManUnitedThirdLong />}523 />524 <Route525 path="/manunited-away-tshirt-long-sleeve-21/22-home"526 element={<ManUnitedAwayLong />}527 />528 <Route529 path="/manunited-third-tshirt-21/22"530 element={<ManUnitedThirdShirt />}531 />532 <Route533 path="/manunited-third-shorts-21/22"534 element={<ManUnitedThirdShorts />}535 />536 <Route537 path="/manunited-away-tshirts-21/22"538 element={<ManUnitedAwayShirt />}539 />540 <Route541 path="/manunited-away-shorts-21/22"542 element={<ManUnitedAwayShorts />}543 />544 <Route545 path="/manunited-home-shorts-21/22"546 element={<ManUnitedHomeShorts />}547 />548 <Route549 path="/manunited-third-long-sleeve-21/22-home"550 element={<ManUnitedHomeLong />}551 />552 <Route553 path="/manunited-third-tshirt-21/22-home"554 element={<ManUnitedHomeShirt />}555 />556 <Route557 path="/mancity-third-tshirt-home-21/22"558 element={<ManCityThirdShirt />}559 />560 <Route561 path="/mancity-third-shorts-21/22"562 element={<ManCityThirdShorts />}563 />564 <Route565 path="/mancity-away-shorts-21/22"566 element={<ManCityAwayShorts />}567 />568 <Route569 path="/mancity-away-tshirt-21/22"570 element={<ManCityAwayShirt />}571 />572 <Route573 path="/mancity-home-shorts-21/22"574 element={<ManCityHomeShorts />}575 />576 <Route577 path="/mancity-home-tshirt-21/22"578 element={<ManCityHomeShirt />}579 />580 <Route581 path="/tottenham-third-tshirt-21/22"582 element={<TottenhamThirdShirt />}583 />584 <Route585 path="/tottenham-third-shorts-21/22"586 element={<TottenhamThirdShort />}587 />588 <Route589 path="/tottenham-away-tshirt-21/22"590 element={<TottenhamAwayShirt />}591 />592 <Route593 path="/tottenham-away-shorts-21/22"594 element={<TottenhamAwayShort />}595 />596 <Route597 path="/tottenham-home-shorts-21/22"598 element={<TottenhamHomeShort />}599 />600 <Route601 path="/westham-third-tshirt-21/22"602 element={<WesthamThirdShirt />}603 />604 <Route605 path="/westham-away-tshirt-21/22"606 element={<WesthamAwayShirt />}607 />608 <Route609 path="/westham-away-shorts-21/22"610 element={<WesthamAwayShorts />}611 />612 <Route613 path="/westham-home-tshirt-21/22"614 element={<WesthamHomeShirt />}615 />616 <Route617 path="/westham-home-shorts-21/22"618 element={<WesthamHomeShorts />}619 />620 <Route621 path="/bayern-munich-kids-tshirt-21/22-away"622 element={<BayernAwayKids />}623 />624 <Route625 path="/borussia-dortmund-tshirt-21/22-home"626 element={<DortmundHomeShirt />}627 />628 <Route629 path="/leipzig-tshirt-21/22-home"630 element={<LeipzigHomeShirt />}631 />632 <Route633 path="/bayern-munich-tshirt-21/22-third"634 element={<BayernThirdShirt />}635 />636 <Route637 path="/bayern-munich-shorts-21/22-third"638 element={<BayernThirdShort />}639 />640 <Route641 path="/bayern-munich-tshirt-21/22-home"642 element={<BayernHomeShirt />}643 />644 <Route645 path="/bayern-munich-tshirt-long-sleeve-21/22-home"646 element={<BayernHomeLong />}647 />648 <Route649 path="/bayern-munich-women-tshirt-21/22-home"650 element={<BayernHomeWomen />}651 />652 <Route653 path="/bayern-munich-shorts-21/22-home"654 element={<BayernHomeShort />}655 />656 <Route657 path="/bayern-munich-shorts-21/22-away"658 element={<BayernAwayShort />}659 />660 <Route661 path="/borussia-dortmund-tshirt-21/22-third"662 element={<DortmundThirdShirt />}663 />664 <Route665 path="/borussia-dortmund-kids-tshirt-21/22-third"666 element={<DortmundThirdKids />}667 />668 <Route669 path="/borussia-dortmund-shorts-21/22-third"670 element={<DortmundThirdShort />}671 />672 <Route673 path="/borussia-dortmund-tshirt-21/22-away"674 element={<DortmundAwayShirt />}675 />676 <Route677 path="/borussia-dortmund-shorts-21/22-away"678 element={<DortmundAwayShort />}679 />680 <Route681 path="/borussia-dortmund-shorts-21/22-home"682 element={<DortmundHomeShort />}683 />684 <Route685 path="/leipzig-tshirt-21/22-third"686 element={<LeipzigThirdShirt />}687 />688 <Route689 path="/leipzig-tshirt-21/22-away"690 element={<LeipzigAwayShirt />}691 />692 <Route693 path="/real-madrid-long-sleeve-tshirt-21/22-home"694 element={<RealMadridHomeLong />}695 />696 <Route697 path="/real-madrid-tshirt-21/22-home"698 element={<RealMadridHome />}699 />700 <Route701 path="/real-madrid-kids-tshirt-21/22-home"702 element={<RealMadridHomeKids />}703 />704 <Route705 path="/atletico-madrid-tshirt-21/22-third"706 element={<AtleticoMadridThirdShirt />}707 />708 <Route709 path="/atletico-madrid-tshirt-21/22-away"710 element={<AtleticoMadridAwayShirt />}711 />712 <Route713 path="/atletico-madrid-shorts-21/22-away"714 element={<AtleticoMadridAwayShorts />}715 />716 <Route717 path="/atletico-madrid-tshirt-21/22-home"718 element={<AtleticoMadridHomeShirt />}719 />720 <Route721 path="/atletico-madrid-shorts-21/22-home"722 element={<AtleticoMadridHomeShorts />}723 />724 <Route725 path="/barcelona-shorts-21/22-third"726 element={<BarcelonaThirdShorts />}727 />728 <Route729 path="/barcelona-tshirt-21/22-third"730 element={<BarcelonaThirdShirt />}731 />732 <Route733 path="/barcelona-kids-tshirt-21/22-away"734 element={<BarcelonaAwayKids />}735 />736 <Route737 path="/barcelona-shorts-21/22-away"738 element={<BarcelonaAwayShorts />}739 />740 <Route741 path="/barcelona-shorts-21/22-home"742 element={<BarcelonaHomeShorts />}743 />744 <Route745 path="/barcelona-tshirt-21/22-home"746 element={<BarcelonaHomeShirt />}747 />748 <Route749 path="/real-madrid-tshirt-21/22-third"750 element={<RealMadridThirdShirt />}751 />752 <Route753 path="/real-madrid-shorts-21/22-third"754 element={<RealMadridThirdShorts />}755 />756 <Route757 path="/real-madrid-tshirt-21/22-away"758 element={<RealMadridAwayShirt />}759 />760 <Route761 path="/real-madrid-long-sleeve-tshirt-21/22-away"762 element={<RealMadridAwayLong />}763 />764 <Route765 path="/real-madrid-shorts-21/22-away"766 element={<RealMadridAwayShorts />}767 />768 <Route769 path="/real-madrid-shorts-21/22-home"770 element={<RealMadridHomeShorts />}771 />772 <Route773 path="/psg-tshirt-women-21/22-home"774 element={<PsgHomeWomen />}775 />776 <Route path="/psg-tshirt-kids-21/22-home" element={<PsgHomeKids />} />777 <Route778 path="/psg-tshirt-kids-21/22-third"779 element={<PsgThirdKids />}780 />781 <Route path="/psg-tshirt-21/22-third" element={<PsgThirdShirt />} />782 <Route path="/psg-tshirt-21/22-away" element={<PsgAwayShirt />} />783 <Route path="/psg-shorts-21/22-third" element={<PsgThirdShort />} />784 <Route path="/psg-shorts-21/22-away" element={<PsgAwayShort />} />785 <Route path="/psg-shorts-21/22-home" element={<PsgHomeShort />} />786 <Route path="/ajax-tshirt-21/22-away" element={<AjaxAwayShirt />} />787 <Route788 path="/celtic-tshirt-21/22-away"789 element={<CelticAwayShirt />}790 />791 <Route792 path="/celtic-tshirt-21/22-home"793 element={<CelticHomeShirt />}794 />795 <Route796 path="/porto-tshirt-21/22-third"797 element={<PortoThirdShirt />}798 />799 <Route path="/porto-tshirt-21/22-away" element={<PortoAwayShirt />} />800 <Route path="/porto-tshirt-21/22-home" element={<PortoHomeShirt />} />801 <Route802 path="/ajax-tshirt-kids-21/22-third"803 element={<AjaxThirdKids />}804 />805 <Route path="/ajax-shorts-21/22-third" element={<AjaxThirdShort />} />806 <Route path="/ajax-shorts-21/22-away" element={<AjaxAwayShort />} />807 <Route path="/ajax-shorts-21/22-home" element={<AjaxHomeShort />} />808 <Route path="/ajax-tshirt-21/22-home" element={<AjaxHomeShirt />} />809 <Route810 path="/benfica-tshirt-21/22-third"811 element={<BenficaThirdShirt />}812 />813 <Route814 path="/benfica-tshirt-21/22-away"815 element={<BenficaAwayShirt />}816 />817 <Route818 path="/benfica-tshirt-21/22-home"819 element={<BenficaHomeShirt />}820 />821 <Route822 path="/benfica-shorts-21/22-away"823 element={<BenficaAwayShort />}824 />825 <Route826 path="/benfica-shorts-21/22-home"827 element={<BenficaHomeShort />}828 />829 {/* FOOTER */}830 <Route path="/about-us" element={<AboutUs />} />831 <Route path="/delivery-guarantee" element={<DeliveryGuarantee />} />832 <Route path="/privacy-policy" element={<PrivacyPolicy />} />833 <Route path="/terms-of-use" element={<TermsOfUse />} />834 <Route path="/size-chart" element={<SizeChart />} />835 <Route path="/faq-help" element={<FaqHelp />} />836 <Route path="/shipping-delivery" element={<Shipping />} />837 <Route path="/return-policy" element={<ReturnPolicy />} />838 <Route path="/payment-method" element={<PaymentMethod />} />839 <Route path="/login" element={<Login />} />840 <Route path="/create-account" element={<SignUp />} />841 <Route path="/my-account" element={<MyAccount />} />842 <Route path="/my-orders" element={<MyOrders />} />843 <Route path="/forgot-password" element={<ForgotPassword />} />844 </Routes>845 <Footer />846 </Router>847 </>848 );849}...

Full Screen

Full Screen

ZaHome.js

Source:ZaHome.js Github

copy

Full Screen

1/**2 * Created by IntelliJ IDEA.3 * User: mingzhang4 * Date: 8/29/115 * Time: 9:37 PM6 * To change this template use File | Settings | File Templates.7 */8ZaHome = function() {9 ZaItem.call(this,"ZaHome");10 this._init();11}12ZaItem.loadMethods["ZaHome"] = new Array();13ZaItem.initMethods["ZaHome"] = new Array();14ZaHome.postLoadDataFunction = new Array();15ZaHome.prototype = new ZaItem;16ZaHome.prototype.constructor = ZaHome;17ZaHome.A2_version= "version";18ZaHome.A2_account = "account";19ZaHome.A2_serverNum = "serverNum";20ZaHome.A2_accountNum = "accountNum";21ZaHome.A2_cosNum = "cosNum";22ZaHome.A2_domainNum = "domainNum";23ZaHome.A2_lastCleanup = "lastCleanup";24ZaHome.A2_lastCleanupTime = "lastCleanupTime";25ZaHome.A2_lastLogPurge = "lastLogPurge";26ZaHome.A2_lastLogPurgeTime = "lastLogPurgeTime";27ZaHome.A2_DBCheckType = "dbCheckType";28ZaHome.A2_DBCheckMessage= "dbCheckMessage";29ZaHome.A2_serviceStatus = "serviceStatus";30ZaHome.A2_serviceStatusMessage = "serviceStatusMessage";31ZaHome.A2_serviceDetailedMessage = "serviceDetailedMessage";32ZaHome.A2_activeSession = "activeSession";33ZaHome.A2_queueLength = "queueLength";34ZaHome.A2_messageCount = "messageCount";35ZaHome.A2_messageVolume = "messageVolume";36ZaHome.A2_showWarningPanel = "showWarningPanel";37ZaHome.A2_maintenanceItemNum = "maintenanceItemNum";38ZaHome.initMethod = function () {39 this.attrs = new Object();40 this.type = ZaItem.HOME;41}42ZaItem.initMethods["ZaHome"].push(ZaHome.initMethod);43// Fake here no soap request, just collect all kinds of information everywhere44ZaHome.loadMethod =45function () {46 var now = new Date();47 var formatter = AjxDateFormat.getDateInstance(AjxDateFormat.LONG);48 var currentTime = formatter.format(now);49 this.attrs[ZaHome.A2_account] = ZaZimbraAdmin.currentAdminAccount.attrs.mail;50 this.attrs[ZaHome.A2_version] = ZaServerVersionInfo.version;51 this.attrs[ZaHome.A2_accountNum] = ZaMsg.MSG_HomeLoading;52 this.attrs[ZaHome.A2_cosNum] = ZaMsg.MSG_HomeLoading;53 this.attrs[ZaHome.A2_domainNum] = ZaMsg.MSG_HomeLoading;54 this.attrs[ZaHome.A2_serverNum] = ZaMsg.MSG_HomeLoading;55 this.attrs[ZaHome.A2_activeSession] = ZaMsg.MSG_HomeLoading;56 this.attrs[ZaHome.A2_lastCleanup] = true;57 this.attrs[ZaHome.A2_lastCleanupTime] = currentTime;58 this.attrs[ZaHome.A2_lastLogPurge] = true;59 this.attrs[ZaHome.A2_lastLogPurgeTime] = currentTime;60 this.attrs[ZaHome.A2_DBCheckType] = true;61 this.attrs[ZaHome.A2_DBCheckMessage] = ZaMsg.LBL_HomeStatusOK;62 this.attrs[ZaHome.A2_serviceStatusMessage] = ZaMsg.MSG_HomeLoading;63 this.attrs[ZaHome.A2_serviceDetailedMessage] = ZaMsg.MSG_HomeLoading;64 this.attrs[ZaHome.A2_queueLength] = ZaMsg.MSG_HomeLoading;65 this.attrs[ZaHome.A2_messageCount] = "120/h";66 this.attrs[ZaHome.A2_messageVolume] = "34MB/h";67 this.attrs[ZaHome.A2_showWarningPanel] = false;68 this.attrs[ZaHome.A2_maintenanceItemNum] = 1;69}70ZaItem.loadMethods["ZaHome"].push(ZaHome.loadMethod);71ZaHome.updateMaintenanceNum = function() {72 var num = 1;73 try {74 var homeCtl = ZaApp.getInstance().getHomeViewController();75 var maintainenceGroup = homeCtl._view._localXForm.getItemsById("maintenance_grp");76 num = maintainenceGroup[0].items.length;77 } catch (ex) {78 }79 ZaApp.getInstance().getHomeViewController().setInstanceValue(num, ZaHome.A2_maintenanceItemNum);80}81ZaHome.postLoadDataFunction.push(ZaHome.updateMaintenanceNum);82ZaHome.loadAccountNum = function() {83 var num = 1;84 try {85 num = ZaApp.getInstance().getAccountStats(true)[ZaItem.ACCOUNT];86 } catch (ex) {87 }88 ZaApp.getInstance().getHomeViewController().setInstanceValue(num, ZaHome.A2_accountNum);89}90ZaHome.postLoadDataFunction.push(ZaHome.loadAccountNum);91ZaHome.prototype.updateAccountNum = function(resp) {92 ZaApp.getInstance().getHomeViewController().setInstanceValue(num, ZaHome.A2_accountNum);93}94ZaHome.loadServerServerNum = function() {95 var soapDoc = AjxSoapDoc.create("GetAllServersRequest", ZaZimbraAdmin.URN, null);96 soapDoc.getMethod().setAttribute("applyConfig", "false");97// var command = new ZmCsfeCommand();98 var updateServerNum = new AjxCallback(this, this.updateServerNum);99 var params = new Object();100 params.soapDoc = soapDoc;101 params.asyncMode = true;102 params.callback = updateServerNum;103 var reqMgrParams = {104 controller : ZaApp.getInstance().getCurrentController(),105 busyMsg : ZaMsg.BUSY_GET_ALL_SERVER106 }107 var resp = ZaRequestMgr.invoke(params, reqMgrParams);108 return resp;109}110ZaHome.postLoadDataFunction.push(ZaHome.loadServerServerNum);111ZaHome.prototype.updateServerNum = function(resp) {112 var num = 1;113 try {114 var resp = resp.getResponse().Body.GetAllServersResponse;115 var list = new ZaItemList(ZaServer);116 list.loadFromJS(resp);117 num = list.size();118 } catch (ex) {119 }120 ZaApp.getInstance().getHomeViewController().setInstanceValue(num, ZaHome.A2_serverNum);121}122ZaHome.loadDomainNum = function() {123 var num = 1;124 try {125 num = ZaApp.getInstance().getDomainList(true).size();126 } catch (ex) {127 }128 ZaApp.getInstance().getHomeViewController().setInstanceValue(num, ZaHome.A2_domainNum);129}130ZaHome.postLoadDataFunction.push(ZaHome.loadDomainNum);131ZaHome.prototype.updateDomainNum = function(resp) {132 var num = 1;133 try {134 var resp = resp.getResponse().Body.GetAllServersResponse;135 var list = new ZaItemList(ZaDomain);136 list.loadFromJS(resp);137 num = list.size();138 } catch (ex) {139 }140 ZaApp.getInstance().getHomeViewController().setInstanceValue(num, ZaHome.A2_domainNum);141}142ZaHome.loadCosNum = function() {143 var num = 1144 try {145 num = ZaApp.getInstance().getCosList(true).size();146 } catch (ex) {147 }148 ZaApp.getInstance().getHomeViewController().setInstanceValue(num, ZaHome.A2_cosNum);149}150ZaHome.postLoadDataFunction.push(ZaHome.loadCosNum);151ZaHome.prototype.updateCosNum = function(resp) {152 var num = 1;153 ZaApp.getInstance().getHomeViewController().setInstanceValue(num, ZaHome.A2_cosNum);154}155ZaHome.loadStatusfo = function () {156 try {157 var logHost = ZaApp.getInstance().getGlobalConfig().attrs[ZaServer.A_zimbraLogHostname];158 //if zimbraLogHostname is set159 if (logHost) {160 var soapDoc = AjxSoapDoc.create("GetServiceStatusRequest", ZaZimbraAdmin.URN, null);161 var updateServiceStatus = new AjxCallback(this, this.updateServiceStatus);162 var command = new ZmCsfeCommand();163 var params = new Object();164 params.soapDoc = soapDoc;165 params.asyncMode = true;166 params.noAuthToken = true;167 params.callback = updateServiceStatus;168 command.invoke(params);169 } else {170 this.updateServiceStatus();171 }172 } catch (ex) {173 this.attrs[ZaHome.A2_serviceStatusMessage] = ZaMsg.LBL_HOmeStatusUnknown ;174 this.attrs[ZaHome.A2_serviceDetailedMessage] = ZaMsg.LBL_HomeDetailedServiceUnknown;175 }176}177ZaHome.postLoadDataFunction.push(ZaHome.loadStatusfo);178ZaHome.prototype.updateServiceStatus = function (resp) {179 var status = new ZaStatus();180 if (resp) {181 resp = resp.getResponse().Body.GetServiceStatusResponse;182 status.initFromJS(resp);183 }184 var serviceStatus;185 var serviceStatusMessage = ZaMsg.LBL_HOmeStatusUnknown;186 var serviceDetailedMessage = ZaMsg.LBL_HomeDetailedServiceUnknown;187 try {188 var statusVector = status.getStatusVector();189 var serverStatus;190 if (statusVector.size() > 0) {191 serviceStatus = true;192 serviceStatusMessage = ZaMsg.LBL_HomeStatusRunning ;193 for(var i = 0; i < statusVector.size(); i++) {194 serverStatus = statusVector.get(i);195 if (serverStatus.status != 1) {196 serviceStatus = false;197 serviceStatusMessage= ZaMsg.LBL_HomeStatusFailed;198 serviceDetailedMessage = ZaMsg.LBL_HomeDetailedServiceNotRunning;199 break;200 }201 }202 }203 } catch (ex) {204 }205 var viewController = ZaApp.getInstance().getHomeViewController();206 viewController.setInstanceValue(serviceStatus, ZaHome.A2_serviceStatus);207 viewController.setInstanceValue(serviceStatusMessage, ZaHome.A2_serviceStatusMessage);208 viewController.setInstanceValue(serviceDetailedMessage, ZaHome.A2_serviceDetailedMessage);209 if (serviceStatus != true && ZaHomeXFormView.showStatusInfo()) {210 viewController.showWarningPanel();211 }212}213ZaHome.loadActiveSesson = function () {214 var serverList = ZaApp.getInstance().getMailServers();215 var totalSession = 0;216 if(serverList && serverList.length) {217 var sessionType = ["soap", "admin", "imap"];218 var parameterList = []219 var cnt = serverList.length;220 for (var i = 0; i < cnt; i++) {221 for (var j = 0 ; j < sessionType.length; j ++) {222 parameterList.push (223 {224 targetServer: serverList[i].id,225 type: sessionType[j]226 }227 )228 }229 }230 var loadOneSessionNumer = function (resp) {231 if (!resp) {232 totalSession = 0;233 } else {234 if(resp && resp.getException && !resp.getException()) {235 resp = resp.getResponse();236 if (resp && resp.Body && resp.Body.GetSessionsResponse) {237 var sessionStats = resp.Body.GetSessionsResponse;238 totalSession += sessionStats.total;239 }240 }241 }242 if (parameterList.length > 0) {243 var currentSession = parameterList.shift();244 try {245 var server = ZaServer.getServerById(currentSession.targetServer);246 if(server) {247 if(ZaItem.hasRight(ZaServer.RIGHT_GET_SESSIONS, server)) {248 var soapDoc = AjxSoapDoc.create("GetSessionsRequest", ZaZimbraAdmin.URN, null);249 var sessionCallback = new AjxCallback (this, loadOneSessionNumer);250 var params = {};251 params.type = currentSession.type;252 soapDoc.getMethod().setAttribute("type", params.type);253 params.fresh = 1;254 soapDoc.getMethod().setAttribute("refresh", params.fresh);255 soapDoc.getMethod().setAttribute("limit", ZaServerSessionStatsPage.PAGE_LIMIT);256 params.offset = 0 ;257 soapDoc.getMethod().setAttribute("offset", params.offset);258 params.sortBy = "nameAsc";259 soapDoc.getMethod().setAttribute("sortBy", params.sortBy);260 var getSessCmd = new ZmCsfeCommand ();261 params.soapDoc = soapDoc ;262 params.asyncMode = true;263 params.noAuthToken = true;264 params.callback = sessionCallback;265 params.targetServer = currentSession.targetServer ;266 var resp = getSessCmd.invoke(params);267 }268 }269 } catch (ex) {270 // Won't do anything here to avoid disturbe the loading process.271 }272 } else {273 this.updateSessionNum(totalSession);274 }275 }276 loadOneSessionNumer.call(this);277 } else {278 this.updateSessionNum(totalSession);279 }280}281ZaHome.prototype.updateSessionNum = function(num) {282 ZaApp.getInstance().getHomeViewController().setInstanceValue(num, ZaHome.A2_activeSession);283}284ZaHome.postLoadDataFunction.push(ZaHome.loadActiveSesson);285ZaHome.loadQueueLength = function () {286 var mtaList = ZaApp.getInstance().getPostQList().getArray();287 var totalQueueLength = 0;288 if(mtaList && mtaList.length) {289 var parameterList = [];290 var cnt = mtaList.length;291 for (var i = 0; i < cnt; i++) {292 parameterList.push(mtaList[i].name);293 }294 var loadOneQueueLength = function (resp, isReset) {295 if (!resp && isReset) {296 totalQueueLength = 0;297 } else {298 if (resp && resp.getException) {299 if (!resp.getException()) {300 resp = resp.getResponse();301 var body = resp.Body;302 if(body && body.GetMailQueueInfoResponse.server && body.GetMailQueueInfoResponse.server[0]) {303 var queue = body.GetMailQueueInfoResponse.server[0].queue;304 for ( var j in queue) {305 if (queue[j].n) {306 totalQueueLength += parseInt(queue[j].n);307 }308 }309 }310 }311 }312 }313 if (parameterList.length > 0) {314 var currentName = parameterList.shift();315 var isEx = false;316 var queueLengthCallback = new AjxCallback(this, loadOneQueueLength);317 try {318 var soapDoc = AjxSoapDoc.create("GetMailQueueInfoRequest", ZaZimbraAdmin.URN, null);319 var attr = soapDoc.set("server", "");320 attr.setAttribute("name", currentName);321 var command = new ZmCsfeCommand();322 var params = new Object();323 params.soapDoc = soapDoc ;324 params.asyncMode = true;325 params.noAuthToken = true;326 params.callback = queueLengthCallback;327 command.invoke(params);328 } catch (ex) {329 queueLengthCallback.run();330 }331 } else {332 this.updateQueueLength(totalQueueLength);333 }334 }335 loadOneQueueLength.call(this, "", true);336 }337 else {338 this.updateQueueLength(totalQueueLength);339 }340}341ZaHome.postLoadDataFunction.push(ZaHome.loadQueueLength);342ZaHome.prototype.updateQueueLength = function(queueLength) {343 ZaApp.getInstance().getHomeViewController().setInstanceValue(queueLength, ZaHome.A2_queueLength);344}345ZaHome.prototype.schedulePostLoading = function () {346 // Don't disturbe the home view rendering process, when view is realy, start to update data.347 var act = new AjxTimedAction(this, ZaHome.prototype.startPostLoading);348 AjxTimedAction.scheduleAction(act, 100);349}350ZaHome.prototype.startPostLoading = function () {351 for (var i = 0; i < ZaHome.postLoadDataFunction.length; i++) {352 ZaHome.postLoadDataFunction[i].call(this);353 }354}355ZaHome.myXModel = {356 items: [357 {id:ZaHome.A2_version,type:_STRING_, ref:"attrs/" + ZaHome.A2_version},358 {id:ZaHome.A2_account,type:_STRING_, ref:"attrs/" + ZaHome.A2_account},359 {id:ZaHome.A2_domainNum,type:_STRING_, ref:"attrs/" + ZaHome.A2_domainNum},360 {id:ZaHome.A2_cosNum,type:_STRING_, ref:"attrs/" + ZaHome.A2_cosNum},361 {id:ZaHome.A2_serverNum,type:_STRING_, ref:"attrs/" + ZaHome.A2_serverNum},362 {id:ZaHome.A2_accountNum,type:_STRING_, ref:"attrs/" + ZaHome.A2_accountNum},363 {id:ZaHome.A2_lastCleanupTime, type:_STRING_, ref: "attrs/" + ZaHome.A2_lastCleanupTime},364 {id:ZaHome.A2_lastCleanup, type:_ENUM_, ref: "attrs/" + ZaHome.A2_lastCleanupTime, choices: ZaModel.BOOLEAN_CHOICES},365 {id:ZaHome.A2_lastLogPurgeTime, type:_STRING_, ref: "attrs/" + ZaHome.A2_lastLogPurgeTime},366 {id:ZaHome.A2_lastLogPurge, type:_ENUM_, ref: "attrs/" + ZaHome.A2_lastLogPurge, choices: ZaModel.BOOLEAN_CHOICES},367 {id:ZaHome.A2_DBCheckMessage, type:_STRING_, ref: "attrs/" + ZaHome.A2_DBCheckMessage},368 {id:ZaHome.A2_DBCheckType, type:_ENUM_, ref: "attrs/" + ZaHome.A2_DBCheckType, choices: ZaModel.BOOLEAN_CHOICES},369 {id:ZaHome.A2_serviceStatusMessage, type:_STRING_, ref: "attrs/" + ZaHome.A2_serviceStatusMessage},370 {id:ZaHome.A2_serviceDetailedMessage, type:_STRING_, ref: "attrs/" + ZaHome.A2_serviceDetailedMessage},371 {id:ZaHome.A2_serviceStatus, type:_ENUM_, ref: "attrs/" + ZaHome.A2_serviceStatus, choices: ZaModel.BOOLEAN_CHOICES},372 {id:ZaHome.A2_activeSession, type:_STRING_, ref:"attrs/" + ZaHome.A2_activeSession},373 {id:ZaHome.A2_queueLength, type:_STRING_, ref:"attrs/" + ZaHome.A2_queueLength},374 {id:ZaHome.A2_messageCount, type:_NUMBER_, ref:"attrs/" + ZaHome.A2_messageCount},375 {id:ZaHome.A2_messageVolume, type:_NUMBER_, ref:"attrs/" + ZaHome.A2_messageVolume},376 {id:ZaHome.A2_showWarningPanel, type:_ENUM_, ref:"attrs/" + ZaHome.A2_showWarningPanel, choices: ZaModel.BOOLEAN_CHOICES1},377 {id:ZaHome.A2_maintenanceItemNum, type:_NUMBER_, ref:"attrs/" + ZaHome.A2_maintenanceItemNum}378 ]...

Full Screen

Full Screen

home_data_mgmt.controller.js

Source:home_data_mgmt.controller.js Github

copy

Full Screen

1const db = require("../../models");2const DaftarHome = db.daftarHome;3const MediaHome = db.mediaHome;4const ErrorLogs = db.errorLogs;5const techControl = require("../technical.controller");6const Op = db.Sequelize.Op;7var kode_error;8//Tambah Home9exports.addHome = (req,res) => {10 DaftarHome.create(11 {12 name: req.body.name,13 search_key: req.body.name.toLowerCase().split(' ').join('-'),14 kategori: req.body.kategori,15 narasi: req.body.narasi,16 narasi_panjang: req.body.narasi_panjang,17 link_logo: req.body.link_logo,18 link_video: req.body.link_video,19 link_audio: req.body.link_audio,20 line: req.body.line,21 instagram: req.body.instagram22 }23 )24 .then(function(rowsUpdated) {25 res.status(200).send({ message: "Berhasil ditambah! "});26 })27 .catch(err => {28 kode_error = 110100;29 techControl.addErrorLog(kode_error, "Controller", "Home Data Management", "Add Home", err.message);30 res.status(500).send({ message: "Telah terjadi kesalahan. Silahkan mencoba lagi. Kode Error: " + kode_error });31 });32}33// Tambah Media34exports.addHomeMedia = (req,res) => {35 MediaHome.create(36 {37 home_id: req.body.home_id,38 link_media: req.body.link_media39 }40 )41 .then(function(rowsUpdated) {42 res.status(200).send({ message: "Berhasil ditambah! "});43 })44 .catch(err => {45 kode_error = 110200;46 techControl.addErrorLog(kode_error, "Controller", "Home Data Management", "Add Home Media", err.message);47 res.status(500).send({ message: "Telah terjadi kesalahan. Silahkan mencoba lagi. Kode Error: " + kode_error });48 });49}50//Get All Home51exports.getAllHome = (req,res) => {52 DaftarHome.findAll({53 attributes: ['home_id', 'search_key', 'name', 'kategori', 'narasi', 'narasi_panjang', 'link_logo', 'link_video', 'link_audio', 'line', 'instagram']54 })55 .then(function (response) {56 res.json(response);57 })58 .catch(err => {59 kode_error = 110300;60 techControl.addErrorLog(kode_error, "Controller", "Home Data Management", "Get All HOME", err.message);61 res.status(500).send({ message: "Telah terjadi kesalahan. Silahkan mencoba lagi. Kode Error: " + kode_error });62 });63}64//Get Home Details65exports.getHomeDetails = (req,res) => {66 DaftarHome.findAll({67 where: { home_id: req.body.home_id },68 attributes: ['home_id', 'search_key', 'name', 'kategori', 'narasi', 'narasi_panjang', 'link_logo', 'link_video', 'link_audio', 'line', 'instagram']69 })70 .then(function (response) {71 res.json(response);72 })73 .catch(err => {74 kode_error = 110400;75 techControl.addErrorLog(kode_error, "Controller", "Home Data Management", "Get HOME Details", err.message);76 res.status(500).send({ message: "Telah terjadi kesalahan. Silahkan mencoba lagi. Kode Error: " + kode_error });77 });78}79//Get Media Details for a HOME80exports.getMediaDetails = (req,res) => {81 MediaHome.findAll({82 where: { home_id: req.body.home_id },83 attributes: ['media_id', 'home_id', 'link_media']84 })85 .then(function(response) {86 res.json(response);87 })88 .catch(err => {89 kode_error = 110500;90 techControl.addErrorLog(kode_error, "Controller", "Home Data Management", "Get Media Details for a HOME", err.message);91 res.status(500).send({ message: "Telah terjadi kesalahan. Silahkan mencoba lagi. Kode Error: " + kode_error });92 });93}94//Update Home Details95exports.updateHomeDetails = (req,res) => {96 DaftarHome.update(97 {98 search_key : req.body.search_key,99 name: req.body.name,100 kategori: req.body.kategori,101 narasi: req.body.narasi,102 narasi_panjang: req.body.narasi_panjang,103 link_logo: req.body.link_logo,104 link_video: req.body.link_video,105 link_audio: req.body.link_audio,106 line: req.body.line,107 instagram: req.body.instagram108 },109 {110 where: { home_id: req.body.home_id }111 }112 )113 .then(function(rowsUpdated) {114 res.status(200).send({ message: "Berhasil diubah! "});115 })116 .catch(err => {117 kode_error = 110600;118 techControl.addErrorLog(kode_error, "Controller", "Home Data Management", "Update Home Details", err.message);119 res.status(500).send({ message: "Telah terjadi kesalahan. Silahkan mencoba lagi. Kode Error: " + kode_error });120 });121}122//Update Home Details123exports.updateHomeMedia = (req,res) => {124 MediaHome.update(125 {126 link_media: req.body.link_media127 },128 {129 where: { home_id: req.body.media_id, media_id: req.body.media_id }130 }131 )132 .then(function(rowsUpdated) {133 res.status(200).send({ message: "Berhasil diubah! "});134 })135 .catch(err => {136 kode_error = 110700;137 techControl.addErrorLog(kode_error, "Controller", "Home Data Management", "Update Media Details", err.message);138 res.status(500).send({ message: "Telah terjadi kesalahan. Silahkan mencoba lagi. Kode Error: " + kode_error });139 });140}141exports.deleteHome = (req,res) => {142 DaftarHome.destroy({143 where: { home_id: req.body.home_id }144 })145 .then(function(response) {146 MediaHome.destroy({147 where: { home_id: req.body.home_id }148 })149 .then(function(response) {150 res.status(200).send({ message: "Berhasil dihapus! "});151 })152 .catch(err => {153 kode_error = 110802;154 techControl.addErrorLog(kode_error, "Controller", "Home Data Management", "Delete Home", err.message);155 res.status(500).send({ message: "Telah terjadi kesalahan. Silahkan mencoba lagi. Kode Error: " + kode_error });156 });157 })158 .catch(err => {159 kode_error = 110801;160 techControl.addErrorLog(kode_error, "Controller", "Home Data Management", "Delete Home", err.message);161 res.status(500).send({ message: "Telah terjadi kesalahan. Silahkan mencoba lagi. Kode Error: " + kode_error });162 });163}164exports.deleteHomeMedia = (req,res) => {165 DaftarHome.destroy({166 where: { media_id: req.body.media_id }167 })168 .then(function(response) {169 res.status(200).send({ message: "Berhasil dihapus! "});170 })171 .catch(err => {172 kode_error = 110900;173 techControl.addErrorLog(kode_error, "Controller", "Home Data Management", "Delete Home Media", err.message);174 res.status(500).send({ message: "Telah terjadi kesalahan. Silahkan mencoba lagi. Kode Error: " + kode_error });175 });176}177exports.publicGetHomeByQuery = (req, res) => {178 DaftarHome.findAll({179 where: { search_key: req.query.ukm },180 attributes: ['home_id']181 })182 .then(function(response) {183 response = response[0];184 DaftarHome.findAll({185 where: { home_id: response['home_id'] },186 attributes: ['home_id', 'name', 'kategori', 'narasi', 'narasi_panjang', 'link_logo', 'link_video', 'link_audio', 'line', 'instagram'],187 include: [188 {189 model: MediaHome,190 where: { home_id: response['home_id'] },191 attributes: ['link_media']192 }193 ]194 })195 .then(function(response) {196 res.json(response);197 })198 .catch(err => {199 kode_error = 111002;200 //techControl.addErrorLog(kode_error, "Controller", "Home Data Management", "Public GET HOME BY QUERY 2", err.message);201 res.status(500).send({ message: "Telah terjadi kesalahan. Silahkan mencoba lagi. Kode Error: " + kode_error });202 })203 })204 .catch(err => {205 kode_error = 111001;206 //techControl.addErrorLog(kode_error, "Controller", "Home Data Management", "Public GET HOME BY QUERY 1", err.message);207 res.status(500).send({ message: "Telah terjadi kesalahan. Silahkan mencoba lagi. Kode Error: " + kode_error });208 })...

Full Screen

Full Screen

homes.jsx

Source:homes.jsx Github

copy

Full Screen

1import React from "react";2import "../css/main.css";3import Icon from "../css/Icomoon/icomoon-icons";4const Homes = () => {5 return (6 <div className="homes">7 {/* First Card */}8 <div className="home">9 <img10 src={require("../img/house-1.jpeg")}11 alt=""12 className="home__img"13 />14 <svg className="home__like">15 <Icon icon="heart" />16 </svg>17 <h5 className="home__name">Beautiful Family House</h5>18 <div className="home__location">19 <svg>20 <Icon icon="map" />21 </svg>22 <p>USA</p>23 </div>24 <div className="home__rooms">25 <svg>26 <Icon icon="bookmark" />27 </svg>28 <p>5 rooms</p>29 </div>30 <div className="home__area">31 <svg>32 <Icon icon="star" />33 </svg>34 <p>35 325 m<sup>2</sup>36 </p>37 </div>38 <div className="home__price">39 <svg>40 <Icon icon="home" />41 </svg>42 <p>$1,200,000</p>43 </div>44 <button className="btn home__btn">Contact Realtors</button>45 </div>46 {/* Second Card */}47 <div className="home">48 <img49 src={require("../img/house-2.jpeg")}50 alt=""51 className="home__img"52 />53 <svg className="home__like">54 <Icon icon="heart" />55 </svg>56 <h5 className="home__name">Modern Glass Villa</h5>57 <div className="home__location">58 <svg>59 <Icon icon="map" />60 </svg>61 <p>Canada</p>62 </div>63 <div className="home__rooms">64 <svg>65 <Icon icon="bookmark" />66 </svg>67 <p>6 rooms</p>68 </div>69 <div className="home__area">70 <svg>71 <Icon icon="star" />72 </svg>73 <p>74 450 m<sup>2</sup>75 </p>76 </div>77 <div className="home__price">78 <svg>79 <Icon icon="home" />80 </svg>81 <p>$2,500,000</p>82 </div>83 <button className="btn home__btn">Contact Realtors</button>84 </div>85 {/* Third Card */}86 <div className="home">87 <img88 src={require("../img/house-3.jpeg")}89 alt=""90 className="home__img"91 />92 <svg className="home__like">93 <Icon icon="heart" />94 </svg>95 <h5 className="home__name">Cozy Country House</h5>96 <div className="home__location">97 <svg>98 <Icon icon="map" />99 </svg>100 <p>UK</p>101 </div>102 <div className="home__rooms">103 <svg>104 <Icon icon="bookmark" />105 </svg>106 <p>6 rooms</p>107 </div>108 <div className="home__area">109 <svg>110 <Icon icon="star" />111 </svg>112 <p>113 300 m<sup>2</sup>114 </p>115 </div>116 <div className="home__price">117 <svg>118 <Icon icon="home" />119 </svg>120 <p>$1,000,000</p>121 </div>122 <button className="btn home__btn">Contact Realtors</button>123 </div>124 {/* Fourth Card */}125 <div className="home">126 <img127 src={require("../img/house-4.jpeg")}128 alt=""129 className="home__img"130 />131 <svg className="home__like">132 <Icon icon="heart" />133 </svg>134 <h5 className="home__name">Large Rustical Villa</h5>135 <div className="home__location">136 <svg>137 <Icon icon="map" />138 </svg>139 <p>Portugal</p>140 </div>141 <div className="home__rooms">142 <svg>143 <Icon icon="bookmark" />144 </svg>145 <p>10 rooms</p>146 </div>147 <div className="home__area">148 <svg>149 <Icon icon="star" />150 </svg>151 <p>152 500 m<sup>2</sup>153 </p>154 </div>155 <div className="home__price">156 <svg>157 <Icon icon="home" />158 </svg>159 <p>$3,900,000</p>160 </div>161 <button className="btn home__btn">Contact Realtors</button>162 </div>163 {/* Fifth Card */}164 <div className="home">165 <img166 src={require("../img/house-5.jpeg")}167 alt=""168 className="home__img"169 />170 <svg className="home__like">171 <Icon icon="heart" />172 </svg>173 <h5 className="home__name">Majestic Palace House</h5>174 <div className="home__location">175 <svg>176 <Icon icon="map" />177 </svg>178 <p>Germany</p>179 </div>180 <div className="home__rooms">181 <svg>182 <Icon icon="bookmark" />183 </svg>184 <p>9 rooms</p>185 </div>186 <div className="home__area">187 <svg>188 <Icon icon="star" />189 </svg>190 <p>191 12 m<sup>2</sup>192 </p>193 </div>194 <div className="home__price">195 <svg>196 <Icon icon="home" />197 </svg>198 <p>$2,700,000</p>199 </div>200 <button className="btn home__btn">Contact Realtors</button>201 </div>202 {/* Sixth Card */}203 <div className="home">204 <img205 src={require("../img/house-6.jpeg")}206 alt=""207 className="home__img"208 />209 <svg className="home__like">210 <Icon icon="heart" />211 </svg>212 <h5 className="home__name">Modern Family Apartment</h5>213 <div className="home__location">214 <svg>215 <Icon icon="map" />216 </svg>217 <p>Pakistan</p>218 </div>219 <div className="home__rooms">220 <svg>221 <Icon icon="bookmark" />222 </svg>223 <p>9 rooms</p>224 </div>225 <div className="home__area">226 <svg>227 <Icon icon="star" />228 </svg>229 <p>230 256 m<sup>2</sup>231 </p>232 </div>233 <div className="home__price">234 <svg>235 <Icon icon="home" />236 </svg>237 <p>$1,000,000</p>238 </div>239 <button className="btn home__btn">Contact Realtors</button>240 </div>241 </div>242 );243};...

Full Screen

Full Screen

asian_odds.js

Source:asian_odds.js Github

copy

Full Screen

1// pages/asian_odds/asian_odds.js2Page({3 /**4 * 页面的初始数据5 */6 data: {7 NumberOfSeconds: "17'",8 MatchScore: '0 - 1',9 main_club_name: '皇家马德里',10 guest_club_name: '巴塞罗那',11 navbar: ['亚赔', '欧赔', '大小', '战绩'],12 currentTab: 0,13 asian_odds_list: [14 {name:'ManbetX',15 main_first_home_odds:'0.80',16 draw_first_home_odds:'-0.25',17 guest_first_home_odds:'0.96',18 main_home_odds:'0.81',19 draw_home_odds:'0.25',20 guest_home_odds: '1.05'21 },22 {23 name: 'ManbetX5555555555555555',24 main_first_home_odds: '0.80',25 draw_first_home_odds: '-0.25',26 guest_first_home_odds: '0.96',27 main_home_odds: '0.81',28 draw_home_odds: '0.25',29 guest_home_odds: '1.05'30 },31 {32 name: 'ManbetX',33 main_first_home_odds: '0.80',34 draw_first_home_odds: '-0.25',35 guest_first_home_odds: '0.96',36 main_home_odds: '0.81',37 draw_home_odds: '0.25',38 guest_home_odds: '1.05'39 }40 ],41 performance_detail_list: [42 {43 date: '2018 05/30',44 matching: '英超',45 main_club: '皇家马德里555555',46 score: '2-1',47 guest_club: '巴塞罗那',48 result: '0.5/1 输'49 },50 {51 date: '2018 05/30',52 matching: '英超',53 main_club: '皇家马德里',54 score: '2-1',55 guest_club: '巴塞罗那iiiiiiiiiiiii',56 result: '0\n走'57 },58 {59 date: '2018 05/30',60 matching: '英超',61 main_club: '皇ma',62 score: '2-1',63 guest_club: '巴塞',64 result: '0.5/1 赢'65 }66 ],67 summary_data_item: ['最高值', '最低值', '平均值'],68 summary_data:[69 {70 main_first_home_odds: '4.4',71 draw_first_home_odds: '3.4',72 guest_first_home_odds: '1.8',73 main_home_odds:'41',74 draw_home_odds: '21',75 guest_home_odds: '1.87'76 },77 {78 main_first_home_odds: '4.4',79 draw_first_home_odds: '3.4',80 guest_first_home_odds: '1.8',81 main_home_odds: '41',82 draw_home_odds: '21',83 guest_home_odds: '1.87'84 },85 {86 main_first_home_odds: '4.4',87 draw_first_home_odds: '3.4',88 guest_first_home_odds: '1.8',89 main_home_odds: '41',90 draw_home_odds: '21',91 guest_home_odds: '1.87'92 }93 ],94 european_odds_list: [95 {96 company_name: 'BET3622222225',97 main_first_home_odds: '7',98 draw_first_home_odds: '4.8',99 guest_first_home_odds: '1.33',100 main_home_odds: '51',101 draw_home_odds: '51',102 guest_home_odds: '1.33'103 }104 ]105 },106 /**107 * 生命周期函数--监听页面加载108 */109 onLoad: function (options) {110 111 },112 /**113 * 生命周期函数--监听页面初次渲染完成114 */115 onReady: function () {116 117 },118 /**119 * 生命周期函数--监听页面显示120 */121 onShow: function () {122 123 },124 /**125 * 生命周期函数--监听页面隐藏126 */127 onHide: function () {128 129 },130 /**131 * 生命周期函数--监听页面卸载132 */133 onUnload: function () {134 135 },136 /**137 * 页面相关事件处理函数--监听用户下拉动作138 */139 onPullDownRefresh: function () {140 141 },142 /**143 * 页面上拉触底事件的处理函数144 */145 onReachBottom: function () {146 147 },148 /**149 * 用户点击右上角分享150 */151 onShareAppMessage: function () {152 153 },154 navbarTap: function (e) {155 this.setData({156 currentTab: e.currentTarget.dataset.idx157 })158 },159 asian_odds: function(e) {160 console.log(e)161 wx.navigateTo({162 url: '../asian_odds_change/asian_odds_change',163 })164 }...

Full Screen

Full Screen

funeralHomes.js

Source:funeralHomes.js Github

copy

Full Screen

...17 res.json(funeralHomes)18 }).select('-__v');19}20function create(req, res, next){21 var funeralHome = new FuneralHome(req.body);22 funeralHome.save(function(err, savedFuneralHome){23 if(err) next(err);24 res.json(savedFuneralHome)25 });26}27function show(req, res, next){28 var id = req.params.id;29 FuneralHome.findById(id, function(err, funeralHome){30 if(err) next(err);31 res.json(funeralHome);32 })33}34function getYelp(req, res) {35 var id = req.params.id...

Full Screen

Full Screen

content.home.controller.js

Source:content.home.controller.js Github

copy

Full Screen

1'use strict';2(function (angular, buildfire) {3 angular4 .module('googleAppsPresentationPluginContent')5 .controller('ContentHomeCtrl', ['TAG_NAMES', 'DataStore', '$timeout', 'Utils',6 function (TAG_NAMES, DataStore, $timeout, Utils) {7 var ContentHome = this;8 ContentHome.MODE_TYPE = {9 PREVIEW: 'preview',10 EDITABLE: 'editable'11 };12 ContentHome.mode = ContentHome.MODE_TYPE.PREVIEW;13 ContentHome.data = {14 content: {15 url: null,16 mode: ""17 }18 };19 ContentHome.isUrlValidated = null;20 ContentHome.pptUrl = null;21 /*Init method call, it will bring all the pre saved data*/22 ContentHome.init = function () {23 ContentHome.success = function (result) {24 console.info('init success result:', result);25 if (result.data && result.id) {26 ContentHome.data = result.data;27 if (!ContentHome.data.content)28 ContentHome.data.content = {};29 ContentHome.pptUrl = ContentHome.data.content.url;30 if (ContentHome.data.content.mode)31 ContentHome.mode = ContentHome.data.content.mode;32 } else {33 var dummyData = {url: "https://docs.google.com/presentation/d/1GajPA3eOHYT39vkDj_NX8v0FjiumnBgGtOyIHROyhd8/preview#slide=id.gc6fa3c898_0_0"};34 ContentHome.pptUrl = dummyData.url;35 ContentHome.mode = ContentHome.MODE_TYPE.PREVIEW;36 }37 };38 ContentHome.error = function (err) {39 console.error('Error while getting data', err);40 };41 DataStore.get(TAG_NAMES.GOOGLE_APPS_PRESENTATION_INFO).then(ContentHome.success, ContentHome.error);42 };43 ContentHome.init();44 ContentHome.validateUrl = function () {45 if(ContentHome.pptUrl.includes("https://drive.google.com/file/d")){46 var ppId=ContentHome.pptUrl.split("https://drive.google.com/file/d/")[1].split("/view?")[0];47 ContentHome.pptUrl="https://docs.google.com/presentation/d/"+ppId+"/preview";48 }49 if (Utils.validateUrl(ContentHome.pptUrl)) {50 ContentHome.data.content.url = ContentHome.pptUrl;51 ContentHome.data.content.mode = ContentHome.mode;52 ContentHome.isUrlValidated = true;53 ContentHome.saveData(JSON.parse(angular.toJson(ContentHome.data)), TAG_NAMES.GOOGLE_APPS_PRESENTATION_INFO);54 } else {55 ContentHome.isUrlValidated = false;56 }57 $timeout(function () {58 ContentHome.isUrlValidated = null;59 }, 3000);60 };61 ContentHome.saveData = function (newObj, tag) {62 if (typeof newObj === 'undefined') {63 return;64 }65 ContentHome.success = function (result) {66 console.info('Saved data result: ', result);67 // updateMasterItem(newObj);68 };69 ContentHome.error = function (err) {70 console.error('Error while saving data : ', err);71 };72 DataStore.save(newObj, tag).then(ContentHome.success, ContentHome.error);73 };74 /*75 * Method to clear JotForm feed url76 * */77 ContentHome.clearData = function () {78 if (!ContentHome.pptUrl) {79 ContentHome.data.content.url = null;80 ContentHome.saveData(ContentHome.data.content, TAG_NAMES.GOOGLE_APPS_PRESENTATION_INFO)81 }82 };83 ContentHome.gotToSite = function () {84 window.open('https://accounts.google.com', '_blank');85 };86 ContentHome.gotToSupport = function () {87 window.open('https://support.google.com/drive/answer/2494822?hl=en', '_blank');88 };89 ContentHome.changeMode = function (mode) {90 ContentHome.data.content.mode = mode;91 ContentHome.saveData(ContentHome.data, TAG_NAMES.GOOGLE_APPS_PRESENTATION_INFO);92 };93 }]);...

Full Screen

Full Screen

home.routes.js

Source:home.routes.js Github

copy

Full Screen

1const { authJwt } = require("../../middleware");2const homeController = require("../../controllers/home/home_data_mgmt.controller");3module.exports = function(app) {4 app.use(function(req, res, next) {5 res.header(6 "Access-Control-Allow-Headers",7 "x-access-token, Origin, Content-Type, Accept"8 );9 next();10 });11 //Admin12 app.post(13 "/api/admin/home/add_home",14 [authJwt.verifyToken, authJwt.isAdmin],15 homeController.addHome16 )17 app.post(18 "/api/admin/home/add_home_media",19 [authJwt.verifyToken, authJwt.isAdmin],20 homeController.addHomeMedia21 )22 app.get(23 "/api/admin/home/all_home",24 [authJwt.verifyToken, authJwt.isAdmin],25 homeController.getAllHome26 )27 app.post(28 "/api/admin/home/get_home_details",29 [authJwt.verifyToken, authJwt.isAdmin],30 homeController.getHomeDetails31 )32 33 app.post(34 "/api/admin/home/get_media_details",35 [authJwt.verifyToken, authJwt.isAdmin],36 homeController.getMediaDetails37 )38 app.post(39 "/api/admin/home/update_home",40 [authJwt.verifyToken, authJwt.isAdmin],41 homeController.updateHomeDetails42 )43 app.post(44 "/api/admin/home/update_home_media",45 [authJwt.verifyToken, authJwt.isAdmin],46 homeController.updateHomeMedia47 )48 app.post(49 "/api/admin/home/delete_home",50 [authJwt.verifyToken, authJwt.isAdmin],51 homeController.deleteHome52 )53 app.post(54 "/api/admin/home/delete_home_media",55 [authJwt.verifyToken, authJwt.isAdmin],56 homeController.deleteHomeMedia57 )58 59 //acara60 app.post(61 "/api/acara/home/add_home",62 [authJwt.verifyToken, authJwt.isAcara],63 homeController.addHome64 )65 app.post(66 "/api/acara/home/add_home_media",67 [authJwt.verifyToken, authJwt.isAcara],68 homeController.addHomeMedia69 )70 app.get(71 "/api/acara/home/all_home",72 [authJwt.verifyToken, authJwt.isAcara],73 homeController.getAllHome74 )75 app.post(76 "/api/acara/home/get_home_details",77 [authJwt.verifyToken, authJwt.isAcara],78 homeController.getHomeDetails79 )80 81 app.post(82 "/api/acara/home/get_media_details",83 [authJwt.verifyToken, authJwt.isAcara],84 homeController.getMediaDetails85 )86 app.post(87 "/api/acara/home/update_home",88 [authJwt.verifyToken, authJwt.isAcara],89 homeController.updateHomeDetails90 )91 app.post(92 "/api/acara/home/update_home_media",93 [authJwt.verifyToken, authJwt.isAcara],94 homeController.updateHomeMedia95 )96 app.post(97 "/api/acara/home/delete_home_media",98 [authJwt.verifyToken, authJwt.isAcara],99 homeController.deleteHomeMedia100 )101 102 //Public103 app.get(104 "/api/public/home/all_home",105 homeController.getAllHome106 )107 108 app.get(109 "/api/public/home/get_home_query",110 homeController.publicGetHomeByQuery111 )...

Full Screen

Full Screen

Using AI Code Generation

copy

Full Screen

1var argosy = require('argosy')2var argosyService = require('argosy-service')3var argosyPattern = require('argosy-pattern')4var home = argosyService({5 home: function (message, callback) {6 callback(null, {message: message})7 }8})9var client = argosy()10client.pipe(home).pipe(client)11client.accept({home: argosyPattern.match.any}).home('hello', function (err, result) {12 console.log(result)13})14### argosyService([options])15Default: `uuid.v4()`16### service.accept(pattern)17### service.pipe(stream)18### service.unpipe(stream)19### service.close()

Full Screen

Using AI Code Generation

copy

Full Screen

1var argosyService = require('argosy-service');2argosyService.home();3var argosyService = require('argosy-service');4argosyService.home();5var argosyService = require('argosy-service');6var argosyService = require('argosy-service');7argosyService.home();8var argosyService = require('argosy-service');9var argosyService = require('argosy-service');10argosyService.home();11var argosyService = require('argosy-service');12var argosyService = require('argosy-service');13argosyService.home();14var argosyService = require('argosy-service');

Full Screen

Using AI Code Generation

copy

Full Screen

1var argosy = require('argosy')2var service = require('argosy-service')3var argosyService = argosy()4argosyService.pipe(service({5 home: function (cb) {6 cb(null, 'Hello World')7 }8})).pipe(argosyService)9argosyService.accept({home: '*'})10var argosy = require('argosy')11var argosyService = argosy()12argosyService.pipe(argosyService)13argosyService.accept({home: '*'})14argosyService.home(function (err, data) {15 console.log(data)16})

Full Screen

Using AI Code Generation

copy

Full Screen

1var argosy = require('argosy')2var argosyPattern = require('argosy-pattern')3var home = require('./home')4var homeService = argosy()5homeService.use('home', home)6homeService.listen(8000)7var homeClient = argosy()8homeClient.use('home', argosyPattern({home: 'home'}))9homeClient.connect(8000)10homeClient.home.home('hello', function (err, response) {11 if (err) throw err12 console.log(response)13})14var argosy = require('argosy')15var argosyPattern = require('argosy-pattern')16var home = argosy()17home.accept({18})19home.process(function (msg, respond) {20 respond(null, 'Hello ' + msg.home)21})22var argosy = require('argosy')23var argosyPattern = require('argosy-pattern')24var home = require('./home')25var homeService = argosy()26homeService.use('home', home)27homeService.listen(8000)28var homeClient = argosy()29homeClient.use('home', argosyPattern({home: 'home'}))30homeClient.connect(8000)31homeClient.home.home('hello', function (err, response) {32 if (err) throw err33 console.log(response)34})35var argosy = require('argosy')36var argosyPattern = require('argosy-pattern')37var home = argosy()38home.accept({39})40home.process(function (msg, respond) {41 respond(null, 'Hello ' + msg.home)42})43var argosy = require('arg

Full Screen

Using AI Code Generation

copy

Full Screen

1var argosy = require('argosy')2var service = argosy()3service.accept({4 Home: function (message, cb) {5 cb(null, "Hello " + message)6 }7})8service.pipe(process.stdout)9service.pipe(service)10var argosy = require('argosy')11var service = argosy()12service.accept({13 Home: function (message, cb) {14 cb(null, "Hello " + message)15 }16})17service.pipe(process.stdout)18service.pipe(service)19var argosy = require('argosy')20var service = argosy()21service.accept({22 Home: function (message, cb) {23 cb(null, "Hello " + message)24 }25})26service.pipe(process.stdout)27service.pipe(service)28var argosy = require('argosy')29var service = argosy()30service.accept({31 Home: function (message, cb) {32 cb(null, "Hello " + message)33 }34})35service.pipe(process.stdout)36service.pipe(service)37var argosy = require('argosy')38var service = argosy()39service.accept({40 Home: function (message, cb) {41 cb(null, "Hello " + message)42 }43})44service.pipe(process.stdout)45service.pipe(service)46var argosy = require('argosy')47var service = argosy()48service.accept({49 Home: function (message, cb) {50 cb(null, "Hello " + message)51 }52})53service.pipe(process.stdout)54service.pipe(service)55var argosy = require('argosy')56var service = argosy()57service.accept({58 Home: function (message, cb) {59 cb(null, "Hello " + message)60 }61})62service.pipe(process.stdout)63service.pipe(service)

Full Screen

Using AI Code Generation

copy

Full Screen

1const service = require('argosy-service')2const home = require('argosy-service-home')3const http = require('http')4const argosy = require('argosy')5const services = argosy().use(home())6const server = http.createServer(services.accept)7server.listen(3000, () => {8 console.log('server listening on port 3000')9 client({10 }, (err, services) => {11 console.log(services)12 })13})14const service = require('argosy-service')15const home = require('argosy-service-home')16const http = require('http')17const argosy = require('argosy')18const services = argosy().use(home())19const server = http.createServer(services.accept)20server.listen(3000, () => {21 console.log('server listening on port 3000')22 client({23 }, (err, services) => {24 console.log(services)25 })26})

Full Screen

Using AI Code Generation

copy

Full Screen

1var argosyService = require('argosy-service')2var service = argosyService({3})4 .use(function (request, response, next) {5 response.end('Hello World')6 })7service.home()8### argosyService([options])9### service.use([path], middleware)10### service.home([options])

Full Screen

Using AI Code Generation

copy

Full Screen

1var argosy = require('argosy')2var service = argosy({3 greet: function greet (name, callback) {4 callback(null, 'hello ' + name)5 }6})7service.accept({8 greet: function greet (name, callback) {9 callback(null, 'hello ' + name)10 }11})12service.on('error', function (err) {13 console.error(err)14})15service.on('ready', function () {16 service.greet('world', function (err, message) {17 console.log(message)18 })19})20var argosy = require('argosy')21var service = argosy({22 greet: function greet (name, callback) {23 callback(null, 'hello ' + name)24 }25})26service.accept({27 greet: function greet (name, callback) {28 callback(null, 'hello ' + name)29 }30})31service.on('error', function (err) {32 console.error(err)33})34service.on('ready', function () {35 service.greet('world', function (err, message) {36 console.log(message)37 })38})39### `var service = argosy([options])`40* `options.log` - a [bunyan](

Full Screen

Automation Testing Tutorials

Learn to execute automation testing from scratch with LambdaTest Learning Hub. Right from setting up the prerequisites to run your first automation test, to following best practices and diving deeper into advanced test scenarios. LambdaTest Learning Hubs compile a list of step-by-step guides to help you be proficient with different test automation frameworks i.e. Selenium, Cypress, TestNG etc.

LambdaTest Learning Hubs:

YouTube

You could also refer to video tutorials over LambdaTest YouTube channel to get step by step demonstration from industry experts.

Run argos automation tests on LambdaTest cloud grid

Perform automation testing on 3000+ real desktop and mobile devices online.

Try LambdaTest Now !!

Get 100 minutes of automation test minutes FREE!!

Next-Gen App & Browser Testing Cloud

Was this article helpful?

Helpful

NotHelpful