@Override
  public void onCreate(Bundle savedInstanceState) {
    // TODO Auto-generated method stub
    super.onCreate(savedInstanceState);
    // super.setDataBaseParams(DbOpenHelper.class);
    setRetainInstance(true);

    setContentView(R.layout.fragment_transaction_edit_extension);

    salesCategoryAdapter =
        new SimpleCursorAdapter(
            this.getActivity(),
            R.layout.rowlist_transaction_edit_salescategory,
            null,
            new String[] {Contract.SalesCategory.FIELD_NAME},
            new int[] {R.id.textView_name},
            0) {

          @Override
          public View getView(int position, View convertView, ViewGroup parent) {
            View result = super.getView(position, convertView, parent);
            if (position == 0) {
              TextView t = (TextView) result.findViewById(R.id.textView_name);
              t.setCompoundDrawablesWithIntrinsicBounds(0, 0, 0, R.drawable.ic_action_important);
              t.setPadding(5, 5, 5, 5);
            }
            return result;
          }
        };

    loaderProductCategoryCallback = new LoaderProductSalesCategory();

    produtAdpater = newProductAdapter(productSalesCategoryList);
  }
 @Override
 public void onAttach(Activity activity) {
   // TODO Auto-generated method stub
   super.onAttach(activity);
   if (!(activity instanceof TransactionEditExtensionListener))
     throw new IllegalStateException(
         "Activity must implements Fragment TransactionEditExtensionListener");
   transactionEditExtensionCallback = (TransactionEditExtensionListener) activity;
 }
  @Override
  public void onLoaderReset(Loader<Cursor> loader) {
    super.onLoaderReset(loader);
    switch (loader.getId()) {
      case LOADER_SALESCATEGORY:
        salesCategoryAdapter.swapCursor(null);

        break;
    }
  }
  @Override
  public void onActivityCreated(Bundle savedInstanceState) {
    super.onActivityCreated(savedInstanceState);

    getLoaderManager().initLoader(LOADER_SALESCATEGORY, null, this);

    Bundle args = new Bundle();
    args.putInt(LoaderProductSalesCategory.ARG_SALESCATEGORYID, salesCategoryId);
    getLoaderManager().initLoader(LOADER_PRODUCTBYCATEGORY, args, loaderProductCategoryCallback);
  }
  @Override
  public void onFragmentCreateView(View rootView, Bundle savedInstanceState) {
    super.onFragmentCreateView(rootView, savedInstanceState);

    setViewAdapter(
        R.id.listView_client_attention,
        new SimpleGeneralValueAdapter(
            this.getContext(),
            GeneralValue.getGeneralValues(
                getDataBase(), Constants.GENERAL_TABLE_STEP_CUSTOMER_ATTENTION, true)));
  }
  @Override
  public void onLoadFinished(Loader<Cursor> loader, Cursor c) {
    super.onLoadFinished(loader, c);

    switch (loader.getId()) {
      case LOADER_SALESCATEGORY:
        salesCategoryAdapter.swapCursor(c);

        break;
    }
  }
  @Override
  public Loader<Cursor> onCreateLoader(int id, Bundle args) {
    super.onCreateLoader(id, args);

    Loader<Cursor> loader = null;

    switch (id) {
      case LOADER_SALESCATEGORY:
        loader =
            new SimpleCursorLoader(this.getActivity()) {
              @Override
              public Cursor loadInBackground() {
                return SalesCategory.getSalesCategoryCursor(getDataBase());
              }
            };
        break;
    }

    return loader;
  }
  @Override
  public void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);

    setContentView(R.layout.fragment_client_messages_attention);
  }
 @Override
 public void onStart() {
   super.onStart();
 }