|
|
|
@ -1,84 +1,173 @@ |
|
|
|
|
<template> |
|
|
|
|
<div> |
|
|
|
|
<el-card shadow="hover" class="mgb20"> |
|
|
|
|
<el-card shadow="hover" |
|
|
|
|
class="mgb20"> |
|
|
|
|
<div class="flex-between"> |
|
|
|
|
<div class="per_title" v-preventReClick @click="goback(0)"> |
|
|
|
|
<div class="per_title" |
|
|
|
|
v-preventReClick |
|
|
|
|
@click="goback(0)"> |
|
|
|
|
<i class="el-icon-arrow-left"></i> |
|
|
|
|
<span class="per_back">返回</span> |
|
|
|
|
<span v-if="form.customerName || !customerId" class="per_school" v-text="isDetail ? form.customerName + '/查看' : (customerId ? form.customerName + '/编辑' : '新增')"></span> |
|
|
|
|
<span v-if="form.customerName || !customerId" |
|
|
|
|
class="per_school" |
|
|
|
|
v-text="isDetail ? form.customerName + '/查看' : (customerId ? form.customerName + '/编辑' : '新增')"></span> |
|
|
|
|
</div> |
|
|
|
|
</div> |
|
|
|
|
</el-card> |
|
|
|
|
|
|
|
|
|
<el-card shadow="hover" class="card"> |
|
|
|
|
<div class="tabs" v-if="customerId"> |
|
|
|
|
<a class="item" v-for="(item, i) in tabs" :key="i" :class="{active: i == curTab}" @click="tabChange(i)">{{ item }}</a> |
|
|
|
|
<el-card shadow="hover" |
|
|
|
|
class="card"> |
|
|
|
|
<div class="tabs" |
|
|
|
|
v-if="customerId"> |
|
|
|
|
<a class="item" |
|
|
|
|
v-for="(item, i) in tabs" |
|
|
|
|
:key="i" |
|
|
|
|
:class="{active: i == curTab}" |
|
|
|
|
@click="tabChange(i)">{{ item }}</a> |
|
|
|
|
</div> |
|
|
|
|
<div v-show="curTab === 'tab1'"> |
|
|
|
|
<el-form :model="form" :rules="rules" ref="form" label-width="120px" class="flex-start-around info" :disabled="isDetail"> |
|
|
|
|
<el-col :span="6" style="margin-right: 60px;"> |
|
|
|
|
<el-form-item prop="countries" label="国家"> |
|
|
|
|
<el-select v-model="form.countries" clearable placeholder="请选择国家"> |
|
|
|
|
<el-option v-for="(item,index) in countryList" :key="index" :label="item.name" :value="item.name"></el-option> |
|
|
|
|
<el-form :model="form" |
|
|
|
|
:rules="rules" |
|
|
|
|
ref="form" |
|
|
|
|
label-width="120px" |
|
|
|
|
class="flex-start-around info" |
|
|
|
|
:disabled="isDetail"> |
|
|
|
|
<el-col :span="6" |
|
|
|
|
style="margin-right: 60px;"> |
|
|
|
|
<el-form-item prop="countries" |
|
|
|
|
label="国家"> |
|
|
|
|
<el-select v-model="form.countries" |
|
|
|
|
clearable |
|
|
|
|
placeholder="请选择国家"> |
|
|
|
|
<el-option v-for="(item,index) in countryList" |
|
|
|
|
:key="index" |
|
|
|
|
:label="item.name" |
|
|
|
|
:value="item.name"></el-option> |
|
|
|
|
</el-select> |
|
|
|
|
</el-form-item> |
|
|
|
|
<el-form-item prop="schoolId" label="客户名称"> |
|
|
|
|
<el-select v-model="form.schoolId" filterable clearable placeholder="请选择学校" :disabled="!!customerId" @change="SchoolChange" @clear="clearSchool"> |
|
|
|
|
<el-option v-for="(item,index) in schoolList" :key="index" :label="item.schoolName" :value="item.schoolId"></el-option> |
|
|
|
|
<el-form-item prop="schoolId" |
|
|
|
|
label="客户名称"> |
|
|
|
|
<div class="flex a-center"> |
|
|
|
|
<el-select v-model="form.schoolId" |
|
|
|
|
filterable |
|
|
|
|
clearable |
|
|
|
|
placeholder="请选择学校" |
|
|
|
|
:disabled="!!customerId" |
|
|
|
|
@change="SchoolChange" |
|
|
|
|
@clear="clearSchool"> |
|
|
|
|
<el-option v-for="(item,index) in schoolList" |
|
|
|
|
:key="index" |
|
|
|
|
:label="item.schoolName" |
|
|
|
|
:value="item.schoolId"></el-option> |
|
|
|
|
</el-select> |
|
|
|
|
<i class="el-icon-circle-plus-outline plus-cus" |
|
|
|
|
@click="addCustomer"></i> |
|
|
|
|
</div> |
|
|
|
|
</el-form-item> |
|
|
|
|
<el-form-item prop="cityId" label="城市"> |
|
|
|
|
<el-select v-model="form.cityId" placeholder="" disabled> |
|
|
|
|
<el-option v-for="(item,index) in cityList" :key="index" :label="item.cityName" :value="item.cityId"></el-option> |
|
|
|
|
<el-form-item prop="cityId" |
|
|
|
|
label="城市"> |
|
|
|
|
<el-select v-model="form.cityId" |
|
|
|
|
placeholder="" |
|
|
|
|
disabled> |
|
|
|
|
<el-option v-for="(item,index) in cityList" |
|
|
|
|
:key="index" |
|
|
|
|
:label="item.cityName" |
|
|
|
|
:value="item.cityId"></el-option> |
|
|
|
|
</el-select> |
|
|
|
|
</el-form-item> |
|
|
|
|
<el-form-item prop="industryId" label="行业"> |
|
|
|
|
<el-select v-model="form.industryId" clearable placeholder="请选择行业" :disabled="form.industryClassId ? false : true"> |
|
|
|
|
<el-option v-for="(item,index) in industryList" :key="index" :label="item.industryName" :value="item.industryId"></el-option> |
|
|
|
|
<el-form-item prop="industryId" |
|
|
|
|
label="行业"> |
|
|
|
|
<el-select v-model="form.industryId" |
|
|
|
|
clearable |
|
|
|
|
placeholder="请选择行业" |
|
|
|
|
:disabled="form.industryClassId ? false : true"> |
|
|
|
|
<el-option v-for="(item,index) in industryList" |
|
|
|
|
:key="index" |
|
|
|
|
:label="item.industryName" |
|
|
|
|
:value="item.industryId"></el-option> |
|
|
|
|
</el-select> |
|
|
|
|
</el-form-item> |
|
|
|
|
|
|
|
|
|
<el-form-item prop="account" label="账号"> |
|
|
|
|
<el-input placeholder="请输入账号" v-model="form.account"></el-input> |
|
|
|
|
<el-form-item prop="account" |
|
|
|
|
label="账号"> |
|
|
|
|
<el-input placeholder="请输入账号" |
|
|
|
|
v-model="form.account"></el-input> |
|
|
|
|
</el-form-item> |
|
|
|
|
<el-form-item label="职务"> |
|
|
|
|
<el-input placeholder="请输入职务名称" v-model="form.position" maxlength="11"></el-input> |
|
|
|
|
<el-input placeholder="请输入职务名称" |
|
|
|
|
v-model="form.position" |
|
|
|
|
maxlength="11"></el-input> |
|
|
|
|
</el-form-item> |
|
|
|
|
<el-form-item label="产品到期时间"> |
|
|
|
|
<el-date-picker type="date" disabled v-model="form.expireDate" style="width: 100%;" value-format="yyyy-MM-dd"></el-date-picker> |
|
|
|
|
<el-date-picker type="date" |
|
|
|
|
disabled |
|
|
|
|
v-model="form.expireDate" |
|
|
|
|
style="width: 100%;" |
|
|
|
|
value-format="yyyy-MM-dd"></el-date-picker> |
|
|
|
|
</el-form-item> |
|
|
|
|
</el-col> |
|
|
|
|
|
|
|
|
|
<el-col :span="6" style="margin-left: 60px;"> |
|
|
|
|
<el-col :span="6" |
|
|
|
|
style="margin-left: 60px;"> |
|
|
|
|
<el-form-item label="客户类型"> |
|
|
|
|
<el-select v-model="form.customerType" placeholder="下单后客户类型自动补充" disabled> |
|
|
|
|
<el-option v-for="(item,index) in customerTypeList" :key="index" :label="item.name" :value="item.value"></el-option> |
|
|
|
|
<el-select v-model="form.customerType" |
|
|
|
|
placeholder="下单后客户类型自动补充" |
|
|
|
|
disabled> |
|
|
|
|
<el-option v-for="(item,index) in customerTypeList" |
|
|
|
|
:key="index" |
|
|
|
|
:label="item.name" |
|
|
|
|
:value="item.value"></el-option> |
|
|
|
|
</el-select> |
|
|
|
|
</el-form-item> |
|
|
|
|
<el-form-item prop="provinceId" label="省份"> |
|
|
|
|
<el-select v-model="form.provinceId" placeholder="" disabled> |
|
|
|
|
<el-option v-for="(item,index) in provinceList" :key="index" :label="item.provinceName" :value="item.provinceId"></el-option> |
|
|
|
|
<el-form-item prop="provinceId" |
|
|
|
|
label="省份"> |
|
|
|
|
<el-select v-model="form.provinceId" |
|
|
|
|
placeholder="" |
|
|
|
|
disabled> |
|
|
|
|
<el-option v-for="(item,index) in provinceList" |
|
|
|
|
:key="index" |
|
|
|
|
:label="item.provinceName" |
|
|
|
|
:value="item.provinceId"></el-option> |
|
|
|
|
</el-select> |
|
|
|
|
</el-form-item> |
|
|
|
|
<el-form-item prop="industryClassId" label="行业类型"> |
|
|
|
|
<el-select v-model="form.industryClassId" clearable placeholder="请选择行业类型" @change="changIndustry" @clear="clearIndustry()"> |
|
|
|
|
<el-option v-for="(item,index) in IndustryClassList" :key="index" :label="item.industryClassName" :value="item.industryClassId"></el-option> |
|
|
|
|
<el-form-item prop="industryClassId" |
|
|
|
|
label="行业类型"> |
|
|
|
|
<el-select v-model="form.industryClassId" |
|
|
|
|
clearable |
|
|
|
|
placeholder="请选择行业类型" |
|
|
|
|
@change="changIndustry" |
|
|
|
|
@clear="clearIndustry()"> |
|
|
|
|
<el-option v-for="(item,index) in IndustryClassList" |
|
|
|
|
:key="index" |
|
|
|
|
:label="item.industryClassName" |
|
|
|
|
:value="item.industryClassId"></el-option> |
|
|
|
|
</el-select> |
|
|
|
|
</el-form-item> |
|
|
|
|
<el-form-item prop="name" label="联系人姓名"> |
|
|
|
|
<el-input placeholder="请输入联系人姓名" v-model="form.name"></el-input> |
|
|
|
|
<el-form-item prop="name" |
|
|
|
|
label="联系人姓名"> |
|
|
|
|
<el-input placeholder="请输入联系人姓名" |
|
|
|
|
v-model="form.name"></el-input> |
|
|
|
|
</el-form-item> |
|
|
|
|
<el-form-item prop="phone" label="手机号"> |
|
|
|
|
<el-input placeholder="请输入联系人手机号" v-model="form.phone" maxlength="11"></el-input> |
|
|
|
|
<el-form-item prop="phone" |
|
|
|
|
label="手机号"> |
|
|
|
|
<el-input placeholder="请输入联系人手机号" |
|
|
|
|
v-model="form.phone" |
|
|
|
|
maxlength="11"></el-input> |
|
|
|
|
</el-form-item> |
|
|
|
|
<el-form-item prop="email" label="邮箱"> |
|
|
|
|
<el-input placeholder="请输入邮箱" v-model="form.email"></el-input> |
|
|
|
|
<el-form-item prop="email" |
|
|
|
|
label="邮箱"> |
|
|
|
|
<el-input placeholder="请输入邮箱" |
|
|
|
|
v-model="form.email"></el-input> |
|
|
|
|
</el-form-item> |
|
|
|
|
</el-col> |
|
|
|
|
</el-form> |
|
|
|
|
<div v-if="!isDetail" style="margin-top: 20px;text-align: center"> |
|
|
|
|
<el-button type="primary" v-preventReClick @click="saveAdd(0)">确定</el-button> |
|
|
|
|
<el-button v-preventReClick @click="$router.back()">取消</el-button> |
|
|
|
|
<div v-if="!isDetail" |
|
|
|
|
style="margin-top: 20px;text-align: center"> |
|
|
|
|
<el-button type="primary" |
|
|
|
|
v-preventReClick |
|
|
|
|
@click="saveAdd(0)">确定</el-button> |
|
|
|
|
<el-button v-preventReClick |
|
|
|
|
@click="$router.back()">取消</el-button> |
|
|
|
|
</div> |
|
|
|
|
</div> |
|
|
|
|
|
|
|
|
@ -87,34 +176,69 @@ |
|
|
|
|
<ul class="filter"> |
|
|
|
|
<li> |
|
|
|
|
<label>产品分类</label> |
|
|
|
|
<el-select v-model="form2.productType" placeholder="请选择产品类型" clearable @change="filterForm2"> |
|
|
|
|
<el-option v-for="(item,index) in productTypeList" :key="index" :label="item.classificationName" :value="item.classificationId"></el-option> |
|
|
|
|
<el-select v-model="form2.productType" |
|
|
|
|
placeholder="请选择产品类型" |
|
|
|
|
clearable |
|
|
|
|
@change="filterForm2"> |
|
|
|
|
<el-option v-for="(item,index) in productTypeList" |
|
|
|
|
:key="index" |
|
|
|
|
:label="item.classificationName" |
|
|
|
|
:value="item.classificationId"></el-option> |
|
|
|
|
</el-select> |
|
|
|
|
</li> |
|
|
|
|
<li> |
|
|
|
|
<label>订阅状态</label> |
|
|
|
|
<el-select v-model="form2.status" placeholder="请选择订阅状态" @change="filterForm2"> |
|
|
|
|
<el-option v-for="(item,index) in subStatusList" :key="index" :label="item.name" :value="item.name"></el-option> |
|
|
|
|
<el-select v-model="form2.status" |
|
|
|
|
placeholder="请选择订阅状态" |
|
|
|
|
@change="filterForm2"> |
|
|
|
|
<el-option v-for="(item,index) in subStatusList" |
|
|
|
|
:key="index" |
|
|
|
|
:label="item.name" |
|
|
|
|
:value="item.name"></el-option> |
|
|
|
|
</el-select> |
|
|
|
|
</li> |
|
|
|
|
<li> |
|
|
|
|
<el-input style="width: 250px;" placeholder="请输入产品名称" prefix-icon="el-icon-search" clearable v-model="form2.keyword"></el-input> |
|
|
|
|
<el-input style="width: 250px;" |
|
|
|
|
placeholder="请输入产品名称" |
|
|
|
|
prefix-icon="el-icon-search" |
|
|
|
|
clearable |
|
|
|
|
v-model="form2.keyword"></el-input> |
|
|
|
|
</li> |
|
|
|
|
</ul> |
|
|
|
|
<div> |
|
|
|
|
<el-button type="primary" @click="exportList">导出列表</el-button> |
|
|
|
|
<el-button type="primary" |
|
|
|
|
@click="exportList">导出列表</el-button> |
|
|
|
|
</div> |
|
|
|
|
</div> |
|
|
|
|
<el-table :data="products" class="orderTable" stripe header-align="center" @selection-change="handleSelectionChange" row-key="id"> |
|
|
|
|
<el-table-column type="selection" width="55" align="center" :reserve-selection="true"></el-table-column> |
|
|
|
|
<el-table-column type="index" width="100" label="序号" align="center"> |
|
|
|
|
<el-table :data="products" |
|
|
|
|
class="orderTable" |
|
|
|
|
stripe |
|
|
|
|
header-align="center" |
|
|
|
|
@selection-change="handleSelectionChange" |
|
|
|
|
row-key="id"> |
|
|
|
|
<el-table-column type="selection" |
|
|
|
|
width="55" |
|
|
|
|
align="center" |
|
|
|
|
:reserve-selection="true"></el-table-column> |
|
|
|
|
<el-table-column type="index" |
|
|
|
|
width="100" |
|
|
|
|
label="序号" |
|
|
|
|
align="center"> |
|
|
|
|
</el-table-column> |
|
|
|
|
<el-table-column prop="productName" label="产品名称" align="center"></el-table-column> |
|
|
|
|
<el-table-column prop="productTypeName" label="产品分类" align="center"></el-table-column> |
|
|
|
|
<el-table-column label="起止日期" align="center"> |
|
|
|
|
<el-table-column prop="goodsName" |
|
|
|
|
label="产品名称" |
|
|
|
|
align="center"></el-table-column> |
|
|
|
|
<el-table-column prop="productTypeName" |
|
|
|
|
label="产品分类" |
|
|
|
|
align="center"></el-table-column> |
|
|
|
|
<el-table-column label="起止日期" |
|
|
|
|
align="center"> |
|
|
|
|
<template slot-scope="scope"> |
|
|
|
|
{{ scope.row.status === '已过期' ? '' : scope.row.startAndEndTime }} |
|
|
|
|
<el-tooltip v-if="scope.row.other" class="item" effect="dark" placement="top"> |
|
|
|
|
<el-tooltip v-if="scope.row.other" |
|
|
|
|
class="item" |
|
|
|
|
effect="dark" |
|
|
|
|
placement="top"> |
|
|
|
|
<div slot="content"> |
|
|
|
|
还有<span v-html="scope.row.other"></span><br>的订单还未生效 |
|
|
|
|
</div> |
|
|
|
@ -122,20 +246,34 @@ |
|
|
|
|
</el-tooltip> |
|
|
|
|
</template> |
|
|
|
|
</el-table-column> |
|
|
|
|
<el-table-column label="剩余期限" align="center"> |
|
|
|
|
<el-table-column label="剩余期限" |
|
|
|
|
align="center"> |
|
|
|
|
<template slot-scope="scope"> |
|
|
|
|
{{scope.row.remain}} 天 |
|
|
|
|
</template> |
|
|
|
|
</el-table-column> |
|
|
|
|
<el-table-column prop="status" label="订阅状态" align="center"></el-table-column> |
|
|
|
|
<el-table-column label="产品状态" align="center"> |
|
|
|
|
<el-table-column prop="status" |
|
|
|
|
label="订阅状态" |
|
|
|
|
align="center"></el-table-column> |
|
|
|
|
<el-table-column label="产品状态" |
|
|
|
|
align="center"> |
|
|
|
|
<template slot-scope="scope"> |
|
|
|
|
<el-switch v-model="scope.row.isEnable" :active-value="1" :inactive-value="0" :active-text="scope.row.isEnable ? '启用' : '禁用'" :disabled="scope.row.status === '已过期'" @change="switchOff($event,scope.row,scope.$index)"></el-switch> |
|
|
|
|
<el-switch v-model="scope.row.isEnable" |
|
|
|
|
:active-value="1" |
|
|
|
|
:inactive-value="0" |
|
|
|
|
:active-text="scope.row.isEnable ? '启用' : '禁用'" |
|
|
|
|
:disabled="scope.row.status === '已过期'" |
|
|
|
|
@change="switchOff($event,scope.row,scope.$index)"></el-switch> |
|
|
|
|
</template> |
|
|
|
|
</el-table-column> |
|
|
|
|
</el-table> |
|
|
|
|
<div class="pagination"> |
|
|
|
|
<el-pagination background layout="total, prev, pager, next" @current-change="handleCurrentChangeProduct" :current-page="pageProduct" :page-size="pageSizeProduct" :total="totalProduct"></el-pagination> |
|
|
|
|
<el-pagination background |
|
|
|
|
layout="total, prev, pager, next" |
|
|
|
|
@current-change="handleCurrentChangeProduct" |
|
|
|
|
:current-page="pageProduct" |
|
|
|
|
:page-size="pageSizeProduct" |
|
|
|
|
:total="totalProduct"></el-pagination> |
|
|
|
|
</div> |
|
|
|
|
</div> |
|
|
|
|
|
|
|
|
@ -144,32 +282,68 @@ |
|
|
|
|
<ul class="filter"> |
|
|
|
|
<li> |
|
|
|
|
<label>订单类型</label> |
|
|
|
|
<el-select v-model="form3.orderType" clearable placeholder="请选择订单类型" @change="getOrder"> |
|
|
|
|
<el-option v-for="(item,index) in orderTypeList" :key="index" :label="item.name" :value="item.value"></el-option> |
|
|
|
|
<el-select v-model="form3.orderType" |
|
|
|
|
clearable |
|
|
|
|
placeholder="请选择订单类型" |
|
|
|
|
@change="getOrder"> |
|
|
|
|
<el-option v-for="(item,index) in orderTypeList" |
|
|
|
|
:key="index" |
|
|
|
|
:label="item.name" |
|
|
|
|
:value="item.value"></el-option> |
|
|
|
|
</el-select> |
|
|
|
|
</li> |
|
|
|
|
<li> |
|
|
|
|
<label>订单状态</label> |
|
|
|
|
<el-select v-model="form3.orderStatus" clearable placeholder="请选择订单状态" @change="getOrder"> |
|
|
|
|
<el-option v-for="(item,index) in orderStatusList" :key="index" :label="item.name" :value="item.id"></el-option> |
|
|
|
|
<el-select v-model="form3.orderStatus" |
|
|
|
|
clearable |
|
|
|
|
placeholder="请选择订单状态" |
|
|
|
|
@change="getOrder"> |
|
|
|
|
<el-option v-for="(item,index) in orderStatusList" |
|
|
|
|
:key="index" |
|
|
|
|
:label="item.name" |
|
|
|
|
:value="item.id"></el-option> |
|
|
|
|
</el-select> |
|
|
|
|
</li> |
|
|
|
|
</ul> |
|
|
|
|
<div> |
|
|
|
|
<el-input style="width: 250px;" placeholder="请输入订单编号、内容" prefix-icon="el-icon-search" clearable v-model="form3.keyword"></el-input> |
|
|
|
|
<el-input style="width: 250px;" |
|
|
|
|
placeholder="请输入订单编号、内容" |
|
|
|
|
prefix-icon="el-icon-search" |
|
|
|
|
clearable |
|
|
|
|
v-model="form3.keyword"></el-input> |
|
|
|
|
</div> |
|
|
|
|
</div> |
|
|
|
|
<el-table :data="orders" class="orderTable" stripe header-align="center" @selection-change="handleSelectionChange" row-key="orderId"> |
|
|
|
|
<el-table-column type="selection" width="55" align="center" :reserve-selection="true"></el-table-column> |
|
|
|
|
<el-table-column type="index" width="100" label="序号" align="center"> |
|
|
|
|
<el-table :data="orders" |
|
|
|
|
class="orderTable" |
|
|
|
|
stripe |
|
|
|
|
header-align="center" |
|
|
|
|
@selection-change="handleSelectionChange" |
|
|
|
|
row-key="orderId"> |
|
|
|
|
<el-table-column type="selection" |
|
|
|
|
width="55" |
|
|
|
|
align="center" |
|
|
|
|
:reserve-selection="true"></el-table-column> |
|
|
|
|
<el-table-column type="index" |
|
|
|
|
width="100" |
|
|
|
|
label="序号" |
|
|
|
|
align="center"> |
|
|
|
|
</el-table-column> |
|
|
|
|
<el-table-column prop="orderNumber" label="订单编号" align="center"></el-table-column> |
|
|
|
|
<el-table-column prop="orderContent" label="订单内容" align="center"> |
|
|
|
|
<el-table-column prop="orderNumber" |
|
|
|
|
label="订单编号" |
|
|
|
|
align="center"></el-table-column> |
|
|
|
|
<el-table-column prop="orderContent" |
|
|
|
|
label="订单内容" |
|
|
|
|
align="center"> |
|
|
|
|
<template slot-scope="scope"> |
|
|
|
|
<el-popover trigger="hover" placement="top" style='width: 500px' v-if='scope.row.orderContent.length >14'> |
|
|
|
|
<el-popover trigger="hover" |
|
|
|
|
placement="top" |
|
|
|
|
style='width: 500px' |
|
|
|
|
v-if='scope.row.orderContent.length >14'> |
|
|
|
|
<p> {{ scope.row.orderContent }}</p> |
|
|
|
|
<div slot="reference" class="name-wrapper"> |
|
|
|
|
<el-tag size="medium" class='tags'>{{ scope.row.orderContent }}</el-tag> |
|
|
|
|
<div slot="reference" |
|
|
|
|
class="name-wrapper"> |
|
|
|
|
<el-tag size="medium" |
|
|
|
|
class='tags'>{{ scope.row.orderContent }}</el-tag> |
|
|
|
|
</div> |
|
|
|
|
</el-popover> |
|
|
|
|
<span v-else> |
|
|
|
@ -177,50 +351,89 @@ |
|
|
|
|
</span> |
|
|
|
|
</template> |
|
|
|
|
</el-table-column> |
|
|
|
|
<el-table-column prop="orderAmount" label="订单金额(元)" align="center"></el-table-column> |
|
|
|
|
<el-table-column prop="createTime" label="订单日期" align="center"></el-table-column> |
|
|
|
|
<el-table-column prop="orderType" label="订单类型" align="center"></el-table-column> |
|
|
|
|
<el-table-column prop="orderStatus" label="订单状态" align="center"></el-table-column> |
|
|
|
|
<el-table-column label="操作" align="center"> |
|
|
|
|
<el-table-column prop="orderAmount" |
|
|
|
|
label="订单金额(元)" |
|
|
|
|
align="center"></el-table-column> |
|
|
|
|
<el-table-column prop="createTime" |
|
|
|
|
label="订单日期" |
|
|
|
|
align="center"></el-table-column> |
|
|
|
|
<el-table-column prop="orderType" |
|
|
|
|
label="订单类型" |
|
|
|
|
align="center"></el-table-column> |
|
|
|
|
<el-table-column prop="orderStatus" |
|
|
|
|
label="订单状态" |
|
|
|
|
align="center"></el-table-column> |
|
|
|
|
<el-table-column label="操作" |
|
|
|
|
align="center"> |
|
|
|
|
<template slot-scope="scope"> |
|
|
|
|
<el-button type="text" @click="toOrderDetail(scope.row)">订单详情</el-button> |
|
|
|
|
<el-button type="text" |
|
|
|
|
@click="toOrderDetail(scope.row)">订单详情</el-button> |
|
|
|
|
</template> |
|
|
|
|
</el-table-column> |
|
|
|
|
</el-table> |
|
|
|
|
<div class="pagination"> |
|
|
|
|
<el-pagination background layout="total, prev, pager, next" @current-change="handleCurrentChangeOrder" :current-page="pageOrder" :page-size="pageSizeOrder" :total="totalOrder"></el-pagination> |
|
|
|
|
<el-pagination background |
|
|
|
|
layout="total, prev, pager, next" |
|
|
|
|
@current-change="handleCurrentChangeOrder" |
|
|
|
|
:current-page="pageOrder" |
|
|
|
|
:page-size="pageSizeOrder" |
|
|
|
|
:total="totalOrder"></el-pagination> |
|
|
|
|
</div> |
|
|
|
|
</div> |
|
|
|
|
|
|
|
|
|
<div v-show="curTab === 'tab4'"> |
|
|
|
|
<div class="tool"> |
|
|
|
|
<div> |
|
|
|
|
<el-input style="width: 350px;" placeholder="请输入订单编号、合同名称、合同编号、产品内容" prefix-icon="el-icon-search" clearable></el-input> |
|
|
|
|
<el-input style="width: 350px;" |
|
|
|
|
placeholder="请输入订单编号、合同名称、合同编号、产品内容" |
|
|
|
|
prefix-icon="el-icon-search" |
|
|
|
|
clearable></el-input> |
|
|
|
|
</div> |
|
|
|
|
</div> |
|
|
|
|
<el-table :data="contractInformations" class="table" stripe header-align="center"> |
|
|
|
|
<el-table-column type="index" width="100" label="序号" align="center"> |
|
|
|
|
<el-table :data="contractInformations" |
|
|
|
|
class="table" |
|
|
|
|
stripe |
|
|
|
|
header-align="center"> |
|
|
|
|
<el-table-column type="index" |
|
|
|
|
width="100" |
|
|
|
|
label="序号" |
|
|
|
|
align="center"> |
|
|
|
|
</el-table-column> |
|
|
|
|
<el-table-column prop="contractNumber" label="订单号" align="center"></el-table-column> |
|
|
|
|
<el-table-column prop="contractNumber" label="合同编号" align="center"></el-table-column> |
|
|
|
|
<el-table-column prop="contractName" label="合同名称" align="center"> |
|
|
|
|
<el-table-column prop="contractNumber" |
|
|
|
|
label="订单号" |
|
|
|
|
align="center"></el-table-column> |
|
|
|
|
<el-table-column prop="contractNumber" |
|
|
|
|
label="合同编号" |
|
|
|
|
align="center"></el-table-column> |
|
|
|
|
<el-table-column prop="contractName" |
|
|
|
|
label="合同名称" |
|
|
|
|
align="center"> |
|
|
|
|
</el-table-column> |
|
|
|
|
<el-table-column prop="endTime" label="合同期限" align="center"> |
|
|
|
|
<el-table-column prop="endTime" |
|
|
|
|
label="合同期限" |
|
|
|
|
align="center"> |
|
|
|
|
<template slot-scope="scope"> |
|
|
|
|
{{scope.row.startTime?scope.row.startTime.split(' ').shift():''}} - {{scope.row.endTime?scope.row.endTime.split(' ').shift():''}} |
|
|
|
|
</template> |
|
|
|
|
</el-table-column> |
|
|
|
|
<el-table-column prop="dataOrCourseName" label="产品内容" align="center"> |
|
|
|
|
<el-table-column prop="dataOrCourseName" |
|
|
|
|
label="产品内容" |
|
|
|
|
align="center"> |
|
|
|
|
</el-table-column> |
|
|
|
|
<el-table-column prop="contractMoney" label="合同金额" align="center"> |
|
|
|
|
<el-table-column prop="contractMoney" |
|
|
|
|
label="合同金额" |
|
|
|
|
align="center"> |
|
|
|
|
<template slot-scope="scope"> |
|
|
|
|
{{scope.row.contractMoney}} 元 |
|
|
|
|
</template> |
|
|
|
|
</el-table-column> |
|
|
|
|
<el-table-column label="操作" align="center"> |
|
|
|
|
<el-table-column label="操作" |
|
|
|
|
align="center"> |
|
|
|
|
<template slot-scope="scope"> |
|
|
|
|
<el-button type="text" @click="showContract(scope.row)">查看</el-button> |
|
|
|
|
<el-button type="text" @click="showContract(scope.row)">下载</el-button> |
|
|
|
|
<el-button type="text" |
|
|
|
|
@click="showContract(scope.row)">查看</el-button> |
|
|
|
|
<el-button type="text" |
|
|
|
|
@click="showContract(scope.row)">下载</el-button> |
|
|
|
|
</template> |
|
|
|
|
</el-table-column> |
|
|
|
|
</el-table> |
|
|
|
@ -229,41 +442,122 @@ |
|
|
|
|
<div v-show="curTab === 'tab5'"> |
|
|
|
|
<div class="tool"> |
|
|
|
|
<div> |
|
|
|
|
<el-input style="width: 300px;" placeholder="请输入商务经理、手机号" prefix-icon="el-icon-search" clearable v-model="bmsKeyword"></el-input> |
|
|
|
|
<el-input style="width: 300px;" |
|
|
|
|
placeholder="请输入商务经理、手机号" |
|
|
|
|
prefix-icon="el-icon-search" |
|
|
|
|
clearable |
|
|
|
|
v-model="bmsKeyword"></el-input> |
|
|
|
|
</div> |
|
|
|
|
</div> |
|
|
|
|
<el-table :data="bms" class="table" stripe header-align="center"> |
|
|
|
|
<el-table-column type="index" width="100" label="序号" align="center"></el-table-column> |
|
|
|
|
<el-table-column prop="userName" label="姓名" width="200" align="center"> |
|
|
|
|
<el-table :data="bms" |
|
|
|
|
class="table" |
|
|
|
|
stripe |
|
|
|
|
header-align="center"> |
|
|
|
|
<el-table-column type="index" |
|
|
|
|
width="100" |
|
|
|
|
label="序号" |
|
|
|
|
align="center"></el-table-column> |
|
|
|
|
<el-table-column prop="userName" |
|
|
|
|
label="姓名" |
|
|
|
|
width="200" |
|
|
|
|
align="center"> |
|
|
|
|
<template slot-scope="scope"> |
|
|
|
|
{{ scope.row.userName }}{{ scope.row.peopleDel ? '(已被删除)' : '' }} |
|
|
|
|
</template> |
|
|
|
|
</el-table-column> |
|
|
|
|
<el-table-column prop="phone" label="手机号" width="150" align="center"></el-table-column> |
|
|
|
|
<el-table-column prop="bmName" label="所属团队" align="center"> |
|
|
|
|
<el-table-column prop="phone" |
|
|
|
|
label="手机号" |
|
|
|
|
width="150" |
|
|
|
|
align="center"></el-table-column> |
|
|
|
|
<el-table-column prop="bmName" |
|
|
|
|
label="所属团队" |
|
|
|
|
align="center"> |
|
|
|
|
<template slot-scope="scope"> |
|
|
|
|
<div v-html="scope.row.bmName"></div> |
|
|
|
|
</template> |
|
|
|
|
</el-table-column> |
|
|
|
|
<el-table-column prop="quantityOfOrder" label="订单数量" width="100" align="center"></el-table-column> |
|
|
|
|
<el-table-column prop="latestTime" label="最近下单时间" width="200" align="center"></el-table-column> |
|
|
|
|
<el-table-column prop="productName" label="产品" align="center" show-overflow-tooltip></el-table-column> |
|
|
|
|
<el-table-column label="操作" width="120" align="center"> |
|
|
|
|
<el-table-column prop="quantityOfOrder" |
|
|
|
|
label="订单数量" |
|
|
|
|
width="100" |
|
|
|
|
align="center"></el-table-column> |
|
|
|
|
<el-table-column prop="latestTime" |
|
|
|
|
label="最近下单时间" |
|
|
|
|
width="200" |
|
|
|
|
align="center"></el-table-column> |
|
|
|
|
<el-table-column prop="productName" |
|
|
|
|
label="产品" |
|
|
|
|
align="center" |
|
|
|
|
show-overflow-tooltip></el-table-column> |
|
|
|
|
<el-table-column label="操作" |
|
|
|
|
width="120" |
|
|
|
|
align="center"> |
|
|
|
|
<template slot-scope="scope"> |
|
|
|
|
<el-button type="text" @click="toOrder(scope.row)">查看</el-button> |
|
|
|
|
<el-button type="text" |
|
|
|
|
@click="toOrder(scope.row)">查看</el-button> |
|
|
|
|
</template> |
|
|
|
|
</el-table-column> |
|
|
|
|
</el-table> |
|
|
|
|
<div class="pagination"> |
|
|
|
|
<el-pagination background layout="total, prev, pager, next" @current-change="handleCurrentChangeBm" :current-page="pageBm" :page-size="pageSizeBm" :total="totalBm"></el-pagination> |
|
|
|
|
<el-pagination background |
|
|
|
|
layout="total, prev, pager, next" |
|
|
|
|
@current-change="handleCurrentChangeBm" |
|
|
|
|
:current-page="pageBm" |
|
|
|
|
:page-size="pageSizeBm" |
|
|
|
|
:total="totalBm"></el-pagination> |
|
|
|
|
</div> |
|
|
|
|
</div> |
|
|
|
|
</el-card> |
|
|
|
|
|
|
|
|
|
<el-dialog :visible.sync="showImg" width="70%" center> |
|
|
|
|
<img :src="fileSrc" width="100%" alt=""> |
|
|
|
|
<el-dialog :visible.sync="showImg" |
|
|
|
|
width="70%" |
|
|
|
|
center> |
|
|
|
|
<img :src="fileSrc" |
|
|
|
|
width="100%" |
|
|
|
|
alt=""> |
|
|
|
|
</el-dialog> |
|
|
|
|
<pdf :visible.sync="pdfVisible" :src.sync="fileSrc"></pdf> |
|
|
|
|
|
|
|
|
|
<el-dialog title="创建客户" |
|
|
|
|
:visible.sync="customerVisible" |
|
|
|
|
width="300px" |
|
|
|
|
class="dialog" |
|
|
|
|
:close-on-click-modal="false"> |
|
|
|
|
<el-form label-width="70px"> |
|
|
|
|
<el-form-item label="客户名称"> |
|
|
|
|
<el-input v-model="customerForm.schoolName" |
|
|
|
|
placeholder="请输入客户名称"></el-input> |
|
|
|
|
</el-form-item> |
|
|
|
|
<el-form-item prop="userName" |
|
|
|
|
label="省份"> |
|
|
|
|
<el-select v-model="customerForm.provinceName" |
|
|
|
|
placeholder="请选择省份" |
|
|
|
|
@change="provinceChange"> |
|
|
|
|
<el-option v-for="(item,index) in provinceList" |
|
|
|
|
:key="index" |
|
|
|
|
:label="item.provinceName" |
|
|
|
|
:value="item.provinceName"></el-option> |
|
|
|
|
</el-select> |
|
|
|
|
</el-form-item> |
|
|
|
|
<el-form-item prop="userName" |
|
|
|
|
label="城市"> |
|
|
|
|
<el-select v-model="customerForm.cityName" |
|
|
|
|
placeholder="请选择城市" |
|
|
|
|
:disabled="customerForm.provinceName ? false : true"> |
|
|
|
|
<el-option v-for="(item,index) in cities" |
|
|
|
|
:key="index" |
|
|
|
|
:label="item.cityName" |
|
|
|
|
:value="item.cityName"></el-option> |
|
|
|
|
</el-select> |
|
|
|
|
</el-form-item> |
|
|
|
|
</el-form> |
|
|
|
|
<span slot="footer" |
|
|
|
|
class="dialog-footer"> |
|
|
|
|
<el-button @click="customerVisible = false">取消</el-button> |
|
|
|
|
<el-button type="primary" |
|
|
|
|
@click="submitCustomer">确定</el-button> |
|
|
|
|
</span> |
|
|
|
|
</el-dialog> |
|
|
|
|
<pdf :visible.sync="pdfVisible" |
|
|
|
|
:src.sync="fileSrc"></pdf> |
|
|
|
|
</div> |
|
|
|
|
</template> |
|
|
|
|
|
|
|
|
@ -482,7 +776,14 @@ export default { |
|
|
|
|
phoneRepeat: false, |
|
|
|
|
emailRepeat: false, |
|
|
|
|
submiting: false, // 新增编辑防抖标识 |
|
|
|
|
updateTime: 0 |
|
|
|
|
updateTime: 0, |
|
|
|
|
customerVisible: false, |
|
|
|
|
cities: [], |
|
|
|
|
customerForm: { |
|
|
|
|
schoolName: '', |
|
|
|
|
provinceName: '', |
|
|
|
|
cityName: '', |
|
|
|
|
} |
|
|
|
|
}; |
|
|
|
|
}, |
|
|
|
|
watch: { |
|
|
|
@ -665,6 +966,37 @@ export default { |
|
|
|
|
this.handlePage() |
|
|
|
|
this.$router.push(`addcustomer?id=${this.customerId}&type=tab2&page=${val}`) |
|
|
|
|
}, |
|
|
|
|
// 创建客户 |
|
|
|
|
addCustomer () { |
|
|
|
|
this.customerVisible = true |
|
|
|
|
}, |
|
|
|
|
// 获取城市 |
|
|
|
|
provinceChange (name) { |
|
|
|
|
this.$get(this.api.queryCity, { |
|
|
|
|
provinceId: this.provinceList.find(e => e.provinceName == name).provinceId |
|
|
|
|
}).then(({ list }) => { |
|
|
|
|
this.cities = list |
|
|
|
|
this.customerForm.cityName = '' |
|
|
|
|
}).catch(res => { }); |
|
|
|
|
}, |
|
|
|
|
// 客户新增提交 |
|
|
|
|
submitCustomer () { |
|
|
|
|
if (this.submiting) return false |
|
|
|
|
const form = this.customerForm |
|
|
|
|
if (!form.schoolName) return this.$message.warning('请输入客户名称') |
|
|
|
|
if (!form.provinceName) return this.$message.warning('请选择省份') |
|
|
|
|
if (!form.cityName) return this.$message.warning('请选择城市') |
|
|
|
|
this.submiting = true |
|
|
|
|
this.$get(this.api.addNewCustomersByOneself, form).then(res => { |
|
|
|
|
this.customerVisible = false |
|
|
|
|
this.submiting = false |
|
|
|
|
this.$message.success('添加成功') |
|
|
|
|
this.form.schoolId = res.schoolId |
|
|
|
|
this.getSchoolData() |
|
|
|
|
}).catch((res) => { |
|
|
|
|
this.submiting = false |
|
|
|
|
}) |
|
|
|
|
}, |
|
|
|
|
// 获取产品分类 |
|
|
|
|
getCategory () { |
|
|
|
|
this.$get(this.api.productCategoryList).then(res => { |
|
|
|
@ -675,7 +1007,7 @@ export default { |
|
|
|
|
filterForm2 () { |
|
|
|
|
const list = this.productAll |
|
|
|
|
const { productType, status, keyword } = this.form2 |
|
|
|
|
this.products = list.filter(e => (productType === '' || productType === e.productType) && (e.status === status || status === '全部') && e.productName.includes(keyword)) |
|
|
|
|
this.products = list.filter(e => (productType === '' || productType === e.productType) && (e.status === status || status === '全部') && (!e.goodsName || (e.goodsName && e.goodsName.includes(keyword)))) |
|
|
|
|
}, |
|
|
|
|
// 已订阅产品导出 |
|
|
|
|
exportList () { |
|
|
|
@ -790,10 +1122,9 @@ export default { |
|
|
|
|
}, |
|
|
|
|
// 获取城市 |
|
|
|
|
getCityData () { |
|
|
|
|
let data = { |
|
|
|
|
this.$get(this.api.queryCity, { |
|
|
|
|
provinceId: this.form.provinceId |
|
|
|
|
} |
|
|
|
|
this.$get(this.api.queryCity,data).then(res => { |
|
|
|
|
}).then(res => { |
|
|
|
|
this.cityList = res.list |
|
|
|
|
}).catch(res => { }); |
|
|
|
|
}, |
|
|
|
@ -1023,15 +1354,16 @@ export default { |
|
|
|
|
} |
|
|
|
|
.radio_icon { |
|
|
|
|
font-size: 26px; |
|
|
|
|
color: #9278FF; |
|
|
|
|
color: #9278ff; |
|
|
|
|
} |
|
|
|
|
/deep/.warning { |
|
|
|
|
margin-left: 5px; |
|
|
|
|
color: #9278FF; |
|
|
|
|
color: #9278ff; |
|
|
|
|
} |
|
|
|
|
.tags { |
|
|
|
|
border: none; |
|
|
|
|
background: none;color: #000; |
|
|
|
|
background: none; |
|
|
|
|
color: #000; |
|
|
|
|
white-space: pre-wrap; |
|
|
|
|
overflow: hidden; |
|
|
|
|
text-overflow: ellipsis; |
|
|
|
@ -1046,4 +1378,10 @@ export default { |
|
|
|
|
width: 100%; |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
.plus-cus { |
|
|
|
|
margin-left: 10px; |
|
|
|
|
font-size: 18px; |
|
|
|
|
color: #666; |
|
|
|
|
cursor: pointer; |
|
|
|
|
} |
|
|
|
|
</style> |
|
|
|
|