diff --git a/.drone.yml b/.drone.yml index 36ede25f..1d0b3095 100644 --- a/.drone.yml +++ b/.drone.yml @@ -174,32 +174,34 @@ steps: depends_on: - make-lff -# - name: make-diwansport -# image: node:16-alpine -# environment: -# REACT_APP_STRIPE_PK: -# from_secret: REACT_APP_STRIPE_PK -# commands: -# - apk add --no-cache make -# - make diwansport-prod -# depends_on: -# - npm-install -# -# - name: deploy-diwansport -# image: amazon/aws-cli:latest -# environment: -# AWS_ACCESS_KEY_ID: -# from_secret: AWS_ACCESS_KEY_ID -# AWS_SECRET_ACCESS_KEY: -# from_secret: AWS_SECRET_ACCESS_KEY -# AWS_DEFAULT_REGION: -# from_secret: AWS_DEFAULT_REGION -# AWS_MAX_ATTEMPTS: 10 -# commands: -# - aws s3 sync build_insports-diwansport s3://insports-diwansport --delete -# - aws cloudfront create-invalidation --distribution-id E3LKAH6TR4O2JL --paths "/*" -# depends_on: -# - make-diwansport + # - name: make-diwansport + # image: node:16-alpine + # environment: + # REACT_APP_STRIPE_PK: + # from_secret: REACT_APP_STRIPE_PK + # commands: + # - apk add --no-cache make + # - make diwansport-prod + # depends_on: + # - npm-install + + # - name: deploy-diwansport + # image: amazon/aws-cli:latest + # environment: + # AWS_ACCESS_KEY_ID: + # from_secret: AWS_ACCESS_KEY_ID + # AWS_SECRET_ACCESS_KEY: + # from_secret: AWS_SECRET_ACCESS_KEY + # AWS_DEFAULT_REGION: + # from_secret: AWS_DEFAULT_REGION + # AWS_MAX_ATTEMPTS: 10 + # commands: + # - aws s3 sync build_insports-diwansport s3://insports-diwansport --delete + # - aws cloudfront create-invalidation --distribution-id E3LKAH6TR4O2JL --paths "/*" # # diwansport.net + # - aws cloudfront create-invalidation --distribution-id E3NJ2G0QSB6MVI --paths "/*" # tunisia.insports.tv + + # depends_on: + # - make-diwansport --- kind: pipeline diff --git a/Makefile b/Makefile index bd0669a8..04944847 100644 --- a/Makefile +++ b/Makefile @@ -130,6 +130,12 @@ india-build: clean REACT_APP_CLIENT=india \ npm run build +tunisia-build: clean + REACT_APP_TYPE=ott \ + REACT_APP_ENV=staging \ + REACT_APP_CLIENT=tunisia \ + npm run build + lff-build: clean REACT_APP_TYPE=ott \ REACT_APP_ENV=staging \ @@ -180,7 +186,16 @@ lff-prod: BUILD_PATH=build_lff \ npm run build && cp -r .well-known build_lff -deploy-all: prod preprod facr-prod lff-prod +diwansport-prod: + rm -rf build_tunisia && \ + REACT_APP_TYPE=ott \ + REACT_APP_ENV=production \ + REACT_APP_STRIPE_PK=pk_live_51J5TEYEDSxVnTgDW5XxhC6ntKZKddXgKHq5HOCDmJTdfSKluMYCdLHOcUA3Miuy8HesxG1eS4c0dQRQpMsEHRrQL00USpu5xIq \ + REACT_APP_CLIENT=tunisia \ + BUILD_PATH=build_tunisia \ + npm run build && cp -r .well-known build_tunisia + +deploy-all: prod preprod facr-prod lff-prod diwansport-prod india-prod test: npm test diff --git a/public/clients/tunisia/favicon/android-chrome-192x192.png b/public/clients/tunisia/favicon/android-chrome-192x192.png new file mode 100644 index 00000000..57dcb8b3 Binary files /dev/null and b/public/clients/tunisia/favicon/android-chrome-192x192.png differ diff --git a/public/clients/tunisia/favicon/android-chrome-512x512.png b/public/clients/tunisia/favicon/android-chrome-512x512.png new file mode 100644 index 00000000..b51a27bf Binary files /dev/null and b/public/clients/tunisia/favicon/android-chrome-512x512.png differ diff --git a/public/clients/tunisia/favicon/apple-touch-icon.png b/public/clients/tunisia/favicon/apple-touch-icon.png new file mode 100644 index 00000000..9a2afe13 Binary files /dev/null and b/public/clients/tunisia/favicon/apple-touch-icon.png differ diff --git a/public/clients/tunisia/favicon/browserconfig.xml b/public/clients/tunisia/favicon/browserconfig.xml new file mode 100644 index 00000000..e12076d5 --- /dev/null +++ b/public/clients/tunisia/favicon/browserconfig.xml @@ -0,0 +1,12 @@ + + + + + + + + + #da532c + + + diff --git a/public/clients/tunisia/favicon/favicon-16x16.png b/public/clients/tunisia/favicon/favicon-16x16.png new file mode 100644 index 00000000..810f07b8 Binary files /dev/null and b/public/clients/tunisia/favicon/favicon-16x16.png differ diff --git a/public/clients/tunisia/favicon/favicon-32x32.png b/public/clients/tunisia/favicon/favicon-32x32.png new file mode 100644 index 00000000..fcd3fd20 Binary files /dev/null and b/public/clients/tunisia/favicon/favicon-32x32.png differ diff --git a/public/clients/tunisia/favicon/favicon.ico b/public/clients/tunisia/favicon/favicon.ico new file mode 100644 index 00000000..9bcb0fcf Binary files /dev/null and b/public/clients/tunisia/favicon/favicon.ico differ diff --git a/public/clients/tunisia/favicon/manifest.json b/public/clients/tunisia/favicon/manifest.json new file mode 100644 index 00000000..52b6bb11 --- /dev/null +++ b/public/clients/tunisia/favicon/manifest.json @@ -0,0 +1,19 @@ +{ + "name": "", + "short_name": "", + "icons": [ + { + "src": "/android-chrome-192x192.png", + "sizes": "192x192", + "type": "image/png" + }, + { + "src": "/android-chrome-512x512.png", + "sizes": "512x512", + "type": "image/png" + } + ], + "theme_color": "#ffffff", + "background_color": "#ffffff", + "display": "standalone" +} \ No newline at end of file diff --git a/public/clients/tunisia/favicon/mstile-144x144.png b/public/clients/tunisia/favicon/mstile-144x144.png new file mode 100644 index 00000000..0dc359d1 Binary files /dev/null and b/public/clients/tunisia/favicon/mstile-144x144.png differ diff --git a/public/clients/tunisia/favicon/mstile-150x150.png b/public/clients/tunisia/favicon/mstile-150x150.png new file mode 100644 index 00000000..d9d37c4d Binary files /dev/null and b/public/clients/tunisia/favicon/mstile-150x150.png differ diff --git a/public/clients/tunisia/favicon/mstile-310x310.png b/public/clients/tunisia/favicon/mstile-310x310.png new file mode 100644 index 00000000..f8679d56 Binary files /dev/null and b/public/clients/tunisia/favicon/mstile-310x310.png differ diff --git a/public/clients/tunisia/favicon/mstile-70x70.png b/public/clients/tunisia/favicon/mstile-70x70.png new file mode 100644 index 00000000..a9225441 Binary files /dev/null and b/public/clients/tunisia/favicon/mstile-70x70.png differ diff --git a/public/clients/tunisia/favicon/safari-pinned-tab.svg b/public/clients/tunisia/favicon/safari-pinned-tab.svg new file mode 100644 index 00000000..0ed4ea4e --- /dev/null +++ b/public/clients/tunisia/favicon/safari-pinned-tab.svg @@ -0,0 +1,18 @@ + + + + +Created by potrace 1.14, written by Peter Selinger 2001-2017 + + + + + \ No newline at end of file diff --git a/public/clients/tunisia/privacy-policy-and-statement.html b/public/clients/tunisia/privacy-policy-and-statement.html new file mode 100644 index 00000000..10395493 --- /dev/null +++ b/public/clients/tunisia/privacy-policy-and-statement.html @@ -0,0 +1,1550 @@ + + + + + + +
+

+
+
+
+

+ +

+ Privacy Policy and Statement +

+ +

+ In accordance with Data Protection and Privacy law +

+ +

+ inSports TV Limited as a data controller +

+ +

+ (inSports TV also referred to as "us", "we", "our" or "the company"; refers to InSport TV Limited) +

+ +

+ inSports TV is committed to the privacy of those that we engage with and + this statements details our approach. While using this site or + providing personal data to us in the course of business, we will + manage your data in accordance with this privacy statement. + +

+ + + +

+ inSports TV provides an online platform that allows to broadcast sports + video content. This is a legitimate interest pursued by inSports TV. + Personal data processed by the business is done so in accordance with + current Data Protection Regulation and GDPR. +

+

+ Personal Data and Collection +

+ +

+ We may obtain personal data including name, address, phone numbers, e-mail address, other electronic identifiers, title, images, IP address, company details, information about usage of inSports TV services (e.g., the types of content that you engage with), device information, transaction information including a credit card number and other authentication information (only when the transaction on our products is made) and other information provided by you or by other people when they use our products in accordance with this policy and with data protection law. We may also obtain similar information from other sources such as club, league or broadcast game footage, or from your use of inSports TV services, or when you sign up to our services, or attend events or otherwise engage with the business. +

+ +

+ Purpose of Use +

+ +

+ We use personal data for the purposes for which it was provided to us as + expressed at the point of collection or as is obvious in the context of collection. + Typically, information is collected for the following purposes: +

+ + + +

+ Your data may also be used in the course of system maintenance; + system logs, diagnosis of issues on company systems and the company + web site, or for site optimisation procedures. +

