From 2f0b9b40bca4fdaf8c32064957d1d456d0e007f0 Mon Sep 17 00:00:00 2001
From: caill <815519168@qq.com>
Date: Sun, 1 Sep 2024 16:21:54 +0800
Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E8=AE=A2=E5=8D=95=E5=B7=A5?=
=?UTF-8?q?=E5=BA=8F?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
common/style/layout.styl | 22 +-
pages.json | 8 +
pages/home/home.vue | 3 +-
pages/manage/mater-in-storage.vue | 73 +-
pages/manage/modify-process.vue | 116 ++
static/image/menu/RF07.png | Bin 0 -> 2265 bytes
uni_modules/uni-datetime-picker/changelog.md | 160 +++
.../uni-datetime-picker/calendar-item.vue | 177 +++
.../uni-datetime-picker/calendar.vue | 947 +++++++++++++++
.../uni-datetime-picker/i18n/en.json | 22 +
.../uni-datetime-picker/i18n/index.js | 8 +
.../uni-datetime-picker/i18n/zh-Hans.json | 22 +
.../uni-datetime-picker/i18n/zh-Hant.json | 22 +
.../uni-datetime-picker/time-picker.vue | 940 +++++++++++++++
.../uni-datetime-picker.vue | 1057 +++++++++++++++++
.../components/uni-datetime-picker/util.js | 421 +++++++
uni_modules/uni-datetime-picker/package.json | 88 ++
uni_modules/uni-datetime-picker/readme.md | 21 +
uni_modules/uni-icons/changelog.md | 2 +
.../components/uni-icons/uni-icons.uvue | 162 +--
uni_modules/uni-icons/package.json | 5 +-
utils/getData2.js | 224 +---
utils/mork2.js | 168 +--
23 files changed, 4158 insertions(+), 510 deletions(-)
create mode 100644 pages/manage/modify-process.vue
create mode 100644 static/image/menu/RF07.png
create mode 100644 uni_modules/uni-datetime-picker/changelog.md
create mode 100644 uni_modules/uni-datetime-picker/components/uni-datetime-picker/calendar-item.vue
create mode 100644 uni_modules/uni-datetime-picker/components/uni-datetime-picker/calendar.vue
create mode 100644 uni_modules/uni-datetime-picker/components/uni-datetime-picker/i18n/en.json
create mode 100644 uni_modules/uni-datetime-picker/components/uni-datetime-picker/i18n/index.js
create mode 100644 uni_modules/uni-datetime-picker/components/uni-datetime-picker/i18n/zh-Hans.json
create mode 100644 uni_modules/uni-datetime-picker/components/uni-datetime-picker/i18n/zh-Hant.json
create mode 100644 uni_modules/uni-datetime-picker/components/uni-datetime-picker/time-picker.vue
create mode 100644 uni_modules/uni-datetime-picker/components/uni-datetime-picker/uni-datetime-picker.vue
create mode 100644 uni_modules/uni-datetime-picker/components/uni-datetime-picker/util.js
create mode 100644 uni_modules/uni-datetime-picker/package.json
create mode 100644 uni_modules/uni-datetime-picker/readme.md
diff --git a/common/style/layout.styl b/common/style/layout.styl
index de49991..ae10184 100644
--- a/common/style/layout.styl
+++ b/common/style/layout.styl
@@ -144,12 +144,12 @@ uni-button:after {
.slide_new table td:first-child{
position: sticky;
left: 0;
- z-index: 101;
+ z-index: 31;
}
.slide_new table th:first-child{
position: sticky;
left: 0;
- z-index: 102;
+ z-index: 32;
}
.slide_new table thead tr th {
position: sticky;
@@ -161,7 +161,7 @@ uni-button:after {
color: #7d7d7d;
background-color: #dcdfea;
font-weight: bold;
- z-index: 100;
+ z-index: 30;
}
.slide_new table tbody tr td {
font-size: 28rpx;
@@ -178,15 +178,23 @@ uni-button:after {
background: #fff;
}
.slide_new table tbody tr td .td_input {
- width: 150rpx;
+ width: 230rpx;
font-size: 28rpx;
color: #305fbf;
- line-height: 30rpx;
+ line-height: 58rpx;
height: 58rpx;
- padding: 14rpx;
+ padding: 0 10rpx;
border: 1px solid #889dc7;
box-shadow: 0 0 0 2px rgba(136, 157, 199,.2);
border-radius: 10rpx;
+ margin: 0 auto;
+}
+.slide_new table tbody tr td .td_select {
+ width: 230rpx;
+ font-size: 28rpx;
+ color: #305fbf;
+ line-height: 58rpx;
+ margin: 0 auto;
}
.slide_new table thead tr th.fontcol1,.slide_new table tbody tr td.fontcol1 {
color: #4e6ef2;
@@ -266,7 +274,7 @@ uni-button:after {
bottom: 0;
left: 0;
width: 100%;
- z-index: 200;
+ z-index: 30;
background-color: #fff;
padding: 14rpx;
box-shadow: 0 0 20rpx 0 rgba(160,160,160,0.7);
diff --git a/pages.json b/pages.json
index 28c4be1..a23ec36 100644
--- a/pages.json
+++ b/pages.json
@@ -66,6 +66,14 @@
}
}
+ ,{
+ "path" : "pages/manage/modify-process",
+ "style" :
+ {
+ "navigationStyle": "custom"
+ }
+
+ }
],
"globalStyle": {
// "pageOrientation": "landscape",
diff --git a/pages/home/home.vue b/pages/home/home.vue
index 1469d64..fc3c6fd 100644
--- a/pages/home/home.vue
+++ b/pages/home/home.vue
@@ -37,7 +37,8 @@
{title: '外协区空料架送回', icon: 'RF05', path: '/pages/manage/empty-material-racks-back'},
{title: '物料转运', icon: 'RF02', path: '/pages/manage/material-transfer'},
{title: '区域锁定', icon: 'RF06', path: '/pages/manage/area-lock'},
- {title: '补空框', icon: 'RF04', path: '/pages/manage/fill-tray'}
+ {title: '补空框', icon: 'RF04', path: '/pages/manage/fill-tray'},
+ {title: '修改订单工序', icon: 'RF07', path: '/pages/manage/modify-process'}
],
show: false,
secM: []
diff --git a/pages/manage/mater-in-storage.vue b/pages/manage/mater-in-storage.vue
index 54e0f6c..913ad07 100644
--- a/pages/manage/mater-in-storage.vue
+++ b/pages/manage/mater-in-storage.vue
@@ -23,43 +23,41 @@
/>
-
-
- 订单号
-
-
-
-
-
-
-
- 物料号
-
-
-
-
-
-
-
- 物料数量
-
-
-
-
-
目的地
-
+
+
+
+
+
+
-
+
@@ -67,7 +65,7 @@
+
+
diff --git a/static/image/menu/RF07.png b/static/image/menu/RF07.png
new file mode 100644
index 0000000000000000000000000000000000000000..ab42ca3b85373546cb4034a8aaffe47af49e9640
GIT binary patch
literal 2265
zcmaJ@c~nzp77wx`i?oP>ERUenidl(}1Og@@K)|p|8J5wIJV*{?F?kR`7J);dfV6Z(
z1&M66MOj1y&OxS##Tro{z)%4NDI-D(NKO&8Vk`4v#m*nYymQ|BzI)I8{qB11d0zwv
z`kEM78zB$~6Q-YcD11g~UIRV&OKhNSgAXf+5ebEf;vpGZ0wSnfQ5*;`1?&Vc6l8PL
zPV|Ew2!!^2et0Al$vQ&jhy-Z1#s-}#5W{E$!ow?7%;qG55D*6@@P!nly89*);BzU+
z&knJ$EHNGA@%_>zU|4!!I43=kL*gR6JOPhXGE5))Z6F1FIb`=c@QKfV=ywA3@vj(izEpc9En82VDT6{9tB&Vq-jEkor)4l
z9XA=gK`BSV7ejoJ5YRBP<3!021qny`X9@!G2U?-@eVO2bVN%&*3=WOeq_k`QpktAFsO4_VqFi!-Dq&$%r
zpwl%~a|8CX*c`r4qx|$8ip3%`g;Izu*wb)87AT_ofP-Af%T`kMHK>TT307(#om*qdkeqUKch*fvhqgg
zoTJ}%B+IC%SFv)Vx#mRy&8V%>2gCmHKiyKd5gp$tcFoPUfv7MuR+a(9{FsHfgV_mAW`uZs>d0dcvdL%?y_+aO`
z6CPTx1D=7;#&cZ9bs8BLX79%Bb+1KM6Y4g?$p-7D)>W7mPPy`Jl=AR}qgm(2Tje^G
z+XXGxe!#RQtBfWb;oYQT3|@J0SY<
z@m(~xRjsw;k%@L-cJf-EJiWRZSF^7-mbtiL_`-DV?r?%-&iwNjePuFHNFS`ri68AU
zH7SXP^Bqnyj#3Y`8m8ZRqVCc?FeDpp-rY)=JKp>Cz}w^Fw_5se+Z{`@9z7wh<7^Lm
z88pu}lU8|4pjx%Vb*aM+8Bx_vLx#RoR-mJus&dSkQPwW
zhMxLKIc%rmsM67%P2$B{`{RjmogMX^Lnalawj1L+9t}v?iVbj#()jo2Lde;${@_sQ
z#*q8(?&{xe=G$>?SJnUecCnkPpGmC}r4xTSwXZwc+5f8*s&$|^k%1qM_zZO$*HGme
z(KUZH&(2qw|B^m?@al65sO0ehl(D2(ct_ba;4mKYWo$F)WI|U#S!={
zhd!I2B{O2rT6ytMaNvB#VsG+Fu)?32t=hipEz-qTj~+c~L1vVOh0ISEO~Z93W0ulFX{#_enL+~J|eOycCr
zpS3M`Zwi|+kWS^O?(z|bjpq8L!W$)0+|!VWpox3S!o3&HPBl2Hu63rarxdkT_m9R_
zjhU}`m;3W(?vU)wQs`$ryCQstN6mcIlaI@50zD=wXu^(->-XiaBJ)>%6DV&kE2^
zaT@v2HLCkn=P~NlQ&TafQ7xzLze;svQrwr10QXh%l$pp8mQFdD+tPu-rTgW->b47Kjs<3mXJ2PG-_00o)nClYYfG?=VW*vTU7ne}
zGj6 px
+- 修复 范围选择时清空返回值不合理的bug,['', ''] -> []
+## 2.0.8(2021-07-07)
+- 新增 日期时间显示框支持插槽
+## 2.0.7(2021-07-01)
+- 优化 添加 uni-icons 依赖
+## 2.0.6(2021-05-22)
+- 修复 图标在小程序上不显示的Bug
+- 优化 重命名引用组件,避免潜在组件命名冲突
+## 2.0.5(2021-05-20)
+- 优化 代码目录扁平化
+## 2.0.4(2021-05-12)
+- 新增 组件示例地址
+## 2.0.3(2021-05-10)
+- 修复 ios 下不识别 '-' 日期格式的Bug
+- 优化 pc 下弹出层添加边框和阴影
+## 2.0.2(2021-05-08)
+- 修复 在 admin 中获取弹出层定位错误的bug
+## 2.0.1(2021-05-08)
+- 修复 type 属性向下兼容,默认值从 date 变更为 datetime
+## 2.0.0(2021-04-30)
+- 支持日历形式的日期+时间的范围选择
+ > 注意:此版本不向后兼容,不再支持单独时间选择(type=time)及相关的 hide-second 属性(时间选可使用内置组件 picker)
+## 1.0.6(2021-03-18)
+- 新增 hide-second 属性,时间支持仅选择时、分
+- 修复 选择跟显示的日期不一样的Bug
+- 修复 chang事件触发2次的Bug
+- 修复 分、秒 end 范围错误的Bug
+- 优化 更好的 nvue 适配
diff --git a/uni_modules/uni-datetime-picker/components/uni-datetime-picker/calendar-item.vue b/uni_modules/uni-datetime-picker/components/uni-datetime-picker/calendar-item.vue
new file mode 100644
index 0000000..8f3c461
--- /dev/null
+++ b/uni_modules/uni-datetime-picker/components/uni-datetime-picker/calendar-item.vue
@@ -0,0 +1,177 @@
+
+
+
+
+ {{weeks.date}}
+
+
+
+
+
+
+
+
diff --git a/uni_modules/uni-datetime-picker/components/uni-datetime-picker/calendar.vue b/uni_modules/uni-datetime-picker/components/uni-datetime-picker/calendar.vue
new file mode 100644
index 0000000..e6fe594
--- /dev/null
+++ b/uni_modules/uni-datetime-picker/components/uni-datetime-picker/calendar.vue
@@ -0,0 +1,947 @@
+
+
+
+
+
+
+
+
+
+
+ {{nowDate.month}}
+
+
+
+
+ {{SUNText}}
+
+
+ {{MONText}}
+
+
+ {{TUEText}}
+
+
+ {{WEDText}}
+
+
+ {{THUText}}
+
+
+ {{FRIText}}
+
+
+ {{SATText}}
+
+
+
+
+
+
+
+
+
+
+
+
+ {{tempSingleDate ? tempSingleDate : selectDateText}}
+
+
+
+
+
+
+ {{tempRange.before ? tempRange.before : startDateText}}
+
+
+
+
+
+
+
+
+ {{tempRange.after ? tempRange.after : endDateText}}
+
+
+
+
+
+
+ {{confirmText}}
+
+
+
+
+
+
+
+
diff --git a/uni_modules/uni-datetime-picker/components/uni-datetime-picker/i18n/en.json b/uni_modules/uni-datetime-picker/components/uni-datetime-picker/i18n/en.json
new file mode 100644
index 0000000..56cd0a6
--- /dev/null
+++ b/uni_modules/uni-datetime-picker/components/uni-datetime-picker/i18n/en.json
@@ -0,0 +1,22 @@
+{
+ "uni-datetime-picker.selectDate": "select date",
+ "uni-datetime-picker.selectTime": "select time",
+ "uni-datetime-picker.selectDateTime": "select date and time",
+ "uni-datetime-picker.startDate": "start date",
+ "uni-datetime-picker.endDate": "end date",
+ "uni-datetime-picker.startTime": "start time",
+ "uni-datetime-picker.endTime": "end time",
+ "uni-datetime-picker.ok": "ok",
+ "uni-datetime-picker.clear": "clear",
+ "uni-datetime-picker.cancel": "cancel",
+ "uni-datetime-picker.year": "-",
+ "uni-datetime-picker.month": "",
+ "uni-calender.MON": "MON",
+ "uni-calender.TUE": "TUE",
+ "uni-calender.WED": "WED",
+ "uni-calender.THU": "THU",
+ "uni-calender.FRI": "FRI",
+ "uni-calender.SAT": "SAT",
+ "uni-calender.SUN": "SUN",
+ "uni-calender.confirm": "confirm"
+}
diff --git a/uni_modules/uni-datetime-picker/components/uni-datetime-picker/i18n/index.js b/uni_modules/uni-datetime-picker/components/uni-datetime-picker/i18n/index.js
new file mode 100644
index 0000000..fa8f0f3
--- /dev/null
+++ b/uni_modules/uni-datetime-picker/components/uni-datetime-picker/i18n/index.js
@@ -0,0 +1,8 @@
+import en from './en.json'
+import zhHans from './zh-Hans.json'
+import zhHant from './zh-Hant.json'
+export default {
+ en,
+ 'zh-Hans': zhHans,
+ 'zh-Hant': zhHant
+}
diff --git a/uni_modules/uni-datetime-picker/components/uni-datetime-picker/i18n/zh-Hans.json b/uni_modules/uni-datetime-picker/components/uni-datetime-picker/i18n/zh-Hans.json
new file mode 100644
index 0000000..d2df5e7
--- /dev/null
+++ b/uni_modules/uni-datetime-picker/components/uni-datetime-picker/i18n/zh-Hans.json
@@ -0,0 +1,22 @@
+{
+ "uni-datetime-picker.selectDate": "选择日期",
+ "uni-datetime-picker.selectTime": "选择时间",
+ "uni-datetime-picker.selectDateTime": "选择日期时间",
+ "uni-datetime-picker.startDate": "开始日期",
+ "uni-datetime-picker.endDate": "结束日期",
+ "uni-datetime-picker.startTime": "开始时间",
+ "uni-datetime-picker.endTime": "结束时间",
+ "uni-datetime-picker.ok": "确定",
+ "uni-datetime-picker.clear": "清除",
+ "uni-datetime-picker.cancel": "取消",
+ "uni-datetime-picker.year": "年",
+ "uni-datetime-picker.month": "月",
+ "uni-calender.SUN": "日",
+ "uni-calender.MON": "一",
+ "uni-calender.TUE": "二",
+ "uni-calender.WED": "三",
+ "uni-calender.THU": "四",
+ "uni-calender.FRI": "五",
+ "uni-calender.SAT": "六",
+ "uni-calender.confirm": "确认"
+}
\ No newline at end of file
diff --git a/uni_modules/uni-datetime-picker/components/uni-datetime-picker/i18n/zh-Hant.json b/uni_modules/uni-datetime-picker/components/uni-datetime-picker/i18n/zh-Hant.json
new file mode 100644
index 0000000..d23fa3c
--- /dev/null
+++ b/uni_modules/uni-datetime-picker/components/uni-datetime-picker/i18n/zh-Hant.json
@@ -0,0 +1,22 @@
+{
+ "uni-datetime-picker.selectDate": "選擇日期",
+ "uni-datetime-picker.selectTime": "選擇時間",
+ "uni-datetime-picker.selectDateTime": "選擇日期時間",
+ "uni-datetime-picker.startDate": "開始日期",
+ "uni-datetime-picker.endDate": "結束日期",
+ "uni-datetime-picker.startTime": "開始时间",
+ "uni-datetime-picker.endTime": "結束时间",
+ "uni-datetime-picker.ok": "確定",
+ "uni-datetime-picker.clear": "清除",
+ "uni-datetime-picker.cancel": "取消",
+ "uni-datetime-picker.year": "年",
+ "uni-datetime-picker.month": "月",
+ "uni-calender.SUN": "日",
+ "uni-calender.MON": "一",
+ "uni-calender.TUE": "二",
+ "uni-calender.WED": "三",
+ "uni-calender.THU": "四",
+ "uni-calender.FRI": "五",
+ "uni-calender.SAT": "六",
+ "uni-calender.confirm": "確認"
+}
\ No newline at end of file
diff --git a/uni_modules/uni-datetime-picker/components/uni-datetime-picker/time-picker.vue b/uni_modules/uni-datetime-picker/components/uni-datetime-picker/time-picker.vue
new file mode 100644
index 0000000..8716d42
--- /dev/null
+++ b/uni_modules/uni-datetime-picker/components/uni-datetime-picker/time-picker.vue
@@ -0,0 +1,940 @@
+
+
+
+
+
+ {{time}}
+
+ {{selectTimeText}}
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/uni_modules/uni-datetime-picker/components/uni-datetime-picker/uni-datetime-picker.vue b/uni_modules/uni-datetime-picker/components/uni-datetime-picker/uni-datetime-picker.vue
new file mode 100644
index 0000000..11fc45a
--- /dev/null
+++ b/uni_modules/uni-datetime-picker/components/uni-datetime-picker/uni-datetime-picker.vue
@@ -0,0 +1,1057 @@
+
+
+
+
+
+
+
+ {{ displayValue || singlePlaceholderText }}
+
+
+
+
+ {{ displayRangeValue.startDate || startPlaceholderText }}
+
+ {{rangeSeparator}}
+
+ {{ displayRangeValue.endDate || endPlaceholderText }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/uni_modules/uni-datetime-picker/components/uni-datetime-picker/util.js b/uni_modules/uni-datetime-picker/components/uni-datetime-picker/util.js
new file mode 100644
index 0000000..acf7e4b
--- /dev/null
+++ b/uni_modules/uni-datetime-picker/components/uni-datetime-picker/util.js
@@ -0,0 +1,421 @@
+class Calendar {
+ constructor({
+ selected,
+ startDate,
+ endDate,
+ range,
+ } = {}) {
+ // 当前日期
+ this.date = this.getDateObj(new Date()) // 当前初入日期
+ // 打点信息
+ this.selected = selected || [];
+ // 起始时间
+ this.startDate = startDate
+ // 终止时间
+ this.endDate = endDate
+ // 是否范围选择
+ this.range = range
+ // 多选状态
+ this.cleanMultipleStatus()
+ // 每周日期
+ this.weeks = {}
+ this.lastHover = false
+ }
+ /**
+ * 设置日期
+ * @param {Object} date
+ */
+ setDate(date) {
+ const selectDate = this.getDateObj(date)
+ this.getWeeks(selectDate.fullDate)
+ }
+
+ /**
+ * 清理多选状态
+ */
+ cleanMultipleStatus() {
+ this.multipleStatus = {
+ before: '',
+ after: '',
+ data: []
+ }
+ }
+
+ setStartDate(startDate) {
+ this.startDate = startDate
+ }
+
+ setEndDate(endDate) {
+ this.endDate = endDate
+ }
+
+ getPreMonthObj(date) {
+ date = fixIosDateFormat(date)
+ date = new Date(date)
+
+ const oldMonth = date.getMonth()
+ date.setMonth(oldMonth - 1)
+ const newMonth = date.getMonth()
+ if (oldMonth !== 0 && newMonth - oldMonth === 0) {
+ date.setMonth(newMonth - 1)
+ }
+ return this.getDateObj(date)
+ }
+ getNextMonthObj(date) {
+ date = fixIosDateFormat(date)
+ date = new Date(date)
+
+ const oldMonth = date.getMonth()
+ date.setMonth(oldMonth + 1)
+ const newMonth = date.getMonth()
+ if (newMonth - oldMonth > 1) {
+ date.setMonth(newMonth - 1)
+ }
+ return this.getDateObj(date)
+ }
+
+ /**
+ * 获取指定格式Date对象
+ */
+ getDateObj(date) {
+ date = fixIosDateFormat(date)
+ date = new Date(date)
+
+ return {
+ fullDate: getDate(date),
+ year: date.getFullYear(),
+ month: addZero(date.getMonth() + 1),
+ date: addZero(date.getDate()),
+ day: date.getDay()
+ }
+ }
+
+ /**
+ * 获取上一个月日期集合
+ */
+ getPreMonthDays(amount, dateObj) {
+ const result = []
+ for (let i = amount - 1; i >= 0; i--) {
+ const month = dateObj.month - 1
+ result.push({
+ date: new Date(dateObj.year, month, -i).getDate(),
+ month,
+ disable: true
+ })
+ }
+ return result
+ }
+ /**
+ * 获取本月日期集合
+ */
+ getCurrentMonthDays(amount, dateObj) {
+ const result = []
+ const fullDate = this.date.fullDate
+ for (let i = 1; i <= amount; i++) {
+ const currentDate = `${dateObj.year}-${dateObj.month}-${addZero(i)}`
+ const isToday = fullDate === currentDate
+ // 获取打点信息
+ const info = this.selected && this.selected.find((item) => {
+ if (this.dateEqual(currentDate, item.date)) {
+ return item
+ }
+ })
+
+ // 日期禁用
+ let disableBefore = true
+ let disableAfter = true
+ if (this.startDate) {
+ disableBefore = dateCompare(this.startDate, currentDate)
+ }
+
+ if (this.endDate) {
+ disableAfter = dateCompare(currentDate, this.endDate)
+ }
+
+ let multiples = this.multipleStatus.data
+ let multiplesStatus = -1
+ if (this.range && multiples) {
+ multiplesStatus = multiples.findIndex((item) => {
+ return this.dateEqual(item, currentDate)
+ })
+ }
+ const checked = multiplesStatus !== -1
+
+ result.push({
+ fullDate: currentDate,
+ year: dateObj.year,
+ date: i,
+ multiple: this.range ? checked : false,
+ beforeMultiple: this.isLogicBefore(currentDate, this.multipleStatus.before, this.multipleStatus.after),
+ afterMultiple: this.isLogicAfter(currentDate, this.multipleStatus.before, this.multipleStatus.after),
+ month: dateObj.month,
+ disable: (this.startDate && !dateCompare(this.startDate, currentDate)) || (this.endDate && !dateCompare(
+ currentDate, this.endDate)),
+ isToday,
+ userChecked: false,
+ extraInfo: info
+ })
+ }
+ return result
+ }
+ /**
+ * 获取下一个月日期集合
+ */
+ _getNextMonthDays(amount, dateObj) {
+ const result = []
+ const month = dateObj.month + 1
+ for (let i = 1; i <= amount; i++) {
+ result.push({
+ date: i,
+ month,
+ disable: true
+ })
+ }
+ return result
+ }
+
+ /**
+ * 获取当前日期详情
+ * @param {Object} date
+ */
+ getInfo(date) {
+ if (!date) {
+ date = new Date()
+ }
+
+ return this.calendar.find(item => item.fullDate === this.getDateObj(date).fullDate)
+ }
+
+ /**
+ * 比较时间是否相等
+ */
+ dateEqual(before, after) {
+ before = new Date(fixIosDateFormat(before))
+ after = new Date(fixIosDateFormat(after))
+ return before.valueOf() === after.valueOf()
+ }
+
+ /**
+ * 比较真实起始日期
+ */
+
+ isLogicBefore(currentDate, before, after) {
+ let logicBefore = before
+ if (before && after) {
+ logicBefore = dateCompare(before, after) ? before : after
+ }
+ return this.dateEqual(logicBefore, currentDate)
+ }
+
+ isLogicAfter(currentDate, before, after) {
+ let logicAfter = after
+ if (before && after) {
+ logicAfter = dateCompare(before, after) ? after : before
+ }
+ return this.dateEqual(logicAfter, currentDate)
+ }
+
+ /**
+ * 获取日期范围内所有日期
+ * @param {Object} begin
+ * @param {Object} end
+ */
+ geDateAll(begin, end) {
+ var arr = []
+ var ab = begin.split('-')
+ var ae = end.split('-')
+ var db = new Date()
+ db.setFullYear(ab[0], ab[1] - 1, ab[2])
+ var de = new Date()
+ de.setFullYear(ae[0], ae[1] - 1, ae[2])
+ var unixDb = db.getTime() - 24 * 60 * 60 * 1000
+ var unixDe = de.getTime() - 24 * 60 * 60 * 1000
+ for (var k = unixDb; k <= unixDe;) {
+ k = k + 24 * 60 * 60 * 1000
+ arr.push(this.getDateObj(new Date(parseInt(k))).fullDate)
+ }
+ return arr
+ }
+
+ /**
+ * 获取多选状态
+ */
+ setMultiple(fullDate) {
+ if (!this.range) return
+
+ let {
+ before,
+ after
+ } = this.multipleStatus
+ if (before && after) {
+ if (!this.lastHover) {
+ this.lastHover = true
+ return
+ }
+ this.multipleStatus.before = fullDate
+ this.multipleStatus.after = ''
+ this.multipleStatus.data = []
+ this.multipleStatus.fulldate = ''
+ this.lastHover = false
+ } else {
+ if (!before) {
+ this.multipleStatus.before = fullDate
+ this.multipleStatus.after = undefined;
+ this.lastHover = false
+ } else {
+ this.multipleStatus.after = fullDate
+ if (dateCompare(this.multipleStatus.before, this.multipleStatus.after)) {
+ this.multipleStatus.data = this.geDateAll(this.multipleStatus.before, this.multipleStatus
+ .after);
+ } else {
+ this.multipleStatus.data = this.geDateAll(this.multipleStatus.after, this.multipleStatus
+ .before);
+ }
+ this.lastHover = true
+ }
+ }
+ this.getWeeks(fullDate)
+ }
+
+ /**
+ * 鼠标 hover 更新多选状态
+ */
+ setHoverMultiple(fullDate) {
+ //抖音小程序点击会触发hover事件,需要避免一下
+ // #ifndef MP-TOUTIAO
+ if (!this.range || this.lastHover) return
+ const {
+ before
+ } = this.multipleStatus
+
+ if (!before) {
+ this.multipleStatus.before = fullDate
+ } else {
+ this.multipleStatus.after = fullDate
+ if (dateCompare(this.multipleStatus.before, this.multipleStatus.after)) {
+ this.multipleStatus.data = this.geDateAll(this.multipleStatus.before, this.multipleStatus.after);
+ } else {
+ this.multipleStatus.data = this.geDateAll(this.multipleStatus.after, this.multipleStatus.before);
+ }
+ }
+ this.getWeeks(fullDate)
+ // #endif
+
+ }
+
+ /**
+ * 更新默认值多选状态
+ */
+ setDefaultMultiple(before, after) {
+ this.multipleStatus.before = before
+ this.multipleStatus.after = after
+ if (before && after) {
+ if (dateCompare(before, after)) {
+ this.multipleStatus.data = this.geDateAll(before, after);
+ this.getWeeks(after)
+ } else {
+ this.multipleStatus.data = this.geDateAll(after, before);
+ this.getWeeks(before)
+ }
+ }
+ }
+
+ /**
+ * 获取每周数据
+ * @param {Object} dateData
+ */
+ getWeeks(dateData) {
+ const {
+ year,
+ month,
+ } = this.getDateObj(dateData)
+
+ const preMonthDayAmount = new Date(year, month - 1, 1).getDay()
+ const preMonthDays = this.getPreMonthDays(preMonthDayAmount, this.getDateObj(dateData))
+
+ const currentMonthDayAmount = new Date(year, month, 0).getDate()
+ const currentMonthDays = this.getCurrentMonthDays(currentMonthDayAmount, this.getDateObj(dateData))
+
+ const nextMonthDayAmount = 42 - preMonthDayAmount - currentMonthDayAmount
+ const nextMonthDays = this._getNextMonthDays(nextMonthDayAmount, this.getDateObj(dateData))
+
+ const calendarDays = [...preMonthDays, ...currentMonthDays, ...nextMonthDays]
+
+ const weeks = new Array(6)
+ for (let i = 0; i < calendarDays.length; i++) {
+ const index = Math.floor(i / 7)
+ if (!weeks[index]) {
+ weeks[index] = new Array(7)
+ }
+ weeks[index][i % 7] = calendarDays[i]
+ }
+
+ this.calendar = calendarDays
+ this.weeks = weeks
+ }
+}
+
+function getDateTime(date, hideSecond) {
+ return `${getDate(date)} ${getTime(date, hideSecond)}`
+}
+
+function getDate(date) {
+ date = fixIosDateFormat(date)
+ date = new Date(date)
+ const year = date.getFullYear()
+ const month = date.getMonth() + 1
+ const day = date.getDate()
+ return `${year}-${addZero(month)}-${addZero(day)}`
+}
+
+function getTime(date, hideSecond) {
+ date = fixIosDateFormat(date)
+ date = new Date(date)
+ const hour = date.getHours()
+ const minute = date.getMinutes()
+ const second = date.getSeconds()
+ return hideSecond ? `${addZero(hour)}:${addZero(minute)}` : `${addZero(hour)}:${addZero(minute)}:${addZero(second)}`
+}
+
+function addZero(num) {
+ if (num < 10) {
+ num = `0${num}`
+ }
+ return num
+}
+
+function getDefaultSecond(hideSecond) {
+ return hideSecond ? '00:00' : '00:00:00'
+}
+
+function dateCompare(startDate, endDate) {
+ startDate = new Date(fixIosDateFormat(startDate))
+ endDate = new Date(fixIosDateFormat(endDate))
+ return startDate <= endDate
+}
+
+function checkDate(date) {
+ const dateReg = /((19|20)\d{2})(-|\/)\d{1,2}(-|\/)\d{1,2}/g
+ return date.match(dateReg)
+}
+//ios低版本15及以下,无法匹配 没有 ’秒‘ 时的情况,所以需要在末尾 秒 加上 问号
+const dateTimeReg = /^\d{4}-(0?[1-9]|1[012])-(0?[1-9]|[12][0-9]|3[01])( [0-5]?[0-9]:[0-5]?[0-9](:[0-5]?[0-9])?)?$/;
+
+function fixIosDateFormat(value) {
+ if (typeof value === 'string' && dateTimeReg.test(value)) {
+ value = value.replace(/-/g, '/')
+ }
+ return value
+}
+
+export {
+ Calendar,
+ getDateTime,
+ getDate,
+ getTime,
+ addZero,
+ getDefaultSecond,
+ dateCompare,
+ checkDate,
+ fixIosDateFormat
+}
diff --git a/uni_modules/uni-datetime-picker/package.json b/uni_modules/uni-datetime-picker/package.json
new file mode 100644
index 0000000..4d1b05c
--- /dev/null
+++ b/uni_modules/uni-datetime-picker/package.json
@@ -0,0 +1,88 @@
+{
+ "id": "uni-datetime-picker",
+ "displayName": "uni-datetime-picker 日期选择器",
+ "version": "2.2.34",
+ "description": "uni-datetime-picker 日期时间选择器,支持日历,支持范围选择",
+ "keywords": [
+ "uni-datetime-picker",
+ "uni-ui",
+ "uniui",
+ "日期时间选择器",
+ "日期时间"
+],
+ "repository": "https://github.com/dcloudio/uni-ui",
+ "engines": {
+ "HBuilderX": ""
+ },
+ "directories": {
+ "example": "../../temps/example_temps"
+ },
+"dcloudext": {
+ "sale": {
+ "regular": {
+ "price": "0.00"
+ },
+ "sourcecode": {
+ "price": "0.00"
+ }
+ },
+ "contact": {
+ "qq": ""
+ },
+ "declaration": {
+ "ads": "无",
+ "data": "无",
+ "permissions": "无"
+ },
+ "npmurl": "https://www.npmjs.com/package/@dcloudio/uni-ui",
+ "type": "component-vue"
+ },
+ "uni_modules": {
+ "dependencies": [
+ "uni-scss",
+ "uni-icons"
+ ],
+ "encrypt": [],
+ "platforms": {
+ "cloud": {
+ "tcb": "y",
+ "aliyun": "y",
+ "alipay": "n"
+ },
+ "client": {
+ "App": {
+ "app-vue": "y",
+ "app-nvue": "n"
+ },
+ "H5-mobile": {
+ "Safari": "y",
+ "Android Browser": "y",
+ "微信浏览器(Android)": "y",
+ "QQ浏览器(Android)": "y"
+ },
+ "H5-pc": {
+ "Chrome": "y",
+ "IE": "y",
+ "Edge": "y",
+ "Firefox": "y",
+ "Safari": "y"
+ },
+ "小程序": {
+ "微信": "y",
+ "阿里": "y",
+ "百度": "y",
+ "字节跳动": "y",
+ "QQ": "y"
+ },
+ "快应用": {
+ "华为": "u",
+ "联盟": "u"
+ },
+ "Vue": {
+ "vue2": "y",
+ "vue3": "y"
+ }
+ }
+ }
+ }
+}
diff --git a/uni_modules/uni-datetime-picker/readme.md b/uni_modules/uni-datetime-picker/readme.md
new file mode 100644
index 0000000..162fbef
--- /dev/null
+++ b/uni_modules/uni-datetime-picker/readme.md
@@ -0,0 +1,21 @@
+
+
+> `重要通知:组件升级更新 2.0.0 后,支持日期+时间范围选择,组件 ui 将使用日历选择日期,ui 变化较大,同时支持 PC 和 移动端。此版本不向后兼容,不再支持单独的时间选择(type=time)及相关的 hide-second 属性(时间选可使用内置组件 picker)。若仍需使用旧版本,可在插件市场下载*非uni_modules版本*,旧版本将不再维护`
+
+## DatetimePicker 时间选择器
+
+> **组件名:uni-datetime-picker**
+> 代码块: `uDatetimePicker`
+
+
+该组件的优势是,支持**时间戳**输入和输出(起始时间、终止时间也支持时间戳),可**同时选择**日期和时间。
+
+若只是需要单独选择日期和时间,不需要时间戳输入和输出,可使用原生的 picker 组件。
+
+**_点击 picker 默认值规则:_**
+
+- 若设置初始值 value, 会显示在 picker 显示框中
+- 若无初始值 value,则初始值 value 为当前本地时间 Date.now(), 但不会显示在 picker 显示框中
+
+### [查看文档](https://uniapp.dcloud.io/component/uniui/uni-datetime-picker)
+#### 如使用过程中有任何问题,或者您对uni-ui有一些好的建议,欢迎加入 uni-ui 交流群:871950839
\ No newline at end of file
diff --git a/uni_modules/uni-icons/changelog.md b/uni_modules/uni-icons/changelog.md
index 620ab02..0261131 100644
--- a/uni_modules/uni-icons/changelog.md
+++ b/uni_modules/uni-icons/changelog.md
@@ -1,3 +1,5 @@
+## 2.0.10(2024-06-07)
+- 优化 uni-app x 中,size 属性的类型
## 2.0.9(2024-01-12)
fix: 修复图标大小默认值错误的问题
## 2.0.8(2023-12-14)
diff --git a/uni_modules/uni-icons/components/uni-icons/uni-icons.uvue b/uni_modules/uni-icons/components/uni-icons/uni-icons.uvue
index a975b4a..ce307c1 100644
--- a/uni_modules/uni-icons/components/uni-icons/uni-icons.uvue
+++ b/uni_modules/uni-icons/components/uni-icons/uni-icons.uvue
@@ -1,91 +1,91 @@
-
- {{unicode}}
-
+
+ {{unicode}}
+
diff --git a/uni_modules/uni-icons/package.json b/uni_modules/uni-icons/package.json
index 397be83..6b681b4 100644
--- a/uni_modules/uni-icons/package.json
+++ b/uni_modules/uni-icons/package.json
@@ -1,7 +1,7 @@
{
"id": "uni-icons",
"displayName": "uni-icons 图标",
- "version": "2.0.9",
+ "version": "2.0.10",
"description": "图标组件,用于展示移动端常见的图标,可自定义颜色、大小。",
"keywords": [
"uni-ui",
@@ -42,7 +42,8 @@
"platforms": {
"cloud": {
"tcb": "y",
- "aliyun": "y"
+ "aliyun": "y",
+ "alipay": "n"
},
"client": {
"App": {
diff --git a/utils/getData2.js b/utils/getData2.js
index effb29f..b92160b 100644
--- a/utils/getData2.js
+++ b/utils/getData2.js
@@ -55,225 +55,17 @@ export const handheldStorehouse = (code, type) => request({
url:'api/handheld/storehouse',
data: {device_code: code, vehicle_type: type}
})
-//
// 工序下料
-export const handheldGetRegionCode = (code) => request({
- url:'api/handheld/getRegionCode',
- data: {orderCode: code}
-})
+// export const handheldGetRegionCode = (code) => request({
+// url:'api/handheld/getRegionCode',
+// data: {orderCode: code}
+// })
export const handheldBlanking = (code, rcode, vcode, material) => request({
url:'api/handheld/blanking',
data: {device_code: code, region_code: rcode, vehicle_code: vcode, material: material}
})
-
-/**
- * 空托盘出库
- */
-// 1.1获取载具类型
-export const getVehicleType = () => request({
- url:'api/pda/group/getVehicleType',
- data: {}
-})
-
-// 1.2空托盘出库确认
-export const callEmptyVehicle = (type, code) => request({
- url:'api/pda/callEmptyVehicle',
- data: {
- vehicle_type: type,
- point_code: code
- }
-})
-/**
- * 空托盘入库
- */
-// 1.1空托盘入库确认
-export const emptyInStore = (type, vcode, code) => request({
- url:'api/pda/emptyInStore',
- data: {
- vehicle_type: type,
- vehicle_code: vcode,
- point_code: code
- }
-})
-/**
- * 组盘入库
- */
-// 1.1获取物料信息
-export const queryMaterial = () => request({
- url:'api/pda/queryMaterial',
- data: {}
-})
-
-// 查询已配盘的组盘信息
-export const queryExistGroup = () => request({
- url:'api/pda/queryExistGroup',
- data: {}
-})
-
-// 组盘
-export const groupManual = (vtype, vcode, pcode, mid, mcode, qty, isl) => request({
- url:'api/pda/group/manual',
- data: {
- vehicle_type: vtype,
- vehicle_code: vcode,
- point_code: pcode,
- material_id: mid,
- material_code: mcode,
- material_qty: qty,
- is_link: isl
- }
-})
-//获取待配盘信息
-export const queryVehicleGroup = () => request({
- url:'api/pda/queryVehicleGroup',
- data: {}
-})
-
-// 开始配盘
-export const groupLink = (arr) => request({
- url:'api/pda/group/link',
- data: arr
-})
-// 打印
-export const pdaPrintf = (code) => request({
- url:'api/pda/printf',
- data: {
- vehicle_code: code
- }
-})
-
-//入库
-export const fullVehicleIn = (code) => request({
- url:'api/pda/fullVehicleIn',
- data: {
- point_code: code
- }
-})
-/**
- * 原料出库
- */
-// 根据物料信息查询配盘信息
-export const queryLinkMaterial = (id) => request({
- url:'api/pda/queryLinkMaterial',
- data: {
- material_id: id
- }
-})
-
-// 1.2出库确认
-export const fullVehicleOut = (code1, code2) => request({
- url:'api/pda/fullVehicleOut',
- data: {
- point_code1: code1,
- point_code2: code2
- }
-})
-/**
- * 生产下料
- */
-// 根据起点查询终点列表
-export const queryEndPointsByStart = (code) => request({
- url:'api/pda/queryEndPointsByStart',
- data: {
- point_code1: code
- }
-})
-
-// 下料
-export const createP2pTask = (code, mcode) => request({
- url:'api/pda/createP2pTask',
- data: {
- point_code1: code,
- point_code2: mcode
- }
-})
-/**
- * 点位更新
- */
-// 解绑
-export const unbindVehicle = (code, type, vcode) => request({
- url:'api/pda/unbindVehicle',
- data: {
- point_code: code,
- vehicle_type: type,
- vehicle_code: vcode
- }
-})
-// 绑定
-export const bindVehicle = (code, type, vcode) => request({
- url:'api/pda/bindVehicle',
- data: {
- point_code: code,
- vehicle_type: type,
- vehicle_code: vcode
- }
-})
-/**
- * 定点作业
- */
-// 查询设备
-export const queryDevice = () => request({
- url:'api/pda/queryDevice',
- data: {}
-})
-
-// 定点作业-确认
-export const taskConfirm = (code1, code2) => request({
- url:'api/pda/taskConfirm',
- data: {
- point_code1: code1,
- point_code2: code2
- }
-})
-/**
- * 作业管理
- */
-// 查询未完成指令
-export const pdaInsts = (keyword, scode, ncode) => request({
- url:'api/pda/insts',
- acsurl: true,
- data: {
- keyword: keyword,
- start_devicecode: scode,
- next_devicecode: ncode
- }
-})
-
-// 指令操作
-export const pdaInst = (type, uuid) => request({
- url:'api/pda/inst',
- acsurl: true,
- data: {
- type: type,
- inst_uuid: uuid
- }
-})
-/**
- * 出库确认
- */
-// 根据载具编码查询配盘信息
-export const queryGroupInfoByVehicle = (code) => request({
- url:'api/pda/queryGroupInfoByVehicle',
- data: {
- vehicle_code: code
- }
-})
-
-// 回库
-export const vehicleGoBack = (code, vcode, num) => request({
- url:'api/pda/vehicleGoBack',
- data: {
- point_code: code,
- vehicle_code: vcode,
- residue_num: num
- }
-})
-// 出库确认
-export const fullVehicleOutConfirm = (code, vcode, num) => request({
- url:'api/pda/fullVehicleOutConfirm',
- data: {
- point_code: code,
- vehicle_code: vcode,
- residue_num: num
- }
+// 修改订单工序
+export const modifyProcess = (data) => request({
+ url:'api/handheld/modifyProcess',
+ data: data
})
\ No newline at end of file
diff --git a/utils/mork2.js b/utils/mork2.js
index e8259aa..b9f9216 100644
--- a/utils/mork2.js
+++ b/utils/mork2.js
@@ -7,172 +7,16 @@ export const handLogin = (user, password) => {
}
return res
}
-export const getVehicleType = () => {
- let res = [
- {
- "value": "LZ",
- "text": "料盅"
- },
- {
- "value": "GTP",
- "text": "钢托盘"
- },
- {
- "value": "1",
- "text": "木托盘"
- }
-]
- return res
-}
-
-export const queryMaterial = () => {
- let res = [
- {
- "material_id": "19",
- "material_code": "2",
- "material_name": "a1"
- },
- {
- "material_id": "9",
- "material_code": "4",
- "material_name": "b1"
- }
-]
- return res
-}
-
-export const queryExistGroup = () => {
- let res = [
- {
- "vehicle_code": "6",
- "vehicle_type": "in ea",
- "material_id": "83",
- "material_code": "75",
- "material_name": "式历委至统",
- "point_code": "76",
- "material_qty": "Ut ea veniam officia in",
- "pcsn": "consequat enim proident labore"
- }
-]
- return res
-}
-
-export const queryVehicleGroup = () => {
- let res = [
- {
- "group_id": "30",
- "vehicle_type": "in quis magna veniam",
- "vehicle_code": "91",
- "material_id": "4",
- "material_code": "20",
- "material_name": "张认义关金",
- "point_code": "16"
- }
-]
-return res
-}
-
-export const groupLink = (arr) => {
+export const regionList = () => {
let res = {
- "message": "tempor elit adipisicing cillum nisi"
+ content: [{value: '1', label: 'aa'}, {value: '2', label: 'bb'}]
}
return res
}
-
-export const pdaPrintf = (code) => {
- let res = {
- "vehicle_code": "91",
- "material_code": "20",
- "material_name": "张认义关金",
- "material_qty": "100",
- "pcsn": "20201112",
- "print_time": "20240210"
- }
- return res
-}
-
-export const queryLinkMaterial = () => {
+
+export const modifyProcess = (data) => {
let res = [
- {
- "point_code": "78",
- "point_name": "片百人共",
- "vehicle_code": "52",
- "material_id": "89",
- "material_code": "85",
- "material_name": "战干者许",
- "pcsn": "ullamco Ut",
- "material_qty": "100"
- }
-]
- return res
-}
-
-export const queryEndPointsByStart = (code) => {
- let res = [
- {
- "point_code2": "81",
- "point_name": "回史就问装作过"
- }
-]
- return res
-}
-
-export const queryDevice = () => {
- let res = [
- {
- "region_code": "68",
- "region_name": "构华",
- "deviceArr": [
- {
- "point_code": "9",
- "point_name": "京产"
- }
- ]
- },
- {
- "region_code": "8",
- "region_name": "构华片资",
- "deviceArr": [
- {
- "point_code": "19",
- "point_name": "京产开向准"
- }
- ]
- }
-]
- return res
-}
-
-export const pdaInsts = () => {
- let res = {
- "code": "1",
- "desc": "in",
- "result": [
- {
- "inst_uuid": "51",
- "task_no": "ADB001",
- "start_devicecode": "46",
- "next_devicecode": "2",
- "inst_status": "0",
- "priority": "一级",
- "create_time": "1976-04-07 02:36:18",
- "carrier": "890000008",
- "instruction_code": '0000',
- "carno": '1号车',
- "inst_step": '1'
- }
- ]
-}
- return res
-}
-
-export const queryGroupInfoByVehicle = (code) => {
- let res = {
- "point_code": "001",
- "material_code": "100001",
- "material_name": "垃圾了付定金",
- "pcsn": "20202020",
- "material_qty": "20.0"
-}
+ {order_code: '111', process: '1', time: '2020-10-10 11:30:30'}, {order_code: '111', process: '2', time: '2020-10-10 11:30:30'}
+ ]
return res
}
\ No newline at end of file