备注信息

This commit is contained in:
weipengfei 2023-09-27 16:19:59 +08:00
parent b14e043f83
commit 2f0f405bdd
3 changed files with 290 additions and 90 deletions

View File

@ -7,10 +7,12 @@ ENV = 'development'
#VUE_APP_BASE_API = 'https://mer1.crmeb.net'
VUE_APP_BASE_API = 'https://crmeb-test.shop.lihaink.cn'
# VUE_APP_BASE_API = 'http://192.168.1.10:8324'
# VUE_APP_BASE_API = 'http://192.168.0.108:8325'
#VUE_APP_BASE_API_Two = 'https://nk.lihaink.cn'
VUE_APP_BASE_API_Two = 'https://crmeb-test.shop.lihaink.cn'
# VUE_APP_BASE_API_Two = 'http://192.168.1.10:8324'
# socket 连接地址
#VUE_APP_WS_URL = 'ws://0.0.0.0:8324'
VUE_APP_WS_URL = 'ws://mer1.crmeb.net'

View File

@ -65,7 +65,7 @@
"lowdb": "^1.0.0",
"moment": "^2.29.1",
"monaco-editor": "^0.19.3",
"node-sass": "^4.13.1",
"node-sass": "^4.14.1",
"normalize.css": "7.0.0",
"nprogress": "0.2.0",
"path-to-regexp": "2.4.0",
@ -94,7 +94,7 @@
"@vue/cli-plugin-babel": "3.5.3",
"@vue/cli-plugin-eslint": "^3.9.1",
"@vue/cli-plugin-unit-jest": "3.5.3",
"@vue/cli-service": "3.5.3",
"@vue/cli-service": "^3.5.3",
"@vue/test-utils": "1.0.0-beta.29",
"autoprefixer": "^9.5.1",
"babel-core": "7.0.0-bridge.0",

View File

