Extract patron mock data to seperate file
This commit is contained in:
parent
0e1a2c6360
commit
e1f28d7a8f
6 changed files with 45 additions and 14 deletions
19
frontend/.idea/codeStyles/Project.xml
Normal file
19
frontend/.idea/codeStyles/Project.xml
Normal file
|
@ -0,0 +1,19 @@
|
||||||
|
<component name="ProjectCodeStyleConfiguration">
|
||||||
|
<code_scheme name="Project" version="173">
|
||||||
|
<option name="RIGHT_MARGIN" value="80" />
|
||||||
|
<JSCodeStyleSettings version="0">
|
||||||
|
<option name="USE_SEMICOLON_AFTER_STATEMENT" value="false" />
|
||||||
|
<option name="FORCE_SEMICOLON_STYLE" value="true" />
|
||||||
|
<option name="USE_DOUBLE_QUOTES" value="false" />
|
||||||
|
<option name="FORCE_QUOTE_STYlE" value="true" />
|
||||||
|
<option name="ENFORCE_TRAILING_COMMA" value="WhenMultiline" />
|
||||||
|
</JSCodeStyleSettings>
|
||||||
|
<codeStyleSettings language="JavaScript">
|
||||||
|
<indentOptions>
|
||||||
|
<option name="INDENT_SIZE" value="2" />
|
||||||
|
<option name="CONTINUATION_INDENT_SIZE" value="2" />
|
||||||
|
<option name="TAB_SIZE" value="2" />
|
||||||
|
</indentOptions>
|
||||||
|
</codeStyleSettings>
|
||||||
|
</code_scheme>
|
||||||
|
</component>
|
|
@ -1,5 +1,5 @@
|
||||||
<component name="ProjectCodeStyleConfiguration">
|
<component name="ProjectCodeStyleConfiguration">
|
||||||
<state>
|
<state>
|
||||||
<option name="PREFERRED_PROJECT_CODE_STYLE" value="Default" />
|
<option name="USE_PER_PROJECT_SETTINGS" value="true" />
|
||||||
</state>
|
</state>
|
||||||
</component>
|
</component>
|
13
frontend/data/patrons.ts
Normal file
13
frontend/data/patrons.ts
Normal file
|
@ -0,0 +1,13 @@
|
||||||
|
const patrons = [
|
||||||
|
{id: 1, name: 'Bob Harrison', email: 'bob.harrison@gmail.com', status: 'Active', checkedOut: 5, overdue: 0, fines: 0},
|
||||||
|
{id: 2, name: 'Rachel Levington', email: 'rachel97@hotmail.com', status: 'Active', checkedOut: 8, overdue: 0, fines: 0},
|
||||||
|
{id: 3, name: 'Jackson Smith', email: 'j.smith@gmail.com', status: 'Overdue', checkedOut: 3, overdue: 3, fines: 9},
|
||||||
|
{id: 4, name: 'Thomas Fletcher', email: 'fletchieT@gmail.com', status: 'Active', checkedOut: 7, overdue: 0, fines: 0},
|
||||||
|
{id: 5, name: 'Steve Terry', email: 'sterry@outlook.com', status: 'Overdue', checkedOut: 1, overdue: 1, fines: 5},
|
||||||
|
{id: 6, name: 'Carrie Pine', email: 'carrie1994@hotmail.com', status: 'Active', checkedOut: 8, overdue: 0, fines: 0},
|
||||||
|
{id: 7, name: 'Delilah Lowry', email: 'heytheredelilah@yahoo.com', status: 'Active', checkedOut: 8, overdue: 0, fines: 0},
|
||||||
|
{id: 8, name: 'George Jefferson', email: 'mrpresidential@protonmail.com', status: 'Active', checkedOut: 3, overdue: 0, fines: 0},
|
||||||
|
{id: 9, name: 'Sharon Mattison', email: 'sharon.mattison@gmail.com', status: 'Overdue', checkedOut: 4, overdue: 4, fines: 7},
|
||||||
|
]
|
||||||
|
|
||||||
|
export default patrons
|
|
@ -1,15 +1,19 @@
|
||||||
// https://nuxt.com/docs/api/configuration/nuxt-config
|
import {fileURLToPath, URL} from 'node:url'
|
||||||
|
|
||||||
|
// https://nuxt.com/docs/api/configuration/nuxt-config
|
||||||
export default defineNuxtConfig({
|
export default defineNuxtConfig({
|
||||||
modules: ['@nuxtjs/tailwindcss', '@nuxtjs/google-fonts', 'nuxt-typed-router'],
|
modules: ['@nuxtjs/tailwindcss', '@nuxtjs/google-fonts', 'nuxt-typed-router'],
|
||||||
devServer: {
|
devServer: {
|
||||||
host: 'bibliothecary.test',
|
host: 'bibliothecary.test',
|
||||||
},
|
},
|
||||||
telemetry: false,
|
telemetry: false,
|
||||||
|
alias: {
|
||||||
|
'@data': fileURLToPath(new URL('./data', import.meta.url))
|
||||||
|
},
|
||||||
googleFonts: {
|
googleFonts: {
|
||||||
preconnect: true,
|
preconnect: true,
|
||||||
families: {
|
families: {
|
||||||
Imprima: true,
|
Imprima: true,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
});
|
})
|
||||||
|
|
|
@ -1,15 +1,5 @@
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
const patrons = [
|
import patrons from '@data/patrons'
|
||||||
{name: 'Bob Harrison', email: 'bob.harrison@gmail.com', status: 'Active', checkedOut: 5, overdue: 0, fines: 0},
|
|
||||||
{name: 'Rachel Levington', email: 'rachel97@hotmail.com', status: 'Active', checkedOut: 8, overdue: 0, fines: 0},
|
|
||||||
{name: 'Jackson Smith', email: 'j.smith@gmail.com', status: 'Overdue', checkedOut: 3, overdue: 3, fines: 9},
|
|
||||||
{name: 'Thomas Fletcher', email: 'fletchieT@gmail.com', status: 'Active', checkedOut: 7, overdue: 0, fines: 0},
|
|
||||||
{name: 'Steve Terry', email: 'sterry@outlook.com', status: 'Overdue', checkedOut: 1, overdue: 1, fines: 5},
|
|
||||||
{name: 'Carrie Pine', email: 'carrie1994@hotmail.com', status: 'Active', checkedOut: 8, overdue: 0, fines: 0},
|
|
||||||
{name: 'Delilah Lowry', email: 'heytheredelilah@yahoo.com', status: 'Active', checkedOut: 8, overdue: 0, fines: 0},
|
|
||||||
{name: 'George Jefferson', email: 'mrpresidential@protonmail.com', status: 'Active', checkedOut: 3, overdue: 0, fines: 0},
|
|
||||||
{name: 'Sharon Mattison', email: 'sharon.mattison@gmail.com', status: 'Overdue', checkedOut: 4, overdue: 4, fines: 7},
|
|
||||||
]
|
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<!--------------------------------------------------------------- TEMPLATE ---->
|
<!--------------------------------------------------------------- TEMPLATE ---->
|
||||||
|
|
5
frontend/webStorm.config.js
Normal file
5
frontend/webStorm.config.js
Normal file
|
@ -0,0 +1,5 @@
|
||||||
|
System.config({
|
||||||
|
"paths": {
|
||||||
|
"@data/*": "./data/*"
|
||||||
|
}
|
||||||
|
})
|
Loading…
Reference in a new issue