Browse Source

支持多语言版本

master
xh-pan1 2 years ago
parent
commit
292de2fc66
  1. 1
      .eslintignore
  2. 2
      canvas-container/components/toolBar/toolModule/custom-page-select.vue
  3. 2
      canvas-container/components/toolBar/toolModule/notice-select.vue
  4. 4
      canvas-container/components/toolBar/toolModule/product-select.vue
  5. 2
      canvas-container/components/toolBar/toolModule/shop-select.vue
  6. 69
      canvas-container/styles/theme/index.css
  7. 12
      src/api/business.js
  8. 55
      src/api/shop.js
  9. 252
      src/components/Sharesetting/index.vue
  10. 2
      src/components/basics/couponTable.vue
  11. 2
      src/components/basics/productTable.vue
  12. 32
      src/styles/elDialog.scss
  13. 2
      src/views/active/activeDetails.vue
  14. 162
      src/views/active/seckilllist/seckillAdd.vue
  15. 2
      src/views/ad/coverConfig/index.vue
  16. 185
      src/views/business/businessList/index.vue
  17. 106
      src/views/business/settlement/addSettlement.vue
  18. 20
      src/views/business/settlement/index.vue
  19. 765
      src/views/business/shopList/index.vue
  20. 1
      src/views/channel/list/index.vue
  21. 2
      src/views/common.vue
  22. 2
      src/views/finance/application/index.vue
  23. 306
      src/views/order/after/details/index.vue
  24. 1
      src/views/order/after/index.vue
  25. 2
      src/views/order/pending/index.vue
  26. 367
      src/views/order/pending/pendDetails.vue
  27. 2
      src/views/renovation/brand/index.vue
  28. 321
      src/views/renovation/commdityClass/Edit.vue
  29. 25
      src/views/renovation/commdityClass/index.vue
  30. 2
      src/views/renovation/commoditySystem/addCommodity.vue
  31. 20
      src/views/renovation/commoditySystem/index.vue
  32. 2
      src/views/risk/IPBlacklist/index.vue
  33. 2
      src/views/risk/riskRules/index.vue
  34. 2
      src/views/risk/userBlacklist/index.vue
  35. 96
      src/views/setup/businessMenus/index.vue
  36. 424
      src/views/setup/tabs/index.vue
  37. 4
      src/views/sharesetting/index.vue

1
.eslintignore

@ -4,3 +4,4 @@ src/canvas-container
canvas-container
public
dist
src

2
canvas-container/components/toolBar/toolModule/custom-page-select.vue

@ -5,7 +5,7 @@
<el-input v-model="formData.keyword" maxlength="20" placeholder="页面名称"></el-input>
</el-form-item>
<el-form-item>
<el-button type="primary" @click="onSubmit">查询</el-button>
<el-button type="primary" @click="onSubmit">{{ $t('common.query') }}</el-button>
</el-form-item>
</el-form>
<el-table

2
canvas-container/components/toolBar/toolModule/notice-select.vue

@ -5,7 +5,7 @@
<el-input v-model="formData.keyword" maxlength="20" placeholder="店铺名称"></el-input>
</el-form-item>
<el-form-item>
<el-button type="primary" @click="onSubmit">查询</el-button>
<el-button type="primary" @click="onSubmit">{{ $t('common.query') }}</el-button>
</el-form-item>
</el-form>
<el-table

4
canvas-container/components/toolBar/toolModule/product-select.vue

@ -11,7 +11,7 @@
<!-- <el-option label="下架" value="0"></el-option>-->
<!-- </el-select>-->
<!-- </el-form-item>-->
<el-form-item label="官方分类">
<el-form-item label="商品分类">
<el-cascader
ref="cascader"
v-model="formData.categoryId"
@ -20,7 +20,7 @@
clearable></el-cascader>
</el-form-item>
<el-form-item>
<el-button type="primary" @click="onSubmit">查询</el-button>
<el-button type="primary" @click="onSubmit">{{ $t('common.query') }}</el-button>
</el-form-item>
</el-form>
<el-table

2
canvas-container/components/toolBar/toolModule/shop-select.vue

@ -5,7 +5,7 @@
<el-input v-model="formData.keyword" maxlength="20" placeholder="店铺名称"></el-input>
</el-form-item>
<el-form-item>
<el-button type="primary" @click="onSubmit">查询</el-button>
<el-button type="primary" @click="onSubmit">{{ $t('common.query') }}</el-button>
</el-form-item>
</el-form>
<el-table

69
canvas-container/styles/theme/index.css

