bdominguez
    • Create new note
    • Create a note from template
      • Sharing URL Link copied
      • /edit
      • View mode
        • Edit mode
        • View mode
        • Book mode
        • Slide mode
        Edit mode View mode Book mode Slide mode
      • Customize slides
      • Note Permission
      • Read
        • Only me
        • Signed-in users
        • Everyone
        Only me Signed-in users Everyone
      • Write
        • Only me
        • Signed-in users
        • Everyone
        Only me Signed-in users Everyone
      • Engagement control Commenting, Suggest edit, Emoji Reply
    • Invite by email
      Invitee

      This note has no invitees

    • Publish Note

      Share your work with the world Congratulations! 🎉 Your note is out in the world Publish Note

      Your note will be visible on your profile and discoverable by anyone.
      Your note is now live.
      This note is visible on your profile and discoverable online.
      Everyone on the web can find and read all notes of this public team.
      See published notes
      Unpublish note
      Please check the box to agree to the Community Guidelines.
      View profile
    • Commenting
      Permission
      Disabled Forbidden Owners Signed-in users Everyone
    • Enable
    • Permission
      • Forbidden
      • Owners
      • Signed-in users
      • Everyone
    • Suggest edit
      Permission
      Disabled Forbidden Owners Signed-in users Everyone
    • Enable
    • Permission
      • Forbidden
      • Owners
      • Signed-in users
    • Emoji Reply
    • Enable
    • Versions and GitHub Sync
    • Note settings
    • Note Insights New
    • Engagement control
    • Make a copy
    • Transfer ownership
    • Delete this note
    • Save as template
    • Insert from template
    • Import from
      • Dropbox
      • Google Drive
      • Gist
      • Clipboard
    • Export to
      • Dropbox
      • Google Drive
      • Gist
    • Download
      • Markdown
      • HTML
      • Raw HTML
Menu Note settings Note Insights Versions and GitHub Sync Sharing URL Create Help
Create Create new note Create a note from template
Menu
Options
Engagement control Make a copy Transfer ownership Delete this note
Import from
Dropbox Google Drive Gist Clipboard
Export to
Dropbox Google Drive Gist
Download
Markdown HTML Raw HTML
Back
Sharing URL Link copied
/edit
View mode
  • Edit mode
  • View mode
  • Book mode
  • Slide mode
Edit mode View mode Book mode Slide mode
Customize slides
Note Permission
Read
Only me
  • Only me
  • Signed-in users
  • Everyone
Only me Signed-in users Everyone
Write
Only me
  • Only me
  • Signed-in users
  • Everyone
