Merge branch 'master' into 'production'
Master See merge request Romulus21/portal!66
This commit is contained in:
@@ -10,8 +10,10 @@ services:
|
||||
- mysql:latest
|
||||
|
||||
variables:
|
||||
MYSQL_DATABASE: portal
|
||||
MYSQL_ROOT_PASSWORD: secret
|
||||
MYSQL_DATABASE: "portal"
|
||||
MYSQL_USER: "root"
|
||||
MYSQL_PASSWORD: "app"
|
||||
MYSQL_ROOT_PASSWORD: "secret"
|
||||
|
||||
# This folder is cached between builds
|
||||
# http://docs.gitlab.com/ce/ci/yaml/README.html#cache
|
||||
@@ -28,13 +30,16 @@ before_script:
|
||||
# Prep for Node
|
||||
- apt-get install gnupg -yqq
|
||||
# Upgrade to Node 8
|
||||
- curl -sL https://deb.nodesource.com/setup_10.x | bash -
|
||||
- curl -sL https://deb.nodesource.com/setup_8.x | bash -
|
||||
# Install dependencies
|
||||
- apt-get install git nodejs libcurl4-gnutls-dev libicu-dev libmcrypt-dev libvpx-dev libjpeg-dev libpng-dev libxpm-dev zlib1g-dev libfreetype6-dev libxml2-dev libexpat1-dev libbz2-dev libgmp3-dev libldap2-dev unixodbc-dev libpq-dev libsqlite3-dev libaspell-dev libsnmp-dev libpcre3-dev libtidy-dev -yqq
|
||||
#- apt-get install php-mbstring php-curl php-json php-intl php-gd php-xml php-zip php-bz2 -yqq
|
||||
- apt-get install mariadb-server -yqq
|
||||
# Install php extensions
|
||||
- docker-php-ext-install pdo pdo_mysql tokenizer xml pcntl curl json
|
||||
# - docker-php-ext-install mbstring intl gd xml bz2 opcache pdo_mysql curl json zip
|
||||
# Install php extensions
|
||||
- docker-php-ext-install mbstring pdo_mysql curl json intl gd xml zip bz2 opcache
|
||||
# Install & enable Xdebug for code coverage reports
|
||||
- pecl install xdebug
|
||||
- docker-php-ext-enable xdebug
|
||||
@@ -43,7 +48,7 @@ before_script:
|
||||
- php composer.phar install
|
||||
# Install Node dependencies.
|
||||
# comment this out if you don't have a node dependency
|
||||
- npm install
|
||||
# - npm install
|
||||
# Copy over testing configuration.
|
||||
# Don't forget to set the database config in .env.testing correctly
|
||||
# DB_HOST=mysql
|
||||
@@ -55,24 +60,21 @@ before_script:
|
||||
# comment this out if you don't have a frontend build
|
||||
# you can change this to to your frontend building script like
|
||||
# npm run build
|
||||
- npm run dev
|
||||
# - npm run dev
|
||||
# Generate an application key. Re-cache.
|
||||
- php artisan key:generate
|
||||
# - php artisan config:cache
|
||||
- php artisan optimize
|
||||
- php artisan config:cache
|
||||
# Run database migrations.
|
||||
- php artisan migrate
|
||||
# Run database seed
|
||||
- php artisan db:seed
|
||||
only:
|
||||
- master
|
||||
|
||||
test:
|
||||
script:
|
||||
# run laravel tests
|
||||
- php artisan test
|
||||
- php vendor/bin/phpunit --coverage-text --colors=never
|
||||
# run frontend tests
|
||||
# if you have any task for testing frontend
|
||||
# set it in your package.json script
|
||||
# comment this out if you don't have a frontend test
|
||||
# - npm test
|
||||
- npm test
|
||||
|
||||
60
composer.lock
generated
60
composer.lock
generated
@@ -1076,16 +1076,16 @@
|
||||
},
|
||||
{
|
||||
"name": "laravel/framework",
|
||||
"version": "v7.22.4",
|
||||
"version": "v7.23.0",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/laravel/framework.git",
|
||||
"reference": "30e851a2b3a2af73fba0b7f4fa22b04260db98e7"
|
||||
"reference": "17cbce101f2fc78e61a6135861823563c7cfb50b"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/laravel/framework/zipball/30e851a2b3a2af73fba0b7f4fa22b04260db98e7",
|
||||
"reference": "30e851a2b3a2af73fba0b7f4fa22b04260db98e7",
|
||||
"url": "https://api.github.com/repos/laravel/framework/zipball/17cbce101f2fc78e61a6135861823563c7cfb50b",
|
||||
"reference": "17cbce101f2fc78e61a6135861823563c7cfb50b",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
@@ -1229,7 +1229,7 @@
|
||||
"framework",
|
||||
"laravel"
|
||||
],
|
||||
"time": "2020-07-27T18:25:06+00:00"
|
||||
"time": "2020-08-04T14:36:37+00:00"
|
||||
},
|
||||
{
|
||||
"name": "laravel/passport",
|
||||
@@ -1899,16 +1899,16 @@
|
||||
},
|
||||
{
|
||||
"name": "nesbot/carbon",
|
||||
"version": "2.37.0",
|
||||
"version": "2.38.0",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/briannesbitt/Carbon.git",
|
||||
"reference": "1f61206de973d67f36ce50f041c792ddac663c3e"
|
||||
"reference": "d8f6a6a91d1eb9304527b040500f61923e97674b"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/briannesbitt/Carbon/zipball/1f61206de973d67f36ce50f041c792ddac663c3e",
|
||||
"reference": "1f61206de973d67f36ce50f041c792ddac663c3e",
|
||||
"url": "https://api.github.com/repos/briannesbitt/Carbon/zipball/d8f6a6a91d1eb9304527b040500f61923e97674b",
|
||||
"reference": "d8f6a6a91d1eb9304527b040500f61923e97674b",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
@@ -1923,7 +1923,7 @@
|
||||
"kylekatarnls/multi-tester": "^2.0",
|
||||
"phpmd/phpmd": "^2.8",
|
||||
"phpstan/extension-installer": "^1.0",
|
||||
"phpstan/phpstan": "^0.12.30",
|
||||
"phpstan/phpstan": "^0.12.35",
|
||||
"phpunit/phpunit": "^7.5 || ^8.0",
|
||||
"squizlabs/php_codesniffer": "^3.4"
|
||||
},
|
||||
@@ -1984,7 +1984,7 @@
|
||||
"type": "tidelift"
|
||||
}
|
||||
],
|
||||
"time": "2020-07-28T06:04:54+00:00"
|
||||
"time": "2020-08-04T19:12:46+00:00"
|
||||
},
|
||||
{
|
||||
"name": "nikic/php-parser",
|
||||
@@ -3839,7 +3839,7 @@
|
||||
},
|
||||
{
|
||||
"name": "symfony/polyfill-ctype",
|
||||
"version": "v1.18.0",
|
||||
"version": "v1.18.1",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/symfony/polyfill-ctype.git",
|
||||
@@ -3915,7 +3915,7 @@
|
||||
},
|
||||
{
|
||||
"name": "symfony/polyfill-iconv",
|
||||
"version": "v1.18.0",
|
||||
"version": "v1.18.1",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/symfony/polyfill-iconv.git",
|
||||
@@ -3992,7 +3992,7 @@
|
||||
},
|
||||
{
|
||||
"name": "symfony/polyfill-intl-grapheme",
|
||||
"version": "v1.18.0",
|
||||
"version": "v1.18.1",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/symfony/polyfill-intl-grapheme.git",
|
||||
@@ -4070,16 +4070,16 @@
|
||||
},
|
||||
{
|
||||
"name": "symfony/polyfill-intl-idn",
|
||||
"version": "v1.18.0",
|
||||
"version": "v1.18.1",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/symfony/polyfill-intl-idn.git",
|
||||
"reference": "bc6549d068d0160e0f10f7a5a23c7d1406b95ebe"
|
||||
"reference": "5dcab1bc7146cf8c1beaa4502a3d9be344334251"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/symfony/polyfill-intl-idn/zipball/bc6549d068d0160e0f10f7a5a23c7d1406b95ebe",
|
||||
"reference": "bc6549d068d0160e0f10f7a5a23c7d1406b95ebe",
|
||||
"url": "https://api.github.com/repos/symfony/polyfill-intl-idn/zipball/5dcab1bc7146cf8c1beaa4502a3d9be344334251",
|
||||
"reference": "5dcab1bc7146cf8c1beaa4502a3d9be344334251",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
@@ -4151,11 +4151,11 @@
|
||||
"type": "tidelift"
|
||||
}
|
||||
],
|
||||
"time": "2020-07-14T12:35:20+00:00"
|
||||
"time": "2020-08-04T06:02:08+00:00"
|
||||
},
|
||||
{
|
||||
"name": "symfony/polyfill-intl-normalizer",
|
||||
"version": "v1.18.0",
|
||||
"version": "v1.18.1",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/symfony/polyfill-intl-normalizer.git",
|
||||
@@ -4236,7 +4236,7 @@
|
||||
},
|
||||
{
|
||||
"name": "symfony/polyfill-mbstring",
|
||||
"version": "v1.18.0",
|
||||
"version": "v1.18.1",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/symfony/polyfill-mbstring.git",
|
||||
@@ -4313,7 +4313,7 @@
|
||||
},
|
||||
{
|
||||
"name": "symfony/polyfill-php70",
|
||||
"version": "v1.18.0",
|
||||
"version": "v1.18.1",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/symfony/polyfill-php70.git",
|
||||
@@ -4390,7 +4390,7 @@
|
||||
},
|
||||
{
|
||||
"name": "symfony/polyfill-php72",
|
||||
"version": "v1.18.0",
|
||||
"version": "v1.18.1",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/symfony/polyfill-php72.git",
|
||||
@@ -4463,7 +4463,7 @@
|
||||
},
|
||||
{
|
||||
"name": "symfony/polyfill-php73",
|
||||
"version": "v1.18.0",
|
||||
"version": "v1.18.1",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/symfony/polyfill-php73.git",
|
||||
@@ -4539,7 +4539,7 @@
|
||||
},
|
||||
{
|
||||
"name": "symfony/polyfill-php80",
|
||||
"version": "v1.18.0",
|
||||
"version": "v1.18.1",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/symfony/polyfill-php80.git",
|
||||
@@ -5598,16 +5598,16 @@
|
||||
},
|
||||
{
|
||||
"name": "facade/ignition",
|
||||
"version": "2.3.4",
|
||||
"version": "2.3.5",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/facade/ignition.git",
|
||||
"reference": "87335b120bc9652e4ee2bf285b7322a785211476"
|
||||
"reference": "58dc4a8df3d41174c677a370b6779b694e4539e7"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/facade/ignition/zipball/87335b120bc9652e4ee2bf285b7322a785211476",
|
||||
"reference": "87335b120bc9652e4ee2bf285b7322a785211476",
|
||||
"url": "https://api.github.com/repos/facade/ignition/zipball/58dc4a8df3d41174c677a370b6779b694e4539e7",
|
||||
"reference": "58dc4a8df3d41174c677a370b6779b694e4539e7",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
@@ -5666,7 +5666,7 @@
|
||||
"laravel",
|
||||
"page"
|
||||
],
|
||||
"time": "2020-07-27T15:17:39+00:00"
|
||||
"time": "2020-08-01T21:20:01+00:00"
|
||||
},
|
||||
{
|
||||
"name": "facade/ignition-contracts",
|
||||
|
||||
@@ -31,7 +31,7 @@
|
||||
"sass": "^1.26.10",
|
||||
"sass-loader": "^8.0.0",
|
||||
"vue": "^2.5.17",
|
||||
"vue-router": "^3.3.4",
|
||||
"vue-router": "^3.4.1",
|
||||
"vue-template-compiler": "^2.6.10",
|
||||
"vuex": "^3.5.1"
|
||||
},
|
||||
@@ -40,6 +40,6 @@
|
||||
"laravel-mix-svg-vue": "^0.2.6",
|
||||
"markdown-it": "^10.0.0",
|
||||
"markdown-it-checkbox": "^1.1.0",
|
||||
"tailwindcss": "^1.6.0"
|
||||
"tailwindcss": "^1.6.2"
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,7 +1,17 @@
|
||||
<template>
|
||||
<div class="mx-2 p-2">
|
||||
<div class="flex justify-between flex-center mb-4">
|
||||
<div class="flex justify-between items-center flex-wrap flex-center mb-4">
|
||||
<a href="#" class="btn" @click="$router.back()">Back</a>
|
||||
<div>
|
||||
<a class="btn-secondary btn-small mr-2" @click="reorderList(true, 'date')">
|
||||
<svg-vue icon="order-time" class="" />
|
||||
<svg-vue icon="arrow" v-bind:class="{ arrowUp: !this.orderDate }" class="transform m-0 rotate-90 transition duration-300 ease-in-out" />
|
||||
</a>
|
||||
<a class="btn-secondary btn-small" @click="reorderList(true, 'alpha')">
|
||||
<svg-vue icon="order-alpha" class="" />
|
||||
<svg-vue icon="arrow" v-bind:class="{ arrowUp: !this.orderAlpha }" class="transform m-0 rotate-90 transition duration-300 ease-in-out" />
|
||||
</a>
|
||||
</div>
|
||||
<router-link :to="'/memos/create'" class="btn-primary">Add New Memo</router-link>
|
||||
</div>
|
||||
<Loader v-if="loading" />
|
||||
@@ -36,6 +46,8 @@ export default {
|
||||
return {
|
||||
loading: true,
|
||||
memos: null,
|
||||
orderDate: false,
|
||||
orderAlpha: false,
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
@@ -52,10 +64,22 @@ export default {
|
||||
})
|
||||
},
|
||||
methods: {
|
||||
reorderList() {
|
||||
this.memos.sort(function(a, b) {
|
||||
return b.data.last_updated_timestamp - a.data.last_updated_timestamp
|
||||
})
|
||||
reorderList(btn = false, types = 'date') {
|
||||
if(btn && types === 'date') {
|
||||
this.orderDate = !this.orderDate
|
||||
} else if (btn && types === 'alpha') {
|
||||
this.orderAlpha = !this.orderAlpha
|
||||
}
|
||||
|
||||
if(this.orderDate && types === 'date') {
|
||||
this.memos.sort((a, b) => a.data.last_updated_timestamp - b.data.last_updated_timestamp)
|
||||
} else if (this.orderAlpha && types === 'alpha') {
|
||||
this.memos.sort((a, b) => a.data.name.localeCompare(b.data.name))
|
||||
} else if(types === 'alpha') {
|
||||
this.memos.sort((a, b) => b.data.name.localeCompare(a.data.name))
|
||||
} else {
|
||||
this.memos.sort((a, b) => b.data.last_updated_timestamp - a.data.last_updated_timestamp)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
14
resources/sass/components/_btn.scss
vendored
14
resources/sass/components/_btn.scss
vendored
@@ -55,3 +55,17 @@
|
||||
@apply bg-green-dark;
|
||||
}
|
||||
}
|
||||
|
||||
.btn-small {
|
||||
@extend .btn;
|
||||
@apply text-sm p-2;
|
||||
|
||||
& svg {
|
||||
@apply ml-2 mr-0;
|
||||
}
|
||||
}
|
||||
|
||||
.arrowUp {
|
||||
--transform-rotate: -90deg !important;
|
||||
}
|
||||
|
||||
|
||||
14
resources/svg/order-alpha.svg
Normal file
14
resources/svg/order-alpha.svg
Normal file
@@ -0,0 +1,14 @@
|
||||
<?xml version="1.0" encoding="iso-8859-1"?>
|
||||
<svg version="1.1" id="Capa_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
|
||||
viewBox="0 0 432 432" style="0 0 432 432;" xml:space="preserve">
|
||||
<g>
|
||||
<g>
|
||||
<g>
|
||||
<polygon points="234.24,9.067 183.893,59.413 284.587,59.413 "/>
|
||||
<polygon points="301.44,304.32 427.947,120.853 427.947,93.973 250.88,93.973 250.88,128.107 376.32,128.107 250.027,310.72 250.027,338.24 432,338.24 432,304.32 "/>
|
||||
<polygon points="234.24,422.933 283.947,373.227 184.533,373.227 "/>
|
||||
<path d="M226.773,338.24L130.987,93.76H96L0,338.24h39.253l19.627-52.267h109.013l19.627,52.267H226.773z M71.893,250.987 L113.28,140.48l41.387,110.507H71.893z"/>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 772 B |
26
resources/svg/order-time.svg
Normal file
26
resources/svg/order-time.svg
Normal file
@@ -0,0 +1,26 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<svg
|
||||
xmlns:svg="http://www.w3.org/2000/svg"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
version="1.1"
|
||||
id="Capa_1"
|
||||
x="0px"
|
||||
y="0px"
|
||||
viewBox="0 0 426.667 426.667"
|
||||
style="0 0 426.667 426.667;"
|
||||
xml:space="preserve">
|
||||
<polygon
|
||||
points="284.587,59.413 234.24,9.067 183.893,59.413 "
|
||||
id="polygon2"
|
||||
transform="translate(-20.906504)" />
|
||||
<polygon
|
||||
points="184.533,373.227 234.24,422.933 283.947,373.227 "
|
||||
id="polygon10"
|
||||
transform="translate(-20.906504)" /><g
|
||||
id="g854"
|
||||
transform="matrix(0.6546605,0,0,0.6546605,73.67248,73.672808)"><path
|
||||
id="path4"
|
||||
d="M 213.227,0 C 95.36,0 0,95.467 0,213.333 c 0,117.866 95.36,213.333 213.227,213.333 117.867,0 213.44,-95.467 213.44,-213.333 C 426.667,95.467 331.093,0 213.227,0 Z m 0.106,384 C 119.04,384 42.666,307.627 42.666,213.333 42.666,119.039 119.04,42.667 213.333,42.667 307.626,42.667 384,119.04 384,213.333 384,307.626 307.627,384 213.333,384 Z" /><polygon
|
||||
id="polygon12"
|
||||
points="192,234.667 303.893,301.867 320,275.627 224,218.667 224,106.667 192,106.667 " /></g>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 1.1 KiB |
10
webpack.mix.js
vendored
10
webpack.mix.js
vendored
@@ -1,7 +1,7 @@
|
||||
const mix = require('laravel-mix');
|
||||
const mix = require('laravel-mix')
|
||||
const tailwindcss = require('tailwindcss')
|
||||
require('laravel-mix-purgecss');
|
||||
require('laravel-mix-svg-vue');
|
||||
require('laravel-mix-purgecss')
|
||||
require('laravel-mix-svg-vue')
|
||||
|
||||
mix.js('resources/js/app.js', 'public/js')
|
||||
.svgVue()
|
||||
@@ -10,4 +10,6 @@ mix.js('resources/js/app.js', 'public/js')
|
||||
processCssUrls: false,
|
||||
postCss: [ tailwindcss('./tailwind.config.js') ],
|
||||
})
|
||||
.purgeCss({whitelistPatterns: [/-active$/, /-enter$/, /-leave-to$/, /show$/, /code$/, /pre$/, /blockquote$/]});
|
||||
.purgeCss({
|
||||
whitelistPatterns: [/-active$/, /-enter$/, /-leave-to$/, /show$/, /code$/, /pre$/, /blockquote$/, /owf/]
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user