@ -1562,7 +1562,6 @@
.el-dialog__headerbtn {
position: absolute;
top: 20px;
right: 20px;
padding: 0;
background: 0 0;
@ -4644,7 +4643,7 @@
}
.el-message-box__status.el-icon-success {
color: #67C23A
color: #183ECD
}
.el-message-box__status.el-icon-info {
@ -5961,15 +5960,15 @@
.el-alert--success.is-light {
background-color: #f0f9eb;
color: #67C23A
color: #183ECD
}
.el-alert--success.is-light .el-alert__description {
color: #67C23A
color: #183ECD
}
.el-alert--success.is-dark {
background-color: #67C23A;
background-color: #183ECD;
color: #FFF
}
@ -6140,7 +6139,7 @@
}
.el-notification .el-icon-success {
color: #67C23A
color: #183ECD
}
.el-notification .el-icon-error {
@ -9832,7 +9831,7 @@
}
.el-upload-list__item .el-icon-upload-success {
color: #67C23A
color: #183ECD
}
.el-upload-list__item .el-icon-close {
@ -10354,11 +10353,11 @@
}
.el-progress.is-success .el-progress-bar__inner {
background-color: #67C23A
background-color: #183ECD
}
.el-progress.is-success .el-progress__text {
color: #67C23A
color: #183ECD
}
.el-progress.is-warning .el-progress-bar__inner {
@ -10551,7 +10550,7 @@
}
.el-message--success .el-message__content {
color: #67C23A
color: #183ECD
}
.el-message--warning {
@ -10598,7 +10597,7 @@
}
.el-message .el-icon-success {
color: #67C23A
color: #183ECD
}
.el-message .el-icon-error {
@ -10671,7 +10670,7 @@
}
.el-badge__content--success {
background-color: #67C23A
background-color: #183ECD
}
.el-badge__content--warning {
@ -10821,8 +10820,8 @@
}
.el-step__head.is-success {
color: #67C23A;
border-color: #67C23A
color: #183ECD;
border-color: #183ECD
}
.el-step__head.is-error {
@ -10925,7 +10924,7 @@
}
.el-step__title.is-success {
color: #67C23A
color: #183ECD
}
.el-step__title.is-error {
@ -10953,7 +10952,7 @@
}
.el-step__description.is-success {
color: #67C23A
color: #183ECD
}
.el-step__description.is-error {
@ -11701,20 +11700,20 @@
.el-tag.el-tag--success {
background-color: #f0f9eb;
border-color: #e1f3d8;
color: #67c23a
color: #183ECD
}
.el-tag.el-tag--success.is-hit {
border-color: #67C23A
border-color: #183ECD
}
.el-tag.el-tag--success .el-tag__close {
color: #67c23a
color: #183ECD
}
.el-tag.el-tag--success .el-tag__close:hover {
color: #FFF;
background-color: #67c23a
background-color: #183ECD
}
.el-tag.el-tag--warning {
@ -11812,13 +11811,13 @@
}
.el-tag--dark.el-tag--success {
background-color: #67c23a;
border-color: #67c23a;
background-color: #183ECD;
border-color: #183ECD;
color: #fff
}
.el-tag--dark.el-tag--success.is-hit {
border-color: #67C23A
border-color: #183ECD
}
.el-tag--dark.el-tag--success .el-tag__close {
@ -11909,20 +11908,20 @@
.el-tag--plain.el-tag--success {
background-color: #fff;
border-color: #c2e7b0;
color: #67c23a
color: #183ECD
}
.el-tag--plain.el-tag--success.is-hit {
border-color: #67C23A
border-color: #183ECD
}
.el-tag--plain.el-tag--success .el-tag__close {
color: #67c23a
color: #183ECD
}
.el-tag--plain.el-tag--success .el-tag__close:hover {
color: #FFF;
background-color: #67c23a
background-color: #183ECD
}
.el-tag--plain.el-tag--warning {
@ -13386,7 +13385,7 @@
}
.el-timeline-item__node--success {
background-color: #67C23A
background-color: #183ECD
}
.el-timeline-item__node--warning {
@ -13519,11 +13518,11 @@
.el-link.el-link--success.is-underline:hover:after,
.el-link.el-link--success:after {
border-color: #67C23A
border-color: #183ECD
}
.el-link.el-link--success {
color: #67C23A
color: #183ECD
}
.el-link.el-link--success:hover {
@ -14027,8 +14026,8 @@
.el-button--success {
color: #FFF;
background-color: #67C23A;
border-color: #67C23A
background-color: #183ECD;
border-color: #183ECD
}
.el-button--success:focus,
@ -14059,15 +14058,15 @@
}
.el-button--success.is-plain {
color: #67C23A;
color: #183ECD;
background: #f0f9eb;
border-color: #c2e7b0
}
.el-button--success.is-plain:focus,
.el-button--success.is-plain:hover {
background: #67C23A;
border-color: #67C23A;
background: #183ECD;
border-color: #183ECD;
color: #FFF
}

12
src/api/business.js

@ -4,7 +4,7 @@ import request from '@/utils/request'
// 商家管理查询
export function businessListGetAll(data) {
return request({
url: '/shop/getAll',
url: '/business/getAll',
method: 'post',
data
})
@ -13,7 +13,7 @@ export function businessListGetAll(data) {
// 新增商家
export function businessListSave(data) {
return request({
url: '/shop/save',
url: '/business/save',
method: 'post',
data
})
@ -22,7 +22,7 @@ export function businessListSave(data) {
// 商家编辑查询
export function businessListGetById(data) {
return request({
url: '/shop/getById',
url: '/business/getById',
method: 'post',
data
})
@ -31,7 +31,7 @@ export function businessListGetById(data) {
// 修改商家
export function businessListUpdate(data) {
return request({
url: '/shop/update',
url: '/business/update',
method: 'post',
data
})
@ -40,7 +40,7 @@ export function businessListUpdate(data) {
// 启停用商家
export function businessListStart(data) {
return request({
url: '/shop/start',
url: '/business/start',
method: 'post',
data
})
@ -48,7 +48,7 @@ export function businessListStart(data) {
export function delBusinessById(data) {
return request({
url: '/shop/cleanShop',
url: '/business/cleanShop',
method: 'post',
data
})

55
src/api/shop.js

@ -0,0 +1,55 @@
import request from '@/utils/request'
// ******店铺列表******
// 店铺管理查询
export function shopListGetAll(data) {
return request({
url: '/shop/getAll',
method: 'post',
data
})
}
// 新增店铺
export function shopListSave(data) {
return request({
url: '/shop/save',
method: 'post',
data
})
}
// 店铺编辑查询
export function shopListGetById(data) {
return request({
url: '/shop/getById',
method: 'post',
data
})
}
// 修改店铺
export function shopListUpdate(data) {
return request({
url: '/shop/update',
method: 'post',
data
})
}
// 启停用店铺
export function shopListStart(data) {
return request({
url: '/shop/start',
method: 'post',
data
})
}
export function delshopById(data) {
return request({
url: '/shop/cleanShop',
method: 'post',
data
})
}

252
src/components/Sharesetting/index.vue

@ -0,0 +1,252 @@
<template>
<div class="comment_manage_page">
<!-- ******************************************************弹框开始***************************************************************** -->
<!-- 新增或者编辑评论弹框 -->
<el-dialog
:title="addForm.shareSettingId && addForm.shareSettingId > 0 ? '修改分账比例设置' : '新增分账比例设置'"
:visible.sync="dialogVisible"
:close-on-click-modal="false"
:before-close="handleClose"
width="500px"
center
>
<div>
<el-form :model="addForm" label-width="80px">
<!-- <el-form-item v-if="addForm.shareTargetType != 1"
:label="addForm.shareTargetType == 1 ? '商品分类Id' : (addForm.shareTargetType == 2 ? '商家Id' : '商品Id')" prop="shareTargetId">
<el-input v-model="addForm.shareTargetId" type="number" maxlength="20"
:placeholder="addForm.shareTargetType == 1 ? '请输入商品分类Id' : (addForm.shareTargetType == 2 ? '请输入商家Id' : '请输入商品Id')" />
</el-form-item>
<el-form-item label="商品分类" v-else prop="classifyId">
<el-cascader
v-model="addForm.classifyId"
:options="classifyList"
clearable
:props="{
checkStrictly: false,
label:'categoryName',
value:'id',
children:'childs'
}"
@change="handleChangeCascader"
/>
</el-form-item>
<el-form-item label="分账方式" prop="shareCalcType" style="display:none">
<el-radio-group v-model="addForm.shareCalcType">
<el-radio :label="1">按利润</el-radio>
<el-radio :label="0">按销售额</el-radio>
</el-radio-group>
</el-form-item>-->
<el-form-item label="分账比例" prop="shareRate">
<template slot-scope="scope">
<el-input-number v-model="addForm.shareRate" :controls="false" :max="100" :min="0" :precision="2" :step="0.01" />%
</template>
</el-form-item>
</el-form>
</div>
<span slot="footer" class="dialog-footer">
<el-button @click="dialogVisible = false"> </el-button>
<el-button type="primary" @click="addForm_enter('ruleForm')"> </el-button>
</span>
</el-dialog>
</div>
</template>
<script>
import {
sharesettingGetall,
sharesettingGetById,
sharesettingSave,
sharesettingUpdate,
sharesettingDelete
} from '@/api/sharesetting'
import {
getClassify
} from '@/api/commodity'
export default {
name: 'ShareSettingDialog',
data() {
return {
tabList: [
{ name: '商品分类', id: 1 },
{ name: '商家', id: 2 },
{ name: '商品', id:3 }
],
total: 1,
currentPage: 1,
dialogVisible: false,
classifyList:[],
addForm:{
shareSettingId:0,
name:"",
avater:"",
shareTargetId:0,
shareTargetType:0,
shareCalcType:0,
shareRate:0
}
}
},
computed : {
},
created() {
},
mounted() {
},
methods: {
showSetting(shareTargetType, shareTargetId){
this.addForm.shareTargetType = shareTargetType
this.addForm.shareTargetId = shareTargetId
this.dialogVisible = true
this.initItem()
},
async initItem(){
let formParams = {
shareTargetType: this.addForm.shareTargetType,
shareTargetId: this.addForm.shareTargetId,
page: 1,
pageSize: 10
}
const res = await sharesettingGetall(formParams)
if( res.data.total > 0){
var target = res.data.list[0]
this.addForm.shareSettingId = target.shareSettingId
this.addForm.name = target.name
this.addForm.avater = target.avater
this.addForm.shareCalcType = target.shareCalcType
this.addForm.shareRate = target.shareRate
}else{
this.addForm.shareSettingId = 0
this.addForm.name = ""
this.addForm.avater = ""
this.addForm.shareCalcType = 0
this.addForm.shareRate = 0
}
},
//
addForm_enter(ruleForm) {
if(this.addForm.shareRate < 0){
this.$message({
message: '分配比例必须大于或者等于0',
type: 'warning'
})
return false
}
if(this.addForm.shareRate > 100){
this.$message({
message: '分配比例必须小于或等于100',
type: 'warning'
})
return false
}
//0
if(this.addForm.shareRate == 0){
if (this.addForm.shareSettingId && this.addForm.shareSettingId > 0) {
sharesettingDelete({
shareSettingId: this.addForm.shareSettingId
}).then(res => {
if (res.code === '') {
this.$message.success('保存成功')
this.dialogVisible = false
}
})
}
return true;
}
if (this.addForm.shareSettingId && this.addForm.shareSettingId > 0) {
sharesettingUpdate(this.addForm).then(res => {
console.log(res)
if (res.code === '') {
this.$message({
message: '修改成功',
type: 'success'
})
}
this.dialogVisible = false
})
} else {
sharesettingSave(this.addForm).then(res => {
console.log(res)
if (res.code === '') {
this.$message({
message: '新增成功',
type: 'success'
})
}
this.dialogVisible = false
})
}
},
handleClose() {
this.dialogVisible = false
}
}
}
</script>
<style lang='scss' scoped>
@import url("../../styles/elDialog.scss");
.comment_manage_page {
padding: 20px;
background: #FFFFFF;
border-radius: 10px;
text-align:center;
}
.pinStyle {
.comment {
margin-bottom: 20px;
display: flex;
align-items: center;
.com_left {
font-size: 20px;
color: #333333;
margin-right: 20px;
}
.com_right {
font-size: 18px;
color: #333333;
}
}
.comment_imgList {
display: flex;
margin-bottom: 20px;
align-items: center;
.img_left {
font-size: 20px;
color: #333333;
margin-right: 20px;
width: 60px;
}
.imgList {
display: flex;
justify-content: flex-start;
align-items: center;
flex-wrap: wrap;
.el-image {
width: 200px;
height: 134px;
border-radius: 4px;
margin-right: 20px;
margin-bottom: 20px;
}
}
}
.line {
width: 890px;
height: 1px;
background: #e0e5eb;
margin: 0 auto;
margin-bottom: 33px;
}
.addComment {
font-size: 20px;
color: #ff7911;
margin-bottom: 20px;
}
}
</style>

2
src/components/basics/couponTable.vue

@ -9,7 +9,7 @@
<el-input v-model="formData.keyword" maxlength="20" class="inputKeyword" placeholder="请输入优惠券名称" />
</el-form-item>
<el-form-item>
<el-button type="primary" plain @click="search">查询</el-button>
<el-button type="primary" plain @click="search">{{ $t('common.query') }}</el-button>
<el-button type="info" plain @click="clear">重置</el-button>
</el-form-item>
</el-form>

2
src/components/basics/productTable.vue

@ -9,7 +9,7 @@
<el-input v-model="formData.keyword" maxlength="20" class="inputKeyword" placeholder="店铺名称/商品ID/商品分组" />
</el-form-item>
<el-form-item>
<el-button type="primary" plain @click="search">查询</el-button>
<el-button type="primary" plain @click="search">{{ $t('common.query') }}</el-button>
<el-button type="info" plain @click="clear">重置</el-button>
</el-form-item>
</el-form>

32
src/styles/elDialog.scss

@ -1,5 +1,7 @@
.el-dialog {
border-radius: 10px;
margin-top: 10vh;
margin-bottom: 5vh;
}
.el-dialog__header {
@ -65,3 +67,33 @@ font-weight: 500;
.el-table th {
text-align: center !important;
}
.el-form-item__label {
vertical-align: middle;
float: left;
padding: 0 12px 0 0;
-webkit-box-sizing: border-box;
box-sizing: border-box;
font-size: 14px;
font-family: PingFang SC;
font-weight: 400;
color: #404F64;
line-height: 36px;
text-align: left;
}
.el-radio__label {
vertical-align: middle;
padding: 0 12px 0 0;
-webkit-box-sizing: border-box;
box-sizing: border-box;
font-size: 14px;
font-family: PingFang SC;
font-weight: 400;
color: #404F64;
line-height: 36px;
text-align: left;
margin-left: 8px;
}

2
src/views/active/activeDetails.vue

@ -118,7 +118,7 @@
</el-form-item>
<el-form-item>
<el-button type="primary" plain @click="search">查询</el-button>
<el-button type="primary" plain @click="search">{{ $t('common.query') }}</el-button>
</el-form-item>
</el-form>
</div>

162
src/views/active/seckilllist/seckillAdd.vue

@ -3,43 +3,23 @@
<div class="content">
<el-form ref="form" :model="form" label-width="100px">
<div class="detail_title">基础信息</div>
<el-form-item label="活动名称:">
<el-input v-model="form.seckillName" maxlength="20" placeholder="请输入活动名称" :disabled="unStart" />
</el-form-item>
<el-form-item label="备注:">
<el-input
v-model="form.remark"
maxlength="200"
type="textarea"
placeholder="请输入活动介绍"
:disabled="unStart"
style="width: 400px;"
/>
<el-input v-model="form.remark" maxlength="200" type="textarea" placeholder="请输入活动介绍" :disabled="unStart"
style="width: 400px;" />
</el-form-item>
<!-- :picker-options="pickerOptions" -->
<el-form-item label="报名时间:">
<el-date-picker
v-model="date2"
type="datetimerange"
range-separator="至"
start-placeholder="开始时间"
end-placeholder="结束时间"
value-format="yyyy-MM-dd HH:mm:ss"
:disabled="applyEnd"
/>
<el-date-picker v-model="date2" type="datetimerange" range-separator="" start-placeholder="开始时间"
end-placeholder="结束时间" value-format="yyyy-MM-dd HH:mm:ss" :disabled="applyEnd" />
<p class="timeInfo">报名时间不能交叉且报名时间不能大于活动时间</p>
</el-form-item>
<el-form-item label="活动时间:">
<el-date-picker
v-model="date1"
type="datetimerange"
range-separator="至"
start-placeholder="开始时间"
end-placeholder="结束时间"
value-format="yyyy-MM-dd HH:mm:ss"
:disabled="applyEnd"
/>
<el-date-picker v-model="date1" type="datetimerange" range-separator="" start-placeholder="开始时间"
end-placeholder="结束时间" value-format="yyyy-MM-dd HH:mm:ss" :disabled="applyEnd" />
<p class="timeInfo">平台活动时间不能交叉并且活动时间不能小于报名时间</p>
</el-form-item>
<el-form-item label="活动保证金:">
@ -52,7 +32,7 @@
<el-input v-model="form.bondMoney" maxlength="9" placeholder="请输入活动保证金金额" :disabled="unStart" />
</el-form-item>
<div class="detail_title">优惠规则</div>
<el-form-item label="直降金额:">
<el-input v-model="form.seckillMoney" maxlength="9" placeholder="请输入活动名称" :disabled="unStart" />
</el-form-item>
@ -95,14 +75,14 @@ export default {
props: {
activityForm: {
type: Object,
default: () => {}
default: () => { }
},
isEdit: {
type: Number,
default: 0
}
},
data () {
data() {
return {
form: new Form(),
date1: [], //
@ -113,19 +93,19 @@ export default {
},
computed: {
//
unStart () {
unStart() {
const t = this.isEdit ? this.activityForm : null
return t && !(t.state === 0)
},
//
applyEnd () {
applyEnd() {
const t = this.isEdit ? this.activityForm : null
return t && (t.state === 3 || t.state === 4)
}
},
watch: {
isEdit: {
handler (nVal, oVal) {
handler(nVal, oVal) {
if (nVal) {
this.getDetails()
} else {
@ -135,21 +115,21 @@ export default {
deep: true
},
activityForm: {
handler (nVal, oVal) {
handler(nVal, oVal) {
if (nVal) {
this.getDetails()
}
}
}
},
created () {
created() {
if (this.isEdit) { // watchisEdit
this.getDetails()
}
},
methods: {
//
async getDetails () {
async getDetails() {
const res = await getSeckillDetail({ seckillId: this.activityForm.seckillId })
if (JSON.stringify(res.data) !== '{}') {
this.form = res.data
@ -157,9 +137,9 @@ export default {
this.date2 = [res.data.signStartTime, res.data.signEndTime]
}
},
cancel () { this.$emit('cancel') },
refersh () { this.$emit('refersh') },
save () {
cancel() { this.$emit('cancel') },
refersh() { this.$emit('refersh') },
save() {
const params = Object.assign({}, this.form, {
startTime: this.date1[0] || '',
endTime: this.date1[1] || '',
@ -208,7 +188,7 @@ export default {
}
})
},
reset () {
reset() {
this.form = new Form()
this.date1 = []
this.date2 = []
@ -220,42 +200,44 @@ export default {
<style lang='scss' scoped>
.edit_add_page {
padding: 0px;
.content {
overflow: hidden;
.detail_title {
font-size: 16px;
font-weight: 500;
padding-left: 10px;
line-height: 16px;
margin-bottom: 15px;
margin-top: 10px;
position: relative;
font-size: 16px;
font-weight: 500;
padding-left: 10px;
line-height: 16px;
margin-bottom: 15px;
margin-top: 10px;
position: relative;
&::before {
content: "";
height: 16px;
width: 4px;
background-color: #183ECD;
position: absolute;
left: 0px;
display: block;
font-weight: 500;
}
&::before {
content: "";
height: 16px;
width: 4px;
background-color: #183ECD;
position: absolute;
left: 0px;
display: block;
font-weight: 500;
}
::v-deep .el-form-item__label {
vertical-align: middle;
float: left;
padding: 0 12px 0 0;
-webkit-box-sizing: border-box;
box-sizing: border-box;
}
font-size: 14px;
font-family: PingFang SC;
font-weight: 400;
color: #404F64;
line-height: 36px;
text-align: left;
::v-deep .el-form-item__label {
vertical-align: middle;
float: left;
padding: 0 12px 0 0;
-webkit-box-sizing: border-box;
box-sizing: border-box;
font-size: 14px;
font-family: PingFang SC;
font-weight: 400;
color: #404F64;
line-height: 36px;
text-align: left;
}
.el-form {
@ -266,10 +248,13 @@ export default {
}
}
}
.photo {
padding: 70px 100px;
.avatar-uploader {
width: 180px;
.el-icon-plus,
img {
width: 180px;
@ -280,47 +265,54 @@ export default {
margin-bottom: 10px;
text-align: center;
}
img {
border: none;
}
}
}
}
.footer{
.footer {
height: 80px;
line-height: 80px;
font-size: 24px;
position: relative;
border-top: 1px solid #e0e5eb;
.btn_list {
position: absolute;
right: 0;
top: 0;
height: 36px;
span {
padding: 0;
margin: 0;
width: 68px;
height: 36px;
line-height: 36px;
text-align: center;
display: inline-block;
/* font-size: 16px; */
border-radius: 4px;
-webkit-box-sizing: border-box;
box-sizing: border-box;
font-size: 14px;
font-family: PingFang SC;
font-weight: 400;
margin: 0;
width: 68px;
height: 36px;
line-height: 36px;
text-align: center;
display: inline-block;
/* font-size: 16px; */
border-radius: 4px;
-webkit-box-sizing: border-box;
box-sizing: border-box;
font-size: 14px;
font-family: PingFang SC;
font-weight: 400;
&:hover {
cursor: pointer;
}
&:nth-child(1) {
background: rgba(255, 255, 255, 1);
order: 1px solid rgba(224, 229, 235, 1);
margin-right: 10px;
border: 1px solid rgba(224, 229, 235, 1);
}
&:nth-child(2) {
background: #183ECD;
color: #fff;
@ -328,11 +320,13 @@ export default {
}
}
}
.timeInfo {
font-size: 12px;
color: #999999;
}
.el-input{
.el-input {
width: 400px;
}
}

2
src/views/ad/coverConfig/index.vue

@ -105,7 +105,7 @@
>
编辑
</el-button>
<el-button slot="reference" type="danger" icon="el-icon-delete" size="mini" @click="del(scope.row.id)">删除</el-button>
<el-button slot="reference" icon="el-icon-delete" size="mini" @click="del(scope.row.id)">删除</el-button>
</div>
</template>
</el-table-column>

185
src/views/business/businessList/index.vue

@ -8,18 +8,18 @@
:inline="true"
:model="formInline"
>
<el-form-item label="店铺名称">
<el-form-item label="商家名称">
<el-input
v-model="formInline.shopName"
v-model="formInline.businessName"
maxlength="20"
placeholder="请输入店铺名称"
placeholder="请输入商家名称"
/>
</el-form-item>
<el-form-item label="店铺编码">
<el-form-item label="商家编码">
<el-input
v-model="formInline.shopCode"
v-model="formInline.businessCode"
maxlength="20"
placeholder="请输入店铺编码"
placeholder="请输入商家编码"
/>
</el-form-item>
<el-form-item label="负责人">
@ -71,21 +71,17 @@
style="width: 100%"
>
<el-table-column
label="店铺名称"
label="商家名称"
width="220"
>
<template slot-scope="scope">{{ scope.row.shopName }}</template>
<template slot-scope="scope">{{ scope.row.businessName }}</template>
</el-table-column>
<el-table-column
prop="shopCode"
label="店铺编码"
prop="businessCode"
label="商家编码"
/>
<el-table-column
prop="chargePersonName"
label="负责人"
/>
<el-table-column
prop="chargePersonPhone"
prop="businessPhone"
label="联系电话"
/>
<el-table-column label="合同状态">
@ -131,6 +127,10 @@
@click="delBusiness(scope.row)"
>删除
</el-button>
<el-button
type="text"
@click="setShareSetting(scope.row)"
>设置分配比例</el-button>
</div>
</template>
</el-table-column>
@ -178,17 +178,38 @@
label-width="120px"
>
<el-form-item
label="店铺名称"
prop="shopName"
label="商家名称"
prop="businessName"
>
<el-input
v-model="ruleForm.shopName"
v-model="ruleForm.businessName"
maxlength="20"
:disabled="disabled"
/>
</el-form-item>
<el-form-item
label="店铺负责人"
label="联系电话"
prop="businessPhone"
>
<el-input
v-if="cpPhoneShow"
:value="hidden(ruleForm.businessPhone,3,4)"
maxlength="11"
:disabled="disabled"
@focus="focusPhoneInput"
/>
<el-input
v-else
ref="phoneCls"
v-model="ruleForm.businessPhone"
maxlength="11"
clearable
:disabled="disabled"
@change="changePhoneInput"
/>
</el-form-item>
<el-form-item
label="商家负责人"
prop="chargePersonName"
>
<el-input
@ -219,17 +240,17 @@
/>
</el-form-item>
<el-form-item
label="店铺地址"
prop="shopAdress"
label="商家地址"
prop="businessAdress"
>
<el-input
ref="addressCls"
v-model="ruleForm.shopAdress"
v-model="ruleForm.businessAdress"
maxlength="60"
:disabled="disabled"
/>
<!-- <div v-else @click="inputAddress">
<el-input :value="hidden(ruleForm.shopAdress, 1, 1)" :disabled="disabled" />
<el-input :value="hidden(ruleForm.businessAdress, 1, 1)" :disabled="disabled" />
</div> -->
</el-form-item>
<el-form-item
@ -325,29 +346,29 @@
>
<el-form-item
label="账号"
prop="shopPhone"
prop="businessPhone"
>
<el-input
v-if="shopPhoneShow"
:value="hidden(ruleForm.shopPhone, 3, 4)"
v-if="businessPhoneShow"
:value="hidden(ruleForm.businessPhone, 3, 4)"
:disabled="disabled"
maxlength="20"
@focus="focusShopPhoneInput"
@focus="focusbusinessPhoneInput"
/>
<el-input
v-else
ref="shopPhoneCls"
v-model="ruleForm.shopPhone"
ref="businessPhoneCls"
v-model="ruleForm.businessPhone"
:disabled="disabled"
maxlength="20"
/>
</el-form-item>
<el-form-item
label="密码"
prop="shopPassword"
prop="businessPassword"
>
<el-input
v-model="ruleForm.shopPassword"
v-model="ruleForm.businessPassword"
type="password"
:disabled="disabled"
maxlength="16"
@ -374,6 +395,8 @@
> </el-button>
</span>
</el-dialog>
<SharesettingDialog
ref="shareSettingDialog"/>
</div>
</div>
</template>
@ -389,9 +412,9 @@ import {
businessListStart,
delBusinessById
} from '@/api/business'
import SharesettingDialog from '../../../components/Sharesetting';
export default {
components: {},
components: {SharesettingDialog},
data () {
//
return {
@ -399,26 +422,26 @@ export default {
dialogVisible: false,
activeName: 'first',
formInline: {
shopName: '', //
shopCode: '', //
chargePersonName: '', //
businessName: '', //
businessCode: '', //
chargePersonName: '', //
contractState: '', // 1- 0-
page: '1', //
pageSize: '10' //
},
disabled: false,
ruleForm: {
shopName: '', //
chargePersonName: '', //
businessName: '', //
chargePersonName: '', //
chargePersonPhone: '', //
shopAdress: '', //
businessAdress: '', //
effectiveDate: '', //
effectiveYear: '', //
contractState: 1, // 1- 0-
auditLive: 1,
auditLiveProduct: 1,
shopPhone: '', //
shopPassword: '' //
businessPhone: '', //
businessPassword: '' //
},
showPhone: false,
showAddress: false,
@ -431,11 +454,11 @@ export default {
effectiveYear: [
{ required: true, message: '请输入生效时限', trigger: 'blur' }
],
shopName: [
{ required: true, message: '请输入店铺名称', trigger: 'blur' }
businessName: [
{ required: true, message: '请输入商家名称', trigger: 'blur' }
],
chargePersonName: [
{ required: true, message: '请输入店铺负责人', trigger: 'blur' }
{ required: true, message: '请输入商家负责人', trigger: 'blur' }
],
chargePersonPhone: [
{ required: true, message: '请输入负责人电话', trigger: 'blur' },
@ -444,7 +467,7 @@ export default {
message: '目前只支持中国大陆的手机号码'
}
],
shopAdress: [
businessAdress: [
{ required: true, message: '请输入地址', trigger: 'blur' }
],
contractState: [
@ -477,14 +500,14 @@ export default {
]
},
rules: {
shopPhone: [
businessPhone: [
{ required: true, message: '请输入账号', trigger: 'blur' },
{
pattern: /^1[3456789]\d{9}$/,
message: '目前只支持中国大陆的手机号码'
}
],
shopPassword: [
businessPassword: [
{ required: true, message: '请输入密码', trigger: 'blur' },
{
@ -499,7 +522,7 @@ export default {
userState: 1,
privacyTime: 0,
cpPhoneShow: true, //
shopPhoneShow: true //
businessPhoneShow: true //
}
},
// data
@ -517,12 +540,15 @@ export default {
},
//
methods: {
focusShopPhoneInput () {
this.shopPhoneShow = false
this.ruleForm.shopPhone = ''
setShareSetting(row) {
this.$refs.shareSettingDialog.showSetting(2, row.businessId)
},
focusbusinessPhoneInput () {
this.businessPhoneShow = false
this.ruleForm.businessPhone = ''
//
this.$nextTick(() => {
this.$refs.shopPhoneCls.focus()
this.$refs.businessPhoneCls.focus()
})
},
focuscpPhoneInput () {
@ -533,6 +559,16 @@ export default {
this.$refs.cpPhoneCls.focus()
})
},
focusPhoneInput () {
this.showPhone = false
this.ruleForm.businessPhone = ''
//
this.$nextTick(() => {
this.$refs.phoneCls.focus()
})
},
changePhoneInput () {
},
changecpPhoneInput () {
},
handleSizeChange (val) {
@ -556,17 +592,17 @@ export default {
this.newAddress = ''
this.personPhone = ''
this.ruleForm = {
shopName: '', //
chargePersonName: '', //
businessName: '', //
chargePersonName: '', //
chargePersonPhone: '', //
shopAdress: '', //
businessAdress: '', //
effectiveDate: '', //
effectiveYear: '', //
contractState: 1, // 1- 0-
auditLive: 1,
auditLiveProduct: 1,
shopPhone: '', //
shopPassword: '' //
businessPhone: '', //
businessPassword: '' //
}
this.dialogVisible = true
console.log(this.userState)
@ -591,13 +627,13 @@ export default {
this.ruleForm.chargePersonPhone = this.personPhone
}
if (this.newAddress !== '') {
this.ruleForm.shopAdress = this.newAddress
this.ruleForm.businessAdress = this.newAddress
}
if (this.userPhone !== '') {
this.ruleForm.shopPhone = this.userPhone
this.ruleForm.businessPhone = this.userPhone
}
if (this.ruleForm.shopName === '') {
this.$message.error('请输入店铺名称')
if (this.ruleForm.businessName === '') {
this.$message.error('请输入商家名称')
return
}
if (this.ruleForm.effectiveDate === '') {
@ -646,9 +682,11 @@ export default {
async seeMore (row) {
this.showPhone = false
this.cpPhoneShow = true
this.shopPhoneShow = true
const res = await businessListGetById({ shopId: row.shopId })
this.businessPhoneShow = true
const res = await businessListGetById({ businessId: row.businessId })
console.log(res)
if (res.code === '') {
this.userState = 3
this.disabled = true
this.ruleForm = res.data
@ -662,7 +700,7 @@ export default {
this.userState = 1
this.disabled = false
this.cpPhoneShow = true
const res = await businessListGetById({ shopId: row.shopId })
const res = await businessListGetById({ businessId: row.businessId })
this.ruleForm = res.data
this.dialogVisible = true
console.log(this.ruleForm)
@ -672,9 +710,9 @@ export default {
console.log(row)
if (row.state === 1) {
const res = await businessListStart({
shopName: row.shopName,
businessName: row.businessName,
state: 0,
shopId: row.shopId
businessId: row.businessId
})
if (res.code === '') {
this.$message({
@ -685,9 +723,9 @@ export default {
}
} else {
const res = await businessListStart({
shopName: row.shopName,
businessName: row.businessName,
state: 1,
shopId: row.shopId
businessId: row.businessId
})
if (res.code === '') {
this.$message({
@ -706,7 +744,7 @@ export default {
type: 'warning'
}).then(async () => {
const res = await delBusinessById({
shopId: row.shopId
businessId: row.businessId
})
if (res.code === '') {
this.$message({
@ -780,6 +818,15 @@ export default {
border-radius: 10px;
}
.btnList{
display: flex;
flex-direction: row;
flex-wrap: wrap;
align-content: center;
justify-content: flex-start;
align-items: center;
}
.fenye {
margin-top: 20px;
}

106
src/views/business/settlement/addSettlement.vue

@ -9,16 +9,16 @@
>
<span>入驻申请</span>
<span
v-if="shopDetails.checkState === 2"
v-if="businessDetails.checkState === 2"
class="leftTitle"
style="color: red;"
>已拒绝</span>
<span
v-if="shopDetails.checkState === 1"
v-if="businessDetails.checkState === 1"
class="leftTitle" style="color: #33B376;"
>已通过</span>
<span
v-if="shopDetails.checkState === 0"
v-if="businessDetails.checkState === 0"
class="leftTitle"
>未处理</span>
<div class="girhtBtn">
@ -28,7 +28,7 @@
>取消
</el-button>
<el-button
v-if="shopDetails.checkState === 0"
v-if="businessDetails.checkState === 0"
type="primary"
@click="handle"
>处理
@ -40,46 +40,46 @@
<div class="msgDetail">
<div class="detail">
<div class="shop_info">
<p class="detail_title">店铺信息</p>
<p class="detail_title">商家信息</p>
<p class="detail_text">
<span>
<font>*</font>店铺名称
<font>*</font>商家名称
</span>
<span>{{ shopDetails.shopName }}</span>
<span>{{ businessDetails.businessName }}</span>
</p>
<p class="detail_text">
<span>
<font>*</font>店铺类型
<font>*</font>商家类型
</span>
<span v-if="shopDetails.authenType == 1">个人</span>
<span v-if="shopDetails.authenType == 2">个体工商户</span>
<span v-if="shopDetails.authenType == 3">企业</span>
<span v-if="shopDetails.authenType == 4">其他组织</span>
<span v-if="businessDetails.authenType == 1">个人</span>
<span v-if="businessDetails.authenType == 2">个体工商户</span>
<span v-if="businessDetails.authenType == 3">企业</span>
<span v-if="businessDetails.authenType == 4">其他组织</span>
</p>
<p class="detail_text">
<span>
<font>*</font>
客服电话
</span>
<span>{{ shopDetails.shopPhone }}</span>
<span>{{ businessDetails.businessPhone }}</span>
</p>
<p class="detail_text">
<span>
<font>*</font>店铺负责人
<font>*</font>商家负责人
</span>
<span>{{ shopDetails.chargePersonName }}</span>
<span>{{ businessDetails.chargePersonName }}</span>
</p>
<p class="detail_text">
<span>
<font>*</font>负责人电话
</span>
<span>{{ shopDetails.chargePersonPhone }}</span>
<span>{{ businessDetails.chargePersonPhone }}</span>
</p>
<p class="detail_text">
<span>
<font>*</font>店铺地址
<font>*</font>商家地址
</span>
<span>{{ shopDetails.shopAdress }}</span>
<span>{{ businessDetails.businessAdress }}</span>
</p>
</div>
<div class="shop_info">
@ -88,25 +88,25 @@
<span>
<font>*</font>名称
</span>
<span>{{ shopDetails.name }}</span>
<span>{{ businessDetails.name }}</span>
</p>
<p class="detail_text">
<span>
<font>*</font>证件信息
</span>
<span>{{ shopDetails.cardTypeName }}</span>
<span>{{ businessDetails.cardTypeName }}</span>
</p>
<p class="detail_text">
<span>
<font>*</font>身份证号码
</span>
<span>{{ shopDetails.idCard }}</span>
<span>{{ businessDetails.idCard }}</span>
</p>
<p class="detail_text">
<span>
<font>*</font>身份证有效期
</span>
<span>{{ shopDetails.cardTime }}</span>
<span>{{ businessDetails.cardTime }}</span>
</p>
<p class="detail_img">
<span>
@ -123,7 +123,7 @@
/>
</p>
<p
v-if="shopDetails && shopDetails.authenType === 1"
v-if="businessDetails && businessDetails.authenType === 1"
class="detail_img"
>
<span>
@ -131,45 +131,45 @@
</span>
<el-image
class="img_box"
:src="shopDetails.cardHand"
:preview-src-list="[shopDetails.cardHand]"
:src="businessDetails.cardHand"
:preview-src-list="[businessDetails.cardHand]"
/>
</p>
</div>
<!-- +++++++++++++++++++++ 主体信息 ++++++++++++++++++++++++++++++++++++++++++++++++ -->
<div
v-if="shopDetails.authenType !== 1"
v-if="businessDetails.authenType !== 1"
class="person_info"
>
<p class="detail_title">主体信息</p>
<p class="detail_text">
<span v-if="shopDetails.authenType == 2"><font>*</font> 商户名称</span>
<span v-if="shopDetails.authenType == 3"><font>*</font> 企业名称</span>
<span v-if="shopDetails.authenType == 4"><font>*</font> 组织名称</span>
<span>{{ shopDetails.subjectName }}</span>
<span v-if="businessDetails.authenType == 2"><font>*</font> 商户名称</span>
<span v-if="businessDetails.authenType == 3"><font>*</font> 企业名称</span>
<span v-if="businessDetails.authenType == 4"><font>*</font> 组织名称</span>
<span>{{ businessDetails.subjectName }}</span>
</p>
<p class="detail_text">
<span><font>*</font> {{ shopDetails.authenType == 4 ? '组织机构代码' : '社会信用代码' }}</span>
<span>{{ shopDetails.subjectCode }}</span>
<span><font>*</font> {{ businessDetails.authenType == 4 ? '组织机构代码' : '社会信用代码' }}</span>
<span>{{ businessDetails.subjectCode }}</span>
</p>
<p class="detail_text">
<span>
<font>*</font>注册地址
</span>
<span>{{ shopDetails.subjectAdress }}</span>
<span>{{ businessDetails.subjectAdress }}</span>
</p>
<p class="detail_text">
<span>
<font>*</font>营业期限
</span>
<span>{{ shopDetails.subjectStartTime }} - {{ shopDetails.subjectEndTime }}</span>
<span>{{ businessDetails.subjectStartTime }} - {{ businessDetails.subjectEndTime }}</span>
</p>
<p class="detail_img">
<span>
<font>*</font>{{ shopDetails.authenType == 4 ? '机构证明材料' : '营业执照' }}
<font>*</font>{{ businessDetails.authenType == 4 ? '机构证明材料' : '营业执照' }}
</span>
<img
v-for="(src, index) in shopDetails.subjectLicense"
v-for="(src, index) in businessDetails.subjectLicense"
:key="'id' + index"
:src="src"
:preview="2"
@ -183,14 +183,14 @@
<span>
<font>*</font>生效日期
</span>
<span>{{ shopDetails.effectiveDate }}</span>
<span>{{ businessDetails.effectiveDate }}</span>
</p>
<p class="detail_text">
<span>
<font>*</font>生效时限
</span>
<span>{{ shopDetails.effectiveYear }}</span>
<span v-if="shopDetails.effectiveYear"></span>
<span>{{ businessDetails.effectiveYear }}</span>
<span v-if="businessDetails.effectiveYear"></span>
</p>
</div>
</div>
@ -295,13 +295,13 @@ export default {
data() {
//
return {
shopId: '',
shopDetails: {},
businessId: '',
businessDetails: {},
addFormDialog: false,
idCardCopyFilePath: [],
chooseDate: '',
addForm: {
shopId: '', // id
businessId: '', // id
checkHandle: '', // 1- 0-
effectiveDate: '', // null- -
effectiveYear: '', //
@ -312,22 +312,22 @@ export default {
watch: {
businessData: {
handler(nVal, oVal) {
this.shopDetails = {}
this.businessDetails = {}
this.idCardCopyFilePath = []
this.shopId = nVal.shopId
this.shopDetails = nVal
this.shopDetails.idCard = hidden(this.shopDetails.idCard, 4, 4)
this.businessId = nVal.businessId
this.businessDetails = nVal
this.businessDetails.idCard = hidden(this.businessDetails.idCard, 4, 4)
this.idCardCopyFilePath.push(nVal.cardPositive)
this.idCardCopyFilePath.push(nVal.cardSide)
}
}
},
created() {
this.shopDetails = {}
this.businessDetails = {}
this.idCardCopyFilePath = []
this.shopId = this.businessData.shopId
this.shopDetails = this.businessData
this.shopDetails.idCard = hidden(this.shopDetails.idCard, 4, 4)
this.businessId = this.businessData.businessId
this.businessDetails = this.businessData
this.businessDetails.idCard = hidden(this.businessDetails.idCard, 4, 4)
this.idCardCopyFilePath.push(this.businessData.cardPositive)
this.idCardCopyFilePath.push(this.businessData.cardSide)
},
@ -351,7 +351,7 @@ export default {
},
clearAddForm() {
this.addForm = {
shopId: '', // id
businessId: '', // id
checkHandle: '', // 1- 0-
effectiveDate: '', // null- -
effectiveYear: '', //
@ -377,7 +377,7 @@ export default {
} else {
this.addForm.effectiveDate = 'null'
}
this.addForm.shopId = this.shopId
this.addForm.businessId = this.businessId
const loading = this.$loading({
lock: true,
text: '处理中请稍后...',
@ -387,7 +387,7 @@ export default {
const res = await settlementHandle(this.addForm)
this.addFormDialog = false
if (res.code === '') {
this.shopDetails = {}
this.businessDetails = {}
this.idCardCopyFilePath = []
this.$message({
message: '处理成功',

20
src/views/business/settlement/index.vue

@ -12,19 +12,19 @@
<el-form :inline="true" :model="formInline">
<el-form-item label="商家名称">
<el-input
v-model="formInline.shopName"
v-model="formInline.businessName"
maxlength="20"
placeholder="请输入商家名称"
/>
</el-form-item>
<el-form-item label="注册手机号">
<el-input
v-model="formInline.shopPhone"
v-model="formInline.businessPhone"
maxlength="11"
placeholder="请输入注册手机号"
/>
</el-form-item>
<el-form-item label="店铺类型">
<el-form-item label="商家类型">
<el-select
v-model="formInline.authenType"
clearable
@ -62,7 +62,7 @@
style="width: 100%"
>
<el-table-column label="商家名称" width="220">
<template slot-scope="scope">{{ scope.row.shopName }}</template>
<template slot-scope="scope">{{ scope.row.businessName }}</template>
</el-table-column>
<el-table-column label="店铺类型">
<template slot-scope="scope">
@ -72,7 +72,7 @@
<span v-if="scope.row.authenType == 4">其他组织</span>
</template>
</el-table-column>
<el-table-column prop="shopPhone" label="注册手机号" />
<!-- <el-table-column prop="businessPhone" label="注册手机号" /> -->
<el-table-column prop="createTime" label="申请时间" />
<el-table-column label="操作" show-overflow-tooltip>
<template slot-scope="scope">
@ -146,8 +146,8 @@ export default {
return {
activeName: '0',
formInline: {
shopName: '', //
shopPhone: '', //
businessName: '', //
businessPhone: '', //
authenType: '', // 1- 2- 3- 4-
dates: [], //
checkState: '0', // 0- 1- 2-
@ -190,12 +190,12 @@ export default {
//
handleDel (row) {
this.addVisible = true
this.getFormData(row.shopId)
this.getFormData(row.businessId)
},
getFormData (shopId) {
getFormData (businessId) {
this.loading = true
//
settlementGetById({ shopId })
settlementGetById({ businessId })
.then(res => {
this.loading = false
this.form = res.data

765
src/views/business/shopList/index.vue

@ -0,0 +1,765 @@
<!-- -->
<template>
<div>
<div class="pending">
<!-- 搜索 -->
<div class="formSearch">
<el-form
:inline="true"
:model="formInline"
>
<el-form-item label="店铺名称">
<el-input
v-model="formInline.shopName"
maxlength="20"
placeholder="请输入店铺名称"
/>
</el-form-item>
<el-form-item label="店铺编码">
<el-input
v-model="formInline.shopCode"
maxlength="20"
placeholder="请输入店铺编码"
/>
</el-form-item>
<el-form-item label="负责人">
<el-input
v-model="formInline.chargePersonName"
maxlength="20"
placeholder="请输入负责人"
/>
</el-form-item>
<el-form-item label="所属商家">
<el-input
v-model="formInline.businessName"
maxlength="20"
placeholder="请输入所属商家"
/>
</el-form-item>
<!-- <el-form-item label="合同状态">
<el-select
v-model="formInline.contractState"
placeholder="请选择"
>
<el-option
label="有效"
value="1"
/>
<el-option
label="无效"
value="0"
/>
</el-select>
</el-form-item> -->
<el-form-item>
<el-button
type="primary"
plain
@click="onSubmit"
>查询
</el-button>
<el-button
type="success"
plain
@click="addbuss"
>新建店铺
</el-button>
</el-form-item>
</el-form>
</div>
<!-- 表格 -->
<div class="tableBox">
<el-table
ref="multipleTable"
:data="tableData"
border
:header-cell-style="{ background: '#EEF3FF', color: '#333333' }"
tooltip-effect="dark"
style="width: 100%"
>
<el-table-column
label="店铺名称"
width="220"
>
<template slot-scope="scope">{{ scope.row.shopName }}</template>
</el-table-column>
<el-table-column
prop="shopCode"
width="150"
label="店铺编码"
/>
<el-table-column
label="所属商家"
width="220"
>
<template slot-scope="scope">{{ scope.row.businessName }}</template>
</el-table-column>
<el-table-column
prop="chargePersonName"
width="80"
label="负责人"
/>
<el-table-column
prop="chargePersonPhone"
label="联系电话"
/>
<!-- <el-table-column label="合同状态">
<template slot-scope="scope">
<span v-if="scope.row.contractState === 0">无效</span>
<span v-if="scope.row.contractState === 1">有效</span>
</template>
</el-table-column> -->
<el-table-column
prop="createTime"
label="创建时间"
/>
<el-table-column
label="操作"
show-overflow-tooltip
>
<template slot-scope="scope">
<div class="btnList">
<el-button
type="text"
@click="seeMore(scope.row)"
>查看
</el-button>
<el-button
type="text"
@click="edit(scope.row)"
>编辑
</el-button>
<!-- <el-button
v-if="scope.row.state == 1"
type="text"
@click="del(scope.row)"
>禁用
</el-button>
<el-button
v-else
type="text"
@click="del(scope.row)"
>启用
</el-button> -->
<el-button
type="text"
@click="delshop(scope.row)"
>删除
</el-button>
<!-- <el-button
type="text"
@click="setShareSetting(scope.row)"
>设置分配比例</el-button> -->
</div>
</template>
</el-table-column>
</el-table>
<div class="fenye">
<el-pagination
:current-page="currentPage"
:page-sizes="[10, 20, 50, 100]"
:page-size="10"
layout="total, sizes, prev, pager, next, jumper"
:total="total"
@size-change="handleSizeChange"
@current-change="handleCurrentChange"
/>
</div>
</div>
<!-- ******************************************************弹框开始****************************************************** -->
<!-- 新建店铺弹框 -->
<el-dialog
:title="
userState === 0
? '新增店铺'
: userState === 1
? '修改店铺'
: '查看店铺'
"
:visible.sync="dialogVisible"
width="30%"
center
:close-on-click-modal="false"
>
<el-form
ref="ruleFormInfo"
:model="ruleForm"
:rules="rulesInfo"
label-width="120px"
>
<el-form-item
label="店铺名称"
prop="shopName"
>
<el-input
v-model="ruleForm.shopName"
maxlength="20"
:disabled="disabled"
/>
</el-form-item>
<el-form-item
label="店铺编码"
prop="shopCode"
v-if="userState !== 0"
>
<el-input
v-model="ruleForm.shopCode"
maxlength="20"
:disabled="true"
/>
</el-form-item>
<el-form-item
label="所属商家"
prop="businessId"
>
<el-select
v-model="ruleForm.businessId"
filterable
remote
reserve-keyword
:disabled="disabled"
placeholder="请输入商家名称"
:remote-method="selectBusinessList"
:loading="loading">
<el-option
v-for="businessItem in businessList"
:key="businessItem.businessId"
:label="businessItem.businessName"
:value="businessItem.businessId">
</el-option>
</el-select>
<!-- <el-input
v-model="ruleForm.businessName"
maxlength="20"
:disabled="disabled"
/> -->
</el-form-item>
<el-form-item
label="店铺负责人"
prop="chargePersonName"
>
<el-input
v-model="ruleForm.chargePersonName"
maxlength="20"
:disabled="disabled"
/>
</el-form-item>
<el-form-item
label="负责人电话"
prop="chargePersonPhone"
>
<el-input
v-if="cpPhoneShow"
:value="hidden(ruleForm.chargePersonPhone,3,4)"
maxlength="11"
:disabled="disabled"
@focus="focuscpPhoneInput"
/>
<el-input
v-else
ref="cpPhoneCls"
v-model="ruleForm.chargePersonPhone"
maxlength="11"
clearable
:disabled="disabled"
@change="changecpPhoneInput"
/>
</el-form-item>
<el-form-item
label="店铺地址"
prop="shopAdress"
>
<el-input
ref="addressCls"
v-model="ruleForm.shopAdress"
maxlength="60"
:disabled="disabled"
/>
<!-- <div v-else @click="inputAddress">
<el-input :value="hidden(ruleForm.shopAdress, 1, 1)" :disabled="disabled" />
</div> -->
</el-form-item>
<!-- <el-form-item
label="生效日期"
prop="effectiveDate"
>
<el-date-picker
v-model="ruleForm.effectiveDate"
:disabled="disabled"
value-format="yyyy-MM-dd"
type="date"
placeholder="选择日期"
/>
</el-form-item>
<el-form-item
label="生效年限"
prop="effectiveYear"
>
<el-input
v-model="ruleForm.effectiveYear"
type="text"
:disabled="disabled"
placeholder="请输入内容"
maxlength="4"
class="elipt"
style="width: 50%"
show-word-limit
/>
<span class="elspan"></span>
</el-form-item>
<el-form-item
label="合同状态"
prop="contractState"
>
<el-radio-group v-model="ruleForm.contractState">
<el-radio
:disabled="disabled"
:label="1"
>有效
</el-radio>
<el-radio
:disabled="disabled"
:label="0"
>无效
</el-radio>
</el-radio-group>
</el-form-item>
<el-form-item
label="直播间审核"
prop="auditLive"
>
<el-radio-group v-model="ruleForm.auditLive">
<el-radio
:disabled="disabled"
:label="1"
>开启
</el-radio>
<el-radio
:disabled="disabled"
:label="0"
>关闭
</el-radio>
</el-radio-group>
</el-form-item>
<el-form-item
label="直播间商品审核"
prop="auditLiveProduct"
>
<el-radio-group v-model="ruleForm.auditLiveProduct">
<el-radio
:disabled="disabled"
:label="1"
>开启
</el-radio>
<el-radio
:disabled="disabled"
:label="0"
>关闭
</el-radio>
</el-radio-group>
</el-form-item> -->
</el-form>
<span
slot="footer"
class="dialog-footer"
>
<el-button @click="closeFn"> </el-button>
<el-button
type="primary"
@click="addCheck()"
> </el-button>
</span>
</el-dialog>
</div>
</div>
</template>
<script>
// jsjsjson
// import from '';
import {
shopListGetAll,
shopListSave,
shopListGetById,
shopListUpdate,
shopListStart,
delshopById
} from '@/api/shop'
import {
businessListGetAll
} from '@/api/business'
export default {
data () {
//
return {
//
dialogVisible: false,
loading: false,
formInline: {
shopName: '', //
shopCode: '', //
chargePersonName: '', //
businessName: '',
page: '1', //
pageSize: '10' //
},
businessList:{},
disabled: false,
ruleForm: {
shopName: '', //
chargePersonName: '', //
chargePersonPhone: '', //
shopAdress: '', //
businessId : null,
businessName : ""
},
showPhone: false,
showAddress: false,
userPhone: '',
showUserPhone: false,
newAddress: '',
personPhone: '',
rulesInfo: {
shopName: [
{ required: true, message: '请输入店铺名称', trigger: 'blur' }
],
chargePersonName: [
{ required: true, message: '请输入店铺负责人', trigger: 'blur' }
],
chargePersonPhone: [
{ required: true, message: '请输入负责人电话', trigger: 'blur' },
{
pattern: /^1[3456789]\d{9}$/,
message: '目前只支持中国大陆的手机号码'
}
],
shopAdress: [
{ required: true, message: '请输入地址', trigger: 'blur' }
],
businessId: [
{
required: true,
message: '请输入商家名称后选择商家',
trigger: 'change'
}
]
},
total: 1,
tableData: [],
currentPage: 1,
userState: 1,
privacyTime: 0,
cpPhoneShow: true, //
shopPhoneShow: true //
}
},
// data
computed: {},
// data
watch: {},
// - 访this
created () {
},
// - 访DOM
mounted () {
this.getAll(this.formInline)
this.privacyTime = localStorage.getItem('privacyTime')
console.log(this.privacyTime)
},
//
methods: {
async selectBusinessList(keyWord) {
let params = {
businessName: keyWord, //
page: '1', //
pageSize: '100' //
}
const res = await businessListGetAll(params)
this.businessList = res.data.list
},
focusShopPhoneInput () {
this.shopPhoneShow = false
this.ruleForm.shopPhone = ''
//
this.$nextTick(() => {
this.$refs.shopPhoneCls.focus()
})
},
focuscpPhoneInput () {
this.cpPhoneShow = false
this.ruleForm.chargePersonPhone = ''
//
this.$nextTick(() => {
this.$refs.cpPhoneCls.focus()
})
},
changecpPhoneInput () {
},
handleSizeChange (val) {
this.formInline.pageSize = val
this.getAll(this.formInline)
},
handleCurrentChange (val) {
this.formInline.page = val
this.getAll(this.formInline)
},
handleClick (tab, event) {
console.log(tab, event)
},
onSubmit () {
this.getAll(this.formInline)
},
//
addbuss () {
this.userState = 0
this.disabled = false
this.newAddress = ''
this.personPhone = ''
this.ruleForm = {
shopName: '', //
shopCode:'',
chargePersonName: '', //
chargePersonPhone: '', //
shopAdress: '', //
businessId:null,
businessName:''
}
this.dialogVisible = true
console.log(this.userState)
},
closeFn () {
this.$nextTick(() => {
this.$refs['ruleFormInfo'].clearValidate()
this.dialogVisible = false
})
},
//
addCheck () {
this.$refs['ruleFormInfo'].validate(valid => {
if (valid) {
console.log(this.userState)
console.log(this.ruleForm)
// if (this.personPhone !== '') {
// this.ruleForm.chargePersonPhone = this.personPhone
// }
if (this.newAddress !== '') {
this.ruleForm.shopAdress = this.newAddress
}
// if (this.userPhone !== '') {
// this.ruleForm.shopPhone = this.userPhone
// }
if (this.ruleForm.shopName === '') {
this.$message.error('请输入店铺名称')
return
}
if (this.ruleForm.businessId === null) {
this.$message.error('请选择商家')
return
}
// if (this.ruleForm.effectiveDate === '') {
// this.$message.error('')
// return
// }
// if (this.ruleForm.effectiveYear === '') {
// this.$message.error('')
// return
// }
if (!this.userState) {
shopListSave(this.ruleForm).then(res => {
console.log(res)
if (res.code === '') {
this.$message({
message: '新增成功',
type: 'success'
})
}
this.getAll(this.formInline)
this.dialogVisible = false
this.$refs.ruleForm.clearValidate()
})
} else {
shopListUpdate(this.ruleForm).then(res => {
console.log(res)
if (res.code === '') {
this.$message({
message: '修改成功',
type: 'success'
})
this.$refs.ruleForm.clearValidate()
}
this.getAll(this.formInline)
this.dialogVisible = false
})
}
} else {
console.log('error submit!!')
this.$message.error('请输入完整信息')
return false
}
})
},
//
async seeMore (row) {
this.showPhone = false
this.cpPhoneShow = true
this.shopPhoneShow = true
const res = await shopListGetById({ shopId: row.shopId })
if (res.code === '') {
this.userState = 3
this.disabled = true
this.ruleForm = res.data
this.selectBusinessList(this.ruleForm.businessName)
this.dialogVisible = true
}
},
//
async edit (row) {
this.showPhone = false
this.personPhone = ''
this.userState = 1
this.disabled = false
this.cpPhoneShow = true
const res = await shopListGetById({ shopId: row.shopId })
this.ruleForm = res.data
this.selectBusinessList(this.ruleForm.businessName)
this.dialogVisible = true
console.log(this.ruleForm)
},
//
async del (row) {
console.log(row)
if (row.state === 1) {
const res = await shopListStart({
shopName: row.shopName,
state: 0,
shopId: row.shopId
})
if (res.code === '') {
this.$message({
message: '停用成功',
type: 'success'
})
this.getAll(this.formInline)
}
} else {
const res = await shopListStart({
shopName: row.shopName,
state: 1,
shopId: row.shopId
})
if (res.code === '') {
this.$message({
message: '启用成功',
type: 'success'
})
this.getAll(this.formInline)
}
}
},
delshop (row) {
// todo
this.$confirm('此操作将永久删除该店铺, 是否继续?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(async () => {
const res = await delshopById({
shopId: row.shopId
})
if (res.code === '') {
this.$message({
message: '操作成功',
type: 'success'
})
this.getAll(this.formInline)
}
}).catch(() => {
})
},
// shopListGetAll
//
async getAll (formInline) {
const res = await shopListGetAll(formInline)
this.total = res.data.total
this.tableData = res.data.list
},
//
inputPhone () {
this.showPhone = true
this.personPhone = ''
this.$nextTick(() => {
this.$refs.phoneCls.focus()
})
},
//
inputAddress () {
this.showAddress = true
this.newAddress = ''
this.$nextTick(() => {
this.$refs.addressCls.focus()
})
},
//
inputUserPhone () {
this.showUserPhone = true
this.userPhone = ''
this.$nextTick(() => {
this.$refs.userPhoneCls.focus()
})
},
//
hidden (str, frontLen, endLen) {
let endLenData = 0
if (str.length !== 2) {
endLenData = endLen
}
const len = str.length - frontLen - endLenData
let xing = ''
for (let i = 0; i < len; i++) {
xing += '*'
}
return (
str.substring(0, frontLen) + xing + str.substring(str.length - endLenData)
)
}
}
}
</script>
<style
lang="scss"
scoped
>
@import url("../../../styles/elDialog.scss");
.pending {
padding: 30px;
background: #FFFFFF;
border-radius: 10px;
}
.btnList{
display: flex;
flex-direction: row;
flex-wrap: wrap;
align-content: center;
justify-content: flex-start;
align-items: center;
}
.fenye {
margin-top: 20px;
}
.elipt {
width: 50%;
}
.elspan {
margin-left: 10px;
}
</style>

1
src/views/channel/list/index.vue

@ -108,7 +108,6 @@
</el-button>
<el-button
size="mini"
type="danger"
@click="handleDelete(scope.row)"
>删除
</el-button>

2
src/views/common.vue

@ -44,7 +44,7 @@
/>
</el-form-item>
<el-form-item>
<el-button type="primary" plain @click="onSubmit">查询</el-button>
<el-button type="primary" plain @click="onSubmit">{{ $t('common.query') }}</el-button>
<el-button type="success" plain @click="onSubmit">新建商家</el-button>
</el-form-item>
</el-form>

2
src/views/finance/application/index.vue

@ -93,7 +93,7 @@
</div>
<span slot="footer" class="dialog-footer">
<el-button v-if="dioObj.type === 2" type="primary" @click="agreeEn(1)">确认打款</el-button>
<el-button v-if="dioObj.type === 2" type="danger" @click="agreeEn(2)">拒绝打款</el-button>
<el-button v-if="dioObj.type === 2" @click="agreeEn(2)">拒绝打款</el-button>
<el-button v-if="dioObj.type === 1" @click="dioObj.show = false"> </el-button>
</span>
</el-dialog>

306
src/views/order/after/details/index.vue

@ -1,21 +1,23 @@
<template>
<div class="detail_page">
<div class="content">
<div class="head_box">
售后详情
<div v-if="detailRow.type != 2" class="btn_list">
<el-button @click="refuse">拒绝售后</el-button>
<el-button type="primary" @click="handle">同意售后</el-button>
</div>
<div v-else class="btn_list">
<el-button @click="back">返回</el-button>
<div class="baseinfo_row">
<div class="baseinfo_col">
<div class="item_title">订单信息</div>
<ul>
<li v-for="(item,index) in orderInfo" :key="index" v-if="index%2 === 0">
<p>{{ item.name }}:</p>
<p :class="[{active: item.type === 1 || item.type === 2 || item.type === 4}]">
<span @click="getInfo(item)">{{ item.value }}</span>
<span v-if="item.type ===3 && item.value" class="active" @click="getInfo(item)">查看物流</span>
<span v-if="item.type === 3 && !item.value">暂无物流信息</span>
</p>
</li>
</ul>
</div>
</div>
<div class="detail">
<div class="order_info">
<p class="detail_title">订单信息</p>
<ul class="order_list">
<li v-for="(item,index) in orderInfo" :key="index">
<div class="baseinfo_col">
<div class="item_title" style="visibility:hidden">订单信息</div>
<ul>
<li v-for="(item,index) in orderInfo" :key="index" v-if="index%2 === 1">
<p>{{ item.name }}:</p>
<p :class="[{active: item.type === 1 || item.type === 2 || item.type === 4}]">
<span @click="getInfo(item)">{{ item.value }}</span>
@ -23,69 +25,102 @@
<span v-if="item.type === 3 && !item.value">暂无物流信息</span>
</p>
</li>
</ul>
</div>
</div>
<div class="baseinfo_row">
<div class="baseinfo_col">
<div class="item_title">商品信息</div>
<el-table :data='order.products' style="width: 100%" class="product_table">
<el-table-column label="商品" width="400">
<template slot-scope="scope">
<div class="product_info">
<img :src="scope.row.image" class="product_img">
<div class="product_detail">
<div class="product_name">{{ scope.row.productName }}</div>
<div class="product_desc">
<p class="skuDetails">
<span v-for="(detailsItem, detailsindex) of scope.row.skuDetails" :key="detailsindex"
class="detail_span">
{{ detailsItem.skuName }}: {{ detailsItem.skuValue }}
</span>
</p>
<p>SKU: {{ scope.row.skuId }}</p>
</div>
</div>
</div>
</template>
</el-table-column>
<el-table-column prop="productPrice" label="价格">
</el-table-column>
<el-table-column prop="number" label="数量">
</el-table-column>
<el-table-column prop="total" label="小计">
</el-table-column>
</el-table>
<div class="product_total">
<div class="product_row"><span>商品总价:</span> <span>{{ order.orderPrice }}</span></div>
<div class="product_row"><span>运费金额:</span> <span>{{ order.logisticsPrice }}</span></div>
<div class="product_price"><span>退款总金额:</span> <span>{{ order.price }}</span></div>
<div class="after_sale_shop">
<p class="detail_title">售后商品</p>
<div v-for="(item,index) in shopList" :key="index" class="goods_list">
<div class="good_details">
<ul>
<li>
<img :src="item.image">
</li>
<li>
<p>{{ item.productName }}</p>
<p>{{ item.skuValue }}</p>
<p>SKU: {{ item.sku }}</p>
</li>
<li>
<p>¥{{ item.productPrice*item.number }}</p>
<p>¥{{ `${item.productPrice}*${item.number}` }}</p>
</li>
<li>¥{{ item.total }}</li>
</ul>
</div>
</div>
<div class="total">
<ul>
<li />
<li />
<li>退款总金额</li>
<li>¥{{ total }}</li>
</ul>
</div>
</div>
</div>
<div class="after_sales_record">
<p class="detail_title">协商历史</p>
<div v-for="(item,index) in recordList" :key="index" class="record_list">
<div class="record_list_title">
<p>{{ item.title }}</p>
<p>{{ item.name }}</p>
<p>{{ item.time }}</p>
<div class="baseinfo_row">
<div class="baseinfo_col">
<div class="item_title">协商历史</div>
<div class="after_sales_record">
<div
v-for="(item, index) in order.afterHistory"
:key="index"
class="record_list"
>
<div class="record_list_title">
<p>{{ item.title }}</p>
<div>
<p>买家名称{{ item.name }}</p>
<p>申请时间{{ item.time }}</p>
</div>
<p>留言{{ item.reason }}</p>
</div>
</div>
<div class="record_list_content">
<!-- <p>-->
<!-- &lt;!&ndash; <span>{{ item.type }}:</span> &ndash;&gt;-->
<!-- <span>{{ item.actionNote }}</span>-->
<!-- </p>-->
<div v-if="order.images && order.images.length != 0" class="proofBox">
<h3>买家举证图片:</h3>
<div class="imgBox">
<el-image v-for="(item, index) of order.images" :key="index" :src="item" :preview-src-list="order.images" alt />
</div>
</div>
</div>
</div>
</div>
</div>
<div class="baseinfo_row">
<div v-if="detailRow.type != 2" class="btnList">
<div class="lists">
<el-button class="btns" @click="refuse">拒绝售后</el-button>
<el-button type="primary" class="btns" @click="handle">同意售后</el-button>
</div>
<div class="record_list_content">
<p>
<!-- <span>{{ item.type }}:</span> -->
<span> 留言{{ item.reason }}</span>
</p>
<p v-if="item.images.length !=0">
<span>举证图片:</span>
<el-image
v-for="(imgItem, imgIndex) in item.images"
:key="imgIndex"
style="width: 100px; height: 100px"
:src="imgItem"
:preview-src-list="item.images"
/>
<!-- <img v-for="(imgItem, imgIndex) in item.images" :src="imgItem" :key="imgIndex" alt>-->
</p>
</div>
<div v-else class="btn_list">
<div class="lists">
<el-button class="btns" @click="back">返回</el-button>
</div>
</div>
</div>
</div>
<el-dialog
:title="dialog.title"
:visible.sync="dialog.visible"
@ -329,9 +364,142 @@ export default {
@import url("../../../../styles/elDialog.scss");
</style>
<style lang='less' scoped>
.item_title {
font-size: 16px;
font-weight: 500;
padding-left: 10px;
line-height: 16px;
margin-bottom: 15px;
margin-top: 10px;
position: relative;
color: #121F31;
&::before {
content: "";
height: 16px;
width: 4px;
background-color: #183ECD;
position: absolute;
left: 0px;
display: block;
font-weight: 500;
}
}
.detail_page {
background-color: #fff;
height: calc(100% - 10px);
.baseinfo_row {
display: flex;
flex-direction: row;
flex-wrap: nowrap;
align-content: center;
justify-content: center;
align-items: flex-start;
.baseinfo_col {
flex: 1;
ul {
li {
p {
margin-top: 8px;
margin-bottom: 8px;
span {
font-size: 14px;
font-family: PingFang SC;
font-weight: 400;
color: #404F64;
}
}
}
}
}
}
.product_table {
.el-table__header {
background: #F2F5FA;
border: 1px solid #E3EAF4;
opacity: 0.72;
}
.cell {
font-size: 14px;
font-family: PingFang SC;
font-weight: 400;
color: #404F64;
}
.product_info {
display: flex;
flex-direction: row;
flex-wrap: nowrap;
align-content: center;
justify-content: center;
align-items: center;
padding: 15px;
.product_img {
width: 74px;
height: 74px;
background: #DEE4EC;
margin-right: 15px;
}
.product_detail {
display: flex;
flex-wrap: nowrap;
flex-direction: column;
align-content: flex-start;
justify-content: center;
align-items: flex-start;
.product_name {
font-size: 14px;
font-family: PingFang SC;
font-weight: 400;
color: #404F64;
}
.product_desc {
font-size: 14px;
font-family: PingFang SC;
font-weight: 400;
color: #828C9A;
}
}
}
}
.product_total {
display: flex;
flex-direction: column;
flex-wrap: nowrap;
align-content: flex-end;
align-items: flex-end;
justify-content: center;
.product_row {
font-size: 14px;
font-family: PingFang SC;
font-weight: 400;
color: #404F64;
margin-top: 3px;
margin-bottom: 2px;
}
.product_price {
font-family: PingFang SC;
font-weight: bold;
color: #404F64;
line-height: 24px;
margin-top: 3px;
margin-bottom: 10px;
}
}
.content {
.head_box {
overflow: hidden;

1
src/views/order/after/index.vue

@ -81,7 +81,6 @@
:visible.sync="detailVisible"
width="75%"
center
top="10vh"
:close-on-click-modal="false"
:modal-append-to-body="false"
>

2
src/views/order/pending/index.vue

@ -85,7 +85,7 @@
<span v-if="scope.row.state == 1" :style="{color: '#E6A23C'}">待付款</span>
<span v-if="scope.row.state == 2" :style="{color: '#F56C6C'}">待发货</span>
<span v-if="scope.row.state == 3" :style="{color: '#409EFF'}">已发货</span>
<span v-if="scope.row.state == 4" :style="{color: '#67C23A'}">已完成</span>
<span v-if="scope.row.state == 4" :style="{color: '#183ECD'}">已完成</span>
<span v-if="scope.row.state == 5" :style="{color: '#909399'}">已关闭</span>
</template>
</el-table-column>

367
src/views/order/pending/pendDetails.vue

@ -1,24 +1,47 @@
<template>
<div class="order_details">
<div class="cotent">
<div class="left_part">
<div class="order_info">
<h2>订单信息</h2>
<div class="baseinfo_row">
<div class="baseinfo_col">
<div class="item_title">订单信息</div>
<ul>
<li>
<p>
<span>商家名称:</span>
<span>{{ order.shopName }}</span>
</p>
<p>
<span>订单ID:</span>
<span>{{ order.orderId }}</span>
</p>
</li>
<li>
<p>
<span>支付单号:</span>
<span>{{ order.transactionId }}</span>
</p>
</li>
<li>
<p>
<span>支付时间:</span>
<span>{{ order.paymentTime }}</span>
</p>
</li>
<li>
<p>
<span>创建时间:</span>
<span>{{ order.createTime }}</span>
</p>
</li>
</ul>
</div>
<div class="baseinfo_col">
<div class="item_title" style="visibility:hidden">订单信息</div>
<ul>
<li>
<p>
<span>订单ID:</span>
<span>{{ order.orderId }}</span>
</p>
</li>
<li>
<p>
<span>订单状态:</span>
@ -28,105 +51,132 @@
<span v-if="order.state === 4">已完成</span>
<span v-if="order.state === 5">已取消</span>
</p>
</li>
<li>
<p>
<span>物流方案:</span>
<span>{{ order.logisticsName }}</span>
</p>
</li>
<li>
<p>
<span>售后状态:</span>
<span>{{ order.afterStateName }}</span>
</p>
</li>
</ul>
</div>
<div class="baseinfo_col">
<div class="item_title">下单信息</div>
<ul>
<li>
<p>
<span>支付方式:</span>
<span v-if="order.paymentMode === 1">微信</span>
<span v-if="order.paymentMode === 2">支付宝</span>
<span>下单账户:</span>
<span>{{ order.customerName }}</span>
</p>
</li>
<li>
<p>
<span>物流方案:</span>
<span>{{ order.logisticsName }}</span>
<span>订单总数:</span>
<span>{{ order.total }}</span>
</p>
</li>
<li>
<p>
<span>创建时间:</span>
<span>{{ order.createTime }}</span>
<span>下单备注:</span>
<span>{{ order.remark }}</span>
</p>
</li>
</ul>
</div>
<div class="baseinfo_col">
<div class="item_title">收货信息</div>
<ul>
<li>
<p>
<span>支付时间:</span>
<span>{{ order.paymentTime }}</span>
<span>姓名:</span>
<span>{{ order.receiveName }}</span>
</p>
</li>
<li>
<p>备注:{{ order.remark }}</p>
<p>
<span>手机号:</span>
<span>{{ order.receivePhone }}</span>
</p>
</li>
<li>
<p>
<span>地址:</span>
<span>{{ order.receiveAdress }} {{ order.address }}</span>
</p>
</li>
</ul>
</div>
<div class="goods_info">
<h2>商品信息</h2>
<div
v-for="(item, index) in order.products"
:key="index"
class="goods_list"
>
<div class="good_price">
<ul>
<li>
<p>商品总价: ¥{{ order.orderPrice }}</p>
<p>支付金额: ¥{{ order.price }}</p>
</li>
<li>
<p>物流费用: {{ order.logisticsPrice }}</p>
</li>
</ul>
</div>
<div class="good_details">
<ul>
<li>
<img :src="item.image">
<div class="details">
<p>{{ item.productName }}</p>
<p class="skuDetails">
<span
v-for="(detailsItem, detailsindex) of item.skuDetails"
:key="detailsindex"
class="detail_span"
>
{{ detailsItem.skuName }}: {{ detailsItem.skuValue }}
</span>
</p>
<p>SKU: {{ item.skuId }}</p>
</div>
<div class="baseinfo_row">
<div class="baseinfo_col">
<div class="item_title">商品信息</div>
<el-table :data='order.products' style="width: 100%" class="product_table">
<el-table-column label="商品" width="400">
<template slot-scope="scope">
<div class="product_info">
<img :src="scope.row.image" class="product_img">
<div class="product_detail">
<div class="product_name">{{ scope.row.productName }}</div>
<div class="product_desc">
<p class="skuDetails">
<span v-for="(detailsItem, detailsindex) of scope.row.skuDetails" :key="detailsindex"
class="detail_span">
{{ detailsItem.skuName }}: {{ detailsItem.skuValue }}
</span>
</p>
<p>SKU: {{ scope.row.skuId }}</p>
</div>
</div>
</li>
<li class="cen">
¥{{ `${item.productPrice} * ${item.number}` }}
</li>
<li>
{{ order.orderPrice }}
</li>
</ul>
</div>
</div>
</template>
</el-table-column>
<el-table-column prop="productPrice" label="价格">
</el-table-column>
<el-table-column prop="number" label="数量">
</el-table-column>
<el-table-column prop="total" label="小计">
</el-table-column>
</el-table>
<div class="product_total">
<div class="product_row"><span>商品总价:</span> <span>{{ order.orderPrice }}</span></div>
<div class="product_row"><span>运费金额:</span> <span>{{ order.logisticsPrice }}</span></div>
<div class="product_price"><span>总金额:</span> <span>{{ order.price }}</span></div>
</div>
</div>
<!-- 未发货时物流信息显示去发货按钮 -->
<div class="logistics_info" v-show="order.logisticsName && order.logisticsNum">
<h2>物流信息</h2>
</div>
<div class="baseinfo_row">
<div class="baseinfo_col">
<div class="item_title">物流信息</div>
<el-button v-if="!order.logisticsNum && order.state == 2" type="primary" class="send_good"
@click="send">去发货</el-button>
<ul v-else>
<li v-if="order.express">
<p>
<span>物流公司:</span>
<span>{{ order.express }}</span>
</p>
</li>
<li v-if="order.deliverFormid">
<p>
<span>运单号:</span>
<span>{{ order.deliverFormid }}</span>
</p>
</li>
</ul>
</div>
<div class="baseinfo_col">
<div class="item_title" style="visibility:hidden">物流信息</div>
<!-- <p
v-if="!order.logisticsNum"
class="send_good"
@click="send"
>
去发货
</p>-->
<el-button
v-if="!order.logisticsNum && order.state == 2"
type="primary"
class="send_good"
@click="send"
>去发货</el-button>
<div v-else class="logistics_content">
<p class="logistics_title">
<span>物流公司: {{ order.logisticsName }}</span>
<span>运单号: {{ order.logisticsNum }}</span>
</p>
<!-- <p
v-for="(item, index) in tracesList"
:key="index"
class="logistics_item"
@ -134,24 +184,10 @@
<span>{{ item.acceptTime }}</span>
<span>{{ acceptStation }}</span>
</p> -->
</div>
</div>
</div>
<div class="right_part">
<div class="pay_order_info">
<h2>下单人信息</h2>
<p>下单账户: {{ order.customerName }}</p>
<p>订单总数: {{ order.total }}</p>
<p>下单备注: {{ order.remark }}</p>
</div>
<div class="take_goods_info">
<h2>收货信息</h2>
<p>姓名: {{ order.receiveName }}</p>
<p>手机号: {{ order.receivePhone }}</p>
<p>地址: {{ order.receiveAdress }}</p>
</div>
</div>
</div>
<!-- 发货 -->
<el-dialog
:visible.sync="isVisible"
@ -292,7 +328,142 @@ ul {
margin: 0;
padding: 0;
}
.item_title {
font-size: 16px;
font-weight: 500;
padding-left: 10px;
line-height: 16px;
margin-bottom: 15px;
margin-top: 10px;
position: relative;
color: #121F31;
&::before {
content: "";
height: 16px;
width: 4px;
background-color: #183ECD;
position: absolute;
left: 0px;
display: block;
font-weight: 500;
}
}
.order_details {
.baseinfo_row {
display: flex;
flex-direction: row;
flex-wrap: nowrap;
align-content: center;
justify-content: center;
align-items: flex-start;
.baseinfo_col {
flex: 1;
ul {
li {
p {
margin-top: 8px;
margin-bottom: 8px;
span {
font-size: 14px;
font-family: PingFang SC;
font-weight: 400;
color: #404F64;
}
}
}
}
}
}
.product_table {
.el-table__header {
background: #F2F5FA;
border: 1px solid #E3EAF4;
opacity: 0.72;
}
.cell {
font-size: 14px;
font-family: PingFang SC;
font-weight: 400;
color: #404F64;
}
.product_info {
display: flex;
flex-direction: row;
flex-wrap: nowrap;
align-content: center;
justify-content: center;
align-items: center;
padding: 15px;
.product_img {
width: 74px;
height: 74px;
background: #DEE4EC;
margin-right: 15px;
}
.product_detail {
display: flex;
flex-wrap: nowrap;
flex-direction: column;
align-content: flex-start;
justify-content: center;
align-items: flex-start;
.product_name {
font-size: 14px;
font-family: PingFang SC;
font-weight: 400;
color: #404F64;
}
.product_desc {
font-size: 14px;
font-family: PingFang SC;
font-weight: 400;
color: #828C9A;
}
}
}
}
.product_total {
display: flex;
flex-direction: column;
flex-wrap: nowrap;
align-content: flex-end;
align-items: flex-end;
justify-content: center;
.product_row {
font-size: 14px;
font-family: PingFang SC;
font-weight: 400;
color: #404F64;
margin-top: 3px;
margin-bottom: 2px;
}
.product_price {
font-family: PingFang SC;
font-weight: bold;
color: #404F64;
line-height: 24px;
margin-top: 3px;
margin-bottom: 10px;
}
}
h3 {
// margin-left: 20px;
margin: 20px 0 20px 20px;

2
src/views/renovation/brand/index.vue

@ -45,7 +45,7 @@
title="确定删除吗?"
@confirm="handleDelete(scope.row)"
>
<el-button slot="reference" type="danger" size="mini">删除</el-button>
<el-button slot="reference" size="mini">删除</el-button>
</el-popconfirm>
</template>
</el-table-column>

321
src/views/renovation/commdityClass/Edit.vue

@ -29,32 +29,45 @@
class="custom-tree-node"
>
<div class="content">
<template v-if="data.depth < 3">
<el-input
v-model="data.classifyName_ZH"
class="input"
:disabled="isCheck"
maxlength="6"
size="mini"
:placeholder="data.classifyLevel | placeholderTips"
/>
<el-input
v-model="data.categoryName"
v-model="data.classifyName_EN"
class="input"
:disabled="isCheck"
maxlength="6"
size="mini"
:placeholder="data.depth | placeholderTips"
:placeholder="data.classifyLevel | placeholderEnTips"
/>
<el-upload
class="upload-uploader"
:on-success="handleImageSuccessOne"
:on-success="handleImageSuccess"
:multiple="false"
:show-file-list="false"
:action="action"
:file-list="data.categoryImgArray"
:file-list="data.classifyImageArray"
>
<img
v-if="data.categoryImgArray.length && data.categoryImgArray[0].imgPath"
v-if="data.classifyImageArray.length && data.classifyImageArray[0].url"
width="80"
height="80"
:src="data.categoryImgArray.length && data.categoryImgArray[0].imgPath"
:src="data.classifyImageArray.length && data.classifyImageArray[0].url"
>
<div v-else><i class="el-icon-plus" /> <span style="display:none; font-size: 10px; color: #909399 !important;">建议尺寸:1252*356</span></div>
<div v-else>
<i class="el-icon-plus" /> <span style="display:none; font-size: 10px; color: #909399 !important;">建议尺寸:1252*356</span>
</div>
</el-upload>
<!-- <template v-if="data.classifyLevel < 3">
</template>
<template v-else>
<div
@ -62,7 +75,7 @@
:class="isCheck ? 'disabled' : ''"
>
<el-input
v-model="data.categoryName"
v-model="data.classifyName"
class="input"
:disabled="isCheck"
size="mini"
@ -74,19 +87,19 @@
:data="dataObj"
:multiple="false"
:show-file-list="false"
:file-list="data.categoryImgArray"
:file-list="data.classifyImageArray"
:on-success="handleImageSuccess"
class="upload-uploader"
:action="action"
>
<img
v-if="
data.categoryImgArray && data.categoryImgArray[0].url
data.classifyImageArray && data.classifyImageArray[0].url
"
width="80"
height="80"
:src="
data.categoryImgArray && data.categoryImgArray[0].url
data.classifyImageArray && data.classifyImageArray[0].url
"
>
<i
@ -95,17 +108,18 @@
/>
</el-upload>
</div>
</template>
</template> -->
</div>
<div
v-if="!isCheck"
class="setting-box"
>
<el-button
v-if="data.classifyLevel != 3"
type="text"
size="mini"
@click="() => append(data)"
>{{ data.depth | addTips }}
@click="() => append(data)">
{{ data.classifyLevel | addTips }}
</el-button>
<el-button
type="text"
@ -156,24 +170,35 @@ import {
} from '@/api/renovation'
let idx = 1000
let imgId = 1
export default {
filters: {
addTips (depth) {
depth = depth + ''
addTips (classifyLevel) {
classifyLevel = classifyLevel + ''
const tipsMp = {
1: '添加二级类别名称',
2: '添加三级类别名称'
2: '添加三级类别名称',
3: ''
}
return tipsMp[depth]
return tipsMp[classifyLevel]
},
placeholderTips (depth) {
depth = depth + ''
placeholderTips (classifyLevel) {
classifyLevel = classifyLevel + ''
const tipsMp = {
1: '输入一级类别名称(最大6个字符)',
2: '输入二级类别名称(最大6个字符)'
1: '输入一级类别中文名称(最大6个字符)',
2: '输入二级类别中文名称(最大6个字符)',
3: '输入三级类别中文名称(最大6个字符)'
}
return tipsMp[depth]
return tipsMp[classifyLevel]
},
placeholderEnTips (classifyLevel) {
classifyLevel = classifyLevel + ''
const tipsMp = {
1: '输入一级类别英文名称(最大60个字符)',
2: '输入二级类别英文名称(最大60个字符)',
3: '输入三级类别英文名称(最大60个字符)'
}
return tipsMp[classifyLevel]
}
},
props: {
@ -189,7 +214,7 @@ export default {
data () {
return {
params: {
categoryName: ''
classifyName: ''
},
file: this.image ? this.image : '',
imgList: [],
@ -258,60 +283,43 @@ export default {
const res = await commdityClassgetById({
oneClassifyId
})
console.log(res)
const resData = res.data
const treeFilter = item => {
const {
categoryName,
categoryImg,
categoryPath,
parentName,
categoryImgArray,
depth,
id,
link
} = item
const newMap = {
depth: depth,
categoryName,
categoryPath: categoryPath || '',
parentName,
categoryImgArray,
link,
id
}
console.log(depth)
if (depth === 3) {
newMap.categoryImgArray = [
{
url: categoryImg
}
]
}
if (item.childs && item.childs.length) {
newMap.childs = item.childs.map(treeFilter)
}
return newMap
}
resData.classifyName_ZH = JSON.parse(resData.classifyNameJson)[
"zh"
];
resData.classifyName_EN = JSON.parse(resData.classifyNameJson)[
"en"
];
this.initImageArray(resData)
if (resData) {
resData.childs =
resData && resData.childs && resData.childs.map(treeFilter)
this.treeData = [resData]
} else {
this.treeData = []
}
console.log(this.treeData)
},
initImageArray(treeData){
if(treeData){
treeData.classifyImageArray = [
{
url: treeData.classifyImage
}
]
treeData.idx = idx++
if(treeData.childs && treeData.childs.length){
for (const index in treeData.childs) {
this.initImageArray(treeData.childs[index])
}
}else{
treeData.childs = []
}
}
},
handleImageSuccess (response, file, fileList) {
console.log(response)
const url = response.data.url
fileList[0].url = url
},
handleImageSuccessOne (response, file, fileList) {
const url = response.data.url
console.log(fileList)
fileList[0].imgPath = url
},
close () {
this.$emit('close')
},
@ -320,60 +328,48 @@ export default {
},
addClassification () {
this.treeData.push({
placeholder: '输入一级类别名称',
addTips: '添加二级类别名称',
categoryName: '',
categoryPath: '',
depth: 1,
idx: idx++,
categoryImgArray: [
classifyId: 0,
classifyPid: 0,
classifyName_ZH: '',
classifyName_EN: '',
classifyImage: '',
classifyLevel: 1,
link: '',
classifyImageArray: [
{
id: imgId++,
imgPath: ''
url: ''
}
]
],
childs: []
})
},
append (data) {
const classifyLevel = data.classifyLevel + 1
console.log(data)
const { categoryName } = data
const depth = data.depth + 1
let newChild
if (!data.childs) {
this.$set(data, 'childs', [])
}
if (depth < 3) {
newChild = {
placeholder: '输入二级类别名称',
addTips: '添加三级类别名称',
depth,
parentName: categoryName,
categoryName: '',
categoryPath: '',
categoryImgArray: [
{
id: imgId++,
imgPath: ''
}
],
childs: [],
idx: idx++
}
} else {
newChild = {
parentName: categoryName,
categoryImgArray: [
{
id: imgId++,
url: ''
}
],
depth: 3,
categoryName: '',
idx: idx++
}
console.log(data)
newChild = {
idx: idx++,
classifyId: 0,
classifyPid: 0,
classifyName_ZH: '',
classifyName_EN: '',
classifyImage: '',
classifyLevel: classifyLevel,
link: '',
classifyImageArray: [
{
url: ''
}
],
childs: []
}
data.childs.push(newChild)
console.log(data)
},
remove (node, data) {
const parent = node.parent
@ -381,58 +377,55 @@ export default {
const index = children.findIndex(d => d.idx === data.idx)
if (index !== -1) {
children.splice(index, 1)
this.deleteArr.push(data.id || '')
if (data.classifyId && data.classifyId > 0) {
this.deleteArr.push(data.classifyId)
}
} else {
this.$message.warning('数据错误,请重试')
}
},
onSubmit () {
console.log(this.type)
if (this.type === 'add') {
this.addGroup()
} else {
this.updateGroup()
}
},
async addGroup () {
console.log(this.treeData)
const treeFilter = item => {
const {
categoryName,
categoryImgArray,
categoryPath,
parentName,
depth,
link
} = item
const newMap = {
depth: depth,
categoryName,
categoryPath: categoryPath || '',
parentName,
link
}
if (categoryImgArray) {
newMap.categoryImg = categoryImgArray[0].imgPath
resetImage(treeData){
console.log(treeData)
if(treeData){
treeData.classifyImage = ''
if(treeData.classifyImageArray && treeData.classifyImageArray.length){
treeData.classifyImage = treeData.classifyImageArray[0].url
}
if (depth === 3) {
newMap.categoryImg = categoryImgArray[0].url
}
if (!newMap.categoryImg) {
this.$message.error('分类\"' + categoryName + '\"请上传分类图片')
if (!treeData.classifyImage) {
this.$message.error('分类\"' + treeData.classifyName + '\"请上传分类图片')
throw new Error('未上传分类图片')
}
if (item.childs && item.childs.length) {
newMap.childs = item.childs.map(treeFilter)
if(treeData.childs && treeData.childs.length){
for (const index in treeData.childs) {
this.resetImage(treeData.childs[index])
}
}
return newMap
}
const params = this.treeData.map(treeFilter)
console.log(params)
},
async addGroup () {
const params = this.treeData
if (params.length === 0) {
this.$message.error('请添加分类')
return
}
for (const index in params) {
let itemParams = params[index]
itemParams.classifyName = itemParams.classifyName_ZH;
itemParams.classifyNameMap = {}
itemParams.classifyNameMap["zh"] = itemParams.classifyName_ZH;
itemParams.classifyNameMap["en"] = itemParams.classifyName_EN;
itemParams.classifyNameJson = JSON.stringify(itemParams.classifyNameMap);
}
this.resetImage(this.treeData[0])
const obj = {
classifies: params
}
@ -448,41 +441,21 @@ export default {
}
},
async updateGroup () {
const treeFilter = item => {
const {
categoryName,
categoryImgArray,
categoryPath,
parentName,
depth,
id,
link
} = item
const newMap = {
depth: depth,
categoryName,
categoryPath: categoryPath || '',
parentName,
link,
id
}
if (categoryImgArray) {
newMap.categoryImg = categoryImgArray[0].imgPath
}
if (depth === 3) {
newMap.categoryImg = categoryImgArray[0].url
}
if (!newMap.categoryImg) {
this.$message.error('分类\"' + categoryName + '\"请上传分类图片')
throw new Error('未上传分类图片')
}
if (item.childs && item.childs.length) {
newMap.childs = item.childs.map(treeFilter)
}
return newMap
const params = this.treeData
if (params.length === 0) {
this.$message.error('请选择分类')
return
}
console.log(this.treeData)
const params = this.treeData.map(treeFilter)
for (const index in params) {
let itemParams = params[index]
itemParams.classifyName = itemParams.classifyName_ZH;
itemParams.classifyNameMap = {}
itemParams.classifyNameMap["zh"] = itemParams.classifyName_ZH;
itemParams.classifyNameMap["en"] = itemParams.classifyName_EN;
itemParams.classifyNameJson = JSON.stringify(itemParams.classifyNameMap);
}
this.resetImage(this.treeData[0])
const obj = {
classifies: params,
deleteIds: this.deleteArr

25
src/views/renovation/commdityClass/index.vue

@ -11,12 +11,14 @@
:header-cell-style="{ background: '#EEF3FF', color: '#333333' }"
:tree-props="{ children: 'childs' }"
>
<el-table-column prop="classifyName" label="商品类别" />
<el-table-column prop="classifyName_ZH" label="商品类别(中文)" />
<el-table-column prop="classifyName_EN" label="商品类别(英文)" />
<el-table-column prop="status" label="操作">
<template slot-scope="scope">
<el-button type="text" @click.native.prevent="checkRow(scope.row)">查看</el-button>
<el-button type="text" @click.native.prevent="updateRow(scope.row)">编辑</el-button>
<el-button type="text" @click.native.prevent="deleteRow(scope.row)">删除</el-button>
<el-button type="text" @click.native.prevent="setShareSetting(scope.row)">设置分配比例</el-button>
</template>
</el-table-column>
</el-table>
@ -38,6 +40,8 @@
@close="editClose"
@success="getProductCategory"
/>
<SharesettingDialog
ref="shareSettingDialog"/>
</div>
</template>
<script>
@ -46,9 +50,10 @@ import {
commdityClassDelete
} from '@/api/renovation'
import EditDialog from './Edit'
import SharesettingDialog from '../../../components/Sharesetting';
export default {
components: {
EditDialog
EditDialog,SharesettingDialog
},
data() {
return {
@ -71,6 +76,9 @@ export default {
this.getAll(this.formParams)
},
methods: {
setShareSetting(row) {
this.$refs.shareSettingDialog.showSetting(1, row.classifyId)
},
handleSizeChange(val) {
this.formParams.pageSize = val
this.getAll(this.formParams)
@ -148,8 +156,17 @@ export default {
},
async getAll(formParams) {
const res = await commdityClassGetAll(formParams)
this.tableData = res.data.list
this.total = res.data.total
let tempData = res.data.list;
tempData.forEach((itemData) => {
itemData.classifyName_ZH = JSON.parse(itemData.classifyNameJson)[
"zh"
];
itemData.classifyName_EN = JSON.parse(itemData.classifyNameJson)[
"en"
];
});
this.tableData = tempData;
this.total = res.data.total;
}
}
}

2
src/views/renovation/commoditySystem/addCommodity.vue

@ -29,7 +29,7 @@
<div>商品款式</div>
</el-col>
<el-col :span="12">
<div>官方分类{{ productItem.classifyName }}</div>
<div>商品分类{{ productItem.classifyName }}</div>
<div>商家分组{{ productItem.shopGroupName }}</div>
<div>商家名称{{ productItem.shopName }}</div>
<div>

20
src/views/renovation/commoditySystem/index.vue

@ -141,6 +141,10 @@
type="text"
@click="Godetails(scope.row)"
>查看详情</el-button>
<el-button
type="text"
@click="setShareSetting(scope.row)"
>设置分配比例</el-button>
</div>
</template>
</el-table-column>
@ -208,6 +212,8 @@
</span>
</el-dialog>
<add-commodity ref="addCommodity" :examine-show="examineShow" @reset="reset" />
<SharesettingDialog
ref="shareSettingDialog"/>
</div>
</template>
@ -220,8 +226,9 @@ import {
productExport
} from '@/api/commodity';
import AddCommodity from './addCommodity';
import SharesettingDialog from '../../../components/Sharesetting';
export default {
components: { AddCommodity },
components: { AddCommodity,SharesettingDialog},
data () {
//
return {
@ -268,6 +275,9 @@ export default {
Godetails (row) {
this.$refs.addCommodity.show(row.productId)
},
setShareSetting(row) {
this.$refs.shareSettingDialog.showSetting(3, row.productId)
},
//
setFictitious (row) {
this.FictitiousVisible = true;
@ -417,6 +427,14 @@ export default {
color: #3a68f2;
cursor: pointer;
}
.btnList{
display: flex;
flex-direction: row;
flex-wrap: wrap;
align-content: center;
justify-content: flex-start;
align-items: center;
}
.vipDialog {
.priceTable {
table {

2
src/views/risk/IPBlacklist/index.vue

@ -72,7 +72,7 @@
>
点击生效
</el-button>
<el-button slot="reference" type="danger" icon="el-icon-delete" size="mini" @click="del(scope.row.id)">删除</el-button>
<el-button slot="reference" icon="el-icon-delete" size="mini" @click="del(scope.row.id)">删除</el-button>
</div>
</template>
</el-table-column>

2
src/views/risk/riskRules/index.vue

@ -65,7 +65,7 @@
>
编辑
</el-button>
<el-button slot="reference" type="danger" icon="el-icon-delete" size="mini" @click="del(scope.row.id)">删除</el-button>
<el-button slot="reference" icon="el-icon-delete" size="mini" @click="del(scope.row.id)">删除</el-button>
</div>
</template>
</el-table-column>

2
src/views/risk/userBlacklist/index.vue

@ -75,7 +75,7 @@
>
点击生效
</el-button>
<el-button slot="reference" type="danger" icon="el-icon-delete" size="mini" @click="del(scope.row.id)">删除</el-button>
<el-button slot="reference" icon="el-icon-delete" size="mini" @click="del(scope.row.id)">删除</el-button>
</div>
</template>
</el-table-column>

96
src/views/setup/businessMenus/index.vue

@ -29,7 +29,8 @@
@selection-change="handleSelectionChange"
>
<el-table-column type="selection" width="55" />
<el-table-column prop="permissionName" label="菜单名称" />
<el-table-column prop="permissionName_ZH" label="中文名称" />
<el-table-column prop="permissionName_EN" label="英文名称" />
<el-table-column label="图标">
<template slot-scope="scope">
<div>
@ -75,11 +76,22 @@
<el-form-item label="父节点ID">
<el-input v-model="addForm.permissionPid" maxlength="20" :disabled="true" placeholder="请输入角色名称" />
</el-form-item>
<el-form-item label="菜单名称" prop="permissionName">
<el-input v-model="addForm.permissionName" maxlength="20" placeholder="请输入菜单名称" />
<el-form-item label="中文名称" prop="permissionName_ZH">
<el-input
v-model="addForm.permissionName_ZH"
maxlength="20"
placeholder="请输入菜单名称"
/>
</el-form-item>
<el-form-item label="英文名称" prop="permissionName_EN">
<el-input
v-model="addForm.permissionName_EN"
maxlength="20"
placeholder="请输入菜单名称"
/>
</el-form-item>
<el-form-item label="菜单路径" prop="permission">
<el-input v-model="addForm.permission" maxlength="40" placeholder="请输入菜单路径" />
<el-input v-model="addForm.permission" maxlength="300" placeholder="请输入菜单路径" />
</el-form-item>
<el-form-item label="图标地址" prop="icon">
<el-input
@ -178,7 +190,8 @@ export default {
userState: 1,
addForm: {
permissionPid: '', // id
permissionName: '', //
permissionName_ZH: "", //
permissionName_EN: "", //
permissionUri: '', // URI
permission: '', //
icon: '', //
@ -194,9 +207,9 @@ export default {
addFormDialog: false,
syncMenuDialog: false,
userRules: {
permissionName: [
{ required: true, message: '请输入权限名称', trigger: 'blur' }
],
// permissionName: [
// { required: true, message: '', trigger: 'blur' }
// ],
permission: [
{ required: true, message: '请输入菜单路径', trigger: 'blur' }
],
@ -329,9 +342,12 @@ export default {
})
return
}
this.addForm = {
permissionPid: '', // id
permissionName: '', //
permissionName_ZH: "", //
permissionName_EN: "", //
permissionUri: '', // URI
permission: '', //
icon: '', //
@ -355,7 +371,8 @@ export default {
}
this.addForm = {
permissionPid: this.multipleSelection[0].permissionId, // id
permissionName: '', //
permissionName_ZH: "", //
permissionName_EN: "", //
permissionUri: '', // URI
permission: '', //
icon: '', //
@ -382,7 +399,8 @@ export default {
}
this.addForm = {
permissionPid: this.multipleSelection[0].permissionId, // id
permissionName: '', //
permissionName_ZH: "", //
permissionName_EN: "", //
permissionUri: '', // URI
permission: '', //
icon: 'el-icon-minus', //
@ -444,8 +462,38 @@ export default {
addForm_enter (ruleForm) {
this.$refs[ruleForm].validate(valid => {
if (valid) {
if (
(this.addForm.permissionName_ZH == "" ||
this.addForm.permissionName_ZH == undefined) &&
(this.addForm.permissionName_EN == "" ||
this.addForm.permissionName_EN == undefined)
) {
this.$message({
message: "请输入名称",
type: "error",
});
return;
}
console.log(this.addForm);
let addData = {};
addData.permissionId = this.addForm.permissionId;
addData.permissionPid = this.addForm.permissionPid;
addData.permissionName = this.addForm.permissionName_ZH;
addData.permissionUri = this.addForm.permissionUri;
addData.permission = this.addForm.permission;
addData.icon = this.addForm.icon;
addData.describe = this.addForm.describe;
addData.resourceType = this.addForm.resourceType;
addData.sort = this.addForm.sort;
addData.permissionNameMap = {}
addData.permissionNameMap["zh"] = this.addForm.permissionName_ZH;
addData.permissionNameMap["en"] = this.addForm.permissionName_EN;
addData.permissionNameJson = JSON.stringify(addData.permissionNameMap);
if (this.userState) {
businessTabsAdd(this.addForm).then(res => {
businessTabsAdd(addData).then(res => {
if (res.code === '') {
this.$message({
message: '新增成功',
@ -456,7 +504,7 @@ export default {
this.addFormDialog = false
})
} else {
businessTabsUpdate(this.addForm).then(res => {
businessTabsUpdate(addData).then(res => {
if (res.code === '') {
this.$message({
message: '修改成功',
@ -478,7 +526,14 @@ export default {
this.userState = 0
this.addFormDialog = true
businessTabsGetById({ permissionId: row.permissionId }).then(res => {
this.addForm = res.data
let itemData = res.data;
itemData.permissionName_ZH = JSON.parse(itemData.permissionNameJson)[
"zh"
];
itemData.permissionName_EN = JSON.parse(itemData.permissionNameJson)[
"en"
];
this.addForm = itemData
// this.addForm.roleIds = [1];
})
},
@ -504,8 +559,17 @@ export default {
//
async getAll (formInline) {
const res = await businessTabsGetAll(formInline)
this.tableData = res.data.list
this.total = res.data.total
let tempData = res.data.list;
tempData.forEach((itemData) => {
itemData.permissionName_ZH = JSON.parse(itemData.permissionNameJson)[
"zh"
];
itemData.permissionName_EN = JSON.parse(itemData.permissionNameJson)[
"en"
];
});
this.tableData = tempData;
this.total = res.data.total;
}
}
}

424
src/views/setup/tabs/index.vue

@ -5,7 +5,11 @@
<FixedNav class="formSearch" :height="200">
<div class="searchInput">
<span>菜单名</span>
<el-input v-model="formInline.permissionName" maxlength="20" placeholder="请输入菜单名" />
<el-input
v-model="formInline.permissionName"
maxlength="20"
placeholder="请输入菜单名"
/>
</div>
<el-button type="primary" plain @click="search">查询</el-button>
<el-button type="info" plain @click="clear">重置</el-button>
@ -13,20 +17,6 @@
<el-button type="success" plain @click="add(2)">新增子级菜单</el-button>
<el-button type="success" plain @click="add(3)">新增子级按钮</el-button>
</FixedNav>
<!-- <div class="formSearch">
<el-form :inline="true" :model="formInline">
<el-form-item label="菜单名">
<el-input v-model="formInline.permissionName" placeholder="请输入菜单名" />
</el-form-item>
<el-form-item>
<el-button type="primary" plain @click="search">查询</el-button>
<el-button type="info" plain @click="clear">重置</el-button>
<el-button type="success" plain @click="add(1)">新增父级目录</el-button>
<el-button type="success" plain @click="add(2)">新增子级菜单</el-button>
<el-button type="success" plain @click="add(3)">新增子级按钮</el-button>
</el-form-item>
</el-form>
</div> -->
<!-- 表格 -->
<div class="tableBox">
<el-table
@ -39,7 +29,8 @@
@selection-change="handleSelectionChange"
>
<el-table-column type="selection" width="55" />
<el-table-column prop="permissionName" label="菜单名称" />
<el-table-column prop="permissionName_ZH" label="中文名称" />
<el-table-column prop="permissionName_EN" label="英文名称" />
<el-table-column label="图标">
<template slot-scope="scope">
<div>
@ -81,15 +72,40 @@
>
<!-- 新增角色 -->
<div>
<el-form ref="ruleForm" :model="addForm" label-width="80px" :rules="userRules">
<el-form
ref="ruleForm"
:model="addForm"
label-width="80px"
:rules="userRules"
>
<el-form-item label="父节点ID">
<el-input v-model="addForm.permissionPid" maxlength="20" :disabled="true" placeholder="请输入角色名称" />
<el-input
v-model="addForm.permissionPid"
maxlength="20"
:disabled="true"
placeholder="请输入角色名称"
/>
</el-form-item>
<el-form-item label="菜单名称" prop="permissionName">
<el-input v-model="addForm.permissionName" maxlength="20" placeholder="请输入菜单名称" />
<el-form-item label="中文名称" prop="permissionName_ZH">
<el-input
v-model="addForm.permissionName_ZH"
maxlength="20"
placeholder="请输入菜单名称"
/>
</el-form-item>
<el-form-item label="英文名称" prop="permissionName_EN">
<el-input
v-model="addForm.permissionName_EN"
maxlength="20"
placeholder="请输入菜单名称"
/>
</el-form-item>
<el-form-item label="菜单路径" prop="permission">
<el-input v-model="addForm.permission" maxlength="100" placeholder="请输入菜单路径" />
<el-input
v-model="addForm.permission"
maxlength="100"
placeholder="请输入菜单路径"
/>
</el-form-item>
<el-form-item label="图标地址" prop="icon">
<el-input
@ -103,13 +119,25 @@
</el-input>
</el-form-item>
<el-form-item label="菜单描述">
<el-input v-model="addForm.describe" maxlength="60" placeholder="请输入菜单描述" />
<el-input
v-model="addForm.describe"
maxlength="60"
placeholder="请输入菜单描述"
/>
</el-form-item>
<el-form-item label="排序值" prop="sort">
<el-input v-model="addForm.sort" maxlength="9" placeholder="请输入排序值" oninput="value=value.replace(/[^\d]/g,'')" />
<el-input
v-model="addForm.sort"
maxlength="9"
placeholder="请输入排序值"
oninput="value=value.replace(/[^\d]/g,'')"
/>
</el-form-item>
<el-form-item label="权限类型" prop="resourceType">
<el-select v-model="addForm.resourceType" placeholder="请选择活动区域">
<el-select
v-model="addForm.resourceType"
placeholder="请选择活动区域"
>
<el-option label="菜单" value="menu" />
<el-option label="按钮" value="button" />
<el-option label="目录" value="catalog" />
@ -119,11 +147,17 @@
</div>
<span slot="footer" class="dialog-footer">
<el-button @click="addFormDialog = false"> </el-button>
<el-button type="primary" @click="addForm_enter('ruleForm')"> </el-button>
<el-button type="primary" @click="addForm_enter('ruleForm')"
> </el-button
>
</span>
</el-dialog>
<Icons :dialog-visible="iconVisible" @choose="chooseIcon" @close="iconVisible = false" />
<Icons
:dialog-visible="iconVisible"
@choose="chooseIcon"
@close="iconVisible = false"
/>
</div>
</template>
@ -136,56 +170,57 @@ import {
tabsGetById,
tabsUpdate,
tabsDelete,
getMaxSort
} from '@/api/setup'
import Icons from './Icons'
import FixedNav from '@/components/FixedNav/index.vue'
getMaxSort,
} from "@/api/setup";
import Icons from "./Icons";
import FixedNav from "@/components/FixedNav/index.vue";
export default {
// import使
components: {
Icons,
FixedNav
FixedNav,
},
data() {
//
return {
formInline: {
permissionName: '', //
page: '1', //
pageSize: '10' //
permissionName: "", //
page: "1", //
pageSize: "10", //
},
total: 1,
tableData: [],
currentPage: 1,
userState: 1,
addForm: {
permissionPid: '', // id
permissionName: '', //
permissionUri: '', // URI
permission: '', //
icon: '', //
describe: '', //
resourceType: 'menu', // menu- button- catalog-
sort: '' //
permissionPid: "", // id
permissionName_ZH: "", //
permissionName_EN: "", //
permissionUri: "", // URI
permission: "", //
icon: "", //
describe: "", //
resourceType: "menu", // menu- button- catalog-
sort: "", //
},
addFormDialog: false,
userRules: {
permissionName: [
{ required: true, message: '请输入权限名称', trigger: 'blur' }
],
// permissionName: [
// { required: true, message: '', trigger: 'blur' }
// ],
permission: [
{ required: true, message: '请输入菜单路径', trigger: 'blur' }
{ required: true, message: "请输入菜单路径", trigger: "blur" },
],
resourceType: [
{ required: true, message: '请选择活动区域', trigger: 'change' }
{ required: true, message: "请选择活动区域", trigger: "change" },
],
sort: [{ required: true, message: '请输入菜单路径', trigger: 'blur' }],
icon: [{ required: true, message: '请输入图标地址', trigger: 'blur' }]
sort: [{ required: true, message: "请输入菜单路径", trigger: "blur" }],
icon: [{ required: true, message: "请输入图标地址", trigger: "blur" }],
},
iconVisible: false,
multipleSelection: []
}
multipleSelection: [],
};
},
// data
computed: {},
@ -195,220 +230,267 @@ export default {
created() {},
// - 访DOM
mounted() {
this.getAll(this.formInline)
this.getAll(this.formInline);
},
//
methods: {
handleSelectionChange(val) {
this.multipleSelection = val
this.multipleSelection = val;
},
handleSizeChange(val) {
this.formInline.pageSize = val
this.getAll(this.formInline)
this.formInline.pageSize = val;
this.getAll(this.formInline);
},
handleCurrentChange(val) {
this.formInline.page = val
this.getAll(this.formInline)
this.formInline.page = val;
this.getAll(this.formInline);
},
removeTag(index) {
console.log(index)
console.log(index);
},
tagChange(index) {
this.$forceUpdate()
console.log(index)
this.$forceUpdate();
console.log(index);
},
//
search() {
this.total = 1
this.formInline.page = 1
this.getAll(this.formInline)
this.total = 1;
this.formInline.page = 1;
this.getAll(this.formInline);
},
//
clear() {
this.formInline = {
permissionName: '', //
page: '1', //
pageSize: '10' //
}
this.getAll(this.formInline)
permissionName: "", //
page: "1", //
pageSize: "10", //
};
this.getAll(this.formInline);
},
//
add(index) {
this.userState = 1
getMaxSort().then(res => {
this.userState = 1;
getMaxSort().then((res) => {
if (index === 1) {
if (this.multipleSelection.length >= 1) {
this.$message({
message: '请勿选择节点进行操作'
})
return
message: "请勿选择节点进行操作",
});
return;
}
this.addForm = {
permissionPid: '', // id
permissionName: '', //
permissionUri: '', // URI
permission: '', //
icon: '', //
describe: '', //
resourceType: 'catalog', // menu- button- catalog-
sort: parseInt(res.data) //
}
this.addFormDialog = true
permissionPid: "", // id
permissionName_ZH: "", //
permissionName_EN: "", //
permissionUri: "", // URI
permission: "", //
icon: "", //
describe: "", //
resourceType: "catalog", // menu- button- catalog-
sort: parseInt(res.data), //
};
this.addFormDialog = true;
} else if (index === 2) {
if (this.multipleSelection.length === 0) {
this.$message({
message: '请选择父节点'
})
return
message: "请选择父节点",
});
return;
}
console.log(this.multipleSelection)
console.log(this.multipleSelection);
if (this.multipleSelection[0].permissionPid !== 0) {
this.$message({
message: '请选择父节点进行操作'
})
return
message: "请选择父节点进行操作",
});
return;
}
this.addForm = {
permissionPid: this.multipleSelection[0].permissionId, // id
permissionName: '', //
permissionUri: '', // URI
permission: '', //
icon: '', //
describe: '', //
resourceType: 'menu', // menu- button- catalog-
sort: parseInt(res.data) //
}
this.addFormDialog = true
console.log(this.multipleSelection[0])
console.log(this.addForm)
permissionName_ZH: "", //
permissionName_EN: "", //
permissionUri: "", // URI
permission: "", //
icon: "", //
describe: "", //
resourceType: "menu", // menu- button- catalog-
sort: parseInt(res.data), //
};
this.addFormDialog = true;
console.log(this.multipleSelection[0]);
console.log(this.addForm);
} else if (index === 3) {
if (this.multipleSelection.length === 0) {
this.$message({
message: '请选择子节点'
})
return
message: "请选择子节点",
});
return;
}
console.log(this.multipleSelection[0].permissionPid)
console.log(this.multipleSelection[0].permissionPid);
if (
this.multipleSelection[0].permissionPid === 0 &&
this.multipleSelection[0].childs.length !== 0
) {
this.$message({
message: '请勿选择父节点进行操作'
})
return
message: "请勿选择父节点进行操作",
});
return;
}
this.addForm = {
permissionPid: this.multipleSelection[0].permissionId, // id
permissionName: '', //
permissionUri: '', // URI
permission: '', //
icon: 'el-icon-minus', //
describe: '', //
resourceType: 'button', // menu- button- catalog-
sort: parseInt(res.data) //
}
this.addFormDialog = true
console.log(this.multipleSelection[0])
console.log(this.addForm)
permissionName_ZH: "", //
permissionName_EN: "", //
permissionUri: "", // URI
permission: "", //
icon: "el-icon-minus", //
describe: "", //
resourceType: "button", // menu- button- catalog-
sort: parseInt(res.data), //
};
this.addFormDialog = true;
console.log(this.multipleSelection[0]);
console.log(this.addForm);
}
})
});
},
//
addForm_enter(ruleForm) {
this.$refs[ruleForm].validate(valid => {
this.$refs[ruleForm].validate((valid) => {
if (valid) {
if (
(this.addForm.permissionName_ZH == "" ||
this.addForm.permissionName_ZH == undefined) &&
(this.addForm.permissionName_EN == "" ||
this.addForm.permissionName_EN == undefined)
) {
this.$message({
message: "请输入名称",
type: "error",
});
return;
}
console.log(this.addForm);
let addData = {};
addData.permissionId = this.addForm.permissionId;
addData.permissionPid = this.addForm.permissionPid;
addData.permissionName = this.addForm.permissionName_ZH;
addData.permissionUri = this.addForm.permissionUri;
addData.permission = this.addForm.permission;
addData.icon = this.addForm.icon;
addData.describe = this.addForm.describe;
addData.resourceType = this.addForm.resourceType;
addData.sort = this.addForm.sort;
addData.permissionNameMap = {}
addData.permissionNameMap["zh"] = this.addForm.permissionName_ZH;
addData.permissionNameMap["en"] = this.addForm.permissionName_EN;
addData.permissionNameJson = JSON.stringify(addData.permissionNameMap);
if (this.userState) {
console.log(this.addForm)
tabsAdd(this.addForm).then(res => {
console.log(res)
if (res.code === '') {
tabsAdd(addData).then((res) => {
console.log(res);
if (res.code === "") {
this.$message({
message: '新增成功',
type: 'success'
})
message: "新增成功",
type: "success",
});
}
this.getAll(this.formInline)
this.addFormDialog = false
})
this.getAll(this.formInline);
this.addFormDialog = false;
});
} else {
tabsUpdate(this.addForm).then(res => {
console.log(res)
if (res.code === '') {
tabsUpdate(addData).then((res) => {
console.log(res);
if (res.code === "") {
this.$message({
message: '修改成功',
type: 'success'
})
message: "修改成功",
type: "success",
});
}
this.getAll(this.formInline)
this.addFormDialog = false
})
this.getAll(this.formInline);
this.addFormDialog = false;
});
}
} else {
console.log('error submit!!')
return false
console.log("error submit!!");
return false;
}
})
});
},
//
edit(row) {
this.userState = 0
this.addFormDialog = true
console.log(row)
tabsGetById({ permissionId: row.permissionId }).then(res => {
this.addForm = res.data
console.log(this.addForm)
this.userState = 0;
this.addFormDialog = true;
console.log(row);
tabsGetById({ permissionId: row.permissionId }).then((res) => {
let itemData = res.data;
itemData.permissionName_ZH = JSON.parse(itemData.permissionNameJson)[
"zh"
];
itemData.permissionName_EN = JSON.parse(itemData.permissionNameJson)[
"en"
];
this.addForm = itemData;
// this.addForm.roleIds = [1];
})
});
},
//
async del(row) {
const res = await tabsDelete({ permissionId: row.permissionId })
if (res.code === '') {
const res = await tabsDelete({ permissionId: row.permissionId });
if (res.code === "") {
this.$message({
message: '删除成功',
type: 'success'
})
message: "删除成功",
type: "success",
});
}
this.getAll(this.formInline)
this.getAll(this.formInline);
},
//
chooseIcon(icon) {
console.log(icon)
this.addForm.icon = icon
this.iconVisible = false
console.log(icon);
this.addForm.icon = icon;
this.iconVisible = false;
},
getFocus() {
this.iconVisible = true
this.iconVisible = true;
},
//
async getAll(formInline) {
const res = await tabsGetAll(formInline)
this.tableData = res.data.list
this.total = res.data.total
}
}
}
const res = await tabsGetAll(formInline);
let tempData = res.data.list;
tempData.forEach((itemData) => {
itemData.permissionName_ZH = JSON.parse(itemData.permissionNameJson)[
"zh"
];
itemData.permissionName_EN = JSON.parse(itemData.permissionNameJson)[
"en"
];
});
this.tableData = tempData;
this.total = res.data.total;
},
},
};
</script>
<style lang='scss' scoped>
//@import url(); css
@import url("../../../styles/elDialog.scss");
.userStyleMenus {
background: #FFFFFF;
background: #ffffff;
border-radius: 10px;
.formSearch{
.formSearch {
padding: 20px 30px;
display: flex;
.searchInput{
.searchInput {
margin-right: 20px;
display: flex;
align-items: center;
span{
span {
min-width: 80px;
}
}
}
.tableBox{
.tableBox {
margin: 0 20px 20px;
}
}

4
src/views/sharesetting/index.vue

@ -234,14 +234,14 @@ export default {
addForm_enter(ruleForm) {
if(this.addForm.shareRate < 0){
this.$message({
message: '税率必须大于或者等于0',
message: '分账比例必须大于或者等于0',
type: 'warning'
})
return false
}
if(this.addForm.shareRate > 100){
this.$message({
message: '税率必须小于或等于100',
message: '分账比例必须小于或等于100',
type: 'warning'
})
return false

Loading…
Cancel
Save