Ver código fonte

供应商、服务客户、工序节点、停车费配置

shasha 1 mês atrás
pai
commit
df48b4da63
38 arquivos alterados com 358 adições e 160 exclusões
  1. 1 1
      snowy-admin-web/src/views/biz/bizloadpoint/timeAlreadyForm.vue
  2. 2 0
      snowy-admin-web/src/views/biz/bizloadpoint/timeIndex.vue
  3. 1 1
      snowy-admin-web/src/views/biz/bizloadpoint/userForm.vue
  4. 5 5
      snowy-admin-web/src/views/biz/bizloadpoint/userIndex.vue
  5. 3 0
      snowy-admin-web/src/views/biz/bizloadtime/index.vue
  6. 21 8
      snowy-admin-web/src/views/biz/bizparkconfig/form.vue
  7. 31 7
      snowy-admin-web/src/views/biz/bizparkconfig/index.vue
  8. 1 0
      snowy-admin-web/src/views/biz/bizprocess/form.vue
  9. 16 4
      snowy-admin-web/src/views/biz/bizprocess/index.vue
  10. 3 4
      snowy-admin-web/src/views/biz/bizprocess/nodeForm.vue
  11. 86 73
      snowy-admin-web/src/views/biz/bizprocess/nodeIndex.vue
  12. 2 1
      snowy-admin-web/src/views/biz/bizservicecustomer/accountForm.vue
  13. 2 2
      snowy-admin-web/src/views/biz/bizservicecustomer/index.vue
  14. 15 9
      snowy-admin-web/src/views/biz/bizvehicle/index.vue
  15. 8 4
      snowy-admin-web/src/views/biz/customer/index.vue
  16. 2 2
      snowy-plugin/snowy-plugin-biz/src/main/java/vip/xiaonuo/biz/modular/bizloadpoint/enums/BizLoadPointEnum.java
  17. 3 0
      snowy-plugin/snowy-plugin-biz/src/main/java/vip/xiaonuo/biz/modular/bizloadtime/service/BizLoadTimeService.java
  18. 22 1
      snowy-plugin/snowy-plugin-biz/src/main/java/vip/xiaonuo/biz/modular/bizloadtime/service/impl/BizLoadTimeServiceImpl.java
  19. 2 2
      snowy-plugin/snowy-plugin-biz/src/main/java/vip/xiaonuo/biz/modular/bizparkconfig/entity/BizParkConfig.java
  20. 2 2
      snowy-plugin/snowy-plugin-biz/src/main/java/vip/xiaonuo/biz/modular/bizparkconfig/enums/BizParkConfigEnum.java
  21. 18 2
      snowy-plugin/snowy-plugin-biz/src/main/java/vip/xiaonuo/biz/modular/bizparkconfig/service/impl/BizParkConfigServiceImpl.java
  22. 2 2
      snowy-plugin/snowy-plugin-biz/src/main/java/vip/xiaonuo/biz/modular/bizprocess/enums/BizProcessEnum.java
  23. 2 2
      snowy-plugin/snowy-plugin-biz/src/main/java/vip/xiaonuo/biz/modular/bizprocess/enums/BizProcessNodeEnum.java
  24. 4 0
      snowy-plugin/snowy-plugin-biz/src/main/java/vip/xiaonuo/biz/modular/bizprocess/param/BizProcessNodePageParam.java
  25. 21 1
      snowy-plugin/snowy-plugin-biz/src/main/java/vip/xiaonuo/biz/modular/bizprocess/service/impl/BizProcessNodeServiceImpl.java
  26. 15 4
      snowy-plugin/snowy-plugin-biz/src/main/java/vip/xiaonuo/biz/modular/bizprocess/service/impl/BizProcessServiceImpl.java
  27. 2 2
      snowy-plugin/snowy-plugin-biz/src/main/java/vip/xiaonuo/biz/modular/bizservicecustomer/enums/BizServiceCustomerAccountEnum.java
  28. 2 2
      snowy-plugin/snowy-plugin-biz/src/main/java/vip/xiaonuo/biz/modular/bizservicecustomer/enums/BizServiceCustomerEnum.java
  29. 2 2
      snowy-plugin/snowy-plugin-biz/src/main/java/vip/xiaonuo/biz/modular/bizservicecustomer/enums/BizServiceCustomerFlowEnum.java
  30. 4 0
      snowy-plugin/snowy-plugin-biz/src/main/java/vip/xiaonuo/biz/modular/bizservicecustomer/param/BizServiceCustomerPageParam.java
  31. 8 3
      snowy-plugin/snowy-plugin-biz/src/main/java/vip/xiaonuo/biz/modular/bizservicecustomer/service/impl/BizServiceCustomerAccountServiceImpl.java
  32. 20 0
      snowy-plugin/snowy-plugin-biz/src/main/java/vip/xiaonuo/biz/modular/bizservicecustomer/service/impl/BizServiceCustomerServiceImpl.java
  33. 2 2
      snowy-plugin/snowy-plugin-biz/src/main/java/vip/xiaonuo/biz/modular/bizsupplier/enums/BizSupplierAccountEnum.java
  34. 2 2
      snowy-plugin/snowy-plugin-biz/src/main/java/vip/xiaonuo/biz/modular/bizsupplier/enums/BizSupplierEnum.java
  35. 2 2
      snowy-plugin/snowy-plugin-biz/src/main/java/vip/xiaonuo/biz/modular/bizsupplier/enums/BizSupplierTransportEnum.java
  36. 7 2
      snowy-plugin/snowy-plugin-biz/src/main/java/vip/xiaonuo/biz/modular/bizsupplier/service/impl/BizSupplierAccountServiceImpl.java
  37. 8 2
      snowy-plugin/snowy-plugin-biz/src/main/java/vip/xiaonuo/biz/modular/bizsupplier/service/impl/BizSupplierServiceImpl.java
  38. 9 4
      snowy-plugin/snowy-plugin-biz/src/main/java/vip/xiaonuo/biz/modular/bizsupplier/service/impl/BizSupplierTransportServiceImpl.java

+ 1 - 1
snowy-admin-web/src/views/biz/bizloadpoint/timeAlreadyForm.vue

@@ -16,7 +16,7 @@
 
 		<a-form ref="formRef" :model="formData" :rules="formRules" :wrapper-col="wrapperCol" :label-col="labelCol">
 			<a-form-item label="可约次数:" name="availableNumber">
-				<a-input-number v-model:value="formData.availableNumber" :min="availableNumber" style="width: 100%;" placeholder="请输入可约次数" allow-clear />
+				<a-input-number v-model:value="formData.availableNumber" :min="alreadyNumber" style="width: 100%;" placeholder="请输入可约次数" allow-clear />
 			</a-form-item>
 		</a-form>
 

+ 2 - 0
snowy-admin-web/src/views/biz/bizloadpoint/timeIndex.vue

@@ -61,6 +61,7 @@
 	const alreadyFormRef = ref()
 	const recordData = ref()
 	const title = ref()
+	const pointId = ref()
 
 	const columns = [
 		{
@@ -101,6 +102,7 @@
 		searchFormState.value = {
 			pointId: record.id
 		}
+		pointId.value = record.id
 		visible.value = true
 	}
 	// 加载字段数据

+ 1 - 1
snowy-admin-web/src/views/biz/bizloadpoint/userForm.vue

@@ -1,6 +1,6 @@
 <template>
 	<xn-form-container
-		title="增加装货点人员信息"
+		:title="formData.id ? '编辑装货点人员信息' : '增加装货点人员信息'"
 		:width="700"
 		v-model:open="open"
 		:destroy-on-close="true"

+ 5 - 5
snowy-admin-web/src/views/biz/bizloadpoint/userIndex.vue

@@ -57,11 +57,11 @@
 			dataIndex: 'serial',
 			align:'center'
 		},
