From 07401392be0115d291e64471325fcc4c17ba2be9 Mon Sep 17 00:00:00 2001
From: wjt <1797368093@qq.com>
Date: 星期五, 21 六月 2024 15:26:35 +0800
Subject: [PATCH] 图片压缩
---
common/http.interceptor.js | 2
policy/components/index.vue | 124 ++
uni_modules/yt-dateTimePicker/components/yt-dateTimePicker/yt-dateTimePicker.vue | 339 ++++++++
static/policy/zhi4.png | 0
policy/policyIndex/policyIndex.vue | 23
static/policy/zhi3.png | 0
policy/policyApply/policyApply.vue | 152 ++-
uni_modules/yt-dateTimePicker/package.json | 76 +
components/lingfeng-timepicker/uitls/util.js | 163 ++++
pages/companyLogin/companyLogin.vue | 6
policy/policyApply/perPage.vue | 87 ++
static/i03.png | 0
policy/applyRecordDetails/applyRecordDetails.vue | 59
components/lingfeng-timepicker/lingfeng-timepicker.vue | 980 ++++++++++++++++++++++++
policy/applyRecord/applyRecord.vue | 102 +-
api/policy.js | 19
static/policy/zhi1.png | 0
static/policy/back.png | 0
static/i04.png | 0
policy/components/mine.vue | 15
static/policy/zhi5.png | 0
/dev/null | 20
api/auth.js | 4
uni_modules/yt-dateTimePicker/readme.md | 85 ++
static/policy/zhi2.png | 0
static/head.png | 0
uni_modules/yt-dateTimePicker/changelog.md | 92 ++
static/policy/qrcode-border.png | 0
28 files changed, 2,157 insertions(+), 191 deletions(-)
diff --git a/api/auth.js b/api/auth.js
index 72195ac..db38798 100644
--- a/api/auth.js
+++ b/api/auth.js
@@ -25,3 +25,7 @@
export function getCompanyInfo(data) {
return http.get(`/system/company/${data.companyId}`, {params: data});
}
+// 鏌ヨ鎯犱紒鏀跨瓥
+export function docList(data) {
+ return http.get(`/system/doc/list`, {params: data});
+}
\ No newline at end of file
diff --git a/api/policy.js b/api/policy.js
index 9c02bdb..8021a4b 100644
--- a/api/policy.js
+++ b/api/policy.js
@@ -8,4 +8,23 @@
// 鏌ヨ浼佷笟
export function companyList(data){
return http.get('/system/company/list', {params: data}, { custom: { loading: true }});
+}
+
+// 鎵ф硶浜哄憳 /enforce/peer/list
+export function enforceList(data) {
+ return http.get('/enforce/order/peerList', {params: data}, { custom: { loading: true }});
+}
+// 鐢宠璁板綍
+
+export function orderList(data) {
+ return http.get('/enforce/order/list', {params: data}, { custom: { loading: true }});
+}
+// 鑾峰彇鎵ф硶鍗� 璇︽儏 /enforce/order/{orderId}
+export function orderDetails(data) {
+ return http.get(`/enforce/order/${data.orderId}`, {params: data}, { custom: { loading: true }});
+}
+// 鎵ф硶瀹℃壒
+
+export function checkLogList(data) {
+ return http.get(`/enforce/check/log/list`, {params: data}, { custom: { loading: true }});
}
\ No newline at end of file
diff --git a/common/http.interceptor.js b/common/http.interceptor.js
index 9099a99..6e49d92 100644
--- a/common/http.interceptor.js
+++ b/common/http.interceptor.js
@@ -60,7 +60,7 @@
// vm.$u.vuex('userInfo', null)
// vm.$u.vuex('token', null)
// uni.removeStorageSync("sessionToken")
- uni.clearStorageSync() // 娓呮鎵�鏈夌殑缂撳瓨
+ // uni.clearStorageSync() // 娓呮鎵�鏈夌殑缂撳瓨
uni.showToast({
title: '鎺堟潈杩囨湡,璇烽噸鏂扮櫥褰�',
icon: 'none',
diff --git a/components/customerForm.vue b/components/customerForm.vue
deleted file mode 100644
index 471abc6..0000000
--- a/components/customerForm.vue
+++ /dev/null
@@ -1,20 +0,0 @@
-<template>
- <view>
-
- </view>
-</template>
-
-<script>
- export default {
- name:"customerForm",
- data() {
- return {
-
- };
- }
- }
-</script>
-
-<style>
-
-</style>
\ No newline at end of file
diff --git a/components/lingfeng-timepicker/lingfeng-timepicker.vue b/components/lingfeng-timepicker/lingfeng-timepicker.vue
new file mode 100644
index 0000000..87166e2
--- /dev/null
+++ b/components/lingfeng-timepicker/lingfeng-timepicker.vue
@@ -0,0 +1,980 @@
+<template>
+ <uni-popup ref="popup" type="bottom" :safe-area="safeArea" @change="popChange">
+ <view class="date-time-picker" v-if="showPopPicker">
+ <!-- <view class="date-time-mask" @click.stop="hide"></view> -->
+ <view class="date-time-container" :class="{'safe-area-padding':!safeArea}" @click.stop="handleEvent">
+ <view class="time-picker-tool">
+ <view class="cancel-base" :class="[cancelButtonClass]" @click.stop="close">
+ <text>{{cancelButtonText}}</text>
+ </view>
+ <view :class="[toolBarTitleClass]">
+ <text>{{toolBarTitle}}</text>
+ </view>
+ <view class="confirm-base" :class="[confirmButtonClass]" @click.stop="confirm">
+ <text>{{confirmButtonText}}</text>
+ </view>
+ </view>
+ <view class="picker-tab" v-if="isShowRange">
+ <view @click="dateTabChange(1)" class="picker-tab-item" :style="[rangeBtnStyle,dateTab==1?rangeBtnActiveStyle:'']"
+ >{{pickerData.startTime}}</view>
+ 鑷�
+ <view @click="dateTabChange(2)" class="picker-tab-item" :style="[rangeBtnStyle,dateTab==2?rangeBtnActiveStyle:'']"
+ >{{pickerData.endTime}}</view>
+ </view>
+ <picker-view class="picker-view" :indicator-style="popupIndicatorStyleString" :value="dateTime" @change="dateTimePickerChange">
+ <picker-view-column data-id='year' v-if='isShowYear'>
+ <view class="item" v-for="(item,index) in years" :key="index">{{item}}骞�</view>
+ </picker-view-column>
+ <picker-view-column data-id='month' v-if='isShowMonth'>
+ <view class="item" v-for="(item,index) in months" :key="index">{{item}}鏈�</view>
+ </picker-view-column>
+ <picker-view-column data-id='day' v-if='isShowDay'>
+ <view class="item" v-for="(item,index) in days" :key="index">{{item}}鏃�</view>
+ </picker-view-column>
+ <picker-view-column data-id='hour' v-if='isShowHour'>
+ <view class="item" v-for="(item,index) in hours" :key="index">{{item}}鏃�</view>
+ </picker-view-column>
+ <picker-view-column data-id='minute' v-if='isShowMinute'>
+ <view class="item" v-for="(item,index) in minutes" :key="index">{{item}}鍒�</view>
+ </picker-view-column>
+ <picker-view-column data-id='second' v-if='isShowSecond'>
+ <view class="item" v-for="(item,index) in seconds" :key="index">{{item}}绉�</view>
+ </picker-view-column>
+ <picker-view-column data-id='week' v-if='isShowWeek'>
+ <view class="item" v-for="(item,index) in weeks" :key="index">{{item}}</view>
+ </picker-view-column>
+ <picker-view-column data-id='quarter' v-if='isShowQuarter'>
+ <view class="item" v-for="(item,index) in quarters" :key="index">{{item}}</view>
+ </picker-view-column>
+ </picker-view>
+ </view>
+ </view>
+ </uni-popup>
+</template>
+
+<script>
+ import {
+ getOneMonthDays,
+ getTimeArray,
+ addZero,
+ removeZero,
+ getIndexOfArray,
+ getQuarterArray,
+ isOnlyTime,
+ isRange,
+ getTotalWeeks,
+ getFirstAndLastDate
+ } from './uitls/util.js'
+ const [year, month, date, hour, minute, second]=getTimeArray(new Date());
+ export default {
+ name: 'TimePicker',
+ props: {
+ minDate: { //鏈�灏忛�夋嫨鏃堕棿
+ type: Object,
+ default: function() {
+ return {
+ year: 1970,
+ month: 1,
+ date: 1,
+ hour:0,
+ minute:0,
+ second:0
+ }
+ }
+ },
+ maxDate: { //鏈�澶ч�夋嫨鏃堕棿
+ type: Object,
+ default: function() {
+ return {
+ year,
+ month,
+ date,
+ hour:23,
+ minute:59,
+ second:59
+ }
+ }
+ },
+ type: {
+ /**
+ * date 骞存湀鏃�
+ * year-month 骞存湀
+ * year 骞�
+ * datetime 骞存湀鏃� 鏃跺垎
+ * datetime-all 骞存湀鏃� 鏃跺垎绉�
+ * time 鏃跺垎绉�
+ * hour-minute 鏃跺垎
+ * week 鍛�
+ * quarter 瀛e害
+ * year-range 骞�-鑼冨洿
+ * year-month-range 骞存湀-鑼冨洿
+ * date-range 骞存湀鏃�-鑼冨洿
+ * datetime-range 骞存湀鏃� 鏃跺垎-鑼冨洿
+ * datetime-all-range 骞存湀鏃� 鏃跺垎绉�-鑼冨洿
+ * time-range 鏃跺垎绉�-鑼冨洿
+ */
+ type: String,
+ default: 'date'
+ },
+ defaultData: {
+ type: Object,
+ default: function() {
+ return {
+ startTime: "", //榛樿寮�濮嬫棩鏈�/鏃堕棿 yyyy-mm-dd (HH:MM:SS)
+ endTime: "", //榛樿缁撴潫鏃ユ湡/鏃堕棿 yyyy-mm-dd (HH:MM:SS)
+ year: "", //榛樿骞翠唤 yyyy
+ month: "", //榛樿骞�-鏈堜唤 yyyy-mm
+ week: "", //榛樿鍛� 2020 绗�1鍛�
+ quarter: "", //榛樿瀛e害 2020 涓�瀛e害
+ }
+ }
+ },
+ popIindicatorStyle:{
+ type: Object,
+ default: null
+ },
+ rangeBtnStyle: { // 鑼冨洿閫夋嫨鎸夐挳鏍峰紡
+ type: Object,
+ default: function(){
+ return {
+ color:'#666'
+ }
+ }
+ },
+ rangeBtnActiveStyle: { // 鑼冨洿閫夋嫨鎸夐挳婵�娲绘牱寮�
+ type: Object,
+ default: function(){
+ return {
+ color:'#049bff',
+ borderColor:'#049bff'
+ }
+ }
+ },
+ cancelButtonText: {
+ type: String,
+ default: '鍙栨秷'
+ },
+ cancelButtonClass: {
+ type: String,
+ default: 'cancel-btn'
+ },
+ toolBarTitle: {
+ type: String,
+ default: ''
+ },
+ toolBarTitleClass: {
+ type: String,
+ default: 'tool-title'
+ },
+ confirmButtonText: {
+ type: String,
+ default: '纭畾'
+ },
+ confirmButtonClass: {
+ type: String,
+ default: 'confirm-btn'
+ },
+ safeArea: {
+ type: Boolean,
+ default: true
+ },
+ en: {
+ type: Boolean,
+ default: false
+ },
+ weekType:{
+ type:String,
+ default:'firstWeek' // firstWeek fullWeek firstDay
+ }
+ },
+ data() {
+ return {
+ showPicker: false,
+ showPopPicker: false,
+ dateTab: 1,
+ popupIndicatorStyleString:"",
+ dateTime: [],//picker-view-column 閫変腑鐨勫��
+ lastDateTime: [],//閫変腑鐨勬椂闂�,灏忎簬10鐨勬暟涓嶅姞0
+ days: [],//鍙�夌殑鏃ュ垪琛�
+ months: [],//鍙�夌殑鏈堝垪琛�
+ quarters: getQuarterArray(1, 12),//鍙�夌殑瀛e害鍒楄〃
+ weeks: [], //鍙�夌殑鍛ㄥ垪琛�
+ hours: [], //鍙�夌殑鏃跺垪琛�
+ minutes: [], //鍙�夌殑鍒嗗垪琛�
+ seconds: [], //鍙�夌殑绉掑垪琛�
+ datestring: "",//閫変腑鐨勬椂闂�,鏍煎紡鍖栧悗鐨勫睍绀�
+ allQuarter: [{
+ name: "涓�瀛e害",
+ start: "01-01",
+ end: "03-31"
+ },
+ {
+ name: "浜屽搴�",
+ start: "04-01",
+ end: "06-30"
+ },
+ {
+ name: "涓夊搴�",
+ start: "07-01",
+ end: "09-30"
+ },
+ {
+ name: "鍥涘搴�",
+ start: "10-01",
+ end: "12-31"
+ }
+ ],
+ pickerData: {
+ startTime: "",
+ endTime: "",
+ month: "",
+ quarter: "",
+ year: ""
+ }
+ };
+ },
+ methods: {
+ showPop() {
+ this.dateTab = 1;
+ this.getPopIndicatorStyle();
+ this.showPopPicker = true;
+ this.tempTime = new Date().getTime();
+ this.$refs.popup.open();
+ },
+ close() {
+ this.$emit('close');
+ this.showPopPicker = false;
+ this.$refs.popup.close();
+ this.pickerData={
+ startTime: "",
+ endTime: "",
+ month: "",
+ quarter: "",
+ year: ""
+ }
+ this.lastDateTime=[];
+ },
+ dateTabChange(i) {
+ if (this.dateTab == i) {
+ return;
+ }
+ this.dateTab = i;
+ this.datestring = i == 2 ? this.pickerData.endTime : this.pickerData.startTime;
+ this.initDateTime();
+ this.tempTime = new Date().getTime();
+ },
+ dateTimePickerChange(e) {
+ if(new Date().getTime()-this.tempTime < 100){
+ //dateTimePickerChange 灏忕▼搴忕鏈夋椂鐐瑰嚮dateTabChange灏辫Е鍙戜簡change
+ // console.log("鏃犳晥婊氬姩")
+ return;
+ }
+ this.tempTime = new Date().getTime();
+ let columns = [...e.target.value];
+ let currentDateList=[];
+
+ if (isOnlyTime(this.type)) {
+ currentDateList = [this.hours[columns[0]],this.minutes[columns[1]],this.seconds[columns[2]]];
+ let tag = 2;
+ if(currentDateList[1]!=this.lastDateTime[1]){
+ tag = 3;
+ }
+ let minTag = currentDateList[0] == this.realMinDate.hour;
+ let maxTag = currentDateList[0] == this.realMaxDate.hour;
+ if(tag > 2) {
+ minTag = minTag && currentDateList[1] == this.realMinDate.minute;
+ maxTag = maxTag && currentDateList[1] == this.realMaxDate.minute;
+ }
+
+ this.getHMSColumnsData(currentDateList, this.lastDateTime, tag, minTag, maxTag);
+ } else if (this.type === "week") {
+ if (this.lastDateTime[0] != this.years[columns[0]]) {
+ this.getWeeks(this.years[columns[0]]);
+ }
+ } else if (this.type === "quarter") {
+ if (this.lastDateTime[0] != this.years[columns[0]]) {
+ if (columns[0] == 0) {
+ this.quarters = getQuarterArray(this.realMinDate.month, 12);
+ } else if (columns[0] == this.years.length - 1) {
+ this.quarters = getQuarterArray(1, this.realMaxDate.month);
+ } else {
+ this.quarters = getQuarterArray(1, 12);
+ }
+ }
+ } else {
+ currentDateList=[this.years[columns[0]],this.months[columns[1]],this.days[columns[2]],this.hours[columns[3]],this.minutes[columns[4]],this.seconds[columns[5]]];
+ this.getColumnsData(currentDateList, this.lastDateTime);
+ }
+ setTimeout(() => {
+ if (this.type === "week") {
+ if (this.lastDateTime[0] != this.years[columns[0]]) {
+ let index = columns[1];
+ index = this.weeks.findIndex(val => val == this.lastDateTime[1]);
+ if (index < 0) {
+ index = columns[0] == 0 ? 0 : this.weeks.length - 1;
+ }
+ columns.splice(1, 1, index)
+ }
+ } else if (this.type === "quarter") {
+ if (this.lastDateTime[0] != this.years[columns[0]]) {
+ let index = columns[1];
+ index = this.quarters.findIndex(val => val == this.lastDateTime[1]);
+ if (index < 0) {
+ index = columns[0] == 0 ? 0 : this.quarters.length - 1;
+ }
+ columns.splice(1, 1, index)
+ }
+ } else {
+ let names = ['year', 'month', 'day', 'hour', 'minute', 'second'];
+ if (isOnlyTime(this.type)){
+ names=names.slice(3);
+ }
+ const arr = [];
+ let i = 1;
+ while(i < currentDateList.length && currentDateList[i] != undefined) {
+ const colName = names[i] + 's';
+ let index = this[colName].findIndex(val => val == currentDateList[i]);
+ if (index < 0) {
+ index = currentDateList[i] <= this[colName][0] ? 0 : this[colName].length - 1;
+ }
+ arr.push(index);
+ i++;
+ }
+ columns.splice(1, columns.length-1, ...arr);
+ }
+ columns.forEach((column, index) => {
+ this.dateTime.splice(index, 1, column);
+ })
+ this.formatDate();
+ },50)
+ },
+ formatDate() {//閫変腑鐨勬椂闂磋褰� 鍙婃牸寮忓寲
+ let names = ['year', 'month', 'day', 'hour', 'minute', 'second'];
+ let dateString, formatDateArray = [];
+ if (['date','year','year-month','year-range','year-month-range','date-range'].includes(this.type)) {
+ formatDateArray = this.dateTime.map((item, index) => {
+ let num=this[names[index] + 's'][item] ? this[names[index] + 's'][item] : this[names[index] + 's'][this[names[index] + 's'].length-1];
+ return addZero(num);
+ })
+ dateString = formatDateArray.join('-');
+ } else if (isOnlyTime(this.type)) {
+ names = names.splice(3);
+ formatDateArray = this.dateTime.map((item, index) => {
+ return addZero(this[names[index] + 's'][item]);
+ })
+ dateString = formatDateArray.join(':');
+ } else if (this.type === "week") {
+ dateString = this.years[this.dateTime[0]] + " " + this.weeks[this.dateTime[1]];
+ } else if (this.type === "quarter") {
+ dateString = this.years[this.dateTime[0]] + " " + this.quarters[this.dateTime[1]];
+ } else {
+ let name1 = names.splice(0, 3);
+ formatDateArray = this.dateTime.map((item, index) => {
+ if (index > 2) {
+ return addZero(this[names[index - 3] + 's'][item]);
+ } else {
+ return addZero(this[name1[index] + 's'][item]);
+ }
+ })
+ dateString = formatDateArray.splice(0, 3).join('-') + ' ' + formatDateArray.join(':');
+ }
+ if(['week','quarter'].includes(this.type)){
+ this.lastDateTime = dateString.split(/[-: ]/);
+ }else{
+ let tempDate = [];
+ dateString.split(/[-: ]/).forEach((val) => {
+ tempDate.push(parseInt(removeZero(val)));
+ })
+ this.lastDateTime = tempDate;
+ }
+
+ switch (this.type) {
+ case "date":
+ case "datetime":
+ case "datetime-all":
+ case "time":
+ case "hour-minute":
+ case "year-range":
+ case "year-month-range":
+ case "date-range":
+ case "datetime-range":
+ case "datetime-all-range":
+ case "time-range":
+ if (this.dateTab == 2) {
+ this.pickerData.endTime = dateString;
+ } else {
+ this.pickerData.startTime = dateString;
+ };
+ break;
+ case "year-month":
+ this.pickerData.month = dateString;
+ break;
+ case "year":
+ this.pickerData.year = dateString;
+ break;
+ case "week":
+ this.pickerData.week = dateString;
+ break;
+ case "quarter":
+ this.pickerData.quarter = dateString;
+ break;
+ }
+ // this.$emit('change', dateString)
+ },
+ getPopIndicatorStyle() {
+ if (this.popIindicatorStyle) {
+ for (let key in this.popIindicatorStyle) {
+ this.popupIndicatorStyleString += `${key}:${this.popIindicatorStyle[key]};`
+ }
+ }
+ },
+ initDefaultDate() {//鍒濆鍖栬捣濮嬫椂闂�
+ const pickerData = {};
+ Object.keys(this.defaultData).forEach(key=>{
+ pickerData[key] = this.defaultData[key];
+ })
+ let [y, m, d] = getTimeArray(new Date());
+ if (this.type === 'year') {
+ pickerData.year=pickerData.year||y;
+ this.datestring = this.getDefaultYearMonth(pickerData.year,this.type);
+ } else if (this.type === 'year-month') {
+ pickerData.month=pickerData.month||(y+'-'+addZero(m));
+ this.datestring = this.getDefaultYearMonth(pickerData.month,this.type);
+ } else if (this.type === 'year-range') {
+ pickerData.startTime=pickerData.startTime||y;
+ pickerData.endTime=pickerData.endTime||y;
+ this.datestring = this.getDefaultYearMonth(pickerData.startTime,this.type);
+ } else if (this.type === 'year-month-range') {
+ pickerData.startTime=pickerData.startTime||(y+'-'+addZero(m));
+ pickerData.endTime=pickerData.endTime||(y+'-'+addZero(m));
+ this.datestring = this.getDefaultYearMonth(pickerData.startTime,this.type);
+ } else if (this.type === 'quarter') {
+ this.datestring = pickerData.quarter;
+ } else if (this.type === 'week') {
+ this.datestring = pickerData.week;
+ } else {
+ // 澶勭悊榛樿寮�濮嬫椂闂村拰缁撴潫鏃堕棿
+ let startTime=isOnlyTime(this.type) ? y + "/" + m + "/" + d + " " + pickerData.startTime : pickerData.startTime;
+ startTime=this.getMinDate(startTime).replace(/-/g,"/");
+ pickerData.startTime = isNaN(Date.parse(startTime)) ? this.formatPickerData(new Date(),this.type) : this.formatPickerData(startTime,this.type);
+ if(isRange(this.type)){
+ let endTime=isOnlyTime(this.type) ? y + "/" + m + "/" + d + " " + pickerData.endTime : pickerData.endTime;
+ endTime=this.getMinDate(endTime).replace(/-/g,"/");
+ pickerData.endTime = isNaN(Date.parse(endTime)) ? this.formatPickerData(new Date(),this.type) : this.formatPickerData(endTime,this.type);
+ }
+ this.datestring = pickerData.startTime;
+ }
+
+ this.$nextTick(()=>{
+ Object.keys(pickerData).forEach(key=>{
+ this.pickerData[key] = pickerData[key];
+ })
+ })
+ },
+ initDateTime() {//鍒濆鍖杙icker-view閫夋嫨鐨勬椂闂�
+ let value;
+ if (this.datestring && this.datestring.length > 0) {
+ if (['year','year-range'].includes(this.type)) {
+ value = new Date(this.datestring, 0);
+ } else if (isOnlyTime(this.type)) {
+ let date = new Date();
+ let ary = this.datestring.split(':');
+ ary.forEach((item, index) => {
+ if (index == 0) {
+ date.setHours(item)
+ } else if (index == 1) {
+ date.setMinutes(item)
+ } else if (index == 2) {
+ date.setSeconds(item)
+ }
+ })
+ value = date;
+ const currentHMS = getTimeArray(value).slice(3);
+ const lastHMS = [-1, -1, -1];
+ this.getHMSColumnsData(currentHMS, lastHMS, 1, true, true);
+ } else if(['year-month','year-month-range'].includes(this.type)){
+ let datestring = this.datestring.replace(/-/g, '/');
+ value = isNaN(Date.parse(datestring)) ? new Date(datestring+'/01') : new Date(datestring);
+ } else {
+ value = new Date(this.datestring.replace(/-/g, '/'));
+ }
+ } else {
+ value = new Date();
+ }
+ let len, timeArray, index;
+ let array = ['week','quarter'].includes(this.type) ? this.datestring.split(" ") : getTimeArray(value);
+ let [year, month, day, hour, minute, second] = array;
+ if (this.isShowWeek) {
+ this.getWeeks(year?year:this.realMinDate.year);
+ } else if(!isOnlyTime(this.type)){
+ this.getColumnsData(array);
+ }
+ let names = ['year', 'month', 'day', 'hour', 'minute', 'second'];
+ switch (this.type) {
+ case "date":
+ case "time":
+ case "date-range":
+ case "time-range":
+ len = 3;
+ break;
+ case "year-month":
+ case "year-month-range":
+ case "hour-minute":
+ case "week":
+ case "quarter":
+ len = 2;
+ break;
+ case "year":
+ case "year-range":
+ len = 1;
+ break;
+ case "datetime":
+ case "datetime-range":
+ len = 5;
+ break;
+ case "datetime-all":
+ case "datetime-all-range":
+ len = 6;
+ break;
+ }
+ timeArray = new Array(len).fill(0);
+ if (isOnlyTime(this.type)) {
+ names = names.slice(3);
+ array = array.slice(3);
+ } else if (this.type === "week") {
+ names = ["year", "week"];
+ } else if (this.type === "quarter") {
+ names = ["year", "quarter"];
+ } else {
+ names = names.slice(0,len);
+ array = array.slice(0,len);
+ }
+ // setTimeout(() => {
+ timeArray = timeArray.map((item, index) => {
+ const name = names[index];
+ return getIndexOfArray(array[index], this[name + 's'])
+ })
+ this.dateTime = timeArray;
+ this.lastDateTime = array;
+ this.formatDate();
+ // },100)
+ },
+ initTimeData(end, start) {//璁剧疆鏈�澶ф渶灏忓��
+ let timeArray = [];
+ while (start <= end) {
+ timeArray.push(start);
+ start++;
+ }
+ return timeArray;
+ },
+ getColumnsData(currentDateList, lastDateTime=[-1,-1,-1,-1,-1,-1]){
+ let min='';
+ let max='';
+ let minTag=false;
+ let maxTag=false;
+ let currentYear=currentDateList[0];
+ let currentMonth=currentDateList[1];
+ let currentDate=currentDateList[2];
+ let currentHMS=currentDateList.slice(3);
+ let lastHMS=lastDateTime.slice(3);
+ if(this.isShowMonth || this.isShowQuarter){
+ if(currentYear==this.realMinDate.year){
+ minTag=true;
+ }
+ if (currentYear == this.realMaxDate.year){
+ maxTag=true;
+ }
+ if(currentYear!=lastDateTime[0]){
+ min=1;
+ max=12;
+ if (minTag){
+ min=this.realMinDate.month;
+ currentMonth=currentMonth<min?min:currentMonth;
+ }
+ if (maxTag){
+ max=this.realMaxDate.month;
+ currentMonth=currentMonth>max?max:currentMonth;
+ }
+ this.isShowMonth && (this.months = this.initTimeData(max, min));
+ this.isShowQuarter && (this.quarters = getQuarterArray(min, max));
+ }
+ }
+ if(this.isShowDay){
+ minTag=minTag&¤tMonth == this.realMinDate.month;
+ maxTag=maxTag&¤tMonth == this.realMaxDate.month;
+ if(currentMonth!=lastDateTime[1]||max){
+ min=1;
+ max=getOneMonthDays(currentYear, currentMonth-1);
+ if (minTag){
+ min=this.realMinDate.date;
+ currentDate=currentDate<min?min:currentDate;
+ }
+ if (maxTag){
+ max=this.realMaxDate.date;
+ currentDate=currentDate>max?max:currentDate;
+ }
+ this.days = this.initTimeData(max, min);
+ }
+ }
+ if(this.isShowHour){
+ // 鍒ゆ柇鏃跺垎绉掑垪琛ㄦ槸鍚﹂渶瑕侀噸鏂拌祴鍊�
+ let tag=0;
+ if(currentHMS[1]!=lastDateTime[4]){
+ tag=3;
+ }
+ if(currentHMS[0]!=lastDateTime[3]){
+ tag=2;
+ }
+ if(max||currentDate!=lastDateTime[2]){
+ tag=1;
+ }
+ minTag=minTag&¤tDate==this.realMinDate.date;
+ maxTag=maxTag&¤tDate==this.realMaxDate.date;
+ if(tag>1){
+ minTag=minTag&¤tHMS[0]==this.realMinDate.hour;
+ maxTag=maxTag&¤tHMS[0]==this.realMaxDate.hour;
+ }
+ if(tag>2){
+ minTag=minTag&¤tHMS[1]==this.realMinDate.minute;
+ maxTag=maxTag&¤tHMS[1]==this.realMaxDate.minute;
+ }
+ this.getHMSColumnsData(currentHMS, lastHMS, tag, minTag, maxTag);
+ }
+ },
+
+ getHMSColumnsData(currentHMS, lastHMS, tag, minTag, maxTag){
+ let [currentHour, currentMinute, currentSecond] = currentHMS;
+ let min="";
+ let max="";
+ if(tag==1){
+ min=0;
+ max=23;
+ if(minTag){
+ min=this.realMinDate.hour;
+ currentHour=currentHour<min?min:currentHour;
+ }
+ if(maxTag){
+ max=this.realMaxDate.hour;
+ currentHour=currentHour>max?max:currentHour;
+ }
+ this.hours = this.initTimeData(max, min);
+ tag=2;
+ }
+
+ if(tag==2){
+ minTag=minTag&¤tHour==this.realMinDate.hour;
+ maxTag=maxTag&¤tHour==this.realMaxDate.hour;
+ min=0;
+ max=59;
+ if(minTag){
+ min=this.realMinDate.minute;
+ currentMinute=currentMinute<min?min:currentMinute;
+ }
+ if(maxTag){
+ max=this.realMaxDate.minute;
+ currentMinute=currentMinute>max?max:currentMinute;
+ }
+ this.minutes = this.initTimeData(max, min);
+ tag=3;
+ }
+
+ if(tag=3){
+ minTag=minTag&¤tMinute==this.realMinDate.minute;
+ maxTag=maxTag&¤tMinute==this.realMaxDate.minute;
+ min=0;
+ max=59;
+ if(minTag){
+ min=this.realMinDate.second;
+ }
+ if(maxTag){
+ max=this.realMaxDate.second;
+ }
+ this.seconds = this.initTimeData(max, min);
+ }
+ },
+ getWeeks(year){
+ let startDate = year + '/01/01', endDate = year + '/12/31';
+ if(year<=this.realMinDate.year){
+ startDate = this.realMinDate.year + '/' + addZero(this.realMinDate.month) + '/' + addZero(this.realMinDate.date);
+ }
+ if(year>=this.realMaxDate.year){
+ endDate = this.realMaxDate.year + '/' + addZero(this.realMaxDate.month) + '/' + addZero(this.realMaxDate.date);
+ }
+ const [start, end] = getTotalWeeks(startDate, endDate, this.en, this.weekType);
+ this.weeks = this.initTimeData(end, start).map(item=>`绗�${item}鍛╜);
+ },
+ getWeekDate(){
+ let [year, w] = this.pickerData.week.split(" ");
+ let week = w.slice(1, - 1);
+ let { start, end } = getFirstAndLastDate(year, week, this.en, this.weekType);
+ start = this.formatPickerData(this.getMinDate(start),'date');
+ end = this.formatPickerData(this.getMAxDate(end),'date');
+ return [this.pickerData.week, start, end];
+ },
+ getQuarterDate(){
+ let [y, q] = this.pickerData.quarter.split(" ");
+ let index = getIndexOfArray(q, this.allQuarter, "name");
+ let start = y + "-" + this.allQuarter[index].start;
+ let end = y + "-" + this.allQuarter[index].end;
+ start = this.formatPickerData(this.getMinDate(start),'date');
+ end = this.formatPickerData(this.getMAxDate(end),'date');
+ return [this.pickerData.quarter,start, end];
+ },
+ getMinDate(date){
+ let defaultMInArr=[1970,1,1,0,0,0];
+ let minDate = `${this.realMinDate.year||defaultMInArr[0]}/${this.realMinDate.month||defaultMInArr[1]}/${this.realMinDate.date||defaultMInArr[2]} ${this.realMinDate.hour||defaultMInArr[3]}:${this.realMinDate.minute||defaultMInArr[4]}:${this.realMinDate.second||defaultMInArr[5]}`;
+ let repDate=date.replace(/-/g,"/");
+ let datetime=isNaN(Date.parse(repDate))?new Date().getTime():new Date(repDate).getTime();
+ return datetime>new Date(minDate).getTime()?date:minDate.replace(/\//g,"-");
+ },
+ getMAxDate(date){
+ let maxDate = `${this.realMaxDate.year}/${this.realMaxDate.month}/${this.realMaxDate.date} ${this.realMaxDate.hour}:${this.realMaxDate.minute}:${this.realMaxDate.second}`;
+ let repDate=date.replace(/-/g,"/");
+ let datetime=isNaN(Date.parse(repDate))?new Date().getTime():new Date(repDate).getTime();
+ return datetime<new Date(maxDate).getTime()?date:maxDate;
+ },
+ getDefaultYearMonth(date,type){
+ let minDate=['year','year-range'].includes(this.type)?this.realMinDate.year:(this.realMinDate.year+"-"+addZero(this.realMinDate.month));
+ let maxDate=['year','year-range'].includes(this.type)?this.realMaxDate.year:(this.realMaxDate.year+"-"+addZero(this.realMaxDate.month));
+ return date<minDate?minDate:date>maxDate?maxDate:date;
+ },
+ //popup
+ show(){
+ this.$nextTick(()=>{
+ this.initDefaultDate();
+ this.initDateTime();
+ this.showPop();
+ })
+ },
+ handleEvent() {
+ return;
+ },
+ confirm() {
+ let val;
+ switch (this.type){
+ case "date":
+ case "datetime":
+ case "datetime-all":
+ case "time":
+ case "hour-minute":
+ val = this.pickerData.startTime;
+ break;
+ case "year":
+ val = this.pickerData.year;
+ break;
+ case "year-month":
+ val = this.pickerData.month;
+ break;
+ case "week":
+ val = this.getWeekDate();
+ break;
+ case "quarter":
+ val = this.getQuarterDate();
+ break;
+ case "year-range":
+ case "year-month-range":
+ case "date-range":
+ case "datetime-range":
+ case "datetime-all-range":
+ case "time-range":
+ let start=this.pickerData.startTime;
+ let end=this.pickerData.endTime;
+ if(start>end){
+ val=[end,start];
+ }else{
+ val=[start,end];
+ }
+ break;
+ default:
+ break;
+ }
+ this.$emit("change",val)
+ this.close();
+ },
+ popChange(val){
+ if(!val.show){
+ this.$emit("close");
+ this.showPopPicker = false;
+ this.$parent.pageScrollFlag=true;
+ }
+ },
+ formatPickerData(date,type){
+ let [y, m, d, HH, MM, SS] = getTimeArray(new Date(date));
+ m=addZero(m);
+ d=addZero(d);
+ HH=addZero(HH);
+ MM=addZero(MM);
+ SS=addZero(SS);
+ switch (type){
+ case "date":
+ case "date-range":
+ return y + "-" + m + "-" + d;
+ case "datetime":
+ case "datetime-range":
+ return y + "-" + m + "-" + d + " " + HH + ":" + MM;
+ case "datetime-all":
+ case "datetime-all-range":
+ return y + "-" + m + "-" + d + " " + HH + ":" + MM + ":" + SS;
+ case "time":
+ case "time-range":
+ return HH + ":" + MM + ":" + SS;
+ case "hour-minute":
+ return HH + ":" + MM;
+ default:
+ return "";
+ break;
+ }
+
+ }
+ },
+ computed: {
+ years() {//鍙�夌殑骞村垪琛�
+ return this.initTimeData(this.realMaxDate.year, this.realMinDate.year);
+ },
+ isShowYear() {
+ return !['time','hour-minute','time-range'].includes(this.type);
+ },
+ isShowMonth() {
+ return !['year','time','hour-minute','week','quarter','year-range','time-range'].includes(this.type);
+ },
+ isShowDay() {
+ return ['date','datetime','datetime-all','date-range','datetime-range','datetime-all-range'].includes(this.type);
+ },
+ isShowHour() {
+ return !['date','year-month','year','week','quarter','year-range','year-month-range','date-range'].includes(this.type);
+ },
+ isShowRange() {
+ return isRange(this.type);
+ },
+ isShowMinute() {
+ return !['date','year-month','year','week','quarter','year-range','year-month-range','date-range'].includes(this.type);
+ },
+ isShowSecond() {
+ return ['time','datetime-all','datetime-all-range','time-range'].includes(this.type);
+ },
+ isShowQuarter() {
+ return this.type === 'quarter';
+ },
+ isShowWeek() {
+ return this.type === 'week';
+ },
+ realMinDate(){
+ return {
+ year: 1970,
+ month: 1,
+ date: 1,
+ hour:0,
+ minute:0,
+ second:0,
+ ...this.minDate
+ }
+ },
+ realMaxDate(){
+ return {
+ year,
+ month,
+ date,
+ hour:23,
+ minute:59,
+ second:59,
+ ...this.maxDate
+ }
+ }
+ },
+ }
+</script>
+
+<style lang="scss">
+ // popup
+ .date-time-picker {
+ width: 100%;
+ height: 40vh;
+ border-top-right-radius: 10rpx;
+ border-top-left-radius: 10rpx;
+ .date-time-mask {
+ position: fixed;
+ top: 0;
+ bottom: 0;
+ left: 0;
+ right: 0;
+ background-color: rgba($color: #000000, $alpha: .5);
+ z-index: 998;
+ }
+
+ .date-time-container {
+ width: 100%;
+ height: 100%;
+ border-top-right-radius: 10rpx;
+ border-top-left-radius: 10rpx;
+ box-sizing: border-box;
+ padding-bottom: 20rpx;
+ background-color: #f6f6f6;
+ display: flex;
+ flex-direction: column;
+
+ .time-picker-tool {
+ height: 80rpx;
+ display: flex;
+ align-items: center;
+ justify-content: space-between;
+ font-size: 32rpx;
+
+ .cancel-base {
+ padding: 0 32rpx;
+ box-sizing: border-box;
+ }
+ .cancel-btn {
+ color: #969799;
+ }
+
+ .tool-title {
+ font-weight: 500;
+ font-size: 32rpx;
+ max-width: 50%;
+ overflow: hidden;
+ white-space: nowrap;
+ text-overflow: ellipsis;
+ }
+ .confirm-base {
+ padding: 0 32rpx;
+ box-sizing: border-box;
+ }
+ .confirm-btn {
+ color: #049bff;
+ }
+ }
+
+ .picker-view {
+ width: 100%;
+ flex: 1;
+
+ .item {
+ font-size: 34rpx;
+ display: flex;
+ align-items: center;
+ justify-content: center;
+ }
+ }
+ }
+ .safe-area-padding{
+ padding-bottom: constant(safe-area-inset-bottom);
+ padding-bottom: env(safe-area-inset-bottom);
+ }
+ }
+ .picker-tab{
+ display: flex;
+ justify-content: space-around;
+ align-items: center;
+ margin: 20rpx 0;
+ }
+ .picker-tab-item{
+ box-sizing: border-box;
+ width: 260rpx;
+ text-align: center;
+ padding: 4rpx 30rpx;
+ border:2rpx solid #666;
+ border-radius: 20rpx;
+ font-size: 30rpx;
+ }
+
+</style>
diff --git a/components/lingfeng-timepicker/uitls/util.js b/components/lingfeng-timepicker/uitls/util.js
new file mode 100644
index 0000000..976744b
--- /dev/null
+++ b/components/lingfeng-timepicker/uitls/util.js
@@ -0,0 +1,163 @@
+/**
+ * 鑾峰彇鏌愬勾鏌愭湀鏈夊灏戝ぉ
+ */
+export const getOneMonthDays = (year, month) => {
+ month = Number(month);
+ const baseMonthsDays = [31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31];
+ if (year % 4 == 0 && (year % 100 != 0 || year % 400 == 0)) {
+ if (month === 1) {
+ baseMonthsDays[month] = 29;
+ }
+ }
+ return baseMonthsDays[month];
+}
+
+/**
+ * 鑾峰彇鏃ユ湡鐨勫勾鏈堟棩鏃跺垎绉�
+ */
+export const getTimeArray = (data) => {
+ const year = data.getFullYear();
+ const month = data.getMonth() + 1;
+ const date = data.getDate();
+ const hour = data.getHours();
+ const minute = data.getMinutes();
+ const second = data.getSeconds();
+ return [year, month, date, hour, minute, second];
+}
+/**
+ * 灏忎簬10鐨勬暟瀛楀墠闈㈣ˉ0
+ */
+export const addZero = (num) => {
+ if (num / 1 == 0) {
+ return "00";
+ }
+ num = "" + num;
+ return num < 10 ? (num.substr(0, 1) == 0 ? num : ('0' + num)) : num;
+}
+/**
+ * 灏忎簬10鐨勬暟瀛楀墠闈㈠幓闄�0
+ */
+export const removeZero = (num) => {
+ if (num / 1 == 0) {
+ return 0
+ }
+ num = "" + num;
+ return num.substr(0, 1) == 0 ? (num.substr(1)) : num;
+}
+/**
+ * 鑾峰彇褰撳墠鍊煎湪鏁扮粍涓殑绱㈠紩
+ */
+export const getIndexOfArray = (value, array, key) => {
+ let index;
+ if (key) {
+ index = array.findIndex(item => item[key] == value);
+ } else {
+ index = array.findIndex(item => item == value);
+ }
+ return index > -1 ? index : 0;
+}
+
+/**
+ * 鑾峰彇瀛e害
+ */
+export const getQuarterArray = (startMOnth, endMOnth) => {
+ let arr = ["涓�瀛e害", "浜屽搴�", "涓夊搴�", "鍥涘搴�"];
+ let start = Math.ceil(startMOnth / 3);
+ let end = Math.ceil(endMOnth / 3);
+ if (end < start) {
+ return arr;
+ } else {
+ return arr.slice(start - 1, end);
+ }
+}
+/**
+ * 鏄惁涓鸿寖鍥撮�夋嫨
+ */
+export const isRange = (type) => {
+ return type.indexOf("range") > -1;
+}
+/**
+ * 鏄惁浠呬负鏃堕棿閫夋嫨
+ */
+export const isOnlyTime = (type) => {
+ return ["time", "hour-minute", "time-range"].includes(type);
+}
+/**
+ * 鑾峰彇start,end涔嬮棿鏈夊灏戝懆
+ */
+export const getTotalWeeks = (start, end, en, weekType) => {
+ if (weekType === 'firstDay') {
+ return getFirstDayTotalWeeks(start, end, weekType)
+ }
+ //鑾峰彇end褰撳墠鍛ㄧ殑绗竴澶�
+ let endMon = getWeekFirstDate(new Date(end), en);
+ //鑾峰彇start褰撳墠鍛ㄧ殑绗竴澶�
+ let startMon = getWeekFirstDate(new Date(start), en);
+ let year = new Date(start).getFullYear();
+ let firMon = getWeekFirstDate(new Date(year + '/01/01'), en);
+ if (weekType === 'fullWeek') {
+ if (new Date(startMon).getFullYear() != year) {
+ let curTime = new Date(startMon);
+ startMon = curTime.setDate(curTime.getDate() + 7);
+ }
+ if (new Date(firMon).getFullYear() != year) {
+ let curTime = new Date(firMon);
+ firMon = curTime.setDate(curTime.getDate() + 7);
+ }
+ }
+ return getStartAndEndWeek(firMon, startMon, endMon, weekType);
+}
+/**
+ * 鑾峰彇褰撳墠鍛ㄧ殑绗竴澶�
+ * 榛樿鍛ㄤ竴涓虹涓�澶╋紝en=true 鏃跺懆鏃ヤ负绗竴澶�
+ */
+function getWeekFirstDate(date, en = false) {
+ let temptTime = new Date(date);
+ let weekday = temptTime.getDay() || (en ? 0 : 7);
+ return temptTime.setDate(temptTime.getDate() - weekday + (en ? 0 : 1));
+}
+/**
+ * 鑾峰彇褰撳墠骞寸week鍛ㄧ殑绗竴澶╁拰鏈�鍚庝竴澶�
+ * 榛樿鍛ㄤ竴涓虹涓�澶╋紝en=true 鏃跺懆鏃ヤ负绗竴澶�
+ */
+export const getFirstAndLastDate = (year, week, en, weekType) => {
+ let firstDate = new Date(getWeekFirstDate(new Date(year + '/01/01'), en));
+ if (weekType === 'fullWeek') {
+ if (firstDate.getFullYear() != year) {
+ firstDate.setDate(firstDate.getDate() + 7);
+ }
+ }
+ if (weekType === 'firstDay') {
+ firstDate = new Date(year + '/01/01');
+ }
+ firstDate = new Date(firstDate.setDate(firstDate.getDate() + (week - 1) * 7));
+ let lastDate = new Date(firstDate);
+ lastDate = new Date(lastDate.setDate(lastDate.getDate() + 6));
+ const [fy, fm, fd] = getTimeArray(firstDate);
+ const [ly, lm, ld] = getTimeArray(lastDate);
+ const start = `${fy}-${addZero(fm)}-${addZero(fd)}`;
+ const end = `${ly}-${addZero(lm)}-${addZero(ld)}`;
+ return {
+ start,
+ end
+ };
+}
+
+function getStartAndEndWeek(first, start, end) {
+ let d = Math.ceil((end.valueOf() - first.valueOf()) / 8.64e7) + 1;
+ let endWeek = Math.ceil(d / 7);
+ let startWeek = 1;
+ if (start !== first) {
+ let d = Math.ceil((start.valueOf() - first.valueOf()) / 8.64e7) + 1;
+ startWeek = Math.ceil(d / 7);
+ }
+ return [startWeek, endWeek];
+}
+
+function getFirstDayTotalWeeks(start, end, weekType) {
+ let year = new Date(start).getFullYear();
+ let startTime = new Date(start).getTime();
+ let endTime = new Date(end).getTime();
+ let firstTime = new Date(year + '/01/01').getTime();
+ return getStartAndEndWeek(firstTime, startTime, endTime, weekType)
+}
\ No newline at end of file
diff --git a/pages/companyLogin/companyLogin.vue b/pages/companyLogin/companyLogin.vue
index 760656b..3188d7d 100644
--- a/pages/companyLogin/companyLogin.vue
+++ b/pages/companyLogin/companyLogin.vue
@@ -24,7 +24,7 @@
鎵嬫満鍙�
</view>
<view class="form-input">
- <input type="number" placeholder="璇疯緭鍏�11浣嶆墜鏈哄彿"/>
+ <input type="number" v-model="form.phone" placeholder="璇疯緭鍏�11浣嶆墜鏈哄彿"/>
</view>
</view>
<view class="form-item">
@@ -32,7 +32,7 @@
楠岃瘉鐮�
</view>
<view class="form-input set-flex set-flex-content-between">
- <input type="number" placeholder="璇疯緭鍏ラ獙璇佺爜"/>
+ <input type="number" v-model="form.code" placeholder="璇疯緭鍏ラ獙璇佺爜"/>
<view @click="getCode">
<text class="driver"></text>
<text class="getcode">{{tips}}</text>
@@ -62,7 +62,7 @@
form: {
phone: '',
code: '',
- userType: ''
+ userType: '01'
},
loginToken: '',
isSendCode: false,
diff --git a/policy/applyRecord/applyRecord.vue b/policy/applyRecord/applyRecord.vue
index 1eea770..41a70c4 100644
--- a/policy/applyRecord/applyRecord.vue
+++ b/policy/applyRecord/applyRecord.vue
@@ -2,13 +2,13 @@
<view class="page-box">
<u-sticky bgColor="white">
<view class="set-search">
- <u-search placeholder="璇疯緭鍏ョ敵璇疯褰曞叧閿瘝 " shape="square" :showAction="false"></u-search>
+ <u-search placeholder="璇疯緭鍏ョ敵璇疯褰曞叧閿瘝 " @search="search" @blur="search" shape="square" :showAction="false"></u-search>
</view>
<view class="border"></view>
- <u-tabs :list="list1" @click="click" :scrollable="false" bgColor="white"></u-tabs>
+ <u-tabs :list="list1" @click="click" :current="current" :scrollable="false" bgColor="white"></u-tabs>
</u-sticky>
<view class="list">
- <view class="list-item" @click="goReport">
+ <view class="list-item" @click="goReport" v-for="(item,index) in dataList" :key="index">
<view class="top-title">
<text>24骞�5鏈堢獊鍑绘鏌ユ秷闃插畨鍏�</text>
<text class="status">宸茬粨鏉�</text>
@@ -34,80 +34,53 @@
</view>
</view>
- <view class="list-item">
- <view class="top-title">
- <text>24骞�5鏈堢獊鍑绘鏌ユ秷闃插畨鍏�</text>
- <text class="status">宸茬粨鏉�</text>
- </view>
- <view class="user-info">
- <text>鐜嬫�濋洦</text>
- <view class="driver"></view>
- <text>鎵ф硶涓�澶ч槦</text>
- </view>
- <view class="set-line">
- <text>鎵ф硶瀵硅薄锛�</text>娌冲崡瑙夐啋绉戞妧鏈夐檺鍏徃
- </view>
- <view class="line"></view>
- <view class="set-flex set-start set-flex-content-between">
- <view>
- <view class="set-line1">
- <text>鎵ф硶鏃堕棿锛�</text>2024-05-12 12:00
- </view>
- <view class="set-line1">
- <text>鐢宠鏃堕棿锛�</text>2024-05-12 12:00:12
- </view>
- </view>
-
- </view>
- </view>
- <view class="list-item">
- <view class="top-title">
- <text>24骞�5鏈堢獊鍑绘鏌ユ秷闃插畨鍏�</text>
- <text class="status">宸茬粨鏉�</text>
- </view>
- <view class="user-info">
- <text>鐜嬫�濋洦</text>
- <view class="driver"></view>
- <text>鎵ф硶涓�澶ч槦</text>
- </view>
- <view class="set-line">
- <text>鎵ф硶瀵硅薄锛�</text>娌冲崡瑙夐啋绉戞妧鏈夐檺鍏徃
- </view>
- <view class="line"></view>
- <view class="set-flex set-start set-flex-content-between">
- <view>
- <view class="set-line1">
- <text>鎵ф硶鏃堕棿锛�</text>2024-05-12 12:00
- </view>
- <view class="set-line1">
- <text>鐢宠鏃堕棿锛�</text>2024-05-12 12:00:12
- </view>
- </view>
-
- </view>
- </view>
+ <u-empty v-if="!dataList.length"></u-empty>
</view>
</view>
</template>
<script>
+ import { orderList } from '@/api/policy.js'
export default {
data() {
return {
+ current: 0,
list1: [{
name: '鍏ㄩ儴',
+ value: ''
}, {
name: '寰呭鎵�',
+ value: 1
}, {
name: '寰呮墽琛�',
+ value: 2
}, {
name: '寰呬笂鎶�',
+ value: 3
}, {
name: '宸叉嫆缁�',
+ value: -1
}, {
name: '宸茬粨鏉�',
- }]
+ value: 4
+ }],
+ queryParams: {
+ pageNum: 1,
+ pageSize: 10
+ },
+ total: 1,
+ dataList: []
}
+ },
+ onShow() {
+ this.orderList()
+ },
+ onReachBottom() {
+ if(this.list.length == this.total) {
+ return
+ }
+ this.queryParams.pageNum++
+ this.orderList()
},
methods: {
goReport() {
@@ -115,8 +88,21 @@
url: `/policy/applyRecordDetails/applyRecordDetails`
})
},
- click() {
-
+ click(e) {
+ this.queryParams.pageNum = 1
+ this.current = e.index
+ },
+ orderList() {
+ orderList({...this.queryParams, orderStatus: this.list1[this.current].value}).then(val => {
+ // console.log(val.data)
+ this.total = val.data.total
+ this.dataList = [...this.dataList,...val.data.rows]
+ })
+ },
+ search(e){
+ this.queryParams.pageNum =1
+ this.queryParams.companyName = e
+ this.orderList()
}
}
}
diff --git a/policy/applyRecordDetails/applyRecordDetails.vue b/policy/applyRecordDetails/applyRecordDetails.vue
index d5e093b..95516ee 100644
--- a/policy/applyRecordDetails/applyRecordDetails.vue
+++ b/policy/applyRecordDetails/applyRecordDetails.vue
@@ -8,7 +8,7 @@
<view class="top-content"></view>
<view class="main-page">
<view class="status">
- 宸茬粨鏉�
+ {{mapStatus[details.orderStatus]}}
</view>
<view class="base-card">
<view class="title">
@@ -17,47 +17,43 @@
<view class="view-form">
<view class="view-form-item">
<view class="label">鎵ф硶涓婚</view>
- <view>24骞�5鏈堜唤娑堥槻绐佸嚮妫�鏌�</view>
+ <view>{{details.enforceReason}}</view>
</view>
<view class="view-form-item">
<view class="label">鎵ф硶瀵硅薄</view>
- <view>24骞�5鏈堜唤娑堥槻绐佸嚮妫�鏌�</view>
+ <view>{{details.companyName}}</view>
</view>
<view class="view-form-item">
<view class="label">鎵ф硶鏃堕棿</view>
- <view>24骞�5鏈堜唤娑堥槻绐佸嚮妫�鏌�</view>
- </view>
- <view class="view-form-item">
- <view class="label">鎵ф硶鏃堕棿</view>
- <view>24骞�5鏈堜唤娑堥槻绐佸嚮妫�鏌�</view>
+ <view>{{details.executeTime}}</view>
</view>
<view class="view-form-item">
<view class="label">鎵ф硶绫诲瀷</view>
- <view>24骞�5鏈堜唤娑堥槻绐佸嚮妫�鏌�</view>
+ <view>{{details.enforceTypeName}}</view>
</view>
<view class="view-form-item">
<view class="label">鎵ф硶浜哄憳</view>
- <view>24骞�5鏈堜唤娑堥槻绐佸嚮妫�鏌�</view>
+ <view>{{details.executeUser}}</view>
</view>
<view class="view-form-item">
<view class="label">鎵ф硶閮ㄩ棬</view>
- <view>24骞�5鏈堜唤娑堥槻绐佸嚮妫�鏌�</view>
+ <view>{{details.executeDeptName}}</view>
</view>
<view class="view-form-item">
- <view class="label">闅忚浜哄憳鏁伴噺</view>
- <view>24骞�5鏈堜唤娑堥槻绐佸嚮妫�鏌�</view>
+ <view class="label">闅忚浜哄憳</view>
+ <view>闅忚浜哄憳</view>
</view>
<view class="view-form-item">
<view class="label">鏄惁閫氱煡浼佷笟</view>
- <view>24骞�5鏈堜唤娑堥槻绐佸嚮妫�鏌�</view>
+ <view>{{details.isNoticeCompany == 0 ? '鍚�': '鏄�'}}</view>
</view>
<view class="view-form-item">
<view class="label">鐢宠鏃堕棿</view>
- <view>24骞�5鏈堜唤娑堥槻绐佸嚮妫�鏌�</view>
+ <view>{{details.applyTime}}</view>
</view>
<view class="view-form-item">
<view class="label">褰撳墠鐘舵��</view>
- <view>24骞�5鏈堜唤娑堥槻绐佸嚮妫�鏌�</view>
+ <view>{{mapStatus[details.orderStatus]}}</view>
</view>
</view>
</view>
@@ -66,11 +62,7 @@
<text>鎵ф硶鍐呭</text>
</view>
<view class="view-content">
- 鐏伀鍣ㄤ娇鐢細涓嶅悓绫诲瀷鐨勭伃鐏櫒閫傜敤浜庝笉鍚岀绫荤殑鐏伨锛屽浜屾哀鍖栫⒊鐏伀鍣ㄩ�傜敤浜庡浐浣撱�佹恫浣撱�佹皵浣撳拰甯︾數璁惧鐏伨锛屽共绮夌伃鐏櫒鍚屾牱閫傜敤浜庡绉嶇伀鐏剧被鍨嬨�備娇鐢ㄦ椂搴斿厛鎷旀帀淇濋櫓閿�锛岀劧鍚庣瀯鍑嗙伀鐒版牴閮ㄨ繘琛屽柗灏勩��
- 娑堥槻鏍撲娇鐢細浣跨敤娑堥槻鏍撴椂锛屽簲纭繚鑷冲皯鏈�3浜哄弬涓庯紝鍏朵腑2浜烘彙绱ф按鏋紝1浜鸿礋璐e紑鍚榾闂ㄣ�備娇鐢ㄥ墠搴旀鏌ユ按甯﹀強鎺ュご鏄惁瀹屽ソ锛岄伩鍏嶆壄鎶橈紝骞剁‘淇濇按甯︿笌姘存灙姝g‘杩炴帴銆�
- 闃茬伀鎺柦锛氬寘鎷絾涓嶉檺浜庝笉涔变涪鐑熻拏銆佷笉绉佹媺涔辨帴鐢电嚎銆佷笉瓒呰礋鑽蜂娇鐢ㄧ數鍣ㄣ�佸畾鏈熸鏌ョ數绾垮拰鐢靛櫒璁惧鏄惁鑰佸寲鎴栫牬鎹熴�佸涓笉瀛樻斁鏄撶噧鏄撶垎鐗╁搧绛夈��
- 鐏伨閫冪敓锛氬彂鐢熺伀鐏炬椂锛屽簲杩呴�熷垽鏂伀鍔挎潵婧愶紝閫夋嫨涓庣伀婧愮浉鍙嶇殑鏂瑰悜閫冪敓銆傚垏鍕夸娇鐢ㄧ數姊�冪敓锛屽簲閫氳繃瀹夊叏閫氶亾鎾ょ銆傞�冪敓杩囩▼涓簲淇濇寔浣庡Э鍔匡紝鐢ㄦ箍姣涘肪鎺╂姢鍙i蓟锛屽噺灏戝惛鍏ユ湁姣掔儫闆俱��
- 鎶ヨ鍜岃嚜鏁戯細鍙戠幇鐏儏鍚庯紝搴旂珛鍗虫嫧鎵撯��119鈥濈伀璀︾數璇濇姤璀︼紝骞惰缁嗚鏄庣伀鐏惧湴鐐广�佺伀鍔垮ぇ灏忕瓑淇℃伅銆傚湪绛夊緟鏁戞彺鏃讹紝搴斿敖閲忎繚鎸佸喎闈欙紝閲囧彇姝g‘鐨勮嚜鏁戞帾鏂斤紝濡備娇鐢ㄧ伃鐏櫒銆佹秷闃叉爴绛夈��
+ {{ details.regionReason }}
</view>
</view>
<view class="base-card">
@@ -106,7 +98,7 @@
<image src="https://picsum.photos/200/300" mode="widthFix"></image>
<image src="https://picsum.photos/200/300" mode="widthFix"></image>
<image src="https://picsum.photos/200/300" mode="widthFix"></image>
-
+ <!-- {{regionImgs}} -->
</view>
</view>
<view class="base-card">
@@ -152,14 +144,33 @@
</template>
<script>
+ import {
+ orderDetails
+ } from '@/api/policy.js'
export default {
data() {
return {
-
+ details: {},
+ mapStatus: {
+ 1: '寰呭鎵�',
+ 2: "寰呮墽琛�",
+ 3: "寰呬笂鎶�",
+ '-1':"宸叉嫆缁�",
+ 4: "宸茬粨鏉�"
+ }
}
},
+ onLoad(options) {
+ this.orderDetails(options.id)
+ },
methods: {
-
+ getDetails(orderId) {
+ orderDetails({
+ orderId
+ }).then(val => {
+ this.details = val.data
+ })
+ }
}
}
</script>
diff --git a/policy/components/index.vue b/policy/components/index.vue
index e07a3f0..3df9939 100644
--- a/policy/components/index.vue
+++ b/policy/components/index.vue
@@ -1,6 +1,6 @@
<template>
<view class="page-content">
-
+
<view class="banner">
<image src="/static/head.png" mode=""></image>
</view>
@@ -8,10 +8,11 @@
<view class="second-box">
<image src="/static/hqzc.png" class="icon"></image>
<view class="driver"></view>
- <view class="right-box">
- <view>
- <view class="u-line-1 margin-bottom">娴峰叧鎬荤讲璐告槗鎸佺画鍙戝睍2024骞寸珛娉曞眬...</view>
- <view class="u-line-1">鍥藉鍖荤枟淇濋殰灞�鍔炲叕瀹ゅ叧浜庡彂甯冪鐞�... </view>
+ <view class="right-box" @click="goPolicyList">
+ <view class="article-list">
+ <view class="u-line-1 margin-bottom" v-for="(item, index) in policyList" :key="index">
+ {{item.docTitle}}</view>
+ <!-- <view class="u-line-1">鍥藉鍖荤枟淇濋殰灞�鍔炲叕瀹ゅ叧浜庡彂甯冪鐞�... </view> -->
</view>
<view class="icon-box">
<u-icon name="arrow-right" size="14" color="#868C98FF"></u-icon>
@@ -19,39 +20,59 @@
</view>
</view>
<view class="policy-list">
- <!-- v-if="isJudge" -->
- <image src="/static/policy/zhi1.png" @click="applyPulicy" mode="widthFix"></image>
- <image src="/static/policy/zhi2.png" @click="recordZhifa" mode="widthFix"></image>
- <image src="/static/policy/zhi3.png" @click="report" mode="widthFix"></image>
- <image src="/static/policy/zhi4.png" @click="applyRecord" mode="widthFix"></image>
- <image src="/static/policy/zhi5.png" @click="goDataLook" mode="widthFix"></image>
+ <image src="/static/policy/zhi1.png" v-if="userAuth" @click="applyPulicy" mode="widthFix"></image>
+ <image src="/static/policy/zhi2.png" v-if="isJudge" @click="recordZhifa" mode="widthFix"></image>
+ <image src="/static/policy/zhi3.png" v-if="userAuth" @click="report" mode="widthFix"></image>
+ <image src="/static/policy/zhi4.png" v-if="userAuth" @click="applyRecord" mode="widthFix"></image>
+ <image src="/static/policy/zhi5.png" @click="goDataLook" v-if="userType == '02'" mode="widthFix">
+ </image>
</view>
</view>
</view>
</template>
<script>
- import { getInfo } from '@/api/auth.js'
+ import {
+ getInfo,
+ docList
+ } from '@/api/auth.js'
import tabsCom from '@/policy/components/tabs.vue'
export default {
+ props: {
+ isJudge: {
+ type: Boolean,
+ default: false
+ },
+ userType: {
+ type: String,
+ default: ""
+ },
+ userAuth: {
+ type: Boolean,
+ default: false
+ }
+ },
components: {
tabsCom
},
data() {
return {
- isJudge: false
+ // isJudge: false,
+ policyList: []
}
},
- onShow() {
- this.getInfo()
+ mounted() {
+ // this.getInfo()
+ this.docList()
},
methods: {
- getInfo() {
- getInfo().then(val =>{
- // console.log()
- this.isJudge = val.data.roles.some(item => item.includes('check_enforce'))
- })
- },
+ // getInfo() {
+ // getInfo().then(val =>{
+ // if(val.data.data.roles) {
+ // this.isJudge = val.data.data.roles.some(item => item.includes('check_enforce'))
+ // }
+ // })
+ // },
applyPulicy() {
uni.navigateTo({
url: '/policy/policyApply/policyApply'
@@ -76,26 +97,43 @@
uni.navigateTo({
url: '/policy/translate/translate'
})
+ },
+ // 鍘诲線鎯犱紒鏀跨瓥
+ goPolicyList() {
+ uni.navigateTo({
+ url: `/pages/hqzc/list`
+ })
+ },
+ docList() {
+ docList({
+ pageSize: 2,
+ pageNum: 1
+ }).then(val => {
+ this.policyList = val.data.rows
+ })
}
}
}
</script>
<style lang="scss" scoped>
- .page-content{
- .banner{
+ .page-content {
+ .banner {
width: 100%;
height: 520rpx;
- image{
+
+ image {
width: 100%;
height: 100%;
}
}
- .main-page-box{
+
+ .main-page-box {
position: relative;
top: -60rpx;
}
- .second-box{
+
+ .second-box {
margin: 0 32rpx;
background-color: white;
border-radius: 20rpx;
@@ -103,42 +141,58 @@
display: flex;
justify-content: space-between;
align-items: center;
- .icon{
+
+ .icon {
width: 76rpx;
height: 76rpx;
-
+
}
- .driver{
+
+ .driver {
height: 50rpx;
width: 2rpx;
background-color: #F1F1F1;
margin: 0 24rpx;
}
- .right-box{
+
+ .right-box {
display: flex;
justify-content: space-between;
align-items: center;
width: calc(100% - 76rpx - 50rpx);
font-size: 26rpx;
color: #4A4E60FF;
- .icon-box{
+
+ .article-list {
+ width: 80%;
+ }
+
+ .icon-box {
background-color: #F1F1F1;
border-radius: 50%;
padding: 10rpx;
}
- .margin-bottom{
+
+ .margin-bottom {
margin-bottom: 10rpx;
+ }
+
+ .margin-bottom:last-child {
+ margin-bottom: 0;
}
}
}
- .policy-list{
+
+ .policy-list {
margin: 22rpx 32rpx;
- image{
+
+ image {
width: 100%;
height: 160rpx;
margin-bottom: 20rpx;
}
- image::last-child{
+
+ image::last-child {
margin-bottom: 0;
}
}
diff --git a/policy/components/mine.vue b/policy/components/mine.vue
index 3f95cd8..1fab1b4 100644
--- a/policy/components/mine.vue
+++ b/policy/components/mine.vue
@@ -6,12 +6,12 @@
<image src="/static/policy/header.png" mode="widthFix"></image>
<view class="user-info">
<view class="user-name">
- <view class="inckname">鍒樺皬闆�</view>
+ <view class="inckname">{{userInfo.data.nickName}}</view>
<view class="direc"></view>
<view class="dept-per">鎵ф硶浜哄憳</view>
</view>
<view class="dept-name">
- 鐜繚灞�--绗竴閮ㄩ棬
+ {{userInfo.data.dept.parentName}}
</view>
</view>
</view>
@@ -19,13 +19,14 @@
<view class="main-box">
<view class="show-phone-number">
<text class="label">鑱旂郴鐢佃瘽</text>
- <text>168****4164</text>
+ <text v-if="userInfo.phonenumber">{{userInfo.data.phonenumber.replace(/(\d{3})\d{4}(\d{4})/, "$1****$2")}}</text>
+ <text v-else>鏆傛棤鎵嬫満鍙�</text>
</view>
<view class="show-phone-number" @click="goChangePhone">
<view class="set-flex">
<!-- <u-icon name="phone" size="22"></u-icon> -->
<image src="/static/policy/phone.png" mode="widthFix"></image>
- <text class="change" >淇敼鎵嬫満鍙�</text>
+ <text class="change">淇敼鎵嬫満鍙�</text>
</view>
<u-icon name="arrow-right"></u-icon>
</view>
@@ -38,6 +39,12 @@
<script>
export default {
+ props: {
+ userInfo: {
+ type: Object,
+ default: () => ({})
+ },
+ },
data(){
return {
src: '/static/policy/header.png'
diff --git a/policy/policyApply/perPage.vue b/policy/policyApply/perPage.vue
new file mode 100644
index 0000000..a05d340
--- /dev/null
+++ b/policy/policyApply/perPage.vue
@@ -0,0 +1,87 @@
+<template>
+ <u-popup mode="button" :safeAreaInsetBottom="false" :show="show" @close="close" @open="open" z-index="8000" bgColor="#fff">
+ <view class="bg-box">
+ <view class="title">閫夋嫨闅忚浜哄憳</view>
+ <u-checkbox-group iconPlacement="right" v-model="checkboxValue1" placement="column" @change="checkboxChange">
+ <u-checkbox :customStyle="{marginBottom: '40rpx', }" v-for="(item, index) in checkboxList1" :key="index"
+ :name="item.userId" :label="`${item.dept.deptName}--${item.nickName}`">
+ </u-checkbox>
+ </u-checkbox-group>
+ <view class="set-flex set-flex-content-between">
+ <view class="button-per">
+ <u-button @click="close">鍙栨秷</u-button>
+ </view>
+ <view class="button-per" @click="enteryResult">
+ <u-button color="#1171E0">纭</u-button>
+ </view>
+ </view>
+ </view>
+ </u-popup>
+</template>
+
+<script>
+ export default {
+ props: {
+ list: {
+ type: Array,
+ default: () => []
+ }
+ },
+ data() {
+ return {
+ show: false,
+ checkboxValue1: [],
+ // 鍩烘湰妗堝垪鏁版嵁
+ checkboxList1: [
+ ],
+ }
+
+ },
+ watch: {
+ list: {
+ handler(n) {
+ this.checkboxList1 = n
+ },
+ immediate: true
+ }
+ },
+ methods: {
+ checkboxChange(n) {
+ // console.log('change', n);
+ },
+ close(){
+ this.show = false
+ },
+ open(list) {
+
+ this.show = true
+ },
+ enteryResult() {
+ this.$emit('selectValue', this.checkboxValue1)
+ this.close()
+ console.log(44)
+ }
+ }
+ }
+</script>
+
+<style scoped>
+ .bg-box{
+ position: fixed;
+ bottom: 0;
+ background-color: white;
+ border-radius: 20rpx 20rpx 0 0;
+ padding: 20rpx 32rpx;
+ z-index: 1000000;
+ width: 100%;
+ box-sizing: border-box;
+ }
+ .title{
+ font-size: 36rpx;
+ font-family: 500;
+ margin-bottom: 40rpx;
+ }
+ .button-per{
+ width: 48%;
+ }
+</style>
\ No newline at end of file
diff --git a/policy/policyApply/policyApply.vue b/policy/policyApply/policyApply.vue
index 45e2bb8..49ff902 100644
--- a/policy/policyApply/policyApply.vue
+++ b/policy/policyApply/policyApply.vue
@@ -13,26 +13,26 @@
鎵ф硶瀵硅薄
</view>
<view class="input">
- <input type="text" placeholder="璇疯緭鍏�" v-model="form.companyName"/>
+ <input type="text" placeholder="璇疯緭鍏�" v-model="form.companyName"/>
<!-- <u-icon name="arrow-right"></u-icon> -->
- <u-text text='鎼滅储' type="primary"></u-text>
+ <u-text text='鎼滅储' type="primary" @click="search"></u-text>
</view>
</view>
<view class="form-item">
<view class="form-label require">
鎵ф硶鏃堕棿
</view>
- <view class="input">
- <input type="text" placeholder="璇疯緭鍏�"/>
+ <view class="input" @click="showTimeFun">
+ <input type="text" placeholder="璇疯緭鍏�" disabled v-model="form.planTimeStr"/>
<u-icon name="arrow-right"></u-icon>
</view>
</view>
- <view class="form-item">
+ <view class="form-item" @click="showType = true">
<view class="form-label require">
鎵ф硶绫诲瀷
</view>
<view class="input">
- <input type="text" placeholder="璇疯緭鍏�"/>
+ <input type="text" placeholder="璇疯緭鍏�" v-model="form.enforceTypeName" disabled/>
<u-icon name="arrow-right"></u-icon>
</view>
</view>
@@ -52,19 +52,27 @@
<view class="form-label">
鎵ф硶浜哄憳
</view>
- <input type="text" placeholder="璇疯緭鍏�"/>
+ <input type="text" placeholder="璇疯緭鍏�" v-model="form.applyUser" disabled/>
</view>
<view class="form-item">
<view class="form-label">
鎵ф硶閮ㄩ棬
</view>
- <input type="text" placeholder="璇疯緭鍏�"/>
+ <input type="text" placeholder="璇疯緭鍏�" v-model="form.applyDeptName" disabled/>
</view>
- <view class="form-item">
- <view class="form-label require">
- 闅忚浜哄憳鏁伴噺
+ <view class="form-item sui" style="align-items: flex-start;" @click="openPer">
+ <view class="form-label require ">
+ 闅忚浜哄憳
</view>
- <input type="text" placeholder="璇疯緭鍏�"/>
+ <view>
+ <view style="color: #a2a2a2;" class="placeholder" v-if="!form.peers.length">璇烽�夋嫨</view>
+ <view v-else>
+ <view style="margin-bottom: 20rpx;" v-for="(item,index) in form.peers" :key="index">
+ {{item.peerUser}}({{item.peerDeptName}})
+ </view>
+ </view>
+ </view>
+ <!-- <u-textarea border="none" disabled style="padding: 0;" placeholder="璇烽�夋嫨" ></u-textarea> -->
</view>
<view class="form-item down-2">
<view class="form-label">
@@ -76,7 +84,7 @@
</view>
</view>
<view class="down-options">
- <view class="button record" >鐢宠璁板綍</view>
+ <view class="button record" @click="applyRecord">鐢宠璁板綍</view>
<view class="button submit" @click="submitApply">鎻愪氦鐢宠</view>
</view>
<!-- <u-form label-position="top" label-width="120px">
@@ -115,62 +123,90 @@
<!-- <u-button @click="submitApply">鎻愪氦鐢宠</u-button>
<u-button @click="applyRecord">鐢宠璁板綍</u-button> -->
<u-picker :show="show" @close="show = false" @confirm="confirmSearch" @cancel="show = false" :columns="columns" keyName="companyName"></u-picker>
- <u-datetime-picker
- :show="showTime"
- @close="showTime = false"
- @cancel="showTime = false"
- v-model="currentTime"
- @confirm="confirmTime"
- :minDate="minDate"
- mode="dateTime"
- ref="datetimePicker"
- class="hide-clear-button"
- ></u-datetime-picker>
+ <!-- <u-datetime-picker
+ :show="showTime"
+ @close="showTime = false"
+ @cancel="showTime = false"
+ @confirm="confirmTime"
+ :minDate="minDate"
+ v-model="currentTime"
+ @change="changeValue"
+ mode="datetime"
+ ref="datetimePicker"
+ ></u-datetime-picker> -->
+ <yt-dateTimePicker
+ ref="myPicker"
+ @submit="confirmTime"
+ :start-year="year"
+ :end-year="endYear"
+ :time-init="timeInit"
+ :time-hide="[true, true, true, true, false, false]"
+ />
<u-picker :show="showType" @close="showType = false" @confirm="confirmType" @cancel="showType = false" :columns="columnsType" keyName="dictLabel"></u-picker>
-
+ <perPage :list="list" ref="perpage" @selectValue="selectValue"></perPage>
</view>
</template>
<script>
- import { orderAdd, companyList } from '@/api/policy.js'
+ import { orderAdd, companyList, enforceList } from '@/api/policy.js'
import { getInfo } from '@/api/auth.js'
import { getDicts } from '@/api/data'
+ import perPage from './perPage'
+ import YtDateTimePicker from "uni_modules/yt-dateTimePicker/components/yt-dateTimePicker/yt-dateTimePicker.vue"
export default {
+ components: {
+ YtDateTimePicker,
+ perPage
+ },
data() {
return {
currentTime: "",
form: {
- executeTime: "",
- applyName: '',
+ applyUser: '',
applyDeptName: '',
enforceType: 1,
isNoticeCompany: 0,
- regionReason: ''
+ regionReason: '',
+ planTimeStr: '',
+ peers: []
},
show: false,
columns: [],
showTime: false,
columnsType: [],
showType: false,
- minDate: ''
+ minDate: '',
+ year: '',
+ endYear: '',
+ timeInit: '',
+ list: []
}
},
onLoad() {
- this.currentTime = this.$u.timeFormat(new Date(), 'yyyy-mm-dd hh:MM:ss')
+ this.year = new Date().getFullYear()
+ this.endYear = this.year + 5
+ this.minDate = new Date().valueOf()
+ this.timeInit = this.$u.timeFormat(new Date(), 'yyyy-mm-dd')
this.getInfo()
this.getDicts()
+ this.enforceList()
},
methods: {
+ enforceList() {
+ enforceList().then(val => {
+ this.list = val.data.data
+ })
+ },
getDicts() {
getDicts('enforce_type').then(val =>{
- console.log(val.data.data)
this.columnsType = [val.data.data]
})
},
getInfo() {
getInfo().then(val => {
const value = val.data.data
- this.form.applyName = value.nickName
+ // this.form.applyName = value.nickName
+ this.form.applyUser = value.nickName
this.form.applyId = value.userId
this.form.applyDeptName = value.dept.deptName
this.form.applyDeptId = value.dept.deptId
@@ -194,12 +230,20 @@
submitApply(){
orderAdd(this.form).then(val => {
if(val.data.code == 200) {
- uni.navigateBack()
+ uni.showToast({
+ title: '鎻愪氦鎴愬姛',
+ icon: 'none'
+ })
+ setTimeout(() => {
+ uni.navigateBack()
+ }, 500)
}
})
},
applyRecord() {
-
+ uni.navigateTo({
+ url:`/policy/applyRecord/applyRecord`
+ })
},
search() {
companyList({companyName: this.form.companyName}).then(val => {
@@ -229,13 +273,13 @@
this.show = false
},
confirmTime(e) {
- // console.log(e.value)
- this.form.applyTime = e.value
- this.showTime = false
+ this.form.planTime = e.year + '-' + e.month+ '-' + + e.day + ' ' + e.hour + ":" + "00:00"
+ this.form.planTimeStr = e.year + '-' + e.month+ '-' + + e.day + ' ' + e.hour
},
showTimeFun() {
- this.showTime = true
-
+ // this.showTime = true
+ this.$refs.myPicker.show();
+
},
sheet(){
@@ -244,6 +288,26 @@
this.form.enforceType = e.value[0].dictCode
this.form.enforceTypeName = e.value[0].dictLabel
this.showType = false
+ },
+ changeValue(e, e1) {
+ this.currentTime = e.value
+ },
+ openPer() {
+ this.$refs.perpage.open(this.list)
+ },
+ selectValue(value) {
+ this.list.forEach(item => {
+ if(value.includes(item.userId)) {
+ this.form.peers.push({
+ peerDeptId: item.dept.deptId,
+ peerDeptName: item.dept.deptName,
+ peerId: item.userId,
+ peerPhone: item.phonenumber,
+ peerType: 3,
+ peerUser: item.nickName
+ })
+ }
+ })
}
}
}
@@ -251,6 +315,9 @@
<style>
page{
background-color: #F4F4F4;
+ }
+ .sui .u-textarea{
+ padding: 0 !important;
}
</style>
<style scoped lang="scss">
@@ -323,7 +390,7 @@
padding-bottom: 40rpx;
width: 100%;
padding: 22rpx 30rpx 40rpx;
- z-index: 1000;
+ z-index: 800;
display: flex;
justify-content: space-between;
align-items: center;
@@ -350,5 +417,8 @@
text-align: center;
}
}
+.sui{
+}
+
</style>
diff --git a/policy/policyIndex/policyIndex.vue b/policy/policyIndex/policyIndex.vue
index 0a89f1b..0ad4e1f 100644
--- a/policy/policyIndex/policyIndex.vue
+++ b/policy/policyIndex/policyIndex.vue
@@ -1,7 +1,7 @@
<template>
<view class="padding-bottom">
- <policyIndexVue v-if="activeNumber == 0"></policyIndexVue>
- <minePage v-if="activeNumber == 1"></minePage>
+ <policyIndexVue v-if="activeNumber == 0" :isJudge="isJudge" :userType="userInfo.userType" :userAuth="userAuth"></policyIndexVue>
+ <minePage v-if="activeNumber == 1" :userInfo="userInfo" :roleGroup="roleGroup"></minePage>
<tabsCom :activeNumber.sync="activeNumber"></tabsCom>
</view>
</template>
@@ -20,7 +20,10 @@
data() {
return {
isJudge: false,
- activeNumber: 0
+ activeNumber: 0,
+ userInfo: {},
+ roleGroup: '',
+ userAuth: false
}
},
onShow() {
@@ -29,8 +32,18 @@
methods: {
getInfo() {
getInfo().then(val =>{
- // console.log()
- this.isJudge = val.data.roles.some(item => item.includes('check_enforce'))
+
+ this.userInfo = val.data
+
+ if(val.data.roles) {
+ this.isJudge = val.data.roles.some(item => item.includes('check_enforce'))
+ const value = val.data.roles.filter(item => !item.includes('check_enforce'))
+ if(value.length) {
+ this.userAuth = true
+ } else {
+ this.userAuth = false
+ }
+ }
})
},
applyPulicy() {
diff --git a/static/head.png b/static/head.png
index 642f895..a0b9d2a 100644
--- a/static/head.png
+++ b/static/head.png
Binary files differ
diff --git a/static/i03.png b/static/i03.png
index 76cd63e..7514b15 100644
--- a/static/i03.png
+++ b/static/i03.png
Binary files differ
diff --git a/static/i04.png b/static/i04.png
index ea3e4f2..bcd24bf 100644
--- a/static/i04.png
+++ b/static/i04.png
Binary files differ
diff --git a/static/policy/back.png b/static/policy/back.png
index 3e08f69..a7dd443 100644
--- a/static/policy/back.png
+++ b/static/policy/back.png
Binary files differ
diff --git a/static/policy/qrcode-border.png b/static/policy/qrcode-border.png
index fedbe51..21e930b 100644
--- a/static/policy/qrcode-border.png
+++ b/static/policy/qrcode-border.png
Binary files differ
diff --git a/static/policy/zhi1.png b/static/policy/zhi1.png
index 6727715..6dfb7db 100644
--- a/static/policy/zhi1.png
+++ b/static/policy/zhi1.png
Binary files differ
diff --git a/static/policy/zhi2.png b/static/policy/zhi2.png
index 8d89f6c..90d0231 100644
--- a/static/policy/zhi2.png
+++ b/static/policy/zhi2.png
Binary files differ
diff --git a/static/policy/zhi3.png b/static/policy/zhi3.png
index 2203666..f48394c 100644
--- a/static/policy/zhi3.png
+++ b/static/policy/zhi3.png
Binary files differ
diff --git a/static/policy/zhi4.png b/static/policy/zhi4.png
index b84a45a..48b547f 100644
--- a/static/policy/zhi4.png
+++ b/static/policy/zhi4.png
Binary files differ
diff --git a/static/policy/zhi5.png b/static/policy/zhi5.png
index d93d97d..7b8f0a3 100644
--- a/static/policy/zhi5.png
+++ b/static/policy/zhi5.png
Binary files differ
diff --git a/uni_modules/yt-dateTimePicker/changelog.md b/uni_modules/yt-dateTimePicker/changelog.md
new file mode 100644
index 0000000..ad3546b
--- /dev/null
+++ b/uni_modules/yt-dateTimePicker/changelog.md
@@ -0,0 +1,92 @@
+## 1.2.2锛�2024-04-18锛�
+璇存槑鏂囨。
+## 1.2.1锛�2024-04-18锛�
+淇璇存槑鏂囨。
+## 1.2.0锛�2024-04-18锛�
+鏀规绉掓墦鍗颁笉鍑烘潵鐨勯棶棰�
+## 1.1.9锛�2024-01-11锛�
+淇敼榛樿鍊艰鏄庢枃妗�
+## 1.1.8锛�2024-01-11锛�
+淇敼榛樿鏃堕棿绌垮弬鏂瑰紡
+## 1.1.7锛�2023-11-07锛�
+淇敼绀轰緥閾炬帴
+## 1.1.6锛�2023-11-07锛�
+澧炲姞绀轰緥閾炬帴
+## 1.1.5锛�2023-11-06锛�
+鎬庡姞鑱旂郴鏂瑰紡
+## 1.1.4锛�2023-11-06锛�
+鏍囩淇敼
+## 1.1.3锛�2023-11-06锛�
+浠嬬粛淇敼
+## 1.1.2锛�2023-11-06锛�
+鍚嶇О淇敼
+## 1.1.0锛�2023-11-06锛�
+鏃堕棿閫夋嫨
+## 1.0.9锛�2023-11-06锛�
+淇敼bug
+## 1.0.8锛�2023-11-06锛�
+涓婁紶绀轰緥椤圭洰
+## 1.0.7锛�2023-11-06锛�
+鍒犻櫎鍥剧墖
+## 1.0.6锛�2023-11-06锛�
+淇敼璇存槑鏂囨。
+## 1.0.5锛�2023-11-04锛�
+鏇存柊璇存槑鏂囨。
+## 1.0.4\5锛�2023-11-04锛�
+鏇存柊璇存槑鏂囨。
+## 1.0.4\5锛�2023-11-04锛�
+鏇存柊璇存槑鏂囨。
+## 1.0.4\5锛�2023-11-04锛�
+鏇存柊璇存槑鏂囨。
+## 1.0.4锛�2023-11-03锛�
+淇敼bug
+## 1.0.3锛�2023-11-03锛�
+鏇存柊浣跨敤璇存槑
+## 1.0.2锛�2023-11-03锛�
+淇bug
+## 1.0.1锛�2023-11-03锛�
+淇敼鍙橀噺鍚�
+## 1.0.0锛�2023-11-03锛�
+淇鏃堕棿鍥炴樉闂
+# CHANGELOG
+## 0.7.0锛�2023-07-11锛�
+- 澧炲姞`time-init`灞炴��, 鑷畾涔夊垵濮嬫椂闂�, 榛樿涓哄綋鍓嶆椂闂�, 鍊间负鏃堕棿鎴�
+## 0.6.0锛�2023-07-11锛�
+
+- 澧炲姞瀵圭鐨勯�夋嫨
+- 澧炲姞`timeHidden`灞炴��, 鑷畾涔夊勾鏈堟棩鏃跺垎绉掕嚜鐢辨樉绀�
+- 澧炲姞`timeLabel`灞炴��, 鑷畾涔夌晫闈㈡椂闂村崟浣嶏紝榛樿涓� `["骞�", "鏈�", "鏃�", "鏃�", "鍒�", "绉�"]`
+- 淇寰俊灏忕▼搴忎腑鏃犳硶瀹氫綅鍒板綋鍓嶆椂闂�
+
+## 0.5.0锛�2021-08-17锛�
+
+- refactor
+
+## 0.4.1锛�2021-08-17锛�
+
+- update readme.md
+
+## 0.4.0锛�2021-08-17锛�
+
+- 绉婚櫎缁勪欢 `color` 灞炴��
+- update readme.md
+
+## 0.3.3锛�2021-08-15锛�
+
+- 淇敼鎻掍欢鍩烘湰淇℃伅
+
+## 0.3.2锛�2021-08-15锛�
+
+- 鏇存柊鏂囨。
+
+## 0.3.1锛�2021-08-15锛�
+
+- fix
+
+## 0.3.0锛�2019-07-22锛�
+
+- 澧炲姞 color 灞炴�э紝鍙互鏇存崲鎸夐挳棰滆壊
+
+## 0.0.4锛�2019-07-17锛�
+
+- 澧炲姞浠� npm 瀹夎鏂瑰紡
diff --git a/uni_modules/yt-dateTimePicker/components/yt-dateTimePicker/yt-dateTimePicker.vue b/uni_modules/yt-dateTimePicker/components/yt-dateTimePicker/yt-dateTimePicker.vue
new file mode 100644
index 0000000..4e32bc2
--- /dev/null
+++ b/uni_modules/yt-dateTimePicker/components/yt-dateTimePicker/yt-dateTimePicker.vue
@@ -0,0 +1,339 @@
+<template>
+ <view class="yt-dateTimePicker" v-if="done">
+ <view class="mask" :class="{ show: open }" @touchmove.stop.prevent catchtouchmove="true">
+ </view>
+ <view class="wrap" :class="{ show: open }">
+ <view class="picker-header" @touchmove.stop.prevent catchtouchmove="true">
+ <view class="btn-picker cancel" @click="open = false">鍙栨秷</view>
+ <view class="btn-picker submit" @click="_onSubmit">纭畾</view>
+ </view>
+ <view class="picker-body">
+ <picker-view :value="value" @change="_onChange">
+ <picker-view-column :disable-flicking="true" v-if="timeHide[0]">
+ <view class="column-item" v-for="item in years" :key="item">
+ {{ item + timeLabel[0] }}
+ </view>
+ </picker-view-column>
+ <picker-view-column :disable-flicking="true" v-if="timeHide[1]">
+ <view class="column-item" v-for="item in months" :key="item">
+ {{ formatNum(item) + timeLabel[1] }}
+ </view>
+ </picker-view-column>
+ <picker-view-column :disable-flicking="true" v-if="timeHide[2]">
+ <view class="column-item" v-for="item in days" :key="item">
+ {{ formatNum(item) + timeLabel[2] }}
+ </view>
+ </picker-view-column>
+ <picker-view-column :disable-flicking="true" v-if="timeHide[3]">
+ <view class="column-item" v-for="item in hours" :key="item">
+ {{ formatNum(item) + timeLabel[3] }}
+ </view>
+ </picker-view-column>
+ <picker-view-column :disable-flicking="true" v-if="timeHide[4]">
+ <view class="column-item" v-for="item in minutes" :key="item">
+ {{ formatNum(item) + timeLabel[4] }}
+ </view>
+ </picker-view-column>
+ <picker-view-column :disable-flicking="true" v-if="timeHide[5]">
+ <view class="column-item" v-for="item in seconds" :key="item">
+ {{ formatNum(item) + timeLabel[5] }}
+ </view>
+ </picker-view-column>
+ </picker-view>
+ </view>
+ </view>
+ </view>
+</template>
+
+<script>
+ export default {
+ name: "yt-dateTimePicker",
+ props: {
+ startYear: {
+ type: Number,
+ default: 2000,
+ },
+ endYear: {
+ type: Number,
+ default: 2099,
+ },
+ timeLabel: {
+ type: Array,
+ default: () => ["骞�", "鏈�", "鏃�", "鏃�", "鍒�", "绉�"],
+ },
+ timeHide: {
+ type: Array,
+ default: () => [true, true, true, true, true, true],
+ },
+ timeInit: {
+ type: String,
+ default: '', //new Date('2023-5-20').valueOf()
+ },
+ },
+
+ data() {
+ return {
+ open: false,
+ years: [],
+ months: [],
+ days: [],
+ hours: [],
+ minutes: [],
+ seconds: [],
+ year: "",
+ month: "",
+ day: "",
+ hour: "",
+ minute: "",
+ second: "",
+ value: [0, 0, 0, 0, 0, 0],
+ done: false,
+ };
+ },
+
+ computed: {
+ currentDatetime() {
+ return this.timeInit ? new Date(new Date(`${this.timeInit}`).valueOf()) : new Date(new Date().valueOf());
+ },
+ },
+
+ mounted() {
+ this.init();
+ },
+
+ watch: {
+ month() {
+ this.initDays();
+ },
+ },
+
+ methods: {
+ init() {
+ this.initYears();
+ this.initMonths();
+ this.initDays();
+ this.initHours();
+ this.initMinutes();
+ this.initSeconds();
+ this.setSelectValue();
+ this.done = true;
+ },
+
+ initYears() {
+ const years = [];
+ for (let year = this.startYear; year <= this.endYear; year++) {
+ years.push(year);
+ if (this.currentDatetime.getFullYear() === year) {
+ this.$set(this.value, 0, year - this.startYear);
+ }
+ }
+ this.years = years;
+ },
+
+ initMonths() {
+ const months = [];
+ for (let month = 1; month <= 12; month++) {
+ months.push(month);
+ if (this.currentDatetime.getMonth() + 1 === month) {
+ this.$set(this.value, 1, month - 1);
+ }
+ }
+ this.months = months;
+ },
+
+ initDays() {
+ const value = this.value;
+ const selectedYear = this.years[value[0]];
+ const selectedMonth = this.months[value[1]];
+ const days = [];
+ const totalDays = new Date(selectedYear, selectedMonth, 0).getDate();
+ for (let day = 1; day <= totalDays; day++) {
+ days.push(day);
+ if (this.currentDatetime.getDate() === day) {
+ this.$set(value, 2, day - 1);
+ }
+ }
+ this.days = days;
+ },
+
+ initHours() {
+ const hours = [];
+ for (let hour = 0; hour <= 23; hour++) {
+ hours.push(hour);
+ if (this.currentDatetime.getHours() === hour) {
+ this.$set(this.value, 3, hour);
+ }
+ }
+ this.hours = hours;
+ },
+
+ initMinutes() {
+ const minutes = [];
+ for (let minute = 0; minute < 60; minute++) {
+ minutes.push(minute);
+ if (this.currentDatetime.getMinutes() === minute) {
+ this.$set(this.value, 4, minute);
+ }
+ }
+ this.minutes = minutes;
+ },
+
+ initSeconds() {
+ const seconds = [];
+ for (let second = 0; second < 60; second++) {
+ seconds.push(second);
+ if (this.currentDatetime.getSeconds() === second) {
+ this.$set(this.value, 5, second);
+ }
+ }
+ this.seconds = seconds;
+ },
+
+ show() {
+ this.init();
+ this.open = true;
+ },
+
+ hide() {
+ this.open = false;
+ },
+
+ _onChange(e) {
+ this.value = e.detail.value;
+ this.setSelectValue();
+ },
+
+ setSelectValue() {
+ const v = this.value;
+ this.year = this.years[v[0]];
+ this.month = this.months[v[1]];
+ this.day = this.days[v[2]];
+ this.hour = this.hours[v[3]];
+ this.minute = this.minutes[v[4]];
+ this.second = this.seconds[v[5]];
+ },
+
+ _onSubmit() {
+ const {
+ year,
+ month,
+ day,
+ hour,
+ minute,
+ second,
+ formatNum,
+ timeHide,
+ timeLabel,
+ } = this;
+ const result = {
+ year: timeHide[0] ? formatNum(year) : "",
+ month: timeHide[1] ? formatNum(month) : "",
+ day: timeHide[2] ? formatNum(day) : "",
+ hour: timeHide[3] ? formatNum(hour) : "",
+ minute: timeHide[4] ? formatNum(minute) : "",
+ second: timeHide[5] ? formatNum(second) : "",
+ };
+ this.$emit("submit", result);
+ this.hide();
+ },
+
+ formatNum(num) {
+ return num < 10 ? "0" + num : num + "";
+ },
+ },
+ };
+</script>
+
+<style lang="scss">
+ $transition: all 0.3s ease;
+ $primary: #1171E0;
+
+ .yt-dateTimePicker {
+ position: relative;
+ z-index: 999;
+
+ picker-view {
+ height: 100%;
+ }
+
+ .mask {
+ position: fixed;
+ z-index: 1000;
+ top: 0;
+ right: 0;
+ bottom: 0;
+ left: 0;
+ background-color: rgba(0, 0, 0, 0.4);
+ visibility: hidden;
+ opacity: 0;
+ transition: $transition;
+
+ &.show {
+ visibility: visible;
+ opacity: 1;
+ }
+ }
+
+ .wrap {
+ z-index: 1001;
+ position: fixed;
+ bottom: 0;
+ left: 0;
+ width: 100%;
+ transition: $transition;
+ transform: translateY(100%);
+
+ &.show {
+ transform: translateY(0);
+ }
+ }
+
+ .picker-header {
+ display: flex;
+ flex-direction: row;
+ justify-content: space-between;
+ align-items: center;
+ padding: 8px 8px;
+ background-color: darken(#fff, 2%);
+ background-color: #fff;
+ }
+
+ .picker-body {
+ width: 100%;
+ height: 420rpx;
+ overflow: hidden;
+ background-color: #fff;
+ }
+
+ .column-item {
+ text-overflow: ellipsis;
+ white-space: nowrap;
+ display: flex;
+ justify-content: center;
+ align-items: center;
+ }
+
+ .btn-picker {
+ position: relative;
+ display: inline-block;
+ padding-left: 10px;
+ padding-right: 10px;
+ box-sizing: border-box;
+ text-align: center;
+ text-decoration: none;
+ line-height: 2;
+ -webkit-tap-highlight-color: transparent;
+ overflow: hidden;
+ background-color: #eee;
+ font-size: 14px;
+ border-radius: 3px;
+ color: #000;
+ cursor: pointer;
+ }
+
+ .btn-picker.submit {
+ background-color: $primary;
+ color: #fff;
+ }
+ }
+</style>
\ No newline at end of file
diff --git a/uni_modules/yt-dateTimePicker/package.json b/uni_modules/yt-dateTimePicker/package.json
new file mode 100644
index 0000000..53bbbd9
--- /dev/null
+++ b/uni_modules/yt-dateTimePicker/package.json
@@ -0,0 +1,76 @@
+{
+ "id": "yt-dateTimePicker",
+ "displayName": "鏃ユ湡鏃堕棿閫夋嫨鍣紙瓒呯骇濂界敤锛夎嚜甯︽粦鍔ㄩ煶鏁�",
+ "version": "1.2.2",
+ "description": "杩欎釜閫夋嫨鍣ㄥ厑璁哥敤鎴烽�夋嫨骞淬�佹湀銆佹棩銆佹椂銆佸垎鍜岀锛屾彁渚涗簡涓板瘜鐨勬牱寮忓拰閰嶇疆閫夐」銆傞�氳繃璁剧疆璧峰鏃堕棿鍜岀粨鏉熸椂闂磋寖鍥达紝鐢ㄦ埛鍙互鏂逛究鍦拌繘琛岀簿鍑嗙殑鏃ユ湡鍜屾椂闂撮�夋嫨銆傛槸寮�鍙憉ni-app搴旂敤绋嬪簭鐨勭悊鎯抽�夋嫨涔嬩竴锛�",
+ "keywords": [
+ "鏃堕棿",
+ "鏃ユ湡",
+ "骞存湀鏃�",
+ "鏃堕棿閫夋嫨鍣�",
+ "鏃ユ湡鏃堕棿閫夋嫨鍣�"
+],
+ "repository": "",
+"engines": {
+ },
+"dcloudext": {
+ "sale": {
+ "regular": {
+ "price": "0.00"
+ },
+ "sourcecode": {
+ "price": "0.00"
+ }
+ },
+ "contact": {
+ "qq": "3190136675"
+ },
+ "declaration": {
+ "ads": "鏃�",
+ "data": "鏃�",
+ "permissions": "鏃�"
+ },
+ "npmurl": "",
+ "type": "component-vue"
+ },
+ "uni_modules": {
+ "dependencies": [],
+ "encrypt": [],
+ "platforms": {
+ "cloud": {
+ "tcb": "y",
+ "aliyun": "y"
+ },
+ "client": {
+ "App": {
+ "app-vue": "y",
+ "app-nvue": "u"
+ },
+ "H5-mobile": {
+ "Safari": "y",
+ "Android Browser": "y",
+ "寰俊娴忚鍣�(Android)": "y",
+ "QQ娴忚鍣�(Android)": "y"
+ },
+ "H5-pc": {
+ "Chrome": "y",
+ "IE": "n",
+ "Edge": "y",
+ "Firefox": "y",
+ "Safari": "y"
+ },
+ "灏忕▼搴�": {
+ "寰俊": "y",
+ "闃块噷": "u",
+ "鐧惧害": "u",
+ "瀛楄妭璺冲姩": "u",
+ "QQ": "u"
+ },
+ "蹇簲鐢�": {
+ "鍗庝负": "u",
+ "鑱旂洘": "u"
+ }
+ }
+ }
+ }
+}
diff --git a/uni_modules/yt-dateTimePicker/readme.md b/uni_modules/yt-dateTimePicker/readme.md
new file mode 100644
index 0000000..6711f7f
--- /dev/null
+++ b/uni_modules/yt-dateTimePicker/readme.md
@@ -0,0 +1,85 @@
+# uniApp 绠�鍗曠殑鏃ユ湡鏃堕棿閫夋嫨鍣�
+
+uniApp 鏃ユ湡鏃堕棿閫夋嫨鍣�, 鍙�夋嫨骞�, 鏈�, 鏃�, 鏃�, 鍒�, 绉�.
+
+
+## 绀轰緥閾炬帴
+
+[璁$畻浣犳潵鍒拌繖涓笘鐣屽灏戝ぉ浜哴(https://tinyurl.com/yangtao-age)
+
+## 婕旂ず鏁堟灉鍥�
+
+<p>
+ <img align=top src="https://7072-prod-4gapv4gl33a8a0ff-1305990777.tcb.qcloud.la/%E9%87%8D%E8%A6%81%E5%9B%BE%E7%89%87%E5%AD%98%E5%82%A8/uniappcj.png?sign=67f6bd2b9d1e5f5bbdecc5ffdf9b923d&t=1699237042" width="500px" height="auto">
+</p>
+
+
+## 鐢ㄦ硶
+
+鍦� template 涓細
+
+```vue
+<template>
+ <view>
+ <button type="default" @click="openDatetimePicker">鏃堕棿閫夋嫨</button>
+ <yt-dateTimePicker
+ ref="myPicker"
+ @submit="handleSubmit"
+ :start-year="2000"
+ :end-year="2099"
+ time-init="2023-5-20"
+ :time-hide="[true, true, true, true, true, false]"
+ :time-label="['骞�', '鏈�', '鏃�', '鏃�', '鍒�', '绉�']"
+ />
+ </view>
+</template>
+```
+
+鍦� script 涓細
+
+- 璇ユ彃浠堕伒寰� easycom 瑙勮寖, 涓嶇敤鏄惧紡瀵煎叆灏卞彲浠ヤ娇鐢� `<yt-dateTimePicker />`
+- 濡傞渶鎸夐渶瀵煎叆鍙互浣跨敤`import YtDateTimePicker from "uni_modules/yt-dateTimePicker/components/yt-dateTimePicker/yt-dateTimePicker.vue";`
+
+```javascript
+export default {
+ data() {
+ return {
+ birthday: "",
+ };
+ },
+ methods: {
+ // 鎵撳紑picker
+ openDatetimePicker() {
+ this.$refs.myPicker.show();
+ },
+
+ // 鍏抽棴picker
+ closeDatetimePicker() {
+ this.$refs.myPicker.hide();
+ },
+
+ handleSubmit(e) {
+ this.birthday = `${e.year}-${e.month}-${e.day} ${e.hour}:${e.minute}:${e.second}`;
+ },
+ },
+};
+```
+
+> Note: 涓嶈鎶婄粍浠舵斁 swiper 閲岄潰鎴栬�� v-for 閲岄潰绛�, 鏈�濂芥斁鍦ㄩ〉闈㈡牴閮�. 閫氬父鎯呭喌涓嬫墦寮� picker 闇�瑕佽皟鐢╜this.$refs.refName.show()`, 鍦ㄩ�夋嫨瀹屾瘯鍚� picker 浼氳嚜鍔ㄩ殣钘忥紝涓嶉渶瑕佽皟鐢╜this.$refs.refName.hide()`鏉ユ墜鍔ㄩ殣钘忋��
+
+## 灞炴�ц鏄�
+
+| 灞炴�� | 鏄惁蹇呭~ | 鍊肩被鍨� | 榛樿鍊� | 璇存槑 |
+| --------- | -------- | -----: | --: | :------------:|
+| start-year| 鏄� | Number |2000 | 閫夋嫨寮�濮嬪勾浠� |
+| end-year | 鏄� | Number |2099 | 閫夋嫨缁撴潫骞翠唤 |
+| time-init | 鍚� | String |2023-5-20| 鑷畾涔夊垵濮嬫椂闂�, 榛樿涓哄綋鍓嶆椂闂� |
+| time-hidden| 鏄� | Array |[true, true, true, true, true, true]| 鑷畾涔夋椂闂村垪鏄剧ず锛岄粯璁ゆ樉绀哄勾鏈堟棩鏃ュ垎 |
+| time-label| 鍚� | Array |['骞�', '鏈�', '鏃�', '鏃�', '鍒�', '绉�'] | 鑷畾涔夊悇涓椂闂村崟浣� |
+| @submit | 鍚� | Function |Object | 鐩戝惉閫夋嫨浜嬩欢, 鍥炶皟鍑芥暟鐨勭涓�涓弬鏁板寘鍚簡閫夋嫨鏃堕棿鐨勫畬鏁翠俊鎭瘄
+
+| `QQ浜ゆ祦缇�(906392632)` |
+
+|<p><img align=top src="https://7072-prod-4gapv4gl33a8a0ff-1305990777.tcb.qcloud.la/%E9%87%8D%E8%A6%81%E5%9B%BE%E7%89%87%E5%AD%98%E5%82%A8/Snipaste_2023-11-06_16-50-56.png?sign=ed27f09cfeabb33e24835fecdd4108db&t=1699260686" width="500px" height="auto"></p>|
+| QQ缇ゅ彿锛�906392632 |
+
--
Gitblit v1.9.1