图标配置
|
|
@ -1,5 +1,5 @@
|
|||
{
|
||||
"name" : "material-app",
|
||||
"name" : "材料站管理",
|
||||
"appid" : "__UNI__AEEB2B7",
|
||||
"description" : "",
|
||||
"versionName" : "1.0.1",
|
||||
|
|
@ -60,6 +60,38 @@
|
|||
"sdkConfigs" : {
|
||||
"ad" : {},
|
||||
"geolocation" : {}
|
||||
},
|
||||
"icons" : {
|
||||
"android" : {
|
||||
"hdpi" : "unpackage/res/icons/72x72.png",
|
||||
"xhdpi" : "unpackage/res/icons/96x96.png",
|
||||
"xxhdpi" : "unpackage/res/icons/144x144.png",
|
||||
"xxxhdpi" : "unpackage/res/icons/192x192.png"
|
||||
},
|
||||
"ios" : {
|
||||
"appstore" : "unpackage/res/icons/1024x1024.png",
|
||||
"ipad" : {
|
||||
"app" : "unpackage/res/icons/76x76.png",
|
||||
"app@2x" : "unpackage/res/icons/152x152.png",
|
||||
"notification" : "unpackage/res/icons/20x20.png",
|
||||
"notification@2x" : "unpackage/res/icons/40x40.png",
|
||||
"proapp@2x" : "unpackage/res/icons/167x167.png",
|
||||
"settings" : "unpackage/res/icons/29x29.png",
|
||||
"settings@2x" : "unpackage/res/icons/58x58.png",
|
||||
"spotlight" : "unpackage/res/icons/40x40.png",
|
||||
"spotlight@2x" : "unpackage/res/icons/80x80.png"
|
||||
},
|
||||
"iphone" : {
|
||||
"app@2x" : "unpackage/res/icons/120x120.png",
|
||||
"app@3x" : "unpackage/res/icons/180x180.png",
|
||||
"notification@2x" : "unpackage/res/icons/40x40.png",
|
||||
"notification@3x" : "unpackage/res/icons/60x60.png",
|
||||
"settings@2x" : "unpackage/res/icons/58x58.png",
|
||||
"settings@3x" : "unpackage/res/icons/87x87.png",
|
||||
"spotlight@2x" : "unpackage/res/icons/80x80.png",
|
||||
"spotlight@3x" : "unpackage/res/icons/120x120.png"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"nativePlugins" : {}
|
||||
|
|
|
|||
|
|
@ -66,7 +66,7 @@
|
|||
<button style="width: 100px" type="primary" @click="scanStart">二维码出库</button>
|
||||
</uni-col>
|
||||
<uni-col :span="6">
|
||||
<button style="width: 100px" type="primary" @click="">RFID识别</button>
|
||||
<button style="width: 100px" type="primary" @click="handleRfid">RFID识别</button>
|
||||
</uni-col>
|
||||
<uni-col :span="6">
|
||||
<button style="width: 100px" type="primary" @click="ocrClick">OCR识别</button>
|
||||
|
|
@ -234,17 +234,17 @@ const delMaterial = (item, index) => {
|
|||
}
|
||||
// 获取编码列表
|
||||
const getCodeDetailData = async (id, publishTask, typeId) => {
|
||||
console.log('yyyyyyyyyy', id, publishTask, typeId)
|
||||
const res = await getCodeDetailAPI({ id: id, publishTask: publishTask, typeId: typeId })
|
||||
console.log('zzzzzzzzz', res)
|
||||
formData.value = res.data
|
||||
console.log('xxxxxxxxxxxxxx', formData.value, maxNum.value)
|
||||
// maxNum.value = formData.value.preNum - formData.value.alNum
|
||||
// console.log('yyyyyyyyyy', id, publishTask, typeId)
|
||||
// const res = await getCodeDetailAPI({ id: id, publishTask: publishTask, typeId: typeId })
|
||||
// console.log('zzzzzzzzz', res)
|
||||
// formData.value = res.data
|
||||
// console.log('xxxxxxxxxxxxxx', formData.value, maxNum.value)
|
||||
// // maxNum.value = formData.value.preNum - formData.value.alNum
|
||||
|
||||
queryCodeParams.value.typeId = queryParams.value.typeId
|
||||
queryCodeParams.value.pageNum = 1
|
||||
codeDeviceList.value = []
|
||||
getCodeDeviceListData() //获取编码列表
|
||||
// queryCodeParams.value.typeId = queryParams.value.typeId
|
||||
// queryCodeParams.value.pageNum = 1
|
||||
// codeDeviceList.value = []
|
||||
// getCodeDeviceListData() //获取编码列表
|
||||
}
|
||||
|
||||
// 获取编码列表
|
||||
|
|
@ -512,6 +512,8 @@ const scanStart = () => {
|
|||
uni.showToast({ title: '扫码识别失败', icon: 'none' })
|
||||
} else {
|
||||
const params = { qrCode, typeId: queryParams.value.typeId }
|
||||
console.log('🚀 ~ success: ~ queryParams.value.isAddCode:', queryParams.value.isAddCode)
|
||||
if (queryParams.value.isAddCode) delete params.typeId
|
||||
console.log('🚀 ~ success: ~ params:', params)
|
||||
try {
|
||||
const res = await getInfoByQrcode(params)
|
||||
|
|
@ -537,7 +539,7 @@ const scanStart = () => {
|
|||
})
|
||||
}
|
||||
} else {
|
||||
uni.showToast({ title: res.data.msg, icon: 'none' })
|
||||
uni.showToast({ title: res.data.msg, icon: 'none', duration: 1500 })
|
||||
}
|
||||
} else {
|
||||
uni.showToast({ title: '扫码识别失败', icon: 'none' })
|
||||
|
|
@ -553,6 +555,12 @@ const scanStart = () => {
|
|||
})
|
||||
}
|
||||
|
||||
// 处理RFID识别
|
||||
const handleRfid = () => {
|
||||
// 提示
|
||||
uni.showToast({ title: '请在扫码终端操作', icon: 'none' })
|
||||
}
|
||||
|
||||
// 处理扫描成功事件
|
||||
const handleScanSuccess = (result) => {
|
||||
qrCodeScan.value = result
|
||||
|
|
|
|||
|
|
@ -84,7 +84,7 @@
|
|||
<uni-td align="center"
|
||||
><uni-easyinput
|
||||
v-model="item.preNum"
|
||||
placeholder="请输入内容"
|
||||
placeholder="请输入数量"
|
||||
type="number"
|
||||
@blur="checkPerNum(item)"
|
||||
></uni-easyinput
|
||||
|
|
@ -256,6 +256,17 @@ const checkPerNum = (item) => {
|
|||
item.preNum = 1
|
||||
return false
|
||||
}
|
||||
if (opts.value.isNew == 0 || opts.value.isOut) {
|
||||
if (item.preNum > item.storageNum) {
|
||||
uni.showToast({
|
||||
icon: 'none',
|
||||
title: '出库数量不能大于库存数量',
|
||||
})
|
||||
// 重置为库存数量
|
||||
item.preNum = item.storageNum
|
||||
return false
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// 选择工程
|
||||
|
|
@ -305,8 +316,6 @@ const submit = () => {
|
|||
form.value
|
||||
.validate()
|
||||
.then(async (valid) => {
|
||||
if (loading.value) return
|
||||
loading.value = true
|
||||
console.log('🚀 ~ form.value.validate.then ~ valid:', valid)
|
||||
if (tableData.value.length === 0) {
|
||||
await uni.showToast({
|
||||
|
|
@ -340,9 +349,17 @@ const submit = () => {
|
|||
if (!opts.value.isEdit && opts.value.isNew != 0) {
|
||||
const res = await addLeaseTask(params)
|
||||
console.log('🚀 ~ .then ~ res:', res)
|
||||
uni.showToast({
|
||||
icon: 'none',
|
||||
title: '操作成功',
|
||||
})
|
||||
back()
|
||||
} else if (opts.value.isEdit && opts.value.isNew != 0) {
|
||||
const res = await editLeaseTask(params)
|
||||
uni.showToast({
|
||||
icon: 'none',
|
||||
title: '操作成功',
|
||||
})
|
||||
back()
|
||||
} else {
|
||||
let res = {}
|
||||
|
|
@ -357,18 +374,16 @@ const submit = () => {
|
|||
item.parentId = opts.value.parentId || res.data
|
||||
item.outNum = item.preNum
|
||||
})
|
||||
await leaseOutApi({ leaseOutDetailsList: tableData.value })
|
||||
const res2 = await leaseOutApi({ leaseOutDetailsList: tableData.value })
|
||||
console.log('🚀 ~ .then ~ res2:', res2)
|
||||
uni.showToast({
|
||||
icon: 'none',
|
||||
title: '操作成功',
|
||||
})
|
||||
back()
|
||||
}
|
||||
loading.value = false
|
||||
// 提示
|
||||
uni.showToast({
|
||||
icon: 'none',
|
||||
title: '操作成功',
|
||||
})
|
||||
} catch (error) {
|
||||
console.log('🚀 ~ .then ~ error:', error)
|
||||
loading.value = false
|
||||
}
|
||||
})
|
||||
.catch((err) => {
|
||||
|
|
|
|||
|
After Width: | Height: | Size: 20 KiB |
|
After Width: | Height: | Size: 21 KiB |
|
After Width: | Height: | Size: 203 KiB |
|
After Width: | Height: | Size: 7.7 KiB |
|
After Width: | Height: | Size: 11 KiB |
|
After Width: | Height: | Size: 12 KiB |
|
After Width: | Height: | Size: 14 KiB |
|
After Width: | Height: | Size: 16 KiB |
|
After Width: | Height: | Size: 17 KiB |
|
After Width: | Height: | Size: 590 B |
|
After Width: | Height: | Size: 962 B |
|
After Width: | Height: | Size: 1.4 KiB |
|
After Width: | Height: | Size: 2.4 KiB |
|
After Width: | Height: | Size: 2.5 KiB |
|
After Width: | Height: | Size: 3.3 KiB |
|
After Width: | Height: | Size: 3.5 KiB |
|
After Width: | Height: | Size: 3.9 KiB |
|
After Width: | Height: | Size: 4.5 KiB |
|
After Width: | Height: | Size: 5.3 KiB |