ysy 2 년 전
부모
커밋
4d26ddd1db
1개의 변경된 파일71개의 추가작업 그리고 5개의 파일을 삭제
  1. 71 5
      pages/pda/jobBooking/components/jobBom.vue

+ 71 - 5
pages/pda/jobBooking/components/jobBom.vue

@@ -75,21 +75,35 @@
 
 				</view>
 
-				<view class="item">
+				<view class="item" @click="handleType">
 					<view class="lable rx-cc">舟皿类型</view>
-					<view class="content"></view>
+					<view class="content content_num">
+						<input class="uni-input" v-model="obj.typeName"></input>
+					</view>
 				</view>
 
 
 
 				<view class="item">
 					<view class="lable rx-cc">舟皿名称</view>
-					<view class="content"></view>
+					<view class="content ">
+						<zxz-uni-data-select :localdata="boatList" v-model="obj.name" dataValue='id' format='{name}-{code}'
+							:clear='false' @change='inputChange'></zxz-uni-data-select>
+					</view>
 				</view>
 
 				<view class="item">
 					<view class="lable rx-cc">舟皿型号</view>
-					<view class="content"></view>
+					<view class="content">
+						{{obj.modelType}}
+					</view>
+				</view>
+				
+				<view class="item">
+					<view class="lable rx-cc">舟皿数量</view>
+				<view class="content content_num">
+					<input class="uni-input" v-model="obj.num" type='digit'></input>
+				</view>
 				</view>
 
 
@@ -100,11 +114,19 @@
 			</view>
 		</view>
 
+		<ba-tree-picker ref="treePicker" key="verify" :multiple="false" @select-change="confirm" title="选择分类"
+			:localdata="classificationList" valueKey="id" textKey="name" childrenKey="children" />
 
 	</view>
 </template>
 
 <script>
+	import baTreePicker from '@/components/ba-tree-picker/ba-tree-picker.vue'
+	import {
+		treeByPid,
+		pageeLedgerMain,
+		assetPage
+	} from '@/api/pda/workOrder.js'
 	export default {
 		props: {
 			item: {
@@ -119,11 +141,55 @@
 		},
 		data() {
 			return {
-
+				classificationList: [],
+				boatList: [],
+				obj: {
+					typeName: '',
+				    modelType: ''
+				}
 			}
 		},
+		created() {
+			this.getTreeList()
+		},
 		methods: {
 
+			getTreeList() {
+				let params = {
+					ids: [8]
+				}
+				treeByPid(params).then(res => {
+					this.classificationList = res
+					this.confirm([res[0].id], res[0].name, res[0].rootCategoryLevelId)
+				})
+			},
+
+			confirm(id, name, rootCategoryLevelId) {
+				this.obj.typeName = name
+				// this.obj.modelType = ''
+		
+
+				let param = {
+					categoryLevelId: id,
+					pageNum: 1,
+					size: -1,
+				}
+				assetPage(param).then(res => {
+					this.boatList = res.list
+				})
+			},
+			
+			inputChange(e) {
+					this.obj.modelType = 55
+		
+		
+			
+	
+			},
+
+			handleType() {
+				this.$refs.treePicker._show()
+			}
 		}
 	}
 </script>