bug
This commit is contained in:
@@ -61,7 +61,7 @@ export default {
|
||||
.ai-detail {
|
||||
height: 100%;
|
||||
background: #F5F6F9;
|
||||
overflow: hidden;
|
||||
overflow: hidden!important;
|
||||
|
||||
.ai-detail__title {
|
||||
margin: 0 20px;
|
||||
|
||||
@@ -20,6 +20,11 @@ const router = new VueRouter({
|
||||
name: 'welcome',
|
||||
component: () => import('../view/Welcome.vue')
|
||||
},
|
||||
{
|
||||
path: 'changePwd',
|
||||
name: 'changePwd',
|
||||
component: () => import('../view/login/ChangePwd')
|
||||
},
|
||||
{
|
||||
path: 'normalSendGoods',
|
||||
name: 'NormalSendGoods',
|
||||
|
||||
@@ -17,7 +17,7 @@
|
||||
:before-generate = "startDownload"
|
||||
name="销售数据.xls"
|
||||
worksheet="销售统计">
|
||||
<el-button size="small">导出销售数据</el-button>
|
||||
<el-button type="primary">导出销售数据</el-button>
|
||||
</json-excel>
|
||||
</template>
|
||||
</ai-search-bar>
|
||||
|
||||
@@ -8,16 +8,18 @@
|
||||
</div>
|
||||
</div>
|
||||
<div class="admin-right">
|
||||
<div class="left" @click="toActive">
|
||||
<span>{{ $store.state.userInfo.name + "(" + $store.state.userInfo.phone + ")" }}</span>
|
||||
<div :style="{marginLeft: '10px', color: $store.state.userInfo.flag == 1? 'green': 'red'}">({{ getStateInfo }})</div>
|
||||
</div>
|
||||
<el-tooltip class="item" effect="dark" content="用户激活" placement="top">
|
||||
<div class="left" @click="toActive">
|
||||
<span>会员信息:</span>
|
||||
<div :style="{marginLeft: '10px', color: $store.state.userInfo.flag == 1? 'green': 'red'}">{{ getStateInfo }}</div>
|
||||
</div>
|
||||
</el-tooltip>
|
||||
<el-dropdown @command="onMallChange" v-if="mallName">
|
||||
<div class="userinfo">
|
||||
<span>{{ mallName }}</span>
|
||||
<img src="../assets/images/bottom.png" />
|
||||
</div>
|
||||
<el-dropdown-menu slot="dropdown">
|
||||
<el-dropdown-menu slot="dropdown" style="width: 171px">
|
||||
<el-dropdown-item
|
||||
v-for="(item, index) in mallList"
|
||||
:command="item"
|
||||
@@ -26,6 +28,17 @@
|
||||
</el-dropdown-item>
|
||||
</el-dropdown-menu>
|
||||
</el-dropdown>
|
||||
<el-dropdown @command="handleClick">
|
||||
<div class="userinfo">
|
||||
<span>{{ $store.state.userInfo.name + "(" + $store.state.userInfo.phone + ")" }}</span>
|
||||
<img src="../assets/images/bottom.png" />
|
||||
</div>
|
||||
<el-dropdown-menu slot="dropdown">
|
||||
<!-- <el-dropdown-item command="phone">修改手机</el-dropdown-item> -->
|
||||
<el-dropdown-item command="pwd">修改密码</el-dropdown-item>
|
||||
<el-dropdown-item command="logout">退出登录</el-dropdown-item>
|
||||
</el-dropdown-menu>
|
||||
</el-dropdown>
|
||||
</div>
|
||||
</div>
|
||||
<div class="admin-main">
|
||||
@@ -63,12 +76,6 @@
|
||||
<span slot="title">数据统计</span>
|
||||
</el-menu-item> -->
|
||||
</el-menu>
|
||||
<div style="position: absolute; bottom: 20px; padding-left: 20px; ">
|
||||
<div style="cursor: pointer; font-size: 16px;" @click="$store.commit('SignOut', true)">
|
||||
<i class="el-icon-back" style="color: white; margin-right: 5px;"></i>
|
||||
<span style="color: white">退出</span>
|
||||
</div>
|
||||
</div>
|
||||
</el-scrollbar>
|
||||
<div class="container">
|
||||
<transition name="fade-transform" mode="out-in">
|
||||
@@ -158,7 +165,17 @@
|
||||
this.$store.commit('setMallId', e.mallId)
|
||||
location.reload()
|
||||
},
|
||||
|
||||
handleClick (e) {
|
||||
if (e === 'phone') {
|
||||
this.$router.push('changePhone')
|
||||
} else if (e === 'pwd') {
|
||||
this.$router.push('changePwd')
|
||||
} else if (e === 'userinfo') {
|
||||
this.$router.push('userInfo')
|
||||
} else {
|
||||
this.$store.commit('SignOut', true)
|
||||
}
|
||||
},
|
||||
handleClose() {
|
||||
this.form.mallId = "";
|
||||
this.form.mallName = "";
|
||||
|
||||
@@ -10,12 +10,12 @@
|
||||
<template slot="content">
|
||||
<ai-search-bar>
|
||||
<template #left>
|
||||
<el-button type="button" :icon="isBegin? 'el-icon-loading': ''" :class="isBegin ? 'el-button el-button--danger': 'el-button el-button--primary'" @click="beginRob()">{{isBegin ? '结束抢仓': '开始抢仓'}}</el-button>
|
||||
<el-button type="primary" @click="isShow = true">选择商品</el-button>
|
||||
<el-button type="primary" :loading="isBegin" @click="beginRob">{{ isBegin ? '结束抢仓': '开始抢仓' }}</el-button>
|
||||
</template>
|
||||
<template #right>
|
||||
<el-button size="small" circle icon="el-icon-refresh-right" @click="getList()"></el-button>
|
||||
<el-button size="small" circle icon="el-icon-refresh-right" @click="getList"></el-button>
|
||||
</template>
|
||||
|
||||
</ai-search-bar>
|
||||
<ai-table
|
||||
:tableData="tableData"
|
||||
@@ -24,37 +24,31 @@
|
||||
:isShowPagination="false"
|
||||
style="margin-top: 8px;"
|
||||
@selection-change="handleSelectionChange"
|
||||
@getList="getList">
|
||||
<el-table-column slot="productName" width="400px" label="商品信息" show-overflow-tooltip align="left">
|
||||
@getList="getList">center
|
||||
<el-table-column slot="productName" width="480px" label="商品信息" show-overflow-tooltip align="center">
|
||||
<template slot-scope="scope">
|
||||
<div>
|
||||
<div class="order-manage_productInfo__1pD83">
|
||||
<img :src="scope.row.productSkcPicture">
|
||||
<div>备货母单号: {{ scope.row.originalPurchaseOrderSn }}</div>
|
||||
<div>{{ scope.row.productName }}</div>
|
||||
<div>SKC: {{ scope.row.productSkcId }}</div>
|
||||
<div>货号: {{ scope.row.productSn }}</div>
|
||||
<div class="order-manage_productInfo__1pD83">
|
||||
<img :src="scope.row.productSkcPicture">
|
||||
<div class="right">
|
||||
|
||||
<div>备货母单号: {{ scope.row.originalPurchaseOrderSn }}</div>
|
||||
<div>{{ scope.row.productName }}</div>
|
||||
<div>SKC: {{ scope.row.productSkcId }}</div>
|
||||
<div>货号: {{ scope.row.productSn }}</div>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column slot="robInfo" label="抢仓信息" show-overflow-tooltip align="left">
|
||||
<el-table-column slot="robInfo" label="抢仓信息" show-overflow-tooltip align="center">
|
||||
<template slot-scope="scope">
|
||||
<div data-testid="beast-core-box" style="margin-right: 2px;">
|
||||
已抢仓 <div style="color: red; display: inline;">{{ scope.row.robTotal }}</div> 次
|
||||
</div>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column slot="status" label="状态" show-overflow-tooltip align="left">
|
||||
<el-table-column slot="className" label="SKU信息" width="440px" show-overflow-tooltip align="center">
|
||||
<template slot-scope="scope">
|
||||
<div data-testid="beast-core-box" class="outerWrapper-1-3-1 outerWrapper dot-module__dot___M-RuH " style="margin-right: 2px;">
|
||||
<div class="dot-module__circle___2l2UV" style="background-color: var(--pc-dot-warn-bg-color,#ff6800);"></div>待发货
|
||||
</div>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column slot="className" label="SKU信息" width="400px" show-overflow-tooltip align="left">
|
||||
<template slot-scope="scope">
|
||||
<div class="order-manage_skuInfo__FW-Nd" v-for="(item, index) in scope.row.detailList">
|
||||
<div class="order-manage_skuInfo__FW-Nd" v-for="(item, index) in scope.row.detailList" :key="index">
|
||||
<div>
|
||||
<div data-testid="beast-core-box" class="outerWrapper-1-3-1 outerWrapper-d18-1-3-20 index-module__image-preview___2fiZX">
|
||||
<div class="index-module__img___p3B1N" :style="getStyle(item.thumbUrlList[0])"></div>
|
||||
@@ -68,13 +62,82 @@
|
||||
</div>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column slot="status" label="状态" show-overflow-tooltip align="center" fixed="right" width="120px">
|
||||
<template slot-scope="scope">
|
||||
<div data-testid="beast-core-box" class="outerWrapper-1-3-1 outerWrapper dot-module__dot___M-RuH " style="margin-right: 2px;">
|
||||
<div class="dot-module__circle___2l2UV" style="background-color: var(--pc-dot-warn-bg-color,#ff6800);"></div>待发货
|
||||
</div>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</ai-table>
|
||||
<AiDialog
|
||||
title="选择商品"
|
||||
:visible.sync="isShow"
|
||||
:close-on-click-modal="false"
|
||||
width="1290px">
|
||||
<el-select v-model="mallId" placeholder="请选择" @click="getList">
|
||||
<el-option
|
||||
v-for="item in mallList"
|
||||
:key="item.mallId"
|
||||
:label="item.mallName"
|
||||
:value="item.mallName">
|
||||
{{ item.mallName }}
|
||||
</el-option>
|
||||
</el-select>
|
||||
<ai-table
|
||||
:tableData="tableData"
|
||||
:col-configs="colConfigs"
|
||||
:total="total"
|
||||
:isShowPagination="false"
|
||||
style="margin-top: 8px;"
|
||||
@selection-change="handleSelectionChange"
|
||||
@getList="getList">center
|
||||
<el-table-column slot="productName" width="400px" label="商品信息" show-overflow-tooltip align="center">
|
||||
<template slot-scope="scope">
|
||||
<div class="order-manage_productInfo__1pD83">
|
||||
<img :src="scope.row.productSkcPicture">
|
||||
<div class="right">
|
||||
|
||||
<div>备货母单号: {{ scope.row.originalPurchaseOrderSn }}</div>
|
||||
<div>{{ scope.row.productName }}</div>
|
||||
<div>SKC: {{ scope.row.productSkcId }}</div>
|
||||
<div>货号: {{ scope.row.productSn }}</div>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column slot="robInfo" label="抢仓信息" show-overflow-tooltip align="center">
|
||||
<template slot-scope="scope">
|
||||
<div data-testid="beast-core-box" style="margin-right: 2px;">
|
||||
已抢仓 <div style="color: red; display: inline;">{{ scope.row.robTotal }}</div> 次
|
||||
</div>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column slot="className" label="SKU信息" width="400px" show-overflow-tooltip align="center">
|
||||
<template slot-scope="scope">
|
||||
<div class="order-manage_skuInfo__FW-Nd" v-for="(item, index) in scope.row.detailList" :key="index">
|
||||
<div>
|
||||
<div data-testid="beast-core-box" class="outerWrapper-1-3-1 outerWrapper-d18-1-3-20 index-module__image-preview___2fiZX">
|
||||
<div class="index-module__img___p3B1N" :style="getStyle(item.thumbUrlList[0])"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="order-manage_contentInfo__1Cjd6" style="max-width: 150px;">
|
||||
<div class="order-manage_title__1VTO5">属性:{{ item.className }},下单数量:{{ item.purchaseQuantity }}</div>
|
||||
<div>SKU ID: {{ item.productSkuId }}</div>
|
||||
<div class="order-manage_productSku__XP_ke">SKU 货号: {{ item.extCode }}</div>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</ai-table>
|
||||
</AiDialog>
|
||||
</template>
|
||||
</ai-list>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { mapState } from 'vuex'
|
||||
import {sendChromeAPIMessage, sendChromeNotification} from '@/api/chromeApi'
|
||||
import { Message } from 'element-ui'
|
||||
export default {
|
||||
@@ -82,14 +145,16 @@
|
||||
|
||||
data () {
|
||||
return {
|
||||
isShow: false,
|
||||
colConfigs: [
|
||||
{ type: "selection", width: '70px', align: 'left', fixed: 'left'},
|
||||
{ prop: 'subPurchaseOrderSn', label: '备货单号', width: '150px', align: 'left', fixed: 'left' },
|
||||
{ slot: 'productName', fixed: 'left'},
|
||||
{ type: "selection", width: '70px', align: 'left' },
|
||||
{ prop: 'subPurchaseOrderSn', label: '备货单号', width: '180px', align: 'left' },
|
||||
{ slot: 'productName' },
|
||||
{ slot: 'className'},
|
||||
{ slot: 'robInfo'},
|
||||
{ slot: 'status' }
|
||||
],
|
||||
mallId: '',
|
||||
tableData: [],
|
||||
total: 0,
|
||||
ids: [],
|
||||
@@ -98,6 +163,8 @@
|
||||
}
|
||||
},
|
||||
|
||||
...mapState(['mallName', 'mallList']),
|
||||
|
||||
created () {
|
||||
this.getList()
|
||||
},
|
||||
@@ -259,12 +326,19 @@
|
||||
</script>
|
||||
|
||||
<style scoped lang="scss">
|
||||
.order-manage_productInfo__1pD83 {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
|
||||
.right {
|
||||
text-align: left;
|
||||
}
|
||||
}
|
||||
.order-manage_productInfo__1pD83>img {
|
||||
left: 0;
|
||||
position: absolute;
|
||||
top: 0;
|
||||
|
||||
width: 60px;
|
||||
margin-right: 10px;
|
||||
}
|
||||
.order-manage_productInfo__1pD83 {
|
||||
min-height: 60px;
|
||||
@@ -296,6 +370,7 @@
|
||||
.index-module__image-preview___2fiZX .index-module__img___p3B1N {
|
||||
width: 60px;
|
||||
height: 60px;
|
||||
margin-right: 10px;
|
||||
background-repeat: no-repeat;
|
||||
background-size: cover;
|
||||
background-color: #f5f5f5;
|
||||
@@ -312,6 +387,7 @@
|
||||
display: -moz-box;
|
||||
display: -ms-flexbox;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
.order-manage_skuInfo__FW-Nd .order-manage_contentInfo__1Cjd6 {
|
||||
|
||||
140
src/view/login/ChangePwd.vue
Normal file
140
src/view/login/ChangePwd.vue
Normal file
@@ -0,0 +1,140 @@
|
||||
<template>
|
||||
<ai-detail class="changePwd">
|
||||
<template slot="title">
|
||||
<ai-title title="修改密码" isShowBottomBorder>
|
||||
</ai-title>
|
||||
</template>
|
||||
<template slot="content">
|
||||
<ai-card title="修改密码">
|
||||
<template #content>
|
||||
<el-form class="ai-form" ref="form" :model="form" label-width="110px" label-position="right">
|
||||
<el-form-item label="旧密码" prop="oldPwd" style="width: 100%!important" :rules="[{ required: true, message: '请输入旧密码', trigger: 'blur' }]">
|
||||
<el-input v-model="form.oldPwd" size="small" type="password" style="width: 50%" placeholder="请输入旧密码"></el-input>
|
||||
</el-form-item>
|
||||
<el-form-item label="新密码" prop="newPwd" style="width: 100%!important" :rules="[{ required: true, message: '请输入新密码', trigger: 'blur' }]">
|
||||
<el-input v-model="form.newPwd" size="small" type="password" style="width: 50%" placeholder="请输入新密码"></el-input>
|
||||
</el-form-item>
|
||||
<el-form-item label="确认新密码" prop="newPwd2" style="width: 100%!important" :rules="[{ required: true, message: '请输入确认新密码', trigger: 'blur' }]">
|
||||
<el-input v-model="form.newPwd2" size="small" type="password" style="width: 50%" placeholder="请输入确认新密码"></el-input>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
</template>
|
||||
</ai-card>
|
||||
</template>
|
||||
<template #footer>
|
||||
<el-button @click="cancel">取消</el-button>
|
||||
<el-button type="primary" @click="confirm">提交</el-button>
|
||||
</template>
|
||||
</ai-detail>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
export default {
|
||||
name: 'ChangePwd',
|
||||
|
||||
data () {
|
||||
const validatorPhone = function (rule, value, callback) {
|
||||
if (value === '') {
|
||||
callback(new Error('请输入手机号'))
|
||||
} else if (!/^1\d{10}$/.test(value)) {
|
||||
callback(new Error('手机号格式错误'))
|
||||
} else {
|
||||
callback()
|
||||
}
|
||||
}
|
||||
const validatorPwd = function (rule, value, callback) {
|
||||
if (value === '') {
|
||||
callback(new Error('请输入新密码'))
|
||||
} else if (value.length < 8 || value.length > 16) {
|
||||
callback(new Error('密码长度不能小于8位大于16位'))
|
||||
} else {
|
||||
callback()
|
||||
}
|
||||
}
|
||||
return {
|
||||
form: {
|
||||
code: '',
|
||||
newPwd: '',
|
||||
phone: '',
|
||||
oldPwd: '',
|
||||
newPwd2: ''
|
||||
},
|
||||
validatorPwd,
|
||||
validatorPhone,
|
||||
timer: null,
|
||||
time: 60,
|
||||
isSend: false,
|
||||
isStart: false
|
||||
}
|
||||
},
|
||||
|
||||
created () {
|
||||
},
|
||||
|
||||
methods: {
|
||||
confirm () {
|
||||
this.$refs.form.validate((valid) => {
|
||||
if (valid) {
|
||||
if (this.form.newPwd !== this.form.newPwd2) {
|
||||
return this.$message.error('新密码和确认密码不一致')
|
||||
}
|
||||
|
||||
this.$http.post(`/api/malluser/updatePwd`, null, {
|
||||
params: {
|
||||
...this.form
|
||||
}
|
||||
}).then(res => {
|
||||
if (res.code == 0) {
|
||||
this.$message.success('密码修改成功,请重新登录')
|
||||
setTimeout(() => {
|
||||
this.$store.commit('SignOut', true)
|
||||
}, 600)
|
||||
}
|
||||
})
|
||||
}
|
||||
})
|
||||
},
|
||||
|
||||
cancel () {
|
||||
this.$router.push('/admin/home')
|
||||
},
|
||||
|
||||
getCode () {
|
||||
if (this.isSend) {
|
||||
return this.$message.error('验证码已发送')
|
||||
}
|
||||
|
||||
if (!/^1[0-9]{10,10}$/.test(this.form.phone)) {
|
||||
return this.$message.error('请输入正确到手机号')
|
||||
}
|
||||
|
||||
this.isSend = true
|
||||
this.$http.post(`/user/sendCode?phone=${this.form.phone}`).then(res => {
|
||||
if (res.code === 0) {
|
||||
this.$message.success('验证码发送成功')
|
||||
this.isStart = true
|
||||
this.timer = setInterval(() => {
|
||||
if (this.time === 0) {
|
||||
this.isSend = false
|
||||
this.isStart = false
|
||||
this.time = 60
|
||||
clearInterval(this.timer)
|
||||
|
||||
return false
|
||||
}
|
||||
|
||||
this.time = this.time - 1
|
||||
}, 1000)
|
||||
}
|
||||
}).catch(() => {
|
||||
this.isSend = false
|
||||
})
|
||||
},
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped lang="scss">
|
||||
.changePwd {
|
||||
}
|
||||
</style>
|
||||
Reference in New Issue
Block a user