|
@@ -238,8 +238,8 @@ export struct ManualWarehousing {
|
|
|
|
|
|
if (res && res.length && res.length > 0) {
|
|
|
this.MaterialInformation = res
|
|
|
+ console.log('dyy',JSON.stringify(res))
|
|
|
}
|
|
|
-
|
|
|
}
|
|
|
// 清空的按钮调用这个方法
|
|
|
clearData = () => {
|
|
@@ -468,14 +468,17 @@ export struct ManualWarehousing {
|
|
|
Text(item.materialName)
|
|
|
.fontWeight(FontWeight.Medium)// Text(item.materialCode)
|
|
|
.fontSize($r('app.float.fontSize_24'))
|
|
|
+ Text(item.materialCode)
|
|
|
+ .fontWeight(FontWeight.Medium)
|
|
|
+ .fontSize($r('app.float.fontSize_24'))
|
|
|
Text(item.spec)
|
|
|
.fontColor("#666666")
|
|
|
.fontWeight(FontWeight.Regular)
|
|
|
.fontSize($r('app.float.fontSize_20'))
|
|
|
- Text(item.type)
|
|
|
- .fontColor("#666666")
|
|
|
- .fontWeight(FontWeight.Regular)
|
|
|
- .fontSize($r('app.float.fontSize_20'))
|
|
|
+ // Text(item.type)
|
|
|
+ // .fontColor("#666666")
|
|
|
+ // .fontWeight(FontWeight.Regular)
|
|
|
+ // .fontSize($r('app.float.fontSize_20'))
|
|
|
Row() {
|
|
|
Text(item.num?.toString())
|
|
|
.fontWeight(FontWeight.Bold)
|
|
@@ -776,6 +779,43 @@ export struct ManualWarehousing {
|
|
|
}
|
|
|
}
|
|
|
|
|
|
+@Component
|
|
|
+struct TextInputExample {
|
|
|
+ @Link exchangeNumber: number
|
|
|
+ @Link index: number
|
|
|
+ @Link num: number
|
|
|
+ @Link private MaterialInformation: Array<MaterialInformationModel>
|
|
|
+ controller: TextInputController = new TextInputController()
|
|
|
+
|
|
|
+ build() {
|
|
|
+ TextInput({ text:this.num.toString(), controller: this.controller })
|
|
|
+ .fontSize($r('app.float.title_font_size'))
|
|
|
+ .fontWeight(FontWeight.Bold)
|
|
|
+ .fontColor($r('app.color.general_font_color'))// .opacity($r('app.float.general_font_opacity'))
|
|
|
+ .height('85%')
|
|
|
+ .width('60%')
|
|
|
+ .textAlign(TextAlign.Center)
|
|
|
+ .backgroundColor($r('app.color.general_card_background_color'))
|
|
|
+ .borderRadius(0)
|
|
|
+ .border({ width: 0.8 })
|
|
|
+ .onChange((newValue: string) => {
|
|
|
+ this.num = Number(newValue)
|
|
|
+ this.MaterialInformation[this.index] = {
|
|
|
+ taskId: this.MaterialInformation[this.index].taskId!,
|
|
|
+ materialName: this.MaterialInformation[this.index].materialName!,
|
|
|
+ // exchangeNumber:this.MaterialInformation[this.index].exchangeNumber!,
|
|
|
+ exchangeNumber: this.exchangeNumber,
|
|
|
+ num: this.num,
|
|
|
+ materialCode: this.MaterialInformation[this.index].materialCode!,
|
|
|
+ batchCode: this.MaterialInformation[this.index].batchCode!,
|
|
|
+ seqNo: this.MaterialInformation[this.index].seqNo!,
|
|
|
+ spec: this.MaterialInformation[this.index].spec!,
|
|
|
+ }
|
|
|
+ console.log('dyy',this.num)
|
|
|
+ })
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
@CustomDialog
|
|
|
///无批次号物料详情弹窗
|
|
|
struct materialDetails {
|
|
@@ -832,7 +872,7 @@ struct materialDetails {
|
|
|
.textAlign(TextAlign.Start)
|
|
|
.fontColor('#99000000')
|
|
|
.width('100%')
|
|
|
- Text('规格描述:' + this.materialModel)
|
|
|
+ Text('规格型号:' + this.materialModel)
|
|
|
.fontSize($r('app.float.robot_state_font_size'))
|
|
|
.textAlign(TextAlign.Start)
|
|
|
.fontColor('#99000000')
|
|
@@ -842,14 +882,12 @@ struct materialDetails {
|
|
|
.fontSize($r('app.float.robot_state_font_size'))
|
|
|
.textAlign(TextAlign.Start)
|
|
|
.fontColor('#99000000')
|
|
|
-
|
|
|
.maxLines(1)
|
|
|
.textOverflow({ overflow: TextOverflow.Ellipsis })
|
|
|
Text(this.batchCode)
|
|
|
.fontSize($r('app.float.robot_state_font_size'))
|
|
|
.textAlign(TextAlign.Start)
|
|
|
.fontColor('#99000000')
|
|
|
-
|
|
|
.maxLines(1)
|
|
|
.textOverflow({ overflow: TextOverflow.Ellipsis })
|
|
|
|
|
@@ -888,30 +926,36 @@ struct materialDetails {
|
|
|
spec: this.MaterialInformation[this.index].spec,
|
|
|
}
|
|
|
})
|
|
|
- TextInput({ text: this.num?.toString() })
|
|
|
- .fontSize($r('app.float.title_font_size'))
|
|
|
- .fontWeight(FontWeight.Bold)
|
|
|
- .fontColor($r('app.color.general_font_color'))// .opacity($r('app.float.general_font_opacity'))
|
|
|
- .height('85%')
|
|
|
- .width('60%')
|
|
|
- .type(InputType.Number)
|
|
|
- .textAlign(TextAlign.Center)
|
|
|
- .backgroundColor($r('app.color.general_card_background_color'))
|
|
|
- .borderRadius(0)
|
|
|
- .border({ width: 0.8 })
|
|
|
- .onChange(() => {
|
|
|
- this.MaterialInformation[this.index] = {
|
|
|
- taskId: this.MaterialInformation[this.index].taskId!,
|
|
|
- materialName: this.MaterialInformation[this.index].materialName!,
|
|
|
- // exchangeNumber:this.MaterialInformation[this.index].exchangeNumber!,
|
|
|
- exchangeNumber: this.exchangeNumber,
|
|
|
- num: this.num,
|
|
|
- materialCode: this.MaterialInformation[this.index].materialCode!,
|
|
|
- batchCode: this.MaterialInformation[this.index].batchCode!,
|
|
|
- seqNo: this.MaterialInformation[this.index].seqNo!,
|
|
|
- spec: this.MaterialInformation[this.index].spec!,
|
|
|
- }
|
|
|
- })
|
|
|
+ TextInputExample({
|
|
|
+ MaterialInformation:this.MaterialInformation,
|
|
|
+ num:this.num,
|
|
|
+ exchangeNumber:this.exchangeNumber,
|
|
|
+ index:this.index
|
|
|
+ })
|
|
|
+ // TextInput({ text:this.num.toString() })
|
|
|
+ // .fontSize($r('app.float.title_font_size'))
|
|
|
+ // .fontWeight(FontWeight.Bold)
|
|
|
+ // .fontColor($r('app.color.general_font_color'))// .opacity($r('app.float.general_font_opacity'))
|
|
|
+ // .height('85%')
|
|
|
+ // .width('60%')
|
|
|
+ // .textAlign(TextAlign.Center)
|
|
|
+ // .backgroundColor($r('app.color.general_card_background_color'))
|
|
|
+ // .borderRadius(0)
|
|
|
+ // .border({ width: 0.8 })
|
|
|
+ // .onChange(() => {
|
|
|
+ // this.MaterialInformation[this.index] = {
|
|
|
+ // taskId: this.MaterialInformation[this.index].taskId!,
|
|
|
+ // materialName: this.MaterialInformation[this.index].materialName!,
|
|
|
+ // // exchangeNumber:this.MaterialInformation[this.index].exchangeNumber!,
|
|
|
+ // exchangeNumber: this.exchangeNumber,
|
|
|
+ // num: this.num,
|
|
|
+ // materialCode: this.MaterialInformation[this.index].materialCode!,
|
|
|
+ // batchCode: this.MaterialInformation[this.index].batchCode!,
|
|
|
+ // seqNo: this.MaterialInformation[this.index].seqNo!,
|
|
|
+ // spec: this.MaterialInformation[this.index].spec!,
|
|
|
+ // }
|
|
|
+ // })
|
|
|
+
|
|
|
|
|
|
Image($r('app.media.add_disabled'))
|
|
|
.width(px2vp(120))
|