+ +

+ Broadcasting services for rightholders +

+ +

+ Where we process or arrange for processing of personal data on your + behalf for the purposes of delivering services, including but not + limited to the inSports sports events broadcasting services, we shall + implement appropriate technical and organisational measures in such a + manner that processing shall meet the requirements of data protection + regulation. The manifestly public nature of spots fixtures may bring + the reporting of sporting performance metrics outside of normal + requirements, however personal data in all other regards is subject to + control in accordance with regulation. This includes but is not + limited to our commitment to; +

+ +
    +
  1. + Sign a specific contract with you for such processing that sets out + the nature, subject matter, duration, and description of purpose in + accordance with the Acts +
  2. +
  3. + Where we are operating as a processor only, to process data on + specific written instruction from you +
  4. +
  5. + Keep the data confidential and secure +
  6. +
  7. + Support you in the event of audits, inspections, Access Requests or + the provision of Data Protection Impact Assessment. +
  8. +
  9. + Delete or return data upon instruction +
  10. +
  11. + Assure compliance of third parties delivering service to us for the + purpose of processing your data +
  12. +
+ +

+ We shall comply at all times with the data protections principles of + the relevant Acts. +

+ +

+ Disclosure to third parties & international transfer +

+ +

+ We take all reasonable measures to protect your personal information while it is in our possession. Your personal information may be transferred to third party service providers who process information on the inSports TV behalf, including providers of information technology, identity management, website hosting and management, network services, data analysis, anti-spam services, data back-up, security, and storage services. +

+ +

+ Your Personal data may also be transferred to joint sponsors of events, or to certification bodies. We may also provide access to your personal information to law enforcement authorities, revenue commissioners, regulatory or other government agencies, or to other third parties should we receive a valid request compatible with applicable law or regulation. +

+ +

+ Personal data submitted through this site may be transferred to third party service providers or to other companies within the inSports group of companies that are outside of the state, and outside of the European Economic Area (EEA). Where you request goods or services to be provided outside the EEA (European Economic Area), or to be delivered in conjunction with others outside of the EEA, personal data provided by you may be shared with organizations or state bodies (customs, revenue authorities and etc.) to fulfil an agreement. +

+ +

+ Responsibility of our customers +

+ +

+ Customers and other organizations engaging with us for service shall warrant that personal information provided to us for the administration and delivery of goods and services being provided under the Agreement has been obtained fairly and lawfully. Such customers or organizations shall also warrant that subjects are aware of the purpose for which their personal data is being used and that such data may be transferred outside of the EEA for processing or to deliver the service or upon your request, and that the privacy rights of subjects have been upheld. +

+ +

+ Confidentiality & security +

+ +

+ inSports TV have implemented generally accepted standards of technology and operational security to protect personal data from alteration, unauthorized disclosure or destruction, and from use for unauthorized purposes. Furthermore, we have taken measures to ensure that contracts with all third parties that provide technical and processing services include terms that specify appropriate technical and organizational security measures to prevent accidental, unauthorized or unlawful disclosure or processing of personal data. +

+ +

+ Data Subject's Rights +

+ +

+ Individuals have rights to: +

+ + + +

+ You can contact us to exercise these rights by e-mail at support@insports.tv. We will ask for additional information to verify your identity + prior to acting upon such requests. We may charge for an access + request in accordance with law. +

+ +

+ Removal from mailing lists +

+ +

+ You may unsubscribe from our mailing lists at any time by using the + ‘unsubscribe’ button on marketing communications, or by contacting us + at support@insports.tv. +

+ +

+ Reporting of Data Breaches +

+ +

+ Where a data breach occurs that poses a risk to the subject it shall + be reported to the Data Protection Commissioner DPC without delay or + at least within 72 hours. Where such breach is likely to expose the + subject to high risk it will be reported to the subject. In any event, + all breached will be managed in accordance with Irish law and + GDPR +

+ +

+ Data Retention +

+ +

+ We retain personal data that you submit to us only for as long as is + necessary and for the purposes for which it was obtained, or as + required by law. +

+ +

+ Cookies +

+ +

+ We use cookies – small text files – which are placed on your hard + drives to provide a more intuitive website experience. Cookies are a + typical part of operating procedure for most websites and most + browsers permit users to opt-out of receiving them if the user would + prefer. This may reduce some of the functionality of the site. +

+ +

+ Cookies can be deleted from your system at any time. +

+ +

+ © inSportsTV.com All right reserved. +

+
+
+

+ *ERSTE LIGA ADDITIONAL NOTICE +

+

+ In the case of ERSTE LIGA TV channel, data is processed jointly in + accordance with EU Regulation 2016/679 (hereinafter GDPR). When + registering on the inSports site, after accepting this Privacy Policy + and Privacy Statement, the user provides the e-mail address required + to use the service, which is handed over to the Hungarian Ice Hockey + Federation (hereinafter referred to as HIHF), the rights holder of the + ERSTE LIGA TV channel, within the framework of joint data processing. + Details of the joint processing by the HIHF: + +

+

+ Purpose of data processing: the HIHF sends marketing, PR and sports + promotional content by electronic messages to users who accept this + Privacy Statement,  to the e-mail address they have provided. + +

+

+ Legal basis for processing: consent of the data subject. + +

+

+ The scope of the data processed: the e-mail address of the user + registered on inSports.tv. + +

+

+ Duration of processing: until the data subject's consent is + withdrawn. + +

+

+ Method of processing: electronically, in compliance with the + necessary security standards. + +

+

+ Data subjects' rights: + +

+
    +
  1. + The data subject has the right to withdraw consent to data + processing at any time. Withdrawal of consent does not affect the + lawfulness of the prior processing. +
  2. +
  3. + The data subject may also exercise his or her right of access to + his or her personal data (right to request information about the + processing), the right to rectification of his or her personal data + (e.g. if his or her e-mail address changes), the right to object to + processing, the right to restriction of processing (e.g. if he or + she does not wish to receive e-mails for a certain period of time), + the right to erasure or blocking of his or her data, and the right + to data portability. + +
  4. +
  5. + If the data subject wishes to exercise his or her rights in + relation to the joint processing described in this paragraph, he or + she may do so by the means listed below: + +
  6. +

    + Name: Hungarian Ice Hockey Federation (hereinafter referred to as + the "Controller") + +

    +

    + Seat: H-1146 Budapest, Istvánmezei út 1-3. + +

    +

    + Postal address: H-1146 Budapest, Istvánmezei út 1-3. + +

    +

    + Represented by: Zsolt Levente Sipos, General Secretary + +

    +

    + Phone: +36 1 460 6863 + +

    +

    + Fax: +36 1 460 6864 + +

    +

    + E-mail: adatvedelem@icehockey.hu + +

    +
+

+ HIHF ERSTE LIGA TV Terms and Conditions of Use, including the Privacy + Statement, can be found at the following link: + "ersteligatv.hu/Felhasznalasi-feltetelek" + +

+
+ + diff --git a/public/clients/tunisia/terms-and-conditions.html b/public/clients/tunisia/terms-and-conditions.html new file mode 100644 index 00000000..9c1a16b2 --- /dev/null +++ b/public/clients/tunisia/terms-and-conditions.html @@ -0,0 +1,4368 @@ + + + + + + +
+

+
+
+
+

+ +

+ Terms and Conditions +

+ +

+ personal user - online access +

+ +

+ Key Definitions +

+ +

+ inSports TV also referred to as "us", "we", "our" or + "the company"; refers to inSport TV Limited. +

+

+ Subscriber also referred to as "you" or "your"; + refers to the individual, representative of a company or entity, + entering into an agreement with inSports TV for access to inSports TV + Service, hereinafter referred to as “users”, “members” or + “visitors”. +

+

+ Agreement; refers to this document and any additional + documentation between you and us that has been clearly and + unambiguously indicated in writing as an addendum to this agreement + and has been signed by both parties. +

+

+ inSports TV Service or “Services” or "Service"; + refers to the sports broadcasting platform operated and provided by + inSports TV and the delivery systems for such data. This service is + currently delivered online under the inSports TV brand. +

+

+ Personal Data: is information relating to an identified or + identifiable natural person who can be identified, directly or + indirectly, in particular by reference to an identifier such as; a + name, an identification number, location data, an online identifier, + or one of more factors specific to the physical, psychological, + genetic, mental, economic, cultural or social identity of that natural + person. +

+

+ European Standard Contractual Clauses also referred to as + "SCC" refers to standard terms for the transfer of personal + data from the European Economic Area EEA to a third country. A copy of + these terms in English, as amended from time to time, can be found at + https://ec.europa.eu/info/law/law-topic/data-protection/data-transfers-outside-eu/modelcontracts-transfer-personal-data-third-countries_en. +

+

+ Data Subject: + An identified or identifiable natural person + +

+

+ Controller (inSports TV): The natural or legal person, or body + which, alone or jointly determines the purpose and means of the + processing of personal data. + +

+

+ Fee: any applicable taxes and service fees charged in + connection with your use of inSports TV. + +

+

+ Payment Method: any information concerning your credit card or + other available payment method. + +

+

+ The Agreement +

+
    +
  1. + When you join the Service you become a User. If you have chosen not + to register for our Service, you may not use the service. +
  2. +
  3. + inSports TV will provide you with the Services offered at the time of + entering into this agreement. You accept these Services as they are. + +
  4. +
  5. + You agree to pay a fee for all premium services provided by inSports + TV to you at the then current rate for the selected service. + Payments may require a current credit card. Should you subscribe to + a service requiring monthly payment such payment will be + administered by a credit card fulfillment firm that is recognized by + the banks. We currently use Stripe, DECTA, Apple ID and Google + billing accounts. We will not retain your complete credit card + details on our systems. +
  6. +
  7. + In consideration for the service provided to you, you acknowledge + and agree to respect the intellectual property rights of inSports TV + over inSports Service +
  8. +
  9. + Any part of these Terms which by its nature or implicitly or to + give effect to its purpose is to continue in force after expiry or + termination of the Services Contract shall survive. +
  10. +
