diff --git a/.env.development b/.env.development index 3e05c9a..f97c926 100644 --- a/.env.development +++ b/.env.development @@ -2,8 +2,9 @@ ENV = 'development' # 接口地址 # VUE_APP_BASE_API = 'http://192.168.2.128:8000' // 刘一帆 -VUE_APP_BASE_API = 'http://192.168.2.98:8000' -# VUE_APP_BASE_API = 'https://cashieradmin.sxczgkj.cn' +# VUE_APP_BASE_API = 'http://192.168.2.98:8000' // 公司测试 +# VUE_APP_BASE_API = 'http://192.168.2.96:8000' // 阿伟 +VUE_APP_BASE_API = 'https://cashieradmin.sxczgkj.cn' # VUE_APP_BASE_API = 'http://192.168.2.16:8000' VUE_APP_WS_API = 'ws://192.168.2.128:8000' diff --git a/src/api/order.js b/src/api/order.js new file mode 100644 index 0000000..173db70 --- /dev/null +++ b/src/api/order.js @@ -0,0 +1,34 @@ +import request from '@/utils/request' + +/** + * 查询订单 + * @param {*} data + * @returns + */ +export function tbOrderInfoData(data) { + return request({ + url: '/api/tbOrderInfo/date', + method: 'post', + data: { + shopId: localStorage.getItem('shopId'), + ...data + } + }) +} + +/** + * 导出数据 + * @param {*} data + * @returns + */ +export function tbOrderInfoDownload(data) { + return request({ + url: '/api/tbOrderInfo/download', + method: 'post', + data: { + shopId: localStorage.getItem('shopId'), + ...data + }, + responseType: 'blob' + }) +} \ No newline at end of file diff --git a/src/components/classify/index.vue b/src/components/classify/index.vue index 742fb33..54359fc 100644 --- a/src/components/classify/index.vue +++ b/src/components/classify/index.vue @@ -5,7 +5,7 @@
{{ item.name }}
全部 - {{ val.name }}
@@ -58,9 +58,12 @@ export default { }, // 选择分类 selectHandle(item, index = -1) { + console.log(item, index) if (index != -1) { - this.categorys[index].childrenList.map(val => { - val.active = false + this.categorys[index].active = false + } else { + item.childrenList.map(item => { + item.active = false }) } item.active = !item.active diff --git a/src/components/shopList/index.vue b/src/components/shopList/index.vue index 21ae13f..5d44d02 100644 --- a/src/components/shopList/index.vue +++ b/src/components/shopList/index.vue @@ -11,8 +11,8 @@ - 查询 - 重置 + 查询 + 重置
@@ -31,13 +31,11 @@ - - @@ -46,7 +44,8 @@
+ @current-change="paginationChange" @size-change="sizeChange" + layout="total, sizes, prev, pager, next, jumper"> 取 消 确 定 @@ -87,12 +86,18 @@ export default { this.searhForm.name = '' this.searhForm.category = '' this.tableData.page = 0 + this.tableData.size = 10 this.tableData.list = [] this.getTableData() }, + // 分页大小改变 + sizeChange(e) { + this.tableData.size = e + this.getTableData() + }, // 分页回调 paginationChange(e) { - this.tableData.page = e + this.tableData.page = e - 1 this.getTableData() }, // 商品列表 @@ -102,6 +107,8 @@ export default { const res = await tbProduct({ page: this.tableData.page, size: this.tableData.size, + name: this.searhForm.name, + categoryId: this.searhForm.category, shopId: localStorage.getItem('shopId'), sort: 'id', }) @@ -140,6 +147,7 @@ export default { this.goods = [] } this.resetHandle() + this.tbShopCategoryGet() this.getTableData() }, close() { diff --git a/src/components/uploadImg/index.vue b/src/components/uploadImg/index.vue index 3f039e5..306fb0d 100644 --- a/src/components/uploadImg/index.vue +++ b/src/components/uploadImg/index.vue @@ -14,6 +14,7 @@ + + \ No newline at end of file diff --git a/src/views/product/add_shop.vue b/src/views/product/add_shop.vue index 610b694..309bcf2 100644 --- a/src/views/product/add_shop.vue +++ b/src/views/product/add_shop.vue @@ -43,7 +43,6 @@ - -