var db = function( host, port, user, pwd, sys_table_list){
	this.sys_table_list = sys_table_list;
	this.host = host || '192.168.4.39';
	this.port = port || '3306';
	this.user = user || 'xyqb_query';
	this.pwd = pwd || 'Uiwb@o^fR&nHOa5t';
}
module.exports = {
	db_config:function(){
		this.dbs = {
		mall : new db('','','','','activity_3c_product ad_detail admin_banner advertisement_type album app_channel app_channel_ad app_name app_name_ad category category_banner category_nature commodity_slogan commodity_slogan_product configuration edx_city faster_entrance faster_entrance_image goods_after_sale_config goods_after_sale_step home_config home_page hot_category jd_address jd_after_sale_config jd_brand jd_category jd_product_sku_image jd_property jd_sku jd_sku_detail_image jd_sku_specs life_faster_entrance life_service mall_category mall_config merchant nature_value new_3c_product product product_category product_nature product_nature_value_bak product_sku product_sku_image product_specification product_spu recommend_brand recommend_product sale_product_detail sale_product_theme spu_image supplier tab_navigate title_banner loan_config virtual_brand virtual_category virtual_product_discount virtual_product_hot virtual_product_sku virtual_product_spu virtual_product_template'),
		xyqb : new db('','','','','baitiao_merchant baitiao_secure_key channel funding_contract funding_corp loan_product merchant_channel payeco_return_url_info red_packet t_phonenum zmxy_return_url configuration secure_proxy funding_corp_config funding_info_map baitiao_preferential_rule funding_corp_policy'),
		account_center : new db('192.168.4.116','6001','','',''),
		cash_loan_flow : new db('192.168.4.80','8001','','','order_callback callback_configuration channel_configuration filter_configuration'),
		clotho : new db('192.168.3.19','3308','','',''),
		contract : new db('','3311','','','contract_template_new'),
		display : new db('192.168.3.19','3307','','','discovery_config'),
		dujiangyan : new db('','3310','','','external_coopr'),
		financial_system : new db('','6603','','','collection_user sys_dictionary sys_status_edge sys_status_vertice'),
		financial_system_api : new db('','6603','','','mailinfo'),
		fund_manage : new db('','3310','','','business_info email_info fund_info merchant'),
		gyxd : new db('192.168.4.116','6602','','','administrative_districts templet user'),
		mall_settlement : new db('192.168.4.253','3315','','','role role_user user'),
		merchant : new db('','3314','','','authority product_nature role role_authority role_supplier role_user user'),
		notify : new db('192.168.4.6','7306','','','merchant merchant_config'),

		offline : new db('','3311','','','goods_detail merchant operator_user'),

		payment_center : new db('','3308','','','card_switcher merchant merchant_config pay_approach_config merchant_pay_approach_relation merchant_bank_config quota'),

		qinqiong : new db('','3310','','','secure_key secure_proxy'),

		quartz : new db('','3310','','','certain_time_job'),
	
		reconciliation : new db('192.168.3.19','3308','','',''),

		redpacket : new db('192.168.4.116','6001','','','tb_activity_channel tb_dict_channel tb_dict_out_channel'),
	
		risk_control : new db('','3309','','','company product_strategy_dispatcher quantify_product red_packet_info user'),
	
		score : new db('192.168.4.249','3322','','',''),
	
		silk_road : new db('192.168.4.80','9999','','',''),
	
		spider_center : new db('192.168.4.253','3317','','','merchant merchant_config'),

		traffic_distribution : new db('192.168.3.36','3313','','','merchant merchant_carousel merchant_credit merchant_detail merchant_section merchant_sort ppdai_exclude_channel t_module t_module_role t_role t_user t_user_role traffic_channel_banner_ids traffic_channel_ids traffic_channel_sort traffic_infos'),

		urge_dispatcher : new db('192.168.4.116','9901','','',''),

		user_credit : new db('','9001','','',''),

		xyqb_app : new db('','3307','','','activities app_banners app_config app_versions banners blanknote_entries credit_questions hot_games loan_banners loan_questions migrations sharings widgets js_patch upgrade_version'),

		xyqb_btzt : new db('','9002','','','zt_channel zt_fund zt_fund_channel zt_fund_credit zt_fund_term'),

		xyqb_user : new db('','3313','','','merchant_config merchant'),	
		}
		return this.dbs
	},
	get_mysql_dump_command:function(key){
		let item = this.dbs[key];
		return `mysqldump --host=${item.host} --port=${item.port} --user=${item.user} --password="${item.pwd}" ${key} ${item.sys_table_list}`
	},
	get_target_mysql_command:function(key){
		
	}
}