商城订单

main
bibi 3 years ago
parent 8318c11546
commit 18083f5080

@ -1,6 +1,7 @@
import httpService from "@/request"
// 工单
// list
export function name(params) {
return httpService({
url: ` `,

@ -1,5 +1,6 @@
import httpService from "@/request"
// 组织
// 所有的组织架构
export function departmentList(params) {
return httpService({

@ -1,5 +1,6 @@
import httpService from "@/request"
// 房产 楼栋
// 楼栋列表
export function buildingList(params) {
return httpService({
@ -8,6 +9,15 @@ export function buildingList(params) {
params: params,
})
}
// 楼栋删除
export function buildingDel(params) {
return httpService({
url: `/user/building/deleteBuilding`,
method: 'post',
data: params,
})
}
// 房屋列表
export function houseList(params) {
return httpService({
@ -16,3 +26,27 @@ export function houseList(params) {
params: params,
})
}
// 房屋列表
export function houseInsert(params) {
return httpService({
url: `/user/estate/insert`,
method: 'post',
data: params,
})
}
// 房屋删除
export function houseDel(params) {
return httpService({
url: `/user/estate/delete`,
method: 'post',
data: params,
})
}
// 房屋租聘切换
export function isEnableLease(params) {
return httpService({
url: `/user/estate/isEnableLease`,
method: 'get',
params: params,
})
}

@ -0,0 +1,11 @@
import httpService from "@/request"
// 订单
// list
export function orderList(params) {
return httpService({
url: `/user/shopOrder/list`,
method: 'get',
params: params,
})
}

@ -12,6 +12,7 @@ router.beforeEach((to, from, next) => {
next('/login');
} else {
next();
NProgress.done()
}
})

@ -26,17 +26,17 @@ export default [
hide: false,
component: resolve => require(['@/views/Basic/Authority'], resolve),
meta: {title: '权限管理'},
children: [
{
path: '/Authority/_details',
name: "Authority_details",
title: "账单管理-详情",
icon: 'profile',
hide: true,
component: resolve => require(['@/views/Basic/Authority/_details'], resolve),
meta: {title: '账单管理-详情'},
}
]
// children: [
// {
// path: '/Authority/_details',
// name: "Authority_details",
// title: "账单管理-详情",
// icon: 'profile',
// hide: true,
// component: resolve => require(['@/views/Basic/Authority/_details'], resolve),
// meta: {title: '账单管理-详情'},
// }
// ]
},
{
path: '/EstateInfo',

@ -18,7 +18,7 @@ Vue.use(Router);
import Layout from "@/views/Layout"
import basic from "./basic" // 基础功能
// import payment from "./payment" // 缴费管理
// import smartMall from "./smartMall" // 智慧商城
import shop from "./shop" // 智慧商城
// import operation from "./operation" // 运营管理
import setting from "./setting" // 设置
@ -45,6 +45,17 @@ const router = [
...setting,
]
},
{
path: "/shop",
name: "shop",
title: "智慧商城",
component: Layout,
redirect: '/OrderManage',
meta: {title: '智慧商城'},
children: [
...shop,
]
},
{
path: "/login",
name: "Login",

@ -6,4 +6,14 @@
* @Description: 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
* @FilePath: /LittleBeeSaas/src/router/smartMall.js
*/
export default []
export default [
{
path: '/OrderManage',
name: "OrderManage",
title: "订单列表",
hide: false,
icon: 'container',
component: resolve => require(['@/views/Shop/OrderManage'], resolve),
meta: {title: '订单列表'}
},
]

@ -67,17 +67,13 @@ export default {
},
data() {
return {
pagination,
columns,
searchForm,
tableChoosed: [],
roleList: [],
//
pagination: pagination,
//
columns: columns,
searchForm:searchForm,
//
tableData: [],
ActionsList: [
],
tableData: [], //
ActionsList: [],
};
},
mounted() {

@ -6,12 +6,12 @@ export const columns = [
{
title: "真实名称",
dataIndex: "actualName",
width: "16%",
width: "12%",
},
{
title: "手机号",
dataIndex: "tel",
width: "16%",
width: "14%",
},
{
title: "所属部门",
@ -21,7 +21,22 @@ export const columns = [
{
title: "岗位",
dataIndex: "positionName",
width: "10%",
},
{
title: "状态",
dataIndex: "status",
width: "16%",
customRender: function (status) {
switch (status) {
case 1:
return '正常'
case 2:
return '停用'
default:
break;
}
}
},
{
title: "备注",

@ -90,6 +90,7 @@
<span slot="action" slot-scope="text,scope">
<a-space size="small">
<a class="ant-dropdown-link" @click="edit(scope)"></a>
<a-switch @change="enableUser(scope.id)" :checked='scope.status ===1'></a-switch>
<a class="ant-dropdown-link" @click="resetPsw(scope.id)"></a>
</a-space>
</span>
@ -209,7 +210,8 @@ import {
departmentUpdate,
departmentDel,
findToUser,
rePassword
rePassword,
userEnable
} from "@/api/basic/department";
export default {
@ -218,9 +220,9 @@ export default {
},
data() {
return {
columns: columns,
pagination: pagination,
searchForm: searchForm,
columns,
pagination,
searchForm,
searchStr: "",
searchValue: "",
rules: {
@ -363,6 +365,15 @@ export default {
});
}
},
async enableUser(id){
const res = await userEnable({manageUserId:id})
if(res.code === 200){
this.$message.success(res.msg)
this.getData()
}else{
this.$message.error(res.msg)
}
},
handleCancel() {
this.show.addDepartment = false;
this.$refs.ruleForm.resetFields();

@ -26,7 +26,7 @@
<template v-slot:actionBox="data">
<a-space size="small">
<a class="ant-dropdown-link" @click='detail(data)'>详情</a>
<a class="ant-dropdown-link" @click='del(data)'>删除</a>
<a class="ant-dropdown-link" @click='del([data.data.id])'>删除</a>
</a-space>
</template>
</commonTable>
@ -136,10 +136,13 @@
<script>
import { columns,pagination,searchForm} from "./depend/config"
import { buildingList } from "@/api/basic/estate"
import { buildingList,buildingDel } from "@/api/basic/estate"
export default {
data() {
return {
pagination,
columns,
searchForm,
drawerConfig:{
addShow:false,
detailShow:false,
@ -154,26 +157,8 @@ export default {
name:[{required:true,message:'请输入楼栋',trigger:'blur'}],
fileList:[{required:true}]
},
fileList: [
{
uid: '-1',
name: 'xxx.png',
url: 'https://zos.alipayobjects.com/rmsportal/jkjgkEfvpUPVyRjUImniVslZfWPnJuuZ.png',
},
{
uid: '-2',
name: 'yyy.png',
status: 'done',
url: 'https://zos.alipayobjects.com/rmsportal/jkjgkEfvpUPVyRjUImniVslZfWPnJuuZ.png',
thumbUrl: 'https://zos.alipayobjects.com/rmsportal/jkjgkEfvpUPVyRjUImniVslZfWPnJuuZ.png',
},
],
fileList: [],
tableChoosed: [],
//
pagination: pagination,
//
columns:columns,
searchForm:searchForm,
unitData:[],
unitColumns: [
{
@ -222,10 +207,6 @@ export default {
label: "批量删除",
value: 1,
},
{
label: "批量导出",
value: 2,
},
],
};
},
@ -274,19 +255,30 @@ export default {
pager.pageSize = pagination.pageSize;
this.pagination = pager;
},
del(data) {
del(ids) {
this.$confirm({
title: "是否删除",
// okText:'',
// cancelText:'',
icon: "",
onOk: function () {
console.log(data);
buildingDel({buildingIds:ids}).then(res=>{
if(res.code === 200){
this.$message.success(res.msg)
}else{
this.$message.error(res.msg)
}
})
},
});
},
Actions(data) {
console.log(data);
let ids =[]
for(const item of this.tableChoosed){
ids.push(item.id)
}
//
if(data===1){
this.del(ids)
}
},
selectionChoosed(data) {
console.log(data);

@ -59,14 +59,3 @@ export const pagination = {
showSizeChanger: true,
showQuickJumper: true,
}
export function del(data) {
this.$confirm({
title: "是否删除",
// okText:'删除',
// cancelText:'取消',
icon: "",
onOk: function () {
console.log(data);
},
});
}

@ -48,7 +48,7 @@
:scroll="{ x: 1300 }"
:row-selection="{
selectedRowKeys: selectedRowKeys,
onChange: selectionChoosed,
onChange: onSelectChange,
}"
:row-key="
(record, index) => {
@ -71,7 +71,7 @@
<span slot="action" slot-scope="text, row">
<a-space>
<a class="ant-dropdown-link" @click='edit(row)'>编辑</a>
<a class="ant-dropdown-link" @click='del(row)'>删除</a>
<a class="ant-dropdown-link" @click='del([row.id])'>删除</a>
</a-space>
</span>
<span slot="tags" slot-scope="tag">
@ -82,7 +82,7 @@
</a-tag>
</span>
<span slot="switch" slot-scope="switchV, row">
<a-switch :checked="switchV === 1" @change="enable(row)"></a-switch>
<a-switch :checked="switchV === 1" @change="handleEnable(row)"></a-switch>
</span>
</a-table>
</div>
@ -250,8 +250,8 @@ function getBase64(file) {
reader.onerror = error => reject(error);
});
}
import { columns,pagination,searchForm, del } from "./depend/config"
import { houseList } from '@/api/basic/estate'
import { columns,pagination,searchForm } from "./depend/config"
import { houseList, houseDel, isEnableLease} from '@/api/basic/estate'
export default {
data() {
return {
@ -324,10 +324,10 @@ export default {
label: "批量删除",
value: 1,
},
{
label: "批量导出",
value: 2,
},
// {
// label: "",
// value: 2,
// },
],
};
},
@ -361,8 +361,16 @@ export default {
handleChange({ fileList }) {
this.fileList = fileList;
},
enable(data) {
console.log(data);
handleEnable: async function(data) {
const res = await isEnableLease({
estateId:data.id
})
if(res.code===200){
this.$message.success(res.msg)
this.getData()
}else{
this.$message.error(res.msg)
}
},
handleTableChange(pagination) {
console.log(pagination);
@ -371,17 +379,30 @@ export default {
pager.pageSize = pagination.pageSize;
this.pagination = pager;
},
// del(data) {
// },
del:del,
del(ids) {
this.$confirm({
title: "是否删除",
icon: "",
onOk: function () {
houseDel({estateIds:ids}).then(res=>{
if(res.code === 200){
this.$message.success(res.msg)
}else{
this.$message.error(res.msg)
}
})
},
});
},
Actions(data) {
console.log(data);
this.activeAction = undefined;
//
if(data===1){
this.del(this.selectedRowKeys)
this.activeAction = undefined;
}
},
selectionChoosed(data) {
console.log(data);
this.tableChoosed = data;
onSelectChange(selectedRowKeys) {
this.selectedRowKeys = selectedRowKeys;
},
addClose(){
this.drawerConfig.addShow = false;

@ -43,15 +43,21 @@ export default {
components: {
yMenu,
},
mounted(){
this.$router.push({ name: sessionStorage.getItem('routerName') });
this.tagActive = Number(sessionStorage.getItem('index'))
},
watch: {
$route: {
handler(val) {
this.tags = val.matched;
sessionStorage.setItem('routerName',val.name)
},
immediate: true,
},
tagActive:{
handler(val) {
// console.log(val);
sessionStorage.setItem('modal',this.menuTags[val].value)
},
immediate: true,
@ -66,13 +72,13 @@ export default {
label: "基础功能",
value: "basic"
},
{
label: "缴费管理",
value: "payment"
},
// {
// label: "",
// value: "payment"
// },
{
label: "智慧商城",
value: "smartMall"
value: "shop"
},
// {
// label: "",
@ -92,6 +98,7 @@ export default {
},
handlerTags(n) {
this.tagActive = n;
sessionStorage.setItem('index',n)
}
},
};

@ -104,7 +104,6 @@ export default {
handlerSelect({selectedKeys}) {
this.selectedKeys = selectedKeys;
this.setSelectedKeys(selectedKeys);
},
handlerOpen(val) {
this.setOpenKeys(val);
@ -140,7 +139,7 @@ export default {
icon: arr[i].icon || ''
}
menus.push(obj)
}
}
if(arr[i].children) {
let obj = {
key: this.indexPath,
@ -156,7 +155,7 @@ export default {
}
// console.log(menus);
}
}
};
</script>

@ -0,0 +1,154 @@
/**
* 配置
* 表格列
*/
export const columns = [
{
title: "订单号",
dataIndex: "code",
width: "15%",
},
{
title: "创建时间",
dataIndex: "createDate",
width: "15%",
},
{
title: "付款方式",
dataIndex: "payType",
width: "15%",
customRender: function (payType) {
switch (payType) {
case 1:
return '支付宝'
case 2:
return '微信'
case 3:
return '现金'
case 4:
return 'pos'
case 5:
return '预缴扣除'
case 6:
return '银行卡'
case 7:
return '支票'
case 8:
return '转账'
case 9:
return '开发商代付'
default:
break;
}
}
},
// {
// title: "jcook订单号",
// dataIndex: "jcookCode",
// width: "15%",
// },
// {
// title: "支付宝交易号",
// dataIndex: "tradeNo",
// width: "15%",
// },
// {
// title: "交易状态",
// dataIndex: "tradeStatus",
// width: "15%",
// },
// {
// title: "支付人名称",
// dataIndex: "payName",
// width: "15%",
// },
// {
// title: "支付人联系方式",
// dataIndex: "payTel",
// width: "15%",
// },
// {
// title: "付款方式",
// dataIndex: "payType",
// width: "15%",
// },
// {
// title: "付款金额",
// dataIndex: "payPrice",
// width: "15%",
// },
// {
// title: "运费",
// dataIndex: "freightFee",
// width: "15%",
// },
// {
// title: "收货人",
// dataIndex: "receiverName",
// width: "15%",
// },
// {
// title: "收货人联系方式",
// dataIndex: "receiverTel",
// width: "15%",
// },
// {
// title: "所在地区名称",
// dataIndex: "locationName",
// width: "15%",
// },
// {
// title: "详细地址",
// dataIndex: "addressDetail",
// width: "15%",
// },
// {
// title: "运费",
// dataIndex: "freightFee",
// width: "15%",
// },
// {
// title: "运费",
// dataIndex: "freightFee",
// width: "15%",
// },
// {
// title: "房屋类型",
// dataIndex: "manageEstateTypeName",
// width: "15%",
// },
{
title: "操作",
dataIndex: "action",
key: "action",
width: "180",
fixed: "right",
scopedSlots: { customRender: "action" },
},
]
// 搜索项
export const searchForm = {
code: "",
jcookCode: '',
tradeStatus:null
}
// 分页
export const pagination = {
current: 1,
total: 0,
pageSize: 10,
showTotal: (total) => `${total}`,
showSizeChanger: true,
showQuickJumper: true,
}
export function del(data) {
this.$confirm({
title: "是否删除",
// okText:'删除',
// cancelText:'取消',
icon: "",
onOk: function () {
console.log(data);
},
});
}

@ -0,0 +1,147 @@
<template>
<div>
<div class="cardTitle">订单列表</div>
<div class="search-box">
<a-row>
<a-col :span="20">
<a-space size="large">
<a-input style="width: 200px" placeholder="请输入订单号" />
<a-input style="width: 200px" placeholder="请输入jcook订单号" />
<a-select style="width: 200px" v-model="searchForm.tradeStatus" placeholder="请选择交易状态" ></a-select>
<a-button type="primary" @click='getData'> </a-button>
<a-button> </a-button>
</a-space>
</a-col>
<a-col :span="4">
<!-- <a-button class="add-btn" @click="">添加</a-button> -->
</a-col>
</a-row>
</div>
<a-table :columns="columns" :data-source="tableData" :rowKey="record=>record.id">>
<div slot="expandedRowRender" slot-scope="record" class="orderInfo">
<a-descriptions title="商品信息">
<a-descriptions-item label="UserName">
{{record.freightFee}}
</a-descriptions-item>
<a-descriptions-item label="Telephone">
1810000000
</a-descriptions-item>
<a-descriptions-item label="Live">
Hangzhou, Zhejiang
</a-descriptions-item>
<a-descriptions-item label="Remark">
empty
</a-descriptions-item>
<a-descriptions-item label="Address">
No. 18, Wantang Road, Xihu District, Hangzhou, Zhejiang, China
</a-descriptions-item>
</a-descriptions>
</div>
<span slot="action" slot-scope="text, record" class="action-col">
<a-space>
<a @click='detail(record)'>查看详情</a>
<a @click='remark(record)'>备注</a>
</a-space>
</span>
</a-table>
</div>
</template>
<script>
import { orderList } from '@/api/shop/order'
import { columns,pagination,searchForm } from './depend/config'
export default {
data() {
return {
tableData:[],
columns,
pagination,
searchForm
};
},
mounted() {
// this.getData()
this.tableData =[{
"id":1,
"code":"123456",
"jcookCode":"123131241",
"tradeNo":"12123",
"tradeStatus":1,
"payName":"张三",
"payTel":"13738611460",
"payType":1,
"payPrice":13,
"freightFee":4,
"receiverName":"王五",
"receiverTel":"13738611465",
"locationName":"宁波镇海",
"addressDetail":"深蓝大厦",
"remake":null,
"createName":"张三",
"createDate":'2022-2-2'
},{
"id":2,
"code":"123456",
"jcookCode":"123131241",
"tradeNo":"12123",
"tradeStatus":1,
"payName":"张三",
"payTel":"13738611460",
"payType":1,
"payPrice":13,
"freightFee":4,
"receiverName":"王五",
"receiverTel":"13738611465",
"locationName":"宁波镇海",
"addressDetail":"深蓝大厦",
"remake":null,
"createName":"张三",
"createDate":'2022-2-2'
},{
"id":3,
"code":"123456",
"jcookCode":"123131241",
"tradeNo":"12123",
"tradeStatus":1,
"payName":"张三",
"payTel":"13738611460",
"payType":1,
"payPrice":13,
"freightFee":4,
"receiverName":"王五",
"receiverTel":"13738611465",
"locationName":"宁波镇海",
"addressDetail":"深蓝大厦",
"remake":null,
"createName":"张三",
"createDate":'2022-2-2'
},
]
},
methods: {
async getData(){
const res = await orderList({
pageNum: this.pagination.current,
size: this.pagination.pageSize,
code:this.searchForm.code,
jcookCode:this.searchForm.jcookCode,
tradeStatus:this.searchForm.tradeStatus,
})
this.tableData = res.data.rows
}
}
};
</script>
<style lang="less" scoped>
.orderInfo{
// background-color:red;
}
/deep/tr.ant-table-expanded-row, tr.ant-table-expanded-row:hover{
// z-index: 999;
position: relative;
}
/deep/.action-col{
position: relative;
// background-color:red;
// z-index: 1;
}
</style>
Loading…
Cancel
Save