Ver Fonte

Merge branch 'develop' of http://124.70.211.186:3000/zxh/E_WeChat into develop

# Conflicts:
#	project.private.config.json
codeMan há 2 anos atrás
pai
commit
9e3a054945

+ 36 - 35
app.js

@@ -1,40 +1,41 @@
 import {
-	ApiModel
+    ApiModel
 } from './utils/Api';
 
 App({
-	onLaunch() {},
-	initSocket() {
-		let that = this;
-		this.globalData.SocketTask = wx.connectSocket({
-			url: 'wss://meida.cnyunl.com/yos/webSocket/' + wx.getStorageSync('userMsg').token,
-			complete: (res) => {
-				console.log(res)
-			}
-		})
-		this.globalData.SocketTask.onOpen(function (res) {
-			that.globalData.socketEstablish = true;
-		})
-		this.globalData.SocketTask.onMessage(function (res) {
-			that.globalData.socket.callback(res)
-		})
-		this.globalData.SocketTask.onError(function (res) {
-			that.globalData.socketEstablish = false;
-		})
-		this.globalData.SocketTask.onClose(function (res) {
-			that.globalData.socketEstablish = false;
-		})
-	},
-	globalData: {
-		http: new ApiModel(), //接口文件
-		queryPer: require("./utils/queryPermissions"), //权限查询
-		handleSelect: null, //处理选择结果  函数
-		savePage: null, //保存页面实例
-		socketEstablish: false, //是否已经建立socket
-		SocketTask: '', // Socket方法
-		socket: { // Socket回调
-			that: null, //保存this
-			callback: function () {}
-		},
-	}
+    onLaunch() {},
+    initSocket() {
+        let that = this;
+        this.globalData.SocketTask = wx.connectSocket({
+            url: 'wss://meida.cnyunl.com/yos/webSocket/' + wx.getStorageSync('userMsg').token,
+            complete: (res) => {
+                console.log(res)
+            }
+        })
+        this.globalData.SocketTask.onOpen(function (res) {
+            that.globalData.socketEstablish = true;
+        })
+        this.globalData.SocketTask.onMessage(function (res) {
+            that.globalData.socket.callback(res)
+        })
+        this.globalData.SocketTask.onError(function (res) {
+            that.globalData.socketEstablish = false;
+        })
+        this.globalData.SocketTask.onClose(function (res) {
+            that.globalData.socketEstablish = false;
+        })
+    },
+    globalData: {
+        userrole: null, //角色身份
+        http: new ApiModel(), //接口文件
+        queryPer: require("./utils/queryPermissions"), //权限查询
+        handleSelect: null, //处理选择结果  函数
+        savePage: null, //保存页面实例
+        socketEstablish: false, //是否已经建立socket
+        SocketTask: '', // Socket方法
+        socket: { // Socket回调
+            that: null, //保存this
+            callback: function () {}
+        },
+    }
 })

+ 2 - 1
app.json

@@ -50,7 +50,8 @@
         "address/index",
         "finance/index",
         "contract/index",
-        "activity/index"
+        "activity/index",
+        "orderFormLine/index"
       ]
     }
   ],

+ 148 - 64
packageA/invoice/detail.js

