|
|
@@ -2,42 +2,77 @@
|
|
|
import DetailStep from './DetailStep.vue'
|
|
|
import ShipmentInforTable from './ShipmentInforTable.vue'
|
|
|
import OperationLogProcess from './OperationLogProcess.vue'
|
|
|
+import { formatTimezone } from '@/utils/tools'
|
|
|
|
|
|
const visible = ref(false)
|
|
|
|
|
|
const openDialog = (row: any) => {
|
|
|
visible.value = true
|
|
|
- console.log(row)
|
|
|
}
|
|
|
|
|
|
const stepList: any = ref([
|
|
|
{
|
|
|
- id: 1,
|
|
|
label: 'Created',
|
|
|
date: 'Jun-01-2024',
|
|
|
icon: 'icon_submit_b',
|
|
|
status: 'completed'
|
|
|
- },
|
|
|
- {
|
|
|
- label: 'Pending',
|
|
|
- date: 'Current',
|
|
|
- icon: 'icon_time_b',
|
|
|
- status: 'current'
|
|
|
- },
|
|
|
- {
|
|
|
- label: 'Rejected',
|
|
|
- date: 'Jun-03-2024',
|
|
|
- icon: 'icon_reject_b',
|
|
|
- status: 'rejected'
|
|
|
- },
|
|
|
- {
|
|
|
- label: 'Approved',
|
|
|
- date: 'Jun-03-2024',
|
|
|
- icon: 'icon_confirm_b',
|
|
|
- status: 'current'
|
|
|
}
|
|
|
])
|
|
|
|
|
|
+const status = ref('pending')
|
|
|
+const handleStepData = () => {
|
|
|
+ let updateTime = 'Jun-04-2024'
|
|
|
+ if (updateTime && status.value === 'pending') {
|
|
|
+ stepList.value.push({
|
|
|
+ label: 'Modified',
|
|
|
+ date: 'Jun-04-2024',
|
|
|
+ icon: 'icon_edit_b'
|
|
|
+ })
|
|
|
+ }
|
|
|
+ if (status.value === 'pending') {
|
|
|
+ stepList.value.push({
|
|
|
+ label: 'Pending',
|
|
|
+ date: 'Current',
|
|
|
+ icon: 'icon_time_b',
|
|
|
+ status: 'current'
|
|
|
+ })
|
|
|
+ stepList.value.push({
|
|
|
+ label: 'Approved',
|
|
|
+ date: 'Current',
|
|
|
+ icon: 'icon_confirm_b',
|
|
|
+ status: 'unfinished'
|
|
|
+ })
|
|
|
+ } else if (status.value === 'approved') {
|
|
|
+ stepList.value.push({
|
|
|
+ label: 'Approved',
|
|
|
+ date: '--',
|
|
|
+ icon: 'icon_confirm_b',
|
|
|
+ status: 'unfinished'
|
|
|
+ })
|
|
|
+ } else if (status.value === 'rejected') {
|
|
|
+ stepList.value.push({
|
|
|
+ label: 'Rejected',
|
|
|
+ date: 'Jun-05-2024',
|
|
|
+ icon: 'icon_reject_b',
|
|
|
+ status: 'rejected'
|
|
|
+ })
|
|
|
+ } else if (status.value === 'cancelled') {
|
|
|
+ stepList.value.push({
|
|
|
+ label: 'Cancelled',
|
|
|
+ date: 'Jun-05-2024',
|
|
|
+ icon: 'icon_cancelled_b',
|
|
|
+ status: 'completed'
|
|
|
+ })
|
|
|
+ }
|
|
|
+}
|
|
|
+handleStepData()
|
|
|
+const deliveryInfoData = ref({
|
|
|
+ modeType: 'Truck',
|
|
|
+ deliveryDate: 'Jun-15-2024',
|
|
|
+ deliveryAddress: 'Main Distribution Center,160#BEIJING ROAD, JINGAN District, Shenzhen, China',
|
|
|
+ specialRequirements: 'Tail Lift Required'
|
|
|
+})
|
|
|
+
|
|
|
defineExpose({
|
|
|
openDialog
|
|
|
})
|
|
|
@@ -67,29 +102,27 @@ defineExpose({
|
|
|
<div class="delivery-info">
|
|
|
<div class="delivery-item inline-flex" style="width: 200px">
|
|
|
<span class="item-label">Mode Type</span>
|
|
|
- <span class="item-value">Shanghai, China</span>
|
|
|
+ <span class="item-value">{{ deliveryInfoData.modeType }}</span>
|
|
|
</div>
|
|
|
<div class="delivery-item inline-flex">
|
|
|
<span class="item-label">Delivery Date</span>
|
|
|
<span class="item-value">
|
|
|
<span class="font_family icon-icon_date_b" style="margin-right: 4px"></span>
|
|
|
- <span style="margin-top: 1px">Jun-15-2024</span>
|
|
|
+ <span style="margin-top: 1px">{{ formatTimezone(deliveryInfoData.deliveryDate) }}</span>
|
|
|
</span>
|
|
|
</div>
|
|
|
<div class="delivery-item">
|
|
|
<span class="item-label">Delivery Address</span>
|
|
|
<span class="item-value">
|
|
|
<span class="font_family icon-icon_location_b" style="margin-right: 2px"></span>
|
|
|
- <span style="margin-top: 1px"
|
|
|
- >Main Distribution Center,160#BEIJING ROAD, JINGAN District, Shenzhen, China</span
|
|
|
- >
|
|
|
+ <span style="margin-top: 1px">{{ deliveryInfoData.deliveryAddress }}</span>
|
|
|
</span>
|
|
|
</div>
|
|
|
<div class="delivery-item">
|
|
|
<span class="item-label">Special Requirements</span>
|
|
|
<span class="item-value">
|
|
|
<span class="font_family icon-icon_paragraph_b" style="margin-right: 2px"></span>
|
|
|
- <span style="margin-top: 1px">Tail Lift Required</span>
|
|
|
+ <span style="margin-top: 1px">{{ deliveryInfoData.specialRequirements }}</span>
|
|
|
</span>
|
|
|
</div>
|
|
|
</div>
|