|
|
#pragma once
|
|
|
|
|
|
#include "mAlgDefines.h"
|
|
|
|
|
|
//#include "iLayerTableModel.h"
|
|
|
|
|
|
#include "iWxDataBasic.h"
|
|
|
#include "mGuiAnal_global.h"
|
|
|
|
|
|
namespace Ui {
|
|
|
class iWxDataBasicEx;
|
|
|
}
|
|
|
|
|
|
class ZxTableView;
|
|
|
class ZxTableModel;
|
|
|
class tLayerDesc;
|
|
|
struct LayerData;
|
|
|
|
|
|
// 分析:第一步
|
|
|
class M_GUI_ANAL_EXPORT iWxDataBasicEx : public iWxDataBasic
|
|
|
{
|
|
|
Q_OBJECT
|
|
|
|
|
|
public:
|
|
|
|
|
|
explicit iWxDataBasicEx(/*QString sFluid, */QWidget *parent = 0);
|
|
|
~iWxDataBasicEx();
|
|
|
|
|
|
virtual void initUI();
|
|
|
|
|
|
// 外部传入 名称
|
|
|
void setName(QString s);
|
|
|
QString getName();
|
|
|
|
|
|
// 类型
|
|
|
// QString getTestType();
|
|
|
// PvtTestType getTestTypeEx();
|
|
|
|
|
|
// 获取 相态选项
|
|
|
PvtFluidType getPhasePft();
|
|
|
QString getPhasePftDesc();
|
|
|
|
|
|
// 流体性质
|
|
|
virtual QString getBasicMainPft();
|
|
|
virtual bool isPhaseS();
|
|
|
|
|
|
int getLayerCount();
|
|
|
|
|
|
public:
|
|
|
|
|
|
// 类似clone
|
|
|
virtual void copyFrom(ZxUiBase* p);
|
|
|
|
|
|
// 序列化
|
|
|
virtual void onSerialize(ZxSerializer* ser);
|
|
|
virtual void onDeserialize(ZxSerializer* ser);
|
|
|
|
|
|
// 新增接口(与一个数据对象体进行绑定式关联)
|
|
|
virtual bool saveAsDataObj(ZxDataObject*& pDataObj);
|
|
|
virtual bool loadFromDataObj(ZxDataObject*& pDataObj);
|
|
|
|
|
|
// 返回名称标识
|
|
|
virtual QString getAwiName();
|
|
|
|
|
|
public:
|
|
|
|
|
|
// 在导航模式下,点击下一步时,先判断本步是否正确
|
|
|
//virtual bool verifyCurInfos(QString& sLog);
|
|
|
|
|
|
// 在导航模式下,点击下一步时,先判断本步是否正确
|
|
|
virtual bool checkCurWxInputs();
|
|
|
|
|
|
protected:
|
|
|
|
|
|
virtual void paintEvent(QPaintEvent *);
|
|
|
|
|
|
public slots:
|
|
|
|
|
|
// 与sigPrevWxValueOf对应
|
|
|
virtual void slotValueToNextWx(QStringList& listParas, QMap<QString, QVariant>& map);
|
|
|
|
|
|
// 外部:返回分析名称
|
|
|
virtual void slotGetAnalTag(QString& s);
|
|
|
|
|
|
// 单相多相改变
|
|
|
void slotPhaseSmClicked(int nIndex);
|
|
|
|
|
|
// 相态(主)改变
|
|
|
void slotFluidMainOptionClicked(int nIndex);
|
|
|
|
|
|
void slotRadioStandardClicked(bool bCheck);
|
|
|
void slotRadioInterfereClicked(bool bCheck);
|
|
|
void slotRadioMiniFracClicked(bool bCheck); //这个只有水
|
|
|
void slotRadioMultiLayersClicked(bool bCheck); //多层
|
|
|
|
|
|
virtual void slotResDataPasted(QModelIndex indexTopLeft, QModelIndex indexBottomRight);
|
|
|
|
|
|
private slots:
|
|
|
|
|
|
// 各个相态(子项)Click
|
|
|
void on_cbxOil_clicked();
|
|
|
void on_cbxGas_clicked();
|
|
|
void on_cbxWater_clicked();
|
|
|
void on_cbxCondense_clicked();
|
|
|
void on_cbxPF_clicked();
|
|
|
void on_cbxCO2_clicked();
|
|
|
|
|
|
void slotFuzzyPhasesChanged(const QString& text);
|
|
|
|
|
|
void on_btnMultiLayer_clicked();
|
|
|
|
|
|
private:
|
|
|
|
|
|
virtual void initUI_ResTable();
|
|
|
|
|
|
// 初始储层数据获取
|
|
|
VVecVariant getDefaultResData(int nMinRowCount = 1);
|
|
|
void fillResTableData(VVecVariant& vvec);
|
|
|
void makesureResDataOfML();
|
|
|
|
|
|
/// @brief 建立关联(储层Res表格数据与载体m_vecLayerDescs)
|
|
|
/// @param bRes2Layer true:下侧储层Res表格数据改变,触发m_vecLayerDescs调整
|
|
|
/// false: m_vecLayerDescs改变,触发下侧储层Res表格数据刷新
|
|
|
void makesureLayerAbouts(bool bRes2Layer);
|
|
|
void reCalLayerRatios();
|
|
|
|
|
|
public:
|
|
|
|
|
|
virtual void runResDataChanged();
|
|
|
|
|
|
|
|
|
// 测试类型发生改变的具体响应处理
|
|
|
void onTestTypeChanged(bool bNotMiniFrac);
|
|
|
|
|
|
// 各个相态(子项)Click后的具体响应处理
|
|
|
void onFluidTypeChanged(PvtFluidClass opMain, PvtFluidType opSub, QCheckBox* pCbx);
|
|
|
|
|
|
// 处理互斥部分,比如:油、气 与 凝析气 是互斥的
|
|
|
void _adjustExclusives(PvtFluidClass opMain, PvtFluidType opSub, QCheckBox* pCbx);
|
|
|
|
|
|
// 当前选择了哪些子项(把枚举变为int返回)
|
|
|
PvtFluidType _collectCheckedItems();
|
|
|
|
|
|
// 单相/多相切换后,更改PftOption
|
|
|
void onSmTypeChanged(bool bPhaseS);
|
|
|
void changeCbxState(QCheckBox* pCbx, bool bChecked, bool bEnabled);
|
|
|
void changeRadioState(QRadioButton* pRadio, bool bChecked, bool bEnabled);
|
|
|
|
|
|
// 释放
|
|
|
void releaseLayerDescs();
|
|
|
|
|
|
// 收集
|
|
|
void cacheLayerDescs(QList<LayerData>& listData, bool bClearOlds = true);
|
|
|
|
|
|
signals:
|
|
|
|
|
|
/// @brief 当相态(主或子项)发生改变触发
|
|
|
/// @param nMain 主,常规/非常规/状态方程
|
|
|
/// @param nSubTypes 子项,油/气/水/凝析/CO2/PF,以(int/枚举)传递,外部进行解析
|
|
|
//void sigOptionFluidChanged(int nMain, int nSubTypes);
|
|
|
|
|
|
/// @brief 当勾选多层或者多层数据修改了,则触发
|
|
|
void sigMultiLayerOptionChanged();
|
|
|
|
|
|
public slots:
|
|
|
|
|
|
/// @brief 返回
|
|
|
void slotGetMultiLayerOptions(bool& bMultiLayer, QVector<tLayerDesc*>* ptrVecDescs);
|
|
|
|
|
|
#ifdef _SCAN_OLD_CODES_
|
|
|
// 层对话框传递内容,为保持AI相关代码的一致性,保留QList
|
|
|
void slotLayerInfoOK(QList<LayerData>& listData);
|
|
|
#endif
|
|
|
|
|
|
public:
|
|
|
|
|
|
// 与ExtCustom相关内容
|
|
|
void adjustUiByExtCustom();
|
|
|
void freshStateWithExtCustom(bool bPhaseS);
|
|
|
|
|
|
private:
|
|
|
|
|
|
Ui::iWxDataBasicEx *ui;
|
|
|
|
|
|
bool m_bExtCustom; //内部变量不涉及序列化,只是为了处理方便
|
|
|
|
|
|
QVector<tLayerDesc*> m_vecLayerDescs; //多层信息
|
|
|
};
|