Giter Club home page Giter Club logo

monosparta-diving-server's Introduction

Dive In Taiwan - Server

This is a project in a trainee program of Mono-Sparta. It's an APP about diving. The project is basded on Laravel Framework 5.8.28

Installation

Windows

  1. Install VirtualBox

  2. Install Vagrant

  3. Install homestead
    All of requirements are in this virtual machine.

    $ vagrant box add laravel/homestead

  4. Install Composer
    It's a package for PHP.

  5. Setup laravel for composer

    $ composer require "laravel/homestead"

Make sure to place composer's system-wide vendor bin directory in your PATH so the laravel executable can be located by your system. > This directory exists in different locations based on your operating system; however, some common locations include: %USERPROFILE%\AppData\Roaming\Composer\vendor\bin 

  1. Start a new laravel project

    $ laravel new projectName

  2. Test
    http://127.0.0.1/projectName/public/

If you still don't know how to install,please take laravel Installation as reference.

MacOS

  1. Install PHP

    $ brew install php

  2. Install Composer

  3. Install Laravel

  4. Install Laravel with Composer

    $ composer global require “laravel/installer”

Make sure to place composer's system-wide vendor bin directory in your PATH so the laravel executable can be located by your system. This directory exists in different locations based on your operating system; however, some common locations include: $HOME/.composer/vendor/bin 

  1. Start a new laravel project

    $ laravel new projectName

  2. Install Valet
    Please take laravel Valet as reference.

Project Architecture

NAME PATH DESCRIPTION
Models of Database Table /app Article,Comment,Log,Shop,Spot,and User model
Controllers /app/Http/Controllers Article and Comment controller. Main is in TaskController.php
Routes /routes/api.php Search,Article,and Comment routes
Database /database migrations,seeds,factories

Restore Laravel Project

Because .gitignore will ignore some files,you must do this to restore the laravel project.
Open your terminal,direct PATH where you want to clone at,then follow commends below.

  1. git clone

    $ git clone https://github.com/MonospaceTW/monosparta-diving-server.git

  2. Reinstall composer
    It will reconstruction content in the index of vendor.

    $ cd monosparta-diving-server
    $ composer install

  3. Restore the index of node_modules

    $ npm install

  4. Restore .env

    $ cp .env.example .env
    $ php artisan key:generate

    Open .env,then check databese,username,and password are correct.
    For example,

    DB_HOST=127.0.0.1
    DB_PORT=3306
    DB_DATABASE=yourDatabaseName
    DB_USERNAME=yourUsername
    DB_PASSWORD=yourPassword
    

If you use Homestead,you need more steps.

  1. Restore Homestead.yaml

    $ php vendor/bin/homestead make

  2. Start Homestead

    $ vagrant up

  3. Sign in Homestead,and restore database

    $ vagrant ssh
    $ cd public_html/yourProjectName
    $ php artisan migrate

API Document

You can check API list at API Document.

monosparta-diving-server's People

Contributors

lukechu1997 avatar anntsai2356 avatar dependabot[bot] avatar bluet avatar

Stargazers

Fei avatar  avatar

Watchers

James Cloos avatar

monosparta-diving-server's Issues

(test)無限捲動綠寶石按鈕

我是使用者,我希望在寶石列表的頁面最下方置中的位置看到一個10*10px大小綠寶石樣式的按鈕,按下按鈕之後在向下瀏覽列表時都會開啟無限捲動功能,一次出現十筆寶石資料,同時加載下十筆寶石資料,直到所有結果都呈現完為止。

------------
首頁
可以被取消?
要開在前端
不同的使用情境有不同的使用方式?
角色是甚麼?
在什麼時候觸發功能?
詳細功能?
考慮角色後滿足兩個角色的需求

調整細項

  • 網站的欄位名稱web改成url
  • shop表單,改不同網站的欄位名稱,第一個欄位放官網(web),第二個欄位放粉專(FB)

(test)無限捲動紫寶石按鈕

@yinmin8610
PM-
在搜尋潛點結果列表頁面底部,在使用者可以滑到第15筆資料的時候出現一個無限捲動紫寶石按鈕,讓使用者點擊後可以無限滑動頁面,查看所有結果。
1.where 頁面位置
2.what 出現甚麼
3.why 存在意義
4.預期成果

Designer-
在哪個頁面需要放上甚麼功能、甚麼樣式的按鈕,按下去後會預期發生甚麼改變
1.按鈕功能
2.按鈕樣式
3.點擊後的結果

API: error handling

error code 400, 500

