Skip to content

Commit

Permalink
Merge pull request #1314 from Kapsch-TrafficCom/develop
Browse files Browse the repository at this point in the history
#1309 committing implementation
  • Loading branch information
fiftin authored Jul 8, 2023
2 parents 29b38c4 + d884330 commit 1611fee
Show file tree
Hide file tree
Showing 40 changed files with 860 additions and 381 deletions.
97 changes: 49 additions & 48 deletions web/package.json
Original file line number Diff line number Diff line change
@@ -1,48 +1,49 @@
{
"name": "web",
"version": "0.1.0",
"private": true,
"scripts": {
"serve": "vue-cli-service serve",
"build": "vue-cli-service build",
"test:unit": "vue-cli-service test:unit",
"lint": "vue-cli-service lint"
},
"dependencies": {
"@mdi/font": "^5.9.55",
"ansi-to-html": "^0.7.2",
"axios": "^0.21.4",
"core-js": "^3.23.2",
"moment": "^2.29.3",
"vue": "^2.6.14",
"vue-codemirror": "^4.0.6",
"vue-router": "^3.5.4",
"vuedraggable": "^2.24.3",
"vuetify": "^2.6.6"
},
"devDependencies": {
"@vue/cli-plugin-babel": "^5.0.6",
"@vue/cli-plugin-eslint": "^5.0.6",
"@vue/cli-plugin-router": "^5.0.6",
"@vue/cli-plugin-unit-mocha": "^5.0.6",
"@vue/cli-service": "^5.0.6",
"@vue/eslint-config-airbnb": "^6.0.0",
"@vue/test-utils": "^1.3.0",
"babel-eslint": "^10.1.0",
"chai": "^4.3.6",
"eslint": "^7.32.0",
"eslint-plugin-import": "^2.26.0",
"eslint-plugin-vue": "^9.1.1",
"eslint-plugin-vuejs-accessibility": "^1.2.0",
"glob-parent": ">=5.1.2",
"nanoid": ">=3.1.31",
"nyc": "^15.1.0",
"sass": "~1.32.12",
"sass-loader": "^13.0.0",
"stylus": "^0.54.8",
"stylus-loader": "^3.0.2",
"vue-cli-plugin-vuetify": "~2.0.7",
"vue-template-compiler": "^2.6.14",
"vuetify-loader": "^1.8.0"
}
}
{
"name": "web",
"version": "0.1.0",
"private": true,
"scripts": {
"serve": "vue-cli-service serve",
"build": "vue-cli-service build",
"test:unit": "vue-cli-service test:unit",
"lint": "vue-cli-service lint"
},
"dependencies": {
"@mdi/font": "^5.9.55",
"ansi-to-html": "^0.7.2",
"axios": "^0.21.4",
"core-js": "^3.23.2",
"moment": "^2.29.3",
"vue": "^2.6.14",
"vue-i18n": "^8.18.2",
"vue-codemirror": "^4.0.6",
"vue-router": "^3.5.4",
"vuedraggable": "^2.24.3",
"vuetify": "^2.6.6"
},
"devDependencies": {
"@vue/cli-plugin-babel": "^5.0.6",
"@vue/cli-plugin-eslint": "^5.0.6",
"@vue/cli-plugin-router": "^5.0.6",
"@vue/cli-plugin-unit-mocha": "^5.0.6",
"@vue/cli-service": "^5.0.6",
"@vue/eslint-config-airbnb": "^6.0.0",
"@vue/test-utils": "^1.3.0",
"babel-eslint": "^10.1.0",
"chai": "^4.3.6",
"eslint": "^7.32.0",
"eslint-plugin-import": "^2.26.0",
"eslint-plugin-vue": "^9.1.1",
"eslint-plugin-vuejs-accessibility": "^1.2.0",
"glob-parent": ">=5.1.2",
"nanoid": ">=3.1.31",
"nyc": "^15.1.0",
"sass": "~1.32.12",
"sass-loader": "^13.0.0",
"stylus": "^0.54.8",
"stylus-loader": "^3.0.2",
"vue-cli-plugin-vuetify": "~2.0.7",
"vue-template-compiler": "^2.6.14",
"vuetify-loader": "^1.8.0"
}
}
48 changes: 24 additions & 24 deletions web/src/App.vue
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<EditDialog
v-model="passwordDialog"
save-button-text="Save"
title="Change password"
:title="$t('changePassword')"
v-if="user"
event-name="i-user"
>
Expand All @@ -22,7 +22,7 @@
<EditDialog
v-model="userDialog"
save-button-text="Save"
title="Edit User"
:title="$t('editUser')"
v-if="user"
event-name="i-user"
>
Expand Down Expand Up @@ -54,7 +54,7 @@
>{{ template ? template.name : null }}
</router-link>
<v-icon>mdi-chevron-right</v-icon>
<span class="breadcrumbs__item">Task #{{ task ? task.id : null }}</span>
<span class="breadcrumbs__item">{{ $t('task', {expr: task ? task.id : null}) }}</span>
</div>

