diff --git a/src/api/product.js b/src/api/product.js index 3c7c839..6416be1 100644 --- a/src/api/product.js +++ b/src/api/product.js @@ -9,56 +9,56 @@ import request from '@/utils/request' export function findAll() { return request({ url: '/sale/manage/specsType/find-all', - method: 'get', + method: 'get' }) } // 查询所有规格jxc export function findAllJxc() { return request({ url: 'scm/manage/product-bas/find-all', - method: 'get', + method: 'get' }) } // 产品属性枚举 export function productType() { return request({ url: '/system/pub/enums/get-product-attr-type', - method: 'get', + method: 'get' }) } // 发货类型 export function getShipping() { return request({ url: '/system/pub/enums/get-shipping-channel', - method: 'get', + method: 'get' }) } // 单位 export function getUnit() { return request({ url: '/system/pub/enums/get-unit', - method: 'get', + method: 'get' }) } // 销售模式 export function saleModel() { return request({ url: 'system/pub/enums/sale-model', - method: 'get', + method: 'get' }) } // 所属分类 export function classifyAll() { return request({ url: '/sale/manage/classify/find-all', - method: 'get', + method: 'get' }) } // 运输方式 export function transportType() { return request({ url: '/system/pub/enums/manager-transport-type', - method: 'get', + method: 'get' }) } // 产品新增 @@ -129,14 +129,14 @@ export function productListJxc(params) { export function productDel(id) { return request({ url: '/sale/manage/product/' + id, - method: 'delete', + method: 'delete' }) } // 删除产品jxc export function productDelJxc(id) { return request({ url: 'scm/manage/product-bas/' + id, - method: 'delete', + method: 'delete' }) } // 产品详情 @@ -215,7 +215,7 @@ export function classifyUpdate(data) { export function classifyDel(id) { return request({ url: '/sale/manage/classify/' + id, - method: 'delete', + method: 'delete' }) } // 规格类型列表 @@ -254,7 +254,7 @@ export function specsTypeUpdate(data) { export function specsTypeDel(id) { return request({ url: '/sale/manage/specsType/' + id, - method: 'delete', + method: 'delete' }) } // 导出产品分类 @@ -285,7 +285,7 @@ export function areaClassIfyList(params) { export function areaClassifyDel(id) { return request({ url: '/sale/manage/area-classify/' + id, - method: 'delete', + method: 'delete' }) } @@ -325,7 +325,7 @@ export function getAreaClassify(params) { export function getEWaresPermissionTypeList() { return request({ url: '/system/pub/enums/getEWaresPermissionTypeList', - method: 'get', + method: 'get' }) } // 根据id查询商品规格 @@ -364,14 +364,14 @@ export function get_hierarchy_list(params) { export function presale_status() { return request({ url: '/system/pub/enums/presale-status', - method: 'get', + method: 'get' }) } // 查询供应方式 export function supply_way() { return request({ url: '/system/pub/enums/supply-way', - method: 'get', + method: 'get' }) } // 标签分类 @@ -431,7 +431,7 @@ export function waresList(params) { export function waresDel(id) { return request({ url: '/sale/manage/wares/' + id, - method: 'delete', + method: 'delete' }) } // 商品新增 @@ -467,22 +467,7 @@ export function waresMove(params) { params }) } -// 商品置顶 -export function waresTop(params) { - return request({ - url: '/sale/manage/wares/floating-roof', - method: 'get', - params - }) -} -// 商品置底 -export function waresBottom(params) { - return request({ - url: '/sale/manage/wares/botton-up', - method: 'get', - params - }) -} + // 邮费模板列表 export function postageList(params) { return request({ @@ -496,7 +481,7 @@ export function postageList(params) { export function postageDel(id) { return request({ url: '/sale/manage/postage/' + id, - method: 'delete', + method: 'delete' }) } // 计费方式 @@ -527,7 +512,7 @@ export function findAllArea(params) { export function orderType() { return request({ url: '/system/pub/enums/special-area', - method: 'get', + method: 'get' }) } @@ -555,7 +540,7 @@ export function postageDetail(params) { params }) } -//获取产品编号 +// 获取产品编号 export function getProductCode(params) { return request({ url: '/sale/manage/product/create-product-code', @@ -563,7 +548,7 @@ export function getProductCode(params) { params }) } -//获取产品编号 +// 获取产品编号 export function getWaresCode(params) { return request({ url: '/sale/manage/wares/create-wares-code', @@ -571,7 +556,7 @@ export function getWaresCode(params) { params }) } -//获取最大排序 +// 获取最大排序 export function getMaxSort(params) { return request({ url: '/sale/manage/product/get-max-sort', @@ -579,7 +564,7 @@ export function getMaxSort(params) { params }) } -//单位列表 +// 单位列表 export function unitList(params) { return request({ url: '/sale/manage/unit/list', @@ -587,7 +572,7 @@ export function unitList(params) { params }) } -//单位新增 +// 单位新增 export function unitSave(data) { return request({ url: '/sale/manage/unit/save', @@ -595,7 +580,7 @@ export function unitSave(data) { data }) } -//单位编辑 +// 单位编辑 export function unitUpdate(data) { return request({ url: '/sale/manage/unit/update', @@ -603,7 +588,7 @@ export function unitUpdate(data) { data }) } -//单位详情 +// 单位详情 export function unitDetail(params) { return request({ url: '/sale/manage/unit/detail', @@ -615,11 +600,11 @@ export function unitDetail(params) { export function unitDel(id) { return request({ url: '/sale/manage/unit/' + id, - method: 'delete', + method: 'delete' }) } -//单位data +// 单位data export function unitAll(params) { return request({ url: '/sale/manage/unit/find-all', @@ -741,14 +726,7 @@ export function productFind(params) { params }) } -// 产品基本信息1 -export function productFind1(params) { - return request({ - url: 'scm/manage/product-bas/find-by-bas-all', - method: 'get', - params - }) -} + // 供应商商品列表 export function thProductList(params) { return request({ @@ -773,6 +751,15 @@ export function specialPostage(params) { params }) } + +// getMaxSortNum +export function getMaxSortNum(params) { + return request({ + url: 'sale/manage/wares/getMaxSortNum', + method: 'get', + params + }) +} // 产品生成 export function generateProduct(params) { return request({ @@ -789,3 +776,20 @@ export function get_sort(params) { params }) } + +export function resetInventoryUse(data) { + return request({ + url: 'sale/manage/wares/resetInventoryUse', + method: 'post', + data + }) +} + +export function getOutOfStockProduct(params) { + return request({ + url: 'sale/manage/wares/list-no-sale', + method: 'get', + params + }) +} + diff --git a/src/components/Delivery/unhandeled.vue b/src/components/Delivery/unhandeled.vue index 7fdbff6..a534b95 100644 --- a/src/components/Delivery/unhandeled.vue +++ b/src/components/Delivery/unhandeled.vue @@ -41,6 +41,13 @@ >订单抵扣 --> + - + { + const params = { + ...this.params, + pkWaresList: this.params.pkWaresList ? this.params.pkWaresList.split(',') : [], + mergeType: this.hdform.mergeType + } del - .deliverUnhandeldMerge( - Object.assign({}, this.params, { - mergeType: this.hdform.mergeType - }) - ) + .deliverUnhandeldMerge(params) .then((res) => { this.$message({ message: res.msg, diff --git a/src/views/information/realInfo/index.vue b/src/views/information/realInfo/index.vue index ddbc9bc..8724f44 100644 --- a/src/views/information/realInfo/index.vue +++ b/src/views/information/realInfo/index.vue @@ -109,73 +109,25 @@ - - - - - - - + + > + + - - - - - - - - - - - - - - - - - - - - - - @@ -504,66 +456,13 @@ export default { checked: true, prop: 'idCardBack' }, - { - id: 9, - text: '省', - checked: true, - prop: 'provinceName' - }, - { - id: 10, - text: '市', - checked: true, - prop: 'cityName' - }, - { - id: 11, - text: '区/县', - checked: true, - prop: 'countyName' - }, { id: 12, text: '详细地址', checked: true, prop: 'address' - }, - { - id: 13, - text: '银行名称', - checked: true, - prop: 'bankName' - }, - { - id: 14, - text: '支行名称', - checked: true, - prop: 'subBankName' - }, - { - id: 15, - text: '开户姓名', - checked: true, - prop: 'accountName' - }, - { - id: 16, - text: '预留电话', - checked: true, - prop: 'reservedPhone' - }, - { - id: 17, - text: '银行卡号', - checked: true, - prop: 'cardNumber' - }, - { - id: 18, - text: '邮箱地址', - checked: true, - prop: 'email' } + ], moren: 'RealInfo', topList: [ diff --git a/src/views/logistics/delivery/components/OutOfStockProductList.vue b/src/views/logistics/delivery/components/OutOfStockProductList.vue new file mode 100644 index 0000000..8445317 --- /dev/null +++ b/src/views/logistics/delivery/components/OutOfStockProductList.vue @@ -0,0 +1,243 @@ + + + + + + + + + + + + + + + + + + + + + + + + 搜索 + + + + + + {{ item.waresName }} ({{ item.waresCode }}) + + + + + + + + + + + + + + + + + + {{ '取消' }} + {{ + '确认' + }} + + + + + + + diff --git a/src/views/logistics/delivery/index.vue b/src/views/logistics/delivery/index.vue index f075384..d9fef6d 100644 --- a/src/views/logistics/delivery/index.vue +++ b/src/views/logistics/delivery/index.vue @@ -6,7 +6,7 @@ :moren="moren" /> - + @@ -64,22 +64,7 @@ - - - - - - - + - + - - - - - - - - - - - - - - - - - - - - - - {{ '取消' }} - {{ - '确认' - }} - - + :selected="selectedProductList" + @submit="handleSubmit" + /> @@ -1286,14 +1206,16 @@ import nowdelivery from '@/components/Delivery/nowdelivery.vue' import * as del from '@/api/delivery.js' import { getvertexValue } from '@/api/member' import { getRouters } from '@/api/settle' -import { productList } from '@/api/product' +import OutOfStockProductList from './components/OutOfStockProductList.vue' + export default { name: 'Fhqd', components: { topBar, unhandeled, yihandeled, - nowdelivery + nowdelivery, + OutOfStockProductList }, data() { return { @@ -1309,7 +1231,7 @@ export default { dialogList: [], lsArr: [], tableData: [], - productLists: [], + productLists: '', systemAllList: [ { label: '是', @@ -1368,7 +1290,7 @@ export default { payTime: [], printTime: [], // 打印时间2 deliverTime: [], // 发货时间2 - productIdList: [], + pkWaresList: [], systemAll: 0 }, isActive: true, @@ -1385,7 +1307,8 @@ export default { menu2: false, menu3: false, menu4: false, - vertexList: [] // 隶属体系 + vertexList: [], // 隶属体系 + selectedProductList: [] } }, created() { @@ -1395,84 +1318,15 @@ export default { }, methods: { clearProduct() { - this.tableData = [] - this.lsArr = [] - this.queryParams.productIdList = [] - this.productLists = [] + this.selectedProductList = [] + this.queryParams.pkWaresList = [] + this.productLists = '' }, openDig() { - this.select = {} - productList(Object.assign({ isPutOn: 0 }, this.queryParams)).then( - (res) => { - res.rows.forEach((item) => { - item.quantity = 1 - item.pkProduct = item.pkProduct - item.isGift = 0 - }) - this.dialogList = res.rows - this.total = res.total - } - ) this.dialogVisible = true + this.select = {} }, - handleClose() { - this.dialogVisible = false - }, - getDataList() { - productList( - Object.assign({ isPutOn: 0 }, this.queryParams, this.select) - ).then((res) => { - res.rows.forEach((item) => { - item.quantity = 1 - item.pkProduct = item.pkProduct - item.isGift = 0 - }) - this.dialogList = res.rows - this.total = res.total - }) - }, - dialogChange(val) { - this.lsArr = val - }, - onSubmit() { - // this.tableData = [] - this.lsArr.forEach((item) => { - this.tableData.push(item) - }) - // this.tableData = this.clearArr(this.tableData) - this.dialogVisible = false - this.dialogList.forEach((row) => { - this.$refs.lessonTableRef.toggleRowSelection(row, false) - }) - // 判断重复 - const arr = this.tableData - let isTrue = false - for (var i = 0; i < arr.length; i++) { - // 首次遍历数组 - for (var j = i + 1; j < arr.length; j++) { - // 再次遍历数组 - if (arr[i].productCode == arr[j].productCode) { - if (arr[i].isGift == arr[j].isGift) { - isTrue = true - } - } - } - } - if (isTrue) { - this.$message.error('请勿选择重复的商品') - this.tableData = [] - this.lsArr = [] - this.queryParams.productIdList = [] - this.productLists = [] - return - } - this.queryParams.productIdList = [] - this.productLists = [] - this.tableData.forEach((item) => { - this.queryParams.productIdList.push(item.pkId) - this.productLists.push(item.productName) - }) - }, + tableRowClassName({ row, rowIndex }) { if (rowIndex % 2 == 1) { return 'warning-row' @@ -1614,17 +1468,23 @@ export default { }, // 重置 reChongzhi() { + this.selectedProductList = [] this.queryParams = { pageNum: 1, pageSize: 500, orderStatus: 1 } - this.productLists = [] + this.productLists = '' this.getSearch() }, // 展开折叠 changeActive() { this.isActive = !this.isActive + }, + handleSubmit(products) { + this.selectedProductList = [...products] + this.queryParams.pkWaresList = products.map((item) => item.pkId).join(',') + this.productLists = products.map((item) => item.waresName).join(',') } } }