更新代码

This commit is contained in:
guaishoudemao
2021-02-06 16:42:26 +08:00
parent f376e4302b
commit a0f56c53fe
80 changed files with 3056 additions and 2156 deletions

View File

@@ -3,23 +3,22 @@
<el-card class="box-card">
<div slot="header" class="clearfix">
<div class="container">
<el-form size="small" :inline="true" label-width="100px">
<el-form-item label="模板标题:">
<el-input v-model="tableFrom.title" placeholder="请输入模板标题" class="selWidth" size="small" clearable></el-input>
</el-form-item>
<el-form size="small" :inline="true">
<el-form-item label="所属类目:">
<el-select v-model="tableFrom.categoryId" placeholder="请选择状态" clearable class="selWidth">
<el-select v-model="tableFrom.categoryId" placeholder="请选择状态" clearable class="selWidth" @change="seachList">
<el-option :label="item.name" :value="item.id" v-for="item in categoryList" :key="item.id"></el-option>
</el-select>
</el-form-item>
<el-form-item label="模板类型:">
<el-select v-model="tableFrom.type" placeholder="请选择类型" clearable class="selWidth">
<el-select v-model="tableFrom.type" placeholder="请选择类型" clearable class="selWidth" @change="seachList">
<el-option label="一次性订阅" value="2"></el-option>
<el-option label="长期订阅" value="3"></el-option>
</el-select>
</el-form-item>
<el-form-item>
<el-button type="primary" @click="seachList" size="small">查询</el-button>
<el-form-item label="模板标题:">
<el-input v-model="tableFrom.title" placeholder="请输入模板标题" class="selWidth" size="small" clearable>
<el-button slot="append" icon="el-icon-search" @click="seachList" size="small"/>
</el-input>
</el-form-item>
</el-form>
</div>

View File

@@ -313,7 +313,8 @@ export default {
contents: {
content: JSON.parse(info.data).content,
mediaId: JSON.parse(info.data).mediaId,
srcUrl: JSON.parse(info.data).srcUrl
srcUrl: JSON.parse(info.data).srcUrl,
articleData: JSON.parse(info.data).articleData
}
}
this.labelarr = info.keywords.split(',') || []
@@ -417,7 +418,7 @@ export default {
}, 1000)
}).catch(() => {
setTimeout(() => {
this.$router.push({ path: `/publicAccount/wxReply/keyword` })
this.$router.push({ path: `/appSetting/publicAccount/wxReply/keyword` })
}, 500)
})
}

View File

@@ -156,8 +156,7 @@
parentMenuId: null,
list: [],
checkedMenuId: null,
isTrue: false,
isAsync: false
isTrue: false
}
},
mounted() {
@@ -186,7 +185,7 @@
},
// 获取 菜单
getMenus() {
wechatMenuApi({ isAsync:this.isAsync }).then(async res => {
wechatMenuApi().then(async res => {
const data = res.menu
this.list = data.button
})
@@ -297,10 +296,11 @@
pagepath: '',
id: 0
}
this.isTrue = true
this.isTrue = false
this.modal2 = false
this.checkedMenuId = null
this.$refs['formValidate'].resetFields()
this.submenus('formValidate')
}
}
}

View File

