Bladeren bron

失信人员

shish 1 jaar geleden
bovenliggende
commit
d748f7038c

+ 55 - 20
hdApp/src/admin/ll/add.vue

@@ -1,6 +1,6 @@
 <template>
   <view class="app-content">
-    <form @submit="commitForm">
+    <form @submit="confirmFn">
       <view class="module-com input-line-wrap">
 
         <tui-list-cell class="line-cell" :hover="false">
@@ -25,7 +25,10 @@
 
         <tui-list-cell class="line-cell" :hover="false">
           <view class="tui-title required">欠款日期</view>
-          <input v-model="form.date" placeholder-class="phcolor" class="tui-input" name="date" placeholder="欠款日期" maxlength="50" type="text" />
+          
+          <view class="uni-input" v-if="form.date==''" style="color:#CCCCCC;width:500upx;" @click="changeDate">请选择日期</view>
+          <view class="uni-input" @click="changeDate" style="width:500upx;">{{form.date}}</view>
+
         </tui-list-cell>
 
         <tui-list-cell class="line-cell" :hover="false">
@@ -50,7 +53,7 @@
       <view class="module-com input-line-wrap summary-wrap">
         <view class="module-tit">其他说明</view>
         <view class="module-det" style="padding-bottom: 20upx">
-          <textarea v-model="form.briefContent" class="goods-summary" placeholder-class="phcolor" placeholder="补充说明" />
+          <textarea v-model="form.intro" class="goods-summary" placeholder-class="phcolor" placeholder="补充说明" />
         </view>
       </view>
 
@@ -60,6 +63,9 @@
       </view>
 
     </form>
+
+    <mx-date-picker :show="showPicker" format="yyyy-mm-dd" type="date" :value="defaultPickerDate" :show-tips="true" @confirm="confirmPicker" @cancel="showPicker = false" />
+
   </view>
 </template>
 <script>
@@ -67,14 +73,17 @@ import { mapGetters } from "vuex";
 import TuiListCell from "@/components/plugin/list-cell";
 import AppUploader from "@/components/app-uploader";
 const form = require("@/utils/formValidation.js");
-import { addGoodsData } from "@/api/goods"
+import { addEvent } from "@/api/ll"
 import htzImageUpload from '@/components/htz-image-upload/htz-image-upload.vue'
