@chuxingpay/basic

2.0.21 • Public • Published

fuxun basic json

CHANGELOG

👉 CHANGELOG

Raw data

  • BankMap (major bank list)

[data] with properties

Syntax Description Sample
Bedmap Bed Types {"name": "其它", "nameEn": "Others", "code": "BT00", "bedCount": 1}
BreakfastMap Breakfast {"name": "无早","nameEn": "No meals","code": 0}
CurrencyMap Currency Codes {"name": "人民币","nameEn": "CNY","code": "CNY","symbol": "¥"}
ErrorMap Error Response Code {"code": "-1","name": "服务器异常,建议稍后再试","nameEn": "Server abnormal, please try later"}
HttpCodeMap Http Status code {"code": 200,"name": "请求成功","nameEn": "OK","description": "The request has succeeded."}
FacilityMap Facility Types {"code": "FCT01", "name": "酒店设施", "nameEn": "Hotel Facilities", "icon": "cuIcon-check1"}
PaymentMap Payment Methods {"code": "union","name": "银联","nameEn": "UnionPay"}
PhotoMap Photo Category {"code": "PC01","name": "外景","nameEn": "Outdoor view"}
PriceMap Price Category {"name": "付迅协议价","nameEn": "付迅协议价","code": "RT02"}
UnitMap Room Unit {"name": "标准房","nameEn": "Standard","code": "RU01"}
WifiMap Wifi Category {"name": "没有网络","nameEn": "No network","code": 0}
WindowMap Window Category {"name": "无窗","nameEn": "No window","code": 0}
GroupMap Hotel Group (Search available) {"name":"洲际","id":1,"src":"zhouJi","nameEn":"IHG"}
GroupFull Hotel Group {"id":10193,"name":"亚朵","nameEn":"亚朵"}
BrandMap Hotel Brand {"id":7,"name":"锦江","level":0,"nameEn":"Jinjiang"}

Usage

npm i @chuxingpay/basic
// load multiple module
const { CurrencyMap, GroupMap, BrandMap } = require("@chuxingpay/basic");

// load single module (RECOMMENDED !!!)
const HttpCodeMap = require("@chuxingpay/basic/es/HttpCodeMap");
import FacilityMap from "@chuxingpay/basic/es/FacilityMap";
import { CurrencyMap, GroupMap, BrandMap } = from('@chuxingpay/basic')

console.log(CurrencyMap.list)
// output [ { "code": "", "name": "", "nameEn": "" }, ...rest ]

console.log(CurrencyMap.codes)
// output ['CNY', 'USD', ...rest ]

console.log(CurrencyMap.find('USD'))
// output [ { "name": "美元", "nameEn": "USD", "code": "USD", "symbol": "$" } ]

console.log(CurrencyMap.findOne('USD'))
// output { "name": "美元", "nameEn": "USD", "code": "USD", "symbol": "$" }

console.log(CurrencyMap.findOne('nil*'))
// output {}

console.log(GroupMap.list)
// output [ { "id": 0, "name": "", "nameEn": "", "src": "" }, ...rest ]

console.log(BrandMap.findByLevel(0))
// output [{"id": 0, "level": 0, "name": "", "nameEn": ""}]

CurrencyMap reference (ISO 4217 code)

Readme

Keywords

Package Sidebar

Install

npm i @chuxingpay/basic

Weekly Downloads

2

Version

2.0.21

License

MIT

Unpacked Size

238 kB

Total Files

38

Last publish

Collaborators

  • canliu
  • jonny.huang
  • qiuxiaoming
  • leeqiang
  • anxing131
  • destec