1
0
فهرست منبع

手动出库左侧物料和料箱逻辑修改,优化代码。

jiaxiaoqiang 8 ماه پیش
والد
کامیت
5127f91f3d

+ 76 - 0
entry/src/main/ets/common/component/SureToDoDialog.ets

@@ -0,0 +1,76 @@
+// 确认调仓弹窗
+@CustomDialog
+export struct SureToDoDialog {
+  controller?: CustomDialogController
+  cancel: () => void = () => {
+  }
+  confirm: () => void = () => {
+  }
+  title:string = ""
+  info:string = ""
+
+
+  build() {
+    Column() {
+      Row() {
+        Text(this.title)
+          .fontSize($r('app.float.title_font_size'))
+          .fontWeight(FontWeight.Medium)
+          .fontColor($r('app.color.general_font_color'))
+          .opacity($r('app.float.general_font_opacity'))
+      }
+      .height('30%')
+      .alignItems(VerticalAlign.Center)
+
+      Row() {
+        Text(this.info)
+          .fontSize($r('app.float.robot_set_font_size'))
+          .fontWeight(FontWeight.Medium)
+          .fontColor($r('app.color.general_font_color'))
+          .opacity($r('app.float.general_font_opacity'))
+      }
+      .width('100%')
+      .height('27%')
+      .justifyContent(FlexAlign.Center)
+
+      Row() {
+        Button('取消')
+          .fontSize($r('app.float.robot_set_font_size'))
+          .fontWeight(FontWeight.Medium)
+          .fontColor($r('app.color.robot_set_card_blue'))
+          .width('32%')
+          .height('50%')
+          .borderRadius($r('app.float.robot_set_radius'))
+          .backgroundColor($r('app.color.robot_set_coord_card_grey'))
+          .onClick(() => {
+            this.controller?.close()
+            this.cancel()
+          })
+        Row()
+          .width('2.5%')
+        Button('确认')
+          .fontSize($r('app.float.robot_set_font_size'))
+          .fontWeight(FontWeight.Medium)
+          .fontColor($r('app.color.general_font_white_color'))
+          .width('32%')
+          .height('50%')
+          .borderRadius($r('app.float.robot_set_radius'))
+          .backgroundColor($r('app.color.robot_set_card_blue'))
+          .onClick(() => {
+            if (this.controller != undefined) {
+              this.controller.close()
+              this.confirm()
+            }
+          })
+      }
+      .justifyContent(FlexAlign.Center)
+      .height('43%')
+      .width('100%')
+    }
+    .width('40%')
+    .height('50%')
+    .backgroundColor($r('app.color.page_general_background'))
+    .justifyContent(FlexAlign.SpaceEvenly)
+    .borderRadius($r('app.float.general_border_radius'))
+  }
+}

+ 178 - 162
entry/src/main/ets/common/util/request/StorageRequestInstance.ets

