Explorar el Código

增加售后计划模块

8521520123jsy hace 1 año
padre
commit
78199929ff

+ 18 - 0
api/salesServiceManagement/toDoList/index.js

@@ -0,0 +1,18 @@
+import {
+	get,
+	put,
+	putJ,
+	postJ,
+	deleteApi
+} from "@/utils/request";
+import Vue from "vue";
+
+
+// 计划列表-------------------------------------------------------------------
+export async function getSalesPlan(params) {
+	const res = await get(Vue.prototype.apiUrl + `/eom/afterSalesPlan/page`, params);
+	if (res.code == 0) {
+		return res.data;
+	}
+	return Promise.reject(new Error(res.message));
+}

+ 7 - 0
pages/index/index.vue

@@ -429,6 +429,13 @@
 						icon: 'icon-gongdanguanli',
 						badge: 0
 					},
+					{
+						name: '售后计划',
+						url: `/pages/salesServiceManagement/toDoList/index`,
+						path: '/pages/salesServiceManagement/toDoList/index',
+						icon: 'icon-gongdanguanli',
+						badge: 0
+					},
 					// {
 					// 	name: '发货确认单',
 					// 	url: `/pages/invoiceConfirm/index`,

+ 0 - 9
pages/salesServiceManagement/demandList/add.vue

