<commit_before><?php

use yii\db\Schema;
use yii\db\Migration;

class m150108_010000_payment extends Migration{

	public function up(){
		$tableOptions = 'engine=innodb character set utf8';
		if($this->db->driverName === 'mysql') {
			$tableOptions .= ' collate utf8_unicode_ci';
		}

		$this->createTable('{{%payment}}', [
			'id' => Schema::TYPE_BIGINT . ' not null primary key comment "支付单id"',
			'oid' => Schema::TYPE_TEXT . ' not null comment "订单id, 多个以英文逗号隔开"',
			'type' => Schema::TYPE_BOOLEAN . ' not null default 1 comment "支付单类型: 1普通支付单"',
			'title' => Schema::TYPE_STRING . '(50) not null comment "订单名称"',
			'description' => Schema::TYPE_STRING . ' comment "描述信息"',
			'url' => Schema::TYPE_TEXT . ' comment "商品展示url"',
			'amount' => Schema::TYPE_BIGINT . ' unsigned not null default 0 comment "支付总额(分)"',
			'mode' => Schema::TYPE_STRING . '(50) not null comment "支付方式"',
			'tid' => Schema::TYPE_STRING . '(50) comment "第三方支付端流水号"',
			'completed_at' => Schema::TYPE_INTEGER . ' not null default 0 comment "支付完成时间"',
			'created_at' => Schema::TYPE_INTEGER . ' not null comment "创建时间"',
			'updated_at' => Schema::TYPE_INTEGER . ' not null comment "更新时间"',
		], $tableOptions . ' comment="支付单"');
	}

	public function down(){
		$this->dropTable('{{%payment}}');
	}<commit_msg>payment<commit_after><?php

use yii\db\Schema;
use yii\db\Migration;

class m150108_010000_payment extends Migration{

	public function up(){
		$tableOptions = 'engine=innodb character set utf8';
		if($this->db->driverName === 'mysql') {
			$tableOptions .= ' collate utf8_unicode_ci';
		}

		$this->createTable('{{%payment}}', [
			'id' => Schema::TYPE_BIGINT . ' not null primary key comment "支付单id"',
			'oid' => Schema::TYPE_TEXT . ' not null comment "订单id, 多个以英文逗号隔开"',
			'type' => Schema::TYPE_BOOLEAN . ' not null default 1 comment "支付单类型: 1普通支付单"',
			'title' => Schema::TYPE_STRING . '(50) not null comment "订单名称"',
			'description' => Schema::TYPE_STRING . ' comment "描述信息"',
			'url' => Schema::TYPE_TEXT . ' comment "商品展示url"',
			'amount' => Schema::TYPE_BIGINT . ' unsigned not null default 0 comment "支付总额(分)"',
			'mode' => Schema::TYPE_STRING . '(50) not null comment "支付方式"',
			'tid' => Schema::TYPE_STRING . '(50) comment "第三方支付端流水号"',
			'completed_at' => Schema::TYPE_INTEGER . ' not null default 0 comment "支付完成时间"',
			'abnormal' => Schema::TYPE_BOOLEAN . ' not null default 0 comment "异常标记: 0正常, 1异常"',
			'created_at' => Schema::TYPE_INTEGER . ' not null comment "创建时间"',
			'updated_at' => Schema::TYPE_INTEGER . ' not null comment "更新时间"',
		], $tableOptions . ' comment="支付单"');
	}

	public function down(){
		$this->dropTable('{{%payment}}');
	}
{'fraction_non_alphanumeric': 0.18277153558052434, 'fraction_numerical': 0.019101123595505618, 'mean_word_length': 4.473360655737705, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 36, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5884286', 'n_tokens_mistral': 1120, 'n_tokens_neox': 1061, 'n_words': 228}