You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
pdd-order-api/app/libs/const/class.StatusConst.php

97 lines
2.9 KiB
PHP

<?php
class StatusConst {
const yes = 'yes';
const no = 'no';
const normal = 'normal';
const pause = 'pause';
const cancel = 'cancel';
const deny = 'deny';
const delete = 'delete';
const skip = 'skip';
const finish = 'finish';
const wait = 'wait';
const waitRetry = 'wait_retry';
const waitRevert = 'wait_revert';
const waitPlan = 'wait_plan';
const process = 'process';
const processing = 'processing';
const processingRevert = 'processing_revert';
const processChildTask = 'process_child_task';
const processCompareImage = 'process_compare_image';
const partSuccess = 'part_success';
const partProcessing = 'part_processing';
const success = 'success';
const updateSuccess = 'update_success';
const revertSuccess = 'revert_success';
const processingDelete = 'processing_delete';
const fail = 'fail';
const updateFail = 'update_fail';
const revertFail = 'revert_fail';
const markSuccess = 'mark_success';
const processingCancel = 'processing_cancel';
const processingUpdate = 'processing_update';
const cancelFail = 'cancel_fail';
const waitProcessing = 'wait_processing';
const waitProcessingDelete = 'wait_processing_delete';
const waitCheck = 'wait_check';
const checkSuccess = 'check_success';
const checkFail = 'check_fail';
const switchOn = 'on';
const switchOff = 'off';
const waitDwsData = 'wait_dws_data';
const payWait = 'pay_wait';
const paySuccess = 'pay_success';
const payFail = 'pay_fail';
const payManualCheck = 'pay_manual_check';
const payManualRefund = 'pay_manual_refund';
const vasOrderUnpaid = 0;
const vasOrderPaid = 1;
const vasOrderSourceOnline = 0;
const vasOrderSourceOffline = 1;
const moved = 'moved';
const notMoved = 'not_moved';
const moving = 'moving';
const settingStatusAll = 'all';
const settingStatusHasSet = 'has_set';
const settingStatusNotSet = 'not_set';
const delay = 'delay';
const lock = 'lock';
public static function getStatusNameByStatusCode($code) {
$codeMap = [
self::finish => '完成',
self::success => '成功',
self::fail => '失败',
self::cancel => '已取消',
self::wait => '等待',
self::processing => '处理中',
self::waitRevert => '等待恢复',
self::processingRevert => '恢复处理中',
self::revertSuccess => '已恢复',
self::revertFail => '恢复失败',
];
return $codeMap[$code] ?: '';
}
/*
batchTask: StatusConst::wait, StatusConst::waitRetry, StatusConst::waitRevert, StatusConst::processing, StatusConst::processingCancel, StatusConst::cancel, StatusConst::finish
batchTaskQueue: StatusConst::processing, StatusConst::processingRevert
batchTaskGoods: StatusConst::wait, StatusConst::delete, StatusConst::updateSuccess, StatusConst::updateFail, StatusConst::revertSuccess, StatusConst::revertFail
*/
}