+

+ Your responsibilities +

+ +
    +
  1. + Notwithstanding our duties and responsibilities in relation to the + Services, you shall retain responsibility and accountability for + managing your affairs and for deciding what to do with information + received from the inSports TV Service. +
  2. +
  3. + Any video content provided by the Services in any form or medium + shall be supplied for your benefit and information only and shall be + used for the purpose of personal, non-commercial use only. Save as + may be required by law or by a competent regulatory authority such + data shall not be copied, referred to or disclosed by you, in whole + or in part, or used for purposes other than those detailed in this + clause, without prior written consent of inSports TV. +
  4. +
  5. + You agree to keep your password for the account secure and + confidential and not transfer any part of your account (e.g. inSports + TV video content) or login details to your account without explicit + consent of inSports TV. You are responsible for the integrity and + security of your account unless you close the account or in the + event of misuse, from when you report misuse to us. +
  6. +
  7. + Should you materially breach the terms of this agreement we may + close your account without prior notice. The sharing of access to + your account, or of Service accessed through your account without + consent form inSports TV is considered a material breach. +
  8. +
  9. + User is deemed liable for any damages incurred by inSports TV due to + material breach of this agreement; this shall extend beyond any + expiration or termination of this agreement indefinitely. +
  10. +
+

+ Purchases +

+ +
    +
  1. + If you wish to purchase any product or service made available + through the Service you may be asked to supply certain information + relevant to your Purchase including payment, authentication and + other information required for legal or taxation purposes.
    + By agreeing to purchase you give us a permission to obtain and + process your payment information.
    + You agree that we may retain and process your billing data (e.g. + credit card) even after it has expired for administrative and + taxation purposes.
    +
  2. +
  3. + You agree that there may be fees ] that are added to our prices. + Your purchase may also be a subject to exchange fees or differences + in prices based on location (e.g. exchange rates). You will be + notified of all such additions in advance of payment. +
  4. +
  5. + We may calculate taxes payable by you based on the billing + information that you provide us at the time of purchase. +
  6. +
  7. + By signing up for a subscription, you agree that your subscription + will be automatically renewed and, unless you cancel your + subscription, you authorize us to charge your Payment Method for the + renewal term. By providing Payment Method information for inSports TV + subscription, you are agreeing to pay a monthly Subscription Fee and + any applicable Fees in connection with your use of the Service. The + Subscription Fee and any applicable Fees will be charged to your + Payment Method automatically at the beginning of your subscription + and at the beginning of each subscription period renewal thereafter + on the calendar day corresponding to the commencement of your + subscription unless you cancel your subscription or account or your + access is suspended or terminated pursuant to these Terms. +
  8. +
  9. + You may cancel your subscription at any time. To cancel your + subscription please open your account settings page - + https://insports.tv/useraccount/bank-cards + and delete your Payment Method details – the subscription will be + nulled. +
  10. +
  11. + ALL FEES ARE NON-REFUNDABLE. If you cancel your subscription, the + cancellation will go into effect at the end of the then-current + subscription period. You will have continued access to the Service + for the remainder of your paid subscription period, but YOU WILL NOT + RECEIVE A REFUND OF ANY FEES PAID. You must cancel your subscription + before it renews for the next month to avoid paying the Subscription + Fee and any applicable Fees for the next renewal period. +
  12. +
+

+ Notices and Messages +

+
    +
  1. + We may provide notices and messages to you through our website and + contact information. You may opt out of marketing related messages + at any time by request to support@insports.tv. +
  2. +
  3. + We may provide messages to you by default in the following ways: + within the Service, or to the contact information you provided to + us. +
  4. +
+

+ Data Protection +

+
    +
  1. + Purpose of Processing;

    + We may process personal details relating to you or your employees or + representatives, for the purpose of administration and delivery of + goods and services provided to you, and to make contact with you + regarding our services. We may also process personal data in order + to manage quality and standards in our work or to facilitate IT + maintenance or the administration of our business.
    +
  2. +
    +
  3. + Categories of personal data

    + Data categories may include name, address, delivery address and + details, phone numbers, e-mail contact addresses, social media + identifications, unique identifications and usage information + relating to electronic communication including but not limited to an + IP address, the company you represent, your employer and your + position in the organisation, payment details, credit rating, and + any other categories directly related to the supply of services to + you. +
    We may also obtain video content that is in the public domain, + available on public broadcast or under contract with a club or + league.
    +
  4. +
    +
  5. + Third parties

    + Should we need to engage third parties for the delivery of service, + or for administrative or delivery functions, including but not + limited to the collection of debt or the transfer of debt to a third + party, we may share personal data provided by you with the parties + for these purposes.
    +
  6. +
    +
  7. + International transfer

    +
      +
    1. + Processing of personal data provided by you.
      + Where you request the goods or services to be provided outside + the EEA (European Economic Area), or to be delivered in + conjunction with others outside of the EEA, personal data + provided by you may be shared with organizations or state + bodies (customs, revenue authorities and etc.) to fulfil an + agreement between us. Where such information is transferred + within the InSports Group of companies it may be transferred + outside of the EEA. Such transfers are subject to EU approved + model contracts for the transfer of personal data. These terms + of transfer and safeguards are published on the European + commission website and can be viewed at + https://ec.europa.eu/info/law/law-topic/dataprotection/data-transfers-outside-eu/model-contracts-transfer-personal-data-thirdcountries_en.
      +
    2. +
    3. + Provision of Services to you outside of the EEA
      + Where you reside outside of the EEA, or consume this Services + outside of the EEA, you agree to process the data provided by + us to you in compliance with European data protection + regulation and that the terms of the EU Controller to + Controller SCCs shall apply to such transfer of personal data + to you. A copy of these terms in English, as amended from time + to time, can be found at + https://ec.europa.eu/info/law/law-topic/data-protection/data-transfers-outside-eu/model-contracts-transfer-personal-data-third-countries_en. A copy can also be found in Appendix 1.
      +
    4. +
    +
    +
  8. +
    +
  9. + Personal Data relating to sports performance is processed and + analysed to create InSports Statistics. InSports Statistics is sold + commercially and may be delivered to any location worldwide. +
  10. +
    +
  11. + Your staff and representatives

    + If you are purchasing or receiving access to InSports TV Service as a + business or in any capacity other than in a personal capacity, you + warrant that personal information provided to us by you for the + administration and delivery of goods and services being provided + under the Agreement has been obtained fairly and lawfully. You also + warrant that subjects are aware of the purpose for which their + personal data is being used and that such data may be transferred + outside of the EEA, and that the privacy rights of subjects have + been upheld. +
    +
  12. +
    +
  13. + Information and access requests

    + Data subjects are entitled at any time to make information requests + to establish if we hold personal data relating to them, the purpose + for which such data is used and the categories of data. Data subject + are also entitled to have access to such data, be informed of who + has access to that data, of the source of data if it was not + provided directly by the subject in the first instance, the logic of + any processing, a copy of comment or opinion relating to such + activity, and where processing is automated, to make a submission. + There are exceptions to some of these entitlements. +
    +
  14. +
    +
  15. + Web bases applications / e-mail

    + Data provided to us may be processed on servers (e-mail, backup, + operational applications and other web based software applications + used by us), or on the servers of our suppliers or partners that do + not reside within the European Economic Area EEA and that have not + had an adequacy decision by the commission. Where this occurs we + shall, to the best of our ability, inform you of this processing. +
    +
  16. +
    +
  17. + Additional personal data

    + In addition to the personal data described above, we may also hold; +
      +
    1. + credit reports received from third parties for the purpose of + credit review. +
    2. +
    3. + Information provided by individuals while exercising their + rights to access, rectify or erase your data, or to object or + complain. This information is retained for the purposes of + compliance record keeping and may be used in the event of + further legal interaction between the individual and us +
    4. +
    5. + cctv images of personnel who visit our premises. These + recordings are made for the purposes of safety and + security +
    6. +
    +
    +
  18. +
    +
  19. + Data retention

    + Personal data provided for the operation of your agreement with us + will be retained for three years subsequent to the completion of the + agreement, or our last communication with you. Some data may be held + for longer periods as required by law, or in the event of a possible + legal action between the parties where it is deemed necessary to be + retained as evidence. +
    +
  20. +
    +
  21. + Your rights

    + To ensure fair and transparent processing of any such personal data + provided by you to us under this agreement we respect the rights of + the data subjects. These rights include; +
      +
    1. + Where information is collected directly from the subject, to + be informed of the controller and representative (listed + above), the purpose of processing, who will have access, the + retention duration for the data, the consequences of not + providing the data, and +
    2. +
    3. + Where data was not provided by the subject, we will identify + the source of that data together with data categories. +
    4. +
    5. + To be informed if a failure to provide the personal data will + have any direct and material personal consequences +
    6. +
    7. + Information on whether we have Personal Data relating to a + subject, the categories of data and the purpose of + processing +
    8. +
    9. + Access to your personal data. Where the format is not + reasonably understood, this shall be delivered in an + intelligible format +
    10. +
    11. + Have inaccurate, incomplete or out-of-date personal data that + we hold about you corrected, or deleted +
    12. +
    13. + Make a submissions to any automated decisions making + processes or profiling of you +
    14. +
    15. + Transfer your data to another controller +
    16. +
    17. + Have your personal data excluded from certain categories of + processing. +
    18. +
    19. + Lodge a complaint with the Data Protection Commissioner. + Contact details for the DPC can be found at + www.dataprotection.ie. +
    20. +
    +
    +
  22. + Controller and representative

    + Data Controller is InSports TV and you may communicate with our + Data Protection Representative by writing to our registered + address, or e-mailing to + support@insports.tv
    +
  23. + + +