@ -14,7 +14,8 @@
v-for="(itemn, indexn) in fromList.fromTxt"
:key="indexn"
:label="itemn.val"
>{{ itemn.text }}</el-radio-button>
>{{ itemn.text }}</el-radio-button
>
</el-radio-group>
<el-date-picker
v-model="timeVal"
@ -28,7 +29,11 @@
@change="onchangeTime"
/>
</el-form-item>
<el-form-item label="关键字:" label-width="80px" style="display: inline-block;">
<el-form-item
label="关键字:"
label-width="80px"
style="display: inline-block"
>
<el-input
v-model="tableFrom.keyword"
@keyup.enter.native="getList(1)"
@ -102,8 +107,16 @@
:value="item.code"
/>
</el-select> -->
<el-cascader v-model="tableFrom.area_id" :options="form.options" @change="handleChange1"></el-cascader>
<el-cascader v-model="tableFrom.street_id" :options="form.options1" @change="getList(1)"></el-cascader>
<el-cascader
v-model="tableFrom.area_id"
:options="form.options"
@change="handleChange1"
></el-cascader>
<el-cascader
v-model="tableFrom.street_id"
:options="form.options1"
@change="getList(1)"
></el-cascader>
</el-form-item>
<el-tabs
v-if="headeNum.length > 0"
@ -119,7 +132,9 @@
</el-tabs>
</el-form>
</div>
<el-button size="small" type="primary" @click="onAdd">添加商户</el-button>
<el-button size="small" type="primary" @click="onAdd"
>添加商户</el-button
>
</div>
<el-table
v-loading="listLoading"
@ -166,7 +181,13 @@
<el-table-column prop="create_time" label="创建时间" min-width="150" />
<el-table-column prop="margin" label="保证金" min-width="150">
<template slot-scope="scope">
<span>{{scope.row.is_margin == 1 ? '未支付' : scope.row.is_margin == 0 ? '无' : '已支付'}}</span>
<span>{{
scope.row.is_margin == 1
? "未支付"
: scope.row.is_margin == 0
? "无"
: "已支付"
}}</span>
</template>
</el-table-column>
<el-table-column prop="sort" label="排序" min-width="100" />
@ -184,7 +205,12 @@
/>
</template>
</el-table-column>
<el-table-column label="操作" min-width="280" fixed="right" align="center">
<el-table-column
label="操作"
min-width="280"
fixed="right"
align="center"
>
<template slot-scope="scope">
<!-- <router-link
v-if="tableFrom.status === '1'"
@ -197,26 +223,35 @@
type="text"
size="small"
@click="onLogo(scope.row.mer_id)"
>登录</el-button>
<el-button type="text" size="small" @click="onEdit(scope.row.mer_id)">编辑</el-button>
>登录</el-button
>
<el-button
type="text"
size="small"
@click="onEdit(scope.row.mer_id)"
>编辑</el-button
>
<el-button
v-if="tableFrom.status === '1'"
type="text"
size="small"
@click="onPassword(scope.row.mer_id)"
>修改管理员密码</el-button>
>修改管理员密码</el-button
>
<el-button
v-if="tableFrom.status === '0'"
type="text"
size="small"
@click="handleDelete(scope.row.mer_id, scope.$index)"
>删除</el-button>
>删除</el-button
>
<el-button
v-if="tableFrom.status === '1'"
type="text"
size="small"
@click="handleTimes(scope.row.mer_id)"
>设置第三方平台商品复制次数</el-button>
>设置第三方平台商品复制次数</el-button
>
<!-- <el-button
v-if="tableFrom.status === '1'"
type="text"
@ -239,12 +274,28 @@
</div>
</el-card>
<!-- 添加商户弹出层 -->
<el-dialog title="添加商品" :visible.sync="popFormVisible" @close="close('form')">
<el-dialog
title="添加商品"
:visible.sync="popFormVisible"
@close="close('form')"
>
<el-form :model="form" :rules="rules" ref="form">
<el-form-item label="商户名称" :label-width="formLabelWidth" prop="mer_name">
<el-input v-model="form.mer_name" autocomplete="off" placeholder="请输入商户名称"></el-input>
<el-form-item
label="商户名称"
:label-width="formLabelWidth"
prop="mer_name"
>
<el-input
v-model="form.mer_name"
autocomplete="off"
placeholder="请输入商户名称"
></el-input>
</el-form-item>
<el-form-item label="商户分类" :label-width="formLabelWidth" prop="category_id">
<el-form-item
label="商户分类"
:label-width="formLabelWidth"
prop="category_id"
>
<el-select v-model="form.category_id" placeholder="请选择商户分类">
<el-option
:label="item.label"
@ -254,7 +305,11 @@
></el-option>
</el-select>
</el-form-item>
<el-form-item label="店铺类型" :label-width="formLabelWidth" prop="type_id">
<el-form-item
label="店铺类型"
:label-width="formLabelWidth"
prop="type_id"
>
<el-select v-model="form.type_id" placeholder="请选择店铺类型">
<el-option
:label="item.label"
@ -265,15 +320,27 @@
</el-select>
</el-form-item>
<el-form-item label="商圈" :label-width="formLabelWidth">
<el-cascader v-model="form.info" :options="form.options" @change="handleChange1"></el-cascader>
<el-cascader v-model="form.info1" :options="form.options1" @change="handleChange2"></el-cascader>
<el-cascader
v-model="form.info"
:options="form.options"
@change="handleChange1"
></el-cascader>
<el-cascader
v-model="form.info1"
:options="form.options1"
@change="handleChange2"
></el-cascader>
<el-cascader
v-model="form.info2"
:options="form.options2"
@change="handleChange3($event, form.options2)"
></el-cascader>
</el-form-item>
<el-form-item label="商户账号" :label-width="formLabelWidth" prop="mer_account">
<el-form-item
label="商户账号"
:label-width="formLabelWidth"
prop="mer_account"
>
<el-input
v-model="form.mer_account"
autocomplete="off"
@ -281,7 +348,11 @@
:disabled="!add"
></el-input>
</el-form-item>
<el-form-item label="登陆密码" :label-width="formLabelWidth" prop="mer_password">
<el-form-item
label="登陆密码"
:label-width="formLabelWidth"
prop="mer_password"
>
<el-input
v-model="form.mer_password"
autocomplete="off"
@ -290,20 +361,68 @@
></el-input>
</el-form-item>
<div class="dis">
<el-form-item label="已支付的保证金" :label-width="formLabelWidth" class="mer_phone">
<el-form-item
label="保证金额度"
:label-width="formLabelWidth"
class="mer_phone"
>
<el-input
v-model="form.ot_margin"
style="width: 200px"
autocomplete="off"
disabled
placeholder="保证金额度"
></el-input>
</el-form-item>
<el-form-item
label="已缴纳的保证金"
:label-width="formLabelWidth"
class="mer_phone"
>
<el-input
v-model="form.paid_margin"
style="width: 200px"
autocomplete="off"
placeholder="请输入已支付的保证金"
disabled
placeholder="已缴纳的保证金"
></el-input>
</el-form-item>
<el-form-item label="自动扣除保证金比例" :label-width="formLabelWidth" prop="commission_rate">
<el-input v-model="form.auto_margin_rate" style="width:200px" autocomplete="off"></el-input>
</div>
<div class="dis">
<el-form-item
label="需缴纳的保证金"
:label-width="formLabelWidth"
class="mer_phone"
>
<el-input
v-model="form.margin"
style="width: 200px"
autocomplete="off"
placeholder="请输入需缴纳的保证金"
></el-input>
</el-form-item>
<el-form-item
label="自动扣除保证金比例"
:label-width="formLabelWidth"
prop="commission_rate"
>
<el-input
v-model="form.auto_margin_rate"
style="width: 200px"
autocomplete="off"
></el-input>
</el-form-item>
</div>
<el-form-item label="商户姓名" :label-width="formLabelWidth" prop="real_name">
<el-input v-model="form.real_name" autocomplete="off" placeholder="请输入商户姓名"></el-input>
<el-form-item
label="商户姓名"
:label-width="formLabelWidth"
prop="real_name"
>
<el-input
v-model="form.real_name"
autocomplete="off"
placeholder="请输入商户姓名"
></el-input>
</el-form-item>
<div class="dis">
<el-form-item
@ -312,9 +431,17 @@
prop="mer_phone"
class="mer_phone"
>
<el-input v-model="form.mer_phone" autocomplete="off" placeholder="请输入商户手机号"></el-input>
<el-input
v-model="form.mer_phone"
autocomplete="off"
placeholder="请输入商户手机号"
></el-input>
</el-form-item>
<el-form-item label="手续费(%)" :label-width="formLabelWidth" prop="commission_rate">
<el-form-item
label="手续费(%)"
:label-width="formLabelWidth"
prop="commission_rate"
>
<el-input-number
v-model="form.commission_rate"
@change="handleChange"
@ -325,14 +452,38 @@
></el-input-number>
</el-form-item>
</div>
<el-form-item label="商户关键字" :label-width="formLabelWidth" prop="mer_keyword">
<el-input v-model="form.mer_keyword" autocomplete="off" placeholder="请输入商户关键字"></el-input>
<el-form-item
label="商户关键字"
:label-width="formLabelWidth"
prop="mer_keyword"
>
<el-input
v-model="form.mer_keyword"
autocomplete="off"
placeholder="请输入商户关键字"
></el-input>
</el-form-item>
<el-form-item label="商户地址" :label-width="formLabelWidth" prop="mer_address">
<el-input v-model="form.mer_address" autocomplete="off" placeholder="请输入商户地址"></el-input>
<el-form-item
label="商户地址"
:label-width="formLabelWidth"
prop="mer_address"
>
<el-input
v-model="form.mer_address"
autocomplete="off"
placeholder="请输入商户地址"
></el-input>
</el-form-item>
<el-form-item label="微信分账商户号" :label-width="formLabelWidth" prop="sub_mchid">
<el-input v-model="form.sub_mchid" autocomplete="off" placeholder="请输入微信分账商户号"></el-input>
<el-form-item
label="微信分账商户号"
:label-width="formLabelWidth"
prop="sub_mchid"
>
<el-input
v-model="form.sub_mchid"
autocomplete="off"
placeholder="请输入微信分账商户号"
></el-input>
</el-form-item>
<el-form-item label="备注" :label-width="formLabelWidth" prop="mark">
<el-input
@ -344,10 +495,20 @@
></el-input>
</el-form-item>
<el-form-item label="排序" :label-width="formLabelWidth" prop="sort">
<el-input-number v-model="form.sort" @change="handleChange" :min="0" :max="10"></el-input-number>
<el-input-number
v-model="form.sort"
@change="handleChange"
:min="0"
:max="10"
></el-input-number>
</el-form-item>
<div class="switch_btn">
<el-form-item class="mini_btn" label="直播间审核" prop="value1" :label-width="formLabelWidth">
<el-form-item
class="mini_btn"
label="直播间审核"
prop="value1"
:label-width="formLabelWidth"
>
<el-switch
v-model="form.value1"
active-color="#3390ff"
@ -356,7 +517,12 @@
inactive-color="#DCDFE6"
></el-switch>
</el-form-item>
<el-form-item class="mini_btn" label="产品审核" prop="value2" :label-width="formLabelWidth">
<el-form-item
class="mini_btn"
label="产品审核"
prop="value2"
:label-width="formLabelWidth"
>
<el-switch
v-model="form.value2"
active-color="#3390ff"
@ -379,7 +545,12 @@
inactive-color="#DCDFE6"
></el-switch>
</el-form-item>
<el-form-item class="mini_btn" label="是否推荐" prop="value4" :label-width="formLabelWidth">
<el-form-item
class="mini_btn"
label="是否推荐"
prop="value4"
:label-width="formLabelWidth"
>
<el-switch
v-model="form.value4"
active-color="#3390ff"
@ -388,7 +559,12 @@
inactive-color="#DCDFE6"
></el-switch>
</el-form-item>
<el-form-item class="mini_btn" label="是否自营" prop="value5" :label-width="formLabelWidth">
<el-form-item
class="mini_btn"
label="是否自营"
prop="value5"
:label-width="formLabelWidth"
>
<el-switch
v-model="form.value5"
active-color="#3390ff"
@ -460,7 +636,9 @@ export default {
area_id: "", //code
street_id: "", //code
village_id: "", //id
paid_margin: "", //
paid_margin: "", //
margin: "", //
ot_margin: "", //
auto_margin_rate: "", //
options: [],
options1: [],
@ -657,7 +835,11 @@ export default {
if (this.add) {
//--merchantCreate
try {
const res = await merchantCreate(this.form);
let f_data = JSON.parse(JSON.stringify(this.form));
delete f_data.options;
delete f_data.options1;
delete f_data.options2;
const res = await merchantCreate(f_data);
console.log("res", res);
if (res.status == 200) {
this.open2(res.message);
@ -671,7 +853,11 @@ export default {
try {
console.log(this.form);
console.log("id", this.merid);
const res = await merchantUpdateA(this.merid, this.form);
let f_data = JSON.parse(JSON.stringify(this.form));
delete f_data.options;
delete f_data.options1;
delete f_data.options2;
const res = await merchantUpdateA(this.merid, f_data);
console.log("res", res);
if (res.status == 200) {
this.open2(res.message);
@ -824,6 +1010,16 @@ export default {
onAdd () {
this.add = true;
this.popFormVisible = true;
this.form.auto_margin_rate = 0; //
this.form.paid_margin = "0.00"; //
this.form.ot_margin = "0.00"; //
this.form.margin = ""; //
this.form.area_id = "";
this.form.street_id = "";
this.form.village_id = "";
this.form.info = "";
this.form.info1 = "";
this.form.info2 = "";
// this.$modalForm(merchantCreateApi()).then(() => this.getList(""));
},
//
@ -845,6 +1041,8 @@ export default {
this.form.mer_phone = res.mer_phone;
this.form.auto_margin_rate = res.auto_margin_rate; //
this.form.paid_margin = res.paid_margin; //
this.form.ot_margin = res.ot_margin; //
this.form.margin = res.margin; //
this.form.area_id = res.geo_address.area_id;
this.form.street_id = res.geo_address.street_id;
this.form.village_id = res.geo_address.village_id;