yangfeng
2024-03-25 a70881cad8fe749f41b06f221d10bb7491259256
发货完成状态接口联调、页面数据处理
4个文件已修改
56 ■■■■■ 已修改文件
src/common/untils/request.js 1 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/orderManageModule/orderManage/index.vue 49 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/other/login/index.vue 4 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
vue.config.js 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/common/untils/request.js
@@ -59,7 +59,6 @@
/* //返回状态判断(添加响应拦截器) */
Axios.interceptors.response.use(
  (res) => {
    console.log("99999", res)
    /* //对响应数据做些事 */
    if (res.data.code === 200) {
      return res.data ? res.data : {}
src/views/orderManageModule/orderManage/index.vue
@@ -261,13 +261,20 @@
      this.searchParam.pageSize = this.pagerOptions.pageSize
      let rsp = await outsourceOrderList(this.searchParam)
      let list = rsp
      console.log(list)
      if (list && list.code == 200) {
        this.tableList.tableInfomation = list.data
        this.pagerOptions.totalCount = list.total
        if (list.total > 0) {
          this.selectRow = list.data[0]
          this.getProductListMethod(list.data[0].id)
          if (this.activeNameBottom == 1) {
            this.getProductListMethod(this.selectRow.id)
          } else if (this.activeNameBottom == 2) {
            this.getMaterialApplyList(this.selectRow.number)
          } else {
            this.getDeliveryList(this.selectRow.id)
          }
        } else {
          this.selectRow = {}
        }
        this.overview()
      }
@@ -275,7 +282,6 @@
    // 获取产品信息
    getProductListMethod(id) {
      outsourceOrderProductList({ outsourcingOrderId: id }).then((res) => {
        console.log(res)
        if (res.code == 200) {
          this.bottomTwoTableList1.tableInfomation = res.data
        }
@@ -284,7 +290,6 @@
    // 获取物料申请单
    getMaterialApplyList(number) {
      getMaterialApplyList({ number: number }).then((res) => {
        console.log(res)
        if (res.code == 200) {
          this.bottomTwoTableList2.tableInfomation = res.data
        }
@@ -325,12 +330,12 @@
        })
      })
    },
    addCommonClick() {
      alert("露西666")
    },
    searchClick(val) {
      this.searchParam.keyword = val
      this.pagerOptions.currPage = 1
      this.bottomTwoTableList1.tableInfomation = []
      this.bottomTwoTableList2.tableInfomation = []
      this.bottomTwoTableList3.tableInfomation = []
      this.getData()
    },
    tableRowClick(row, column, event) {
@@ -361,17 +366,25 @@
          confirmButtonText: "确定",
          cancelButtonText: "取消",
          type: "warning"
        }).then(() => {
          this.changeOutsourceOrderStatus(row.number, 6, "生产完成成功")
        })
          .then(() => {
            this.changeOutsourceOrderStatus(row.number, 6, "生产完成成功")
          })
          .catch(() => {
            this.$message.warning("已取消生产完成")
          })
      } else if (val == "发货完成") {
        this.$confirm("是否确认全部发货完成?", "提示", {
          confirmButtonText: "确定",
          cancelButtonText: "取消",
          type: "warning"
        }).then(() => {
          this.changeOutsourceOrderStatus(row.number, 7, "全部发货完成成功")
        })
          .then(() => {
            this.changeOutsourceOrderStatus(row.number, 7, "全部发货完成成功")
          })
          .catch(() => {
            this.$message.warning("已取消发货完成")
          })
      }
    },
    changeOutsourceOrderStatus(number, status, str) {
@@ -408,12 +421,14 @@
    },
    tabClickBottom(activeNameBottom) {
      this.activeNameBottom = activeNameBottom
      if (activeNameBottom == 1) {
        this.getProductListMethod(this.selectRow.id)
      } else if (activeNameBottom == 2) {
        this.getMaterialApplyList(this.selectRow.number)
      } else {
        this.getDeliveryList(this.selectRow.id)
      if (Object.keys(this.selectRow).length > 0) {
        if (activeNameBottom == 1) {
          this.getProductListMethod(this.selectRow.id)
        } else if (activeNameBottom == 2) {
          this.getMaterialApplyList(this.selectRow.number)
        } else {
          this.getDeliveryList(this.selectRow.id)
        }
      }
    },
    setTable() {
src/views/other/login/index.vue
@@ -154,16 +154,14 @@
            captcha: this.formLogin.code,
            captchaId: this.captchaId
          }).then((res) => {
            console.log(res, "dddd")
            if (res.code == 200) {
              console.log(res, "8888")
              this.$message.success("登录成功")
              localStorage.setItem("token", res.data.token)
              localStorage.setItem("username", res.data.user.username)
              localStorage.setItem("uuid", res.data.user.id)
              setTimeout(() => {
                this.$router.push({ path: "/orderManageModule/orderManage" })
              }, 2000)
              }, 1000)
            } else {
              this.$message.warning(res.msg)
              if (res.msg == "验证码错误") {
vue.config.js
@@ -21,7 +21,7 @@
      //   changeOrigin: true
      // },
      "/api-outsourcing": {
        target: "http://192.168.20.120:8008",
        target: "http://192.168.20.119:8009",
        ws: true,
        changeOrigin: true
      },