+

+ Assignment of benefit

Third parties
+

+
    +
  1. + We may receive information from you or from other sources in the + course of delivering the Services. To the fullest extent permitted + by law, we shall not be liable to you for any loss or damage + suffered by you arising from fraud, misrepresentation, withholding + of information that is material or relevant to the Services, or + other deficiency relating to such information, whether on your part + or that of the other information sources. +
  2. +
  3. + InSports TV has no control over, and assumes no responsibility for + the content, privacy policies, or practices of any third party site + or services that may use InSports TV. You further acknowledge and + agree that InSports TV shall not be responsible or liable, directly or + indirectly, for any damage or loss caused or alleged to be caused by + or in connection with use of or reliance on any such video content + available on or through any third party web sites or services. +
  4. +
  5. + When you provide information to us on the InSports Service, such + information may be shared with other parties in accordance with your + privacy settings or subject to a separate agreement overriding these + Terms and Conditions. Examples of such agreements include but are + not limited to agreements with your club or league. +
  6. +
  7. + We shall have the right to appoint sub-contractors to assist us in + delivering the Services. Where we appoint sub-contractors under this + clause, we may share Confidential Information with them and for all + purposes in connection with the Agreement we shall accept + responsibility for their activities which shall form part of the + Services. +
  8. +
+

+ Cookies +

+
    +
  1. + We receive and store certain types of information when you visit or + interact with the Service. For example, we use "cookies," and we + obtain certain types of information when your Web browser accesses + the Service. Cookies are necessary for the good functioning of the + Service, they help us to improve our services and to give you extra + functionalities. +
  2. +
+

+ Changes +

+
    +
  1. + We reserve the right, at our sole discretion, to modify or replace + these Terms at any time. Your continued use of the Service after we + modify or replace these terms means that you are consenting to the + updated Terms. +
  2. +
+

+ Intellectual Property Rights +

+
    +
  1. + InSports TV reserves all of its intellectual property rights in the + Service. Using the Service does not give you any ownership in our + Service or the video content or information made available through + our Service. Trademarks, logos and elements of video content used in + connection with the Service may be owned by other respective owners. + InSports TV logos and video used for the Service are the property of + InSports TV. +
  2. +
  3. + InSports TV logos, trademarks and Statistics may not be used by you + for any further process, or in conjunction with other third parties + without express agreement form InSports TV. +
  4. +
+

+ No Warranty +

+
    +
  1. + To the extent allowed under law, InSports TV and it's affiliates and + those that InSports TV work with to provide the Service disclaim all + implied warranties and representations (particularly any implied + warrantee of merchantability, fitness for purpose, accuracy of data, + or non infringement), do not guarantee that the Service will + function without interruption of errors, and provide the service on + an “as is” and “as available” basis. +
  2. +
+

+ Exclusion of Liability +

+
    +
  1. + To the extent permitted by law InSports TV and it's affiliates and + those that InSports work with to provide the Service shall not be + liable for any indirect, incidental, special, consequential or + punitive damages, or any loss of data, opportunities, reputation, + profit or revenues related to the use of the Service. +
  2. +
  3. + To the extent permitted by law no event shall result in a liability + to InSports TV and it's affiliates and those that InSports TV work with + to provide the Service exceed, in the aggregate for all related + claims, that exceeds the lessor of five times the most recent + monthly or yearly fee that you paid InSports TV for the Service, if + any, or €1,000. +
  4. +
  5. + This limitation of liability shall apply to all claims of liability + (warrantee, tort, negligence, contract or law) to the extent + permissible by law and even if InSports TV or it's affiliates have + been informed of the possibility of any such damage or if these + remedies fail their essential purpose. +
  6. +
  7. + We shall not be in breach of our contractual obligations or incur + any liability to you if we are unable to comply with the Agreement + as a result of any cause beyond our reasonable control. +
  8. +
+

+ Termination +

+
    +
  1. + Each party of this agreement can terminate the Services Contract or + suspend its operation by giving 30 days prior notice in writing to + the other at any time. Termination or suspension under this clause + shall not affect any rights that may have accrued for either of us + before termination or suspension and all sums due to us shall become + payable in full when termination or suspension takes effect. + Additionally, this contract will terminate immediately without + notice if, in our sole discretion, you fail to comply with present + Terms and Conditions including breach of warranties given (please + see the section below). +
  2. +
  3. + On termination, you lose the right to access or use the Services. + Any amounts owed by you prior to termination remain owed after + termination. +
  4. +
  5. + The intellectual property rights of InSports over InSports TV including + video content shall endure following the termination of this + contract +
  6. +
+

+ Operation of an InSports account +

+
    +
  1. + You warrant that you shall: +
      +
    1. + you shall Comply with all applicable laws, including, without + limitation, privacy laws, intellectual property laws, + anti-spam laws, export control laws, tax laws, and regulatory + requirements While using the InSports Service; + +
    2. +
    3. + provide accurate information to us and keep it updated. Use + your real name on your profile and not create a false identity + on InSports, misrepresent your identity, create a + +
    4. +
    5. + not develop, support or use software, devices, scripts, + robots, or any other means or processes (including crawlers, + browser plugins and add-ons, or any other technology) to + scrape the Services or otherwise copy profiles and other data + from the Services; +
    6. +
    7. + override any security feature or bypass or circumvent any + access controls or use limits of the Service; +
    8. +
    9. + post anything that contains software viruses, worms, or any + other harmful code; +
    10. +
    11. + shall not reverse engineer, decompile, disassemble, decipher + or otherwise attempt to derive the source code for the + Services or any related technology that is not open + source; +
    12. +
    13. + shall not rent, lease, loan, trade, sell/re-sell or otherwise + monetize the Services or related data or access to the same, + without InSports TV consent; +
    14. +
    15. + shall not use bots or other automated methods to access the + Services; +
    16. +
    17. + Monitor the Services’ availability, performance or + functionality for any competitive purpose; +
    18. +
    19. + Engage in “framing,” “mirroring,” or otherwise simulating the + appearance or function of the Services; +
    20. +
    21. + Overlay or otherwise modify the Services or their appearance + (such as inter alia by inserting or removing elements into the + Services); +
    22. +
    23. + Interfere with the operation of, or place an unreasonable + load on, the Services (e.g., spam, denial of service attack, + viruses, gaming algorithms). +
    24. +
    +
  2. +
+

+ Notices +

+
    +
  1. + Any notice under this agreement shall be given in writing and + delivered; +
      +
    1. + Any notice under this agreement shall be given in writing and + delivered; + +
    2. +
    3. + by registered post or + +
    4. +
    5. + to our address appearing in the Letter of Engagement, and + signed for or + +
    6. +
    7. + by e-mail to us where such e-mail has been acknowledged by + return from an InSports Representative. + +
    8. +
    +
  2. + Notices shall be deemed delivered on the date of the signing or + acknowledgement of receipt as described above. + +
  3. + + +
+

+ Capacity +

+
    +
  1. + You are over 16 and agree to and accept the provisions of the + Agreement on yours, and entity for which you represent, behalf. You + shall procure that any other beneficiaries shall act as if they had + each signed a copy of the Letter of Engagement and agreed to be + bound by the Agreement. However, you alone shall be responsible for + payment of our Charges or, + +
  2. +
  3. + acknowledge that if you are under 16 that you have followed the + appropriate acceptance process in the InSports TV Service to accept + the provisions of this agreement. This requires the consent of a + parent or guardian. + +
  4. +
+

+ Severability +

+
    +
  1. + Each clause or sub clause of the Agreement constitutes a separate + and independent provision. If any provisions of the Agreement are + judged by any court or authority of competent jurisdiction to be + void or unenforceable, the remaining provisions shall continue in + full force and effect. + +
  2. +
  3. + If any provisions of the Agreement are judged by any court or + authority of competent jurisdiction to be void or unenforceable, + that provision shall be replaced with a provision that gives legal + effect and exact meaning and intention of the initial clause, and is + acceptable to the authority that found the clause to be void or + unenforceable. + +
  4. +
+

+ No Waver +

+
    +
  1. + + Failure to exercise or enforce any rights shall not amount to a + waiver of such rights. + +
  2. +
+

+ Service feedback +

+
    +
  1. + While engaging with us you should experience a culture of openness + and professionalism. We may from time to time ask you to provide + feedback, and invite your commentary. Should you have reason to feel + that you need to discuss our service or complain about our + activities, please contact us through our "contact us" facility on + our website or Service, by e-mail or by post. We welcome feedback + and dialog regarding the service that we offer. + +
  2. +
+

+ Law and jurisdiction +

+
    +
  1. + The Agreement shall in all respects be subject to and governed by + Irish law and all disputes arising on any basis from or under the + Services Contract shall be subject to the exclusive jurisdiction of + the Irish courts. + +
  2. +
+

+ Contact Us +

+
    +
  1. + If you have any questions about these Terms, please contact us + support@insports.tv

    + Your access to and use of the Service is conditioned on your + acceptance of and compliance with the terms of this agreement. Use + of the InSports Service is governed by these terms and conditions at + all times and by indicating your acceptance of these terms, or using + the InSports Service, you are entering into a binding agreement with + us.

    + If you do not agree to these terms you must not access or otherwise + use the InSports Service. These Terms apply to all members, visitors, + users and others who access or use the InSports Service. +
    +
  2. +
+

+ Appendix 1 +

+

+ +

+ Commission Decision C(2004) 5271

+ SET II

+ Standard contractual clauses for the transfer of personal data + from the Community to third countries (controller to controller + transfers)

+ Data transfer agreement


+ InSports TV as described at the head of this agreement

+ hereinafter “data exporter”

+ and

+ The purchasing party as described at the head of this agreement

+ hereinafter “data importer”

+ each a “party”; together “the parties”. +
+

+ +

+

+ Definitions +

+

