// Path: ListViewHelper_Library/src/com/shizhefei/view/listviewhelper/IDataAdapter.java
// public interface IDataAdapter<DATA> extends ListAdapter {
// 
//     public abstract void setData(DATA data, boolean isRefresh);
// 
//     public abstract DATA getData();
// 
//     public void notifyDataSetChanged();
// 
// }
// 
// Path: app/src/main/java/com/kejiwen/architecture/activity/NoteActivity.java
// public class NoteActivity extends BaseActivity implements OnBackStackListener, View.OnClickListener {
//     private final static String TAG = "ProfileInfoActivity";
// 
//     private String mInfoStr;
// 
//     private EditText mEditText;
//     private Button mSubmitBtn;
//     private int mType;
// 
//     @Override
//     protected void onCreate(Bundle savedInstanceState) {
//         setContentView(R.layout.note);
//         super.onCreate(savedInstanceState);
//         mTitleBar.setTitle("备注");
//         mTitleBar.setBackButton(R.mipmap.titlebar_back_arrow, this);
// 
//         mEditText = (EditText) findViewById(R.id.note_edit);
//         mSubmitBtn = (Button) findViewById(R.id.submit_btn);
//         mSubmitBtn.setOnClickListener(this);
//         mInfoStr = getIntent().getStringExtra("info");
//         mType = getIntent().getIntExtra("type", 0);
// 
//         if (!TextUtils.isEmpty(mInfoStr)) {
//             mEditText.setText(mInfoStr);
//         }
//     }
// 
//     @Override
//     protected int getTitleBarRes() {
//         return R.id.titlebar;
//     }
// 
//     @Override
//     public void onBackStack() {
//         finish();
//     }
// 
//     @Override
//     public void onClick(View view) {
//         mInfoStr = mEditText.getText().toString();
//         int position = getIntent().getIntExtra("position",0);
//         if (mType == 1) {
//             CustomerDataSource.mLists.get(position).setAlias(mInfoStr);
//         } else if (mType == 2) {
//             CustomerProductDataSource.mLists.get(position).setComment(mInfoStr);
//         } else if (mType == 3){
//             ProductCustomerOnsellDataSource.mLists.get(position).setNote(mInfoStr);
//         } else if (mType == 4) {
//             ProductCustomerHistoryDataSource.mLists.get(position).setNote(mInfoStr);
//         }
// 
//         Toast.makeText(this, "提交成功", Toast.LENGTH_LONG).show();
//         finish();
//     }
// 
// }
// 
// Path: app/src/main/java/com/kejiwen/architecture/model/CustomerItem.java
// public class CustomerItem {
//     private String name;
//     private String alias;
//     private String risk;
//     private String sex;
//     private String phone;
//     private String state;
//     private String type;
//     private String position;
//     private String note;
// 
//     public String getName() {
//         return name;
//     }
// 
//     public void setName(String name) {
//         this.name = name;
//     }
// 
//     public String getAlias() {
//         return alias;
//     }
// 
//     public void setAlias(String alias) {
//         this.alias = alias;
//     }
// 
//     public String getRisk() {
//         return risk;
//     }
// 
//     public void setRisk(String risk) {
//         this.risk = risk;
//     }
// 
//     public String getSex() {
//         return sex;
//     }
// 
//     public void setSex(String sex) {
//         this.sex = sex;
//     }
// 
//     public String getPhone() {
//         return phone;
//     }
// 
//     public void setPhone(String phone) {
//         this.phone = phone;
//     }
// 
//     public String getState() {
//         return state;
//     }
// 
//     public void setState(String state) {
//         this.state = state;
//     }
// 
//     public String getType() {
//         return type;
//     }
// 
//     public void setType(String type) {
//         this.type = type;
//     }
// 
//     public String getPosition() {
//         return position;
//     }
// 
//     public void setPosition(String position) {
//         this.position = position;
//     }
// 
//     public String getNote() {
//         return note;
//     }
// 
//     public void setNote(String note) {
//         this.note = note;
//     }
// }


import java.util.ArrayList;
import java.util.List;
import android.content.Context;
import android.content.Intent;
import android.net.Uri;
import android.text.TextUtils;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.BaseAdapter;
import android.widget.ImageButton;
import android.widget.TextView;
import com.shizhefei.view.listviewhelper.IDataAdapter;
import com.kejiwen.architecture.R;
import com.kejiwen.architecture.activity.NoteActivity;
import com.kejiwen.architecture.model.CustomerItem;

/*
Copyright 2015 shizhefei（LuckyJayce）

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

   http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
 */
package com.kejiwen.architecture.adapter;




public class ProductCustomerOnSellListAdapter extends BaseAdapter implements IDataAdapter<List<CustomerItem>> {
    private List<CustomerItem> mCustomerItems = new ArrayList<CustomerItem>();
    private LayoutInflater mInflater;
    private Context mContext;

    public ProductCustomerOnSellListAdapter(Context context) {
        super();
        mContext = context;
        mInflater = LayoutInflater.from(context);
    }

