|
|
|
@ -78,20 +78,62 @@ |
|
|
|
|
<el-table-column type="expand" fixed="left"> |
|
|
|
|
<template #default="{ row }"> |
|
|
|
|
<div class="p-10px flex justify-center"> |
|
|
|
|
<VueDraggable |
|
|
|
|
<!-- <VueDraggable |
|
|
|
|
target="tbody" |
|
|
|
|
v-model="row.signProducts" |
|
|
|
|
:animation="150" |
|
|
|
|
@end="onDragEnd" |
|
|
|
|
style="width: 100%" |
|
|
|
|
> --> |
|
|
|
|
<el-table |
|
|
|
|
:data="row.signProducts" |
|
|
|
|
row-key="id" |
|
|
|
|
stripe |
|
|
|
|
style="width: 90%; margin: 0 auto" |
|
|
|
|
> |
|
|
|
|
<el-table |
|
|
|
|
:data="row.signProducts" |
|
|
|
|
row-key="id" |
|
|
|
|
stripe |
|
|
|
|
style="width: 80%; margin: 0 auto" |
|
|
|
|
> |
|
|
|
|
<el-table-column prop="productName" label="成交产品" width="120px" /> |
|
|
|
|
<el-table-column prop="" label="子订单号" /> |
|
|
|
|
<el-table-column prop="" label="登记人" width="120px" /> |
|
|
|
|
<el-table-column prop="" label="成交日期" width="120px" /> |
|
|
|
|
<el-table-column prop="" label="成交价" width="120px" /> |
|
|
|
|
<el-table-column prop="" label="支付金额" width="120px" /> |
|
|
|
|
<el-table-column prop="" label="已到账金额" width="120px" /> |
|
|
|
|
<el-table-column prop="" label="提成状态" width="120px" /> |
|
|
|
|
<el-table-column prop="" label="备注" /> |
|
|
|
|
<el-table-column label="操作" width="200px" fixed="right"> |
|
|
|
|
<template #default="scope"> |
|
|
|
|
<el-button |
|
|
|
|
type="primary" |
|
|
|
|
class="mr-10px" |
|
|
|
|
link |
|
|
|
|
style="padding: 0; margin-left: 0" |
|
|
|
|
v-hasPermi="['clue:order:after-sale']" |
|
|
|
|
@click="sellAfter(scope.row)" |
|
|
|
|
> |
|
|
|
|
售后 |
|
|
|
|
</el-button> |
|
|
|
|
<el-button |
|
|
|
|
type="primary" |
|
|
|
|
class="mr-10px" |
|
|
|
|
link |
|
|
|
|
style="padding: 0; margin-left: 0" |
|
|
|
|
v-hasPermi="['clue:order:return']" |
|
|
|
|
@click="feeBack(scope.row)" |
|
|
|
|
> |
|
|
|
|
回款 |
|
|
|
|
</el-button> |
|
|
|
|
<el-button |
|
|
|
|
type="primary" |
|
|
|
|
class="mr-10px" |
|
|
|
|
link |
|
|
|
|
style="padding: 0; margin-left: 0" |
|
|
|
|
v-hasPermi="['clue:pool:enroll']" |
|
|
|
|
@click="cancelDeal(scope.row)" |
|
|
|
|
> |
|
|
|
|
取消登记 |
|
|
|
|
</el-button> |
|
|
|
|
</template> |
|
|
|
|
</el-table-column> |
|
|
|
|
<!-- <el-table-column prop="productName" label="成交产品" width="120px" /> |
|
|
|
|
<el-table-column prop="specsName" label="产品规格" width="120px" /> |
|
|
|
|
<el-table-column prop="signNum" label="成交数量" width="90px" /> |
|
|
|
|
<el-table-column prop="remark" label="成交备注" width="100px" /> |
|
|
|
@ -157,9 +199,9 @@ |
|
|
|
|
删除 |
|
|
|
|
</el-button> |
|
|
|
|
</template> |
|
|
|
|
</el-table-column> |
|
|
|
|
</el-table> |
|
|
|
|
</VueDraggable> |
|
|
|
|
</el-table-column> --> |
|
|
|
|
</el-table> |
|
|
|
|
<!-- </VueDraggable> --> |
|
|
|
|
</div> |
|
|
|
|
</template> |
|
|
|
|
</el-table-column> |
|
|
|
@ -184,7 +226,7 @@ |
|
|
|
|
</span> |
|
|
|
|
</template> |
|
|
|
|
</el-table-column> |
|
|
|
|
<el-table-column label="操作" width="240px" fixed="right"> |
|
|
|
|
<el-table-column label="操作" width="120px" fixed="right"> |
|
|
|
|
<template #default="scope"> |
|
|
|
|
<el-button |
|
|
|
|
type="primary" |
|
|
|
@ -196,27 +238,6 @@ |
|
|
|
|
> |
|
|
|
|
详情 |
|
|
|
|
</el-button> |
|
|
|
|
<el-button |
|
|
|
|
type="primary" |
|
|
|
|
class="mr-10px" |
|
|
|
|
link |
|
|
|
|
style="padding: 0; margin-left: 0" |
|
|
|
|
v-hasPermi="['clue:order:after-sale']" |
|
|
|
|
@click="sellAfter(scope.row)" |
|
|
|
|
> |
|
|
|
|
售后 |
|
|
|
|
</el-button> |
|
|
|
|
<el-button |
|
|
|
|
type="primary" |
|
|
|
|
class="mr-10px" |
|
|
|
|
link |
|
|
|
|
style="padding: 0; margin-left: 0" |
|
|
|
|
v-if="scope.row.isPayoff == '未结清'" |
|
|
|
|
v-hasPermi="['clue:order:return']" |
|
|
|
|
@click="feeBack(scope.row)" |
|
|
|
|
> |
|
|
|
|
回款 |
|
|
|
|
</el-button> |
|
|
|
|
<el-button |
|
|
|
|
type="primary" |
|
|
|
|
class="mr-10px" |
|
|
|
@ -227,26 +248,6 @@ |
|
|
|
|
> |
|
|
|
|
添加支出 |
|
|
|
|
</el-button> |
|
|
|
|
<el-button |
|
|
|
|
type="primary" |
|
|
|
|
class="mr-10px" |
|
|
|
|
link |
|
|
|
|
style="padding: 0; margin-left: 0" |
|
|
|
|
v-hasPermi="['clue:pool:enroll']" |
|
|
|
|
@click="cancelDeal(scope.row)" |
|
|
|
|
> |
|
|
|
|
取消登记 |
|
|
|
|
</el-button> |
|
|
|
|
<el-button |
|
|
|
|
type="primary" |
|
|
|
|
class="mr-10px" |
|
|
|
|
link |
|
|
|
|
style="padding: 0; margin-left: 0" |
|
|
|
|
v-hasPermi="['clue:order:add-product']" |
|
|
|
|
@click="handleAddProduct(scope.row)" |
|
|
|
|
> |
|
|
|
|
添加产品 |
|
|
|
|
</el-button> |
|
|
|
|
</template> |
|
|
|
|
</el-table-column> |
|
|
|
|
</SSTable> |
|
|
|
@ -277,8 +278,8 @@ import DialogAddProduct from './DialogAddProduct.vue' |
|
|
|
|
import { removeNullField } from '@/utils' |
|
|
|
|
import { formatDate } from '@/utils/formatTime' |
|
|
|
|
import { ElMessageBox, ElOption, ElSelect } from 'element-plus' |
|
|
|
|
import { VueDraggable } from 'vue-draggable-plus' |
|
|
|
|
import { checkPermi } from '@/utils/permission' |
|
|
|
|
// import { VueDraggable } from 'vue-draggable-plus' |
|
|
|
|
// import { checkPermi } from '@/utils/permission' |
|
|
|
|
|
|
|
|
|
const userOptions = ref([]) |
|
|
|
|
const allUserOptions = ref([]) |
|
|
|
@ -421,14 +422,14 @@ async function getOptions() { |
|
|
|
|
getCurdSchemas() |
|
|
|
|
} |
|
|
|
|
const deliveryDialog = ref() |
|
|
|
|
function handleDelivery(row) { |
|
|
|
|
deliveryDialog.value.open(row) |
|
|
|
|
} |
|
|
|
|
// function handleDelivery(row) { |
|
|
|
|
// deliveryDialog.value.open(row) |
|
|
|
|
// } |
|
|
|
|
|
|
|
|
|
const addProductDialog = ref() |
|
|
|
|
function handleAddProduct(row) { |
|
|
|
|
addProductDialog.value.open(row.signId, prodOptions.value) |
|
|
|
|
} |
|
|
|
|
// const addProductDialog = ref() |
|
|
|
|
// function handleAddProduct(row) { |
|
|
|
|
// addProductDialog.value.open(row.signId, prodOptions.value) |
|
|
|
|
// } |
|
|
|
|
|
|
|
|
|
const batchIds = ref([]) |
|
|
|
|
function handleSelectionChange(val) { |
|
|
|
@ -486,51 +487,51 @@ function handleBatchUpdateInstall() { |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
async function handleRemoveProduct(row) { |
|
|
|
|
try { |
|
|
|
|
// 修改状态的二次确认 |
|
|
|
|
await message.confirm(`确认要删除${row.productName}吗?`) |
|
|
|
|
// 发起修改状态 |
|
|
|
|
await SignApi.removeOrderProduct(row.id) |
|
|
|
|
message.success('删除成功') |
|
|
|
|
// 刷新列表 |
|
|
|
|
getTableList() |
|
|
|
|
} catch {} |
|
|
|
|
} |
|
|
|
|
// async function handleRemoveProduct(row) { |
|
|
|
|
// try { |
|
|
|
|
// // 修改状态的二次确认 |
|
|
|
|
// await message.confirm(`确认要删除${row.productName}吗?`) |
|
|
|
|
// // 发起修改状态 |
|
|
|
|
// await SignApi.removeOrderProduct(row.id) |
|
|
|
|
// message.success('删除成功') |
|
|
|
|
// // 刷新列表 |
|
|
|
|
// getTableList() |
|
|
|
|
// } catch {} |
|
|
|
|
// } |
|
|
|
|
|
|
|
|
|
async function handleChangeProdoce(row) { |
|
|
|
|
try { |
|
|
|
|
// 修改状态的二次确认 |
|
|
|
|
await message.confirm('确认要修改生产状态吗?') |
|
|
|
|
// 发起修改状态 |
|
|
|
|
await SignApi.updateProduceStatus({ |
|
|
|
|
signId: row.signId, |
|
|
|
|
id: row.id, |
|
|
|
|
isProduced: row.isProduced |
|
|
|
|
}) |
|
|
|
|
message.success('修改成功') |
|
|
|
|
// 刷新列表 |
|
|
|
|
// getTableList() |
|
|
|
|
} catch { |
|
|
|
|
// 取消后,进行恢复按钮 |
|
|
|
|
row.isProduced = !row.isProduced |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
// async function handleChangeProdoce(row) { |
|
|
|
|
// try { |
|
|
|
|
// // 修改状态的二次确认 |
|
|
|
|
// await message.confirm('确认要修改生产状态吗?') |
|
|
|
|
// // 发起修改状态 |
|
|
|
|
// await SignApi.updateProduceStatus({ |
|
|
|
|
// signId: row.signId, |
|
|
|
|
// id: row.id, |
|
|
|
|
// isProduced: row.isProduced |
|
|
|
|
// }) |
|
|
|
|
// message.success('修改成功') |
|
|
|
|
// // 刷新列表 |
|
|
|
|
// // getTableList() |
|
|
|
|
// } catch { |
|
|
|
|
// // 取消后,进行恢复按钮 |
|
|
|
|
// row.isProduced = !row.isProduced |
|
|
|
|
// } |
|
|
|
|
// } |
|
|
|
|
|
|
|
|
|
const expendRows = ref([]) |
|
|
|
|
async function onDragEnd(ev) { |
|
|
|
|
try { |
|
|
|
|
expendRows.value = [ev.data.signId] |
|
|
|
|
const list = tableObject.value.tableList.find((it) => it.signId == ev.data.signId).signProducts |
|
|
|
|
await SignApi.updateProduceSort(list.map((it) => it.id)) |
|
|
|
|
message.success('修改成功') |
|
|
|
|
// 刷新列表 |
|
|
|
|
getTableList() |
|
|
|
|
} catch (error) { |
|
|
|
|
console.log(error) |
|
|
|
|
getTableList() |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
// const expendRows = ref([]) |
|
|
|
|
// async function onDragEnd(ev) { |
|
|
|
|
// try { |
|
|
|
|
// expendRows.value = [ev.data.signId] |
|
|
|
|
// const list = tableObject.value.tableList.find((it) => it.signId == ev.data.signId).signProducts |
|
|
|
|
// await SignApi.updateProduceSort(list.map((it) => it.id)) |
|
|
|
|
// message.success('修改成功') |
|
|
|
|
// // 刷新列表 |
|
|
|
|
// getTableList() |
|
|
|
|
// } catch (error) { |
|
|
|
|
// console.log(error) |
|
|
|
|
// getTableList() |
|
|
|
|
// } |
|
|
|
|
// } |
|
|
|
|
</script> |
|
|
|
|
|
|
|
|
|
<style lang="scss" scoped></style> |
|
|
|
|