400 Bad Request : The request could not be understood or was missing required parameters.
500 Internal Server Error

資料庫:調整內容

前端發現一些潛點/潛店資料可以改進的地方,如下列表,請檢查資料庫內容

潛店圖片網址格式不正確 (無法抓到圖片)

  • 北部 :id 2 亞潮潛水

  • 3 巡航艦潛水

  • 8 橘子鯊潛水

  • 11(第1張) 愛潛水全方位潛水中心

  • 南部: id 59 墾丁環礁潛水中心

  • 64 放呆潛水俱樂部 (第1張)

  • 66 潛莊潛水渡假中心 (第2張)

潛店圖片無法顯示

  • 北部: id 7 海洋芒果潛水裝備專賣店 (第2~5張)

  • 16 潛水易購網 (第2~5張)

  • 中部: id 27 台中潛水訓練中心 (第2~3張)

潛店圖片重複

  • 中部: id 30 海洋芒果潛水裝備專賣店
  • 32 碧海藍天國際潛水飛行聯盟
  • 34 宇洋水上體育用品店 (1&2張)
  • 35 探險家戶外用品 (2&3張)
  • 37 海蛞蝓技術潛水訓練中心
  • 39 野蠻紮實潛水訓練中心 (1&2張)
  • 42 PADI威鯨潛水訓練中心 (2~4張)
  • 38 廣三SOGO努特生活館 與 35 探險家戶外用品 照片一樣

潛店圖片死圖

  • 中部: id 43 藍灣潛水訓練中心 (第4張)

潛店未放圖

  • 南部: id 墾丁新台北潛水中心 69

潛店網址連結錯誤

  • 外島 id 79 小琉球小綠龜潛水 FB網址錯誤 ( 少 http:// )
  • 南部 id 51 乖巧鯊潛水渡假村 url 連結已死
  • 中部 id 46 Go Diving趣潛水 FB連結為 "一個空白"
  • 29 乖巧鯊潛水訓練中心 url 網址錯誤 ( 少 http:// )

潛店名稱錯誤

  • 北部 id 15 NEREUS 加上 潛水貨倉

潛店網址 url 需 FB 跳轉

潛店地址重複 (縣市地區)

  • 北部: id 1~13
  • 離島 id 77

潛點圖片網址格式不正確 (無法抓到圖片)

  • 北部: id 1 野柳(第5張)

潛點圖片重複

  • 北部: id 1 野柳(1&2張)

API:加上分頁

分頁格式:
一頁15筆資料。

以下API需要加上分頁規則

  • Show spot search list
  • Show spot search with Location and Level
  • Show shop search list
  • Show shop search with Location and Level
  • Show article list
  • Show article category list

API:潛點潛店篩選後的分頁

潛點潛店篩選後的分頁無法正常運作

以下API需要更改分頁寫法

  • Show spot search with Location and Level
  • Show shop search with Location and Service

整理真實資料

資料項目可以在表單查看

  • Alice:離島
  • Brian:東部
  • Jasmine:北部
  • Ann:中部
  • Luke:南部

截止時間:8/7

優化UI

  • 定義服務網站名稱
  • 首頁搜尋bar改成全寬
  • 關鍵字搜尋完加上結果筆數
  • 評論加上時間
  • email改成聯絡我們
  • 知識header拿掉
  • 篩選結果 文章 補空狀態
  • 空白欄位寫“尚無資料”
  • 補齊錯誤頁面的字(等前後端確定)
  • 規劃User Testing
  • 架構圖3.0
  • 標準字設計
  • 導覽頁

API:更新API文件敘述

API文件

  • Show spot search list
  • Show spot search with Location and Level
  • Show certain spot
  • Show spot random list for home

  • Show shop search list
  • Show shop search with Location and Level
  • Show certain shop
  • Show shop random list for home

  • Show article list
  • Show article category list
  • show certain article detial
  • Show article random list for home

  • Spot/Shop/Article keyword search

  • Add comment
  • Delete comment

API:所有有關搜尋結果的都加上搜尋到的筆數

需要加上筆數的API

  • Show spot search list
  • Show spot search with Location and Level
  • Shop certain spot detail (comment total)
  • Show shop search list
  • Show shop search with Location and Level
  • Shop certain shop detail (comment total)
  • Spot/Shop/Article keyword search
  • Show article list
  • Show article category list

@yinmin8610 @ssiyang 我把需要用到筆數的API都可以顯示筆數了,你們可以去API文件測試,確認沒問題就在上面幫我打勾

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.