• 发货物流信息
field($model, 'no')->textInput(['maxlength' => true]) ?> field($model, 'com')->textInput(['maxlength' => true]) ?> field($model, 'status')->dropDownList(\common\models\Package::getStatusList()) ?>
isNewRecord ? Yii::t('common', 'Create') : Yii::t('common', 'Update'), ['class' => $model->isNewRecord ? 'btn btn-success' : 'btn btn-success']) ?>
  • 发货商品
$orderSku['data'], 'columns' => [ 'id', [ 'attribute' => 'goods_id', 'format' => 'raw', 'value' => function ($model) { return $model->goods->name; }, ], [ 'attribute' => 'sku_id', 'format' => 'raw', 'value' => function ($model) { if ($model->sku) { return $model->sku->name; } else { return '默认'; } }, ], 'quantity', 'unit_price', [ 'label' => '商品总价', 'format' => 'raw', 'value' => function ($model) { return $model->quantity * $model->unit_price . '元'; }, ], [ 'attribute' => 'status', 'value' => function ($model) { return \common\models\OrderSku::getStatusList($model->status); }, ], ], ]); ?>
  • 订单信息
$order, 'attributes' => [ 'id', // [ // 'attribute' => 'user_id', // 'format' => 'raw', // 'value' => function ($model) { // if (!empty($model->user)) { // return Html::a($model->user->nickName, \yii\helpers\Url::to(['/wechat-user/view', 'id' => $model->user_id]), ['title' => '查看用户', 'data-toggle' => 'tooltip', 'target' => '_blank']); // } else { // return '无'; // } // }, // ], 'out_trade_no', 'user_id:user', 'order_no', 'total_amount', 'pay_amount', 'pay_time:datetime', 'remark', 'receiver_name', 'receiver_tel', 'receiver_address', 'created_at:datetime', 'updated_at:datetime', [ 'attribute' => 'status', 'value' => function ($model) { return \common\models\Order::getStatusList($model->status); }, ], ], ]) ?>