| | |
| | | data |
| | | }) |
| | | } |
| | | // 修改销售明细状态 |
| | | export function updateStatus(data) { |
| | | return request({ |
| | | url: "/api/salesDetails/updateStatus", |
| | | method: "post", |
| | | data |
| | | }) |
| | | } |
| | | // 更新销售明细 |
| | | export function getUpdateSalesDetails(data) { |
| | | return request({ |
| | |
| | | logisticCost: data.logisticCost || 0, |
| | | logisticNumber: data.logisticNumber || "", |
| | | quotationId: this.quotationId, |
| | | deliverType: data.deliverType || 0 |
| | | deliverType: data.deliverType || 0, |
| | | status: 1 |
| | | } |
| | | let params = {} |
| | | if (this.editConfig.title === "新建") { |
| | |
| | | <template slot="tableButton"> |
| | | <el-table-column label="操作" width="180"> |
| | | <template slot-scope="scope"> |
| | | <el-button @click="handleClick(scope.row, '查看')" type="text" size="small">查看</el-button> |
| | | <el-button @click.stop="handleClick(scope.row, '查看')" type="text" size="small">查看</el-button> |
| | | <template v-if="scope.row.status === 1"> |
| | | <el-button @click="handleClick(scope.row, '编辑')" type="text" size="small">编辑</el-button> |
| | | <el-button @click="submitClick(scope.row)" type="text" size="small">确认提交</el-button> |
| | | <el-button @click.stop="handleClick(scope.row, '编辑')" type="text" size="small">编辑</el-button> |
| | | <el-button @click.stop="submitClick(scope.row)" type="text" size="small">确认提交</el-button> |
| | | <!-- <el-button @click="delClick(scope.row.id)" type="text" size="small">删除</el-button> --> |
| | | <el-button @click="closeClick(scope.row.id)" type="text" size="small">关闭</el-button> |
| | | <el-button @click.stop="closeClick(scope.row)" type="text" size="small">关闭</el-button> |
| | | </template> |
| | | </template> |
| | | </el-table-column> |
| | |
| | | getSalesDetailsList, |
| | | getDelSalesDetails, |
| | | getProductInventoryInfo, |
| | | getProductOrderInfo |
| | | getProductOrderInfo, |
| | | updateStatus |
| | | } from "@/api/sales/salesDetails" |
| | | import pageMixin from "@/components/makepager/pager/mixin/pageMixin" |
| | | import DetailSpecification from "@/views/sales/salesDetails/DetailSpecification" |
| | |
| | | ...item, |
| | | client_name: item.client.name, |
| | | member_name: item.Member.username, |
| | | source: "CRM同步", |
| | | status: 2 |
| | | source: "CRM同步" |
| | | } |
| | | }) |
| | | this.tableList.tableInfomation = list || [] |
| | |
| | | } |
| | | }, |
| | | // 确认提交 |
| | | submitClick(row) { |
| | | async submitClick(row) { |
| | | console.log(row, "确认提交") |
| | | this.updateStatus(row.id, 2) |
| | | }, |
| | | // 关闭 |
| | | closeClick(row) { |
| | | console.log(row, "关闭") |
| | | this.updateStatus(row.id, 4) |
| | | }, |
| | | // 修改状态 |
| | | async updateStatus(id, status) { |
| | | await updateStatus({ |
| | | id: id, |
| | | status: status |
| | | }).then((res) => { |
| | | console.log(res) |
| | | if (res.code == 200) { |
| | | this.$message.success("修改成功") |
| | | this.getData() |
| | | } |
| | | }) |
| | | }, |
| | | // 删除 |
| | | delClick(rowID) { |