<commit_before># coding: utf-8
Spree::Config.currency = "CNY"

zone = Spree::Zone.find_or_create_by(
  {
    name: "中国", description: "中国", default_tax: false,
    kind: "country"
  }
)
zone.save
z = Spree::ZoneMember.new
z.zoneable =Spree::Country.find_by(iso_name: "CHINA")
z.zone = zone
z.save

Spree::Config.address_requires_state = true
Spree::AddressBook::Config[:disable_bill_address] = true
Spree::Config[:allow_guest_checkout] = false

shipping_category = Spree::ShippingCategory.find_or_create_by!(name: "快递")
shipping_method = Spree::ShippingMethod.find_or_create_by(name: '快递')
shipping_method.shipping_categories.destroy_all
shipping_method.shipping_categories.push shipping_category

shipping_rate = Spree::Calculator::Shipping::FlatRate.new
shipping_rate.preferences[:amount] = 5
shipping_rate.calculable = shipping_method
shipping_rate.save

shipping_method.calculator = shipping_rate
shipping_method.zones.push(zone)
shipping_method.save

store = Spree::Store.first
store.name = "塞外宝岛"
store.default_currency = "CNY"
store.save

alipay = Spree::Gateway::AlipayDirect.find_or_initialize_by(name: '支付宝')
alipay.preferences[:alipay_pid] = '2088022452414794'
alipay.preferences[:alipay_key] = '<KEY>'
alipay.active = true
alipay.save

check = Spree::PaymentMethod::Check.find_or_initialize_by(name: '账户转账')
check.active = true
check.description = "<p>开卡行：农业银行内蒙古分行   二连浩特支行</p><p>农业银行卡号： 6228 4550 5601 0194 762  户名：明干巴雅尔</p>"
check.save<commit_msg>change name<commit_after># coding: utf-8
Spree::Config.currency = "CNY"

zone = Spree::Zone.find_or_create_by(
  {
    name: "中国", description: "中国", default_tax: false,
    kind: "country"
  }
)
zone.save
z = Spree::ZoneMember.new
z.zoneable =Spree::Country.find_by(iso_name: "CHINA")
z.zone = zone
z.save

Spree::Config.address_requires_state = true
Spree::AddressBook::Config[:disable_bill_address] = true
Spree::Config[:allow_guest_checkout] = false

shipping_category = Spree::ShippingCategory.find_or_create_by!(name: "快递")
shipping_method = Spree::ShippingMethod.find_or_create_by(name: '快递')
shipping_method.shipping_categories.destroy_all
shipping_method.shipping_categories.push shipping_category

shipping_rate = Spree::Calculator::Shipping::FlatRate.new
shipping_rate.preferences[:amount] = 5
shipping_rate.calculable = shipping_method
shipping_rate.save

shipping_method.calculator = shipping_rate
shipping_method.zones.push(zone)
shipping_method.save

store = Spree::Store.first
store.name = "塞外宝岛"
store.default_currency = "CNY"
store.save

alipay = Spree::Gateway::AlipayDirect.find_or_initialize_by(name: '支付宝')
alipay.preferences[:alipay_pid] = '2088022452414794'
alipay.preferences[:alipay_key] = '<KEY>'
alipay.active = true
alipay.save

check = Spree::PaymentMethod::Check.find_or_initialize_by(name: '账户转账')
check.active = true
check.description = "<p>开户行：中国农业银行</p><p>农业银行卡号： 62284 5505 60101 94762  户名：明干巴雅尔</p>"
check.save
{'fraction_non_alphanumeric': 0.12994156067377105, 'fraction_numerical': 0.025438294946717083, 'mean_word_length': 7.660714285714286, 'pattern_counts': {'":': 0, '<': 13, '<?xml version=': 0, '>': 13, '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': '7537182', 'n_tokens_mistral': 1183, 'n_tokens_neox': 1183, 'n_words': 162}