@@ -1,66 +1,150 @@
-// packageA/invoice/detail.js
-Page({
-
-  /**
-   * 页面的初始数据
-   */
-  data: {
-
-  },
-
-  /**
-   * 生命周期函数--监听页面加载
-   */
-  onLoad(options) {
-
-  },
-
-  /**
-   * 生命周期函数--监听页面初次渲染完成
-   */
-  onReady() {
-
-  },
-
-  /**
-   * 生命周期函数--监听页面显示
-   */
-  onShow() {
-
-  },
-
-  /**
-   * 生命周期函数--监听页面隐藏
-   */
-  onHide() {
+const _Http = getApp().globalData.http;
 
-  },
-
-  /**
-   * 生命周期函数--监听页面卸载
-   */
-  onUnload() {
-
-  },
-
-  /**
-   * 页面相关事件处理函数--监听用户下拉动作
-   */
-  onPullDownRefresh() {
-
-  },
-
-  /**
-   * 页面上拉触底事件的处理函数
-   */
-  onReachBottom() {
-
-  },
-
-  /**
-   * 用户点击右上角分享
-   */
-  onShareAppMessage() {
-
-  }
+Page({
+    data: {
+        tabsActive: 2,
+        sa_invoiceapplyid: "",
+        tabsList: [{
+            label: "详细信息",
+            icon: "icon-tabchanpin"
+        }, {
+            label: "开票单位",
+            icon: "icon-tabchanpin"
+        }, {
+            label: "开票明细",
+            icon: "icon-tabchanpin",
+            model: "#DetailLine"
+        }]
+    },
+    onLoad(options) {
+        this.setData({
+            sa_invoiceapplyid: options.id
+        });
+        this.getDetail();
+    },
+    getDetail() {
+        _Http.basic({
+            "id": "20221216143003",
+            "version": 1,
+            "content": {
+                "sa_invoiceapplyid": this.data.sa_invoiceapplyid
+            }
+        }).then(res => {
+            console.log("开票单详情", res)
+            if (res.msg != '成功') return wx.showToast({
+                title: res.msg,
+                icon: "none"
+            })
+            this.setData({
+                detail: res.data
+            });
+            this.setPreview();
+            this.partialRenewal();
+        })
+    },
+    /* 设置显示信息 */
+    setPreview() {
+        let item = this.data.detail;
+        let list1 = [{
+            label: "申请单号",
+            value: item.billno
+        }, {
+            label: "发票限额",
+            value: item.quota
+        }, {
+            label: "是否手工单",
+            value: item.byhand ? '是' : '否'
+        }, {
+            label: "发票种类",
+            value: item.invoiceline
+        }, {
+            label: "发票收款人",
+            value: item.invoicepayee
+        }, {
+            label: "开票员",
+            value: item.invoiceclerk
+        }, {
+            label: "发票复核人",
+            value: item.invoicechecker
+        }, {
+            label: "提交人",
+            value: item.submitby
+        }, {
+            label: "提交日期",
+            value: item.submitdate
+        }, {
+            label: "备注",
+            value: item.remarks
+        }];
+        let list2 = [{
+            label: "状态",
+            value: item.status
+        }, {
+            label: "创建人",
+            value: item.createby
+        }, {
+            label: "创建时间",
+            value: item.createdate
+        }, {
+            label: "审核人",
+            value: item.checkby
+        }, {
+            label: "审核时间",
+            value: item.checkdate
+        }, {
+            label: "修改人",
+            value: item.changeby
+        }, {
+            label: "修改时间",
+            value: item.changedate
+        }, ];
+        let riseLine = [{
+            label: "抬头",
+            value: item.enterprisename
+        }, {
+            label: "税号",
+            value: item.taxno
+        }, {
+            label: "开户行",
+            value: item.bank
+        }, {
+            label: "开户账号",
+            value: item.bankcardno
+        }, {
+            label: "开票地址",
+            value: item.address
+        }, {
+            label: "联系方式",
+            value: item.phonenumber
+        }];
+        this.setData({
+            list1,
+            list2,
+            riseLine
+        })
+    },
+    //局部数据更新 tabs
+    partialRenewal(init = false) {
+        let model = this.data.tabsList[this.data.tabsActive].model;
+        if (model) {
+            let Component = this.selectComponent(model),
+                {
+                    total,
+                    pageNumber,
+                    pageTotal
+                } = Component.data.content,
+                id = this.data.sa_invoiceapplyid;
+            if (total == null || init) {
+                Component.getList(id, init);
+            } else if (pageNumber < pageTotal) {
+                Component.getList(id, false);
+            }
+        }
+    },
+    onReachBottom() {
+        this.partialRenewal();
+    },
+    onUnload() {
+
+    },
 })

+ 5 - 1
packageA/invoice/detail.json

@@ -1,3 +1,7 @@
 {
-  "usingComponents": {}
+  "usingComponents": {
+    "Preview": "../shipment/modules/preview/index",
+    "HeaderDetails": "./modules/headerDetails/index",
+    "DetailLine": "./modules/detailLine/index"
+  }
 }

+ 96 - 1
packageA/invoice/detail.scss

@@ -1 +1,96 @@
-/* packageA/invoice/detail.wxss */
+.intr {
+    position: relative;
+    width: 100vw;
+    box-sizing: border-box;
+    background-color: #fff;
+    padding: 20rpx 30rpx;
+
+    .num {
+        height: 40rpx;
+        line-height: 40rpx;
+        font-size: 32rpx;
+        font-family: PingFang SC-Bold, PingFang SC;
+        font-weight: bold;
+        color: #333333;
+        margin-bottom: 10rpx;
+    }
+
+    .exp {
+        height: 34rpx;
+        line-height: 34rpx;
+        font-size: 26rpx;
+        margin-bottom: 8rpx;
+        color: #666;
+    }
+
+    .copy {
+        position: absolute;
+        right: 30rpx;
+        top: 20rpx;
+        background-color: #FF9933;
+        border-radius: 12rpx;
+        padding: 0 10rpx;
+        color: #fff;
+        border: none;
+        height: 70rpx;
+    }
+
+}
+
+.box {
+    width: 100vw;
+    padding: 20rpx 30rpx;
+    box-sizing: border-box;
+    background-color: #fff;
+    margin-top: 10rpx;
+
+    .row {
+        display: flex;
+        justify-content: space-between;
+        min-height: 60rpx;
+        align-items: center;
+
+        .label {
+            font-size: 28rpx;
+        }
+
+        checkbox {
+            width: 36rpx;
+            height: 36rpx;
+            margin-right: 6rpx;
+        }
+
+        checkbox .wx-checkbox-input {
+            width: 36rpx;
+            height: 36rpx;
+        }
+    }
+}
+
+
+.footer {
+    display: flex;
+    justify-content: center;
+    padding: 0 30rpx;
+    position: fixed;
+    width: 100vw;
+    height: 130rpx;
+    background: #FFFFFF;
+    box-shadow: 0px -4rpx 16rpx 2rpx rgba(150, 157, 165, 0.16);
+    bottom: 0;
+    box-sizing: border-box;
+    z-index: 9999;
+    padding-top: 10rpx;
+
+    .but {
+        width: 690rpx;
+        height: 90rpx;
+        background: var(--warning);
+        border-radius: 16rpx;
+        font-size: 28rpx;
+        font-family: PingFang SC-Bold, PingFang SC;
+        font-weight: bold;
+        color: #fff;
+    }
+
+}

+ 19 - 2
packageA/invoice/detail.wxml

@@ -1,2 +1,19 @@
-<!--packageA/invoice/detail.wxml-->
-<text>packageA/invoice/detail.wxml</text>
+<view class="intr">
+	<view class="num">
+		{{detail.billno}}
+	</view>
+	<view class="exp">状态:{{detail.status}}</view>
+	<view class="exp">创建日期:{{detail.createdate}}</view>
+	<view class="exp">开票单位:{{detail.enterprisename|| "--"}}</view>
+	<view class="exp">备注:{{detail.remarks || "--"}}</view>
+</view>
+<Yl_FunTabs list='{{tabsList}}' active='{{tabsActive}}' bind:onChenge="tabsChange">
+	<Preview slot='详细信息' list1='{{list1}}' list2='{{list2}}' />
+	<HeaderDetails slot='开票单位' list="{{riseLine}}" />
+	<DetailLine slot='开票明细' id='DetailLine' />
+	<view style="height: 140rpx;" />
+</Yl_FunTabs>
+
+<view class="footer" wx:if="{{detail.status=='审核'}}">
+	<van-button custom-class='but' bind:click="receiving">确认收货</van-button>
+</view>

+ 170 - 0
packageA/invoice/modules/detailLine/index.js

@@ -0,0 +1,170 @@
+const _Http = getApp().globalData.http,
+  file = require("../../../../utils/FormatTheAttachment");
+Component({
+  data: {
+    sa_invoiceapplyid: 0,
+    "content": {
+      nocache: true,
+      "pageNumber": 1,
+      pageTotal: 1,
+      total: null
+    }
+  },
+  methods: {
+    /* 获取产品列表 */
+    getList(id, init) {
+      let content = this.data.content;
+      content.sa_invoiceapplyid = id;
+      if (init) content.pageNumber = 1;
+      _Http.basic({
+        "id": "20221217091303",
+        "version": 1,
+        content
+      }).then(res => {
+        console.log("订单行列表", res)
+        if (res.msg != '成功') return wx.showToast({
+          title: res.msg,
+          icon: "none"
+        })
+        res.data = res.data.map(value => {
+          if (value.attinfos.length != 0) {
+            value.attinfos = file.fileList(value.attinfos)
+            let image = value.attinfos.find(v => v.fileType == "image");
+            value.cover = image ? image.cover : "";
+          }
+          return value;
+        })
+        this.setData({
+          list: res.pageNumber == 1 ? res.data : this.data.list.concat(res.data),
+          "content.pageNumber": res.pageNumber + 1,
+          "content.pageSize": res.pageSize,
+          "content.pageTotal": res.pageTotal,
+          "content.total": res.total,
+          sa_invoiceapplyid: id
+        })
+      })
+    },
+    /* 去添加订单行 */
+    addProduct() {
+      let detail = getCurrentPages().find(v => v.__route__ == 'packageA/invoice/detail').data.detail;
+      wx.navigateTo({
+        url: `/select/orderFormLine/index?params=${JSON.stringify({
+          "id": "20221217085103",
+          "version":1,
+          "content": {
+              nocache:true,
+              "sys_enterpriseid":detail.sys_enterpriseid,
+              "sa_invoiceapplyid":detail.sa_invoiceapplyid,
+              "where":{
+                "condition":"",
+                "sonum":"",
+                "begindate":"",
+                "enddate":""
+              }
+          }
+        })}`
+      });
+      getApp().globalData.handleSelect = this.handleSelect.bind(this);
+    },
+    /* 处理新增订单行 */
+    handleSelect(detail) {
+      let that = this;
+      wx.showModal({
+        title: '提示',
+        content: `是否确认添加${detail.result.length}条订单行?`,
+        complete: (res) => {
+          if (res.confirm) _Http.basic({
+            "id": "20221217091203",
+            "version": 1,
+            "content": {
+              "sa_invoiceapplyid": that.data.sa_invoiceapplyid,
+              "iteminfos": detail.list.map(v => {
+                return {
+                  "sa_invoiceapply_orderid": 0,
+                  "saorderid": v.sa_orderid,
+                  "sa_orderitemsid": v.sa_orderitemsid,
+                  "price": v.price
+                }
+              })
+            }
+          }).then(s => {
+            console.log('新增订单行', s)
+            wx.showToast({
+              title: s.msg == '成功' ? '添加成功' : s.msg,
+              icon: "none"
+            });
+            if (s.msg == '成功') setTimeout(() => {
+              that.getList(that.data.sa_invoiceapplyid, true);
+              wx.navigateBack();
+              // that.updateThePrice();
+            }, 300)
+          })
+        }
+      });
+    },
+    /* 修改开票金额数量 */
+    changeProduct({
+      detail
+    }) {
+      let invoiceaqty = detail.invoiceaqty;
+      detail.invoiceaqty = 0;
+      _Http.basic({
+        "id": "20221217091203",
+        "version": 1,
+        "content": {
+          "sa_invoiceapplyid": this.data.sa_invoiceapplyid,
+          "iteminfos": [detail]
+        }
+      }).then(res => {
+        console.log("修改订单行", res)
+        let i = this.data.list.findIndex(v => v.sa_orderitemsid == detail.sa_orderitemsid)
+        if (res.msg != '成功') {
+          wx.showToast({
+            title: res.msg,
+            icon: "none"
+          });
+          if (i != -1) this.setData({
+            [`list[${i}].invoiceamount`]: this.data.list[i].invoiceamount,
+            [`list[${i}].invoiceaqty`]: this.data.list[i].invoiceaqty
+          })
+        } else {
+          if (i != -1) this.setData({
+            [`list[${i}].invoiceamount`]: detail.invoiceamount,
+            [`list[${i}].invoiceaqty`]: (invoiceaqty - 0).toFixed(2)
+          })
+        }
+      })
+    },
+    /* 删除订单行 */
+    deleteItem({
+      detail
+    }) {
+      console.log(detail)
+      let that = this;
+      wx.showModal({
+        title: '提示',
+        content: `是否确认删除“${detail.itemname}”`,
+        complete: ({
+          confirm
+        }) => {
+          if (confirm) _Http.basic({
+            "id": "20221217091403",
+            "version": 1,
+            "content": {
+              "sa_invoiceapply_orderids": [detail.sa_invoiceapply_orderid]
+            }
+          }).then(res => {
+            console.log('删除订单行', res)
+            wx.showToast({
+              title: res.msg == '成功' ? '删除成功' : res.msg,
+              icon: "none"
+            });
+            if (res.msg == '成功') that.setData({
+              list: that.data.list.filter(v => v.sa_orderitemsid != detail.sa_orderitemsid)
+            })
+          })
+        }
+      })
+    },
+  }
+})

+ 6 - 0
packageA/invoice/modules/detailLine/index.json

@@ -0,0 +1,6 @@
+{
+  "component": true,
+  "usingComponents": {
+    "List": "./list/index"
+  }
+}

+ 5 - 0
packageA/invoice/modules/detailLine/index.scss

@@ -0,0 +1,5 @@
+@import "../../../../static/common-head.scss";
+.count{
+	font-size: 30rpx !important;
+	font-weight: bold;
+}

+ 10 - 0
packageA/invoice/modules/detailLine/index.wxml

@@ -0,0 +1,10 @@
+<view class="head">
+	<view class="count">开票订单行</view>
+	<view class="expand">
+		<navigator wx:if="{{!disabled}}" url="#" class="but" bindtap="addProduct">
+			<van-icon name="plus" />
+		</navigator>
+	</view>
+</view>
+
+<List list='{{list}}' disabled='{{disabled}}' bindchangeProduct="changeProduct" binddeleteItem='deleteItem' />

+ 66 - 0
packageA/invoice/modules/detailLine/list/index.js

@@ -0,0 +1,66 @@
+Component({
+	properties: {
+		list: Array,
+		deleteItem: Function,
+		changeProduct: Function, //修改队列
+		disabled: Boolean
+	},
+	options: {
+		addGlobalClass: true
+	},
+	methods: {
+		toProductDetail(e) {
+			const {
+				item
+			} = e.currentTarget.dataset;
+			console.log(item)
+		},
+		onBlur(e) {
+			let {
+				data
+			} = e.currentTarget.dataset;
+			let i = this.data.list.findIndex(v => v.sa_orderitemsid == data.sa_orderitemsid)
+			if (e.detail.value > data.uninvoiceamount) {
+				e.detail.value = data.uninvoiceamount;
+				wx.showToast({
+					title: `最大开票金额${data.uninvoiceamount}元`,
+					icon: "none"
+				});
+				if (i != -1) this.setData({
+					[`list[${i}].invoiceamount`]: data.uninvoiceamount,
+					[`list[${i}].invoiceaqty`]: data.uninvoiceamount / data.price,
+				})
+			} else if (e.detail.value == 0) {
+				wx.showToast({
+					title: `开票金额不可为0`,
+					icon: "none"
+				});
+				if (i != -1) this.setData({
+					[`list[${i}].invoiceamount`]: this.data.list[i].invoiceamount,
+					[`list[${i}].invoiceaqty`]: this.data.list[i].invoiceaqty,
+				})
+			} else {
+				if (e.detail.value != data.invoiceamount) this.triggerEvent("changeProduct", {
+					"sa_invoiceapply_orderid": data.sa_invoiceapply_orderid,
+					"saorderid": data.sa_orderid,
+					"sa_orderitemsid": data.sa_orderitemsid,
+					"price": data.price,
+					"invoiceamount": e.detail.value - 0,
+					"invoiceaqty": (e.detail.value - 0) / data.price
+				})
+			}
+		},
+		deleteProduct(e) {
+			let {
+				item
+			} = e.currentTarget.dataset;
+			this.triggerEvent("deleteItem", item)
+		},
+		isEdit() {
+			if (this.data.disabled) wx.showToast({
+				title: '当前状态不可编辑!',
+				icon: "none"
+			})
+		}
+	}
+})

+ 5 - 0
packageA/invoice/modules/detailLine/list/index.json

@@ -0,0 +1,5 @@
+{
+    "component": true,
+    "usingComponents": {
+    }
+}

+ 138 - 0
packageA/invoice/modules/detailLine/list/index.scss

@@ -0,0 +1,138 @@
+.product-item {
+  background-color: #fff;
+  box-sizing: border-box;
+  border-bottom: 1rpx solid #DDDDDD;
+  margin-bottom: 20rpx;
+
+  .product {
+    padding: 20rpx 30rpx;
+    box-sizing: border-box;
+
+    .mian {
+      position: relative;
+      display: flex;
+      align-items: center;
+      width: 100%;
+      box-sizing: border-box;
+
+      .img {
+        flex-shrink: 0;
+        width: 112rpx;
+        height: 112rpx;
+        border-radius: 16rpx;
+        margin-right: 20rpx;
+        overflow: hidden;
+
+        .err {
+          display: flex;
+          width: 100%;
+          height: 100%;
+          align-items: center;
+          justify-content: center;
+          font-size: 22rpx;
+          border: 1px solid #ddd;
+          box-sizing: border-box;
+          color: #666;
+        }
+      }
+
+      .dec {
+        flex: 1;
+        width: 0;
+        min-height: 128rpx;
+        height: 100%;
+        font-size: 24rpx;
+        font-family: PingFang SC-Regular, PingFang SC;
+        color: #999999;
+
+        .title {
+          display: flex;
+          width: 90%;
+          height: 40rpx;
+          font-size: 28rpx;
+          font-weight: 600;
+          color: #333333;
+
+          .line-1 {
+            max-width: 380rpx;
+          }
+
+          .tag {
+            display: inline-block;
+            color: #fff;
+            background-color: #F80700;
+            padding: 0 20rpx;
+            margin-left: 20rpx;
+            border-radius: 20rpx;
+            font-weight: normal;
+            font-size: 22rpx;
+            line-height: 40rpx;
+          }
+        }
+
+        .subfield {
+          display: flex;
+          margin-top: 8rpx;
+          height: 34rpx;
+          line-height: 34rpx;
+
+          text {
+            display: inline-block;
+            width: 48%;
+          }
+        }
+
+      }
+
+      .delete {
+        position: absolute;
+        width: 68rpx;
+        height: 68rpx;
+        line-height: 68rpx;
+        right: -30rpx;
+        top: -20rpx;
+        text-align: center;
+        font-size: 32rpx;
+        color: #999;
+      }
+    }
+  }
+
+  .bot {
+    width: 690rpx;
+    border-top: 1rpx solid #ddd;
+    margin: 0 auto;
+    padding-bottom: 20rpx;
+
+    .row {
+      display: flex;
+      width: 100%;
+      margin-top: 20rpx;
+
+      view {
+        display: flex;
+        height: 54rpx;
+        align-items: center;
+        flex-shrink: 0;
+        .label {
+          font-size: 24rpx;
+          font-family: PingFang SC-Regular, PingFang SC;
+          color: #666666;
+          text-align-last: justify;
+        }
+      }
+
+      .input {
+        height: 54rpx;
+        background: #FFFFFF;
+        border-radius: 8rpx;
+        border: 1rpx solid #CCCCCC;
+        font-size: 28rpx;
+        font-family: PingFang SC-Regular, PingFang SC;
+        color: #333333;
+        line-height: 44px;
+        text-align: center;
+      }
+    }
+  }
+}

+ 46 - 0
packageA/invoice/modules/detailLine/list/index.wxml

@@ -0,0 +1,46 @@
+<view class="product-item" wx:for="{{list}}" wx:key="sa_orderitemsid">
+	<navigator class="product" url="#" data-item="{{item}}" bindtap="toProductDetail">
+		<view class="mian">
+			<view class="img" data-file="{{item.attinfos}}" catchtap="viewImage">
+				<van-image width="100%" height="100%" wx:if="{{item.cover}}" src="{{item.cover}}" use-loading-slot lazy-load>
+					<van-loading slot="loading" type="spinner" size="20" vertical />
+				</van-image>
+				<text wx:else class="err">暂无图片</text>
+			</view>
+			<view class="dec">
+				<view class="title">
+					<text class="line-1">{{item.itemname}}</text>
+					<text class="tag" wx:if="{{item.stockstatus}}">{{item.stockstatus}}</text>
+				</view>
+				<view class="subfield">
+					{{item.type}}:{{item.sonum}}
+				</view>
+				<view class="subfield">
+					可开票金额:{{item.uninvoiceamount}}元
+				</view>
+				<view class="subfield">
+					<text class="line-1" style="margin-right: 6rpx;">型号:{{item.model||' --'}}</text>
+					<text class="line-1">规格:{{item.spec||' --'}}</text>
+				</view>
+			</view>
+			<view wx:if="{{!disabled}}" class="delete" data-item="{{item}}" catchtap="deleteProduct">
+				<text class="iconfont icon-guanlian-shanchu" />
+			</view>
+		</view>
+	</navigator>
+	<view class="bot">
+		<view class="row">
+			<view>
+				<view class="label">开票金额(元):</view>
+				<input disabled='{{disabled}}' bindtap="isEdit" class="input" style="width: 240rpx;" type="digit" value="{{item.invoiceamount}}" data-data="{{item}}" bindblur="onBlur" />
+			</view>
+			<view style="flex: 1; justify-content: flex-end;">
+				<view class="label line-1">开票数量:{{item.invoiceaqty}}{{item.unit}}</view>
+			</view>
+		</view>
+	</view>
+</view>
+<block wx:if="{{list.length==0}}">
+	<Yl_Empty />
+	<view style="height: 150rpx;" />
+</block>

+ 17 - 0
packageA/invoice/modules/headerDetails/index.js

@@ -0,0 +1,17 @@
+Component({
+  properties: {
+    list: Array
+  },
+  data: {
+    showAll: false
+  },
+  methods: {
+    onChange({
+      detail
+    }) {
+      this.setData({
+        showAll: detail
+      })
+    }
+  }
+})

+ 7 - 0
packageA/invoice/modules/headerDetails/index.json

@@ -0,0 +1,7 @@
+{
+    "component": true,
+    "usingComponents": {
+        "Yl_Headline":"/components/Yl_Headline/index",
+        "Yl_ReportForms":"/components/Yl_ReportForms/index"
+    }
+}

+ 0 - 0
packageA/invoice/modules/headerDetails/index.scss


+ 2 - 0
packageA/invoice/modules/headerDetails/index.wxml

@@ -0,0 +1,2 @@
+<Yl_Headline title='抬头信息' type='switch' switchLabel='仅显示已填信息' switch='{{showAll}}' bind:callBack='onChange' />
+<Yl_ReportForms showAll='{{!showAll}}' list='{{list}}' />

+ 1 - 1
packageA/invoice/modules/list/index.wxml

@@ -1,4 +1,4 @@
-<navigator url="/packageA/shipment/detail?id={{item.sa_logisticsid}}" class="item" wx:for="{{list}}" wx:key="billno">
+<navigator url="/packageA/invoice/detail?id={{item.sa_invoiceapplyid}}" class="item" wx:for="{{list}}" wx:key="sa_invoiceapplyid">
     <view class="top">
         提交日期:{{item.submitdate || ' --'}} <text>{{item.status}}</text>
     </view>

+ 62 - 17
packageA/invoice/update.js

@@ -1,5 +1,4 @@
-const _Http = getApp().globalData.http,
-    getTime = require("../../utils/getTime");
+const _Http = getApp().globalData.http;
 
 Page({
     data: {
@@ -15,9 +14,6 @@ Page({
                     "id": 20221013160602,
                     "content": {
                         nocache: true,
-                        sys_enterpriseid: 1,
-                        "pageNumber": 1,
-                        "pageTotal": 1,
                         "pageSize": 20,
                         "where": {
                             "condition": "",
@@ -41,24 +37,73 @@ Page({
                 valueName: "remarks",
                 required: false
             },
-        ]
+        ],
+        content: {
+            sa_invoiceapplyid: 0,
+            byhand: false,
+            enterprisename: "", //抬头
+            taxno: "", //税号
+            bank: "", //开户行
+            phonenumber: "", //手机号
+            bankcardno: "", //开户账号
+            address: "", //开票地址
+            quota: 0,
+        }
     },
     onLoad(options) {
         console.log(wx.getStorageSync('userMsg').usertype == 1)
     },
-    /* 选择财务信息 
-    selectFinance() {
-        if (this.isEdit()) return;
-        wx.navigateTo({
-            url: `?params=${JSON.stringify()}&radio=true`,
-        });
-        getApp().globalData.handleSelect = this.setFinance.bind(this);
-    },*/
     /* 打断处理form */
-    interrupt(e) {
-        console.log("打断", e)
+    interrupt({
+        detail
+    }) {
+        console.log("打断", detail)
+        if (detail.temporary.item.label == "开票抬头") {
+            let item = detail.data.item;
+            detail.data.value[0] = `抬头:${item.enterprisename}\n税号:${item.taxno}\n地址:${item.address}`;
+            detail.form[detail.temporary.index].value = detail.data.value;
+            this.setData({
+                form: detail.form,
+                "content.enterprisename": item.enterprisename,
+                "content.taxno": item.taxno,
+                "content.bank": item.bank,
+                "content.phonenumber": item.phonenumber,
+                "content.bankcardno": item.bankcardno,
+                "content.address": item.address,
+            })
+        }
+        this.selectComponent("#Form").confirm();
+        wx.navigateBack()
+    },
+    submit() {
+        let data = this.selectComponent("#Form").submit();
+        let content = this.data.content;
+        content.remarks = data.remarks;
+        wx.showModal({
+            title: '提示',
+            content: '是否确定创建开票申请单?',
+            complete: ({
+                confirm
+            }) => {
+                if (confirm) _Http.basic({
+                    "id": "20221216142903",
+                    "version": 1,
+                    content
+                }).then(res => {
+                    console.log("创建开票申请单", res)
+                    wx.showToast({
+                        title: res.msg == '成功' ? '创建成功' : res.msg,
+                        icon: "none",
+                        mask: true
+                    });
+                    if (res.msg == '成功') setTimeout(() => wx.redirectTo({
+                        url: '/packageA/invoice/detail?id=' + res.data.sa_invoiceapplyid,
+                    }), 500)
+                })
+            }
+        })
+
     },
-    submit() {},
     // 是否显示全部
     onChange({
         detail

+ 1 - 1
packageA/invoice/update.wxml

@@ -3,5 +3,5 @@
 	<view slot='discountrate' style="margin-right: 36rpx;">%</view>
 </Yl_Field>
 <view class="footer">
-	<van-button custom-class='but' disabled="{{disabled}}" bind:click="submit">申请开票</van-button>
+	<van-button custom-class='but' disabled="{{disabled}}" bind:click="submit">创建开票申请单</van-button>
 </view>

+ 3 - 1
pages/login/modules/login.js

@@ -4,7 +4,9 @@ let count = 0; //接口完成数量
 function loginMsg(res) {
     wx.setStorageSync('account_list', res.account_list);
     if (res.account_list.length == 1) {
-        wx.setStorageSync('userMsg', res.account_list[0])
+        let item = res.account_list[0];
+        getApp().globalData.userrole = item.usertype == 1 ? '业务员' : '经销商';
+        wx.setStorageSync('userMsg', item)
         query_userauth();
     } else {
         wx.redirectTo({

+ 1 - 0
pages/login/selectSite.js

@@ -16,6 +16,7 @@ Page({
         const {
             item
         } = e.currentTarget.dataset;
+        getApp().globalData.userrole = item.usertype == 1 ? '业务员' : '经销商';
         wx.setStorageSync('userMsg', item);
         login.query_userauth();
     },

+ 3 - 1
project.config.json

@@ -53,5 +53,7 @@
     "ignore": [],
     "include": []
   },
-  "appid": "wxc1b6ae925ac1d06a"
+  "appid": "wxc1b6ae925ac1d06a",
+  "projectname": "E_WeChat",
+  "libVersion": "2.29.1"
 }

+ 123 - 0
select/orderFormLine/index.js

@@ -0,0 +1,123 @@
+const _Http = getApp().globalData.http,
+	file = require("../../utils/FormatTheAttachment");
+Page({
+  data: {
+    loading: true,
+    params: {}, //请求体
+    result: [], //返回结果
+    radio: false, //是否为单选
+    idname: "sa_orderitemsid", //idkey
+    showName: "itemname"
+  },
+  onLoad(options) {
+    if (options.params) {
+      let params = JSON.parse(options.params);
+      if (!params.content.pageNumber || !params.content.pageTotal) {
+        params.content.pageNumber = 1;
+        params.content.pageTotal = 1;
+      };
+      this.setData({
+        params
+      });
+    }
+    this.setData({
+      radio: options.radio ? true : false,
+      idname: options.idname || this.data.idname,
+      showName: options.showName || this.data.showName,
+    });
+    this.getList();
+  },
+  getList(init = false) {
+    //init 用于初始化分页
+    if (init.detail != undefined) init = init.detail;
+    let params = this.data.params;
+    if (init) params.content.pageNumber = 1;
+    if (params.content.pageNumber > params.content.pageTotal) return;
+    _Http.basic(params).then(res => {
+      console.log("选择订单行列表", res)
+      this.selectComponent('#ListBox').RefreshToComplete();
+      if (res.msg != '成功') return wx.showToast({
+        title: res.msg,
+        icon: "none"
+      })
+      res.data = res.data.map(value => {
+        if (value.attinfos.length != 0) {
+          value.attinfos = file.fileList(value.attinfos)
+          let image = value.attinfos.find(v => v.fileType == "image");
+          value.cover = image ? image.cover : "";
+        }
+        value.gradeprice && (value.gradeprice = (value.gradeprice - 0).toFixed(2));
+        value.price && (value.price = (value.price - 0).toFixed(2));
+        value.oldprice && (value.oldprice = (value.oldprice - 0).toFixed(2));
+        return value;
+      })
+      this.setData({
+        'params.content.pageNumber': res.pageNumber + 1,
+        'params.content.pageTotal': res.pageTotal,
+        'params.content.total': res.total,
+        list: res.pageNumber == 1 ? res.data : this.data.list.concat(res.data),
+        loading: false
+      })
+    })
+  },
+  /* 选中 */
+  changeResult(e) {
+    let {
+      id
+    } = e.currentTarget.dataset, result = this.data.result;
+    if (this.data.radio) {
+      result = [id];
+    } else {
+      result.some(v => v == id) ? result = result.filter(v => v != id) : result.push(id)
+    }
+    this.setData({
+      result
+    });
+    if (this.data.radio) this.submit();
+  },
+  /* 提交 */
+  submit() {
+    let result = this.data.result,
+      obj = this.data.radio ? {
+        id: result,
+        item: this.data.list.find(value => value[this.data.idname] == result),
+        value: [this.data.list.find(value => value[this.data.idname] == result)[this.data.showName], result]
+      } : {
+        result,
+        list: result.map(v => this.data.list.find(value => value[this.data.idname] == v)),
+        value: [result.map(v => {
+          let data = this.data.list.find(value => value[this.data.idname] == v);
+          return data ? data[this.data.showName] : ""
+        }), result]
+      }
+    getApp().globalData.handleSelect && getApp().globalData.handleSelect(obj)
+  },
+  /* 开始搜索 */
+  startSearch({
+    detail
+  }) {
+    let condition = this.data.content ? this.data.content.where.condition : this.data.params.content.where.condition;
+    if (detail == condition) return;
+    this.setData({
+      'content.where.condition': detail,
+      'params.content.where.condition': detail
+    });
+    this.getList(true);
+  },
+  /* 取消搜索 */
+  onClear() {
+    this.setData({
+      'content.where.condition': "",
+      'params.content.where.condition': ""
+    });
+    this.getList(true);
+  },
+  onReady() {
+    this.selectComponent("#ListBox").setHeight(".total", this);
+  },
+  onUnload() {
+    //回收数据
+    getApp().globalData.handleSelect = null;
+    getApp().globalData.savePage = null;
+  }
+})

+ 3 - 0
select/orderFormLine/index.json

@@ -0,0 +1,3 @@
+{
+  "usingComponents": {}
+}

+ 145 - 0
select/orderFormLine/index.scss

@@ -0,0 +1,145 @@
+@import "./index.skeleton.wxss";
+page {
+	height: 100vh;
+	overflow: hidden;
+}
+
+.total {
+	height: 60rpx;
+	line-height: 60rpx;
+	font-size: 24rpx;
+	font-family: PingFang SC-Regular, PingFang SC;
+	color: #666666;
+	padding-left: 30rpx;
+}
+
+.setclient-list-item {
+	width: 100vw;
+	padding: 0 30rpx;
+	background-color: #FFFFFF;
+	box-sizing: border-box;
+	border-bottom: 1rpx solid #DDDDDD;
+	margin-bottom: 20rpx;
+
+	.mian {
+		display: flex;
+		align-items: center;
+		width: 100%;
+		border-bottom: 1rpx solid #DDDDDD;
+		box-sizing: border-box;
+		padding: 20rpx 0;
+
+		.img {
+			flex-shrink: 0;
+			width: 128rpx;
+			height: 128rpx;
+			border-radius: 16rpx;
+			margin-right: 30rpx;
+			overflow: hidden;
+
+			.err {
+				display: flex;
+				width: 100%;
+				height: 100%;
+				align-items: center;
+				justify-content: center;
+				font-size: 22rpx;
+				border: 1px solid #ddd;
+				box-sizing: border-box;
+				color: #666;
+			}
+		}
+
+		.dec {
+			flex: 1;
+			width: 0;
+			min-height: 128rpx;
+			height: 100%;
+			font-size: 24rpx;
+			font-family: PingFang SC-Regular, PingFang SC;
+			color: #999999;
+
+			.title {
+				height: 40rpx;
+				line-height: 40rpx;
+				font-size: 28rpx;
+				font-family: PingFang SC-Semibold, PingFang SC;
+				font-weight: 600;
+				color: #333333;
+			}
+
+			.subfield {
+				margin-top: 6rpx;
+				height: 34rpx;
+				line-height: 34rpx;
+
+
+				text {
+					display: inline-block;
+					max-width: 250rpx;
+					min-width: 150rpx;
+				}
+			}
+
+			.price {
+				height: 40rpx;
+				line-height: 40rpx;
+				margin-top: 8rpx;
+
+				.num {
+					font-size: 28rpx;
+					color: #FF3B30;
+					font-weight: 600;
+				}
+
+				text {
+					color: #333333;
+				}
+			}
+		}
+	}
+
+	.bot {
+		font-size: 24rpx;
+		font-family: PingFang SC-Regular, PingFang SC;
+		color: #999999;
+		height: 72rpx;
+		line-height: 72rpx;
+
+		text {
+			display: inline-block;
+			width: 50%;
+		}
+	}
+}
+
+.footer {
+	display: flex;
+	justify-content: space-between;
+	align-items: center;
+	padding: 0 30rpx;
+	position: fixed;
+	width: 100vw;
+	height: 130rpx;
+	background: #FFFFFF;
+	box-shadow: 0px -4rpx 16rpx 2rpx rgba(150, 157, 165, 0.16);
+	bottom: 0;
+	box-sizing: border-box;
+
+	.count {
+		font-size: 28rpx;
+		font-family: PingFang SC-Regular, PingFang SC;
+		color: #333333;
+	}
+
+	.but {
+		width: 156rpx;
+		height: 90rpx;
+		background: #3874F6;
+		border-radius: 8rpx;
+		font-size: 28rpx;
+		font-family: PingFang SC-Bold, PingFang SC;
+		font-weight: bold;
+		color: #FFFFFF;
+	}
+}

+ 142 - 0
select/orderFormLine/index.skeleton.wxml

@@ -0,0 +1,142 @@
+<!--
+此文件为开发者工具生成,生成时间: 2023/1/30下午1:28:47
+使用方法:
+在 E:\云链项目\e-wechat\select\orderFormLine\index.wxml 引入模板
+
+```
+<import src="index.skeleton.wxml"/>
+<template is="skeleton" wx:if="{{loading}}" />
+```
+
+在 E:\云链项目\e-wechat\select\orderFormLine\index.wxss 中引入样式
+```
+@import "./index.skeleton.wxss";
+```
+
+更多详细信息可以参考文档:https://developers.weixin.qq.com/miniprogram/dev/devtools/skeleton.html
+-->
+<template name="skeleton">
+  <view class="sk-container">
+    <view is="miniprogram_npm/@vant/weapp/search/index" class="search">
+      <view class="van-search index--van-search " style="background: #ffffff">
+        <view class="van-search__content index--van-search__content van-search__content--round index--van-search__content--round">
+          <view is="miniprogram_npm/@vant/weapp/field/index" class="van-search__field index--van-search__field ">
+            <view is="miniprogram_npm/@vant/weapp/cell/index">
+              <view class="field-index--van-field van-cell cell-index--van-cell van-cell--borderless cell-index--van-cell--borderless sk-pseudo sk-pseudo-circle" hover-class="van-cell--hover hover-class" hover-stay-time="70" style="padding: 5px 10px 5px 0; background-color: transparent;">
+                <view is="miniprogram_npm/@vant/weapp/icon/index" class="van-cell__left-icon-wrap cell-index--van-cell__left-icon-wrap">
+                  <view class="cell-index--van-cell__left-icon van-icon icon-index--van-icon van-icon-search icon-index--van-icon-search sk-pseudo sk-pseudo-circle" style="true"></view>
+                </view>
+                <view class="van-cell__value cell-index--van-cell__value ">
+                  <view class="van-field__body field-index--van-field__body van-field__body--search field-index--van-field__body--search">
+                    <view class="van-field__control field-index--van-field__control sk-image" cursor="-1" maxlength="-1" placeholder="请输入搜索关键词" placeholder-class="van-field__placeholder" placeholder-style="true" selection-end="-1" selection-start="-1" type="search"
+                      value="true"></view>
+                  </view>
+                </view>
+              </view>
+            </view>
+          </view>
+        </view>
+      </view>
+    </view>
+    <view class="total sk-transparent sk-text-30-0000-778 sk-text">共2个</view>
+    <view is="components/Yl_ListBox/index" id="ListBox">
+      <scroll-view scroll-y="true" class="ListBox-index--scroll-view" refresher-enabled="true" style="height: 640px;">
+        <navigator class="setclient-list-item" data-id="23">
+          <view class="mian">
+            <view is="miniprogram_npm/@vant/weapp/checkbox/index">
+              <view class="van-checkbox checkbox-index--van-checkbox ">
+                <view class="van-checkbox__icon-wrap checkbox-index--van-checkbox__icon-wrap">
+                  <view is="miniprogram_npm/@vant/weapp/icon/index" class="van-checkbox__icon checkbox-index--van-checkbox__icon van-checkbox__icon--square checkbox-index--van-checkbox__icon--square" style="font-size:14px">
+                    <view class="van-icon icon-index--van-icon van-icon-success icon-index--van-icon-success sk-pseudo sk-pseudo-circle" style="font-size:0.8em;line-height: 1.25em;"></view>
+                  </view>
+                </view>
+                <view class=" van-checkbox__label checkbox-index--van-checkbox__label van-checkbox__label--right checkbox-index--van-checkbox__label--right"></view>
+              </view>
+            </view>
+            <view class="img" data-file="[object Object],[object Object],[object Object],[object Object]">
+              <view is="miniprogram_npm/@vant/weapp/image/index">
+                <view class=" van-image image-index--van-image" style="width:100%;height:100%">
+                  <image class="van-image__img image-index--van-image__img sk-image" mode="scaleToFill" lazy-load="true"></image>
+                </view>
+              </view>
+            </view>
+            <view class="dec">
+              <view class="title line-1 sk-transparent sk-text-15-0000-687 sk-text">
+                测试新增
+              </view>
+              <view class="subfield line-1">
+                <text class="sk-transparent sk-text-14-7059-742 sk-text">标准订单:SO202211300014</text>
+              </view>
+              <view class="subfield line-1">
+                <text class="sk-transparent sk-text-14-7059-242 sk-text">数量:20</text>
+                <text class="sk-transparent sk-text-14-7059-438 sk-text">单价:10.00</text>
+              </view>
+              <view class="price line-1 sk-transparent">
+                可开票金额:
+                <text class="num sk-transparent sk-text-15-0000-691 sk-text">¥200元</text>
+              </view>
+            </view>
+          </view>
+          <view class="bot">
+            <text class="sk-transparent sk-text-33-3333-911 sk-text">型号:S</text>
+            <text class="sk-transparent sk-text-33-3333-308 sk-text">规格: --</text>
+          </view>
+        </navigator>
+        <navigator class="setclient-list-item" data-id="81">
+          <view class="mian">
+            <view is="miniprogram_npm/@vant/weapp/checkbox/index">
+              <view class="van-checkbox checkbox-index--van-checkbox ">
+                <view class="van-checkbox__icon-wrap checkbox-index--van-checkbox__icon-wrap">
+                  <view is="miniprogram_npm/@vant/weapp/icon/index" class="van-checkbox__icon checkbox-index--van-checkbox__icon van-checkbox__icon--square checkbox-index--van-checkbox__icon--square" style="font-size:14px">
+                    <view class="van-icon icon-index--van-icon van-icon-success icon-index--van-icon-success sk-pseudo sk-pseudo-circle" style="font-size:0.8em;line-height: 1.25em;"></view>
+                  </view>
+                </view>
+                <view class=" van-checkbox__label checkbox-index--van-checkbox__label van-checkbox__label--right checkbox-index--van-checkbox__label--right"></view>
+              </view>
+            </view>
+            <view class="img" data-file="[object Object],[object Object]">
+              <view is="miniprogram_npm/@vant/weapp/image/index">
+                <view class=" van-image image-index--van-image" style="width:100%;height:100%">
+                  <image class="van-image__img image-index--van-image__img sk-image" mode="scaleToFill" lazy-load="true"></image>
+                </view>
+              </view>
+            </view>
+            <view class="dec">
+              <view class="title line-1 sk-transparent sk-text-15-0000-536 sk-text">
+                暖通复合管
+              </view>
+              <view class="subfield line-1">
+                <text class="sk-transparent sk-text-14-7059-412 sk-text">标准订单:SO202301040009</text>
+              </view>
+              <view class="subfield line-1">
+                <text class="sk-transparent sk-text-14-7059-899 sk-text">数量:6</text>
+                <text class="sk-transparent sk-text-14-7059-60 sk-text">单价:900.36</text>
+              </view>
+              <view class="price line-1 sk-transparent">
+                可开票金额:
+                <text class="num sk-transparent sk-text-15-0000-835 sk-text">¥5402.16元</text>
+              </view>
+            </view>
+          </view>
+          <view class="bot">
+            <text class="sk-transparent sk-text-33-3333-633 sk-text">型号:DN20</text>
+            <text class="sk-transparent sk-text-33-3333-875 sk-text">规格: --</text>
+          </view>
+        </navigator>
+        <view style="height: 65px;"></view>
+        <view class="ListBox-index--safety"></view>
+      </scroll-view>
+    </view>
+    <view class="footer">
+      <view class="count sk-transparent sk-text-14-2857-413 sk-text">
+        已选:0
+      </view>
+      <view is="miniprogram_npm/@vant/weapp/button/index">
+        <button app-parameter="true" business-id="true" class="but van-button button-index--van-button van-button--default button-index--van-button--default van-button--normal button-index--van-button--normal van-button--disabled button-index--van-button--disabled van-button--unclickable button-index--van-button--unclickable sk-button sk-pseudo sk-pseudo-circle"
+          data-detail="null" form-type="true" hover-class="true" lang="true" open-type="true" send-message-img="true" send-message-path="true" send-message-title="true" session-from="true" style="true">
+          <view class="van-button__text button-index--van-button__text sk-transparent sk-text-15-0000-808 sk-text" style="background-position-x: 50%;">确定</view>
+        </button>
+      </view>
+    </view>
+  </view>
+</template>

+ 135 - 0
select/orderFormLine/index.skeleton.wxss

@@ -0,0 +1,135 @@
+/*
+此文件为开发者工具生成,生成时间: 2023/1/30下午1:28:48
+
+在 E:\云链项目\e-wechat\select\orderFormLine\index.wxss 中引入样式
+```
+@import "./index.skeleton.wxss";
+```
+
+更多详细信息可以参考文档:https://developers.weixin.qq.com/miniprogram/dev/devtools/skeleton.html
+*/
+.sk-transparent {
+    color: transparent !important;
+  }
+.sk-text-30-0000-778 {
+    background-image: linear-gradient(transparent 30.0000%, #EEEEEE 0%, #EEEEEE 70.0000%, transparent 0%) !important;
+    background-size: 100% 60.0000rpx;
+    position: relative !important;
+  }
+.sk-text {
+    background-origin: content-box !important;
+    background-clip: content-box !important;
+    background-color: transparent !important;
+    color: transparent !important;
+    background-repeat: repeat-y !important;
+  }
+.sk-text-15-0000-687 {
+    background-image: linear-gradient(transparent 15.0000%, #EEEEEE 0%, #EEEEEE 85.0000%, transparent 0%) !important;
+    background-size: 100% 40.0000rpx;
+    position: relative !important;
+  }
+.sk-text-14-7059-742 {
+    background-image: linear-gradient(transparent 14.7059%, #EEEEEE 0%, #EEEEEE 85.2941%, transparent 0%) !important;
+    background-size: 100% 34.0000rpx;
+    position: relative !important;
+  }
+.sk-text-14-7059-242 {
+    background-image: linear-gradient(transparent 14.7059%, #EEEEEE 0%, #EEEEEE 85.2941%, transparent 0%) !important;
+    background-size: 100% 34.0000rpx;
+    position: relative !important;
+  }
+.sk-text-14-7059-438 {
+    background-image: linear-gradient(transparent 14.7059%, #EEEEEE 0%, #EEEEEE 85.2941%, transparent 0%) !important;
+    background-size: 100% 34.0000rpx;
+    position: relative !important;
+  }
+.sk-text-15-0000-691 {
+    background-image: linear-gradient(transparent 15.0000%, #EEEEEE 0%, #EEEEEE 85.0000%, transparent 0%) !important;
+    background-size: 100% 40.0000rpx;
+    position: relative !important;
+  }
+.sk-text-33-3333-911 {
+    background-image: linear-gradient(transparent 33.3333%, #EEEEEE 0%, #EEEEEE 66.6667%, transparent 0%) !important;
+    background-size: 100% 72.0000rpx;
+    position: relative !important;
+  }
+.sk-text-33-3333-308 {
+    background-image: linear-gradient(transparent 33.3333%, #EEEEEE 0%, #EEEEEE 66.6667%, transparent 0%) !important;
+    background-size: 100% 72.0000rpx;
+    position: relative !important;
+  }
+.sk-text-15-0000-536 {
+    background-image: linear-gradient(transparent 15.0000%, #EEEEEE 0%, #EEEEEE 85.0000%, transparent 0%) !important;
+    background-size: 100% 40.0000rpx;
+    position: relative !important;
+  }
+.sk-text-14-7059-412 {
+    background-image: linear-gradient(transparent 14.7059%, #EEEEEE 0%, #EEEEEE 85.2941%, transparent 0%) !important;
+    background-size: 100% 34.0000rpx;
+    position: relative !important;
+  }
+.sk-text-14-7059-899 {
+    background-image: linear-gradient(transparent 14.7059%, #EEEEEE 0%, #EEEEEE 85.2941%, transparent 0%) !important;
+    background-size: 100% 34.0000rpx;
+    position: relative !important;
+  }
+.sk-text-14-7059-60 {
+    background-image: linear-gradient(transparent 14.7059%, #EEEEEE 0%, #EEEEEE 85.2941%, transparent 0%) !important;
+    background-size: 100% 34.0000rpx;
+    position: relative !important;
+  }
+.sk-text-15-0000-835 {
+    background-image: linear-gradient(transparent 15.0000%, #EEEEEE 0%, #EEEEEE 85.0000%, transparent 0%) !important;
+    background-size: 100% 40.0000rpx;
+    position: relative !important;
+  }
+.sk-text-33-3333-633 {
+    background-image: linear-gradient(transparent 33.3333%, #EEEEEE 0%, #EEEEEE 66.6667%, transparent 0%) !important;
+    background-size: 100% 72.0000rpx;
+    position: relative !important;
+  }
+.sk-text-33-3333-875 {
+    background-image: linear-gradient(transparent 33.3333%, #EEEEEE 0%, #EEEEEE 66.6667%, transparent 0%) !important;
+    background-size: 100% 72.0000rpx;
+    position: relative !important;
+  }
+.sk-text-14-2857-413 {
+    background-image: linear-gradient(transparent 14.2857%, #EEEEEE 0%, #EEEEEE 85.7143%, transparent 0%) !important;
+    background-size: 100% 39.2000rpx;
+    position: relative !important;
+  }
+.sk-text-15-0000-808 {
+    background-image: linear-gradient(transparent 15.0000%, #EEEEEE 0%, #EEEEEE 85.0000%, transparent 0%) !important;
+    background-size: 100% 40.0000rpx;
+    position: relative !important;
+  }
+.sk-button {
+    color: #EFEFEF !important;
+    background: #EFEFEF !important;
+    border: none !important;
+    box-shadow: none !important;
+  }
+.sk-image {
+    background: #EFEFEF !important;
+  }
+.sk-pseudo::before, .sk-pseudo::after {
+      background: #EFEFEF !important;
+      background-image: none !important;
+      color: transparent !important;
+      border-color: transparent !important;
+    }
+.sk-pseudo-rect::before, .sk-pseudo-rect::after {
+      border-radius: 0 !important;
+    }
+.sk-pseudo-circle::before, .sk-pseudo-circle::after {
+      border-radius: 50% !important;
+    }
+.sk-container {
+    position: absolute;
+    left: 0;
+    top: 0;
+    width: 100%;
+    height: 100%;
+    overflow: hidden;
+    background-color: transparent;
+  }

+ 59 - 0
select/orderFormLine/index.wxml

@@ -0,0 +1,59 @@
+<import src="index.skeleton.wxml"/>
+<template is="skeleton" wx:if="{{loading}}" />
+
+<van-search class="search" value="{{ params.content.where.condition }}" shape="round" placeholder="请输入搜索关键词" bind:search='startSearch' bind:clear='onClear' />
+<view class="total">共{{params.content.total}}个</view>
+
+<Yl_ListBox id='ListBox' bind:getlist='getList'>
+	<navigator class="setclient-list-item" url="#" wx:for="{{list}}" wx:key="itemno" data-id="{{item[idname]}}" bindtap="changeResult">
+		<view class="mian">
+			<van-checkbox wx:if="{{!radio}}" value="{{ handle.isCheck(item[idname],result) }}" shape="square" icon-size='28rpx' />
+			<view class="img" data-file="{{item.attinfos}}" catchtap="viewImage">
+				<van-image width="100%" height="100%" wx:if="{{item.cover}}" src="{{item.cover}}" use-loading-slot use-error-slot lazy-load>
+					<van-loading slot="loading" type="spinner" size="20" vertical />
+					<text slot="error" style="font-size: 24rpx;">暂无图片</text>
+				</van-image>
+				<text wx:else class="err">暂无图片</text>
+			</view>
+			<view class="dec">
+				<view class="title line-1">
+					{{item.itemname}}
+				</view>
+				<view class="subfield line-1">
+					<text>{{item.type}}:{{item.sonum||' --'}}</text>
+				</view>
+				<view class="subfield line-1">
+					<text>数量:{{item.qty||' --'}}</text>
+					<text>单价:{{item.price||' --'}}</text>
+				</view>
+				<view class="price line-1">
+					可开票金额:<text class="num">¥{{item.amount - item.invoiceamount}}元</text>
+				</view>
+			</view>
+		</view>
+		<view class="bot">
+			<text>型号:{{item.model||' --'}}</text>
+			<text>规格:{{item.spec||' --'}}</text>
+		</view>
+	</navigator>
+	<view wx:if="{{!radio}}" style="height: 130rpx;" />
+	<Yl_Empty wx:if="{{list.length==0}}" />
+</Yl_ListBox>
+
+<block wx:if="{{!radio}}">
+	<view class="footer">
+		<view class="count">
+			已选:{{result.length}}
+		</view>
+		<van-button custom-class='but' disabled='{{result.length==0}}' bind:click="submit">确定</van-button>
+	</view>
+	<wxs module="handle">
+		module.exports = {
+			isCheck: function (id, list) {
+				return list.some(function (v) {
+					return v == id
+				});
+			},
+		}
+	</wxs>
+</block>

+ 3 - 0
select/product/index.js

@@ -48,6 +48,9 @@ Page({
 					let image = value.attinfos.find(v => v.fileType == "image");
 					value.cover = image ? image.cover : "";
 				}
+				value.gradeprice && (value.gradeprice = (value.gradeprice - 0).toFixed(2));
+				value.price && (value.price = (value.price - 0).toFixed(2));
+				value.oldprice && (value.oldprice = (value.oldprice - 0).toFixed(2));
 				value.brandName = value.brand.map(name => name.brandname)
 				value.tradefields = value.tradefield.map(name => name.tradefield)
 				return value;