+import MxDatePicker from '@/components/mx-datepicker/mx-datepicker.vue';
 export default {
   name: "add",
-  components: { TuiListCell, AppUploader,htzImageUpload },
+  components: { TuiListCell, AppUploader,htzImageUpload,MxDatePicker },
 	mixins: [],
   data() {
     return {
+			defaultPickerDate:'',
+			showPicker: false,
       headers:{token:''},
       form: {
         name: "",
@@ -82,7 +91,9 @@ export default {
         mobile:"",
         amount: "",
         date:"",
-        no:""
+        no:"",
+        prove: [],
+        intro:''
       },
       currentImgData:[]
     };
@@ -92,45 +103,69 @@ export default {
     this.headers.token = token
   },
   methods: {
+    changeDate(){
+			this.showPicker = true
+    },
+		confirmPicker(e) {
+			this.form.date = e.value
+      this.showPicker = false
+		},
     goBack(){
       uni.navigateBack({delta:1})
     },
     imgDeleteFn(res){
       const index = res.index
-      this.form.shopImg.splice(index,1)
+      this.form.prove.splice(index,1)
     },
     imgUploadSuccess(res) {
       var _res = JSON.parse(res.data)
       if(_res.code == 1){
         this.currentImgData.push(_res.data.smallUrl)
-        this.form.shopImg.push(_res.data.shortUrl)
+        this.form.prove.push(_res.data.shortUrl)
       }
     },
     init() {
 
     },
-    confirmFn() {
+    confirmFn(){
       let that = this
-      if (this.$util.isEmpty(this.form.shopImg)) {
-        this.$msg("请上传图片");
+      if (this.$util.isEmpty(this.form.name)){
+        this.$msg('请填写店名或姓名')
+        return false
+      }
+      if (this.$util.isEmpty(this.form.mobile) && this.$util.isEmpty(this.form.wx) && this.$util.isEmpty(this.form.no)){
+        this.$msg('手机号、微信号或身份证号必填一项')
+        return false
+      }
+      if(!this.$util.isEmpty(this.form.mobile)){
+        if(this.$util.checkMobile(this.form.mobile) == false){
+          this.$msg('请填写正确手机号')
+          return false
+        }
+      }
+      if (this.$util.isEmpty(this.form.date)){
+        this.$msg('请填写日期')
+        return false
+      }
+      if (this.$util.isEmpty(this.form.amount) || Number(this.form.amount)<=0){
+        this.$msg('请填写金额')
+        return false
+      }
+      if (this.$util.isEmpty(this.form.prove)) {
+        this.$msg("请上传证据,最少一张");
         return false;
       }
-      this.form.cover = this.form.shopImg[0]
-
       that.$util.confirmModal({content:'确认添加?提交后不可修改'},() => {
         uni.showLoading({mask:true})
-        let form = JSON.parse(JSON.stringify(this.form));
-        addGoodsData({...form,itemList:JSON.stringify(product) }).then(res => {
+        console.log(this.form)
+        addEvent(this.form).then(res => {
           uni.hideLoading()
           this.$msg("添加成功")
           setTimeout(function(){
-            uni.navigateBack({})
-          },1500)
+            uni.navigateBack()
+          },1200)
         })
       })
-    },
-    commitForm(e) {
-      this.confirmFn()
     }
   }
 };

+ 10 - 8
hdApp/src/admin/ll/components/user.vue

@@ -3,7 +3,7 @@
         <view class="order-top_box" style="position:relative;">
           <image style="width:130upx;position:absolute;top:110upx;right:25upx;border-radius:10upx;" mode="widthFix" :src="item.cover"></image>
           <view class="tit">{{ item.name }}</view>
-          <view style="color:#666666;">--</view>
+          <view style="color:#666666;"></view>
         </view>
         <view class="order-list_info">
             <view class="order-info_box">
@@ -27,13 +27,13 @@
                 <view>¥{{ item.breakAmount }}</view>
             </view>
             <view class="order-info_box">
-                <view>首次失信:</view>
-                <view>{{ item.firstDate }}</view>
+                <view>最近失信:</view>
+                <view>{{ item.lastDate }}</view>
             </view>
         </view>
         <view class="list-bottom">
             <view class="list-button">
-                <button class="admin-button-com bule">分享</button>
+                <button class="admin-button-com bule" @click.stop="share">分享</button>
             </view>
         </view>
     </view>
@@ -53,7 +53,9 @@ export default {
 		};
 	},
 	methods: {
-
+    share(){
+      this.$msg('开发中')
+    }
 	}
 };
 </script>
@@ -80,7 +82,7 @@ export default {
   & > .tit {
     flex: 8;
     color: #333333;
-    font-size: 30upx;
+    font-size:32upx;
     font-weight: 650;
     margin-left:2upx;
   }
@@ -136,9 +138,9 @@ export default {
   & > .order-info_box {
     display: flex;
     align-items: center;
-    font-size: 26upx;
+    font-size: 31upx;
     font-weight: 400;
-    margin-bottom: 5upx;
+    margin-bottom:10upx;
     & > view:nth-child(1) {
       color: #999999;
     }

+ 5 - 41
hdApp/src/admin/ll/detail.vue

@@ -7,14 +7,11 @@
 			<view class="bills-info_box content-box">
 				<view class="order-info_box">
 					<view>制单日期:</view>
-					<view>{{ detailInfo.addTime.substr(5,11) }}</view>
+					<view></view>
 				</view>
 				<view class="order-info_box">
 					<view>制单编号:</view>
 					<view>{{ detailInfo.orderSn }}</view>
-					<view class="price">
-						<button @click="copy(detailInfo.orderSn)" class="admin-button-com default">复制</button>
-					</view>
 				</view>
 				<view class="order-info_box" v-if="detailInfo.status==1">
 					<view>制作人员:</view>
@@ -94,24 +91,21 @@
 			</view>
 		</view>
 		<div class="app-footer">
-			<button class="admin-button-com bule" v-if="detailInfo.status == 1" @click="printWork(detailInfo)">打印</button>
-			<button class="admin-button-com default" v-else>打印</button>
-			<button class="admin-button-com bule" v-if="detailInfo.status == 0" @click="cancelFn(detailInfo)">取消</button>
-			<button class="admin-button-com default" v-else>取消</button>
+			<button class="admin-button-com bule" @click="">打印</button>
 		</div>
 	</view>
 </template>
 <script>
 import { mapGetters } from "vuex";
 import TuiListCell from "@/components/plugin/list-cell";
-import { fullInfo,cancelWork,print } from "@/api/work/index";
+import { getUserDetail } from "@/api/ll";
 export default {
 	name: "detail",
 	components: { TuiListCell },
 	mixins: [],
 	data() {
 		return {
-			detailInfo: {addTime:''},
+			detailInfo:{},
 			workItem:[],
 			goodsInfo:[]
 		};
@@ -120,43 +114,13 @@ export default {
 		this.init().then(res => {
 			uni.stopPullDownRefresh()
 		})
-	},
-	onShow() {
-
 	},
 	computed: {
 		...mapGetters({ loginInfo: "getLoginInfo" }),
 	},
 	methods: {
-		printWork(item){
-			print({id:item.id}).then(res=>{
-				if(res.code == 1){
-					this.$msg(res.msg)
-				}
-			})
-		},
-		cancelFn(item){
-			let that = this
-			that.$util.confirmModal({content:'确认取消?'},() => {
-				cancelWork({id:item.id}).then(res=>{
-					if(res.code == 1){
-						item.status = 2
-						that.$msg('取消成功')
-					}
-				})
-			})
-		},
-		copy(val) {
-			const self = this;
-			uni.setClipboardData({
-				data: val,
-				success: function() {
-					self.$msg("复制成功");
-				}
-			});
-		},
 		async init() {
-			const res = await fullInfo({ id: this.option.id })
+			const res = await getUserDetail({ id: this.option.id })
 			this.detailInfo = res.data.info;
 			this.workItem = res.data.item
 			this.goodsInfo = res.data.goods

+ 9 - 3
hdApp/src/admin/ll/list.vue

@@ -1,6 +1,6 @@
 <template>
     <view class="app-main app-content">
-      <view style="width:100%;font-size:38upx;font-weight:bold;text-align: center;padding-top:30upx;padding-bottom:40upx;background-color: white;">失信人员查询系统</view>
+      <view style="width:100%;font-size:40upx;font-weight:bold;text-align: center;padding-top:30upx;padding-bottom:40upx;background-color: white;">失信人员查询系统</view>
       <view style="background-color: white;">
         <view style="width:100%;">
           <button class="admin-button-com big blue" style="margin-left:2%;" @click="">手机号</button>
@@ -12,7 +12,10 @@
         <view style="width:100%;text-align: center;padding-bottom:30upx;margin-top:10upx;">
           <input v-model="search" name="search" ref="searchRef" type="text" placeholder="这里搜索" 
           style="border:1upx solid #CCCCCC;width:96%;border-radius: 10upx;height:90upx;margin:0 auto;text-align: left;padding-left:15upx;font-size:32upx;" />
-          <view style="width:100%;font-size:30upx;color:black;margin:15upx 0 5upx 2%;text-align: left;">失信人员 50人</view>
+          <view style="width:100%;font-size:30upx;color:black;margin:30upx 0 5upx 2%;text-align: left;font-size:32upx;">
+            <text>失信人员 50人</text>
+            <text style="float:right;color:#3385FF;text-decoration: underline;margin-right:40upx;" @click.stop="goMy()">我提交的记录</text>
+          </view>
         </view>
       </view>
       <div class="list-wrap">
@@ -79,13 +82,16 @@
       this.getList()
     },
     methods: {
+      goMy(){
+        this.$util.pageTo({url:"/admin/ll/my"})
+      },
       add(){
         this.$util.pageTo({url:"/admin/ll/add"})
       },
       init(){
       },
       getList() {
-        return getUserList({}).then((res) => {
+        return getUserList().then((res) => {
           this.completes(res);
           if (this.$util.isEmpty(res.data)){
             return false

+ 165 - 0
hdApp/src/admin/ll/my.vue

@@ -0,0 +1,165 @@
+<template>
+    <view class="app-main app-content">
+      <div class="list-wrap">
+        <block v-if="!$util.isEmpty(list.data)">
+          <div class="list" v-for="(item, index) in list.data" :key="index">
+            <llUser :item="item"></llUser>
+          </div>
+        </block>
+        <block v-else>
+          <app-wrapper-empty title="暂无数据" :is-empty="$util.isEmpty(list.data)" />
+        </block>
+      </div>
+    </view>
+  </template>
+  <script>
+  import NotLogin from "@/components/not-login";
+  import AppWrapperEmpty from "@/components/app-wrapper-empty";
+  import ModalModule from "@/components/plugin/modal";
+  import { list } from "@/mixins";
+  import { mapGetters } from "vuex";
+  import { getUserList} from "@/api/ll";
+  import AppSearchModule from "@/components/module/app-search";
+  import DropShopSelect from "@/components/module/shopSelect";
+  import llUser from "./components/user";
+  import DateSelect from "@/components/module/dateSelect";
+  export default {
+    name: "my",
+    components: {
+      AppWrapperEmpty,
+      ModalModule,
+      AppSearchModule,
+      DropShopSelect,
+      llUser,
+      DateSelect,
+      NotLogin
+    },
+    mixins: [list],
+    computed: { 
+      ...mapGetters(["getLoginInfo", "getDictionariesInfo"]) 
+    },
+    data() {
+      return {
+        search:''
+      };
+    },
+    onPullDownRefresh() {
+      this.resetList();
+      this.getList()
+      uni.stopPullDownRefresh()
+    },
+    onReachBottom() {
+      if (!this.list.finished) {
+        this.getList().then((res) => {
+          uni.stopPullDownRefresh();
+        });
+      } else {
+        uni.stopPullDownRefresh();
+      }
+    },
+    mounted() {
+
+    },
+    onLoad() {
+      this.getList()
+    },
+    methods: {
+      add(){
+        this.$util.pageTo({url:"/admin/ll/add"})
+      },
+      init(){
+      },
+      getList() {
+        return getUserList({requestType:'my'}).then((res) => {
+          this.completes(res);
+          if (this.$util.isEmpty(res.data)){
+            return false
+          }
+        })
+      }
+    },
+  };
+  </script>
+  <style lang="scss" scoped>
+  page{
+      width: 750upx;
+      overflow: hidden;
+  }
+  .app-content {
+    padding-bottom: 1upx;
+      overflow: hidden;
+    .select-dn_bx {
+      padding-left: 18upx;
+    }
+    .app-tabs {
+      position: fixed;
+      /* 手机mobile屏幕小于1000px */
+      @media screen and (max-width: 1100px) {
+        width: 100%;
+      }
+      /* 收银台cashier屏幕大于1000px */
+      @media screen and (min-width:1100px) {
+        width: 40%;
+      }    
+      z-index: 9;
+    }
+    .input-wrap_box {
+      background-color: #fff;
+      position: fixed;
+      top: 0;
+      z-index: 10;
+      /* 手机mobile屏幕小于1000px */
+      @media screen and (max-width: 1100px) {
+        width: 100%;
+      }
+      /* 收银台cashier屏幕大于1000px */
+      @media screen and (min-width:1100px) {
+        width: 40%;
+      }    
+      height: 100upx;
+      display: flex;
+      align-items: center;
+      padding: 0 30upx;
+      & > view:nth-child(2) {
+        flex: 1;
+      }
+    }
+    .list-wrap {
+      padding-top:25upx;
+      .list {
+        background-color: #fff;
+        margin-bottom: 20upx;
+      }
+    }
+      .app-footer {
+          justify-content: flex-end;
+      }
+  }
+  .upload-confirm-wrap {
+    max-height: 600upx;
+    overflow-y: auto;
+    .modal-tit {
+      @include disFlex(center, center);
+      font-size: 40upx;
+      margin-top: 30upx;
+      margin-bottom: 50upx;
+      .iconfont {
+        color: #09bb07;
+        margin-right: 20upx;
+        font-size: 50upx;
+      }
+    }
+    .sel-wrap {
+      color: $fontColor2;
+      font-size: 32upx;
+      .sel-tit {
+        text-align: left;
+      }
+      .sel-btn {
+        @include disFlex(center, flex-start);
+        flex-wrap: wrap;
+        padding: 10upx 0 40upx;
+      }
+    }
+  }
+  </style>

+ 10 - 2
hdApp/src/api/ll/index.js

@@ -1,5 +1,13 @@
 import https from '@/plugins/luch-request_0.0.7/request'
 
 export const getUserList = data => {
-	return https.post('/ll-user/list', data)
-}
+	return https.get('/ll-user/list', data)
+};
+
+export const addEvent = data => {
+	return https.post("/ll-event/add", data);
+};
+
+export const getUserDetail = data => {
+	return https.get('/ll-user/detail', data)
+};

+ 2 - 1
hdApp/src/pages.json

@@ -29,7 +29,8 @@
 			"pages": [
 				{"path": "list","style": {"navigationBarTitleText": "花卉行业"}},
 				{"path": "add","style": {"navigationBarTitleText": "新增"}},
-				{"path": "detail","style": {"navigationBarTitleText": "明细"}}
+				{"path": "detail","style": {"navigationBarTitleText": "明细"}},
+				{"path": "my","style": {"navigationBarTitleText": "我提交的记录"}}
 			]
 		},
 		{