<v-spacer></v-spacer>
Expand All @@ -73,7 +73,7 @@
<EditDialog
v-model="newProjectDialog"
save-button-text="Create"
title="New Project"
:title="$t('newProject')"
event-name="i-project"
>
<template v-slot:form="{ onSave, onError, needSave, needReset }">
Expand All @@ -98,7 +98,7 @@
text
@click="snackbar = false"
>
Close
{{ $t('close') }}
</v-btn>
</v-snackbar>

Expand Down Expand Up @@ -168,7 +168,7 @@
</v-list-item-icon>

<v-list-item-content>
New project...
{{ $t('newProject2') }}
</v-list-item-content>
</v-list-item>
</v-list>
Expand All @@ -181,7 +181,7 @@
</v-list-item-icon>

<v-list-item-content>
<v-list-item-title>New Project</v-list-item-title>
<v-list-item-title>{{ $t('newProject') }}</v-list-item-title>
</v-list-item-content>
</v-list-item>
</v-list>
Expand All @@ -190,10 +190,10 @@
<v-list-item v-if="systemInfo && systemInfo.demo">
<v-list-item-content>
<v-alert class="ma-0 pa-2" color="red">
<div class="mb-1 font-weight-bold">DEMO MODE</div>
<div class="mb-1 font-weight-bold">{{ $t('demoMode') }}</div>
<ul style="padding-left: 14px; font-size: 14px; line-height: 1.3;">
<li>You can run any tasks</li>
<li>You have read-only access</li>
<li>{{ $t('youCanRunAnyTasks') }}</li>
<li>{{ $t('youHaveReadonlyAccess') }}</li>
</ul>
</v-alert>
</v-list-item-content>
Expand All @@ -205,7 +205,7 @@
</v-list-item-icon>

<v-list-item-content>
<v-list-item-title>Dashboard</v-list-item-title>
<v-list-item-title>{{ $t('dashboard') }}</v-list-item-title>
</v-list-item-content>
</v-list-item>

Expand All @@ -215,7 +215,7 @@
</v-list-item-icon>

<v-list-item-content>
<v-list-item-title>Task Templates</v-list-item-title>
<v-list-item-title>{{ $t('taskTemplates') }}</v-list-item-title>
</v-list-item-content>
</v-list-item>

Expand All @@ -225,7 +225,7 @@
</v-list-item-icon>

<v-list-item-content>
<v-list-item-title>Inventory</v-list-item-title>
<v-list-item-title>{{ $t('inventory') }}</v-list-item-title>
</v-list-item-content>
</v-list-item>

Expand All @@ -235,7 +235,7 @@
</v-list-item-icon>

<v-list-item-content>
<v-list-item-title>Environment</v-list-item-title>
<v-list-item-title>{{ $t('environment') }}</v-list-item-title>
</v-list-item-content>
</v-list-item>

Expand All @@ -245,7 +245,7 @@
</v-list-item-icon>

<v-list-item-content>
<v-list-item-title>Key Store</v-list-item-title>
<v-list-item-title>{{ $t('keyStore') }}</v-list-item-title>
</v-list-item-content>
</v-list-item>

Expand All @@ -255,7 +255,7 @@
</v-list-item-icon>

<v-list-item-content>
<v-list-item-title>Repositories</v-list-item-title>
<v-list-item-title>{{ $t('repositories') }}</v-list-item-title>
</v-list-item-content>
</v-list-item>

Expand All @@ -265,7 +265,7 @@
</v-list-item-icon>

