付延余
2022-12-19 8fc8838a441ae3d3b1616f4fc003b16292978b54
注册,登录,主页,日计划的修改
18个文件已修改
2个文件已添加
5661 ■■■■ 已修改文件
api/global.js 2 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
manifest.json 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
pages.json 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
pages/approval-history/approval-history.vue 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
pages/check-the-schedule/check-the-schedule.vue 6 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
pages/edit-my-application/edit-my-application.vue 176 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
pages/home/home.vue 271 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
pages/jihua/jihua.vue 427 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
pages/login/login.vue 155 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
pages/my-application/my-application.vue 202 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
pages/my-have-todo/my-have-todo.vue 17 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
pages/my-todo/my-todo.vue 50 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
pages/new-application-form-data/new-application-form-data.vue 4044 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
pages/new-application/new-application.vue 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
pages/register/register.vue 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
static/cursor.gif 补丁 | 查看 | 原始文档 | blame | 历史
utils/api.js 229 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
utils/jihua.js 6 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
utils/request.js 22 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
utils/tool.js 36 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
api/global.js
@@ -29,6 +29,8 @@
// const baseUrl = 'http://192.168.3.159:9999'
// const baseUrl = 'https://mx.jzeg.cn:443/app';
// let baseUrl = 'http://192.168.0.114:9999';
const baseUrl = "https://mx.jzeg.cn:9998"; // 正式服务
// POST请求
manifest.json
@@ -53,7 +53,7 @@
        "appid" : "wx69ae2830c7d22d5a",
        "setting" : {
            "urlCheck" : false,
            "es6" : true,
            "es6" : false,
            "minified" : true
        },
        "usingComponents" : true
pages.json
@@ -3,8 +3,8 @@
        {
            "path": "pages/login/login",
            "style": {
                // "navigationStyle": "custom"
                "navigationBarTitleText": "请登录",
                "navigationStyle": "custom",
                // "navigationBarTitleText": "请登录",
                "enablePullDownRefresh": false
            }
        },
pages/approval-history/approval-history.vue
@@ -29,7 +29,7 @@
                </uni-tr>
                <uni-tr>
                    <uni-th align="center">审批意见</uni-th>
                    <uni-td>{{ item.comment == null ? '' : item.comment }}</uni-td>
                    <uni-td>{{ item.comment=='undefined'?item.endTime?'未填写':'':item.comment|| item.endTime?'未填写':'' }}</uni-td>
                </uni-tr>
                <uni-tr>
                    <uni-th align="center">耗时</uni-th>
@@ -48,7 +48,7 @@
                </uni-tr>
                <uni-tr>
                    <uni-th align="center">完成时间</uni-th>
                    <uni-td>{{ item.endTime == null ? '' : item.endTime }}</uni-td>
                    <uni-td>{{ item.endTime ||'' }}</uni-td>
                </uni-tr>
                <uni-tr>
                    <uni-th align="center">状态</uni-th>
pages/check-the-schedule/check-the-schedule.vue
@@ -19,11 +19,11 @@
        </uni-tr>
        <uni-tr>
          <uni-th align="center">审批操作</uni-th>
          <uni-td>{{ item.deleteReason == null ? '' : item.deleteReason }}</uni-td>
          <uni-td>{{ item.deleteReason || ''  }}</uni-td>
        </uni-tr>
        <uni-tr>
          <uni-th align="center">审批意见</uni-th>
          <uni-td>{{ item.comment == null ? '' : item.comment }}</uni-td>
          <uni-td>{{ item.comment=='undefined'?'未填写':item.comment|| '未填写' }}</uni-td>
        </uni-tr>
        <uni-tr>
          <uni-th align="center">耗时</uni-th>
@@ -44,7 +44,7 @@
        </uni-tr>
        <uni-tr>
          <uni-th align="center">完成时间</uni-th>
          <uni-td>{{ item.endTime == null ? '' : item.endTime }}</uni-td>
          <uni-td>{{ item.endTime ||'' }}</uni-td>
        </uni-tr>
        <uni-tr>
          <uni-th align="center">状态</uni-th>
pages/edit-my-application/edit-my-application.vue
@@ -4,6 +4,9 @@
        <combination-title class="newApplicationTitle" title="新增"></combination-title>
        <view class="formDataContaniner">
            <u--form labelPosition="left" :model="newFormData" ref="formRef">
                <u-form-item @click="selectLedger" labelWidth="20%" label="账套" borderBottom>
                    <u--input disabled disabledColor="#ffffff" v-model="ledgerName" border="none"></u--input>
                </u-form-item>
                <u-form-item labelWidth="20%" label="结算客户" borderBottom ref="customerNameRef">
                    <u--input v-model="newFormData.customerName" disabled disabledColor="#ffffff" border="none"></u--input>
                </u-form-item>
@@ -27,8 +30,19 @@
            </u--form>
        </view>
        <!-- 选择账套 -->
        <u-picker
            @change="selectLedgerChange"
            @confirm="selectLedgerConfirm"
            @cancel="selectLedgerCancel"
            @close="selectLedgerClose"
            :show="selectLedgerShow"
            :columns="ledgerList"
            keyName="name"
        ></u-picker>
        <!-- 申请日历、范围时间 -->
        <u-calendar :show="timeShow" :mode="mode" @confirm="confirmTime" @close="timeClose" rowHeight="110" :maxDate="maxDate"></u-calendar>
        <u-calendar :show="timeShow" :mode="mode" @confirm="confirmTime" @close="timeClose" rowHeight="110"></u-calendar>
        <!-- 添加合同子项 -->
        <view class="addContractContainer">
            <u-popup :show="addContractShow" @close="addContractClose" @open="addContractOpen" mode="bottom" round="22">