+ For the purposes of the clauses: +

+
    +
  1. + “personal data”, “special categories of data/sensitive data”, + “process/processing”, “controller”, “processor”, “data subject” and + “supervisory authority/authority” shall have the same meaning as in + Directive 95/46/EC of 24 October 1995 (whereby “the authority” shall + mean the competent data protection authority in the territory in + which the data exporter is established); + +
  2. +
  3. + “the data exporter” shall mean the controller who transfers the + personal data; + +
  4. +
  5. + “the data importer” shall mean the controller who agrees to receive + from the data exporter personal data for further processing in + accordance with the terms of these clauses and who is not subject to + a third country’s system ensuring adequate protection; + +
  6. +
  7. + “clauses” shall mean these contractual clauses, which are a + free-standing document that does not incorporate commercial business + terms established by the parties under separate commercial + arrangements. + +
  8. +
+

+ The details of the transfer (as well as the personal data covered) + are specified in Annex B, which forms an integral part of the + clauses. +

+
    +
  1. + Obligations of the data exporter +

    + The data exporter warrants and undertakes that: +

    +
      +
    1. + The personal data have been collected, processed and + transferred in accordance with the laws applicable to the data + exporter. +
    2. +
    3. + It has used reasonable efforts to determine that the data + importer is able to satisfy its legal obligations under these + clauses. +
    4. +
    5. + It will provide the data importer, when so requested, with + copies of relevant data protection laws or references to them + (where relevant, and not including legal advice) of the country + in which the data exporter is established. +
    6. +
    7. + It will respond to enquiries from data subjects and the + authority concerning processing of the personal data by the data + importer, unless the parties have agreed that the data importer + will so respond, in which case the data exporter will still + respond to the extent reasonably possible and with the + information reasonably available to it if the data importer is + unwilling or unable to respond. Responses will be made within a + reasonable time. +
    8. +
    9. + It will make available, upon request, a copy of the clauses to + data subjects who are third party beneficiaries under clause + III, unless the clauses contain confidential information, in + which case it may remove such information. Where information is + removed, the data exporter shall inform data subjects in writing + of the reason for removal and of their right to draw the removal + to the attention of the authority. However, the data exporter + shall abide by a decision of the authority regarding access to + the full text of the clauses by data subjects, as long as data + subjects have agreed to respect the confidentiality of the + confidential information removed. The data exporter shall also + provide a copy of the clauses to the authority where + required. +
    10. +
    +
  2. +
    +
  3. + Obligations of the data importer +

    + The data importer warrants and undertakes that: +

    +
      +
    1. + It will have in place appropriate technical and organisational + measures to protect the personal data against accidental or + unlawful destruction or accidental loss, alteration, + unauthorised disclosure or access, and which provide a level of + security appropriate to the risk represented by the processing + and the nature of the data to be protected. +
    2. +
    3. + It will have in place procedures so that any third party it + authorises to have access to the personal data, including + processors, will respect and maintain the confidentiality and + security of the personal data. Any person acting under the + authority of the data importer, including a data processor, + shall be obligated to process the personal data only on + instructions from the data importer. This provision does not + apply to persons authorised or required by law or regulation to + have access to the personal data. +
    4. +
    5. + It has no reason to believe, at the time of entering into these + clauses, in the existence of any local laws that would have a + substantial adverse effect on the guarantees provided for under + these clauses, and it will inform the data exporter (which will + pass such notification on to the authority where required) if it + becomes aware of any such laws. +
    6. +
    7. + It will process the personal data for purposes described in + Annex B, and has the legal authority to give the warranties and + fulfil the undertakings set out in these clauses +
    8. +
    9. + It will identify to the data exporter a contact point within + its organisation authorised to respond to enquiries concerning + processing of the personal data, and will cooperate in good + faith with the data exporter, the data subject and the authority + concerning all such enquiries within a reasonable time. In case + of legal dissolution of the data exporter, or if the parties + have so agreed, the data importer will assume responsibility for + compliance with the provisions of clause I(e). +
    10. +
    11. + At the request of the data exporter, it will provide the data + exporter with evidence of financial resources sufficient to + fulfil its responsibilities under clause III (which may include + insurance coverage). +
    12. +
    13. + Upon reasonable request of the data exporter, it will submit + its data processing facilities, data files and documentation + needed for processing to reviewing, auditing and/or certifying + by the data exporter (or any independent or impartial inspection + agents or auditors, selected by the data exporter and not + reasonably objected to by the data importer) to ascertain + compliance with the warranties and undertakings in these + clauses, with reasonable notice and during regular business + hours. The request will be subject to any necessary consent or + approval from a regulatory or supervisory authority within the + country of the data importer, which consent or approval the data + importer will attempt to obtain in a timely fashion. +
    14. +
    15. + It will process the personal data, at its option, in accordance + with: +
        +
      1. + the data protection laws of the country in which the data + exporter is established, or +
      2. +
      3. + the relevant provisions (1) of any Commission decision pursuant to Article 25(6) of + Directive 95/46/EC, where the data importer complies with + the relevant provisions of such an authorisation or decision + and is based in a country to which such an authorisation or + decision pertains, but is not covered by such authorisation + or decision for the purposes of the transfer(s) of the + personal data (2), or +
      4. +
      5. + the data processing principles set forth in Annex A. Data + importer to indicate which option it selects: Initials of + data importer:_; +
      6. +
      +
    16. +
    17. + It will not disclose or transfer the personal data to a third + party data controller located outside the European Economic Area + (EEA) unless it notifies the data exporter about the transfer + and +
        +
      1. + the third party data controller processes the personal data + in accordance with a Commission decision finding that a + third country provides adequate protection, or +
      2. +
      3. + the third party data controller becomes a signatory to + these clauses or another data transfer agreement approved by + a competent authority in the EU, or +
      4. +
      5. + data subjects have been given the opportunity to object, + after having been informed of the purposes of the transfer, + the categories of recipients and the fact that the countries + to which data is exported may have different data protection + standards, or +
      6. +
      7. + with regard to onward transfers of sensitive data, data + subjects have given their unambiguous consent to the onward + transfer +
      8. +
      +
    18. +
    +
  4. +
    +
  5. + Liability and third party rights + +
      +
    1. + Each party shall be liable to the other parties for damages it + causes by any breach of these clauses. Liability as between the + parties is limited to actual damage suffered. Punitive damages + (i.e. damages intended to punish a party for its outrageous + conduct) are specifically excluded. Each party shall be liable + to data subjects for damages it causes by any breach of third + party rights under these clauses. This does not affect the + liability of the data exporter under its data protection + law. +
    2. +
    3. + The parties agree that a data subject shall have the right to + enforce as a third party beneficiary this clause and clauses + I(b), I(d), I(e), II(a), II(c), II(d), II(e), II(h), II(i), + III(a), V, VI(d) and VII against the data importer or the data + exporter, for their respective breach of their contractual + obligations, with regard to his personal data, and accept + jurisdiction for this purpose in the data exporter’s country of + establishment. In cases involving allegations of breach by the + data importer, the data subject must first request the data + exporter to take appropriate action to enforce his rights + against the data importer; if the data exporter does not take + such action within a reasonable period (which under normal + circumstances would be one month), the data subject may then + enforce his rights against the data importer directly. A data + subject is entitled to proceed directly against a data exporter + that has failed to use reasonable efforts to determine that the + data importer is able to satisfy its legal obligations under + these clauses (the data exporter shall have the burden to prove + that it took reasonable efforts). +
    4. +
    +
  6. +
  7. + Law applicable to the clauses +

    + These clauses shall be governed by the law of the country in + which the data exporter is established, with the exception of the + laws and regulations relating to processing of the personal data + by the data importer under clause II(h), which shall apply only if + so selected by the data importer under that clause. +

    +
  8. +
  9. + + Resolution of disputes with data subjects or the authority + +
      +
    1. + In the event of a dispute or claim brought by a data subject or + the authority concerning the processing of the personal data + against either or both of the parties, the parties will inform + each other about any such disputes or claims, and will cooperate + with a view to settling them amicably in a timely fashion. +
    2. +
    3. + The parties agree to respond to any generally available + non-binding mediation procedure initiated by a data subject or + by the authority. If they do participate in the proceedings, the + parties may elect to do so remotely (such as by telephone or + other electronic means). The parties also agree to consider + participating in any other arbitration, mediation or other + dispute resolution proceedings developed for data protection + disputes. +
    4. +
    5. + Each party shall abide by a decision of a competent court of + the data exporter’s country of establishment or of the authority + which is final and against which no further appeal is + possible. +
    6. +
    +
  10. +
  11. + + Termination + +
      +
    1. + In the event that the data importer is in breach of its + obligations under these clauses, then the data exporter may + temporarily suspend the transfer of personal data to the data + importer until the breach is repaired or the contract is + terminated. +
    2. +
    3. + In the event that: +
        +
      1. + the transfer of personal data to the data importer has been + temporarily suspended by the data exporter for longer than + one month pursuant to paragraph (a); +
      2. +
      3. + compliance by the data importer with these clauses would + put it in breach of its legal or regulatory obligations in + the country of import; +
      4. +
      5. + the data importer is in substantial or persistent breach of + any warranties or undertakings given by it under these + clauses; +
      6. +
      7. + a final decision against which no further appeal is + possible of a competent court of the data exporter’s country + of establishment or of the authority rules that there has + been a breach of the clauses by the data importer or the + data exporter; or +
      8. +
      9. + a petition is presented for the administration or winding + up of the data importer, whether in its personal or business + capacity, which petition is not dismissed within the + applicable period for such dismissal under applicable law; a + winding up order is made; a receiver is appointed over any + of its assets; a trustee in bankruptcy is appointed, if the + data importer is an individual; a company voluntary + arrangement is commenced by it; or any equivalent event in + any jurisdiction occurs then the data exporter, without + prejudice to any other rights which it may have against then + the data exporter, without prejudice to any other rights + which it may have against the data importer, shall be + entitled to terminate these clauses, in which case the + authority shall be informed where required. In cases covered + by (i), (ii), or (iv) above the data importer may also + terminate these clauses +
      10. +
      11. + Either party may terminate these clauses if (i) any + Commission positive adequacy decision under Article 25(6) of + Directive 95/46/EC (or any superseding text) is issued in + relation to the country (or a sector thereof) to which the + data is transferred and processed by the data importer, or + (ii) Directive 95/46/EC (or any superseding text) becomes + directly applicable in such country +
      12. +
      13. + The parties agree that the termination of these clauses at + any time, in any circumstances and for whatever reason + (except for termination under clause VI(c)) does not exempt + them from the obligations and/or conditions under the + clauses as regards the processing of the personal data + transferred. +
      14. +
      +
    4. +
    +
  12. +
  13. + + Variation of these clauses + +

    + The parties may not modify these clauses except to update any + information in Annex B, in which case they will inform the + authority where required. This does not preclude the parties from + adding additional commercial clauses where required. +

    +
  14. +
  15. + + Description of the Transfer + +

    + The details of the transfer and of the personal data are + specified in Annex B. The parties agree that Annex B may contain + confidential business information which they will not disclose to + third parties, except as required by law or in response to a + competent regulatory or government agency, or as required under + clause I(e). The parties may execute additional annexes to cover + additional transfers, which will be submitted to the authority + where required. Annex B may, in the alternative, be drafted to + cover multiple transfers. +

    +
  16. +
