本文整理汇总了Java中com.odoo.core.account.Profile类的典型用法代码示例。如果您正苦于以下问题:Java Profile类的具体用法?Java Profile怎么用?Java Profile使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
Profile类属于com.odoo.core.account包,在下文中一共展示了Profile类的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: baseSettingsItems
import com.odoo.core.account.Profile; //导入依赖的package包/类
public static List<ODrawerItem> baseSettingsItems(Context context) {
String key = "base.settings";
OPreferenceManager pref = new OPreferenceManager(context);
List<ODrawerItem> settings = new ArrayList<>();
settings.add(new ODrawerItem(key).setTitle(OResource.string(context, R.string.label_settings))
.setGroupTitle());
settings.add(new ODrawerItem(key).setTitle(OResource.string(context, R.string.title_profile))
.setInstance(Profile.class).setIcon(R.drawable.ic_action_user));
settings.add(new ODrawerItem(key).setTitle(OResource.string(context, R.string.label_settings))
.setIcon(R.drawable.ic_action_settings)
.setInstance(SettingsActivity.class));
// if (pref.getBoolean(Profile.CONNECT_WITH_ODOO, false))
// settings.add(new ODrawerItem(key).setTitle(OResource.string(context, R.string.label_access_odoo_mobile))
// .setInstance(OdooMobileQRReader.class).setIcon(R.drawable.ic_action_qrcode)
// .setExtra(OUser.current(context).getAsBundle()));
// OdooNews news = new OdooNews(context, null);
// if (!news.isEmptyTable()) {
// settings.add(new ODrawerItem(key).setTitle("Odoo News")
// .setInstance(new News()).setIcon(R.drawable.ic_odoo_o)
// );
// }
return settings;
}
示例2: baseSettingsItems
import com.odoo.core.account.Profile; //导入依赖的package包/类
public static List<ODrawerItem> baseSettingsItems(Context context) {
String key = "base.settings";
OPreferenceManager pref = new OPreferenceManager(context);
List<ODrawerItem> settings = new ArrayList<>();
settings.add(new ODrawerItem(key).setTitle(OResource.string(context, R.string.label_settings))
.setGroupTitle());
settings.add(new ODrawerItem(key).setTitle(OResource.string(context, R.string.title_profile))
.setInstance(Profile.class).setIcon(R.drawable.ic_action_user));
settings.add(new ODrawerItem(key).setTitle(OResource.string(context, R.string.label_settings))
.setIcon(R.drawable.ic_action_settings)
.setInstance(SettingsActivity.class));
// if (pref.getBoolean(Profile.CONNECT_WITH_ODOO, false))
// settings.add(new ODrawerItem(key).setTitle(OResource.string(context, R.string.label_access_odoo_mobile))
// .setInstance(OdooMobileQRReader.class).setIcon(R.drawable.ic_action_qrcode)
// .setExtra(OUser.current(context).getAsBundle()));
OdooNews news = new OdooNews(context, null);
if (!news.isEmptyTable()) {
settings.add(new ODrawerItem(key).setTitle("Odoo News")
.setInstance(new News()).setIcon(R.drawable.ic_odoo_o)
);
}
return settings;
}