Files
OMS/app/omeanalysts/dbschema/ome_orderDiscounts.php
2026-01-04 19:08:31 +08:00

206 lines
7.2 KiB
PHP

<?php
/**
* Copyright 2012-2026 ShopeX (https://www.shopex.cn)
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
$db['ome_orderDiscounts'] = array(
'columns' => array(
'discount_id' => array(
'type' => 'int unsigned',
'required' => true,
'pkey' => true,
'editable' => false,
'extra' => 'auto_increment',
),
'order_id' => array(
'type' => 'table:orders@ome',
'required' => true,
'editable' => false,
),
'order_bn' => array(
'type' => 'varchar(32)',
'required' => true,
'label' => '订单号',
'width' => 180,
'editable' => false,
'filtertype' => 'normal',
'filterdefault' => true,
'in_list' => true,
),
'sku' => array(
'type' => 'varchar(200)',
'label' => '商品货号',
'width' => 120,
'editable' => false,
'filterdefault' => false,
'in_list' => false,
'default_in_list' => false,
'default' => '',
),
'shop_id' => array(
'type' => 'table:shop@ome',
'label' => '来源店铺',
'width' => 75,
'editable' => false,
'in_list' => true,
'filtertype' => 'normal',
'filterdefault' => true,
),
'shop_type' => array(
'type' => 'varchar(50)',
'label' => '平台类型',
'width' => 75,
'editable' => false,
'in_list' => true,
'filtertype' => 'normal',
'filterdefault' => true,
),
'original_money' => array(
'type' => 'money',
'default' => '0',
'required' => true,
'editable' => false,
'label' => '原价金额',
'in_list' => true,
'default_in_list' => true,
'sdfpath' => 'cur_amount',
),
'sale_money' => array(
'type' => 'money',
'default' => '0',
'required' => true,
'editable' => false,
'label' => '销售金额',
'in_list' => true,
'default_in_list' => true,
'sdfpath' => 'cur_amount',
),
'pay_money' => array(
'type' => 'money',
'default' => '0',
'required' => true,
'editable' => false,
'label' => '支付金额',
'in_list' => true,
'default_in_list' => true,
'sdfpath' => 'cur_amount',
),
'discount_type' => array(
'type' => array(
'pay' => '支付优惠',
'promotion' => '促销优惠',
),
'default' => 'promotion',
'required' => true,
'label' => '优惠类型',
'width' => 70,
'editable' => false,
'filtertype' => 'yes',
'filterdefault' => true,
'in_list' => true,
'default_in_list' => false,
),
'discount_name' => array(
'type' => 'longtext',
'editable' => false,
'in_list' => true,
'default_in_list' => true,
'label' => '优惠名称',
),
'discount_money' => array(
'type' => 'money',
'default' => '0',
'required' => true,
'editable' => false,
'label' => '优惠金额',
'in_list' => true,
'default_in_list' => true,
'sdfpath' => 'cur_amount',
),
'order_createtime' => array(
'type' => 'time',
'label' => '下单时间',
'width' => 130,
'editable' => false,
'filtertype' => 'time',
'filterdefault' => true,
'in_list' => true,
),
'paytime' => array(
'type' => 'time',
'label' => '付款时间',
'width' => 130,
'editable' => false,
'in_list' => true,
),
'pay_status' => array(
'type' => array(
0 => '未支付',
1 => '已支付',
2 => '处理中',
3 => '部分付款',
4 => '部分退款',
5 => '全额退款',
6 => '退款申请中',
7 => '退款中',
8 => '支付中',
),
'default' => '0',
'required' => true,
'label' => '付款状态',
'width' => 75,
'editable' => false,
'filtertype' => 'yes',
'filterdefault' => true,
'in_list' => true,
'default_in_list' => false,
),
'createtime' => array(
'type' => 'time',
'label' => '记录创建时间',
'width' => 130,
'editable' => false,
'filtertype' => 'time',
'filterdefault' => true,
'in_list' => false,
),
'last_modified' => array(
'label' => '记录最后更新时间',
'type' => 'last_modify',
'width' => 130,
'editable' => false,
'in_list' => false,
'default' => 0,
),
'org_id' => array(
'type' => 'table:operation_organization@ome',
'label' => '运营组织',
'editable' => false,
'width' => 60,
'filtertype' => 'normal',
'filterdefault' => true,
'in_list' => true,
'default_in_list' => true,
),
),
'index' => array(
'ind_paytime_order_bn_shop' => array('columns' => array(0 => 'paytime',1 => 'order_bn', 2 => 'shop_id')),
'ind_order_bn' => array('columns' => array(0 => 'order_bn')),
),
'comment' => '订单优惠明细表',
'engine' => 'innodb',
'version' => '$Rev: $',
);