<v-list-item-content>
<v-list-item-title>Team</v-list-item-title>
<v-list-item-title>{{ $t('team') }}</v-list-item-title>
</v-list-item-content>
</v-list-item>
</v-list>
Expand All @@ -278,7 +278,7 @@
<v-switch
v-model="darkMode"
inset
label="Dark Mode"
:label="$t('darkMode')"
persistent-hint
></v-switch>
</v-list-item>
Expand All @@ -305,7 +305,7 @@
</v-list-item-icon>

<v-list-item-content>
Users
{{ $t('users') }}
</v-list-item-content>
</v-list-item>

Expand All @@ -315,7 +315,7 @@
</v-list-item-icon>

<v-list-item-content>
Edit Account
{{ $t('editAccount') }}
</v-list-item-content>
</v-list-item>

Expand Down Expand Up @@ -356,7 +356,7 @@
</v-list-item-icon>

<v-list-item-content>
Sign Out
{{ $t('signOut') }}
</v-list-item-content>
</v-list-item>
</v-list>
Expand Down Expand Up @@ -398,18 +398,18 @@
>
<v-alert text color="error" class="d-inline-block">
<h3 class="headline">
Error
{{ $t('error') }}
</h3>
{{ snackbarText }}
</v-alert>
<div class="mb-6">
<v-btn text color="blue darken-1" @click="refreshPage()">
<v-icon left>mdi-refresh</v-icon>
Refresh Page
{{ $t('refreshPage') }}
</v-btn>
<v-btn text color="blue darken-1" @click="signOut()">
<v-icon left>mdi-exit-to-app</v-icon>
Relogin
{{ $t('relogin') }}
</v-btn>
</div>
</v-container>
Expand Down
4 changes: 2 additions & 2 deletions web/src/components/ChangePasswordForm.vue
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,11 @@

<v-text-field
v-model="item.password"
label="Password"
:label="$t('password2')"
:type="showPassword ? 'text' : 'password'"
:append-icon="showPassword ? 'mdi-eye' : 'mdi-eye-off'"
@click:append="showPassword = !showPassword"
:rules="[v => !!v || 'Password is required']"
:rules="[v => !!v || $t('password_required')]"
required
:disabled="formSaving"
></v-text-field>
Expand Down
2 changes: 1 addition & 1 deletion web/src/components/EditDialog.vue
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ Can use used in tandem with ItemFormBase.js. See KeyForm.vue for example.
text
@click="close()"
>
Cancel
{{ $t('cancel') }}
</v-btn>

<v-btn
Expand Down
4 changes: 2 additions & 2 deletions web/src/components/EditViewsForm.vue
Original file line number Diff line number Diff line change
Expand Up @@ -48,8 +48,8 @@
<v-alert
v-else
type="info"
>No views</v-alert>
<v-btn @click="addView()" color="primary">Add view</v-btn>
>{{ $t('noViews') }}</v-alert>
<v-btn @click="addView()" color="primary">{{ $t('addView') }}</v-btn>
</div>
</template>

Expand Down
15 changes: 7 additions & 8 deletions web/src/components/EnvironmentForm.vue
Original file line number Diff line number Diff line change
Expand Up @@ -13,33 +13,33 @@

<v-text-field
v-model="item.name"
label="Environment Name"
:rules="[v => !!v || 'Name is required']"
:label="$t('environmentName')"
:rules="[v => !!v || $t('name_required')]"
required
:disabled="formSaving"
class="mb-4"
></v-text-field>

<v-subheader>
Extra variables
{{ $t('extraVariables') }}
</v-subheader>

<codemirror
:style="{ border: '1px solid lightgray' }"
v-model="item.json"
:options="cmOptions"
placeholder="Enter extra variables JSON..."
:placeholder="$t('enterExtraVariablesJson')"
/>

<v-subheader>
Environment variables
{{ $t('environmentVariables') }}
</v-subheader>

<codemirror
:style="{ border: '1px solid lightgray' }"
v-model="item.env"
:options="cmOptions"
placeholder="Enter env JSON..."
:placeholder="$t('enterEnvJson')"
/>

<v-alert
Expand All @@ -48,8 +48,7 @@
type="info"
class="mt-4"
>
Environment and extra variables must be valid JSON.
Example:
{{ $t('environmentAndExtraVariablesMustBeValidJsonExample') }}
<pre style="font-size: 14px;">{
"var_available_in_playbook_1": 1245,
"var_available_in_playbook_2": "test"
Expand Down
Loading

0 comments on commit 1611fee

Please sign in to comment.