@@ -10,16 +10,17 @@ import { records } from '../../../view/Statistics';
 export interface StorageStatus {
   //批次号
   batchCode?: string;
+
   //已经占用箱数
-  useNum?:number
+  useNum?: number
   //空箱数
-  emptyBoxNum?:string
+  emptyBoxNum?: string
   //可用箱数
-  canUsedNum?:string
+  canUsedNum?: string
   //总容量箱数
-  allNum?:number
+  allNum?: number
   //仓储类型
-  type?:string
+  type?: string
   //批次号
 
   coordinate?: string
@@ -28,14 +29,14 @@ export interface StorageStatus {
   //
   creator?: string
   //仓库编码
-  houseNo?:string
+  houseNo?: string
   deptId?: string
-  houseType?:string
+  houseType?: string
   //主键
-  id?:string
+  id?: string
   locationNo?: string
   //	物料名称
-  materialName?:string
+  materialName?: string
   //物料编码
   materialNo?: string
   //出入库数量
@@ -46,55 +47,56 @@ export interface StorageStatus {
   //	序列号
   seqNo?: string
   // 状态;1-待处理;2-处理中;3-处理异常;4-已完成
-  state?:string
+  state?: string
   //	库存数量
-  stockNum?:string
+  stockNum?: string
   //出入库任务单号
   taskNo?: string
-  unit?:string
+  unit?: string
   updated?: string
   //任务名称
-  taskName?:string
+  taskName?: string
   updator?: string
   vehicleNo?: string
 }
-export interface  StorageStatusList {
+
+export interface StorageStatusList {
   //载具编号
-  vehicleCode?:string
+  vehicleCode?: string
   //产品规格
-  spec?:string
+  spec?: string
   //批次号
   batchCode?: string;
-  ///完成数量
-  completedNum?:number
 
+  ///完成数量
+  completedNum?: number
   //已经占用箱数
-  useNum?:number
+  useNum?: number
   //空箱数
-  emptyBoxNum?:string
+  emptyBoxNum?: string
   //可用箱数
-  canUsedNum?:string
+  canUsedNum?: string
   //总容量箱数
-  allNum?:number
+  allNum?: number
   //仓储类型
-  type?:string
+  type?: string
   //储位坐标
   coordinate?: string
   //储位位置
-  position?:string
+  position?: string
   //创建时间
   created?: string
   //
   creator?: string
   //仓库编码
-  houseNo?:string
+  houseNo?: string
   deptId?: string
-  houseType?:string
+  houseType?: string
   //主键
-  id?:string
+  id?: string
   locationNo?: string
   //	物料名称
-  materialName?:string
+  materialName?: string
   //物料编码
   materialNo?: string
   //出入库数量
@@ -104,147 +106,156 @@ export interface  StorageStatusList {
   //	序列号
   seqNo?: string
   // 状态;1-待处理;2-处理中;3-处理异常;4-已完成
-  state?:number
+  state?: number
   //	库存数量
-  stockNum?:string
+  stockNum?: string
   //出入库任务单号
   taskNo?: string
-  unit?:string
+  unit?: string
   updated?: string
   //任务名称
-  taskName?:string
+  taskName?: string
   updator?: string
-
   vehicleNo?: string
-  pageNo?:number
-  pageSize?:number
+  pageNo?: number
+  pageSize?: number
 }
 
 export interface taskclass {
-  created?:string
+  created?: string
   creator?: string
   deptId?: string
   id?: string
   //今日报告
-  bugNum?:number
+  bugNum?: number
   //今日完成
-  completeNum?:number
+  completeNum?: number
   //齐套数量
-  kittingNum?:number
+  kittingNum?: number
   //今日任务
-  planNum?:number
-  orgId?:string
+  planNum?: number
+  orgId?: string
   outType?: string
   progress?: string
   relOrderNo?: string
-  relOutOrderNo?:string
+  relOutOrderNo?: string
   relPlanNo?: string
   taskName?: string
-  state?:string
-  taskNo?:string
-  type?:string
-  updated?:string
-  materialName?:string
-  updator?:string
-  num?:number
+  state?: string
+  taskNo?: string
+  type?: string
+  updated?: string
+  materialName?: string
+  updator?: string
+  num?: number
 }
-export interface  StorageStatusList1 {
-  created?:string
+
+export interface StorageStatusList1 {
+  created?: string
   creator?: string
   deptId?: string
   id?: string
-  orgId?:string
+  orgId?: string
   outType?: string
   progress?: string
   relOrderNo?: string
-  relOutOrderNo?:string
+  relOutOrderNo?: string
   relPlanNo?: string
   taskName?: string
-  state?:string
-  taskNo?:string
-  type?:string
-  updated?:string
-  materialName?:string
-  updator?:string
-  num?:number
-  max?:number
-  min?:number
+  state?: string
+  taskNo?: string
+  type?: string
+  updated?: string
+  materialName?: string
+  updator?: string
+  num?: number
+  max?: number
+  min?: number
 }
+
 // 统计占用率请求
-const testGet1 = async () : Promise<StorageStatus> => {
-  let obj: StorageStatus = { } //尽量用{}来定义空对象,如果用null在get属性的时候可能会出错
-  let res:StorageStatus = await StorageRequest.get("/api/v1/position/lineStockState1")
+const testGet1 = async (): Promise<StorageStatus> => {
+  let obj: StorageStatus = {} //尽量用{}来定义空对象,如果用null在get属性的时候可能会出错
+  let res: StorageStatus = await StorageRequest.get("/api/v1/position/lineStockState1")
   obj = res as StorageStatus
-  console.info("testTag", ' -----------------'+JSON.stringify(obj));
-  console.debug('await StorageRequest.get 如果是Promise.reject 就不会执行await后面的代码', obj.batchCode, )
+  console.info("testTag", ' -----------------' + JSON.stringify(obj));
+  console.debug('await StorageRequest.get 如果是Promise.reject 就不会执行await后面的代码', obj.batchCode,)
   return Promise.resolve(obj)
 }
 //任务统计
-const task = async () : Promise<taskclass> => {
-  let obj: taskclass = { } //尽量用{}来定义空对象,如果用null在get属性的时候可能会出错
-  let res:taskclass = await StorageRequest.get("/api/v1/statistics/todayInfo")
+const task = async (): Promise<taskclass> => {
+  let obj: taskclass = {} //尽量用{}来定义空对象,如果用null在get属性的时候可能会出错
+  let res: taskclass = await StorageRequest.get("/api/v1/statistics/todayInfo")
   obj = res as taskclass
-  console.info("testTag", ' -----------------'+JSON.stringify(obj));
-  console.debug('await StorageRequest.get 如果是Promise.reject 就不会执行await后面的代码', obj )
+  console.info("testTag", ' -----------------' + JSON.stringify(obj));
+  console.debug('await StorageRequest.get 如果是Promise.reject 就不会执行await后面的代码', obj)
   return Promise.resolve(obj)
 }
-export interface  PlanClass{
-  productTypeNum?:number
-  unCompletePlan?:number
+
+export interface PlanClass {
+  productTypeNum?: number
+  unCompletePlan?: number
 
 }
-const Plan = async () : Promise<PlanClass> => {
-  let obj: PlanClass = { } //尽量用{}来定义空对象,如果用null在get属性的时候可能会出错
-  let res:PlanClass = await StorageRequest.get("/api/v1/plan/task/planTaskStatistics")
+
+const Plan = async (): Promise<PlanClass> => {
+  let obj: PlanClass = {} //尽量用{}来定义空对象,如果用null在get属性的时候可能会出错
+  let res: PlanClass = await StorageRequest.get("/api/v1/plan/task/planTaskStatistics")
   obj = res as PlanClass
-  console.info("testTag", ' -----------------'+JSON.stringify(obj));
-  console.debug('await StorageRequest.get 如果是Promise.reject 就不会执行await后面的代码', obj )
+  console.info("testTag", ' -----------------' + JSON.stringify(obj));
+  console.debug('await StorageRequest.get 如果是Promise.reject 就不会执行await后面的代码', obj)
   return Promise.resolve(obj)
 }
 
 
 // 入库取料箱数据
-export interface  WarehousingBufferHopperList {
-  houseNo?:string;
+export interface WarehousingBufferHopperList {
+  houseNo?: string;
+
   //料箱已存物料信息
 
   list?: WorkBinInfo[];
+
   ///料箱编号-*+9
-  vehicleNo?:string
+  vehicleNo?: string
 }
-const Warehousing = async() : Promise<WarehousingBufferHopperList[]> => {
-  let obj:WarehousingBufferHopperList[] = []
-  let res:WarehousingBufferHopperList = await StorageRequest.post("/api/v1/stock/queryVehicleList", {
-   housetype:1
-  }as RequestParamModel)
+
+const Warehousing = async (): Promise<WarehousingBufferHopperList[]> => {
+  let obj: WarehousingBufferHopperList[] = []
+  let res: WarehousingBufferHopperList = await StorageRequest.post("/api/v1/stock/queryVehicleList", {
+    housetype: 1
+  } as RequestParamModel)
   console.log('testTag', '********' + JSON.stringify(res))
   obj = JSON.parse(JSON.stringify(res))
   return obj
 }
+
 // 入库存料箱
-export interface  BufferHopperclass {
+export interface BufferHopperclass {
   // 料箱存入物料信息
   detailsList?: OutboundData[];
+
   // 料箱编号
-  vehicleNo?:string
+  vehicleNo?: string
 }
-const BufferHopper= async() : Promise<BufferHopperclass[]> => {
-  let obj:BufferHopperclass[] = []
-  let res:BufferHopperclass = await StorageRequest.post("/api/v1/wmsOrder/inBox", {
+
+const BufferHopper = async (): Promise<BufferHopperclass[]> => {
+  let obj: BufferHopperclass[] = []
+  let res: BufferHopperclass = await StorageRequest.post("/api/v1/wmsOrder/inBox", {
     detailsList: [],
-    taskId:''
-  }as RequestParamModel)
+    taskId: ''
+  } as RequestParamModel)
   console.log('testTag', '发送成功' + JSON.stringify(res))
   obj = JSON.parse(JSON.stringify(res))
   return obj
 }
 ///当前库存请求
-const testPost = async(search?: string) : Promise<StorageStatusList[]> => {
+const testPost = async (search?: string): Promise<StorageStatusList[]> => {
   let obj: StorageStatusList[] = []
-   let res:StorageStatusList = await StorageRequest.post("/api/v1/stock/list", {
-     houseType:1,
-     materialCode: search ?? "",
-     }as RequestParamModel)
+  let res: StorageStatusList = await StorageRequest.post("/api/v1/stock/list", {
+    houseType: 1,
+    materialCode: search ?? "",
+  } as RequestParamModel)
   console.log('testTag', '&&&&&&&&&&&&' + JSON.stringify(res))
   obj = JSON.parse(JSON.stringify(res))
   return obj
@@ -264,24 +275,25 @@ const testPost = async(search?: string) : Promise<StorageStatusList[]> => {
   //   })
   // return Promise.resolve(obj)
 }
+
 ////出库取料箱出库
-export interface  Tasklist {
+export interface Tasklist {
 
   //批次号
   batchCode?: string;
-  ///完成数量
-  completedNum?:number
 
+  ///完成数量
+  completedNum?: number
   //已经占用箱数
-  useNum?:number
+  useNum?: number
   //空箱数
-  emptyBoxNum?:string
+  emptyBoxNum?: string
   //可用箱数
-  canUsedNum?:string
+  canUsedNum?: string
   //总容量箱数
-  allNum?:number
+  allNum?: number
   //仓储类型
-  type?:string
+  type?: string
   //批次号
 
   coordinate?: string
@@ -290,69 +302,71 @@ export interface  Tasklist {
   //
   creator?: string
   //仓库编码
-  houseNo?:string
+  houseNo?: string
   deptId?: string
-  houseType?:string
+  houseType?: string
   //主键
-  id?:string
+  id?: string
   locationNo?: string
   //	物料名称
-  materialName?:string
+  materialName?: string
   //物料编码
   materialNo?: string
   //出入库数量
   num?: number
   orgId?: string
-  relPlanNo?:string
-  relOrderNo?:string
-  relOutOrderNo?:string
-  progress?:string
+  relPlanNo?: string
+  relOrderNo?: string
+  relOutOrderNo?: string
+  progress?: string
   planNo?: string
   position?: string
   //	序列号
   seqNo?: string
   // 状态;1-待处理;2-处理中;3-处理异常;4-已完成
-  state?:number
+  state?: number
   //	库存数量
-  stockNum?:string
+  stockNum?: string
   //出入库任务单号
   taskNo?: string
-  unit?:string
+  unit?: string
   updated?: string
   //任务名称
-  taskName?:string
+  taskName?: string
   updator?: string
   vehicleNo?: string
 
 }
-const Tasklistoutbound = async() : Promise<Tasklist[]> => {
+
+const Tasklistoutbound = async (): Promise<Tasklist[]> => {
   let obj: Tasklist[] = []
-  let res:Tasklist = await StorageRequest.post("/api/v1/task/list", {
+  let res: Tasklist = await StorageRequest.post("/api/v1/task/list", {
     type: 2
-  }as RequestParamModel)
+  } as RequestParamModel)
   console.log('testTag', 'Tasklist成功' + JSON.stringify(res))
   obj = JSON.parse(JSON.stringify(res))
-  console.log('testTag', 'aaaaaaaa' +JSON.stringify(obj));
+  console.log('testTag', 'aaaaaaaa' + JSON.stringify(obj));
   return obj
 }
+
 /////物料位置
 export interface Materialpositionclass {
-  vehicleCode?:string
+  vehicleCode?: string
   //批次号
   batchCode?: string;
-  ///完成数量
-  completedNum?:number
 
+  ///完成数量
+  completedNum?: number
   //已经占用箱数
-  useNum?:number
+  useNum?: number
   //空箱数
-  emptyBoxNum?:string
+  emptyBoxNum?: string
   //可用箱数
-  canUsedNum?:string
+  canUsedNum?: string
   //总容量箱数
-  allNum?:number
+  allNum?: number
   //仓储类型
-  type?:string
+  type?: string
   //批次号
 
   coordinate?: string
@@ -361,14 +375,14 @@ export interface Materialpositionclass {
   //
   creator?: string
   //仓库编码
-  houseNo?:string
+  houseNo?: string
   deptId?: string
-  houseType?:string
+  houseType?: string
   //主键
-  id?:string
+  id?: string
   locationNo?: string
   //	物料名称
-  materialName?:string
+  materialName?: string
   //物料编码
   materialNo?: string
   //出入库数量
@@ -379,20 +393,21 @@ export interface Materialpositionclass {
   //	序列号
   seqNo?: string
   // 状态;1-待处理;2-处理中;3-处理异常;4-已完成
-  state?:number
+  state?: number
   //	库存数量
-  stockNum?:string
+  stockNum?: string
   //出入库任务单号
   taskNo?: string
-  unit?:string
+  unit?: string
   updated?: string
   //任务名称
-  taskName?:string
+  taskName?: string
   updator?: string
   vehicleNo?: string
-  pageNo?:number
-  pageSize?:number
+  pageNo?: number
+  pageSize?: number
 }
+
 // const Materialposition = async() : Promise< Materialpositionclass[]> => {
 //   let obj: Materialpositionclass[] = []
 //   let res:Materialpositionclass = await StorageRequest.post("/api/v3/stock/list", {
@@ -407,19 +422,19 @@ export interface Materialpositionclass {
 export interface SelectMaterialslist {
   //批次号
   batchCode?: string;
-  ///完成数量
-  completedNum?:number
 
+  ///完成数量
+  completedNum?: number
   //已经占用箱数
-  useNum?:number
+  useNum?: number
   //空箱数
-  emptyBoxNum?:string
+  emptyBoxNum?: string
   //可用箱数
-  canUsedNum?:string
+  canUsedNum?: string
   //总容量箱数
-  allNum?:number
+  allNum?: number
   //仓储类型
-  type?:string
+  type?: string
   //批次号
 
   coordinate?: string
@@ -428,14 +443,14 @@ export interface SelectMaterialslist {
   //
   creator?: string
   //仓库编码
-  houseNo?:string
+  houseNo?: string
   deptId?: string
-  houseType?:string
+  houseType?: string
   //主键
-  id?:string
+  id?: string
   locationNo?: string
   //	物料名称
-  materialName?:string
+  materialName?: string
   //物料编码
   materialNo?: string
   //出入库数量
@@ -446,20 +461,21 @@ export interface SelectMaterialslist {
   //	序列号
   seqNo?: string
   // 状态;1-待处理;2-处理中;3-处理异常;4-已完成
-  state?:number
+  state?: number
   //	库存数量
-  stockNum?:string
+  stockNum?: string
   //出入库任务单号
   taskNo?: string
-  unit?:string
+  unit?: string
   updated?: string
   //任务名称
-  taskName?:string
+  taskName?: string
   updator?: string
   vehicleNo?: string
-  pageNo?:number
-  pageSize?:number
+  pageNo?: number
+  pageSize?: number
 }
+
 // const SelectMaterials = async() : Promise<SelectMaterialslist[]> => {
 //   let res = await StorageRequest.post("/api/v3/task/page", {
 //     pageNo: 1
@@ -469,9 +485,9 @@ export interface SelectMaterialslist {
 //   return obj.records
 // }
 ////库存预警
-const stockWarning = async() : Promise<StorageStatusList1[]> => {
+const stockWarning = async (): Promise<StorageStatusList1[]> => {
   let obj: StorageStatusList1[] = []
-  let res:StorageStatusList1 = await StorageRequest.get("/api/v1/stock/stockWarning/1")
+  let res: StorageStatusList1 = await StorageRequest.get("/api/v1/stock/stockWarning/1")
   console.log('testTag', 'yyyyyyy' + JSON.stringify(res))
   obj = JSON.parse(JSON.stringify(res))
   return obj
@@ -487,4 +503,4 @@ const stockWarning = async() : Promise<StorageStatusList1[]> => {
 //   })
 //   console.log("执行了StorageRequest.testPut, 输出的结果", res)
 // }
- export  {Plan,testGet1, testPost,  BufferHopper,task,stockWarning,Warehousing,Tasklistoutbound, }
+export { Plan, testGet1, testPost, BufferHopper, task, stockWarning, Warehousing, Tasklistoutbound, }

+ 3 - 3
entry/src/main/ets/common/util/request/helps.ets

@@ -2,10 +2,10 @@ import { InternalAxiosRequestConfig, AxiosResponse, AxiosError } from "@ohos/axi
 import promptAction from '@ohos.promptAction'
 
 // 是否在控制台打印某项log
-const pConfig = false
-const pHeaders = false
+const pConfig = true
+const pHeaders = true
 const pUrl = true
-const pParams = false
+const pParams = true
 const pBody = true
 const pResponse = true
 const pData = true

+ 202 - 51
entry/src/main/ets/view/ManualOutbound.ets

@@ -8,6 +8,7 @@ import CommonConstants from '../common/constants/CommonConstants'
 import { stat2 } from './ManualWarehousing'
 import { MaterialInformationModel } from '../model/MaterialInformation'
 import { StationInfoModel } from '../model/StorageSpace'
+import { SureToDoDialog } from '../common/component/SureToDoDialog'
 
 @Entry
 @Component
@@ -19,6 +20,8 @@ export struct ManualOutbound {
   @State private Materialposition: Array<Materialpositionclass> = []
   //物料信息表
   @State private materialList: Array<MaterialInformationModel> = []
+  // 料箱位置的查看详情数据
+  @State private positionInfoList: Array<MaterialInformationModel> = []
   //物料编码
   @State materialCode: string = ''
   //料箱编号
@@ -39,33 +42,76 @@ export struct ManualOutbound {
   @State materiaNo: string = ''
   //取料箱中物料信息
   @State private boxMaterials: Array<MaterialInformationModel> = []
-  // @State private boxMaterials: Array<MaterialInformationList> = [
-  //   {
-  //     num: 200,
-  //     materialName: "哈哈哈哈哈",
-  //     materialCode: 'BM47111400130447;SL5',
-  //     unitDictLabel: "个"
-  //
-  //   },
-  //   {
-  //     num: 300,
-  //     materialName: "自知则知之",
-  //     materialCode: 'BM47111400130447;SL6'
-  //   },
-  //   {
-  //     num: 400,
-  //     materialName: "天天吞吞吐吐",
-  //     materialCode: 'BM47111400130447;SL7'
-  //   }
-  //
-  // ]
+  // 打开物料位置弹窗之后的操作
+  currentBoxStationModel: Materialpositionclass = {}
+  goingToLookDetail = async (m: Materialpositionclass) => {
+    this.currentBoxStationModel = m
+    let res: MaterialInformationModel[] = await StorageRequest.post("/api/v1/wmsOrder/outBox", {
+      vehicleCode: m.vehicleCode ?? ""
+    } as RequestParamModel)
+    this.positionInfoList = res
+    this.infoListController.open()
+  }
+  goingToOut = (m: Materialpositionclass) => {
+    this.currentBoxStationModel = m
+    this.infoDialogController.open()
+  }
+  dialogCancel = () => {
+    this.currentBoxStationModel = {}
+    this.infoDialogController.close()
+    this.infoListController.close()
+  }
+  dialogSure = async () => {
+    let res: outBoxClass = await StorageRequest.post("/api/v1/wmsOrder/outBox", {
+      houseNo: this.currentBoxStationModel?.houseNo ?? "",
+      vehicleNo: this.currentBoxStationModel?.vehicleNo ?? "",
+      stanCode: CommonConstants.STATION_CODE
+    } as RequestParamModel)
+
+    this.outBox = res
+
+    promptAction.showToast({
+      message: "任务进行中,请等待....",
+      duration: 1800,
+      bottom: '50%'
+    })
+    this.infoDialogController.close()
+    this.materialLocationController.close()
+
+  }
+  infoDialogController: CustomDialogController = new CustomDialogController({
+    builder: SureToDoDialog(
+      {
+        cancel: this.dialogCancel,
+        confirm: this.dialogSure,
+        title: "出库确认",
+        info: '确认出库当前料箱吗?'
+      }
+    ),
+    alignment: DialogAlignment.Center,
+    customStyle: true,
+    autoCancel: false,
+  })
+  infoListController: CustomDialogController = new CustomDialogController({
+    builder: LocationInfoListDialog(
+      {
+        closeDialog: this.dialogCancel,
+        materials: this.positionInfoList
+      }
+    ),
+    alignment: DialogAlignment.Center,
+    customStyle: true,
+    autoCancel: false,
+  })
   //物料位置
   materialLocationController: CustomDialogController = new CustomDialogController({
     builder: MaterialLocationDialog({
       outBox: this.outBox,
       materialName: this.materialName,
       Materialposition: this.Materialposition,
-      boxMaterials: this.boxMaterials
+      boxMaterials: this.boxMaterials,
+      lookDetail: this.goingToLookDetail,
+      goToOut: this.goingToOut,
     }),
     alignment: DialogAlignment.Center,
     customStyle: true,
@@ -350,12 +396,12 @@ export struct ManualOutbound {
                   this.materialLocationController.open()
                   this.onclick = index
                   this.materialName = item.materialName!
-                  this.MaterialpositionHttp().then((res: Materialpositionclass[]) => {
-                    console.log('testTag', 'result cccccc' + JSON.stringify(res))
-                    if (res && res.length > 0) {
-                      this.Materialposition = res
-                    }
-                  })
+                  // this.MaterialpositionHttp().then((res: Materialpositionclass[]) => {
+                  //   console.log('testTag', 'result cccccc' + JSON.stringify(res))
+                  //   if (res && res.length > 0) {
+                  //     this.Materialposition = res
+                  //   }
+                  // })
                 })
               }
             })
@@ -673,6 +719,10 @@ struct MaterialLocationDialog {
   @State vehicleNo: string = ''
   @State houseNo: string = ''
   Controller: CustomDialogController
+  lookDetail: (m: Materialpositionclass) => void = () => {
+  }
+  goToOut: (m: Materialpositionclass) => void = () => {
+  }
   //后端料箱出库
   RemoveMaterialBox = async () => {
     let res: outBoxClass = await StorageRequest.post("/api/v1/wmsOrder/outBox", {
@@ -746,20 +796,12 @@ struct MaterialLocationDialog {
             GridItem() {
               Row() {
                 Column() {
-                  Text(item?.coordinate ? item.coordinate + '-' + item.position : "")
-                    .fontSize($r('app.float.fontSize_24'))
-                    .fontWeight(FontWeight.Regular)
-                    .fontColor($r('app.color.black_90'))
-                    .height('20%')
-                    .width('100%')
-                  Text(item.materialName)
-                    .fontSize($r('app.float.fontSize_24'))
-                    .fontWeight(FontWeight.Regular)
-                    .fontColor($r('app.color.black_60'))
-                    .height('20%')
-                    .width('100%')
-                  Blank()
                   Row() {
+                    Text(item?.coordinate ? item.coordinate + '-' + item.position : "")
+                      .fontSize($r('app.float.fontSize_24'))
+                      .fontWeight(FontWeight.Regular)
+                      .fontColor($r('app.color.black_90'))
+                      .margin({ right: 15 })
                     Text(item.num?.toString())
                       .fontSize($r('app.float.fontSize_38'))
                       .fontWeight(FontWeight.Bold)
@@ -769,32 +811,66 @@ struct MaterialLocationDialog {
                       .fontWeight(FontWeight.Regular)
                       .fontColor($r('app.color.black_60'))
                   }
-                  .height('50%')
+
+                  Text(item.materialName)
+                    .fontSize($r('app.float.fontSize_24'))
+                    .fontWeight(FontWeight.Regular)
+                    .fontColor($r('app.color.black_60'))
+                    .width('100%')
+                  Blank()
+
                 }
-                .width('100%')
-                .padding(10)
-                .borderRadius(10)
+                .width('60%')
                 .alignItems(HorizontalAlign.Start)
                 .justifyContent(FlexAlign.Center)
                 .height('100%')
+
+                Row() {
+                  Text("详情")
+                    .fontSize($r('app.float.fontSize_24'))
+                    .fontWeight(FontWeight.Regular)
+                    .fontColor($r('app.color.white_100'))
+                    .backgroundColor($r('app.color.blue_100'))
+                    .height(40)
+                    .textAlign(TextAlign.Center)
+                    .borderRadius(10)
+                    .width(60)
+                    .onClick(() => {
+                      this.lookDetail(item)
+                    })
+
+
+                  Text("出库")
+                    .fontSize($r('app.float.fontSize_24'))
+                    .fontWeight(FontWeight.Regular)
+                    .fontColor($r('app.color.white_100'))
+                    .margin({ left: 15 })
+                    .backgroundColor($r('app.color.warn_1'))
+                    .height(40)
+                    .textAlign(TextAlign.Center)
+                    .borderRadius(10)
+                    .width(60)
+                    .onClick(() => {
+                      this.goToOut(item)
+                    })
+
+                }
+                .width('40%')
+                .justifyContent(FlexAlign.End)
+                .height('100%')
               }
               .padding(5)
               .borderRadius(10)
-              .height('25%')
+              .height('12%')
               .width('100%')
               .backgroundColor(this.selectMaterial === index ? $r('app.color.robot_set_card_blue') : $r('app.color.robot_set_card_white'))
-              .onClick(async () => {
-                this.houseNo = item.houseNo!
-                this.vehicleNo = item.vehicleCode!
 
-                this.RemoveMaterialBox()
-              })
             }
             .padding({ left: 5 })
           })
         }
         .padding(10)
-        .columnsTemplate('1fr 1fr 1fr 1fr 1fr 1fr')
+        .columnsTemplate('1fr 1fr')
         .columnsGap(10)
         .rowsGap(10)
         .width('100%')
@@ -808,6 +884,81 @@ struct MaterialLocationDialog {
   }
 }
 
+
+// 物料位置(物料在哪些料箱里面)
+@CustomDialog
+struct LocationInfoListDialog {
+  @Link materials: MaterialInformationModel[]
+  scroller: Scroller = new Scroller()
+  Controller: CustomDialogController
+  closeDialog: () => void = () => {
+  }
+
+  build() {
+    Stack() {
+      Column() {
+        Grid(this.scroller) {
+          ForEach(this.materials, (item: MaterialInformationModel, index: number) => {
+            GridItem() {
+              Column() {
+                Row() {
+                  Text(item?.materialName)
+                    .fontSize($r('app.float.fontSize_24'))
+                    .fontWeight(FontWeight.Regular)
+                    .fontColor($r('app.color.black_90'))
+                    .margin({ right: 15 })
+                  Row() {
+                    Text(item.num?.toString())
+                      .fontSize($r('app.float.fontSize_38'))
+                      .fontWeight(FontWeight.Bold)
+                      .fontColor($r('app.color.black_90'))
+                    Text(item.unitDictLabel)
+                      .fontSize($r('app.float.fontSize_24'))
+                      .fontWeight(FontWeight.Regular)
+                      .fontColor($r('app.color.black_60'))
+                  }
+                }
+                .justifyContent(FlexAlign.SpaceBetween)
+                .width('100%')
+
+                Text(item.materialCode)
+                  .fontSize($r('app.float.fontSize_24'))
+                  .fontWeight(FontWeight.Regular)
+                  .fontColor($r('app.color.black_60'))
+                  .width('100%')
+
+              }
+              .width('100%')
+              .alignItems(HorizontalAlign.Start)
+              .justifyContent(FlexAlign.Center)
+              .height('60')
+
+            }
+            .padding({ left: 5, bottom: 8 })
+            .borderRadius(5)
+            .border({ width: 2, color: Color.Gray })
+          })
+        }
+        .padding(10)
+        .columnsTemplate('1fr')
+        .columnsGap(10)
+        .rowsGap(10)
+        .width('100%')
+        .height('100%')
+      }
+      .width('100%')
+      .height('100%')
+    }
+    .width('60%')
+    .height('80%')
+    .backgroundColor($r('app.color.page_general_background'))
+    .borderRadius(20)
+    .onClick(() => {
+      this.closeDialog()
+    })
+  }
+}
+
 export class outboundMaterialsClass {
   //批次号
   batchCode?: string;