+

+ ANNEX A +

+

+ DATA PROCESSING PRINCIPLES +

+
    +
  1. + Purpose limitation: Personal data may be processed and subsequently + used or further communicated only for purposes described in Annex B + or subsequently authorised by the data subject. +
  2. +
  3. + Data quality and proportionality: Personal data must be accurate + and, where necessary, kept up to date. The personal data must be + adequate, relevant and not excessive in relation to the purposes for + which they are transferred and further processed. + +
  4. +
  5. + Transparency: Data subjects must be provided with information + necessary to ensure fair processing (such as information about the + purposes of processing and about the transfer), unless such + information has already been given by the data exporter. + +
  6. +
  7. + Security and confidentiality: Technical and organisational security + measures must be taken by the data controller that are appropriate + to the risks, such as against accidental or unlawful destruction or + accidental loss, alteration, unauthorised disclosure or access, + presented by the processing. Any person acting under the authority + of the data controller, including a processor, must not process the + data except on instructions from the data controller. + +
  8. +
  9. + Rights of access, rectification, deletion and objection: As + provided in Article 12 of Directive 95/46/EC, data subjects must, + whether directly or via a third party, be provided with the personal + information about them that an organisation holds, except for + requests which are manifestly abusive, based on unreasonable + intervals or their number or repetitive or systematic nature, or for + which access need not be granted under the law of the country of the + data exporter. Provided that the authority has given its prior + approval, access need also not be granted when doing so would be + likely to seriously harm the interests of the data importer or other + organisations dealing with the data importer and such interests are + not overridden by the interests for fundamental rights and freedoms + of the data subject. The sources of the personal data need not be + identified when this is not possible by reasonable efforts, or where + the rights of persons other than the individual would be violated. + Data subjects must be able to have the personal information about + them rectified, amended, or deleted where it is inaccurate or + processed against these principles. If there are compelling grounds + to doubt the legitimacy of the request, the organisation may require + further justifications before proceeding to rectification, amendment + or deletion. Notification of any rectification, amendment or + deletion to third parties to whom the data have been disclosed need + not be made when this involves a disproportionate effort. A data + subject must also be able to object to the processing of the + personal data relating to him if there are compelling legitimate + grounds relating to his particular situation. The burden of proof + for any refusal rests on the data importer, and the data subject may + always challenge a refusal before the authority. + +
  10. +
  11. + Sensitive data: The data importer shall take such additional + measures (e.g. relating to security) as are necessary to protect + such sensitive data in accordance with its obligations under clause + II. + +
  12. +
  13. + Data used for marketing purposes: Where data are processed for the + purposes of direct marketing, effective procedures should exist + allowing the data subject at any time to “opt-out” from having his + data used for such purposes. + +
  14. +
  15. + Automated decisions: For purposes hereof “automated decision” shall + mean a decision by the data exporter or the data importer which + produces legal effects concerning a data subject or significantly + affects a data subject and which is based solely on automated + processing of personal data intended to evaluate certain personal + aspects relating to him, such as his performance at work, + creditworthiness, reliability, conduct, etc. The data importer shall + not make any automated decisions concerning data subjects, except + when: + +
      +
    1. + +
        +
      1. + such decisions are made by the data importer in entering + into or performing a contract with the data subject, + and +
      2. +
      3. + (the data subject is given an opportunity to discuss the + results of a relevant automated decision with a + representative of the parties making such decision or + otherwise to make representations to that parties. +
      4. +
      + or
      +
    2. +
    3. + where otherwise provided by the law of the data exporter +
    4. +
    +
  16. +
+

+ ANNEX B
+ DESCRIPTION OF THE TRANSFER
+

+

+ Data subjects +

+

+ The personal data transferred concern the following categories of + data subjects: +

+

+

+ Purposes of the transfer(s) +

+

+ The transfer is made for the following purposes: +

+

+

+ Categories of data +

+

+ The personal data transferred concern the following categories of + data: +

+

+

+ Recipients +

+

+ The personal data transferred may be disclosed only to the following + recipients or categories of recipients: +

+

+

+ Data protection registration information of data exporter (where + applicable) +

+

+ +

+

+

+ Additional useful information (storage limits and other relevant + information) +

+

+ +

+

+

+ Contact points for data protection enquiries +

+

+ Data importer
+ As noted at the head of this agreement
+

+

+ Data exporter +

+

+ Lazar Andreevich Petrov,
The contact address is: + support@insports.tv

+ © InSports.tv All right reserved.
+

+
+ + diff --git a/public/images/landing_ligue_1.png b/public/images/landing_ligue_1.png new file mode 100644 index 00000000..4f8c4058 Binary files /dev/null and b/public/images/landing_ligue_1.png differ diff --git a/public/images/landing_mobile_ligue_1.png b/public/images/landing_mobile_ligue_1.png new file mode 100644 index 00000000..1deafbfb Binary files /dev/null and b/public/images/landing_mobile_ligue_1.png differ diff --git a/public/images/tunis_auth_logo_mobile.svg b/public/images/tunis_auth_logo_mobile.svg new file mode 100644 index 00000000..20e711c2 --- /dev/null +++ b/public/images/tunis_auth_logo_mobile.svg @@ -0,0 +1,29 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/public/images/tunis_clubs.svg b/public/images/tunis_clubs.svg new file mode 100644 index 00000000..79079e60 --- /dev/null +++ b/public/images/tunis_clubs.svg @@ -0,0 +1,84 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/config/clients/index.tsx b/src/config/clients/index.tsx index f6835d60..18647023 100644 --- a/src/config/clients/index.tsx +++ b/src/config/clients/index.tsx @@ -5,7 +5,7 @@ import { instat } from './instat' import { lff } from './lff' import { insports } from './insports' import { india } from './india' -import { tunis } from './tunis' +import { tunisia } from './tunisia' export const currentClient = process.env.REACT_APP_CLIENT || 'insports' @@ -14,7 +14,7 @@ export const isInSportsClient = currentClient === 'insports' export const isInstatClient = currentClient === 'instat' export const isFacrClient = currentClient === 'facr' export const isIndiaClient = currentClient === 'india' -export const isTunisClient = currentClient === 'tunis' +export const isTunisClient = currentClient === 'tunisia' const clients = { facr, @@ -22,7 +22,7 @@ const clients = { insports, instat, lff, - tunis, + tunisia, } export const client: ClientConfig = clients[currentClient] diff --git a/src/config/clients/lff.tsx b/src/config/clients/lff.tsx index 276f0a06..e0d1b1b2 100644 --- a/src/config/clients/lff.tsx +++ b/src/config/clients/lff.tsx @@ -11,6 +11,7 @@ export const lff: ClientConfig = { }, defaultLanguage: 'lv', description: 'Live sports streaming platform. Football, basketball, ice hockey and more. Access to various player playlists and game highlights. Multiple subscription options. Available across all devices.', + disabledHighlights: true, disabledPreferences: true, name: ClientNames.Lff, privacyLink: '/clients/instat/terms-and-conditions.html', diff --git a/src/config/clients/tunis.tsx b/src/config/clients/tunis.tsx deleted file mode 100644 index 6764be26..00000000 --- a/src/config/clients/tunis.tsx +++ /dev/null @@ -1,57 +0,0 @@ -import { css } from 'styled-components/macro' - -import { - ClientConfig, - ClientIds, - ClientNames, -} from './types' - -const randomHash = () => ( - (Math.random() ** Math.random()) * 9999999999999999 -) - -export const tunis: ClientConfig = { - auth: { - clientId: ClientIds.Tunis, - metaDataUrlParams: `?hash=${randomHash()}`, - }, - defaultLanguage: 'fr', - description: 'Live sports streaming platform. All matches playing under the auspices of Czech Republic FA. Access to full matches, various player playlists, and highlights. Free access in the Czech Republic. Available across all devices', - disabledPreferences: false, - name: ClientNames.Tunis, - privacyLink: '/privacy-policy-and-statement', - showSearch: false, - styles: { - background: '', - homePageHeader: css` - background: radial-gradient( - 160.34% 257.27% at -7.45% 162.22%, - #2AB7AA 3.27%, - #02505C 43.69%, #0B2E4D 100%); - `, - logo: 'tunis-logo.svg', - logoHeight: 6.3, - logoLeft: 1.1, - logoTop: 1.74, - logoWidth: 8.25, - matchLogoHeight: 3.4, - matchLogoTopMargin: 0.9, - matchLogoWidth: 4.5, - matchPageMobileHeaderLogo: css` - width: 35px; - height: 25px; - top: 2px; - `, - mobileHeaderLogo: css` - width: 48px; - height: 37px; - `, - userAccountLogo: css` - width: 4.56rem; - height: 3.488rem; - `, - }, - termsLink: '/terms-and-conditions?client_id=facr-ott-web', - title: 'FACR.TV - The home of Czech football streaming', - userAccountLinksDisabled: true, -} diff --git a/src/config/clients/tunisia.tsx b/src/config/clients/tunisia.tsx new file mode 100644 index 00000000..b92522e3 --- /dev/null +++ b/src/config/clients/tunisia.tsx @@ -0,0 +1,58 @@ +import { css } from 'styled-components/macro' + +import { + ClientConfig, + ClientIds, + ClientNames, +} from './types' + +const randomHash = () => ( + (Math.random() ** Math.random()) * 9999999999999999 +) + +export const tunisia: ClientConfig = { + auth: { + clientId: ClientIds.Tunisia, + metaDataUrlParams: `?hash=${randomHash()}`, + }, + defaultLanguage: 'fr', + description: '', + disabledFilters: true, + disabledHighlights: true, + disabledPreferences: true, + name: ClientNames.Tunisia, + privacyLink: '/privacy-policy-and-statement?client_id=insports-ott-web', + showSearch: true, + styles: { + background: '', + homePageHeader: css` + background: radial-gradient( + 160.34% 257.27% at -7.45% 162.22%, + #2AB7AA 3.27%, + #02505C 43.69%, #0B2E4D 100%); + `, + logo: 'tunis-logo.svg', + logoHeight: 1.922, + logoLeft: 1.1, + logoTop: 1.74, + logoWidth: 9, + matchLogoHeight: 1.922, + matchLogoTopMargin: 1, + matchLogoWidth: 9, + matchPageMobileHeaderLogo: css` + width: 100px; + height: 21px; + top: 5px; + `, + mobileHeaderLogo: css` + width: 100px; + height: 21px; + `, + userAccountLogo: css` + width: 9rem; + height: 1.922rem; + `, + }, + termsLink: '/terms-and-conditions?client_id=insports-ott-web', + title: 'Diwan Sport - The home of Tunisian Ligue Professionnelle 1', +} diff --git a/src/config/clients/types.tsx b/src/config/clients/types.tsx index 77f01e9b..88a59a2d 100644 --- a/src/config/clients/types.tsx +++ b/src/config/clients/types.tsx @@ -10,16 +10,17 @@ export enum ClientIds { Insports = 'insports-ott-web', Instat = 'ott-web', Lff = 'lff-ott-web', - Tunis = 'tunis-ott-web', + Tunisia = 'tunis-ott-web', } export enum ClientNames { + Brasil = 'brasil', Facr = 'facr', India = 'india', Insports = 'insports', Instat = 'instat', Lff = 'lff', - Tunis = 'tunis', + Tunisia = 'tunisia' } export type ClientConfig = { @@ -30,6 +31,8 @@ export type ClientConfig = { }, defaultLanguage: string, description: string, + disabledFilters?: boolean, + disabledHighlights?: boolean, disabledPreferences?: boolean, name: ClientNames, privacyLink: string, diff --git a/src/config/currencies.tsx b/src/config/currencies.tsx index 65d9066f..2471f257 100644 --- a/src/config/currencies.tsx +++ b/src/config/currencies.tsx @@ -12,5 +12,6 @@ export const currencySymbols = { KZT: '₸', MDL: 'L', RUB: '₽', + TND: 'TND', USD: '$', } as const diff --git a/src/config/lexics/joinMatch.tsx b/src/config/lexics/joinMatch.tsx index 15d9b05c..01d61260 100644 --- a/src/config/lexics/joinMatch.tsx +++ b/src/config/lexics/joinMatch.tsx @@ -1,4 +1,8 @@ export const joinMatchLexics = { + diwan_desc: 20035, + diwan_join: 20037, + diwan_season: 19983, + diwan_title: 20036, join_insports_tv: 15420, join_now: 15422, promo_text: 15421, diff --git a/src/config/lexics/payment.tsx b/src/config/lexics/payment.tsx index fc1e0580..0a2e8a9f 100644 --- a/src/config/lexics/payment.tsx +++ b/src/config/lexics/payment.tsx @@ -19,6 +19,7 @@ export const paymentLexics = { error_empty_name: 15290, error_empty_state: 19821, error_payment_unsuccessful: 14446, + failed_paymee: 20046, if_you_cancel: 18189, is_gpay: 20045, next_payment: 18183, @@ -27,6 +28,7 @@ export const paymentLexics = { payment_date: 15603, payment_method: 2010, pb_instat: 18274, + processing: 722, save_sub: 18190, state: 12932, still_cancel: 2646, diff --git a/src/config/pages.tsx b/src/config/pages.tsx index b692e38b..16552b2a 100644 --- a/src/config/pages.tsx +++ b/src/config/pages.tsx @@ -1,5 +1,6 @@ export const PAGES = { about_the_project: 'https://instatsport.com/InStatTV/ott_platform', + failedPaymee: '/failed-paymee', highlights: '/highlights', home: '/', mailings: '/useraccount/mailings', diff --git a/src/config/payments.tsx b/src/config/payments.tsx new file mode 100644 index 00000000..29aba071 --- /dev/null +++ b/src/config/payments.tsx @@ -0,0 +1,22 @@ +import { ClientNames } from './clients/types' + +export enum PaymentSystem { + PagBrazil = 'pag_brasil', + Paymee = 'paymee', + Paytm = 'paytm', + Stripe = 'stripe' +} + +type PaymentsType = { + [key in ClientNames]: PaymentSystem +} + +export const payments: PaymentsType = { + [ClientNames.Tunisia]: PaymentSystem.Paymee, + brasil: PaymentSystem.PagBrazil, + [ClientNames.India]: PaymentSystem.Paytm, + [ClientNames.Insports]: PaymentSystem.Stripe, + [ClientNames.Instat]: PaymentSystem.Stripe, + [ClientNames.Facr]: PaymentSystem.Stripe, + [ClientNames.Lff]: PaymentSystem.Stripe, +} diff --git a/src/features/App/AuthenticatedApp.tsx b/src/features/App/AuthenticatedApp.tsx index d8dc320f..34bf7e00 100644 --- a/src/features/App/AuthenticatedApp.tsx +++ b/src/features/App/AuthenticatedApp.tsx @@ -40,6 +40,7 @@ const HighlightsPage = lazy(() => import('pages/HighlightsPage')) const ThanksPage = lazy(() => import('pages/ThanksPage')) const Mailings = lazy(() => import('pages/Mailings')) +const FailedPaymeePage = lazy(() => import('pages/FailedPaymeePage')) export const AuthenticatedApp = () => { useLexicsConfig(indexLexics) @@ -66,6 +67,9 @@ export const AuthenticatedApp = () => { + + + diff --git a/src/features/AuthServiceApp/config/clients/index.tsx b/src/features/AuthServiceApp/config/clients/index.tsx index 6de84332..f29566c8 100644 --- a/src/features/AuthServiceApp/config/clients/index.tsx +++ b/src/features/AuthServiceApp/config/clients/index.tsx @@ -5,7 +5,7 @@ import { insports } from './insports' import { instat } from './instat' import { lff } from './lff' import { india } from './india' -import { tunis } from './tunis' +import { tunisia } from './tunisia' const clients = { [ClientIds.Facr]: facr, @@ -13,7 +13,7 @@ const clients = { [ClientIds.Lff]: lff, [ClientIds.Insports]: insports, [ClientIds.India]: india, - [ClientIds.Tunis]: tunis, + [ClientIds.Tunisia]: tunisia, } const params = new URLSearchParams(window.location.search) diff --git a/src/features/AuthServiceApp/config/clients/tunis.tsx b/src/features/AuthServiceApp/config/clients/tunisia.tsx similarity index 85% rename from src/features/AuthServiceApp/config/clients/tunis.tsx rename to src/features/AuthServiceApp/config/clients/tunisia.tsx index b587b6e8..b6b7922e 100644 --- a/src/features/AuthServiceApp/config/clients/tunis.tsx +++ b/src/features/AuthServiceApp/config/clients/tunisia.tsx @@ -1,6 +1,6 @@ import styled, { css } from 'styled-components/macro' -import { tunis as platformTunis } from 'config/clients/tunis' +import { tunisia as platformTunis } from 'config/clients/tunisia' import { isMobileDevice } from 'config/userAgent' import type { ClientConfig } from './types' @@ -16,7 +16,7 @@ const Background = styled.div` radial-gradient(152.89% 271.81% at 0% 96.71%, #2AB7AA 3.27%, #02505C 43.69%, #0B2E4D 100%); ` -export const tunis: ClientConfig = { +export const tunisia: ClientConfig = { ...platformTunis, background: Background, styles: { @@ -49,9 +49,10 @@ export const tunis: ClientConfig = { margin-bottom: 1.82rem; ${isMobileDevice ? css` - margin-bottom: 20px; - width: 130px; - height: 100px; + background-image: url(/images/tunis_auth_logo_mobile.svg); + margin-bottom: 20px; + width: 102px; + height: 75px; ` : ''} `, popupApplyButton: css` diff --git a/src/features/AuthStore/helpers.tsx b/src/features/AuthStore/helpers.tsx index d9d1f050..c2fd3612 100644 --- a/src/features/AuthStore/helpers.tsx +++ b/src/features/AuthStore/helpers.tsx @@ -22,11 +22,11 @@ export interface Settings extends UserManagerSettings { export const getClientNameByRedirectUri = () => { switch (client.name) { case ClientNames.Lff: - return 'lff.instat' + return 'lff.insports' case ClientNames.India: return 'india.insports' - case ClientNames.Tunis: - return ClientNames.Tunis + case ClientNames.Tunisia: + return 'diwan.insports' case ClientNames.Facr: return ClientNames.Facr case ClientNames.Instat: @@ -44,7 +44,7 @@ const redirectUrl = () => { || client.name === 'lff' || client.name === 'facr' || client.name === 'india' - || client.name === 'tunis' + || client.name === 'tunisia' ): return `${window.origin}/redirect` case (ENV === 'staging' || ENV === 'preproduction'): diff --git a/src/features/BuyMatchPopup/components/BrazilPayment/hooks.tsx b/src/features/BuyMatchPopup/components/BrazilPayment/hooks.tsx deleted file mode 100644 index e41d1e70..00000000 --- a/src/features/BuyMatchPopup/components/BrazilPayment/hooks.tsx +++ /dev/null @@ -1,101 +0,0 @@ -import { - useEffect, - useState, - MouseEvent, -} from 'react' - -import { useHistory } from 'react-router-dom' - -import { ProfileTypes } from 'config' - -import isNumber from 'lodash/isNumber' - -import { useLexicsStore } from 'features/LexicsStore' -import { useBuyMatchPopupStore } from 'features/BuyMatchPopup/store' -import { getProfileUrl } from 'features/ProfileLink/helpers' - -import { getMatchInfo } from 'requests/getMatchInfo' -import { getBrazilPaymentUrl } from 'requests/getBrazilPaymentUrl' - -import type { Props } from './index' - -type ResponsePayment = { - url: string, -} - -type ResponsePaymentArray = ResponsePayment | null - -export const useBrazilPayment = ({ - match, - open, - selectedPackage, - setIsOpenBrasilian, -}: Props) => { - const history = useHistory() - const { close } = useBuyMatchPopupStore() - - const [src, setSrc] = useState('') - const [error, setError] = useState('') - const { translate } = useLexicsStore() - - const { id, sportType } = match - - const { - name, - nameLexic, - originalObject, - pass, - } = selectedPackage - - const teams = isNumber(nameLexic) ? translate(String(nameLexic)) : name - const pack = translate(String(pass)) - - const matchLink = getProfileUrl({ - id, - profileType: ProfileTypes.MATCHES, - sportType, - }) - - const closePopup = async (e?: MouseEvent) => { - e?.stopPropagation() - setIsOpenBrasilian(false) - setError('') - - const accessMatch = await getMatchInfo(sportType, id) - if (accessMatch?.access) { - close() - history.push(matchLink) - } - } - - // eslint-disable-next-line - window.onmessage = function (event) { - if (event.data === 'close') { - closePopup() - } - } - useEffect(() => { - if (open) { - (async () => { - try { - const json: ResponsePaymentArray = await getBrazilPaymentUrl({ - action: pass === 'pass_match_access' ? 'one_payment' : 'create_subscription', - item: originalObject, - product_name: `${pack} ${teams}`, - }) - setSrc(json?.url || '') - } catch (err) { - setError('error_payment_unsuccessful') - } - })() - } - // eslint-disable-next-line react-hooks/exhaustive-deps - }, [selectedPackage, open]) - - return { - closePopup, - error, - matchLink, - src, - } -} diff --git a/src/features/BuyMatchPopup/components/ErrorStep/index.tsx b/src/features/BuyMatchPopup/components/ErrorStep/index.tsx index c9b662a6..461d99c0 100644 --- a/src/features/BuyMatchPopup/components/ErrorStep/index.tsx +++ b/src/features/BuyMatchPopup/components/ErrorStep/index.tsx @@ -17,13 +17,13 @@ export const ErrorStep = () => { } = useBuyMatchPopupStore() return ( - +
- + {paymentError || } diff --git a/src/features/BuyMatchPopup/components/IframePayment/hooks.tsx b/src/features/BuyMatchPopup/components/IframePayment/hooks.tsx new file mode 100644 index 00000000..2cd13cc4 --- /dev/null +++ b/src/features/BuyMatchPopup/components/IframePayment/hooks.tsx @@ -0,0 +1,173 @@ +import { + MouseEvent, + useCallback, + useEffect, + useState, +} from 'react' + +import { PAGES, ProfileTypes } from 'config' +import { ClientNames } from 'config/clients/types' +import { payments, PaymentSystem } from 'config/payments' + +import isNumber from 'lodash/isNumber' + +import { useLexicsStore } from 'features/LexicsStore' +import { useBuyMatchPopupStore } from 'features/BuyMatchPopup/store' +import { getProfileUrl } from 'features/ProfileLink/helpers' + +import { getMatchInfo } from 'requests/getMatchInfo' +import { getPaymentUrl } from 'requests/getPaymentUrl' + +import { redirectToUrl } from 'helpers' + +import type { Props } from './index' + +type ResponsePayment = { + url: string, +} + +type ResponsePaymentArray = ResponsePayment | null + +export const useIframePayment = ({ + match, + open, + paymentSystem, + selectedPackage, + setIsOpenIframe, +}: Props) => { + const { close } = useBuyMatchPopupStore() + + const [src, setSrc] = useState('') + const [error, setError] = useState('') + const [isPaymentProcessing, setIsPaymentProcessing] = useState(false) + const { translate } = useLexicsStore() + + const { id, sportType } = match + + const { + name, + nameLexic, + originalObject, + pass, + } = selectedPackage + + const teams = isNumber(nameLexic) ? translate(String(nameLexic)) : name + const pack = translate(String(pass)) + + const matchLink = getProfileUrl({ + id, + profileType: ProfileTypes.MATCHES, + sportType, + }) + + const closePopup = useCallback(async (e?: MouseEvent) => { + e?.stopPropagation() + + if (error) { + setIsOpenIframe(false) + setError('') + } + + const accessMatch = await getMatchInfo(sportType, id) + if (accessMatch?.access) { + setIsPaymentProcessing(false) + setIsOpenIframe(false) + setError('') + close() + redirectToUrl(matchLink) + } + }, [close, error, id, matchLink, setIsOpenIframe, sportType]) + + const paymentRequest = async () => { + let url_cancel + let url_return + let action: Parameters[0]['action'] + + switch (paymentSystem) { + case PaymentSystem.Paymee: + url_cancel = `${window.origin}/failed-paymee` + url_return = null + // paymee не умеет работать с подписками + action = 'one_payment' + break + default: + url_return = `${window.location.origin}${PAGES.thanksForSubscribe}` + action = pass === 'pass_match_access' ? 'one_payment' : 'create_subscription' + break + } + + const payment: ResponsePaymentArray = await getPaymentUrl({ + action, + item: originalObject, + product_name: `${pack} ${teams}`, + service: paymentSystem, + url_cancel, + url_return, + }) + setSrc(payment?.url || '') + } + + if (paymentSystem === payments[ClientNames.Brasil]) { + // eslint-disable-next-line + window.onmessage = function (event) { + if (event.data === 'close') { + closePopup() + } + } + } + + useEffect(() => { + let interval: ReturnType + let timeout: ReturnType + + const paymentCallback = (event: MessageEvent<{ event_id: string }>) => { + if (event.data.event_id === 'paymee.complete') { + setIsPaymentProcessing(true) + interval = setInterval(() => closePopup(), 2000) + timeout = setTimeout(() => { + clearInterval(interval) + setIsPaymentProcessing(false) + setError('failed_paymee') + setSrc('') + }, 60000) + } + } + if (paymentSystem === payments[ClientNames.Tunisia]) { + window.addEventListener( + 'message', + paymentCallback, + false, + ) + } + return () => { + window.removeEventListener( + 'message', + paymentCallback, + false, + ) + clearInterval(interval) + clearTimeout(timeout) + } + }, [closePopup, paymentSystem]) + + useEffect(() => { + if (open) { + (async () => { + try { + await paymentRequest() + } catch (err) { + setError('error_payment_unsuccessful') + } + })() + } + // eslint-disable-next-line react-hooks/exhaustive-deps + }, [selectedPackage, open]) + + return { + closePopup, + error, + isPaymentProcessing, + matchLink, + src, + } +} diff --git a/src/features/BuyMatchPopup/components/BrazilPayment/index.tsx b/src/features/BuyMatchPopup/components/IframePayment/index.tsx similarity index 52% rename from src/features/BuyMatchPopup/components/BrazilPayment/index.tsx rename to src/features/BuyMatchPopup/components/IframePayment/index.tsx index 7cd1abc0..c4bbe528 100644 --- a/src/features/BuyMatchPopup/components/BrazilPayment/index.tsx +++ b/src/features/BuyMatchPopup/components/IframePayment/index.tsx @@ -2,7 +2,10 @@ import { Loader } from 'features/Loader' import { MatchPackage, Match } from 'features/BuyMatchPopup/types' import { T9n } from 'features/T9n' -import { useBrazilPayment } from './hooks' +import { PaymentSystem } from 'config/payments' +import { isMobileDevice } from 'config' + +import { useIframePayment } from './hooks' import { LoaderWrapper, @@ -12,35 +15,38 @@ import { export type Props = { match: Match, open: boolean, + paymentSystem: PaymentSystem, selectedPackage: MatchPackage, - setIsOpenBrasilian: (open: boolean) => void, + setIsOpenIframe: (open: boolean) => void, } -export const BrazilPayment = ({ +export const IframePayment = ({ match, open, + paymentSystem, selectedPackage, - setIsOpenBrasilian, + setIsOpenIframe, }: Props) => { const { - closePopup, error, + isPaymentProcessing, src, - } = useBrazilPayment({ + } = useIframePayment({ match, open, + paymentSystem, selectedPackage, - setIsOpenBrasilian, + setIsOpenIframe, }) return ( - + setIsOpenIframe(false)}> {src && open ? (