Merge branch 'i18n' into deploy

This commit is contained in:
Pan 2019-06-05 09:38:00 +08:00
commit b7b12acbd2
5 changed files with 22 additions and 18 deletions

View File

@ -839,16 +839,20 @@ export default {
that.$emit('crop-upload-fail', err, field, ki) that.$emit('crop-upload-fail', err, field, ki)
} }
}) })
},
closeHandler(e) {
if (this.value && (e.key == 'Escape' || e.keyCode == 27)) {
this.off()
}
} }
}, },
created() { created() {
// esc // esc
document.addEventListener('keyup', (e) => { document.addEventListener('keyup', this.closeHandler)
if (this.value && (e.key == 'Escape' || e.keyCode == 27)) { },
this.off() destroyed() {
} document.removeEventListener('keyup', this.closeHandler)
}) },
}
} }
</script> </script>

View File

@ -9,7 +9,7 @@
:placeholder="fillPlaceHolder" :placeholder="fillPlaceHolder"
:readonly="readonly" :readonly="readonly"
:disabled="disabled" :disabled="disabled"
:autoComplete="autoComplete" :autocomplete="autoComplete"
:required="required" :required="required"
type="email" type="email"
class="material-input" class="material-input"
@ -24,7 +24,7 @@
:placeholder="fillPlaceHolder" :placeholder="fillPlaceHolder"
:readonly="readonly" :readonly="readonly"
:disabled="disabled" :disabled="disabled"
:autoComplete="autoComplete" :autocomplete="autoComplete"
:required="required" :required="required"
type="url" type="url"
class="material-input" class="material-input"
@ -40,7 +40,7 @@
:step="step" :step="step"
:readonly="readonly" :readonly="readonly"
:disabled="disabled" :disabled="disabled"
:autoComplete="autoComplete" :autocomplete="autoComplete"
:max="max" :max="max"
:min="min" :min="min"
:minlength="minlength" :minlength="minlength"
@ -59,7 +59,7 @@
:placeholder="fillPlaceHolder" :placeholder="fillPlaceHolder"
:readonly="readonly" :readonly="readonly"
:disabled="disabled" :disabled="disabled"
:autoComplete="autoComplete" :autocomplete="autoComplete"
:max="max" :max="max"
:min="min" :min="min"
:required="required" :required="required"
@ -76,7 +76,7 @@
:placeholder="fillPlaceHolder" :placeholder="fillPlaceHolder"
:readonly="readonly" :readonly="readonly"
:disabled="disabled" :disabled="disabled"
:autoComplete="autoComplete" :autocomplete="autoComplete"
:required="required" :required="required"
type="tel" type="tel"
class="material-input" class="material-input"
@ -91,7 +91,7 @@
:placeholder="fillPlaceHolder" :placeholder="fillPlaceHolder"
:readonly="readonly" :readonly="readonly"
:disabled="disabled" :disabled="disabled"
:autoComplete="autoComplete" :autocomplete="autoComplete"
:minlength="minlength" :minlength="minlength"
:maxlength="maxlength" :maxlength="maxlength"
:required="required" :required="required"

View File

@ -6,7 +6,7 @@ import { getToken } from '@/utils/auth'
// create an axios instance // create an axios instance
const service = axios.create({ const service = axios.create({
baseURL: process.env.VUE_APP_BASE_API, // url = base url + request url baseURL: process.env.VUE_APP_BASE_API, // url = base url + request url
withCredentials: true, // send cookies when cross-domain requests // withCredentials: true, // send cookies when cross-domain requests
timeout: 5000 // request timeout timeout: 5000 // request timeout
}) })

View File

@ -6,7 +6,7 @@
<PlatformDropdown v-model="postForm.platforms" /> <PlatformDropdown v-model="postForm.platforms" />
<SourceUrlDropdown v-model="postForm.source_uri" /> <SourceUrlDropdown v-model="postForm.source_uri" />
<el-button v-loading="loading" style="margin-left: 10px;" type="success" @click="submitForm"> <el-button v-loading="loading" style="margin-left: 10px;" type="success" @click="submitForm">
Publush Publish
</el-button> </el-button>
<el-button v-loading="loading" type="warning" @click="draftForm"> <el-button v-loading="loading" type="warning" @click="draftForm">
Draft Draft
@ -35,7 +35,7 @@
</el-col> </el-col>
<el-col :span="10"> <el-col :span="10">
<el-form-item label-width="120px" label="Publush Time:" class="postInfo-container-item"> <el-form-item label-width="120px" label="Publish Time:" class="postInfo-container-item">
<el-date-picker v-model="displayTime" type="datetime" format="yyyy-MM-dd HH:mm:ss" placeholder="Select date and time" /> <el-date-picker v-model="displayTime" type="datetime" format="yyyy-MM-dd HH:mm:ss" placeholder="Select date and time" />
</el-form-item> </el-form-item>
</el-col> </el-col>

View File

@ -1,6 +1,6 @@
<template> <template>
<div class="login-container"> <div class="login-container">
<el-form ref="loginForm" :model="loginForm" :rules="loginRules" class="login-form" auto-complete="on" label-position="left"> <el-form ref="loginForm" :model="loginForm" :rules="loginRules" class="login-form" autocomplete="on" label-position="left">
<div class="title-container"> <div class="title-container">
<h3 class="title"> <h3 class="title">
@ -20,7 +20,7 @@
name="username" name="username"
type="text" type="text"
tabindex="1" tabindex="1"
auto-complete="on" autocomplete="on"
/> />
</el-form-item> </el-form-item>
@ -37,7 +37,7 @@
:placeholder="$t('login.password')" :placeholder="$t('login.password')"
name="password" name="password"
tabindex="2" tabindex="2"
auto-complete="on" autocomplete="on"
@keyup.native="checkCapslock" @keyup.native="checkCapslock"
@blur="capsTooltip = false" @blur="capsTooltip = false"
@keyup.enter.native="handleLogin" @keyup.enter.native="handleLogin"