|
|
@@ -0,0 +1,119 @@
|
|
|
+package com.modular.booking.model;
|
|
|
+
|
|
|
+import android.os.Parcel;
|
|
|
+import android.os.Parcelable;
|
|
|
+
|
|
|
+import java.util.List;
|
|
|
+
|
|
|
+/**
|
|
|
+ * Created by Arison on 2018/1/24.
|
|
|
+ */
|
|
|
+
|
|
|
+public class Product implements Parcelable {
|
|
|
+
|
|
|
+ private String Code;
|
|
|
+ private String DishCategoryCode;
|
|
|
+ private String DishCategoryName;
|
|
|
+ private String Name;
|
|
|
+ private String HelpCode;
|
|
|
+ private boolean IsWeightConfim;
|
|
|
+
|
|
|
+ private List<UnitItems> UnitItems;
|
|
|
+
|
|
|
+ public Product() {
|
|
|
+ }
|
|
|
+
|
|
|
+ public String getCode() {
|
|
|
+ return Code;
|
|
|
+ }
|
|
|
+
|
|
|
+ public void setCode(String code) {
|
|
|
+ Code = code;
|
|
|
+ }
|
|
|
+
|
|
|
+ public String getDishCategoryCode() {
|
|
|
+ return DishCategoryCode;
|
|
|
+ }
|
|
|
+
|
|
|
+ public void setDishCategoryCode(String dishCategoryCode) {
|
|
|
+ DishCategoryCode = dishCategoryCode;
|
|
|
+ }
|
|
|
+
|
|
|
+ public String getDishCategoryName() {
|
|
|
+ return DishCategoryName;
|
|
|
+ }
|
|
|
+
|
|
|
+ public void setDishCategoryName(String dishCategoryName) {
|
|
|
+ DishCategoryName = dishCategoryName;
|
|
|
+ }
|
|
|
+
|
|
|
+ public String getName() {
|
|
|
+ return Name;
|
|
|
+ }
|
|
|
+
|
|
|
+ public void setName(String name) {
|
|
|
+ Name = name;
|
|
|
+ }
|
|
|
+
|
|
|
+ public String getHelpCode() {
|
|
|
+ return HelpCode;
|
|
|
+ }
|
|
|
+
|
|
|
+ public void setHelpCode(String helpCode) {
|
|
|
+ HelpCode = helpCode;
|
|
|
+ }
|
|
|
+
|
|
|
+ public boolean isWeightConfim() {
|
|
|
+ return IsWeightConfim;
|
|
|
+ }
|
|
|
+
|
|
|
+ public void setWeightConfim(boolean weightConfim) {
|
|
|
+ IsWeightConfim = weightConfim;
|
|
|
+ }
|
|
|
+
|
|
|
+ public List<com.modular.booking.model.UnitItems> getUnitItems() {
|
|
|
+ return UnitItems;
|
|
|
+ }
|
|
|
+
|
|
|
+ public void setUnitItems(List<com.modular.booking.model.UnitItems> unitItems) {
|
|
|
+ UnitItems = unitItems;
|
|
|
+ }
|
|
|
+
|
|
|
+ @Override
|
|
|
+ public int describeContents() {
|
|
|
+ return 0;
|
|
|
+ }
|
|
|
+
|
|
|
+ @Override
|
|
|
+ public void writeToParcel(Parcel dest, int flags) {
|
|
|
+ dest.writeString(this.Code);
|
|
|
+ dest.writeString(this.DishCategoryCode);
|
|
|
+ dest.writeString(this.DishCategoryName);
|
|
|
+ dest.writeString(this.Name);
|
|
|
+ dest.writeString(this.HelpCode);
|
|
|
+ dest.writeByte(this.IsWeightConfim ? (byte) 1 : (byte) 0);
|
|
|
+ dest.writeTypedList(this.UnitItems);
|
|
|
+ }
|
|
|
+
|
|
|
+ protected Product(Parcel in) {
|
|
|
+ this.Code = in.readString();
|
|
|
+ this.DishCategoryCode = in.readString();
|
|
|
+ this.DishCategoryName = in.readString();
|
|
|
+ this.Name = in.readString();
|
|
|
+ this.HelpCode = in.readString();
|
|
|
+ this.IsWeightConfim = in.readByte() != 0;
|
|
|
+ this.UnitItems = in.createTypedArrayList(com.modular.booking.model.UnitItems.CREATOR);
|
|
|
+ }
|
|
|
+
|
|
|
+ public static final Creator<Product> CREATOR = new Creator<Product>() {
|
|
|
+ @Override
|
|
|
+ public Product createFromParcel(Parcel source) {
|
|
|
+ return new Product(source);
|
|
|
+ }
|
|
|
+
|
|
|
+ @Override
|
|
|
+ public Product[] newArray(int size) {
|
|
|
+ return new Product[size];
|
|
|
+ }
|
|
|
+ };
|
|
|
+}
|