Browse Source

现场修改77777

tags/old_version_1
fyf 1 year ago
parent
commit
ca003243d7
4 changed files with 72 additions and 8 deletions
  1. +4
    -0
      app/src/main/java/com/bonait/bnframework/business/ExecuteTheRecipe.java
  2. +51
    -0
      app/src/main/java/com/bonait/bnframework/business/MainInit.java
  3. +8
    -8
      app/src/main/java/com/bonait/bnframework/modules/home/fragment/Home1Fragment.java
  4. +9
    -0
      app/src/main/java/com/bonait/bnframework/modules/home/fragment/mode/QDListSectionAdapter.java

+ 4
- 0
app/src/main/java/com/bonait/bnframework/business/ExecuteTheRecipe.java View File

@@ -427,6 +427,10 @@ public class ExecuteTheRecipe {

if(ishand)
{
if(ConfigName.getInstance().versionSelectionEnum.equals("大炒自动投料版本") || ConfigName.getInstance().versionSelectionEnum.equals("小炒版本"))
{
ExecuteTheRecipe.BottomClick("平移-去1号位");
}
String name = "";
String zl = "";
int val = 0;


+ 51
- 0
app/src/main/java/com/bonait/bnframework/business/MainInit.java View File

@@ -104,6 +104,8 @@ public class MainInit {
// NetworkUtils.connetEnternet(app);

//text();

//cx_cp();
}


@@ -126,6 +128,55 @@ public class MainInit {
}
}
}





}

/**
* 根据第一个配方重新写配方
*/
public static void cx_cp()
{
ArrayList<BPA_GOODS> goods= QueryDB.GetGoodsALL();
//38f0a737-2476-40d8-a7d8-28ff7796e9d2 鱼香肉丝
//b414cef3-a315-4841-954a-abee17af02d6 重游发财


String ydrs="dc2136ad-ee32-48c1-8077-afbdb80af9a3";
ArrayList<BPA_GOODSRECIPE> ydrs_pf=QueryDB.GetGoodsSrecipeID(ydrs);


String hc="b414cef3-a315-4841-954a-abee17af02d6";
ArrayList<BPA_GOODSRECIPE> hc_pf=QueryDB.GetGoodsSrecipeID(hc);

ArrayList<BPA_GOODSRECIPE> rec= QueryDB.GetGoodsSrecipeALL();
for (BPA_GOODSRECIPE pf:rec)
{
QueryDB.DeleteGoodsSrecipe(pf);
}
for (BPA_GOODS good:goods)
{
if(good.sort<=30)
{
for (BPA_GOODSRECIPE m:ydrs_pf)
{
m.id=java.util.UUID.randomUUID().toString();
m.goodsID=good.id;
QueryDB.AddGoodsSrecipe(m);
}
}else
{
for (BPA_GOODSRECIPE m:hc_pf)
{
m.id=java.util.UUID.randomUUID().toString();
m.goodsID=good.id;
QueryDB.AddGoodsSrecipe(m);
}
}
}
}
/**
* 初始化数据库数据(默认数据)


+ 8
- 8
app/src/main/java/com/bonait/bnframework/modules/home/fragment/Home1Fragment.java View File

@@ -351,10 +351,10 @@ public class Home1Fragment extends BaseFragment {
@Override
public void clickListener(View v, Object data) {
boolean status = !(boolean) data;
if (!IsMake(true))
{
return;
}
// if (!IsMake(true))
// {
// return;
// }
choushui_control.SetStatus(status);
ToastUtils.info("点击按钮:炒锅抽水" + status);
ExecuteTheRecipe.WritePLC("炒锅抽水", status, null);
@@ -370,10 +370,10 @@ public class Home1Fragment extends BaseFragment {
@Override
public void clickListener(View v, Object data) {
boolean status = !(boolean) data;
if (!IsMake(true))
{
return;
}
// if (!IsMake(true))
// {
// return;
// }
fangshui_control.SetStatus(status);
ToastUtils.info("点击按钮:炒锅放水" + status);
ExecuteTheRecipe.WritePLC("炒锅放水", status, null);


+ 9
- 0
app/src/main/java/com/bonait/bnframework/modules/home/fragment/mode/QDListSectionAdapter.java View File

@@ -15,6 +15,8 @@ import com.bonait.bnframework.business.ConfigData;
import com.bonait.bnframework.common.constant.ConfigName;
import com.bonait.bnframework.common.constant.MessageName;
import com.bonait.bnframework.common.db.QueryDB;
import com.bonait.bnframework.common.db.mode.BPA_GOODS;
import com.bonait.bnframework.common.db.mode.BPA_GOODSRECIPE;
import com.bonait.bnframework.common.helper.I.MyClickListener;
import com.bonait.bnframework.common.image.MyBitmapUtils;
import com.bonait.bnframework.common.message.MessageManager;
@@ -25,6 +27,8 @@ import com.qmuiteam.qmui.widget.dialog.QMUIDialogAction;
import com.qmuiteam.qmui.widget.section.QMUIDefaultStickySectionAdapter;
import com.qmuiteam.qmui.widget.section.QMUISection;

import java.util.ArrayList;

public class QDListSectionAdapter extends QMUIDefaultStickySectionAdapter {
private TextView tvTag ,tvNote,tvAccount,Sc_text,delete_text;

@@ -113,6 +117,11 @@ public class QDListSectionAdapter extends QMUIDefaultStickySectionAdapter {
ConfigData.getInstance().GetGoodProcess(holder.itemView.getContext(),id,true);
}else
{
// ArrayList<BPA_GOODS> goods= QueryDB.GetGoodsALL();
// for (BPA_GOODS good:goods)
// {
// ConfigData.getInstance().UploadGoods(holder.itemView.getContext(),good.id);
// }
ConfigData.getInstance().UploadGoods(holder.itemView.getContext(),id);
}
}


Loading…
Cancel
Save