@@ -3,20 +3,19 @@
<el-card class="box-card">
<div slot="header" class="clearfix">
<div class="container">
<el-form size="small" :inline="true" label-width="100px">
<el-form size="small" :inline="true" >
<el-form-item label="状态:">
<el-select v-model="tableFrom.status" placeholder="请选择状态" clearable class="selWidth">
<el-select v-model="tableFrom.status" placeholder="请选择状态" clearable class="selWidth" @change="seachList">
<el-option :label="item.label" :value="item.value" v-for="(item, index) in switchData" :key="index"></el-option>
</el-select>
</el-form-item>
<el-form-item label="模板名称:">
<el-input v-model="tableFrom.name" placeholder="请输入模板名称" class="selWidth" size="small" clearable></el-input>
</el-form-item>
<el-form-item>
<el-button type="primary" @click="seachList" size="small">查询</el-button>
<el-input v-model="tableFrom.name" placeholder="请输入模板名称" class="selWidth" size="small" clearable>
<el-button slot="append" icon="el-icon-search" @click="seachList" size="small"/>
</el-input>
</el-form-item>
</el-form>
<el-button type="primary" @click="add" size="small">添加模板消息</el-button>
<!--<el-button type="primary" @click="add" size="small">添加模板消息</el-button>-->
</div>
</div>
<el-table
@@ -76,12 +75,12 @@
label="添加时间"
min-width="150"
/>
<el-table-column label="操作" min-width="150" fixed="right" align="center">
<template slot-scope="scope">
<el-button type="text" size="small" @click="edit(scope.row)">编辑</el-button>
<el-button type="text" size="small" @click="handleDelete(scope.row, scope.$index)">删除</el-button>
</template>
</el-table-column>
<!--<el-table-column label="操作" min-width="150" fixed="right" align="center">-->
<!--<template slot-scope="scope">-->
<!--<el-button type="text" size="small" @click="edit(scope.row)">编辑</el-button>-->
<!--<el-button type="text" size="small" @click="handleDelete(scope.row, scope.$index)">删除</el-button>-->
<!--</template>-->
<!--</el-table-column>-->
</el-table>
<div class="block">
<el-pagination
@@ -131,7 +130,8 @@
page: 1,
limit: 20,
status: '',
name: ''
name: '',
type: this.$route.params.type
},
tableData: {
data: [],

View File

@@ -4,11 +4,8 @@
<div slot="header" class="clearfix">
<div class="container">
<el-form inline size="small">
<el-form-item>
<el-input class="selWidth" v-model="listPram.keywords" placeholder="请输入关键词" clearable />
</el-form-item>
<el-form-item>
<el-select v-model="listPram.cid" clearable placeholder="请选择文章分类">
<el-form-item label="文章分类:">
<el-select v-model="listPram.cid" clearable class="selWidth" placeholder="请选择文章分类" @change="handerSearch">
<el-option
v-for="item in categoryTreeData"
:key="item.id"
@@ -17,8 +14,10 @@
</el-option>
</el-select>
</el-form-item>
<el-form-item>
<el-button type="primary" @click="handerSearch">搜索</el-button>
<el-form-item label="关键词:">
<el-input v-model="listPram.keywords" placeholder="请输入关键词" class="selWidth" size="small" clearable>
<el-button slot="append" icon="el-icon-search" @click="handerSearch" size="small"/>
</el-input>
</el-form-item>
</el-form>
</div>

View File

@@ -10,8 +10,8 @@
<div class="content" v-if="sales">
<span class="content-number spBlock mb15">{{ sales.count }}</span>
<div>
<span class="content-time mr20"><i class="content-is" :class="Number(sales.dayRate)>=0?'up':'down'">{{ sales.dayRate }}%</i><i :class="Number(sales.dayRate)>=0?'el-icon-caret-top':'el-icon-caret-bottom'" /></span>
<span class="content-time"><i class="content-is" :class="Number(sales.weekRate)>=0?'up':'down'">{{ sales.weekRate }}%</i><i :class="Number(sales.weekRate)>=0?'el-icon-caret-top':'el-icon-caret-bottom'" /></span>
<span class="content-time mr20"><i class="content-is" :class="Number(sales.dayRate)>=0?'up':'down'">{{ sales.dayRate }}%</i><i :class="Number(sales.dayRate)>=0?'el-icon-caret-top':'el-icon-caret-bottom'" /></span>
<span class="content-time"><i class="content-is" :class="Number(sales.weekRate)>=0?'up':'down'">{{ sales.weekRate }}%</i><i :class="Number(sales.weekRate)>=0?'el-icon-caret-top':'el-icon-caret-bottom'" /></span>
</div>
<el-divider></el-divider>
<div class="acea-row row-between-wrapper">
@@ -30,8 +30,8 @@
<div class="content" v-if="views">
<span class="content-number spBlock mb15">{{ views.count }}</span>
<div>
<span class="content-time mr20"><i class="content-is" :class="Number(views.dayRate)>=0?'up':'down'">{{ views.dayRate }}%</i><i :class="Number(views.dayRate)>=0?'el-icon-caret-top':'el-icon-caret-bottom'" /></span>
<span class="content-time"><i class="content-is" :class="Number(views.weekRate)>=0?'up':'down'">{{ views.weekRate }}%</i><i :class="Number(views.weekRate)>=0?'el-icon-caret-top':'el-icon-caret-bottom'" /></span>
<span class="content-time mr20"><i class="content-is" :class="Number(views.dayRate)>=0?'up':'down'">{{ views.dayRate }}%</i><i :class="Number(views.dayRate)>=0?'el-icon-caret-top':'el-icon-caret-bottom'" /></span>
<span class="content-time"><i class="content-is" :class="Number(views.weekRate)>=0?'up':'down'">{{ views.weekRate }}%</i><i :class="Number(views.weekRate)>=0?'el-icon-caret-top':'el-icon-caret-bottom'" /></span>
</div>
<el-divider></el-divider>
<div class="acea-row row-between-wrapper">
@@ -50,8 +50,8 @@
<div class="content" v-if="order">
<span class="content-number spBlock mb15">{{ order.count }}</span>
<div>
<span class="content-time mr20"><i class="content-is" :class="Number(order.dayRate)>=0?'up':'down'">{{ order.dayRate }}%</i><i :class="Number(order.dayRate)>=0?'el-icon-caret-top':'el-icon-caret-bottom'" /></span>
<span class="content-time"><i class="content-is" :class="Number(order.weekRate)>=0?'up':'down'">{{ order.weekRate }}%</i><i :class="Number(order.weekRate)>=0?'el-icon-caret-top':'el-icon-caret-bottom'" /></span>
<span class="content-time mr20"><i class="content-is" :class="Number(order.dayRate)>=0?'up':'down'">{{ order.dayRate }}%</i><i :class="Number(order.dayRate)>=0?'el-icon-caret-top':'el-icon-caret-bottom'" /></span>
<span class="content-time"><i class="content-is" :class="Number(order.weekRate)>=0?'up':'down'">{{ order.weekRate }}%</i><i :class="Number(order.weekRate)>=0?'el-icon-caret-top':'el-icon-caret-bottom'" /></span>
</div>
<el-divider></el-divider>
<div class="acea-row row-between-wrapper">
@@ -70,8 +70,8 @@
<div class="content" v-if="user">
<span class="content-number spBlock mb15">{{ user.count }}</span>
<div>
<span class="content-time mr20"><i class="content-is" :class="Number(user.dayRate)>=0?'up':'down'">{{ user.dayRate }}%</i><i :class="Number(user.dayRate)>=0?'el-icon-caret-top':'el-icon-caret-bottom'" /></span>
<span class="content-time"><i class="content-is" :class="Number(user.weekRate)>=0?'up':'down'">{{ user.weekRate }}%</i><i :class="Number(user.weekRate)>=0?'el-icon-caret-top':'el-icon-caret-bottom'" /></span>
<span class="content-time mr20"><i class="content-is" :class="Number(user.dayRate)>=0?'up':'down'">{{ user.dayRate }}%</i><i :class="Number(user.dayRate)>=0?'el-icon-caret-top':'el-icon-caret-bottom'" /></span>
<span class="content-time"><i class="content-is" :class="Number(user.weekRate)>=0?'up':'down'">{{ user.weekRate }}%</i><i :class="Number(user.weekRate)>=0?'el-icon-caret-top':'el-icon-caret-bottom'" /></span>
</div>
<el-divider></el-divider>
<div class="acea-row row-between-wrapper">

View File

@@ -74,7 +74,7 @@
return {
grid: {
xl: 3,
lg: 6,
lg: 3,
md: 6,
sm: 8,
xs: 8

View File

@@ -24,7 +24,7 @@
<el-radio-group v-model="promoterForm.storeBrokerageStatus">
<el-radio label="1">指定分销</el-radio>
<el-radio label="2">人人分销</el-radio>
<el-radio label="3">满额分销</el-radio>
<!--<el-radio label="3">满额分销</el-radio>-->
</el-radio-group>
</el-form-item>
<el-form-item prop="brokerageBindind">
@@ -91,15 +91,15 @@
</span>
<el-input-number v-model="promoterForm.extractTime" :min="0" class="selWidth" placeholder="佣金冻结时间(天)"></el-input-number>
</el-form-item>
<el-form-item prop="storeBrokeragePrice">
<span slot="label">
<span>满额分销最低金额</span>
<el-tooltip class="item" effect="dark" content="满额分销满足金额开通分销权限" placement="top-start">
<i class="el-icon-warning-outline" />
</el-tooltip>
</span>
<el-input-number v-model="promoterForm.storeBrokeragePrice" placeholder="满额分销满足金额开通分销权限" :min="0" :precision="2" :step="0.1" class="selWidth"></el-input-number>
</el-form-item>
<!--<el-form-item prop="storeBrokeragePrice">-->
<!--<span slot="label">-->
<!--<span>满额分销最低金额</span>-->
<!--<el-tooltip class="item" effect="dark" content="满额分销满足金额开通分销权限" placement="top-start">-->
<!--<i class="el-icon-warning-outline" />-->
<!--</el-tooltip>-->
<!--</span>-->
<!--<el-input-number v-model="promoterForm.storeBrokeragePrice" placeholder="满额分销满足金额开通分销权限" :min="0" :precision="2" :step="0.1" class="selWidth"></el-input-number>-->
<!--</el-form-item>-->
<el-form-item>
<el-button size="mini" type="primary" :loading="loading" @click="submitForm('promoterForm')">提交</el-button>
</el-form-item>

View File

@@ -58,33 +58,33 @@
/>
<el-table-column
sortable
label="订单数量"
label="推广订单数量"
prop="spreadOrderNum"
min-width="120"
prop="payCount"
/>
<el-table-column
sortable
label="推广订单金额"
min-width="120"
prop="payCount"
prop="spreadOrderTotalPrice"
/>
<el-table-column
sortable
label="佣金金额"
label="佣金金额"
min-width="120"
prop="brokeragePrice"
prop="totalBrokeragePrice"
/>
<el-table-column
sortable
label="已提现金额"
min-width="120"
prop="brokeragePrice"
prop="extractCountPrice"
/>
<el-table-column
sortable
label="提现金额"
label="提现次数"
min-width="120"
prop="brokeragePrice"
prop="extractCountNum"
/>
<el-table-column
sortable
@@ -135,7 +135,7 @@
>
<div class="container">
<el-form size="small" label-width="100px">
<el-form-item label="时间选择:" class="width100">
<el-form-item v-if="this.onName !== 'man'" key="1" label="时间选择:" class="width100">
<el-radio-group v-model="spreadFrom.dateLimit" type="button" class="mr20" size="small" @change="selectChangeSpread(spreadFrom.dateLimit)">
<el-radio-button v-for="(item,i) in fromList.fromTxt" :key="i" :label="item.val">{{ item.text }}</el-radio-button>
</el-radio-group>
@@ -319,7 +319,6 @@
// 统计
spreadStatistics() {
spreadStatisticsApi({ dateLimit: this.tableFrom.dateLimit, keywords: this.tableFrom.nickName}).then((res) => {
//this.cardLists = res
this.cardLists = [
{ name: '分销人员人数', count: res.distributionNum },
{ name: '发展会员人数', count: res.developNum },
@@ -423,7 +422,8 @@
this.tableFrom.dateLimit = tab
this.tableFrom.page = 1
this.timeVal = []
this.getList()
this.spreadStatistics()
// this.getList()
},
// 具体日期
onchangeTime(e) {

View File

@@ -43,21 +43,26 @@
min-width="130"
/>
<el-table-column
sortable
prop="totalBrokerage"
label="总佣金金额"
min-width="120"
/>
<el-table-column
sortable
label="账户余额"
min-width="100"
prop="nowMoney"
/>
<el-table-column
sortable
:default-sort = "{prop: 'brokerage', order: 'descending'}"
prop="brokerage"
label="账户佣金"
min-width="200"
/>
<el-table-column
sortable
prop="totalExtract"
label="到账佣金"
min-width="150"
@@ -116,17 +121,12 @@
highlight-current-row
>
<el-table-column
prop="nickName"
label="昵称"
width="80"
/>
<el-table-column
prop="number"
prop="price"
label="佣金金额"
min-width="100"
/>
<el-table-column
prop="createTime"
prop="updateTime"
label="获得时间"
min-width="120"
/>

View File

@@ -139,7 +139,8 @@
/>
<el-table-column label="操作" min-width="80" fixed="right" align="center">
<template slot-scope="scope">
<el-button type="text" size="small" @click="handleEdit(scope.row)">编辑</el-button>
<el-button v-if="scope.row.status !== 1" type="text" size="small" @click="handleEdit(scope.row)">编辑</el-button>
<span v-else></span>
</template>
</el-table-column>
</el-table>
@@ -345,6 +346,6 @@
<style scoped>
.selWidth{
width: 300px;
width: 350px;
}
</style>

View File

@@ -10,13 +10,13 @@
</el-radio-group>
<el-date-picker v-model="timeVal" value-format="yyyy-MM-dd" format="yyyy-MM-dd" size="small" type="daterange" placement="bottom-end" placeholder="自定义时间" style="width: 250px;" @change="onchangeTime" />
</el-form-item>
<el-form-item label="是否支付:">
<el-radio-group v-model="tableFrom.paid" type="button" size="small" @change="getList(1)">
<el-radio-button label="">全部</el-radio-button>
<el-radio-button label="1">已支付</el-radio-button>
<el-radio-button label="0">未支付</el-radio-button>
</el-radio-group>
</el-form-item>
<!--<el-form-item label="是否支付:">-->
<!--<el-radio-group v-model="tableFrom.paid" type="button" size="small" @change="getList(1)">-->
<!--<el-radio-button label="">全部</el-radio-button>-->
<!--<el-radio-button label="1">已支付</el-radio-button>-->
<!--<el-radio-button label="0">未支付</el-radio-button>-->
<!--</el-radio-group>-->
<!--</el-form-item>-->
<el-form-item label="关键字:" class="width100">
<el-input v-model="tableFrom.keywords" placeholder="微信昵称/姓名/订单号" class="selWidth" size="small" clearable>
<el-button slot="append" icon="el-icon-search" size="small" @click="getList(1)" />
@@ -76,14 +76,14 @@
prop="givePrice"
:sort-method="(a,b)=>{return a.givePrice - b.givePrice}"
/>
<el-table-column
label="是否支付"
min-width="80"
>
<template slot-scope="scope">
<span class="spBlock">{{ scope.row.paid | payStatusFilter }}</span>
</template>
</el-table-column>
<!--<el-table-column-->
<!--label="是否支付"-->
<!--min-width="80"-->
<!--&gt;-->
<!--<template slot-scope="scope">-->
<!--<span class="spBlock">{{ scope.row.paid | payStatusFilter }}</span>-->
<!--</template>-->
<!--</el-table-column>-->
<el-table-column
label="充值类型"
min-width="80"
@@ -100,12 +100,12 @@
<span class="spBlock">{{ scope.row.payTime || '无' }}</span>
</template>
</el-table-column>
<el-table-column label="操作" min-width="120" fixed="right" align="center">
<template slot-scope="scope">
<el-button type="text" size="small" @click="handleDelete(scope.row)" v-if="!scope.row.paid">删除</el-button>
<el-button type="text" size="small" @click="handleRefund(scope.row)" v-if="parseFloat(scope.row.refundPrice) <= 0 && scope.row.paid">退款</el-button>
</template>
</el-table-column>
<!--<el-table-column label="操作" min-width="120" fixed="right" align="center">-->
<!--<template slot-scope="scope">-->
<!--<el-button type="text" size="small" @click="handleDelete(scope.row)" v-if="!scope.row.paid">删除</el-button>-->
<!--<el-button type="text" size="small" @click="handleRefund(scope.row)" v-if="parseFloat(scope.row.refundPrice) <= 0 && scope.row.paid">退款</el-button>-->
<!--</template>-->
<!--</el-table-column>-->
</el-table>
<div class="block">
<el-pagination

View File

@@ -140,8 +140,8 @@ export default {
wxCode: ''
},
loginRules: {
account: [{ required: true, trigger: 'blur' }], // validator: validateUsername
pwd: [{ required: true, trigger: 'blur', validator: validatePassword }],
account: [{ required: true, trigger: 'blur', message: '请输入用户名' }], // validator: validateUsername
pwd: [{ required: true, trigger: 'blur', message: '请输入密码' }],
code: [{ required: true, message: '请输入正确的验证码', trigger: 'blur' }]
},
passwordType: 'password',
@@ -241,7 +241,7 @@ export default {
getInfo() {
getLoginPicApi().then(res => {
this.swiperList = res.banner
this.loginLogo = res.logo
this.loginLogo = res.loginLogo
this.backgroundImages = res.backgroundImage
// Cookies.set('MerInfo', JSON.stringify(data))
})
@@ -484,6 +484,7 @@ export default {
.containerSamll {
/*width: 56% !important;*/
width: 670px;
background: #fff !important;
}
@@ -493,6 +494,7 @@ export default {
}
.index_from {
width: 384px;
padding: 0 40px 32px 40px;
height: 400px;
box-sizing: border-box;

View File

@@ -21,7 +21,6 @@
:highlight-current-row="selectModel"
size="mini"
class="table"
highlight-current-row
@current-change="handleCurrentRowChange"
>
<el-table-column label="ID" prop="id" width="80"/>
@@ -45,7 +44,6 @@
</el-card>
<el-dialog
:visible.sync="editDialogConfig.visible"
title="title"
fullscreen
:title="editDialogConfig.isCreate === 0? '创建表单':'编辑表单'"
destroy-on-close

View File

@@ -104,7 +104,7 @@
</el-col>
<el-col :span="24">
<el-form-item label="砍价人数:" prop="peopleNum">
<el-input-number v-model="formValidate.peopleNum" :min="2" :step="1" step-strictly step-strictly placeholder="请输入砍价人数" class="selWidthd mr20"/>
<el-input-number v-model="formValidate.peopleNum" :min="2" :step="1" step-strictly placeholder="请输入砍价人数" class="selWidthd mr20"/>
<span>需邀请多少人砍价成功</span>
</el-form-item>
</el-col>
@@ -493,7 +493,7 @@
});
}
if(tit==='1'&& num === 'duo' ){
_this.specType ? _this.ManyAttrValue[i].image = img[0].sattDir : _this.ManyAttrValue[0].image = img[0].sattDir
_this.ManyAttrValue[i].image = img[0].sattDir
}
},tit, 'content')
},
@@ -558,7 +558,7 @@
this.fullscreenLoading = true
productDetailApi(id).then(async res => {
this.formValidate = {
image: res.image,
image: this.$selfUtil.setDomain(res.image),
imagess: JSON.parse(res.sliderImage),
title: res.storeName,
info: res.storeInfo,
@@ -585,12 +585,14 @@
if(res.specType){
res.attrValues.forEach((row) => {
row.quota = row.stock;
row.image = this.$selfUtil.setDomain(row.image)
});
this.ManyAttrValue = res.attrValues
this.multipleSelection = res.attrValues
}else{
res.attrValue.forEach((row) => {
row.quota = row.stock;
row.image = this.$selfUtil.setDomain(row.image)
});
this.ManyAttrValue = res.attrValue
this.radio = res.attrValue[0]
@@ -605,8 +607,8 @@
this.fullscreenLoading = true
bargainInfoApi({id:id}).then(async res => {
this.formValidate = {
image: res.image,
imagess: res.sliderImage?JSON.parse(res.sliderImage):[],
image: this.$selfUtil.setDomain(res.image),
imagess: JSON.parse(res.sliderImage),
title: res.title,
proName: res.title,
info: res.info,
@@ -633,6 +635,7 @@
this.ManyAttrValue = res.attrValues;
this.$nextTick(() => {
this.ManyAttrValue.forEach((item, index) => {
item.image = this.$selfUtil.setDomain(item.image)
if (item.checked) {
this.radio = item
}
@@ -640,6 +643,9 @@
});
}else{
this.ManyAttrValue = res.attrValue;
this.ManyAttrValue.forEach((item, index) => {
item.image = this.$selfUtil.setDomain(item.image)
})
this.formValidate.attr = [];
this.radio = res.attrValue[0];
}

View File

@@ -57,7 +57,6 @@
v-model="termTime"
type="datetimerange"
range-separator=""
format="yyyy - MM - dd - HH : mm : ss"
value-format="yyyy-MM-dd HH:mm:ss"
start-placeholder="开始日期"
:picker-options="pickerOptions"
@@ -76,11 +75,11 @@
v-model="isForeverTime"
type="datetimerange"
range-separator=""
format="yyyy - MM - dd - HH : mm : ss"
value-format="yyyy-MM-dd HH:mm:ss"
:picker-options="pickerOptions"
start-placeholder="开始日期"
end-placeholder="结束日期">
end-placeholder="结束日期"
@blur="handleTimestamp">
</el-date-picker>
</el-form-item>
<el-form-item label="领取方式" prop="resource">
@@ -133,7 +132,6 @@
loading: false,
threshold: false,
termTime: [],
isForeverTime: [],
props2: {
children: 'child',
label: 'name',
@@ -164,21 +162,31 @@
status: false,
checked: []
},
isForeverTime: [],
rules: {
name: [
{ required: true, message: '请输入优惠券名称', trigger: 'blur' },
{ required: true, message: '请输入优惠券名称', trigger: 'blur' }
],
day: [
{ required: true, message: '请输入使用有效期限(天)', trigger: 'blur' },
{ required: true, message: '请输入使用有效期限(天)', trigger: 'blur' }
],
money: [
{ required: true, message: '请输入优惠券面值', trigger: 'blur' },
{ required: true, message: '请输入优惠券面值', trigger: 'blur' }
],
primaryKey: [
{ required: true, message: '请选择品类', trigger: 'change' },
{ required: true, message: '请选择品类', trigger: 'change' }
],
checked: [
{ required: true, message: '请至少选择一个商品', trigger: 'change', type: 'array' },
{ required: true, message: '请至少选择一个商品', trigger: 'change', type: 'array' }
],
isForeverTime: [
{ required: true, message: '请选择领取时间', trigger: 'change', type: 'array' }
],
total: [
{ required: true, message: '请输入发布数量', trigger: 'blur' }
],
minPrice: [
{ required: true, message: '请输入最低消费', trigger: 'blur' }
]
}
}
@@ -188,6 +196,9 @@
if( this.$route.params.id ) this.getInfo()
},
methods: {
handleTimestamp(){
},
// 商品分类;
getCategorySelect() {
categoryApi({ status: -1, type: 1 }).then(res => {
@@ -219,7 +230,7 @@
}
info.minPrice == 0 ? this.threshold = false : this.threshold = true
info.isForever ? this.isForeverTime = [info.receiveStartTime, info.receiveEndTime] : this.isForeverTime = []
info.isFixedTime ? this.termTime = [info.useStartTime, info.useEndTime] : this.termTime = []
info.isFixedTime && info.useStartTime && info.useEndTime ? this.termTime = [info.useStartTime, info.useEndTime] : this.termTime = []
this.loading = false
}).catch(res => {
this.loading = false
@@ -236,6 +247,8 @@
},'many',_this.ruleForm.checked)
},
submitForm(formName) {
if( (this.ruleForm.isFixedTime && !this.termTime) || this.ruleForm.isFixedTime && !this.termTime.length) return this.$message.warning("请选择使用有效期限")
if( (this.ruleForm.isForever && !this.isForeverTime) || (this.ruleForm.isForever && !this.isForeverTime.length)) return this.$message.warning("请选择请选择领取时间")
if( this.ruleForm.useType === 2 ) this.ruleForm.primaryKey = this.ruleForm.checked.map(item => {return item.id}).join(',')
if( this.ruleForm.useType === 1 ) this.ruleForm.primaryKey = ''
if( !this.threshold ) this.ruleForm.minPrice = 0
@@ -246,7 +259,7 @@
this.ruleForm.isForever && this.isForeverTime.length ? this.ruleForm.receiveEndTime = this.isForeverTime[1] : this.ruleForm.receiveEndTime = ''
this.$refs[formName].validate((valid) => {
if (valid) {
this.loading = true
this.loading = true
couponSaveApi(this.ruleForm).then(() => {
this.$message.success("新增成功")
this.loading = false

View File

@@ -112,7 +112,7 @@
<template slot-scope="scope">
<el-button type="text" class="mr10" size="small" @click="receive(scope.row)">领取记录</el-button>
<router-link :to=" { path: '/marketing/coupon/list/save/' + scope.row.id } ">
<el-button type="text" size="small">复制</el-button>
<el-button v-if="scope.row.status" type="text" size="small">复制</el-button>
</router-link>
</template>
</el-table-column>

View File

@@ -17,7 +17,7 @@
label-width="180px"
@submit.native.prevent
>
<!-- 砍价商品-->
<!-- 拼团商品-->
<div v-show="currentTab === 0">
<el-form-item label="选择商品:" prop="image">
<div class="upLoadPicBox" @click="changeGood">
@@ -99,13 +99,13 @@
</el-col>
<el-col :span="24">
<el-form-item label="拼团时效(单位 小时)" prop="effectiveTime">
<el-input-number v-model="formValidate.effectiveTime" :min="1" :step="1" step-strictly step-strictly placeholder="请输入拼团人数" class="selWidthd mr20"/>
<el-input-number v-model="formValidate.effectiveTime" :min="1" :step="1" step-strictly placeholder="请输入拼团人数" class="selWidthd mr20"/>
<span>用户发起拼团后开始计时需在设置时间内邀请到规定好友人数参团超过时效时间则系统判定拼团失败自动发起退款</span>
</el-form-item>
</el-col>
<el-col :span="24">
<el-form-item label="拼团人数:" prop="people">
<el-input-number v-model="formValidate.people" :min="2" :step="1" step-strictly step-strictly placeholder="请输入拼团人数" class="selWidthd mr20"/>
<el-input-number v-model="formValidate.people" :min="2" :step="1" step-strictly placeholder="请输入拼团人数" class="selWidthd mr20"/>
<span>单次拼团需要参与的用户数</span>
</el-form-item>
</el-col>
@@ -117,13 +117,13 @@
</el-col>
<el-col :span="24">
<el-form-item label="单次购买数量限制:" prop="onceNum">
<el-input-number v-model="formValidate.onceNum" :min="1" :step="1" step-strictly placeholder="请输入购买数量限制" class="selWidthd mr20"/>
<el-input-number v-model="formValidate.onceNum" :min="1" :max="formValidate.num" :step="1" step-strictly placeholder="请输入购买数量限制" class="selWidthd mr20"/>
<span>用户参与拼团时一次购买最大数量限制例如设置为2表示参与拼团时用户一次购买数量最大可选择2个</span>
</el-form-item>
</el-col>
<el-col :span="24">
<el-form-item label="补齐人数:" prop="peopleNum">
<el-input-number v-model="formValidate.peopleNum" :min="0" :max="formValidate.people - 1" :step="1" step-strictly placeholder="请输入补齐人数" class="selWidthd mr20"/>
<el-form-item label="补齐人数:" prop="virtualRation">
<el-input-number v-model="formValidate.virtualRation" :min="0" :max="formValidate.people - 1" :step="1" step-strictly placeholder="请输入补齐人数" class="selWidthd mr20"/>
<span>当用户参与拼团后成团时效内未成团情况下设置补齐人数可虚拟成团例如成团人数为10人补齐人数为4人真实用户需要参与6人成团才可以在最后未成团时自动补齐虚拟人员</span>
</el-form-item>
</el-col>
@@ -147,14 +147,14 @@
</div>
</el-form-item>
</el-col>
<el-col v-bind="grid2">
<el-form-item label="热门推荐:" required>
<el-radio-group v-model="formValidate.isHost">
<el-radio :label="false" class="radio">关闭</el-radio>
<el-radio :label="true">开启</el-radio>
</el-radio-group>
</el-form-item>
</el-col>
<!--<el-col v-bind="grid2">-->
<!--<el-form-item label="热门推荐:" required>-->
<!--<el-radio-group v-model="formValidate.isHost">-->
<!--<el-radio :label="false" class="radio">关闭</el-radio>-->
<!--<el-radio :label="true">开启</el-radio>-->
<!--</el-radio-group>-->
<!--</el-form-item>-->
<!--</el-col>-->
<el-col v-bind="grid2">
<el-form-item label="活动状态:" required>
<el-radio-group v-model="formValidate.isShow">
@@ -214,7 +214,6 @@
:max="scope.row.stock"
:step="1" step-strictly
class="priceBox"
@change="inpChange(scope.row[iii], scope.row.id)"
/>
<span v-else v-text="scope.row[iii]" class="priceBox" />
</template>
@@ -308,7 +307,7 @@
timeVal: [],
effectiveTime: 0,
people: 2,
peopleNum: 0
virtualRation: 0
}
const objTitle = {
price: {
@@ -402,7 +401,7 @@
timeVal:[
{ required: true, message: '请选择活动日期', trigger: 'change', type: 'array'}
],
peopleNum:[
virtualRation:[
{ required: true, message: '请输入补齐人数', trigger: 'blur'}
],
onceNum: [
@@ -456,18 +455,6 @@
})
this.multipleSelection = val;
},
inpChange(currentValue, id){
// this.ManyAttrValue.map(item => {
// if(!currentValue && item.id ===id){
// item.quota = 1
// this.$set(item, 'quota', 1)
// this.ManyAttrValue = Object.assign([], this.ManyAttrValue)
// }
// })
console.log(this.ManyAttrValue)
// if(!currentValue) item.quota = 1
},
watCh(val) {
const tmp = {}
const tmpTab = {}
@@ -499,7 +486,7 @@
});
}
if(tit==='1'&& num === 'duo' ){
_this.specType ? _this.ManyAttrValue[i].image = img[0].sattDir : _this.ManyAttrValue[0].image = img[0].sattDir
_this.ManyAttrValue[i].image = img[0].sattDir
}
},tit, 'content')
@@ -520,8 +507,7 @@
},
handleSubmitNest1() {
if (!this.formValidate.image) {
this.$message.warning("请选择商品!");
return;
return this.$message.warning("请选择商品!");
} else {
this.currentTab++;
if (!this.$route.params.id) this.getProdect(this.productId);
@@ -564,9 +550,9 @@
getProdect(id) {
this.fullscreenLoading = true
productDetailApi(id).then(async res => {
this.formValidate = res;
//this.formValidate = res;
this.formValidate = {
image: res.image,
image: this.$selfUtil.setDomain(res.image),
imagelist: JSON.parse(res.sliderImage),
title: res.storeName,
info: res.storeInfo,
@@ -600,6 +586,7 @@
});
this.$nextTick(() => {
res.attrValues.forEach((row) => {
row.image = this.$selfUtil.setDomain(row.image)
this.$refs.multipleTable.toggleRowSelection(row, true);
this.$set(row, 'checked', true)
});
@@ -621,9 +608,9 @@
getSekllProdect(id) {
this.fullscreenLoading = true
combinationInfoApi({id:id}).then(async res => {
this.formValidate = res;
//this.formValidate = res;
this.formValidate = {
image: res.image,
image: this.$selfUtil.setDomain(res.image),
imagelist: JSON.parse(res.sliderImage),
title: res.title,
info: res.info,
@@ -648,13 +635,13 @@
effectiveTime : res.effectiveTime,
isPostage: false,
startTime: res.startTimeStr || '',
stopTime: res.stopTimeStr || '',
peopleNum : Math.floor(res.people-res.virtualRation/100*res.people)
stopTime: res.stopTimeStr || ''
}
if(res.specType){
this.ManyAttrValue = res.attrValues;
this.$nextTick(() => {
this.ManyAttrValue.forEach((item, index) => {
item.image = this.$selfUtil.setDomain(item.image)
if (item.checked) {
this.$set(item, 'price', item.price)
this.$set(item, 'quota', item.quota)
@@ -709,7 +696,7 @@
this.formValidate.attrValue = this.multipleSelection
}
this.formValidate.images = JSON.stringify(this.formValidate.imagelist);
this.formValidate.virtualRation = Math.floor((this.formValidate.people - this.formValidate.peopleNum) / this.formValidate.people * 100)
// this.formValidate.virtualRation = Math.floor((this.formValidate.people - this.formValidate.peopleNum) / this.formValidate.people * 100)
this.$refs[name].validate((valid) => {
if (valid) {
this.fullscreenLoading = true;

View File

@@ -192,7 +192,6 @@
:max="scope.row.stock"
:step="1" step-strictly
class="priceBox"
@change="inpChange(scope.row[iii], scope.row.id)"
/>
<span v-else v-text="scope.row[iii]" class="priceBox" />
<!--<el-input v-model="scope.row[iii]" :type="formThead[iii].title==='商品编号'?'text':'number'" class="priceBox" />-->
@@ -419,18 +418,6 @@
this.getCategorySelect()
},
methods: {
inpChange(currentValue, id){
// this.ManyAttrValue.map(item => {
// if(!currentValue && item.id ===id){
// item.quota = 1
// this.$set(item, 'quota', 1)
// this.ManyAttrValue = Object.assign([], this.ManyAttrValue)
// }
// })
console.log(this.ManyAttrValue)
// if(!currentValue) item.quota = 1
},
watCh(val) {
const tmp = {}
const tmpTab = {}
@@ -464,7 +451,7 @@
});
}
if(tit==='1'&& num === 'duo' ){
_this.specType ? _this.ManyAttrValue[i].image = img[0].sattDir : _this.ManyAttrValue[0].image = img[0].sattDir
_this.ManyAttrValue[i].image = img[0].sattDir
}
},tit, 'content')
},
@@ -484,8 +471,7 @@
},
handleSubmitNest1() {
if (!this.formValidate.image) {
this.$message.warning("请选择商品!");
return;
return this.$message.warning("请选择商品!");
} else {
this.currentTab++;
if (!this.$route.params.id) this.getProdect(this.productId);
@@ -530,7 +516,7 @@
productDetailApi(id).then(async res => {
let info = res
this.formValidate = {
image: info.image,
image: this.$selfUtil.setDomain(info.image),
imagess: JSON.parse(info.sliderImage),
title: info.storeName,
info: info.storeInfo,
@@ -559,6 +545,7 @@
});
this.$nextTick(() => {
info.attrValues.forEach((row) => {
row.image = this.$selfUtil.setDomain(row.image)
this.$refs.multipleTable.toggleRowSelection(row, true);
this.$set(row, 'checked', true)
});
@@ -582,8 +569,8 @@
seckillStoreInfoApi({id:id}).then(async res => {
let info = res
this.formValidate = {
image: info.image,
imagess: JSON.parse(info.sliderImage) || [],
image: this.$selfUtil.setDomain(info.image),
imagess: JSON.parse(info.sliderImage),
title: info.title,
info: info.info,
quota: info.quota,
@@ -609,6 +596,7 @@
this.ManyAttrValue = info.attrValues;
this.$nextTick(() => {
this.ManyAttrValue.forEach((item, index) => {
item.image = this.$selfUtil.setDomain(item.image)
if (item.checked) {
this.$set(item, 'price', item.price)
this.$set(item, 'quota', item.quota)

View File

@@ -129,11 +129,11 @@
</el-table-column>
<el-table-column
label="订单状态"
min-width="150"
min-width="180"
>
<template slot-scope="scope">
<div v-if="scope.row.statusStr.key === 'refunding'" class="refunding">
<b style="color: #f124c7;">申请退款</b>
<div v-if="scope.row.refundStatus === 1 || scope.row.refundStatus === 2" class="refunding">
<b style="color: #f124c7;">{{scope.row.statusStr.value}}</b>
<span>退款原因{{scope.row.refundReasonWap}}</span>
<span>备注说明{{scope.row.refundReasonWapExplain}}</span>
<span>退款时间{{scope.row.refundReasonTime}}</span>
@@ -172,10 +172,9 @@
<el-dropdown-item @click.native="onOrderDetails(scope.row.id)">订单详情</el-dropdown-item>
<el-dropdown-item @click.native="onOrderLog(scope.row.id)">订单记录</el-dropdown-item>
<el-dropdown-item @click.native="onOrderMark(scope.row)">订单备注</el-dropdown-item>
<el-dropdown-item v-show="scope.row.statusStr.key === 'refunding'" @click.native="onOrderRefuse(scope.row)">拒绝退款</el-dropdown-item>
<!--(scope.row.payPrice == 0 && [0,1].indexOf(scope.row.refundStatus) !== -1))-->
<!--&& (parseFloat(scope.row.payPrice) >= parseFloat(scope.row.refundPrice))-->
<el-dropdown-item v-show="((scope.row.statusStr.key !== 'refunded' && scope.row.statusStr.key !== 'unPaid') && (parseFloat(scope.row.payPrice) >= parseFloat(scope.row.refundPrice))) || (scope.row.payPrice == 0 && [0,1].indexOf(scope.row.refundStatus) !== -1)" @click.native="onOrderRefund(scope.row)">立即退款</el-dropdown-item>
<el-dropdown-item v-show="scope.row.refundStatus === 1" @click.native="onOrderRefuse(scope.row)">拒绝退款</el-dropdown-item>
<!--v-show="((scope.row.statusStr.key !== 'refunded' && scope.row.statusStr.key !== 'unPaid') && (parseFloat(scope.row.payPrice) >= parseFloat(scope.row.refundPrice))) || (scope.row.payPrice == 0 && [0,1].indexOf(scope.row.refundStatus) !== -1)"-->
<el-dropdown-item v-show="scope.row.refundStatus === 1" @click.native="onOrderRefund(scope.row)">立即退款</el-dropdown-item>
<el-dropdown-item v-show="scope.row.statusStr.key === 'deleted'" @click.native="handleDelete(scope.row, scope.$index)">删除订单</el-dropdown-item>
</el-dropdown-menu>
</el-dropdown>

View File

@@ -29,7 +29,7 @@
<div class="description-term">交付邮费{{orderDatalist.payPostage}}</div>
<div class="description-term">优惠券金额{{orderDatalist.couponPrice}}</div>
<div class="description-term">实际支付{{orderDatalist.payPrice}}</div>
<div class="description-term" v-if="orderDatalist.refundPrice">退款金额{{orderDatalist.refundPrice}}</div>
<div class="description-term fontColor3" v-if="orderDatalist.refundPrice">退款金额{{orderDatalist.refundPrice}}</div>
<div class="description-term" v-if="orderDatalist.useIntegral">使用积分{{orderDatalist.useIntegral}}</div>
<div class="description-term" v-if="orderDatalist.backIntegral">退回积分{{orderDatalist.backIntegral}}</div>
<div class="description-term">创建时间{{orderDatalist.createTime}}</div>
@@ -94,14 +94,13 @@
</div>
</div>
<span slot="footer" class="dialog-footer">
<el-button @click="dialogVisible = false"> </el-button>
<el-button type="primary" @click="dialogVisible = false"> </el-button>
<el-button type="primary" @click="modal2 = false">关闭</el-button>
</span>
</el-dialog>
</div>
</template>
<script>
<script>0
import { orderDetailApi, getLogisticsInfoApi } from '@/api/order'
export default {
name: 'OrderDetail',

View File

@@ -9,7 +9,7 @@
<template v-if="current === 0">
<el-form-item prop="phone">
<el-input type="text" v-model="formInline.phone" prefix="ios-contact-outline"
placeholder="请输入手机号" size="large"/>
placeholder="请输入手机号" size="large" :readonly="infoData.phone?true:false"/>
</el-form-item>
<el-form-item prop="code" class="captcha">
<div class="acea-row" style="flex-wrap: nowrap;">
@@ -102,6 +102,7 @@
}
};
return {
isReadonly: false,
cutNUm: '获取验证码',
canClick: true,
current: 0,
@@ -128,6 +129,15 @@
}
}
},
props:{
infoData: {
type: Object,
default: null
}
},
mounted(){
this.infoData ? this.formInline.phone = this.infoData.phone : this.formInline.phone = '';
},
methods: {
// 短信验证码
cutDown () {

View File

@@ -9,7 +9,7 @@
<template v-if="current === 0">
<el-form-item prop="account">
<el-input type="text" v-model="formInline.account" prefix="ios-contact-outline"
placeholder="请输入当前手机号" size="large"/>
placeholder="请输入当前号" size="large"/>
</el-form-item>
<el-form-item prop="password">
<el-input type="password" v-model="formInline.password" prefix="ios-contact-outline"
@@ -62,7 +62,7 @@
</template>
<script>
import { captchaApi, configApi, updateHoneApi } from '@/api/sms';
import { captchaApi, configApi, updateHoneApi, phoneValidatorApi } from '@/api/sms';
export default {
name: 'forgetPhone',
props: {
@@ -113,7 +113,7 @@
{ required: true, message: '请输入密码', trigger: 'blur' }
],
account: [
{ required: true, validator: validatePhone, trigger: 'blur' }
{ required: true, message: '请输入当前账号', trigger: 'blur' }
]
}
}
@@ -147,7 +147,10 @@
handleSubmit1 (name) {
this.$refs[name].validate((valid) => {
if (valid) {
this.handleSubmit(name,1);
phoneValidatorApi(this.formInline).then(async res => {
this.$message.success('操作成功')
this.current = 1;
})
} else {
return false;
}

View File

@@ -38,7 +38,11 @@
<el-button size="mini" :loading="loading" type="primary" style="width:100%;margin-bottom:20px;"
@click="handleSubmit('formInline')">登录
</el-button>
<el-button size="mini" type="text" style="width: 100%;margin-left: 0" @click="changeReg">注册账户</el-button>
<div class="acea-row row-center-wrapper">
<el-button size="mini" type="text" style="margin-left: 0" @click="changePassword">忘记密码</el-button>
<el-divider direction="vertical"></el-divider>
<el-button size="mini" type="text" style="margin-left: 0" @click="changeReg">注册账户</el-button>
</div>
</el-form>
</el-col>
</el-row>
@@ -84,7 +88,7 @@ export default {
this.passwordType = 'password'
}
this.$nextTick(() => {
this.$refs.token.focus()
this.$refs.password.focus()
})
},
handleSubmit(name) {
@@ -104,7 +108,7 @@ export default {
}
})
},
// 休息密码
// 修改密码
changePassword() {
this.$emit('on-change')
},

View File

@@ -299,11 +299,15 @@ export default {
},
watch: {
sms (n) {
console.log(n)
if (n.open === 1) this.getList();
}
},
mounted() {
if (this.isChecked === '1' && this.sms.open === 1) this.getList();
console.log(this.isChecked)
console.log(this.sms.open)
if (this.sms.open === 1) this.getList();
// if (this.isChecked === '1' && this.sms.open === 1) this.getList();
},
methods: {
editSign(){

View File

@@ -44,8 +44,8 @@
</el-card>
<el-card class="box-card" v-loading="loading">
<table-list v-if="isShowList" ref="tableLists" :sms="sms" :copy="copy" :dump="dump" :query="query" :accountInfo="accountInfo" @openService="openService"/>
<login-from v-if="isShowLogn" @on-changes="onChangeReg" @on-Login="onLogin" />
<forget-password v-if="isShow" @goback="goback" @on-Login="onLogin" :isIndex="isIndex"></forget-password>
<login-from v-if="isShowLogn" @on-change="onChangePasssword" @on-changes="onChangeReg" @on-Login="onLogin" />
<forget-password :infoData="infoData" v-if="isShow" @goback="goback" @on-Login="onLogin" :isIndex="isIndex"></forget-password>
<forget-phone v-if="isForgetPhone" @gobackPhone="gobackPhone" @on-Login="onLogin"></forget-phone>
<register-from v-if="isShowReg" @on-change="logoup" />
</el-card>
@@ -81,7 +81,8 @@ export default {
sms: { open: 0 }, // 短信信息
query: { open: 0 }, // 物流查询
dump: { open: 0 }, // 电子面单打印
copy: { open: 0 } // 商品采集
copy: { open: 0 }, // 商品采集,
infoData: {}
}
},
computed: {
@@ -130,6 +131,14 @@ export default {
this.isIndex = true;
this.passsword();
},
// 忘记密码
onChangePasssword () {
this.isIndex = false;
this.passsword();
// this.isShowLogn = false;
// this.isShow = true;
// this.isShowList = false;
},
passsword () {
this.isShowLogn = false;
this.isShow = true;
@@ -143,6 +152,7 @@ export default {
this.loading = true;
smsInfoApi().then(async res => {
let data = res;
this.infoData = res;
this.sms = {
num: data.sms.num,
open: data.sms.open,
@@ -207,6 +217,7 @@ export default {
logoutApi().then(async res => {
this.isShowLogn = true
this.isShowList = false
this.infoData.phone = '';
this.$store.dispatch('user/isLogin')
})
},

View File

@@ -92,7 +92,7 @@
<el-tag
v-for="(tag, index) in formValidate.coupons"
:key="index"
class="mr10"
class="mr10 mb10"
closable
:disable-transitions="false"
@close="handleCloseCoupon(tag)"
@@ -561,11 +561,6 @@
this.setTagsViewTitle()
this.getInfo()
}
// if( this.formValidate.attr.length ){
// this.formValidate.attr.map(item => {
// this.$set(item, 'inputVisible', false)
// })
// }
this.getCategorySelect()
this.getShippingList()
},
@@ -868,9 +863,9 @@
this.isAttr = false;
let info = res
this.formValidate = {
image: info.image,
sliderImages: JSON.parse(info.sliderImage),
image: this.$selfUtil.setDomain(info.image),
sliderImage: info.sliderImage,
sliderImages: JSON.parse(info.sliderImage),
storeName: info.storeName,
storeInfo: info.storeInfo,
keyword: info.keyword,
@@ -898,6 +893,12 @@
couponIds: info.couponIds,
activity: info.activityStr ? info.activityStr.split(',') : ['默认','秒杀','砍价','拼团']
}
let imgs = JSON.parse(info.sliderImage)
let imgss = []
Object.keys(imgs).map(i => {
imgss.push(this.$selfUtil.setDomain(imgs[i]))
})
this.formValidate.sliderImages = [ ...imgss ]
if(info.isHot) this.checkboxGroup.push('isHot')
if(info.isGood) this.checkboxGroup.push('isGood')
if(info.isBenefit) this.checkboxGroup.push('isBenefit')
@@ -914,9 +915,9 @@
})
this.ManyAttrValue = info.attrValues;
this.ManyAttrValue.forEach((val) => {
val.image = this.$selfUtil.setDomain(val.image)
this.attrInfo[Object.values(val.attrValue).sort().join('/')] = val
})
const tmp = {}
const tmpTab = {}
this.formValidate.attr.forEach((o, i) => {

View File

@@ -98,7 +98,7 @@
>
<template slot-scope="scope">
<el-switch
:disabled="tableFrom.type === '5'"
:disabled="Number(tableFrom.type) > 2"
v-model="scope.row.isShow"
:active-value="true"
:inactive-value="false"
@@ -142,8 +142,8 @@
<el-dialog
title="复制淘宝、天猫、京东、苏宁"
:visible.sync="dialogVisible"
:close-on-click-modal="false"
width="1200px"
:modal="false"
class="taoBaoModal"
:before-close="handleClose">
<tao-bao v-if="dialogVisible" @handleCloseMod="handleCloseMod"></tao-bao>
@@ -295,7 +295,7 @@ export default {
<style scoped lang="scss">
.taoBaoModal{
z-index: 333 !important;
// z-index: 3333 !important;
}
.demo-table-expand{
/deep/ label{

View File

@@ -17,7 +17,7 @@
</el-select>
</el-form-item>
<el-form-item label="商品搜索:" class="mr10">
<el-input v-model="tableFrom.productSearch" placeholder="请输入商品名称商品id" class="selWidth" size="small" clearable>
<el-input v-model="tableFrom.productSearch" placeholder="请输入商品名称" class="selWidth" size="small" clearable>
<el-button slot="append" icon="el-icon-search" @click="seachList" size="small"/>
</el-input>
</el-form-item>

View File

@@ -7,9 +7,12 @@
<el-link type="primary" :underline="false">增加采集次数</el-link>
</router-link>
</span>
<el-link v-if="copyConfig.copyType && copyConfig.copyType!=1" type="primary" :underline="false" href="https://www.kancloud.cn/crmeb/crmeb_java/1909022" target="_blank">如何配置密钥</el-link>
<el-link v-if="copyConfig.copyType && copyConfig.copyType!=1" type="primary" :underline="false"
href="https://help.crmeb.net/crmeb_java/2103903" target="_blank">如何配置密钥
</el-link>
<br>
商品采集设置设置 > 系统设置 > 第三方接口设置 > 采集商品配置如配置一号通采集请先登录一号通账号无一号通请选择99Api设置</div>
商品采集设置设置 > 系统设置 > 第三方接口设置 > 采集商品配置如配置一号通采集请先登录一号通账号无一号通请选择99Api设置
</div>
</el-card>
<el-form class="formValidate mt20" ref="formValidate" :model="formValidate" :rules="ruleInline" label-width="120px"
@submit.native.prevent v-loading="loading">
@@ -38,7 +41,8 @@
</el-col>
<el-col :span="24">
<el-form-item label="商品简介:">
<el-input v-model="formValidate.storeInfo" maxlength="250" type="textarea" :rows="3" placeholder="请输入商品简介"></el-input>
<el-input v-model="formValidate.storeInfo" maxlength="250" type="textarea" :rows="3"
placeholder="请输入商品简介"></el-input>
</el-form-item>
</el-col>
<el-col :span="24">
@@ -47,29 +51,29 @@
class="selWidth" :show-all-levels="false"/>
</el-form-item>
</el-col>
<el-col v-bind="grid">
<el-col :span="24">
<el-form-item label="商品关键字:" prop="keyword">
<el-input v-model="formValidate.keyword" placeholder="请输入商品关键字"></el-input>
</el-form-item>
</el-col>
<el-col v-bind="grid">
<el-form-item label="单位:" prop="unitName">
<el-input v-model="formValidate.unitName" placeholder="请输入单位"></el-input>
<el-input v-model="formValidate.unitName" placeholder="请输入单位" class="selWidth"></el-input>
</el-form-item>
</el-col>
<el-col v-bind="grid">
<el-form-item label="积分:">
<el-input-number v-model="formValidate.giveIntegral" placeholder="请输入排序" />
<el-input-number v-model="formValidate.giveIntegral" placeholder="请输入排序" class="selWidth"/>
</el-form-item>
</el-col>
<el-col v-bind="grid">
<el-form-item label="虚拟销量:">
<el-input-number v-model="formValidate.ficti" placeholder="请输入排序" />
<el-input-number v-model="formValidate.ficti" placeholder="请输入排序" class="selWidth"/>
</el-form-item>
</el-col>
<el-col v-bind="grid">
<el-form-item label="运费模板:" prop="tempId">
<el-select v-model="formValidate.tempId" placeholder="请选择" class="selWidthd mr20">
<el-select v-model="formValidate.tempId" placeholder="请选择" class="selWidth">
<el-option
v-for="item in shippingList"
:key="item.id"
@@ -194,8 +198,17 @@
</template>
<script>
import {crawlFromApi, treeListApi, crawlSaveApi, categoryApi, importProductApi, productCreateApi, copyConfigApi} from '@/api/store';
import { shippingTemplatesList } from '@/api/logistics'
import {
copyProductApi,
crawlFromApi,
treeListApi,
crawlSaveApi,
categoryApi,
importProductApi,
productCreateApi,
copyConfigApi
} from '@/api/store';
import {shippingTemplatesList} from '@/api/logistics'
const defaultObj = [{
image: '',
price: null,
@@ -253,32 +266,32 @@
page: 1,
limit: 9999
},
shippingList:[],
merCateList:[],
shippingList: [],
merCateList: [],
images: '',
url: '',
modalPic: false,
isChoice: '',
ruleInline: {
storeName: [
{ required: true, message: '请输入商品名称', trigger: 'blur' }
{required: true, message: '请输入商品名称', trigger: 'blur'}
],
cateIds: [
{ required: true, message: '请选择商品分类', trigger: 'change', type: 'array', min: '1' }
{required: true, message: '请选择商品分类', trigger: 'change', type: 'array', min: '1'}
],
unitName: [
{ required: true, message: '请输入单位', trigger: 'blur' }
{required: true, message: '请输入单位', trigger: 'blur'}
],
tempId: [
{required: true, message: '请选择运费模板', trigger: 'change', type: 'number'}
],
keyword: [
{ required: true, message: '请输入商品关键字', trigger: 'blur' }
{required: true, message: '请输入商品关键字', trigger: 'blur'}
]
},
grid: {
xl: 8,
lg: 8,
xl: 12,
lg: 12,
md: 12,
sm: 24,
xs: 24
@@ -303,7 +316,7 @@
},
watch: {
'formValidate.attr': {
handler: function(val) {
handler: function (val) {
this.watCh(val)
},
immediate: false,
@@ -319,9 +332,9 @@
delAttrTable(index) {
this.ManyAttrValue.splice(index, 1)
},
getCopyConfig(){
getCopyConfig() {
copyConfigApi().then(res => {
this.copyConfig = res
this.copyConfig = res
})
},
// 批量添加
@@ -343,7 +356,7 @@
const tmp = {}
const tmpTab = {}
this.formValidate.attr.forEach((o, i) => {
tmp['value' + i] = { title: o.attrName }
tmp['value' + i] = {title: o.attrName}
tmpTab['value' + i] = ''
})
this.ManyAttrValue = this.attrFormat(val)
@@ -355,12 +368,13 @@
let data = []
const res = []
return format(arr)
function format(arr) {
if (arr.length > 1) {
arr.forEach((v, i) => {
if (i === 0) data = arr[i]['attrValue']
const tmp = []
data.forEach(function(vv) {
data.forEach(function (vv) {
arr[i + 1] && arr[i + 1]['attrValue'] && arr[i + 1]['attrValue'].forEach(g => {
const rep2 = (i !== 0 ? '' : arr[i]['attrName'] + '_') + vv + '$&' + arr[i + 1]['attrName'] + '_' + g
tmp.push(rep2)
@@ -407,7 +421,7 @@
volume: 0,
brokerage: 0,
brokerage_two: 0,
attrValue: { [v['attrName']]: vv }
attrValue: {[v['attrName']]: vv}
}
Object.values(res[kk].attrValue).forEach((v, i) => {
res[kk]['value' + i] = v
@@ -435,7 +449,7 @@
},
// 商品分类;
goodsCategory() {
categoryApi({ status: -1, type: 1 }).then(res => {
categoryApi({status: -1, type: 1}).then(res => {
this.merCateList = res
})
},
@@ -447,10 +461,53 @@
// return this.$message.warning('请输入以http开头的地址');
// }
this.loading = true;
importProductApi({ url: this.url, form: this.form}).then(res => {
this.copyConfig.copyType == 1 ? copyProductApi({url: this.url}).then(res => {
let info = res.info;
this.formValidate = {
image: res.image,
sliderImages: JSON.parse(res.sliderImage),
image: this.$selfUtil.setDomain(info.image),
sliderImage: info.sliderImage,
storeName: info.storeName,
storeInfo: info.storeInfo,
keyword: info.keyword,
cateIds: info.cateId ? info.cateId.split(',') : [], // 商品分类id
cateId: info.cateId,// 商品分类id传值
unitName: info.unitName,
sort: 0,
isShow: 0,
isBenefit: 0,
isNew: 0,
isGood: 0,
isHot: 0,
isBest: 0,
tempId: info.tempId,
attrValue: info.attrValue,
attr: info.attr || [],
selectRule: info.selectRule,
isSub: false,
content: info.content,
specType: info.attr.length ? true : false,
id: info.id,
giveIntegral: info.giveIntegral,
ficti: info.ficti
}
let imgs = JSON.parse(info.sliderImage)
let imgss = []
Object.keys(imgs).map(i => {
imgss.push(this.$selfUtil.setDomain(imgs[i]))
})
this.formValidate.sliderImages = imgss
if (this.formValidate.attr.length) {
this.oneFormBatch[0].image = this.$selfUtil.setDomain(info.image)
for (var i = 0; i < this.formValidate.attr.length; i++) {
this.formValidate.attr[i].attrValue = JSON.parse(this.formValidate.attr[i].attrValues)
}
}
this.loading = false;
}).catch(() => {
this.loading = false;
}) : importProductApi({url: this.url, form: this.form}).then(res => {
this.formValidate = {
image: this.$selfUtil.setDomain(res.image),
sliderImage: res.sliderImage,
storeName: res.storeName,
storeInfo: res.storeInfo,
@@ -476,8 +533,14 @@
giveIntegral: res.giveIntegral,
ficti: res.ficti
}
if(this.formValidate.attr.length){
this.oneFormBatch[0].image = res.image
let imgs = JSON.parse(res.sliderImage)
let imgss = []
Object.keys(imgs).map(i => {
imgss.push(this.$selfUtil.setDomain(imgs[i]))
})
this.formValidate.sliderImages = imgss
if (this.formValidate.attr.length) {
this.oneFormBatch[0].image = this.$selfUtil.setDomain(res.image)
for (var i = 0; i < this.formValidate.attr.length; i++) {
this.formValidate.attr[i].attrValue = JSON.parse(this.formValidate.attr[i].attrValues)
}
@@ -491,8 +554,8 @@
}
},
// 提交
handleSubmit (name) {
this.formValidate.attr.length ? this.formValidate.attrValue=this.ManyAttrValue:this.formValidate.attrValue=[]
handleSubmit(name) {
this.formValidate.attr.length ? this.formValidate.attrValue = this.ManyAttrValue : this.formValidate.attrValue = []
this.formValidate.cateId = this.formValidate.cateIds.join(',')
this.formValidate.sliderImage = JSON.stringify(this.formValidate.sliderImages)
for (var i = 0; i < this.formValidate.attr.length; i++) {
@@ -509,38 +572,38 @@
this.modal_loading = false
})
} else {
if(!this.formValidate.storeName || !this.formValidate.cateId || !this.formValidate.keyword
|| !this.formValidate.unitName || !this.formValidate.image){
if (!this.formValidate.storeName || !this.formValidate.cateId || !this.formValidate.keyword
|| !this.formValidate.unitName || !this.formValidate.image) {
this.$message.warning("请填写完整商品信息!");
}
}
})
},
// 点击商品图
modalPicTap (tit, num, i) {
modalPicTap(tit, num, i) {
const _this = this
this.$modalUpload(function(img) {
if(tit==='1'&& !num){
this.$modalUpload(function (img) {
if (tit === '1' && !num) {
_this.formValidate.image = img[0].sattDir
_this.OneattrValue[0].image = img[0].sattDir
}
if(tit==='2'&& !num){
if(img.length>10) return this.$message.warning("最多选择10张图片");
if(img.length + _this.formValidate.sliderImages.length > 10) return this.$message.warning("最多选择10张图片");
if (tit === '2' && !num) {
if (img.length > 10) return this.$message.warning("最多选择10张图片");
if (img.length + _this.formValidate.sliderImages.length > 10) return this.$message.warning("最多选择10张图片");
img.map((item) => {
_this.formValidate.sliderImages.push(item.sattDir)
});
}
if(tit==='1'&& num === 'dan' ){
if (tit === '1' && num === 'dan') {
_this.OneattrValue[0].image = img[0].sattDir
}
if(tit==='1'&& num === 'duo' ){
if (tit === '1' && num === 'duo') {
_this.ManyAttrValue[i].image = img[0].sattDir
}
if(tit==='1'&& num === 'pi' ){
if (tit === '1' && num === 'pi') {
_this.oneFormBatch[0].image = img[0].sattDir
}
},tit, 'store')
}, tit, 'store')
},
handleDragStart(e, item) {
this.dragging = item;
@@ -570,43 +633,48 @@
</script>
<style scoped lang="scss">
.selWidth{
width: 100%;
}
.lunBox{
display: flex;
flex-direction: column;
border: 1px solid #0bb20c;
}
.pictrueBox{
display: inline-block;
}
.selWidth {
width: 100%;
}
.pictrue{
width:111px;
height:111px;
border:1px dotted rgba(0,0,0,0.1);
display: inline-block;
position: relative;
cursor: pointer;
img{
width: 100%;
height: 100%;
}
}
.pictrueTab{
width:40px !important;
height:40px !important;
}
.upLoad {
width: 86px;
height: 86px;
border: 1px dotted rgba(0, 0, 0, 0.1);
border-radius: 4px;
background: rgba(0, 0, 0, 0.02);
cursor: pointer;
}
.ft{
color: red;
.lunBox {
display: flex;
flex-direction: column;
border: 1px solid #0bb20c;
}
.pictrueBox {
display: inline-block;
}
.pictrue {
width: 111px;
height: 111px;
border: 1px dotted rgba(0, 0, 0, 0.1);
display: inline-block;
position: relative;
cursor: pointer;
img {
width: 100%;
height: 100%;
}
}
.pictrueTab {
width: 40px !important;
height: 40px !important;
}
.upLoad {
width: 86px;
height: 86px;
border: 1px dotted rgba(0, 0, 0, 0.1);
border-radius: 4px;
background: rgba(0, 0, 0, 0.02);
cursor: pointer;
}
.ft {
color: red;
}
</style>

View File

@@ -20,7 +20,7 @@
<el-input v-model="pram.realName" placeholder="管理员姓名" />
</el-form-item>
<el-form-item label="管理员身份" prop="roles">
<el-select v-model="pram.roles" placeholder="身份" clearable multiple>
<el-select v-model="pram.roles" placeholder="身份" clearable multiple style="width: 100%">
<el-option
v-for="item,index in roleList.list"
:key="index"
@@ -29,6 +29,10 @@
/>
</el-select>
</el-form-item>
<el-form-item label="手机号" prop="phone">
<el-input type="text" v-model="pram.phone" prefix="ios-contact-outline"
placeholder="请输入手机号" size="large"/>
</el-form-item>
<el-form-item label="状态">
<el-switch v-model="pram.status" :active-value="true" :inactive-value="false" />
</el-form-item>
@@ -59,6 +63,15 @@ export default {
}
},
data() {
const validatePhone = (rule, value, callback) => {
if (!value) {
return callback(new Error('请填写手机号'));
} else if (!/^1[3456789]\d{9}$/.test(value)) {
callback(new Error('手机号格式不正确!'));
} else {
callback();
}
};
const validatePass = (rule, value, callback) => {
if (value === '') {
callback(new Error('请再次输入密码'))
@@ -78,7 +91,8 @@ export default {
realName: null,
roles: [],
status: null,
id: null
id: null,
phone: null
},
roleList: [],
rules: {
@@ -87,7 +101,10 @@ export default {
pwd: [{ required: true, message: '请填管理员密码', trigger: ['blur', 'change'] }],
repwd: [{ required: true, message: '确认密码密码', validator: validatePass, trigger: ['blur', 'change'] }],
realName: [{ required: true, message: '管理员姓名', trigger: ['blur', 'change'] }],
roles: [{ required: true, message: '管理员身份', type: 'array', trigger: ['blur', 'change'] }]
roles: [{ required: true, message: '管理员身份', type: 'array', trigger: ['blur', 'change'] }],
phone: [
{ validator: validatePhone, trigger: 'blur' }
]
}
}
},
@@ -111,7 +128,7 @@ export default {
},
initEditData() {
if (this.isCreate !== 1) return
const { account, realName, roles, level, status, id } = this.editData
const { account, realName, roles, level, status, id, phone } = this.editData
this.pram.account = account
this.pram.realName = realName
const _roles = []
@@ -123,6 +140,7 @@ export default {
this.pram.roles = _roles
this.pram.status = status
this.pram.id = id
this.pram.phone = phone
this.rules.pwd = []
this.rules.repwd = []
},

View File

@@ -42,6 +42,11 @@
/>
<el-table-column label="姓名" prop="realName" min-width="120"/>
<el-table-column label="账号" prop="account" min-width="120"/>
<el-table-column label="手机号" prop="lastTime" min-width="120">
<template slot-scope="scope">
<span>{{ scope.row.phone | filterEmpty }}</span>
</template>
</el-table-column>
<el-table-column label="身份" prop="realName" min-width="230">
<template slot-scope="scope">
<el-tag size="small" type="info" v-for="(item, index) in scope.row.roleNames.split(',')" class="mr5">{{ item }}</el-tag>
@@ -57,9 +62,35 @@
<span>{{ scope.row.lastIp | filterEmpty }}</span>
</template>
</el-table-column>
<el-table-column label="状态" prop="status" min-width="100">
<el-table-column
label="状态"
min-width="100"
>
<template slot-scope="scope">
<span>{{ scope.row.status | filterShowOrHide }}</span>
<el-switch
v-model="scope.row.status"
:active-value="true"
:inactive-value="false"
active-text="开启"
inactive-text="关闭"
@change="onchangeIsShow(scope.row)"
/>
</template>
</el-table-column>
<el-table-column
label="是否接收短信"
min-width="100"
>
<template slot-scope="scope">
<el-switch
v-model="scope.row.isSms"
:active-value="true"
:inactive-value="false"
active-text="开启"
inactive-text="关闭"
:disabled="!scope.row.phone"
@click.native="onchangeIsSms(scope.row)"
/>
</template>
</el-table-column>
<el-table-column label="删除标记" prop="status" min-width="100">
@@ -93,6 +124,7 @@
:title="editDialogConfig.isCreate === 0? '创建身份':'编辑身份'"
destroy-on-close
:close-on-click-modal="false"
width="700px"
>
<edit
v-if="editDialogConfig.visible"
@@ -142,6 +174,38 @@ export default {
this.handleGetRoleList()
},
methods: {
onchangeIsShow(row) {
systemAdminApi.updateStatusApi({id: row.id, status: row.status})
.then(async () => {
this.$message.success('修改成功');
this.handleGetAdminList()
}).catch(()=>{
row.status = !row.status
})
},
onchangeIsSms(row) {
// this.$confirm(`此操作将${!row.isSms ? '开启' : '关闭'}验证, 是否继续?`, "提示", {
// confirmButtonText: "确定",
// cancelButtonText: "取消",
// type: "warning"
// }).then(async () => {
// row.isSms = !row.isSms
// }).catch(() => {
// this.$message.error('取消操作')
// })
if(!row.phone) return this.$message({
message: '请先为管理员添加手机号!',
type: 'warning'
});
systemAdminApi.updateIsSmsApi({id: row.id})
.then(async () => {
this.$message.success('修改成功');
this.handleGetAdminList()
}).catch(()=>{
row.isSms = !row.isSms
})
},
handleSearch() {
this.listPram.page = 1
this.handleGetAdminList()

View File

@@ -259,10 +259,28 @@ export default {
},
popoverHide() {},
handleClose() {
this.dialogVisible = false
this.$refs['ruleForm'].resetFields()
this.dialogVisible = false
this.ruleForm={
name: '',
type: 1,
appoint: false,
sort: 0,
region: [{
first: 1,
firstPrice: 1,
renewal: 1,
renewalPrice: 1,
city_ids: []
}],
undelivery: 0,
free: [],
undelives: {},
city_id3: []
}
},
changeRegion(value) {
console.log(value)
// console.integralLog(value)
},
changeRadio(num) {

View File

@@ -86,7 +86,7 @@
/>
</div>
</el-card>
<CreatTemplates ref="addTemplates" @getList="getList" />
<CreatTemplates ref="addTemplates" @getList="getList"/>
</div>
</template>
@@ -115,6 +115,7 @@ export default {
components: { CreatTemplates },
data() {
return {
isShow: false,
dialogVisible: false,
form: {
keywords: ''
@@ -133,7 +134,7 @@ export default {
handleSubmit() {
this.$refs.addTemplates.dialogVisible = true
this.$refs.addTemplates.getCityList()
this.$refs.addTemplates.changType(0, this.te)
this.$refs.addTemplates.changType(0)
},
handleSearch() {
this.page = 1
@@ -162,7 +163,6 @@ export default {
},
// 编辑
bindEdit(item) {
// this.$refs.addTemplates.dialogVisible = true
this.$refs.addTemplates.getCityList()
this.$refs.addTemplates.getInfo(item.id, item.appoint)
this.$refs.addTemplates.changType(1)

View File

@@ -11,7 +11,7 @@
<el-date-picker v-model="timeVal" value-format="yyyy-MM-dd" format="yyyy-MM-dd" size="small" type="daterange" placement="bottom-end" placeholder="自定义时间" style="width: 250px;" @change="onchangeTime" />
</el-form-item>
<el-form-item label="选择门店:">
<el-select v-model="tableFrom.storeId" clearable filterable placeholder="请选择" class="selWidth" clearable @change="getList(1)">
<el-select v-model="tableFrom.storeId" filterable placeholder="请选择" class="selWidth" clearable @change="getList(1)">
<el-option
v-for="item in storeSelectList"
:key="item.id"

View File

@@ -189,7 +189,7 @@ export default {
//刪除
storeDelete(id){
let that = this;
that.$modalSure().then(() => {
that.$modalSure('删除提货点吗?').then(() => {
storeDeleteApi({ id: id }).then(() => {
that.$message.success('删除成功')
that.storeGetCount();

View File

@@ -74,8 +74,8 @@
</el-table-column>
<el-table-column label="操作" min-width="120" fixed="right" align="center">
<template slot-scope="scope">
<el-button type="text" @click="edit(scope.row.id)" class="mr10">编辑</el-button>
<!--<el-button type="text" @click="handleDelete(scope.row.id, scope.$index)">删除</el-button>-->
<el-button type="text" size="small" @click="edit(scope.row.id)" class="mr10">编辑</el-button>
<el-button type="text" size="small" @click="handleDelete(scope.row.id, scope.$index)">删除</el-button>
</template>
</el-table-column>
</el-table>
@@ -163,7 +163,7 @@
},
// 删除
handleDelete(id, idx) {
this.$modalSure().then(() => {
this.$modalSure('删除吗?所有用户已经关联的数据都会清除').then(() => {
levelDeleteApi({id:id}).then(() => {
this.$message.success('删除成功')
this.tableData.data.splice(idx, 1)

View File

@@ -31,7 +31,7 @@
<el-table-column label="操作" min-width="120" fixed="right" align="center">
<template slot-scope="scope">
<el-button class="mr10" type="text" size="small" @click="onAdd(scope.row)">编辑</el-button>
<!--<el-button type="text" size="small" @click="handleDelete(scope.row.id, scope.$index)" disable>删除</el-button>-->
<el-button type="text" size="small" @click="handleDelete(scope.row.id, scope.$index)" disable>删除</el-button>
</template>
</el-table-column>
</el-table>
@@ -132,7 +132,7 @@
},
// 删除
handleDelete(id, idx) {
this.$modalSure().then(() => {
this.$modalSure('删除吗?所有用户已经关联的数据都会清除').then(() => {
this.$route.path.indexOf('group') !== -1 ? groupDeleteApi({id:id}).then(() => {
this.$message.success('删除成功')
this.tableData.data.splice(idx, 1)

View File

@@ -52,7 +52,7 @@
<el-select v-model="userFrom.country" placeholder="请选择" class="selWidth" clearable @on-change="changeCountry">
<el-option value="" label="全部"></el-option>
<el-option value="CN" label="中国"></el-option>
<el-option value="OTHER" label="其他"></el-option>
<el-option value="OTHER" label="国外"></el-option>
</el-select>
</el-form-item>
</el-col>
@@ -333,7 +333,7 @@
<el-dialog
title="用户列表"
:visible.sync="userVisible"
width="700px">
width="900px">
<user-list v-if="userVisible" @getTemplateRow="getTemplateRow"></user-list>
<span slot="footer" class="dialog-footer">
<el-button @click="userVisible = false"> </el-button>
@@ -418,7 +418,7 @@
label="积分"
required
>
<el-input-number type="text" v-model="PointValidateForm.integralValue" :max="999999"></el-input-number>
<el-input-number type="text" step-strictly v-model="PointValidateForm.integralValue" :max="999999"></el-input-number>
</el-form-item>
</el-form>
<span slot="footer" class="dialog-footer">
@@ -430,7 +430,7 @@
<el-dialog
title="用户详情"
:visible.sync="Visible"
width="1000px"
width="1100px"
v-if="uid"
:before-close="Close">
<user-details ref="userDetails" :uid="uid" v-if="Visible"></user-details>
@@ -734,6 +734,7 @@
_this.formValidate.give_coupon_ids.push(item.coupon_id)
_this.couponData.push(item.title)
})
_this.selectionList = []
},this.userIds)
},
Close() {
@@ -784,13 +785,15 @@
this.visible = true
},
submitForm(formName) {
let data = [];
if(this.multipleSelectionAll.length){
this.multipleSelectionAll.map((item) => {
data.push(item.uid)
});
this.userIds = data.join(',');
}
// let data = [];
// if(!this.userIds){
// if(this.multipleSelectionAll.length){
// this.multipleSelectionAll.map((item) => {
// data.push(item.uid)
// });
// this.userIds = data.join(',');
// }
// }
this.$refs[formName].validate((valid) => {
if (valid) {
this.loading = true
@@ -816,13 +819,21 @@
},
setBatch(name, row){
this.batchName = name
if(row) this.userIds = row.uid
if(row){
this.userIds = row.uid
if(this.batchName ==='group'){
this.dynamicValidateForm.groupId = row.groupId?Number(row.groupId):''
}else{
this.dynamicValidateForm.groupId = row.tagId?row.tagId.split(',').map(Number):[]
}
}else{
this.dynamicValidateForm.groupId = ''
}
if (this.multipleSelectionAll.length === 0 && !row) return this.$message.warning('请选择要设置的用户')
this.dialogVisible = true
},
handleClose(){
this.dialogVisible = false
this.multipleSelectionAll = [];
this.$refs['dynamicValidateForm'].resetFields();
},
// 全选
@@ -830,6 +841,13 @@
this.selectionList = selection;
setTimeout(() => {
this.changePageCoreRecordData()
let data = [];
if(this.multipleSelectionAll.length){
this.multipleSelectionAll.map((item) => {
data.push(item.uid)
});
this.userIds = data.join(',');
}
}, 50)
},
// 搜索

View File

@@ -27,7 +27,7 @@
</el-menu>
</el-col>
<el-col :span="20">
<el-table :data="tableData.data" class="tabNumWidth" size="mini" v-loading="loading">
<el-table :data="tableData.data" class="tabNumWidth" size="mini" v-loading="loading" max-height="400">
<el-table-column
:prop="item.key"
:label="item.title"
@@ -37,7 +37,7 @@
</el-table>
<div class="block">
<el-pagination
:page-sizes="[20, 40, 60, 80]"
:page-sizes="[6, 12, 18, 24]"
:page-size="tableFrom.limit"
:current-page="tableFrom.page"
layout="total, sizes, prev, pager, next, jumper"
@@ -236,7 +236,7 @@
},
{
title: '类型',
key: 'type',
key: 'title',
minWidth: 120
},
{