Pārlūkot izejas kodu

refactor: add checked property to component data

pull/604/head
Andrea PIERRÉ pirms 3 gadiem
vecāks
revīzija
fa145da93e
Šim parakstam datu bāzē netika atrasta zināma atslēga GPG atslēgas ID: 78A39B4A078E6C06
2 mainītis faili ar 5 papildinājumiem un 2 dzēšanām
  1. +3
    -1
      packages/lesspass-pure/src/components/MasterPassword.vue
  2. +2
    -1
      packages/lesspass-pure/src/views/Login.vue

+ 3
- 1
packages/lesspass-pure/src/components/MasterPassword.vue Parādīt failu

@@ -65,6 +65,7 @@
class="form-check-input"
type="checkbox"
id="checkPlainPassword"
v-model="checkPlainPassword"
/>
<label class="form-check-label" for="checkPlainPassword">{{
$t("Use plain password")
@@ -98,7 +99,8 @@ export default {
icon3: "",
color1: "",
color2: "",
color3: ""
color3: "",
checkPlainPassword: false
};
},
methods: {


+ 2
- 1
packages/lesspass-pure/src/views/Login.vue Parādīt failu

@@ -116,10 +116,11 @@ export default {
signIn() {
if (this.formIsValid()) {
const baseURL = this.baseURL;
let checkPlainPassword = this.$children[0].checkPlainPassword
this.$store.dispatch("setBaseURL", { baseURL });
encryptPassword(this.email, this.password)
.then(encryptedPassword => {
let pass = document.getElementById("checkPlainPassword").checked ? this.password : encryptedPassword;
let pass = checkPlainPassword ? this.password : encryptedPassword;
User.login({ email: this.email, password: pass })
.then(response => {
this.$store.dispatch("login", response.data);


Notiek ielāde…
Atcelt
Saglabāt