diff --git a/pages-home/home/home.vue b/pages-home/home/home.vue
index ba36f70..10c14a7 100644
--- a/pages-home/home/home.vue
+++ b/pages-home/home/home.vue
@@ -22,8 +22,29 @@
+
+
+ 审批单处理全部
+
+
+ 已提交
+ 4
+
+
+
+ 未通过
+ 1
+
+
+
+ 已通过
+ 6
+
+
+
+
-
+
维修中
4
@@ -43,7 +64,7 @@
-
@@ -106,7 +127,7 @@ export default {
pageSize: 10,
total: 0,
//下来刷新状态
- isTriggered:false,
+ isTriggered:true,
orderList: [
],
defaultAvatar: require('@/static/icons/avatar.png')
@@ -138,7 +159,7 @@ export default {
/**
* 上滑加载数据
*/
- onReachBottom() {
+ onReachBottomCus() {
//判断 如果页码*页容量大于等于总条数,提示该页数据加载完毕
if (this.pageNo * this.pageSize >= this.total) {
uni.$u.toast('没有更多数据了')
@@ -382,6 +403,55 @@ export default {
}
}
+ .body-card {
+ border-radius: 6px 6px 6px 6px;
+ margin: 18px;
+ padding: 15px;
+ background: #FFFFFF;
+ .title {
+ margin-bottom: 30rpx;
+ font-weight: bold;
+ font-size: 32rpx;
+ color: #113A68;
+ box-sizing: border-box;
+ display: flex;
+ align-items: center;
+ justify-content: space-between;
+ column-gap: 20rpx;
+ }
+ .formValue {
+ flex: 1;
+ width: 0;
+ text-align: right;
+ font-weight: 500;
+ font-size: 13px;
+ color: #858BA0;
+ }
+ .title-box{
+ display: flex;
+ justify-content: space-around;
+ .title-box-item{
+ width: 33%;
+ text-align: center;
+ .titleDesc {
+ font-weight: 500;
+ font-size: 24rpx;
+ color: #858BA0;
+ }
+ .titleNumber{
+ font-weight: 500;
+ font-size: 40rpx;
+ color: #333333;
+ margin: 4px;
+ }
+ .titleImg{
+ width: 48rpx;
+ height: 48rpx;
+ }
+ }
+ }
+ }
+
.orderCount {
margin: 40rpx 32rpx;
background: #FFFFFF;
@@ -437,6 +507,7 @@ export default {
display: flex;
flex-direction: column;
row-gap: 20rpx;
+ height: calc(100vh - 500rpx);
}
}
diff --git a/pages-home/static/alow.png b/pages-home/static/alow.png
new file mode 100644
index 0000000..db054cc
Binary files /dev/null and b/pages-home/static/alow.png differ
diff --git a/pages-home/static/no.png b/pages-home/static/no.png
new file mode 100644
index 0000000..0757fd6
Binary files /dev/null and b/pages-home/static/no.png differ
diff --git a/pages-home/static/up.png b/pages-home/static/up.png
new file mode 100644
index 0000000..8ae66ae
Binary files /dev/null and b/pages-home/static/up.png differ
diff --git a/pages-order/orderDetail/orderDetail.vue b/pages-order/orderDetail/orderDetail.vue
index 717380e..2e165c9 100644
--- a/pages-order/orderDetail/orderDetail.vue
+++ b/pages-order/orderDetail/orderDetail.vue
@@ -257,8 +257,8 @@ import VNavigationBar from '@/components/VNavigationBar.vue'
import {bus} from "@/utils/eventBus";
import request from '@/utils/request';
import upload from '@/utils/upload'
-import {getOrderStatusText,formatDate,formatTimestamp,getDictTextByCodeAndValue,saveTicketsRecords,setStorageWithExpiry,getStorageWithExpiry} from "@/utils/utils";
-import {getUserInfo,setJSONData} from '@/utils/auth'
+import {getOrderStatusText,formatDate,formatTimestamp,getDictTextByCodeAndValue,saveTicketsRecords} from "@/utils/utils";
+import {getUserInfo,setJSONData,setStorageWithExpiry,getStorageWithExpiry} from '@/utils/auth'
import config from '@/config'
export default {
components: {
@@ -497,6 +497,11 @@ export default {
}else if("start" == e.item.code){
//开始施工
this.startWork(this.ticketInfo.id)
+ }else if("apply" == e.item.code){
+ //配件申请
+ uni.navigateTo({
+ url: '/pages-repair/apply/applyForm?ticketId='+this.ticketId
+ })
}
// uni.showModal({
// title: '提示',
@@ -693,37 +698,7 @@ export default {
},
//翻译配件单位
getItemUnit(unitCode){
- if(unitCode){
- let dictArray = getStorageWithExpiry("repair_unit");
- if(null==dictArray || undefined==dictArray){
- request({
- url: '/admin-api/system/dict-data/type',
- method: 'get',
- tenantIdFlag:false,
- params:{type:"repair_unit"}
- }).then((res) => {
- console.log(res)
- if (res.code == 200) {
- setStorageWithExpiry("repair_unit",res.data,3600)
- let dictObj = dictArray.find(dict => dict.value == unitCode)
- console.log(dictObj, "dictObj")
- if (dictObj) {
- return dictObj.label
- } else {
- return "未知数据"
- }
- }
- })
- }else{
- let dictObj = dictArray.find(dict => dict.value == unitCode)
- console.log(dictObj, "dictObj")
- if (dictObj) {
- return dictObj.label
- } else {
- return "未知数据"
- }
- }
- }
+ return getDictTextByCodeAndValue("repair_unit",unitCode);
},
/**
* 点击配件申请单提醒,查看相关配件
diff --git a/pages-order/orderList/orderList.vue b/pages-order/orderList/orderList.vue
index df2c2d2..9b0d463 100644
--- a/pages-order/orderList/orderList.vue
+++ b/pages-order/orderList/orderList.vue
@@ -16,7 +16,7 @@
-
@@ -88,7 +88,7 @@ export default {
/**
* 上滑加载数据
*/
- onReachBottom() {
+ onReachBottomCus() {
//判断 如果页码*页容量大于等于总条数,提示该页数据加载完毕
if (this.pageNo * this.pageSize >= this.total) {
uni.$u.toast('没有更多数据了')
diff --git a/pages-repair/apply/applyForm.vue b/pages-repair/apply/applyForm.vue
new file mode 100644
index 0000000..a69937c
--- /dev/null
+++ b/pages-repair/apply/applyForm.vue
@@ -0,0 +1,382 @@
+
+
+
+
+
+
+ 搜索
+
+
+
+
+ {{ item.name }}
+
+
+
+
+
+
+ {{ item.name }}
+
+ 单位:
+ {{ getItemUnit(item.unit) }}
+
+
+
+ {{ item.num }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/pages-repair/applyList/applyList.vue b/pages-repair/applyList/applyList.vue
index bf406a4..9c04fea 100644
--- a/pages-repair/applyList/applyList.vue
+++ b/pages-repair/applyList/applyList.vue
@@ -10,7 +10,7 @@
-
@@ -93,7 +93,7 @@
this.getOrderList()
},
getOrderList(){
-
+
}
}
}
@@ -106,21 +106,21 @@
display: flex;
flex-direction: column;
color: #333333;
-
+
.body {
flex: 1;
height: 0;
padding: 24rpx 32rpx;
overflow: auto;
}
-
+
.tabList {
background: #FFFFFF;
border-radius: 12rpx 12rpx 12rpx 12rpx;
display: flex;
align-items: center;
padding: 0 40rpx;
-
+
.tabItem {
padding: 30rpx;
flex: 1;
@@ -128,11 +128,11 @@
text-align: center;
position: relative;
font-size: 28rpx;
-
+
&.actived {
color: #0174F6;
}
-
+
.activeLine {
position: absolute;
bottom: 0;
@@ -145,7 +145,7 @@
}
}
}
-
+
.orderList {
//padding: 30rpx 0;
padding-top: 10rpx;
@@ -153,7 +153,7 @@
display: flex;
flex-direction: column;
row-gap: 20rpx;
-
+
.stateImg {
}
}
diff --git a/pages-repair/home/home.vue b/pages-repair/home/home.vue
deleted file mode 100644
index c8b9ecf..0000000
--- a/pages-repair/home/home.vue
+++ /dev/null
@@ -1,545 +0,0 @@
-
-
-
-
-
-
-
-
-
- {{ userInfo.nickname }}
- {{ userInfo.roleNames }}
-
-
-
-
-
- 审批单处理
-
-
- 已提交
- 4
-
-
-
- 未通过
- 1
-
-
-
- 已通过
- 6
-
-
-
-
-
-
-
-
-
- 维修工单
- 当前共
- {{total}}
- 项工单需要处理
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/pages-repair/orderList/orderList.vue b/pages-repair/orderList/orderList.vue
index 73a873b..5f99523 100644
--- a/pages-repair/orderList/orderList.vue
+++ b/pages-repair/orderList/orderList.vue
@@ -16,7 +16,7 @@
-
@@ -88,7 +88,7 @@ export default {
/**
* 上滑加载数据
*/
- onReachBottom() {
+ onReachBottomCus() {
//判断 如果页码*页容量大于等于总条数,提示该页数据加载完毕
if (this.pageNo * this.pageSize >= this.total) {
uni.$u.toast('没有更多数据了')
diff --git a/pages-warehouse/home/home.vue b/pages-warehouse/home/home.vue
index 6048262..456ba05 100644
--- a/pages-warehouse/home/home.vue
+++ b/pages-warehouse/home/home.vue
@@ -31,7 +31,7 @@
-
@@ -184,7 +184,7 @@ export default {
/**
* 上滑加载数据
*/
- onReachBottom() {
+ onReachBottomCus() {
//判断 如果页码*页容量大于等于总条数,提示该页数据加载完毕
if (this.pageNo * this.pageSize >= this.total) {
uni.$u.toast('没有更多数据了')
diff --git a/pages.json b/pages.json
index 294b799..3b6038f 100644
--- a/pages.json
+++ b/pages.json
@@ -129,7 +129,7 @@
"root": "pages-repair",
"pages": [
{
- "path": "home/home",
+ "path": "apply/applyForm",
"style": {
"navigationBarTitleText": ""
}
@@ -148,7 +148,7 @@
},
{
"path" : "applyList/applyList",
- "style" :
+ "style" :
{
"navigationBarTitleText" : ""
}
diff --git a/pages/detedetails/detelisthygg.vue b/pages/detedetails/detelisthygg.vue
index 78f8a43..0f39c10 100644
--- a/pages/detedetails/detelisthygg.vue
+++ b/pages/detedetails/detelisthygg.vue
@@ -33,7 +33,7 @@
-
+
@@ -60,7 +60,7 @@
-
+
@@ -117,14 +117,14 @@
})
}
},
- onReachBottom() {
+ onReachBottomCus() {
console.log(111)
if (this.pageNum >= this.totalPages) {
uni.showToast({
title: '没有下一页数据',
icon: 'none'
})
-
+
} else {
this.pageNum++
this.arrlist=[]
@@ -137,7 +137,7 @@
url: '/admin-api/appInspection/news/listGfClass',
method: 'get'
})
-
+
this.typeList = typeRes.data
},
getfab() {
@@ -152,7 +152,7 @@
getback(){
uni.navigateBack({
delta:1,
- })
+ })
},
async getlistindex(){
//行业公告分类
@@ -180,8 +180,8 @@
this.arrlist = res.rows
}
let total = res.total
- this.totalPages = Math.ceil(total / this.pageSize);
-
+ this.totalPages = Math.ceil(total / this.pageSize);
+
},
getdetails(id){
uni.navigateTo({
@@ -205,9 +205,9 @@
url:'/pages/detedetails/managelist?type=hygg'
})
}
-
+
}
-
+
}
@@ -315,7 +315,7 @@
width: 100%;
height: 100%;
}
-
+
}
.t-right{
width: 60%;
@@ -324,7 +324,7 @@
font-size: 20px;
font-weight: bold;
color: #333333;
- white-space: nowrap;
+ white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
@@ -335,10 +335,10 @@
font-size: 16px;
font-weight: bold;
color: #5e5e5e;
- white-space: nowrap;
+ white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
-
+
}
.t-zi{
font-size: 14px;
@@ -346,7 +346,7 @@
color: #666666;
overflow: hidden;
text-overflow: ellipsis;
- display: -webkit-box;
+ display: -webkit-box;
-webkit-line-clamp: 3;
-webkit-box-orient: vertical;
@@ -419,6 +419,6 @@
border-style:solid;
border-width:2px;
font-size: 15px;
-
+
}
-
\ No newline at end of file
+
diff --git a/utils/utils.js b/utils/utils.js
index 1a40c58..3191430 100644
--- a/utils/utils.js
+++ b/utils/utils.js
@@ -230,4 +230,14 @@ export function formatDate(timestamp) {
return `${year}-${month}-${day}`;
}
+/**
+ * 生成一个16位的纯数字的唯一ID
+ * 生成策略 head + 当前时间戳 + 随机数
+ * @param head 前缀
+ */
+export function createUniqueCodeByHead(head = '') {
+ const min = 100; // 最小值
+ const max = 999; // 最大值
+ return head.toString() + Date.now().toString() + Math.floor(Math.random() * (max - min + 1)) + min;
+}