-		{
-			title: '装货点位',
-			dataIndex: 'loadPoint',
-			align:'center'
-		},
+		// {
+		// 	title: '装货点位',
+		// 	dataIndex: 'loadPoint',
+		// 	align:'center'
+		// },
 		{
 			title: '装货员账号',
 			dataIndex: 'account',

+ 3 - 0
snowy-admin-web/src/views/biz/bizloadtime/index.vue

@@ -62,17 +62,20 @@
 		</s-table>
 	</a-card>
 	<Form ref="formRef" @successful="tableRef.refresh()" />
+	<AlreadyForm ref="alreadyFormRef" @successful="tableRef.refresh()" />
 </template>
 
 <script setup name="bizloadtime">
 	import { cloneDeep } from 'lodash-es'
 	import Form from './form.vue'
+	import AlreadyForm from './alreadyForm.vue'
 	import bizLoadTimeApi from '@/api/biz/bizLoadTimeApi'
 
 	const searchFormState = ref({})
 	const searchFormRef = ref()
 	const tableRef = ref()
 	const formRef = ref()
+	const alreadyFormRef = ref()
 	const toolConfig = { refresh: true, height: true, columnSetting: true, striped: false }
 	const columns = [
 		{

+ 21 - 8
snowy-admin-web/src/views/biz/bizparkconfig/form.vue

@@ -8,16 +8,20 @@
 	>
 		<a-form ref="formRef" :model="formData" :rules="formRules" :wrapper-col="wrapperCol" :label-col="labelCol">
 			<a-form-item label="预约类型:" name="appointmentType">
-				<a-input v-model:value="formData.appointmentType" placeholder="请输入预约类型" allow-clear />
+				<a-radio-group button-style="solid" v-model:value="formData.appointmentType">
+					<a-radio-button v-for="appointmentItem in appointmentClassifyOptions" :key="appointmentItem.value" :value="appointmentItem.value" >
+						{{ appointmentItem.label }}
+					</a-radio-button>
+				</a-radio-group>
 			</a-form-item>
-			<a-form-item label="免费停留时长:" name="freeParkTime">
-				<a-input v-model:value="formData.freeParkTime" placeholder="请输入免费停留时长" allow-clear />
+			<a-form-item label="免费停留时长(分钟):" name="freeParkTime">
+				<a-input-number v-model:value="formData.freeParkTime" :min="0" style="width: 100%;" placeholder="请输入免费停留时长" allow-clear />
 			</a-form-item>
-			<a-form-item label="超出每小时费用:" name="exceedAmount">
-				<a-input v-model:value="formData.exceedAmount" placeholder="请输入超出每小时费用" allow-clear />
+			<a-form-item label="超出费用(元/小时):" name="exceedAmount">
+				<a-input-number v-model:value="formData.exceedAmount" :min="0" style="width: 100%;" placeholder="请输入超出每小时费用" allow-clear />
 			</a-form-item>
-			<a-form-item label="支付后停留时长:" name="payAfterParkTime">
-				<a-input v-model:value="formData.payAfterParkTime" placeholder="请输入支付后停留时长" allow-clear />
+			<a-form-item label="支付后停留时长(分钟):" name="payAfterParkTime">
+				<a-input-number v-model:value="formData.payAfterParkTime" :min="0" style="width: 100%;" placeholder="请输入支付后停留时长" allow-clear />
 			</a-form-item>
 		</a-form>
 		<template #footer>
@@ -31,6 +35,8 @@
 	import { cloneDeep } from 'lodash-es'
 	import { required } from '@/utils/formRules'
 	import bizParkConfigApi from '@/api/biz/bizParkConfigApi'
+	import tool from '@/utils/tool'
+
 	// 抽屉状态
 	const open = ref(false)
 	const emit = defineEmits({ successful: null })
@@ -40,9 +46,12 @@
 	const submitLoading = ref(false)
 
 	//设置表单样式
-	const labelCol = ref({ span: 4})
+	const labelCol = ref({ span: 6})
 	const wrapperCol = ref({ span: 16})
 
+	// 预约分类
+	const appointmentClassifyOptions = tool.dictList('appointment_classify')
+
 	// 打开抽屉
 	const onOpen = (record) => {
 		open.value = true
@@ -59,6 +68,10 @@
 	}
 	// 默认要校验的
 	const formRules = {
+		appointmentType: [required('请选择预约类型')],
+		freeParkTime: [required('请输入免费停留时长')],
+		exceedAmount: [required('请输入超出每小时费用')],
+		payAfterParkTime: [required('请输入支付后停留时长')], 
 	}
 	// 验证并提交数据
 	const onSubmit = () => {

+ 31 - 7
snowy-admin-web/src/views/biz/bizparkconfig/index.vue

@@ -4,7 +4,10 @@
 			<a-row :gutter="24">
 				<a-col :span="6">
 					<a-form-item label="预约类型" name="appointmentType">
-						<a-input v-model:value="searchFormState.appointmentType" placeholder="查询预约类型" allow-clear  />
+						<a-select v-model:value="searchFormState.appointmentType" 
+							placeholder="查询预约类型" 
+							:options="appointmentClassifyOptions">
+						</a-select>
 					</a-form-item>
 				</a-col>
 				<a-col :span="6">
@@ -31,6 +34,18 @@
 				<template v-if="column.dataIndex === 'serial'">
 					{{ index + 1 }}
 				</template>
+				<template v-if="column.dataIndex === 'appointmentType'">
+					{{ $TOOL.dictTypeData('appointment_classify', record.appointmentType) }}
+				</template>
+				<template v-if="column.dataIndex === 'freeParkTime'">
+					{{ record.freeParkTime + ' 分钟' }} 
+				</template>
+				<template v-if="column.dataIndex === 'exceedAmount'">
+					{{ record.exceedAmount + ' 元/小时' }} 
+				</template>
+				<template v-if="column.dataIndex === 'payAfterParkTime'">
+					{{ record.payAfterParkTime + ' 分钟' }} 
+				</template>
 				<template v-if="column.dataIndex === 'action'">
 					<a-space>
 						<a @click="formRef.onOpen(record)" v-if="hasPerm('bizParkConfigEdit')">编辑</a>
@@ -48,6 +63,7 @@
 	import { cloneDeep } from 'lodash-es'
 	import Form from './form.vue'
 	import bizParkConfigApi from '@/api/biz/bizParkConfigApi'
+	import tool from '@/utils/tool'
 
 	const searchFormState = ref({})
 	const searchFormRef = ref()
@@ -64,22 +80,27 @@
 		},
 		{
 			title: '预约类型',
-			dataIndex: 'appointmentType'
+			dataIndex: 'appointmentType',
+			align:'center'
 		},
 		{
 			title: '免费停留时长',
-			dataIndex: 'freeParkTime'
+			dataIndex: 'freeParkTime',
+			align:'center'
 		},
 		{
 			title: '超出每小时费用',
-			dataIndex: 'exceedAmount'
+			dataIndex: 'exceedAmount',
+			align:'center'
 		},
 		{
 			title: '支付后停留时长',
-			dataIndex: 'payAfterParkTime'
+			dataIndex: 'payAfterParkTime',
+			align:'center'
 		},
 		{
 			title: '创建时间',
+			width: 180,
 			dataIndex: 'createTime',
 			align: 'center'
 		},
@@ -118,8 +139,8 @@
 					}
 				]
 
-				bizServiceCustomerApi
-					.bizServiceCustomerDelete(params)
+				bizParkConfigApi
+					.bizParkConfigDelete(params)
 					.then(() => {
 						tableRef.value.refresh(true)
 					})
@@ -130,4 +151,7 @@
 			onCancel() {}
 		})
 	}
+
+	// 预约分类
+	const appointmentClassifyOptions = tool.dictList('appointment_classify')
 </script>

+ 1 - 0
snowy-admin-web/src/views/biz/bizprocess/form.vue

