pull/4/head
parent
0907d1c436
commit
a62d49e078
|
@ -1,6 +1,7 @@
|
|||
<template>
|
||||
<div class="app-container home">
|
||||
|
||||
<iframe width="680" height="260" frameborder="0" scrolling="no" hspace="0" src="https://i.tianqi.com/?c=code&a=getcode&id=13&icon=1&py=pudong"/>
|
||||
<iframe width="550" height="300" frameborder="0" scrolling="no" hspace="0" src=" https://www.beijing-time.org/"/>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
|
|
|
@ -1,84 +1,140 @@
|
|||
<template>
|
||||
<div>
|
||||
<el-table
|
||||
:data="tableData"
|
||||
style="width: 100%">
|
||||
<el-table-column
|
||||
prop="date"
|
||||
label="日期"
|
||||
width="150">
|
||||
</el-table-column>
|
||||
<el-card class="box-card" style="width: 94%;transform: translateX(3%);margin-top: 30px">
|
||||
<div slot="header" class="clearfix">
|
||||
<span>筛选搜索</span>
|
||||
<el-button style="float: right; padding: 3px 30px" type="text" @click="findShop">查询结果</el-button>
|
||||
<el-button style="float: right; padding: 3px 10px" type="text" @click="chong">重置</el-button>
|
||||
</div>
|
||||
<div class="text item">
|
||||
<el-form ref="form" :model="shop" label-width="100px">
|
||||
<el-form-item>
|
||||
输入搜索:<el-input v-model="shop.shopName" placeholder="商品名称" style="width: 180px;margin-right: 50px"></el-input>
|
||||
订单编号:<el-input v-model="shop.shopNum" placeholder="编号" style="width: 180px;margin-right: 50px"></el-input>
|
||||
订单分类:<el-cascader
|
||||
placeholder="请选择"
|
||||
v-model="typeId"
|
||||
:options="type"
|
||||
:props=Cascader
|
||||
@change="shopTypeId(shop.typeId)" clearable
|
||||
></el-cascader>
|
||||
<el-select v-model="shop.brandId" placeholder="请选择商品" style="margin-right: 30px" clearable>
|
||||
<el-option v-for="item in dict.type.pms_shop_brandid" :label="item.label" :value="item.value" :key="item.value"></el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item>
|
||||
订单状态:<el-select v-model="shop.publishStatus" placeholder="请选择上架状态" style="margin-right: 30px" clearable>
|
||||
<el-option v-for="item in dict.type.pms_shop_publiststatus" :label="item.label" :value="item.value" :key="item.value"></el-option>
|
||||
</el-select>
|
||||
审核状态:<el-select v-model="shop.verifyStatus" placeholder="请选择审核状态" style="margin-right: 30px" clearable>
|
||||
<el-option v-for="item in dict.type.pms_shop_verifystatus" :label="item.label" :value="item.value" :key="item.value"></el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
</div>
|
||||
</el-card>
|
||||
|
||||
<el-table-column label="购买信息">
|
||||
<el-table-column
|
||||
prop="name"
|
||||
label="账号"
|
||||
width="120">
|
||||
|
||||
<el-card class="box-card" style="width: 94%;transform: translateX(3%);margin-top: 10px">
|
||||
<div slot="header" class="clearfix">
|
||||
<span>数据列表</span>
|
||||
<button @click="add" style="float: right; padding: 3px 10px" type="text">添加</button>
|
||||
</div>
|
||||
|
||||
<el-table :data="arr" style="width: 100%" @selection-change="handleSelectionChange">
|
||||
<el-table-column type="selection" width="55"></el-table-column>
|
||||
<el-table-column label="日期" width="120" align="center">
|
||||
<template slot-scope="scope">
|
||||
<span style="margin-left: 10px">{{ scope.row.ordersLaunchdate }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="name"
|
||||
label="名称"
|
||||
width="120">
|
||||
<el-table-column label="购买信息">
|
||||
<el-table-column label="订单编号" width="150" align="center">
|
||||
<template slot-scope="scope">
|
||||
<span style="margin-left: 10px">订单编号: {{ scope.row.ordersNum }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="订单所属人" width="120" align="center">
|
||||
<template slot-scope="scope">
|
||||
<span style="margin-left: 10px">{{ scope.row.userName }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
|
||||
<el-table-column label="购买详情">
|
||||
<el-table-column
|
||||
prop="province"
|
||||
label="购买接口"
|
||||
width="120">
|
||||
<el-table-column prop="province" label="购买接口" width="120" align="center">
|
||||
<template slot-scope="scope">
|
||||
<span style="margin-left: 10px">{{ scope.row.productName }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="city"
|
||||
label="购买类型"
|
||||
width="120">
|
||||
|
||||
<el-table-column label="订单金额" width="150" align="center">
|
||||
<template slot-scope="scope">
|
||||
<span style="margin-left: 10px">{{ scope.row.ordersPrice }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="address"
|
||||
label="购买方式"
|
||||
width="300">
|
||||
<el-table-column label="订单规格" width="300" align="center">
|
||||
<template slot-scope="scope">
|
||||
<span style="margin-left: 10px">{{ scope.row.ordersSpecification }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="zip"
|
||||
label="总金额"
|
||||
width="120">
|
||||
<el-table-column label="订单款项状态" width="150" align="center">
|
||||
<template slot-scope="scope">
|
||||
<span style="margin-left: 10px" v-if="scope.row.ordersState==0">待支付</span>
|
||||
<span style="margin-left: 10px" v-if="scope.row.ordersState==1">已付款</span>
|
||||
<span style="margin-left: 10px" v-if="scope.row.ordersState==2">未付款</span>
|
||||
<span style="margin-left: 10px" v-if="scope.row.ordersState==4">售后(申请退款)</span>
|
||||
<span style="margin-left: 10px" v-if="scope.row.ordersState==5">已退款</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="zip"
|
||||
label="是否已经完成付款"
|
||||
width="120">
|
||||
<el-table-column label="操作" align="center">
|
||||
<template slot-scope="scope">
|
||||
<el-button
|
||||
size="mini"
|
||||
@click="handleEdit(scope.row)">编辑</el-button>
|
||||
<el-button
|
||||
size="mini"
|
||||
type="danger"
|
||||
@click="handleDelete(scope.row)">删除</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table-column>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
</el-card>
|
||||
<!-- <el-pagination style="float: right"-->
|
||||
<!-- @size-change="handleSizeChange"-->
|
||||
<!-- @current-change="handleCurrentChange"-->
|
||||
<!-- :current-page="shop.pageNum"-->
|
||||
<!-- :page-sizes="[2, 4, 6, 8]"-->
|
||||
<!-- :page-size="shop.pageSize"-->
|
||||
<!-- layout="total, sizes, prev, pager, next, jumper"-->
|
||||
<!-- :total="shop.total">-->
|
||||
<!-- </el-pagination>-->
|
||||
|
||||
</div>
|
||||
|
||||
</template>
|
||||
|
||||
|
||||
|
||||
<script>
|
||||
import { selectList, update } from '@/api/market/orders'
|
||||
import {handleDelete} from "@/api/market/product";
|
||||
import { diGui } from "@/api/market/orders";
|
||||
//这里可以导入其他文件(比如:组件,工具js,第三方插件js,json文件,图片文件等等),
|
||||
//例如:import 《组件名称》 from '《组件路径》,
|
||||
import axios from 'axios'; // 假设你正在使用axios进行HTTP请求
|
||||
|
||||
export default {
|
||||
dicts:[''],
|
||||
dicts:['pms_shop_typeid','pms_shop_publiststatus','pms_shop_brandid','pms_shop_verifystatus'],
|
||||
//import引入的组件需要注入到对象中才能使用"
|
||||
components: {},
|
||||
props: {},
|
||||
data() {
|
||||
//这里存放数据"
|
||||
|
||||
return {
|
||||
orders:{
|
||||
shop:{
|
||||
pageNum:1,
|
||||
pageSize:5,
|
||||
total:1,
|
||||
typeId:0
|
||||
},
|
||||
tableData: [], // 初始化为空数组,等待异步数据填充
|
||||
arr:[],
|
||||
type:[],
|
||||
Cascader:{ expandTrigger:'hover',value:'id',label:'typeName',children:'parentPOS' },
|
||||
|
@ -94,20 +150,20 @@ export default {
|
|||
// 商品分类下拉框
|
||||
shopTypeId(){
|
||||
for (let i = 0; i < this.typeId.length; i++) {
|
||||
this.orders.typeId=this.typeId[i]
|
||||
this.shop.typeId=this.typeId[i]
|
||||
}
|
||||
},
|
||||
/**递归*/
|
||||
diGui(){
|
||||
diGui(this.orders.typeId).then(
|
||||
diGui(this.shop.typeId).then(
|
||||
res => {
|
||||
this.type=res.data
|
||||
}
|
||||
)
|
||||
},
|
||||
// 删除
|
||||
handleDelete(orders){
|
||||
handleDelete(orders.id).then(
|
||||
handleDelete(shop){
|
||||
handleDelete(shop.id).then(
|
||||
res => {
|
||||
this.$message.success(res.msg)
|
||||
this.page()
|
||||
|
@ -116,21 +172,21 @@ export default {
|
|||
},
|
||||
// 重置
|
||||
chong(){
|
||||
this.orders={}
|
||||
this.shop={}
|
||||
this.page()
|
||||
},
|
||||
// 分页
|
||||
handleSizeChange(val) {
|
||||
this.orders.pageSize=val
|
||||
this.shop.pageSize=val
|
||||
this.page()
|
||||
},
|
||||
handleCurrentChange(val) {
|
||||
this.orders.pageNum=val
|
||||
this.shop.pageNum=val
|
||||
this.page()
|
||||
},
|
||||
// 上架,新品,推荐修改
|
||||
updateShop(orders){
|
||||
update(orders).then(
|
||||
updateShop(shop){
|
||||
update(shop).then(
|
||||
res => {
|
||||
this.$message.success(res.msg)
|
||||
this.page()
|
||||
|
@ -138,15 +194,15 @@ export default {
|
|||
)
|
||||
},
|
||||
// 修改跳转路径
|
||||
handleEdit(orders){
|
||||
if (this.orders.serviceIds && typeof this.orders.serviceIds === 'string') {
|
||||
orders.serviceid = this.orders.serviceIds.split(',');
|
||||
handleEdit(shop){
|
||||
if (this.shop.serviceIds && typeof this.shop.serviceIds === 'string') {
|
||||
shop.serviceid = this.shop.serviceIds.split(',');
|
||||
// ... 后续操作
|
||||
}
|
||||
console.log(JSON.stringify(orders))
|
||||
orders.serviceid=orders.serviceIds.split(',').map(id => parseInt(id, 10));
|
||||
console.log(JSON.stringify(orders))
|
||||
this.$router.push({path:'/product/info/update',query:{orders:orders}})
|
||||
console.log(JSON.stringify(shop))
|
||||
shop.serviceid=shop.serviceIds.split(',').map(id => parseInt(id, 10));
|
||||
console.log(JSON.stringify(shop))
|
||||
this.$router.push({path:'/product/info/update',query:{shop:shop}})
|
||||
},
|
||||
// 查询
|
||||
findShop(){
|
||||
|
@ -161,34 +217,24 @@ export default {
|
|||
this.multipleSelection = val;
|
||||
},
|
||||
//商品列表
|
||||
// selectList(){
|
||||
// selectList(this.orders).then(
|
||||
// res => {
|
||||
// console.log(res)
|
||||
// this.arr=res.data.list
|
||||
// this.orders.total=res.data.total
|
||||
// }
|
||||
// )
|
||||
// }.
|
||||
|
||||
selectList(){
|
||||
selectList().then(
|
||||
selectList(data).then(
|
||||
res => {
|
||||
this.typeList = res.data
|
||||
console.log(res)
|
||||
this.arr=res.data.list
|
||||
this.shop.total=res.data.total
|
||||
}
|
||||
)
|
||||
}
|
||||
},
|
||||
//生命周期 - 创建完成(可以访问当前this实例)",
|
||||
created() {
|
||||
this.selectList()
|
||||
this.page()
|
||||
this.diGui()
|
||||
this.fetchData(); // 组件创建后立即获取数据
|
||||
|
||||
this.selectList()
|
||||
},
|
||||
//生命周期 - 挂载完成(可以访问DOM元素)",
|
||||
mounted() {
|
||||
|
||||
},
|
||||
beforeCreate() {
|
||||
}, //生命周期 - 创建之前",
|
||||
|
|
|
@ -8,6 +8,101 @@
|
|||
<el-step title="选择商品关联"></el-step>
|
||||
</el-steps>
|
||||
|
||||
|
||||
|
||||
|
||||
<el-card class="box-card" style="width: 94%;transform: translateX(3%);margin-top: 30px">
|
||||
<el-table :data="arr" style="width: 100%" @selection-change="handleSelectionChange">
|
||||
<el-table-column type="selection" width="55"></el-table-column>
|
||||
<el-table-column label="编号" width="80" align="center">
|
||||
<template slot-scope="scope">
|
||||
<span style="margin-left: 10px">{{ scope.row.id }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="商品图片" width="150" align="center">
|
||||
<template slot-scope="scope">
|
||||
<img :src="scope.row.picImg" alt="图片损坏">
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="商品名称" width="400" align="center">
|
||||
<template slot-scope="scope">
|
||||
<span style="margin-left: 10px">{{ scope.row.shopName }}</span>
|
||||
<br>
|
||||
品牌:<span style="margin-left: 10px">{{ scope.row.brandName }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="货号" width="150" align="center">
|
||||
<template slot-scope="scope">
|
||||
<span style="margin-left: 10px">货号:{{ scope.row.shopNum }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="标签" width="150" align="center">
|
||||
<template slot-scope="scope">
|
||||
上架:
|
||||
<el-switch
|
||||
v-model="scope.row.publishStatus"
|
||||
@change="updateShop(scope.row)"
|
||||
active-color="#409EFF"
|
||||
inactive-color="#C0CCDA"
|
||||
:active-value="1"
|
||||
:inactive-value="0">
|
||||
</el-switch>
|
||||
<br>
|
||||
新品:
|
||||
<el-switch
|
||||
v-model="scope.row.newStatus"
|
||||
@change="updateShop(scope.row)"
|
||||
active-color="#409EFF"
|
||||
inactive-color="#C0CCDA"
|
||||
:active-value="1"
|
||||
:inactive-value="0">
|
||||
</el-switch>
|
||||
<br>
|
||||
推荐:
|
||||
<el-switch
|
||||
v-model="scope.row.recommandStatus"
|
||||
@change="updateShop(scope.row)"
|
||||
active-color="#409EFF"
|
||||
inactive-color="#C0CCDA"
|
||||
:active-value="1"
|
||||
:inactive-value="0">
|
||||
</el-switch>
|
||||
<br>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="排序" width="150" align="center">
|
||||
<template slot-scope="scope">
|
||||
<span style="margin-left: 10px">{{ scope.row.sort }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="销量" width="150" align="center">
|
||||
<template slot-scope="scope">
|
||||
<span style="margin-left: 10px">{{ scope.row.sale }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="审核状态" width="150" align="center">
|
||||
<template slot-scope="scope">
|
||||
<span style="margin-left: 10px" v-if="scope.row.verifyStatus==0">未审核</span>
|
||||
<span style="margin-left: 10px" v-if="scope.row.verifyStatus==1">审核通知</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="操作" align="center">
|
||||
<template slot-scope="scope">
|
||||
<el-button
|
||||
size="mini"
|
||||
@click="handleEdit(scope.row)">编辑</el-button>
|
||||
<el-button
|
||||
size="mini"
|
||||
type="danger"
|
||||
@click="handleDelete(scope.row)">删除</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
</el-card>
|
||||
|
||||
|
||||
|
||||
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
|
|
Loading…
Reference in New Issue