jiangping
2023-09-18 8d322f025a9483030a47d4671c5fa7502bbcb930
休bug
已修改5个文件
38 ■■■■■ 文件已修改
platform/src/api/business/goods.js 8 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
platform/src/components/business/OperaGoodsWindow.vue 8 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
platform/src/views/business/goods.vue 15 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
platform/src/views/system/user.vue 1 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
server/platform/src/main/java/com/doumee/api/business/BaseGoodsController.java 6 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
platform/src/api/business/goods.js
@@ -48,12 +48,12 @@
}
// 修改状态
export function updateStatusById (data) {
  return request.post('/business/baseGoods/updateStatusById', data)
export function updateStatus (data) {
  return request.post('/business/baseGoods/updateStatus', data)
}
export function updateStatusById (data) {
/*export function updateStatusById (data) {
  return request.post('/business/baseGoods/updateStatusById', data)
}
}*/
// 列表 - 商品选择
export function findListForbaseGoodsId (goodsId) {
platform/src/components/business/OperaGoodsWindow.vue
@@ -98,8 +98,8 @@
<script>
import BaseOpera from '@/components/base/BaseOpera'
import GlobalWindow from '@/components/common/GlobalWindow'
import { brand } from '@/api/system/common.js'
import { findListForGoodsId, create, updateById, companyCreate, companyUpdateById } from '@/api/business/goods.js'
import { baseCategory,brand } from '@/api/system/common.js'
import {  create, updateById, companyCreate, companyUpdateById } from '@/api/business/goods.js'
export default {
  name: 'OperaGoodsWindow',
  extends: BaseOpera,
@@ -315,13 +315,13 @@
      this.form.imgurl = ''
    },
      getbrand() {
        brand({})
        brand({status:0})
          .then(res => {
            this.brandList = res
          })
      },
      getcategory(type) {
        findListForGoodsId(this.form.id || '')
        baseCategory({status:0 , type:1})
          .then(res => {
            this.categoryList = res
            if (type === 1) {
platform/src/views/business/goods.vue
@@ -105,7 +105,7 @@
import OperaGoodsWindow from '@/components/business/OperaGoodsWindow'
import selectProduct from '@/components/business/selectProduct'
import { brand, baseCategory, importExcel } from '@/api/system/common.js'
import { updateStatusById, queryById, exportDoc, batchUpdateDisableById } from '@/api/business/goods.js'
import { updateStatus, queryById, exportDoc } from '@/api/business/goods.js'
export default {
  name: 'Goods',
  extends: BaseTable,
@@ -121,6 +121,7 @@
        brandId: ''
      },
      ids: '',
      idList: [],
      categoryList: [],
      brandList: [],
      statusList: [
@@ -144,6 +145,7 @@
    handleSelectionChange(e) {
      let arr = e.map(item => item.id)
      this.ids = arr.join(',')
      this.idList = arr;
      console.log(this.ids)
    },
    // 批量上下架
@@ -152,11 +154,12 @@
        this.$message.warning({ message: '至少选择一项内容' })
        return
      }
      batchUpdateDisableById({
        ids: this.ids,
      updateStatus({
        idList: this.idList,
        status: type
      }).then(res => {
        this.$message.success({ message: res })
        this.$tip.apiSuccess('操作成功');
        // this.$message.success({ message:res.message })
        this.search()
      })
    },
@@ -221,8 +224,8 @@
        })
    },
    changeStatus(item) {
      updateDisableById({
        id: item.id,
      updateStatus({
        idList: [item.id],
        status: item.status
      }).then(res => {
        this.$tip.apiSuccess('更新成功')
platform/src/views/system/user.vue
@@ -125,6 +125,7 @@
    return {
      // 搜索
      searchForm: {
        type:0,
        username: '', // 名字
        realname: '', // 姓名
        rootDeptId: null, // 部门ID
server/platform/src/main/java/com/doumee/api/business/BaseGoodsController.java
@@ -96,12 +96,12 @@
     * 主键上下架
     *
     */
    @ApiOperation("根据ID查询")
    @ApiOperation("根据ID查询批量上架下架")
    @PostMapping("/updateStatus")
    @RequiresPermissions("business:basegoods:query")
    @RequiresPermissions("business:basegoods:update")
    public ApiResponse updateStatusByIds(@RequestBody   BaseGoods param ){
        baseGoodsService.updateStatusByIds(param);
        return ApiResponse.success(null);
        return ApiResponse.success("操作成功!");
    }