@@ -50,6 +50,7 @@
 	}
 	// 默认要校验的
 	const formRules = {
+		processName: [required('请输入工序名称')]
 	}
 	// 验证并提交数据
 	const onSubmit = () => {

+ 16 - 4
snowy-admin-web/src/views/biz/bizprocess/index.vue

@@ -36,23 +36,33 @@
 						<a @click="formRef.onOpen(record)" v-if="hasPerm('bizProcessEdit')">编辑</a>
 						<a-divider type="vertical" v-if="hasPerm(['bizProcessEdit', 'bizProcessDelete'], 'and')" />
 						<a-button type="link" danger size="small" v-if="hasPerm('bizProcessDelete')" @click="deleteConfig(record)">删除</a-button>
+					
+						<a-divider type="vertical" v-if="hasPerm(['bizProcessEdit', 'bizProcessDelete'], 'or') && hasPerm('bizProcessNode')" />
+						<a @click="nodeIndexRef.onOpen(record)" v-if="hasPerm('bizProcessNode')">节点</a>
+
 					</a-space>
 				</template>
 			</template>
 		</s-table>
 	</a-card>
 	<Form ref="formRef" @successful="tableRef.refresh()" />
+	<NodeIndex ref="nodeIndexRef" @successful="tableRef.refresh()" />
 </template>
 
 <script setup name="bizprocess">
 	import { cloneDeep } from 'lodash-es'
 	import Form from './form.vue'
+	import NodeIndex from './nodeIndex.vue'
 	import bizProcessApi from '@/api/biz/bizProcessApi'
+	import {ExclamationCircleOutlined} from '@ant-design/icons-vue';
+	import {Modal} from 'ant-design-vue';
+	import {createVNode} from 'vue';
 
 	const searchFormState = ref({})
 	const searchFormRef = ref()
 	const tableRef = ref()
 	const formRef = ref()
+	const nodeIndexRef = ref()
 	const submitLoading = ref(false)
 	const toolConfig = { refresh: true, height: true, columnSetting: true, striped: false }
 	const columns = [
@@ -64,10 +74,12 @@
 		},
 		{
 			title: '工序名称',
-			dataIndex: 'processName'
+			dataIndex: 'processName',
+			align:'center'
 		},
 		{
 			title: '创建时间',
+			width: 180,
 			dataIndex: 'createTime',
 			align: 'center'
 		},
@@ -78,7 +90,7 @@
 			title: '操作',
 			dataIndex: 'action',
 			align: 'center',
-			width: 150
+			width: 260
 		})
 	}
 	const loadData = (parameter) => {
@@ -106,8 +118,8 @@
 					}
 				]
 
-				bizServiceCustomerApi
-					.bizServiceCustomerDelete(params)
+				bizProcessApi
+					.bizProcessDelete(params)
 					.then(() => {
 						tableRef.value.refresh(true)
 					})

+ 3 - 4
snowy-admin-web/src/views/biz/bizprocess/nodeForm.vue

@@ -7,9 +7,6 @@
 		@close="onClose"
 	>
 		<a-form ref="formRef" :model="formData" :rules="formRules" :wrapper-col="wrapperCol" :label-col="labelCol">
-			<a-form-item label="工序id:" name="processId">
-				<a-input v-model:value="formData.processId" placeholder="请输入工序id" allow-clear />
-			</a-form-item>
 			<a-form-item label="节点名称:" name="nodeName">
 				<a-input v-model:value="formData.nodeName" placeholder="请输入节点名称" allow-clear />
 			</a-form-item>
@@ -38,8 +35,9 @@
 	const wrapperCol = ref({ span: 16})
 
 	// 打开抽屉
