| | |
| | | }, |
| | | "planOrderFinishRate": { |
| | | "description": "计划达成率", |
| | | "type": "string" |
| | | "type": "integer" |
| | | }, |
| | | "planProductionAmount": { |
| | | "description": "计划加工数", |
| | |
| | | "description": "总设备数", |
| | | "type": "integer" |
| | | }, |
| | | "totalProductionAmount": { |
| | | "description": "总产量", |
| | | "type": "integer" |
| | | }, |
| | | "updatedAt": { |
| | | "type": "string" |
| | | }, |
| | |
| | | }, |
| | | "workOrderStatsData": { |
| | | "description": "工单进度统计", |
| | | "type": "string" |
| | | }, |
| | | "workerTypeStats": { |
| | | "description": "人员工种分析", |
| | | "type": "array", |
| | | "items": { |
| | | "$ref": "#/definitions/model.CommonStats" |
| | | } |
| | | }, |
| | | "workerTypeStatsData": { |
| | | "description": "人员工种分析", |
| | | "type": "string" |
| | | }, |
| | | "workshopStats": { |
| | |
| | | "defective": { |
| | | "type": "integer" |
| | | }, |
| | | "name": { |
| | | "type": "string" |
| | | }, |
| | | "percent": { |
| | | "type": "integer" |
| | | }, |
| | |
| | | }, |
| | | "planOrderFinishRate": { |
| | | "description": "计划达成率", |
| | | "type": "string" |
| | | "type": "integer" |
| | | }, |
| | | "planProductionAmount": { |
| | | "description": "计划加工数", |
| | |
| | | "description": "总设备数", |
| | | "type": "integer" |
| | | }, |
| | | "totalProductionAmount": { |
| | | "description": "总产量", |
| | | "type": "integer" |
| | | }, |
| | | "updatedAt": { |
| | | "type": "string" |
| | | }, |
| | |
| | | }, |
| | | "workOrderStatsData": { |
| | | "description": "工单进度统计", |
| | | "type": "string" |
| | | }, |
| | | "workerTypeStats": { |
| | | "description": "人员工种分析", |
| | | "type": "array", |
| | | "items": { |
| | | "$ref": "#/definitions/model.CommonStats" |
| | | } |
| | | }, |
| | | "workerTypeStatsData": { |
| | | "description": "人员工种分析", |
| | | "type": "string" |
| | | }, |
| | | "workshopStats": { |
| | |
| | | "defective": { |
| | | "type": "integer" |
| | | }, |
| | | "name": { |
| | | "type": "string" |
| | | }, |
| | | "percent": { |
| | | "type": "integer" |
| | | }, |
| | |
| | | type: string |
| | | planOrderFinishRate: |
| | | description: 计划达成率 |
| | | type: string |
| | | type: integer |
| | | planProductionAmount: |
| | | description: 计划加工数 |
| | | type: integer |
| | |
| | | totalDeviceAmount: |
| | | description: 总设备数 |
| | | type: integer |
| | | totalProductionAmount: |
| | | description: 总产量 |
| | | type: integer |
| | | updatedAt: |
| | | type: string |
| | | version: |
| | |
| | | type: array |
| | | workOrderStatsData: |
| | | description: 工单进度统计 |
| | | type: string |
| | | workerTypeStats: |
| | | description: 人员工种分析 |
| | | items: |
| | | $ref: '#/definitions/model.CommonStats' |
| | | type: array |
| | | workerTypeStatsData: |
| | | description: 人员工种分析 |
| | | type: string |
| | | workshopStats: |
| | | description: 车间统计 |
| | |
| | | properties: |
| | | defective: |
| | | type: integer |
| | | name: |
| | | type: string |
| | | percent: |
| | | type: integer |
| | | qualified: |
| | |
| | | gorm.Model |
| | | Version string |
| | | DeviceRunningAmount int //开机台数 |
| | | totalProductionAmount int //总产量 |
| | | WorkOrderAmount int //生产工单数 |
| | | DelayWorkOrderAmount int //延期交付工单数 |
| | | TotalProductionAmount int //总产量 |
| | | WorkOrderAmount int64 //生产工单数 |
| | | DelayWorkOrderAmount int64 //延期交付工单数 |
| | | MaterialMissWorkOrderAmount int //物料不足工单数 |
| | | PlanOrderFinishRate string //计划达成率 |
| | | TotalDeviceAmount int //总设备数 |
| | | InMaintenanceDeviceAmount int //维修中设备数 |
| | | PlanOrderFinishRate int64 //计划达成率 |
| | | TotalDeviceAmount int64 //总设备数 |
| | | InMaintenanceDeviceAmount int64 //维修中设备数 |
| | | InternalDeviceRunningAmount int //自有开机台数 |
| | | ExternalDeviceRunningAmount int //外加工台数 |
| | | OutPlanProductionAmount int //计划外加工数 |
| | |
| | | PersonnelProductivity []*CommonStats `gorm:"-"` //人员生产效率 |
| | | PersonnelSkillPercentData string //人员技能占比 |
| | | PersonnelSkillPercent []*CommonStats `gorm:"-"` //人员技能占比 |
| | | WorkerTypeStatsData string //人员工种分析 |
| | | WorkerTypeStats []*CommonStats `gorm:"-"` //人员工种分析 |
| | | |
| | | TodayFinishAmount int //车间当日合计生产 |
| | | TodayFinishAmount int64 //车间当日合计生产 |
| | | TodayQualifiedRate string //车间当日正品率 |
| | | WorkshopStatsData string //车间统计 |
| | | WorkshopStats []*WorkshopStats `gorm:"-"` //车间统计 |
| | |
| | | } |
| | | |
| | | WorkshopStats struct { |
| | | Total int |
| | | Qualified int |
| | | Name string |
| | | Total int64 |
| | | Qualified int64 |
| | | Defective int |
| | | Percent int |
| | | } |
| | |
| | | var orderFinishRate []*CommonStats |
| | | var personnelProductivity []*CommonStats |
| | | var personnelSkillPercent []*CommonStats |
| | | var workerTypeStats []*CommonStats |
| | | var workshopStats []*WorkshopStats |
| | | var workOrderStats []*WorkOrderStats |
| | | var err error |
| | |
| | | slf.PersonnelSkillPercent = personnelSkillPercent |
| | | } |
| | | } |
| | | if slf.WorkerTypeStatsData != "" { |
| | | if err = json.Unmarshal([]byte(slf.WorkerTypeStatsData), &workerTypeStats); err == nil { |
| | | slf.WorkerTypeStats = workerTypeStats |
| | | } |
| | | } |
| | | if slf.WorkshopStatsData != "" { |
| | | if err = json.Unmarshal([]byte(slf.WorkshopStatsData), &workshopStats); err == nil { |
| | | slf.WorkshopStats = workshopStats |