@@ -200,10 +200,6 @@
 			},
 			//客户回调
 			async contactDetail(id) {
-				// if (!id) {
-				// 	this.contractInfo = {};
-				// 	return;
-				// }
 				let {
 					base,
 					other,
@@ -217,7 +213,6 @@
 				if (other.address) {
 					addressName += other.address;
 				}
-				// this.$set(this.form, 'contractInfo', base);
 				this.form.contactCode = base.code;
 				if (this.type != 'view') {
 					this.$set(this.form, 'contactAddress', addressName);
@@ -240,9 +235,6 @@
 			sourceCodeOnchange(e) {
 				const value = e.detail.value;
 				this.form.faultLevel = value[0].value;
-				console.log(e, '赋值')
-				// this.form.sourceCode = value.map(item => item.value).toString()
-				// this.form.sourceName = value.map(item => item.text).toString()
 			},
 			invoiceDialogOpen() {
 				if (!this.form.contactId) {
@@ -348,7 +340,6 @@
 				}
 			}
 		},
-
 	}
 </script>
 

+ 2 - 2
pages/salesServiceManagement/demandList/components/contactList.vue

@@ -44,10 +44,10 @@
 </template>
 
 <script>
-	import myCard from '@/pages/saleManage/components/myCard.vue'
+	// import myCard from '@/pages/saleManage/components/myCard.vue'
 	export default {
 		components: {
-			myCard
+			// myCard
 		},
 		props: {
 			itemList: {

+ 42 - 37
pages/salesServiceManagement/demandList/components/invoice.scss

@@ -17,46 +17,51 @@
 					transform: scale(1.2);
 				}
 			}
-
-			.listBox-con {
+		}
+		
+		.listBox-con {
+			width: 100%;
+			// display: flex;
+			// flex-wrap: wrap;
+			// justify-content: space-between;
+			align-items: center;
+			padding: 0 18rpx 0 0;
+		
+			.listBox-top {
 				width: 100%;
-				// display: flex;
-				// flex-wrap: wrap;
-				// justify-content: space-between;
-				align-items: center;
-				padding: 0 18rpx 0 0;
-
-				.listBox-top {
-					width: 100%;
-					display: flex;
-					justify-content: space-between;
-					padding-bottom: 10rpx;
-
-					.listBox-name,
-					.listBox-code {
-						display: inline-block;
-						font-size: $uni-font-size-sm;
-						font-weight: bold;
-					}
+				display: flex;
+				justify-content: space-between;
+				padding-bottom: 10rpx;
+		
+				.listBox-name,
+				.listBox-code {
+					display: inline-block;
+					font-size: $uni-font-size-sm;
+					font-weight: bold;
 				}
-
-				.listBox-bottom {
+			}
+		
+			.listBox-bottom {
+				width: 100%;
+				display: flex;
+				justify-content: space-between;
+				font-size: $uni-font-size-sm;
+				flex-wrap: wrap;
+		
+				>view {
 					width: 100%;
-					display: flex;
-					justify-content: space-between;
-					font-size: $uni-font-size-sm;
-					flex-wrap: wrap;
-
-					>view {
-						width: 100%;
-						overflow: hidden;
-						white-space: nowrap;
-						text-overflow: ellipsis;
-					}
-
-					.half {
-						width: 50%;
-					}
+					overflow: hidden;
+					white-space: nowrap;
+					text-overflow: ellipsis;
+				}
+		
+				.half {
+					width: 50%;
+				}
+				
+				.label-s{
+					width: 50%;
+					display: inline-block !important;
 				}
 			}
 		}

+ 19 - 5
pages/salesServiceManagement/demandList/index.vue

@@ -233,8 +233,6 @@
 					pageNum: this.page,
 					size: this.size,
 					type: 1,
-					name: this.searchVal
-
 				}
 				getTableList(data).then(res => {
 					if (this.page === 1) {
@@ -265,7 +263,6 @@
 					confirmText: '撤回',
 					confirmColor: '#FF4D4F',
 				});
-				console.log(res, 'res ----')
 				if (res[1].confirm) {
 					const data = await revokeSalesDemand({
 						id: row.id
@@ -277,7 +274,7 @@
 					})
 					this.doSearch();
 				} else if (res.cancel) {
-					console.log('用户取消删除');
+					console.log('用户取消');
 				}
 
 			},
@@ -292,8 +289,25 @@
 				}
 				this.getList();
 			},
-			del(item) {
+			async del(item) {
 				console.log(item, 'item ---')
+				const res = await uni.showModal({
+					title: '确认删除',
+					content: '确定要删除该条数据吗?',
+					confirmText: '删除',
+					confirmColor: '#FF4D4F',
+				});
+				if (res[1].confirm) {
+					const data = await deleteInformation([row.id])
+					if (!data) return
+					this.$refs.uToast.show({
+						type: "success",
+						message: "操作成功",
+					})
+					this.doSearch();
+				} else if (res.cancel) {
+					console.log('用户取消');
+				}
 				// deleteInformation([item.id]).then(res => {
 				// 	this.isEnd = false
 				// 	this.page = 1

+ 245 - 0
pages/salesServiceManagement/toDoList/components/editPlan.vue

@@ -0,0 +1,245 @@
+<template>
+	<view class="">
+		<uni-nav-bar background-color="#157A2C" color="#fff" fixed="true" statusBar="true" left-icon="back"
+			:title="title" @clickLeft="back">
+		</uni-nav-bar>
+		<u-subsection :list="list" :current="current" @change="sectionChange"></u-subsection>
+		<u-cell-group v-if="current == 0">
+			<u-cell title="需求编码" arrow-direction="down">
+				<view slot="value" style="display: flex;align-items: center;width: 100%;">
+					<u--input readonly style="flex:1" border="surround" v-model="form.code">
+					</u--input>
+				</view>
+			</u-cell>
+			<u-cell title="名称" arrow-direction="down">
+				<view slot="value" style="display: flex;align-items: center;width: 100%;">
+					<u--input placeholder="请输入" :readonly="!isDisable" style="flex:1" border="surround"
+						v-model="form.name">
+					</u--input>
+				</view>
+			</u-cell>
+			<u-cell title="自动派单" arrow-direction="down">
+				<uni-data-picker :readonly="!isDisable" v-model="form.isSyncBill" slot="value" placeholder="请选择"
+					:localdata="isSyncBillist" @change="dispatchOnchange">
+				</uni-data-picker>
+			</u-cell>
+			<u-cell title="预计售后时长" arrow-direction="down">
+				<view slot="value" style="display: flex;align-items: center;width: 100%;">
+					<u--input :readonly="!isDisable" style="flex:1" border="surround" v-model="form.duration">
+						<template #suffix>
+							<uni-data-picker class="time_select" :readonly="!isDisable" v-model="form.durationUnit"
+								slot="value" placeholder="请选择" :localdata="durationList" @change="durationOnchange">
+							</uni-data-picker>
+						</template>
+					</u--input>
+				</view>
+			</u-cell>
+			<u-cell title="部门" arrow-direction="down">
+				<view slot="value" style="display: flex;align-items: center;width: 100%;">
+					<u--input :disabled="!isDisable" style="flex:1" placeholder="请选择" border="surround"
+						@click.native="selectDepartment" v-model="form.executeGroupName">
+					</u--input>
+				</view>
+			</u-cell>
+			<u-cell title="执行人" arrow-direction="down">
+				<view slot="value" style="display: flex;align-items: center;width: 100%;">
+					<zxz-uni-data-select class="executor_user" :localdata="userList" v-model="form.executeUserId" @change="handleUserChange"
+						:multiple="Usertype==2"></zxz-uni-data-select>
+				</view>
+			</u-cell>
+			<u-cell title="紧急程度" arrow-direction="down">
+					<uni-data-picker :readonly="!isDisable" v-model="form.urgent" slot="value" placeholder="请选择"
+						:localdata="urgentList" @change="urgentOnchange">
+					</uni-data-picker>
+			</u-cell>
+			<u-cell title="备注" arrow-direction="down">
+				<view slot="value" style="display: flex;align-items: center;width: 100%;">
+					<u--textarea> :readonly="!isDisable" style="flex:1" border="surround" v-model="form.remark">
+					</u--textarea>
+				</view>
+			</u-cell>
+		</u-cell-group>
+		<SchemeList v-if="current == 1" />
+		<view class="footerButton" v-if="isDisable">
+			<u-button type="default" text="返回" @click="back"></u-button>
+			<u-button type="primary" @click="save" text="保存"></u-button>
+		</view>
+		<ba-tree-picker ref="treePicker" :multiple="false" @select-change="confirm" title="选择部门" :localdata="listData"
+			valueKey="id" textKey="name" childrenKey="children" />
+		<u-toast ref="uToast"></u-toast>
+	</view>
+</template>
+ 
+<script>
+	import SchemeList from './schemeList.vue'
+	import {
+		getByCode
+	} from '@/api/pda/common.js'
+	import {
+		listOrganizations,
+		getUserPage
+	} from '@/api/myTicket/index.js'
+	export default {
+		components: {
+			SchemeList
+		},
+		computed: {
+			isDisable() {
+				let flag = this.type != 'view'
+				return flag;
+			}
+		},
+		data() {
+			return {
+				current: 0,
+				title: '修改计划',
+				type: 'edit',
+				form: {
+					name: '',
+					remark: '',
+					duration: '',
+					durationUnit: '',
+					executeGroupId: '',
+					executeGroupName: '',
+					executeUserName: '',
+					executeUserId: ''
+				},
+				Usertype: '',
+				list: ['基本信息', '方案', '联系人'],
+				isSyncBillist: [{
+						value: '1',
+						text: '是'
+					},
+					{
+						value: '1',
+						text: '否'
+					}
+				],
+				durationList: [{
+						value: '1',
+						text: '分钟'
+					},
+					{
+						value: '2',
+						text: '小时'
+					},
+					{
+						value: '3',
+						text: '天'
+					},
+				],
+				urgentList: [],
+				listData: [], // 部门数据
+				userList: [], // 执行人列表
+			}
+		},
+		onLoad(params) {
+			console.log(params, 'params')
+			this.type = params.type;
+			this.title = params.type == 'view' ? '计划详情' : '修改计划';
+			this.getDetails(params.id);
+		},
+		onUnload() {},
+		created() {},
+		methods: {
+			async getDetails(id) {
+				this.getByData();
+				this.getDept();
+			},
+			async getByData() {
+				const codeValue = await getByCode('urgent_type');
+				console.log(codeValue, 'codeValue');
+				let list = codeValue.map(item => {
+					const key = Object.keys(item)[0]
+					return {
+						value: key,
+						text: item[key]
+					}
+				})
+				this.urgentList = list;
+			},
+			getDept() {
+				listOrganizations(1).then(data => {
+					console.log(data, 'data --');
+					this.listData = data;
+				})
+			},
+			confirm(data, name) {
+				this.form.executeGroupName = name
+				this.form.executeGroupId = data[0]
+				this.form.executeUserName = ''
+				this.form.executeUserId = ''
+				this.getUser(data[0])
+			},
+			getUser(deptCode) {
+				getUserPage({
+					pageNum: 1,
+					size: -1,
+					groupId: deptCode
+				}).then(data => {
+					this.userList = data.list.map(item => {
+						item.text = item.name
+						item.value = item.id
+						return item
+					})
+				})
+			},
+			sectionChange(index) {
+				this.current = index;
+			},
+			// 选择部门
+			selectDepartment() {
+				console.log('选择部门');
+				this.$refs.treePicker._show();
+			},
+			// 选择人
+			handleUserChange(obj) {
+				this.form.executeUserName = obj.name;
+				console.log(obj, 'obj')
+			},
+			dispatchOnchange() {
+
+			},
+			durationOnchange(){
+				
+			}
+		}
+	}
+</script>
+
+<style lang="scss" scoped>
+	/deep/.u-subsection__item__text {
+		font-size: 28rpx !important;
+	}
+
+	/deep/.u-cell__body__content {
+		flex: none;
+		margin-right: 16rpx;
+	}
+
+	/deep/ .time_select .uni-data-tree-input {
+		width: 200rpx;
+	}
+	
+	/deep/ .executor_user{
+		background: #fff;
+	}
+
+	.footerButton {
+		width: 100%;
+		height: 84rpx;
+		display: flex;
+		position: fixed;
+		bottom: 0;
+		z-index: 10;
+
+		/deep/.u-button {
+			height: 100%;
+		}
+
+		>view {
+			flex: 1;
+
+		}
+	}
+</style>

+ 134 - 0
pages/salesServiceManagement/toDoList/components/schemeAdd.vue

@@ -0,0 +1,134 @@
+<template>
+	<view class="mainBox">
+		<uni-nav-bar background-color="#157A2C" color="#fff" fixed="true" statusBar="true" left-icon="back" title="方案信息"
+			@clickLeft="back">
+		</uni-nav-bar>
+		<u-cell-group>
+			<u-cell title="姓名" arrow-direction="down">
+				<uni-data-picker v-model="form.typeId" slot="value" placeholder="请选择" :localdata="typeIdList"
+					@change="typeOnchange">
+				</uni-data-picker>
+			</u-cell>
+			<u-cell title="编码" arrow-direction="down">
+				<u--input slot="value" placeholder="请输入" border="surround" v-model="form.code"></u--input>
+			</u-cell>
+			<u-cell title="名称" arrow-direction="down">
+				<u--input @click.native="selectProduct" slot="value" placeholder="请输入" border="surround"
+					v-model="form.name">
+
+				</u--input>
+				<!-- <u--input slot="value" placeholder="请输入" border="surround" v-model="form.name"></u--input> -->
+			</u-cell>
+			<u-cell title="型号" arrow-direction="down">
+				<u--input slot="value" placeholder="请输入" border="surround" v-model="form.categoryModel"></u--input>
+			</u-cell>
+			<u-cell title="规格" arrow-direction="down">
+				<u--input slot="value" placeholder="请输入" border="surround" v-model="form.specification"></u--input>
+			</u-cell>
+			<u-cell title="仓库" arrow-direction="down">
+				<u--input slot="value" placeholder="请输入" border="surround" v-model="form.warehouseId"></u--input>
+			</u-cell>
+			<u-cell title="库存" arrow-direction="down">
+				<u--input slot="value" placeholder="请输入" border="surround" v-model="form.warehouseNum"></u--input>
+			</u-cell>
+			<u-cell title="数量" arrow-direction="down">
+				<u--input slot="value" placeholder="请输入" border="surround" v-model="form.totalCount"></u--input>
+			</u-cell>
+			<u-cell title="单位" arrow-direction="down">
+				<u--input slot="value" placeholder="请输入" border="surround" v-model="form.measureUnit"></u--input>
+			</u-cell>
+			<u-cell title="单价" arrow-direction="down">
+				<u--input slot="value" placeholder="请输入" border="surround" v-model="form.singlePrice"></u--input>
+			</u-cell>
+			<u-cell title="合计" arrow-direction="down">
+				<u--input slot="value" placeholder="请输入" border="surround" v-model="form.settlementPrice"></u--input>
+			</u-cell>
+			<u-cell title="详细内容" arrow-direction="down">
+				<u--input slot="value" placeholder="请输入" border="surround" v-model="form.content"></u--input>
+			</u-cell>
+			<view class="footerButton">
+				<u-button type="default" text="返回" @click="back"></u-button>
+				<u-button type="primary" @click="save" text="保存"></u-button>
+			</view>
+		</u-cell-group>
+	</view>
+</template>
+
+<script>
+	export default {
+		data() {
+			return {
+				form: {
+					typeId: '2',
+					code: '',
+					name: '',
+					categoryModel: '', // 型号
+					specification: '', // 规格
+					content: '', // 详细内容
+					warehouseId: '', // 仓库
+					warehouseNum: '', // 库存
+					totalCount: '', // 数量
+					measureUnit: '', // 单位
+					singlePrice: '', // 单价
+					settlementPrice: '', // 合计
+				},
+				typeIdList: [{
+						text: '工时',
+						value: '1'
+					},
+					{
+						text: '零配件',
+						value: '2'
+					},
+					{
+						text: '差旅费',
+						value: '3'
+					}
+				],
+				obtain: '主数据'
+			}
+		},
+		onLoad(params) {
+			this.obtain = params.obtain || '主数据'
+			console.log(params, 'params');
+		},
+		methods: {
+			typeOnchange(e) {
+				console.log(e, 'eee');
+			},
+			selectProduct() {
+				uni.navigateTo({
+					url: `/pages/salesServiceManagement/toDoList/components/selectProduct?obtain=${this.obtain}`
+				})
+			}
+		}
+	}
+</script>
+
+<style scoped lang="scss">
+	/deep/.u-cell__body__content {
+		flex: none;
+		margin-right: 16rpx;
+	}
+
+	.mainBox {
+		padding-bottom: 84rpx;
+	}
+
+	.footerButton {
+		width: 100%;
+		height: 84rpx;
+		display: flex;
+		position: fixed;
+		bottom: 0;
+
+		/deep/.u-button {
+			height: 100%;
+		}
+
+		>view {
+			flex: 1;
+
+		}
+	}
+</style>

+ 64 - 0
pages/salesServiceManagement/toDoList/components/schemeList.vue

@@ -0,0 +1,64 @@
+<template>
+	<view class="scheme">
+		<u-list class="listContent">
+			<view class="listBox-con">
+				<view class="listBox-bottom">
+					<view>项目:{{' '}}</view>
+					<view>编码:{{' '}}</view>
+					<view>名称:{{' '}}</view>
+					<view class="label-s">型号:{{' '}}</view>
+					<view class="label-s">规格:{{' '}}</view>
+					<view class="label-s">仓库:{{' '}}</view>
+					<view class="label-s">库存:{{' '}}</view>
+					<view class="label-s">数量:{{' '}}</view>
+					<view class="label-s">单位:{{' '}}</view>
+					<view class="label-s">单价(元):{{' '}}</view>
+					<view class="label-s">合计(元):{{' '}}</view>
+					<view>详细内容:{{' '}}</view>
+				</view>
+			</view>
+		</u-list> 
+		<view class="add" @click="add"> 
+			<u-icon name="plus" color="#fff"></u-icon>
+		</view>
+	</view>
+</template>
+
+<script>
+	export default {
+		components:{},
+		data(){
+			return {}
+		},
+		computed:{},
+		onShow() {
+			
+		},
+		methods:{
+			add(){
+				uni.navigateTo({
+					url: `/pages/salesServiceManagement/toDoList/components/schemeAdd?obtain=仓库`
+				})
+			}
+		}
+	}
+</script>
+
+<style lang="scss" scoped>
+	@import url('@/pages/salesServiceManagement/demandList/components/invoice.scss');
+	.scheme{
+		padding: 10rpx 20rpx;
+	}
+	.add {
+		width: 96rpx;
+		height: 96rpx;
+		border-radius: 48rpx;
+		background: #3c9cff;
+		position: fixed;
+		bottom: 100rpx;
+		right: 24rpx;
+		display: flex;
+		align-items: center;
+		justify-content: center;
+	}
+</style>

+ 212 - 0
pages/salesServiceManagement/toDoList/components/selectProduct.vue

@@ -0,0 +1,212 @@
+<template>
+	<view class="mainBox">
+		<uni-nav-bar fixed="true" statusBar="true" left-icon="back" title="选择产品" @clickLeft="backAdd">
+			<!--右菜单-->
+			<template slot="right">
+				<u-button type="success" size="small" class="u-reset-button" @click="classification"
+					text="选择分类"></u-button>
+			</template>
+		</uni-nav-bar>
+		<view class="wrapper">
+			<u-list @scrolltolower="scrolltolower" class="listContent">
+				<checkbox-group v-for="(item, index) in tableList" :key="index"
+					@change="e => selectVal(e, item, index)">
+					<label>
+						<view class="listBox">
+							<view class="listBox-sel">
+								<checkbox :value="item.id" color="#fff" :disabled="item.disabled"
+									:checked="item.checked" />
+							</view>
+							<view class="listBox-con">
+								<view class="listBox-bottom">
+									<view> <text>编码:</text> <text class="value">{{ item.code }}</text> </view>
+									<view> <text>名称:</text> <text class="value">{{ item.name }}</text> </view>
+									<view> <text>型号:</text> <text class="value">{{ item.modelType }}</text> </view>
+									<view> <text>规格:</text> <text class="value">{{ item.specification }}</text> </view>
+									<view> <text>计量单位:</text> <text class="value">{{ item.measuringUnit }}</text>
+									</view>
+									<view> <text>重量单位:</text> <text class="value">{{ item.weightUnit }}</text> </view>
+									<view> <text>分类:</text> <text class="value">{{ item.categoryLevelPath }}</text>
+									</view>
+								</view>
+							</view>
+						</view>
+					</label>
+				</checkbox-group>
+				<u-empty class="noDate" style="margin-top: 20vh" v-if="!tableList.length"></u-empty>
+			</u-list>
+		</view>
+		<ba-tree-picker ref="treePicker" key="verify" :multiple="false" @select-change="confirm" title="选择分类"
+			:selectedData="selectedData" :localdata="classificationList" valueKey="id" textKey="name"
+			childrenKey="children" />
+		<view class="footer">
+			<u-button type="success" size="small" class="u-reset-button" @click="jumpAdd">
+				<view class="selBtn">选择( {{ checkListLen }} )</view>
+			</u-button>
+		</view>
+	</view>
+</template>
+
+<script>
+	import {
+		treeByPid
+	} from '@/api/pda/workOrder.js'
+	import {
+		getProductList,
+		getBatchDetails,
+		getInventoryDetails,
+		getMaterielDetails,
+	} from '@/api/repair'
+	export default {
+		data() {
+			return {
+				tableList: [],
+				obtain: '主数据',
+				dimension: '1', // 列表维度
+				categoryLevelId: 6, // 分类id(默认6 查询备品备件)
+				selectedData: ['6'],
+				classificationList: [],
+				pageNum: 1,
+				isEnd: false,
+				detailsData:{}
+			}
+		},
+		computed:{
+			checkListLen() {
+				return this.detailsData.id ? 1 : 0
+			},
+		},
+		onLoad(params) {
+			console.log(params, '参数')
+			this.obtain = params.obtain;
+			if (params.obtain == '仓库') {
+				this.changeDimension(this.dimension);
+			} else {
+
+			}
+		},
+		onShow(){
+			this.getTreeList()
+		},
+		components: {},
+		methods: {
+			//返回添加页
+			backAdd() {
+				uni.navigateBack()
+			},
+			// 仓库数据
+			changeDimension(dimension) {
+				uni.showLoading({
+					title: '加载中'
+				})
+				return new Promise(async (resolve, reject) => {
+					try {
+						let params = {
+							// assetName: this.assetName,
+							// dimension: this.dimension,
+							pageNum: this.pageNum,
+							size: 15,
+							categoryLevelId: this.categoryLevelId
+						}
+						const api = dimension == 1 ? getProductList : dimension == 2 ?
+							getBatchDetails : dimension == 3 ? getInventoryDetails : getMaterielDetails;
+						let res = await api(params);
+						this.tableList = res.list.map((el) => {
+							el.modelType = el.categoryModel;
+							el.name = el.categoryName;
+							el.code = el.categoryCode;
+							return el;
+						});
+
+
+						uni.hideLoading();
+						resolve();
+						console.log(res, 'res')
+					} catch (error) {
+						uni.hideLoading()
+						reject()
+					}
+				})
+			},
+			classification() {
+				this.$refs.treePicker._show();
+				console.log('选择分类')
+			},
+			scrolltolower() {
+				// if (this.isEnd) {
+				// 	return
+				// }
+				// this.getList();
+			},
+			// 选择
+			selectVal(e, val, index) {
+				this.$set(this.tableList[index], 'checked', !this.tableList[index].checked);
+				this.tableList.forEach((item, i) => {
+					if (item.id != val.id) {
+						this.$set(this.tableList[i], 'checked', false)
+					}
+				})
+				console.log(this.tableList, 'list - - ')
+			},
+			getTreeList() {
+				treeByPid({
+					ids: [6]
+				}).then(res => {
+					this.classificationList = res;
+					this.confirm(res[0].id, res[0].name, res[0].rootCategoryLevelId)
+				})
+			},
+			confirm(id, name, rootCategoryLevelId) {
+				// this.rootCategoryLevelId = rootCategoryLevelId
+				this.categoryLevelId = id;
+				this.tableList = [];
+				this.changeDimension(this.dimension);
+			},
+			jumpAdd(){
+				
+			}
+		}
+	}
+</script>
+
+<style scoped lang="scss">
+	@import url('@/pages/salesServiceManagement/demandList/components/invoice.scss');
+
+	.mainBox {
+		height: 100vh;
+		display: flex;
+		flex-direction: column;
+		
+		.wrapper {
+			// flex: 1;
+			height: calc(100vh - 250rpx);
+			overflow: hidden;
+		}
+		
+		//底部按钮
+		.footer {
+			height: 45px;
+			position: relative;
+			display: flex;
+			justify-content: space-between;
+			align-items: center;
+			bottom: 0;
+			width: 100%;
+			height: 50px;
+			border-top: 1px solid #eeecec;
+			background-color: #ffffff;
+			z-index: 999;
+
+			.bottom {
+				margin-left: 10rpx;
+			}
+
+			.u-reset-button {
+				position: absolute;
+				right: 10rpx;
+				top: 20rpx;
+				width: 150rpx;
+			}
+		}
+	}
+</style>

+ 261 - 0
pages/salesServiceManagement/toDoList/index.vue

@@ -0,0 +1,261 @@
+<template>
+	<view class="mainBox">
+		<uni-nav-bar background-color="#157A2C" color="#fff" fixed="true" statusBar="true" left-icon="back" title="售后计划"
+			@clickLeft="back">
+		</uni-nav-bar>
+		<view class="top-wrapper">
+			<uni-section>
+				<uni-easyinput prefixIcon="search" style="width: 460rpx" v-model="searchVal" placeholder="名称">
+				</uni-easyinput>
+			</uni-section>
+			<button class="search_btn" @click="doSearch">搜索</button>
+			<image class="menu_icon" src="~@/static/pda/menu.svg"></image>
+		</view>
+		<view class="wrapper">
+			<u-list @scrolltolower="scrolltolower" class="listContent">
+				<view v-for="(item, index) in tableList" :key="index" style="position: relative;">
+					<myCard @del="del(item)" @edit="edit('edit',item.id)" @details="edit('view',item.id)" :item="item"
+						:index="index+1" :columns="columns" :btnList="btnList">
+					</myCard>
+				</view>
+			</u-list>
+		</view>
+
+		<u-toast ref="uToast"></u-toast>
+
+	</view>
+</template>
+
+<script>
+	import {
+		getSalesPlan,
+	} from '@/api/salesServiceManagement/toDoList/index.js'
+	import myCard from '@/pages/saleManage/components/myCard.vue'
+	export default {
+		components: {
+			myCard,
+		},
+
+		data() {
+			return {
+				searchVal: '',
+				isEnd: false,
+				page: 1,
+				size: 10,
+				tableList: [],
+				columns: [
+					[{
+						label: '计划单号:',
+						prop: 'code',
+						type: 'title',
+						className: 'perce100',
+					}],
+					[{
+						label: '计划名称:',
+						prop: 'name'
+					}, ],
+					[{
+						label: '设备名称:',
+						prop: 'categoryName',
+						formatter: (row) => {
+							if (!row.deviceDetails) return '';
+							let str = '';
+							row.deviceDetails.map((el, idx) => {
+								if (idx + 1 == row.deviceDetails.length) {
+									str += el.categoryName;
+								} else {
+									str = str + '' + el.categoryName + ',';
+								}
+							});
+							return str;
+						}
+					}],
+					[{
+						label: '客户名称:',
+						prop: 'contactName'
+					}, {
+						label: '紧急程度:',
+						prop: 'urgent',
+						formatter: (item) => {
+							return {
+								1: '普通',
+								2: '紧急',
+								3: '重要'
+							} [item.urgent];
+						}
+					}],
+					[{
+						label: '创建人:',
+						prop: 'createUserName'
+					}, {
+						label: '创建时间:',
+						prop: 'createTime',
+					}],
+					[{
+						label: '操作:',
+						prop: 'action',
+						type: 'action',
+						className: 'perce100',
+					}],
+				],
+				btnList: [{
+						name: '详情',
+						apiName: 'details',
+						btnType: 'primary',
+						type: '2',
+						pageUrl: '',
+
+					}, {
+						name: '修改',
+						apiName: 'edit',
+						btnType: 'primary',
+						type: '2',
+						pageUrl: '',
+						judge: [{
+							authorities: '',
+						}, {
+							key: 'planStatus',
+							value: [0, 4, 5],
+
+						}],
+					},
+					{
+						name: '删除',
+						apiName: 'del',
+						btnType: 'error ',
+						type: '2',
+						pageUrl: '',
+						judge: [{
+							authorities: '',
+						}, {
+							key: 'planStatus',
+							value: [0, 4, 5],
+						}],
+					}, {
+						name: '派单',
+						apiName: 'handleAudit',
+						btnType: 'primary',
+						type: '2',
+						pageUrl: '',
+						judge: [{
+							authorities: '',
+						}, {
+							key: 'planStatus',
+							value: [0, 4, 5],
+						}],
+					},
+					{
+						name: '撤回',
+						apiName: 'handleAudit',
+						btnType: 'primary',
+						type: '2',
+						pageUrl: '',
+						judge: [{
+							authorities: '',
+						}, {
+							key: 'planStatus',
+							value: [1],
+						}],
+					},
+				],
+			}
+		},
+		computed: {
+
+		},
+
+		onShow() {
+			this.isEnd = false
+			this.page = 1
+			this.getList()
+		},
+
+		methods: {
+			doSearch() {
+				this.isEnd = false
+				this.page = 1
+				this.getList()
+			},
+			//获取列表信息
+			getList() {
+				if (this.isEnd) {
+					return
+				}
+				uni.showLoading({
+					title: '加载中'
+				})
+				let data = {
+					pageNum: this.page,
+					size: this.size,
+
+				}
+				getSalesPlan(data).then(res => {
+					if (this.page === 1) {
+						this.tableList = res.list
+					} else {
+						this.tableList.push(...res.list)
+					}
+					this.page += 1
+					this.isEnd = this.tableList.length >= res.count;
+					console.log(this.tableList, 'tableList')
+					uni.hideLoading();
+				}).catch((e) => {
+					uni.hideLoading()
+				})
+			},
+			scrolltolower() {
+				if (this.isEnd) {
+					return
+				}
+				this.getList();
+			},
+			del(item) {
+
+			},
+			edit(type,id) {
+				uni.navigateTo({
+					url: `/pages/salesServiceManagement/toDoList/components/editPlan?type=${type}&id=${id}`
+				})
+			}
+		}
+	}
+</script>
+
+<style lang="scss" scoped>
+	.top-wrapper {
+		background-color: #fff;
+		display: flex;
+		width: 750rpx;
+		height: 88rpx;
+		padding: 16rpx 32rpx;
+		align-items: center;
+		gap: 16rpx;
+
+		/deep/.uni-section {
+			margin-top: 0px;
+		}
+
+		/deep/.uni-section-header {
+			padding: 0px;
+
+		}
+
+		.search_btn {
+			width: 120rpx;
+			height: 70rpx;
+			line-height: 70rpx;
+			padding: 0 24rpx;
+			background: $theme-color;
+			font-size: 32rpx;
+			color: #fff;
+			margin: 0;
+			margin-left: 26rpx;
+		}
+
+		.menu_icon {
+			width: 44rpx;
+			height: 44rpx;
+			margin-left: 14rpx;
+		}
+	}
+</style>