增加默认接诊人数
This commit is contained in:
parent
63118e7261
commit
4804e3f930
@ -11,8 +11,9 @@ use Hyperf\Snowflake\Concern\Snowflake;
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* @property string $system_inquiry_config_id 主键id
|
* @property string $system_inquiry_config_id 主键id
|
||||||
* @property int $inquiry_type 接诊类型(1:专家问诊 2:快速问诊 3:公益问诊 4:问诊购药)
|
* @property int $inquiry_type 接诊类型(1:专家问诊 2:快速问诊 3:公益问诊 4:问诊购药 5:检测)
|
||||||
* @property int $inquiry_mode 接诊方式(1:图文 2:视频 3:语音 4:电话 5:会员)
|
* @property int $inquiry_mode 接诊方式(1:图文 2:视频 3:语音 4:电话 5:会员 6:疑难会诊 7:附赠)
|
||||||
|
* @property int $default_work_num_day 默认每日接诊数量
|
||||||
* @property int $max_work_num_day 每日最大接诊数量
|
* @property int $max_work_num_day 每日最大接诊数量
|
||||||
* @property string $inquiry_price 接诊价格
|
* @property string $inquiry_price 接诊价格
|
||||||
* @property string $min_inquiry_price 最低接诊价格(专家问诊)
|
* @property string $min_inquiry_price 最低接诊价格(专家问诊)
|
||||||
@ -34,12 +35,12 @@ class SystemInquiryConfig extends Model
|
|||||||
/**
|
/**
|
||||||
* The attributes that are mass assignable.
|
* The attributes that are mass assignable.
|
||||||
*/
|
*/
|
||||||
protected array $fillable = ['system_inquiry_config_id', 'inquiry_type', 'inquiry_mode', 'max_work_num_day', 'inquiry_price', 'min_inquiry_price', 'max_inquiry_price', 'times_number', 'duration', 'created_at', 'updated_at'];
|
protected array $fillable = ['system_inquiry_config_id', 'inquiry_type', 'inquiry_mode', 'default_work_num_day', 'max_work_num_day', 'inquiry_price', 'min_inquiry_price', 'max_inquiry_price', 'times_number', 'duration', 'created_at', 'updated_at'];
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The attributes that should be cast to native types.
|
* The attributes that should be cast to native types.
|
||||||
*/
|
*/
|
||||||
protected array $casts = ['system_inquiry_config_id' => 'string', 'inquiry_type' => 'integer', 'inquiry_mode' => 'integer', 'max_work_num_day' => 'integer', 'times_number' => 'integer', 'duration' => 'integer', 'created_at' => 'datetime', 'updated_at' => 'datetime'];
|
protected array $casts = ['system_inquiry_config_id' => 'string', 'inquiry_type' => 'integer', 'inquiry_mode' => 'integer', 'max_work_num_day' => 'integer', 'times_number' => 'integer', 'duration' => 'integer', 'created_at' => 'datetime', 'updated_at' => 'datetime', 'default_work_num_day' => 'integer'];
|
||||||
|
|
||||||
protected string $primaryKey = "system_inquiry_config_id";
|
protected string $primaryKey = "system_inquiry_config_id";
|
||||||
|
|
||||||
|
|||||||
@ -58,9 +58,6 @@ class DoctorInquiryService extends BaseService
|
|||||||
// 接诊价格
|
// 接诊价格
|
||||||
$info['inquiry_price'] = 0;
|
$info['inquiry_price'] = 0;
|
||||||
|
|
||||||
// 接诊人数
|
|
||||||
$info['work_num_day'] = 30;
|
|
||||||
|
|
||||||
// 系统问诊配置表
|
// 系统问诊配置表
|
||||||
$params = array();
|
$params = array();
|
||||||
$params['inquiry_type'] = $inquiry_type;
|
$params['inquiry_type'] = $inquiry_type;
|
||||||
@ -85,6 +82,9 @@ class DoctorInquiryService extends BaseService
|
|||||||
|
|
||||||
$info['inquiry_price'] = $inquiry_price[0];
|
$info['inquiry_price'] = $inquiry_price[0];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// 默认接诊人数
|
||||||
|
$info['work_num_day'] = $system_inquiry_config['default_work_num_day'] ?: 0;
|
||||||
} else {
|
} else {
|
||||||
// 接诊价格
|
// 接诊价格
|
||||||
$info['inquiry_price'] = $doctor_inquiry_config['inquiry_price'] ?: 0;
|
$info['inquiry_price'] = $doctor_inquiry_config['inquiry_price'] ?: 0;
|
||||||
@ -194,7 +194,7 @@ class DoctorInquiryService extends BaseService
|
|||||||
$data['inquiry_mode'] = $inquiry_mode;
|
$data['inquiry_mode'] = $inquiry_mode;
|
||||||
$data['is_enable'] = 1; // 是否启用(0:否 1:是)
|
$data['is_enable'] = 1; // 是否启用(0:否 1:是)
|
||||||
$data['last_enable_method'] = 1; // 最后开启方式(1:自己 2:后台)
|
$data['last_enable_method'] = 1; // 最后开启方式(1:自己 2:后台)
|
||||||
$data['work_num_day'] = $system_inquiry_config['max_work_num_day'] ?: 0;
|
$data['work_num_day'] = $system_inquiry_config['default_work_num_day'] ?: 0;
|
||||||
$data['inquiry_price'] = $system_inquiry_config['inquiry_price'];
|
$data['inquiry_price'] = $system_inquiry_config['inquiry_price'];
|
||||||
|
|
||||||
$doctor_inquiry_config = DoctorInquiryConfig::addInquiryConfig($data);
|
$doctor_inquiry_config = DoctorInquiryConfig::addInquiryConfig($data);
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user