English
English
简体中文
Contact Us
Register
Log In
layoutIndex

Panel Multilingual BizBundle

Last Updated on : 2022-09-16 09:19:48download

Panel Multilingual BizBundle provides the capabilities to update and get panel language packs for smart products based on the integration with Smart Life App SDK. Go to Tuya IoT Development Platform > App > Multi-language > Product Language to manage multilingual entries of smart products.

Functional description

  • You must call API methods in TuyaSmartLangsManager to get information about the list views.

  • Add the components of the Voice Skills Account Linking UI BizBundle to the Podfile and run the command pod update.

    source "https://github.com/tuya/tuya-pod-specs"
    source 'https://cdn.cocoapods.org/'
    platform :ios, '11.0'
    
    target 'your_target_name' do
    // Adds the UI BizBundle.
    pod 'TuyaSmartLangsExtraBizBundle'
    end
    
  • Dependent services: none

Update panel multilingual content

API description

- (void)updateProductLangWithProductId:(NSString *)productId
                              i18nTime:(long long)i18nTime
                         completeBlock:(void (^)(NSError *error))completeBlock;

Request parameters

Field Type Description
productId NSString The product ID (PID). The devices with the same PID have the same schema data. You can call deviceModel.productId to get the PID.
i18nTime Long The multilingual timestamp of a product. You can call deviceModel.i18nTime to get the value.

ObjC:

[[TuyaSmartLangsManager sharedInstance] updateProductLangWithProductId:deviceModel.productId i18nTime:deviceModel.i18nTime completeBlock:^(NSError * _Nonnull error) {

}];

Swift:

TuyaSmartLangsManager.sharedInstance().updateProductLang(withProductId: deviceModel.productId, i18nTime: deviceModel.i18nTime, completeBlock: { (error) in

})

Query panel multilingual content

API description

- (void)getProductLangWithProductId:(NSString *)productId
                           i18nTime:(long long)i18nTime
                       successBlock:(void (^)(NSDictionary *langsDic))successBlock
                          failBlock:(void (^)(NSError *error))failBlock;

Request parameters

Field Type Description
productId NSString The product ID (PID). The devices with the same PID have the same schema data. You can call deviceModel.productId to get the PID.
i18nTime Long The multilingual timestamp of a product. You can call deviceModel.i18nTime to get the value.

ObjC:

[[TuyaSmartLangsManager sharedInstance] getProductLangWithProductId:deviceModel.productId i18nTime:deviceModel.i18nTime successBlock:^(NSDictionary * _Nonnull langsDic) {

} failBlock:^(NSError * _Nonnull error) {

}];

Swift:

TuyaSmartLangsManager.sharedInstance().getProductLang(withProductId: deviceModel.productId, i18nTime: deviceModel.i18nTime, successBlock: { (result) in

}, failure: { (error) in

})