@@ -381,6 +395,7 @@
<script>
import combinationTitle from '@/components/common/combined-title/combined-title.vue';
import popupMenu from '@/components/common/popup-menu/popup-menu.vue';
import { BaseUrl } from '@/utils/request.js';
// 最大显示的日期
const d = new Date();
@@ -391,6 +406,10 @@
export default {
    data() {
        return {
            // 账套选择器
            selectLedgerShow: false,
            ledgerList: [],
            ledgerName: '',
            applicationOrderIndex: null,
            tdStyle: 'max-height: 30px;overflow: scroll;',
            spanStyle: 'overflow:auto',
@@ -408,7 +427,6 @@
            // 时间
            timeShow: false,
            mode: 'range',
            maxDate: `${year}-${month}-${date + 70}`,
            // 选择客户
            selectCustomerData: {
                compIds: '',
@@ -637,6 +655,7 @@
            }
        },
        init() {
            this.getLedgerList(); // 账套列表
            this.jcfavouredpolicyitem();
            this.coalfiled();
            this.coalprice();
@@ -646,6 +665,76 @@
            this.fetchCompTree();
            this.getFavouredPolicyItem();
            this.editApplicationFormData(); // 修改申请表单详情
        },
        /**
         * 获取分类账套
         */
        getLedgerList() {
            this.$reqGet('zhaccountledger', { compId: uni.getStorageSync('userInfo').compId }).then(res => {
                this.ledgerList.push(res.data.records);
                // console.log('账套列表',this.ledgerList);
                // if (res.data.records) {
                //     this.newFormData.ledgerId = res.data.records[0].id;
                //     this.ledgerName = res.data.records[0].name;
                // }
            });
        },
        selectLedger() {
            this.selectLedgerShow = true;
        },
        selectLedgerChange(index) {
            console.log('账套选择器', index);
            // if(this.newFormData.customerName||this.newFormData.contractNum||this.newFormData.contractName){
            //     this.newFormData.customerName = '';
            //     this.newFormData.contractNum = '';
            //     this.newFormData.contractName = '';
            // }
        },
        async selectLedgerConfirm(index) {
            console.log('选择账套点击确定', index);
            this.selectLedgerShow = false;
            await this.$reqGet('getAccount', { customerId: this.newFormData.customerId, ledgerId: index.value[0].id }).then(res => {
                let accountReq = res.data;
                let amountPrice = 0;
                this.newFormData.contractOrders.forEach(item => {
                    amountPrice += Number(item.amount);
                });
                console.log('价格合计', amountPrice);
                if (this.newFormData.payType == 0) {
                    if (accountReq.balance > amountPrice) {
                        this.ledgerName = index.value[0].name;
                        this.newFormData.ledgerId = index.value[0].id;
                        this.accountDetails = accountReq;
                    } else {
                        uni.showToast({
                            title: '账户内现汇余额:' + accountReq.balance +',不足支付现在订单',
                            icon: 'none'
                        });
                    }
                } else if (this.newFormData.payType == 1) {
                    if (accountReq.balance2 > amountPrice) {
                        this.ledgerName = index.value[0].name;
                        this.newFormData.ledgerId = index.value[0].id;
                        this.accountDetails = accountReq;
                    } else {
                        uni.showToast({
                            title: '账户内承兑余额:'+accountReq.balance2+',不足支付现在订单',
                            icon: 'none'
                        });
                    }
                }
            });
        },
        selectLedgerCancel() {
            this.selectLedgerShow = false;
        },
        selectLedgerClose() {
            this.selectLedgerShow = false;
        },
        // 初始化申请表单
        async editApplicationFormData() {
@@ -658,6 +747,7 @@
                console.log('整体详情', res.data);
                this.newFormData = res.data;
                this.timeDataStr = this.newFormData.startDate;
                this.ledgerName = res.data.ledgerName;
            });
            // 获取合同详情,煤种
@@ -665,7 +755,7 @@
            // 初始化当前申请客户账户情况
            if (this.newFormData.customerId) {
                await this.$reqGet('getAccount', { customerId: this.newFormData.customerId }).then(res => {
                await this.$reqGet('getAccount', { customerId: this.newFormData.customerId, ledgerId: this.newFormData.ledgerId }).then(res => {
                    this.accountDetails = res.data;
                });
            }
@@ -821,7 +911,7 @@
        selectCustomerOkClick(v) {
            this.newFormData.customerName = v.customerName;
            this.newFormData.customerId = v.id;
            this.$reqGet('getAccount', { customerId: v.id }).then(res => {
            this.$reqGet('getAccount', { customerId: v.id,ledgerId: this.newFormData.ledgerId }).then(res => {
                this.accountDetails = res.data;
                this.searchContractForm.customerName = res.data.customerName;
@@ -893,7 +983,9 @@
                        quant: '',
                        toStation: '',
                        trainType: 1,
                        type: ''
                        type: '',
                        ledgerId:null,
                        ledgerName:''
                    };
                    // 运输类型初始化
                    switch (this.addContractFormdata.trainType) {
@@ -949,21 +1041,11 @@
        addContractConsignee() {
            this.addContractConsigneeShow = true;
        },
        // 收货人
        addContractConsigneeConfirm(v) {
            // console.log('收货人', v);
            this.addContractFormdata.toStation = v.toStation;
            this.addContractFormdata.customerName = v.customerName;
            this.addContractFormdata.customerId = v.id;
            this.$reqGet('getAccount', { customerId: v.id }).then(res => {
                // console.log('获取收货人账号', res);
                // this.accountDetails = res.data;
                // this.newFormData.customerName = res.data.customerName;
                // this.newFormData.customerId = res.data.id;
                // this.searchContractForm.customerName = res.data.customerName;
            });
            this.$nextTick(() => {
                this.addContractConsigneeShow = false;
            });
            // 赋值给取价格请求参数
            this.getNewPriceData.customerAddressName = v.customerFullName;
@@ -983,6 +1065,7 @@
                }
                this.addContractCoalData.push(a);
            });
            this.addContractConsigneeShow = false;
        },
        // 品种选择器
        addContractCoalConfirm(e) {
@@ -1183,40 +1266,43 @@
            this.newFormData.contractOrders.forEach(e => {
                amount += Number(e.amount);
            });
            if (this.newFormData.payType == '0') {
                if (this.newFormData.contractOrders.length <= 0) {
                    this.$u.toast('请添加订单子项!');
                    return false;
                } else if (this.accountDetails.balance < amount) {
                    let msg = this.accountDetails.balance == null ? 0 : this.accountDetails.balance;
                    this.$u.toast('客户账户承兑余额不足,承兑余额:' + msg);
                } else {
                    uni.showLoading({
                        title: '加载中...'
                    });
                    this.editShenQing();
                    // this.xswaybill();
            console.log(typeof this.newFormData.payType);
            if (this.newFormData.contractOrders.length > 0) {
                if (this.newFormData.payType == 0) {
                    if (this.accountDetails.balance < amount) {
                        let msg = this.accountDetails.balance == null ? 0 : this.accountDetails.balance;
                        this.$u.toast('客户账户现汇余额不足,承兑余额:' + msg);
                    } else {
                        uni.showLoading({
                            title: '加载中...'
                        });
                        this.editShenQing();
                        // this.xswaybill();
                    }
                } else if (this.newFormData.payType == 1) {
                    if (this.accountDetails.balance2 < amount) {
                        let msg = this.accountDetails.balance2 == null ? 0 : this.accountDetails.balance2;
                        this.$u.toast('客户账户承兑余额不足,承兑余额:' + msg);
                    } else {
                        uni.showLoading({
                            title: '加载中...'
                        });
                        this.editShenQing();
                    }
                }
            } else {
                if (this.newFormData.contractOrders.length <= 0) {
                    this.$u.toast('请添加订单子项!');
                    return false;
                } else if (this.accountDetails.balance2 < amount) {
                    let msg = this.accountDetails.balance2 == null ? 0 : this.accountDetails.balance2;
                    this.$u.toast('客户账户承兑余额不足,承兑余额:' + msg);
                } else {
                    uni.showLoading({
                        title: '加载中...'
                    });
                    this.editShenQing();
                }
                uni.showToast({
                    title: '请添加订单子项!',
                    icon: 'none'
                });
            }
        },
        // 修改申请信息
        editShenQing() {
            console.log('editApp-------');
            uni
                .request({
                    url: this.baseUrl + '/yunxiao/xswaybill',
                    url: BaseUrl + '/yunxiao/xswaybill',
                    method: 'PUT',
                    data: this.newFormData,
                    header: {
@@ -1227,7 +1313,11 @@
                })
                .then(res => {
                    uni.hideLoading();
                    this.$u.toast('修改成功');
                    uni.showToast({
                        title:'修改成功!',
                        icon:'none',
                        duration:1500
                    })
                    this.$nextTick(() => {
                        uni.navigateBack({
                            delta: 1
pages/home/home.vue
@@ -50,7 +50,7 @@
                    <view class="bottom-container">
                        <!-- 按钮区域 -->
                        <view class="bottom-content__chulizhong bottom-content__item">
                            <view @click="withDrawClick(item.id)" v-if="item.status == 1">
                            <view @click="withDrawClick(item.procInstId)" v-if="item.status == 1">
                                <image src="@/static/home/cehui.png" mode=""></image>
                                <view>撤回</view>
                            </view>
@@ -58,21 +58,25 @@
                                <image src="@/static/home/jindu.png" mode=""></image>
                                <view>查看进度</view>
                            </view>
                            <view @click="theFormDataClick(item.tableId)" v-if="(item.status == 1 || item.status == 2) && item.procDefId == 'WAY_BILL:4:87504'">
                            <view @click="theFormDataClick(item.tableId)" v-if="(item.status == 1 || item.status == 2 || item.status == 3) && item.processName == '发运通知单'">
                                <image src="@/static/home/biaodan.png" mode=""></image>
                                <view>表单数据</view>
                                <view>申请详情</view>
                            </view>
                            <view @click="apply(item)" v-if="item.status == 3">
                            <!-- <view @click="apply(item)" v-if="item.status == 3">
                                <image src="@/static/home/history.png" mode=""></image>
                                <view>重新申请</view>
                            </view>
                            <view @click="editMyApplication(item)" v-if="item.status == 3 && item.procDefId == 'WAY_BILL:4:87504'">
                            </view> -->
                            <view @click="editMyApplication(item)" v-if="item.status == 1 && item.processName == '发运通知单'">
                                <image src="@/static/home/history.png" mode=""></image>
                                <view>编辑</view>
                            </view>
                            <view @click="approvalHistoryClick(item.procInstId)" v-if="item.status == 2 || item.status == 3">
                                <image src="@/static/home/history.png" mode=""></image>
                                <view>审批历史</view>
                            </view>
                            <view @click="deleteWithDrawApplication(item.tableId)" v-if="item.status == 3">
                                <image src="@/static/home/delete.png" mode=""></image>
                                <view>删除</view>
                            </view>
                        </view>
                        <!-- 已结束小组按钮 -->
@@ -120,10 +124,10 @@
                    <view class="bottom-container">
                        <!-- 待办按钮 -->
                        <view class="bottom-content__item">
                            <!-- <view @click="theFormDataClick">
                            <view @click="theFormDataClick(item.tableId)">
                <image src="@/static/home/jindu.png" mode=""></image>
                <view>申请详情</view>
              </view> -->
              </view>
                            <view @click="adopClick(item)">
                                <image src="@/static/home/tongguo.png" mode=""></image>
                                <view>通过</view>
@@ -163,7 +167,7 @@
                        </view>
                        <view class="center-content__two center-margin">
                            <view>
                                <text>发起人:{{ item.actBusiness.createByName }}</text>
                                <text>发起人:{{ item.actBusiness.createByName || '' }}</text>
                            </view>
                            <view>
                                <text>审批操作:{{ item.deleteReason }}</text>
@@ -171,7 +175,7 @@
                        </view>
                        <view class="center-content__three center-margin">
                            <view class="">
                                <text>审批意见:{{ item.comment || '' }}</text>
                                <text>审批意见:{{ item.comment=='undefined'?'未填写':item.comment || '未填写' }}</text>
                            </view>
                            <view class="">
                                <text>
@@ -194,7 +198,7 @@
                    <view class="bottom-container">
                        <!-- 已办按钮 -->
                        <view class="bottom-content__item">
                            <view @click="theFormDataClick(item.tableId)" v-if="item.procDefId == 'WAY_BILL:4:87504'">
                            <view @click="theFormDataClick(item.tableId)" v-if="item.processName == '发运通知单'">
                                <image src="@/static/home/biaodan.png" mode=""></image>
                                <view>表单数据</view>
                            </view>
@@ -245,8 +249,11 @@
        <!-- 撤回模态框 -->
        <view class="wodeshenqingMotai">
            <u-modal width="684rpx" :show="withDrawShow" title="撤回原因" :showCancelButton="true" @confirm="withDrawConfirm" @cancel="withDrawCancel">
                <view class="slot-content"><u--textarea v-model="withDrawData.reason" placeholder="请输入撤回原因"></u--textarea></view>
            <u-modal width="684rpx" :show="withDrawShow" title="提示" :showCancelButton="true" @confirm="withDrawConfirm" @cancel="withDrawCancel">
                <view class="slot-content">
                    <!-- <u--textarea v-model="withDrawData.reason" placeholder="请输入撤回原因"></u--textarea> -->
                    <text>确认撤回该申请吗?</text>
                </view>
            </u-modal>
        </view>
@@ -309,10 +316,10 @@
                    <view class="top"><u-icon name="backspace" color="#FF4233" size="70"></u-icon></view>
                    <view class="bottom-text"><text>退出</text></view>
                </view>
                <view class="utils-container-body" @click="huanBang">
                <!-- <view class="utils-container-body" @click="huanBang">
                    <view class="top"><u-icon name="lock-open" color="#1987FF" size="70"></u-icon></view>
                    <view class="bottom-text"><text>换绑</text></view>
                </view>
                </view> -->
            </view>
        </view>
        <u-gap height="60" bgColor="#eeeeee"></u-gap>
@@ -368,8 +375,8 @@
            withDrawShow: false,
            fyData: [],
            withDrawData: {
                reason: '',
                id: '', // 撤回申请ID
                // reason: '',
                // id: '', // 撤回申请ID
                procInstId: ''
            },
            withDrawContent: '',
@@ -594,18 +601,12 @@
            this.menuShow = e;
        },
        // 撤回模态框
        withDrawClick(id) {
        withDrawClick(procInstId) {
            this.withDrawShow = true;
            this.withDrawData.id = id;
            this.withDrawData.procInstId = procInstId;
        },
        withDrawConfirm() {
            this.shenqingData.forEach(i => {
                if (i.id == this.withDrawData.id) {
                    this.withDrawData.procInstId = i.procInstId;
                }
            });
            if (this.withDrawData.reason.length >= 2) {
                this.$reqPost('withDraw', this.withDrawData, 'form').then(res => {
                this.$reqPost('cancel', this.withDrawData).then(res => {
                    this.withDrawShow = false;
                    if (res.code == 0) {
                        uni.showToast({
@@ -613,14 +614,14 @@
                            duration: 2000
                        });
                    }
                    // 刷新列表
                    this.getProcessDataList();
                    this.todoList();
                    this.doneList();
                });
            } else {
                uni.showToast({
                    title: '请规范输入',
                    duration: 2000
                });
            }
        },
        withDrawCancel() {
            this.withDrawShow = false;
        },
        // 通过
        adopClick(v) {
@@ -637,13 +638,14 @@
        adoptModalConfirm() {
            this.adoptModalShow = false;
            this.adoptForm.comment = this.adoptModalContent;
            this.$reqPost('passAll', this.adoptForm, 'form').then(res => {
            this.$reqPost('passAll', this.adoptForm).then(res => {
                if (res.code == 0) {
                    this.$u.toast('操作成功!');
                } else {
                    this.$u.toast('添加失败!!');
                    this.$u.toast('通过失败!!');
                }
                this.todoList(); // 我的待办
                this.doneList();
            });
        },
        adoptModalCancel() {
@@ -659,20 +661,24 @@
        rejectModalConfirm() {
            this.rejectModalShow = false;
            this.$reqPost('backAll', this.rejectForm, 'form').then(res => {
            this.$reqPost('backAll', this.rejectForm).then(res => {
                if (res.code == 0) {
                    this.$u.toast('操作成功!');
                } else {
                    this.$u.toast('操作失败!!!');
                }
                this.todoList(); // 我的待办
                this.doneList();
            });
        },
        rejectModalCancel() {
            this.rejectModalShow = false;
        },
        withDrawCancel() {
            this.withDrawShow = false;
        // 删除申请
        deleteApplicationClick(id) {
            this.deleteApplicationModalShow = true;
            this.procInstId = id;
            console.log(id);
        },
        // 删除申请模态框
        deleteApplicationModalConfirm() {
@@ -702,83 +708,112 @@
                url: `/pages/the-form-data/the-form-data?index=${v}`
            });
        },
        // 重新申请
        apply(v) {
            if (!v.procDefId || v.procDefId == 'null') {
                this.$u.toast('流程定义为空');
                return;
            }
            this.form.id = v.id;
            this.form.procDefId = v.procDefId;
            this.form.title = v.title;
            // 加载审批人
            // this.userLoading = true;
            uni.showLoading({
                title: '审批人加载中'
            });
            // getFirstNode(v.procDefId).then((res) => {
            this.$reqGet('getFirstNode', {}, v.procDefId).then(res => {
                // this.userLoading = false;
                console.log('审批人', res);
                uni.hideLoading();
                if (res.data) {
                    this.error = '';
                    if (res.data.type == 3 || res.data.type == 4) {
                        this.isGateway = true;
                        this.form.firstGateway = true;
                        this.showAssign = false;
                        this.isCustom = false;
                        return;
        // 删除撤回申请
        deleteWithDrawApplication(id){
            uni
                .request({
                    url: `${BaseUrl}/yunxiao/xswaybill/${id}`,
                    method: 'DELETE',
                    header: {
                        'TENANT-ID': 5,
                        Authorization: 'Bearer ' + uni.getStorageSync('access_token'),
                        VERSION: 'zzl'
                    }
                    if (res.data.type == 5) {
                        this.isCustom = true;
                        this.isGateway = false;
                        this.form.firstGateway = false;
                        this.showAssign = false;
                        return;
                    }
                    if (res.data.type == 1) {
                        this.showAssign = true;
                        this.isGateway = false;
                        this.form.firstGateway = false;
                        this.isCustom = false;
                        if (res.data.users && res.data.users.length > 0) {
                            this.assigneeList = res.data.users;
                            // 默认勾选
                            let ids = [];
                            res.data.users.forEach(e => {
                                ids.push(e.userId);
                            });
                            this.form.assignees = ids;
                            this.showAssign = true;
                            // 获取表单内容,重新创建申请
                            this.$reqPost('apply', this.form, 'form').then(res => {
                                console.log('重新提交申请', res);
                                if (res.code == 0) {
                                    uni.showToast({
                                        title: res.data,
                                        icon: 'success',
                                        duration: 2000
                                    });
                                }
                                // 初始化申请列表
                                // this.myApplication.pageNumber = 1;
                                // this.shenqingData = [];
                                // this.getMoreNews();
                                this.getProcessDataList();
                            });
                        } else {
                            this.form.assignees = [];
                            this.showAssign = true;
                            this.error = '请进入"流程管理"为审批节点分配候选审批人员';
                        }
                    }
                }
                console.log(this.form);
            });
            this.modalVisible = true;
                })
                .then(res => {
                    uni.showToast({
                        title:'删除成功',
                        icon:'none'
                    })
                    // 刷新列表
                    this.getProcessDataList();
                })
                .catch(err => {
                    uni.showToast({
                        title:'删除出错',
                        icon:'none'
                    })
                });
        },
        // 重新申请
        // apply(v) {
        //     if (!v.procDefId || v.procDefId == 'null') {
        //         this.$u.toast('流程定义为空');
        //         return;
        //     }
        //     this.form.id = v.id;
        //     this.form.procDefId = v.procDefId;
        //     this.form.title = v.title;
        //     // 加载审批人
        //     // this.userLoading = true;
        //     uni.showLoading({
        //         title: '审批人加载中'
        //     });
        //     // getFirstNode(v.procDefId).then((res) => {
        //     this.$reqGet('getFirstNode', {}, v.procDefId).then(res => {
        //         // this.userLoading = false;
        //         console.log('审批人', res);
        //         uni.hideLoading();
        //         if (res.data) {
        //             this.error = '';
        //             if (res.data.type == 3 || res.data.type == 4) {
        //                 this.isGateway = true;
        //                 this.form.firstGateway = true;
        //                 this.showAssign = false;
        //                 this.isCustom = false;
        //                 return;
        //             }
        //             if (res.data.type == 5) {
        //                 this.isCustom = true;
        //                 this.isGateway = false;
        //                 this.form.firstGateway = false;
        //                 this.showAssign = false;
        //                 return;
        //             }
        //             if (res.data.type == 1) {
        //                 this.showAssign = true;
        //                 this.isGateway = false;
        //                 this.form.firstGateway = false;
        //                 this.isCustom = false;
        //                 if (res.data.users && res.data.users.length > 0) {
        //                     this.assigneeList = res.data.users;
        //                     // 默认勾选
        //                     let ids = [];
        //                     res.data.users.forEach(e => {
        //                         ids.push(e.userId);
        //                     });
        //                     this.form.assignees = ids;
        //                     this.showAssign = true;
        //                     // 获取表单内容,重新创建申请
        //                     this.$reqPost('apply', this.form, 'form').then(res => {
        //                         console.log('重新提交申请', res);
        //                         if (res.code == 0) {
        //                             uni.showToast({
        //                                 title: res.data,
        //                                 icon: 'success',
        //                                 duration: 2000
        //                             });
        //                         }
        //                         // 初始化申请列表
        //                         // this.myApplication.pageNumber = 1;
        //                         // this.shenqingData = [];
        //                         // this.getMoreNews();
        //                         this.getProcessDataList();
        //                     });
        //                 } else {
        //                     this.form.assignees = [];
        //                     this.showAssign = true;
        //                     this.error = '请进入"流程管理"为审批节点分配候选审批人员';
        //                 }
        //             }
        //         }
        //         console.log(this.form);
        //     });
        //     this.modalVisible = true;
        // },
        // 修改
        editMyApplication(v) {
            console.log('修改申请');
@@ -792,12 +827,7 @@
                url: `/pages/approval-history/approval-history?index=${v}`
            });
        },
        // 删除申请
        deleteApplicationClick(id) {
            this.deleteApplicationModalShow = true;
            this.procInstId = id;
            console.log(id);
        },
        redirectLogin() {
            redirectLogin();
        },
@@ -820,7 +850,8 @@
    .utils {
        .utils-container {
            display: flex;
            justify-content: space-between;
            // justify-content: space-between;
            justify-content: center;
            width: 66%;
            margin: 0 auto;
            .utils-container-body {
pages/jihua/jihua.vue
@@ -1,5 +1,6 @@
<template>
    <view class="jihua-wrap">
        <u-overlay :show="overlayShow" @click="overlayShow = false"></u-overlay>
        <view class="qiehuan-box"><u-tabs :list="tabList" @click="tabClick"></u-tabs></view>
        <view class="jihua-main">
            <view class="shaixuan-box">
@@ -11,14 +12,8 @@
            </view>
            <view class="main-inside">
                <view v-if="isTomJihua == '全部'">
                    <u-empty
                        v-if="fyData.length == 0"
                          mode="data"
                            icon="http://cdn.uviewui.com/uview/empty/data.png"
                            class="empty-container"
                      >
                    </u-empty>
                    <view class="main-block-box" v-for="(item, index) in fyData" :key="item.id">
                    <u-empty v-if="fyData.length == 0" mode="data" icon="http://cdn.uviewui.com/uview/empty/data.png" class="empty-container"></u-empty>
                    <view id="u-dropdown" class="main-block-box" v-for="(item, index) in fyData" :key="item.id" ref="planViewRef">
                        <view class="jihua-main-line">
                            <!-- <view class="name">客户名称:{{item.customerName || ''}}</view> -->
                            <view class="name">收货单位:{{ item.customerAddressName || '' }}</view>
@@ -33,22 +28,35 @@
                            <view class="main-flex">
                                <view class="carNum-box">
                                    <view>计划车数:</view>
                                    <u--input placeholder="请输入发运车数" border="surround" v-model="item.numPlan" @change="inputChange"></u--input>
                                    <!-- <u--input placeholder="请输入发运车数" border="surround" v-model="item.numPlan" @change="inputChange" @focus="faYunPlanCarsFocus(item)"></u--input> -->
                                    <view class="planCars" :style="{color:item.numPlan  ? '#111':'#ccc'}" @click="faYunPlanCarsFocus(item)">
                                        <text v-model="item.numPlan">{{ item.numPlan || '点击输入数量' }}</text>
                                        <view class="cursor" v-if="isCursor && fayunPlanFocusId == item.id"><image src="@/static/cursor.gif" mode=""><image></view>
                                    </view>
                                </view>
                                <view>实际发车数:{{ item.numReal || '' }}</view>
                                <view>实际发车数:{{ item.numReal || '暂无' }}</view>
                            </view>
                        </view>
                        <u-keyboard
                            @change="valChange"
                            @backspace="backspace"
                            @confirm="keyBoardConfirm"
                            @cancel="keyBoardCancel"
                            @close="keyBoardClose"
                            :show="keyBoardShow"
                            ref="uKeyboard"
                            mode="number"
                            :overlay="false"
                            :closeOnClickOverlay="false"
                            :dotDisabled="true"
                            zIndex="100000"
                        ></u-keyboard>
                    </view>
                    <u-button class="xiugai-btn" type="primary" text="提交" @click="dataFormSubmit"></u-button>
                    <u-button class="xiugai-btn" type="primary" text="提交" @click="submit"></u-button>
                </view>
                <view v-if="isTomJihua == '已设置的计划'">
                    <u-empty
                        v-if="fyData.length == 0"
                          mode="data"
                            icon="http://cdn.uviewui.com/uview/empty/data.png"
                            class="empty-container"
                      >
                    </u-empty>
                    <u-empty v-if="fyData.length == 0" mode="data" icon="http://cdn.uviewui.com/uview/empty/data.png" class="empty-container"></u-empty>
                    <view class="main-block-box" v-for="(item, index) in fyData" :key="item.id">
                        <view class="jihua-main-line">
                            <view class="name">客户名称:{{ item.customerName || '' }}</view>
@@ -56,27 +64,45 @@
                        <view class="jihua-main-line">
                            <view class="main-flex">
                                <view>煤种:{{ item.order.coalName || '' }}</view>
                                <view>剩余量:{{ item.order.executiveSurplus || '' }}</view>
                                <view>剩余量:{{ item.order.executiveSurplus || '' }}</view>
                            </view>
                        </view>
                        <view class="jihua-main-line">
                            <view class="main-flex">
                                <view class="carNum-box">
                                    <view>计划车数:</view>
                                    <u--input placeholder="请输入发运车数" border="surround" v-model="item.numPlan" @change="inputTotalChange(item)"></u--input>
                                    <!-- <u--input placeholder="请输入发运车数" border="surround" v-model="item.numPlan" @change="inputTotalChange(item)" @focus="faYunPlanCarsFocus(item)"></u--input> -->
                                    <view class="planCars" :style="{color:item.numPlan  ? '#111':'#ccc'}" @click="faYunPlanCarsFocus(item)">
                                        <text v-model="item.numPlan">{{ item.numPlan || '点击输入数量' }}</text>
                                        <view class="cursor" v-if="isCursor && fayunPlanFocusId == item.id">
                                            <image src="@/static/cursor.gif" mode="" />
                                        </view>
                                    </view>
                                </view>
                                <view>实际发车数:{{ item.order.numReal == null ? '暂无' : item.order.numReal }}</view>
                            </view>
                        </view>
                        <u-keyboard
                            @change="valChange"
                            @backspace="backspace"
                            @confirm="keyBoardConfirm"
                            @cancel="keyBoardCancel"
                            @close="keyBoardClose"
                            :show="keyBoardShow"
                            ref="uKeyboard"
                            mode="number"
                            :overlay="false"
                            :closeOnClickOverlay="false"
                            :dotDisabled="true"
                            zIndex="100000"
                        ></u-keyboard>
                    </view>
                    <u-button class="xiugai-btn" type="primary" text="修改" @click="getOrderCarNum"></u-button>
                    <u-button class="xiugai-btn" type="primary" text="修改" @click="editPlan"></u-button>
                </view>
            </view>
        </view>
        <view class="back-top-container">
            <u-back-top :scroll-top="scrollTop" icon="arrow-up" mode='square'></u-back-top>
        </view>
        <view class="back-top-container"><u-back-top :scroll-top="scrollTop" icon="arrow-up" mode="square"></u-back-top></view>
        <!-- 菜单栏 -->
        <popup-menu @menuShow="menushow" ref="menuRef"></popup-menu>
    </view>
@@ -84,6 +110,7 @@
<script>
import popupMenu from '@/components/common/popup-menu/popup-menu.vue';
import tool from '@/utils/tool.js';
export default {
    components: {
        popupMenu
@@ -92,7 +119,7 @@
        return {
            radioValue: '全部',
            tabList: [
                {
                {
                    name: '今日发运计划'
                },
                {
@@ -108,7 +135,13 @@
            isTomJihua: '全部',
            editRow: '', //修改行的行
            menuShow: false,
            scrollTop: 0 // 返回顶部按钮绑定
            scrollTop: 0, // 返回顶部按钮绑定,
            // 键盘
            keyBoardShow: false,
            keyBoardValue: '',
            fayunPlanFocusId: null,
            isCursor: false ,// 日计划车辆输入框焦点动画
            overlayShow:false // 遮罩层
        };
    },
    onShow() {
@@ -118,12 +151,57 @@
        this.init();
    },
    onPageScroll(e) {
        // 传入scrollTop值并触发所有easy-loadimage组件下的滚动监听事件
        this.scrollTop = e.scrollTop;
    },
    },
    // 点击导航栏菜单后
    onNavigationBarButtonTap(e) {
        // console.log(e);
        this.$refs.menuRef.menuClick();
    },
    mounted() {
        // setInterval(() => {
        //     uni.hideKeyboard();
        // }, 1);
    },
    watch: {
        isTomJihua: {
            handler: function(newV, oldV) {
                if (newV != oldV) {
                    this.keyBoardShow = false;
                }
            },
            deep: true,
            immediate: true
        },
        keyBoardValue: {
            handler: function(newV, oldV) {
                console.log('键盘输入值', newV, oldV);
                this.fyData.map(item => {
                    if (item.id == this.fayunPlanFocusId) {
                        if (item.numPlan && item.numPlan != newV) {
                            item.numPlan = this.keyBoardValue;
                            if (this.isTomJihua == '已设置的计划') {
                                this.editRow = item;
                            }
                        }
                    }
                });
            },
            deep: true,
            immediate: true
        },
        scrollTop: {
            handler: function(newV, oldV) {
                // console.log('页面滑动', newV);
                if (newV != oldV) {
                    this.keyBoardClose();
                    // this.keyBoardShow = false;
                }
            }
        },
        deep: true,
        immediate: true
    },
    methods: {
        init() {
@@ -132,22 +210,30 @@
        menushow(e) {
            this.menuShow = e;
        },
        //提交
        dataFormSubmit() {
            //提交订单
            this.fyData.forEach(e => {
                e.shippingDate = this.info.shippingDate;
                if (e.planId && !e.numPlan) {
                    e.numPlan = -1; //删除设置为空的计划
                }
                let orderId = e.id;
                e.id = e.planId;
                e.orderId = orderId;
            });
            this.$reqPost('addObj', this.fyData).then(res => {
                this.$u.toast('添加成功');
                this.fyList();
            });
            console.log('日发运计划更新数据提交',this.fyData);
                this.overlayShow = true;
                this.fyData.forEach(e => {
                    e.shippingDate = this.info.shippingDate;
                    if (e.planId && !e.numPlan) {
                        e.numPlan = -1; // 删除设置为空的计划
                    }
                    let orderId = e.id;  // 订单id
                    e.orderId = orderId;
                    // e.id = e.planId;
                });
                this.$reqPost('addObj', this.fyData).then(res => {
                    console.log('addObj接口返回',res);
                    this.$u.toast('添加成功');
                    this.fyList();
                });
        },
        // 全部日计划提交按钮防抖
        submit:tool.throttle(function(){
                this.dataFormSubmit();
        }),
        // 修改日计划按钮
        getOrderCarNum() {
            //修改
            this.$reqPost('setCarNums', this.editRow).then(res => {
@@ -155,6 +241,11 @@
                this.xscarshippingdayplan();
            });
        },
        // 修改日计划防抖按钮
        editPlan:tool.throttle(function(){
            this.getOrderCarNum();
        }),
        // 切换全部和已设置
        groupChange(n) {
            console.log(n, 'n================');
            this.isTomJihua = n;
@@ -163,6 +254,140 @@
            } else {
                this.fyList();
            }
        },
        fyList() {
            this.overlayShow = true;
            //列表查询
            uni.showLoading({
                title: '正在加载...'
            });
            let compId = uni.getStorageSync('userInfo').compId;
            let params = {
                current: 1,
                size: 100,
                status: 2,
                trainType: 1,
                compId: compId
            };
            this.$reqGet('fyList', params).then(res => {
                if (res.code == 0) {
                    console.log('fylist--------',res.data);
                    this.xscarshippingdayplan(res.data);
                }
            });
        },
        xscarshippingdayplan(allList) {
            uni.showLoading({
                title: '正在加载...'
            });
            this.overlayShow = true;
            //已经设置的
            let params = {
                current: 1,
                size: 50,
                shippingDate: this.info.shippingDate
            };
            this.$reqGet('xscarshippingdayplan', params)
                .then(res => {
                    console.log('不知道是什么---------------',res);
                    if (res.code == 0) {
                        if (allList) {
                            let selectFyData = res.data.records;
                            allList.forEach(e => {
                                selectFyData.forEach(ee => {
                                    if (e.id == ee.orderId) {
                                        e.numPlan = ee.numPlan;
                                        e.numReal = ee.numReal;
                                        // e.planId = ee.id;
                                        console.log('修改planid操作',`planId:${ee.id}`);
                                        if (ee.carNums != null) {
                                            e.carNums = ee.carNums;
                                        }
                                    }
                                });
                            });
                            this.fyData = allList;
                        } else {
                            this.fyData = res.data.records;
                        }
                        uni.hideLoading();
                        this.overlayShow = false;
                    }
                })
                .catch(e => {
                    uni.hideLoading();
                    this.overlayShow = false;
                });
        },
        //切换今日和明日
        tabClick(item) {
            console.log(item, 'item==========');
            if (item.index == 1) {
                this.info.shippingDate = this.tomorrowDate();
                if (this.isTomJihua == '已设置的计划') {
                    this.xscarshippingdayplan();
                } else {
                    this.fyList();
                }
            } else {
                this.info.shippingDate = this.todayDate();
                if (this.isTomJihua == '已设置的计划') {
                    this.xscarshippingdayplan();
                } else {
                    this.fyList();
                }
            }
        },
        inputChange(val) {
            console.log('全部计划', val);
        },
        inputTotalChange(val) {
            console.log(val, 'val2=======val2,已设置计划');
            this.editRow = val;
        },
        // input获取焦点
        faYunPlanCarsFocus(item) {
            // 获取该焦点在页面的位置
            // let boxBottom = document.getElementById('#u-dropdown');
            // console.log('元素',boxBottom);
            // let bottom = this.$refs.planViewRef.offsetHeight
            this.fayunPlanFocusId = item.id;
            this.keyBoardShow = true;
            this.isCursor = true;
            this.keyBoardValue = item.numPlan + '';
        },
        // 键盘
        valChange(val) {
            // this.keyBoardValue += val;
            // 将每次按键的值拼接到value变量中,注意+=写法
            this.fyData.map(item => {
                if (item.id == this.fayunPlanFocusId) {
                    if (item.numPlan) {
                        item.numPlan = this.keyBoardValue += val + '';
                        this.keyBoardValue = item.numPlan;
                    } else {
                        item.numPlan = val;
                        this.keyBoardValue = item.numPlan;
                    }
                }
            });
        },
        backspace() {
            this.keyBoardValue = this.keyBoardValue.substr(0, this.keyBoardValue.length - 1);
        },
        keyBoardConfirm(val) {
            console.log('键盘点击确定的值', val);
            this.keyBoardClose();
        },
        keyBoardCancel() {
            this.keyBoardClose();
        },
        keyBoardClose() {
            console.log('键盘关闭了');
            this.fayunPlanFocusId = null;
            this.keyBoardShow = false;
            this.isCursor = false;
        },
        todayDate() {
            let yes = new Date().getTime();
@@ -187,92 +412,6 @@
            const time = y + '-' + m + '-' + d;
            console.log('tomorrowDate---------222', time);
            return time;
        },
        fyList() {
            //列表查询
            uni.showLoading({
                title: '正在加载...'
            });
            let compId = uni.getStorageSync('userInfo').compId;
            let params = {
                current: 1,
                size: 100,
                status: 2,
                trainType: 1,
                compId: compId
            };
            this.$reqGet('fyList', params).then(res => {
                if (res.code == 0) {
                    this.xscarshippingdayplan(res.data);
                }
            });
        },
        xscarshippingdayplan(allList) {
            //已经设置的
            console.log(allList, 'allList==========');
            let params = {
                current: 1,
                size: 50,
                shippingDate: this.info.shippingDate
            };
            this.$reqGet('xscarshippingdayplan', params)
                .then(res => {
                    if (res.code == 0) {
                        if (!allList) {
                            this.fyData = res.data.records;
                            console.log(this.fyData, 'this.fyData=========11111111');
                        } else {
                            let l = res.data.records;
                            allList.forEach(e => {
                                l.forEach(ee => {
                                    if (e.id == ee.orderId) {
                                        e.numPlan = ee.numPlan;
                                        e.numReal = ee.numReal;
                                        e.planId = ee.id;
                                        if (ee.carNums != null) {
                                            e.carNums = ee.carNums;
                                        }
                                    }
                                });
                            });
                            this.fyData = allList;
                            console.log(this.fyData, 'this.fyData=========22222222');
                        }
                        console.log(this.fyData, 'this.fyData=========333333333');
                        uni.hideLoading();
                    }
                })
                .catch(e => {
                    uni.hideLoading();
                });
        },
        tabClick(item) {
            //切换今日和明日
            console.log(item, 'item==========');
            if (item.index == 1) {
                this.info.shippingDate = this.tomorrowDate();
                if (this.isTomJihua == '已设置的计划') {
                    this.xscarshippingdayplan();
                } else {
                    this.fyList();
                }
            } else {
                this.info.shippingDate = this.todayDate();
                if (this.isTomJihua == '已设置的计划') {
                    this.xscarshippingdayplan();
                } else {
                    this.fyList();
                }
            }
        },
        inputChange(val) {
            console.log(val);
        },
        inputTotalChange(val) {
            console.log(val, 'val2=======val2');
            this.editRow = val;
        }
    }
};
@@ -324,9 +463,9 @@
        font-size: vww(12) !important;
        line-height: vww(12) !important;
    }
    .u-empty{
        width:100%;
        height:vww(300);
    .u-empty {
        width: 100%;
        height: vww(300);
    }
}
@@ -412,6 +551,30 @@
                }
                .carNum-box {
                    display: flex;
                    .planCars {
                        display: flex;
                        box-sizing: border-box;
                        overflow: auto;
                        width: vww(120);
                        border: 1px solid #dddddd;
                        border-radius: vww(4);
                        padding: vww(1) vww(10);
                        // 输入焦点图片
                        .cursor {
                            // float: left;
                            width: vww(1);
                            height: vww(15);
                            vertical-align: middle;
                            align-self: center;
                            image {
                                width: vww(1);
                                display: block;
                                height: vww(15);
                            }
                        }
                    }
                    view {
                        font-size: vww(14);
                        line-height: vww(32);
@@ -421,4 +584,4 @@
        }
    }
}
</style>
</style>
pages/login/login.vue
@@ -1,11 +1,10 @@
<template>
<!-- <template>
    <view class="login">
        <image src="@/static/login/banner.png" class="background"></image>
        <view class="login-container">
            <view class="loginBtn"><u-button text="微信账号快捷登录" type="success" shape="circle" icon="weixin-fill" @click="toGrantAuthorization"></u-button></view>
            <view class="utils"><text @click="toBindPage">绑定系统账号</text></view>
        </view>
        <!-- 特定范围说明 -->
        <view class="loginBottom"><text>小程序仅供已拥有系统账号特定内部人员使用</text></view>
        <u-modal
            @confirm="wxLoginConfirm"
@@ -201,3 +200,155 @@
    }
}
</style>
 -->
 <template>
     <view class="login">
        <u-overlay :show="show" @click="show = false"></u-overlay>
         <image src="@/static/login/banner.png" class="background"></image>
         <view class="inputBox">
             <view class="phone">
                 <image src="@/static/login/phone.png" mode="加载错误"></image>
                 <input type="text" placeholder="请输入用户名/手机号" v-model="formData.username" />
             </view>
             <view class="password">
                 <image src="@/static/login/lock.png" mode="加载错误" />
                 <input type="password" placeholder="请输入账号密码" v-model="formData.password" />
             </view>
             <view class="loginBtn"><button type="default" @click="loginSubmit">登录</button></view>
         </view>
     </view>
 </template>
 <script>
 import { setAccessToken, setTokenType, setRefreshToken, setClientId, setScope, redirectHome, redirectLogin } from '@/utils/status.js';
 export default {
     name: 'login',
     data() {
         return {
            show:false,
             formData: {
                 // username: 'zhangjialiang',
                 // password: '123456aaa',
                // username: 'gequan',
                // password: 'gequan!@#$',
                username: '',
                password: ''
             },
             bindData: {
                 state: 'MINI',
                 code: ''
             }
         };
     },
    onShow() {
        // 清除缓存
        if (uni.getStorageSync('userInfo') || uni.getStorageSync('access_token') || uni.getStorageSync('refresh_token')) {
            uni.clearStorageSync();
        }
    },
     methods: {
         loginSubmit() {
            if(this.formData.username == ''){
                uni.showToast({
                    title:'请输入用户名!',
                    icon:'none'
                })
            } else if(this.formData.password == ''){
                uni.showToast({
                    title:'请输入密码!',
                    icon:'none'
                })
            } else {
                this.show = true;
                uni.showLoading({
                    title: '登录中...'
                });
                this.apiLogin(this.formData)
                    .then(this.saveUserInfo)
                    .catch(this.loginFail);
            }
         },
         saveUserInfo(response) {
             uni.hideLoading();
            this.show = false;
             if (response.statusCode === 200) {
                 const { access_token, refresh_token, token_type, scope } = response.data;
                 try {
                     setAccessToken(access_token);
                     setTokenType(token_type);
                     setRefreshToken(refresh_token);
                     setScope(scope);
                     this.$store.dispatch('menus');
                     uni.hideLoading();
                     redirectHome();
                 } catch (e) {
                     console.log('检测到错误',e);
                 }
             } else {
                 uni.showToast({
                     title: response.data.msg,
                     icon:'none',
                     duration: 2000
                 });
             }
         },
         loginFail(err) {
            this.show = false;
             console.log('登录接口错误', err);
         }
     }
 };
 </script>
 <style lang="scss" scoped>
 .login {
     .background {
         width: 100%;
         height: vww(289);
         // height: vww(246);
     }
     .inputBox {
         width: vww(280);
         margin: vww(40) auto;
         input {
             width: vww(240);
             margin-left: vww(8);
         }
         .phone {
             width: vww(280);
             height: vww(36);
             display: flex;
             align-items: center;
             border-bottom: vww(1) solid #cccccc;
             image {
                 width: vww(20);
                 height: vww(20);
             }
         }
         .password {
             width: vww(280);
             height: vww(36);
             display: flex;
             align-items: center;
             margin-top: vww(40);
             border-bottom: vww(1) solid #cccccc;
             image {
                 width: vww(20);
                 height: vww(20);
             }
         }
         .loginBtn {
             margin-top: vww(80);
             button {
                 background-color: #007aff;
                 color: #ffffff;
                 font-size: vww(16);
                 border-radius: vww(22);
             }
         }
     }
 }
 </style>
pages/my-application/my-application.vue
@@ -61,7 +61,7 @@
              <text>所属流程:{{ item.processName }}</text>
            </view>
            <view class="">
              <text>审批环节:{{ item.currTaskName == null ? '' : item.currTaskName }}</text>
              <text>审批环节:{{ item.currTaskName ||'' }}</text>
            </view>
          </view>
          <view class="center-content__two center-margin">
@@ -86,7 +86,7 @@
        <view class="bottom-container">
          <!-- 按钮区域 -->
          <view class="bottom-content__chulizhong bottom-content__item">
            <view @click="withDrawClick(item.id)" v-if="item.status == 1">
            <view @click="withDrawClick(item.procInstId)" v-if="item.status == 1">
              <image src="@/static/home/cehui.png" mode=""></image>
              <view>撤回</view>
            </view>
@@ -94,15 +94,15 @@
              <image src="@/static/home/jindu.png" mode=""></image>
              <view>查看进度</view>
            </view>
            <view @click="theFormDataClick(item.tableId)" v-if="(item.status == 1 || item.status == 2 )&& (item.procDefId == 'WAY_BILL:4:87504')">
            <view @click="theFormDataClick(item.tableId)" v-if="(item.status == 1 || item.status == 2 || item.status == 3 ) && (item.processName == '发运通知单')">
              <image src="@/static/home/biaodan.png" mode=""></image>
              <view>申请详情</view>
            </view>
            <view v-if="item.status == 3" @click="apply(item)">
            <!-- <view v-if="item.status == 3" @click="apply(item)">
              <image src="@/static/home/history.png" mode=""></image>
              <view>重新申请</view>
            </view>
            <view v-if="item.status == 3" @click="editMyApplication(item)">
            </view> -->
            <view @click="editMyApplication(item)" v-if="item.status == 1 && item.processName == '发运通知单'">
              <image src="@/static/home/history.png" mode=""></image>
              <view>编辑</view>
            </view>
@@ -110,6 +110,10 @@
              <image src="@/static/home/history.png" mode=""></image>
              <view>审批历史</view>
            </view>
                        <view @click="deleteWithDrawApplication(item.tableId)" v-if="item.status == 3">
                            <image src="@/static/home/delete.png" mode=""></image>
                            <view>删除</view>
                        </view>
          </view>
        </view>
      </template>
@@ -118,10 +122,11 @@
    <!-- 撤回模态框 -->
    <view class="wodeshenqingMotai">
      <u-modal width="684rpx" :show="withDrawShow" title="撤回原因" :showCancelButton="true" @confirm="withDrawConfirm"
      <u-modal width="684rpx" :show="withDrawShow" title="提示" :showCancelButton="true" @confirm="withDrawConfirm"
               @cancel="withDrawCancel">
        <view class="slot-content">
          <u--textarea v-model="withDrawData.reason" placeholder="请输入撤回原因"></u--textarea>
          <!-- <u--textarea v-model="withDrawData.reason" placeholder="请输入撤回原因"></u--textarea> -->
                    <text>确认撤回该申请吗?</text>
        </view>
      </u-modal>
    </view>
@@ -143,7 +148,7 @@
      <u-back-top :scroll-top="scrollTop" style="position:fixed;bottom:100px;right:100px;"></u-back-top>
    </view>
    <view class="" style="height:50px;">
    <view class="empty-placeH">
    </view>
@@ -193,8 +198,8 @@
      // 撤回模态框
      withDrawShow: false,
      withDrawData: {
        reason: '',
        id: '', // 撤回申请ID
        // reason: '',
        // id: '', // 撤回申请ID
        procInstId: ''
      },
      // 重新申请
@@ -403,17 +408,12 @@
      this.init();
    },
    // 撤回模态框
    withDrawClick(id) {
    withDrawClick(procInstId) {
      this.withDrawShow = true;
      this.withDrawData.id = id;
      this.withDrawData.procInstId = procInstId;
    },
    withDrawConfirm() {
      this.shenqingData.forEach(i => {
        if (i.id == this.withDrawData.id) {
          this.withDrawData.procInstId = i.procInstId;
        }
      });
      this.$reqPost('withDraw', this.withDrawData, 'form').then(res => {
      this.$reqPost('cancel', this.withDrawData).then(res => {
        console.log('res', res);
        if (res.code == 0) {
          uni.showToast({
@@ -428,95 +428,86 @@
        this.getMoreNews();
      });
      console.log(this.withDrawId);
      if (this.withDrawData.reason.length >= 2) {
        console.log(this.withDrawData.reason);
      } else {
        uni.showToast({
          title: '请规范输入',
          duration: 2000
        });
      }
    },
    withDrawCancel() {
      this.withDrawShow = false;
    },
    apply(v) {
      if (!v.procDefId || v.procDefId == 'null') {
        this.$u.toast('流程定义为空');
        return;
      }
      this.form.id = v.id;
      this.form.procDefId = v.procDefId;
      this.form.title = v.title;
      // 加载审批人
      // this.userLoading = true;
      uni.showLoading({
        title: '审批人加载中'
      });
      // getFirstNode(v.procDefId).then((res) => {
      this.$reqGet('getFirstNode', {}, v.procDefId).then(res => {
        // this.userLoading = false;
        console.log('审批人', res);
        uni.hideLoading();
        if (res.data) {
          this.error = '';
          if (res.data.type == 3 || res.data.type == 4) {
            this.isGateway = true;
            this.form.firstGateway = true;
            this.showAssign = false;
            this.isCustom = false;
            return;
          }
          if (res.data.type == 5) {
            this.isCustom = true;
            this.isGateway = false;
            this.form.firstGateway = false;
            this.showAssign = false;
            return;
          }
          if (res.data.type == 1) {
            this.showAssign = true;
            this.isGateway = false;
            this.form.firstGateway = false;
            this.isCustom = false;
            if (res.data.users && res.data.users.length > 0) {
              this.assigneeList = res.data.users;
              // 默认勾选
              let ids = [];
              res.data.users.forEach(e => {
                ids.push(e.userId);
              });
              this.form.assignees = ids;
              this.showAssign = true;
              // 获取表单内容,重新创建申请
              this.$reqPost('apply', this.form, 'form').then(res => {
                console.log('重新提交申请', res);
                if (res.code == 0) {
                  uni.showToast({
                    title: res.data,
                    icon: 'success',
                    duration: 2000
                  });
                }
                // 初始化申请列表
                this.myApplication.pageNumber = 1;
                this.shenqingData = [];
                this.getMoreNews();
              })
            } else {
              this.form.assignees = [];
              this.showAssign = true;
              this.error = '请进入"流程管理"为审批节点分配候选审批人员';
            }
          }
        }
        console.log(this.form);
      });
    // apply(v) {
    //   if (!v.procDefId || v.procDefId == 'null') {
    //     this.$u.toast('流程定义为空');
    //     return;
    //   }
    //   this.form.id = v.id;
    //   this.form.procDefId = v.procDefId;
    //   this.form.title = v.title;
    //   // 加载审批人
    //   // this.userLoading = true;
    //   uni.showLoading({
    //     title: '审批人加载中'
    //   });
    //   // getFirstNode(v.procDefId).then((res) => {
    //   this.$reqGet('getFirstNode', {}, v.procDefId).then(res => {
    //     // this.userLoading = false;
    //     console.log('审批人', res);
    //     uni.hideLoading();
    //     if (res.data) {
    //       this.error = '';
    //       if (res.data.type == 3 || res.data.type == 4) {
    //         this.isGateway = true;
    //         this.form.firstGateway = true;
    //         this.showAssign = false;
    //         this.isCustom = false;
    //         return;
    //       }
    //       if (res.data.type == 5) {
    //         this.isCustom = true;
    //         this.isGateway = false;
    //         this.form.firstGateway = false;
    //         this.showAssign = false;
    //         return;
    //       }
    //       if (res.data.type == 1) {
    //         this.showAssign = true;
    //         this.isGateway = false;
    //         this.form.firstGateway = false;
    //         this.isCustom = false;
    //         if (res.data.users && res.data.users.length > 0) {
    //           this.assigneeList = res.data.users;
    //           // 默认勾选
    //           let ids = [];
    //           res.data.users.forEach(e => {
    //             ids.push(e.userId);
    //           });
    //           this.form.assignees = ids;
    //           this.showAssign = true;
    //           // 获取表单内容,重新创建申请
    //           this.$reqPost('apply', this.form, 'form').then(res => {
    //             console.log('重新提交申请', res);
    //             if (res.code == 0) {
    //               uni.showToast({
    //                 title: res.data,
    //                 icon: 'success',
    //                 duration: 2000
    //               });
    //             }
    //             // 初始化申请列表
    //             this.myApplication.pageNumber = 1;
    //             this.shenqingData = [];
    //             this.getMoreNews();
    //           })
    //         } else {
    //           this.form.assignees = [];
    //           this.showAssign = true;
    //           this.error = '请进入"流程管理"为审批节点分配候选审批人员';
    //         }
    //       }
    //     }
    //     console.log(this.form);
    //   });
      this.modalVisible = true;
      // }
    },
    //   this.modalVisible = true;
    //   // }
    // },
    // 修改申请
    editMyApplication(v) {
      console.log('修改申请');
@@ -796,6 +787,11 @@
      right:vww(20)!important;
    }
  }
    // 底部占位
    .empty-placeH{
        height:vww(50);
    }
  // 底部
pages/my-have-todo/my-have-todo.vue
@@ -51,7 +51,7 @@
                            </view>
                            <view class="center-content__two center-margin">
                                <view>
                                    <text>发起人:{{ item.actBusiness.createByName }}</text>
                                    <text>发起人:{{ item.actBusiness.createByName || '' }}</text>
                                </view>
                                <view>
                                    <text>审批操作:{{ item.deleteReason }}</text>
@@ -59,7 +59,7 @@
                            </view>
                            <view class="center-content__three center-margin">
                                <view class="">
                                    <text>审批意见:{{ item.comment == 'undefined' ? '' : item.comment || '' }}</text>
                                    <text>审批意见:{{ item.comment == 'undefined' ? '未填写' : item.comment || '未填写' }}</text>
                                </view>
                                <view class="">
                                    <text>
@@ -82,7 +82,7 @@
                        <view class="bottom-container">
                            <!-- 已办按钮 -->
                            <view class="bottom-content__item">
                                <view @click="theFormDataClick(item.tableId)" v-if="item.procDefId == 'WAY_BILL:4:87504'">
                                <view @click="theFormDataClick(item.tableId)" v-if="item.processName == '发运通知单'">
                                    <image src="@/static/home/biaodan.png" mode=""></image>
                                    <view>申请详情</view>
                                </view>
@@ -99,6 +99,10 @@
                    </template>
                </combination-card>
            </u-checkbox-group>
        </view>
        <view class="empty-placeH">
        </view>
        <!-- 底部全选 -->
        <view class="bottomTabbar">
@@ -387,6 +391,8 @@
<style lang="scss" scoped>
::v-deep.my-have-todo {
    width: 100%;
    height: 100%;
    // 搜索区域
    .searchContainer {
        width: 94%;
@@ -600,6 +606,11 @@
            right: vww(20) !important;
        }
    }
    // 底部站位
    .empty-placeH{
        height:vww(5);
    }
    // 底部
    .bottomTabbar {
pages/my-todo/my-todo.vue
@@ -81,7 +81,7 @@
          <view class="bottom-container">
            <!-- 待办按钮 -->
            <view class="bottom-content__item">
              <view @click="theFormDataClick(item.tableId)" v-if="item.procDefId == 'WAY_BILL:4:87504'">
              <view @click="theFormDataClick(item.tableId)" v-if="item.processName == '发运通知单'">
                <image src="@/static/home/jindu.png" mode=""></image>
                <view>申请详情</view>
              </view>
@@ -89,7 +89,7 @@
                <image src="@/static/home/tongguo.png" mode=""></image>
                <view>通过</view>
              </view>
              <view @click="rejectModalShow = true">
              <view @click="rejectClick(item)">
                <image src="@/static/home/bohui.png" mode=""></image>
                <view>驳回</view>
              </view>
@@ -192,6 +192,7 @@
<script>
import popupMenu from '@/components/common/popup-menu/popup-menu.vue';
import combinationCard from '@/components/common/combination-card/combination-card.vue';
import { callWithErrorHandling } from "vue";
export default {
  data() {
@@ -422,6 +423,7 @@
    },
    // 通过
    adopClick(v) {
            console.log('通过',v);
      this.adoptModalShow = true;
      this.adoptForm.ids = v.id;
      this.modalType = 0;
@@ -436,47 +438,61 @@
    // 通过模态框
    adoptModalConfirm() {
      this.adoptModalShow = false;
      this.checkBoxValue.forEach(item => {
        this.adoptDataBox.push(item.slice(0, 6))
      })
      this.adoptForm.ids = this.adoptDataBox.toString();
      this.$reqPost('passAll', this.adoptForm, 'form').then(res => {
            if(this.checkBoxValue.length >= 1){
                this.checkBoxValue.forEach(item => {
                  this.adoptDataBox.push(item.slice(0, 6))
                })
                this.adoptForm.ids = this.adoptDataBox.toString();
            }
      this.$reqPost('passAll', this.adoptForm).then(res => {
        console.log('是否还原', this.adoptForm.ids, this.rejectForm.procInstIds);
        if (res.code == 0) {
          this.$u.toast('操作成功!');
        } else {
          this.$u.toast('添加失败!!');
        }
                // 初始化
                this.checkBoxValue = []
                this.adoptForm.ids = '';
                this.adoptForm.comment = '';
        this.init();
      });
    },
    adoptModalCancel() {
      this.adoptModalShow = false;
    },
        // 驳回点击
        rejectClick(v) {
          this.modalType = 1;
          this.rejectModalShow = true;
          this.rejectForm.procInstIds = v.procInstId;
        },
    // 驳回模态框
    rejectModalConfirm() {
      this.rejectModalShow = false;
      this.checkBoxValue.forEach(item => {
        this.rejectDataBox.push(item.slice(6, 12))
      })
      this.rejectForm.procInstIds = this.rejectDataBox.toString();
      this.$reqPost('backAll', this.rejectForm, 'form').then(res => {
            if(this.checkBoxValue.length >= 1){
                this.checkBoxValue.forEach(item => {
                  this.rejectDataBox.push(item.slice(6, 12))
                })
                this.rejectForm.procInstIds = this.rejectDataBox.toString();
            }
      this.$reqPost('backAll', this.rejectForm).then(res => {
        if (res.code == 0) {
          this.$u.toast('操作成功!');
        } else {
          this.$u.toast('操作失败!!!');
        }
                // 初始化
                this.rejectForm.procInstIds = '';
                this.rejectForm.comment = '';
                this.checkBoxValue = []
        this.init();
      });
    },
    rejectModalCancel() {
      this.rejectModalShow = false;
    },
    rejectClick(v) {
      this.modalType = 1;
      this.rejectModalShow = true;
      this.rejectForm.procInstIds = v.procInstId;
    },
    batchRejectClick() {
      if (this.checkBoxValue.length != 0) {
        this.rejectModalShow = true;
pages/new-application-form-data/new-application-form-data.vue
Diff too large
pages/new-application/new-application.vue
@@ -23,7 +23,7 @@
                    </view>
                    <view class="card-left_bottom">
                        <text>版本:v{{ item.version }}</text>
                        <text>所属分类:{{ item.categoryTitle }}</text>
                        <text>所属分类:{{ item.categoryTitle|| '' }}</text>
                    </view>
                </view>
                <view class="card-right">
@@ -93,7 +93,7 @@
                uni.hideLoading();
                if (res.code === 0) {
                    res.data.records.forEach(item => {
                        if (item.id == 'WAY_BILL:4:87504') {
                        if (item.name == '发运通知单'||item.description == '发运通知单') {
                            this.newApplicationData.push(item);
                        }
                    });
pages/register/register.vue
@@ -51,9 +51,9 @@
                    setTokenType(token_type);
                    setRefreshToken(refresh_token);
                    setScope(scope);
                    // this.$store.dispatch('menus');
                    // redirectHome();
                    this.$store.dispatch('menus');
                    uni.hideLoading();
                    // redirectHome();
                    this.bindWx(); // 登录成功后获取code码,返给后端
                } catch (e) {
                    // error
static/cursor.gif
utils/api.js
@@ -1,83 +1,93 @@
export const api = {
    // 微信绑定客户
    bindWx:{
        url:'/admin/social/bind',
        method:"POST"
    bindWx: {
        url: '/admin/social/bind',
        method: "POST"
    },
    // 获取单位树
    fetchCompTree:{
        url:'/admin/dept/compTree',
        method:'GET'
    fetchCompTree: {
        url: '/admin/dept/compTree',
        method: 'GET'
    },
    // 我的申请
    getProcessDataList:{
        url:'/oa/actBusiness/getByCondition',
        name:'pig',
        method:'GET'
    getProcessDataList: {
        url: '/oa/actBusiness/getByCondition',
        name: 'pig',
        method: 'GET'
    },
    // 新增申请
    getNewProcessDataList:{
        url:'/oa/actProcess/getByCondition',
        name:'pig',
        mehtod:'GET'
    getNewProcessDataList: {
        url: '/oa/actProcess/getByCondition',
        name: 'pig',
        mehtod: 'GET'
    },
    // 操作人员
    operator:{
        url:'/admin/dict/type/operator',
        name:'pig',
        method:'GET'
    operator: {
        url: '/admin/dict/type/operator',
        name: 'pig',
        method: 'GET'
    },
    // 付款类型
    pay_type:{
        url:'/admin/dict/type/pay_type',
        name:'pig',
        method:'GET'
    pay_type: {
        url: '/admin/dict/type/pay_type',
        name: 'pig',
        method: 'GET'
    },
    // 其他参数
    others_params:{
        url:'/admin/dict/type/others_params',
        name:'pig',
        method:'GET'
    others_params: {
        url: '/admin/dict/type/others_params',
        name: 'pig',
        method: 'GET'
    },
    // 页面参数
    coalprice:{
        url:'/yunxiao/coalprice/page',
        name:'pig',
        method:'GET'
    coalprice: {
        url: '/yunxiao/coalprice/page',
        name: 'pig',
        method: 'GET'
    },
    jcfavouredpolicyitem:{
        url:'/yunxiao/jcfavouredpolicyitem/page',
        name:'pig',
        method:'GET'
    jcfavouredpolicyitem: {
        url: '/yunxiao/jcfavouredpolicyitem/page',
        name: 'pig',
        method: 'GET'
    },
    // 获取全部优惠政策
    getFavouredPolicyItem:{
        url:'/yunxiao/jcfavouredpolicyitem/page',
        method:'GET'
    getFavouredPolicyItem: {
        url: '/yunxiao/jcfavouredpolicyitem/page',
        method: 'GET'
    },
    // 煤场
    coalfiled:{
        url:'/yunxiao/coalfiled/page',
        name:'pig',
        method:'GET'
    coalfiled: {
        url: '/yunxiao/coalfiled/page',
        name: 'pig',
        method: 'GET'
    },
    /**
     * @Ledger 分类账套
     */
    zhaccountledger: {
        url: '/yunxiao/zhaccountledger/page',
        method: 'GET'
    },
    // 选择客户
    /**
     * @选择客户
     */
    // 搜索
    customer:{
        url:'/yunxiao/customer/page',
        method:'GET'
    customer: {
        url: '/yunxiao/customer/page',
        method: 'GET'
    },
    // 获取账户
    getAccount:{
        url:'/yunxiao/account/getAccount',
        method:'GET'
    getAccount: {
        url: '/yunxiao/account/getAccount',
        method: 'GET'
    },
    // 选择客户回调
    // customerAccount:{
@@ -87,80 +97,85 @@
    // 选择合同
    contract:{
        url:'/yunxiao/contract/page',
        method:'GET'
    contract: {
        url: '/yunxiao/contract/page',
        method: 'GET'
    },
    // 合同类型&状态
    contract_status:{
        url:'/admin/dict/type/contract_status',
        method:'GET'
    contract_status: {
        url: '/admin/dict/type/contract_status',
        method: 'GET'
    },
    contract_type:{
        url:'/admin/dict/type/contract_type',
        method:'GET'
    contract_type: {
        url: '/admin/dict/type/contract_type',
        method: 'GET'
    },
    trainFreightFind:{
        url:"/yunxiao/trainFreight/find",
        mehtod:"GET"
    trainFreightFind: {
        url: "/yunxiao/trainFreight/find",
        mehtod: "GET"
    },
    // 合同详情
    getByContractId:{
        url:'/yunxiao/contractitem/getByContractId',
        method:'GET'
    getByContractId: {
        url: '/yunxiao/contractitem/getByContractId',
        method: 'GET'
    },
    // 添加申请
    xswaybill:{
        url:'/yunxiao/xswaybill',
        method:'POST'
    xswaybill: {
        url: '/yunxiao/xswaybill',
        method: 'POST'
    },
    // 煤种价格修改信息
    getNewPrice:{
        url:'/yunxiao/coalpricemodifyinfo/getNewPrice',
        method:'GET'
    getNewPrice: {
        url: '/yunxiao/coalpricemodifyinfo/getNewPrice',
        method: 'GET'
    },
    // 撤回
    withDraw:{
        url:'/oa/actBusiness/cancel',
    // withDraw: {
    //     url: '/oa/actBusiness/cancel',
    //     method: 'POST'
    // },
    // 修改过的撤回
    cancel:{
        url:'/oa/actRemote/cancel',
        method:'POST'
    },
    // 获取操作人
    getFirstNode:{
        url:'/oa/actProcess/getFirstNode',
        method:'GET'
    getFirstNode: {
        url: '/oa/actProcess/getFirstNode',
        method: 'GET'
    },
    // 重新申请
    apply:{
        url:'/oa/actBusiness/apply',
        method:'POST'
    apply: {
        url: '/oa/actBusiness/apply',
        method: 'POST'
    },
    // 我的待办
    todoList:{
        url:'/oa/actTask/todoList',
        name:'pig',
        method:'GET'
    todoList: {
        url: '/oa/actTask/todoList',
        name: 'pig',
        method: 'GET'
    },
    // 我的已办
    doneList:{
        url:'/oa/actTask/doneList',
        name:'pig',
        method:'GET'
    doneList: {
        url: '/oa/actTask/doneList',
        name: 'pig',
        method: 'GET'
    },
    // 表单数据
    formData:{
        url:'/yunxiao/xswaybill',
        method:'GET'
    formData: {
        url: '/yunxiao/xswaybill',
        method: 'GET'
    },
    // 查看进度
    historicFlow:{
        url:'/oa/actTask/historicFlow',
        method:'GET'
    historicFlow: {
        url: '/oa/actTask/historicFlow',
        method: 'GET'
    },
    // 待办通过
    // getNextNode:{
@@ -168,23 +183,23 @@
    //     method:'GET'
    // },
    // 批量通过
    passAll:{
        url:'/oa/actTask/passAll',
        method:'POST'
    passAll: {
        url: '/oa/actTask/passAll',
        method: 'POST'
    },
    // 批量驳回
    backAll:{
        url:'/oa/actTask/backAll',
        method:"POST"
    backAll: {
        url: '/oa/actTask/backAll',
        method: "POST"
    },
    deleteHistoric:{
        url:'/oa/actTask/deleteHistoric',
        method:"POST"
    deleteHistoric: {
        url: '/oa/actTask/deleteHistoric',
        method: "POST"
    },
    // 修改驳回申请信息
    editXswaybill:{
        url:'/yunxiao/xswaybill',
        method:'PUT'
    editXswaybill: {
        url: '/yunxiao/xswaybill',
        method: 'PUT'
    },
    // 退出清空缓存
    // logout:{
@@ -193,9 +208,9 @@
    // }
    // 煤仓当前剩余量
    coalbunker:{
        url:'/yunxiao/coalbunker/page',
        method:'GET'
    coalbunker: {
        url: '/yunxiao/coalbunker/page',
        method: 'GET'
    }
}
utils/jihua.js
@@ -13,6 +13,12 @@
        url: '/yunxiao/xscarshippingdayplan/page',
        method: 'GET'
    },
    // xscarshippingdayplan: {
    //     url: '/yunxiao/contractorder/page',
    //     method: 'GET'
    // },
    // /yunxiao/xscarshippingdayplan
    addObj: {
        url: '/yunxiao/xscarshippingdayplan',
utils/request.js
@@ -23,11 +23,11 @@
        duration: 2000
    });
    setTimeout(() => {
            uni.clearStorageSync();
            // 重定向登录
            uni.redirectTo({
                url: '/pages/login/login'
            })
        uni.clearStorageSync();
        // 重定向登录
        uni.redirectTo({
            url: '/pages/login/login'
        })
    }, 2000);
    return false;
}
@@ -84,14 +84,16 @@
// let BaseUrl = 'http://192.168.3.159:9999';
// const BaseUrl = 'https://mx.jzeg.cn:443/app';
const BaseUrl = "https://mx.jzeg.cn:9998";  // 正式服务
// let BaseUrl = 'http://192.168.0.114:9999';
const BaseUrl = "https://mx.jzeg.cn:9998"; // 正式服务
// 请求拦截
const fetch = (url, opt ,urlParam) => {
const fetch = (url, opt, urlParam) => {
    let urls = (api[opt.url]?.url || api[url]?.url || jihua[opt.url]?.url || jihua[url]?.url);
    let params = opt.params ? ('?' + Object.keys(opt.params).map(key => key + '=' + opt.params[key]).join('&')) :
    '';
        '';
    opt.url = urlParam ? BaseUrl + urls + `/${urlParam}` + params : BaseUrl + urls + params
    opt.method = opt.method || "GET";
    var header = {}
@@ -100,7 +102,7 @@
            "TENANT-ID": 5,
            Authorization: 'Bearer ' + uni.getStorageSync('access_token'),
            VERSION: "zzl",
            Accept:'application/json, text/plain, */*' // 客户端所能接受的数据类型
            // Accept: 'application/json, text/plain, */*' // 客户端所能接受的数据类型
        }
    }
utils/tool.js
New file
@@ -0,0 +1,36 @@
/*函数节流
 函数节流是减少函数的触发频率
*/
function throttle(fn, interval) {
  var enterTime = 0;//触发的时间
  var gapTime = interval || 1000 ;//间隔时间,如果interval不传,则默认300ms
  return function() {
    var context = this;
    var backTime = new Date();//第一次函数return即触发的时间
    if (backTime - enterTime > gapTime) {
      fn.call(context,arguments);
      enterTime = backTime;//赋值给第一次触发的时间,这样就保存了第二次触发的时间
    }
  };
}
/*函数防抖
函数防抖则是延迟函数执行,并且不管触发多少次都只执行最后一次
*/
function debounce(fn, interval) {
  var timer;
  var gapTime = interval || 1000;//间隔时间,如果interval不传,则默认1000ms
  return function() {
    clearTimeout(timer);
    var context = this;
    var args = arguments;//保存此处的arguments,因为setTimeout是全局的,arguments不是防抖函数需要的。
    timer = setTimeout(function() {
      fn.call(context,args);
    }, gapTime);
  };
}
export default {
  throttle,
  debounce
};