//
//  Singleton.h
//  iSales-NPD
//
//  Created by Jack on 2016/10/12.
//  Copyright © 2016年 United Software Applications, Inc. All rights reserved.
//

#import <Foundation/Foundation.h>
#import <sqlite3.h>

@interface Singleton : NSObject

typedef enum {
    Shop_Order = 0,
    Sales_Order = 1
}Customer_Oder_Type;

@property (nonatomic,assign) sqlite3 *currentDB;///<当前打开的数据库

#pragma mark - Customer

@property (nonatomic,assign) BOOL permissions_price_setting;///<价格设置权限
@property (nonatomic,assign) BOOL permissions_edit_order;///<编辑订单权限，Place Order
@property (nonatomic,assign) BOOL permissions_submit_order;///<提交订单权限
@property (nonatomic,assign) BOOL permissions_merge_order;///<合并订单权限

@property (nonatomic,assign) NSInteger npd_shop_price_type;///<Shop设置的价格类型，0提货价、1统一卖价、 2计算价
@property (nonatomic,copy) NSString *deliveryString;///<登陆成功后接收的提货价名称
// 使用枚举吗？Customer_Oder_Type
@property (nonatomic,assign) NSInteger customer_order_type;///< 0 Shop Order/ 1 Sales Order，

@property (nonatomic,assign) BOOL global_lock;///<全局锁，Yes表示订单不能查看Detail，需要密码验证Price Setting，Hide Price
@property (nonatomic,assign) BOOL customer_can_see_sales_Order;///<是否有权查看Sales Order，控制Order List
@property (nonatomic,strong) NSMutableDictionary *shop_order_status_filter;///<Shop Order Status
@property (nonatomic,copy) NSString *specialInstruction;///<登陆时传的Special Instruction，在提交订单时显示
@property (nonatomic,assign) BOOL currentOrderIsMerged;///<当前打开的订单是否为Purchas Order
#pragma mark - Employee 



#pragma mark - Method

+ (instancetype)sharedInstance;

- (void)resetGlobalLock;

@end
