定制产品

This commit is contained in:
faiz 2024-08-29 17:22:11 +08:00
parent 4042b16a75
commit 0af602352e
7 changed files with 867 additions and 544 deletions

View File

@ -1,42 +1,42 @@
@charset "UTF-8"; @charset "UTF-8";
.el-card{ .el-card {
font-size: 14px; font-size: 14px;
} }
.svg-icon{ .svg-icon {
width: 0.8em !important; width: 0.8em !important;
height: 0.8em !important; height: 0.8em !important;
} }
.el-table--mini { .el-table--mini {
font-size: 13px !important; font-size: 13px !important;
} }
.el-dialog__body{ .el-dialog__body {
// padding: 5px 20px 15px 20px !important; // padding: 5px 20px 15px 20px !important;
} }
.el-dialog__wrapper{ .el-dialog__wrapper {
//overflow: auto !important; //overflow: auto !important;
} }
.selWidth{ .selWidth {
width: 280px; width: 280px;
} }
.mobile-page{ .mobile-page {
width: 100%; width: 100%;
} }
.paddingBox{ .paddingBox {
padding:0 10px 10px; padding: 0 10px 10px;
} }
.mobile-config{ .mobile-config {
width: 100%; width: 100%;
padding: 15px; padding: 15px;
} }
.c_label{ .c_label {
font-size: 14px; font-size: 14px;
color: #999999; color: #999999;
} }
.c_label span{ .c_label span {
margin-left: 10px; margin-left: 10px;
color: #333; color: #333;
} }
.empty-box{ .empty-box {
width: 100%; width: 100%;
height: 100%; height: 100%;
display: flex; display: flex;
@ -45,14 +45,23 @@
background: #f3f5f7; background: #f3f5f7;
border-radius: 6px; border-radius: 6px;
} }
.empty-box.on{ .empty-box.on {
border-radius: 0px; border-radius: 0px;
} }
.empty-box .iconfont-diy{ .customize {
// background: red;
.cell {
height: 100%;
display: flex;
flex-direction: column;
justify-content: space-around;
}
}
.empty-box .iconfont-diy {
color: #bbbfc8; color: #bbbfc8;
font-size: 30px; font-size: 30px;
} }
.c_row-item{ .c_row-item {
display: flex; display: flex;
justify-content: space-between; justify-content: space-between;
align-items: center; align-items: center;
@ -125,43 +134,43 @@
-webkit-justify-content: space-between; -webkit-justify-content: space-between;
justify-content: space-between; justify-content: space-between;
} }
.divBox{ .divBox {
box-sizing: border-box; box-sizing: border-box;
.el-pagination{ .el-pagination {
display: flex; display: flex;
justify-content: flex-end; justify-content: flex-end;
margin-top: 25px; margin-top: 25px;
} }
} }
.seachTiele{ .seachTiele {
font-size: 12px; font-size: 12px;
} }
.el-divider--horizontal{ .el-divider--horizontal {
margin: 19px 0; margin: 19px 0;
} }
.suibian-modal{ .suibian-modal {
.el-dialog__footer{ .el-dialog__footer {
display: none !important; display: none !important;
} }
} }
.el-message-box__wrapper{ .el-message-box__wrapper {
overflow: auto; overflow: auto;
} }
.el-message-box{ .el-message-box {
overflow: auto!important; overflow: auto !important;
} }
.modal-form{ .modal-form {
width: 600px; width: 600px;
} }
.modal-form .el-select{ .modal-form .el-select {
width: 100%; width: 100%;
} }
.upload-form{ .upload-form {
min-width: 1000px; min-width: 1000px;
max-height:620px; max-height: 620px;
} }
.listPic{ .listPic {
.image-slot{ .image-slot {
width: 100%; width: 100%;
height: 100%; height: 100%;
display: flex; display: flex;
@ -169,18 +178,19 @@
align-items: center; align-items: center;
} }
} }
.switchTable{ .switchTable {
.el-switch.is-disabled { .el-switch.is-disabled {
opacity: 1; opacity: 1;
} }
.el-switch.is-disabled .el-switch__core, .el-switch.is-disabled .el-switch__label { .el-switch.is-disabled .el-switch__core,
cursor: pointer !important;; .el-switch.is-disabled .el-switch__label {
cursor: pointer !important;
} }
} }
/** /**
* 上传图片的照相机 * 上传图片的照相机
*/ */
.upLoadPicBox{ .upLoadPicBox {
display: inline-block; display: inline-block;
cursor: pointer; cursor: pointer;
@ -194,7 +204,7 @@
width: 100%; width: 100%;
height: 100%; height: 100%;
} }
.btndel{ .btndel {
position: absolute; position: absolute;
right: -5px; right: -5px;
top: -5px; top: -5px;
@ -218,58 +228,58 @@
/** /**
* 标题带下划线 * 标题带下划线
*/ */
.dividerTitle{ .dividerTitle {
.title{ .title {
border-bottom: 2px solid var(--prev-color-primary); border-bottom: 2px solid var(--prev-color-primary);
padding: 0 8px 18px 5px; padding: 0 8px 18px 5px;
color: #000; color: #000;
font-size: 14px; font-size: 14px;
} }
} }
.cameraIconfont{ .cameraIconfont {
color: #898989; color: #898989;
font-size: 26px; font-size: 26px;
} }
.ml10{ .ml10 {
margin-left: 10px; margin-left: 10px;
} }
.mr10{ .mr10 {
margin-right: 10px; margin-right: 10px;
} }
.mb15{ .mb15 {
margin-bottom: 15px; margin-bottom: 15px;
} }
.mb20{ .mb20 {
margin-bottom: 20px; margin-bottom: 20px;
} }
.mb5{ .mb5 {
margin-bottom: 5px; margin-bottom: 5px;
} }
.mr15{ .mr15 {
margin-right: 15px; margin-right: 15px;
} }
.mt20{ .mt20 {
margin-top: 20px; margin-top: 20px;
} }
.mr50 { .mr50 {
margin-right: 50px; margin-right: 50px;
} }
.mr20{ .mr20 {
margin-right: 20px !important; margin-right: 20px !important;
} }
.ml40 { .ml40 {
margin-left: 40px !important; margin-left: 40px !important;
} }
.ml50{ .ml50 {
margin-left: 50px !important; margin-left: 50px !important;
} }
.mb10{ .mb10 {
margin-bottom: 10px; margin-bottom: 10px;
} }
.mr5{ .mr5 {
margin-right: 5px; margin-right: 5px;
} }
.pl25{ .pl25 {
padding-left: 25px; padding-left: 25px;
box-sizing: border-box; box-sizing: border-box;
} }
@ -279,19 +289,19 @@ a {
text-decoration: none; text-decoration: none;
outline: none; outline: none;
cursor: pointer; cursor: pointer;
transition: color .2s ease; transition: color 0.2s ease;
font-size: 12px; font-size: 12px;
} }
.spBlock{ .spBlock {
display: block; display: block;
} }
.onHand{ .onHand {
cursor: pointer; cursor: pointer;
} }
/** /**
* 搜索框标题 * 搜索框标题
*/ */
.seachTiele{ .seachTiele {
line-height: 35px; line-height: 35px;
font-size: 12px; font-size: 12px;
} }
@ -322,7 +332,7 @@ a {
.el-table__row .el-switch .el-switch__core, .el-table__row .el-switch .el-switch__core,
.el-table__row .el-switch .el-switch__label { .el-table__row .el-switch .el-switch__label {
font-size: 12px; font-size: 12px;
width: 55px!important; width: 55px !important;
} }
.el-switch__label * { .el-switch__label * {
font-size: 12px; font-size: 12px;
@ -343,7 +353,7 @@ a {
margin-bottom: 0; margin-bottom: 0;
width: 33.33%; width: 33.33%;
} }
table .el-image{ table .el-image {
width: 36px; width: 36px;
height: 36px; height: 36px;
} }
@ -351,19 +361,23 @@ table .el-image{
.index_bg { .index_bg {
width: 100%; width: 100%;
height: 100vh; height: 100vh;
background: rgba(0, 0, 0, .6) !important; background: rgba(0, 0, 0, 0.6) !important;
z-index: 0 !important; z-index: 0 !important;
} }
//表格下拉文字 //表格下拉文字
.el-form-item__label, .el-form-item__content{ .el-form-item__label,
.el-form-item__content {
font-size: 13px !important; font-size: 13px !important;
} }
@font-face { @font-face {
font-family: "iconfont"; /* Project id 2955395 */ font-family: "iconfont"; /* Project id 2955395 */
src: url('//at.alicdn.com/t/font_2955395_hzsad8tzvr.woff2?t=1637567333533') format('woff2'), src: url("//at.alicdn.com/t/font_2955395_hzsad8tzvr.woff2?t=1637567333533")
url('//at.alicdn.com/t/font_2955395_hzsad8tzvr.woff?t=1637567333533') format('woff'), format("woff2"),
url('//at.alicdn.com/t/font_2955395_hzsad8tzvr.ttf?t=1637567333533') format('truetype'); url("//at.alicdn.com/t/font_2955395_hzsad8tzvr.woff?t=1637567333533")
format("woff"),
url("//at.alicdn.com/t/font_2955395_hzsad8tzvr.ttf?t=1637567333533")
format("truetype");
} }
.iconfont { .iconfont {
@ -417,75 +431,78 @@ table .el-image{
.icon-dingdanguanli:before { .icon-dingdanguanli:before {
content: "\e605"; content: "\e605";
} }
.el-menu-item,.el-submenu__title { .el-menu-item,
.el-submenu__title {
height: 50px; height: 50px;
line-height: 50px; line-height: 50px;
} }
.styleTwo,.styleTwo .el-menu--popup { .styleTwo,
min-width: 140px!important; .styleTwo .el-menu--popup {
min-width: 140px !important;
padding: 0; padding: 0;
max-height: auto; max-height: auto;
} }
.styleTwo .el-menu--popup{ .styleTwo .el-menu--popup {
border-radius: 4px; border-radius: 4px;
background: #5F5F66!important; background: #5f5f66 !important;
} }
.styleTwo{ .styleTwo {
&::before{ &::before {
content: ""; content: "";
border: 10px solid transparent; border: 10px solid transparent;
border-right-color: #5F5F66; border-right-color: #5f5f66;
position: absolute; position: absolute;
left: 0; left: 0;
top: 50px; top: 50px;
} }
} }
.styleTwo .el-menu--popup-right-start{ .styleTwo .el-menu--popup-right-start {
margin-left: 17px; margin-left: 17px;
margin-right: 12px; margin-right: 12px;
} }
.styleTwo li{ .styleTwo li {
background: #5f5f66!important; background: #5f5f66 !important;
height: 46px!important; height: 46px !important;
line-height: 46px!important; line-height: 46px !important;
font-size: 13px; font-size: 13px;
padding-left: 0!important; padding-left: 0 !important;
} }
.styleTwo .el-submenu__title{ .styleTwo .el-submenu__title {
background: #5f5f66!important; background: #5f5f66 !important;
height: 46px!important; height: 46px !important;
line-height: 46px!important; line-height: 46px !important;
font-size: 13px; font-size: 13px;
color: #ffffff!important; color: #ffffff !important;
} }
.styleTwo li:hover,.styleTwo .is-active{ .styleTwo li:hover,
background: #77777D!important; .styleTwo .is-active {
.el-submenu__title{ background: #77777d !important;
background: #77777D!important; .el-submenu__title {
background: #77777d !important;
} }
} }
.styleTwo .router-link-active{ .styleTwo .router-link-active {
background: #ffffff; background: #ffffff;
} }
#app .hideSidebar .style2 .el-submenu>.el-submenu__title{ #app .hideSidebar .style2 .el-submenu > .el-submenu__title {
text-align: left!important; text-align: left !important;
} }
.el-slider__button-wrapper{ .el-slider__button-wrapper {
z-index: 100 z-index: 100;
} }
.el-radio-button .el-radio__input.is-checked+.el-radio__label, .el-radio-button .el-radio__input.is-checked + .el-radio__label,
.el-radio-button .el-radio-button__inner:hover { .el-radio-button .el-radio-button__inner:hover {
color: var(--prev-color-primary); color: var(--prev-color-primary);
} }
.fc-upload-btn{ .fc-upload-btn {
display: flex!important; display: flex !important;
align-items: center; align-items: center;
justify-content: center; justify-content: center;
} }
.fc-upload-btn .el-icon-camera{ .fc-upload-btn .el-icon-camera {
font-size: 26px; font-size: 26px;
color: #898989; color: #898989;
} }

View File

@ -14,18 +14,29 @@
<div class="text"> <div class="text">
<div class="title"> <div class="title">
<span class="bold">{{ merData.mer_name }}</span> <span class="bold">{{ merData.mer_name }}</span>
<el-tag v-if="merData.is_trader" type="danger" class="tags_name" effect="dark" size="mini">自营</el-tag> <el-tag
<el-tag v-if="merData.merchantType" type="warning" class="tags_name" effect="dark" size="mini">{{merData.merchantType.type_name}}</el-tag> v-if="merData.is_trader"
type="danger"
class="tags_name"
effect="dark"
size="mini"
>自营</el-tag
>
<el-tag
v-if="merData.merchantType"
type="warning"
class="tags_name"
effect="dark"
size="mini"
>{{ merData.merchantType.type_name }}</el-tag
>
</div> </div>
<div> <div>
<span class="mr20">{{ merData.mer_address }}</span> <span class="mr20">{{ merData.mer_address }}</span>
</div> </div>
</div> </div>
<div> <div>
<el-button <el-button v-if="isEdit" size="small" @click="cancelEdit"
v-if="isEdit"
size="small"
@click="cancelEdit"
>取消</el-button >取消</el-button
> >
<el-button <el-button
@ -45,7 +56,9 @@
<el-dropdown @command="handleCommand" class="ml10"> <el-dropdown @command="handleCommand" class="ml10">
<el-button icon="el-icon-more" size="small"></el-button> <el-button icon="el-icon-more" size="small"></el-button>
<el-dropdown-menu slot="dropdown"> <el-dropdown-menu slot="dropdown">
<el-dropdown-item command="password">修改管理员密码</el-dropdown-item> <el-dropdown-item command="password"
>修改管理员密码</el-dropdown-item
>
</el-dropdown-menu> </el-dropdown-menu>
</el-dropdown> </el-dropdown>
</div> </div>
@ -53,7 +66,7 @@
<ul class="list"> <ul class="list">
<li class="item"> <li class="item">
<div class="title">联系人</div> <div class="title">联系人</div>
<div>{{merData.real_name}}</div> <div>{{ merData.real_name }}</div>
</li> </li>
<li class="item"> <li class="item">
<div class="title">联系电话</div> <div class="title">联系电话</div>
@ -61,7 +74,7 @@
</li> </li>
<li class="item"> <li class="item">
<div class="title">状态</div> <div class="title">状态</div>
<div>{{ merData.status==1 ? '开启' : '关闭' }}</div> <div>{{ merData.status == 1 ? "开启" : "关闭" }}</div>
</li> </li>
<li class="item"> <li class="item">
<div class="title">入驻时间</div> <div class="title">入驻时间</div>
@ -86,25 +99,28 @@
:merData="merData" :merData="merData"
@modifyCopy="modifyCopy" @modifyCopy="modifyCopy"
@success="editSuccess" @success="editSuccess"
v-if="isEdit || isAdd"> v-if="isEdit || isAdd"
>
</merEditForm> </merEditForm>
<mer-info ref="merInfo" :merData="merData" v-else-if="!isEdit && !isAdd"></mer-info> <mer-info
ref="merInfo"
:merData="merData"
v-else-if="!isEdit && !isAdd"
></mer-info>
</div> </div>
<div v-if="isAdd" class="footer"> <div v-if="isAdd" class="footer">
<el-button size="small" @click="handleClose">取消</el-button> <el-button size="small" @click="handleClose">取消</el-button>
<el-button type="primary" size="small" @click="submitInfo">提交</el-button> <el-button type="primary" size="small" @click="submitInfo"
>提交</el-button
>
</div> </div>
</el-drawer> </el-drawer>
</div> </div>
</template> </template>
<script> <script>
import { merchantDetail } from "@/api/merchant";
import { import merInfo from "./merInfo";
merchantDetail, import merEditForm from "./merEditForm";
} from '@/api/merchant';
import merInfo from './merInfo';
import merEditForm from './merEditForm';
export default { export default {
props: { props: {
drawer: { drawer: {
@ -118,36 +134,34 @@ export default {
storeType: { storeType: {
type: Array, type: Array,
default: [], default: [],
} },
}, },
components: { merInfo, merEditForm }, components: { merInfo, merEditForm },
data() { data() {
return { return {
loading: true, loading: true,
merId: '', merId: "",
isEdit: false, isEdit: false,
isAdd: false, isAdd: false,
direction: 'rtl', direction: "rtl",
activeName: 'detail', activeName: "detail",
merData: {}, merData: {},
orderImg: require('@/assets/images/store_icon.png'), orderImg: require("@/assets/images/store_icon.png"),
}; };
}, },
filters: { filters: {},
},
methods: { methods: {
handleClose() { handleClose() {
if(this.isEdit || this.isAdd) { if (this.isEdit || this.isAdd) {
this.$refs.editForm.resetData(); this.$refs.editForm.resetData();
this.$refs.editForm.activeName = 'detail'; this.$refs.editForm.activeName = "detail";
}else{ } else {
this.$refs.merInfo.activeName = 'detail'; this.$refs.merInfo.activeName = "detail";
} }
this.$emit('closeDrawer'); this.$emit("closeDrawer");
}, },
getInfo(id) { getInfo(id) {
this.merId = id this.merId = id;
this.isAdd = false; this.isAdd = false;
merchantDetail(id) merchantDetail(id)
.then((res) => { .then((res) => {
@ -155,75 +169,118 @@ export default {
this.drawer = true; this.drawer = true;
this.merData = res.data; this.merData = res.data;
let financial_bank = { let financial_bank = {
name:'', name: "",
bank:'', bank: "",
bank_code:'', bank_code: "",
inter_bank:'' inter_bank: "",
} };
if(!res.data.financial_bank){ if (!res.data.financial_bank) {
this.merData.financial_bank = financial_bank; this.merData.financial_bank = financial_bank;
} }
if(!this.isEdit)this.$refs.merInfo.onOperateLog(this.merId); if (!this.isEdit) this.$refs.merInfo.onOperateLog(this.merId);
}) })
.catch((res) => { .catch((res) => {
this.$message.error(res.message); this.$message.error(res.message);
}); });
}, },
initData(){ initData() {
this.merData = { this.merData = {
is_trader:0, is_trader: 0,
is_margin:0, is_margin: 0,
is_service:0, is_service: 0,
is_goods:0, is_goods: 0,
financial_bank:{ financial_bank: {
name:'', name: "",
bank:'', bank: "",
bank_code:'', bank_code: "",
inter_bank:'' inter_bank: "",
}, },
ext:{ ext: {
com:{} biz: {
} end: "",
} city: "",
image: [],
start: "",
number: "",
address: "",
cityInfo: "",
province: "",
address_true: "",
businessScope: "",
},
com: {
name: "",
type: "",
mobile: "",
number: "",
contact: "",
initiator: "",
is_huimei: false,
init_image: [],
is_soldier: false,
inti_mobile: "",
inti_number: "",
image_huimei: [],
image_soldier: [],
},
bank: {
CNAPS: "",
bankCard: "",
bankName: "",
bankCardImg: [],
bankBranchName: "",
bankCardUserName: "",
},
idcard: {
end: "",
name: "",
start: "",
image1: "",
image2: "",
image3: "",
number: "",
},
},
};
this.isEdit = false; this.isEdit = false;
this.isAdd = true; this.isAdd = true;
this.loading = false; this.loading = false;
}, },
merEdit(){ merEdit() {
this.isEdit = true; this.isEdit = true;
this.$nextTick(()=>{ this.$nextTick(() => {
this.getInfo(this.merId); this.getInfo(this.merId);
}) });
}, },
cancelEdit() { cancelEdit() {
this.isEdit = false this.isEdit = false;
}, },
// //
editSuccess(){ editSuccess() {
if(this.isAdd){ if (this.isAdd) {
this.handleClose(); this.handleClose();
}else{ } else {
this.isEdit = false; this.isEdit = false;
} }
this.$emit('getList') this.$emit("getList");
}, },
// //
modifyCopy(){ modifyCopy() {
this.$emit('handleTimes',this.merId); this.$emit("handleTimes", this.merId);
}, },
// //
handleCommand() { handleCommand() {
this.$emit('onPassword',this.merId); this.$emit("onPassword", this.merId);
}, },
saveInfo(){ saveInfo() {
this.$refs.editForm.onSubmit(this.merId); this.$refs.editForm.onSubmit(this.merId);
setTimeout(()=>{ setTimeout(() => {
this.getInfo(this.merId); this.getInfo(this.merId);
},500) }, 500);
}, },
submitInfo(){ submitInfo() {
this.$refs.editForm.handleCreate(); this.$refs.editForm.handleCreate();
} },
}, },
}; };
</script> </script>
@ -253,7 +310,7 @@ export default {
} }
} }
} }
.bold{ .bold {
font-weight: bold; font-weight: bold;
} }
.list { .list {
@ -338,7 +395,7 @@ export default {
.gary { .gary {
color: #aaa; color: #aaa;
} }
.footer{ .footer {
width: 100%; width: 100%;
text-align: center; text-align: center;
position: absolute; position: absolute;

View File

@ -35,7 +35,11 @@
</el-row> </el-row>
<el-row :gutter="24" class="mt20"> <el-row :gutter="24" class="mt20">
<el-col :span="12"> <el-col :span="12">
<el-form-item label="企业名称:" prop="ext.com.name" v-if="merData.ext&&merData.ext.com"> <el-form-item
label="企业名称:"
prop="ext.com.name"
v-if="merData.ext && merData.ext.com"
>
<el-input <el-input
size="small" size="small"
v-model="merData.ext.com.name" v-model="merData.ext.com.name"
@ -46,9 +50,7 @@
</el-col> </el-col>
<el-col :span="12"> <el-col :span="12">
<el-form-item label="商户类型:" prop="is_trader"> <el-form-item label="商户类型:" prop="is_trader">
<el-radio-group <el-radio-group v-model="merData.is_trader">
v-model="merData.is_trader"
>
<el-radio :label="1" class="radio">自营</el-radio> <el-radio :label="1" class="radio">自营</el-radio>
<el-radio :label="0">非自营</el-radio> <el-radio :label="0">非自营</el-radio>
</el-radio-group> </el-radio-group>
@ -178,7 +180,7 @@
<el-form-item label="每日提现额度:" prop="exchange_limit"> <el-form-item label="每日提现额度:" prop="exchange_limit">
<el-input <el-input
size="small" size="small"
oninput ="value=value.replace(/[^\d]/g,'')" oninput="value=value.replace(/[^\d]/g,'')"
v-model="merData.exchange_limit" v-model="merData.exchange_limit"
placeholder="请输入每日提现额度" placeholder="请输入每日提现额度"
class="selWidth" class="selWidth"
@ -211,10 +213,13 @@
</el-row> </el-row>
<el-row v-if="merData.financial_bank"> <el-row v-if="merData.financial_bank">
<el-col :span="12"> <el-col :span="12">
<el-form-item label="开户银行卡号:" prop="financial_bank.bank_code"> <el-form-item
label="开户银行卡号:"
prop="financial_bank.bank_code"
>
<el-input <el-input
size="small" size="small"
oninput ="value=value.replace(/[^\d]/g,'')" oninput="value=value.replace(/[^\d]/g,'')"
v-model="merData.financial_bank.bank_code" v-model="merData.financial_bank.bank_code"
placeholder="请输入开户银行卡号" placeholder="请输入开户银行卡号"
class="selWidth" class="selWidth"
@ -225,7 +230,7 @@
<el-form-item label="联行号:" prop="financial_bank.inter_bank"> <el-form-item label="联行号:" prop="financial_bank.inter_bank">
<el-input <el-input
size="small" size="small"
oninput ="value=value.replace(/[^\d]/g,'')" oninput="value=value.replace(/[^\d]/g,'')"
v-model="merData.financial_bank.inter_bank" v-model="merData.financial_bank.inter_bank"
placeholder="请输入联行号" placeholder="请输入联行号"
class="selWidth" class="selWidth"
@ -245,10 +250,13 @@
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="12"> <el-col :span="12">
<el-form-item label="法人身份证:" prop="financial_bank.inter_bank"> <el-form-item
label="法人身份证:"
prop="financial_bank.inter_bank"
>
<el-input <el-input
size="small" size="small"
oninput ="value=value.replace(/[^\d]/g,'')" oninput="value=value.replace(/[^\d]/g,'')"
v-model="merData.ext.idcard.number" v-model="merData.ext.idcard.number"
placeholder="请输入法人身份证" placeholder="请输入法人身份证"
class="selWidth" class="selWidth"
@ -265,8 +273,15 @@
<el-col :span="24"> <el-col :span="24">
<el-form-item label="店铺保证金:" label-width="146px"> <el-form-item label="店铺保证金:" label-width="146px">
<el-radio-group v-model="merData.is_margin"> <el-radio-group v-model="merData.is_margin">
<el-radio :disabled="merData.is_margin==10" :label="0" class="radio"></el-radio> <el-radio
<el-radio v-if="merData.is_margin!=10" :label="1"></el-radio> :disabled="merData.is_margin == 10"
:label="0"
class="radio"
></el-radio
>
<el-radio v-if="merData.is_margin != 10" :label="1"
></el-radio
>
<el-radio v-else :label="10"></el-radio> <el-radio v-else :label="10"></el-radio>
</el-radio-group> </el-radio-group>
<span v-if="merData.is_margin != 0"> <span v-if="merData.is_margin != 0">
@ -274,15 +289,16 @@
:disabled="true" :disabled="true"
v-model="merData.margin" v-model="merData.margin"
placeholder="请填写保证金" placeholder="请填写保证金"
style="width:120px;margin-left: 8px;" style="width: 120px; margin-left: 8px"
/> , />
,
</span> </span>
<span v-if="merData.is_margin != 0"> <span v-if="merData.is_margin != 0">
额度 额度
<el-input <el-input
v-model="merData.ot_margin" v-model="merData.ot_margin"
placeholder="请填写额度" placeholder="请填写额度"
style="width:120px;margin-left: 8px;" style="width: 120px; margin-left: 8px"
/> />
</span> </span>
</el-form-item> </el-form-item>
@ -290,8 +306,15 @@
<el-col :span="24"> <el-col :span="24">
<el-form-item label="技术服务费:" label-width="146px"> <el-form-item label="技术服务费:" label-width="146px">
<el-radio-group v-model="merData.is_service"> <el-radio-group v-model="merData.is_service">
<el-radio :disabled="merData.is_service==10" :label="0" class="radio"></el-radio> <el-radio
<el-radio v-if="merData.is_service!=10" :label="1"></el-radio> :disabled="merData.is_service == 10"
:label="0"
class="radio"
></el-radio
>
<el-radio v-if="merData.is_service != 10" :label="1"
></el-radio
>
<el-radio v-else :label="10"></el-radio> <el-radio v-else :label="10"></el-radio>
</el-radio-group> </el-radio-group>
<span v-if="merData.is_service != 0"> <span v-if="merData.is_service != 0">
@ -299,15 +322,16 @@
:disabled="true" :disabled="true"
v-model="merData.service_cost" v-model="merData.service_cost"
placeholder="请填写技术服务费" placeholder="请填写技术服务费"
style="width:120px;margin-left: 8px;" style="width: 120px; margin-left: 8px"
/> , />
,
</span> </span>
<span v-if="merData.is_service != 0"> <span v-if="merData.is_service != 0">
额度 额度
<el-input <el-input
v-model="merData.ot_service_cost" v-model="merData.ot_service_cost"
placeholder="请填写额度" placeholder="请填写额度"
style="width:120px;margin-left: 8px;" style="width: 120px; margin-left: 8px"
/> />
</span> </span>
</el-form-item> </el-form-item>
@ -315,8 +339,15 @@
<el-col :span="24"> <el-col :span="24">
<el-form-item label="上架费:" label-width="146px"> <el-form-item label="上架费:" label-width="146px">
<el-radio-group v-model="merData.is_goods"> <el-radio-group v-model="merData.is_goods">
<el-radio :disabled="merData.is_goods==10" :label="0" class="radio"></el-radio> <el-radio
<el-radio v-if="merData.is_goods!=10" :label="1"></el-radio> :disabled="merData.is_goods == 10"
:label="0"
class="radio"
></el-radio
>
<el-radio v-if="merData.is_goods != 10" :label="1"
></el-radio
>
<el-radio v-else :label="10"></el-radio> <el-radio v-else :label="10"></el-radio>
</el-radio-group> </el-radio-group>
<span v-if="merData.is_goods != 0"> <span v-if="merData.is_goods != 0">
@ -324,15 +355,16 @@
:disabled="true" :disabled="true"
v-model="merData.goods_cost" v-model="merData.goods_cost"
placeholder="请填写上架费" placeholder="请填写上架费"
style="width:120px;margin-left: 8px;" style="width: 120px; margin-left: 8px"
/> , />
,
</span> </span>
<span v-if="merData.is_goods != 0"> <span v-if="merData.is_goods != 0">
额度 额度
<el-input <el-input
v-model="merData.ot_goods_cost" v-model="merData.ot_goods_cost"
placeholder="请填写额度" placeholder="请填写额度"
style="width:120px;margin-left: 8px;" style="width: 120px; margin-left: 8px"
/> />
</span> </span>
</el-form-item> </el-form-item>
@ -342,7 +374,7 @@
<el-input <el-input
v-model="merData.exchange_limit" v-model="merData.exchange_limit"
placeholder="请填写额度" placeholder="请填写额度"
style="width:120px;margin-left: 8px;" style="width: 120px; margin-left: 8px"
/> />
</el-form-item> </el-form-item>
</el-col> </el-col>
@ -353,37 +385,57 @@
</el-col> --> </el-col> -->
</el-row> </el-row>
<el-row :gutter="24" class="mt20"> <el-row :gutter="24" class="mt20">
<el-col v-if="!isAdd":span="8"> <el-col v-if="!isAdd" :span="8">
<el-form-item label="保证金支付状态:"> <el-form-item label="保证金支付状态:">
<span>{{merData.is_margin != 0?merData.ot_margin-merData.margin>0 ? '待缴' : '已缴':'无' }}</span> <span>{{
merData.is_margin != 0
? merData.ot_margin - merData.margin > 0
? "待缴"
: "已缴"
: "无"
}}</span>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col v-if="!isAdd" :span="8"> <el-col v-if="!isAdd" :span="8">
<el-form-item label="技术服务费支付状态:" label-width="142px"> <el-form-item label="技术服务费支付状态:" label-width="142px">
<span>{{merData.is_service != 0?merData.ot_service_cost-merData.service_cost>0 ? '待缴' : '已缴':'无'}}</span> <span>{{
merData.is_service != 0
? merData.ot_service_cost - merData.service_cost > 0
? "待缴"
: "已缴"
: "无"
}}</span>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col v-if="!isAdd" :span="8"> <el-col v-if="!isAdd" :span="8">
<el-form-item label="上架费支付状态:"> <el-form-item label="上架费支付状态:">
<span>{{merData.is_goods != 0?merData.ot_goods_cost-merData.goods_cost>0 ? '待缴' : '已缴':'无'}}</span> <span>{{
merData.is_goods != 0
? merData.ot_goods_cost - merData.goods_cost > 0
? "待缴"
: "已缴"
: "无"
}}</span>
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-row> </el-row>
<el-row :gutter="24" class="mt20"> <el-row :gutter="24" class="mt20">
<el-col v-if="!isAdd" :span="8"> <el-col v-if="!isAdd" :span="8">
<el-form-item label="保证金应缴费用:"> <el-form-item label="保证金应缴费用:">
<span>{{merData.ot_margin-merData.margin}}</span> <span>{{ merData.ot_margin - merData.margin }}</span>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col v-if="!isAdd" :span="8"> <el-col v-if="!isAdd" :span="8">
<el-form-item label="技术服务费应缴费用:" label-width="150px"> <el-form-item label="技术服务费应缴费用:" label-width="150px">
<span>{{merData.ot_service_cost-merData.service_cost}}</span> <span>{{
merData.ot_service_cost - merData.service_cost
}}</span>
<!-- <span>{{merData.ot_service_cost-merData.service_cost}}</span> --> <!-- <span>{{merData.ot_service_cost-merData.service_cost}}</span> -->
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col v-if="!isAdd" :span="8"> <el-col v-if="!isAdd" :span="8">
<el-form-item label="上架费应缴费用:"> <el-form-item label="上架费应缴费用:">
<span>{{merData.ot_goods_cost-merData.goods_cost}}</span> <span>{{ merData.ot_goods_cost - merData.goods_cost }}</span>
<!-- <span>{{merData.ot_goods_cost-merData.goods_cost}}</span> --> <!-- <span>{{merData.ot_goods_cost-merData.goods_cost}}</span> -->
</el-form-item> </el-form-item>
</el-col> </el-col>
@ -525,7 +577,11 @@
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="12"> <el-col :span="12">
<el-form-item label="对接人身份证号:" prop="ext.com.number" v-if="merData.ext&&merData.ext.com"> <el-form-item
label="对接人身份证号:"
prop="ext.com.number"
v-if="merData.ext && merData.ext.com"
>
<el-input <el-input
size="small" size="small"
placeholder="请填写对接人身份证号" placeholder="请填写对接人身份证号"
@ -550,17 +606,17 @@
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="24"> <el-col :span="24">
<div class="info-red" style="margin-left: 120px;">当开启自动分账时每个子商户在微信后台的分账商户号即特约子商户号</div> <div class="info-red" style="margin-left: 120px">
当开启自动分账时每个子商户在微信后台的分账商户号即特约子商户号
</div>
</el-col> </el-col>
</el-row> </el-row>
</div> </div>
</el-tab-pane> </el-tab-pane>
</el-tabs> </el-tabs>
</el-form> </el-form>
</template> </template>
<script> <script>
import { merchantUpdate, merchantCreate } from "@/api/merchant"; import { merchantUpdate, merchantCreate } from "@/api/merchant";
export default { export default {
props: { props: {
@ -579,70 +635,93 @@ export default {
storeType: { storeType: {
type: Array, type: Array,
default: [], default: [],
} },
}, },
data() { data() {
const validatePhone = (rule, value, callback) => { const validatePhone = (rule, value, callback) => {
if (!value) { if (!value) {
return callback(new Error('请填写联系方式')) return callback(new Error("请填写联系方式"));
} else if (!/^1[3456789]\d{9}$/.test(value)) { } else if (!/^1[3456789]\d{9}$/.test(value)) {
callback(new Error('格式不正确!')) callback(new Error("格式不正确!"));
} else { } else {
callback() callback();
} }
};
var checkPhone = (rule, value, callback) => {
console.log(value);
if (!value) {
callback(new Error("请输入客服电话"));
} else {
let regPone = null;
const mobile = /^1(3|4|5|6|7|8|9)\d{9}$/; // 16
const tel = /^(0[0-9]{2,3}\-)([2-9][0-9]{4,7})+(\-[0-9]{1,4})?$/; //
const tels = /^400-[016789]\d{2}-\d{4}$/;
if (value.charAt(0) == 0) {
// charAt
regPone = tel;
} else if (value.charAt(0) == 4) {
regPone = tels;
} else {
regPone = mobile;
} }
if (!regPone.test(value)) {
return callback(
new Error(
"请填写客服电话(座机格式'区号-座机号码'),400格式400-XXX-XXXX"
)
);
}
callback();
}
};
return { return {
loading: false, loading: false,
merId: '', merId: "",
direction: 'rtl', direction: "rtl",
activeName: 'detail', activeName: "detail",
ruleValidate: { ruleValidate: {
mer_name: [ mer_name: [
{ required: true, message: '请输入店铺名称', trigger: 'change' } { required: true, message: "请输入店铺名称", trigger: "change" },
], ],
'ext.com.contact': [ "ext.com.contact": [
{ required: true, message: '请输入企业名称', trigger: 'blur' } { required: true, message: "请输入企业名称", trigger: "blur" },
], ],
mer_account: [ mer_account: [
{ required: true, message: '请输入商户账号', trigger: 'blur' } { required: true, message: "请输入商户账号", trigger: "blur" },
], ],
category_id: [ category_id: [
{ required: true, message: '请选择商户分类', trigger: 'change' } { required: true, message: "请选择商户分类", trigger: "change" },
], ],
type_id: [ type_id: [
{ required: true, message: '请选择店铺类型', trigger: 'change' } { required: true, message: "请选择店铺类型", trigger: "change" },
], ],
mer_phone: [{ required: true, validator: validatePhone, trigger: 'blur' }], mer_phone: [{ required: true, validator: checkPhone, trigger: "blur" }],
}, },
}; };
}, },
filters: { filters: {},
}, mounted() {},
mounted() {
},
methods: { methods: {
/**修改采集次数 */ /**修改采集次数 */
modifyCopy() { modifyCopy() {
this.$emit('modifyCopy') this.$emit("modifyCopy");
}, },
/**重置表单数据 */ /**重置表单数据 */
resetData(){ resetData() {
this.$refs.merDataField.resetFields(); this.$refs.merDataField.resetFields();
}, },
/*提交信息*/ /*提交信息*/
onSubmit(id){ onSubmit(id) {
this.$refs['merDataField'].validate(valid => { this.$refs["merDataField"].validate((valid) => {
if (valid) { if (valid) {
this.loading = true; this.loading = true;
merchantUpdate(id,this.merData) merchantUpdate(id, this.merData)
.then(async res => { .then(async (res) => {
this.$message.success(res.message); this.$message.success(res.message);
this.loading = false; this.loading = false;
this.$emit('success'); this.$emit("success");
}) })
.catch(res => { .catch((res) => {
this.loading = false; this.loading = false;
this.$message.error(res.message); this.$message.error(res.message);
}); });
@ -650,26 +729,29 @@ export default {
}); });
}, },
/**创建商户 */ /**创建商户 */
handleCreate(){ handleCreate() {
this.$refs['merDataField'].validate((valid) => { this.$refs["merDataField"].validate((valid) => {
if (valid) { if (valid) {
merchantCreate(this.merData) merchantCreate(this.merData)
.then(async (res) => { .then(async (res) => {
this.$message.success(res.message); this.$message.success(res.message);
this.$emit('success'); this.$emit("success");
}) })
.catch((res) => { .catch((res) => {
this.$message.error(res.message); this.$message.error(res.message);
}); });
} else { } else {
if(!this.merData.mer_name)return this.$message.error('请填写基本信息-商户名称'); if (!this.merData.mer_name)
return this.$message.error("请填写基本信息-商户名称");
// if(!this.merData.category_id)return this.$message.error('-'); // if(!this.merData.category_id)return this.$message.error('-');
if(!this.merData.type_id)return this.$message.error('请选择基本信息-店铺类型'); if (!this.merData.type_id)
if(!this.merData.mer_account)return this.$message.error('请填写账号信息-商户账号'); return this.$message.error("请选择基本信息-店铺类型");
if (!this.merData.mer_account)
return this.$message.error("请填写账号信息-商户账号");
// if(!this.merData.mer_phone)return this.$message.error('-'); // if(!this.merData.mer_phone)return this.$message.error('-');
} }
}); });
} },
}, },
}; };
</script> </script>
@ -720,14 +802,14 @@ export default {
} }
} }
} }
.info-red{ .info-red {
color: red; color: red;
font-size: 12px; font-size: 12px;
} }
::v-deep .el-input-number.is-controls-right .el-input__inner{ ::v-deep .el-input-number.is-controls-right .el-input__inner {
padding: 0 40px 0 10px; padding: 0 40px 0 10px;
} }
::v-deep .el-form-item__label{ ::v-deep .el-form-item__label {
font-weight: normal; font-weight: normal;
color: #282828; color: #282828;
} }
@ -746,6 +828,4 @@ export default {
.gary { .gary {
color: #aaa; color: #aaa;
} }
</style> </style>

View File

@ -274,7 +274,12 @@
/> />
</template> </template>
</el-table-column> </el-table-column>
<el-table-column prop="lock" label="限制(开启/关闭)" min-width="120" v-if="isStatus!=0"> <el-table-column
prop="lock"
label="限制(开启/关闭)"
min-width="120"
v-if="isStatus != 0"
>
<template slot-scope="scope"> <template slot-scope="scope">
<el-switch <el-switch
v-model="scope.row.lock" v-model="scope.row.lock"
@ -324,14 +329,14 @@
<el-table-column label="操作" min-width="220" fixed="right"> <el-table-column label="操作" min-width="220" fixed="right">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button <el-button
v-if="isStatus=== '1' || isStatus=== '2' " v-if="isStatus === '1' || isStatus === '2'"
type="text" type="text"
size="small" size="small"
@click="onLogo(scope.row.mer_id)" @click="onLogo(scope.row.mer_id)"
>登录</el-button >登录</el-button
> >
<el-button <el-button
v-if="isStatus=== '1'" v-if="isStatus === '1'"
type="text" type="text"
size="small" size="small"
@click="handleSign(scope.row.mer_id)" @click="handleSign(scope.row.mer_id)"
@ -408,7 +413,7 @@ import {
exportMerchantApi, exportMerchantApi,
getMerCateApi, getMerCateApi,
marginDeductionForm, marginDeductionForm,
merchantContactApi merchantContactApi,
} from "@/api/merchant"; } from "@/api/merchant";
import merDetail from "./handle/merDetails.vue"; import merDetail from "./handle/merDetails.vue";
import { fromList } from "@/libs/constants.js"; import { fromList } from "@/libs/constants.js";
@ -461,15 +466,15 @@ export default {
is_trader: "", is_trader: "",
is_best: "", is_best: "",
category_id: "", category_id: "",
is_sign:'', is_sign: "",
type_id: "", type_id: "",
city: "", city: "",
phone:'', phone: "",
name:'', name: "",
mark:'', mark: "",
is_new:'' is_new: "",
}, },
isStatus:'1', isStatus: "1",
autoUpdate: true, autoUpdate: true,
merId: "", merId: "",
drawer: false, drawer: false,
@ -506,7 +511,7 @@ export default {
let excelData = JSON.parse(JSON.stringify(this.tableFrom)), let excelData = JSON.parse(JSON.stringify(this.tableFrom)),
data = []; data = [];
excelData.page = 1; excelData.page = 1;
excelData.limit = 100 excelData.limit = 100;
let pageCount = 1; let pageCount = 1;
let lebData = {}; let lebData = {};
for (let i = 0; i < pageCount; i++) { for (let i = 0; i < pageCount; i++) {
@ -546,7 +551,7 @@ export default {
merchantContactApi(id) merchantContactApi(id)
.then((res) => { .then((res) => {
this.$message.success(res.message); this.$message.success(res.message);
window.open(res.message) window.open(res.message);
}) })
.catch((res) => { .catch((res) => {
this.$message.error(res.message); this.$message.error(res.message);
@ -601,10 +606,14 @@ export default {
// //
getList(num) { getList(num) {
this.listLoading = true; this.listLoading = true;
if(this.isStatus==2){ if (this.isStatus == 2) {
this.tableFrom = {...this.tableFrom,lock:'1',status:''} this.tableFrom = { ...this.tableFrom, lock: "1", status: "" };
}else{ } else {
this.tableFrom = {...this.tableFrom,status:this.isStatus,lock:'0'} this.tableFrom = {
...this.tableFrom,
status: this.isStatus,
lock: "0",
};
} }
this.tableFrom.page = num ? num : this.tableFrom.page; this.tableFrom.page = num ? num : this.tableFrom.page;
merchantListApi(this.tableFrom) merchantListApi(this.tableFrom)

View File

@ -1,31 +1,73 @@
<template> <template>
<div class="divBox"> <div class="divBox">
<div class="selCard mb14"> <div class="selCard mb14">
<el-form size="small" inline :model="tableFrom" ref="searchForm" label-width="85px"> <el-form
size="small"
inline
:model="tableFrom"
ref="searchForm"
label-width="85px"
>
<el-form-item label="订单状态:" class="width100" prop="status"> <el-form-item label="订单状态:" class="width100" prop="status">
<el-radio-group v-model="tableFrom.status" type="button" @change="getList(1),getCardList()"> <el-radio-group
<el-radio-button label="">全部 {{ '(' +orderChartType.all?orderChartType.all:0 + ')' }}</el-radio-button> v-model="tableFrom.status"
<el-radio-button type="button"
label="1" @change="getList(1), getCardList()"
>待付款 {{ '(' +orderChartType.unpaid?orderChartType.unpaid:0+ ')' }}</el-radio-button> >
<el-radio-button <el-radio-button label=""
label="2" >全部
>待发货 {{ '(' +orderChartType.unshipped?orderChartType.unshipped:0+ ')' }}</el-radio-button> {{
<el-radio-button "(" + orderChartType.all ? orderChartType.all : 0 + ")"
label="3" }}</el-radio-button
>待收货 {{ '(' +orderChartType.untake?orderChartType.untake:0+ ')' }}</el-radio-button> >
<el-radio-button <el-radio-button label="1"
label="4" >待付款
>待评价 {{ '(' +orderChartType.unevaluate?orderChartType.unevaluate:0+ ')' }}</el-radio-button> {{
<el-radio-button "(" + orderChartType.unpaid ? orderChartType.unpaid : 0 + ")"
label="5" }}</el-radio-button
>交易完成 {{ '(' +orderChartType.complete?orderChartType.complete:0+ ')' }}</el-radio-button> >
<el-radio-button <el-radio-button label="2"
label="6" >待发货
>已退款 {{ '(' +orderChartType.refund?orderChartType.refund:0+ ')' }}</el-radio-button> {{
<el-radio-button "(" + orderChartType.unshipped
label="7" ? orderChartType.unshipped
>已删除 {{ '(' +orderChartType.del?orderChartType.del:0+ ')' }}</el-radio-button> : 0 + ")"
}}</el-radio-button
>
<el-radio-button label="3"
>待收货
{{
"(" + orderChartType.untake ? orderChartType.untake : 0 + ")"
}}</el-radio-button
>
<el-radio-button label="4"
>待评价
{{
"(" + orderChartType.unevaluate
? orderChartType.unevaluate
: 0 + ")"
}}</el-radio-button
>
<el-radio-button label="5"
>交易完成
{{
"(" + orderChartType.complete
? orderChartType.complete
: 0 + ")"
}}</el-radio-button
>
<el-radio-button label="6"
>已退款
{{
"(" + orderChartType.refund ? orderChartType.refund : 0 + ")"
}}</el-radio-button
>
<el-radio-button label="7"
>已删除
{{
"(" + orderChartType.del ? orderChartType.del : 0 + ")"
}}</el-radio-button
>
</el-radio-group> </el-radio-group>
</el-form-item> </el-form-item>
<el-form-item label="时间选择:"> <el-form-item label="时间选择:">
@ -37,7 +79,7 @@
type="datetimerange" type="datetimerange"
placement="bottom-end" placement="bottom-end"
placeholder="自定义时间" placeholder="自定义时间"
style="width: 280px;" style="width: 280px"
:picker-options="pickerOptions" :picker-options="pickerOptions"
@change="onchangeTime" @change="onchangeTime"
/> />
@ -51,7 +93,7 @@
type="datetimerange" type="datetimerange"
placement="bottom-end" placement="bottom-end"
placeholder="自定义时间" placeholder="自定义时间"
style="width: 280px;" style="width: 280px"
:picker-options="pickerOptions" :picker-options="pickerOptions"
@change="onchangeFinishTime" @change="onchangeFinishTime"
/> />
@ -63,7 +105,7 @@
filterable filterable
placeholder="请选择" placeholder="请选择"
class="selWidth" class="selWidth"
@change="getList(1),getCardList()" @change="getList(1), getCardList()"
> >
<el-option <el-option
v-for="item in activity" v-for="item in activity"
@ -80,7 +122,7 @@
filterable filterable
placeholder="请选择" placeholder="请选择"
class="selWidth" class="selWidth"
@change="getList(1),getCardList()" @change="getList(1), getCardList()"
> >
<el-option <el-option
v-for="item in merSelect" v-for="item in merSelect"
@ -96,7 +138,7 @@
clearable clearable
placeholder="请选择" placeholder="请选择"
class="selWidth" class="selWidth"
@change="getList(1),getCardList()" @change="getList(1), getCardList()"
> >
<el-option label="自营" value="1" /> <el-option label="自营" value="1" />
<el-option label="非自营" value="0" /> <el-option label="非自营" value="0" />
@ -105,7 +147,7 @@
<el-form-item label="商品名称:" prop="store_name"> <el-form-item label="商品名称:" prop="store_name">
<el-input <el-input
v-model="tableFrom.store_name" v-model="tableFrom.store_name"
@keyup.enter.native="getList(1),getCardList()" @keyup.enter.native="getList(1), getCardList()"
placeholder="请输入商品名称" placeholder="请输入商品名称"
class="selWidth" class="selWidth"
clearable clearable
@ -117,7 +159,7 @@
clearable clearable
placeholder="请选择" placeholder="请选择"
class="selWidth" class="selWidth"
@change="getList(1),getCardList()" @change="getList(1), getCardList()"
> >
<el-option label="银联扫码" value="13" /> <el-option label="银联扫码" value="13" />
<!-- <el-option label="微信" value="1" /> --> <!-- <el-option label="微信" value="1" /> -->
@ -162,7 +204,7 @@
<el-form-item label="关键字:" prop="keywords"> <el-form-item label="关键字:" prop="keywords">
<el-input <el-input
v-model="tableFrom.keywords" v-model="tableFrom.keywords"
@keyup.enter.native="getList(1),getCardList()" @keyup.enter.native="getList(1), getCardList()"
placeholder="请输入订单号/收货人/联系方式/ID/商品编号" placeholder="请输入订单号/收货人/联系方式/ID/商品编号"
class="selWidth" class="selWidth"
clearable clearable
@ -171,7 +213,7 @@
<el-form-item label="总单单号:" prop="group_order_sn"> <el-form-item label="总单单号:" prop="group_order_sn">
<el-input <el-input
v-model="tableFrom.group_order_sn" v-model="tableFrom.group_order_sn"
@keyup.enter.native="getList(1),getCardList()" @keyup.enter.native="getList(1), getCardList()"
placeholder="请输入总单单号" placeholder="请输入总单单号"
class="selWidth" class="selWidth"
clearable clearable
@ -180,7 +222,7 @@
<el-form-item label="用户信息:" prop="username"> <el-form-item label="用户信息:" prop="username">
<el-input <el-input
v-model="tableFrom.username" v-model="tableFrom.username"
@keyup.enter.native="getList(1),getCardList()" @keyup.enter.native="getList(1), getCardList()"
placeholder="请输入用户昵称/手机号" placeholder="请输入用户昵称/手机号"
class="selWidth" class="selWidth"
clearable clearable
@ -189,7 +231,7 @@
<el-form-item label="商品ID" prop="product_id"> <el-form-item label="商品ID" prop="product_id">
<el-input <el-input
v-model="tableFrom.product_id" v-model="tableFrom.product_id"
@keyup.enter.native="getList(1),getCardList()" @keyup.enter.native="getList(1), getCardList()"
placeholder="请输入商品ID" placeholder="请输入商品ID"
class="selWidth" class="selWidth"
clearable clearable
@ -216,15 +258,31 @@
<el-option label="否" value="0" /> <el-option label="否" value="0" />
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item label="定制产品:" prop="is_customize">
<el-select
v-model="tableFrom.is_customize"
clearable
placeholder="请选择"
class="selWidth"
@change="getList(1)"
>
<el-option label="是" value="1" />
<el-option label="否" value="0" />
</el-select>
</el-form-item>
<el-form-item> <el-form-item>
<el-button type="primary" size="small" @click="getList(1)">搜索</el-button> <el-button type="primary" size="small" @click="getList(1)"
>搜索</el-button
>
<el-button size="small" @click="searchReset()">重置</el-button> <el-button size="small" @click="searchReset()">重置</el-button>
</el-form-item> </el-form-item>
</el-form> </el-form>
</div> </div>
<cards-data v-if="cardLists.length>0" :card-lists="cardLists" /> <cards-data v-if="cardLists.length > 0" :card-lists="cardLists" />
<el-card> <el-card>
<el-button size="small" type="primary" class="mb20" @click="exports">导出列表</el-button> <el-button size="small" type="primary" class="mb20" @click="exports"
>导出列表</el-button
>
<el-table <el-table
v-loading="listLoading" v-loading="listLoading"
:data="tableData.data" :data="tableData.data"
@ -250,20 +308,35 @@
<span>{{ props.row.remark | filterEmpty }}</span> <span>{{ props.row.remark | filterEmpty }}</span>
</el-form-item> </el-form-item>
<el-form-item label="总单号:"> <el-form-item label="总单号:">
<span>{{ props.row.groupOrder ? props.row.groupOrder.group_order_sn : '' }}</span> <span>{{
props.row.groupOrder
? props.row.groupOrder.group_order_sn
: ""
}}</span>
</el-form-item> </el-form-item>
</el-form> </el-form>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="订单编号" min-width="150"> <el-table-column label="订单编号" min-width="150">
<template slot-scope="scope"> <template slot-scope="scope">
<span style="display: block;" v-text="scope.row.order_sn" /> <span style="display: block" v-text="scope.row.order_sn" />
<span v-show="scope.row.is_del > 0" style="color: #ED4014;display: block;">用户已删除</span> <span
v-show="scope.row.is_del > 0"
style="color: #ed4014; display: block"
>用户已删除</span
>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="用户信息" min-width="130"> <el-table-column label="用户信息" min-width="130">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button type="text" size="small" @click.native="onUserDetails(scope.row.uid)">{{scope.row.user&&scope.row.user.nickname +'/'+ scope.row.uid}}</el-button> <el-button
type="text"
size="small"
@click.native="onUserDetails(scope.row.uid)"
>{{
scope.row.user && scope.row.user.nickname + "/" + scope.row.uid
}}</el-button
>
</template> </template>
</el-table-column> </el-table-column>
<!-- <el-table-column label="订单类型" min-width="80"> <!-- <el-table-column label="订单类型" min-width="80">
@ -271,10 +344,16 @@
<span>{{ scope.row.is_virtual == 1 ? "虚拟订单" : scope.row.order_type == 0 ? "普通订单" : "核销订单" }}</span> <span>{{ scope.row.is_virtual == 1 ? "虚拟订单" : scope.row.order_type == 0 ? "普通订单" : "核销订单" }}</span>
</template> </template>
</el-table-column> --> </el-table-column> -->
<el-table-column prop="real_name" label="收货人/订购人" min-width="120" /> <el-table-column
prop="real_name"
label="收货人/订购人"
min-width="120"
/>
<el-table-column label="商户名称" min-width="100"> <el-table-column label="商户名称" min-width="100">
<template slot-scope="scope"> <template slot-scope="scope">
<span>{{ scope.row.merchant ? scope.row.merchant.mer_name :'' }}</span> <span>{{
scope.row.merchant ? scope.row.merchant.mer_name : ""
}}</span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="商品信息" min-width="330"> <el-table-column label="商品信息" min-width="330">
@ -290,28 +369,55 @@
:preview-src-list="[val.cart_info.product.image]" :preview-src-list="[val.cart_info.product.image]"
/> />
</div> </div>
<span <span class="tabBox_tit"
class="tabBox_tit" >{{ val.cart_info.product.store_name + " | "
>{{ val.cart_info.product.store_name + ' | ' }}{{ val.cart_info.productAttr.sku }}</span> }}{{ val.cart_info.productAttr.sku }}</span
>
<span class="tabBox_pice"> <span class="tabBox_pice">
{{ '¥'+ val.cart_info.productAttr.price + ' x '+ val.product_num }} {{
"¥" +
val.cart_info.productAttr.price +
" x " +
val.product_num
}}
<em <em
v-if="val.refund_num < val.product_num && val.refund_num > 0" v-if="val.refund_num < val.product_num && val.refund_num > 0"
style="color: red;font-style: normal;" style="color: red; font-style: normal"
>(-{{ val.product_num - val.refund_num }})</em> >(-{{ val.product_num - val.refund_num }})</em
>
</span> </span>
</div> </div>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column
class-name="customize"
prop="is_customize"
label="定制产品"
min-width="100"
>
<template slot-scope="scope">
<div
v-for="(val, i) in scope.row.orderProduct"
:key="i"
class="tabBox acea-row row-middle"
>
{{ val.product.is_customize ? "是" : "否" }}
</div>
</template>
</el-table-column>
<el-table-column label="实际支付" min-width="90"> <el-table-column label="实际支付" min-width="90">
<template slot-scope="scope"> <template slot-scope="scope">
<span>{{ scope.row.pay_price }}</span> <span>{{ scope.row.pay_price }}</span>
<p v-if="scope.row.finalOrder">尾款{{ scope.row.finalOrder.pay_price }}</p> <p v-if="scope.row.finalOrder">
尾款{{ scope.row.finalOrder.pay_price }}
</p>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="支付方式" min-width="80"> <el-table-column label="支付方式" min-width="80">
<template slot-scope="scope"> <template slot-scope="scope">
<span v-if="scope.row.paid === 1">{{ scope.row.pay_type | orderPayType }}</span> <span v-if="scope.row.paid === 1">{{
scope.row.pay_type | orderPayType
}}</span>
<span v-else>--</span> <span v-else>--</span>
</template> </template>
</el-table-column> </el-table-column>
@ -325,8 +431,15 @@
<span v-if="scope.row.is_del === 0"> <span v-if="scope.row.is_del === 0">
<span v-if="scope.row.paid === 0">待付款</span> <span v-if="scope.row.paid === 0">待付款</span>
<span v-else> <span v-else>
<span v-if="scope.row.order_type === 0 || scope.row.order_type === 2">{{ scope.row.status | orderStatusFilter }}</span> <span
<span v-else>{{ scope.row.status | cancelOrderStatusFilter }}</span> v-if="
scope.row.order_type === 0 || scope.row.order_type === 2
"
>{{ scope.row.status | orderStatusFilter }}</span
>
<span v-else>{{
scope.row.status | cancelOrderStatusFilter
}}</span>
</span> </span>
</span> </span>
<span v-else>已删除</span> <span v-else>已删除</span>
@ -337,19 +450,36 @@
<span>{{ scope.row.create_time }}</span> <span>{{ scope.row.create_time }}</span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column width="100px" label="操作" min-width="80" fixed="right" align="center"> <el-table-column
width="100px"
label="操作"
min-width="80"
fixed="right"
align="center"
>
<template slot-scope="scope"> <template slot-scope="scope">
<span v-for="(val, i ) in scope.row.orderProduct" :key="i"> <span v-for="(val, i) in scope.row.orderProduct" :key="i">
<el-button <el-button
v-if="orderFilter(scope.row)" v-if="orderFilter(scope.row)"
type="text" type="text"
size="small" size="small"
@click="onRefundDetail(scope.row.order_sn)" @click="onRefundDetail(scope.row.order_sn)"
>查看退款单</el-button> >查看退款单</el-button
>
</span> </span>
<el-button type="text" size="small" @click="onOrderDetails(scope.row.order_id)">详情</el-button> <el-button
type="text"
size="small"
@click="onOrderDetails(scope.row.order_id)"
>详情</el-button
>
<!-- <el-button type="text" size="small" @click="onOrderOpenRefund(scope.row.order_id)">开启退款</el-button> --> <!-- <el-button type="text" size="small" @click="onOrderOpenRefund(scope.row.order_id)">开启退款</el-button> -->
<el-button type="text" size="small" @click="onOrderOpen(scope.row.order_id)">开启强制退款</el-button> <el-button
type="text"
size="small"
@click="onOrderOpen(scope.row.order_id)"
>开启强制退款</el-button
>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
@ -372,7 +502,8 @@
@closeDrawer="closeDrawer" @closeDrawer="closeDrawer"
@changeDrawer="changeDrawer" @changeDrawer="changeDrawer"
:uid="uid" :uid="uid"
:isUser="false" /> :isUser="false"
/>
<!--详情--> <!--详情-->
<order-detail <order-detail
ref="orderDetail" ref="orderDetail"
@ -385,16 +516,22 @@
</template> </template>
<script> <script>
import {
import { refundorderOpenApi,orderListApi, chartApi, cardListApi, exportOrderApi,openRefundApi } from "@/api/order"; refundorderOpenApi,
orderListApi,
chartApi,
cardListApi,
exportOrderApi,
openRefundApi,
} from "@/api/order";
import { merSelectApi } from "@/api/product"; import { merSelectApi } from "@/api/product";
import userDetails from '../../user/list/userDetails'; import userDetails from "../../user/list/userDetails";
import orderDetail from './orderDetails.vue'; import orderDetail from "./orderDetails.vue";
import createWorkBook from '@/utils/newToExcel.js'; import createWorkBook from "@/utils/newToExcel.js";
import cardsData from "@/components/cards/index"; import cardsData from "@/components/cards/index";
import { fromList } from "@/libs/constants.js"; import { fromList } from "@/libs/constants.js";
import timeOptions from '@/utils/timeOptions'; import timeOptions from "@/utils/timeOptions";
import * as FileSaver from 'file-saver' import * as FileSaver from "file-saver";
import Worker from "worker-loader!@/worker/calcWorker.js"; import Worker from "worker-loader!@/worker/calcWorker.js";
export default { export default {
components: { orderDetail, cardsData, userDetails }, components: { orderDetail, cardsData, userDetails },
@ -407,45 +544,46 @@ export default {
total: 0, total: 0,
}, },
activity: [ activity: [
{name: "普通订单",type: 0}, { name: "普通订单", type: 0 },
// {name: "",type: 1}, // {name: "",type: 1},
{name: "预售订单",type: 2}, { name: "预售订单", type: 2 },
// {name: "",type: 3}, // {name: "",type: 3},
// {name: "",type: 4} // {name: "",type: 4}
], ],
listLoading: true, listLoading: true,
tableFrom: { tableFrom: {
order_sn: this.$route.query.order_sn ? this.$route.query.order_sn : "", order_sn: this.$route.query.order_sn ? this.$route.query.order_sn : "",
group_order_sn: '', group_order_sn: "",
keywords: "", keywords: "",
paid:'', paid: "1",
username: "", username: "",
store_name: "", store_name: "",
status: this.$route.query.status || '', status: this.$route.query.status || "",
date: "", date: "",
mer_id: "", mer_id: "",
page: 1, page: 1,
limit: 20, limit: 20,
is_trader: '', is_trader: "",
is_customize: "",
pay_type: "", pay_type: "",
filter_delivery: '', filter_delivery: "",
filter_product : '', filter_product: "",
activity_type: '', activity_type: "",
product_id:'', product_id: "",
bar_code:'', bar_code: "",
finish_time:'' finish_time: "",
}, },
dliveryWayList: [ dliveryWayList: [
{ value: 1, label: '快递订单' }, { value: 1, label: "快递订单" },
{ value: 2, label: '配送订单' }, { value: 2, label: "配送订单" },
{ value: 4, label: '核销订单' }, { value: 4, label: "核销订单" },
{ value: 3, label: '虚拟发货' }, { value: 3, label: "虚拟发货" },
{ value: 6, label: '自动发货' } { value: 6, label: "自动发货" },
], // ], //
productTypeList: [ productTypeList: [
{ value: 1, label: '实物商品' }, { value: 1, label: "实物商品" },
{ value: 2, label: '虚拟商品' }, { value: 2, label: "虚拟商品" },
{ value: 3, label: '卡密商品' } { value: 3, label: "卡密商品" },
], // ], //
orderChartType: {}, orderChartType: {},
timeVal: [], timeVal: [],
@ -480,8 +618,8 @@ export default {
} }
this.headerList(); this.headerList();
this.getMerSelect(); this.getMerSelect();
this.getCardList() this.getCardList();
this.getList(''); this.getList("");
}, },
// //
activated() { activated() {
@ -492,18 +630,18 @@ export default {
} }
this.headerList(); this.headerList();
this.getMerSelect(); this.getMerSelect();
this.getCardList() this.getCardList();
this.getList(''); this.getList("");
}, },
methods: { methods: {
/**重置 */ /**重置 */
searchReset(){ searchReset() {
this.timeVal = [] this.timeVal = [];
this.finishTime = [] this.finishTime = [];
this.tableFrom.date = "" this.tableFrom.date = "";
this.tableFrom.finish_time = "" this.tableFrom.finish_time = "";
this.$refs.searchForm.resetFields() this.$refs.searchForm.resetFields();
this.getList(1) this.getList(1);
}, },
// 退 // 退
onRefundDetail(sn) { onRefundDetail(sn) {
@ -529,7 +667,11 @@ export default {
addTdClass(val) { addTdClass(val) {
if (val.row.status > 0 && val.row.paid == 1) { if (val.row.status > 0 && val.row.paid == 1) {
for (let i = 0; i < val.row.orderProduct.length; i++) { for (let i = 0; i < val.row.orderProduct.length; i++) {
if (val.row.orderProduct[i].refund_num > 0 && val.row.orderProduct[i].refund_num < val.row.orderProduct[i].product_num) { if (
val.row.orderProduct[i].refund_num > 0 &&
val.row.orderProduct[i].refund_num <
val.row.orderProduct[i].product_num
) {
return "row-bg"; return "row-bg";
} }
} }
@ -549,13 +691,13 @@ export default {
}, },
// //
onUserDetails(uid) { onUserDetails(uid) {
this.uid = uid this.uid = uid;
this.userDawer = true this.userDawer = true;
this.$refs.userDetails.getData(uid,false,true); this.$refs.userDetails.getData(uid, false, true);
}, },
closeDrawer() { closeDrawer() {
this.drawer = false this.drawer = false;
this.userDawer = false this.userDawer = false;
}, },
changeDrawer(v) { changeDrawer(v) {
this.drawer = v; this.drawer = v;
@ -586,43 +728,44 @@ export default {
async exports() { async exports() {
const loading = this.$loading({ const loading = this.$loading({
lock: true, lock: true,
text: '导出中...', text: "导出中...",
spinner: 'el-icon-loading', spinner: "el-icon-loading",
background: 'hsla(0, 0%, 100%, .9)' background: "hsla(0, 0%, 100%, .9)",
}); });
let excelData = JSON.parse(JSON.stringify(this.tableFrom)), data = [] let excelData = JSON.parse(JSON.stringify(this.tableFrom)),
excelData.page = 1 data = [];
excelData.limit = 200 excelData.page = 1;
let pageCount = 1 excelData.limit = 200;
let pageCount = 1;
let lebData = {}; let lebData = {};
// let work; // let work;
for (let i = 0; i < pageCount; i++) { for (let i = 0; i < pageCount; i++) {
lebData = await this.downData(excelData) lebData = await this.downData(excelData);
// if(work){ // if(work){
// work.setContent(lebData.export) // work.setContent(lebData.export)
// }else{ // }else{
// work = createWorkBook(lebData.header, lebData.title, data, lebData.foot,lebData.filename); // work = createWorkBook(lebData.header, lebData.title, data, lebData.foot,lebData.filename);
// } // }
// //
pageCount = Math.ceil(lebData.count/excelData.limit) pageCount = Math.ceil(lebData.count / excelData.limit);
// //
if (lebData.export.length) { if (lebData.export.length) {
data = data.concat(lebData.export) data = data.concat(lebData.export);
excelData.page++ excelData.page++;
} }
} }
console.log('开始处理'); console.log("开始处理");
// //
let start = performance.now(); let start = performance.now();
// 线 // 线
let worker = new Worker(); let worker = new Worker();
// 线postMessage // 线postMessage
worker.postMessage({ worker.postMessage({
header:lebData.header, header: lebData.header,
title: lebData.title, title: lebData.title,
data, data,
foot: lebData.foot, foot: lebData.foot,
filename:lebData.filename filename: lebData.filename,
}); });
// message // message
worker.addEventListener("message", (e) => { worker.addEventListener("message", (e) => {
@ -633,24 +776,24 @@ export default {
// //
let durationTime = end - start; let durationTime = end - start;
console.log('计算结果:', e.data); console.log("计算结果:", e.data);
let { blob, filename } = e.data let { blob, filename } = e.data;
FileSaver.saveAs(blob, filename + '.xlsx') FileSaver.saveAs(blob, filename + ".xlsx");
loading.close(); loading.close();
console.log(`代码执行了 ${durationTime} 毫秒`); console.log(`代码执行了 ${durationTime} 毫秒`);
}); });
// this.exportCsv(lebData.header,data,lebData.filename) // this.exportCsv(lebData.header,data,lebData.filename)
// createWorkBook(lebData.header, lebData.title, data, lebData.foot,lebData.filename) // createWorkBook(lebData.header, lebData.title, data, lebData.foot,lebData.filename)
// work.saveAndDowloade(lebData.filename) // work.saveAndDowloade(lebData.filename)
return return;
}, },
/**订单列表 */ /**订单列表 */
downData(excelData) { downData(excelData) {
return new Promise((resolve, reject) => { return new Promise((resolve, reject) => {
exportOrderApi(excelData).then((res) => { exportOrderApi(excelData).then((res) => {
return resolve(res.data) return resolve(res.data);
}) });
}) });
}, },
// //
exportRecord() { exportRecord() {
@ -658,20 +801,18 @@ export default {
.then((res) => { .then((res) => {
const h = this.$createElement; const h = this.$createElement;
this.$msgbox({ this.$msgbox({
title: '提示', title: "提示",
message: h('p', null, [ message: h("p", null, [
h('span', null, '文件正在生成中,请稍后点击"'), h("span", null, '文件正在生成中,请稍后点击"'),
h('span', { style: 'color: teal' }, '导出记录'), h("span", { style: "color: teal" }, "导出记录"),
h('span', null, '"查看~ '), h("span", null, '"查看~ '),
]), ]),
confirmButtonText: '我知道了', confirmButtonText: "我知道了",
}).then(action => { }).then((action) => {});
});
}) })
.catch((res) => { .catch((res) => {
this.$message.error(res.message) this.$message.error(res.message);
}) });
}, },
// //
onOrderDetails(id) { onOrderDetails(id) {
@ -683,7 +824,7 @@ export default {
}, },
// 退 // 退
onOrderOpen(id) { onOrderOpen(id) {
this.$modalForm(refundorderOpenApi(id)).then(() => this.getList('')) this.$modalForm(refundorderOpenApi(id)).then(() => this.getList(""));
}, },
// 退 // 退
// onOrderOpenRefund(id) { // onOrderOpenRefund(id) {
@ -711,11 +852,11 @@ export default {
// }, // },
pageChangeLog(page) { pageChangeLog(page) {
this.tableFromLog.page = page; this.tableFromLog.page = page;
this.getList(''); this.getList("");
}, },
handleSizeChangeLog(val) { handleSizeChangeLog(val) {
this.tableFromLog.limit = val; this.tableFromLog.limit = val;
this.getList(''); this.getList("");
}, },
// //
onchangeTime(e) { onchangeTime(e) {
@ -723,7 +864,7 @@ export default {
console.log(e); console.log(e);
this.tableFrom.date = e ? this.timeVal.join("-") : ""; this.tableFrom.date = e ? this.timeVal.join("-") : "";
this.tableFrom.page = 1; this.tableFrom.page = 1;
this.getCardList() this.getCardList();
this.getList(1); this.getList(1);
}, },
// //
@ -731,7 +872,7 @@ export default {
this.finishTime = e; this.finishTime = e;
this.tableFrom.finish_time = e ? this.finishTime.join("-") : ""; this.tableFrom.finish_time = e ? this.finishTime.join("-") : "";
this.tableFrom.page = 1; this.tableFrom.page = 1;
this.getCardList() this.getCardList();
this.getList(1); this.getList(1);
}, },
// //
@ -751,7 +892,7 @@ export default {
this.listLoading = false; this.listLoading = false;
}); });
}, },
getCardList(){ getCardList() {
cardListApi(this.tableFrom) cardListApi(this.tableFrom)
.then((res) => { .then((res) => {
this.cardLists = res.data; this.cardLists = res.data;
@ -762,11 +903,11 @@ export default {
}, },
pageChange(page) { pageChange(page) {
this.tableFrom.page = page; this.tableFrom.page = page;
this.getList(''); this.getList("");
}, },
handleSizeChange(val) { handleSizeChange(val) {
this.tableFrom.limit = val; this.tableFrom.limit = val;
this.getList(''); this.getList("");
}, },
headerList() { headerList() {
chartApi() chartApi()

View File

@ -240,6 +240,19 @@
class="selWidth" class="selWidth"
/> />
</el-form-item> </el-form-item>
<el-form-item label="定制产品:" prop="is_customize">
<el-select
v-model="tableFrom.is_customize"
clearable
filterable
placeholder="请选择"
class="selWidth"
@change="getList(1)"
>
<el-option label="是" value="1" />
<el-option label="否" value="0" />
</el-select>
</el-form-item>
<el-form-item> <el-form-item>
<el-button type="primary" size="small" @click="getList(1)" <el-button type="primary" size="small" @click="getList(1)"
>搜索</el-button >搜索</el-button
@ -376,7 +389,7 @@
</div> </div>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column prop="store_name" label="商品名称" min-width="180"> <el-table-column prop="store_name" label="商品名称" min-width="120">
<template slot-scope="scope"> <template slot-scope="scope">
<div> <div>
<span class="tags_name" :class="'name' + scope.row.spec_type">{{ <span class="tags_name" :class="'name' + scope.row.spec_type">{{
@ -386,7 +399,7 @@
</div> </div>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column prop="is_customize" label="定制产品" min-width="180"> <el-table-column prop="is_customize" label="定制产品" min-width="80">
<template slot-scope="scope"> <template slot-scope="scope">
<div> <div>
{{ scope.row.is_customize ? "是" : "否" }} {{ scope.row.is_customize ? "是" : "否" }}
@ -982,6 +995,7 @@ export default {
page: 1, page: 1,
limit: 20, limit: 20,
date: "", date: "",
is_customize: "",
cate_id: "", cate_id: "",
sys_labels: "", sys_labels: "",
pid: "", pid: "",

View File

@ -608,9 +608,13 @@
class="demo-ruleForm" class="demo-ruleForm"
> >
<el-form-item label="定制产品" prop="is_customize"> <el-form-item label="定制产品" prop="is_customize">
<el-radio-group v-model="ruleForm.is_customize"> <el-radio-group v-model="projectData.is_customize">
<el-radio :label="0"></el-radio> <el-radio :disabled="projectData.is_customize == 1" :label="0"
<el-radio :label="1"></el-radio> ></el-radio
>
<el-radio :disabled="projectData.is_customize == 0" :label="1"
></el-radio
>
</el-radio-group> </el-radio-group>
</el-form-item> </el-form-item>
<el-form-item <el-form-item
@ -843,7 +847,7 @@ export default {
refusal: "", refusal: "",
status: 1, status: 1,
id: "", id: "",
is_customize: 0, // is_customize: 0,
status_img: [], status_img: [],
}, },
formThead: Object.assign({}, objTitle), formThead: Object.assign({}, objTitle),
@ -1027,8 +1031,9 @@ export default {
this.ruleForm.refusal = ""; this.ruleForm.refusal = "";
productDetailApi(id) productDetailApi(id)
.then((res) => { .then((res) => {
(this.projectData = res.data), this.projectData = res.data;
(this.ruleForm.status_img = res.data.status_img);
this.ruleForm.status_img = res.data.status_img;
let qualification = { let qualification = {
production_name: "", production_name: "",
businessList: [], businessList: [],