Only me Signed-in users Everyone
Engagement control Commenting, Suggest edit, Emoji Reply
  • Invite by email
    Invitee

    This note has no invitees

  • Publish Note

    Share your work with the world Congratulations! 🎉 Your note is out in the world Publish Note

    Your note will be visible on your profile and discoverable by anyone.
    Your note is now live.
    This note is visible on your profile and discoverable online.
    Everyone on the web can find and read all notes of this public team.
    See published notes
    Unpublish note
    Please check the box to agree to the Community Guidelines.
    View profile
    Engagement control
    Commenting
    Permission
    Disabled Forbidden Owners Signed-in users Everyone
    Enable
    Permission
    • Forbidden
    • Owners
    • Signed-in users
    • Everyone
    Suggest edit
    Permission
    Disabled Forbidden Owners Signed-in users Everyone
    Enable
    Permission
    • Forbidden
    • Owners
    • Signed-in users
    Emoji Reply
    Enable
    Import from Dropbox Google Drive Gist Clipboard
       Owned this note    Owned this note      
    Published Linked with GitHub
    • Any changes
      Be notified of any changes
    • Mention me
      Be notified of mention me
    • Unsubscribe
    # Migración Tricao ## Front End #### Home - Banner de noticias: https://dev-api.tricao.cl/v1/news_banners - Horarios del parque (en todas las vistas al ser parte del footer): https://dev-api.tricao.cl/v1/park_availabilities Hacer queries de todas las noticias y de los horarios del parque. #### Fundación - Posts del Blog: https://dev-api.tricao.cl/v1/foundations?page=1&per_page=20&status=published&date= En esta es necesario hacer un simple query de todas las fundaciones (noticias). El resto de la información de la vista puede ser escrita en el mismo frontend. #### Horarios y precios Actualmente está la info en el Front, se debería exponer un endPoint en la API. Es necesario hacer un query de los horarios disponibles (que siempre son 2) (aunque quizas simplemente usa la request del footer para no hacer la request 2 veces). También es necesario hacer un query de todos los tipos de entrada, anidandoló con una posible nueva entidad (PROPUESTA DE CAMBIO) de entrada (id, entrance_type_id, age_group, precio) Por último, hacer un query sobre los tipos de actividades (Experiencias y Quincho) y realizar una query anidada para conseguir todas los eventos tipo Experiencia (Kayak, Raft Ride, Beach, Bicycle, etc). #### Experiencias -> Actividades Actualmente está la info en el Front, se debería exponer un endPoint en la API. ƒ - Al ingresar a una experiencia: https://dev-api.tricao.cl/v1/activity_types El request entrega mucha información incluyendo la informacion de todas las experiencias, en `data` están Experiencia y Quincho, y en `include` están las demás actividades. Lo otro sería hacer un query sobre todos los eventos tipo Experiencia. #### Cómo llegar No usa info de la API. #### Historia No usa info de la API. #### Actividades -> Eventos - Categorias: https://dev-api.tricao.cl/v1/tags - Eventos: https://dev-api.tricao.cl/v1/events?page=1&per_page=2&status=true&month=12&tag= (array vacío) Realizar una query simple #### Preguntas frecuentes No usa info de la API (no es necesario). #### Portal de ayuda - No usa info de la API. - Mailer #### Flujo de compra **Vista 1: Calendario:** - Dias disponibles: https://dev-api.tricao.cl/v1/open_days - Riesgos: https://dev-api.tricao.cl/v1/configuration_parameters/risk - Terminos y condiciones: https://dev-api.tricao.cl/v1/configuration_parameters/terms - Condiciones de cancelación: https://dev-api.tricao.cl/v1/configuration_parameters/cancellation_policy - Capacidad del parque: https://dev-api.tricao.cl/v1/configuration_parameters/park_capacity - Oversold: https://dev-api.tricao.cl/v1/configuration_parameters/oversold En esta vista es posible hacer un query sobre todos los días disponibles desde la fecha actual en adelante, dado que hay días guardados desde el 2019. Risks, terms y cancellation policy retornan un JSON con atributo *text* que contiene todo el HTML correspondiente. **Vista 2: Entradas** - Tipos de entradas para una fecha: https://dev-api.tricao.cl/v1/entrance_ticket_types?date=fecha - Tipos de actividades para una fecha: https://dev-api.tricao.cl/v1/activity_types?date=fecha Hacer una query sobre todos los tipos de entradas, anidando los detalles y condiciones según el id del tipo de entrada. *** **Vista 3: Client Form** - Get Info del cliente by rut: https://dev-api.tricao.cl/v1/clients/get_client_by_rut?rut=rut **Vista 4: Checkout** - On Click button, create tricao purchase: https://dev-api.tricao.cl/v1/purchases/tricao_purchase - Flujo WebPay - Transaction status #### Cambios y devoluciones - Obtener información para cambios/devoluciones a partir de un numero de compra: https://dev-api.tricao.cl/v1/refund/get_info_for_refund?rut=1.956.787-7&order_number=54921&foreigner=false **Si es cambio** - Revisar disponibilidad de entrada para la nueva fecha: https://dev-api.tricao.cl/v1/activity_types?date=07-11-2021 - Realizar cambio: https://dev-api.tricao.cl/v1/refund/change **Si es devolución** - Get all banks: https://dev-api.tricao.cl/v1/refund/all_banks - Get info for refund: https://dev-api.tricao.cl/v1/refund/get_info_for_refund?rut=1.956.787-7&order_number=54921&foreigner=false - Crear solicitud de devolución: https://dev-api.tricao.cl/v1/refund/create_request ## Backoffice #### Dashboard - Información autos: https://dev-api.tricao.cl/v1/vehicle_entrances/actual_cars_info - Total entradas vendidas para hoy: https://dev-api.tricao.cl/v1/purchase_qr_scans/calendar_report?date=[Date] (Ej: Thu%20Dec%2016%202021%2011:04:54%20GMT-0300%20(hora%20de%20verano%20de%20Chile)) - Visitas hoy: https://dev-api.tricao.cl/v1/purchase_qr_scans/visits_today (Request entrega error 500) - #### Admin Dashboard - Procentaje de ocupacion por visitas https://dev-api.tricao.cl/v1/charts/visits?months=1 - Cantidad general de venta de tickets: https://dev-api.tricao.cl/v1/charts/general_tickets?months=6 - Porcentaje de venta de tickets por actividades: https://dev-api.tricao.cl/v1/charts/tickets_by_activity?months=6 (Harcoded request entrega error 500) #### Ventas - Pestaña 1: Ventas - __/purchases/total_purchases_by_user__ o __/purchases/purchases_by_user?page=number__ Se consiguen todas las ventas realizadas ese día desde __user_purchases__ (tabla intermedia N:N que conecta __purchases__ con __users__) En cuanto a la response "total_purchases_number" le calbiaría el nombre a "total_pages_number" al momento de hacer la paginación - Pestaña 2: Reporte de Ventas - __/purchases/report__ Se consigue el número de ventas del día y se diferencia entre las de crédito y las de debito. - __/purchases/users__ Consigue a todos los usuarios para listrlos cuando el tipo de ventas se setea en "Ventas en el parque" (aparece un dropdown de usuarios) #### Portería - #### Pestaña 1: Validación de tickets - Información tickets: https://dev-api.tricao.cl/v1/purchase_qr_scans/ticket_index?page=1&per_page=30&date=&order=&rut= - Cantidad tickets: https://dev-api.tricao.cl/v1/purchase_qr_scans/ticket_index_count?page=1&per_page=30&date=&order=&rut= (Endpoint innecesario) - Tickets escaneados: https://dev-api.tricao.cl/v1/purchase_qr_scans/ticket_last_scan - En esta parte esta la opción de ingresar un código QR, que llama al endpoint: **/purchase_qr_scans/** que verifica si es un token válido. - #### Pestaña 2: Entrada de autos - Tickets de hoy: **/vehicle_entrances/todays_entries** - En esta vista se da la opción de ingresar una entrada de auto que llama a **/vehicle_entrances/create_vehicle_entry** - #### Pestaña 3: Salida de autos - Tickets de hoy: **/vehicle_entrances/todays_exits** - En esta vista se da la opción de ingresar una salida de auto que llama a **/vehicle_entrances/vehicle_exit** #### Tickets - Pestaña 1: Historial de Validaciones - __/purchases_qr_scans/ticket_index__ Consigue un array de todos los tickets comprados ese día (actividades + entradas), luego los lista y los pagina. - __/purchases_qr_scans/ticket_index_count__ Hace exactamente lo mismo que el endpoint de arriba, pero cuenta la canitdad total de tickets vendidos El último endpoint mencionado acá es innecesario, se puede hacer todo en un mismo endpoint o se puede contar en frontend. - Pestaña 2: Reservaciones - __/reservations?page=number__ Busca todas las reservas según los query params (_date_, _rut_, _order_number_, _ticket_type_). En caso de que no sean provistos, no entrga nada. - __/reservations/total_count__ Ejecuta el mismo código que el de arriba, pero retorna el total (número) de reservas. El último endpoint mencionado acá es innecesario, se puede hacer todo en un mismo endpoint o se puede contar en frontend. - Pestaña 3: Devoluciones - __/refund__ Consigue todos los reembolsos según los query params (_order_ [purchase_id], _email_, _rut_, _foreigner_, _start_date_) - __/refund/all_banks__ Consigue una lista de todos los bancos guardados en las seeds. El nombre del endpoint puede ser mejor en plural. #### Códigos (promocionales) - Codigos: - __/promotion_codes/all_promotions__ Retorna una lista con todas las promociones y sus respectivos códigos - __/promotion_codes/total_promotions_number__ Retorna la cantidad total de códigos y cantidad de promociones (status opcional) - Crear nuevo codigo: - __/activity_types__ - __/entrance_ticket_type__ Retorna una lista con los tipos de entrada (Entrada General, Pase Semestral, Entrada General + Aviario, Entrada General + Jardín Botánico) - __POST promotion_codes/generate_codes/__ Se le entrega maxTickets y percentageDiscount por cada ticket type #### Database - __/clients__ Muestra una lista paginada de todos los clientes. Algunos query params son fijos (_per_page_) o ni siquiera se da la opción de setearlos (_rut_, _first_name_, _last_name_). #### Usuarios - **/users** Muestra todos los usuarios registrados y sus atributos (_email_, _first_name_, _last_name_, _creator, user_role_) - Si se va a _Crear Nuevo Usuario_: - **/user_roles** Retorna todos los roles posibles de los usuarios (Admin, Operator, Porteria) #### Cargar Excel - Entrega todos los archivos de entrada creo: **/entrances/get_all_entrance_files** - Al cargar archivo: **/entrances/upload_entrances** (PATCH) #### Configuración - Pestaña 1: Disponibilidad - __/open_days__ Consigue un arreglo de todos los días en que está abierto (seteado en seeds). - Pestaña 2: Tickets - __/configuration_parameters/park_capacity__ Entrega el valor numerico de la capacidad - __/entrance_ticket_types__ Muestra los tipos de entradas. - __/activity_types__ Retorna todos los tipos de actividades No es posible visualizar esta página en algunos navegadores se muestra en blanco (hasta ahora el unico que lo muestra bien es Firefox). - Pestaña 3: Términos y condiciones Aqui se puede configurar valores del endpoint de _/configuration_parameters_ que son autoexplicativos - __/risk__ - __/terms__ - __/cancellation_policy__ - Pestaña 4: Actividades - __/events?page=1&per_page=5&status=&month=&tag=__ Aqui entrega los activities dependiendo del pagination y los status elejidos por el usuario (_Todos, Publicadas, Deshabilitadas_) - __/events/total_events_number__ Retorna el numero total de eventos - Pestaña 5: Horarios - __/park_availabilities__ Retorna la disponibilidad del parque, es decir, el horario en verano e invierno. Al setear nuevos horarios se manda lo siguiente: - __PUT /park_availabilities/1__ - __PUT /park_availabilities/2__ Junto con los nuevos horarios en el request - Pestaña 6: Banner de noticias - __/news_banners__ Retornar el banner con su texto, fechas y su visibilidad - __PATCH /update_news_banner__ Actualiza el texto y su visibilidad #### Fundación (noticias de fundacion) - Fundación: - __foundations/__ Retorna una lista con todas las foundations - __total_fundations_numbers/__ Retorna la cantidad de foundations - Crear nueva noticia: - __POST fundations/__ (titulo, fecha, texto y status) #### Pase bicicleta - Pase bicicleta: - __bicycle_passes/__ Retorna start y end time del pase, y la información del cliente que le pertenece el pase. (end_time = start_time + 1 mes?) - Creacion pase: - __bicycle_client/__ Se entregan los datos del cliente y la fecha de comienzo del pase. #### Envío de mail - __/announcements/activities_list__ retorna todos los tipos de actividad (Aviario, Quincho1, Quincho2, etc...) - __/announcements/email_getters?start_date=23-12-2021&end_date=25-12-2021&activities=__ Retorna los emails asociados segun los parametros de la query como las actividades relacionadas y el rango de fechas. (Ej:announcements/email_getters?start_date=23-12-2021&end_date=25-12-2021&activities=Kayak,Canopy,Quincho02)

    Import from clipboard

    Paste your markdown or webpage here...

    Advanced permission required

    Your current role can only read. Ask the system administrator to acquire write and comment permission.

    This team is disabled

    Sorry, this team is disabled. You can't edit this note.

    This note is locked

    Sorry, only owner can edit this note.

    Reach the limit

    Sorry, you've reached the max length this note can be.
    Please reduce the content or divide it to more notes, thank you!

    Import from Gist

    Import from Snippet

    or

    Export to Snippet

    Are you sure?

    Do you really want to delete this note?
    All users will lose their connection.

    Create a note from template

    Create a note from template

    Oops...
    This template has been removed or transferred.
    Upgrade
    All
    • All
    • Team
    No template.

    Create a template

    Upgrade

    Delete template

    Do you really want to delete this template?
    Turn this template into a regular note and keep its content, versions, and comments.

    This page need refresh

    You have an incompatible client version.
    Refresh to update.
    New version available!
    See releases notes here
    Refresh to enjoy new features.
    Your user state has changed.
    Refresh to load new user state.

    Sign in

    Forgot password

    or

    By clicking below, you agree to our terms of service.

    Sign in via Facebook Sign in via Twitter Sign in via GitHub Sign in via Dropbox Sign in with Wallet
    Wallet ( )
    Connect another wallet

    New to HackMD? Sign up

    Help

    • English
    • 中文
    • Français
    • Deutsch
    • 日本語
    • Español
    • Català
    • Ελληνικά
    • Português
    • italiano
    • Türkçe
    • Русский
    • Nederlands
    • hrvatski jezik
    • język polski
    • Українська
    • हिन्दी
    • svenska
    • Esperanto
    • dansk

    Documents

    Help & Tutorial

    How to use Book mode

    Slide Example

    API Docs

    Edit in VSCode

    Install browser extension

    Contacts

    Feedback

    Discord

    Send us email

    Resources

    Releases

    Pricing

    Blog

    Policy

    Terms

    Privacy

    Cheatsheet

    Syntax Example Reference
    # Header Header 基本排版
    - Unordered List
    • Unordered List
    1. Ordered List
    1. Ordered List
    - [ ] Todo List
    • Todo List
    > Blockquote
    Blockquote
    **Bold font** Bold font
    *Italics font* Italics font
    ~~Strikethrough~~ Strikethrough
    19^th^ 19th
    H~2~O H2O
    ++Inserted text++ Inserted text
    ==Marked text== Marked text
    [link text](https:// "title") Link
    ![image alt](https:// "title") Image
    `Code` Code 在筆記中貼入程式碼
    ```javascript
    var i = 0;
    ```
    var i = 0;
    :smile: :smile: Emoji list
    {%youtube youtube_id %} Externals
    $L^aT_eX$ LaTeX
    :::info
    This is a alert area.
    :::

    This is a alert area.

    Versions and GitHub Sync
    Get Full History Access

    • Edit version name
    • Delete

    revision author avatar     named on  

    More Less

    Note content is identical to the latest version.
    Compare
      Choose a version
      No search result
      Version not found
    Sign in to link this note to GitHub
    Learn more
    This note is not linked with GitHub
     

    Feedback

    Submission failed, please try again

    Thanks for your support.

    On a scale of 0-10, how likely is it that you would recommend HackMD to your friends, family or business associates?

    Please give us some advice and help us improve HackMD.

     

    Thanks for your feedback

    Remove version name

    Do you want to remove this version name and description?

    Transfer ownership

    Transfer to
      Warning: is a public team. If you transfer note to this team, everyone on the web can find and read this note.

        Link with GitHub

        Please authorize HackMD on GitHub
        • Please sign in to GitHub and install the HackMD app on your GitHub repo.
        • HackMD links with GitHub through a GitHub App. You can choose which repo to install our App.
        Learn more  Sign in to GitHub

        Push the note to GitHub Push to GitHub Pull a file from GitHub

          Authorize again
         

        Choose which file to push to

        Select repo
        Refresh Authorize more repos
        Select branch
        Select file
        Select branch
        Choose version(s) to push
        • Save a new version and push
        • Choose from existing versions
        Include title and tags
        Available push count

        Pull from GitHub

         
        File from GitHub
        File from HackMD

        GitHub Link Settings

        File linked

        Linked by
        File path
        Last synced branch
        Available push count

        Danger Zone

        Unlink
        You will no longer receive notification when GitHub file changes after unlink.

        Syncing

        Push failed

        Push successfully