| 1234567891011121314151617181920212223242526272829303132333435363738394041424344 |
- // pages/voyages/detail/detail.js
- import {
- postApi
- } from "../../../apis/api"
- Page({
- data: {
- id: '',
- tab: 1,
- recordCurrentPage: 1,
- dischargeCurrentPage: 1
- },
- changeTab(e) {
- let {
- tab
- } = e.currentTarget.dataset
- this.setData({
- tab
- })
- },
- async getVoyageDetail() {
- let res = await postApi("/voyage/detail", {
- voyageId: this.data.id
- })
- },
- async getCarLoadRecordList() {
- let res = await postApi("/voyage/getCarLoadRecordList", {
- voyageId: this.data.id
- })
- },
- async getDischargeList() {
- let res = await postApi("/voyage/getDischargeList", {
- voyageId: this.data.id
- })
- },
- onLoad(options) {
- this.setData({
- id: options.id
- })
- this.getVoyageDetail()
- },
- })
|