    @Override

// Path: ListViewHelper_Library/src/com/shizhefei/view/listviewhelper/IDataAdapter.java
// public interface IDataAdapter<DATA> extends ListAdapter {
// 
//     public abstract void setData(DATA data, boolean isRefresh);
// 
//     public abstract DATA getData();
// 
//     public void notifyDataSetChanged();
// 
// }
// 
// Path: app/src/main/java/com/kejiwen/architecture/activity/NoteActivity.java
// public class NoteActivity extends BaseActivity implements OnBackStackListener, View.OnClickListener {
//     private final static String TAG = "ProfileInfoActivity";
// 
//     private String mInfoStr;
// 
//     private EditText mEditText;
//     private Button mSubmitBtn;
//     private int mType;
// 
//     @Override
//     protected void onCreate(Bundle savedInstanceState) {
//         setContentView(R.layout.note);
//         super.onCreate(savedInstanceState);
//         mTitleBar.setTitle("备注");
//         mTitleBar.setBackButton(R.mipmap.titlebar_back_arrow, this);
// 
//         mEditText = (EditText) findViewById(R.id.note_edit);
//         mSubmitBtn = (Button) findViewById(R.id.submit_btn);
//         mSubmitBtn.setOnClickListener(this);
//         mInfoStr = getIntent().getStringExtra("info");
//         mType = getIntent().getIntExtra("type", 0);
// 
//         if (!TextUtils.isEmpty(mInfoStr)) {
//             mEditText.setText(mInfoStr);
//         }
//     }
// 
//     @Override
//     protected int getTitleBarRes() {
//         return R.id.titlebar;
//     }
// 
//     @Override
//     public void onBackStack() {
//         finish();
//     }
// 
//     @Override
//     public void onClick(View view) {
//         mInfoStr = mEditText.getText().toString();
//         int position = getIntent().getIntExtra("position",0);
//         if (mType == 1) {
//             CustomerDataSource.mLists.get(position).setAlias(mInfoStr);
//         } else if (mType == 2) {
//             CustomerProductDataSource.mLists.get(position).setComment(mInfoStr);
//         } else if (mType == 3){
//             ProductCustomerOnsellDataSource.mLists.get(position).setNote(mInfoStr);
//         } else if (mType == 4) {
//             ProductCustomerHistoryDataSource.mLists.get(position).setNote(mInfoStr);
//         }
// 
//         Toast.makeText(this, "提交成功", Toast.LENGTH_LONG).show();
//         finish();
//     }
// 
// }
// 
// Path: app/src/main/java/com/kejiwen/architecture/model/CustomerItem.java
// public class CustomerItem {
//     private String name;
//     private String alias;
//     private String risk;
//     private String sex;
//     private String phone;
//     private String state;
//     private String type;
//     private String position;
//     private String note;
// 
//     public String getName() {
//         return name;
//     }
// 
//     public void setName(String name) {
//         this.name = name;
//     }
// 
//     public String getAlias() {
//         return alias;
//     }
// 
//     public void setAlias(String alias) {
//         this.alias = alias;
//     }
// 
//     public String getRisk() {
//         return risk;
//     }
// 
//     public void setRisk(String risk) {
//         this.risk = risk;
//     }
// 
//     public String getSex() {
//         return sex;
//     }
// 
//     public void setSex(String sex) {
//         this.sex = sex;
//     }
// 
//     public String getPhone() {
//         return phone;
//     }
// 
//     public void setPhone(String phone) {
//         this.phone = phone;
//     }
// 
//     public String getState() {
//         return state;
//     }
// 
//     public void setState(String state) {
//         this.state = state;
//     }
// 
//     public String getType() {
//         return type;
//     }
// 
//     public void setType(String type) {
//         this.type = type;
//     }
// 
//     public String getPosition() {
//         return position;
//     }
// 
//     public void setPosition(String position) {
//         this.position = position;
//     }
// 
//     public String getNote() {
//         return note;
//     }
// 
//     public void setNote(String note) {
//         this.note = note;
//     }
// }


// Path: app/src/main/java/com/kejiwen/architecture/adapter/ProductCustomerOnSellListAdapter.java
import java.util.ArrayList;
import java.util.List;
import android.content.Context;
import android.content.Intent;
import android.net.Uri;
import android.text.TextUtils;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.BaseAdapter;
import android.widget.ImageButton;
import android.widget.TextView;
import com.shizhefei.view.listviewhelper.IDataAdapter;
import com.kejiwen.architecture.R;
import com.kejiwen.architecture.activity.NoteActivity;
import com.kejiwen.architecture.model.CustomerItem;

/*
Copyright 2015 shizhefei（LuckyJayce）

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

   http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
 */
package com.kejiwen.architecture.adapter;




public class ProductCustomerOnSellListAdapter extends BaseAdapter implements IDataAdapter<List<CustomerItem>> {
    private List<CustomerItem> mCustomerItems = new ArrayList<CustomerItem>();
    private LayoutInflater mInflater;
    private Context mContext;

    public ProductCustomerOnSellListAdapter(Context context) {
        super();
        mContext = context;
        mInflater = LayoutInflater.from(context);
    }

    @Override

    public int getCount() {
