Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
J
jump_hm_warehouse
概览
Overview
Details
Activity
Cycle Analytics
版本库
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
问题
0
Issues
0
列表
Board
标记
里程碑
合并请求
0
Merge Requests
0
CI / CD
CI / CD
流水线
作业
日程表
图表
维基
Wiki
代码片段
Snippets
成员
Members
Collapse sidebar
Close sidebar
活动
图像
聊天
创建新问题
作业
提交
Issue Boards
Open sidebar
毛勇泽
jump_hm_warehouse
Commits
26fd5c1d
Commit
26fd5c1d
authored
Jan 22, 2024
by
陈桂东
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
commit
parent
2e175768
显示空白字符变更
内嵌
并排
正在显示
7 个修改的文件
包含
57 行增加
和
26 行删除
+57
-26
oh-package-lock.json5
common/oh-package-lock.json5
+19
-0
BzhxDao.ets
common/src/main/ets/db/dao/BzhxDao.ets
+10
-0
BzhxModel.ets
entry/src/main/ets/model/BzhxModel.ets
+10
-2
HwModel.ets
entry/src/main/ets/model/HwModel.ets
+10
-5
LeftDialog.ets
entry/src/main/ets/pages/metailmange/WzInPage/WzinDetail/LeftDialog.ets
+0
-4
PzInfo.ets
entry/src/main/ets/pages/metailmange/WzInPage/WzinDetail/PzInfo.ets
+2
-3
WzinDetail.ets
entry/src/main/ets/pages/metailmange/WzInPage/WzinDetail/WzinDetail.ets
+6
-12
没有找到文件。
common/oh-package-lock.json5
0 → 100644
View file @
26fd5c1d
{
"lockfileVersion": 1,
"ATTENTION": "THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY.",
"specifiers": {
"reflect-metadata@^0.1.13": "reflect-metadata@0.1.13",
"@ohos/axios@^2.1.1": "@ohos/axios@2.1.1"
},
"packages": {
"reflect-metadata@0.1.13": {
"resolved": "https://repo.harmonyos.com/ohpm/reflect-metadata/-/reflect-metadata-0.1.13.tgz",
"integrity": "sha512-Ts1Y/anZELhSsjMcU605fU9RE4Oi3p5ORujwbIKXfWa+0Zxs510Qrmrce5/Jowq3cHSZSJqBjypxmHarc+vEWg=="
},
"@ohos/axios@2.1.1": {
"resolved": "https://repo.harmonyos.com/ohpm/@ohos/axios/-/axios-2.1.1.har",
"integrity": "sha512-EQax257+eKKT0Rx7h6N6xvmKbDRWDjCCWOP2vyyktySFwvjtypXuXmQKEvRjmAalR6cqf8mbfhWmpg0bD9OQ3w=="
}
}
}
\ No newline at end of file
common/src/main/ets/db/dao/BzhxDao.ets
View file @
26fd5c1d
...
@@ -67,6 +67,16 @@ export class BzhxDao extends BaseTable<Bzhx> {
...
@@ -67,6 +67,16 @@ export class BzhxDao extends BaseTable<Bzhx> {
wp.orderByAsc('GUID').offsetAs(offset).limitAs(20);
wp.orderByAsc('GUID').offsetAs(offset).limitAs(20);
return this.query(wp, this.getTableColumns())
return this.query(wp, this.getTableColumns())
}
}
// 获取被装号型列表
async getBzhxByCode(pmdmcode: string): Promise<Bzhx[]> {
let wp = this.getPredicates();
wp.equalTo('PMDMTEN', pmdmcode);
return this.query(wp, this.getTableColumns())
}
async selectWZInfo(lsm?:string):Promise<Bzhx[]>{
async selectWZInfo(lsm?:string):Promise<Bzhx[]>{
let wp = this.getPredicates();
let wp = this.getPredicates();
if (lsm) {
if (lsm) {
...
...
entry/src/main/ets/model/BzhxModel.ets
View file @
26fd5c1d
...
@@ -22,10 +22,18 @@ class BzhxModel {
...
@@ -22,10 +22,18 @@ class BzhxModel {
}
}
// 查询被装号型
// 查询被装号型
async query(offset: number, pmdmsix? : string
,pmdmten? : string
): Promise<Bzhx[]> {
async query(offset: number, pmdmsix? : string): Promise<Bzhx[]> {
let res = await SQLiteContext.with(BzhxDao).getBzhxList(offset, pmdmsix
, pmdmten
)
let res = await SQLiteContext.with(BzhxDao).getBzhxList(offset, pmdmsix)
return res;
return res;
}
}
// 根据品名代码查询
async queryByCode(pmdmcode:string): Promise<Bzhx> {
let res = await SQLiteContext.with(BzhxDao).getBzhxByCode(pmdmcode)
return res[0];
}
async queryLsm(lsm?: string):Promise<Bzhx[]> {
async queryLsm(lsm?: string):Promise<Bzhx[]> {
let res = await SQLiteContext.with(BzhxDao).selectWZInfo(lsm);
let res = await SQLiteContext.with(BzhxDao).selectWZInfo(lsm);
Logger.info("查询LSM结果"+JSON.stringify(res))
Logger.info("查询LSM结果"+JSON.stringify(res))
...
...
entry/src/main/ets/model/HwModel.ets
View file @
26fd5c1d
import { HwInfo, SQLiteContext,
HwInfoDao
} from '@ohos/common'
import { HwInfo, SQLiteContext,
HwInfoDao
} from '@ohos/common'
// 货位管理
// 货位管理
class HwModel {
class HwModel {
// 添加货位
// 添加货位
async set(data: HwInfo[]) {
async set(data: HwInfo[]) {
await SQLiteContext.with(HwInfoDao).batchInsert(data)
const copyData = data.map((v) => {
return {
...v,
hwzt: "11111111SF1"
}
})
await SQLiteContext.with(HwInfoDao).batchInsert(copyData)
}
}
// 查询货位
// 查询货位
async query(no?
: string): Promise<HwInfo[]> {
async query(no?: string): Promise<HwInfo[]> {
let res = await SQLiteContext.with(HwInfoDao).getHwList(no)
let res = await SQLiteContext.with(HwInfoDao).getHwList(no)
return res;
return res;
}
}
// 查询库房下货位
// 查询库房下货位
async queryHw(kfguid?
: string): Promise<HwInfo[]> {
async queryHw(kfguid?: string): Promise<HwInfo[]> {
let res = await SQLiteContext.with(HwInfoDao).getselectHwList(kfguid)
let res = await SQLiteContext.with(HwInfoDao).getselectHwList(kfguid)
return res;
return res;
}
}
...
@@ -21,7 +27,6 @@ class HwModel {
...
@@ -21,7 +27,6 @@ class HwModel {
async clear() {
async clear() {
await SQLiteContext.with(HwInfoDao).clearTable()
await SQLiteContext.with(HwInfoDao).clearTable()
}
}
}
}
const hwModel = new HwModel()
const hwModel = new HwModel()
...
...
entry/src/main/ets/pages/metailmange/WzInPage/WzinDetail/LeftDialog.ets
View file @
26fd5c1d
...
@@ -17,10 +17,8 @@ export struct LeftDialog {
...
@@ -17,10 +17,8 @@ export struct LeftDialog {
Text('凭证数量:' + this.item.pzsl).fontSize(12).fontColor('#3b4144').margin({ top: 30 })
Text('凭证数量:' + this.item.pzsl).fontSize(12).fontColor('#3b4144').margin({ top: 30 })
}
}
.width('70%')
.width('70%')
Blank()
Blank()
.layoutWeight(1)
.layoutWeight(1)
Flex({ direction: FlexDirection.Column, justifyContent: FlexAlign.Center, alignItems: ItemAlign.Start }) {
Flex({ direction: FlexDirection.Column, justifyContent: FlexAlign.Center, alignItems: ItemAlign.Start }) {
if(this.item.wczt == '未完成' && this.item.crksl < this.item.pzsl) {
if(this.item.wczt == '未完成' && this.item.crksl < this.item.pzsl) {
Text('未完成').fontSize(14).fontColor('red')
Text('未完成').fontSize(14).fontColor('red')
...
@@ -29,9 +27,7 @@ export struct LeftDialog {
...
@@ -29,9 +27,7 @@ export struct LeftDialog {
}
}
Text('入库数量: ' + this.item.crksl).fontSize(12).fontColor('#3b4144').margin({ top: 30 })
Text('入库数量: ' + this.item.crksl).fontSize(12).fontColor('#3b4144').margin({ top: 30 })
}
}
.width('40%')
.width('40%')
}
}
.width('100%')
.width('100%')
.justifyContent(FlexAlign.SpaceBetween)
.justifyContent(FlexAlign.SpaceBetween)
...
...
entry/src/main/ets/pages/metailmange/WzInPage/WzinDetail/PzInfo.ets
View file @
26fd5c1d
...
@@ -26,9 +26,6 @@ export struct PzInfo {
...
@@ -26,9 +26,6 @@ export struct PzInfo {
case 'zmlx':
case 'zmlx':
return renderZmlx(this.wzcrk.zmlx)
return renderZmlx(this.wzcrk.zmlx)
case '':
return ''
default:
default:
return String(this.wzcrk[key])
return String(this.wzcrk[key])
}
}
...
@@ -50,6 +47,8 @@ export struct PzInfo {
...
@@ -50,6 +47,8 @@ export struct PzInfo {
.width("70%")
.width("70%")
.height(40)
.height(40)
.padding(10)
.padding(10)
.borderColor('#bcc5d7')
.borderWidth(1)
.backgroundColor(item.enabled ? '#fff' : "app.color.disabledColor")
.backgroundColor(item.enabled ? '#fff' : "app.color.disabledColor")
.enabled(item.enabled)
.enabled(item.enabled)
}.padding("10vp")
}.padding("10vp")
...
...
entry/src/main/ets/pages/metailmange/WzInPage/WzinDetail/WzinDetail.ets
View file @
26fd5c1d
...
@@ -5,7 +5,6 @@ import { Wzcrk } from '@ohos/common/src/main/ets/entity/Wzcrk';
...
@@ -5,7 +5,6 @@ import { Wzcrk } from '@ohos/common/src/main/ets/entity/Wzcrk';
import {WzInfo} from './WzInfo'
import {WzInfo} from './WzInfo'
import {PzInfo} from './PzInfo'
import {PzInfo} from './PzInfo'
import wzcrkmxModel from '../../../../model/WzcrkmxModel';
import wzcrkmxModel from '../../../../model/WzcrkmxModel';
import { Wzcrkmx } from '@ohos/common/src/main/ets/entity/Wzcrkmx';
import { WzmxClass } from '../Wzin.data';
import { WzmxClass } from '../Wzin.data';
import bzhxModel from '../../../../model/BzhxModel';
import bzhxModel from '../../../../model/BzhxModel';
...
@@ -43,28 +42,26 @@ struct WzinDetail{
...
@@ -43,28 +42,26 @@ struct WzinDetail{
// 获取凭证信息
// 获取凭证信息
async getDetail() {
async getDetail() {
const res = await wzcrkmxModel.query(this.wzcrk.guid)
const res = await wzcrkmxModel.query(this.wzcrk.guid)
Logger.info('接收到出入库物资明细信息>>', JSON.stringify(res))
for (let index = 0; index < res.length; index++) {
for (let index = 0; index < res.length; index++) {
const element = res[index];
const element = res[index];
const res1 = await bzhxModel.query(0, '', element.pmdmcode)
const res1 = await bzhxModel.queryByCode(element.pmdmcode)
Logger.info('查询到对应品名代码》》',JSON.stringify(res1))
Logger.info('查询到对应品名代码》》',JSON.stringify(res1))
// @ts-ignore
// @ts-ignore
element.xh = res1
[0]
.xh
element.xh = res1.xh
// @ts-ignore
// @ts-ignore
element.hxmc = res1
[0]
.hxmc
element.hxmc = res1.hxmc
// @ts-ignore
// @ts-ignore
element.pmdmSix = res1
[0]
.pmdmSix
element.pmdmSix = res1.pmdmSix
// @ts-ignore
// @ts-ignore
element.wzpm = res1
[0]
.wzpm
element.wzpm = res1.wzpm
// @ts-ignore
// @ts-ignore
element.wczt = this.wzcrk.wczt
element.wczt = this.wzcrk.wczt
// @ts-ignore
// @ts-ignore
this.wzmx.push(new WzmxClass(element))
this.wzmx.push(new WzmxClass(element))
}
}
Logger.info('接收到出入库物资明细信息>>', JSON.stringify(this.wzmx))
}
}
@Builder TabBuilder(index: number, name: string) {
@Builder TabBuilder(index: number, name: string) {
Column() {
Column() {
Text(name)
Text(name)
...
@@ -77,9 +74,6 @@ struct WzinDetail{
...
@@ -77,9 +74,6 @@ struct WzinDetail{
.borderRadius(3)
.borderRadius(3)
.backgroundColor(this.currentIndex === index ? this.fontColor : '#00000000')
.backgroundColor(this.currentIndex === index ? this.fontColor : '#00000000')
}
}
@Builder VoucherRow() {
}
build(){
build(){
Column() {
Column() {
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论