-	const onOpen = (record) => {
+	const onOpen = (record, processId) => {
 		open.value = true
+		formData.value.processId = processId
 		if (record) {
 			let recordData = cloneDeep(record)
 			formData.value = Object.assign({}, recordData)
@@ -53,6 +51,7 @@
 	}
 	// 默认要校验的
 	const formRules = {
+		nodeName: [required('请输入节点名称')]
 	}
 	// 验证并提交数据
 	const onSubmit = () => {

+ 86 - 73
snowy-admin-web/src/views/biz/bizprocess/nodeIndex.vue

@@ -1,53 +1,58 @@
 <template>
-	<a-card :bordered="false">
-		<s-table
-			ref="tableRef"
-			:columns="columns"
-			:data="loadData"
-			:alert="options.alert.show"
-			bordered
-			:row-key="(record) => record.id"
-			:tool-config="toolConfig"
-			:row-selection="options.rowSelection"
-		>
-			<template #operator class="table-operator">
-				<a-space>
-					<a-button type="primary" @click="formRef.onOpen()" v-if="hasPerm('bizProcessNodeAdd')">
-						<template #icon><plus-outlined /></template>
-						新增
-					</a-button>
-					<xn-batch-button
-						v-if="hasPerm('bizProcessNodeBatchDelete')"
-						buttonName="批量删除"
-                        icon="DeleteOutlined"
-						:selectedRowKeys="selectedRowKeys"
-						@batchCallBack="deleteBatchBizProcessNode"
-					/>
-				</a-space>
-			</template>
-			<template #bodyCell="{ column, record }">
-				<template v-if="column.dataIndex === 'action'">
+	<a-drawer :title="title" :width="850" :open="visible" :destroy-on-close="true" @close="onClose">
+		<a-card :bordered="false" class="mb-2">
+			<s-table
+				ref="tableRef"
+				:columns="columns"
+				:data="loadData"
+				bordered
+				:row-key="(record) => record.id"
+			>
+				<template #operator class="table-operator">
 					<a-space>
-						<a @click="formRef.onOpen(record)" v-if="hasPerm('bizProcessNodeEdit')">编辑</a>
-						<a-divider type="vertical" v-if="hasPerm(['bizProcessNodeEdit', 'bizProcessNodeDelete'], 'and')" />
-						<a-popconfirm title="确定要删除吗?" @confirm="deleteBizProcessNode(record)">
-							<a-button type="link" danger size="small" v-if="hasPerm('bizProcessNodeDelete')">删除</a-button>
-						</a-popconfirm>
+						<a-button type="primary" @click="formRef.onOpen(null, processId)" v-if="hasPerm('bizProcessNodeAdd')">
+							<template #icon><plus-outlined /></template> 新增
+						</a-button>
 					</a-space>
 				</template>
-			</template>
-		</s-table>
-	</a-card>
+				<template #bodyCell="{ column, record, index }">
+					<template v-if="column.dataIndex === 'serial'">
+						{{ index + 1 }}
+					</template>
+					<template v-if="column.dataIndex === 'action'">
+						<a-space>
+							<a @click="formRef.onOpen(record, processId)" v-if="hasPerm('bizProcessNodeEdit')">编辑</a>
+							<a-divider type="vertical" v-if="hasPerm(['bizProcessNodeEdit', 'bizProcessNodeDelete'], 'and')" />
+							<a-button type="link" danger size="small" v-if="hasPerm('bizProcessNodeDelete')" @click="deleteConfig(record)">删除</a-button>
+						</a-space>
+					</template>
+				</template>
+			</s-table>
+		</a-card>
+	</a-drawer>
+
 	<Form ref="formRef" @successful="tableRef.refresh()" />
 </template>
 
-<script setup name="bizprocessnode">
+<script setup name="bizsupplieraccount">
 	import { cloneDeep } from 'lodash-es'
-	import Form from './form.vue'
+	import Form from './nodeForm.vue'
 	import bizProcessNodeApi from '@/api/biz/bizProcessNodeApi'
+	import {ExclamationCircleOutlined} from '@ant-design/icons-vue';
+	import {Modal} from 'ant-design-vue';
+	import {createVNode} from 'vue';
+	
+	const submitLoading = ref(false)
+	const toolConfig = { refresh: true, height: false, columnSetting: false, striped: false }
+	// 默认是关闭状态
+	const visible = ref(false)
+	const searchFormState = ref({})
 	const tableRef = ref()
 	const formRef = ref()
-	const toolConfig = { refresh: true, height: true, columnSetting: true, striped: false }
+	const recordData = ref()
+	const title = ref()
+	const processId = ref()
+
 	const columns = [
 		{
 			title: '序号',
@@ -57,10 +62,12 @@
 		},
 		{
 			title: '节点名称',
-			dataIndex: 'nodeName'
+			dataIndex: 'nodeName',
+			align: 'center',
 		},
 		{
 			title: '创建时间',
+			width: 180,
 			dataIndex: 'createTime',
 			align: 'center'
 		},
@@ -74,47 +81,53 @@
 			width: 150
 		})
 	}
-	const selectedRowKeys = ref([])
-	// 列表选择配置
-	const options = {
-		// columns数字类型字段加入 needTotal: true 可以勾选自动算账
-		alert: {
-			show: true,
-			clear: () => {
-				selectedRowKeys.value = ref([])
-			}
-		},
-		rowSelection: {
-			onChange: (selectedRowKey, selectedRows) => {
-				selectedRowKeys.value = selectedRowKey
-			}
+	// 打开抽屉
+	const onOpen = (record) => {
+		recordData.value = record
+		title.value = "【" + record.processName + "】-节点管理"
+		searchFormState.value = {
+			processId: record.id
 		}
+		processId.value = record.id
+		visible.value = true
 	}
 	const loadData = (parameter) => {
-		return bizProcessNodeApi.bizProcessNodePage(parameter).then((data) => {
+		return bizProcessNodeApi.bizProcessNodePage(Object.assign(parameter, searchFormState.value)).then((data) => {
 			return data
 		})
 	}
-	// 重置
-	const reset = () => {
-		searchFormRef.value.resetFields()
-		tableRef.value.refresh(true)
+	// 关闭抽屉
+	const onClose = () => {
+		visible.value = false
 	}
 	// 删除
-	const deleteBizProcessNode = (record) => {
-		let params = [
-			{
-				id: record.id
-			}
-		]
-		bizProcessNodeApi.bizProcessNodeDelete(params).then(() => {
-			tableRef.value.refresh(true)
-		})
-	}
-	// 批量删除
-	const deleteBatchBizProcessNode = (params) => {
-		bizProcessNodeApi.bizProcessNodeDelete(params).then(() => {
-			tableRef.value.clearRefreshSelected()
+	const deleteConfig = (record) => {
+		Modal.confirm({
+			title: '确定删除该数据吗?',
+			icon: createVNode(ExclamationCircleOutlined),
+			content: '',
+			onOk() {
+				submitLoading.value = true
+				let params = [
+					{
+						id: record.id
+					}
+				]
+
+				bizProcessNodeApi
+					.bizProcessNodeDelete(params)
+					.then(() => {
+						tableRef.value.refresh(true)
+					})
+					.finally(() => {
+						submitLoading.value = false
+					})
+			},
+			onCancel() {}
 		})
 	}
+	// 调用这个函数将子组件的一些数据和方法暴露出去
+	defineExpose({
+		onOpen
+	})
 </script>

+ 2 - 1
snowy-admin-web/src/views/biz/bizservicecustomer/accountForm.vue

@@ -38,8 +38,9 @@
 	const wrapperCol = ref({ span: 16})
 
 	// 打开抽屉
-	const onOpen = (record) => {
+	const onOpen = (record, serviceCustomerId) => {
 		open.value = true
+		formData.value.serviceCustomerId = serviceCustomerId
 		if (record) {
 			let recordData = cloneDeep(record)
 			formData.value = Object.assign({}, recordData)

+ 2 - 2
snowy-admin-web/src/views/biz/bizservicecustomer/index.vue

@@ -3,8 +3,8 @@
 		<a-form ref="searchFormRef" name="advanced_search" :model="searchFormState" class="ant-advanced-search-form">
 			<a-row :gutter="24">
 				<a-col :span="6">
-					<a-form-item label="客户" name="name">
-						<a-input v-model:value="searchFormState.name" placeholder="查询客户名称" allow-clear  />
+					<a-form-item label="客户" name="customerName">
+						<a-input v-model:value="searchFormState.customerName" placeholder="查询客户名称" allow-clear  />
 					</a-form-item>
 				</a-col>
 				<a-col :span="6">

+ 15 - 9
snowy-admin-web/src/views/biz/bizvehicle/index.vue

@@ -20,6 +20,11 @@
 				<a-col :span="6">
 					<a-button type="primary" @click="tableRef.refresh()">查询</a-button>
 					<a-button style="margin: 0 8px" @click="reset">重置</a-button>
+
+					<a-button type="primary" @click="formRef.onOpen()" v-if="hasPerm('bizVehicleAdd')">
+						<template #icon><plus-outlined /></template>
+						新增
+					</a-button>
 				</a-col>
 			</a-row>
 		</a-form>
@@ -32,15 +37,10 @@
 			bordered
 			:row-key="(record) => record.id"
 		>
-			<template #operator class="table-operator">
-				<a-space>
-					<a-button type="primary" @click="formRef.onOpen()" v-if="hasPerm('bizVehicleAdd')">
-						<template #icon><plus-outlined /></template>
-						新增
-					</a-button>
-				</a-space>
-			</template>
-			<template #bodyCell="{ column, record }">
+			<template #bodyCell="{ column, record, index }">
+				<template v-if="column.dataIndex === 'serial'">
+					{{ index + 1 }}
+				</template>
 				<template v-if="column.dataIndex === 'action'">
 					<a-space>
 						<a @click="formRef.onOpen(record)" v-if="hasPerm('bizVehicleEdit')">编辑</a>
@@ -79,6 +79,12 @@
 	const searchFormRef = ref()
 
 	const columns = [
+		{
+			title: '序号',
+			width: 50,
+			dataIndex: 'serial',
+			align:'center'
+		},
 		{
 			title: '车牌号',
 			dataIndex: 'licensePlate',

+ 8 - 4
snowy-admin-web/src/views/biz/customer/index.vue

@@ -77,26 +77,30 @@
 		},
 		{
 			title: '客户名称',
-			width: 180,
+			align:'center',
 			dataIndex: 'name'
 		},
 		{
 			title: '联系人',
-			width: 80,
+			width: 120,
+			align:'center',
 			dataIndex: 'contact'
 		},
 		{
 			title: '手机号',
-			width: 80,
+			width: 120,
+			align:'center',
 			dataIndex: 'phone'
 		},
 		{
 			title: '客户地址',
-			width: 250,
+			align:'center',
 			dataIndex: 'address'
 		},
 		{
 			title: '备注',
+			width: 200,
+			align:'center',
 			dataIndex: 'remark'
 		},
 	]

+ 2 - 2
snowy-plugin/snowy-plugin-biz/src/main/java/vip/xiaonuo/biz/modular/bizloadpoint/enums/BizLoadPointEnum.java

@@ -23,8 +23,8 @@ import lombok.Getter;
 @Getter
 public enum BizLoadPointEnum {
 
-    /** 测试 */
-    TEST("TEST");
+    /** 未删除 */
+    NOT_DELETE("NOT_DELETE");
 
     private final String value;
 

+ 3 - 0
snowy-plugin/snowy-plugin-biz/src/main/java/vip/xiaonuo/biz/modular/bizloadtime/service/BizLoadTimeService.java

@@ -82,6 +82,9 @@ public interface BizLoadTimeService extends IService<BizLoadTime> {
     // 根据提货时间配置ID和装货点位ID获取装货时间配置
     List<BizLoadTime> search(BizLoadTimePageParam bizLoadTimePageParam);
 
+    // 增加预约次数
+    void addAlready(BizLoadTimeIdParam bizLoadTimeIdParam);
+
     /**
      * 获取装货时间配置详情
      *

+ 22 - 1
snowy-plugin/snowy-plugin-biz/src/main/java/vip/xiaonuo/biz/modular/bizloadtime/service/impl/BizLoadTimeServiceImpl.java

@@ -70,7 +70,7 @@ public class BizLoadTimeServiceImpl extends ServiceImpl<BizLoadTimeMapper, BizLo
             queryWrapper.eq("t.point_id", bizLoadTimePageParam.getPointId());
         }
         if(ObjectUtil.isNotEmpty(bizLoadTimePageParam.getLoadPoint())) {
-            queryWrapper.eq("p.load_point", bizLoadTimePageParam.getLoadPoint());
+            queryWrapper.like("p.load_point", bizLoadTimePageParam.getLoadPoint());
         }
         if(ObjectUtil.isNotEmpty(bizLoadTimePageParam.getStartLoadBeginTime()) && ObjectUtil.isNotEmpty(bizLoadTimePageParam.getEndLoadBeginTime())) {
             queryWrapper.between("t.begin_time", bizLoadTimePageParam.getStartLoadBeginTime(), bizLoadTimePageParam.getEndLoadBeginTime());
@@ -160,6 +160,27 @@ public class BizLoadTimeServiceImpl extends ServiceImpl<BizLoadTimeMapper, BizLo
         }
     }
 
+    @Transactional(rollbackFor = Exception.class)
+    @Override
+    public void addAlready(BizLoadTimeIdParam bizLoadTimeIdParam) {
+        BizLoadTime bizLoadTime = this.queryEntity(bizLoadTimeIdParam.getId());
+        if(null == bizLoadTime){
+            throw new CommonException("装货配置时间段不存在!");
+        }
+        /** 可约次数 */
+        Integer availableNumber = bizLoadTime.getAvailableNumber();
+        /** 已约次数 */
+        Integer alreadyNumber = bizLoadTime.getAlreadyNumber();
+
+        if(availableNumber <= alreadyNumber){
+            throw new CommonException("装货配置时间段已不可预约!");
+        }else {
+            alreadyNumber += 1;
+            bizLoadTime.setAlreadyNumber(alreadyNumber);
+            this.updateById(bizLoadTime);
+        }
+    }
+
     @Override
     public BizLoadTime queryEntity(String id) {
         BizLoadTime bizLoadTime = this.getById(id);

+ 2 - 2
snowy-plugin/snowy-plugin-biz/src/main/java/vip/xiaonuo/biz/modular/bizparkconfig/entity/BizParkConfig.java

@@ -41,7 +41,7 @@ public class BizParkConfig extends CommonEntity {
     @Schema(description = "预约类型")
     private String appointmentType;
 
-    /** 免费停留时长 */
+    /** 免费停留时长:分钟 */
     @Schema(description = "免费停留时长")
     private Integer freeParkTime;
 
@@ -49,7 +49,7 @@ public class BizParkConfig extends CommonEntity {
     @Schema(description = "超出每小时费用")
     private BigDecimal exceedAmount;
 
-    /** 支付后停留时长 */
+    /** 支付后停留时长:分钟 */
     @Schema(description = "支付后停留时长")
     private Integer payAfterParkTime;
 }

+ 2 - 2
snowy-plugin/snowy-plugin-biz/src/main/java/vip/xiaonuo/biz/modular/bizparkconfig/enums/BizParkConfigEnum.java

@@ -23,8 +23,8 @@ import lombok.Getter;
 @Getter
 public enum BizParkConfigEnum {
 
-    /** 测试 */
-    TEST("TEST");
+    /** 未删除 */
+    NOT_DELETE("NOT_DELETE");
 
     private final String value;
 

+ 18 - 2
snowy-plugin/snowy-plugin-biz/src/main/java/vip/xiaonuo/biz/modular/bizparkconfig/service/impl/BizParkConfigServiceImpl.java

@@ -23,6 +23,9 @@ import org.springframework.stereotype.Service;
 import org.springframework.transaction.annotation.Transactional;
 import vip.xiaonuo.biz.modular.bizloadpoint.entity.BizLoadPoint;
 import vip.xiaonuo.biz.modular.bizloadpoint.param.BizLoadPointPageParam;
+import vip.xiaonuo.biz.modular.bizparkconfig.enums.BizParkConfigEnum;
+import vip.xiaonuo.biz.modular.bizprocess.entity.BizProcess;
+import vip.xiaonuo.biz.modular.bizprocess.enums.BizProcessEnum;
 import vip.xiaonuo.biz.modular.bizsupplier.entity.BizSupplier;
 import vip.xiaonuo.common.enums.CommonSortOrderEnum;
 import vip.xiaonuo.common.exception.CommonException;
@@ -50,7 +53,7 @@ public class BizParkConfigServiceImpl extends ServiceImpl<BizParkConfigMapper, B
     public Page<BizParkConfig> page(BizParkConfigPageParam bizParkConfigPageParam) {
         QueryWrapper<BizParkConfig> queryWrapper = new QueryWrapper<BizParkConfig>().checkSqlInjection();
         if(ObjectUtil.isNotEmpty(bizParkConfigPageParam.getAppointmentType())) {
-            queryWrapper.lambda().like(BizParkConfig::getAppointmentType, bizParkConfigPageParam.getAppointmentType());
+            queryWrapper.lambda().eq(BizParkConfig::getAppointmentType, bizParkConfigPageParam.getAppointmentType());
         }
         queryWrapper.lambda().eq(BizParkConfig::getDeleteFlag, "NOT_DELETE");
         if(ObjectUtil.isAllNotEmpty(bizParkConfigPageParam.getSortField(), bizParkConfigPageParam.getSortOrder())) {
@@ -58,7 +61,7 @@ public class BizParkConfigServiceImpl extends ServiceImpl<BizParkConfigMapper, B
             queryWrapper.orderBy(true, bizParkConfigPageParam.getSortOrder().equals(CommonSortOrderEnum.ASC.getValue()),
                     StrUtil.toUnderlineCase(bizParkConfigPageParam.getSortField()));
         } else {
-            queryWrapper.lambda().orderByAsc(BizParkConfig::getId);
+            queryWrapper.lambda().orderByDesc(BizParkConfig::getCreateTime);
         }
         return this.page(CommonPageRequest.defaultPage(), queryWrapper);
     }
@@ -66,6 +69,12 @@ public class BizParkConfigServiceImpl extends ServiceImpl<BizParkConfigMapper, B
     @Transactional(rollbackFor = Exception.class)
     @Override
     public void add(BizParkConfigAddParam bizParkConfigAddParam) {
+        //查询是否添加过
+        long count = this.count(new QueryWrapper<BizParkConfig>().lambda().eq(BizParkConfig::getAppointmentType, bizParkConfigAddParam.getAppointmentType())
+                                                                    .eq(BizParkConfig::getDeleteFlag, BizParkConfigEnum.NOT_DELETE.getValue()));
+        if(count>0){
+            throw new CommonException("预约类型的停车费配置已存在!");
+        }
         BizParkConfig bizParkConfig = BeanUtil.toBean(bizParkConfigAddParam, BizParkConfig.class);
         this.save(bizParkConfig);
     }
@@ -73,6 +82,13 @@ public class BizParkConfigServiceImpl extends ServiceImpl<BizParkConfigMapper, B
     @Transactional(rollbackFor = Exception.class)
     @Override
     public void edit(BizParkConfigEditParam bizParkConfigEditParam) {
+        //查询是否添加过
+        long count = this.count(new QueryWrapper<BizParkConfig>().lambda().eq(BizParkConfig::getAppointmentType, bizParkConfigEditParam.getAppointmentType())
+                                                                        .ne(BizParkConfig::getId, bizParkConfigEditParam.getId())
+                                                                        .eq(BizParkConfig::getDeleteFlag, BizParkConfigEnum.NOT_DELETE.getValue()));
+        if(count>0){
+            throw new CommonException("预约类型的停车费配置已存在!");
+        }
         BizParkConfig bizParkConfig = this.queryEntity(bizParkConfigEditParam.getId());
         BeanUtil.copyProperties(bizParkConfigEditParam, bizParkConfig);
         this.updateById(bizParkConfig);

+ 2 - 2
snowy-plugin/snowy-plugin-biz/src/main/java/vip/xiaonuo/biz/modular/bizprocess/enums/BizProcessEnum.java

@@ -23,8 +23,8 @@ import lombok.Getter;
 @Getter
 public enum BizProcessEnum {
 
-    /** 测试 */
-    TEST("TEST");
+    /** 未删除 */
+    NOT_DELETE("NOT_DELETE");
 
     private final String value;
 

+ 2 - 2
snowy-plugin/snowy-plugin-biz/src/main/java/vip/xiaonuo/biz/modular/bizprocess/enums/BizProcessNodeEnum.java

@@ -23,8 +23,8 @@ import lombok.Getter;
 @Getter
 public enum BizProcessNodeEnum {
 
-    /** 测试 */
-    TEST("TEST");
+    /** 未删除 */
+    NOT_DELETE("NOT_DELETE");
 
     private final String value;
 

+ 4 - 0
snowy-plugin/snowy-plugin-biz/src/main/java/vip/xiaonuo/biz/modular/bizprocess/param/BizProcessNodePageParam.java

@@ -46,4 +46,8 @@ public class BizProcessNodePageParam {
     @Schema(description = "关键词")
     private String searchKey;
 
+    /** 工序id */
+    @Schema(description = "工序id")
+    private String processId;
+
 }

+ 21 - 1
snowy-plugin/snowy-plugin-biz/src/main/java/vip/xiaonuo/biz/modular/bizprocess/service/impl/BizProcessNodeServiceImpl.java

@@ -21,6 +21,8 @@ import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
 import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
 import org.springframework.stereotype.Service;
 import org.springframework.transaction.annotation.Transactional;
+import vip.xiaonuo.biz.modular.bizprocess.entity.BizProcess;
+import vip.xiaonuo.biz.modular.bizprocess.enums.BizProcessNodeEnum;
 import vip.xiaonuo.common.enums.CommonSortOrderEnum;
 import vip.xiaonuo.common.exception.CommonException;
 import vip.xiaonuo.common.page.CommonPageRequest;
@@ -46,12 +48,15 @@ public class BizProcessNodeServiceImpl extends ServiceImpl<BizProcessNodeMapper,
     @Override
     public Page<BizProcessNode> page(BizProcessNodePageParam bizProcessNodePageParam) {
         QueryWrapper<BizProcessNode> queryWrapper = new QueryWrapper<BizProcessNode>().checkSqlInjection();
+        if(ObjectUtil.isNotEmpty(bizProcessNodePageParam.getProcessId())){
+            queryWrapper.lambda().like(BizProcessNode::getProcessId, bizProcessNodePageParam.getProcessId());
+        }
         if(ObjectUtil.isAllNotEmpty(bizProcessNodePageParam.getSortField(), bizProcessNodePageParam.getSortOrder())) {
             CommonSortOrderEnum.validate(bizProcessNodePageParam.getSortOrder());
             queryWrapper.orderBy(true, bizProcessNodePageParam.getSortOrder().equals(CommonSortOrderEnum.ASC.getValue()),
                     StrUtil.toUnderlineCase(bizProcessNodePageParam.getSortField()));
         } else {
-            queryWrapper.lambda().orderByAsc(BizProcessNode::getId);
+            queryWrapper.lambda().orderByDesc(BizProcessNode::getCreateTime);
         }
         return this.page(CommonPageRequest.defaultPage(), queryWrapper);
     }
@@ -59,6 +64,13 @@ public class BizProcessNodeServiceImpl extends ServiceImpl<BizProcessNodeMapper,
     @Transactional(rollbackFor = Exception.class)
     @Override
     public void add(BizProcessNodeAddParam bizProcessNodeAddParam) {
+        //查询名称是否添加过
+        long countName = this.count(new QueryWrapper<BizProcessNode>().lambda().eq(BizProcessNode::getNodeName, bizProcessNodeAddParam.getNodeName())
+                                                                            .eq(BizProcessNode::getProcessId, bizProcessNodeAddParam.getProcessId())
+                                                                            .eq(BizProcessNode::getDeleteFlag, BizProcessNodeEnum.NOT_DELETE.getValue()));
+        if(countName>0){
+            throw new CommonException("生产工序节点名称已存在!");
+        }
         BizProcessNode bizProcessNode = BeanUtil.toBean(bizProcessNodeAddParam, BizProcessNode.class);
         this.save(bizProcessNode);
     }
@@ -66,6 +78,14 @@ public class BizProcessNodeServiceImpl extends ServiceImpl<BizProcessNodeMapper,
     @Transactional(rollbackFor = Exception.class)
     @Override
     public void edit(BizProcessNodeEditParam bizProcessNodeEditParam) {
+        //查询名称是否添加过
+        long countName = this.count(new QueryWrapper<BizProcessNode>().lambda().eq(BizProcessNode::getNodeName, bizProcessNodeEditParam.getNodeName())
+                                                        .eq(BizProcessNode::getProcessId, bizProcessNodeEditParam.getProcessId())
+                                                        .ne(BizProcessNode::getId, bizProcessNodeEditParam.getId())
+                                                        .eq(BizProcessNode::getDeleteFlag, BizProcessNodeEnum.NOT_DELETE.getValue()));
+        if(countName>0){
+            throw new CommonException("生产工序节点名称已存在!");
+        }
         BizProcessNode bizProcessNode = this.queryEntity(bizProcessNodeEditParam.getId());
         BeanUtil.copyProperties(bizProcessNodeEditParam, bizProcessNode);
         this.updateById(bizProcessNode);

+ 15 - 4
snowy-plugin/snowy-plugin-biz/src/main/java/vip/xiaonuo/biz/modular/bizprocess/service/impl/BizProcessServiceImpl.java

@@ -21,9 +21,7 @@ import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
 import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
 import org.springframework.stereotype.Service;
 import org.springframework.transaction.annotation.Transactional;
-import vip.xiaonuo.biz.modular.bizloadpoint.entity.BizLoadPoint;
-import vip.xiaonuo.biz.modular.bizparkconfig.entity.BizParkConfig;
-import vip.xiaonuo.biz.modular.bizparkconfig.param.BizParkConfigPageParam;
+import vip.xiaonuo.biz.modular.bizprocess.enums.BizProcessEnum;
 import vip.xiaonuo.common.enums.CommonSortOrderEnum;
 import vip.xiaonuo.common.exception.CommonException;
 import vip.xiaonuo.common.page.CommonPageRequest;
@@ -57,7 +55,7 @@ public class BizProcessServiceImpl extends ServiceImpl<BizProcessMapper, BizProc
             queryWrapper.orderBy(true, bizProcessPageParam.getSortOrder().equals(CommonSortOrderEnum.ASC.getValue()),
                     StrUtil.toUnderlineCase(bizProcessPageParam.getSortField()));
         } else {
-            queryWrapper.lambda().orderByAsc(BizProcess::getId);
+            queryWrapper.lambda().orderByDesc(BizProcess::getCreateTime);
         }
         return this.page(CommonPageRequest.defaultPage(), queryWrapper);
     }
@@ -65,6 +63,12 @@ public class BizProcessServiceImpl extends ServiceImpl<BizProcessMapper, BizProc
     @Transactional(rollbackFor = Exception.class)
     @Override
     public void add(BizProcessAddParam bizProcessAddParam) {
+        //查询名称是否添加过
+        long countName = this.count(new QueryWrapper<BizProcess>().lambda().eq(BizProcess::getProcessName, bizProcessAddParam.getProcessName())
+                                                                        .eq(BizProcess::getDeleteFlag, BizProcessEnum.NOT_DELETE.getValue()));
+        if(countName>0){
+            throw new CommonException("生产工序名称已存在!");
+        }
         BizProcess bizProcess = BeanUtil.toBean(bizProcessAddParam, BizProcess.class);
         this.save(bizProcess);
     }
@@ -72,6 +76,13 @@ public class BizProcessServiceImpl extends ServiceImpl<BizProcessMapper, BizProc
     @Transactional(rollbackFor = Exception.class)
     @Override
     public void edit(BizProcessEditParam bizProcessEditParam) {
+        //查询名称是否添加过
+        long countName = this.count(new QueryWrapper<BizProcess>().lambda().eq(BizProcess::getProcessName, bizProcessEditParam.getProcessName())
+                                                                        .ne(BizProcess::getId, bizProcessEditParam.getId())
+                                                                        .eq(BizProcess::getDeleteFlag, BizProcessEnum.NOT_DELETE.getValue()));
+        if(countName>0){
+            throw new CommonException("生产工序名称已存在!");
+        }
         BizProcess bizProcess = this.queryEntity(bizProcessEditParam.getId());
         BeanUtil.copyProperties(bizProcessEditParam, bizProcess);
         this.updateById(bizProcess);

+ 2 - 2
snowy-plugin/snowy-plugin-biz/src/main/java/vip/xiaonuo/biz/modular/bizservicecustomer/enums/BizServiceCustomerAccountEnum.java

@@ -23,8 +23,8 @@ import lombok.Getter;
 @Getter
 public enum BizServiceCustomerAccountEnum {
 
-    /** 测试 */
-    TEST("TEST");
+    /** 未删除 */
+    NOT_DELETE("NOT_DELETE");
 
     private final String value;
 

+ 2 - 2
snowy-plugin/snowy-plugin-biz/src/main/java/vip/xiaonuo/biz/modular/bizservicecustomer/enums/BizServiceCustomerEnum.java

@@ -23,8 +23,8 @@ import lombok.Getter;
 @Getter
 public enum BizServiceCustomerEnum {
 
-    /** 测试 */
-    TEST("TEST");
+    /** 未删除 */
+    NOT_DELETE("NOT_DELETE");
 
     private final String value;
 

+ 2 - 2
snowy-plugin/snowy-plugin-biz/src/main/java/vip/xiaonuo/biz/modular/bizservicecustomer/enums/BizServiceCustomerFlowEnum.java

@@ -23,8 +23,8 @@ import lombok.Getter;
 @Getter
 public enum BizServiceCustomerFlowEnum {
 
-    /** 测试 */
-    TEST("TEST");
+    /** 未删除 */
+    NOT_DELETE("NOT_DELETE");
 
     private final String value;
 

+ 4 - 0
snowy-plugin/snowy-plugin-biz/src/main/java/vip/xiaonuo/biz/modular/bizservicecustomer/param/BizServiceCustomerPageParam.java

@@ -48,4 +48,8 @@ public class BizServiceCustomerPageParam {
     @Schema(description = "关键词")
     private String searchKey;
 
+    /** 客户名称 */
+    @Schema(description = "客户名称")
+    private String customerName;
+
 }

+ 8 - 3
snowy-plugin/snowy-plugin-biz/src/main/java/vip/xiaonuo/biz/modular/bizservicecustomer/service/impl/BizServiceCustomerAccountServiceImpl.java

@@ -19,12 +19,10 @@ import cn.hutool.core.util.StrUtil;
 import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
 import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
 import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
-import io.swagger.v3.oas.annotations.media.Schema;
 import org.springframework.stereotype.Service;
 import org.springframework.transaction.annotation.Transactional;
-import vip.xiaonuo.biz.modular.bizservicecustomer.entity.BizServiceCustomerFlow;
+import vip.xiaonuo.biz.modular.bizservicecustomer.enums.BizServiceCustomerAccountEnum;
 import vip.xiaonuo.biz.modular.bizservicecustomer.param.*;
-import vip.xiaonuo.biz.modular.bizsupplier.entity.BizSupplierAccount;
 import vip.xiaonuo.common.enums.CommonSortOrderEnum;
 import vip.xiaonuo.common.exception.CommonException;
 import vip.xiaonuo.common.page.CommonPageRequest;
@@ -63,6 +61,9 @@ public class BizServiceCustomerAccountServiceImpl extends ServiceImpl<BizService
     @Transactional(rollbackFor = Exception.class)
     @Override
     public void add(BizServiceCustomerAccountAddParam bizServiceCustomerAccountAddParam) {
+        //查询名称是否添加过
+        long countName = this.count(new QueryWrapper<BizServiceCustomerAccount>().lambda().eq(BizServiceCustomerAccount::getLoginAccount, bizServiceCustomerAccountAddParam.getLoginAccount())
+                                                                                .eq(BizServiceCustomerAccount::getDeleteFlag, BizServiceCustomerAccountEnum.NOT_DELETE.getValue()));
         BizServiceCustomerAccount bizServiceCustomerAccount = BeanUtil.toBean(bizServiceCustomerAccountAddParam, BizServiceCustomerAccount.class);
         this.save(bizServiceCustomerAccount);
     }
@@ -70,6 +71,10 @@ public class BizServiceCustomerAccountServiceImpl extends ServiceImpl<BizService
     @Transactional(rollbackFor = Exception.class)
     @Override
     public void edit(BizServiceCustomerAccountEditParam bizServiceCustomerAccountEditParam) {
+        //查询名称是否添加过
+        long countName = this.count(new QueryWrapper<BizServiceCustomerAccount>().lambda().eq(BizServiceCustomerAccount::getLoginAccount, bizServiceCustomerAccountEditParam.getLoginAccount())
+                                                                                .ne(BizServiceCustomerAccount::getId, bizServiceCustomerAccountEditParam.getId())
+                                                                                .eq(BizServiceCustomerAccount::getDeleteFlag, BizServiceCustomerAccountEnum.NOT_DELETE.getValue()));
         BizServiceCustomerAccount bizServiceCustomerAccount = this.queryEntity(bizServiceCustomerAccountEditParam.getId());
         BeanUtil.copyProperties(bizServiceCustomerAccountEditParam, bizServiceCustomerAccount);
         this.updateById(bizServiceCustomerAccount);

+ 20 - 0
snowy-plugin/snowy-plugin-biz/src/main/java/vip/xiaonuo/biz/modular/bizservicecustomer/service/impl/BizServiceCustomerServiceImpl.java

@@ -22,7 +22,11 @@ import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
 import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
 import org.springframework.stereotype.Service;
 import org.springframework.transaction.annotation.Transactional;
+import vip.xiaonuo.biz.modular.bizservicecustomer.entity.BizServiceCustomerAccount;
 import vip.xiaonuo.biz.modular.bizservicecustomer.entity.BizServiceCustomerFlow;
+import vip.xiaonuo.biz.modular.bizservicecustomer.enums.BizServiceCustomerEnum;
+import vip.xiaonuo.biz.modular.bizsupplier.entity.BizSupplierAccount;
+import vip.xiaonuo.biz.modular.bizsupplier.enums.BizSupplierAccountEnum;
 import vip.xiaonuo.common.enums.CommonSortOrderEnum;
 import vip.xiaonuo.common.exception.CommonException;
 import vip.xiaonuo.common.page.CommonPageRequest;
@@ -48,6 +52,9 @@ public class BizServiceCustomerServiceImpl extends ServiceImpl<BizServiceCustome
     @Override
     public Page<BizServiceCustomer> page(BizServiceCustomerPageParam bizServiceCustomerPageParam) {
         QueryWrapper<BizServiceCustomer> queryWrapper = new QueryWrapper<BizServiceCustomer>().checkSqlInjection();
+        if(ObjectUtil.isNotEmpty(bizServiceCustomerPageParam.getCustomerName())){
+            queryWrapper.lambda().like(BizServiceCustomer::getName, bizServiceCustomerPageParam.getCustomerName());
+        }
         if(ObjectUtil.isAllNotEmpty(bizServiceCustomerPageParam.getSortField(), bizServiceCustomerPageParam.getSortOrder())) {
             CommonSortOrderEnum.validate(bizServiceCustomerPageParam.getSortOrder());
             queryWrapper.orderBy(true, bizServiceCustomerPageParam.getSortOrder().equals(CommonSortOrderEnum.ASC.getValue()),
@@ -67,6 +74,12 @@ public class BizServiceCustomerServiceImpl extends ServiceImpl<BizServiceCustome
                 throw new CommonException("手机号码:{}格式错误", bizServiceCustomerAddParam.getPhone());
             }
         }
+        //查询名称是否添加过
+        long countName = this.count(new QueryWrapper<BizServiceCustomer>().lambda().eq(BizServiceCustomer::getName, bizServiceCustomerAddParam.getName())
+                                                                    .eq(BizServiceCustomer::getDeleteFlag, BizServiceCustomerEnum.NOT_DELETE.getValue()));
+        if(countName>0){
+            throw new CommonException("服务客户名称已存在!");
+        }
         BizServiceCustomer bizServiceCustomer = BeanUtil.toBean(bizServiceCustomerAddParam, BizServiceCustomer.class);
         this.save(bizServiceCustomer);
     }
@@ -80,6 +93,13 @@ public class BizServiceCustomerServiceImpl extends ServiceImpl<BizServiceCustome
                 throw new CommonException("手机号码:{}格式错误", bizServiceCustomerEditParam.getPhone());
             }
         }
+        //查询名称是否添加过
+        long countName = this.count(new QueryWrapper<BizServiceCustomer>().lambda().eq(BizServiceCustomer::getName, bizServiceCustomerEditParam.getName())
+                .ne(BizServiceCustomer::getId, bizServiceCustomerEditParam.getId())
+                .eq(BizServiceCustomer::getDeleteFlag, BizServiceCustomerEnum.NOT_DELETE.getValue()));
+        if(countName>0){
+            throw new CommonException("服务客户名称已存在!");
+        }
         BizServiceCustomer bizServiceCustomer = this.queryEntity(bizServiceCustomerEditParam.getId());
         BeanUtil.copyProperties(bizServiceCustomerEditParam, bizServiceCustomer);
         this.updateById(bizServiceCustomer);

+ 2 - 2
snowy-plugin/snowy-plugin-biz/src/main/java/vip/xiaonuo/biz/modular/bizsupplier/enums/BizSupplierAccountEnum.java

@@ -23,8 +23,8 @@ import lombok.Getter;
 @Getter
 public enum BizSupplierAccountEnum {
 
-    /** 测试 */
-    TEST("TEST");
+    /** 未删除 */
+    NOT_DELETE("NOT_DELETE");
 
     private final String value;
 

+ 2 - 2
snowy-plugin/snowy-plugin-biz/src/main/java/vip/xiaonuo/biz/modular/bizsupplier/enums/BizSupplierEnum.java

@@ -23,8 +23,8 @@ import lombok.Getter;
 @Getter
 public enum BizSupplierEnum {
 
-    /** 测试 */
-    TEST("TEST");
+    /** 未删除 */
+    NOT_DELETE("NOT_DELETE");
 
     private final String value;
 

+ 2 - 2
snowy-plugin/snowy-plugin-biz/src/main/java/vip/xiaonuo/biz/modular/bizsupplier/enums/BizSupplierTransportEnum.java

@@ -23,8 +23,8 @@ import lombok.Getter;
 @Getter
 public enum BizSupplierTransportEnum {
 
-    /** 测试 */
-    TEST("TEST");
+    /** 未删除 */
+    NOT_DELETE("NOT_DELETE");
 
     private final String value;
 

+ 7 - 2
snowy-plugin/snowy-plugin-biz/src/main/java/vip/xiaonuo/biz/modular/bizsupplier/service/impl/BizSupplierAccountServiceImpl.java

@@ -23,7 +23,10 @@ import org.springframework.stereotype.Service;
 import org.springframework.transaction.annotation.Transactional;
 import vip.xiaonuo.biz.modular.bizloadpoint.entity.BizLoadPoint;
 import vip.xiaonuo.biz.modular.bizsupplier.entity.BizSupplier;
+import vip.xiaonuo.biz.modular.bizsupplier.enums.BizSupplierAccountEnum;
 import vip.xiaonuo.biz.modular.customer.entity.BizCustomer;
+import vip.xiaonuo.biz.modular.customer.entity.BizCustomerAccount;
+import vip.xiaonuo.biz.modular.customer.enums.BizCustomerAccountEnum;
 import vip.xiaonuo.common.enums.CommonSortOrderEnum;
 import vip.xiaonuo.common.exception.CommonException;
 import vip.xiaonuo.common.page.CommonPageRequest;
@@ -67,7 +70,8 @@ public class BizSupplierAccountServiceImpl extends ServiceImpl<BizSupplierAccoun
     @Override
     public void add(BizSupplierAccountAddParam bizSupplierAccountAddParam) {
         //查询名称是否添加过
-        long countName = this.count(new QueryWrapper<BizSupplierAccount>().lambda().eq(BizSupplierAccount::getSupplierAccount, bizSupplierAccountAddParam.getSupplierAccount()));
+        long countName = this.count(new QueryWrapper<BizSupplierAccount>().lambda().eq(BizSupplierAccount::getSupplierAccount, bizSupplierAccountAddParam.getSupplierAccount())
+                                                                                    .eq(BizSupplierAccount::getDeleteFlag, BizSupplierAccountEnum.NOT_DELETE.getValue()));
         if(countName>0){
             throw new CommonException("供应商账号已存在!");
         }
@@ -80,7 +84,8 @@ public class BizSupplierAccountServiceImpl extends ServiceImpl<BizSupplierAccoun
     public void edit(BizSupplierAccountEditParam bizSupplierAccountEditParam) {
         //查询名称是否添加过
         long countName = this.count(new QueryWrapper<BizSupplierAccount>().lambda().eq(BizSupplierAccount::getSupplierAccount, bizSupplierAccountEditParam.getSupplierAccount())
-                                                                                    .ne(BizSupplierAccount::getId, bizSupplierAccountEditParam.getId()));
+                                                                                    .ne(BizSupplierAccount::getId, bizSupplierAccountEditParam.getId())
+                                                                                    .eq(BizSupplierAccount::getDeleteFlag, BizSupplierAccountEnum.NOT_DELETE.getValue()));
         if(countName>0){
             throw new CommonException("供应商账号已存在!");
         }

+ 8 - 2
snowy-plugin/snowy-plugin-biz/src/main/java/vip/xiaonuo/biz/modular/bizsupplier/service/impl/BizSupplierServiceImpl.java

@@ -22,7 +22,10 @@ import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
 import org.apache.commons.lang3.StringUtils;
 import org.springframework.stereotype.Service;
 import org.springframework.transaction.annotation.Transactional;
+import vip.xiaonuo.biz.modular.bizsupplier.entity.BizSupplierAccount;
 import vip.xiaonuo.biz.modular.bizsupplier.entity.BizSupplierTransport;
+import vip.xiaonuo.biz.modular.bizsupplier.enums.BizSupplierAccountEnum;
+import vip.xiaonuo.biz.modular.bizsupplier.enums.BizSupplierEnum;
 import vip.xiaonuo.common.exception.CommonException;
 import vip.xiaonuo.common.page.CommonPageRequest;
 import vip.xiaonuo.biz.modular.bizsupplier.entity.BizSupplier;
@@ -68,7 +71,8 @@ public class BizSupplierServiceImpl extends ServiceImpl<BizSupplierMapper, BizSu
             }
         }
         //判断供货商是否存在
-        long count = this.count(new QueryWrapper<BizSupplier>().lambda().eq(BizSupplier::getSupplierName, bizSupplierAddParam.getSupplierName()));
+        long count = this.count(new QueryWrapper<BizSupplier>().lambda().eq(BizSupplier::getSupplierName, bizSupplierAddParam.getSupplierName())
+                                                        .eq(BizSupplier::getDeleteFlag, BizSupplierEnum.NOT_DELETE.getValue()));
         if(count>0){
             throw new CommonException("供货商已存在!");
         }
@@ -88,7 +92,9 @@ public class BizSupplierServiceImpl extends ServiceImpl<BizSupplierMapper, BizSu
         BizSupplier bizSupplier = this.queryEntity(bizSupplierEditParam.getId());
         if(!StringUtils.equals(bizSupplier.getSupplierName(),bizSupplierEditParam.getSupplierName())){
             //修改过供货商名称,判断供货商是否存在
-            long count = this.count(new QueryWrapper<BizSupplier>().lambda().eq(BizSupplier::getSupplierName, bizSupplierEditParam.getSupplierName()));
+            long count = this.count(new QueryWrapper<BizSupplier>().lambda().eq(BizSupplier::getSupplierName, bizSupplierEditParam.getSupplierName())
+                                                                    .ne(BizSupplier::getId, bizSupplierEditParam.getId())
+                                                                    .eq(BizSupplier::getDeleteFlag, BizSupplierEnum.NOT_DELETE.getValue()));
             if(count>0){
                 throw new CommonException("供货商已存在!");
             }

+ 9 - 4
snowy-plugin/snowy-plugin-biz/src/main/java/vip/xiaonuo/biz/modular/bizsupplier/service/impl/BizSupplierTransportServiceImpl.java

@@ -21,7 +21,10 @@ import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
 import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
 import org.springframework.stereotype.Service;
 import org.springframework.transaction.annotation.Transactional;
+import vip.xiaonuo.biz.modular.bizsupplier.entity.BizSupplier;
 import vip.xiaonuo.biz.modular.bizsupplier.entity.BizSupplierAccount;
+import vip.xiaonuo.biz.modular.bizsupplier.enums.BizSupplierAccountEnum;
+import vip.xiaonuo.biz.modular.bizsupplier.enums.BizSupplierTransportEnum;
 import vip.xiaonuo.common.enums.CommonSortOrderEnum;
 import vip.xiaonuo.common.exception.CommonException;
 import vip.xiaonuo.common.page.CommonPageRequest;
@@ -66,9 +69,10 @@ public class BizSupplierTransportServiceImpl extends ServiceImpl<BizSupplierTran
     public void add(BizSupplierTransportAddParam bizSupplierTransportAddParam) {
         //查询名称是否添加过
         long countName = this.count(new QueryWrapper<BizSupplierTransport>().lambda().eq(BizSupplierTransport::getTransportNo, bizSupplierTransportAddParam.getTransportNo())
-                                                                                    .eq(BizSupplierTransport::getSupplierId, bizSupplierTransportAddParam.getSupplierId()));
+                                                                                    .eq(BizSupplierTransport::getSupplierId, bizSupplierTransportAddParam.getSupplierId())
+                                                                                    .eq(BizSupplierTransport::getDeleteFlag, BizSupplierTransportEnum.NOT_DELETE.getValue()));
         if(countName>0){
-            throw new CommonException("供应商号已存在!");
+            throw new CommonException("供应商运输号已存在!");
         }
         BizSupplierTransport bizSupplierTransport = BeanUtil.toBean(bizSupplierTransportAddParam, BizSupplierTransport.class);
         this.save(bizSupplierTransport);
@@ -80,9 +84,10 @@ public class BizSupplierTransportServiceImpl extends ServiceImpl<BizSupplierTran
         //查询名称是否添加过
         long countName = this.count(new QueryWrapper<BizSupplierTransport>().lambda().eq(BizSupplierTransport::getTransportNo, bizSupplierTransportEditParam.getTransportNo())
                 .eq(BizSupplierTransport::getSupplierId, bizSupplierTransportEditParam.getSupplierId())
-                .ne(BizSupplierTransport::getId, bizSupplierTransportEditParam.getId()));
+                .ne(BizSupplierTransport::getId, bizSupplierTransportEditParam.getId())
+                .eq(BizSupplierTransport::getDeleteFlag, BizSupplierTransportEnum.NOT_DELETE.getValue()));
         if(countName>0){
-            throw new CommonException("供应商号已存在!");
+            throw new CommonException("供应商运输号已存在!");
         }
         BizSupplierTransport bizSupplierTransport = this.queryEntity(bizSupplierTransportEditParam.getId());
         BeanUtil.copyProperties(bizSupplierTransportEditParam, bizSupplierTransport);